@esri/calcite-components 1.4.0-next.4 → 1.4.0-next.6

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.
Files changed (704) hide show
  1. package/dist/calcite/calcite.esm.js +2 -2
  2. package/dist/calcite/index.esm.js +2 -2
  3. package/dist/calcite/{p-1b48dcda.entry.js → p-00e1b3a8.entry.js} +2 -2
  4. package/dist/calcite/{p-4a86d1ab.js → p-02706e35.js} +1 -1
  5. package/dist/calcite/p-058ac7cb.entry.js +6 -0
  6. package/dist/calcite/{p-be5734f7.js → p-08fb12d7.js} +2 -2
  7. package/dist/calcite/{p-5081856a.entry.js → p-09339f89.entry.js} +2 -2
  8. package/dist/calcite/{p-549d3d07.entry.js → p-0f9e9bef.entry.js} +2 -2
  9. package/dist/calcite/{p-198ab071.entry.js → p-15d26e08.entry.js} +2 -2
  10. package/dist/calcite/{p-c6c82380.entry.js → p-1678bfd5.entry.js} +2 -2
  11. package/dist/calcite/{p-14f78c1b.entry.js → p-18e2b588.entry.js} +2 -2
  12. package/dist/calcite/{p-14eccdb3.entry.js → p-198abcbb.entry.js} +2 -2
  13. package/dist/calcite/p-1bcc4ef2.js +6 -0
  14. package/dist/calcite/{p-4be0d67c.entry.js → p-20c6068d.entry.js} +2 -2
  15. package/dist/calcite/{p-2468ff71.js → p-238464b3.js} +1 -1
  16. package/dist/calcite/{p-10335369.js → p-24833d0f.js} +2 -2
  17. package/dist/calcite/{p-a8ae64d6.js → p-28ee6675.js} +1 -1
  18. package/dist/calcite/{p-f8af9a6c.js → p-2d155925.js} +1 -1
  19. package/dist/calcite/{p-f8ff6c94.entry.js → p-2f987df1.entry.js} +2 -2
  20. package/dist/calcite/{p-a0d99484.entry.js → p-309c88b2.entry.js} +2 -2
  21. package/dist/calcite/{p-460df0b5.js → p-36a4f2c8.js} +1 -1
  22. package/dist/calcite/{p-607951d2.entry.js → p-3c58757e.entry.js} +2 -2
  23. package/dist/calcite/{p-3465fcef.js → p-3d782f5e.js} +1 -1
  24. package/dist/calcite/{p-9170dc8c.entry.js → p-3e4ed9a3.entry.js} +2 -2
  25. package/dist/calcite/{p-29675f69.entry.js → p-3f09b972.entry.js} +2 -2
  26. package/dist/calcite/{p-b88213e9.entry.js → p-3fb7e1e9.entry.js} +2 -2
  27. package/dist/calcite/{p-4094c395.js → p-49e5e96a.js} +1 -1
  28. package/dist/calcite/{p-e4676089.entry.js → p-4ad0e5e7.entry.js} +2 -2
  29. package/dist/calcite/{p-167a7bdc.js → p-50e95bdb.js} +1 -1
  30. package/dist/calcite/{p-e7e84acd.entry.js → p-51f4cb23.entry.js} +2 -2
  31. package/dist/calcite/{p-09b5e911.entry.js → p-520cf1b0.entry.js} +2 -2
  32. package/dist/calcite/{p-690e8224.entry.js → p-56d69bd6.entry.js} +2 -2
  33. package/dist/calcite/{p-4612e3c4.entry.js → p-5b82075d.entry.js} +2 -2
  34. package/dist/calcite/{p-5099d131.entry.js → p-6582a43e.entry.js} +2 -2
  35. package/dist/calcite/{p-99546fc2.entry.js → p-6989f500.entry.js} +2 -2
  36. package/dist/calcite/{p-ac512a57.entry.js → p-6aadaed2.entry.js} +2 -2
  37. package/dist/calcite/{p-eabc3a81.entry.js → p-6c011dac.entry.js} +2 -2
  38. package/dist/calcite/{p-110f836d.js → p-6e1f7f1f.js} +1 -1
  39. package/dist/calcite/{p-762e069e.entry.js → p-70edce50.entry.js} +2 -2
  40. package/dist/calcite/{p-00346107.entry.js → p-71294102.entry.js} +2 -2
  41. package/dist/calcite/{p-c592404b.entry.js → p-721669b1.entry.js} +2 -2
  42. package/dist/calcite/{p-cc5d73b1.entry.js → p-7773ec0c.entry.js} +2 -2
  43. package/dist/calcite/{p-7aac398a.js → p-78ecccfd.js} +2 -2
  44. package/dist/calcite/{p-7c069e47.entry.js → p-794cd7e0.entry.js} +2 -2
  45. package/dist/calcite/{p-1e353e72.js → p-7e85033a.js} +1 -1
  46. package/dist/calcite/{p-37601822.entry.js → p-829a8016.entry.js} +2 -2
  47. package/dist/calcite/{p-bfa1073e.entry.js → p-8576f7a9.entry.js} +2 -2
  48. package/dist/calcite/{p-4dd1d026.entry.js → p-85ce36b4.entry.js} +2 -2
  49. package/dist/calcite/{p-fbb43fd3.entry.js → p-89b037e5.entry.js} +2 -2
  50. package/dist/calcite/{p-7c93f55c.entry.js → p-8bc8392a.entry.js} +2 -2
  51. package/dist/calcite/{p-d83e122d.js → p-8d592b3c.js} +1 -1
  52. package/dist/calcite/{p-bf3b07a8.entry.js → p-8d911c0f.entry.js} +2 -2
  53. package/dist/calcite/{p-518e42e2.js → p-8e4e219a.js} +1 -1
  54. package/dist/calcite/{p-798257c9.js → p-8eb6d3d6.js} +2 -2
  55. package/dist/calcite/{p-9d6d46fb.js → p-8eed6488.js} +1 -1
  56. package/dist/calcite/{p-1f65fd97.entry.js → p-902ccf8c.entry.js} +2 -2
  57. package/dist/calcite/{p-41b1924f.entry.js → p-90faa188.entry.js} +2 -2
  58. package/dist/calcite/{p-5b0e38f4.entry.js → p-94ae14ed.entry.js} +2 -2
  59. package/dist/calcite/{p-2477ffab.js → p-977a7373.js} +2 -2
  60. package/dist/calcite/{p-fc5a05c8.js → p-9c5561f6.js} +2 -2
  61. package/dist/calcite/{p-71ee6c09.js → p-9ecad02c.js} +2 -2
  62. package/dist/calcite/p-a2dcc545.js +6 -0
  63. package/dist/calcite/{p-6c28a6a6.entry.js → p-ac50f328.entry.js} +2 -2
  64. package/dist/calcite/{p-af19d2eb.entry.js → p-acbe9c99.entry.js} +2 -2
  65. package/dist/calcite/p-ad29a95f.js +6 -0
  66. package/dist/calcite/{p-3476e72e.js → p-ae330013.js} +2 -2
  67. package/dist/calcite/{p-88e0c279.js → p-b0388e91.js} +2 -2
  68. package/dist/calcite/{p-07e56bf4.js → p-b086f92d.js} +1 -1
  69. package/dist/calcite/p-b3099221.js +6 -0
  70. package/dist/calcite/{p-c33810ce.js → p-b3f59734.js} +1 -1
  71. package/dist/calcite/{p-12b426c9.entry.js → p-b7f76e88.entry.js} +2 -2
  72. package/dist/calcite/p-bb1f280b.entry.js +6 -0
  73. package/dist/calcite/{p-cafbf219.entry.js → p-bde56e46.entry.js} +2 -2
  74. package/dist/calcite/{p-48071f1a.entry.js → p-bde9a8bf.entry.js} +2 -2
  75. package/dist/calcite/{p-e88938fe.entry.js → p-becceac4.entry.js} +2 -2
  76. package/dist/calcite/p-c3bd1ae0.entry.js +6 -0
  77. package/dist/calcite/{p-8ac1324f.entry.js → p-c477bf75.entry.js} +2 -2
  78. package/dist/calcite/{p-db1f6411.js → p-c4e985ef.js} +2 -2
  79. package/dist/calcite/{p-605ff48d.entry.js → p-c9159a0a.entry.js} +2 -2
  80. package/dist/calcite/{p-4569f702.entry.js → p-ca95c6ed.entry.js} +2 -2
  81. package/dist/calcite/{p-dc554515.entry.js → p-cabf475d.entry.js} +2 -2
  82. package/dist/calcite/p-cc008746.js +6 -0
  83. package/dist/calcite/{p-b6d1694c.entry.js → p-cd8ecd59.entry.js} +2 -2
  84. package/dist/calcite/{p-b1c81dcc.js → p-cf5e973f.js} +2 -2
  85. package/dist/calcite/{p-90b23414.entry.js → p-d4f5d56a.entry.js} +2 -2
  86. package/dist/calcite/{p-0e0a4c8e.entry.js → p-dda5a868.entry.js} +2 -2
  87. package/dist/calcite/p-de460c7f.js +6 -0
  88. package/dist/calcite/p-e907c9d7.entry.js +6 -0
  89. package/dist/calcite/{p-23c694da.entry.js → p-e9dedbc2.entry.js} +2 -2
  90. package/dist/calcite/{p-74a4ac3e.js → p-ece4c169.js} +1 -1
  91. package/dist/calcite/{p-df5d4340.entry.js → p-ef9439cd.entry.js} +2 -2
  92. package/dist/calcite/p-f0eab93a.entry.js +6 -0
  93. package/dist/calcite/{p-01e73d3c.entry.js → p-f1dc743d.entry.js} +2 -2
  94. package/dist/calcite/{p-feb44263.entry.js → p-f2bf5444.entry.js} +2 -2
  95. package/dist/calcite/{p-ab5ba8d8.entry.js → p-f44b8d1c.entry.js} +2 -2
  96. package/dist/calcite/{p-083022ce.entry.js → p-fd37640e.entry.js} +2 -2
  97. package/dist/calcite/{p-18fe3593.entry.js → p-fd38d722.entry.js} +2 -2
  98. package/dist/calcite/p-ff1e2786.js +6 -0
  99. package/dist/cjs/{ExpandToggle-9c9692c9.js → ExpandToggle-34efb36e.js} +5 -5
  100. package/dist/cjs/{FloatingArrow-8cad3e02.js → FloatingArrow-ca4a438c.js} +2 -2
  101. package/dist/cjs/{Heading-a54c437a.js → Heading-16403a18.js} +2 -2
  102. package/dist/cjs/{app-globals-6921d6ca.js → app-globals-08fa4928.js} +2 -2
  103. package/dist/cjs/{array-11eaef78.js → array-a48e72f4.js} +1 -1
  104. package/dist/cjs/calcite-accordion_2.cjs.entry.js +7 -7
  105. package/dist/cjs/calcite-action-bar.cjs.entry.js +15 -15
  106. package/dist/cjs/calcite-action-group.cjs.entry.js +13 -13
  107. package/dist/cjs/calcite-action-menu.cjs.entry.js +9 -9
  108. package/dist/cjs/calcite-action-pad.cjs.entry.js +14 -14
  109. package/dist/cjs/calcite-action.cjs.entry.js +11 -11
  110. package/dist/cjs/calcite-alert.cjs.entry.js +12 -12
  111. package/dist/cjs/calcite-avatar.cjs.entry.js +6 -6
  112. package/dist/cjs/calcite-block_2.cjs.entry.js +12 -12
  113. package/dist/cjs/calcite-button.cjs.entry.js +13 -13
  114. package/dist/cjs/calcite-card.cjs.entry.js +10 -10
  115. package/dist/cjs/calcite-checkbox.cjs.entry.js +10 -10
  116. package/dist/cjs/calcite-chip-group.cjs.entry.js +8 -8
  117. package/dist/cjs/calcite-chip.cjs.entry.js +12 -12
  118. package/dist/cjs/calcite-color-picker_3.cjs.entry.js +585 -339
  119. package/dist/cjs/calcite-combobox_3.cjs.entry.js +18 -18
  120. package/dist/cjs/calcite-date-picker_4.cjs.entry.js +13 -13
  121. package/dist/cjs/calcite-dropdown_3.cjs.entry.js +12 -12
  122. package/dist/cjs/calcite-fab.cjs.entry.js +7 -7
  123. package/dist/cjs/calcite-filter.cjs.entry.js +13 -13
  124. package/dist/cjs/calcite-flow-item.cjs.entry.js +12 -12
  125. package/dist/cjs/calcite-flow.cjs.entry.js +3 -3
  126. package/dist/cjs/calcite-graph_2.cjs.entry.js +13 -13
  127. package/dist/cjs/calcite-handle.cjs.entry.js +10 -10
  128. package/dist/cjs/calcite-icon.cjs.entry.js +6 -6
  129. package/dist/cjs/calcite-inline-editable.cjs.entry.js +12 -12
  130. package/dist/cjs/calcite-input-date-picker.cjs.entry.js +18 -18
  131. package/dist/cjs/calcite-input-message.cjs.entry.js +5 -5
  132. package/dist/cjs/calcite-input-number.cjs.entry.js +13 -13
  133. package/dist/cjs/calcite-input-text.cjs.entry.js +13 -13
  134. package/dist/cjs/calcite-input-time-picker_2.cjs.entry.js +14 -14
  135. package/dist/cjs/calcite-input.cjs.entry.js +13 -13
  136. package/dist/cjs/calcite-label.cjs.entry.js +6 -6
  137. package/dist/cjs/calcite-link.cjs.entry.js +7 -7
  138. package/dist/cjs/calcite-list_3.cjs.entry.js +50 -40
  139. package/dist/cjs/calcite-loader.cjs.entry.js +3 -3
  140. package/dist/cjs/calcite-modal.cjs.entry.js +13 -13
  141. package/dist/cjs/calcite-notice.cjs.entry.js +12 -12
  142. package/dist/cjs/calcite-option_3.cjs.entry.js +10 -10
  143. package/dist/cjs/calcite-pagination.cjs.entry.js +10 -10
  144. package/dist/cjs/calcite-panel.cjs.entry.js +14 -14
  145. package/dist/cjs/calcite-pick-list_3.cjs.entry.js +16 -16
  146. package/dist/cjs/calcite-popover.cjs.entry.js +16 -16
  147. package/dist/cjs/calcite-progress.cjs.entry.js +2 -2
  148. package/dist/cjs/calcite-radio-button-group.cjs.entry.js +3 -3
  149. package/dist/cjs/calcite-radio-button.cjs.entry.js +10 -10
  150. package/dist/cjs/calcite-rating.cjs.entry.js +13 -13
  151. package/dist/cjs/calcite-scrim.cjs.entry.js +9 -9
  152. package/dist/cjs/calcite-segmented-control_2.cjs.entry.js +9 -9
  153. package/dist/cjs/calcite-shell_3.cjs.entry.js +11 -11
  154. package/dist/cjs/calcite-sortable-list.cjs.entry.js +5 -5
  155. package/dist/cjs/calcite-split-button.cjs.entry.js +4 -4
  156. package/dist/cjs/calcite-stepper_2.cjs.entry.js +10 -10
  157. package/dist/cjs/calcite-switch.cjs.entry.js +10 -10
  158. package/dist/cjs/calcite-tab_4.cjs.entry.js +7 -7
  159. package/dist/cjs/calcite-text-area.cjs.entry.js +15 -15
  160. package/dist/cjs/calcite-tile-select_2.cjs.entry.js +5 -5
  161. package/dist/cjs/calcite-tile.cjs.entry.js +8 -8
  162. package/dist/cjs/calcite-tip_3.cjs.entry.js +11 -11
  163. package/dist/cjs/calcite-tooltip.cjs.entry.js +9 -9
  164. package/dist/cjs/calcite-tree_2.cjs.entry.js +9 -9
  165. package/dist/cjs/calcite-value-list_2.cjs.entry.js +16 -16
  166. package/dist/cjs/calcite.cjs.js +5 -5
  167. package/dist/cjs/{composed-offset-position.esm-5a2f9ff8.js → composed-offset-position.esm-00262258.js} +1 -1
  168. package/dist/cjs/{conditionalSlot-39f2741e.js → conditionalSlot-44ce332c.js} +3 -3
  169. package/dist/cjs/{debounce-f09b6263.js → debounce-a2674dc4.js} +1 -1
  170. package/dist/cjs/{dom-1b2f41d1.js → dom-c4a69490.js} +3 -3
  171. package/dist/cjs/{filter-c268fa9a.js → filter-a7677076.js} +2 -2
  172. package/dist/cjs/{floating-ui-86f1cd7e.js → floating-ui-b9ad845e.js} +71 -65
  173. package/dist/cjs/{focusTrapComponent-84a6204d.js → focusTrapComponent-ad111b58.js} +2 -2
  174. package/dist/cjs/{form-c4ef3b01.js → form-4441b5de.js} +3 -3
  175. package/dist/cjs/{guid-053b3b9f.js → guid-3ea77659.js} +1 -1
  176. package/dist/cjs/{index-3f1e65e1.js → index-5631fa22.js} +1 -1
  177. package/dist/cjs/index.cjs.js +2 -2
  178. package/dist/cjs/{interactive-002e7de1.js → interactive-0d0f7af7.js} +1 -1
  179. package/dist/cjs/{key-26c7350c.js → key-5a12f647.js} +1 -1
  180. package/dist/cjs/{label-c5a73703.js → label-81db116a.js} +2 -2
  181. package/dist/cjs/{loadable-21f49ddd.js → loadable-9733bc78.js} +1 -1
  182. package/dist/cjs/loader.cjs.js +5 -5
  183. package/dist/cjs/{locale-bec864db.js → locale-cd52f850.js} +4 -4
  184. package/dist/cjs/{math-b23a2620.js → math-d7fcd025.js} +1 -1
  185. package/dist/cjs/{observers-7b381996.js → observers-6aa64455.js} +1 -1
  186. package/dist/cjs/{openCloseComponent-d285707d.js → openCloseComponent-f2d47f5b.js} +2 -2
  187. package/dist/cjs/{resources-4b35c7c3.js → resources-4a16f695.js} +1 -1
  188. package/dist/cjs/{resources-ccc69560.js → resources-7805e29e.js} +5 -5
  189. package/dist/cjs/{resources-d72b2060.js → resources-9c69ee5f.js} +1 -1
  190. package/dist/cjs/{resources-6603995b.js → resources-a3154079.js} +1 -1
  191. package/dist/cjs/{resources-42c16d2f.js → resources-cb69cc10.js} +1 -1
  192. package/dist/cjs/{resources-adbdd1d0.js → resources-fb8b0a5e.js} +1 -1
  193. package/dist/cjs/{sortable.esm-e90f34c4.js → sortable.esm-b954a413.js} +1 -1
  194. package/dist/cjs/{t9n-d1d3fae9.js → t9n-e49fe20d.js} +3 -3
  195. package/dist/cjs/{throttle-d2814ea6.js → throttle-3df9debd.js} +2 -2
  196. package/dist/cjs/utils-136fb325.js +213 -0
  197. package/dist/cjs/{utils-da168911.js → utils-411455bc.js} +3 -3
  198. package/dist/collection/components/accordion/accordion.js +1 -1
  199. package/dist/collection/components/accordion-item/accordion-item.js +1 -1
  200. package/dist/collection/components/accordion-item/resources.js +1 -1
  201. package/dist/collection/components/action/action.js +1 -1
  202. package/dist/collection/components/action/resources.js +1 -1
  203. package/dist/collection/components/action-bar/action-bar.js +1 -1
  204. package/dist/collection/components/action-bar/resources.js +1 -1
  205. package/dist/collection/components/action-bar/utils.js +1 -1
  206. package/dist/collection/components/action-group/action-group.js +1 -1
  207. package/dist/collection/components/action-group/resources.js +1 -1
  208. package/dist/collection/components/action-menu/action-menu.js +1 -1
  209. package/dist/collection/components/action-menu/resources.js +1 -1
  210. package/dist/collection/components/action-pad/action-pad.js +1 -1
  211. package/dist/collection/components/action-pad/resources.js +1 -1
  212. package/dist/collection/components/alert/alert.js +1 -1
  213. package/dist/collection/components/alert/resources.js +1 -1
  214. package/dist/collection/components/avatar/avatar.js +1 -1
  215. package/dist/collection/components/avatar/utils.js +1 -1
  216. package/dist/collection/components/block/block.js +1 -1
  217. package/dist/collection/components/block/resources.js +1 -1
  218. package/dist/collection/components/block-section/block-section.js +1 -1
  219. package/dist/collection/components/block-section/resources.js +1 -1
  220. package/dist/collection/components/button/button.js +1 -1
  221. package/dist/collection/components/button/resources.js +1 -1
  222. package/dist/collection/components/card/card.js +1 -1
  223. package/dist/collection/components/card/resources.js +1 -1
  224. package/dist/collection/components/checkbox/checkbox.js +1 -1
  225. package/dist/collection/components/chip/chip.js +1 -1
  226. package/dist/collection/components/chip/resources.js +1 -1
  227. package/dist/collection/components/chip-group/chip-group.js +1 -1
  228. package/dist/collection/components/color-picker/color-picker.css +59 -52
  229. package/dist/collection/components/color-picker/color-picker.js +448 -233
  230. package/dist/collection/components/color-picker/resources.js +37 -27
  231. package/dist/collection/components/color-picker/utils.js +116 -30
  232. package/dist/collection/components/color-picker-hex-input/color-picker-hex-input.css +19 -16
  233. package/dist/collection/components/color-picker-hex-input/color-picker-hex-input.js +225 -118
  234. package/dist/collection/components/color-picker-hex-input/resources.js +3 -3
  235. package/dist/collection/components/color-picker-swatch/color-picker-swatch.css +10 -6
  236. package/dist/collection/components/color-picker-swatch/color-picker-swatch.js +34 -7
  237. package/dist/collection/components/color-picker-swatch/resources.js +8 -2
  238. package/dist/collection/components/combobox/combobox.js +1 -1
  239. package/dist/collection/components/combobox/resources.js +1 -1
  240. package/dist/collection/components/combobox/utils.js +1 -1
  241. package/dist/collection/components/combobox-item/combobox-item.js +1 -1
  242. package/dist/collection/components/combobox-item/resources.js +1 -1
  243. package/dist/collection/components/combobox-item-group/combobox-item-group.js +1 -1
  244. package/dist/collection/components/combobox-item-group/resources.js +1 -1
  245. package/dist/collection/components/date-picker/date-picker.js +1 -1
  246. package/dist/collection/components/date-picker/resources.js +1 -1
  247. package/dist/collection/components/date-picker/utils.js +1 -1
  248. package/dist/collection/components/date-picker-day/date-picker-day.js +1 -1
  249. package/dist/collection/components/date-picker-month/date-picker-month.js +1 -1
  250. package/dist/collection/components/date-picker-month-header/date-picker-month-header.js +1 -1
  251. package/dist/collection/components/date-picker-month-header/resources.js +1 -1
  252. package/dist/collection/components/dropdown/dropdown.js +1 -1
  253. package/dist/collection/components/dropdown/resources.js +1 -1
  254. package/dist/collection/components/dropdown-group/dropdown-group.js +1 -1
  255. package/dist/collection/components/dropdown-group/resources.js +1 -1
  256. package/dist/collection/components/dropdown-item/dropdown-item.js +1 -1
  257. package/dist/collection/components/dropdown-item/resources.js +1 -1
  258. package/dist/collection/components/fab/fab.js +1 -1
  259. package/dist/collection/components/fab/resources.js +1 -1
  260. package/dist/collection/components/filter/filter.js +1 -1
  261. package/dist/collection/components/filter/resources.js +1 -1
  262. package/dist/collection/components/flow/flow.js +1 -1
  263. package/dist/collection/components/flow/resources.js +1 -1
  264. package/dist/collection/components/flow-item/flow-item.js +1 -1
  265. package/dist/collection/components/flow-item/resources.js +1 -1
  266. package/dist/collection/components/functional/ExpandToggle.js +1 -1
  267. package/dist/collection/components/functional/FloatingArrow.js +1 -1
  268. package/dist/collection/components/functional/Heading.js +1 -1
  269. package/dist/collection/components/graph/graph.js +1 -1
  270. package/dist/collection/components/graph/util.js +1 -1
  271. package/dist/collection/components/handle/handle.js +1 -1
  272. package/dist/collection/components/handle/resources.js +1 -1
  273. package/dist/collection/components/icon/icon.js +1 -1
  274. package/dist/collection/components/icon/resources.js +1 -1
  275. package/dist/collection/components/icon/utils.js +1 -1
  276. package/dist/collection/components/inline-editable/inline-editable.js +1 -1
  277. package/dist/collection/components/inline-editable/resources.js +1 -1
  278. package/dist/collection/components/input/input.js +1 -1
  279. package/dist/collection/components/input/resources.js +1 -1
  280. package/dist/collection/components/input-date-picker/input-date-picker.js +1 -1
  281. package/dist/collection/components/input-date-picker/resources.js +1 -1
  282. package/dist/collection/components/input-message/input-message.js +1 -1
  283. package/dist/collection/components/input-message/interfaces.js +1 -1
  284. package/dist/collection/components/input-number/input-number.js +1 -1
  285. package/dist/collection/components/input-number/resources.js +1 -1
  286. package/dist/collection/components/input-text/input-text.js +1 -1
  287. package/dist/collection/components/input-text/resources.js +1 -1
  288. package/dist/collection/components/input-time-picker/input-time-picker.js +1 -1
  289. package/dist/collection/components/input-time-picker/resources.js +1 -1
  290. package/dist/collection/components/label/label.js +1 -1
  291. package/dist/collection/components/label/resources.js +1 -1
  292. package/dist/collection/components/link/link.js +1 -1
  293. package/dist/collection/components/list/list.js +60 -30
  294. package/dist/collection/components/list/resources.js +2 -2
  295. package/dist/collection/components/list-item/list-item.js +1 -1
  296. package/dist/collection/components/list-item/resources.js +1 -1
  297. package/dist/collection/components/list-item/utils.js +1 -1
  298. package/dist/collection/components/list-item-group/list-item-group.js +1 -1
  299. package/dist/collection/components/list-item-group/resources.js +1 -1
  300. package/dist/collection/components/loader/loader.js +1 -1
  301. package/dist/collection/components/modal/modal.js +1 -1
  302. package/dist/collection/components/modal/resources.js +1 -1
  303. package/dist/collection/components/notice/notice.js +1 -1
  304. package/dist/collection/components/notice/resources.js +1 -1
  305. package/dist/collection/components/option/option.js +1 -1
  306. package/dist/collection/components/option-group/option-group.js +1 -1
  307. package/dist/collection/components/pagination/pagination.js +1 -1
  308. package/dist/collection/components/pagination/resources.js +1 -1
  309. package/dist/collection/components/panel/panel.js +1 -1
  310. package/dist/collection/components/panel/resources.js +1 -1
  311. package/dist/collection/components/pick-list/pick-list.js +1 -1
  312. package/dist/collection/components/pick-list/resources.js +1 -1
  313. package/dist/collection/components/pick-list/shared-list-logic.js +1 -1
  314. package/dist/collection/components/pick-list/shared-list-render.js +1 -1
  315. package/dist/collection/components/pick-list-group/pick-list-group.js +1 -1
  316. package/dist/collection/components/pick-list-group/resources.js +1 -1
  317. package/dist/collection/components/pick-list-item/pick-list-item.js +1 -1
  318. package/dist/collection/components/pick-list-item/resources.js +1 -1
  319. package/dist/collection/components/popover/PopoverManager.js +1 -1
  320. package/dist/collection/components/popover/popover.js +1 -1
  321. package/dist/collection/components/popover/resources.js +1 -1
  322. package/dist/collection/components/progress/progress.js +1 -1
  323. package/dist/collection/components/radio-button/radio-button.js +1 -1
  324. package/dist/collection/components/radio-button/resources.js +1 -1
  325. package/dist/collection/components/radio-button-group/radio-button-group.js +1 -1
  326. package/dist/collection/components/rating/function/star.js +1 -1
  327. package/dist/collection/components/rating/rating.js +1 -1
  328. package/dist/collection/components/resources.js +1 -1
  329. package/dist/collection/components/scrim/resources.js +1 -1
  330. package/dist/collection/components/scrim/scrim.js +1 -1
  331. package/dist/collection/components/segmented-control/segmented-control.js +1 -1
  332. package/dist/collection/components/segmented-control-item/resources.js +1 -1
  333. package/dist/collection/components/segmented-control-item/segmented-control-item.js +1 -1
  334. package/dist/collection/components/select/resources.js +1 -1
  335. package/dist/collection/components/select/select.js +1 -1
  336. package/dist/collection/components/shell/resources.js +1 -1
  337. package/dist/collection/components/shell/shell.js +1 -1
  338. package/dist/collection/components/shell-center-row/resources.js +1 -1
  339. package/dist/collection/components/shell-center-row/shell-center-row.js +1 -1
  340. package/dist/collection/components/shell-panel/resources.js +1 -1
  341. package/dist/collection/components/shell-panel/shell-panel.js +1 -1
  342. package/dist/collection/components/slider/resources.js +1 -1
  343. package/dist/collection/components/slider/slider.js +1 -1
  344. package/dist/collection/components/sortable-list/resources.js +1 -1
  345. package/dist/collection/components/sortable-list/sortable-list.js +1 -1
  346. package/dist/collection/components/split-button/resources.js +1 -1
  347. package/dist/collection/components/split-button/split-button.js +1 -1
  348. package/dist/collection/components/stepper/stepper.js +1 -1
  349. package/dist/collection/components/stepper-item/stepper-item.js +1 -1
  350. package/dist/collection/components/switch/switch.js +1 -1
  351. package/dist/collection/components/tab/tab.js +1 -1
  352. package/dist/collection/components/tab-nav/tab-nav.js +1 -1
  353. package/dist/collection/components/tab-title/resources.js +1 -1
  354. package/dist/collection/components/tab-title/tab-title.js +1 -1
  355. package/dist/collection/components/tabs/resources.js +1 -1
  356. package/dist/collection/components/tabs/tabs.js +1 -1
  357. package/dist/collection/components/text-area/resources.js +1 -1
  358. package/dist/collection/components/text-area/text-area.js +1 -1
  359. package/dist/collection/components/tile/resources.js +1 -1
  360. package/dist/collection/components/tile/tile.js +1 -1
  361. package/dist/collection/components/tile-select/resources.js +1 -1
  362. package/dist/collection/components/tile-select/tile-select.js +1 -1
  363. package/dist/collection/components/tile-select-group/tile-select-group.js +1 -1
  364. package/dist/collection/components/time-picker/resources.js +1 -1
  365. package/dist/collection/components/time-picker/time-picker.js +1 -1
  366. package/dist/collection/components/tip/resources.js +1 -1
  367. package/dist/collection/components/tip/tip.js +1 -1
  368. package/dist/collection/components/tip-group/tip-group.js +1 -1
  369. package/dist/collection/components/tip-manager/resources.js +1 -1
  370. package/dist/collection/components/tip-manager/tip-manager.js +1 -1
  371. package/dist/collection/components/tooltip/TooltipManager.js +1 -1
  372. package/dist/collection/components/tooltip/resources.js +1 -1
  373. package/dist/collection/components/tooltip/tooltip.js +1 -1
  374. package/dist/collection/components/tooltip/utils.js +1 -1
  375. package/dist/collection/components/tree/tree.js +1 -1
  376. package/dist/collection/components/tree/utils.js +1 -1
  377. package/dist/collection/components/tree-item/resources.js +1 -1
  378. package/dist/collection/components/tree-item/tree-item.js +1 -1
  379. package/dist/collection/components/value-list/resources.js +1 -1
  380. package/dist/collection/components/value-list/utils.js +1 -1
  381. package/dist/collection/components/value-list/value-list.js +1 -1
  382. package/dist/collection/components/value-list-item/resources.js +1 -1
  383. package/dist/collection/components/value-list-item/value-list-item.js +1 -1
  384. package/dist/collection/index.js +1 -1
  385. package/dist/collection/utils/array.js +1 -1
  386. package/dist/collection/utils/conditionalSlot.js +1 -1
  387. package/dist/collection/utils/config.js +1 -1
  388. package/dist/collection/utils/date.js +1 -1
  389. package/dist/collection/utils/dom.js +1 -1
  390. package/dist/collection/utils/filter.js +1 -1
  391. package/dist/collection/utils/floating-ui.js +1 -1
  392. package/dist/collection/utils/focusTrapComponent.js +1 -1
  393. package/dist/collection/utils/form.js +1 -1
  394. package/dist/collection/utils/globalAttributes.js +1 -1
  395. package/dist/collection/utils/globalScript.js +1 -1
  396. package/dist/collection/utils/guid.js +1 -1
  397. package/dist/collection/utils/interactive.js +1 -1
  398. package/dist/collection/utils/key.js +1 -1
  399. package/dist/collection/utils/label.js +1 -1
  400. package/dist/collection/utils/loadable.js +1 -1
  401. package/dist/collection/utils/locale.js +1 -1
  402. package/dist/collection/utils/math.js +1 -1
  403. package/dist/collection/utils/mode.js +1 -1
  404. package/dist/collection/utils/number.js +1 -1
  405. package/dist/collection/utils/observers.js +1 -1
  406. package/dist/collection/utils/openCloseComponent.js +1 -1
  407. package/dist/collection/utils/resources.js +1 -1
  408. package/dist/collection/utils/t9n.js +1 -1
  409. package/dist/collection/utils/time.js +1 -1
  410. package/dist/components/ExpandToggle.js +1 -1
  411. package/dist/components/FloatingArrow.js +1 -1
  412. package/dist/components/Heading.js +1 -1
  413. package/dist/components/action-group.js +1 -1
  414. package/dist/components/action-menu.js +1 -1
  415. package/dist/components/action.js +1 -1
  416. package/dist/components/array.js +1 -1
  417. package/dist/components/button.js +1 -1
  418. package/dist/components/calcite-accordion-item.js +1 -1
  419. package/dist/components/calcite-accordion.js +1 -1
  420. package/dist/components/calcite-action-bar.js +1 -1
  421. package/dist/components/calcite-action-group.js +1 -1
  422. package/dist/components/calcite-action-menu.js +1 -1
  423. package/dist/components/calcite-action-pad.js +1 -1
  424. package/dist/components/calcite-action.js +1 -1
  425. package/dist/components/calcite-alert.js +1 -1
  426. package/dist/components/calcite-avatar.js +1 -1
  427. package/dist/components/calcite-block-section.js +1 -1
  428. package/dist/components/calcite-block.js +1 -1
  429. package/dist/components/calcite-button.js +1 -1
  430. package/dist/components/calcite-card.js +1 -1
  431. package/dist/components/calcite-checkbox.js +1 -1
  432. package/dist/components/calcite-chip-group.js +1 -1
  433. package/dist/components/calcite-chip.js +1 -1
  434. package/dist/components/calcite-color-picker-hex-input.js +2 -2
  435. package/dist/components/calcite-color-picker-swatch.js +1 -1
  436. package/dist/components/calcite-color-picker.js +377 -314
  437. package/dist/components/calcite-combobox-item-group.js +1 -1
  438. package/dist/components/calcite-combobox-item.js +1 -1
  439. package/dist/components/calcite-combobox.js +1 -1
  440. package/dist/components/calcite-date-picker-day.js +1 -1
  441. package/dist/components/calcite-date-picker-month-header.js +1 -1
  442. package/dist/components/calcite-date-picker-month.js +1 -1
  443. package/dist/components/calcite-date-picker.js +1 -1
  444. package/dist/components/calcite-dropdown-group.js +1 -1
  445. package/dist/components/calcite-dropdown-item.js +1 -1
  446. package/dist/components/calcite-dropdown.js +1 -1
  447. package/dist/components/calcite-fab.js +1 -1
  448. package/dist/components/calcite-filter.js +1 -1
  449. package/dist/components/calcite-flow-item.js +1 -1
  450. package/dist/components/calcite-flow.js +1 -1
  451. package/dist/components/calcite-graph.js +1 -1
  452. package/dist/components/calcite-handle.js +1 -1
  453. package/dist/components/calcite-icon.js +1 -1
  454. package/dist/components/calcite-inline-editable.js +1 -1
  455. package/dist/components/calcite-input-date-picker.js +1 -1
  456. package/dist/components/calcite-input-message.js +1 -1
  457. package/dist/components/calcite-input-number.js +2 -617
  458. package/dist/components/calcite-input-text.js +1 -1
  459. package/dist/components/calcite-input-time-picker.js +1 -1
  460. package/dist/components/calcite-input.js +1 -1
  461. package/dist/components/calcite-label.js +1 -1
  462. package/dist/components/calcite-link.js +1 -1
  463. package/dist/components/calcite-list-item-group.js +1 -1
  464. package/dist/components/calcite-list-item.js +1 -1
  465. package/dist/components/calcite-list.js +40 -30
  466. package/dist/components/calcite-loader.js +1 -1
  467. package/dist/components/calcite-modal.js +1 -1
  468. package/dist/components/calcite-notice.js +1 -1
  469. package/dist/components/calcite-option-group.js +1 -1
  470. package/dist/components/calcite-option.js +1 -1
  471. package/dist/components/calcite-pagination.js +1 -1
  472. package/dist/components/calcite-panel.js +1 -1
  473. package/dist/components/calcite-pick-list-group.js +1 -1
  474. package/dist/components/calcite-pick-list-item.js +1 -1
  475. package/dist/components/calcite-pick-list.js +1 -1
  476. package/dist/components/calcite-popover.js +1 -1
  477. package/dist/components/calcite-progress.js +1 -1
  478. package/dist/components/calcite-radio-button-group.js +1 -1
  479. package/dist/components/calcite-radio-button.js +1 -1
  480. package/dist/components/calcite-rating.js +1 -1
  481. package/dist/components/calcite-scrim.js +1 -1
  482. package/dist/components/calcite-segmented-control-item.js +1 -1
  483. package/dist/components/calcite-segmented-control.js +1 -1
  484. package/dist/components/calcite-select.js +1 -1
  485. package/dist/components/calcite-shell-center-row.js +1 -1
  486. package/dist/components/calcite-shell-panel.js +1 -1
  487. package/dist/components/calcite-shell.js +1 -1
  488. package/dist/components/calcite-slider.js +1 -1
  489. package/dist/components/calcite-sortable-list.js +1 -1
  490. package/dist/components/calcite-split-button.js +1 -1
  491. package/dist/components/calcite-stepper-item.js +1 -1
  492. package/dist/components/calcite-stepper.js +1 -1
  493. package/dist/components/calcite-switch.js +1 -1
  494. package/dist/components/calcite-tab-nav.js +1 -1
  495. package/dist/components/calcite-tab-title.js +1 -1
  496. package/dist/components/calcite-tab.js +1 -1
  497. package/dist/components/calcite-tabs.js +1 -1
  498. package/dist/components/calcite-text-area.js +1 -1
  499. package/dist/components/calcite-tile-select-group.js +1 -1
  500. package/dist/components/calcite-tile-select.js +1 -1
  501. package/dist/components/calcite-tile.js +1 -1
  502. package/dist/components/calcite-time-picker.js +1 -1
  503. package/dist/components/calcite-tip-group.js +1 -1
  504. package/dist/components/calcite-tip-manager.js +1 -1
  505. package/dist/components/calcite-tip.js +1 -1
  506. package/dist/components/calcite-tooltip.js +1 -1
  507. package/dist/components/calcite-tree-item.js +1 -1
  508. package/dist/components/calcite-tree.js +1 -1
  509. package/dist/components/calcite-value-list-item.js +1 -1
  510. package/dist/components/calcite-value-list.js +1 -1
  511. package/dist/components/checkbox.js +1 -1
  512. package/dist/components/chip.js +1 -1
  513. package/dist/components/color-picker-hex-input.js +252 -88
  514. package/dist/components/color-picker-swatch.js +42 -2118
  515. package/dist/components/composed-offset-position.esm.js +1 -1
  516. package/dist/components/conditionalSlot.js +1 -1
  517. package/dist/components/date-picker-day.js +1 -1
  518. package/dist/components/date-picker-month-header.js +1 -1
  519. package/dist/components/date-picker-month.js +1 -1
  520. package/dist/components/date-picker.js +2 -2
  521. package/dist/components/date.js +1 -1
  522. package/dist/components/debounce.js +1 -1
  523. package/dist/components/dom.js +1 -1
  524. package/dist/components/dropdown.js +1 -1
  525. package/dist/components/filter.js +1 -1
  526. package/dist/components/filter2.js +1 -1
  527. package/dist/components/floating-ui.js +68 -62
  528. package/dist/components/focusTrapComponent.js +1 -1
  529. package/dist/components/form.js +1 -1
  530. package/dist/components/graph.js +1 -1
  531. package/dist/components/guid.js +1 -1
  532. package/dist/components/handle.js +1 -1
  533. package/dist/components/icon.js +1 -1
  534. package/dist/components/index.js +1 -1
  535. package/dist/components/index2.js +2116 -0
  536. package/dist/components/input-number.js +623 -0
  537. package/dist/components/input.js +2 -2
  538. package/dist/components/interactive.js +1 -1
  539. package/dist/components/key.js +1 -1
  540. package/dist/components/label.js +1 -1
  541. package/dist/components/label2.js +1 -1
  542. package/dist/components/link.js +1 -1
  543. package/dist/components/loadable.js +1 -1
  544. package/dist/components/loader.js +1 -1
  545. package/dist/components/locale.js +2 -2
  546. package/dist/components/math.js +1 -1
  547. package/dist/components/observers.js +1 -1
  548. package/dist/components/openCloseComponent.js +1 -1
  549. package/dist/components/panel.js +1 -1
  550. package/dist/components/pick-list-item.js +1 -1
  551. package/dist/components/popover.js +1 -1
  552. package/dist/components/progress.js +1 -1
  553. package/dist/components/resources.js +1 -1
  554. package/dist/components/resources2.js +1 -1
  555. package/dist/components/resources3.js +1 -1
  556. package/dist/components/scrim.js +1 -1
  557. package/dist/components/shared-list-render.js +1 -1
  558. package/dist/components/sortable.esm.js +1 -1
  559. package/dist/components/switch.js +1 -1
  560. package/dist/components/t9n.js +1 -1
  561. package/dist/components/tab-nav.js +1 -1
  562. package/dist/components/tab-title.js +1 -1
  563. package/dist/components/tab.js +1 -1
  564. package/dist/components/tabs.js +1 -1
  565. package/dist/components/throttle.js +1 -1
  566. package/dist/components/tile.js +1 -1
  567. package/dist/components/time-picker.js +2 -2
  568. package/dist/components/tooltip.js +1 -1
  569. package/dist/components/utils.js +112 -31
  570. package/dist/components/utils2.js +1 -1
  571. package/dist/components/utils3.js +1 -1
  572. package/dist/esm/{ExpandToggle-095e2f69.js → ExpandToggle-84cd3334.js} +5 -5
  573. package/dist/esm/{FloatingArrow-4e190499.js → FloatingArrow-2a728102.js} +2 -2
  574. package/dist/esm/{Heading-08826e02.js → Heading-aa5e7f03.js} +2 -2
  575. package/dist/esm/{app-globals-a86875ad.js → app-globals-9a63f836.js} +2 -2
  576. package/dist/esm/{array-937e8e63.js → array-cba42ef7.js} +1 -1
  577. package/dist/esm/calcite-accordion_2.entry.js +7 -7
  578. package/dist/esm/calcite-action-bar.entry.js +15 -15
  579. package/dist/esm/calcite-action-group.entry.js +13 -13
  580. package/dist/esm/calcite-action-menu.entry.js +9 -9
  581. package/dist/esm/calcite-action-pad.entry.js +14 -14
  582. package/dist/esm/calcite-action.entry.js +11 -11
  583. package/dist/esm/calcite-alert.entry.js +12 -12
  584. package/dist/esm/calcite-avatar.entry.js +6 -6
  585. package/dist/esm/calcite-block_2.entry.js +12 -12
  586. package/dist/esm/calcite-button.entry.js +13 -13
  587. package/dist/esm/calcite-card.entry.js +10 -10
  588. package/dist/esm/calcite-checkbox.entry.js +10 -10
  589. package/dist/esm/calcite-chip-group.entry.js +8 -8
  590. package/dist/esm/calcite-chip.entry.js +12 -12
  591. package/dist/esm/calcite-color-picker_3.entry.js +585 -339
  592. package/dist/esm/calcite-combobox_3.entry.js +18 -18
  593. package/dist/esm/calcite-date-picker_4.entry.js +13 -13
  594. package/dist/esm/calcite-dropdown_3.entry.js +12 -12
  595. package/dist/esm/calcite-fab.entry.js +7 -7
  596. package/dist/esm/calcite-filter.entry.js +13 -13
  597. package/dist/esm/calcite-flow-item.entry.js +12 -12
  598. package/dist/esm/calcite-flow.entry.js +3 -3
  599. package/dist/esm/calcite-graph_2.entry.js +13 -13
  600. package/dist/esm/calcite-handle.entry.js +10 -10
  601. package/dist/esm/calcite-icon.entry.js +6 -6
  602. package/dist/esm/calcite-inline-editable.entry.js +12 -12
  603. package/dist/esm/calcite-input-date-picker.entry.js +18 -18
  604. package/dist/esm/calcite-input-message.entry.js +5 -5
  605. package/dist/esm/calcite-input-number.entry.js +13 -13
  606. package/dist/esm/calcite-input-text.entry.js +13 -13
  607. package/dist/esm/calcite-input-time-picker_2.entry.js +14 -14
  608. package/dist/esm/calcite-input.entry.js +13 -13
  609. package/dist/esm/calcite-label.entry.js +6 -6
  610. package/dist/esm/calcite-link.entry.js +7 -7
  611. package/dist/esm/calcite-list_3.entry.js +50 -40
  612. package/dist/esm/calcite-loader.entry.js +3 -3
  613. package/dist/esm/calcite-modal.entry.js +13 -13
  614. package/dist/esm/calcite-notice.entry.js +12 -12
  615. package/dist/esm/calcite-option_3.entry.js +10 -10
  616. package/dist/esm/calcite-pagination.entry.js +10 -10
  617. package/dist/esm/calcite-panel.entry.js +14 -14
  618. package/dist/esm/calcite-pick-list_3.entry.js +16 -16
  619. package/dist/esm/calcite-popover.entry.js +16 -16
  620. package/dist/esm/calcite-progress.entry.js +2 -2
  621. package/dist/esm/calcite-radio-button-group.entry.js +3 -3
  622. package/dist/esm/calcite-radio-button.entry.js +10 -10
  623. package/dist/esm/calcite-rating.entry.js +13 -13
  624. package/dist/esm/calcite-scrim.entry.js +9 -9
  625. package/dist/esm/calcite-segmented-control_2.entry.js +9 -9
  626. package/dist/esm/calcite-shell_3.entry.js +11 -11
  627. package/dist/esm/calcite-sortable-list.entry.js +5 -5
  628. package/dist/esm/calcite-split-button.entry.js +4 -4
  629. package/dist/esm/calcite-stepper_2.entry.js +10 -10
  630. package/dist/esm/calcite-switch.entry.js +10 -10
  631. package/dist/esm/calcite-tab_4.entry.js +7 -7
  632. package/dist/esm/calcite-text-area.entry.js +15 -15
  633. package/dist/esm/calcite-tile-select_2.entry.js +5 -5
  634. package/dist/esm/calcite-tile.entry.js +8 -8
  635. package/dist/esm/calcite-tip_3.entry.js +11 -11
  636. package/dist/esm/calcite-tooltip.entry.js +9 -9
  637. package/dist/esm/calcite-tree_2.entry.js +9 -9
  638. package/dist/esm/calcite-value-list_2.entry.js +16 -16
  639. package/dist/esm/calcite.js +6 -6
  640. package/dist/esm/{composed-offset-position.esm-fb83e249.js → composed-offset-position.esm-2c2ff148.js} +1 -1
  641. package/dist/esm/{conditionalSlot-98fcfe31.js → conditionalSlot-734f45e3.js} +3 -3
  642. package/dist/esm/{debounce-911eef82.js → debounce-13053af0.js} +1 -1
  643. package/dist/esm/{dom-2b55c6b1.js → dom-3643d47b.js} +3 -3
  644. package/dist/esm/{filter-6a2a0d23.js → filter-c124b3a7.js} +2 -2
  645. package/dist/esm/{floating-ui-1f96fa4e.js → floating-ui-dde330fd.js} +71 -65
  646. package/dist/esm/{focusTrapComponent-9f5c20f0.js → focusTrapComponent-be382f0c.js} +2 -2
  647. package/dist/esm/{form-ef433149.js → form-9b4d08d5.js} +3 -3
  648. package/dist/esm/{guid-08c9d9d2.js → guid-00c961cf.js} +1 -1
  649. package/dist/esm/{index-34f68bbe.js → index-de813188.js} +1 -1
  650. package/dist/esm/index.js +2 -2
  651. package/dist/esm/{interactive-a2eb6b56.js → interactive-7577fa95.js} +1 -1
  652. package/dist/esm/{key-a12e3d36.js → key-204f54dc.js} +1 -1
  653. package/dist/esm/{label-e5638056.js → label-aa3ca023.js} +2 -2
  654. package/dist/esm/{loadable-7ddbc3f7.js → loadable-295e7059.js} +1 -1
  655. package/dist/esm/loader.js +6 -6
  656. package/dist/esm/{locale-cdbef5ac.js → locale-cf07a13b.js} +4 -4
  657. package/dist/esm/{math-2b6a45bc.js → math-81cb18a5.js} +1 -1
  658. package/dist/esm/{observers-58b3356b.js → observers-e24920a0.js} +1 -1
  659. package/dist/esm/{openCloseComponent-6350a6b9.js → openCloseComponent-d6957380.js} +2 -2
  660. package/dist/esm/{resources-f97f2e3d.js → resources-20a9105d.js} +1 -1
  661. package/dist/esm/{resources-95e5c0bc.js → resources-510afe06.js} +1 -1
  662. package/dist/esm/{resources-52988112.js → resources-b814eba0.js} +5 -5
  663. package/dist/esm/{resources-87498192.js → resources-b81c1240.js} +1 -1
  664. package/dist/esm/{resources-66bba32b.js → resources-d27d888f.js} +1 -1
  665. package/dist/esm/{resources-509df361.js → resources-f496ba11.js} +1 -1
  666. package/dist/esm/{sortable.esm-69990d9c.js → sortable.esm-8c3ec43a.js} +1 -1
  667. package/dist/esm/{t9n-c5155b27.js → t9n-62bf4e90.js} +3 -3
  668. package/dist/esm/{throttle-161e1712.js → throttle-ab3e5fce.js} +2 -2
  669. package/dist/esm/utils-119581ee.js +195 -0
  670. package/dist/esm/{utils-4c71f289.js → utils-1692b158.js} +3 -3
  671. package/dist/extras/docs-json.json +156 -30
  672. package/dist/extras/vscode-data.json +22 -2
  673. package/dist/loader/cdn.js +1 -1
  674. package/dist/loader/index.cjs.js +1 -1
  675. package/dist/loader/index.es2017.js +1 -1
  676. package/dist/loader/index.js +1 -1
  677. package/dist/types/components/color-picker/color-picker.d.ts +54 -23
  678. package/dist/types/components/color-picker/interfaces.d.ts +1 -0
  679. package/dist/types/components/color-picker/resources.d.ts +28 -18
  680. package/dist/types/components/color-picker/utils.d.ts +16 -7
  681. package/dist/types/components/color-picker-hex-input/color-picker-hex-input.d.ts +33 -16
  682. package/dist/types/components/color-picker-hex-input/resources.d.ts +2 -2
  683. package/dist/types/components/color-picker-swatch/color-picker-swatch.d.ts +3 -2
  684. package/dist/types/components/color-picker-swatch/resources.d.ts +6 -1
  685. package/dist/types/components/list/list.d.ts +7 -2
  686. package/dist/types/components/list/resources.d.ts +1 -1
  687. package/dist/types/components.d.ts +62 -6
  688. package/dist/types/preact.d.ts +2 -1
  689. package/hydrate/index.js +796 -447
  690. package/package.json +4 -5
  691. package/dist/calcite/p-2927ff1d.js +0 -6
  692. package/dist/calcite/p-3623550f.entry.js +0 -6
  693. package/dist/calcite/p-5782f6ba.js +0 -6
  694. package/dist/calcite/p-5e1869b5.js +0 -6
  695. package/dist/calcite/p-663a4c37.js +0 -6
  696. package/dist/calcite/p-8b7561ca.js +0 -6
  697. package/dist/calcite/p-95860b15.entry.js +0 -6
  698. package/dist/calcite/p-b0a41644.js +0 -6
  699. package/dist/calcite/p-b1dcf567.js +0 -6
  700. package/dist/calcite/p-b73ede81.entry.js +0 -6
  701. package/dist/calcite/p-c107f270.entry.js +0 -6
  702. package/dist/calcite/p-f8d77f71.entry.js +0 -6
  703. package/dist/cjs/utils-78b4120a.js +0 -124
  704. package/dist/esm/utils-ab93be5f.js +0 -114
