@esri/calcite-components 1.0.0-beta.81 → 1.0.0-beta.82

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 (1037) hide show
  1. package/dist/calcite/assets/icon/compactness16.json +1 -0
  2. package/dist/calcite/assets/icon/compactness24.json +1 -0
  3. package/dist/calcite/assets/icon/compactness32.json +1 -0
  4. package/dist/calcite/assets/icon/configure16.json +1 -0
  5. package/dist/calcite/assets/icon/configure24.json +1 -0
  6. package/dist/calcite/assets/icon/configure32.json +1 -0
  7. package/dist/calcite/assets/icon/debugScript16.json +1 -0
  8. package/dist/calcite/assets/icon/debugScript24.json +1 -0
  9. package/dist/calcite/assets/icon/debugScript32.json +1 -0
  10. package/dist/calcite/assets/icon/dissolveFeatures16.json +1 -0
  11. package/dist/calcite/assets/icon/dissolveFeatures24.json +1 -0
  12. package/dist/calcite/assets/icon/dissolveFeatures32.json +1 -0
  13. package/dist/calcite/assets/icon/distanceType16.json +1 -0
  14. package/dist/calcite/assets/icon/distanceType24.json +1 -0
  15. package/dist/calcite/assets/icon/distanceType32.json +1 -0
  16. package/dist/calcite/assets/icon/gridDiamond16.json +1 -0
  17. package/dist/calcite/assets/icon/gridDiamond24.json +1 -0
  18. package/dist/calcite/assets/icon/gridDiamond32.json +1 -0
  19. package/dist/calcite/assets/icon/gridHexagon16.json +1 -0
  20. package/dist/calcite/assets/icon/gridHexagon24.json +1 -0
  21. package/dist/calcite/assets/icon/gridHexagon32.json +1 -0
  22. package/dist/calcite/assets/icon/gridTriangle16.json +1 -0
  23. package/dist/calcite/assets/icon/gridTriangle24.json +1 -0
  24. package/dist/calcite/assets/icon/gridTriangle32.json +1 -0
  25. package/dist/calcite/assets/icon/insets16.json +1 -0
  26. package/dist/calcite/assets/icon/insets24.json +1 -0
  27. package/dist/calcite/assets/icon/insets32.json +1 -0
  28. package/dist/calcite/assets/icon/maximumTerritoryDistance16.json +1 -0
  29. package/dist/calcite/assets/icon/maximumTerritoryDistance24.json +1 -0
  30. package/dist/calcite/assets/icon/maximumTerritoryDistance32.json +1 -0
  31. package/dist/calcite/assets/icon/minDistanceBetweenCenters16.json +1 -0
  32. package/dist/calcite/assets/icon/minDistanceBetweenCenters24.json +1 -0
  33. package/dist/calcite/assets/icon/minDistanceBetweenCenters32.json +1 -0
  34. package/dist/calcite/assets/icon/numberOfTerritories16.json +1 -0
  35. package/dist/calcite/assets/icon/numberOfTerritories24.json +1 -0
  36. package/dist/calcite/assets/icon/numberOfTerritories32.json +1 -0
  37. package/dist/calcite/assets/icon/overlapFeatures16.json +1 -0
  38. package/dist/calcite/assets/icon/overlapFeatures24.json +1 -0
  39. package/dist/calcite/assets/icon/overlapFeatures32.json +1 -0
  40. package/dist/calcite/assets/icon/profileVariables16.json +1 -0
  41. package/dist/calcite/assets/icon/profileVariables24.json +1 -0
  42. package/dist/calcite/assets/icon/profileVariables32.json +1 -0
  43. package/dist/calcite/assets/icon/rasterAnalysis16.json +1 -0
  44. package/dist/calcite/assets/icon/rasterAnalysis24.json +1 -0
  45. package/dist/calcite/assets/icon/rasterAnalysis32.json +1 -0
  46. package/dist/calcite/assets/icon/recurrence16.json +1 -0
  47. package/dist/calcite/assets/icon/recurrence24.json +1 -0
  48. package/dist/calcite/assets/icon/recurrence32.json +1 -0
  49. package/dist/calcite/assets/icon/splitFeatures16.json +1 -0
  50. package/dist/calcite/assets/icon/splitFeatures24.json +1 -0
  51. package/dist/calcite/assets/icon/splitFeatures32.json +1 -0
  52. package/dist/calcite/assets/icon/territoryBufferDistance16.json +1 -0
  53. package/dist/calcite/assets/icon/territoryBufferDistance24.json +1 -0
  54. package/dist/calcite/assets/icon/territoryBufferDistance32.json +1 -0
  55. package/dist/calcite/assets/icon/testData16.json +1 -0
  56. package/dist/calcite/assets/icon/testData24.json +1 -0
  57. package/dist/calcite/assets/icon/testData32.json +1 -0
  58. package/dist/calcite/calcite.esm.js +2 -2
  59. package/dist/calcite/calcite.js +1 -1
  60. package/dist/calcite/index.esm.js +1 -1
  61. package/dist/calcite/{p-0ba791df.entry.js → p-01386e9f.entry.js} +2 -2
  62. package/dist/calcite/p-01dc5605.entry.js +6 -0
  63. package/dist/calcite/p-0349dbb1.system.js +6 -0
  64. package/dist/calcite/{p-f5a00782.entry.js → p-03f1df01.entry.js} +2 -2
  65. package/dist/calcite/p-06320e6a.entry.js +6 -0
  66. package/dist/calcite/{p-4f04264f.system.entry.js → p-06d14664.system.entry.js} +2 -2
  67. package/dist/calcite/p-0985e4df.system.entry.js +6 -0
  68. package/dist/calcite/p-09c7a130.system.entry.js +6 -0
  69. package/dist/calcite/p-0c41044b.entry.js +6 -0
  70. package/dist/calcite/{p-99520e50.js → p-0dbcb343.js} +1 -1
  71. package/dist/calcite/{p-5ed8397b.js → p-1094dab2.js} +1 -1
  72. package/dist/calcite/{p-117836c2.system.entry.js → p-11d0e13f.system.entry.js} +2 -2
  73. package/dist/calcite/{p-4275a429.system.js → p-164bea30.system.js} +2 -2
  74. package/dist/calcite/{p-a9630b98.js → p-18bcf729.js} +1 -1
  75. package/dist/calcite/{p-0f0713c7.entry.js → p-1af2a45c.entry.js} +2 -2
  76. package/dist/calcite/p-20f86b1d.entry.js +6 -0
  77. package/dist/calcite/p-21dbd253.system.js +6 -0
  78. package/dist/calcite/{p-769054e6.entry.js → p-23a643c6.entry.js} +2 -2
  79. package/dist/calcite/{p-8d9d8984.system.entry.js → p-23ab0d5a.system.entry.js} +2 -2
  80. package/dist/calcite/{p-7c32da09.entry.js → p-2681265e.entry.js} +2 -2
  81. package/dist/calcite/p-27de1d41.entry.js +6 -0
  82. package/dist/calcite/{p-40a15f4a.system.entry.js → p-28dc602c.system.entry.js} +2 -2
  83. package/dist/calcite/p-2e9f9de6.system.entry.js +6 -0
  84. package/dist/calcite/{p-4f443e21.system.entry.js → p-2f977a66.system.entry.js} +2 -2
  85. package/dist/calcite/{p-be0551f8.system.js → p-30dfc127.system.js} +1 -1
  86. package/dist/calcite/{p-23c9c6f9.js → p-33694839.js} +1 -1
  87. package/dist/calcite/{p-34cf7a42.entry.js → p-33d317d6.entry.js} +2 -2
  88. package/dist/calcite/p-358263ac.system.js +6 -0
  89. package/dist/calcite/{p-2f07bcb4.system.js → p-3819513d.system.js} +1 -1
  90. package/dist/calcite/p-3b01dd13.system.entry.js +6 -0
  91. package/dist/calcite/{p-045f28b2.entry.js → p-3c3ec245.entry.js} +2 -2
  92. package/dist/calcite/p-3c78a381.entry.js +6 -0
  93. package/dist/calcite/p-3de000e5.system.js +6 -0
  94. package/dist/calcite/p-3e21c354.entry.js +6 -0
  95. package/dist/calcite/{p-3119474f.entry.js → p-3e92df28.entry.js} +2 -2
  96. package/dist/calcite/p-410b7a2a.system.entry.js +6 -0
  97. package/dist/calcite/{p-ae4a167e.system.js → p-43d72920.system.js} +2 -2
  98. package/dist/calcite/{p-de040bc0.entry.js → p-44061788.entry.js} +2 -2
  99. package/dist/calcite/{p-cb3633ce.system.entry.js → p-446cb0a3.system.entry.js} +2 -2
  100. package/dist/calcite/{p-72ab20ed.system.entry.js → p-474380ed.system.entry.js} +2 -2
  101. package/dist/calcite/{p-cec925c5.system.entry.js → p-4a6fda6a.system.entry.js} +2 -2
  102. package/dist/calcite/{p-c62291e6.system.entry.js → p-4c3ce7bd.system.entry.js} +2 -2
  103. package/dist/calcite/{p-e3f1b697.system.entry.js → p-4cd8e82e.system.entry.js} +2 -2
  104. package/dist/calcite/{p-7e9cac29.system.entry.js → p-4f823472.system.entry.js} +2 -2
  105. package/dist/calcite/p-508a7e13.system.entry.js +6 -0
  106. package/dist/calcite/p-5234dd2e.system.entry.js +6 -0
  107. package/dist/calcite/{p-8117e07b.system.js → p-55057483.system.js} +1 -1
  108. package/dist/calcite/{p-2363fc48.system.entry.js → p-56096486.system.entry.js} +2 -2
  109. package/dist/calcite/p-5adf6e11.entry.js +6 -0
  110. package/dist/calcite/{p-22e1813c.entry.js → p-62e44703.entry.js} +2 -2
  111. package/dist/calcite/{p-329ade24.system.entry.js → p-64f15878.system.entry.js} +2 -2
  112. package/dist/calcite/p-6592ebdb.system.entry.js +6 -0
  113. package/dist/calcite/p-66a7f499.system.entry.js +6 -0
  114. package/dist/calcite/p-676b5b1e.entry.js +6 -0
  115. package/dist/calcite/{p-7ebc956d.system.js → p-68277cce.system.js} +1 -1
  116. package/dist/calcite/p-6945f08a.system.entry.js +6 -0
  117. package/dist/calcite/p-697ea587.system.entry.js +6 -0
  118. package/dist/calcite/p-6a27e2d9.entry.js +6 -0
  119. package/dist/calcite/p-6bf2e610.entry.js +6 -0
  120. package/dist/calcite/{p-fb726bdd.system.js → p-6ca6734d.system.js} +1 -1
  121. package/dist/calcite/p-6d1d2449.entry.js +6 -0
  122. package/dist/calcite/p-6e8677ae.entry.js +6 -0
  123. package/dist/calcite/{p-f8d2efa3.js → p-70f33b3e.js} +1 -1
  124. package/dist/calcite/p-7266932c.js +6 -0
  125. package/dist/calcite/p-73784058.js +6 -0
  126. package/dist/calcite/p-751b387d.system.entry.js +6 -0
  127. package/dist/calcite/p-76e2d427.system.js +6 -0
  128. package/dist/calcite/{p-89146101.entry.js → p-792fd998.entry.js} +2 -2
  129. package/dist/calcite/{p-4ff2f38c.entry.js → p-7ae35ad7.entry.js} +2 -2
  130. package/dist/calcite/p-7dcdfeac.entry.js +6 -0
  131. package/dist/calcite/{p-db2360e6.js → p-7f183647.js} +1 -1
  132. package/dist/calcite/{p-daf452fa.entry.js → p-7f556dbd.entry.js} +2 -2
  133. package/dist/calcite/p-80d62897.entry.js +6 -0
  134. package/dist/calcite/{p-c82c3a08.entry.js → p-80e8926a.entry.js} +2 -2
  135. package/dist/calcite/{p-c76d5a12.entry.js → p-82da0c62.entry.js} +2 -2
  136. package/dist/calcite/{p-d7f31cff.system.js → p-83192ea5.system.js} +1 -1
  137. package/dist/calcite/p-8319da8e.entry.js +6 -0
  138. package/dist/calcite/{p-1d3ba736.system.entry.js → p-83cc50f2.system.entry.js} +2 -2
  139. package/dist/calcite/p-84cd0598.system.entry.js +6 -0
  140. package/dist/calcite/{p-9b7b6b30.entry.js → p-8505461f.entry.js} +2 -2
  141. package/dist/calcite/p-86904d57.entry.js +6 -0
  142. package/dist/calcite/{p-55d64bae.system.entry.js → p-87698ac7.system.entry.js} +2 -2
  143. package/dist/calcite/{p-2a4bbfa2.system.entry.js → p-87aae2e3.system.entry.js} +2 -2
  144. package/dist/calcite/{p-5dd1e943.system.js → p-88147c4a.system.js} +1 -1
  145. package/dist/calcite/{p-5a3414c7.js → p-89b2f38d.js} +1 -1
  146. package/dist/calcite/p-8a87f2b7.system.entry.js +6 -0
  147. package/dist/calcite/{p-bef4c06f.system.js → p-8b0ea955.system.js} +1 -1
  148. package/dist/calcite/p-8e0a0d74.system.entry.js +6 -0
  149. package/dist/calcite/p-9141d57e.entry.js +6 -0
  150. package/dist/calcite/p-954973e6.system.entry.js +6 -0
  151. package/dist/calcite/{p-69fdc534.entry.js → p-9802e5ca.entry.js} +2 -2
  152. package/dist/calcite/p-9969deb4.system.entry.js +6 -0
  153. package/dist/calcite/{p-82c05795.js → p-997202fe.js} +2 -2
  154. package/dist/calcite/{p-609f05ef.entry.js → p-9987d5e9.entry.js} +2 -2
  155. package/dist/calcite/p-9d9629d5.system.entry.js +6 -0
  156. package/dist/calcite/p-9f50e2fe.system.entry.js +6 -0
  157. package/dist/calcite/{p-f839293b.system.js → p-a0f7fe5b.system.js} +2 -2
  158. package/dist/calcite/p-a1076e59.system.js +6 -0
  159. package/dist/calcite/p-a1f93b32.js +6 -0
  160. package/dist/calcite/{p-e131dae7.system.entry.js → p-a3074bb4.system.entry.js} +2 -2
  161. package/dist/calcite/{p-e837987d.system.js → p-a3d47df8.system.js} +1 -1
  162. package/dist/calcite/{p-26fc61bb.system.js → p-a4729c51.system.js} +2 -2
  163. package/dist/calcite/{p-ffc13e2d.entry.js → p-a56b2d66.entry.js} +2 -2
  164. package/dist/calcite/{p-8729fefb.entry.js → p-a66f170f.entry.js} +2 -2
  165. package/dist/calcite/{p-e4a047e7.system.entry.js → p-aaad5997.system.entry.js} +2 -2
  166. package/dist/calcite/p-aadce719.entry.js +6 -0
  167. package/dist/calcite/p-ad58c01e.system.js +6 -0
  168. package/dist/calcite/{p-948a5bba.system.entry.js → p-aea7886a.system.entry.js} +2 -2
  169. package/dist/calcite/p-aeaaccdf.entry.js +6 -0
  170. package/dist/calcite/{p-47913e44.system.entry.js → p-b2947a00.system.entry.js} +2 -2
  171. package/dist/calcite/p-b571cc54.system.entry.js +6 -0
  172. package/dist/calcite/p-b8132e75.system.entry.js +6 -0
  173. package/dist/calcite/{p-1b7e43a7.js → p-bf2fe8b0.js} +2 -2
  174. package/dist/calcite/p-c665108b.entry.js +6 -0
  175. package/dist/calcite/{p-1866c3d6.entry.js → p-c76d3ea1.entry.js} +2 -2
  176. package/dist/calcite/p-c8919467.entry.js +6 -0
  177. package/dist/calcite/p-c9235ef4.entry.js +6 -0
  178. package/dist/calcite/p-c9f57b84.system.entry.js +6 -0
  179. package/dist/calcite/{p-24db2b0a.system.js → p-ca9efa2d.system.js} +1 -1
  180. package/dist/calcite/p-cc1b5a8a.entry.js +6 -0
  181. package/dist/calcite/p-cc425495.entry.js +6 -0
  182. package/dist/calcite/{p-99bd5049.system.js → p-cca09bde.system.js} +1 -1
  183. package/dist/calcite/p-cfbb3f0f.system.entry.js +6 -0
  184. package/dist/calcite/{p-61021069.system.js → p-d04eb041.system.js} +1 -1
  185. package/dist/calcite/{p-c477a6ac.system.entry.js → p-d22143e9.system.entry.js} +2 -2
  186. package/dist/calcite/p-d2e3fa31.system.entry.js +6 -0
  187. package/dist/calcite/p-d38ffb30.js +6 -0
  188. package/dist/calcite/{p-aad21300.system.js → p-d40e595b.system.js} +2 -2
  189. package/dist/calcite/p-d484cd1b.system.entry.js +6 -0
  190. package/dist/calcite/{p-a3478523.js → p-d6381f74.js} +1 -1
  191. package/dist/calcite/p-d674d041.entry.js +6 -0
  192. package/dist/calcite/{p-e64fc8d7.entry.js → p-d76afd8f.entry.js} +2 -2
  193. package/dist/calcite/p-da7761d3.js +6 -0
  194. package/dist/calcite/{p-dfd0c1ce.js → p-dc14a2a0.js} +1 -1
  195. package/dist/calcite/{p-f3ba8a0a.entry.js → p-dc1d1b83.entry.js} +2 -2
  196. package/dist/calcite/{p-3ceba891.js → p-dd444456.js} +2 -2
  197. package/dist/calcite/p-df476c53.system.entry.js +6 -0
  198. package/dist/calcite/p-e086d5bc.entry.js +6 -0
  199. package/dist/calcite/{p-14ca50d9.entry.js → p-e0fb9338.entry.js} +2 -2
  200. package/dist/calcite/{p-21461822.entry.js → p-e2bc1677.entry.js} +2 -2
  201. package/dist/calcite/{p-ed535fb3.system.js → p-e3ee7868.system.js} +1 -1
  202. package/dist/calcite/p-e45b2203.entry.js +6 -0
  203. package/dist/calcite/p-e575643a.js +6 -0
  204. package/dist/calcite/p-e68bfc88.system.entry.js +6 -0
  205. package/dist/calcite/p-e9357dcc.system.entry.js +6 -0
  206. package/dist/calcite/p-e95c755c.entry.js +6 -0
  207. package/dist/calcite/p-e9acab15.entry.js +6 -0
  208. package/dist/calcite/{p-3113528a.js → p-e9e1dee1.js} +1 -1
  209. package/dist/calcite/p-ed7aab50.system.entry.js +6 -0
  210. package/dist/calcite/p-edc5bf01.js +6 -0
  211. package/dist/calcite/p-ee5494db.system.entry.js +6 -0
  212. package/dist/calcite/{p-90660203.js → p-ee9b4197.js} +1 -1
  213. package/dist/calcite/{p-bddde234.system.entry.js → p-ef059155.system.entry.js} +2 -2
  214. package/dist/calcite/{p-2bcf0f54.js → p-f383e414.js} +2 -2
  215. package/dist/calcite/{p-44f00a2a.system.entry.js → p-f5394fa4.system.entry.js} +2 -2
  216. package/dist/calcite/p-f74193a3.js +6 -0
  217. package/dist/calcite/{p-3412c57d.system.js → p-f86fd5f9.system.js} +2 -2
  218. package/dist/calcite/p-f8d59d84.entry.js +6 -0
  219. package/dist/calcite/{p-a2b46564.entry.js → p-fa2ce2ae.entry.js} +2 -2
  220. package/dist/calcite/{p-52c9824d.system.entry.js → p-faeb976d.system.entry.js} +2 -2
  221. package/dist/calcite/p-fc2144e0.system.entry.js +6 -0
  222. package/dist/calcite/{p-e8698d9f.system.entry.js → p-fcac8f9c.system.entry.js} +2 -2
  223. package/dist/calcite/{p-ceae054a.system.entry.js → p-fd5d23d1.system.entry.js} +2 -2
  224. package/dist/calcite/{p-b15cde3f.js → p-fe972352.js} +1 -1
  225. package/dist/cjs/{ExpandToggle-e3bd3e9d.js → ExpandToggle-8c61677e.js} +6 -6
  226. package/dist/cjs/{Heading-b864aca1.js → Heading-0cb5902d.js} +2 -2
  227. package/dist/cjs/{array-00db7b4e.js → array-f1fe66d8.js} +1 -1
  228. package/dist/cjs/calcite-accordion_2.cjs.entry.js +5 -5
  229. package/dist/cjs/calcite-action-bar.cjs.entry.js +11 -11
  230. package/dist/cjs/calcite-action-group.cjs.entry.js +8 -8
  231. package/dist/cjs/calcite-action-menu.cjs.entry.js +24 -22
  232. package/dist/cjs/calcite-action-pad.cjs.entry.js +10 -10
  233. package/dist/cjs/calcite-action.cjs.entry.js +7 -5
  234. package/dist/cjs/calcite-alert.cjs.entry.js +7 -7
  235. package/dist/cjs/calcite-avatar.cjs.entry.js +6 -6
  236. package/dist/cjs/calcite-block_2.cjs.entry.js +20 -12
  237. package/dist/cjs/calcite-button.cjs.entry.js +11 -10
  238. package/dist/cjs/calcite-card.cjs.entry.js +7 -7
  239. package/dist/cjs/calcite-checkbox.cjs.entry.js +9 -9
  240. package/dist/cjs/calcite-chip.cjs.entry.js +13 -12
  241. package/dist/cjs/calcite-color-picker_3.cjs.entry.js +1306 -1312
  242. package/dist/cjs/calcite-combobox_3.cjs.entry.js +23 -19
  243. package/dist/cjs/calcite-date-picker_4.cjs.entry.js +17 -13
  244. package/dist/cjs/calcite-dropdown_3.cjs.entry.js +29 -17
  245. package/dist/cjs/calcite-fab.cjs.entry.js +5 -5
  246. package/dist/cjs/calcite-filter.cjs.entry.js +16 -14
  247. package/dist/cjs/calcite-flow.cjs.entry.js +4 -4
  248. package/dist/cjs/calcite-graph_2.cjs.entry.js +10 -10
  249. package/dist/cjs/calcite-handle.cjs.entry.js +5 -3
  250. package/dist/cjs/calcite-icon.cjs.entry.js +6 -6
  251. package/dist/cjs/calcite-inline-editable.cjs.entry.js +11 -13
  252. package/dist/cjs/calcite-input-date-picker.cjs.entry.js +32 -14
  253. package/dist/cjs/calcite-input-message.cjs.entry.js +4 -4
  254. package/dist/cjs/calcite-input-time-picker_2.cjs.entry.js +29 -14
  255. package/dist/cjs/calcite-input.cjs.entry.js +59 -37
  256. package/dist/cjs/calcite-label.cjs.entry.js +5 -5
  257. package/dist/cjs/calcite-link.cjs.entry.js +5 -5
  258. package/dist/cjs/calcite-list_3.cjs.entry.js +8 -8
  259. package/dist/cjs/calcite-loader.cjs.entry.js +3 -3
  260. package/dist/cjs/calcite-modal.cjs.entry.js +7 -7
  261. package/dist/cjs/calcite-notice.cjs.entry.js +7 -7
  262. package/dist/cjs/calcite-option_3.cjs.entry.js +8 -8
  263. package/dist/cjs/calcite-pagination.cjs.entry.js +2 -2
  264. package/dist/cjs/calcite-panel.cjs.entry.js +35 -12
  265. package/dist/cjs/calcite-pick-list_3.cjs.entry.js +13 -13
  266. package/dist/cjs/calcite-popover_2.cjs.entry.js +102 -45
  267. package/dist/cjs/calcite-progress.cjs.entry.js +2 -2
  268. package/dist/cjs/calcite-radio-button-group.cjs.entry.js +3 -3
  269. package/dist/cjs/calcite-radio-button.cjs.entry.js +9 -9
  270. package/dist/cjs/calcite-radio-group_2.cjs.entry.js +8 -8
  271. package/dist/cjs/calcite-rating.cjs.entry.js +7 -7
  272. package/dist/cjs/calcite-scrim.cjs.entry.js +2 -2
  273. package/dist/cjs/calcite-shell_3.cjs.entry.js +9 -9
  274. package/dist/cjs/calcite-sortable-list.cjs.entry.js +5 -5
  275. package/dist/cjs/calcite-split-button.cjs.entry.js +3 -3
  276. package/dist/cjs/calcite-stepper_2.cjs.entry.js +112 -105
  277. package/dist/cjs/calcite-switch.cjs.entry.js +8 -8
  278. package/dist/cjs/calcite-tab_4.cjs.entry.js +9 -9
  279. package/dist/cjs/calcite-tile-select_2.cjs.entry.js +4 -4
  280. package/dist/cjs/calcite-tile.cjs.entry.js +8 -8
  281. package/dist/cjs/calcite-tip_3.cjs.entry.js +11 -9
  282. package/dist/cjs/calcite-tooltip_2.cjs.entry.js +163 -134
  283. package/dist/cjs/calcite-tree_2.cjs.entry.js +15 -15
  284. package/dist/cjs/calcite-value-list_2.cjs.entry.js +27 -27
  285. package/dist/cjs/calcite.cjs.js +4 -4
  286. package/dist/cjs/{conditionalSlot-8468d1b6.js → conditionalSlot-ba5cd797.js} +3 -3
  287. package/dist/cjs/{debounce-a29e2f71.js → debounce-94d2834e.js} +1 -1
  288. package/dist/cjs/{dom-66c5cb56.js → dom-9ac0341c.js} +13 -2
  289. package/dist/cjs/{forIn-d4941a7b.js → forIn-9f737b26.js} +2 -2
  290. package/dist/cjs/{form-cfcc3b12.js → form-11926121.js} +20 -3
  291. package/dist/cjs/{guid-364777e6.js → guid-8b6d6cb4.js} +1 -1
  292. package/dist/cjs/{index-ab066772.js → index-5c65e149.js} +1 -4
  293. package/dist/cjs/index.cjs.js +1 -1
  294. package/dist/cjs/{interactive-3808ad50.js → interactive-e294111f.js} +1 -1
  295. package/dist/cjs/{interfaces-597482d7.js → interfaces-083f4502.js} +1 -1
  296. package/dist/cjs/{label-e53e11ab.js → label-165fc611.js} +19 -19
  297. package/dist/cjs/loader.cjs.js +4 -4
  298. package/dist/cjs/{locale-2f9c939d.js → locale-f2ebe4fa.js} +22 -30
  299. package/dist/cjs/{math-b81c3249.js → math-9d6de52c.js} +1 -1
  300. package/dist/cjs/{number-99949cb0.js → number-364babbc.js} +1 -1
  301. package/dist/cjs/{observers-2dc895e1.js → observers-d9fdf006.js} +1 -1
  302. package/dist/cjs/{popper-5aeab272.js → popper-3f97eb01.js} +2 -2
  303. package/dist/cjs/{resources-ff2cae6a.js → resources-1a214670.js} +1 -1
  304. package/dist/cjs/{resources-7b0c6b5a.js → resources-247d05d5.js} +3 -3
  305. package/dist/cjs/{resources-39df6d9b.js → resources-5da94c46.js} +1 -1
  306. package/dist/cjs/{resources-9baed1da.js → resources-684ec2e5.js} +6 -6
  307. package/dist/cjs/{sortable.esm-6d0d59e8.js → sortable.esm-0005295a.js} +1 -1
  308. package/dist/cjs/{utils-9f674b6a.js → utils-51c079f6.js} +1 -1
  309. package/dist/collection/collection-manifest.json +1 -1
  310. package/dist/collection/components/accordion/accordion.js +1 -1
  311. package/dist/collection/components/accordion/interfaces.js +1 -1
  312. package/dist/collection/components/accordion-item/accordion-item.js +3 -3
  313. package/dist/collection/components/action/action.js +3 -2
  314. package/dist/collection/components/action/resources.js +1 -1
  315. package/dist/collection/components/action-bar/action-bar.js +2 -2
  316. package/dist/collection/components/action-bar/resources.js +1 -1
  317. package/dist/collection/components/action-bar/utils.js +1 -1
  318. package/dist/collection/components/action-group/action-group.js +1 -1
  319. package/dist/collection/components/action-group/resources.js +1 -1
  320. package/dist/collection/components/action-menu/action-menu.js +18 -16
  321. package/dist/collection/components/action-menu/resources.js +1 -1
  322. package/dist/collection/components/action-pad/action-pad.js +2 -2
  323. package/dist/collection/components/action-pad/resources.js +1 -1
  324. package/dist/collection/components/alert/alert.css +2 -6
  325. package/dist/collection/components/alert/alert.js +3 -3
  326. package/dist/collection/components/alert/interfaces.js +1 -1
  327. package/dist/collection/components/alert/resources.js +1 -1
  328. package/dist/collection/components/avatar/avatar.css +1 -1
  329. package/dist/collection/components/avatar/avatar.js +1 -1
  330. package/dist/collection/components/avatar/utils.js +1 -1
  331. package/dist/collection/components/block/block.js +19 -9
  332. package/dist/collection/components/block/resources.js +1 -1
  333. package/dist/collection/components/block-section/block-section.js +3 -3
  334. package/dist/collection/components/block-section/interfaces.js +1 -1
  335. package/dist/collection/components/block-section/resources.js +1 -1
  336. package/dist/collection/components/button/button.js +5 -4
  337. package/dist/collection/components/button/interfaces.js +1 -1
  338. package/dist/collection/components/button/resources.js +1 -1
  339. package/dist/collection/components/card/card.js +3 -3
  340. package/dist/collection/components/card/resources.js +1 -1
  341. package/dist/collection/components/checkbox/checkbox.css +5 -1
  342. package/dist/collection/components/checkbox/checkbox.js +3 -2
  343. package/dist/collection/components/chip/chip.css +21 -18
  344. package/dist/collection/components/chip/chip.js +4 -4
  345. package/dist/collection/components/chip/interfaces.js +1 -1
  346. package/dist/collection/components/chip/resources.js +4 -3
  347. package/dist/collection/components/color-picker/color-picker.css +2 -9
  348. package/dist/collection/components/color-picker/color-picker.js +7 -2
  349. package/dist/collection/components/color-picker/interfaces.js +1 -1
  350. package/dist/collection/components/color-picker/resources.js +1 -1
  351. package/dist/collection/components/color-picker/utils.js +1 -1
  352. package/dist/collection/components/color-picker-hex-input/color-picker-hex-input.js +7 -2
  353. package/dist/collection/components/color-picker-hex-input/resources.js +1 -1
  354. package/dist/collection/components/color-picker-swatch/color-picker-swatch.js +1 -1
  355. package/dist/collection/components/color-picker-swatch/resources.js +1 -1
  356. package/dist/collection/components/combobox/combobox.js +13 -8
  357. package/dist/collection/components/combobox/interfaces.js +1 -1
  358. package/dist/collection/components/combobox/resources.js +5 -1
  359. package/dist/collection/components/combobox/utils.js +1 -1
  360. package/dist/collection/components/combobox-item/combobox-item.js +1 -1
  361. package/dist/collection/components/combobox-item/resources.js +1 -1
  362. package/dist/collection/components/combobox-item-group/combobox-item-group.js +1 -1
  363. package/dist/collection/components/combobox-item-group/resources.js +1 -1
  364. package/dist/collection/components/date-picker/date-picker.js +7 -3
  365. package/dist/collection/components/date-picker/interfaces.js +1 -1
  366. package/dist/collection/components/date-picker/resources.js +1 -1
  367. package/dist/collection/components/date-picker/utils.js +1 -1
  368. package/dist/collection/components/date-picker-day/date-picker-day.css +0 -2
  369. package/dist/collection/components/date-picker-day/date-picker-day.js +1 -1
  370. package/dist/collection/components/date-picker-month/date-picker-month.js +2 -2
  371. package/dist/collection/components/date-picker-month-header/date-picker-month-header.js +1 -1
  372. package/dist/collection/components/dropdown/dropdown.js +24 -12
  373. package/dist/collection/components/dropdown/interfaces.js +1 -1
  374. package/dist/collection/components/dropdown/resources.js +1 -1
  375. package/dist/collection/components/dropdown-group/dropdown-group.js +1 -1
  376. package/dist/collection/components/dropdown-group/interfaces.js +1 -1
  377. package/dist/collection/components/dropdown-group/resources.js +1 -1
  378. package/dist/collection/components/dropdown-item/dropdown-item.js +3 -3
  379. package/dist/collection/components/dropdown-item/resources.js +1 -1
  380. package/dist/collection/components/fab/fab.js +1 -1
  381. package/dist/collection/components/fab/resources.js +1 -1
  382. package/dist/collection/components/filter/filter.js +9 -8
  383. package/dist/collection/components/filter/resources.js +2 -3
  384. package/dist/collection/components/flow/flow.css +1 -9
  385. package/dist/collection/components/flow/flow.js +1 -1
  386. package/dist/collection/components/flow/interfaces.js +1 -1
  387. package/dist/collection/components/flow/resources.js +1 -1
  388. package/dist/collection/components/functional/ExpandToggle.js +2 -2
  389. package/dist/collection/components/functional/Heading.js +1 -1
  390. package/dist/collection/components/graph/graph.js +1 -1
  391. package/dist/collection/components/graph/interfaces.js +1 -1
  392. package/dist/collection/components/graph/util.js +1 -1
  393. package/dist/collection/components/handle/handle.js +3 -2
  394. package/dist/collection/components/handle/resources.js +1 -1
  395. package/dist/collection/components/icon/assets/icon/compactness16.json +1 -0
  396. package/dist/collection/components/icon/assets/icon/compactness24.json +1 -0
  397. package/dist/collection/components/icon/assets/icon/compactness32.json +1 -0
  398. package/dist/collection/components/icon/assets/icon/configure16.json +1 -0
  399. package/dist/collection/components/icon/assets/icon/configure24.json +1 -0
  400. package/dist/collection/components/icon/assets/icon/configure32.json +1 -0
  401. package/dist/collection/components/icon/assets/icon/debugScript16.json +1 -0
  402. package/dist/collection/components/icon/assets/icon/debugScript24.json +1 -0
  403. package/dist/collection/components/icon/assets/icon/debugScript32.json +1 -0
  404. package/dist/collection/components/icon/assets/icon/dissolveFeatures16.json +1 -0
  405. package/dist/collection/components/icon/assets/icon/dissolveFeatures24.json +1 -0
  406. package/dist/collection/components/icon/assets/icon/dissolveFeatures32.json +1 -0
  407. package/dist/collection/components/icon/assets/icon/distanceType16.json +1 -0
  408. package/dist/collection/components/icon/assets/icon/distanceType24.json +1 -0
  409. package/dist/collection/components/icon/assets/icon/distanceType32.json +1 -0
  410. package/dist/collection/components/icon/assets/icon/gridDiamond16.json +1 -0
  411. package/dist/collection/components/icon/assets/icon/gridDiamond24.json +1 -0
  412. package/dist/collection/components/icon/assets/icon/gridDiamond32.json +1 -0
  413. package/dist/collection/components/icon/assets/icon/gridHexagon16.json +1 -0
  414. package/dist/collection/components/icon/assets/icon/gridHexagon24.json +1 -0
  415. package/dist/collection/components/icon/assets/icon/gridHexagon32.json +1 -0
  416. package/dist/collection/components/icon/assets/icon/gridTriangle16.json +1 -0
  417. package/dist/collection/components/icon/assets/icon/gridTriangle24.json +1 -0
  418. package/dist/collection/components/icon/assets/icon/gridTriangle32.json +1 -0
  419. package/dist/collection/components/icon/assets/icon/insets16.json +1 -0
  420. package/dist/collection/components/icon/assets/icon/insets24.json +1 -0
  421. package/dist/collection/components/icon/assets/icon/insets32.json +1 -0
  422. package/dist/collection/components/icon/assets/icon/maximumTerritoryDistance16.json +1 -0
  423. package/dist/collection/components/icon/assets/icon/maximumTerritoryDistance24.json +1 -0
  424. package/dist/collection/components/icon/assets/icon/maximumTerritoryDistance32.json +1 -0
  425. package/dist/collection/components/icon/assets/icon/minDistanceBetweenCenters16.json +1 -0
  426. package/dist/collection/components/icon/assets/icon/minDistanceBetweenCenters24.json +1 -0
  427. package/dist/collection/components/icon/assets/icon/minDistanceBetweenCenters32.json +1 -0
  428. package/dist/collection/components/icon/assets/icon/numberOfTerritories16.json +1 -0
  429. package/dist/collection/components/icon/assets/icon/numberOfTerritories24.json +1 -0
  430. package/dist/collection/components/icon/assets/icon/numberOfTerritories32.json +1 -0
  431. package/dist/collection/components/icon/assets/icon/overlapFeatures16.json +1 -0
  432. package/dist/collection/components/icon/assets/icon/overlapFeatures24.json +1 -0
  433. package/dist/collection/components/icon/assets/icon/overlapFeatures32.json +1 -0
  434. package/dist/collection/components/icon/assets/icon/profileVariables16.json +1 -0
  435. package/dist/collection/components/icon/assets/icon/profileVariables24.json +1 -0
  436. package/dist/collection/components/icon/assets/icon/profileVariables32.json +1 -0
  437. package/dist/collection/components/icon/assets/icon/rasterAnalysis16.json +1 -0
  438. package/dist/collection/components/icon/assets/icon/rasterAnalysis24.json +1 -0
  439. package/dist/collection/components/icon/assets/icon/rasterAnalysis32.json +1 -0
  440. package/dist/collection/components/icon/assets/icon/recurrence16.json +1 -0
  441. package/dist/collection/components/icon/assets/icon/recurrence24.json +1 -0
  442. package/dist/collection/components/icon/assets/icon/recurrence32.json +1 -0
  443. package/dist/collection/components/icon/assets/icon/splitFeatures16.json +1 -0
  444. package/dist/collection/components/icon/assets/icon/splitFeatures24.json +1 -0
  445. package/dist/collection/components/icon/assets/icon/splitFeatures32.json +1 -0
  446. package/dist/collection/components/icon/assets/icon/territoryBufferDistance16.json +1 -0
  447. package/dist/collection/components/icon/assets/icon/territoryBufferDistance24.json +1 -0
  448. package/dist/collection/components/icon/assets/icon/territoryBufferDistance32.json +1 -0
  449. package/dist/collection/components/icon/assets/icon/testData16.json +1 -0
  450. package/dist/collection/components/icon/assets/icon/testData24.json +1 -0
  451. package/dist/collection/components/icon/assets/icon/testData32.json +1 -0
  452. package/dist/collection/components/icon/icon.js +3 -3
  453. package/dist/collection/components/icon/resources.js +1 -1
  454. package/dist/collection/components/icon/utils.js +1 -1
  455. package/dist/collection/components/inline-editable/inline-editable.js +5 -7
  456. package/dist/collection/components/inline-editable/resources.js +1 -1
  457. package/dist/collection/components/input/input.js +68 -32
  458. package/dist/collection/components/input/interfaces.js +1 -1
  459. package/dist/collection/components/input/resources.js +4 -1
  460. package/dist/collection/components/input-date-picker/input-date-picker.js +26 -7
  461. package/dist/collection/components/input-message/input-message.js +1 -1
  462. package/dist/collection/components/input-message/interfaces.js +1 -1
  463. package/dist/collection/components/input-time-picker/input-time-picker.js +40 -9
  464. package/dist/collection/components/interfaces.js +1 -1
  465. package/dist/collection/components/label/label.js +1 -1
  466. package/dist/collection/components/label/resources.js +1 -1
  467. package/dist/collection/components/link/link.js +1 -1
  468. package/dist/collection/components/list/list.js +1 -1
  469. package/dist/collection/components/list/resources.js +1 -1
  470. package/dist/collection/components/list-item/list-item.js +1 -1
  471. package/dist/collection/components/list-item/resources.js +1 -1
  472. package/dist/collection/components/list-item-group/list-item-group.js +1 -1
  473. package/dist/collection/components/list-item-group/resources.js +1 -1
  474. package/dist/collection/components/loader/loader.js +1 -1
  475. package/dist/collection/components/modal/interfaces.js +1 -1
  476. package/dist/collection/components/modal/modal.css +1 -37
  477. package/dist/collection/components/modal/modal.js +1 -1
  478. package/dist/collection/components/modal/resources.js +1 -1
  479. package/dist/collection/components/notice/notice.js +1 -1
  480. package/dist/collection/components/notice/resources.js +1 -1
  481. package/dist/collection/components/option/option.js +1 -1
  482. package/dist/collection/components/option-group/option-group.js +1 -1
  483. package/dist/collection/components/pagination/pagination.js +1 -1
  484. package/dist/collection/components/pagination/resources.js +1 -1
  485. package/dist/collection/components/panel/panel.css +1 -1
  486. package/dist/collection/components/panel/panel.js +47 -6
  487. package/dist/collection/components/panel/resources.js +1 -1
  488. package/dist/collection/components/pick-list/pick-list.js +1 -1
  489. package/dist/collection/components/pick-list/resources.js +1 -1
  490. package/dist/collection/components/pick-list/shared-list-logic.js +1 -1
  491. package/dist/collection/components/pick-list/shared-list-render.js +3 -2
  492. package/dist/collection/components/pick-list-group/pick-list-group.js +1 -1
  493. package/dist/collection/components/pick-list-group/resources.js +1 -1
  494. package/dist/collection/components/pick-list-item/pick-list-item.css +1 -1
  495. package/dist/collection/components/pick-list-item/pick-list-item.js +3 -3
  496. package/dist/collection/components/pick-list-item/resources.js +1 -1
  497. package/dist/collection/components/popover/PopoverManager.js +64 -0
  498. package/dist/collection/components/popover/popover.js +31 -7
  499. package/dist/collection/components/popover/resources.js +1 -2
  500. package/dist/collection/components/popover-manager/popover-manager.js +32 -45
  501. package/dist/collection/components/progress/progress.js +1 -1
  502. package/dist/collection/components/radio-button/radio-button.js +3 -3
  503. package/dist/collection/components/radio-button/resources.js +1 -1
  504. package/dist/collection/components/radio-button-group/radio-button-group.js +1 -1
  505. package/dist/collection/components/radio-group/interfaces.js +1 -1
  506. package/dist/collection/components/radio-group/radio-group.js +1 -1
  507. package/dist/collection/components/radio-group-item/radio-group-item.js +3 -3
  508. package/dist/collection/components/radio-group-item/resources.js +1 -1
  509. package/dist/collection/components/rating/rating.js +1 -1
  510. package/dist/collection/components/rating/resources.js +1 -1
  511. package/dist/collection/components/scrim/resources.js +1 -1
  512. package/dist/collection/components/scrim/scrim.js +1 -1
  513. package/dist/collection/components/select/resources.js +1 -1
  514. package/dist/collection/components/select/select.js +1 -1
  515. package/dist/collection/components/shell/resources.js +1 -1
  516. package/dist/collection/components/shell/shell.js +1 -1
  517. package/dist/collection/components/shell-center-row/resources.js +1 -1
  518. package/dist/collection/components/shell-center-row/shell-center-row.css +1 -1
  519. package/dist/collection/components/shell-center-row/shell-center-row.js +1 -1
  520. package/dist/collection/components/shell-panel/resources.js +1 -1
  521. package/dist/collection/components/shell-panel/shell-panel.css +2 -2
  522. package/dist/collection/components/shell-panel/shell-panel.js +5 -2
  523. package/dist/collection/components/slider/slider.css +29 -0
  524. package/dist/collection/components/slider/slider.js +1 -1
  525. package/dist/collection/components/sortable-list/resources.js +1 -1
  526. package/dist/collection/components/sortable-list/sortable-list.js +1 -1
  527. package/dist/collection/components/split-button/resources.js +1 -1
  528. package/dist/collection/components/split-button/split-button.js +1 -1
  529. package/dist/collection/components/stepper/interfaces.js +6 -0
  530. package/dist/collection/components/stepper/stepper.js +75 -55
  531. package/dist/collection/components/stepper-item/stepper-item.js +72 -74
  532. package/dist/collection/components/switch/switch.js +3 -3
  533. package/dist/collection/components/tab/interfaces.js +1 -1
  534. package/dist/collection/components/tab/tab.js +3 -3
  535. package/dist/collection/components/tab-nav/tab-nav.js +1 -1
  536. package/dist/collection/components/tab-title/tab-title.js +4 -4
  537. package/dist/collection/components/tabs/interfaces.js +1 -1
  538. package/dist/collection/components/tabs/resources.js +1 -1
  539. package/dist/collection/components/tabs/tabs.css +1 -1
  540. package/dist/collection/components/tabs/tabs.js +1 -1
  541. package/dist/collection/components/tile/resources.js +1 -1
  542. package/dist/collection/components/tile/tile.css +1 -0
  543. package/dist/collection/components/tile/tile.js +1 -1
  544. package/dist/collection/components/tile-select/interfaces.js +1 -1
  545. package/dist/collection/components/tile-select/resources.js +1 -1
  546. package/dist/collection/components/tile-select/tile-select.js +1 -1
  547. package/dist/collection/components/tile-select-group/interfaces.js +1 -1
  548. package/dist/collection/components/tile-select-group/tile-select-group.js +1 -1
  549. package/dist/collection/components/time-picker/resources.js +1 -1
  550. package/dist/collection/components/time-picker/time-picker.js +1 -1
  551. package/dist/collection/components/tip/resources.js +1 -1
  552. package/dist/collection/components/tip/tip.js +1 -1
  553. package/dist/collection/components/tip-group/tip-group.js +1 -1
  554. package/dist/collection/components/tip-manager/resources.js +1 -1
  555. package/dist/collection/components/tip-manager/tip-manager.css +1 -9
  556. package/dist/collection/components/tip-manager/tip-manager.js +23 -4
  557. package/dist/collection/components/tooltip/TooltipManager.js +157 -0
  558. package/dist/collection/components/tooltip/resources.js +1 -2
  559. package/dist/collection/components/tooltip/tooltip.css +1 -1
  560. package/dist/collection/components/tooltip/tooltip.js +8 -12
  561. package/dist/collection/components/tooltip-manager/tooltip-manager.js +5 -160
  562. package/dist/collection/components/tree/interfaces.js +1 -1
  563. package/dist/collection/components/tree/tree.js +12 -12
  564. package/dist/collection/components/tree-item/interfaces.js +1 -1
  565. package/dist/collection/components/tree-item/resources.js +1 -1
  566. package/dist/collection/components/tree-item/tree-item.js +18 -18
  567. package/dist/collection/components/value-list/resources.js +1 -1
  568. package/dist/collection/components/value-list/value-list.js +19 -19
  569. package/dist/collection/components/value-list-item/resources.js +1 -1
  570. package/dist/collection/components/value-list-item/value-list-item.js +22 -22
  571. package/dist/collection/utils/array.js +1 -1
  572. package/dist/collection/utils/conditionalSlot.js +1 -1
  573. package/dist/collection/utils/date.js +1 -1
  574. package/dist/collection/utils/dom.js +11 -1
  575. package/dist/collection/utils/filter.js +2 -2
  576. package/dist/collection/utils/form.js +16 -1
  577. package/dist/collection/utils/globalAttributes.js +1 -1
  578. package/dist/collection/utils/guid.js +1 -1
  579. package/dist/collection/utils/interactive.js +1 -1
  580. package/dist/collection/utils/key.js +1 -1
  581. package/dist/collection/utils/label.js +18 -18
  582. package/dist/collection/utils/locale.js +22 -29
  583. package/dist/collection/utils/math.js +1 -1
  584. package/dist/collection/utils/number.js +1 -1
  585. package/dist/collection/utils/observers.js +1 -1
  586. package/dist/collection/utils/popper.js +1 -1
  587. package/dist/collection/utils/resources.js +1 -1
  588. package/dist/collection/utils/time.js +1 -1
  589. package/dist/components/ExpandToggle.js +2 -2
  590. package/dist/components/Heading.js +1 -1
  591. package/dist/components/action-group.js +11 -17
  592. package/dist/components/action-menu.js +26 -30
  593. package/dist/components/action.js +3 -2
  594. package/dist/components/array.js +1 -1
  595. package/dist/components/button.js +6 -5
  596. package/dist/components/calcite-accordion-item.js +3 -3
  597. package/dist/components/calcite-accordion.js +1 -1
  598. package/dist/components/calcite-action-bar.js +14 -20
  599. package/dist/components/calcite-action-group.js +1 -1
  600. package/dist/components/calcite-action-menu.js +1 -1
  601. package/dist/components/calcite-action-pad.js +14 -20
  602. package/dist/components/calcite-action.js +1 -1
  603. package/dist/components/calcite-alert.js +4 -4
  604. package/dist/components/calcite-avatar.js +3 -3
  605. package/dist/components/calcite-block-section.js +3 -3
  606. package/dist/components/calcite-block.js +27 -25
  607. package/dist/components/calcite-button.js +1 -1
  608. package/dist/components/calcite-card.js +3 -3
  609. package/dist/components/calcite-checkbox.js +1 -1
  610. package/dist/components/calcite-chip.js +1 -1
  611. package/dist/components/calcite-color-picker-hex-input.js +1 -1
  612. package/dist/components/calcite-color-picker-swatch.js +1 -1
  613. package/dist/components/calcite-color-picker.js +8 -3
  614. package/dist/components/calcite-combobox-item-group.js +1 -1
  615. package/dist/components/calcite-combobox-item.js +1 -1
  616. package/dist/components/calcite-combobox.js +14 -9
  617. package/dist/components/calcite-date-picker-day.js +1 -1
  618. package/dist/components/calcite-date-picker-month-header.js +1 -1
  619. package/dist/components/calcite-date-picker-month.js +1 -1
  620. package/dist/components/calcite-date-picker.js +1 -1
  621. package/dist/components/calcite-dropdown-group.js +1 -1
  622. package/dist/components/calcite-dropdown-item.js +3 -3
  623. package/dist/components/calcite-dropdown.js +1 -1
  624. package/dist/components/calcite-fab.js +1 -1
  625. package/dist/components/calcite-filter.js +1 -1
  626. package/dist/components/calcite-flow.js +2 -2
  627. package/dist/components/calcite-graph.js +1 -1
  628. package/dist/components/calcite-handle.js +1 -1
  629. package/dist/components/calcite-icon.js +1 -1
  630. package/dist/components/calcite-inline-editable.js +5 -7
  631. package/dist/components/calcite-input-date-picker.js +24 -5
  632. package/dist/components/calcite-input-message.js +1 -1
  633. package/dist/components/calcite-input-time-picker.js +25 -9
  634. package/dist/components/calcite-input.js +1 -1
  635. package/dist/components/calcite-label.js +1 -1
  636. package/dist/components/calcite-link.js +1 -1
  637. package/dist/components/calcite-list-item-group.js +1 -1
  638. package/dist/components/calcite-list-item.js +1 -1
  639. package/dist/components/calcite-list.js +1 -1
  640. package/dist/components/calcite-loader.js +1 -1
  641. package/dist/components/calcite-modal.js +3 -3
  642. package/dist/components/calcite-notice.js +1 -1
  643. package/dist/components/calcite-option-group.js +1 -1
  644. package/dist/components/calcite-option.js +1 -1
  645. package/dist/components/calcite-pagination.js +1 -1
  646. package/dist/components/calcite-panel.js +41 -23
  647. package/dist/components/calcite-pick-list-group.js +2 -2
  648. package/dist/components/calcite-pick-list-item.js +1 -1
  649. package/dist/components/calcite-pick-list.js +2 -2
  650. package/dist/components/calcite-popover-manager.js +30 -38
  651. package/dist/components/calcite-popover.js +1 -1
  652. package/dist/components/calcite-progress.js +1 -1
  653. package/dist/components/calcite-radio-button-group.js +1 -1
  654. package/dist/components/calcite-radio-button.js +3 -3
  655. package/dist/components/calcite-radio-group-item.js +3 -3
  656. package/dist/components/calcite-radio-group.js +1 -1
  657. package/dist/components/calcite-rating.js +1 -1
  658. package/dist/components/calcite-scrim.js +1 -1
  659. package/dist/components/calcite-select.js +1 -1
  660. package/dist/components/calcite-shell-center-row.js +2 -2
  661. package/dist/components/calcite-shell-panel.js +2 -2
  662. package/dist/components/calcite-shell.js +1 -1
  663. package/dist/components/calcite-slider.js +2 -2
  664. package/dist/components/calcite-sortable-list.js +1 -1
  665. package/dist/components/calcite-split-button.js +1 -1
  666. package/dist/components/calcite-stepper-item.js +48 -59
  667. package/dist/components/calcite-stepper.js +63 -45
  668. package/dist/components/calcite-switch.js +1 -1
  669. package/dist/components/calcite-tab-nav.js +1 -1
  670. package/dist/components/calcite-tab-title.js +1 -1
  671. package/dist/components/calcite-tab.js +1 -1
  672. package/dist/components/calcite-tabs.js +1 -1
  673. package/dist/components/calcite-tile-select-group.js +1 -1
  674. package/dist/components/calcite-tile-select.js +1 -1
  675. package/dist/components/calcite-tile.js +1 -1
  676. package/dist/components/calcite-time-picker.js +1 -1
  677. package/dist/components/calcite-tip-group.js +1 -1
  678. package/dist/components/calcite-tip-manager.js +7 -5
  679. package/dist/components/calcite-tip.js +2 -2
  680. package/dist/components/calcite-tooltip-manager.js +47 -2
  681. package/dist/components/calcite-tooltip.js +170 -17
  682. package/dist/components/calcite-tree-item.js +7 -7
  683. package/dist/components/calcite-tree.js +5 -5
  684. package/dist/components/calcite-value-list-item.js +11 -11
  685. package/dist/components/calcite-value-list.js +9 -9
  686. package/dist/components/checkbox.js +4 -3
  687. package/dist/components/chip.js +8 -7
  688. package/dist/components/color-picker-hex-input.js +7 -2
  689. package/dist/components/color-picker-swatch.js +1336 -1352
  690. package/dist/components/conditionalSlot.js +1 -1
  691. package/dist/components/date-picker-day.js +2 -2
  692. package/dist/components/date-picker-month-header.js +1 -1
  693. package/dist/components/date-picker-month.js +2 -2
  694. package/dist/components/date-picker.js +7 -3
  695. package/dist/components/date.js +1 -1
  696. package/dist/components/debounce.js +1 -1
  697. package/dist/components/dom.js +12 -2
  698. package/dist/components/dropdown.js +23 -11
  699. package/dist/components/filter.js +10 -8
  700. package/dist/components/forIn.js +1 -1
  701. package/dist/components/form.js +18 -3
  702. package/dist/components/graph.js +1 -1
  703. package/dist/components/guid.js +1 -1
  704. package/dist/components/handle.js +3 -2
  705. package/dist/components/icon.js +3 -3
  706. package/dist/components/index.js +1 -1
  707. package/dist/components/input.js +53 -30
  708. package/dist/components/interactive.js +1 -1
  709. package/dist/components/interfaces.js +1 -1
  710. package/dist/components/interfaces2.js +1 -1
  711. package/dist/components/label.js +19 -19
  712. package/dist/components/label2.js +1 -1
  713. package/dist/components/link.js +1 -1
  714. package/dist/components/loader.js +1 -1
  715. package/dist/components/locale.js +22 -30
  716. package/dist/components/math.js +1 -1
  717. package/dist/components/number.js +1 -1
  718. package/dist/components/observers.js +1 -1
  719. package/dist/components/pick-list-item.js +5 -5
  720. package/dist/components/popover.js +91 -7
  721. package/dist/components/popper.js +1 -1
  722. package/dist/components/progress.js +1 -1
  723. package/dist/components/resources.js +11 -19
  724. package/dist/components/resources2.js +8 -6
  725. package/dist/components/resources3.js +25 -11
  726. package/dist/components/scrim.js +1 -1
  727. package/dist/components/shared-list-render.js +5 -5
  728. package/dist/components/sortable.esm.js +1 -1
  729. package/dist/components/switch.js +3 -3
  730. package/dist/components/tab-nav.js +2 -2
  731. package/dist/components/tab-title.js +3 -3
  732. package/dist/components/tab.js +3 -3
  733. package/dist/components/tabs.js +2 -2
  734. package/dist/components/tile.js +2 -2
  735. package/dist/components/time-picker.js +1 -1
  736. package/dist/components/utils.js +1 -1
  737. package/dist/components/utils2.js +1 -1
  738. package/dist/custom-elements/index.js +2278 -2064
  739. package/dist/esm/{ExpandToggle-847b61ba.js → ExpandToggle-1f6d84ba.js} +6 -6
  740. package/dist/esm/{Heading-f4ee0499.js → Heading-8d613e81.js} +2 -2
  741. package/dist/esm/{array-328a8961.js → array-1655bbf7.js} +1 -1
  742. package/dist/esm/calcite-accordion_2.entry.js +5 -5
  743. package/dist/esm/calcite-action-bar.entry.js +11 -11
  744. package/dist/esm/calcite-action-group.entry.js +8 -8
  745. package/dist/esm/calcite-action-menu.entry.js +24 -22
  746. package/dist/esm/calcite-action-pad.entry.js +10 -10
  747. package/dist/esm/calcite-action.entry.js +7 -5
  748. package/dist/esm/calcite-alert.entry.js +7 -7
  749. package/dist/esm/calcite-avatar.entry.js +6 -6
  750. package/dist/esm/calcite-block_2.entry.js +20 -12
  751. package/dist/esm/calcite-button.entry.js +11 -10
  752. package/dist/esm/calcite-card.entry.js +7 -7
  753. package/dist/esm/calcite-checkbox.entry.js +9 -9
  754. package/dist/esm/calcite-chip.entry.js +13 -12
  755. package/dist/esm/calcite-color-picker_3.entry.js +1306 -1312
  756. package/dist/esm/calcite-combobox_3.entry.js +23 -19
  757. package/dist/esm/calcite-date-picker_4.entry.js +17 -13
  758. package/dist/esm/calcite-dropdown_3.entry.js +29 -17
  759. package/dist/esm/calcite-fab.entry.js +5 -5
  760. package/dist/esm/calcite-filter.entry.js +16 -14
  761. package/dist/esm/calcite-flow.entry.js +4 -4
  762. package/dist/esm/calcite-graph_2.entry.js +10 -10
  763. package/dist/esm/calcite-handle.entry.js +5 -3
  764. package/dist/esm/calcite-icon.entry.js +6 -6
  765. package/dist/esm/calcite-inline-editable.entry.js +11 -13
  766. package/dist/esm/calcite-input-date-picker.entry.js +32 -14
  767. package/dist/esm/calcite-input-message.entry.js +4 -4
  768. package/dist/esm/calcite-input-time-picker_2.entry.js +29 -14
  769. package/dist/esm/calcite-input.entry.js +60 -38
  770. package/dist/esm/calcite-label.entry.js +5 -5
  771. package/dist/esm/calcite-link.entry.js +5 -5
  772. package/dist/esm/calcite-list_3.entry.js +8 -8
  773. package/dist/esm/calcite-loader.entry.js +3 -3
  774. package/dist/esm/calcite-modal.entry.js +7 -7
  775. package/dist/esm/calcite-notice.entry.js +7 -7
  776. package/dist/esm/calcite-option_3.entry.js +8 -8
  777. package/dist/esm/calcite-pagination.entry.js +2 -2
  778. package/dist/esm/calcite-panel.entry.js +35 -12
  779. package/dist/esm/calcite-pick-list_3.entry.js +13 -13
  780. package/dist/esm/calcite-popover_2.entry.js +102 -45
  781. package/dist/esm/calcite-progress.entry.js +2 -2
  782. package/dist/esm/calcite-radio-button-group.entry.js +3 -3
  783. package/dist/esm/calcite-radio-button.entry.js +9 -9
  784. package/dist/esm/calcite-radio-group_2.entry.js +8 -8
  785. package/dist/esm/calcite-rating.entry.js +7 -7
  786. package/dist/esm/calcite-scrim.entry.js +2 -2
  787. package/dist/esm/calcite-shell_3.entry.js +9 -9
  788. package/dist/esm/calcite-sortable-list.entry.js +5 -5
  789. package/dist/esm/calcite-split-button.entry.js +3 -3
  790. package/dist/esm/calcite-stepper_2.entry.js +112 -105
  791. package/dist/esm/calcite-switch.entry.js +8 -8
  792. package/dist/esm/calcite-tab_4.entry.js +9 -9
  793. package/dist/esm/calcite-tile-select_2.entry.js +4 -4
  794. package/dist/esm/calcite-tile.entry.js +8 -8
  795. package/dist/esm/calcite-tip_3.entry.js +11 -9
  796. package/dist/esm/calcite-tooltip_2.entry.js +163 -134
  797. package/dist/esm/calcite-tree_2.entry.js +15 -15
  798. package/dist/esm/calcite-value-list_2.entry.js +27 -27
  799. package/dist/esm/calcite.js +4 -4
  800. package/dist/esm/{conditionalSlot-a8a2c2f8.js → conditionalSlot-203be745.js} +3 -3
  801. package/dist/esm/{debounce-f689f579.js → debounce-c4df98cc.js} +1 -1
  802. package/dist/esm/{dom-0dcd3a1e.js → dom-da697a3f.js} +13 -3
  803. package/dist/esm/{forIn-8f588c7b.js → forIn-9b83dde4.js} +2 -2
  804. package/dist/esm/{form-2b88b33a.js → form-bca481e1.js} +19 -4
  805. package/dist/esm/{guid-174508ff.js → guid-b4461004.js} +1 -1
  806. package/dist/esm/{index-221092de.js → index-8ece2564.js} +1 -4
  807. package/dist/esm/index.js +1 -1
  808. package/dist/esm/{interactive-b11a6c05.js → interactive-cb5bf285.js} +1 -1
  809. package/dist/esm/{interfaces-2bc002ac.js → interfaces-f57a0946.js} +1 -1
  810. package/dist/esm/{label-2dac3c62.js → label-50132b90.js} +19 -19
  811. package/dist/esm/loader.js +4 -4
  812. package/dist/esm/{locale-9c18bf7f.js → locale-7ce850e5.js} +22 -30
  813. package/dist/esm/{math-4cd9449e.js → math-2e4483eb.js} +1 -1
  814. package/dist/esm/{number-a39356c7.js → number-237e74a9.js} +1 -1
  815. package/dist/esm/{observers-232c6ed6.js → observers-b198f831.js} +1 -1
  816. package/dist/esm/polyfills/css-shim.js +1 -1
  817. package/dist/esm/{popper-66bcddc6.js → popper-0fd1fd89.js} +2 -2
  818. package/dist/esm/{resources-8ade5fae.js → resources-3c30f589.js} +1 -1
  819. package/dist/esm/{resources-762aa55a.js → resources-c4ee68b9.js} +6 -6
  820. package/dist/esm/{resources-df870d40.js → resources-e8f918f0.js} +1 -1
  821. package/dist/esm/{resources-886efb7e.js → resources-f170fbe8.js} +3 -3
  822. package/dist/esm/{sortable.esm-0891f88f.js → sortable.esm-34b12dd8.js} +1 -1
  823. package/dist/esm/{utils-79203b5b.js → utils-040a2a22.js} +1 -1
  824. package/dist/esm-es5/{ExpandToggle-847b61ba.js → ExpandToggle-1f6d84ba.js} +2 -2
  825. package/dist/esm-es5/{Heading-f4ee0499.js → Heading-8d613e81.js} +2 -2
  826. package/dist/esm-es5/{array-328a8961.js → array-1655bbf7.js} +1 -1
  827. package/dist/esm-es5/calcite-accordion_2.entry.js +2 -2
  828. package/dist/esm-es5/calcite-action-bar.entry.js +2 -2
  829. package/dist/esm-es5/calcite-action-group.entry.js +2 -2
  830. package/dist/esm-es5/calcite-action-menu.entry.js +3 -3
  831. package/dist/esm-es5/calcite-action-pad.entry.js +3 -3
  832. package/dist/esm-es5/calcite-action.entry.js +2 -2
  833. package/dist/esm-es5/calcite-alert.entry.js +2 -2
  834. package/dist/esm-es5/calcite-avatar.entry.js +2 -2
  835. package/dist/esm-es5/calcite-block_2.entry.js +2 -2
  836. package/dist/esm-es5/calcite-button.entry.js +2 -2
  837. package/dist/esm-es5/calcite-card.entry.js +2 -2
  838. package/dist/esm-es5/calcite-checkbox.entry.js +2 -2
  839. package/dist/esm-es5/calcite-chip.entry.js +2 -2
  840. package/dist/esm-es5/calcite-color-picker_3.entry.js +2 -2
  841. package/dist/esm-es5/calcite-combobox_3.entry.js +2 -2
  842. package/dist/esm-es5/calcite-date-picker_4.entry.js +2 -2
  843. package/dist/esm-es5/calcite-dropdown_3.entry.js +3 -3
  844. package/dist/esm-es5/calcite-fab.entry.js +2 -2
  845. package/dist/esm-es5/calcite-filter.entry.js +2 -2
  846. package/dist/esm-es5/calcite-flow.entry.js +2 -2
  847. package/dist/esm-es5/calcite-graph_2.entry.js +2 -2
  848. package/dist/esm-es5/calcite-handle.entry.js +2 -2
  849. package/dist/esm-es5/calcite-icon.entry.js +2 -2
  850. package/dist/esm-es5/calcite-inline-editable.entry.js +2 -2
  851. package/dist/esm-es5/calcite-input-date-picker.entry.js +2 -2
  852. package/dist/esm-es5/calcite-input-message.entry.js +2 -2
  853. package/dist/esm-es5/calcite-input-time-picker_2.entry.js +2 -2
  854. package/dist/esm-es5/calcite-input.entry.js +2 -2
  855. package/dist/esm-es5/calcite-label.entry.js +2 -2
  856. package/dist/esm-es5/calcite-link.entry.js +2 -2
  857. package/dist/esm-es5/calcite-list_3.entry.js +2 -2
  858. package/dist/esm-es5/calcite-loader.entry.js +2 -2
  859. package/dist/esm-es5/calcite-modal.entry.js +3 -3
  860. package/dist/esm-es5/calcite-notice.entry.js +3 -3
  861. package/dist/esm-es5/calcite-option_3.entry.js +2 -2
  862. package/dist/esm-es5/calcite-pagination.entry.js +2 -2
  863. package/dist/esm-es5/calcite-panel.entry.js +3 -3
  864. package/dist/esm-es5/calcite-pick-list_3.entry.js +2 -2
  865. package/dist/esm-es5/calcite-popover_2.entry.js +3 -3
  866. package/dist/esm-es5/calcite-progress.entry.js +2 -2
  867. package/dist/esm-es5/calcite-radio-button-group.entry.js +2 -2
  868. package/dist/esm-es5/calcite-radio-button.entry.js +2 -2
  869. package/dist/esm-es5/calcite-radio-group_2.entry.js +2 -2
  870. package/dist/esm-es5/calcite-rating.entry.js +2 -2
  871. package/dist/esm-es5/calcite-scrim.entry.js +2 -2
  872. package/dist/esm-es5/calcite-shell_3.entry.js +2 -2
  873. package/dist/esm-es5/calcite-sortable-list.entry.js +2 -2
  874. package/dist/esm-es5/calcite-split-button.entry.js +2 -2
  875. package/dist/esm-es5/calcite-stepper_2.entry.js +3 -3
  876. package/dist/esm-es5/calcite-switch.entry.js +2 -2
  877. package/dist/esm-es5/calcite-tab_4.entry.js +2 -2
  878. package/dist/esm-es5/calcite-tile-select_2.entry.js +2 -2
  879. package/dist/esm-es5/calcite-tile.entry.js +2 -2
  880. package/dist/esm-es5/calcite-tip_3.entry.js +2 -2
  881. package/dist/esm-es5/calcite-tooltip_2.entry.js +3 -3
  882. package/dist/esm-es5/calcite-tree_2.entry.js +2 -2
  883. package/dist/esm-es5/calcite-value-list_2.entry.js +2 -2
  884. package/dist/esm-es5/calcite.js +2 -2
  885. package/dist/esm-es5/{conditionalSlot-a8a2c2f8.js → conditionalSlot-203be745.js} +2 -2
  886. package/dist/esm-es5/{debounce-f689f579.js → debounce-c4df98cc.js} +1 -1
  887. package/dist/esm-es5/{dom-0dcd3a1e.js → dom-da697a3f.js} +2 -2
  888. package/dist/esm-es5/{forIn-8f588c7b.js → forIn-9b83dde4.js} +2 -2
  889. package/dist/esm-es5/form-bca481e1.js +6 -0
  890. package/dist/esm-es5/{guid-174508ff.js → guid-b4461004.js} +1 -1
  891. package/dist/esm-es5/{index-221092de.js → index-8ece2564.js} +2 -2
  892. package/dist/esm-es5/index.js +1 -1
  893. package/dist/esm-es5/{interactive-b11a6c05.js → interactive-cb5bf285.js} +1 -1
  894. package/dist/esm-es5/{interfaces-2bc002ac.js → interfaces-f57a0946.js} +1 -1
  895. package/dist/esm-es5/label-50132b90.js +6 -0
  896. package/dist/esm-es5/loader.js +2 -2
  897. package/dist/esm-es5/locale-7ce850e5.js +6 -0
  898. package/dist/esm-es5/{math-4cd9449e.js → math-2e4483eb.js} +1 -1
  899. package/dist/esm-es5/{number-a39356c7.js → number-237e74a9.js} +1 -1
  900. package/dist/esm-es5/{observers-232c6ed6.js → observers-b198f831.js} +1 -1
  901. package/dist/esm-es5/{popper-66bcddc6.js → popper-0fd1fd89.js} +2 -2
  902. package/dist/esm-es5/{resources-8ade5fae.js → resources-3c30f589.js} +1 -1
  903. package/dist/esm-es5/resources-c4ee68b9.js +6 -0
  904. package/dist/esm-es5/{resources-df870d40.js → resources-e8f918f0.js} +1 -1
  905. package/dist/esm-es5/{resources-886efb7e.js → resources-f170fbe8.js} +2 -2
  906. package/dist/esm-es5/{sortable.esm-0891f88f.js → sortable.esm-34b12dd8.js} +1 -1
  907. package/dist/esm-es5/{utils-79203b5b.js → utils-040a2a22.js} +1 -1
  908. package/dist/extras/docs-json.json +152 -137
  909. package/dist/loader/cdn.js +1 -1
  910. package/dist/loader/index.cjs.js +1 -1
  911. package/dist/loader/index.es2017.js +1 -1
  912. package/dist/loader/index.js +1 -1
  913. package/dist/types/components/action-menu/action-menu.d.ts +3 -2
  914. package/dist/types/components/block/block.d.ts +2 -2
  915. package/dist/types/components/button/button.d.ts +2 -1
  916. package/dist/types/components/chip/resources.d.ts +3 -2
  917. package/dist/types/components/color-picker/color-picker.d.ts +1 -0
  918. package/dist/types/components/color-picker-hex-input/color-picker-hex-input.d.ts +1 -0
  919. package/dist/types/components/combobox/resources.d.ts +4 -0
  920. package/dist/types/components/dropdown/dropdown.d.ts +4 -1
  921. package/dist/types/components/filter/filter.d.ts +1 -1
  922. package/dist/types/components/filter/resources.d.ts +0 -1
  923. package/dist/types/components/inline-editable/inline-editable.d.ts +0 -1
  924. package/dist/types/components/input/input.d.ts +10 -4
  925. package/dist/types/components/input/resources.d.ts +3 -0
  926. package/dist/types/components/input-date-picker/input-date-picker.d.ts +1 -0
  927. package/dist/types/components/input-time-picker/input-time-picker.d.ts +5 -0
  928. package/dist/types/components/panel/panel.d.ts +8 -0
  929. package/dist/types/components/popover/PopoverManager.d.ts +10 -0
  930. package/dist/types/components/popover/popover.d.ts +4 -0
  931. package/dist/types/components/popover/resources.d.ts +0 -1
  932. package/dist/types/components/popover-manager/popover-manager.d.ts +6 -2
  933. package/dist/types/components/shell-panel/shell-panel.d.ts +1 -0
  934. package/dist/types/components/stepper/interfaces.d.ts +10 -0
  935. package/dist/types/components/stepper/stepper.d.ts +13 -9
  936. package/dist/types/components/stepper-item/stepper-item.d.ts +7 -8
  937. package/dist/types/components/tab-title/tab-title.d.ts +1 -1
  938. package/dist/types/components/tip-manager/tip-manager.d.ts +5 -0
  939. package/dist/types/components/tooltip/TooltipManager.d.ts +27 -0
  940. package/dist/types/components/tooltip/resources.d.ts +0 -1
  941. package/dist/types/components/tooltip/tooltip.d.ts +0 -2
  942. package/dist/types/components/tooltip-manager/tooltip-manager.d.ts +1 -29
  943. package/dist/types/components/tree/tree.d.ts +7 -7
  944. package/dist/types/components/tree-item/tree-item.d.ts +11 -11
  945. package/dist/types/components/value-list/value-list.d.ts +13 -13
  946. package/dist/types/components/value-list-item/value-list-item.d.ts +12 -12
  947. package/dist/types/components.d.ts +85 -53
  948. package/dist/types/preact.d.ts +4 -2
  949. package/dist/types/utils/dom.d.ts +8 -0
  950. package/dist/types/utils/form.d.ts +20 -5
  951. package/hydrate/index.js +2301 -2073
  952. package/package.json +22 -23
  953. package/readme.md +4 -4
  954. package/dist/calcite/p-023a27d2.system.entry.js +0 -6
  955. package/dist/calcite/p-0a6b6898.system.entry.js +0 -6
  956. package/dist/calcite/p-0ee86cc3.js +0 -6
  957. package/dist/calcite/p-0f8c3ea0.entry.js +0 -6
  958. package/dist/calcite/p-1084cd40.entry.js +0 -6
  959. package/dist/calcite/p-14be4304.system.entry.js +0 -6
  960. package/dist/calcite/p-181bd093.entry.js +0 -6
  961. package/dist/calcite/p-19987cfa.system.entry.js +0 -6
  962. package/dist/calcite/p-1d0db848.system.entry.js +0 -6
  963. package/dist/calcite/p-2789e3e2.system.js +0 -6
  964. package/dist/calcite/p-2c0fdd49.entry.js +0 -6
  965. package/dist/calcite/p-2f42b00e.system.entry.js +0 -6
  966. package/dist/calcite/p-300c0203.system.entry.js +0 -6
  967. package/dist/calcite/p-33391f44.entry.js +0 -6
  968. package/dist/calcite/p-34a92432.system.entry.js +0 -6
  969. package/dist/calcite/p-3b38f3f5.system.entry.js +0 -6
  970. package/dist/calcite/p-3b6e600a.entry.js +0 -6
  971. package/dist/calcite/p-3c732519.entry.js +0 -6
  972. package/dist/calcite/p-3e5f8e93.system.entry.js +0 -6
  973. package/dist/calcite/p-3ebff946.system.entry.js +0 -6
  974. package/dist/calcite/p-40334853.system.js +0 -6
  975. package/dist/calcite/p-469490f8.js +0 -6
  976. package/dist/calcite/p-482956de.entry.js +0 -6
  977. package/dist/calcite/p-48aa73e5.entry.js +0 -6
  978. package/dist/calcite/p-4a543a6e.entry.js +0 -6
  979. package/dist/calcite/p-4b6a7167.entry.js +0 -6
  980. package/dist/calcite/p-50f49b13.system.entry.js +0 -6
  981. package/dist/calcite/p-5857c533.system.entry.js +0 -6
  982. package/dist/calcite/p-608aaf1d.js +0 -6
  983. package/dist/calcite/p-60f78917.system.entry.js +0 -6
  984. package/dist/calcite/p-6294787b.system.js +0 -6
  985. package/dist/calcite/p-62a93131.entry.js +0 -6
  986. package/dist/calcite/p-6750e68e.entry.js +0 -6
  987. package/dist/calcite/p-678e83fe.entry.js +0 -6
  988. package/dist/calcite/p-693cc0cd.system.entry.js +0 -6
  989. package/dist/calcite/p-6c9ab1d6.system.entry.js +0 -6
  990. package/dist/calcite/p-6ebbdae4.entry.js +0 -6
  991. package/dist/calcite/p-7225f4ed.js +0 -6
  992. package/dist/calcite/p-7463e93d.entry.js +0 -6
  993. package/dist/calcite/p-7549f33d.entry.js +0 -6
  994. package/dist/calcite/p-88f476f3.system.entry.js +0 -6
  995. package/dist/calcite/p-8d372581.entry.js +0 -6
  996. package/dist/calcite/p-941b8b06.js +0 -6
  997. package/dist/calcite/p-9d488536.entry.js +0 -6
  998. package/dist/calcite/p-9da64897.system.js +0 -6
  999. package/dist/calcite/p-a4b72090.system.entry.js +0 -6
  1000. package/dist/calcite/p-af100a3b.entry.js +0 -6
  1001. package/dist/calcite/p-b3d74df1.entry.js +0 -6
  1002. package/dist/calcite/p-b50b0f92.system.entry.js +0 -6
  1003. package/dist/calcite/p-b6dad672.system.entry.js +0 -6
  1004. package/dist/calcite/p-bae3c0b1.entry.js +0 -6
  1005. package/dist/calcite/p-bc873e26.system.js +0 -6
  1006. package/dist/calcite/p-c0ab6c20.system.entry.js +0 -6
  1007. package/dist/calcite/p-c22bd1df.system.entry.js +0 -6
  1008. package/dist/calcite/p-c2770291.js +0 -6
  1009. package/dist/calcite/p-c66cce4a.js +0 -6
  1010. package/dist/calcite/p-c91e5ce6.system.entry.js +0 -6
  1011. package/dist/calcite/p-cc881354.entry.js +0 -6
  1012. package/dist/calcite/p-d0ae73bc.system.entry.js +0 -6
  1013. package/dist/calcite/p-d2aad5f9.system.entry.js +0 -6
  1014. package/dist/calcite/p-d441a36b.system.js +0 -6
  1015. package/dist/calcite/p-d668cc57.entry.js +0 -6
  1016. package/dist/calcite/p-d8c1d1bb.system.js +0 -6
  1017. package/dist/calcite/p-d9669187.entry.js +0 -6
  1018. package/dist/calcite/p-da5a9916.system.entry.js +0 -6
  1019. package/dist/calcite/p-ddc498f5.entry.js +0 -6
  1020. package/dist/calcite/p-e21b549b.js +0 -6
  1021. package/dist/calcite/p-e6034e51.entry.js +0 -6
  1022. package/dist/calcite/p-e6b83b93.entry.js +0 -6
  1023. package/dist/calcite/p-ea09f02f.system.entry.js +0 -6
  1024. package/dist/calcite/p-eaf8f62d.entry.js +0 -6
  1025. package/dist/calcite/p-ec6942a8.system.entry.js +0 -6
  1026. package/dist/calcite/p-ef8bcab3.entry.js +0 -6
  1027. package/dist/calcite/p-f753e964.entry.js +0 -6
  1028. package/dist/calcite/p-f89876d3.system.entry.js +0 -6
  1029. package/dist/calcite/p-fc2aa57a.system.entry.js +0 -6
  1030. package/dist/calcite/p-ffeda3eb.system.entry.js +0 -6
  1031. package/dist/components/resources4.js +0 -16
  1032. package/dist/components/resources5.js +0 -33
  1033. package/dist/components/tooltip-manager.js +0 -172
  1034. package/dist/esm-es5/form-2b88b33a.js +0 -6
  1035. package/dist/esm-es5/label-2dac3c62.js +0 -6
  1036. package/dist/esm-es5/locale-9c18bf7f.js +0 -6
  1037. package/dist/esm-es5/resources-762aa55a.js +0 -6
