bitboss-ui 2.0.23 → 2.0.25
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/index.js +138 -140
- package/dist/index10.js +78 -8
- package/dist/{index101.js → index100.js} +2 -3
- package/dist/{index103.js → index102.js} +2 -3
- package/dist/index104.js +289 -0
- package/dist/{index107.js → index106.js} +8 -9
- package/dist/{index109.js → index108.js} +2 -3
- package/dist/index11.js +35 -75
- package/dist/{index111.js → index110.js} +2 -3
- package/dist/{index113.js → index112.js} +2 -3
- package/dist/{index115.js → index114.js} +2 -3
- package/dist/{index117.js → index116.js} +8 -9
- package/dist/{index119.js → index118.js} +1 -2
- package/dist/index12.js +189 -37
- package/dist/index120.js +42 -0
- package/dist/index121.js +38 -35
- package/dist/index122.js +38 -39
- package/dist/index123.js +42 -40
- package/dist/index124.js +31 -44
- package/dist/index125.js +2 -36
- package/dist/index126.js +21 -3
- package/dist/index127.js +2 -22
- package/dist/index128.js +312 -3
- package/dist/index129.js +21 -310
- package/dist/index13.js +78 -190
- package/dist/index130.js +2 -25
- package/dist/index131.js +5 -3
- package/dist/index132.js +9 -6
- package/dist/index133.js +5 -9
- package/dist/index134.js +3 -7
- package/dist/index135.js +1 -2
- package/dist/index136.js +1 -2
- package/dist/index137.js +1 -2
- package/dist/index138.js +1 -2
- package/dist/index139.js +1 -2
- package/dist/index140.js +1 -2
- package/dist/index141.js +1 -2
- package/dist/index142.js +1 -2
- package/dist/index143.js +1 -2
- package/dist/index144.js +1 -2
- package/dist/index145.js +1 -2
- package/dist/index146.js +1 -2
- package/dist/index147.js +1 -2
- package/dist/index148.js +1 -2
- package/dist/index149.js +1 -2
- package/dist/{index16.js → index15.js} +3 -4
- package/dist/index150.js +1 -2
- package/dist/index151.js +1 -2
- package/dist/index152.js +1 -2
- package/dist/index153.js +1 -2
- package/dist/index154.js +1 -2
- package/dist/index155.js +1 -2
- package/dist/index156.js +1 -2
- package/dist/index157.js +1 -2
- package/dist/index158.js +1 -2
- package/dist/index159.js +1 -2
- package/dist/index160.js +2 -3
- package/dist/{index161.js → index162.js} +0 -1
- package/dist/index164.js +5 -0
- package/dist/index165.js +1 -2
- package/dist/index166.js +1 -2
- package/dist/index167.js +1 -2
- package/dist/index168.js +1 -2
- package/dist/index169.js +1 -2
- package/dist/{index18.js → index17.js} +3 -4
- package/dist/index170.js +2 -3
- package/dist/index172.js +4 -0
- package/dist/index173.js +3 -3
- package/dist/index174.js +1 -2
- package/dist/index175.js +1 -2
- package/dist/index176.js +1 -2
- package/dist/index177.js +1 -2
- package/dist/index178.js +1 -2
- package/dist/index179.js +1 -2
- package/dist/index180.js +1 -2
- package/dist/index181.js +1 -2
- package/dist/index182.js +1 -2
- package/dist/index183.js +1 -2
- package/dist/index184.js +1 -2
- package/dist/{index185.js → index186.js} +0 -1
- package/dist/index188.js +5 -0
- package/dist/index189.js +1 -2
- package/dist/{index20.js → index19.js} +17 -19
- package/dist/index190.js +1 -2
- package/dist/index191.js +1 -2
- package/dist/index192.js +1 -2
- package/dist/index193.js +1 -2
- package/dist/index194.js +1 -2
- package/dist/index195.js +1 -2
- package/dist/index196.js +1 -2
- package/dist/index197.js +1 -2
- package/dist/index198.js +81 -4
- package/dist/index199.js +0 -1
- package/dist/index200.js +7 -81
- package/dist/index201.js +5 -45
- package/dist/index202.js +18 -0
- package/dist/index203.js +16 -14
- package/dist/index204.js +19 -4
- package/dist/index205.js +19 -4
- package/dist/index206.js +26 -35
- package/dist/index207.js +3 -7
- package/dist/index208.js +2 -8
- package/dist/index209.js +247 -7
- package/dist/{index22.js → index21.js} +20 -21
- package/dist/index210.js +49 -124
- package/dist/index211.js +44 -6
- package/dist/index212.js +5 -124
- package/dist/index213.js +49 -20
- package/dist/index214.js +3 -17
- package/dist/index215.js +3 -17
- package/dist/index216.js +35 -3
- package/dist/index217.js +6 -3
- package/dist/index218.js +7 -175
- package/dist/index219.js +2 -6
- package/dist/index220.js +4 -370
- package/dist/index221.js +43 -20
- package/dist/index223.js +13 -4
- package/dist/index224.js +154 -246
- package/dist/index225.js +77 -46
- package/dist/index227.js +126 -6
- package/dist/index228.js +123 -50
- package/dist/index229.js +2 -159
- package/dist/{index24.js → index23.js} +7 -8
- package/dist/index230.js +174 -85
- package/dist/index231.js +7 -0
- package/dist/index232.js +369 -3
- package/dist/index233.js +2 -5
- package/dist/index234.js +2 -3
- package/dist/index235.js +18 -3
- package/dist/index236.js +105 -18
- package/dist/{index239.js → index238.js} +2 -3
- package/dist/index240.js +4 -0
- package/dist/index241.js +10 -3
- package/dist/index242.js +2 -10
- package/dist/index243.js +281 -4
- package/dist/index244.js +6 -4
- package/dist/index245.js +2 -10
- package/dist/index246.js +2 -24
- package/dist/index247.js +2 -10
- package/dist/index248.js +2 -7
- package/dist/index249.js +2 -17
- package/dist/{index26.js → index25.js} +5 -6
- package/dist/index250.js +2 -225
- package/dist/index251.js +2 -4
- package/dist/index252.js +4 -0
- package/dist/index253.js +2 -8
- package/dist/index254.js +2 -432
- package/dist/index255.js +24 -86
- package/dist/index256.js +22 -282
- package/dist/index258.js +7 -3
- package/dist/index259.js +224 -3
- package/dist/index260.js +431 -3
- package/dist/index261.js +89 -3
- package/dist/index262.js +9 -3
- package/dist/index263.js +3 -127
- package/dist/index264.js +8 -22
- package/dist/index265.js +25 -0
- package/dist/index266.js +6 -201
- package/dist/index267.js +16 -3
- package/dist/index268.js +4 -3
- package/dist/index269.js +3 -3
- package/dist/{index28.js → index27.js} +2 -3
- package/dist/index270.js +12 -3
- package/dist/index271.js +9 -3
- package/dist/index272.js +9 -3
- package/dist/index273.js +14 -26
- package/dist/index274.js +199 -22
- package/dist/index275.js +5 -0
- package/dist/index277.js +2 -128
- package/dist/index278.js +126 -3
- package/dist/index279.js +20 -8
- package/dist/index281.js +435 -12
- package/dist/index282.js +125 -8
- package/dist/index283.js +3 -18
- package/dist/index284.js +2 -66
- package/dist/index285.js +211 -6
- package/dist/index286.js +5 -5
- package/dist/index287.js +65 -3
- package/dist/index288.js +15 -4
- package/dist/index289.js +2 -212
- package/dist/{index30.js → index29.js} +2 -3
- package/dist/index290.js +6 -15
- package/dist/index291.js +7 -80
- package/dist/index292.js +21 -0
- package/dist/index293.js +79 -5
- package/dist/index295.js +4 -60
- package/dist/index296.js +4 -36
- package/dist/index297.js +59 -3
- package/dist/index298.js +0 -1
- package/dist/index299.js +34 -7
- package/dist/index300.js +46 -7
- package/dist/index301.js +2 -20
- package/dist/index302.js +480 -48
- package/dist/index304.js +423 -0
- package/dist/index305.js +42 -417
- package/dist/index306.js +2 -48
- package/dist/{index32.js → index31.js} +3 -4
- package/dist/{index34.js → index33.js} +4 -5
- package/dist/{index36.js → index35.js} +21 -23
- package/dist/{index38.js → index37.js} +6 -7
- package/dist/{index40.js → index39.js} +2 -3
- package/dist/index4.js +16 -0
- package/dist/{index42.js → index41.js} +3 -4
- package/dist/{index44.js → index43.js} +10 -12
- package/dist/{index46.js → index45.js} +3 -4
- package/dist/{index48.js → index47.js} +2 -3
- package/dist/{index50.js → index49.js} +3 -4
- package/dist/index5.js +40 -15
- package/dist/{index52.js → index51.js} +2 -3
- package/dist/{index54.js → index53.js} +2 -3
- package/dist/{index56.js → index55.js} +2 -3
- package/dist/{index58.js → index57.js} +1 -2
- package/dist/{index60.js → index59.js} +7 -9
- package/dist/index6.js +76 -39
- package/dist/{index62.js → index61.js} +2 -3
- package/dist/{index64.js → index63.js} +2 -3
- package/dist/{index66.js → index65.js} +4 -5
- package/dist/{index68.js → index67.js} +2 -3
- package/dist/{index70.js → index69.js} +1 -2
- package/dist/index7.js +62 -79
- package/dist/{index72.js → index71.js} +7 -8
- package/dist/{index74.js → index73.js} +15 -17
- package/dist/{index76.js → index75.js} +4 -5
- package/dist/index77.js +46 -0
- package/dist/index78.js +120 -38
- package/dist/index8.js +18 -61
- package/dist/{index81.js → index80.js} +4 -5
- package/dist/{index83.js → index82.js} +4 -6
- package/dist/{index85.js → index84.js} +6 -7
- package/dist/{index87.js → index86.js} +1 -2
- package/dist/{index89.js → index88.js} +2 -3
- package/dist/index9.js +7 -20
- package/dist/{index91.js → index90.js} +2 -3
- package/dist/{index93.js → index92.js} +2 -3
- package/dist/{index95.js → index94.js} +0 -1
- package/dist/{index97.js → index96.js} +2 -3
- package/dist/{index99.js → index98.js} +2 -3
- package/dist/style.css +1 -1
- package/package.json +2 -2
- package/dist/index.js.map +0 -1
- package/dist/index10.js.map +0 -1
- package/dist/index101.js.map +0 -1
- package/dist/index103.js.map +0 -1
- package/dist/index105.js +0 -273
- package/dist/index105.js.map +0 -1
- package/dist/index107.js.map +0 -1
- package/dist/index109.js.map +0 -1
- package/dist/index11.js.map +0 -1
- package/dist/index111.js.map +0 -1
- package/dist/index113.js.map +0 -1
- package/dist/index115.js.map +0 -1
- package/dist/index117.js.map +0 -1
- package/dist/index119.js.map +0 -1
- package/dist/index12.js.map +0 -1
- package/dist/index121.js.map +0 -1
- package/dist/index122.js.map +0 -1
- package/dist/index123.js.map +0 -1
- package/dist/index124.js.map +0 -1
- package/dist/index125.js.map +0 -1
- package/dist/index126.js.map +0 -1
- package/dist/index127.js.map +0 -1
- package/dist/index128.js.map +0 -1
- package/dist/index129.js.map +0 -1
- package/dist/index13.js.map +0 -1
- package/dist/index130.js.map +0 -1
- package/dist/index131.js.map +0 -1
- package/dist/index132.js.map +0 -1
- package/dist/index133.js.map +0 -1
- package/dist/index134.js.map +0 -1
- package/dist/index135.js.map +0 -1
- package/dist/index136.js.map +0 -1
- package/dist/index137.js.map +0 -1
- package/dist/index138.js.map +0 -1
- package/dist/index139.js.map +0 -1
- package/dist/index14.js +0 -85
- package/dist/index14.js.map +0 -1
- package/dist/index140.js.map +0 -1
- package/dist/index141.js.map +0 -1
- package/dist/index142.js.map +0 -1
- package/dist/index143.js.map +0 -1
- package/dist/index144.js.map +0 -1
- package/dist/index145.js.map +0 -1
- package/dist/index146.js.map +0 -1
- package/dist/index147.js.map +0 -1
- package/dist/index148.js.map +0 -1
- package/dist/index149.js.map +0 -1
- package/dist/index150.js.map +0 -1
- package/dist/index151.js.map +0 -1
- package/dist/index152.js.map +0 -1
- package/dist/index153.js.map +0 -1
- package/dist/index154.js.map +0 -1
- package/dist/index155.js.map +0 -1
- package/dist/index156.js.map +0 -1
- package/dist/index157.js.map +0 -1
- package/dist/index158.js.map +0 -1
- package/dist/index159.js.map +0 -1
- package/dist/index16.js.map +0 -1
- package/dist/index160.js.map +0 -1
- package/dist/index161.js.map +0 -1
- package/dist/index163.js +0 -6
- package/dist/index163.js.map +0 -1
- package/dist/index165.js.map +0 -1
- package/dist/index166.js.map +0 -1
- package/dist/index167.js.map +0 -1
- package/dist/index168.js.map +0 -1
- package/dist/index169.js.map +0 -1
- package/dist/index170.js.map +0 -1
- package/dist/index171.js +0 -6
- package/dist/index171.js.map +0 -1
- package/dist/index173.js.map +0 -1
- package/dist/index174.js.map +0 -1
- package/dist/index175.js.map +0 -1
- package/dist/index176.js.map +0 -1
- package/dist/index177.js.map +0 -1
- package/dist/index178.js.map +0 -1
- package/dist/index179.js.map +0 -1
- package/dist/index18.js.map +0 -1
- package/dist/index180.js.map +0 -1
- package/dist/index181.js.map +0 -1
- package/dist/index182.js.map +0 -1
- package/dist/index183.js.map +0 -1
- package/dist/index184.js.map +0 -1
- package/dist/index185.js.map +0 -1
- package/dist/index187.js +0 -6
- package/dist/index187.js.map +0 -1
- package/dist/index189.js.map +0 -1
- package/dist/index190.js.map +0 -1
- package/dist/index191.js.map +0 -1
- package/dist/index192.js.map +0 -1
- package/dist/index193.js.map +0 -1
- package/dist/index194.js.map +0 -1
- package/dist/index195.js.map +0 -1
- package/dist/index196.js.map +0 -1
- package/dist/index197.js.map +0 -1
- package/dist/index198.js.map +0 -1
- package/dist/index199.js.map +0 -1
- package/dist/index20.js.map +0 -1
- package/dist/index200.js.map +0 -1
- package/dist/index201.js.map +0 -1
- package/dist/index203.js.map +0 -1
- package/dist/index204.js.map +0 -1
- package/dist/index205.js.map +0 -1
- package/dist/index206.js.map +0 -1
- package/dist/index207.js.map +0 -1
- package/dist/index208.js.map +0 -1
- package/dist/index209.js.map +0 -1
- package/dist/index210.js.map +0 -1
- package/dist/index211.js.map +0 -1
- package/dist/index212.js.map +0 -1
- package/dist/index213.js.map +0 -1
- package/dist/index214.js.map +0 -1
- package/dist/index215.js.map +0 -1
- package/dist/index216.js.map +0 -1
- package/dist/index217.js.map +0 -1
- package/dist/index218.js.map +0 -1
- package/dist/index219.js.map +0 -1
- package/dist/index22.js.map +0 -1
- package/dist/index220.js.map +0 -1
- package/dist/index221.js.map +0 -1
- package/dist/index222.js +0 -30
- package/dist/index222.js.map +0 -1
- package/dist/index223.js.map +0 -1
- package/dist/index224.js.map +0 -1
- package/dist/index225.js.map +0 -1
- package/dist/index226.js +0 -47
- package/dist/index226.js.map +0 -1
- package/dist/index227.js.map +0 -1
- package/dist/index228.js.map +0 -1
- package/dist/index229.js.map +0 -1
- package/dist/index230.js.map +0 -1
- package/dist/index232.js.map +0 -1
- package/dist/index233.js.map +0 -1
- package/dist/index234.js.map +0 -1
- package/dist/index235.js.map +0 -1
- package/dist/index236.js.map +0 -1
- package/dist/index237.js +0 -109
- package/dist/index237.js.map +0 -1
- package/dist/index239.js.map +0 -1
- package/dist/index24.js.map +0 -1
- package/dist/index241.js.map +0 -1
- package/dist/index242.js.map +0 -1
- package/dist/index243.js.map +0 -1
- package/dist/index244.js.map +0 -1
- package/dist/index245.js.map +0 -1
- package/dist/index246.js.map +0 -1
- package/dist/index247.js.map +0 -1
- package/dist/index248.js.map +0 -1
- package/dist/index249.js.map +0 -1
- package/dist/index250.js.map +0 -1
- package/dist/index251.js.map +0 -1
- package/dist/index253.js.map +0 -1
- package/dist/index254.js.map +0 -1
- package/dist/index255.js.map +0 -1
- package/dist/index256.js.map +0 -1
- package/dist/index257.js +0 -9
- package/dist/index257.js.map +0 -1
- package/dist/index258.js.map +0 -1
- package/dist/index259.js.map +0 -1
- package/dist/index26.js.map +0 -1
- package/dist/index260.js.map +0 -1
- package/dist/index261.js.map +0 -1
- package/dist/index262.js.map +0 -1
- package/dist/index263.js.map +0 -1
- package/dist/index264.js.map +0 -1
- package/dist/index266.js.map +0 -1
- package/dist/index267.js.map +0 -1
- package/dist/index268.js.map +0 -1
- package/dist/index269.js.map +0 -1
- package/dist/index270.js.map +0 -1
- package/dist/index271.js.map +0 -1
- package/dist/index272.js.map +0 -1
- package/dist/index273.js.map +0 -1
- package/dist/index274.js.map +0 -1
- package/dist/index276.js +0 -439
- package/dist/index276.js.map +0 -1
- package/dist/index277.js.map +0 -1
- package/dist/index278.js.map +0 -1
- package/dist/index279.js.map +0 -1
- package/dist/index28.js.map +0 -1
- package/dist/index280.js +0 -6
- package/dist/index280.js.map +0 -1
- package/dist/index281.js.map +0 -1
- package/dist/index282.js.map +0 -1
- package/dist/index283.js.map +0 -1
- package/dist/index284.js.map +0 -1
- package/dist/index285.js.map +0 -1
- package/dist/index286.js.map +0 -1
- package/dist/index287.js.map +0 -1
- package/dist/index288.js.map +0 -1
- package/dist/index289.js.map +0 -1
- package/dist/index290.js.map +0 -1
- package/dist/index291.js.map +0 -1
- package/dist/index293.js.map +0 -1
- package/dist/index294.js +0 -7
- package/dist/index294.js.map +0 -1
- package/dist/index295.js.map +0 -1
- package/dist/index296.js.map +0 -1
- package/dist/index297.js.map +0 -1
- package/dist/index298.js.map +0 -1
- package/dist/index299.js.map +0 -1
- package/dist/index30.js.map +0 -1
- package/dist/index300.js.map +0 -1
- package/dist/index301.js.map +0 -1
- package/dist/index302.js.map +0 -1
- package/dist/index303.js +0 -483
- package/dist/index303.js.map +0 -1
- package/dist/index305.js.map +0 -1
- package/dist/index306.js.map +0 -1
- package/dist/index307.js +0 -5
- package/dist/index307.js.map +0 -1
- package/dist/index32.js.map +0 -1
- package/dist/index34.js.map +0 -1
- package/dist/index36.js.map +0 -1
- package/dist/index38.js.map +0 -1
- package/dist/index40.js.map +0 -1
- package/dist/index42.js.map +0 -1
- package/dist/index44.js.map +0 -1
- package/dist/index46.js.map +0 -1
- package/dist/index48.js.map +0 -1
- package/dist/index5.js.map +0 -1
- package/dist/index50.js.map +0 -1
- package/dist/index52.js.map +0 -1
- package/dist/index54.js.map +0 -1
- package/dist/index56.js.map +0 -1
- package/dist/index58.js.map +0 -1
- package/dist/index6.js.map +0 -1
- package/dist/index60.js.map +0 -1
- package/dist/index62.js.map +0 -1
- package/dist/index64.js.map +0 -1
- package/dist/index66.js.map +0 -1
- package/dist/index68.js.map +0 -1
- package/dist/index7.js.map +0 -1
- package/dist/index70.js.map +0 -1
- package/dist/index72.js.map +0 -1
- package/dist/index74.js.map +0 -1
- package/dist/index76.js.map +0 -1
- package/dist/index78.js.map +0 -1
- package/dist/index79.js +0 -130
- package/dist/index79.js.map +0 -1
- package/dist/index8.js.map +0 -1
- package/dist/index81.js.map +0 -1
- package/dist/index83.js.map +0 -1
- package/dist/index85.js.map +0 -1
- package/dist/index87.js.map +0 -1
- package/dist/index89.js.map +0 -1
- package/dist/index9.js.map +0 -1
- package/dist/index91.js.map +0 -1
- package/dist/index93.js.map +0 -1
- package/dist/index95.js.map +0 -1
- package/dist/index97.js.map +0 -1
- package/dist/index99.js.map +0 -1
package/dist/index226.js
DELETED
@@ -1,47 +0,0 @@
|
|
1
|
-
import { defineComponent as _, computed as a, openBlock as o, createElementBlock as c, createElementVNode as p, Fragment as b, renderList as h, createBlock as k, normalizeClass as f, withCtx as y, createTextVNode as x, toDisplayString as B } from "vue";
|
2
|
-
import C from "./index14.js";
|
3
|
-
/* empty css */
|
4
|
-
const M = { class: "bb-base-date-picker__button-menu bb-base-date-picker__month-selector" }, v = { class: "content" }, E = /* @__PURE__ */ _({
|
5
|
-
__name: "BaseDatePickerMonthSelector",
|
6
|
-
props: {
|
7
|
-
cursor: {},
|
8
|
-
disabled: { type: Boolean }
|
9
|
-
},
|
10
|
-
emits: ["update:month"],
|
11
|
-
setup(l, { emit: d }) {
|
12
|
-
const s = l, m = d, i = a(() => s.cursor.month()), u = a(
|
13
|
-
() => new Array(12).fill(0).map((r, t) => {
|
14
|
-
const n = s.cursor.clone().startOf("year").add(t, "month");
|
15
|
-
return {
|
16
|
-
text: n.format("MMMM"),
|
17
|
-
key: n.unix(),
|
18
|
-
selected: n.month() === i.value,
|
19
|
-
handler: () => m("update:month", t)
|
20
|
-
};
|
21
|
-
})
|
22
|
-
);
|
23
|
-
return (r, t) => (o(), c("div", M, [
|
24
|
-
p("div", v, [
|
25
|
-
(o(!0), c(b, null, h(u.value, (e) => (o(), k(C, {
|
26
|
-
key: e.key,
|
27
|
-
class: f({
|
28
|
-
content__btn: !0,
|
29
|
-
"content__btn--selected": e.selected
|
30
|
-
}),
|
31
|
-
disabled: r.disabled,
|
32
|
-
type: "button",
|
33
|
-
onClick: e.handler
|
34
|
-
}, {
|
35
|
-
default: y(() => [
|
36
|
-
x(B(e.text), 1)
|
37
|
-
]),
|
38
|
-
_: 2
|
39
|
-
}, 1032, ["class", "disabled", "onClick"]))), 128))
|
40
|
-
])
|
41
|
-
]));
|
42
|
-
}
|
43
|
-
});
|
44
|
-
export {
|
45
|
-
E as default
|
46
|
-
};
|
47
|
-
//# sourceMappingURL=index226.js.map
|
package/dist/index226.js.map
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"index226.js","sources":["../src/components/BaseDatePicker/BaseDatePickerMonthSelector.vue"],"sourcesContent":["<template>\n\t<div\n\t\tclass=\"bb-base-date-picker__button-menu bb-base-date-picker__month-selector\"\n\t>\n\t\t<div class=\"content\">\n\t\t\t<BaseButton\n\t\t\t\tv-for=\"option in options\"\n\t\t\t\t:key=\"option.key\"\n\t\t\t\t:class=\"{\n\t\t\t\t\tcontent__btn: true,\n\t\t\t\t\t'content__btn--selected': option.selected,\n\t\t\t\t}\"\n\t\t\t\t:disabled=\"disabled\"\n\t\t\t\ttype=\"button\"\n\t\t\t\t@click=\"option.handler\"\n\t\t\t>\n\t\t\t\t{{ option.text }}\n\t\t\t</BaseButton>\n\t\t</div>\n\t</div>\n</template>\n\n<script setup lang=\"ts\">\nimport type { Dayjs } from 'dayjs';\nimport { computed } from 'vue';\nimport BaseButton from '../BaseButton/BaseButton.vue';\n\ntype Props = {\n\tcursor: Dayjs;\n\tdisabled: boolean;\n};\nconst props = defineProps<Props>();\nconst emit = defineEmits<{\n\t(event: 'update:month', value: number): void;\n}>();\n\nconst month = computed(() => props.cursor.month());\n\nconst options = computed(() =>\n\tnew Array(12).fill(0).map((_: unknown, index) => {\n\t\tlet base = props.cursor.clone().startOf('year');\n\t\tconst d = base.add(index, 'month');\n\t\treturn {\n\t\t\ttext: d.format('MMMM'),\n\t\t\tkey: d.unix(),\n\t\t\tselected: d.month() === month.value,\n\t\t\thandler: () => emit('update:month', index),\n\t\t};\n\t})\n);\n</script>\n"],"names":["props","__props","emit","__emit","month","computed","options","_","index","d"],"mappings":";;;;;;;;;;;AA+BA,UAAMA,IAAQC,GACRC,IAAOC,GAIPC,IAAQC,EAAS,MAAML,EAAM,OAAO,OAAO,GAE3CM,IAAUD;AAAA,MAAS,MACxB,IAAI,MAAM,EAAE,EAAE,KAAK,CAAC,EAAE,IAAI,CAACE,GAAYC,MAAU;AAEhD,cAAMC,IADKT,EAAM,OAAO,MAAM,EAAE,QAAQ,MAAM,EAC/B,IAAIQ,GAAO,OAAO;AAC1B,eAAA;AAAA,UACN,MAAMC,EAAE,OAAO,MAAM;AAAA,UACrB,KAAKA,EAAE,KAAK;AAAA,UACZ,UAAUA,EAAE,MAAM,MAAML,EAAM;AAAA,UAC9B,SAAS,MAAMF,EAAK,gBAAgBM,CAAK;AAAA,QAAA;AAAA,MAC1C,CACA;AAAA,IAAA;;;;;;;;;;;;;;;;;;;;;;"}
|
package/dist/index227.js.map
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"index227.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;"}
|
package/dist/index228.js.map
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"index228.js","sources":["../src/components/BaseDatePicker/BaseDatePickerYearSelector.vue"],"sourcesContent":["<template>\n\t<div\n\t\tref=\"container\"\n\t\tclass=\"bb-base-date-picker__button-menu bb-base-date-picker__year-selector scrollbar-border\"\n\t>\n\t\t<div class=\"content\">\n\t\t\t<BaseButton\n\t\t\t\tv-for=\"option in options\"\n\t\t\t\t:key=\"option.key\"\n\t\t\t\t:class=\"{\n\t\t\t\t\tcontent__btn: true,\n\t\t\t\t\t'content__btn--selected': option.selected,\n\t\t\t\t}\"\n\t\t\t\t:disabled=\"disabled\"\n\t\t\t\t@click=\"option.handler\"\n\t\t\t>\n\t\t\t\t{{ option.text }}\n\t\t\t</BaseButton>\n\t\t</div>\n\t</div>\n</template>\n\n<script setup lang=\"ts\">\nimport type { Dayjs } from 'dayjs';\nimport { computed, onMounted } from 'vue';\nimport { range } from '@/utilities/functions/range';\nimport { ref } from 'vue';\nimport BaseButton from '../BaseButton/BaseButton.vue';\n\ntype Props = {\n\tcursor: Dayjs;\n\tdisabled: boolean;\n};\nconst props = defineProps<Props>();\nconst emit = defineEmits<{\n\t(event: 'update:year', value: number): void;\n}>();\n\nconst container = ref<HTMLElement>();\n\nconst year = computed(() => props.cursor.year());\n\nconst howMany = 100;\nconst startingYear = new Date().getFullYear() - howMany / 2;\n\nconst options = range(startingYear, startingYear + howMany).map((y) => {\n\treturn {\n\t\ttext: y,\n\t\tkey: y,\n\t\tselected: y === year.value,\n\t\thandler: () => emit('update:year', y),\n\t};\n});\nonMounted(() => {\n\tif (!container.value) return;\n\tconst el = container.value.querySelector<HTMLElement>(\n\t\t'.content__btn--selected'\n\t);\n\tif (!el) return;\n\tel.parentElement!.scrollTop =\n\t\tel.offsetTop - el.parentElement!.clientHeight / 2 + 16;\n});\n</script>\n"],"names":["howMany","props","__props","emit","__emit","container","ref","year","computed","startingYear","options","range","y","onMounted","el"],"mappings":";;;;gCA0CMA,IAAU;;;;;;;;AAThB,UAAMC,IAAQC,GACRC,IAAOC,GAIPC,IAAYC,KAEZC,IAAOC,EAAS,MAAMP,EAAM,OAAO,MAAM,GAGzCQ,KAAmB,oBAAA,KAAA,GAAO,gBAAgBT,IAAU,GAEpDU,IAAUC,EAAMF,GAAcA,IAAeT,CAAO,EAAE,IAAI,CAACY,OACzD;AAAA,MACN,MAAMA;AAAA,MACN,KAAKA;AAAA,MACL,UAAUA,MAAML,EAAK;AAAA,MACrB,SAAS,MAAMJ,EAAK,eAAeS,CAAC;AAAA,IAAA,EAErC;AACD,WAAAC,EAAU,MAAM;AACX,UAAA,CAACR,EAAU,MAAO;AAChB,YAAAS,IAAKT,EAAU,MAAM;AAAA,QAC1B;AAAA,MAAA;AAED,MAAKS,MACLA,EAAG,cAAe,YACjBA,EAAG,YAAYA,EAAG,cAAe,eAAe,IAAI;AAAA,IAAA,CACrD;;;;;;;;;;;;;;;;;;;;;;;;"}
|
package/dist/index229.js.map
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"index229.js","sources":["../src/composables/useOptions.ts"],"sourcesContent":["import {\n\tcomputed,\n\tnextTick,\n\tonBeforeMount,\n\tonBeforeUnmount,\n\tref,\n\twatch,\n\ttype Ref,\n} from 'vue';\nimport type { Option as BaseOption } from '@/types/Option';\nimport { last } from '@/utilities/functions/last';\nimport { useArray } from './useArray';\nimport { uniqBy } from '@/utilities/functions/uniqBy';\nimport { useItemValue } from './useItemValue';\nimport { useItemText } from './useItemText';\nimport { hash } from '@/utilities/functions/hash';\nimport { isNotNil } from '@/utilities/functions/isNotNil';\nimport { waitFor } from '@/utilities/functions/waitFor';\nimport { isNil } from '@/utilities/functions/isNil';\n\ntype Options = {\n\tmultiple: boolean;\n\tstash: boolean;\n\titemText: string | ((item: any) => string) | undefined;\n\titemValue: string | ((item: any) => string) | undefined;\n\tmodelValue: Ref<any>;\n\tresetQueryOnOptionSelected: boolean;\n\temit: any;\n\titems: Ref<any>;\n\tenforceCoherence: boolean;\n\tprefill: boolean;\n\tmodelValueDebounceTime: number;\n\tdepsDebounceTime: number;\n\tdependencies: Ref<any[]>;\n\tqueryDebounceTime: number;\n\tdisabled: Ref<boolean>;\n};\n\nexport const useOptions = (params: Options) => {\n\tconst query = ref<string>('');\n\n\tconst lastEmittedValue = ref();\n\tconst updateModelValue = (value: any) => {\n\t\tlastEmittedValue.value = value;\n\t\tparams.emit('update:modelValue', value);\n\t};\n\n\tconst internalItems = ref<any[]>([]);\n\tconst {\n\t\tarray: innerStash,\n\t\tadd: addToStash,\n\t\tremove: removeFromStash,\n\t\tset: setStash,\n\t} = useArray<BaseOption>();\n\n\tconst {\n\t\tarray: manualItems,\n\t\tadd: addToManualItems,\n\t\tremove: removeFromManualItems,\n\t} = useArray<BaseOption>();\n\n\tconst { getItemText } = useItemText();\n\tconst { getItemValue } = useItemValue();\n\tconst createOption = (item: any): BaseOption => {\n\t\tconst disabled = !!(params.disabled.value || item.disabled);\n\t\tconst text = getItemText(item, params.itemText);\n\t\tconst value = getItemValue(item, params.itemValue);\n\n\t\t// Undefined is not supported\n\t\tif (value === undefined)\n\t\t\tthrow new Error(\n\t\t\t\t'The result of extracting \"value\" from option was undefined. Affected item is ' +\n\t\t\t\t\tJSON.stringify(item) +\n\t\t\t\t\t' please check itemValue property is correct.'\n\t\t\t);\n\t\tconst valueHash = hash(value);\n\t\tconst selected = false;\n\t\treturn {\n\t\t\titem,\n\t\t\ttext,\n\t\t\tvalue,\n\t\t\tvalueHash,\n\t\t\tdisabled,\n\t\t\tselected,\n\t\t};\n\t};\n\n\tconst setSelected = (o: BaseOption) => {\n\t\to.selected = isNotNil(modelValueIndexedByHash.value[o.valueHash]);\n\t\treturn o;\n\t};\n\tconst options = computed<BaseOption[]>(() => {\n\t\tconst base = ([] as BaseOption[]).concat(\n\t\t\tinternalItems.value.map((item) => {\n\t\t\t\treturn setSelected(createOption(item));\n\t\t\t}),\n\t\t\tmanualItems.value.map(setSelected),\n\t\t\tinnerStash.value.map(setSelected)\n\t\t);\n\t\treturn uniqBy(base, (o) => o.valueHash);\n\t});\n\n\tconst selectOption = (option: BaseOption) => {\n\t\tif (params.multiple) {\n\t\t\tupdateModelValue(params.modelValue.value.concat(option.value));\n\t\t\tif (params.stash) {\n\t\t\t\taddToStash(option);\n\t\t\t}\n\n\t\t\tif (params.resetQueryOnOptionSelected) {\n\t\t\t\talignQueryToState();\n\t\t\t}\n\t\t} else {\n\t\t\tif (params.stash) {\n\t\t\t\tsetStash(option);\n\t\t\t}\n\t\t\tupdateModelValue(option.value);\n\t\t\tnextTick(() => alignQueryToState());\n\t\t}\n\t};\n\tconst unselectOption = async (option: BaseOption) => {\n\t\tremoveFromManualItems((o) => o.valueHash !== option.valueHash);\n\t\tremoveFromStash((o) => o.valueHash !== option.valueHash);\n\t\tif (params.multiple) {\n\t\t\tconst copy = { ...modelValueIndexedByHash.value };\n\t\t\tdelete copy[option.valueHash];\n\t\t\tupdateModelValue(Object.values(copy));\n\t\t} else {\n\t\t\tupdateModelValue(null);\n\t\t\tawait nextTick();\n\t\t\talignQueryToState();\n\t\t}\n\t};\n\n\t/**\n\t * Indexes modelValue to a map of hash - value pairs so we can easily track which values are selected\n\t */\n\tconst modelValueIndexedByHash = computed(() => {\n\t\tconst map: Record<string, any> = {};\n\t\tconst arr = [].concat(params.modelValue.value);\n\t\tfor (let index = 0; index < arr.length; index++) {\n\t\t\tconst element = arr[index];\n\t\t\tmap[hash(element)] = element;\n\t\t}\n\t\treturn map;\n\t});\n\n\tconst getOptions = async ({ prefill = false }) => {\n\t\tlet items: any[] = [];\n\t\tif (Array.isArray(params.items.value)) {\n\t\t\titems = params.items.value;\n\t\t} else {\n\t\t\tif (typeof params.items.value === 'function') {\n\t\t\t\tconst order = ++innerLoading.value;\n\t\t\t\ttry {\n\t\t\t\t\titems = await params.items.value(\n\t\t\t\t\t\tquery.value,\n\t\t\t\t\t\tprefill,\n\t\t\t\t\t\tparams.modelValue.value\n\t\t\t\t\t);\n\t\t\t\t\t// If by the time this resolves another call has already been made discard this result\n\t\t\t\t\tif (order < innerLoading.value) {\n\t\t\t\t\t\tawait waitFor(() => order === innerLoading.value);\n\t\t\t\t\t\titems = internalItems.value;\n\t\t\t\t\t}\n\t\t\t\t} catch (error) {\n\t\t\t\t\tconsole.error(error);\n\t\t\t\t}\n\t\t\t\tinnerLoading.value--;\n\t\t\t}\n\t\t}\n\t\tinternalItems.value = items as any;\n\t};\n\n\t/**\n\t * Indexes options by their hash so they can be retrieved\n\t */\n\tconst optionsIndexedByHash = computed(() => {\n\t\tconst map: Record<string, BaseOption> = {};\n\t\tfor (let index = 0; index < options.value.length; index++) {\n\t\t\tconst element = options.value[index];\n\t\t\tconst { valueHash } = element;\n\t\t\tmap[valueHash] = element;\n\t\t}\n\t\treturn {\n\t\t\tget: (value: any) => {\n\t\t\t\treturn map[hash(value)];\n\t\t\t},\n\t\t};\n\t});\n\n\t/**\n\t * For every item in modelValue find the linked option if it exists.\n\t * This is used to display chips.\n\t */\n\tconst selectedOptions = computed(() => {\n\t\treturn [].concat(params.modelValue.value).reduce((acc, h) => {\n\t\t\tconst found = optionsIndexedByHash.value.get(h);\n\t\t\tif (found) {\n\t\t\t\tacc.push(found);\n\t\t\t}\n\t\t\treturn acc;\n\t\t}, [] as BaseOption[]);\n\t});\n\n\tconst valueIsSelected = (value: any) =>\n\t\tisNotNil(optionsIndexedByHash.value.get(value));\n\n\tconst alignQueryToState = () => {\n\t\tif (params.multiple) {\n\t\t\tquery.value = '';\n\t\t\treturn;\n\t\t}\n\t\tlet option: BaseOption | undefined;\n\t\tif (selectedOptions.value) {\n\t\t\toption = last(selectedOptions.value);\n\t\t}\n\t\tquery.value = option?.text || '';\n\t};\n\n\t/**\n\t * Add an option to the manual items and then reset the query\n\t */\n\tconst addCurrentQueryToManualItems = () => {\n\t\tconst text = query.value.trim();\n\t\tconst option = createOption(text);\n\t\taddToManualItems(option);\n\t\talignQueryToState();\n\t};\n\n\t/**\n\t * Use a number accumulator because if the fn takes 5 seconds\n\t * and after 2 seconds another search is run\n\t * When the first returns the second is still out for 2 seconds\n\t * and we want to track them both.\n\t * Debounce will not be enough.\n\t */\n\tconst innerLoading = ref(0);\n\n\t/**\n\t * Coherent values are values that have an option they can be linked to.\n\t * Divide coherent and incoherent values.\n\t */\n\n\tconst coherenceStatus = computed(() => {\n\t\treturn [].concat(params.modelValue.value).reduce(\n\t\t\t(acc, curr) => {\n\t\t\t\tif (valueIsSelected(curr)) {\n\t\t\t\t\tacc.coherent.push(curr);\n\t\t\t\t} else {\n\t\t\t\t\tacc.incoherent.push(curr);\n\t\t\t\t}\n\t\t\t\treturn acc;\n\t\t\t},\n\t\t\t{ coherent: [], incoherent: [] }\n\t\t);\n\t});\n\n\t/**\n\t * Model value is considered coherent when:\n\t * - multiple mode is empty\n\t * - single mode is null\n\t */\n\tconst modelValueIsCoherent = computed(() => {\n\t\tif (params.multiple && !params.modelValue.value.length) return true;\n\t\telse if (!params.multiple && isNil(params.modelValue.value)) return true;\n\t\treturn !coherenceStatus.value.incoherent.length;\n\t});\n\n\t/**\n\t * Realign selection state to the passed settings.\n\t * If modelValue has any value that is not coherent while\n\t * coherence is enforced the value should be removed\n\t */\n\tconst alignToCoherenceSettings = () => {\n\t\tif (params.enforceCoherence && !modelValueIsCoherent.value) {\n\t\t\tif (!params.multiple) updateModelValue(null);\n\t\t\telse updateModelValue(coherenceStatus.value.coherent);\n\t\t}\n\t};\n\n\t/**\n\t * Prefilling is the phase where the component understands it needs\n\t * to update its inner items due to a change in state, whether dependencies have changed, items or modelValue have changed.\n\t * It can be intended as the component aligning itself to what state is passed to it.\n\t */\n\tconst hasPrefilled = ref(false);\n\tconst isPrefilling = ref(false);\n\tconst prefillItems = async () => {\n\t\tisPrefilling.value = true;\n\t\tawait getOptions({ prefill: true });\n\t\talignToCoherenceSettings();\n\t\talignQueryToState();\n\t\thasPrefilled.value = true;\n\t\tisPrefilling.value = false;\n\t};\n\n\tonBeforeMount(async () => {\n\t\tif (params.prefill) {\n\t\t\tawait prefillItems();\n\t\t\tif (params.stash) {\n\t\t\t\tsetStash(...selectedOptions.value);\n\t\t\t}\n\t\t}\n\t});\n\n\t/**\n\t * Triggered on input when items is a function.\n\t */\n\n\tlet timeout: ReturnType<typeof setTimeout>;\n\tconst searchByQuery = () => {\n\t\tif (timeout) clearTimeout(timeout);\n\t\ttimeout = setTimeout(async () => {\n\t\t\ttry {\n\t\t\t\tawait getOptions({ prefill: false });\n\t\t\t} catch (error) {\n\t\t\t\tconsole.error(error);\n\t\t\t}\n\t\t}, params.queryDebounceTime);\n\t};\n\tonBeforeUnmount(() => clearTimeout(timeout));\n\n\t/**\n\t * When modelValue changes split behavior for single and multiple selection:\n\t */\n\tlet modelValueTimeout: ReturnType<typeof setTimeout>;\n\twatch(\n\t\t() => params.modelValue.value,\n\t\t() => {\n\t\t\tif (modelValueIsCoherent.value) return;\n\t\t\tif (modelValueTimeout) clearTimeout(modelValueTimeout);\n\t\t\tmodelValueTimeout = setTimeout(async () => {\n\t\t\t\tprefillItems();\n\t\t\t}, params.modelValueDebounceTime);\n\t\t}\n\t);\n\n\t/**\n\t * START DEPENDENCY HANDLING\n\t * Explicit dependencies (props.dependencies) and implicit dependencies (props.items)\n\t * need to trigger a pipeline of realignment whenever they change\n\t */\n\tlet depsTimeout: ReturnType<typeof setTimeout>;\n\n\tconst handleDependencyChange = async (current: any, previous: any) => {\n\t\t// Circumvent arrays defined in the template by the parent triggering the watcher\n\t\tif (hash(previous) === hash(current)) return;\n\t\t// Do not track until prefill completes\n\t\tif (!hasPrefilled.value) return;\n\t\tif (depsTimeout) clearTimeout(depsTimeout);\n\t\tdepsTimeout = setTimeout(async () => {\n\t\t\tawait prefillItems();\n\t\t}, params.depsDebounceTime);\n\t};\n\n\t/**\n\t * This is triggered to refresh static items whenever the passed array changes.\n\t * If the parent defines an array in the template this is triggered\n\t * at every render so we take counter measures\n\t * Even if the entire array changes all the previously selected values are still in the stash.\n\t */\n\twatch(() => params.items.value, handleDependencyChange);\n\n\t/**\n\t * When dependencies change\n\t * If the input has not been prefilled yet just return\n\t * Check dependencies are the same by value and not reference\n\t * Otherwise we search again for options as they might be different base on dependencies.\n\t * If coherence is enforced we set the state accordingly\n\t */\n\twatch(() => params.dependencies.value, handleDependencyChange);\n\n\t/**\n\t * END DEPENDENCIES HANDLING\n\t */\n\n\treturn {\n\t\taddCurrentQueryToManualItems,\n\t\talignQueryToState,\n\t\tgetOptions,\n\t\thasPrefilled,\n\t\tinnerLoading,\n\t\tisPrefilling,\n\t\tmanualItems,\n\t\toptions,\n\t\tprefillItems,\n\t\tquery,\n\t\tsearchByQuery,\n\t\tselectedOptions,\n\t\tselectOption,\n\t\tsetStash,\n\t\tunselectOption,\n\t\tupdateModelValue,\n\t\tvalueIsSelected,\n\t\tinternalItems,\n\t};\n};\n"],"names":["useOptions","params","query","ref","lastEmittedValue","updateModelValue","value","internalItems","innerStash","addToStash","removeFromStash","setStash","useArray","manualItems","addToManualItems","removeFromManualItems","getItemText","useItemText","getItemValue","useItemValue","createOption","item","disabled","text","valueHash","hash","setSelected","o","isNotNil","modelValueIndexedByHash","options","computed","base","uniqBy","selectOption","option","alignQueryToState","nextTick","unselectOption","copy","map","arr","index","element","getOptions","prefill","items","order","innerLoading","waitFor","error","optionsIndexedByHash","selectedOptions","acc","h","found","valueIsSelected","last","addCurrentQueryToManualItems","coherenceStatus","curr","modelValueIsCoherent","isNil","alignToCoherenceSettings","hasPrefilled","isPrefilling","prefillItems","onBeforeMount","timeout","searchByQuery","onBeforeUnmount","modelValueTimeout","watch","depsTimeout","handleDependencyChange","current","previous"],"mappings":";;;;;;;;;;AAsCa,MAAAA,KAAa,CAACC,MAAoB;AACxC,QAAAC,IAAQC,EAAY,EAAE,GAEtBC,IAAmBD,KACnBE,IAAmB,CAACC,MAAe;AACxC,IAAAF,EAAiB,QAAQE,GAClBL,EAAA,KAAK,qBAAqBK,CAAK;AAAA,EAAA,GAGjCC,IAAgBJ,EAAW,CAAA,CAAE,GAC7B;AAAA,IACL,OAAOK;AAAA,IACP,KAAKC;AAAA,IACL,QAAQC;AAAA,IACR,KAAKC;AA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B;AAAA,IACjC;AAAA,EAAA;AAQG,MAAAwE;AAEE,QAAAC,IAAyB,OAAOC,GAAcC,MAAkB;AAErE,IAAInD,EAAKmD,CAAQ,MAAMnD,EAAKkD,CAAO,KAE9BX,EAAa,UACdS,kBAA0BA,CAAW,GACzCA,IAAc,WAAW,YAAY;AACpC,YAAMP,EAAa;AAAA,IAAA,GACjBjE,EAAO,gBAAgB;AAAA,EAAA;AAS3B,SAAAuE,EAAM,MAAMvE,EAAO,MAAM,OAAOyE,CAAsB,GAStDF,EAAM,MAAMvE,EAAO,aAAa,OAAOyE,CAAsB,GAMtD;AAAA,IACN,8BAAAhB;AAAA,IACA,mBAAAtB;AAAA,IACA,YAAAQ;AAAA,IACA,cAAAoB;AAAA,IACA,cAAAhB;AAAA,IACA,cAAAiB;AAAA,IACA,aAAApD;AAAA,IACA,SAAAiB;AAAA,IACA,cAAAoC;AAAA,IACA,OAAAhE;AAAA,IACA,eAAAmE;AAAA,IACA,iBAAAjB;AAAA,IACA,cAAAlB;AAAA,IACA,UAAAvB;AAAA,IACA,gBAAA2B;AAAA,IACA,kBAAAjC;AAAA,IACA,iBAAAmD;AAAA,IACA,eAAAjD;AAAA,EAAA;AAEF;"}
|
package/dist/index230.js.map
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"index230.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
package/dist/index232.js.map
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"index232.js","sources":["../src/utilities/functions/isCssColor.ts"],"sourcesContent":["/**\n * Taken from vuetify colorable mixin\n * https://github.com/vuetifyjs/vuetify/blob/master/packages/vuetify/src/mixins/colorable/index.ts\n */\nexport const isCssColor = (color: string): boolean => {\n\treturn !!color && !!color.match(/^(#|var\\(--|(rgb|hsl)a?\\()/);\n};\n"],"names":["isCssColor","color"],"mappings":"AAIa,MAAAA,IAAa,CAACC,MACnB,CAAC,CAACA,KAAS,CAAC,CAACA,EAAM,MAAM,4BAA4B;"}
|
package/dist/index233.js.map
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"index233.js","sources":["../src/utilities/functions/when.ts"],"sourcesContent":["import { curry } from './curry';\n/**\n * Runs fn on item if iteratee(item) is thruthy\n * @param iteratee The test\n * @param item The item to test\n * @param fn The transformer function\n * @returns\n */\nexport const baseWhen = <T, U>(\n\titeratee: (item: T) => boolean,\n\tfn: (item: T) => U,\n\titem: T\n) => {\n\tif (iteratee(item)) return fn(item);\n\treturn item;\n};\n\nexport const when = curry(baseWhen);\n"],"names":["baseWhen","iteratee","fn","item","when","curry"],"mappings":";AAQO,MAAMA,IAAW,CACvBC,GACAC,GACAC,MAEIF,EAASE,CAAI,IAAUD,EAAGC,CAAI,IAC3BA,GAGKC,IAAOC,EAAML,CAAQ;"}
|
package/dist/index234.js.map
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"index234.js","sources":["../src/utilities/functions/booleanishToBoolean.ts"],"sourcesContent":["/**\n * Accepts a booleanish input and returns a boolean value\n * @param input booleanish input\n * @returns\n */\nexport const booleanishToBoolean = (input: boolean | 'true' | 'false') => {\n\tif (typeof input === 'boolean') return input;\n\telse return input === 'true';\n};\n"],"names":["booleanishToBoolean","input"],"mappings":"AAKa,MAAAA,IAAsB,CAACC,MAC/B,OAAOA,KAAU,YAAkBA,IAC3BA,MAAU;"}
|
package/dist/index235.js.map
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"index235.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
|
package/dist/index236.js.map
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"index236.js","sources":["../src/utilities/functions/matchAnyKey.ts"],"sourcesContent":["import { isNil } from './isNil';\n\nconst ensureKeyExists = <T extends object>(item: T, key: keyof T) => {\n\tif (!Object.prototype.hasOwnProperty.call(item, key)) {\n\t\tthrow new Error(\n\t\t\t`Object ${JSON.stringify(item, null, 2)} has no property named \"${key.toString()}\"`\n\t\t);\n\t}\n};\nconst asString = (value: any) => {\n\tif (typeof value === 'string') return value.toLocaleLowerCase();\n\treturn JSON.stringify(value).toLowerCase();\n};\n\n/**\n * Return true or false based on whether the query is included in the passed keys\n * @param item The object to test\n * @param keys The keys to be tested as haystack\n * @param query The query to searched as needle\n * @returns boolean\n */\nexport const matchAnyKey = <T extends object>(\n\titem: T,\n\tkeys: (keyof T)[],\n\tquery: string\n) => {\n\tconst lcQuery = query.toLocaleLowerCase();\n\tfor (let index = 0; index < keys.length; index++) {\n\t\tconst key = keys[index];\n\t\tensureKeyExists(item, key);\n\t\tconst value = item[key];\n\t\tif (isNil(value)) continue;\n\t\tconst valueAsString = asString(value);\n\t\tif (valueAsString.includes(lcQuery)) return true;\n\t}\n\treturn false;\n};\n"],"names":["ensureKeyExists","item","key","asString","value","matchAnyKey","keys","query","lcQuery","index","isNil"],"mappings":";AAEA,MAAMA,IAAkB,CAAmBC,GAASC,MAAiB;AACpE,MAAI,CAAC,OAAO,UAAU,eAAe,KAAKD,GAAMC,CAAG;AAClD,UAAM,IAAI;AAAA,MACT,UAAU,KAAK,UAAUD,GAAM,MAAM,CAAC,CAAC,2BAA2BC,EAAI,SAAA,CAAU;AAAA,IAAA;AAGnF,GACMC,IAAW,CAACC,MACb,OAAOA,KAAU,WAAiBA,EAAM,kBAAkB,IACvD,KAAK,UAAUA,CAAK,EAAE,YAAY,GAU7BC,IAAc,CAC1BJ,GACAK,GACAC,MACI;AACE,QAAAC,IAAUD,EAAM;AACtB,WAASE,IAAQ,GAAGA,IAAQH,EAAK,QAAQG,KAAS;AAC3C,UAAAP,IAAMI,EAAKG,CAAK;AACtB,IAAAT,EAAgBC,GAAMC,CAAG;AACnB,UAAAE,IAAQH,EAAKC,CAAG;AAClB,QAAAQ,EAAMN,CAAK,EAAG;AAElB,QADsBD,EAASC,CAAK,EAClB,SAASI,CAAO,EAAU,QAAA;AAAA,EAC7C;AACO,SAAA;AACR;"}
|
package/dist/index237.js
DELETED
@@ -1,109 +0,0 @@
|
|
1
|
-
import { defineComponent as y, ref as F, computed as H, watch as N, openBlock as p, createElementBlock as L, Fragment as S, renderList as V, createBlock as A, normalizeClass as O, withModifiers as P, withCtx as $, createTextVNode as z, toDisplayString as D } from "vue";
|
2
|
-
import { hash as d } from "./index223.js";
|
3
|
-
import { isNil as l } from "./index126.js";
|
4
|
-
import E from "./index121.js";
|
5
|
-
/* empty css */
|
6
|
-
const K = /* @__PURE__ */ y({
|
7
|
-
__name: "ChipsBox",
|
8
|
-
props: {
|
9
|
-
options: {}
|
10
|
-
},
|
11
|
-
emits: ["option:unselected"],
|
12
|
-
setup(f, { expose: v, emit: h }) {
|
13
|
-
const t = f, u = h, n = F(null), i = H(() => t.options.some((e) => !e.disabled)), a = (e = 1) => {
|
14
|
-
const s = l(n.value) ? -1 : n.value;
|
15
|
-
let o = (s + e) % t.options.length;
|
16
|
-
for (; t.options[o].disabled && o !== s; )
|
17
|
-
o = a(e + 1);
|
18
|
-
return o;
|
19
|
-
}, x = () => {
|
20
|
-
if (!i.value) return;
|
21
|
-
const e = a();
|
22
|
-
n.value = e;
|
23
|
-
}, c = (e = 1) => {
|
24
|
-
const s = l(n.value) ? 0 : n.value;
|
25
|
-
let o = (s - e + t.options.length) % t.options.length;
|
26
|
-
for (; t.options[o].disabled && o !== s; )
|
27
|
-
o = c(e + 1);
|
28
|
-
return o;
|
29
|
-
}, m = async () => {
|
30
|
-
if (!i.value) return;
|
31
|
-
const e = c();
|
32
|
-
n.value = e;
|
33
|
-
}, w = () => {
|
34
|
-
if (!i.value) return;
|
35
|
-
let e = 0;
|
36
|
-
for (; t.options[e].disabled; )
|
37
|
-
e++;
|
38
|
-
n.value = e;
|
39
|
-
}, b = () => {
|
40
|
-
if (!i.value) return;
|
41
|
-
let e = t.options.length - 1;
|
42
|
-
for (; t.options[e].disabled && e !== 0; )
|
43
|
-
e--;
|
44
|
-
n.value = e;
|
45
|
-
}, I = () => {
|
46
|
-
if (!i.value) return;
|
47
|
-
let e = 0;
|
48
|
-
for (; !t.options[e].selected && t.options.length !== e; )
|
49
|
-
e++;
|
50
|
-
n.value = e;
|
51
|
-
}, g = () => {
|
52
|
-
if (!i.value) return;
|
53
|
-
let e = t.options.length - 1;
|
54
|
-
for (; t.options[e].selected && e !== 0; )
|
55
|
-
e--;
|
56
|
-
n.value = e;
|
57
|
-
}, _ = (e) => {
|
58
|
-
if (!i.value) return;
|
59
|
-
const s = t.options.findIndex(
|
60
|
-
(o) => o.valueHash === e
|
61
|
-
);
|
62
|
-
s >= 0 && (n.value = s);
|
63
|
-
}, r = () => {
|
64
|
-
n.value = null;
|
65
|
-
}, k = () => {
|
66
|
-
if (l(n.value)) return;
|
67
|
-
const e = t.options[n.value];
|
68
|
-
e.selected && u("option:unselected", e);
|
69
|
-
}, C = () => l(n.value) ? void 0 : t.options[n.value];
|
70
|
-
return N(
|
71
|
-
() => t.options,
|
72
|
-
(e, s) => {
|
73
|
-
d(e) !== d(s) && r();
|
74
|
-
},
|
75
|
-
{
|
76
|
-
flush: "post"
|
77
|
-
}
|
78
|
-
), v({
|
79
|
-
focusNext: x,
|
80
|
-
focusPrevious: m,
|
81
|
-
focusFirst: w,
|
82
|
-
focusFirstSelected: I,
|
83
|
-
focusLast: b,
|
84
|
-
focusLastSelected: g,
|
85
|
-
blur: r,
|
86
|
-
confirmOption: k,
|
87
|
-
focusByHash: _,
|
88
|
-
getHighlighted: C
|
89
|
-
}), (e, s) => (p(!0), L(S, null, V(e.options, (o, B) => (p(), A(E, {
|
90
|
-
key: o.valueHash,
|
91
|
-
class: O({
|
92
|
-
"bb-chipsbox-item": !0,
|
93
|
-
"bb-chipsbox-item--focused": B === n.value
|
94
|
-
}),
|
95
|
-
clearable: !0,
|
96
|
-
text: o.text,
|
97
|
-
"onClick:clear": P((M) => u("option:unselected", o), ["stop"])
|
98
|
-
}, {
|
99
|
-
default: $(() => [
|
100
|
-
z(D(o.text), 1)
|
101
|
-
]),
|
102
|
-
_: 2
|
103
|
-
}, 1032, ["class", "text", "onClick:clear"]))), 128));
|
104
|
-
}
|
105
|
-
});
|
106
|
-
export {
|
107
|
-
K as default
|
108
|
-
};
|
109
|
-
//# sourceMappingURL=index237.js.map
|
package/dist/index237.js.map
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"index237.js","sources":["../src/components/ChipsBox.vue"],"sourcesContent":["<template>\n\t<BbChip\n\t\tv-for=\"(item, index) in options\"\n\t\t:key=\"item.valueHash\"\n\t\t:class=\"{\n\t\t\t'bb-chipsbox-item': true,\n\t\t\t'bb-chipsbox-item--focused': index === focusedIndex,\n\t\t}\"\n\t\t:clearable=\"true\"\n\t\t:text=\"item.text\"\n\t\t@click:clear.stop=\"emit('option:unselected', item)\"\n\t\t>{{ item.text }}</BbChip\n\t>\n</template>\n\n<script setup lang=\"ts\">\nimport { computed } from 'vue';\nimport { hash } from '@/utilities/functions/hash';\nimport { isNil } from '@/utilities/functions/isNil';\nimport { ref } from 'vue';\nimport { watch } from 'vue';\nimport BbChip from './BbChip/BbChip.vue';\nimport type { Option } from '@/types/Option';\n\ntype Props = {\n\toptions: Option[];\n};\nconst props = defineProps<Props>();\n\nconst emit = defineEmits<{\n\t(e: 'option:unselected', option: Option): void;\n}>();\n\n/**\n * START FOCUS HANDLING\n */\n\nconst focusedIndex = ref<null | number>(null);\n\nconst canFocus = computed(() => props.options.some((o) => !o.disabled));\n\nconst findNextAvailableIndex = (offset = 1) => {\n\tconst initialValue = isNil(focusedIndex.value) ? -1 : focusedIndex.value!;\n\tlet newIndex = (initialValue + offset) % props.options.length;\n\twhile (props.options[newIndex].disabled && newIndex !== initialValue) {\n\t\tnewIndex = findNextAvailableIndex(offset + 1);\n\t}\n\treturn newIndex;\n};\n\nconst focusNext = () => {\n\tif (!canFocus.value) return;\n\tconst newIndex = findNextAvailableIndex();\n\tfocusedIndex.value = newIndex;\n};\nconst findPreviousAvailableIndex = (offset = 1) => {\n\tconst initialValue = isNil(focusedIndex.value) ? 0 : focusedIndex.value!;\n\tlet newIndex =\n\t\t(initialValue - offset + props.options.length) % props.options.length;\n\twhile (props.options[newIndex].disabled && newIndex !== initialValue) {\n\t\tnewIndex = findPreviousAvailableIndex(offset + 1);\n\t}\n\treturn newIndex;\n};\nconst focusPrevious = async () => {\n\tif (!canFocus.value) return;\n\tconst newIndex = findPreviousAvailableIndex();\n\tfocusedIndex.value = newIndex;\n};\n\nconst focusFirst = () => {\n\tif (!canFocus.value) return;\n\tlet newIndex = 0;\n\twhile (props.options[newIndex].disabled) {\n\t\tnewIndex++;\n\t}\n\tfocusedIndex.value = newIndex;\n};\n\nconst focusLast = () => {\n\tif (!canFocus.value) return;\n\tlet newIndex = props.options.length - 1;\n\twhile (props.options[newIndex].disabled && newIndex !== 0) {\n\t\tnewIndex--;\n\t}\n\tfocusedIndex.value = newIndex;\n};\nconst focusFirstSelected = () => {\n\tif (!canFocus.value) return;\n\tlet newIndex = 0;\n\twhile (\n\t\t!props.options[newIndex].selected &&\n\t\tprops.options.length !== newIndex\n\t) {\n\t\tnewIndex++;\n\t}\n\tfocusedIndex.value = newIndex;\n};\nconst focusLastSelected = () => {\n\tif (!canFocus.value) return;\n\tlet newIndex = props.options.length - 1;\n\twhile (props.options[newIndex].selected && newIndex !== 0) {\n\t\tnewIndex--;\n\t}\n\tfocusedIndex.value = newIndex;\n};\n\nconst focusByHash = (hash: Option['valueHash']) => {\n\tif (!canFocus.value) return;\n\tconst linkedOptionIndex = props.options.findIndex(\n\t\t(o) => o.valueHash === hash\n\t);\n\tif (linkedOptionIndex >= 0) {\n\t\tfocusedIndex.value = linkedOptionIndex;\n\t}\n};\n\nconst blur = () => {\n\tfocusedIndex.value = null;\n};\n\n/**\n * END FOCUS HANDLING\n */\n\nconst confirmOption = () => {\n\tif (isNil(focusedIndex.value)) return;\n\tconst option = props.options[focusedIndex.value!];\n\tif (option.selected) {\n\t\temit('option:unselected', option);\n\t}\n};\n\nconst getHighlighted = () => {\n\tif (isNil(focusedIndex.value)) return;\n\tconst option = props.options[focusedIndex.value!];\n\treturn option;\n};\n\nwatch(\n\t() => props.options,\n\t(value, previous) => {\n\t\tif (hash(value) !== hash(previous)) {\n\t\t\tblur();\n\t\t}\n\t},\n\t{\n\t\tflush: 'post',\n\t}\n);\n\ndefineExpose({\n\tfocusNext,\n\tfocusPrevious,\n\tfocusFirst,\n\tfocusFirstSelected,\n\tfocusLast,\n\tfocusLastSelected,\n\tblur,\n\tconfirmOption,\n\tfocusByHash,\n\tgetHighlighted,\n});\n</script>\n\n<style lang=\"postcss\">\n@import '@/assets/css/ChipsBox';\n</style>\n"],"names":["props","__props","emit","__emit","focusedIndex","ref","canFocus","computed","o","findNextAvailableIndex","offset","initialValue","isNil","newIndex","focusNext","findPreviousAvailableIndex","focusPrevious","focusFirst","focusLast","focusFirstSelected","focusLastSelected","focusByHash","hash","linkedOptionIndex","blur","confirmOption","option","getHighlighted","watch","value","previous","__expose"],"mappings":";;;;;;;;;;;;AA2BA,UAAMA,IAAQC,GAERC,IAAOC,GAQPC,IAAeC,EAAmB,IAAI,GAEtCC,IAAWC,EAAS,MAAMP,EAAM,QAAQ,KAAK,CAACQ,MAAM,CAACA,EAAE,QAAQ,CAAC,GAEhEC,IAAyB,CAACC,IAAS,MAAM;AAC9C,YAAMC,IAAeC,EAAMR,EAAa,KAAK,IAAI,KAAKA,EAAa;AACnE,UAAIS,KAAYF,IAAeD,KAAUV,EAAM,QAAQ;AACvD,aAAOA,EAAM,QAAQa,CAAQ,EAAE,YAAYA,MAAaF;AAC5C,QAAAE,IAAAJ,EAAuBC,IAAS,CAAC;AAEtC,aAAAG;AAAA,IAAA,GAGFC,IAAY,MAAM;AACnB,UAAA,CAACR,EAAS,MAAO;AACrB,YAAMO,IAAWJ;AACjB,MAAAL,EAAa,QAAQS;AAAA,IAAA,GAEhBE,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A,QACvC,CAAC,MAAM,EAAE,cAAcsB;AAAAA,MAAA;AAExB,MAAIC,KAAqB,MACxBnB,EAAa,QAAQmB;AAAA,IACtB,GAGKC,IAAO,MAAM;AAClB,MAAApB,EAAa,QAAQ;AAAA,IAAA,GAOhBqB,IAAgB,MAAM;AACvB,UAAAb,EAAMR,EAAa,KAAK,EAAG;AAC/B,YAAMsB,IAAS1B,EAAM,QAAQI,EAAa,KAAM;AAChD,MAAIsB,EAAO,YACVxB,EAAK,qBAAqBwB,CAAM;AAAA,IACjC,GAGKC,IAAiB,MAClBf,EAAMR,EAAa,KAAK,IAAG,SAChBJ,EAAM,QAAQI,EAAa,KAAM;AAIjD,WAAAwB;AAAA,MACC,MAAM5B,EAAM;AAAA,MACZ,CAAC6B,GAAOC,MAAa;AACpB,QAAIR,EAAKO,CAAK,MAAMP,EAAKQ,CAAQ,KAC3BN;MAEP;AAAA,MACA;AAAA,QACC,OAAO;AAAA,MACR;AAAA,IAAA,GAGYO,EAAA;AAAA,MACZ,WAAAjB;AAAA,MACA,eAAAE;AAAA,MACA,YAAAC;AAAA,MACA,oBAAAE;AAAA,MACA,WAAAD;AAAA,MACA,mBAAAE;AAAA,MACA,MAAAI;AAAA,MACA,eAAAC;AAAA,MACA,aAAAJ;AAAA,MACA,gBAAAM;AAAA,IAAA,CACA;;;;;;;;;;;;;;;;;"}
|
package/dist/index239.js.map
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"index239.js","sources":["../src/components/CommaBox.vue"],"sourcesContent":["<template>\n\t<span\n\t\tv-for=\"(item, index) in options\"\n\t\t:key=\"item.valueHash\"\n\t\t:class=\"{\n\t\t\t'bb-commabox-item': true,\n\t\t\t'bb-commabox-item--focused': index === focusedIndex,\n\t\t\t'bb-commabox-item--has-comma': index !== options.length - 1,\n\t\t}\"\n\t\t:clearable=\"true\"\n\t\t:text=\"item.text\"\n\t\t@click:clear.stop=\"emit('option:unselected', item)\"\n\t\t>{{ item.text }}</span\n\t>\n</template>\n\n<script setup lang=\"ts\">\nimport { computed } from 'vue';\nimport { hash } from '@/utilities/functions/hash';\nimport { isNil } from '@/utilities/functions/isNil';\nimport { ref } from 'vue';\nimport { watch } from 'vue';\nimport type { Option } from '@/types/Option';\n\ntype Props = {\n\toptions: Option[];\n};\nconst props = defineProps<Props>();\n\nconst emit = defineEmits<{\n\t(e: 'option:unselected', option: Option): void;\n}>();\n\n/**\n * START FOCUS HANDLING\n */\n\nconst focusedIndex = ref<null | number>(null);\n\nconst canFocus = computed(() => props.options.some((o) => !o.disabled));\n\nconst findNextAvailableIndex = (offset = 1) => {\n\tconst initialValue = isNil(focusedIndex.value) ? -1 : focusedIndex.value!;\n\tlet newIndex = (initialValue + offset) % props.options.length;\n\twhile (props.options[newIndex].disabled && newIndex !== initialValue) {\n\t\tnewIndex = findNextAvailableIndex(offset + 1);\n\t}\n\treturn newIndex;\n};\n\nconst focusNext = () => {\n\tif (!canFocus.value) return;\n\tconst newIndex = findNextAvailableIndex();\n\tfocusedIndex.value = newIndex;\n};\nconst findPreviousAvailableIndex = (offset = 1) => {\n\tconst initialValue = isNil(focusedIndex.value) ? 0 : focusedIndex.value!;\n\tlet newIndex =\n\t\t(initialValue - offset + props.options.length) % props.options.length;\n\twhile (props.options[newIndex].disabled && newIndex !== initialValue) {\n\t\tnewIndex = findPreviousAvailableIndex(offset + 1);\n\t}\n\treturn newIndex;\n};\nconst focusPrevious = async () => {\n\tif (!canFocus.value) return;\n\tconst newIndex = findPreviousAvailableIndex();\n\tfocusedIndex.value = newIndex;\n};\n\nconst focusFirst = () => {\n\tif (!canFocus.value) return;\n\tlet newIndex = 0;\n\twhile (props.options[newIndex].disabled) {\n\t\tnewIndex++;\n\t}\n\tfocusedIndex.value = newIndex;\n};\n\nconst focusLast = () => {\n\tif (!canFocus.value) return;\n\tlet newIndex = props.options.length - 1;\n\twhile (props.options[newIndex].disabled && newIndex !== 0) {\n\t\tnewIndex--;\n\t}\n\tfocusedIndex.value = newIndex;\n};\nconst focusFirstSelected = () => {\n\tif (!canFocus.value) return;\n\tlet newIndex = 0;\n\twhile (\n\t\t!props.options[newIndex].selected &&\n\t\tprops.options.length !== newIndex\n\t) {\n\t\tnewIndex++;\n\t}\n\tfocusedIndex.value = newIndex;\n};\nconst focusLastSelected = () => {\n\tif (!canFocus.value) return;\n\tlet newIndex = props.options.length - 1;\n\twhile (props.options[newIndex].selected && newIndex !== 0) {\n\t\tnewIndex--;\n\t}\n\tfocusedIndex.value = newIndex;\n};\n\nconst focusByHash = (hash: Option['valueHash']) => {\n\tif (!canFocus.value) return;\n\tconst linkedOptionIndex = props.options.findIndex(\n\t\t(o) => o.valueHash === hash\n\t);\n\tif (linkedOptionIndex >= 0) {\n\t\tfocusedIndex.value = linkedOptionIndex;\n\t}\n};\n\nconst blur = () => {\n\tfocusedIndex.value = null;\n};\n\n/**\n * END FOCUS HANDLING\n */\n\nconst confirmOption = () => {\n\tif (!focusedIndex.value) return;\n\tconst option = props.options[focusedIndex.value];\n\tif (option.selected) {\n\t\temit('option:unselected', option);\n\t}\n};\n\nconst getHighlighted = () => {\n\tif (isNil(focusedIndex.value)) return;\n\tconst option = props.options[focusedIndex.value!];\n\treturn option;\n};\n\nwatch(\n\t() => props.options,\n\t(value, previous) => {\n\t\tif (hash(value) !== hash(previous)) {\n\t\t\tblur();\n\t\t}\n\t},\n\t{\n\t\tflush: 'post',\n\t}\n);\n\ndefineExpose({\n\tfocusNext,\n\tfocusPrevious,\n\tfocusFirst,\n\tfocusFirstSelected,\n\tfocusLast,\n\tfocusLastSelected,\n\tblur,\n\tconfirmOption,\n\tfocusByHash,\n\tgetHighlighted,\n});\n</script>\n\n<style lang=\"postcss\">\n@import '@/assets/css/CommaBox';\n</style>\n"],"names":["props","__props","emit","__emit","focusedIndex","ref","canFocus","computed","o","findNextAvailableIndex","offset","initialValue","isNil","newIndex","focusNext","findPreviousAvailableIndex","focusPrevious","focusFirst","focusLast","focusFirstSelected","focusLastSelected","focusByHash","hash","link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A,MACA,eAAAE;AAAA,MACA,YAAAC;AAAA,MACA,oBAAAE;AAAA,MACA,WAAAD;AAAA,MACA,mBAAAE;AAAA,MACA,MAAAI;AAAA,MACA,eAAAC;AAAA,MACA,aAAAJ;AAAA,MACA,gBAAAM;AAAA,IAAA,CACA;;;;;;;;;;;;;"}
|
package/dist/index24.js.map
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"index24.js","sources":["../src/components/BaseDialog/BaseDialog.vue"],"sourcesContent":["<template>\n\t<teleport to=\"body\">\n\t\t<div v-bind=\"overlayAttributes\" ref=\"overlay\">\n\t\t\t<div v-bind=\"panelAttributes\" ref=\"panel\">\n\t\t\t\t<div\n\t\t\t\t\tv-if=\"hasRenderedAtLeastOnce\"\n\t\t\t\t\tref=\"content\"\n\t\t\t\t\tclass=\"bb-base-dialog__content\"\n\t\t\t\t>\n\t\t\t\t\t<div ref=\"header\" class=\"bb-base-dialog__header\">\n\t\t\t\t\t\t<slot\n\t\t\t\t\t\t\t:close=\"onCloseClick\"\n\t\t\t\t\t\t\tname=\"header\"\n\t\t\t\t\t\t\t:title=\"title\"\n\t\t\t\t\t\t\t:title-id=\"titleId\"\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t<span :id=\"titleId\" class=\"bb-base-dialog__title\">\n\t\t\t\t\t\t\t\t<slot name=\"title\" :text=\"title\">{{ title }}</slot>\n\t\t\t\t\t\t\t</span>\n\t\t\t\t\t\t\t<span class=\"bb-base-dialog-close\">\n\t\t\t\t\t\t\t\t<button\n\t\t\t\t\t\t\t\t\tv-if=\"showClose\"\n\t\t\t\t\t\t\t\t\t:aria-label=\"closeLabel\"\n\t\t\t\t\t\t\t\t\ttype=\"button\"\n\t\t\t\t\t\t\t\t\t@click=\"onCloseClick\"\n\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t<slot name=\"close\">\n\t\t\t\t\t\t\t\t\t\t<span class=\"bb-base-dialog-close__icon\"\n\t\t\t\t\t\t\t\t\t\t\t><svg\n\t\t\t\t\t\t\t\t\t\t\t\taria-hidden=\"true\"\n\t\t\t\t\t\t\t\t\t\t\t\tfill=\"none\"\n\t\t\t\t\t\t\t\t\t\t\t\tviewBox=\"0 0 24 24\"\n\t\t\t\t\t\t\t\t\t\t\t\txmlns=\"http://www.w3.org/2000/svg\"\n\t\t\t\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t\t\t\t<path\n\t\t\t\t\t\t\t\t\t\t\t\t\td=\"M23 23L1 1M23 1L1 23\"\n\t\t\t\t\t\t\t\t\t\t\t\t\tstroke=\"currentColor\"\n\t\t\t\t\t\t\t\t\t\t\t\t\tstroke-linecap=\"round\"\n\t\t\t\t\t\t\t\t\t\t\t\t\tstroke-width=\"2\"\n\t\t\t\t\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\t\t\t\t</svg>\n\t\t\t\t\t\t\t\t\t\t</span>\n\t\t\t\t\t\t\t\t\t</slot>\n\t\t\t\t\t\t\t\t</button>\n\t\t\t\t\t\t\t</span>\n\t\t\t\t\t\t</slot>\n\t\t\t\t\t</div>\n\t\t\t\t\t<div ref=\"body\" class=\"bb-base-dialog__body scrollbar-border\">\n\t\t\t\t\t\t<slot\n\t\t\t\t\t\t\t:description-id=\"descriptionId\"\n\t\t\t\t\t\t\tname=\"description\"\n\t\t\t\t\t\t\t:text=\"description\"\n\t\t\t\t\t\t\t><div\n\t\t\t\t\t\t\t\tv-if=\"description\"\n\t\t\t\t\t\t\t\t:id=\"descriptionId\"\n\t\t\t\t\t\t\t\tclass=\"bb-base-dialog__description sr-only\"\n\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t{{ description }}\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t</slot>\n\t\t\t\t\t\t<slot></slot>\n\t\t\t\t\t</div>\n\t\t\t\t\t<div style=\"flex: 10000 10000 0%\"></div>\n\t\t\t\t\t<div ref=\"footer\" class=\"bb-base-dialog__footer\">\n\t\t\t\t\t\t<slot name=\"footer\"></slot>\n\t\t\t\t\t</div>\n\t\t\t\t</div>\n\t\t\t</div>\n\t\t</div>\n\t</teleport>\n</template>\n\n<script setup lang=\"ts\">\nimport {\n\tcomputed,\n\tonBeforeUnmount,\n\tonMounted,\n\tref,\n\tuseAttrs,\n\tnextTick,\n\tgetCurrentInstance,\n\twatch,\n} from 'vue';\nimport { throttle } from '@/utilities/functions/throttle';\nimport { useFocusTrap } from '@vueuse/integrations/useFocusTrap';\nimport { useId } from '@/composables/useId';\nimport { wait } from '@/utilities/functions/wait';\nimport { waitFor } from '@/utilities/functions/waitFor';\nimport type { CommonProps, Size } from '@/types/CommonProps';\nimport { useModalsState } from '@/composables/useModalsState';\nimport { useLogger } from '@/composables/useLogger';\n\nexport type Sizes = {\n\tsm: number;\n\tmd: number;\n\tlg: number;\n};\n\nexport type BaseDialogProps = Pick<\n\tCommonProps,\n\t| 'closeLabel'\n\t| 'compact'\n\t| 'disabled'\n\t| 'eager'\n\t| 'panelClasses'\n\t| 'overlayClasses'\n\t| 'persistent'\n\t| 'showClose'\n\t| 'title'\n\t| 'transition'\n\t| 'transitionDuration'\n> &\n\tSize<Sizes> & {\n\t\t/**\n\t\t * Description of the content of the modal. Extremely useful for accessibility reasons.\n\t\t */\n\t\tdescription?: string;\n\t\t/**\n\t\t * Elements that obtains focus immediately after opening the dialog.\n\t\t * By default it's the first tabbable item.\n\t\t */\n\t\tfocusTarget?: string;\n\t\t/**\n\t\t * Displays the modala as fulscreen with no margin to the page\n\t\t */\n\t\tfullscreen?: boolean;\n\t\t/**\n\t\t * Defines the state open / closed of the modal.\n\t\t */\n\t\tmodelValue?: boolean | null;\n\t};\n\nconst props = withDefaults(defineProps<BaseDialogProps>(), {\n\tcloseLabel: 'Chiudi modale',\n\tshowClose: true,\n\tsize: 'sm',\n\ttransition: 'fade',\n\ttransitionDuration: 350,\n\tpanelClasses: () => [],\n\toverlayClasses: () => [],\n});\n\nexport type BaseDialogSlots = {\n\theader?: (props: {\n\t\ttitleId: typeof titleId;\n\t\tclose: typeof onCloseClick;\n\t\ttitle: BaseDialogProps['title'];\n\t}) => any;\n\ttitle?: (props: { text: BaseDialogProps['title'] }) => any;\n\tclose?: (props: object) => any;\n\tdescription?: (props: {\n\t\tdescriptionId: typeof descriptionId;\n\t\ttext: BaseDialogProps['description'];\n\t}) => any;\n\tdefault?: (props: object) => any;\n\tfooter?: (props: object) => any;\n};\n\ndefineSlots<BaseDialogSlots>();\n\nexport type BaseDialogEvents = {\n\t(e: 'shown'): void;\n\t(e: 'hidden'): void;\n\t(e: 'update:modelValue', value: boolean): void;\n};\n\nconst emit = defineEmits<BaseDialogEvents>();\n\nconst titleId = `title_${useId().id.value}`;\nconst descriptionId = `description_${useId().id.value}`;\n\nconst observer = ref<ResizeObserver | null>(null);\nconst overlay = ref<HTMLElement | null>(null);\nconst panel = ref<HTMLElement | null>(null);\nconst content = ref<HTMLElement | null>(null);\nconst header = ref<HTMLElement | null>(null);\nconst body = ref<HTMLElement | null>(null);\nconst footer = ref<HTMLElement | null>(null);\nconst height = ref<number | null>(null);\n\n// @ts-expect-error possibly undef\nconst isNuxt = !!getCurrentInstance()?.proxy?.$nuxt;\n\nconst orderInStack = ref(0);\nconst isCurrent = computed(() => {\n\tconst { openedModals } = useModalsState();\n\treturn openedModals.value && openedModals.value === orderInStack.value;\n});\n\nconst { activate, deactivate } = useFocusTrap(panel, {\n\tinitialFocus: props.focusTarget ?? undefined,\n\tclickOutsideDeactivates: (event) => {\n\t\t// This is used when other teleports are running.\n\t\t// eg if you have a select inside a modal it will be in fact outside of the modal because of teleport\n\t\treturn event.target === overlay.value;\n\t},\n\tallowOutsideClick: true,\n\t/* On esc deactivate the trap, return focus and then close the modal */\n\tescapeDeactivates: () => {\n\t\tnextTick(() => {\n\t\t\temit('update:modelValue', false);\n\t\t});\n\t\treturn true;\n\t},\n});\n\nconst attrs = useAttrs();\n\nconst closeLabel = computed(() => props.closeLabel);\n\nonMounted(async () => {\n\tif (body.value) {\n\t\tobserver.value = new ResizeObserver(onContentGrow);\n\t\tobserver.value.observe(body.value);\n\t}\n\twindow.addEventListener('resize', onContentGrow);\n\n\tonContentGrow();\n\tif (!props.modelValue && !hasRenderedAtLeastOnce.value) return;\n\tif (isNuxt && !globalThis.document) return;\n\talignToModelValue();\n});\nonBeforeUnmount(() => {\n\twindow.removeEventListener('resize', onContentGrow);\n});\n\nconst open = ref(false);\nconst opening = ref(false);\nconst closed = ref(true);\nconst closing = ref(false);\nconst hasRenderedAtLeastOnce = ref(props.eager || props.modelValue);\n\nconst busy = computed(() => opening.value || closing.value);\n\nconst restrictBody = () => {\n\tif (!globalThis.document) return;\n\tconst scrollBarWidth =\n\t\twindow.innerWidth - document.documentElement.clientWidth;\n\tdocument.body.style.overflow = 'hidden';\n\tdocument.body.style.paddingRight = `${scrollBarWidth}px`;\n};\nconst releaseBody = () => {\n\tif (!globalThis.document) return;\n\tdocument.body.style.overflow = 'auto';\n\tdocument.body.style.paddingRight = '0px';\n};\n\nonBeforeUnmount(() => {\n\tif (props.modelValue) {\n\t\tconst { openedModals, modalHasClosed } = useModalsState();\n\t\tif (openedModals.value) {\n\t\t\tmodalHasClosed();\n\t\t\torderInStack.value = 0;\n\t\t\treleaseBody();\n\t\t}\n\t}\n});\n\n/**\n * When modelValue becomes true if the component wasn't rendered render it\n * and wait for it to be on the page (or transitions would not work).\n * Stash the latest focused element so we can return it later when it closes.\n * Focus on the panel upon opening.\n * ---\n * Notice all interactions update modelValue and then this function aligns the display to it\n */\nconst alignToModelValue = async () => {\n\tif (props.modelValue) {\n\t\tif (!hasRenderedAtLeastOnce.value) {\n\t\t\thasRenderedAtLeastOnce.value = true;\n\t\t\tawait waitFor(() => !!body.value);\n\t\t\tawait nextTick();\n\t\t\tif (body.value) {\n\t\t\t\tobserver.value = new ResizeObserver(onContentGrow);\n\t\t\t\tobserver.value.observe(body.value);\n\t\t\t}\n\t\t}\n\n\t\tclosed.value = false;\n\t\tclosing.value = false;\n\t\topening.value = true;\n\n\t\t// This prevents overscroll chaining (additional scrolling to the body when the modal has been completely scrolled)\n\t\tconst { modalHasOpened, openedModals } = useModalsState();\n\t\tmodalHasOpened();\n\t\torderInStack.value = openedModals.value;\n\t\trestrictBody();\n\n\t\tawait wait(props.transitionDuration);\n\t\topening.value = false;\n\t\topen.value = true;\n\t\temit('shown');\n\t\tactivate();\n\t} else {\n\t\tdeactivate();\n\t\topening.value = false;\n\t\topen.value = false;\n\t\tclosing.value = true;\n\n\t\tawait wait(props.transitionDuration);\n\n\t\tclosing.value = false;\n\t\tclosed.value = true;\n\t\tconst { modalHasClosed, openedModals } = useModalsState();\n\t\tmodalHasClosed();\n\t\torderInStack.value = 0;\n\t\tif (!openedModals.value) {\n\t\t\treleaseBody();\n\t\t}\n\t\temit('hidden');\n\t}\n};\n/**\n * Every time modelValue changes align the display to it\n */\nwatch(\n\t() => props.modelValue,\n\t() => {\n\t\tif (!props.modelValue && !hasRenderedAtLeastOnce.value) return;\n\t\tif (isNuxt && !globalThis.document) return;\n\t\talignToModelValue();\n\t},\n\t{ flush: 'post' }\n);\n\n/**\n * Disable scrolling\n */\nconst onOverlayScroll = (event: Event) => {\n\tif (event.target === overlay.value) {\n\t\tevent.preventDefault();\n\t}\n};\n\n/**\n * Close the modal on overlay click if not persistent\n */\nconst onOverlayClick = (event: MouseEvent) => {\n\tif (props.disabled || busy.value) return;\n\tif (overlay.value) {\n\t\tif (event.target === overlay.value) {\n\t\t\tif (!props.persistent) {\n\t\t\t\temit('update:modelValue', false);\n\t\t\t}\n\t\t}\n\t}\n};\n\n/**\n * On click on the X button\n */\nconst onCloseClick = () => {\n\tif (props.disabled || busy.value) return;\n\tdeactivate();\n\temit('update:modelValue', false);\n};\n\nconst overlayAttributes = computed(() => {\n\tconst classes = [\n\t\t{\n\t\t\t'bb-base-dialog bb-base-dialog__overlay': true,\n\t\t\t'bb-base-dialog--fullscreen': props.fullscreen,\n\t\t\t'bb-base-dialog--faded': !isCurrent.value,\n\t\t\t'bb-base-dialog--open': open.value,\n\t\t\t'bb-base-dialog--opening': opening.value,\n\t\t\t'bb-base-dialog--closed': closed.value,\n\t\t\t'bb-base-dialog--closing': closing.value,\n\t\t\t[`bb-base-dialog--transition-${props.transition}`]: true,\n\t\t},\n\t\tprops.overlayClasses,\n\t].flat();\n\tconst eventListeners = {\n\t\tonClick: onOverlayClick,\n\t\tonScroll: onOverlayScroll,\n\t\tonTouchmove: onOverlayScroll,\n\t\tonWheel: onOverlayScroll,\n\t\tonKeydown: onOverlayScroll,\n\t};\n\n\tconst style = {\n\t\ttransitionDuration: props.transitionDuration / 1000 + 's',\n\t};\n\treturn {\n\t\tclass: classes,\n\t\tstyle,\n\t\t...eventListeners,\n\t\t...attrs,\n\t};\n});\n\nconst panelAttributes = computed(() => {\n\tconst classes = [\n\t\t{\n\t\t\t'bb-base-dialog__panel': true,\n\t\t\t'bb-base-dialog__panel--compact': props.compact,\n\t\t},\n\t\tprops.panelClasses,\n\t].flat();\n\n\tconst accessibilityAttrs: {\n\t\t[key: string]: string | boolean;\n\t} = {\n\t\trole: 'dialog',\n\t\t'aria-modal': true,\n\t};\n\n\tif (hasRenderedAtLeastOnce.value) {\n\t\tif (props.title) {\n\t\t\taccessibilityAttrs['aria-labelledby'] = titleId;\n\t\t}\n\n\t\tif (props.description)\n\t\t\taccessibilityAttrs['aria-describedby'] = descriptionId;\n\t}\n\n\tlet maxWidth;\n\tconst sizes: Sizes = {\n\t\tsm: 384,\n\t\tmd: 652,\n\t\tlg: 896,\n\t};\n\tif (props.fullscreen) maxWidth = '100%';\n\telse if (typeof props.size === 'number') maxWidth = props.size + 'px';\n\telse if (props.size in sizes)\n\t\tmaxWidth = sizes[props.size as keyof Sizes] + 'px';\n\telse maxWidth = props.size + 'px';\n\n\tconst style = {\n\t\tmaxWidth,\n\t\ttransitionDuration: props.transitionDuration / 1000 + 's',\n\t};\n\n\treturn {\n\t\tclass: classes,\n\t\tstyle,\n\t\t...accessibilityAttrs,\n\t};\n});\n\nlet calledGrowTimes = 0;\n\n/**\n * This is called when content inside body changes.\n * Gets the total height the panel needs to be\n * It could be called numerous times so throttle every 300ms\n */\nconst onContentGrow = throttle(\n\tasync () => {\n\t\tcalledGrowTimes++;\n\t\tif (calledGrowTimes === 100) {\n\t\t\tconst { error } = useLogger();\n\t\t\terror(\n\t\t\t\t'Dialog is updating its height too often. Please check the content is reliably sized.'\n\t\t\t);\n\t\t}\n\t\tif (props.fullscreen) {\n\t\t\theight.value = window.innerHeight;\n\t\t\treturn;\n\t\t}\n\t\tif (header.value && body.value && footer.value) {\n\t\t\tconst contentHeight =\n\t\t\t\theader.value.scrollHeight +\n\t\t\t\tbody.value.scrollHeight +\n\t\t\t\tfooter.value.scrollHeight +\n\t\t\t\t2;\n\t\t\t/* Add two so renderless elements at the bottom are not cut off */\n\t\t\tif (content.value) {\n\t\t\t\tcontent.value.style.height = '0px';\n\t\t\t\tcontent.value.style.height = `${contentHeight + 2}px`;\n\t\t\t\t/**\n\t\t\t\t * Run until all transitions inside have completed\n\t\t\t\t */\n\t\t\t\tawait wait(30);\n\t\t\t\tif (header.value && body.value && footer.value) {\n\t\t\t\t\tconst contentHeight2 =\n\t\t\t\t\t\theader.value.scrollHeight +\n\t\t\t\t\t\tbody.value.scrollHeight +\n\t\t\t\t\t\tfooter.value.scrollHeight +\n\t\t\t\t\t\t2;\n\t\t\t\t\tif (contentHeight !== contentHeight2) onContentGrow();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t},\n\t200,\n\t{ trailing: true }\n);\n</script>\n\n<style lang=\"postcss\">\n@import '@/assets/css/BaseDialog';\n</style>\n"],"names":["props","__props","emit","__emit","titleId","useId","descriptionId","observer","ref","overlay","panel","content","header","body","footer","height","isNuxt","_b","_a","getCurrentInstance","orderInStack","isCurrent","computed","openedModals","useModalsState","activate","deactivate","useFocusTrap","event","nextTick","attrs","useAttrs","closeLabel","onMounted","onContentGrow","hasRenderedAtLeastOnce","alignToModelValue","onBeforeUnmount","open","opening","closed","closing","busy","restrictBody","scrollBarWidth","releaseBody","modalHasClosed","waitFor","modalHasOpened","wait","watch","onOverlayScroll","onOverlayClick","onCloseClick","overlayAttributes","classes","eventListeners","style","panelAttributes","accessibilityAttrs","maxWidth","sizes","calledGrowTimes","throttle","error","useLogger","contentHeight","contentHeight2"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAoIA,UAAMA,IAAQC,GAkCRC,IAAOC,GAEPC,IAAU,SAASC,EAAM,EAAE,GAAG,KAAK,IACnCC,IAAgB,eAAeD,EAAM,EAAE,GAAG,KAAK,IAE/CE,IAAWC,EAA2B,IAAI,GAC1CC,IAAUD,EAAwB,IAAI,GACtCE,IAAQF,EAAwB,IAAI,GACpCG,IAAUH,EAAwB,IAAI,GACtCI,IAASJ,EAAwB,IAAI,GACrCK,IAAOL,EAAwB,IAAI,GACnCM,IAASN,EAAwB,IAAI,GACrCO,IAASP,EAAmB,IAAI,GAGhCQ,IAAS,CAAC,GAACC,KAAAC,IAAAC,GAAA,MAAA,gBAAAD,EAAsB,UAAtB,QAAAD,EAA6B,QAExCG,IAAeZ,EAAI,CAAC,GACpBa,IAAYC,EAAS,MAAM;AAC1B,YAAA,EAAE,cAAAC,MAAiBC;AACzB,aAAOD,EAAa,SAASA,EAAa,UAAUH,EAAa;AAAA,IAAA,CACjE,GAEK,EAAE,UAAAK,GAAU,YAAAC,MAAeC,GAAajB,GAAO;AAAA,MACpD,cAAcV,EAAM,eAAe;AAAA,MACnC,yBAAyB,CAAC4B,MAGlBA,EAAM,WAAWnB,EAAQ;AAAA,MAEjC,mBAAmB;AAAA;AAAA,MAEnB,mBAAmB,OAClBoB,EAAS,MAAM;AACd,QAAA3B,EAAK,qBAAqB,EAAK;AAAA,MAAA,CAC/B,GACM;AAAA,IACR,CACA,GAEK4B,IAAQC,MAERC,IAAaV,EAAS,MAAMtB,EAAM,UAAU;AAElD,IAAAiC,GAAU,YAAY;AAQrB,MAPIpB,EAAK,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,YAAMyD,KAAQ;AAAA,QACb,UAAAG;AAAA,QACA,oBAAoB5D,EAAM,qBAAqB,MAAO;AAAA,MAAA;AAGhD,aAAA;AAAA,QACN,OAAOuD;AAAA,QACP,OAAAE;AAAA,QACA,GAAGE;AAAA,MAAA;AAAA,IACJ,CACA;AAED,QAAIG,IAAkB;AAOtB,UAAM5B,IAAgB6B;AAAA,MACrB,YAAY;AAEX,YADAD,KACIA,MAAoB,KAAK;AACtB,gBAAA,EAAE,OAAAE,MAAUC;AAClB,UAAAD;AAAA,YACC;AAAA,UAAA;AAAA,QAEF;AACA,YAAIhE,EAAM,YAAY;AACrB,UAAAe,EAAO,QAAQ,OAAO;AACtB;AAAA,QACD;AACA,YAAIH,EAAO,SAASC,EAAK,SAASC,EAAO,OAAO;AACzC,gBAAAoD,IACLtD,EAAO,MAAM,eACbC,EAAK,MAAM,eACXC,EAAO,MAAM,eACb;AAED,cAAIH,EAAQ,UACHA,EAAA,MAAM,MAAM,SAAS,OAC7BA,EAAQ,MAAM,MAAM,SAAS,GAAGuD,IAAgB,CAAC,MAIjD,MAAMjB,EAAK,EAAE,GACTrC,EAAO,SAASC,EAAK,SAASC,EAAO,QAAO;AACzC,kBAAAqD,IACLvD,EAAO,MAAM,eACbC,EAAK,MAAM,eACXC,EAAO,MAAM,eACb;AACG,YAAAoD,MAAkBC,KAA8BjC;UACrD;AAAA,QAEF;AAAA,MACD;AAAA,MACA;AAAA,MACA,EAAE,UAAU,GAAK;AAAA,IAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
package/dist/index241.js.map
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"index241.js","sources":["../src/utilities/functions/head.ts"],"sourcesContent":["/** Takes an array and returns the first item in it */\nexport const head = <T>(arr: T[]) => arr[0];\n"],"names":["head","arr"],"mappings":"AACO,MAAMA,IAAO,CAAIC,MAAaA,EAAI,CAAC;"}
|
package/dist/index242.js.map
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"index242.js","sources":["../src/utilities/functions/pickBy.ts"],"sourcesContent":["export const pickBy = <T extends object>(\n\tobj: T,\n\titeratee: (value: T[keyof T], key: keyof T, object: T) => boolean\n): Partial<T> => {\n\tconst accumulator: Partial<T> = {};\n\tfor (const key in obj) {\n\t\tif (Object.prototype.hasOwnProperty.call(obj, key)) {\n\t\t\tconst element = obj[key];\n\t\t\tif (iteratee(element, key, obj)) accumulator[key] = element;\n\t\t}\n\t}\n\treturn accumulator;\n};\n"],"names":["pickBy","obj","iteratee","accumulator","key","element"],"mappings":"AAAa,MAAAA,IAAS,CACrBC,GACAC,MACgB;AAChB,QAAMC,IAA0B,CAAA;AAChC,aAAWC,KAAOH;AACjB,QAAI,OAAO,UAAU,eAAe,KAAKA,GAAKG,CAAG,GAAG;AAC7C,YAAAC,IAAUJ,EAAIG,CAAG;AACvB,MAAIF,EAASG,GAASD,GAAKH,CAAG,MAAGE,EAAYC,CAAG,IAAIC;AAAA,IACrD;AAEM,SAAAF;AACR;"}
|
package/dist/index243.js.map
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"index243.js","sources":["../src/utilities/functions/noop.ts"],"sourcesContent":["/* \n This function is No-OP it does nothing\n*/\nexport const noop = () => {};\n"],"names":["noop"],"mappings":"AAGO,MAAMA,IAAO,MAAM;AAAC;"}
|
package/dist/index244.js.map
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"index244.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;"}
|
package/dist/index245.js.map
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"index245.js","sources":["../src/utilities/functions/findRightIndex.ts"],"sourcesContent":["/**\n * Same as find but from the end of an array\n */\nexport const findRightIndex = <T>(\n\tarr: T[],\n\titeratee: (value: T, index: number, arr: T[]) => boolean\n) => {\n\tfor (let index = arr.length - 1; index >= 0; index--) {\n\t\tconst element = arr[index];\n\t\tif (iteratee(element, index, arr)) {\n\t\t\treturn index;\n\t\t}\n\t}\n\treturn -1;\n};\n"],"names":["findRightIndex","arr","iteratee","index","element"],"mappings":"AAGa,MAAAA,IAAiB,CAC7BC,GACAC,MACI;AACJ,WAASC,IAAQF,EAAI,SAAS,GAAGE,KAAS,GAAGA,KAAS;AAC/C,UAAAC,IAAUH,EAAIE,CAAK;AACzB,QAAID,EAASE,GAASD,GAAOF,CAAG;AACxB,aAAAE;AAAA,EAET;AACO,SAAA;AACR;"}
|
package/dist/index246.js.map
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"index246.js","sources":["../node_modules/focusable-selectors/index.js"],"sourcesContent":["const not = {\n inert: ':not([inert]):not([inert] *)',\n negTabIndex: ':not([tabindex^=\"-\"])',\n disabled: ':not(:disabled)',\n}\n\nexport default [\n `a[href]${not.inert}${not.negTabIndex}`,\n `area[href]${not.inert}${not.negTabIndex}`,\n `input:not([type=\"hidden\"]):not([type=\"radio\"])${not.inert}${not.negTabIndex}${not.disabled}`,\n `input[type=\"radio\"]${not.inert}${not.negTabIndex}${not.disabled}`,\n `select${not.inert}${not.negTabIndex}${not.disabled}`,\n `textarea${not.inert}${not.negTabIndex}${not.disabled}`,\n `button${not.inert}${not.negTabIndex}${not.disabled}`,\n `details${not.inert} > summary:first-of-type${not.negTabIndex}`,\n // Discard until Firefox supports `:has()`\n // See: https://github.com/KittyGiraudel/focusable-selectors/issues/12\n // `details:not(:has(> summary))${not.inert}${not.negTabIndex}`,\n `iframe${not.inert}${not.negTabIndex}`,\n `audio[controls]${not.inert}${not.negTabIndex}`,\n `video[controls]${not.inert}${not.negTabIndex}`,\n `[contenteditable]${not.inert}${not.negTabIndex}`,\n `[tabindex]${not.inert}${not.negTabIndex}`,\n]\n"],"names":["not","selectors"],"mappings":"AAAA,MAAMA,IAAM;AAAA,EACV,OAAO;AAAA,EACP,aAAa;AAAA,EACb,UAAU;AACZ,GAEeC,IAAA;AAAA,EACb,UAAUD,EAAI,KAAK,GAAGA,EAAI,WAAW;AAAA,EACrC,aAAaA,EAAI,KAAK,GAAGA,EAAI,WAAW;AAAA,EACxC,iDAAiDA,EAAI,KAAK,GAAGA,EAAI,WAAW,GAAGA,EAAI,QAAQ;AAAA,EAC3F,sBAAsBA,EAAI,KAAK,GAAGA,EAAI,WAAW,GAAGA,EAAI,QAAQ;AAAA,EAChE,SAASA,EAAI,KAAK,GAAGA,EAAI,WAAW,GAAGA,EAAI,QAAQ;AAAA,EACnD,WAAWA,EAAI,KAAK,GAAGA,EAAI,WAAW,GAAGA,EAAI,QAAQ;AAAA,EACrD,SAASA,EAAI,KAAK,GAAGA,EAAI,WAAW,GAAGA,EAAI,QAAQ;AAAA,EACnD,UAAUA,EAAI,KAAK,2BAA2BA,EAAI,WAAW;AAAA;AAAA;AAAA;AAAA,EAI7D,SAASA,EAAI,KAAK,GAAGA,EAAI,WAAW;AAAA,EACpC,kBAAkBA,EAAI,KAAK,GAAGA,EAAI,WAAW;AAAA,EAC7C,kBAAkBA,EAAI,KAAK,GAAGA,EAAI,WAAW;AAAA,EAC7C,oBAAoBA,EAAI,KAAK,GAAGA,EAAI,WAAW;AAAA,EAC/C,aAAaA,EAAI,KAAK,GAAGA,EAAI,WAAW;AAC1C;","x_google_ignoreList":[0]}
|
package/dist/index247.js.map
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"index247.js","sources":["../src/utilities/functions/debounce.ts"],"sourcesContent":["export function debounce<T extends (...args: any[]) => any>(\n\tfunc: T,\n\twait: number\n): (...args: Parameters<T>) => void {\n\tlet timeoutId: ReturnType<typeof setTimeout> | undefined;\n\n\treturn function (this: any, ...args: Parameters<T>) {\n\t\tif (timeoutId !== undefined) {\n\t\t\tclearTimeout(timeoutId);\n\t\t}\n\n\t\ttimeoutId = setTimeout(() => {\n\t\t\tfunc.apply(this, args);\n\t\t}, wait);\n\t};\n}\n"],"names":["debounce","func","wait","timeoutId","args"],"mappings":"AAAgB,SAAAA,EACfC,GACAC,GACmC;AAC/B,MAAAC;AAEJ,SAAO,YAAwBC,GAAqB;AACnD,IAAID,MAAc,UACjB,aAAaA,CAAS,GAGvBA,IAAY,WAAW,MAAM;AACvB,MAAAF,EAAA,MAAM,MAAMG,CAAI;AAAA,OACnBF,CAAI;AAAA,EAAA;AAET;"}
|
package/dist/index248.js.map
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"index248.js","sources":["../node_modules/mime/dist/src/index.js"],"sourcesContent":["import otherTypes from '../types/other.js';\nimport standardTypes from '../types/standard.js';\nimport Mime from './Mime.js';\nexport { default as Mime } from './Mime.js';\nexport default new Mime(standardTypes, otherTypes)._freeze();\n//# sourceMappingURL=index.js.map"],"names":["index","Mime","standardTypes","otherTypes"],"mappings":";;;AAIA,MAAeA,IAAA,IAAIC,EAAKC,GAAeC,CAAU,EAAE,QAAS;","x_google_ignoreList":[0]}
|
package/dist/index249.js.map
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"index249.js","sources":["../src/utilities/functions/findInTree.ts"],"sourcesContent":["/**\n * Find the eleemnt for which iteratee rfeturns true in a tree like structure\n */\nexport const findInTree = <T extends Record<string, any>>(\n\titems: T[],\n\tkeyName: keyof T,\n\titeratee: (item: T) => boolean\n): null | T => {\n\treturn items.reduce((acc: null | T, curr) => {\n\t\tif (acc) return acc;\n\t\tif (iteratee(curr)) {\n\t\t\treturn curr;\n\t\t}\n\n\t\tif (keyName in curr) {\n\t\t\tconst fromChildren = findInTree(\n\t\t\t\t[].concat(curr[keyName]),\n\t\t\t\tkeyName,\n\t\t\t\titeratee\n\t\t\t);\n\t\t\tif (fromChildren) {\n\t\t\t\treturn fromChildren;\n\t\t\t}\n\t\t}\n\t\treturn acc;\n\t}, null);\n};\n"],"names":["findInTree","items","keyName","iteratee","acc","curr","fromChildren"],"mappings":"AAGO,MAAMA,IAAa,CACzBC,GACAC,GACAC,MAEOF,EAAM,OAAO,CAACG,GAAeC,MAAS;AAC5C,MAAID,EAAY,QAAAA;AACZ,MAAAD,EAASE,CAAI;AACT,WAAAA;AAGR,MAAIH,KAAWG,GAAM;AACpB,UAAMC,IAAeN;AAAA,MACpB,CAAA,EAAG,OAAOK,EAAKH,CAAO,CAAC;AAAA,MACvBA;AAAA,MACAC;AAAA,IAAA;AAED,QAAIG;AACI,aAAAA;AAAA,EAET;AACO,SAAAF;GACL,IAAI;"}
|
package/dist/index250.js.map
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"index250.js","sources":["../node_modules/lodash.deburr/index.js"],"sourcesContent":["/**\n * lodash (Custom Build) <https://lodash.com/>\n * Build: `lodash modularize exports=\"npm\" -o ./`\n * Copyright jQuery Foundation and other contributors <https://jquery.org/>\n * Released under MIT license <https://lodash.com/license>\n * Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE>\n * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors\n */\n\n/** Used as references for various `Number` constants. */\nvar INFINITY = 1 / 0;\n\n/** `Object#toString` result references. */\nvar symbolTag = '[object Symbol]';\n\n/** Used to match Latin Unicode letters (excluding mathematical operators). */\nvar reLatin = /[\\xc0-\\xd6\\xd8-\\xf6\\xf8-\\xff\\u0100-\\u017f]/g;\n\n/** Used to compose unicode character classes. */\nvar rsComboMarksRange = '\\\\u0300-\\\\u036f\\\\ufe20-\\\\ufe23',\n rsComboSymbolsRange = '\\\\u20d0-\\\\u20f0';\n\n/** Used to compose unicode capture groups. */\nvar rsCombo = '[' + rsComboMarksRange + rsComboSymbolsRange + ']';\n\n/**\n * Used to match [combining diacritical marks](https://en.wikipedia.org/wiki/Combining_Diacritical_Marks) and\n * [combining diacritical marks for symbols](https://en.wikipedia.org/wiki/Combining_Diacritical_Marks_for_Symbols).\n */\nvar reComboMark = RegExp(rsCombo, 'g');\n\n/** Used to map Latin Unicode letters to basic Latin letters. */\nvar deburredLetters = {\n // Latin-1 Supplement block.\n '\\xc0': 'A', '\\xc1': 'A', '\\xc2': 'A', '\\xc3': 'A', '\\xc4': 'A', '\\xc5': 'A',\n '\\xe0': 'a', '\\xe1': 'a', '\\xe2': 'a', '\\xe3': 'a', '\\xe4': 'a', '\\xe5': 'a',\n '\\xc7': 'C', '\\xe7': 'c',\n '\\xd0': 'D', '\\xf0': 'd',\n '\\xc8': 'E', '\\xc9': 'E', '\\xca': 'E', '\\xcb': 'E',\n '\\xe8': 'e', '\\xe9': 'e', '\\xea': 'e', '\\xeb': 'e',\n '\\xcc': 'I', '\\xcd': 'I', '\\xce': 'I', '\\xcf': 'I',\n '\\xec': 'i', '\\xed': 'i', '\\xee': 'i', '\\xef': 'i',\n '\\xd1': 'N', '\\xf1': 'n',\n '\\xd2': 'O', '\\xd3': 'O', '\\xd4': 'O', '\\xd5': 'O', '\\xd6': 'O', '\\xd8': 'O',\n '\\xf2': 'o', '\\xf3': 'o', '\\xf4': 'o', '\\xf5': 'o', '\\xf6': 'o', '\\xf8': 'o',\n '\\xd9': 'U', '\\xda': 'U', '\\xdb': 'U', '\\xdc': 'U',\n '\\xf9': 'u', '\\xfa': 'u', '\\xfb': 'u', '\\xfc': 'u',\n '\\xdd': 'Y', '\\xfd': 'y', '\\xff': 'y',\n '\\xc6': 'Ae', '\\xe6': 'ae',\n '\\xde': 'Th', '\\xfe': 'th',\n '\\xdf': 'ss',\n // Latin Extended-A block.\n '\\u0100': 'A', '\\u0102': 'A', '\\u0104': 'A',\n '\\u0101': 'a', '\\u0103': 'a', '\\u0105': 'a',\n '\\u0106': 'C', '\\u0108': 'C', '\\u010a': 'C', '\\u010c': 'C',\n '\\u0107': 'c', '\\u0109': 'c', '\\u010b': 'c', '\\u010d': 'c',\n '\\u010e': 'D', '\\u0110': 'D', '\\u010f': 'd', '\\u0111': 'd',\n '\\u0112': 'E', '\\u0114': 'E', '\\u0116': 'E', '\\u0118': 'E', '\\u011a': 'E',\n '\\u0113': 'e', '\\u0115': 'e', '\\u0117': 'e', '\\u0119': 'e', '\\u011b': 'e',\n '\\u011c': 'G', '\\u011e': 'G', '\\u0120': 'G', '\\u0122': 'G',\n '\\u011d': 'g', '\\u011f': 'g', '\\u0121': 'g', '\\u0123': 'g',\n '\\u0124': 'H', '\\u0126': 'H', '\\u0125': 'h', '\\u0127': 'h',\n '\\u0128': 'I', '\\u012a': 'I', '\\u012c': 'I', '\\u012e': 'I', '\\u0130': 'I',\n '\\u0129': 'i', '\\u012b': 'i', '\\u012d': 'i', '\\u012f': 'i', '\\u0131': 'i',\n '\\u0134': 'J', '\\u0135': 'j',\n '\\u0136': 'K', '\\u0137': 'k', '\\u0138': 'k',\n '\\u0139': 'L', '\\u013b': 'L', '\\u013d': 'L', '\\u013f': 'L', '\\u0141': 'L',\n '\\u013a': 'l', '\\u013c': 'l', '\\u013e': 'l', '\\u0140': 'l', '\\u0142': 'l',\n '\\u0143': 'N', '\\u0145': 'N', '\\u0147': 'N', '\\u014a': 'N',\n '\\u0144': 'n', '\\u0146': 'n', '\\u0148': 'n', '\\u014b': 'n',\n '\\u014c': 'O', '\\u014e': 'O', '\\u0150': 'O',\n '\\u014d': 'o', '\\u014f': 'o', '\\u0151': 'o',\n '\\u0154': 'R', '\\u0156': 'R', '\\u0158': 'R',\n '\\u0155': 'r', '\\u0157': 'r', '\\u0159': 'r',\n '\\u015a': 'S', '\\u015c': 'S', '\\u015e': 'S', '\\u0160': 'S',\n '\\u015b': 's', '\\u015d': 's', '\\u015f': 's', '\\u0161': 's',\n '\\u0162': 'T', '\\u0164': 'T', '\\u0166': 'T',\n '\\u0163': 't', '\\u0165': 't', '\\u0167': 't',\n '\\u0168': 'U', '\\u016a': 'U', '\\u016c': 'U', '\\u016e': 'U', '\\u0170': 'U', '\\u0172': 'U',\n '\\u0169': 'u', '\\u016b': 'u', '\\u016d': 'u', '\\u016f': 'u', '\\u0171': 'u', '\\u0173': 'u',\n '\\u0174': 'W', '\\u0175': 'w',\n '\\u0176': 'Y', '\\u0177': 'y', '\\u0178': 'Y',\n '\\u0179': 'Z', '\\u017b': 'Z', '\\u017d': 'Z',\n '\\u017a': 'z', '\\u017c': 'z', '\\u017e': 'z',\n '\\u0132': 'IJ', '\\u0133': 'ij',\n '\\u0152': 'Oe', '\\u0153': 'oe',\n '\\u0149': \"'n\", '\\u017f': 'ss'\n};\n\n/** Detect free variable `global` from Node.js. */\nvar freeGlobal = typeof global == 'object' && global && global.Object === Object && global;\n\n/** Detect free variable `self`. */\nvar freeSelf = typeof self == 'object' && self && self.Object === Object && self;\n\n/** Used as a reference to the global object. */\nvar root = freeGlobal || freeSelf || Function('return this')();\n\n/**\n * The base implementation of `_.propertyOf` without support for deep paths.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Function} Returns the new accessor function.\n */\nfunction basePropertyOf(object) {\n return function(key) {\n return object == null ? undefined : object[key];\n };\n}\n\n/**\n * Used by `_.deburr` to convert Latin-1 Supplement and Latin Extended-A\n * letters to basic Latin letters.\n *\n * @private\n * @param {string} letter The matched letter to deburr.\n * @returns {string} Returns the deburred letter.\n */\nvar deburrLetter = basePropertyOf(deburredLetters);\n\n/** Used for built-in method references. */\nvar objectProto = Object.prototype;\n\n/**\n * Used to resolve the\n * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)\n * of values.\n */\nvar objectToString = objectProto.toString;\n\n/** Built-in value references. */\nvar Symbol = root.Symbol;\n\n/** Used to convert symbols to primitives and strings. */\nvar symbolProto = Symbol ? Symbol.prototype : undefined,\n symbolToString = symbolProto ? symbolProto.toString : undefined;\n\n/**\n * The base implementation of `_.toString` which doesn't convert nullish\n * values to empty strings.\n *\n * @private\n * @param {*} value The value to process.\n * @returns {string} Returns the string.\n */\nfunction baseToString(value) {\n // Exit early for strings to avoid a performance hit in some environments.\n if (typeof value == 'string') {\n return value;\n }\n if (isSymbol(value)) {\n return symbolToString ? symbolToString.call(value) : '';\n }\n var result = (value + '');\n return (result == '0' && (1 / value) == -INFINITY) ? '-0' : result;\n}\n\n/**\n * Checks if `value` is object-like. A value is object-like if it's not `null`\n * and has a `typeof` result of \"object\".\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is object-like, else `false`.\n * @example\n *\n * _.isObjectLike({});\n * // => true\n *\n * _.isObjectLike([1, 2, 3]);\n * // => true\n *\n * _.isObjectLike(_.noop);\n * // => false\n *\n * _.isObjectLike(null);\n * // => false\n */\nfunction isObjectLike(value) {\n return !!value && typeof value == 'object';\n}\n\n/**\n * Checks if `value` is classified as a `Symbol` primitive or object.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a symbol, else `false`.\n * @example\n *\n * _.isSymbol(Symbol.iterator);\n * // => true\n *\n * _.isSymbol('abc');\n * // => false\n */\nfunction isSymbol(value) {\n return typeof value == 'symbol' ||\n (isObjectLike(value) && objectToString.call(value) == symbolTag);\n}\n\n/**\n * Converts `value` to a string. An empty string is returned for `null`\n * and `undefined` values. The sign of `-0` is preserved.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to process.\n * @returns {string} Returns the string.\n * @example\n *\n * _.toString(null);\n * // => ''\n *\n * _.toString(-0);\n * // => '-0'\n *\n * _.toString([1, 2, 3]);\n * // => '1,2,3'\n */\nfunction toString(value) {\n return value == null ? '' : baseToString(value);\n}\n\n/**\n * Deburrs `string` by converting\n * [Latin-1 Supplement](https://en.wikipedia.org/wiki/Latin-1_Supplement_(Unicode_block)#Character_table)\n * and [Latin Extended-A](https://en.wikipedia.org/wiki/Latin_Extended-A)\n * letters to basic Latin letters and removing\n * [combining diacritical marks](https://en.wikipedia.org/wiki/Combining_Diacritical_Marks).\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category String\n * @param {string} [string=''] The string to deburr.\n * @returns {string} Returns the deburred string.\n * @example\n *\n * _.deburr('déjà vu');\n * // => 'deja vu'\n */\nfunction deburr(string) {\n string = toString(string);\n return string && string.replace(reLatin, deburrLetter).replace(reComboMark, '');\n}\n\nmodule.exports = deburr;\n"],"names":["INFINITY","symbolTag","reLatin","rsComboMarksRange","rsComboSymbolsRange","rsCombo","reComboMark","deburredLetters","freeGlobal","global","freeSelf","root","basePropertyOf","object","key","deburrLetter","objectProto","objectToString","Symbol","symbolProto","symbolToString","baseToString","value","isSymbol","result","isObjectLike","toString","deburr","string","lodash_deburr"],"mappings":";AAUA,IAAIA,IAAW,OAGXC,IAAY,mBAGZC,IAAU,+CAGVC,IAAoB,kCACpBC,IAAsB,mBAGtBC,IAAU,MAAMF,IAAoBC,IAAsB,KAM1DE,IAAc,OAAOD,GAAS,GAAG,GAGjCE,IAAkB;AAAA;AAAA,EAEpB,GAAQ;AAAA,EAAM,GAAQ;AAAA,EAAK,GAAQ;AAAA,EAAK,GAAQ;AAAA,EAAK,GAAQ;AAAA,EAAK,GAAQ;AAAA,EAC1E,GAAQ;AAAA,EAAM,GAAQ;AAAA,EAAK,GAAQ;AAAA,EAAK,GAAQ;AAAA,EAAK,GAAQ;AAAA,EAAK,GAAQ;AAAA,EAC1E,GAAQ;AAAA,EAAM,GAAQ;AAAA,EACtB,GAAQ;AAAA,EAAM,GAAQ;AAAA,EACtB,GAAQ;AAAA,EAAM,GAAQ;AAAA,EAAK,GAAQ;AAAA,EAAK,GAAQ;AAAA,EAChD,GAAQ;AAAA,EAAM,GAAQ;AAAA,EAAK,GAAQ;AAAA,EAAK,GAAQ;AAAA,EAChD,GAAQ;AAAA,EAAM,GAAQ;AAAA,EAAK,GAAQ;AAAA,EAAK,GAAQ;AAAA,EAChD,GAAQ;AAAA,EAAM,GAAQ;AAAA,EAAK,GAAQ;AAAA,EAAK,GAAQ;AAAA,EAChD,GAAQ;AAAA,EAAM,GAAQ;AAAA,EACtB,GAAQ;AAAA,EAAM,GAAQ;AAAA,EAAK,GAAQ;AAAA,EAAK,GAAQ;AAAA,EAAK,GAA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OAAO,KAAKD,EAAaC,CAAK;AAChD;AAoBA,SAASK,EAAOC,GAAQ;AACtB,SAAAA,IAASF,EAASE,CAAM,GACjBA,KAAUA,EAAO,QAAQ1B,GAASa,CAAY,EAAE,QAAQT,GAAa,EAAE;AAChF;AAEA,IAAAuB,IAAiBF;;","x_google_ignoreList":[0]}
|
package/dist/index251.js.map
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"index251.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;"}
|
package/dist/index253.js.map
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"index253.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;"}
|
package/dist/index254.js.map
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"index254.js","sources":["../node_modules/focus-trap/dist/focus-trap.esm.js"],"sourcesContent":["/*!\n* focus-trap 7.5.4\n* @license MIT, https://github.com/focus-trap/focus-trap/blob/master/LICENSE\n*/\nimport { isFocusable, tabbable, focusable, isTabbable, getTabIndex } from 'tabbable';\n\nfunction ownKeys(e, r) {\n var t = Object.keys(e);\n if (Object.getOwnPropertySymbols) {\n var o = Object.getOwnPropertySymbols(e);\n r && (o = o.filter(function (r) {\n return Object.getOwnPropertyDescriptor(e, r).enumerable;\n })), t.push.apply(t, o);\n }\n return t;\n}\nfunction _objectSpread2(e) {\n for (var r = 1; r < arguments.length; r++) {\n var t = null != arguments[r] ? arguments[r] : {};\n r % 2 ? ownKeys(Object(t), !0).forEach(function (r) {\n _defineProperty(e, r, t[r]);\n }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) {\n Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r));\n });\n }\n return e;\n}\nfunction _defineProperty(obj, key, value) {\n key = _toPropertyKey(key);\n if (key in obj) {\n Object.defineProperty(obj, key, {\n value: value,\n enumerable: true,\n configurable: true,\n writable: true\n });\n } else {\n obj[key] = value;\n }\n return obj;\n}\nfunction _toPrimitive(input, hint) {\n if (typeof input !== \"object\" || input === null) return input;\n var prim = input[Symbol.toPrimitive];\n if (prim !== undefined) {\n var res = prim.call(input, hint || \"default\");\n if (typeof res !== \"object\") return res;\n throw new TypeError(\"@@toPrimitive must return a primitive value.\");\n }\n return (hint === \"string\" ? String : Number)(input);\n}\nfunction _toPropertyKey(arg) {\n var key = _toPrimitive(arg, \"string\");\n return typeof key === \"symbol\" ? key : String(key);\n}\n\nvar activeFocusTraps = {\n activateTrap: function activateTrap(trapStack, trap) {\n if (trapStack.length > 0) {\n var activeTrap = trapStack[trapStack.length - 1];\n if (activeTrap !== trap) {\n activeTrap.pause();\n }\n }\n var trapIndex = trapStack.indexOf(trap);\n if (trapIndex === -1) {\n trapStack.push(trap);\n } else {\n // move this existing trap to the front of the queue\n trapStack.splice(trapIndex, 1);\n trapStack.push(trap);\n }\n },\n deactivateTrap: function deactivateTrap(trapStack, trap) {\n var trapIndex = trapStack.indexOf(trap);\n if (trapIndex !== -1) {\n trapStack.splice(trapIndex, 1);\n }\n if (trapStack.length > 0) {\n trapStack[trapStack.length - 1].unpause();\n }\n }\n};\nvar isSelectableInput = function isSelectableInput(node) {\n return node.tagName && node.tagName.toLowerCase() === 'input' && typeof node.select === 'function';\n};\nvar isEscapeEvent = function isEscapeEvent(e) {\n return (e === null || e === void 0 ? void 0 : e.key) === 'Escape' || (e === null || e === void 0 ? void 0 : e.key) === 'Esc' || (e === null || e === void 0 ? void 0 : e.keyCode) === 27;\n};\nvar isTabEvent = function isTabEvent(e) {\n return (e === null || e === void 0 ? void 0 : e.key) === 'Tab' || (e === null || e === void 0 ? void 0 : e.keyCode) === 9;\n};\n\n// checks for TAB by default\nvar isKeyForward = function isKeyForward(e) {\n return isTabEvent(e) && !e.shiftKey;\n};\n\n// checks for SHIFT+TAB by default\nvar isKeyBackward = function isKeyBackward(e) {\n return isTabEvent(e) && e.shiftKey;\n};\nvar delay = function delay(fn) {\n return setTimeout(fn, 0);\n};\n\n// Array.find/findIndex() are not supported on IE; this replicates enough\n// of Array.findIndex() for our needs\nvar findIndex = function findIndex(arr, fn) {\n var idx = -1;\n arr.every(function (value, i) {\n if (fn(value)) {\n idx = i;\n return false; // break\n }\n\n return true; // next\n });\n\n return idx;\n};\n\n/**\n * Get an option's value when it could be a plain value, or a handler that provides\n * the value.\n * @param {*} value Option's value to check.\n * @param {...*} [params] Any parameters to pass to the handler, if `value` is a function.\n * @returns {*} The `value`, or the handler's returned value.\n */\nvar valueOrHandler = function valueOrHandler(value) {\n for (var _len = arguments.length, params = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n params[_key - 1] = arguments[_key];\n }\n return typeof value === 'function' ? value.apply(void 0, params) : value;\n};\nvar getActualTarget = function getActualTarget(event) {\n // NOTE: If the trap is _inside_ a shadow DOM, event.target will always be the\n // shadow host. However, event.target.composedPath() will be an array of\n // nodes \"clicked\" from inner-most (the actual element inside the shadow) to\n // outer-most (the host HTML document). If we have access to composedPath(),\n // then use its first element; otherwise, fall back to event.target (and\n // this only works for an _open_ shadow DOM; otherwise,\n // composedPath()[0] === event.target always).\n return event.target.shadowRoot && typeof event.composedPath === 'function' ? event.composedPath()[0] : event.target;\n};\n\n// NOTE: this must be _outside_ `createFocusTrap()` to make sure all traps in this\n// current instance use the same stack if `userOptions.trapStack` isn't specified\nvar internalTrapStack = [];\nvar createFocusTrap = function createFocusTrap(elements, userOptions) {\n // SSR: a live trap shouldn't be created in this type of environment so this\n // should be safe code to execute if the `document` option isn't specified\n var doc = (userOptions === null || userOptions === void 0 ? void 0 : userOptions.document) || document;\n var trapStack = (userOptions === null || userOptions === void 0 ? void 0 : userOptions.trapStack) || internalTrapStack;\n var config = _objectSpread2({\n returnFocusOnDeactivate: true,\n escapeDeactivates: true,\n delayInitialFocus: true,\n isKeyForward: isKeyForward,\n isKeyBackward: isKeyBackward\n }, userOptions);\n var state = {\n // containers given to createFocusTrap()\n // @type {Array<HTMLElement>}\n containers: [],\n // list of objects identifying tabbable nodes in `containers` in the trap\n // NOTE: it's possible that a group has no tabbable nodes if nodes get removed while the trap\n // is active, but the trap should never get to a state where there isn't at least one group\n // with at least one tabbable node in it (that would lead to an error condition that would\n // result in an error being thrown)\n // @type {Array<{\n // container: HTMLElement,\n // tabbableNodes: Array<HTMLElement>, // empty if none\n // focusableNodes: Array<HTMLElement>, // empty if none\n // posTabIndexesFound: boolean,\n // firstTabbableNode: HTMLElement|undefined,\n // lastTabbableNode: HTMLElement|undefined,\n // firstDomTabbableNode: HTMLElement|undefined,\n // lastDomTabbableNode: HTMLElement|undefined,\n // nextTabbableNode: (node: HTMLElement, forward: boolean) => HTMLElement|undefined\n // }>}\n containerGroups: [],\n // same order/length as `containers` list\n\n // references to objects in `containerGroups`, but only those that actually have\n // tabbable nodes in them\n // NOTE: same order as `containers` and `containerGroups`, but __not necessarily__\n // the same length\n tabbableGroups: [],\n nodeFocusedBeforeActivation: null,\n mostRecentlyFocusedNode: null,\n active: false,\n paused: false,\n // timer ID for when delayInitialFocus is true and initial focus in this trap\n // has been delayed during activation\n delayInitialFocusTimer: undefined,\n // the most recent KeyboardEvent for the configured nav key (typically [SHIFT+]TAB), if any\n recentNavEvent: undefined\n };\n var trap; // eslint-disable-line prefer-const -- some private functions reference it, and its methods reference private functions, so we must declare here and define later\n\n /**\n * Gets a configuration option value.\n * @param {Object|undefined} configOverrideOptions If true, and option is defined in this set,\n * value will be taken from this object. Otherwise, value will be taken from base configuration.\n * @param {string} optionName Name of the option whose value is sought.\n * @param {string|undefined} [configOptionName] Name of option to use __instead of__ `optionName`\n * IIF `configOverrideOptions` is not defined. Otherwise, `optionName` is used.\n */\n var getOption = function getOption(configOverrideOptions, optionName, configOptionName) {\n return configOverrideOptions && configOverrideOptions[optionName] !== undefined ? configOverrideOptions[optionName] : config[configOptionName || optionName];\n };\n\n /**\n * Finds the index of the container that contains the element.\n * @param {HTMLElement} element\n * @param {Event} [event] If available, and `element` isn't directly found in any container,\n * the event's composed path is used to see if includes any known trap containers in the\n * case where the element is inside a Shadow DOM.\n * @returns {number} Index of the container in either `state.containers` or\n * `state.containerGroups` (the order/length of these lists are the same); -1\n * if the element isn't found.\n */\n var findContainerIndex = function findContainerIndex(element, event) {\n var composedPath = typeof (event === null || event === void 0 ? void 0 : event.composedPath) === 'function' ? event.composedPath() : undefined;\n // NOTE: search `containerGroups` because it's possible a group contains no tabbable\n // nodes, but still contains focusable nodes (e.g. if they all have `tabindex=-1`)\n // and we still need to find the element in there\n return state.containerGroups.findIndex(function (_ref) {\n var container = _ref.container,\n tabbableNodes = _ref.tabbableNodes;\n return container.contains(element) || ( // fall back to explicit tabbable search which will take into consideration any\n // web components if the `tabbableOptions.getShadowRoot` option was used for\n // the trap, enabling shadow DOM support in tabbable (`Node.contains()` doesn't\n // look inside web components even if open)\n composedPath === null || composedPath === void 0 ? void 0 : composedPath.includes(container)) || tabbableNodes.find(function (node) {\n return node === element;\n });\n });\n };\n\n /**\n * Gets the node for the given option, which is expected to be an option that\n * can be either a DOM node, a string that is a selector to get a node, `false`\n * (if a node is explicitly NOT given), or a function that returns any of these\n * values.\n * @param {string} optionName\n * @returns {undefined | false | HTMLElement | SVGElement} Returns\n * `undefined` if the option is not specified; `false` if the option\n * resolved to `false` (node explicitly not given); otherwise, the resolved\n * DOM node.\n * @throws {Error} If the option is set, not `false`, and is not, or does not\n * resolve to a node.\n */\n var getNodeForOption = function getNodeForOption(optionName) {\n var optionValue = config[optionName];\n if (typeof optionValue === 'function') {\n for (var _len2 = arguments.length, params = new Array(_len2 > 1 ? _len2 - 1 : 0), _key2 = 1; _key2 < _len2; _key2++) {\n params[_key2 - 1] = arguments[_key2];\n }\n optionValue = optionValue.apply(void 0, params);\n }\n if (optionValue === true) {\n optionValue = undefined; // use default value\n }\n\n if (!optionValue) {\n if (optionValue === undefined || optionValue === false) {\n return optionValue;\n }\n // else, empty string (invalid), null (invalid), 0 (invalid)\n\n throw new Error(\"`\".concat(optionName, \"` was specified but was not a node, or did not return a node\"));\n }\n var node = optionValue; // could be HTMLElement, SVGElement, or non-empty string at this point\n\n if (typeof optionValue === 'string') {\n node = doc.querySelector(optionValue); // resolve to node, or null if fails\n if (!node) {\n throw new Error(\"`\".concat(optionName, \"` as selector refers to no known node\"));\n }\n }\n return node;\n };\n var getInitialFocusNode = function getInitialFocusNode() {\n var node = getNodeForOption('initialFocus');\n\n // false explicitly indicates we want no initialFocus at all\n if (node === false) {\n return false;\n }\n if (node === undefined || !isFocusable(node, config.tabbableOptions)) {\n // option not specified nor focusable: use fallback options\n if (findContainerIndex(doc.activeElement) >= 0) {\n node = doc.activeElement;\n } else {\n var firstTabbableGroup = state.tabbableGroups[0];\n var firstTabbableNode = firstTabbableGroup && firstTabbableGroup.firstTabbableNode;\n\n // NOTE: `fallbackFocus` option function cannot return `false` (not supported)\n node = firstTabbableNode || getNodeForOption('fallbackFocus');\n }\n }\n if (!node) {\n throw new Error('Your focus-trap needs to have at least one focusable element');\n }\n return node;\n };\n var updateTabbableNodes = function updateTabbableNodes() {\n state.containerGroups = state.containers.map(function (container) {\n var tabbableNodes = tabbable(container, config.tabbableOptions);\n\n // NOTE: if we have tabbable nodes, we must have focusable nodes; focusable nodes\n // are a superset of tabbable nodes since nodes with negative `tabindex` attributes\n // are focusable but not tabbable\n var focusableNodes = focusable(container, config.tabbableOptions);\n var firstTabbableNode = tabbableNodes.length > 0 ? tabbableNodes[0] : undefined;\n var lastTabbableNode = tabbableNodes.length > 0 ? tabbableNodes[tabbableNodes.length - 1] : undefined;\n var firstDomTabbableNode = focusableNodes.find(function (node) {\n return isTabbable(node);\n });\n var lastDomTabbableNode = focusableNodes.slice().reverse().find(function (node) {\n return isTabbable(node);\n });\n var posTabIndexesFound = !!tabbableNodes.find(function (node) {\n return getTabIndex(node) > 0;\n });\n return {\n container: container,\n tabbableNodes: tabbableNodes,\n focusableNodes: focusableNodes,\n /** True if at least one node with positive `tabindex` was found in this container. */\n posTabIndexesFound: posTabIndexesFound,\n /** First tabbable node in container, __tabindex__ order; `undefined` if none. */\n firstTabbableNode: firstTabbableNode,\n /** Last tabbable node in container, __tabindex__ order; `undefined` if none. */\n lastTabbableNode: lastTabbableNode,\n // NOTE: DOM order is NOT NECESSARILY \"document position\" order, but figuring that out\n // would require more than just https://developer.mozilla.org/en-US/docs/Web/API/Node/compareDocumentPosition\n // because that API doesn't work with Shadow DOM as well as it should (@see\n // https://github.com/whatwg/dom/issues/320) and since this first/last is only needed, so far,\n // to address an edge case related to positive tabindex support, this seems like a much easier,\n // \"close enough most of the time\" alternative for positive tabindexes which should generally\n // be avoided anyway...\n /** First tabbable node in container, __DOM__ order; `undefined` if none. */\n firstDomTabbableNode: firstDomTabbableNode,\n /** Last tabbable node in container, __DOM__ order; `undefined` if none. */\n lastDomTabbableNode: lastDomTabbableNode,\n /**\n * Finds the __tabbable__ node that follows the given node in the specified direction,\n * in this container, if any.\n * @param {HTMLElement} node\n * @param {boolean} [forward] True if going in forward tab order; false if going\n * in reverse.\n * @returns {HTMLElement|undefined} The next tabbable node, if any.\n */\n nextTabbableNode: function nextTabbableNode(node) {\n var forward = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;\n var nodeIdx = tabbableNodes.indexOf(node);\n if (nodeIdx < 0) {\n // either not tabbable nor focusable, or was focused but not tabbable (negative tabindex):\n // since `node` should at least have been focusable, we assume that's the case and mimic\n // what browsers do, which is set focus to the next node in __document position order__,\n // regardless of positive tabindexes, if any -- and for reasons explained in the NOTE\n // above related to `firstDomTabbable` and `lastDomTabbable` properties, we fall back to\n // basic DOM order\n if (forward) {\n return focusableNodes.slice(focusableNodes.indexOf(node) + 1).find(function (el) {\n return isTabbable(el);\n });\n }\n return focusableNodes.slice(0, focusableNodes.indexOf(node)).reverse().find(function (el) {\n return isTabbable(el);\n });\n }\n return tabbableNodes[nodeIdx + (forward ? 1 : -1)];\n }\n };\n });\n state.tabbableGroups = state.containerGroups.filter(function (group) {\n return group.tabbableNodes.length > 0;\n });\n\n // throw if no groups have tabbable nodes and we don't have a fallback focus node either\n if (state.tabbableGroups.length <= 0 && !getNodeForOption('fallbackFocus') // returning false not supported for this option\n ) {\n throw new Error('Your focus-trap must have at least one container with at least one tabbable node in it at all times');\n }\n\n // NOTE: Positive tabindexes are only properly supported in single-container traps because\n // doing it across multiple containers where tabindexes could be all over the place\n // would require Tabbable to support multiple containers, would require additional\n // specialized Shadow DOM support, and would require Tabbable's multi-container support\n // to look at those containers in document position order rather than user-provided\n // order (as they are treated in Focus-trap, for legacy reasons). See discussion on\n // https://github.com/focus-trap/focus-trap/issues/375 for more details.\n if (state.containerGroups.find(function (g) {\n return g.posTabIndexesFound;\n }) && state.containerGroups.length > 1) {\n throw new Error(\"At least one node with a positive tabindex was found in one of your focus-trap's multiple containers. Positive tabindexes are only supported in single-container focus-traps.\");\n }\n };\n\n /**\n * Gets the current activeElement. If it's a web-component and has open shadow-root\n * it will recursively search inside shadow roots for the \"true\" activeElement.\n *\n * @param {Document | ShadowRoot} el\n *\n * @returns {HTMLElement} The element that currently has the focus\n **/\n var getActiveElement = function getActiveElement(el) {\n var activeElement = el.activeElement;\n if (!activeElement) {\n return;\n }\n if (activeElement.shadowRoot && activeElement.shadowRoot.activeElement !== null) {\n return getActiveElement(activeElement.shadowRoot);\n }\n return activeElement;\n };\n var tryFocus = function tryFocus(node) {\n if (node === false) {\n return;\n }\n if (node === getActiveElement(document)) {\n return;\n }\n if (!node || !node.focus) {\n tryFocus(getInitialFocusNode());\n return;\n }\n node.focus({\n preventScroll: !!config.preventScroll\n });\n // NOTE: focus() API does not trigger focusIn event so set MRU node manually\n state.mostRecentlyFocusedNode = node;\n if (isSelectableInput(node)) {\n node.select();\n }\n };\n var getReturnFocusNode = function getReturnFocusNode(previousActiveElement) {\n var node = getNodeForOption('setReturnFocus', previousActiveElement);\n return node ? node : node === false ? false : previousActiveElement;\n };\n\n /**\n * Finds the next node (in either direction) where focus should move according to a\n * keyboard focus-in event.\n * @param {Object} params\n * @param {Node} [params.target] Known target __from which__ to navigate, if any.\n * @param {KeyboardEvent|FocusEvent} [params.event] Event to use if `target` isn't known (event\n * will be used to determine the `target`). Ignored if `target` is specified.\n * @param {boolean} [params.isBackward] True if focus should move backward.\n * @returns {Node|undefined} The next node, or `undefined` if a next node couldn't be\n * determined given the current state of the trap.\n */\n var findNextNavNode = function findNextNavNode(_ref2) {\n var target = _ref2.target,\n event = _ref2.event,\n _ref2$isBackward = _ref2.isBackward,\n isBackward = _ref2$isBackward === void 0 ? false : _ref2$isBackward;\n target = target || getActualTarget(event);\n updateTabbableNodes();\n var destinationNode = null;\n if (state.tabbableGroups.length > 0) {\n // make sure the target is actually contained in a group\n // NOTE: the target may also be the container itself if it's focusable\n // with tabIndex='-1' and was given initial focus\n var containerIndex = findContainerIndex(target, event);\n var containerGroup = containerIndex >= 0 ? state.containerGroups[containerIndex] : undefined;\n if (containerIndex < 0) {\n // target not found in any group: quite possible focus has escaped the trap,\n // so bring it back into...\n if (isBackward) {\n // ...the last node in the last group\n destinationNode = state.tabbableGroups[state.tabbableGroups.length - 1].lastTabbableNode;\n } else {\n // ...the first node in the first group\n destinationNode = state.tabbableGroups[0].firstTabbableNode;\n }\n } else if (isBackward) {\n // REVERSE\n\n // is the target the first tabbable node in a group?\n var startOfGroupIndex = findIndex(state.tabbableGroups, function (_ref3) {\n var firstTabbableNode = _ref3.firstTabbableNode;\n return target === firstTabbableNode;\n });\n if (startOfGroupIndex < 0 && (containerGroup.container === target || isFocusable(target, config.tabbableOptions) && !isTabbable(target, config.tabbableOptions) && !containerGroup.nextTabbableNode(target, false))) {\n // an exception case where the target is either the container itself, or\n // a non-tabbable node that was given focus (i.e. tabindex is negative\n // and user clicked on it or node was programmatically given focus)\n // and is not followed by any other tabbable node, in which\n // case, we should handle shift+tab as if focus were on the container's\n // first tabbable node, and go to the last tabbable node of the LAST group\n startOfGroupIndex = containerIndex;\n }\n if (startOfGroupIndex >= 0) {\n // YES: then shift+tab should go to the last tabbable node in the\n // previous group (and wrap around to the last tabbable node of\n // the LAST group if it's the first tabbable node of the FIRST group)\n var destinationGroupIndex = startOfGroupIndex === 0 ? state.tabbableGroups.length - 1 : startOfGroupIndex - 1;\n var destinationGroup = state.tabbableGroups[destinationGroupIndex];\n destinationNode = getTabIndex(target) >= 0 ? destinationGroup.lastTabbableNode : destinationGroup.lastDomTabbableNode;\n } else if (!isTabEvent(event)) {\n // user must have customized the nav keys so we have to move focus manually _within_\n // the active group: do this based on the order determined by tabbable()\n destinationNode = containerGroup.nextTabbableNode(target, false);\n }\n } else {\n // FORWARD\n\n // is the target the last tabbable node in a group?\n var lastOfGroupIndex = findIndex(state.tabbableGroups, function (_ref4) {\n var lastTabbableNode = _ref4.lastTabbableNode;\n return target === lastTabbableNode;\n });\n if (lastOfGroupIndex < 0 && (containerGroup.container === target || isFocusable(target, config.tabbableOptions) && !isTabbable(target, config.tabbableOptions) && !containerGroup.nextTabbableNode(target))) {\n // an exception case where the target is the container itself, or\n // a non-tabbable node that was given focus (i.e. tabindex is negative\n // and user clicked on it or node was programmatically given focus)\n // and is not followed by any other tabbable node, in which\n // case, we should handle tab as if focus were on the container's\n // last tabbable node, and go to the first tabbable node of the FIRST group\n lastOfGroupIndex = containerIndex;\n }\n if (lastOfGroupIndex >= 0) {\n // YES: then tab should go to the first tabbable node in the next\n // group (and wrap around to the first tabbable node of the FIRST\n // group if it's the last tabbable node of the LAST group)\n var _destinationGroupIndex = lastOfGroupIndex === state.tabbableGroups.length - 1 ? 0 : lastOfGroupIndex + 1;\n var _destinationGroup = state.tabbableGroups[_destinationGroupIndex];\n destinationNode = getTabIndex(target) >= 0 ? _destinationGroup.firstTabbableNode : _destinationGroup.firstDomTabbableNode;\n } else if (!isTabEvent(event)) {\n // user must have customized the nav keys so we have to move focus manually _within_\n // the active group: do this based on the order determined by tabbable()\n destinationNode = containerGroup.nextTabbableNode(target);\n }\n }\n } else {\n // no groups available\n // NOTE: the fallbackFocus option does not support returning false to opt-out\n destinationNode = getNodeForOption('fallbackFocus');\n }\n return destinationNode;\n };\n\n // This needs to be done on mousedown and touchstart instead of click\n // so that it precedes the focus event.\n var checkPointerDown = function checkPointerDown(e) {\n var target = getActualTarget(e);\n if (findContainerIndex(target, e) >= 0) {\n // allow the click since it ocurred inside the trap\n return;\n }\n if (valueOrHandler(config.clickOutsideDeactivates, e)) {\n // immediately deactivate the trap\n trap.deactivate({\n // NOTE: by setting `returnFocus: false`, deactivate() will do nothing,\n // which will result in the outside click setting focus to the node\n // that was clicked (and if not focusable, to \"nothing\"); by setting\n // `returnFocus: true`, we'll attempt to re-focus the node originally-focused\n // on activation (or the configured `setReturnFocus` node), whether the\n // outside click was on a focusable node or not\n returnFocus: config.returnFocusOnDeactivate\n });\n return;\n }\n\n // This is needed for mobile devices.\n // (If we'll only let `click` events through,\n // then on mobile they will be blocked anyways if `touchstart` is blocked.)\n if (valueOrHandler(config.allowOutsideClick, e)) {\n // allow the click outside the trap to take place\n return;\n }\n\n // otherwise, prevent the click\n e.preventDefault();\n };\n\n // In case focus escapes the trap for some strange reason, pull it back in.\n // NOTE: the focusIn event is NOT cancelable, so if focus escapes, it may cause unexpected\n // scrolling if the node that got focused was out of view; there's nothing we can do to\n // prevent that from happening by the time we discover that focus escaped\n var checkFocusIn = function checkFocusIn(event) {\n var target = getActualTarget(event);\n var targetContained = findContainerIndex(target, event) >= 0;\n\n // In Firefox when you Tab out of an iframe the Document is briefly focused.\n if (targetContained || target instanceof Document) {\n if (targetContained) {\n state.mostRecentlyFocusedNode = target;\n }\n } else {\n // escaped! pull it back in to where it just left\n event.stopImmediatePropagation();\n\n // focus will escape if the MRU node had a positive tab index and user tried to nav forward;\n // it will also escape if the MRU node had a 0 tab index and user tried to nav backward\n // toward a node with a positive tab index\n var nextNode; // next node to focus, if we find one\n var navAcrossContainers = true;\n if (state.mostRecentlyFocusedNode) {\n if (getTabIndex(state.mostRecentlyFocusedNode) > 0) {\n // MRU container index must be >=0 otherwise we wouldn't have it as an MRU node...\n var mruContainerIdx = findContainerIndex(state.mostRecentlyFocusedNode);\n // there MAY not be any tabbable nodes in the container if there are at least 2 containers\n // and the MRU node is focusable but not tabbable (focus-trap requires at least 1 container\n // with at least one tabbable node in order to function, so this could be the other container\n // with nothing tabbable in it)\n var tabbableNodes = state.containerGroups[mruContainerIdx].tabbableNodes;\n if (tabbableNodes.length > 0) {\n // MRU tab index MAY not be found if the MRU node is focusable but not tabbable\n var mruTabIdx = tabbableNodes.findIndex(function (node) {\n return node === state.mostRecentlyFocusedNode;\n });\n if (mruTabIdx >= 0) {\n if (config.isKeyForward(state.recentNavEvent)) {\n if (mruTabIdx + 1 < tabbableNodes.length) {\n nextNode = tabbableNodes[mruTabIdx + 1];\n navAcrossContainers = false;\n }\n // else, don't wrap within the container as focus should move to next/previous\n // container\n } else {\n if (mruTabIdx - 1 >= 0) {\n nextNode = tabbableNodes[mruTabIdx - 1];\n navAcrossContainers = false;\n }\n // else, don't wrap within the container as focus should move to next/previous\n // container\n }\n // else, don't find in container order without considering direction too\n }\n }\n // else, no tabbable nodes in that container (which means we must have at least one other\n // container with at least one tabbable node in it, otherwise focus-trap would've thrown\n // an error the last time updateTabbableNodes() was run): find next node among all known\n // containers\n } else {\n // check to see if there's at least one tabbable node with a positive tab index inside\n // the trap because focus seems to escape when navigating backward from a tabbable node\n // with tabindex=0 when this is the case (instead of wrapping to the tabbable node with\n // the greatest positive tab index like it should)\n if (!state.containerGroups.some(function (g) {\n return g.tabbableNodes.some(function (n) {\n return getTabIndex(n) > 0;\n });\n })) {\n // no containers with tabbable nodes with positive tab indexes which means the focus\n // escaped for some other reason and we should just execute the fallback to the\n // MRU node or initial focus node, if any\n navAcrossContainers = false;\n }\n }\n } else {\n // no MRU node means we're likely in some initial condition when the trap has just\n // been activated and initial focus hasn't been given yet, in which case we should\n // fall through to trying to focus the initial focus node, which is what should\n // happen below at this point in the logic\n navAcrossContainers = false;\n }\n if (navAcrossContainers) {\n nextNode = findNextNavNode({\n // move FROM the MRU node, not event-related node (which will be the node that is\n // outside the trap causing the focus escape we're trying to fix)\n target: state.mostRecentlyFocusedNode,\n isBackward: config.isKeyBackward(state.recentNavEvent)\n });\n }\n if (nextNode) {\n tryFocus(nextNode);\n } else {\n tryFocus(state.mostRecentlyFocusedNode || getInitialFocusNode());\n }\n }\n state.recentNavEvent = undefined; // clear\n };\n\n // Hijack key nav events on the first and last focusable nodes of the trap,\n // in order to prevent focus from escaping. If it escapes for even a\n // moment it can end up scrolling the page and causing confusion so we\n // kind of need to capture the action at the keydown phase.\n var checkKeyNav = function checkKeyNav(event) {\n var isBackward = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;\n state.recentNavEvent = event;\n var destinationNode = findNextNavNode({\n event: event,\n isBackward: isBackward\n });\n if (destinationNode) {\n if (isTabEvent(event)) {\n // since tab natively moves focus, we wouldn't have a destination node unless we\n // were on the edge of a container and had to move to the next/previous edge, in\n // which case we want to prevent default to keep the browser from moving focus\n // to where it normally would\n event.preventDefault();\n }\n tryFocus(destinationNode);\n }\n // else, let the browser take care of [shift+]tab and move the focus\n };\n\n var checkKey = function checkKey(event) {\n if (isEscapeEvent(event) && valueOrHandler(config.escapeDeactivates, event) !== false) {\n event.preventDefault();\n trap.deactivate();\n return;\n }\n if (config.isKeyForward(event) || config.isKeyBackward(event)) {\n checkKeyNav(event, config.isKeyBackward(event));\n }\n };\n var checkClick = function checkClick(e) {\n var target = getActualTarget(e);\n if (findContainerIndex(target, e) >= 0) {\n return;\n }\n if (valueOrHandler(config.clickOutsideDeactivates, e)) {\n return;\n }\n if (valueOrHandler(config.allowOutsideClick, e)) {\n return;\n }\n e.preventDefault();\n e.stopImmediatePropagation();\n };\n\n //\n // EVENT LISTENERS\n //\n\n var addListeners = function addListeners() {\n if (!state.active) {\n return;\n }\n\n // There can be only one listening focus trap at a time\n activeFocusTraps.activateTrap(trapStack, trap);\n\n // Delay ensures that the focused element doesn't capture the event\n // that caused the focus trap activation.\n state.delayInitialFocusTimer = config.delayInitialFocus ? delay(function () {\n tryFocus(getInitialFocusNode());\n }) : tryFocus(getInitialFocusNode());\n doc.addEventListener('focusin', checkFocusIn, true);\n doc.addEventListener('mousedown', checkPointerDown, {\n capture: true,\n passive: false\n });\n doc.addEventListener('touchstart', checkPointerDown, {\n capture: true,\n passive: false\n });\n doc.addEventListener('click', checkClick, {\n capture: true,\n passive: false\n });\n doc.addEventListener('keydown', checkKey, {\n capture: true,\n passive: false\n });\n return trap;\n };\n var removeListeners = function removeListeners() {\n if (!state.active) {\n return;\n }\n doc.removeEventListener('focusin', checkFocusIn, true);\n doc.removeEventListener('mousedown', checkPointerDown, true);\n doc.removeEventListener('touchstart', checkPointerDown, true);\n doc.removeEventListener('click', checkClick, true);\n doc.removeEventListener('keydown', checkKey, true);\n return trap;\n };\n\n //\n // MUTATION OBSERVER\n //\n\n var checkDomRemoval = function checkDomRemoval(mutations) {\n var isFocusedNodeRemoved = mutations.some(function (mutation) {\n var removedNodes = Array.from(mutation.removedNodes);\n return removedNodes.some(function (node) {\n return node === state.mostRecentlyFocusedNode;\n });\n });\n\n // If the currently focused is removed then browsers will move focus to the\n // <body> element. If this happens, try to move focus back into the trap.\n if (isFocusedNodeRemoved) {\n tryFocus(getInitialFocusNode());\n }\n };\n\n // Use MutationObserver - if supported - to detect if focused node is removed\n // from the DOM.\n var mutationObserver = typeof window !== 'undefined' && 'MutationObserver' in window ? new MutationObserver(checkDomRemoval) : undefined;\n var updateObservedNodes = function updateObservedNodes() {\n if (!mutationObserver) {\n return;\n }\n mutationObserver.disconnect();\n if (state.active && !state.paused) {\n state.containers.map(function (container) {\n mutationObserver.observe(container, {\n subtree: true,\n childList: true\n });\n });\n }\n };\n\n //\n // TRAP DEFINITION\n //\n\n trap = {\n get active() {\n return state.active;\n },\n get paused() {\n return state.paused;\n },\n activate: function activate(activateOptions) {\n if (state.active) {\n return this;\n }\n var onActivate = getOption(activateOptions, 'onActivate');\n var onPostActivate = getOption(activateOptions, 'onPostActivate');\n var checkCanFocusTrap = getOption(activateOptions, 'checkCanFocusTrap');\n if (!checkCanFocusTrap) {\n updateTabbableNodes();\n }\n state.active = true;\n state.paused = false;\n state.nodeFocusedBeforeActivation = doc.activeElement;\n onActivate === null || onActivate === void 0 || onActivate();\n var finishActivation = function finishActivation() {\n if (checkCanFocusTrap) {\n updateTabbableNodes();\n }\n addListeners();\n updateObservedNodes();\n onPostActivate === null || onPostActivate === void 0 || onPostActivate();\n };\n if (checkCanFocusTrap) {\n checkCanFocusTrap(state.containers.concat()).then(finishActivation, finishActivation);\n return this;\n }\n finishActivation();\n return this;\n },\n deactivate: function deactivate(deactivateOptions) {\n if (!state.active) {\n return this;\n }\n var options = _objectSpread2({\n onDeactivate: config.onDeactivate,\n onPostDeactivate: config.onPostDeactivate,\n checkCanReturnFocus: config.checkCanReturnFocus\n }, deactivateOptions);\n clearTimeout(state.delayInitialFocusTimer); // noop if undefined\n state.delayInitialFocusTimer = undefined;\n removeListeners();\n state.active = false;\n state.paused = false;\n updateObservedNodes();\n activeFocusTraps.deactivateTrap(trapStack, trap);\n var onDeactivate = getOption(options, 'onDeactivate');\n var onPostDeactivate = getOption(options, 'onPostDeactivate');\n var checkCanReturnFocus = getOption(options, 'checkCanReturnFocus');\n var returnFocus = getOption(options, 'returnFocus', 'returnFocusOnDeactivate');\n onDeactivate === null || onDeactivate === void 0 || onDeactivate();\n var finishDeactivation = function finishDeactivation() {\n delay(function () {\n if (returnFocus) {\n tryFocus(getReturnFocusNode(state.nodeFocusedBeforeActivation));\n }\n onPostDeactivate === null || onPostDeactivate === void 0 || onPostDeactivate();\n });\n };\n if (returnFocus && checkCanReturnFocus) {\n checkCanReturnFocus(getReturnFocusNode(state.nodeFocusedBeforeActivation)).then(finishDeactivation, finishDeactivation);\n return this;\n }\n finishDeactivation();\n return this;\n },\n pause: function pause(pauseOptions) {\n if (state.paused || !state.active) {\n return this;\n }\n var onPause = getOption(pauseOptions, 'onPause');\n var onPostPause = getOption(pauseOptions, 'onPostPause');\n state.paused = true;\n onPause === null || onPause === void 0 || onPause();\n removeListeners();\n updateObservedNodes();\n onPostPause === null || onPostPause === void 0 || onPostPause();\n return this;\n },\n unpause: function unpause(unpauseOptions) {\n if (!state.paused || !state.active) {\n return this;\n }\n var onUnpause = getOption(unpauseOptions, 'onUnpause');\n var onPostUnpause = getOption(unpauseOptions, 'onPostUnpause');\n state.paused = false;\n onUnpause === null || onUnpause === void 0 || onUnpause();\n updateTabbableNodes();\n addListeners();\n updateObservedNodes();\n onPostUnpause === null || onPostUnpause === void 0 || onPostUnpause();\n return this;\n },\n updateContainerElements: function updateContainerElements(containerElements) {\n var elementsAsArray = [].concat(containerElements).filter(Boolean);\n state.containers = elementsAsArray.map(function (element) {\n return typeof element === 'string' ? doc.querySelector(element) : element;\n });\n if (state.active) {\n updateTabbableNodes();\n }\n updateObservedNodes();\n return this;\n }\n };\n\n // initialize container elements\n trap.updateContainerElements(elements);\n return trap;\n};\n\nexport { createFocusTrap };\n//# sourceMappingURL=focus-trap.esm.js.map\n"],"names":["ownKeys","e","r","t","o","_objectSpread2","_defineProperty","obj","key","value","_toPropertyKey","_toPrimitive","input","hint","prim","res","arg","activeFocusTraps","trapStack","trap","activeTrap","trapIndex","isSelectableInput","node","isEscapeEvent","isTabEvent","isKeyForward","isKeyBackward","delay","fn","findIndex","arr","idx","i","valueOrHandler","_len","params","_key","getActualTarget","event","internalTrapStack","createFocusTrap","elements","userOptions","doc","config","state","getOption","configOverrideOptions","optionName","configOptionName","findContainerIndex","element","composedPath","_ref","container","tabbableNodes","getNodeForOption","optionValue","_len2","_key2","getInitialFocusNode","isFocusable","firstTabbableGroup","firstTabbableNode","updateTabbableNodes","tabbable","focusableNodes","focusable","lastTabbableNode","firstDomTabbableNode","isTabbable","lastDomTabbableNode","posTabIndexesFound","getTabIndex","forward","nodeIdx","el","group","g","getActiveElement","activeElement","tryFocus","getReturnFocusNode","previousActiveElement","findNextNavNode","_ref2","target","_ref2$isBackward","isBackward","destinationNode","containerIndex","containerGroup","startOfGroupIndex","_ref3","destinationGroupIndex","destinationGroup","lastOfGroupIndex","_ref4","_destinationGroupIndex","_destinationGroup","checkPointerDown","checkFocusIn","targetContained","nextNode","navAcrossContainers","mruContainerIdx","mruTabIdx","n","checkKeyNav","checkKey","checkClick","addListeners","removeListeners","checkDomRemoval","mutations","isFocusedNodeRemoved","mutation","removedNodes","mutationObserver","updateObservedNodes","activateOptions","onActivate","onPostActivate","checkCanFocusTrap","finishActivation","deactivateOptions","options","onDeactivate","onPostDeactivate","checkCanReturnFocus","returnFocus","finishDeactivation","pauseOptions","onPause","onPostPause","unpauseOptions","onUnpause","onPostUnpause","containerElements","elementsAsArray"],"mappings":";AAAA;AAAA;AAAA;AAAA;AAMA,SAASA,EAAQC,GAAGC,GAAG;AACrB,MAAIC,IAAI,OAAO,KAAKF,CAAC;AACrB,MAAI,OAAO,uBAAuB;AAChC,QAAIG,IAAI,OAAO,sBAAsBH,CAAC;AACtC,IAAAC,MAAME,IAAIA,EAAE,OAAO,SAAUF,GAAG;AAC9B,aAAO,OAAO,yBAAyBD,GAAGC,CAAC,EAAE;AAAA,IACnD,CAAK,IAAIC,EAAE,KAAK,MAAMA,GAAGC,CAAC;AAAA,EACvB;AACD,SAAOD;AACT;AACA,SAASE,EAAeJ,GAAG;AACzB,WAASC,IAAI,GAAGA,IAAI,UAAU,QAAQA,KAAK;AACzC,QAAIC,IAAY,UAAUD,CAAC,KAAnB,OAAuB,UAAUA,CAAC,IAAI;AAC9C,IAAAA,IAAI,IAAIF,EAAQ,OAAOG,CAAC,GAAG,EAAE,EAAE,QAAQ,SAAUD,GAAG;AAClD,MAAAI,GAAgBL,GAAGC,GAAGC,EAAED,CAAC,CAAC;AAAA,IAChC,CAAK,IAAI,OAAO,4BAA4B,OAAO,iBAAiBD,GAAG,OAAO,0BAA0BE,CAAC,CAAC,IAAIH,EAAQ,OAAOG,CAAC,CAAC,EAAE,QAAQ,SAAUD,GAAG;AAChJ,aAAO,eAAeD,GAAG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