@govbr-ds/webcomponents 2.0.0-next.62 → 2.0.0-next.64
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/br-checkbox.br-input.br-radio.entry.cjs.js.map +1 -1
- package/dist/cjs/br-checkbox_3.cjs.entry.js +17 -28
- package/dist/cjs/br-collapse.br-list.entry.cjs.js.map +1 -1
- package/dist/cjs/br-collapse_2.cjs.entry.js +10 -15
- package/dist/cjs/br-datetime-picker.cjs.entry.js +18 -31
- package/dist/cjs/br-datetime-picker.entry.cjs.js.map +1 -1
- package/dist/cjs/br-dropdown.br-select.entry.cjs.js.map +1 -1
- package/dist/cjs/br-dropdown_2.cjs.entry.js +73 -56
- package/dist/cjs/br-header-list.cjs.entry.js +6 -13
- package/dist/cjs/br-header-list.entry.cjs.js.map +1 -1
- package/dist/cjs/br-header.cjs.entry.js +2 -5
- package/dist/cjs/br-header.entry.cjs.js.map +1 -1
- package/dist/cjs/br-item.cjs.entry.js +3 -6
- package/dist/cjs/br-item.entry.cjs.js.map +1 -1
- package/dist/cjs/br-message.cjs.entry.js +13 -16
- package/dist/cjs/br-message.entry.cjs.js.map +1 -1
- package/dist/cjs/br-modal.cjs.entry.js +8 -13
- package/dist/cjs/br-modal.entry.cjs.js.map +1 -1
- package/dist/cjs/br-scrim.cjs.entry.js +40 -51
- package/dist/cjs/br-scrim.entry.cjs.js.map +1 -1
- package/dist/cjs/br-skip-link.cjs.entry.js +25 -30
- package/dist/cjs/br-skip-link.entry.cjs.js.map +1 -1
- package/dist/cjs/br-skiplink-item.cjs.entry.js +32 -37
- package/dist/cjs/br-skiplink-item.entry.cjs.js.map +1 -1
- package/dist/cjs/br-step.br-step-item.entry.cjs.js.map +1 -1
- package/dist/cjs/br-step_2.cjs.entry.js +33 -56
- package/dist/cjs/br-switch.cjs.entry.js +3 -6
- package/dist/cjs/br-switch.entry.cjs.js.map +1 -1
- package/dist/cjs/br-textarea.cjs.entry.js +5 -8
- package/dist/cjs/br-textarea.entry.cjs.js.map +1 -1
- package/dist/cjs/br-tooltip.cjs.entry.js +1 -2
- package/dist/cjs/br-tooltip.entry.cjs.js.map +1 -1
- package/dist/cjs/br-wizard-panel.cjs.entry.js +6 -13
- package/dist/cjs/br-wizard-panel.entry.cjs.js.map +1 -1
- package/dist/cjs/br-wizard.cjs.entry.js +147 -182
- package/dist/cjs/br-wizard.entry.cjs.js.map +1 -1
- package/dist/cjs/{floating-ui-D_WzFT9x.js → floating-ui-CkTJEp-y.js} +11 -15
- package/dist/{esm/floating-ui-DBIzWbO2.js.map → cjs/floating-ui-CkTJEp-y.js.map} +1 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/webcomponents.cjs.js +1 -1
- package/dist/collection/components/checkbox/checkbox.js +9 -16
- package/dist/collection/components/checkbox/checkbox.js.map +1 -1
- package/dist/collection/components/collapse/collapse.js +10 -15
- package/dist/collection/components/collapse/collapse.js.map +1 -1
- package/dist/collection/components/datetime-picker/datetime-picker.js +18 -31
- package/dist/collection/components/datetime-picker/datetime-picker.js.map +1 -1
- package/dist/collection/components/dropdown/dropdown.js +13 -20
- package/dist/collection/components/dropdown/dropdown.js.map +1 -1
- package/dist/collection/components/header/header-list/header-list.js +6 -13
- package/dist/collection/components/header/header-list/header-list.js.map +1 -1
- package/dist/collection/components/header/header.js +2 -5
- package/dist/collection/components/header/header.js.map +1 -1
- package/dist/collection/components/item/item.js +3 -6
- package/dist/collection/components/item/item.js.map +1 -1
- package/dist/collection/components/message/message.js +13 -16
- package/dist/collection/components/message/message.js.map +1 -1
- package/dist/collection/components/modal/modal.js +8 -13
- package/dist/collection/components/modal/modal.js.map +1 -1
- package/dist/collection/components/radio/radio.js +8 -13
- package/dist/collection/components/radio/radio.js.map +1 -1
- package/dist/collection/components/scrim/scrim.js +40 -51
- package/dist/collection/components/scrim/scrim.js.map +1 -1
- package/dist/collection/components/select/select.js +79 -36
- package/dist/collection/components/select/select.js.map +1 -1
- package/dist/collection/components/skip-link/skip-link-item/skip-link-item.js +32 -37
- package/dist/collection/components/skip-link/skip-link-item/skip-link-item.js.map +1 -1
- package/dist/collection/components/skip-link/skip-link.js +25 -30
- package/dist/collection/components/skip-link/skip-link.js.map +1 -1
- package/dist/collection/components/step/step-item/step-item.js +13 -26
- package/dist/collection/components/step/step-item/step-item.js.map +1 -1
- package/dist/collection/components/step/step.js +20 -31
- package/dist/collection/components/step/step.js.map +1 -1
- package/dist/collection/components/switch/switch.js +3 -6
- package/dist/collection/components/switch/switch.js.map +1 -1
- package/dist/collection/components/textarea/textarea.js +5 -8
- package/dist/collection/components/textarea/textarea.js.map +1 -1
- package/dist/collection/components/wizard/wizard-panel/wizard-panel.js +6 -13
- package/dist/collection/components/wizard/wizard-panel/wizard-panel.js.map +1 -1
- package/dist/collection/components/wizard/wizard.js +147 -182
- package/dist/collection/components/wizard/wizard.js.map +1 -1
- package/dist/collection/utils/floating-ui.js +9 -12
- package/dist/collection/utils/floating-ui.js.map +1 -1
- package/dist/components/br-breadcrumb.js +3 -3
- package/dist/components/br-checkbox.js +4 -4
- package/dist/components/br-checkgroup.js +1 -1
- package/dist/components/br-collapse.js +4 -4
- package/dist/components/br-datetime-picker.js +1981 -1995
- package/dist/components/br-datetime-picker.js.map +1 -1
- package/dist/components/br-dropdown.js +1 -1
- package/dist/components/br-footer-category.js +3 -3
- package/dist/components/br-footer-item.js +1 -1
- package/dist/components/br-header-function.js +1 -1
- package/dist/components/br-header-link.js +1 -1
- package/dist/components/br-header-list.js +31 -39
- package/dist/components/br-header-list.js.map +1 -1
- package/dist/components/br-header.js +63 -67
- package/dist/components/br-header.js.map +1 -1
- package/dist/components/br-item.js +1 -1
- package/dist/components/br-list.js +3 -3
- package/dist/components/br-message.js +28 -32
- package/dist/components/br-message.js.map +1 -1
- package/dist/components/br-modal.js +21 -27
- package/dist/components/br-modal.js.map +1 -1
- package/dist/components/br-pagination.js +7 -7
- package/dist/components/br-radio.js +1 -1
- package/dist/components/br-scrim.js +49 -61
- package/dist/components/br-scrim.js.map +1 -1
- package/dist/components/br-select.js +3 -3
- package/dist/components/br-skip-link.js +42 -49
- package/dist/components/br-skip-link.js.map +1 -1
- package/dist/components/br-skiplink-item.js +55 -61
- package/dist/components/br-skiplink-item.js.map +1 -1
- package/dist/components/br-step-item.js +4 -4
- package/dist/components/br-step.js +4 -4
- package/dist/components/br-switch.js +12 -16
- package/dist/components/br-switch.js.map +1 -1
- package/dist/components/br-textarea.js +14 -18
- package/dist/components/br-textarea.js.map +1 -1
- package/dist/components/br-tooltip.js +1 -1
- package/dist/components/br-wizard-panel.js +13 -21
- package/dist/components/br-wizard-panel.js.map +1 -1
- package/dist/components/br-wizard.js +190 -228
- package/dist/components/br-wizard.js.map +1 -1
- package/dist/components/{p-Cc75U9ZX.js → p-B_YesJM8.js} +26 -34
- package/dist/components/{p-Cc75U9ZX.js.map → p-B_YesJM8.js.map} +1 -1
- package/dist/components/{p-xFn46pdm.js → p-Bc03PTAW.js} +27 -39
- package/dist/components/{p-xFn46pdm.js.map → p-Bc03PTAW.js.map} +1 -1
- package/dist/components/{p-DzKEfDGA.js → p-Bri6ECVa.js} +27 -33
- package/dist/components/{p-DzKEfDGA.js.map → p-Bri6ECVa.js.map} +1 -1
- package/dist/components/{p-BZ8BetvD.js → p-CJSXIVVe.js} +17 -23
- package/dist/components/{p-BZ8BetvD.js.map → p-CJSXIVVe.js.map} +1 -1
- package/dist/components/{p-D9c7NikS.js → p-CWRBs6PD.js} +24 -38
- package/dist/components/{p-D9c7NikS.js.map → p-CWRBs6PD.js.map} +1 -1
- package/dist/components/{p-D0dPo1K5.js → p-CwtLw60M.js} +12 -16
- package/dist/components/{p-D0dPo1K5.js.map → p-CwtLw60M.js.map} +1 -1
- package/dist/components/{p-z1PVVVFI.js → p-DW63EY0U.js} +27 -35
- package/dist/components/{p-z1PVVVFI.js.map → p-DW63EY0U.js.map} +1 -1
- package/dist/components/{p-7kxAU6Gr.js → p-DdjKNpU3.js} +92 -72
- package/dist/components/p-DdjKNpU3.js.map +1 -0
- package/dist/{webcomponents/p-B4au_byv.js → components/p-k0WZfTfL.js} +121 -124
- package/dist/components/{p-B4au_byv.js.map → p-k0WZfTfL.js.map} +1 -1
- package/dist/components/{p-OKkBxn1z.js → p-lIb35q2K.js} +3 -3
- package/dist/custom-elements.json +19459 -0
- package/dist/esm/br-checkbox.br-input.br-radio.entry.js.map +1 -1
- package/dist/esm/br-checkbox_3.entry.js +17 -28
- package/dist/esm/br-collapse.br-list.entry.js.map +1 -1
- package/dist/esm/br-collapse_2.entry.js +10 -15
- package/dist/esm/br-datetime-picker.entry.js +18 -31
- package/dist/esm/br-datetime-picker.entry.js.map +1 -1
- package/dist/esm/br-dropdown.br-select.entry.js.map +1 -1
- package/dist/esm/br-dropdown_2.entry.js +73 -56
- package/dist/esm/br-header-list.entry.js +6 -13
- package/dist/esm/br-header-list.entry.js.map +1 -1
- package/dist/esm/br-header.entry.js +2 -5
- package/dist/esm/br-header.entry.js.map +1 -1
- package/dist/esm/br-item.entry.js +3 -6
- package/dist/esm/br-item.entry.js.map +1 -1
- package/dist/esm/br-message.entry.js +13 -16
- package/dist/esm/br-message.entry.js.map +1 -1
- package/dist/esm/br-modal.entry.js +8 -13
- package/dist/esm/br-modal.entry.js.map +1 -1
- package/dist/esm/br-scrim.entry.js +40 -51
- package/dist/esm/br-scrim.entry.js.map +1 -1
- package/dist/esm/br-skip-link.entry.js +25 -30
- package/dist/esm/br-skip-link.entry.js.map +1 -1
- package/dist/esm/br-skiplink-item.entry.js +32 -37
- package/dist/esm/br-skiplink-item.entry.js.map +1 -1
- package/dist/esm/br-step.br-step-item.entry.js.map +1 -1
- package/dist/esm/br-step_2.entry.js +33 -56
- package/dist/esm/br-switch.entry.js +3 -6
- package/dist/esm/br-switch.entry.js.map +1 -1
- package/dist/esm/br-textarea.entry.js +5 -8
- package/dist/esm/br-textarea.entry.js.map +1 -1
- package/dist/esm/br-tooltip.entry.js +1 -2
- package/dist/esm/br-tooltip.entry.js.map +1 -1
- package/dist/esm/br-wizard-panel.entry.js +6 -13
- package/dist/esm/br-wizard-panel.entry.js.map +1 -1
- package/dist/esm/br-wizard.entry.js +147 -182
- package/dist/esm/br-wizard.entry.js.map +1 -1
- package/dist/esm/{floating-ui-DBIzWbO2.js → floating-ui-k0WZfTfL.js} +11 -15
- package/dist/{cjs/floating-ui-D_WzFT9x.js.map → esm/floating-ui-k0WZfTfL.js.map} +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/esm/webcomponents.js +1 -1
- package/dist/hydrate/index.js +451 -592
- package/dist/hydrate/index.mjs +451 -592
- package/dist/types/components/select/select.d.ts +5 -0
- package/dist/types/components.d.ts +10 -0
- package/dist/webcomponents/br-checkbox.br-input.br-radio.entry.esm.js.map +1 -1
- package/dist/webcomponents/br-collapse.br-list.entry.esm.js.map +1 -1
- package/dist/webcomponents/br-datetime-picker.entry.esm.js.map +1 -1
- package/dist/webcomponents/br-dropdown.br-select.entry.esm.js.map +1 -1
- package/dist/webcomponents/br-header-list.entry.esm.js.map +1 -1
- package/dist/webcomponents/br-header.entry.esm.js.map +1 -1
- package/dist/webcomponents/br-item.entry.esm.js.map +1 -1
- package/dist/webcomponents/br-message.entry.esm.js.map +1 -1
- package/dist/webcomponents/br-modal.entry.esm.js.map +1 -1
- package/dist/webcomponents/br-scrim.entry.esm.js.map +1 -1
- package/dist/webcomponents/br-skip-link.entry.esm.js.map +1 -1
- package/dist/webcomponents/br-skiplink-item.entry.esm.js.map +1 -1
- package/dist/webcomponents/br-step.br-step-item.entry.esm.js.map +1 -1
- package/dist/webcomponents/br-switch.entry.esm.js.map +1 -1
- package/dist/webcomponents/br-textarea.entry.esm.js.map +1 -1
- package/dist/webcomponents/br-tooltip.entry.esm.js.map +1 -1
- package/dist/webcomponents/br-wizard-panel.entry.esm.js.map +1 -1
- package/dist/webcomponents/br-wizard.entry.esm.js.map +1 -1
- package/dist/webcomponents/{p-2fe329d6.entry.js → p-10e25a32.entry.js} +28 -34
- package/dist/webcomponents/p-10e25a32.entry.js.map +1 -0
- package/dist/webcomponents/{p-61e5421b.entry.js → p-27eb10f9.entry.js} +57 -61
- package/dist/webcomponents/p-27eb10f9.entry.js.map +1 -0
- package/dist/webcomponents/{p-097912c2.entry.js → p-2be1c309.entry.js} +34 -41
- package/dist/webcomponents/p-2be1c309.entry.js.map +1 -0
- package/dist/webcomponents/{p-5070161f.entry.js → p-30af66b3.entry.js} +45 -51
- package/dist/webcomponents/p-30af66b3.entry.js.map +1 -0
- package/dist/webcomponents/{p-9464b692.entry.js → p-336071a5.entry.js} +2 -4
- package/dist/webcomponents/p-336071a5.entry.js.map +1 -0
- package/dist/webcomponents/{p-8a034433.entry.js → p-462c5647.entry.js} +20 -24
- package/dist/webcomponents/p-462c5647.entry.js.map +1 -0
- package/dist/webcomponents/{p-d674cee3.entry.js → p-46dfc3ee.entry.js} +12 -16
- package/dist/webcomponents/p-46dfc3ee.entry.js.map +1 -0
- package/dist/webcomponents/{p-821b896c.entry.js → p-56aabe89.entry.js} +36 -44
- package/dist/webcomponents/p-56aabe89.entry.js.map +1 -0
- package/dist/webcomponents/{p-a615baaa.entry.js → p-5710a3e9.entry.js} +41 -65
- package/dist/webcomponents/p-5710a3e9.entry.js.map +1 -0
- package/dist/webcomponents/{p-1799a082.entry.js → p-6a9d2a0b.entry.js} +1996 -2010
- package/dist/webcomponents/p-6a9d2a0b.entry.js.map +1 -0
- package/dist/webcomponents/{p-8ad1f003.entry.js → p-83001853.entry.js} +175 -213
- package/dist/webcomponents/p-83001853.entry.js.map +1 -0
- package/dist/webcomponents/{p-463b06a4.entry.js → p-90401ecd.entry.js} +32 -38
- package/dist/webcomponents/p-90401ecd.entry.js.map +1 -0
- package/dist/webcomponents/{p-216dc111.entry.js → p-a2eec4fb.entry.js} +49 -61
- package/dist/webcomponents/p-a2eec4fb.entry.js.map +1 -0
- package/dist/webcomponents/{p-d6475852.entry.js → p-c1b0a116.entry.js} +11 -19
- package/dist/webcomponents/p-c1b0a116.entry.js.map +1 -0
- package/dist/webcomponents/{p-c90a089a.entry.js → p-ca2d95f7.entry.js} +96 -83
- package/dist/webcomponents/p-ca2d95f7.entry.js.map +1 -0
- package/dist/webcomponents/{p-7ff6698f.entry.js → p-cfa86a23.entry.js} +10 -14
- package/dist/webcomponents/p-cfa86a23.entry.js.map +1 -0
- package/dist/webcomponents/{p-abc0ecbe.entry.js → p-e5875d3d.entry.js} +10 -14
- package/dist/webcomponents/p-e5875d3d.entry.js.map +1 -0
- package/dist/webcomponents/{p-0bfb0edf.entry.js → p-f2ea0d7e.entry.js} +133 -145
- package/dist/webcomponents/p-f2ea0d7e.entry.js.map +1 -0
- package/dist/{components/p-B4au_byv.js → webcomponents/p-k0WZfTfL.js} +121 -124
- package/dist/webcomponents/{p-B4au_byv.js.map → p-k0WZfTfL.js.map} +1 -1
- package/dist/webcomponents/webcomponents.esm.js +1 -1
- package/dist/webcomponents.html-custom-data.json +2573 -0
- package/package.json +1 -1
- package/dist/cjs/tslib.es6-CF44W9Bn.js +0 -42
- package/dist/cjs/tslib.es6-CF44W9Bn.js.map +0 -1
- package/dist/components/p-7kxAU6Gr.js.map +0 -1
- package/dist/components/p-DIPMDb5E.js +0 -55
- package/dist/components/p-DIPMDb5E.js.map +0 -1
- package/dist/esm/tslib.es6-DIPMDb5E.js +0 -40
- package/dist/esm/tslib.es6-DIPMDb5E.js.map +0 -1
- package/dist/webcomponents/p-097912c2.entry.js.map +0 -1
- package/dist/webcomponents/p-0bfb0edf.entry.js.map +0 -1
- package/dist/webcomponents/p-1799a082.entry.js.map +0 -1
- package/dist/webcomponents/p-216dc111.entry.js.map +0 -1
- package/dist/webcomponents/p-2fe329d6.entry.js.map +0 -1
- package/dist/webcomponents/p-463b06a4.entry.js.map +0 -1
- package/dist/webcomponents/p-5070161f.entry.js.map +0 -1
- package/dist/webcomponents/p-61e5421b.entry.js.map +0 -1
- package/dist/webcomponents/p-7ff6698f.entry.js.map +0 -1
- package/dist/webcomponents/p-821b896c.entry.js.map +0 -1
- package/dist/webcomponents/p-8a034433.entry.js.map +0 -1
- package/dist/webcomponents/p-8ad1f003.entry.js.map +0 -1
- package/dist/webcomponents/p-9464b692.entry.js.map +0 -1
- package/dist/webcomponents/p-DIPMDb5E.js +0 -55
- package/dist/webcomponents/p-DIPMDb5E.js.map +0 -1
- package/dist/webcomponents/p-a615baaa.entry.js.map +0 -1
- package/dist/webcomponents/p-abc0ecbe.entry.js.map +0 -1
- package/dist/webcomponents/p-c90a089a.entry.js.map +0 -1
- package/dist/webcomponents/p-d6475852.entry.js.map +0 -1
- package/dist/webcomponents/p-d674cee3.entry.js.map +0 -1
- /package/dist/components/{p-OKkBxn1z.js.map → p-lIb35q2K.js.map} +0 -0
|
@@ -2,40 +2,39 @@
|
|
|
2
2
|
* Construído por SERPRO
|
|
3
3
|
* © https://serpro.gov.br/ - MIT License.
|
|
4
4
|
*/
|
|
5
|
-
import { _ as t } from "./p-DIPMDb5E.js";
|
|
6
|
-
|
|
7
5
|
/**
|
|
8
6
|
* Custom positioning reference element.
|
|
9
7
|
* @see https://floating-ui.com/docs/virtual-elements
|
|
10
|
-
*/
|
|
8
|
+
*/
|
|
9
|
+
const t = [ "top", "right", "bottom", "left" ];
|
|
11
10
|
|
|
12
|
-
const
|
|
11
|
+
const e = Math.min;
|
|
13
12
|
|
|
14
|
-
const
|
|
13
|
+
const n = Math.max;
|
|
15
14
|
|
|
16
|
-
const
|
|
15
|
+
const o = Math.round;
|
|
17
16
|
|
|
18
|
-
const
|
|
17
|
+
const i = Math.floor;
|
|
19
18
|
|
|
20
19
|
const createCoords = t => ({
|
|
21
20
|
x: t,
|
|
22
21
|
y: t
|
|
23
22
|
});
|
|
24
23
|
|
|
25
|
-
const
|
|
24
|
+
const s = {
|
|
26
25
|
left: "right",
|
|
27
26
|
right: "left",
|
|
28
27
|
bottom: "top",
|
|
29
28
|
top: "bottom"
|
|
30
29
|
};
|
|
31
30
|
|
|
32
|
-
const
|
|
31
|
+
const r = {
|
|
33
32
|
start: "end",
|
|
34
33
|
end: "start"
|
|
35
34
|
};
|
|
36
35
|
|
|
37
|
-
function clamp(t,
|
|
38
|
-
return
|
|
36
|
+
function clamp(t, o, i) {
|
|
37
|
+
return n(t, e(o, i));
|
|
39
38
|
}
|
|
40
39
|
|
|
41
40
|
function evaluate(t, e) {
|
|
@@ -58,10 +57,10 @@ function getAxisLength(t) {
|
|
|
58
57
|
return t === "y" ? "height" : "width";
|
|
59
58
|
}
|
|
60
59
|
|
|
61
|
-
const
|
|
60
|
+
const c = new Set([ "top", "bottom" ]);
|
|
62
61
|
|
|
63
62
|
function getSideAxis(t) {
|
|
64
|
-
return
|
|
63
|
+
return c.has(getSide(t)) ? "y" : "x";
|
|
65
64
|
}
|
|
66
65
|
|
|
67
66
|
function getAlignmentAxis(t) {
|
|
@@ -88,27 +87,27 @@ function getExpandedPlacements(t) {
|
|
|
88
87
|
}
|
|
89
88
|
|
|
90
89
|
function getOppositeAlignmentPlacement(t) {
|
|
91
|
-
return t.replace(/start|end/g, (t =>
|
|
90
|
+
return t.replace(/start|end/g, (t => r[t]));
|
|
92
91
|
}
|
|
93
92
|
|
|
94
|
-
const
|
|
93
|
+
const l = [ "left", "right" ];
|
|
95
94
|
|
|
96
|
-
const
|
|
95
|
+
const a = [ "right", "left" ];
|
|
97
96
|
|
|
98
|
-
const
|
|
97
|
+
const f = [ "top", "bottom" ];
|
|
99
98
|
|
|
100
|
-
const
|
|
99
|
+
const u = [ "bottom", "top" ];
|
|
101
100
|
|
|
102
101
|
function getSideList(t, e, n) {
|
|
103
102
|
switch (t) {
|
|
104
103
|
case "top":
|
|
105
104
|
case "bottom":
|
|
106
|
-
if (n) return e ?
|
|
107
|
-
return e ?
|
|
105
|
+
if (n) return e ? a : l;
|
|
106
|
+
return e ? l : a;
|
|
108
107
|
|
|
109
108
|
case "left":
|
|
110
109
|
case "right":
|
|
111
|
-
return e ?
|
|
110
|
+
return e ? f : u;
|
|
112
111
|
|
|
113
112
|
default:
|
|
114
113
|
return [];
|
|
@@ -128,7 +127,7 @@ function getOppositeAxisPlacements(t, e, n, o) {
|
|
|
128
127
|
}
|
|
129
128
|
|
|
130
129
|
function getOppositePlacement(t) {
|
|
131
|
-
return t.replace(/left|right|bottom|top/g, (t =>
|
|
130
|
+
return t.replace(/left|right|bottom|top/g, (t => s[t]));
|
|
132
131
|
}
|
|
133
132
|
|
|
134
133
|
function expandPaddingObject(t) {
|
|
@@ -355,10 +354,10 @@ function computeCoordsFromPlacement(t, e, n) {
|
|
|
355
354
|
*/ const arrow$1 = t => ({
|
|
356
355
|
name: "arrow",
|
|
357
356
|
options: t,
|
|
358
|
-
async fn(
|
|
359
|
-
const {x: o, y: i, placement: s, rects: r, platform: c, elements: l, middlewareData: a} =
|
|
357
|
+
async fn(n) {
|
|
358
|
+
const {x: o, y: i, placement: s, rects: r, platform: c, elements: l, middlewareData: a} = n;
|
|
360
359
|
// Since `element` is required, we don't Partial<> the type.
|
|
361
|
-
const {element: f, padding: u = 0} = evaluate(t,
|
|
360
|
+
const {element: f, padding: u = 0} = evaluate(t, n) || {};
|
|
362
361
|
if (f == null) {
|
|
363
362
|
return {};
|
|
364
363
|
}
|
|
@@ -386,30 +385,30 @@ function computeCoordsFromPlacement(t, e, n) {
|
|
|
386
385
|
// If the padding is large enough that it causes the arrow to no longer be
|
|
387
386
|
// centered, modify the padding so that it is centered.
|
|
388
387
|
const E = O / 2 - h[p] / 2 - 1;
|
|
389
|
-
const
|
|
390
|
-
const
|
|
388
|
+
const R = e(g[y], E);
|
|
389
|
+
const P = e(g[v], E);
|
|
391
390
|
// Make sure the arrow doesn't overflow the floating element if the center
|
|
392
391
|
// point is outside the floating element's bounds.
|
|
393
|
-
const T =
|
|
394
|
-
const L = O - h[p] -
|
|
392
|
+
const T = R;
|
|
393
|
+
const L = O - h[p] - P;
|
|
395
394
|
const N = O / 2 - h[p] / 2 + C;
|
|
396
395
|
const F = clamp(T, N, L);
|
|
397
396
|
// If the reference is small enough that the arrow's padding causes it to
|
|
398
397
|
// to point to nothing for an aligned placement, adjust the offset of the
|
|
399
398
|
// floating element itself. To ensure `shift()` continues to take action,
|
|
400
399
|
// a single reset is performed when this is true.
|
|
401
|
-
const
|
|
402
|
-
const
|
|
400
|
+
const W = !a.arrow && getAlignment(s) != null && N !== F && r.reference[p] / 2 - (N < T ? R : P) - h[p] / 2 < 0;
|
|
401
|
+
const B = W ? N < T ? N - T : N - L : 0;
|
|
403
402
|
return {
|
|
404
|
-
[m]: d[m] +
|
|
403
|
+
[m]: d[m] + B,
|
|
405
404
|
data: {
|
|
406
405
|
[m]: F,
|
|
407
|
-
centerOffset: N - F -
|
|
408
|
-
...
|
|
409
|
-
alignmentOffset:
|
|
406
|
+
centerOffset: N - F - B,
|
|
407
|
+
...W && {
|
|
408
|
+
alignmentOffset: B
|
|
410
409
|
}
|
|
411
410
|
},
|
|
412
|
-
reset:
|
|
411
|
+
reset: W
|
|
413
412
|
};
|
|
414
413
|
}
|
|
415
414
|
})
|
|
@@ -464,8 +463,8 @@ const flip$1 = function(t) {
|
|
|
464
463
|
} ];
|
|
465
464
|
// One or more sides is overflowing.
|
|
466
465
|
if (!C.every((t => t <= 0))) {
|
|
467
|
-
var
|
|
468
|
-
const t = (((
|
|
466
|
+
var R, P;
|
|
467
|
+
const t = (((R = s.flip) == null ? void 0 : R.index) || 0) + 1;
|
|
469
468
|
const e = A[t];
|
|
470
469
|
if (e) {
|
|
471
470
|
const n = u === "alignment" ? y !== getSideAxis(e) : false;
|
|
@@ -487,7 +486,7 @@ const flip$1 = function(t) {
|
|
|
487
486
|
}
|
|
488
487
|
// First, find the candidates that fit on the mainAxis side of overflow,
|
|
489
488
|
// then find the placement that fits the best on the main crossAxis side.
|
|
490
|
-
let n = (
|
|
489
|
+
let n = (P = E.filter((t => t.overflows[0] <= 0)).sort(((t, e) => t.overflows[1] - e.overflows[1]))[0]) == null ? void 0 : P.placement;
|
|
491
490
|
// Otherwise fallback.
|
|
492
491
|
if (!n) {
|
|
493
492
|
switch (d) {
|
|
@@ -537,8 +536,8 @@ function getSideOffsets(t, e) {
|
|
|
537
536
|
};
|
|
538
537
|
}
|
|
539
538
|
|
|
540
|
-
function isAnySideFullyClipped(
|
|
541
|
-
return
|
|
539
|
+
function isAnySideFullyClipped(e) {
|
|
540
|
+
return t.some((t => e[t] >= 0));
|
|
542
541
|
}
|
|
543
542
|
|
|
544
543
|
/**
|
|
@@ -595,7 +594,7 @@ function isAnySideFullyClipped(t) {
|
|
|
595
594
|
};
|
|
596
595
|
};
|
|
597
596
|
|
|
598
|
-
const
|
|
597
|
+
const g = new Set([ "left", "top" ]);
|
|
599
598
|
|
|
600
599
|
// For type backwards-compatibility, the `OffsetOptions` type was also
|
|
601
600
|
// Derivable.
|
|
@@ -605,11 +604,11 @@ async function convertValueToCoords(t, e) {
|
|
|
605
604
|
const r = getSide(n);
|
|
606
605
|
const c = getAlignment(n);
|
|
607
606
|
const l = getSideAxis(n) === "y";
|
|
608
|
-
const a =
|
|
607
|
+
const a = g.has(r) ? -1 : 1;
|
|
609
608
|
const f = s && l ? -1 : 1;
|
|
610
609
|
const u = evaluate(e, t);
|
|
611
610
|
// eslint-disable-next-line prefer-const
|
|
612
|
-
let {mainAxis:
|
|
611
|
+
let {mainAxis: d, crossAxis: m, alignmentAxis: p} = typeof u === "number" ? {
|
|
613
612
|
mainAxis: u,
|
|
614
613
|
crossAxis: 0,
|
|
615
614
|
alignmentAxis: null
|
|
@@ -623,9 +622,9 @@ async function convertValueToCoords(t, e) {
|
|
|
623
622
|
}
|
|
624
623
|
return l ? {
|
|
625
624
|
x: m * f,
|
|
626
|
-
y:
|
|
625
|
+
y: d * a
|
|
627
626
|
} : {
|
|
628
|
-
x:
|
|
627
|
+
x: d * a,
|
|
629
628
|
y: m * f
|
|
630
629
|
};
|
|
631
630
|
}
|
|
@@ -781,23 +780,23 @@ function isShadowRoot(t) {
|
|
|
781
780
|
return t instanceof ShadowRoot || t instanceof getWindow(t).ShadowRoot;
|
|
782
781
|
}
|
|
783
782
|
|
|
784
|
-
const
|
|
783
|
+
const d = new Set([ "inline", "contents" ]);
|
|
785
784
|
|
|
786
785
|
function isOverflowElement(t) {
|
|
787
786
|
const {overflow: e, overflowX: n, overflowY: o, display: i} = getComputedStyle$1(t);
|
|
788
|
-
return /auto|scroll|overlay|hidden|clip/.test(e + o + n) && !
|
|
787
|
+
return /auto|scroll|overlay|hidden|clip/.test(e + o + n) && !d.has(i);
|
|
789
788
|
}
|
|
790
789
|
|
|
791
|
-
const
|
|
790
|
+
const m = new Set([ "table", "td", "th" ]);
|
|
792
791
|
|
|
793
792
|
function isTableElement(t) {
|
|
794
|
-
return
|
|
793
|
+
return m.has(getNodeName(t));
|
|
795
794
|
}
|
|
796
795
|
|
|
797
|
-
const
|
|
796
|
+
const p = [ ":popover-open", ":modal" ];
|
|
798
797
|
|
|
799
798
|
function isTopLayer(t) {
|
|
800
|
-
return
|
|
799
|
+
return p.some((e => {
|
|
801
800
|
try {
|
|
802
801
|
return t.matches(e);
|
|
803
802
|
} catch (t) {
|
|
@@ -806,18 +805,18 @@ function isTopLayer(t) {
|
|
|
806
805
|
}));
|
|
807
806
|
}
|
|
808
807
|
|
|
809
|
-
const
|
|
808
|
+
const h = [ "transform", "translate", "scale", "rotate", "perspective" ];
|
|
810
809
|
|
|
811
|
-
const
|
|
810
|
+
const w = [ "transform", "translate", "scale", "rotate", "perspective", "filter" ];
|
|
812
811
|
|
|
813
|
-
const
|
|
812
|
+
const y = [ "paint", "layout", "strict", "content" ];
|
|
814
813
|
|
|
815
814
|
function isContainingBlock(t) {
|
|
816
815
|
const e = isWebKit();
|
|
817
816
|
const n = isElement(t) ? getComputedStyle$1(t) : t;
|
|
818
817
|
// https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block
|
|
819
818
|
// https://drafts.csswg.org/css-transforms-2/#individual-transforms
|
|
820
|
-
return
|
|
819
|
+
return h.some((t => n[t] ? n[t] !== "none" : false)) || (n.containerType ? n.containerType !== "normal" : false) || !e && (n.backdropFilter ? n.backdropFilter !== "none" : false) || !e && (n.filter ? n.filter !== "none" : false) || w.some((t => (n.willChange || "").includes(t))) || y.some((t => (n.contain || "").includes(t)));
|
|
821
820
|
}
|
|
822
821
|
|
|
823
822
|
function getContainingBlock(t) {
|
|
@@ -838,10 +837,10 @@ function isWebKit() {
|
|
|
838
837
|
return CSS.supports("-webkit-backdrop-filter", "none");
|
|
839
838
|
}
|
|
840
839
|
|
|
841
|
-
const
|
|
840
|
+
const v = new Set([ "html", "body", "#document" ]);
|
|
842
841
|
|
|
843
842
|
function isLastTraversableNode(t) {
|
|
844
|
-
return
|
|
843
|
+
return v.has(getNodeName(t));
|
|
845
844
|
}
|
|
846
845
|
|
|
847
846
|
function getComputedStyle$1(t) {
|
|
@@ -915,18 +914,18 @@ function getCssDimensions(t) {
|
|
|
915
914
|
// In testing environments, the `width` and `height` properties are empty
|
|
916
915
|
// strings for SVG elements, returning NaN. Fallback to `0` in this case.
|
|
917
916
|
let n = parseFloat(e.width) || 0;
|
|
918
|
-
let
|
|
917
|
+
let i = parseFloat(e.height) || 0;
|
|
919
918
|
const s = isHTMLElement(t);
|
|
920
919
|
const r = s ? t.offsetWidth : n;
|
|
921
|
-
const c = s ? t.offsetHeight :
|
|
922
|
-
const l =
|
|
920
|
+
const c = s ? t.offsetHeight : i;
|
|
921
|
+
const l = o(n) !== r || o(i) !== c;
|
|
923
922
|
if (l) {
|
|
924
923
|
n = r;
|
|
925
|
-
|
|
924
|
+
i = c;
|
|
926
925
|
}
|
|
927
926
|
return {
|
|
928
927
|
width: n,
|
|
929
|
-
height:
|
|
928
|
+
height: i,
|
|
930
929
|
$: l
|
|
931
930
|
};
|
|
932
931
|
}
|
|
@@ -941,9 +940,9 @@ function getScale(t) {
|
|
|
941
940
|
return createCoords(1);
|
|
942
941
|
}
|
|
943
942
|
const n = e.getBoundingClientRect();
|
|
944
|
-
const {width:
|
|
945
|
-
let c = (r ?
|
|
946
|
-
let l = (r ?
|
|
943
|
+
const {width: i, height: s, $: r} = getCssDimensions(e);
|
|
944
|
+
let c = (r ? o(n.width) : n.width) / i;
|
|
945
|
+
let l = (r ? o(n.height) : n.height) / s;
|
|
947
946
|
// 0, NaN, or Infinity should always fallback to 1.
|
|
948
947
|
if (!c || !Number.isFinite(c)) {
|
|
949
948
|
c = 1;
|
|
@@ -957,12 +956,12 @@ function getScale(t) {
|
|
|
957
956
|
};
|
|
958
957
|
}
|
|
959
958
|
|
|
960
|
-
const
|
|
959
|
+
const x = createCoords(0);
|
|
961
960
|
|
|
962
961
|
function getVisualOffsets(t) {
|
|
963
962
|
const e = getWindow(t);
|
|
964
963
|
if (!isWebKit() || !e.visualViewport) {
|
|
965
|
-
return
|
|
964
|
+
return x;
|
|
966
965
|
}
|
|
967
966
|
return {
|
|
968
967
|
x: e.visualViewport.offsetLeft,
|
|
@@ -1096,14 +1095,14 @@ function getClientRects(t) {
|
|
|
1096
1095
|
// of the `<html>` and `<body>` rect bounds if horizontally scrollable.
|
|
1097
1096
|
function getDocumentRect(t) {
|
|
1098
1097
|
const e = getDocumentElement(t);
|
|
1099
|
-
const
|
|
1098
|
+
const o = getNodeScroll(t);
|
|
1100
1099
|
const i = t.ownerDocument.body;
|
|
1101
|
-
const s =
|
|
1102
|
-
const r =
|
|
1103
|
-
let c = -
|
|
1104
|
-
const l = -
|
|
1100
|
+
const s = n(e.scrollWidth, e.clientWidth, i.scrollWidth, i.clientWidth);
|
|
1101
|
+
const r = n(e.scrollHeight, e.clientHeight, i.scrollHeight, i.clientHeight);
|
|
1102
|
+
let c = -o.scrollLeft + getWindowScrollBarX(t);
|
|
1103
|
+
const l = -o.scrollTop;
|
|
1105
1104
|
if (getComputedStyle$1(i).direction === "rtl") {
|
|
1106
|
-
c +=
|
|
1105
|
+
c += n(e.clientWidth, i.clientWidth) - s;
|
|
1107
1106
|
}
|
|
1108
1107
|
return {
|
|
1109
1108
|
width: s,
|
|
@@ -1116,7 +1115,7 @@ function getDocumentRect(t) {
|
|
|
1116
1115
|
// Safety check: ensure the scrollbar space is reasonable in case this
|
|
1117
1116
|
// calculation is affected by unusual styles.
|
|
1118
1117
|
// Most scrollbars leave 15-18px of space.
|
|
1119
|
-
const
|
|
1118
|
+
const b = 25;
|
|
1120
1119
|
|
|
1121
1120
|
function getViewportRect(t, e) {
|
|
1122
1121
|
const n = getWindow(t);
|
|
@@ -1145,10 +1144,10 @@ function getViewportRect(t, e) {
|
|
|
1145
1144
|
const n = getComputedStyle(e);
|
|
1146
1145
|
const i = t.compatMode === "CSS1Compat" ? parseFloat(n.marginLeft) + parseFloat(n.marginRight) || 0 : 0;
|
|
1147
1146
|
const r = Math.abs(o.clientWidth - e.clientWidth - i);
|
|
1148
|
-
if (r <=
|
|
1147
|
+
if (r <= b) {
|
|
1149
1148
|
s -= r;
|
|
1150
1149
|
}
|
|
1151
|
-
} else if (a <=
|
|
1150
|
+
} else if (a <= b) {
|
|
1152
1151
|
// If the <body> scrollbar is on the left, the width needs to be extended
|
|
1153
1152
|
// by the scrollbar amount so there isn't extra space on the right.
|
|
1154
1153
|
s += a;
|
|
@@ -1161,7 +1160,7 @@ function getViewportRect(t, e) {
|
|
|
1161
1160
|
};
|
|
1162
1161
|
}
|
|
1163
1162
|
|
|
1164
|
-
const
|
|
1163
|
+
const S = new Set([ "absolute", "fixed" ]);
|
|
1165
1164
|
|
|
1166
1165
|
// Returns the inner client rect, subtracting scrollbars if present.
|
|
1167
1166
|
function getInnerBoundingClientRect(t, e) {
|
|
@@ -1228,7 +1227,7 @@ function getClippingElementAncestors(t, e) {
|
|
|
1228
1227
|
if (!n && e.position === "fixed") {
|
|
1229
1228
|
i = null;
|
|
1230
1229
|
}
|
|
1231
|
-
const c = s ? !n && !i : !n && e.position === "static" && !!i &&
|
|
1230
|
+
const c = s ? !n && !i : !n && e.position === "static" && !!i && S.has(i.position) || isOverflowElement(r) && !n && hasFixedPositionAncestor(t, r);
|
|
1232
1231
|
if (c) {
|
|
1233
1232
|
// Drop non-containing blocks.
|
|
1234
1233
|
o = o.filter((t => t !== r));
|
|
@@ -1245,18 +1244,18 @@ function getClippingElementAncestors(t, e) {
|
|
|
1245
1244
|
// Gets the maximum area that the element is visible in due to any number of
|
|
1246
1245
|
// clipping ancestors.
|
|
1247
1246
|
function getClippingRect(t) {
|
|
1248
|
-
let {element:
|
|
1249
|
-
const c = i === "clippingAncestors" ? isTopLayer(
|
|
1247
|
+
let {element: o, boundary: i, rootBoundary: s, strategy: r} = t;
|
|
1248
|
+
const c = i === "clippingAncestors" ? isTopLayer(o) ? [] : getClippingElementAncestors(o, this._c) : [].concat(i);
|
|
1250
1249
|
const l = [ ...c, s ];
|
|
1251
1250
|
const a = l[0];
|
|
1252
1251
|
const f = l.reduce(((t, i) => {
|
|
1253
|
-
const s = getClientRectFromClippingAncestor(
|
|
1254
|
-
t.top =
|
|
1255
|
-
t.right =
|
|
1256
|
-
t.bottom =
|
|
1257
|
-
t.left =
|
|
1252
|
+
const s = getClientRectFromClippingAncestor(o, i, r);
|
|
1253
|
+
t.top = n(s.top, t.top);
|
|
1254
|
+
t.right = e(s.right, t.right);
|
|
1255
|
+
t.bottom = e(s.bottom, t.bottom);
|
|
1256
|
+
t.left = n(s.left, t.left);
|
|
1258
1257
|
return t;
|
|
1259
|
-
}), getClientRectFromClippingAncestor(
|
|
1258
|
+
}), getClientRectFromClippingAncestor(o, a, r));
|
|
1260
1259
|
return {
|
|
1261
1260
|
width: f.right - f.left,
|
|
1262
1261
|
height: f.bottom - f.top,
|
|
@@ -1382,7 +1381,7 @@ function isRTL(t) {
|
|
|
1382
1381
|
return getComputedStyle$1(t).direction === "rtl";
|
|
1383
1382
|
}
|
|
1384
1383
|
|
|
1385
|
-
const
|
|
1384
|
+
const A = {
|
|
1386
1385
|
convertOffsetParentRelativeRectToViewportRelativeRect,
|
|
1387
1386
|
getDocumentElement,
|
|
1388
1387
|
getClippingRect,
|
|
@@ -1400,15 +1399,15 @@ function rectsAreEqual(t, e) {
|
|
|
1400
1399
|
}
|
|
1401
1400
|
|
|
1402
1401
|
// https://samthor.au/2021/observing-dom/
|
|
1403
|
-
function observeMove(t,
|
|
1404
|
-
let
|
|
1402
|
+
function observeMove(t, o) {
|
|
1403
|
+
let s = null;
|
|
1405
1404
|
let r;
|
|
1406
1405
|
const c = getDocumentElement(t);
|
|
1407
1406
|
function cleanup() {
|
|
1408
1407
|
var t;
|
|
1409
1408
|
clearTimeout(r);
|
|
1410
|
-
(t =
|
|
1411
|
-
|
|
1409
|
+
(t = s) == null || t.disconnect();
|
|
1410
|
+
s = null;
|
|
1412
1411
|
}
|
|
1413
1412
|
function refresh(l, a) {
|
|
1414
1413
|
if (l === void 0) {
|
|
@@ -1421,19 +1420,19 @@ function observeMove(t, e) {
|
|
|
1421
1420
|
const f = t.getBoundingClientRect();
|
|
1422
1421
|
const {left: u, top: g, width: d, height: m} = f;
|
|
1423
1422
|
if (!l) {
|
|
1424
|
-
|
|
1423
|
+
o();
|
|
1425
1424
|
}
|
|
1426
1425
|
if (!d || !m) {
|
|
1427
1426
|
return;
|
|
1428
1427
|
}
|
|
1429
|
-
const p =
|
|
1430
|
-
const h =
|
|
1431
|
-
const w =
|
|
1432
|
-
const y =
|
|
1428
|
+
const p = i(g);
|
|
1429
|
+
const h = i(c.clientWidth - (u + d));
|
|
1430
|
+
const w = i(c.clientHeight - (g + m));
|
|
1431
|
+
const y = i(u);
|
|
1433
1432
|
const v = -p + "px " + -h + "px " + -w + "px " + -y + "px";
|
|
1434
1433
|
const x = {
|
|
1435
1434
|
rootMargin: v,
|
|
1436
|
-
threshold:
|
|
1435
|
+
threshold: n(0, e(1, a)) || 1
|
|
1437
1436
|
};
|
|
1438
1437
|
let b = true;
|
|
1439
1438
|
function handleObserve(e) {
|
|
@@ -1467,15 +1466,15 @@ function observeMove(t, e) {
|
|
|
1467
1466
|
// Older browsers don't support a `document` as the root and will throw an
|
|
1468
1467
|
// error.
|
|
1469
1468
|
try {
|
|
1470
|
-
|
|
1469
|
+
s = new IntersectionObserver(handleObserve, {
|
|
1471
1470
|
...x,
|
|
1472
1471
|
// Handle <iframe>s
|
|
1473
1472
|
root: c.ownerDocument
|
|
1474
1473
|
});
|
|
1475
1474
|
} catch (t) {
|
|
1476
|
-
|
|
1475
|
+
s = new IntersectionObserver(handleObserve, x);
|
|
1477
1476
|
}
|
|
1478
|
-
|
|
1477
|
+
s.observe(t);
|
|
1479
1478
|
}
|
|
1480
1479
|
refresh(true);
|
|
1481
1480
|
return cleanup;
|
|
@@ -1559,20 +1558,20 @@ function observeMove(t, e) {
|
|
|
1559
1558
|
* A number (shorthand for `mainAxis` or distance), or an axes configuration
|
|
1560
1559
|
* object may be passed.
|
|
1561
1560
|
* @see https://floating-ui.com/docs/offset
|
|
1562
|
-
*/ const
|
|
1561
|
+
*/ const O = offset$1;
|
|
1563
1562
|
|
|
1564
1563
|
/**
|
|
1565
1564
|
* Optimizes the visibility of the floating element by shifting it in order to
|
|
1566
1565
|
* keep it in view when it will overflow the clipping boundary.
|
|
1567
1566
|
* @see https://floating-ui.com/docs/shift
|
|
1568
|
-
*/ const
|
|
1567
|
+
*/ const C = shift$1;
|
|
1569
1568
|
|
|
1570
1569
|
/**
|
|
1571
1570
|
* Optimizes the visibility of the floating element by flipping the `placement`
|
|
1572
1571
|
* in order to keep it in view when the preferred placement(s) will overflow the
|
|
1573
1572
|
* clipping boundary. Alternative to `autoPlacement`.
|
|
1574
1573
|
* @see https://floating-ui.com/docs/flip
|
|
1575
|
-
*/ const
|
|
1574
|
+
*/ const E = flip$1;
|
|
1576
1575
|
|
|
1577
1576
|
/**
|
|
1578
1577
|
* Provides data to hide the floating element in applicable situations, such as
|
|
@@ -1584,7 +1583,7 @@ function observeMove(t, e) {
|
|
|
1584
1583
|
* Provides data to position an inner element of the floating element so that it
|
|
1585
1584
|
* appears centered to the reference element.
|
|
1586
1585
|
* @see https://floating-ui.com/docs/arrow
|
|
1587
|
-
*/ const
|
|
1586
|
+
*/ const P = arrow$1;
|
|
1588
1587
|
|
|
1589
1588
|
/**
|
|
1590
1589
|
* Computes the `x` and `y` coordinates that will place the floating element
|
|
@@ -1595,7 +1594,7 @@ function observeMove(t, e) {
|
|
|
1595
1594
|
// single call. If other functions become expensive, we can add them as well.
|
|
1596
1595
|
const o = new Map;
|
|
1597
1596
|
const i = {
|
|
1598
|
-
platform:
|
|
1597
|
+
platform: A,
|
|
1599
1598
|
...n
|
|
1600
1599
|
};
|
|
1601
1600
|
const s = {
|
|
@@ -1612,7 +1611,7 @@ function observeMove(t, e) {
|
|
|
1612
1611
|
* FloatingUIManager é uma classe utilitária que gerencia o posicionamento de elementos flutuantes
|
|
1613
1612
|
* como tooltips ou popovers em relação a um elemento de disparo (trigger).
|
|
1614
1613
|
* Ela utiliza a biblioteca Floating UI para calcular posições e lidar com atualizações.
|
|
1615
|
-
*/ class
|
|
1614
|
+
*/ class T {
|
|
1616
1615
|
constructor(t) {
|
|
1617
1616
|
var e;
|
|
1618
1617
|
this.triggerElement = t.triggerElement;
|
|
@@ -1639,18 +1638,16 @@ function observeMove(t, e) {
|
|
|
1639
1638
|
* Também atualiza a posição da seta, se fornecida.
|
|
1640
1639
|
* Além disso, define o atributo de dados `data-placement` no elemento de conteúdo para refletir a posição atual.
|
|
1641
1640
|
* @returns {Promise<void>} Uma promessa que resolve quando a posição é atualizada.
|
|
1642
|
-
*/ updatePosition() {
|
|
1643
|
-
|
|
1644
|
-
|
|
1645
|
-
|
|
1646
|
-
|
|
1647
|
-
|
|
1648
|
-
|
|
1649
|
-
|
|
1650
|
-
|
|
1651
|
-
|
|
1652
|
-
(t = this.onUpdate) === null || t === void 0 ? void 0 : t.call(this, e);
|
|
1653
|
-
}));
|
|
1641
|
+
*/ async updatePosition() {
|
|
1642
|
+
var t;
|
|
1643
|
+
const e = await computePosition(this.triggerElement, this.contentElement, {
|
|
1644
|
+
placement: this.placement,
|
|
1645
|
+
middleware: this.buildMiddleware()
|
|
1646
|
+
});
|
|
1647
|
+
this.updateTooltipPosition(e);
|
|
1648
|
+
this.updateArrowPosition(e);
|
|
1649
|
+
this.setPlacementDataAttribute(e);
|
|
1650
|
+
(t = this.onUpdate) === null || t === void 0 ? void 0 : t.call(this, e);
|
|
1654
1651
|
}
|
|
1655
1652
|
/**
|
|
1656
1653
|
* Constrói os middlewares necessários para o Floating UI.
|
|
@@ -1658,11 +1655,11 @@ function observeMove(t, e) {
|
|
|
1658
1655
|
* incluindo offset, flip, shift e hide. Se uma seta for fornecida, o middleware de seta também é adicionado.
|
|
1659
1656
|
* @returns {Middleware[]} Retorna um array de middlewares configurados para o Floating UI.
|
|
1660
1657
|
*/ buildMiddleware() {
|
|
1661
|
-
const t = [
|
|
1658
|
+
const t = [ O(8), E(), C({
|
|
1662
1659
|
padding: 5
|
|
1663
1660
|
}), R() ];
|
|
1664
1661
|
if (this.arrowElement != null) {
|
|
1665
|
-
t.push(
|
|
1662
|
+
t.push(P({
|
|
1666
1663
|
element: this.arrowElement
|
|
1667
1664
|
}));
|
|
1668
1665
|
}
|
|
@@ -1716,6 +1713,6 @@ function observeMove(t, e) {
|
|
|
1716
1713
|
}
|
|
1717
1714
|
}
|
|
1718
1715
|
|
|
1719
|
-
export {
|
|
1720
|
-
//# sourceMappingURL=p-
|
|
1721
|
-
//# sourceMappingURL=p-
|
|
1716
|
+
export { T as F };
|
|
1717
|
+
//# sourceMappingURL=p-k0WZfTfL.js.map
|
|
1718
|
+
//# sourceMappingURL=p-k0WZfTfL.js.map
|