New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

squared

Package Overview
Dependencies
Maintainers
1
Versions
261
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

squared - npm Package Compare versions

Comparing version 0.7.2 to 0.8.0

14

dist/extensions/android.widget.bottomnavigation.js

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

/* android.widget 0.7.2
/* android.widget 0.8.0
https://github.com/anpham6/squared */

@@ -21,4 +21,4 @@

processNode(node, parent) {
const options = $utilA.createViewAttribute(node.element ? this.options[node.element.id] : undefined);
$util.defaultWhenNull(options, 'android', 'background', `?android:attr/windowBackground`);
const options = $utilA.createViewAttribute(this.options[node.elementId]);
$util.assignEmptyValue(options, 'android', 'background', `?android:attr/windowBackground`);
for (let i = 5; i < node.length; i++) {

@@ -53,4 +53,4 @@ const item = node.item(i);

if (menu !== '') {
const options = $utilA.createViewAttribute(node.element ? this.options[node.element.id] : undefined);
$util.defaultWhenNull(options, 'app', 'menu', `@menu/${menu}`);
const options = $utilA.createViewAttribute(this.options[node.elementId]);
$util.assignEmptyValue(options, 'app', 'menu', `@menu/${menu}`);
node.app('menu', options.app.menu);

@@ -60,4 +60,4 @@ }

setStyleTheme() {
const options = $utilA.createStyleAttribute(Object.assign({}, this.options.resource));
$util.defaultWhenNull(options, 'parent', 'Theme.AppCompat.Light.DarkActionBar');
const options = $utilA.createStyleAttribute(this.options.resource);
$util.assignEmptyValue(options, 'parent', 'Theme.AppCompat.Light.DarkActionBar');
$Resource.addTheme(options);

@@ -64,0 +64,0 @@ }

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

this.android=this.android||{},this.android.widget=this.android.widget||{},this.android.widget.bottomnavigation=function(){"use strict";var e=android.base.Resource;const t=squared.base.lib.enumeration,n=squared.lib.util,i=android.lib.constant,a=android.lib.enumeration,o=android.lib.util;class r extends squared.base.Extension{constructor(e,t,n,i){super(e,t,n,i),this.require("android.widget.menu")}processNode(r,d){const s=o.createViewAttribute(r.element?this.options[r.element.id]:void 0);n.defaultWhenNull(s,"android","background","?android:attr/windowBackground");for(let e=5;e<r.length;e++){const t=r.item(e);t.hide();for(const e of t.cascade())e.hide()}r.setControlType(i.SUPPORT_ANDROID.BOTTOM_NAVIGATION,a.CONTAINER_NODE.BLOCK),r.exclude({resource:t.NODE_RESOURCE.ASSET}),r.render(d);const u=this.application.controllerHandler.renderNodeStatic(i.SUPPORT_ANDROID.BOTTOM_NAVIGATION,r.renderDepth,e.formatOptions(s,this.application.extensionManager.optionValueAsBoolean(i.EXT_ANDROID.RESOURCE_STRINGS,"numberResourceValue")),"match_parent","wrap_content",r);for(const e of r.cascade())this.subscribersChild.add(e);return this.setStyleTheme(),{output:u,complete:!0}}postBaseLayout(e){const t=e.renderParent;t&&(t.has("width")||t.android("layout_width","match_parent"),t.has("height")||t.android("layout_height","match_parent"));const i=n.optionalAsString(r.findNestedByName(e.element,"android.widget.menu"),"dataset.layoutName");if(""!==i){const t=o.createViewAttribute(e.element?this.options[e.element.id]:void 0);n.defaultWhenNull(t,"app","menu",`@menu/${i}`),e.app("menu",t.app.menu)}}setStyleTheme(){const t=o.createStyleAttribute(Object.assign({},this.options.resource));n.defaultWhenNull(t,"parent","Theme.AppCompat.Light.DarkActionBar"),e.addTheme(t)}}const d=new r("android.widget.bottomnavigation",2);return squared&&squared.includeAsync(d),d}();
this.android=this.android||{},this.android.widget=this.android.widget||{},this.android.widget.bottomnavigation=function(){"use strict";var e=android.base.Resource;const t=squared.base.lib.enumeration,n=squared.lib.util,a=android.lib.constant,i=android.lib.enumeration,o=android.lib.util;class r extends squared.base.Extension{constructor(e,t,n,a){super(e,t,n,a),this.require("android.widget.menu")}processNode(r,s){const d=o.createViewAttribute(this.options[r.elementId]);n.assignEmptyValue(d,"android","background","?android:attr/windowBackground");for(let e=5;e<r.length;e++){const t=r.item(e);t.hide();for(const e of t.cascade())e.hide()}r.setControlType(a.SUPPORT_ANDROID.BOTTOM_NAVIGATION,i.CONTAINER_NODE.BLOCK),r.exclude({resource:t.NODE_RESOURCE.ASSET}),r.render(s);const u=this.application.controllerHandler.renderNodeStatic(a.SUPPORT_ANDROID.BOTTOM_NAVIGATION,r.renderDepth,e.formatOptions(d,this.application.extensionManager.optionValueAsBoolean(a.EXT_ANDROID.RESOURCE_STRINGS,"numberResourceValue")),"match_parent","wrap_content",r);for(const e of r.cascade())this.subscribersChild.add(e);return this.setStyleTheme(),{output:u,complete:!0}}postBaseLayout(e){const t=e.renderParent;t&&(t.has("width")||t.android("layout_width","match_parent"),t.has("height")||t.android("layout_height","match_parent"));const a=n.optionalAsString(r.findNestedByName(e.element,"android.widget.menu"),"dataset.layoutName");if(""!==a){const t=o.createViewAttribute(this.options[e.elementId]);n.assignEmptyValue(t,"app","menu",`@menu/${a}`),e.app("menu",t.app.menu)}}setStyleTheme(){const t=o.createStyleAttribute(this.options.resource);n.assignEmptyValue(t,"parent","Theme.AppCompat.Light.DarkActionBar"),e.addTheme(t)}}const s=new r("android.widget.bottomnavigation",2);return squared&&squared.includeAsync(s),s}();

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

/* android.widget 0.7.2
/* android.widget 0.8.0
https://github.com/anpham6/squared */

@@ -17,3 +17,3 @@

processNode(node, parent) {
const options = $utilA.createViewAttribute(node.element ? this.options[node.element.id] : undefined);
const options = $utilA.createViewAttribute(this.options[node.elementId]);
node.setControlType($constA.SUPPORT_ANDROID.COORDINATOR, $enumA.CONTAINER_NODE.BLOCK);

@@ -29,3 +29,3 @@ node.exclude({ resource: $enum.NODE_RESOURCE.ASSET });

if (extension) {
const toolbarOptions = $utilA.createViewAttribute(extension.options[toolbar.element.id]);
const toolbarOptions = $utilA.createViewAttribute(extension.options[toolbar.elementId]);
if ('collapsingToolbar' in toolbarOptions) {

@@ -32,0 +32,0 @@ node.android('fitsSystemWindows', 'true');

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

this.android=this.android||{},this.android.widget=this.android.widget||{},this.android.widget.coordinator=function(){"use strict";var e=android.base.Resource;const t=squared.base.lib.enumeration,i=squared.lib.dom,o=android.lib.constant,n=android.lib.enumeration,d=android.lib.util;class r extends squared.base.Extension{processNode(a,s){const l=d.createViewAttribute(a.element?this.options[a.element.id]:void 0);a.setControlType(o.SUPPORT_ANDROID.COORDINATOR,n.CONTAINER_NODE.BLOCK),a.exclude({resource:t.NODE_RESOURCE.ASSET}),a.render(s);const c=this.application.controllerHandler.renderNodeStatic(o.SUPPORT_ANDROID.COORDINATOR,a.renderDepth,e.formatOptions(l,this.application.extensionManager.optionValueAsBoolean(o.EXT_ANDROID.RESOURCE_STRINGS,"numberResourceValue")),"","",a,!0),u=r.findNestedByName(a.element,"android.widget.toolbar");if(u){const e=i.getElementAsNode(u);if(e&&e.element){const t=this.application.extensionManager.retrieve("android.widget.toolbar");if(t){"collapsingToolbar"in d.createViewAttribute(t.options[e.element.id])&&a.android("fitsSystemWindows","true")}}}return{output:c}}postProcedure(e){e.documentRoot&&(e.inlineWidth&&e.some(t=>!!t.rightAligned&&(e.android("layout_width","match_parent",!0),!0)),e.inlineHeight&&e.some(t=>!!t.bottomAligned&&(e.android("layout_height","match_parent",!0),!0)))}}const a=new r("android.widget.coordinator",2);return squared&&squared.includeAsync(a),a}();
this.android=this.android||{},this.android.widget=this.android.widget||{},this.android.widget.coordinator=function(){"use strict";var e=android.base.Resource;const t=squared.base.lib.enumeration,i=squared.lib.dom,o=android.lib.constant,n=android.lib.enumeration,r=android.lib.util;class d extends squared.base.Extension{processNode(a,s){const l=r.createViewAttribute(this.options[a.elementId]);a.setControlType(o.SUPPORT_ANDROID.COORDINATOR,n.CONTAINER_NODE.BLOCK),a.exclude({resource:t.NODE_RESOURCE.ASSET}),a.render(s);const c=this.application.controllerHandler.renderNodeStatic(o.SUPPORT_ANDROID.COORDINATOR,a.renderDepth,e.formatOptions(l,this.application.extensionManager.optionValueAsBoolean(o.EXT_ANDROID.RESOURCE_STRINGS,"numberResourceValue")),"","",a,!0),u=d.findNestedByName(a.element,"android.widget.toolbar");if(u){const e=i.getElementAsNode(u);if(e&&e.element){const t=this.application.extensionManager.retrieve("android.widget.toolbar");if(t){"collapsingToolbar"in r.createViewAttribute(t.options[e.elementId])&&a.android("fitsSystemWindows","true")}}}return{output:c}}postProcedure(e){e.documentRoot&&(e.inlineWidth&&e.some(t=>!!t.rightAligned&&(e.android("layout_width","match_parent",!0),!0)),e.inlineHeight&&e.some(t=>!!t.bottomAligned&&(e.android("layout_height","match_parent",!0),!0)))}}const a=new d("android.widget.coordinator",2);return squared&&squared.includeAsync(a),a}();

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

/* android.widget 0.7.2
/* android.widget 0.8.0
https://github.com/anpham6/squared */

@@ -30,3 +30,3 @@

if (item.tagName === 'NAV' && !$util.includes(item.dataset.use, $const.EXT_NAME.EXTERNAL)) {
item.dataset.use = ($util.hasValue(item.dataset.use) ? `${item.dataset.use}, ` : '') + $const.EXT_NAME.EXTERNAL;
item.dataset.use = (item.dataset.use ? `${item.dataset.use}, ` : '') + $const.EXT_NAME.EXTERNAL;
}

@@ -42,3 +42,3 @@ }

if (Drawer.findNestedByName(node.element, "android.widget.menu" /* MENU */)) {
$util.defaultWhenNull(options, 'android', 'fitsSystemWindows', 'true');
$util.assignEmptyValue(options, 'android', 'fitsSystemWindows', 'true');
this.setStyleTheme(node.localSettings.targetAPI);

@@ -48,3 +48,3 @@ }

const navigationViewOptions = $utilA.createViewAttribute(this.options.navigationView);
$util.defaultWhenNull(navigationViewOptions, 'android', 'layout_gravity', node.localizeString('left'));
$util.assignEmptyValue(navigationViewOptions, 'android', 'layout_gravity', node.localizeString('left'));
const navView = node.item();

@@ -63,15 +63,15 @@ navView.android('layout_gravity', navigationViewOptions.android.layout_gravity);

const application = this.application;
const options = $utilA.createViewAttribute(this.options.navigation);
const options = $utilA.createViewAttribute(this.options.navigationView);
const menu = $util.optionalAsString(Drawer.findNestedByName(node.element, "android.widget.menu" /* MENU */), 'dataset.layoutName');
const headerLayout = $util.optionalAsString(Drawer.findNestedByName(node.element, $const.EXT_NAME.EXTERNAL), 'dataset.layoutName');
if (menu !== '') {
$util.defaultWhenNull(options, 'app', 'menu', `@menu/${menu}`);
$util.assignEmptyValue(options, 'app', 'menu', `@menu/${menu}`);
}
if (headerLayout !== '') {
$util.defaultWhenNull(options, 'app', 'headerLayout', `@layout/${headerLayout}`);
$util.assignEmptyValue(options, 'app', 'headerLayout', `@layout/${headerLayout}`);
}
if (menu !== '' || headerLayout !== '') {
$util.defaultWhenNull(options, 'android', 'id', `${node.documentId}_navigation`);
$util.defaultWhenNull(options, 'android', 'fitsSystemWindows', 'true');
$util.defaultWhenNull(options, 'android', 'layout_gravity', node.localizeString('left'));
$util.assignEmptyValue(options, 'android', 'id', `${node.documentId}_navigation`);
$util.assignEmptyValue(options, 'android', 'fitsSystemWindows', 'true');
$util.assignEmptyValue(options, 'android', 'layout_gravity', node.localizeString('left'));
const output = application.controllerHandler.renderNodeStatic($constA.SUPPORT_ANDROID.NAVIGATION_VIEW, 1, $Resource.formatOptions(options, this.application.extensionManager.optionValueAsBoolean($constA.EXT_ANDROID.RESOURCE_STRINGS, 'numberResourceValue')), 'wrap_content', 'match_parent');

@@ -91,5 +91,5 @@ application.addRenderQueue(node.id.toString(), output);

setStyleTheme(api) {
const options = $utilA.createStyleAttribute(Object.assign({}, this.options.resource));
$util.defaultWhenNull(options, 'parent', 'Theme.AppCompat.Light.NoActionBar');
$util.defaultWhenNull(options.items, 'android:windowTranslucentStatus', 'true');
const options = $utilA.createStyleAttribute(this.options.resource);
$util.assignEmptyValue(options, 'parent', 'Theme.AppCompat.Light.NoActionBar');
$util.assignEmptyValue(options.items, 'android:windowTranslucentStatus', 'true');
$Resource.addTheme(options);

@@ -99,5 +99,5 @@ if (api >= 21) {

lollipop.items = {};
$util.defaultWhenNull(lollipop.output, 'path', 'res/values-v21');
$util.defaultWhenNull(lollipop.items, 'android:windowDrawsSystemBarBackgrounds', 'true');
$util.defaultWhenNull(lollipop.items, 'android:statusBarColor', '@android:color/transparent');
$util.assignEmptyValue(lollipop.output, 'path', 'res/values-v21');
$util.assignEmptyValue(lollipop.items, 'android:windowDrawsSystemBarBackgrounds', 'true');
$util.assignEmptyValue(lollipop.items, 'android:statusBarColor', '@android:color/transparent');
$Resource.addTheme(lollipop);

@@ -104,0 +104,0 @@ }

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

this.android=this.android||{},this.android.widget=this.android.widget||{},this.android.widget.drawer=function(){"use strict";var e=android.base.Resource;const t=squared.base.lib.enumeration,a=squared.base.lib.constant,n=squared.lib.dom,i=squared.lib.util,o=android.lib.constant,d=android.lib.enumeration,r=android.lib.util;class s extends squared.base.Extension{constructor(e,t,n,i){super(e,t,n,i),this.documentRoot=!0,this.require(a.EXT_NAME.EXTERNAL,!0),this.require("android.widget.menu"),this.require("android.widget.coordinator")}init(e){if(this.included(e)&&e.children.length){for(let t=0;t<e.children.length;t++){const n=e.children[t];"NAV"!==n.tagName||i.includes(n.dataset.use,a.EXT_NAME.EXTERNAL)||(n.dataset.use=(i.hasValue(n.dataset.use)?`${n.dataset.use}, `:"")+a.EXT_NAME.EXTERNAL)}return this.application.parseElements.add(e),!0}return!1}processNode(a){const n=r.createViewAttribute(this.options.self);if(s.findNestedByName(a.element,"android.widget.menu"))i.defaultWhenNull(n,"android","fitsSystemWindows","true"),this.setStyleTheme(a.localSettings.targetAPI);else{const e=r.createViewAttribute(this.options.navigationView);i.defaultWhenNull(e,"android","layout_gravity",a.localizeString("left"));const t=a.item();t.android("layout_gravity",e.android.layout_gravity),t.android("layout_height","match_parent"),t.positioned=!0}return a.documentRoot=!0,a.setControlType(o.SUPPORT_ANDROID.DRAWER,d.CONTAINER_NODE.BLOCK),a.exclude({resource:t.NODE_RESOURCE.FONT_STYLE}),{output:this.application.controllerHandler.renderNodeStatic(o.SUPPORT_ANDROID.DRAWER,0,e.formatOptions(n,this.application.extensionManager.optionValueAsBoolean(o.EXT_ANDROID.RESOURCE_STRINGS,"numberResourceValue")),"match_parent","match_parent",a,!0),complete:!0}}postParseDocument(t){const n=this.application,d=r.createViewAttribute(this.options.navigation),l=i.optionalAsString(s.findNestedByName(t.element,"android.widget.menu"),"dataset.layoutName"),u=i.optionalAsString(s.findNestedByName(t.element,a.EXT_NAME.EXTERNAL),"dataset.layoutName");if(""!==l&&i.defaultWhenNull(d,"app","menu",`@menu/${l}`),""!==u&&i.defaultWhenNull(d,"app","headerLayout",`@layout/${u}`),""!==l||""!==u){i.defaultWhenNull(d,"android","id",`${t.documentId}_navigation`),i.defaultWhenNull(d,"android","fitsSystemWindows","true"),i.defaultWhenNull(d,"android","layout_gravity",t.localizeString("left"));const a=n.controllerHandler.renderNodeStatic(o.SUPPORT_ANDROID.NAVIGATION_VIEW,1,e.formatOptions(d,this.application.extensionManager.optionValueAsBoolean(o.EXT_ANDROID.RESOURCE_STRINGS,"numberResourceValue")),"wrap_content","match_parent");n.addRenderQueue(""+t.id,a)}}postProcedure(e){const t=s.findNestedByName(e.element,"android.widget.coordinator");if(t){const e=n.getElementAsNode(t);e&&e.some(e=>e.positioned)&&e.inlineHeight&&e.android("layout_height","match_parent")}}setStyleTheme(t){const a=r.createStyleAttribute(Object.assign({},this.options.resource));if(i.defaultWhenNull(a,"parent","Theme.AppCompat.Light.NoActionBar"),i.defaultWhenNull(a.items,"android:windowTranslucentStatus","true"),e.addTheme(a),t>=21){const t=r.createStyleAttribute(i.cloneObject(a));t.items={},i.defaultWhenNull(t.output,"path","res/values-v21"),i.defaultWhenNull(t.items,"android:windowDrawsSystemBarBackgrounds","true"),i.defaultWhenNull(t.items,"android:statusBarColor","@android:color/transparent"),e.addTheme(t)}}}const l=new s("android.widget.drawer",2);return squared&&squared.includeAsync(l),l}();
this.android=this.android||{},this.android.widget=this.android.widget||{},this.android.widget.drawer=function(){"use strict";var e=android.base.Resource;const t=squared.base.lib.enumeration,a=squared.base.lib.constant,i=squared.lib.dom,n=squared.lib.util,o=android.lib.constant,s=android.lib.enumeration,r=android.lib.util;class d extends squared.base.Extension{constructor(e,t,i,n){super(e,t,i,n),this.documentRoot=!0,this.require(a.EXT_NAME.EXTERNAL,!0),this.require("android.widget.menu"),this.require("android.widget.coordinator")}init(e){if(this.included(e)&&e.children.length){for(let t=0;t<e.children.length;t++){const i=e.children[t];"NAV"!==i.tagName||n.includes(i.dataset.use,a.EXT_NAME.EXTERNAL)||(i.dataset.use=(i.dataset.use?`${i.dataset.use}, `:"")+a.EXT_NAME.EXTERNAL)}return this.application.parseElements.add(e),!0}return!1}processNode(a){const i=r.createViewAttribute(this.options.self);if(d.findNestedByName(a.element,"android.widget.menu"))n.assignEmptyValue(i,"android","fitsSystemWindows","true"),this.setStyleTheme(a.localSettings.targetAPI);else{const e=r.createViewAttribute(this.options.navigationView);n.assignEmptyValue(e,"android","layout_gravity",a.localizeString("left"));const t=a.item();t.android("layout_gravity",e.android.layout_gravity),t.android("layout_height","match_parent"),t.positioned=!0}return a.documentRoot=!0,a.setControlType(o.SUPPORT_ANDROID.DRAWER,s.CONTAINER_NODE.BLOCK),a.exclude({resource:t.NODE_RESOURCE.FONT_STYLE}),{output:this.application.controllerHandler.renderNodeStatic(o.SUPPORT_ANDROID.DRAWER,0,e.formatOptions(i,this.application.extensionManager.optionValueAsBoolean(o.EXT_ANDROID.RESOURCE_STRINGS,"numberResourceValue")),"match_parent","match_parent",a,!0),complete:!0}}postParseDocument(t){const i=this.application,s=r.createViewAttribute(this.options.navigationView),u=n.optionalAsString(d.findNestedByName(t.element,"android.widget.menu"),"dataset.layoutName"),l=n.optionalAsString(d.findNestedByName(t.element,a.EXT_NAME.EXTERNAL),"dataset.layoutName");if(""!==u&&n.assignEmptyValue(s,"app","menu",`@menu/${u}`),""!==l&&n.assignEmptyValue(s,"app","headerLayout",`@layout/${l}`),""!==u||""!==l){n.assignEmptyValue(s,"android","id",`${t.documentId}_navigation`),n.assignEmptyValue(s,"android","fitsSystemWindows","true"),n.assignEmptyValue(s,"android","layout_gravity",t.localizeString("left"));const a=i.controllerHandler.renderNodeStatic(o.SUPPORT_ANDROID.NAVIGATION_VIEW,1,e.formatOptions(s,this.application.extensionManager.optionValueAsBoolean(o.EXT_ANDROID.RESOURCE_STRINGS,"numberResourceValue")),"wrap_content","match_parent");i.addRenderQueue(""+t.id,a)}}postProcedure(e){const t=d.findNestedByName(e.element,"android.widget.coordinator");if(t){const e=i.getElementAsNode(t);e&&e.some(e=>e.positioned)&&e.inlineHeight&&e.android("layout_height","match_parent")}}setStyleTheme(t){const a=r.createStyleAttribute(this.options.resource);if(n.assignEmptyValue(a,"parent","Theme.AppCompat.Light.NoActionBar"),n.assignEmptyValue(a.items,"android:windowTranslucentStatus","true"),e.addTheme(a),t>=21){const t=r.createStyleAttribute(n.cloneObject(a));t.items={},n.assignEmptyValue(t.output,"path","res/values-v21"),n.assignEmptyValue(t.items,"android:windowDrawsSystemBarBackgrounds","true"),n.assignEmptyValue(t.items,"android:statusBarColor","@android:color/transparent"),e.addTheme(t)}}}const u=new d("android.widget.drawer",2);return squared&&squared.includeAsync(u),u}();

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

/* android.widget 0.7.2
/* android.widget 0.8.0
https://github.com/anpham6/squared */

@@ -26,5 +26,5 @@

const element = node.element;
const target = $util.hasValue(node.dataset.target);
const target = node.dataset.target;
const options = $utilA.createViewAttribute(this.options[element.id]);
const backgroundColor = $color.parseRGBA(node.css('backgroundColor'), node.css('opacity'));
const backgroundColor = $color.parseColor(node.css('backgroundColor'), node.css('opacity'));
let colorValue = '';

@@ -34,5 +34,5 @@ if (backgroundColor) {

}
$util.defaultWhenNull(options, 'android', 'backgroundTint', colorValue !== '' ? `@color/${colorValue}` : '?attr/colorAccent');
$util.assignEmptyValue(options, 'android', 'backgroundTint', colorValue !== '' ? `@color/${colorValue}` : '?attr/colorAccent');
if (node.hasBit('excludeProcedure', $enum.NODE_PROCEDURE.ACCESSIBILITY)) {
$util.defaultWhenNull(options, 'android', 'focusable', 'false');
$util.assignEmptyValue(options, 'android', 'focusable', 'false');
}

@@ -57,3 +57,3 @@ let src = '';

if (src !== '') {
$util.defaultWhenNull(options, 'app', 'srcCompat', `@drawable/${src}`);
$util.assignEmptyValue(options, 'app', 'srcCompat', `@drawable/${src}`);
}

@@ -117,3 +117,3 @@ node.setControlType($constA.SUPPORT_ANDROID.FLOATING_ACTION_BUTTON, $enumA.CONTAINER_NODE.BUTTON);

node.exclude({ procedure: $enum.NODE_PROCEDURE.ALIGNMENT });
node.render(node);
node.render(this.application.resolveTarget(target, node));
}

@@ -120,0 +120,0 @@ else {

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

this.android=this.android||{},this.android.widget=this.android.widget||{},this.android.widget.floatingactionbutton=function(){"use strict";var e=android.base.Resource;const t=squared.base.lib.enumeration,a=squared.lib.color,o=squared.lib.util,r=android.lib.constant,i=android.lib.enumeration,n=android.lib.util;const d=new class extends squared.base.Extension{is(e){const t=e.element;return super.is(e)&&("INPUT"!==t.tagName||["button","file","image","reset","search","submit"].includes(t.type))}condition(e){return this.included(e.element)}processNode(d,l){const s=d.element,c=o.hasValue(d.dataset.target),u=n.createViewAttribute(this.options[s.id]),p=a.parseRGBA(d.css("backgroundColor"),d.css("opacity"));let I="";p&&(I=e.addColor(p)),o.defaultWhenNull(u,"android","backgroundTint",""!==I?`@color/${I}`:"?attr/colorAccent"),d.hasBit("excludeProcedure",t.NODE_PROCEDURE.ACCESSIBILITY)&&o.defaultWhenNull(u,"android","focusable","false");let O="";switch(s.tagName){case"IMG":O=e.addImageSrcSet(s,r.PREFIX_ANDROID.DIALOG);break;case"INPUT":O="image"===s.type?e.addImage({mdpi:s.src},r.PREFIX_ANDROID.DIALOG):e.addImageUrl(d.css("backgroundImage"),r.PREFIX_ANDROID.DIALOG);break;case"BUTTON":O=e.addImageUrl(d.css("backgroundImage"),r.PREFIX_ANDROID.DIALOG)}if(""!==O&&o.defaultWhenNull(u,"app","srcCompat",`@drawable/${O}`),d.setControlType(r.SUPPORT_ANDROID.FLOATING_ACTION_BUTTON,i.CONTAINER_NODE.BUTTON),d.exclude({resource:t.NODE_RESOURCE.BOX_STYLE|t.NODE_RESOURCE.ASSET}),!d.pageFlow||c){const e=d.horizontalBias(),a=d.verticalBias(),o=d.documentParent,i=[];i.push(e<.5?d.localizeString("left"):e>.5?d.localizeString("right"):"center_horizontal"),a<.5?(i.push("top"),d.app("layout_dodgeInsetEdges","top")):i.push(a>.5?"bottom":"center_vertical");const n=d.mergeGravity("layout_gravity",...i);if(e>0&&e<1&&.5!==e&&(e<.5?d.modifyBox(16,d.linear.left-o.box.left):d.modifyBox(4,o.box.right-d.linear.right)),a>0&&a<1&&.5!==a&&(a<.5?d.modifyBox(2,d.linear.top-o.box.top):d.modifyBox(8,o.box.bottom-d.linear.bottom)),c){let e=l.documentId;if(l.controlName===r.SUPPORT_ANDROID.TOOLBAR){const t=l.data("android.widget.toolbar","outerParent");t&&(e=t)}d.app("layout_anchor",e),""!==n&&(d.app("layout_anchorGravity",n),d.delete("android","layout_gravity")),d.exclude({procedure:t.NODE_PROCEDURE.ALIGNMENT}),d.render(d)}else d.render(l);d.positioned=!0}else d.render(l);return{output:this.application.controllerHandler.renderNodeStatic(r.SUPPORT_ANDROID.FLOATING_ACTION_BUTTON,c?-1:d.renderDepth,e.formatOptions(u,this.application.extensionManager.optionValueAsBoolean(r.EXT_ANDROID.RESOURCE_STRINGS,"numberResourceValue")),"wrap_content","wrap_content",d),complete:!0}}}("android.widget.floatingactionbutton",2,["BUTTON","INPUT","IMG"]);return squared&&squared.includeAsync(d),d}();
this.android=this.android||{},this.android.widget=this.android.widget||{},this.android.widget.floatingactionbutton=function(){"use strict";var e=android.base.Resource;const t=squared.base.lib.enumeration,a=squared.lib.color,o=squared.lib.util,r=android.lib.constant,i=android.lib.enumeration,n=android.lib.util;const d=new class extends squared.base.Extension{is(e){const t=e.element;return super.is(e)&&("INPUT"!==t.tagName||["button","file","image","reset","search","submit"].includes(t.type))}condition(e){return this.included(e.element)}processNode(d,s){const l=d.element,c=d.dataset.target,u=n.createViewAttribute(this.options[l.id]),p=a.parseColor(d.css("backgroundColor"),d.css("opacity"));let I="";p&&(I=e.addColor(p)),o.assignEmptyValue(u,"android","backgroundTint",""!==I?`@color/${I}`:"?attr/colorAccent"),d.hasBit("excludeProcedure",t.NODE_PROCEDURE.ACCESSIBILITY)&&o.assignEmptyValue(u,"android","focusable","false");let O="";switch(l.tagName){case"IMG":O=e.addImageSrcSet(l,r.PREFIX_ANDROID.DIALOG);break;case"INPUT":O="image"===l.type?e.addImage({mdpi:l.src},r.PREFIX_ANDROID.DIALOG):e.addImageUrl(d.css("backgroundImage"),r.PREFIX_ANDROID.DIALOG);break;case"BUTTON":O=e.addImageUrl(d.css("backgroundImage"),r.PREFIX_ANDROID.DIALOG)}if(""!==O&&o.assignEmptyValue(u,"app","srcCompat",`@drawable/${O}`),d.setControlType(r.SUPPORT_ANDROID.FLOATING_ACTION_BUTTON,i.CONTAINER_NODE.BUTTON),d.exclude({resource:t.NODE_RESOURCE.BOX_STYLE|t.NODE_RESOURCE.ASSET}),!d.pageFlow||c){const e=d.horizontalBias(),a=d.verticalBias(),o=d.documentParent,i=[];i.push(e<.5?d.localizeString("left"):e>.5?d.localizeString("right"):"center_horizontal"),a<.5?(i.push("top"),d.app("layout_dodgeInsetEdges","top")):i.push(a>.5?"bottom":"center_vertical");const n=d.mergeGravity("layout_gravity",...i);if(e>0&&e<1&&.5!==e&&(e<.5?d.modifyBox(16,d.linear.left-o.box.left):d.modifyBox(4,o.box.right-d.linear.right)),a>0&&a<1&&.5!==a&&(a<.5?d.modifyBox(2,d.linear.top-o.box.top):d.modifyBox(8,o.box.bottom-d.linear.bottom)),c){let e=s.documentId;if(s.controlName===r.SUPPORT_ANDROID.TOOLBAR){const t=s.data("android.widget.toolbar","outerParent");t&&(e=t)}d.app("layout_anchor",e),""!==n&&(d.app("layout_anchorGravity",n),d.delete("android","layout_gravity")),d.exclude({procedure:t.NODE_PROCEDURE.ALIGNMENT}),d.render(this.application.resolveTarget(c,d))}else d.render(s);d.positioned=!0}else d.render(s);return{output:this.application.controllerHandler.renderNodeStatic(r.SUPPORT_ANDROID.FLOATING_ACTION_BUTTON,c?-1:d.renderDepth,e.formatOptions(u,this.application.extensionManager.optionValueAsBoolean(r.EXT_ANDROID.RESOURCE_STRINGS,"numberResourceValue")),"wrap_content","wrap_content",d),complete:!0}}}("android.widget.floatingactionbutton",2,["BUTTON","INPUT","IMG"]);return squared&&squared.includeAsync(d),d}();

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

/* android.widget 0.7.2
/* android.widget 0.8.0
https://github.com/anpham6/squared */

@@ -12,2 +12,3 @@

const $enum = squared.base.lib.enumeration;
const $css = squared.lib.css;
const $dom = squared.lib.dom;

@@ -23,3 +24,3 @@ const $util = squared.lib.util;

};
const VALIDATE_ITEM = {
const REGEXP_ITEM = {
id: /^@\+id\/\w+$/,

@@ -44,3 +45,3 @@ title: /^.+$/,

};
const VALIDATE_GROUP = {
const REGEXP_GROUP = {
id: /^@\+id\/\w+$/,

@@ -63,3 +64,3 @@ checkableBehavior: /^(none|all|single)$/,

if (match) {
options[NAMESPACE_APP.includes(attr) ? 'app' : 'android'][attr] = match.join('|');
options[NAMESPACE_APP.includes(attr) ? 'app' : 'android'][attr] = Array.from(new Set(match)).join('|');
}

@@ -113,3 +114,3 @@ }

element.querySelectorAll('NAV').forEach((item) => {
if ($dom.getStyle(element).display === 'none') {
if ($css.getStyle(element).display === 'none') {
$dom.setElementCache(item, 'squaredExternalDisplay', 'none');

@@ -186,8 +187,8 @@ item.style.display = 'block';

node.alignmentType |= 4 /* AUTO_LAYOUT */;
parseDataSet(VALIDATE_GROUP, element, options);
parseDataSet(REGEXP_GROUP, element, options);
break;
case VIEW_NAVIGATION.ITEM:
parseDataSet(VALIDATE_ITEM, element, options);
parseDataSet(REGEXP_ITEM, element, options);
if (!$util.hasValue(options.android.icon)) {
const style = $dom.getStyle(element);
const style = $css.getStyle(element);
let src = $Resource.addImageUrl((style.backgroundImage !== 'none' ? style.backgroundImage : style.background), $constA.PREFIX_ANDROID.MENU);

@@ -194,0 +195,0 @@ if (src !== '') {

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

this.android=this.android||{},this.android.widget=this.android.widget||{},this.android.widget.menu=function(){"use strict";var e=android.base.Resource;const t=squared.base.lib.constant,n=squared.base.lib.enumeration,a=squared.lib.dom,i=squared.lib.util,r=android.lib.constant,o=android.lib.enumeration,l=android.lib.util,s={MENU:"menu",ITEM:"item",GROUP:"group"},d={id:/^@\+id\/\w+$/,title:/^.+$/,titleCondensed:/^.+$/,icon:/^@drawable\/.+$/,onClick:/^.+$/,showAsAction:/^(ifRoom|never|withText|always|collapseActionView)$/,actionLayout:/^@layout\/.+$/,actionViewClass:/^.+$/,actionProviderClass:/^.+$/,alphabeticShortcut:/^[a-zA-Z]+$/,alphabeticModifiers:/(META|CTRL|ALT|SHIFT|SYM|FUNCTION)+/g,numericShortcut:/^[0-9]+$/,numericModifiers:/(META|CTRL|ALT|SHIFT|SYM|FUNCTION)+/g,checkable:/^(true|false)$/,visible:/^(true|false)$/,enabled:/^(true|false)$/,menuCategory:/^(container|system|secondary|alternative)$/,orderInCategory:/^[0-9]+$/},c={id:/^@\+id\/\w+$/,checkableBehavior:/^(none|all|single)$/,visible:/^(true|false)$/,enabled:/^(true|false)$/,menuCategory:/^(container|system|secondary|alternative)$/,orderInCategory:/^[0-9]+$/},u=["showAsAction","actionViewClass","actionProviderClass"];function h(e,t){return e.some(e=>e.element.type===t)}function E(e,t,n){for(const a in t.dataset){const i=t.dataset[a];if(i&&e[a]){const t=i.match(e[a]);t&&(n[u.includes(a)?"app":"android"][a]=t.join("|"))}}}function m(e){if(""!==e.title)return e.title;for(let t=0;t<e.childNodes.length;t++){const n=a.getElementAsNode(e.childNodes[t]);if(n&&n.textElement)return n.textContent.trim()}return""}const N=new class extends squared.base.Extension{constructor(e,n,a,i){super(e,n,a,i),this.require(t.EXT_NAME.EXTERNAL,!0)}init(e){if(this.included(e)){let t=!1;if(e.children.length){t=!0;const n=e.children[0].tagName;for(let a=1;a<e.children.length;a++)if(e.children[a].tagName!==n){t=!1;break}if(t){let n=e.parentElement;for(;n;){if("NAV"===n.tagName&&this.application.parseElements.has(n)){t=!1;break}n=n.parentElement}}}t&&(e.querySelectorAll("NAV").forEach(t=>{"none"===a.getStyle(e).display&&(a.setElementCache(t,"squaredExternalDisplay","none"),t.style.display="block")}),this.application.parseElements.add(e))}return!1}condition(e){return this.included(e.element)}processNode(e){e.documentRoot=!0,e.alignmentType|=4,e.setControlType(s.MENU,o.CONTAINER_NODE.INLINE),e.exclude({procedure:n.NODE_PROCEDURE.ALL,resource:n.NODE_RESOURCE.ALL});const t=this.application.controllerHandler.renderNodeStatic(s.MENU,0,{},"","",e,!0);for(const t of e.cascade())this.subscribersChild.add(t);return{output:t,complete:!0}}processChild(t,u){if(t.plainText)return t.hide(),{output:"",next:!0};const N=l.createViewAttribute(),p=t.element;let g,b="",y=!1;switch("NAV"===t.tagName?(g=s.MENU,b=m(p),y=!0):t.some(e=>e.length>0)?(t.some(e=>"NAV"===e.tagName)?(g=s.ITEM,t.each(e=>"NAV"!==e.tagName&&e.hide())):(g=s.GROUP,t.every(e=>h(e,"radio"))?N.android.checkableBehavior="single":t.every(e=>h(e,"checkbox"))&&(N.android.checkableBehavior="all")),b=m(p),y=!0):(g=s.ITEM,b=(p.title||p.innerText).trim(),h(t,"checkbox")&&!u.android("checkableBehavior")&&(N.android.checkable="true")),g){case s.MENU:t.alignmentType|=4;break;case s.GROUP:t.alignmentType|=4,E(c,p,N);break;case s.ITEM:if(E(d,p,N),!i.hasValue(N.android.icon)){const n=a.getStyle(p);let i=e.addImageUrl("none"!==n.backgroundImage?n.backgroundImage:n.background,r.PREFIX_ANDROID.MENU);if(""!==i)N.android.icon=`@drawable/${i}`;else{const n=t.find(e=>e.imageElement);n&&""!==(i=e.addImageSrcSet(n.element,r.PREFIX_ANDROID.MENU))&&(N.android.icon=`@drawable/${i}`)}}}if(""!==b){const t=e.addString(b,"",this.application.extensionManager.optionValueAsBoolean(r.EXT_ANDROID.RESOURCE_STRINGS,"numberResourceValue"));N.android.title=""!==t?`@string/${t}`:b}return t.setControlType(g,o.CONTAINER_NODE.INLINE),t.exclude({procedure:n.NODE_PROCEDURE.ALL,resource:n.NODE_RESOURCE.ALL}),t.render(u),{output:this.application.controllerHandler.renderNodeStatic(g,t.renderDepth,N,"","",t,y),complete:!0,next:g===s.MENU}}postBaseLayout(e){const t=e.element;if(this.included(t)){t.querySelectorAll("NAV").forEach(e=>{const t=a.getElementCache(e,"squaredExternalDisplay");t&&(e.style.display=t,a.deleteElementCache(e,"squaredExternalDisplay"))});const n=this.application.processing;e===n.node&&n.layout&&(n.layout.pathname="res/menu")}}}("android.widget.menu",2,["NAV"]);return squared&&squared.includeAsync(N),N}();
this.android=this.android||{},this.android.widget=this.android.widget||{},this.android.widget.menu=function(){"use strict";var e=android.base.Resource;const t=squared.base.lib.constant,n=squared.base.lib.enumeration,a=squared.lib.css,i=squared.lib.dom,r=squared.lib.util,o=android.lib.constant,l=android.lib.enumeration,s=android.lib.util,d={MENU:"menu",ITEM:"item",GROUP:"group"},c={id:/^@\+id\/\w+$/,title:/^.+$/,titleCondensed:/^.+$/,icon:/^@drawable\/.+$/,onClick:/^.+$/,showAsAction:/^(ifRoom|never|withText|always|collapseActionView)$/,actionLayout:/^@layout\/.+$/,actionViewClass:/^.+$/,actionProviderClass:/^.+$/,alphabeticShortcut:/^[a-zA-Z]+$/,alphabeticModifiers:/(META|CTRL|ALT|SHIFT|SYM|FUNCTION)+/g,numericShortcut:/^[0-9]+$/,numericModifiers:/(META|CTRL|ALT|SHIFT|SYM|FUNCTION)+/g,checkable:/^(true|false)$/,visible:/^(true|false)$/,enabled:/^(true|false)$/,menuCategory:/^(container|system|secondary|alternative)$/,orderInCategory:/^[0-9]+$/},u={id:/^@\+id\/\w+$/,checkableBehavior:/^(none|all|single)$/,visible:/^(true|false)$/,enabled:/^(true|false)$/,menuCategory:/^(container|system|secondary|alternative)$/,orderInCategory:/^[0-9]+$/},h=["showAsAction","actionViewClass","actionProviderClass"];function E(e,t){return e.some(e=>e.element.type===t)}function m(e,t,n){for(const a in t.dataset){const i=t.dataset[a];if(i&&e[a]){const t=i.match(e[a]);t&&(n[h.includes(a)?"app":"android"][a]=Array.from(new Set(t)).join("|"))}}}function N(e){if(""!==e.title)return e.title;for(let t=0;t<e.childNodes.length;t++){const n=i.getElementAsNode(e.childNodes[t]);if(n&&n.textElement)return n.textContent.trim()}return""}const p=new class extends squared.base.Extension{constructor(e,n,a,i){super(e,n,a,i),this.require(t.EXT_NAME.EXTERNAL,!0)}init(e){if(this.included(e)){let t=!1;if(e.children.length){t=!0;const n=e.children[0].tagName;for(let a=1;a<e.children.length;a++)if(e.children[a].tagName!==n){t=!1;break}if(t){let n=e.parentElement;for(;n;){if("NAV"===n.tagName&&this.application.parseElements.has(n)){t=!1;break}n=n.parentElement}}}t&&(e.querySelectorAll("NAV").forEach(t=>{"none"===a.getStyle(e).display&&(i.setElementCache(t,"squaredExternalDisplay","none"),t.style.display="block")}),this.application.parseElements.add(e))}return!1}condition(e){return this.included(e.element)}processNode(e){e.documentRoot=!0,e.alignmentType|=4,e.setControlType(d.MENU,l.CONTAINER_NODE.INLINE),e.exclude({procedure:n.NODE_PROCEDURE.ALL,resource:n.NODE_RESOURCE.ALL});const t=this.application.controllerHandler.renderNodeStatic(d.MENU,0,{},"","",e,!0);for(const t of e.cascade())this.subscribersChild.add(t);return{output:t,complete:!0}}processChild(t,i){if(t.plainText)return t.hide(),{output:"",next:!0};const h=s.createViewAttribute(),p=t.element;let g,b="",y=!1;switch("NAV"===t.tagName?(g=d.MENU,b=N(p),y=!0):t.some(e=>e.length>0)?(t.some(e=>"NAV"===e.tagName)?(g=d.ITEM,t.each(e=>"NAV"!==e.tagName&&e.hide())):(g=d.GROUP,t.every(e=>E(e,"radio"))?h.android.checkableBehavior="single":t.every(e=>E(e,"checkbox"))&&(h.android.checkableBehavior="all")),b=N(p),y=!0):(g=d.ITEM,b=(p.title||p.innerText).trim(),E(t,"checkbox")&&!i.android("checkableBehavior")&&(h.android.checkable="true")),g){case d.MENU:t.alignmentType|=4;break;case d.GROUP:t.alignmentType|=4,m(u,p,h);break;case d.ITEM:if(m(c,p,h),!r.hasValue(h.android.icon)){const n=a.getStyle(p);let i=e.addImageUrl("none"!==n.backgroundImage?n.backgroundImage:n.background,o.PREFIX_ANDROID.MENU);if(""!==i)h.android.icon=`@drawable/${i}`;else{const n=t.find(e=>e.imageElement);n&&""!==(i=e.addImageSrcSet(n.element,o.PREFIX_ANDROID.MENU))&&(h.android.icon=`@drawable/${i}`)}}}if(""!==b){const t=e.addString(b,"",this.application.extensionManager.optionValueAsBoolean(o.EXT_ANDROID.RESOURCE_STRINGS,"numberResourceValue"));h.android.title=""!==t?`@string/${t}`:b}return t.setControlType(g,l.CONTAINER_NODE.INLINE),t.exclude({procedure:n.NODE_PROCEDURE.ALL,resource:n.NODE_RESOURCE.ALL}),t.render(i),{output:this.application.controllerHandler.renderNodeStatic(g,t.renderDepth,h,"","",t,y),complete:!0,next:g===d.MENU}}postBaseLayout(e){const t=e.element;if(this.included(t)){t.querySelectorAll("NAV").forEach(e=>{const t=i.getElementCache(e,"squaredExternalDisplay");t&&(e.style.display=t,i.deleteElementCache(e,"squaredExternalDisplay"))});const n=this.application.processing;e===n.node&&n.layout&&(n.layout.pathname="res/menu")}}}("android.widget.menu",2,["NAV"]);return squared&&squared.includeAsync(p),p}();

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

/* android.widget 0.7.2
/* android.widget 0.8.0
https://github.com/anpham6/squared */

@@ -12,3 +12,5 @@

const $enum = squared.base.lib.enumeration;
const $css = squared.lib.css;
const $dom = squared.lib.dom;
const $element = squared.lib.element;
const $util = squared.lib.util;

@@ -29,3 +31,3 @@ const $xml = squared.lib.xml;

if (item.tagName === 'NAV' && !$util.includes(item.dataset.use, $const.EXT_NAME.EXTERNAL)) {
item.dataset.use = ($util.hasValue(item.dataset.use) ? `${item.dataset.use}, ` : '') + $const.EXT_NAME.EXTERNAL;
item.dataset.use = (item.dataset.use ? `${item.dataset.use}, ` : '') + $const.EXT_NAME.EXTERNAL;
break;

@@ -47,3 +49,3 @@ }

const element = node.element;
const target = $util.hasValue(node.dataset.target);
const target = node.dataset.target;
const options = Object.assign({}, this.options[element.id]);

@@ -65,4 +67,4 @@ const toolbarOptions = $utilA.createViewAttribute(options.self);

if (result !== '') {
$util.defaultWhenNull(toolbar, 'app', 'navigationIcon', `@drawable/${result}`);
if ($dom.getStyle(item).display !== 'none') {
$util.assignEmptyValue(toolbarOptions, 'app', 'navigationIcon', `@drawable/${result}`);
if ($css.getStyle(item).display !== 'none') {
children--;

@@ -75,4 +77,4 @@ }

if (result !== '') {
$util.defaultWhenNull(toolbar, 'app', 'collapseIcon', `@drawable/${result}`);
if ($dom.getStyle(item).display !== 'none') {
$util.assignEmptyValue(toolbarOptions, 'app', 'collapseIcon', `@drawable/${result}`);
if ($css.getStyle(item).display !== 'none') {
children--;

@@ -83,3 +85,3 @@ }

}
if ($util.hasValue(item.dataset.target)) {
if (item.dataset.target) {
children--;

@@ -103,3 +105,3 @@ }

}
const hasCollapsingToolbar = 'collapsingToolbar' in options || collapsingToolbarChildren.length;
const hasCollapsingToolbar = 'collapsingToolbar' in options || collapsingToolbarChildren.length > 0;
const hasAppBar = 'appBar' in options || appBarChildren.length > 0 || hasCollapsingToolbar;

@@ -109,31 +111,29 @@ let appBarOverlay = '';

if (hasCollapsingToolbar) {
$util.defaultWhenNull(toolbarOptions, 'app', 'layout_collapseMode', 'pin');
$util.assignEmptyValue(toolbarOptions, 'app', 'layout_collapseMode', 'pin');
}
else {
if (!hasAppBar) {
$util.defaultWhenNull(toolbarOptions, 'android', 'fitsSystemWindows', 'true');
$util.assignEmptyValue(toolbarOptions, 'android', 'fitsSystemWindows', 'true');
}
$util.defaultWhenNull(toolbarOptions, 'app', 'popupTheme', '@style/ThemeOverlay.AppCompat.Light');
$util.assignEmptyValue(toolbarOptions, 'app', 'popupTheme', '@style/ThemeOverlay.AppCompat.Light');
if (backgroundImage) {
$util.defaultWhenNull(appBarChildren.length ? appBarOptions : toolbarOptions, 'android', 'background', `@drawable/${$Resource.addImageUrl(node.css('backgroundImage'))}`);
$util.assignEmptyValue(appBarChildren.length ? appBarOptions : toolbarOptions, 'android', 'background', `@drawable/${$Resource.addImageUrl(node.css('backgroundImage'))}`);
node.exclude({ resource: $enum.NODE_RESOURCE.IMAGE_SOURCE });
}
else {
$util.defaultWhenNull(toolbarOptions, 'app', 'layout_scrollFlags', 'scroll|enterAlways');
$util.assignEmptyValue(toolbarOptions, 'app', 'layout_scrollFlags', 'scroll|enterAlways');
}
}
if (appBarChildren.length) {
$util.defaultWhenNull(appBarOptions, 'android', 'layout_height', '?android:attr/actionBarSize');
$util.assignEmptyValue(appBarOptions, 'android', 'layout_height', '?android:attr/actionBarSize');
}
else {
$util.defaultWhenNull(toolbarOptions, 'android', 'layout_height', '?android:attr/actionBarSize');
$util.assignEmptyValue(toolbarOptions, 'android', 'layout_height', '?android:attr/actionBarSize');
node.exclude({ procedure: $enum.NODE_PROCEDURE.LAYOUT });
}
if (hasMenu) {
if (hasAppBar) {
if (toolbarOptions.app.popupTheme) {
popupOverlay = toolbarOptions.app.popupTheme.replace('@style/', '');
}
toolbarOptions.app.popupTheme = '@style/AppTheme.PopupOverlay';
if (hasMenu && hasAppBar) {
if (toolbarOptions.app.popupTheme) {
popupOverlay = toolbarOptions.app.popupTheme.replace('@style/', '');
}
toolbarOptions.app.popupTheme = '@style/AppTheme.PopupOverlay';
}

@@ -162,7 +162,7 @@ const innerDepth = depth + (hasAppBar ? 1 : 0) + (hasCollapsingToolbar ? 1 : 0);

}
$util.defaultWhenNull(backgroundImageOptions, 'android', 'id', `${node.documentId}_image`);
$util.defaultWhenNull(backgroundImageOptions, 'android', 'src', `@drawable/${$Resource.addImageUrl(node.css('backgroundImage'))}`);
$util.defaultWhenNull(backgroundImageOptions, 'android', 'scaleType', scaleType);
$util.defaultWhenNull(backgroundImageOptions, 'android', 'fitsSystemWindows', 'true');
$util.defaultWhenNull(backgroundImageOptions, 'app', 'layout_collapseMode', 'parallax');
$util.assignEmptyValue(backgroundImageOptions, 'android', 'id', `${node.documentId}_image`);
$util.assignEmptyValue(backgroundImageOptions, 'android', 'src', `@drawable/${$Resource.addImageUrl(node.css('backgroundImage'))}`);
$util.assignEmptyValue(backgroundImageOptions, 'android', 'scaleType', scaleType);
$util.assignEmptyValue(backgroundImageOptions, 'android', 'fitsSystemWindows', 'true');
$util.assignEmptyValue(backgroundImageOptions, 'app', 'layout_collapseMode', 'parallax');
output = controller.renderNodeStatic($constA.CONTAINER_ANDROID.IMAGE, innerDepth, $Resource.formatOptions(backgroundImageOptions, numberResourceValue), 'match_parent', 'match_parent') + output;

@@ -176,5 +176,5 @@ node.exclude({ resource: $enum.NODE_RESOURCE.IMAGE_SOURCE });

if (hasAppBar) {
$util.defaultWhenNull(appBarOptions, 'android', 'id', `${node.documentId}_appbar`);
$util.defaultWhenNull(appBarOptions, 'android', 'layout_height', node.hasHeight ? $util.formatPX(node.height) : 'wrap_content');
$util.defaultWhenNull(appBarOptions, 'android', 'fitsSystemWindows', 'true');
$util.assignEmptyValue(appBarOptions, 'android', 'id', `${node.documentId}_appbar`);
$util.assignEmptyValue(appBarOptions, 'android', 'layout_height', node.hasHeight ? $util.formatPX(node.height) : 'wrap_content');
$util.assignEmptyValue(appBarOptions, 'android', 'fitsSystemWindows', 'true');
if (hasMenu) {

@@ -185,10 +185,6 @@ if (appBarOptions.android.theme) {

appBarOptions.android.theme = '@style/AppTheme.AppBarOverlay';
node.data("android.widget.toolbar" /* TOOLBAR */, 'themeData', {
target,
appBarOverlay,
popupOverlay
});
node.data("android.widget.toolbar" /* TOOLBAR */, 'themeData', { appBarOverlay, popupOverlay });
}
else {
$util.defaultWhenNull(appBarOptions, 'android', 'theme', '@style/ThemeOverlay.AppCompat.Dark.ActionBar');
$util.assignEmptyValue(appBarOptions, 'android', 'theme', '@style/ThemeOverlay.AppCompat.Dark.ActionBar');
}

@@ -203,9 +199,9 @@ appBarNode = this.createPlaceholder(node, appBarChildren);

depth++;
$util.defaultWhenNull(collapsingToolbarOptions, 'android', 'id', `${node.documentId}_collapsingtoolbar`);
$util.defaultWhenNull(collapsingToolbarOptions, 'android', 'fitsSystemWindows', 'true');
$util.assignEmptyValue(collapsingToolbarOptions, 'android', 'id', `${node.documentId}_collapsingtoolbar`);
$util.assignEmptyValue(collapsingToolbarOptions, 'android', 'fitsSystemWindows', 'true');
if (!backgroundImage) {
$util.defaultWhenNull(collapsingToolbarOptions, 'app', 'contentScrim', '?attr/colorPrimary');
$util.assignEmptyValue(collapsingToolbarOptions, 'app', 'contentScrim', '?attr/colorPrimary');
}
$util.defaultWhenNull(collapsingToolbarOptions, 'app', 'layout_scrollFlags', 'scroll|exitUntilCollapsed');
$util.defaultWhenNull(collapsingToolbarOptions, 'app', 'toolbarId', node.documentId);
$util.assignEmptyValue(collapsingToolbarOptions, 'app', 'layout_scrollFlags', 'scroll|exitUntilCollapsed');
$util.assignEmptyValue(collapsingToolbarOptions, 'app', 'toolbarId', node.documentId);
collapsingToolbarNode = this.createPlaceholder(node, collapsingToolbarChildren);

@@ -224,3 +220,3 @@ collapsingToolbarNode.parent = appBarNode;

output = $xml.replacePlaceholder(outer, collapsingToolbarNode ? collapsingToolbarNode.id : appBarNode.id, output);
appBarNode.render(target ? appBarNode : parent);
appBarNode.render(target ? application.resolveTarget(target, appBarNode) : parent);
if (!collapsingToolbarNode) {

@@ -238,3 +234,3 @@ node.parent = appBarNode;

else if (collapsingToolbarNode) {
collapsingToolbarNode.render(target ? collapsingToolbarNode : parent);
collapsingToolbarNode.render(target ? application.resolveTarget(target, collapsingToolbarNode) : parent);
node.parent = collapsingToolbarNode;

@@ -244,3 +240,3 @@ node.render(collapsingToolbarNode);

else {
node.render(target ? node : parent);
node.render(target ? application.resolveTarget(target, node) : parent);
}

@@ -262,5 +258,5 @@ node.containerType = $enumA.CONTAINER_NODE.BLOCK;

if (menu !== '') {
const options = node.element && this.options[node.element.id] || {};
const options = this.options[node.elementId] || {};
const toolbarOptions = $utilA.createViewAttribute(options.self);
$util.defaultWhenNull(toolbarOptions, 'app', 'menu', `@menu/${menu}`);
$util.assignEmptyValue(toolbarOptions, 'app', 'menu', `@menu/${menu}`);
node.app('menu', toolbarOptions.app.menu);

@@ -270,19 +266,16 @@ }

if (themeData) {
this.setStyleTheme(themeData);
const options = $utilA.createStyleAttribute(this.options.resource);
const optionsActionBar = $utilA.createStyleAttribute({ name: '.NoActionBar', output: options.output });
const optionsAppBar = $utilA.createStyleAttribute({ name: '.AppBarOverlay', output: options.output });
const optionsPopup = $utilA.createStyleAttribute({ name: '.PopupOverlay', output: options.output });
$util.assignEmptyValue(options, 'parent', 'Theme.AppCompat.Light.DarkActionBar');
$util.assignEmptyValue(optionsActionBar.items, 'windowActionBar', 'false');
$util.assignEmptyValue(optionsActionBar.items, 'windowNoTitle', 'true');
$util.assignEmptyValue(optionsAppBar, 'parent', themeData.appBarOverlay || 'ThemeOverlay.AppCompat.Dark.ActionBar');
$util.assignEmptyValue(optionsPopup, 'parent', themeData.popupOverlay || 'ThemeOverlay.AppCompat.Light');
$Resource.addTheme(options, optionsActionBar, optionsAppBar, optionsPopup);
}
}
setStyleTheme(themeData) {
const options = $utilA.createStyleAttribute(Object.assign({}, this.options.resource));
const optionsActionBar = $utilA.createStyleAttribute({ name: '.NoActionBar', output: options.output });
const optionsAppBar = $utilA.createStyleAttribute({ name: '.AppBarOverlay', output: options.output });
const optionsPopup = $utilA.createStyleAttribute({ name: '.PopupOverlay', output: options.output });
$util.defaultWhenNull(options, 'parent', 'Theme.AppCompat.Light.DarkActionBar');
$util.defaultWhenNull(optionsActionBar.items, 'windowActionBar', 'false');
$util.defaultWhenNull(optionsActionBar.items, 'windowNoTitle', 'true');
$util.defaultWhenNull(optionsAppBar, 'parent', themeData.appBarOverlay || 'ThemeOverlay.AppCompat.Dark.ActionBar');
$util.defaultWhenNull(optionsPopup, 'parent', themeData.popupOverlay || 'ThemeOverlay.AppCompat.Light');
$Resource.addTheme(options, optionsActionBar, optionsAppBar, optionsPopup);
}
createPlaceholder(node, children) {
const placeholder = this.application.createNode($dom.createElement(node.actualParent ? node.actualParent.element : null, node.block));
const placeholder = this.application.createNode($element.createElement(node.actualParent ? node.actualParent.element : null, node.block));
placeholder.inherit(node, 'base');

@@ -301,9 +294,9 @@ placeholder.exclude({ resource: $enum.NODE_RESOURCE.ALL });

const toolbar$1 = new Toolbar("android.widget.toolbar" /* TOOLBAR */, 2 /* ANDROID */);
const toolbar = new Toolbar("android.widget.toolbar" /* TOOLBAR */, 2 /* ANDROID */);
if (squared) {
squared.includeAsync(toolbar$1);
squared.includeAsync(toolbar);
}
return toolbar$1;
return toolbar;
}());

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

this.android=this.android||{},this.android.widget=this.android.widget||{},this.android.widget.toolbar=function(){"use strict";var e=android.base.Resource;const t=squared.base.lib.constant,a=squared.base.lib.enumeration,n=squared.lib.dom,r=squared.lib.util,l=squared.lib.xml,o=android.lib.constant,d=android.lib.enumeration,i=android.lib.util;class s extends squared.base.Extension{constructor(e,t,a,n){super(e,t,a,n),this.require("android.widget.menu")}init(e){if(this.included(e)){for(let a=0;a<e.children.length;a++){const n=e.children[a];if("NAV"===n.tagName&&!r.includes(n.dataset.use,t.EXT_NAME.EXTERNAL)){n.dataset.use=(r.hasValue(n.dataset.use)?`${n.dataset.use}, `:"")+t.EXT_NAME.EXTERNAL;break}}if(e.dataset.target){const t=document.getElementById(e.dataset.target);t&&e.parentElement!==t&&!r.includes(t.dataset.use,"android.widget.coordinator")&&this.application.parseElements.add(e)}}return!1}processNode(t,u){const p=this.application,c=p.controllerHandler,h=t.element,m=r.hasValue(t.dataset.target),N=Object.assign({},this.options[h.id]),g=i.createViewAttribute(N.self),O=i.createViewAttribute(N.appBar),A=i.createViewAttribute(N.collapsingToolbar),f=s.findNestedByName(h,"android.widget.menu"),b=t.has("backgroundImage"),E=[],y=[];let I=m?0:u.renderDepth+1,R=t.filter(e=>!e.positioned).length;for(let t=0;t<h.children.length;t++){const a=h.children[t];if("IMG"===a.tagName){if(r.hasValue(a.dataset.navigationIcon)){const t=e.addImageSrcSet(a,o.PREFIX_ANDROID.MENU);""!==t&&(r.defaultWhenNull(toolbar,"app","navigationIcon",`@drawable/${t}`),"none"!==n.getStyle(a).display&&R--)}if(r.hasValue(a.dataset.collapseIcon)){const t=e.addImageSrcSet(a,o.PREFIX_ANDROID.MENU);""!==t&&(r.defaultWhenNull(toolbar,"app","collapseIcon",`@drawable/${t}`),"none"!==n.getStyle(a).display&&R--)}}if(r.hasValue(a.dataset.target))R--;else{const e=n.getElementAsNode(a);if(e)switch(a.dataset.targetModule){case"appBar":E.push(e),R--;break;case"collapsingToolbar":y.push(e),R--}}}const T="collapsingToolbar"in N||y.length,_="appBar"in N||E.length>0||T;let S="",D="";T?r.defaultWhenNull(g,"app","layout_collapseMode","pin"):(_||r.defaultWhenNull(g,"android","fitsSystemWindows","true"),r.defaultWhenNull(g,"app","popupTheme","@style/ThemeOverlay.AppCompat.Light"),b?(r.defaultWhenNull(E.length?O:g,"android","background",`@drawable/${e.addImageUrl(t.css("backgroundImage"))}`),t.exclude({resource:a.NODE_RESOURCE.IMAGE_SOURCE})):r.defaultWhenNull(g,"app","layout_scrollFlags","scroll|enterAlways")),E.length?r.defaultWhenNull(O,"android","layout_height","?android:attr/actionBarSize"):(r.defaultWhenNull(g,"android","layout_height","?android:attr/actionBarSize"),t.exclude({procedure:a.NODE_PROCEDURE.LAYOUT})),f&&_&&(g.app.popupTheme&&(D=g.app.popupTheme.replace("@style/","")),g.app.popupTheme="@style/AppTheme.PopupOverlay");const w=I+(_?1:0)+(T?1:0),P=p.extensionManager.optionValueAsBoolean(o.EXT_ANDROID.RESOURCE_STRINGS,"numberResourceValue");t.setControlType(o.SUPPORT_ANDROID.TOOLBAR,d.CONTAINER_NODE.BLOCK);let W=c.renderNodeStatic(o.SUPPORT_ANDROID.TOOLBAR,w,e.formatOptions(g,P),"match_parent","wrap_content",t,R>0);if(T&&b){const n=i.createViewAttribute(N.backgroundImage);let l="center";switch(t.css("backgroundSize")){case"cover":case"100% auto":case"auto 100%":l="centerCrop";break;case"contain":case"100% 100%":l="fitXY";break;case"auto":l="matrix"}r.defaultWhenNull(n,"android","id",`${t.documentId}_image`),r.defaultWhenNull(n,"android","src",`@drawable/${e.addImageUrl(t.css("backgroundImage"))}`),r.defaultWhenNull(n,"android","scaleType",l),r.defaultWhenNull(n,"android","fitsSystemWindows","true"),r.defaultWhenNull(n,"app","layout_collapseMode","parallax"),W=c.renderNodeStatic(o.CONTAINER_ANDROID.IMAGE,w,e.formatOptions(n,P),"match_parent","match_parent")+W,t.exclude({resource:a.NODE_RESOURCE.IMAGE_SOURCE})}let C,B,L="";if(_&&(r.defaultWhenNull(O,"android","id",`${t.documentId}_appbar`),r.defaultWhenNull(O,"android","layout_height",t.hasHeight?r.formatPX(t.height):"wrap_content"),r.defaultWhenNull(O,"android","fitsSystemWindows","true"),f?(O.android.theme&&(S=O.android.theme),O.android.theme="@style/AppTheme.AppBarOverlay",t.data("android.widget.toolbar","themeData",{target:m,appBarOverlay:S,popupOverlay:D})):r.defaultWhenNull(O,"android","theme","@style/ThemeOverlay.AppCompat.Dark.ActionBar"),(C=this.createPlaceholder(t,E)).parent=t.parent,C.controlId=i.stripId(O.android.id),C.setControlType(o.SUPPORT_ANDROID.APPBAR,d.CONTAINER_NODE.BLOCK),p.processing.cache.append(C,E.length>0),L=c.renderNodeStatic(o.SUPPORT_ANDROID.APPBAR,m?-1:I,e.formatOptions(O,P),"match_parent","wrap_content",C,!0),T&&(I++,r.defaultWhenNull(A,"android","id",`${t.documentId}_collapsingtoolbar`),r.defaultWhenNull(A,"android","fitsSystemWindows","true"),b||r.defaultWhenNull(A,"app","contentScrim","?attr/colorPrimary"),r.defaultWhenNull(A,"app","layout_scrollFlags","scroll|exitUntilCollapsed"),r.defaultWhenNull(A,"app","toolbarId",t.documentId),(B=this.createPlaceholder(t,y)).parent=C,B))){B.each(e=>e.dataset.target=B.controlId),B.setControlType(o.SUPPORT_ANDROID.COLLAPSING_TOOLBAR,d.CONTAINER_NODE.BLOCK),p.processing.cache.append(B,y.length>0);const t=c.renderNodeStatic(o.SUPPORT_ANDROID.COLLAPSING_TOOLBAR,m&&!_?-1:I,e.formatOptions(A,P),"match_parent","match_parent",B,!0);L=l.replacePlaceholder(L,C.id,t)}return C?(W=l.replacePlaceholder(L,B?B.id:C.id,W),C.render(m?C:u),B?(B.parent=C,B.render(C),t.parent=B):t.parent=C,t.data("android.widget.toolbar","outerParent",C.documentId),t.render(t.parent)):B?(B.render(m?B:u),t.parent=B,t.render(B)):t.render(m?t:u),t.containerType=d.CONTAINER_NODE.BLOCK,t.exclude({resource:a.NODE_RESOURCE.FONT_STYLE}),{output:W}}processChild(e){let t=!1;return e.imageElement&&(r.hasValue(e.dataset.navigationIcon)||r.hasValue(e.dataset.collapseIcon))&&(e.hide(),t=!0),{output:"",next:t}}postProcedure(e){const t=r.optionalAsString(s.findNestedByName(e.element,"android.widget.menu"),"dataset.layoutName");if(""!==t){const a=i.createViewAttribute((e.element&&this.options[e.element.id]||{}).self);r.defaultWhenNull(a,"app","menu",`@menu/${t}`),e.app("menu",a.app.menu)}const a=e.data("android.widget.toolbar","themeData");a&&this.setStyleTheme(a)}setStyleTheme(t){const a=i.createStyleAttribute(Object.assign({},this.options.resource)),n=i.createStyleAttribute({name:".NoActionBar",output:a.output}),l=i.createStyleAttribute({name:".AppBarOverlay",output:a.output}),o=i.createStyleAttribute({name:".PopupOverlay",output:a.output});r.defaultWhenNull(a,"parent","Theme.AppCompat.Light.DarkActionBar"),r.defaultWhenNull(n.items,"windowActionBar","false"),r.defaultWhenNull(n.items,"windowNoTitle","true"),r.defaultWhenNull(l,"parent",t.appBarOverlay||"ThemeOverlay.AppCompat.Dark.ActionBar"),r.defaultWhenNull(o,"parent",t.popupOverlay||"ThemeOverlay.AppCompat.Light"),e.addTheme(a,n,l,o)}createPlaceholder(e,t){const r=this.application.createNode(n.createElement(e.actualParent?e.actualParent.element:null,e.block));r.inherit(e,"base"),r.exclude({resource:a.NODE_RESOURCE.ALL}),r.positioned=!0;let l=1/0;for(const e of t)l=Math.min(l,e.siblingIndex),e.parent=r;return r.siblingIndex=l,r}}const u=new s("android.widget.toolbar",2);return squared&&squared.includeAsync(u),u}();
this.android=this.android||{},this.android.widget=this.android.widget||{},this.android.widget.toolbar=function(){"use strict";var e=android.base.Resource;const a=squared.base.lib.constant,t=squared.base.lib.enumeration,r=squared.lib.css,n=squared.lib.dom,o=squared.lib.element,s=squared.lib.util,i=squared.lib.xml,d=android.lib.constant,l=android.lib.enumeration,p=android.lib.util;class c extends squared.base.Extension{constructor(e,a,t,r){super(e,a,t,r),this.require("android.widget.menu")}init(e){if(this.included(e)){for(let t=0;t<e.children.length;t++){const r=e.children[t];if("NAV"===r.tagName&&!s.includes(r.dataset.use,a.EXT_NAME.EXTERNAL)){r.dataset.use=(r.dataset.use?`${r.dataset.use}, `:"")+a.EXT_NAME.EXTERNAL;break}}if(e.dataset.target){const a=document.getElementById(e.dataset.target);a&&e.parentElement!==a&&!s.includes(a.dataset.use,"android.widget.coordinator")&&this.application.parseElements.add(e)}}return!1}processNode(a,o){const u=this.application,m=u.controllerHandler,g=a.element,h=a.dataset.target,E=Object.assign({},this.options[g.id]),y=p.createViewAttribute(E.self),O=p.createViewAttribute(E.appBar),A=p.createViewAttribute(E.collapsingToolbar),N=c.findNestedByName(g,"android.widget.menu"),b=a.has("backgroundImage"),I=[],R=[];let T=h?0:o.renderDepth+1,_=a.filter(e=>!e.positioned).length;for(let a=0;a<g.children.length;a++){const t=g.children[a];if("IMG"===t.tagName){if(s.hasValue(t.dataset.navigationIcon)){const a=e.addImageSrcSet(t,d.PREFIX_ANDROID.MENU);""!==a&&(s.assignEmptyValue(y,"app","navigationIcon",`@drawable/${a}`),"none"!==r.getStyle(t).display&&_--)}if(s.hasValue(t.dataset.collapseIcon)){const a=e.addImageSrcSet(t,d.PREFIX_ANDROID.MENU);""!==a&&(s.assignEmptyValue(y,"app","collapseIcon",`@drawable/${a}`),"none"!==r.getStyle(t).display&&_--)}}if(t.dataset.target)_--;else{const e=n.getElementAsNode(t);if(e)switch(t.dataset.targetModule){case"appBar":I.push(e),_--;break;case"collapsingToolbar":R.push(e),_--}}}const S="collapsingToolbar"in E||R.length>0,V="appBar"in E||I.length>0||S;let D="",w="";S?s.assignEmptyValue(y,"app","layout_collapseMode","pin"):(V||s.assignEmptyValue(y,"android","fitsSystemWindows","true"),s.assignEmptyValue(y,"app","popupTheme","@style/ThemeOverlay.AppCompat.Light"),b?(s.assignEmptyValue(I.length?O:y,"android","background",`@drawable/${e.addImageUrl(a.css("backgroundImage"))}`),a.exclude({resource:t.NODE_RESOURCE.IMAGE_SOURCE})):s.assignEmptyValue(y,"app","layout_scrollFlags","scroll|enterAlways")),I.length?s.assignEmptyValue(O,"android","layout_height","?android:attr/actionBarSize"):(s.assignEmptyValue(y,"android","layout_height","?android:attr/actionBarSize"),a.exclude({procedure:t.NODE_PROCEDURE.LAYOUT})),N&&V&&(y.app.popupTheme&&(w=y.app.popupTheme.replace("@style/","")),y.app.popupTheme="@style/AppTheme.PopupOverlay");const P=T+(V?1:0)+(S?1:0),f=u.extensionManager.optionValueAsBoolean(d.EXT_ANDROID.RESOURCE_STRINGS,"numberResourceValue");a.setControlType(d.SUPPORT_ANDROID.TOOLBAR,l.CONTAINER_NODE.BLOCK);let C=m.renderNodeStatic(d.SUPPORT_ANDROID.TOOLBAR,P,e.formatOptions(y,f),"match_parent","wrap_content",a,_>0);if(S&&b){const r=p.createViewAttribute(E.backgroundImage);let n="center";switch(a.css("backgroundSize")){case"cover":case"100% auto":case"auto 100%":n="centerCrop";break;case"contain":case"100% 100%":n="fitXY";break;case"auto":n="matrix"}s.assignEmptyValue(r,"android","id",`${a.documentId}_image`),s.assignEmptyValue(r,"android","src",`@drawable/${e.addImageUrl(a.css("backgroundImage"))}`),s.assignEmptyValue(r,"android","scaleType",n),s.assignEmptyValue(r,"android","fitsSystemWindows","true"),s.assignEmptyValue(r,"app","layout_collapseMode","parallax"),C=m.renderNodeStatic(d.CONTAINER_ANDROID.IMAGE,P,e.formatOptions(r,f),"match_parent","match_parent")+C,a.exclude({resource:t.NODE_RESOURCE.IMAGE_SOURCE})}let B,L,v="";if(V&&(s.assignEmptyValue(O,"android","id",`${a.documentId}_appbar`),s.assignEmptyValue(O,"android","layout_height",a.hasHeight?s.formatPX(a.height):"wrap_content"),s.assignEmptyValue(O,"android","fitsSystemWindows","true"),N?(O.android.theme&&(D=O.android.theme),O.android.theme="@style/AppTheme.AppBarOverlay",a.data("android.widget.toolbar","themeData",{appBarOverlay:D,popupOverlay:w})):s.assignEmptyValue(O,"android","theme","@style/ThemeOverlay.AppCompat.Dark.ActionBar"),(B=this.createPlaceholder(a,I)).parent=a.parent,B.controlId=p.stripId(O.android.id),B.setControlType(d.SUPPORT_ANDROID.APPBAR,l.CONTAINER_NODE.BLOCK),u.processing.cache.append(B,I.length>0),v=m.renderNodeStatic(d.SUPPORT_ANDROID.APPBAR,h?-1:T,e.formatOptions(O,f),"match_parent","wrap_content",B,!0),S&&(T++,s.assignEmptyValue(A,"android","id",`${a.documentId}_collapsingtoolbar`),s.assignEmptyValue(A,"android","fitsSystemWindows","true"),b||s.assignEmptyValue(A,"app","contentScrim","?attr/colorPrimary"),s.assignEmptyValue(A,"app","layout_scrollFlags","scroll|exitUntilCollapsed"),s.assignEmptyValue(A,"app","toolbarId",a.documentId),(L=this.createPlaceholder(a,R)).parent=B,L))){L.each(e=>e.dataset.target=L.controlId),L.setControlType(d.SUPPORT_ANDROID.COLLAPSING_TOOLBAR,l.CONTAINER_NODE.BLOCK),u.processing.cache.append(L,R.length>0);const a=m.renderNodeStatic(d.SUPPORT_ANDROID.COLLAPSING_TOOLBAR,h&&!V?-1:T,e.formatOptions(A,f),"match_parent","match_parent",L,!0);v=i.replacePlaceholder(v,B.id,a)}return B?(C=i.replacePlaceholder(v,L?L.id:B.id,C),B.render(h?u.resolveTarget(h,B):o),L?(L.parent=B,L.render(B),a.parent=L):a.parent=B,a.data("android.widget.toolbar","outerParent",B.documentId),a.render(a.parent)):L?(L.render(h?u.resolveTarget(h,L):o),a.parent=L,a.render(L)):a.render(h?u.resolveTarget(h,a):o),a.containerType=l.CONTAINER_NODE.BLOCK,a.exclude({resource:t.NODE_RESOURCE.FONT_STYLE}),{output:C}}processChild(e){let a=!1;return e.imageElement&&(s.hasValue(e.dataset.navigationIcon)||s.hasValue(e.dataset.collapseIcon))&&(e.hide(),a=!0),{output:"",next:a}}postProcedure(a){const t=s.optionalAsString(c.findNestedByName(a.element,"android.widget.menu"),"dataset.layoutName");if(""!==t){const e=p.createViewAttribute((this.options[a.elementId]||{}).self);s.assignEmptyValue(e,"app","menu",`@menu/${t}`),a.app("menu",e.app.menu)}const r=a.data("android.widget.toolbar","themeData");if(r){const a=p.createStyleAttribute(this.options.resource),t=p.createStyleAttribute({name:".NoActionBar",output:a.output}),n=p.createStyleAttribute({name:".AppBarOverlay",output:a.output}),o=p.createStyleAttribute({name:".PopupOverlay",output:a.output});s.assignEmptyValue(a,"parent","Theme.AppCompat.Light.DarkActionBar"),s.assignEmptyValue(t.items,"windowActionBar","false"),s.assignEmptyValue(t.items,"windowNoTitle","true"),s.assignEmptyValue(n,"parent",r.appBarOverlay||"ThemeOverlay.AppCompat.Dark.ActionBar"),s.assignEmptyValue(o,"parent",r.popupOverlay||"ThemeOverlay.AppCompat.Light"),e.addTheme(a,t,n,o)}}createPlaceholder(e,a){const r=this.application.createNode(o.createElement(e.actualParent?e.actualParent.element:null,e.block));r.inherit(e,"base"),r.exclude({resource:t.NODE_RESOURCE.ALL}),r.positioned=!0;let n=1/0;for(const e of a)n=Math.min(n,e.siblingIndex),e.parent=r;return r.siblingIndex=n,r}}const u=new c("android.widget.toolbar",2);return squared&&squared.includeAsync(u),u}();

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

!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((e=e||self).squared={})}(this,function(e){"use strict";function t(e){return(t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function r(e){this.wrapped=e}function n(e){var t,n;function a(t,n){try{var o=e[t](n),l=o.value,u=l instanceof r;Promise.resolve(u?l.wrapped:l).then(function(e){u?a("next",e):i(o.done?"return":"normal",e)},function(e){a("throw",e)})}catch(e){i("throw",e)}}function i(e,r){switch(e){case"return":t.resolve({value:r,done:!0});break;case"throw":t.reject(r);break;default:t.resolve({value:r,done:!1})}(t=t.next)?a(t.key,t.arg):n=null}this._invoke=function(e,r){return new Promise(function(i,o){var l={key:e,arg:r,resolve:i,reject:o,next:null};n?n=n.next=l:(t=n=l,a(e,r))})},"function"!=typeof e.return&&(this.return=void 0)}function a(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}"function"==typeof Symbol&&Symbol.asyncIterator&&(n.prototype[Symbol.asyncIterator]=function(){return this}),n.prototype.next=function(e){return this._invoke("next",e)},n.prototype.throw=function(e){return this._invoke("throw",e)},n.prototype.return=function(e){return this._invoke("return",e)};function i(e,t){return l(e)||function(e,t){var r=[],n=!0,a=!1,i=void 0;try{for(var o,l=e[Symbol.iterator]();!(n=(o=l.next()).done)&&(r.push(o.value),!t||r.length!==t);n=!0);}catch(e){a=!0,i=e}finally{try{n||null==l.return||l.return()}finally{if(a)throw i}}return r}(e,t)||c()}function o(e){return function(e){if(Array.isArray(e)){for(var t=0,r=Array(e.length);t<e.length;t++)r[t]=e[t];return r}}(e)||u(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance")}()}function l(e){if(Array.isArray(e))return e}function u(e){if(Symbol.iterator in Object(e)||"[object Arguments]"===Object.prototype.toString.call(e))return Array.from(e)}function c(){throw new TypeError("Invalid attempt to destructure non-iterable instance")}var s="ABCDEFGHIJKLMNOPQRSTUVWXYZ",f=["","C","CC","CCC","CD","D","DC","DCC","DCCC","CM","","X","XX","XXX","XL","L","LX","LXX","LXXX","XC","","I","II","III","IV","V","VI","VII","VIII","IX"];function v(e,t,r,n){for(var a=r.split("."),i=e,o=t,l=Array.isArray(c=a),u=0,c=l?c:c[Symbol.iterator]();;){var s;if(l){if(u>=c.length)break;s=c[u++]}else{if((u=c.next()).done)break;s=u.value}if(void 0===i[s]||void 0===o[s])return(void 0!==i[s]||void 0!==o[s])&&(void 0!==i[s]?[1,0]:[0,1]);i=i[s],o=o[s]}if(n){var f=parseInt(i),v=parseInt(o);if(!isNaN(f)&&!isNaN(v))return[f,v];if(!isNaN(f))return[1,0];if(!isNaN(v))return[0,1]}return[i,o]}var h={DECIMAL:"-?\\d+(?:.\\d+)?",ZERO_ONE:"0(?:\\.\\d+)?|1(?:\\.0+)?"};h.UNIT="(".concat(h.DECIMAL,")(px|em|ch|pc|pt|vw|vh|vmin|vmax|mm|cm|in)"),h.DEGREE="(".concat(h.DECIMAL,")(deg|rad|turn|grad)"),h.LENGTH="(".concat(h.DECIMAL,"(?:[a-z]{2,}|%)?)");var g={URL:/url\("?(.+?)"?\)/,URI:/^[A-Za-z]+:\/\//,UNIT:RegExp("^".concat(h.UNIT,"$")),ATTRIBUTE:/([^\s]+)="([^"]+)"/};function d(e){return""!==e?!(arguments.length>1&&void 0!==arguments[1])||arguments[1]?e.charAt(0).toUpperCase()+e.substring(1).toLowerCase():e.charAt(0).toLowerCase()+e.substring(1):e}function p(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"-",r=e.replace(RegExp("^".concat(t,"+")),"").match(RegExp("(".concat(t,"[a-z])"),"g"));if(r)for(var n=Array.isArray(i=r),a=0,i=n?i:i[Symbol.iterator]();;){var o;if(n){if(a>=i.length)break;o=i[a++]}else{if((a=i.next()).done)break;o=a.value}e=e.replace(o,o[1].toUpperCase())}return e}function m(e){return e&&parseFloat(e)||0}function y(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return e<1?"".concat(0===t?Math.round(100*e):parseFloat((100*e).toPrecision(t)),"%"):"100%"}function F(e,t){if(e){if(C(e))return"".concat(e,"px");if((e=e.trim()).endsWith("px")||e.endsWith("%")||"auto"===e)return e;var r=e.match(g.UNIT);if(r){var n=parseFloat(r[1]);switch(r[2]){case"em":case"ch":n*=t||16;break;case"pc":n*=12;case"pt":n*=4/3;break;case"vw":n*=window.innerWidth/100;break;case"vh":n*=window.innerHeight/100;break;case"vmin":n*=Math.min(window.innerWidth,window.innerHeight)/100;break;case"vmax":n*=Math.max(window.innerWidth,window.innerHeight)/100;break;case"mm":n/=10;case"cm":n/=2.54;case"in":n*=96*window.devicePixelRatio}return"".concat(n,"px")}}return"0px"}function b(e,t,r){return arguments.length>3&&void 0!==arguments[3]&&arguments[3]?D(e)?m(e)/100:parseFloat(F(e,r))/t:D(e)?Math.round(t*(m(e)/100)):parseFloat(F(e,r))}function A(e){return"string"==typeof e&&(e=parseFloat(e)),isNaN(e)?"0px":"".concat(Math.round(e),"px")}function E(e){return"string"==typeof e&&(e=parseFloat(e)),isNaN(e)?"0%":e<1?y(e):"".concat(Math.round(e),"%")}function x(e,t){return(e&t)===t}function C(e){return""!==e&&/^-?\d+(\.\d+)?$/.test(e.trim())}function k(e){return"string"==typeof e&&""!==e.trim()}function D(e){return/^\d+(\.\d+)?%$/.test(e)}function B(e){for(var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],a=Array.isArray(o=e),i=0,o=a?o:o[Symbol.iterator]();;){var l;if(a){if(i>=o.length)break;l=o[i++]}else{if((i=o.next()).done)break;l=i.value}var u=l;Array.isArray(u)?r.push(B(u,[],n)):n&&"object"===t(u)?r.push(S(u,{},!0)):r.push(u)}return r}function S(e){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];for(var a in e)r[a]=Array.isArray(e[a])?n?B(e[a],[],!0):e[a]:"object"===t(e[a])?S(e[a],{},n):e[a];return r}function w(e,r,n){var a,i=!1;if(e&&"object"===t(e)){a=e;var o=r.split("."),l=0;do{a=a[o[l]]}while(null!=a&&++l<o.length&&"string"!=typeof a&&"number"!=typeof a&&"boolean"!=typeof a);i=null!=a&&l===o.length}switch(n){case"object":return i?a:null;case"number":return i&&!isNaN(parseInt(a))?parseInt(a):0;case"boolean":return i&&!0===a;default:return i?""+a:""}}function M(e){if(!g.URI.test(e)){var t=location.pathname.split("/");if(t.pop(),"/"===e.charAt(0))e=location.origin+e;else if(e.startsWith("../")){var r,n=[],a=0,i=e.split("/"),o=Array.isArray(i),l=0;for(i=o?i:i[Symbol.iterator]();;){var u;if(o){if(l>=i.length)break;u=i[l++]}else{if((l=i.next()).done)break;u=l.value}".."===u?a++:n.push(u)}(r=t=t.slice(0,Math.max(t.length-a,0))).push.apply(r,n),e=location.origin+t.join("/")}else e="".concat(location.origin+t.join("/"),"/").concat(e)}return e}function I(e,t){return e?e.replace(RegExp("^".concat(t,"+")),""):""}function R(e,t){return e?e.replace(RegExp("".concat(t,"+$")),""):""}function N(e){return null!=e&&""!==(""+e).trim()}function O(e,t){return e===t||Math.floor(e)===Math.floor(t)||Math.ceil(e)===Math.ceil(t)||Math.ceil(e)===Math.floor(t)||Math.floor(e)===Math.ceil(t)}function T(e,t){for(var r=[],n=[],a=0;a<e.length;a++){var i=e[a];t(i,a,e)?r.push(i):n.push(i)}return[r,n]}function L(e,t,r){for(var n=0;n<e.length;n++)t(e[n],n,e)&&(r&&r(e[n],n,e),e.splice(n--,1));return e}function _(e,t){for(var r=[],n=0;n<e.length;n++)t(e[n],n,e)&&r.push(e[n]);return r}function P(e,t){for(var r=[],n=0;n<e.length;n++){var a=t(e[n],n,e);N(a)&&r.push(a)}return r}function G(e,t){for(var r=[],n=0;n<e.length;n++)r[n]=t(e[n],n,e);return r}function j(e,t){for(var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"\n",n="",a=0;a<e.length;a++){var i=t(e[a],a,e);""!==i&&(n+=i+r)}return n.substring(0,n.length-r.length)}var z=Object.freeze({REGEXP_STRING:h,REGEXP_PATTERN:g,capitalize:d,convertUnderscore:function(e){var t=(e=e.charAt(0).toLowerCase()+e.substring(1)).match(/([a-z][A-Z])/g);if(t)for(var r=Array.isArray(a=t),n=0,a=r?a:a[Symbol.iterator]();;){var i;if(r){if(n>=a.length)break;i=a[n++]}else{if((n=a.next()).done)break;i=n.value}var o=i;e=e.replace(o,"".concat(o[0],"_").concat(o[1].toLowerCase()))}return e},convertCamelCase:p,convertWord:function(e){return e?e.replace(arguments.length>1&&void 0!==arguments[1]&&arguments[1]?/[^a-zA-Z\d]+/g:/[^\w]+/g,"_").trim():""},convertInt:function(e){return e&&parseInt(e)||0},convertFloat:m,convertAngle:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"deg",r=parseFloat(e);switch(t){case"rad":r*=180/Math.PI;break;case"grad":r/=400;case"turn":r*=360}return r},convertPercent:y,convertPX:F,convertPercentPX:b,convertAlpha:function e(t){for(var r="";t>=s.length;){var n=Math.floor(t/s.length);n>1&&n<=s.length?(r+=s.charAt(n-1),t-=n*s.length):n>s.length&&(r+=e(n*s.length),t-=n*s.length);var a=t%s.length;r+=s.charAt(a),t-=a+s.length}return r=s.charAt(t)+r},convertRoman:function(e){for(var t=(""+e).split(""),r="",n=3;n--;)r=(f[parseInt(t.pop()||"")+10*n]||"")+r;return"M".repeat(parseInt(t.join("")))+r},convertEnum:function(e,t,r){for(var n=Object.keys(t),a=0;a<n.length;a++){var i=n[a];if(e===t[i])return r[i]}return""},formatPX:A,formatPercent:E,formatString:function(e){for(var t=0;t<(arguments.length<=1?0:arguments.length-1);t++)e=e.replace("{".concat(t,"}"),t+1<1||arguments.length<=t+1?void 0:arguments[t+1]);return e},hasBit:x,isNumber:C,isString:k,isArray:function(e){return Array.isArray(e)&&e.length>0},isUnit:function(e){return g.UNIT.test(e)},isPercent:D,isEqual:function(e,t){if(e===t)return!0;if(Array.isArray(e)&&Array.isArray(t)){if(e.length===t.length){for(var r=0;r<e.length;r++)if(e[r]!==t[r])return!1;return!0}}else if(Object.keys(e).length===Object.keys(t).length){for(var n in e)if(e[n]!==t[n])return!1;return!0}return!1},includes:function(e,t){if(e){var r=e.split(arguments.length>2&&void 0!==arguments[2]?arguments[2]:","),n=Array.isArray(r),a=0;for(r=n?r:r[Symbol.iterator]();;){var i;if(n){if(a>=r.length)break;i=r[a++]}else{if((a=r.next()).done)break;i=a.value}if(i.trim()===t)return!0}}return!1},cloneInstance:function(e){return Object.assign(Object.create(Object.getPrototypeOf(e)),e)},cloneArray:B,cloneObject:S,optional:w,optionalAsObject:function(e,t){return w(e,t,"object")},optionalAsString:function(e,t){return w(e,t,"string")},optionalAsNumber:function(e,t){return w(e,t,"number")},optionalAsBoolean:function(e,t){return w(e,t,"boolean")},resolvePath:M,trimNull:function(e){return e?e.trim():""},trimString:function(e,t){return e?I(R(e,t),t):""},trimStart:I,trimEnd:R,indexOf:function(e){for(var t=arguments.length,r=Array(t>1?t-1:0),n=1;n<t;n++)r[n-1]=arguments[n];for(var a=0;a<r.length;a++){var i=e.indexOf(r[a]);if(-1!==i)return i}return-1},lastIndexOf:function(e){return e.substring(e.lastIndexOf(arguments.length>1&&void 0!==arguments[1]?arguments[1]:"/")+1)},searchObject:function(e,r){var n,a=[];if("object"===t(r))for(var i in r){var o=r[i];N(e[o])&&a.push([o,e[o]])}else for(var l in n=/^\*.+\*$/.test(r)?function(e){return-1!==e.indexOf(r.replace(/\*/g,""))}:/^\*/.test(r)?function(e){return e.endsWith(r.replace(/\*/,""))}:/\*$/.test(r)?function(e){return e.startsWith(r.replace(/\*/,""))}:function(e){return e===r},e)n(l)&&a.push([l,e[l]]);return a},hasValue:N,hasInSet:function(e,t){for(var r=Array.isArray(a=e),n=0,a=r?a:a[Symbol.iterator]();;){var i;if(r){if(n>=a.length)break;i=a[n++]}else{if((n=a.next()).done)break;i=n.value}if(t(i))return!0}return!1},withinRange:function(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;return t>=e-r&&t<=e+r},withinFraction:O,assignWhenNull:function(e,t){for(var r in t)N(e[r])||(e[r]=t[r])},defaultWhenNull:function(e){for(var r=e,n=0;n<(arguments.length<=1?0:arguments.length-1)-1;n++){var a=n+1<1||arguments.length<=n+1?void 0:arguments[n+1];if(n===(arguments.length<=1?0:arguments.length-1)-2)N(r[a])||(r[a]=n+1+1<1||arguments.length<=n+1+1?void 0:arguments[n+1+1]);else{if(!k(a))break;if("object"===t(r[a]))r=r[a];else{if(void 0!==r[a])break;r[a]={},r=r[a]}}}},sortNumber:function(e){return e.sort(arguments.length>1&&void 0!==arguments[1]&&arguments[1]?function(e,t){return e>t?-1:1}:function(e,t){return e<t?-1:1})},sortArray:function(e,t){for(var r=arguments.length,n=Array(r>2?r-2:0),a=2;a<r;a++)n[a-2]=arguments[a];return e.sort(function(e,r){for(var a=0;a<n.length;a++){var i=v(e,r,n[a],!0);if(i&&i[0]!==i[1])return t?i[0]>i[1]?1:-1:i[0]<i[1]?1:-1}return 0})},flatArray:function(e){for(var t=e;t.some(function(e){return Array.isArray(e)});)t=[].concat.apply([],_(t,function(e){return null!=e}));return t},partitionArray:T,spliceArray:L,filterArray:_,flatMap:P,filterMap:function(e,t,r){for(var n=[],a=0;a<e.length;a++)t(e[a],a,e)&&n.push(r(e[a],a,e));return n},replaceMap:function(e,t){for(var r=0;r<e.length;r++)e[r]=t(e[r],r,e);return e},objectMap:G,joinMap:j,captureMap:function(e,t,r){for(var n=0;n<e.length&&(!t(e[n],n,e)||!1!==r(e[n],n,e));n++);}}),W=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this._children=t||[]}var t,r,n;return t=e,(r=[{key:Symbol.iterator,value:function(){var e=this._children,t=0;return{next:function(){return t<e.length?{done:!1,value:e[t++]}:{done:!0,value:void 0}}}}},{key:"item",value:function(e,t){return void 0===e||void 0===t?void 0===e?this._children[this._children.length-1]:this._children[e]:e>=0&&e<this._children.length?(this._children[e]=t,t):void 0}},{key:"append",value:function(e){return this._children.push(e),this}},{key:"remove",value:function(e){for(var t=0;t<this._children.length;t++)if(this._children[t]===e)return this._children.splice(t,1);return[]}},{key:"contains",value:function(e){return-1!==this._children.indexOf(e)}},{key:"retain",value:function(e){return this._children=e,this}},{key:"duplicate",value:function(){return this._children.slice(0)}},{key:"clear",value:function(){return this._children.length=0,this}},{key:"each",value:function(e){for(var t=0;t<this._children.length;t++)e(this._children[t],t,this._children);return this}},{key:"find",value:function(e,t){if("string"==typeof e){for(var r=0;r<this._children.length;r++)if(this._children[r][e]===t)return this._children[r]}else for(var n=0;n<this._children.length;n++)if(e(this._children[n],n,this._children))return this._children[n]}},{key:"sort",value:function(e){return this._children.sort(e),this}},{key:"every",value:function(e){if(this.length>0){for(var t=0;t<this._children.length;t++)if(!e(this._children[t],t,this._children))return!1;return!0}return!1}},{key:"some",value:function(e){for(var t=0;t<this._children.length;t++)if(e(this._children[t],t,this._children))return!0;return!1}},{key:"filter",value:function(e){return _(this._children,e)}},{key:"partition",value:function(e){return T(this._children,e)}},{key:"splice",value:function(e,t){return L(this._children,e,t)}},{key:"map",value:function(e){return G(this._children,e)}},{key:"flatMap",value:function(e){return P(this._children,e)}},{key:"cascade",value:function(){function t(r){for(var n=[],a=Array.isArray(l=r.children),i=0,l=a?l:l[Symbol.iterator]();;){var u;if(a){if(i>=l.length)break;u=l[i++]}else{if((i=l.next()).done)break;u=i.value}var c=u;n.push(c),c instanceof e&&c.length&&n.push.apply(n,o(t(c)))}return n}return t(this)}},{key:"children",get:function(){return this._children}},{key:"length",get:function(){return this._children.length}}])&&a(t.prototype,r),n&&a(t,n),e}(),X="0123456789ABCDEF",U={Pink:{value:"#FFC0CB"},LightPink:{value:"#FFB6C1"},HotPink:{value:"#FF69B4"},DeepPink:{value:"#FF1493"},PaleVioletRed:{value:"#DB7093"},MediumVioletRed:{value:"#C71585"},LightSalmon:{value:"#FFA07A"},Salmon:{value:"#FA8072"},DarkSalmon:{value:"#E9967A"},LightCoral:{value:"#F08080"},IndianRed:{value:"#CD5C5C"},Crimson:{value:"#DC143C"},Firebrick:{value:"#B22222"},DarkRed:{value:"#8B0000"},Red:{value:"#FF0000"},OrangeRed:{value:"#FF4500"},Tomato:{value:"#FF6347"},Coral:{value:"#FF7F50"},Orange:{value:"#FFA500"},DarkOrange:{value:"#FF8C00"},Yellow:{value:"#FFFF00"},LightYellow:{value:"#FFFFE0"},LemonChiffon:{value:"#FFFACD"},LightGoldenrodYellow:{value:"#FAFAD2"},PapayaWhip:{value:"#FFEFD5"},Moccasin:{value:"#FFE4B5"},PeachPuff:{value:"#FFDAB9"},PaleGoldenrod:{value:"#EEE8AA"},Khaki:{value:"#F0E68C"},DarkKhaki:{value:"#BDB76B"},Gold:{value:"#FFD700"},Cornsilk:{value:"#FFF8DC"},BlanchedAlmond:{value:"#FFEBCD"},Bisque:{value:"#FFE4C4"},NavajoWhite:{value:"#FFDEAD"},Wheat:{value:"#F5DEB3"},Burlywood:{value:"#DEB887"},Tan:{value:"#D2B48C"},RosyBrown:{value:"#BC8F8F"},SandyBrown:{value:"#F4A460"},Goldenrod:{value:"#DAA520"},DarkGoldenrod:{value:"#B8860B"},Peru:{value:"#CD853F"},Chocolate:{value:"#D2691E"},SaddleBrown:{value:"#8B4513"},Sienna:{value:"#A0522D"},Brown:{value:"#A52A2A"},Maroon:{value:"#800000"},DarkOliveGreen:{value:"#556B2F"},Olive:{value:"#808000"},OliveDrab:{value:"#6B8E23"},YellowGreen:{value:"#9ACD32"},LimeGreen:{value:"#32CD32"},Lime:{value:"#00FF00"},LawnGreen:{value:"#7CFC00"},Chartreuse:{value:"#7FFF00"},GreenYellow:{value:"#ADFF2F"},SpringGreen:{value:"#00FF7F"},MediumSpringGreen:{value:"#00FA9A"},LightGreen:{value:"#90EE90"},PaleGreen:{value:"#98FB98"},DarkSeaGreen:{value:"#8FBC8F"},MediumAquamarine:{value:"#66CDAA"},MediumSeaGreen:{value:"#3CB371"},SeaGreen:{value:"#2E8B57"},ForestGreen:{value:"#228B22"},Green:{value:"#008000"},DarkGreen:{value:"#006400"},Aqua:{value:"#00FFFF"},Cyan:{value:"#00FFFF"},LightCyan:{value:"#E0FFFF"},PaleTurquoise:{value:"#AFEEEE"},Aquamarine:{value:"#7FFFD4"},Turquoise:{value:"#40E0D0"},DarkTurquoise:{value:"#00CED1"},MediumTurquoise:{value:"#48D1CC"},LightSeaGreen:{value:"#20B2AA"},CadetBlue:{value:"#5F9EA0"},DarkCyan:{value:"#008B8B"},Teal:{value:"#008080"},LightSteelBlue:{value:"#B0C4DE"},PowderBlue:{value:"#B0E0E6"},LightBlue:{value:"#ADD8E6"},SkyBlue:{value:"#87CEEB"},LightSkyBlue:{value:"#87CEFA"},DeepSkyBlue:{value:"#00BFFF"},DodgerBlue:{value:"#1E90FF"},Cornflower:{value:"#6495ED"},SteelBlue:{value:"#4682B4"},RoyalBlue:{value:"#4169E1"},Blue:{value:"#0000FF"},MediumBlue:{value:"#0000CD"},DarkBlue:{value:"#00008B"},Navy:{value:"#000080"},MidnightBlue:{value:"#191970"},Lavender:{value:"#E6E6FA"},Thistle:{value:"#D8BFD8"},Plum:{value:"#DDA0DD"},Violet:{value:"#EE82EE"},Orchid:{value:"#DA70D6"},Fuchsia:{value:"#FF00FF"},Magenta:{value:"#FF00FF"},MediumOrchid:{value:"#BA55D3"},MediumPurple:{value:"#9370DB"},BlueViolet:{value:"#8A2BE2"},DarkViolet:{value:"#9400D3"},DarkOrchid:{value:"#9932CC"},DarkMagenta:{value:"#8B008B"},Purple:{value:"#800080"},RebeccaPurple:{value:"#663399"},Indigo:{value:"#4B0082"},DarkSlateBlue:{value:"#483D8B"},SlateBlue:{value:"#6A5ACD"},MediumSlateBlue:{value:"#7B68EE"},White:{value:"#FFFFFF"},Snow:{value:"#FFFAFA"},Honeydew:{value:"#F0FFF0"},MintCream:{value:"#F5FFFA"},Azure:{value:"#F0FFFF"},AliceBlue:{value:"#F0F8FF"},GhostWhite:{value:"#F8F8FF"},WhiteSmoke:{value:"#F5F5F5"},Seashell:{value:"#FFF5EE"},Beige:{value:"#F5F5DC"},OldLace:{value:"#FDF5E6"},FloralWhite:{value:"#FFFAF0"},Ivory:{value:"#FFFFF0"},AntiqueWhite:{value:"#FAEBD7"},Linen:{value:"#FAF0E6"},LavenderBlush:{value:"#FFF0F5"},MistyRose:{value:"#FFE4E1"},Gainsboro:{value:"#DCDCDC"},LightGray:{value:"#D3D3D3"},Silver:{value:"#C0C0C0"},DarkGray:{value:"#A9A9A9"},Gray:{value:"#808080"},DimGray:{value:"#696969"},LightSlateGray:{value:"#778899"},SlateGray:{value:"#708090"},DarkSlateGray:{value:"#2F4F4F"},LightGrey:{value:"#D3D3D3"},DarkGrey:{value:"#A9A9A9"},Grey:{value:"#808080"},DimGrey:{value:"#696969"},LightSlateGrey:{value:"#778899"},SlateGrey:{value:"#708090"},DarkSlateGrey:{value:"#2F4F4F"},Black:{value:"#000000"}},q=/[A-Za-z\d]{3,}/,H=/rgba?\((\d+), (\d+), (\d+)(?:, ([\d.]+))?\)/,V=[];for(var $ in U){var Y=U[$];Y.name=$;var K=ne(Y.value);K&&(Y.rgba=K,Y.hsl=Z(Y.rgba),V.push(Y))}function Z(e){var t=e.r,r=void 0===t?0:t,n=e.g,a=void 0===n?0:n,i=e.b,o=void 0===i?0:i,l=Math.min(r/=255,a/=255,o/=255),u=Math.max(r,a,o),c=(u+l)/2,s=c,f=c;if(u===l)c=0,s=0;else{var v=u-l;switch(s=f>.5?v/(2-u-l):v/(u+l),u){case r:c=(a-o)/v+(a<o?6:0);break;case a:c=(o-r)/v+2;break;case o:c=(r-a)/v+4}c/=6}return{h:360*c,s:100*s,l:100*f}}function Q(e,t){if(e.hsl&&t.hsl){var r=e.hsl.h,n=t.hsl.h;return r===n&&(r=e.hsl.s)===(n=t.hsl.s)&&(r=e.hsl.l,n=t.hsl.l),r>=n?1:-1}return 0}function J(e){return"rgb".concat(e.a<255?"a":"","(").concat(e.r,", ").concat(e.g,", ").concat(e.b).concat(e.a<255?", ".concat((e.a/255).toPrecision(2)):"",")")}function ee(e){return parseFloat(e)<1?re(255*parseFloat(e)):"FF"}function te(e){for(var t in U)if(t.toLowerCase()===e.trim().toLowerCase())return U[t]}function re(){for(var e="",t=arguments.length,r=Array(t),n=0;n<t;n++)r[n]=arguments[n];for(var a=0;a<r.length;a++){var i=r[a],o="string"==typeof i?parseInt(i):i;if(isNaN(o))return"00";e+=X.charAt(((o=Math.max(0,Math.min(o,255)))-o%16)/16)+X.charAt(o%16)}return e}function ne(e){if(e=e.replace(/#/g,"").trim(),q.test(e)){var t=255;switch(e.length){case 4:t=parseInt(e.charAt(3).repeat(2),16);case 3:e=e.charAt(0).repeat(2)+e.charAt(1).repeat(2)+e.charAt(2).repeat(2);break;case 5:e+=e.charAt(4);break;default:e.length>=8&&(t=parseInt(e.substring(6,8),16)),e=e.substring(0,6)}if(6===e.length)return{r:parseInt(e.substring(0,2),16),g:parseInt(e.substring(2,4),16),b:parseInt(e.substring(4),16),a:t}}}function ae(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"1",r=arguments.length>2&&void 0!==arguments[2]&&arguments[2];if(e&&("transparent"!==e||r)){if(""===t.trim()&&(t="1"),"#"===e.charAt(0)){var n=ne(e);n&&(e=J(n))}else if("initial"===e)e=J({r:0,g:0,b:0,a:1});else if("transparent"===e)e=J({r:0,g:0,b:0,a:0});else if(!e.startsWith("rgb")){var a=te(e);a&&a.rgba&&(a.rgba.a=parseFloat(ee(t)),e=J(a.rgba))}var i=e.match(H);if(i&&i.length>=4&&(void 0===i[4]||parseFloat(i[4])>0||r)){void 0===i[4]&&(i[4]=parseFloat(t).toPrecision(2));var o=re(i[1])+re(i[2])+re(i[3]),l=ee(i[4]),u="#".concat(o+l),c=parseFloat(i[4]);return{valueRGB:"#".concat(o),valueRGBA:u,valueARGB:"#".concat(l+o),alpha:c,rgba:ne(u),opaque:c<1,visible:c>0}}}}V.sort(Q);var ie=Object.freeze({getColorByName:te,getColorByShade:function(e){var t=V.slice(0),r=t.findIndex(function(t){return t.value===e});if(-1!==r)return t[r];var n=ne(e);if(n){var a=Z(n);if(a)return t.push({name:"",value:"",hsl:a,rgba:{r:-1,g:-1,b:-1,a:1}}),t.sort(Q),r=t.findIndex(function(e){return""===e.name}),t[Math.min(r+1,t.length-1)]}},convertHex:re,convertRGBA:ne,parseRGBA:ae,reduceRGBA:function(e,t){var r=ne(e);if(r){var n=t<0?0:255;return r.r=Math.round((n-r.r)*(t=Math.abs(t)))+r.r,r.g=Math.round((n-r.g)*t)+r.g,r.b=Math.round((n-r.b)*t)+r.b,ae(J(r))}}}),oe=/((?:\d+%\s*,?\s*)+|from|to)\s*{\s*(.+?)\s*}/;function le(){return{top:0,left:0,right:0,bottom:0}}function ue(){return Object.assign({width:0,height:0},{top:0,left:0,right:0,bottom:0})}function ce(e){return{top:e.top,right:e.right,bottom:e.bottom,left:e.left,width:e.width,height:e.height}}function se(e){if(e){if(!(arguments.length>1&&void 0!==arguments[1])||arguments[1]){var t=be(e,"style");if(t)return t;var r=Ae(e);if(r&&r.plainText)return r.unsafe("styleMap")}if(me(e)){var n=getComputedStyle(e);return Fe(e,"style",n),n}return{}}return{display:"none"}}function fe(e,t,r,n){var a="";if(e)for(var i=e.parentElement;i&&(void 0===n||!n.includes(i.tagName))&&(("inherit"===(a=se(i)[t]||"")||r&&r.some(function(e){return-1!==a.indexOf(e)}))&&(a=""),""===a&&i!==document.body);)i=i.parentElement;return a}function ve(e,t){if(e){for(var r=arguments.length,n=Array(r>2?r-2:0),a=2;a<r;a++)n[a-2]=arguments[a];if("#"!==e.nodeName.charAt(0)&&n.includes(se(e)[t]))return!0;if(e.parentElement)return n.includes(se(e.parentElement)[t])}return!1}function he(e,r){var n="";if("object"===t(e.style)&&(n=e.style[r]),!n){var a=be(e,"styleMap");a&&(n=a[r])}return n||""}function ge(e,t){var r=arguments.length>2&&void 0!==arguments[2]&&arguments[2],n=Ae(e),a=p(t);return n&&n.cssInitial(a)||he(e,a)||de(e,t)||r&&se(e)[a]||""}function de(e,t){if(e){var r=e.attributes.getNamedItem(t);if(r)return r.value.trim()}return""}function pe(e){if(e&&"#text"===e.nodeName&&e.textContent){if(arguments.length>1&&void 0!==arguments[1]&&arguments[1]){for(var t=e.textContent,r=0;r<t.length;r++)switch(t.charCodeAt(r)){case 9:case 10:case 13:case 32:continue;default:return!0}return!1}return""!==e.textContent.trim()}return!1}function me(e){return!!e&&"object"===t(e.style)}function ye(e){return!(e.left<0&&e.top<0&&Math.abs(e.left)>=e.width&&Math.abs(e.top)>=e.height)}function Fe(e,t,r){e["__".concat(t)]=r}function be(e,t){return e["__".concat(t)]||void 0}function Ae(e){return k(e.className)&&e.className.startsWith("squared")?void 0:be(e,"node")}var Ee=Object.freeze({ELEMENT_BLOCK:["ADDRESS","ARTICLE","ASIDE","BLOCKQUOTE","CANVAS","DD","DIV","DL","DT","FIELDSET","FIGCAPTION","FIGURE","FOOTER","FORM","H1","H2","H3","H4","H5","H6","HEADER","LI","MAIN","NAV","OL","OUTPUT","P","PRE","SECTION","TFOOT","TH","THEAD","TR","UL","VIDEO"],ELEMENT_INLINE:["A","ABBR","ACRONYM","B","BDO","BIG","BR","BUTTON","CITE","CODE","DFN","EM","I","IFRAME","IMG","INPUT","KBD","LABEL","MAP","OBJECT","Q","S","SAMP","SCRIPT","SELECT","SMALL","SPAN","STRIKE","STRONG","SUB","SUP","TEXTAREA","TIME","TT","U","VAR","PLAINTEXT"],isUserAgent:function(e){if("string"==typeof e){var t=e.toUpperCase();e=0,-1!==t.indexOf("CHROME")&&(e|=2),-1!==t.indexOf("SAFARI")&&(e|=4),-1!==t.indexOf("FIREFOX")&&(e|=16),-1!==t.indexOf("EDGE")&&(e|=8)}var r=navigator.userAgent;return x(e,-1!==r.indexOf("Safari")&&-1===r.indexOf("Chrome")?4:-1!==r.indexOf("Firefox")?16:-1!==r.indexOf("Edge")?8:2)},getDeviceDPI:function(){return 96*window.devicePixelRatio},getKeyframeRules:function(){var e=new Map;e:for(var t=0;t<document.styleSheets.length;t++){var r=document.styleSheets[t];if(r.cssRules)for(var n=0;n<r.cssRules.length;n++)try{var a=r.cssRules[n];if(7===a.type){for(var o={},l=0;l<a.cssRules.length;l++){var u=oe.exec(a.cssRules[l].cssText);if(u){var c=(a.cssRules[l].keyText||u[1].trim()).split(","),s=Array.isArray(c),f=0;for(c=s?c:c[Symbol.iterator]();;){var v;if(s){if(f>=c.length)break;v=c[f++]}else{if((f=c.next()).done)break;v=f.value}var h=v;switch(h=h.trim()){case"from":h="0%";break;case"to":h="100%"}o[h]={};var g=u[2].split(";"),d=Array.isArray(g),p=0;for(g=d?g:g[Symbol.iterator]();;){var m;if(d){if(p>=g.length)break;m=g[p++]}else{if((p=g.next()).done)break;m=p.value}var y=i(m.split(":"),2),F=y[1];F&&(o[h][y[0].trim()]=F.trim())}}}}e.set(a.name,o)}}catch(e){break e}}return e},checkStyleAttribute:function(e,t,r,n,a){if(void 0===n&&(n=se(e)),"inherit"===r&&(r=fe(e.parentElement,t)),"initial"!==r){if(r!==n[t])switch(t){case"backgroundColor":case"borderTopColor":case"borderRightColor":case"borderBottomColor":case"borderLeftColor":case"color":case"fontSize":case"fontWeight":return n[t]||r;case"width":case"height":case"minWidth":case"maxWidth":case"minHeight":case"maxHeight":case"lineHeight":case"verticalAlign":case"textIndent":case"columnGap":case"top":case"right":case"bottom":case"left":case"marginTop":case"marginRight":case"marginBottom":case"marginLeft":case"paddingTop":case"paddingRight":case"paddingBottom":case"paddingLeft":return/^[A-Za-z\-]+$/.test(r)||D(r)?r:F(r,a)}return r}return""},getDataSet:function(e,t){var r={};if(me(e))for(var n in t=p(t,"\\."),e.dataset)n.length>t.length&&n.startsWith(t)&&(r[d(n.substring(t.length),!1)]=e.dataset[n]);return r},newBoxRect:le,newRectDimension:ue,newBoxModel:function(){return{marginTop:0,marginRight:0,marginBottom:0,marginLeft:0,paddingTop:0,paddingRight:0,paddingBottom:0,paddingLeft:0}},getDOMRect:function(e){var t=e.getBoundingClientRect();return t.x=t.left,t.y=t.top,t},createElement:function(e){var t=document.createElement(arguments.length>1&&void 0!==arguments[1]&&arguments[1]?"div":"span"),r=t.style;return r.position="static",r.margin="0px",r.padding="0px",r.border="none",r.cssFloat="none",r.clear="none",r.display="none",t.className="__css.placeholder",e&&e.appendChild(t),t},removeElementsByClassName:function(e){for(var t=document.getElementsByClassName(e),r=0;r<t.length;r++){var n=t[r];n.parentElement&&n.parentElement.removeChild(n)}},getRangeClientRect:function(e){var t=document.createRange();t.selectNodeContents(e);for(var r=t.getClientRects(),n=[],a=0;a<r.length;a++){var i=r.item(a);0===Math.round(i.width)&&O(i.left,i.right)||n.push(i)}var o=ue(),l=0;if(n.length){o=ce(n[0]);for(var u=new Set([o.top]),c=new Set([o.bottom]),s=o.top,f=o.bottom,v=1;v<n.length;v++){var h=n[v];u.add(Math.round(h.top)),c.add(Math.round(h.bottom)),s=Math.min(s,h.top),f=Math.min(f,h.bottom),o.width+=h.width,o.right=Math.max(h.right,o.right),o.height=Math.max(h.height,o.height)}u.size>1&&c.size>1&&(o.top=s,o.bottom=f,n[n.length-1].top>=n[0].bottom&&e.textContent&&(""!==e.textContent.trim()||/^\s*\n/.test(e.textContent))&&(l=n.length-1))}return Object.assign({},o,{multiline:l})},assignBounds:ce,getStyle:se,getFontSize:function(e){return parseInt(se(e).fontSize||"16px")},cssResolveUrl:function(e){var t=e.match(g.URL);return t?M(t[1]):""},cssInheritStyle:fe,cssParent:ve,cssFromParent:function(e,t){if(me(e)&&e.parentElement){var r=Ae(e),n=se(e);if(r&&n)return n[t]===se(e.parentElement)[t]&&!r.cssInitial(t)}return!1},cssInline:he,cssAttribute:ge,cssInheritAttribute:function(e,t){for(var r=e,n="";r&&(""===(n=ge(r,t))||"inherit"===n);)r=r.parentElement;return n},getNamedItem:de,getBackgroundPosition:function(e,t,r){var n=arguments.length>3&&void 0!==arguments[3]&&arguments[3],a=arguments.length>4&&void 0!==arguments[4]&&arguments[4],i={top:0,left:0,right:0,bottom:0,horizontal:"left",vertical:"top",originalX:"",originalY:""},o="center"===e?["center","center"]:e.split(" ");if(4===o.length)for(var l=0;l<o.length;l++){var u=o[l];switch(l){case 0:i.horizontal=u;break;case 2:i.vertical=u;break;case 1:case 3:var c=b(u,1===l?t.width:t.height,r,a);1===l?n?"right"===i.horizontal?(i.originalX=D(u)?E(100-parseInt(u)):A(t.width-parseInt(F(u,r))),i.right=c,i.left=a?1-c:t.width-c):(i.left=c,i.originalX=u):"center"!==i.horizontal&&(i[i.horizontal]=c):n?"bottom"===i.vertical?(i.originalY=D(u)?E(100-parseInt(u)):A(t.height-parseInt(F(u,r))),i.bottom=c,i.top=a?1-c:t.height-c):(i.top=c,i.originalY=u):"center"!==i.vertical&&(i[i.vertical]=c)}}else if(2===o.length)for(var s=0;s<o.length;s++){var f=o[s],v=void 0,h=void 0,g=void 0;0===s?(v=t.width,h="left",g="originalX"):(v=t.height,h="top",g="originalY");var d=b(f,v,r,a);if(D(f))i[h]=d,i[g]=f;else if(/^[a-z]+$/.test(f)){if(i[0===s?"horizontal":"vertical"]=f,n)switch(f){case"left":case"top":i[g]="0%";break;case"right":case"bottom":i[h]=a?1:v,i[g]="100%";break;case"center":i[h]=a?.5:Math.round(v/2),i[g]="50%"}}else i[h]=d,i[g]=f}return i},getFirstChildElement:function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(e)for(var r=0;r<e.childNodes.length;r++){var n=Ae(e.childNodes[r]);if(n&&(!n.excluded||t&&n.lineBreak))return n.element}return null},getLastChildElement:function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(e)for(var r=e.childNodes.length-1;r>=0;r--){var n=Ae(e.childNodes[r]);if(n&&n.naturalElement&&(!n.excluded||t&&n.lineBreak))return n.element}return null},hasFreeFormText:function(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];return function e(r){for(var n=0;n<r.length;n++){var a=r[n];if("#text"===a.nodeName){if(pe(a,t)||ve(a,"whiteSpace","pre","pre-wrap")&&a.textContent&&""!==a.textContent)return!0}else if(e(a.childNodes))return!0}return!1}("#text"===e.nodeName?[e]:e.childNodes)},isPlainText:pe,hasLineBreak:function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(e){var r=e.textContent||"";if(arguments.length>2&&void 0!==arguments[2]&&arguments[2]&&(r=r.trim()),e.children){for(var n=0;n<e.children.length;n++)if("BR"===e.children[n].tagName)return!0}else if(!t&&/\n/.test(r)){var a=Ae(e),i=a?a.css("whiteSpace"):se(e).whiteSpace||"";return["pre","pre-wrap"].includes(i)||"#text"===e.nodeName&&ve(e,"whiteSpace","pre","pre-wrap")}}return!1},isLineBreak:function(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];if(e){var r=Ae(e);if(r)return"BR"===r.tagName||t&&r.excluded&&r.blockStatic}return!1},getElementsBetween:function(e,t){var r=arguments.length>2&&void 0!==arguments[2]&&arguments[2];if(!e||e.parentElement===t.parentElement){var n=t.parentElement;if(n){for(var a=e?-1:0,i=-1,o=Array.from(n.childNodes),l=0;l<o.length;l++)o[l]===e&&(a=l),o[l]===t&&(i=l);if(-1!==a&&-1!==i&&a!==i){var u=o.slice(Math.min(a,i)+1,Math.max(a,i));return L(u,r?function(e){return"#comment"===e.nodeName}:function(e){return"#"===e.nodeName.charAt(0)&&!pe(e)}),u}}}return[]},getPreviousElementSibling:function(e){if(e)for(e=e.previousSibling;e;){var t=Ae(e);if(t&&(!t.excluded||t.lineBreak))return t.element;e=e.previousSibling}return null},getNextElementSibling:function(e){if(e)for(e=e.nextSibling;e;){var t=Ae(e);if(t&&(!t.excluded||t.lineBreak))return t.element;e=e.nextSibling}return null},hasComputedStyle:me,hasVisibleRect:function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],r=e.getBoundingClientRect();return 0!==r.width&&0!==r.height&&(!t||ye(r))},withinViewport:ye,setElementCache:Fe,getElementCache:be,deleteElementCache:function(e){for(var t=arguments.length,r=Array(t>1?t-1:0),n=1;n<t;n++)r[n-1]=arguments[n];for(var a=0;a<r.length;a++)delete e["__".concat(r[a])]},getElementAsNode:Ae});function xe(e){return e.length?Math.min.apply(null,e):1/0}function Ce(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:8;return e.toPrecision(r)===t.toPrecision(r)}function ke(e){if(e!==Math.floor(e)){var t=/^(\d+)\.(\d*?)(0{5,}|9{5,})\d*$/.exec(""+e);if(t)return""===t[2]?Math.round(e):parseFloat(e.toPrecision(("0"!==t[1]?t[1].length:0)+t[2].length))}return e}function De(e){return e*Math.PI/180}var Be=Object.freeze({minArray:xe,maxArray:function(e){return e.length?Math.max.apply(null,e):-1/0},distanceFromX:function(e,t){return e*Math.sin(De(t))},distanceFromY:function(e,t){return e*Math.cos(De(t))*-1},isEqual:Ce,moreEqual:function(e,t){return e>t||Ce(e,t,arguments.length>2&&void 0!==arguments[2]?arguments[2]:8)},lessEqual:function(e,t){return e<t||Ce(e,t,arguments.length>2&&void 0!==arguments[2]?arguments[2]:8)},truncate:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:3;return e===Math.floor(e)?""+e:e.toPrecision(t).replace(/\.?0+$/,"")},truncateFraction:ke,truncateString:function(e){for(var t,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:3,n=RegExp("(\\d+\\.\\d{".concat(r,"})(\\d)\\d*"),"g"),a=e;null!==(t=n.exec(e));)parseInt(t[2])>=5&&(t[1]=""+ke(parseFloat(t[1])+1/Math.pow(10,r))),a=a.replace(t[0],t[1]);return a},convertRadian:De,offsetAngle:function(e,t){var r=t.y-e.y,n=180*Math.atan2(r,t.x-e.x)/Math.PI;return n<0?270+(r<0?n:Math.abs(n))%360:(n+90)%360},clampRange:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1;return e<t?e=t:e>r&&(e=r),e},nextMultiple:function(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;if(e.length>1){var n=xe(e);if(t&&t.length===e.length)for(var a=0;a<t.length;a++)r=Math.max(r,t[a]+e[a]);else t=void 0,r=Math.max(r,n);for(var i=0;i<r;)i+=n;for(var o=t?t[0]:0,l=!1;!l;)for(var u=o+i,c=1;c<e.length;c++){if(u%(e[c]+(t?t[c]:0))!=0){l=!1,i+=n;break}l=!0}return o+i}return e[0]}});function Se(e,t){for(var r in e)t=t.replace(RegExp("\\t*<<".concat(r,">>[\\w\\W]*<<").concat(r,">>")),"{%".concat(r,"}"));return t}var we="__ROOT__";function Me(e){return"{".concat((arguments.length>1&&void 0!==arguments[1]?arguments[1]:":")+""+e,"}")}function Ie(e){for(var t,r=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"\t",a=[],i=/\s*(<(\/)?([?\w]+)[^>]*>)\n?([^<]*)/g;null!==(t=i.exec(e));)a.push({tag:t[1],closing:!!t[2],tagName:t[3],value:""===t[4].trim()?"":t[4]});for(var o=/\/>\n*$/,l="",u=-1,c=0;c<a.length;c++){var s=a[c],f=u;if(c>0){if(s.closing)u--;else if(f++,!o.exec(s.tag))if(r&&""===s.value.trim()){var v=a[c+1];v&&v.closing&&v.tagName===s.tagName?(s.tag=s.tag.replace(/\s*>$/," />"),c++):u++}else u++;var h=!0,g=s.tag.trim().split("\n"),d=Array.isArray(g),p=0;for(g=d?g:g[Symbol.iterator]();;){var m;if(d){if(p>=g.length)break;m=g[p++]}else{if((p=g.next()).done)break;m=p.value}var y=m,F=f+(h?0:1);l+=(F>0?n.repeat(F):"")+y.trim()+"\n",h=!1}}else l+=s.tag+"\n";l+=s.value}return l.trim()}var Re,Ne,Oe=Object.freeze({formatPlaceholder:Me,replacePlaceholder:function(e,t,r){var n=arguments.length>3&&void 0!==arguments[3]&&arguments[3],a="number"==typeof t?Me(t):t;return e.replace(a,(n?a:"")+r+"\n"+(n?"":a))},pushIndent:function(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"\t";if(""!==e){var n=RegExp("^".concat(r.replace("\\","\\\\"),"+"));return j(e.split("\n"),function(e){var a=n.exec(e);return a?e.replace(a[0],r.repeat(t+a[0].length)):e})}return e},replaceIndent:function(e,t,r){if(t>=0){var n=-1;return j(e.split("\n"),function(e){var a=r.exec(e);return a?(-1===n&&(n=a[2].length),a[1]+"\t".repeat(t+(a[2].length-n))+a[3]):e})}return e},replaceTab:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:4;return t>0?arguments.length>2&&void 0!==arguments[2]&&arguments[2]?j(e.split("\n"),function(e){var r=e.match(/^(\t+)(.*)$/);return r?" ".repeat(t*r[1].length)+r[2]:e}):e.replace(/\t/g," ".repeat(t)):e},replaceEntity:function(e){return e.replace(/&#(\d+);/g,function(e,t){return String.fromCharCode(parseInt(t))}).replace(/\u00A0/g,"&#160;").replace(/\u2002/g,"&#8194;").replace(/\u2003/g,"&#8195;").replace(/\u2009/g,"&#8201;").replace(/\u200C/g,"&#8204;").replace(/\u200D/g,"&#8205;").replace(/\u200E/g,"&#8206;").replace(/\u200F/g,"&#8207;")},replaceCharacter:function(e){return e.replace(/&nbsp;/g,"&#160;").replace(/&(?!#?[A-Za-z0-9]{2,};)/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/'/g,"&apos;").replace(/"/g,"&quot;")},parseTemplate:function(e){var t={};return t[we]=Se(function e(r){for(var n,a={},i=/(\t*<<(\w+)>>)\n*[\w\W]*\n*\1/g;null!==(n=i.exec(r));){var o=n[0].replace(RegExp("^".concat(n[1],"\\n")),"").replace(RegExp("".concat(n[1],"$")),"");a[n[2]]=Se(e(o),o)}return Object.assign(t,a),a}(e),e),t},createTemplate:function e(r,n){var a=arguments.length>2&&void 0!==arguments[2]&&arguments[2],i=arguments.length>3?arguments[3]:void 0;void 0===i&&(i=we);var o=r[i]||"",l=function(l){if(null!=n[l]){var u=n[l],c="",s="";if(Array.isArray(u))if(s="%",Array.isArray(u[0])){var f=function(e){return"((\\t*##".concat(l,"-").concat(e,"##\\s*\\n)([\\w\\W]*?\\s*\\n)(\\t*##").concat(l,"-").concat(e,"##\\s*\\n))")},v=RegExp(f("start")+"([\\w\\W]*?)"+f("end")).exec(o);if(v){for(var h=u[0].length,g=Object.assign({},r),d="",p="",m=0;m<h;m++){var y="".concat(i,"_").concat(l,"_").concat(m);g[y]=v[3],d+=e(g,u[0][m],a,y),p=v[8]+p}o=o.replace(v[1],d).replace(v[6],p)}else c=!1}else if(0===u.length||"object"!==t(u[0]))c=!1;else{for(var F=0;F<u.length;F++)c+=e(r,u[F],a,""+l);c=""!==c&&R(c,"\n")}else s="[&~]",c="boolean"!=typeof u&&""+u;if(c)""!==c&&(o=o.replace(RegExp("{".concat(s+l,"}")),c));else{if(RegExp("{&".concat(l,"}")).test(o))return{v:""};"%"===s&&(o=o.replace(RegExp("[ \\t]*{%".concat(l,"}\\n*")),""))}}};for(var u in n){var c=l(u);if("object"===t(c))return c.v}return i===we&&(o=o.replace(/\n*\t*{%\w+}\n+/g,"\n").replace(/\n\n/g,"\n").trim(),a&&(o=Ie(o))),o.replace(/\s*((\w+:)?\w+="[^"]*)?{~\w+}"?/g,"")},formatTemplate:Ie});e.settings={},e.system={};var Te=new Set,Le=new Map;function _e(e){if(Re){if(e instanceof squared.base.Extension)return Re.extensionManager.include(e);if("string"==typeof e){e=e.trim();var t=Re.builtInExtensions[e]||Ge(e);if(t)return Re.extensionManager.include(t)}}return!1}function Pe(r,n){if("object"===t(n)){if(r instanceof squared.base.Extension)return Object.assign(r.options,n),!0;if("string"==typeof r&&Re){r=r.trim();var a=Re.extensionManager.retrieve(r)||Array.from(Te).find(function(e){return e.name===r});if(a)return Object.assign(a.options,n),!0;if(Le.set(r,n),e.settings.handleExtensionsAsync)return!0}}return!1}function Ge(e){return Re&&Re.extensionManager.retrieve(e)}function je(){Re&&Re.reset()}var ze={base:{Container:W},color:ie,dom:Ee,math:Be,util:z,xml:Oe};e.setFramework=function(t){if(Ne!==t){var r=arguments.length>1&&void 0!==arguments[1]&&arguments[1]?t.cached():t.create();if(void 0===Ne&&Object.assign(r.userSettings,e.settings),e.settings=r.userSettings,(Re=r.application).userSettings=e.settings,Array.isArray(e.settings.builtInExtensions)){for(var n=new Set,a=Array.isArray(o=e.settings.builtInExtensions),i=0,o=a?o:o[Symbol.iterator]();;){var l;if(a){if(i>=o.length)break;l=o[i++]}else{if((i=o.next()).done)break;l=i.value}var u=l;if(u=u.trim(),Re.builtInExtensions[u])n.add(Re.builtInExtensions[u]);else for(var c in Re.builtInExtensions)c.startsWith("".concat(u,"."))&&n.add(Re.builtInExtensions[c])}for(var s=Array.isArray(v=n),f=0,v=s?v:v[Symbol.iterator]();;){var h;if(s){if(f>=v.length)break;h=v[f++]}else{if((f=v.next()).done)break;h=f.value}Re.extensionManager.include(h)}}Ne=t,e.system=t.system}je()},e.parseDocument=function t(){for(var r=arguments.length,n=Array(r),a=0;a<r;a++)n[a]=arguments[a];if(Re&&!Re.closed){var o;if(e.settings.handleExtensionsAsync){for(var l=Array.isArray(c=Te),u=0,c=l?c:c[Symbol.iterator]();;){var s;if(l){if(u>=c.length)break;s=c[u++]}else{if((u=c.next()).done)break;s=u.value}Re.extensionManager.include(s)}var f=Le.entries(),v=Array.isArray(f),h=0;for(f=v?f:f[Symbol.iterator]();;){var g;if(v){if(h>=f.length)break;g=f[h++]}else{if((h=f.next()).done)break;g=h.value}var d=i(g,2);Pe(d[0],d[1])}Te.clear(),Le.clear()}return(o=Re).parseDocument.apply(o,n)}return{then:function(e){Re?Re.closed&&confirm("ERROR: Document is closed. Reset and rerun?")&&(Re.reset(),t.call.apply(t,[null].concat(n)).then(e)):alert("ERROR: Framework not installed.")}}},e.include=_e,e.includeAsync=function(t){return!!_e(t)||!!(t instanceof squared.base.Extension&&(Te.add(t),e.settings.handleExtensionsAsync))},e.exclude=function(e){if(Re){if(e instanceof squared.base.Extension)return Te.has(e)?(Te.delete(e),Re.extensionManager.exclude(e),!0):Re.extensionManager.exclude(e);if("string"==typeof e){e=e.trim();var t=Re.extensionManager.retrieve(e);if(t)return Re.extensionManager.exclude(t)}}return!1},e.configure=Pe,e.apply=function(e,r){return e instanceof squared.base.Extension?_e(e):"string"==typeof e&&(e=e.trim(),"object"===t(r)?Pe(e,r):Ge(e))},e.retrieve=Ge,e.ready=function(){return!!Re&&!Re.initialized&&!Re.closed},e.close=function(){Re&&!Re.initialized&&Re.size&&Re.finalize()},e.reset=je,e.saveAllToDisk=function(){Re&&!Re.initialized&&Re.size&&(Re.closed||Re.finalize(),Re.saveAllToDisk())},e.toString=function(){return Re?""+Re:""},e.lib=ze,Object.defineProperty(e,"__esModule",{value:!0})});
!function(e,r){"object"==typeof exports&&"undefined"!=typeof module?r(exports):"function"==typeof define&&define.amd?define(["exports"],r):r((e=e||self).squared={})}(this,function(e){"use strict";function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function t(e){this.wrapped=e}function n(e){var r,n;function a(r,n){try{var i=e[r](n),o=i.value,s=o instanceof t;Promise.resolve(s?o.wrapped:o).then(function(e){s?a("next",e):l(i.done?"return":"normal",e)},function(e){a("throw",e)})}catch(e){l("throw",e)}}function l(e,t){switch(e){case"return":r.resolve({value:t,done:!0});break;case"throw":r.reject(t);break;default:r.resolve({value:t,done:!1})}(r=r.next)?a(r.key,r.arg):n=null}this._invoke=function(e,t){return new Promise(function(l,i){var o={key:e,arg:t,resolve:l,reject:i,next:null};n?n=n.next=o:(r=n=o,a(e,t))})},"function"!=typeof e.return&&(this.return=void 0)}function a(e,r){for(var t=0;t<r.length;t++){var n=r[t];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}"function"==typeof Symbol&&Symbol.asyncIterator&&(n.prototype[Symbol.asyncIterator]=function(){return this}),n.prototype.next=function(e){return this._invoke("next",e)},n.prototype.throw=function(e){return this._invoke("throw",e)},n.prototype.return=function(e){return this._invoke("return",e)};function l(e,r){return i(e)||function(e,r){var t=[],n=!0,a=!1,l=void 0;try{for(var i,o=e[Symbol.iterator]();!(n=(i=o.next()).done)&&(t.push(i.value),!r||t.length!==r);n=!0);}catch(e){a=!0,l=e}finally{try{n||null==o.return||o.return()}finally{if(a)throw l}}return t}(e,r)||o()}function i(e){if(Array.isArray(e))return e}function o(){throw new TypeError("Invalid attempt to destructure non-iterable instance")}var s="ABCDEFGHIJKLMNOPQRSTUVWXYZ",u=["","C","CC","CCC","CD","D","DC","DCC","DCCC","CM","","X","XX","XXX","XL","L","LX","LXX","LXXX","XC","","I","II","III","IV","V","VI","VII","VIII","IX"],h=/([a-z][A-Z])/g,c=/[^\w]+/g,g=/[^a-zA-Z\d]+/g,f=/(\s+[+\-]\s+|\s*[*\/]\s*)/;function v(e,r,t,n){for(var a=t.split("."),l=e,i=r,o=Array.isArray(u=a),s=0,u=o?u:u[Symbol.iterator]();;){var h;if(o){if(s>=u.length)break;h=u[s++]}else{if((s=u.next()).done)break;h=s.value}if(void 0===l[h]||void 0===i[h])return(void 0!==l[h]||void 0!==i[h])&&(void 0!==l[h]?[1,0]:[0,1]);l=l[h],i=i[h]}if(n){var c=parseFloat(l),g=parseFloat(i);if(!isNaN(c)&&!isNaN(g))return[c,g];if(!isNaN(c))return[1,0];if(!isNaN(g))return[0,1]}return[l,i]}var b={URL:'url\\("?(.+?)"?\\)',DECIMAL:"-?\\d+(?:\\.\\d+)?",ZERO_ONE:"0(?:\\.\\d+)?|1(?:\\.0+)?",PERCENT:"\\d+(\\.\\d+)?%",CALC:"calc(\\(.+\\))",VAR:"var\\((--[A-Za-z0-9\\-]+)\\)"};b.UNIT="(".concat(b.DECIMAL,")(px|em|ch|pc|pt|vw|vh|vmin|vmax|mm|cm|in)"),b.DEGREE="(".concat(b.DECIMAL,")(deg|rad|turn|grad)"),b.LENGTH="(".concat(b.DECIMAL,"(?:[a-z]{2,}|%)?)");var d={UNIT:RegExp("^".concat(b.UNIT,"$")),DECIMAL:RegExp("^".concat(b.DECIMAL,"$")),PERCENT:RegExp("^".concat(b.PERCENT,"$")),CALC:RegExp("^".concat(b.CALC,"$")),URL:RegExp(b.URL),URI:/^[A-Za-z]+:\/\//,SEPARATOR:/\s*,\s*/,ATTRIBUTE:/([^\s]+)="([^"]+)"/,CUSTOMPROPERTY:/^(?:var|calc)\(.+\)$/,PLACEHOLDER:/{(\d+)}/};function m(){return 96*window.devicePixelRatio}function p(e){return""!==e?!(arguments.length>1&&void 0!==arguments[1])||arguments[1]?e.charAt(0).toUpperCase()+e.substring(1).toLowerCase():e.charAt(0).toLowerCase()+e.substring(1):e}function y(e){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"-",t=e.replace(RegExp("^".concat(r,"+")),"").match(RegExp("(".concat(r,"[a-z])"),"g"));if(t)for(var n=Array.isArray(l=t),a=0,l=n?l:l[Symbol.iterator]();;){var i;if(n){if(a>=l.length)break;i=l[a++]}else{if((a=l.next()).done)break;i=a.value}e=e.replace(i,i[1].toUpperCase())}return e}function A(e){return e&&parseFloat(e)||0}function E(e,r){return e?(e=e.trim()).endsWith("%")||"auto"===e?e:"".concat(C(e,r),"px"):"0px"}function F(e,r,t){return S(e)?Math.round(r*(A(e)/100)):C(e,t)}function x(e){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,t=arguments.length>2?arguments[2]:void 0;"("===(e=e.trim()).charAt(0)&&")"===e.charAt(e.length-1)||(e="(".concat(e,")"));for(var n=[],a=[],l=0,i=0;i<e.length;i++)switch(e.charAt(i)){case"(":l++,n[i]=!0;break;case")":a.push(i)}if(l===a.length)for(var o=[],s=0;;)for(var u=0;u<a.length;u++){for(var h=a[u]-1,c=!1;h>=0;h--){if(n[h]){c=!0,n[h]=!1;break}if(a.includes(h))break}if(c){var g=[],v=[],b=e.substring(h+1,a[u]).split(f),m=Array.isArray(b),p=0;for(b=m?b:b[Symbol.iterator]();;){var y;if(m){if(p>=b.length)break;y=b[p++]}else{if((p=b.next()).done)break;y=p.value}var A=y;switch(A=A.trim()){case"+":case"-":case"*":case"/":v.push(A);break;default:var E=d.PLACEHOLDER.exec(A);if(E)g.push(o[parseInt(E[1])]);else if(D(A))g.push(C(A,t));else if(S(A))g.push(parseFloat(A)/100*r);else{if(!I(A))return;g.push(parseFloat(A))}}}if(g.length!==v.length+1)return;for(var F=0;F<v.length;F++)if("/"===v[F]){if(0===Math.abs(g[F+1]))return;g.splice(F,2,g[F]/g[F+1]),v.splice(F--,1)}for(var x=0;x<v.length;x++)"*"===v[x]&&(g.splice(x,2,g[x]*g[x+1]),v.splice(x--,1));for(var k=0;k<v.length;k++)g.splice(k,2,g[k]+("-"===v[k]?-g[k+1]:g[k+1])),v.splice(k--,1);if(1!==g.length)return;if(1===a.length)return g[0];o[s]=g[0];var w="{".concat(s++,"}"),R=a[u]+1;e=e.substring(0,h)+"".concat(w+" ".repeat(R-(h+w.length)))+e.substring(R),a.splice(u--,1)}}}function C(e,r){if(e){var t=e.match(d.UNIT);if(t){var n=parseFloat(t[1]);switch(t[2]){case"px":return n;case"em":case"ch":n*=r||16;break;case"pc":n*=12;case"pt":n*=4/3;break;case"mm":n/=10;case"cm":n/=2.54;case"in":n*=m();break;case"vw":n*=window.innerWidth/100;break;case"vh":n*=window.innerHeight/100;break;case"vmin":n*=Math.min(window.innerWidth,window.innerHeight)/100;break;case"vmax":n*=Math.max(window.innerWidth,window.innerHeight)/100}return n}if(I(e))return parseFloat(e)}return 0}function k(e){return"string"==typeof e&&(e=parseFloat(e)),isNaN(e)?"0px":"".concat(Math.round(e),"px")}function w(e){var r=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];return"string"==typeof e&&(e=parseFloat(e)),isNaN(e)?"0%":"".concat(r?Math.round(e):e,"%")}function R(e,r){return(e&r)===r}function I(e){return""!==e&&d.DECIMAL.test(e.trim())}function M(e){return"string"==typeof e&&""!==e.trim()}function D(e){return d.UNIT.test(e)}function S(e){return d.PERCENT.test(e)}function B(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],a=Array.isArray(i=e),l=0,i=a?i:i[Symbol.iterator]();;){var o;if(a){if(l>=i.length)break;o=i[l++]}else{if((l=i.next()).done)break;o=l.value}var s=o;Array.isArray(s)?t.push(B(s,[],n)):n&&"object"===r(s)?t.push(O(s,{},!0)):t.push(s)}return t}function O(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];for(var a in e){var l=e[a];t[a]=Array.isArray(l)?n?B(l,[],!0):l:l&&"object"===r(l)?O(l,{},n):l}return t}function N(e,t,n){var a,l=!1;if(e&&"object"===r(e)){a=e;var i=t.split("."),o=0;do{a=a[i[o]]}while(null!=a&&++o<i.length&&"object"===r(a));l=o===i.length&&null!=a}switch(n){case"object":return l?a:null;case"number":return a=parseFloat(a),l&&!isNaN(a)?a:0;case"boolean":return l&&!0===a;default:return l?""+a:""}}function T(e){if(!d.URI.test(e)){var r=location.pathname.split("/");if(r.pop(),"/"===e.charAt(0))e=location.origin+e;else if(e.startsWith("../")){var t=[],n=0,a=e.split("/"),l=Array.isArray(a),i=0;for(a=l?a:a[Symbol.iterator]();;){var o;if(l){if(i>=a.length)break;o=a[i++]}else{if((i=a.next()).done)break;o=i.value}".."===o?n++:t.push(o)}r=H(r.slice(0,Math.max(r.length-n,0)),t),e=location.origin+r.join("/")}else e="".concat(location.origin+r.join("/"),"/").concat(e);return e}return""}function L(e,r){return e.replace(RegExp("^".concat(r,"+")),"")}function _(e,r){return e.replace(RegExp("".concat(r,"+$")),"")}function P(e){return null!=e&&""!==(""+e).trim()}function j(e,r){var t=arguments.length>2&&void 0!==arguments[2]?arguments[2]:.5;return r>=e-t&&r<=e+t}function z(e,r){for(var t=[],n=[],a=0;a<e.length;a++){var l=e[a];r(l,a,e)?t.push(l):n.push(l)}return[t,n]}function U(e,r,t){for(var n=0;n<e.length;n++)r(e[n],n,e)&&(t&&t(e[n],n,e),e.splice(n--,1));return e}function X(e,r){for(var t=[],n=0;n<e.length;n++)r(e[n],n,e)&&t.push(e[n]);return t}function H(e,r){for(var t=Array.isArray(a=r),n=0,a=t?a:a[Symbol.iterator]();;){var l;if(t){if(n>=a.length)break;l=a[n++]}else{if((n=a.next()).done)break;l=n.value}e.push(l)}return e}function q(e,r){for(var t=[],n=0;n<e.length;n++){var a=r(e[n],n,e);P(a)&&t.push(a)}return t}function G(e,r){for(var t=[],n=0;n<e.length;n++)t[n]=r(e[n],n,e);return t}function V(e,r){for(var t=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"\n",n="",a=0;a<e.length;a++){var l=r(e[a],a,e);""!==l&&(n+=l+t)}return n.substring(0,n.length-t.length)}for(var W=Object.freeze({REGEXP_STRING:b,REGEXP_COMPILED:d,isUserAgent:function(e){if("string"==typeof e){var r=e.toUpperCase();e=0,-1!==r.indexOf("CHROME")&&(e|=2),-1!==r.indexOf("SAFARI")&&(e|=4),-1!==r.indexOf("FIREFOX")&&(e|=8),-1!==r.indexOf("EDGE")&&(e|=16)}var t=navigator.userAgent;return R(e,-1!==t.indexOf("Safari")&&-1===t.indexOf("Chrome")?4:-1!==t.indexOf("Firefox")?8:-1!==t.indexOf("Edge")?16:2)},getDeviceDPI:m,capitalize:p,convertUnderscore:function(e){var r=(e=e.charAt(0).toLowerCase()+e.substring(1)).match(h);if(r)for(var t=Array.isArray(a=r),n=0,a=t?a:a[Symbol.iterator]();;){var l;if(t){if(n>=a.length)break;l=a[n++]}else{if((n=a.next()).done)break;l=n.value}var i=l;e=e.replace(i,"".concat(i[0],"_").concat(i[1].toLowerCase()))}return e},convertCamelCase:y,convertWord:function(e){return arguments.length>1&&void 0!==arguments[1]&&arguments[1]?e.trim().replace(g,"_"):e.replace(c,"_")},convertInt:function(e){return e&&parseInt(e)||0},convertFloat:A,convertAngle:function(e){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"deg",t=parseFloat(e);switch(r){case"rad":t*=180/Math.PI;break;case"grad":t/=400;case"turn":t*=360}return t},convertPX:E,convertUnit:F,convertAlpha:function e(r){for(var t="";r>=s.length;){var n=Math.floor(r/s.length);n>1&&n<=s.length?(t+=s.charAt(n-1),r-=n*s.length):n>s.length&&(t+=e(n*s.length),r-=n*s.length);var a=r%s.length;t+=s.charAt(a),r-=a+s.length}return t=s.charAt(r)+t},convertRoman:function(e){for(var r=(""+e).split(""),t="",n=3;n--;)t=(u[parseInt(r.pop()||"")+10*n]||"")+t;return"M".repeat(parseInt(r.join("")))+t},convertEnum:function(e,r,t){for(var n=Object.keys(r),a=0;a<n.length;a++){var l=n[a];if(e===r[l])return t[l]}return""},calculate:x,calculateUnit:C,formatPX:k,formatPercent:w,formatString:function(e){for(var r=0;r<(arguments.length<=1?0:arguments.length-1);r++)e=e.replace("{".concat(r,"}"),r+1<1||arguments.length<=r+1?void 0:arguments[r+1]);return e},hasBit:R,isNumber:I,isString:M,isArray:function(e){return Array.isArray(e)&&e.length>0},isUnit:D,isPercent:S,isCalc:function(e){return d.CALC.test(e)},isEqual:function(e,r){if(e===r)return!0;if(Array.isArray(e)&&Array.isArray(r)){if(e.length===r.length){for(var t=0;t<e.length;t++)if(e[t]!==r[t])return!1;return!0}}else if(Object.keys(e).length===Object.keys(r).length){for(var n in e)if(e[n]!==r[n])return!1;return!0}return!1},includes:function(e,r){if(e){var t=e.split(arguments.length>2&&void 0!==arguments[2]?arguments[2]:","),n=Array.isArray(t),a=0;for(t=n?t:t[Symbol.iterator]();;){var l;if(n){if(a>=t.length)break;l=t[a++]}else{if((a=t.next()).done)break;l=a.value}if(l.trim()===r)return!0}}return!1},cloneInstance:function(e){return Object.assign(Object.create(Object.getPrototypeOf(e)),e)},cloneArray:B,cloneObject:O,optional:N,optionalAsObject:function(e,r){return N(e,r,"object")},optionalAsString:function(e,r){return N(e,r,"string")},optionalAsNumber:function(e,r){return N(e,r,"number")},optionalAsBoolean:function(e,r){return N(e,r,"boolean")},resolvePath:T,trimNull:function(e){return e?e.trim():""},trimString:function(e,r){return L(_(e,r),r)},trimStart:L,trimEnd:_,firstIndexOf:function(e){for(var r=arguments.length,t=Array(r>1?r-1:0),n=1;n<r;n++)t[n-1]=arguments[n];for(var a=0;a<t.length;a++){var l=e.indexOf(t[a]);if(-1!==l)return l}return-1},fromLastIndexOf:function(e){return e.substring(e.lastIndexOf(arguments.length>1&&void 0!==arguments[1]?arguments[1]:"/")+1)},searchObject:function(e,t){var n,a=[];if("object"===r(t))for(var l in t){var i=t[l];P(e[i])&&a.push([i,e[i]])}else for(var o in n=/^\*.+\*$/.test(t)?function(e){return-1!==e.indexOf(t.replace(/\*/g,""))}:/^\*/.test(t)?function(e){return e.endsWith(t.replace(/\*/,""))}:/\*$/.test(t)?function(e){return e.startsWith(t.replace(/\*/,""))}:function(e){return e===t},e)n(o)&&a.push([o,e[o]]);return a},hasValue:P,hasInSet:function(e,r){for(var t=Array.isArray(a=e),n=0,a=t?a:a[Symbol.iterator]();;){var l;if(t){if(n>=a.length)break;l=a[n++]}else{if((n=a.next()).done)break;l=n.value}if(r(l))return!0}return!1},withinRange:j,assignEmptyProperty:function(e,r){for(var t in r)e.hasOwnProperty(t)||(e[t]=r[t]);return e},assignEmptyValue:function(e){if((arguments.length<=1?0:arguments.length-1)>1)for(var t=e,n=0;;n++){var a=n+1<1||arguments.length<=n+1?void 0:arguments[n+1];if(n===(arguments.length<=1?0:arguments.length-1)-2){P(t[a])||(t[a]=n+1+1<1||arguments.length<=n+1+1?void 0:arguments[n+1+1]);break}if(!M(a))break;if(t[a]&&"object"===r(t[a]))t=t[a];else{if(null!=t[a])break;t[a]={},t=t[a]}}},sortNumber:function(e){return e.sort(arguments.length>1&&void 0!==arguments[1]&&arguments[1]?function(e,r){return e>r?-1:1}:function(e,r){return e<r?-1:1})},sortArray:function(e,r){for(var t=arguments.length,n=Array(t>2?t-2:0),a=2;a<t;a++)n[a-2]=arguments[a];return e.sort(function(e,t){for(var a=0;a<n.length;a++){var l=v(e,t,n[a],!0);if(l&&l[0]!==l[1])return r?l[0]>l[1]?1:-1:l[0]<l[1]?1:-1}return 0})},flatArray:function(e){for(var r=e;r.some(function(e){return Array.isArray(e)});)r=[].concat.apply([],X(r,function(e){return null!=e}));return r},partitionArray:z,spliceArray:U,filterArray:X,concatArray:H,concatMultiArray:function(e){for(var r=arguments.length,t=Array(r>1?r-1:0),n=1;n<r;n++)t[n-1]=arguments[n];for(var a=0;a<t.length;a++)for(var l=Array.isArray(o=t[a]),i=0,o=l?o:o[Symbol.iterator]();;){var s;if(l){if(i>=o.length)break;s=o[i++]}else{if((i=o.next()).done)break;s=i.value}e.push(s)}return e},flatMap:q,filterMap:function(e,r,t){for(var n=[],a=0;a<e.length;a++)r(e[a],a,e)&&n.push(t(e[a],a,e));return n},replaceMap:function(e,r){for(var t=0;t<e.length;t++)e[t]=r(e[t],t,e);return e},objectMap:G,joinMap:V,captureMap:function(e,r,t){for(var n=0;n<e.length&&(!r(e[n],n,e)||!1!==t(e[n],n,e));n++);}}),$=function(){function e(r){!function(e,r){if(!(e instanceof r))throw new TypeError("Cannot call a class as a function")}(this,e),this._children=r||[]}var r,t,n;return r=e,(t=[{key:Symbol.iterator,value:function(){var e=this._children,r=0;return{next:function(){return r<e.length?{done:!1,value:e[r++]}:{done:!0,value:void 0}}}}},{key:"item",value:function(e,r){return void 0===e||void 0===r?void 0===e?this._children[this._children.length-1]:this._children[e]:e>=0&&e<this._children.length?(this._children[e]=r,r):void 0}},{key:"append",value:function(e){return this._children.push(e),this}},{key:"remove",value:function(e){for(var r=0;r<this._children.length;r++)if(this._children[r]===e)return this._children.splice(r,1);return[]}},{key:"contains",value:function(e){return-1!==this._children.indexOf(e)}},{key:"retain",value:function(e){return this._children=e,this}},{key:"duplicate",value:function(){return this._children.slice(0)}},{key:"clear",value:function(){return this._children.length=0,this}},{key:"each",value:function(e){for(var r=0;r<this._children.length;r++)e(this._children[r],r,this._children);return this}},{key:"find",value:function(e,r){if("string"==typeof e){for(var t=0;t<this._children.length;t++)if(this._children[t][e]===r)return this._children[t]}else for(var n=0;n<this._children.length;n++)if(e(this._children[n],n,this._children))return this._children[n]}},{key:"sort",value:function(e){return this._children.sort(e),this}},{key:"concat",value:function(e){return H(this._children,e),this}},{key:"every",value:function(e){if(this.length>0){for(var r=0;r<this._children.length;r++)if(!e(this._children[r],r,this._children))return!1;return!0}return!1}},{key:"some",value:function(e){for(var r=0;r<this._children.length;r++)if(e(this._children[r],r,this._children))return!0;return!1}},{key:"filter",value:function(e){return X(this._children,e)}},{key:"partition",value:function(e){return z(this._children,e)}},{key:"splice",value:function(e,r){return U(this._children,e,r)}},{key:"map",value:function(e){return G(this._children,e)}},{key:"flatMap",value:function(e){return q(this._children,e)}},{key:"cascade",value:function(){function r(t){for(var n=[],a=Array.isArray(i=t.children),l=0,i=a?i:i[Symbol.iterator]();;){var o;if(a){if(l>=i.length)break;o=i[l++]}else{if((l=i.next()).done)break;o=l.value}var s=o;n.push(s),s instanceof e&&s.length&&H(n,r(s))}return n}return r(this)}},{key:"children",get:function(){return this._children}},{key:"length",get:function(){return this._children.length}}])&&a(r.prototype,t),n&&a(r,n),e}(),Y=[{value:"#000000",name:"black",rgb:{r:0,g:0,b:0},hsl:{h:0,s:0,l:0}},{value:"#696969",name:"dimgray",rgb:{r:105,g:105,b:105},hsl:{h:0,s:0,l:41}},{value:"#696969",name:"dimgrey",rgb:{r:105,g:105,b:105},hsl:{h:0,s:0,l:41}},{value:"#808080",name:"gray",rgb:{r:128,g:128,b:128},hsl:{h:0,s:0,l:50}},{value:"#808080",name:"grey",rgb:{r:128,g:128,b:128},hsl:{h:0,s:0,l:50}},{value:"#A9A9A9",name:"darkgray",rgb:{r:169,g:169,b:169},hsl:{h:0,s:0,l:66}},{value:"#A9A9A9",name:"darkgrey",rgb:{r:169,g:169,b:169},hsl:{h:0,s:0,l:66}},{value:"#C0C0C0",name:"silver",rgb:{r:192,g:192,b:192},hsl:{h:0,s:0,l:75}},{value:"#D3D3D3",name:"lightgray",rgb:{r:211,g:211,b:211},hsl:{h:0,s:0,l:83}},{value:"#D3D3D3",name:"lightgrey",rgb:{r:211,g:211,b:211},hsl:{h:0,s:0,l:83}},{value:"#DCDCDC",name:"gainsboro",rgb:{r:220,g:220,b:220},hsl:{h:0,s:0,l:86}},{value:"#F5F5F5",name:"whitesmoke",rgb:{r:245,g:245,b:245},hsl:{h:0,s:0,l:96}},{value:"#FFFFFF",name:"white",rgb:{r:255,g:255,b:255},hsl:{h:0,s:0,l:100}},{value:"#BC8F8F",name:"rosybrown",rgb:{r:188,g:143,b:143},hsl:{h:0,s:25,l:65}},{value:"#CD5C5C",name:"indianred",rgb:{r:205,g:92,b:92},hsl:{h:0,s:53,l:58}},{value:"#A52A2A",name:"brown",rgb:{r:165,g:42,b:42},hsl:{h:0,s:59,l:41}},{value:"#B22222",name:"firebrick",rgb:{r:178,g:34,b:34},hsl:{h:0,s:68,l:42}},{value:"#F08080",name:"lightcoral",rgb:{r:240,g:128,b:128},hsl:{h:0,s:79,l:72}},{value:"#800000",name:"maroon",rgb:{r:128,g:0,b:0},hsl:{h:0,s:100,l:25}},{value:"#8B0000",name:"darkred",rgb:{r:139,g:0,b:0},hsl:{h:0,s:100,l:27}},{value:"#FF0000",name:"red",rgb:{r:255,g:0,b:0},hsl:{h:0,s:100,l:50}},{value:"#FFFAFA",name:"snow",rgb:{r:255,g:250,b:250},hsl:{h:0,s:100,l:99}},{value:"#FFE4E1",name:"mistyrose",rgb:{r:255,g:228,b:225},hsl:{h:6,s:100,l:94}},{value:"#FA8072",name:"salmon",rgb:{r:250,g:128,b:114},hsl:{h:6,s:93,l:71}},{value:"#FF6347",name:"tomato",rgb:{r:255,g:99,b:71},hsl:{h:9,s:100,l:64}},{value:"#E9967A",name:"darksalmon",rgb:{r:233,g:150,b:122},hsl:{h:15,s:72,l:70}},{value:"#FF7F50",name:"coral",rgb:{r:255,g:127,b:80},hsl:{h:16,s:100,l:66}},{value:"#FF4500",name:"orangered",rgb:{r:255,g:69,b:0},hsl:{h:16,s:100,l:50}},{value:"#FFA07A",name:"lightsalmon",rgb:{r:255,g:160,b:122},hsl:{h:17,s:100,l:74}},{value:"#A0522D",name:"sienna",rgb:{r:160,g:82,b:45},hsl:{h:19,s:56,l:40}},{value:"#FFF5EE",name:"seashell",rgb:{r:255,g:245,b:238},hsl:{h:25,s:100,l:97}},{value:"#D2691E",name:"chocolate",rgb:{r:210,g:105,b:30},hsl:{h:25,s:75,l:47}},{value:"#8B4513",name:"saddlebrown",rgb:{r:139,g:69,b:19},hsl:{h:25,s:76,l:31}},{value:"#F4A460",name:"sandybrown",rgb:{r:244,g:164,b:96},hsl:{h:28,s:87,l:67}},{value:"#FFDAB9",name:"peachpuff",rgb:{r:255,g:218,b:185},hsl:{h:28,s:100,l:86}},{value:"#CD853F",name:"peru",rgb:{r:205,g:133,b:63},hsl:{h:30,s:59,l:53}},{value:"#FAF0E6",name:"linen",rgb:{r:250,g:240,b:230},hsl:{h:30,s:67,l:94}},{value:"#FFE4C4",name:"bisque",rgb:{r:255,g:228,b:196},hsl:{h:33,s:100,l:88}},{value:"#FF8C00",name:"darkorange",rgb:{r:255,g:140,b:0},hsl:{h:33,s:100,l:50}},{value:"#DEB887",name:"burlywood",rgb:{r:222,g:184,b:135},hsl:{h:34,s:57,l:70}},{value:"#FAEBD7",name:"antiquewhite",rgb:{r:250,g:235,b:215},hsl:{h:34,s:78,l:91}},{value:"#D2B48C",name:"tan",rgb:{r:210,g:180,b:140},hsl:{h:34,s:44,l:69}},{value:"#FFDEAD",name:"navajowhite",rgb:{r:255,g:222,b:173},hsl:{h:36,s:100,l:84}},{value:"#FFEBCD",name:"blanchedalmond",rgb:{r:255,g:235,b:205},hsl:{h:36,s:100,l:90}},{value:"#FFEFD5",name:"papayawhip",rgb:{r:255,g:239,b:213},hsl:{h:37,s:100,l:92}},{value:"#FFE4B5",name:"moccasin",rgb:{r:255,g:228,b:181},hsl:{h:38,s:100,l:85}},{value:"#FFA500",name:"orange",rgb:{r:255,g:165,b:0},hsl:{h:39,s:100,l:50}},{value:"#F5DEB3",name:"wheat",rgb:{r:245,g:222,b:179},hsl:{h:39,s:77,l:83}},{value:"#FDF5E6",name:"oldlace",rgb:{r:253,g:245,b:230},hsl:{h:39,s:85,l:95}},{value:"#FFFAF0",name:"floralwhite",rgb:{r:255,g:250,b:240},hsl:{h:40,s:100,l:97}},{value:"#B8860B",name:"darkgoldenrod",rgb:{r:184,g:134,b:11},hsl:{h:43,s:89,l:38}},{value:"#DAA520",name:"goldenrod",rgb:{r:218,g:165,b:32},hsl:{h:43,s:74,l:49}},{value:"#FFF8DC",name:"cornsilk",rgb:{r:255,g:248,b:220},hsl:{h:48,s:100,l:93}},{value:"#FFD700",name:"gold",rgb:{r:255,g:215,b:0},hsl:{h:51,s:100,l:50}},{value:"#FFFACD",name:"lemonchiffon",rgb:{r:255,g:250,b:205},hsl:{h:54,s:100,l:90}},{value:"#F0E68C",name:"khaki",rgb:{r:240,g:230,b:140},hsl:{h:54,s:77,l:75}},{value:"#EEE8AA",name:"palegoldenrod",rgb:{r:238,g:232,b:170},hsl:{h:55,s:67,l:80}},{value:"#BDB76B",name:"darkkhaki",rgb:{r:189,g:183,b:107},hsl:{h:56,s:38,l:58}},{value:"#F5F5DC",name:"beige",rgb:{r:245,g:245,b:220},hsl:{h:60,s:56,l:91}},{value:"#FAFAD2",name:"lightgoldenrodyellow",rgb:{r:250,g:250,b:210},hsl:{h:60,s:80,l:90}},{value:"#808000",name:"olive",rgb:{r:128,g:128,b:0},hsl:{h:60,s:100,l:25}},{value:"#FFFF00",name:"yellow",rgb:{r:255,g:255,b:0},hsl:{h:60,s:100,l:50}},{value:"#FFFFE0",name:"lightyellow",rgb:{r:255,g:255,b:224},hsl:{h:60,s:100,l:94}},{value:"#FFFFF0",name:"ivory",rgb:{r:255,g:255,b:240},hsl:{h:60,s:100,l:97}},{value:"#6B8E23",name:"olivedrab",rgb:{r:107,g:142,b:35},hsl:{h:80,s:60,l:35}},{value:"#9ACD32",name:"yellowgreen",rgb:{r:154,g:205,b:50},hsl:{h:80,s:61,l:50}},{value:"#556B2F",name:"darkolivegreen",rgb:{r:85,g:107,b:47},hsl:{h:82,s:39,l:30}},{value:"#ADFF2F",name:"greenyellow",rgb:{r:173,g:255,b:47},hsl:{h:84,s:100,l:59}},{value:"#7FFF00",name:"chartreuse",rgb:{r:127,g:255,b:0},hsl:{h:90,s:100,l:50}},{value:"#7CFC00",name:"lawngreen",rgb:{r:124,g:252,b:0},hsl:{h:90,s:100,l:49}},{value:"#8FBC8F",name:"darkseagreen",rgb:{r:143,g:188,b:143},hsl:{h:120,s:25,l:65}},{value:"#228B22",name:"forestgreen",rgb:{r:34,g:139,b:34},hsl:{h:120,s:61,l:34}},{value:"#32CD32",name:"limegreen",rgb:{r:50,g:205,b:50},hsl:{h:120,s:61,l:50}},{value:"#90EE90",name:"lightgreen",rgb:{r:144,g:238,b:144},hsl:{h:120,s:73,l:75}},{value:"#98FB98",name:"palegreen",rgb:{r:152,g:251,b:152},hsl:{h:120,s:93,l:79}},{value:"#006400",name:"darkgreen",rgb:{r:0,g:100,b:0},hsl:{h:120,s:100,l:20}},{value:"#008000",name:"green",rgb:{r:0,g:128,b:0},hsl:{h:120,s:100,l:25}},{value:"#00FF00",name:"lime",rgb:{r:0,g:255,b:0},hsl:{h:120,s:100,l:50}},{value:"#F0FFF0",name:"honeydew",rgb:{r:240,g:255,b:240},hsl:{h:120,s:100,l:97}},{value:"#2E8B57",name:"seagreen",rgb:{r:46,g:139,b:87},hsl:{h:146,s:50,l:36}},{value:"#3CB371",name:"mediumseagreen",rgb:{r:60,g:179,b:113},hsl:{h:147,s:50,l:47}},{value:"#00FF7F",name:"springgreen",rgb:{r:0,g:255,b:127},hsl:{h:150,s:100,l:50}},{value:"#F5FFFA",name:"mintcream",rgb:{r:245,g:255,b:250},hsl:{h:150,s:100,l:98}},{value:"#00FA9A",name:"mediumspringgreen",rgb:{r:0,g:250,b:154},hsl:{h:157,s:100,l:49}},{value:"#66CDAA",name:"mediumaquamarine",rgb:{r:102,g:205,b:170},hsl:{h:160,s:51,l:60}},{value:"#7FFFD4",name:"aquamarine",rgb:{r:127,g:255,b:212},hsl:{h:160,s:100,l:75}},{value:"#40E0D0",name:"turquoise",rgb:{r:64,g:224,b:208},hsl:{h:174,s:72,l:56}},{value:"#20B2AA",name:"lightseagreen",rgb:{r:32,g:178,b:170},hsl:{h:177,s:70,l:41}},{value:"#48D1CC",name:"mediumturquoise",rgb:{r:72,g:209,b:204},hsl:{h:178,s:60,l:55}},{value:"#2F4F4F",name:"darkslategray",rgb:{r:47,g:79,b:79},hsl:{h:180,s:25,l:25}},{value:"#2F4F4F",name:"darkslategrey",rgb:{r:47,g:79,b:79},hsl:{h:180,s:25,l:25}},{value:"#AFEEEE",name:"paleturquoise",rgb:{r:175,g:238,b:238},hsl:{h:180,s:65,l:81}},{value:"#008080",name:"teal",rgb:{r:0,g:128,b:128},hsl:{h:180,s:100,l:25}},{value:"#008B8B",name:"darkcyan",rgb:{r:0,g:139,b:139},hsl:{h:180,s:100,l:27}},{value:"#00FFFF",name:"aqua",rgb:{r:0,g:255,b:255},hsl:{h:180,s:100,l:50}},{value:"#00FFFF",name:"cyan",rgb:{r:0,g:255,b:255},hsl:{h:180,s:100,l:50}},{value:"#E0FFFF",name:"lightcyan",rgb:{r:224,g:255,b:255},hsl:{h:180,s:100,l:94}},{value:"#F0FFFF",name:"azure",rgb:{r:240,g:255,b:255},hsl:{h:180,s:100,l:97}},{value:"#00CED1",name:"darkturquoise",rgb:{r:0,g:206,b:209},hsl:{h:181,s:100,l:41}},{value:"#5F9EA0",name:"cadetblue",rgb:{r:95,g:158,b:160},hsl:{h:182,s:25,l:50}},{value:"#B0E0E6",name:"powderblue",rgb:{r:176,g:224,b:230},hsl:{h:187,s:52,l:80}},{value:"#ADD8E6",name:"lightblue",rgb:{r:173,g:216,b:230},hsl:{h:195,s:53,l:79}},{value:"#00BFFF",name:"deepskyblue",rgb:{r:0,g:191,b:255},hsl:{h:195,s:100,l:50}},{value:"#87CEEB",name:"skyblue",rgb:{r:135,g:206,b:235},hsl:{h:197,s:71,l:73}},{value:"#87CEFA",name:"lightskyblue",rgb:{r:135,g:206,b:250},hsl:{h:203,s:92,l:75}},{value:"#4682B4",name:"steelblue",rgb:{r:70,g:130,b:180},hsl:{h:207,s:44,l:49}},{value:"#F0F8FF",name:"aliceblue",rgb:{r:240,g:248,b:255},hsl:{h:208,s:100,l:97}},{value:"#1E90FF",name:"dodgerblue",rgb:{r:30,g:144,b:255},hsl:{h:210,s:100,l:56}},{value:"#708090",name:"slategray",rgb:{r:112,g:128,b:144},hsl:{h:210,s:13,l:50}},{value:"#708090",name:"slategrey",rgb:{r:112,g:128,b:144},hsl:{h:210,s:13,l:50}},{value:"#778899",name:"lightslategray",rgb:{r:119,g:136,b:153},hsl:{h:210,s:14,l:53}},{value:"#778899",name:"lightslategrey",rgb:{r:119,g:136,b:153},hsl:{h:210,s:14,l:53}},{value:"#B0C4DE",name:"lightsteelblue",rgb:{r:176,g:196,b:222},hsl:{h:214,s:41,l:78}},{value:"#6495ED",name:"cornflower",rgb:{r:100,g:149,b:237},hsl:{h:219,s:79,l:66}},{value:"#4169E1",name:"royalblue",rgb:{r:65,g:105,b:225},hsl:{h:225,s:73,l:57}},{value:"#191970",name:"midnightblue",rgb:{r:25,g:25,b:112},hsl:{h:240,s:64,l:27}},{value:"#E6E6FA",name:"lavender",rgb:{r:230,g:230,b:250},hsl:{h:240,s:67,l:94}},{value:"#000080",name:"navy",rgb:{r:0,g:0,b:128},hsl:{h:240,s:100,l:25}},{value:"#00008B",name:"darkblue",rgb:{r:0,g:0,b:139},hsl:{h:240,s:100,l:27}},{value:"#0000CD",name:"mediumblue",rgb:{r:0,g:0,b:205},hsl:{h:240,s:100,l:40}},{value:"#0000FF",name:"blue",rgb:{r:0,g:0,b:255},hsl:{h:240,s:100,l:50}},{value:"#F8F8FF",name:"ghostwhite",rgb:{r:248,g:248,b:255},hsl:{h:240,s:100,l:99}},{value:"#6A5ACD",name:"slateblue",rgb:{r:106,g:90,b:205},hsl:{h:248,s:53,l:58}},{value:"#483D8B",name:"darkslateblue",rgb:{r:72,g:61,b:139},hsl:{h:248,s:39,l:39}},{value:"#7B68EE",name:"mediumslateblue",rgb:{r:123,g:104,b:238},hsl:{h:249,s:80,l:67}},{value:"#9370DB",name:"mediumpurple",rgb:{r:147,g:112,b:219},hsl:{h:260,s:60,l:65}},{value:"#8A2BE2",name:"blueviolet",rgb:{r:138,g:43,b:226},hsl:{h:271,s:76,l:53}},{value:"#4B0082",name:"indigo",rgb:{r:75,g:0,b:130},hsl:{h:275,s:100,l:25}},{value:"#9932CC",name:"darkorchid",rgb:{r:153,g:50,b:204},hsl:{h:280,s:61,l:50}},{value:"#9400D3",name:"darkviolet",rgb:{r:148,g:0,b:211},hsl:{h:282,s:100,l:41}},{value:"#BA55D3",name:"mediumorchid",rgb:{r:186,g:85,b:211},hsl:{h:288,s:59,l:58}},{value:"#D8BFD8",name:"thistle",rgb:{r:216,g:191,b:216},hsl:{h:300,s:24,l:80}},{value:"#DDA0DD",name:"plum",rgb:{r:221,g:160,b:221},hsl:{h:300,s:47,l:75}},{value:"#EE82EE",name:"violet",rgb:{r:238,g:130,b:238},hsl:{h:300,s:76,l:72}},{value:"#800080",name:"purple",rgb:{r:128,g:0,b:128},hsl:{h:300,s:100,l:25}},{value:"#8B008B",name:"darkmagenta",rgb:{r:139,g:0,b:139},hsl:{h:300,s:100,l:27}},{value:"#FF00FF",name:"fuchsia",rgb:{r:255,g:0,b:255},hsl:{h:300,s:100,l:50}},{value:"#FF00FF",name:"magenta",rgb:{r:255,g:0,b:255},hsl:{h:300,s:100,l:50}},{value:"#DA70D6",name:"orchid",rgb:{r:218,g:112,b:214},hsl:{h:302,s:59,l:65}},{value:"#C71585",name:"mediumvioletred",rgb:{r:199,g:21,b:133},hsl:{h:322,s:81,l:43}},{value:"#FF1493",name:"deeppink",rgb:{r:255,g:20,b:147},hsl:{h:328,s:100,l:54}},{value:"#FF69B4",name:"hotpink",rgb:{r:255,g:105,b:180},hsl:{h:330,s:100,l:71}},{value:"#FFF0F5",name:"lavenderblush",rgb:{r:255,g:240,b:245},hsl:{h:340,s:100,l:97}},{value:"#DB7093",name:"palevioletred",rgb:{r:219,g:112,b:147},hsl:{h:340,s:60,l:65}},{value:"#DC143C",name:"crimson",rgb:{r:220,g:20,b:60},hsl:{h:348,s:83,l:47}},{value:"#FFC0CB",name:"pink",rgb:{r:255,g:192,b:203},hsl:{h:350,s:100,l:88}},{value:"#FFB6C1",name:"lightpink",rgb:{r:255,g:182,b:193},hsl:{h:351,s:100,l:86}}],K=0;K<Y.length;K++){Object.freeze(Y[K])}var Z={},Q="0123456789ABCDEF",J=/[A-Za-z\d]{3,}/,ee=/rgba?\((\d+), (\d+), (\d+)(?:, ([\d.]+))?\)/,re=function(e){return 255*parseFloat(e.trim()||"1")};function te(e){for(var r=0;r<Y.length;r++){var t=Y[r];if(t.name===e.toLowerCase())return t}}function ne(e){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"1",t=arguments.length>2&&void 0!==arguments[2]&&arguments[2];if(e&&("transparent"!==e||t)){if(Z[e])return Z[e];var n,a="";if("#"===e.charAt(0))n=le(e);else if(e.startsWith("rgb")){var l=e.match(ee);l&&(n={r:parseInt(l[1]),g:parseInt(l[2]),b:parseInt(l[3]),a:l[4]?255*parseFloat(l[4]):re(r)})}else switch(e){case"transparent":n={r:0,g:0,b:0,a:0},a="transparent";break;case"initial":n={r:0,g:0,b:0,a:255},a="black";break;default:var i=te(e);i&&(n=Object.assign({},i.rgb,{a:re(r)}),a=e)}if(n&&(n.a>0||t)){var o=ae(n.r,n.g,n.b),s=ae(n.a),u=n.a/255;return Z[e]={name:a,value:"#".concat(o),valueAsRGBA:"#".concat(o+s),valueAsARGB:"#".concat(s+o),rgba:n,hsl:ie(n),opacity:u,semiopaque:u>0&&u<1,transparent:0===u},Object.freeze(Z[e]),Z[e]}}}function ae(){for(var e="",r=arguments.length,t=Array(r),n=0;n<r;n++)t[n]=arguments[n];for(var a=0;a<t.length;a++){var l=Math.max(0,Math.min(t[a],255));e+=isNaN(l)?"00":Q.charAt((l-l%16)/16)+Q.charAt(l%16)}return e}function le(e){if(e=e.replace(/#/g,"").trim(),J.test(e)){var r=255;switch(e.length){case 4:r=parseInt(e.charAt(3).repeat(2),16);case 3:e=e.charAt(0).repeat(2)+e.charAt(1).repeat(2)+e.charAt(2).repeat(2);break;case 5:e+=e.charAt(4);break;default:e.length>=8&&(r=parseInt(e.substring(6,8),16)),e=e.substring(0,6)}if(6===e.length)return{r:parseInt(e.substring(0,2),16),g:parseInt(e.substring(2,4),16),b:parseInt(e.substring(4),16),a:r}}}function ie(e){var r=e.r/255,t=e.g/255,n=e.b/255,a=Math.min(r,t,n),l=Math.max(r,t,n),i=(l+a)/2,o=i,s=i;if(l===a)i=0,o=0;else{var u=l-a;switch(o=s>.5?u/(2-l-a):u/(l+a),l){case r:i=(t-n)/u+(t<n?6:0);break;case t:i=(n-r)/u+2;break;case n:i=(r-t)/u+4}i/=6}return{h:Math.round(360*i),s:Math.round(100*o),l:Math.round(100*s),a:e.a/255}}function oe(e){return"rgb".concat(e.a<255?"a":"","(").concat(e.r,", ").concat(e.g,", ").concat(e.b).concat(e.a<255?", ".concat((e.a/255).toPrecision(2)):"",")")}var se=Object.freeze({findColorName:te,findColorShade:function(e){var r=le(e);if(r){for(var t=ie(r),n=[],a=-1,l=0;l<Y.length;l++){var i=Y[l];if(i.value===e)return i;-1!==a?a===i.hsl.h&&n.push(i):t.h>=i.hsl.h&&(n.push(i),a=i.hsl.h)}if(1===n.length)return n[0];if(n.length>1){for(var o=t.l+t.s,s=[],u=0;u<n.length;u++){var h=n[u];s.push(Math.abs(o-(h.hsl.l+h.hsl.s)))}for(var c=1/0,g=-1,f=0;f<s.length;f++)s[f]<c&&(c=s[f],g=f);return n[g]}return Y[Y.length-1]}},parseColor:ne,reduceColor:function(e,r){var t=le(e);if(t){var n=r<0?0:255;return ne(oe({r:(t.r+Math.round((n-t.r)*(r=Math.abs(r))))%255,g:(t.g+Math.round((n-t.g)*r))%255,b:(t.b+Math.round((n-t.b)*r))%255,a:t.a}))}},getHexCode:ae,convertHex:function(e){return"#".concat(ae(e.r,e.g,e.b)+(e.a<255?ae(e.a):""))},parseRGBA:le,convertHSLA:ie,formatRGBA:oe,formatHSLA:function(e){return"hsl".concat(e.a<255?"a":"","(").concat(e.h,", ").concat(e.s,"%, ").concat(e.l,"%").concat(e.a<255?", ".concat((e.a/255).toPrecision(2)):"",")")}});function ue(){return{top:0,left:0,right:0,bottom:0,width:0,height:0}}function he(e){return{top:e.top,right:e.right,bottom:e.bottom,left:e.left,width:e.width,height:e.height}}function ce(e,r,t){e["__".concat(r)]=t}function ge(e,r){return e["__".concat(r)]||void 0}function fe(e){return M(e.className)&&e.className.startsWith("squared")?void 0:ge(e,"node")}var ve=Object.freeze({newBoxRect:function(){return{top:0,left:0,right:0,bottom:0}},newRectDimension:ue,newBoxModel:function(){return{marginTop:0,marginRight:0,marginBottom:0,marginLeft:0,paddingTop:0,paddingRight:0,paddingBottom:0,paddingLeft:0}},getRangeClientRect:function(e){var r=document.createRange();r.selectNodeContents(e);for(var t=r.getClientRects(),n=[],a=0;a<t.length;a++){var l=t.item(a);0===Math.round(l.width)&&j(l.left,l.right)||n.push(l)}var i={top:0,left:0,right:0,bottom:0,width:0,height:0},o=0;if(n.length){i=he(n[0]);for(var s=new Set([i.top]),u=new Set([i.bottom]),h=i.top,c=i.bottom,g=1;g<n.length;g++){var f=n[g];s.add(Math.round(f.top)),u.add(Math.round(f.bottom)),h=Math.min(h,f.top),c=Math.min(c,f.bottom),i.width+=f.width,i.right=Math.max(f.right,i.right),i.height=Math.max(f.height,i.height)}s.size>1&&u.size>1&&(i.top=h,i.bottom=c,n[n.length-1].top>=n[0].bottom&&e.textContent&&(""!==e.textContent.trim()||/^\s*\n/.test(e.textContent))&&(o=n.length-1))}return i.multiline=o,i},assignRect:he,removeElementsByClassName:function(e){for(var r=document.getElementsByClassName(e),t=0;t<r.length;t++){var n=r[t];n.parentElement&&n.parentElement.removeChild(n)}},isElementVisible:function(e){var r=arguments.length>1&&void 0!==arguments[1]&&arguments[1],t=e.getBoundingClientRect();return 0!==t.width&&0!==t.height&&(!r||function(e){return!(e.left<0&&e.top<0&&Math.abs(e.left)>=e.width&&Math.abs(e.top)>=e.height)}(t))},getFirstChildElement:function(e){var r=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(e)for(var t=0;t<e.childNodes.length;t++){var n=fe(e.childNodes[t]);if(n&&(!n.excluded||r&&n.lineBreak))return n.element}return null},getLastChildElement:function(e){var r=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(e)for(var t=e.childNodes.length-1;t>=0;t--){var n=fe(e.childNodes[t]);if(n&&n.naturalElement&&(!n.excluded||r&&n.lineBreak))return n.element}return null},getElementsBetweenSiblings:function(e,r){var t=arguments.length>2&&void 0!==arguments[2]&&arguments[2];if(!e||e.parentElement===r.parentElement){var n=r.parentElement;if(n){for(var a=e?-1:0,l=-1,i=Array.from(n.childNodes),o=0;o<i.length;o++)i[o]===e&&(a=o),i[o]===r&&(l=o);if(-1!==a&&-1!==l&&a!==l){var s=i.slice(Math.min(a,l)+1,Math.max(a,l));return U(s,t?function(e){return"#comment"===e.nodeName}:function(e){return"#"===e.nodeName.charAt(0)&&("text"!==e.nodeName||!!e.textContent&&""===e.textContent.trim())}),s}}}return[]},getPreviousElementSibling:function(e){if(e)for(e=e.previousSibling;e;){var r=fe(e);if(r&&(!r.excluded||r.lineBreak))return r.element;e=e.previousSibling}return null},getNextElementSibling:function(e){if(e)for(e=e.nextSibling;e;){var r=fe(e);if(r&&(!r.excluded||r.lineBreak))return r.element;e=e.nextSibling}return null},setElementCache:ce,getElementCache:ge,deleteElementCache:function(e){for(var r=arguments.length,t=Array(r>1?r-1:0),n=1;n<r;n++)t[n-1]=arguments[n];for(var a=0;a<t.length;a++)e["__".concat(t[a])]=void 0},getElementAsNode:fe}),be=/((?:\d+%\s*,?\s*)+|from|to)\s*{\s*(.+?)\s*}/,de=RegExp("".concat(b.VAR),"g");function me(e,r,t){return S(e)?parseFloat(e)/100:C(e,t)/r}function pe(e){return!!e&&("object"===r(e.style)&&null!==e.style)}function ye(e){if(e){if(!(arguments.length>1&&void 0!==arguments[1])||arguments[1]){var r=ge(e,"style");if(r)return r;var t=fe(e);if(t&&t.plainText)return t.unsafe("styleMap")}if(pe(e)){var n=getComputedStyle(e);return ce(e,"style",n),n}return{}}return{display:"none"}}function Ae(e){return parseInt(ye(e).fontSize||"16px")}function Ee(e,r){if(e){for(var t=arguments.length,n=Array(t>2?t-2:0),a=2;a<t;a++)n[a-2]=arguments[a];return"#"!==e.nodeName.charAt(0)&&n.includes(ye(e)[r])||e.parentElement&&n.includes(ye(e.parentElement)[r])}return!1}function Fe(e,r,t){var n="";if(e){for(var a=e.parentElement,l=arguments.length,i=Array(l>3?l-3:0),o=3;o<l;o++)i[o-3]=arguments[o];for(;a&&!i.includes(a.tagName)&&(("inherit"===(n=ye(a)[r]||"")||t&&t.test(n))&&(n=""),""===n&&a!==document.body);)a=a.parentElement}return n}function xe(e,r){var t=pe(e)?e.style[r]:"";if(!t){var n=ge(e,"styleMap");n&&(t=n[r])}return t||""}function Ce(e,r){var t=arguments.length>2&&void 0!==arguments[2]&&arguments[2],n=fe(e),a=y(r);return n&&n.cssInitial(a)||xe(e,a)||ke(e,r)||t&&ye(e)[a]||""}function ke(e,r){if(e){var t=e.attributes.getNamedItem(r);if(t)return t.value.trim()}return""}var we=Object.freeze({getKeyframeRules:function(){var e=new Map;e:for(var r=0;r<document.styleSheets.length;r++){var t=document.styleSheets[r];if(t.cssRules)for(var n=0;n<t.cssRules.length;n++)try{var a=t.cssRules[n];if(7===a.type){for(var i={},o=0;o<a.cssRules.length;o++){var s=be.exec(a.cssRules[o].cssText);if(s){var u=(a.cssRules[o].keyText||s[1].trim()).split(d.SEPARATOR),h=Array.isArray(u),c=0;for(u=h?u:u[Symbol.iterator]();;){var g;if(h){if(c>=u.length)break;g=u[c++]}else{if((c=u.next()).done)break;g=c.value}var f=g;switch(f=f.trim()){case"from":f="0%";break;case"to":f="100%"}i[f]={};var v=s[2].split(";"),b=Array.isArray(v),m=0;for(v=b?v:v[Symbol.iterator]();;){var p;if(b){if(m>=v.length)break;p=v[m++]}else{if((m=v.next()).done)break;p=m.value}var y=l(p.split(":"),2),A=y[1];A&&(i[f][y[0].trim()]=A.trim())}}}}e.set(a.name,i)}}catch(e){break e}}return e},hasComputedStyle:pe,checkStyleValue:function(e,r,t,n,a){if(void 0===n&&(n=ye(e)),"inherit"===t&&(t=Fe(e.parentElement,r)),t&&"initial"!==t){if(t!==n[r]){switch(r){case"backgroundColor":case"borderTopColor":case"borderRightColor":case"borderBottomColor":case"borderLeftColor":case"color":case"fontSize":case"fontWeight":return n[r]}if(d.CUSTOMPROPERTY.test(t))return n[r];switch(r){case"width":case"height":case"minWidth":case"maxWidth":case"minHeight":case"maxHeight":case"lineHeight":case"verticalAlign":case"textIndent":case"columnGap":case"top":case"right":case"bottom":case"left":case"marginTop":case"marginRight":case"marginBottom":case"marginLeft":case"paddingTop":case"paddingRight":case"paddingBottom":case"paddingLeft":return D(t)?E(t,a):t}}return t}return""},getDataSet:function(e,r){var t={};if(e)for(var n in r=y(r,"\\."),e.dataset)n.length>r.length&&n.startsWith(r)&&(t[p(n.substring(r.length),!1)]=e.dataset[n]);return t},getStyle:ye,getFontSize:Ae,isParentStyle:Ee,getInheritedStyle:Fe,isInheritedStyle:function(e,r){if(pe(e)&&e.parentElement){var t=fe(e);if(t&&!t.cssInitial(r))return ye(e)[r]===ye(e.parentElement)[r]}return!1},getInlineStyle:xe,getAttribute:Ce,getParentAttribute:function(e,r){for(var t=e,n="";t&&(""===(n=Ce(t,r))||"inherit"===n);)t=t.parentElement;return n},calculateVar:function(e,r,t,n){for(var a,l=getComputedStyle(e),i=r;null!==(a=de.exec(r));){var o=l.getPropertyValue(a[1]).trim();if(""===o)return;i=i.replace(a[0],o)}if(t&&!n)if(e instanceof SVGElement){var s=e.getBoundingClientRect();n="height"===t||t.length<=2&&-1!==t.indexOf("y")?s.height:s.width}else{var u=(e.parentElement||e).getBoundingClientRect();n=-1!==t.toLowerCase().indexOf("height")?u.height:u.width}return x(i,n,Ae(e))},getNamedItem:ke,getBackgroundPosition:function(e,r,t){var n=arguments.length>3&&void 0!==arguments[3]&&arguments[3],a={top:0,left:0,right:0,bottom:0,horizontal:"left",vertical:"top",originalX:"",originalY:""},l="center"===e?["center","center"]:e.split(" ");if(4===l.length)for(var i=0;i<l.length;i++){var o=l[i];switch(i){case 0:a.horizontal=o;break;case 1:var s=n?me(o,r.width,t):F(o,r.width,t);switch(a.horizontal){case"end:":a.horizontal="right";case"right":a.right=s,a.left=n?1-s:r.width-s,a.originalX=S(o)?w(100-parseInt(o)):k(r.width-parseInt(E(o,t)));break;case"start":a.horizontal="left";default:a.left=s,a.originalX=o}break;case 2:a.vertical=o;break;case 3:var u=n?me(o,r.height,t):F(o,r.height,t);"bottom"===a.vertical?(a.bottom=u,a.top=n?1-u:r.height-u,a.originalY=S(o)?w(100-parseInt(o)):k(r.height-parseInt(E(o,t)))):(a.top=u,a.originalY=o)}}else if(2===l.length)for(var h=0;h<l.length;h++){var c=l[h],g=void 0,f=void 0,v=void 0;if(0===h?(g=r.width,f="left",v="originalX",a.horizontal=c):(g=r.height,f="top",v="originalY",a.vertical=c),/^[a-z]+$/.test(c))switch(c){case"start":a.horizontal="left";case"left":case"top":a[v]="0%";break;case"end":a.horizontal="right";case"right":case"bottom":a[f]=n?1:g,a[v]="100%";break;case"center":a[f]=n?.5:Math.round(g/2),a[v]="50%"}else a[f]=n?me(c,g,t):F(c,g,t),a[v]=c}return a},resolveURL:function(e){var r=e.match(d.URL);return r?T(r[1]):""}});function Re(e){if("#text"===e.nodeName&&e.textContent){if(arguments.length>1&&void 0!==arguments[1]&&arguments[1]){for(var r=e.textContent,t=0;t<r.length;t++)switch(r.charCodeAt(t)){case 9:case 10:case 13:case 32:continue;default:return!0}return!1}return""!==e.textContent.trim()}return!1}var Ie=Object.freeze({ELEMENT_BLOCK:["ADDRESS","ARTICLE","ASIDE","BLOCKQUOTE","CANVAS","DD","DIV","DL","DT","FIELDSET","FIGCAPTION","FIGURE","FOOTER","FORM","H1","H2","H3","H4","H5","H6","HEADER","LI","MAIN","NAV","OL","OUTPUT","P","PRE","SECTION","TFOOT","TH","THEAD","TR","UL","VIDEO"],ELEMENT_INLINE:["A","ABBR","ACRONYM","B","BDO","BIG","BR","BUTTON","CITE","CODE","DFN","EM","I","IFRAME","IMG","INPUT","KBD","LABEL","MAP","OBJECT","Q","S","SAMP","SCRIPT","SELECT","SMALL","SPAN","STRIKE","STRONG","SUB","SUP","TEXTAREA","TIME","TT","U","VAR","PLAINTEXT"],createElement:function(e){var r=document.createElement(arguments.length>1&&void 0!==arguments[1]&&arguments[1]?"div":"span"),t=r.style;return t.position="static",t.margin="0px",t.padding="0px",t.border="none",t.cssFloat="none",t.clear="none",t.display="none",r.className="__css.placeholder",e&&e.appendChild(r),r},isPlainText:Re,isLineBreak:function(e){if("BR"===e.tagName)return!0;if(!(arguments.length>1&&void 0!==arguments[1])||arguments[1]){var r=fe(e);return r&&r.excluded&&r.blockStatic}return!1},hasLineBreak:function(e){var r=arguments.length>1&&void 0!==arguments[1]&&arguments[1],t=arguments.length>2&&void 0!==arguments[2]&&arguments[2];if(e.children){for(var n=0;n<e.children.length;n++)if("BR"===e.children[n].tagName)return!0}else if(!r){var a=e.textContent||"";if(t&&(a=a.trim()),/\n/.test(a)){var l=fe(e),i=l?l.css("whiteSpace"):ye(e).whiteSpace||"";return["pre","pre-wrap"].includes(i)||"#text"===e.nodeName&&Ee(e,"whiteSpace","pre","pre-wrap")}}return!1},hasFreeFormText:function(e){var r=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];return function e(t){for(var n=0;n<t.length;n++){var a=t[n];if("#text"===a.nodeName){if(Re(a,r)||Ee(a,"whiteSpace","pre","pre-wrap")&&a.textContent&&""!==a.textContent)return!0}else if(e(a.childNodes))return!0}return!1}("#text"===e.nodeName?[e]:e.childNodes)}});function Me(e){return e.length?Math.min.apply(null,e):1/0}function De(e,r){var t=arguments.length>2&&void 0!==arguments[2]?arguments[2]:8;return e.toPrecision(t)===r.toPrecision(t)}function Se(e){if(e!==Math.floor(e)){var r=/^(\d+)\.(\d*?)(0{5,}|9{5,})\d*$/.exec(""+e);if(r)return""===r[2]?Math.round(e):parseFloat(e.toPrecision(("0"!==r[1]?r[1].length:0)+r[2].length))}return e}function Be(e){return e*Math.PI/180}var Oe=Object.freeze({minArray:Me,maxArray:function(e){return e.length?Math.max.apply(null,e):-1/0},isEqual:De,moreEqual:function(e,r){return e>r||De(e,r,arguments.length>2&&void 0!==arguments[2]?arguments[2]:8)},lessEqual:function(e,r){return e<r||De(e,r,arguments.length>2&&void 0!==arguments[2]?arguments[2]:8)},truncate:function(e){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:3;if(e===Math.floor(e))return""+e;if(e>1){r+=1;for(var t=1;e/Math.pow(10,t++)>=1;)r+=1}return e.toPrecision(r).replace(/\.?0+$/,"")},truncateFraction:Se,truncateString:function(e){for(var r,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:3,n=RegExp("(\\d+\\.\\d{".concat(t,"})(\\d)\\d*"),"g"),a=e;null!==(r=n.exec(e));)parseInt(r[2])>=5&&(r[1]=""+Se(parseFloat(r[1])+1/Math.pow(10,t))),a=a.replace(r[0],r[1]);return a},convertRadian:Be,trianguleASA:function(e,r,t){var n=180-e-r;return[t/Math.sin(Be(n))*Math.sin(Be(e)),t/Math.sin(Be(n))*Math.sin(Be(r))]},offsetAngle:function(e,r){var t=180*Math.atan2(r.y-e.y,r.x-e.x)/Math.PI+90;return t<0&&(t+=360),t},offsetAngleX:function(e,r){return r*Math.sin(Be(e))},offsetAngleY:function(e,r){return r*Math.cos(Be(e))*-1},clampRange:function(e){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,t=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1;return e<r?e=r:e>t&&(e=t),e},nextMultiple:function(e){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,t=arguments.length>2?arguments[2]:void 0;if(e.length>1){var n=Me(e);if(t&&t.length===e.length)for(var a=0;a<t.length;a++)r=Math.max(r,t[a]+e[a]);else t=void 0,r=Math.max(r,n);for(var l=0;l<r;)l+=n;for(var i=t?t[0]:0,o=!1;!o;)for(var s=i+l,u=1;u<e.length;u++){if(s%(e[u]+(t?t[u]:0))!=0){o=!1,l+=n;break}o=!0}return i+l}return e[0]}}),Ne="__ROOT__",Te={ATTRIBUTE:/\s*((\w+:)?\w+="[^"]*)?{~\w+}"?/g,COLLECTION:/\n*\t*{%\w+}\n+/g,LINEBREAK:/\n\n/g},Le={ITEM:/\s*(<(\/)?([?\w]+)[^>]*>)\n?([^<]*)/g,OPENTAG:/\s*>$/,CLOSETAG:/\/>\n*$/},_e=/^(\t+)(.*)$/;function Pe(e,r){for(var t in e)r=r.replace(RegExp("\\t*<<".concat(t,">>[\\w\\W]*<<").concat(t,">>")),"{%".concat(t,"}"));return r}function je(e,r){return"((\\t*##".concat(e,"-").concat(r,"##\\s*\\n)([\\w\\W]*?\\s*\\n)(\\t*##").concat(e,"-").concat(r,"##\\s*\\n))")}function ze(e){return"{".concat((arguments.length>1&&void 0!==arguments[1]?arguments[1]:":")+""+e,"}")}function Ue(e){for(var r,t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"\t",a=[];null!==(r=Le.ITEM.exec(e));)a.push({tag:r[1],closing:!!r[2],tagName:r[3],value:""===r[4].trim()?"":r[4]});for(var l="",i=-1,o=0;o<a.length;o++){var s=a[o],u=i;if(o>0){if(s.closing)i--;else if(u++,!Le.CLOSETAG.exec(s.tag))if(t&&""===s.value.trim()){var h=a[o+1];h&&h.closing&&h.tagName===s.tagName?(s.tag=s.tag.replace(Le.OPENTAG," />"),o++):i++}else i++;var c=!0,g=s.tag.trim().split("\n"),f=Array.isArray(g),v=0;for(g=f?g:g[Symbol.iterator]();;){var b;if(f){if(v>=g.length)break;b=g[v++]}else{if((v=g.next()).done)break;b=v.value}var d=b,m=u+(c?0:1);l+=(m>0?n.repeat(m):"")+d.trim()+"\n",c=!1}}else l+=s.tag+"\n";l+=s.value}return l.trim()}var Xe,He,qe=Object.freeze({formatPlaceholder:ze,replacePlaceholder:function(e,r,t){var n=arguments.length>3&&void 0!==arguments[3]&&arguments[3],a="number"==typeof r?ze(r):r;return e.replace(a,(n?a:"")+t+"\n"+(n?"":a))},pushIndent:function(e,r){var t=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"\t",n=RegExp("^".concat(t.replace("\\","\\\\"),"+"));return V(e.split("\n"),function(e){var a=n.exec(e);return a?e.replace(a[0],t.repeat(r+a[0].length)):e})},replaceIndent:function(e,r,t){if(r>=0){var n=-1;return V(e.split("\n"),function(e){var a=t.exec(e);return a?(-1===n&&(n=a[2].length),a[1]+"\t".repeat(r+(a[2].length-n))+a[3]):e})}return e},replaceTab:function(e){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:4;return r>0?arguments.length>2&&void 0!==arguments[2]&&arguments[2]?V(e.split("\n"),function(e){var t=e.match(_e);return t?" ".repeat(r*t[1].length)+t[2]:e}):e.replace(/\t/g," ".repeat(r)):e},replaceEntity:function(e){return e.replace(/&#(\d+);/g,function(e,r){return String.fromCharCode(parseInt(r))}).replace(/&(?!#?[A-Za-z0-9]{2,};)/g,"&amp;").replace(/\u00A0/g,"&#160;").replace(/\u2002/g,"&#8194;").replace(/\u2003/g,"&#8195;").replace(/\u2009/g,"&#8201;").replace(/\u200C/g,"&#8204;").replace(/\u200D/g,"&#8205;").replace(/\u200E/g,"&#8206;").replace(/\u200F/g,"&#8207;")},replaceCharacter:function(e){return e.replace(/&nbsp;/g,"&#160;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/'/g,"&apos;").replace(/"/g,"&quot;")},parseTemplate:function(e){var r={};return r[Ne]=Pe(function e(t){for(var n,a={},l=/(\t*<<(\w+)>>)\n*[\w\W]*\n*\1/g;null!==(n=l.exec(t));)n[0]=n[0].replace(RegExp("^".concat(n[1],"\\n")),"").replace(RegExp("".concat(n[1],"$")),""),a[n[2]]=Pe(e(n[0]),n[0]);return Object.assign(r,a),a}(e),e),r},createTemplate:function e(t,n){var a=arguments.length>2&&void 0!==arguments[2]&&arguments[2],l=arguments.length>3?arguments[3]:void 0;void 0===l&&(l=Ne);var i=t[l]||"";for(var o in n)if(null!=n[o]){var s=n[o],u="",h="";if(Array.isArray(s))if(h="%",Array.isArray(s[0])){var c=RegExp(je(o,"start")+"([\\w\\W]*?)"+je(o,"end")).exec(i);if(c){for(var g=s[0].length,f=Object.assign({},t),v="",b="",d=0;d<g;d++){var m="".concat(l,"_").concat(o,"_").concat(d);f[m]=c[3],v+=e(f,s[0][d],a,m),b=c[8]+b}i=i.replace(c[1],v).replace(c[6],b)}else u=!1}else if(0===s.length||"object"!==r(s[0]))u=!1;else{for(var p=0;p<s.length;p++)u+=e(t,s[p],a,""+o);u=""!==u&&_(u,"\n")}else h="[&~]",u="boolean"!=typeof s&&""+s;if(u)""!==u&&(i=i.replace(RegExp("{".concat(h+o,"}")),u));else{if(RegExp("{&".concat(o,"}")).test(i))return"";"%"===h&&(i=i.replace(RegExp("[ \\t]*{%".concat(o,"}\\n*")),""))}}return l===Ne&&(i=i.replace(Te.COLLECTION,"\n").replace(Te.LINEBREAK,"\n").trim(),a&&(i=Ue(i))),i.replace(Te.ATTRIBUTE,"")},formatTemplate:Ue});e.settings={},e.system={};var Ge=new Set,Ve=new Map;function We(e){if(Xe){if(e instanceof squared.base.Extension)return Xe.extensionManager.include(e);if("string"==typeof e){e=e.trim();var r=Xe.builtInExtensions[e]||Ye(e);if(r)return Xe.extensionManager.include(r)}}return!1}function $e(t,n){if("object"===r(n)){if(t instanceof squared.base.Extension)return Object.assign(t.options,n),!0;if("string"==typeof t&&Xe){t=t.trim();var a=Xe.extensionManager.retrieve(t)||Array.from(Ge).find(function(e){return e.name===t});if(a)return Object.assign(a.options,n),!0;if(Ve.set(t,n),e.settings.handleExtensionsAsync)return!0}}return!1}function Ye(e){return Xe&&Xe.extensionManager.retrieve(e)}function Ke(){Xe&&Xe.reset()}var Ze={base:{Container:$},color:se,css:we,dom:ve,element:Ie,math:Oe,util:W,xml:qe};e.setFramework=function(r){if(He!==r){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1]?r.cached():r.create();void 0===He&&Object.assign(t.userSettings,e.settings),e.settings=t.userSettings,(Xe=t.application).userSettings=e.settings;for(var n=new Set,a=Array.isArray(i=e.settings.builtInExtensions),l=0,i=a?i:i[Symbol.iterator]();;){var o;if(a){if(l>=i.length)break;o=i[l++]}else{if((l=i.next()).done)break;o=l.value}var s=o;if(Xe.builtInExtensions[s])n.add(Xe.builtInExtensions[s]);else for(var u in Xe.builtInExtensions)u.startsWith("".concat(s,"."))&&n.add(Xe.builtInExtensions[u])}for(var h=Array.isArray(g=n),c=0,g=h?g:g[Symbol.iterator]();;){var f;if(h){if(c>=g.length)break;f=g[c++]}else{if((c=g.next()).done)break;f=c.value}Xe.extensionManager.include(f)}He=r,e.system=r.system}Ke()},e.parseDocument=function r(){for(var t=arguments.length,n=Array(t),a=0;a<t;a++)n[a]=arguments[a];if(Xe&&!Xe.closed){var i;if(e.settings.handleExtensionsAsync){for(var o=Array.isArray(u=Ge),s=0,u=o?u:u[Symbol.iterator]();;){var h;if(o){if(s>=u.length)break;h=u[s++]}else{if((s=u.next()).done)break;h=s.value}Xe.extensionManager.include(h)}var c=Ve.entries(),g=Array.isArray(c),f=0;for(c=g?c:c[Symbol.iterator]();;){var v;if(g){if(f>=c.length)break;v=c[f++]}else{if((f=c.next()).done)break;v=f.value}var b=l(v,2);$e(b[0],b[1])}Ge.clear(),Ve.clear()}return(i=Xe).parseDocument.apply(i,n)}return{then:function(e){Xe?Xe.closed&&confirm("ERROR: Document is closed. Reset and rerun?")&&(Xe.reset(),r.call.apply(r,[null].concat(n)).then(e)):alert("ERROR: Framework not installed.")}}},e.include=We,e.includeAsync=function(r){return!!We(r)||!!(r instanceof squared.base.Extension&&(Ge.add(r),e.settings.handleExtensionsAsync))},e.exclude=function(e){if(Xe){if(e instanceof squared.base.Extension)return Ge.has(e)?(Ge.delete(e),Xe.extensionManager.exclude(e),!0):Xe.extensionManager.exclude(e);if("string"==typeof e){e=e.trim();var r=Xe.extensionManager.retrieve(e);if(r)return Xe.extensionManager.exclude(r)}}return!1},e.configure=$e,e.apply=function(e,t){return e instanceof squared.base.Extension?We(e):"string"==typeof e&&(e=e.trim(),"object"===r(t)?$e(e,t):Ye(e))},e.retrieve=Ye,e.ready=function(){return!!Xe&&!Xe.initialized&&!Xe.closed},e.close=function(){Xe&&!Xe.initialized&&Xe.size&&Xe.finalize()},e.reset=Ke,e.saveAllToDisk=function(){Xe&&!Xe.initialized&&Xe.size&&(Xe.closed||Xe.finalize(),Xe.saveAllToDisk())},e.toString=function(){return Xe?""+Xe:""},e.lib=Ze,Object.defineProperty(e,"__esModule",{value:!0})});
{
"name": "squared",
"version": "0.7.2",
"version": "0.8.0",
"description": "Converts and optimizes HTML and SVG using JavaScript into the various standard Android layouts in XML with support for CSS/SMIL animations. Easiest to use and also most accurate. Compatible with Chrome and Safari.",

@@ -62,3 +62,3 @@ "main": "dist/squared.js",

"rimraf": "^2.6.3",
"rollup": "^1.4.0",
"rollup": "^1.6.0",
"rollup-plugin-babel": "^4.3.2",

@@ -65,0 +65,0 @@ "rollup-plugin-terser": "^4.0.4",

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

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