@koobiq/components 20.4.2 → 21.0.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 (771) hide show
  1. package/accordion/accordion-trigger.scss +3 -10
  2. package/accordion/accordion.scss +4 -6
  3. package/actions-panel/actions-panel-container.scss +45 -1
  4. package/alert/alert.component.scss +3 -2
  5. package/app-switcher/_app-switcher-theme.scss +0 -4
  6. package/app-switcher/app-switcher-dropdown-app.scss +3 -2
  7. package/app-switcher/app-switcher-dropdown-site.scss +2 -1
  8. package/app-switcher/{kbq-app-switcher-list-item.scss → app-switcher-list-item.scss} +18 -4
  9. package/app-switcher/app-switcher-tokens.scss +15 -0
  10. package/app-switcher/app-switcher.scss +14 -4
  11. package/autocomplete/autocomplete.scss +7 -6
  12. package/badge/badge.component.scss +5 -8
  13. package/breadcrumbs/breadcrumbs.scss +25 -10
  14. package/button/_button-base.scss +30 -7
  15. package/button/_button-theme.scss +16 -0
  16. package/button/button-group.scss +7 -0
  17. package/button/button-tokens.scss +0 -2
  18. package/button/button.scss +34 -2
  19. package/button-toggle/_button-toggle-theme.scss +7 -2
  20. package/button-toggle/button-toggle.scss +65 -15
  21. package/checkbox/_checkbox-theme.scss +4 -3
  22. package/checkbox/checkbox.scss +3 -6
  23. package/clamped-text/clamped-text.scss +6 -2
  24. package/code-block/code-block-tokens.scss +0 -224
  25. package/code-block/code-block.scss +20 -9
  26. package/content-panel/content-panel-aside.scss +3 -2
  27. package/content-panel/content-panel-container.scss +37 -0
  28. package/content-panel/content-panel.scss +4 -3
  29. package/core/highlight/_highlight-theme.scss +3 -1
  30. package/core/option/action-container.scss +2 -2
  31. package/core/option/action.scss +2 -1
  32. package/core/option/option.scss +2 -1
  33. package/core/pop-up/_pop-up.scss +0 -37
  34. package/core/selection/pseudo-checkbox/pseudo-checkbox.scss +5 -10
  35. package/core/styles/_core.scss +3 -0
  36. package/core/styles/_koobiq-theme.scss +5 -6
  37. package/core/styles/common/_animation.scss +44 -16
  38. package/core/styles/common/_groups-mixins.scss +21 -19
  39. package/core/styles/common/_groups.scss +4 -32
  40. package/core/styles/common/_index.scss +0 -2
  41. package/core/styles/common/_link.scss +117 -0
  42. package/core/styles/common/_list.scss +0 -26
  43. package/core/styles/common/_overlay.scss +8 -10
  44. package/core/styles/common/_rtl.scss +0 -14
  45. package/core/styles/common/_select.scss +33 -15
  46. package/core/styles/common/_squircle.scss +63 -0
  47. package/core/styles/common/_tokens.scss +0 -11
  48. package/core/styles/common/_vendor-prefixes.scss +0 -20
  49. package/core/styles/functions/_timing.scss +0 -22
  50. package/core/styles/theming/_scrollbar-theme.scss +6 -1
  51. package/core/styles/theming/_theming.scss +13 -65
  52. package/core/styles/typography/_index.scss +0 -1
  53. package/core/styles/typography/_typography.scss +0 -143
  54. package/core/styles/visual/_body.scss +1 -6
  55. package/core/styles/visual/_layout.scss +0 -12
  56. package/datepicker/calendar-body.scss +3 -1
  57. package/datepicker/calendar-header.scss +0 -1
  58. package/datepicker/datepicker-content.scss +33 -1
  59. package/datepicker/datepicker-toggle.scss +0 -38
  60. package/dl/dl-tokens.scss +10 -0
  61. package/dl/dl.scss +113 -13
  62. package/dropdown/_dropdown-theme.scss +4 -16
  63. package/dropdown/dropdown-item.scss +4 -10
  64. package/dropdown/dropdown.scss +2 -1
  65. package/empty-state/_empty-state-theme.scss +10 -4
  66. package/empty-state/empty-state-tokens.scss +4 -4
  67. package/empty-state/empty-state.scss +4 -0
  68. package/fesm2022/koobiq-components-accordion.mjs +347 -229
  69. package/fesm2022/koobiq-components-accordion.mjs.map +1 -1
  70. package/fesm2022/koobiq-components-actions-panel.mjs +302 -187
  71. package/fesm2022/koobiq-components-actions-panel.mjs.map +1 -1
  72. package/fesm2022/koobiq-components-alert.mjs +39 -39
  73. package/fesm2022/koobiq-components-alert.mjs.map +1 -1
  74. package/fesm2022/koobiq-components-app-switcher.mjs +677 -367
  75. package/fesm2022/koobiq-components-app-switcher.mjs.map +1 -1
  76. package/fesm2022/koobiq-components-autocomplete.mjs +620 -253
  77. package/fesm2022/koobiq-components-autocomplete.mjs.map +1 -1
  78. package/fesm2022/koobiq-components-badge.mjs +46 -48
  79. package/fesm2022/koobiq-components-badge.mjs.map +1 -1
  80. package/fesm2022/koobiq-components-breadcrumbs.mjs +221 -169
  81. package/fesm2022/koobiq-components-breadcrumbs.mjs.map +1 -1
  82. package/fesm2022/koobiq-components-button-toggle.mjs +565 -196
  83. package/fesm2022/koobiq-components-button-toggle.mjs.map +1 -1
  84. package/fesm2022/koobiq-components-button.mjs +332 -116
  85. package/fesm2022/koobiq-components-button.mjs.map +1 -1
  86. package/fesm2022/koobiq-components-checkbox.mjs +172 -132
  87. package/fesm2022/koobiq-components-checkbox.mjs.map +1 -1
  88. package/fesm2022/koobiq-components-clamped-text.mjs +165 -158
  89. package/fesm2022/koobiq-components-clamped-text.mjs.map +1 -1
  90. package/fesm2022/koobiq-components-code-block.mjs +755 -601
  91. package/fesm2022/koobiq-components-code-block.mjs.map +1 -1
  92. package/fesm2022/koobiq-components-content-panel.mjs +260 -143
  93. package/fesm2022/koobiq-components-content-panel.mjs.map +1 -1
  94. package/fesm2022/koobiq-components-core.mjs +4342 -1595
  95. package/fesm2022/koobiq-components-core.mjs.map +1 -1
  96. package/fesm2022/koobiq-components-datepicker.mjs +1713 -1606
  97. package/fesm2022/koobiq-components-datepicker.mjs.map +1 -1
  98. package/fesm2022/koobiq-components-divider.mjs +73 -36
  99. package/fesm2022/koobiq-components-divider.mjs.map +1 -1
  100. package/fesm2022/koobiq-components-dl.mjs +447 -89
  101. package/fesm2022/koobiq-components-dl.mjs.map +1 -1
  102. package/fesm2022/koobiq-components-dropdown.mjs +703 -599
  103. package/fesm2022/koobiq-components-dropdown.mjs.map +1 -1
  104. package/fesm2022/koobiq-components-dynamic-translation.mjs +20 -20
  105. package/fesm2022/koobiq-components-dynamic-translation.mjs.map +1 -1
  106. package/fesm2022/koobiq-components-ellipsis-center.mjs +46 -31
  107. package/fesm2022/koobiq-components-ellipsis-center.mjs.map +1 -1
  108. package/fesm2022/koobiq-components-empty-state.mjs +116 -60
  109. package/fesm2022/koobiq-components-empty-state.mjs.map +1 -1
  110. package/fesm2022/koobiq-components-file-upload.mjs +550 -290
  111. package/fesm2022/koobiq-components-file-upload.mjs.map +1 -1
  112. package/fesm2022/koobiq-components-filter-bar.mjs +2810 -2538
  113. package/fesm2022/koobiq-components-filter-bar.mjs.map +1 -1
  114. package/fesm2022/koobiq-components-flag.mjs +79 -24
  115. package/fesm2022/koobiq-components-flag.mjs.map +1 -1
  116. package/fesm2022/koobiq-components-form-field.mjs +389 -525
  117. package/fesm2022/koobiq-components-form-field.mjs.map +1 -1
  118. package/fesm2022/koobiq-components-icon.mjs +366 -136
  119. package/fesm2022/koobiq-components-icon.mjs.map +1 -1
  120. package/fesm2022/koobiq-components-inline-edit.mjs +429 -212
  121. package/fesm2022/koobiq-components-inline-edit.mjs.map +1 -1
  122. package/fesm2022/koobiq-components-input.mjs +601 -459
  123. package/fesm2022/koobiq-components-input.mjs.map +1 -1
  124. package/fesm2022/koobiq-components-link-deprecated.mjs +196 -0
  125. package/fesm2022/koobiq-components-link-deprecated.mjs.map +1 -0
  126. package/fesm2022/koobiq-components-link.mjs +328 -125
  127. package/fesm2022/koobiq-components-link.mjs.map +1 -1
  128. package/fesm2022/koobiq-components-list.mjs +583 -433
  129. package/fesm2022/koobiq-components-list.mjs.map +1 -1
  130. package/fesm2022/koobiq-components-loader-overlay.mjs +167 -68
  131. package/fesm2022/koobiq-components-loader-overlay.mjs.map +1 -1
  132. package/fesm2022/koobiq-components-markdown.mjs +55 -78
  133. package/fesm2022/koobiq-components-markdown.mjs.map +1 -1
  134. package/fesm2022/koobiq-components-modal.mjs +853 -475
  135. package/fesm2022/koobiq-components-modal.mjs.map +1 -1
  136. package/fesm2022/koobiq-components-navbar.mjs +895 -556
  137. package/fesm2022/koobiq-components-navbar.mjs.map +1 -1
  138. package/fesm2022/koobiq-components-notification-center.mjs +680 -310
  139. package/fesm2022/koobiq-components-notification-center.mjs.map +1 -1
  140. package/fesm2022/koobiq-components-overflow-items.mjs +46 -64
  141. package/fesm2022/koobiq-components-overflow-items.mjs.map +1 -1
  142. package/fesm2022/koobiq-components-popover.mjs +684 -285
  143. package/fesm2022/koobiq-components-popover.mjs.map +1 -1
  144. package/fesm2022/koobiq-components-progress-bar.mjs +87 -33
  145. package/fesm2022/koobiq-components-progress-bar.mjs.map +1 -1
  146. package/fesm2022/koobiq-components-progress-spinner.mjs +52 -43
  147. package/fesm2022/koobiq-components-progress-spinner.mjs.map +1 -1
  148. package/fesm2022/koobiq-components-radio.mjs +450 -231
  149. package/fesm2022/koobiq-components-radio.mjs.map +1 -1
  150. package/fesm2022/koobiq-components-resizer.mjs +127 -21
  151. package/fesm2022/koobiq-components-resizer.mjs.map +1 -1
  152. package/fesm2022/koobiq-components-scrollbar-deprecated.mjs +299 -0
  153. package/fesm2022/koobiq-components-scrollbar-deprecated.mjs.map +1 -0
  154. package/fesm2022/koobiq-components-scrollbar.mjs +745 -222
  155. package/fesm2022/koobiq-components-scrollbar.mjs.map +1 -1
  156. package/fesm2022/koobiq-components-search-expandable.mjs +288 -126
  157. package/fesm2022/koobiq-components-search-expandable.mjs.map +1 -1
  158. package/fesm2022/koobiq-components-select.mjs +883 -693
  159. package/fesm2022/koobiq-components-select.mjs.map +1 -1
  160. package/fesm2022/koobiq-components-sidebar.mjs +207 -88
  161. package/fesm2022/koobiq-components-sidebar.mjs.map +1 -1
  162. package/fesm2022/koobiq-components-sidepanel.mjs +689 -296
  163. package/fesm2022/koobiq-components-sidepanel.mjs.map +1 -1
  164. package/fesm2022/koobiq-components-skeleton.mjs +815 -41
  165. package/fesm2022/koobiq-components-skeleton.mjs.map +1 -1
  166. package/fesm2022/koobiq-components-split-button.mjs +109 -88
  167. package/fesm2022/koobiq-components-split-button.mjs.map +1 -1
  168. package/fesm2022/koobiq-components-splitter-deprecated.mjs +591 -0
  169. package/fesm2022/koobiq-components-splitter-deprecated.mjs.map +1 -0
  170. package/fesm2022/koobiq-components-splitter.mjs +890 -501
  171. package/fesm2022/koobiq-components-splitter.mjs.map +1 -1
  172. package/fesm2022/koobiq-components-table.mjs +63 -49
  173. package/fesm2022/koobiq-components-table.mjs.map +1 -1
  174. package/fesm2022/koobiq-components-tabs.mjs +1062 -603
  175. package/fesm2022/koobiq-components-tabs.mjs.map +1 -1
  176. package/fesm2022/koobiq-components-tags.mjs +886 -733
  177. package/fesm2022/koobiq-components-tags.mjs.map +1 -1
  178. package/fesm2022/koobiq-components-textarea.mjs +213 -185
  179. package/fesm2022/koobiq-components-textarea.mjs.map +1 -1
  180. package/fesm2022/koobiq-components-time-range.mjs +299 -147
  181. package/fesm2022/koobiq-components-time-range.mjs.map +1 -1
  182. package/fesm2022/koobiq-components-timepicker.mjs +233 -245
  183. package/fesm2022/koobiq-components-timepicker.mjs.map +1 -1
  184. package/fesm2022/koobiq-components-timezone.mjs +344 -142
  185. package/fesm2022/koobiq-components-timezone.mjs.map +1 -1
  186. package/fesm2022/koobiq-components-title.mjs +229 -145
  187. package/fesm2022/koobiq-components-title.mjs.map +1 -1
  188. package/fesm2022/koobiq-components-toast.mjs +463 -143
  189. package/fesm2022/koobiq-components-toast.mjs.map +1 -1
  190. package/fesm2022/koobiq-components-toggle.mjs +177 -130
  191. package/fesm2022/koobiq-components-toggle.mjs.map +1 -1
  192. package/fesm2022/koobiq-components-tooltip.mjs +657 -214
  193. package/fesm2022/koobiq-components-tooltip.mjs.map +1 -1
  194. package/fesm2022/koobiq-components-top-bar.mjs +61 -32
  195. package/fesm2022/koobiq-components-top-bar.mjs.map +1 -1
  196. package/fesm2022/koobiq-components-tree-select.mjs +719 -488
  197. package/fesm2022/koobiq-components-tree-select.mjs.map +1 -1
  198. package/fesm2022/koobiq-components-tree.mjs +1506 -558
  199. package/fesm2022/koobiq-components-tree.mjs.map +1 -1
  200. package/fesm2022/koobiq-components-username.mjs +290 -135
  201. package/fesm2022/koobiq-components-username.mjs.map +1 -1
  202. package/file-upload/dropzone.scss +31 -3
  203. package/file-upload/file-upload-tokens.scss +2 -22
  204. package/file-upload/file-upload.scss +6 -0
  205. package/file-upload/multiple-file-upload.component.scss +14 -12
  206. package/file-upload/single-file-upload.component.scss +3 -2
  207. package/filter-bar/filters.scss +7 -0
  208. package/filter-bar/pipes/base-pipe.scss +3 -3
  209. package/filter-bar/pipes/pipe-date.scss +8 -1
  210. package/flag/flag-tokens.scss +22 -0
  211. package/flag/flag.scss +34 -21
  212. package/form-field/{_fiedset-theme.scss → _fieldset-theme.scss} +1 -5
  213. package/form-field/_form-field-theme.scss +4 -9
  214. package/form-field/cleaner.scss +3 -1
  215. package/form-field/fieldset.scss +3 -4
  216. package/form-field/form-field.scss +26 -21
  217. package/form-field/password-toggle.scss +3 -1
  218. package/icon/_icon-button-theme.scss +7 -0
  219. package/icon/_icon-theme.scss +10 -7
  220. package/icon/icon-button.scss +0 -2
  221. package/icon/icon-tokens.scss +12 -9
  222. package/inline-edit/inline-edit.scss +40 -54
  223. package/input/input.scss +4 -0
  224. package/link/{_link-theme.scss → deprecated/_link-theme.scss} +11 -6
  225. package/link/deprecated/link-tokens.scss +27 -0
  226. package/link/link-tokens.scss +6 -25
  227. package/link/link.scss +137 -0
  228. package/list/list.scss +3 -2
  229. package/loader-overlay/_loader-overlay-theme.scss +19 -10
  230. package/loader-overlay/loader-overlay-tokens.scss +0 -2
  231. package/loader-overlay/loader-overlay.scss +7 -1
  232. package/markdown/_markdown-theme.scss +16 -0
  233. package/markdown/markdown-tokens.scss +5 -0
  234. package/markdown/markdown.scss +2 -1
  235. package/modal/_modal-animation.scss +23 -14
  236. package/modal/modal-tokens.scss +2 -1
  237. package/modal/modal.scss +35 -31
  238. package/navbar/_navbar-item_horizontal.scss +8 -6
  239. package/navbar/_navbar-item_vertical.scss +18 -6
  240. package/navbar/_navbar-theme.scss +9 -1
  241. package/navbar/navbar-brand.scss +8 -6
  242. package/navbar/navbar-divider.scss +1 -1
  243. package/navbar/navbar-item.scss +8 -9
  244. package/navbar/navbar-toggle.scss +3 -3
  245. package/navbar/navbar-tokens.scss +14 -0
  246. package/navbar/navbar.scss +1 -2
  247. package/navbar/vertical-navbar.scss +2 -2
  248. package/notification-center/_notification-center-theme.scss +11 -6
  249. package/notification-center/notification-center-tokens.scss +33 -0
  250. package/notification-center/notification-center.scss +58 -20
  251. package/notification-center/notification-item.scss +15 -6
  252. package/package.json +112 -81
  253. package/popover/popover-tokens.scss +0 -2
  254. package/popover/popover.scss +41 -19
  255. package/prebuilt-themes/theme.css +1 -1
  256. package/progress-bar/_progress-bar-theme.scss +20 -3
  257. package/progress-bar/progress-bar-tokens.scss +3 -0
  258. package/progress-bar/progress-bar.scss +36 -8
  259. package/progress-spinner/progress-spinner.scss +4 -3
  260. package/radio/_radio-theme.scss +21 -4
  261. package/radio/radio-tokens.scss +7 -3
  262. package/radio/radio.scss +55 -8
  263. package/schematics/collection.json +399 -7
  264. package/schematics/migrations/accordion-state-saving-default/README.md +60 -0
  265. package/schematics/migrations/accordion-state-saving-default/data.js +75 -0
  266. package/schematics/migrations/accordion-state-saving-default/index.js +60 -0
  267. package/schematics/migrations/accordion-state-saving-default/schema.json +15 -0
  268. package/schematics/migrations/actions-panel-overlay-container/README.md +35 -0
  269. package/schematics/migrations/actions-panel-overlay-container/data.js +47 -0
  270. package/schematics/migrations/actions-panel-overlay-container/index.js +54 -0
  271. package/schematics/migrations/actions-panel-overlay-container/schema.json +15 -0
  272. package/schematics/migrations/alert-signals/README.md +13 -7
  273. package/schematics/migrations/alert-signals/data.js +3 -0
  274. package/schematics/migrations/alert-signals/index.js +70 -203
  275. package/schematics/migrations/angular-animations-removal/README.md +46 -0
  276. package/schematics/migrations/angular-animations-removal/data.js +150 -0
  277. package/schematics/migrations/angular-animations-removal/index.js +20 -0
  278. package/schematics/migrations/angular-animations-removal/schema.json +15 -0
  279. package/schematics/migrations/app-switcher-signals/README.md +88 -0
  280. package/schematics/migrations/app-switcher-signals/data.js +136 -0
  281. package/schematics/migrations/app-switcher-signals/index.js +365 -0
  282. package/schematics/migrations/app-switcher-signals/schema.json +20 -0
  283. package/schematics/migrations/autocomplete-panel-width-auto/README.md +2 -2
  284. package/schematics/migrations/autocomplete-panel-width-auto/index.js +1 -1
  285. package/schematics/migrations/autocomplete-signals/README.md +92 -0
  286. package/schematics/migrations/autocomplete-signals/data.js +149 -0
  287. package/schematics/migrations/autocomplete-signals/index.js +706 -0
  288. package/schematics/migrations/autocomplete-signals/schema.json +20 -0
  289. package/schematics/migrations/badge-signals/README.md +77 -0
  290. package/schematics/migrations/badge-signals/data.js +109 -0
  291. package/schematics/migrations/badge-signals/index.js +693 -0
  292. package/schematics/migrations/badge-signals/schema.json +20 -0
  293. package/schematics/migrations/button-state-and-styles/README.md +129 -0
  294. package/schematics/migrations/button-state-and-styles/data.js +136 -0
  295. package/schematics/migrations/button-state-and-styles/index.js +220 -0
  296. package/schematics/migrations/button-state-and-styles/schema.json +20 -0
  297. package/schematics/migrations/button-supported-colors/README.md +73 -0
  298. package/schematics/migrations/button-supported-colors/data.js +106 -0
  299. package/schematics/migrations/button-supported-colors/index.js +260 -0
  300. package/schematics/migrations/button-supported-colors/schema.json +20 -0
  301. package/schematics/migrations/button-toggle-signals-and-aria/README.md +137 -0
  302. package/schematics/migrations/button-toggle-signals-and-aria/data.js +200 -0
  303. package/schematics/migrations/button-toggle-signals-and-aria/index.js +496 -0
  304. package/schematics/migrations/button-toggle-signals-and-aria/schema.json +20 -0
  305. package/schematics/migrations/button-truncation/README.md +110 -0
  306. package/schematics/migrations/button-truncation/data.js +88 -0
  307. package/schematics/migrations/button-truncation/index.js +269 -0
  308. package/schematics/migrations/button-truncation/schema.json +20 -0
  309. package/schematics/migrations/checkbox-signals/README.md +76 -0
  310. package/schematics/migrations/checkbox-signals/data.js +114 -0
  311. package/schematics/migrations/checkbox-signals/index.js +634 -0
  312. package/schematics/migrations/checkbox-signals/schema.json +20 -0
  313. package/schematics/migrations/clamped-text-disclosure/README.md +62 -0
  314. package/schematics/migrations/clamped-text-disclosure/data.js +101 -0
  315. package/schematics/migrations/clamped-text-disclosure/index.js +59 -0
  316. package/schematics/migrations/clamped-text-disclosure/schema.json +15 -0
  317. package/schematics/migrations/code-block-signals/README.md +84 -0
  318. package/schematics/migrations/code-block-signals/data.js +121 -0
  319. package/schematics/migrations/code-block-signals/index.js +700 -0
  320. package/schematics/migrations/code-block-signals/schema.json +20 -0
  321. package/schematics/migrations/color-signals/README.md +46 -0
  322. package/schematics/migrations/color-signals/data.js +131 -0
  323. package/schematics/migrations/color-signals/index.js +19 -0
  324. package/schematics/migrations/color-signals/schema.json +20 -0
  325. package/schematics/migrations/core-mixins-removal/README.md +20 -0
  326. package/schematics/migrations/core-mixins-removal/data.js +27 -0
  327. package/schematics/migrations/core-mixins-removal/index.js +17 -0
  328. package/schematics/migrations/core-mixins-removal/schema.json +15 -0
  329. package/schematics/migrations/css-selectors/README.md +2 -2
  330. package/schematics/migrations/css-selectors/index.js +1 -1
  331. package/schematics/migrations/datepicker-signals/README.md +24 -0
  332. package/schematics/migrations/datepicker-signals/data.js +49 -0
  333. package/schematics/migrations/datepicker-signals/index.js +17 -0
  334. package/schematics/migrations/datepicker-signals/schema.json +15 -0
  335. package/schematics/migrations/deprecated-icons/README.md +2 -2
  336. package/schematics/migrations/deprecated-icons/index.js +1 -1
  337. package/schematics/migrations/design-tokens-v4/README.md +75 -0
  338. package/schematics/migrations/design-tokens-v4/index.js +59 -0
  339. package/schematics/migrations/design-tokens-v4/schema.json +15 -0
  340. package/schematics/migrations/divider-signals-and-aria/README.md +47 -0
  341. package/schematics/migrations/divider-signals-and-aria/data.js +62 -0
  342. package/schematics/migrations/divider-signals-and-aria/index.js +211 -0
  343. package/schematics/migrations/divider-signals-and-aria/schema.json +15 -0
  344. package/schematics/migrations/dl-attribute-coercion/README.md +59 -0
  345. package/schematics/migrations/dl-attribute-coercion/data.js +85 -0
  346. package/schematics/migrations/dl-attribute-coercion/index.js +161 -0
  347. package/schematics/migrations/dl-attribute-coercion/schema.json +15 -0
  348. package/schematics/migrations/dl-standalone-names/README.md +49 -0
  349. package/schematics/migrations/dl-standalone-names/data.js +44 -0
  350. package/schematics/migrations/dl-standalone-names/index.js +321 -0
  351. package/schematics/migrations/dl-standalone-names/schema.json +20 -0
  352. package/schematics/migrations/dropdown-demote-overlay/README.md +137 -0
  353. package/schematics/migrations/dropdown-demote-overlay/data.js +84 -0
  354. package/schematics/migrations/dropdown-demote-overlay/index.js +288 -0
  355. package/schematics/migrations/dropdown-demote-overlay/schema.json +20 -0
  356. package/schematics/migrations/dropdown-signals/README.md +83 -0
  357. package/schematics/migrations/dropdown-signals/data.js +152 -0
  358. package/schematics/migrations/dropdown-signals/index.js +19 -0
  359. package/schematics/migrations/dropdown-signals/schema.json +20 -0
  360. package/schematics/migrations/empty-state-error-color/README.md +84 -0
  361. package/schematics/migrations/empty-state-error-color/data.js +85 -0
  362. package/schematics/migrations/empty-state-error-color/index.js +71 -0
  363. package/schematics/migrations/empty-state-error-color/schema.json +15 -0
  364. package/schematics/migrations/empty-state-size-attr/README.md +2 -2
  365. package/schematics/migrations/empty-state-size-attr/index.js +1 -1
  366. package/schematics/migrations/file-upload-cva-and-primitives/README.md +70 -0
  367. package/schematics/migrations/file-upload-cva-and-primitives/data.js +97 -0
  368. package/schematics/migrations/file-upload-cva-and-primitives/index.js +60 -0
  369. package/schematics/migrations/file-upload-cva-and-primitives/schema.json +15 -0
  370. package/schematics/migrations/file-upload-deprecated-outputs/README.md +90 -0
  371. package/schematics/migrations/file-upload-deprecated-outputs/data.js +20 -0
  372. package/schematics/migrations/file-upload-deprecated-outputs/index.js +70 -0
  373. package/schematics/migrations/file-upload-deprecated-outputs/schema.json +20 -0
  374. package/schematics/migrations/filter-bar-rename-action/README.md +183 -0
  375. package/schematics/migrations/filter-bar-rename-action/data.js +151 -0
  376. package/schematics/migrations/filter-bar-rename-action/index.js +177 -0
  377. package/schematics/migrations/filter-bar-rename-action/schema.json +20 -0
  378. package/schematics/migrations/filter-bar-signals/README.md +27 -16
  379. package/schematics/migrations/filter-bar-signals/data.js +1 -2
  380. package/schematics/migrations/filter-bar-signals/index.js +100 -195
  381. package/schematics/migrations/filter-bar-state-saving-default/README.md +53 -0
  382. package/schematics/migrations/filter-bar-state-saving-default/data.js +87 -0
  383. package/schematics/migrations/filter-bar-state-saving-default/index.js +61 -0
  384. package/schematics/migrations/filter-bar-state-saving-default/schema.json +15 -0
  385. package/schematics/migrations/flag-inner-html/README.md +67 -0
  386. package/schematics/migrations/flag-inner-html/data.js +58 -0
  387. package/schematics/migrations/flag-inner-html/index.js +61 -0
  388. package/schematics/migrations/flag-inner-html/schema.json +15 -0
  389. package/schematics/migrations/form-field-signals/README.md +125 -0
  390. package/schematics/migrations/form-field-signals/data.js +288 -0
  391. package/schematics/migrations/form-field-signals/index.js +382 -0
  392. package/schematics/migrations/form-field-signals/schema.json +20 -0
  393. package/schematics/migrations/icon-semantics-and-api/README.md +65 -0
  394. package/schematics/migrations/icon-semantics-and-api/data.js +97 -0
  395. package/schematics/migrations/icon-semantics-and-api/index.js +64 -0
  396. package/schematics/migrations/icon-semantics-and-api/schema.json +15 -0
  397. package/schematics/migrations/icons-replacement/README.md +5 -5
  398. package/schematics/migrations/icons-replacement/index.js +1 -1
  399. package/schematics/migrations/inline-edit-a11y-and-types/README.md +82 -0
  400. package/schematics/migrations/inline-edit-a11y-and-types/data.js +117 -0
  401. package/schematics/migrations/inline-edit-a11y-and-types/index.js +97 -0
  402. package/schematics/migrations/inline-edit-a11y-and-types/schema.json +20 -0
  403. package/schematics/migrations/input-number-surface/README.md +140 -0
  404. package/schematics/migrations/input-number-surface/data.js +135 -0
  405. package/schematics/migrations/input-number-surface/index.js +292 -0
  406. package/schematics/migrations/input-number-surface/schema.json +20 -0
  407. package/schematics/migrations/input-signals/README.md +20 -0
  408. package/schematics/migrations/input-signals/data.js +30 -0
  409. package/schematics/migrations/input-signals/index.js +17 -0
  410. package/schematics/migrations/input-signals/schema.json +15 -0
  411. package/schematics/migrations/link-deprecated-path/README.md +144 -0
  412. package/schematics/migrations/link-deprecated-path/index.js +19 -0
  413. package/schematics/migrations/link-deprecated-path/schema.json +20 -0
  414. package/schematics/migrations/link-signals/README.md +71 -0
  415. package/schematics/migrations/link-signals/data.js +116 -0
  416. package/schematics/migrations/link-signals/index.js +415 -0
  417. package/schematics/migrations/link-signals/schema.json +20 -0
  418. package/schematics/migrations/list-signals/README.md +22 -0
  419. package/schematics/migrations/list-signals/data.js +35 -0
  420. package/schematics/migrations/list-signals/index.js +17 -0
  421. package/schematics/migrations/list-signals/schema.json +15 -0
  422. package/schematics/migrations/list-tree-multiple-input/README.md +105 -0
  423. package/schematics/migrations/list-tree-multiple-input/data.js +74 -0
  424. package/schematics/migrations/list-tree-multiple-input/index.js +221 -0
  425. package/schematics/migrations/list-tree-multiple-input/schema.json +20 -0
  426. package/schematics/migrations/loader-overlay-signals/README.md +62 -0
  427. package/schematics/migrations/loader-overlay-signals/data.js +101 -0
  428. package/schematics/migrations/loader-overlay-signals/index.js +697 -0
  429. package/schematics/migrations/loader-overlay-signals/schema.json +20 -0
  430. package/schematics/migrations/loader-overlay-size-attr/README.md +2 -2
  431. package/schematics/migrations/loader-overlay-size-attr/index.js +1 -1
  432. package/schematics/migrations/locale-configuration-providers/README.md +163 -0
  433. package/schematics/migrations/locale-configuration-providers/data.js +257 -0
  434. package/schematics/migrations/locale-configuration-providers/index.js +294 -0
  435. package/schematics/migrations/locale-configuration-providers/schema.json +20 -0
  436. package/schematics/migrations/mandatory-peer-dependencies/README.md +70 -0
  437. package/schematics/migrations/mandatory-peer-dependencies/index.js +42 -0
  438. package/schematics/migrations/mandatory-peer-dependencies/schema.json +15 -0
  439. package/schematics/migrations/markdown-signals/README.md +58 -0
  440. package/schematics/migrations/markdown-signals/data.js +79 -0
  441. package/schematics/migrations/markdown-signals/index.js +639 -0
  442. package/schematics/migrations/markdown-signals/schema.json +20 -0
  443. package/schematics/migrations/modal-dialog-semantics/README.md +106 -0
  444. package/schematics/migrations/modal-dialog-semantics/data.js +110 -0
  445. package/schematics/migrations/modal-dialog-semantics/index.js +58 -0
  446. package/schematics/migrations/modal-dialog-semantics/schema.json +15 -0
  447. package/schematics/migrations/modal-signals/README.md +88 -0
  448. package/schematics/migrations/modal-signals/data.js +132 -0
  449. package/schematics/migrations/modal-signals/index.js +19 -0
  450. package/schematics/migrations/modal-signals/schema.json +20 -0
  451. package/schematics/migrations/navbar-signals-and-aria/README.md +111 -0
  452. package/schematics/migrations/navbar-signals-and-aria/data.js +198 -0
  453. package/schematics/migrations/navbar-signals-and-aria/index.js +568 -0
  454. package/schematics/migrations/navbar-signals-and-aria/schema.json +20 -0
  455. package/schematics/migrations/new-icons-pack/README.md +10 -10
  456. package/schematics/migrations/new-icons-pack/index.js +1 -1
  457. package/schematics/migrations/notification-center-signals/README.md +67 -0
  458. package/schematics/migrations/notification-center-signals/data.js +66 -0
  459. package/schematics/migrations/notification-center-signals/index.js +61 -0
  460. package/schematics/migrations/notification-center-signals/schema.json +15 -0
  461. package/schematics/migrations/option-signals/README.md +37 -0
  462. package/schematics/migrations/option-signals/data.js +86 -0
  463. package/schematics/migrations/option-signals/index.js +19 -0
  464. package/schematics/migrations/option-signals/schema.json +20 -0
  465. package/schematics/migrations/popover-leave-delay/README.md +51 -0
  466. package/schematics/migrations/popover-leave-delay/data.js +61 -0
  467. package/schematics/migrations/popover-leave-delay/index.js +54 -0
  468. package/schematics/migrations/popover-leave-delay/schema.json +15 -0
  469. package/schematics/migrations/progress-bar-percentage-and-aria/README.md +54 -0
  470. package/schematics/migrations/progress-bar-percentage-and-aria/data.js +76 -0
  471. package/schematics/migrations/progress-bar-percentage-and-aria/index.js +58 -0
  472. package/schematics/migrations/progress-bar-percentage-and-aria/schema.json +15 -0
  473. package/schematics/migrations/progress-spinner-signals/README.md +72 -0
  474. package/schematics/migrations/progress-spinner-signals/data.js +83 -0
  475. package/schematics/migrations/progress-spinner-signals/index.js +694 -0
  476. package/schematics/migrations/progress-spinner-signals/schema.json +20 -0
  477. package/schematics/migrations/query-list-signals/README.md +32 -0
  478. package/schematics/migrations/query-list-signals/data.js +70 -0
  479. package/schematics/migrations/query-list-signals/index.js +17 -0
  480. package/schematics/migrations/query-list-signals/schema.json +15 -0
  481. package/schematics/migrations/radio-signals-and-aria/README.md +82 -0
  482. package/schematics/migrations/radio-signals-and-aria/data.js +163 -0
  483. package/schematics/migrations/radio-signals-and-aria/index.js +39 -0
  484. package/schematics/migrations/radio-signals-and-aria/schema.json +20 -0
  485. package/schematics/migrations/read-state-dwell-handlers/README.md +125 -0
  486. package/schematics/migrations/read-state-dwell-handlers/data.js +45 -0
  487. package/schematics/migrations/read-state-dwell-handlers/index.js +215 -0
  488. package/schematics/migrations/read-state-dwell-handlers/schema.json +20 -0
  489. package/schematics/migrations/scrollbar-deprecated-path/README.md +128 -0
  490. package/schematics/migrations/scrollbar-deprecated-path/index.js +20 -0
  491. package/schematics/migrations/scrollbar-deprecated-path/schema.json +20 -0
  492. package/schematics/migrations/select-signal-inputs/README.md +61 -0
  493. package/schematics/migrations/select-signal-inputs/data.js +99 -0
  494. package/schematics/migrations/select-signal-inputs/index.js +57 -0
  495. package/schematics/migrations/select-signal-inputs/schema.json +15 -0
  496. package/schematics/migrations/sidepanel-non-modal-behavior/README.md +57 -0
  497. package/schematics/migrations/sidepanel-non-modal-behavior/data.js +111 -0
  498. package/schematics/migrations/sidepanel-non-modal-behavior/index.js +57 -0
  499. package/schematics/migrations/sidepanel-non-modal-behavior/schema.json +15 -0
  500. package/schematics/migrations/signal-inputs-subclasses/README.md +28 -0
  501. package/schematics/migrations/signal-inputs-subclasses/data.js +69 -0
  502. package/schematics/migrations/signal-inputs-subclasses/index.js +17 -0
  503. package/schematics/migrations/signal-inputs-subclasses/schema.json +15 -0
  504. package/schematics/migrations/split-button-optional-disabled/README.md +47 -0
  505. package/schematics/migrations/split-button-optional-disabled/data.js +53 -0
  506. package/schematics/migrations/split-button-optional-disabled/index.js +57 -0
  507. package/schematics/migrations/split-button-optional-disabled/schema.json +15 -0
  508. package/schematics/migrations/splitter-deprecated-path/README.md +136 -0
  509. package/schematics/migrations/splitter-deprecated-path/index.js +20 -0
  510. package/schematics/migrations/splitter-deprecated-path/schema.json +20 -0
  511. package/schematics/migrations/state-saving-default/README.md +67 -0
  512. package/schematics/migrations/state-saving-default/data.js +88 -0
  513. package/schematics/migrations/state-saving-default/index.js +62 -0
  514. package/schematics/migrations/state-saving-default/schema.json +15 -0
  515. package/schematics/migrations/table-cell-content/README.md +55 -0
  516. package/schematics/migrations/table-cell-content/data.js +66 -0
  517. package/schematics/migrations/table-cell-content/index.js +66 -0
  518. package/schematics/migrations/table-cell-content/schema.json +15 -0
  519. package/schematics/migrations/tabs-signals-and-aria/README.md +93 -0
  520. package/schematics/migrations/tabs-signals-and-aria/data.js +139 -0
  521. package/schematics/migrations/tabs-signals-and-aria/index.js +65 -0
  522. package/schematics/migrations/tabs-signals-and-aria/schema.json +15 -0
  523. package/schematics/migrations/tag-list-cleaner/README.md +58 -0
  524. package/schematics/migrations/tag-list-cleaner/data.js +42 -0
  525. package/schematics/migrations/tag-list-cleaner/index.js +196 -0
  526. package/schematics/migrations/tag-list-cleaner/schema.json +20 -0
  527. package/schematics/migrations/tag-slots/README.md +41 -0
  528. package/schematics/migrations/tag-slots/index.js +190 -0
  529. package/schematics/migrations/tag-slots/schema.json +20 -0
  530. package/schematics/migrations/tags-signals/README.md +85 -0
  531. package/schematics/migrations/tags-signals/data.js +103 -0
  532. package/schematics/migrations/tags-signals/index.js +673 -0
  533. package/schematics/migrations/tags-signals/schema.json +20 -0
  534. package/schematics/migrations/textarea-signals/README.md +72 -0
  535. package/schematics/migrations/textarea-signals/data.js +121 -0
  536. package/schematics/migrations/textarea-signals/index.js +379 -0
  537. package/schematics/migrations/textarea-signals/schema.json +20 -0
  538. package/schematics/migrations/time-range-title-for/README.md +164 -0
  539. package/schematics/migrations/time-range-title-for/data.js +139 -0
  540. package/schematics/migrations/time-range-title-for/index.js +163 -0
  541. package/schematics/migrations/time-range-title-for/schema.json +20 -0
  542. package/schematics/migrations/timepicker-signals/README.md +78 -0
  543. package/schematics/migrations/timepicker-signals/data.js +82 -0
  544. package/schematics/migrations/timepicker-signals/index.js +709 -0
  545. package/schematics/migrations/timepicker-signals/schema.json +20 -0
  546. package/schematics/migrations/timezone-grouping-utils/README.md +73 -0
  547. package/schematics/migrations/timezone-grouping-utils/data.js +101 -0
  548. package/schematics/migrations/timezone-grouping-utils/index.js +64 -0
  549. package/schematics/migrations/timezone-grouping-utils/schema.json +15 -0
  550. package/schematics/migrations/title-encapsulation/README.md +49 -0
  551. package/schematics/migrations/title-encapsulation/data.js +69 -0
  552. package/schematics/migrations/title-encapsulation/index.js +57 -0
  553. package/schematics/migrations/title-encapsulation/schema.json +15 -0
  554. package/schematics/migrations/toast-stack-and-defaults/README.md +102 -0
  555. package/schematics/migrations/toast-stack-and-defaults/data.js +79 -0
  556. package/schematics/migrations/toast-stack-and-defaults/index.js +53 -0
  557. package/schematics/migrations/toast-stack-and-defaults/schema.json +15 -0
  558. package/schematics/migrations/tooltip-pointer-events-and-types/README.md +53 -0
  559. package/schematics/migrations/tooltip-pointer-events-and-types/data.js +89 -0
  560. package/schematics/migrations/tooltip-pointer-events-and-types/index.js +60 -0
  561. package/schematics/migrations/tooltip-pointer-events-and-types/schema.json +15 -0
  562. package/schematics/migrations/top-bar-container-selectors/README.md +111 -0
  563. package/schematics/migrations/top-bar-container-selectors/data.js +56 -0
  564. package/schematics/migrations/top-bar-container-selectors/index.js +84 -0
  565. package/schematics/migrations/top-bar-container-selectors/schema.json +20 -0
  566. package/schematics/migrations/tree-select-signals/README.md +61 -0
  567. package/schematics/migrations/tree-select-signals/data.js +106 -0
  568. package/schematics/migrations/tree-select-signals/index.js +58 -0
  569. package/schematics/migrations/tree-select-signals/schema.json +15 -0
  570. package/schematics/migrations/tree-signals/README.md +82 -0
  571. package/schematics/migrations/tree-signals/data.js +123 -0
  572. package/schematics/migrations/tree-signals/index.js +54 -0
  573. package/schematics/migrations/tree-signals/schema.json +15 -0
  574. package/schematics/migrations/tree-state-saving-default/README.md +66 -0
  575. package/schematics/migrations/tree-state-saving-default/data.js +78 -0
  576. package/schematics/migrations/tree-state-saving-default/index.js +60 -0
  577. package/schematics/migrations/tree-state-saving-default/schema.json +15 -0
  578. package/schematics/migrations/username-pipe-injection/README.md +59 -0
  579. package/schematics/migrations/username-pipe-injection/data.js +78 -0
  580. package/schematics/migrations/username-pipe-injection/index.js +58 -0
  581. package/schematics/migrations/username-pipe-injection/schema.json +15 -0
  582. package/schematics/migrations/v20-upgrade/README.md +36 -16
  583. package/schematics/migrations/v20-upgrade/data.js +124 -77
  584. package/schematics/migrations/v20-upgrade/index.js +6 -213
  585. package/schematics/migrations/v21-upgrade/README.md +271 -0
  586. package/schematics/migrations/v21-upgrade/data.js +1371 -0
  587. package/schematics/migrations/v21-upgrade/index.js +94 -0
  588. package/schematics/migrations/v21-upgrade/schema.json +20 -0
  589. package/schematics/migrations/zoneless-change-detection/README.md +30 -0
  590. package/schematics/migrations/zoneless-change-detection/data.js +29 -0
  591. package/schematics/migrations/zoneless-change-detection/index.js +20 -0
  592. package/schematics/migrations/zoneless-change-detection/schema.json +15 -0
  593. package/schematics/migrations.json +392 -2
  594. package/schematics/ng-add/index.js +515 -14
  595. package/schematics/ng-add/schema.json +15 -0
  596. package/schematics/utils/deprecated-path-migration.js +61 -0
  597. package/schematics/utils/package-config.js +9 -105
  598. package/scrollbar/{_scrollbar-component-theme.scss → deprecated/_scrollbar-component-theme.scss} +1 -1
  599. package/scrollbar/{scrollbar.component.scss → deprecated/scrollbar.component.scss} +1 -1
  600. package/scrollbar/native-scrollbar.scss +68 -0
  601. package/scrollbar/scrollbar-tokens.scss +13 -22
  602. package/scrollbar/scrollbar-track.scss +94 -0
  603. package/scrollbar/scrollbar-viewport.scss +33 -0
  604. package/scrollbar/scrollbar.scss +24 -0
  605. package/search-expandable/search-expandable-tokens.scss +4 -0
  606. package/search-expandable/search-expandable.scss +4 -2
  607. package/select/_select-theme.scss +3 -16
  608. package/select/select.scss +0 -6
  609. package/sidebar/sidebar.scss +20 -0
  610. package/sidepanel/_sidepanel-theme.scss +1 -1
  611. package/sidepanel/sidepanel-tokens.scss +7 -1
  612. package/sidepanel/sidepanel.scss +41 -5
  613. package/skeleton/skeleton-presets.scss +350 -0
  614. package/skeleton/skeleton-tokens.scss +127 -0
  615. package/skeleton/skeleton.scss +53 -45
  616. package/split-button/_split-button-theme.scss +4 -4
  617. package/split-button/split-button.scss +2 -6
  618. package/splitter/{_splitter-theme.scss → deprecated/_splitter-theme.scss} +1 -1
  619. package/splitter/deprecated/splitter.scss +51 -0
  620. package/splitter/splitter-tokens.scss +19 -0
  621. package/splitter/splitter.scss +148 -28
  622. package/table/_table-theme.scss +13 -12
  623. package/table/table-tokens.scss +8 -0
  624. package/table/table.scss +47 -22
  625. package/tabs/_tabs-common.scss +14 -14
  626. package/tabs/_tabs-theme.scss +4 -5
  627. package/tabs/tab-body.scss +49 -1
  628. package/tabs/tab-header.scss +2 -1
  629. package/tags/tag-list.scss +4 -0
  630. package/tags/tag.scss +19 -1
  631. package/time-range/time-range.scss +9 -0
  632. package/timezone/timezone-option.component.scss +4 -7
  633. package/timezone/timezone-select.component.scss +3 -0
  634. package/toast/_toast-theme.scss +1 -4
  635. package/toast/toast-container.component.scss +19 -13
  636. package/toast/toast-tokens.scss +12 -6
  637. package/toast/toast.component.scss +42 -19
  638. package/toggle/_toggle-theme.scss +4 -10
  639. package/toggle/toggle.scss +67 -26
  640. package/tooltip/_tooltip-theme.scss +7 -1
  641. package/tooltip/tooltip-tokens.scss +1 -2
  642. package/tooltip/tooltip.scss +55 -9
  643. package/top-bar/top-bar-tokens.scss +13 -2
  644. package/top-bar/top-bar.scss +24 -19
  645. package/tree/_tree-theme.scss +0 -1
  646. package/tree/toggle.scss +5 -9
  647. package/tree/tree-option.scss +2 -4
  648. package/tree/tree-tokens.scss +2 -1
  649. package/tree/tree.scss +3 -5
  650. package/tree-select/_tree-select-theme.scss +4 -15
  651. package/tree-select/tree-select-tokens.scss +16 -0
  652. package/tree-select/tree-select.scss +0 -6
  653. package/{accordion/index.d.ts → types/koobiq-components-accordion.d.ts} +102 -84
  654. package/{actions-panel/index.d.ts → types/koobiq-components-actions-panel.d.ts} +44 -59
  655. package/{alert/index.d.ts → types/koobiq-components-alert.d.ts} +8 -3
  656. package/types/koobiq-components-app-switcher.d.ts +406 -0
  657. package/types/koobiq-components-autocomplete.d.ts +443 -0
  658. package/{badge/index.d.ts → types/koobiq-components-badge.d.ts} +25 -20
  659. package/{breadcrumbs/index.d.ts → types/koobiq-components-breadcrumbs.d.ts} +97 -46
  660. package/types/koobiq-components-button-toggle.d.ts +340 -0
  661. package/types/koobiq-components-button.d.ts +296 -0
  662. package/types/koobiq-components-checkbox.d.ts +172 -0
  663. package/types/koobiq-components-clamped-text.d.ts +184 -0
  664. package/{code-block/index.d.ts → types/koobiq-components-code-block.d.ts} +114 -79
  665. package/{content-panel/index.d.ts → types/koobiq-components-content-panel.d.ts} +81 -25
  666. package/{core/index.d.ts → types/koobiq-components-core.d.ts} +2827 -865
  667. package/{datepicker/index.d.ts → types/koobiq-components-datepicker.d.ts} +161 -116
  668. package/types/koobiq-components-divider.d.ts +43 -0
  669. package/types/koobiq-components-dl.d.ts +235 -0
  670. package/{dropdown/index.d.ts → types/koobiq-components-dropdown.d.ts} +245 -239
  671. package/types/koobiq-components-ellipsis-center.d.ts +85 -0
  672. package/types/koobiq-components-empty-state.d.ts +106 -0
  673. package/{file-upload/index.d.ts → types/koobiq-components-file-upload.d.ts} +214 -107
  674. package/{filter-bar/index.d.ts → types/koobiq-components-filter-bar.d.ts} +410 -495
  675. package/types/koobiq-components-flag.d.ts +68 -0
  676. package/{form-field/index.d.ts → types/koobiq-components-form-field.d.ts} +167 -191
  677. package/types/koobiq-components-icon.d.ts +333 -0
  678. package/{inline-edit/index.d.ts → types/koobiq-components-inline-edit.d.ts} +109 -46
  679. package/types/koobiq-components-input.d.ts +477 -0
  680. package/types/koobiq-components-link-deprecated.d.ts +101 -0
  681. package/types/koobiq-components-link.d.ts +176 -0
  682. package/{list/index.d.ts → types/koobiq-components-list.d.ts} +162 -99
  683. package/types/koobiq-components-loader-overlay.d.ts +101 -0
  684. package/{markdown/index.d.ts → types/koobiq-components-markdown.d.ts} +16 -24
  685. package/types/koobiq-components-modal.d.ts +666 -0
  686. package/types/koobiq-components-navbar.d.ts +569 -0
  687. package/types/koobiq-components-notification-center.d.ts +500 -0
  688. package/{overflow-items/index.d.ts → types/koobiq-components-overflow-items.d.ts} +8 -22
  689. package/types/koobiq-components-popover.d.ts +468 -0
  690. package/types/koobiq-components-progress-bar.d.ts +67 -0
  691. package/{progress-spinner/index.d.ts → types/koobiq-components-progress-spinner.d.ts} +33 -10
  692. package/types/koobiq-components-radio.d.ts +294 -0
  693. package/{resizer/index.d.ts → types/koobiq-components-resizer.d.ts} +37 -2
  694. package/{scrollbar/index.d.ts → types/koobiq-components-scrollbar-deprecated.d.ts} +18 -1
  695. package/types/koobiq-components-scrollbar.d.ts +154 -0
  696. package/types/koobiq-components-search-expandable.d.ts +164 -0
  697. package/{select/index.d.ts → types/koobiq-components-select.d.ts} +360 -167
  698. package/types/koobiq-components-sidebar.d.ts +152 -0
  699. package/types/koobiq-components-sidepanel.d.ts +436 -0
  700. package/types/koobiq-components-skeleton.d.ts +234 -0
  701. package/types/koobiq-components-split-button.d.ts +65 -0
  702. package/{splitter/index.d.ts → types/koobiq-components-splitter-deprecated.d.ts} +44 -1
  703. package/types/koobiq-components-splitter.d.ts +406 -0
  704. package/types/koobiq-components-table.d.ts +44 -0
  705. package/types/koobiq-components-tabs.d.ts +888 -0
  706. package/{tags/index.d.ts → types/koobiq-components-tags.d.ts} +249 -133
  707. package/types/koobiq-components-textarea.d.ts +178 -0
  708. package/{time-range/index.d.ts → types/koobiq-components-time-range.d.ts} +135 -62
  709. package/types/koobiq-components-timepicker.d.ts +223 -0
  710. package/types/koobiq-components-timezone.d.ts +266 -0
  711. package/types/koobiq-components-title.d.ts +184 -0
  712. package/types/koobiq-components-toast.d.ts +289 -0
  713. package/types/koobiq-components-toggle.d.ts +121 -0
  714. package/types/koobiq-components-tooltip.d.ts +610 -0
  715. package/types/koobiq-components-top-bar.d.ts +61 -0
  716. package/types/koobiq-components-tree-select.d.ts +667 -0
  717. package/types/koobiq-components-tree.d.ts +1290 -0
  718. package/types/koobiq-components-username.d.ts +340 -0
  719. package/username/_username-theme.scss +35 -0
  720. package/username/username.scss +10 -34
  721. package/app-switcher/index.d.ts +0 -276
  722. package/autocomplete/index.d.ts +0 -286
  723. package/button/index.d.ts +0 -153
  724. package/button-toggle/index.d.ts +0 -162
  725. package/checkbox/index.d.ts +0 -163
  726. package/clamped-text/index.d.ts +0 -146
  727. package/core/styles/_tokens.scss +0 -7
  728. package/core/styles/common/_clearfix.scss +0 -13
  729. package/core/styles/common/_popup.scss +0 -6
  730. package/core/styles/functions/_index.scss +0 -3
  731. package/core/styles/functions/_number.scss +0 -60
  732. package/core/styles/functions/_string.scss +0 -18
  733. package/core/styles/theming/scrollbar-tokens.scss +0 -25
  734. package/core/styles/typography/_typography-utils.scss +0 -84
  735. package/divider/index.d.ts +0 -20
  736. package/dl/index.d.ts +0 -45
  737. package/ellipsis-center/index.d.ts +0 -71
  738. package/empty-state/index.d.ts +0 -45
  739. package/flag/index.d.ts +0 -44
  740. package/icon/index.d.ts +0 -200
  741. package/input/index.d.ts +0 -354
  742. package/link/index.d.ts +0 -56
  743. package/loader-overlay/index.d.ts +0 -57
  744. package/modal/index.d.ts +0 -339
  745. package/navbar/index.d.ts +0 -372
  746. package/notification-center/index.d.ts +0 -323
  747. package/popover/index.d.ts +0 -182
  748. package/prebuilt-themes/dark-theme.css +0 -1
  749. package/prebuilt-themes/light-theme.css +0 -1
  750. package/progress-bar/index.d.ts +0 -31
  751. package/radio/index.d.ts +0 -203
  752. package/search-expandable/index.d.ts +0 -101
  753. package/sidebar/index.d.ts +0 -94
  754. package/sidepanel/index.d.ts +0 -272
  755. package/skeleton/index.d.ts +0 -26
  756. package/split-button/index.d.ts +0 -46
  757. package/table/index.d.ts +0 -25
  758. package/tabs/index.d.ts +0 -677
  759. package/textarea/index.d.ts +0 -138
  760. package/timepicker/index.d.ts +0 -197
  761. package/timezone/index.d.ts +0 -125
  762. package/title/index.d.ts +0 -139
  763. package/toast/index.d.ts +0 -178
  764. package/toggle/index.d.ts +0 -104
  765. package/tooltip/index.d.ts +0 -335
  766. package/top-bar/index.d.ts +0 -33
  767. package/tree/index.d.ts +0 -802
  768. package/tree-select/index.d.ts +0 -475
  769. package/username/index.d.ts +0 -194
  770. /package/{dynamic-translation/index.d.ts → types/koobiq-components-dynamic-translation.d.ts} +0 -0
  771. /package/{index.d.ts → types/koobiq-components.d.ts} +0 -0