@@ -1,22 +1,24 @@
1
1
  /*!
2
2
  * All material copyright ESRI, All Rights Reserved, unless otherwise specified.
3
3
  * See https://github.com/Esri/calcite-components/blob/master/LICENSE.md for details.
4
- * v1.4.0-next.4
4
+ * v1.4.0-next.6
5
5
  */
6
6
  import { proxyCustomElement, HTMLElement, createEvent, h } from '@stencil/core/internal/client/index.js';
7
- import { c as color, d as defineCustomElement$a } from './color-picker-swatch.js';
7
+ import { c as color } from './index2.js';
8
8
  import { j as isPrimaryPointerButton, c as getElementDir } from './dom.js';
9
- import { n as normalizeHex, C as CSSColorMode, p as parseMode, c as colorEqual } from './utils.js';
9
+ import { C as CSS, D as DEFAULT_COLOR, a as DIMENSIONS, H as HSV_LIMITS, O as OPACITY_LIMITS, d as defineCustomElement$c, b as DEFAULT_STORAGE_KEY_PREFIX, R as RGB_LIMITS } from './color-picker-hex-input.js';
10
+ import { C as CSSColorMode, n as normalizeHex, a as hexify, b as alphaCompatible, o as opacityToAlpha, c as alphaToOpacity, p as parseMode, d as colorEqual, t as toNonAlphaMode, e as normalizeAlpha, f as normalizeColor, g as toAlphaMode } from './utils.js';
10
11
  import { u as updateHostInteraction } from './interactive.js';
