@sankhyalabs/ezui 0.0.0-bugfix-dev-KB-79202.0 → 0.0.0-bugfix-dev-KB-76031.2
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/ez-actions-button.cjs.entry.js +1 -1
- package/dist/cjs/ez-alert-list.cjs.entry.js +1 -1
- package/dist/cjs/ez-alert.cjs.entry.js +1 -1
- package/dist/cjs/ez-application.cjs.entry.js +1 -1
- package/dist/cjs/ez-badge.cjs.entry.js +1 -1
- package/dist/cjs/ez-breadcrumb.cjs.entry.js +1 -1
- package/dist/cjs/ez-button.cjs.entry.js +1 -1
- package/dist/cjs/ez-calendar.cjs.entry.js +1 -1
- package/dist/cjs/ez-card-item_2.cjs.entry.js +1 -1
- package/dist/cjs/ez-chart.cjs.entry.js +1 -1
- package/dist/cjs/ez-check.cjs.entry.js +1 -1
- package/dist/cjs/ez-chip.cjs.entry.js +1 -1
- package/dist/cjs/ez-collapsible-box.cjs.entry.js +1 -1
- package/dist/cjs/ez-combo-box.cjs.entry.js +1 -1
- package/dist/cjs/ez-custom-form-input_2.cjs.entry.js +2 -2
- package/dist/cjs/ez-date-input.cjs.entry.js +1 -1
- package/dist/cjs/ez-date-time-input.cjs.entry.js +1 -1
- package/dist/cjs/ez-dialog.cjs.entry.js +1 -1
- package/dist/cjs/ez-double-list.cjs.entry.js +1 -1
- package/dist/cjs/ez-dropdown_2.cjs.entry.js +1 -1
- package/dist/cjs/ez-file-item.cjs.entry.js +1 -1
- package/dist/cjs/ez-filter-input.cjs.entry.js +1 -1
- package/dist/cjs/ez-form-view.cjs.entry.js +1 -1
- package/dist/cjs/ez-form.cjs.entry.js +1 -1
- package/dist/cjs/ez-grid.cjs.entry.js +29 -16
- package/dist/cjs/ez-guide-navigator.cjs.entry.js +1 -1
- package/dist/cjs/ez-icon.cjs.entry.js +1 -1
- package/dist/cjs/ez-list.cjs.entry.js +2 -2
- package/dist/cjs/ez-loading-bar.cjs.entry.js +1 -1
- package/dist/cjs/ez-modal-container.cjs.entry.js +1 -1
- package/dist/cjs/ez-modal.cjs.entry.js +1 -1
- package/dist/cjs/ez-multi-selection-list_2.cjs.entry.js +1584 -0
- package/dist/cjs/ez-number-input.cjs.entry.js +1 -1
- package/dist/cjs/ez-popover.cjs.entry.js +1 -1
- package/dist/cjs/ez-popup.cjs.entry.js +1 -1
- package/dist/cjs/ez-radio-button.cjs.entry.js +1 -1
- package/dist/cjs/ez-scroller_2.cjs.entry.js +1 -1
- package/dist/cjs/ez-search.cjs.entry.js +1 -1
- package/dist/cjs/ez-sidebar-navigator.cjs.entry.js +1 -1
- package/dist/cjs/ez-split-button.cjs.entry.js +1 -1
- package/dist/cjs/ez-split-item.cjs.entry.js +1 -1
- package/dist/cjs/ez-split-panel.cjs.entry.js +1 -1
- package/dist/cjs/ez-tabselector.cjs.entry.js +1 -1
- package/dist/cjs/ez-text-area.cjs.entry.js +1 -1
- package/dist/cjs/ez-text-input.cjs.entry.js +1 -1
- package/dist/cjs/ez-time-input.cjs.entry.js +1 -1
- package/dist/cjs/ez-toast.cjs.entry.js +1 -1
- package/dist/cjs/ez-tooltip.cjs.entry.js +1 -1
- package/dist/cjs/ez-tree.cjs.entry.js +1 -1
- package/dist/cjs/ez-upload.cjs.entry.js +1 -1
- package/dist/cjs/ez-view-stack.cjs.entry.js +1 -1
- package/dist/cjs/ezui.cjs.js +2 -2
- package/dist/cjs/filter-column.cjs.entry.js +3 -46
- package/dist/cjs/{index-a7b0c73d.js → index-9e5554cb.js} +5 -2
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/collection/collection-manifest.json +1 -0
- package/dist/collection/components/ez-grid/controller/ag-grid/components/EzGridCustomHeader.js +1 -1
- package/dist/collection/components/ez-grid/ez-grid.css +37 -7
- package/dist/collection/components/ez-grid/ez-grid.js +26 -13
- package/dist/collection/components/ez-grid/subcomponents/filter-column.js +2 -45
- package/dist/collection/components/ez-list/ez-list.css +3 -3
- package/dist/collection/components/ez-multi-selection-list/ez-multi-selection-list.css +1 -0
- package/dist/collection/components/ez-popover-plus/ez-popover-plus.css +67 -0
- package/dist/collection/components/ez-popover-plus/ez-popover-plus.js +465 -0
- package/dist/custom-elements/index.d.ts +6 -0
- package/dist/custom-elements/index.js +1439 -68
- package/dist/esm/ez-actions-button.entry.js +1 -1
- package/dist/esm/ez-alert-list.entry.js +1 -1
- package/dist/esm/ez-alert.entry.js +1 -1
- package/dist/esm/ez-application.entry.js +1 -1
- package/dist/esm/ez-badge.entry.js +1 -1
- package/dist/esm/ez-breadcrumb.entry.js +1 -1
- package/dist/esm/ez-button.entry.js +1 -1
- package/dist/esm/ez-calendar.entry.js +1 -1
- package/dist/esm/ez-card-item_2.entry.js +1 -1
- package/dist/esm/ez-chart.entry.js +1 -1
- package/dist/esm/ez-check.entry.js +1 -1
- package/dist/esm/ez-chip.entry.js +1 -1
- package/dist/esm/ez-collapsible-box.entry.js +1 -1
- package/dist/esm/ez-combo-box.entry.js +1 -1
- package/dist/esm/ez-custom-form-input_2.entry.js +2 -2
- package/dist/esm/ez-date-input.entry.js +1 -1
- package/dist/esm/ez-date-time-input.entry.js +1 -1
- package/dist/esm/ez-dialog.entry.js +1 -1
- package/dist/esm/ez-double-list.entry.js +1 -1
- package/dist/esm/ez-dropdown_2.entry.js +1 -1
- package/dist/esm/ez-file-item.entry.js +1 -1
- package/dist/esm/ez-filter-input.entry.js +1 -1
- package/dist/esm/ez-form-view.entry.js +1 -1
- package/dist/esm/ez-form.entry.js +1 -1
- package/dist/esm/ez-grid.entry.js +29 -16
- package/dist/esm/ez-guide-navigator.entry.js +1 -1
- package/dist/esm/ez-icon.entry.js +1 -1
- package/dist/esm/ez-list.entry.js +2 -2
- package/dist/esm/ez-loading-bar.entry.js +1 -1
- package/dist/esm/ez-modal-container.entry.js +1 -1
- package/dist/esm/ez-modal.entry.js +1 -1
- package/dist/esm/ez-multi-selection-list_2.entry.js +1579 -0
- package/dist/esm/ez-number-input.entry.js +1 -1
- package/dist/esm/ez-popover.entry.js +1 -1
- package/dist/esm/ez-popup.entry.js +1 -1
- package/dist/esm/ez-radio-button.entry.js +1 -1
- package/dist/esm/ez-scroller_2.entry.js +1 -1
- package/dist/esm/ez-search.entry.js +1 -1
- package/dist/esm/ez-sidebar-navigator.entry.js +1 -1
- package/dist/esm/ez-split-button.entry.js +1 -1
- package/dist/esm/ez-split-item.entry.js +1 -1
- package/dist/esm/ez-split-panel.entry.js +1 -1
- package/dist/esm/ez-tabselector.entry.js +1 -1
- package/dist/esm/ez-text-area.entry.js +1 -1
- package/dist/esm/ez-text-input.entry.js +1 -1
- package/dist/esm/ez-time-input.entry.js +1 -1
- package/dist/esm/ez-toast.entry.js +1 -1
- package/dist/esm/ez-tooltip.entry.js +1 -1
- package/dist/esm/ez-tree.entry.js +1 -1
- package/dist/esm/ez-upload.entry.js +1 -1
- package/dist/esm/ez-view-stack.entry.js +1 -1
- package/dist/esm/ezui.js +3 -3
- package/dist/esm/filter-column.entry.js +3 -46
- package/dist/esm/{index-baa5e267.js → index-5a720e56.js} +5 -3
- package/dist/esm/loader.js +3 -3
- package/dist/ezui/ezui.esm.js +1 -1
- package/dist/ezui/{p-44caad9a.entry.js → p-0378416a.entry.js} +1 -1
- package/dist/ezui/{p-65f471bc.entry.js → p-03b0ed5a.entry.js} +1 -1
- package/dist/ezui/{p-ae098837.entry.js → p-043b97b5.entry.js} +1 -1
- package/dist/ezui/{p-5b205c80.entry.js → p-044d46d5.entry.js} +1 -1
- package/dist/ezui/{p-a4cee65d.entry.js → p-0cfbbe82.entry.js} +1 -1
- package/dist/ezui/{p-77a4bd35.entry.js → p-11bfeca3.entry.js} +1 -1
- package/dist/ezui/{p-7e677b7b.entry.js → p-2069c78a.entry.js} +1 -1
- package/dist/ezui/{p-17eabf46.entry.js → p-24b42f3d.entry.js} +1 -1
- package/dist/ezui/{p-556468d9.entry.js → p-3791d9c8.entry.js} +1 -1
- package/dist/ezui/{p-1ad6c61b.entry.js → p-3885e66e.entry.js} +1 -1
- package/dist/ezui/p-3af64edd.entry.js +1 -0
- package/dist/ezui/{p-fa6732f2.entry.js → p-44b39e81.entry.js} +1 -1
- package/dist/ezui/{p-c1527804.entry.js → p-4818b8ce.entry.js} +1 -1
- package/dist/ezui/{p-7a171eae.entry.js → p-4f7d3e72.entry.js} +1 -1
- package/dist/ezui/{p-d9548bdf.entry.js → p-5010315a.entry.js} +1 -1
- package/dist/ezui/{p-ea54d056.entry.js → p-68b2e579.entry.js} +1 -1
- package/dist/ezui/{p-1f50fa05.entry.js → p-6b51c9cc.entry.js} +1 -1
- package/dist/ezui/{p-2bb2a0c4.entry.js → p-6d31c43c.entry.js} +1 -1
- package/dist/ezui/{p-6cdd3e0a.entry.js → p-6d8b3298.entry.js} +1 -1
- package/dist/ezui/p-6ec40dec.entry.js +1 -0
- package/dist/ezui/{p-5ed81457.entry.js → p-6fc26622.entry.js} +1 -1
- package/dist/ezui/{p-da1b4a38.entry.js → p-708b196e.entry.js} +1 -1
- package/dist/ezui/{p-555c9018.entry.js → p-7567ccdd.entry.js} +1 -1
- package/dist/ezui/p-75705ffb.entry.js +1 -0
- package/dist/ezui/{p-1e7a8633.entry.js → p-81461d2f.entry.js} +1 -1
- package/dist/ezui/{p-8df1ca33.entry.js → p-82fa4b09.entry.js} +1 -1
- package/dist/ezui/p-88c615f0.entry.js +1 -0
- package/dist/ezui/{p-56fe5341.entry.js → p-9066b0b0.entry.js} +1 -1
- package/dist/ezui/{p-09de35a2.entry.js → p-91ccae0c.entry.js} +1 -1
- package/dist/ezui/{p-c0d9c4f8.entry.js → p-92748142.entry.js} +1 -1
- package/dist/ezui/{p-0faf71c5.entry.js → p-92fbaf2b.entry.js} +1 -1
- package/dist/ezui/{p-e6a9041d.entry.js → p-9e95bfeb.entry.js} +1 -1
- package/dist/ezui/{p-06136139.entry.js → p-a34bee4d.entry.js} +2 -2
- package/dist/ezui/{p-990b4318.entry.js → p-a921e3e7.entry.js} +1 -1
- package/dist/ezui/{p-3429080c.entry.js → p-b22889ea.entry.js} +1 -1
- package/dist/ezui/{p-17be134a.entry.js → p-b2f6bc0a.entry.js} +1 -1
- package/dist/ezui/{p-cb1535f7.entry.js → p-b9282c79.entry.js} +1 -1
- package/dist/ezui/{p-e347df9c.entry.js → p-bef7daac.entry.js} +1 -1
- package/dist/ezui/{p-9f5fa3f9.entry.js → p-c2b20f78.entry.js} +1 -1
- package/dist/ezui/p-c75d4b4a.entry.js +1 -0
- package/dist/ezui/{p-17de16e5.entry.js → p-c96fbbef.entry.js} +1 -1
- package/dist/ezui/{p-2f45506d.entry.js → p-ca8936df.entry.js} +1 -1
- package/dist/ezui/{p-20c024f7.entry.js → p-cf33bc48.entry.js} +1 -1
- package/dist/ezui/{p-354abfe8.entry.js → p-d32125d1.entry.js} +1 -1
- package/dist/ezui/{p-a80b1287.entry.js → p-dfca5946.entry.js} +1 -1
- package/dist/ezui/{p-7fdd479f.entry.js → p-e18d9e6a.entry.js} +1 -1
- package/dist/ezui/{p-fd0a19d6.entry.js → p-e3f8660b.entry.js} +1 -1
- package/dist/ezui/{p-23a36bb6.js → p-e4c7eb39.js} +2 -2
- package/dist/ezui/{p-0306dff7.entry.js → p-e6b38ade.entry.js} +1 -1
- package/dist/ezui/{p-650e4b6d.entry.js → p-f1c2c19e.entry.js} +1 -1
- package/dist/ezui/{p-b26f6c5b.entry.js → p-f30e0590.entry.js} +1 -1
- package/dist/ezui/{p-cf87aacb.entry.js → p-f4da7e1e.entry.js} +1 -1
- package/dist/ezui/{p-6e429cff.entry.js → p-fc194825.entry.js} +1 -1
- package/dist/types/components/ez-grid/ez-grid.d.ts +5 -0
- package/dist/types/components/ez-grid/subcomponents/filter-column.d.ts +0 -11
- package/dist/types/components/ez-popover-plus/ez-popover-plus.d.ts +81 -0
- package/dist/types/components.d.ts +94 -0
- package/package.json +3 -3
- package/react/components.d.ts +1 -0
- package/react/components.js +1 -0
- package/react/components.js.map +1 -1
- package/dist/cjs/ez-multi-selection-list.cjs.entry.js +0 -186
- package/dist/esm/ez-multi-selection-list.entry.js +0 -182
- package/dist/ezui/p-16e612fc.entry.js +0 -1
- package/dist/ezui/p-1ab96710.entry.js +0 -1
- package/dist/ezui/p-a6fe527a.entry.js +0 -1
- package/dist/ezui/p-bc2f844e.entry.js +0 -1
- package/dist/ezui/p-dc8b36c3.entry.js +0 -1
|
@@ -17332,7 +17332,7 @@ function formatSize(size) {
|
|
|
17332
17332
|
* @param {any} o
|
|
17333
17333
|
* @return {boolean}
|
|
17334
17334
|
*/
|
|
17335
|
-
function isNode(o) {
|
|
17335
|
+
function isNode$1(o) {
|
|
17336
17336
|
return (typeof Node === 'function'
|
|
17337
17337
|
? o instanceof Node
|
|
17338
17338
|
: o && typeof o === 'object' && typeof o.nodeType === 'number' && typeof o.nodeName === 'string');
|
|
@@ -17344,13 +17344,13 @@ function isNode(o) {
|
|
|
17344
17344
|
* @param {any} o
|
|
17345
17345
|
* @returns {boolean}
|
|
17346
17346
|
*/
|
|
17347
|
-
function isElement(o) {
|
|
17347
|
+
function isElement$1(o) {
|
|
17348
17348
|
return (typeof HTMLElement === 'function'
|
|
17349
17349
|
? o instanceof HTMLElement //DOM2
|
|
17350
17350
|
: o && isNonNullObject(o) && o.nodeType === 1 && typeof o.nodeName === 'string');
|
|
17351
17351
|
}
|
|
17352
17352
|
function isNodeOrElement(o) {
|
|
17353
|
-
return isNode(o) || isElement(o);
|
|
17353
|
+
return isNode$1(o) || isElement$1(o);
|
|
17354
17354
|
}
|
|
17355
17355
|
/**
|
|
17356
17356
|
* Makes a copy of a node list into a list
|
|
@@ -17440,8 +17440,8 @@ const DomUtils = /*#__PURE__*/Object.freeze({
|
|
|
17440
17440
|
setElementHeight: setElementHeight,
|
|
17441
17441
|
setFixedHeight: setFixedHeight,
|
|
17442
17442
|
formatSize: formatSize,
|
|
17443
|
-
isNode: isNode,
|
|
17444
|
-
isElement: isElement,
|
|
17443
|
+
isNode: isNode$1,
|
|
17444
|
+
isElement: isElement$1,
|
|
17445
17445
|
isNodeOrElement: isNodeOrElement,
|
|
17446
17446
|
copyNodeList: copyNodeList,
|
|
17447
17447
|
iterateNamedNodeMap: iterateNamedNodeMap,
|
|
@@ -56417,7 +56417,7 @@ class EzGridCustomHeader {
|
|
|
56417
56417
|
this.element.classList.add('ag-cell-label-container');
|
|
56418
56418
|
this.element.setAttribute('title', (_a = this.params.tooltip) !== null && _a !== void 0 ? _a : '');
|
|
56419
56419
|
this.element.innerHTML = `
|
|
56420
|
-
<div class='ez-flex ez-flex--justify-between'>
|
|
56420
|
+
<div id='filter-column-${agParams.column.getColId()}-${agParams.context.dataUnit.dataUnitId}' class='ez-flex ez-flex--justify-between'>
|
|
56421
56421
|
<i id='ez-grid-filter-icon' class='ez-icon-filter' style='color:#008561'></i>
|
|
56422
56422
|
<i id='ez-grid-menu-icon' class='ez-icon-dots-vertical'></i>
|
|
56423
56423
|
</div>
|
|
@@ -72187,7 +72187,7 @@ class InMemoryFilterColumnDataSource {
|
|
|
72187
72187
|
}
|
|
72188
72188
|
}
|
|
72189
72189
|
|
|
72190
|
-
const ezGridCss = ".sc-ez-grid-h{display:grid;grid-template-rows:auto 1fr auto;height:100%;width:100%;--ez-grid__header--background-color:var(--background--xlight, #FFF);--ez-grid__selection-counter--z-index:var(--visible, 1);--ez-grid__container--shadow:var(--shadow);--ez-grid--min-height:300px;--ez-grid__container--shadow--outline:var(--shadow--outline) var(--color--strokes);--ez-grid__header--shadow:var(--shadow--xsmall);--ez-grid__header--shadow--outline:var(--shadow--outline) var(--color--strokes);--ez-grid__header--outline:none;--ez-grid__header--border:none;min-height:var(--ez-grid--min-height)}.grid-header.sc-ez-grid{display:grid;justify-content:space-between;align-items:center;grid-row-start:1;grid-template-columns:1fr;background-color:var(--ez-grid__header--background-color, #FFF)}.grid-header.shadow-mode.sc-ez-grid{box-shadow:var(--ez-grid__header--shadow);border:var(--ez-grid__header--border);outline:var(--ez-grid__header--outline)}.grid-header.outline-mode.sc-ez-grid{box-shadow:var(--ez-grid__header--shadow--outline);border:var(--ez-grid__header--border);outline:var(--ez-grid__header--outline)}.
|
|
72190
|
+
const ezGridCss = ".sc-ez-grid-h{display:grid;grid-template-rows:auto 1fr auto;height:100%;width:100%;--ez-grid__header--background-color:var(--background--xlight, #FFF);--ez-grid__selection-counter--z-index:var(--visible, 1);--ez-grid__container--shadow:var(--shadow);--ez-grid--min-height:300px;--ez-grid__container--shadow--outline:var(--shadow--outline) var(--color--strokes);--ez-grid__header--shadow:var(--shadow--xsmall);--ez-grid__header--shadow--outline:var(--shadow--outline) var(--color--strokes);--ez-grid__header--outline:none;--ez-grid__header--border:none;min-height:var(--ez-grid--min-height)}.grid-header.sc-ez-grid{display:grid;justify-content:space-between;align-items:center;grid-row-start:1;grid-template-columns:1fr;background-color:var(--ez-grid__header--background-color, #FFF)}.grid-header.shadow-mode.sc-ez-grid{box-shadow:var(--ez-grid__header--shadow);border:var(--ez-grid__header--border);outline:var(--ez-grid__header--outline)}.grid-header.outline-mode.sc-ez-grid{box-shadow:var(--ez-grid__header--shadow--outline);border:var(--ez-grid__header--border);outline:var(--ez-grid__header--outline)}.grid__container.sc-ez-grid{padding-top:15px;margin-top:-12px;outline:none;box-shadow:var(--ez-grid__container--shadow);background-color:var(--ez-grid__header--background-color)}.grid__container.outline-mode.sc-ez-grid{box-shadow:var(--ez-grid__container--shadow--outline);border:none;outline:none}.grid-header__popover.sc-ez-grid{position:relative;top:var(--space--sm, 16px)}.grid-header__container.sc-ez-grid{display:flex;align-items:center}.grid-header__position.sc-ez-grid{display:flex;align-items:center;justify-content:space-between}.grid__selection-counter.sc-ez-grid{position:fixed;white-space:nowrap;transform:translate(-50%, 0px);left:50%;opacity:0;bottom:-100%;transition:opacity 0.1s, bottom 0.5s}.grid__selection-counter--opened.sc-ez-grid{opacity:1;bottom:0px}.grid__btn-close.sc-ez-grid{display:flex;align-items:center;justify-content:center;padding:0;outline:none;width:20px;height:20px;border:none;background-color:unset;cursor:pointer}.grid__btn-clear.sc-ez-grid{--ez-button--link-color:var(--color--alert-warning-900, #8C6B00);--ez-button--link--hover-color:var(--color--alert-warning-900, #8C6B00)}[no-header].sc-ez-grid-h .grid-header.sc-ez-grid{height:0;padding:0}.grid-header__pagination.sc-ez-grid{justify-content:flex-end;flex-wrap:nowrap}.grid-header__pagination-label.sc-ez-grid{width:100%;white-space:nowrap}.overflowed.sc-ez-grid{display:none}.pagination-contracted.sc-ez-grid{width:100px}.pagination-expanded.sc-ez-grid{min-width:150px}.left__header-contracted.sc-ez-grid{width:calc(100% - 100px)}.left__header-expanded.sc-ez-grid{flex-grow:1}.cancel-pagination.sc-ez-grid{display:flex;flex-direction:row;align-items:center;justify-content:space-between;gap:4px;padding:8px;width:180px}.cancel-pagination-btn.sc-ez-grid{color:var(--color--error);font-size:var(--text--medium);font-weight:var(--text-weight--large);font-family:var(--font-pattern, Roboto);text-wrap:nowrap;cursor:pointer}.spin.sc-ez-grid{animation-name:spin;animation-duration:5000ms;animation-iteration-count:infinite;animation-timing-function:linear}@keyframes spin{from{transform:rotate(0deg)}to{transform:rotate(360deg)}}";
|
|
72191
72191
|
|
|
72192
72192
|
const windowInstace$1 = window;
|
|
72193
72193
|
const matches = (text, filter) => {
|
|
@@ -72376,6 +72376,7 @@ const EzGrid$1 = class extends HTMLElement$1 {
|
|
|
72376
72376
|
this._gridController.setColumnsState(config === null || config === void 0 ? void 0 : config.columns);
|
|
72377
72377
|
}
|
|
72378
72378
|
updatePaginationTooltip() {
|
|
72379
|
+
this.handleShowCancelPagination();
|
|
72379
72380
|
if (!this._refPaginationLabelTooltip)
|
|
72380
72381
|
return;
|
|
72381
72382
|
const alreadyDefined = this._refPaginationLabelTooltip.getAttribute('data-tooltip');
|
|
@@ -72562,11 +72563,28 @@ const EzGrid$1 = class extends HTMLElement$1 {
|
|
|
72562
72563
|
return "pagination-expanded";
|
|
72563
72564
|
return "pagination-contracted";
|
|
72564
72565
|
}
|
|
72566
|
+
async handleCancelPagination() {
|
|
72567
|
+
this.dataUnit.cancelPagination = true;
|
|
72568
|
+
await this._cancelPaginationPopoverElement.hide();
|
|
72569
|
+
}
|
|
72570
|
+
renderCancelPagination() {
|
|
72571
|
+
return (h("ez-popover", { ref: (element) => (this._cancelPaginationPopoverElement = element), "overlay-type": 'none', autoClose: false }, h("div", { class: 'cancel-pagination' }, h("ez-icon", { iconName: "sync", size: "x-large", class: "spin" }), h("span", { onClick: () => this.handleCancelPagination(), class: 'cancel-pagination-btn' }, "Cancelar pagina\u00E7\u00E3o"))));
|
|
72572
|
+
}
|
|
72573
|
+
handleShowCancelPagination() {
|
|
72574
|
+
var _a;
|
|
72575
|
+
if (!this._hasToShowCancelPagination()) {
|
|
72576
|
+
this._cancelPaginationPopoverElement.hide();
|
|
72577
|
+
return;
|
|
72578
|
+
}
|
|
72579
|
+
if (this._cancelPaginationPopoverElement.opened)
|
|
72580
|
+
return;
|
|
72581
|
+
(_a = this._cancelPaginationPopoverElement) === null || _a === void 0 ? void 0 : _a.show("15px");
|
|
72582
|
+
}
|
|
72565
72583
|
getPaginationControl() {
|
|
72566
72584
|
if (!this._paginationInfo)
|
|
72567
72585
|
return null;
|
|
72568
72586
|
const { currentPage, hasMore } = this._paginationInfo;
|
|
72569
|
-
return (h("div", { class: `grid-header__container grid-header__pagination ${this.resolvePaginationClassMode()}`, ref: ref => (this._refPaginationControl = ref) }, h("div", { class: "ez-text ez-text--primary ez-text--medium ez-margin-right--medium", ref: (element) => (this._refPaginationLabel = element) }, h("span", { class: "grid-header__pagination-label" }, this.paginationCounterMode == 'show' && h("strong", { class: "ez-text ez-text--primary ez-text--medium" }, this._getActualPageLabel()), this.paginationCounterMode == 'show' && this._getRemainingPageLabel())), h("div", { id: "grid-pagination-tooltip", ref: (element) => (this._refPaginationLabelTooltip = element), class: "ez-flex ez-margin-right--medium", title: `${this._getActualPageLabel()} ${this._getRemainingPageLabel()}` }, h("ez-button", { size: "small", class: "ez-margin-right--medium", iconName: "chevron-left", mode: "icon", enabled: currentPage > 0, onClick: () => this.previousPage(), label: "P\u00E1gina anterior" }), h("ez-button", { size: "small", iconName: "chevron-right", mode: "icon", enabled: hasMore, onClick: () => this.nextPage(), label: "Pr\u00F3xima P\u00E1gina" }))));
|
|
72587
|
+
return (h("div", { class: `grid-header__container grid-header__pagination ${this.resolvePaginationClassMode()}`, ref: ref => (this._refPaginationControl = ref) }, this.renderCancelPagination(), h("div", { class: "ez-text ez-text--primary ez-text--medium ez-margin-right--medium", ref: (element) => (this._refPaginationLabel = element) }, h("span", { class: "grid-header__pagination-label" }, this.paginationCounterMode == 'show' && h("strong", { class: "ez-text ez-text--primary ez-text--medium" }, this._getActualPageLabel()), this.paginationCounterMode == 'show' && this._getRemainingPageLabel())), h("div", { id: "grid-pagination-tooltip", ref: (element) => (this._refPaginationLabelTooltip = element), class: "ez-flex ez-margin-right--medium", title: `${this._getActualPageLabel()} ${this._getRemainingPageLabel()}` }, h("ez-button", { size: "small", class: "ez-margin-right--medium", iconName: "chevron-left", mode: "icon", enabled: currentPage > 0, onClick: () => this.previousPage(), label: "P\u00E1gina anterior" }), h("ez-button", { size: "small", iconName: "chevron-right", mode: "icon", enabled: hasMore, onClick: () => this.nextPage(), label: "Pr\u00F3xima P\u00E1gina" }))));
|
|
72570
72588
|
}
|
|
72571
72589
|
componentDidLoad() {
|
|
72572
72590
|
const _application = ApplicationContext.getContextValue("__SNK__APPLICATION__");
|
|
@@ -72638,6 +72656,11 @@ const EzGrid$1 = class extends HTMLElement$1 {
|
|
|
72638
72656
|
const { total, count } = this._paginationInfo;
|
|
72639
72657
|
return `${total == undefined ? ` de ${count + 1} ou mais` : ` de ${total}`}`;
|
|
72640
72658
|
}
|
|
72659
|
+
_hasToShowCancelPagination() {
|
|
72660
|
+
const { total, count } = this._paginationInfo;
|
|
72661
|
+
const hasMore = (total === undefined);
|
|
72662
|
+
return !this.dataUnit.cancelPagination && hasMore && count > this.dataUnit.pageSize;
|
|
72663
|
+
}
|
|
72641
72664
|
_getPaginationTooltip() {
|
|
72642
72665
|
return this._getActualPageLabel() + this._getRemainingPageLabel();
|
|
72643
72666
|
}
|
|
@@ -72708,7 +72731,7 @@ const EzGrid$1 = class extends HTMLElement$1 {
|
|
|
72708
72731
|
return (_a = this.columnfilterDataSource) !== null && _a !== void 0 ? _a : new InMemoryFilterColumnDataSource(this.dataUnit);
|
|
72709
72732
|
}
|
|
72710
72733
|
hideHeader() {
|
|
72711
|
-
return
|
|
72734
|
+
return (!!this._element.getAttribute("no-header") && !this._paginationInfo);
|
|
72712
72735
|
}
|
|
72713
72736
|
resolveLeftHeaderClass() {
|
|
72714
72737
|
if (this.paginationCounterMode == 'show')
|
|
@@ -72717,17 +72740,7 @@ const EzGrid$1 = class extends HTMLElement$1 {
|
|
|
72717
72740
|
}
|
|
72718
72741
|
render() {
|
|
72719
72742
|
var _a;
|
|
72720
|
-
return (h(Host, { "no-header": this.hideHeader() }, h("div", { class: {
|
|
72721
|
-
'grid__container ez-grid': true,
|
|
72722
|
-
'outline-mode': this.outlineMode,
|
|
72723
|
-
'shadow-mode': !this.outlineMode,
|
|
72724
|
-
'no-padding': this.compact,
|
|
72725
|
-
'header-overlay': !this.hideHeader(),
|
|
72726
|
-
}, ref: elem => (this._container = elem) }), h("div", { class: {
|
|
72727
|
-
'ez-box ez-padding--small grid-header': true,
|
|
72728
|
-
'outline-mode': this.outlineMode,
|
|
72729
|
-
'shadow-mode': !this.outlineMode && !this.hideHeader(),
|
|
72730
|
-
} }, h("filter-column", { class: "grid-header__popover", noHeaderTaskBar: !this._hasLeftButtons, dataSource: this.getDataSource(), dataUnit: this.dataUnit, gridHeaderHidden: this.hideHeader(), ref: (element) => (this._filterColumn = element) }), h("div", { class: "grid-header__position" }, h("div", { class: `grid-header__container grid-header__left-container ${this.resolveLeftHeaderClass()}` }, h("slot", { name: "leftButtons" })), this.getPaginationControl())), h("div", { ref: (ref) => (this._gridSelectionCounter = ref), class: `grid__selection-counter ez-elevation--4
|
|
72743
|
+
return (h(Host, { "no-header": this.hideHeader() }, h("div", { class: `grid__container ez-grid ${this.outlineMode ? 'outline-mode' : 'shadow-mode'} ${this.compact ? 'no-padding' : ""}`, ref: elem => (this._container = elem) }), h("div", { class: `ez-box ${this.outlineMode ? 'outline-mode' : 'shadow-mode'} ez-padding--small grid-header` }, h("filter-column", { class: "grid-header__popover", noHeaderTaskBar: !this._hasLeftButtons, dataSource: this.getDataSource(), dataUnit: this.dataUnit, gridHeaderHidden: this.hideHeader(), ref: (element) => (this._filterColumn = element) }), h("div", { class: "grid-header__position" }, h("div", { class: `grid-header__container grid-header__left-container ${this.resolveLeftHeaderClass()}` }, h("slot", { name: "leftButtons" })), this.getPaginationControl())), h("div", { ref: (ref) => (this._gridSelectionCounter = ref), class: `grid__selection-counter ez-elevation--4
|
|
72731
72744
|
${this._showSelectionCounter ? 'grid__selection-counter--opened' : ''}
|
|
72732
72745
|
` }, h(SelectionCounter, { selectionCount: this._selectionCount, currentPageSelected: this._currentPageSelected, paginationInfo: this._paginationInfo, canSelectAll: (_a = this.selectionToastConfig) === null || _a === void 0 ? void 0 : _a.canSelectAll, allRecordSelected: this._isAllSelection, onSelectAll: () => this.onSelectAllRecords(), onSelectPage: () => this.onSelectPageRecords(), onClearAll: () => this.onClearSelectedRecords(), onClose: () => (this._showSelectionCounter = false) })), h("div", { class: "grid__footer" }, h("slot", { name: "footer" }))));
|
|
72733
72746
|
}
|
|
@@ -72874,7 +72887,7 @@ const EzIcon$1 = class extends HTMLElement$1 {
|
|
|
72874
72887
|
static get style() { return ezIconCss; }
|
|
72875
72888
|
};
|
|
72876
72889
|
|
|
72877
|
-
const ezListCss = ".sc-ez-list-h {\n \n --ez-list__host--z-index: var(--visible, 1);\n\n \n --ez-list__host--border-radius: var(--border--radius-medium, 12px);\n\n \n --ez-list__host--padding: var(--space--medium, 12px);\n\n \n --ez-list__icon--padding: var(--space--small, 6px);\n\n \n --ez-list__icon--color: #AFB6C0;\n\n \n --ez-list__item--margin: 0 var(--space--small, 6px);\n\n \n --ez-list__item--color: var(--title--primary, #2b3a54);\n\n \n --ez-list__item--border-bottom;\n\n \n --ez-list__item--border-bottom-color;\n\n \n --ez-list__item--font-family: var(--font-pattern, \"Roboto\");\n\n \n --ez-list__item--font-size: var(--text--medium, 14px);\n \n \n --ez-list__item--white-space: var(--ez-list__item--white-space, nowrap);\n\n \n --ez-list__selectable--padding-right: var(--space--small, 6px);\n \n \n --ez-list__selectable--padding-left: var(--space--small, 6px);\n\n \n --ez-list__selected-item--border-radius: var(--border--radius-small, 6px);\n \n \n --ez-list__selected-item--background-color: var(--color--primary-300, #E2F4EF);\n\n \n --ez-list__group--font-family: var(--font-pattern, \"Roboto\");\n \n \n --ez-list__group--font-size: var(--text--medium, 14px);\n \n \n --ez-list__group--font-weight: var(--text-weight--large, 600);\n \n \n --ez-list__group--padding-bottom: var(--space-small, 6px);\n\n \n --ez-list__group-overlay--font-family: var(--font-pattern, \"Roboto\");\n\n \n --ez-list__group-overlay--font-size: var(--text--medium, 14px);\n \n \n --ez-list__over--border--color: var(--color--primary, #008561);\n\n \n --ez-list__last-droppable-space--height: var(--space--small, 6px);\n \n \n --ez-list__draggable-list--padding-bottom: var(--space--small, 6px);\n\n \n --ez-list__draggable-icon--image: url('data:image/svg+xml;utf8,<svg width=\"18\" height=\"18\" viewBox=\"0 0 18 18\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"m 6.75,2.25 h 1.5 v 1.5 h -1.5 z m 3,0 h 1.5 v 1.5 h -1.5 z m -3,3 h 1.5 v 1.5 h -1.5 z m 3,0 h 1.5 v 1.5 h -1.5 z m -3,3 h 1.5 v 1.5 h -1.5 z m 3,0 h 1.5 v 1.5 h -1.5 z m -3,3 h 1.5 v 1.5 h -1.5 z m 3,0 h 1.5 v 1.5 h -1.5 z m -3,3 h 1.5 v 1.5 h -1.5 z m 3,0 h 1.5 v 1.5 h -1.5 z\"/></svg>');\n\n \n \n --ez-list__scrollbar--color-default: var(--scrollbar--default, #626e82);\n \n --ez-list__scrollbar--color-background: var(--scrollbar--background, #E5EAF0);\n \n --ez-list__scrollbar--color-hover: var(--scrollbar--hover, #2B3A54);\n \n --ez-list__scrollbar--color-clicked: var(--scrollbar--clicked, #a2abb9);\n \n --ez-list__scrollbar--border-radius: var(--border--radius-small, 6px);\n \n --ez-list__scrollbar--width: var(--space--medium, 12px);\n\n max-height: 100%;\n width: 100%;\n background-color: #fff;\n display: flex;\n\n \n z-index: var(--ez-list__host--z-index);\n}\n\np.sc-ez-list {\n margin: 0;\n}\n\n.draggable.sc-ez-list {\n \n width: 100%;\n display: grid;\n grid-template-columns: minmax(0px, auto) minmax(0px, auto);\n place-items: center;\n border-top: 1px dashed #fff;\n justify-content: space-between;\n\n \n font-family: var(--ez-list__item--font-family);\n font-size: var(--ez-list__item--font-size);\n}\n\n.dragging.sc-ez-list {\n background: #FFFFFF;\n \n\n border: 1px solid #008561;\n box-sizing: border-box;\n box-shadow: 0px 0px 16px rgba(0, 38, 111, 0.122);\n border-radius: 6px;\n}\n\n.selectable.sc-ez-list {\n cursor: pointer;\n\n \n padding-right: var(--ez-list__selectable--padding-right);\n padding-left: var(--ez-list__selectable--padding-left);\n}\n\n.selectable-container.sc-ez-list {\n margin: 0px !important;\n}\n\n.hover-feedback.sc-ez-list:hover {\n background-color: var(--background--medium);\n border-radius: var(--border--radius-regular);\n}\n\n.item-content.sc-ez-list {\n display: flex;\n align-items: center;\n overflow: hidden;\n justify-content: flex-start;\n width: 100%;\n}\n\n.draggable-list.sc-ez-list {\n padding: 0;\n margin: 0;\n width: 100%;\n max-height: 100%;\n scrollbar-width: thin;\n \n \n color: var(--text-color);\n scrollbar-color: var(--ez-list__scrollbar--color-clicked) var(--ez-list__scrollbar--color-background);\n}\n\n.draggable-list.sc-ez-list li.sc-ez-list {\n display: flex;\n \n \n font-family: var(--ez-list__item--font-family);\n font-size: var(--ez-list__item--font-size);\n color: var(--ez-list__item--color);\n border-bottom: var(--ez-list__item--border-bottom, none) var(--ez-list__item--border-bottom-color);\n}\n\n.draggable-list.sc-ez-list li.sc-ez-list > div.sc-ez-list {\n \n padding: var(--space--3xs, 4px) var(--space--3xs, 4px);\n margin: var(--ez-list__item--margin);\n}\n\n.over.sc-ez-list {\n \n border-top: 1px dashed var(--ez-list__over--border--color);\n}\n\n.last-droppable-space.sc-ez-list {\n \n height: var(--ez-list__last-droppable-space--height);\n}\n\n.draggable-selected.sc-ez-list {\n \n background-color: var(--background--strong) !important;\n}\n\n.draggable-selected.sc-ez-list div.sc-ez-list:hover {\n \n background-color: var(--background--strong) !important;\n}\n\n.draggable-list.sc-ez-list::-webkit-scrollbar {\n \n background-color: var(--ez-list__scrollbar--color-background);\n width: var(--ez-list__scrollbar--width);\n max-width: var(--ez-list__scrollbar--width);\n min-width: var(--ez-list__scrollbar--width);\n}\n\n.draggable-list.sc-ez-list::-webkit-scrollbar-track {\n \n background-color: var(--ez-list__scrollbar--color-background);\n border-radius: var(--ez-list__scrollbar--border-radius);\n}\n\n.draggable-list.sc-ez-list::-webkit-scrollbar-thumb {\n \n background-color: var(--ez-list__scrollbar--color-default);\n border-radius: var(--ez-list__scrollbar--border-radius);\n}\n\n.draggable-list.sc-ez-list::-webkit-scrollbar-thumb:vertical:hover, .draggable-list.sc-ez-list::-webkit-scrollbar-thumb:horizontal:hover {\n \n background-color: var(--ez-list__scrollbar--color-hover);\n}\n\n.draggable-list.sc-ez-list::-webkit-scrollbar-thumb:vertical:active, .draggable-list.sc-ez-list::-webkit-scrollbar-thumb:horizontal:active {\n \n background-color: var(--ez-list__scrollbar--color-clicked);\n}\n\n.draggable-icon.sc-ez-list {\n align-items: flex-start;\n display: flex;\n outline: none;\n border: none;\n background-color: unset;\n}\n\n.draggable-icon.sc-ez-list::after {\n content: '';\n display: flex;\n width: 18px;\n height: 18px;\n\n \n background-color: var(--ez-list__icon--color);\n -webkit-mask-image: var(--ez-list__draggable-icon--image);\n mask-image: var(--ez-list__draggable-icon--image);\n}\n\n*.sc-ez-list {\n box-sizing: border-box;\n}\n\n.checkbox.sc-ez-list {\n width: fit-content;\n}\n\n.text--ellipsis.sc-ez-list {\n overflow: hidden;\n text-overflow: ellipsis;\n \n \n white-space: var(--ez-list__item--white-space);\n}\n\n.group-container.sc-ez-list {\n display: flex;\n flex-direction: column;\n max-height: 100%;\n overflow-y: auto;\n outline: none;\n width: 100%;\n scrollbar-width: thin;\n\n \n scrollbar-color: var(--ez-list__scrollbar--color-clicked) var(--ez-list__scrollbar--color-background);\n}\n\n.group-name.sc-ez-list {\n -webkit-user-select: none;\n -moz-user-select: -moz-none;\n -ms-user-select: none;\n user-select: none;\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n\n \n color: var(--title--primary);\n font-family: var(--ez-list__group--font-family);\n font-size: var(--ez-list__group--font-size);\n font-weight: var(--ez-list__group--font-weight);\n padding-bottom: var(--ez-list__group--padding-bottom);\n}\n\n.group.sc-ez-list {\n display: flex;\n flex-direction: column;\n}\n\n.group-container.sc-ez-list::-webkit-scrollbar {\n \n background-color: var(--ez-list__scrollbar--color-background);\n width: var(--ez-list__scrollbar--width);\n max-width: var(--ez-list__scrollbar--width);\n min-width: var(--ez-list__scrollbar--width);\n}\n\n.group-container.sc-ez-list::-webkit-scrollbar-track {\n \n background-color: var(--ez-list__scrollbar--color-background);\n border-radius: var(--ez-list__scrollbar--border-radius);\n}\n\n.group-container.sc-ez-list::-webkit-scrollbar-thumb {\n \n background-color: var(--ez-list__scrollbar--color-default);\n border-radius: var(--ez-list__scrollbar--border-radius);\n}\n\n.group-container.sc-ez-list::-webkit-scrollbar-thumb:vertical:hover, .group-container.sc-ez-list::-webkit-scrollbar-thumb:horizontal:hover {\n \n background-color: var(--ez-list__scrollbar--color-hover);\n}\n\n.group-container.sc-ez-list::-webkit-scrollbar-thumb:vertical:active, .group-container.sc-ez-list::-webkit-scrollbar-thumb:horizontal:active {\n \n background-color: var(--ez-list__scrollbar--color-clicked);\n}\n\n.section-container.sc-ez-list {\n display: flex;\n position: relative;\n height: 100%;\n}\n\n.items-container.sc-ez-list {\n width: 100%;\n max-height: 100%;\n outline: none;\n scrollbar-width: thin;\n\n \n scrollbar-color: var(--ez-list__scrollbar--color-clicked) var(--ez-list__scrollbar--color-background);\n}\n\n.group-items-container.sc-ez-list {\n width: 100%;\n max-height: 100%;\n height: 100%;\n outline: none;\n}\n\n.items-container.sc-ez-list::-webkit-scrollbar {\n \n background-color: var(--ez-list__scrollbar--color-background);\n width: var(--ez-list__scrollbar--width);\n max-width: var(--ez-list__scrollbar--width);\n min-width: var(--ez-list__scrollbar--width);\n}\n\n.items-container.sc-ez-list::-webkit-scrollbar-track {\n \n background-color: var(--ez-list__scrollbar--color-background);\n border-radius: var(--ez-list__scrollbar--border-radius);\n}\n\n.items-container.sc-ez-list::-webkit-scrollbar-thumb {\n \n background-color: var(--ez-list__scrollbar--color-default);\n border-radius: var(--ez-list__scrollbar--border-radius);\n}\n\n.items-container.sc-ez-list::-webkit-scrollbar-thumb:vertical:hover, .items-container.sc-ez-list::-webkit-scrollbar-thumb:horizontal:hover {\n \n background-color: var(--ez-list__scrollbar--color-hover);\n}\n\n.items-container.sc-ez-list::-webkit-scrollbar-thumb:vertical:active, .items-container.sc-ez-list::-webkit-scrollbar-thumb:horizontal:active {\n \n background-color: var(--ez-list__scrollbar--color-clicked);\n}\n\n.group-overlay.sc-ez-list {\n background: rgba(226, 244, 239, 0.8);\n border: 1px solid #008561;\n border-radius: 8px;\n position: absolute;\n display: none;\n place-items: center;\n top: 0;\n bottom: 0;\n left: 0;\n right: 0;\n z-index: 2;\n margin: 0;\n cursor: pointer;\n\n \n font-family: var(--ez-list__group-overlay--font-family);\n font-size: var(--ez-list__group-overlay--font-size);\n}\n\n.presetedHeight.sc-ez-list {\n min-height: 100px;\n}\n\n.overlay-text.sc-ez-list {\n position: absolute;\n top: 50%;\n left: 50%;\n font-size: 50px;\n color: white;\n transform: translate(-50%, -50%);\n -ms-transform: translate(-50%, -50%);\n}\n\n.selected-item.sc-ez-list {\n \n background: var(--ez-list__selected-item--background-color);\n border-radius: var(--ez-list__selected-item--border-radius);\n}\n\n.slot-item.sc-ez-list {\n align-items: flex-end;\n}\n\n.overGroup.sc-ez-list {\n background: rgba(226, 244, 239, 0.8);\n border: 1px solid #008561;\n box-sizing: border-box;\n border-radius: 8px;\n padding-top: 6px;\n}";
|
|
72890
|
+
const ezListCss = ".sc-ez-list-h{--ez-list__host--z-index:var(--visible, 1);--ez-list__host--border-radius:var(--border--radius-medium, 12px);--ez-list__host--padding:var(--space--medium, 12px);--ez-list__icon--padding:var(--space--small, 6px);--ez-list__icon--color:#AFB6C0;--ez-list__item--margin:0 var(--space--small, 6px);--ez-list__item--color:var(--title--primary, #2b3a54);--ez-list__item--border-bottom:none;--ez-list__item--border-bottom-color:none;--ez-list__item--font-family:var(--font-pattern, \"Roboto\");--ez-list__item--font-size:var(--text--medium, 14px);--ez-list__item--white-space:var(--ez-list__item--white-space, nowrap);--ez-list__selectable--padding-right:var(--space--small, 6px);--ez-list__selectable--padding-left:var(--space--small, 6px);--ez-list__selected-item--border-radius:var(--border--radius-small, 6px);--ez-list__selected-item--background-color:var(--color--primary-300, #E2F4EF);--ez-list__group--font-family:var(--font-pattern, \"Roboto\");--ez-list__group--font-size:var(--text--medium, 14px);--ez-list__group--font-weight:var(--text-weight--large, 600);--ez-list__group--padding-bottom:var(--space-small, 6px);--ez-list__group-overlay--font-family:var(--font-pattern, \"Roboto\");--ez-list__group-overlay--font-size:var(--text--medium, 14px);--ez-list__over--border--color:var(--color--primary, #008561);--ez-list__last-droppable-space--height:var(--space--small, 6px);--ez-list__draggable-list--padding-bottom:var(--space--small, 6px);--ez-list__draggable-icon--image:url('data:image/svg+xml;utf8,<svg width=\"18\" height=\"18\" viewBox=\"0 0 18 18\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"m 6.75,2.25 h 1.5 v 1.5 h -1.5 z m 3,0 h 1.5 v 1.5 h -1.5 z m -3,3 h 1.5 v 1.5 h -1.5 z m 3,0 h 1.5 v 1.5 h -1.5 z m -3,3 h 1.5 v 1.5 h -1.5 z m 3,0 h 1.5 v 1.5 h -1.5 z m -3,3 h 1.5 v 1.5 h -1.5 z m 3,0 h 1.5 v 1.5 h -1.5 z m -3,3 h 1.5 v 1.5 h -1.5 z m 3,0 h 1.5 v 1.5 h -1.5 z\"/></svg>');--ez-list__scrollbar--color-default:var(--scrollbar--default, #626e82);--ez-list__scrollbar--color-background:var(--scrollbar--background, #E5EAF0);--ez-list__scrollbar--color-hover:var(--scrollbar--hover, #2B3A54);--ez-list__scrollbar--color-clicked:var(--scrollbar--clicked, #a2abb9);--ez-list__scrollbar--border-radius:var(--border--radius-small, 6px);--ez-list__scrollbar--width:var(--space--2xs, 8px);max-height:100%;width:100%;background-color:#fff;display:flex;z-index:var(--ez-list__host--z-index)}p.sc-ez-list{margin:0}.draggable.sc-ez-list{width:100%;display:grid;grid-template-columns:minmax(0px, auto) minmax(0px, auto);place-items:center;border-top:1px dashed #fff;justify-content:space-between;font-family:var(--ez-list__item--font-family);font-size:var(--ez-list__item--font-size)}.dragging.sc-ez-list{background:#FFFFFF;border:1px solid #008561;box-sizing:border-box;box-shadow:0px 0px 16px rgba(0, 38, 111, 0.122);border-radius:6px}.selectable.sc-ez-list{cursor:pointer;padding-right:var(--ez-list__selectable--padding-right);padding-left:var(--ez-list__selectable--padding-left)}.selectable-container.sc-ez-list{margin:0px !important}.hover-feedback.sc-ez-list:hover{background-color:var(--background--medium);border-radius:var(--border--radius-regular)}.item-content.sc-ez-list{display:flex;align-items:center;overflow:hidden;justify-content:flex-start;width:100%}.draggable-list.sc-ez-list{padding:0;margin:0;width:100%;max-height:100%;scrollbar-width:thin;color:var(--text-color);scrollbar-color:var(--ez-list__scrollbar--color-clicked) var(--ez-list__scrollbar--color-background)}.draggable-list.sc-ez-list li.sc-ez-list{display:flex;font-family:var(--ez-list__item--font-family);font-size:var(--ez-list__item--font-size);color:var(--ez-list__item--color);border-bottom:var(--ez-list__item--border-bottom, none) var(--ez-list__item--border-bottom-color)}.draggable-list.sc-ez-list li.sc-ez-list>div.sc-ez-list{padding:var(--space--3xs, 4px) var(--space--3xs, 4px);margin:var(--ez-list__item--margin)}.over.sc-ez-list{border-top:1px dashed var(--ez-list__over--border--color)}.last-droppable-space.sc-ez-list{height:var(--ez-list__last-droppable-space--height)}.draggable-selected.sc-ez-list{background-color:var(--background--strong) !important}.draggable-selected.sc-ez-list div.sc-ez-list:hover{background-color:var(--background--strong) !important}.draggable-list.sc-ez-list::-webkit-scrollbar{background-color:var(--ez-list__scrollbar--color-background);width:var(--ez-list__scrollbar--width);max-width:var(--ez-list__scrollbar--width);min-width:var(--ez-list__scrollbar--width)}.draggable-list.sc-ez-list::-webkit-scrollbar-track{background-color:var(--ez-list__scrollbar--color-background);border-radius:var(--ez-list__scrollbar--border-radius)}.draggable-list.sc-ez-list::-webkit-scrollbar-thumb{background-color:var(--ez-list__scrollbar--color-default);border-radius:var(--ez-list__scrollbar--border-radius)}.draggable-list.sc-ez-list::-webkit-scrollbar-thumb:vertical:hover,.draggable-list.sc-ez-list::-webkit-scrollbar-thumb:horizontal:hover{background-color:var(--ez-list__scrollbar--color-hover)}.draggable-list.sc-ez-list::-webkit-scrollbar-thumb:vertical:active,.draggable-list.sc-ez-list::-webkit-scrollbar-thumb:horizontal:active{background-color:var(--ez-list__scrollbar--color-clicked)}.draggable-icon.sc-ez-list{align-items:flex-start;display:flex;outline:none;border:none;background-color:unset}.draggable-icon.sc-ez-list::after{content:'';display:flex;width:18px;height:18px;background-color:var(--ez-list__icon--color);-webkit-mask-image:var(--ez-list__draggable-icon--image);mask-image:var(--ez-list__draggable-icon--image)}*.sc-ez-list{box-sizing:border-box}.checkbox.sc-ez-list{width:fit-content}.text--ellipsis.sc-ez-list{overflow:hidden;text-overflow:ellipsis;white-space:var(--ez-list__item--white-space)}.group-container.sc-ez-list{display:flex;flex-direction:column;max-height:100%;overflow-y:auto;outline:none;width:100%;scrollbar-width:thin;scrollbar-color:var(--ez-list__scrollbar--color-clicked) var(--ez-list__scrollbar--color-background)}.group-name.sc-ez-list{-webkit-user-select:none;-moz-user-select:-moz-none;-ms-user-select:none;user-select:none;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;color:var(--title--primary);font-family:var(--ez-list__group--font-family);font-size:var(--ez-list__group--font-size);font-weight:var(--ez-list__group--font-weight);padding-bottom:var(--ez-list__group--padding-bottom)}.group.sc-ez-list{display:flex;flex-direction:column}.group-container.sc-ez-list::-webkit-scrollbar{background-color:var(--ez-list__scrollbar--color-background);width:var(--ez-list__scrollbar--width);max-width:var(--ez-list__scrollbar--width);min-width:var(--ez-list__scrollbar--width)}.group-container.sc-ez-list::-webkit-scrollbar-track{background-color:var(--ez-list__scrollbar--color-background);border-radius:var(--ez-list__scrollbar--border-radius)}.group-container.sc-ez-list::-webkit-scrollbar-thumb{background-color:var(--ez-list__scrollbar--color-default);border-radius:var(--ez-list__scrollbar--border-radius)}.group-container.sc-ez-list::-webkit-scrollbar-thumb:vertical:hover,.group-container.sc-ez-list::-webkit-scrollbar-thumb:horizontal:hover{background-color:var(--ez-list__scrollbar--color-hover)}.group-container.sc-ez-list::-webkit-scrollbar-thumb:vertical:active,.group-container.sc-ez-list::-webkit-scrollbar-thumb:horizontal:active{background-color:var(--ez-list__scrollbar--color-clicked)}.section-container.sc-ez-list{display:flex;position:relative;height:100%}.items-container.sc-ez-list{width:100%;max-height:100%;outline:none;scrollbar-width:thin;scrollbar-color:var(--ez-list__scrollbar--color-clicked) var(--ez-list__scrollbar--color-background)}.group-items-container.sc-ez-list{width:100%;max-height:100%;height:100%;outline:none}.items-container.sc-ez-list::-webkit-scrollbar{background-color:var(--ez-list__scrollbar--color-background);width:var(--ez-list__scrollbar--width);max-width:var(--ez-list__scrollbar--width);min-width:var(--ez-list__scrollbar--width)}.items-container.sc-ez-list::-webkit-scrollbar-track{background-color:var(--ez-list__scrollbar--color-background);border-radius:var(--ez-list__scrollbar--border-radius)}.items-container.sc-ez-list::-webkit-scrollbar-thumb{background-color:var(--ez-list__scrollbar--color-default);border-radius:var(--ez-list__scrollbar--border-radius)}.items-container.sc-ez-list::-webkit-scrollbar-thumb:vertical:hover,.items-container.sc-ez-list::-webkit-scrollbar-thumb:horizontal:hover{background-color:var(--ez-list__scrollbar--color-hover)}.items-container.sc-ez-list::-webkit-scrollbar-thumb:vertical:active,.items-container.sc-ez-list::-webkit-scrollbar-thumb:horizontal:active{background-color:var(--ez-list__scrollbar--color-clicked)}.group-overlay.sc-ez-list{background:rgba(226, 244, 239, 0.8);border:1px solid #008561;border-radius:8px;position:absolute;display:none;place-items:center;top:0;bottom:0;left:0;right:0;z-index:2;margin:0;cursor:pointer;font-family:var(--ez-list__group-overlay--font-family);font-size:var(--ez-list__group-overlay--font-size)}.presetedHeight.sc-ez-list{min-height:100px}.overlay-text.sc-ez-list{position:absolute;top:50%;left:50%;font-size:50px;color:white;transform:translate(-50%, -50%);-ms-transform:translate(-50%, -50%)}.selected-item.sc-ez-list{background:var(--ez-list__selected-item--background-color);border-radius:var(--ez-list__selected-item--border-radius)}.slot-item.sc-ez-list{align-items:flex-end}.overGroup.sc-ez-list{background:rgba(226, 244, 239, 0.8);border:1px solid #008561;box-sizing:border-box;border-radius:8px;padding-top:6px}";
|
|
72878
72891
|
|
|
72879
72892
|
const EzList$1 = class extends HTMLElement$1 {
|
|
72880
72893
|
constructor() {
|
|
@@ -73662,7 +73675,7 @@ const EzModalContainer$1 = class extends HTMLElement$1 {
|
|
|
73662
73675
|
static get style() { return ezModalContainerCss; }
|
|
73663
73676
|
};
|
|
73664
73677
|
|
|
73665
|
-
const ezMultiSelectionListCss = ".sc-ez-multi-selection-list-h{--ez-check--outter-gap:0px;--ez-multi-selection-default-height:322px;display:block;width:304px;height:var(--ez-multi-selection-default-height);max-height:calc(100vh - 350px)}.multi-selection__input.sc-ez-multi-selection-list{margin-bottom:var(--space--2xs, 8px)}.multi-selection__content-options.sc-ez-multi-selection-list{position:relative;left:-4px}.multi-selection__select-all.sc-ez-multi-selection-list{height:var(--space--xl);margin:0 var(--space--small, 6px)}.multi-selection__list.sc-ez-multi-selection-list{max-height:calc(100vh - 435px);overflow-y:auto;overflow-x:clip}.multi-selection__list.sc-ez-multi-selection-list::-webkit-scrollbar{width:var(--space--small);min-width:var(--space--small);max-width:var(--space--small)}";
|
|
73678
|
+
const ezMultiSelectionListCss = ".sc-ez-multi-selection-list-h{--ez-check--outter-gap:0px;--ez-multi-selection-default-height:322px;display:block;width:304px;height:var(--ez-multi-selection-default-height);min-height:fit-content;max-height:calc(100vh - 350px)}.multi-selection__input.sc-ez-multi-selection-list{margin-bottom:var(--space--2xs, 8px)}.multi-selection__content-options.sc-ez-multi-selection-list{position:relative;left:-4px}.multi-selection__select-all.sc-ez-multi-selection-list{height:var(--space--xl);margin:0 var(--space--small, 6px)}.multi-selection__list.sc-ez-multi-selection-list{max-height:calc(100vh - 435px);overflow-y:auto;overflow-x:clip}.multi-selection__list.sc-ez-multi-selection-list::-webkit-scrollbar{width:var(--space--small);min-width:var(--space--small);max-width:var(--space--small)}";
|
|
73666
73679
|
|
|
73667
73680
|
var ViewScenarios;
|
|
73668
73681
|
(function (ViewScenarios) {
|
|
@@ -74186,6 +74199,1405 @@ const EzPopover$1 = class extends HTMLElement$1 {
|
|
|
74186
74199
|
static get style() { return ezPopoverCss; }
|
|
74187
74200
|
};
|
|
74188
74201
|
|
|
74202
|
+
/**
|
|
74203
|
+
* Custom positioning reference element.
|
|
74204
|
+
* @see https://floating-ui.com/docs/virtual-elements
|
|
74205
|
+
*/
|
|
74206
|
+
const min = Math.min;
|
|
74207
|
+
const max = Math.max;
|
|
74208
|
+
const round = Math.round;
|
|
74209
|
+
const createCoords = v => ({
|
|
74210
|
+
x: v,
|
|
74211
|
+
y: v
|
|
74212
|
+
});
|
|
74213
|
+
const oppositeSideMap = {
|
|
74214
|
+
left: 'right',
|
|
74215
|
+
right: 'left',
|
|
74216
|
+
bottom: 'top',
|
|
74217
|
+
top: 'bottom'
|
|
74218
|
+
};
|
|
74219
|
+
const oppositeAlignmentMap = {
|
|
74220
|
+
start: 'end',
|
|
74221
|
+
end: 'start'
|
|
74222
|
+
};
|
|
74223
|
+
function clamp(start, value, end) {
|
|
74224
|
+
return max(start, min(value, end));
|
|
74225
|
+
}
|
|
74226
|
+
function evaluate(value, param) {
|
|
74227
|
+
return typeof value === 'function' ? value(param) : value;
|
|
74228
|
+
}
|
|
74229
|
+
function getSide(placement) {
|
|
74230
|
+
return placement.split('-')[0];
|
|
74231
|
+
}
|
|
74232
|
+
function getAlignment(placement) {
|
|
74233
|
+
return placement.split('-')[1];
|
|
74234
|
+
}
|
|
74235
|
+
function getOppositeAxis(axis) {
|
|
74236
|
+
return axis === 'x' ? 'y' : 'x';
|
|
74237
|
+
}
|
|
74238
|
+
function getAxisLength(axis) {
|
|
74239
|
+
return axis === 'y' ? 'height' : 'width';
|
|
74240
|
+
}
|
|
74241
|
+
function getSideAxis(placement) {
|
|
74242
|
+
return ['top', 'bottom'].includes(getSide(placement)) ? 'y' : 'x';
|
|
74243
|
+
}
|
|
74244
|
+
function getAlignmentAxis(placement) {
|
|
74245
|
+
return getOppositeAxis(getSideAxis(placement));
|
|
74246
|
+
}
|
|
74247
|
+
function getAlignmentSides(placement, rects, rtl) {
|
|
74248
|
+
if (rtl === void 0) {
|
|
74249
|
+
rtl = false;
|
|
74250
|
+
}
|
|
74251
|
+
const alignment = getAlignment(placement);
|
|
74252
|
+
const alignmentAxis = getAlignmentAxis(placement);
|
|
74253
|
+
const length = getAxisLength(alignmentAxis);
|
|
74254
|
+
let mainAlignmentSide = alignmentAxis === 'x' ? alignment === (rtl ? 'end' : 'start') ? 'right' : 'left' : alignment === 'start' ? 'bottom' : 'top';
|
|
74255
|
+
if (rects.reference[length] > rects.floating[length]) {
|
|
74256
|
+
mainAlignmentSide = getOppositePlacement(mainAlignmentSide);
|
|
74257
|
+
}
|
|
74258
|
+
return [mainAlignmentSide, getOppositePlacement(mainAlignmentSide)];
|
|
74259
|
+
}
|
|
74260
|
+
function getExpandedPlacements(placement) {
|
|
74261
|
+
const oppositePlacement = getOppositePlacement(placement);
|
|
74262
|
+
return [getOppositeAlignmentPlacement(placement), oppositePlacement, getOppositeAlignmentPlacement(oppositePlacement)];
|
|
74263
|
+
}
|
|
74264
|
+
function getOppositeAlignmentPlacement(placement) {
|
|
74265
|
+
return placement.replace(/start|end/g, alignment => oppositeAlignmentMap[alignment]);
|
|
74266
|
+
}
|
|
74267
|
+
function getSideList(side, isStart, rtl) {
|
|
74268
|
+
const lr = ['left', 'right'];
|
|
74269
|
+
const rl = ['right', 'left'];
|
|
74270
|
+
const tb = ['top', 'bottom'];
|
|
74271
|
+
const bt = ['bottom', 'top'];
|
|
74272
|
+
switch (side) {
|
|
74273
|
+
case 'top':
|
|
74274
|
+
case 'bottom':
|
|
74275
|
+
if (rtl) return isStart ? rl : lr;
|
|
74276
|
+
return isStart ? lr : rl;
|
|
74277
|
+
case 'left':
|
|
74278
|
+
case 'right':
|
|
74279
|
+
return isStart ? tb : bt;
|
|
74280
|
+
default:
|
|
74281
|
+
return [];
|
|
74282
|
+
}
|
|
74283
|
+
}
|
|
74284
|
+
function getOppositeAxisPlacements(placement, flipAlignment, direction, rtl) {
|
|
74285
|
+
const alignment = getAlignment(placement);
|
|
74286
|
+
let list = getSideList(getSide(placement), direction === 'start', rtl);
|
|
74287
|
+
if (alignment) {
|
|
74288
|
+
list = list.map(side => side + "-" + alignment);
|
|
74289
|
+
if (flipAlignment) {
|
|
74290
|
+
list = list.concat(list.map(getOppositeAlignmentPlacement));
|
|
74291
|
+
}
|
|
74292
|
+
}
|
|
74293
|
+
return list;
|
|
74294
|
+
}
|
|
74295
|
+
function getOppositePlacement(placement) {
|
|
74296
|
+
return placement.replace(/left|right|bottom|top/g, side => oppositeSideMap[side]);
|
|
74297
|
+
}
|
|
74298
|
+
function expandPaddingObject(padding) {
|
|
74299
|
+
return {
|
|
74300
|
+
top: 0,
|
|
74301
|
+
right: 0,
|
|
74302
|
+
bottom: 0,
|
|
74303
|
+
left: 0,
|
|
74304
|
+
...padding
|
|
74305
|
+
};
|
|
74306
|
+
}
|
|
74307
|
+
function getPaddingObject(padding) {
|
|
74308
|
+
return typeof padding !== 'number' ? expandPaddingObject(padding) : {
|
|
74309
|
+
top: padding,
|
|
74310
|
+
right: padding,
|
|
74311
|
+
bottom: padding,
|
|
74312
|
+
left: padding
|
|
74313
|
+
};
|
|
74314
|
+
}
|
|
74315
|
+
function rectToClientRect(rect) {
|
|
74316
|
+
const {
|
|
74317
|
+
x,
|
|
74318
|
+
y,
|
|
74319
|
+
width,
|
|
74320
|
+
height
|
|
74321
|
+
} = rect;
|
|
74322
|
+
return {
|
|
74323
|
+
width,
|
|
74324
|
+
height,
|
|
74325
|
+
top: y,
|
|
74326
|
+
left: x,
|
|
74327
|
+
right: x + width,
|
|
74328
|
+
bottom: y + height,
|
|
74329
|
+
x,
|
|
74330
|
+
y
|
|
74331
|
+
};
|
|
74332
|
+
}
|
|
74333
|
+
|
|
74334
|
+
function computeCoordsFromPlacement(_ref, placement, rtl) {
|
|
74335
|
+
let {
|
|
74336
|
+
reference,
|
|
74337
|
+
floating
|
|
74338
|
+
} = _ref;
|
|
74339
|
+
const sideAxis = getSideAxis(placement);
|
|
74340
|
+
const alignmentAxis = getAlignmentAxis(placement);
|
|
74341
|
+
const alignLength = getAxisLength(alignmentAxis);
|
|
74342
|
+
const side = getSide(placement);
|
|
74343
|
+
const isVertical = sideAxis === 'y';
|
|
74344
|
+
const commonX = reference.x + reference.width / 2 - floating.width / 2;
|
|
74345
|
+
const commonY = reference.y + reference.height / 2 - floating.height / 2;
|
|
74346
|
+
const commonAlign = reference[alignLength] / 2 - floating[alignLength] / 2;
|
|
74347
|
+
let coords;
|
|
74348
|
+
switch (side) {
|
|
74349
|
+
case 'top':
|
|
74350
|
+
coords = {
|
|
74351
|
+
x: commonX,
|
|
74352
|
+
y: reference.y - floating.height
|
|
74353
|
+
};
|
|
74354
|
+
break;
|
|
74355
|
+
case 'bottom':
|
|
74356
|
+
coords = {
|
|
74357
|
+
x: commonX,
|
|
74358
|
+
y: reference.y + reference.height
|
|
74359
|
+
};
|
|
74360
|
+
break;
|
|
74361
|
+
case 'right':
|
|
74362
|
+
coords = {
|
|
74363
|
+
x: reference.x + reference.width,
|
|
74364
|
+
y: commonY
|
|
74365
|
+
};
|
|
74366
|
+
break;
|
|
74367
|
+
case 'left':
|
|
74368
|
+
coords = {
|
|
74369
|
+
x: reference.x - floating.width,
|
|
74370
|
+
y: commonY
|
|
74371
|
+
};
|
|
74372
|
+
break;
|
|
74373
|
+
default:
|
|
74374
|
+
coords = {
|
|
74375
|
+
x: reference.x,
|
|
74376
|
+
y: reference.y
|
|
74377
|
+
};
|
|
74378
|
+
}
|
|
74379
|
+
switch (getAlignment(placement)) {
|
|
74380
|
+
case 'start':
|
|
74381
|
+
coords[alignmentAxis] -= commonAlign * (rtl && isVertical ? -1 : 1);
|
|
74382
|
+
break;
|
|
74383
|
+
case 'end':
|
|
74384
|
+
coords[alignmentAxis] += commonAlign * (rtl && isVertical ? -1 : 1);
|
|
74385
|
+
break;
|
|
74386
|
+
}
|
|
74387
|
+
return coords;
|
|
74388
|
+
}
|
|
74389
|
+
|
|
74390
|
+
/**
|
|
74391
|
+
* Computes the `x` and `y` coordinates that will place the floating element
|
|
74392
|
+
* next to a given reference element.
|
|
74393
|
+
*
|
|
74394
|
+
* This export does not have any `platform` interface logic. You will need to
|
|
74395
|
+
* write one for the platform you are using Floating UI with.
|
|
74396
|
+
*/
|
|
74397
|
+
const computePosition$1 = async (reference, floating, config) => {
|
|
74398
|
+
const {
|
|
74399
|
+
placement = 'bottom',
|
|
74400
|
+
strategy = 'absolute',
|
|
74401
|
+
middleware = [],
|
|
74402
|
+
platform
|
|
74403
|
+
} = config;
|
|
74404
|
+
const validMiddleware = middleware.filter(Boolean);
|
|
74405
|
+
const rtl = await (platform.isRTL == null ? void 0 : platform.isRTL(floating));
|
|
74406
|
+
let rects = await platform.getElementRects({
|
|
74407
|
+
reference,
|
|
74408
|
+
floating,
|
|
74409
|
+
strategy
|
|
74410
|
+
});
|
|
74411
|
+
let {
|
|
74412
|
+
x,
|
|
74413
|
+
y
|
|
74414
|
+
} = computeCoordsFromPlacement(rects, placement, rtl);
|
|
74415
|
+
let statefulPlacement = placement;
|
|
74416
|
+
let middlewareData = {};
|
|
74417
|
+
let resetCount = 0;
|
|
74418
|
+
for (let i = 0; i < validMiddleware.length; i++) {
|
|
74419
|
+
const {
|
|
74420
|
+
name,
|
|
74421
|
+
fn
|
|
74422
|
+
} = validMiddleware[i];
|
|
74423
|
+
const {
|
|
74424
|
+
x: nextX,
|
|
74425
|
+
y: nextY,
|
|
74426
|
+
data,
|
|
74427
|
+
reset
|
|
74428
|
+
} = await fn({
|
|
74429
|
+
x,
|
|
74430
|
+
y,
|
|
74431
|
+
initialPlacement: placement,
|
|
74432
|
+
placement: statefulPlacement,
|
|
74433
|
+
strategy,
|
|
74434
|
+
middlewareData,
|
|
74435
|
+
rects,
|
|
74436
|
+
platform,
|
|
74437
|
+
elements: {
|
|
74438
|
+
reference,
|
|
74439
|
+
floating
|
|
74440
|
+
}
|
|
74441
|
+
});
|
|
74442
|
+
x = nextX != null ? nextX : x;
|
|
74443
|
+
y = nextY != null ? nextY : y;
|
|
74444
|
+
middlewareData = {
|
|
74445
|
+
...middlewareData,
|
|
74446
|
+
[name]: {
|
|
74447
|
+
...middlewareData[name],
|
|
74448
|
+
...data
|
|
74449
|
+
}
|
|
74450
|
+
};
|
|
74451
|
+
if (reset && resetCount <= 50) {
|
|
74452
|
+
resetCount++;
|
|
74453
|
+
if (typeof reset === 'object') {
|
|
74454
|
+
if (reset.placement) {
|
|
74455
|
+
statefulPlacement = reset.placement;
|
|
74456
|
+
}
|
|
74457
|
+
if (reset.rects) {
|
|
74458
|
+
rects = reset.rects === true ? await platform.getElementRects({
|
|
74459
|
+
reference,
|
|
74460
|
+
floating,
|
|
74461
|
+
strategy
|
|
74462
|
+
}) : reset.rects;
|
|
74463
|
+
}
|
|
74464
|
+
({
|
|
74465
|
+
x,
|
|
74466
|
+
y
|
|
74467
|
+
} = computeCoordsFromPlacement(rects, statefulPlacement, rtl));
|
|
74468
|
+
}
|
|
74469
|
+
i = -1;
|
|
74470
|
+
}
|
|
74471
|
+
}
|
|
74472
|
+
return {
|
|
74473
|
+
x,
|
|
74474
|
+
y,
|
|
74475
|
+
placement: statefulPlacement,
|
|
74476
|
+
strategy,
|
|
74477
|
+
middlewareData
|
|
74478
|
+
};
|
|
74479
|
+
};
|
|
74480
|
+
|
|
74481
|
+
/**
|
|
74482
|
+
* Resolves with an object of overflow side offsets that determine how much the
|
|
74483
|
+
* element is overflowing a given clipping boundary on each side.
|
|
74484
|
+
* - positive = overflowing the boundary by that number of pixels
|
|
74485
|
+
* - negative = how many pixels left before it will overflow
|
|
74486
|
+
* - 0 = lies flush with the boundary
|
|
74487
|
+
* @see https://floating-ui.com/docs/detectOverflow
|
|
74488
|
+
*/
|
|
74489
|
+
async function detectOverflow(state, options) {
|
|
74490
|
+
var _await$platform$isEle;
|
|
74491
|
+
if (options === void 0) {
|
|
74492
|
+
options = {};
|
|
74493
|
+
}
|
|
74494
|
+
const {
|
|
74495
|
+
x,
|
|
74496
|
+
y,
|
|
74497
|
+
platform,
|
|
74498
|
+
rects,
|
|
74499
|
+
elements,
|
|
74500
|
+
strategy
|
|
74501
|
+
} = state;
|
|
74502
|
+
const {
|
|
74503
|
+
boundary = 'clippingAncestors',
|
|
74504
|
+
rootBoundary = 'viewport',
|
|
74505
|
+
elementContext = 'floating',
|
|
74506
|
+
altBoundary = false,
|
|
74507
|
+
padding = 0
|
|
74508
|
+
} = evaluate(options, state);
|
|
74509
|
+
const paddingObject = getPaddingObject(padding);
|
|
74510
|
+
const altContext = elementContext === 'floating' ? 'reference' : 'floating';
|
|
74511
|
+
const element = elements[altBoundary ? altContext : elementContext];
|
|
74512
|
+
const clippingClientRect = rectToClientRect(await platform.getClippingRect({
|
|
74513
|
+
element: ((_await$platform$isEle = await (platform.isElement == null ? void 0 : platform.isElement(element))) != null ? _await$platform$isEle : true) ? element : element.contextElement || (await (platform.getDocumentElement == null ? void 0 : platform.getDocumentElement(elements.floating))),
|
|
74514
|
+
boundary,
|
|
74515
|
+
rootBoundary,
|
|
74516
|
+
strategy
|
|
74517
|
+
}));
|
|
74518
|
+
const rect = elementContext === 'floating' ? {
|
|
74519
|
+
x,
|
|
74520
|
+
y,
|
|
74521
|
+
width: rects.floating.width,
|
|
74522
|
+
height: rects.floating.height
|
|
74523
|
+
} : rects.reference;
|
|
74524
|
+
const offsetParent = await (platform.getOffsetParent == null ? void 0 : platform.getOffsetParent(elements.floating));
|
|
74525
|
+
const offsetScale = (await (platform.isElement == null ? void 0 : platform.isElement(offsetParent))) ? (await (platform.getScale == null ? void 0 : platform.getScale(offsetParent))) || {
|
|
74526
|
+
x: 1,
|
|
74527
|
+
y: 1
|
|
74528
|
+
} : {
|
|
74529
|
+
x: 1,
|
|
74530
|
+
y: 1
|
|
74531
|
+
};
|
|
74532
|
+
const elementClientRect = rectToClientRect(platform.convertOffsetParentRelativeRectToViewportRelativeRect ? await platform.convertOffsetParentRelativeRectToViewportRelativeRect({
|
|
74533
|
+
elements,
|
|
74534
|
+
rect,
|
|
74535
|
+
offsetParent,
|
|
74536
|
+
strategy
|
|
74537
|
+
}) : rect);
|
|
74538
|
+
return {
|
|
74539
|
+
top: (clippingClientRect.top - elementClientRect.top + paddingObject.top) / offsetScale.y,
|
|
74540
|
+
bottom: (elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom) / offsetScale.y,
|
|
74541
|
+
left: (clippingClientRect.left - elementClientRect.left + paddingObject.left) / offsetScale.x,
|
|
74542
|
+
right: (elementClientRect.right - clippingClientRect.right + paddingObject.right) / offsetScale.x
|
|
74543
|
+
};
|
|
74544
|
+
}
|
|
74545
|
+
|
|
74546
|
+
/**
|
|
74547
|
+
* Optimizes the visibility of the floating element by flipping the `placement`
|
|
74548
|
+
* in order to keep it in view when the preferred placement(s) will overflow the
|
|
74549
|
+
* clipping boundary. Alternative to `autoPlacement`.
|
|
74550
|
+
* @see https://floating-ui.com/docs/flip
|
|
74551
|
+
*/
|
|
74552
|
+
const flip$1 = function (options) {
|
|
74553
|
+
if (options === void 0) {
|
|
74554
|
+
options = {};
|
|
74555
|
+
}
|
|
74556
|
+
return {
|
|
74557
|
+
name: 'flip',
|
|
74558
|
+
options,
|
|
74559
|
+
async fn(state) {
|
|
74560
|
+
var _middlewareData$arrow, _middlewareData$flip;
|
|
74561
|
+
const {
|
|
74562
|
+
placement,
|
|
74563
|
+
middlewareData,
|
|
74564
|
+
rects,
|
|
74565
|
+
initialPlacement,
|
|
74566
|
+
platform,
|
|
74567
|
+
elements
|
|
74568
|
+
} = state;
|
|
74569
|
+
const {
|
|
74570
|
+
mainAxis: checkMainAxis = true,
|
|
74571
|
+
crossAxis: checkCrossAxis = true,
|
|
74572
|
+
fallbackPlacements: specifiedFallbackPlacements,
|
|
74573
|
+
fallbackStrategy = 'bestFit',
|
|
74574
|
+
fallbackAxisSideDirection = 'none',
|
|
74575
|
+
flipAlignment = true,
|
|
74576
|
+
...detectOverflowOptions
|
|
74577
|
+
} = evaluate(options, state);
|
|
74578
|
+
|
|
74579
|
+
// If a reset by the arrow was caused due to an alignment offset being
|
|
74580
|
+
// added, we should skip any logic now since `flip()` has already done its
|
|
74581
|
+
// work.
|
|
74582
|
+
// https://github.com/floating-ui/floating-ui/issues/2549#issuecomment-1719601643
|
|
74583
|
+
if ((_middlewareData$arrow = middlewareData.arrow) != null && _middlewareData$arrow.alignmentOffset) {
|
|
74584
|
+
return {};
|
|
74585
|
+
}
|
|
74586
|
+
const side = getSide(placement);
|
|
74587
|
+
const initialSideAxis = getSideAxis(initialPlacement);
|
|
74588
|
+
const isBasePlacement = getSide(initialPlacement) === initialPlacement;
|
|
74589
|
+
const rtl = await (platform.isRTL == null ? void 0 : platform.isRTL(elements.floating));
|
|
74590
|
+
const fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipAlignment ? [getOppositePlacement(initialPlacement)] : getExpandedPlacements(initialPlacement));
|
|
74591
|
+
const hasFallbackAxisSideDirection = fallbackAxisSideDirection !== 'none';
|
|
74592
|
+
if (!specifiedFallbackPlacements && hasFallbackAxisSideDirection) {
|
|
74593
|
+
fallbackPlacements.push(...getOppositeAxisPlacements(initialPlacement, flipAlignment, fallbackAxisSideDirection, rtl));
|
|
74594
|
+
}
|
|
74595
|
+
const placements = [initialPlacement, ...fallbackPlacements];
|
|
74596
|
+
const overflow = await detectOverflow(state, detectOverflowOptions);
|
|
74597
|
+
const overflows = [];
|
|
74598
|
+
let overflowsData = ((_middlewareData$flip = middlewareData.flip) == null ? void 0 : _middlewareData$flip.overflows) || [];
|
|
74599
|
+
if (checkMainAxis) {
|
|
74600
|
+
overflows.push(overflow[side]);
|
|
74601
|
+
}
|
|
74602
|
+
if (checkCrossAxis) {
|
|
74603
|
+
const sides = getAlignmentSides(placement, rects, rtl);
|
|
74604
|
+
overflows.push(overflow[sides[0]], overflow[sides[1]]);
|
|
74605
|
+
}
|
|
74606
|
+
overflowsData = [...overflowsData, {
|
|
74607
|
+
placement,
|
|
74608
|
+
overflows
|
|
74609
|
+
}];
|
|
74610
|
+
|
|
74611
|
+
// One or more sides is overflowing.
|
|
74612
|
+
if (!overflows.every(side => side <= 0)) {
|
|
74613
|
+
var _middlewareData$flip2, _overflowsData$filter;
|
|
74614
|
+
const nextIndex = (((_middlewareData$flip2 = middlewareData.flip) == null ? void 0 : _middlewareData$flip2.index) || 0) + 1;
|
|
74615
|
+
const nextPlacement = placements[nextIndex];
|
|
74616
|
+
if (nextPlacement) {
|
|
74617
|
+
// Try next placement and re-run the lifecycle.
|
|
74618
|
+
return {
|
|
74619
|
+
data: {
|
|
74620
|
+
index: nextIndex,
|
|
74621
|
+
overflows: overflowsData
|
|
74622
|
+
},
|
|
74623
|
+
reset: {
|
|
74624
|
+
placement: nextPlacement
|
|
74625
|
+
}
|
|
74626
|
+
};
|
|
74627
|
+
}
|
|
74628
|
+
|
|
74629
|
+
// First, find the candidates that fit on the mainAxis side of overflow,
|
|
74630
|
+
// then find the placement that fits the best on the main crossAxis side.
|
|
74631
|
+
let resetPlacement = (_overflowsData$filter = overflowsData.filter(d => d.overflows[0] <= 0).sort((a, b) => a.overflows[1] - b.overflows[1])[0]) == null ? void 0 : _overflowsData$filter.placement;
|
|
74632
|
+
|
|
74633
|
+
// Otherwise fallback.
|
|
74634
|
+
if (!resetPlacement) {
|
|
74635
|
+
switch (fallbackStrategy) {
|
|
74636
|
+
case 'bestFit':
|
|
74637
|
+
{
|
|
74638
|
+
var _overflowsData$filter2;
|
|
74639
|
+
const placement = (_overflowsData$filter2 = overflowsData.filter(d => {
|
|
74640
|
+
if (hasFallbackAxisSideDirection) {
|
|
74641
|
+
const currentSideAxis = getSideAxis(d.placement);
|
|
74642
|
+
return currentSideAxis === initialSideAxis ||
|
|
74643
|
+
// Create a bias to the `y` side axis due to horizontal
|
|
74644
|
+
// reading directions favoring greater width.
|
|
74645
|
+
currentSideAxis === 'y';
|
|
74646
|
+
}
|
|
74647
|
+
return true;
|
|
74648
|
+
}).map(d => [d.placement, d.overflows.filter(overflow => overflow > 0).reduce((acc, overflow) => acc + overflow, 0)]).sort((a, b) => a[1] - b[1])[0]) == null ? void 0 : _overflowsData$filter2[0];
|
|
74649
|
+
if (placement) {
|
|
74650
|
+
resetPlacement = placement;
|
|
74651
|
+
}
|
|
74652
|
+
break;
|
|
74653
|
+
}
|
|
74654
|
+
case 'initialPlacement':
|
|
74655
|
+
resetPlacement = initialPlacement;
|
|
74656
|
+
break;
|
|
74657
|
+
}
|
|
74658
|
+
}
|
|
74659
|
+
if (placement !== resetPlacement) {
|
|
74660
|
+
return {
|
|
74661
|
+
reset: {
|
|
74662
|
+
placement: resetPlacement
|
|
74663
|
+
}
|
|
74664
|
+
};
|
|
74665
|
+
}
|
|
74666
|
+
}
|
|
74667
|
+
return {};
|
|
74668
|
+
}
|
|
74669
|
+
};
|
|
74670
|
+
};
|
|
74671
|
+
|
|
74672
|
+
/**
|
|
74673
|
+
* Optimizes the visibility of the floating element by shifting it in order to
|
|
74674
|
+
* keep it in view when it will overflow the clipping boundary.
|
|
74675
|
+
* @see https://floating-ui.com/docs/shift
|
|
74676
|
+
*/
|
|
74677
|
+
const shift$1 = function (options) {
|
|
74678
|
+
if (options === void 0) {
|
|
74679
|
+
options = {};
|
|
74680
|
+
}
|
|
74681
|
+
return {
|
|
74682
|
+
name: 'shift',
|
|
74683
|
+
options,
|
|
74684
|
+
async fn(state) {
|
|
74685
|
+
const {
|
|
74686
|
+
x,
|
|
74687
|
+
y,
|
|
74688
|
+
placement
|
|
74689
|
+
} = state;
|
|
74690
|
+
const {
|
|
74691
|
+
mainAxis: checkMainAxis = true,
|
|
74692
|
+
crossAxis: checkCrossAxis = false,
|
|
74693
|
+
limiter = {
|
|
74694
|
+
fn: _ref => {
|
|
74695
|
+
let {
|
|
74696
|
+
x,
|
|
74697
|
+
y
|
|
74698
|
+
} = _ref;
|
|
74699
|
+
return {
|
|
74700
|
+
x,
|
|
74701
|
+
y
|
|
74702
|
+
};
|
|
74703
|
+
}
|
|
74704
|
+
},
|
|
74705
|
+
...detectOverflowOptions
|
|
74706
|
+
} = evaluate(options, state);
|
|
74707
|
+
const coords = {
|
|
74708
|
+
x,
|
|
74709
|
+
y
|
|
74710
|
+
};
|
|
74711
|
+
const overflow = await detectOverflow(state, detectOverflowOptions);
|
|
74712
|
+
const crossAxis = getSideAxis(getSide(placement));
|
|
74713
|
+
const mainAxis = getOppositeAxis(crossAxis);
|
|
74714
|
+
let mainAxisCoord = coords[mainAxis];
|
|
74715
|
+
let crossAxisCoord = coords[crossAxis];
|
|
74716
|
+
if (checkMainAxis) {
|
|
74717
|
+
const minSide = mainAxis === 'y' ? 'top' : 'left';
|
|
74718
|
+
const maxSide = mainAxis === 'y' ? 'bottom' : 'right';
|
|
74719
|
+
const min = mainAxisCoord + overflow[minSide];
|
|
74720
|
+
const max = mainAxisCoord - overflow[maxSide];
|
|
74721
|
+
mainAxisCoord = clamp(min, mainAxisCoord, max);
|
|
74722
|
+
}
|
|
74723
|
+
if (checkCrossAxis) {
|
|
74724
|
+
const minSide = crossAxis === 'y' ? 'top' : 'left';
|
|
74725
|
+
const maxSide = crossAxis === 'y' ? 'bottom' : 'right';
|
|
74726
|
+
const min = crossAxisCoord + overflow[minSide];
|
|
74727
|
+
const max = crossAxisCoord - overflow[maxSide];
|
|
74728
|
+
crossAxisCoord = clamp(min, crossAxisCoord, max);
|
|
74729
|
+
}
|
|
74730
|
+
const limitedCoords = limiter.fn({
|
|
74731
|
+
...state,
|
|
74732
|
+
[mainAxis]: mainAxisCoord,
|
|
74733
|
+
[crossAxis]: crossAxisCoord
|
|
74734
|
+
});
|
|
74735
|
+
return {
|
|
74736
|
+
...limitedCoords,
|
|
74737
|
+
data: {
|
|
74738
|
+
x: limitedCoords.x - x,
|
|
74739
|
+
y: limitedCoords.y - y,
|
|
74740
|
+
enabled: {
|
|
74741
|
+
[mainAxis]: checkMainAxis,
|
|
74742
|
+
[crossAxis]: checkCrossAxis
|
|
74743
|
+
}
|
|
74744
|
+
}
|
|
74745
|
+
};
|
|
74746
|
+
}
|
|
74747
|
+
};
|
|
74748
|
+
};
|
|
74749
|
+
|
|
74750
|
+
function hasWindow() {
|
|
74751
|
+
return typeof window !== 'undefined';
|
|
74752
|
+
}
|
|
74753
|
+
function getNodeName(node) {
|
|
74754
|
+
if (isNode(node)) {
|
|
74755
|
+
return (node.nodeName || '').toLowerCase();
|
|
74756
|
+
}
|
|
74757
|
+
// Mocked nodes in testing environments may not be instances of Node. By
|
|
74758
|
+
// returning `#document` an infinite loop won't occur.
|
|
74759
|
+
// https://github.com/floating-ui/floating-ui/issues/2317
|
|
74760
|
+
return '#document';
|
|
74761
|
+
}
|
|
74762
|
+
function getWindow(node) {
|
|
74763
|
+
var _node$ownerDocument;
|
|
74764
|
+
return (node == null || (_node$ownerDocument = node.ownerDocument) == null ? void 0 : _node$ownerDocument.defaultView) || window;
|
|
74765
|
+
}
|
|
74766
|
+
function getDocumentElement(node) {
|
|
74767
|
+
var _ref;
|
|
74768
|
+
return (_ref = (isNode(node) ? node.ownerDocument : node.document) || window.document) == null ? void 0 : _ref.documentElement;
|
|
74769
|
+
}
|
|
74770
|
+
function isNode(value) {
|
|
74771
|
+
if (!hasWindow()) {
|
|
74772
|
+
return false;
|
|
74773
|
+
}
|
|
74774
|
+
return value instanceof Node || value instanceof getWindow(value).Node;
|
|
74775
|
+
}
|
|
74776
|
+
function isElement(value) {
|
|
74777
|
+
if (!hasWindow()) {
|
|
74778
|
+
return false;
|
|
74779
|
+
}
|
|
74780
|
+
return value instanceof Element || value instanceof getWindow(value).Element;
|
|
74781
|
+
}
|
|
74782
|
+
function isHTMLElement(value) {
|
|
74783
|
+
if (!hasWindow()) {
|
|
74784
|
+
return false;
|
|
74785
|
+
}
|
|
74786
|
+
return value instanceof HTMLElement || value instanceof getWindow(value).HTMLElement;
|
|
74787
|
+
}
|
|
74788
|
+
function isShadowRoot(value) {
|
|
74789
|
+
if (!hasWindow() || typeof ShadowRoot === 'undefined') {
|
|
74790
|
+
return false;
|
|
74791
|
+
}
|
|
74792
|
+
return value instanceof ShadowRoot || value instanceof getWindow(value).ShadowRoot;
|
|
74793
|
+
}
|
|
74794
|
+
function isOverflowElement(element) {
|
|
74795
|
+
const {
|
|
74796
|
+
overflow,
|
|
74797
|
+
overflowX,
|
|
74798
|
+
overflowY,
|
|
74799
|
+
display
|
|
74800
|
+
} = getComputedStyle$1(element);
|
|
74801
|
+
return /auto|scroll|overlay|hidden|clip/.test(overflow + overflowY + overflowX) && !['inline', 'contents'].includes(display);
|
|
74802
|
+
}
|
|
74803
|
+
function isTableElement(element) {
|
|
74804
|
+
return ['table', 'td', 'th'].includes(getNodeName(element));
|
|
74805
|
+
}
|
|
74806
|
+
function isTopLayer(element) {
|
|
74807
|
+
return [':popover-open', ':modal'].some(selector => {
|
|
74808
|
+
try {
|
|
74809
|
+
return element.matches(selector);
|
|
74810
|
+
} catch (e) {
|
|
74811
|
+
return false;
|
|
74812
|
+
}
|
|
74813
|
+
});
|
|
74814
|
+
}
|
|
74815
|
+
function isContainingBlock(elementOrCss) {
|
|
74816
|
+
const webkit = isWebKit();
|
|
74817
|
+
const css = isElement(elementOrCss) ? getComputedStyle$1(elementOrCss) : elementOrCss;
|
|
74818
|
+
|
|
74819
|
+
// https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block
|
|
74820
|
+
return css.transform !== 'none' || css.perspective !== 'none' || (css.containerType ? css.containerType !== 'normal' : false) || !webkit && (css.backdropFilter ? css.backdropFilter !== 'none' : false) || !webkit && (css.filter ? css.filter !== 'none' : false) || ['transform', 'perspective', 'filter'].some(value => (css.willChange || '').includes(value)) || ['paint', 'layout', 'strict', 'content'].some(value => (css.contain || '').includes(value));
|
|
74821
|
+
}
|
|
74822
|
+
function getContainingBlock(element) {
|
|
74823
|
+
let currentNode = getParentNode(element);
|
|
74824
|
+
while (isHTMLElement(currentNode) && !isLastTraversableNode(currentNode)) {
|
|
74825
|
+
if (isContainingBlock(currentNode)) {
|
|
74826
|
+
return currentNode;
|
|
74827
|
+
} else if (isTopLayer(currentNode)) {
|
|
74828
|
+
return null;
|
|
74829
|
+
}
|
|
74830
|
+
currentNode = getParentNode(currentNode);
|
|
74831
|
+
}
|
|
74832
|
+
return null;
|
|
74833
|
+
}
|
|
74834
|
+
function isWebKit() {
|
|
74835
|
+
if (typeof CSS === 'undefined' || !CSS.supports) return false;
|
|
74836
|
+
return CSS.supports('-webkit-backdrop-filter', 'none');
|
|
74837
|
+
}
|
|
74838
|
+
function isLastTraversableNode(node) {
|
|
74839
|
+
return ['html', 'body', '#document'].includes(getNodeName(node));
|
|
74840
|
+
}
|
|
74841
|
+
function getComputedStyle$1(element) {
|
|
74842
|
+
return getWindow(element).getComputedStyle(element);
|
|
74843
|
+
}
|
|
74844
|
+
function getNodeScroll(element) {
|
|
74845
|
+
if (isElement(element)) {
|
|
74846
|
+
return {
|
|
74847
|
+
scrollLeft: element.scrollLeft,
|
|
74848
|
+
scrollTop: element.scrollTop
|
|
74849
|
+
};
|
|
74850
|
+
}
|
|
74851
|
+
return {
|
|
74852
|
+
scrollLeft: element.scrollX,
|
|
74853
|
+
scrollTop: element.scrollY
|
|
74854
|
+
};
|
|
74855
|
+
}
|
|
74856
|
+
function getParentNode(node) {
|
|
74857
|
+
if (getNodeName(node) === 'html') {
|
|
74858
|
+
return node;
|
|
74859
|
+
}
|
|
74860
|
+
const result =
|
|
74861
|
+
// Step into the shadow DOM of the parent of a slotted node.
|
|
74862
|
+
node.assignedSlot ||
|
|
74863
|
+
// DOM Element detected.
|
|
74864
|
+
node.parentNode ||
|
|
74865
|
+
// ShadowRoot detected.
|
|
74866
|
+
isShadowRoot(node) && node.host ||
|
|
74867
|
+
// Fallback.
|
|
74868
|
+
getDocumentElement(node);
|
|
74869
|
+
return isShadowRoot(result) ? result.host : result;
|
|
74870
|
+
}
|
|
74871
|
+
function getNearestOverflowAncestor(node) {
|
|
74872
|
+
const parentNode = getParentNode(node);
|
|
74873
|
+
if (isLastTraversableNode(parentNode)) {
|
|
74874
|
+
return node.ownerDocument ? node.ownerDocument.body : node.body;
|
|
74875
|
+
}
|
|
74876
|
+
if (isHTMLElement(parentNode) && isOverflowElement(parentNode)) {
|
|
74877
|
+
return parentNode;
|
|
74878
|
+
}
|
|
74879
|
+
return getNearestOverflowAncestor(parentNode);
|
|
74880
|
+
}
|
|
74881
|
+
function getOverflowAncestors(node, list, traverseIframes) {
|
|
74882
|
+
var _node$ownerDocument2;
|
|
74883
|
+
if (list === void 0) {
|
|
74884
|
+
list = [];
|
|
74885
|
+
}
|
|
74886
|
+
if (traverseIframes === void 0) {
|
|
74887
|
+
traverseIframes = true;
|
|
74888
|
+
}
|
|
74889
|
+
const scrollableAncestor = getNearestOverflowAncestor(node);
|
|
74890
|
+
const isBody = scrollableAncestor === ((_node$ownerDocument2 = node.ownerDocument) == null ? void 0 : _node$ownerDocument2.body);
|
|
74891
|
+
const win = getWindow(scrollableAncestor);
|
|
74892
|
+
if (isBody) {
|
|
74893
|
+
const frameElement = getFrameElement(win);
|
|
74894
|
+
return list.concat(win, win.visualViewport || [], isOverflowElement(scrollableAncestor) ? scrollableAncestor : [], frameElement && traverseIframes ? getOverflowAncestors(frameElement) : []);
|
|
74895
|
+
}
|
|
74896
|
+
return list.concat(scrollableAncestor, getOverflowAncestors(scrollableAncestor, [], traverseIframes));
|
|
74897
|
+
}
|
|
74898
|
+
function getFrameElement(win) {
|
|
74899
|
+
return win.parent && Object.getPrototypeOf(win.parent) ? win.frameElement : null;
|
|
74900
|
+
}
|
|
74901
|
+
|
|
74902
|
+
function getCssDimensions(element) {
|
|
74903
|
+
const css = getComputedStyle$1(element);
|
|
74904
|
+
// In testing environments, the `width` and `height` properties are empty
|
|
74905
|
+
// strings for SVG elements, returning NaN. Fallback to `0` in this case.
|
|
74906
|
+
let width = parseFloat(css.width) || 0;
|
|
74907
|
+
let height = parseFloat(css.height) || 0;
|
|
74908
|
+
const hasOffset = isHTMLElement(element);
|
|
74909
|
+
const offsetWidth = hasOffset ? element.offsetWidth : width;
|
|
74910
|
+
const offsetHeight = hasOffset ? element.offsetHeight : height;
|
|
74911
|
+
const shouldFallback = round(width) !== offsetWidth || round(height) !== offsetHeight;
|
|
74912
|
+
if (shouldFallback) {
|
|
74913
|
+
width = offsetWidth;
|
|
74914
|
+
height = offsetHeight;
|
|
74915
|
+
}
|
|
74916
|
+
return {
|
|
74917
|
+
width,
|
|
74918
|
+
height,
|
|
74919
|
+
$: shouldFallback
|
|
74920
|
+
};
|
|
74921
|
+
}
|
|
74922
|
+
|
|
74923
|
+
function unwrapElement(element) {
|
|
74924
|
+
return !isElement(element) ? element.contextElement : element;
|
|
74925
|
+
}
|
|
74926
|
+
|
|
74927
|
+
function getScale(element) {
|
|
74928
|
+
const domElement = unwrapElement(element);
|
|
74929
|
+
if (!isHTMLElement(domElement)) {
|
|
74930
|
+
return createCoords(1);
|
|
74931
|
+
}
|
|
74932
|
+
const rect = domElement.getBoundingClientRect();
|
|
74933
|
+
const {
|
|
74934
|
+
width,
|
|
74935
|
+
height,
|
|
74936
|
+
$
|
|
74937
|
+
} = getCssDimensions(domElement);
|
|
74938
|
+
let x = ($ ? round(rect.width) : rect.width) / width;
|
|
74939
|
+
let y = ($ ? round(rect.height) : rect.height) / height;
|
|
74940
|
+
|
|
74941
|
+
// 0, NaN, or Infinity should always fallback to 1.
|
|
74942
|
+
|
|
74943
|
+
if (!x || !Number.isFinite(x)) {
|
|
74944
|
+
x = 1;
|
|
74945
|
+
}
|
|
74946
|
+
if (!y || !Number.isFinite(y)) {
|
|
74947
|
+
y = 1;
|
|
74948
|
+
}
|
|
74949
|
+
return {
|
|
74950
|
+
x,
|
|
74951
|
+
y
|
|
74952
|
+
};
|
|
74953
|
+
}
|
|
74954
|
+
|
|
74955
|
+
const noOffsets = /*#__PURE__*/createCoords(0);
|
|
74956
|
+
function getVisualOffsets(element) {
|
|
74957
|
+
const win = getWindow(element);
|
|
74958
|
+
if (!isWebKit() || !win.visualViewport) {
|
|
74959
|
+
return noOffsets;
|
|
74960
|
+
}
|
|
74961
|
+
return {
|
|
74962
|
+
x: win.visualViewport.offsetLeft,
|
|
74963
|
+
y: win.visualViewport.offsetTop
|
|
74964
|
+
};
|
|
74965
|
+
}
|
|
74966
|
+
function shouldAddVisualOffsets(element, isFixed, floatingOffsetParent) {
|
|
74967
|
+
if (isFixed === void 0) {
|
|
74968
|
+
isFixed = false;
|
|
74969
|
+
}
|
|
74970
|
+
if (!floatingOffsetParent || isFixed && floatingOffsetParent !== getWindow(element)) {
|
|
74971
|
+
return false;
|
|
74972
|
+
}
|
|
74973
|
+
return isFixed;
|
|
74974
|
+
}
|
|
74975
|
+
|
|
74976
|
+
function getBoundingClientRect(element, includeScale, isFixedStrategy, offsetParent) {
|
|
74977
|
+
if (includeScale === void 0) {
|
|
74978
|
+
includeScale = false;
|
|
74979
|
+
}
|
|
74980
|
+
if (isFixedStrategy === void 0) {
|
|
74981
|
+
isFixedStrategy = false;
|
|
74982
|
+
}
|
|
74983
|
+
const clientRect = element.getBoundingClientRect();
|
|
74984
|
+
const domElement = unwrapElement(element);
|
|
74985
|
+
let scale = createCoords(1);
|
|
74986
|
+
if (includeScale) {
|
|
74987
|
+
if (offsetParent) {
|
|
74988
|
+
if (isElement(offsetParent)) {
|
|
74989
|
+
scale = getScale(offsetParent);
|
|
74990
|
+
}
|
|
74991
|
+
} else {
|
|
74992
|
+
scale = getScale(element);
|
|
74993
|
+
}
|
|
74994
|
+
}
|
|
74995
|
+
const visualOffsets = shouldAddVisualOffsets(domElement, isFixedStrategy, offsetParent) ? getVisualOffsets(domElement) : createCoords(0);
|
|
74996
|
+
let x = (clientRect.left + visualOffsets.x) / scale.x;
|
|
74997
|
+
let y = (clientRect.top + visualOffsets.y) / scale.y;
|
|
74998
|
+
let width = clientRect.width / scale.x;
|
|
74999
|
+
let height = clientRect.height / scale.y;
|
|
75000
|
+
if (domElement) {
|
|
75001
|
+
const win = getWindow(domElement);
|
|
75002
|
+
const offsetWin = offsetParent && isElement(offsetParent) ? getWindow(offsetParent) : offsetParent;
|
|
75003
|
+
let currentWin = win;
|
|
75004
|
+
let currentIFrame = getFrameElement(currentWin);
|
|
75005
|
+
while (currentIFrame && offsetParent && offsetWin !== currentWin) {
|
|
75006
|
+
const iframeScale = getScale(currentIFrame);
|
|
75007
|
+
const iframeRect = currentIFrame.getBoundingClientRect();
|
|
75008
|
+
const css = getComputedStyle$1(currentIFrame);
|
|
75009
|
+
const left = iframeRect.left + (currentIFrame.clientLeft + parseFloat(css.paddingLeft)) * iframeScale.x;
|
|
75010
|
+
const top = iframeRect.top + (currentIFrame.clientTop + parseFloat(css.paddingTop)) * iframeScale.y;
|
|
75011
|
+
x *= iframeScale.x;
|
|
75012
|
+
y *= iframeScale.y;
|
|
75013
|
+
width *= iframeScale.x;
|
|
75014
|
+
height *= iframeScale.y;
|
|
75015
|
+
x += left;
|
|
75016
|
+
y += top;
|
|
75017
|
+
currentWin = getWindow(currentIFrame);
|
|
75018
|
+
currentIFrame = getFrameElement(currentWin);
|
|
75019
|
+
}
|
|
75020
|
+
}
|
|
75021
|
+
return rectToClientRect({
|
|
75022
|
+
width,
|
|
75023
|
+
height,
|
|
75024
|
+
x,
|
|
75025
|
+
y
|
|
75026
|
+
});
|
|
75027
|
+
}
|
|
75028
|
+
|
|
75029
|
+
// If <html> has a CSS width greater than the viewport, then this will be
|
|
75030
|
+
// incorrect for RTL.
|
|
75031
|
+
function getWindowScrollBarX(element, rect) {
|
|
75032
|
+
const leftScroll = getNodeScroll(element).scrollLeft;
|
|
75033
|
+
if (!rect) {
|
|
75034
|
+
return getBoundingClientRect(getDocumentElement(element)).left + leftScroll;
|
|
75035
|
+
}
|
|
75036
|
+
return rect.left + leftScroll;
|
|
75037
|
+
}
|
|
75038
|
+
|
|
75039
|
+
function getHTMLOffset(documentElement, scroll, ignoreScrollbarX) {
|
|
75040
|
+
if (ignoreScrollbarX === void 0) {
|
|
75041
|
+
ignoreScrollbarX = false;
|
|
75042
|
+
}
|
|
75043
|
+
const htmlRect = documentElement.getBoundingClientRect();
|
|
75044
|
+
const x = htmlRect.left + scroll.scrollLeft - (ignoreScrollbarX ? 0 :
|
|
75045
|
+
// RTL <body> scrollbar.
|
|
75046
|
+
getWindowScrollBarX(documentElement, htmlRect));
|
|
75047
|
+
const y = htmlRect.top + scroll.scrollTop;
|
|
75048
|
+
return {
|
|
75049
|
+
x,
|
|
75050
|
+
y
|
|
75051
|
+
};
|
|
75052
|
+
}
|
|
75053
|
+
|
|
75054
|
+
function convertOffsetParentRelativeRectToViewportRelativeRect(_ref) {
|
|
75055
|
+
let {
|
|
75056
|
+
elements,
|
|
75057
|
+
rect,
|
|
75058
|
+
offsetParent,
|
|
75059
|
+
strategy
|
|
75060
|
+
} = _ref;
|
|
75061
|
+
const isFixed = strategy === 'fixed';
|
|
75062
|
+
const documentElement = getDocumentElement(offsetParent);
|
|
75063
|
+
const topLayer = elements ? isTopLayer(elements.floating) : false;
|
|
75064
|
+
if (offsetParent === documentElement || topLayer && isFixed) {
|
|
75065
|
+
return rect;
|
|
75066
|
+
}
|
|
75067
|
+
let scroll = {
|
|
75068
|
+
scrollLeft: 0,
|
|
75069
|
+
scrollTop: 0
|
|
75070
|
+
};
|
|
75071
|
+
let scale = createCoords(1);
|
|
75072
|
+
const offsets = createCoords(0);
|
|
75073
|
+
const isOffsetParentAnElement = isHTMLElement(offsetParent);
|
|
75074
|
+
if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {
|
|
75075
|
+
if (getNodeName(offsetParent) !== 'body' || isOverflowElement(documentElement)) {
|
|
75076
|
+
scroll = getNodeScroll(offsetParent);
|
|
75077
|
+
}
|
|
75078
|
+
if (isHTMLElement(offsetParent)) {
|
|
75079
|
+
const offsetRect = getBoundingClientRect(offsetParent);
|
|
75080
|
+
scale = getScale(offsetParent);
|
|
75081
|
+
offsets.x = offsetRect.x + offsetParent.clientLeft;
|
|
75082
|
+
offsets.y = offsetRect.y + offsetParent.clientTop;
|
|
75083
|
+
}
|
|
75084
|
+
}
|
|
75085
|
+
const htmlOffset = documentElement && !isOffsetParentAnElement && !isFixed ? getHTMLOffset(documentElement, scroll, true) : createCoords(0);
|
|
75086
|
+
return {
|
|
75087
|
+
width: rect.width * scale.x,
|
|
75088
|
+
height: rect.height * scale.y,
|
|
75089
|
+
x: rect.x * scale.x - scroll.scrollLeft * scale.x + offsets.x + htmlOffset.x,
|
|
75090
|
+
y: rect.y * scale.y - scroll.scrollTop * scale.y + offsets.y + htmlOffset.y
|
|
75091
|
+
};
|
|
75092
|
+
}
|
|
75093
|
+
|
|
75094
|
+
function getClientRects(element) {
|
|
75095
|
+
return Array.from(element.getClientRects());
|
|
75096
|
+
}
|
|
75097
|
+
|
|
75098
|
+
// Gets the entire size of the scrollable document area, even extending outside
|
|
75099
|
+
// of the `<html>` and `<body>` rect bounds if horizontally scrollable.
|
|
75100
|
+
function getDocumentRect(element) {
|
|
75101
|
+
const html = getDocumentElement(element);
|
|
75102
|
+
const scroll = getNodeScroll(element);
|
|
75103
|
+
const body = element.ownerDocument.body;
|
|
75104
|
+
const width = max(html.scrollWidth, html.clientWidth, body.scrollWidth, body.clientWidth);
|
|
75105
|
+
const height = max(html.scrollHeight, html.clientHeight, body.scrollHeight, body.clientHeight);
|
|
75106
|
+
let x = -scroll.scrollLeft + getWindowScrollBarX(element);
|
|
75107
|
+
const y = -scroll.scrollTop;
|
|
75108
|
+
if (getComputedStyle$1(body).direction === 'rtl') {
|
|
75109
|
+
x += max(html.clientWidth, body.clientWidth) - width;
|
|
75110
|
+
}
|
|
75111
|
+
return {
|
|
75112
|
+
width,
|
|
75113
|
+
height,
|
|
75114
|
+
x,
|
|
75115
|
+
y
|
|
75116
|
+
};
|
|
75117
|
+
}
|
|
75118
|
+
|
|
75119
|
+
function getViewportRect(element, strategy) {
|
|
75120
|
+
const win = getWindow(element);
|
|
75121
|
+
const html = getDocumentElement(element);
|
|
75122
|
+
const visualViewport = win.visualViewport;
|
|
75123
|
+
let width = html.clientWidth;
|
|
75124
|
+
let height = html.clientHeight;
|
|
75125
|
+
let x = 0;
|
|
75126
|
+
let y = 0;
|
|
75127
|
+
if (visualViewport) {
|
|
75128
|
+
width = visualViewport.width;
|
|
75129
|
+
height = visualViewport.height;
|
|
75130
|
+
const visualViewportBased = isWebKit();
|
|
75131
|
+
if (!visualViewportBased || visualViewportBased && strategy === 'fixed') {
|
|
75132
|
+
x = visualViewport.offsetLeft;
|
|
75133
|
+
y = visualViewport.offsetTop;
|
|
75134
|
+
}
|
|
75135
|
+
}
|
|
75136
|
+
return {
|
|
75137
|
+
width,
|
|
75138
|
+
height,
|
|
75139
|
+
x,
|
|
75140
|
+
y
|
|
75141
|
+
};
|
|
75142
|
+
}
|
|
75143
|
+
|
|
75144
|
+
// Returns the inner client rect, subtracting scrollbars if present.
|
|
75145
|
+
function getInnerBoundingClientRect(element, strategy) {
|
|
75146
|
+
const clientRect = getBoundingClientRect(element, true, strategy === 'fixed');
|
|
75147
|
+
const top = clientRect.top + element.clientTop;
|
|
75148
|
+
const left = clientRect.left + element.clientLeft;
|
|
75149
|
+
const scale = isHTMLElement(element) ? getScale(element) : createCoords(1);
|
|
75150
|
+
const width = element.clientWidth * scale.x;
|
|
75151
|
+
const height = element.clientHeight * scale.y;
|
|
75152
|
+
const x = left * scale.x;
|
|
75153
|
+
const y = top * scale.y;
|
|
75154
|
+
return {
|
|
75155
|
+
width,
|
|
75156
|
+
height,
|
|
75157
|
+
x,
|
|
75158
|
+
y
|
|
75159
|
+
};
|
|
75160
|
+
}
|
|
75161
|
+
function getClientRectFromClippingAncestor(element, clippingAncestor, strategy) {
|
|
75162
|
+
let rect;
|
|
75163
|
+
if (clippingAncestor === 'viewport') {
|
|
75164
|
+
rect = getViewportRect(element, strategy);
|
|
75165
|
+
} else if (clippingAncestor === 'document') {
|
|
75166
|
+
rect = getDocumentRect(getDocumentElement(element));
|
|
75167
|
+
} else if (isElement(clippingAncestor)) {
|
|
75168
|
+
rect = getInnerBoundingClientRect(clippingAncestor, strategy);
|
|
75169
|
+
} else {
|
|
75170
|
+
const visualOffsets = getVisualOffsets(element);
|
|
75171
|
+
rect = {
|
|
75172
|
+
x: clippingAncestor.x - visualOffsets.x,
|
|
75173
|
+
y: clippingAncestor.y - visualOffsets.y,
|
|
75174
|
+
width: clippingAncestor.width,
|
|
75175
|
+
height: clippingAncestor.height
|
|
75176
|
+
};
|
|
75177
|
+
}
|
|
75178
|
+
return rectToClientRect(rect);
|
|
75179
|
+
}
|
|
75180
|
+
function hasFixedPositionAncestor(element, stopNode) {
|
|
75181
|
+
const parentNode = getParentNode(element);
|
|
75182
|
+
if (parentNode === stopNode || !isElement(parentNode) || isLastTraversableNode(parentNode)) {
|
|
75183
|
+
return false;
|
|
75184
|
+
}
|
|
75185
|
+
return getComputedStyle$1(parentNode).position === 'fixed' || hasFixedPositionAncestor(parentNode, stopNode);
|
|
75186
|
+
}
|
|
75187
|
+
|
|
75188
|
+
// A "clipping ancestor" is an `overflow` element with the characteristic of
|
|
75189
|
+
// clipping (or hiding) child elements. This returns all clipping ancestors
|
|
75190
|
+
// of the given element up the tree.
|
|
75191
|
+
function getClippingElementAncestors(element, cache) {
|
|
75192
|
+
const cachedResult = cache.get(element);
|
|
75193
|
+
if (cachedResult) {
|
|
75194
|
+
return cachedResult;
|
|
75195
|
+
}
|
|
75196
|
+
let result = getOverflowAncestors(element, [], false).filter(el => isElement(el) && getNodeName(el) !== 'body');
|
|
75197
|
+
let currentContainingBlockComputedStyle = null;
|
|
75198
|
+
const elementIsFixed = getComputedStyle$1(element).position === 'fixed';
|
|
75199
|
+
let currentNode = elementIsFixed ? getParentNode(element) : element;
|
|
75200
|
+
|
|
75201
|
+
// https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block
|
|
75202
|
+
while (isElement(currentNode) && !isLastTraversableNode(currentNode)) {
|
|
75203
|
+
const computedStyle = getComputedStyle$1(currentNode);
|
|
75204
|
+
const currentNodeIsContaining = isContainingBlock(currentNode);
|
|
75205
|
+
if (!currentNodeIsContaining && computedStyle.position === 'fixed') {
|
|
75206
|
+
currentContainingBlockComputedStyle = null;
|
|
75207
|
+
}
|
|
75208
|
+
const shouldDropCurrentNode = elementIsFixed ? !currentNodeIsContaining && !currentContainingBlockComputedStyle : !currentNodeIsContaining && computedStyle.position === 'static' && !!currentContainingBlockComputedStyle && ['absolute', 'fixed'].includes(currentContainingBlockComputedStyle.position) || isOverflowElement(currentNode) && !currentNodeIsContaining && hasFixedPositionAncestor(element, currentNode);
|
|
75209
|
+
if (shouldDropCurrentNode) {
|
|
75210
|
+
// Drop non-containing blocks.
|
|
75211
|
+
result = result.filter(ancestor => ancestor !== currentNode);
|
|
75212
|
+
} else {
|
|
75213
|
+
// Record last containing block for next iteration.
|
|
75214
|
+
currentContainingBlockComputedStyle = computedStyle;
|
|
75215
|
+
}
|
|
75216
|
+
currentNode = getParentNode(currentNode);
|
|
75217
|
+
}
|
|
75218
|
+
cache.set(element, result);
|
|
75219
|
+
return result;
|
|
75220
|
+
}
|
|
75221
|
+
|
|
75222
|
+
// Gets the maximum area that the element is visible in due to any number of
|
|
75223
|
+
// clipping ancestors.
|
|
75224
|
+
function getClippingRect(_ref) {
|
|
75225
|
+
let {
|
|
75226
|
+
element,
|
|
75227
|
+
boundary,
|
|
75228
|
+
rootBoundary,
|
|
75229
|
+
strategy
|
|
75230
|
+
} = _ref;
|
|
75231
|
+
const elementClippingAncestors = boundary === 'clippingAncestors' ? isTopLayer(element) ? [] : getClippingElementAncestors(element, this._c) : [].concat(boundary);
|
|
75232
|
+
const clippingAncestors = [...elementClippingAncestors, rootBoundary];
|
|
75233
|
+
const firstClippingAncestor = clippingAncestors[0];
|
|
75234
|
+
const clippingRect = clippingAncestors.reduce((accRect, clippingAncestor) => {
|
|
75235
|
+
const rect = getClientRectFromClippingAncestor(element, clippingAncestor, strategy);
|
|
75236
|
+
accRect.top = max(rect.top, accRect.top);
|
|
75237
|
+
accRect.right = min(rect.right, accRect.right);
|
|
75238
|
+
accRect.bottom = min(rect.bottom, accRect.bottom);
|
|
75239
|
+
accRect.left = max(rect.left, accRect.left);
|
|
75240
|
+
return accRect;
|
|
75241
|
+
}, getClientRectFromClippingAncestor(element, firstClippingAncestor, strategy));
|
|
75242
|
+
return {
|
|
75243
|
+
width: clippingRect.right - clippingRect.left,
|
|
75244
|
+
height: clippingRect.bottom - clippingRect.top,
|
|
75245
|
+
x: clippingRect.left,
|
|
75246
|
+
y: clippingRect.top
|
|
75247
|
+
};
|
|
75248
|
+
}
|
|
75249
|
+
|
|
75250
|
+
function getDimensions(element) {
|
|
75251
|
+
const {
|
|
75252
|
+
width,
|
|
75253
|
+
height
|
|
75254
|
+
} = getCssDimensions(element);
|
|
75255
|
+
return {
|
|
75256
|
+
width,
|
|
75257
|
+
height
|
|
75258
|
+
};
|
|
75259
|
+
}
|
|
75260
|
+
|
|
75261
|
+
function getRectRelativeToOffsetParent(element, offsetParent, strategy) {
|
|
75262
|
+
const isOffsetParentAnElement = isHTMLElement(offsetParent);
|
|
75263
|
+
const documentElement = getDocumentElement(offsetParent);
|
|
75264
|
+
const isFixed = strategy === 'fixed';
|
|
75265
|
+
const rect = getBoundingClientRect(element, true, isFixed, offsetParent);
|
|
75266
|
+
let scroll = {
|
|
75267
|
+
scrollLeft: 0,
|
|
75268
|
+
scrollTop: 0
|
|
75269
|
+
};
|
|
75270
|
+
const offsets = createCoords(0);
|
|
75271
|
+
if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {
|
|
75272
|
+
if (getNodeName(offsetParent) !== 'body' || isOverflowElement(documentElement)) {
|
|
75273
|
+
scroll = getNodeScroll(offsetParent);
|
|
75274
|
+
}
|
|
75275
|
+
if (isOffsetParentAnElement) {
|
|
75276
|
+
const offsetRect = getBoundingClientRect(offsetParent, true, isFixed, offsetParent);
|
|
75277
|
+
offsets.x = offsetRect.x + offsetParent.clientLeft;
|
|
75278
|
+
offsets.y = offsetRect.y + offsetParent.clientTop;
|
|
75279
|
+
} else if (documentElement) {
|
|
75280
|
+
// If the <body> scrollbar appears on the left (e.g. RTL systems). Use
|
|
75281
|
+
// Firefox with layout.scrollbar.side = 3 in about:config to test this.
|
|
75282
|
+
offsets.x = getWindowScrollBarX(documentElement);
|
|
75283
|
+
}
|
|
75284
|
+
}
|
|
75285
|
+
const htmlOffset = documentElement && !isOffsetParentAnElement && !isFixed ? getHTMLOffset(documentElement, scroll) : createCoords(0);
|
|
75286
|
+
const x = rect.left + scroll.scrollLeft - offsets.x - htmlOffset.x;
|
|
75287
|
+
const y = rect.top + scroll.scrollTop - offsets.y - htmlOffset.y;
|
|
75288
|
+
return {
|
|
75289
|
+
x,
|
|
75290
|
+
y,
|
|
75291
|
+
width: rect.width,
|
|
75292
|
+
height: rect.height
|
|
75293
|
+
};
|
|
75294
|
+
}
|
|
75295
|
+
|
|
75296
|
+
function isStaticPositioned(element) {
|
|
75297
|
+
return getComputedStyle$1(element).position === 'static';
|
|
75298
|
+
}
|
|
75299
|
+
|
|
75300
|
+
function getTrueOffsetParent(element, polyfill) {
|
|
75301
|
+
if (!isHTMLElement(element) || getComputedStyle$1(element).position === 'fixed') {
|
|
75302
|
+
return null;
|
|
75303
|
+
}
|
|
75304
|
+
if (polyfill) {
|
|
75305
|
+
return polyfill(element);
|
|
75306
|
+
}
|
|
75307
|
+
let rawOffsetParent = element.offsetParent;
|
|
75308
|
+
|
|
75309
|
+
// Firefox returns the <html> element as the offsetParent if it's non-static,
|
|
75310
|
+
// while Chrome and Safari return the <body> element. The <body> element must
|
|
75311
|
+
// be used to perform the correct calculations even if the <html> element is
|
|
75312
|
+
// non-static.
|
|
75313
|
+
if (getDocumentElement(element) === rawOffsetParent) {
|
|
75314
|
+
rawOffsetParent = rawOffsetParent.ownerDocument.body;
|
|
75315
|
+
}
|
|
75316
|
+
return rawOffsetParent;
|
|
75317
|
+
}
|
|
75318
|
+
|
|
75319
|
+
// Gets the closest ancestor positioned element. Handles some edge cases,
|
|
75320
|
+
// such as table ancestors and cross browser bugs.
|
|
75321
|
+
function getOffsetParent(element, polyfill) {
|
|
75322
|
+
const win = getWindow(element);
|
|
75323
|
+
if (isTopLayer(element)) {
|
|
75324
|
+
return win;
|
|
75325
|
+
}
|
|
75326
|
+
if (!isHTMLElement(element)) {
|
|
75327
|
+
let svgOffsetParent = getParentNode(element);
|
|
75328
|
+
while (svgOffsetParent && !isLastTraversableNode(svgOffsetParent)) {
|
|
75329
|
+
if (isElement(svgOffsetParent) && !isStaticPositioned(svgOffsetParent)) {
|
|
75330
|
+
return svgOffsetParent;
|
|
75331
|
+
}
|
|
75332
|
+
svgOffsetParent = getParentNode(svgOffsetParent);
|
|
75333
|
+
}
|
|
75334
|
+
return win;
|
|
75335
|
+
}
|
|
75336
|
+
let offsetParent = getTrueOffsetParent(element, polyfill);
|
|
75337
|
+
while (offsetParent && isTableElement(offsetParent) && isStaticPositioned(offsetParent)) {
|
|
75338
|
+
offsetParent = getTrueOffsetParent(offsetParent, polyfill);
|
|
75339
|
+
}
|
|
75340
|
+
if (offsetParent && isLastTraversableNode(offsetParent) && isStaticPositioned(offsetParent) && !isContainingBlock(offsetParent)) {
|
|
75341
|
+
return win;
|
|
75342
|
+
}
|
|
75343
|
+
return offsetParent || getContainingBlock(element) || win;
|
|
75344
|
+
}
|
|
75345
|
+
|
|
75346
|
+
const getElementRects = async function (data) {
|
|
75347
|
+
const getOffsetParentFn = this.getOffsetParent || getOffsetParent;
|
|
75348
|
+
const getDimensionsFn = this.getDimensions;
|
|
75349
|
+
const floatingDimensions = await getDimensionsFn(data.floating);
|
|
75350
|
+
return {
|
|
75351
|
+
reference: getRectRelativeToOffsetParent(data.reference, await getOffsetParentFn(data.floating), data.strategy),
|
|
75352
|
+
floating: {
|
|
75353
|
+
x: 0,
|
|
75354
|
+
y: 0,
|
|
75355
|
+
width: floatingDimensions.width,
|
|
75356
|
+
height: floatingDimensions.height
|
|
75357
|
+
}
|
|
75358
|
+
};
|
|
75359
|
+
};
|
|
75360
|
+
|
|
75361
|
+
function isRTL(element) {
|
|
75362
|
+
return getComputedStyle$1(element).direction === 'rtl';
|
|
75363
|
+
}
|
|
75364
|
+
|
|
75365
|
+
const platform = {
|
|
75366
|
+
convertOffsetParentRelativeRectToViewportRelativeRect,
|
|
75367
|
+
getDocumentElement,
|
|
75368
|
+
getClippingRect,
|
|
75369
|
+
getOffsetParent,
|
|
75370
|
+
getElementRects,
|
|
75371
|
+
getClientRects,
|
|
75372
|
+
getDimensions,
|
|
75373
|
+
getScale,
|
|
75374
|
+
isElement,
|
|
75375
|
+
isRTL
|
|
75376
|
+
};
|
|
75377
|
+
|
|
75378
|
+
/**
|
|
75379
|
+
* Optimizes the visibility of the floating element by shifting it in order to
|
|
75380
|
+
* keep it in view when it will overflow the clipping boundary.
|
|
75381
|
+
* @see https://floating-ui.com/docs/shift
|
|
75382
|
+
*/
|
|
75383
|
+
const shift = shift$1;
|
|
75384
|
+
|
|
75385
|
+
/**
|
|
75386
|
+
* Optimizes the visibility of the floating element by flipping the `placement`
|
|
75387
|
+
* in order to keep it in view when the preferred placement(s) will overflow the
|
|
75388
|
+
* clipping boundary. Alternative to `autoPlacement`.
|
|
75389
|
+
* @see https://floating-ui.com/docs/flip
|
|
75390
|
+
*/
|
|
75391
|
+
const flip = flip$1;
|
|
75392
|
+
|
|
75393
|
+
/**
|
|
75394
|
+
* Computes the `x` and `y` coordinates that will place the floating element
|
|
75395
|
+
* next to a given reference element.
|
|
75396
|
+
*/
|
|
75397
|
+
const computePosition = (reference, floating, options) => {
|
|
75398
|
+
// This caches the expensive `getClippingElementAncestors` function so that
|
|
75399
|
+
// multiple lifecycle resets re-use the same result. It only lives for a
|
|
75400
|
+
// single call. If other functions become expensive, we can add them as well.
|
|
75401
|
+
const cache = new Map();
|
|
75402
|
+
const mergedOptions = {
|
|
75403
|
+
platform,
|
|
75404
|
+
...options
|
|
75405
|
+
};
|
|
75406
|
+
const platformWithCache = {
|
|
75407
|
+
...mergedOptions.platform,
|
|
75408
|
+
_c: cache
|
|
75409
|
+
};
|
|
75410
|
+
return computePosition$1(reference, floating, {
|
|
75411
|
+
...mergedOptions,
|
|
75412
|
+
platform: platformWithCache
|
|
75413
|
+
});
|
|
75414
|
+
};
|
|
75415
|
+
|
|
75416
|
+
const ezPopoverPlusCss = ":host{--ez-popover__box--border-radius:var(--border--radius-medium, 12px);--ez-popover__box--box-shadow:var(--shadow, 0px 0px 16px 0px #000);--ez-popover__box--background-color:var(--background--xlight, #fff);--ez-popover__box--z-index:var(--most-visible, 4);position:relative;display:flex;user-select:none}.popover__overlay{display:none;position:fixed;padding:0;top:0px;left:0px;width:100%;height:100vh;box-sizing:border-box;z-index:var(--more-visible--2x, 3)}.popover__overlay--light{background-color:rgba(var(--rgb-background--overlay), var(--opacity--bright))}.popover__overlay--medium{background-color:rgba(var(--rgb-background--overlay), var(--opacity--soft));backdrop-filter:blur(var(--background-blur--medium))}.popover__box{display:none;position:fixed;top:0;left:0;z-index:var(--ez-popover__box--z-index);flex-direction:column;height:fit-content;background-color:var(--ez-popover__box--background-color);border-radius:var(--ez-popover__box--border-radius);box-shadow:var(--ez-popover__box--box-shadow)}.popover__box--fit-content{width:fit-content}.popover__box--full-width{width:calc(100% - 10px)}";
|
|
75417
|
+
|
|
75418
|
+
const EzPopoverPlus$1 = class extends HTMLElement$1 {
|
|
75419
|
+
constructor() {
|
|
75420
|
+
super();
|
|
75421
|
+
this.__registerHost();
|
|
75422
|
+
this.__attachShadow();
|
|
75423
|
+
this.ezVisibilityChange = createEvent(this, "ezVisibilityChange", 7);
|
|
75424
|
+
this.TIME_DEBOUNCE = 500;
|
|
75425
|
+
this.autoClose = true;
|
|
75426
|
+
this.boxWidth = "fit-content";
|
|
75427
|
+
this.opened = false;
|
|
75428
|
+
this.overlayType = "light";
|
|
75429
|
+
this.anchorElement = undefined;
|
|
75430
|
+
this.options = { horizontalGap: 0, verticalGap: 0, fromRight: false };
|
|
75431
|
+
}
|
|
75432
|
+
async observeOpened(newValue, oldValue) {
|
|
75433
|
+
if (newValue !== oldValue) {
|
|
75434
|
+
if (newValue) {
|
|
75435
|
+
this.openPopover();
|
|
75436
|
+
}
|
|
75437
|
+
else {
|
|
75438
|
+
this.hidePopover();
|
|
75439
|
+
}
|
|
75440
|
+
this.ezVisibilityChange.emit(newValue);
|
|
75441
|
+
return;
|
|
75442
|
+
}
|
|
75443
|
+
}
|
|
75444
|
+
/**
|
|
75445
|
+
* Atualiza a posição do popover.
|
|
75446
|
+
*/
|
|
75447
|
+
async updatePosition(top, left) {
|
|
75448
|
+
this.updateOptionPosition(top, left);
|
|
75449
|
+
await this.updatePositionPopover();
|
|
75450
|
+
}
|
|
75451
|
+
/**
|
|
75452
|
+
* Exibe o ez-popover.
|
|
75453
|
+
*/
|
|
75454
|
+
async show(top, left) {
|
|
75455
|
+
this.updateOptionPosition(top, left);
|
|
75456
|
+
this.opened = true;
|
|
75457
|
+
}
|
|
75458
|
+
/**
|
|
75459
|
+
* Ancora a exibição do popOver a um elemento HTML.
|
|
75460
|
+
*/
|
|
75461
|
+
async showUnder(element, options) {
|
|
75462
|
+
if (options) {
|
|
75463
|
+
this.options = options;
|
|
75464
|
+
}
|
|
75465
|
+
this.anchorElement = element;
|
|
75466
|
+
this.opened = true;
|
|
75467
|
+
}
|
|
75468
|
+
/**
|
|
75469
|
+
* Oculta o ez-popover.
|
|
75470
|
+
*/
|
|
75471
|
+
async hide() {
|
|
75472
|
+
this.opened = false;
|
|
75473
|
+
}
|
|
75474
|
+
/**
|
|
75475
|
+
* Altera as opções.
|
|
75476
|
+
*/
|
|
75477
|
+
async setOptions(options) {
|
|
75478
|
+
Object.assign(this.options, options);
|
|
75479
|
+
}
|
|
75480
|
+
/**
|
|
75481
|
+
* Altera o elemento de ancoragem.
|
|
75482
|
+
*/
|
|
75483
|
+
async setAnchorElement(anchor) {
|
|
75484
|
+
this.anchorElement = anchor;
|
|
75485
|
+
}
|
|
75486
|
+
parseSizePixel(sizePixel, defaultValue) {
|
|
75487
|
+
if (!sizePixel) {
|
|
75488
|
+
return defaultValue !== null && defaultValue !== void 0 ? defaultValue : 0;
|
|
75489
|
+
}
|
|
75490
|
+
if (typeof sizePixel === "string") {
|
|
75491
|
+
return Number(sizePixel.replace("px", ""));
|
|
75492
|
+
}
|
|
75493
|
+
return sizePixel !== null && sizePixel !== void 0 ? sizePixel : 0;
|
|
75494
|
+
}
|
|
75495
|
+
updateOptionPosition(top, left) {
|
|
75496
|
+
Object.assign(this.options, {
|
|
75497
|
+
horizontalGap: this.parseSizePixel(left, this.options.horizontalGap),
|
|
75498
|
+
verticalGap: this.parseSizePixel(top, this.options.verticalGap),
|
|
75499
|
+
});
|
|
75500
|
+
}
|
|
75501
|
+
async updatePositionPopover() {
|
|
75502
|
+
if (!this._box || !this.opened) {
|
|
75503
|
+
return;
|
|
75504
|
+
}
|
|
75505
|
+
if (!this.anchorElement) {
|
|
75506
|
+
this.anchorElement = this._host;
|
|
75507
|
+
}
|
|
75508
|
+
if (typeof this.anchorElement === 'string') {
|
|
75509
|
+
this.anchorElement = document.getElementById(this.anchorElement);
|
|
75510
|
+
}
|
|
75511
|
+
await computePosition(this.anchorElement, this._box, {
|
|
75512
|
+
placement: this.options.fromRight ? 'bottom-end' : 'bottom-start',
|
|
75513
|
+
middleware: [flip(), shift({ padding: 5 })],
|
|
75514
|
+
strategy: 'fixed',
|
|
75515
|
+
}).then(({ x, y, placement }) => {
|
|
75516
|
+
const newTop = placement.includes("bottom") ? y + this.options.verticalGap : y - this.options.verticalGap;
|
|
75517
|
+
const newLeft = placement.includes("start") ? x + this.options.horizontalGap : x - this.options.horizontalGap;
|
|
75518
|
+
Object.assign(this._box.style, {
|
|
75519
|
+
top: `${newTop}px`,
|
|
75520
|
+
left: `${newLeft}px`,
|
|
75521
|
+
});
|
|
75522
|
+
});
|
|
75523
|
+
}
|
|
75524
|
+
hidePopover() {
|
|
75525
|
+
if (!this._box) {
|
|
75526
|
+
return;
|
|
75527
|
+
}
|
|
75528
|
+
this._box.style.display = '';
|
|
75529
|
+
this.hideOverlay();
|
|
75530
|
+
this.ezVisibilityChange.emit(false);
|
|
75531
|
+
}
|
|
75532
|
+
async openPopover() {
|
|
75533
|
+
if (!this._box) {
|
|
75534
|
+
return;
|
|
75535
|
+
}
|
|
75536
|
+
this._box.style.display = 'flex';
|
|
75537
|
+
this._box.style.visibility = 'hidden';
|
|
75538
|
+
await this.updatePositionPopover();
|
|
75539
|
+
this.openOverlay();
|
|
75540
|
+
this.ezVisibilityChange.emit(true);
|
|
75541
|
+
this._box.style.visibility = 'visible';
|
|
75542
|
+
}
|
|
75543
|
+
openOverlay() {
|
|
75544
|
+
if (!this._overlay || !this._overlayIsActive) {
|
|
75545
|
+
return;
|
|
75546
|
+
}
|
|
75547
|
+
this._overlay.style.display = 'block';
|
|
75548
|
+
}
|
|
75549
|
+
hideOverlay() {
|
|
75550
|
+
if (!this._overlay) {
|
|
75551
|
+
return;
|
|
75552
|
+
}
|
|
75553
|
+
this._overlay.style.display = 'none';
|
|
75554
|
+
}
|
|
75555
|
+
checkStatusOverlay() {
|
|
75556
|
+
if (this.overlayType !== "none") {
|
|
75557
|
+
return true;
|
|
75558
|
+
}
|
|
75559
|
+
if (this.overlayType === "none" && this.autoClose) {
|
|
75560
|
+
return true;
|
|
75561
|
+
}
|
|
75562
|
+
return false;
|
|
75563
|
+
}
|
|
75564
|
+
updatePositionDebounce() {
|
|
75565
|
+
if (!this.opened) {
|
|
75566
|
+
return;
|
|
75567
|
+
}
|
|
75568
|
+
clearTimeout(this._timeoutDebounce);
|
|
75569
|
+
this._timeoutDebounce = setTimeout(() => {
|
|
75570
|
+
this.updatePositionPopover();
|
|
75571
|
+
}, this.TIME_DEBOUNCE);
|
|
75572
|
+
}
|
|
75573
|
+
componentWillLoad() {
|
|
75574
|
+
window.addEventListener('scroll', this.updatePositionDebounce.bind(this), true);
|
|
75575
|
+
window.addEventListener('resize', this.updatePositionDebounce.bind(this), true);
|
|
75576
|
+
}
|
|
75577
|
+
componentDidLoad() {
|
|
75578
|
+
this._overlayIsActive = this.checkStatusOverlay();
|
|
75579
|
+
this._resizeObserver = new ResizeObserver(this.updatePositionPopover.bind(this));
|
|
75580
|
+
this._resizeObserver.observe(this._box);
|
|
75581
|
+
}
|
|
75582
|
+
disconnectedCallback() {
|
|
75583
|
+
window.removeEventListener('scroll', this.updatePositionDebounce.bind(this), true);
|
|
75584
|
+
window.removeEventListener('resize', this.updatePositionDebounce.bind(this), true);
|
|
75585
|
+
this._resizeObserver.disconnect();
|
|
75586
|
+
}
|
|
75587
|
+
render() {
|
|
75588
|
+
return (h(Host, null, h("div", { ref: el => this._overlay = el, onClick: () => this.hide(), class: `popover__overlay popover__overlay--${this.overlayType}` }), h("section", { ref: el => this._box = el, class: {
|
|
75589
|
+
"popover__box": true,
|
|
75590
|
+
"popover__box--fit-content": this.boxWidth === "fit-content",
|
|
75591
|
+
"popover__box--full-width": this.boxWidth !== "fit-content",
|
|
75592
|
+
} }, h("slot", null))));
|
|
75593
|
+
}
|
|
75594
|
+
get _host() { return this; }
|
|
75595
|
+
static get watchers() { return {
|
|
75596
|
+
"opened": ["observeOpened"]
|
|
75597
|
+
}; }
|
|
75598
|
+
static get style() { return ezPopoverPlusCss; }
|
|
75599
|
+
};
|
|
75600
|
+
|
|
74189
75601
|
const ezPopupCss = ":host{display:flex;width:auto;--ez-popup-z-index:var(--elevation--24, 24);--ez-popup__container--color:var(--title--primary, #2b3a54);--ez-popup__container--padding:var(--space--md, 20px);--ez-popup__header--padding-bottom:var(--space--medium, 12px);--ez-popup__title--font-family:var(--font-pattern, \"Roboto\");--ez-popup__title--font-size:var(--title--large, 20px);--ez-popup__title--color:var(--title--primary, #2b3a54);--ez-popup__title--font-weight:var(--text-weight--large, 600);--ez-popup__btn__close--icon-color:var(--title--primary, #2b3a54);--ez-popup__btn__close--icon:url('data:image/svg+xml;utf8,<svg width=\"14\" height=\"14\" viewBox=\"0 0 14 14\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M 8.2421753,6.9944578 13.743748,1.4930784 C 13.907781,1.3290628 14,1.1065946 14,0.87462511 14,0.64266712 13.907782,0.42019873 13.743748,0.25617155 13.579712,0.09215597 13.35727,6.48e-8 13.125266,6.48e-8 12.89338,6.48e-8 12.670821,0.09215634 12.506787,0.25617155 L 7.005215,5.7575508 1.5035972,0.25617155 C 1.3395631,0.09215597 1.1170968,6.48e-8 0.88511716,6.48e-8 0.65314917,6.48e-8 0.4306712,0.09215597 0.26663695,0.25617155 0.10260271,0.42019873 0.01045441,0.64266712 0.01045441,0.87462511 c 0,0.23196949 0.0921483,0.45443769 0.25618254,0.61845329 L 5.7682546,6.9944578 0.26663695,12.497027 c -0.0834745,0.08067 -0.15003245,0.1772 -0.19581514,0.283871 C 0.02505077,12.887561 9.831648e-4,13.002399 2.950369e-5,13.118395 -9.2415746e-4,13.234504 0.02125019,13.349689 0.06527245,13.457057 c 0.04401053,0.107479 0.10898307,0.205064 0.1911168,0.287137 0.0821454,0.08208 0.17979645,0.146888 0.28727561,0.190839 0.10747906,0.04395 0.22262954,0.06598 0.33872417,0.06493 0.116095,-10e-4 0.23082547,-0.0253 0.33747687,-0.07112 0.1066637,-0.04593 0.2031133,-0.112615 0.2837313,-0.196086 L 7.005215,8.2313646 12.506787,13.732768 c 0.164034,0.164027 0.386593,0.256125 0.618479,0.256125 0.232004,0 0.454446,-0.09209 0.618482,-0.256125 C 13.907781,13.568741 14,13.346308 14,13.114315 14,12.882323 13.90779,12.659888 13.743748,12.495861 Z\"/></svg>')}.overlay{position:fixed;display:flex;top:0px;z-index:var(--ez-popup-z-index, 24);left:0px;width:100%;align-items:center;justify-content:center;box-sizing:border-box;height:100vh;backdrop-filter:blur(4px);background:rgba(0, 4, 12, 0.4)}.popup{display:flex;height:100%;align-items:center;justify-content:center;box-sizing:border-box}.popup__container{width:100%;max-height:90%;height:100%;display:flex;flex-wrap:wrap;overflow:hidden;outline:none;background:#FFFF;color:var(--ez-popup__container--color);border-radius:12px;box-shadow:0px 0px 16px rgba(0, 38, 111, 0.122);box-sizing:border-box;padding:var(--ez-popup__container--padding)}.popup__container--auto{height:auto}.popup__overflow-y--auto{overflow-y:auto}.popup__content{box-sizing:border-box;height:100%;width:100%}.popup__expandable-content{box-sizing:border-box;width:100%;height:calc(100% - 44px)}.popup__header{width:100%;display:flex}.popup__header--padding{padding-bottom:var(--ez-popup__header--padding-bottom)}.popup__title{display:flex;margin:0;width:100%;font-family:var(--ez-popup__title--font-family);font-size:var(--ez-popup__title--font-size);font-weight:var(--ez-popup__title--font-weight);color:var(--ez-popup__title--color);line-height:1.3}.btn-close{justify-content:flex-end;align-self:flex-start;align-items:flex-start;display:flex;outline:none;border:none;background-color:unset;cursor:pointer}.btn-close::after{content:'';display:flex;background-color:var(--ez-popup__btn__close--icon-color);width:14px;height:14px;-webkit-mask-image:var(--ez-popup__btn__close--icon);mask-image:var(--ez-popup__btn__close--icon)}.btn-close--solo{width:100%}.row{width:100%;display:flex;flex-wrap:wrap}.col{display:flex;flex-wrap:wrap;align-self:flex-start;box-sizing:border-box}.col--stretch{align-self:stretch}.col--undefined{width:unset}.col--nowrap{flex-wrap:nowrap}.ez-popup__size-limit--x-small{min-width:350px;max-width:560px}@media screen and (min-width: 320px){.col--sd-1{width:8.33333%}.col--sd-2{width:16.66667%}.col--sd-3{width:25%}.col--sd-4{width:33.33333%}.col--sd-5{width:41.66667%}.col--sd-6{width:50%}.col--sd-7{width:58.33333%}.col--sd-8{width:66.66667%}.col--sd-9{width:75%}.col--sd-10{width:83.33333%}.col--sd-11{width:91.66667%}.col--sd-12{width:100%}}@media screen and (min-width: 480px){.col--pn-1{width:8.33333%}.col--pn-2{width:16.66667%}.col--pn-3{width:25%}.col--pn-4{width:33.33333%}.col--pn-5{width:41.66667%}.col--pn-6{width:50%}.col--pn-7{width:58.33333%}.col--pn-8{width:66.66667%}.col--pn-9{width:75%}.col--pn-10{width:83.33333%}.col--pn-11{width:91.66667%}.col--pn-12{width:100%}}@media screen and (min-width: 768px){.col--tb-1{width:8.33333%}.col--tb-2{width:16.66667%}.col--tb-3{width:25%}.col--tb-4{width:33.33333%}.col--tb-5{width:41.66667%}.col--tb-6{width:50%}.col--tb-7{width:58.33333%}.col--tb-8{width:66.66667%}.col--tb-9{width:75%}.col--tb-10{width:83.33333%}.col--tb-11{width:91.66667%}.col--tb-12{width:100%}}@media screen and (min-width: 992px){.col--md-1{width:8.33333%}.col--md-2{width:16.66667%}.col--md-3{width:25%}.col--md-4{width:33.33333%}.col--md-5{width:41.66667%}.col--md-6{width:50%}.col--md-7{width:58.33333%}.col--md-8{width:66.66667%}.col--md-9{width:75%}.col--md-10{width:83.33333%}.col--md-11{width:91.66667%}.col--md-12{width:100%}}@media screen and (min-width: 1200px){.col--ld-1{width:8.33333%}.col--ld-2{width:16.66667%}.col--ld-3{width:25%}.col--ld-4{width:33.33333%}.col--ld-5{width:41.66667%}.col--ld-6{width:50%}.col--ld-7{width:58.33333%}.col--ld-8{width:66.66667%}.col--ld-9{width:75%}.col--ld-10{width:83.33333%}.col--ld-11{width:91.66667%}.col--ld-12{width:100%}}";
|
|
74190
75602
|
|
|
74191
75603
|
const EzPopup$1 = class extends HTMLElement$1 {
|
|
@@ -78828,13 +80240,6 @@ const FilterColumn$1 = class extends HTMLElement$1 {
|
|
|
78828
80240
|
super();
|
|
78829
80241
|
this.__registerHost();
|
|
78830
80242
|
this.applyFilterColumnOptions = createEvent(this, "applyFilterColumnOptions", 7);
|
|
78831
|
-
this.TOP_POSITION = '65';
|
|
78832
|
-
this.TOP_POSITION_HEADER_HIDDEN = '18';
|
|
78833
|
-
this.TOP_POSITION_NO_TASKBAR = '32';
|
|
78834
|
-
this.TOP_POSITION_NO_TASKBAR_HEADER_HIDDEN = '20';
|
|
78835
|
-
this.DEFAULT_HEIGHT = 430;
|
|
78836
|
-
this.FIX_MARGIN = 60;
|
|
78837
|
-
this.FILTER_COLUMN_WIDTH = 330;
|
|
78838
80243
|
this.opened = true;
|
|
78839
80244
|
this.columnName = undefined;
|
|
78840
80245
|
this.columnLabel = undefined;
|
|
@@ -78864,50 +80269,14 @@ const FilterColumn$1 = class extends HTMLElement$1 {
|
|
|
78864
80269
|
this.columnName = configs.columnName;
|
|
78865
80270
|
this.columnLabel = configs.columnLabel;
|
|
78866
80271
|
await this.setOptions(configs.filteredOptions);
|
|
78867
|
-
await this.ezPopoverElement.
|
|
78868
|
-
}
|
|
78869
|
-
}
|
|
78870
|
-
calculateLeftPosition({ leftPosition, fromIcon }) {
|
|
78871
|
-
const leftPositionCalculated = this.calcFilterColumnLeftPosition(leftPosition);
|
|
78872
|
-
if (!fromIcon) {
|
|
78873
|
-
return `${leftPositionCalculated}px`;
|
|
80272
|
+
await this.ezPopoverElement.showUnder(`filter-column-${configs.columnName}-${this.dataUnit.dataUnitId}`);
|
|
78874
80273
|
}
|
|
78875
|
-
const difference = this.ezPopoverElement.getBoundingClientRect().left;
|
|
78876
|
-
const leftResolved = (leftPositionCalculated + 16) - difference;
|
|
78877
|
-
return `${(leftResolved > 0 ? leftResolved : 0)}px`;
|
|
78878
|
-
}
|
|
78879
|
-
calcFilterColumnLeftPosition(leftReference) {
|
|
78880
|
-
var _a, _b;
|
|
78881
|
-
const gridReference = this.ezPopoverElement.closest("ez-grid");
|
|
78882
|
-
const gridLimit = (_a = gridReference.getBoundingClientRect()) === null || _a === void 0 ? void 0 : _a.right;
|
|
78883
|
-
const popoverDiff = (_b = this.ezPopoverElement.getBoundingClientRect()) === null || _b === void 0 ? void 0 : _b.left;
|
|
78884
|
-
const maxLeft = gridLimit - (this.FILTER_COLUMN_WIDTH + popoverDiff);
|
|
78885
|
-
const leftInt = leftReference - (this.FIX_MARGIN + popoverDiff);
|
|
78886
|
-
return leftInt > maxLeft ? maxLeft : leftInt;
|
|
78887
80274
|
}
|
|
78888
80275
|
buildIsTextSearch() {
|
|
78889
80276
|
var _a, _b;
|
|
78890
80277
|
const userInterface = (_b = (_a = this.fieldDescriptor) === null || _a === void 0 ? void 0 : _a.userInterface) !== null && _b !== void 0 ? _b : UserInterface.SHORTTEXT;
|
|
78891
80278
|
this.isTextSearch = !(userInterface === UserInterface.DECIMALNUMBER || userInterface === UserInterface.INTEGERNUMBER);
|
|
78892
80279
|
}
|
|
78893
|
-
calcTopPosition() {
|
|
78894
|
-
const referencePosition = this.buildReferenceTopPosition();
|
|
78895
|
-
const totalPopoverHeight = parseInt(referencePosition) + this.DEFAULT_HEIGHT;
|
|
78896
|
-
const popoverPosition = Math.round(this.ezPopoverElement.getBoundingClientRect().top);
|
|
78897
|
-
const popoverBottomPosition = popoverPosition + totalPopoverHeight;
|
|
78898
|
-
const windowHeight = window.innerHeight;
|
|
78899
|
-
if (windowHeight > popoverBottomPosition) {
|
|
78900
|
-
return `${referencePosition}px`;
|
|
78901
|
-
}
|
|
78902
|
-
const differenceBetween = windowHeight - popoverBottomPosition;
|
|
78903
|
-
return `${differenceBetween}px`;
|
|
78904
|
-
}
|
|
78905
|
-
buildReferenceTopPosition() {
|
|
78906
|
-
if (this.noHeaderTaskBar) {
|
|
78907
|
-
return this.gridHeaderHidden ? this.TOP_POSITION_NO_TASKBAR_HEADER_HIDDEN : this.TOP_POSITION_NO_TASKBAR;
|
|
78908
|
-
}
|
|
78909
|
-
return this.gridHeaderHidden ? this.TOP_POSITION_HEADER_HIDDEN : this.TOP_POSITION;
|
|
78910
|
-
}
|
|
78911
80280
|
async clearConfigs() {
|
|
78912
80281
|
var _a;
|
|
78913
80282
|
await ((_a = this.ezMultiSelectionList) === null || _a === void 0 ? void 0 : _a.clearFilteredOptions());
|
|
@@ -78983,7 +80352,7 @@ const FilterColumn$1 = class extends HTMLElement$1 {
|
|
|
78983
80352
|
}
|
|
78984
80353
|
}
|
|
78985
80354
|
render() {
|
|
78986
|
-
return (h("ez-popover", { class: 'filter-column__popover', "overlay-type": 'none',
|
|
80355
|
+
return (h("ez-popover-plus", { ref: (element) => (this.ezPopoverElement = element), class: 'filter-column__popover', "overlay-type": 'none', autoClose: true, onEzVisibilityChange: this.handleEzVisibilityChange.bind(this) }, h("section", { class: 'filter-column' }, h("header", { class: 'filter-column__header' }, h("span", { class: 'ez-text ez-text--medium filter-column__header-title' }, "Filtro da coluna ", this.columnLabel), h("ez-button", { mode: 'icon', "icon-name": 'close', class: 'ez-button--tertiary', onClick: () => this.hide() })), h("ez-multi-selection-list", { id: 'filter-column-selection-list', columnName: this.columnName, dataSource: this.dataSource, options: this.options, useOptions: this.useOptions, ref: (element) => (this.ezMultiSelectionList = element), onChangeFilteredOptions: (event) => this.changeSelectedItems(event.detail), isTextSearch: this.isTextSearch }), h("footer", { class: 'filter-column__footer' }, h("ez-button", { label: 'Aplicar', class: 'ez-button--primary', onClick: this.submit.bind(this) })))));
|
|
78987
80356
|
}
|
|
78988
80357
|
static get style() { return filterColumnCss; }
|
|
78989
80358
|
};
|
|
@@ -79036,6 +80405,7 @@ const EzModalContainer = /*@__PURE__*/proxyCustomElement(EzModalContainer$1, [6,
|
|
|
79036
80405
|
const EzMultiSelectionList = /*@__PURE__*/proxyCustomElement(EzMuiltiSelectionList, [2,"ez-multi-selection-list",{"columnName":[1,"column-name"],"dataSource":[16],"useOptions":[1028,"use-options"],"options":[1040],"isTextSearch":[4,"is-text-search"],"filteredOptions":[32],"displayOptions":[32],"viewScenario":[32],"displayOptionToCheckAllItems":[32]}]);
|
|
79037
80406
|
const EzNumberInput = /*@__PURE__*/proxyCustomElement(EzNumberInput$1, [1,"ez-number-input",{"label":[1],"value":[1538],"enabled":[4],"canShowError":[516,"can-show-error"],"errorMessage":[1537,"error-message"],"allowNegative":[4,"allow-negative"],"precision":[2],"prettyPrecision":[2,"pretty-precision"],"mode":[513],"autoFocus":[4,"auto-focus"],"_value":[32]}]);
|
|
79038
80407
|
const EzPopover = /*@__PURE__*/proxyCustomElement(EzPopover$1, [1,"ez-popover",{"autoClose":[516,"auto-close"],"boxWidth":[513,"box-width"],"opened":[1540],"innerElement":[1537,"inner-element"],"overlayType":[513,"overlay-type"]}]);
|
|
80408
|
+
const EzPopoverPlus = /*@__PURE__*/proxyCustomElement(EzPopoverPlus$1, [1,"ez-popover-plus",{"autoClose":[516,"auto-close"],"boxWidth":[513,"box-width"],"opened":[1540],"overlayType":[513,"overlay-type"],"anchorElement":[1537,"anchor-element"],"options":[1040]}]);
|
|
79039
80409
|
const EzPopup = /*@__PURE__*/proxyCustomElement(EzPopup$1, [1,"ez-popup",{"size":[1],"opened":[1540],"useHeader":[516,"use-header"],"heightMode":[513,"height-mode"],"ezTitle":[1,"ez-title"],"enabledScroll":[4,"enabled-scroll"]}]);
|
|
79040
80410
|
const EzRadioButton = /*@__PURE__*/proxyCustomElement(EzRadioButton$1, [1,"ez-radio-button",{"value":[1544],"options":[1040],"enabled":[516],"label":[513],"direction":[1537]}]);
|
|
79041
80411
|
const EzScroller = /*@__PURE__*/proxyCustomElement(EzScroller$1, [1,"ez-scroller",{"direction":[1],"locked":[4],"activeShadow":[4,"active-shadow"],"isActive":[32]},[[2,"click","clickListener"],[1,"mousedown","mouseDownHandler"],[1,"mouseup","mouseUpHandler"],[1,"mousemove","mouseMoveHandler"]]]);
|
|
@@ -79095,6 +80465,7 @@ const defineCustomElements = (opts) => {
|
|
|
79095
80465
|
EzMultiSelectionList,
|
|
79096
80466
|
EzNumberInput,
|
|
79097
80467
|
EzPopover,
|
|
80468
|
+
EzPopoverPlus,
|
|
79098
80469
|
EzPopup,
|
|
79099
80470
|
EzRadioButton,
|
|
79100
80471
|
EzScroller,
|
|
@@ -79125,4 +80496,4 @@ const defineCustomElements = (opts) => {
|
|
|
79125
80496
|
}
|
|
79126
80497
|
};
|
|
79127
80498
|
|
|
79128
|
-
export { EzActionsButton, EzAlert, EzAlertList, EzApplication, EzBadge, EzBreadcrumb, EzButton, EzCalendar, EzCardItem, EzChart, EzCheck, EzChip, EzCollapsibleBox, EzComboBox, EzCustomFormInput, EzDateInput, EzDateTimeInput, EzDialog, EzDoubleList, EzDropdown, EzFileItem, EzFilterInput, EzForm, EzFormView, EzGrid, EzGuideNavigator, EzIcon, EzList, EzLoadingBar, EzModal, EzModalContainer, EzMultiSelectionList, EzNumberInput, EzPopover, EzPopup, EzRadioButton, EzScroller, EzSearch, EzSidebarButton, EzSidebarNavigator, EzSkeleton, EzSplitButton, EzSplitItem, EzSplitPanel, EzTabselector, EzTextArea, EzTextEdit, EzTextInput, EzTimeInput, EzToast, EzTooltip, EzTree, EzUpload, EzViewStack, FilterColumn, MultiSelectionBoxMessage, defineCustomElements };
|
|
80499
|
+
export { EzActionsButton, EzAlert, EzAlertList, EzApplication, EzBadge, EzBreadcrumb, EzButton, EzCalendar, EzCardItem, EzChart, EzCheck, EzChip, EzCollapsibleBox, EzComboBox, EzCustomFormInput, EzDateInput, EzDateTimeInput, EzDialog, EzDoubleList, EzDropdown, EzFileItem, EzFilterInput, EzForm, EzFormView, EzGrid, EzGuideNavigator, EzIcon, EzList, EzLoadingBar, EzModal, EzModalContainer, EzMultiSelectionList, EzNumberInput, EzPopover, EzPopoverPlus, EzPopup, EzRadioButton, EzScroller, EzSearch, EzSidebarButton, EzSidebarNavigator, EzSkeleton, EzSplitButton, EzSplitItem, EzSplitPanel, EzTabselector, EzTextArea, EzTextEdit, EzTextInput, EzTimeInput, EzToast, EzTooltip, EzTree, EzUpload, EzViewStack, FilterColumn, MultiSelectionBoxMessage, defineCustomElements };
|