@@ -1,19 +1,19 @@
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.0.0-beta.81
4
+ * v1.0.0-beta.82
5
5
  */
6
6
  'use strict';
7
7
 
8
8
  Object.defineProperty(exports, '__esModule', { value: true });
9
9
 
10
- const index = require('./index-ab066772.js');
11
- const dom = require('./dom-66c5cb56.js');
12
- const utils = require('./utils-9f674b6a.js');
13
- const math = require('./math-b81c3249.js');
14
- const interactive = require('./interactive-3808ad50.js');
15
- const debounce = require('./debounce-a29e2f71.js');
16
- require('./guid-364777e6.js');
10
+ const index = require('./index-5c65e149.js');
11
+ const dom = require('./dom-9ac0341c.js');
12
+ const utils = require('./utils-51c079f6.js');
13
+ const math = require('./math-9d6de52c.js');
14
+ const interactive = require('./interactive-e294111f.js');
15
+ const debounce = require('./debounce-94d2834e.js');
16
+ require('./guid-8b6d6cb4.js');
17
17
 
18
18
  /** Error message constants. */
19
19
  var FUNC_ERROR_TEXT = 'Expected a function';
@@ -531,1023 +531,995 @@ function hexDouble(num) {
531
531
  }
532
532
  });
533
533
 
