@esri/calcite-components 5.2.0-next.31 → 5.2.0-next.33
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/cdn/{CU7CJFBQ.js → 2GG5WJZ2.js} +1 -1
- package/dist/cdn/{JFKJED36.js → 2RR6DRJZ.js} +1 -1
- package/dist/cdn/{5PHIIVOU.js → 2ZCW5SHY.js} +1 -1
- package/dist/cdn/{UYUBR74C.js → 37HSCZWM.js} +1 -1
- package/dist/cdn/{JSGT6DCJ.js → 37MDDA2R.js} +1 -1
- package/dist/cdn/{GSG6GHLN.js → 3GJBTYP6.js} +1 -1
- package/dist/cdn/{6YTP7R4Z.js → 3I6NCIU6.js} +1 -1
- package/dist/cdn/{CIZGCFP6.js → 3US3IAPR.js} +1 -1
- package/dist/cdn/{2H7GADY6.js → 3WLVOWHC.js} +1 -1
- package/dist/cdn/{ZVDNCEBK.js → 4674UWCN.js} +1 -1
- package/dist/cdn/{O7NYKDOG.js → 46EMOVPJ.js} +1 -1
- package/dist/cdn/{ZJHYIAS5.js → 46XLMFW4.js} +1 -1
- package/dist/cdn/{BAG3AJA4.js → 4B2H4UXQ.js} +1 -1
- package/dist/cdn/{7ZO4IPZP.js → 4DFCGU4F.js} +1 -1
- package/dist/cdn/{6TS5ZWQ7.js → 4GIJM5PH.js} +1 -1
- package/dist/cdn/{WKGZT2PG.js → 4HDJWLQ7.js} +1 -1
- package/dist/cdn/{IKBEV42F.js → 4OFBKSKN.js} +1 -1
- package/dist/cdn/{MQDJHBBP.js → 4QZUWISY.js} +1 -1
- package/dist/cdn/{S6KZLK5M.js → 5GX5HL7A.js} +1 -1
- package/dist/cdn/5IG7LHMX.js +2 -0
- package/dist/cdn/{5RP24S6I.js → 5VGVDEIU.js} +1 -1
- package/dist/cdn/{B35DWLY3.js → 6P2K3A57.js} +1 -1
- package/dist/cdn/{5JJPS3HK.js → 6PMLDIXD.js} +1 -1
- package/dist/cdn/{Y42AXULS.js → 6QX32DQR.js} +1 -1
- package/dist/cdn/{AGIZ5KII.js → 6RT6J3DX.js} +1 -1
- package/dist/cdn/{B5SOOORA.js → 6ZXBCNXC.js} +1 -1
- package/dist/cdn/{ZXZ7BCV3.js → 75I3WNIM.js} +1 -1
- package/dist/cdn/{K4PSZCHX.js → 77QCPBMC.js} +1 -1
- package/dist/cdn/{ESLOUCHV.js → AVCECO7Z.js} +1 -1
- package/dist/cdn/{P2S6K7H4.js → AZPPPVW7.js} +1 -1
- package/dist/cdn/{TSZKDMVH.js → B4ZQFSCB.js} +1 -1
- package/dist/cdn/{GXI7Q6QU.js → BABSLEYQ.js} +1 -1
- package/dist/cdn/{JGCDFFLC.js → BAEPIHLC.js} +1 -1
- package/dist/cdn/{XHEIS6D3.js → BBGUUQ27.js} +1 -1
- package/dist/cdn/{RT3EYWNV.js → BKL6IZCX.js} +1 -1
- package/dist/cdn/{B32RTCOC.js → BRKJWLJ3.js} +1 -1
- package/dist/cdn/{GJYVDQON.js → BWUBINBO.js} +1 -1
- package/dist/cdn/{6ICS6SMF.js → BX3OKDMC.js} +1 -1
- package/dist/cdn/{P6CXN7P4.js → C47RBXMD.js} +1 -1
- package/dist/cdn/{URIFYT4D.js → C5DKUE6G.js} +1 -1
- package/dist/cdn/{BXPFZXKS.js → CFZYQZYE.js} +1 -1
- package/dist/cdn/{GVQVBOVP.js → CHGLSJHW.js} +1 -1
- package/dist/cdn/{JZA7C6P3.js → CKEFWQNB.js} +1 -1
- package/dist/cdn/{YLAZZLRL.js → CM3XMRLZ.js} +1 -1
- package/dist/cdn/{DGQGNFWC.js → CMC2XDM6.js} +1 -1
- package/dist/cdn/{GTTVUYZE.js → D4KZEAYI.js} +1 -1
- package/dist/cdn/{ETODEMQI.js → D6CXDU3W.js} +1 -1
- package/dist/cdn/{G6JEYMUX.js → DB57RYTA.js} +1 -1
- package/dist/cdn/{CN7PTHEB.js → DFF4EOLD.js} +1 -1
- package/dist/cdn/{HFKP45FH.js → DN5OMZUO.js} +1 -1
- package/dist/cdn/{DM6ECIF2.js → DTSFQVNC.js} +1 -1
- package/dist/cdn/{LPRA3T32.js → ECSSKIE3.js} +1 -1
- package/dist/cdn/{H6J4OSM7.js → EFWGS5PI.js} +1 -1
- package/dist/cdn/{IRVIPQ7D.js → EHQCJKE5.js} +1 -1
- package/dist/cdn/{HIHNZASH.js → EN55H6CB.js} +1 -1
- package/dist/cdn/{B64U7QND.js → EOAEBSPQ.js} +1 -1
- package/dist/cdn/{YA7ARNQJ.js → ET3FQEVJ.js} +1 -1
- package/dist/cdn/{BN3I74NC.js → F4H4VQT2.js} +1 -1
- package/dist/cdn/{62XMTWRN.js → F5MUC5DJ.js} +1 -1
- package/dist/cdn/{XOGICJGV.js → FPCL46QC.js} +1 -1
- package/dist/cdn/{B2S475VC.js → FRRT4G2O.js} +1 -1
- package/dist/cdn/{7UDX2IW2.js → FU6Z4CWX.js} +1 -1
- package/dist/cdn/{U5K5WQQL.js → G7SZDFCD.js} +1 -1
- package/dist/cdn/{34LKI7AN.js → GGMK3KZU.js} +1 -1
- package/dist/cdn/{2YFHVR5X.js → GI33XEIF.js} +1 -1
- package/dist/cdn/{ASAPFCDE.js → GKNNITKF.js} +1 -1
- package/dist/cdn/{KMRQDEB2.js → GR6WAC5B.js} +1 -1
- package/dist/cdn/{KDQXAYDJ.js → H6KT2QMH.js} +1 -1
- package/dist/cdn/{5XTVVQ6D.js → HAUC3ZTO.js} +1 -1
- package/dist/cdn/{YUYGZXBT.js → HBZYYCM2.js} +1 -1
- package/dist/cdn/{SIYPKMOX.js → HEXBKECR.js} +1 -1
- package/dist/cdn/{DX4UNEXL.js → HMJ24I6B.js} +1 -1
- package/dist/cdn/{DSZP76JS.js → HUPA5IFV.js} +1 -1
- package/dist/cdn/{EBF72GF4.js → IB72JSFF.js} +1 -1
- package/dist/cdn/{YM7MW4ZE.js → IT6JFKUK.js} +1 -1
- package/dist/cdn/{WBRB2MAG.js → J5VDG2CV.js} +1 -1
- package/dist/cdn/{GVXEBJEW.js → JOCLP663.js} +1 -1
- package/dist/cdn/{FAYBZ4NA.js → JWBGLAPO.js} +1 -1
- package/dist/cdn/{OSBBG6HI.js → KNGIJFVN.js} +1 -1
- package/dist/cdn/KOI4GURL.js +2 -0
- package/dist/cdn/{IJ5EZCER.js → KZ7TTBTC.js} +1 -1
- package/dist/cdn/{DDD32FUC.js → LI52BZOS.js} +1 -1
- package/dist/cdn/{5WA7VCUZ.js → LSO6DDC3.js} +1 -1
- package/dist/cdn/{QPZWBDRN.js → LWASXXOJ.js} +1 -1
- package/dist/cdn/{SZHLLS6U.js → LXEWKP4V.js} +1 -1
- package/dist/cdn/{XNTVXLSV.js → M4KQZXFD.js} +1 -1
- package/dist/cdn/{2KBNA5VV.js → M6XLHY3H.js} +1 -1
- package/dist/cdn/{RA3ZTRG2.js → MJQR7Q4D.js} +1 -1
- package/dist/cdn/{4DQGC5JY.js → MPTMZGOH.js} +1 -1
- package/dist/cdn/{KCNYR66O.js → MVJ53E5E.js} +1 -1
- package/dist/cdn/{2PB3PUJA.js → NG2FNZKH.js} +1 -1
- package/dist/cdn/{3GDCEW2O.js → NJ53QODK.js} +1 -1
- package/dist/cdn/{SAW4B7WT.js → NRDIA4LH.js} +1 -1
- package/dist/cdn/{MIXAK4SX.js → NVCKG2LA.js} +1 -1
- package/dist/cdn/{N3NMWUPR.js → NVXOJYTF.js} +1 -1
- package/dist/cdn/{5HDPDQLH.js → O2NZXAPE.js} +1 -1
- package/dist/cdn/{OAT4WOFR.js → O4CG2KMT.js} +1 -1
- package/dist/cdn/{O3ZI5ANT.js → OHNA55LL.js} +1 -1
- package/dist/cdn/{SKFU336B.js → OMTJ4L2P.js} +1 -1
- package/dist/cdn/{GL2M4Y47.js → OTEQPSJQ.js} +1 -1
- package/dist/cdn/{NEUPWH65.js → PKRLTMPS.js} +1 -1
- package/dist/cdn/{D5VAYHIC.js → PTCHII4U.js} +1 -1
- package/dist/cdn/{SRJHFMFP.js → PV7TDYU3.js} +1 -1
- package/dist/cdn/{275HTM6C.js → PXYIOZIV.js} +1 -1
- package/dist/cdn/{IXX32AEN.js → Q2WVT7UK.js} +1 -1
- package/dist/cdn/{YWGZAN5R.js → QECDBCGY.js} +1 -1
- package/dist/cdn/{TBX6B7NS.js → QNDDCBWA.js} +1 -1
- package/dist/cdn/{H34AXDQR.js → QURYHC53.js} +1 -1
- package/dist/cdn/{HX5G6PEU.js → R7KFMQQW.js} +1 -1
- package/dist/cdn/{OIYAOKXL.js → RGID7PSO.js} +1 -1
- package/dist/cdn/{OHEH32P2.js → RGSJYFQH.js} +1 -1
- package/dist/cdn/{ILFOOTH6.js → RJBTDVGZ.js} +1 -1
- package/dist/cdn/{I7VLBVVR.js → RTAA5SCY.js} +1 -1
- package/dist/cdn/{WQBBH5FE.js → RWVOVOFX.js} +1 -1
- package/dist/cdn/{JGO735CO.js → S3VRNZZL.js} +1 -1
- package/dist/cdn/{ST5SCEF4.js → S5CTHPE7.js} +1 -1
- package/dist/cdn/{5IPGJCLD.js → SPIULO4N.js} +1 -1
- package/dist/cdn/{S5W6RC6X.js → SYREZKUP.js} +1 -1
- package/dist/cdn/{C7ODFPXC.js → T6NIS7OZ.js} +1 -1
- package/dist/cdn/{XZZQRQ65.js → TIHX4AAH.js} +1 -1
- package/dist/cdn/{5WH4GGFT.js → TXCBHQPT.js} +1 -1
- package/dist/cdn/{SRNYDEOY.js → TZLAWKW7.js} +1 -1
- package/dist/cdn/{2DNDO7OS.js → UHB37CJC.js} +1 -1
- package/dist/cdn/{4XIM5ILC.js → VBZNY3J7.js} +1 -1
- package/dist/cdn/{FRJN2MYE.js → VVVKQ5W4.js} +1 -1
- package/dist/cdn/{EJ4Q77N6.js → W2WT7Q5D.js} +1 -1
- package/dist/cdn/{ZYUHSMKB.js → W7CROCVR.js} +1 -1
- package/dist/cdn/{XPIK2PAN.js → WBFIK4DJ.js} +1 -1
- package/dist/cdn/{W64C3RNL.js → WLNVICGJ.js} +1 -1
- package/dist/cdn/{VLZTSSQW.js → WVV35MYK.js} +1 -1
- package/dist/cdn/{73LRUXQN.js → WZTZBANR.js} +1 -1
- package/dist/cdn/{LG7NMJYN.js → X3E3YKXL.js} +1 -1
- package/dist/cdn/{PUPGDIZ5.js → X3QN4ONZ.js} +1 -1
- package/dist/cdn/{OMBL5LNO.js → X4JVOXEB.js} +1 -1
- package/dist/cdn/X55EXSZ4.js +2 -0
- package/dist/cdn/{F3AVUHA6.js → XGEGV5M4.js} +1 -1
- package/dist/cdn/{QN35D4ON.js → XMX7ZLMR.js} +1 -1
- package/dist/cdn/{O6SPXDVK.js → Y5VJK3NK.js} +1 -1
- package/dist/cdn/{554NDE73.js → YIXTHTJK.js} +1 -1
- package/dist/cdn/{BXZHLQWU.js → YRB3YUJ2.js} +1 -1
- package/dist/cdn/{NQY3QGUP.js → ZAWJZUWL.js} +1 -1
- package/dist/cdn/{34T5T2XB.js → ZDD5BPHD.js} +1 -1
- package/dist/cdn/{GOBF5ORA.js → ZLOFPY73.js} +1 -1
- package/dist/cdn/{SIGHPEZ7.js → ZM5MQRTG.js} +1 -1
- package/dist/cdn/{IA4HJQWG.js → ZY6HQZ6P.js} +1 -1
- package/dist/cdn/index.js +1 -1
- package/dist/chunks/runtime.js +4 -4
- package/dist/components/calcite-accordion/customElement.d.ts +4 -6
- package/dist/components/calcite-action-bar/customElement.d.ts +20 -6
- package/dist/components/calcite-action-bar/customElement.js +147 -15
- package/dist/components/calcite-action-group/customElement.d.ts +8 -11
- package/dist/components/calcite-action-menu/customElement.d.ts +3 -3
- package/dist/components/calcite-action-pad/customElement.d.ts +3 -3
- package/dist/components/calcite-autocomplete/customElement.d.ts +3 -3
- package/dist/components/calcite-block/customElement.d.ts +3 -3
- package/dist/components/calcite-block-section/customElement.d.ts +3 -4
- package/dist/components/calcite-chip-group/customElement.d.ts +5 -8
- package/dist/components/calcite-combobox/customElement.d.ts +15 -21
- package/dist/components/calcite-dialog/customElement.d.ts +10 -10
- package/dist/components/calcite-dropdown/customElement.d.ts +3 -3
- package/dist/components/calcite-dropdown-group/customElement.d.ts +4 -6
- package/dist/components/calcite-flow-item/customElement.d.ts +3 -3
- package/dist/components/calcite-focus-trap/customElement.d.ts +6 -6
- package/dist/components/calcite-input-date-picker/customElement.d.ts +3 -3
- package/dist/components/calcite-input-time-picker/customElement.d.ts +7 -7
- package/dist/components/calcite-input-time-zone/customElement.d.ts +7 -7
- package/dist/components/calcite-label/customElement.d.ts +3 -1
- package/dist/components/calcite-list/customElement.d.ts +15 -24
- package/dist/components/calcite-meter/customElement.d.ts +4 -3
- package/dist/components/calcite-notice/customElement.d.ts +3 -1
- package/dist/components/calcite-panel/customElement.d.ts +3 -3
- package/dist/components/calcite-popover/customElement.d.ts +9 -9
- package/dist/components/calcite-segmented-control/customElement.d.ts +3 -1
- package/dist/components/calcite-select/customElement.d.ts +3 -1
- package/dist/components/calcite-sheet/customElement.d.ts +6 -6
- package/dist/components/calcite-shell/customElement.js +75 -5
- package/dist/components/calcite-shell-panel/customElement.d.ts +16 -11
- package/dist/components/calcite-shell-panel/customElement.js +75 -12
- package/dist/components/calcite-sort-handle/customElement.d.ts +3 -3
- package/dist/components/calcite-split-button/customElement.d.ts +6 -4
- package/dist/components/calcite-swatch-group/customElement.d.ts +5 -8
- package/dist/components/calcite-table/customElement.d.ts +4 -6
- package/dist/components/calcite-table-cell/customElement.d.ts +5 -4
- package/dist/components/calcite-table-row/customElement.d.ts +5 -4
- package/dist/components/calcite-tile-group/customElement.d.ts +9 -9
- package/dist/components/calcite-time-picker/customElement.d.ts +4 -4
- package/dist/components/calcite-tooltip/customElement.d.ts +3 -3
- package/dist/components/calcite-tree/customElement.d.ts +9 -15
- package/dist/controllers/useTime.d.ts +4 -4
- package/dist/docs/api.json +1 -1
- package/dist/docs/docs.json +1 -1
- package/dist/docs/vscode.html-custom-data.json +1 -1
- package/dist/docs/web-types.json +1 -1
- package/dist/loader.js +2 -2
- package/dist/types/lumina.d.ts +2 -2
- package/dist/types/preact.d.ts +2 -2
- package/dist/types/react.d.ts +2 -2
- package/dist/types/stencil.d.ts +2 -2
- package/package.json +2 -2
- package/dist/cdn/CXNZFM4C.js +0 -2
- package/dist/cdn/PCWHJTFI.js +0 -2
- package/dist/cdn/XKRS7NPC.js +0 -2
|
@@ -55,11 +55,11 @@ export abstract class InputTimePicker extends LitElement {
|
|
|
55
55
|
/** Specifies the `id` of the component's associated form. When not set, the component is associated with its ancestor form element, if one exists. */
|
|
56
56
|
accessor form: string | undefined;
|
|
57
57
|
/**
|
|
58
|
-
* Specifies the component's hour format
|
|
58
|
+
* Specifies the component's hour format.
|
|
59
59
|
*
|
|
60
|
-
* `"user"` displays the user's locale format
|
|
61
|
-
* `"12"` displays a 12-hour format
|
|
62
|
-
* `"24"` displays a 24-hour format.
|
|
60
|
+
* - `"user"` displays the user's locale format.
|
|
61
|
+
* - `"12"` displays a 12-hour format.
|
|
62
|
+
* - `"24"` displays a 24-hour format.
|
|
63
63
|
*
|
|
64
64
|
* @default "user"
|
|
65
65
|
*/
|
|
@@ -118,11 +118,11 @@ export abstract class InputTimePicker extends LitElement {
|
|
|
118
118
|
*/
|
|
119
119
|
accessor open: boolean;
|
|
120
120
|
/**
|
|
121
|
-
* Specifies the type of positioning to use for overlaid content
|
|
121
|
+
* Specifies the type of positioning to use for overlaid content.
|
|
122
122
|
*
|
|
123
|
-
* `"absolute"` works for most cases - positioning the component inside of overflowing parent containers, which affects the container's layout
|
|
123
|
+
* - `"absolute"` works for most cases - positioning the component inside of overflowing parent containers, which affects the container's layout.
|
|
124
124
|
*
|
|
125
|
-
* `"fixed"` is used to escape an overflowing parent container, or when the reference element's `position` CSS property is `"fixed"`.
|
|
125
|
+
* - `"fixed"` is used to escape an overflowing parent container, or when the reference element's `position` CSS property is `"fixed"`.
|
|
126
126
|
*
|
|
127
127
|
* @default "absolute"
|
|
128
128
|
*/
|
|
@@ -660,11 +660,11 @@ export abstract class InputTimeZone extends LitElement {
|
|
|
660
660
|
/** Specifies the name of the component. Required to pass the component's `value` on form submission. */
|
|
661
661
|
accessor name: string | undefined;
|
|
662
662
|
/**
|
|
663
|
-
* When `mode` is `"offset"`, specifies how the offset will be displayed
|
|
663
|
+
* When `mode` is `"offset"`, specifies how the offset will be displayed.
|
|
664
664
|
*
|
|
665
|
-
* `"user"` uses `UTC` or `GMT` depending on the user's locale
|
|
666
|
-
* `"gmt"` always uses `GMT
|
|
667
|
-
* `"utc"` always uses `UTC`.
|
|
665
|
+
* - `"user"` uses `UTC` or `GMT` depending on the user's locale.
|
|
666
|
+
* - `"gmt"` always uses `GMT`.
|
|
667
|
+
* - `"utc"` always uses `UTC`.
|
|
668
668
|
*
|
|
669
669
|
* @default "user"
|
|
670
670
|
*/
|
|
@@ -676,11 +676,11 @@ export abstract class InputTimeZone extends LitElement {
|
|
|
676
676
|
*/
|
|
677
677
|
accessor open: boolean;
|
|
678
678
|
/**
|
|
679
|
-
* Specifies the type of positioning to use for overlaid content
|
|
679
|
+
* Specifies the type of positioning to use for overlaid content.
|
|
680
680
|
*
|
|
681
|
-
* `"absolute"` works for most cases - positioning the component inside of overflowing parent containers, which affects the container's layout
|
|
681
|
+
* - `"absolute"` works for most cases - positioning the component inside of overflowing parent containers, which affects the container's layout.
|
|
682
682
|
*
|
|
683
|
-
* `"fixed"` is used to escape an overflowing parent container, or when the reference element's `position` CSS property is `"fixed"`.
|
|
683
|
+
* - `"fixed"` is used to escape an overflowing parent container, or when the reference element's `position` CSS property is `"fixed"`.
|
|
684
684
|
*
|
|
685
685
|
* @default "absolute"
|
|
686
686
|
*/
|
|
@@ -17,7 +17,9 @@ export abstract class Label extends LitElement {
|
|
|
17
17
|
/** Specifies the `id` of the component the label is bound to. Use when the component the label is bound to does not reside within the component. */
|
|
18
18
|
accessor for: string | undefined;
|
|
19
19
|
/**
|
|
20
|
-
* Defines the component's layout in relation to the slotted component. Use `"inline"` positions to wrap the label and slotted component on the same line.
|
|
20
|
+
* Defines the component's layout in relation to the slotted component. Use `"inline"` positions to wrap the label and slotted component on the same line.
|
|
21
|
+
*
|
|
22
|
+
* [Deprecated] The `"default"` value is deprecated in v3.3.0, removal target v6.0.0 - use `"block"` instead.
|
|
21
23
|
*
|
|
22
24
|
* @default "default"
|
|
23
25
|
*/
|
|
@@ -29,11 +29,10 @@ export abstract class List extends LitElement {
|
|
|
29
29
|
*/
|
|
30
30
|
accessor disabled: boolean;
|
|
31
31
|
/**
|
|
32
|
-
* Specifies the nesting behavior of `calcite-list-item`s
|
|
32
|
+
* Specifies the nesting behavior of `calcite-list-item`s.
|
|
33
33
|
*
|
|
34
|
-
* `"flat"` displays `calcite-list-item`s in a uniform list
|
|
35
|
-
*
|
|
36
|
-
* `"nested"` displays `calcite-list-item`s under their parent element.
|
|
34
|
+
* - `"flat"` displays `calcite-list-item`s in a uniform list.
|
|
35
|
+
* - `"nested"` displays `calcite-list-item`s under their parent element.
|
|
37
36
|
*
|
|
38
37
|
* The parent component's behavior should follow throughout its child elements.
|
|
39
38
|
*
|
|
@@ -85,13 +84,10 @@ export abstract class List extends LitElement {
|
|
|
85
84
|
*/
|
|
86
85
|
accessor group: string | undefined;
|
|
87
86
|
/**
|
|
88
|
-
* Specifies the interaction mode of the component
|
|
89
|
-
*
|
|
90
|
-
* `"interactive"` allows interaction styling and pointer changes on hover,
|
|
87
|
+
* Specifies the interaction mode of the component.
|
|
91
88
|
*
|
|
92
|
-
* `"
|
|
93
|
-
*
|
|
94
|
-
* the `"static"` value should only be used when `selectionMode` is `"none"`.
|
|
89
|
+
* - `"interactive"` allows interaction styling and pointer changes on hover.
|
|
90
|
+
* - `"static"` does not allow interaction styling and pointer changes on hover. Should only be used when `selectionMode` is `"none"`.
|
|
95
91
|
*
|
|
96
92
|
* @default "interactive"
|
|
97
93
|
*/
|
|
@@ -130,27 +126,22 @@ export abstract class List extends LitElement {
|
|
|
130
126
|
/** The currently selected items. */
|
|
131
127
|
get selectedItems(): ListItem[];
|
|
132
128
|
/**
|
|
133
|
-
* Specifies the selection appearance
|
|
134
|
-
*
|
|
135
|
-
* `"icon"` displays a checkmark or dot,
|
|
129
|
+
* Specifies the selection appearance.
|
|
136
130
|
*
|
|
137
|
-
*
|
|
138
|
-
*
|
|
139
|
-
* `"
|
|
131
|
+
* - `"icon"` displays a checkmark or dot.
|
|
132
|
+
* - `"highlight"` displays background highlight.
|
|
133
|
+
* - `"border"` displays a border. [Deprecated] in v5.0.0, removal target v6.0.0 - use `"highlight"` instead.
|
|
140
134
|
*
|
|
141
135
|
* @default "icon"
|
|
142
136
|
*/
|
|
143
137
|
accessor selectionAppearance: Extract<"icon" | "border" | "highlight", SelectionAppearance>;
|
|
144
138
|
/**
|
|
145
|
-
* Specifies the selection mode of the component
|
|
146
|
-
*
|
|
147
|
-
* `"multiple"` allows any number of selections,
|
|
148
|
-
*
|
|
149
|
-
* `"single"` allows only one selection,
|
|
150
|
-
*
|
|
151
|
-
* `"single-persist"` allows one selection and prevents de-selection, and
|
|
139
|
+
* Specifies the selection mode of the component.
|
|
152
140
|
*
|
|
153
|
-
* `"
|
|
141
|
+
* - `"multiple"` allows any number of selections.
|
|
142
|
+
* - `"single"` allows only one selection.
|
|
143
|
+
* - `"single-persist"` allows one selection and prevents de-selection.
|
|
144
|
+
* - `"none"` does not allow any selections.
|
|
154
145
|
*
|
|
155
146
|
* @default "none"
|
|
156
147
|
*/
|
|
@@ -28,9 +28,10 @@ export abstract class Meter extends LitElement {
|
|
|
28
28
|
*/
|
|
29
29
|
accessor disabled: boolean;
|
|
30
30
|
/**
|
|
31
|
-
* Specifies the component's display
|
|
32
|
-
*
|
|
33
|
-
* `"
|
|
31
|
+
* Specifies the component's display.
|
|
32
|
+
*
|
|
33
|
+
* - `"single"` displays a single color.
|
|
34
|
+
* - `"range"` displays a range of colors based on provided `low`, `high`, `min` or `max` values.
|
|
34
35
|
*
|
|
35
36
|
* @default "range"
|
|
36
37
|
*/
|
|
@@ -73,7 +73,9 @@ export abstract class Notice extends LitElement {
|
|
|
73
73
|
*/
|
|
74
74
|
accessor scale: Scale;
|
|
75
75
|
/**
|
|
76
|
-
* Specifies the width of the component.
|
|
76
|
+
* Specifies the width of the component.
|
|
77
|
+
*
|
|
78
|
+
* [Deprecated] The `"half"` value is deprecated in v3.0.0, removal target v6.0.0 - use `"full"` instead.
|
|
77
79
|
*
|
|
78
80
|
* @default "auto"
|
|
79
81
|
*/
|
|
@@ -129,11 +129,11 @@ export abstract class Panel extends LitElement {
|
|
|
129
129
|
expand?: string | undefined;
|
|
130
130
|
};
|
|
131
131
|
/**
|
|
132
|
-
* Specifies the type of positioning to use for overlaid content
|
|
132
|
+
* Specifies the type of positioning to use for overlaid content.
|
|
133
133
|
*
|
|
134
|
-
* `"absolute"` works for most cases - positioning the component inside of overflowing parent containers, which affects the container's layout
|
|
134
|
+
* - `"absolute"` works for most cases - positioning the component inside of overflowing parent containers, which affects the container's layout.
|
|
135
135
|
*
|
|
136
|
-
* `"fixed"` is used to escape an overflowing parent container, or when the reference element's `position` CSS property is `"fixed"`.
|
|
136
|
+
* - `"fixed"` is used to escape an overflowing parent container, or when the reference element's `position` CSS property is `"fixed"`.
|
|
137
137
|
*
|
|
138
138
|
* @default "absolute"
|
|
139
139
|
*/
|
|
@@ -41,13 +41,13 @@ export abstract class Popover extends LitElement {
|
|
|
41
41
|
*/
|
|
42
42
|
accessor focusTrapDisabled: boolean;
|
|
43
43
|
/**
|
|
44
|
-
* Specifies custom focus trap configuration on the component
|
|
44
|
+
* Specifies custom focus trap configuration on the component.
|
|
45
45
|
*
|
|
46
|
-
* `"allowOutsideClick`" allows outside clicks
|
|
47
|
-
* `"initialFocus"` enables initial focus
|
|
48
|
-
* `"returnFocusOnDeactivate"` returns focus when not active
|
|
49
|
-
* `"extraContainers"` specifies additional focusable elements external to the trap, such as 3rd-party components appending elements to the document body
|
|
50
|
-
* `"setReturnFocus"` customizes the element to which focus is returned when the trap is deactivated. Return `false` to prevent focus return, or `undefined` to use the default behavior (returning focus to the element focused before activation).
|
|
46
|
+
* - `"allowOutsideClick`" allows outside clicks.
|
|
47
|
+
* - `"initialFocus"` enables initial focus.
|
|
48
|
+
* - `"returnFocusOnDeactivate"` returns focus when not active.
|
|
49
|
+
* - `"extraContainers"` specifies additional focusable elements external to the trap, such as 3rd-party components appending elements to the document body.
|
|
50
|
+
* - `"setReturnFocus"` customizes the element to which focus is returned when the trap is deactivated. Return `false` to prevent focus return, or `undefined` to use the default behavior (returning focus to the element focused before activation).
|
|
51
51
|
*/
|
|
52
52
|
accessor focusTrapOptions: Partial<FocusTrapOptions> | undefined;
|
|
53
53
|
/** Specifies the component's heading text. */
|
|
@@ -81,11 +81,11 @@ export abstract class Popover extends LitElement {
|
|
|
81
81
|
*/
|
|
82
82
|
accessor open: boolean;
|
|
83
83
|
/**
|
|
84
|
-
* Specifies the type of positioning to use for overlaid content
|
|
84
|
+
* Specifies the type of positioning to use for overlaid content.
|
|
85
85
|
*
|
|
86
|
-
* `"absolute"` works for most cases - positioning the component inside of overflowing parent containers, which affects the container's layout
|
|
86
|
+
* - `"absolute"` works for most cases - positioning the component inside of overflowing parent containers, which affects the container's layout.
|
|
87
87
|
*
|
|
88
|
-
* `"fixed"` is used to escape an overflowing parent container, or when the reference element's `position` CSS property is `"fixed"`.
|
|
88
|
+
* - `"fixed"` is used to escape an overflowing parent container, or when the reference element's `position` CSS property is `"fixed"`.
|
|
89
89
|
*
|
|
90
90
|
* @default "absolute"
|
|
91
91
|
*/
|
|
@@ -75,7 +75,9 @@ export abstract class SegmentedControl extends LitElement {
|
|
|
75
75
|
/** The component's `selectedItem` value. */
|
|
76
76
|
accessor value: string;
|
|
77
77
|
/**
|
|
78
|
-
* Specifies the width of the component.
|
|
78
|
+
* Specifies the width of the component.
|
|
79
|
+
*
|
|
80
|
+
* [Deprecated] The `"half"` value is deprecated in v3.0.0, removal target v6.0.0 - use `"full"` instead.
|
|
79
81
|
*
|
|
80
82
|
* @default "auto"
|
|
81
83
|
*/
|
|
@@ -75,7 +75,9 @@ export abstract class Select extends LitElement {
|
|
|
75
75
|
/** The component's `selectedOption` value. */
|
|
76
76
|
accessor value: string;
|
|
77
77
|
/**
|
|
78
|
-
* Specifies the width of the component.
|
|
78
|
+
* Specifies the width of the component.
|
|
79
|
+
*
|
|
80
|
+
* [Deprecated] The `"half"` value is deprecated in v3.0.0, removal target v6.0.0 - use `"full"` instead.
|
|
79
81
|
*
|
|
80
82
|
* @default "auto"
|
|
81
83
|
*/
|
|
@@ -44,13 +44,13 @@ export abstract class Sheet extends LitElement {
|
|
|
44
44
|
*/
|
|
45
45
|
accessor focusTrapDisabled: boolean;
|
|
46
46
|
/**
|
|
47
|
-
* Specifies custom focus trap configuration on the component
|
|
47
|
+
* Specifies custom focus trap configuration on the component.
|
|
48
48
|
*
|
|
49
|
-
* `"allowOutsideClick"` allows outside clicks
|
|
50
|
-
* `"initialFocus"` enables initial focus
|
|
51
|
-
* `"returnFocusOnDeactivate"` returns focus when not active
|
|
52
|
-
* `"extraContainers"` specifies additional focusable elements external to the trap, such as 3rd-party components appending elements to the document body
|
|
53
|
-
* `"setReturnFocus"` customizes the element to which focus is returned when the trap is deactivated. Return `false` to prevent focus return, or `undefined` to use the default behavior (returning focus to the element focused before activation).
|
|
49
|
+
* - `"allowOutsideClick"` allows outside clicks.
|
|
50
|
+
* - `"initialFocus"` enables initial focus.
|
|
51
|
+
* - `"returnFocusOnDeactivate"` returns focus when not active.
|
|
52
|
+
* - `"extraContainers"` specifies additional focusable elements external to the trap, such as 3rd-party components appending elements to the document body.
|
|
53
|
+
* - `"setReturnFocus"` customizes the element to which focus is returned when the trap is deactivated. Return `false` to prevent focus return, or `undefined` to use the default behavior (returning focus to the element focused before activation).
|
|
54
54
|
*/
|
|
55
55
|
accessor focusTrapOptions: Partial<FocusTrapOptions> | undefined;
|
|
56
56
|
/** Specifies the component's height. */
|
|
@@ -3,7 +3,8 @@ import { c as customElement } from "../../chunks/runtime.js";
|
|
|
3
3
|
import { keyed } from "lit/directives/keyed.js";
|
|
4
4
|
import { css, html } from "lit";
|
|
5
5
|
import { LitElement, safeClassMap } from "@arcgis/lumina";
|
|
6
|
-
import {
|
|
6
|
+
import { createRef, ref } from "lit/directives/ref.js";
|
|
7
|
+
import { s as slotChangeHasAssignedElement, a as slotChangeGetAssignedElements, g as getStylePixelValue } from "../../chunks/dom.js";
|
|
7
8
|
const styles = css`:host{box-sizing:border-box;background-color:var(--calcite-color-foreground-1);color:var(--calcite-color-text-2);font-size:var(--calcite-font-size--1)}:host *{box-sizing:border-box}:host{position:absolute;inset:0;display:flex;block-size:100%;inline-size:100%;flex-direction:column;overflow:hidden;border-radius:var(--calcite-shell-corner-radius);box-shadow:var(--calcite-shell-shadow)}.main{position:relative;display:flex;block-size:100%;inline-size:100%;flex:1 1 auto;flex-direction:row;justify-content:space-between;overflow:hidden}.content{display:flex;block-size:100%;inline-size:100%;flex-direction:column;flex-wrap:nowrap;overflow:auto;justify-content:space-between}.content ::slotted(calcite-panel),.content ::slotted(calcite-flow){flex:1 1 auto;align-self:stretch;max-block-size:unset}.content--behind{position:absolute;inset:0;border-width:0px;z-index:calc(var(--calcite-z-index) - 1);display:initial}.content--non-interactive{pointer-events:none;display:flex;block-size:100%;inline-size:100%;flex-direction:column;flex-wrap:nowrap}::slotted(calcite-shell-panel){inline-size:unset}::slotted(.header .heading){font-size:var(--calcite-font-size-relative-sm);line-height:var(--calcite-font-line-height-relative-snug);font-weight:var(--calcite-font-weight-normal)}slot[name=panel-start]::slotted(calcite-shell-panel),slot[name=panel-end]::slotted(calcite-shell-panel){position:relative;z-index:calc(var(--calcite-z-index) + 1)}slot[name=panel-end]::slotted(calcite-shell-panel){margin-inline-start:auto}::slotted(calcite-panel),::slotted(calcite-flow){border-width:var(--calcite-border-width-sm);border-color:var(--calcite-shell-border-color, var(--calcite-color-border-3));border-inline-start-width:var(--calcite-border-width-none);border-inline-end-width:var(--calcite-border-width-none);border-style:solid}slot[name=panel-top]::slotted(calcite-shell-panel:not([display-mode^=float])),slot[name=panel-bottom]::slotted(calcite-shell-panel:not([display-mode^=float])){border-color:var(--calcite-shell-border-color, var(--calcite-color-border-3));border-inline-start-width:var(--calcite-border-width-sm);border-inline-end-width:var(--calcite-border-width-sm)}.center-content{display:flex;flex-direction:column;justify-content:space-between;block-size:100%;inline-size:100%;min-inline-size:0}.content-bottom{justify-content:flex-end}::slotted(calcite-shell-panel){flex:none;align-self:stretch}::slotted(calcite-tip-manager){position:absolute;z-index:var(--calcite-z-index-toast);box-sizing:border-box}@keyframes in-up{0%{opacity:0;transform:translate3D(0,5px,0)}to{opacity:1;transform:translateZ(0)}}::slotted(calcite-tip-manager){animation:in-up var(--calcite-internal-animation-timing-slow) ease-in-out;border-radius:.25rem;--tw-shadow: 0 6px 20px -4px rgba(0, 0, 0, .1), 0 4px 12px -2px rgba(0, 0, 0, .08);--tw-shadow-colored: 0 6px 20px -4px var(--tw-shadow-color), 0 4px 12px -2px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow);inset-block-end:.5rem;inset-inline:var(--calcite-shell-tip-spacing, 26vw)}slot[name=panel-bottom]::slotted(calcite-shell-panel){margin-block-start:auto}slot[name=panel-top]::slotted(calcite-shell-panel){margin-block-end:auto}.position-wrapper{position:absolute;pointer-events:none;inset:0}.main.has-resizable-panel-top ::slotted(calcite-panel){border-block-start:none}.main.has-resizable-panel-bottom ::slotted(calcite-panel){border-block-end:none}.main.has-action-bar-position-panel ::slotted(calcite-panel){border:0}:host([hidden]){display:none}[hidden]{display:none}`;
|
|
8
9
|
const CSS = {
|
|
9
10
|
main: "main",
|
|
@@ -33,6 +34,11 @@ const panelSlots = ["panel-start", "panel-end", "panel-top", "panel-bottom"];
|
|
|
33
34
|
class Shell extends LitElement {
|
|
34
35
|
constructor() {
|
|
35
36
|
super();
|
|
37
|
+
this.defaultSlotRef = createRef();
|
|
38
|
+
this.panelBottomSlotRef = createRef();
|
|
39
|
+
this.panelEndSlotRef = createRef();
|
|
40
|
+
this.panelStartSlotRef = createRef();
|
|
41
|
+
this.panelTopSlotRef = createRef();
|
|
36
42
|
this.panelSlotState = {
|
|
37
43
|
"panel-start": { elements: [], resizable: false },
|
|
38
44
|
"panel-end": { elements: [], resizable: false },
|
|
@@ -108,9 +114,70 @@ class Shell extends LitElement {
|
|
|
108
114
|
el.embedded = true;
|
|
109
115
|
});
|
|
110
116
|
}
|
|
117
|
+
configurePanels(panels, layout, position) {
|
|
118
|
+
panels.forEach((panel) => {
|
|
119
|
+
const sizingPanel = panel;
|
|
120
|
+
panel.layout = layout;
|
|
121
|
+
panel.position = position;
|
|
122
|
+
sizingPanel.shellSizingDataProvider = (axis) => this.getShellPanelSizingData(panel, axis);
|
|
123
|
+
});
|
|
124
|
+
}
|
|
125
|
+
getDefaultSlotMinSize(axis) {
|
|
126
|
+
return this.defaultSlotRef.value?.assignedElements({ flatten: true }).reduce((total, element) => {
|
|
127
|
+
const computedStyle = window.getComputedStyle(element);
|
|
128
|
+
return axis === "inline" ? total + getStylePixelValue(computedStyle.borderInlineStartWidth) + getStylePixelValue(computedStyle.borderInlineEndWidth) : total + getStylePixelValue(computedStyle.borderBlockStartWidth) + getStylePixelValue(computedStyle.borderBlockEndWidth);
|
|
129
|
+
}, 0) ?? 0;
|
|
130
|
+
}
|
|
131
|
+
getDefaultSlotBounds() {
|
|
132
|
+
const defaultSlotElements = this.defaultSlotRef.value?.assignedElements({ flatten: true }) ?? [];
|
|
133
|
+
if (!defaultSlotElements.length) {
|
|
134
|
+
return null;
|
|
135
|
+
}
|
|
136
|
+
return defaultSlotElements.reduce((bounds, element) => {
|
|
137
|
+
const rect = element.getBoundingClientRect();
|
|
138
|
+
return bounds ? {
|
|
139
|
+
bottom: Math.max(bounds.bottom, rect.bottom),
|
|
140
|
+
left: Math.min(bounds.left, rect.left),
|
|
141
|
+
right: Math.max(bounds.right, rect.right),
|
|
142
|
+
top: Math.min(bounds.top, rect.top)
|
|
143
|
+
} : {
|
|
144
|
+
bottom: rect.bottom,
|
|
145
|
+
left: rect.left,
|
|
146
|
+
right: rect.right,
|
|
147
|
+
top: rect.top
|
|
148
|
+
};
|
|
149
|
+
}, null);
|
|
150
|
+
}
|
|
151
|
+
getShellPanelSizingData(panel, axis) {
|
|
152
|
+
const panelLayoutContainer = panel.assignedSlot?.parentElement;
|
|
153
|
+
if (!panelLayoutContainer) {
|
|
154
|
+
return null;
|
|
155
|
+
}
|
|
156
|
+
const containerRect = panelLayoutContainer.getBoundingClientRect();
|
|
157
|
+
const defaultSlotRect = this.getDefaultSlotBounds();
|
|
158
|
+
if (!defaultSlotRect) {
|
|
159
|
+
return {
|
|
160
|
+
availableSize: axis === "inline" ? containerRect.width : containerRect.height
|
|
161
|
+
};
|
|
162
|
+
}
|
|
163
|
+
const defaultSlotMinSize = this.getDefaultSlotMinSize(axis);
|
|
164
|
+
const isRTL = window.getComputedStyle(this).direction === "rtl";
|
|
165
|
+
let availableOccupiedSize;
|
|
166
|
+
if (axis === "inline") {
|
|
167
|
+
const isStart = panel.position === "start";
|
|
168
|
+
availableOccupiedSize = isRTL ? isStart ? containerRect.right - defaultSlotRect.left : defaultSlotRect.right - containerRect.left : isStart ? defaultSlotRect.right - containerRect.left : containerRect.right - defaultSlotRect.left;
|
|
169
|
+
} else {
|
|
170
|
+
availableOccupiedSize = panel.position === "start" ? defaultSlotRect.bottom - containerRect.top : containerRect.bottom - defaultSlotRect.top;
|
|
171
|
+
}
|
|
172
|
+
const availableSize = Math.max(Math.floor(availableOccupiedSize) - Math.ceil(defaultSlotMinSize), 0);
|
|
173
|
+
return {
|
|
174
|
+
availableSize
|
|
175
|
+
};
|
|
176
|
+
}
|
|
111
177
|
handlePanelTopChange(event) {
|
|
112
178
|
const panelElements = slotChangeGetAssignedElements(event).filter((el) => el?.matches("calcite-shell-panel"));
|
|
113
179
|
this.hasPanelTop = slotChangeHasAssignedElement(event);
|
|
180
|
+
this.configurePanels(panelElements, "horizontal", "start");
|
|
114
181
|
panelElements.forEach((el) => {
|
|
115
182
|
el.layout = "horizontal";
|
|
116
183
|
el.position = "start";
|
|
@@ -120,6 +187,7 @@ class Shell extends LitElement {
|
|
|
120
187
|
handlePanelBottomChange(event) {
|
|
121
188
|
const panelElements = slotChangeGetAssignedElements(event).filter((el) => el?.matches("calcite-shell-panel"));
|
|
122
189
|
this.hasPanelBottom = slotChangeHasAssignedElement(event);
|
|
190
|
+
this.configurePanels(panelElements, "horizontal", "end");
|
|
123
191
|
panelElements.forEach((el) => {
|
|
124
192
|
el.layout = "horizontal";
|
|
125
193
|
el.position = "end";
|
|
@@ -128,6 +196,7 @@ class Shell extends LitElement {
|
|
|
128
196
|
}
|
|
129
197
|
handlePanelStartChange(event) {
|
|
130
198
|
const panelElements = slotChangeGetAssignedElements(event).filter((el) => el?.matches("calcite-shell-panel"));
|
|
199
|
+
this.configurePanels(panelElements, "vertical", "start");
|
|
131
200
|
panelElements.forEach((el) => {
|
|
132
201
|
el.layout = "vertical";
|
|
133
202
|
el.position = "start";
|
|
@@ -136,6 +205,7 @@ class Shell extends LitElement {
|
|
|
136
205
|
}
|
|
137
206
|
handlePanelEndChange(event) {
|
|
138
207
|
const panelElements = slotChangeGetAssignedElements(event).filter((el) => el?.matches("calcite-shell-panel"));
|
|
208
|
+
this.configurePanels(panelElements, "vertical", "end");
|
|
139
209
|
panelElements.forEach((el) => {
|
|
140
210
|
el.layout = "vertical";
|
|
141
211
|
el.position = "end";
|
|
@@ -180,10 +250,10 @@ class Shell extends LitElement {
|
|
|
180
250
|
}
|
|
181
251
|
renderContent() {
|
|
182
252
|
const { panelIsResizing } = this;
|
|
183
|
-
const defaultSlotNode = keyed("default-slot", html`<slot></slot>`);
|
|
253
|
+
const defaultSlotNode = keyed("default-slot", html`<slot ${ref(this.defaultSlotRef)}></slot>`);
|
|
184
254
|
const defaultSlotContainerNode = panelIsResizing ? html`<div class=${safeClassMap(CSS.contentNonInteractive)}>${defaultSlotNode}</div>` : defaultSlotNode;
|
|
185
|
-
const panelBottomSlotNode = keyed("panel-bottom-slot", html`<slot name=${SLOTS.panelBottom} @slotchange=${this.handlePanelBottomChange}></slot>`);
|
|
186
|
-
const panelTopSlotNode = keyed("panel-top-slot", html`<slot name=${SLOTS.panelTop} @slotchange=${this.handlePanelTopChange}></slot>`);
|
|
255
|
+
const panelBottomSlotNode = keyed("panel-bottom-slot", html`<slot name=${SLOTS.panelBottom} @slotchange=${this.handlePanelBottomChange} ${ref(this.panelBottomSlotRef)}></slot>`);
|
|
256
|
+
const panelTopSlotNode = keyed("panel-top-slot", html`<slot name=${SLOTS.panelTop} @slotchange=${this.handlePanelTopChange} ${ref(this.panelTopSlotRef)}></slot>`);
|
|
187
257
|
const contentContainerKey = "content-container";
|
|
188
258
|
const content = this.contentBehind ? [
|
|
189
259
|
keyed(contentContainerKey, html`<div class=${safeClassMap({
|
|
@@ -205,7 +275,7 @@ class Shell extends LitElement {
|
|
|
205
275
|
[CSS.hasActionBarPositionPanel]: this.hasActionBarPositionPanel,
|
|
206
276
|
[CSS.hasResizablePanelBottom]: this.hasResizablePanelBottom,
|
|
207
277
|
[CSS.hasResizablePanelTop]: this.hasResizablePanelTop
|
|
208
|
-
})}><slot name=${SLOTS.panelStart} @slotchange=${this.handlePanelStartChange}></slot>${this.renderContent()}<slot name=${SLOTS.panelEnd} @slotchange=${this.handlePanelEndChange}></slot></div>`;
|
|
278
|
+
})}><slot name=${SLOTS.panelStart} @slotchange=${this.handlePanelStartChange} ${ref(this.panelStartSlotRef)}></slot>${this.renderContent()}<slot name=${SLOTS.panelEnd} @slotchange=${this.handlePanelEndChange} ${ref(this.panelEndSlotRef)}></slot></div>`;
|
|
209
279
|
}
|
|
210
280
|
renderPositionedSlots() {
|
|
211
281
|
return html`<div class=${safeClassMap(CSS.positionedSlotWrapper)}>${this.renderAlerts()}${this.renderDialogs()}${this.renderSheets()}</div>`;
|
|
@@ -29,17 +29,13 @@ export abstract class ShellPanel extends LitElement {
|
|
|
29
29
|
*/
|
|
30
30
|
accessor collapsed: boolean;
|
|
31
31
|
/**
|
|
32
|
-
* Specifies the component's display mode
|
|
32
|
+
* Specifies the component's display mode.
|
|
33
33
|
*
|
|
34
|
-
* `"dock"` displays at full height adjacent to center content
|
|
35
|
-
*
|
|
36
|
-
* `"
|
|
37
|
-
*
|
|
38
|
-
* `"float"`
|
|
39
|
-
*
|
|
40
|
-
* `"float-content"` does not display at full height with content separately detached from `calcite-action-bar` on top of center content.
|
|
41
|
-
*
|
|
42
|
-
* `"float-all"` detaches the `calcite-panel` and `calcite-action-bar` on top of center content.
|
|
34
|
+
* - `"dock"` displays at full height adjacent to center content.
|
|
35
|
+
* - `"overlay"` displays at full height on top of center content.
|
|
36
|
+
* - `"float-content"` does not display at full height with content separately detached from `calcite-action-bar` on top of center content.
|
|
37
|
+
* - `"float-all"` detaches the `calcite-panel` and `calcite-action-bar` on top of center content.
|
|
38
|
+
* - `"float"` does not display at full height with content separately detached from `calcite-action-bar` on top of center content. [Deprecated] in v2.11.0, removal target v6.0.0 - use `"float-content"` instead.
|
|
43
39
|
*
|
|
44
40
|
* @default "dock"
|
|
45
41
|
*/
|
|
@@ -78,6 +74,8 @@ export abstract class ShellPanel extends LitElement {
|
|
|
78
74
|
* @default false
|
|
79
75
|
*/
|
|
80
76
|
accessor resizable: boolean;
|
|
77
|
+
/** @internal */
|
|
78
|
+
accessor shellSizingDataProvider: ShellSizingDataProvider | undefined;
|
|
81
79
|
/** Specifies the component's width. */
|
|
82
80
|
accessor width: Extract<Width, Scale> | undefined;
|
|
83
81
|
/**
|
|
@@ -107,4 +105,11 @@ export abstract class ShellPanel extends LitElement {
|
|
|
107
105
|
calciteShellPanelCollapse: ShellPanel["calciteShellPanelCollapse"]["detail"];
|
|
108
106
|
calciteShellPanelExpand: ShellPanel["calciteShellPanelExpand"]["detail"];
|
|
109
107
|
};
|
|
110
|
-
}
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
/** @param axis */
|
|
111
|
+
export type ShellSizingDataProvider = (axis: "inline" | "block") => ShellPanelSizingData | null;
|
|
112
|
+
|
|
113
|
+
export type ShellPanelSizingData = {
|
|
114
|
+
availableSize: number;
|
|
115
|
+
};
|
|
@@ -40,6 +40,7 @@ class ShellPanel extends LitElement {
|
|
|
40
40
|
super();
|
|
41
41
|
this.direction = useDirection();
|
|
42
42
|
this.resizeHandleRef = createRef();
|
|
43
|
+
this.actionBars = [];
|
|
43
44
|
this.actionBarContainerResizeObserver = createObserver("resize", () => this.updateActionBarSize());
|
|
44
45
|
this.handleActionBarExpand = () => {
|
|
45
46
|
this.isActionBarExpanded = true;
|
|
@@ -48,12 +49,13 @@ class ShellPanel extends LitElement {
|
|
|
48
49
|
this.isActionBarExpanded = false;
|
|
49
50
|
};
|
|
50
51
|
this.contentRef = createRef();
|
|
52
|
+
this.containerRef = createRef();
|
|
51
53
|
this.messages = useT9n();
|
|
52
54
|
this.sizeOverride = useSizeOverride({
|
|
53
55
|
targetElement: this.contentRef,
|
|
54
56
|
getBounds: () => ({
|
|
55
|
-
inline: { min: this.resizeValues.minInlineSize, max: this.
|
|
56
|
-
block: { min: this.resizeValues.minBlockSize, max: this.
|
|
57
|
+
inline: { min: this.resizeValues.minInlineSize, max: this.getMaxInlineSize() },
|
|
58
|
+
block: { min: this.resizeValues.minBlockSize, max: this.getMaxBlockSize() }
|
|
57
59
|
}),
|
|
58
60
|
onResize: (resizeValues) => {
|
|
59
61
|
this.resizeValues = resizeValues;
|
|
@@ -85,7 +87,7 @@ class ShellPanel extends LitElement {
|
|
|
85
87
|
this.listen("calciteActionBarCollapse", this.handleActionBarCollapseEvent);
|
|
86
88
|
}
|
|
87
89
|
static {
|
|
88
|
-
this.properties = { resizeValues: [16, {}, { state: true }], isActionBarExpanded: [16, {}, { state: true }], hasHeader: [16, {}, { state: true }], actionBarPosition: [3, {}, { reflect: true }], collapsed: [7, {}, { reflect: true, type: Boolean }], displayMode: [3, {}, { reflect: true }], heightScale: [3, {}, { reflect: true }], layout: [3, {}, { reflect: true }], messageOverrides: [0, {}, { attribute: false }], position: [3, {}, { reflect: true }], resizable: [7, {}, { reflect: true, type: Boolean }], height: [3, {}, { reflect: true }], widthScale: [3, {}, { reflect: true }], width: [3, {}, { reflect: true }] };
|
|
90
|
+
this.properties = { resizeValues: [16, {}, { state: true }], isActionBarExpanded: [16, {}, { state: true }], hasHeader: [16, {}, { state: true }], actionBarPosition: [3, {}, { reflect: true }], collapsed: [7, {}, { reflect: true, type: Boolean }], displayMode: [3, {}, { reflect: true }], heightScale: [3, {}, { reflect: true }], layout: [3, {}, { reflect: true }], messageOverrides: [0, {}, { attribute: false }], position: [3, {}, { reflect: true }], resizable: [7, {}, { reflect: true, type: Boolean }], shellSizingDataProvider: [0, {}, { attribute: false }], height: [3, {}, { reflect: true }], widthScale: [3, {}, { reflect: true }], width: [3, {}, { reflect: true }] };
|
|
89
91
|
}
|
|
90
92
|
static {
|
|
91
93
|
this.styles = [styles, styles$1];
|
|
@@ -201,20 +203,85 @@ class ShellPanel extends LitElement {
|
|
|
201
203
|
this.interaction?.unset();
|
|
202
204
|
}
|
|
203
205
|
updateResizeValues() {
|
|
204
|
-
const { contentRef } = this;
|
|
206
|
+
const { contentRef, layout } = this;
|
|
205
207
|
if (!contentRef.value) {
|
|
206
208
|
return;
|
|
207
209
|
}
|
|
208
210
|
const computedStyle = window.getComputedStyle(contentRef.value);
|
|
211
|
+
const computedMaxInlineSize = getStylePixelValue(computedStyle.maxInlineSize) || window.innerWidth;
|
|
212
|
+
const computedMaxBlockSize = getStylePixelValue(computedStyle.maxBlockSize) || window.innerHeight;
|
|
213
|
+
const availableInlineSize = layout === "vertical" ? this.getAvailableInlineSize() : null;
|
|
214
|
+
const availableBlockSize = layout === "horizontal" ? this.getAvailableBlockSize() : null;
|
|
209
215
|
this.resizeValues = {
|
|
210
216
|
inlineSize: getStylePixelValue(computedStyle.inlineSize),
|
|
211
217
|
blockSize: getStylePixelValue(computedStyle.blockSize),
|
|
212
218
|
minInlineSize: getStylePixelValue(computedStyle.minInlineSize),
|
|
213
219
|
minBlockSize: getStylePixelValue(computedStyle.minBlockSize),
|
|
214
|
-
maxInlineSize:
|
|
215
|
-
maxBlockSize:
|
|
220
|
+
maxInlineSize: availableInlineSize === null ? computedMaxInlineSize : Math.min(computedMaxInlineSize, availableInlineSize),
|
|
221
|
+
maxBlockSize: availableBlockSize === null ? computedMaxBlockSize : Math.min(computedMaxBlockSize, availableBlockSize)
|
|
216
222
|
};
|
|
217
223
|
}
|
|
224
|
+
getAvailableBlockSize() {
|
|
225
|
+
return this.getAvailableSize("block");
|
|
226
|
+
}
|
|
227
|
+
getAvailableInlineSize() {
|
|
228
|
+
return this.getAvailableSize("inline");
|
|
229
|
+
}
|
|
230
|
+
getAvailableSize(axis) {
|
|
231
|
+
const dimension = axis === "inline" ? "width" : "height";
|
|
232
|
+
const shellSizingData = this.shellSizingDataProvider?.(axis);
|
|
233
|
+
const actionBarContainerSize = this.actionBarContainerEl?.getBoundingClientRect()[dimension] ?? 0;
|
|
234
|
+
const actionBarSize = Math.max(actionBarContainerSize, this.actionBars.reduce((total, actionBar) => total + actionBar.getBoundingClientRect()[dimension], 0));
|
|
235
|
+
if (!shellSizingData) {
|
|
236
|
+
return null;
|
|
237
|
+
}
|
|
238
|
+
const { availableSize } = shellSizingData;
|
|
239
|
+
const containerSpacingSize = this.getContainerSpacingSize(axis);
|
|
240
|
+
const contentSpacingSize = this.getContentSpacingSize(axis);
|
|
241
|
+
return Math.max(Math.floor(availableSize) - Math.ceil(actionBarSize) - Math.ceil(containerSpacingSize) - Math.ceil(contentSpacingSize), 0);
|
|
242
|
+
}
|
|
243
|
+
getContentSpacingSize(axis) {
|
|
244
|
+
const content = this.contentRef.value;
|
|
245
|
+
if (!content) {
|
|
246
|
+
return 0;
|
|
247
|
+
}
|
|
248
|
+
const computedStyle = window.getComputedStyle(content);
|
|
249
|
+
return axis === "inline" ? getStylePixelValue(computedStyle.marginInlineStart) + getStylePixelValue(computedStyle.marginInlineEnd) + getStylePixelValue(computedStyle.borderInlineStartWidth) + getStylePixelValue(computedStyle.borderInlineEndWidth) : getStylePixelValue(computedStyle.marginBlockStart) + getStylePixelValue(computedStyle.marginBlockEnd) + getStylePixelValue(computedStyle.borderBlockStartWidth) + getStylePixelValue(computedStyle.borderBlockEndWidth);
|
|
250
|
+
}
|
|
251
|
+
getContainerSpacingSize(axis) {
|
|
252
|
+
const container = this.containerRef.value;
|
|
253
|
+
if (!container) {
|
|
254
|
+
return 0;
|
|
255
|
+
}
|
|
256
|
+
const computedStyle = window.getComputedStyle(container);
|
|
257
|
+
return axis === "inline" ? getStylePixelValue(computedStyle.marginInlineStart) + getStylePixelValue(computedStyle.marginInlineEnd) + getStylePixelValue(computedStyle.borderInlineStartWidth) + getStylePixelValue(computedStyle.borderInlineEndWidth) : getStylePixelValue(computedStyle.marginBlockStart) + getStylePixelValue(computedStyle.marginBlockEnd) + getStylePixelValue(computedStyle.borderBlockStartWidth) + getStylePixelValue(computedStyle.borderBlockEndWidth);
|
|
258
|
+
}
|
|
259
|
+
getMaxBlockSize() {
|
|
260
|
+
const { layout, contentRef } = this;
|
|
261
|
+
if (layout !== "horizontal") {
|
|
262
|
+
return this.resizeValues.maxBlockSize;
|
|
263
|
+
}
|
|
264
|
+
if (!contentRef.value) {
|
|
265
|
+
return this.resizeValues.maxBlockSize;
|
|
266
|
+
}
|
|
267
|
+
const computedStyle = window.getComputedStyle(contentRef.value);
|
|
268
|
+
const cssMax = getStylePixelValue(computedStyle.maxBlockSize) || window.innerHeight;
|
|
269
|
+
const availableBlockSize = this.getAvailableBlockSize();
|
|
270
|
+
return availableBlockSize === null ? cssMax : Math.min(cssMax, availableBlockSize);
|
|
271
|
+
}
|
|
272
|
+
getMaxInlineSize() {
|
|
273
|
+
const { layout, contentRef } = this;
|
|
274
|
+
if (layout !== "vertical") {
|
|
275
|
+
return this.resizeValues.maxInlineSize;
|
|
276
|
+
}
|
|
277
|
+
if (!contentRef.value) {
|
|
278
|
+
return this.resizeValues.maxInlineSize;
|
|
279
|
+
}
|
|
280
|
+
const computedStyle = window.getComputedStyle(contentRef.value);
|
|
281
|
+
const cssMax = getStylePixelValue(computedStyle.maxInlineSize) || window.innerWidth;
|
|
282
|
+
const availableInlineSize = this.getAvailableInlineSize();
|
|
283
|
+
return availableInlineSize === null ? cssMax : Math.min(cssMax, availableInlineSize);
|
|
284
|
+
}
|
|
218
285
|
async refreshResize() {
|
|
219
286
|
await this.componentOnReady();
|
|
220
287
|
await this.updateComplete;
|
|
@@ -230,7 +297,6 @@ class ShellPanel extends LitElement {
|
|
|
230
297
|
}
|
|
231
298
|
const rtl = this.direction === "rtl";
|
|
232
299
|
const restrictSizeMin = this.resizeValues.minInlineSize === null || this.resizeValues.minBlockSize === null ? void 0 : { width: this.resizeValues.minInlineSize, height: this.resizeValues.minBlockSize };
|
|
233
|
-
const restrictSizeMax = this.resizeValues.maxInlineSize === null || this.resizeValues.maxBlockSize === null ? void 0 : { width: this.resizeValues.maxInlineSize, height: this.resizeValues.maxBlockSize };
|
|
234
300
|
this.interaction = interact(contentRef.value, { context: el.ownerDocument }).resizable({
|
|
235
301
|
edges: {
|
|
236
302
|
top: position === "end" && layout === "horizontal" ? resizeHandle : false,
|
|
@@ -238,7 +304,7 @@ class ShellPanel extends LitElement {
|
|
|
238
304
|
bottom: position === "start" && layout === "horizontal" ? resizeHandle : false,
|
|
239
305
|
left: position === (rtl ? "start" : "end") && layout === "vertical" ? resizeHandle : false
|
|
240
306
|
},
|
|
241
|
-
modifiers: [interact.modifiers.restrictSize({ min: restrictSizeMin
|
|
307
|
+
modifiers: [interact.modifiers.restrictSize({ min: restrictSizeMin })],
|
|
242
308
|
listeners: {
|
|
243
309
|
resizestart: () => {
|
|
244
310
|
this.calciteInternalShellPanelResizeStart.emit();
|
|
@@ -344,10 +410,7 @@ class ShellPanel extends LitElement {
|
|
|
344
410
|
if (effectivePosition === "end" || effectivePosition === "bottom") {
|
|
345
411
|
mainNodes.reverse();
|
|
346
412
|
}
|
|
347
|
-
return html`<div class=${safeClassMap({
|
|
348
|
-
[CSS.container]: true,
|
|
349
|
-
[CSS.floatAll]: displayMode === "float-all"
|
|
350
|
-
})}>${mainNodes}</div>`;
|
|
413
|
+
return html`<div class=${safeClassMap({ [CSS.container]: true, [CSS.floatAll]: displayMode === "float-all" })} ${ref(this.containerRef)}>${mainNodes}</div>`;
|
|
351
414
|
}
|
|
352
415
|
}
|
|
353
416
|
customElement("calcite-shell-panel", ShellPanel);
|
|
@@ -42,11 +42,11 @@ export abstract class SortHandle extends LitElement {
|
|
|
42
42
|
*/
|
|
43
43
|
accessor open: boolean;
|
|
44
44
|
/**
|
|
45
|
-
* Specifies the type of positioning to use for overlaid content
|
|
45
|
+
* Specifies the type of positioning to use for overlaid content.
|
|
46
46
|
*
|
|
47
|
-
* `"absolute"` works for most cases - positioning the component inside of overflowing parent containers, which affects the container's layout
|
|
47
|
+
* - `"absolute"` works for most cases - positioning the component inside of overflowing parent containers, which affects the container's layout.
|
|
48
48
|
*
|
|
49
|
-
* `"fixed"` is used to escape an overflowing parent container, or when the reference element's `position` CSS property is `"fixed"`.
|
|
49
|
+
* - `"fixed"` is used to escape an overflowing parent container, or when the reference element's `position` CSS property is `"fixed"`.
|
|
50
50
|
*
|
|
51
51
|
* @default "absolute"
|
|
52
52
|
*/
|