@@ -1,60 +1,19 @@
1
- import { trigger, state, style, transition, animate, group, query } from '@angular/animations';
2
1
  import { TemplatePortal, DomPortalOutlet } from '@angular/cdk/portal';
3
2
  import { DOCUMENT } from '@angular/common';
4
3
  import * as i0 from '@angular/core';
5
- import { inject, TemplateRef, ApplicationRef, Injector, ViewContainerRef, Directive, InjectionToken, ElementRef, effect, contentChild, input, booleanAttribute, signal, Input, ContentChild, ViewChild, ViewEncapsulation, ChangeDetectionStrategy, Component, NgZone, DestroyRef, contentChildren, computed, numberAttribute, EventEmitter, QueryList, untracked, Output, ContentChildren, ChangeDetectorRef, Renderer2, output, NgModule } from '@angular/core';
4
+ import { inject, TemplateRef, ApplicationRef, Injector, ViewContainerRef, Directive, InjectionToken, ElementRef, effect, viewChild, contentChild, input, booleanAttribute, computed, signal, untracked, ViewEncapsulation, ChangeDetectionStrategy, Component, NgZone, Renderer2, DestroyRef, contentChildren, model, numberAttribute, output, QueryList, afterNextRender, NgModule } from '@angular/core';
6
5
  import { Subject, Subscription, merge, timer, of, asapScheduler } from 'rxjs';
7
6
  import { FocusMonitor } from '@angular/cdk/a11y';
8
- import { TAB, UP_ARROW, DOWN_ARROW, ENTER } from '@angular/cdk/keycodes';
9
- import { KBQ_PANEL_DEFAULT_MIN_WIDTH, KbqComponentColors, KBQ_TITLE_TEXT_REF, ESCAPE, LEFT_ARROW, RIGHT_ARROW, isPointInRect, isPointInTriangle, ActiveDescendantKeyManager, FocusKeyManager, getSafeTriangleVertices, ENTER as ENTER$1, SPACE, DOWN_ARROW as DOWN_ARROW$1, defaultOffsetY, kbqResolvePanelWidth, kbqGetPanelWidthOrigin, kbqSiblingPopupProvider } from '@koobiq/components/core';
7
+ import { ENTER, SPACE, TAB, UP_ARROW, DOWN_ARROW } from '@angular/cdk/keycodes';
8
+ import { KBQ_PANEL_DEFAULT_MIN_WIDTH, KbqComponentColors, kbqAnimationsDisabled, KBQ_TITLE_TEXT_REF, ESCAPE, LEFT_ARROW, RIGHT_ARROW, isExplicitPanelWidth, isPointInRect, isPointInTriangle, getSafeTriangleVertices, isVerticalMovement, ActiveDescendantKeyManager, FocusKeyManager, kbqRepositionScrollStrategyFactory, KBQ_OVERLAY_LAYERS, ENTER as ENTER$1, SPACE as SPACE$1, DOWN_ARROW as DOWN_ARROW$1, kbqIsElementOrigin, kbqResolveOverlayOrigin, defaultOffsetY, kbqGetPanelWidthOrigin, kbqResolvePanelWidth, kbqSiblingPopupProvider } from '@koobiq/components/core';
10
9
  import { KbqIcon, KbqIconModule } from '@koobiq/components/icon';
11
10
  import { KBQ_FORM_FIELD, KBQ_FORM_FIELD_DEFAULT_OPTIONS, KbqFormField } from '@koobiq/components/form-field';
12
11
  import { Directionality } from '@angular/cdk/bidi';
13
- import { Overlay, OverlayContainer, OverlayConfig, OverlayModule } from '@angular/cdk/overlay';
14
- import { normalizePassiveListenerOptions, Platform } from '@angular/cdk/platform';
12
+ import { ScrollDispatcher, Overlay, OverlayConfig, OverlayModule } from '@angular/cdk/overlay';
13
+ import { normalizePassiveListenerOptions, Platform, _getEventTarget } from '@angular/cdk/platform';
15
14
  import { takeUntilDestroyed, outputToObservable } from '@angular/core/rxjs-interop';
16
- import { take, startWith, switchMap, filter, delay, map, takeUntil } from 'rxjs/operators';
17
- import { coerceBooleanProperty } from '@angular/cdk/coercion';
18
-
19
- /**
20
- * Animations used by the kbq-dropdown component.
21
- * @docs-private
22
- */
23
- const kbqDropdownAnimations = {
24
- /**
25
- * This animation controls the dropdown panel's entry and exit from the page.
26
- *
27
- * When the dropdown panel is added to the DOM, it scales in and fades in its border.
28
- *
29
- * When the dropdown panel is removed from the DOM, it simply fades out after a brief
30
- * delay to display the ripple.
31
- */
32
- transformDropdown: trigger('transformDropdown', [
33
- state('void', style({
34
- opacity: 0,
35
- transform: 'scale(0.8)'
36
- })),
37
- transition('void => enter', group([
38
- query('.kbq-dropdown__content', animate('0ms linear', style({ opacity: 1 }))),
39
- animate('0ms cubic-bezier(0, 0, 0.2, 1)', style({ transform: 'scale(1)' }))
40
- ])),
41
- transition('* => void', animate('50ms 25ms linear', style({ opacity: 0 })))
42
- ]),
43
- /**
44
- * This animation fades in the background color and content of the dropdown panel
45
- * after its containing element is scaled in.
46
- */
47
- fadeInItems: trigger('fadeInItems', [
48
- // now. Remove next time we do breaking changes.
49
- state('showing', style({ opacity: 1 })),
50
- transition('void => *', [
51
- style({ opacity: 0 }),
52
- animate('0ms 0ms cubic-bezier(0.55, 0, 0.55, 0.2)')
53
- ])
54
- ])
55
- };
56
- const fadeInItems = kbqDropdownAnimations.fadeInItems;
57
- const transformDropdown = kbqDropdownAnimations.transformDropdown;
15
+ import { startWith, switchMap, filter, delay, map, takeUntil } from 'rxjs/operators';
16
+ import { KbqScrollbarViewport } from '@koobiq/components/scrollbar';
58
17
 
59
18
  /**
60
19
  * Dropdown content that will be rendered lazily once the dropdown is opened.
@@ -71,6 +30,7 @@ class KbqDropdownContent {
71
30
  }
72
31
  /**
73
32
  * Attaches the content with a particular context.
33
+ *
74
34
  * @docs-private
75
35
  */
76
36
  attach(context = {}) {
@@ -91,6 +51,7 @@ class KbqDropdownContent {
91
51
  }
92
52
  /**
93
53
  * Detaches the content.
54
+ *
94
55
  * @docs-private
95
56
  */
96
57
  detach() {
@@ -101,10 +62,10 @@ class KbqDropdownContent {
101
62
  ngOnDestroy() {
102
63
  this.outlet?.dispose();
103
64
  }
104
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.30", ngImport: i0, type: KbqDropdownContent, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
105
- /** @nocollapse */ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "20.3.30", type: KbqDropdownContent, isStandalone: true, selector: "ng-template[kbqDropdownContent]", ngImport: i0 }); }
65
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: KbqDropdownContent, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
66
+ /** @nocollapse */ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.25", type: KbqDropdownContent, isStandalone: true, selector: "ng-template[kbqDropdownContent]", ngImport: i0 }); }
106
67
  }
107
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.30", ngImport: i0, type: KbqDropdownContent, decorators: [{
68
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: KbqDropdownContent, decorators: [{
108
69
  type: Directive,
109
70
  args: [{
110
71
  selector: 'ng-template[kbqDropdownContent]'
@@ -113,7 +74,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.30", ngImpo
113
74
 
114
75
  /**
115
76
  * Throws an exception for the case when dropdown trigger doesn't have a valid kbq-dropdown instance
116
- * @docs-private
77
+ *
78
+ * @internal
117
79
  */
118
80
  function throwKbqDropdownMissingError() {
119
81
  throw Error(`kbqDropdownTriggerFor: must pass in an kbq-dropdown instance.
@@ -124,7 +86,8 @@ function throwKbqDropdownMissingError() {
124
86
  /**
125
87
  * Throws an exception for the case when dropdown's x-position value isn't valid.
126
88
  * In other words, it doesn't match 'before' or 'after'.
127
- * @docs-private
89
+ *
90
+ * @internal
128
91
  */
129
92
  function throwKbqDropdownInvalidPositionX() {
130
93
  throw Error(`xPosition value must be either 'before', 'after', or 'center'.
@@ -133,7 +96,8 @@ function throwKbqDropdownInvalidPositionX() {
133
96
  /**
134
97
  * Throws an exception for the case when dropdown's y-position value isn't valid.
135
98
  * In other words, it doesn't match 'above' or 'below'.
136
- * @docs-private
99
+ *
100
+ * @internal
137
101
  */
138
102
  function throwKbqDropdownInvalidPositionY() {
139
103
  throw Error(`yPosition value must be either 'above' or below'.
@@ -142,7 +106,8 @@ function throwKbqDropdownInvalidPositionY() {
142
106
  /**
143
107
  * Throws an exception for the case when `kbqDropdownSearch` is applied to a form field that doesn't
144
108
  * host a `kbqInput`.
145
- * @docs-private
109
+ *
110
+ * @internal
146
111
  */
147
112
  function throwKbqDropdownSearchMissingInputError() {
148
113
  throw Error(`kbqDropdownSearch: must be applied to a kbq-form-field containing an input[kbqInput].
@@ -154,7 +119,8 @@ function throwKbqDropdownSearchMissingInputError() {
154
119
  /**
155
120
  * Throws an exception for the case when `kbqDropdownSearch`'s input isn't bound to a form control, so
156
121
  * there is no query to react to.
157
- * @docs-private
122
+ *
123
+ * @internal
158
124
  */
159
125
  function throwKbqDropdownSearchMissingNgControlError() {
160
126
  throw Error(`kbqDropdownSearch: the input must be bound to a form control.
@@ -203,7 +169,7 @@ class KbqDropdownItemAction {
203
169
  }
204
170
  /** `progress` takes priority over the action, same as `disabled`. */
205
171
  isInactive() {
206
- return this.dropdownItem.disabled || this.dropdownItem.progress();
172
+ return this.dropdownItem.disabled() || this.dropdownItem.progress();
207
173
  }
208
174
  /**
209
175
  * Always stops the click from bubbling to the item's own primary click handler.
@@ -217,10 +183,10 @@ class KbqDropdownItemAction {
217
183
  event.stopImmediatePropagation();
218
184
  }
219
185
  }
220
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.30", ngImport: i0, type: KbqDropdownItemAction, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
221
- /** @nocollapse */ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "20.3.30", type: KbqDropdownItemAction, isStandalone: true, selector: "[kbqDropdownItemAction]", host: { listeners: { "click": "onClick($event)" }, properties: { "class.kbq-disabled": "isInactive()", "attr.aria-disabled": "isInactive() || null" }, classAttribute: "kbq-dropdown-item__action" }, ngImport: i0 }); }
186
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: KbqDropdownItemAction, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
187
+ /** @nocollapse */ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.25", type: KbqDropdownItemAction, isStandalone: true, selector: "[kbqDropdownItemAction]", host: { listeners: { "click": "onClick($event)" }, properties: { "class.kbq-disabled": "isInactive()", "attr.aria-disabled": "isInactive() || null" }, classAttribute: "kbq-dropdown-item__action" }, ngImport: i0 }); }
222
188
  }
223
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.30", ngImport: i0, type: KbqDropdownItemAction, decorators: [{
189
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: KbqDropdownItemAction, decorators: [{
224
190
  type: Directive,
225
191
  args: [{
226
192
  selector: '[kbqDropdownItemAction]',
@@ -235,6 +201,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.30", ngImpo
235
201
 
236
202
  /**
237
203
  * Injection token used to provide the parent dropdown to dropdown-specific components.
204
+ *
238
205
  * @docs-private
239
206
  */
240
207
  const KBQ_DROPDOWN_PANEL = new InjectionToken('KBQ_DROPDOWN_PANEL');
@@ -261,42 +228,75 @@ function KBQ_DROPDOWN_DEFAULT_OPTIONS_FACTORY() {
261
228
  };
262
229
  }
263
230
 
231
+ /** Elements that carry no label text of their own and are skipped when reading an item's label. */
232
+ const NON_LABEL_SELECTOR = '[kbq-icon], .kbq-icon, [kbqDropdownItemAction]';
233
+ /** Hosts that already turn ENTER/SPACE into a click, or handle activation themselves (app-switcher items). */
234
+ const SELF_ACTIVATING_HOST_SELECTOR = 'button, a[href], [role="menuitem"]';
235
+ /** Secondary line of a `kbq-dropdown-item`, shown under the item's text. */
236
+ class KbqDropdownItemCaption {
237
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: KbqDropdownItemCaption, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
238
+ /** @nocollapse */ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.25", type: KbqDropdownItemCaption, isStandalone: true, selector: "[kbqDropdownItemCaption]", host: { classAttribute: "kbq-dropdown-item__caption" }, ngImport: i0 }); }
239
+ }
240
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: KbqDropdownItemCaption, decorators: [{
241
+ type: Directive,
242
+ args: [{
243
+ selector: '[kbqDropdownItemCaption]',
244
+ host: { class: 'kbq-dropdown-item__caption' }
245
+ }]
246
+ }] });
264
247
  /**
265
248
  * This directive is intended to be used inside an kbq-dropdown tag.
266
- * It exists mostly to set the role attribute.
249
+ *
250
+ * Note that it sets no ARIA role: neither the panel nor its items currently carry menu semantics, so
251
+ * triggers must not advertise a popup they cannot describe.
267
252
  */
268
253
  class KbqDropdownItem {
269
- // TODO: Skipped for migration because:
270
- // Accessor inputs cannot be migrated as they are too complex.
271
- get disabled() {
272
- return this._disabled;
273
- }
274
- set disabled(value) {
275
- if (value !== this.disabled) {
276
- this._disabled = value;
277
- }
254
+ /** Element holding the text of the item, measured by `kbq-title`. */
255
+ get textElement() {
256
+ return this.textElementQuery();
257
+ }
258
+ /** Whether the dropdown item is highlighted. */
259
+ get highlighted() {
260
+ return this.highlightedState();
261
+ }
262
+ set highlighted(value) {
263
+ this.highlightedState.set(value);
278
264
  }
279
265
  constructor() {
280
266
  this.elementRef = inject(ElementRef);
281
267
  this.focusMonitor = inject(FocusMonitor);
282
268
  this.parentDropdownPanel = inject(KBQ_DROPDOWN_PANEL, { optional: true });
269
+ this.textElementQuery = viewChild('kbqTitleText', ...(ngDevMode ? [{ debugName: "textElementQuery" }] : /* istanbul ignore next */ []));
270
+ this.icon = contentChild(KbqIcon, ...(ngDevMode ? [{ debugName: "icon" }] : /* istanbul ignore next */ []));
283
271
  /** Secondary, independently-focusable icon action projected into the item (e.g. a settings link). */
284
- this.itemAction = contentChild(KbqDropdownItemAction, ...(ngDevMode ? [{ debugName: "itemAction" }] : []));
285
- this._disabled = false;
272
+ this.itemAction = contentChild(KbqDropdownItemAction, ...(ngDevMode ? [{ debugName: "itemAction" }] : /* istanbul ignore next */ []));
273
+ /** Whether the dropdown item is disabled. */
274
+ this.disabled = input(false, { ...(ngDevMode ? { debugName: "disabled" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
286
275
  /** Whether the dropdown item is in a loading state. */
287
- this.progress = input(false, ...(ngDevMode ? [{ debugName: "progress", transform: booleanAttribute }] : [{ transform: booleanAttribute }]));
276
+ this.progress = input(false, { ...(ngDevMode ? { debugName: "progress" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
277
+ /**
278
+ * Value of the `disabled` and `aria-disabled` attributes.
279
+ *
280
+ * @internal
281
+ */
282
+ this.disabledAttribute = computed(() => this.disabled() || null, ...(ngDevMode ? [{ debugName: "disabledAttribute" }] : /* istanbul ignore next */ []));
288
283
  /** Stream that emits when the dropdown item is hovered. */
289
284
  this.hovered = new Subject();
290
285
  /** Stream that emits when the menu item is focused. */
291
286
  this.focused = new Subject();
292
- /** Whether the dropdown item is highlighted. */
293
- this.highlighted = false;
287
+ this.highlightedState = signal(false, ...(ngDevMode ? [{ debugName: "highlightedState" }] : /* istanbul ignore next */ []));
294
288
  /** Whether the item is the panel's active item while DOM focus is held elsewhere. */
295
- this.active = signal(false, ...(ngDevMode ? [{ debugName: "active" }] : []));
289
+ this.active = signal(false, ...(ngDevMode ? [{ debugName: "active" }] : /* istanbul ignore next */ []));
296
290
  /** Whether the dropdown item acts as a trigger for a nested dropdown. */
297
291
  this.isNested = false;
298
292
  /** @docs-private */
299
293
  this.componentColors = KbqComponentColors;
294
+ /**
295
+ * Whether the progress shimmer stands still.
296
+ *
297
+ * @docs-private
298
+ */
299
+ this.animationsDisabled = kbqAnimationsDisabled();
300
300
  effect(() => {
301
301
  // Start monitoring the element so it gets the appropriate focused classes. We want to
302
302
  // show the focus style for menu items only when the focus was not caused by a mouse or
@@ -334,7 +334,13 @@ class KbqDropdownItem {
334
334
  * the meantime. `preventScroll` is therefore always forced on, overriding `options`.
335
335
  */
336
336
  focus(origin, options) {
337
- if (this.disabled)
337
+ // Untracked: called from a consumer's `effect()`, `disabled` and what the focus listeners read on the way would
338
+ // make the effect run again whenever they change.
339
+ untracked(() => this.focusItem(origin, options));
340
+ }
341
+ /** Body of `focus()`. */
342
+ focusItem(origin, options) {
343
+ if (this.disabled())
338
344
  return;
339
345
  const element = this.getHostElement();
340
346
  const focusOptions = { ...options, preventScroll: true };
@@ -356,11 +362,12 @@ class KbqDropdownItem {
356
362
  }
357
363
  /** Used to set the `tabindex`. */
358
364
  getTabIndex() {
359
- return this.disabled ? '-1' : '0';
365
+ // The attributes' signal rather than `disabled`: the binding runs right after theirs.
366
+ return this.disabledAttribute() ? '-1' : '0';
360
367
  }
361
368
  /** Prevents the default element actions if it is disabled. Bound via `host` metadata. */
362
369
  checkDisabled(event) {
363
- if (this.disabled) {
370
+ if (this.disabled()) {
364
371
  event.preventDefault();
365
372
  event.stopPropagation();
366
373
  }
@@ -373,15 +380,38 @@ class KbqDropdownItem {
373
380
  return;
374
381
  this.focus('mouse');
375
382
  }
383
+ /** Handles key presses on the item. Bound via `host` metadata. */
384
+ handleKeydown(event) {
385
+ if (this.disabled() || this.progress())
386
+ return;
387
+ if (event.keyCode === ENTER || event.keyCode === SPACE) {
388
+ this.handleActivationKeydown(event);
389
+ return;
390
+ }
391
+ this.handleActionKeydown(event);
392
+ }
393
+ /** Replays ENTER/SPACE as a click on a non-interactive host (e.g. a `<div>` item with a secondary action). */
394
+ handleActivationKeydown(event) {
395
+ const hostElement = this.getHostElement();
396
+ // A nested trigger opens its submenu on these keys instead.
397
+ if (this.isNested || event.target !== hostElement)
398
+ return;
399
+ if (hostElement.matches(SELF_ACTIVATING_HOST_SELECTOR))
400
+ return;
401
+ event.preventDefault();
402
+ // SPACE must not also reach the panel's typeahead.
403
+ event.stopPropagation();
404
+ hostElement.click();
405
+ }
376
406
  /**
377
407
  * Lets Tab move focus between the host and `itemAction` without leaving the dropdown
378
408
  * (`stopPropagation` only — the browser's native focus move still happens). Any other Tab
379
409
  * press, i.e. actually leaving the item, is left untouched and still closes the dropdown via
380
- * the panel's `FocusKeyManager.tabOut`. Bound via `host` metadata.
410
+ * the panel's `FocusKeyManager.tabOut`.
381
411
  */
382
412
  handleActionKeydown(event) {
383
413
  const action = this.itemAction();
384
- if (!action || event.keyCode !== TAB || this.disabled || this.progress())
414
+ if (!action || event.keyCode !== TAB)
385
415
  return;
386
416
  const target = event.target;
387
417
  const hostEl = this.getHostElement();
@@ -394,29 +424,41 @@ class KbqDropdownItem {
394
424
  }
395
425
  /** Gets the label to be used when determining whether the option should be focused. */
396
426
  getLabel() {
397
- const clone = this.getHostElement().cloneNode(true);
398
- const stripped = clone.querySelectorAll('[kbq-icon], .kbq-icon, [kbqDropdownItemAction]');
399
- // Strip away icons and the action so they don't show up in the text.
400
- for (let i = 0; i < stripped.length; i++) {
401
- const node = stripped[i];
402
- node.parentNode?.removeChild(node);
403
- }
404
- return clone.textContent?.trim() || '';
427
+ const hostElement = this.getHostElement();
428
+ const text = hostElement.textContent || '';
429
+ // Typeahead reads every label on each keystroke, so the walk is memoised on the raw text.
430
+ if (this.cachedLabel?.text !== text) {
431
+ this.cachedLabel = { text, label: this.readLabel(hostElement).trim() };
432
+ }
433
+ return this.cachedLabel.label;
434
+ }
435
+ /** Concatenates the item's own text, skipping icons and the projected action. */
436
+ readLabel(element) {
437
+ let label = '';
438
+ element.childNodes.forEach((node) => {
439
+ if (node.nodeType === Node.TEXT_NODE) {
440
+ label += node.textContent;
441
+ }
442
+ else if (node.nodeType === Node.ELEMENT_NODE && !node.matches(NON_LABEL_SELECTOR)) {
443
+ label += this.readLabel(node);
444
+ }
445
+ });
446
+ return label;
405
447
  }
406
448
  haltDisabledEvents(event) {
407
- if (this.disabled || this.progress()) {
449
+ if (this.disabled() || this.progress()) {
408
450
  event.preventDefault();
409
451
  event.stopImmediatePropagation();
410
452
  event.stopPropagation();
411
453
  }
412
454
  }
413
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.30", ngImport: i0, type: KbqDropdownItem, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
414
- /** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.30", type: KbqDropdownItem, isStandalone: true, selector: "kbq-dropdown-item, [kbq-dropdown-item]", inputs: { disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: false, isRequired: false, transformFunction: booleanAttribute }, progress: { classPropertyName: "progress", publicName: "progress", isSignal: true, isRequired: false, transformFunction: null } }, host: { listeners: { "click": "checkDisabled($event)", "mouseenter": "handleMouseEnter()", "keydown": "handleActionKeydown($event)" }, properties: { "class.kbq-dropdown-item_with-icon": "icon", "class.kbq-dropdown-item_highlighted": "highlighted", "class.kbq-dropdown-item_active": "active()", "class.kbq-disabled": "disabled", "class.kbq-progress": "progress()", "class.kbq-dropdown-item_has-action": "!!itemAction()", "attr.disabled": "disabled || null", "attr.tabindex": "getTabIndex()" }, classAttribute: "kbq-dropdown-item" }, providers: [
455
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: KbqDropdownItem, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
456
+ /** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.25", type: KbqDropdownItem, isStandalone: true, selector: "kbq-dropdown-item, [kbq-dropdown-item]", inputs: { disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, progress: { classPropertyName: "progress", publicName: "progress", isSignal: true, isRequired: false, transformFunction: null } }, host: { listeners: { "click": "checkDisabled($event)", "mouseenter": "handleMouseEnter()", "keydown": "handleKeydown($event)" }, properties: { "class.kbq-dropdown-item_highlighted": "highlighted", "class.kbq-dropdown-item_active": "active()", "class.kbq-disabled": "disabled()", "class.kbq-progress": "progress()", "class.kbq-dropdown-item_has-action": "!!itemAction()", "attr.disabled": "disabledAttribute()", "attr.aria-disabled": "disabledAttribute()", "attr.tabindex": "getTabIndex()" }, classAttribute: "kbq-dropdown-item" }, providers: [
415
457
  { provide: KBQ_TITLE_TEXT_REF, useExisting: KbqDropdownItem },
416
458
  { provide: KBQ_DROPDOWN_ITEM_ACTION_HOST, useExisting: KbqDropdownItem }
417
- ], queries: [{ propertyName: "itemAction", first: true, predicate: KbqDropdownItemAction, descendants: true, isSignal: true }, { propertyName: "icon", first: true, predicate: KbqIcon, descendants: true }], viewQueries: [{ propertyName: "textElement", first: true, predicate: ["kbqTitleText"], descendants: true }], exportAs: ["kbqDropdownItem"], ngImport: i0, template: "<ng-content select=\"[kbq-icon]\" />\n\n<div #kbqTitleText class=\"kbq-dropdown-item__text\">\n <ng-content />\n</div>\n\n<ng-content select=\"[kbqDropdownItemAction]\" />\n\n@if (isNested) {\n <i kbq-icon=\"kbq-chevron-right-s_16\" class=\"kbq-dropdown-trigger__icon\" [color]=\"componentColors.ContrastFade\"></i>\n}\n\n<div class=\"kbq-dropdown-item-overlay\" (click)=\"haltDisabledEvents($event)\"></div>\n", styles: ["@keyframes kbq-progress{0%{background-position:0 0}to{background-position:64px 0}}.kbq-progress{position:relative}.kbq-progress:after{content:\"\";position:absolute;border-radius:inherit;inset:0;background:linear-gradient(135deg,#0000000a 12px,#ffffff1a 12px 22px,#0000000a 22px 34px,#ffffff1a 34px) repeat;background-size:32px 32px;animation:kbq-progress 1s linear infinite}@media(prefers-reduced-motion:reduce){.kbq-progress:after{animation:none}}.kbq-truncate-line{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.kbq-no-select{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.kbq-dropdown-item{width:100%;border-radius:var(--kbq-dropdown-item-border-radius);-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;position:relative;display:flex;flex-direction:row;align-items:center;box-sizing:border-box;outline:none;-webkit-tap-highlight-color:transparent;min-height:32px;gap:var(--kbq-size-s);border:var(--kbq-size-3xs) solid transparent;padding:var(--kbq-size-xxs) calc(var(--kbq-size-m) - var(--kbq-size-3xs))}.kbq-dropdown-item .kbq-list-text>*{margin:0;padding:0;font-weight:400;font-size:inherit}.kbq-dropdown-item .kbq-list-text{display:flex;flex-direction:column;width:100%;box-sizing:content-box;overflow:hidden}.kbq-dropdown-item .kbq-list-text:empty{display:none}.kbq-dropdown-item .kbq-list-text{display:inline-block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.kbq-dropdown-item .kbq-list-option-caption{padding-top:var(--kbq-size-3xs)}.kbq-dropdown-item:not(.kbq-disabled){cursor:pointer}.kbq-dropdown-item{text-align:left;align-items:flex-start;text-decoration:none}.kbq-dropdown-item>.kbq-icon:first-child:before,.kbq-dropdown-item>.kbq-icon:first-child>svg{align-self:center;display:flex;height:var(--kbq-size-xl);width:16px;align-items:center}.kbq-dropdown-item .kbq-dropdown-item__caption{padding-top:var(--kbq-size-3xs)}.kbq-dropdown-item__text>*{margin:0;padding:0;font-weight:400;font-size:inherit}.kbq-dropdown-item__text{display:flex;flex-direction:column;width:100%;box-sizing:content-box;overflow:hidden}.kbq-dropdown-item__text:empty{display:none}.kbq-dropdown-item__text{display:inline-block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.kbq-dropdown-item-overlay{position:absolute;inset:-1px;border-radius:inherit}.kbq-dropdown-item_has-action{align-items:center}.kbq-dropdown-item_has-action>.kbq-dropdown-item__action{position:relative;z-index:1;flex:0 0 auto}.kbq-dropdown-item.kbq-progress .kbq-dropdown-item-overlay{content:\"\";position:absolute;border-radius:inherit;inset:0;background:linear-gradient(135deg,#0000000a 12px,#ffffff1a 12px 22px,#0000000a 22px 34px,#ffffff1a 34px) repeat;background-size:32px 32px;animation:kbq-progress 1s linear infinite;inset:calc(-1 * var(--kbq-size-3xs))}@media(prefers-reduced-motion:reduce){.kbq-dropdown-item.kbq-progress .kbq-dropdown-item-overlay{animation:none}}.kbq-dropdown__group-header{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;display:flex;flex-direction:row;align-items:center;box-sizing:border-box;min-height:32px;border-left:var(--kbq-size-3xs) solid transparent;border-right:var(--kbq-size-3xs) solid transparent;padding-top:var(--kbq-size-xs);padding-left:calc(var(--kbq-size-m) - var(--kbq-size-3xs));padding-right:calc(var(--kbq-size-m) - var(--kbq-size-3xs));padding-bottom:var(--kbq-size-3xs)}.kbq-dropdown__group-header .kbq-list-text>*{margin:0;padding:0;font-weight:400;font-size:inherit}.kbq-dropdown__group-header .kbq-list-text{display:flex;flex-direction:column;width:100%;box-sizing:content-box;overflow:hidden}.kbq-dropdown__group-header .kbq-list-text:empty{display:none}.kbq-dropdown__group-header .kbq-list-text{display:inline-block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.kbq-dropdown__group-header.kbq-dropdown__group-header_small{display:flex;flex-direction:row;align-items:center;box-sizing:border-box;min-height:32px;border-left:var(--kbq-size-3xs) solid transparent;border-right:var(--kbq-size-3xs) solid transparent;padding-top:var(--kbq-size-m);padding-left:calc(var(--kbq-size-m) - var(--kbq-size-3xs));padding-right:calc(var(--kbq-size-m) - var(--kbq-size-3xs));padding-bottom:var(--kbq-size-xxs)}.kbq-dropdown__group-header.kbq-dropdown__group-header_small .kbq-list-text>*{margin:0;padding:0;font-weight:400;font-size:inherit}.kbq-dropdown__group-header.kbq-dropdown__group-header_small .kbq-list-text{display:flex;flex-direction:column;width:100%;box-sizing:content-box;overflow:hidden}.kbq-dropdown__group-header.kbq-dropdown__group-header_small .kbq-list-text:empty{display:none}.kbq-dropdown__group-header.kbq-dropdown__group-header_small .kbq-list-text{display:inline-block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}\n"], dependencies: [{ kind: "component", type: KbqIcon, selector: "[kbq-icon]", inputs: ["small", "autoColor", "kbq-icon"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
459
+ ], queries: [{ propertyName: "icon", first: true, predicate: KbqIcon, descendants: true, isSignal: true }, { propertyName: "itemAction", first: true, predicate: KbqDropdownItemAction, descendants: true, isSignal: true }], viewQueries: [{ propertyName: "textElementQuery", first: true, predicate: ["kbqTitleText"], descendants: true, isSignal: true }], exportAs: ["kbqDropdownItem"], ngImport: i0, template: "<ng-content select=\"[kbq-icon]\" />\n\n<div #kbqTitleText class=\"kbq-dropdown-item__text\">\n <ng-content />\n</div>\n\n<ng-content select=\"[kbqDropdownItemAction]\" />\n\n@if (isNested) {\n <i kbq-icon=\"kbq-chevron-right-s_16\" class=\"kbq-dropdown-trigger__icon\" [color]=\"componentColors.ContrastFade\"></i>\n}\n\n<div\n class=\"kbq-dropdown-item-overlay\"\n [class.kbq-animations-disabled]=\"animationsDisabled\"\n (click)=\"haltDisabledEvents($event)\"\n></div>\n", styles: ["@charset \"UTF-8\";.kbq-truncate-line{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.kbq-dropdown-item{width:100%;border-radius:var(--kbq-dropdown-item-border-radius)}@supports (corner-shape: squircle){.kbq-dropdown-item{corner-shape:squircle;border-radius:clamp(var(--kbq-dropdown-item-border-radius) * 1.85,var(--kbq-dropdown-item-border-radius) * 2.3 - 3.6px,var(--kbq-dropdown-item-border-radius) * 2)}}.kbq-dropdown-item{-webkit-user-select:none;user-select:none;position:relative;display:flex;flex-direction:row;align-items:center;box-sizing:border-box;outline:none;-webkit-tap-highlight-color:transparent;min-height:32px;gap:var(--kbq-size-s);border:var(--kbq-size-3xs) solid transparent;padding:var(--kbq-size-xxs) calc(var(--kbq-size-m) - var(--kbq-size-3xs))}.kbq-dropdown-item .kbq-list-text>*{margin:0;padding:0;font-weight:400;font-size:inherit}.kbq-dropdown-item .kbq-list-text{display:flex;flex-direction:column;width:100%;box-sizing:content-box;overflow:hidden}.kbq-dropdown-item .kbq-list-text:empty{display:none}.kbq-dropdown-item .kbq-list-text{display:inline-block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.kbq-dropdown-item .kbq-list-option-caption{padding-top:var(--kbq-size-3xs)}.kbq-dropdown-item:not(.kbq-disabled){cursor:pointer}.kbq-dropdown-item{text-align:left;align-items:flex-start;text-decoration:none}.kbq-dropdown-item>.kbq-icon:first-child:before,.kbq-dropdown-item>.kbq-icon:first-child>svg{align-self:center;display:flex;height:var(--kbq-size-xl);width:16px;align-items:center}.kbq-dropdown-item .kbq-dropdown-item__caption{padding-top:var(--kbq-size-3xs)}.kbq-dropdown-item__text>*{margin:0;padding:0;font-weight:400;font-size:inherit}.kbq-dropdown-item__text{display:flex;flex-direction:column;width:100%;box-sizing:content-box;overflow:hidden}.kbq-dropdown-item__text:empty{display:none}.kbq-dropdown-item__text{display:inline-block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.kbq-dropdown-item-overlay{position:absolute;inset:-1px;border-radius:inherit;corner-shape:inherit}.kbq-dropdown-item_has-action{align-items:center}.kbq-dropdown-item_has-action>.kbq-dropdown-item__action{position:relative;z-index:1;flex:0 0 auto}.kbq-dropdown-item.kbq-progress .kbq-dropdown-item-overlay{content:\"\";position:absolute;border-radius:inherit;corner-shape:inherit;inset:0;background:linear-gradient(135deg,#0000000a 12px,#ffffff1a 12px 22px,#0000000a 22px 34px,#ffffff1a 34px) repeat;background-size:32px 32px;animation:kbq-progress 1s linear infinite;inset:calc(-1 * var(--kbq-size-3xs))}.kbq-dropdown-item.kbq-progress .kbq-dropdown-item-overlay.kbq-animations-disabled{animation:none;transition:none}@media(prefers-reduced-motion:reduce){.kbq-dropdown-item.kbq-progress .kbq-dropdown-item-overlay{animation:none;transition:none}}.kbq-dropdown__group-header{-webkit-user-select:none;user-select:none;display:flex;flex-direction:row;align-items:center;box-sizing:border-box;min-height:32px;border-left:var(--kbq-size-3xs) solid transparent;border-right:var(--kbq-size-3xs) solid transparent;padding-top:var(--kbq-size-xs);padding-left:calc(var(--kbq-size-m) - var(--kbq-size-3xs));padding-right:calc(var(--kbq-size-m) - var(--kbq-size-3xs));padding-bottom:var(--kbq-size-3xs)}.kbq-dropdown__group-header .kbq-list-text>*{margin:0;padding:0;font-weight:400;font-size:inherit}.kbq-dropdown__group-header .kbq-list-text{display:flex;flex-direction:column;width:100%;box-sizing:content-box;overflow:hidden}.kbq-dropdown__group-header .kbq-list-text:empty{display:none}.kbq-dropdown__group-header .kbq-list-text{display:inline-block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}\n"], dependencies: [{ kind: "component", type: KbqIcon, selector: "[kbq-icon]", inputs: ["aria-hidden", "iconSize", "autoColor", "kbq-icon"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
418
460
  }
419
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.30", ngImport: i0, type: KbqDropdownItem, decorators: [{
461
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: KbqDropdownItem, decorators: [{
420
462
  type: Component,
421
463
  args: [{ selector: 'kbq-dropdown-item, [kbq-dropdown-item]', imports: [
422
464
  KbqIcon
@@ -425,28 +467,24 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.30", ngImpo
425
467
  { provide: KBQ_DROPDOWN_ITEM_ACTION_HOST, useExisting: KbqDropdownItem }
426
468
  ], changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, host: {
427
469
  class: 'kbq-dropdown-item',
428
- '[class.kbq-dropdown-item_with-icon]': 'icon',
470
+ // Only the class reads `disabled`, and the three attributes, which run back to back before every class
471
+ // binding, read `disabledAttribute`: the host bindings of every item in a view run in that view's reactive
472
+ // consumer, where a signal read again after others costs a scan of all it has read so far. A signal read twice
473
+ // in a row costs none.
429
474
  '[class.kbq-dropdown-item_highlighted]': 'highlighted',
430
475
  '[class.kbq-dropdown-item_active]': 'active()',
431
- '[class.kbq-disabled]': 'disabled',
476
+ '[class.kbq-disabled]': 'disabled()',
432
477
  '[class.kbq-progress]': 'progress()',
433
478
  '[class.kbq-dropdown-item_has-action]': '!!itemAction()',
434
- '[attr.disabled]': 'disabled || null',
479
+ '[attr.disabled]': 'disabledAttribute()',
480
+ // `disabled` is inert on `<div>`/`<a>` hosts.
481
+ '[attr.aria-disabled]': 'disabledAttribute()',
435
482
  '[attr.tabindex]': 'getTabIndex()',
436
483
  '(click)': 'checkDisabled($event)',
437
484
  '(mouseenter)': 'handleMouseEnter()',
438
- '(keydown)': 'handleActionKeydown($event)'
439
- }, exportAs: 'kbqDropdownItem', template: "<ng-content select=\"[kbq-icon]\" />\n\n<div #kbqTitleText class=\"kbq-dropdown-item__text\">\n <ng-content />\n</div>\n\n<ng-content select=\"[kbqDropdownItemAction]\" />\n\n@if (isNested) {\n <i kbq-icon=\"kbq-chevron-right-s_16\" class=\"kbq-dropdown-trigger__icon\" [color]=\"componentColors.ContrastFade\"></i>\n}\n\n<div class=\"kbq-dropdown-item-overlay\" (click)=\"haltDisabledEvents($event)\"></div>\n", styles: ["@keyframes kbq-progress{0%{background-position:0 0}to{background-position:64px 0}}.kbq-progress{position:relative}.kbq-progress:after{content:\"\";position:absolute;border-radius:inherit;inset:0;background:linear-gradient(135deg,#0000000a 12px,#ffffff1a 12px 22px,#0000000a 22px 34px,#ffffff1a 34px) repeat;background-size:32px 32px;animation:kbq-progress 1s linear infinite}@media(prefers-reduced-motion:reduce){.kbq-progress:after{animation:none}}.kbq-truncate-line{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.kbq-no-select{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.kbq-dropdown-item{width:100%;border-radius:var(--kbq-dropdown-item-border-radius);-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;position:relative;display:flex;flex-direction:row;align-items:center;box-sizing:border-box;outline:none;-webkit-tap-highlight-color:transparent;min-height:32px;gap:var(--kbq-size-s);border:var(--kbq-size-3xs) solid transparent;padding:var(--kbq-size-xxs) calc(var(--kbq-size-m) - var(--kbq-size-3xs))}.kbq-dropdown-item .kbq-list-text>*{margin:0;padding:0;font-weight:400;font-size:inherit}.kbq-dropdown-item .kbq-list-text{display:flex;flex-direction:column;width:100%;box-sizing:content-box;overflow:hidden}.kbq-dropdown-item .kbq-list-text:empty{display:none}.kbq-dropdown-item .kbq-list-text{display:inline-block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.kbq-dropdown-item .kbq-list-option-caption{padding-top:var(--kbq-size-3xs)}.kbq-dropdown-item:not(.kbq-disabled){cursor:pointer}.kbq-dropdown-item{text-align:left;align-items:flex-start;text-decoration:none}.kbq-dropdown-item>.kbq-icon:first-child:before,.kbq-dropdown-item>.kbq-icon:first-child>svg{align-self:center;display:flex;height:var(--kbq-size-xl);width:16px;align-items:center}.kbq-dropdown-item .kbq-dropdown-item__caption{padding-top:var(--kbq-size-3xs)}.kbq-dropdown-item__text>*{margin:0;padding:0;font-weight:400;font-size:inherit}.kbq-dropdown-item__text{display:flex;flex-direction:column;width:100%;box-sizing:content-box;overflow:hidden}.kbq-dropdown-item__text:empty{display:none}.kbq-dropdown-item__text{display:inline-block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.kbq-dropdown-item-overlay{position:absolute;inset:-1px;border-radius:inherit}.kbq-dropdown-item_has-action{align-items:center}.kbq-dropdown-item_has-action>.kbq-dropdown-item__action{position:relative;z-index:1;flex:0 0 auto}.kbq-dropdown-item.kbq-progress .kbq-dropdown-item-overlay{content:\"\";position:absolute;border-radius:inherit;inset:0;background:linear-gradient(135deg,#0000000a 12px,#ffffff1a 12px 22px,#0000000a 22px 34px,#ffffff1a 34px) repeat;background-size:32px 32px;animation:kbq-progress 1s linear infinite;inset:calc(-1 * var(--kbq-size-3xs))}@media(prefers-reduced-motion:reduce){.kbq-dropdown-item.kbq-progress .kbq-dropdown-item-overlay{animation:none}}.kbq-dropdown__group-header{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;display:flex;flex-direction:row;align-items:center;box-sizing:border-box;min-height:32px;border-left:var(--kbq-size-3xs) solid transparent;border-right:var(--kbq-size-3xs) solid transparent;padding-top:var(--kbq-size-xs);padding-left:calc(var(--kbq-size-m) - var(--kbq-size-3xs));padding-right:calc(var(--kbq-size-m) - var(--kbq-size-3xs));padding-bottom:var(--kbq-size-3xs)}.kbq-dropdown__group-header .kbq-list-text>*{margin:0;padding:0;font-weight:400;font-size:inherit}.kbq-dropdown__group-header .kbq-list-text{display:flex;flex-direction:column;width:100%;box-sizing:content-box;overflow:hidden}.kbq-dropdown__group-header .kbq-list-text:empty{display:none}.kbq-dropdown__group-header .kbq-list-text{display:inline-block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.kbq-dropdown__group-header.kbq-dropdown__group-header_small{display:flex;flex-direction:row;align-items:center;box-sizing:border-box;min-height:32px;border-left:var(--kbq-size-3xs) solid transparent;border-right:var(--kbq-size-3xs) solid transparent;padding-top:var(--kbq-size-m);padding-left:calc(var(--kbq-size-m) - var(--kbq-size-3xs));padding-right:calc(var(--kbq-size-m) - var(--kbq-size-3xs));padding-bottom:var(--kbq-size-xxs)}.kbq-dropdown__group-header.kbq-dropdown__group-header_small .kbq-list-text>*{margin:0;padding:0;font-weight:400;font-size:inherit}.kbq-dropdown__group-header.kbq-dropdown__group-header_small .kbq-list-text{display:flex;flex-direction:column;width:100%;box-sizing:content-box;overflow:hidden}.kbq-dropdown__group-header.kbq-dropdown__group-header_small .kbq-list-text:empty{display:none}.kbq-dropdown__group-header.kbq-dropdown__group-header_small .kbq-list-text{display:inline-block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}\n"] }]
440
- }], ctorParameters: () => [], propDecorators: { textElement: [{
441
- type: ViewChild,
442
- args: ['kbqTitleText']
443
- }], icon: [{
444
- type: ContentChild,
445
- args: [KbqIcon]
446
- }], itemAction: [{ type: i0.ContentChild, args: [i0.forwardRef(() => KbqDropdownItemAction), { isSignal: true }] }], disabled: [{
447
- type: Input,
448
- args: [{ transform: booleanAttribute }]
449
- }], progress: [{ type: i0.Input, args: [{ isSignal: true, alias: "progress", required: false }] }] } });
485
+ '(keydown)': 'handleKeydown($event)'
486
+ }, exportAs: 'kbqDropdownItem', template: "<ng-content select=\"[kbq-icon]\" />\n\n<div #kbqTitleText class=\"kbq-dropdown-item__text\">\n <ng-content />\n</div>\n\n<ng-content select=\"[kbqDropdownItemAction]\" />\n\n@if (isNested) {\n <i kbq-icon=\"kbq-chevron-right-s_16\" class=\"kbq-dropdown-trigger__icon\" [color]=\"componentColors.ContrastFade\"></i>\n}\n\n<div\n class=\"kbq-dropdown-item-overlay\"\n [class.kbq-animations-disabled]=\"animationsDisabled\"\n (click)=\"haltDisabledEvents($event)\"\n></div>\n", styles: ["@charset \"UTF-8\";.kbq-truncate-line{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.kbq-dropdown-item{width:100%;border-radius:var(--kbq-dropdown-item-border-radius)}@supports (corner-shape: squircle){.kbq-dropdown-item{corner-shape:squircle;border-radius:clamp(var(--kbq-dropdown-item-border-radius) * 1.85,var(--kbq-dropdown-item-border-radius) * 2.3 - 3.6px,var(--kbq-dropdown-item-border-radius) * 2)}}.kbq-dropdown-item{-webkit-user-select:none;user-select:none;position:relative;display:flex;flex-direction:row;align-items:center;box-sizing:border-box;outline:none;-webkit-tap-highlight-color:transparent;min-height:32px;gap:var(--kbq-size-s);border:var(--kbq-size-3xs) solid transparent;padding:var(--kbq-size-xxs) calc(var(--kbq-size-m) - var(--kbq-size-3xs))}.kbq-dropdown-item .kbq-list-text>*{margin:0;padding:0;font-weight:400;font-size:inherit}.kbq-dropdown-item .kbq-list-text{display:flex;flex-direction:column;width:100%;box-sizing:content-box;overflow:hidden}.kbq-dropdown-item .kbq-list-text:empty{display:none}.kbq-dropdown-item .kbq-list-text{display:inline-block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.kbq-dropdown-item .kbq-list-option-caption{padding-top:var(--kbq-size-3xs)}.kbq-dropdown-item:not(.kbq-disabled){cursor:pointer}.kbq-dropdown-item{text-align:left;align-items:flex-start;text-decoration:none}.kbq-dropdown-item>.kbq-icon:first-child:before,.kbq-dropdown-item>.kbq-icon:first-child>svg{align-self:center;display:flex;height:var(--kbq-size-xl);width:16px;align-items:center}.kbq-dropdown-item .kbq-dropdown-item__caption{padding-top:var(--kbq-size-3xs)}.kbq-dropdown-item__text>*{margin:0;padding:0;font-weight:400;font-size:inherit}.kbq-dropdown-item__text{display:flex;flex-direction:column;width:100%;box-sizing:content-box;overflow:hidden}.kbq-dropdown-item__text:empty{display:none}.kbq-dropdown-item__text{display:inline-block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.kbq-dropdown-item-overlay{position:absolute;inset:-1px;border-radius:inherit;corner-shape:inherit}.kbq-dropdown-item_has-action{align-items:center}.kbq-dropdown-item_has-action>.kbq-dropdown-item__action{position:relative;z-index:1;flex:0 0 auto}.kbq-dropdown-item.kbq-progress .kbq-dropdown-item-overlay{content:\"\";position:absolute;border-radius:inherit;corner-shape:inherit;inset:0;background:linear-gradient(135deg,#0000000a 12px,#ffffff1a 12px 22px,#0000000a 22px 34px,#ffffff1a 34px) repeat;background-size:32px 32px;animation:kbq-progress 1s linear infinite;inset:calc(-1 * var(--kbq-size-3xs))}.kbq-dropdown-item.kbq-progress .kbq-dropdown-item-overlay.kbq-animations-disabled{animation:none;transition:none}@media(prefers-reduced-motion:reduce){.kbq-dropdown-item.kbq-progress .kbq-dropdown-item-overlay{animation:none;transition:none}}.kbq-dropdown__group-header{-webkit-user-select:none;user-select:none;display:flex;flex-direction:row;align-items:center;box-sizing:border-box;min-height:32px;border-left:var(--kbq-size-3xs) solid transparent;border-right:var(--kbq-size-3xs) solid transparent;padding-top:var(--kbq-size-xs);padding-left:calc(var(--kbq-size-m) - var(--kbq-size-3xs));padding-right:calc(var(--kbq-size-m) - var(--kbq-size-3xs));padding-bottom:var(--kbq-size-3xs)}.kbq-dropdown__group-header .kbq-list-text>*{margin:0;padding:0;font-weight:400;font-size:inherit}.kbq-dropdown__group-header .kbq-list-text{display:flex;flex-direction:column;width:100%;box-sizing:content-box;overflow:hidden}.kbq-dropdown__group-header .kbq-list-text:empty{display:none}.kbq-dropdown__group-header .kbq-list-text{display:inline-block;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}\n"] }]
487
+ }], ctorParameters: () => [], propDecorators: { textElementQuery: [{ type: i0.ViewChild, args: ['kbqTitleText', { isSignal: true }] }], icon: [{ type: i0.ContentChild, args: [i0.forwardRef(() => KbqIcon), { isSignal: true }] }], itemAction: [{ type: i0.ContentChild, args: [i0.forwardRef(() => KbqDropdownItemAction), { isSignal: true }] }], disabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }], progress: [{ type: i0.Input, args: [{ isSignal: true, alias: "progress", required: false }] }] } });
450
488
 
451
489
  /**
452
490
  * Marks a `kbq-form-field` projected into a `kbq-dropdown` as the panel's search field.
@@ -460,6 +498,7 @@ class KbqDropdownSearch {
460
498
  /**
461
499
  * Panel this field searches. A nested panel declared inside its parent's content shares the view with
462
500
  * it, so the parent has to be able to tell which of the projected fields is its own.
501
+ *
463
502
  * @docs-private
464
503
  */
465
504
  this.panel = inject(KBQ_DROPDOWN_PANEL, { optional: true });
@@ -486,7 +525,7 @@ class KbqDropdownSearch {
486
525
  }
487
526
  /** The current search query. */
488
527
  value() {
489
- return this.formField.control().value;
528
+ return this.formField.control().value();
490
529
  }
491
530
  /** @docs-private */
492
531
  handleClick(event) {
@@ -520,8 +559,8 @@ class KbqDropdownSearch {
520
559
  const edge = keyCode === LEFT_ARROW ? 0 : value.length;
521
560
  return selectionStart !== edge || selectionEnd !== edge;
522
561
  }
523
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.30", ngImport: i0, type: KbqDropdownSearch, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
524
- /** @nocollapse */ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "20.3.30", type: KbqDropdownSearch, isStandalone: true, selector: "[kbqDropdownSearch]", host: { listeners: { "click": "handleClick($event)", "keydown": "handleKeydown($event)" } }, providers: [
562
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: KbqDropdownSearch, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
563
+ /** @nocollapse */ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.25", type: KbqDropdownSearch, isStandalone: true, selector: "[kbqDropdownSearch]", host: { listeners: { "click": "handleClick($event)", "keydown": "handleKeydown($event)" } }, providers: [
525
564
  {
526
565
  // Merged, not replaced: the field still inherits whatever defaults the app configures.
527
566
  provide: KBQ_FORM_FIELD_DEFAULT_OPTIONS,
@@ -533,7 +572,7 @@ class KbqDropdownSearch {
533
572
  }
534
573
  ], exportAs: ["kbqDropdownSearch"], ngImport: i0 }); }
535
574
  }
536
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.30", ngImport: i0, type: KbqDropdownSearch, decorators: [{
575
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: KbqDropdownSearch, decorators: [{
537
576
  type: Directive,
538
577
  args: [{
539
578
  selector: '[kbqDropdownSearch]',
@@ -567,10 +606,10 @@ const NESTED_HOVER_SWITCH_DELAY = 50;
567
606
  /** Class applied to the panel while its safe area is protecting an open submenu, see `activateSafeArea`. */
568
607
  const SAFE_AREA_ACTIVE_CLASS = 'kbq-dropdown__panel_safe-area-active';
569
608
  class KbqDropdownStaticContent {
570
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.30", ngImport: i0, type: KbqDropdownStaticContent, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
571
- /** @nocollapse */ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "20.3.30", type: KbqDropdownStaticContent, isStandalone: true, selector: "[kbqDropdownStaticContent]", ngImport: i0 }); }
609
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: KbqDropdownStaticContent, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
610
+ /** @nocollapse */ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.25", type: KbqDropdownStaticContent, isStandalone: true, selector: "[kbqDropdownStaticContent]", ngImport: i0 }); }
572
611
  }
573
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.30", ngImport: i0, type: KbqDropdownStaticContent, decorators: [{
612
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: KbqDropdownStaticContent, decorators: [{
574
613
  type: Directive,
575
614
  args: [{
576
615
  selector: '[kbqDropdownStaticContent]'
@@ -578,163 +617,160 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.30", ngImpo
578
617
  }] });
579
618
  /** Footer that is rendered below the dropdown options panel. */
580
619
  class KbqDropdownFooter {
581
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.30", ngImport: i0, type: KbqDropdownFooter, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
582
- /** @nocollapse */ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "20.3.30", type: KbqDropdownFooter, isStandalone: true, selector: "[kbqDropdownFooter], kbq-dropdown-footer", host: { classAttribute: "kbq-dropdown-footer" }, ngImport: i0 }); }
620
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: KbqDropdownFooter, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
621
+ /** @nocollapse */ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.25", type: KbqDropdownFooter, isStandalone: true, selector: "[kbqDropdownFooter], kbq-dropdown-footer", host: { classAttribute: "kbq-dropdown-footer" }, ngImport: i0 }); }
583
622
  }
584
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.30", ngImport: i0, type: KbqDropdownFooter, decorators: [{
623
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: KbqDropdownFooter, decorators: [{
585
624
  type: Directive,
586
625
  args: [{
587
626
  selector: '[kbqDropdownFooter], kbq-dropdown-footer',
588
627
  host: { class: 'kbq-dropdown-footer' }
589
628
  }]
590
629
  }] });
630
+ /** Header of a group of items in the dropdown panel. */
631
+ class KbqDropdownGroupHeader {
632
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: KbqDropdownGroupHeader, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
633
+ /** @nocollapse */ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.25", type: KbqDropdownGroupHeader, isStandalone: true, selector: "[kbqDropdownGroupHeader]", host: { classAttribute: "kbq-dropdown__group-header" }, ngImport: i0 }); }
634
+ }
635
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: KbqDropdownGroupHeader, decorators: [{
636
+ type: Directive,
637
+ args: [{
638
+ selector: '[kbqDropdownGroupHeader]',
639
+ host: { class: 'kbq-dropdown__group-header' }
640
+ }]
641
+ }] });
591
642
  class KbqDropdown {
592
- /** Position of the dropdown in the X axis. */
593
- // TODO: Skipped for migration because:
594
- // Accessor inputs cannot be migrated as they are too complex.
595
- get xPosition() {
596
- return this._xPosition;
597
- }
598
- set xPosition(value) {
599
- if (value !== 'before' && value !== 'after' && value !== 'center') {
600
- throwKbqDropdownInvalidPositionX();
601
- }
602
- this._xPosition = value;
603
- this.setPositionClasses();
604
- }
605
- /** Position of the dropdown in the Y axis. */
606
- // TODO: Skipped for migration because:
607
- // Accessor inputs cannot be migrated as they are too complex.
608
- get yPosition() {
609
- return this._yPosition;
610
- }
611
- set yPosition(value) {
612
- if (value !== 'above' && value !== 'below') {
613
- throwKbqDropdownInvalidPositionY();
614
- }
615
- this._yPosition = value;
616
- this.setPositionClasses();
617
- }
618
- /** Whether the dropdown should overlap its trigger vertically. */
619
- // TODO: Skipped for migration because:
620
- // Accessor inputs cannot be migrated as they are too complex.
621
- get overlapTriggerY() {
622
- return this._overlapTriggerY;
623
- }
624
- set overlapTriggerY(value) {
625
- this._overlapTriggerY = coerceBooleanProperty(value);
626
- }
627
- /** Whether the dropdown should overlap its trigger horizontally. */
628
- // TODO: Skipped for migration because:
629
- // Accessor inputs cannot be migrated as they are too complex.
630
- get overlapTriggerX() {
631
- return this._overlapTriggerX;
632
- }
633
- set overlapTriggerX(value) {
634
- this._overlapTriggerX = coerceBooleanProperty(value);
635
- }
636
- /** Whether the dropdown has a backdrop. */
637
- // TODO: Skipped for migration because:
638
- // Accessor inputs cannot be migrated as they are too complex.
639
- get hasBackdrop() {
640
- return this._hasBackdrop;
641
- }
642
- set hasBackdrop(value) {
643
- this._hasBackdrop = coerceBooleanProperty(value);
644
- }
645
- /**
646
- * This method takes classes set on the host kbq-dropdown element and applies them on the
647
- * dropdown template that displays in the overlay container. Otherwise, it's difficult
648
- * to style the containing dropdown from outside the component.
649
- * @param classes list of class names
650
- */
651
- // TODO: Skipped for migration because:
652
- // Accessor inputs cannot be migrated as they are too complex.
653
- set panelClass(classes) {
654
- const previousPanelClass = this.previousPanelClass;
655
- const classList = { ...this.classList };
656
- if (previousPanelClass && previousPanelClass.length) {
657
- previousPanelClass.split(' ').forEach((className) => (classList[className] = false));
658
- }
659
- this.previousPanelClass = classes;
660
- if (classes?.length) {
661
- classes.split(' ').forEach((className) => (classList[className] = true));
662
- this.elementRef.nativeElement.className = '';
663
- }
664
- // Reassign a new object reference so the native `[class]` binding picks up the change.
665
- this.classList = classList;
666
- }
667
643
  constructor() {
668
644
  this.elementRef = inject(ElementRef);
669
645
  this.ngZone = inject(NgZone);
646
+ this.injector = inject(Injector);
647
+ /** The pending deferred initial focus, see `focusFirstItem`. */
648
+ this.initialFocusRef = null;
670
649
  this.document = inject(DOCUMENT);
650
+ this.renderer = inject(Renderer2);
671
651
  this.defaultOptions = inject(KBQ_DROPDOWN_DEFAULT_OPTIONS);
672
652
  this.destroyRef = inject(DestroyRef);
673
- this.panelFormField = contentChild(KbqFormField, ...(ngDevMode ? [{ debugName: "panelFormField" }] : []));
653
+ this.panelFormField = contentChild(KbqFormField, ...(ngDevMode ? [{ debugName: "panelFormField" }] : /* istanbul ignore next */ []));
674
654
  /**
675
655
  * Signal content queries carry `descendants: true`, and a nested panel declared inside this one's
676
656
  * content is part of the same view — so the match has to be narrowed to the fields this panel owns,
677
- * the way `updateDirectDescendants` narrows the items.
657
+ * the way `syncDirectDescendants` narrows the items.
678
658
  */
679
- this.searches = contentChildren(KbqDropdownSearch, ...(ngDevMode ? [{ debugName: "searches", descendants: true }] : [{ descendants: true }]));
680
- this.search = computed(() => this.searches().find((search) => search.panel === this), ...(ngDevMode ? [{ debugName: "search" }] : []));
659
+ this.searches = contentChildren(KbqDropdownSearch, { ...(ngDevMode ? { debugName: "searches" } : /* istanbul ignore next */ {}), descendants: true });
660
+ this.search = computed(() => this.searches().find((search) => search.panel === this), ...(ngDevMode ? [{ debugName: "search" }] : /* istanbul ignore next */ []));
681
661
  /** Whether the dropdown projects a search form-field. @docs-private */
682
- this.hasSearch = computed(() => !!this.panelFormField(), ...(ngDevMode ? [{ debugName: "hasSearch" }] : []));
662
+ this.hasSearch = computed(() => !!this.panelFormField(), ...(ngDevMode ? [{ debugName: "hasSearch" }] : /* istanbul ignore next */ []));
663
+ /**
664
+ * Whether the arrow keys move a highlight instead of the DOM focus. Turn it on when the keyboard belongs to
665
+ * something outside the panel — an editor whose caret the panel is anchored to, for instance — and forward
666
+ * the keys with {@link handleKeydown}.
667
+ */
668
+ this.activeDescendantNavigation = input(false, { ...(ngDevMode ? { debugName: "activeDescendantNavigation" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
683
669
  /** Whether the panel highlights the active item instead of focusing it. @docs-private */
684
- this.inSearchMode = computed(() => !!this.search(), ...(ngDevMode ? [{ debugName: "inSearchMode" }] : []));
685
- this.navigationWithWrap = input(false, ...(ngDevMode ? [{ debugName: "navigationWithWrap" }] : []));
686
- this._xPosition = this.defaultOptions.xPosition;
687
- this._yPosition = this.defaultOptions.yPosition;
688
- this._overlapTriggerX = this.defaultOptions.overlapTriggerX;
689
- this._overlapTriggerY = this.defaultOptions.overlapTriggerY;
690
- this._hasBackdrop = this.defaultOptions.hasBackdrop;
691
- /** Config object to be passed into the dropdown panel's `[class]` binding */
692
- this.classList = {};
693
- /** Current state of the panel animation. */
694
- this.panelAnimationState = 'void';
695
- /** Emits whenever an animation on the dropdown completes. */
696
- this.animationDone = new Subject();
670
+ this.inSearchMode = computed(() => !!this.search() || this.activeDescendantNavigation(), ...(ngDevMode ? [{ debugName: "inSearchMode" }] : /* istanbul ignore next */ []));
671
+ this.navigationWithWrap = input(false, ...(ngDevMode ? [{ debugName: "navigationWithWrap" }] : /* istanbul ignore next */ []));
672
+ // The position members are `model()`s because `kbq-split-button` and `kbq-navbar-item` write them.
673
+ /** Position of the dropdown in the X axis. */
674
+ this.xPosition = model(this.defaultOptions.xPosition, ...(ngDevMode ? [{ debugName: "xPosition" }] : /* istanbul ignore next */ []));
675
+ /** Position of the dropdown in the Y axis. */
676
+ this.yPosition = model(this.defaultOptions.yPosition, ...(ngDevMode ? [{ debugName: "yPosition" }] : /* istanbul ignore next */ []));
677
+ /** Whether the dropdown should overlap its trigger vertically. */
678
+ this.overlapTriggerY = model(this.defaultOptions.overlapTriggerY, ...(ngDevMode ? [{ debugName: "overlapTriggerY" }] : /* istanbul ignore next */ []));
679
+ /** Whether the dropdown should overlap its trigger horizontally. */
680
+ this.overlapTriggerX = model(this.defaultOptions.overlapTriggerX, ...(ngDevMode ? [{ debugName: "overlapTriggerX" }] : /* istanbul ignore next */ []));
681
+ /** Whether the dropdown has a backdrop. */
682
+ this.hasBackdrop = input(this.defaultOptions.hasBackdrop, { ...(ngDevMode ? { debugName: "hasBackdrop" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
683
+ /** Classes set on the host `kbq-dropdown` element, transferred onto the panel in the overlay container. */
684
+ this.panelClass = input('', { ...(ngDevMode ? { debugName: "panelClass" } : /* istanbul ignore next */ {}), alias: 'class' });
685
+ /** The position the trigger resolved; supersedes the inputs until one of them changes. */
686
+ this.positionOverride = signal(null, ...(ngDevMode ? [{ debugName: "positionOverride" }] : /* istanbul ignore next */ []));
687
+ /** Whether a safe area is protecting an open submenu, see `activateSafeArea`. */
688
+ this.safeAreaActive = signal(false, ...(ngDevMode ? [{ debugName: "safeAreaActive" }] : /* istanbul ignore next */ []));
689
+ /** Config object passed into the dropdown panel's `[class]` binding. */
690
+ this.classList = computed(() => {
691
+ const { posX, posY } = this.positionOverride() ?? { posX: this.xPosition(), posY: this.yPosition() };
692
+ const classes = {
693
+ 'kbq-dropdown-before': posX === 'before',
694
+ 'kbq-dropdown-after': posX === 'after',
695
+ 'kbq-dropdown-center': posX === 'center',
696
+ 'kbq-dropdown-above': posY === 'above',
697
+ 'kbq-dropdown-below': posY === 'below',
698
+ [SAFE_AREA_ACTIVE_CLASS]: this.safeAreaActive()
699
+ };
700
+ for (const className of this.panelClass().split(' ')) {
701
+ if (className)
702
+ classes[className] = true;
703
+ }
704
+ return classes;
705
+ }, ...(ngDevMode ? [{ debugName: "classList" }] : /* istanbul ignore next */ []));
706
+ /** Whether a trigger has the panel attached, see `setOpened`. */
707
+ this.opened = false;
697
708
  /** Class to be added to the backdrop element. */
698
- // TODO: Skipped for migration because:
699
- // This input overrides a field from a superclass, while the superclass field
700
- // is not migrated.
701
- this.backdropClass = this.defaultOptions.backdropClass;
709
+ this.backdropClass = input(this.defaultOptions.backdropClass, ...(ngDevMode ? [{ debugName: "backdropClass" }] : /* istanbul ignore next */ []));
702
710
  /**
703
711
  * Width of the panel. If set to `auto`, the panel will match the trigger width, but will never be
704
712
  * narrower than `panelMinWidth`. If set to null, the panel will grow to match its content.
705
713
  * Any other value is used as an exact width, and `panelMinWidth` is not applied.
706
714
  */
707
- this.panelWidth = input(this.defaultOptions.panelWidth ?? null, ...(ngDevMode ? [{ debugName: "panelWidth" }] : []));
715
+ this.panelWidth = input(this.defaultOptions.panelWidth ?? null, ...(ngDevMode ? [{ debugName: "panelWidth" }] : /* istanbul ignore next */ []));
708
716
  /**
709
717
  * Minimum width of the panel in pixels. The panel is never narrower than this, nor than its trigger.
710
718
  */
711
719
  this.panelMinWidth = input(this.defaultOptions.panelMinWidth === undefined
712
720
  ? KBQ_PANEL_DEFAULT_MIN_WIDTH
713
- : this.defaultOptions.panelMinWidth, ...(ngDevMode ? [{ debugName: "panelMinWidth", transform: numberAttribute }] : [{ transform: numberAttribute }]));
721
+ : this.defaultOptions.panelMinWidth, { ...(ngDevMode ? { debugName: "panelMinWidth" } : /* istanbul ignore next */ {}), transform: numberAttribute });
714
722
  /**
715
723
  * Maximum width of the panel in pixels. Caps how far the panel grows with its content — it never makes
716
724
  * the panel narrower than the trigger, and never clamps an explicit `panelWidth`.
717
725
  * When null, the `--kbq-dropdown-size-container-width-max` token applies.
718
726
  */
719
- this.panelMaxWidth = input(this.defaultOptions.panelMaxWidth === undefined ? null : this.defaultOptions.panelMaxWidth, ...(ngDevMode ? [{ debugName: "panelMaxWidth", transform: numberAttribute }] : [{ transform: numberAttribute }]));
727
+ this.panelMaxWidth = input(this.defaultOptions.panelMaxWidth === undefined ? null : this.defaultOptions.panelMaxWidth, { ...(ngDevMode ? { debugName: "panelMaxWidth" } : /* istanbul ignore next */ {}), transform: numberAttribute });
720
728
  /**
721
729
  * Whether nested dropdowns opened from this dropdown's items use a "safe area": while the
722
730
  * pointer moves from a trigger toward its open submenu, sibling items it crosses over on the way
723
- * don't prematurely close the submenu.
731
+ * don't prematurely close the submenu. Set on the panel that contains the nested triggers.
724
732
  */
725
- this.safeArea = input(this.defaultOptions.safeArea ?? true, ...(ngDevMode ? [{ debugName: "safeArea", transform: booleanAttribute }] : [{ transform: booleanAttribute }]));
733
+ this.safeArea = input(this.defaultOptions.safeArea ?? true, { ...(ngDevMode ? { debugName: "safeArea" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
726
734
  /**
727
- * `panelMinWidth` rendered as a CSS length for the `--kbq-dropdown-size-container-width-min`
728
- * token, so the panel's CSS `min-width` floor tracks the input — mirroring how `panelMaxWidth`
729
- * drives `max-width`. Non-finite input (e.g. `null`) leaves the token's static default in place.
735
+ * `panelMinWidth` as a CSS length for `--kbq-dropdown-size-container-width-min`.
736
+ *
730
737
  * @docs-private
731
738
  */
732
739
  this.panelMinWidthToken = computed(() => {
733
740
  const minWidth = this.panelMinWidth();
734
- return Number.isFinite(minWidth) ? `${minWidth}px` : null;
735
- }, ...(ngDevMode ? [{ debugName: "panelMinWidthToken" }] : []));
741
+ // Always a length: dropping the token would fall back to the static 200px floor. It collapses
742
+ // wherever `kbqResolvePanelWidth` applies no minimum, or the panel would overflow its pane.
743
+ if (isExplicitPanelWidth(this.panelWidth()) || !Number.isFinite(minWidth))
744
+ return '0px';
745
+ return `${minWidth}px`;
746
+ }, ...(ngDevMode ? [{ debugName: "panelMinWidthToken" }] : /* istanbul ignore next */ []));
747
+ /** @docs-private */
748
+ this.templateRef = viewChild.required(TemplateRef);
749
+ this.scrollbarViewport = viewChild(KbqScrollbarViewport, ...(ngDevMode ? [{ debugName: "scrollbarViewport" }] : /* istanbul ignore next */ []));
750
+ this.queriedItems = contentChildren(KbqDropdownItem, { ...(ngDevMode ? { debugName: "queriedItems" } : /* istanbul ignore next */ {}), descendants: true });
751
+ /** Items borrowed from the parent panel, see `adoptItems`. Used only while this panel has none of its own. */
752
+ this.adoptedItems = signal(null, ...(ngDevMode ? [{ debugName: "adoptedItems" }] : /* istanbul ignore next */ []));
753
+ /**
754
+ * List of the items inside of a dropdown.
755
+ */
756
+ this.items = computed(() => {
757
+ const queried = this.queriedItems();
758
+ return queried.length > 0 ? queried : (this.adoptedItems() ?? queried);
759
+ }, ...(ngDevMode ? [{ debugName: "items" }] : /* istanbul ignore next */ []));
760
+ /**
761
+ * Dropdown content that will be rendered lazily.
762
+ *
763
+ * @docs-private
764
+ */
765
+ this.lazyContent = contentChild(KbqDropdownContent, ...(ngDevMode ? [{ debugName: "lazyContent" }] : /* istanbul ignore next */ []));
736
766
  /** Event emitted when the dropdown is closed. */
737
- this.closed = new EventEmitter();
767
+ this.closed = output();
768
+ /**
769
+ * Whether the `closed` being emitted closes the panels this one is nested in too, see `closeChain`.
770
+ *
771
+ * @internal
772
+ */
773
+ this.closingChain = false;
738
774
  this.focusOrigin = 'program';
739
775
  /** Only the direct descendant menu items. */
740
776
  this.directDescendantItems = new QueryList();
@@ -767,16 +803,42 @@ class KbqDropdown {
767
803
  // A flip while the panel is open leaves focus wherever the previous mode put it: on an item
768
804
  // the new manager will not track, or on an input that is being destroyed. Hand it over the
769
805
  // same way opening does, deferred so the write lands outside this change detection pass.
770
- if (this.panelAnimationState === 'enter') {
771
- this.ngZone.onStable.pipe(take(1)).subscribe(() => this.applyInitialFocus(this.focusOrigin));
806
+ if (this.opened) {
807
+ this.applyInitialFocusAfterRender(this.focusOrigin);
772
808
  }
773
809
  });
774
- }
775
- ngOnInit() {
776
- this.setPositionClasses();
810
+ effect(() => this.syncDirectDescendants(this.items()));
811
+ // A partial `KBQ_DROPDOWN_DEFAULT_OPTIONS` can leave these undefined, so the default is not validated.
812
+ const defaultPosX = untracked(this.xPosition);
813
+ const defaultPosY = untracked(this.yPosition);
814
+ // Validates the position (`model()` has no `transform`) and drops the trigger's resolved override.
815
+ effect(() => {
816
+ const posX = this.xPosition();
817
+ const posY = this.yPosition();
818
+ if (posX !== defaultPosX && posX !== 'before' && posX !== 'after' && posX !== 'center') {
819
+ throwKbqDropdownInvalidPositionX();
820
+ }
821
+ if (posY !== defaultPosY && posY !== 'above' && posY !== 'below') {
822
+ throwKbqDropdownInvalidPositionY();
823
+ }
824
+ untracked(() => this.positionOverride.set(null));
825
+ });
826
+ // `class` also lands on the host as an attribute. Strip only the transferred names, so classes
827
+ // other directives put on `<kbq-dropdown>` survive.
828
+ let previousPanelClass = '';
829
+ effect(() => {
830
+ const classes = this.panelClass();
831
+ for (const className of `${previousPanelClass} ${classes}`.split(' ')) {
832
+ if (className) {
833
+ this.renderer.removeClass(this.elementRef.nativeElement, className);
834
+ }
835
+ }
836
+ previousPanelClass = classes;
837
+ });
777
838
  }
778
839
  ngAfterContentInit() {
779
- this.updateDirectDescendants();
840
+ // Not waiting for the effect: `initKeyManager` and `focusFirstItem` need the descendants now.
841
+ this.syncDirectDescendants(untracked(this.items));
780
842
  this.initKeyManager();
781
843
  // If a user manually (programmatically) focuses a menu item, we need to reflect that focus
782
844
  // change back to the key manager. Note that we don't need to unsubscribe here because focused
@@ -806,7 +868,7 @@ class KbqDropdown {
806
868
  this.currentHovered = item;
807
869
  // Hovering doesn't focus the item in search mode, so arrowing on has to resume from it.
808
870
  // Disabled items are skipped, the same way the key manager skips them for the arrows.
809
- if (this.inSearchMode() && !item.disabled) {
871
+ if (this.inSearchMode() && !item.disabled()) {
810
872
  this.keyManager.setActiveItem(item);
811
873
  }
812
874
  });
@@ -814,7 +876,6 @@ class KbqDropdown {
814
876
  ngOnDestroy() {
815
877
  this.directDescendantItems.destroy();
816
878
  this.tabSubscription.unsubscribe();
817
- this.closed.complete();
818
879
  this.deactivateSafeArea();
819
880
  this.panelReached.complete();
820
881
  this.switchTarget.complete();
@@ -825,27 +886,31 @@ class KbqDropdown {
825
886
  return itemChanges.pipe(startWith(this.directDescendantItems), switchMap((items) => merge(...items.map((item) => item.hovered))));
826
887
  }
827
888
  /**
828
- * Tracks the pointer against `triangle` to protect `owner`'s open submenu, closing it via
829
- * `onExit` if the pointer leaves the triangle without first reaching `panelRect`. Meanwhile, if a
830
- * different nested trigger is hovered, `switchTarget()` emits it — immediately if it's outside
831
- * the triangle, otherwise after a grace period (see `NESTED_HOVER_SWITCH_DELAY`). Replaces any
832
- * safe area already being tracked.
889
+ * Tracks the pointer against the triangle spanned by `origin` and the protected submenu, closing
890
+ * `owner`'s submenu via `onExit` if the pointer leaves the triangle without first reaching the
891
+ * panel. Meanwhile, if a different nested trigger is hovered, `switchTarget()` emits it —
892
+ * immediately if it's outside the triangle, otherwise after a grace period (see
893
+ * `NESTED_HOVER_SWITCH_DELAY`). Replaces any safe area already being tracked.
894
+ *
833
895
  * @docs-private
834
896
  */
835
- activateSafeArea(owner, triangle, panelRect, onExit) {
897
+ activateSafeArea(owner, origin, getPanelRect, onExit) {
836
898
  this.deactivateSafeArea();
837
899
  this.safeAreaOwner = owner;
838
- this.classList = { ...this.classList, [SAFE_AREA_ACTIVE_CLASS]: true };
900
+ this.safeAreaActive.set(true);
839
901
  this.safeAreaCleanup = this.ngZone.runOutsideAngular(() => {
840
902
  const listener = (event) => {
841
903
  const point = { x: event.clientX, y: event.clientY };
904
+ const panelRect = getPanelRect();
842
905
  if (isPointInRect(point, panelRect)) {
843
906
  this.panelReached.next();
844
907
  this.deactivateSafeArea();
845
908
  return;
846
909
  }
847
- if (!isPointInTriangle(point, triangle)) {
848
- const switchTo = this.currentHovered?.isNested && this.currentHovered !== owner && !this.currentHovered.disabled
910
+ if (!isPointInTriangle(point, getSafeTriangleVertices(origin, panelRect))) {
911
+ const switchTo = this.currentHovered?.isNested &&
912
+ this.currentHovered !== owner &&
913
+ !this.currentHovered.disabled()
849
914
  ? this.currentHovered
850
915
  : null;
851
916
  this.deactivateSafeArea();
@@ -861,7 +926,7 @@ class KbqDropdown {
861
926
  return () => this.document.removeEventListener('mousemove', listener, passiveEventListenerOptions$1);
862
927
  });
863
928
  this.switchTargetSubscription = this.hovered()
864
- .pipe(filter((active) => active.isNested && active !== owner && !active.disabled), switchMap((active) => timer(NESTED_HOVER_SWITCH_DELAY).pipe(map(() => active), takeUntil(this.panelReached))))
929
+ .pipe(filter((active) => active.isNested && active !== owner && !active.disabled()), switchMap((active) => timer(NESTED_HOVER_SWITCH_DELAY).pipe(map(() => active), takeUntil(this.panelReached))))
865
930
  .subscribe((active) => {
866
931
  this.deactivateSafeArea();
867
932
  onExit();
@@ -870,6 +935,7 @@ class KbqDropdown {
870
935
  }
871
936
  /**
872
937
  * Stops tracking the current safe area, if any.
938
+ *
873
939
  * @docs-private
874
940
  */
875
941
  deactivateSafeArea() {
@@ -878,16 +944,15 @@ class KbqDropdown {
878
944
  this.safeAreaOwner = null;
879
945
  this.switchTargetSubscription.unsubscribe();
880
946
  this.switchTargetSubscription = Subscription.EMPTY;
881
- if (this.classList[SAFE_AREA_ACTIVE_CLASS]) {
947
+ if (untracked(this.safeAreaActive)) {
882
948
  // The mousemove listener that can reach this runs outside the Angular zone, so re-enter it
883
- // to make sure the `classList` update is picked up by change detection.
884
- this.ngZone.run(() => {
885
- this.classList = { ...this.classList, [SAFE_AREA_ACTIVE_CLASS]: false };
886
- });
949
+ // to make sure the class update is picked up by change detection.
950
+ this.ngZone.run(() => this.safeAreaActive.set(false));
887
951
  }
888
952
  }
889
953
  /**
890
954
  * Whether a safe area is currently being tracked.
955
+ *
891
956
  * @docs-private
892
957
  */
893
958
  isSafeAreaActive() {
@@ -895,22 +960,16 @@ class KbqDropdown {
895
960
  }
896
961
  /**
897
962
  * Whether `item` is the nested trigger currently protected by an active safe area.
963
+ *
898
964
  * @docs-private
899
965
  */
900
966
  isSafeAreaOwner(item) {
901
967
  return this.safeAreaOwner === item;
902
968
  }
903
- /**
904
- * Stream that emits when the pointer reaches the panel the active safe area protects (as opposed
905
- * to leaving the safe area, which closes the panel instead).
906
- * @docs-private
907
- */
908
- onPanelReached() {
909
- return this.panelReached.asObservable();
910
- }
911
969
  /**
912
970
  * Stream that emits the sibling trigger that should open once a forced safe-area switch has
913
971
  * closed the trigger it was protecting.
972
+ *
914
973
  * @docs-private
915
974
  */
916
975
  onSwitchTarget() {
@@ -921,7 +980,10 @@ class KbqDropdown {
921
980
  const keyCode = event.keyCode;
922
981
  switch (keyCode) {
923
982
  case ESCAPE:
924
- this.closed.emit('keydown');
983
+ // Spent by a pop-up inside the panel, such as the tooltip of a truncated item, which closes alone.
984
+ if (!event.defaultPrevented) {
985
+ this.closed.emit('keydown');
986
+ }
925
987
  break;
926
988
  case LEFT_ARROW:
927
989
  if (this.parent && this.direction === 'ltr') {
@@ -946,12 +1008,14 @@ class KbqDropdown {
946
1008
  }
947
1009
  return;
948
1010
  default:
949
- // Only the vertical arrows move the highlight in search mode; every other key that the
950
- // search field lets through would otherwise scroll the list back on each keystroke.
951
- if (keyCode === UP_ARROW || keyCode === DOWN_ARROW) {
1011
+ // Home/End too: with a stale `mouse` origin the item they move to is not scrolled into view.
1012
+ if (isVerticalMovement(event)) {
952
1013
  this.setFocusOrigin('keyboard');
953
1014
  this.keyManager.onKeydown(event);
954
- this.revealActiveItem();
1015
+ // Only the arrows reveal: other keys would scroll the list back on each keystroke.
1016
+ if (keyCode === UP_ARROW || keyCode === DOWN_ARROW) {
1017
+ this.revealActiveItem();
1018
+ }
955
1019
  }
956
1020
  else {
957
1021
  this.keyManager.onKeydown(event);
@@ -964,16 +1028,25 @@ class KbqDropdown {
964
1028
  }
965
1029
  /**
966
1030
  * Applies the panel's initial focus, see `applyInitialFocus`.
1031
+ *
967
1032
  * @param origin Action from which the focus originated. Used to set the correct styling.
968
1033
  */
969
1034
  focusFirstItem(origin = 'program') {
970
- // When the content is rendered lazily, it takes a bit before the items are inside the DOM.
971
- if (this.lazyContent) {
972
- this.ngZone.onStable.pipe(take(1)).subscribe(() => this.applyInitialFocus(origin));
973
- }
974
- else {
975
- this.applyInitialFocus(origin);
976
- }
1035
+ // Untracked: called from a consumer's `effect()`, the state read on the way — the content and search field
1036
+ // queries, the `disabled` of the items — would make the effect run again whenever it changes.
1037
+ untracked(() => {
1038
+ // When the content is rendered lazily, it takes a bit before the items are inside the DOM.
1039
+ if (this.lazyContent()) {
1040
+ this.applyInitialFocusAfterRender(origin);
1041
+ }
1042
+ else {
1043
+ this.applyInitialFocus(origin);
1044
+ }
1045
+ });
1046
+ }
1047
+ applyInitialFocusAfterRender(origin) {
1048
+ this.initialFocusRef?.destroy();
1049
+ this.initialFocusRef = afterNextRender(() => this.applyInitialFocus(origin), { injector: this.injector });
977
1050
  }
978
1051
  /**
979
1052
  * Applies focus when the dropdown is opened.
@@ -1006,6 +1079,7 @@ class KbqDropdown {
1006
1079
  * Moves focus back into the projected search field, reporting whether there was one. A nested panel
1007
1080
  * restores focus through this instead of onto its trigger item, which would strand the caret outside
1008
1081
  * the query.
1082
+ *
1009
1083
  * @docs-private
1010
1084
  */
1011
1085
  restoreFocus() {
@@ -1029,51 +1103,59 @@ class KbqDropdown {
1029
1103
  this.keyManager.activeItem?.resetStyles();
1030
1104
  this.keyManager.setActiveItem(-1);
1031
1105
  }
1106
+ /**
1107
+ * Lends this panel the parent's items, for a submenu whose own items were initialised as children of
1108
+ * the root panel. Ignored once the panel has items of its own.
1109
+ *
1110
+ * @docs-private
1111
+ */
1112
+ adoptItems(items) {
1113
+ this.adoptedItems.set(items);
1114
+ }
1032
1115
  /**
1033
1116
  * Adds classes to the dropdown panel based on its position. Can be used by
1034
1117
  * consumers to add specific styling based on the position.
1118
+ *
1035
1119
  * @param posX Position of the dropdown along the x axis.
1036
1120
  * @param posY Position of the dropdown along the y axis.
1121
+ *
1037
1122
  * @docs-private
1038
1123
  */
1039
- setPositionClasses(posX = this.xPosition, posY = this.yPosition) {
1040
- // Reassign a new object reference so the native `[class]` binding picks up the change.
1041
- this.classList = {
1042
- ...this.classList,
1043
- 'kbq-dropdown-before': posX === 'before',
1044
- 'kbq-dropdown-after': posX === 'after',
1045
- 'kbq-dropdown-center': posX === 'center',
1046
- 'kbq-dropdown-above': posY === 'above',
1047
- 'kbq-dropdown-below': posY === 'below'
1048
- };
1124
+ setPositionClasses(posX = untracked(this.xPosition), posY = untracked(this.yPosition)) {
1125
+ this.positionOverride.set({ posX, posY });
1049
1126
  }
1050
- /** Starts the enter animation. */
1051
- startAnimation() {
1052
- this.panelAnimationState = 'enter';
1053
- }
1054
- /** Resets the panel animation to its initial state. */
1055
- resetAnimation() {
1056
- this.panelAnimationState = 'void';
1057
- }
1058
- /** Callback that is invoked when the panel animation completes. */
1059
- onAnimationDone(event) {
1060
- this.animationDone.next(event);
1061
- this.isAnimating = false;
1062
- }
1063
- onAnimationStart(event) {
1064
- this.isAnimating = true;
1065
- // Scroll the content element to the top as soon as the animation starts. This is necessary,
1066
- // because we move focus to the first item while it's still being animated, which can throw
1067
- // the browser off when it determines the scroll position. Alternatively we can move focus
1068
- // when the animation is done, however moving focus asynchronously will interrupt screen
1069
- // readers which are in the process of reading out the dropdown already. We take the `element`
1070
- // from the `event` since we can't use a `ViewChild` to access the pane.
1071
- if (event.toState === 'enter' && this.keyManager.activeItemIndex <= 0) {
1072
- event.element.scrollTop = 0;
1073
- }
1127
+ /**
1128
+ * Called by the trigger when it attaches the panel and when it detaches it.
1129
+ *
1130
+ * @docs-private
1131
+ */
1132
+ setOpened(opened) {
1133
+ this.opened = opened;
1134
+ this.openedRender?.destroy();
1135
+ if (!opened)
1136
+ return;
1137
+ this.openedRender = afterNextRender(() => {
1138
+ // Focus moves to the first item before the panel has rendered, which can throw the browser off
1139
+ // when it determines the scroll position.
1140
+ if (this.keyManager.activeItemIndex <= 0) {
1141
+ this.scrollbarViewport()?.scrollToTop();
1142
+ }
1143
+ this.scrollbarViewport()?.flashScrollIndicators();
1144
+ }, { injector: this.injector });
1074
1145
  }
1075
1146
  close() {
1076
- this.closed.emit(this.focusOrigin === 'keyboard' ? 'keydown' : 'click');
1147
+ this.closeChain(this.focusOrigin === 'keyboard' ? 'keydown' : 'click');
1148
+ }
1149
+ /**
1150
+ * Emits `closed` for an activated item, which closes every panel up to the root. Its reason follows the focus
1151
+ * origin, so after keyboard navigation it is the `'keydown'` that Escape reports for closing one panel alone.
1152
+ *
1153
+ * @internal
1154
+ */
1155
+ closeChain(reason) {
1156
+ this.closingChain = true;
1157
+ this.closed.emit(reason);
1158
+ this.closingChain = false;
1077
1159
  }
1078
1160
  /**
1079
1161
  * With a search field the caret has to stay in the input, so the active item is only highlighted and
@@ -1093,7 +1175,8 @@ class KbqDropdown {
1093
1175
  this.keyManager = this.activeDescendantKeyManager;
1094
1176
  }
1095
1177
  else {
1096
- this.focusKeyManager ??= this.configureKeyManager(new FocusKeyManager(this.directDescendantItems).withTypeAhead());
1178
+ // Home/End only without a search field, where they belong to the caret.
1179
+ this.focusKeyManager ??= this.configureKeyManager(new FocusKeyManager(this.directDescendantItems).withTypeAhead().withHomeAndEnd());
1097
1180
  this.keyManager = this.focusKeyManager;
1098
1181
  }
1099
1182
  this.tabSubscription.unsubscribe();
@@ -1126,63 +1209,33 @@ class KbqDropdown {
1126
1209
  this.keyManager.activeItem?.getHostElement().scrollIntoView?.({ block: 'nearest', inline: 'nearest' });
1127
1210
  }
1128
1211
  /**
1129
- * Sets up a stream that will keep track of any newly-added menu items and will update the list
1130
- * of direct descendants. We collect the descendants this way, because `items` can include
1131
- * items that are part of child menus, and using a custom way of registering items is unreliable
1132
- * when it comes to maintaining the item order.
1212
+ * Narrows `items` down to the ones this panel owns. We collect the descendants this way, because
1213
+ * `items` can include items that are part of child menus, and using a custom way of registering
1214
+ * items is unreliable when it comes to maintaining the item order.
1133
1215
  */
1134
- updateDirectDescendants() {
1135
- this.items.changes.pipe(startWith(this.items)).subscribe((items) => {
1136
- this.directDescendantItems.reset(items.filter((item) => item.parentDropdownPanel === this));
1137
- this.directDescendantItems.notifyOnChanges();
1138
- });
1216
+ syncDirectDescendants(items) {
1217
+ const owned = items.filter((item) => item.parentDropdownPanel === this);
1218
+ const current = this.directDescendantItems.toArray();
1219
+ // Re-notifying an unchanged list would restart every stream keyed on `changes`.
1220
+ if (owned.length === current.length && owned.every((item, index) => item === current[index]))
1221
+ return;
1222
+ this.directDescendantItems.reset(owned);
1223
+ this.directDescendantItems.notifyOnChanges();
1139
1224
  }
1140
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.30", ngImport: i0, type: KbqDropdown, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
1141
- /** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.2.0", version: "20.3.30", type: KbqDropdown, isStandalone: true, selector: "kbq-dropdown", inputs: { navigationWithWrap: { classPropertyName: "navigationWithWrap", publicName: "navigationWithWrap", isSignal: true, isRequired: false, transformFunction: null }, xPosition: { classPropertyName: "xPosition", publicName: "xPosition", isSignal: false, isRequired: false, transformFunction: null }, yPosition: { classPropertyName: "yPosition", publicName: "yPosition", isSignal: false, isRequired: false, transformFunction: null }, overlapTriggerY: { classPropertyName: "overlapTriggerY", publicName: "overlapTriggerY", isSignal: false, isRequired: false, transformFunction: null }, overlapTriggerX: { classPropertyName: "overlapTriggerX", publicName: "overlapTriggerX", isSignal: false, isRequired: false, transformFunction: null }, hasBackdrop: { classPropertyName: "hasBackdrop", publicName: "hasBackdrop", isSignal: false, isRequired: false, transformFunction: null }, panelClass: { classPropertyName: "panelClass", publicName: "class", isSignal: false, isRequired: false, transformFunction: null }, backdropClass: { classPropertyName: "backdropClass", publicName: "backdropClass", isSignal: false, isRequired: false, transformFunction: null }, panelWidth: { classPropertyName: "panelWidth", publicName: "panelWidth", isSignal: true, isRequired: false, transformFunction: null }, panelMinWidth: { classPropertyName: "panelMinWidth", publicName: "panelMinWidth", isSignal: true, isRequired: false, transformFunction: null }, panelMaxWidth: { classPropertyName: "panelMaxWidth", publicName: "panelMaxWidth", isSignal: true, isRequired: false, transformFunction: null }, safeArea: { classPropertyName: "safeArea", publicName: "safeArea", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { closed: "closed" }, host: { styleAttribute: "display: contents" }, providers: [
1225
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: KbqDropdown, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
1226
+ /** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.2.0", version: "21.2.25", type: KbqDropdown, isStandalone: true, selector: "kbq-dropdown", inputs: { activeDescendantNavigation: { classPropertyName: "activeDescendantNavigation", publicName: "activeDescendantNavigation", isSignal: true, isRequired: false, transformFunction: null }, navigationWithWrap: { classPropertyName: "navigationWithWrap", publicName: "navigationWithWrap", isSignal: true, isRequired: false, transformFunction: null }, xPosition: { classPropertyName: "xPosition", publicName: "xPosition", isSignal: true, isRequired: false, transformFunction: null }, yPosition: { classPropertyName: "yPosition", publicName: "yPosition", isSignal: true, isRequired: false, transformFunction: null }, overlapTriggerY: { classPropertyName: "overlapTriggerY", publicName: "overlapTriggerY", isSignal: true, isRequired: false, transformFunction: null }, overlapTriggerX: { classPropertyName: "overlapTriggerX", publicName: "overlapTriggerX", isSignal: true, isRequired: false, transformFunction: null }, hasBackdrop: { classPropertyName: "hasBackdrop", publicName: "hasBackdrop", isSignal: true, isRequired: false, transformFunction: null }, panelClass: { classPropertyName: "panelClass", publicName: "class", isSignal: true, isRequired: false, transformFunction: null }, backdropClass: { classPropertyName: "backdropClass", publicName: "backdropClass", isSignal: true, isRequired: false, transformFunction: null }, panelWidth: { classPropertyName: "panelWidth", publicName: "panelWidth", isSignal: true, isRequired: false, transformFunction: null }, panelMinWidth: { classPropertyName: "panelMinWidth", publicName: "panelMinWidth", isSignal: true, isRequired: false, transformFunction: null }, panelMaxWidth: { classPropertyName: "panelMaxWidth", publicName: "panelMaxWidth", isSignal: true, isRequired: false, transformFunction: null }, safeArea: { classPropertyName: "safeArea", publicName: "safeArea", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { xPosition: "xPositionChange", yPosition: "yPositionChange", overlapTriggerY: "overlapTriggerYChange", overlapTriggerX: "overlapTriggerXChange", closed: "closed" }, host: { styleAttribute: "display: contents" }, providers: [
1142
1227
  { provide: KBQ_DROPDOWN_PANEL, useExisting: KbqDropdown }
1143
- ], queries: [{ propertyName: "panelFormField", first: true, predicate: KbqFormField, descendants: true, isSignal: true }, { propertyName: "searches", predicate: KbqDropdownSearch, descendants: true, isSignal: true }, { propertyName: "lazyContent", first: true, predicate: KbqDropdownContent, descendants: true }, { propertyName: "items", predicate: KbqDropdownItem, descendants: true }], viewQueries: [{ propertyName: "templateRef", first: true, predicate: TemplateRef, descendants: true }], exportAs: ["kbqDropdown"], ngImport: i0, template: "<ng-template>\n <div\n tabindex=\"-1\"\n class=\"kbq-dropdown__panel\"\n [class.kbq-dropdown__panel_nested]=\"parent\"\n [class]=\"classList\"\n [style.max-width.px]=\"panelMaxWidth()\"\n [style.--kbq-dropdown-size-container-width-min]=\"panelMinWidthToken()\"\n [@transformDropdown]=\"panelAnimationState\"\n (@transformDropdown.done)=\"onAnimationDone($event)\"\n (@transformDropdown.start)=\"onAnimationStart($event)\"\n (click)=\"close()\"\n (keydown)=\"handleKeydown($event)\"\n >\n <div class=\"kbq-dropdown__content\">\n <ng-content />\n </div>\n <ng-content select=\"[kbqDropdownFooter], kbq-dropdown-footer\" />\n </div>\n</ng-template>\n\n<ng-content select=\"[kbqDropdownStaticContent]\" />\n", styles: [".kbq-dropdown-footer{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;display:flex;align-items:center;box-sizing:border-box;min-height:var(--kbq-select-footer-size-min-height, var(--kbq-size-4xl));border-top-width:var(--kbq-select-footer-size-border-width, var(--kbq-size-border-width));border-top-style:solid;padding:var(--kbq-select-footer-size-padding-vertical, var(--kbq-size-xxs)) var(--kbq-select-footer-size-padding-horizontal, var(--kbq-size-l))}.kbq-dropdown-trigger.kbq-button{padding-left:calc(var(--kbq-dropdown-trigger-horizontal-padding, 10px) - var(--kbq-size-border-width));padding-right:calc(var(--kbq-dropdown-trigger-horizontal-padding, 10px) - var(--kbq-size-border-width))}.kbq-dropdown-trigger.kbq-button .kbq-icon_left{margin-right:var(--kbq-size-xs)}.kbq-dropdown-trigger.kbq-button .kbq-icon_right{margin-left:var(--kbq-size-3xs)}.kbq-dropdown-trigger.kbq-button-icon.kbq-button-icon_right.kbq-button-icon_left .kbq-icon_left{margin-right:0}.kbq-dropdown-trigger.kbq-button-icon.kbq-button-icon_right.kbq-button-icon_left .kbq-icon_right{margin-left:0}.kbq-dropdown-trigger__icon{margin-left:auto;align-self:center}.kbq-dropdown__panel{outline:none;overflow-x:hidden;overflow-y:auto;min-width:max(var(--kbq-dropdown-size-container-width-min),100%);max-width:var(--kbq-dropdown-size-container-width-max);border-radius:var(--kbq-dropdown-size-container-border-radius);box-sizing:border-box}.kbq-dropdown__panel.ng-animating{pointer-events:none}.kbq-dropdown__panel .kbq-dropdown-item{position:relative}.kbq-dropdown__panel .kbq-dropdown-item:before,.kbq-dropdown__panel .kbq-dropdown-item:after{position:absolute;content:\"\";width:var(--kbq-size-xxs);height:calc(100% + var(--kbq-size-3xs) * 2)}.kbq-dropdown__panel .kbq-dropdown-item:before{right:calc(100% + var(--kbq-size-3xs))}.kbq-dropdown__panel .kbq-dropdown-item:after{left:calc(100% + var(--kbq-size-3xs))}.kbq-dropdown__panel .kbq-dropdown-item:before,.kbq-dropdown__panel .kbq-dropdown-item:after{top:calc(-1 * var(--kbq-size-3xs));bottom:calc(-1 * var(--kbq-size-3xs))}.kbq-dropdown__panel .kbq-dropdown-item.kbq-progress:after{background:none;animation:none}.kbq-dropdown__panel .kbq-divider{margin-left:calc(var(--kbq-size-xxs) * -1);margin-right:calc(var(--kbq-size-xxs) * -1)}.kbq-dropdown__content{display:flex;flex-direction:column;padding:var(--kbq-size-xxs)}.kbq-dropdown-footer{border-color:var(--kbq-line-contrast-less)}.kbq-dropdown__panel{box-shadow:var(--kbq-dropdown-container-shadow);background:var(--kbq-dropdown-container-background)}.kbq-dropdown-item{background:var(--kbq-list-default-container-background);color:var(--kbq-list-default-text-color)}.kbq-dropdown-item .kbq-icon.kbq-empty:not(.kbq-icon-button,.kbq-icon-item){color:var(--kbq-list-default-text-color)}.kbq-dropdown-item .kbq-dropdown-item__caption{color:var(--kbq-dropdown-item-caption-color)}.kbq-dropdown-item.kbq-dropdown-item_highlighted,.kbq-dropdown-item.kbq-dropdown-item_active:not(.kbq-disabled),.kbq-dropdown-item.cdk-focused:not(.kbq-disabled){background:var(--kbq-list-states-hover-container-background);color:var(--kbq-list-states-hover-text-color)}.kbq-dropdown-item.kbq-dropdown-item_highlighted .kbq-icon.kbq-empty:not(.kbq-icon-button,.kbq-icon-item),.kbq-dropdown-item.kbq-dropdown-item_active:not(.kbq-disabled) .kbq-icon.kbq-empty:not(.kbq-icon-button,.kbq-icon-item),.kbq-dropdown-item.cdk-focused:not(.kbq-disabled) .kbq-icon.kbq-empty:not(.kbq-icon-button,.kbq-icon-item){color:var(--kbq-list-states-hover-text-color)}.kbq-dropdown-item .kbq-dropdown__panel_safe-area-active.cdk-focused:not(.kbq-dropdown-item_highlighted,.kbq-selected,.kbq-disabled){background:var(--kbq-list-default-container-background);color:var(--kbq-list-default-text-color)}.kbq-dropdown-item .kbq-dropdown__panel_safe-area-active.cdk-focused:not(.kbq-dropdown-item_highlighted,.kbq-selected,.kbq-disabled) .kbq-icon.kbq-empty:not(.kbq-icon-button,.kbq-icon-item){color:var(--kbq-list-default-text-color)}.kbq-dropdown-item:active:not(.kbq-disabled),.kbq-dropdown-item.kbq-active:not(.kbq-disabled){background:var(--kbq-list-states-active-container-background)}.kbq-dropdown-item.kbq-selected{background:var(--kbq-list-states-selected-container-background);color:var(--kbq-list-states-selected-text-color)}.kbq-dropdown-item.kbq-selected .kbq-icon.kbq-empty:not(.kbq-icon-button,.kbq-icon-item){color:var(--kbq-list-states-selected-text-color)}.kbq-dropdown-item.kbq-selected.kbq-dropdown-item_active:not(.kbq-disabled),.kbq-dropdown-item.kbq-selected.cdk-focused:not(.kbq-disabled){background:var(--kbq-list-states-selected-hover-container-background);color:var(--kbq-list-states-selected-hover-text-color)}.kbq-dropdown-item.kbq-selected.kbq-dropdown-item_active:not(.kbq-disabled) .kbq-icon.kbq-empty:not(.kbq-icon-button,.kbq-icon-item),.kbq-dropdown-item.kbq-selected.cdk-focused:not(.kbq-disabled) .kbq-icon.kbq-empty:not(.kbq-icon-button,.kbq-icon-item){color:var(--kbq-list-states-selected-hover-text-color)}.kbq-dropdown-item.kbq-selected:active:not(.kbq-disabled),.kbq-dropdown-item.kbq-selected.kbq-active:not(.kbq-disabled){background:var(--kbq-list-states-selected-active-container-background)}.kbq-dropdown-item.kbq-disabled{background:var(--kbq-list-states-disabled-container-background);color:var(--kbq-list-states-disabled-text-color)}.kbq-dropdown-item.kbq-disabled .kbq-icon.kbq-empty:not(.kbq-icon-button,.kbq-icon-item){color:var(--kbq-list-states-disabled-text-color)}.kbq-dropdown-item:is(.kbq-selected,.cdk-focused,.kbq-dropdown-item_active):has(+:is(.kbq-selected,.cdk-focused,.kbq-dropdown-item_active)){border-bottom-left-radius:0;border-bottom-right-radius:0}.kbq-dropdown-item:is(.kbq-selected,.cdk-focused,.kbq-dropdown-item_active)+:is(.kbq-selected,.cdk-focused,.kbq-dropdown-item_active){border-top-left-radius:0;border-top-right-radius:0}.kbq-dropdown__group-header.kbq-dropdown__group-header_small{color:var(--kbq-foreground-contrast-secondary)}.kbq-dropdown-item-overlay{background:transparent}.kbq-dropdown-item,.kbq-dropdown__content{font-size:var(--kbq-typography-text-normal-font-size);font-style:var(--kbq-typography-text-normal-font-style);font-weight:var(--kbq-typography-text-normal-font-weight);line-height:var(--kbq-typography-text-normal-line-height);font-family:var(--kbq-typography-text-normal-font-family);text-transform:var(--kbq-typography-text-normal-text-transform);font-feature-settings:var(--kbq-typography-text-normal-font-feature-settings);letter-spacing:var(--kbq-typography-text-normal-letter-spacing)}.kbq-dropdown-item .kbq-dropdown-item__caption,.kbq-dropdown__content .kbq-dropdown-item__caption{font-size:var(--kbq-typography-text-compact-font-size);font-style:var(--kbq-typography-text-compact-font-style);font-weight:var(--kbq-typography-text-compact-font-weight);line-height:var(--kbq-typography-text-compact-line-height);font-family:var(--kbq-typography-text-compact-font-family);text-transform:var(--kbq-typography-text-compact-text-transform);font-feature-settings:var(--kbq-typography-text-compact-font-feature-settings);letter-spacing:var(--kbq-typography-text-compact-letter-spacing)}.kbq-dropdown__group-header{font-size:var(--kbq-typography-big-strong-font-size);font-style:var(--kbq-typography-big-strong-font-style);font-weight:var(--kbq-typography-big-strong-font-weight);line-height:var(--kbq-typography-big-strong-line-height);font-family:var(--kbq-typography-big-strong-font-family);text-transform:var(--kbq-typography-big-strong-text-transform);font-feature-settings:var(--kbq-typography-big-strong-font-feature-settings);letter-spacing:var(--kbq-typography-big-strong-letter-spacing)}.kbq-dropdown__group-header.kbq-dropdown__group-header_small{font-size:var(--kbq-typography-caps-compact-strong-font-size);font-style:var(--kbq-typography-caps-compact-strong-font-style);font-weight:var(--kbq-typography-caps-compact-strong-font-weight);line-height:var(--kbq-typography-caps-compact-strong-line-height);font-family:var(--kbq-typography-caps-compact-strong-font-family);text-transform:var(--kbq-typography-caps-compact-strong-text-transform);font-feature-settings:var(--kbq-typography-caps-compact-strong-font-feature-settings);letter-spacing:var(--kbq-typography-caps-compact-strong-letter-spacing)}\n", "@charset \"UTF-8\";.kbq-list,.kbq-list-selection,.kbq-list-option.cdk-drag-preview,.kbq-list-drag-preview_text{--kbq-list-size-container-padding-left: var(--kbq-size-m);--kbq-list-size-container-padding-right: var(--kbq-size-m);--kbq-list-size-container-padding-vertical: var(--kbq-size-xxs);--kbq-list-size-container-content-gap-horizontal: var(--kbq-size-s);--kbq-list-size-container-content-gap-vertical: var(--kbq-size-3xs);--kbq-list-size-container-focus-outline-width: var(--kbq-size-3xs);--kbq-list-default-container-background: transparent;--kbq-list-default-text-color: var(--kbq-foreground-contrast);--kbq-list-default-icon-color: var(--kbq-icon-contrast);--kbq-list-default-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-default-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-states-hover-container-background: var(--kbq-states-background-transparent-hover);--kbq-list-states-active-container-background: var(--kbq-states-background-transparent-active);--kbq-list-states-hover-text-color: var(--kbq-foreground-contrast);--kbq-list-states-hover-icon-color: var(--kbq-icon-contrast);--kbq-list-states-hover-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-states-hover-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-states-selected-container-background: var(--kbq-background-theme-less);--kbq-list-multiple-states-selected-container-background: var(--kbq-background-contrast-less);--kbq-list-states-selected-text-color: var(--kbq-foreground-contrast);--kbq-list-states-selected-icon-color: var(--kbq-icon-contrast);--kbq-list-states-selected-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-states-selected-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-multiple-states-selected-text-color: var(--kbq-foreground-contrast);--kbq-list-multiple-states-selected-icon-color: var(--kbq-icon-contrast);--kbq-list-multiple-states-selected-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-multiple-states-selected-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-states-selected-hover-container-background: var(--kbq-states-background-theme-less-hover);--kbq-list-multiple-states-selected-hover-container-background: var(--kbq-states-background-contrast-less-hover);--kbq-list-states-selected-active-container-background: var(--kbq-states-background-theme-less-active);--kbq-list-multiple-states-selected-active-container-background: var(--kbq-states-background-contrast-less-active);--kbq-list-states-selected-hover-text-color: var(--kbq-foreground-contrast);--kbq-list-states-selected-hover-icon-color: var(--kbq-icon-contrast);--kbq-list-states-selected-hover-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-states-selected-hover-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-multiple-states-selected-hover-text-color: var(--kbq-foreground-contrast);--kbq-list-multiple-states-selected-hover-icon-color: var(--kbq-icon-contrast);--kbq-list-multiple-states-selected-hover-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-multiple-states-selected-hover-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-states-focused-focus-outline-color: var(--kbq-states-line-focus-theme);--kbq-list-states-disabled-container-background: transparent;--kbq-list-states-disabled-text-color: var(--kbq-states-foreground-disabled);--kbq-list-states-disabled-icon-color: var(--kbq-states-icon-disabled);--kbq-list-states-disabled-icon-button-color: var(--kbq-states-icon-disabled);--kbq-list-states-disabled-caption-color: var(--kbq-states-foreground-disabled);--kbq-list-states-dragged-container-background: var(--kbq-background-card);--kbq-list-states-dragged-container-shadow: var(--kbq-shadow-popup)}.kbq-list-selection{--kbq-list-size-dragged-indicator-thickness: var(--kbq-size-3xs);--kbq-list-states-dragged-indicator-color: var(--kbq-line-theme)}.kbq-list-drag-preview_text{--kbq-list-size-drag-preview-max-width: 480px;--kbq-list-states-drag-preview-background: color-mix( in srgb, var(--kbq-background-card) calc(var(--kbq-opacity-overlay) * 100%), transparent )}.kbq-dropdown__panel{--kbq-dropdown-size-container-width-min: 200px;--kbq-dropdown-size-container-width-max: var(--kbq-panel-size-width-max, 640px);--kbq-dropdown-size-container-padding-vertical: var(--kbq-size-xxs);--kbq-dropdown-size-container-border-radius: var(--kbq-size-s);--kbq-dropdown-container-background: var(--kbq-background-card);--kbq-dropdown-container-shadow: var(--kbq-shadow-popup);--kbq-dropdown-item-border-radius: var(--kbq-size-xs);--kbq-dropdown-item-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-default-container-background: transparent;--kbq-list-default-text-color: var(--kbq-foreground-contrast);--kbq-list-default-icon-color: var(--kbq-icon-contrast);--kbq-list-default-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-default-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-states-hover-container-background: var(--kbq-states-background-transparent-hover);--kbq-list-states-active-container-background: var(--kbq-states-background-transparent-active);--kbq-list-states-hover-text-color: var(--kbq-foreground-contrast);--kbq-list-states-hover-icon-color: var(--kbq-icon-contrast);--kbq-list-states-hover-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-states-hover-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-states-selected-container-background: var(--kbq-background-theme-less);--kbq-list-multiple-states-selected-container-background: var(--kbq-background-contrast-less);--kbq-list-states-selected-text-color: var(--kbq-foreground-contrast);--kbq-list-states-selected-icon-color: var(--kbq-icon-contrast);--kbq-list-states-selected-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-states-selected-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-multiple-states-selected-text-color: var(--kbq-foreground-contrast);--kbq-list-multiple-states-selected-icon-color: var(--kbq-icon-contrast);--kbq-list-multiple-states-selected-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-multiple-states-selected-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-states-selected-hover-container-background: var(--kbq-states-background-theme-less-hover);--kbq-list-multiple-states-selected-hover-container-background: var(--kbq-states-background-contrast-less-hover);--kbq-list-states-selected-active-container-background: var(--kbq-states-background-theme-less-active);--kbq-list-multiple-states-selected-active-container-background: var(--kbq-states-background-contrast-less-active);--kbq-list-states-selected-hover-text-color: var(--kbq-foreground-contrast);--kbq-list-states-selected-hover-icon-color: var(--kbq-icon-contrast);--kbq-list-states-selected-hover-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-states-selected-hover-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-multiple-states-selected-hover-text-color: var(--kbq-foreground-contrast);--kbq-list-multiple-states-selected-hover-icon-color: var(--kbq-icon-contrast);--kbq-list-multiple-states-selected-hover-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-multiple-states-selected-hover-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-states-focused-focus-outline-color: var(--kbq-states-line-focus-theme);--kbq-list-states-disabled-container-background: transparent;--kbq-list-states-disabled-text-color: var(--kbq-states-foreground-disabled);--kbq-list-states-disabled-icon-color: var(--kbq-states-icon-disabled);--kbq-list-states-disabled-icon-button-color: var(--kbq-states-icon-disabled);--kbq-list-states-disabled-caption-color: var(--kbq-states-foreground-disabled);--kbq-list-states-dragged-container-background: var(--kbq-background-card);--kbq-list-states-dragged-container-shadow: var(--kbq-shadow-popup)}\n"], animations: [
1144
- kbqDropdownAnimations.transformDropdown,
1145
- kbqDropdownAnimations.fadeInItems
1146
- ], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
1228
+ ], queries: [{ propertyName: "panelFormField", first: true, predicate: KbqFormField, descendants: true, isSignal: true }, { propertyName: "searches", predicate: KbqDropdownSearch, descendants: true, isSignal: true }, { propertyName: "queriedItems", predicate: KbqDropdownItem, descendants: true, isSignal: true }, { propertyName: "lazyContent", first: true, predicate: KbqDropdownContent, descendants: true, isSignal: true }], viewQueries: [{ propertyName: "templateRef", first: true, predicate: TemplateRef, descendants: true, isSignal: true }, { propertyName: "scrollbarViewport", first: true, predicate: KbqScrollbarViewport, descendants: true, isSignal: true }], exportAs: ["kbqDropdown"], ngImport: i0, template: "<ng-template>\n <div\n kbqScrollbarViewport\n tabindex=\"-1\"\n class=\"kbq-dropdown__panel\"\n [class.kbq-dropdown__panel_nested]=\"parent\"\n [class]=\"classList()\"\n [style.max-width.px]=\"panelMaxWidth()\"\n [style.--kbq-dropdown-size-container-width-min]=\"panelMinWidthToken()\"\n (keydown)=\"handleKeydown($event)\"\n >\n <!-- Scoped to the options content: a click on a footer control must not close the panel. -->\n <div class=\"kbq-dropdown__content\" (click)=\"close()\">\n <ng-content />\n </div>\n <ng-content select=\"[kbqDropdownFooter], kbq-dropdown-footer\" />\n </div>\n</ng-template>\n\n<ng-content select=\"[kbqDropdownStaticContent]\" />\n", styles: [".kbq-dropdown-footer{-webkit-user-select:none;user-select:none;display:flex;align-items:center;box-sizing:border-box;min-height:var(--kbq-select-footer-size-min-height, var(--kbq-size-4xl));border-top-width:var(--kbq-select-footer-size-border-width, var(--kbq-size-border-width));border-top-style:solid;padding:var(--kbq-select-footer-size-padding-vertical, var(--kbq-size-xxs)) var(--kbq-select-footer-size-padding-horizontal, var(--kbq-size-l))}.kbq-dropdown-trigger.kbq-button{padding-left:calc(var(--kbq-dropdown-trigger-horizontal-padding, 10px) - var(--kbq-size-border-width));padding-right:calc(var(--kbq-dropdown-trigger-horizontal-padding, 10px) - var(--kbq-size-border-width))}.kbq-dropdown-trigger.kbq-button .kbq-icon_left{margin-right:var(--kbq-size-xs)}.kbq-dropdown-trigger.kbq-button .kbq-icon_right{margin-left:var(--kbq-size-3xs)}.kbq-dropdown-trigger.kbq-button-icon.kbq-button-icon_right.kbq-button-icon_left .kbq-icon_left{margin-right:0}.kbq-dropdown-trigger.kbq-button-icon.kbq-button-icon_right.kbq-button-icon_left .kbq-icon_right{margin-left:0}.kbq-dropdown-trigger__icon{margin-left:auto;align-self:center}.kbq-dropdown__panel{outline:none;overflow-x:hidden;overflow-y:auto;min-width:max(var(--kbq-dropdown-size-container-width-min),100%);max-width:var(--kbq-dropdown-size-container-width-max);border-radius:var(--kbq-dropdown-size-container-border-radius)}@supports (corner-shape: squircle){.kbq-dropdown__panel{corner-shape:squircle;border-radius:clamp(var(--kbq-dropdown-size-container-border-radius) * 1.85,var(--kbq-dropdown-size-container-border-radius) * 2.3 - 3.6px,var(--kbq-dropdown-size-container-border-radius) * 2)}}.kbq-dropdown__panel{box-sizing:border-box}.kbq-dropdown__panel.ng-animating{pointer-events:none}.kbq-dropdown__panel .kbq-dropdown-item{position:relative}.kbq-dropdown__panel .kbq-dropdown-item:before,.kbq-dropdown__panel .kbq-dropdown-item:after{position:absolute;content:\"\";width:var(--kbq-size-xxs);height:calc(100% + var(--kbq-size-3xs) * 2)}.kbq-dropdown__panel .kbq-dropdown-item:before{right:calc(100% + var(--kbq-size-3xs))}.kbq-dropdown__panel .kbq-dropdown-item:after{left:calc(100% + var(--kbq-size-3xs))}.kbq-dropdown__panel .kbq-dropdown-item:before,.kbq-dropdown__panel .kbq-dropdown-item:after{top:calc(-1 * var(--kbq-size-3xs));bottom:calc(-1 * var(--kbq-size-3xs))}.kbq-dropdown__panel .kbq-dropdown-item.kbq-progress:after{background:none;animation:none}.kbq-dropdown__panel .kbq-divider{margin-left:calc(var(--kbq-size-xxs) * -1);margin-right:calc(var(--kbq-size-xxs) * -1)}.kbq-dropdown__content{display:flex;flex-direction:column;padding:var(--kbq-size-xxs)}.kbq-dropdown-footer{border-color:var(--kbq-line-contrast-less)}.kbq-dropdown__panel{box-shadow:var(--kbq-dropdown-container-shadow);background:var(--kbq-dropdown-container-background)}.kbq-dropdown-item{background:var(--kbq-list-default-container-background);color:var(--kbq-list-default-text-color)}.kbq-dropdown-item .kbq-icon.kbq-empty:not(.kbq-icon-button,.kbq-icon-item){color:var(--kbq-list-default-text-color)}.kbq-dropdown-item .kbq-dropdown-item__caption{color:var(--kbq-dropdown-item-caption-color)}.kbq-dropdown-item.kbq-dropdown-item_highlighted,.kbq-dropdown-item.kbq-dropdown-item_active:not(.kbq-disabled),.kbq-dropdown-item.cdk-focused:not(.kbq-disabled){background:var(--kbq-list-states-hover-container-background);color:var(--kbq-list-states-hover-text-color)}.kbq-dropdown-item.kbq-dropdown-item_highlighted .kbq-icon.kbq-empty:not(.kbq-icon-button,.kbq-icon-item),.kbq-dropdown-item.kbq-dropdown-item_active:not(.kbq-disabled) .kbq-icon.kbq-empty:not(.kbq-icon-button,.kbq-icon-item),.kbq-dropdown-item.cdk-focused:not(.kbq-disabled) .kbq-icon.kbq-empty:not(.kbq-icon-button,.kbq-icon-item){color:var(--kbq-list-states-hover-text-color)}.kbq-dropdown__panel_safe-area-active .kbq-dropdown-item.cdk-focused:not(.kbq-dropdown-item_highlighted,.kbq-selected,.kbq-disabled){background:var(--kbq-list-default-container-background);color:var(--kbq-list-default-text-color)}.kbq-dropdown__panel_safe-area-active .kbq-dropdown-item.cdk-focused:not(.kbq-dropdown-item_highlighted,.kbq-selected,.kbq-disabled) .kbq-icon.kbq-empty:not(.kbq-icon-button,.kbq-icon-item){color:var(--kbq-list-default-text-color)}.kbq-dropdown-item:active:not(.kbq-disabled),.kbq-dropdown-item.kbq-active:not(.kbq-disabled){background:var(--kbq-list-states-active-container-background)}.kbq-dropdown-item.kbq-selected{background:var(--kbq-list-states-selected-container-background);color:var(--kbq-list-states-selected-text-color)}.kbq-dropdown-item.kbq-selected .kbq-icon.kbq-empty:not(.kbq-icon-button,.kbq-icon-item){color:var(--kbq-list-states-selected-text-color)}.kbq-dropdown-item.kbq-selected.kbq-dropdown-item_active:not(.kbq-disabled),.kbq-dropdown-item.kbq-selected.cdk-focused:not(.kbq-disabled){background:var(--kbq-list-states-selected-hover-container-background);color:var(--kbq-list-states-selected-hover-text-color)}.kbq-dropdown-item.kbq-selected.kbq-dropdown-item_active:not(.kbq-disabled) .kbq-icon.kbq-empty:not(.kbq-icon-button,.kbq-icon-item),.kbq-dropdown-item.kbq-selected.cdk-focused:not(.kbq-disabled) .kbq-icon.kbq-empty:not(.kbq-icon-button,.kbq-icon-item){color:var(--kbq-list-states-selected-hover-text-color)}.kbq-dropdown-item.kbq-selected:active:not(.kbq-disabled),.kbq-dropdown-item.kbq-selected.kbq-active:not(.kbq-disabled){background:var(--kbq-list-states-selected-active-container-background)}.kbq-dropdown-item.kbq-disabled{background:var(--kbq-list-states-disabled-container-background);color:var(--kbq-list-states-disabled-text-color)}.kbq-dropdown-item.kbq-disabled .kbq-icon.kbq-empty:not(.kbq-icon-button,.kbq-icon-item){color:var(--kbq-list-states-disabled-text-color)}.kbq-dropdown-item:is(.kbq-selected,.cdk-focused,.kbq-dropdown-item_active):has(+:is(.kbq-selected,.cdk-focused,.kbq-dropdown-item_active)){border-bottom-left-radius:0;border-bottom-right-radius:0}.kbq-dropdown-item:is(.kbq-selected,.cdk-focused,.kbq-dropdown-item_active)+:is(.kbq-selected,.cdk-focused,.kbq-dropdown-item_active){border-top-left-radius:0;border-top-right-radius:0}.kbq-dropdown-item-overlay{background:transparent}.kbq-dropdown-item,.kbq-dropdown__content{font-size:var(--kbq-typography-text-normal-font-size);font-style:var(--kbq-typography-text-normal-font-style);font-weight:var(--kbq-typography-text-normal-font-weight);line-height:var(--kbq-typography-text-normal-line-height);font-family:var(--kbq-typography-text-normal-font-family);text-transform:var(--kbq-typography-text-normal-text-transform);font-feature-settings:var(--kbq-typography-text-normal-font-feature-settings);letter-spacing:var(--kbq-typography-text-normal-letter-spacing)}.kbq-dropdown-item .kbq-dropdown-item__caption,.kbq-dropdown__content .kbq-dropdown-item__caption{font-size:var(--kbq-typography-text-compact-font-size);font-style:var(--kbq-typography-text-compact-font-style);font-weight:var(--kbq-typography-text-compact-font-weight);line-height:var(--kbq-typography-text-compact-line-height);font-family:var(--kbq-typography-text-compact-font-family);text-transform:var(--kbq-typography-text-compact-text-transform);font-feature-settings:var(--kbq-typography-text-compact-font-feature-settings);letter-spacing:var(--kbq-typography-text-compact-letter-spacing)}.kbq-dropdown__group-header{font-size:var(--kbq-typography-big-strong-font-size);font-style:var(--kbq-typography-big-strong-font-style);font-weight:var(--kbq-typography-big-strong-font-weight);line-height:var(--kbq-typography-big-strong-line-height);font-family:var(--kbq-typography-big-strong-font-family);text-transform:var(--kbq-typography-big-strong-text-transform);font-feature-settings:var(--kbq-typography-big-strong-font-feature-settings);letter-spacing:var(--kbq-typography-big-strong-letter-spacing)}\n", "@charset \"UTF-8\";.kbq-list,.kbq-list-selection,.kbq-list-option.cdk-drag-preview,.kbq-list-drag-preview_text{--kbq-list-size-container-padding-left: var(--kbq-size-m);--kbq-list-size-container-padding-right: var(--kbq-size-m);--kbq-list-size-container-padding-vertical: var(--kbq-size-xxs);--kbq-list-size-container-content-gap-horizontal: var(--kbq-size-s);--kbq-list-size-container-content-gap-vertical: var(--kbq-size-3xs);--kbq-list-size-container-focus-outline-width: var(--kbq-size-3xs);--kbq-list-default-container-background: transparent;--kbq-list-default-text-color: var(--kbq-foreground-contrast);--kbq-list-default-icon-color: var(--kbq-icon-contrast);--kbq-list-default-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-default-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-states-hover-container-background: var(--kbq-states-background-transparent-hover);--kbq-list-states-active-container-background: var(--kbq-states-background-transparent-active);--kbq-list-states-hover-text-color: var(--kbq-foreground-contrast);--kbq-list-states-hover-icon-color: var(--kbq-icon-contrast);--kbq-list-states-hover-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-states-hover-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-states-selected-container-background: var(--kbq-background-theme-less);--kbq-list-multiple-states-selected-container-background: var(--kbq-background-contrast-less);--kbq-list-states-selected-text-color: var(--kbq-foreground-contrast);--kbq-list-states-selected-icon-color: var(--kbq-icon-contrast);--kbq-list-states-selected-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-states-selected-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-multiple-states-selected-text-color: var(--kbq-foreground-contrast);--kbq-list-multiple-states-selected-icon-color: var(--kbq-icon-contrast);--kbq-list-multiple-states-selected-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-multiple-states-selected-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-states-selected-hover-container-background: var(--kbq-states-background-theme-less-hover);--kbq-list-multiple-states-selected-hover-container-background: var(--kbq-states-background-contrast-less-hover);--kbq-list-states-selected-active-container-background: var(--kbq-states-background-theme-less-active);--kbq-list-multiple-states-selected-active-container-background: var(--kbq-states-background-contrast-less-active);--kbq-list-states-selected-hover-text-color: var(--kbq-foreground-contrast);--kbq-list-states-selected-hover-icon-color: var(--kbq-icon-contrast);--kbq-list-states-selected-hover-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-states-selected-hover-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-multiple-states-selected-hover-text-color: var(--kbq-foreground-contrast);--kbq-list-multiple-states-selected-hover-icon-color: var(--kbq-icon-contrast);--kbq-list-multiple-states-selected-hover-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-multiple-states-selected-hover-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-states-focused-focus-outline-color: var(--kbq-states-line-focus-theme);--kbq-list-states-disabled-container-background: transparent;--kbq-list-states-disabled-text-color: var(--kbq-states-foreground-disabled);--kbq-list-states-disabled-icon-color: var(--kbq-states-icon-disabled);--kbq-list-states-disabled-icon-button-color: var(--kbq-states-icon-disabled);--kbq-list-states-disabled-caption-color: var(--kbq-states-foreground-disabled);--kbq-list-states-dragged-container-background: var(--kbq-background-card);--kbq-list-states-dragged-container-shadow: var(--kbq-shadow-popup)}.kbq-list-selection{--kbq-list-size-dragged-indicator-thickness: var(--kbq-size-3xs);--kbq-list-states-dragged-indicator-color: var(--kbq-line-theme)}.kbq-list-drag-preview_text{--kbq-list-size-drag-preview-max-width: 480px;--kbq-list-states-drag-preview-background: color-mix( in srgb, var(--kbq-background-card) calc(var(--kbq-opacity-overlay) * 100%), transparent )}.kbq-dropdown__panel{--kbq-dropdown-size-container-width-min: 200px;--kbq-dropdown-size-container-width-max: var(--kbq-panel-size-width-max, 640px);--kbq-dropdown-size-container-padding-vertical: var(--kbq-size-xxs);--kbq-dropdown-size-container-border-radius: var(--kbq-size-s);--kbq-dropdown-container-background: var(--kbq-background-card);--kbq-dropdown-container-shadow: var(--kbq-shadow-popup);--kbq-dropdown-item-border-radius: var(--kbq-size-xs);--kbq-dropdown-item-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-default-container-background: transparent;--kbq-list-default-text-color: var(--kbq-foreground-contrast);--kbq-list-default-icon-color: var(--kbq-icon-contrast);--kbq-list-default-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-default-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-states-hover-container-background: var(--kbq-states-background-transparent-hover);--kbq-list-states-active-container-background: var(--kbq-states-background-transparent-active);--kbq-list-states-hover-text-color: var(--kbq-foreground-contrast);--kbq-list-states-hover-icon-color: var(--kbq-icon-contrast);--kbq-list-states-hover-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-states-hover-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-states-selected-container-background: var(--kbq-background-theme-less);--kbq-list-multiple-states-selected-container-background: var(--kbq-background-contrast-less);--kbq-list-states-selected-text-color: var(--kbq-foreground-contrast);--kbq-list-states-selected-icon-color: var(--kbq-icon-contrast);--kbq-list-states-selected-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-states-selected-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-multiple-states-selected-text-color: var(--kbq-foreground-contrast);--kbq-list-multiple-states-selected-icon-color: var(--kbq-icon-contrast);--kbq-list-multiple-states-selected-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-multiple-states-selected-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-states-selected-hover-container-background: var(--kbq-states-background-theme-less-hover);--kbq-list-multiple-states-selected-hover-container-background: var(--kbq-states-background-contrast-less-hover);--kbq-list-states-selected-active-container-background: var(--kbq-states-background-theme-less-active);--kbq-list-multiple-states-selected-active-container-background: var(--kbq-states-background-contrast-less-active);--kbq-list-states-selected-hover-text-color: var(--kbq-foreground-contrast);--kbq-list-states-selected-hover-icon-color: var(--kbq-icon-contrast);--kbq-list-states-selected-hover-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-states-selected-hover-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-multiple-states-selected-hover-text-color: var(--kbq-foreground-contrast);--kbq-list-multiple-states-selected-hover-icon-color: var(--kbq-icon-contrast);--kbq-list-multiple-states-selected-hover-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-multiple-states-selected-hover-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-states-focused-focus-outline-color: var(--kbq-states-line-focus-theme);--kbq-list-states-disabled-container-background: transparent;--kbq-list-states-disabled-text-color: var(--kbq-states-foreground-disabled);--kbq-list-states-disabled-icon-color: var(--kbq-states-icon-disabled);--kbq-list-states-disabled-icon-button-color: var(--kbq-states-icon-disabled);--kbq-list-states-disabled-caption-color: var(--kbq-states-foreground-disabled);--kbq-list-states-dragged-container-background: var(--kbq-background-card);--kbq-list-states-dragged-container-shadow: var(--kbq-shadow-popup)}\n"], dependencies: [{ kind: "directive", type: KbqScrollbarViewport, selector: "[kbqScrollbarViewport]", inputs: ["kbqScrollbarMode", "kbqScrollbarHideDelay"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
1147
1229
  }
1148
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.30", ngImport: i0, type: KbqDropdown, decorators: [{
1230
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: KbqDropdown, decorators: [{
1149
1231
  type: Component,
1150
- args: [{ selector: 'kbq-dropdown', imports: [], providers: [
1232
+ args: [{ selector: 'kbq-dropdown', imports: [KbqScrollbarViewport], providers: [
1151
1233
  { provide: KBQ_DROPDOWN_PANEL, useExisting: KbqDropdown }
1152
1234
  ], changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, host: {
1153
1235
  // Remove the TemplatePortal host box from layout while keeping kbqDropdownStaticContent in the document flow.
1154
1236
  style: 'display: contents'
1155
- }, animations: [
1156
- kbqDropdownAnimations.transformDropdown,
1157
- kbqDropdownAnimations.fadeInItems
1158
- ], exportAs: 'kbqDropdown', template: "<ng-template>\n <div\n tabindex=\"-1\"\n class=\"kbq-dropdown__panel\"\n [class.kbq-dropdown__panel_nested]=\"parent\"\n [class]=\"classList\"\n [style.max-width.px]=\"panelMaxWidth()\"\n [style.--kbq-dropdown-size-container-width-min]=\"panelMinWidthToken()\"\n [@transformDropdown]=\"panelAnimationState\"\n (@transformDropdown.done)=\"onAnimationDone($event)\"\n (@transformDropdown.start)=\"onAnimationStart($event)\"\n (click)=\"close()\"\n (keydown)=\"handleKeydown($event)\"\n >\n <div class=\"kbq-dropdown__content\">\n <ng-content />\n </div>\n <ng-content select=\"[kbqDropdownFooter], kbq-dropdown-footer\" />\n </div>\n</ng-template>\n\n<ng-content select=\"[kbqDropdownStaticContent]\" />\n", styles: [".kbq-dropdown-footer{-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;display:flex;align-items:center;box-sizing:border-box;min-height:var(--kbq-select-footer-size-min-height, var(--kbq-size-4xl));border-top-width:var(--kbq-select-footer-size-border-width, var(--kbq-size-border-width));border-top-style:solid;padding:var(--kbq-select-footer-size-padding-vertical, var(--kbq-size-xxs)) var(--kbq-select-footer-size-padding-horizontal, var(--kbq-size-l))}.kbq-dropdown-trigger.kbq-button{padding-left:calc(var(--kbq-dropdown-trigger-horizontal-padding, 10px) - var(--kbq-size-border-width));padding-right:calc(var(--kbq-dropdown-trigger-horizontal-padding, 10px) - var(--kbq-size-border-width))}.kbq-dropdown-trigger.kbq-button .kbq-icon_left{margin-right:var(--kbq-size-xs)}.kbq-dropdown-trigger.kbq-button .kbq-icon_right{margin-left:var(--kbq-size-3xs)}.kbq-dropdown-trigger.kbq-button-icon.kbq-button-icon_right.kbq-button-icon_left .kbq-icon_left{margin-right:0}.kbq-dropdown-trigger.kbq-button-icon.kbq-button-icon_right.kbq-button-icon_left .kbq-icon_right{margin-left:0}.kbq-dropdown-trigger__icon{margin-left:auto;align-self:center}.kbq-dropdown__panel{outline:none;overflow-x:hidden;overflow-y:auto;min-width:max(var(--kbq-dropdown-size-container-width-min),100%);max-width:var(--kbq-dropdown-size-container-width-max);border-radius:var(--kbq-dropdown-size-container-border-radius);box-sizing:border-box}.kbq-dropdown__panel.ng-animating{pointer-events:none}.kbq-dropdown__panel .kbq-dropdown-item{position:relative}.kbq-dropdown__panel .kbq-dropdown-item:before,.kbq-dropdown__panel .kbq-dropdown-item:after{position:absolute;content:\"\";width:var(--kbq-size-xxs);height:calc(100% + var(--kbq-size-3xs) * 2)}.kbq-dropdown__panel .kbq-dropdown-item:before{right:calc(100% + var(--kbq-size-3xs))}.kbq-dropdown__panel .kbq-dropdown-item:after{left:calc(100% + var(--kbq-size-3xs))}.kbq-dropdown__panel .kbq-dropdown-item:before,.kbq-dropdown__panel .kbq-dropdown-item:after{top:calc(-1 * var(--kbq-size-3xs));bottom:calc(-1 * var(--kbq-size-3xs))}.kbq-dropdown__panel .kbq-dropdown-item.kbq-progress:after{background:none;animation:none}.kbq-dropdown__panel .kbq-divider{margin-left:calc(var(--kbq-size-xxs) * -1);margin-right:calc(var(--kbq-size-xxs) * -1)}.kbq-dropdown__content{display:flex;flex-direction:column;padding:var(--kbq-size-xxs)}.kbq-dropdown-footer{border-color:var(--kbq-line-contrast-less)}.kbq-dropdown__panel{box-shadow:var(--kbq-dropdown-container-shadow);background:var(--kbq-dropdown-container-background)}.kbq-dropdown-item{background:var(--kbq-list-default-container-background);color:var(--kbq-list-default-text-color)}.kbq-dropdown-item .kbq-icon.kbq-empty:not(.kbq-icon-button,.kbq-icon-item){color:var(--kbq-list-default-text-color)}.kbq-dropdown-item .kbq-dropdown-item__caption{color:var(--kbq-dropdown-item-caption-color)}.kbq-dropdown-item.kbq-dropdown-item_highlighted,.kbq-dropdown-item.kbq-dropdown-item_active:not(.kbq-disabled),.kbq-dropdown-item.cdk-focused:not(.kbq-disabled){background:var(--kbq-list-states-hover-container-background);color:var(--kbq-list-states-hover-text-color)}.kbq-dropdown-item.kbq-dropdown-item_highlighted .kbq-icon.kbq-empty:not(.kbq-icon-button,.kbq-icon-item),.kbq-dropdown-item.kbq-dropdown-item_active:not(.kbq-disabled) .kbq-icon.kbq-empty:not(.kbq-icon-button,.kbq-icon-item),.kbq-dropdown-item.cdk-focused:not(.kbq-disabled) .kbq-icon.kbq-empty:not(.kbq-icon-button,.kbq-icon-item){color:var(--kbq-list-states-hover-text-color)}.kbq-dropdown-item .kbq-dropdown__panel_safe-area-active.cdk-focused:not(.kbq-dropdown-item_highlighted,.kbq-selected,.kbq-disabled){background:var(--kbq-list-default-container-background);color:var(--kbq-list-default-text-color)}.kbq-dropdown-item .kbq-dropdown__panel_safe-area-active.cdk-focused:not(.kbq-dropdown-item_highlighted,.kbq-selected,.kbq-disabled) .kbq-icon.kbq-empty:not(.kbq-icon-button,.kbq-icon-item){color:var(--kbq-list-default-text-color)}.kbq-dropdown-item:active:not(.kbq-disabled),.kbq-dropdown-item.kbq-active:not(.kbq-disabled){background:var(--kbq-list-states-active-container-background)}.kbq-dropdown-item.kbq-selected{background:var(--kbq-list-states-selected-container-background);color:var(--kbq-list-states-selected-text-color)}.kbq-dropdown-item.kbq-selected .kbq-icon.kbq-empty:not(.kbq-icon-button,.kbq-icon-item){color:var(--kbq-list-states-selected-text-color)}.kbq-dropdown-item.kbq-selected.kbq-dropdown-item_active:not(.kbq-disabled),.kbq-dropdown-item.kbq-selected.cdk-focused:not(.kbq-disabled){background:var(--kbq-list-states-selected-hover-container-background);color:var(--kbq-list-states-selected-hover-text-color)}.kbq-dropdown-item.kbq-selected.kbq-dropdown-item_active:not(.kbq-disabled) .kbq-icon.kbq-empty:not(.kbq-icon-button,.kbq-icon-item),.kbq-dropdown-item.kbq-selected.cdk-focused:not(.kbq-disabled) .kbq-icon.kbq-empty:not(.kbq-icon-button,.kbq-icon-item){color:var(--kbq-list-states-selected-hover-text-color)}.kbq-dropdown-item.kbq-selected:active:not(.kbq-disabled),.kbq-dropdown-item.kbq-selected.kbq-active:not(.kbq-disabled){background:var(--kbq-list-states-selected-active-container-background)}.kbq-dropdown-item.kbq-disabled{background:var(--kbq-list-states-disabled-container-background);color:var(--kbq-list-states-disabled-text-color)}.kbq-dropdown-item.kbq-disabled .kbq-icon.kbq-empty:not(.kbq-icon-button,.kbq-icon-item){color:var(--kbq-list-states-disabled-text-color)}.kbq-dropdown-item:is(.kbq-selected,.cdk-focused,.kbq-dropdown-item_active):has(+:is(.kbq-selected,.cdk-focused,.kbq-dropdown-item_active)){border-bottom-left-radius:0;border-bottom-right-radius:0}.kbq-dropdown-item:is(.kbq-selected,.cdk-focused,.kbq-dropdown-item_active)+:is(.kbq-selected,.cdk-focused,.kbq-dropdown-item_active){border-top-left-radius:0;border-top-right-radius:0}.kbq-dropdown__group-header.kbq-dropdown__group-header_small{color:var(--kbq-foreground-contrast-secondary)}.kbq-dropdown-item-overlay{background:transparent}.kbq-dropdown-item,.kbq-dropdown__content{font-size:var(--kbq-typography-text-normal-font-size);font-style:var(--kbq-typography-text-normal-font-style);font-weight:var(--kbq-typography-text-normal-font-weight);line-height:var(--kbq-typography-text-normal-line-height);font-family:var(--kbq-typography-text-normal-font-family);text-transform:var(--kbq-typography-text-normal-text-transform);font-feature-settings:var(--kbq-typography-text-normal-font-feature-settings);letter-spacing:var(--kbq-typography-text-normal-letter-spacing)}.kbq-dropdown-item .kbq-dropdown-item__caption,.kbq-dropdown__content .kbq-dropdown-item__caption{font-size:var(--kbq-typography-text-compact-font-size);font-style:var(--kbq-typography-text-compact-font-style);font-weight:var(--kbq-typography-text-compact-font-weight);line-height:var(--kbq-typography-text-compact-line-height);font-family:var(--kbq-typography-text-compact-font-family);text-transform:var(--kbq-typography-text-compact-text-transform);font-feature-settings:var(--kbq-typography-text-compact-font-feature-settings);letter-spacing:var(--kbq-typography-text-compact-letter-spacing)}.kbq-dropdown__group-header{font-size:var(--kbq-typography-big-strong-font-size);font-style:var(--kbq-typography-big-strong-font-style);font-weight:var(--kbq-typography-big-strong-font-weight);line-height:var(--kbq-typography-big-strong-line-height);font-family:var(--kbq-typography-big-strong-font-family);text-transform:var(--kbq-typography-big-strong-text-transform);font-feature-settings:var(--kbq-typography-big-strong-font-feature-settings);letter-spacing:var(--kbq-typography-big-strong-letter-spacing)}.kbq-dropdown__group-header.kbq-dropdown__group-header_small{font-size:var(--kbq-typography-caps-compact-strong-font-size);font-style:var(--kbq-typography-caps-compact-strong-font-style);font-weight:var(--kbq-typography-caps-compact-strong-font-weight);line-height:var(--kbq-typography-caps-compact-strong-line-height);font-family:var(--kbq-typography-caps-compact-strong-font-family);text-transform:var(--kbq-typography-caps-compact-strong-text-transform);font-feature-settings:var(--kbq-typography-caps-compact-strong-font-feature-settings);letter-spacing:var(--kbq-typography-caps-compact-strong-letter-spacing)}\n", "@charset \"UTF-8\";.kbq-list,.kbq-list-selection,.kbq-list-option.cdk-drag-preview,.kbq-list-drag-preview_text{--kbq-list-size-container-padding-left: var(--kbq-size-m);--kbq-list-size-container-padding-right: var(--kbq-size-m);--kbq-list-size-container-padding-vertical: var(--kbq-size-xxs);--kbq-list-size-container-content-gap-horizontal: var(--kbq-size-s);--kbq-list-size-container-content-gap-vertical: var(--kbq-size-3xs);--kbq-list-size-container-focus-outline-width: var(--kbq-size-3xs);--kbq-list-default-container-background: transparent;--kbq-list-default-text-color: var(--kbq-foreground-contrast);--kbq-list-default-icon-color: var(--kbq-icon-contrast);--kbq-list-default-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-default-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-states-hover-container-background: var(--kbq-states-background-transparent-hover);--kbq-list-states-active-container-background: var(--kbq-states-background-transparent-active);--kbq-list-states-hover-text-color: var(--kbq-foreground-contrast);--kbq-list-states-hover-icon-color: var(--kbq-icon-contrast);--kbq-list-states-hover-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-states-hover-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-states-selected-container-background: var(--kbq-background-theme-less);--kbq-list-multiple-states-selected-container-background: var(--kbq-background-contrast-less);--kbq-list-states-selected-text-color: var(--kbq-foreground-contrast);--kbq-list-states-selected-icon-color: var(--kbq-icon-contrast);--kbq-list-states-selected-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-states-selected-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-multiple-states-selected-text-color: var(--kbq-foreground-contrast);--kbq-list-multiple-states-selected-icon-color: var(--kbq-icon-contrast);--kbq-list-multiple-states-selected-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-multiple-states-selected-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-states-selected-hover-container-background: var(--kbq-states-background-theme-less-hover);--kbq-list-multiple-states-selected-hover-container-background: var(--kbq-states-background-contrast-less-hover);--kbq-list-states-selected-active-container-background: var(--kbq-states-background-theme-less-active);--kbq-list-multiple-states-selected-active-container-background: var(--kbq-states-background-contrast-less-active);--kbq-list-states-selected-hover-text-color: var(--kbq-foreground-contrast);--kbq-list-states-selected-hover-icon-color: var(--kbq-icon-contrast);--kbq-list-states-selected-hover-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-states-selected-hover-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-multiple-states-selected-hover-text-color: var(--kbq-foreground-contrast);--kbq-list-multiple-states-selected-hover-icon-color: var(--kbq-icon-contrast);--kbq-list-multiple-states-selected-hover-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-multiple-states-selected-hover-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-states-focused-focus-outline-color: var(--kbq-states-line-focus-theme);--kbq-list-states-disabled-container-background: transparent;--kbq-list-states-disabled-text-color: var(--kbq-states-foreground-disabled);--kbq-list-states-disabled-icon-color: var(--kbq-states-icon-disabled);--kbq-list-states-disabled-icon-button-color: var(--kbq-states-icon-disabled);--kbq-list-states-disabled-caption-color: var(--kbq-states-foreground-disabled);--kbq-list-states-dragged-container-background: var(--kbq-background-card);--kbq-list-states-dragged-container-shadow: var(--kbq-shadow-popup)}.kbq-list-selection{--kbq-list-size-dragged-indicator-thickness: var(--kbq-size-3xs);--kbq-list-states-dragged-indicator-color: var(--kbq-line-theme)}.kbq-list-drag-preview_text{--kbq-list-size-drag-preview-max-width: 480px;--kbq-list-states-drag-preview-background: color-mix( in srgb, var(--kbq-background-card) calc(var(--kbq-opacity-overlay) * 100%), transparent )}.kbq-dropdown__panel{--kbq-dropdown-size-container-width-min: 200px;--kbq-dropdown-size-container-width-max: var(--kbq-panel-size-width-max, 640px);--kbq-dropdown-size-container-padding-vertical: var(--kbq-size-xxs);--kbq-dropdown-size-container-border-radius: var(--kbq-size-s);--kbq-dropdown-container-background: var(--kbq-background-card);--kbq-dropdown-container-shadow: var(--kbq-shadow-popup);--kbq-dropdown-item-border-radius: var(--kbq-size-xs);--kbq-dropdown-item-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-default-container-background: transparent;--kbq-list-default-text-color: var(--kbq-foreground-contrast);--kbq-list-default-icon-color: var(--kbq-icon-contrast);--kbq-list-default-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-default-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-states-hover-container-background: var(--kbq-states-background-transparent-hover);--kbq-list-states-active-container-background: var(--kbq-states-background-transparent-active);--kbq-list-states-hover-text-color: var(--kbq-foreground-contrast);--kbq-list-states-hover-icon-color: var(--kbq-icon-contrast);--kbq-list-states-hover-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-states-hover-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-states-selected-container-background: var(--kbq-background-theme-less);--kbq-list-multiple-states-selected-container-background: var(--kbq-background-contrast-less);--kbq-list-states-selected-text-color: var(--kbq-foreground-contrast);--kbq-list-states-selected-icon-color: var(--kbq-icon-contrast);--kbq-list-states-selected-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-states-selected-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-multiple-states-selected-text-color: var(--kbq-foreground-contrast);--kbq-list-multiple-states-selected-icon-color: var(--kbq-icon-contrast);--kbq-list-multiple-states-selected-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-multiple-states-selected-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-states-selected-hover-container-background: var(--kbq-states-background-theme-less-hover);--kbq-list-multiple-states-selected-hover-container-background: var(--kbq-states-background-contrast-less-hover);--kbq-list-states-selected-active-container-background: var(--kbq-states-background-theme-less-active);--kbq-list-multiple-states-selected-active-container-background: var(--kbq-states-background-contrast-less-active);--kbq-list-states-selected-hover-text-color: var(--kbq-foreground-contrast);--kbq-list-states-selected-hover-icon-color: var(--kbq-icon-contrast);--kbq-list-states-selected-hover-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-states-selected-hover-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-multiple-states-selected-hover-text-color: var(--kbq-foreground-contrast);--kbq-list-multiple-states-selected-hover-icon-color: var(--kbq-icon-contrast);--kbq-list-multiple-states-selected-hover-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-multiple-states-selected-hover-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-states-focused-focus-outline-color: var(--kbq-states-line-focus-theme);--kbq-list-states-disabled-container-background: transparent;--kbq-list-states-disabled-text-color: var(--kbq-states-foreground-disabled);--kbq-list-states-disabled-icon-color: var(--kbq-states-icon-disabled);--kbq-list-states-disabled-icon-button-color: var(--kbq-states-icon-disabled);--kbq-list-states-disabled-caption-color: var(--kbq-states-foreground-disabled);--kbq-list-states-dragged-container-background: var(--kbq-background-card);--kbq-list-states-dragged-container-shadow: var(--kbq-shadow-popup)}\n"] }]
1159
- }], ctorParameters: () => [], propDecorators: { panelFormField: [{ type: i0.ContentChild, args: [i0.forwardRef(() => KbqFormField), { isSignal: true }] }], searches: [{ type: i0.ContentChildren, args: [i0.forwardRef(() => KbqDropdownSearch), { ...{ descendants: true }, isSignal: true }] }], navigationWithWrap: [{ type: i0.Input, args: [{ isSignal: true, alias: "navigationWithWrap", required: false }] }], xPosition: [{
1160
- type: Input
1161
- }], yPosition: [{
1162
- type: Input
1163
- }], overlapTriggerY: [{
1164
- type: Input
1165
- }], overlapTriggerX: [{
1166
- type: Input
1167
- }], hasBackdrop: [{
1168
- type: Input
1169
- }], panelClass: [{
1170
- type: Input,
1171
- args: ['class']
1172
- }], backdropClass: [{
1173
- type: Input
1174
- }], panelWidth: [{ type: i0.Input, args: [{ isSignal: true, alias: "panelWidth", required: false }] }], panelMinWidth: [{ type: i0.Input, args: [{ isSignal: true, alias: "panelMinWidth", required: false }] }], panelMaxWidth: [{ type: i0.Input, args: [{ isSignal: true, alias: "panelMaxWidth", required: false }] }], safeArea: [{ type: i0.Input, args: [{ isSignal: true, alias: "safeArea", required: false }] }], templateRef: [{
1175
- type: ViewChild,
1176
- args: [TemplateRef, { static: false }]
1177
- }], items: [{
1178
- type: ContentChildren,
1179
- args: [KbqDropdownItem, { descendants: true }]
1180
- }], lazyContent: [{
1181
- type: ContentChild,
1182
- args: [KbqDropdownContent, { static: false }]
1183
- }], closed: [{
1184
- type: Output
1185
- }] } });
1237
+ }, exportAs: 'kbqDropdown', template: "<ng-template>\n <div\n kbqScrollbarViewport\n tabindex=\"-1\"\n class=\"kbq-dropdown__panel\"\n [class.kbq-dropdown__panel_nested]=\"parent\"\n [class]=\"classList()\"\n [style.max-width.px]=\"panelMaxWidth()\"\n [style.--kbq-dropdown-size-container-width-min]=\"panelMinWidthToken()\"\n (keydown)=\"handleKeydown($event)\"\n >\n <!-- Scoped to the options content: a click on a footer control must not close the panel. -->\n <div class=\"kbq-dropdown__content\" (click)=\"close()\">\n <ng-content />\n </div>\n <ng-content select=\"[kbqDropdownFooter], kbq-dropdown-footer\" />\n </div>\n</ng-template>\n\n<ng-content select=\"[kbqDropdownStaticContent]\" />\n", styles: [".kbq-dropdown-footer{-webkit-user-select:none;user-select:none;display:flex;align-items:center;box-sizing:border-box;min-height:var(--kbq-select-footer-size-min-height, var(--kbq-size-4xl));border-top-width:var(--kbq-select-footer-size-border-width, var(--kbq-size-border-width));border-top-style:solid;padding:var(--kbq-select-footer-size-padding-vertical, var(--kbq-size-xxs)) var(--kbq-select-footer-size-padding-horizontal, var(--kbq-size-l))}.kbq-dropdown-trigger.kbq-button{padding-left:calc(var(--kbq-dropdown-trigger-horizontal-padding, 10px) - var(--kbq-size-border-width));padding-right:calc(var(--kbq-dropdown-trigger-horizontal-padding, 10px) - var(--kbq-size-border-width))}.kbq-dropdown-trigger.kbq-button .kbq-icon_left{margin-right:var(--kbq-size-xs)}.kbq-dropdown-trigger.kbq-button .kbq-icon_right{margin-left:var(--kbq-size-3xs)}.kbq-dropdown-trigger.kbq-button-icon.kbq-button-icon_right.kbq-button-icon_left .kbq-icon_left{margin-right:0}.kbq-dropdown-trigger.kbq-button-icon.kbq-button-icon_right.kbq-button-icon_left .kbq-icon_right{margin-left:0}.kbq-dropdown-trigger__icon{margin-left:auto;align-self:center}.kbq-dropdown__panel{outline:none;overflow-x:hidden;overflow-y:auto;min-width:max(var(--kbq-dropdown-size-container-width-min),100%);max-width:var(--kbq-dropdown-size-container-width-max);border-radius:var(--kbq-dropdown-size-container-border-radius)}@supports (corner-shape: squircle){.kbq-dropdown__panel{corner-shape:squircle;border-radius:clamp(var(--kbq-dropdown-size-container-border-radius) * 1.85,var(--kbq-dropdown-size-container-border-radius) * 2.3 - 3.6px,var(--kbq-dropdown-size-container-border-radius) * 2)}}.kbq-dropdown__panel{box-sizing:border-box}.kbq-dropdown__panel.ng-animating{pointer-events:none}.kbq-dropdown__panel .kbq-dropdown-item{position:relative}.kbq-dropdown__panel .kbq-dropdown-item:before,.kbq-dropdown__panel .kbq-dropdown-item:after{position:absolute;content:\"\";width:var(--kbq-size-xxs);height:calc(100% + var(--kbq-size-3xs) * 2)}.kbq-dropdown__panel .kbq-dropdown-item:before{right:calc(100% + var(--kbq-size-3xs))}.kbq-dropdown__panel .kbq-dropdown-item:after{left:calc(100% + var(--kbq-size-3xs))}.kbq-dropdown__panel .kbq-dropdown-item:before,.kbq-dropdown__panel .kbq-dropdown-item:after{top:calc(-1 * var(--kbq-size-3xs));bottom:calc(-1 * var(--kbq-size-3xs))}.kbq-dropdown__panel .kbq-dropdown-item.kbq-progress:after{background:none;animation:none}.kbq-dropdown__panel .kbq-divider{margin-left:calc(var(--kbq-size-xxs) * -1);margin-right:calc(var(--kbq-size-xxs) * -1)}.kbq-dropdown__content{display:flex;flex-direction:column;padding:var(--kbq-size-xxs)}.kbq-dropdown-footer{border-color:var(--kbq-line-contrast-less)}.kbq-dropdown__panel{box-shadow:var(--kbq-dropdown-container-shadow);background:var(--kbq-dropdown-container-background)}.kbq-dropdown-item{background:var(--kbq-list-default-container-background);color:var(--kbq-list-default-text-color)}.kbq-dropdown-item .kbq-icon.kbq-empty:not(.kbq-icon-button,.kbq-icon-item){color:var(--kbq-list-default-text-color)}.kbq-dropdown-item .kbq-dropdown-item__caption{color:var(--kbq-dropdown-item-caption-color)}.kbq-dropdown-item.kbq-dropdown-item_highlighted,.kbq-dropdown-item.kbq-dropdown-item_active:not(.kbq-disabled),.kbq-dropdown-item.cdk-focused:not(.kbq-disabled){background:var(--kbq-list-states-hover-container-background);color:var(--kbq-list-states-hover-text-color)}.kbq-dropdown-item.kbq-dropdown-item_highlighted .kbq-icon.kbq-empty:not(.kbq-icon-button,.kbq-icon-item),.kbq-dropdown-item.kbq-dropdown-item_active:not(.kbq-disabled) .kbq-icon.kbq-empty:not(.kbq-icon-button,.kbq-icon-item),.kbq-dropdown-item.cdk-focused:not(.kbq-disabled) .kbq-icon.kbq-empty:not(.kbq-icon-button,.kbq-icon-item){color:var(--kbq-list-states-hover-text-color)}.kbq-dropdown__panel_safe-area-active .kbq-dropdown-item.cdk-focused:not(.kbq-dropdown-item_highlighted,.kbq-selected,.kbq-disabled){background:var(--kbq-list-default-container-background);color:var(--kbq-list-default-text-color)}.kbq-dropdown__panel_safe-area-active .kbq-dropdown-item.cdk-focused:not(.kbq-dropdown-item_highlighted,.kbq-selected,.kbq-disabled) .kbq-icon.kbq-empty:not(.kbq-icon-button,.kbq-icon-item){color:var(--kbq-list-default-text-color)}.kbq-dropdown-item:active:not(.kbq-disabled),.kbq-dropdown-item.kbq-active:not(.kbq-disabled){background:var(--kbq-list-states-active-container-background)}.kbq-dropdown-item.kbq-selected{background:var(--kbq-list-states-selected-container-background);color:var(--kbq-list-states-selected-text-color)}.kbq-dropdown-item.kbq-selected .kbq-icon.kbq-empty:not(.kbq-icon-button,.kbq-icon-item){color:var(--kbq-list-states-selected-text-color)}.kbq-dropdown-item.kbq-selected.kbq-dropdown-item_active:not(.kbq-disabled),.kbq-dropdown-item.kbq-selected.cdk-focused:not(.kbq-disabled){background:var(--kbq-list-states-selected-hover-container-background);color:var(--kbq-list-states-selected-hover-text-color)}.kbq-dropdown-item.kbq-selected.kbq-dropdown-item_active:not(.kbq-disabled) .kbq-icon.kbq-empty:not(.kbq-icon-button,.kbq-icon-item),.kbq-dropdown-item.kbq-selected.cdk-focused:not(.kbq-disabled) .kbq-icon.kbq-empty:not(.kbq-icon-button,.kbq-icon-item){color:var(--kbq-list-states-selected-hover-text-color)}.kbq-dropdown-item.kbq-selected:active:not(.kbq-disabled),.kbq-dropdown-item.kbq-selected.kbq-active:not(.kbq-disabled){background:var(--kbq-list-states-selected-active-container-background)}.kbq-dropdown-item.kbq-disabled{background:var(--kbq-list-states-disabled-container-background);color:var(--kbq-list-states-disabled-text-color)}.kbq-dropdown-item.kbq-disabled .kbq-icon.kbq-empty:not(.kbq-icon-button,.kbq-icon-item){color:var(--kbq-list-states-disabled-text-color)}.kbq-dropdown-item:is(.kbq-selected,.cdk-focused,.kbq-dropdown-item_active):has(+:is(.kbq-selected,.cdk-focused,.kbq-dropdown-item_active)){border-bottom-left-radius:0;border-bottom-right-radius:0}.kbq-dropdown-item:is(.kbq-selected,.cdk-focused,.kbq-dropdown-item_active)+:is(.kbq-selected,.cdk-focused,.kbq-dropdown-item_active){border-top-left-radius:0;border-top-right-radius:0}.kbq-dropdown-item-overlay{background:transparent}.kbq-dropdown-item,.kbq-dropdown__content{font-size:var(--kbq-typography-text-normal-font-size);font-style:var(--kbq-typography-text-normal-font-style);font-weight:var(--kbq-typography-text-normal-font-weight);line-height:var(--kbq-typography-text-normal-line-height);font-family:var(--kbq-typography-text-normal-font-family);text-transform:var(--kbq-typography-text-normal-text-transform);font-feature-settings:var(--kbq-typography-text-normal-font-feature-settings);letter-spacing:var(--kbq-typography-text-normal-letter-spacing)}.kbq-dropdown-item .kbq-dropdown-item__caption,.kbq-dropdown__content .kbq-dropdown-item__caption{font-size:var(--kbq-typography-text-compact-font-size);font-style:var(--kbq-typography-text-compact-font-style);font-weight:var(--kbq-typography-text-compact-font-weight);line-height:var(--kbq-typography-text-compact-line-height);font-family:var(--kbq-typography-text-compact-font-family);text-transform:var(--kbq-typography-text-compact-text-transform);font-feature-settings:var(--kbq-typography-text-compact-font-feature-settings);letter-spacing:var(--kbq-typography-text-compact-letter-spacing)}.kbq-dropdown__group-header{font-size:var(--kbq-typography-big-strong-font-size);font-style:var(--kbq-typography-big-strong-font-style);font-weight:var(--kbq-typography-big-strong-font-weight);line-height:var(--kbq-typography-big-strong-line-height);font-family:var(--kbq-typography-big-strong-font-family);text-transform:var(--kbq-typography-big-strong-text-transform);font-feature-settings:var(--kbq-typography-big-strong-font-feature-settings);letter-spacing:var(--kbq-typography-big-strong-letter-spacing)}\n", "@charset \"UTF-8\";.kbq-list,.kbq-list-selection,.kbq-list-option.cdk-drag-preview,.kbq-list-drag-preview_text{--kbq-list-size-container-padding-left: var(--kbq-size-m);--kbq-list-size-container-padding-right: var(--kbq-size-m);--kbq-list-size-container-padding-vertical: var(--kbq-size-xxs);--kbq-list-size-container-content-gap-horizontal: var(--kbq-size-s);--kbq-list-size-container-content-gap-vertical: var(--kbq-size-3xs);--kbq-list-size-container-focus-outline-width: var(--kbq-size-3xs);--kbq-list-default-container-background: transparent;--kbq-list-default-text-color: var(--kbq-foreground-contrast);--kbq-list-default-icon-color: var(--kbq-icon-contrast);--kbq-list-default-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-default-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-states-hover-container-background: var(--kbq-states-background-transparent-hover);--kbq-list-states-active-container-background: var(--kbq-states-background-transparent-active);--kbq-list-states-hover-text-color: var(--kbq-foreground-contrast);--kbq-list-states-hover-icon-color: var(--kbq-icon-contrast);--kbq-list-states-hover-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-states-hover-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-states-selected-container-background: var(--kbq-background-theme-less);--kbq-list-multiple-states-selected-container-background: var(--kbq-background-contrast-less);--kbq-list-states-selected-text-color: var(--kbq-foreground-contrast);--kbq-list-states-selected-icon-color: var(--kbq-icon-contrast);--kbq-list-states-selected-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-states-selected-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-multiple-states-selected-text-color: var(--kbq-foreground-contrast);--kbq-list-multiple-states-selected-icon-color: var(--kbq-icon-contrast);--kbq-list-multiple-states-selected-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-multiple-states-selected-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-states-selected-hover-container-background: var(--kbq-states-background-theme-less-hover);--kbq-list-multiple-states-selected-hover-container-background: var(--kbq-states-background-contrast-less-hover);--kbq-list-states-selected-active-container-background: var(--kbq-states-background-theme-less-active);--kbq-list-multiple-states-selected-active-container-background: var(--kbq-states-background-contrast-less-active);--kbq-list-states-selected-hover-text-color: var(--kbq-foreground-contrast);--kbq-list-states-selected-hover-icon-color: var(--kbq-icon-contrast);--kbq-list-states-selected-hover-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-states-selected-hover-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-multiple-states-selected-hover-text-color: var(--kbq-foreground-contrast);--kbq-list-multiple-states-selected-hover-icon-color: var(--kbq-icon-contrast);--kbq-list-multiple-states-selected-hover-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-multiple-states-selected-hover-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-states-focused-focus-outline-color: var(--kbq-states-line-focus-theme);--kbq-list-states-disabled-container-background: transparent;--kbq-list-states-disabled-text-color: var(--kbq-states-foreground-disabled);--kbq-list-states-disabled-icon-color: var(--kbq-states-icon-disabled);--kbq-list-states-disabled-icon-button-color: var(--kbq-states-icon-disabled);--kbq-list-states-disabled-caption-color: var(--kbq-states-foreground-disabled);--kbq-list-states-dragged-container-background: var(--kbq-background-card);--kbq-list-states-dragged-container-shadow: var(--kbq-shadow-popup)}.kbq-list-selection{--kbq-list-size-dragged-indicator-thickness: var(--kbq-size-3xs);--kbq-list-states-dragged-indicator-color: var(--kbq-line-theme)}.kbq-list-drag-preview_text{--kbq-list-size-drag-preview-max-width: 480px;--kbq-list-states-drag-preview-background: color-mix( in srgb, var(--kbq-background-card) calc(var(--kbq-opacity-overlay) * 100%), transparent )}.kbq-dropdown__panel{--kbq-dropdown-size-container-width-min: 200px;--kbq-dropdown-size-container-width-max: var(--kbq-panel-size-width-max, 640px);--kbq-dropdown-size-container-padding-vertical: var(--kbq-size-xxs);--kbq-dropdown-size-container-border-radius: var(--kbq-size-s);--kbq-dropdown-container-background: var(--kbq-background-card);--kbq-dropdown-container-shadow: var(--kbq-shadow-popup);--kbq-dropdown-item-border-radius: var(--kbq-size-xs);--kbq-dropdown-item-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-default-container-background: transparent;--kbq-list-default-text-color: var(--kbq-foreground-contrast);--kbq-list-default-icon-color: var(--kbq-icon-contrast);--kbq-list-default-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-default-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-states-hover-container-background: var(--kbq-states-background-transparent-hover);--kbq-list-states-active-container-background: var(--kbq-states-background-transparent-active);--kbq-list-states-hover-text-color: var(--kbq-foreground-contrast);--kbq-list-states-hover-icon-color: var(--kbq-icon-contrast);--kbq-list-states-hover-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-states-hover-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-states-selected-container-background: var(--kbq-background-theme-less);--kbq-list-multiple-states-selected-container-background: var(--kbq-background-contrast-less);--kbq-list-states-selected-text-color: var(--kbq-foreground-contrast);--kbq-list-states-selected-icon-color: var(--kbq-icon-contrast);--kbq-list-states-selected-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-states-selected-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-multiple-states-selected-text-color: var(--kbq-foreground-contrast);--kbq-list-multiple-states-selected-icon-color: var(--kbq-icon-contrast);--kbq-list-multiple-states-selected-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-multiple-states-selected-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-states-selected-hover-container-background: var(--kbq-states-background-theme-less-hover);--kbq-list-multiple-states-selected-hover-container-background: var(--kbq-states-background-contrast-less-hover);--kbq-list-states-selected-active-container-background: var(--kbq-states-background-theme-less-active);--kbq-list-multiple-states-selected-active-container-background: var(--kbq-states-background-contrast-less-active);--kbq-list-states-selected-hover-text-color: var(--kbq-foreground-contrast);--kbq-list-states-selected-hover-icon-color: var(--kbq-icon-contrast);--kbq-list-states-selected-hover-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-states-selected-hover-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-multiple-states-selected-hover-text-color: var(--kbq-foreground-contrast);--kbq-list-multiple-states-selected-hover-icon-color: var(--kbq-icon-contrast);--kbq-list-multiple-states-selected-hover-icon-button-color: var(--kbq-icon-contrast-fade);--kbq-list-multiple-states-selected-hover-caption-color: var(--kbq-foreground-contrast-secondary);--kbq-list-states-focused-focus-outline-color: var(--kbq-states-line-focus-theme);--kbq-list-states-disabled-container-background: transparent;--kbq-list-states-disabled-text-color: var(--kbq-states-foreground-disabled);--kbq-list-states-disabled-icon-color: var(--kbq-states-icon-disabled);--kbq-list-states-disabled-icon-button-color: var(--kbq-states-icon-disabled);--kbq-list-states-disabled-caption-color: var(--kbq-states-foreground-disabled);--kbq-list-states-dragged-container-background: var(--kbq-background-card);--kbq-list-states-dragged-container-shadow: var(--kbq-shadow-popup)}\n"] }]
1238
+ }], ctorParameters: () => [], propDecorators: { panelFormField: [{ type: i0.ContentChild, args: [i0.forwardRef(() => KbqFormField), { isSignal: true }] }], searches: [{ type: i0.ContentChildren, args: [i0.forwardRef(() => KbqDropdownSearch), { ...{ descendants: true }, isSignal: true }] }], activeDescendantNavigation: [{ type: i0.Input, args: [{ isSignal: true, alias: "activeDescendantNavigation", required: false }] }], navigationWithWrap: [{ type: i0.Input, args: [{ isSignal: true, alias: "navigationWithWrap", required: false }] }], xPosition: [{ type: i0.Input, args: [{ isSignal: true, alias: "xPosition", required: false }] }, { type: i0.Output, args: ["xPositionChange"] }], yPosition: [{ type: i0.Input, args: [{ isSignal: true, alias: "yPosition", required: false }] }, { type: i0.Output, args: ["yPositionChange"] }], overlapTriggerY: [{ type: i0.Input, args: [{ isSignal: true, alias: "overlapTriggerY", required: false }] }, { type: i0.Output, args: ["overlapTriggerYChange"] }], overlapTriggerX: [{ type: i0.Input, args: [{ isSignal: true, alias: "overlapTriggerX", required: false }] }, { type: i0.Output, args: ["overlapTriggerXChange"] }], hasBackdrop: [{ type: i0.Input, args: [{ isSignal: true, alias: "hasBackdrop", required: false }] }], panelClass: [{ type: i0.Input, args: [{ isSignal: true, alias: "class", required: false }] }], backdropClass: [{ type: i0.Input, args: [{ isSignal: true, alias: "backdropClass", required: false }] }], panelWidth: [{ type: i0.Input, args: [{ isSignal: true, alias: "panelWidth", required: false }] }], panelMinWidth: [{ type: i0.Input, args: [{ isSignal: true, alias: "panelMinWidth", required: false }] }], panelMaxWidth: [{ type: i0.Input, args: [{ isSignal: true, alias: "panelMaxWidth", required: false }] }], safeArea: [{ type: i0.Input, args: [{ isSignal: true, alias: "safeArea", required: false }] }], templateRef: [{ type: i0.ViewChild, args: [i0.forwardRef(() => TemplateRef), { isSignal: true }] }], scrollbarViewport: [{ type: i0.ViewChild, args: [i0.forwardRef(() => KbqScrollbarViewport), { isSignal: true }] }], queriedItems: [{ type: i0.ContentChildren, args: [i0.forwardRef(() => KbqDropdownItem), { ...{ descendants: true }, isSignal: true }] }], lazyContent: [{ type: i0.ContentChild, args: [i0.forwardRef(() => KbqDropdownContent), { isSignal: true }] }], closed: [{ type: i0.Output, args: ["closed"] }] } });
1186
1239
 
1187
1240
  /**
1188
1241
  * Injection token that determines the scroll handling while the dropdown is open. The root default keeps the
@@ -1190,33 +1243,31 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.30", ngImpo
1190
1243
  */
1191
1244
  const KBQ_DROPDOWN_SCROLL_STRATEGY = new InjectionToken('kbq-dropdown-scroll-strategy', {
1192
1245
  providedIn: 'root',
1193
- factory: () => KBQ_DROPDOWN_SCROLL_STRATEGY_FACTORY(inject(Overlay))
1246
+ factory: () => KBQ_DROPDOWN_SCROLL_STRATEGY_FACTORY(inject(ScrollDispatcher))
1194
1247
  });
1195
1248
  /** @docs-private */
1196
- function KBQ_DROPDOWN_SCROLL_STRATEGY_FACTORY(overlay) {
1197
- return () => overlay.scrollStrategies.reposition();
1249
+ function KBQ_DROPDOWN_SCROLL_STRATEGY_FACTORY(scrollDispatcher) {
1250
+ return kbqRepositionScrollStrategyFactory(scrollDispatcher);
1198
1251
  }
1199
- /** @docs-private */
1252
+ /**
1253
+ * Redundant to the root factory of the token; kept so an app can restore the default under its own override (#DS-2196).
1254
+ *
1255
+ * @docs-private
1256
+ */
1200
1257
  const KBQ_DROPDOWN_SCROLL_STRATEGY_FACTORY_PROVIDER = {
1201
1258
  provide: KBQ_DROPDOWN_SCROLL_STRATEGY,
1202
- deps: [Overlay],
1259
+ deps: [ScrollDispatcher],
1203
1260
  useFactory: KBQ_DROPDOWN_SCROLL_STRATEGY_FACTORY
1204
1261
  };
1205
- /**
1206
- * Marker provided by host components that create their own stacking context at
1207
- * the default overlay z-index (e.g. `KbqTopBar`, `KbqNavbar` use
1208
- * `position: sticky` + `z-index: $overlay-z-index`). When this token is
1209
- * available in the injector tree, `KbqDropdownTrigger` defaults `demoteOverlay`
1210
- * to `false` so the dropdown overlay is not lowered below the host.
1211
- *
1212
- * An explicit `[demoteOverlay]` binding on the trigger still wins.
1213
- */
1214
- const KBQ_DROPDOWN_HOST = new InjectionToken('kbq-dropdown-host');
1215
1262
  /** Default top padding of the nested dropdown panel. */
1216
1263
  const NESTED_PANEL_TOP_PADDING = 4;
1217
1264
  const NESTED_PANEL_LEFT_PADDING = 8;
1218
1265
  /** Options for binding a passive event listener. */
1219
1266
  const passiveEventListenerOptions = normalizePassiveListenerOptions({ passive: true });
1267
+ /** Tags whose implicit role always allows `aria-expanded`; `a[href]` is checked separately. */
1268
+ const NATIVELY_EXPANDABLE_TAGS = new Set(['BUTTON', 'SUMMARY']);
1269
+ /** The triggers bound to a panel and their one subscription to its `closed`, see `KbqDropdownTrigger.bindToPanel`. */
1270
+ const panelBindings = new WeakMap();
1220
1271
  const positionMap = {
1221
1272
  /** Maps CDK overlay x-anchor back to a dropdown x-position label. */
1222
1273
  overlayXToPosX: {
@@ -1242,96 +1293,96 @@ const positionMap = {
1242
1293
  * responsible for toggling the display of the provided dropdown instance.
1243
1294
  */
1244
1295
  class KbqDropdownTrigger {
1245
- /** References the dropdown instance that the trigger is associated with. */
1246
- // TODO: Skipped for migration because:
1247
- // Accessor inputs cannot be migrated as they are too complex.
1248
- get dropdown() {
1249
- return this._dropdown;
1250
- }
1251
- set dropdown(dropdown) {
1252
- if (dropdown === this._dropdown) {
1253
- return;
1254
- }
1255
- this._dropdown = dropdown;
1256
- this.closeSubscription.unsubscribe();
1257
- if (dropdown) {
1258
- this.closeSubscription = dropdown.closed.asObservable().subscribe((reason) => {
1259
- this.destroy(reason);
1260
- // If a click closed the dropdown, we should close the entire chain of nested dropdowns.
1261
- if (['click', 'tab'].includes(reason) && this.parent) {
1262
- this.parent.closed.emit(reason);
1263
- }
1264
- });
1265
- }
1266
- }
1267
1296
  /** The text direction of the containing app. */
1268
1297
  get dir() {
1269
1298
  return this._dir?.value === 'rtl' ? 'rtl' : 'ltr';
1270
1299
  }
1271
1300
  /** Whether the dropdown is open. */
1272
1301
  get opened() {
1273
- return this._opened;
1302
+ return this.openedState();
1303
+ }
1304
+ /**
1305
+ * `aria-expanded` only where a role allows it: on a generic `<div>`/`<span>` it fails `aria-allowed-attr`.
1306
+ *
1307
+ * @docs-private
1308
+ */
1309
+ get ariaExpanded() {
1310
+ return this.hasExpandableRole ? this.opened : null;
1311
+ }
1312
+ // Not cached: a co-located `[attr.role]` binding (e.g. `KbqNavbarItem`) lands during change detection.
1313
+ get hasExpandableRole() {
1314
+ const element = this.elementRef.nativeElement;
1315
+ return (NATIVELY_EXPANDABLE_TAGS.has(element.tagName) ||
1316
+ (element.tagName === 'A' && element.hasAttribute('href')) ||
1317
+ element.hasAttribute('role'));
1274
1318
  }
1275
1319
  /**
1276
1320
  * Whether the dropdown overlay is currently attached. Part of the `KbqSiblingPopup` contract.
1277
1321
  *
1278
- * `opened` is set synchronously right after the overlay is attached and, on close, only once the exit
1279
- * animation is done — i.e. it stays `true` for the whole time the trigger is busy with its panel,
1280
- * including the moment `destroy()` restores focus to the trigger.
1322
+ * Set right after the overlay is attached and cleared right after it is detached, once `destroy()` has
1323
+ * restored focus to the trigger, so a tooltip on the trigger stays muted for that focus.
1281
1324
  */
1282
1325
  get isAttached() {
1283
- return this._opened;
1326
+ return this.openedState();
1284
1327
  }
1285
1328
  constructor() {
1286
1329
  this.overlay = inject(Overlay);
1330
+ this.overlayLayers = inject(KBQ_OVERLAY_LAYERS);
1287
1331
  this.elementRef = inject(ElementRef);
1288
1332
  this.viewContainerRef = inject(ViewContainerRef);
1289
1333
  this.scrollStrategy = inject(KBQ_DROPDOWN_SCROLL_STRATEGY);
1290
1334
  this.parent = inject(KbqDropdown, { optional: true });
1291
1335
  this.dropdownItemInstance = inject(KbqDropdownItem, { optional: true, self: true });
1292
1336
  this._dir = inject(Directionality, { optional: true });
1293
- this.changeDetectorRef = inject(ChangeDetectorRef);
1294
1337
  this.focusMonitor = inject(FocusMonitor);
1295
- this.overlayContainer = inject(OverlayContainer);
1296
- this.renderer = inject(Renderer2);
1297
- this.ngZone = inject(NgZone);
1338
+ this.document = inject(DOCUMENT);
1339
+ this.injector = inject(Injector);
1298
1340
  this.isBrowser = inject(Platform).isBrowser;
1299
- this.host = inject(KBQ_DROPDOWN_HOST, { optional: true });
1300
- // TODO: Skipped for migration because:
1301
- // Your application code writes to the input. This prevents migration.
1302
- this.openByArrowDown = true;
1341
+ /** Position offset of the dropdown in the X axis. */
1342
+ // `model()` because `kbq-navbar-item` writes it.
1343
+ this.offsetX = model(undefined, ...(ngDevMode ? [{ debugName: "offsetX" }] : /* istanbul ignore next */ []));
1344
+ /** Position offset of the dropdown in the Y axis. */
1345
+ // `undefined` means "use the computed offset", so it must not be coerced to `NaN`.
1346
+ this.offsetY = input(undefined, { ...(ngDevMode ? { debugName: "offsetY" } : /* istanbul ignore next */ {}), transform: (value) => (value == null ? undefined : numberAttribute(value)) });
1347
+ /** Data to be passed along to any lazily-rendered content. */
1348
+ this.data = input(undefined, { ...(ngDevMode ? { debugName: "data" } : /* istanbul ignore next */ {}), alias: 'kbqDropdownTriggerData' });
1349
+ /** Whether the Down Arrow opens the dropdown when the trigger is focused. Written by `kbq-navbar-item`. */
1350
+ this.openByArrowDown = model(true, ...(ngDevMode ? [{ debugName: "openByArrowDown" }] : /* istanbul ignore next */ []));
1351
+ /**
1352
+ * What the panel is positioned against: an element, or a rectangle in viewport coordinates such as the one
1353
+ * `kbqCreateCaretOrigin` keeps on the caret. `null` anchors the panel to the trigger element.
1354
+ *
1355
+ * Call {@link updatePosition} to move an open panel to a new origin.
1356
+ */
1357
+ this.origin = input(null, { ...(ngDevMode ? { debugName: "origin" } : /* istanbul ignore next */ {}), alias: 'kbqDropdownTriggerOrigin' });
1303
1358
  /**
1304
- * Whether to demote the overlay container z-index so that dropdown overlays
1305
- * sit below sibling overlays (tooltips, modals, etc.). Set to `false` to
1306
- * keep the dropdown overlay at the default overlay container z-index.
1359
+ * Whether opening the dropdown moves the keyboard focus into the panel. Turn it off to leave focus where it
1360
+ * is — in the editor the panel is anchored to, for instance — and pair it with `activeDescendantNavigation`
1361
+ * on the panel so the arrow keys still work.
1307
1362
  */
1308
- // TODO: Skipped for migration because:
1309
- // Your application code writes to the input. This prevents migration.
1310
- this.demoteOverlay = true;
1363
+ this.autoFocus = input(true, { ...(ngDevMode ? { debugName: "autoFocus" } : /* istanbul ignore next */ {}), alias: 'kbqDropdownTriggerAutoFocus', transform: booleanAttribute });
1311
1364
  /**
1312
1365
  * Whether focus should be restored when the menu is closed.
1313
1366
  * Note that disabling this option can have accessibility implications
1314
1367
  * and it's up to you to manage focus, if you decide to turn it off.
1315
1368
  */
1316
- // TODO: Skipped for migration because:
1317
- // Class of this input is referenced in the signature of another class.
1318
- this.restoreFocus = true;
1369
+ // `model()` because `KbqOptionActionComponent` writes it.
1370
+ this.restoreFocus = model(true, { ...(ngDevMode ? { debugName: "restoreFocus" } : /* istanbul ignore next */ {}), alias: 'kbqDropdownTriggerRestoreFocus' });
1371
+ /** References the dropdown instance that the trigger is associated with. */
1372
+ // Not `input.required`, so that `throwKbqDropdownMissingError` reports a missing panel.
1373
+ this.dropdown = input(undefined, { ...(ngDevMode ? { debugName: "dropdown" } : /* istanbul ignore next */ {}), alias: 'kbqDropdownTriggerFor' });
1319
1374
  /** Event emitted when the associated dropdown is opened. */
1320
1375
  this.dropdownOpened = output();
1321
- /**
1322
- * Event emitted when the associated dropdown is closed. Kept as an `@Output()` EventEmitter
1323
- * (not `output()`): `KbqOptionActionComponent` subscribes to it via `.pipe()` through the
1324
- * KBQ_OPTION_ACTION_PARENT contract, which an `OutputEmitterRef` does not support — see #DS-5079.
1325
- */
1326
- this.dropdownClosed = new EventEmitter();
1376
+ /** Event emitted when the associated dropdown is closed. */
1377
+ this.dropdownClosed = output();
1327
1378
  /** Emits `true` when the dropdown opens and `false` when it closes. Part of the `KbqSiblingPopup` contract. */
1328
- this.openedChange = merge(outputToObservable(this.dropdownOpened).pipe(map(() => true)), this.dropdownClosed.pipe(map(() => false)));
1329
- this._opened = false;
1379
+ this.openedChange = merge(outputToObservable(this.dropdownOpened).pipe(map(() => true)), outputToObservable(this.dropdownClosed).pipe(map(() => false)));
1380
+ this.openedState = signal(false, ...(ngDevMode ? [{ debugName: "openedState" }] : /* istanbul ignore next */ []));
1330
1381
  this.overlayRef = null;
1331
- this.closeSubscription = Subscription.EMPTY;
1382
+ /** Per-session subscription to `closingActions()`; torn down on every close. */
1383
+ this.closingActionsSubscription = Subscription.EMPTY;
1332
1384
  this.hoverSubscription = Subscription.EMPTY;
1333
- this.widthLockSubscription = Subscription.EMPTY;
1334
- this.classAddedToOverlayContainer = false;
1385
+ this.widthLockRef = null;
1335
1386
  /**
1336
1387
  * Handles touch start events on the trigger.
1337
1388
  * Needs to be an arrow function so we can easily use addEventListener and removeEventListener.
@@ -1343,8 +1394,51 @@ class KbqDropdownTrigger {
1343
1394
  if (dropdownItemInstance) {
1344
1395
  dropdownItemInstance.isNested = this.isNested();
1345
1396
  }
1346
- if (this.host) {
1347
- this.demoteOverlay = false;
1397
+ effect((onCleanup) => {
1398
+ const dropdown = this.dropdown();
1399
+ if (!dropdown)
1400
+ return;
1401
+ onCleanup(KbqDropdownTrigger.bindToPanel(dropdown, this));
1402
+ });
1403
+ }
1404
+ /**
1405
+ * Subscribes the triggers of a panel to its `closed` once, so that an emission closes the triggers that had the
1406
+ * panel open when it began: a trigger that a `dropdownClosed` handler opens on the way stays open.
1407
+ *
1408
+ * @returns Teardown that unbinds the trigger.
1409
+ */
1410
+ static bindToPanel(dropdown, trigger) {
1411
+ let binding = panelBindings.get(dropdown);
1412
+ if (!binding) {
1413
+ const triggers = new Set();
1414
+ const subscription = outputToObservable(dropdown.closed).subscribe((reason) => {
1415
+ const open = [...triggers].filter((candidate) => candidate.openedState());
1416
+ for (const candidate of open) {
1417
+ // Checked again: closing the chain of one trigger can close another one first.
1418
+ if (candidate.openedState())
1419
+ candidate.closeFromPanel(dropdown, reason);
1420
+ }
1421
+ });
1422
+ binding = { triggers, subscription };
1423
+ panelBindings.set(dropdown, binding);
1424
+ }
1425
+ const { triggers, subscription } = binding;
1426
+ triggers.add(trigger);
1427
+ return () => {
1428
+ triggers.delete(trigger);
1429
+ if (triggers.size)
1430
+ return;
1431
+ subscription.unsubscribe();
1432
+ panelBindings.delete(dropdown);
1433
+ };
1434
+ }
1435
+ /** Closes the panel this trigger has open on its `closed`, and the chain of panels it is nested in. */
1436
+ closeFromPanel(dropdown, reason) {
1437
+ // A click, Tab or an activated item closes the entire chain of nested dropdowns.
1438
+ const closesChain = reason === 'click' || reason === 'tab' || (dropdown instanceof KbqDropdown && dropdown.closingChain);
1439
+ this.destroy(reason, closesChain);
1440
+ if (closesChain && this.parent) {
1441
+ untracked(() => this.parent.closeChain(reason));
1348
1442
  }
1349
1443
  }
1350
1444
  ngAfterContentInit() {
@@ -1365,54 +1459,96 @@ class KbqDropdownTrigger {
1365
1459
  }
1366
1460
  /** Toggles the dropdown between the open and closed states. */
1367
1461
  toggle() {
1368
- return this._opened ? this.close() : this.open();
1462
+ return untracked(this.openedState) ? this.close() : this.open();
1463
+ }
1464
+ /** Moves an open panel to the current origin and re-applies its position. */
1465
+ updatePosition() {
1466
+ untracked(() => {
1467
+ if (!this.openedState() || !this.overlayRef)
1468
+ return;
1469
+ this.setPosition(this.overlayRef.getConfig().positionStrategy);
1470
+ this.overlayRef.updatePosition();
1471
+ });
1369
1472
  }
1370
1473
  /** Opens the dropdown. */
1371
1474
  open() {
1372
- if (this._opened) {
1475
+ // Untracked, as `close()`, `toggle()`, `updatePosition()` and `focus()`: called from a consumer's `effect()`,
1476
+ // the state read on the way — `opened`, the inputs of the trigger and of the panel — would make the effect run
1477
+ // again on every open and close.
1478
+ untracked(() => this.openPanel());
1479
+ }
1480
+ /** Body of `open()`. */
1481
+ openPanel() {
1482
+ if (this.openedState()) {
1373
1483
  return;
1374
1484
  }
1375
1485
  this.check();
1376
1486
  const overlayRef = this.createOverlay();
1377
1487
  const overlayConfig = overlayRef.getConfig();
1378
1488
  this.setPosition(overlayConfig.positionStrategy);
1379
- overlayConfig.hasBackdrop = this.dropdown.hasBackdrop ? !this.isNested() : this.dropdown.hasBackdrop;
1489
+ overlayConfig.hasBackdrop = this.dropdown().hasBackdrop?.()
1490
+ ? !this.isNested()
1491
+ : !!this.dropdown().hasBackdrop?.();
1380
1492
  // The overlay is created once and reused, so the trigger has to be re-measured on every open
1381
1493
  // to keep up with layout changes between them.
1382
1494
  if (this.shouldMatchTriggerWidth) {
1383
1495
  overlayRef.updateSize(this.getOverlaySize());
1384
1496
  }
1385
1497
  overlayRef.attach(this.getPortal());
1386
- if (this.dropdown.lazyContent) {
1387
- this.dropdown.lazyContent.detach();
1388
- this.dropdown.lazyContent.attach(this.data);
1389
- }
1390
- this.closeSubscription = this.closingActions().subscribe(() => this.close());
1498
+ const lazyContent = this.dropdown().lazyContent?.();
1499
+ if (lazyContent) {
1500
+ lazyContent.detach();
1501
+ lazyContent.attach(this.data());
1502
+ }
1503
+ // The overlay positions the pane once its content has rendered, which without zone.js happens in a later
1504
+ // task: the browser can paint a frame in between with the pane at the viewport origin, where the item
1505
+ // under the pointer takes the hover and focus. Placed now, it is re-placed after the render.
1506
+ overlayRef.updatePosition();
1507
+ this.closingActionsSubscription.unsubscribe();
1508
+ this.closingActionsSubscription = this.closingActions().subscribe(() => this.close());
1391
1509
  this.init();
1392
- if (this.dropdown instanceof KbqDropdown) {
1393
- this.dropdown.startAnimation();
1510
+ if (this.dropdown() instanceof KbqDropdown) {
1511
+ this.dropdown().setOpened(true);
1394
1512
  }
1395
- this.addClassToOverlayContainer();
1396
1513
  this.lockOverlayWidthForSearch();
1397
1514
  }
1398
1515
  /** Closes the dropdown. */
1399
1516
  close() {
1400
- this.dropdown.closed.emit();
1401
- this.removeClassFromOverlayContainer();
1517
+ untracked(() => this.dropdown().closed.emit());
1402
1518
  }
1403
1519
  /**
1404
1520
  * Focuses the dropdown trigger.
1405
1521
  */
1406
1522
  focus(origin, options) {
1407
- // The trigger of a nested panel is an item of a search panel: the caret belongs to the query,
1408
- // not to the item, so hand it back to the field instead of focusing this element.
1409
- if (this.isNested() && this.parent.restoreFocus?.())
1410
- return;
1411
- if (this.focusMonitor && origin) {
1412
- this.focusMonitor.focusVia(this.elementRef.nativeElement, origin, options);
1413
- }
1414
- else {
1415
- this.elementRef.nativeElement.focus();
1523
+ untracked(() => {
1524
+ // The trigger of a nested panel is an item of a search panel: the caret belongs to the query,
1525
+ // not to the item, so hand it back to the field instead of focusing this element.
1526
+ if (this.isNested() && this.parent.restoreFocus?.())
1527
+ return;
1528
+ // A programmatic open leaves `openedBy` unset; the host still gets `cdk-program-focused`.
1529
+ this.focusMonitor.focusVia(this.elementRef.nativeElement, origin ?? 'program', options);
1530
+ });
1531
+ }
1532
+ /** Whether focus is still the overlay's to give back, i.e. an outside click hasn't moved it elsewhere. */
1533
+ overlayHoldsFocus() {
1534
+ const activeElement = this.document.activeElement;
1535
+ // Reads `null` when the overlay is being disposed, e.g. while the trigger itself is destroyed.
1536
+ const overlayElement = this.overlayRef?.overlayElement;
1537
+ return (!activeElement ||
1538
+ activeElement === this.document.body ||
1539
+ !!overlayElement?.contains(activeElement) ||
1540
+ this.elementRef.nativeElement.contains(activeElement));
1541
+ }
1542
+ /**
1543
+ * Takes the focus off the detached panel. A renderer can keep its view in the document for a while
1544
+ * (`provideAnimations()` does, until its engine flushes), and the panel this one is nested in would not count
1545
+ * the focus left there as its own to restore.
1546
+ */
1547
+ releaseFocus() {
1548
+ const activeElement = this.document.activeElement;
1549
+ const overlayElement = this.overlayRef?.overlayElement;
1550
+ if (activeElement && overlayElement?.contains(activeElement)) {
1551
+ activeElement.blur();
1416
1552
  }
1417
1553
  }
1418
1554
  /** Handles mouse presses on the trigger. */
@@ -1432,17 +1568,17 @@ class KbqDropdownTrigger {
1432
1568
  * sibling item crossed on the way to the submenu doesn't prematurely close it.
1433
1569
  */
1434
1570
  handleMouseLeave(event) {
1435
- if (!this.isNested() || !this._opened || !this.isBrowser || !this.parent.safeArea() || !this.overlayRef) {
1571
+ if (!this.isNested() || !this.openedState() || !this.isBrowser || !this.parent.safeArea() || !this.overlayRef) {
1436
1572
  return;
1437
1573
  }
1438
- const panelRect = this.overlayRef.overlayElement.getBoundingClientRect();
1439
- const triangle = getSafeTriangleVertices({ x: event.clientX, y: event.clientY }, panelRect);
1440
- this.parent.activateSafeArea(this.dropdownItemInstance, triangle, panelRect, () => this.close());
1574
+ const overlayElement = this.overlayRef.overlayElement;
1575
+ // Measured on each move: the panel can be repositioned by a scroll or resize mid-transit.
1576
+ this.parent.activateSafeArea(this.dropdownItemInstance, { x: event.clientX, y: event.clientY }, () => overlayElement.getBoundingClientRect(), () => this.close());
1441
1577
  }
1442
1578
  /** Handles key presses on the trigger. */
1443
1579
  handleKeydown(event) {
1444
1580
  const keyCode = event.keyCode;
1445
- if (keyCode === ENTER$1 || keyCode === SPACE) {
1581
+ if (keyCode === ENTER$1 || keyCode === SPACE$1) {
1446
1582
  this.openedBy = 'keyboard';
1447
1583
  event.preventDefault();
1448
1584
  if (this.isNested()) {
@@ -1456,7 +1592,7 @@ class KbqDropdownTrigger {
1456
1592
  }
1457
1593
  if ((this.isNested() &&
1458
1594
  ((keyCode === RIGHT_ARROW && this.dir === 'ltr') || (keyCode === LEFT_ARROW && this.dir === 'rtl'))) ||
1459
- (!this.isNested() && keyCode === DOWN_ARROW$1 && this.openByArrowDown)) {
1595
+ (!this.isNested() && keyCode === DOWN_ARROW$1 && this.openByArrowDown())) {
1460
1596
  event.preventDefault();
1461
1597
  this.openedBy = 'keyboard';
1462
1598
  this.open();
@@ -1474,7 +1610,7 @@ class KbqDropdownTrigger {
1474
1610
  }
1475
1611
  }
1476
1612
  /** Closes the dropdown and does the necessary cleanup. */
1477
- destroy(reason) {
1613
+ destroy(reason, closesChain = false) {
1478
1614
  if (!this.overlayRef || !this.opened) {
1479
1615
  return;
1480
1616
  }
@@ -1482,79 +1618,67 @@ class KbqDropdownTrigger {
1482
1618
  if (this.isNested()) {
1483
1619
  this.parent.deactivateSafeArea();
1484
1620
  }
1485
- this.dropdown.resetActiveItem();
1486
- this.closeSubscription.unsubscribe();
1487
- this.widthLockSubscription.unsubscribe();
1621
+ this.dropdown().resetActiveItem();
1622
+ this.closingActionsSubscription.unsubscribe();
1623
+ this.widthLockRef?.destroy();
1624
+ // Read before detaching the overlay.
1625
+ const focusIsOurs = this.overlayHoldsFocus();
1488
1626
  this.overlayRef.detach();
1489
- if (this.restoreFocus && (reason === 'keydown' || !this.openedBy || !this.isNested())) {
1627
+ // A nested panel closing with the whole chain leaves the focus to the root trigger.
1628
+ const ownsFocus = (reason === 'keydown' && !closesChain) || !this.openedBy || !this.isNested();
1629
+ if (this.restoreFocus() && focusIsOurs && ownsFocus) {
1490
1630
  this.focus(this.openedBy);
1491
1631
  }
1632
+ this.releaseFocus();
1492
1633
  this.openedBy = undefined;
1493
- if (this.dropdown instanceof KbqDropdown) {
1494
- this.dropdown.resetAnimation();
1495
- const animationSubscription = this.dropdown.animationDone.pipe(filter((event) => event.toState === 'void'), take(1));
1496
- if (this.dropdown.lazyContent) {
1497
- // Wait for the exit animation to finish before detaching the content.
1498
- animationSubscription
1499
- .pipe(
1500
- // Interrupt if the content got re-attached.
1501
- takeUntil(this.dropdown.lazyContent.attached))
1502
- .subscribe({
1503
- next: () => this.dropdown.lazyContent.detach(),
1504
- // No matter whether the content got re-attached, reset the this.dropdown.
1505
- complete: () => this.setIsOpened(false)
1506
- });
1507
- }
1508
- else {
1509
- animationSubscription.subscribe(() => this.setIsOpened(false));
1510
- }
1511
- }
1512
- else {
1513
- this.setIsOpened(false);
1514
- if (this.dropdown.lazyContent) {
1515
- this.dropdown.lazyContent.detach();
1516
- }
1634
+ const dropdown = this.dropdown();
1635
+ if (dropdown instanceof KbqDropdown) {
1636
+ dropdown.setOpened(false);
1517
1637
  }
1638
+ dropdown.lazyContent?.()?.detach();
1639
+ // Last: a `dropdownClosed` handler can open the panel again, with this trigger or another one.
1640
+ this.setIsOpened(false);
1518
1641
  }
1519
1642
  /**
1520
1643
  * This method sets the dropdown state to open and focuses the first item if
1521
1644
  * the dropdown was opened via the keyboard.
1522
1645
  */
1523
1646
  init() {
1524
- this.dropdown.parent = this.isNested() ? this.parent : undefined;
1525
- this.dropdown.direction = this.dir;
1647
+ const dropdown = this.dropdown();
1648
+ dropdown.parent = this.isNested() ? this.parent : undefined;
1649
+ dropdown.direction = this.dir;
1526
1650
  // reset submenu items since they can be initialized as children of root menu
1527
- if (this.parent && !this.dropdown.items.length) {
1528
- this.dropdown.items.reset(Array.from(this.parent.items));
1529
- this.dropdown.items.notifyOnChanges();
1651
+ if (this.parent && !dropdown.items().length) {
1652
+ dropdown.adoptItems?.(this.parent.items());
1653
+ }
1654
+ if (this.autoFocus()) {
1655
+ dropdown.focusFirstItem(this.openedBy || 'program');
1656
+ }
1657
+ else {
1658
+ dropdown.resetActiveItem();
1530
1659
  }
1531
- this.dropdown.focusFirstItem(this.openedBy || 'program');
1532
1660
  this.setIsOpened(true);
1533
1661
  }
1534
1662
  // set state rather than toggle to support triggers sharing a dropdown
1535
1663
  setIsOpened(isOpen) {
1536
- if (isOpen !== this._opened) {
1537
- this.changeDetectorRef.markForCheck();
1664
+ this.openedState.set(isOpen);
1665
+ if (this.isNested()) {
1666
+ this.dropdownItemInstance.highlighted = isOpen;
1538
1667
  }
1539
- this._opened = isOpen;
1540
- if (this._opened) {
1541
- // TODO: The 'emit' function requires a mandatory void argument
1668
+ // Last, for the same reason as in `destroy()`.
1669
+ if (isOpen) {
1542
1670
  this.dropdownOpened.emit();
1543
1671
  }
1544
1672
  else {
1545
- // TODO: The 'emit' function requires a mandatory void argument
1546
1673
  this.dropdownClosed.emit();
1547
1674
  }
1548
- if (this.isNested()) {
1549
- this.dropdownItemInstance.highlighted = isOpen;
1550
- }
1551
1675
  }
1552
1676
  /**
1553
1677
  * This method checks that a valid instance of KbqDropdown has been passed into
1554
1678
  * kbqDropdownTriggerFor. If not, an exception is thrown.
1555
1679
  */
1556
1680
  check() {
1557
- if (!this.dropdown) {
1681
+ if (!this.dropdown()) {
1558
1682
  throwKbqDropdownMissingError();
1559
1683
  }
1560
1684
  }
@@ -1567,6 +1691,8 @@ class KbqDropdownTrigger {
1567
1691
  const config = this.getOverlayConfig();
1568
1692
  this.subscribeToPositions(config.positionStrategy);
1569
1693
  this.overlayRef = this.overlay.create(config);
1694
+ // The trigger, not `origin`: a point origin has no place in the DOM.
1695
+ this.overlayLayers.adopt(this.overlayRef, this.elementRef.nativeElement);
1570
1696
  // Consume the `keydownEvents` in order to prevent them from going to another overlay.
1571
1697
  // Ideally we'd also have our keyboard event logic in here, however doing so will
1572
1698
  // break anybody that may have implemented the `KbqDropdownPanel` themselves.
@@ -1574,51 +1700,65 @@ class KbqDropdownTrigger {
1574
1700
  }
1575
1701
  return this.overlayRef;
1576
1702
  }
1703
+ /** Whether the panel is anchored to a rectangle in viewport coordinates rather than to an element. */
1704
+ get hasPointOrigin() {
1705
+ const origin = this.origin();
1706
+ return !!origin && !kbqIsElementOrigin(origin);
1707
+ }
1708
+ /** The origin the position strategy is connected to. */
1709
+ getResolvedOrigin() {
1710
+ const origin = this.origin();
1711
+ return origin ? kbqResolveOverlayOrigin(origin) : this.elementRef;
1712
+ }
1577
1713
  /** Whether the panel should be at least as wide as its trigger. */
1578
1714
  get shouldMatchTriggerWidth() {
1579
- const isVerticalTrigger = this.dropdown.overlapTriggerY && !this.dropdown.overlapTriggerX;
1715
+ const isVerticalTrigger = this.dropdown().overlapTriggerY() && !this.dropdown().overlapTriggerX();
1580
1716
  return !this.isNested() && !isVerticalTrigger;
1581
1717
  }
1582
1718
  /**
1583
1719
  * This method builds the configuration object needed to create the overlay, the OverlayState.
1720
+ *
1584
1721
  * @returns OverlayConfig
1585
1722
  */
1586
1723
  getOverlayConfig() {
1587
1724
  return new OverlayConfig({
1588
1725
  positionStrategy: this.overlay
1589
1726
  .position()
1590
- .flexibleConnectedTo(this.elementRef)
1727
+ .flexibleConnectedTo(this.getResolvedOrigin())
1591
1728
  .withTransformOriginOn('.kbq-dropdown__panel')
1592
1729
  .withPush(false),
1593
- backdropClass: this.dropdown.backdropClass || 'cdk-overlay-transparent-backdrop',
1730
+ backdropClass: this.dropdown().backdropClass?.() || 'cdk-overlay-transparent-backdrop',
1594
1731
  scrollStrategy: this.scrollStrategy(),
1595
1732
  direction: this.dir,
1596
1733
  ...(this.shouldMatchTriggerWidth && this.getOverlaySize())
1597
1734
  });
1598
1735
  }
1599
1736
  /**
1600
- * Listens to changes in the position of the overlay and sets the correct classes
1601
- * on the dropdown based on the new position. This ensures the animation origin is always
1602
- * correct, even if a fallback position is used for the overlay.
1737
+ * Listens to changes in the position of the overlay and sets the matching position classes on the dropdown,
1738
+ * so they follow a fallback position too.
1603
1739
  */
1604
1740
  subscribeToPositions(position) {
1605
- if (this.dropdown.setPositionClasses) {
1741
+ if (this.dropdown().setPositionClasses) {
1606
1742
  position.positionChanges.subscribe((change) => {
1607
1743
  const posX = positionMap.overlayXToPosX[change.connectionPair.overlayX];
1608
1744
  const posY = change.connectionPair.overlayY === 'top' ? 'below' : 'above';
1609
- this.dropdown.setPositionClasses(posX, posY);
1745
+ this.dropdown().setPositionClasses(posX, posY);
1610
1746
  });
1611
1747
  }
1612
1748
  }
1613
1749
  /**
1614
1750
  * Sets the appropriate positions on a position strategy
1615
1751
  * so the overlay connects with the trigger correctly.
1752
+ *
1616
1753
  * @param positionStrategy Strategy whose position to update.
1617
1754
  */
1618
1755
  setPosition(positionStrategy) {
1619
- let [originX, originFallbackX, overlayX, overlayFallbackX] = positionMap.xPositions[this.dropdown.xPosition];
1756
+ // The overlay is created once and reused, so the origin is applied again on every open. A panel anchored
1757
+ // to a point has no trigger box to fall back on, so it is pushed back into the viewport near its edges.
1758
+ positionStrategy.setOrigin(this.getResolvedOrigin()).withPush(this.hasPointOrigin);
1759
+ let [originX, originFallbackX, overlayX, overlayFallbackX] = positionMap.xPositions[this.dropdown().xPosition()];
1620
1760
  // eslint-disable-next-line prefer-const
1621
- let [overlayY, overlayFallbackY, originY, originFallbackY] = this.dropdown.yPosition === 'above'
1761
+ let [overlayY, overlayFallbackY, originY, originFallbackY] = this.dropdown().yPosition() === 'above'
1622
1762
  ? ['bottom', 'top', 'bottom', 'top']
1623
1763
  : ['top', 'bottom', 'top', 'bottom'];
1624
1764
  let offsetY = 0;
@@ -1627,33 +1767,33 @@ class KbqDropdownTrigger {
1627
1767
  // When the dropdown is nested, it should always align itself
1628
1768
  // to the edges of the trigger, instead of overlapping it,
1629
1769
  // so 'center' is not applicable for nested panels — falls back to 'after'.
1630
- const xPosition = this.dropdown.xPosition === 'center' ? 'after' : this.dropdown.xPosition;
1770
+ const xPosition = this.dropdown().xPosition() === 'center' ? 'after' : this.dropdown().xPosition();
1631
1771
  [originX, originFallbackX, overlayX, overlayFallbackX] = positionMap.nonOverlapXPositions[xPosition];
1632
1772
  offsetY = overlayY === 'bottom' ? NESTED_PANEL_TOP_PADDING : -NESTED_PANEL_TOP_PADDING;
1633
1773
  offsetX = NESTED_PANEL_LEFT_PADDING;
1634
1774
  }
1635
1775
  else {
1636
- if (!this.dropdown.overlapTriggerY) {
1776
+ if (!this.dropdown().overlapTriggerY()) {
1637
1777
  offsetY = defaultOffsetY;
1638
1778
  originY = overlayY === 'top' ? 'bottom' : 'top';
1639
1779
  originFallbackY = overlayFallbackY === 'top' ? 'bottom' : 'top';
1640
1780
  }
1641
- if (!this.dropdown.overlapTriggerX) {
1781
+ if (!this.dropdown().overlapTriggerX()) {
1642
1782
  [originX, originFallbackX, overlayX, overlayFallbackX] =
1643
- positionMap.nonOverlapXPositions[this.dropdown.xPosition];
1783
+ positionMap.nonOverlapXPositions[this.dropdown().xPosition()];
1644
1784
  }
1645
1785
  }
1646
- const resolvedOffsetY = this.offsetY ?? (overlayY === 'top' ? offsetY : -offsetY);
1647
- const resolvedFallbackOffsetY = this.offsetY ?? (overlayFallbackY === 'top' ? offsetY : -offsetY);
1786
+ const resolvedOffsetY = this.offsetY() ?? (overlayY === 'top' ? offsetY : -offsetY);
1787
+ const resolvedFallbackOffsetY = this.offsetY() ?? (overlayFallbackY === 'top' ? offsetY : -offsetY);
1648
1788
  positionStrategy.withPositions([
1649
- { originX, originY, overlayX, overlayY, offsetY: resolvedOffsetY, offsetX: this.offsetX ?? -offsetX },
1789
+ { originX, originY, overlayX, overlayY, offsetY: resolvedOffsetY, offsetX: this.offsetX() ?? -offsetX },
1650
1790
  {
1651
1791
  originX: originFallbackX,
1652
1792
  originY,
1653
1793
  overlayX: overlayFallbackX,
1654
1794
  overlayY,
1655
1795
  offsetY: resolvedOffsetY,
1656
- offsetX: this.offsetX ?? offsetX
1796
+ offsetX: this.offsetX() ?? offsetX
1657
1797
  },
1658
1798
  {
1659
1799
  originX,
@@ -1661,7 +1801,7 @@ class KbqDropdownTrigger {
1661
1801
  overlayX,
1662
1802
  overlayY: overlayFallbackY,
1663
1803
  offsetY: resolvedFallbackOffsetY,
1664
- offsetX: this.offsetX ?? -offsetX
1804
+ offsetX: this.offsetX() ?? -offsetX
1665
1805
  },
1666
1806
  {
1667
1807
  originX: originFallbackX,
@@ -1669,29 +1809,32 @@ class KbqDropdownTrigger {
1669
1809
  overlayX: overlayFallbackX,
1670
1810
  overlayY: overlayFallbackY,
1671
1811
  offsetY: resolvedFallbackOffsetY,
1672
- offsetX: this.offsetX ?? -offsetX
1812
+ offsetX: this.offsetX() ?? -offsetX
1673
1813
  }
1674
1814
  ]);
1675
1815
  }
1676
1816
  /** Cleans up the active subscriptions. */
1677
1817
  cleanUpSubscriptions() {
1678
- this.closeSubscription.unsubscribe();
1818
+ this.closingActionsSubscription.unsubscribe();
1679
1819
  this.hoverSubscription.unsubscribe();
1680
- this.widthLockSubscription.unsubscribe();
1820
+ this.widthLockRef?.destroy();
1681
1821
  }
1682
1822
  /** Returns a stream that emits whenever an action that should close the dropdown occurs. */
1683
1823
  closingActions() {
1684
1824
  const backdrop = this.overlayRef.backdropClick();
1685
- const outsidePointerEvents = this.overlayRef.outsidePointerEvents();
1825
+ // A click on the trigger is the trigger's own: it toggles a top-level panel and keeps a nested one open. Taken for
1826
+ // an outside click, it closed the nested panel before the click reached the trigger. The trigger does not handle
1827
+ // `contextmenu` and `auxclick`, so those close the panel as they do anywhere else.
1828
+ const outsidePointerEvents = this.overlayRef.outsidePointerEvents().pipe(filter((event) => event.type !== 'click' || !this.elementRef.nativeElement.contains(_getEventTarget(event))));
1686
1829
  const detachments = this.overlayRef.detachments();
1687
- const parentClose = this.parent ? this.parent.closed : of();
1830
+ const parentClose = this.parent ? outputToObservable(this.parent.closed) : of();
1688
1831
  const hover = this.parent
1689
- ? this.parent.hovered().pipe(filter((active) => active !== this.dropdownItemInstance), filter(() => this._opened),
1832
+ ? this.parent.hovered().pipe(filter((active) => active !== this.dropdownItemInstance), filter(() => this.openedState()),
1690
1833
  // While a safe area protects this dropdown, closing is driven by the safe area
1691
1834
  // itself instead: either it resolves on its own (see `handleMouseLeave()`), or a
1692
1835
  // forced switch to a different nested trigger closes this one via `onExit` — always
1693
- // before the new trigger opens, so the two don't race over animation state shared by
1694
- // triggers pointing at the same dropdown (see `KbqDropdown.activateSafeArea()`).
1836
+ // before the new trigger opens, so the two don't race over the state of a dropdown shared by
1837
+ // both triggers (see `KbqDropdown.activateSafeArea()`).
1695
1838
  filter(() => !this.parent.isSafeAreaActive()))
1696
1839
  : of();
1697
1840
  return merge(backdrop, outsidePointerEvents, parentClose, hover, detachments);
@@ -1702,7 +1845,7 @@ class KbqDropdownTrigger {
1702
1845
  if (!this.isNested()) {
1703
1846
  return;
1704
1847
  }
1705
- this.hoverSubscription = merge(this.parent.hovered().pipe(filter((active) => active === this.dropdownItemInstance && !active.disabled),
1848
+ this.hoverSubscription = merge(this.parent.hovered().pipe(filter((active) => active === this.dropdownItemInstance && !active.disabled()),
1706
1849
  // While a *different* trigger's safe area is active, opening is deferred to
1707
1850
  // `onSwitchTarget()` below, which only fires once that trigger has actually closed.
1708
1851
  // Hovering the trigger that owns the active safe area (coming back to it) still
@@ -1718,20 +1861,7 @@ class KbqDropdownTrigger {
1718
1861
  // previous `mouseleave`.
1719
1862
  this.parent.deactivateSafeArea();
1720
1863
  this.openedBy = 'mouse';
1721
- // If the same dropdown is used between multiple triggers, it might still be animating
1722
- // while the new trigger tries to re-open it. Wait for the animation to finish
1723
- // before doing so. Also interrupt if the user moves to another item.
1724
- if (this.dropdown instanceof KbqDropdown && this.dropdown.isAnimating) {
1725
- // We need the `delay(0)` here in order to avoid
1726
- // 'changed after checked' errors in some cases. See #12194.
1727
- this.dropdown.animationDone
1728
- .pipe(take(1), delay(0, asapScheduler), takeUntil(this.parent.hovered()))
1729
- // eslint-disable-next-line rxjs-x/no-nested-subscribe
1730
- .subscribe(() => this.open());
1731
- }
1732
- else {
1733
- this.open();
1734
- }
1864
+ this.open();
1735
1865
  });
1736
1866
  }
1737
1867
  /** Gets the portal that should be attached to the overlay. */
@@ -1739,13 +1869,16 @@ class KbqDropdownTrigger {
1739
1869
  // Note that we can avoid this check by keeping the portal on the dropdown panel.
1740
1870
  // While it would be cleaner, we'd have to introduce another required method on
1741
1871
  // `KbqDropdownPanel`, making it harder to consume.
1742
- if (!this.portal || this.portal.templateRef !== this.dropdown.templateRef) {
1743
- this.portal = new TemplatePortal(this.dropdown.templateRef, this.viewContainerRef);
1872
+ if (!this.portal || this.portal.templateRef !== this.dropdown().templateRef()) {
1873
+ this.portal = new TemplatePortal(this.dropdown().templateRef(), this.viewContainerRef);
1744
1874
  }
1745
1875
  return this.portal;
1746
1876
  }
1747
1877
  getOverlaySize() {
1748
- return kbqResolvePanelWidth(this.dropdown.panelWidth?.(), this.dropdown.panelMinWidth?.(), this.isBrowser ? kbqGetPanelWidthOrigin(this.widthOrigin ?? this.elementRef) : 0);
1878
+ // A caret has no width to match, and the hidden element such a trigger usually sits on has none either;
1879
+ // an explicit `panelWidth` still applies.
1880
+ const triggerWidth = this.isBrowser && !this.hasPointOrigin ? kbqGetPanelWidthOrigin(this.widthOrigin ?? this.elementRef) : 0;
1881
+ return kbqResolvePanelWidth(this.dropdown().panelWidth?.(), this.dropdown().panelMinWidth?.(), triggerWidth);
1749
1882
  }
1750
1883
  /**
1751
1884
  * When the panel hosts a search field, its content-sized width would jump as the field's cleaner
@@ -1755,48 +1888,28 @@ class KbqDropdownTrigger {
1755
1888
  lockOverlayWidthForSearch() {
1756
1889
  if (!this.isBrowser ||
1757
1890
  !this.shouldMatchTriggerWidth ||
1758
- !(this.dropdown instanceof KbqDropdown) ||
1759
- !this.dropdown.hasSearch()) {
1891
+ !(this.dropdown() instanceof KbqDropdown) ||
1892
+ !this.dropdown().hasSearch()) {
1760
1893
  return;
1761
1894
  }
1762
- this.widthLockSubscription = this.ngZone.onStable
1763
- .asObservable()
1764
- .pipe(take(1))
1765
- .subscribe(() => this.pinOverlayWidth());
1895
+ this.widthLockRef = afterNextRender(() => this.pinOverlayWidth(), { injector: this.injector });
1766
1896
  }
1767
1897
  /** Freezes the overlay pane at its rendered width. */
1768
1898
  pinOverlayWidth() {
1769
- if (!this._opened || !this.overlayRef)
1899
+ if (!this.openedState() || !this.overlayRef)
1770
1900
  return;
1771
1901
  // An explicit or `'auto'` panelWidth already fixes the pane; only pin content-sized panels.
1772
1902
  if (this.getOverlaySize().width !== '')
1773
1903
  return;
1774
- // Measure the pane, not `.kbq-dropdown__panel`: the panel scales in via `@transformDropdown`,
1775
- // so its `getBoundingClientRect()` can read a mid-animation (scaled) width. The pane is
1776
- // transform-immune and the panel fills it.
1777
1904
  const width = this.overlayRef.overlayElement.getBoundingClientRect().width;
1778
1905
  if (width) {
1779
1906
  this.overlayRef.updateSize({ width });
1780
1907
  }
1781
1908
  }
1782
- addClassToOverlayContainer() {
1783
- if (!this.demoteOverlay)
1784
- return;
1785
- const overlayContainer = this.overlayContainer?.getContainerElement();
1786
- if (overlayContainer.childNodes.length === 1) {
1787
- this.classAddedToOverlayContainer = true;
1788
- this.renderer.addClass(overlayContainer, 'cdk-overlay-container_dropdown');
1789
- }
1790
- }
1791
- removeClassFromOverlayContainer() {
1792
- if (this.classAddedToOverlayContainer) {
1793
- this.renderer.removeClass(this.overlayContainer.getContainerElement(), 'cdk-overlay-container_dropdown');
1794
- }
1795
- }
1796
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.30", ngImport: i0, type: KbqDropdownTrigger, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
1797
- /** @nocollapse */ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "16.1.0", version: "20.3.30", type: KbqDropdownTrigger, isStandalone: true, selector: "[kbqDropdownTriggerFor]", inputs: { offsetX: ["offsetX", "offsetX", numberAttribute], offsetY: ["offsetY", "offsetY", numberAttribute], data: ["kbqDropdownTriggerData", "data"], openByArrowDown: "openByArrowDown", demoteOverlay: ["demoteOverlay", "demoteOverlay", booleanAttribute], restoreFocus: ["kbqDropdownTriggerRestoreFocus", "restoreFocus"], dropdown: ["kbqDropdownTriggerFor", "dropdown"] }, outputs: { dropdownOpened: "dropdownOpened", dropdownClosed: "dropdownClosed" }, host: { listeners: { "mousedown": "handleMousedown($event)", "mouseleave": "handleMouseLeave($event)", "keydown": "handleKeydown($event)", "click": "handleClick($event)" }, properties: { "class.kbq-pressed": "opened" }, classAttribute: "kbq-dropdown-trigger" }, providers: [kbqSiblingPopupProvider(KbqDropdownTrigger)], exportAs: ["kbqDropdownTrigger"], ngImport: i0 }); }
1909
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: KbqDropdownTrigger, deps: [], target: i0.ɵɵFactoryTarget.Directive }); }
1910
+ /** @nocollapse */ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "21.2.25", type: KbqDropdownTrigger, isStandalone: true, selector: "[kbqDropdownTriggerFor]", inputs: { offsetX: { classPropertyName: "offsetX", publicName: "offsetX", isSignal: true, isRequired: false, transformFunction: null }, offsetY: { classPropertyName: "offsetY", publicName: "offsetY", isSignal: true, isRequired: false, transformFunction: null }, data: { classPropertyName: "data", publicName: "kbqDropdownTriggerData", isSignal: true, isRequired: false, transformFunction: null }, openByArrowDown: { classPropertyName: "openByArrowDown", publicName: "openByArrowDown", isSignal: true, isRequired: false, transformFunction: null }, origin: { classPropertyName: "origin", publicName: "kbqDropdownTriggerOrigin", isSignal: true, isRequired: false, transformFunction: null }, autoFocus: { classPropertyName: "autoFocus", publicName: "kbqDropdownTriggerAutoFocus", isSignal: true, isRequired: false, transformFunction: null }, restoreFocus: { classPropertyName: "restoreFocus", publicName: "kbqDropdownTriggerRestoreFocus", isSignal: true, isRequired: false, transformFunction: null }, dropdown: { classPropertyName: "dropdown", publicName: "kbqDropdownTriggerFor", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { offsetX: "offsetXChange", openByArrowDown: "openByArrowDownChange", restoreFocus: "kbqDropdownTriggerRestoreFocusChange", dropdownOpened: "dropdownOpened", dropdownClosed: "dropdownClosed" }, host: { listeners: { "mousedown": "handleMousedown($event)", "mouseleave": "handleMouseLeave($event)", "keydown": "handleKeydown($event)", "click": "handleClick($event)" }, properties: { "class.kbq-pressed": "opened", "attr.aria-expanded": "ariaExpanded" }, classAttribute: "kbq-dropdown-trigger" }, providers: [kbqSiblingPopupProvider(KbqDropdownTrigger)], exportAs: ["kbqDropdownTrigger"], ngImport: i0 }); }
1798
1911
  }
1799
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.30", ngImport: i0, type: KbqDropdownTrigger, decorators: [{
1912
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: KbqDropdownTrigger, decorators: [{
1800
1913
  type: Directive,
1801
1914
  args: [{
1802
1915
  selector: `[kbqDropdownTriggerFor]`,
@@ -1804,6 +1917,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.30", ngImpo
1804
1917
  host: {
1805
1918
  class: 'kbq-dropdown-trigger',
1806
1919
  '[class.kbq-pressed]': 'opened',
1920
+ // No `aria-haspopup` here: the panel carries neither `role="menu"` nor `role="menuitem"`, and
1921
+ // `aria-haspopup="true"` is a synonym for `menu` — it would announce a menu that does not
1922
+ // exist. Hosts that do build menu semantics on top (e.g. `KbqAppSwitcherDropdownSite`) set the
1923
+ // attribute themselves.
1924
+ '[attr.aria-expanded]': 'ariaExpanded',
1807
1925
  '(mousedown)': 'handleMousedown($event)',
1808
1926
  '(mouseleave)': 'handleMouseLeave($event)',
1809
1927
  '(keydown)': 'handleKeydown($event)',
@@ -1811,54 +1929,36 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.30", ngImpo
1811
1929
  },
1812
1930
  exportAs: 'kbqDropdownTrigger'
1813
1931
  }]
1814
- }], ctorParameters: () => [], propDecorators: { offsetX: [{
1815
- type: Input,
1816
- args: [{ transform: numberAttribute }]
1817
- }], offsetY: [{
1818
- type: Input,
1819
- args: [{ transform: numberAttribute }]
1820
- }], data: [{
1821
- type: Input,
1822
- args: ['kbqDropdownTriggerData']
1823
- }], openByArrowDown: [{
1824
- type: Input
1825
- }], demoteOverlay: [{
1826
- type: Input,
1827
- args: [{ transform: booleanAttribute }]
1828
- }], restoreFocus: [{
1829
- type: Input,
1830
- args: ['kbqDropdownTriggerRestoreFocus']
1831
- }], dropdown: [{
1832
- type: Input,
1833
- args: ['kbqDropdownTriggerFor']
1834
- }], dropdownOpened: [{ type: i0.Output, args: ["dropdownOpened"] }], dropdownClosed: [{
1835
- type: Output
1836
- }] } });
1932
+ }], ctorParameters: () => [], propDecorators: { offsetX: [{ type: i0.Input, args: [{ isSignal: true, alias: "offsetX", required: false }] }, { type: i0.Output, args: ["offsetXChange"] }], offsetY: [{ type: i0.Input, args: [{ isSignal: true, alias: "offsetY", required: false }] }], data: [{ type: i0.Input, args: [{ isSignal: true, alias: "kbqDropdownTriggerData", required: false }] }], openByArrowDown: [{ type: i0.Input, args: [{ isSignal: true, alias: "openByArrowDown", required: false }] }, { type: i0.Output, args: ["openByArrowDownChange"] }], origin: [{ type: i0.Input, args: [{ isSignal: true, alias: "kbqDropdownTriggerOrigin", required: false }] }], autoFocus: [{ type: i0.Input, args: [{ isSignal: true, alias: "kbqDropdownTriggerAutoFocus", required: false }] }], restoreFocus: [{ type: i0.Input, args: [{ isSignal: true, alias: "kbqDropdownTriggerRestoreFocus", required: false }] }, { type: i0.Output, args: ["kbqDropdownTriggerRestoreFocusChange"] }], dropdown: [{ type: i0.Input, args: [{ isSignal: true, alias: "kbqDropdownTriggerFor", required: false }] }], dropdownOpened: [{ type: i0.Output, args: ["dropdownOpened"] }], dropdownClosed: [{ type: i0.Output, args: ["dropdownClosed"] }] } });
1837
1933
 
1838
1934
  class KbqDropdownModule {
1839
- /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.30", ngImport: i0, type: KbqDropdownModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
1840
- /** @nocollapse */ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "20.3.30", ngImport: i0, type: KbqDropdownModule, imports: [OverlayModule,
1935
+ /** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: KbqDropdownModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
1936
+ /** @nocollapse */ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "21.2.25", ngImport: i0, type: KbqDropdownModule, imports: [OverlayModule,
1841
1937
  KbqIconModule,
1842
1938
  KbqDropdownStaticContent,
1843
1939
  KbqDropdown,
1844
1940
  KbqDropdownItem,
1941
+ KbqDropdownItemCaption,
1845
1942
  KbqDropdownItemAction,
1846
1943
  KbqDropdownTrigger,
1847
1944
  KbqDropdownContent,
1848
1945
  KbqDropdownFooter,
1946
+ KbqDropdownGroupHeader,
1849
1947
  KbqDropdownSearch], exports: [KbqDropdown,
1850
1948
  KbqDropdownItem,
1949
+ KbqDropdownItemCaption,
1851
1950
  KbqDropdownItemAction,
1852
1951
  KbqDropdownTrigger,
1853
1952
  KbqDropdownContent,
1854
1953
  KbqDropdownStaticContent,
1855
1954
  KbqDropdownFooter,
1955
+ KbqDropdownGroupHeader,
1856
1956
  KbqDropdownSearch] }); }
1857
- /** @nocollapse */ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "20.3.30", ngImport: i0, type: KbqDropdownModule, imports: [OverlayModule,
1957
+ /** @nocollapse */ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: KbqDropdownModule, imports: [OverlayModule,
1858
1958
  KbqIconModule,
1859
1959
  KbqDropdownItem] }); }
1860
1960
  }
1861
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.30", ngImport: i0, type: KbqDropdownModule, decorators: [{
1961
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.25", ngImport: i0, type: KbqDropdownModule, decorators: [{
1862
1962
  type: NgModule,
1863
1963
  args: [{
1864
1964
  imports: [
@@ -1867,20 +1967,24 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.30", ngImpo
1867
1967
  KbqDropdownStaticContent,
1868
1968
  KbqDropdown,
1869
1969
  KbqDropdownItem,
1970
+ KbqDropdownItemCaption,
1870
1971
  KbqDropdownItemAction,
1871
1972
  KbqDropdownTrigger,
1872
1973
  KbqDropdownContent,
1873
1974
  KbqDropdownFooter,
1975
+ KbqDropdownGroupHeader,
1874
1976
  KbqDropdownSearch
1875
1977
  ],
1876
1978
  exports: [
1877
1979
  KbqDropdown,
1878
1980
  KbqDropdownItem,
1981
+ KbqDropdownItemCaption,
1879
1982
  KbqDropdownItemAction,
1880
1983
  KbqDropdownTrigger,
1881
1984
  KbqDropdownContent,
1882
1985
  KbqDropdownStaticContent,
1883
1986
  KbqDropdownFooter,
1987
+ KbqDropdownGroupHeader,
1884
1988
  KbqDropdownSearch
1885
1989
  ]
1886
1990
  }]
@@ -1890,5 +1994,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.30", ngImpo
1890
1994
  * Generated bundle index. Do not edit.
1891
1995
  */
1892
1996
 
1893
- export { KBQ_DROPDOWN_DEFAULT_OPTIONS, KBQ_DROPDOWN_DEFAULT_OPTIONS_FACTORY, KBQ_DROPDOWN_HOST, KBQ_DROPDOWN_PANEL, KBQ_DROPDOWN_SCROLL_STRATEGY, KBQ_DROPDOWN_SCROLL_STRATEGY_FACTORY, KBQ_DROPDOWN_SCROLL_STRATEGY_FACTORY_PROVIDER, KbqDropdown, KbqDropdownContent, KbqDropdownFooter, KbqDropdownItem, KbqDropdownItemAction, KbqDropdownModule, KbqDropdownSearch, KbqDropdownStaticContent, KbqDropdownTrigger, NESTED_HOVER_SWITCH_DELAY, NESTED_PANEL_LEFT_PADDING, NESTED_PANEL_TOP_PADDING, fadeInItems, kbqDropdownAnimations, throwKbqDropdownInvalidPositionX, throwKbqDropdownInvalidPositionY, throwKbqDropdownMissingError, throwKbqDropdownSearchMissingInputError, throwKbqDropdownSearchMissingNgControlError, transformDropdown };
1997
+ export { KBQ_DROPDOWN_DEFAULT_OPTIONS, KBQ_DROPDOWN_DEFAULT_OPTIONS_FACTORY, KBQ_DROPDOWN_ITEM_ACTION_HOST, KBQ_DROPDOWN_PANEL, KBQ_DROPDOWN_SCROLL_STRATEGY, KBQ_DROPDOWN_SCROLL_STRATEGY_FACTORY, KBQ_DROPDOWN_SCROLL_STRATEGY_FACTORY_PROVIDER, KbqDropdown, KbqDropdownContent, KbqDropdownFooter, KbqDropdownGroupHeader, KbqDropdownItem, KbqDropdownItemAction, KbqDropdownItemCaption, KbqDropdownModule, KbqDropdownSearch, KbqDropdownStaticContent, KbqDropdownTrigger, NESTED_HOVER_SWITCH_DELAY, NESTED_PANEL_LEFT_PADDING, NESTED_PANEL_TOP_PADDING, throwKbqDropdownInvalidPositionX, throwKbqDropdownInvalidPositionY, throwKbqDropdownMissingError, throwKbqDropdownSearchMissingInputError, throwKbqDropdownSearchMissingNgControlError };
1894
1998
  //# sourceMappingURL=koobiq-components-dropdown.mjs.map