534
- var colorName = {
535
- "aliceblue": [240, 248, 255],
536
- "antiquewhite": [250, 235, 215],
537
- "aqua": [0, 255, 255],
538
- "aquamarine": [127, 255, 212],
539
- "azure": [240, 255, 255],
540
- "beige": [245, 245, 220],
541
- "bisque": [255, 228, 196],
542
- "black": [0, 0, 0],
543
- "blanchedalmond": [255, 235, 205],
544
- "blue": [0, 0, 255],
545
- "blueviolet": [138, 43, 226],
546
- "brown": [165, 42, 42],
547
- "burlywood": [222, 184, 135],
548
- "cadetblue": [95, 158, 160],
549
- "chartreuse": [127, 255, 0],
550
- "chocolate": [210, 105, 30],
551
- "coral": [255, 127, 80],
552
- "cornflowerblue": [100, 149, 237],
553
- "cornsilk": [255, 248, 220],
554
- "crimson": [220, 20, 60],
555
- "cyan": [0, 255, 255],
556
- "darkblue": [0, 0, 139],
557
- "darkcyan": [0, 139, 139],
558
- "darkgoldenrod": [184, 134, 11],
559
- "darkgray": [169, 169, 169],
560
- "darkgreen": [0, 100, 0],
561
- "darkgrey": [169, 169, 169],
562
- "darkkhaki": [189, 183, 107],
563
- "darkmagenta": [139, 0, 139],
564
- "darkolivegreen": [85, 107, 47],
565
- "darkorange": [255, 140, 0],
566
- "darkorchid": [153, 50, 204],
567
- "darkred": [139, 0, 0],
568
- "darksalmon": [233, 150, 122],
569
- "darkseagreen": [143, 188, 143],
570
- "darkslateblue": [72, 61, 139],
571
- "darkslategray": [47, 79, 79],
572
- "darkslategrey": [47, 79, 79],
573
- "darkturquoise": [0, 206, 209],
574
- "darkviolet": [148, 0, 211],
575
- "deeppink": [255, 20, 147],
576
- "deepskyblue": [0, 191, 255],
577
- "dimgray": [105, 105, 105],
578
- "dimgrey": [105, 105, 105],
579
- "dodgerblue": [30, 144, 255],
580
- "firebrick": [178, 34, 34],
581
- "floralwhite": [255, 250, 240],
582
- "forestgreen": [34, 139, 34],
583
- "fuchsia": [255, 0, 255],
584
- "gainsboro": [220, 220, 220],
585
- "ghostwhite": [248, 248, 255],
586
- "gold": [255, 215, 0],
587
- "goldenrod": [218, 165, 32],
588
- "gray": [128, 128, 128],
589
- "green": [0, 128, 0],
590
- "greenyellow": [173, 255, 47],
591
- "grey": [128, 128, 128],
592
- "honeydew": [240, 255, 240],
593
- "hotpink": [255, 105, 180],
594
- "indianred": [205, 92, 92],
595
- "indigo": [75, 0, 130],
596
- "ivory": [255, 255, 240],
597
- "khaki": [240, 230, 140],
598
- "lavender": [230, 230, 250],
599
- "lavenderblush": [255, 240, 245],
600
- "lawngreen": [124, 252, 0],
601
- "lemonchiffon": [255, 250, 205],
602
- "lightblue": [173, 216, 230],
603
- "lightcoral": [240, 128, 128],
604
- "lightcyan": [224, 255, 255],
605
- "lightgoldenrodyellow": [250, 250, 210],
606
- "lightgray": [211, 211, 211],
607
- "lightgreen": [144, 238, 144],
608
- "lightgrey": [211, 211, 211],
609
- "lightpink": [255, 182, 193],
610
- "lightsalmon": [255, 160, 122],
611
- "lightseagreen": [32, 178, 170],
612
- "lightskyblue": [135, 206, 250],
613
- "lightslategray": [119, 136, 153],
614
- "lightslategrey": [119, 136, 153],
615
- "lightsteelblue": [176, 196, 222],
616
- "lightyellow": [255, 255, 224],
617
- "lime": [0, 255, 0],
618
- "limegreen": [50, 205, 50],
619
- "linen": [250, 240, 230],
620
- "magenta": [255, 0, 255],
621
- "maroon": [128, 0, 0],
622
- "mediumaquamarine": [102, 205, 170],
623
- "mediumblue": [0, 0, 205],
624
- "mediumorchid": [186, 85, 211],
625
- "mediumpurple": [147, 112, 219],
626
- "mediumseagreen": [60, 179, 113],
627
- "mediumslateblue": [123, 104, 238],
628
- "mediumspringgreen": [0, 250, 154],
629
- "mediumturquoise": [72, 209, 204],
630
- "mediumvioletred": [199, 21, 133],
631
- "midnightblue": [25, 25, 112],
632
- "mintcream": [245, 255, 250],
633
- "mistyrose": [255, 228, 225],
634
- "moccasin": [255, 228, 181],
635
- "navajowhite": [255, 222, 173],
636
- "navy": [0, 0, 128],
637
- "oldlace": [253, 245, 230],
638
- "olive": [128, 128, 0],
639
- "olivedrab": [107, 142, 35],
640
- "orange": [255, 165, 0],
641
- "orangered": [255, 69, 0],
642
- "orchid": [218, 112, 214],
643
- "palegoldenrod": [238, 232, 170],
644
- "palegreen": [152, 251, 152],
645
- "paleturquoise": [175, 238, 238],
646
- "palevioletred": [219, 112, 147],
647
- "papayawhip": [255, 239, 213],
648
- "peachpuff": [255, 218, 185],
649
- "peru": [205, 133, 63],
650
- "pink": [255, 192, 203],
651
- "plum": [221, 160, 221],
652
- "powderblue": [176, 224, 230],
653
- "purple": [128, 0, 128],
654
- "rebeccapurple": [102, 51, 153],
655
- "red": [255, 0, 0],
656
- "rosybrown": [188, 143, 143],
657
- "royalblue": [65, 105, 225],
658
- "saddlebrown": [139, 69, 19],
659
- "salmon": [250, 128, 114],
660
- "sandybrown": [244, 164, 96],
661
- "seagreen": [46, 139, 87],
662
- "seashell": [255, 245, 238],
663
- "sienna": [160, 82, 45],
664
- "silver": [192, 192, 192],
665
- "skyblue": [135, 206, 235],
666
- "slateblue": [106, 90, 205],
667
- "slategray": [112, 128, 144],
668
- "slategrey": [112, 128, 144],
669
- "snow": [255, 250, 250],
670
- "springgreen": [0, 255, 127],
671
- "steelblue": [70, 130, 180],
672
- "tan": [210, 180, 140],
673
- "teal": [0, 128, 128],
674
- "thistle": [216, 191, 216],
675
- "tomato": [255, 99, 71],
676
- "turquoise": [64, 224, 208],
677
- "violet": [238, 130, 238],
678
- "wheat": [245, 222, 179],
679
- "white": [255, 255, 255],
680
- "whitesmoke": [245, 245, 245],
681
- "yellow": [255, 255, 0],
682
- "yellowgreen": [154, 205, 50]
534
+ var colorName = {
535
+ "aliceblue": [240, 248, 255],
536
+ "antiquewhite": [250, 235, 215],
537
+ "aqua": [0, 255, 255],
538
+ "aquamarine": [127, 255, 212],
539
+ "azure": [240, 255, 255],
540
+ "beige": [245, 245, 220],
541
+ "bisque": [255, 228, 196],
542
+ "black": [0, 0, 0],
543
+ "blanchedalmond": [255, 235, 205],
544
+ "blue": [0, 0, 255],
545
+ "blueviolet": [138, 43, 226],
546
+ "brown": [165, 42, 42],
547
+ "burlywood": [222, 184, 135],
548
+ "cadetblue": [95, 158, 160],
549
+ "chartreuse": [127, 255, 0],
550
+ "chocolate": [210, 105, 30],
551
+ "coral": [255, 127, 80],
552
+ "cornflowerblue": [100, 149, 237],
553
+ "cornsilk": [255, 248, 220],
554
+ "crimson": [220, 20, 60],
555
+ "cyan": [0, 255, 255],
556
+ "darkblue": [0, 0, 139],
557
+ "darkcyan": [0, 139, 139],
558
+ "darkgoldenrod": [184, 134, 11],
559
+ "darkgray": [169, 169, 169],
560
+ "darkgreen": [0, 100, 0],
561
+ "darkgrey": [169, 169, 169],
562
+ "darkkhaki": [189, 183, 107],
563
+ "darkmagenta": [139, 0, 139],
564
+ "darkolivegreen": [85, 107, 47],
565
+ "darkorange": [255, 140, 0],
566
+ "darkorchid": [153, 50, 204],
567
+ "darkred": [139, 0, 0],
568
+ "darksalmon": [233, 150, 122],
569
+ "darkseagreen": [143, 188, 143],
570
+ "darkslateblue": [72, 61, 139],
571
+ "darkslategray": [47, 79, 79],
572
+ "darkslategrey": [47, 79, 79],
573
+ "darkturquoise": [0, 206, 209],
574
+ "darkviolet": [148, 0, 211],
575
+ "deeppink": [255, 20, 147],
576
+ "deepskyblue": [0, 191, 255],
577
+ "dimgray": [105, 105, 105],
578
+ "dimgrey": [105, 105, 105],
579
+ "dodgerblue": [30, 144, 255],
580
+ "firebrick": [178, 34, 34],
581
+ "floralwhite": [255, 250, 240],
582
+ "forestgreen": [34, 139, 34],
583
+ "fuchsia": [255, 0, 255],
584
+ "gainsboro": [220, 220, 220],
585
+ "ghostwhite": [248, 248, 255],
586
+ "gold": [255, 215, 0],
587
+ "goldenrod": [218, 165, 32],
588
+ "gray": [128, 128, 128],
589
+ "green": [0, 128, 0],
590
+ "greenyellow": [173, 255, 47],
591
+ "grey": [128, 128, 128],
592
+ "honeydew": [240, 255, 240],
593
+ "hotpink": [255, 105, 180],
594
+ "indianred": [205, 92, 92],
595
+ "indigo": [75, 0, 130],
596
+ "ivory": [255, 255, 240],
597
+ "khaki": [240, 230, 140],
598
+ "lavender": [230, 230, 250],
599
+ "lavenderblush": [255, 240, 245],
600
+ "lawngreen": [124, 252, 0],
601
+ "lemonchiffon": [255, 250, 205],
602
+ "lightblue": [173, 216, 230],
603
+ "lightcoral": [240, 128, 128],
604
+ "lightcyan": [224, 255, 255],
605
+ "lightgoldenrodyellow": [250, 250, 210],
606
+ "lightgray": [211, 211, 211],
607
+ "lightgreen": [144, 238, 144],
608
+ "lightgrey": [211, 211, 211],
609
+ "lightpink": [255, 182, 193],
610
+ "lightsalmon": [255, 160, 122],
611
+ "lightseagreen": [32, 178, 170],
612
+ "lightskyblue": [135, 206, 250],
613
+ "lightslategray": [119, 136, 153],
614
+ "lightslategrey": [119, 136, 153],
615
+ "lightsteelblue": [176, 196, 222],
616
+ "lightyellow": [255, 255, 224],
617
+ "lime": [0, 255, 0],
618
+ "limegreen": [50, 205, 50],
619
+ "linen": [250, 240, 230],
620
+ "magenta": [255, 0, 255],
621
+ "maroon": [128, 0, 0],
622
+ "mediumaquamarine": [102, 205, 170],
623
+ "mediumblue": [0, 0, 205],
624
+ "mediumorchid": [186, 85, 211],
625
+ "mediumpurple": [147, 112, 219],
626
+ "mediumseagreen": [60, 179, 113],
627
+ "mediumslateblue": [123, 104, 238],
628
+ "mediumspringgreen": [0, 250, 154],
629
+ "mediumturquoise": [72, 209, 204],
630
+ "mediumvioletred": [199, 21, 133],
631
+ "midnightblue": [25, 25, 112],
632
+ "mintcream": [245, 255, 250],
633
+ "mistyrose": [255, 228, 225],
634
+ "moccasin": [255, 228, 181],
635
+ "navajowhite": [255, 222, 173],
636
+ "navy": [0, 0, 128],
637
+ "oldlace": [253, 245, 230],
638
+ "olive": [128, 128, 0],
639
+ "olivedrab": [107, 142, 35],
640
+ "orange": [255, 165, 0],
641
+ "orangered": [255, 69, 0],
642
+ "orchid": [218, 112, 214],
643
+ "palegoldenrod": [238, 232, 170],
644
+ "palegreen": [152, 251, 152],
645
+ "paleturquoise": [175, 238, 238],
646
+ "palevioletred": [219, 112, 147],
647
+ "papayawhip": [255, 239, 213],
648
+ "peachpuff": [255, 218, 185],
649
+ "peru": [205, 133, 63],
650
+ "pink": [255, 192, 203],
651
+ "plum": [221, 160, 221],
652
+ "powderblue": [176, 224, 230],
653
+ "purple": [128, 0, 128],
654
+ "rebeccapurple": [102, 51, 153],
655
+ "red": [255, 0, 0],
656
+ "rosybrown": [188, 143, 143],
657
+ "royalblue": [65, 105, 225],
658
+ "saddlebrown": [139, 69, 19],
659
+ "salmon": [250, 128, 114],
660
+ "sandybrown": [244, 164, 96],
661
+ "seagreen": [46, 139, 87],
662
+ "seashell": [255, 245, 238],
663
+ "sienna": [160, 82, 45],
664
+ "silver": [192, 192, 192],
665
+ "skyblue": [135, 206, 235],
666
+ "slateblue": [106, 90, 205],
667
+ "slategray": [112, 128, 144],
668
+ "slategrey": [112, 128, 144],
669
+ "snow": [255, 250, 250],
670
+ "springgreen": [0, 255, 127],
671
+ "steelblue": [70, 130, 180],
672
+ "tan": [210, 180, 140],
673
+ "teal": [0, 128, 128],
674
+ "thistle": [216, 191, 216],
675
+ "tomato": [255, 99, 71],
676
+ "turquoise": [64, 224, 208],
677
+ "violet": [238, 130, 238],
678
+ "wheat": [245, 222, 179],
679
+ "white": [255, 255, 255],
680
+ "whitesmoke": [245, 245, 245],
681
+ "yellow": [255, 255, 0],
682
+ "yellowgreen": [154, 205, 50]
683
683
  };
684
684
 
685
685
  /* MIT license */
686
-
687
686
  /* eslint-disable no-mixed-operators */
687
+
688
+
688
689
  // NOTE: conversions should only return primitive values (i.e. arrays, or
689
690
  // values that give correct `typeof` results).
690
691
  // do not use box values types (i.e. Number(), String(), etc.)
691
692
 
692
693
  const reverseKeywords = {};
693
-
694
694
  for (const key of Object.keys(colorName)) {
695
- reverseKeywords[colorName[key]] = key;
695
+ reverseKeywords[colorName[key]] = key;
696
696
  }
697
697
 
698
698
  const convert$1 = {
699
- rgb: {
700
- channels: 3,
701
- labels: 'rgb'
702
- },
703
- hsl: {
704
- channels: 3,
705
- labels: 'hsl'
706
- },
707
- hsv: {
708
- channels: 3,
709
- labels: 'hsv'
710
- },
711
- hwb: {
712
- channels: 3,
713
- labels: 'hwb'
714
- },
715
- cmyk: {
716
- channels: 4,
717
- labels: 'cmyk'
718
- },
719
- xyz: {
720
- channels: 3,
721
- labels: 'xyz'
722
- },
723
- lab: {
724
- channels: 3,
725
- labels: 'lab'
726
- },
727
- lch: {
728
- channels: 3,
729
- labels: 'lch'
730
- },
731
- hex: {
732
- channels: 1,
733
- labels: ['hex']
734
- },
735
- keyword: {
736
- channels: 1,
737
- labels: ['keyword']
738
- },
739
- ansi16: {
740
- channels: 1,
741
- labels: ['ansi16']
742
- },
743
- ansi256: {
744
- channels: 1,
745
- labels: ['ansi256']
746
- },
747
- hcg: {
748
- channels: 3,
749
- labels: ['h', 'c', 'g']
750
- },
751
- apple: {
752
- channels: 3,
753
- labels: ['r16', 'g16', 'b16']
754
- },
755
- gray: {
756
- channels: 1,
757
- labels: ['gray']
758
- }
759
- };
760
- var conversions = convert$1; // Hide .channels and .labels properties
761
-
699
+ rgb: {channels: 3, labels: 'rgb'},
700
+ hsl: {channels: 3, labels: 'hsl'},
701
+ hsv: {channels: 3, labels: 'hsv'},
702
+ hwb: {channels: 3, labels: 'hwb'},
703
+ cmyk: {channels: 4, labels: 'cmyk'},
704
+ xyz: {channels: 3, labels: 'xyz'},
705
+ lab: {channels: 3, labels: 'lab'},
706
+ lch: {channels: 3, labels: 'lch'},
707
+ hex: {channels: 1, labels: ['hex']},
708
+ keyword: {channels: 1, labels: ['keyword']},
709
+ ansi16: {channels: 1, labels: ['ansi16']},
710
+ ansi256: {channels: 1, labels: ['ansi256']},
711
+ hcg: {channels: 3, labels: ['h', 'c', 'g']},
712
+ apple: {channels: 3, labels: ['r16', 'g16', 'b16']},
713
+ gray: {channels: 1, labels: ['gray']}
714
+ };
715
+
716
+ var conversions = convert$1;
717
+
718
+ // Hide .channels and .labels properties
762
719
  for (const model of Object.keys(convert$1)) {
763
- if (!('channels' in convert$1[model])) {
764
- throw new Error('missing channels property: ' + model);
765
- }
720
+ if (!('channels' in convert$1[model])) {
721
+ throw new Error('missing channels property: ' + model);
722
+ }
766
723
 
767
- if (!('labels' in convert$1[model])) {
768
- throw new Error('missing channel labels property: ' + model);
769
- }
724
+ if (!('labels' in convert$1[model])) {
725
+ throw new Error('missing channel labels property: ' + model);
726
+ }
770
727
 
771
- if (convert$1[model].labels.length !== convert$1[model].channels) {
772
- throw new Error('channel and label counts mismatch: ' + model);
773
- }
728
+ if (convert$1[model].labels.length !== convert$1[model].channels) {
729
+ throw new Error('channel and label counts mismatch: ' + model);
730
+ }
774
731
 
775
- const {
776
- channels,
777
- labels
778
- } = convert$1[model];
779
- delete convert$1[model].channels;
780
- delete convert$1[model].labels;
781
- Object.defineProperty(convert$1[model], 'channels', {
782
- value: channels
783
- });
784
- Object.defineProperty(convert$1[model], 'labels', {
785
- value: labels
786
- });
732
+ const {channels, labels} = convert$1[model];
733
+ delete convert$1[model].channels;
734
+ delete convert$1[model].labels;
735
+ Object.defineProperty(convert$1[model], 'channels', {value: channels});
736
+ Object.defineProperty(convert$1[model], 'labels', {value: labels});
787
737
  }
