wcs-core 2.9.0 → 2.12.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/{popper-5777994b.js → popper-8cf375ec.js} +130 -71
- package/dist/cjs/wcs-accordion-content.cjs.entry.js +19 -0
- package/dist/cjs/wcs-accordion-header.cjs.entry.js +16 -0
- package/dist/cjs/wcs-accordion-panel.cjs.entry.js +31 -0
- package/dist/cjs/wcs-accordion.cjs.entry.js +36 -0
- package/dist/cjs/wcs-button.cjs.entry.js +1 -1
- package/dist/cjs/wcs-com-nav-category.cjs.entry.js +1 -1
- package/dist/cjs/wcs-com-nav-submenu.cjs.entry.js +2 -2
- package/dist/cjs/wcs-com-nav.cjs.entry.js +24 -2
- package/dist/cjs/wcs-dropdown.cjs.entry.js +4 -2
- package/dist/cjs/wcs-error_2.cjs.entry.js +6 -9
- package/dist/cjs/wcs-galactic-menu.cjs.entry.js +1 -1
- package/dist/cjs/wcs-horizontal-stepper.cjs.entry.js +13 -10
- package/dist/cjs/wcs-mat-icon.cjs.entry.js +1 -1
- package/dist/cjs/wcs-modal.cjs.entry.js +6 -2
- package/dist/cjs/wcs-select_2.cjs.entry.js +2790 -2577
- package/dist/cjs/wcs-tooltip.cjs.entry.js +11 -4
- package/dist/cjs/wcs.cjs.js +1 -1
- package/dist/collection/collection-manifest.json +4 -0
- package/dist/collection/components/accordion/accordion.js +38 -0
- package/dist/collection/components/accordion-content/accordion-content.css +4 -0
- package/dist/collection/components/accordion-content/accordion-content.js +15 -0
- package/dist/collection/components/accordion-header/accordion-header.js +9 -0
- package/dist/collection/components/accordion-panel/accordion-panel.css +35 -0
- package/dist/collection/components/accordion-panel/accordion-panel.js +89 -0
- package/dist/collection/components/button/button.css +12 -4
- package/dist/collection/components/com-nav/com-nav.css +68 -10
- package/dist/collection/components/com-nav/com-nav.js +34 -5
- package/dist/collection/components/com-nav-category/com-nav-category.css +70 -45
- package/dist/collection/components/com-nav-submenu/com-nav-submenu.css +123 -72
- package/dist/collection/components/com-nav-submenu/com-nav-submenu.js +1 -1
- package/dist/collection/components/dropdown/dropdown.js +3 -1
- package/dist/collection/components/form-field/form-field.js +6 -9
- package/dist/collection/components/horizontal-stepper/horizontal-stepper.js +14 -11
- package/dist/collection/components/input/input.js +1 -1
- package/dist/collection/components/mat-icon/mat-icon.css +3 -1
- package/dist/collection/components/modal/modal.css +16 -29
- package/dist/collection/components/modal/modal.js +25 -4
- package/dist/collection/components/select/select.js +2 -0
- package/dist/collection/components/tooltip/tooltip.js +28 -2
- package/dist/esm/loader.js +1 -1
- package/dist/esm/{popper-5f42e560.js → popper-548df79b.js} +130 -71
- package/dist/esm/wcs-accordion-content.entry.js +15 -0
- package/dist/esm/wcs-accordion-header.entry.js +12 -0
- package/dist/esm/wcs-accordion-panel.entry.js +27 -0
- package/dist/esm/wcs-accordion.entry.js +32 -0
- package/dist/esm/wcs-button.entry.js +1 -1
- package/dist/esm/wcs-com-nav-category.entry.js +1 -1
- package/dist/esm/wcs-com-nav-submenu.entry.js +2 -2
- package/dist/esm/wcs-com-nav.entry.js +25 -3
- package/dist/esm/wcs-dropdown.entry.js +4 -2
- package/dist/esm/wcs-error_2.entry.js +6 -9
- package/dist/esm/wcs-galactic-menu.entry.js +1 -1
- package/dist/esm/wcs-horizontal-stepper.entry.js +13 -10
- package/dist/esm/wcs-mat-icon.entry.js +1 -1
- package/dist/esm/wcs-modal.entry.js +6 -2
- package/dist/esm/wcs-select_2.entry.js +2790 -2577
- package/dist/esm/wcs-tooltip.entry.js +11 -4
- package/dist/esm/wcs.js +1 -1
- package/dist/types/components/accordion/accordion.d.ts +12 -0
- package/dist/types/components/accordion-content/accordion-content.d.ts +3 -0
- package/dist/types/components/accordion-header/accordion-header.d.ts +3 -0
- package/dist/types/components/accordion-panel/accordion-panel.d.ts +8 -0
- package/dist/types/components/com-nav/com-nav.d.ts +7 -0
- package/dist/types/components/input/input-interface.d.ts +1 -1
- package/dist/types/components/modal/modal.d.ts +4 -0
- package/dist/types/components/tooltip/tooltip.d.ts +12 -0
- package/dist/types/components.d.ts +72 -0
- package/dist/wcs/p-055c20de.entry.js +1 -0
- package/dist/wcs/p-0bb5f03a.entry.js +1 -0
- package/dist/wcs/p-19e6600c.entry.js +15 -0
- package/dist/wcs/p-2507b398.entry.js +1 -0
- package/dist/wcs/p-4f15e5f6.entry.js +1 -0
- package/dist/wcs/{p-ecbe5165.entry.js → p-600d4d99.entry.js} +2 -2
- package/dist/wcs/{p-22813c8e.entry.js → p-66e74651.entry.js} +1 -1
- package/dist/wcs/p-706d195a.entry.js +1 -0
- package/dist/wcs/{p-4e9e226d.entry.js → p-b69840d6.entry.js} +1 -1
- package/dist/wcs/p-bcf381a2.entry.js +1 -0
- package/dist/wcs/p-c295cfca.entry.js +1 -0
- package/dist/wcs/p-cf77e1d9.entry.js +1 -0
- package/dist/wcs/p-d45c7c63.entry.js +1 -0
- package/dist/wcs/p-df5baf36.entry.js +1 -0
- package/dist/wcs/p-e4fdcd1f.js +1 -0
- package/dist/wcs/{p-ff6d0dfd.entry.js → p-f00ef24c.entry.js} +1 -1
- package/dist/wcs/p-f43213f5.entry.js +1 -0
- package/dist/wcs/wcs.esm.js +1 -1
- package/package.json +9 -5
- package/CHANGELOG.md +0 -269
- package/dist/wcs/p-08a7e84d.entry.js +0 -1
- package/dist/wcs/p-1f5aed36.entry.js +0 -1
- package/dist/wcs/p-7c26f650.entry.js +0 -1
- package/dist/wcs/p-8864a491.entry.js +0 -1
- package/dist/wcs/p-94a31f64.entry.js +0 -1
- package/dist/wcs/p-b5ffbea8.entry.js +0 -1
- package/dist/wcs/p-c7d6d3e1.entry.js +0 -15
- package/dist/wcs/p-d3c9a644.js +0 -1
- package/dist/wcs/p-db68379f.entry.js +0 -1
package/dist/cjs/loader.cjs.js
CHANGED
|
@@ -14,7 +14,7 @@ const patchEsm = () => {
|
|
|
14
14
|
const defineCustomElements = (win, options) => {
|
|
15
15
|
if (typeof window === 'undefined') return Promise.resolve();
|
|
16
16
|
return patchEsm().then(() => {
|
|
17
|
-
return index.bootstrapLazy([["wcs-editable-field.cjs",[[1,"wcs-editable-field",{"type":[1],"label":[1],"readonly":[4],"value":[1032],"validateFn":[16],"formatFn":[16],"errorMsg":[1,"error-msg"],"currentState":[32],"isError":[32]},[[8,"click","onWindowClickEvent"]]]]],["wcs-grid.cjs",[[1,"wcs-grid",{"serverMode":[4,"server-mode"],"data":[16],"loading":[4],"selectionConfig":[1,"selection-config"],"selectedItems":[8,"selected-items"],"wcsGridPaginationId":[1,"wcs-grid-pagination-id"],"rowIdPath":[1,"row-id-path"],"columns":[32],"paginationEl":[32],"rows":[32]},[[0,"wcsHiddenChange","onHiddenColumnChange"],[0,"wcsSortChange","sortChangeEventHandler"],[0,"wcsGridPaginationChange","paginationChangeEventHandler"],[8,"wcsGridPaginationChange","paginationChangeEventHandlerOutside"]]]]],["wcs-grid-pagination.cjs",[[1,"wcs-grid-pagination",{"availablePageSizes":[16],"currentPage":[2,"current-page"],"pageSize":[2,"page-size"],"itemsCount":[2,"items-count"],"pageCount":[2,"page-count"]}]]],["wcs-horizontal-stepper.cjs",[[1,"wcs-horizontal-stepper",{"currentStep":[1026,"current-step"],"steps":[16],"mode":[1],"checkOnComplete":[4,"check-on-complete"],"buttonMode":[32],"internalCurrentStep":[32],"previous":[64],"next":[64]}]]],["wcs-dropdown.cjs",[[1,"wcs-dropdown",{"noArrow":[4,"no-arrow"],"mode":[1],"shape":[1],"disabled":[4],"placement":[1],"expanded":[32]},[[8,"click","onWindowClickEvent"],[0,"wcsDropdownItemClick","dropdownItemClick"]]]]],["wcs-galactic-menu.cjs",[[1,"wcs-galactic-menu",{"text":[1],"showPopoverMenu":[32]},[[8,"click","onWindowClickEvent"]]]]],["wcs-input.cjs",[[1,"wcs-input",{"fireFocusEvents":[4,"fire-focus-events"],"accept":[1],"autocapitalize":[1],"autocomplete":[1],"autocorrect":[1],"autofocus":[4],"clearInput":[4,"clear-input"],"clearOnEdit":[4,"clear-on-edit"],"debounce":[2],"prefixLabel":[1,"prefix-label"],"suffixLabel":[1,"suffix-label"],"disabled":[4],"enterkeyhint":[1],"icon":[1],"inputmode":[1],"max":[1],"maxlength":[2],"min":[1],"minlength":[2],"multiple":[4],"name":[1],"pattern":[1],"placeholder":[1],"readonly":[4],"required":[4],"spellcheck":[4],"state":[513],"step":[1],"size":[2],"type":[1],"value":[1032],"hasFocus":[32],"setFocus":[64],"setBlur":[64],"getInputElement":[64]}]]],["wcs-
|
|
17
|
+
return index.bootstrapLazy([["wcs-editable-field.cjs",[[1,"wcs-editable-field",{"type":[1],"label":[1],"readonly":[4],"value":[1032],"validateFn":[16],"formatFn":[16],"errorMsg":[1,"error-msg"],"currentState":[32],"isError":[32]},[[8,"click","onWindowClickEvent"]]]]],["wcs-grid.cjs",[[1,"wcs-grid",{"serverMode":[4,"server-mode"],"data":[16],"loading":[4],"selectionConfig":[1,"selection-config"],"selectedItems":[8,"selected-items"],"wcsGridPaginationId":[1,"wcs-grid-pagination-id"],"rowIdPath":[1,"row-id-path"],"columns":[32],"paginationEl":[32],"rows":[32]},[[0,"wcsHiddenChange","onHiddenColumnChange"],[0,"wcsSortChange","sortChangeEventHandler"],[0,"wcsGridPaginationChange","paginationChangeEventHandler"],[8,"wcsGridPaginationChange","paginationChangeEventHandlerOutside"]]]]],["wcs-grid-pagination.cjs",[[1,"wcs-grid-pagination",{"availablePageSizes":[16],"currentPage":[2,"current-page"],"pageSize":[2,"page-size"],"itemsCount":[2,"items-count"],"pageCount":[2,"page-count"]}]]],["wcs-horizontal-stepper.cjs",[[1,"wcs-horizontal-stepper",{"currentStep":[1026,"current-step"],"steps":[16],"mode":[1],"checkOnComplete":[4,"check-on-complete"],"buttonMode":[32],"internalCurrentStep":[32],"previous":[64],"next":[64]}]]],["wcs-modal.cjs",[[4,"wcs-modal",{"withoutBackdrop":[516,"without-backdrop"],"show":[516],"showCloseButton":[516,"show-close-button"],"size":[1],"hideActions":[516,"hide-actions"]},[[4,"keydown","onKeyDown"]]]]],["wcs-dropdown.cjs",[[1,"wcs-dropdown",{"noArrow":[4,"no-arrow"],"mode":[1],"shape":[1],"disabled":[4],"placement":[1],"expanded":[32]},[[8,"click","onWindowClickEvent"],[0,"wcsDropdownItemClick","dropdownItemClick"]]]]],["wcs-galactic-menu.cjs",[[1,"wcs-galactic-menu",{"text":[1],"showPopoverMenu":[32]},[[8,"click","onWindowClickEvent"]]]]],["wcs-input.cjs",[[1,"wcs-input",{"fireFocusEvents":[4,"fire-focus-events"],"accept":[1],"autocapitalize":[1],"autocomplete":[1],"autocorrect":[1],"autofocus":[4],"clearInput":[4,"clear-input"],"clearOnEdit":[4,"clear-on-edit"],"debounce":[2],"prefixLabel":[1,"prefix-label"],"suffixLabel":[1,"suffix-label"],"disabled":[4],"enterkeyhint":[1],"icon":[1],"inputmode":[1],"max":[1],"maxlength":[2],"min":[1],"minlength":[2],"multiple":[4],"name":[1],"pattern":[1],"placeholder":[1],"readonly":[4],"required":[4],"spellcheck":[4],"state":[513],"step":[1],"size":[2],"type":[1],"value":[1032],"hasFocus":[32],"setFocus":[64],"setBlur":[64],"getInputElement":[64]}]]],["wcs-textarea.cjs",[[1,"wcs-textarea",{"fireFocusEvents":[4,"fire-focus-events"],"autocapitalize":[1],"autofocus":[4],"clearOnEdit":[1028,"clear-on-edit"],"debounce":[2],"disabled":[4],"icon":[1],"inputmode":[1],"enterkeyhint":[1],"maxlength":[2],"minlength":[2],"name":[1],"placeholder":[1],"readonly":[4],"required":[4],"spellcheck":[4],"state":[513],"cols":[2],"rows":[2],"wrap":[1],"autoGrow":[4,"auto-grow"],"value":[1025],"hasFocus":[32],"fitContent":[64],"setFocus":[64],"setBlur":[64],"getInputElement":[64]}]]],["wcs-accordion.cjs",[[1,"wcs-accordion",null,[[0,"wcsOpenChange","wcsOpenChangeHandler"]]]]],["wcs-accordion-content.cjs",[[1,"wcs-accordion-content"]]],["wcs-accordion-header.cjs",[[1,"wcs-accordion-header"]]],["wcs-accordion-panel.cjs",[[1,"wcs-accordion-panel",{"open":[1540],"close":[64]}]]],["wcs-action-bar.cjs",[[1,"wcs-action-bar",{"gutter":[4],"hasTabs":[32]}]]],["wcs-app.cjs",[[1,"wcs-app"]]],["wcs-badge.cjs",[[1,"wcs-badge",{"shape":[1],"color":[1]}]]],["wcs-card.cjs",[[1,"wcs-card",{"mode":[1537]}]]],["wcs-card-body.cjs",[[1,"wcs-card-body"]]],["wcs-com-nav.cjs",[[1,"wcs-com-nav",{"appName":[1,"app-name"],"mobileMenuOpen":[32],"currentActiveSizing":[32]}]]],["wcs-com-nav-category.cjs",[[1,"wcs-com-nav-category",{"label":[1],"categoryOpen":[32],"close":[64],"open":[64]},[[8,"click","onWindowClickEvent"],[8,"wcsCategoryOpened","onSubmenuOpened"]]]]],["wcs-com-nav-submenu.cjs",[[1,"wcs-com-nav-submenu",{"label":[1],"panelTitle":[1,"panel-title"],"panelDescription":[1,"panel-description"],"menuOpen":[32],"close":[64],"open":[64]},[[8,"click","onWindowClickEvent"],[8,"wcsSubmenuOpened","onSubmenuOpened"],[0,"wcsCategoryItemClicked","wcsCategoryItemClickedHandler"]]]]],["wcs-divider.cjs",[[1,"wcs-divider"]]],["wcs-dropdown-divider.cjs",[[1,"wcs-dropdown-divider"]]],["wcs-dropdown-header.cjs",[[1,"wcs-dropdown-header"]]],["wcs-dropdown-item.cjs",[[4,"wcs-dropdown-item",null,[[1,"mousedown","onMouseDown"]]]]],["wcs-field.cjs",[[1,"wcs-field"]]],["wcs-field-content.cjs",[[1,"wcs-field-content"]]],["wcs-field-label.cjs",[[1,"wcs-field-label"]]],["wcs-footer.cjs",[[1,"wcs-footer"]]],["wcs-galactic.cjs",[[1,"wcs-galactic",{"text":[1],"show":[32]}]]],["wcs-grid-column.cjs",[[1,"wcs-grid-column",{"path":[1],"name":[1],"sort":[4],"sortFn":[16],"formatter":[16],"sortOrder":[1025,"sort-order"],"width":[1],"customCells":[4,"custom-cells"],"hidden":[4]}]]],["wcs-grid-custom-cell.cjs",[[1,"wcs-grid-custom-cell",{"columnId":[1,"column-id"],"rowId":[8,"row-id"]}]]],["wcs-header.cjs",[[1,"wcs-header"]]],["wcs-hint.cjs",[[1,"wcs-hint",{"small":[1540]}]]],["wcs-icon.cjs",[[0,"wcs-icon",{"icon":[1],"size":[1]}]]],["wcs-label.cjs",[[1,"wcs-label",{"required":[516]}]]],["wcs-list-item.cjs",[[1,"wcs-list-item",{"activated":[1028]}]]],["wcs-list-item-properties.cjs",[[1,"wcs-list-item-properties"]]],["wcs-list-item-property.cjs",[[1,"wcs-list-item-property"]]],["wcs-nav.cjs",[[1,"wcs-nav"]]],["wcs-nav-item.cjs",[[4,"wcs-nav-item",{"text":[513],"href":[513]}]]],["wcs-progress-radial.cjs",[[1,"wcs-progress-radial",{"size":[2],"showLabel":[4,"show-label"],"value":[2]}]]],["wcs-radio-group.cjs",[[1,"wcs-radio-group",{"value":[8],"name":[520],"mode":[513]},[[0,"wcsRadioClick","selectedOptionChanged"]]]]],["wcs-switch.cjs",[[1,"wcs-switch",{"name":[1],"checked":[516],"labelAlignment":[513,"label-alignment"],"disabled":[4]}]]],["wcs-tab.cjs",[[1,"wcs-tab",{"header":[513],"itemKey":[8,"item-key"]}]]],["wcs-tabs.cjs",[[1,"wcs-tabs",{"align":[513],"selectedIndex":[2,"selected-index"],"selectedKey":[8,"selected-key"],"headersOnly":[4,"headers-only"],"gutter":[4],"headers":[32],"currentActiveTabIndex":[32]},[[0,"tabLoaded","onTabLoaded"]]]]],["wcs-tooltip.cjs",[[1,"wcs-tooltip",{"for":[1],"position":[513],"interactive":[4],"maxWidth":[8,"max-width"],"delay":[2],"duration":[2],"trigger":[1],"theme":[1],"content":[1],"hide":[64],"show":[64],"disable":[64],"enable":[64]}]]],["wcs-progress-bar.cjs",[[1,"wcs-progress-bar",{"small":[4],"showLabel":[4,"show-label"],"value":[2]}]]],["wcs-radio.cjs",[[1,"wcs-radio",{"mode":[513],"value":[1544],"label":[1537],"checked":[1540],"disabled":[1028]}]]],["wcs-select_2.cjs",[[4,"wcs-select-option",{"disabled":[1540],"selected":[1540],"value":[8],"chipColor":[1,"chip-color"],"chipBackgroundColor":[1,"chip-background-color"],"multiple":[1540]},[[1,"mousedown","onMouseDown"]]],[1,"wcs-select",{"value":[1032],"placeholder":[1537],"disabled":[1028],"multiple":[516],"chips":[516],"name":[1],"compareWith":[16],"expanded":[32],"hasLoaded":[32],"displayText":[32],"focused":[32],"overlayDirection":[32],"open":[64],"close":[64]},[[1,"mousedown","onMouseDown"],[8,"click","onWindowClickEvent"],[0,"wcsSelectOptionClick","selectedOptionChanged"]]]]],["wcs-error_2.cjs",[[1,"wcs-error"],[1,"wcs-form-field",{"isError":[1540,"is-error"],"hasPrefix":[32],"hasSuffix":[32],"spiedElement":[32]}]]],["wcs-spinner.cjs",[[1,"wcs-spinner",{"mode":[513]}]]],["wcs-button.cjs",[[1,"wcs-button",{"type":[1025],"href":[1],"disabled":[516],"ripple":[4],"shape":[513],"mode":[513]},[[0,"click","onClick"]]]]],["wcs-checkbox.cjs",[[1,"wcs-checkbox",{"name":[1],"indeterminate":[1540],"checked":[1540],"labelAlignment":[1537,"label-alignment"],"disabled":[4]}]]],["wcs-mat-icon.cjs",[[1,"wcs-mat-icon",{"icon":[1],"size":[1],"family":[1],"familyFile":[32],"familyClass":[32]}]]]], options);
|
|
18
18
|
});
|
|
19
19
|
};
|
|
20
20
|
|
|
@@ -156,7 +156,10 @@ function getBasePlacement(placement) {
|
|
|
156
156
|
return placement.split('-')[0];
|
|
157
157
|
}
|
|
158
158
|
|
|
159
|
-
var
|
|
159
|
+
var max = Math.max;
|
|
160
|
+
var min = Math.min;
|
|
161
|
+
var round = Math.round;
|
|
162
|
+
|
|
160
163
|
function getBoundingClientRect(element, includeScale) {
|
|
161
164
|
if (includeScale === void 0) {
|
|
162
165
|
includeScale = false;
|
|
@@ -167,20 +170,28 @@ function getBoundingClientRect(element, includeScale) {
|
|
|
167
170
|
var scaleY = 1;
|
|
168
171
|
|
|
169
172
|
if (isHTMLElement(element) && includeScale) {
|
|
173
|
+
var offsetHeight = element.offsetHeight;
|
|
174
|
+
var offsetWidth = element.offsetWidth; // Do not attempt to divide by 0, otherwise we get `Infinity` as scale
|
|
170
175
|
// Fallback to 1 in case both values are `0`
|
|
171
|
-
|
|
172
|
-
|
|
176
|
+
|
|
177
|
+
if (offsetWidth > 0) {
|
|
178
|
+
scaleX = round(rect.width) / offsetWidth || 1;
|
|
179
|
+
}
|
|
180
|
+
|
|
181
|
+
if (offsetHeight > 0) {
|
|
182
|
+
scaleY = round(rect.height) / offsetHeight || 1;
|
|
183
|
+
}
|
|
173
184
|
}
|
|
174
185
|
|
|
175
186
|
return {
|
|
176
|
-
width:
|
|
177
|
-
height:
|
|
178
|
-
top:
|
|
179
|
-
right:
|
|
180
|
-
bottom:
|
|
181
|
-
left:
|
|
182
|
-
x:
|
|
183
|
-
y:
|
|
187
|
+
width: rect.width / scaleX,
|
|
188
|
+
height: rect.height / scaleY,
|
|
189
|
+
top: rect.top / scaleY,
|
|
190
|
+
right: rect.right / scaleX,
|
|
191
|
+
bottom: rect.bottom / scaleY,
|
|
192
|
+
left: rect.left / scaleX,
|
|
193
|
+
x: rect.left / scaleX,
|
|
194
|
+
y: rect.top / scaleY
|
|
184
195
|
};
|
|
185
196
|
}
|
|
186
197
|
|
|
@@ -289,6 +300,10 @@ function getContainingBlock(element) {
|
|
|
289
300
|
|
|
290
301
|
var currentNode = getParentNode(element);
|
|
291
302
|
|
|
303
|
+
if (isShadowRoot(currentNode)) {
|
|
304
|
+
currentNode = currentNode.host;
|
|
305
|
+
}
|
|
306
|
+
|
|
292
307
|
while (isHTMLElement(currentNode) && ['html', 'body'].indexOf(getNodeName(currentNode)) < 0) {
|
|
293
308
|
var css = getComputedStyle(currentNode); // This is non-exhaustive but covers the most common CSS properties that
|
|
294
309
|
// create a containing block.
|
|
@@ -325,13 +340,13 @@ function getMainAxisFromPlacement(placement) {
|
|
|
325
340
|
return ['top', 'bottom'].indexOf(placement) >= 0 ? 'x' : 'y';
|
|
326
341
|
}
|
|
327
342
|
|
|
328
|
-
var max = Math.max;
|
|
329
|
-
var min = Math.min;
|
|
330
|
-
var round = Math.round;
|
|
331
|
-
|
|
332
343
|
function within(min$1, value, max$1) {
|
|
333
344
|
return max(min$1, min(value, max$1));
|
|
334
345
|
}
|
|
346
|
+
function withinMaxClamp(min, value, max) {
|
|
347
|
+
var v = within(min, value, max);
|
|
348
|
+
return v > max ? max : v;
|
|
349
|
+
}
|
|
335
350
|
|
|
336
351
|
function getFreshSideObject() {
|
|
337
352
|
return {
|
|
@@ -435,6 +450,10 @@ const arrow$1 = {
|
|
|
435
450
|
requiresIfExists: ['preventOverflow']
|
|
436
451
|
};
|
|
437
452
|
|
|
453
|
+
function getVariation(placement) {
|
|
454
|
+
return placement.split('-')[1];
|
|
455
|
+
}
|
|
456
|
+
|
|
438
457
|
var unsetSides = {
|
|
439
458
|
top: 'auto',
|
|
440
459
|
right: 'auto',
|
|
@@ -450,8 +469,8 @@ function roundOffsetsByDPR(_ref) {
|
|
|
450
469
|
var win = window;
|
|
451
470
|
var dpr = win.devicePixelRatio || 1;
|
|
452
471
|
return {
|
|
453
|
-
x: round(
|
|
454
|
-
y: round(
|
|
472
|
+
x: round(x * dpr) / dpr || 0,
|
|
473
|
+
y: round(y * dpr) / dpr || 0
|
|
455
474
|
};
|
|
456
475
|
}
|
|
457
476
|
|
|
@@ -461,18 +480,28 @@ function mapToStyles(_ref2) {
|
|
|
461
480
|
var popper = _ref2.popper,
|
|
462
481
|
popperRect = _ref2.popperRect,
|
|
463
482
|
placement = _ref2.placement,
|
|
483
|
+
variation = _ref2.variation,
|
|
464
484
|
offsets = _ref2.offsets,
|
|
465
485
|
position = _ref2.position,
|
|
466
486
|
gpuAcceleration = _ref2.gpuAcceleration,
|
|
467
487
|
adaptive = _ref2.adaptive,
|
|
468
|
-
roundOffsets = _ref2.roundOffsets
|
|
469
|
-
|
|
470
|
-
var
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
488
|
+
roundOffsets = _ref2.roundOffsets,
|
|
489
|
+
isFixed = _ref2.isFixed;
|
|
490
|
+
var _offsets$x = offsets.x,
|
|
491
|
+
x = _offsets$x === void 0 ? 0 : _offsets$x,
|
|
492
|
+
_offsets$y = offsets.y,
|
|
493
|
+
y = _offsets$y === void 0 ? 0 : _offsets$y;
|
|
494
|
+
|
|
495
|
+
var _ref3 = typeof roundOffsets === 'function' ? roundOffsets({
|
|
496
|
+
x: x,
|
|
497
|
+
y: y
|
|
498
|
+
}) : {
|
|
499
|
+
x: x,
|
|
500
|
+
y: y
|
|
501
|
+
};
|
|
475
502
|
|
|
503
|
+
x = _ref3.x;
|
|
504
|
+
y = _ref3.y;
|
|
476
505
|
var hasX = offsets.hasOwnProperty('x');
|
|
477
506
|
var hasY = offsets.hasOwnProperty('y');
|
|
478
507
|
var sideX = left;
|
|
@@ -487,7 +516,7 @@ function mapToStyles(_ref2) {
|
|
|
487
516
|
if (offsetParent === getWindow(popper)) {
|
|
488
517
|
offsetParent = getDocumentElement(popper);
|
|
489
518
|
|
|
490
|
-
if (getComputedStyle(offsetParent).position !== 'static') {
|
|
519
|
+
if (getComputedStyle(offsetParent).position !== 'static' && position === 'absolute') {
|
|
491
520
|
heightProp = 'scrollHeight';
|
|
492
521
|
widthProp = 'scrollWidth';
|
|
493
522
|
}
|
|
@@ -496,17 +525,19 @@ function mapToStyles(_ref2) {
|
|
|
496
525
|
|
|
497
526
|
offsetParent = offsetParent;
|
|
498
527
|
|
|
499
|
-
if (placement === top) {
|
|
500
|
-
sideY = bottom;
|
|
501
|
-
|
|
502
|
-
|
|
528
|
+
if (placement === top || (placement === left || placement === right) && variation === end) {
|
|
529
|
+
sideY = bottom;
|
|
530
|
+
var offsetY = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.height : // $FlowFixMe[prop-missing]
|
|
531
|
+
offsetParent[heightProp];
|
|
532
|
+
y -= offsetY - popperRect.height;
|
|
503
533
|
y *= gpuAcceleration ? 1 : -1;
|
|
504
534
|
}
|
|
505
535
|
|
|
506
|
-
if (placement === left) {
|
|
507
|
-
sideX = right;
|
|
508
|
-
|
|
509
|
-
|
|
536
|
+
if (placement === left || (placement === top || placement === bottom) && variation === end) {
|
|
537
|
+
sideX = right;
|
|
538
|
+
var offsetX = isFixed && offsetParent === win && win.visualViewport ? win.visualViewport.width : // $FlowFixMe[prop-missing]
|
|
539
|
+
offsetParent[widthProp];
|
|
540
|
+
x -= offsetX - popperRect.width;
|
|
510
541
|
x *= gpuAcceleration ? 1 : -1;
|
|
511
542
|
}
|
|
512
543
|
}
|
|
@@ -515,18 +546,29 @@ function mapToStyles(_ref2) {
|
|
|
515
546
|
position: position
|
|
516
547
|
}, adaptive && unsetSides);
|
|
517
548
|
|
|
549
|
+
var _ref4 = roundOffsets === true ? roundOffsetsByDPR({
|
|
550
|
+
x: x,
|
|
551
|
+
y: y
|
|
552
|
+
}) : {
|
|
553
|
+
x: x,
|
|
554
|
+
y: y
|
|
555
|
+
};
|
|
556
|
+
|
|
557
|
+
x = _ref4.x;
|
|
558
|
+
y = _ref4.y;
|
|
559
|
+
|
|
518
560
|
if (gpuAcceleration) {
|
|
519
561
|
var _Object$assign;
|
|
520
562
|
|
|
521
|
-
return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1)
|
|
563
|
+
return Object.assign({}, commonStyles, (_Object$assign = {}, _Object$assign[sideY] = hasY ? '0' : '', _Object$assign[sideX] = hasX ? '0' : '', _Object$assign.transform = (win.devicePixelRatio || 1) <= 1 ? "translate(" + x + "px, " + y + "px)" : "translate3d(" + x + "px, " + y + "px, 0)", _Object$assign));
|
|
522
564
|
}
|
|
523
565
|
|
|
524
566
|
return Object.assign({}, commonStyles, (_Object$assign2 = {}, _Object$assign2[sideY] = hasY ? y + "px" : '', _Object$assign2[sideX] = hasX ? x + "px" : '', _Object$assign2.transform = '', _Object$assign2));
|
|
525
567
|
}
|
|
526
568
|
|
|
527
|
-
function computeStyles(
|
|
528
|
-
var state =
|
|
529
|
-
options =
|
|
569
|
+
function computeStyles(_ref5) {
|
|
570
|
+
var state = _ref5.state,
|
|
571
|
+
options = _ref5.options;
|
|
530
572
|
var _options$gpuAccelerat = options.gpuAcceleration,
|
|
531
573
|
gpuAcceleration = _options$gpuAccelerat === void 0 ? true : _options$gpuAccelerat,
|
|
532
574
|
_options$adaptive = options.adaptive,
|
|
@@ -536,9 +578,11 @@ function computeStyles(_ref4) {
|
|
|
536
578
|
|
|
537
579
|
var commonStyles = {
|
|
538
580
|
placement: getBasePlacement(state.placement),
|
|
581
|
+
variation: getVariation(state.placement),
|
|
539
582
|
popper: state.elements.popper,
|
|
540
583
|
popperRect: state.rects.popper,
|
|
541
|
-
gpuAcceleration: gpuAcceleration
|
|
584
|
+
gpuAcceleration: gpuAcceleration,
|
|
585
|
+
isFixed: state.options.strategy === 'fixed'
|
|
542
586
|
};
|
|
543
587
|
|
|
544
588
|
if (state.modifiersData.popperOffsets != null) {
|
|
@@ -796,7 +840,7 @@ function getInnerBoundingClientRect(element) {
|
|
|
796
840
|
}
|
|
797
841
|
|
|
798
842
|
function getClientRectFromMixedType(element, clippingParent) {
|
|
799
|
-
return clippingParent === viewport ? rectToClientRect(getViewportRect(element)) :
|
|
843
|
+
return clippingParent === viewport ? rectToClientRect(getViewportRect(element)) : isElement(clippingParent) ? getInnerBoundingClientRect(clippingParent) : rectToClientRect(getDocumentRect(getDocumentElement(element)));
|
|
800
844
|
} // A "clipping parent" is an overflowable container with the characteristic of
|
|
801
845
|
// clipping (or hiding) overflowing elements with a position different from
|
|
802
846
|
// `initial`
|
|
@@ -838,10 +882,6 @@ function getClippingRect(element, boundary, rootBoundary) {
|
|
|
838
882
|
return clippingRect;
|
|
839
883
|
}
|
|
840
884
|
|
|
841
|
-
function getVariation(placement) {
|
|
842
|
-
return placement.split('-')[1];
|
|
843
|
-
}
|
|
844
|
-
|
|
845
885
|
function computeOffsets(_ref) {
|
|
846
886
|
var reference = _ref.reference,
|
|
847
887
|
element = _ref.element,
|
|
@@ -927,11 +967,10 @@ function detectOverflow(state, options) {
|
|
|
927
967
|
padding = _options$padding === void 0 ? 0 : _options$padding;
|
|
928
968
|
var paddingObject = mergePaddingObject(typeof padding !== 'number' ? padding : expandToHashMap(padding, basePlacements));
|
|
929
969
|
var altContext = elementContext === popper ? reference : popper;
|
|
930
|
-
var referenceElement = state.elements.reference;
|
|
931
970
|
var popperRect = state.rects.popper;
|
|
932
971
|
var element = state.elements[altBoundary ? altContext : elementContext];
|
|
933
972
|
var clippingClientRect = getClippingRect(isElement(element) ? element : element.contextElement || getDocumentElement(state.elements.popper), boundary, rootBoundary);
|
|
934
|
-
var referenceClientRect = getBoundingClientRect(
|
|
973
|
+
var referenceClientRect = getBoundingClientRect(state.elements.reference);
|
|
935
974
|
var popperOffsets = computeOffsets({
|
|
936
975
|
reference: referenceClientRect,
|
|
937
976
|
element: popperRect,
|
|
@@ -1314,6 +1353,14 @@ function preventOverflow(_ref) {
|
|
|
1314
1353
|
var tetherOffsetValue = typeof tetherOffset === 'function' ? tetherOffset(Object.assign({}, state.rects, {
|
|
1315
1354
|
placement: state.placement
|
|
1316
1355
|
})) : tetherOffset;
|
|
1356
|
+
var normalizedTetherOffsetValue = typeof tetherOffsetValue === 'number' ? {
|
|
1357
|
+
mainAxis: tetherOffsetValue,
|
|
1358
|
+
altAxis: tetherOffsetValue
|
|
1359
|
+
} : Object.assign({
|
|
1360
|
+
mainAxis: 0,
|
|
1361
|
+
altAxis: 0
|
|
1362
|
+
}, tetherOffsetValue);
|
|
1363
|
+
var offsetModifierState = state.modifiersData.offset ? state.modifiersData.offset[state.placement] : null;
|
|
1317
1364
|
var data = {
|
|
1318
1365
|
x: 0,
|
|
1319
1366
|
y: 0
|
|
@@ -1323,13 +1370,15 @@ function preventOverflow(_ref) {
|
|
|
1323
1370
|
return;
|
|
1324
1371
|
}
|
|
1325
1372
|
|
|
1326
|
-
if (checkMainAxis
|
|
1373
|
+
if (checkMainAxis) {
|
|
1374
|
+
var _offsetModifierState$;
|
|
1375
|
+
|
|
1327
1376
|
var mainSide = mainAxis === 'y' ? top : left;
|
|
1328
1377
|
var altSide = mainAxis === 'y' ? bottom : right;
|
|
1329
1378
|
var len = mainAxis === 'y' ? 'height' : 'width';
|
|
1330
1379
|
var offset = popperOffsets[mainAxis];
|
|
1331
|
-
var min$1 =
|
|
1332
|
-
var max$1 =
|
|
1380
|
+
var min$1 = offset + overflow[mainSide];
|
|
1381
|
+
var max$1 = offset - overflow[altSide];
|
|
1333
1382
|
var additive = tether ? -popperRect[len] / 2 : 0;
|
|
1334
1383
|
var minLen = variation === start ? referenceRect[len] : popperRect[len];
|
|
1335
1384
|
var maxLen = variation === start ? -popperRect[len] : -referenceRect[len]; // We need to include the arrow in the calculation so the arrow doesn't go
|
|
@@ -1349,36 +1398,45 @@ function preventOverflow(_ref) {
|
|
|
1349
1398
|
// width or height)
|
|
1350
1399
|
|
|
1351
1400
|
var arrowLen = within(0, referenceRect[len], arrowRect[len]);
|
|
1352
|
-
var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin -
|
|
1353
|
-
var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax +
|
|
1401
|
+
var minOffset = isBasePlacement ? referenceRect[len] / 2 - additive - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis : minLen - arrowLen - arrowPaddingMin - normalizedTetherOffsetValue.mainAxis;
|
|
1402
|
+
var maxOffset = isBasePlacement ? -referenceRect[len] / 2 + additive + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis : maxLen + arrowLen + arrowPaddingMax + normalizedTetherOffsetValue.mainAxis;
|
|
1354
1403
|
var arrowOffsetParent = state.elements.arrow && getOffsetParent(state.elements.arrow);
|
|
1355
1404
|
var clientOffset = arrowOffsetParent ? mainAxis === 'y' ? arrowOffsetParent.clientTop || 0 : arrowOffsetParent.clientLeft || 0 : 0;
|
|
1356
|
-
var offsetModifierValue =
|
|
1357
|
-
var tetherMin =
|
|
1358
|
-
var tetherMax =
|
|
1405
|
+
var offsetModifierValue = (_offsetModifierState$ = offsetModifierState == null ? void 0 : offsetModifierState[mainAxis]) != null ? _offsetModifierState$ : 0;
|
|
1406
|
+
var tetherMin = offset + minOffset - offsetModifierValue - clientOffset;
|
|
1407
|
+
var tetherMax = offset + maxOffset - offsetModifierValue;
|
|
1408
|
+
var preventedOffset = within(tether ? min(min$1, tetherMin) : min$1, offset, tether ? max(max$1, tetherMax) : max$1);
|
|
1409
|
+
popperOffsets[mainAxis] = preventedOffset;
|
|
1410
|
+
data[mainAxis] = preventedOffset - offset;
|
|
1411
|
+
}
|
|
1359
1412
|
|
|
1360
|
-
|
|
1361
|
-
|
|
1362
|
-
popperOffsets[mainAxis] = preventedOffset;
|
|
1363
|
-
data[mainAxis] = preventedOffset - offset;
|
|
1364
|
-
}
|
|
1413
|
+
if (checkAltAxis) {
|
|
1414
|
+
var _offsetModifierState$2;
|
|
1365
1415
|
|
|
1366
|
-
|
|
1367
|
-
var _mainSide = mainAxis === 'x' ? top : left;
|
|
1416
|
+
var _mainSide = mainAxis === 'x' ? top : left;
|
|
1368
1417
|
|
|
1369
|
-
|
|
1418
|
+
var _altSide = mainAxis === 'x' ? bottom : right;
|
|
1370
1419
|
|
|
1371
|
-
|
|
1420
|
+
var _offset = popperOffsets[altAxis];
|
|
1372
1421
|
|
|
1373
|
-
|
|
1422
|
+
var _len = altAxis === 'y' ? 'height' : 'width';
|
|
1374
1423
|
|
|
1375
|
-
|
|
1424
|
+
var _min = _offset + overflow[_mainSide];
|
|
1376
1425
|
|
|
1377
|
-
|
|
1426
|
+
var _max = _offset - overflow[_altSide];
|
|
1378
1427
|
|
|
1379
|
-
|
|
1380
|
-
|
|
1381
|
-
|
|
1428
|
+
var isOriginSide = [top, left].indexOf(basePlacement) !== -1;
|
|
1429
|
+
|
|
1430
|
+
var _offsetModifierValue = (_offsetModifierState$2 = offsetModifierState == null ? void 0 : offsetModifierState[altAxis]) != null ? _offsetModifierState$2 : 0;
|
|
1431
|
+
|
|
1432
|
+
var _tetherMin = isOriginSide ? _min : _offset - referenceRect[_len] - popperRect[_len] - _offsetModifierValue + normalizedTetherOffsetValue.altAxis;
|
|
1433
|
+
|
|
1434
|
+
var _tetherMax = isOriginSide ? _offset + referenceRect[_len] + popperRect[_len] - _offsetModifierValue - normalizedTetherOffsetValue.altAxis : _max;
|
|
1435
|
+
|
|
1436
|
+
var _preventedOffset = tether && isOriginSide ? withinMaxClamp(_tetherMin, _offset, _tetherMax) : within(tether ? _tetherMin : _min, _offset, tether ? _tetherMax : _max);
|
|
1437
|
+
|
|
1438
|
+
popperOffsets[altAxis] = _preventedOffset;
|
|
1439
|
+
data[altAxis] = _preventedOffset - _offset;
|
|
1382
1440
|
}
|
|
1383
1441
|
|
|
1384
1442
|
state.modifiersData[name] = data;
|
|
@@ -1410,8 +1468,8 @@ function getNodeScroll(node) {
|
|
|
1410
1468
|
|
|
1411
1469
|
function isElementScaled(element) {
|
|
1412
1470
|
var rect = element.getBoundingClientRect();
|
|
1413
|
-
var scaleX = rect.width / element.offsetWidth || 1;
|
|
1414
|
-
var scaleY = rect.height / element.offsetHeight || 1;
|
|
1471
|
+
var scaleX = round(rect.width) / element.offsetWidth || 1;
|
|
1472
|
+
var scaleY = round(rect.height) / element.offsetHeight || 1;
|
|
1415
1473
|
return scaleX !== 1 || scaleY !== 1;
|
|
1416
1474
|
} // Returns the composite rect of an element relative to its offsetParent.
|
|
1417
1475
|
// Composite means it takes into account transforms as well as layout.
|
|
@@ -1579,7 +1637,8 @@ function popperGenerator(generatorOptions) {
|
|
|
1579
1637
|
var isDestroyed = false;
|
|
1580
1638
|
var instance = {
|
|
1581
1639
|
state: state,
|
|
1582
|
-
setOptions: function setOptions(
|
|
1640
|
+
setOptions: function setOptions(setOptionsAction) {
|
|
1641
|
+
var options = typeof setOptionsAction === 'function' ? setOptionsAction(state.options) : setOptionsAction;
|
|
1583
1642
|
cleanupModifierEffects();
|
|
1584
1643
|
state.options = Object.assign({}, defaultOptions, state.options, options);
|
|
1585
1644
|
state.scrollParents = {
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
+
|
|
5
|
+
const index = require('./index-3cb9d725.js');
|
|
6
|
+
|
|
7
|
+
const accordionContentCss = ":host{margin:calc(3 * var(--wcs-base-margin));display:block}";
|
|
8
|
+
|
|
9
|
+
let AccordionContent = class {
|
|
10
|
+
constructor(hostRef) {
|
|
11
|
+
index.registerInstance(this, hostRef);
|
|
12
|
+
}
|
|
13
|
+
render() {
|
|
14
|
+
return (index.h(index.Host, { slot: "content" }, index.h("slot", null)));
|
|
15
|
+
}
|
|
16
|
+
};
|
|
17
|
+
AccordionContent.style = accordionContentCss;
|
|
18
|
+
|
|
19
|
+
exports.wcs_accordion_content = AccordionContent;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
+
|
|
5
|
+
const index = require('./index-3cb9d725.js');
|
|
6
|
+
|
|
7
|
+
let AccordionHeader = class {
|
|
8
|
+
constructor(hostRef) {
|
|
9
|
+
index.registerInstance(this, hostRef);
|
|
10
|
+
}
|
|
11
|
+
render() {
|
|
12
|
+
return (index.h(index.Host, { slot: "header" }, index.h("slot", null)));
|
|
13
|
+
}
|
|
14
|
+
};
|
|
15
|
+
|
|
16
|
+
exports.wcs_accordion_header = AccordionHeader;
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
+
|
|
5
|
+
const index = require('./index-3cb9d725.js');
|
|
6
|
+
const selectArrow = require('./select-arrow-76ccf86d.js');
|
|
7
|
+
|
|
8
|
+
const accordionPanelCss = ":host{display:flex;flex-direction:column;cursor:pointer;margin-bottom:16px}:host .header{display:flex;align-items:center;justify-content:space-between;padding:14px 24px;border-radius:7px;font-weight:500;font-size:16px;color:var(--wcs-primary);background-color:var(--wcs-light)}:host .header-action{display:flex;align-items:center;user-select:none}:host .header-action .arrow{fill:var(--wcs-primary)}:host .content{display:none}:host([open]){margin-bottom:0}:host([open]) .content{display:block}";
|
|
9
|
+
|
|
10
|
+
let AccordionPanel = class {
|
|
11
|
+
constructor(hostRef) {
|
|
12
|
+
index.registerInstance(this, hostRef);
|
|
13
|
+
this.wcsOpenChange = index.createEvent(this, "wcsOpenChange", 7);
|
|
14
|
+
this.open = false;
|
|
15
|
+
}
|
|
16
|
+
openChange(newValue) {
|
|
17
|
+
this.wcsOpenChange.emit(newValue);
|
|
18
|
+
}
|
|
19
|
+
async close() {
|
|
20
|
+
this.open = false;
|
|
21
|
+
}
|
|
22
|
+
render() {
|
|
23
|
+
return (index.h(index.Host, null, index.h("div", { class: "header", onClick: () => this.open = !this.open }, index.h("slot", { name: "header" }), index.h("div", { class: "header-action" }, index.h("span", null, this.open ? 'Fermez' : 'Ouvrez'), index.h(selectArrow.SelectArrow, { up: this.open }))), index.h("div", { class: "content" }, index.h("slot", { name: "content" }))));
|
|
24
|
+
}
|
|
25
|
+
static get watchers() { return {
|
|
26
|
+
"open": ["openChange"]
|
|
27
|
+
}; }
|
|
28
|
+
};
|
|
29
|
+
AccordionPanel.style = accordionPanelCss;
|
|
30
|
+
|
|
31
|
+
exports.wcs_accordion_panel = AccordionPanel;
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
+
|
|
5
|
+
const index = require('./index-3cb9d725.js');
|
|
6
|
+
|
|
7
|
+
let Accordion = class {
|
|
8
|
+
constructor(hostRef) {
|
|
9
|
+
index.registerInstance(this, hostRef);
|
|
10
|
+
this.accordionPanels = [];
|
|
11
|
+
}
|
|
12
|
+
componentWillLoad() {
|
|
13
|
+
this.accordionPanels = this.getAllAccordionPanelsFromHostElement();
|
|
14
|
+
}
|
|
15
|
+
wcsOpenChangeHandler(event) {
|
|
16
|
+
if (event.detail) {
|
|
17
|
+
this.closeAllAccordionsExcept(event.target);
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
render() {
|
|
21
|
+
return (index.h(index.Host, null, index.h("slot", null)));
|
|
22
|
+
}
|
|
23
|
+
getAllAccordionPanelsFromHostElement() {
|
|
24
|
+
return Array.from(this.el.children)
|
|
25
|
+
.filter(el => el.tagName === 'WCS-ACCORDION-PANEL');
|
|
26
|
+
}
|
|
27
|
+
/**
|
|
28
|
+
* Close all accordion panels except the one that match the eventTarget reference
|
|
29
|
+
*/
|
|
30
|
+
closeAllAccordionsExcept(eventTarget) {
|
|
31
|
+
this.accordionPanels.filter(a => a !== eventTarget).forEach(a => a.close());
|
|
32
|
+
}
|
|
33
|
+
get el() { return index.getElement(this); }
|
|
34
|
+
};
|
|
35
|
+
|
|
36
|
+
exports.wcs_accordion = Accordion;
|
|
@@ -6,7 +6,7 @@ const index = require('./index-3cb9d725.js');
|
|
|
6
6
|
const helpers = require('./helpers-6abce594.js');
|
|
7
7
|
const component = require('./component-fc28ed16.js');
|
|
8
8
|
|
|
9
|
-
const buttonCss = "@keyframes mdc-ripple-fg-radius-in{from{animation-timing-function:cubic-bezier(0.4, 0, 0.2, 1);transform:translate(var(--mdc-ripple-fg-translate-start, 0)) scale(1)}to{transform:translate(var(--mdc-ripple-fg-translate-end, 0)) scale(var(--mdc-ripple-fg-scale, 1))}}@keyframes mdc-ripple-fg-opacity-in{from{animation-timing-function:linear;opacity:0}to{opacity:var(--mdc-ripple-fg-opacity, 0)}}@keyframes mdc-ripple-fg-opacity-out{from{animation-timing-function:linear;opacity:var(--mdc-ripple-fg-opacity, 0)}to{opacity:0}}.mdc-ripple-surface{--mdc-ripple-fg-size:0;--mdc-ripple-left:0;--mdc-ripple-top:0;--mdc-ripple-fg-scale:1;--mdc-ripple-fg-translate-end:0;--mdc-ripple-fg-translate-start:0;-webkit-tap-highlight-color:rgba(0, 0, 0, 0);will-change:transform, opacity;position:relative;outline:none;overflow:hidden}.mdc-ripple-surface::before,.mdc-ripple-surface::after{position:absolute;border-radius:50%;opacity:0;pointer-events:none;content:\"\"}.mdc-ripple-surface::before{transition:opacity 15ms linear, background-color 15ms linear;z-index:1;z-index:var(--mdc-ripple-z-index, 1)}.mdc-ripple-surface::after{z-index:0;z-index:var(--mdc-ripple-z-index, 0)}.mdc-ripple-surface.mdc-ripple-upgraded::before{transform:scale(var(--mdc-ripple-fg-scale, 1))}.mdc-ripple-surface.mdc-ripple-upgraded::after{top:0;left:0;transform:scale(0);transform-origin:center center}.mdc-ripple-surface.mdc-ripple-upgraded--unbounded::after{top:var(--mdc-ripple-top, 0);left:var(--mdc-ripple-left, 0)}.mdc-ripple-surface.mdc-ripple-upgraded--foreground-activation::after{animation:mdc-ripple-fg-radius-in 225ms forwards, mdc-ripple-fg-opacity-in 75ms forwards}.mdc-ripple-surface.mdc-ripple-upgraded--foreground-deactivation::after{animation:mdc-ripple-fg-opacity-out 150ms;transform:translate(var(--mdc-ripple-fg-translate-end, 0)) scale(var(--mdc-ripple-fg-scale, 1))}.mdc-ripple-surface::before,.mdc-ripple-surface::after{top:calc(50% - 100%);left:calc(50% - 100%);width:200%;height:200%}.mdc-ripple-surface.mdc-ripple-upgraded::after{width:var(--mdc-ripple-fg-size, 100%);height:var(--mdc-ripple-fg-size, 100%)}.mdc-ripple-surface[data-mdc-ripple-is-unbounded],.mdc-ripple-upgraded--unbounded{overflow:visible}.mdc-ripple-surface[data-mdc-ripple-is-unbounded]::before,.mdc-ripple-surface[data-mdc-ripple-is-unbounded]::after,.mdc-ripple-upgraded--unbounded::before,.mdc-ripple-upgraded--unbounded::after{top:calc(50% - 50%);left:calc(50% - 50%);width:100%;height:100%}.mdc-ripple-surface[data-mdc-ripple-is-unbounded].mdc-ripple-upgraded::before,.mdc-ripple-surface[data-mdc-ripple-is-unbounded].mdc-ripple-upgraded::after,.mdc-ripple-upgraded--unbounded.mdc-ripple-upgraded::before,.mdc-ripple-upgraded--unbounded.mdc-ripple-upgraded::after{top:var(--mdc-ripple-top, calc(50% - 50%));left:var(--mdc-ripple-left, calc(50% - 50%));width:var(--mdc-ripple-fg-size, 100%);height:var(--mdc-ripple-fg-size, 100%)}.mdc-ripple-surface[data-mdc-ripple-is-unbounded].mdc-ripple-upgraded::after,.mdc-ripple-upgraded--unbounded.mdc-ripple-upgraded::after{width:var(--mdc-ripple-fg-size, 100%);height:var(--mdc-ripple-fg-size, 100%)}.mdc-ripple-surface::before,.mdc-ripple-surface::after{background-color:#000;background-color:var(--mdc-ripple-color, #000)}.mdc-ripple-surface:hover::before,.mdc-ripple-surface.mdc-ripple-surface--hover::before{opacity:0.04;opacity:var(--mdc-ripple-hover-opacity, 0.04)}.mdc-ripple-surface.mdc-ripple-upgraded--background-focused::before,.mdc-ripple-surface:not(.mdc-ripple-upgraded):focus::before{transition-duration:75ms;opacity:0.12;opacity:var(--mdc-ripple-focus-opacity, 0.12)}.mdc-ripple-surface:not(.mdc-ripple-upgraded)::after{transition:opacity 150ms linear}.mdc-ripple-surface:not(.mdc-ripple-upgraded):active::after{transition-duration:75ms;opacity:0.12;opacity:var(--mdc-ripple-press-opacity, 0.12)}.mdc-ripple-surface.mdc-ripple-upgraded{--mdc-ripple-fg-opacity:var(--mdc-ripple-press-opacity, 0.12)}:host{display:inline-block;--wcs-button-padding:calc(var(--wcs-padding) / 2) var(--wcs-padding);--wcs-button-color:var(--wcs-contrast, var(--wcs-white, white));--wcs-button-background-color:var(--wcs-base, var(--wcs-primary, #0088CE));--wcs-button-ripple-color:var(--wcs-contrast, var(--wcs-white, white));--wcs-button-border-radius:var(--wcs-border-radius);--wcs-button-border-color:var(--wcs-base)}:host([mode=clear]){--wcs-button-border-color:transparent}:host([mode=clear]) .wcs-inner-button{box-shadow:none}:host([mode=clear]),:host([mode=stroked]){--wcs-button-color:var(--wcs-base);--wcs-button-background-color:transparent}:host([mode=clear]) .wcs-inner-button::before,:host([mode=clear]) .wcs-inner-button::after,:host([mode=stroked]) .wcs-inner-button::before,:host([mode=stroked]) .wcs-inner-button::after{--wcs-button-ripple-color:var(--wcs-base)}:host([shape=small]){--wcs-button-padding:2px 16px}:host([shape=round]){--wcs-button-padding:0;--wcs-button-border-radius:50%}:host([shape=round]) .wcs-inner-button{display:inline-flex;align-items:center;justify-content:center;min-width:42px;min-height:42px}:host([shape=square]){--wcs-button-padding:0}:host([shape=square]) .wcs-inner-button{display:inline-flex;align-items:center;justify-content:center;min-width:42px;min-height:42px}:host([shape=normal]){--wcs-button-padding:calc(var(--wcs-padding) / 2 + 1px) calc(var(--wcs-padding))}:host([mode=stroked]) .wcs-inner-button{box-shadow:inset 0 0 0 1px var(--wcs-button-border-color)}:host([disabled]){--wcs-button-color:var(--wcs-text-disabled);--wcs-button-background-color:var(--wcs-light)}:host([disabled]) .wcs-inner-button{--wcs-button-border-color:var(--wcs-light);opacity:1;cursor:default;pointer-events:none}:host([disabled]):host([mode=clear]),:host([disabled]):host([disabled]){--wcs-button-background-color:transparent}.wcs-inner-button{--mdc-ripple-fg-size:0;--mdc-ripple-left:0;--mdc-ripple-top:0;--mdc-ripple-fg-scale:1;--mdc-ripple-fg-translate-end:0;--mdc-ripple-fg-translate-start:0;-webkit-tap-highlight-color:rgba(0, 0, 0, 0);will-change:transform, opacity;display:flex;align-content:center;font-family:var(--wcs-font-sans-serif);background-color:var(--wcs-button-background-color);color:var(--wcs-button-color);padding:var(--wcs-button-padding);border-radius:var(--wcs-button-border-radius);border:none;overflow:hidden;outline:0;text-transform:none;margin:0;cursor:pointer;font-weight:500;text-align:center;white-space:nowrap;vertical-align:middle;user-select:none;font-size:1rem;line-height:1.5;transition:color 175ms ease-in-out, background-color 175ms ease-in-out, box-shadow 175ms cubic-bezier(0.4, 0, 0.2, 1)}.wcs-inner-button::before,.wcs-inner-button::after{position:absolute;border-radius:50%;opacity:0;pointer-events:none;content:\"\"}.wcs-inner-button::before{transition:opacity 15ms linear, background-color 15ms linear;z-index:1;z-index:var(--mdc-ripple-z-index, 1)}.wcs-inner-button::after{z-index:0;z-index:var(--mdc-ripple-z-index, 0)}.wcs-inner-button.mdc-ripple-upgraded::before{transform:scale(var(--mdc-ripple-fg-scale, 1))}.wcs-inner-button.mdc-ripple-upgraded::after{top:0;left:0;transform:scale(0);transform-origin:center center}.wcs-inner-button.mdc-ripple-upgraded--unbounded::after{top:var(--mdc-ripple-top, 0);left:var(--mdc-ripple-left, 0)}.wcs-inner-button.mdc-ripple-upgraded--foreground-activation::after{animation:mdc-ripple-fg-radius-in 225ms forwards, mdc-ripple-fg-opacity-in 75ms forwards}.wcs-inner-button.mdc-ripple-upgraded--foreground-deactivation::after{animation:mdc-ripple-fg-opacity-out 150ms;transform:translate(var(--mdc-ripple-fg-translate-end, 0)) scale(var(--mdc-ripple-fg-scale, 1))}.wcs-inner-button::before,.wcs-inner-button::after{top:calc(50% - 100%);left:calc(50% - 100%);width:200%;height:200%}.wcs-inner-button.mdc-ripple-upgraded::after{width:var(--mdc-ripple-fg-size, 100%);height:var(--mdc-ripple-fg-size, 100%)}.wcs-inner-button:hover::before,.wcs-inner-button.mdc-ripple-surface--hover::before{opacity:0.1;opacity:var(--mdc-ripple-hover-opacity, 0.1)}.wcs-inner-button.mdc-ripple-upgraded--background-focused::before,.wcs-inner-button:not(.mdc-ripple-upgraded):focus::before{transition-duration:75ms;opacity:0.2;opacity:var(--mdc-ripple-focus-opacity, 0.2)}.wcs-inner-button:not(.mdc-ripple-upgraded)::after{transition:opacity 150ms linear}.wcs-inner-button:not(.mdc-ripple-upgraded):active::after{transition-duration:75ms;opacity:0.3;opacity:var(--mdc-ripple-press-opacity, 0.3)}.wcs-inner-button.mdc-ripple-upgraded{--mdc-ripple-fg-opacity:var(--mdc-ripple-press-opacity, 0.3)}.wcs-inner-button::before,.wcs-inner-button::after{background-color:white;background-color:var(--mdc-ripple-color, white)}.wcs-inner-button::before,.wcs-inner-button::after{background-color:var(--wcs-button-ripple-color)}.wcs-inner-button:focus{box-shadow:0 1px 1px 0 rgba(0, 0, 0, 0.14), 0 2px 1px -1px rgba(0, 0, 0, 0.12), 0 1px 3px 0 rgba(0, 0, 0, 0.2)}.wcs-inner-button:hover{box-shadow:0 2px 2px 0 rgba(0, 0, 0, 0.14), 0 3px 1px -2px rgba(0, 0, 0, 0.12), 0 1px 5px 0 rgba(0, 0, 0, 0.2)}a{text-decoration:none}button::-moz-focus-inner,a::-moz-focus-inner{border:0}";
|
|
9
|
+
const buttonCss = "@keyframes mdc-ripple-fg-radius-in{from{animation-timing-function:cubic-bezier(0.4, 0, 0.2, 1);transform:translate(var(--mdc-ripple-fg-translate-start, 0)) scale(1)}to{transform:translate(var(--mdc-ripple-fg-translate-end, 0)) scale(var(--mdc-ripple-fg-scale, 1))}}@keyframes mdc-ripple-fg-opacity-in{from{animation-timing-function:linear;opacity:0}to{opacity:var(--mdc-ripple-fg-opacity, 0)}}@keyframes mdc-ripple-fg-opacity-out{from{animation-timing-function:linear;opacity:var(--mdc-ripple-fg-opacity, 0)}to{opacity:0}}.mdc-ripple-surface{--mdc-ripple-fg-size:0;--mdc-ripple-left:0;--mdc-ripple-top:0;--mdc-ripple-fg-scale:1;--mdc-ripple-fg-translate-end:0;--mdc-ripple-fg-translate-start:0;-webkit-tap-highlight-color:rgba(0, 0, 0, 0);will-change:transform, opacity;position:relative;outline:none;overflow:hidden}.mdc-ripple-surface::before,.mdc-ripple-surface::after{position:absolute;border-radius:50%;opacity:0;pointer-events:none;content:\"\"}.mdc-ripple-surface::before{transition:opacity 15ms linear, background-color 15ms linear;z-index:1;z-index:var(--mdc-ripple-z-index, 1)}.mdc-ripple-surface::after{z-index:0;z-index:var(--mdc-ripple-z-index, 0)}.mdc-ripple-surface.mdc-ripple-upgraded::before{transform:scale(var(--mdc-ripple-fg-scale, 1))}.mdc-ripple-surface.mdc-ripple-upgraded::after{top:0;left:0;transform:scale(0);transform-origin:center center}.mdc-ripple-surface.mdc-ripple-upgraded--unbounded::after{top:var(--mdc-ripple-top, 0);left:var(--mdc-ripple-left, 0)}.mdc-ripple-surface.mdc-ripple-upgraded--foreground-activation::after{animation:mdc-ripple-fg-radius-in 225ms forwards, mdc-ripple-fg-opacity-in 75ms forwards}.mdc-ripple-surface.mdc-ripple-upgraded--foreground-deactivation::after{animation:mdc-ripple-fg-opacity-out 150ms;transform:translate(var(--mdc-ripple-fg-translate-end, 0)) scale(var(--mdc-ripple-fg-scale, 1))}.mdc-ripple-surface::before,.mdc-ripple-surface::after{top:calc(50% - 100%);left:calc(50% - 100%);width:200%;height:200%}.mdc-ripple-surface.mdc-ripple-upgraded::after{width:var(--mdc-ripple-fg-size, 100%);height:var(--mdc-ripple-fg-size, 100%)}.mdc-ripple-surface[data-mdc-ripple-is-unbounded],.mdc-ripple-upgraded--unbounded{overflow:visible}.mdc-ripple-surface[data-mdc-ripple-is-unbounded]::before,.mdc-ripple-surface[data-mdc-ripple-is-unbounded]::after,.mdc-ripple-upgraded--unbounded::before,.mdc-ripple-upgraded--unbounded::after{top:calc(50% - 50%);left:calc(50% - 50%);width:100%;height:100%}.mdc-ripple-surface[data-mdc-ripple-is-unbounded].mdc-ripple-upgraded::before,.mdc-ripple-surface[data-mdc-ripple-is-unbounded].mdc-ripple-upgraded::after,.mdc-ripple-upgraded--unbounded.mdc-ripple-upgraded::before,.mdc-ripple-upgraded--unbounded.mdc-ripple-upgraded::after{top:var(--mdc-ripple-top, calc(50% - 50%));left:var(--mdc-ripple-left, calc(50% - 50%));width:var(--mdc-ripple-fg-size, 100%);height:var(--mdc-ripple-fg-size, 100%)}.mdc-ripple-surface[data-mdc-ripple-is-unbounded].mdc-ripple-upgraded::after,.mdc-ripple-upgraded--unbounded.mdc-ripple-upgraded::after{width:var(--mdc-ripple-fg-size, 100%);height:var(--mdc-ripple-fg-size, 100%)}.mdc-ripple-surface::before,.mdc-ripple-surface::after{background-color:#000;background-color:var(--mdc-ripple-color, #000)}.mdc-ripple-surface:hover::before,.mdc-ripple-surface.mdc-ripple-surface--hover::before{opacity:0.04;opacity:var(--mdc-ripple-hover-opacity, 0.04)}.mdc-ripple-surface.mdc-ripple-upgraded--background-focused::before,.mdc-ripple-surface:not(.mdc-ripple-upgraded):focus::before{transition-duration:75ms;opacity:0.12;opacity:var(--mdc-ripple-focus-opacity, 0.12)}.mdc-ripple-surface:not(.mdc-ripple-upgraded)::after{transition:opacity 150ms linear}.mdc-ripple-surface:not(.mdc-ripple-upgraded):active::after{transition-duration:75ms;opacity:0.12;opacity:var(--mdc-ripple-press-opacity, 0.12)}.mdc-ripple-surface.mdc-ripple-upgraded{--mdc-ripple-fg-opacity:var(--mdc-ripple-press-opacity, 0.12)}:host{display:inline-block;--wcs-button-padding:calc(var(--wcs-padding) / 2) var(--wcs-padding);--wcs-button-color:var(--wcs-contrast, var(--wcs-white, white));--wcs-button-background-color:var(--wcs-base, var(--wcs-primary, #0088CE));--wcs-button-ripple-color:var(--wcs-contrast, var(--wcs-white, white));--wcs-button-border-radius:var(--wcs-border-radius);--wcs-button-border-color:var(--wcs-base)}:host([mode=clear]){--wcs-button-border-color:transparent}:host([mode=clear]) .wcs-inner-button{box-shadow:none}:host([mode=clear]),:host([mode=stroked]){--wcs-button-color:var(--wcs-base);--wcs-button-background-color:transparent}:host([mode=clear]) .wcs-inner-button::before,:host([mode=clear]) .wcs-inner-button::after,:host([mode=stroked]) .wcs-inner-button::before,:host([mode=stroked]) .wcs-inner-button::after{--wcs-button-ripple-color:var(--wcs-base)}:host([shape=small]){--wcs-button-padding:2px 16px}:host([shape=small]) .wcs-inner-button{min-width:var(--wcs-button-min-width, unset);min-height:var(--wcs-button-min-height, unset)}:host([shape=round]){--wcs-button-padding:0;--wcs-button-border-radius:50%}:host([shape=round]) .wcs-inner-button{display:inline-flex;align-items:center;justify-content:center;min-width:var(--wcs-button-min-width, 42px);min-height:var(--wcs-button-min-height, 42px)}:host([shape=square]){--wcs-button-padding:0}:host([shape=square]) .wcs-inner-button{display:inline-flex;align-items:center;justify-content:center;min-width:var(--wcs-button-min-width, 42px);min-height:var(--wcs-button-min-height, 42px)}:host([shape=normal]){--wcs-button-padding:calc(var(--wcs-padding) / 2 + 1px) calc(var(--wcs-padding))}:host([shape=normal]) .wcs-inner-button{min-width:var(--wcs-button-min-width, unset);min-height:var(--wcs-button-min-height, unset)}:host([mode=stroked]) .wcs-inner-button{box-shadow:inset 0 0 0 1px var(--wcs-button-border-color)}:host([disabled]){--wcs-button-color:var(--wcs-text-disabled);--wcs-button-background-color:var(--wcs-light)}:host([disabled]) .wcs-inner-button{--wcs-button-border-color:var(--wcs-light);opacity:1;cursor:default;pointer-events:none}:host([disabled]):host([mode=clear]),:host([disabled]):host([disabled]){--wcs-button-background-color:transparent}.wcs-inner-button{--mdc-ripple-fg-size:0;--mdc-ripple-left:0;--mdc-ripple-top:0;--mdc-ripple-fg-scale:1;--mdc-ripple-fg-translate-end:0;--mdc-ripple-fg-translate-start:0;-webkit-tap-highlight-color:rgba(0, 0, 0, 0);will-change:transform, opacity;display:flex;align-content:center;font-family:var(--wcs-font-sans-serif);background-color:var(--wcs-button-background-color);color:var(--wcs-button-color);padding:var(--wcs-button-padding);border-radius:var(--wcs-button-border-radius);border:none;overflow:hidden;outline:0;text-transform:none;margin:0;cursor:pointer;font-weight:500;text-align:center;white-space:nowrap;vertical-align:middle;user-select:none;font-size:1rem;line-height:1.5;transition:color 175ms ease-in-out, background-color 175ms ease-in-out, box-shadow 175ms cubic-bezier(0.4, 0, 0.2, 1)}.wcs-inner-button::before,.wcs-inner-button::after{position:absolute;border-radius:50%;opacity:0;pointer-events:none;content:\"\"}.wcs-inner-button::before{transition:opacity 15ms linear, background-color 15ms linear;z-index:1;z-index:var(--mdc-ripple-z-index, 1)}.wcs-inner-button::after{z-index:0;z-index:var(--mdc-ripple-z-index, 0)}.wcs-inner-button.mdc-ripple-upgraded::before{transform:scale(var(--mdc-ripple-fg-scale, 1))}.wcs-inner-button.mdc-ripple-upgraded::after{top:0;left:0;transform:scale(0);transform-origin:center center}.wcs-inner-button.mdc-ripple-upgraded--unbounded::after{top:var(--mdc-ripple-top, 0);left:var(--mdc-ripple-left, 0)}.wcs-inner-button.mdc-ripple-upgraded--foreground-activation::after{animation:mdc-ripple-fg-radius-in 225ms forwards, mdc-ripple-fg-opacity-in 75ms forwards}.wcs-inner-button.mdc-ripple-upgraded--foreground-deactivation::after{animation:mdc-ripple-fg-opacity-out 150ms;transform:translate(var(--mdc-ripple-fg-translate-end, 0)) scale(var(--mdc-ripple-fg-scale, 1))}.wcs-inner-button::before,.wcs-inner-button::after{top:calc(50% - 100%);left:calc(50% - 100%);width:200%;height:200%}.wcs-inner-button.mdc-ripple-upgraded::after{width:var(--mdc-ripple-fg-size, 100%);height:var(--mdc-ripple-fg-size, 100%)}.wcs-inner-button:hover::before,.wcs-inner-button.mdc-ripple-surface--hover::before{opacity:0.1;opacity:var(--mdc-ripple-hover-opacity, 0.1)}.wcs-inner-button.mdc-ripple-upgraded--background-focused::before,.wcs-inner-button:not(.mdc-ripple-upgraded):focus::before{transition-duration:75ms;opacity:0.2;opacity:var(--mdc-ripple-focus-opacity, 0.2)}.wcs-inner-button:not(.mdc-ripple-upgraded)::after{transition:opacity 150ms linear}.wcs-inner-button:not(.mdc-ripple-upgraded):active::after{transition-duration:75ms;opacity:0.3;opacity:var(--mdc-ripple-press-opacity, 0.3)}.wcs-inner-button.mdc-ripple-upgraded{--mdc-ripple-fg-opacity:var(--mdc-ripple-press-opacity, 0.3)}.wcs-inner-button::before,.wcs-inner-button::after{background-color:white;background-color:var(--mdc-ripple-color, white)}.wcs-inner-button::before,.wcs-inner-button::after{background-color:var(--wcs-button-ripple-color)}.wcs-inner-button:focus{box-shadow:0 1px 1px 0 rgba(0, 0, 0, 0.14), 0 2px 1px -1px rgba(0, 0, 0, 0.12), 0 1px 3px 0 rgba(0, 0, 0, 0.2)}.wcs-inner-button:hover{box-shadow:0 2px 2px 0 rgba(0, 0, 0, 0.14), 0 3px 1px -2px rgba(0, 0, 0, 0.12), 0 1px 5px 0 rgba(0, 0, 0, 0.2)}a{text-decoration:none}button::-moz-focus-inner,a::-moz-focus-inner{border:0}";
|
|
10
10
|
|
|
11
11
|
let Button = class {
|
|
12
12
|
constructor(hostRef) {
|
|
@@ -4,7 +4,7 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
4
4
|
|
|
5
5
|
const index = require('./index-3cb9d725.js');
|
|
6
6
|
|
|
7
|
-
const comNavCategoryCss = ":host{display:block}:host .item-container:not([data-open]){display:none}:host .label:after{font-family:icons;padding-left:var(--wcs-base-margin);font-size:0.6rem;content:\"\\f107\";line-height:1;box-sizing:border-box}:host .label-container{cursor:pointer;user-select:none;display:flex;align-items:center}:host .label-container[data-open]:after{position:absolute;left:calc(50% + var(--wcs-com-content-max-width) / 8 - 0.5625rem);z-index:2;display:block;width:1.125rem;height:1.125rem;content:\"\";background-color:var(--wcs-primary);transform:rotate(45deg)}:host .item-container[data-open]{position:absolute;left:calc(50% + var(--wcs-com-content-max-width) / 8);top:0;right:0;padding:50px 0 50px 50px;background-blend-mode:multiply;background-color:rgba(0, 0, 0, 0.15);box-sizing:border-box;height:100%;display:flex;flex-direction:column;align-items:start}:host .item-container[data-open] ::slotted(a:not(:first-child)){margin-top:24px}:host .item-container[data-open] ::slotted(a)
|
|
7
|
+
const comNavCategoryCss = ":host{display:block;padding-bottom:var(--wcs-padding)}:host .label-container{display:block;padding-left:calc(9 * var(--wcs-base-margin));color:var(--wcs-gray)}:host ::slotted(a):after{font-family:icons;padding-left:var(--wcs-base-margin);font-size:0.6rem;content:\"\\f107\";line-height:1;box-sizing:border-box}:host ::slotted(a){display:block;cursor:pointer;text-decoration:none;font-size:16px;color:var(--wcs-gray);padding-left:calc(12 * var(--wcs-base-margin));padding-top:calc(1.5 * var(--wcs-base-margin));padding-bottom:calc(1.5 * var(--wcs-base-margin))}@media screen and (min-width: 576px){:host{padding-bottom:unset}:host .item-container:not([data-open]){display:none}:host .label:after{font-family:icons;padding-left:var(--wcs-base-margin);font-size:0.6rem;content:\"\\f107\";line-height:1;box-sizing:border-box}:host .label-container{cursor:pointer;user-select:none;display:flex;align-items:center;padding-left:unset;color:var(--wcs-white)}:host .label-container[data-open]:after{position:absolute;left:calc(50% + var(--wcs-com-content-max-width) / 8 - 0.5625rem);z-index:2;display:block;width:1.125rem;height:1.125rem;content:\"\";background-color:var(--wcs-primary);transform:rotate(45deg)}:host .item-container[data-open]{position:absolute;left:calc(50% + var(--wcs-com-content-max-width) / 8);top:0;right:0;padding:50px 0 50px 50px;background-blend-mode:multiply;background-color:rgba(0, 0, 0, 0.15);box-sizing:border-box;height:100%;display:flex;flex-direction:column;align-items:start}:host .item-container[data-open] ::slotted(a:not(:first-child)){margin-top:24px}:host .item-container[data-open] ::slotted(a){display:unset;color:var(--wcs-white);padding-left:unset;padding-top:unset;padding-bottom:unset}}";
|
|
8
8
|
|
|
9
9
|
let ComNavCategory = class {
|
|
10
10
|
constructor(hostRef) {
|
|
@@ -4,7 +4,7 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
4
4
|
|
|
5
5
|
const index = require('./index-3cb9d725.js');
|
|
6
6
|
|
|
7
|
-
const comNavSubmenuCss = ":host{display:block;
|
|
7
|
+
const comNavSubmenuCss = ":host{display:block;padding-bottom:var(--wcs-padding)}:host .menu-button{display:block;font-weight:500;padding-left:calc(3 * var(--wcs-base-margin))}:host .arrow-icon{display:none}:host .arrow-container{display:none}:host .label{text-transform:uppercase;font-size:16px;cursor:unset;font-weight:500;color:var(--wcs-gray);text-decoration:none}:host .drawer{display:contents}:host .drawer-container{display:contents}:host .drawer-description{display:none}:host .menu-items ::slotted(a):after{font-family:icons;padding-left:var(--wcs-base-margin);font-size:0.6rem;content:\"\\f107\";line-height:1;box-sizing:border-box}:host .menu-items ::slotted(a){user-select:none;cursor:pointer;text-decoration:none;font-size:16px;color:var(--wcs-gray);font-weight:500;display:block;padding-top:calc(1.5 * var(--wcs-base-margin));padding-bottom:calc(1.5 * var(--wcs-base-margin));padding-left:calc(6 * var(--wcs-base-margin))}@media screen and (min-width: 576px){:host{height:100%;padding-bottom:unset}:host .menu-button{display:flex;align-items:center;height:100%;cursor:pointer;user-select:none;font-weight:unset;padding-left:unset}:host .label{text-transform:unset;cursor:pointer}:host .arrow-icon{display:inline-block;font-family:icons;font-size:0.6rem;line-height:1;box-sizing:border-box}:host .arrow-container{display:unset;margin-left:var(--wcs-base-margin)}:host .arrow-icon:not([data-open]){transform:rotate(90deg)}:host .arrow-icon[data-open]{transform:rotate(-90deg)}:host .drawer{display:none;position:absolute;top:75px;z-index:8888;left:0;width:100%;box-sizing:border-box;padding:50px;background-color:var(--wcs-primary);color:var(--wcs-white)}:host .drawer-content{display:flex;justify-content:space-between;max-width:62.5%;flex:1}:host .drawer-content div:first-child{flex:0.8}:host .drawer-content div{max-width:260px}:host .menu-items{padding:0 80px 0 50px;display:flex;flex-direction:column;align-items:flex-end}:host .menu-items ::slotted(*:not(:first-child)){margin-top:24px}:host .menu-items ::slotted(a){color:var(--wcs-white);font-weight:400;display:unset;padding-top:unset;padding-bottom:unset;padding-left:unset}:host .drawer-container{display:flex;max-width:var(--wcs-com-content-max-width);margin:0 auto}:host .drawer-container h3{margin:0 0 24px 0;font-size:1.5rem;line-height:1.25;font-weight:400}:host .drawer-container p{margin-top:0;margin-bottom:1rem;font-weight:500;font-size:1rem;line-height:1.375}:host .drawer[data-open]{display:block}:host .drawer-description{display:block}}";
|
|
8
8
|
|
|
9
9
|
let ComNavSubmenu = class {
|
|
10
10
|
constructor(hostRef) {
|
|
@@ -60,7 +60,7 @@ let ComNavSubmenu = class {
|
|
|
60
60
|
this.close();
|
|
61
61
|
}
|
|
62
62
|
render() {
|
|
63
|
-
return (index.h(index.Host, { onClick: evt => this.onClick(evt) }, index.h("div", { onClick: _ => this.menuOpen = !this.menuOpen, class: "menu-button" }, index.h("span", { class: "label" }, this.label), index.h("span", { class: "arrow-container" }, index.h("span", { class: "arrow-icon", "data-open": this.menuOpen }, "\uF107"))), index.h("div", { class: "drawer", "data-open": this.menuOpen }, index.h("div", { class: "drawer-container" }, index.h("div", { class: "drawer-content" }, index.h("div",
|
|
63
|
+
return (index.h(index.Host, { onClick: evt => this.onClick(evt) }, index.h("div", { onClick: _ => this.menuOpen = !this.menuOpen, class: "menu-button" }, index.h("span", { class: "label" }, this.label), index.h("span", { class: "arrow-container" }, index.h("span", { class: "arrow-icon", "data-open": this.menuOpen }, "\uF107"))), index.h("div", { class: "drawer", "data-open": this.menuOpen }, index.h("div", { class: "drawer-container" }, index.h("div", { class: "drawer-content" }, index.h("div", { class: "drawer-description" }, index.h("h3", null, this.panelTitle), index.h("p", null, this.panelDescription)), index.h("div", { class: "menu-items", onClick: (evt) => this.handleMenuItemsClick(evt) }, index.h("slot", null)))))));
|
|
64
64
|
}
|
|
65
65
|
get el() { return index.getElement(this); }
|
|
66
66
|
};
|