@tmorrow/cre8-wc 1.1.2 → 1.1.4

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 (666) hide show
  1. package/cdn/cre8-wc.esm.js +1 -1
  2. package/cdn/cre8-wc.esm.js.map +1 -1
  3. package/cdn/cre8-wc.min.js +1 -1
  4. package/cdn/cre8-wc.min.js.map +1 -1
  5. package/lib/cdn-entry.js +129 -0
  6. package/lib/cdn-entry.js.map +1 -0
  7. package/lib/components/accordion/accordion.js +58 -40
  8. package/lib/components/accordion/accordion.js.map +1 -0
  9. package/lib/components/accordion/accordion.styles.js +4 -0
  10. package/lib/components/accordion/accordion.styles.js.map +1 -0
  11. package/lib/components/accordion-item/accordion-item.js +187 -98
  12. package/lib/components/accordion-item/accordion-item.js.map +1 -0
  13. package/lib/components/accordion-item/accordion-item.styles.js +4 -0
  14. package/lib/components/accordion-item/accordion-item.styles.js.map +1 -0
  15. package/lib/components/alert/alert.js +146 -107
  16. package/lib/components/alert/alert.js.map +1 -0
  17. package/lib/components/alert/alert.styles.js +4 -0
  18. package/lib/components/alert/alert.styles.js.map +1 -0
  19. package/lib/components/badge/badge.js +73 -50
  20. package/lib/components/badge/badge.js.map +1 -0
  21. package/lib/components/badge/badge.styles.js +4 -0
  22. package/lib/components/badge/badge.styles.js.map +1 -0
  23. package/lib/components/band/band.js +34 -31
  24. package/lib/components/band/band.js.map +1 -0
  25. package/lib/components/band/band.styles.js +4 -0
  26. package/lib/components/band/band.styles.js.map +1 -0
  27. package/lib/components/breadcrumbs/breadcrumbs.js +52 -28
  28. package/lib/components/breadcrumbs/breadcrumbs.js.map +1 -0
  29. package/lib/components/breadcrumbs/breadcrumbs.styles.js +4 -0
  30. package/lib/components/breadcrumbs/breadcrumbs.styles.js.map +1 -0
  31. package/lib/components/breadcrumbs-item/breadcrumbs-item.js +28 -27
  32. package/lib/components/breadcrumbs-item/breadcrumbs-item.js.map +1 -0
  33. package/lib/components/breadcrumbs-item/breadcrumbs-item.styles.js +4 -0
  34. package/lib/components/breadcrumbs-item/breadcrumbs-item.styles.js.map +1 -0
  35. package/lib/components/button/button.js +297 -1040
  36. package/lib/components/button/button.js.map +1 -0
  37. package/lib/components/button/button.styles.js +885 -0
  38. package/lib/components/button/button.styles.js.map +1 -0
  39. package/lib/components/button-group/button-group.js +30 -27
  40. package/lib/components/button-group/button-group.js.map +1 -0
  41. package/lib/components/button-group/button-group.styles.js +4 -0
  42. package/lib/components/button-group/button-group.styles.js.map +1 -0
  43. package/lib/components/card/card.js +57 -35
  44. package/lib/components/card/card.js.map +1 -0
  45. package/lib/components/card/card.styles.js +4 -0
  46. package/lib/components/card/card.styles.js.map +1 -0
  47. package/lib/components/chart/chart.js +528 -354
  48. package/lib/components/chart/chart.js.map +1 -0
  49. package/lib/components/chart/chart.styles.js +4 -0
  50. package/lib/components/chart/chart.styles.js.map +1 -0
  51. package/lib/components/checkbox-field/checkbox-field.js +66 -53
  52. package/lib/components/checkbox-field/checkbox-field.js.map +1 -0
  53. package/lib/components/checkbox-field/checkbox-field.styles.js +4 -0
  54. package/lib/components/checkbox-field/checkbox-field.styles.js.map +1 -0
  55. package/lib/components/checkbox-field-item/checkbox-field-item.js +252 -183
  56. package/lib/components/checkbox-field-item/checkbox-field-item.js.map +1 -0
  57. package/lib/components/checkbox-field-item/checkbox-field-item.styles.js +4 -0
  58. package/lib/components/checkbox-field-item/checkbox-field-item.styles.js.map +1 -0
  59. package/lib/components/contexts/form-internals-context.js +9 -0
  60. package/lib/components/contexts/form-internals-context.js.map +1 -0
  61. package/lib/components/cre8-element.js +57 -56
  62. package/lib/components/cre8-element.js.map +1 -0
  63. package/lib/components/cre8-form-element.js +212 -244
  64. package/lib/components/cre8-form-element.js.map +1 -0
  65. package/lib/components/danger-button/danger-button.js +274 -147
  66. package/lib/components/danger-button/danger-button.js.map +1 -0
  67. package/lib/components/danger-button/danger-button.styles.js +4 -0
  68. package/lib/components/danger-button/danger-button.styles.js.map +1 -0
  69. package/lib/components/date-picker/calendar/calendar.js +465 -0
  70. package/lib/components/date-picker/calendar/calendar.js.map +1 -0
  71. package/lib/components/date-picker/calendar/calendar.styles.js +4 -0
  72. package/lib/components/date-picker/calendar/calendar.styles.js.map +1 -0
  73. package/lib/components/date-picker/calendar-month-modal/calendar-month-modal.js +76 -0
  74. package/lib/components/date-picker/calendar-month-modal/calendar-month-modal.js.map +1 -0
  75. package/lib/components/date-picker/calendar-month-modal/calendar-month-modal.styles.js +4 -0
  76. package/lib/components/date-picker/calendar-month-modal/calendar-month-modal.styles.js.map +1 -0
  77. package/lib/components/date-picker/calendar-navigation/calendar-navigation.js +110 -0
  78. package/lib/components/date-picker/calendar-navigation/calendar-navigation.js.map +1 -0
  79. package/lib/components/date-picker/calendar-navigation/calendar-navigation.styles.js +4 -0
  80. package/lib/components/date-picker/calendar-navigation/calendar-navigation.styles.js.map +1 -0
  81. package/lib/components/date-picker/calendar-year-modal/calendar-year-modal.js +116 -0
  82. package/lib/components/date-picker/calendar-year-modal/calendar-year-modal.js.map +1 -0
  83. package/lib/components/date-picker/calendar-year-modal/calendar-year-modal.styles.js +4 -0
  84. package/lib/components/date-picker/calendar-year-modal/calendar-year-modal.styles.js.map +1 -0
  85. package/lib/components/date-picker/date-picker.js +91 -784
  86. package/lib/components/date-picker/date-picker.js.map +1 -0
  87. package/lib/components/date-picker/date-picker.styles.js +4 -0
  88. package/lib/components/date-picker/date-picker.styles.js.map +1 -0
  89. package/lib/components/divider/divider.js +45 -35
  90. package/lib/components/divider/divider.js.map +1 -0
  91. package/lib/components/divider/divider.styles.js +4 -0
  92. package/lib/components/divider/divider.styles.js.map +1 -0
  93. package/lib/components/dropdown/dropdown.js +97 -63
  94. package/lib/components/dropdown/dropdown.js.map +1 -0
  95. package/lib/components/dropdown/dropdown.styles.js +4 -0
  96. package/lib/components/dropdown/dropdown.styles.js.map +1 -0
  97. package/lib/components/dropdown-item/dropdown-item.js +38 -31
  98. package/lib/components/dropdown-item/dropdown-item.js.map +1 -0
  99. package/lib/components/dropdown-item/dropdown-item.styles.js +4 -0
  100. package/lib/components/dropdown-item/dropdown-item.styles.js.map +1 -0
  101. package/lib/components/feature/feature.js +40 -35
  102. package/lib/components/feature/feature.js.map +1 -0
  103. package/lib/components/feature/feature.styles.js +4 -0
  104. package/lib/components/feature/feature.styles.js.map +1 -0
  105. package/lib/components/field/field.js +218 -153
  106. package/lib/components/field/field.js.map +1 -0
  107. package/lib/components/field/field.styles.js +4 -0
  108. package/lib/components/field/field.styles.js.map +1 -0
  109. package/lib/components/field-note/field-note.js +58 -45
  110. package/lib/components/field-note/field-note.js.map +1 -0
  111. package/lib/components/field-note/field-note.styles.js +4 -0
  112. package/lib/components/field-note/field-note.styles.js.map +1 -0
  113. package/lib/components/footer/footer.js +25 -18
  114. package/lib/components/footer/footer.js.map +1 -0
  115. package/lib/components/footer/footer.styles.js +4 -0
  116. package/lib/components/footer/footer.styles.js.map +1 -0
  117. package/lib/components/global-nav/global-nav.js +44 -37
  118. package/lib/components/global-nav/global-nav.js.map +1 -0
  119. package/lib/components/global-nav/global-nav.styles.js +4 -0
  120. package/lib/components/global-nav/global-nav.styles.js.map +1 -0
  121. package/lib/components/global-nav-item/global-nav-item.js +149 -112
  122. package/lib/components/global-nav-item/global-nav-item.js.map +1 -0
  123. package/lib/components/global-nav-item/global-nav-item.styles.js +4 -0
  124. package/lib/components/global-nav-item/global-nav-item.styles.js.map +1 -0
  125. package/lib/components/grid/grid.js +48 -45
  126. package/lib/components/grid/grid.js.map +1 -0
  127. package/lib/components/grid/grid.styles.js +4 -0
  128. package/lib/components/grid/grid.styles.js.map +1 -0
  129. package/lib/components/grid-item/grid-item.js +19 -16
  130. package/lib/components/grid-item/grid-item.js.map +1 -0
  131. package/lib/components/grid-item/grid-item.styles.js +4 -0
  132. package/lib/components/grid-item/grid-item.styles.js.map +1 -0
  133. package/lib/components/header/header.js +34 -29
  134. package/lib/components/header/header.js.map +1 -0
  135. package/lib/components/header/header.styles.js +4 -0
  136. package/lib/components/header/header.styles.js.map +1 -0
  137. package/lib/components/heading/heading.js +113 -76
  138. package/lib/components/heading/heading.js.map +1 -0
  139. package/lib/components/heading/heading.styles.js +4 -0
  140. package/lib/components/heading/heading.styles.js.map +1 -0
  141. package/lib/components/hero/hero.js +43 -40
  142. package/lib/components/hero/hero.js.map +1 -0
  143. package/lib/components/hero/hero.styles.js +4 -0
  144. package/lib/components/hero/hero.styles.js.map +1 -0
  145. package/lib/components/icon/icon.js +232 -9
  146. package/lib/components/icon/icon.js.map +1 -0
  147. package/lib/components/icon/icon.styles.js +4 -0
  148. package/lib/components/icon/icon.styles.js.map +1 -0
  149. package/lib/components/inline-alert/inline-alert.js +114 -87
  150. package/lib/components/inline-alert/inline-alert.js.map +1 -0
  151. package/lib/components/inline-alert/inline-alert.styles.js +4 -0
  152. package/lib/components/inline-alert/inline-alert.styles.js.map +1 -0
  153. package/lib/components/layout/layout.js +30 -27
  154. package/lib/components/layout/layout.js.map +1 -0
  155. package/lib/components/layout/layout.styles.js +4 -0
  156. package/lib/components/layout/layout.styles.js.map +1 -0
  157. package/lib/components/layout-container/layout-container.js +30 -27
  158. package/lib/components/layout-container/layout-container.js.map +1 -0
  159. package/lib/components/layout-container/layout-container.styles.js +4 -0
  160. package/lib/components/layout-container/layout-container.styles.js.map +1 -0
  161. package/lib/components/layout-section/layout-section.js +41 -33
  162. package/lib/components/layout-section/layout-section.js.map +1 -0
  163. package/lib/components/layout-section/layout-section.styles.js +4 -0
  164. package/lib/components/layout-section/layout-section.styles.js.map +1 -0
  165. package/lib/components/linelength-container/linelength-container.js +19 -16
  166. package/lib/components/linelength-container/linelength-container.js.map +1 -0
  167. package/lib/components/linelength-container/linelength-container.styles.js +4 -0
  168. package/lib/components/linelength-container/linelength-container.styles.js.map +1 -0
  169. package/lib/components/link/link.js +125 -87
  170. package/lib/components/link/link.js.map +1 -0
  171. package/lib/components/link/link.styles.js +4 -0
  172. package/lib/components/link/link.styles.js.map +1 -0
  173. package/lib/components/link-list/link-list.js +48 -45
  174. package/lib/components/link-list/link-list.js.map +1 -0
  175. package/lib/components/link-list/link-list.styles.js +4 -0
  176. package/lib/components/link-list/link-list.styles.js.map +1 -0
  177. package/lib/components/link-list-item/link-list-item.js +40 -37
  178. package/lib/components/link-list-item/link-list-item.js.map +1 -0
  179. package/lib/components/link-list-item/link-list-item.styles.js +4 -0
  180. package/lib/components/link-list-item/link-list-item.styles.js.map +1 -0
  181. package/lib/components/list/list.js +35 -32
  182. package/lib/components/list/list.js.map +1 -0
  183. package/lib/components/list/list.styles.js +4 -0
  184. package/lib/components/list/list.styles.js.map +1 -0
  185. package/lib/components/list-item/list-item.js +25 -21
  186. package/lib/components/list-item/list-item.js.map +1 -0
  187. package/lib/components/list-item/list-item.styles.js +4 -0
  188. package/lib/components/list-item/list-item.styles.js.map +1 -0
  189. package/lib/components/loading-spinner/loading-spinner.js +126 -71
  190. package/lib/components/loading-spinner/loading-spinner.js.map +1 -0
  191. package/lib/components/loading-spinner/loading-spinner.styles.js +4 -0
  192. package/lib/components/loading-spinner/loading-spinner.styles.js.map +1 -0
  193. package/lib/components/logo/logo.js +28 -25
  194. package/lib/components/logo/logo.js.map +1 -0
  195. package/lib/components/logo/logo.styles.js +4 -0
  196. package/lib/components/logo/logo.styles.js.map +1 -0
  197. package/lib/components/main/main.js +29 -26
  198. package/lib/components/main/main.js.map +1 -0
  199. package/lib/components/main/main.styles.js +4 -0
  200. package/lib/components/main/main.styles.js.map +1 -0
  201. package/lib/components/modal/modal.js +174 -125
  202. package/lib/components/modal/modal.js.map +1 -0
  203. package/lib/components/modal/modal.styles.js +4 -0
  204. package/lib/components/modal/modal.styles.js.map +1 -0
  205. package/lib/components/multi-select/multi-select.js +300 -211
  206. package/lib/components/multi-select/multi-select.js.map +1 -0
  207. package/lib/components/multi-select/multi-select.styles.js +4 -0
  208. package/lib/components/multi-select/multi-select.styles.js.map +1 -0
  209. package/lib/components/nav-container/nav-container.js +19 -16
  210. package/lib/components/nav-container/nav-container.js.map +1 -0
  211. package/lib/components/nav-container/nav-container.styles.js +4 -0
  212. package/lib/components/nav-container/nav-container.styles.js.map +1 -0
  213. package/lib/components/page-header/page-header.js +36 -29
  214. package/lib/components/page-header/page-header.js.map +1 -0
  215. package/lib/components/page-header/page-header.styles.js +4 -0
  216. package/lib/components/page-header/page-header.styles.js.map +1 -0
  217. package/lib/components/pagination/page-counter/page-counter.js +67 -0
  218. package/lib/components/pagination/page-counter/page-counter.js.map +1 -0
  219. package/lib/components/pagination/page-counter/page-counter.styles.js +4 -0
  220. package/lib/components/pagination/page-counter/page-counter.styles.js.map +1 -0
  221. package/lib/components/pagination/pagination.js +282 -237
  222. package/lib/components/pagination/pagination.js.map +1 -0
  223. package/lib/components/pagination/pagination.styles.js +4 -0
  224. package/lib/components/pagination/pagination.styles.js.map +1 -0
  225. package/lib/components/percent-bar/percent-bar.js +56 -48
  226. package/lib/components/percent-bar/percent-bar.js.map +1 -0
  227. package/lib/components/percent-bar/percent-bar.styles.js +4 -0
  228. package/lib/components/percent-bar/percent-bar.styles.js.map +1 -0
  229. package/lib/components/popover/popover.js +304 -179
  230. package/lib/components/popover/popover.js.map +1 -0
  231. package/lib/components/popover/popover.styles.js +4 -0
  232. package/lib/components/popover/popover.styles.js.map +1 -0
  233. package/lib/components/primary-nav/primary-nav.js +44 -37
  234. package/lib/components/primary-nav/primary-nav.js.map +1 -0
  235. package/lib/components/primary-nav/primary-nav.styles.js +4 -0
  236. package/lib/components/primary-nav/primary-nav.styles.js.map +1 -0
  237. package/lib/components/primary-nav-item/primary-nav-item.js +151 -113
  238. package/lib/components/primary-nav-item/primary-nav-item.js.map +1 -0
  239. package/lib/components/primary-nav-item/primary-nav-item.styles.js +4 -0
  240. package/lib/components/primary-nav-item/primary-nav-item.styles.js.map +1 -0
  241. package/lib/components/progress-meter/progress-meter.js +74 -57
  242. package/lib/components/progress-meter/progress-meter.js.map +1 -0
  243. package/lib/components/progress-meter/progress-meter.styles.js +4 -0
  244. package/lib/components/progress-meter/progress-meter.styles.js.map +1 -0
  245. package/lib/components/progress-steps/progress-steps.js +19 -0
  246. package/lib/components/progress-steps/progress-steps.js.map +1 -0
  247. package/lib/components/progress-steps/progress-steps.styles.js +4 -0
  248. package/lib/components/progress-steps/progress-steps.styles.js.map +1 -0
  249. package/lib/components/progress-steps-item/progress-steps-item.js +52 -40
  250. package/lib/components/progress-steps-item/progress-steps-item.js.map +1 -0
  251. package/lib/components/progress-steps-item/progress-steps-item.styles.js +4 -0
  252. package/lib/components/progress-steps-item/progress-steps-item.styles.js.map +1 -0
  253. package/lib/components/radio-field/radio-field.js +59 -49
  254. package/lib/components/radio-field/radio-field.js.map +1 -0
  255. package/lib/components/radio-field/radio-field.styles.js +4 -0
  256. package/lib/components/radio-field/radio-field.styles.js.map +1 -0
  257. package/lib/components/radio-field-item/radio-field-item.js +222 -179
  258. package/lib/components/radio-field-item/radio-field-item.js.map +1 -0
  259. package/lib/components/radio-field-item/radio-field-item.styles.js +4 -0
  260. package/lib/components/radio-field-item/radio-field-item.styles.js.map +1 -0
  261. package/lib/components/remove-tag/remove-tag.js +89 -60
  262. package/lib/components/remove-tag/remove-tag.js.map +1 -0
  263. package/lib/components/remove-tag/remove-tag.styles.js +4 -0
  264. package/lib/components/remove-tag/remove-tag.styles.js.map +1 -0
  265. package/lib/components/section/section.js +46 -27
  266. package/lib/components/section/section.js.map +1 -0
  267. package/lib/components/section/section.styles.js +4 -0
  268. package/lib/components/section/section.styles.js.map +1 -0
  269. package/lib/components/select/select.js +243 -158
  270. package/lib/components/select/select.js.map +1 -0
  271. package/lib/components/select/select.styles.js +4 -0
  272. package/lib/components/select/select.styles.js.map +1 -0
  273. package/lib/components/select-tile/select-tile-checkbox-controller.js +60 -0
  274. package/lib/components/select-tile/select-tile-checkbox-controller.js.map +1 -0
  275. package/lib/components/select-tile/select-tile-radio-controller.js +167 -0
  276. package/lib/components/select-tile/select-tile-radio-controller.js.map +1 -0
  277. package/lib/components/select-tile/select-tile.js +228 -223
  278. package/lib/components/select-tile/select-tile.js.map +1 -0
  279. package/lib/components/select-tile/select-tile.styles.js +4 -0
  280. package/lib/components/select-tile/select-tile.styles.js.map +1 -0
  281. package/lib/components/select-tile-list/select-tile-list.js +76 -62
  282. package/lib/components/select-tile-list/select-tile-list.js.map +1 -0
  283. package/lib/components/select-tile-list/select-tile-list.styles.js +4 -0
  284. package/lib/components/select-tile-list/select-tile-list.styles.js.map +1 -0
  285. package/lib/components/skeleton-loader/skeleton-loader.js +68 -39
  286. package/lib/components/skeleton-loader/skeleton-loader.js.map +1 -0
  287. package/lib/components/skeleton-loader/skeleton-loader.styles.js +4 -0
  288. package/lib/components/skeleton-loader/skeleton-loader.styles.js.map +1 -0
  289. package/lib/components/split-button/split-button.js +51 -46
  290. package/lib/components/split-button/split-button.js.map +1 -0
  291. package/lib/components/split-button/split-button.styles.js +4 -0
  292. package/lib/components/split-button/split-button.styles.js.map +1 -0
  293. package/lib/components/submenu/submenu.js +19 -16
  294. package/lib/components/submenu/submenu.js.map +1 -0
  295. package/lib/components/submenu/submenu.styles.js +4 -0
  296. package/lib/components/submenu/submenu.styles.js.map +1 -0
  297. package/lib/components/submenu-item/submenu-item.js +32 -26
  298. package/lib/components/submenu-item/submenu-item.js.map +1 -0
  299. package/lib/components/submenu-item/submenu-item.styles.js +4 -0
  300. package/lib/components/submenu-item/submenu-item.styles.js.map +1 -0
  301. package/lib/components/tab/tab.js +74 -63
  302. package/lib/components/tab/tab.js.map +1 -0
  303. package/lib/components/tab/tab.styles.js +4 -0
  304. package/lib/components/tab/tab.styles.js.map +1 -0
  305. package/lib/components/tab-panel/tab-panel.js +49 -43
  306. package/lib/components/tab-panel/tab-panel.js.map +1 -0
  307. package/lib/components/tab-panel/tab-panel.styles.js +4 -0
  308. package/lib/components/tab-panel/tab-panel.styles.js.map +1 -0
  309. package/lib/components/table/table.js +46 -41
  310. package/lib/components/table/table.js.map +1 -0
  311. package/lib/components/table/table.styles.js +4 -0
  312. package/lib/components/table/table.styles.js.map +1 -0
  313. package/lib/components/table-body/table-body.js +20 -17
  314. package/lib/components/table-body/table-body.js.map +1 -0
  315. package/lib/components/table-body/table-body.styles.js +4 -0
  316. package/lib/components/table-body/table-body.styles.js.map +1 -0
  317. package/lib/components/table-cell/table-cell.js +39 -36
  318. package/lib/components/table-cell/table-cell.js.map +1 -0
  319. package/lib/components/table-cell/table-cell.styles.js +4 -0
  320. package/lib/components/table-cell/table-cell.styles.js.map +1 -0
  321. package/lib/components/table-header/table-header.js +20 -17
  322. package/lib/components/table-header/table-header.js.map +1 -0
  323. package/lib/components/table-header/table-header.styles.js +4 -0
  324. package/lib/components/table-header/table-header.styles.js.map +1 -0
  325. package/lib/components/table-header-cell/table-header-cell.js +35 -32
  326. package/lib/components/table-header-cell/table-header-cell.js.map +1 -0
  327. package/lib/components/table-header-cell/table-header-cell.styles.js +4 -0
  328. package/lib/components/table-header-cell/table-header-cell.styles.js.map +1 -0
  329. package/lib/components/table-object/table-object.js +21 -18
  330. package/lib/components/table-object/table-object.js.map +1 -0
  331. package/lib/components/table-object/table-object.styles.js +4 -0
  332. package/lib/components/table-object/table-object.styles.js.map +1 -0
  333. package/lib/components/table-row/table-row.js +76 -55
  334. package/lib/components/table-row/table-row.js.map +1 -0
  335. package/lib/components/table-row/table-row.styles.js +4 -0
  336. package/lib/components/table-row/table-row.styles.js.map +1 -0
  337. package/lib/components/tabs/tabs.js +452 -303
  338. package/lib/components/tabs/tabs.js.map +1 -0
  339. package/lib/components/tabs/tabs.styles.js +4 -0
  340. package/lib/components/tabs/tabs.styles.js.map +1 -0
  341. package/lib/components/tag/tag.js +236 -167
  342. package/lib/components/tag/tag.js.map +1 -0
  343. package/lib/components/tag/tag.styles.js +4 -0
  344. package/lib/components/tag/tag.styles.js.map +1 -0
  345. package/lib/components/tag-list/tag-list.js +40 -35
  346. package/lib/components/tag-list/tag-list.js.map +1 -0
  347. package/lib/components/tag-list/tag-list.styles.js +4 -0
  348. package/lib/components/tag-list/tag-list.styles.js.map +1 -0
  349. package/lib/components/tertiary-nav/tertiary-nav.js +40 -33
  350. package/lib/components/tertiary-nav/tertiary-nav.js.map +1 -0
  351. package/lib/components/tertiary-nav/tertiary-nav.styles.js +4 -0
  352. package/lib/components/tertiary-nav/tertiary-nav.styles.js.map +1 -0
  353. package/lib/components/tertiary-nav-item/tertiary-nav-item.js +52 -43
  354. package/lib/components/tertiary-nav-item/tertiary-nav-item.js.map +1 -0
  355. package/lib/components/tertiary-nav-item/tertiary-nav-item.styles.js +4 -0
  356. package/lib/components/tertiary-nav-item/tertiary-nav-item.styles.js.map +1 -0
  357. package/lib/components/text-link/text-link.js +45 -41
  358. package/lib/components/text-link/text-link.js.map +1 -0
  359. package/lib/components/text-link/text-link.styles.js +4 -0
  360. package/lib/components/text-link/text-link.styles.js.map +1 -0
  361. package/lib/components/text-passage/text-passage-light-dom.js +145 -0
  362. package/lib/components/text-passage/text-passage-light-dom.js.map +1 -0
  363. package/lib/components/text-passage/text-passage-light-dom.styles.js +4 -0
  364. package/lib/components/text-passage/text-passage-light-dom.styles.js.map +1 -0
  365. package/lib/components/text-passage/text-passage.js +72 -44
  366. package/lib/components/text-passage/text-passage.js.map +1 -0
  367. package/lib/components/text-passage/text-passage.styles.js +4 -0
  368. package/lib/components/text-passage/text-passage.styles.js.map +1 -0
  369. package/lib/components/tooltip/tooltip.js +278 -173
  370. package/lib/components/tooltip/tooltip.js.map +1 -0
  371. package/lib/components/tooltip/tooltip.styles.js +4 -0
  372. package/lib/components/tooltip/tooltip.styles.js.map +1 -0
  373. package/lib/components/utility-nav/utility-nav.js +40 -33
  374. package/lib/components/utility-nav/utility-nav.js.map +1 -0
  375. package/lib/components/utility-nav/utility-nav.styles.js +4 -0
  376. package/lib/components/utility-nav/utility-nav.styles.js.map +1 -0
  377. package/lib/components/utility-nav-item/utility-nav-item.js +70 -49
  378. package/lib/components/utility-nav-item/utility-nav-item.js.map +1 -0
  379. package/lib/components/utility-nav-item/utility-nav-item.styles.js +4 -0
  380. package/lib/components/utility-nav-item/utility-nav-item.styles.js.map +1 -0
  381. package/lib/design-tokens/brands/blue/css/fonts.css +31 -0
  382. package/lib/design-tokens/brands/blue/css/tokens_blue.css +248 -0
  383. package/lib/design-tokens/brands/blue/css/tokens_blue.module.js +737 -0
  384. package/lib/design-tokens/brands/blue/css/tokens_blue.module.js.map +1 -0
  385. package/lib/design-tokens/brands/blue/css/tokens_brand.css +492 -0
  386. package/lib/design-tokens/brands/bolt/tokens_bolt.theme.js +756 -0
  387. package/lib/design-tokens/brands/bolt/tokens_bolt.theme.js.map +1 -0
  388. package/lib/design-tokens/brands/cre8/css/fonts.css +35 -0
  389. package/lib/design-tokens/brands/cre8/css/tokens_brand.css +494 -0
  390. package/lib/design-tokens/brands/cre8/css/tokens_cre8.css +767 -0
  391. package/lib/design-tokens/brands/cre8/css/tokens_cre8.module.js +771 -0
  392. package/lib/design-tokens/brands/cre8/css/tokens_cre8.module.js.map +1 -0
  393. package/lib/design-tokens/brands/cre8-a2ui/css/fonts.css +35 -0
  394. package/lib/design-tokens/brands/cre8-a2ui/css/tokens_brand.css +494 -0
  395. package/lib/design-tokens/brands/cre8-a2ui/css/tokens_cre8-a2ui.css +248 -0
  396. package/lib/design-tokens/brands/cre8-a2ui/css/tokens_cre8-a2ui.module.js +772 -0
  397. package/lib/design-tokens/brands/cre8-a2ui/css/tokens_cre8-a2ui.module.js.map +1 -0
  398. package/lib/design-tokens/brands/cre8-legacy/css/fonts.css +47 -0
  399. package/lib/design-tokens/brands/cre8-legacy/css/tokens_brand.css +464 -0
  400. package/lib/design-tokens/brands/cre8-legacy/css/tokens_cre8-legacy.css +0 -0
  401. package/lib/design-tokens/brands/cre8-legacy/css/tokens_cre8-legacy.module.js +737 -0
  402. package/lib/design-tokens/brands/cre8-legacy/css/tokens_cre8-legacy.module.js.map +1 -0
  403. package/lib/design-tokens/brands/femmecubator/css/fonts.css +35 -0
  404. package/lib/design-tokens/brands/femmecubator/css/tokens_femmecubator2.module.js +983 -0
  405. package/lib/design-tokens/brands/femmecubator/css/tokens_femmecubator2.module.js.map +1 -0
  406. package/lib/design-tokens/brands/legacy/css/fonts.css +26 -0
  407. package/lib/design-tokens/brands/legacy/css/tokens_brand.css +491 -0
  408. package/lib/design-tokens/brands/legacy/css/tokens_legacy.css +250 -0
  409. package/lib/design-tokens/brands/legacy/css/tokens_legacy.module.js +737 -0
  410. package/lib/design-tokens/brands/legacy/css/tokens_legacy.module.js.map +1 -0
  411. package/lib/design-tokens/brands/marketing/css/fonts.css +31 -0
  412. package/lib/design-tokens/brands/marketing/css/tokens_brand.css +502 -0
  413. package/lib/design-tokens/brands/marketing/css/tokens_marketing.module.js +736 -0
  414. package/lib/design-tokens/brands/marketing/css/tokens_marketing.module.js.map +1 -0
  415. package/lib/design-tokens/brands/minimalist/css/fonts.css +26 -0
  416. package/lib/design-tokens/brands/minimalist/css/tokens_brand.css +492 -0
  417. package/lib/design-tokens/brands/minimalist/css/tokens_minimalist.css +736 -0
  418. package/lib/design-tokens/brands/minimalist/css/tokens_minimalist.module.js +737 -0
  419. package/lib/design-tokens/brands/minimalist/css/tokens_minimalist.module.js.map +1 -0
  420. package/lib/design-tokens/brands/prisma/figma-tokens.css +339 -0
  421. package/lib/design-tokens/brands/prisma/tokens_prisma.module.js +771 -0
  422. package/lib/design-tokens/brands/prisma/tokens_prisma.module.js.map +1 -0
  423. package/lib/design-tokens/brands/starbucks/fonts.css +26 -0
  424. package/lib/design-tokens/brands/starbucks/tokens.module.js +552 -0
  425. package/lib/design-tokens/brands/starbucks/tokens.module.js.map +1 -0
  426. package/lib/design-tokens/brands/starbucks/tokens_starbucks.module.js +776 -0
  427. package/lib/design-tokens/brands/starbucks/tokens_starbucks.module.js.map +1 -0
  428. package/lib/design-tokens/brands/tmorrow/css/tokens_brand.css +104 -0
  429. package/lib/design-tokens/brands/tmorrow/css/tokens_tmorrow-frost.css +222 -0
  430. package/lib/design-tokens/brands/tmorrow/css/tokens_tmorrow-neon.css +218 -0
  431. package/lib/design-tokens/capitalone/fonts.css +26 -0
  432. package/lib/design-tokens/capitalone/overrides.css +33 -0
  433. package/lib/design-tokens/capitalone/tokens.module.css +532 -0
  434. package/lib/design-tokens/core/scss/abstracts/functions.css +0 -0
  435. package/lib/design-tokens/core/scss/theming/animation.css +1 -0
  436. package/lib/design-tokens/core/scss/theming/body.css +1 -0
  437. package/lib/design-tokens/core/scss/theming/breakpoints.css +0 -0
  438. package/lib/design-tokens/core/scss/theming/component.css +1 -0
  439. package/lib/design-tokens/core/scss/theming/display.css +1 -0
  440. package/lib/design-tokens/core/scss/theming/head.css +1 -0
  441. package/lib/design-tokens/core/scss/theming/head.module.js +6 -0
  442. package/lib/design-tokens/core/scss/theming/head.module.js.map +1 -0
  443. package/lib/design-tokens/core/scss/theming/spacing.css +1 -0
  444. package/lib/design-tokens/core/scss/theming/typography-usage.css +0 -0
  445. package/lib/design-tokens/core/scss/theming/variables.css +1 -0
  446. package/lib/design-tokens/core/scss/theming/visibility.css +1 -0
  447. package/lib/design-tokens/core/scss/utilities/animation.css +1 -0
  448. package/lib/design-tokens/core/scss/utilities/colors.css +1 -0
  449. package/lib/design-tokens/core/scss/utilities/display.css +1 -0
  450. package/lib/design-tokens/femmecubator/equity.css +142 -0
  451. package/lib/design-tokens/femmecubator/fonts.css +35 -0
  452. package/lib/design-tokens/femmecubator/tokens_brand.css +146 -0
  453. package/lib/design-tokens/femmecubator/tokens_femmecubator.module.css +247 -0
  454. package/lib/design-tokens/figma-tokens.css +0 -0
  455. package/lib/design-tokens/mcdonalds/tokens.module.css +58 -0
  456. package/lib/design-tokens/target/fonts.css +26 -0
  457. package/lib/design-tokens/target/tokens.module.css +738 -0
  458. package/lib/design-tokens/tokens_netflix.theme.js +806 -0
  459. package/lib/design-tokens/tokens_netflix.theme.js.map +1 -0
  460. package/lib/directives/if-truthy.js +24 -0
  461. package/lib/directives/if-truthy.js.map +1 -0
  462. package/lib/directives/spread.js +29 -0
  463. package/lib/directives/spread.js.map +1 -0
  464. package/lib/index.js +84 -168
  465. package/lib/index.js.map +1 -0
  466. package/lib/scripts/convert-scss-to-ts.js +25 -0
  467. package/lib/scripts/convert-scss-to-ts.js.map +1 -0
  468. package/lib/scripts/extract-tokens.js +120 -0
  469. package/lib/scripts/extract-tokens.js.map +1 -0
  470. package/lib/scripts/generate-react-wrappers.js +229 -0
  471. package/lib/scripts/generate-react-wrappers.js.map +1 -0
  472. package/lib/scripts/generateWesparkleThemes.js +52 -0
  473. package/lib/scripts/generateWesparkleThemes.js.map +1 -0
  474. package/lib/toBeAccessible.js +18 -0
  475. package/lib/toBeAccessible.js.map +1 -0
  476. package/lib/utilities/is-mobile.js +10 -0
  477. package/lib/utilities/is-mobile.js.map +1 -0
  478. package/lib/utilities/story-helpers.js +14 -0
  479. package/lib/utilities/story-helpers.js.map +1 -0
  480. package/lib/vite.config.cdn.js +85 -0
  481. package/lib/vite.config.cdn.js.map +1 -0
  482. package/lib/vite.config.js +156 -0
  483. package/lib/vite.config.js.map +1 -0
  484. package/package.json +8 -9
  485. package/lib/design-tokens/brands copy/blue/_base.scss +0 -142
  486. package/lib/design-tokens/brands copy/blue/badge.scss +0 -5
  487. package/lib/design-tokens/brands copy/blue/bg.scss +0 -35
  488. package/lib/design-tokens/brands copy/blue/border-style.scss +0 -5
  489. package/lib/design-tokens/brands copy/blue/border.scss +0 -21
  490. package/lib/design-tokens/brands copy/blue/borderRadius.scss +0 -15
  491. package/lib/design-tokens/brands copy/blue/borderWidth.scss +0 -11
  492. package/lib/design-tokens/brands copy/blue/breakpoint.scss +0 -9
  493. package/lib/design-tokens/brands copy/blue/button.scss +0 -225
  494. package/lib/design-tokens/brands copy/blue/content.scss +0 -29
  495. package/lib/design-tokens/brands copy/blue/css/tokens_blue.module.d.ts +0 -3
  496. package/lib/design-tokens/brands copy/blue/css/tokens_blue.module.d.ts.map +0 -1
  497. package/lib/design-tokens/brands copy/blue/desktop-menu.scss +0 -5
  498. package/lib/design-tokens/brands copy/blue/fontFamilies.scss +0 -5
  499. package/lib/design-tokens/brands copy/blue/fontSize.scss +0 -17
  500. package/lib/design-tokens/brands copy/blue/fontWeights.scss +0 -7
  501. package/lib/design-tokens/brands copy/blue/footer.scss +0 -9
  502. package/lib/design-tokens/brands copy/blue/header.scss +0 -81
  503. package/lib/design-tokens/brands copy/blue/icon-size.scss +0 -6
  504. package/lib/design-tokens/brands copy/blue/letterSpacing.scss +0 -9
  505. package/lib/design-tokens/brands copy/blue/lineHeights.scss +0 -15
  506. package/lib/design-tokens/brands copy/blue/link.scss +0 -4
  507. package/lib/design-tokens/brands copy/blue/paragraphIndent.scss +0 -4
  508. package/lib/design-tokens/brands copy/blue/paragraphSpacing.scss +0 -4
  509. package/lib/design-tokens/brands copy/blue/progress-meter.scss +0 -4
  510. package/lib/design-tokens/brands copy/blue/shadow.scss +0 -8
  511. package/lib/design-tokens/brands copy/blue/spacing.scss +0 -21
  512. package/lib/design-tokens/brands copy/blue/textCase.scss +0 -5
  513. package/lib/design-tokens/brands copy/blue/textDecoration.scss +0 -5
  514. package/lib/design-tokens/brands copy/blue/tokens-all-blue.scss +0 -628
  515. package/lib/design-tokens/brands copy/blue/tokens-brand.scss +0 -31
  516. package/lib/design-tokens/brands copy/blue-v1/_base.scss +0 -76
  517. package/lib/design-tokens/brands copy/blue-v1/badge.scss +0 -5
  518. package/lib/design-tokens/brands copy/blue-v1/bg.scss +0 -34
  519. package/lib/design-tokens/brands copy/blue-v1/border-style.scss +0 -5
  520. package/lib/design-tokens/brands copy/blue-v1/border.scss +0 -21
  521. package/lib/design-tokens/brands copy/blue-v1/borderRadius.scss +0 -15
  522. package/lib/design-tokens/brands copy/blue-v1/borderWidth.scss +0 -11
  523. package/lib/design-tokens/brands copy/blue-v1/breakpoint.scss +0 -9
  524. package/lib/design-tokens/brands copy/blue-v1/button.scss +0 -199
  525. package/lib/design-tokens/brands copy/blue-v1/content.scss +0 -29
  526. package/lib/design-tokens/brands copy/blue-v1/desktop-menu.scss +0 -5
  527. package/lib/design-tokens/brands copy/blue-v1/fontFamilies.scss +0 -5
  528. package/lib/design-tokens/brands copy/blue-v1/fontSize.scss +0 -17
  529. package/lib/design-tokens/brands copy/blue-v1/fontWeights.scss +0 -9
  530. package/lib/design-tokens/brands copy/blue-v1/footer.scss +0 -9
  531. package/lib/design-tokens/brands copy/blue-v1/header.scss +0 -79
  532. package/lib/design-tokens/brands copy/blue-v1/icon-size.scss +0 -6
  533. package/lib/design-tokens/brands copy/blue-v1/letterSpacing.scss +0 -9
  534. package/lib/design-tokens/brands copy/blue-v1/lineHeights.scss +0 -15
  535. package/lib/design-tokens/brands copy/blue-v1/link.scss +0 -4
  536. package/lib/design-tokens/brands copy/blue-v1/paragraphIndent.scss +0 -4
  537. package/lib/design-tokens/brands copy/blue-v1/paragraphSpacing.scss +0 -4
  538. package/lib/design-tokens/brands copy/blue-v1/shadow.scss +0 -8
  539. package/lib/design-tokens/brands copy/blue-v1/spacing.scss +0 -21
  540. package/lib/design-tokens/brands copy/blue-v1/textCase.scss +0 -5
  541. package/lib/design-tokens/brands copy/blue-v1/textDecoration.scss +0 -5
  542. package/lib/design-tokens/brands copy/blue-v1/tokens-all-blue-v1.scss +0 -534
  543. package/lib/design-tokens/brands copy/blue-v1/tokens-brand.scss +0 -30
  544. package/lib/design-tokens/brands copy/cre8/_base.scss +0 -157
  545. package/lib/design-tokens/brands copy/cre8/badge.scss +0 -5
  546. package/lib/design-tokens/brands copy/cre8/bg.scss +0 -34
  547. package/lib/design-tokens/brands copy/cre8/border-style.scss +0 -5
  548. package/lib/design-tokens/brands copy/cre8/border.scss +0 -18
  549. package/lib/design-tokens/brands copy/cre8/borderRadius.scss +0 -15
  550. package/lib/design-tokens/brands copy/cre8/borderWidth.scss +0 -11
  551. package/lib/design-tokens/brands copy/cre8/breakpoint.scss +0 -9
  552. package/lib/design-tokens/brands copy/cre8/button.scss +0 -211
  553. package/lib/design-tokens/brands copy/cre8/content.scss +0 -29
  554. package/lib/design-tokens/brands copy/cre8/desktop-menu.scss +0 -5
  555. package/lib/design-tokens/brands copy/cre8/fontFamilies.scss +0 -4
  556. package/lib/design-tokens/brands copy/cre8/fontSize.scss +0 -17
  557. package/lib/design-tokens/brands copy/cre8/fontWeights.scss +0 -7
  558. package/lib/design-tokens/brands copy/cre8/footer.scss +0 -8
  559. package/lib/design-tokens/brands copy/cre8/header.scss +0 -81
  560. package/lib/design-tokens/brands copy/cre8/icon-size.scss +0 -6
  561. package/lib/design-tokens/brands copy/cre8/letterSpacing.scss +0 -10
  562. package/lib/design-tokens/brands copy/cre8/lineHeights.scss +0 -22
  563. package/lib/design-tokens/brands copy/cre8/link.scss +0 -4
  564. package/lib/design-tokens/brands copy/cre8/paragraphIndent.scss +0 -4
  565. package/lib/design-tokens/brands copy/cre8/paragraphSpacing.scss +0 -4
  566. package/lib/design-tokens/brands copy/cre8/progress-meter.scss +0 -4
  567. package/lib/design-tokens/brands copy/cre8/shadow.scss +0 -8
  568. package/lib/design-tokens/brands copy/cre8/spacing.scss +0 -21
  569. package/lib/design-tokens/brands copy/cre8/textCase.scss +0 -5
  570. package/lib/design-tokens/brands copy/cre8/textDecoration.scss +0 -5
  571. package/lib/design-tokens/brands copy/cre8/tokens-all-cre8.scss +0 -631
  572. package/lib/design-tokens/brands copy/cre8/tokens-brand.scss +0 -31
  573. package/lib/design-tokens/brands copy/femmecubator/base.scss +0 -64
  574. package/lib/design-tokens/brands copy/femmecubator/border.scss +0 -15
  575. package/lib/design-tokens/brands copy/femmecubator/color.scss +0 -56
  576. package/lib/design-tokens/brands copy/femmecubator/spacing.scss +0 -13
  577. package/lib/design-tokens/brands copy/femmecubator/tokens-all-femmecubator.scss +0 -139
  578. package/lib/design-tokens/brands copy/femmecubator/tokens-brand.scss +0 -8
  579. package/lib/design-tokens/brands copy/legacy/_base.scss +0 -103
  580. package/lib/design-tokens/brands copy/legacy/badge.scss +0 -5
  581. package/lib/design-tokens/brands copy/legacy/bg.scss +0 -34
  582. package/lib/design-tokens/brands copy/legacy/border-style.scss +0 -5
  583. package/lib/design-tokens/brands copy/legacy/border.scss +0 -17
  584. package/lib/design-tokens/brands copy/legacy/borderRadius.scss +0 -15
  585. package/lib/design-tokens/brands copy/legacy/borderWidth.scss +0 -11
  586. package/lib/design-tokens/brands copy/legacy/breakpoint.scss +0 -9
  587. package/lib/design-tokens/brands copy/legacy/button.scss +0 -225
  588. package/lib/design-tokens/brands copy/legacy/content.scss +0 -29
  589. package/lib/design-tokens/brands copy/legacy/desktop-menu.scss +0 -5
  590. package/lib/design-tokens/brands copy/legacy/fontFamilies.scss +0 -4
  591. package/lib/design-tokens/brands copy/legacy/fontSize.scss +0 -17
  592. package/lib/design-tokens/brands copy/legacy/fontWeights.scss +0 -10
  593. package/lib/design-tokens/brands copy/legacy/footer.scss +0 -9
  594. package/lib/design-tokens/brands copy/legacy/header.scss +0 -81
  595. package/lib/design-tokens/brands copy/legacy/icon-size.scss +0 -6
  596. package/lib/design-tokens/brands copy/legacy/letterSpacing.scss +0 -9
  597. package/lib/design-tokens/brands copy/legacy/lineHeights.scss +0 -19
  598. package/lib/design-tokens/brands copy/legacy/paragraphIndent.scss +0 -4
  599. package/lib/design-tokens/brands copy/legacy/paragraphSpacing.scss +0 -4
  600. package/lib/design-tokens/brands copy/legacy/progress-meter.scss +0 -4
  601. package/lib/design-tokens/brands copy/legacy/shadow.scss +0 -8
  602. package/lib/design-tokens/brands copy/legacy/spacing.scss +0 -20
  603. package/lib/design-tokens/brands copy/legacy/textCase.scss +0 -5
  604. package/lib/design-tokens/brands copy/legacy/textDecoration.scss +0 -5
  605. package/lib/design-tokens/brands copy/legacy/tokens-all-legacy.scss +0 -588
  606. package/lib/design-tokens/brands copy/legacy/tokens-brand.scss +0 -30
  607. package/lib/design-tokens/brands copy/marketing/_base.scss +0 -137
  608. package/lib/design-tokens/brands copy/marketing/asset.scss +0 -7
  609. package/lib/design-tokens/brands copy/marketing/badge.scss +0 -5
  610. package/lib/design-tokens/brands copy/marketing/bg.scss +0 -35
  611. package/lib/design-tokens/brands copy/marketing/border-style.scss +0 -5
  612. package/lib/design-tokens/brands copy/marketing/border.scss +0 -21
  613. package/lib/design-tokens/brands copy/marketing/borderRadius.scss +0 -15
  614. package/lib/design-tokens/brands copy/marketing/borderWidth.scss +0 -11
  615. package/lib/design-tokens/brands copy/marketing/breakpoint.scss +0 -9
  616. package/lib/design-tokens/brands copy/marketing/button.scss +0 -225
  617. package/lib/design-tokens/brands copy/marketing/content.scss +0 -29
  618. package/lib/design-tokens/brands copy/marketing/desktop-menu.scss +0 -5
  619. package/lib/design-tokens/brands copy/marketing/fontFamilies.scss +0 -4
  620. package/lib/design-tokens/brands copy/marketing/fontSize.scss +0 -17
  621. package/lib/design-tokens/brands copy/marketing/fontWeights.scss +0 -7
  622. package/lib/design-tokens/brands copy/marketing/footer.scss +0 -9
  623. package/lib/design-tokens/brands copy/marketing/header.scss +0 -81
  624. package/lib/design-tokens/brands copy/marketing/icon-size.scss +0 -6
  625. package/lib/design-tokens/brands copy/marketing/letterSpacing.scss +0 -9
  626. package/lib/design-tokens/brands copy/marketing/lineHeights.scss +0 -22
  627. package/lib/design-tokens/brands copy/marketing/link.scss +0 -4
  628. package/lib/design-tokens/brands copy/marketing/paragraphIndent.scss +0 -4
  629. package/lib/design-tokens/brands copy/marketing/paragraphSpacing.scss +0 -4
  630. package/lib/design-tokens/brands copy/marketing/progress-meter.scss +0 -4
  631. package/lib/design-tokens/brands copy/marketing/shadow.scss +0 -8
  632. package/lib/design-tokens/brands copy/marketing/spacing.scss +0 -21
  633. package/lib/design-tokens/brands copy/marketing/textCase.scss +0 -5
  634. package/lib/design-tokens/brands copy/marketing/textDecoration.scss +0 -5
  635. package/lib/design-tokens/brands copy/marketing/tokens-all-marketing.scss +0 -633
  636. package/lib/design-tokens/brands copy/marketing/tokens-brand.scss +0 -32
  637. package/lib/design-tokens/brands copy/minimalist/_base.scss +0 -81
  638. package/lib/design-tokens/brands copy/minimalist/asset.scss +0 -6
  639. package/lib/design-tokens/brands copy/minimalist/badge.scss +0 -5
  640. package/lib/design-tokens/brands copy/minimalist/bg.scss +0 -34
  641. package/lib/design-tokens/brands copy/minimalist/border-style.scss +0 -5
  642. package/lib/design-tokens/brands copy/minimalist/border.scss +0 -17
  643. package/lib/design-tokens/brands copy/minimalist/borderRadius.scss +0 -15
  644. package/lib/design-tokens/brands copy/minimalist/borderWidth.scss +0 -11
  645. package/lib/design-tokens/brands copy/minimalist/breakpoint.scss +0 -9
  646. package/lib/design-tokens/brands copy/minimalist/button.scss +0 -225
  647. package/lib/design-tokens/brands copy/minimalist/content.scss +0 -29
  648. package/lib/design-tokens/brands copy/minimalist/desktop-menu.scss +0 -5
  649. package/lib/design-tokens/brands copy/minimalist/fontFamilies.scss +0 -4
  650. package/lib/design-tokens/brands copy/minimalist/fontFamily.scss +0 -4
  651. package/lib/design-tokens/brands copy/minimalist/fontSize.scss +0 -17
  652. package/lib/design-tokens/brands copy/minimalist/fontWeights.scss +0 -6
  653. package/lib/design-tokens/brands copy/minimalist/footer.scss +0 -9
  654. package/lib/design-tokens/brands copy/minimalist/header.scss +0 -81
  655. package/lib/design-tokens/brands copy/minimalist/icon-size.scss +0 -6
  656. package/lib/design-tokens/brands copy/minimalist/letterSpacing.scss +0 -9
  657. package/lib/design-tokens/brands copy/minimalist/lineHeights.scss +0 -20
  658. package/lib/design-tokens/brands copy/minimalist/paragraphIndent.scss +0 -4
  659. package/lib/design-tokens/brands copy/minimalist/paragraphSpacing.scss +0 -4
  660. package/lib/design-tokens/brands copy/minimalist/progress-meter.scss +0 -4
  661. package/lib/design-tokens/brands copy/minimalist/shadow.scss +0 -8
  662. package/lib/design-tokens/brands copy/minimalist/spacing.scss +0 -20
  663. package/lib/design-tokens/brands copy/minimalist/textCase.scss +0 -5
  664. package/lib/design-tokens/brands copy/minimalist/textDecoration.scss +0 -5
  665. package/lib/design-tokens/brands copy/minimalist/tokens-all-minimalist.scss +0 -567
  666. package/lib/design-tokens/brands copy/minimalist/tokens-brand.scss +0 -32
@@ -1,213 +1,248 @@
1
- import { css as w, html as a, nothing as g } from "lit";
2
- import { ifDefined as u } from "lit/directives/if-defined.js";
3
- import { property as n, state as f, queryAll as z } from "lit/decorators.js";
4
- import { h as C } from "../../icon-D22g8aWB.js";
5
- import { s as _ } from "../../Caret_Right-DZH0BlfG.js";
6
- import { Cre8Element as P } from "../cre8-element.js";
7
- import { Cre8Button as y } from "../button/button.js";
8
- const k = `<svg fill="currentColor" width="16" height="16" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
9
- <path d="M12.1508 14.7578C12.2184 14.8254 12.272 14.9056 12.3085 14.9939C12.3451 15.0822 12.3639 15.1768 12.3639 15.2724C12.3639 15.3679 12.3451 15.4625 12.3085 15.5508C12.272 15.6391 12.2184 15.7193 12.1508 15.7869C12.0832 15.8544 12.003 15.908 11.9147 15.9446C11.8265 15.9812 11.7318 16 11.6363 16C11.5407 16 11.4461 15.9812 11.3578 15.9446C11.2695 15.908 11.1893 15.8544 11.1218 15.7869L3.8494 8.51452C3.78178 8.44698 3.72814 8.36677 3.69154 8.27849C3.65495 8.1902 3.63611 8.09557 3.63611 8C3.63611 7.90443 3.65495 7.8098 3.69154 7.72151C3.72814 7.63323 3.78178 7.55302 3.8494 7.48548L11.1218 0.213121C11.2582 0.0766618 11.4433 -3.80414e-09 11.6363 0C11.8293 3.80414e-09 12.0143 0.0766618 12.1508 0.213121C12.2873 0.34958 12.3639 0.534658 12.3639 0.72764C12.3639 0.920622 12.2873 1.1057 12.1508 1.24216L5.39205 8L12.1508 14.7578Z"/>
10
- </svg>
11
- `, $ = `<svg fill="currentColor" width="16" height="16" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
12
- <path d="M15.7869 14.7577C15.8544 14.8253 15.908 14.9055 15.9446 14.9937C15.9812 15.082 16 15.1766 16 15.2722C16 15.3678 15.9812 15.4624 15.9446 15.5507C15.908 15.6389 15.8544 15.7191 15.7869 15.7867C15.7193 15.8543 15.6391 15.9079 15.5508 15.9444C15.4625 15.981 15.3679 15.9998 15.2724 15.9998C15.1768 15.9998 15.0822 15.981 14.9939 15.9444C14.9056 15.9079 14.8254 15.8543 14.7579 15.7867L7.48557 8.51443C7.41795 8.44689 7.36432 8.36669 7.32772 8.2784C7.29112 8.19012 7.27228 8.09549 7.27228 7.99992C7.27228 7.90435 7.29112 7.80972 7.32772 7.72143C7.36432 7.63315 7.41795 7.55294 7.48557 7.4854L14.7579 0.213119C14.8943 0.076661 15.0794 -3.8041e-09 15.2724 0C15.4653 3.8041e-09 15.6504 0.076661 15.7869 0.213119C15.9233 0.349576 16 0.534653 16 0.727633C16 0.920613 15.9233 1.10569 15.7869 1.24215L9.0282 7.99992L15.7869 14.7577ZM1.75592 7.99992L8.5146 1.24215C8.65106 1.10569 8.72772 0.920613 8.72772 0.727633C8.72772 0.534653 8.65106 0.349576 8.5146 0.213119C8.37814 0.076661 8.19306 1.43782e-09 8.00008 0C7.8071 -1.43781e-09 7.62203 0.076661 7.48557 0.213119L0.213286 7.4854C0.145671 7.55294 0.0920317 7.63315 0.0554344 7.72143C0.0188371 7.80972 0 7.90435 0 7.99992C0 8.09549 0.0188371 8.19012 0.0554344 8.2784C0.0920317 8.36669 0.145671 8.44689 0.213286 8.51443L7.48557 15.7867C7.55314 15.8543 7.63335 15.9079 7.72163 15.9444C7.80991 15.981 7.90453 15.9998 8.00008 15.9998C8.09564 15.9998 8.19026 15.981 8.27854 15.9444C8.36682 15.9079 8.44703 15.8543 8.5146 15.7867C8.58217 15.7191 8.63576 15.6389 8.67233 15.5507C8.7089 15.4624 8.72772 15.3678 8.72772 15.2722C8.72772 15.1766 8.7089 15.082 8.67233 14.9937C8.63576 14.9055 8.58217 14.8253 8.5146 14.7577L1.75592 7.99992Z"/>
13
- </svg>
14
- `, v = {
15
- md: 768,
16
- lg: 960
17
- }, x = (d = "768") => !window.matchMedia(`(min-width: ${d}px)`).matches, R = w`*,::slotted(*),*:before,*:after{box-sizing:border-box}:root{--size-base-unit: 0.5rem}[dir=rtl]{--rtlTranslateX: 50%;--rtlGradientToRight: 270deg;--rtlRotate45Inverse: -45deg}:host{--cre8-z-index-1: 1;--cre8-z-index-50: 50;--cre8-z-index-100: 100;--cre8-z-index-200: 200;--cre8-z-index-1030: 1030;--cre8-anim-fade-quick: 0.35s;--cre8-anim-ease: ease}@keyframes fadeIn{100%{opacity:1}}@keyframes slideIn{100%{transform:translateX(0)}}@keyframes slideInFwd{100%{width:272px;height:272px}}@keyframes slideOutRight{100%{width:272px;height:272px}}@keyframes slideUp{100%{transform:translateY(0)}}@media(width >= 481px){@keyframes slideInFwd{100%{width:417px;height:417px}}@keyframes slideOutRight{100%{width:417px;height:417px}}}@media(width >= 48rem){@keyframes slideInFwd{100%{width:330px;height:330px}}@keyframes slideOutRight{100%{width:330px;height:330px;transform:translateX(calc(100vw - 45px))}}}@media(width >= 60rem){@keyframes slideInFwd{100%{width:460px;height:460px}}@keyframes slideOutRight{100%{width:460px;height:460px;transform:translateX(calc(100vw - 45px))}}}@media(width >= 75rem){@keyframes slideInFwd{100%{width:592px;height:591px}}@keyframes slideOutRight{100%{width:592px;height:591px;transform:translateX(calc(100vw - 45px))}}}@media(width >= 87.5rem){@keyframes slideOutRight{100%{width:592px;height:591px;transform:translateX(calc(100vw - 120px))}}}@media(width >= 2200px){@keyframes slideOutRight{100%{width:592px;height:591px;transform:translateX(calc(100vw - 592px))}}}span.ripple{position:absolute;border-radius:50%;transform:scale(0);animation:ripple 600ms linear;background-color:var(--ripple-bg-color)}@keyframes ripple{to{transform:scale(4);opacity:1}}:root{--size-base-unit: 0.5rem}[dir=rtl]{--rtlTranslateX: 50%;--rtlGradientToRight: 270deg;--rtlRotate45Inverse: -45deg}:host{display:inline-flex}.cre8-c-pagination__text{font-family:var(--cre8-typography-label-small-font-family);font-size:var(--cre8-typography-label-small-font-size);font-weight:var(--cre8-typography-label-small-font-weight);line-height:var(--cre8-typography-label-small-line-height);text-decoration:var(--cre8-typography-label-small-text-decoration);text-transform:var(--cre8-typography-label-small-text-transform);padding:0.5rem}`;
18
- var N = Object.defineProperty, p = (d, t, e, s) => {
19
- for (var r = void 0, o = d.length - 1, c; o >= 0; o--)
20
- (c = d[o]) && (r = c(t, e, r) || r);
21
- return r && N(t, e, r), r;
1
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
2
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
4
+ else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
22
6
  };