788
738
 
789
739
  convert$1.rgb.hsl = function (rgb) {
790
- const r = rgb[0] / 255;
791
- const g = rgb[1] / 255;
792
- const b = rgb[2] / 255;
793
- const min = Math.min(r, g, b);
794
- const max = Math.max(r, g, b);
795
- const delta = max - min;
796
- let h;
797
- let s;
798
-
799
- if (max === min) {
800
- h = 0;
801
- } else if (r === max) {
802
- h = (g - b) / delta;
803
- } else if (g === max) {
804
- h = 2 + (b - r) / delta;
805
- } else if (b === max) {
806
- h = 4 + (r - g) / delta;
807
- }
740
+ const r = rgb[0] / 255;
741
+ const g = rgb[1] / 255;
742
+ const b = rgb[2] / 255;
743
+ const min = Math.min(r, g, b);
744
+ const max = Math.max(r, g, b);
745
+ const delta = max - min;
746
+ let h;
747
+ let s;
748
+
749
+ if (max === min) {
750
+ h = 0;
751
+ } else if (r === max) {
752
+ h = (g - b) / delta;
753
+ } else if (g === max) {
754
+ h = 2 + (b - r) / delta;
755
+ } else if (b === max) {
756
+ h = 4 + (r - g) / delta;
757
+ }
808
758
 
809
- h = Math.min(h * 60, 360);
759
+ h = Math.min(h * 60, 360);
810
760
 
811
- if (h < 0) {
812
- h += 360;
813
- }
761
+ if (h < 0) {
762
+ h += 360;
763
+ }
814
764
 
815
- const l = (min + max) / 2;
765
+ const l = (min + max) / 2;
816
766
 
817
- if (max === min) {
818
- s = 0;
819
- } else if (l <= 0.5) {
820
- s = delta / (max + min);
821
- } else {
822
- s = delta / (2 - max - min);
823
- }
767
+ if (max === min) {
768
+ s = 0;
769
+ } else if (l <= 0.5) {
770
+ s = delta / (max + min);
771
+ } else {
772
+ s = delta / (2 - max - min);
773
+ }
824
774
 
825
- return [h, s * 100, l * 100];
775
+ return [h, s * 100, l * 100];
826
776
  };
827
777
 
828
778
  convert$1.rgb.hsv = function (rgb) {
829
- let rdif;
830
- let gdif;
831
- let bdif;
832
- let h;
833
- let s;
834
- const r = rgb[0] / 255;
835
- const g = rgb[1] / 255;
836
- const b = rgb[2] / 255;
837
- const v = Math.max(r, g, b);
838
- const diff = v - Math.min(r, g, b);
839
-
840
- const diffc = function (c) {
841
- return (v - c) / 6 / diff + 1 / 2;
842
- };
843
-
844
- if (diff === 0) {
845
- h = 0;
846
- s = 0;
847
- } else {
848
- s = diff / v;
849
- rdif = diffc(r);
850
- gdif = diffc(g);
851
- bdif = diffc(b);
852
-
853
- if (r === v) {
854
- h = bdif - gdif;
855
- } else if (g === v) {
856
- h = 1 / 3 + rdif - bdif;
857
- } else if (b === v) {
858
- h = 2 / 3 + gdif - rdif;
859
- }
779
+ let rdif;
780
+ let gdif;
781
+ let bdif;
782
+ let h;
783
+ let s;
784
+
785
+ const r = rgb[0] / 255;
786
+ const g = rgb[1] / 255;
787
+ const b = rgb[2] / 255;
788
+ const v = Math.max(r, g, b);
789
+ const diff = v - Math.min(r, g, b);
790
+ const diffc = function (c) {
791
+ return (v - c) / 6 / diff + 1 / 2;
792
+ };
860
793
 
861
- if (h < 0) {
862
- h += 1;
863
- } else if (h > 1) {
864
- h -= 1;
865
- }
866
- }
794
+ if (diff === 0) {
795
+ h = 0;
796
+ s = 0;
797
+ } else {
798
+ s = diff / v;
799
+ rdif = diffc(r);
800
+ gdif = diffc(g);
801
+ bdif = diffc(b);
802
+
803
+ if (r === v) {
804
+ h = bdif - gdif;
805
+ } else if (g === v) {
806
+ h = (1 / 3) + rdif - bdif;
807
+ } else if (b === v) {
808
+ h = (2 / 3) + gdif - rdif;
809
+ }
810
+
811
+ if (h < 0) {
812
+ h += 1;
813
+ } else if (h > 1) {
814
+ h -= 1;
815
+ }
816
+ }
867
817
 
868
- return [h * 360, s * 100, v * 100];
818
+ return [
819
+ h * 360,
820
+ s * 100,
821
+ v * 100
822
+ ];
869
823
  };
870
824
 
