Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@lrnwebcomponents/responsive-utility

Package Overview
Dependencies
Maintainers
4
Versions
111
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@lrnwebcomponents/responsive-utility - npm Package Compare versions

Comparing version 2.3.3 to 2.3.6

vscode-html-custom-data.json

128

custom-elements.json
{
"version": 2,
"tags": []
"version": "experimental",
"tags": [
{
"name": "responsive-utility",
"attributes": [
{
"name": "details",
"description": "Stores",
"type": "array",
"default": "[]"
}
],
"properties": [
{
"name": "details",
"attribute": "details",
"description": "Stores",
"type": "array",
"default": "[]"
},
{
"name": "rootPath",
"type": "string"
},
{
"name": "importPath",
"type": "string"
},
{
"name": "root",
"type": "HTMLElement | StampedTemplate | ShadowRoot | null"
},
{
"name": "$",
"type": "{ [key: string]: Element; }"
},
{
"name": "PROPERTY_EFFECT_TYPES",
"type": "{ [key: string]: string; }"
}
]
},
{
"name": "responsive-utility",
"attributes": [
{
"name": "details",
"description": "Stores",
"type": "array",
"default": "[]"
}
],
"properties": [
{
"name": "details",
"attribute": "details",
"description": "Stores",
"type": "array",
"default": "[]"
},
{
"name": "rootPath",
"type": "string"
},
{
"name": "importPath",
"type": "string"
},
{
"name": "root",
"type": "HTMLElement | StampedTemplate | ShadowRoot | null"
},
{
"name": "$",
"type": "{ [key: string]: Element; }"
},
{
"name": "PROPERTY_EFFECT_TYPES",
"type": "{ [key: string]: string; }"
}
]
},
{
"name": "tag"
},
{
"name": "responsive-utility",
"attributes": [
{
"name": "details",
"description": "Stores",
"type": "array",
"default": "[]"
}
],
"properties": [
{
"name": "details",
"attribute": "details",
"description": "Stores",
"type": "array",
"default": "[]"
},
{
"name": "rootPath",
"type": "string"
},
{
"name": "importPath",
"type": "string"
},
{
"name": "root",
"type": "HTMLElement | StampedTemplate | ShadowRoot | null"
},
{
"name": "$",
"type": "{ [key: string]: Element; }"
},
{
"name": "PROPERTY_EFFECT_TYPES",
"type": "{ [key: string]: string; }"
}
]
}
]
}

8

package.json

@@ -14,3 +14,3 @@ {

},
"version": "2.3.3",
"version": "2.3.6",
"description": "Automated conversion of responsive-utility/",

@@ -27,3 +27,3 @@ "repository": {

"start": "yarn run dev",
"build": "../../node_modules/.bin/gulp && ../../node_modules/.bin/rollup -c && ../../node_modules/.bin/prettier --ignore-path ../../.prettierignore --write '**/*.{js,json}' && wca analyze \"**/*.js\" --outFile custom-elements.json",
"build": "../../node_modules/.bin/gulp && ../../node_modules/.bin/rollup -c && ../../node_modules/.bin/prettier --ignore-path ../../.prettierignore --write '**/*.{js,json}' && wca analyze \"**/*.js\" --format vscode --outFile vscode-html-custom-data.json",
"dev": "concurrently --kill-others \"yarn run watch\" \"yarn run serve\"",

@@ -44,3 +44,3 @@ "watch": "../../node_modules/.bin/gulp dev",

"@lrnwebcomponents/deduping-fix": "^2.1.1",
"@lrnwebcomponents/storybook-utilities": "^2.3.3",
"@lrnwebcomponents/storybook-utilities": "^2.3.6",
"@polymer/iron-component-page": "github:PolymerElements/iron-component-page",

@@ -64,3 +64,3 @@ "@polymer/iron-demo-helpers": "3.1.0",

],
"gitHead": "493ea1a015492311b17a8328eee98e4f6eb12948"
"gitHead": "15ccf147355d2d3a441d65446f094c9d031c17c0"
}

@@ -1,2 +0,2 @@