11
12
  import { i as isActivationKey } from './key.js';
12
13
  import { c as componentLoaded, a as setUpLoadableComponent, s as setComponentLoaded } from './loadable.js';
13
14
  import { c as connectLocalized, d as disconnectLocalized } from './locale.js';
14
15
  import { c as clamp } from './math.js';
15
16
  import { u as updateMessages, s as setUpMessages, c as connectMessages, d as disconnectMessages } from './t9n.js';
16
- import { d as defineCustomElement$c } from './button.js';
17
- import { d as defineCustomElement$b } from './color-picker-hex-input.js';
18
- import { d as defineCustomElement$9 } from './icon.js';
19
- import { d as defineCustomElement$8 } from './input.js';
17
+ import { d as defineCustomElement$d } from './button.js';
18
+ import { d as defineCustomElement$b } from './color-picker-swatch.js';
19
+ import { d as defineCustomElement$a } from './icon.js';
20
+ import { d as defineCustomElement$9 } from './input.js';
21
+ import { d as defineCustomElement$8 } from './input-number.js';
20
22
  import { d as defineCustomElement$7 } from './loader.js';
21
23
  import { d as defineCustomElement$6 } from './progress.js';
22
24
  import { d as defineCustomElement$5 } from './tab.js';
@@ -25,91 +27,9 @@ import { d as defineCustomElement$3 } from './tab-title.js';
25
27
  import { d as defineCustomElement$2 } from './tabs.js';