871
825
  convert$1.rgb.hwb = function (rgb) {
872
- const r = rgb[0];
873
- const g = rgb[1];
874
- let b = rgb[2];
875
- const h = convert$1.rgb.hsl(rgb)[0];
876
- const w = 1 / 255 * Math.min(r, Math.min(g, b));
877
- b = 1 - 1 / 255 * Math.max(r, Math.max(g, b));
878
- return [h, w * 100, b * 100];
826
+ const r = rgb[0];
827
+ const g = rgb[1];
828
+ let b = rgb[2];
829
+ const h = convert$1.rgb.hsl(rgb)[0];
830
+ const w = 1 / 255 * Math.min(r, Math.min(g, b));
831
+
832
+ b = 1 - 1 / 255 * Math.max(r, Math.max(g, b));
833
+
834
+ return [h, w * 100, b * 100];
879
835
  };
880
836
 
881
837
  convert$1.rgb.cmyk = function (rgb) {
882
- const r = rgb[0] / 255;
883
- const g = rgb[1] / 255;
884
- const b = rgb[2] / 255;
885
- const k = Math.min(1 - r, 1 - g, 1 - b);
886
- const c = (1 - r - k) / (1 - k) || 0;
887
- const m = (1 - g - k) / (1 - k) || 0;
888
- const y = (1 - b - k) / (1 - k) || 0;
889
- return [c * 100, m * 100, y * 100, k * 100];
838
+ const r = rgb[0] / 255;
839
+ const g = rgb[1] / 255;
840
+ const b = rgb[2] / 255;
841
+
842
+ const k = Math.min(1 - r, 1 - g, 1 - b);
843
+ const c = (1 - r - k) / (1 - k) || 0;
844
+ const m = (1 - g - k) / (1 - k) || 0;
845
+ const y = (1 - b - k) / (1 - k) || 0;
846
+
847
+ return [c * 100, m * 100, y * 100, k * 100];
890
848
  };
891
849
 
892
850
  function comparativeDistance(x, y) {
893
- /*
894
- See https://en.m.wikipedia.org/wiki/Euclidean_distance#Squared_Euclidean_distance
895
- */
896
- return (x[0] - y[0]) ** 2 + (x[1] - y[1]) ** 2 + (x[2] - y[2]) ** 2;
851
+ /*
852
+ See https://en.m.wikipedia.org/wiki/Euclidean_distance#Squared_Euclidean_distance
853
+ */
854
+ return (
855
+ ((x[0] - y[0]) ** 2) +
856
+ ((x[1] - y[1]) ** 2) +
857
+ ((x[2] - y[2]) ** 2)
858
+ );
897
859
  }
898
860
 
899
861
  convert$1.rgb.keyword = function (rgb) {
900
- const reversed = reverseKeywords[rgb];
901
-
902
- if (reversed) {
903
- return reversed;
904
- }
862
+ const reversed = reverseKeywords[rgb];
863
+ if (reversed) {
864
+ return reversed;
865
+ }
905
866
 
906
- let currentClosestDistance = Infinity;
907
- let currentClosestKeyword;
867
+ let currentClosestDistance = Infinity;
868
+ let currentClosestKeyword;
908
869
 
909
- for (const keyword of Object.keys(colorName)) {
910
- const value = colorName[keyword]; // Compute comparative distance
870
+ for (const keyword of Object.keys(colorName)) {
871
+ const value = colorName[keyword];
911
872
 
912
- const distance = comparativeDistance(rgb, value); // Check if its less, if so set as closest
873
+ // Compute comparative distance
874
+ const distance = comparativeDistance(rgb, value);
913
875
 
914
- if (distance < currentClosestDistance) {
915
- currentClosestDistance = distance;
916
- currentClosestKeyword = keyword;
917
- }
918
- }
876
+ // Check if its less, if so set as closest
877
+ if (distance < currentClosestDistance) {
878
+ currentClosestDistance = distance;
879
+ currentClosestKeyword = keyword;
880
+ }
881
+ }
919
882
 
920
- return currentClosestKeyword;
883
+ return currentClosestKeyword;
921
884
  };
922
885
 
923
886
  convert$1.keyword.rgb = function (keyword) {
924
- return colorName[keyword];
887
+ return colorName[keyword];
925
888
  };
926
889
 
927
890
  convert$1.rgb.xyz = function (rgb) {
928
- let r = rgb[0] / 255;
929
- let g = rgb[1] / 255;
930
- let b = rgb[2] / 255; // Assume sRGB
891
+ let r = rgb[0] / 255;
892
+ let g = rgb[1] / 255;
893
+ let b = rgb[2] / 255;
894
+
895
+ // Assume sRGB
896
+ r = r > 0.04045 ? (((r + 0.055) / 1.055) ** 2.4) : (r / 12.92);
897
+ g = g > 0.04045 ? (((g + 0.055) / 1.055) ** 2.4) : (g / 12.92);
898
+ b = b > 0.04045 ? (((b + 0.055) / 1.055) ** 2.4) : (b / 12.92);
931
899
 
932
- r = r > 0.04045 ? ((r + 0.055) / 1.055) ** 2.4 : r / 12.92;
933
- g = g > 0.04045 ? ((g + 0.055) / 1.055) ** 2.4 : g / 12.92;
934
- b = b > 0.04045 ? ((b + 0.055) / 1.055) ** 2.4 : b / 12.92;
935
- const x = r * 0.4124 + g * 0.3576 + b * 0.1805;
936
- const y = r * 0.2126 + g * 0.7152 + b * 0.0722;
937
- const z = r * 0.0193 + g * 0.1192 + b * 0.9505;
938
- return [x * 100, y * 100, z * 100];
900
+ const x = (r * 0.4124) + (g * 0.3576) + (b * 0.1805);
901
+ const y = (r * 0.2126) + (g * 0.7152) + (b * 0.0722);
902
+ const z = (r * 0.0193) + (g * 0.1192) + (b * 0.9505);
903
+
904
+ return [x * 100, y * 100, z * 100];
939
905
  };
940
906
 
941
907
  convert$1.rgb.lab = function (rgb) {
942
- const xyz = convert$1.rgb.xyz(rgb);
943
- let x = xyz[0];
944
- let y = xyz[1];
945
- let z = xyz[2];
946
- x /= 95.047;
947
- y /= 100;
948
- z /= 108.883;
949
- x = x > 0.008856 ? x ** (1 / 3) : 7.787 * x + 16 / 116;
950
- y = y > 0.008856 ? y ** (1 / 3) : 7.787 * y + 16 / 116;
951
- z = z > 0.008856 ? z ** (1 / 3) : 7.787 * z + 16 / 116;
952
- const l = 116 * y - 16;
953
- const a = 500 * (x - y);
954
- const b = 200 * (y - z);
955
- return [l, a, b];
908
+ const xyz = convert$1.rgb.xyz(rgb);
909
+ let x = xyz[0];
910
+ let y = xyz[1];
911
+ let z = xyz[2];
912
+
913
+ x /= 95.047;
914
+ y /= 100;
915
+ z /= 108.883;
916
+
917
+ x = x > 0.008856 ? (x ** (1 / 3)) : (7.787 * x) + (16 / 116);
918
+ y = y > 0.008856 ? (y ** (1 / 3)) : (7.787 * y) + (16 / 116);
919
+ z = z > 0.008856 ? (z ** (1 / 3)) : (7.787 * z) + (16 / 116);
920
+
921
+ const l = (116 * y) - 16;
922
+ const a = 500 * (x - y);
923
+ const b = 200 * (y - z);
924
+
925
+ return [l, a, b];
956
926
  };
957
927
 
958
928
  convert$1.hsl.rgb = function (hsl) {
959
- const h = hsl[0] / 360;
960
- const s = hsl[1] / 100;
961
- const l = hsl[2] / 100;
962
- let t2;
963
- let t3;
964
- let val;
965
-
966
- if (s === 0) {
967
- val = l * 255;
968
- return [val, val, val];
969
- }
970
-
971
- if (l < 0.5) {
972
- t2 = l * (1 + s);
973
- } else {
974
- t2 = l + s - l * s;
975
- }
929
+ const h = hsl[0] / 360;
930
+ const s = hsl[1] / 100;
931
+ const l = hsl[2] / 100;
932
+ let t2;
933
+ let t3;
934
+ let val;
935
+
936
+ if (s === 0) {
937
+ val = l * 255;
938
+ return [val, val, val];
939
+ }
976
940
 
977
- const t1 = 2 * l - t2;
978
- const rgb = [0, 0, 0];
941
+ if (l < 0.5) {
942
+ t2 = l * (1 + s);
943
+ } else {
944
+ t2 = l + s - l * s;
945
+ }
979
946
 
980
- for (let i = 0; i < 3; i++) {
981
- t3 = h + 1 / 3 * -(i - 1);
947
+ const t1 = 2 * l - t2;
982
948
 
983
- if (t3 < 0) {
984
- t3++;
985
- }
949
+ const rgb = [0, 0, 0];
950
+ for (let i = 0; i < 3; i++) {
951
+ t3 = h + 1 / 3 * -(i - 1);
952
+ if (t3 < 0) {
953
+ t3++;
954
+ }
986
955
 
987
- if (t3 > 1) {
988
- t3--;
989
- }
956
+ if (t3 > 1) {
957
+ t3--;
958
+ }
990
959
 
991
- if (6 * t3 < 1) {
992
- val = t1 + (t2 - t1) * 6 * t3;
993
- } else if (2 * t3 < 1) {
994
- val = t2;
995
- } else if (3 * t3 < 2) {
996
- val = t1 + (t2 - t1) * (2 / 3 - t3) * 6;
997
- } else {
998
- val = t1;
999
- }
960
+ if (6 * t3 < 1) {
961
+ val = t1 + (t2 - t1) * 6 * t3;
962
+ } else if (2 * t3 < 1) {
963
+ val = t2;
964
+ } else if (3 * t3 < 2) {
965
+ val = t1 + (t2 - t1) * (2 / 3 - t3) * 6;
966
+ } else {
967
+ val = t1;
968
+ }
1000
969
 
1001
- rgb[i] = val * 255;
1002
- }
970
+ rgb[i] = val * 255;
971
+ }
1003
972
 
1004
- return rgb;
973
+ return rgb;
1005
974
  };
1006
975
 
1007
976
  convert$1.hsl.hsv = function (hsl) {
1008
- const h = hsl[0];
1009
- let s = hsl[1] / 100;
1010
- let l = hsl[2] / 100;
1011
- let smin = s;
1012
- const lmin = Math.max(l, 0.01);
1013
- l *= 2;
1014
- s *= l <= 1 ? l : 2 - l;
1015
- smin *= lmin <= 1 ? lmin : 2 - lmin;
1016
- const v = (l + s) / 2;
1017
- const sv = l === 0 ? 2 * smin / (lmin + smin) : 2 * s / (l + s);
1018
- return [h, sv * 100, v * 100];
977
+ const h = hsl[0];
978
+ let s = hsl[1] / 100;
979
+ let l = hsl[2] / 100;
980
+ let smin = s;
981
+ const lmin = Math.max(l, 0.01);
982
+
983
+ l *= 2;
984
+ s *= (l <= 1) ? l : 2 - l;
985
+ smin *= lmin <= 1 ? lmin : 2 - lmin;
986
+ const v = (l + s) / 2;
987
+ const sv = l === 0 ? (2 * smin) / (lmin + smin) : (2 * s) / (l + s);
988
+
989
+ return [h, sv * 100, v * 100];
1019
990
  };
1020
991
 
1021
992
  convert$1.hsv.rgb = function (hsv) {
1022
- const h = hsv[0] / 60;
1023
- const s = hsv[1] / 100;
1024
- let v = hsv[2] / 100;
1025
- const hi = Math.floor(h) % 6;
1026
- const f = h - Math.floor(h);
1027
- const p = 255 * v * (1 - s);
1028
- const q = 255 * v * (1 - s * f);
1029
- const t = 255 * v * (1 - s * (1 - f));
1030
- v *= 255;
1031
-
1032
- switch (hi) {
1033
- case 0:
1034
- return [v, t, p];
1035
-
1036
- case 1:
1037
- return [q, v, p];
1038
-
1039
- case 2:
1040
- return [p, v, t];
1041
-
1042
- case 3:
1043
- return [p, q, v];
1044
-
1045
- case 4:
1046
- return [t, p, v];
1047
-
1048
- case 5:
1049
- return [v, p, q];
1050
- }
993
+ const h = hsv[0] / 60;
994
+ const s = hsv[1] / 100;
995
+ let v = hsv[2] / 100;
996
+ const hi = Math.floor(h) % 6;
997
+
998
+ const f = h - Math.floor(h);
999
+ const p = 255 * v * (1 - s);
1000
+ const q = 255 * v * (1 - (s * f));
1001
+ const t = 255 * v * (1 - (s * (1 - f)));
1002
+ v *= 255;
1003
+
1004
+ switch (hi) {
1005
+ case 0:
1006
+ return [v, t, p];
1007
+ case 1:
1008
+ return [q, v, p];
1009
+ case 2:
1010
+ return [p, v, t];
1011
+ case 3:
1012
+ return [p, q, v];
1013
+ case 4:
1014
+ return [t, p, v];
1015
+ case 5:
1016
+ return [v, p, q];
1017
+ }
1051
1018
  };
1052
1019
 
1053
1020
  convert$1.hsv.hsl = function (hsv) {
1054
- const h = hsv[0];
1055
- const s = hsv[1] / 100;
1056
- const v = hsv[2] / 100;
1057
- const vmin = Math.max(v, 0.01);
1058
- let sl;
1059
- let l;
1060
- l = (2 - s) * v;
1061
- const lmin = (2 - s) * vmin;
1062
- sl = s * vmin;
1063
- sl /= lmin <= 1 ? lmin : 2 - lmin;
1064
- sl = sl || 0;
1065
- l /= 2;
1066
- return [h, sl * 100, l * 100];
1067
- }; // http://dev.w3.org/csswg/css-color/#hwb-to-rgb
1021
+ const h = hsv[0];
1022
+ const s = hsv[1] / 100;
1023
+ const v = hsv[2] / 100;
1024
+ const vmin = Math.max(v, 0.01);
1025
+ let sl;
1026
+ let l;
1068
1027
 
1028
+ l = (2 - s) * v;
1029
+ const lmin = (2 - s) * vmin;
1030
+ sl = s * vmin;
1031
+ sl /= (lmin <= 1) ? lmin : 2 - lmin;
1032
+ sl = sl || 0;
1033
+ l /= 2;
1069
1034
 
1035
+ return [h, sl * 100, l * 100];
1036
+ };
1037
+
1038
+ // http://dev.w3.org/csswg/css-color/#hwb-to-rgb
1070
1039
  convert$1.hwb.rgb = function (hwb) {
1071
- const h = hwb[0] / 360;
1072
- let wh = hwb[1] / 100;
1073
- let bl = hwb[2] / 100;
1074
- const ratio = wh + bl;
1075
- let f; // Wh + bl cant be > 1
1076
-
1077
- if (ratio > 1) {
1078
- wh /= ratio;
1079
- bl /= ratio;
1080
- }
1040
+ const h = hwb[0] / 360;
1041
+ let wh = hwb[1] / 100;
1042
+ let bl = hwb[2] / 100;
1043
+ const ratio = wh + bl;
1044
+ let f;
1045
+
1046
+ // Wh + bl cant be > 1
1047
+ if (ratio > 1) {
1048
+ wh /= ratio;
1049
+ bl /= ratio;
1050
+ }
1081
1051
 
1082
- const i = Math.floor(6 * h);
1083
- const v = 1 - bl;
1084
- f = 6 * h - i;
1052
+ const i = Math.floor(6 * h);
1053
+ const v = 1 - bl;
1054
+ f = 6 * h - i;
1085
1055
 
1086
- if ((i & 0x01) !== 0) {
1087
- f = 1 - f;
1088
- }
1056
+ if ((i & 0x01) !== 0) {
1057
+ f = 1 - f;
1058
+ }
1089
1059
 
1090
- const n = wh + f * (v - wh); // Linear interpolation
1091
-
1092
- let r;
1093
- let g;
1094
- let b;
1095
- /* eslint-disable max-statements-per-line,no-multi-spaces */
1096
-
1097
- switch (i) {
1098
- default:
1099
- case 6:
1100
- case 0:
1101
- r = v;
1102
- g = n;
1103
- b = wh;
1104
- break;
1105
-
1106
- case 1:
1107
- r = n;
1108
- g = v;
1109
- b = wh;
1110
- break;
1111
-
1112
- case 2:
1113
- r = wh;
1114
- g = v;
1115
- b = n;
1116
- break;
1117
-
1118
- case 3:
1119
- r = wh;
1120
- g = n;
1121
- b = v;
1122
- break;
1123
-
1124
- case 4:
1125
- r = n;
1126
- g = wh;
1127
- b = v;
1128
- break;
1129
-
1130
- case 5:
1131
- r = v;
1132
- g = wh;
1133
- b = n;
1134
- break;
1135
- }
1136
- /* eslint-enable max-statements-per-line,no-multi-spaces */
1060
+ const n = wh + f * (v - wh); // Linear interpolation
1137
1061
 
1062
+ let r;
1063
+ let g;
1064
+ let b;
1065
+ /* eslint-disable max-statements-per-line,no-multi-spaces */
1066
+ switch (i) {
1067
+ default:
1068
+ case 6:
1069
+ case 0: r = v; g = n; b = wh; break;
1070
+ case 1: r = n; g = v; b = wh; break;
1071
+ case 2: r = wh; g = v; b = n; break;
1072
+ case 3: r = wh; g = n; b = v; break;
1073
+ case 4: r = n; g = wh; b = v; break;
1074
+ case 5: r = v; g = wh; b = n; break;
1075
+ }
1076
+ /* eslint-enable max-statements-per-line,no-multi-spaces */
1138
1077
 
1139
- return [r * 255, g * 255, b * 255];
1078
+ return [r * 255, g * 255, b * 255];
1140
1079
  };
1141
1080
 
1142
1081
  convert$1.cmyk.rgb = function (cmyk) {
1143
- const c = cmyk[0] / 100;
1144
- const m = cmyk[1] / 100;
1145
- const y = cmyk[2] / 100;
1146
- const k = cmyk[3] / 100;
1147
- const r = 1 - Math.min(1, c * (1 - k) + k);
1148
- const g = 1 - Math.min(1, m * (1 - k) + k);
1149
- const b = 1 - Math.min(1, y * (1 - k) + k);
1150
- return [r * 255, g * 255, b * 255];
1082
+ const c = cmyk[0] / 100;
1083
+ const m = cmyk[1] / 100;
1084
+ const y = cmyk[2] / 100;
1085
+ const k = cmyk[3] / 100;
1086
+
1087
+ const r = 1 - Math.min(1, c * (1 - k) + k);
1088
+ const g = 1 - Math.min(1, m * (1 - k) + k);
1089
+ const b = 1 - Math.min(1, y * (1 - k) + k);
1090
+
1091
+ return [r * 255, g * 255, b * 255];
1151
1092
  };
1152
1093
 
1153
1094
  convert$1.xyz.rgb = function (xyz) {
1154
- const x = xyz[0] / 100;
1155
- const y = xyz[1] / 100;
1156
- const z = xyz[2] / 100;
1157
- let r;
1158
- let g;
1159
- let b;
1160
- r = x * 3.2406 + y * -1.5372 + z * -0.4986;
1161
- g = x * -0.9689 + y * 1.8758 + z * 0.0415;
1162
- b = x * 0.0557 + y * -0.2040 + z * 1.0570; // Assume sRGB
1163
-
1164
- r = r > 0.0031308 ? 1.055 * r ** (1.0 / 2.4) - 0.055 : r * 12.92;
1165
- g = g > 0.0031308 ? 1.055 * g ** (1.0 / 2.4) - 0.055 : g * 12.92;
1166
- b = b > 0.0031308 ? 1.055 * b ** (1.0 / 2.4) - 0.055 : b * 12.92;
1167
- r = Math.min(Math.max(0, r), 1);
1168
- g = Math.min(Math.max(0, g), 1);
1169
- b = Math.min(Math.max(0, b), 1);
1170
- return [r * 255, g * 255, b * 255];
1095
+ const x = xyz[0] / 100;
1096
+ const y = xyz[1] / 100;
1097
+ const z = xyz[2] / 100;
1098
+ let r;
1099
+ let g;
1100
+ let b;
1101
+
1102
+ r = (x * 3.2406) + (y * -1.5372) + (z * -0.4986);
1103
+ g = (x * -0.9689) + (y * 1.8758) + (z * 0.0415);
1104
+ b = (x * 0.0557) + (y * -0.2040) + (z * 1.0570);
1105
+
1106
+ // Assume sRGB
1107
+ r = r > 0.0031308
1108
+ ? ((1.055 * (r ** (1.0 / 2.4))) - 0.055)
1109
+ : r * 12.92;
1110
+
1111
+ g = g > 0.0031308
1112
+ ? ((1.055 * (g ** (1.0 / 2.4))) - 0.055)
1113
+ : g * 12.92;
1114
+
1115
+ b = b > 0.0031308
1116
+ ? ((1.055 * (b ** (1.0 / 2.4))) - 0.055)
1117
+ : b * 12.92;
1118
+
1119
+ r = Math.min(Math.max(0, r), 1);
1120
+ g = Math.min(Math.max(0, g), 1);
1121
+ b = Math.min(Math.max(0, b), 1);
1122
+
1123
+ return [r * 255, g * 255, b * 255];
1171
1124
  };
1172
1125
 
1173
1126
  convert$1.xyz.lab = function (xyz) {
1174
- let x = xyz[0];
1175
- let y = xyz[1];
1176
- let z = xyz[2];
1177
- x /= 95.047;
1178
- y /= 100;
1179
- z /= 108.883;
1180
- x = x > 0.008856 ? x ** (1 / 3) : 7.787 * x + 16 / 116;
1181
- y = y > 0.008856 ? y ** (1 / 3) : 7.787 * y + 16 / 116;
1182
- z = z > 0.008856 ? z ** (1 / 3) : 7.787 * z + 16 / 116;
1183
- const l = 116 * y - 16;
1184
- const a = 500 * (x - y);
1185
- const b = 200 * (y - z);
1186
- return [l, a, b];
1127
+ let x = xyz[0];
1128
+ let y = xyz[1];
1129
+ let z = xyz[2];
1130
+
1131
+ x /= 95.047;
1132
+ y /= 100;
1133
+ z /= 108.883;
1134
+
1135
+ x = x > 0.008856 ? (x ** (1 / 3)) : (7.787 * x) + (16 / 116);
1136
+ y = y > 0.008856 ? (y ** (1 / 3)) : (7.787 * y) + (16 / 116);
1137
+ z = z > 0.008856 ? (z ** (1 / 3)) : (7.787 * z) + (16 / 116);
1138
+
1139
+ const l = (116 * y) - 16;
1140
+ const a = 500 * (x - y);
1141
+ const b = 200 * (y - z);
1142
+
1143
+ return [l, a, b];
1187
1144
  };
1188
1145
 
1189
1146
  convert$1.lab.xyz = function (lab) {
1190
- const l = lab[0];
1191
- const a = lab[1];
1192
- const b = lab[2];
1193
- let x;
1194
- let y;
1195
- let z;
1196
- y = (l + 16) / 116;
1197
- x = a / 500 + y;
1198
- z = y - b / 200;
1199
- const y2 = y ** 3;
1200
- const x2 = x ** 3;
1201
- const z2 = z ** 3;
1202
- y = y2 > 0.008856 ? y2 : (y - 16 / 116) / 7.787;
1203
- x = x2 > 0.008856 ? x2 : (x - 16 / 116) / 7.787;
1204
- z = z2 > 0.008856 ? z2 : (z - 16 / 116) / 7.787;
1205
- x *= 95.047;
1206
- y *= 100;
1207
- z *= 108.883;
1208
- return [x, y, z];
1147
+ const l = lab[0];
1148
+ const a = lab[1];
1149
+ const b = lab[2];
1150
+ let x;
1151
+ let y;
1152
+ let z;
1153
+
1154
+ y = (l + 16) / 116;
1155
+ x = a / 500 + y;
1156
+ z = y - b / 200;
1157
+
1158
+ const y2 = y ** 3;
1159
+ const x2 = x ** 3;
1160
+ const z2 = z ** 3;
1161
+ y = y2 > 0.008856 ? y2 : (y - 16 / 116) / 7.787;
1162
+ x = x2 > 0.008856 ? x2 : (x - 16 / 116) / 7.787;
1163
+ z = z2 > 0.008856 ? z2 : (z - 16 / 116) / 7.787;
1164
+
1165
+ x *= 95.047;
1166
+ y *= 100;
1167
+ z *= 108.883;
1168
+
1169
+ return [x, y, z];
1209
1170
  };
1210
1171
 
1211
1172
  convert$1.lab.lch = function (lab) {
1212
- const l = lab[0];
1213
- const a = lab[1];
1214
- const b = lab[2];
1215
- let h;
1216
- const hr = Math.atan2(b, a);
1217
- h = hr * 360 / 2 / Math.PI;
1218
-
1219
- if (h < 0) {
1220
- h += 360;
1221
- }
1173
+ const l = lab[0];
1174
+ const a = lab[1];
1175
+ const b = lab[2];
1176
+ let h;
1177
+
1178
+ const hr = Math.atan2(b, a);
1179
+ h = hr * 360 / 2 / Math.PI;
1222
1180
 
1223
- const c = Math.sqrt(a * a + b * b);
1224
- return [l, c, h];
1181
+ if (h < 0) {
1182
+ h += 360;
1183
+ }
1184
+
1185
+ const c = Math.sqrt(a * a + b * b);
1186
+
1187
+ return [l, c, h];
1225
1188
  };
1226
1189
 
1227
1190
  convert$1.lch.lab = function (lch) {
1228
- const l = lch[0];
1229
- const c = lch[1];
1230
- const h = lch[2];
1231
- const hr = h / 360 * 2 * Math.PI;
1232
- const a = c * Math.cos(hr);
1233
- const b = c * Math.sin(hr);
1234
- return [l, a, b];
1191
+ const l = lch[0];
1192
+ const c = lch[1];
1193
+ const h = lch[2];
1194
+
1195
+ const hr = h / 360 * 2 * Math.PI;
1196
+ const a = c * Math.cos(hr);
1197
+ const b = c * Math.sin(hr);
1198
+
1199
+ return [l, a, b];
1235
1200
  };
1236
1201
 
1237
1202
  convert$1.rgb.ansi16 = function (args, saturation = null) {
1238
- const [r, g, b] = args;
1239
- let value = saturation === null ? convert$1.rgb.hsv(args)[2] : saturation; // Hsv -> ansi16 optimization
1203
+ const [r, g, b] = args;
1204
+ let value = saturation === null ? convert$1.rgb.hsv(args)[2] : saturation; // Hsv -> ansi16 optimization
1240
1205
 
1241
- value = Math.round(value / 50);
1206
+ value = Math.round(value / 50);
1242
1207
 
1243
- if (value === 0) {
1244
- return 30;
1245
- }
1208
+ if (value === 0) {
1209
+ return 30;
1210
+ }
1246
1211
 
1247
- let ansi = 30 + (Math.round(b / 255) << 2 | Math.round(g / 255) << 1 | Math.round(r / 255));
1212
+ let ansi = 30
1213
+ + ((Math.round(b / 255) << 2)
1214
+ | (Math.round(g / 255) << 1)
1215
+ | Math.round(r / 255));
1248
1216
 
1249
- if (value === 2) {
1250
- ansi += 60;
1251
- }
1217
+ if (value === 2) {
1218
+ ansi += 60;
1219
+ }
1252
1220
 
1253
- return ansi;
1221
+ return ansi;
1254
1222
  };
1255
1223
 
1256
1224
  convert$1.hsv.ansi16 = function (args) {
1257
- // Optimization here; we already know the value and don't need to get
1258
- // it converted for us.
1259
- return convert$1.rgb.ansi16(convert$1.hsv.rgb(args), args[2]);
1225
+ // Optimization here; we already know the value and don't need to get
1226
+ // it converted for us.
1227
+ return convert$1.rgb.ansi16(convert$1.hsv.rgb(args), args[2]);
1260
1228
  };
1261
1229
 
1262
1230
  convert$1.rgb.ansi256 = function (args) {
1263
- const r = args[0];
1264
- const g = args[1];
1265
- const b = args[2]; // We use the extended greyscale palette here, with the exception of
1266
- // black and white. normal palette only has 4 greyscale shades.
1267
-
1268
- if (r === g && g === b) {
1269
- if (r < 8) {
1270
- return 16;
1271
- }
1231
+ const r = args[0];
1232
+ const g = args[1];
1233
+ const b = args[2];
1234
+
1235
+ // We use the extended greyscale palette here, with the exception of
1236
+ // black and white. normal palette only has 4 greyscale shades.
1237
+ if (r === g && g === b) {
1238
+ if (r < 8) {
1239
+ return 16;
1240
+ }
1272
1241
 
1273
- if (r > 248) {
1274
- return 231;
1275
- }
1242
+ if (r > 248) {
1243
+ return 231;
1244
+ }
1276
1245
 
1277
- return Math.round((r - 8) / 247 * 24) + 232;
1278
- }
1246
+ return Math.round(((r - 8) / 247) * 24) + 232;
1247
+ }
1248
+
1249
+ const ansi = 16
1250
+ + (36 * Math.round(r / 255 * 5))
1251
+ + (6 * Math.round(g / 255 * 5))
1252
+ + Math.round(b / 255 * 5);
1279
1253
 
1280
- const ansi = 16 + 36 * Math.round(r / 255 * 5) + 6 * Math.round(g / 255 * 5) + Math.round(b / 255 * 5);
1281
- return ansi;
1254
+ return ansi;
1282
1255
  };
1283
1256
 
1284
1257
  convert$1.ansi16.rgb = function (args) {
1285
- let color = args % 10; // Handle greyscale
1258
+ let color = args % 10;
1286
1259
 
1287
- if (color === 0 || color === 7) {
1288
- if (args > 50) {
1289
- color += 3.5;
1290
- }
1260
+ // Handle greyscale
1261
+ if (color === 0 || color === 7) {
1262
+ if (args > 50) {
1263
+ color += 3.5;
1264
+ }
1291
1265
 
1292
- color = color / 10.5 * 255;
1293
- return [color, color, color];
1294
- }
1266
+ color = color / 10.5 * 255;
1267
+
1268
+ return [color, color, color];
1269
+ }
1270
+
1271
+ const mult = (~~(args > 50) + 1) * 0.5;
1272
+ const r = ((color & 1) * mult) * 255;
1273
+ const g = (((color >> 1) & 1) * mult) * 255;
1274
+ const b = (((color >> 2) & 1) * mult) * 255;
1295
1275
 
1296
- const mult = (~~(args > 50) + 1) * 0.5;
1297
- const r = (color & 1) * mult * 255;
1298
- const g = (color >> 1 & 1) * mult * 255;
1299
- const b = (color >> 2 & 1) * mult * 255;
1300
- return [r, g, b];
1276
+ return [r, g, b];
1301
1277
  };
1302
1278
 
1303
1279
  convert$1.ansi256.rgb = function (args) {
1304
- // Handle greyscale
1305
- if (args >= 232) {
1306
- const c = (args - 232) * 10 + 8;
1307
- return [c, c, c];
1308
- }
1280
+ // Handle greyscale
1281
+ if (args >= 232) {
1282
+ const c = (args - 232) * 10 + 8;
1283
+ return [c, c, c];
1284
+ }
1309
1285
 
1310
- args -= 16;
1311
- let rem;
1312
- const r = Math.floor(args / 36) / 5 * 255;
1313
- const g = Math.floor((rem = args % 36) / 6) / 5 * 255;
1314
- const b = rem % 6 / 5 * 255;
1315
- return [r, g, b];
1286
+ args -= 16;
1287
+
1288
+ let rem;
1289
+ const r = Math.floor(args / 36) / 5 * 255;
1290
+ const g = Math.floor((rem = args % 36) / 6) / 5 * 255;
1291
+ const b = (rem % 6) / 5 * 255;
1292
+
1293
+ return [r, g, b];
1316
1294
  };
1317
1295
 
1318
1296
  convert$1.rgb.hex = function (args) {
1319
- const integer = ((Math.round(args[0]) & 0xFF) << 16) + ((Math.round(args[1]) & 0xFF) << 8) + (Math.round(args[2]) & 0xFF);
1320
- const string = integer.toString(16).toUpperCase();
1321
- return '000000'.substring(string.length) + string;
1297
+ const integer = ((Math.round(args[0]) & 0xFF) << 16)
1298
+ + ((Math.round(args[1]) & 0xFF) << 8)
1299
+ + (Math.round(args[2]) & 0xFF);
1300
+
1301
+ const string = integer.toString(16).toUpperCase();
1302
+ return '000000'.substring(string.length) + string;
1322
1303
  };
1323
1304
 
1324
1305
  convert$1.hex.rgb = function (args) {
1325
- const match = args.toString(16).match(/[a-f0-9]{6}|[a-f0-9]{3}/i);
1306
+ const match = args.toString(16).match(/[a-f0-9]{6}|[a-f0-9]{3}/i);
1307
+ if (!match) {
1308
+ return [0, 0, 0];
1309
+ }
1326
1310
 
1327
- if (!match) {
1328
- return [0, 0, 0];
1329
- }
1311
+ let colorString = match[0];
1330
1312
 
1331
- let colorString = match[0];
1313
+ if (match[0].length === 3) {
1314
+ colorString = colorString.split('').map(char => {
1315
+ return char + char;
1316
+ }).join('');
1317
+ }
1332
1318
 
1333
- if (match[0].length === 3) {
1334
- colorString = colorString.split('').map(char => {
1335
- return char + char;
1336
- }).join('');
1337
- }
1319
+ const integer = parseInt(colorString, 16);
1320
+ const r = (integer >> 16) & 0xFF;
1321
+ const g = (integer >> 8) & 0xFF;
1322
+ const b = integer & 0xFF;
1338
1323
 
1339
- const integer = parseInt(colorString, 16);
1340
- const r = integer >> 16 & 0xFF;
1341
- const g = integer >> 8 & 0xFF;
1342
- const b = integer & 0xFF;
1343
- return [r, g, b];
1324
+ return [r, g, b];
1344
1325
  };
1345
1326
 
1346
1327
  convert$1.rgb.hcg = function (rgb) {
1347
- const r = rgb[0] / 255;
1348
- const g = rgb[1] / 255;
1349
- const b = rgb[2] / 255;
1350
- const max = Math.max(Math.max(r, g), b);
1351
- const min = Math.min(Math.min(r, g), b);
1352
- const chroma = max - min;
1353
- let grayscale;
1354
- let hue;
1355
-
1356
- if (chroma < 1) {
1357
- grayscale = min / (1 - chroma);
1358
- } else {
1359
- grayscale = 0;
1360
- }
1328
+ const r = rgb[0] / 255;
1329
+ const g = rgb[1] / 255;
1330
+ const b = rgb[2] / 255;
1331
+ const max = Math.max(Math.max(r, g), b);
1332
+ const min = Math.min(Math.min(r, g), b);
1333
+ const chroma = (max - min);
1334
+ let grayscale;
1335
+ let hue;
1336
+
1337
+ if (chroma < 1) {
1338
+ grayscale = min / (1 - chroma);
1339
+ } else {
1340
+ grayscale = 0;
1341
+ }
1361
1342
 
1362
- if (chroma <= 0) {
1363
- hue = 0;
1364
- } else if (max === r) {
1365
- hue = (g - b) / chroma % 6;
1366
- } else if (max === g) {
1367
- hue = 2 + (b - r) / chroma;
1368
- } else {
1369
- hue = 4 + (r - g) / chroma;
1370
- }
1343
+ if (chroma <= 0) {
1344
+ hue = 0;
1345
+ } else
1346
+ if (max === r) {
1347
+ hue = ((g - b) / chroma) % 6;
1348
+ } else
1349
+ if (max === g) {
1350
+ hue = 2 + (b - r) / chroma;
1351
+ } else {
1352
+ hue = 4 + (r - g) / chroma;
1353
+ }
1354
+
1355
+ hue /= 6;
1356
+ hue %= 1;
1371
1357
 
1372
- hue /= 6;
1373
- hue %= 1;
1374
- return [hue * 360, chroma * 100, grayscale * 100];
1358
+ return [hue * 360, chroma * 100, grayscale * 100];
1375
1359
  };
1376
1360
 
1377
1361
  convert$1.hsl.hcg = function (hsl) {
1378
- const s = hsl[1] / 100;
1379
- const l = hsl[2] / 100;
1380
- const c = l < 0.5 ? 2.0 * s * l : 2.0 * s * (1.0 - l);
1381
- let f = 0;
1362
+ const s = hsl[1] / 100;
1363
+ const l = hsl[2] / 100;
1382
1364
 
1383
- if (c < 1.0) {
1384
- f = (l - 0.5 * c) / (1.0 - c);
1385
- }
1365
+ const c = l < 0.5 ? (2.0 * s * l) : (2.0 * s * (1.0 - l));
1386
1366
 
1387
- return [hsl[0], c * 100, f * 100];
1367
+ let f = 0;
1368
+ if (c < 1.0) {
1369
+ f = (l - 0.5 * c) / (1.0 - c);
1370
+ }
1371
+
1372
+ return [hsl[0], c * 100, f * 100];
1388
1373
  };
1389
1374
 
1390
1375
  convert$1.hsv.hcg = function (hsv) {
1391
- const s = hsv[1] / 100;
1392
- const v = hsv[2] / 100;
1393
- const c = s * v;
1394
- let f = 0;
1376
+ const s = hsv[1] / 100;
1377
+ const v = hsv[2] / 100;
1395
1378
 
1396
- if (c < 1.0) {
1397
- f = (v - c) / (1 - c);
1398
- }
1379
+ const c = s * v;
1380
+ let f = 0;
1381
+
1382
+ if (c < 1.0) {
1383
+ f = (v - c) / (1 - c);
1384
+ }
1399
1385
 
1400
- return [hsv[0], c * 100, f * 100];
1386
+ return [hsv[0], c * 100, f * 100];
1401
1387
  };
1402
1388
 
1403
1389
  convert$1.hcg.rgb = function (hcg) {
1404
- const h = hcg[0] / 360;
1405
- const c = hcg[1] / 100;
1406
- const g = hcg[2] / 100;
1390
+ const h = hcg[0] / 360;
1391
+ const c = hcg[1] / 100;
1392
+ const g = hcg[2] / 100;
1407
1393
 
1408
- if (c === 0.0) {
1409
- return [g * 255, g * 255, g * 255];
1410
- }
1394
+ if (c === 0.0) {
1395
+ return [g * 255, g * 255, g * 255];
1396
+ }
1411
1397
 
1412
- const pure = [0, 0, 0];
1413
- const hi = h % 1 * 6;
1414
- const v = hi % 1;
1415
- const w = 1 - v;
1416
- let mg = 0;
1417
- /* eslint-disable max-statements-per-line */
1418
-
1419
- switch (Math.floor(hi)) {
1420
- case 0:
1421
- pure[0] = 1;
1422
- pure[1] = v;
1423
- pure[2] = 0;
1424
- break;
1425
-
1426
- case 1:
1427
- pure[0] = w;
1428
- pure[1] = 1;
1429
- pure[2] = 0;
1430
- break;
1431
-
1432
- case 2:
1433
- pure[0] = 0;
1434
- pure[1] = 1;
1435
- pure[2] = v;
1436
- break;
1437
-
1438
- case 3:
1439
- pure[0] = 0;
1440
- pure[1] = w;
1441
- pure[2] = 1;
1442
- break;
1443
-
1444
- case 4:
1445
- pure[0] = v;
1446
- pure[1] = 0;
1447
- pure[2] = 1;
1448
- break;
1449
-
1450
- default:
1451
- pure[0] = 1;
1452
- pure[1] = 0;
1453
- pure[2] = w;
1454
- }
1455
- /* eslint-enable max-statements-per-line */
1398
+ const pure = [0, 0, 0];
1399
+ const hi = (h % 1) * 6;
1400
+ const v = hi % 1;
1401
+ const w = 1 - v;
1402
+ let mg = 0;
1403
+
1404
+ /* eslint-disable max-statements-per-line */
1405
+ switch (Math.floor(hi)) {
1406
+ case 0:
1407
+ pure[0] = 1; pure[1] = v; pure[2] = 0; break;
1408
+ case 1:
1409
+ pure[0] = w; pure[1] = 1; pure[2] = 0; break;
1410
+ case 2:
1411
+ pure[0] = 0; pure[1] = 1; pure[2] = v; break;
1412
+ case 3:
1413
+ pure[0] = 0; pure[1] = w; pure[2] = 1; break;
1414
+ case 4:
1415
+ pure[0] = v; pure[1] = 0; pure[2] = 1; break;
1416
+ default:
1417
+ pure[0] = 1; pure[1] = 0; pure[2] = w;
1418
+ }
1419
+ /* eslint-enable max-statements-per-line */
1456
1420
 
1421
+ mg = (1.0 - c) * g;
1457
1422
 
1458
- mg = (1.0 - c) * g;
1459
- return [(c * pure[0] + mg) * 255, (c * pure[1] + mg) * 255, (c * pure[2] + mg) * 255];
1423
+ return [
1424
+ (c * pure[0] + mg) * 255,
1425
+ (c * pure[1] + mg) * 255,
1426
+ (c * pure[2] + mg) * 255
1427
+ ];
1460
1428
  };
1461
1429
 
1462
1430
  convert$1.hcg.hsv = function (hcg) {
1463
- const c = hcg[1] / 100;
1464
- const g = hcg[2] / 100;
1465
- const v = c + g * (1.0 - c);
1466
- let f = 0;
1431
+ const c = hcg[1] / 100;
1432
+ const g = hcg[2] / 100;
1467
1433
 
1468
- if (v > 0.0) {
1469
- f = c / v;
1470
- }
1434
+ const v = c + g * (1.0 - c);
1435
+ let f = 0;
1436
+
1437
+ if (v > 0.0) {
1438
+ f = c / v;
1439
+ }
1471
1440
 
1472
- return [hcg[0], f * 100, v * 100];
1441
+ return [hcg[0], f * 100, v * 100];
1473
1442
  };
1474
1443
 
1475
1444
  convert$1.hcg.hsl = function (hcg) {
1476
- const c = hcg[1] / 100;
1477
- const g = hcg[2] / 100;
1478
- const l = g * (1.0 - c) + 0.5 * c;
1479
- let s = 0;
1480
-
1481
- if (l > 0.0 && l < 0.5) {
1482
- s = c / (2 * l);
1483
- } else if (l >= 0.5 && l < 1.0) {
1484
- s = c / (2 * (1 - l));
1485
- }
1445
+ const c = hcg[1] / 100;
1446
+ const g = hcg[2] / 100;
1447
+
1448
+ const l = g * (1.0 - c) + 0.5 * c;
1449
+ let s = 0;
1450
+
1451
+ if (l > 0.0 && l < 0.5) {
1452
+ s = c / (2 * l);
1453
+ } else
1454
+ if (l >= 0.5 && l < 1.0) {
1455
+ s = c / (2 * (1 - l));
1456
+ }
1486
1457
 
1487
- return [hcg[0], s * 100, l * 100];
1458
+ return [hcg[0], s * 100, l * 100];
1488
1459
  };
1489
1460
 
1490
1461
  convert$1.hcg.hwb = function (hcg) {
1491
- const c = hcg[1] / 100;
1492
- const g = hcg[2] / 100;
1493
- const v = c + g * (1.0 - c);
1494
- return [hcg[0], (v - c) * 100, (1 - v) * 100];
1462
+ const c = hcg[1] / 100;
1463
+ const g = hcg[2] / 100;
1464
+ const v = c + g * (1.0 - c);
1465
+ return [hcg[0], (v - c) * 100, (1 - v) * 100];
1495
1466
  };
1496
1467
 
1497
1468
  convert$1.hwb.hcg = function (hwb) {
1498
- const w = hwb[1] / 100;
1499
- const b = hwb[2] / 100;
1500
- const v = 1 - b;
1501
- const c = v - w;
1502
- let g = 0;
1503
-
1504
- if (c < 1) {
1505
- g = (v - c) / (1 - c);
1506
- }
1469
+ const w = hwb[1] / 100;
1470
+ const b = hwb[2] / 100;
1471
+ const v = 1 - b;
1472
+ const c = v - w;
1473
+ let g = 0;
1474
+
1475
+ if (c < 1) {
1476
+ g = (v - c) / (1 - c);
1477
+ }
1507
1478
 
1508
- return [hwb[0], c * 100, g * 100];
1479
+ return [hwb[0], c * 100, g * 100];
1509
1480
  };
1510
1481
 
1511
1482
  convert$1.apple.rgb = function (apple) {
1512
- return [apple[0] / 65535 * 255, apple[1] / 65535 * 255, apple[2] / 65535 * 255];
1483
+ return [(apple[0] / 65535) * 255, (apple[1] / 65535) * 255, (apple[2] / 65535) * 255];
1513
1484
  };
1514
1485
 
1515
1486
  convert$1.rgb.apple = function (rgb) {
1516
- return [rgb[0] / 255 * 65535, rgb[1] / 255 * 65535, rgb[2] / 255 * 65535];
1487
+ return [(rgb[0] / 255) * 65535, (rgb[1] / 255) * 65535, (rgb[2] / 255) * 65535];
1517
1488
  };
1518
1489
 
1519
1490
  convert$1.gray.rgb = function (args) {
1520
- return [args[0] / 100 * 255, args[0] / 100 * 255, args[0] / 100 * 255];
1491
+ return [args[0] / 100 * 255, args[0] / 100 * 255, args[0] / 100 * 255];
1521
1492
  };
1522
1493
 
1523
1494
  convert$1.gray.hsl = function (args) {
1524
- return [0, 0, args[0]];
1495
+ return [0, 0, args[0]];
1525
1496
  };
1526
1497
 
1527
1498
  convert$1.gray.hsv = convert$1.gray.hsl;
1528
1499
 
1529
1500
  convert$1.gray.hwb = function (gray) {
1530
- return [0, 100, gray[0]];
1501
+ return [0, 100, gray[0]];
1531
1502
  };
1532
1503
 
1533
1504
  convert$1.gray.cmyk = function (gray) {
1534
- return [0, 0, 0, gray[0]];
1505
+ return [0, 0, 0, gray[0]];
1535
1506
  };
1536
1507
 
1537
1508
  convert$1.gray.lab = function (gray) {
1538
- return [gray[0], 0, 0];
1509
+ return [gray[0], 0, 0];
1539
1510
  };
1540
1511
 
1541
1512
  convert$1.gray.hex = function (gray) {
1542
- const val = Math.round(gray[0] / 100 * 255) & 0xFF;
1543
- const integer = (val << 16) + (val << 8) + val;
1544
- const string = integer.toString(16).toUpperCase();
1545
- return '000000'.substring(string.length) + string;
1513
+ const val = Math.round(gray[0] / 100 * 255) & 0xFF;
1514
+ const integer = (val << 16) + (val << 8) + val;
1515
+
1516
+ const string = integer.toString(16).toUpperCase();
1517
+ return '000000'.substring(string.length) + string;
1546
1518
  };
1547
1519
 
1548
1520
  convert$1.rgb.gray = function (rgb) {
1549
- const val = (rgb[0] + rgb[1] + rgb[2]) / 3;
1550
- return [val / 255 * 100];
1521
+ const val = (rgb[0] + rgb[1] + rgb[2]) / 3;
1522
+ return [val / 255 * 100];
1551
1523
  };
1552
1524
 
1553
1525
  /*
@@ -1562,646 +1534,658 @@ convert$1.rgb.gray = function (rgb) {
1562
1534
  */
1563
1535
 
1564
1536
  function buildGraph() {
1565
- const graph = {}; // https://jsperf.com/object-keys-vs-for-in-with-closure/3
1566
-
1567
- const models = Object.keys(conversions);
1568
-
1569
- for (let len = models.length, i = 0; i < len; i++) {
1570
- graph[models[i]] = {
1571
- // http://jsperf.com/1-vs-infinity
1572
- // micro-opt, but this is simple.
1573
- distance: -1,
1574
- parent: null
1575
- };
1576
- }
1577
-
1578
- return graph;
1579
- } // https://en.wikipedia.org/wiki/Breadth-first_search
1537
+ const graph = {};
1538
+ // https://jsperf.com/object-keys-vs-for-in-with-closure/3
1539
+ const models = Object.keys(conversions);
1540
+
1541
+ for (let len = models.length, i = 0; i < len; i++) {
1542
+ graph[models[i]] = {
1543
+ // http://jsperf.com/1-vs-infinity
1544
+ // micro-opt, but this is simple.
1545
+ distance: -1,
1546
+ parent: null
1547
+ };
1548
+ }
1580
1549
 
1550
+ return graph;
1551
+ }
1581
1552
 
1553
+ // https://en.wikipedia.org/wiki/Breadth-first_search
1582
1554
  function deriveBFS(fromModel) {
1583
- const graph = buildGraph();
1584
- const queue = [fromModel]; // Unshift -> queue -> pop
1555
+ const graph = buildGraph();
1556
+ const queue = [fromModel]; // Unshift -> queue -> pop
1585
1557
 
1586
- graph[fromModel].distance = 0;
1558
+ graph[fromModel].distance = 0;
1587
1559
 
1588
- while (queue.length) {
1589
- const current = queue.pop();
1590
- const adjacents = Object.keys(conversions[current]);
1560
+ while (queue.length) {
1561
+ const current = queue.pop();
1562
+ const adjacents = Object.keys(conversions[current]);
1591
1563
 
1592
- for (let len = adjacents.length, i = 0; i < len; i++) {
1593
- const adjacent = adjacents[i];
1594
- const node = graph[adjacent];
1564
+ for (let len = adjacents.length, i = 0; i < len; i++) {
1565
+ const adjacent = adjacents[i];
1566
+ const node = graph[adjacent];
1595
1567
 
1596
- if (node.distance === -1) {
1597
- node.distance = graph[current].distance + 1;
1598
- node.parent = current;
1599
- queue.unshift(adjacent);
1600
- }
1601
- }
1602
- }
1568
+ if (node.distance === -1) {
1569
+ node.distance = graph[current].distance + 1;
1570
+ node.parent = current;
1571
+ queue.unshift(adjacent);
1572
+ }
1573
+ }
1574
+ }
1603
1575
 
1604
- return graph;
1576
+ return graph;
1605
1577
  }
1606
1578
 
1607
1579
  function link(from, to) {
1608
- return function (args) {
1609
- return to(from(args));
1610
- };
1580
+ return function (args) {
1581
+ return to(from(args));
1582
+ };
1611
1583
  }
1612
1584
 
1613
1585
  function wrapConversion(toModel, graph) {
1614
- const path = [graph[toModel].parent, toModel];
1615
- let fn = conversions[graph[toModel].parent][toModel];
1616
- let cur = graph[toModel].parent;
1617
-
1618
- while (graph[cur].parent) {
1619
- path.unshift(graph[cur].parent);
1620
- fn = link(conversions[graph[cur].parent][cur], fn);
1621
- cur = graph[cur].parent;
1622
- }
1586
+ const path = [graph[toModel].parent, toModel];
1587
+ let fn = conversions[graph[toModel].parent][toModel];
1588
+
1589
+ let cur = graph[toModel].parent;
1590
+ while (graph[cur].parent) {
1591
+ path.unshift(graph[cur].parent);
1592
+ fn = link(conversions[graph[cur].parent][cur], fn);
1593
+ cur = graph[cur].parent;
1594
+ }
1623
1595
 
1624
- fn.conversion = path;
1625
- return fn;
1596
+ fn.conversion = path;
1597
+ return fn;
1626
1598
  }
1627
1599
 
1628
1600
  var route = function (fromModel) {
1629
- const graph = deriveBFS(fromModel);
1630
- const conversion = {};
1631
- const models = Object.keys(graph);
1601
+ const graph = deriveBFS(fromModel);
1602
+ const conversion = {};
1632
1603
 
1633
- for (let len = models.length, i = 0; i < len; i++) {
1634
- const toModel = models[i];
1635
- const node = graph[toModel];
1604
+ const models = Object.keys(graph);
1605
+ for (let len = models.length, i = 0; i < len; i++) {
1606
+ const toModel = models[i];
1607
+ const node = graph[toModel];
1636
1608
 
1637
- if (node.parent === null) {
1638
- // No possible conversion, or this node is the source model.
1639
- continue;
1640
- }
1609
+ if (node.parent === null) {
1610
+ // No possible conversion, or this node is the source model.
1611
+ continue;
1612
+ }
1641
1613
 
1642
- conversion[toModel] = wrapConversion(toModel, graph);
1643
- }
1614
+ conversion[toModel] = wrapConversion(toModel, graph);
1615
+ }
1644
1616
 
1645
- return conversion;
1617
+ return conversion;
1646
1618
  };
1647
1619
 
1648
1620
  const convert = {};