23
- const b = class b extends P {
24
- constructor() {
25
- super(...arguments), this.currentPage = 1, this.display = "default";
26
- }
27
- // Properties below are for future 'range' variant for table pagination
28
- // private get _currentResults() {
29
- // return this.pageSize * (this.currentPage - 1);
30
- // }
31
- // private get _firstInRange() {
32
- // return this._currentResults + 1;
33
- // }
34
- // private get _lastInRange() {
35
- // const last = this._firstInRange + (this.pageSize - 1);
36
- // return last > this.totalResults ? this.totalResults : last;
37
- // }
38
- get _totalPages() {
39
- return Math.ceil(this.totalResults / this.pageSize);
40
- }
41
- render() {
42
- const t = this.componentClassNames("cre8-c-page-counter", {});
43
- return a`
44
- <div class='${t}'>
45
- <span class="cre8-c-pagination__text" aria-live="polite">
46
- ${!this.display || this.display === "default" ? a`${this.currentPage}` : a`${this.currentPage} of ${this._totalPages}`}
47
- </span>
48
- </div>
49
- `;
50
- }
51
- };
52
- b.styles = [R];
53
- let h = b;
54
- p([
55
- n({ type: Boolean, reflect: !0 })
56
- ], h.prototype, "rangeVariant");
57
- p([
58
- n()
59
- ], h.prototype, "currentPage");
60
- p([
61
- n()
62
- ], h.prototype, "totalResults");
63
- p([
64
- n()
65
- ], h.prototype, "pageSize");
66
- p([
67
- n()
68
- ], h.prototype, "display");
69
- customElements.get("cre8-page-counter") === void 0 && customElements.define("cre8-page-counter", h);
70
- const S = w`*,::slotted(*),*:before,*:after{box-sizing:border-box}:root{--size-base-unit: 0.5rem}[dir=rtl]{--rtlTranslateX: 50%;--rtlGradientToRight: 270deg;--rtlRotate45Inverse: -45deg}:host{--cre8-z-index-1: 1;--cre8-z-index-50: 50;--cre8-z-index-100: 100;--cre8-z-index-200: 200;--cre8-z-index-1030: 1030;--cre8-anim-fade-quick: 0.35s;--cre8-anim-ease: ease}@keyframes fadeIn{100%{opacity:1}}@keyframes slideIn{100%{transform:translateX(0)}}@keyframes slideInFwd{100%{width:272px;height:272px}}@keyframes slideOutRight{100%{width:272px;height:272px}}@keyframes slideUp{100%{transform:translateY(0)}}@media(width >= 481px){@keyframes slideInFwd{100%{width:417px;height:417px}}@keyframes slideOutRight{100%{width:417px;height:417px}}}@media(width >= 48rem){@keyframes slideInFwd{100%{width:330px;height:330px}}@keyframes slideOutRight{100%{width:330px;height:330px;transform:translateX(calc(100vw - 45px))}}}@media(width >= 60rem){@keyframes slideInFwd{100%{width:460px;height:460px}}@keyframes slideOutRight{100%{width:460px;height:460px;transform:translateX(calc(100vw - 45px))}}}@media(width >= 75rem){@keyframes slideInFwd{100%{width:592px;height:591px}}@keyframes slideOutRight{100%{width:592px;height:591px;transform:translateX(calc(100vw - 45px))}}}@media(width >= 87.5rem){@keyframes slideOutRight{100%{width:592px;height:591px;transform:translateX(calc(100vw - 120px))}}}@media(width >= 2200px){@keyframes slideOutRight{100%{width:592px;height:591px;transform:translateX(calc(100vw - 592px))}}}span.ripple{position:absolute;border-radius:50%;transform:scale(0);animation:ripple 600ms linear;background-color:var(--ripple-bg-color)}@keyframes ripple{to{transform:scale(4);opacity:1}}:root{--size-base-unit: 0.5rem}[dir=rtl]{--rtlTranslateX: 50%;--rtlGradientToRight: 270deg;--rtlRotate45Inverse: -45deg}:host{display:var(--pagination-display, inline-flex);justify-content:var(--pagination-justify-content, center);align-items:var(--pagination-align-items, center);--cre8-button-width: 2rem;--cre8-button-height: 2rem;--cre8-button-min-width: 2rem;--cre8-button-min-height: 2rem;--cre8-button-padding-horizontal-small: 0px;--cre8-button-padding-vertical-small: 0px}*,::slotted(*),*:before,*:after{box-sizing:border-box;width:auto;height:auto;display:flex;justify-content:center;--cre8-button-margin-right: var(--cre8-spacing-2);--cre8-button-margin-left: var(--cre8-spacing-2);margin-right:var(--cre8-button-margin-right);margin-left:var(--cre8-button-margin-left);align-items:center}[aria-current=true],#current{--cre8-color-button-tertiary-bg: var( --cre8-color-bg-strong);--cre8-color-button-tertiary-content: var(--cre8-color-content-knockout);--cre8-color-button-tertiary-border: var(--cre8-color-border-transparent)}[aria-current=true]:hover,[aria-current=true]:active,#current:hover,#current:active{border-radius:var(--cre8-border-radius-button);--cre8-color-button-tertiary-bg-hover: var(--cre8-color-bg-strong);--cre8-color-button-tertiary-content-hover: var(--cre8-color-content-knockout)}[aria-current=true]:hover:focus,[aria-current=true]:hover:focus-visible,[aria-current=true]:hover:focus-within,[aria-current=true]:active:focus,[aria-current=true]:active:focus-visible,[aria-current=true]:active:focus-within,#current:hover:focus,#current:hover:focus-visible,#current:hover:focus-within,#current:active:focus,#current:active:focus-visible,#current:active:focus-within{border-radius:var(--cre8-border-radius-button);--cre8-color-button-tertiary-bg-active: var(--cre8-color-bg-strong);--cre8-color-button-tertiary-content-active: var(--cre8-color-content-knockout);outline:var(--cre8-border-width-focus) solid var(--cre8-color-border-active-outline);outline-offset:0.125rem}.cre8-c-pagination--compact,.cre8-c-pagination--icon-only,.cre8-c-pagination--range{--cre8-button-width: 3rem;--cre8-button-height: 3rem;--cre8-button-min-width: 3rem;--cre8-button-min-height: 3rem}.cre8-c-pagionation__icon{fill:var(--cre8-color-button-tertiary-content)}.cre8-c-pagination__icon:has(cre8-button:disabled){color:var(--cre8-color-button-tertiary-content-disabled)}.cre8-c-pagination [aria-disabled=true]{fill:var(--cre8-color-content-default);--cre8-color-button-tertiary-content: var(--cre8-color-content-default)}`;
71
- var T = Object.defineProperty, L = Object.getOwnPropertyDescriptor, l = (d, t, e, s) => {
72
- for (var r = s > 1 ? void 0 : s ? L(t, e) : t, o = d.length - 1, c; o >= 0; o--)
73
- (c = d[o]) && (r = (s ? c(t, e, r) : c(r)) || r);
74
- return s && r && T(t, e, r), r;
75
- };
76
- const m = class m extends P {
77
- constructor() {
78
- super(...arguments), this._currentPage = 99, this._pageSize = 10, this.visiblePages = 5, this._handleKeydown = (t, e) => (s) => {
79
- s.code === "Enter" && this._goToPage(t, e);
80
- }, this._goToPage = (t, e) => () => {
81
- const s = this._currentPage;
82
- let r;
83
- this.buttons.forEach((o) => {
84
- const c = new y();
85
- return c.hideText && c.text === e && (r = c, r.shadowRoot.querySelector(".cre8-c-button").blur()), null;
86
- }), this._currentPage = t, this.currentPage = this._currentPage, this.requestUpdate("currentPage", s), this.dispatchEvent(new CustomEvent(
87
- "pagination.click",
88
- { detail: { buttonName: e ?? this.currentPage.toString(), value: this.currentPage } }
89
- ));
90
- };
91
- }
92
- get pageSize() {
93
- return this._pageSize;
94
- }
95
- set pageSize(t) {
96
- const e = this._pageSize;
97
- this._pageSize = t, this.requestUpdate("pageSize", e);
98
- }
99
- get currentPage() {
100
- return this._currentPage;
101
- }
102
- set currentPage(t) {
103
- const e = this._currentPage;
104
- this._currentPage = t, this.requestUpdate("currentPage", e);
105
- }
106
- connectedCallBack() {
107
- super.connectedCallback();
108
- }
109
- get maxVisiblePages() {
110
- const t = {
111
- md: 5
112
- };
113
- return x(v.lg.toString()) ? x(v.md.toString()) ? 0 : Math.min(t.md, this.visiblePages) : this.visiblePages;
114
- }
115
- get totalPages() {
116
- return Math.ceil(this.totalResults / this.pageSize);
117
- }
118
- get hasNoPreviousPage() {
119
- return this._currentPage <= 1;
120
- }
121
- get hasNoNextPage() {
122
- return this._currentPage >= this.totalPages;
123
- }
124
- _onHandleResize() {
125
- this.requestUpdate();
126
- }
127
- handleResize() {
128
- this._onHandleResize.bind(this);
129
- }
130
- // get range of pages to display [3, 4, 5], [2, 3, 4, 5]
131
- get pageRange() {
132
- const t = Math.floor(this.maxVisiblePages / 2);
133
- let e = this.currentPage - t;
134
- e = Math.min(e, this.totalPages - this.maxVisiblePages + 1), e = Math.max(e, 1);
135
- const s = Math.min(e + this.maxVisiblePages - 1, this.totalPages);
136
- return [...Array(this.totalPages)].map((r, o) => o + 1).slice(e - 1, s);
137
- }
138
- async firstUpdated() {
139
- if (await this.updateComplete, this._pageSize !== this.pageSize) {
140
- const t = this._pageSize;
141
- this._pageSize = this.pageSize, this.requestUpdate("pageSize", t);
7
+ /* eslint-disable import/prefer-default-export */
8
+ /* eslint-disable lit/no-template-map */
9
+ import { html, nothing, } from 'lit';
10
+ import { ifDefined } from 'lit/directives/if-defined.js';
11
+ import { property, queryAll, state } from 'lit/decorators.js';
12
+ import svgCaretLeft from '/Users/tylersmbp/Projects/cre8-web-components/packages/cre8-wc/icons/System/Regular/Caret_Left.svg?raw';
13
+ import svgFirstPage from '/Users/tylersmbp/Projects/cre8-web-components/packages/cre8-wc/icons/System/Regular/Caret_Double_Left.svg?raw';
14
+ import svgLastPage from '/Users/tylersmbp/Projects/cre8-web-components/packages/cre8-wc/icons/System/Regular/Caret_Double_Right.svg?raw';
15
+ import svgCaretRight from '/Users/tylersmbp/Projects/cre8-web-components/packages/cre8-wc/icons/System/Regular/Caret_Right.svg?raw';
16
+ import { Cre8Element } from '../cre8-element';
17
+ import { Cre8Button } from '../button/button';
18
+ import { isMobile, screenSizes } from '../../utilities/is-mobile';
19
+ import './page-counter/page-counter';
20
+ import styles from './pagination.styles.js';
21
+ /**
22
+ * The Pagination component is used to split up a large amount of results
23
+ * by showing only a certain amount on each page. You can cycle through
24
+ * the pages using Page Numbers, Next and Previous Buttons, or optional
25
+ * First Page and Last Page Buttons. This component is also used by Table
26
+ * to cycle through rows of results. Pagination has 3 display options:
27
+ *
28
+ * **default**: Can contain up to seven Page Numbers (ellipses included)
29
+ * at a time flanked by Next and Previous Buttons. When there are more than
30
+ * seven pages, numbers start getting replaced by ellipses. Use this option
31
+ * when you have a lot of horizontal space in a layout. It should not be used
32
+ * for mobile web layouts since its buttons are smaller than the minimum touch target of 44px.
33
+ * The component has built in responsivity to mobile page size so you dont have tohandle this
34
+ * seperately
35
+ *
36
+ *
37
+ * **compact** : Best used as a summary of where you are among pages or table rows flanked by
38
+ * Previous and Next Buttons. Use this option when you have limited horizontal space but still
39
+ * need to show where users are among results. Great for mobile layouts.
40
+ *
41
+ *
42
+ * **icon-only** : Use this option in very tight spaces when it’s not required to show users
43
+ * where they are among results. Great for mobile layouts.
44
+ *
45
+ *
46
+ * ## HOW TO USE
47
+ *
48
+ * Select an option from the “display” dropdown depending on layout width
49
+ * Select where your current page is from the “Page” dropdown
50
+ * To show less pages when using Full Numbers, use the "visiblePages” toggles
51
+ * To hide the First Page and Last Page Buttons, turn on the “hideFirstLastButton” toggle
52
+ * To change the states of page numbers or buttons, interact with the buttond to invoke each “State”
53
+ * When using Compact Numbers, you can choose between “compact” and “icon-only” formats
54
+ *
55
+ *
56
+ * ## ACCESSIBILITY NOTE
57
+ *
58
+ * To best orient people using screen readers, push focus to the top of
59
+ * the list of results after any of the pagination buttons have been triggered,
60
+ * **except for the currently selected one**. Focus target could be a visual results heading,
61
+ * or the top heading of the results container of the page selected
62
+ * via a programmatic selector, e.g. < section id=“results” aria-label="results-section" > or
63
+ * < div role= “group” aria-label=“results” >.
64
+ *
65
+ * @dependency cre8-button, cre8-icon, cre8-pagination-counter
66
+ * @csspart icon - distinguishes the page buttons from the icon buttons
67
+ * @cssproperty "--pagination-display" - controls the display css property
68
+ * @cssproperty "--pagination-justify-content" - controls horizontal alignment of pagination
69
+ * @cssproperty "--pagination-align-items" - controls vertical alignment of pagination
70
+ */
71
+ export class Cre8Pagination extends Cre8Element {
72
+ constructor() {
73
+ super(...arguments);
74
+ this._currentPage = 99;
75
+ this._pageSize = 10;
76
+ /**
77
+ * Controls how many page buttons are displayVarianted on the page
78
+ * at once, if container size permits. recommended max = 5 pages
79
+ *
80
+ * @attr number
81
+ */
82
+ this.visiblePages = 5;
83
+ this._handleKeydown = (page, _buttonName) => (e) => {
84
+ if (e.code === 'Enter') {
85
+ this._goToPage(page, _buttonName); /* 2 */
86
+ }
87
+ };
88
+ this._goToPage = (page, _buttonName) => () => {
89
+ const old = this._currentPage;
90
+ let focusButton;
91
+ this.buttons.forEach((_) => {
92
+ const b = new Cre8Button();
93
+ if (b.hideText && (b.text === _buttonName)) {
94
+ focusButton = b;
95
+ focusButton.shadowRoot.querySelector('.cre8-c-button').blur();
96
+ }
97
+ return null;
98
+ });
99
+ this._currentPage = page;
100
+ this.currentPage = this._currentPage;
101
+ this.requestUpdate('currentPage', old);
102
+ this.dispatchEvent(new CustomEvent('pagination.click', { detail: { buttonName: _buttonName ?? this.currentPage.toString(), value: this.currentPage } }));
103
+ };
104
+ }
105
+ /**
106
+ * how many elements will displayVariant per page, indicated by business to typically be 20
107
+ * @attr number
108
+ */
109
+ get pageSize() {
110
+ return this._pageSize;
111
+ }
112
+ set pageSize(newSize) {
113
+ const oldSize = this._pageSize;
114
+ this._pageSize = newSize;
115
+ this.requestUpdate('pageSize', oldSize);
116
+ }
117
+ get currentPage() {
118
+ return this._currentPage;
119
+ }
120
+ set currentPage(newPage) {
121
+ const oldPage = this._currentPage;
122
+ this._currentPage = newPage;
123
+ this.requestUpdate('currentPage', oldPage);
124
+ }
125
+ connectedCallBack() {
126
+ super.connectedCallback();
127
+ }
128
+ get maxVisiblePages() {
129
+ const allowedVisiblePages = {
130
+ md: 5,
131
+ };
132
+ // lg and up
133
+ if (!isMobile(screenSizes.lg.toString())) {
134
+ return this.visiblePages;
135
+ }
136
+ if (!isMobile(screenSizes.md.toString())) {
137
+ return Math.min(allowedVisiblePages.md, this.visiblePages);
138
+ }
139
+ return 0;
140
+ }
141
+ get totalPages() {
142
+ return Math.ceil(this.totalResults / this.pageSize);
143
+ }
144
+ get hasNoPreviousPage() {
145
+ return this._currentPage <= 1;
142
146
  }
143
- if (this.windowWidth = window.innerWidth, window.addEventListener("resize", () => {
144
- if (this.windowWidth !== window.innerWidth) {
145
- const t = this.windowWidth;
146
- this.windowWidth = window.innerWidth, this.handleResize(), this.requestUpdate("isResponsive", t);
147
- }
148
- }), this._currentPage !== this.currentPage) {
149
- const t = this._currentPage;
150
- this._currentPage = this.currentPage, this.requestUpdate("currentPage", t);
147
+ get hasNoNextPage() {
148
+ return this._currentPage >= this.totalPages;
151
149
  }
152
- }
153
- disconnectedCallback() {
154
- window.removeEventListener("resize", this.handleResize), super.disconnectedCallback();
155
- }
156
- displayTypes() {
157
- return a`<cre8-page-counter
150
+ _onHandleResize() {
151
+ this.requestUpdate();
152
+ }
153
+ handleResize() {
154
+ this._onHandleResize.bind(this);
155
+ }
156
+ // get range of pages to display [3, 4, 5], [2, 3, 4, 5]
157
+ get pageRange() {
158
+ const left = Math.floor(this.maxVisiblePages / 2);
159
+ let startPage = this.currentPage - left;
160
+ startPage = Math.min(startPage, this.totalPages - this.maxVisiblePages + 1);
161
+ startPage = Math.max(startPage, 1);
162
+ const endPage = Math.min(startPage + this.maxVisiblePages - 1, this.totalPages);
163
+ return [...Array(this.totalPages)].map((_, index) => index + 1).slice(startPage - 1, endPage);
164
+ }
165
+ async firstUpdated() {
166
+ await this.updateComplete;
167
+ if (this._pageSize !== this.pageSize) {
168
+ const old = this._pageSize;
169
+ this._pageSize = this.pageSize;
170
+ this.requestUpdate('pageSize', old);
171
+ }
172
+ this.windowWidth = window.innerWidth;
173
+ window.addEventListener('resize', () => {
174
+ if (this.windowWidth !== window.innerWidth) {
175
+ const oldWidth = this.windowWidth;
176
+ this.windowWidth = window.innerWidth;
177
+ this.handleResize();
178
+ this.requestUpdate('isResponsive', oldWidth);
179
+ }
180
+ });
181
+ if (this._currentPage !== this.currentPage) {
182
+ const old = this._currentPage;
183
+ this._currentPage = this.currentPage;
184
+ this.requestUpdate('currentPage', old);
185
+ }
186
+ }
187
+ disconnectedCallback() {
188
+ window.removeEventListener('resize', this.handleResize);
189
+ super.disconnectedCallback();
190
+ }
191
+ displayTypes() {
192
+ return html `<cre8-page-counter
158
193
  currentPage=${this.currentPage}
159
- style="display:${this.display === "compact" ? "flex" : "none"};"
194
+ style="display:${this.display === 'compact' ? 'flex' : 'none'};"
160
195
  totalResults=${this.totalResults}
161
196
  pageSize=${this._pageSize}
162
197
  display=${this.display}>
163
198
  </cre8-page-counter>`;
164
- }
165
- goToPage(t, e) {
166
- return this._goToPage(t, e).bind(this);
167
- }
168
- handleKeydown(t, e) {
169
- return this._handleKeydown(t, e);
170
- }
171
- render() {
172
- const t = this.componentClassNames("cre8-c-pagination", {
173
- "cre8-c-pagination--compact": this.display !== void 0 && this.display === "compact",
174
- "cre8-c-pagination--icon-only": this.display !== void 0 && this.display === "icon-only"
175
- });
176
- return a`<nav
199
+ }
200
+ goToPage(page, buttonName) {
201
+ return this._goToPage(page, buttonName).bind(this);
202
+ }
203
+ handleKeydown(page, buttonName) {
204
+ return this._handleKeydown(page, buttonName);
205
+ }
206
+ render() {
207
+ const classNames = this.componentClassNames('cre8-c-pagination', {
208
+ 'cre8-c-pagination--compact': this.display !== undefined && this.display === 'compact',
209
+ 'cre8-c-pagination--icon-only': this.display !== undefined && this.display === 'icon-only',
210
+ });
211
+ return html `<nav
177
212
  aria-label="pagination"
178
- class=${t}>
213
+ class=${classNames}>
179
214
  <slot></slot>
180
- ${this.hideLastAndFirstButtons ? g : a` <cre8-button
215
+ ${!this.hideLastAndFirstButtons ? html ` <cre8-button
181
216
  variant="tertiary"
182
217
  size="sm"
183
218
  text=""
184
219
  hideText
185
220
  part="icon"
186
- aria-disabled="${u(this.hasNoPreviousPage)}"
221
+ aria-disabled="${ifDefined(this.hasNoPreviousPage)}"
187
222
  ?disabled=${this.hasNoPreviousPage}
188
- @click=${this.goToPage(1, "First Page")}
189
- @keydown=${this.handleKeydown(1, "First Page")}
223
+ @click=${this.goToPage(1, 'First Page')}
224
+ @keydown=${this.handleKeydown(1, 'First Page')}
190
225
 
191
226
  >
192
227
  <span slot="before">
193
228
  <cre8-icon
194
229
  className="cre8-c-pagination__icon"
195
230
  aria-label="First Page"
196
- svg=${$}
231
+ svg=${svgFirstPage}
197
232
  size="24">
198
233
  </cre8-icon>
199
234
  </span>
200
- </cre8-button>`}
235
+ </cre8-button>` : nothing}
201
236
  <cre8-button
202
237
  variant="tertiary"
203
238
  size="sm"
204
239
  hideText
205
240
  text=""
206
241
  part="icon"
207
- aria-disabled="${u(this.hasNoPreviousPage)}"
242
+ aria-disabled="${ifDefined(this.hasNoPreviousPage)}"
208
243
  ?disabled=${this.hasNoPreviousPage}
209
- @click=${this.goToPage(this._currentPage - 1, "Previous Page")}
210
- @keydown=${this.handleKeydown(this.currentPage - 1, "Previous Page")}
244
+ @click=${this.goToPage(this._currentPage - 1, 'Previous Page')}
245
+ @keydown=${this.handleKeydown(this.currentPage - 1, 'Previous Page')}
211
246
 
212
247
  >
213
248
  <span slot="before">
@@ -215,7 +250,7 @@ const m = class m extends P {
215
250
  className="cre8-c-pagination__icon"
216
251
  aria-label="Previous Page"
217
252
  slot="before"
218
- svg=${k}
253
+ svg=${svgCaretLeft}
219
254
  size="24"
220
255
 
221
256
  >
@@ -224,17 +259,23 @@ const m = class m extends P {
224
259
  </cre8-button>
225
260
 
226
261
  ${this.displayTypes()}
227
- ${!this.display || this.display === "default" ? a`${this.pageRange[this.pageRange.length - 1] > 1 && this.pageRange[0] !== 1 ? a`<cre8-button hideText iconName="ellipsis" variant="tertiary" size="sm" aria-disabled="true" inert></cre8-button>` : g}
228
- ${this.pageRange.map((e) => e === this.currentPage ? a`<cre8-button variant="tertiary" tab-index="-1" text="${e}" class="icon-only" size="sm" id="current"></cre8-button>` : a`<cre8-button
262
+ ${!this.display || this.display === 'default'
263
+ ? html `${this.pageRange[this.pageRange.length - 1] > 1 && this.pageRange[0] !== 1
264
+ ? html `<cre8-button hideText iconName="ellipsis" variant="tertiary" size="sm" aria-disabled="true" inert></cre8-button>`
265
+ : nothing}
266
+ ${this.pageRange.map((page) => (page === this.currentPage
267
+ ? html `<cre8-button variant="tertiary" tab-index="-1" text="${page}" class="icon-only" size="sm" id="current"></cre8-button>`
268
+ : html `<cre8-button
229
269
  variant="tertiary"
230
270
  size="sm"
231
- text="${e}"
271
+ text="${page}"
232
272
  class="icon-only"
233
- id="${e}"
234
- @click=${this.goToPage(e, e.toString())}
235
- @keydown=${this.handleKeydown(e, e.toString())}>
236
- </cre8-button>`)}
237
- ${this.pageRange[this.pageRange.length - 1] < this.totalPages ? a`<cre8-button
273
+ id="${page}"
274
+ @click=${this.goToPage(page, page.toString())}
275
+ @keydown=${this.handleKeydown(page, page.toString())}>
276
+ </cre8-button>`))}
277
+ ${this.pageRange[this.pageRange.length - 1] < this.totalPages
278
+ ? html `<cre8-button
238
279
  hideText
239
280
  iconName="ellipsis"
240
281
  text="ellipsis"
@@ -242,39 +283,42 @@ const m = class m extends P {
242
283
  size="sm"
243
284
  aria-disabled="true"
244
285
  inert>
245
- </cre8-button>` : g}` : g}
286
+ </cre8-button>`
287
+ : nothing}`
288
+ : nothing}
246
289
  <cre8-button
247
290
  variant="tertiary"
248
291
  size="sm"
249
292
  part="icon"
250
293
  hideText
251
294
  text=""
252
- aria-disabled="${u(this.hasNoNextPage)}"
295
+ aria-disabled="${ifDefined(this.hasNoNextPage)}"
253
296
  ?disabled=${this.hasNoNextPage}
254
- @click=${this.goToPage(this.currentPage + 1, "Next Page")}
255
- @keydown=${this.handleKeydown(this.currentPage + 1, "Next Page")}
297
+ @click=${this.goToPage(this.currentPage + 1, 'Next Page')}
298
+ @keydown=${this.handleKeydown(this.currentPage + 1, 'Next Page')}
256
299
 
257
300
  >
258
301
  <span slot="before">
259
302
  <cre8-icon
260
303
  aria-label="Next Page"
261
304
  className="cre8-c-pagination__icon"
262
- slot="before" svg=${_}
305
+ slot="before" svg=${svgCaretRight}
263
306
  size="24">
264
307
  </cre8-icon>
265
308
  </span>
266
309
  </cre8-button>
267
310
 
268
- ${this.hideLastAndFirstButtons ? g : a` <cre8-button
311
+ ${!this.hideLastAndFirstButtons
312
+ ? html ` <cre8-button
269
313
  variant="tertiary"
270
314
  size="sm"
271
315
  hideText
272
316
  text=""
273
317
  part="icon"
274
- aria-disabled="${u(this.hasNoNextPage)}"
318
+ aria-disabled="${ifDefined(this.hasNoNextPage)}"
275
319
  ?disabled=${this.hasNoNextPage}
276
- @click=${this.goToPage(this.totalPages, "Last Page")}
277
- @keydown=${this.handleKeydown(this.totalPages, "Last Page")}
320
+ @click=${this.goToPage(this.totalPages, 'Last Page')}
321
+ @keydown=${this.handleKeydown(this.totalPages, 'Last Page')}
278
322
 
279
323
  >
280
324
  <span slot="before">
@@ -282,51 +326,52 @@ const m = class m extends P {
282
326
  aria-label="Last Page"
283
327
  className="cre8-c-pagination__icon"
284
328
  slot="before"
285
- svg=${C}
329
+ svg=${svgLastPage}
286
330
  size="24"
287
331
  >
288
332
  </cre8-icon>
289
333
  </span>
290
- </cre8-button>`}
334
+ </cre8-button>`
335
+ : nothing}
291
336
 
292
337
  </nav>`;
293
- }
294
- };
295
- m.styles = [S], m.elementDefinitions = {
296
- "cre8-button": y
297
- };
298
- let i = m;
299
- l([
300
- f()
301
- ], i.prototype, "_currentPage", 2);
302
- l([
303
- n({ reflect: !0, type: Number })
304
- ], i.prototype, "totalResults", 2);
305
- l([
306
- n({ type: Number, reflect: !0 })
307
- ], i.prototype, "pageSize", 1);
308
- l([
309
- f()
310
- ], i.prototype, "_pageSize", 2);
311
- l([
312
- n({ reflect: !0, type: Number })
313
- ], i.prototype, "visiblePages", 2);
314
- l([
315
- n({ type: String, reflect: !0 })
316
- ], i.prototype, "display", 2);
317
- l([
318
- f()
319
- ], i.prototype, "windowWidth", 2);
320
- l([
321
- z("cre8-button")
322
- ], i.prototype, "buttons", 2);
323
- l([
324
- n({ type: Boolean, reflect: !0 })
325
- ], i.prototype, "hideLastAndFirstButtons", 2);
326
- l([
327
- n({ reflect: !0, type: Number })
328
- ], i.prototype, "currentPage", 1);
329
- customElements.get("cre8-pagination") === void 0 && customElements.define("cre8-pagination", i);
330
- export {
331
- i as Cre8Pagination
338
+ }
339
+ }
340
+ Cre8Pagination.styles = [styles];
341
+ Cre8Pagination.elementDefinitions = {
342
+ 'cre8-button': Cre8Button,
332
343
  };
344
+ __decorate([
345
+ state()
346
+ ], Cre8Pagination.prototype, "_currentPage", void 0);
347
+ __decorate([
348
+ property({ reflect: true, type: Number })
349
+ ], Cre8Pagination.prototype, "totalResults", void 0);
350
+ __decorate([
351
+ property({ type: Number, reflect: true })
352
+ ], Cre8Pagination.prototype, "pageSize", null);
353
+ __decorate([
354
+ state()
355
+ ], Cre8Pagination.prototype, "_pageSize", void 0);
356
+ __decorate([
357
+ property({ reflect: true, type: Number })
358
+ ], Cre8Pagination.prototype, "visiblePages", void 0);
359
+ __decorate([
360
+ property({ type: String, reflect: true })
361
+ ], Cre8Pagination.prototype, "display", void 0);
362
+ __decorate([
363
+ state()
364
+ ], Cre8Pagination.prototype, "windowWidth", void 0);
365
+ __decorate([
366
+ queryAll('cre8-button')
367
+ ], Cre8Pagination.prototype, "buttons", void 0);
368
+ __decorate([
369
+ property({ type: Boolean, reflect: true })
370
+ ], Cre8Pagination.prototype, "hideLastAndFirstButtons", void 0);
371
+ __decorate([
372
+ property({ reflect: true, type: Number })
373
+ ], Cre8Pagination.prototype, "currentPage", null);
374
+ if (customElements.get('cre8-pagination') === undefined) {
375
+ customElements.define('cre8-pagination', Cre8Pagination);
376
+ }
377
+ //# sourceMappingURL=pagination.js.map