26
28
  import { t as throttle } from './throttle.js';
27
29
 
28
- const CSS = {
29
- container: "container",
30
- controlSection: "control-section",
31
- hexOptions: "color-hex-options",
32
- section: "section",
33
- header: "header",
34
- control: "control",
35
- splitSection: "section--split",
36
- colorModeContainer: "color-mode-container",
37
- colorMode: "color-mode",
38
- channels: "channels",
39
- channel: "channel",
40
- savedColors: "saved-colors",
41
- savedColorsSection: "saved-colors-section",
42
- saveColor: "save-color",
43
- deleteColor: "delete-color",
44
- savedColorsButtons: "saved-colors-buttons",
45
- headerHex: "header--hex",
46
- colorFieldAndSlider: "color-field-and-slider",
47
- colorFieldAndSliderInteractive: "color-field-and-slider--interactive",
48
- colorFieldAndSliderWrap: "color-field-and-slider-wrap",
49
- scope: "scope",
50
- hueScope: "scope--hue",
51
- colorFieldScope: "scope--color-field",
52
- savedColor: "saved-color"
53
- };
54
- const DEFAULT_COLOR = color("#007AC2");
55
- const DEFAULT_STORAGE_KEY_PREFIX = "calcite-color-";
56
- const RGB_LIMITS = {
57
- r: 255,
58
- g: 255,
59
- b: 255
60
- };
61
- const HSV_LIMITS = {
62
- h: 360,
63
- s: 100,
64
- v: 100
65
- };
66
- const DIMENSIONS = {
67
- s: {
68
- slider: {
69
- height: 10,
70
- width: 160
71
- },
72
- colorField: {
73
- height: 80,
74
- width: 160
75
- },
76
- thumb: {
77
- radius: 8
78
- }
79
- },
80
- m: {
81
- slider: {
82
- height: 14,
83
- width: 272
84
- },
85
- colorField: {
86
- height: 150,
87
- width: 272
88
- },
89
- thumb: {
90
- radius: 10
91
- }
92
- },
93
- l: {
94
- slider: {
95
- height: 16,
96
- width: 464
97
- },
98
- colorField: {
99
- height: 200,
100
- width: 464
101
- },
102
- thumb: {
103
- radius: 12
104
- }
105
- }
106
- };
107
-
108
- const colorPickerCss = "@keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in-down{0%{opacity:0;transform:translate3D(0, -5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;transform:translate3D(0, 5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-scale{0%{opacity:0;transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;transform:scale3D(1, 1, 1)}}:root{--calcite-animation-timing:calc(150ms * var(--calcite-internal-duration-factor));--calcite-internal-duration-factor:var(--calcite-duration-factor, 1);--calcite-internal-animation-timing-fast:calc(100ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-medium:calc(200ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-slow:calc(300ms * var(--calcite-internal-duration-factor))}.calcite-animate{opacity:0;animation-fill-mode:both;animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{animation-name:in}.calcite-animate__in-down{animation-name:in-down}.calcite-animate__in-up{animation-name:in-up}.calcite-animate__in-scale{animation-name:in-scale}@media (prefers-reduced-motion: reduce){:root{--calcite-internal-duration-factor:0.01}}:root{--calcite-floating-ui-transition:var(--calcite-animation-timing);--calcite-floating-ui-z-index:600}:host([hidden]){display:none}:host([disabled]){cursor:default;-webkit-user-select:none;user-select:none;opacity:var(--calcite-ui-opacity-disabled)}:host([disabled]) *,:host([disabled]) ::slotted(*){pointer-events:none}:host{display:inline-block;font-size:var(--calcite-font-size--2);line-height:1rem;font-weight:var(--calcite-font-weight-normal)}:host([disabled]) ::slotted([calcite-hydrated][disabled]),:host([disabled]) [calcite-hydrated][disabled]{opacity:1}:host([scale=s]) .container{inline-size:160px}:host([scale=s]) .saved-colors{grid-template-columns:repeat(auto-fill, minmax(20px, 1fr))}:host([scale=s]) .channels{flex-direction:column}:host([scale=s]) .channel{inline-size:100%;margin-block-end:4px}:host([scale=s]) .channel:last-child{margin-block-end:0}:host([scale=m]) .container{inline-size:272px}:host([scale=l]) .header{padding-block-end:0px}:host([scale=l]){font-size:var(--calcite-font-size--1);line-height:1rem}:host([scale=l]) .container{inline-size:464px}:host([scale=l]) .color-field-and-slider{margin-block-end:-20px}:host([scale=l]) .section{padding-block:0 16px;padding-inline:16px}:host([scale=l]) .section:first-of-type{padding-block-start:16px}:host([scale=l]) .saved-colors{grid-template-columns:repeat(auto-fill, minmax(28px, 1fr));grid-gap:12px;padding-block-start:16px}:host([scale=l]) .control-section{flex-wrap:nowrap;align-items:baseline}:host([scale=l]) .control-section>:nth-child(2){margin-inline-start:12px}:host([scale=l]) .color-hex-options{display:flex;flex-shrink:1;flex-direction:column;justify-content:space-around;min-block-size:98px;inline-size:160px}:host([scale=l]) .color-mode-container{flex-shrink:3}.container{background-color:var(--calcite-ui-foreground-1);display:inline-block;border:1px solid var(--calcite-ui-border-1)}.color-field-and-slider-wrap{position:relative}.scope{position:absolute;font-size:var(--calcite-font-size--1);outline-color:transparent;outline-offset:14px}.scope:focus{outline:2px solid var(--calcite-ui-focus-color, var(--calcite-ui-brand));outline-offset:calc(\n 2px *\n calc(\n 1 -\n 2 * clamp(\n 0,\n var(--calcite-ui-focus-offset-invert),\n 1\n )\n )\n );outline-offset:16px}.color-field-and-slider{margin-block-end:-16px;touch-action:none}.color-field-and-slider--interactive{cursor:pointer}.control-section{display:flex;flex-direction:row;flex-wrap:wrap}.section{padding-block:0 12px;padding-inline:12px}.section:first-of-type{padding-block-start:12px}.color-hex-options,.section--split{flex-grow:1}.header{display:flex;align-items:center;justify-content:space-between;padding-block-end:0.25rem;color:var(--calcite-ui-text-1)}.header--hex,.color-mode-container{padding-block-start:12px}.channels{display:flex;justify-content:space-between}.channel{inline-size:31%}.saved-colors{padding-block-start:12px;display:grid;grid-template-columns:repeat(auto-fill, minmax(24px, 1fr));grid-gap:8px;inline-size:100%}.saved-colors-buttons{display:flex}.saved-color{outline-offset:0;outline-color:transparent;cursor:pointer}.saved-color:focus{outline:2px solid var(--calcite-ui-brand);outline-offset:2px}.saved-color:hover{transition:outline-color var(--calcite-internal-animation-timing-fast) ease-in-out;outline:2px solid var(--calcite-ui-border-2);outline-offset:2px}";
30
+ const colorPickerCss = "@keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in-down{0%{opacity:0;transform:translate3D(0, -5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;transform:translate3D(0, 5px, 0)}100%{opacity:1;transform:translate3D(0, 0, 0)}}@keyframes in-scale{0%{opacity:0;transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;transform:scale3D(1, 1, 1)}}:root{--calcite-animation-timing:calc(150ms * var(--calcite-internal-duration-factor));--calcite-internal-duration-factor:var(--calcite-duration-factor, 1);--calcite-internal-animation-timing-fast:calc(100ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-medium:calc(200ms * var(--calcite-internal-duration-factor));--calcite-internal-animation-timing-slow:calc(300ms * var(--calcite-internal-duration-factor))}.calcite-animate{opacity:0;animation-fill-mode:both;animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{animation-name:in}.calcite-animate__in-down{animation-name:in-down}.calcite-animate__in-up{animation-name:in-up}.calcite-animate__in-scale{animation-name:in-scale}@media (prefers-reduced-motion: reduce){:root{--calcite-internal-duration-factor:0.01}}:root{--calcite-floating-ui-transition:var(--calcite-animation-timing);--calcite-floating-ui-z-index:600}:host([hidden]){display:none}:host([disabled]){cursor:default;-webkit-user-select:none;user-select:none;opacity:var(--calcite-ui-opacity-disabled)}:host([disabled]) *,:host([disabled]) ::slotted(*){pointer-events:none}:host{display:inline-block;font-size:var(--calcite-font-size--2);line-height:1rem;font-weight:var(--calcite-font-weight-normal)}:host([disabled]) ::slotted([calcite-hydrated][disabled]),:host([disabled]) [calcite-hydrated][disabled]{opacity:1}:host([scale=s]){--calcite-color-picker-spacing:8px}:host([scale=s]) .container{inline-size:160px}:host([scale=s]) .saved-colors{gap:0.25rem;grid-template-columns:repeat(auto-fill, 20px)}:host([scale=m]){--calcite-color-picker-spacing:12px}:host([scale=m]) .container{inline-size:272px}:host([scale=l]){--calcite-color-picker-spacing:16px;font-size:var(--calcite-font-size--1);line-height:1rem}:host([scale=l]) .container{inline-size:464px}:host([scale=l]) .section:first-of-type{padding-block-start:var(--calcite-color-picker-spacing)}:host([scale=l]) .saved-colors{grid-template-columns:repeat(auto-fill, 32px)}:host([scale=l]) .control-section{flex-wrap:nowrap;align-items:baseline;flex-wrap:wrap}:host([scale=l]) .color-hex-options{display:flex;flex-shrink:1;flex-direction:column;justify-content:space-around}:host([scale=l]) .color-mode-container{flex-shrink:3}.container{background-color:var(--calcite-ui-foreground-1);display:inline-block;border:1px solid var(--calcite-ui-border-1)}.control-and-scope{position:relative;display:flex;cursor:pointer;touch-action:none}.scope{position:absolute;z-index:1;font-size:var(--calcite-font-size--1);outline-color:transparent}.scope:focus{outline:2px solid var(--calcite-ui-focus-color, var(--calcite-ui-brand));outline-offset:calc(\n 2px *\n calc(\n 1 -\n 2 * clamp(\n 0,\n var(--calcite-ui-focus-offset-invert),\n 1\n )\n )\n );outline-offset:16px}.hex-and-channels-group{inline-size:100%}.hex-and-channels-group,.control-section{display:flex;flex-direction:row;flex-wrap:wrap}.section{padding-block:0 var(--calcite-color-picker-spacing);padding-inline:var(--calcite-color-picker-spacing)}.section:first-of-type{padding-block-start:var(--calcite-color-picker-spacing)}.sliders{display:flex;flex-direction:column;justify-content:space-between;margin-inline-start:var(--calcite-color-picker-spacing)}.preview-and-sliders{display:flex;align-items:center;padding:var(--calcite-color-picker-spacing)}.color-hex-options,.section--split{flex-grow:1}.header{display:flex;align-items:center;justify-content:space-between;color:var(--calcite-ui-text-1)}.color-mode-container{padding-block-start:var(--calcite-color-picker-spacing)}.channels{display:flex;row-gap:0.125rem}.channel[data-channel-index=\"3\"]{inline-size:159px}:host([scale=s]) .channels{flex-wrap:wrap}:host([scale=s]) .channel{flex-basis:30%;flex-grow:1}:host([scale=s]) .channel[data-channel-index=\"3\"]{inline-size:unset;margin-inline-start:unset}:host([scale=l]) .channel[data-channel-index=\"3\"]{inline-size:131px}.saved-colors{display:grid;gap:0.5rem;padding-block-start:var(--calcite-color-picker-spacing);grid-template-columns:repeat(auto-fill, 24px)}.saved-colors-buttons{display:flex}.saved-color{outline-offset:0;outline-color:transparent;cursor:pointer}.saved-color:focus{outline:2px solid var(--calcite-ui-brand);outline-offset:2px}.saved-color:hover{transition:outline-color var(--calcite-internal-animation-timing-fast) ease-in-out;outline:2px solid var(--calcite-ui-border-2);outline-offset:2px}";
109
31
 
110
32
  const throttleFor60FpsInMs = 16;
111
- const defaultValue = normalizeHex(DEFAULT_COLOR.hex());
112
- const defaultFormat = "auto";
113
33
  const ColorPicker = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
114
34
  constructor() {
115
35
  super();
@@ -117,12 +37,9 @@ const ColorPicker = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
117
37
  this.__attachShadow();
118
38
  this.calciteColorPickerChange = createEvent(this, "calciteColorPickerChange", 6);
119
39
  this.calciteColorPickerInput = createEvent(this, "calciteColorPickerInput", 6);
120
- this.colorFieldAndSliderHovered = false;
121
- this.hueThumbState = "idle";
122
40
  this.internalColorUpdateContext = null;
123
41
  this.mode = CSSColorMode.HEX;
124
42
  this.shiftKeyChannelAdjustment = 0;
125
- this.sliderThumbState = "idle";
126
43
  this.handleTabActivate = (event) => {
127
44
  this.channelMode = event.currentTarget.getAttribute("data-color-mode");
128
45
  this.updateChannelsFromColor(this.color);
@@ -167,7 +84,7 @@ const ColorPicker = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
167
84
  this.internalColorSet(null);
168
85
  return;
169
86
  }
170
- const normalizedHex = color$1 && normalizeHex(color$1.hex());
87
+ const normalizedHex = color$1 && normalizeHex(hexify(color$1, alphaCompatible(this.mode)));
171
88
  if (hex !== normalizedHex) {
172
89
  this.internalColorSet(color(hex));
173
90
  }
@@ -179,16 +96,20 @@ const ColorPicker = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
179
96
  this.handleChannelInput = (event) => {
180
97
  const input = event.currentTarget;
181
98
  const channelIndex = Number(input.getAttribute("data-channel-index"));
182
- const limit = this.channelMode === "rgb"
183
- ? RGB_LIMITS[Object.keys(RGB_LIMITS)[channelIndex]]
184
- : HSV_LIMITS[Object.keys(HSV_LIMITS)[channelIndex]];
99
+ const isAlphaChannel = channelIndex === 3;
100
+ const limit = isAlphaChannel
101
+ ? OPACITY_LIMITS.max
102
+ : this.channelMode === "rgb"
103
+ ? RGB_LIMITS[Object.keys(RGB_LIMITS)[channelIndex]]
104
+ : HSV_LIMITS[Object.keys(HSV_LIMITS)[channelIndex]];
185
105
  let inputValue;
186
106
  if (this.allowEmpty && !input.value) {
187
107
  inputValue = "";
188
108
  }
189
109
  else {
190
- const value = Number(input.value) + this.shiftKeyChannelAdjustment;
191
- const clamped = clamp(value, 0, limit);
110
+ const value = Number(input.value);
111
+ const adjustedValue = value + this.shiftKeyChannelAdjustment;
112
+ const clamped = clamp(adjustedValue, 0, limit);
192
113
  inputValue = clamped.toString();
193
114
  }
194
115
  input.value = inputValue;
@@ -202,11 +123,13 @@ const ColorPicker = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
202
123
  const channels = [...this.channels];
203
124
  const shouldClearChannels = this.allowEmpty && !input.value;
204
125
  if (shouldClearChannels) {
205
- this.channels = [null, null, null];
126
+ this.channels = [null, null, null, null];
206
127
  this.internalColorSet(null);
207
128
  return;
208
129
  }
209
- channels[channelIndex] = Number(input.value);
130
+ const isAlphaChannel = channelIndex === 3;
131
+ const value = Number(input.value);
132
+ channels[channelIndex] = isAlphaChannel ? opacityToAlpha(value) : value;
210
133
  this.updateColorFromChannels(channels);
211
134
  };
212
135
  this.handleSavedColorKeyDown = (event) => {
@@ -215,144 +138,101 @@ const ColorPicker = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
215
138
  this.handleSavedColorSelect(event);
216
139
  }
217
140
  };
218
- this.handleColorFieldAndSliderPointerLeave = () => {
219
- this.colorFieldAndSliderInteractive = false;
220
- this.colorFieldAndSliderHovered = false;
221
- if (this.sliderThumbState !== "drag" && this.hueThumbState !== "drag") {
222
- this.hueThumbState = "idle";
223
- this.sliderThumbState = "idle";
224
- this.drawColorFieldAndSlider();
225
- }
226
- };
227
- this.handleColorFieldAndSliderPointerDown = (event) => {
141
+ this.handleColorFieldPointerDown = (event) => {
228
142
  if (!isPrimaryPointerButton(event)) {
229
143
  return;
230
144
  }
231
145
  const { offsetX, offsetY } = event;
232
- const region = this.getCanvasRegion(offsetY);
233
- if (region === "color-field") {
234
- this.hueThumbState = "drag";
235
- this.captureColorFieldColor(offsetX, offsetY);
236
- this.colorFieldScopeNode?.focus();
146
+ document.addEventListener("pointermove", this.globalPointerMoveHandler);
147
+ document.addEventListener("pointerup", this.globalPointerUpHandler, { once: true });
148
+ this.activeCanvasInfo = {
149
+ context: this.colorFieldRenderingContext,
150
+ bounds: this.colorFieldRenderingContext.canvas.getBoundingClientRect()
151
+ };
152
+ this.captureColorFieldColor(offsetX, offsetY);
153
+ this.colorFieldScopeNode.focus();
154
+ };
155
+ this.handleHueSliderPointerDown = (event) => {
156
+ if (!isPrimaryPointerButton(event)) {
157
+ return;
237
158
  }
238
- else if (region === "slider") {
239
- this.sliderThumbState = "drag";
240
- this.captureHueSliderColor(offsetX);
241
- this.hueScopeNode?.focus();
159
+ const { offsetX } = event;
160
+ document.addEventListener("pointermove", this.globalPointerMoveHandler);
161
+ document.addEventListener("pointerup", this.globalPointerUpHandler, { once: true });
162
+ this.activeCanvasInfo = {
163
+ context: this.hueSliderRenderingContext,
164
+ bounds: this.hueSliderRenderingContext.canvas.getBoundingClientRect()
165
+ };
166
+ this.captureHueSliderColor(offsetX);
167
+ this.hueScopeNode.focus();
168
+ };
169
+ this.handleOpacitySliderPointerDown = (event) => {
170
+ if (!isPrimaryPointerButton(event)) {
171
+ return;
242
172
  }
173
+ const { offsetX } = event;
243
174
  document.addEventListener("pointermove", this.globalPointerMoveHandler);
244
175
  document.addEventListener("pointerup", this.globalPointerUpHandler, { once: true });
245
- this.activeColorFieldAndSliderRect =
246
- this.fieldAndSliderRenderingContext.canvas.getBoundingClientRect();
176
+ this.activeCanvasInfo = {
177
+ context: this.opacitySliderRenderingContext,
178
+ bounds: this.opacitySliderRenderingContext.canvas.getBoundingClientRect()
179
+ };
180
+ this.captureOpacitySliderValue(offsetX);
181
+ this.opacityScopeNode.focus();
247
182
  };
248
183
  this.globalPointerUpHandler = (event) => {
249
184
  if (!isPrimaryPointerButton(event)) {
250
185
  return;
251
186
  }
252
- const previouslyDragging = this.sliderThumbState === "drag" || this.hueThumbState === "drag";
253
- this.hueThumbState = "idle";
254
- this.sliderThumbState = "idle";
255
- this.activeColorFieldAndSliderRect = null;
256
- this.drawColorFieldAndSlider();
187
+ const previouslyDragging = this.activeCanvasInfo;
188
+ this.activeCanvasInfo = null;
189
+ this.drawColorControls();
257
190
  if (previouslyDragging) {
258
191
  this.calciteColorPickerChange.emit();
259
192
  }
260
193
  };
261
194
  this.globalPointerMoveHandler = (event) => {
262
- const { el, dimensions } = this;
263
- const sliderThumbDragging = this.sliderThumbState === "drag";
264
- const hueThumbDragging = this.hueThumbState === "drag";
265
- if (!el.isConnected || (!sliderThumbDragging && !hueThumbDragging)) {
195
+ const { activeCanvasInfo, el } = this;
196
+ if (!el.isConnected || !activeCanvasInfo) {
266
197
  return;
267
198
  }
199
+ const { context, bounds } = activeCanvasInfo;
268
200
  let samplingX;
269
201
  let samplingY;
270
- const colorFieldAndSliderRect = this.activeColorFieldAndSliderRect;
271
202
  const { clientX, clientY } = event;
272
- if (this.colorFieldAndSliderHovered) {
273
- samplingX = clientX - colorFieldAndSliderRect.x;
274
- samplingY = clientY - colorFieldAndSliderRect.y;
203
+ if (context.canvas.matches(":hover")) {
204
+ samplingX = clientX - bounds.x;
205
+ samplingY = clientY - bounds.y;
275
206
  }
276
207
  else {
277
- const colorFieldWidth = dimensions.colorField.width;
278
- const colorFieldHeight = dimensions.colorField.height;
279
- const hueSliderHeight = dimensions.slider.height;
280
- if (clientX < colorFieldAndSliderRect.x + colorFieldWidth &&
281
- clientX > colorFieldAndSliderRect.x) {
282
- samplingX = clientX - colorFieldAndSliderRect.x;
208
+ // snap x and y to the closest edge
209
+ if (clientX < bounds.x + bounds.width && clientX > bounds.x) {
210
+ samplingX = clientX - bounds.x;
283
211
  }
284
- else if (clientX < colorFieldAndSliderRect.x) {
212
+ else if (clientX < bounds.x) {
285
213
  samplingX = 0;
286
214
  }
287
215
  else {
288
- samplingX = colorFieldWidth - 1;
216
+ samplingX = bounds.width;
289
217
  }
290
- if (clientY < colorFieldAndSliderRect.y + colorFieldHeight + hueSliderHeight &&
291
- clientY > colorFieldAndSliderRect.y) {
292
- samplingY = clientY - colorFieldAndSliderRect.y;
218
+ if (clientY < bounds.y + bounds.height && clientY > bounds.y) {
219
+ samplingY = clientY - bounds.y;
293
220
  }
294
- else if (clientY < colorFieldAndSliderRect.y) {
221
+ else if (clientY < bounds.y) {
295
222
  samplingY = 0;
296
223
  }
297
224
  else {
298
- samplingY = colorFieldHeight + hueSliderHeight;
225
+ samplingY = bounds.height;
299
226
  }
300
227
  }
301
- if (hueThumbDragging) {
228
+ if (context === this.colorFieldRenderingContext) {
302
229
  this.captureColorFieldColor(samplingX, samplingY, false);
303
230
  }
304
- else {
231
+ else if (context === this.hueSliderRenderingContext) {
305
232
  this.captureHueSliderColor(samplingX);
306
233
  }
307
- };
308
- this.handleColorFieldAndSliderPointerEnterOrMove = ({ offsetX, offsetY }) => {
309
- const { dimensions: { colorField, slider, thumb } } = this;
310
- this.colorFieldAndSliderInteractive = offsetY <= colorField.height + slider.height;
311
- this.colorFieldAndSliderHovered = true;
312
- const region = this.getCanvasRegion(offsetY);
313
- if (region === "color-field") {
314
- const prevHueThumbState = this.hueThumbState;
315
- const color = this.baseColorFieldColor.hsv();
316
- const centerX = Math.round(color.saturationv() / (HSV_LIMITS.s / colorField.width));
317
- const centerY = Math.round(colorField.height - color.value() / (HSV_LIMITS.v / colorField.height));
318
- const hoveringThumb = this.containsPoint(offsetX, offsetY, centerX, centerY, thumb.radius);
319
- let transitionedBetweenHoverAndIdle = false;
320
- if (prevHueThumbState === "idle" && hoveringThumb) {
321
- this.hueThumbState = "hover";
322
- transitionedBetweenHoverAndIdle = true;
323
- }
324
- else if (prevHueThumbState === "hover" && !hoveringThumb) {
325
- this.hueThumbState = "idle";
326
- transitionedBetweenHoverAndIdle = true;
327
- }
328
- if (this.hueThumbState !== "drag") {
329
- if (transitionedBetweenHoverAndIdle) {
330
- // refresh since we won't update color and thus no redraw
331
- this.drawColorFieldAndSlider();
332
- }
333
- }
334
- }
335
- else if (region === "slider") {
336
- const sliderThumbColor = this.baseColorFieldColor.hsv().saturationv(100).value(100);
337
- const prevSliderThumbState = this.sliderThumbState;
338
- const sliderThumbCenterX = Math.round(sliderThumbColor.hue() / (360 / slider.width));
339
- const sliderThumbCenterY = Math.round((slider.height + this.getSliderCapSpacing()) / 2) + colorField.height;
340
- const hoveringSliderThumb = this.containsPoint(offsetX, offsetY, sliderThumbCenterX, sliderThumbCenterY, thumb.radius);
341
- let sliderThumbTransitionedBetweenHoverAndIdle = false;
342
- if (prevSliderThumbState === "idle" && hoveringSliderThumb) {
343
- this.sliderThumbState = "hover";
344
- sliderThumbTransitionedBetweenHoverAndIdle = true;
345
- }
346
- else if (prevSliderThumbState === "hover" && !hoveringSliderThumb) {
347
- this.sliderThumbState = "idle";
348
- sliderThumbTransitionedBetweenHoverAndIdle = true;
349
- }
350
- if (this.sliderThumbState !== "drag") {
351
- if (sliderThumbTransitionedBetweenHoverAndIdle) {
352
- // refresh since we won't update color and thus no redraw
353
- this.drawColorFieldAndSlider();
354
- }
355
- }
234
+ else if (context === this.opacitySliderRenderingContext) {
235
+ this.captureOpacitySliderValue(samplingX);
356
236
  }
357
237
  };
358
238
  this.storeColorFieldScope = (node) => {
@@ -368,23 +248,35 @@ const ColorPicker = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
368
248
  return (h("calcite-tab-title", { class: CSS.colorMode, "data-color-mode": channelMode, key: channelMode, onCalciteTabsActivate: this.handleTabActivate, selected: selected }, label));
369
249
  };
370
250
  this.renderChannelsTab = (channelMode) => {
371
- const { channelMode: activeChannelMode, channels, messages } = this;
251
+ const { allowEmpty, channelMode: activeChannelMode, channels, messages, alphaChannel } = this;
372
252
  const selected = channelMode === activeChannelMode;
373
253
  const isRgb = channelMode === "rgb";
374
- const channelLabels = isRgb
375
- ? [messages.r, messages.g, messages.b]
376
- : [messages.h, messages.s, messages.v];
377
254
  const channelAriaLabels = isRgb
378
255
  ? [messages.red, messages.green, messages.blue]
379
256
  : [messages.hue, messages.saturation, messages.value];
380
257
  const direction = getElementDir(this.el);
381
- return (h("calcite-tab", { class: CSS.control, key: channelMode, selected: selected }, h("div", { class: CSS.channels, dir: "ltr" }, channels.map((channel, index) =>
382
- /* the channel container is ltr, so we apply the host's direction */
383
- this.renderChannel(channel, index, channelLabels[index], channelAriaLabels[index], direction)))));
258
+ const channelsToRender = alphaChannel ? channels : channels.slice(0, 3);
259
+ return (h("calcite-tab", { class: CSS.control, key: channelMode, selected: selected }, h("div", { class: CSS.channels, dir: "ltr" }, channelsToRender.map((channelValue, index) => {
260
+ const isAlphaChannel = index === 3;
261
+ if (isAlphaChannel) {
262
+ channelValue =
263
+ allowEmpty && !channelValue ? channelValue : alphaToOpacity(channelValue);
264
+ }
265
+ /* the channel container is ltr, so we apply the host's direction */
266
+ return this.renderChannel(channelValue, index, channelAriaLabels[index], direction, isAlphaChannel ? "%" : "");
267
+ }))));
268
+ };
269
+ this.renderChannel = (value, index, ariaLabel, direction, suffix) => {
270
+ return (h("calcite-input", { class: CSS.channel, "data-channel-index": index, dir: direction, key: index, label: ariaLabel, lang: this.effectiveLocale, numberButtonType: "none", numberingSystem: this.numberingSystem, onCalciteInputChange: this.handleChannelChange, onCalciteInputInput: this.handleChannelInput, onKeyDown: this.handleKeyDown, scale: this.scale === "l" ? "m" : "s",
271
+ // workaround to ensure input borders overlap as desired
272
+ // this is because the build transforms margin-left to its
273
+ // logical-prop, which is undesired as channels are always ltr
274
+ style: {
275
+ marginLeft: index > 0 && !(this.scale === "s" && this.alphaChannel && index === 3) ? "-1px" : ""
276
+ }, suffixText: suffix, type: "number", value: value?.toString() }));
384
277
  };
385
- this.renderChannel = (value, index, label, ariaLabel, direction) => (h("calcite-input", { class: CSS.channel, "data-channel-index": index, dir: direction, label: ariaLabel, lang: this.effectiveLocale, numberButtonType: "none", numberingSystem: this.numberingSystem, onCalciteInputChange: this.handleChannelChange, onCalciteInputInput: this.handleChannelInput, onKeyDown: this.handleKeyDown, prefixText: label, scale: this.scale === "l" ? "m" : "s", type: "number", value: value?.toString() }));
386
278
  this.deleteColor = () => {
387
- const colorToDelete = this.color.hex();
279
+ const colorToDelete = hexify(this.color, this.alphaChannel);
388
280
  const inStorage = this.savedColors.indexOf(colorToDelete) > -1;
389
281
  if (!inStorage) {
390
282
  return;
@@ -397,7 +289,7 @@ const ColorPicker = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
397
289
  }
398
290
  };
399
291
  this.saveColor = () => {
400
- const colorToSave = this.color.hex();
292
+ const colorToSave = hexify(this.color, this.alphaChannel);
401
293
  const alreadySaved = this.savedColors.indexOf(colorToSave) > -1;
402
294
  if (alreadySaved) {
403
295
  return;
@@ -409,12 +301,18 @@ const ColorPicker = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
409
301
  localStorage.setItem(storageKey, JSON.stringify(savedColors));
410
302
  }
411
303
  };
412
- this.drawColorFieldAndSlider = throttle(() => {
413
- if (!this.fieldAndSliderRenderingContext) {
414
- return;
304
+ this.drawColorControls = throttle((type = "all") => {
305
+ if ((type === "all" || type === "color-field") && this.colorFieldRenderingContext) {
306
+ this.drawColorField();
307
+ }
308
+ if ((type === "all" || type === "hue-slider") && this.hueSliderRenderingContext) {
309
+ this.drawHueSlider();
310
+ }
311
+ if (this.alphaChannel &&
312
+ (type === "all" || type === "opacity-slider") &&
313
+ this.opacitySliderRenderingContext) {
314
+ this.drawOpacitySlider();
415
315
  }
416
- this.drawColorField();
417
- this.drawHueSlider();
418
316
  }, throttleFor60FpsInMs);
419
317
  this.captureColorFieldColor = (x, y, skipEqual = true) => {
420
318
  const { dimensions: { colorField: { height, width } } } = this;
@@ -422,24 +320,56 @@ const ColorPicker = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
422
320
  const value = Math.round((HSV_LIMITS.v / height) * (height - y));
423
321
  this.internalColorSet(this.baseColorFieldColor.hsv().saturationv(saturation).value(value), skipEqual);
424
322
  };
425
- this.initColorFieldAndSlider = (canvas) => {
426
- this.fieldAndSliderRenderingContext = canvas.getContext("2d");
427
- this.updateCanvasSize(canvas);
323
+ this.initColorField = (canvas) => {
324
+ this.colorFieldRenderingContext = canvas.getContext("2d");
325
+ this.updateCanvasSize("color-field");
326
+ this.drawColorControls();
327
+ };
328
+ this.initHueSlider = (canvas) => {
329
+ this.hueSliderRenderingContext = canvas.getContext("2d");
330
+ this.updateCanvasSize("hue-slider");
331
+ this.drawHueSlider();
332
+ };
333
+ this.initOpacitySlider = (canvas) => {
334
+ this.opacitySliderRenderingContext = canvas.getContext("2d");
335
+ this.updateCanvasSize("opacity-slider");
336
+ this.drawOpacitySlider();
337
+ };
338
+ this.storeOpacityScope = (node) => {
339
+ this.opacityScopeNode = node;
340
+ };
341
+ this.handleOpacityScopeKeyDown = (event) => {
342
+ const modifier = event.shiftKey ? 10 : 1;
343
+ const { key } = event;
344
+ const arrowKeyToXOffset = {
345
+ ArrowUp: 1,
346
+ ArrowRight: 1,
347
+ ArrowDown: -1,
348
+ ArrowLeft: -1
349
+ };
350
+ if (arrowKeyToXOffset[key]) {
351
+ event.preventDefault();
352
+ const delta = opacityToAlpha(arrowKeyToXOffset[key] * modifier);
353
+ this.captureHueSliderColor(this.opacityScopeLeft + delta);
354
+ }
428
355
  };
429
356
  this.allowEmpty = false;
357
+ this.alphaChannel = false;
358
+ this.channelsDisabled = false;
430
359
  this.color = DEFAULT_COLOR;
431
360
  this.disabled = false;
432
- this.format = defaultFormat;
433
- this.hideHex = false;
361
+ this.format = "auto";
434
362
  this.hideChannels = false;
363
+ this.hexDisabled = false;
364
+ this.hideHex = false;
435
365
  this.hideSaved = false;
366
+ this.savedDisabled = false;
436
367
  this.scale = "m";
437
368
  this.storageId = undefined;
438
369
  this.messageOverrides = undefined;
439
370
  this.numberingSystem = undefined;
440
- this.value = defaultValue;
371
+ this.value = normalizeHex(hexify(DEFAULT_COLOR, this.alphaChannel));
441
372
  this.defaultMessages = undefined;
442
- this.colorFieldAndSliderInteractive = false;
443
373
  this.channelMode = "rgb";
444
374
  this.channels = this.toChannels(DEFAULT_COLOR);
445
375
  this.dimensions = DIMENSIONS.m;
@@ -448,12 +378,19 @@ const ColorPicker = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
448
378
  this.savedColors = [];
449
379
  this.colorFieldScopeTop = undefined;
450
380
  this.colorFieldScopeLeft = undefined;
451
- this.scopeOrientation = undefined;
452
381
  this.hueScopeLeft = undefined;
453
- this.hueScopeTop = undefined;
382
+ this.opacityScopeLeft = undefined;
383
+ this.scopeOrientation = undefined;
384
+ }
385
+ handleAlphaChannelChange(alphaChannel) {
386
+ const { format } = this;
387
+ if (alphaChannel && format !== "auto" && !alphaCompatible(format)) {
388
+ console.warn(`ignoring alphaChannel as the current format (${format}) does not support alpha`);
389
+ this.alphaChannel = false;
390
+ }
454
391
  }
455
392
  handleColorChange(color, oldColor) {
456
- this.drawColorFieldAndSlider();
393
+ this.drawColorControls();
457
394
  this.updateChannelsFromColor(color);
458
395
  this.previousColor = oldColor;
459
396
  }
@@ -463,7 +400,8 @@ const ColorPicker = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
463
400
  }
464
401
  handleScaleChange(scale = "m") {
465
402
  this.updateDimensions(scale);
466
- this.updateCanvasSize(this.fieldAndSliderRenderingContext?.canvas);
403
+ this.updateCanvasSize("all");
404
+ this.drawColorControls();
467
405
  }
468
406
  onMessagesChange() {
469
407
  /* wired up by t9n util */
@@ -480,9 +418,9 @@ const ColorPicker = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
480
418
  return;
481
419
  }
482
420
  modeChanged = this.mode !== nextMode;
483
- this.setMode(nextMode);
421
+ this.setMode(nextMode, this.internalColorUpdateContext === null);
484
422
  }
485
- const dragging = this.sliderThumbState === "drag" || this.hueThumbState === "drag";
423
+ const dragging = this.activeCanvasInfo;
486
424
  if (this.internalColorUpdateContext === "initial") {
487
425
  return;
488
426
  }
@@ -493,17 +431,16 @@ const ColorPicker = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
493
431
  }
494
432
  return;
495
433
  }
496
- const color$1 = allowEmpty && !value ? null : color(value);
434
+ const color$1 = allowEmpty && !value
435
+ ? null
436
+ : color(value != null && typeof value === "object" && alphaCompatible(this.mode)
437
+ ? normalizeColor(value)
438
+ : value);
497
439
  const colorChanged = !colorEqual(color$1, this.color);
498
440
  if (modeChanged || colorChanged) {
499
- this.internalColorSet(color$1, true, "internal");
441
+ this.internalColorSet(color$1, this.alphaChannel && !(this.mode.endsWith("a") || this.mode.endsWith("a-css")), "internal");
500
442
  }
501
443
  }
502
- //--------------------------------------------------------------------------
503
- //
504
- // Internal State/Props
505
- //
506
- //--------------------------------------------------------------------------
507
444
  get baseColorFieldColor() {
508
445
  return this.color || this.previousColor || DEFAULT_COLOR;
509
446
  }
@@ -559,7 +496,7 @@ const ColorPicker = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
559
496
  if (!valueIsCompatible) {
560
497
  this.showIncompatibleColorWarning(value, format);
561
498
  }
562
- this.setMode(format);
499
+ this.setMode(format, false);
563
500
  this.internalColorSet(initialColor, false, "initial");
564
501
  this.updateDimensions(this.scale);
565
502
  const storageKey = `${DEFAULT_STORAGE_KEY_PREFIX}${this.storageId}`;
@@ -590,34 +527,38 @@ const ColorPicker = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
590
527
  //
591
528
  //--------------------------------------------------------------------------
592
529
  render() {
593
- const { allowEmpty, color, messages, hideHex, hideChannels, hideSaved, savedColors, scale } = this;
594
- const selectedColorInHex = color ? color.hex() : null;
595
- const hexInputScale = scale === "l" ? "m" : "s";
596
- const { colorFieldAndSliderInteractive, colorFieldScopeTop, colorFieldScopeLeft, hueScopeLeft, hueScopeTop, scopeOrientation, dimensions: { colorField: { height: colorFieldHeight, width: colorFieldWidth }, slider: { height: sliderHeight } } } = this;
597
- const hueTop = hueScopeTop ?? sliderHeight / 2 + colorFieldHeight;
598
- const hueLeft = hueScopeLeft ?? (colorFieldWidth * DEFAULT_COLOR.hue()) / HSV_LIMITS.h;
530
+ const { allowEmpty, channelsDisabled, color, colorFieldScopeLeft, colorFieldScopeTop, dimensions: { colorField: { width: colorFieldWidth }, slider: { width: sliderWidth }, thumb: { radius: thumbRadius } }, hexDisabled, hideChannels, hideHex, hideSaved, hueScopeLeft, messages, alphaChannel, opacityScopeLeft, savedColors, savedDisabled, scale, scopeOrientation } = this;
531
+ const selectedColorInHex = color ? hexify(color, alphaChannel) : null;
532
+ const hueTop = thumbRadius;
533
+ const hueLeft = hueScopeLeft ?? (sliderWidth * DEFAULT_COLOR.hue()) / HSV_LIMITS.h;
534
+ const opacityTop = thumbRadius;
535
+ const opacityLeft = opacityScopeLeft ??
536
+ (colorFieldWidth * alphaToOpacity(DEFAULT_COLOR.alpha())) / OPACITY_LIMITS.max;
599
537
  const noColor = color === null;
600
538
  const vertical = scopeOrientation === "vertical";
601
- return (h("div", { class: CSS.container }, h("div", { class: CSS.colorFieldAndSliderWrap }, h("canvas", { class: {
602
- [CSS.colorFieldAndSlider]: true,
603
- [CSS.colorFieldAndSliderInteractive]: colorFieldAndSliderInteractive
604
- }, onPointerDown: this.handleColorFieldAndSliderPointerDown, onPointerEnter: this.handleColorFieldAndSliderPointerEnterOrMove, onPointerLeave: this.handleColorFieldAndSliderPointerLeave, onPointerMove: this.handleColorFieldAndSliderPointerEnterOrMove,
539
+ const noHex = hexDisabled || hideHex;
540
+ const noChannels = channelsDisabled || hideChannels;
541
+ const noSaved = savedDisabled || hideSaved;
542
+ return (h("div", { class: CSS.container }, h("div", { class: CSS.controlAndScope }, h("canvas", { class: CSS.colorField, onPointerDown: this.handleColorFieldPointerDown,
543
+ // eslint-disable-next-line react/jsx-sort-props
544
+ ref: this.initColorField }), h("div", { "aria-label": vertical ? messages.value : messages.saturation, "aria-valuemax": vertical ? HSV_LIMITS.v : HSV_LIMITS.s, "aria-valuemin": "0", "aria-valuenow": (vertical ? color?.saturationv() : color?.value()) || "0", class: { [CSS.scope]: true, [CSS.colorFieldScope]: true }, onKeyDown: this.handleColorFieldScopeKeyDown, role: "slider", style: { top: `${colorFieldScopeTop || 0}px`, left: `${colorFieldScopeLeft || 0}px` }, tabindex: "0",
545
+ // eslint-disable-next-line react/jsx-sort-props
546
+ ref: this.storeColorFieldScope })), h("div", { class: CSS.previewAndSliders }, h("calcite-color-picker-swatch", { class: CSS.preview, color: selectedColorInHex, scale: "l" }), h("div", { class: CSS.sliders }, h("div", { class: CSS.controlAndScope }, h("canvas", { class: { [CSS.slider]: true, [CSS.hueSlider]: true }, onPointerDown: this.handleHueSliderPointerDown,
547
+ // eslint-disable-next-line react/jsx-sort-props
548
+ ref: this.initHueSlider }), h("div", { "aria-label": messages.hue, "aria-valuemax": HSV_LIMITS.h, "aria-valuemin": "0", "aria-valuenow": color?.round().hue() || DEFAULT_COLOR.round().hue(), class: { [CSS.scope]: true, [CSS.hueScope]: true }, onKeyDown: this.handleHueScopeKeyDown, role: "slider", style: { top: `${hueTop}px`, left: `${hueLeft}px` }, tabindex: "0",
605
549
  // eslint-disable-next-line react/jsx-sort-props
606
- ref: this.initColorFieldAndSlider }), h("div", { "aria-label": vertical ? messages.value : messages.saturation, "aria-valuemax": vertical ? HSV_LIMITS.v : HSV_LIMITS.s, "aria-valuemin": "0", "aria-valuenow": (vertical ? color?.saturationv() : color?.value()) || "0", class: { [CSS.scope]: true, [CSS.colorFieldScope]: true }, onKeyDown: this.handleColorFieldScopeKeyDown, role: "slider", style: { top: `${colorFieldScopeTop || 0}px`, left: `${colorFieldScopeLeft || 0}px` }, tabindex: "0",
550
+ ref: this.storeHueScope })), alphaChannel ? (h("div", { class: CSS.controlAndScope }, h("canvas", { class: { [CSS.slider]: true, [CSS.opacitySlider]: true }, onPointerDown: this.handleOpacitySliderPointerDown,
607
551
  // eslint-disable-next-line react/jsx-sort-props
608
- ref: this.storeColorFieldScope }), h("div", { "aria-label": messages.hue, "aria-valuemax": HSV_LIMITS.h, "aria-valuemin": "0", "aria-valuenow": color?.round().hue() || DEFAULT_COLOR.round().hue(), class: { [CSS.scope]: true, [CSS.hueScope]: true }, onKeyDown: this.handleHueScopeKeyDown, role: "slider", style: { top: `${hueTop}px`, left: `${hueLeft}px` }, tabindex: "0",
552
+ ref: this.initOpacitySlider }), h("div", { "aria-label": messages.opacity, "aria-valuemax": OPACITY_LIMITS.max, "aria-valuemin": OPACITY_LIMITS.min, "aria-valuenow": (color || DEFAULT_COLOR).round().alpha(), class: { [CSS.scope]: true, [CSS.opacityScope]: true }, onKeyDown: this.handleOpacityScopeKeyDown, role: "slider", style: { top: `${opacityTop}px`, left: `${opacityLeft}px` }, tabindex: "0",
609
553
  // eslint-disable-next-line react/jsx-sort-props
610
- ref: this.storeHueScope })), hideHex && hideChannels ? null : (h("div", { class: {
554
+ ref: this.storeOpacityScope }))) : null)), noHex && noChannels ? null : (h("div", { class: {
611
555
  [CSS.controlSection]: true,
612
556
  [CSS.section]: true
613
- } }, hideHex ? null : (h("div", { class: CSS.hexOptions }, h("span", { class: {
614
- [CSS.header]: true,
615
- [CSS.headerHex]: true
616
- } }, messages.hex), h("calcite-color-picker-hex-input", { allowEmpty: allowEmpty, class: CSS.control, hexLabel: messages.hex, numberingSystem: this.numberingSystem, onCalciteColorPickerHexInputChange: this.handleHexInputChange, scale: hexInputScale, value: selectedColorInHex }))), hideChannels ? null : (h("calcite-tabs", { class: {
557
+ } }, h("div", { class: CSS.hexAndChannelsGroup }, noHex ? null : (h("div", { class: CSS.hexOptions }, h("calcite-color-picker-hex-input", { allowEmpty: allowEmpty, alphaChannel: alphaChannel, class: CSS.control, messages: messages, numberingSystem: this.numberingSystem, onCalciteColorPickerHexInputChange: this.handleHexInputChange, scale: scale, value: selectedColorInHex }))), noChannels ? null : (h("calcite-tabs", { class: {
617
558
  [CSS.colorModeContainer]: true,
618
559
  [CSS.splitSection]: true
619
- }, scale: hexInputScale }, h("calcite-tab-nav", { slot: "title-group" }, this.renderChannelsTabTitle("rgb"), this.renderChannelsTabTitle("hsv")), this.renderChannelsTab("rgb"), this.renderChannelsTab("hsv"))))), hideSaved ? null : (h("div", { class: { [CSS.savedColorsSection]: true, [CSS.section]: true } }, h("div", { class: CSS.header }, h("label", null, messages.saved), h("div", { class: CSS.savedColorsButtons }, h("calcite-button", { appearance: "transparent", class: CSS.deleteColor, disabled: noColor, iconStart: "minus", kind: "neutral", label: messages.deleteColor, onClick: this.deleteColor, scale: hexInputScale, type: "button" }), h("calcite-button", { appearance: "transparent", class: CSS.saveColor, disabled: noColor, iconStart: "plus", kind: "neutral", label: messages.saveColor, onClick: this.saveColor, scale: hexInputScale, type: "button" }))), savedColors.length > 0 ? (h("div", { class: CSS.savedColors }, [
620
- ...savedColors.map((color) => (h("calcite-color-picker-swatch", { active: selectedColorInHex === color, class: CSS.savedColor, color: color, key: color, onClick: this.handleSavedColorSelect, onKeyDown: this.handleSavedColorKeyDown, scale: scale, tabIndex: 0 })))
560
+ }, scale: scale === "l" ? "m" : "s" }, h("calcite-tab-nav", { slot: "title-group" }, this.renderChannelsTabTitle("rgb"), this.renderChannelsTabTitle("hsv")), this.renderChannelsTab("rgb"), this.renderChannelsTab("hsv")))))), noSaved ? null : (h("div", { class: { [CSS.savedColorsSection]: true, [CSS.section]: true } }, h("div", { class: CSS.header }, h("label", null, messages.saved), h("div", { class: CSS.savedColorsButtons }, h("calcite-button", { appearance: "transparent", class: CSS.deleteColor, disabled: noColor, iconStart: "minus", kind: "neutral", label: messages.deleteColor, onClick: this.deleteColor, scale: scale, type: "button" }), h("calcite-button", { appearance: "transparent", class: CSS.saveColor, disabled: noColor, iconStart: "plus", kind: "neutral", label: messages.saveColor, onClick: this.saveColor, scale: scale, type: "button" }))), savedColors.length > 0 ? (h("div", { class: CSS.savedColors }, [
561
+ ...savedColors.map((color) => (h("calcite-color-picker-swatch", { class: CSS.savedColor, color: color, key: color, onClick: this.handleSavedColorSelect, onKeyDown: this.handleSavedColorKeyDown, scale: scale, tabIndex: 0 })))
621
562
  ])) : null))));
622
563
  }
623
564
  // --------------------------------------------------------------------------
@@ -633,23 +574,38 @@ const ColorPicker = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
633
574
  showIncompatibleColorWarning(value, format) {
634
575
  console.warn(`ignoring color value (${value}) as it is not compatible with the current format (${format})`);
635
576
  }
636
- setMode(format) {
637
- this.mode = format === "auto" ? this.mode : format;
577
+ setMode(format, warn = true) {
578
+ const mode = format === "auto" ? this.mode : format;
579
+ this.mode = this.ensureCompatibleMode(mode, warn);
580
+ }
581
+ ensureCompatibleMode(mode, warn) {
582
+ const { alphaChannel } = this;
583
+ const isAlphaCompatible = alphaCompatible(mode);
584
+ if (alphaChannel && !isAlphaCompatible) {
585
+ const alphaMode = toAlphaMode(mode);
586
+ if (warn) {
587
+ console.warn(`setting format to (${alphaMode}) as the provided one (${mode}) does not support alpha`);
588
+ }
589
+ return alphaMode;
590
+ }
591
+ if (!alphaChannel && isAlphaCompatible) {
592
+ const nonAlphaMode = toNonAlphaMode(mode);
593
+ if (warn) {
594
+ console.warn(`setting format to (${nonAlphaMode}) as the provided one (${mode}) does not support alpha`);
595
+ }
596
+ return nonAlphaMode;
597
+ }
598
+ return mode;
638
599
  }
639
600
  captureHueSliderColor(x) {
640
601
  const { dimensions: { slider: { width } } } = this;
641
602
  const hue = (360 / width) * x;
642
603
  this.internalColorSet(this.baseColorFieldColor.hue(hue), false);
643
604
  }
644
- getCanvasRegion(y) {
645
- const { dimensions: { colorField: { height: colorFieldHeight }, slider: { height: sliderHeight } } } = this;
646
- if (y <= colorFieldHeight) {
647
- return "color-field";
648
- }
649
- if (y <= colorFieldHeight + sliderHeight) {
650
- return "slider";
651
- }
652
- return "none";
605
+ captureOpacitySliderValue(x) {
606
+ const { dimensions: { slider: { width } } } = this;
607
+ const alpha = opacityToAlpha((OPACITY_LIMITS.max / width) * x);
608
+ this.internalColorSet(this.baseColorFieldColor.alpha(alpha), false);
653
609
  }
654
610
  internalColorSet(color, skipEqual = true, context = "user-interaction") {
655
611
  if (skipEqual && colorEqual(color, this.color)) {
@@ -666,16 +622,25 @@ const ColorPicker = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
666
622
  }
667
623
  const hexMode = "hex";
668
624
  if (format.includes(hexMode)) {
669
- return normalizeHex(color.round()[hexMode]());
625
+ const hasAlpha = format === CSSColorMode.HEXA;
626
+ return normalizeHex(hexify(color.round(), hasAlpha), hasAlpha);
670
627
  }
671
628
  if (format.includes("-css")) {
672
- return color[format.replace("-css", "").replace("a", "")]().round().string();
629
+ const value = color[format.replace("-css", "").replace("a", "")]().round().string();
630
+ // Color omits alpha values when alpha is 1
631
+ const needToInjectAlpha = (format.endsWith("a") || format.endsWith("a-css")) && color.alpha() === 1;
632
+ if (needToInjectAlpha) {
633
+ const model = value.slice(0, 3);
634
+ const values = value.slice(4, -1);
635
+ return `${model}a(${values}, ${color.alpha()})`;
636
+ }
637
+ return value;
673
638
  }
674
- const colorObject = color[format]().round().object();
639
+ const colorObject =
640
+ /* Color() does not support hsva, hsla nor rgba, so we use the non-alpha mode */
641
+ color[toNonAlphaMode(format)]().round().object();
675
642
  if (format.endsWith("a")) {
676
- // normalize alpha prop
677
- colorObject.a = colorObject.alpha;
678
- delete colorObject.alpha;
643
+ return normalizeAlpha(colorObject);
679
644
  }
680
645
  return colorObject;
681
646
  }
@@ -687,9 +652,14 @@ const ColorPicker = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
687
652
  this.dimensions = DIMENSIONS[scale];
688
653
  }
689
654
  drawColorField() {
690
- const context = this.fieldAndSliderRenderingContext;
655
+ const context = this.colorFieldRenderingContext;
691
656
  const { dimensions: { colorField: { height, width } } } = this;
692
- context.fillStyle = this.baseColorFieldColor.hsv().saturationv(100).value(100).string();
657
+ context.fillStyle = this.baseColorFieldColor
658
+ .hsv()
659
+ .saturationv(100)
660
+ .value(100)
661
+ .alpha(1)
662
+ .string();
693
663
  context.fillRect(0, 0, width, height);
694
664
  const whiteGradient = context.createLinearGradient(0, 0, width, 0);
695
665
  whiteGradient.addColorStop(0, "rgba(255,255,255,1)");
@@ -704,6 +674,9 @@ const ColorPicker = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
704
674
  this.drawActiveColorFieldColor();
705
675
  }
706
676
  setCanvasContextSize(canvas, { height, width }) {
677
+ if (!canvas) {
678
+ return;
679
+ }
707
680
  const devicePixelRatio = window.devicePixelRatio || 1;
708
681
  canvas.width = width * devicePixelRatio;
709
682
  canvas.height = height * devicePixelRatio;
@@ -712,21 +685,21 @@ const ColorPicker = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
712
685
  const context = canvas.getContext("2d");
713
686
  context.scale(devicePixelRatio, devicePixelRatio);
714
687
  }
715
- updateCanvasSize(canvas) {
716
- if (!canvas) {
717
- return;
688
+ updateCanvasSize(context = "all") {
689
+ const { dimensions } = this;
690
+ if (context === "all" || context === "color-field") {
691
+ this.setCanvasContextSize(this.colorFieldRenderingContext?.canvas, dimensions.colorField);
692
+ }
693
+ const adjustedSliderDimensions = {
694
+ width: dimensions.slider.width,
695
+ height: dimensions.slider.height + (dimensions.thumb.radius - dimensions.slider.height / 2) * 2
696
+ };
697
+ if (context === "all" || context === "hue-slider") {
698
+ this.setCanvasContextSize(this.hueSliderRenderingContext?.canvas, adjustedSliderDimensions);
699
+ }
700
+ if (context === "all" || context === "opacity-slider") {
701
+ this.setCanvasContextSize(this.opacitySliderRenderingContext?.canvas, adjustedSliderDimensions);
718
702
  }
719
- this.setCanvasContextSize(canvas, {
720
- width: this.dimensions.colorField.width,
721
- height: this.dimensions.colorField.height +
722
- this.dimensions.slider.height +
723
- this.getSliderCapSpacing() * 2
724
- });
725
- this.drawColorFieldAndSlider();
726
- }
727
- containsPoint(testPointX, testPointY, boundsX, boundsY, boundsRadius) {
728
- return (Math.pow(testPointX - boundsX, 2) + Math.pow(testPointY - boundsY, 2) <=
729
- Math.pow(boundsRadius, 2));
730
703
  }
731
704
  drawActiveColorFieldColor() {
732
705
  const { color } = this;
@@ -741,22 +714,23 @@ const ColorPicker = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
741
714
  this.colorFieldScopeLeft = x;
742
715
  this.colorFieldScopeTop = y;
743
716
  });
744
- this.drawThumb(this.fieldAndSliderRenderingContext, radius, x, y, hsvColor, this.hueThumbState);
717
+ this.drawThumb(this.colorFieldRenderingContext, radius, x, y, hsvColor);
745
718
  }
746
- drawThumb(context, radius, x, y, color, state) {
719
+ drawThumb(context, radius, x, y, color) {
747
720
  const startAngle = 0;
748
721
  const endAngle = 2 * Math.PI;
722
+ const outlineWidth = 1;
723
+ radius = radius - outlineWidth;
749
724
  context.beginPath();
750
725
  context.arc(x, y, radius, startAngle, endAngle);
751
- context.shadowBlur = state === "hover" ? 32 : 16;
752
- context.shadowColor = `rgba(0, 0, 0, ${state === "drag" ? 0.32 : 0.16})`;
753
726
  context.fillStyle = "#fff";
754
727
  context.fill();
728
+ context.strokeStyle = "rgba(0,0,0,0.3)";
729
+ context.lineWidth = outlineWidth;
730
+ context.stroke();
755
731
  context.beginPath();
756
732
  context.arc(x, y, radius - 3, startAngle, endAngle);
757
- context.shadowBlur = 0;
758
- context.shadowColor = "transparent";
759
- context.fillStyle = color.rgb().string();
733
+ context.fillStyle = color.rgb().alpha(1).string();
760
734
  context.fill();
761
735
  }
762
736
  drawActiveHueSliderColor() {
@@ -765,18 +739,19 @@ const ColorPicker = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
765
739
  return;
766
740
  }
767
741
  const hsvColor = color.hsv().saturationv(100).value(100);
768
- const { dimensions: { colorField: { height: colorFieldHeight }, slider: { height, width }, thumb: { radius } } } = this;
742
+ const { dimensions: { slider: { height, width }, thumb: { radius } } } = this;
769
743
  const x = hsvColor.hue() / (360 / width);
770
- const y = height / 2 + colorFieldHeight;
744
+ const y = radius - height / 2 + height / 2;
771
745
  requestAnimationFrame(() => {
772
746
  this.hueScopeLeft = x;
773
- this.hueScopeTop = y;
774
747
  });
775
- this.drawThumb(this.fieldAndSliderRenderingContext, radius, x, y, hsvColor, this.sliderThumbState);
748
+ this.drawThumb(this.hueSliderRenderingContext, radius, x, y, hsvColor);
776
749
  }
777
750
  drawHueSlider() {
778
- const context = this.fieldAndSliderRenderingContext;
779
- const { dimensions: { colorField: { height: colorFieldHeight }, slider: { height, width } } } = this;
751
+ const context = this.hueSliderRenderingContext;
752
+ const { dimensions: { slider: { height, width }, thumb: { radius: thumbRadius } } } = this;
753
+ const x = 0;
754
+ const y = thumbRadius - height / 2;
780
755
  const gradient = context.createLinearGradient(0, 0, width, 0);
781
756
  const hueSliderColorStopKeywords = ["red", "yellow", "lime", "cyan", "blue", "magenta", "red"];
782
757
  const offset = 1 / (hueSliderColorStopKeywords.length - 1);
@@ -785,27 +760,107 @@ const ColorPicker = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
785
760
  gradient.addColorStop(currentOffset, color(keyword).string());
786
761
  currentOffset += offset;
787
762
  });
763
+ context.clearRect(0, 0, width, height + this.getSliderCapSpacing() * 2);
764
+ this.drawSliderPath(context, height, width, x, y);
788
765
  context.fillStyle = gradient;
789
- context.clearRect(0, colorFieldHeight, width, height + this.getSliderCapSpacing() * 2);
790
- context.fillRect(0, colorFieldHeight, width, height);
766
+ context.fill();
767
+ context.strokeStyle = "rgba(0,0,0,0.3)";
768
+ context.lineWidth = 1;
769
+ context.stroke();
791
770
  this.drawActiveHueSliderColor();
792
771
  }
772
+ drawOpacitySlider() {
773
+ const context = this.opacitySliderRenderingContext;
774
+ const { baseColorFieldColor: previousColor, dimensions: { slider: { height, width }, thumb: { radius: thumbRadius } } } = this;
775
+ const x = 0;
776
+ const y = thumbRadius - height / 2;
777
+ context.clearRect(0, 0, width, height + this.getSliderCapSpacing() * 2);
778
+ const gradient = context.createLinearGradient(0, y, width, 0);
779
+ const startColor = previousColor.rgb().alpha(0);
780
+ const midColor = previousColor.rgb().alpha(0.5);
781
+ const endColor = previousColor.rgb().alpha(1);
782
+ gradient.addColorStop(0, startColor.string());
783
+ gradient.addColorStop(0.5, midColor.string());
784
+ gradient.addColorStop(1, endColor.string());
785
+ this.drawSliderPath(context, height, width, x, y);
786
+ const pattern = context.createPattern(this.getCheckeredBackgroundPattern(), "repeat");
787
+ context.fillStyle = pattern;
788
+ context.fill();
789
+ context.fillStyle = gradient;
790
+ context.fill();
791
+ context.strokeStyle = "rgba(0,0,0,0.3)";
792
+ context.lineWidth = 1;
793
+ context.stroke();
794
+ this.drawActiveOpacitySliderColor();
795
+ }
796
+ drawSliderPath(context, height, width, x, y) {
797
+ const radius = height / 2 + 1;
798
+ context.beginPath();
799
+ context.moveTo(x + radius, y);
800
+ context.lineTo(x + width - radius, y);
801
+ context.quadraticCurveTo(x + width, y, x + width, y + radius);
802
+ context.lineTo(x + width, y + height - radius);
803
+ context.quadraticCurveTo(x + width, y + height, x + width - radius, y + height);
804
+ context.lineTo(x + radius, y + height);
805
+ context.quadraticCurveTo(x, y + height, x, y + height - radius);
806
+ context.lineTo(x, y + radius);
807
+ context.quadraticCurveTo(x, y, x + radius, y);
808
+ context.closePath();
809
+ }
810
+ getCheckeredBackgroundPattern() {
811
+ if (this.checkerPattern) {
812
+ return this.checkerPattern;
813
+ }
814
+ const pattern = document.createElement("canvas");
815
+ pattern.width = 10;
816
+ pattern.height = 10;
817
+ const patternContext = pattern.getContext("2d");
818
+ patternContext.fillStyle = "#ccc";
819
+ patternContext.fillRect(0, 0, 10, 10);
820
+ patternContext.fillStyle = "#fff";
821
+ patternContext.fillRect(0, 0, 5, 5);
822
+ patternContext.fillRect(5, 5, 5, 5);
823
+ this.checkerPattern = pattern;
824
+ return pattern;
825
+ }
826
+ drawActiveOpacitySliderColor() {
827
+ const { color } = this;
828
+ if (!color) {
829
+ return;
830
+ }
831
+ const hsvColor = color;
832
+ const { dimensions: { slider: { width }, thumb: { radius } } } = this;
833
+ const x = alphaToOpacity(hsvColor.alpha()) / (OPACITY_LIMITS.max / width);
834
+ const y = radius;
835
+ requestAnimationFrame(() => {
836
+ this.opacityScopeLeft = x;
837
+ });
838
+ this.drawThumb(this.opacitySliderRenderingContext, radius, x, y, hsvColor);
839
+ }
793
840
  updateColorFromChannels(channels) {
794
841
  this.internalColorSet(color(channels, this.channelMode));
795
842
  }
796
843
  updateChannelsFromColor(color) {
797
- this.channels = color ? this.toChannels(color) : [null, null, null];
844
+ this.channels = color ? this.toChannels(color) : [null, null, null, null];
798
845
  }
799
846
  toChannels(color) {
800
847
  const { channelMode } = this;
801
- return color[channelMode]()
848
+ const channels = color[channelMode]()
802
849
  .array()
803
- .map((value) => Math.floor(value));
850
+ .map((value, index) => {
851
+ const isAlpha = index === 3;
852
+ return isAlpha ? value : Math.floor(value);
853
+ });
854
+ if (channels.length === 3) {
855
+ channels.push(1); // Color omits alpha when 1
856
+ }
857
+ return channels;
804
858
  }
805
859
  static get delegatesFocus() { return true; }
806
860
  static get assetsDirs() { return ["assets"]; }
807
861
  get el() { return this; }
808
862
  static get watchers() { return {
863
+ "alphaChannel": ["handleAlphaChannelChange"],
809
864
  "color": ["handleColorChange"],
810
865
  "format": ["handleFormatChange"],
811
866
  "scale": ["handleScaleChange"],
@@ -816,12 +871,16 @@ const ColorPicker = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
816
871
  static get style() { return colorPickerCss; }
817
872
  }, [17, "calcite-color-picker", {
818
873
  "allowEmpty": [516, "allow-empty"],
874
+ "alphaChannel": [4, "alpha-channel"],
875
+ "channelsDisabled": [4, "channels-disabled"],
819
876
  "color": [1040],
820
877
  "disabled": [516],
821
878
  "format": [513],
822
- "hideHex": [516, "hide-hex"],
823
879
  "hideChannels": [516, "hide-channels"],
880
+ "hexDisabled": [4, "hex-disabled"],
881
+ "hideHex": [516, "hide-hex"],
824
882
  "hideSaved": [516, "hide-saved"],
883
+ "savedDisabled": [516, "saved-disabled"],
825
884
  "scale": [513],
826
885
  "storageId": [513, "storage-id"],
827
886
  "messageOverrides": [1040],
@@ -829,7 +888,6 @@ const ColorPicker = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
829
888
  "value": [1025],
830
889
  "messages": [1040],
831
890
  "defaultMessages": [32],
832
- "colorFieldAndSliderInteractive": [32],
833
891
  "channelMode": [32],
834
892
  "channels": [32],
835
893
  "dimensions": [32],
@@ -837,16 +895,16 @@ const ColorPicker = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
837
895
  "savedColors": [32],
838
896
  "colorFieldScopeTop": [32],
839
897
  "colorFieldScopeLeft": [32],
840
- "scopeOrientation": [32],
841
898
  "hueScopeLeft": [32],
842
- "hueScopeTop": [32],
899
+ "opacityScopeLeft": [32],
900
+ "scopeOrientation": [32],
843
901
  "setFocus": [64]
844
902
  }, [[2, "keydown", "handleChannelKeyUpOrDown"], [2, "keyup", "handleChannelKeyUpOrDown"]]]);
845
903
  function defineCustomElement$1() {
846
904
  if (typeof customElements === "undefined") {
847
905
  return;
848
906
  }
849
- const components = ["calcite-color-picker", "calcite-button", "calcite-color-picker-hex-input", "calcite-color-picker-swatch", "calcite-icon", "calcite-input", "calcite-loader", "calcite-progress", "calcite-tab", "calcite-tab-nav", "calcite-tab-title", "calcite-tabs"];
907
+ const components = ["calcite-color-picker", "calcite-button", "calcite-color-picker-hex-input", "calcite-color-picker-swatch", "calcite-icon", "calcite-input", "calcite-input-number", "calcite-loader", "calcite-progress", "calcite-tab", "calcite-tab-nav", "calcite-tab-title", "calcite-tabs"];
850
908
  components.forEach(tagName => { switch (tagName) {
851
909
  case "calcite-color-picker":
852
910
  if (!customElements.get(tagName)) {
@@ -855,25 +913,30 @@ function defineCustomElement$1() {
855
913
  break;
856
914
  case "calcite-button":
857
915
  if (!customElements.get(tagName)) {
858
- defineCustomElement$c();
916
+ defineCustomElement$d();
859
917
  }
860
918
  break;
861
919
  case "calcite-color-picker-hex-input":
862
920
  if (!customElements.get(tagName)) {
863
- defineCustomElement$b();
921
+ defineCustomElement$c();
864
922
  }
865
923
  break;
866
924
  case "calcite-color-picker-swatch":
867
925
  if (!customElements.get(tagName)) {
868
- defineCustomElement$a();
926
+ defineCustomElement$b();
869
927
  }
870
928
  break;
871
929
  case "calcite-icon":
872
930
  if (!customElements.get(tagName)) {
873
- defineCustomElement$9();
931
+ defineCustomElement$a();
874
932
  }
875
933
  break;
876
934
  case "calcite-input":
935
+ if (!customElements.get(tagName)) {
936
+ defineCustomElement$9();
937
+ }
938
+ break;
939
+ case "calcite-input-number":
877
940
  if (!customElements.get(tagName)) {
878
941
  defineCustomElement$8();
879
942
  }