@frame-kit/ui-ng 0.0.1

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 (220) hide show
  1. package/COMPONENTS.md +683 -0
  2. package/DEVELOPMENT_GUIDE.md +1102 -0
  3. package/LICENSE +21 -0
  4. package/README.md +69 -0
  5. package/THEMING.md +130 -0
  6. package/core/headline/README.md +121 -0
  7. package/core/icon/README.md +173 -0
  8. package/core/image/README.md +210 -0
  9. package/core/link/README.md +297 -0
  10. package/core/separator/README.md +145 -0
  11. package/core/text/README.md +240 -0
  12. package/directives/infinite-scroll/README.md +102 -0
  13. package/directives/spotlight/README.md +154 -0
  14. package/directives/tooltip/README.md +147 -0
  15. package/docs/endpoint-link/README.md +142 -0
  16. package/docs/method-badge/README.md +154 -0
  17. package/fesm2022/frame-kit-ui-ng-core-headline.mjs +122 -0
  18. package/fesm2022/frame-kit-ui-ng-core-headline.mjs.map +1 -0
  19. package/fesm2022/frame-kit-ui-ng-core-icon.mjs +189 -0
  20. package/fesm2022/frame-kit-ui-ng-core-icon.mjs.map +1 -0
  21. package/fesm2022/frame-kit-ui-ng-core-image.mjs +123 -0
  22. package/fesm2022/frame-kit-ui-ng-core-image.mjs.map +1 -0
  23. package/fesm2022/frame-kit-ui-ng-core-link.mjs +369 -0
  24. package/fesm2022/frame-kit-ui-ng-core-link.mjs.map +1 -0
  25. package/fesm2022/frame-kit-ui-ng-core-separator.mjs +59 -0
  26. package/fesm2022/frame-kit-ui-ng-core-separator.mjs.map +1 -0
  27. package/fesm2022/frame-kit-ui-ng-core-text.mjs +204 -0
  28. package/fesm2022/frame-kit-ui-ng-core-text.mjs.map +1 -0
  29. package/fesm2022/frame-kit-ui-ng-directives-infinite-scroll.mjs +74 -0
  30. package/fesm2022/frame-kit-ui-ng-directives-infinite-scroll.mjs.map +1 -0
  31. package/fesm2022/frame-kit-ui-ng-directives-spotlight.mjs +76 -0
  32. package/fesm2022/frame-kit-ui-ng-directives-spotlight.mjs.map +1 -0
  33. package/fesm2022/frame-kit-ui-ng-directives-tooltip.mjs +425 -0
  34. package/fesm2022/frame-kit-ui-ng-directives-tooltip.mjs.map +1 -0
  35. package/fesm2022/frame-kit-ui-ng-docs-endpoint-link.mjs +63 -0
  36. package/fesm2022/frame-kit-ui-ng-docs-endpoint-link.mjs.map +1 -0
  37. package/fesm2022/frame-kit-ui-ng-docs-method-badge.mjs +43 -0
  38. package/fesm2022/frame-kit-ui-ng-docs-method-badge.mjs.map +1 -0
  39. package/fesm2022/frame-kit-ui-ng-forms.mjs +3632 -0
  40. package/fesm2022/frame-kit-ui-ng-forms.mjs.map +1 -0
  41. package/fesm2022/frame-kit-ui-ng-layouts-app-shell.mjs +239 -0
  42. package/fesm2022/frame-kit-ui-ng-layouts-app-shell.mjs.map +1 -0
  43. package/fesm2022/frame-kit-ui-ng-layouts-content-split.mjs +132 -0
  44. package/fesm2022/frame-kit-ui-ng-layouts-content-split.mjs.map +1 -0
  45. package/fesm2022/frame-kit-ui-ng-services-overlay-orchestrator.mjs +133 -0
  46. package/fesm2022/frame-kit-ui-ng-services-overlay-orchestrator.mjs.map +1 -0
  47. package/fesm2022/frame-kit-ui-ng-services-spotlight.mjs +60 -0
  48. package/fesm2022/frame-kit-ui-ng-services-spotlight.mjs.map +1 -0
  49. package/fesm2022/frame-kit-ui-ng-services-toast.mjs +166 -0
  50. package/fesm2022/frame-kit-ui-ng-services-toast.mjs.map +1 -0
  51. package/fesm2022/frame-kit-ui-ng-ui-accordion.mjs +214 -0
  52. package/fesm2022/frame-kit-ui-ng-ui-accordion.mjs.map +1 -0
  53. package/fesm2022/frame-kit-ui-ng-ui-alert.mjs +82 -0
  54. package/fesm2022/frame-kit-ui-ng-ui-alert.mjs.map +1 -0
  55. package/fesm2022/frame-kit-ui-ng-ui-avatar-stack.mjs +76 -0
  56. package/fesm2022/frame-kit-ui-ng-ui-avatar-stack.mjs.map +1 -0
  57. package/fesm2022/frame-kit-ui-ng-ui-avatar.mjs +81 -0
  58. package/fesm2022/frame-kit-ui-ng-ui-avatar.mjs.map +1 -0
  59. package/fesm2022/frame-kit-ui-ng-ui-badge.mjs +81 -0
  60. package/fesm2022/frame-kit-ui-ng-ui-badge.mjs.map +1 -0
  61. package/fesm2022/frame-kit-ui-ng-ui-breadcrumb.mjs +68 -0
  62. package/fesm2022/frame-kit-ui-ng-ui-breadcrumb.mjs.map +1 -0
  63. package/fesm2022/frame-kit-ui-ng-ui-button.mjs +108 -0
  64. package/fesm2022/frame-kit-ui-ng-ui-button.mjs.map +1 -0
  65. package/fesm2022/frame-kit-ui-ng-ui-callout.mjs +58 -0
  66. package/fesm2022/frame-kit-ui-ng-ui-callout.mjs.map +1 -0
  67. package/fesm2022/frame-kit-ui-ng-ui-card.mjs +70 -0
  68. package/fesm2022/frame-kit-ui-ng-ui-card.mjs.map +1 -0
  69. package/fesm2022/frame-kit-ui-ng-ui-copyable-field.mjs +113 -0
  70. package/fesm2022/frame-kit-ui-ng-ui-copyable-field.mjs.map +1 -0
  71. package/fesm2022/frame-kit-ui-ng-ui-data-table.mjs +1288 -0
  72. package/fesm2022/frame-kit-ui-ng-ui-data-table.mjs.map +1 -0
  73. package/fesm2022/frame-kit-ui-ng-ui-dialog.mjs +456 -0
  74. package/fesm2022/frame-kit-ui-ng-ui-dialog.mjs.map +1 -0
  75. package/fesm2022/frame-kit-ui-ng-ui-drawer.mjs +398 -0
  76. package/fesm2022/frame-kit-ui-ng-ui-drawer.mjs.map +1 -0
  77. package/fesm2022/frame-kit-ui-ng-ui-dropdown-menu.mjs +398 -0
  78. package/fesm2022/frame-kit-ui-ng-ui-dropdown-menu.mjs.map +1 -0
  79. package/fesm2022/frame-kit-ui-ng-ui-editable-field.mjs +125 -0
  80. package/fesm2022/frame-kit-ui-ng-ui-editable-field.mjs.map +1 -0
  81. package/fesm2022/frame-kit-ui-ng-ui-icon-badge.mjs +113 -0
  82. package/fesm2022/frame-kit-ui-ng-ui-icon-badge.mjs.map +1 -0
  83. package/fesm2022/frame-kit-ui-ng-ui-icon-list.mjs +111 -0
  84. package/fesm2022/frame-kit-ui-ng-ui-icon-list.mjs.map +1 -0
  85. package/fesm2022/frame-kit-ui-ng-ui-inline-edit.mjs +103 -0
  86. package/fesm2022/frame-kit-ui-ng-ui-inline-edit.mjs.map +1 -0
  87. package/fesm2022/frame-kit-ui-ng-ui-list-editor.mjs +135 -0
  88. package/fesm2022/frame-kit-ui-ng-ui-list-editor.mjs.map +1 -0
  89. package/fesm2022/frame-kit-ui-ng-ui-loader.mjs +81 -0
  90. package/fesm2022/frame-kit-ui-ng-ui-loader.mjs.map +1 -0
  91. package/fesm2022/frame-kit-ui-ng-ui-menu-item.mjs +79 -0
  92. package/fesm2022/frame-kit-ui-ng-ui-menu-item.mjs.map +1 -0
  93. package/fesm2022/frame-kit-ui-ng-ui-nav-brand.mjs +40 -0
  94. package/fesm2022/frame-kit-ui-ng-ui-nav-brand.mjs.map +1 -0
  95. package/fesm2022/frame-kit-ui-ng-ui-nav-group.mjs +110 -0
  96. package/fesm2022/frame-kit-ui-ng-ui-nav-group.mjs.map +1 -0
  97. package/fesm2022/frame-kit-ui-ng-ui-nav-separator.mjs +91 -0
  98. package/fesm2022/frame-kit-ui-ng-ui-nav-separator.mjs.map +1 -0
  99. package/fesm2022/frame-kit-ui-ng-ui-node-tree-breadcrumb.mjs +86 -0
  100. package/fesm2022/frame-kit-ui-ng-ui-node-tree-breadcrumb.mjs.map +1 -0
  101. package/fesm2022/frame-kit-ui-ng-ui-node-tree.mjs +443 -0
  102. package/fesm2022/frame-kit-ui-ng-ui-node-tree.mjs.map +1 -0
  103. package/fesm2022/frame-kit-ui-ng-ui-note.mjs +56 -0
  104. package/fesm2022/frame-kit-ui-ng-ui-note.mjs.map +1 -0
  105. package/fesm2022/frame-kit-ui-ng-ui-numbered-list.mjs +105 -0
  106. package/fesm2022/frame-kit-ui-ng-ui-numbered-list.mjs.map +1 -0
  107. package/fesm2022/frame-kit-ui-ng-ui-pagination.mjs +110 -0
  108. package/fesm2022/frame-kit-ui-ng-ui-pagination.mjs.map +1 -0
  109. package/fesm2022/frame-kit-ui-ng-ui-progress-bar.mjs +129 -0
  110. package/fesm2022/frame-kit-ui-ng-ui-progress-bar.mjs.map +1 -0
  111. package/fesm2022/frame-kit-ui-ng-ui-sidenav-link.mjs +42 -0
  112. package/fesm2022/frame-kit-ui-ng-ui-sidenav-link.mjs.map +1 -0
  113. package/fesm2022/frame-kit-ui-ng-ui-tabs.mjs +894 -0
  114. package/fesm2022/frame-kit-ui-ng-ui-tabs.mjs.map +1 -0
  115. package/fesm2022/frame-kit-ui-ng-ui-timeline.mjs +81 -0
  116. package/fesm2022/frame-kit-ui-ng-ui-timeline.mjs.map +1 -0
  117. package/fesm2022/frame-kit-ui-ng-ui-toast.mjs +179 -0
  118. package/fesm2022/frame-kit-ui-ng-ui-toast.mjs.map +1 -0
  119. package/fesm2022/frame-kit-ui-ng-ui-user-menu.mjs +143 -0
  120. package/fesm2022/frame-kit-ui-ng-ui-user-menu.mjs.map +1 -0
  121. package/fesm2022/frame-kit-ui-ng-ui-wizard-dialog.mjs +191 -0
  122. package/fesm2022/frame-kit-ui-ng-ui-wizard-dialog.mjs.map +1 -0
  123. package/fesm2022/frame-kit-ui-ng.mjs +58 -0
  124. package/fesm2022/frame-kit-ui-ng.mjs.map +1 -0
  125. package/layouts/app-shell/README.md +357 -0
  126. package/layouts/content-split/README.md +180 -0
  127. package/package.json +253 -0
  128. package/services/overlay-orchestrator/README.md +184 -0
  129. package/services/spotlight/README.md +61 -0
  130. package/services/toast/README.md +118 -0
  131. package/types/frame-kit-ui-ng-core-headline.d.ts +38 -0
  132. package/types/frame-kit-ui-ng-core-icon.d.ts +74 -0
  133. package/types/frame-kit-ui-ng-core-image.d.ts +93 -0
  134. package/types/frame-kit-ui-ng-core-link.d.ts +251 -0
  135. package/types/frame-kit-ui-ng-core-separator.d.ts +28 -0
  136. package/types/frame-kit-ui-ng-core-text.d.ts +186 -0
  137. package/types/frame-kit-ui-ng-directives-infinite-scroll.d.ts +42 -0
  138. package/types/frame-kit-ui-ng-directives-spotlight.d.ts +51 -0
  139. package/types/frame-kit-ui-ng-directives-tooltip.d.ts +70 -0
  140. package/types/frame-kit-ui-ng-docs-endpoint-link.d.ts +43 -0
  141. package/types/frame-kit-ui-ng-docs-method-badge.d.ts +30 -0
  142. package/types/frame-kit-ui-ng-forms.d.ts +1674 -0
  143. package/types/frame-kit-ui-ng-layouts-app-shell.d.ts +75 -0
  144. package/types/frame-kit-ui-ng-layouts-content-split.d.ts +43 -0
  145. package/types/frame-kit-ui-ng-services-overlay-orchestrator.d.ts +96 -0
  146. package/types/frame-kit-ui-ng-services-spotlight.d.ts +32 -0
  147. package/types/frame-kit-ui-ng-services-toast.d.ts +100 -0
  148. package/types/frame-kit-ui-ng-ui-accordion.d.ts +86 -0
  149. package/types/frame-kit-ui-ng-ui-alert.d.ts +34 -0
  150. package/types/frame-kit-ui-ng-ui-avatar-stack.d.ts +38 -0
  151. package/types/frame-kit-ui-ng-ui-avatar.d.ts +36 -0
  152. package/types/frame-kit-ui-ng-ui-badge.d.ts +33 -0
  153. package/types/frame-kit-ui-ng-ui-breadcrumb.d.ts +45 -0
  154. package/types/frame-kit-ui-ng-ui-button.d.ts +48 -0
  155. package/types/frame-kit-ui-ng-ui-callout.d.ts +26 -0
  156. package/types/frame-kit-ui-ng-ui-card.d.ts +30 -0
  157. package/types/frame-kit-ui-ng-ui-copyable-field.d.ts +62 -0
  158. package/types/frame-kit-ui-ng-ui-data-table.d.ts +482 -0
  159. package/types/frame-kit-ui-ng-ui-dialog.d.ts +166 -0
  160. package/types/frame-kit-ui-ng-ui-drawer.d.ts +130 -0
  161. package/types/frame-kit-ui-ng-ui-dropdown-menu.d.ts +77 -0
  162. package/types/frame-kit-ui-ng-ui-editable-field.d.ts +65 -0
  163. package/types/frame-kit-ui-ng-ui-icon-badge.d.ts +45 -0
  164. package/types/frame-kit-ui-ng-ui-icon-list.d.ts +67 -0
  165. package/types/frame-kit-ui-ng-ui-inline-edit.d.ts +44 -0
  166. package/types/frame-kit-ui-ng-ui-list-editor.d.ts +56 -0
  167. package/types/frame-kit-ui-ng-ui-loader.d.ts +32 -0
  168. package/types/frame-kit-ui-ng-ui-menu-item.d.ts +27 -0
  169. package/types/frame-kit-ui-ng-ui-nav-brand.d.ts +25 -0
  170. package/types/frame-kit-ui-ng-ui-nav-group.d.ts +60 -0
  171. package/types/frame-kit-ui-ng-ui-nav-separator.d.ts +33 -0
  172. package/types/frame-kit-ui-ng-ui-node-tree-breadcrumb.d.ts +35 -0
  173. package/types/frame-kit-ui-ng-ui-node-tree.d.ts +135 -0
  174. package/types/frame-kit-ui-ng-ui-note.d.ts +22 -0
  175. package/types/frame-kit-ui-ng-ui-numbered-list.d.ts +52 -0
  176. package/types/frame-kit-ui-ng-ui-pagination.d.ts +49 -0
  177. package/types/frame-kit-ui-ng-ui-progress-bar.d.ts +50 -0
  178. package/types/frame-kit-ui-ng-ui-sidenav-link.d.ts +24 -0
  179. package/types/frame-kit-ui-ng-ui-tabs.d.ts +266 -0
  180. package/types/frame-kit-ui-ng-ui-timeline.d.ts +42 -0
  181. package/types/frame-kit-ui-ng-ui-toast.d.ts +56 -0
  182. package/types/frame-kit-ui-ng-ui-user-menu.d.ts +87 -0
  183. package/types/frame-kit-ui-ng-ui-wizard-dialog.d.ts +116 -0
  184. package/types/frame-kit-ui-ng.d.ts +53 -0
  185. package/ui/accordion/README.md +261 -0
  186. package/ui/alert/README.md +211 -0
  187. package/ui/avatar/README.md +167 -0
  188. package/ui/avatar-stack/README.md +164 -0
  189. package/ui/badge/README.md +162 -0
  190. package/ui/breadcrumb/README.md +240 -0
  191. package/ui/button/README.md +184 -0
  192. package/ui/callout/README.md +159 -0
  193. package/ui/card/README.md +174 -0
  194. package/ui/copyable-field/README.md +235 -0
  195. package/ui/data-table/README.md +408 -0
  196. package/ui/dialog/README.md +222 -0
  197. package/ui/drawer/README.md +274 -0
  198. package/ui/dropdown-menu/README.md +336 -0
  199. package/ui/editable-field/README.md +171 -0
  200. package/ui/icon-badge/README.md +131 -0
  201. package/ui/icon-list/README.md +205 -0
  202. package/ui/inline-edit/README.md +135 -0
  203. package/ui/list-editor/README.md +162 -0
  204. package/ui/loader/README.md +160 -0
  205. package/ui/menu-item/README.md +204 -0
  206. package/ui/nav-brand/README.md +111 -0
  207. package/ui/nav-group/README.md +145 -0
  208. package/ui/nav-separator/README.md +44 -0
  209. package/ui/node-tree/README.md +278 -0
  210. package/ui/node-tree-breadcrumb/README.md +164 -0
  211. package/ui/note/README.md +146 -0
  212. package/ui/numbered-list/README.md +187 -0
  213. package/ui/pagination/README.md +174 -0
  214. package/ui/progress-bar/README.md +223 -0
  215. package/ui/sidenav-link/README.md +214 -0
  216. package/ui/tabs/README.md +204 -0
  217. package/ui/timeline/README.md +285 -0
  218. package/ui/toast/README.md +243 -0
  219. package/ui/user-menu/README.md +260 -0
  220. package/ui/wizard-dialog/README.md +283 -0