1621
+
1649
1622
  const models = Object.keys(conversions);
1650
1623
 
1651
1624
  function wrapRaw(fn) {
1652
- const wrappedFn = function (...args) {
1653
- const arg0 = args[0];
1654
-
1655
- if (arg0 === undefined || arg0 === null) {
1656
- return arg0;
1657
- }
1658
-
1659
- if (arg0.length > 1) {
1660
- args = arg0;
1661
- }
1625
+ const wrappedFn = function (...args) {
1626
+ const arg0 = args[0];
1627
+ if (arg0 === undefined || arg0 === null) {
1628
+ return arg0;
1629
+ }
1662
1630
 
1663
- return fn(args);
1664
- }; // Preserve .conversion property if there is one
1631
+ if (arg0.length > 1) {
1632
+ args = arg0;
1633
+ }
1665
1634
 
1635
+ return fn(args);
1636
+ };
1666
1637
 
1667
- if ('conversion' in fn) {
1668
- wrappedFn.conversion = fn.conversion;
1669
- }
1638
+ // Preserve .conversion property if there is one
1639
+ if ('conversion' in fn) {
1640
+ wrappedFn.conversion = fn.conversion;
1641
+ }
1670
1642
 
1671
- return wrappedFn;
1643
+ return wrappedFn;
1672
1644
  }
1673
1645
 
1674
1646
  function wrapRounded(fn) {
1675
- const wrappedFn = function (...args) {
1676
- const arg0 = args[0];
1677
-
1678
- if (arg0 === undefined || arg0 === null) {
1679
- return arg0;
1680
- }
1647
+ const wrappedFn = function (...args) {
1648
+ const arg0 = args[0];
1681
1649
 
1682
- if (arg0.length > 1) {
1683
- args = arg0;
1684
- }
1650
+ if (arg0 === undefined || arg0 === null) {
1651
+ return arg0;
1652
+ }
1685
1653
 
1686
- const result = fn(args); // We're assuming the result is an array here.
1687
- // see notice in conversions.js; don't use box types
1688
- // in conversion functions.
1654
+ if (arg0.length > 1) {
1655
+ args = arg0;
1656
+ }
1689
1657
 
1690
- if (typeof result === 'object') {
1691
- for (let len = result.length, i = 0; i < len; i++) {
1692
- result[i] = Math.round(result[i]);
1693
- }
1694
- }
1658
+ const result = fn(args);
1695
1659
 
1696
- return result;
1697
- }; // Preserve .conversion property if there is one
1660
+ // We're assuming the result is an array here.
1661
+ // see notice in conversions.js; don't use box types
1662
+ // in conversion functions.
1663
+ if (typeof result === 'object') {
1664
+ for (let len = result.length, i = 0; i < len; i++) {
1665
+ result[i] = Math.round(result[i]);
1666
+ }
1667
+ }
1698
1668
 
1669
+ return result;
1670
+ };
1699
1671
 
1700
- if ('conversion' in fn) {
1701
- wrappedFn.conversion = fn.conversion;
1702
- }
1672
+ // Preserve .conversion property if there is one
1673
+ if ('conversion' in fn) {
1674
+ wrappedFn.conversion = fn.conversion;
1675
+ }
1703
1676
 
1704
- return wrappedFn;
1677
+ return wrappedFn;
1705
1678
  }
1706
1679
 
1707
1680
  models.forEach(fromModel => {
1708
- convert[fromModel] = {};
1709
- Object.defineProperty(convert[fromModel], 'channels', {
1710
- value: conversions[fromModel].channels
1711
- });
1712
- Object.defineProperty(convert[fromModel], 'labels', {
1713
- value: conversions[fromModel].labels
1714
- });
1715
- const routes = route(fromModel);
1716
- const routeModels = Object.keys(routes);
1717
- routeModels.forEach(toModel => {
1718
- const fn = routes[toModel];
1719
- convert[fromModel][toModel] = wrapRounded(fn);
1720
- convert[fromModel][toModel].raw = wrapRaw(fn);
1721
- });
1681
+ convert[fromModel] = {};
1682
+
1683
+ Object.defineProperty(convert[fromModel], 'channels', {value: conversions[fromModel].channels});
1684
+ Object.defineProperty(convert[fromModel], 'labels', {value: conversions[fromModel].labels});
1685
+
1686
+ const routes = route(fromModel);
1687
+ const routeModels = Object.keys(routes);
1688
+
1689
+ routeModels.forEach(toModel => {
1690
+ const fn = routes[toModel];
1691
+
1692
+ convert[fromModel][toModel] = wrapRounded(fn);
1693
+ convert[fromModel][toModel].raw = wrapRaw(fn);
1694
+ });
1722
1695
  });
1696
+
1723
1697
  var colorConvert = convert;
1724
1698
 
1725
- const skippedModels = [// To be honest, I don't really feel like keyword belongs in color convert, but eh.
1726
- 'keyword', // Gray conflicts with some method names, and has its own method defined.
1727
- 'gray', // Shouldn't really be in color-convert either...
1728
- 'hex'];
1729
- const hashedModelKeys = {};
1699
+ const skippedModels = [
1700
+ // To be honest, I don't really feel like keyword belongs in color convert, but eh.
1701
+ 'keyword',
1702
+
1703
+ // Gray conflicts with some method names, and has its own method defined.
1704
+ 'gray',
1730
1705
 
1706
+ // Shouldn't really be in color-convert either...
1707
+ 'hex',
1708
+ ];
1709
+
1710
+ const hashedModelKeys = {};
1731
1711
  for (const model of Object.keys(colorConvert)) {
1732
- hashedModelKeys[[...colorConvert[model].labels].sort().join('')] = model;
1712
+ hashedModelKeys[[...colorConvert[model].labels].sort().join('')] = model;
1733
1713
  }
1734
1714
 
1735
1715
  const limiters = {};
1736
1716
 
1737
1717
  function Color(object, model) {
1738
- if (!(this instanceof Color)) {
1739
- return new Color(object, model);
1740
- }
1741
-
1742
- if (model && model in skippedModels) {
1743
- model = null;
1744
- }
1745
-
1746
- if (model && !(model in colorConvert)) {
1747
- throw new Error('Unknown model: ' + model);
1748
- }
1749
-
1750
- let i;
1751
- let channels;
1752
-
1753
- if (object == null) {
1754
- // eslint-disable-line no-eq-null,eqeqeq
1755
- this.model = 'rgb';
1756
- this.color = [0, 0, 0];
1757
- this.valpha = 1;
1758
- } else if (object instanceof Color) {
1759
- this.model = object.model;
1760
- this.color = [...object.color];
1761
- this.valpha = object.valpha;
1762
- } else if (typeof object === 'string') {
1763
- const result = colorString.get(object);
1764
-
1765
- if (result === null) {
1766
- throw new Error('Unable to parse color from string: ' + object);
1767
- }
1718
+ if (!(this instanceof Color)) {
1719
+ return new Color(object, model);
1720
+ }
1768
1721
 
1769
- this.model = result.model;
1770
- channels = colorConvert[this.model].channels;
1771
- this.color = result.value.slice(0, channels);
1772
- this.valpha = typeof result.value[channels] === 'number' ? result.value[channels] : 1;
1773
- } else if (object.length > 0) {
1774
- this.model = model || 'rgb';
1775
- channels = colorConvert[this.model].channels;
1776
- const newArray = Array.prototype.slice.call(object, 0, channels);
1777
- this.color = zeroArray(newArray, channels);
1778
- this.valpha = typeof object[channels] === 'number' ? object[channels] : 1;
1779
- } else if (typeof object === 'number') {
1780
- // This is always RGB - can be converted later on.
1781
- this.model = 'rgb';
1782
- this.color = [object >> 16 & 0xFF, object >> 8 & 0xFF, object & 0xFF];
1783
- this.valpha = 1;
1784
- } else {
1785
- this.valpha = 1;
1786
- const keys = Object.keys(object);
1787
-
1788
- if ('alpha' in object) {
1789
- keys.splice(keys.indexOf('alpha'), 1);
1790
- this.valpha = typeof object.alpha === 'number' ? object.alpha : 0;
1791
- }
1722
+ if (model && model in skippedModels) {
1723
+ model = null;
1724
+ }
1792
1725
 
1793
- const hashedKeys = keys.sort().join('');
1726
+ if (model && !(model in colorConvert)) {
1727
+ throw new Error('Unknown model: ' + model);
1728
+ }
1794
1729
 
1795
- if (!(hashedKeys in hashedModelKeys)) {
1796
- throw new Error('Unable to parse color from object: ' + JSON.stringify(object));
1797
- }
1730
+ let i;
1731
+ let channels;
1732
+
1733
+ if (object == null) { // eslint-disable-line no-eq-null,eqeqeq
1734
+ this.model = 'rgb';
1735
+ this.color = [0, 0, 0];
1736
+ this.valpha = 1;
1737
+ } else if (object instanceof Color) {
1738
+ this.model = object.model;
1739
+ this.color = [...object.color];
1740
+ this.valpha = object.valpha;
1741
+ } else if (typeof object === 'string') {
1742
+ const result = colorString.get(object);
1743
+ if (result === null) {
1744
+ throw new Error('Unable to parse color from string: ' + object);
1745
+ }
1798
1746
 
1799
- this.model = hashedModelKeys[hashedKeys];
1800
- const {
1801
- labels
1802
- } = colorConvert[this.model];
1803
- const color = [];
1747
+ this.model = result.model;
1748
+ channels = colorConvert[this.model].channels;
1749
+ this.color = result.value.slice(0, channels);
1750
+ this.valpha = typeof result.value[channels] === 'number' ? result.value[channels] : 1;
1751
+ } else if (object.length > 0) {
1752
+ this.model = model || 'rgb';
1753
+ channels = colorConvert[this.model].channels;
1754
+ const newArray = Array.prototype.slice.call(object, 0, channels);
1755
+ this.color = zeroArray(newArray, channels);
1756
+ this.valpha = typeof object[channels] === 'number' ? object[channels] : 1;
1757
+ } else if (typeof object === 'number') {
1758
+ // This is always RGB - can be converted later on.
1759
+ this.model = 'rgb';
1760
+ this.color = [
1761
+ (object >> 16) & 0xFF,
1762
+ (object >> 8) & 0xFF,
1763
+ object & 0xFF,
1764
+ ];
1765
+ this.valpha = 1;
1766
+ } else {
1767
+ this.valpha = 1;
1804
1768
 
1805
- for (i = 0; i < labels.length; i++) {
1806
- color.push(object[labels[i]]);
1807
- }
1769
+ const keys = Object.keys(object);
1770
+ if ('alpha' in object) {
1771
+ keys.splice(keys.indexOf('alpha'), 1);
1772
+ this.valpha = typeof object.alpha === 'number' ? object.alpha : 0;
1773
+ }
1808
1774
 
1809
- this.color = zeroArray(color);
1810
- } // Perform limitations (clamping, etc.)
1775
+ const hashedKeys = keys.sort().join('');
1776
+ if (!(hashedKeys in hashedModelKeys)) {
1777
+ throw new Error('Unable to parse color from object: ' + JSON.stringify(object));
1778
+ }
1811
1779
 
1780
+ this.model = hashedModelKeys[hashedKeys];
1812
1781
 
1813
- if (limiters[this.model]) {
1814
- channels = colorConvert[this.model].channels;
1782
+ const {labels} = colorConvert[this.model];
1783
+ const color = [];
1784
+ for (i = 0; i < labels.length; i++) {
1785
+ color.push(object[labels[i]]);
1786
+ }
1815
1787
 
1816
- for (i = 0; i < channels; i++) {
1817
- const limit = limiters[this.model][i];
1788
+ this.color = zeroArray(color);
1789
+ }
1818
1790
 
1819
- if (limit) {
1820
- this.color[i] = limit(this.color[i]);
1821
- }
1822
- }
1823
- }
1791
+ // Perform limitations (clamping, etc.)
1792
+ if (limiters[this.model]) {
1793
+ channels = colorConvert[this.model].channels;
1794
+ for (i = 0; i < channels; i++) {
1795
+ const limit = limiters[this.model][i];
1796
+ if (limit) {
1797
+ this.color[i] = limit(this.color[i]);
1798
+ }
1799
+ }
1800
+ }
1824
1801
 
1825
- this.valpha = Math.max(0, Math.min(1, this.valpha));
1802
+ this.valpha = Math.max(0, Math.min(1, this.valpha));
1826
1803
 
1827
- if (Object.freeze) {
1828
- Object.freeze(this);
1829
- }
1804
+ if (Object.freeze) {
1805
+ Object.freeze(this);
1806
+ }
1830
1807
  }
1831
1808
 
1832
1809
  Color.prototype = {
1833
- toString() {
1834
- return this.string();
1835
- },
1836
-
1837
- toJSON() {
1838
- return this[this.model]();
1839
- },
1840
-
1841
- string(places) {
1842
- let self = this.model in colorString.to ? this : this.rgb();
1843
- self = self.round(typeof places === 'number' ? places : 1);
1844
- const args = self.valpha === 1 ? self.color : [...self.color, this.valpha];
1845
- return colorString.to[self.model](args);
1846
- },
1847
-
1848
- percentString(places) {
1849
- const self = this.rgb().round(typeof places === 'number' ? places : 1);
1850
- const args = self.valpha === 1 ? self.color : [...self.color, this.valpha];
1851
- return colorString.to.rgb.percent(args);
1852
- },
1853
-
1854
- array() {
1855
- return this.valpha === 1 ? [...this.color] : [...this.color, this.valpha];
1856
- },
1857
-
1858
- object() {
1859
- const result = {};
1860
- const {
1861
- channels
1862
- } = colorConvert[this.model];
1863
- const {
1864
- labels
1865
- } = colorConvert[this.model];
1866
-
1867
- for (let i = 0; i < channels; i++) {
1868
- result[labels[i]] = this.color[i];
1869
- }
1870
-
1871
- if (this.valpha !== 1) {
1872
- result.alpha = this.valpha;
1873
- }
1874
-
1875
- return result;
1876
- },
1810
+ toString() {
1811
+ return this.string();
1812
+ },
1813
+
1814
+ toJSON() {
1815
+ return this[this.model]();
1816
+ },
1817
+
1818
+ string(places) {
1819
+ let self = this.model in colorString.to ? this : this.rgb();
1820
+ self = self.round(typeof places === 'number' ? places : 1);
1821
+ const args = self.valpha === 1 ? self.color : [...self.color, this.valpha];
1822
+ return colorString.to[self.model](args);
1823
+ },
1824
+
1825
+ percentString(places) {
1826
+ const self = this.rgb().round(typeof places === 'number' ? places : 1);
1827
+ const args = self.valpha === 1 ? self.color : [...self.color, this.valpha];
1828
+ return colorString.to.rgb.percent(args);
1829
+ },
1830
+
1831
+ array() {
1832
+ return this.valpha === 1 ? [...this.color] : [...this.color, this.valpha];
1833
+ },
1834
+
1835
+ object() {
1836
+ const result = {};
1837
+ const {channels} = colorConvert[this.model];
1838
+ const {labels} = colorConvert[this.model];
1839
+
1840
+ for (let i = 0; i < channels; i++) {
1841
+ result[labels[i]] = this.color[i];
1842
+ }
1877
1843
 
1878
- unitArray() {
1879
- const rgb = this.rgb().color;
1880
- rgb[0] /= 255;
1881
- rgb[1] /= 255;
1882
- rgb[2] /= 255;
1844
+ if (this.valpha !== 1) {
1845
+ result.alpha = this.valpha;
1846
+ }
1883
1847
 
1884
- if (this.valpha !== 1) {
1885
- rgb.push(this.valpha);
1886
- }
1848
+ return result;
1849
+ },
1887
1850
 
1888
- return rgb;
1889
- },
1851
+ unitArray() {
1852
+ const rgb = this.rgb().color;
1853
+ rgb[0] /= 255;
1854
+ rgb[1] /= 255;
1855
+ rgb[2] /= 255;
1890
1856
 
1891
- unitObject() {
1892
- const rgb = this.rgb().object();
1893
- rgb.r /= 255;
1894
- rgb.g /= 255;
1895
- rgb.b /= 255;
1857
+ if (this.valpha !== 1) {
1858
+ rgb.push(this.valpha);
1859
+ }
1896
1860
 
1897
- if (this.valpha !== 1) {
1898
- rgb.alpha = this.valpha;
1899
- }
1861
+ return rgb;
1862
+ },
1900
1863
 
1901
- return rgb;
1902
- },
1864
+ unitObject() {
1865
+ const rgb = this.rgb().object();
1866
+ rgb.r /= 255;
1867
+ rgb.g /= 255;
1868
+ rgb.b /= 255;
1903
1869
 
1904
- round(places) {
1905
- places = Math.max(places || 0, 0);
1906
- return new Color([...this.color.map(roundToPlace(places)), this.valpha], this.model);
1907
- },
1870
+ if (this.valpha !== 1) {
1871
+ rgb.alpha = this.valpha;
1872
+ }
1908
1873
 
1909
- alpha(value) {
1910
- if (value !== undefined) {
1911
- return new Color([...this.color, Math.max(0, Math.min(1, value))], this.model);
1912
- }
1874
+ return rgb;
1875
+ },
1913
1876
 
1914
- return this.valpha;
1915
- },
1877
+ round(places) {
1878
+ places = Math.max(places || 0, 0);
1879
+ return new Color([...this.color.map(roundToPlace(places)), this.valpha], this.model);
1880
+ },
1916
1881
 
1917
- // Rgb
1918
- red: getset('rgb', 0, maxfn(255)),
1919
- green: getset('rgb', 1, maxfn(255)),
1920
- blue: getset('rgb', 2, maxfn(255)),
1921
- hue: getset(['hsl', 'hsv', 'hsl', 'hwb', 'hcg'], 0, value => (value % 360 + 360) % 360),
1922
- saturationl: getset('hsl', 1, maxfn(100)),
1923
- lightness: getset('hsl', 2, maxfn(100)),
1924
- saturationv: getset('hsv', 1, maxfn(100)),
1925
- value: getset('hsv', 2, maxfn(100)),
1926
- chroma: getset('hcg', 1, maxfn(100)),
1927
- gray: getset('hcg', 2, maxfn(100)),
1928
- white: getset('hwb', 1, maxfn(100)),
1929
- wblack: getset('hwb', 2, maxfn(100)),
1930
- cyan: getset('cmyk', 0, maxfn(100)),
1931
- magenta: getset('cmyk', 1, maxfn(100)),
1932
- yellow: getset('cmyk', 2, maxfn(100)),
1933
- black: getset('cmyk', 3, maxfn(100)),
1934
- x: getset('xyz', 0, maxfn(95.047)),
1935
- y: getset('xyz', 1, maxfn(100)),
1936
- z: getset('xyz', 2, maxfn(108.833)),
1937
- l: getset('lab', 0, maxfn(100)),
1938
- a: getset('lab', 1),
1939
- b: getset('lab', 2),
1940
-
1941
- keyword(value) {
1942
- if (value !== undefined) {
1943
- return new Color(value);
1944
- }
1882
+ alpha(value) {
1883
+ if (value !== undefined) {
1884
+ return new Color([...this.color, Math.max(0, Math.min(1, value))], this.model);
1885
+ }
1945
1886
 
1946
- return colorConvert[this.model].keyword(this.color);
1947
- },
1887
+ return this.valpha;
1888
+ },
1948
1889
 
1949
- hex(value) {
1950
- if (value !== undefined) {
1951
- return new Color(value);
1952
- }
1890
+ // Rgb
1891
+ red: getset('rgb', 0, maxfn(255)),
1892
+ green: getset('rgb', 1, maxfn(255)),
1893
+ blue: getset('rgb', 2, maxfn(255)),
1953
1894
 
1954
- return colorString.to.hex(this.rgb().round().color);
1955
- },
1895
+ hue: getset(['hsl', 'hsv', 'hsl', 'hwb', 'hcg'], 0, value => ((value % 360) + 360) % 360),
1956
1896
 
1957
- hexa(value) {
1958
- if (value !== undefined) {
1959
- return new Color(value);
1960
- }
1897
+ saturationl: getset('hsl', 1, maxfn(100)),
1898
+ lightness: getset('hsl', 2, maxfn(100)),
1961
1899
 
1962
- const rgbArray = this.rgb().round().color;
1963
- let alphaHex = Math.round(this.valpha * 255).toString(16).toUpperCase();
1900
+ saturationv: getset('hsv', 1, maxfn(100)),
1901
+ value: getset('hsv', 2, maxfn(100)),
1964
1902
 
1965
- if (alphaHex.length === 1) {
1966
- alphaHex = '0' + alphaHex;
1967
- }
1903
+ chroma: getset('hcg', 1, maxfn(100)),
1904
+ gray: getset('hcg', 2, maxfn(100)),
1968
1905
 
1969
- return colorString.to.hex(rgbArray) + alphaHex;
1970
- },
1906
+ white: getset('hwb', 1, maxfn(100)),
1907
+ wblack: getset('hwb', 2, maxfn(100)),
1971
1908
 
1972
- rgbNumber() {
1973
- const rgb = this.rgb().color;
1974
- return (rgb[0] & 0xFF) << 16 | (rgb[1] & 0xFF) << 8 | rgb[2] & 0xFF;
1975
- },
1909
+ cyan: getset('cmyk', 0, maxfn(100)),
1910
+ magenta: getset('cmyk', 1, maxfn(100)),
1911
+ yellow: getset('cmyk', 2, maxfn(100)),
1912
+ black: getset('cmyk', 3, maxfn(100)),
1976
1913
 
1977
- luminosity() {
1978
- // http://www.w3.org/TR/WCAG20/#relativeluminancedef
1979
- const rgb = this.rgb().color;
1980
- const lum = [];
1914
+ x: getset('xyz', 0, maxfn(95.047)),
1915
+ y: getset('xyz', 1, maxfn(100)),
1916
+ z: getset('xyz', 2, maxfn(108.833)),
1981
1917
 
1982
- for (const [i, element] of rgb.entries()) {
1983
- const chan = element / 255;
1984
- lum[i] = chan <= 0.04045 ? chan / 12.92 : ((chan + 0.055) / 1.055) ** 2.4;
1985
- }
1918
+ l: getset('lab', 0, maxfn(100)),
1919
+ a: getset('lab', 1),
1920
+ b: getset('lab', 2),
1986
1921
 
1987
- return 0.2126 * lum[0] + 0.7152 * lum[1] + 0.0722 * lum[2];
1988
- },
1922
+ keyword(value) {
1923
+ if (value !== undefined) {
1924
+ return new Color(value);
1925
+ }
1989
1926
 
1990
- contrast(color2) {
1991
- // http://www.w3.org/TR/WCAG20/#contrast-ratiodef
1992
- const lum1 = this.luminosity();
1993
- const lum2 = color2.luminosity();
1927
+ return colorConvert[this.model].keyword(this.color);
1928
+ },
1994
1929
 
1995
- if (lum1 > lum2) {
1996
- return (lum1 + 0.05) / (lum2 + 0.05);
1997
- }
1930
+ hex(value) {
1931
+ if (value !== undefined) {
1932
+ return new Color(value);
1933
+ }
1998
1934
 
1999
- return (lum2 + 0.05) / (lum1 + 0.05);
2000
- },
1935
+ return colorString.to.hex(this.rgb().round().color);
1936
+ },
2001
1937
 
2002
- level(color2) {
2003
- // https://www.w3.org/TR/WCAG/#contrast-enhanced
2004
- const contrastRatio = this.contrast(color2);
1938
+ hexa(value) {
1939
+ if (value !== undefined) {
1940
+ return new Color(value);
1941
+ }
2005
1942
 
2006
- if (contrastRatio >= 7) {
2007
- return 'AAA';
2008
- }
1943
+ const rgbArray = this.rgb().round().color;
2009
1944
 
2010
- return contrastRatio >= 4.5 ? 'AA' : '';
2011
- },
1945
+ let alphaHex = Math.round(this.valpha * 255).toString(16).toUpperCase();
1946
+ if (alphaHex.length === 1) {
1947
+ alphaHex = '0' + alphaHex;
1948
+ }
2012
1949
 
2013
- isDark() {
2014
- // YIQ equation from http://24ways.org/2010/calculating-color-contrast
2015
- const rgb = this.rgb().color;
2016
- const yiq = (rgb[0] * 2126 + rgb[1] * 7152 + rgb[2] * 722) / 10000;
2017
- return yiq < 128;
2018
- },
1950
+ return colorString.to.hex(rgbArray) + alphaHex;
1951
+ },
2019
1952
 
2020
- isLight() {
2021
- return !this.isDark();
2022
- },
1953
+ rgbNumber() {
1954
+ const rgb = this.rgb().color;
1955
+ return ((rgb[0] & 0xFF) << 16) | ((rgb[1] & 0xFF) << 8) | (rgb[2] & 0xFF);
1956
+ },
2023
1957
 
2024
- negate() {
2025
- const rgb = this.rgb();
1958
+ luminosity() {
1959
+ // http://www.w3.org/TR/WCAG20/#relativeluminancedef
1960
+ const rgb = this.rgb().color;
2026
1961
 
2027
- for (let i = 0; i < 3; i++) {
2028
- rgb.color[i] = 255 - rgb.color[i];
2029
- }
1962
+ const lum = [];
1963
+ for (const [i, element] of rgb.entries()) {
1964
+ const chan = element / 255;
1965
+ lum[i] = (chan <= 0.04045) ? chan / 12.92 : ((chan + 0.055) / 1.055) ** 2.4;
1966
+ }
2030
1967
 
2031
- return rgb;
2032
- },
1968
+ return 0.2126 * lum[0] + 0.7152 * lum[1] + 0.0722 * lum[2];
1969
+ },
2033
1970
 
2034
- lighten(ratio) {
2035
- const hsl = this.hsl();
2036
- hsl.color[2] += hsl.color[2] * ratio;
2037
- return hsl;
2038
- },
1971
+ contrast(color2) {
1972
+ // http://www.w3.org/TR/WCAG20/#contrast-ratiodef
1973
+ const lum1 = this.luminosity();
1974
+ const lum2 = color2.luminosity();
2039
1975
 
2040
- darken(ratio) {
2041
- const hsl = this.hsl();
2042
- hsl.color[2] -= hsl.color[2] * ratio;
2043
- return hsl;
2044
- },
1976
+ if (lum1 > lum2) {
1977
+ return (lum1 + 0.05) / (lum2 + 0.05);
1978
+ }
2045
1979
 
2046
- saturate(ratio) {
2047
- const hsl = this.hsl();
2048
- hsl.color[1] += hsl.color[1] * ratio;
2049
- return hsl;
2050
- },
1980
+ return (lum2 + 0.05) / (lum1 + 0.05);
1981
+ },
2051
1982
 
2052
- desaturate(ratio) {
2053
- const hsl = this.hsl();
2054
- hsl.color[1] -= hsl.color[1] * ratio;
2055
- return hsl;
2056
- },
1983
+ level(color2) {
1984
+ // https://www.w3.org/TR/WCAG/#contrast-enhanced
1985
+ const contrastRatio = this.contrast(color2);
1986
+ if (contrastRatio >= 7) {
1987
+ return 'AAA';
1988
+ }
2057
1989
 
2058
- whiten(ratio) {
2059
- const hwb = this.hwb();
2060
- hwb.color[1] += hwb.color[1] * ratio;
2061
- return hwb;
2062
- },
1990
+ return (contrastRatio >= 4.5) ? 'AA' : '';
1991
+ },
2063
1992
 
2064
- blacken(ratio) {
2065
- const hwb = this.hwb();
2066
- hwb.color[2] += hwb.color[2] * ratio;
2067
- return hwb;
2068
- },
1993
+ isDark() {
1994
+ // YIQ equation from http://24ways.org/2010/calculating-color-contrast
1995
+ const rgb = this.rgb().color;
1996
+ const yiq = (rgb[0] * 2126 + rgb[1] * 7152 + rgb[2] * 722) / 10000;
1997
+ return yiq < 128;
1998
+ },
2069
1999
 
2070
- grayscale() {
2071
- // http://en.wikipedia.org/wiki/Grayscale#Converting_color_to_grayscale
2072
- const rgb = this.rgb().color;
2073
- const value = rgb[0] * 0.3 + rgb[1] * 0.59 + rgb[2] * 0.11;
2074
- return Color.rgb(value, value, value);
2075
- },
2000
+ isLight() {
2001
+ return !this.isDark();
2002
+ },
2076
2003
 
2077
- fade(ratio) {
2078
- return this.alpha(this.valpha - this.valpha * ratio);
2079
- },
2004
+ negate() {
2005
+ const rgb = this.rgb();
2006
+ for (let i = 0; i < 3; i++) {
2007
+ rgb.color[i] = 255 - rgb.color[i];
2008
+ }
2080
2009
 
2081
- opaquer(ratio) {
2082
- return this.alpha(this.valpha + this.valpha * ratio);
2083
- },
2010
+ return rgb;
2011
+ },
2012
+
2013
+ lighten(ratio) {
2014
+ const hsl = this.hsl();
2015
+ hsl.color[2] += hsl.color[2] * ratio;
2016
+ return hsl;
2017
+ },
2018
+
2019
+ darken(ratio) {
2020
+ const hsl = this.hsl();
2021
+ hsl.color[2] -= hsl.color[2] * ratio;
2022
+ return hsl;
2023
+ },
2024
+
2025
+ saturate(ratio) {
2026
+ const hsl = this.hsl();
2027
+ hsl.color[1] += hsl.color[1] * ratio;
2028
+ return hsl;
2029
+ },
2030
+
2031
+ desaturate(ratio) {
2032
+ const hsl = this.hsl();
2033
+ hsl.color[1] -= hsl.color[1] * ratio;
2034
+ return hsl;
2035
+ },
2036
+
2037
+ whiten(ratio) {
2038
+ const hwb = this.hwb();
2039
+ hwb.color[1] += hwb.color[1] * ratio;
2040
+ return hwb;
2041
+ },
2042
+
2043
+ blacken(ratio) {
2044
+ const hwb = this.hwb();
2045
+ hwb.color[2] += hwb.color[2] * ratio;
2046
+ return hwb;
2047
+ },
2048
+
2049
+ grayscale() {
2050
+ // http://en.wikipedia.org/wiki/Grayscale#Converting_color_to_grayscale
2051
+ const rgb = this.rgb().color;
2052
+ const value = rgb[0] * 0.3 + rgb[1] * 0.59 + rgb[2] * 0.11;
2053
+ return Color.rgb(value, value, value);
2054
+ },
2055
+
2056
+ fade(ratio) {
2057
+ return this.alpha(this.valpha - (this.valpha * ratio));
2058
+ },
2059
+
2060
+ opaquer(ratio) {
2061
+ return this.alpha(this.valpha + (this.valpha * ratio));
2062
+ },
2063
+
2064
+ rotate(degrees) {
2065
+ const hsl = this.hsl();
2066
+ let hue = hsl.color[0];
2067
+ hue = (hue + degrees) % 360;
2068
+ hue = hue < 0 ? 360 + hue : hue;
2069
+ hsl.color[0] = hue;
2070
+ return hsl;
2071
+ },
2072
+
2073
+ mix(mixinColor, weight) {
2074
+ // Ported from sass implementation in C
2075
+ // https://github.com/sass/libsass/blob/0e6b4a2850092356aa3ece07c6b249f0221caced/functions.cpp#L209
2076
+ if (!mixinColor || !mixinColor.rgb) {
2077
+ throw new Error('Argument to "mix" was not a Color instance, but rather an instance of ' + typeof mixinColor);
2078
+ }
2084
2079
 
2085
- rotate(degrees) {
2086
- const hsl = this.hsl();
2087
- let hue = hsl.color[0];
2088
- hue = (hue + degrees) % 360;
2089
- hue = hue < 0 ? 360 + hue : hue;
2090
- hsl.color[0] = hue;
2091
- return hsl;
2092
- },
2080
+ const color1 = mixinColor.rgb();
2081
+ const color2 = this.rgb();
2082
+ const p = weight === undefined ? 0.5 : weight;
2093
2083
 
2094
- mix(mixinColor, weight) {
2095
- // Ported from sass implementation in C
2096
- // https://github.com/sass/libsass/blob/0e6b4a2850092356aa3ece07c6b249f0221caced/functions.cpp#L209
2097
- if (!mixinColor || !mixinColor.rgb) {
2098
- throw new Error('Argument to "mix" was not a Color instance, but rather an instance of ' + typeof mixinColor);
2099
- }
2084
+ const w = 2 * p - 1;
2085
+ const a = color1.alpha() - color2.alpha();
2100
2086
 
2101
- const color1 = mixinColor.rgb();
2102
- const color2 = this.rgb();
2103
- const p = weight === undefined ? 0.5 : weight;
2104
- const w = 2 * p - 1;
2105
- const a = color1.alpha() - color2.alpha();
2106
- const w1 = ((w * a === -1 ? w : (w + a) / (1 + w * a)) + 1) / 2;
2107
- const w2 = 1 - w1;
2108
- return Color.rgb(w1 * color1.red() + w2 * color2.red(), w1 * color1.green() + w2 * color2.green(), w1 * color1.blue() + w2 * color2.blue(), color1.alpha() * p + color2.alpha() * (1 - p));
2109
- }
2087
+ const w1 = (((w * a === -1) ? w : (w + a) / (1 + w * a)) + 1) / 2;
2088
+ const w2 = 1 - w1;
2110
2089
 
2111
- }; // Model conversion methods and static constructors
2090
+ return Color.rgb(
2091
+ w1 * color1.red() + w2 * color2.red(),
2092
+ w1 * color1.green() + w2 * color2.green(),
2093
+ w1 * color1.blue() + w2 * color2.blue(),
2094
+ color1.alpha() * p + color2.alpha() * (1 - p));
2095
+ },
2096
+ };
2112
2097
 
2098
+ // Model conversion methods and static constructors
2113
2099
  for (const model of Object.keys(colorConvert)) {
2114
- if (skippedModels.includes(model)) {
2115
- continue;
2116
- }
2117
-
2118
- const {
2119
- channels
2120
- } = colorConvert[model]; // Conversion methods
2121
-
2122
- Color.prototype[model] = function (...args) {
2123
- if (this.model === model) {
2124
- return new Color(this);
2125
- }
2100
+ if (skippedModels.includes(model)) {
2101
+ continue;
2102
+ }
2126
2103
 
2127
- if (args.length > 0) {
2128
- return new Color(args, model);
2129
- }
2104
+ const {channels} = colorConvert[model];
2130
2105
 
2131
- return new Color([...assertArray(colorConvert[this.model][model].raw(this.color)), this.valpha], model);
2132
- }; // 'static' construction methods
2106
+ // Conversion methods
2107
+ Color.prototype[model] = function (...args) {
2108
+ if (this.model === model) {
2109
+ return new Color(this);
2110
+ }
2133
2111
 
2112
+ if (args.length > 0) {
2113
+ return new Color(args, model);
2114
+ }
2134
2115
 
2135
- Color[model] = function (...args) {
2136
- let color = args[0];
2116
+ return new Color([...assertArray(colorConvert[this.model][model].raw(this.color)), this.valpha], model);
2117
+ };
2137
2118
 
2138
- if (typeof color === 'number') {
2139
- color = zeroArray(args, channels);
2140
- }
2119
+ // 'static' construction methods
2120
+ Color[model] = function (...args) {
2121
+ let color = args[0];
2122
+ if (typeof color === 'number') {
2123
+ color = zeroArray(args, channels);
2124
+ }
2141
2125
 
2142
- return new Color(color, model);
2143
- };
2126
+ return new Color(color, model);
2127
+ };
2144
2128
  }
2145
2129
 
2146
2130
  function roundTo(number, places) {
2147
- return Number(number.toFixed(places));
2131
+ return Number(number.toFixed(places));
2148
2132
  }
2149
2133
 
2150
2134
  function roundToPlace(places) {
2151
- return function (number) {
2152
- return roundTo(number, places);
2153
- };
2135
+ return function (number) {
2136
+ return roundTo(number, places);
2137
+ };
2154
2138
  }
2155
2139
 
2156
2140
  function getset(model, channel, modifier) {
2157
- model = Array.isArray(model) ? model : [model];
2141
+ model = Array.isArray(model) ? model : [model];
2158
2142
 
2159
- for (const m of model) {
2160
- (limiters[m] || (limiters[m] = []))[channel] = modifier;
2161
- }
2143
+ for (const m of model) {
2144
+ (limiters[m] || (limiters[m] = []))[channel] = modifier;
2145
+ }
2162
2146
 
2163
- model = model[0];
2164
- return function (value) {
2165
- let result;
2147
+ model = model[0];
2166
2148
 
2167
- if (value !== undefined) {
2168
- if (modifier) {
2169
- value = modifier(value);
2170
- }
2149
+ return function (value) {
2150
+ let result;
2171
2151
 
2172
- result = this[model]();
2173
- result.color[channel] = value;
2174
- return result;
2175
- }
2152
+ if (value !== undefined) {
2153
+ if (modifier) {
2154
+ value = modifier(value);
2155
+ }
2176
2156
 
2177
- result = this[model]().color[channel];
2157
+ result = this[model]();
2158
+ result.color[channel] = value;
2159
+ return result;
2160
+ }
2178
2161
 
2179
- if (modifier) {
2180
- result = modifier(result);
2181
- }
2162
+ result = this[model]().color[channel];
2163
+ if (modifier) {
2164
+ result = modifier(result);
2165
+ }
2182
2166
 
2183
- return result;
2184
- };
2167
+ return result;
2168
+ };
2185
2169
  }
2186
2170
 
2187
2171
  function maxfn(max) {
2188
- return function (v) {
2189
- return Math.max(0, Math.min(max, v));
2190
- };
2172
+ return function (v) {
2173
+ return Math.max(0, Math.min(max, v));
2174
+ };
2191
2175
  }
2192
2176
 
2193
2177
  function assertArray(value) {
2194
- return Array.isArray(value) ? value : [value];
2178
+ return Array.isArray(value) ? value : [value];
2195
2179
  }
2196
2180
 
2197
2181
  function zeroArray(array, length) {
2198
- for (let i = 0; i < length; i++) {
2199
- if (typeof array[i] !== 'number') {
2200
- array[i] = 0;
2201
- }
2202
- }
2182
+ for (let i = 0; i < length; i++) {
2183
+ if (typeof array[i] !== 'number') {
2184
+ array[i] = 0;
2185
+ }
2186
+ }
2203
2187
 
2204
- return array;
2188
+ return array;
2205
2189
  }
2206
2190
 
2207
2191
  var color = Color;
@@ -2307,7 +2291,7 @@ const DIMENSIONS = {
2307
2291
  }
2308
2292
  };
2309
2293
 
2310
- const colorPickerCss = "@-webkit-keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in{0%{opacity:0}100%{opacity:1}}@-webkit-keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}@keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 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;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-duration:var(--calcite-animation-timing);animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{-webkit-animation-name:in;animation-name:in}.calcite-animate__in-down{-webkit-animation-name:in-down;animation-name:in-down}.calcite-animate__in-up{-webkit-animation-name:in-up;animation-name:in-up}.calcite-animate__in-scale{-webkit-animation-name:in-scale;animation-name:in-scale}:root{--calcite-popper-transition:var(--calcite-animation-timing)}:host([hidden]){display:none}:host{display:inline-block;font-size:var(--calcite-font-size--2);line-height:1rem;font-weight:var(--calcite-font-weight-normal)}:host([disabled]){pointer-events:none;cursor:default;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;opacity:var(--calcite-ui-opacity-disabled)}:host([disabled]) ::slotted([calcite-hydrated][disabled]),:host([disabled]) [calcite-hydrated][disabled]{opacity:1}:host([scale=s]) .container{width:160px}:host([scale=s]) .saved-colors{grid-template-columns:repeat(auto-fill, minmax(20px, 1fr))}:host([scale=s]) .channels{-ms-flex-direction:column;flex-direction:column}:host([scale=s]) .channel{width:100%;margin-bottom:4px}:host([scale=s]) .channel:last-child{margin-bottom:0}:host([scale=m]) .container{width:272px}:host([scale=l]) .header{padding-bottom:0px}:host([scale=l]){font-size:var(--calcite-font-size--1);line-height:1rem}:host([scale=l]) .container{width:464px}:host([scale=l]) .color-field-and-slider{margin-bottom:-20px}:host([scale=l]) .section{padding:0 16px 16px}:host([scale=l]) .section:first-of-type{padding-top:16px}:host([scale=l]) .saved-colors{grid-template-columns:repeat(auto-fill, minmax(28px, 1fr));grid-gap:12px;padding-top:16px}:host([scale=l]) .control-section{-ms-flex-wrap:nowrap;flex-wrap:nowrap;-ms-flex-align:baseline;align-items:baseline}:host([scale=l]) .control-section>:nth-child(2){-webkit-margin-start:12px;margin-inline-start:12px}:host([scale=l]) .color-hex-options{display:-ms-flexbox;display:flex;-ms-flex-negative:1;flex-shrink:1;-ms-flex-direction:column;flex-direction:column;-ms-flex-pack:distribute;justify-content:space-around;min-height:98px;width:160px}:host([scale=l]) .color-mode-container{-ms-flex-negative:3;flex-shrink:3}:host([appearance=minimal]) .container{border:none}.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{pointer-events:none;position:absolute;margin-bottom:0px;margin-right:0px;height:0.5rem;width:0.5rem;padding:0px;font-size:var(--calcite-font-size--1);outline-offset:0;outline-color:transparent;-webkit-transition:outline-offset 100ms ease-in-out, outline-color 100ms ease-in-out;transition:outline-offset 100ms ease-in-out, outline-color 100ms ease-in-out;margin-top:-0.25rem;margin-left:-0.25rem;outline-offset:10px}.scope:focus{outline:2px solid var(--calcite-ui-brand);outline-offset:12px}.color-field-and-slider{margin-bottom:-16px}.color-field-and-slider--interactive{cursor:pointer}.control-section{display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;-ms-flex-wrap:wrap;flex-wrap:wrap}.section{padding:0 12px 12px}.section:first-of-type{padding-top:12px}.color-hex-options,.section--split{-ms-flex-positive:1;flex-grow:1}.header{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:justify;justify-content:space-between;padding-bottom:0.25rem;color:var(--calcite-ui-text-1)}.header--hex,.color-mode-container{padding-top:12px}.channels{display:-ms-flexbox;display:flex;-ms-flex-pack:justify;justify-content:space-between}.channel{width:31%}.saved-colors{padding-top:12px;display:grid;grid-template-columns:repeat(auto-fill, minmax(24px, 1fr));grid-gap:8px;width:100%}.saved-colors-buttons{display:-ms-flexbox;display:flex}.saved-color{outline-offset:0;outline-color:transparent;-webkit-transition:outline-offset 100ms ease-in-out, outline-color 100ms ease-in-out;transition:outline-offset 100ms ease-in-out, outline-color 100ms ease-in-out;cursor:pointer}.saved-color:focus{outline:2px solid var(--calcite-ui-brand);outline-offset:2px}.saved-color:hover{-webkit-transition:outline-color var(--calcite-internal-animation-timing-fast) ease-in-out;transition:outline-color var(--calcite-internal-animation-timing-fast) ease-in-out;outline:2px solid var(--calcite-ui-border-2);outline-offset:2px}";
2294
+ const colorPickerCss = "@-webkit-keyframes in{0%{opacity:0}100%{opacity:1}}@keyframes in{0%{opacity:0}100%{opacity:1}}@-webkit-keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-down{0%{opacity:0;-webkit-transform:translate3D(0, -5px, 0);transform:translate3D(0, -5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@keyframes in-up{0%{opacity:0;-webkit-transform:translate3D(0, 5px, 0);transform:translate3D(0, 5px, 0)}100%{opacity:1;-webkit-transform:translate3D(0, 0, 0);transform:translate3D(0, 0, 0)}}@-webkit-keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 1);transform:scale3D(1, 1, 1)}}@keyframes in-scale{0%{opacity:0;-webkit-transform:scale3D(0.95, 0.95, 1);transform:scale3D(0.95, 0.95, 1)}100%{opacity:1;-webkit-transform:scale3D(1, 1, 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;-webkit-animation-fill-mode:both;animation-fill-mode:both;-webkit-animation-duration:var(--calcite-animation-timing);animation-duration:var(--calcite-animation-timing)}.calcite-animate__in{-webkit-animation-name:in;animation-name:in}.calcite-animate__in-down{-webkit-animation-name:in-down;animation-name:in-down}.calcite-animate__in-up{-webkit-animation-name:in-up;animation-name:in-up}.calcite-animate__in-scale{-webkit-animation-name:in-scale;animation-name:in-scale}:root{--calcite-popper-transition:var(--calcite-animation-timing)}:host([hidden]){display:none}:host{display:inline-block;font-size:var(--calcite-font-size--2);line-height:1rem;font-weight:var(--calcite-font-weight-normal)}:host([disabled]){pointer-events:none;cursor:default;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;opacity:var(--calcite-ui-opacity-disabled)}:host([disabled]) ::slotted([calcite-hydrated][disabled]),:host([disabled]) [calcite-hydrated][disabled]{opacity:1}:host([scale=s]) .container{width:160px}:host([scale=s]) .saved-colors{grid-template-columns:repeat(auto-fill, minmax(20px, 1fr))}:host([scale=s]) .channels{-ms-flex-direction:column;flex-direction:column}:host([scale=s]) .channel{width:100%;margin-bottom:4px}:host([scale=s]) .channel:last-child{margin-bottom:0}:host([scale=m]) .container{width:272px}:host([scale=l]) .header{padding-bottom:0px}:host([scale=l]){font-size:var(--calcite-font-size--1);line-height:1rem}:host([scale=l]) .container{width:464px}:host([scale=l]) .color-field-and-slider{margin-bottom:-20px}:host([scale=l]) .section{padding:0 16px 16px}:host([scale=l]) .section:first-of-type{padding-top:16px}:host([scale=l]) .saved-colors{grid-template-columns:repeat(auto-fill, minmax(28px, 1fr));grid-gap:12px;padding-top:16px}:host([scale=l]) .control-section{-ms-flex-wrap:nowrap;flex-wrap:nowrap;-ms-flex-align:baseline;align-items:baseline}:host([scale=l]) .control-section>:nth-child(2){-webkit-margin-start:12px;margin-inline-start:12px}:host([scale=l]) .color-hex-options{display:-ms-flexbox;display:flex;-ms-flex-negative:1;flex-shrink:1;-ms-flex-direction:column;flex-direction:column;-ms-flex-pack:distribute;justify-content:space-around;min-height:98px;width:160px}:host([scale=l]) .color-mode-container{-ms-flex-negative:3;flex-shrink:3}:host([appearance=minimal]) .container{border:none}.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{pointer-events:none;position:absolute;font-size:var(--calcite-font-size--1);outline-offset:0;outline-color:transparent;-webkit-transition:outline-offset 100ms ease-in-out, outline-color 100ms ease-in-out;transition:outline-offset 100ms ease-in-out, outline-color 100ms ease-in-out;outline-offset:14px}.scope:focus{outline:2px solid var(--calcite-ui-brand);outline-offset:16px}.color-field-and-slider{margin-bottom:-16px}.color-field-and-slider--interactive{cursor:pointer}.control-section{display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;-ms-flex-wrap:wrap;flex-wrap:wrap}.section{padding:0 12px 12px}.section:first-of-type{padding-top:12px}.color-hex-options,.section--split{-ms-flex-positive:1;flex-grow:1}.header{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:justify;justify-content:space-between;padding-bottom:0.25rem;color:var(--calcite-ui-text-1)}.header--hex,.color-mode-container{padding-top:12px}.channels{display:-ms-flexbox;display:flex;-ms-flex-pack:justify;justify-content:space-between}.channel{width:31%}.saved-colors{padding-top:12px;display:grid;grid-template-columns:repeat(auto-fill, minmax(24px, 1fr));grid-gap:8px;width:100%}.saved-colors-buttons{display:-ms-flexbox;display:flex}.saved-color{outline-offset:0;outline-color:transparent;-webkit-transition:outline-offset 100ms ease-in-out, outline-color 100ms ease-in-out;transition:outline-offset 100ms ease-in-out, outline-color 100ms ease-in-out;cursor:pointer}.saved-color:focus{outline:2px solid var(--calcite-ui-brand);outline-offset:2px}.saved-color:hover{-webkit-transition:outline-color var(--calcite-internal-animation-timing-fast) ease-in-out;transition:outline-color var(--calcite-internal-animation-timing-fast) ease-in-out;outline:2px solid var(--calcite-ui-border-2);outline-offset:2px}";
2311
2295
 
2312
2296
  const throttleFor60FpsInMs = 16;
2313
2297
  const defaultValue = utils.normalizeHex(DEFAULT_COLOR$1.hex());
@@ -2709,7 +2693,7 @@ const ColorPicker = class {
2709
2693
  /* the channel container is ltr, so we apply the host's direction */
2710
2694
  this.renderChannel(channel, index, channelLabels[index], channelAriaLabels[index], direction)))));
2711
2695
  };
2712
- this.renderChannel = (value, index$1, label, ariaLabel, direction) => (index.h("calcite-input", { class: CSS$2.channel, "data-channel-index": index$1, dir: direction, label: ariaLabel, numberButtonType: "none", onCalciteInputChange: this.handleChannelChange, onCalciteInputInput: this.handleChannelInput, prefixText: label, scale: this.scale === "l" ? "m" : "s", type: "number", value: value === null || value === void 0 ? void 0 : value.toString() }));
2696
+ this.renderChannel = (value, index$1, label, ariaLabel, direction) => (index.h("calcite-input", { class: CSS$2.channel, "data-channel-index": index$1, dir: direction, label: ariaLabel, numberButtonType: "none", onCalciteInputChange: this.handleChannelChange, onCalciteInputInput: this.handleChannelInput, onKeyDown: this.handleKeyDown, prefixText: label, scale: this.scale === "l" ? "m" : "s", type: "number", value: value === null || value === void 0 ? void 0 : value.toString() }));
2713
2697
  this.deleteColor = () => {
2714
2698
  const colorToDelete = this.color.hex();
2715
2699
  const inStorage = this.savedColors.indexOf(colorToDelete) > -1;
@@ -2908,6 +2892,11 @@ const ColorPicker = class {
2908
2892
  // Private Methods
2909
2893
  //
2910
2894
  //--------------------------------------------------------------------------
2895
+ handleKeyDown(event) {
2896
+ if (event.key === "Enter") {
2897
+ event.preventDefault();
2898
+ }
2899
+ }
2911
2900
  showIncompatibleColorWarning(value, format) {
2912
2901
  console.warn(`ignoring color value (${value}) as it is not compatible with the current format (${format})`);
2913
2902
  }
@@ -3205,7 +3194,7 @@ const ColorPickerHexInput = class {
3205
3194
  render() {
3206
3195
  const { intlHex, value } = this;
3207
3196
  const hexInputValue = this.formatForInternalInput(value);
3208
- return (index.h("div", { class: CSS$1.container }, index.h("calcite-input", { class: CSS$1.input, label: intlHex, maxLength: 6, onCalciteInputBlur: this.onCalciteInputBlur, onCalciteInputChange: this.onInputChange, prefixText: "#", ref: this.storeInputRef, scale: this.scale, value: hexInputValue }), hexInputValue ? (index.h("calcite-color-picker-swatch", { active: true, class: CSS$1.preview, color: `#${hexInputValue}`, scale: this.scale })) : null));
3197
+ return (index.h("div", { class: CSS$1.container }, index.h("calcite-input", { class: CSS$1.input, label: intlHex, maxLength: 6, onCalciteInputBlur: this.onCalciteInputBlur, onCalciteInputChange: this.onInputChange, onKeyDown: this.handleKeyDown, prefixText: "#", ref: this.storeInputRef, scale: this.scale, value: hexInputValue }), hexInputValue ? (index.h("calcite-color-picker-swatch", { active: true, class: CSS$1.preview, color: `#${hexInputValue}`, scale: this.scale })) : null));
3209
3198
  }
3210
3199
  //--------------------------------------------------------------------------
3211
3200
  //
@@ -3252,6 +3241,11 @@ const ColorPickerHexInput = class {
3252
3241
  nudgeRGBChannels(color$1, amount) {
3253
3242
  return color.rgb(color$1.array().map((channel) => channel + amount));
3254
3243
  }
3244
+ handleKeyDown(event) {
3245
+ if (event.key === "Enter") {
3246
+ event.preventDefault();
3247
+ }
3248
+ }
3255
3249
  get el() { return index.getElement(this); }
3256
3250
  static get watchers() { return {
3257
3251
  "value": ["handleValueChange"]