!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports,require("@polymer/polymer/polymer-element.js"),require("@polymer/iron-resizable-behavior/iron-resizable-behavior.js"),require("@polymer/polymer/lib/legacy/class.js")):"function"==typeof define&&define.amd?define(["exports","@polymer/polymer/polymer-element.js","@polymer/iron-resizable-behavior/iron-resizable-behavior.js","@polymer/polymer/lib/legacy/class.js"],t):t((e=e||self).ResponsiveUtility={},e.polymerElement_js,e.ironResizableBehavior_js,e.class_js)}(this,function(e,t,n,i){"use strict";function o(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}function r(e,t,n){return t&&o(e.prototype,t),n&&o(e,n),e}function l(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function s(e){return(s=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function a(e,t){return(a=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function d(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function u(e,t,n){return(u="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var i=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=s(e)););return e}(e,t);if(i){var o=Object.getOwnPropertyDescriptor(i,t);return o.get?o.get.call(n):o.value}})(e,t,n||e)}function c(){var e,t,n=(e=["\n <style>\n :host {\n display: inline;\n }\n </style>\n <slot></slot>\n "],t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}})));return c=function(){return n},n}window.ResponsiveUtility={},window.ResponsiveUtility.instance=null;var p=function(e){function o(){var e,t,n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),t=this,(e=!(n=s(o).call(this))||"object"!=typeof n&&"function"!=typeof n?d(t):n).details=[],null==window.ResponsiveUtility.instance&&(window.ResponsiveUtility.instance=d(e)),e.addEventListener("iron-resize",e._onIronResize.bind(d(e))),e}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&a(e,t)}(o,i.mixinBehaviors([n.IronResizableBehavior],t.PolymerElement)),r(o,[{key:"connectedCallback",value:function(){u(s(o.prototype),"connectedCallback",this).call(this),window.addEventListener("responsive-element",this.responiveElementEvent.bind(this)),window.addEventListener("delete-responsive-element",this.deleteResponiveElementEvent.bind(this))}},{key:"disconnectedCallback",value:function(){window.removeEventListener("responsive-element",this.responiveElementEvent.bind(this)),window.removeEventListener("delete-responsive-element",this.deleteResponiveElementEvent.bind(this)),u(s(o.prototype),"disconnectedCallback",this).call(this)}},{key:"responiveElementEvent",value:function(e){var t={element:e.detail.element,attribute:void 0!==e.detail.attribute&&null!==e.detail.attribute?e.detail.attribute:"responsive-size",relativeToParent:void 0===e.detail.relativeToParent||null===e.detail.relativeToParent||e.detail.relativeToParent,sm:void 0!==e.detail.sm&&null!==e.detail.sm?e.detail.sm:900,md:void 0!==e.detail.md&&null!==e.detail.md?e.detail.md:1200,lg:void 0!==e.detail.lg&&null!==e.detail.lg?e.detail.lg:1500,xl:void 0!==e.detail.xl&&null!==e.detail.xl?e.detail.lg:1800};if("ResizeObserver"in window&&!0===t.relativeToParent){var n=new ResizeObserver(function(){window.ResponsiveUtility.setSize(t)}),i=void 0!==e.detail.parentNode&&null!==e.detail.parentNode?e.detail.parentNode.nodeType===Node.DOCUMENT_FRAGMENT_NODE?e.detail.element.parentNode.host:e.detail.element.parentNode:e.detail.element;n.observe(i)}this.details.push(t),window.ResponsiveUtility.setSize(t)}},{key:"deleteResponiveElementEvent",value:function(e){for(var t=0;t<this.details.length;t++)e.detail===detail[t]&&this.details.splice(t,1)}}],[{key:"template",get:function(){return t.html(c())}},{key:"tag",get:function(){return"responsive-utility"}},{key:"properties",get:function(){return function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},i=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(i=i.concat(Object.getOwnPropertySymbols(n).filter(function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))),i.forEach(function(t){l(e,t,n[t])})}return e}({},u(s(o),"properties",this),{details:{type:Array}})}}]),r(o,[{key:"_onIronResize",value:function(){for(var e=0;e<this.details.length;e++)window.ResponsiveUtility.setSize(this.details[e])}}]),o}();window.customElements.define(p.tag,p),window.ResponsiveUtility.requestAvailability=function(){null==window.ResponsiveUtility.instance&&(window.ResponsiveUtility.instance=document.createElement("responsive-utility")),document.body.appendChild(window.ResponsiveUtility.instance)},window.ResponsiveUtility.setSize=function(e){var t,n=window.ResponsiveUtility._getWidth(e);t=n<e.sm?"xs":n<e.md?"sm":n<e.lg?"md":n<e.xl?"lg":"xl",void 0!==e.element.getAttribute(e.attribute)&&t===e.element.getAttribute(e.attribute)||e.element.setAttribute(e.attribute,t)},window.ResponsiveUtility._getWidth=function(e){var t=e.element;if(!0===e.relativeToParent){if(t&&void 0!==t.offsetWidth&&null!==t.offsetWidth&&t.offsetWidth>0)return t.offsetWidth;if(null!==t.parentNode)return t.parentNode.nodeType===Node.DOCUMENT_FRAGMENT_NODE&&t.parentNode.host?t.parentNode.host.offsetWidth:t.parentNode.offsetWidth}return window.outerWidth},e.ResponsiveUtility=p,Object.defineProperty(e,"__esModule",{value:!0})});
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports,require("@polymer/polymer/polymer-element.js"),require("@polymer/iron-resizable-behavior/iron-resizable-behavior.js"),require("@polymer/polymer/lib/legacy/class.js")):"function"==typeof define&&define.amd?define(["exports","@polymer/polymer/polymer-element.js","@polymer/iron-resizable-behavior/iron-resizable-behavior.js","@polymer/polymer/lib/legacy/class.js"],t):t((e=e||self).ResponsiveUtility={},e.polymerElement_js,e.ironResizableBehavior_js,e.class_js)}(this,function(e,t,n,i){"use strict";function r(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}function o(e,t,n){return t&&r(e.prototype,t),n&&r(e,n),e}function l(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function s(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,i)}return n}function a(e){return(a=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function d(e,t){return(d=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function u(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function c(e,t,n){return(c="undefined"!=typeof Reflect&&Reflect.get?Reflect.get:function(e,t,n){var i=function(e,t){for(;!Object.prototype.hasOwnProperty.call(e,t)&&null!==(e=a(e)););return e}(e,t);if(i){var r=Object.getOwnPropertyDescriptor(i,t);return r.get?r.get.call(n):r.value}})(e,t,n||e)}function p(){var e,t,n=(e=["\n <style>\n :host {\n display: inline;\n }\n </style>\n <slot></slot>\n "],t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}})));return p=function(){return n},n}window.ResponsiveUtility={},window.ResponsiveUtility.instance=null;var f=function(e){function r(){var e,t,n;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,r),t=this,(e=!(n=a(r).call(this))||"object"!=typeof n&&"function"!=typeof n?u(t):n).details=[],null==window.ResponsiveUtility.instance&&(window.ResponsiveUtility.instance=u(e)),e.addEventListener("iron-resize",e._onIronResize.bind(u(e))),e}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&d(e,t)}(r,i.mixinBehaviors([n.IronResizableBehavior],t.PolymerElement)),o(r,[{key:"connectedCallback",value:function(){c(a(r.prototype),"connectedCallback",this).call(this),window.addEventListener("responsive-element",this.responiveElementEvent.bind(this)),window.addEventListener("delete-responsive-element",this.deleteResponiveElementEvent.bind(this))}},{key:"disconnectedCallback",value:function(){window.removeEventListener("responsive-element",this.responiveElementEvent.bind(this)),window.removeEventListener("delete-responsive-element",this.deleteResponiveElementEvent.bind(this)),c(a(r.prototype),"disconnectedCallback",this).call(this)}},{key:"responiveElementEvent",value:function(e){var t={element:e.detail.element,attribute:void 0!==e.detail.attribute&&null!==e.detail.attribute?e.detail.attribute:"responsive-size",relativeToParent:void 0===e.detail.relativeToParent||null===e.detail.relativeToParent||e.detail.relativeToParent,sm:void 0!==e.detail.sm&&null!==e.detail.sm?e.detail.sm:900,md:void 0!==e.detail.md&&null!==e.detail.md?e.detail.md:1200,lg:void 0!==e.detail.lg&&null!==e.detail.lg?e.detail.lg:1500,xl:void 0!==e.detail.xl&&null!==e.detail.xl?e.detail.lg:1800};if("ResizeObserver"in window&&!0===t.relativeToParent){var n=new ResizeObserver(function(){window.ResponsiveUtility.setSize(t)}),i=void 0!==e.detail.parentNode&&null!==e.detail.parentNode?e.detail.parentNode.nodeType===Node.DOCUMENT_FRAGMENT_NODE?e.detail.element.parentNode.host:e.detail.element.parentNode:e.detail.element;n.observe(i)}this.details.push(t),window.ResponsiveUtility.setSize(t)}},{key:"deleteResponiveElementEvent",value:function(e){for(var t=0;t<this.details.length;t++)e.detail===detail[t]&&this.details.splice(t,1)}}],[{key:"template",get:function(){return t.html(p())}},{key:"tag",get:function(){return"responsive-utility"}},{key:"properties",get:function(){return function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?s(Object(n),!0).forEach(function(t){l(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):s(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}({},c(a(r),"properties",this),{details:{type:Array}})}}]),o(r,[{key:"_onIronResize",value:function(){for(var e=0;e<this.details.length;e++)window.ResponsiveUtility.setSize(this.details[e])}}]),r}();window.customElements.define(f.tag,f),window.ResponsiveUtility.requestAvailability=function(){null==window.ResponsiveUtility.instance&&(window.ResponsiveUtility.instance=document.createElement("responsive-utility")),document.body.appendChild(window.ResponsiveUtility.instance)},window.ResponsiveUtility.setSize=function(e){var t,n=window.ResponsiveUtility._getWidth(e);t=n<e.sm?"xs":n<e.md?"sm":n<e.lg?"md":n<e.xl?"lg":"xl",void 0!==e.element.getAttribute(e.attribute)&&t===e.element.getAttribute(e.attribute)||e.element.setAttribute(e.attribute,t)},window.ResponsiveUtility._getWidth=function(e){var t=e.element;if(!0===e.relativeToParent){if(t&&void 0!==t.offsetWidth&&null!==t.offsetWidth&&t.offsetWidth>0)return t.offsetWidth;if(null!==t.parentNode)return t.parentNode.nodeType===Node.DOCUMENT_FRAGMENT_NODE&&t.parentNode.host?t.parentNode.host.offsetWidth:t.parentNode.offsetWidth}return window.outerWidth},e.ResponsiveUtility=f,Object.defineProperty(e,"__esModule",{value:!0})});
//# sourceMappingURL=responsive-utility.umd.js.map

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc