@tartaguti/ui-components 0.0.0-stage → 0.1.0

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 (392) hide show
  1. package/CHANGELOG.md +7 -0
  2. package/LICENSE +21 -0
  3. package/README.md +192 -2
  4. package/THIRD-PARTY-NOTICES.md +29 -0
  5. package/custom-elements.json +16731 -0
  6. package/dist/accordion/tt-accordion-item.d.ts +32 -0
  7. package/dist/accordion/tt-accordion-item.d.ts.map +1 -0
  8. package/dist/accordion/tt-accordion-item.js +247 -0
  9. package/dist/accordion/tt-accordion-item.js.map +1 -0
  10. package/dist/accordion/tt-accordion.d.ts +28 -0
  11. package/dist/accordion/tt-accordion.d.ts.map +1 -0
  12. package/dist/accordion/tt-accordion.js +148 -0
  13. package/dist/accordion/tt-accordion.js.map +1 -0
  14. package/dist/bento/tt-bento-item.d.ts +35 -0
  15. package/dist/bento/tt-bento-item.d.ts.map +1 -0
  16. package/dist/bento/tt-bento-item.js +201 -0
  17. package/dist/bento/tt-bento-item.js.map +1 -0
  18. package/dist/bento/tt-bento.d.ts +25 -0
  19. package/dist/bento/tt-bento.d.ts.map +1 -0
  20. package/dist/bento/tt-bento.js +314 -0
  21. package/dist/bento/tt-bento.js.map +1 -0
  22. package/dist/floating.d.ts +61 -0
  23. package/dist/floating.d.ts.map +1 -0
  24. package/dist/floating.js +120 -0
  25. package/dist/floating.js.map +1 -0
  26. package/dist/index.d.ts +92 -0
  27. package/dist/index.d.ts.map +1 -0
  28. package/dist/index.js +96 -0
  29. package/dist/index.js.map +1 -0
  30. package/dist/interaction/tt-draggable.d.ts +29 -0
  31. package/dist/interaction/tt-draggable.d.ts.map +1 -0
  32. package/dist/interaction/tt-draggable.js +66 -0
  33. package/dist/interaction/tt-draggable.js.map +1 -0
  34. package/dist/interaction/tt-droppable.d.ts +37 -0
  35. package/dist/interaction/tt-droppable.d.ts.map +1 -0
  36. package/dist/interaction/tt-droppable.js +108 -0
  37. package/dist/interaction/tt-droppable.js.map +1 -0
  38. package/dist/interaction/tt-resizable.d.ts +45 -0
  39. package/dist/interaction/tt-resizable.d.ts.map +1 -0
  40. package/dist/interaction/tt-resizable.js +210 -0
  41. package/dist/interaction/tt-resizable.js.map +1 -0
  42. package/dist/interaction/tt-reveal.d.ts +54 -0
  43. package/dist/interaction/tt-reveal.d.ts.map +1 -0
  44. package/dist/interaction/tt-reveal.js +302 -0
  45. package/dist/interaction/tt-reveal.js.map +1 -0
  46. package/dist/motion.d.ts +8 -0
  47. package/dist/motion.d.ts.map +1 -0
  48. package/dist/motion.js +49 -0
  49. package/dist/motion.js.map +1 -0
  50. package/dist/overlay.d.ts +7 -0
  51. package/dist/overlay.d.ts.map +1 -0
  52. package/dist/overlay.js +121 -0
  53. package/dist/overlay.js.map +1 -0
  54. package/dist/safe-url.d.ts +14 -0
  55. package/dist/safe-url.d.ts.map +1 -0
  56. package/dist/safe-url.js +46 -0
  57. package/dist/safe-url.js.map +1 -0
  58. package/dist/scroll-lock.d.ts +22 -0
  59. package/dist/scroll-lock.d.ts.map +1 -0
  60. package/dist/scroll-lock.js +56 -0
  61. package/dist/scroll-lock.js.map +1 -0
  62. package/dist/sidebar/tt-menu-group.d.ts +69 -0
  63. package/dist/sidebar/tt-menu-group.d.ts.map +1 -0
  64. package/dist/sidebar/tt-menu-group.js +358 -0
  65. package/dist/sidebar/tt-menu-group.js.map +1 -0
  66. package/dist/sidebar/tt-menu-item.d.ts +70 -0
  67. package/dist/sidebar/tt-menu-item.d.ts.map +1 -0
  68. package/dist/sidebar/tt-menu-item.js +502 -0
  69. package/dist/sidebar/tt-menu-item.js.map +1 -0
  70. package/dist/sidebar/tt-sidebar-footer.d.ts +39 -0
  71. package/dist/sidebar/tt-sidebar-footer.d.ts.map +1 -0
  72. package/dist/sidebar/tt-sidebar-footer.js +205 -0
  73. package/dist/sidebar/tt-sidebar-footer.js.map +1 -0
  74. package/dist/sidebar/tt-sidebar-header.d.ts +31 -0
  75. package/dist/sidebar/tt-sidebar-header.d.ts.map +1 -0
  76. package/dist/sidebar/tt-sidebar-header.js +150 -0
  77. package/dist/sidebar/tt-sidebar-header.js.map +1 -0
  78. package/dist/sidebar/tt-sidebar.d.ts +72 -0
  79. package/dist/sidebar/tt-sidebar.d.ts.map +1 -0
  80. package/dist/sidebar/tt-sidebar.js +539 -0
  81. package/dist/sidebar/tt-sidebar.js.map +1 -0
  82. package/dist/sr-only.d.ts +15 -0
  83. package/dist/sr-only.d.ts.map +1 -0
  84. package/dist/sr-only.js +27 -0
  85. package/dist/sr-only.js.map +1 -0
  86. package/dist/tokens.css +1124 -0
  87. package/dist/tt-alert.d.ts +26 -0
  88. package/dist/tt-alert.d.ts.map +1 -0
  89. package/dist/tt-alert.js +165 -0
  90. package/dist/tt-alert.js.map +1 -0
  91. package/dist/tt-aspect-ratio.d.ts +40 -0
  92. package/dist/tt-aspect-ratio.d.ts.map +1 -0
  93. package/dist/tt-aspect-ratio.js +98 -0
  94. package/dist/tt-aspect-ratio.js.map +1 -0
  95. package/dist/tt-auth.d.ts +75 -0
  96. package/dist/tt-auth.d.ts.map +1 -0
  97. package/dist/tt-auth.js +520 -0
  98. package/dist/tt-auth.js.map +1 -0
  99. package/dist/tt-avatar.d.ts +26 -0
  100. package/dist/tt-avatar.d.ts.map +1 -0
  101. package/dist/tt-avatar.js +169 -0
  102. package/dist/tt-avatar.js.map +1 -0
  103. package/dist/tt-badge.d.ts +36 -0
  104. package/dist/tt-badge.d.ts.map +1 -0
  105. package/dist/tt-badge.js +135 -0
  106. package/dist/tt-badge.js.map +1 -0
  107. package/dist/tt-breadcrumbs.d.ts +22 -0
  108. package/dist/tt-breadcrumbs.d.ts.map +1 -0
  109. package/dist/tt-breadcrumbs.js +144 -0
  110. package/dist/tt-breadcrumbs.js.map +1 -0
  111. package/dist/tt-button-group.d.ts +32 -0
  112. package/dist/tt-button-group.d.ts.map +1 -0
  113. package/dist/tt-button-group.js +132 -0
  114. package/dist/tt-button-group.js.map +1 -0
  115. package/dist/tt-button.d.ts +31 -0
  116. package/dist/tt-button.d.ts.map +1 -0
  117. package/dist/tt-button.js +483 -0
  118. package/dist/tt-button.js.map +1 -0
  119. package/dist/tt-card.d.ts +26 -0
  120. package/dist/tt-card.d.ts.map +1 -0
  121. package/dist/tt-card.js +429 -0
  122. package/dist/tt-card.js.map +1 -0
  123. package/dist/tt-chart.d.ts +36 -0
  124. package/dist/tt-chart.d.ts.map +1 -0
  125. package/dist/tt-chart.js +332 -0
  126. package/dist/tt-chart.js.map +1 -0
  127. package/dist/tt-checkbox-group.d.ts +38 -0
  128. package/dist/tt-checkbox-group.d.ts.map +1 -0
  129. package/dist/tt-checkbox-group.js +243 -0
  130. package/dist/tt-checkbox-group.js.map +1 -0
  131. package/dist/tt-checkbox.d.ts +35 -0
  132. package/dist/tt-checkbox.d.ts.map +1 -0
  133. package/dist/tt-checkbox.js +354 -0
  134. package/dist/tt-checkbox.js.map +1 -0
  135. package/dist/tt-code-block.d.ts +37 -0
  136. package/dist/tt-code-block.d.ts.map +1 -0
  137. package/dist/tt-code-block.js +409 -0
  138. package/dist/tt-code-block.js.map +1 -0
  139. package/dist/tt-collapsible.d.ts +71 -0
  140. package/dist/tt-collapsible.d.ts.map +1 -0
  141. package/dist/tt-collapsible.js +206 -0
  142. package/dist/tt-collapsible.js.map +1 -0
  143. package/dist/tt-combobox.d.ts +107 -0
  144. package/dist/tt-combobox.d.ts.map +1 -0
  145. package/dist/tt-combobox.js +816 -0
  146. package/dist/tt-combobox.js.map +1 -0
  147. package/dist/tt-company-card.d.ts +30 -0
  148. package/dist/tt-company-card.d.ts.map +1 -0
  149. package/dist/tt-company-card.js +382 -0
  150. package/dist/tt-company-card.js.map +1 -0
  151. package/dist/tt-comparison-table.d.ts +59 -0
  152. package/dist/tt-comparison-table.d.ts.map +1 -0
  153. package/dist/tt-comparison-table.js +441 -0
  154. package/dist/tt-comparison-table.js.map +1 -0
  155. package/dist/tt-component-doc.d.ts +63 -0
  156. package/dist/tt-component-doc.d.ts.map +1 -0
  157. package/dist/tt-component-doc.js +585 -0
  158. package/dist/tt-component-doc.js.map +1 -0
  159. package/dist/tt-confirm.d.ts +45 -0
  160. package/dist/tt-confirm.d.ts.map +1 -0
  161. package/dist/tt-confirm.js +151 -0
  162. package/dist/tt-confirm.js.map +1 -0
  163. package/dist/tt-contact-list.d.ts +18 -0
  164. package/dist/tt-contact-list.d.ts.map +1 -0
  165. package/dist/tt-contact-list.js +101 -0
  166. package/dist/tt-contact-list.js.map +1 -0
  167. package/dist/tt-copy-button.d.ts +25 -0
  168. package/dist/tt-copy-button.d.ts.map +1 -0
  169. package/dist/tt-copy-button.js +194 -0
  170. package/dist/tt-copy-button.js.map +1 -0
  171. package/dist/tt-data-table.d.ts +69 -0
  172. package/dist/tt-data-table.d.ts.map +1 -0
  173. package/dist/tt-data-table.js +542 -0
  174. package/dist/tt-data-table.js.map +1 -0
  175. package/dist/tt-divider.d.ts +19 -0
  176. package/dist/tt-divider.d.ts.map +1 -0
  177. package/dist/tt-divider.js +104 -0
  178. package/dist/tt-divider.js.map +1 -0
  179. package/dist/tt-drawer.d.ts +38 -0
  180. package/dist/tt-drawer.d.ts.map +1 -0
  181. package/dist/tt-drawer.js +433 -0
  182. package/dist/tt-drawer.js.map +1 -0
  183. package/dist/tt-dropdown-menu.d.ts +57 -0
  184. package/dist/tt-dropdown-menu.d.ts.map +1 -0
  185. package/dist/tt-dropdown-menu.js +631 -0
  186. package/dist/tt-dropdown-menu.js.map +1 -0
  187. package/dist/tt-empty-state.d.ts +13 -0
  188. package/dist/tt-empty-state.d.ts.map +1 -0
  189. package/dist/tt-empty-state.js +94 -0
  190. package/dist/tt-empty-state.js.map +1 -0
  191. package/dist/tt-example.d.ts +33 -0
  192. package/dist/tt-example.d.ts.map +1 -0
  193. package/dist/tt-example.js +250 -0
  194. package/dist/tt-example.js.map +1 -0
  195. package/dist/tt-file-upload.d.ts +85 -0
  196. package/dist/tt-file-upload.d.ts.map +1 -0
  197. package/dist/tt-file-upload.js +662 -0
  198. package/dist/tt-file-upload.js.map +1 -0
  199. package/dist/tt-filter.d.ts +62 -0
  200. package/dist/tt-filter.d.ts.map +1 -0
  201. package/dist/tt-filter.js +393 -0
  202. package/dist/tt-filter.js.map +1 -0
  203. package/dist/tt-form.d.ts +33 -0
  204. package/dist/tt-form.d.ts.map +1 -0
  205. package/dist/tt-form.js +202 -0
  206. package/dist/tt-form.js.map +1 -0
  207. package/dist/tt-grid.d.ts +22 -0
  208. package/dist/tt-grid.d.ts.map +1 -0
  209. package/dist/tt-grid.js +106 -0
  210. package/dist/tt-grid.js.map +1 -0
  211. package/dist/tt-icon.d.ts +20 -0
  212. package/dist/tt-icon.d.ts.map +1 -0
  213. package/dist/tt-icon.js +510 -0
  214. package/dist/tt-icon.js.map +1 -0
  215. package/dist/tt-image.d.ts +59 -0
  216. package/dist/tt-image.d.ts.map +1 -0
  217. package/dist/tt-image.js +314 -0
  218. package/dist/tt-image.js.map +1 -0
  219. package/dist/tt-inbox.d.ts +45 -0
  220. package/dist/tt-inbox.d.ts.map +1 -0
  221. package/dist/tt-inbox.js +275 -0
  222. package/dist/tt-inbox.js.map +1 -0
  223. package/dist/tt-input.d.ts +43 -0
  224. package/dist/tt-input.d.ts.map +1 -0
  225. package/dist/tt-input.js +476 -0
  226. package/dist/tt-input.js.map +1 -0
  227. package/dist/tt-kbd.d.ts +39 -0
  228. package/dist/tt-kbd.d.ts.map +1 -0
  229. package/dist/tt-kbd.js +145 -0
  230. package/dist/tt-kbd.js.map +1 -0
  231. package/dist/tt-key-values.d.ts +17 -0
  232. package/dist/tt-key-values.d.ts.map +1 -0
  233. package/dist/tt-key-values.js +126 -0
  234. package/dist/tt-key-values.js.map +1 -0
  235. package/dist/tt-knowledge-doc.d.ts +24 -0
  236. package/dist/tt-knowledge-doc.d.ts.map +1 -0
  237. package/dist/tt-knowledge-doc.js +120 -0
  238. package/dist/tt-knowledge-doc.js.map +1 -0
  239. package/dist/tt-layout.d.ts +36 -0
  240. package/dist/tt-layout.d.ts.map +1 -0
  241. package/dist/tt-layout.js +318 -0
  242. package/dist/tt-layout.js.map +1 -0
  243. package/dist/tt-modal.d.ts +32 -0
  244. package/dist/tt-modal.d.ts.map +1 -0
  245. package/dist/tt-modal.js +553 -0
  246. package/dist/tt-modal.js.map +1 -0
  247. package/dist/tt-navbar.d.ts +33 -0
  248. package/dist/tt-navbar.d.ts.map +1 -0
  249. package/dist/tt-navbar.js +390 -0
  250. package/dist/tt-navbar.js.map +1 -0
  251. package/dist/tt-page-header.d.ts +28 -0
  252. package/dist/tt-page-header.d.ts.map +1 -0
  253. package/dist/tt-page-header.js +166 -0
  254. package/dist/tt-page-header.js.map +1 -0
  255. package/dist/tt-page.d.ts +14 -0
  256. package/dist/tt-page.d.ts.map +1 -0
  257. package/dist/tt-page.js +163 -0
  258. package/dist/tt-page.js.map +1 -0
  259. package/dist/tt-pagination.d.ts +27 -0
  260. package/dist/tt-pagination.d.ts.map +1 -0
  261. package/dist/tt-pagination.js +194 -0
  262. package/dist/tt-pagination.js.map +1 -0
  263. package/dist/tt-preview.d.ts +11 -0
  264. package/dist/tt-preview.d.ts.map +1 -0
  265. package/dist/tt-preview.js +68 -0
  266. package/dist/tt-preview.js.map +1 -0
  267. package/dist/tt-product.d.ts +40 -0
  268. package/dist/tt-product.d.ts.map +1 -0
  269. package/dist/tt-product.js +590 -0
  270. package/dist/tt-product.js.map +1 -0
  271. package/dist/tt-profile-card.d.ts +23 -0
  272. package/dist/tt-profile-card.d.ts.map +1 -0
  273. package/dist/tt-profile-card.js +199 -0
  274. package/dist/tt-profile-card.js.map +1 -0
  275. package/dist/tt-progress.d.ts +26 -0
  276. package/dist/tt-progress.d.ts.map +1 -0
  277. package/dist/tt-progress.js +156 -0
  278. package/dist/tt-progress.js.map +1 -0
  279. package/dist/tt-quantity.d.ts +36 -0
  280. package/dist/tt-quantity.d.ts.map +1 -0
  281. package/dist/tt-quantity.js +396 -0
  282. package/dist/tt-quantity.js.map +1 -0
  283. package/dist/tt-radio-group.d.ts +50 -0
  284. package/dist/tt-radio-group.d.ts.map +1 -0
  285. package/dist/tt-radio-group.js +372 -0
  286. package/dist/tt-radio-group.js.map +1 -0
  287. package/dist/tt-rating.d.ts +54 -0
  288. package/dist/tt-rating.d.ts.map +1 -0
  289. package/dist/tt-rating.js +312 -0
  290. package/dist/tt-rating.js.map +1 -0
  291. package/dist/tt-search.d.ts +47 -0
  292. package/dist/tt-search.d.ts.map +1 -0
  293. package/dist/tt-search.js +360 -0
  294. package/dist/tt-search.js.map +1 -0
  295. package/dist/tt-section.d.ts +13 -0
  296. package/dist/tt-section.d.ts.map +1 -0
  297. package/dist/tt-section.js +98 -0
  298. package/dist/tt-section.js.map +1 -0
  299. package/dist/tt-select.d.ts +62 -0
  300. package/dist/tt-select.d.ts.map +1 -0
  301. package/dist/tt-select.js +662 -0
  302. package/dist/tt-select.js.map +1 -0
  303. package/dist/tt-skeleton.d.ts +20 -0
  304. package/dist/tt-skeleton.d.ts.map +1 -0
  305. package/dist/tt-skeleton.js +143 -0
  306. package/dist/tt-skeleton.js.map +1 -0
  307. package/dist/tt-slider.d.ts +74 -0
  308. package/dist/tt-slider.d.ts.map +1 -0
  309. package/dist/tt-slider.js +426 -0
  310. package/dist/tt-slider.js.map +1 -0
  311. package/dist/tt-social-links.d.ts +34 -0
  312. package/dist/tt-social-links.d.ts.map +1 -0
  313. package/dist/tt-social-links.js +242 -0
  314. package/dist/tt-social-links.js.map +1 -0
  315. package/dist/tt-sparkline.d.ts +19 -0
  316. package/dist/tt-sparkline.d.ts.map +1 -0
  317. package/dist/tt-sparkline.js +191 -0
  318. package/dist/tt-sparkline.js.map +1 -0
  319. package/dist/tt-spinner.d.ts +19 -0
  320. package/dist/tt-spinner.d.ts.map +1 -0
  321. package/dist/tt-spinner.js +93 -0
  322. package/dist/tt-spinner.js.map +1 -0
  323. package/dist/tt-stack.d.ts +42 -0
  324. package/dist/tt-stack.d.ts.map +1 -0
  325. package/dist/tt-stack.js +158 -0
  326. package/dist/tt-stack.js.map +1 -0
  327. package/dist/tt-stat.d.ts +17 -0
  328. package/dist/tt-stat.d.ts.map +1 -0
  329. package/dist/tt-stat.js +134 -0
  330. package/dist/tt-stat.js.map +1 -0
  331. package/dist/tt-switch.d.ts +39 -0
  332. package/dist/tt-switch.d.ts.map +1 -0
  333. package/dist/tt-switch.js +254 -0
  334. package/dist/tt-switch.js.map +1 -0
  335. package/dist/tt-switcher.d.ts +23 -0
  336. package/dist/tt-switcher.d.ts.map +1 -0
  337. package/dist/tt-switcher.js +203 -0
  338. package/dist/tt-switcher.js.map +1 -0
  339. package/dist/tt-table-cell.d.ts +26 -0
  340. package/dist/tt-table-cell.d.ts.map +1 -0
  341. package/dist/tt-table-cell.js +121 -0
  342. package/dist/tt-table-cell.js.map +1 -0
  343. package/dist/tt-table-row.d.ts +31 -0
  344. package/dist/tt-table-row.d.ts.map +1 -0
  345. package/dist/tt-table-row.js +72 -0
  346. package/dist/tt-table-row.js.map +1 -0
  347. package/dist/tt-table.d.ts +44 -0
  348. package/dist/tt-table.d.ts.map +1 -0
  349. package/dist/tt-table.js +270 -0
  350. package/dist/tt-table.js.map +1 -0
  351. package/dist/tt-tabs.d.ts +31 -0
  352. package/dist/tt-tabs.d.ts.map +1 -0
  353. package/dist/tt-tabs.js +223 -0
  354. package/dist/tt-tabs.js.map +1 -0
  355. package/dist/tt-tag-list.d.ts +19 -0
  356. package/dist/tt-tag-list.d.ts.map +1 -0
  357. package/dist/tt-tag-list.js +136 -0
  358. package/dist/tt-tag-list.js.map +1 -0
  359. package/dist/tt-text.d.ts +52 -0
  360. package/dist/tt-text.d.ts.map +1 -0
  361. package/dist/tt-text.js +337 -0
  362. package/dist/tt-text.js.map +1 -0
  363. package/dist/tt-textarea.d.ts +43 -0
  364. package/dist/tt-textarea.d.ts.map +1 -0
  365. package/dist/tt-textarea.js +356 -0
  366. package/dist/tt-textarea.js.map +1 -0
  367. package/dist/tt-thread.d.ts +62 -0
  368. package/dist/tt-thread.d.ts.map +1 -0
  369. package/dist/tt-thread.js +374 -0
  370. package/dist/tt-thread.js.map +1 -0
  371. package/dist/tt-toast.d.ts +49 -0
  372. package/dist/tt-toast.d.ts.map +1 -0
  373. package/dist/tt-toast.js +440 -0
  374. package/dist/tt-toast.js.map +1 -0
  375. package/dist/tt-toggle-group.d.ts +73 -0
  376. package/dist/tt-toggle-group.d.ts.map +1 -0
  377. package/dist/tt-toggle-group.js +273 -0
  378. package/dist/tt-toggle-group.js.map +1 -0
  379. package/dist/tt-toggle.d.ts +54 -0
  380. package/dist/tt-toggle.d.ts.map +1 -0
  381. package/dist/tt-toggle.js +232 -0
  382. package/dist/tt-toggle.js.map +1 -0
  383. package/dist/tt-toolbar.d.ts +26 -0
  384. package/dist/tt-toolbar.d.ts.map +1 -0
  385. package/dist/tt-toolbar.js +164 -0
  386. package/dist/tt-toolbar.js.map +1 -0
  387. package/dist/tt-tooltip.d.ts +42 -0
  388. package/dist/tt-tooltip.d.ts.map +1 -0
  389. package/dist/tt-tooltip.js +299 -0
  390. package/dist/tt-tooltip.js.map +1 -0
  391. package/package.json +84 -4
  392. package/vscode.html-custom-data.json +2907 -0
@@ -0,0 +1,631 @@
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;
6
+ };
7
+ import { LitElement, html, css } from "lit";
8
+ import { customElement, property, state, query } from "lit/decorators.js";
9
+ import { trackAnchor, placeBelow } from "./floating.js";
10
+ import { ifDefined } from "lit/directives/if-defined.js";
11
+ import "./tt-icon.js";
12
+ let uid = 0;
13
+ /**
14
+ * Actions attached to a thing: the row menu behind a table's dots button,
15
+ * or a settings menu in a header.
16
+ *
17
+ * Distinct from tt-select. A select edits a value and shows what is
18
+ * currently chosen; a menu performs an action and remembers nothing.
19
+ */
20
+ let TTDropdownMenu = class TTDropdownMenu extends LitElement {
21
+ constructor() {
22
+ super(...arguments);
23
+ this.items = [];
24
+ this.label = "Actions";
25
+ // Which edge of the trigger the menu lines up with.
26
+ this.align = "end";
27
+ this.disabled = false;
28
+ /*
29
+ The trigger's height: the same three steps, from the same tokens, as
30
+ tt-button and every field, so a menu beside them in a row or a
31
+ tt-button-group is exactly as tall. The trigger used to be fixed at
32
+ the small height, 4px short of a medium button in a split button.
33
+
34
+ Defaults to small, not medium like the rest, because the usual home
35
+ of the default kebab trigger is a table row or a card corner, where
36
+ the smaller target keeps the row from growing. Reflected: the sizes
37
+ are :host rules.
38
+ */
39
+ this.size = "small";
40
+ this.open = false;
41
+ this.activeIndex = -1;
42
+ // The default trigger is a square icon button. Slotted content is
43
+ // usually a word, which needs horizontal padding and no fixed width.
44
+ // There is no CSS selector for "this slot has assigned nodes", so the
45
+ // slotchange event has to set a flag the styles can key off.
46
+ this.customTrigger = false;
47
+ /*
48
+ Whether the slotted trigger has text of its own. Text names the button
49
+ by itself, and an aria-label on top would replace the words people
50
+ can see. An icon has no text, so without label the trigger was
51
+ announced as just "button".
52
+ */
53
+ this.triggerHasText = false;
54
+ // The trigger width the menu is currently sized to, so a scroll does
55
+ // not redo the measurement on every frame.
56
+ this.appliedTriggerWidth = -1;
57
+ this.menuId = `tt-menu-${++uid}`;
58
+ // composedPath sees through shadow boundaries. event.target alone is
59
+ // retargeted to the host, so our own clicks would look like outside ones.
60
+ this.handleDocumentClick = (event) => {
61
+ if (!event.composedPath().includes(this))
62
+ this.closeMenu(false);
63
+ };
64
+ this.reposition = () => {
65
+ if (this.open)
66
+ this.position();
67
+ };
68
+ }
69
+ disconnectedCallback() {
70
+ this.removeGlobalListeners();
71
+ super.disconnectedCallback();
72
+ }
73
+ openMenu() {
74
+ if (this.disabled || this.open)
75
+ return;
76
+ this.open = true;
77
+ this.activeIndex = -1;
78
+ document.addEventListener("click", this.handleDocumentClick);
79
+ // Not a window scroll listener: scroll events are not composed, so a
80
+ // window listener never sees the page scrolling inside tt-layout's
81
+ // shadow root. trackAnchor listens on the real scroll ancestors.
82
+ this.untrack = trackAnchor(this, this.reposition);
83
+ }
84
+ closeMenu(refocus = true) {
85
+ if (!this.open)
86
+ return;
87
+ this.open = false;
88
+ this.activeIndex = -1;
89
+ this.removeGlobalListeners();
90
+ if (refocus)
91
+ this.trigger?.focus();
92
+ }
93
+ removeGlobalListeners() {
94
+ document.removeEventListener("click", this.handleDocumentClick);
95
+ this.untrack?.();
96
+ this.untrack = undefined;
97
+ }
98
+ handleTriggerClick() {
99
+ if (this.open) {
100
+ this.closeMenu();
101
+ return;
102
+ }
103
+ this.openMenu();
104
+ // Onto the first item, as a menu button does, so the next arrow key
105
+ // or a screen reader starts from inside the menu.
106
+ this.move(1);
107
+ }
108
+ choose(item) {
109
+ if (item.disabled)
110
+ return;
111
+ this.closeMenu();
112
+ this.dispatchEvent(new CustomEvent("tt-menu-select", {
113
+ detail: { value: item.value },
114
+ bubbles: true,
115
+ composed: true,
116
+ }));
117
+ }
118
+ move(delta) {
119
+ const count = this.items.length;
120
+ if (count === 0)
121
+ return;
122
+ let next = this.activeIndex;
123
+ for (let i = 0; i < count; i++) {
124
+ next = (next + delta + count) % count;
125
+ if (!this.items[next].disabled)
126
+ break;
127
+ }
128
+ this.activeIndex = next;
129
+ }
130
+ handleKeydown(event) {
131
+ if (this.disabled)
132
+ return;
133
+ switch (event.key) {
134
+ /*
135
+ Opening with an arrow key also moves the cursor, matching
136
+ tt-select. Opening onto nothing means the next press is spent
137
+ just getting to the first item, and the keyboard user pays for
138
+ every menu twice.
139
+ */
140
+ case "ArrowDown":
141
+ event.preventDefault();
142
+ if (!this.open)
143
+ this.openMenu();
144
+ this.move(1);
145
+ break;
146
+ case "ArrowUp":
147
+ event.preventDefault();
148
+ if (!this.open) {
149
+ this.openMenu();
150
+ // One past the end, so the step below lands on the last item.
151
+ this.activeIndex = this.items.length;
152
+ }
153
+ this.move(-1);
154
+ break;
155
+ case "Enter":
156
+ case " ":
157
+ event.preventDefault();
158
+ if (this.open && this.activeIndex >= 0) {
159
+ this.choose(this.items[this.activeIndex]);
160
+ }
161
+ else {
162
+ this.openMenu();
163
+ this.move(1);
164
+ }
165
+ break;
166
+ case "Escape":
167
+ if (this.open) {
168
+ event.preventDefault();
169
+ this.closeMenu();
170
+ }
171
+ break;
172
+ case "Tab":
173
+ this.closeMenu(false);
174
+ break;
175
+ }
176
+ }
177
+ /*
178
+ Keys pressed while focus is on an item. Only movement and leaving:
179
+ Enter and Space are left to the item's own <button>, whose click
180
+ already chooses it. Handling them here as well would choose twice.
181
+ */
182
+ handleMenuKeydown(event) {
183
+ switch (event.key) {
184
+ case "ArrowDown":
185
+ event.preventDefault();
186
+ this.move(1);
187
+ break;
188
+ case "ArrowUp":
189
+ event.preventDefault();
190
+ this.move(-1);
191
+ break;
192
+ case "Home":
193
+ event.preventDefault();
194
+ this.activeIndex = -1;
195
+ this.move(1);
196
+ break;
197
+ case "End":
198
+ event.preventDefault();
199
+ this.activeIndex = this.items.length;
200
+ this.move(-1);
201
+ break;
202
+ case "Escape":
203
+ event.preventDefault();
204
+ this.closeMenu();
205
+ break;
206
+ case "Tab":
207
+ // Back on the trigger BEFORE the browser moves focus, so Tab
208
+ // carries on from the trigger instead of from an item that is
209
+ // about to disappear.
210
+ this.closeMenu();
211
+ break;
212
+ }
213
+ }
214
+ updated(changed) {
215
+ if (changed.has("open"))
216
+ this.syncPopover();
217
+ /*
218
+ FOCUS FOLLOWS THE CURSOR. The highlighted item used to be a CSS
219
+ class and nothing else: focus stayed on the trigger, so a screen
220
+ reader said nothing at all while the user arrowed through the menu.
221
+ Moving real focus onto the item is the standard menu-button pattern
222
+ and makes every item announce itself, with no ARIA to keep in sync.
223
+ */
224
+ if (this.open &&
225
+ this.activeIndex >= 0 &&
226
+ (changed.has("activeIndex") || changed.has("open"))) {
227
+ const items = this.renderRoot.querySelectorAll(".item");
228
+ items[this.activeIndex]?.focus();
229
+ }
230
+ }
231
+ syncPopover() {
232
+ const menu = this.menu;
233
+ if (!menu)
234
+ return;
235
+ if (this.open) {
236
+ /*
237
+ Show BEFORE positioning. A closed popover is display:none, and a
238
+ display:none element measures 0x0, so positioning first meant
239
+ position() worked with a width of zero: the align="end" offset
240
+ collapsed to the trigger's right edge and the viewport clamp had
241
+ nothing to clamp, so a menu near the right edge ran off screen.
242
+ */
243
+ if (!menu.matches(":popover-open"))
244
+ menu.showPopover();
245
+ this.position();
246
+ }
247
+ else if (menu.matches(":popover-open")) {
248
+ menu.hidePopover();
249
+ }
250
+ }
251
+ /*
252
+ Rendered in the top layer via popover, so a table's overflow cannot
253
+ clip it. The top layer is outside normal flow, so the position has to
254
+ be set from script. The maths lives in floating.ts because tt-filter
255
+ needs exactly the same thing.
256
+ */
257
+ position() {
258
+ if (!this.trigger || !this.menu)
259
+ return;
260
+ // Before placeBelow, not after: the align="end" offset and the
261
+ // viewport clamp are both computed from the menu's width, so it has
262
+ // to be final before the maths runs.
263
+ this.matchTriggerWidth();
264
+ placeBelow(this.trigger, this.menu, { align: this.align });
265
+ }
266
+ /*
267
+ A menu narrower than the control that opened it looks like a mistake,
268
+ and one wider than it looks like a different control. So the menu is
269
+ never narrower than its own min-width, and never a different width
270
+ from the trigger once the trigger is the bigger of the two.
271
+
272
+ An icon button keeps the default: a 36px trigger should not open a
273
+ 36px menu. Above the floor the trigger wins outright, which is what
274
+ makes a full-width control open a full-width menu.
275
+ */
276
+ matchTriggerWidth() {
277
+ const menu = this.menu;
278
+ const trigger = this.trigger.getBoundingClientRect().width;
279
+ /*
280
+ position() runs again on every scroll and resize while the menu is
281
+ open, and the work below writes a style and then reads a computed
282
+ one, which forces a synchronous layout. The trigger almost never
283
+ changes width mid-scroll, so do it only when it actually has.
284
+ */
285
+ if (trigger === this.appliedTriggerWidth)
286
+ return;
287
+ this.appliedTriggerWidth = trigger;
288
+ // Cleared first, or the floor below is measured against a width this
289
+ // method set on a previous open.
290
+ menu.style.width = "";
291
+ // Read from the stylesheet rather than repeating the number here, so
292
+ // the CSS above stays the only place the floor is written down.
293
+ const floor = parseFloat(getComputedStyle(menu).minWidth) || 0;
294
+ if (trigger > floor)
295
+ menu.style.width = `${trigger}px`;
296
+ }
297
+ static { this.styles = css `
298
+ /* The browser's own [hidden] rule loses to any :host display, so a
299
+ hidden element would still show. Important, so it always wins. */
300
+ :host([hidden]) {
301
+ display: none !important;
302
+ }
303
+
304
+ :host {
305
+ display: inline-flex;
306
+ font-family: var(--tt-font-sans);
307
+
308
+ --_h: var(--tt-control-sm);
309
+ }
310
+
311
+ :host([size="medium"]) {
312
+ --_h: var(--tt-control-md);
313
+ }
314
+
315
+ :host([size="large"]) {
316
+ --_h: var(--tt-control-lg);
317
+ }
318
+
319
+ :host([disabled]) {
320
+ opacity: var(--tt-opacity-disabled);
321
+ }
322
+
323
+ .trigger {
324
+ display: inline-flex;
325
+ align-items: center;
326
+ justify-content: center;
327
+ gap: var(--tt-space-2);
328
+
329
+ /* border-box, so the 1px border sits inside the height, as on
330
+ tt-button, instead of being added around it. */
331
+ box-sizing: border-box;
332
+ width: var(--_h);
333
+ height: var(--_h);
334
+ padding: 0;
335
+
336
+ border: 1px solid transparent;
337
+ /* tt-button-group flattens this per position, so controls that
338
+ sit together share one edge instead of stacking two. */
339
+ border-radius: var(--tt-group-radius, var(--tt-radius));
340
+
341
+ background: transparent;
342
+ color: var(--tt-muted-foreground);
343
+
344
+ font: inherit;
345
+ font-size: var(--tt-text-sm);
346
+ cursor: pointer;
347
+
348
+ transition:
349
+ background var(--tt-duration-normal) var(--tt-ease),
350
+ color var(--tt-duration-normal) var(--tt-ease);
351
+ /* Long-press should activate the control, not start selecting
352
+ its label. The other half of the mobile blue flash: the tap
353
+ highlight is the flash, this is the drag-select. */
354
+ -webkit-user-select: none;
355
+ user-select: none;
356
+ }
357
+
358
+ /* A slotted label needs room to breathe; the icon-only default does
359
+ not, and would look lopsided with padding. */
360
+ .trigger.custom {
361
+ width: auto;
362
+ padding: 0 var(--tt-space-3);
363
+
364
+ /* A wrapped label would overflow the fixed height. */
365
+ white-space: nowrap;
366
+
367
+ border-color: var(--tt-input);
368
+ background: var(--tt-field);
369
+ color: var(--tt-foreground);
370
+ font-weight: var(--tt-weight-medium);
371
+ }
372
+
373
+ .trigger:hover:not(:disabled) {
374
+ background: var(--tt-accent);
375
+ color: var(--tt-foreground);
376
+ }
377
+
378
+ .trigger:focus-visible {
379
+ outline: var(--tt-ring-width) solid var(--tt-ring);
380
+ outline-offset: var(--tt-ring-offset);
381
+ }
382
+
383
+ .trigger:disabled {
384
+ cursor: not-allowed;
385
+ }
386
+
387
+ .menu {
388
+ position: fixed;
389
+ margin: 0;
390
+ padding: var(--tt-space-1);
391
+
392
+ /*
393
+ So a width means the width you see. Without it the 4px padding and
394
+ 1px border on each side were added on top of every measurement,
395
+ which is why a 180px min-width drew a 190px menu. It also has to be
396
+ true before position() can pin the menu to the trigger, or matching
397
+ a 240px trigger would draw a 250px menu.
398
+
399
+ The app's global reset does not reach in here: shadow DOM does not
400
+ inherit a * selector, so every component sets this for itself.
401
+ */
402
+ box-sizing: border-box;
403
+
404
+ /*
405
+ The floor, and the whole size for a small trigger. 190 rather than
406
+ 180 only because border-box now counts the border and padding that
407
+ used to be added afterwards: the menu on screen is the same width
408
+ it has always been.
409
+
410
+ position() widens it to match anything wider than this.
411
+ */
412
+ min-width: 190px;
413
+
414
+ /* A backstop for the script clamp: an unusually long label can
415
+ still never make the menu wider than the viewport. */
416
+ max-width: calc(100vw - 16px);
417
+
418
+ max-height: 60vh;
419
+ overflow-y: auto;
420
+
421
+ list-style: none;
422
+
423
+ background: var(--tt-popover);
424
+ color: var(--tt-popover-foreground);
425
+
426
+ border: 1px solid var(--tt-border);
427
+ border-radius: var(--tt-radius);
428
+ box-shadow: var(--tt-elevation-2);
429
+ }
430
+
431
+ /*
432
+ In and out of the top layer. display and overlay are discrete, and
433
+ allow-discrete holds them for the whole exit, so the list stays
434
+ painted and in the top layer until its fade has finished. Quicker
435
+ out than in. translate only, never scale: placeBelow measures this
436
+ element while it is still at its starting style, and a scale would
437
+ shrink the width it measures. Reduced motion is the 1ms durations in
438
+ tokens.css.
439
+ */
440
+ .menu {
441
+ transition:
442
+ opacity var(--tt-duration-fast) var(--tt-ease-in),
443
+ translate var(--tt-duration-fast) var(--tt-ease-in),
444
+ overlay var(--tt-duration-fast) allow-discrete,
445
+ display var(--tt-duration-fast) allow-discrete;
446
+ }
447
+
448
+ .menu:popover-open {
449
+ transition-duration: var(--tt-duration-slow);
450
+ transition-timing-function: var(--tt-ease-out);
451
+ }
452
+
453
+ @starting-style {
454
+ .menu:popover-open {
455
+ opacity: 0;
456
+ translate: 0 -4px;
457
+ }
458
+ }
459
+
460
+ /* Closed, and closing: clicks during the fade reach the page. */
461
+ .menu:not(:popover-open) {
462
+ display: none;
463
+ opacity: 0;
464
+ translate: 0 -4px;
465
+ pointer-events: none;
466
+ }
467
+
468
+ li {
469
+ list-style: none;
470
+ }
471
+
472
+ .item {
473
+ display: flex;
474
+ align-items: center;
475
+ gap: var(--tt-space-2);
476
+
477
+ width: 100%;
478
+ box-sizing: border-box;
479
+
480
+ padding: var(--tt-space-2) var(--tt-space-3);
481
+
482
+ border: none;
483
+ border-radius: var(--tt-radius-sm);
484
+ background: transparent;
485
+ color: inherit;
486
+
487
+ font: inherit;
488
+ font-size: var(--tt-text-sm);
489
+ text-align: left;
490
+ white-space: nowrap;
491
+
492
+ cursor: pointer;
493
+ /* Long-press should activate the control, not start selecting
494
+ its label. The other half of the mobile blue flash: the tap
495
+ highlight is the flash, this is the drag-select. */
496
+ -webkit-user-select: none;
497
+ user-select: none;
498
+ }
499
+
500
+ .item:hover:not(:disabled),
501
+ .item.active:not(:disabled) {
502
+ background: var(--tt-accent);
503
+ color: var(--tt-accent-foreground);
504
+ }
505
+
506
+ .item.danger {
507
+ color: var(--tt-destructive);
508
+ }
509
+
510
+ .item.danger:hover:not(:disabled),
511
+ .item.danger.active:not(:disabled) {
512
+ background: color-mix(in srgb, var(--tt-destructive) 12%, transparent);
513
+ color: var(--tt-destructive);
514
+ }
515
+
516
+ .item:disabled {
517
+ opacity: var(--tt-opacity-disabled);
518
+ cursor: not-allowed;
519
+ }
520
+
521
+ .separated {
522
+ margin-top: var(--tt-space-1);
523
+ padding-top: var(--tt-space-1);
524
+ border-top: 1px solid var(--tt-border);
525
+ }
526
+
527
+ `; }
528
+ // Focus has to be forwarded: focusing the host focuses nothing, since the
529
+ // control lives in the shadow root. Same as tt-slider and tt-input.
530
+ focus(options) {
531
+ this.renderRoot?.querySelector(".trigger")?.focus(options);
532
+ }
533
+ render() {
534
+ return html `
535
+ <button
536
+ class="trigger ${this.customTrigger ? "custom" : ""}"
537
+ part="trigger"
538
+ type="button"
539
+ aria-haspopup="menu"
540
+ aria-expanded=${this.open ? "true" : "false"}
541
+ aria-controls=${this.menuId}
542
+ aria-label=${ifDefined(this.triggerHasText ? undefined : this.label)}
543
+ ?disabled=${this.disabled}
544
+ @click=${this.handleTriggerClick}
545
+ @keydown=${this.handleKeydown}
546
+ >
547
+ <slot
548
+ name="trigger"
549
+ @slotchange=${(e) => {
550
+ const slot = e.target;
551
+ const nodes = slot.assignedNodes();
552
+ this.customTrigger = nodes.length > 0;
553
+ this.triggerHasText = nodes.some((node) => node.textContent?.trim());
554
+ }}
555
+ >
556
+ <tt-icon name="more-vertical" size="16px"></tt-icon>
557
+ </slot>
558
+ </button>
559
+
560
+ <ul
561
+ class="menu"
562
+ part="menu"
563
+ id=${this.menuId}
564
+ popover="manual"
565
+ role="menu"
566
+ aria-label=${this.label}
567
+ @keydown=${this.handleMenuKeydown}
568
+ >
569
+ ${this.items.map((item, index) => html `
570
+ <!-- role="none": a menu's children must be menu items, and a
571
+ bare <li> would sit between the two as a "listitem". -->
572
+ <li class=${item.separated ? "separated" : ""} role="none">
573
+ <button
574
+ class="item ${item.danger ? "danger" : ""} ${index ===
575
+ this.activeIndex
576
+ ? "active"
577
+ : ""}"
578
+ part="item"
579
+ type="button"
580
+ role="menuitem"
581
+ tabindex="-1"
582
+ ?disabled=${item.disabled}
583
+ @click=${() => this.choose(item)}
584
+ @mousemove=${() => (this.activeIndex = index)}
585
+ >
586
+ ${item.label}
587
+ </button>
588
+ </li>
589
+ `)}
590
+ </ul>
591
+ `;
592
+ }
593
+ };
594
+ __decorate([
595
+ property({ type: Array })
596
+ ], TTDropdownMenu.prototype, "items", void 0);
597
+ __decorate([
598
+ property({ type: String })
599
+ ], TTDropdownMenu.prototype, "label", void 0);
600
+ __decorate([
601
+ property({ type: String })
602
+ ], TTDropdownMenu.prototype, "align", void 0);
603
+ __decorate([
604
+ property({ type: Boolean, reflect: true })
605
+ ], TTDropdownMenu.prototype, "disabled", void 0);
606
+ __decorate([
607
+ property({ type: String, reflect: true })
608
+ ], TTDropdownMenu.prototype, "size", void 0);
609
+ __decorate([
610
+ state()
611
+ ], TTDropdownMenu.prototype, "open", void 0);
612
+ __decorate([
613
+ state()
614
+ ], TTDropdownMenu.prototype, "activeIndex", void 0);
615
+ __decorate([
616
+ state()
617
+ ], TTDropdownMenu.prototype, "customTrigger", void 0);
618
+ __decorate([
619
+ state()
620
+ ], TTDropdownMenu.prototype, "triggerHasText", void 0);
621
+ __decorate([
622
+ query(".trigger")
623
+ ], TTDropdownMenu.prototype, "trigger", void 0);
624
+ __decorate([
625
+ query(".menu")
626
+ ], TTDropdownMenu.prototype, "menu", void 0);
627
+ TTDropdownMenu = __decorate([
628
+ customElement("tt-dropdown-menu")
629
+ ], TTDropdownMenu);
630
+ export { TTDropdownMenu };
631
+ //# sourceMappingURL=tt-dropdown-menu.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"tt-dropdown-menu.js","sourceRoot":"","sources":["../src/tt-dropdown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5ChC,cAAc;IAD1B,aAAa,CAAC,kBAAkB,CAAC;GACrB,cAAc,CAymB1B"}
@@ -0,0 +1,13 @@
1
+ import { LitElement } from "lit";
2
+ export declare class TTEmptyState extends LitElement {
3
+ heading: string;
4
+ description: string;
5
+ static styles: import("lit").CSSResult;
6
+ render(): import("lit-html").TemplateResult<1>;
7
+ }
8
+ declare global {
9
+ interface HTMLElementTagNameMap {
10
+ "tt-empty-state": TTEmptyState;
11
+ }
12
+ }
13
+ //# sourceMappingURL=tt-empty-state.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"tt-empty-state.d.ts","sourceRoot":"","sources":["../src/tt-empty-state.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAa,MAAM,KAAK,CAAC;AAG5C,qBACa,YAAa,SAAQ,UAAU;IACd,OAAO,SAAM;IACb,WAAW,SAAM;IAE7C,MAAM,CAAC,MAAM,0BA8CX;IAEF,MAAM;CAqBP;AAED,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,qBAAqB;QAC7B,gBAAgB,EAAE,YAAY,CAAC;KAChC;CACF"}