se-design 1.0.75 → 1.0.76-dev1
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/assets/style.css +1 -1
- package/dist/components/AccessibleDiv/index.d.ts +24 -0
- package/dist/components/Checkbox/index.d.ts +12 -0
- package/dist/components/CustomAccordion/index.d.ts +1 -0
- package/dist/components/CustomModal/index.d.ts +15 -12
- package/dist/components/DatePicker/useDatePickerA11y.d.ts +50 -0
- package/dist/components/Dropdown/index.d.ts +13 -0
- package/dist/components/Icon/index.d.ts +8 -2
- package/dist/components/InputWithIcon/index.d.ts +9 -1
- package/dist/components/LabelChip/index.d.ts +1 -0
- package/dist/components/Modal/index.d.ts +1 -0
- package/dist/components/PhoneInput/index.d.ts +13 -5
- package/dist/components/Popover/index.d.ts +2 -0
- package/dist/components/SidebarOverlay/index.d.ts +8 -0
- package/dist/components/index.d.ts +1 -0
- package/dist/index.js +144 -133
- package/dist/index.js.map +1 -1
- package/dist/index10.js +23 -59
- package/dist/index10.js.map +1 -1
- package/dist/index100.js +1 -1
- package/dist/index100.js.map +1 -1
- package/dist/index101.js +1 -1
- package/dist/index101.js.map +1 -1
- package/dist/index102.js +2 -2
- package/dist/index102.js.map +1 -1
- package/dist/index103.js +2 -2
- package/dist/index103.js.map +1 -1
- package/dist/index104.js +1 -1
- package/dist/index104.js.map +1 -1
- package/dist/index105.js +1 -1
- package/dist/index105.js.map +1 -1
- package/dist/index106.js +1 -1
- package/dist/index106.js.map +1 -1
- package/dist/index107.js +2 -2
- package/dist/index107.js.map +1 -1
- package/dist/index108.js +2 -2
- package/dist/index108.js.map +1 -1
- package/dist/index109.js +2 -2
- package/dist/index109.js.map +1 -1
- package/dist/index11.js +70 -63
- package/dist/index11.js.map +1 -1
- package/dist/index110.js +2 -2
- package/dist/index110.js.map +1 -1
- package/dist/index111.js +1 -1
- package/dist/index111.js.map +1 -1
- package/dist/index112.js +1 -1
- package/dist/index112.js.map +1 -1
- package/dist/index113.js +2 -2
- package/dist/index113.js.map +1 -1
- package/dist/index114.js +2 -2
- package/dist/index114.js.map +1 -1
- package/dist/index115.js +1 -1
- package/dist/index115.js.map +1 -1
- package/dist/index116.js +1 -1
- package/dist/index116.js.map +1 -1
- package/dist/index117.js +1 -1
- package/dist/index117.js.map +1 -1
- package/dist/index118.js +2 -2
- package/dist/index118.js.map +1 -1
- package/dist/index119.js +1 -1
- package/dist/index119.js.map +1 -1
- package/dist/index12.js +71 -34
- package/dist/index12.js.map +1 -1
- package/dist/index120.js +2 -2
- package/dist/index120.js.map +1 -1
- package/dist/index121.js +2 -2
- package/dist/index121.js.map +1 -1
- package/dist/index122.js +2 -2
- package/dist/index122.js.map +1 -1
- package/dist/index123.js +2 -2
- package/dist/index123.js.map +1 -1
- package/dist/index124.js +2 -2
- package/dist/index124.js.map +1 -1
- package/dist/index125.js +2 -2
- package/dist/index125.js.map +1 -1
- package/dist/index126.js +1 -1
- package/dist/index126.js.map +1 -1
- package/dist/index127.js +1 -1
- package/dist/index127.js.map +1 -1
- package/dist/index128.js +1 -1
- package/dist/index128.js.map +1 -1
- package/dist/index129.js +1 -1
- package/dist/index129.js.map +1 -1
- package/dist/index13.js +50 -14
- package/dist/index13.js.map +1 -1
- package/dist/index130.js +2 -2
- package/dist/index130.js.map +1 -1
- package/dist/index131.js +2 -2
- package/dist/index131.js.map +1 -1
- package/dist/index132.js +1 -1
- package/dist/index132.js.map +1 -1
- package/dist/index133.js +1 -1
- package/dist/index133.js.map +1 -1
- package/dist/index134.js +2 -2
- package/dist/index134.js.map +1 -1
- package/dist/index135.js +1 -1
- package/dist/index135.js.map +1 -1
- package/dist/index136.js +1 -1
- package/dist/index136.js.map +1 -1
- package/dist/index137.js +1 -1
- package/dist/index137.js.map +1 -1
- package/dist/index138.js +1 -1
- package/dist/index138.js.map +1 -1
- package/dist/index139.js +1 -1
- package/dist/index139.js.map +1 -1
- package/dist/index14.js +15 -9
- package/dist/index14.js.map +1 -1
- package/dist/index140.js +1 -1
- package/dist/index140.js.map +1 -1
- package/dist/index141.js +2 -2
- package/dist/index141.js.map +1 -1
- package/dist/index142.js +1 -1
- package/dist/index142.js.map +1 -1
- package/dist/index143.js +2 -2
- package/dist/index143.js.map +1 -1
- package/dist/index144.js +2 -2
- package/dist/index144.js.map +1 -1
- package/dist/index145.js +1 -1
- package/dist/index145.js.map +1 -1
- package/dist/index146.js +2 -2
- package/dist/index146.js.map +1 -1
- package/dist/index147.js +2 -2
- package/dist/index147.js.map +1 -1
- package/dist/index148.js +1 -1
- package/dist/index148.js.map +1 -1
- package/dist/index149.js +1 -1
- package/dist/index149.js.map +1 -1
- package/dist/index15.js +10 -218
- package/dist/index15.js.map +1 -1
- package/dist/index150.js +2 -2
- package/dist/index150.js.map +1 -1
- package/dist/index151.js +2 -2
- package/dist/index151.js.map +1 -1
- package/dist/index152.js +1 -1
- package/dist/index152.js.map +1 -1
- package/dist/index153.js +2 -2
- package/dist/index153.js.map +1 -1
- package/dist/index154.js +2 -2
- package/dist/index154.js.map +1 -1
- package/dist/index155.js +1 -1
- package/dist/index155.js.map +1 -1
- package/dist/index156.js +1 -1
- package/dist/index156.js.map +1 -1
- package/dist/index157.js +1 -1
- package/dist/index157.js.map +1 -1
- package/dist/index158.js +1 -1
- package/dist/index158.js.map +1 -1
- package/dist/index159.js +1 -1
- package/dist/index159.js.map +1 -1
- package/dist/index16.js +220 -60
- package/dist/index16.js.map +1 -1
- package/dist/index160.js +1 -1
- package/dist/index160.js.map +1 -1
- package/dist/index161.js +1 -1
- package/dist/index161.js.map +1 -1
- package/dist/index162.js +1 -1
- package/dist/index162.js.map +1 -1
- package/dist/index163.js +1 -1
- package/dist/index163.js.map +1 -1
- package/dist/index164.js +1 -1
- package/dist/index164.js.map +1 -1
- package/dist/index165.js +1 -1
- package/dist/index165.js.map +1 -1
- package/dist/index166.js +1 -1
- package/dist/index166.js.map +1 -1
- package/dist/index167.js +1 -1
- package/dist/index167.js.map +1 -1
- package/dist/index168.js +1 -1
- package/dist/index168.js.map +1 -1
- package/dist/index169.js +1 -1
- package/dist/index169.js.map +1 -1
- package/dist/index17.js +60 -99
- package/dist/index17.js.map +1 -1
- package/dist/index170.js +1 -1
- package/dist/index170.js.map +1 -1
- package/dist/index171.js +1 -1
- package/dist/index171.js.map +1 -1
- package/dist/index172.js +1 -1
- package/dist/index172.js.map +1 -1
- package/dist/index173.js +2 -2
- package/dist/index173.js.map +1 -1
- package/dist/index174.js +1 -1
- package/dist/index174.js.map +1 -1
- package/dist/index175.js +1 -1
- package/dist/index175.js.map +1 -1
- package/dist/index176.js +1 -1
- package/dist/index176.js.map +1 -1
- package/dist/index177.js +2 -2
- package/dist/index177.js.map +1 -1
- package/dist/index178.js +1 -1
- package/dist/index178.js.map +1 -1
- package/dist/index179.js +1 -1
- package/dist/index179.js.map +1 -1
- package/dist/index18.js +95 -282
- package/dist/index18.js.map +1 -1
- package/dist/index180.js +2 -2
- package/dist/index180.js.map +1 -1
- package/dist/index181.js +1 -1
- package/dist/index181.js.map +1 -1
- package/dist/index182.js +1 -1
- package/dist/index182.js.map +1 -1
- package/dist/index183.js +1 -1
- package/dist/index183.js.map +1 -1
- package/dist/index184.js +2 -2
- package/dist/index184.js.map +1 -1
- package/dist/index185.js +1 -1
- package/dist/index185.js.map +1 -1
- package/dist/index186.js +1 -1
- package/dist/index186.js.map +1 -1
- package/dist/index187.js +2 -2
- package/dist/index187.js.map +1 -1
- package/dist/index188.js +1 -1
- package/dist/index188.js.map +1 -1
- package/dist/index189.js +2 -2
- package/dist/index189.js.map +1 -1
- package/dist/index19.js +317 -16
- package/dist/index19.js.map +1 -1
- package/dist/index190.js +2 -149
- package/dist/index190.js.map +1 -1
- package/dist/index191.js +2 -9
- package/dist/index191.js.map +1 -1
- package/dist/index192.js +2 -6
- package/dist/index192.js.map +1 -1
- package/dist/index193.js +2 -5
- package/dist/index193.js.map +1 -1
- package/dist/index194.js +2 -40
- package/dist/index194.js.map +1 -1
- package/dist/index195.js +2 -59
- package/dist/index195.js.map +1 -1
- package/dist/index196.js +2 -23
- package/dist/index196.js.map +1 -1
- package/dist/index197.js +152 -0
- package/dist/index197.js.map +1 -0
- package/dist/index198.js +12 -0
- package/dist/index198.js.map +1 -0
- package/dist/index199.js +5 -23
- package/dist/index199.js.map +1 -1
- package/dist/index20.js +15 -31
- package/dist/index20.js.map +1 -1
- package/dist/index200.js +8 -0
- package/dist/index200.js.map +1 -0
- package/dist/index201.js +36 -80
- package/dist/index201.js.map +1 -1
- package/dist/index206.js +26 -0
- package/dist/index206.js.map +1 -0
- package/dist/index207.js +71 -0
- package/dist/index207.js.map +1 -0
- package/dist/index21.js +33 -61
- package/dist/index21.js.map +1 -1
- package/dist/{index210.js → index215.js} +1 -1
- package/dist/{index210.js.map → index215.js.map} +1 -1
- package/dist/index22.js +57 -76
- package/dist/index22.js.map +1 -1
- package/dist/{index218.js → index223.js} +1 -1
- package/dist/{index218.js.map → index223.js.map} +1 -1
- package/dist/{index221.js → index226.js} +2 -2
- package/dist/{index221.js.map → index226.js.map} +1 -1
- package/dist/index23.js +83 -21
- package/dist/index23.js.map +1 -1
- package/dist/index235.js +171 -8
- package/dist/index235.js.map +1 -1
- package/dist/index236.js +3 -9
- package/dist/index236.js.map +1 -1
- package/dist/index238.js +18 -169
- package/dist/index238.js.map +1 -1
- package/dist/index239.js +10 -11
- package/dist/index239.js.map +1 -1
- package/dist/index24.js +20 -222
- package/dist/index24.js.map +1 -1
- package/dist/index240.js +8 -4
- package/dist/index240.js.map +1 -1
- package/dist/index241.js +4 -5
- package/dist/index241.js.map +1 -1
- package/dist/index242.js +168 -36
- package/dist/index242.js.map +1 -1
- package/dist/index243.js +11 -2
- package/dist/index243.js.map +1 -1
- package/dist/index244.js +5 -7
- package/dist/index244.js.map +1 -1
- package/dist/index245.js +5 -326
- package/dist/index245.js.map +1 -1
- package/dist/index246.js +36 -48
- package/dist/index246.js.map +1 -1
- package/dist/index247.js +2 -2
- package/dist/index248.js +7 -75
- package/dist/index248.js.map +1 -1
- package/dist/index249.js +308 -74
- package/dist/index249.js.map +1 -1
- package/dist/index25.js +289 -43
- package/dist/index25.js.map +1 -1
- package/dist/index250.js +45 -47
- package/dist/index250.js.map +1 -1
- package/dist/index251.js +2 -8
- package/dist/index251.js.map +1 -1
- package/dist/index252.js +75 -4
- package/dist/index252.js.map +1 -1
- package/dist/index253.js +89 -48
- package/dist/index253.js.map +1 -1
- package/dist/index254.js +52 -2
- package/dist/index254.js.map +1 -1
- package/dist/index255.js +8 -2
- package/dist/index255.js.map +1 -1
- package/dist/index256.js +8 -0
- package/dist/index256.js.map +1 -0
- package/dist/index257.js +55 -0
- package/dist/index257.js.map +1 -0
- package/dist/index258.js +5 -0
- package/dist/index258.js.map +1 -0
- package/dist/index259.js +5 -0
- package/dist/index259.js.map +1 -0
- package/dist/index26.js +48 -23
- package/dist/index26.js.map +1 -1
- package/dist/index27.js +21 -81
- package/dist/index27.js.map +1 -1
- package/dist/index28.js +101 -138
- package/dist/index28.js.map +1 -1
- package/dist/index29.js +139 -128
- package/dist/index29.js.map +1 -1
- package/dist/index3.js +57 -98
- package/dist/index3.js.map +1 -1
- package/dist/index30.js +133 -69
- package/dist/index30.js.map +1 -1
- package/dist/index31.js +67 -96
- package/dist/index31.js.map +1 -1
- package/dist/index32.js +96 -71
- package/dist/index32.js.map +1 -1
- package/dist/index33.js +70 -38
- package/dist/index33.js.map +1 -1
- package/dist/index34.js +40 -71
- package/dist/index34.js.map +1 -1
- package/dist/index35.js +67 -82
- package/dist/index35.js.map +1 -1
- package/dist/index36.js +99 -54
- package/dist/index36.js.map +1 -1
- package/dist/index37.js +53 -280
- package/dist/index37.js.map +1 -1
- package/dist/index38.js +281 -70
- package/dist/index38.js.map +1 -1
- package/dist/index39.js +69 -80
- package/dist/index39.js.map +1 -1
- package/dist/index4.js +102 -42
- package/dist/index4.js.map +1 -1
- package/dist/index40.js +82 -32
- package/dist/index40.js.map +1 -1
- package/dist/index41.js +26 -44
- package/dist/index41.js.map +1 -1
- package/dist/index42.js +45 -67
- package/dist/index42.js.map +1 -1
- package/dist/index43.js +65 -49
- package/dist/index43.js.map +1 -1
- package/dist/index44.js +53 -139
- package/dist/index44.js.map +1 -1
- package/dist/index45.js +132 -179
- package/dist/index45.js.map +1 -1
- package/dist/index46.js +194 -35
- package/dist/index46.js.map +1 -1
- package/dist/index47.js +34 -29
- package/dist/index47.js.map +1 -1
- package/dist/index48.js +31 -145
- package/dist/index48.js.map +1 -1
- package/dist/index49.js +131 -70
- package/dist/index49.js.map +1 -1
- package/dist/index5.js +40 -315
- package/dist/index5.js.map +1 -1
- package/dist/index50.js +80 -371
- package/dist/index50.js.map +1 -1
- package/dist/index51.js +451 -91
- package/dist/index51.js.map +1 -1
- package/dist/index52.js +98 -38
- package/dist/index52.js.map +1 -1
- package/dist/index53.js +35 -35
- package/dist/index53.js.map +1 -1
- package/dist/index54.js +35 -90
- package/dist/index54.js.map +1 -1
- package/dist/index55.js +89 -159
- package/dist/index55.js.map +1 -1
- package/dist/index56.js +157 -143
- package/dist/index56.js.map +1 -1
- package/dist/index57.js +149 -33
- package/dist/index57.js.map +1 -1
- package/dist/index58.js +33 -86
- package/dist/index58.js.map +1 -1
- package/dist/index59.js +80 -113
- package/dist/index59.js.map +1 -1
- package/dist/index6.js +323 -43
- package/dist/index6.js.map +1 -1
- package/dist/index60.js +114 -62
- package/dist/index60.js.map +1 -1
- package/dist/index61.js +62 -147
- package/dist/index61.js.map +1 -1
- package/dist/index62.js +146 -312
- package/dist/index62.js.map +1 -1
- package/dist/index63.js +317 -44
- package/dist/index63.js.map +1 -1
- package/dist/index64.js +44 -143
- package/dist/index64.js.map +1 -1
- package/dist/index65.js +145 -12
- package/dist/index65.js.map +1 -1
- package/dist/index66.js +10 -44
- package/dist/index66.js.map +1 -1
- package/dist/index67.js +42 -15
- package/dist/index67.js.map +1 -1
- package/dist/index68.js +76 -48
- package/dist/index68.js.map +1 -1
- package/dist/index69.js +18 -58
- package/dist/index69.js.map +1 -1
- package/dist/index7.js +44 -51
- package/dist/index7.js.map +1 -1
- package/dist/index70.js +66 -5
- package/dist/index70.js.map +1 -1
- package/dist/index71.js +25 -7
- package/dist/index71.js.map +1 -1
- package/dist/index72.js +105 -0
- package/dist/index72.js.map +1 -0
- package/dist/index73.js +62 -2
- package/dist/index73.js.map +1 -1
- package/dist/index74.js +21 -2
- package/dist/index74.js.map +1 -1
- package/dist/index75.js +5 -2
- package/dist/index75.js.map +1 -1
- package/dist/index76.js +54 -2
- package/dist/index76.js.map +1 -1
- package/dist/index77.js +24 -2
- package/dist/index77.js.map +1 -1
- package/dist/index78.js +9 -2
- package/dist/index78.js.map +1 -1
- package/dist/index8.js +48 -85
- package/dist/index8.js.map +1 -1
- package/dist/index80.js +2 -2
- package/dist/index80.js.map +1 -1
- package/dist/index81.js +2 -2
- package/dist/index81.js.map +1 -1
- package/dist/index82.js +1 -1
- package/dist/index82.js.map +1 -1
- package/dist/index83.js +2 -2
- package/dist/index83.js.map +1 -1
- package/dist/index84.js +1 -1
- package/dist/index84.js.map +1 -1
- package/dist/index85.js +1 -1
- package/dist/index85.js.map +1 -1
- package/dist/index86.js +1 -1
- package/dist/index86.js.map +1 -1
- package/dist/index87.js +1 -1
- package/dist/index87.js.map +1 -1
- package/dist/index88.js +1 -1
- package/dist/index88.js.map +1 -1
- package/dist/index89.js +1 -1
- package/dist/index89.js.map +1 -1
- package/dist/index9.js +91 -27
- package/dist/index9.js.map +1 -1
- package/dist/index90.js +1 -1
- package/dist/index90.js.map +1 -1
- package/dist/index91.js +1 -1
- package/dist/index91.js.map +1 -1
- package/dist/index92.js +1 -1
- package/dist/index92.js.map +1 -1
- package/dist/index93.js +1 -1
- package/dist/index93.js.map +1 -1
- package/dist/index94.js +1 -1
- package/dist/index94.js.map +1 -1
- package/dist/index95.js +1 -1
- package/dist/index95.js.map +1 -1
- package/dist/index96.js +1 -1
- package/dist/index96.js.map +1 -1
- package/dist/index97.js +1 -1
- package/dist/index97.js.map +1 -1
- package/dist/index98.js +1 -1
- package/dist/index98.js.map +1 -1
- package/dist/index99.js +1 -1
- package/dist/index99.js.map +1 -1
- package/package.json +1 -1
- package/dist/index230.js +0 -7
- package/dist/index230.js.map +0 -1
- package/dist/index232.js +0 -25
- package/dist/index232.js.map +0 -1
- package/dist/index233.js +0 -57
- package/dist/index233.js.map +0 -1
- package/dist/index234.js +0 -22
- package/dist/index234.js.map +0 -1
- package/dist/index237.js +0 -8
- package/dist/index237.js.map +0 -1
- package/dist/index79.js +0 -5
- package/dist/index79.js.map +0 -1
package/dist/index238.js
CHANGED
|
@@ -1,173 +1,22 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
return t.cloneNode(!0);
|
|
5
|
-
}, z = function() {
|
|
6
|
-
return window.location.protocol === "file:";
|
|
7
|
-
}, Z = function(t, o, n) {
|
|
8
|
-
var e = new XMLHttpRequest();
|
|
9
|
-
e.onreadystatechange = function() {
|
|
10
|
-
try {
|
|
11
|
-
if (!/\.svg/i.test(t) && e.readyState === 2) {
|
|
12
|
-
var s = e.getResponseHeader("Content-Type");
|
|
13
|
-
if (!s)
|
|
14
|
-
throw new Error("Content type not found");
|
|
15
|
-
var i = ut(s).type;
|
|
16
|
-
if (!(i === "image/svg+xml" || i === "text/plain"))
|
|
17
|
-
throw new Error("Invalid content type: ".concat(i));
|
|
18
|
-
}
|
|
19
|
-
if (e.readyState === 4) {
|
|
20
|
-
if (e.status === 404 || e.responseXML === null)
|
|
21
|
-
throw new Error(z() ? "Note: SVG injection ajax calls do not work locally without adjusting security settings in your browser. Or consider using a local webserver." : "Unable to load SVG file: " + t);
|
|
22
|
-
if (e.status === 200 || z() && e.status === 0)
|
|
23
|
-
n(null, e);
|
|
24
|
-
else
|
|
25
|
-
throw new Error("There was a problem injecting the SVG: " + e.status + " " + e.statusText);
|
|
26
|
-
}
|
|
27
|
-
} catch (a) {
|
|
28
|
-
if (e.abort(), a instanceof Error)
|
|
29
|
-
n(a, e);
|
|
30
|
-
else
|
|
31
|
-
throw a;
|
|
32
|
-
}
|
|
33
|
-
}, e.open("GET", t), e.withCredentials = o, e.overrideMimeType && e.overrideMimeType("text/xml"), e.send();
|
|
34
|
-
}, v = {}, B = function(t, o) {
|
|
35
|
-
v[t] = v[t] || [], v[t].push(o);
|
|
36
|
-
}, ft = function(t) {
|
|
37
|
-
for (var o = function(i, a) {
|
|
38
|
-
setTimeout(function() {
|
|
39
|
-
if (Array.isArray(v[t])) {
|
|
40
|
-
var u = g.get(t), p = v[t][i];
|
|
41
|
-
u instanceof SVGSVGElement && p(null, Y(u)), u instanceof Error && p(u), i === v[t].length - 1 && delete v[t];
|
|
42
|
-
}
|
|
43
|
-
}, 0);
|
|
44
|
-
}, n = 0, e = v[t].length; n < e; n++)
|
|
45
|
-
o(n);
|
|
46
|
-
}, lt = function(t, o, n) {
|
|
47
|
-
if (g.has(t)) {
|
|
48
|
-
var e = g.get(t);
|
|
49
|
-
if (e === void 0) {
|
|
50
|
-
B(t, n);
|
|
51
|
-
return;
|
|
52
|
-
}
|
|
53
|
-
if (e instanceof SVGSVGElement) {
|
|
54
|
-
n(null, Y(e));
|
|
55
|
-
return;
|
|
56
|
-
}
|
|
57
|
-
}
|
|
58
|
-
g.set(t, void 0), B(t, n), Z(t, o, function(s, i) {
|
|
59
|
-
var a;
|
|
60
|
-
s ? g.set(t, s) : ((a = i.responseXML) === null || a === void 0 ? void 0 : a.documentElement) instanceof SVGSVGElement && g.set(t, i.responseXML.documentElement), ft(t);
|
|
61
|
-
});
|
|
62
|
-
}, ct = function(t, o, n) {
|
|
63
|
-
Z(t, o, function(e, s) {
|
|
64
|
-
var i;
|
|
65
|
-
e ? n(e) : ((i = s.responseXML) === null || i === void 0 ? void 0 : i.documentElement) instanceof SVGSVGElement && n(null, s.responseXML.documentElement);
|
|
66
|
-
});
|
|
67
|
-
}, dt = 0, vt = function() {
|
|
68
|
-
return ++dt;
|
|
69
|
-
}, l = [], J = {}, pt = "http://www.w3.org/2000/svg", F = "http://www.w3.org/1999/xlink", K = function(t, o, n, e, s, i, a) {
|
|
70
|
-
var u = t.getAttribute("data-src") || t.getAttribute("src");
|
|
71
|
-
if (!u) {
|
|
72
|
-
a(new Error("Invalid data-src or src attribute"));
|
|
73
|
-
return;
|
|
74
|
-
}
|
|
75
|
-
if (l.indexOf(t) !== -1) {
|
|
76
|
-
l.splice(l.indexOf(t), 1), t = null;
|
|
77
|
-
return;
|
|
78
|
-
}
|
|
79
|
-
l.push(t), t.setAttribute("src", "");
|
|
80
|
-
var p = e ? lt : ct;
|
|
81
|
-
p(u, s, function(j, r) {
|
|
82
|
-
if (!r) {
|
|
83
|
-
l.splice(l.indexOf(t), 1), t = null, a(j);
|
|
84
|
-
return;
|
|
85
|
-
}
|
|
86
|
-
var w = t.getAttribute("id");
|
|
87
|
-
w && r.setAttribute("id", w);
|
|
88
|
-
var S = t.getAttribute("title");
|
|
89
|
-
S && r.setAttribute("title", S);
|
|
90
|
-
var E = t.getAttribute("width");
|
|
91
|
-
E && r.setAttribute("width", E);
|
|
92
|
-
var y = t.getAttribute("height");
|
|
93
|
-
y && r.setAttribute("height", y);
|
|
94
|
-
var G = Array.from(new Set(D(D(D([], (r.getAttribute("class") || "").split(" "), !0), ["injected-svg"], !1), (t.getAttribute("class") || "").split(" "), !0))).join(" ").trim();
|
|
95
|
-
r.setAttribute("class", G);
|
|
96
|
-
var b = t.getAttribute("style");
|
|
97
|
-
b && r.setAttribute("style", b), r.setAttribute("data-src", u);
|
|
98
|
-
var R = [].filter.call(t.attributes, function(f) {
|
|
99
|
-
return /^data-\w[\w-]*$/.test(f.name);
|
|
100
|
-
});
|
|
101
|
-
if (Array.prototype.forEach.call(R, function(f) {
|
|
102
|
-
f.name && f.value && r.setAttribute(f.name, f.value);
|
|
103
|
-
}), n) {
|
|
104
|
-
var h = {
|
|
105
|
-
clipPath: ["clip-path"],
|
|
106
|
-
"color-profile": ["color-profile"],
|
|
107
|
-
cursor: ["cursor"],
|
|
108
|
-
filter: ["filter"],
|
|
109
|
-
linearGradient: ["fill", "stroke"],
|
|
110
|
-
marker: ["marker", "marker-start", "marker-mid", "marker-end"],
|
|
111
|
-
mask: ["mask"],
|
|
112
|
-
path: [],
|
|
113
|
-
pattern: ["fill", "stroke"],
|
|
114
|
-
radialGradient: ["fill", "stroke"]
|
|
115
|
-
}, C, d, m, T, k;
|
|
116
|
-
Object.keys(h).forEach(function(f) {
|
|
117
|
-
C = f, m = h[f], d = r.querySelectorAll(C + "[id]");
|
|
118
|
-
for (var nt = function(I, mt) {
|
|
119
|
-
T = d[I].id, k = T + "-" + vt();
|
|
120
|
-
var M;
|
|
121
|
-
Array.prototype.forEach.call(m, function(W) {
|
|
122
|
-
M = r.querySelectorAll("[" + W + '*="' + T + '"]');
|
|
123
|
-
for (var O = 0, st = M.length; O < st; O++) {
|
|
124
|
-
var $ = M[O].getAttribute(W);
|
|
125
|
-
$ && !$.match(new RegExp('url\\("?#' + T + '"?\\)')) || M[O].setAttribute(W, "url(#" + k + ")");
|
|
126
|
-
}
|
|
127
|
-
});
|
|
128
|
-
for (var U = r.querySelectorAll("[*|href]"), H = [], N = 0, at = U.length; N < at; N++) {
|
|
129
|
-
var P = U[N].getAttributeNS(F, "href");
|
|
130
|
-
P && P.toString() === "#" + d[I].id && H.push(U[N]);
|
|
131
|
-
}
|
|
132
|
-
for (var Q = 0, ot = H.length; Q < ot; Q++)
|
|
133
|
-
H[Q].setAttributeNS(F, "href", "#" + k);
|
|
134
|
-
d[I].id = k;
|
|
135
|
-
}, _ = 0, it = d.length; _ < it; _++)
|
|
136
|
-
nt(_);
|
|
137
|
-
});
|
|
138
|
-
}
|
|
139
|
-
r.removeAttribute("xmlns:a");
|
|
140
|
-
for (var x = r.querySelectorAll("script"), L = [], V, q, A = 0, tt = x.length; A < tt; A++)
|
|
141
|
-
q = x[A].getAttribute("type"), (!q || q === "application/ecmascript" || q === "application/javascript" || q === "text/javascript") && (V = x[A].innerText || x[A].textContent, V && L.push(V), r.removeChild(x[A]));
|
|
142
|
-
if (L.length > 0 && (o === "always" || o === "once" && !J[u])) {
|
|
143
|
-
for (var X = 0, et = L.length; X < et; X++)
|
|
144
|
-
new Function(L[X])(window);
|
|
145
|
-
J[u] = !0;
|
|
146
|
-
}
|
|
147
|
-
var rt = r.querySelectorAll("style");
|
|
148
|
-
if (Array.prototype.forEach.call(rt, function(f) {
|
|
149
|
-
f.textContent += "";
|
|
150
|
-
}), r.setAttribute("xmlns", pt), r.setAttribute("xmlns:xlink", F), i(r), !t.parentNode) {
|
|
151
|
-
l.splice(l.indexOf(t), 1), t = null, a(new Error("Parent node is null"));
|
|
152
|
-
return;
|
|
153
|
-
}
|
|
154
|
-
t.parentNode.replaceChild(r, t), l.splice(l.indexOf(t), 1), t = null, a(null, r);
|
|
155
|
-
});
|
|
156
|
-
}, wt = function(t, o) {
|
|
157
|
-
var n = o === void 0 ? {} : o, e = n.afterAll, s = e === void 0 ? function() {
|
|
158
|
-
} : e, i = n.afterEach, a = i === void 0 ? function() {
|
|
159
|
-
} : i, u = n.beforeEach, p = u === void 0 ? function() {
|
|
160
|
-
} : u, j = n.cacheRequests, r = j === void 0 ? !0 : j, w = n.evalScripts, S = w === void 0 ? "never" : w, E = n.httpRequestWithCredentials, y = E === void 0 ? !1 : E, G = n.renumerateIRIElements, b = G === void 0 ? !0 : G;
|
|
161
|
-
if (t && "length" in t)
|
|
162
|
-
for (var R = 0, h = 0, C = t.length; h < C; h++)
|
|
163
|
-
K(t[h], S, b, r, y, p, function(d, m) {
|
|
164
|
-
a(d, m), t && "length" in t && t.length === ++R && s(R);
|
|
165
|
-
});
|
|
166
|
-
else t ? K(t, S, b, r, y, p, function(d, m) {
|
|
167
|
-
a(d, m), s(1), t = null;
|
|
168
|
-
}) : s(0);
|
|
1
|
+
import { useEffect as s } from "react";
|
|
2
|
+
const u = {
|
|
3
|
+
block: "nearest"
|
|
169
4
|
};
|
|
5
|
+
function m({
|
|
6
|
+
containerRef: t,
|
|
7
|
+
activeIndex: o,
|
|
8
|
+
itemSelector: r = '[role="option"]',
|
|
9
|
+
enabled: c = !0,
|
|
10
|
+
scrollOptions: e = u
|
|
11
|
+
}) {
|
|
12
|
+
s(() => {
|
|
13
|
+
if (!c || o < 0 || !t?.current)
|
|
14
|
+
return;
|
|
15
|
+
const n = t.current.querySelectorAll(r)[o];
|
|
16
|
+
n && n.scrollIntoView(e);
|
|
17
|
+
}, [o, t, r, c, e]);
|
|
18
|
+
}
|
|
170
19
|
export {
|
|
171
|
-
|
|
20
|
+
m as useScrollActiveIntoView
|
|
172
21
|
};
|
|
173
22
|
//# sourceMappingURL=index238.js.map
|
package/dist/index238.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index238.js","sources":["../node_modules/@tanem/svg-injector/dist/svg-injector.esm.js"],"sourcesContent":["import { __spreadArray } from 'tslib';\nimport { parse } from 'content-type';\n\nvar cache = new Map();\n\nvar cloneSvg = function cloneSvg(sourceSvg) {\n return sourceSvg.cloneNode(true);\n};\n\nvar isLocal = function isLocal() {\n return window.location.protocol === 'file:';\n};\n\nvar makeAjaxRequest = function makeAjaxRequest(url, httpRequestWithCredentials, callback) {\n var httpRequest = new XMLHttpRequest();\n httpRequest.onreadystatechange = function () {\n try {\n if (!/\\.svg/i.test(url) && httpRequest.readyState === 2) {\n var contentType = httpRequest.getResponseHeader('Content-Type');\n if (!contentType) {\n throw new Error('Content type not found');\n }\n var type = parse(contentType).type;\n if (!(type === 'image/svg+xml' || type === 'text/plain')) {\n throw new Error(\"Invalid content type: \".concat(type));\n }\n }\n if (httpRequest.readyState === 4) {\n if (httpRequest.status === 404 || httpRequest.responseXML === null) {\n throw new Error(isLocal() ? 'Note: SVG injection ajax calls do not work locally without ' + 'adjusting security settings in your browser. Or consider ' + 'using a local webserver.' : 'Unable to load SVG file: ' + url);\n }\n if (httpRequest.status === 200 || isLocal() && httpRequest.status === 0) {\n callback(null, httpRequest);\n } else {\n throw new Error('There was a problem injecting the SVG: ' + httpRequest.status + ' ' + httpRequest.statusText);\n }\n }\n } catch (error) {\n httpRequest.abort();\n if (error instanceof Error) {\n callback(error, httpRequest);\n } else {\n throw error;\n }\n }\n };\n httpRequest.open('GET', url);\n httpRequest.withCredentials = httpRequestWithCredentials;\n if (httpRequest.overrideMimeType) {\n httpRequest.overrideMimeType('text/xml');\n }\n httpRequest.send();\n};\n\nvar requestQueue = {};\nvar queueRequest = function queueRequest(url, callback) {\n requestQueue[url] = requestQueue[url] || [];\n requestQueue[url].push(callback);\n};\nvar processRequestQueue = function processRequestQueue(url) {\n var _loop_1 = function _loop_1(i, len) {\n setTimeout(function () {\n if (Array.isArray(requestQueue[url])) {\n var cacheValue = cache.get(url);\n var callback = requestQueue[url][i];\n if (cacheValue instanceof SVGSVGElement) {\n callback(null, cloneSvg(cacheValue));\n }\n if (cacheValue instanceof Error) {\n callback(cacheValue);\n }\n if (i === requestQueue[url].length - 1) {\n delete requestQueue[url];\n }\n }\n }, 0);\n };\n for (var i = 0, len = requestQueue[url].length; i < len; i++) {\n _loop_1(i);\n }\n};\n\nvar loadSvgCached = function loadSvgCached(url, httpRequestWithCredentials, callback) {\n if (cache.has(url)) {\n var cacheValue = cache.get(url);\n if (cacheValue === undefined) {\n queueRequest(url, callback);\n return;\n }\n if (cacheValue instanceof SVGSVGElement) {\n callback(null, cloneSvg(cacheValue));\n return;\n }\n }\n cache.set(url, undefined);\n queueRequest(url, callback);\n makeAjaxRequest(url, httpRequestWithCredentials, function (error, httpRequest) {\n var _a;\n if (error) {\n cache.set(url, error);\n } else if (((_a = httpRequest.responseXML) === null || _a === void 0 ? void 0 : _a.documentElement) instanceof SVGSVGElement) {\n cache.set(url, httpRequest.responseXML.documentElement);\n }\n processRequestQueue(url);\n });\n};\n\nvar loadSvgUncached = function loadSvgUncached(url, httpRequestWithCredentials, callback) {\n makeAjaxRequest(url, httpRequestWithCredentials, function (error, httpRequest) {\n var _a;\n if (error) {\n callback(error);\n } else if (((_a = httpRequest.responseXML) === null || _a === void 0 ? void 0 : _a.documentElement) instanceof SVGSVGElement) {\n callback(null, httpRequest.responseXML.documentElement);\n }\n });\n};\n\nvar idCounter = 0;\nvar uniqueId = function uniqueId() {\n return ++idCounter;\n};\n\nvar injectedElements = [];\nvar ranScripts = {};\nvar svgNamespace = 'http://www.w3.org/2000/svg';\nvar xlinkNamespace = 'http://www.w3.org/1999/xlink';\nvar injectElement = function injectElement(el, evalScripts, renumerateIRIElements, cacheRequests, httpRequestWithCredentials, beforeEach, callback) {\n var elUrl = el.getAttribute('data-src') || el.getAttribute('src');\n if (!elUrl) {\n callback(new Error('Invalid data-src or src attribute'));\n return;\n }\n if (injectedElements.indexOf(el) !== -1) {\n injectedElements.splice(injectedElements.indexOf(el), 1);\n el = null;\n return;\n }\n injectedElements.push(el);\n el.setAttribute('src', '');\n var loadSvg = cacheRequests ? loadSvgCached : loadSvgUncached;\n loadSvg(elUrl, httpRequestWithCredentials, function (error, svg) {\n if (!svg) {\n injectedElements.splice(injectedElements.indexOf(el), 1);\n el = null;\n callback(error);\n return;\n }\n var elId = el.getAttribute('id');\n if (elId) {\n svg.setAttribute('id', elId);\n }\n var elTitle = el.getAttribute('title');\n if (elTitle) {\n svg.setAttribute('title', elTitle);\n }\n var elWidth = el.getAttribute('width');\n if (elWidth) {\n svg.setAttribute('width', elWidth);\n }\n var elHeight = el.getAttribute('height');\n if (elHeight) {\n svg.setAttribute('height', elHeight);\n }\n var mergedClasses = Array.from(new Set(__spreadArray(__spreadArray(__spreadArray([], (svg.getAttribute('class') || '').split(' '), true), ['injected-svg'], false), (el.getAttribute('class') || '').split(' '), true))).join(' ').trim();\n svg.setAttribute('class', mergedClasses);\n var elStyle = el.getAttribute('style');\n if (elStyle) {\n svg.setAttribute('style', elStyle);\n }\n svg.setAttribute('data-src', elUrl);\n var elData = [].filter.call(el.attributes, function (at) {\n return /^data-\\w[\\w-]*$/.test(at.name);\n });\n Array.prototype.forEach.call(elData, function (dataAttr) {\n if (dataAttr.name && dataAttr.value) {\n svg.setAttribute(dataAttr.name, dataAttr.value);\n }\n });\n if (renumerateIRIElements) {\n var iriElementsAndProperties_1 = {\n clipPath: ['clip-path'],\n 'color-profile': ['color-profile'],\n cursor: ['cursor'],\n filter: ['filter'],\n linearGradient: ['fill', 'stroke'],\n marker: ['marker', 'marker-start', 'marker-mid', 'marker-end'],\n mask: ['mask'],\n path: [],\n pattern: ['fill', 'stroke'],\n radialGradient: ['fill', 'stroke']\n };\n var element_1;\n var elements_1;\n var properties_1;\n var currentId_1;\n var newId_1;\n Object.keys(iriElementsAndProperties_1).forEach(function (key) {\n element_1 = key;\n properties_1 = iriElementsAndProperties_1[key];\n elements_1 = svg.querySelectorAll(element_1 + '[id]');\n var _loop_1 = function _loop_1(a, elementsLen) {\n currentId_1 = elements_1[a].id;\n newId_1 = currentId_1 + '-' + uniqueId();\n var referencingElements;\n Array.prototype.forEach.call(properties_1, function (property) {\n referencingElements = svg.querySelectorAll('[' + property + '*=\"' + currentId_1 + '\"]');\n for (var b = 0, referencingElementLen = referencingElements.length; b < referencingElementLen; b++) {\n var attrValue = referencingElements[b].getAttribute(property);\n if (attrValue && !attrValue.match(new RegExp('url\\\\(\"?#' + currentId_1 + '\"?\\\\)'))) {\n continue;\n }\n referencingElements[b].setAttribute(property, 'url(#' + newId_1 + ')');\n }\n });\n var allLinks = svg.querySelectorAll('[*|href]');\n var links = [];\n for (var c = 0, allLinksLen = allLinks.length; c < allLinksLen; c++) {\n var href = allLinks[c].getAttributeNS(xlinkNamespace, 'href');\n if (href && href.toString() === '#' + elements_1[a].id) {\n links.push(allLinks[c]);\n }\n }\n for (var d = 0, linksLen = links.length; d < linksLen; d++) {\n links[d].setAttributeNS(xlinkNamespace, 'href', '#' + newId_1);\n }\n elements_1[a].id = newId_1;\n };\n for (var a = 0, elementsLen = elements_1.length; a < elementsLen; a++) {\n _loop_1(a);\n }\n });\n }\n svg.removeAttribute('xmlns:a');\n var scripts = svg.querySelectorAll('script');\n var scriptsToEval = [];\n var script;\n var scriptType;\n for (var i = 0, scriptsLen = scripts.length; i < scriptsLen; i++) {\n scriptType = scripts[i].getAttribute('type');\n if (!scriptType || scriptType === 'application/ecmascript' || scriptType === 'application/javascript' || scriptType === 'text/javascript') {\n script = scripts[i].innerText || scripts[i].textContent;\n if (script) {\n scriptsToEval.push(script);\n }\n svg.removeChild(scripts[i]);\n }\n }\n if (scriptsToEval.length > 0 && (evalScripts === 'always' || evalScripts === 'once' && !ranScripts[elUrl])) {\n for (var l = 0, scriptsToEvalLen = scriptsToEval.length; l < scriptsToEvalLen; l++) {\n new Function(scriptsToEval[l])(window);\n }\n ranScripts[elUrl] = true;\n }\n var styleTags = svg.querySelectorAll('style');\n Array.prototype.forEach.call(styleTags, function (styleTag) {\n styleTag.textContent += '';\n });\n svg.setAttribute('xmlns', svgNamespace);\n svg.setAttribute('xmlns:xlink', xlinkNamespace);\n beforeEach(svg);\n if (!el.parentNode) {\n injectedElements.splice(injectedElements.indexOf(el), 1);\n el = null;\n callback(new Error('Parent node is null'));\n return;\n }\n el.parentNode.replaceChild(svg, el);\n injectedElements.splice(injectedElements.indexOf(el), 1);\n el = null;\n callback(null, svg);\n });\n};\n\nvar SVGInjector = function SVGInjector(elements, _a) {\n var _b = _a === void 0 ? {} : _a,\n _c = _b.afterAll,\n afterAll = _c === void 0 ? function () {\n return undefined;\n } : _c,\n _d = _b.afterEach,\n afterEach = _d === void 0 ? function () {\n return undefined;\n } : _d,\n _e = _b.beforeEach,\n beforeEach = _e === void 0 ? function () {\n return undefined;\n } : _e,\n _f = _b.cacheRequests,\n cacheRequests = _f === void 0 ? true : _f,\n _g = _b.evalScripts,\n evalScripts = _g === void 0 ? 'never' : _g,\n _h = _b.httpRequestWithCredentials,\n httpRequestWithCredentials = _h === void 0 ? false : _h,\n _j = _b.renumerateIRIElements,\n renumerateIRIElements = _j === void 0 ? true : _j;\n if (elements && 'length' in elements) {\n var elementsLoaded_1 = 0;\n for (var i = 0, j = elements.length; i < j; i++) {\n injectElement(elements[i], evalScripts, renumerateIRIElements, cacheRequests, httpRequestWithCredentials, beforeEach, function (error, svg) {\n afterEach(error, svg);\n if (elements && 'length' in elements && elements.length === ++elementsLoaded_1) {\n afterAll(elementsLoaded_1);\n }\n });\n }\n } else if (elements) {\n injectElement(elements, evalScripts, renumerateIRIElements, cacheRequests, httpRequestWithCredentials, beforeEach, function (error, svg) {\n afterEach(error, svg);\n afterAll(1);\n elements = null;\n });\n } else {\n afterAll(0);\n }\n};\n\nexport { SVGInjector };\n//# sourceMappingURL=svg-injector.esm.js.map\n"],"names":["__spreadArray","parse_1","cache","cloneSvg","sourceSvg","isLocal","makeAjaxRequest","url","httpRequestWithCredentials","callback","httpRequest","contentType","type","parse","error","requestQueue","queueRequest","processRequestQueue","_loop_1","len","cacheValue","i","loadSvgCached","_a","loadSvgUncached","idCounter","uniqueId","injectedElements","ranScripts","svgNamespace","xlinkNamespace","injectElement","el","evalScripts","renumerateIRIElements","cacheRequests","beforeEach","elUrl","loadSvg","svg","elId","elTitle","elWidth","elHeight","mergedClasses","elStyle","elData","at","dataAttr","iriElementsAndProperties_1","element_1","elements_1","properties_1","currentId_1","newId_1","key","a","elementsLen","referencingElements","property","b","referencingElementLen","attrValue","allLinks","links","c","allLinksLen","href","d","linksLen","scripts","scriptsToEval","script","scriptType","scriptsLen","l","scriptsToEvalLen","styleTags","styleTag","SVGInjector","elements","_b","_c","afterAll","_d","afterEach","_e","_f","_g","_h","_j","elementsLoaded_1","j"],"mappings":"AAGA,SAAA,iBAAAA,SAAA;AAAA,SAAA,SAAAC,UAAA;AAAA,IAAIC,IAAQ,oBAAI,OAEZC,IAAW,SAAkBC,GAAW;AAC1C,SAAOA,EAAU,UAAU,EAAI;AACjC,GAEIC,IAAU,WAAmB;AAC/B,SAAO,OAAO,SAAS,aAAa;AACtC,GAEIC,IAAkB,SAAyBC,GAAKC,GAA4BC,GAAU;AACxF,MAAIC,IAAc,IAAI;AACtB,EAAAA,EAAY,qBAAqB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,CAAE,IAAGA,GAC5B2D,IAAKD,EAAG,UACRE,IAAWD,MAAO,SAAS,WAAY;AAAA,EAE3C,IAAQA,GACJE,IAAKH,EAAG,WACRI,IAAYD,MAAO,SAAS,WAAY;AAAA,EAE5C,IAAQA,GACJE,IAAKL,EAAG,YACR7C,IAAakD,MAAO,SAAS,WAAY;AAAA,EAE7C,IAAQA,GACJC,IAAKN,EAAG,eACR9C,IAAgBoD,MAAO,SAAS,KAAOA,GACvCC,IAAKP,EAAG,aACRhD,IAAcuD,MAAO,SAAS,UAAUA,GACxCC,IAAKR,EAAG,4BACRzE,IAA6BiF,MAAO,SAAS,KAAQA,GACrDC,IAAKT,EAAG,uBACR/C,IAAwBwD,MAAO,SAAS,KAAOA;AACjD,MAAIV,KAAY,YAAYA;AAE1B,aADIW,IAAmB,GACdtE,IAAI,GAAGuE,IAAIZ,EAAS,QAAQ3D,IAAIuE,GAAGvE;AAC1C,MAAAU,EAAciD,EAAS3D,CAAC,GAAGY,GAAaC,GAAuBC,GAAe3B,GAA4B4B,GAAY,SAAUtB,GAAOyB,GAAK;AAC1I,QAAA8C,EAAUvE,GAAOyB,CAAG,GAChByC,KAAY,YAAYA,KAAYA,EAAS,WAAW,EAAEW,KAC5DR,EAASQ,CAAgB;AAAA,MAEnC,CAAO;AAAA,MAEE,CAAIX,IACTjD,EAAciD,GAAU/C,GAAaC,GAAuBC,GAAe3B,GAA4B4B,GAAY,SAAUtB,GAAOyB,GAAK;AACvI,IAAA8C,EAAUvE,GAAOyB,CAAG,GACpB4C,EAAS,CAAC,GACVH,IAAW;AAAA,EACjB,CAAK,IAEDG,EAAS,CAAC;AAEd;","x_google_ignoreList":[0]}
|
|
1
|
+
{"version":3,"file":"index238.js","sources":["../src/utils/a11y/useScrollActiveIntoView.ts"],"sourcesContent":["import { useEffect } from 'react';\nimport type { RefObject } from 'react';\n\nconst DEFAULT_SCROLL_OPTIONS: ScrollIntoViewOptions = { block: 'nearest' };\n\nexport interface UseScrollActiveIntoViewOptions {\n /**\n * Ref to the container element\n */\n containerRef?: RefObject<HTMLElement | null>;\n \n /**\n * Index of the currently active/highlighted item (-1 if none)\n */\n activeIndex: number;\n \n /**\n * CSS selector for item elements\n * Default: '[role=\"option\"]'\n */\n itemSelector?: string;\n \n /**\n * Whether scrolling is enabled\n * Default: true\n */\n enabled?: boolean;\n \n /**\n * ScrollIntoView options\n * Default: { block: 'nearest' }\n */\n scrollOptions?: ScrollIntoViewOptions;\n}\n\n/**\n * Hook to automatically scroll the active item into view.\n * \n * Useful for aria-activedescendant patterns where DOM focus stays\n * on the container (e.g., input field) but we need to visually show\n * which descendant option is logically active.\n * \n * Common use cases:\n * - Combobox dropdown options\n * - Menu items with virtual focus\n * - Grid cells with keyboard navigation\n * - Tree view items\n * - Listbox options\n * \n * @example\n * ```tsx\n * const [highlightedIndex, setHighlightedIndex] = useState(-1);\n * const listboxRef = useRef<HTMLDivElement>(null);\n * \n * useScrollActiveIntoView({\n * containerRef: listboxRef,\n * activeIndex: highlightedIndex,\n * itemSelector: '[role=\"option\"]'\n * });\n * \n * // Now when highlightedIndex changes, the item scrolls into view\n * ```\n * \n * @example Custom scroll behavior\n * ```tsx\n * useScrollActiveIntoView({\n * containerRef: menuRef,\n * activeIndex: activeMenuIndex,\n * itemSelector: '[role=\"menuitem\"]',\n * scrollOptions: { block: 'center', behavior: 'smooth' }\n * });\n * ```\n */\nexport function useScrollActiveIntoView({\n containerRef,\n activeIndex,\n itemSelector = '[role=\"option\"]',\n enabled = true,\n scrollOptions = DEFAULT_SCROLL_OPTIONS\n}: UseScrollActiveIntoViewOptions): void {\n useEffect(() => {\n // Early returns for disabled states\n if (!enabled || activeIndex < 0 || !containerRef?.current) {\n return;\n }\n \n const container = containerRef.current;\n const items = container.querySelectorAll(itemSelector);\n const activeItem = items[activeIndex] as HTMLElement;\n \n if (activeItem) {\n activeItem.scrollIntoView(scrollOptions);\n }\n }, [activeIndex, containerRef, itemSelector, enabled, scrollOptions]);\n}\n"],"names":["useEffect","DEFAULT_SCROLL_OPTIONS","block","useScrollActiveIntoView","containerRef","activeIndex","itemSelector","enabled","scrollOptions","current","activeItem","querySelectorAll","scrollIntoView"],"mappings":"AAGA,SAAA,aAAAA,SAAA;AAAA,MAAMC,IAAgD;AAAA,EAAEC,OAAO;AAAU;AAsElE,SAASC,EAAwB;AAAA,EACtCC,cAAAA;AAAAA,EACAC,aAAAA;AAAAA,EACAC,cAAAA,IAAe;AAAA,EACfC,SAAAA,IAAU;AAAA,EACVC,eAAAA,IAAgBP;AACc,GAAS;AACvCD,EAAAA,EAAU,MAAM;AAEd,QAAI,CAACO,KAAWF,IAAc,KAAK,CAACD,GAAcK;AAChD;AAKF,UAAMC,IAFYN,EAAaK,QACPE,iBAAiBL,CAAY,EAC5BD,CAAW;AAEpC,IAAIK,KACFA,EAAWE,eAAeJ,CAAa;AAAA,EAE3C,GAAG,CAACH,GAAaD,GAAcE,GAAcC,GAASC,CAAa,CAAC;AACtE;"}
|
package/dist/index239.js
CHANGED
|
@@ -1,14 +1,13 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
if (
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
var _ = r.exports;
|
|
1
|
+
function r(t, i) {
|
|
2
|
+
if (t == null) return {};
|
|
3
|
+
var o = {};
|
|
4
|
+
for (var e in t) if ({}.hasOwnProperty.call(t, e)) {
|
|
5
|
+
if (i.indexOf(e) !== -1) continue;
|
|
6
|
+
o[e] = t[e];
|
|
7
|
+
}
|
|
8
|
+
return o;
|
|
9
|
+
}
|
|
11
10
|
export {
|
|
12
|
-
|
|
11
|
+
r as default
|
|
13
12
|
};
|
|
14
13
|
//# sourceMappingURL=index239.js.map
|
package/dist/index239.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index239.js","sources":["../node_modules/
|
|
1
|
+
{"version":3,"file":"index239.js","sources":["../node_modules/@babel/runtime/helpers/esm/objectWithoutPropertiesLoose.js"],"sourcesContent":["function _objectWithoutPropertiesLoose(r, e) {\n if (null == r) return {};\n var t = {};\n for (var n in r) if ({}.hasOwnProperty.call(r, n)) {\n if (-1 !== e.indexOf(n)) continue;\n t[n] = r[n];\n }\n return t;\n}\nexport { _objectWithoutPropertiesLoose as default };"],"names":["_objectWithoutPropertiesLoose","r","e","t","n"],"mappings":"AAAA,SAASA,EAA8BC,GAAGC,GAAG;AAC3C,MAAYD,KAAR,KAAW,QAAO,CAAA;AACtB,MAAIE,IAAI,CAAA;AACR,WAASC,KAAKH,EAAG,KAAI,CAAA,EAAG,eAAe,KAAKA,GAAGG,CAAC,GAAG;AACjD,QAAWF,EAAE,QAAQE,CAAC,MAAlB,GAAqB;AACzB,IAAAD,EAAEC,CAAC,IAAIH,EAAEG,CAAC;AAAA,EACZ;AACA,SAAOD;AACT;","x_google_ignoreList":[0]}
|
package/dist/index24.js
CHANGED
|
@@ -1,228 +1,26 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
import { useCombobox as pe } from "./index201.js";
|
|
9
|
-
function m() {
|
|
10
|
-
return m = Object.assign ? Object.assign.bind() : function(t) {
|
|
11
|
-
for (var a = 1; a < arguments.length; a++) {
|
|
12
|
-
var c = arguments[a];
|
|
13
|
-
for (var i in c) ({}).hasOwnProperty.call(c, i) && (t[i] = c[i]);
|
|
14
|
-
}
|
|
15
|
-
return t;
|
|
16
|
-
}, m.apply(null, arguments);
|
|
17
|
-
}
|
|
18
|
-
const Ee = (t) => {
|
|
19
|
-
const [a, c] = S(!1), [i, E] = S(""), [n, b] = S(() => t?.defaultSelectedValue ? Array.isArray(t?.defaultSelectedValue) ? t?.defaultSelectedValue : [t.defaultSelectedValue] : []), C = de(null), N = T(void 0, "dropdown-label"), _ = T(void 0, "dropdown-listbox"), {
|
|
20
|
-
selectBy: f = "",
|
|
21
|
-
optionsUniqueBy: d = "",
|
|
22
|
-
displaySelected: q = !1,
|
|
23
|
-
dropDownOptions: D,
|
|
24
|
-
defaultText: v = "Select",
|
|
25
|
-
iconColor: I = "var(--color-gray-700)",
|
|
26
|
-
disabled: y = !1,
|
|
27
|
-
dropdownClassName: z = "",
|
|
28
|
-
hasError: k = !1,
|
|
29
|
-
errorMessage: J = "",
|
|
30
|
-
customDropdownContent: V = null,
|
|
31
|
-
isBorderless: Q = !1,
|
|
32
|
-
shouldShowSearch: P = !1,
|
|
33
|
-
searchPlaceholder: U = "Search...",
|
|
34
|
-
searchResultEmptyMessage: A = "No results found",
|
|
35
|
-
ariaLabel: W = "",
|
|
36
|
-
customSelectedValue: $ = ""
|
|
37
|
-
} = t;
|
|
38
|
-
j(() => {
|
|
39
|
-
const e = t?.defaultSelectedValue ? Array.isArray(t?.defaultSelectedValue) ? t?.defaultSelectedValue : [t.defaultSelectedValue] : [];
|
|
40
|
-
b(e);
|
|
41
|
-
}, [t?.defaultSelectedValue]), j(() => {
|
|
42
|
-
a || E("");
|
|
43
|
-
}, [a]);
|
|
44
|
-
const s = t?.type === "multi-select", B = () => i.trim() ? (D || []).filter((e) => (e?.[f]?.toString().toLowerCase() || "").includes(i.toLowerCase())) : D || [], x = (e) => {
|
|
45
|
-
b([e]), c(!1), t?.onOptionClick?.(e);
|
|
46
|
-
}, g = B(), {
|
|
47
|
-
listboxProps: F,
|
|
48
|
-
getOptionProps: H,
|
|
49
|
-
highlightedIndex: K,
|
|
50
|
-
containerProps: X,
|
|
51
|
-
inputProps: h
|
|
52
|
-
} = pe({
|
|
53
|
-
items: s ? [] : g,
|
|
54
|
-
// Only use for single-select
|
|
55
|
-
isOpen: a && !s,
|
|
56
|
-
onOpenChange: c,
|
|
57
|
-
onSelect: (e) => {
|
|
58
|
-
x(e);
|
|
59
|
-
},
|
|
60
|
-
listboxId: _,
|
|
61
|
-
disabled: s || y,
|
|
62
|
-
hasItems: g.length > 0
|
|
63
|
-
}), G = (e, r = !1) => s ? v : r && $ ? $ : e?.[f] || v, Y = () => {
|
|
64
|
-
b([]), t?.onClear?.();
|
|
65
|
-
}, O = (e, r = !1) => {
|
|
66
|
-
if (t?.renderOptionChip)
|
|
67
|
-
return t?.renderOptionChip(e, r);
|
|
68
|
-
if (s && n?.length > 0) {
|
|
69
|
-
const l = n[0]?.[f] || "", u = n.length - 1;
|
|
70
|
-
return /* @__PURE__ */ o.createElement("div", {
|
|
71
|
-
className: "option-chip flex items-center w-full"
|
|
72
|
-
}, /* @__PURE__ */ o.createElement("div", {
|
|
73
|
-
className: `${u > 0 ? "w-full" : "flex-1"} truncate`
|
|
74
|
-
}, `${v}: ${l}`), u > 0 && /* @__PURE__ */ o.createElement("div", {
|
|
75
|
-
className: "flex-shrink-0"
|
|
76
|
-
}, "+", u));
|
|
77
|
-
}
|
|
78
|
-
return /* @__PURE__ */ o.createElement("p", {
|
|
79
|
-
className: "option-chip flex flex-1 items-center justify-between"
|
|
80
|
-
}, G(e, r));
|
|
81
|
-
}, L = () => /* @__PURE__ */ o.createElement("div", {
|
|
82
|
-
className: " w-full relative flex items-center border-b border-[var(--color-gray-300)]"
|
|
83
|
-
}, /* @__PURE__ */ o.createElement(fe, {
|
|
84
|
-
leftIcon: {
|
|
85
|
-
name: "search",
|
|
86
|
-
position: "left",
|
|
87
|
-
style: {
|
|
88
|
-
color: "var(--color-gray-500)"
|
|
89
|
-
}
|
|
1
|
+
import e from "react";
|
|
2
|
+
import { Badge as c } from "./index10.js";
|
|
3
|
+
const m = (t) => {
|
|
4
|
+
const {
|
|
5
|
+
label: a,
|
|
6
|
+
color: l,
|
|
7
|
+
onClick: r = () => {
|
|
90
8
|
},
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
9
|
+
tag: o
|
|
10
|
+
} = t;
|
|
11
|
+
return /* @__PURE__ */ e.createElement("div", {
|
|
12
|
+
className: "se-design-color-coded-label flex items-center gap-2",
|
|
13
|
+
onClick: r
|
|
14
|
+
}, l && /* @__PURE__ */ e.createElement("span", {
|
|
15
|
+
className: "w-[15px] h-[15px] rounded-[3px] inline-block",
|
|
94
16
|
style: {
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
border: "none",
|
|
101
|
-
outline: "none"
|
|
102
|
-
},
|
|
103
|
-
automationId: "se-design-dropdown-search"
|
|
104
|
-
})), Z = (e, r) => {
|
|
105
|
-
const l = e[f], u = n[0]?.[f] || v, se = d?.length ? e[d] == n[0]?.[d] : !0, p = q && l === u && se, ce = K === r, ie = s ? {} : H(r, p);
|
|
106
|
-
return /* @__PURE__ */ o.createElement("div", m({
|
|
107
|
-
key: e.id || e.value,
|
|
108
|
-
className: `option break-words px-3 py-2 hover:bg-gray-100 cursor-pointer select-none flex items-center justify-between ${p ? "selected" : ""} ${ce ? "bg-gray-100" : ""}`,
|
|
109
|
-
onClick: () => x(e),
|
|
110
|
-
onKeyDown: (w) => {
|
|
111
|
-
(w.key === "Enter" || w.key === " ") && (w.preventDefault(), x(e));
|
|
112
|
-
},
|
|
113
|
-
tabIndex: -1,
|
|
114
|
-
"data-automation-id": `dropdown-option-${e?.automationId || r}`
|
|
115
|
-
}, ie, {
|
|
116
|
-
"aria-selected": p ? "true" : "false"
|
|
117
|
-
}), O({
|
|
118
|
-
...e,
|
|
119
|
-
isOptionSelected: p
|
|
120
|
-
}, !1), p && /* @__PURE__ */ o.createElement(M, {
|
|
121
|
-
name: "checkmark",
|
|
122
|
-
stroke: I
|
|
123
|
-
}));
|
|
124
|
-
}, ee = () => /* @__PURE__ */ o.createElement("div", m({
|
|
125
|
-
className: "dropdown-content dropdown-options",
|
|
126
|
-
"aria-label": "Dropdown options"
|
|
127
|
-
}, F), P && L(), /* @__PURE__ */ o.createElement("div", {
|
|
128
|
-
className: "flex flex-col max-h-80 overflow-y-auto"
|
|
129
|
-
}, g.length > 0 ? g.map((e, r) => Z(e, r)) : /* @__PURE__ */ o.createElement("div", {
|
|
130
|
-
className: "px-3 py-4 text-center text-[var(--color-gray-700)] text-sm",
|
|
131
|
-
role: "status",
|
|
132
|
-
"aria-live": "polite"
|
|
133
|
-
}, A))), te = (e, r) => {
|
|
134
|
-
let l = [];
|
|
135
|
-
e ? l = [...n, r] : l = n?.filter((u) => u[d] !== r[d]), b(l);
|
|
136
|
-
}, oe = () => {
|
|
137
|
-
C.current?.togglePopover(), t?.onApply?.(n);
|
|
138
|
-
}, re = (e) => {
|
|
139
|
-
const r = n.some((l) => l[d] === e[d]);
|
|
140
|
-
return /* @__PURE__ */ o.createElement("div", {
|
|
141
|
-
key: e.id || e.value,
|
|
142
|
-
className: "option px-3 py-2 hover:bg-gray-100 cursor-pointer select-none flex items-center justify-between"
|
|
143
|
-
}, /* @__PURE__ */ o.createElement(me, {
|
|
144
|
-
automationId: "checkbox",
|
|
145
|
-
className: "checkbox",
|
|
146
|
-
defaultChecked: r,
|
|
147
|
-
onChange: (l) => te(l, e),
|
|
148
|
-
label: e?.label
|
|
149
|
-
}));
|
|
150
|
-
}, le = () => {
|
|
151
|
-
const e = B();
|
|
152
|
-
return /* @__PURE__ */ o.createElement("div", {
|
|
153
|
-
className: "dropdown-content dropdown-options",
|
|
154
|
-
role: "listbox",
|
|
155
|
-
"aria-label": "Multi-select dropdown options",
|
|
156
|
-
"aria-multiselectable": "true"
|
|
157
|
-
}, P && L(), /* @__PURE__ */ o.createElement("div", {
|
|
158
|
-
className: "flex flex-col max-h-80 overflow-y-auto"
|
|
159
|
-
}, e.length > 0 ? e.map((r) => re(r)) : /* @__PURE__ */ o.createElement("div", {
|
|
160
|
-
className: "px-3 py-4 text-center text-[var(--color-gray-700)] text-sm",
|
|
161
|
-
role: "status",
|
|
162
|
-
"aria-live": "polite"
|
|
163
|
-
}, A)), /* @__PURE__ */ o.createElement("div", {
|
|
164
|
-
className: "flex items-center justify-end gap-4 p-3 border-t border-[var(--color-gray-200)]"
|
|
165
|
-
}, /* @__PURE__ */ o.createElement(R, {
|
|
166
|
-
label: "Clear",
|
|
167
|
-
type: "link",
|
|
168
|
-
size: "sm",
|
|
169
|
-
onClick: Y,
|
|
170
|
-
automationId: "se-design-dropdown-clear-button"
|
|
171
|
-
}), /* @__PURE__ */ o.createElement(R, {
|
|
172
|
-
label: "Apply",
|
|
173
|
-
type: "primary",
|
|
174
|
-
size: "sm",
|
|
175
|
-
onClick: oe,
|
|
176
|
-
automationId: "se-design-dropdown-apply-button"
|
|
177
|
-
})));
|
|
178
|
-
}, ae = () => {
|
|
179
|
-
const e = a ? "border-[var(--color-blue-500)]" : y ? "border-[var(--color-gray-300)]" : "border-[var(--color-gray-600)]", r = k ? "border-[var(--color-red-500)]" : "", l = `dropdown-src-element bg-[var(--color-white)] flex px-3 py-2 ${Q ? "border-0" : `border rounded-md ${r || e}`} flex items-center ${z}`;
|
|
180
|
-
return /* @__PURE__ */ o.createElement("div", {
|
|
181
|
-
className: l
|
|
182
|
-
}, /* @__PURE__ */ o.createElement("div", {
|
|
183
|
-
className: "flex-1 min-w-0",
|
|
184
|
-
"data-automation-id": t?.dropDownSelectAutomationId || "selected-dropdown-value"
|
|
185
|
-
}, O(n[0], !0)), /* @__PURE__ */ o.createElement("div", {
|
|
186
|
-
className: "flex-shrink-0 ml-2",
|
|
187
|
-
"aria-hidden": "true"
|
|
188
|
-
}, /* @__PURE__ */ o.createElement(M, {
|
|
189
|
-
name: "chevron",
|
|
190
|
-
rotation: a ? "180" : "0",
|
|
191
|
-
className: "transition-transform",
|
|
192
|
-
stroke: I
|
|
193
|
-
})));
|
|
194
|
-
}, ne = () => W || "Select option";
|
|
195
|
-
return /* @__PURE__ */ o.createElement("div", {
|
|
196
|
-
className: `se-design-dropdown-container${t?.className ? ` ${t?.className}` : ""}`,
|
|
197
|
-
style: t?.style
|
|
198
|
-
}, t?.label && /* @__PURE__ */ o.createElement("div", {
|
|
199
|
-
id: N,
|
|
200
|
-
className: "se-design-dropdown-label mb-[3px] text-[var(--color-gray-700)] text-sm"
|
|
201
|
-
}, t?.label), /* @__PURE__ */ o.createElement("div", m({
|
|
202
|
-
style: t?.style,
|
|
203
|
-
className: `${y ? "bg-[var(--color-gray-50)] rounded-md cursor-not-allowed" : ""}`
|
|
204
|
-
}, s ? {} : X), /* @__PURE__ */ o.createElement(ue, m({
|
|
205
|
-
ref: C,
|
|
206
|
-
isPopoverOpen: a,
|
|
207
|
-
renderPopoverContents: V || (s ? le : ee),
|
|
208
|
-
contentWidth: "full",
|
|
209
|
-
renderPopoverSrcElement: ae,
|
|
210
|
-
onPopoverToggle: (e) => c(e),
|
|
211
|
-
disabled: y,
|
|
212
|
-
automationId: t?.dropDownSrcAutomationId,
|
|
213
|
-
popoverContentAutomationId: t?.dropDownContentAutomationId,
|
|
214
|
-
ariaLabelledBy: t?.label ? N : void 0,
|
|
215
|
-
ariaLabel: t?.label ? void 0 : ne(),
|
|
216
|
-
sourceRole: "combobox"
|
|
217
|
-
}, !s && h ? {
|
|
218
|
-
"aria-activedescendant": h["aria-activedescendant"],
|
|
219
|
-
"aria-controls": h["aria-controls"],
|
|
220
|
-
"aria-expanded": h["aria-expanded"]
|
|
221
|
-
} : {}))), k && /* @__PURE__ */ o.createElement("div", {
|
|
222
|
-
className: "text-[var(--color-red-500)] text-sm"
|
|
223
|
-
}, J));
|
|
17
|
+
backgroundColor: l
|
|
18
|
+
}
|
|
19
|
+
}), /* @__PURE__ */ e.createElement("div", null, a), o && /* @__PURE__ */ e.createElement(c, {
|
|
20
|
+
label: o
|
|
21
|
+
}));
|
|
224
22
|
};
|
|
225
23
|
export {
|
|
226
|
-
|
|
24
|
+
m as ColorCodedLabel
|
|
227
25
|
};
|
|
228
26
|
//# sourceMappingURL=index24.js.map
|
package/dist/index24.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index24.js","sources":["../src/components/Dropdown/index.tsx"],"sourcesContent":["import React, { FC, useState, useRef, useEffect } from 'react';\n\nimport { Popover, PopoverHandle } from 'src/components/Popover';\nimport { Icon } from 'components/Icon';\nimport { Checkbox } from '../Checkbox';\nimport { Button } from '../Button';\nimport { InputWithIcon } from '../InputWithIcon';\nimport { useStableId } from '../../utils/useStableId';\nimport { useCombobox } from '../../utils/a11y/useCombobox';\n\ntype DropdownValue = {\n [key: string]: any;\n};\n\ntype DropdownProps = {\n label?: string;\n ariaLabel?: string;\n type: 'select' | 'multi-select';\n dropDownOptions?: DropdownValue[];\n defaultText?: string;\n selectBy?: string;\n optionsUniqueBy?: string;\n displaySelected?: boolean;\n defaultSelectedValue?: DropdownValue | DropdownValue[];\n customSelectedValue?: string;\n onOptionClick?: (selectedValue: DropdownValue) => void;\n style?: React.CSSProperties;\n renderOptionChip?: (option: DropdownValue, srcOption: boolean) => React.ReactNode;\n className?: string;\n iconColor?: string;\n disabled?: boolean;\n dropdownClassName?: string;\n hasError?: boolean;\n errorMessage?: string;\n onApply?: (selectedValue: DropdownValue[]) => void;\n onClear?: () => void;\n customDropdownContent?: () => React.ReactNode;\n isBorderless?: boolean;\n dropDownSrcAutomationId?: string;\n dropDownSelectAutomationId?: string;\n dropDownContentAutomationId?: string;\n shouldShowSearch?: boolean;\n searchPlaceholder?: string;\n searchResultEmptyMessage?: string;\n};\n\nexport const Dropdown: FC<DropdownProps> = (props) => {\n const [isDropDownOpen, setIsDropDownOpen] = useState(false);\n const [searchQuery, setSearchQuery] = useState('');\n const [selectedDropDownValues, setSelectedDropDownValues] = useState<DropdownValue[]>(() =>\n props?.defaultSelectedValue\n ? Array.isArray(props?.defaultSelectedValue)\n ? props?.defaultSelectedValue\n : [props.defaultSelectedValue]\n : []\n );\n const popoverRef = useRef<HTMLDivElement & PopoverHandle>(null);\n const labelId = useStableId(undefined, 'dropdown-label');\n const listboxId = useStableId(undefined, 'dropdown-listbox');\n\n const {\n selectBy = '',\n optionsUniqueBy = '',\n displaySelected = false,\n dropDownOptions,\n defaultText = 'Select',\n iconColor = 'var(--color-gray-700)',\n disabled = false,\n dropdownClassName = '',\n hasError = false,\n errorMessage = '',\n customDropdownContent = null,\n isBorderless = false,\n shouldShowSearch = false,\n searchPlaceholder = 'Search...',\n searchResultEmptyMessage = 'No results found',\n ariaLabel = '',\n customSelectedValue = ''\n } = props;\n\n useEffect(() => {\n const newValues = props?.defaultSelectedValue\n ? Array.isArray(props?.defaultSelectedValue)\n ? props?.defaultSelectedValue\n : [props.defaultSelectedValue]\n : [];\n setSelectedDropDownValues(newValues);\n }, [props?.defaultSelectedValue]);\n\n useEffect(() => {\n if (!isDropDownOpen) {\n setSearchQuery('');\n }\n }, [isDropDownOpen]);\n\n const isMultiSelect = props?.type === 'multi-select';\n\n const getFilteredOptions = () => {\n if (!searchQuery.trim()) {\n return dropDownOptions || [];\n }\n return (dropDownOptions || []).filter((option) => {\n const optionValue = option?.[selectBy]?.toString().toLowerCase() || '';\n return optionValue.includes(searchQuery.toLowerCase());\n });\n };\n\n const handleDropDownOptionClick = (dropDownOption: any) => {\n setSelectedDropDownValues([dropDownOption]);\n setIsDropDownOpen(false);\n props?.onOptionClick?.(dropDownOption);\n };\n\n // Use useCombobox hook for keyboard navigation (only for single-select)\n const filteredOptions = getFilteredOptions();\n const {\n listboxProps,\n getOptionProps,\n highlightedIndex,\n containerProps: comboboxContainerProps,\n inputProps: comboboxInputProps\n } = useCombobox({\n items: isMultiSelect ? [] : filteredOptions, // Only use for single-select\n isOpen: isDropDownOpen && !isMultiSelect,\n onOpenChange: setIsDropDownOpen,\n onSelect: (item: DropdownValue) => {\n handleDropDownOptionClick(item);\n },\n listboxId,\n disabled: isMultiSelect || disabled,\n hasItems: filteredOptions.length > 0\n });\n\n const getSelectedDropDownValue = (option: DropdownValue, isSrcOption: boolean = false) => {\n if (isMultiSelect) {\n return defaultText;\n }\n\n // if custom selected value is provided, use it instead of the option value\n if (isSrcOption && customSelectedValue) {\n return customSelectedValue;\n }\n\n return option?.[selectBy] || defaultText;\n };\n\n const clearSelectedDropDownValues = () => {\n setSelectedDropDownValues([]);\n props?.onClear?.();\n };\n\n const optionChip = (option: DropdownValue, srcOption: boolean = false) => {\n if (props?.renderOptionChip) {\n return props?.renderOptionChip(option, srcOption);\n }\n\n if (isMultiSelect && selectedDropDownValues?.length > 0) {\n const firstSelectedLabel = selectedDropDownValues[0]?.[selectBy] || '';\n const remainingCount = selectedDropDownValues.length - 1;\n\n // For multiple selections: text takes remaining space, count takes minimum space needed\n return (\n <div className={`option-chip flex items-center w-full`}>\n <div\n className={`${remainingCount > 0 ? 'w-full' : 'flex-1'} truncate`}\n >{`${defaultText}: ${firstSelectedLabel}`}</div>\n {remainingCount > 0 && <div className=\"flex-shrink-0\">+{remainingCount}</div>}\n </div>\n );\n }\n\n return (\n <p className={`option-chip flex flex-1 items-center justify-between`}>\n {getSelectedDropDownValue(option, srcOption)}\n </p>\n );\n };\n\n const renderSearchBar = () => {\n return (\n <div className=\" w-full relative flex items-center border-b border-[var(--color-gray-300)]\">\n <InputWithIcon\n leftIcon={{ name: 'search', position: 'left', style: { color: 'var(--color-gray-500)' } }}\n value={searchQuery}\n onChange={(value) => setSearchQuery(value)}\n placeholder={searchPlaceholder}\n style={{ margin: 0, gap: 0 }}\n inputStyle={{ width: '100%', border: 'none', outline: 'none' }}\n automationId=\"se-design-dropdown-search\"\n />\n </div>\n );\n };\n\n const dropDownOptionJsx = (dropDownOption: DropdownValue, index: number) => {\n const optionTxt = dropDownOption[selectBy];\n const dropDownSelectedValue = selectedDropDownValues[0]?.[selectBy] || defaultText;\n const selectByUniqueId = optionsUniqueBy?.length\n ? dropDownOption[optionsUniqueBy] == selectedDropDownValues[0]?.[optionsUniqueBy]\n : true;\n const isOptionSelected = displaySelected && optionTxt === dropDownSelectedValue && selectByUniqueId;\n const isHighlighted = highlightedIndex === index;\n const optionProps = !isMultiSelect ? getOptionProps(index, isOptionSelected) : {};\n \n return (\n <div\n key={dropDownOption.id || dropDownOption.value}\n className={`option break-words px-3 py-2 hover:bg-gray-100 cursor-pointer select-none flex items-center justify-between ${\n isOptionSelected ? 'selected' : ''\n } ${isHighlighted ? 'bg-gray-100' : ''}`}\n onClick={() => handleDropDownOptionClick(dropDownOption)}\n onKeyDown={(e) => {\n if (e.key === 'Enter' || e.key === ' ') {\n e.preventDefault();\n handleDropDownOptionClick(dropDownOption);\n }\n }}\n tabIndex={-1}\n data-automation-id={`dropdown-option-${dropDownOption?.automationId || index}`}\n {...optionProps}\n aria-selected={isOptionSelected ? 'true' : 'false'}\n >\n {optionChip({ ...dropDownOption, isOptionSelected }, false)}\n {isOptionSelected && <Icon name=\"checkmark\" stroke={iconColor} />}\n </div>\n );\n };\n\n const renderDropdownContents = () => {\n return (\n <div \n className=\"dropdown-content dropdown-options\" \n aria-label=\"Dropdown options\"\n {...listboxProps}\n >\n {shouldShowSearch && renderSearchBar()}\n <div className=\"flex flex-col max-h-80 overflow-y-auto\">\n {filteredOptions.length > 0 ? (\n filteredOptions.map((dropDownOption, index) => dropDownOptionJsx(dropDownOption, index))\n ) : (\n <div\n className=\"px-3 py-4 text-center text-[var(--color-gray-700)] text-sm\"\n role=\"status\"\n aria-live=\"polite\"\n >\n {searchResultEmptyMessage}\n </div>\n )}\n </div>\n </div>\n );\n };\n\n const handleMultiSelectDropdownOptionClick = (isSelected: boolean, dropDownOption: DropdownValue) => {\n let newSelectedDropDownValues: DropdownValue[] = [];\n if (isSelected) {\n newSelectedDropDownValues = [...selectedDropDownValues, dropDownOption];\n } else {\n newSelectedDropDownValues = selectedDropDownValues?.filter(\n (option) => option[optionsUniqueBy] !== dropDownOption[optionsUniqueBy]\n );\n }\n setSelectedDropDownValues(newSelectedDropDownValues);\n };\n\n const handleApplySelectedDropDownValues = () => {\n popoverRef.current?.togglePopover();\n props?.onApply?.(selectedDropDownValues);\n };\n\n const multiSelectDropdownOptionJSX = (dropDownOption: DropdownValue) => {\n const isOptionSelected = selectedDropDownValues.some(\n (option) => option[optionsUniqueBy] === dropDownOption[optionsUniqueBy]\n );\n return (\n <div\n key={dropDownOption.id || dropDownOption.value}\n className=\"option px-3 py-2 hover:bg-gray-100 cursor-pointer select-none flex items-center justify-between\"\n >\n <Checkbox\n automationId=\"checkbox\"\n className=\"checkbox\"\n defaultChecked={isOptionSelected}\n onChange={(value) => handleMultiSelectDropdownOptionClick(value, dropDownOption)}\n label={dropDownOption?.label}\n />\n </div>\n );\n };\n\n const renderMultiSelectDropdownContents = () => {\n const filteredOptions = getFilteredOptions();\n return (\n <div\n className=\"dropdown-content dropdown-options\"\n role=\"listbox\"\n aria-label=\"Multi-select dropdown options\"\n aria-multiselectable=\"true\"\n >\n {shouldShowSearch && renderSearchBar()}\n <div className=\"flex flex-col max-h-80 overflow-y-auto\">\n {filteredOptions.length > 0 ? (\n filteredOptions.map((dropDownOption) => multiSelectDropdownOptionJSX(dropDownOption))\n ) : (\n <div\n className=\"px-3 py-4 text-center text-[var(--color-gray-700)] text-sm\"\n role=\"status\"\n aria-live=\"polite\"\n >\n {searchResultEmptyMessage}\n </div>\n )}\n </div>\n <div className=\"flex items-center justify-end gap-4 p-3 border-t border-[var(--color-gray-200)]\">\n <Button label=\"Clear\" type=\"link\" size=\"sm\" onClick={clearSelectedDropDownValues} automationId=\"se-design-dropdown-clear-button\" />\n <Button label=\"Apply\" type=\"primary\" size=\"sm\" onClick={handleApplySelectedDropDownValues} automationId=\"se-design-dropdown-apply-button\" />\n </div>\n </div>\n );\n };\n\n const renderDropdownSelect = () => {\n const borderColor = isDropDownOpen\n ? 'border-[var(--color-blue-500)]'\n : disabled\n ? 'border-[var(--color-gray-300)]'\n : 'border-[var(--color-gray-600)]';\n const errorBorderColor = hasError ? 'border-[var(--color-red-500)]' : '';\n const dropDownSelectClass = `dropdown-src-element bg-[var(--color-white)] flex px-3 py-2 ${\n isBorderless ? 'border-0' : `border rounded-md ${errorBorderColor ? errorBorderColor : borderColor}`\n } flex items-center ${dropdownClassName}`;\n\n return (\n <div className={dropDownSelectClass}>\n <div\n className=\"flex-1 min-w-0\"\n data-automation-id={props?.dropDownSelectAutomationId || 'selected-dropdown-value'}\n >\n {optionChip(selectedDropDownValues[0], true)}\n </div>\n <div className=\"flex-shrink-0 ml-2\" aria-hidden=\"true\">\n <Icon\n name={'chevron'}\n rotation={isDropDownOpen ? '180' : '0'}\n className={`transition-transform`}\n stroke={iconColor}\n />\n </div>\n </div>\n );\n };\n\n const getDropdownAriaLabel = () => {\n return ariaLabel || `Select option`;\n };\n\n return (\n <div\n className={`se-design-dropdown-container${props?.className ? ` ${props?.className}` : ''}`}\n style={props?.style}\n >\n {props?.label && (\n <div id={labelId} className=\"se-design-dropdown-label mb-[3px] text-[var(--color-gray-700)] text-sm\">\n {props?.label}\n </div>\n )}\n <div\n style={props?.style}\n className={`${disabled ? 'bg-[var(--color-gray-50)] rounded-md cursor-not-allowed' : ''}`}\n {...(!isMultiSelect ? comboboxContainerProps : {})}\n >\n <Popover\n ref={popoverRef}\n isPopoverOpen={isDropDownOpen}\n renderPopoverContents={\n customDropdownContent\n ? customDropdownContent\n : isMultiSelect\n ? renderMultiSelectDropdownContents\n : renderDropdownContents\n }\n contentWidth={'full'}\n renderPopoverSrcElement={renderDropdownSelect}\n onPopoverToggle={(value) => setIsDropDownOpen(value)}\n disabled={disabled}\n automationId={props?.dropDownSrcAutomationId}\n popoverContentAutomationId={props?.dropDownContentAutomationId}\n ariaLabelledBy={props?.label ? labelId : undefined}\n ariaLabel={props?.label ? undefined : getDropdownAriaLabel()}\n sourceRole=\"combobox\"\n {...(!isMultiSelect && comboboxInputProps ? {\n 'aria-activedescendant': comboboxInputProps['aria-activedescendant'],\n 'aria-controls': comboboxInputProps['aria-controls'],\n 'aria-expanded': comboboxInputProps['aria-expanded']\n } : {})}\n />\n </div>\n {hasError && <div className=\"text-[var(--color-red-500)] text-sm\">{errorMessage}</div>}\n </div>\n );\n};\n"],"names":["Dropdown","props","isDropDownOpen","setIsDropDownOpen","useState","searchQuery","setSearchQuery","selectedDropDownValues","setSelectedDropDownValues","defaultSelectedValue","Array","isArray","popoverRef","useRef","labelId","useStableId","undefined","listboxId","selectBy","optionsUniqueBy","displaySelected","dropDownOptions","defaultText","iconColor","disabled","dropdownClassName","hasError","errorMessage","customDropdownContent","isBorderless","shouldShowSearch","searchPlaceholder","searchResultEmptyMessage","ariaLabel","customSelectedValue","useEffect","newValues","isMultiSelect","type","getFilteredOptions","trim","filter","option","toString","toLowerCase","includes","handleDropDownOptionClick","dropDownOption","onOptionClick","filteredOptions","listboxProps","getOptionProps","highlightedIndex","containerProps","comboboxContainerProps","inputProps","comboboxInputProps","useCombobox","items","isOpen","onOpenChange","onSelect","item","hasItems","length","getSelectedDropDownValue","isSrcOption","clearSelectedDropDownValues","onClear","optionChip","srcOption","renderOptionChip","firstSelectedLabel","remainingCount","React","createElement","className","renderSearchBar","InputWithIcon","leftIcon","name","position","style","color","value","onChange","placeholder","margin","gap","inputStyle","width","border","outline","automationId","dropDownOptionJsx","index","optionTxt","dropDownSelectedValue","selectByUniqueId","isOptionSelected","isHighlighted","optionProps","_extends","key","id","onClick","onKeyDown","e","preventDefault","tabIndex","Icon","stroke","renderDropdownContents","map","role","handleMultiSelectDropdownOptionClick","isSelected","newSelectedDropDownValues","handleApplySelectedDropDownValues","current","togglePopover","onApply","multiSelectDropdownOptionJSX","some","Checkbox","defaultChecked","label","renderMultiSelectDropdownContents","Button","size","renderDropdownSelect","borderColor","errorBorderColor","dropDownSelectClass","dropDownSelectAutomationId","rotation","getDropdownAriaLabel","Popover","ref","isPopoverOpen","renderPopoverContents","contentWidth","renderPopoverSrcElement","onPopoverToggle","dropDownSrcAutomationId","popoverContentAutomationId","dropDownContentAutomationId","ariaLabelledBy","sourceRole"],"mappings":";;;;;;;;;;;;;;;;;AA8CO,MAAMA,KAA+BC,CAAUA,MAAA;AACpD,QAAM,CAACC,GAAgBC,CAAiB,IAAIC,EAAS,EAAK,GACpD,CAACC,GAAaC,CAAc,IAAIF,EAAS,EAAE,GAC3C,CAACG,GAAwBC,CAAyB,IAAIJ,EAA0B,MACpFH,GAAOQ,uBACHC,MAAMC,QAAQV,GAAOQ,oBAAoB,IACv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AAI1F;AAAAA,IAAS8D,WAAU;AAAA,EAAA,GACzB3E,GAAO6H,KACL,GAEPnD,gBAAAA,EAAAA,cAAA,OAAA2B,EAAA;AAAA,IACEpB,OAAOjF,GAAOiF;AAAAA,IACdN,WAAW,GAAGpD,IAAW,4DAA4D,EAAE;AAAA,EAAA,GACjFa,IAAyC,CAAE,IAA3BiB,CAA2B,GAEjDoB,gBAAAA,EAAAC,cAAC8D,IAAOnC,EAAA;AAAA,IACNoC,KAAK9H;AAAAA,IACL+H,eAAezI;AAAAA,IACf0I,uBACEhH,MAEIS,IACA0F,KACAf;AAAAA,IAEN6B,cAAc;AAAA,IACdC,yBAAyBZ;AAAAA,IACzBa,iBAAkB3D,CAAUjF,MAAAA,EAAkBiF,CAAK;AAAA,IACnD5D,UAAAA;AAAAA,IACAqE,cAAc5F,GAAO+I;AAAAA,IACrBC,4BAA4BhJ,GAAOiJ;AAAAA,IACnCC,gBAAgBlJ,GAAO6H,QAAQhH,IAAUE;AAAAA,IACzCiB,WAAWhC,GAAO6H,QAAQ9G,SAAYwH,GAAqB;AAAA,IAC3DY,YAAW;AAAA,EAAA,GACN,CAAC/G,KAAiBmB,IAAqB;AAAA,IAC1C,yBAAyBA,EAAmB,uBAAuB;AAAA,IACnE,iBAAiBA,EAAmB,eAAe;AAAA,IACnD,iBAAiBA,EAAmB,eAAe;AAAA,EAAA,IACjD,CAAA,CAAE,CACP,CACE,GACJ9B,KAAYiD,gBAAAA,EAAAA,cAAA,OAAA;AAAA,IAAKC,WAAU;AAAA,EAAA,GAAuCjD,CAAkB,CAClF;AAET;"}
|
|
1
|
+
{"version":3,"file":"index24.js","sources":["../src/components/ColorCodedLabel/index.tsx"],"sourcesContent":["import React, { FC } from 'react';\nimport { Badge } from 'src/components/Badge';\n\nexport type ColorCodedLabelProps = {\n label: string;\n tag?: string;\n color?: string;\n onClick?: () => void;\n};\n\nexport const ColorCodedLabel: FC<ColorCodedLabelProps> = (props) => {\n const { label, color, onClick = () => {}, tag } = props;\n return (\n <div\n className=\"se-design-color-coded-label flex items-center gap-2\"\n onClick={onClick}\n >\n {color && <span className=\"w-[15px] h-[15px] rounded-[3px] inline-block\" style={{ backgroundColor: color }}></span>}\n <div>{label}</div>\n {tag && <Badge label={tag} />}\n </div>\n );\n};\n"],"names":["React__default","Badge","ColorCodedLabel","props","label","color","onClick","tag","React","createElement","className","style","backgroundColor"],"mappings":"AAUO,OAAAA,OAAA;AAAA,SAAA,SAAAC,SAAA;AAAA,MAAMC,IAA6CC,CAAAA,MAAU;AAClE,QAAM;AAAA,IAAEC,OAAAA;AAAAA,IAAOC,OAAAA;AAAAA,IAAOC,SAAAA,IAAUA,MAAM;AAAA,IAAC;AAAA,IAAGC,KAAAA;AAAAA,EAAAA,IAAQJ;AAClD,SACEK,gBAAAA,EAAAC,cAAA,OAAA;AAAA,IACEC,WAAU;AAAA,IACVJ,SAAAA;AAAAA,EAAAA,GAECD,KAASG,gBAAAA,EAAAC,cAAA,QAAA;AAAA,IAAMC,WAAU;AAAA,IAA+CC,OAAO;AAAA,MAAEC,iBAAiBP;AAAAA,IAAAA;AAAAA,EAAM,CAAS,GAClHG,gBAAAA,EAAAC,cAAA,OAAA,MAAML,CAAW,GAChBG,KAAOC,gBAAAA,EAAAC,cAACR,GAAK;AAAA,IAACG,OAAOG;AAAAA,EAAAA,CAAM,CACzB;AAET;"}
|
package/dist/index240.js
CHANGED
|
@@ -1,7 +1,11 @@
|
|
|
1
|
-
function e(
|
|
2
|
-
return e = Object.
|
|
3
|
-
|
|
4
|
-
|
|
1
|
+
function e() {
|
|
2
|
+
return e = Object.assign ? Object.assign.bind() : function(t) {
|
|
3
|
+
for (var n = 1; n < arguments.length; n++) {
|
|
4
|
+
var a = arguments[n];
|
|
5
|
+
for (var r in a) ({}).hasOwnProperty.call(a, r) && (t[r] = a[r]);
|
|
6
|
+
}
|
|
7
|
+
return t;
|
|
8
|
+
}, e.apply(null, arguments);
|
|
5
9
|
}
|
|
6
10
|
export {
|
|
7
11
|
e as default
|
package/dist/index240.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index240.js","sources":["../node_modules/@babel/runtime/helpers/esm/
|
|
1
|
+
{"version":3,"file":"index240.js","sources":["../node_modules/@babel/runtime/helpers/esm/extends.js"],"sourcesContent":["function _extends() {\n return _extends = Object.assign ? Object.assign.bind() : function (n) {\n for (var e = 1; e < arguments.length; e++) {\n var t = arguments[e];\n for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]);\n }\n return n;\n }, _extends.apply(null, arguments);\n}\nexport { _extends as default };"],"names":["_extends","n","e","t"],"mappings":"AAAA,SAASA,IAAW;AAClB,SAAOA,IAAW,OAAO,SAAS,OAAO,OAAO,KAAI,IAAK,SAAUC,GAAG;AACpE,aAASC,IAAI,GAAGA,IAAI,UAAU,QAAQA,KAAK;AACzC,UAAIC,IAAI,UAAUD,CAAC;AACnB,eAAS,KAAKC,EAAG,EAAC,CAAA,GAAI,eAAe,KAAKA,GAAG,CAAC,MAAMF,EAAE,CAAC,IAAIE,EAAE,CAAC;AAAA,IAChE;AACA,WAAOF;AAAA,EACT,GAAGD,EAAS,MAAM,MAAM,SAAS;AACnC;","x_google_ignoreList":[0]}
|