@@ -0,0 +1,456 @@
1
+ import * as i1 from '@angular/cdk/a11y';
2
+ import { A11yModule } from '@angular/cdk/a11y';
3
+ import { DOCUMENT } from '@angular/common';
4
+ import * as i0 from '@angular/core';
5
+ import { Directive, input, contentChild, output, inject, DestroyRef, signal, computed, effect, HostListener, HostBinding, ChangeDetectionStrategy, Component, ApplicationRef, EnvironmentInjector, Injector, createComponent, Injectable } from '@angular/core';
6
+ import { OverlayOrchestrator, OVERLAY_PRIORITY } from '@frame-kit/ui-ng/services/overlay-orchestrator';
7
+ import { Subject } from 'rxjs';
8
+ import { take } from 'rxjs/operators';
9
+
10
+ class FkDialogHeaderDirective {
11
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: FkDialogHeaderDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
12
+ static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.9", type: FkDialogHeaderDirective, isStandalone: true, selector: "[fkDialogHeader]", ngImport: i0 });
13
+ }
14
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: FkDialogHeaderDirective, decorators: [{
15
+ type: Directive,
16
+ args: [{
17
+ selector: '[fkDialogHeader]',
18
+ standalone: true,
19
+ }]
20
+ }] });
21
+
22
+ let nextDialogId = 0;
23
+ class DialogComponent {
24
+ // ===== INPUTS =====
25
+ /** Controls whether the dialog is open. */
26
+ open = input(false, ...(ngDevMode ? [{ debugName: "open" }] : /* istanbul ignore next */ []));
27
+ /** When true, renders a backdrop overlay behind the dialog. */
28
+ modal = input(true, ...(ngDevMode ? [{ debugName: "modal" }] : /* istanbul ignore next */ []));
29
+ /** When true, shows the close button in the dialog header. */
30
+ closable = input(true, ...(ngDevMode ? [{ debugName: "closable" }] : /* istanbul ignore next */ []));
31
+ /** When true, pressing Escape closes the dialog. */
32
+ closeOnEscape = input(true, ...(ngDevMode ? [{ debugName: "closeOnEscape" }] : /* istanbul ignore next */ []));
33
+ /** When true, clicking the backdrop overlay closes the dialog. */
34
+ closeOnBackdrop = input(false, ...(ngDevMode ? [{ debugName: "closeOnBackdrop" }] : /* istanbul ignore next */ []));
35
+ /** Size variant that controls the dialog's max-width. */
36
+ size = input('md', ...(ngDevMode ? [{ debugName: "size" }] : /* istanbul ignore next */ []));
37
+ /** Where the dialog is anchored on screen. */
38
+ position = input('center', ...(ngDevMode ? [{ debugName: "position" }] : /* istanbul ignore next */ []));
39
+ /** Optional title text rendered in the dialog header and used for `aria-labelledby`. */
40
+ header = input(null, ...(ngDevMode ? [{ debugName: "header" }] : /* istanbul ignore next */ []));
41
+ /** When true, focus returns to the previously focused element when the dialog closes. */
42
+ restoreFocus = input(true, ...(ngDevMode ? [{ debugName: "restoreFocus" }] : /* istanbul ignore next */ []));
43
+ /** When true, CDK auto-focus is applied when the dialog opens. */
44
+ autoFocus = input(true, ...(ngDevMode ? [{ debugName: "autoFocus" }] : /* istanbul ignore next */ []));
45
+ /** Entry/exit animation applied to the dialog panel. */
46
+ animation = input('scale-fade', ...(ngDevMode ? [{ debugName: "animation" }] : /* istanbul ignore next */ []));
47
+ /** When true, all close mechanisms (Escape, backdrop, button) are blocked. */
48
+ preventClose = input(false, ...(ngDevMode ? [{ debugName: "preventClose" }] : /* istanbul ignore next */ []));
49
+ /** Async guard function called before closing; return false to cancel the close. */
50
+ canClose = input(null, ...(ngDevMode ? [{ debugName: "canClose" }] : /* istanbul ignore next */ []));
51
+ /** When true, the dialog expands to full-screen on mobile viewports. */
52
+ fullscreenMobile = input(false, ...(ngDevMode ? [{ debugName: "fullscreenMobile" }] : /* istanbul ignore next */ []));
53
+ /** When true, the dialog body uses a flex column layout. */
54
+ flexBody = input(false, ...(ngDevMode ? [{ debugName: "flexBody" }] : /* istanbul ignore next */ []));
55
+ // ===== CONTENT CHILDREN =====
56
+ customHeader = contentChild(FkDialogHeaderDirective, ...(ngDevMode ? [{ debugName: "customHeader" }] : /* istanbul ignore next */ []));
57
+ // ===== BASE PROPS =====
58
+ className = input('', ...(ngDevMode ? [{ debugName: "className" }] : /* istanbul ignore next */ []));
59
+ id = input(null, ...(ngDevMode ? [{ debugName: "id" }] : /* istanbul ignore next */ []));
60
+ ariaLabel = input(null, ...(ngDevMode ? [{ debugName: "ariaLabel" }] : /* istanbul ignore next */ []));
61
+ ariaDescribedBy = input(null, ...(ngDevMode ? [{ debugName: "ariaDescribedBy" }] : /* istanbul ignore next */ []));
62
+ // ===== OUTPUTS =====
63
+ /** Fires when the dialog's open state should change, emitting the new boolean. */
64
+ openChange = output();
65
+ /** Fires immediately before the dialog begins its open animation. */
66
+ beforeOpen = output();
67
+ /** Fires after the dialog is fully open and visible. */
68
+ opened = output();
69
+ /** Fires immediately before the dialog begins its close animation. */
70
+ beforeClose = output();
71
+ /** Fires after the dialog is fully closed. */
72
+ closed = output();
73
+ // ===== INTERNAL STATE =====
74
+ doc = inject(DOCUMENT);
75
+ destroyRef = inject(DestroyRef);
76
+ titleId = `fk-dialog-title-${nextDialogId++}`;
77
+ previouslyFocusedElement = null;
78
+ bodyScrollLocked = false;
79
+ closeGuardRunning = false;
80
+ /** Whether the dialog DOM is rendered (stays true during exit animation). */
81
+ visible = signal(false, ...(ngDevMode ? [{ debugName: "visible" }] : /* istanbul ignore next */ []));
82
+ /** Whether the dialog is animating out. */
83
+ animatingOut = signal(false, ...(ngDevMode ? [{ debugName: "animatingOut" }] : /* istanbul ignore next */ []));
84
+ // ===== COMPUTED =====
85
+ classes = computed(() => {
86
+ return ['fk-dialog', this.className()].filter(Boolean).join(' ');
87
+ }, ...(ngDevMode ? [{ debugName: "classes" }] : /* istanbul ignore next */ []));
88
+ ariaLabelledBy = computed(() => {
89
+ if (this.ariaLabel()) {
90
+ return null;
91
+ }
92
+ return this.header() ? this.titleId : null;
93
+ }, ...(ngDevMode ? [{ debugName: "ariaLabelledBy" }] : /* istanbul ignore next */ []));
94
+ constructor() {
95
+ effect(() => {
96
+ const isOpen = this.open();
97
+ if (isOpen) {
98
+ this.onDialogOpen();
99
+ }
100
+ else {
101
+ this.onDialogClose();
102
+ }
103
+ });
104
+ this.destroyRef.onDestroy(() => {
105
+ this.unlockBodyScroll();
106
+ });
107
+ }
108
+ get hostClass() {
109
+ return this.classes();
110
+ }
111
+ get hostId() {
112
+ return this.id();
113
+ }
114
+ // ===== KEYBOARD =====
115
+ onEscapeKey() {
116
+ if (this.open() && this.closeOnEscape()) {
117
+ this.close();
118
+ }
119
+ }
120
+ // ===== ACTIONS =====
121
+ /** Closes the dialog, running any `canClose` guard first; no-ops when `preventClose` is true. */
122
+ async close() {
123
+ if (this.closeGuardRunning) {
124
+ return;
125
+ }
126
+ if (this.preventClose()) {
127
+ return;
128
+ }
129
+ const guard = this.canClose();
130
+ if (guard) {
131
+ this.closeGuardRunning = true;
132
+ try {
133
+ const allowed = await Promise.resolve(guard());
134
+ if (!allowed) {
135
+ return;
136
+ }
137
+ }
138
+ finally {
139
+ this.closeGuardRunning = false;
140
+ }
141
+ }
142
+ this.beforeClose.emit();
143
+ this.openChange.emit(false);
144
+ this.closed.emit();
145
+ }
146
+ onOverlayClick() {
147
+ if (this.closeOnBackdrop()) {
148
+ this.close();
149
+ }
150
+ }
151
+ /** Called when the overlay exit animation finishes. */
152
+ onExitAnimationDone() {
153
+ if (this.animatingOut()) {
154
+ this.animatingOut.set(false);
155
+ this.visible.set(false);
156
+ }
157
+ }
158
+ // ===== LIFECYCLE =====
159
+ onDialogOpen() {
160
+ this.previouslyFocusedElement =
161
+ this.doc.activeElement ?? null;
162
+ this.beforeOpen.emit();
163
+ this.animatingOut.set(false);
164
+ this.visible.set(true);
165
+ if (this.modal()) {
166
+ this.lockBodyScroll();
167
+ }
168
+ this.opened.emit();
169
+ }
170
+ onDialogClose() {
171
+ this.unlockBodyScroll();
172
+ if (this.visible()) {
173
+ if (this.animation() !== 'none') {
174
+ this.animatingOut.set(true);
175
+ }
176
+ else {
177
+ this.visible.set(false);
178
+ }
179
+ }
180
+ if (this.restoreFocus() && this.previouslyFocusedElement) {
181
+ this.previouslyFocusedElement.focus();
182
+ this.previouslyFocusedElement = null;
183
+ }
184
+ }
185
+ // ===== SCROLL LOCK =====
186
+ lockBodyScroll() {
187
+ if (!this.bodyScrollLocked) {
188
+ this.doc.body.style.overflow = 'hidden';
189
+ this.bodyScrollLocked = true;
190
+ }
191
+ }
192
+ unlockBodyScroll() {
193
+ if (this.bodyScrollLocked) {
194
+ this.doc.body.style.overflow = '';
195
+ this.bodyScrollLocked = false;
196
+ }
197
+ }
198
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: DialogComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
199
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.9", type: DialogComponent, isStandalone: true, selector: "fk-dialog", inputs: { open: { classPropertyName: "open", publicName: "open", isSignal: true, isRequired: false, transformFunction: null }, modal: { classPropertyName: "modal", publicName: "modal", isSignal: true, isRequired: false, transformFunction: null }, closable: { classPropertyName: "closable", publicName: "closable", isSignal: true, isRequired: false, transformFunction: null }, closeOnEscape: { classPropertyName: "closeOnEscape", publicName: "closeOnEscape", isSignal: true, isRequired: false, transformFunction: null }, closeOnBackdrop: { classPropertyName: "closeOnBackdrop", publicName: "closeOnBackdrop", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, position: { classPropertyName: "position", publicName: "position", isSignal: true, isRequired: false, transformFunction: null }, header: { classPropertyName: "header", publicName: "header", isSignal: true, isRequired: false, transformFunction: null }, restoreFocus: { classPropertyName: "restoreFocus", publicName: "restoreFocus", isSignal: true, isRequired: false, transformFunction: null }, autoFocus: { classPropertyName: "autoFocus", publicName: "autoFocus", isSignal: true, isRequired: false, transformFunction: null }, animation: { classPropertyName: "animation", publicName: "animation", isSignal: true, isRequired: false, transformFunction: null }, preventClose: { classPropertyName: "preventClose", publicName: "preventClose", isSignal: true, isRequired: false, transformFunction: null }, canClose: { classPropertyName: "canClose", publicName: "canClose", isSignal: true, isRequired: false, transformFunction: null }, fullscreenMobile: { classPropertyName: "fullscreenMobile", publicName: "fullscreenMobile", isSignal: true, isRequired: false, transformFunction: null }, flexBody: { classPropertyName: "flexBody", publicName: "flexBody", isSignal: true, isRequired: false, transformFunction: null }, className: { classPropertyName: "className", publicName: "className", isSignal: true, isRequired: false, transformFunction: null }, id: { classPropertyName: "id", publicName: "id", isSignal: true, isRequired: false, transformFunction: null }, ariaLabel: { classPropertyName: "ariaLabel", publicName: "ariaLabel", isSignal: true, isRequired: false, transformFunction: null }, ariaDescribedBy: { classPropertyName: "ariaDescribedBy", publicName: "ariaDescribedBy", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { openChange: "openChange", beforeOpen: "beforeOpen", opened: "opened", beforeClose: "beforeClose", closed: "closed" }, host: { listeners: { "document:keydown.escape": "onEscapeKey()" }, properties: { "class": "this.hostClass", "attr.id": "this.hostId" } }, queries: [{ propertyName: "customHeader", first: true, predicate: FkDialogHeaderDirective, descendants: true, isSignal: true }], ngImport: i0, template: "@if (visible()) {\n <!-- eslint-disable-next-line @angular-eslint/template/click-events-have-key-events, @angular-eslint/template/interactive-supports-focus -->\n <div\n class=\"fk-dialog__overlay\"\n [class.fk-dialog__overlay--modal]=\"modal()\"\n [class.fk-dialog__animate-overlay--in]=\"!animatingOut()\"\n [class.fk-dialog__animate-overlay--out]=\"animatingOut()\"\n [class.fk-dialog__animate-overlay--none]=\"animation() === 'none'\"\n (click)=\"onOverlayClick()\"\n (animationend)=\"onExitAnimationDone()\"\n >\n <!-- eslint-disable-next-line @angular-eslint/template/click-events-have-key-events -->\n <div\n class=\"fk-dialog__panel\"\n [class.fk-dialog__animate-panel--scale-fade]=\"\n animation() === 'scale-fade' && !animatingOut()\n \"\n [class.fk-dialog__animate-panel--fade]=\"\n animation() === 'fade' && !animatingOut()\n \"\n [class.fk-dialog__animate-panel--slide-up]=\"\n animation() === 'slide-up' && !animatingOut()\n \"\n [class.fk-dialog__animate-panel--slide-down]=\"\n animation() === 'slide-down' && !animatingOut()\n \"\n [class.fk-dialog__animate-panel-out--scale-fade]=\"\n animation() === 'scale-fade' && animatingOut()\n \"\n [class.fk-dialog__animate-panel-out--fade]=\"\n animation() === 'fade' && animatingOut()\n \"\n [class.fk-dialog__animate-panel-out--slide-up]=\"\n animation() === 'slide-up' && animatingOut()\n \"\n [class.fk-dialog__animate-panel-out--slide-down]=\"\n animation() === 'slide-down' && animatingOut()\n \"\n [class.fk-dialog__panel--sm]=\"size() === 'sm'\"\n [class.fk-dialog__panel--md]=\"size() === 'md'\"\n [class.fk-dialog__panel--lg]=\"size() === 'lg'\"\n [class.fk-dialog__panel--xl]=\"size() === 'xl'\"\n [class.fk-dialog__panel--fullscreen]=\"size() === 'fullscreen'\"\n [class.fk-dialog__panel--fullscreen-auto]=\"fullscreenMobile()\"\n [class.fk-dialog__panel--top]=\"position() === 'top'\"\n role=\"dialog\"\n [attr.aria-modal]=\"modal() ? 'true' : null\"\n [attr.aria-label]=\"ariaLabel()\"\n [attr.aria-labelledby]=\"ariaLabelledBy()\"\n [attr.aria-describedby]=\"ariaDescribedBy()\"\n [cdkTrapFocus]=\"modal()\"\n [cdkTrapFocusAutoCapture]=\"autoFocus()\"\n (click)=\"$event.stopPropagation()\"\n >\n @if (customHeader() || header() || closable()) {\n <div class=\"fk-dialog__header\">\n <ng-content select=\"[fkDialogHeader]\" />\n\n @if (!customHeader() && header()) {\n <span class=\"fk-dialog__title\" [id]=\"titleId\">{{ header() }}</span>\n }\n\n @if (closable()) {\n <button\n class=\"fk-dialog__close\"\n type=\"button\"\n aria-label=\"Close dialog\"\n (click)=\"close()\"\n >\n &times;\n </button>\n }\n </div>\n }\n\n <div class=\"fk-dialog__body\" [class.fk-dialog__body--flex]=\"flexBody()\">\n <ng-content />\n </div>\n\n <ng-content select=\"[libDialogFooter]\" />\n </div>\n </div>\n}\n", styles: [":host{display:contents}.fk-dialog__overlay{position:fixed;inset:0;z-index:var(--fk-dialog-overlay-z-index, 1000);display:flex;align-items:center;justify-content:center;padding:var(--fk-dialog-panel-margin, var(--fk-rhythm-4, 1rem))}.fk-dialog__overlay--modal{background:var(--fk-dialog-overlay-bg, rgba(0, 0, 0, .5))}.fk-dialog__overlay.fk-dialog__animate-overlay--in{animation:fk-dialog-overlay-fade-in .2s cubic-bezier(.4,0,.2,1) both}.fk-dialog__overlay.fk-dialog__animate-overlay--out{animation:fk-dialog-overlay-fade-out .2s cubic-bezier(.4,0,.2,1) both}.fk-dialog__overlay.fk-dialog__animate-overlay--none{animation:none}.fk-dialog__panel{display:flex;flex-direction:column;background:var(--fk-dialog-panel-bg, var(--fk-color-surface, #ffffff));border:var(--fk-dialog-panel-border, none);border-radius:var(--fk-dialog-panel-border-radius, var(--fk-radius-lg, .75rem));box-shadow:var(--fk-dialog-panel-shadow, 0 8px 32px rgba(0, 0, 0, .12));max-height:var(--fk-dialog-panel-max-height, 85vh);width:100%;overflow:clip}.fk-dialog__panel--sm{max-width:var(--fk-dialog-width-sm, 24rem)}.fk-dialog__panel--md{max-width:var(--fk-dialog-width-md, 32rem)}.fk-dialog__panel--lg{max-width:var(--fk-dialog-width-lg, 40rem)}.fk-dialog__panel--xl{max-width:var(--fk-dialog-width-xl, 52rem)}.fk-dialog__panel--fullscreen{max-width:none;max-height:none;width:100%;height:100%;border-radius:0}@media(max-width:47.999em){.fk-dialog__panel--fullscreen-auto{max-width:none;max-height:none;width:100%;height:100%;border-radius:0}}.fk-dialog__panel--top{align-self:flex-start}.fk-dialog__panel.fk-dialog__animate-panel--scale-fade{animation:fk-dialog-scale-fade-in .2s cubic-bezier(.4,0,.2,1) both}.fk-dialog__panel.fk-dialog__animate-panel-out--scale-fade{animation:fk-dialog-scale-fade-out .2s cubic-bezier(.4,0,.2,1) both}.fk-dialog__panel.fk-dialog__animate-panel--fade{animation:fk-dialog-fade-in .2s cubic-bezier(.4,0,.2,1) both}.fk-dialog__panel.fk-dialog__animate-panel-out--fade{animation:fk-dialog-fade-out .2s cubic-bezier(.4,0,.2,1) both}.fk-dialog__panel.fk-dialog__animate-panel--slide-up{animation:fk-dialog-slide-up-in .2s cubic-bezier(.4,0,.2,1) both}.fk-dialog__panel.fk-dialog__animate-panel-out--slide-up{animation:fk-dialog-slide-up-out .2s cubic-bezier(.4,0,.2,1) both}.fk-dialog__panel.fk-dialog__animate-panel--slide-down{animation:fk-dialog-slide-down-in .2s cubic-bezier(.4,0,.2,1) both}.fk-dialog__panel.fk-dialog__animate-panel-out--slide-down{animation:fk-dialog-slide-down-out .2s cubic-bezier(.4,0,.2,1) both}.fk-dialog__header{display:flex;align-items:center;justify-content:center;position:relative;padding:var(--fk-dialog-header-padding, var(--fk-rhythm-4, 1rem) var(--fk-dialog-header-padding-inline, var(--fk-rhythm-6, 1.5rem)));flex-shrink:0}.fk-dialog__title{font-family:var(--fk-font-family-base, \"Inter\", ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, \"Apple Color Emoji\", \"Segoe UI Emoji\");font-size:var(--fk-typography-h4-font-size, 1.125rem);font-weight:var(--fk-font-weight-semibold, 600);color:var(--fk-color-text, #1f2d3d);line-height:var(--fk-typography-h4-line-height, 1.25);padding-inline-end:var(--fk-rhythm-7, 2rem)}.fk-dialog__close{position:absolute;right:var(--fk-dialog-header-padding-inline, var(--fk-rhythm-6, 1.5rem));display:flex;align-items:center;justify-content:center;width:var(--fk-dialog-close-size, 2rem);height:var(--fk-dialog-close-size, 2rem);padding:0;border:none;border-radius:var(--fk-radius-sm, .25rem);background:transparent;color:var(--fk-dialog-close-color, var(--fk-color-muted, #8a98a8));font-size:var(--fk-font-size-xl, 1.25rem);line-height:1;cursor:pointer;transition:color .15s ease,background-color .15s ease}.fk-dialog__close:hover{color:var(--fk-dialog-close-color-hover, var(--fk-color-text, #1f2d3d));background-color:var(--fk-color-surface-muted, #f7f9fb)}.fk-dialog__close:focus-visible{outline:none;box-shadow:var(--fk-focus-ring, 0 0 0 3px rgba(10, 132, 255, .18))}.fk-dialog__body{flex:1;padding:var(--fk-dialog-body-padding, var(--fk-rhythm-6, 1.5rem));overflow-y:auto;overscroll-behavior:contain;container-type:inline-size}.fk-dialog__body--flex{display:flex;flex-direction:column;overflow:hidden}::ng-deep [libDialogFooter]{display:flex;align-items:center;justify-content:center;gap:var(--fk-dialog-footer-gap, .75rem);padding:var(--fk-dialog-footer-padding, var(--fk-rhythm-4, 1rem) var(--fk-rhythm-6, 1.5rem));border-top:var(--fk-dialog-footer-border, 1px solid var(--fk-color-border, #d9e2ee));flex-shrink:0}::ng-deep [libDialogFooter]>*{flex:1 1 0;min-width:0}::ng-deep [fkDialogActions]{display:flex;gap:var(--fk-dialog-actions-gap, var(--fk-rhythm-3, .75rem));margin-top:var(--fk-dialog-actions-margin-top, var(--fk-rhythm-5, 1.25rem))}::ng-deep [fkDialogActions]>*{flex:1 1 0;min-width:0}@container (max-width: 24rem){::ng-deep [fkDialogActions]{flex-direction:column-reverse}::ng-deep [fkDialogActions]>*{flex:none;width:100%}}@keyframes fk-dialog-overlay-fade-in{0%{opacity:0}to{opacity:1}}@keyframes fk-dialog-overlay-fade-out{0%{opacity:1}to{opacity:0}}@keyframes fk-dialog-scale-fade-in{0%{opacity:0;transform:scale(.95)}to{opacity:1;transform:scale(1)}}@keyframes fk-dialog-scale-fade-out{0%{opacity:1;transform:scale(1)}to{opacity:0;transform:scale(.95)}}@keyframes fk-dialog-fade-in{0%{opacity:0}to{opacity:1}}@keyframes fk-dialog-fade-out{0%{opacity:1}to{opacity:0}}@keyframes fk-dialog-slide-up-in{0%{opacity:0;transform:translateY(1rem)}to{opacity:1;transform:translateY(0)}}@keyframes fk-dialog-slide-up-out{0%{opacity:1;transform:translateY(0)}to{opacity:0;transform:translateY(1rem)}}@keyframes fk-dialog-slide-down-in{0%{opacity:0;transform:translateY(-1rem)}to{opacity:1;transform:translateY(0)}}@keyframes fk-dialog-slide-down-out{0%{opacity:1;transform:translateY(0)}to{opacity:0;transform:translateY(-1rem)}}@media(prefers-reduced-motion:reduce){.fk-dialog__animate-overlay--in,.fk-dialog__animate-overlay--out,.fk-dialog__animate-panel--scale-fade,.fk-dialog__animate-panel--fade,.fk-dialog__animate-panel--slide-up,.fk-dialog__animate-panel--slide-down,.fk-dialog__animate-panel-out--scale-fade,.fk-dialog__animate-panel-out--fade,.fk-dialog__animate-panel-out--slide-up,.fk-dialog__animate-panel-out--slide-down{animation:none}}\n"], dependencies: [{ kind: "ngmodule", type: A11yModule }, { kind: "directive", type: i1.CdkTrapFocus, selector: "[cdkTrapFocus]", inputs: ["cdkTrapFocus", "cdkTrapFocusAutoCapture"], exportAs: ["cdkTrapFocus"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
200
+ }
201
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: DialogComponent, decorators: [{
202
+ type: Component,
203
+ args: [{ selector: 'fk-dialog', standalone: true, imports: [A11yModule], changeDetection: ChangeDetectionStrategy.OnPush, template: "@if (visible()) {\n <!-- eslint-disable-next-line @angular-eslint/template/click-events-have-key-events, @angular-eslint/template/interactive-supports-focus -->\n <div\n class=\"fk-dialog__overlay\"\n [class.fk-dialog__overlay--modal]=\"modal()\"\n [class.fk-dialog__animate-overlay--in]=\"!animatingOut()\"\n [class.fk-dialog__animate-overlay--out]=\"animatingOut()\"\n [class.fk-dialog__animate-overlay--none]=\"animation() === 'none'\"\n (click)=\"onOverlayClick()\"\n (animationend)=\"onExitAnimationDone()\"\n >\n <!-- eslint-disable-next-line @angular-eslint/template/click-events-have-key-events -->\n <div\n class=\"fk-dialog__panel\"\n [class.fk-dialog__animate-panel--scale-fade]=\"\n animation() === 'scale-fade' && !animatingOut()\n \"\n [class.fk-dialog__animate-panel--fade]=\"\n animation() === 'fade' && !animatingOut()\n \"\n [class.fk-dialog__animate-panel--slide-up]=\"\n animation() === 'slide-up' && !animatingOut()\n \"\n [class.fk-dialog__animate-panel--slide-down]=\"\n animation() === 'slide-down' && !animatingOut()\n \"\n [class.fk-dialog__animate-panel-out--scale-fade]=\"\n animation() === 'scale-fade' && animatingOut()\n \"\n [class.fk-dialog__animate-panel-out--fade]=\"\n animation() === 'fade' && animatingOut()\n \"\n [class.fk-dialog__animate-panel-out--slide-up]=\"\n animation() === 'slide-up' && animatingOut()\n \"\n [class.fk-dialog__animate-panel-out--slide-down]=\"\n animation() === 'slide-down' && animatingOut()\n \"\n [class.fk-dialog__panel--sm]=\"size() === 'sm'\"\n [class.fk-dialog__panel--md]=\"size() === 'md'\"\n [class.fk-dialog__panel--lg]=\"size() === 'lg'\"\n [class.fk-dialog__panel--xl]=\"size() === 'xl'\"\n [class.fk-dialog__panel--fullscreen]=\"size() === 'fullscreen'\"\n [class.fk-dialog__panel--fullscreen-auto]=\"fullscreenMobile()\"\n [class.fk-dialog__panel--top]=\"position() === 'top'\"\n role=\"dialog\"\n [attr.aria-modal]=\"modal() ? 'true' : null\"\n [attr.aria-label]=\"ariaLabel()\"\n [attr.aria-labelledby]=\"ariaLabelledBy()\"\n [attr.aria-describedby]=\"ariaDescribedBy()\"\n [cdkTrapFocus]=\"modal()\"\n [cdkTrapFocusAutoCapture]=\"autoFocus()\"\n (click)=\"$event.stopPropagation()\"\n >\n @if (customHeader() || header() || closable()) {\n <div class=\"fk-dialog__header\">\n <ng-content select=\"[fkDialogHeader]\" />\n\n @if (!customHeader() && header()) {\n <span class=\"fk-dialog__title\" [id]=\"titleId\">{{ header() }}</span>\n }\n\n @if (closable()) {\n <button\n class=\"fk-dialog__close\"\n type=\"button\"\n aria-label=\"Close dialog\"\n (click)=\"close()\"\n >\n &times;\n </button>\n }\n </div>\n }\n\n <div class=\"fk-dialog__body\" [class.fk-dialog__body--flex]=\"flexBody()\">\n <ng-content />\n </div>\n\n <ng-content select=\"[libDialogFooter]\" />\n </div>\n </div>\n}\n", styles: [":host{display:contents}.fk-dialog__overlay{position:fixed;inset:0;z-index:var(--fk-dialog-overlay-z-index, 1000);display:flex;align-items:center;justify-content:center;padding:var(--fk-dialog-panel-margin, var(--fk-rhythm-4, 1rem))}.fk-dialog__overlay--modal{background:var(--fk-dialog-overlay-bg, rgba(0, 0, 0, .5))}.fk-dialog__overlay.fk-dialog__animate-overlay--in{animation:fk-dialog-overlay-fade-in .2s cubic-bezier(.4,0,.2,1) both}.fk-dialog__overlay.fk-dialog__animate-overlay--out{animation:fk-dialog-overlay-fade-out .2s cubic-bezier(.4,0,.2,1) both}.fk-dialog__overlay.fk-dialog__animate-overlay--none{animation:none}.fk-dialog__panel{display:flex;flex-direction:column;background:var(--fk-dialog-panel-bg, var(--fk-color-surface, #ffffff));border:var(--fk-dialog-panel-border, none);border-radius:var(--fk-dialog-panel-border-radius, var(--fk-radius-lg, .75rem));box-shadow:var(--fk-dialog-panel-shadow, 0 8px 32px rgba(0, 0, 0, .12));max-height:var(--fk-dialog-panel-max-height, 85vh);width:100%;overflow:clip}.fk-dialog__panel--sm{max-width:var(--fk-dialog-width-sm, 24rem)}.fk-dialog__panel--md{max-width:var(--fk-dialog-width-md, 32rem)}.fk-dialog__panel--lg{max-width:var(--fk-dialog-width-lg, 40rem)}.fk-dialog__panel--xl{max-width:var(--fk-dialog-width-xl, 52rem)}.fk-dialog__panel--fullscreen{max-width:none;max-height:none;width:100%;height:100%;border-radius:0}@media(max-width:47.999em){.fk-dialog__panel--fullscreen-auto{max-width:none;max-height:none;width:100%;height:100%;border-radius:0}}.fk-dialog__panel--top{align-self:flex-start}.fk-dialog__panel.fk-dialog__animate-panel--scale-fade{animation:fk-dialog-scale-fade-in .2s cubic-bezier(.4,0,.2,1) both}.fk-dialog__panel.fk-dialog__animate-panel-out--scale-fade{animation:fk-dialog-scale-fade-out .2s cubic-bezier(.4,0,.2,1) both}.fk-dialog__panel.fk-dialog__animate-panel--fade{animation:fk-dialog-fade-in .2s cubic-bezier(.4,0,.2,1) both}.fk-dialog__panel.fk-dialog__animate-panel-out--fade{animation:fk-dialog-fade-out .2s cubic-bezier(.4,0,.2,1) both}.fk-dialog__panel.fk-dialog__animate-panel--slide-up{animation:fk-dialog-slide-up-in .2s cubic-bezier(.4,0,.2,1) both}.fk-dialog__panel.fk-dialog__animate-panel-out--slide-up{animation:fk-dialog-slide-up-out .2s cubic-bezier(.4,0,.2,1) both}.fk-dialog__panel.fk-dialog__animate-panel--slide-down{animation:fk-dialog-slide-down-in .2s cubic-bezier(.4,0,.2,1) both}.fk-dialog__panel.fk-dialog__animate-panel-out--slide-down{animation:fk-dialog-slide-down-out .2s cubic-bezier(.4,0,.2,1) both}.fk-dialog__header{display:flex;align-items:center;justify-content:center;position:relative;padding:var(--fk-dialog-header-padding, var(--fk-rhythm-4, 1rem) var(--fk-dialog-header-padding-inline, var(--fk-rhythm-6, 1.5rem)));flex-shrink:0}.fk-dialog__title{font-family:var(--fk-font-family-base, \"Inter\", ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, \"Apple Color Emoji\", \"Segoe UI Emoji\");font-size:var(--fk-typography-h4-font-size, 1.125rem);font-weight:var(--fk-font-weight-semibold, 600);color:var(--fk-color-text, #1f2d3d);line-height:var(--fk-typography-h4-line-height, 1.25);padding-inline-end:var(--fk-rhythm-7, 2rem)}.fk-dialog__close{position:absolute;right:var(--fk-dialog-header-padding-inline, var(--fk-rhythm-6, 1.5rem));display:flex;align-items:center;justify-content:center;width:var(--fk-dialog-close-size, 2rem);height:var(--fk-dialog-close-size, 2rem);padding:0;border:none;border-radius:var(--fk-radius-sm, .25rem);background:transparent;color:var(--fk-dialog-close-color, var(--fk-color-muted, #8a98a8));font-size:var(--fk-font-size-xl, 1.25rem);line-height:1;cursor:pointer;transition:color .15s ease,background-color .15s ease}.fk-dialog__close:hover{color:var(--fk-dialog-close-color-hover, var(--fk-color-text, #1f2d3d));background-color:var(--fk-color-surface-muted, #f7f9fb)}.fk-dialog__close:focus-visible{outline:none;box-shadow:var(--fk-focus-ring, 0 0 0 3px rgba(10, 132, 255, .18))}.fk-dialog__body{flex:1;padding:var(--fk-dialog-body-padding, var(--fk-rhythm-6, 1.5rem));overflow-y:auto;overscroll-behavior:contain;container-type:inline-size}.fk-dialog__body--flex{display:flex;flex-direction:column;overflow:hidden}::ng-deep [libDialogFooter]{display:flex;align-items:center;justify-content:center;gap:var(--fk-dialog-footer-gap, .75rem);padding:var(--fk-dialog-footer-padding, var(--fk-rhythm-4, 1rem) var(--fk-rhythm-6, 1.5rem));border-top:var(--fk-dialog-footer-border, 1px solid var(--fk-color-border, #d9e2ee));flex-shrink:0}::ng-deep [libDialogFooter]>*{flex:1 1 0;min-width:0}::ng-deep [fkDialogActions]{display:flex;gap:var(--fk-dialog-actions-gap, var(--fk-rhythm-3, .75rem));margin-top:var(--fk-dialog-actions-margin-top, var(--fk-rhythm-5, 1.25rem))}::ng-deep [fkDialogActions]>*{flex:1 1 0;min-width:0}@container (max-width: 24rem){::ng-deep [fkDialogActions]{flex-direction:column-reverse}::ng-deep [fkDialogActions]>*{flex:none;width:100%}}@keyframes fk-dialog-overlay-fade-in{0%{opacity:0}to{opacity:1}}@keyframes fk-dialog-overlay-fade-out{0%{opacity:1}to{opacity:0}}@keyframes fk-dialog-scale-fade-in{0%{opacity:0;transform:scale(.95)}to{opacity:1;transform:scale(1)}}@keyframes fk-dialog-scale-fade-out{0%{opacity:1;transform:scale(1)}to{opacity:0;transform:scale(.95)}}@keyframes fk-dialog-fade-in{0%{opacity:0}to{opacity:1}}@keyframes fk-dialog-fade-out{0%{opacity:1}to{opacity:0}}@keyframes fk-dialog-slide-up-in{0%{opacity:0;transform:translateY(1rem)}to{opacity:1;transform:translateY(0)}}@keyframes fk-dialog-slide-up-out{0%{opacity:1;transform:translateY(0)}to{opacity:0;transform:translateY(1rem)}}@keyframes fk-dialog-slide-down-in{0%{opacity:0;transform:translateY(-1rem)}to{opacity:1;transform:translateY(0)}}@keyframes fk-dialog-slide-down-out{0%{opacity:1;transform:translateY(0)}to{opacity:0;transform:translateY(-1rem)}}@media(prefers-reduced-motion:reduce){.fk-dialog__animate-overlay--in,.fk-dialog__animate-overlay--out,.fk-dialog__animate-panel--scale-fade,.fk-dialog__animate-panel--fade,.fk-dialog__animate-panel--slide-up,.fk-dialog__animate-panel--slide-down,.fk-dialog__animate-panel-out--scale-fade,.fk-dialog__animate-panel-out--fade,.fk-dialog__animate-panel-out--slide-up,.fk-dialog__animate-panel-out--slide-down{animation:none}}\n"] }]
204
+ }], ctorParameters: () => [], propDecorators: { open: [{ type: i0.Input, args: [{ isSignal: true, alias: "open", required: false }] }], modal: [{ type: i0.Input, args: [{ isSignal: true, alias: "modal", required: false }] }], closable: [{ type: i0.Input, args: [{ isSignal: true, alias: "closable", required: false }] }], closeOnEscape: [{ type: i0.Input, args: [{ isSignal: true, alias: "closeOnEscape", required: false }] }], closeOnBackdrop: [{ type: i0.Input, args: [{ isSignal: true, alias: "closeOnBackdrop", required: false }] }], size: [{ type: i0.Input, args: [{ isSignal: true, alias: "size", required: false }] }], position: [{ type: i0.Input, args: [{ isSignal: true, alias: "position", required: false }] }], header: [{ type: i0.Input, args: [{ isSignal: true, alias: "header", required: false }] }], restoreFocus: [{ type: i0.Input, args: [{ isSignal: true, alias: "restoreFocus", required: false }] }], autoFocus: [{ type: i0.Input, args: [{ isSignal: true, alias: "autoFocus", required: false }] }], animation: [{ type: i0.Input, args: [{ isSignal: true, alias: "animation", required: false }] }], preventClose: [{ type: i0.Input, args: [{ isSignal: true, alias: "preventClose", required: false }] }], canClose: [{ type: i0.Input, args: [{ isSignal: true, alias: "canClose", required: false }] }], fullscreenMobile: [{ type: i0.Input, args: [{ isSignal: true, alias: "fullscreenMobile", required: false }] }], flexBody: [{ type: i0.Input, args: [{ isSignal: true, alias: "flexBody", required: false }] }], customHeader: [{ type: i0.ContentChild, args: [i0.forwardRef(() => FkDialogHeaderDirective), { isSignal: true }] }], className: [{ type: i0.Input, args: [{ isSignal: true, alias: "className", required: false }] }], id: [{ type: i0.Input, args: [{ isSignal: true, alias: "id", required: false }] }], ariaLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "ariaLabel", required: false }] }], ariaDescribedBy: [{ type: i0.Input, args: [{ isSignal: true, alias: "ariaDescribedBy", required: false }] }], openChange: [{ type: i0.Output, args: ["openChange"] }], beforeOpen: [{ type: i0.Output, args: ["beforeOpen"] }], opened: [{ type: i0.Output, args: ["opened"] }], beforeClose: [{ type: i0.Output, args: ["beforeClose"] }], closed: [{ type: i0.Output, args: ["closed"] }], hostClass: [{
205
+ type: HostBinding,
206
+ args: ['class']
207
+ }], hostId: [{
208
+ type: HostBinding,
209
+ args: ['attr.id']
210
+ }], onEscapeKey: [{
211
+ type: HostListener,
212
+ args: ['document:keydown.escape']
213
+ }] } });
214
+
215
+ const DEFAULT_DIALOG_CONFIG = {
216
+ modal: true,
217
+ closable: true,
218
+ closeOnEscape: true,
219
+ closeOnBackdrop: false,
220
+ size: 'md',
221
+ position: 'center',
222
+ animation: 'scale-fade',
223
+ header: null,
224
+ restoreFocus: true,
225
+ autoFocus: true,
226
+ preventClose: false,
227
+ fullscreenMobile: false,
228
+ flexBody: false,
229
+ className: '',
230
+ ariaLabel: null,
231
+ ariaDescribedBy: null,
232
+ };
233
+
234
+ class DialogRef {
235
+ beforeOpenSubject = new Subject();
236
+ afterOpenedSubject = new Subject();
237
+ beforeCloseSubject = new Subject();
238
+ afterClosedSubject = new Subject();
239
+ closed = false;
240
+ closeGuard = null;
241
+ config;
242
+ constructor(config = {}) {
243
+ this.config = config;
244
+ if (config.canClose) {
245
+ this.closeGuard = config.canClose;
246
+ }
247
+ }
248
+ get data() {
249
+ return this.config.data;
250
+ }
251
+ setCanClose(guard) {
252
+ this.closeGuard = guard;
253
+ }
254
+ async close(result) {
255
+ if (this.closed) {
256
+ return;
257
+ }
258
+ if (this.config.preventClose) {
259
+ return;
260
+ }
261
+ if (this.closeGuard) {
262
+ const allowed = await Promise.resolve(this.closeGuard());
263
+ if (!allowed) {
264
+ return;
265
+ }
266
+ }
267
+ this.beforeCloseSubject.next();
268
+ this.beforeCloseSubject.complete();
269
+ this.closed = true;
270
+ this.afterClosedSubject.next(result);
271
+ this.afterClosedSubject.complete();
272
+ }
273
+ beforeOpen() {
274
+ return this.beforeOpenSubject.asObservable().pipe(take(1));
275
+ }
276
+ afterOpened() {
277
+ return this.afterOpenedSubject.asObservable().pipe(take(1));
278
+ }
279
+ beforeClose() {
280
+ return this.beforeCloseSubject.asObservable().pipe(take(1));
281
+ }
282
+ afterClosed() {
283
+ return this.afterClosedSubject.asObservable().pipe(take(1));
284
+ }
285
+ /** @internal */
286
+ markBeforeOpen() {
287
+ this.beforeOpenSubject.next();
288
+ this.beforeOpenSubject.complete();
289
+ }
290
+ /** @internal */
291
+ markOpened() {
292
+ this.afterOpenedSubject.next();
293
+ this.afterOpenedSubject.complete();
294
+ }
295
+ }
296
+
297
+ const DIALOG_DATA = Symbol('DIALOG_DATA');
298
+ const DIALOG_REF = Symbol('DIALOG_REF');
299
+ const BASE_Z_INDEX = 1000;
300
+ const Z_INDEX_STEP = 10;
301
+ class DialogService {
302
+ appRef = inject(ApplicationRef);
303
+ injector = inject(EnvironmentInjector);
304
+ doc = inject(DOCUMENT);
305
+ orchestrator = inject(OverlayOrchestrator);
306
+ activeDialogs = [];
307
+ overlayIds = new Map();
308
+ get openCount() {
309
+ return this.activeDialogs.length;
310
+ }
311
+ open(content, config) {
312
+ const mergedConfig = {
313
+ ...DEFAULT_DIALOG_CONFIG,
314
+ ...config,
315
+ };
316
+ const dialogRef = new DialogRef(mergedConfig);
317
+ const childInjector = Injector.create({
318
+ parent: this.injector,
319
+ providers: [
320
+ { provide: DIALOG_DATA, useValue: mergedConfig.data },
321
+ { provide: DIALOG_REF, useValue: dialogRef },
322
+ ],
323
+ });
324
+ const hostRef = createComponent(DialogComponent, {
325
+ environmentInjector: this.injector,
326
+ elementInjector: childInjector,
327
+ });
328
+ const contentRef = createComponent(content, {
329
+ environmentInjector: this.injector,
330
+ elementInjector: childInjector,
331
+ hostElement: this.doc.createElement('div'),
332
+ });
333
+ this.applyConfig(hostRef, mergedConfig);
334
+ this.appRef.attachView(hostRef.hostView);
335
+ this.appRef.attachView(contentRef.hostView);
336
+ this.doc.body.appendChild(hostRef.location.nativeElement);
337
+ const entry = {
338
+ ref: dialogRef,
339
+ hostRef,
340
+ contentRef,
341
+ };
342
+ this.activeDialogs.push(entry);
343
+ // Register with orchestrator — closes lower-priority overlays
344
+ const overlayId = this.orchestrator.register({
345
+ priority: OVERLAY_PRIORITY.DIALOG,
346
+ type: 'dialog',
347
+ close: () => dialogRef.close(),
348
+ });
349
+ this.overlayIds.set(entry, overlayId);
350
+ hostRef.instance.beforeOpen.subscribe(() => {
351
+ dialogRef.markBeforeOpen();
352
+ });
353
+ hostRef.instance.opened.subscribe(() => {
354
+ dialogRef.markOpened();
355
+ });
356
+ hostRef.instance.closed.subscribe(() => {
357
+ dialogRef.close();
358
+ });
359
+ dialogRef.afterClosed().subscribe(() => {
360
+ this.destroyDialog(entry);
361
+ });
362
+ hostRef.setInput('open', true);
363
+ hostRef.changeDetectorRef.detectChanges();
364
+ const panelBody = hostRef.location.nativeElement.querySelector('.fk-dialog__body');
365
+ if (panelBody) {
366
+ panelBody.appendChild(contentRef.location.nativeElement);
367
+ contentRef.changeDetectorRef.detectChanges();
368
+ // Move [libDialogFooter] elements out of body to the panel root
369
+ // so they render in the pinned footer area (after fk-dialog__body)
370
+ const panel = panelBody.parentElement;
371
+ const footerEls = panelBody.querySelectorAll('[libDialogFooter]');
372
+ footerEls.forEach((el) => {
373
+ panel?.appendChild(el);
374
+ });
375
+ }
376
+ this.applyZIndex(entry);
377
+ return dialogRef;
378
+ }
379
+ closeAll() {
380
+ [...this.activeDialogs].forEach((entry) => entry.ref.close());
381
+ }
382
+ /** Returns true if the given entry is the topmost (last) active dialog. */
383
+ isTopmost(entry) {
384
+ return (this.activeDialogs.length > 0 &&
385
+ this.activeDialogs[this.activeDialogs.length - 1] === entry);
386
+ }
387
+ applyZIndex(entry) {
388
+ const index = this.activeDialogs.indexOf(entry);
389
+ const zIndex = BASE_Z_INDEX + index * Z_INDEX_STEP;
390
+ const overlay = entry.hostRef.location.nativeElement.querySelector('.fk-dialog__overlay');
391
+ if (overlay) {
392
+ overlay.style.zIndex = String(zIndex);
393
+ }
394
+ }
395
+ applyConfig(hostRef, config) {
396
+ hostRef.setInput('modal', config.modal ?? true);
397
+ hostRef.setInput('closable', config.closable ?? true);
398
+ hostRef.setInput('closeOnEscape', config.closeOnEscape ?? true);
399
+ hostRef.setInput('closeOnBackdrop', config.closeOnBackdrop ?? false);
400
+ hostRef.setInput('size', config.size ?? 'md');
401
+ hostRef.setInput('position', config.position ?? 'center');
402
+ hostRef.setInput('animation', config.animation ?? 'scale-fade');
403
+ hostRef.setInput('header', config.header ?? null);
404
+ hostRef.setInput('restoreFocus', config.restoreFocus ?? true);
405
+ hostRef.setInput('autoFocus', config.autoFocus ?? true);
406
+ hostRef.setInput('className', config.className ?? '');
407
+ hostRef.setInput('preventClose', config.preventClose ?? false);
408
+ hostRef.setInput('canClose', config.canClose ?? null);
409
+ hostRef.setInput('fullscreenMobile', config.fullscreenMobile ?? false);
410
+ hostRef.setInput('flexBody', config.flexBody ?? false);
411
+ hostRef.setInput('ariaLabel', config.ariaLabel ?? null);
412
+ hostRef.setInput('ariaDescribedBy', config.ariaDescribedBy ?? null);
413
+ }
414
+ destroyDialog(entry) {
415
+ const overlayId = this.overlayIds.get(entry);
416
+ if (overlayId) {
417
+ this.orchestrator.unregister(overlayId);
418
+ this.overlayIds.delete(entry);
419
+ }
420
+ const idx = this.activeDialogs.indexOf(entry);
421
+ if (idx > -1) {
422
+ this.activeDialogs.splice(idx, 1);
423
+ }
424
+ entry.hostRef.setInput('open', false);
425
+ entry.hostRef.changeDetectorRef.detectChanges();
426
+ this.appRef.detachView(entry.contentRef.hostView);
427
+ this.appRef.detachView(entry.hostRef.hostView);
428
+ entry.contentRef.destroy();
429
+ entry.hostRef.destroy();
430
+ }
431
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: DialogService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
432
+ static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: DialogService, providedIn: 'root' });
433
+ }
434
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: DialogService, decorators: [{
435
+ type: Injectable,
436
+ args: [{ providedIn: 'root' }]
437
+ }] });
438
+
439
+ class FkDialogActionsDirective {
440
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: FkDialogActionsDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
441
+ static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.9", type: FkDialogActionsDirective, isStandalone: true, selector: "[fkDialogActions]", ngImport: i0 });
442
+ }
443
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.9", ngImport: i0, type: FkDialogActionsDirective, decorators: [{
444
+ type: Directive,
445
+ args: [{
446
+ selector: '[fkDialogActions]',
447
+ standalone: true,
448
+ }]
449
+ }] });
450
+
451
+ /**
452
+ * Generated bundle index. Do not edit.
453
+ */
454
+
455
+ export { DEFAULT_DIALOG_CONFIG, DIALOG_DATA, DIALOG_REF, DialogComponent, DialogRef, DialogService, FkDialogActionsDirective, FkDialogHeaderDirective };
456
+ //# sourceMappingURL=frame-kit-ui-ng-ui-dialog.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"frame-kit-ui-ng-ui-dialog.mjs","sources":["../../../../packages/ui-ng/ui/dialog/dialog-header.directive.ts","../../../../packages/ui-ng/ui/dialog/dialog.component.ts","../../../../packages/ui-ng/ui/dialog/dialog.component.html","../../../../packages/ui-ng/ui/dialog/dialog.config.ts","../../../../packages/ui-ng/ui/dialog/dialog-ref.ts","../../../../packages/ui-ng/ui/dialog/dialog.service.ts","../../../../packages/ui-ng/ui/dialog/dialog-actions.directive.ts","../../../../packages/ui-ng/ui/dialog/frame-kit-ui-ng-ui-dialog.ts"],"sourcesContent":["import { Directive } from '@angular/core';\n\n@Directive({\n selector: '[fkDialogHeader]',\n standalone: true,\n})\nexport class FkDialogHeaderDirective {}\n","import { A11yModule } from '@angular/cdk/a11y';\nimport { DOCUMENT } from '@angular/common';\nimport {\n ChangeDetectionStrategy,\n Component,\n computed,\n contentChild,\n DestroyRef,\n effect,\n HostBinding,\n HostListener,\n inject,\n input,\n output,\n signal,\n} from '@angular/core';\n\nimport type {\n CanCloseFn,\n DialogAnimation,\n DialogPosition,\n DialogSize,\n} from './dialog.types';\nimport { FkDialogHeaderDirective } from './dialog-header.directive';\n\nlet nextDialogId = 0;\n\n@Component({\n selector: 'fk-dialog',\n standalone: true,\n imports: [A11yModule],\n changeDetection: ChangeDetectionStrategy.OnPush,\n templateUrl: './dialog.component.html',\n styleUrl: './dialog.component.scss',\n})\nexport class DialogComponent {\n // ===== INPUTS =====\n /** Controls whether the dialog is open. */\n readonly open = input(false);\n /** When true, renders a backdrop overlay behind the dialog. */\n readonly modal = input(true);\n /** When true, shows the close button in the dialog header. */\n readonly closable = input(true);\n /** When true, pressing Escape closes the dialog. */\n readonly closeOnEscape = input(true);\n /** When true, clicking the backdrop overlay closes the dialog. */\n readonly closeOnBackdrop = input(false);\n /** Size variant that controls the dialog's max-width. */\n readonly size = input<DialogSize>('md');\n /** Where the dialog is anchored on screen. */\n readonly position = input<DialogPosition>('center');\n /** Optional title text rendered in the dialog header and used for `aria-labelledby`. */\n readonly header = input<string | null>(null);\n /** When true, focus returns to the previously focused element when the dialog closes. */\n readonly restoreFocus = input(true);\n /** When true, CDK auto-focus is applied when the dialog opens. */\n readonly autoFocus = input(true);\n /** Entry/exit animation applied to the dialog panel. */\n readonly animation = input<DialogAnimation>('scale-fade');\n /** When true, all close mechanisms (Escape, backdrop, button) are blocked. */\n readonly preventClose = input(false);\n /** Async guard function called before closing; return false to cancel the close. */\n readonly canClose = input<CanCloseFn | null>(null);\n /** When true, the dialog expands to full-screen on mobile viewports. */\n readonly fullscreenMobile = input(false);\n /** When true, the dialog body uses a flex column layout. */\n readonly flexBody = input(false);\n\n // ===== CONTENT CHILDREN =====\n readonly customHeader = contentChild(FkDialogHeaderDirective);\n\n // ===== BASE PROPS =====\n readonly className = input<string>('');\n readonly id = input<string | null>(null);\n readonly ariaLabel = input<string | null>(null);\n readonly ariaDescribedBy = input<string | null>(null);\n\n // ===== OUTPUTS =====\n /** Fires when the dialog's open state should change, emitting the new boolean. */\n readonly openChange = output<boolean>();\n /** Fires immediately before the dialog begins its open animation. */\n readonly beforeOpen = output<void>();\n /** Fires after the dialog is fully open and visible. */\n readonly opened = output<void>();\n /** Fires immediately before the dialog begins its close animation. */\n readonly beforeClose = output<void>();\n /** Fires after the dialog is fully closed. */\n readonly closed = output<void>();\n\n // ===== INTERNAL STATE =====\n private readonly doc = inject(DOCUMENT);\n private readonly destroyRef = inject(DestroyRef);\n readonly titleId = `fk-dialog-title-${nextDialogId++}`;\n private previouslyFocusedElement: HTMLElement | null = null;\n private bodyScrollLocked = false;\n private closeGuardRunning = false;\n\n /** Whether the dialog DOM is rendered (stays true during exit animation). */\n readonly visible = signal(false);\n\n /** Whether the dialog is animating out. */\n readonly animatingOut = signal(false);\n\n // ===== COMPUTED =====\n readonly classes = computed(() => {\n return ['fk-dialog', this.className()].filter(Boolean).join(' ');\n });\n\n readonly ariaLabelledBy = computed(() => {\n if (this.ariaLabel()) {\n return null;\n }\n\n return this.header() ? this.titleId : null;\n });\n\n constructor() {\n effect(() => {\n const isOpen = this.open();\n\n if (isOpen) {\n this.onDialogOpen();\n } else {\n this.onDialogClose();\n }\n });\n\n this.destroyRef.onDestroy(() => {\n this.unlockBodyScroll();\n });\n }\n\n @HostBinding('class')\n get hostClass() {\n return this.classes();\n }\n\n @HostBinding('attr.id')\n get hostId() {\n return this.id();\n }\n\n // ===== KEYBOARD =====\n @HostListener('document:keydown.escape')\n onEscapeKey() {\n if (this.open() && this.closeOnEscape()) {\n this.close();\n }\n }\n\n // ===== ACTIONS =====\n /** Closes the dialog, running any `canClose` guard first; no-ops when `preventClose` is true. */\n async close() {\n if (this.closeGuardRunning) {\n return;\n }\n\n if (this.preventClose()) {\n return;\n }\n\n const guard = this.canClose();\n\n if (guard) {\n this.closeGuardRunning = true;\n\n try {\n const allowed = await Promise.resolve(guard());\n\n if (!allowed) {\n return;\n }\n } finally {\n this.closeGuardRunning = false;\n }\n }\n\n this.beforeClose.emit();\n this.openChange.emit(false);\n this.closed.emit();\n }\n\n onOverlayClick() {\n if (this.closeOnBackdrop()) {\n this.close();\n }\n }\n\n /** Called when the overlay exit animation finishes. */\n onExitAnimationDone() {\n if (this.animatingOut()) {\n this.animatingOut.set(false);\n this.visible.set(false);\n }\n }\n\n // ===== LIFECYCLE =====\n private onDialogOpen() {\n this.previouslyFocusedElement =\n (this.doc.activeElement as HTMLElement) ?? null;\n\n this.beforeOpen.emit();\n this.animatingOut.set(false);\n this.visible.set(true);\n\n if (this.modal()) {\n this.lockBodyScroll();\n }\n\n this.opened.emit();\n }\n\n private onDialogClose() {\n this.unlockBodyScroll();\n\n if (this.visible()) {\n if (this.animation() !== 'none') {\n this.animatingOut.set(true);\n } else {\n this.visible.set(false);\n }\n }\n\n if (this.restoreFocus() && this.previouslyFocusedElement) {\n this.previouslyFocusedElement.focus();\n this.previouslyFocusedElement = null;\n }\n }\n\n // ===== SCROLL LOCK =====\n private lockBodyScroll() {\n if (!this.bodyScrollLocked) {\n this.doc.body.style.overflow = 'hidden';\n this.bodyScrollLocked = true;\n }\n }\n\n private unlockBodyScroll() {\n if (this.bodyScrollLocked) {\n this.doc.body.style.overflow = '';\n this.bodyScrollLocked = false;\n }\n }\n}\n","@if (visible()) {\n <!-- eslint-disable-next-line @angular-eslint/template/click-events-have-key-events, @angular-eslint/template/interactive-supports-focus -->\n <div\n class=\"fk-dialog__overlay\"\n [class.fk-dialog__overlay--modal]=\"modal()\"\n [class.fk-dialog__animate-overlay--in]=\"!animatingOut()\"\n [class.fk-dialog__animate-overlay--out]=\"animatingOut()\"\n [class.fk-dialog__animate-overlay--none]=\"animation() === 'none'\"\n (click)=\"onOverlayClick()\"\n (animationend)=\"onExitAnimationDone()\"\n >\n <!-- eslint-disable-next-line @angular-eslint/template/click-events-have-key-events -->\n <div\n class=\"fk-dialog__panel\"\n [class.fk-dialog__animate-panel--scale-fade]=\"\n animation() === 'scale-fade' && !animatingOut()\n \"\n [class.fk-dialog__animate-panel--fade]=\"\n animation() === 'fade' && !animatingOut()\n \"\n [class.fk-dialog__animate-panel--slide-up]=\"\n animation() === 'slide-up' && !animatingOut()\n \"\n [class.fk-dialog__animate-panel--slide-down]=\"\n animation() === 'slide-down' && !animatingOut()\n \"\n [class.fk-dialog__animate-panel-out--scale-fade]=\"\n animation() === 'scale-fade' && animatingOut()\n \"\n [class.fk-dialog__animate-panel-out--fade]=\"\n animation() === 'fade' && animatingOut()\n \"\n [class.fk-dialog__animate-panel-out--slide-up]=\"\n animation() === 'slide-up' && animatingOut()\n \"\n [class.fk-dialog__animate-panel-out--slide-down]=\"\n animation() === 'slide-down' && animatingOut()\n \"\n [class.fk-dialog__panel--sm]=\"size() === 'sm'\"\n [class.fk-dialog__panel--md]=\"size() === 'md'\"\n [class.fk-dialog__panel--lg]=\"size() === 'lg'\"\n [class.fk-dialog__panel--xl]=\"size() === 'xl'\"\n [class.fk-dialog__panel--fullscreen]=\"size() === 'fullscreen'\"\n [class.fk-dialog__panel--fullscreen-auto]=\"fullscreenMobile()\"\n [class.fk-dialog__panel--top]=\"position() === 'top'\"\n role=\"dialog\"\n [attr.aria-modal]=\"modal() ? 'true' : null\"\n [attr.aria-label]=\"ariaLabel()\"\n [attr.aria-labelledby]=\"ariaLabelledBy()\"\n [attr.aria-describedby]=\"ariaDescribedBy()\"\n [cdkTrapFocus]=\"modal()\"\n [cdkTrapFocusAutoCapture]=\"autoFocus()\"\n (click)=\"$event.stopPropagation()\"\n >\n @if (customHeader() || header() || closable()) {\n <div class=\"fk-dialog__header\">\n <ng-content select=\"[fkDialogHeader]\" />\n\n @if (!customHeader() && header()) {\n <span class=\"fk-dialog__title\" [id]=\"titleId\">{{ header() }}</span>\n }\n\n @if (closable()) {\n <button\n class=\"fk-dialog__close\"\n type=\"button\"\n aria-label=\"Close dialog\"\n (click)=\"close()\"\n >\n &times;\n </button>\n }\n </div>\n }\n\n <div class=\"fk-dialog__body\" [class.fk-dialog__body--flex]=\"flexBody()\">\n <ng-content />\n </div>\n\n <ng-content select=\"[libDialogFooter]\" />\n </div>\n </div>\n}\n","import type {\n CanCloseFn,\n DialogAnimation,\n DialogPosition,\n DialogSize,\n} from './dialog.types';\n\nexport interface DialogConfig<TData = unknown> {\n modal?: boolean;\n closable?: boolean;\n closeOnEscape?: boolean;\n closeOnBackdrop?: boolean;\n size?: DialogSize;\n position?: DialogPosition;\n animation?: DialogAnimation;\n header?: string | null;\n restoreFocus?: boolean;\n autoFocus?: boolean;\n preventClose?: boolean;\n canClose?: CanCloseFn;\n fullscreenMobile?: boolean;\n flexBody?: boolean;\n className?: string;\n ariaLabel?: string | null;\n ariaDescribedBy?: string | null;\n data?: TData;\n}\n\nexport const DEFAULT_DIALOG_CONFIG: DialogConfig = {\n modal: true,\n closable: true,\n closeOnEscape: true,\n closeOnBackdrop: false,\n size: 'md',\n position: 'center',\n animation: 'scale-fade',\n header: null,\n restoreFocus: true,\n autoFocus: true,\n preventClose: false,\n fullscreenMobile: false,\n flexBody: false,\n className: '',\n ariaLabel: null,\n ariaDescribedBy: null,\n};\n","import { Observable, Subject } from 'rxjs';\nimport { take } from 'rxjs/operators';\n\nimport type { DialogConfig } from './dialog.config';\nimport type { CanCloseFn } from './dialog.types';\n\nexport class DialogRef<TResult = unknown, TData = unknown> {\n private readonly beforeOpenSubject = new Subject<void>();\n private readonly afterOpenedSubject = new Subject<void>();\n private readonly beforeCloseSubject = new Subject<void>();\n private readonly afterClosedSubject = new Subject<TResult | undefined>();\n private closed = false;\n private closeGuard: CanCloseFn | null = null;\n\n readonly config: DialogConfig<TData>;\n\n constructor(config: DialogConfig<TData> = {} as DialogConfig<TData>) {\n this.config = config;\n\n if (config.canClose) {\n this.closeGuard = config.canClose;\n }\n }\n\n get data(): TData | undefined {\n return this.config.data;\n }\n\n setCanClose(guard: CanCloseFn | null) {\n this.closeGuard = guard;\n }\n\n async close(result?: TResult) {\n if (this.closed) {\n return;\n }\n\n if (this.config.preventClose) {\n return;\n }\n\n if (this.closeGuard) {\n const allowed = await Promise.resolve(this.closeGuard());\n\n if (!allowed) {\n return;\n }\n }\n\n this.beforeCloseSubject.next();\n this.beforeCloseSubject.complete();\n\n this.closed = true;\n this.afterClosedSubject.next(result);\n this.afterClosedSubject.complete();\n }\n\n beforeOpen(): Observable<void> {\n return this.beforeOpenSubject.asObservable().pipe(take(1));\n }\n\n afterOpened(): Observable<void> {\n return this.afterOpenedSubject.asObservable().pipe(take(1));\n }\n\n beforeClose(): Observable<void> {\n return this.beforeCloseSubject.asObservable().pipe(take(1));\n }\n\n afterClosed(): Observable<TResult | undefined> {\n return this.afterClosedSubject.asObservable().pipe(take(1));\n }\n\n /** @internal */\n markBeforeOpen() {\n this.beforeOpenSubject.next();\n this.beforeOpenSubject.complete();\n }\n\n /** @internal */\n markOpened() {\n this.afterOpenedSubject.next();\n this.afterOpenedSubject.complete();\n }\n}\n","import { DOCUMENT } from '@angular/common';\nimport {\n ApplicationRef,\n ComponentRef,\n createComponent,\n EnvironmentInjector,\n inject,\n Injectable,\n Injector,\n Type,\n} from '@angular/core';\n\nimport { OverlayOrchestrator } from '@frame-kit/ui-ng/services/overlay-orchestrator';\nimport { OVERLAY_PRIORITY } from '@frame-kit/ui-ng/services/overlay-orchestrator';\nimport { DialogComponent } from './dialog.component';\nimport { DEFAULT_DIALOG_CONFIG, DialogConfig } from './dialog.config';\nimport { DialogRef } from './dialog-ref';\n\nexport const DIALOG_DATA = Symbol('DIALOG_DATA');\nexport const DIALOG_REF = Symbol('DIALOG_REF');\n\nconst BASE_Z_INDEX = 1000;\nconst Z_INDEX_STEP = 10;\n\ninterface DialogEntry {\n ref: DialogRef;\n hostRef: ComponentRef<DialogComponent>;\n contentRef: ComponentRef<unknown>;\n}\n\n@Injectable({ providedIn: 'root' })\nexport class DialogService {\n private readonly appRef = inject(ApplicationRef);\n private readonly injector = inject(EnvironmentInjector);\n private readonly doc = inject(DOCUMENT);\n private readonly orchestrator = inject(OverlayOrchestrator);\n\n private activeDialogs: DialogEntry[] = [];\n private overlayIds = new Map<DialogEntry, string>();\n\n get openCount(): number {\n return this.activeDialogs.length;\n }\n\n open<TResult = unknown, TData = unknown>(\n content: Type<unknown>,\n config?: DialogConfig<TData>,\n ): DialogRef<TResult, TData> {\n const mergedConfig = {\n ...DEFAULT_DIALOG_CONFIG,\n ...config,\n } as DialogConfig<TData>;\n const dialogRef = new DialogRef<TResult, TData>(mergedConfig);\n\n const childInjector = Injector.create({\n parent: this.injector,\n providers: [\n { provide: DIALOG_DATA as never, useValue: mergedConfig.data },\n { provide: DIALOG_REF as never, useValue: dialogRef },\n ],\n });\n\n const hostRef = createComponent(DialogComponent, {\n environmentInjector: this.injector,\n elementInjector: childInjector,\n });\n\n const contentRef = createComponent(content, {\n environmentInjector: this.injector,\n elementInjector: childInjector,\n hostElement: this.doc.createElement('div'),\n });\n\n this.applyConfig(hostRef, mergedConfig);\n this.appRef.attachView(hostRef.hostView);\n this.appRef.attachView(contentRef.hostView);\n\n this.doc.body.appendChild(hostRef.location.nativeElement);\n\n const entry: DialogEntry = {\n ref: dialogRef as DialogRef<unknown, unknown>,\n hostRef,\n contentRef,\n };\n\n this.activeDialogs.push(entry);\n\n // Register with orchestrator — closes lower-priority overlays\n const overlayId = this.orchestrator.register({\n priority: OVERLAY_PRIORITY.DIALOG,\n type: 'dialog',\n close: () => dialogRef.close(),\n });\n\n this.overlayIds.set(entry, overlayId);\n\n hostRef.instance.beforeOpen.subscribe(() => {\n dialogRef.markBeforeOpen();\n });\n\n hostRef.instance.opened.subscribe(() => {\n dialogRef.markOpened();\n });\n\n hostRef.instance.closed.subscribe(() => {\n dialogRef.close();\n });\n\n dialogRef.afterClosed().subscribe(() => {\n this.destroyDialog(entry);\n });\n\n hostRef.setInput('open', true);\n hostRef.changeDetectorRef.detectChanges();\n\n const panelBody =\n hostRef.location.nativeElement.querySelector('.fk-dialog__body');\n\n if (panelBody) {\n panelBody.appendChild(contentRef.location.nativeElement);\n contentRef.changeDetectorRef.detectChanges();\n\n // Move [libDialogFooter] elements out of body to the panel root\n // so they render in the pinned footer area (after fk-dialog__body)\n const panel = panelBody.parentElement;\n const footerEls = panelBody.querySelectorAll('[libDialogFooter]');\n\n footerEls.forEach((el: Element) => {\n panel?.appendChild(el);\n });\n }\n\n this.applyZIndex(entry);\n\n return dialogRef;\n }\n\n closeAll() {\n [...this.activeDialogs].forEach((entry) => entry.ref.close());\n }\n\n /** Returns true if the given entry is the topmost (last) active dialog. */\n isTopmost(entry: DialogEntry): boolean {\n return (\n this.activeDialogs.length > 0 &&\n this.activeDialogs[this.activeDialogs.length - 1] === entry\n );\n }\n\n private applyZIndex(entry: DialogEntry) {\n const index = this.activeDialogs.indexOf(entry);\n const zIndex = BASE_Z_INDEX + index * Z_INDEX_STEP;\n const overlay = entry.hostRef.location.nativeElement.querySelector(\n '.fk-dialog__overlay',\n );\n\n if (overlay) {\n overlay.style.zIndex = String(zIndex);\n }\n }\n\n private applyConfig(\n hostRef: ComponentRef<DialogComponent>,\n config: DialogConfig,\n ) {\n hostRef.setInput('modal', config.modal ?? true);\n hostRef.setInput('closable', config.closable ?? true);\n hostRef.setInput('closeOnEscape', config.closeOnEscape ?? true);\n hostRef.setInput('closeOnBackdrop', config.closeOnBackdrop ?? false);\n hostRef.setInput('size', config.size ?? 'md');\n hostRef.setInput('position', config.position ?? 'center');\n hostRef.setInput('animation', config.animation ?? 'scale-fade');\n hostRef.setInput('header', config.header ?? null);\n hostRef.setInput('restoreFocus', config.restoreFocus ?? true);\n hostRef.setInput('autoFocus', config.autoFocus ?? true);\n hostRef.setInput('className', config.className ?? '');\n hostRef.setInput('preventClose', config.preventClose ?? false);\n hostRef.setInput('canClose', config.canClose ?? null);\n hostRef.setInput('fullscreenMobile', config.fullscreenMobile ?? false);\n hostRef.setInput('flexBody', config.flexBody ?? false);\n hostRef.setInput('ariaLabel', config.ariaLabel ?? null);\n hostRef.setInput('ariaDescribedBy', config.ariaDescribedBy ?? null);\n }\n\n private destroyDialog(entry: DialogEntry) {\n const overlayId = this.overlayIds.get(entry);\n\n if (overlayId) {\n this.orchestrator.unregister(overlayId);\n this.overlayIds.delete(entry);\n }\n\n const idx = this.activeDialogs.indexOf(entry);\n\n if (idx > -1) {\n this.activeDialogs.splice(idx, 1);\n }\n\n entry.hostRef.setInput('open', false);\n entry.hostRef.changeDetectorRef.detectChanges();\n\n this.appRef.detachView(entry.contentRef.hostView);\n this.appRef.detachView(entry.hostRef.hostView);\n\n entry.contentRef.destroy();\n entry.hostRef.destroy();\n }\n}\n","import { Directive } from '@angular/core';\n\n@Directive({\n selector: '[fkDialogActions]',\n standalone: true,\n})\nexport class FkDialogActionsDirective {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;MAMa,uBAAuB,CAAA;uGAAvB,uBAAuB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA;2FAAvB,uBAAuB,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,kBAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA;;2FAAvB,uBAAuB,EAAA,UAAA,EAAA,CAAA;kBAJnC,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACT,oBAAA,QAAQ,EAAE,kBAAkB;AAC5B,oBAAA,UAAU,EAAE,IAAI;AACjB,iBAAA;;;ACoBD,IAAI,YAAY,GAAG,CAAC;MAUP,eAAe,CAAA;;;AAGjB,IAAA,IAAI,GAAG,KAAK,CAAC,KAAK,2EAAC;;AAEnB,IAAA,KAAK,GAAG,KAAK,CAAC,IAAI,4EAAC;;AAEnB,IAAA,QAAQ,GAAG,KAAK,CAAC,IAAI,+EAAC;;AAEtB,IAAA,aAAa,GAAG,KAAK,CAAC,IAAI,oFAAC;;AAE3B,IAAA,eAAe,GAAG,KAAK,CAAC,KAAK,sFAAC;;AAE9B,IAAA,IAAI,GAAG,KAAK,CAAa,IAAI,2EAAC;;AAE9B,IAAA,QAAQ,GAAG,KAAK,CAAiB,QAAQ,+EAAC;;AAE1C,IAAA,MAAM,GAAG,KAAK,CAAgB,IAAI,6EAAC;;AAEnC,IAAA,YAAY,GAAG,KAAK,CAAC,IAAI,mFAAC;;AAE1B,IAAA,SAAS,GAAG,KAAK,CAAC,IAAI,gFAAC;;AAEvB,IAAA,SAAS,GAAG,KAAK,CA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