@sixbell-telco/sdk 0.2.1 → 0.4.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 (149) hide show
  1. package/CHANGELOG.md +54 -0
  2. package/README.md +96 -55
  3. package/_index.scss +0 -2
  4. package/assets/styles/combobox.scss +17 -17
  5. package/components/accordion/accordion-item/accordion-item.component.d.ts +1 -2
  6. package/components/avatar/src/avatar.component.d.ts +11 -18
  7. package/components/button/src/button.component.d.ts +22 -41
  8. package/components/card/card-actions/card-actions.component.d.ts +8 -0
  9. package/components/card/card-content/card-content.component.d.ts +5 -0
  10. package/components/card/card-title/card-title.component.d.ts +5 -0
  11. package/components/card/public-api.d.ts +3 -0
  12. package/components/card/src/card.component.d.ts +19 -20
  13. package/components/countdown/src/countdown.component.d.ts +6 -1
  14. package/components/dropdown/dropdown-item/dropdown-item.component.d.ts +10 -0
  15. package/components/dropdown/public-api.d.ts +1 -0
  16. package/components/dropdown/src/dropdown.component.d.ts +24 -42
  17. package/components/dual-list/src/dual-list.component.d.ts +11 -60
  18. package/components/file-upload/file-uploader/src/file-uploader.component.d.ts +2 -5
  19. package/components/forms/checkbox/src/checkbox.component.d.ts +2 -3
  20. package/components/forms/input/src/input.component.d.ts +7 -8
  21. package/components/forms/radio/src/radio.component.d.ts +2 -6
  22. package/components/forms/select/src/select.component.d.ts +5 -8
  23. package/components/forms/textarea/src/textarea.component.d.ts +5 -11
  24. package/components/link/src/link.component.d.ts +18 -45
  25. package/components/modal/modal-actions/modal-actions.component.d.ts +8 -0
  26. package/components/modal/modal-content/modal-content.component.d.ts +5 -0
  27. package/components/modal/modal-title/modal-title.component.d.ts +5 -0
  28. package/components/modal/public-api.d.ts +3 -0
  29. package/components/modal/src/modal.component.d.ts +10 -14
  30. package/components/product-card/src/product-card.component.d.ts +5 -9
  31. package/components/tab/src/tab.component.d.ts +1 -2
  32. package/components/table/src/table.component.d.ts +14 -19
  33. package/directives/click-outside/index.d.ts +5 -0
  34. package/directives/click-outside/public-api.d.ts +1 -0
  35. package/directives/click-outside/src/click-outside.directive.d.ts +10 -0
  36. package/directives/typography/src/typography.directive.d.ts +3 -4
  37. package/esm2022/components/accordion/accordion-item/accordion-item.component.mjs +5 -6
  38. package/esm2022/components/avatar/src/avatar.component.mjs +27 -43
  39. package/esm2022/components/button/src/button.component.mjs +43 -118
  40. package/esm2022/components/card/card-actions/card-actions.component.mjs +22 -0
  41. package/esm2022/components/card/card-content/card-content.component.mjs +12 -0
  42. package/esm2022/components/card/card-title/card-title.component.mjs +12 -0
  43. package/esm2022/components/card/public-api.mjs +4 -1
  44. package/esm2022/components/card/src/card.component.mjs +20 -45
  45. package/esm2022/components/countdown/src/countdown.component.mjs +10 -3
  46. package/esm2022/components/dropdown/dropdown-item/dropdown-item.component.mjs +24 -0
  47. package/esm2022/components/dropdown/public-api.mjs +2 -1
  48. package/esm2022/components/dropdown/src/dropdown.component.mjs +65 -101
  49. package/esm2022/components/dual-list/src/dual-list.component.mjs +23 -63
  50. package/esm2022/components/file-upload/file-dropzone/src/file-dropzone.component.mjs +3 -3
  51. package/esm2022/components/file-upload/file-uploader/src/file-uploader.component.mjs +3 -7
  52. package/esm2022/components/forms/checkbox/src/checkbox.component.mjs +9 -8
  53. package/esm2022/components/forms/combobox/src/combobox.component.mjs +3 -3
  54. package/esm2022/components/forms/datepicker/src/datepicker.component.mjs +2 -2
  55. package/esm2022/components/forms/form-error/src/form-error.component.mjs +3 -3
  56. package/esm2022/components/forms/input/src/input.component.mjs +51 -45
  57. package/esm2022/components/forms/radio/src/radio.component.mjs +5 -18
  58. package/esm2022/components/forms/range/src/range.component.mjs +3 -3
  59. package/esm2022/components/forms/select/src/select.component.mjs +24 -34
  60. package/esm2022/components/forms/switch/src/switch.component.mjs +3 -3
  61. package/esm2022/components/forms/textarea/src/textarea.component.mjs +35 -48
  62. package/esm2022/components/forms/toggle/src/toggle.component.mjs +3 -3
  63. package/esm2022/components/link/src/link.component.mjs +27 -183
  64. package/esm2022/components/modal/modal-actions/modal-actions.component.mjs +22 -0
  65. package/esm2022/components/modal/modal-content/modal-content.component.mjs +12 -0
  66. package/esm2022/components/modal/modal-title/modal-title.component.mjs +13 -0
  67. package/esm2022/components/modal/public-api.mjs +4 -1
  68. package/esm2022/components/modal/src/modal.component.mjs +29 -32
  69. package/esm2022/components/notification/src/notification.component.mjs +2 -5
  70. package/esm2022/components/paginator/components/pagination-item/pagination-item.component.mjs +24 -24
  71. package/esm2022/components/product-card/src/product-card.component.mjs +5 -14
  72. package/esm2022/components/progress/src/progress.component.mjs +3 -3
  73. package/esm2022/components/tab/src/tab.component.mjs +2 -4
  74. package/esm2022/components/table/src/table.component.mjs +35 -40
  75. package/esm2022/components/table/table-header-checkbox/table-header-checkbox.component.mjs +3 -3
  76. package/esm2022/components/table/table-row-checkbox/table-row-checkbox.component.mjs +1 -1
  77. package/esm2022/components/toast/toast-message/toast-message.component.mjs +4 -4
  78. package/esm2022/components/wizard/wizard-marker/wizard-marker.component.mjs +4 -4
  79. package/esm2022/components/wizard/wizard-step/wizard-step.component.mjs +3 -3
  80. package/esm2022/components/wizard/wizard-wrapper/wizard-wrapper.component.mjs +3 -3
  81. package/esm2022/directives/click-outside/public-api.mjs +2 -0
  82. package/esm2022/directives/click-outside/sixbell-telco-sdk-directives-click-outside.mjs +5 -0
  83. package/esm2022/directives/click-outside/src/click-outside.directive.mjs +30 -0
  84. package/esm2022/directives/typography/src/typography.directive.mjs +19 -18
  85. package/fesm2022/sixbell-telco-sdk-components-accordion.mjs +4 -5
  86. package/fesm2022/sixbell-telco-sdk-components-accordion.mjs.map +1 -1
  87. package/fesm2022/sixbell-telco-sdk-components-avatar.mjs +26 -42
  88. package/fesm2022/sixbell-telco-sdk-components-avatar.mjs.map +1 -1
  89. package/fesm2022/sixbell-telco-sdk-components-button.mjs +43 -118
  90. package/fesm2022/sixbell-telco-sdk-components-button.mjs.map +1 -1
  91. package/fesm2022/sixbell-telco-sdk-components-card.mjs +57 -46
  92. package/fesm2022/sixbell-telco-sdk-components-card.mjs.map +1 -1
  93. package/fesm2022/sixbell-telco-sdk-components-countdown.mjs +9 -2
  94. package/fesm2022/sixbell-telco-sdk-components-countdown.mjs.map +1 -1
  95. package/fesm2022/sixbell-telco-sdk-components-dropdown.mjs +86 -101
  96. package/fesm2022/sixbell-telco-sdk-components-dropdown.mjs.map +1 -1
  97. package/fesm2022/sixbell-telco-sdk-components-dual-list.mjs +21 -61
  98. package/fesm2022/sixbell-telco-sdk-components-dual-list.mjs.map +1 -1
  99. package/fesm2022/sixbell-telco-sdk-components-file-upload-file-dropzone.mjs +2 -2
  100. package/fesm2022/sixbell-telco-sdk-components-file-upload-file-dropzone.mjs.map +1 -1
  101. package/fesm2022/sixbell-telco-sdk-components-file-upload-file-uploader.mjs +2 -6
  102. package/fesm2022/sixbell-telco-sdk-components-file-upload-file-uploader.mjs.map +1 -1
  103. package/fesm2022/sixbell-telco-sdk-components-forms-checkbox.mjs +8 -7
  104. package/fesm2022/sixbell-telco-sdk-components-forms-checkbox.mjs.map +1 -1
  105. package/fesm2022/sixbell-telco-sdk-components-forms-combobox.mjs +2 -2
  106. package/fesm2022/sixbell-telco-sdk-components-forms-combobox.mjs.map +1 -1
  107. package/fesm2022/sixbell-telco-sdk-components-forms-datepicker.mjs +1 -1
  108. package/fesm2022/sixbell-telco-sdk-components-forms-datepicker.mjs.map +1 -1
  109. package/fesm2022/sixbell-telco-sdk-components-forms-form-error.mjs +2 -2
  110. package/fesm2022/sixbell-telco-sdk-components-forms-form-error.mjs.map +1 -1
  111. package/fesm2022/sixbell-telco-sdk-components-forms-input.mjs +51 -45
  112. package/fesm2022/sixbell-telco-sdk-components-forms-input.mjs.map +1 -1
  113. package/fesm2022/sixbell-telco-sdk-components-forms-radio.mjs +4 -17
  114. package/fesm2022/sixbell-telco-sdk-components-forms-radio.mjs.map +1 -1
  115. package/fesm2022/sixbell-telco-sdk-components-forms-range.mjs +2 -2
  116. package/fesm2022/sixbell-telco-sdk-components-forms-range.mjs.map +1 -1
  117. package/fesm2022/sixbell-telco-sdk-components-forms-select.mjs +23 -33
  118. package/fesm2022/sixbell-telco-sdk-components-forms-select.mjs.map +1 -1
  119. package/fesm2022/sixbell-telco-sdk-components-forms-switch.mjs +2 -2
  120. package/fesm2022/sixbell-telco-sdk-components-forms-switch.mjs.map +1 -1
  121. package/fesm2022/sixbell-telco-sdk-components-forms-textarea.mjs +34 -47
  122. package/fesm2022/sixbell-telco-sdk-components-forms-textarea.mjs.map +1 -1
  123. package/fesm2022/sixbell-telco-sdk-components-forms-toggle.mjs +2 -2
  124. package/fesm2022/sixbell-telco-sdk-components-forms-toggle.mjs.map +1 -1
  125. package/fesm2022/sixbell-telco-sdk-components-link.mjs +27 -183
  126. package/fesm2022/sixbell-telco-sdk-components-link.mjs.map +1 -1
  127. package/fesm2022/sixbell-telco-sdk-components-modal.mjs +67 -32
  128. package/fesm2022/sixbell-telco-sdk-components-modal.mjs.map +1 -1
  129. package/fesm2022/sixbell-telco-sdk-components-notification.mjs +1 -4
  130. package/fesm2022/sixbell-telco-sdk-components-notification.mjs.map +1 -1
  131. package/fesm2022/sixbell-telco-sdk-components-paginator.mjs +23 -23
  132. package/fesm2022/sixbell-telco-sdk-components-paginator.mjs.map +1 -1
  133. package/fesm2022/sixbell-telco-sdk-components-product-card.mjs +4 -13
  134. package/fesm2022/sixbell-telco-sdk-components-product-card.mjs.map +1 -1
  135. package/fesm2022/sixbell-telco-sdk-components-progress.mjs +2 -2
  136. package/fesm2022/sixbell-telco-sdk-components-progress.mjs.map +1 -1
  137. package/fesm2022/sixbell-telco-sdk-components-tab.mjs +1 -3
  138. package/fesm2022/sixbell-telco-sdk-components-tab.mjs.map +1 -1
  139. package/fesm2022/sixbell-telco-sdk-components-table.mjs +37 -42
  140. package/fesm2022/sixbell-telco-sdk-components-table.mjs.map +1 -1
  141. package/fesm2022/sixbell-telco-sdk-components-toast.mjs +3 -3
  142. package/fesm2022/sixbell-telco-sdk-components-toast.mjs.map +1 -1
  143. package/fesm2022/sixbell-telco-sdk-components-wizard.mjs +7 -7
  144. package/fesm2022/sixbell-telco-sdk-components-wizard.mjs.map +1 -1
  145. package/fesm2022/sixbell-telco-sdk-directives-click-outside.mjs +37 -0
  146. package/fesm2022/sixbell-telco-sdk-directives-click-outside.mjs.map +1 -0
  147. package/fesm2022/sixbell-telco-sdk-directives-typography.mjs +18 -17
  148. package/fesm2022/sixbell-telco-sdk-directives-typography.mjs.map +1 -1
  149. package/package.json +13 -7
@@ -1,226 +1,70 @@
1
+ import { CommonModule } from '@angular/common';
1
2
  import * as i0 from '@angular/core';
2
3
  import { input, Component, ChangeDetectionStrategy } from '@angular/core';
3
4
  import { FormsModule } from '@angular/forms';
4
5
  import * as i1 from '@angular/router';
5
- import { NavigationEnd, RouterLinkActive, RouterLink } from '@angular/router';
6
+ import { RouterLinkActive, RouterLink } from '@angular/router';
6
7
  import { IconComponent } from '@sixbell-telco/sdk/components/icon';
7
- import { matHomeOutline, matKeyboardArrowRightOutline } from '@sixbell-telco/sdk/components/icon/material/outline';
8
- import { TypographyDirective } from '@sixbell-telco/sdk/directives/typography';
9
8
  import { cn } from '@sixbell-telco/sdk/utils/cn';
10
- import { cva, cx } from 'class-variance-authority';
11
- import { filter } from 'rxjs';
9
+ import { cva } from 'class-variance-authority';
12
10
 
13
- const linkContainer = cva([], {
11
+ const linkComponent = cva(['link', 'font-body', 'font-normal', 'inline-flex', 'items-center', 'leading-normal'], {
14
12
  variants: {
15
13
  variant: {
16
- primary: ['link', 'link-primary', 'no-underline'],
17
- secondary: ['link', 'link-secondary', 'no-underline'],
18
- accent: ['link', 'link-accent', 'no-underline'],
19
- success: ['link', 'link-success', 'no-underline'],
20
- info: ['link', 'link-info', 'no-underline'],
21
- warning: ['link', 'link-warning', 'no-underline'],
22
- error: ['link', 'link-error', 'no-underline'],
23
- 'btn-primary': [
24
- 'btn',
25
- 'min-h-12',
26
- 'btn-ghost',
27
- 'h-auto',
28
- 'font-normal',
29
- 'text-neutral',
30
- 'hover:font-semibold',
31
- 'hover:text-primary-content',
32
- 'hover:bg-primary',
33
- 'active:hover:font-semibold',
34
- 'active:hover:text-primary-content',
35
- 'active:hover:bg-primary',
36
- 'active:focus:font-semibold',
37
- 'active:focus:text-primary-content',
38
- 'active:focus:bg-primary',
39
- ],
40
- 'btn-secondary': [
41
- 'btn',
42
- 'min-h-12',
43
- 'btn-ghost',
44
- 'h-auto',
45
- 'font-normal',
46
- 'text-neutral',
47
- 'hover:font-semibold',
48
- 'hover:text-secondary-content',
49
- 'hover:bg-secondary',
50
- 'active:hover:font-semibold',
51
- 'active:hover:text-secondary-content',
52
- 'active:hover:bg-secondary',
53
- 'active:focus:font-semibold',
54
- 'active:focus:text-secondary-content',
55
- 'active:focus:bg-secondary',
56
- ],
57
- 'btn-warning': [
58
- 'btn',
59
- 'min-h-12',
60
- 'btn-ghost',
61
- 'h-auto',
62
- 'font-normal',
63
- 'text-neutral',
64
- 'hover:font-semibold',
65
- 'hover:text-warning-content',
66
- 'hover:bg-warning',
67
- 'active:hover:font-semibold',
68
- 'active:hover:text-warning-content',
69
- 'active:hover:bg-warning',
70
- 'active:focus:font-semibold',
71
- 'active:focus:text-warning-content',
72
- 'active:focus:bg-warning',
73
- ],
74
- 'btn-error': [
75
- 'btn',
76
- 'min-h-12',
77
- 'btn-ghost',
78
- 'h-auto',
79
- 'font-normal',
80
- 'text-neutral',
81
- 'hover:font-semibold',
82
- 'hover:text-error-content',
83
- 'hover:bg-error',
84
- 'active:hover:font-semibold',
85
- 'active:hover:text-error-content',
86
- 'active:hover:bg-error',
87
- 'active:focus:font-semibold',
88
- 'active:focus:text-error-content',
89
- 'active:focus:bg-error',
90
- ],
91
- 'btn-collapsable-primary': [
92
- 'btn',
93
- 'min-h-12',
94
- 'btn-ghost',
95
- 'h-auto',
96
- 'items-center',
97
- 'gap-2',
98
- 'font-normal',
99
- 'text-neutral',
100
- 'hover:font-semibold',
101
- 'hover:text-neutral-content',
102
- 'hover:bg-primary',
103
- 'active:hover:font-semibold',
104
- 'active:hover:text-neutral-content',
105
- 'active:hover:bg-primary',
106
- 'active:focus:font-semibold',
107
- 'active:focus:text-neutral-content',
108
- 'active:focus:bg-primary',
109
- ],
14
+ primary: ['link-primary', 'no-underline'],
15
+ secondary: ['link-secondary', 'no-underline'],
16
+ tertiary: ['link-tertiary', 'no-underline'],
17
+ accent: ['link-accent', 'no-underline'],
18
+ success: ['link-success', 'no-underline'],
19
+ info: ['link-info', 'no-underline'],
20
+ warning: ['link-warning', 'no-underline'],
21
+ error: ['link-error', 'no-underline'],
110
22
  },
111
- shape: {
112
- 'round-none': ['rounded-none'],
113
- 'round-sm': ['rounded-btn-sm'],
114
- 'round-md': ['rounded-btn-md'],
115
- 'round-lg': ['rounded-btn-lg'],
116
- },
117
- padding: {
118
- none: [],
119
- sm: ['px-2', 'py-1'],
120
- md: ['px-3', 'py-2'],
121
- lg: ['px-4', 'py-3'],
122
- },
123
- alignment: {
124
- center: ['justify-center'],
125
- left: ['justify-start'],
126
- right: ['justify-end'],
127
- between: ['justify-between'],
128
- },
129
- },
130
- compoundVariants: [],
131
- defaultVariants: {
132
- variant: 'btn-primary',
133
- shape: 'round-md',
134
- padding: 'md',
135
- alignment: 'left',
136
- },
137
- });
138
- const linkIcon = cva(['inline-flex items-center'], {
139
- variants: {
140
23
  iconPosition: {
141
- left: ['flex-row gap-2'],
142
- right: ['flex-row-reverse gap-2'],
24
+ left: [''],
25
+ right: ['flex-row-reverse'],
143
26
  },
144
27
  },
145
28
  compoundVariants: [],
146
29
  defaultVariants: {
30
+ variant: 'primary',
147
31
  iconPosition: 'left',
148
32
  },
149
33
  });
150
- const linkComponent = ({ variant, shape, padding, alignment, iconPosition } = {}) => cx(linkContainer({ variant, shape, padding, alignment }), linkIcon({ iconPosition }));
151
34
  class LinkComponent {
152
35
  router;
153
36
  // base
154
37
  variant = input();
155
- shape = input();
156
- padding = input();
157
- alignment = input();
38
+ icon = input();
158
39
  iconPosition = input();
159
- fontSize = input('body-sm');
160
- containerClasses = input('');
161
- iconClasses = input('');
162
40
  label = input('');
163
- icon = input();
164
- fallbackIcon = matHomeOutline;
165
- iconArrowRight = matKeyboardArrowRightOutline;
166
- opened = false;
167
- activeClasses = 'bg-primary text-neutral-content font-semibold';
168
41
  // router
169
- route = input();
170
- childrenRoutes = input();
171
- routerLinkActiveOptions = input({ exact: false });
42
+ routerLink = input(null);
43
+ routerLinkOptions = input({ exact: false });
44
+ routerLinkActive = input('active');
45
+ queryParams = input(null);
46
+ queryParamsHandling = input(null);
47
+ fragment = input(undefined);
172
48
  constructor(router) {
173
49
  this.router = router;
174
50
  }
175
- get containerClass() {
176
- return cn(linkContainer({
51
+ get componentClass() {
52
+ return cn(linkComponent({
177
53
  variant: this.variant(),
178
- shape: this.shape(),
179
- padding: this.padding(),
180
- alignment: this.alignment(),
181
- class: this.containerClasses(),
182
- }));
183
- }
184
- get iconClass() {
185
- return cn(linkIcon({
186
54
  iconPosition: this.iconPosition(),
187
- class: this.iconClasses(),
188
55
  }));
189
56
  }
190
- get dropdownClass() {
191
- return cn({ 'invisible h-0 mt-[5px]': this.opened === false, 'visible h-auto mt-[5px] grid grid-cols-[max-content_1fr]': this.opened === true });
192
- }
193
- get isOpenedClass() {
194
- return cn({ 'rotate-0 transition-transform duration-150 ease-ease-out-back': this.opened === false }, { 'rotate-90 transition-transform duration-150 ease-ease-out-back': this.opened === true });
195
- }
196
- ngOnInit() {
197
- this.router.events.pipe(filter((event) => event instanceof NavigationEnd)).subscribe(() => {
198
- const currentPath = this.router.url;
199
- this.updateOpenedState(currentPath);
200
- });
201
- const lastOpenedNavlink = localStorage.getItem('lastOpenedNavlink');
202
- if (lastOpenedNavlink !== null) {
203
- this.opened = this.childrenRoutes()?.some((route) => lastOpenedNavlink === this.route()?.path + route.path) ?? false;
204
- }
205
- }
206
- updateOpenedState(currentPath) {
207
- this.opened = this.childrenRoutes()?.some((route) => currentPath.includes(this.route()?.path + route.path)) ?? false;
208
- localStorage.setItem('lastOpenedNavlink', currentPath);
209
- }
210
- toggle() {
211
- this.opened = !this.opened;
212
- }
213
57
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.12", ngImport: i0, type: LinkComponent, deps: [{ token: i1.Router }], target: i0.ɵɵFactoryTarget.Component });
214
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.12", type: LinkComponent, isStandalone: true, selector: "st-link", inputs: { variant: { classPropertyName: "variant", publicName: "variant", isSignal: true, isRequired: false, transformFunction: null }, shape: { classPropertyName: "shape", publicName: "shape", isSignal: true, isRequired: false, transformFunction: null }, padding: { classPropertyName: "padding", publicName: "padding", isSignal: true, isRequired: false, transformFunction: null }, alignment: { classPropertyName: "alignment", publicName: "alignment", isSignal: true, isRequired: false, transformFunction: null }, iconPosition: { classPropertyName: "iconPosition", publicName: "iconPosition", isSignal: true, isRequired: false, transformFunction: null }, fontSize: { classPropertyName: "fontSize", publicName: "fontSize", isSignal: true, isRequired: false, transformFunction: null }, containerClasses: { classPropertyName: "containerClasses", publicName: "containerClasses", isSignal: true, isRequired: false, transformFunction: null }, iconClasses: { classPropertyName: "iconClasses", publicName: "iconClasses", isSignal: true, isRequired: false, transformFunction: null }, label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null }, icon: { classPropertyName: "icon", publicName: "icon", isSignal: true, isRequired: false, transformFunction: null }, route: { classPropertyName: "route", publicName: "route", isSignal: true, isRequired: false, transformFunction: null }, childrenRoutes: { classPropertyName: "childrenRoutes", publicName: "childrenRoutes", isSignal: true, isRequired: false, transformFunction: null }, routerLinkActiveOptions: { classPropertyName: "routerLinkActiveOptions", publicName: "routerLinkActiveOptions", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "@let routeVar = this.route();\n@let childrenRoutesVar = this.childrenRoutes();\n@let fontSizeVar = this.fontSize();\n@let iconVar = this.icon();\n@let routerLinkActiveOptionsVar = this.routerLinkActiveOptions();\n@let variantVar = this.variant();\n\n@if (variantVar === 'btn-primary' || variantVar === 'btn-secondary' || variantVar === 'btn-warning' || variantVar === 'btn-error') {\n\t@if (routeVar !== undefined) {\n\t\t<a\n\t\t\t[class]=\"containerClass\"\n\t\t\t[routerLink]=\"routeVar.path\"\n\t\t\t[routerLinkActive]=\"activeClasses\"\n\t\t\t[routerLinkActiveOptions]=\"routerLinkActiveOptionsVar\"\n\t\t>\n\t\t\t@if (iconVar) {\n\t\t\t\t<span [class]=\"iconClass\">\n\t\t\t\t\t@if (this.label()) {\n\t\t\t\t\t\t<st-icon [icon]=\"iconVar ?? fallbackIcon\" color=\"inherit\" size=\"md\"></st-icon>\n\t\t\t\t\t\t<span typography [typographyVariant]=\"fontSizeVar\" [typographyColor]=\"'inherit'\" [typographyFontWeight]=\"'inherit'\">{{ label() }}</span>\n\t\t\t\t\t}\n\t\t\t\t\t@if (!this.label()) {\n\t\t\t\t\t\t<st-icon [icon]=\"iconVar ?? fallbackIcon\" color=\"inherit\" size=\"md\"></st-icon>\n\t\t\t\t\t}\n\t\t\t\t</span>\n\t\t\t}\n\t\t\t@if (!iconVar && this.label()) {\n\t\t\t\t<span typography [typographyVariant]=\"fontSizeVar\" [typographyColor]=\"'inherit'\" [typographyFontWeight]=\"'inherit'\">{{ label() }}</span>\n\t\t\t}\n\t\t</a>\n\t} @else {\n\t\t<a [class]=\"containerClass\">\n\t\t\t@if (iconVar) {\n\t\t\t\t<span [class]=\"iconClass\">\n\t\t\t\t\t@if (this.label()) {\n\t\t\t\t\t\t<st-icon [icon]=\"iconVar ?? fallbackIcon\" color=\"inherit\" size=\"md\"></st-icon>\n\t\t\t\t\t\t<span typography [typographyVariant]=\"fontSizeVar\" [typographyColor]=\"'inherit'\" [typographyFontWeight]=\"'inherit'\">{{ label() }}</span>\n\t\t\t\t\t}\n\t\t\t\t\t@if (!this.label()) {\n\t\t\t\t\t\t<st-icon [icon]=\"iconVar ?? fallbackIcon\" color=\"inherit\" size=\"md\"></st-icon>\n\t\t\t\t\t}\n\t\t\t\t</span>\n\t\t\t}\n\t\t\t@if (!iconVar && this.label()) {\n\t\t\t\t<span typography [typographyVariant]=\"fontSizeVar\" [typographyColor]=\"'inherit'\" [typographyFontWeight]=\"'inherit'\">{{ label() }}</span>\n\t\t\t}\n\t\t</a>\n\t}\n} @else if (variantVar === 'btn-collapsable-primary') {\n\t@if (routeVar !== undefined) {\n\t\t<button [class]=\"containerClass\" (click)=\"toggle()\">\n\t\t\t<div class=\"inline-flex items-center justify-start gap-2\">\n\t\t\t\t@if (iconVar) {\n\t\t\t\t\t<st-icon [icon]=\"iconVar ?? fallbackIcon\" color=\"inherit\" size=\"md\"></st-icon>\n\t\t\t\t}\n\t\t\t\t<span typography [typographyVariant]=\"fontSizeVar\" [typographyColor]=\"'inherit'\" [typographyFontWeight]=\"'inherit'\">{{\n\t\t\t\t\trouteVar.label\n\t\t\t\t}}</span>\n\t\t\t</div>\n\t\t\t<div [class]=\"isOpenedClass\">\n\t\t\t\t<st-icon [icon]=\"iconArrowRight\" color=\"inherit\" size=\"md\"></st-icon>\n\t\t\t</div>\n\t\t</button>\n\n\t\t<div [class]=\"dropdownClass\">\n\t\t\t<div class=\"ml-9 mr-2 h-full w-[2px] self-center bg-separator\"></div>\n\t\t\t<ul class=\"space-y-[5px]\">\n\t\t\t\t@for (item of childrenRoutesVar; track $index) {\n\t\t\t\t\t<li>\n\t\t\t\t\t\t<a\n\t\t\t\t\t\t\tclass=\"inline-flex h-auto min-h-12 w-full items-center justify-start gap-2 rounded-btn-md px-6 py-2 font-normal text-neutral hover:bg-primary hover:font-semibold hover:text-neutral-content focus:bg-primary focus:font-semibold focus:text-neutral-content active:hover:bg-primary active:hover:font-semibold active:hover:text-neutral-content active:focus:bg-primary active:focus:font-semibold active:focus:text-neutral-content\"\n\t\t\t\t\t\t\t[routerLink]=\"routeVar?.path ? routeVar?.path + item.path : '#'\"\n\t\t\t\t\t\t\t[routerLinkActive]=\"activeClasses\"\n\t\t\t\t\t\t\t[routerLinkActiveOptions]=\"routerLinkActiveOptionsVar\"\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t<span typography [typographyVariant]=\"fontSizeVar\" [typographyColor]=\"'inherit'\" [typographyFontWeight]=\"'inherit'\">{{\n\t\t\t\t\t\t\t\titem.label\n\t\t\t\t\t\t\t}}</span>\n\t\t\t\t\t\t</a>\n\t\t\t\t\t</li>\n\t\t\t\t}\n\t\t\t</ul>\n\t\t</div>\n\t} @else {\n\t\t<button [class]=\"containerClass\" (click)=\"toggle()\">\n\t\t\t<div class=\"inline-flex items-center justify-start gap-2\">\n\t\t\t\t@if (iconVar) {\n\t\t\t\t\t<st-icon [icon]=\"iconVar ?? fallbackIcon\" color=\"inherit\" size=\"md\"></st-icon>\n\t\t\t\t}\n\t\t\t\t<span typography [typographyVariant]=\"fontSizeVar\" [typographyColor]=\"'inherit'\" [typographyFontWeight]=\"'inherit'\">{{ 'Empty' }}</span>\n\t\t\t</div>\n\t\t\t<div [class]=\"isOpenedClass\">\n\t\t\t\t<st-icon [icon]=\"iconArrowRight\" color=\"inherit\" size=\"md\"></st-icon>\n\t\t\t</div>\n\t\t</button>\n\n\t\t<div [class]=\"dropdownClass\">\n\t\t\t<div class=\"ml-9 mr-2 h-full w-[2px] self-center bg-separator\"></div>\n\t\t\t<ul class=\"space-y-[5px]\">\n\t\t\t\t@for (item of childrenRoutesVar; track $index) {\n\t\t\t\t\t<li>\n\t\t\t\t\t\t<a\n\t\t\t\t\t\t\tclass=\"inline-flex h-auto min-h-12 w-full items-center justify-start gap-2 rounded-btn-md px-6 py-2 font-normal text-neutral hover:bg-primary hover:font-semibold hover:text-neutral-content focus:bg-primary focus:font-semibold focus:text-neutral-content active:hover:bg-primary active:hover:font-semibold active:hover:text-neutral-content active:focus:bg-primary active:focus:font-semibold active:focus:text-neutral-content\"\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t<span typography [typographyVariant]=\"fontSizeVar\" [typographyColor]=\"'inherit'\" [typographyFontWeight]=\"'inherit'\">{{\n\t\t\t\t\t\t\t\titem.label\n\t\t\t\t\t\t\t}}</span>\n\t\t\t\t\t\t</a>\n\t\t\t\t\t</li>\n\t\t\t\t}\n\t\t\t</ul>\n\t\t</div>\n\t}\n} @else {\n\t@if (routeVar !== undefined) {\n\t\t<a\n\t\t\t[class]=\"containerClass\"\n\t\t\t[routerLink]=\"routeVar.path\"\n\t\t\t[routerLinkActive]=\"activeClasses\"\n\t\t\t[routerLinkActiveOptions]=\"routerLinkActiveOptionsVar\"\n\t\t>\n\t\t\t@if (iconVar) {\n\t\t\t\t<span [class]=\"iconClass\">\n\t\t\t\t\t@if (this.label()) {\n\t\t\t\t\t\t<st-icon [icon]=\"iconVar ?? fallbackIcon\" color=\"inherit\" size=\"md\"></st-icon>\n\t\t\t\t\t\t<span typography [typographyVariant]=\"fontSizeVar\" [typographyColor]=\"'inherit'\" [typographyFontWeight]=\"'inherit'\">{{ label() }}</span>\n\t\t\t\t\t}\n\t\t\t\t\t@if (!this.label()) {\n\t\t\t\t\t\t<st-icon [icon]=\"iconVar ?? fallbackIcon\" color=\"inherit\" size=\"md\"></st-icon>\n\t\t\t\t\t}\n\t\t\t\t</span>\n\t\t\t}\n\t\t\t@if (!iconVar && this.label()) {\n\t\t\t\t<span typography [typographyVariant]=\"fontSizeVar\" [typographyColor]=\"'inherit'\" [typographyFontWeight]=\"'inherit'\">{{ label() }}</span>\n\t\t\t}\n\t\t</a>\n\t} @else {\n\t\t<a [class]=\"containerClass\">\n\t\t\t@if (iconVar) {\n\t\t\t\t<span [class]=\"iconClass\">\n\t\t\t\t\t@if (this.label()) {\n\t\t\t\t\t\t<st-icon [icon]=\"iconVar ?? fallbackIcon\" color=\"inherit\" size=\"md\"></st-icon>\n\t\t\t\t\t\t<span typography [typographyVariant]=\"fontSizeVar\" [typographyColor]=\"'inherit'\" [typographyFontWeight]=\"'inherit'\">{{ label() }}</span>\n\t\t\t\t\t}\n\t\t\t\t\t@if (!this.label()) {\n\t\t\t\t\t\t<st-icon [icon]=\"iconVar ?? fallbackIcon\" color=\"inherit\" size=\"md\"></st-icon>\n\t\t\t\t\t}\n\t\t\t\t</span>\n\t\t\t}\n\t\t\t@if (!iconVar && this.label()) {\n\t\t\t\t<span typography [typographyVariant]=\"fontSizeVar\" [typographyColor]=\"'inherit'\" [typographyFontWeight]=\"'inherit'\">{{ label() }}</span>\n\t\t\t}\n\t\t</a>\n\t}\n}\n", styles: [""], dependencies: [{ kind: "directive", type: TypographyDirective, selector: "[typography]", inputs: ["typographyVariant", "typographyColor", "typographyFontWeight", "classes"] }, { kind: "component", type: IconComponent, selector: "st-icon", inputs: ["color", "size", "classes", "icon"] }, { kind: "directive", type: RouterLinkActive, selector: "[routerLinkActive]", inputs: ["routerLinkActiveOptions", "ariaCurrentWhenActive", "routerLinkActive"], outputs: ["isActiveChange"], exportAs: ["routerLinkActive"] }, { kind: "directive", type: RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "ngmodule", type: FormsModule }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
58
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.12", type: LinkComponent, isStandalone: true, selector: "st-link", inputs: { variant: { classPropertyName: "variant", publicName: "variant", isSignal: true, isRequired: false, transformFunction: null }, icon: { classPropertyName: "icon", publicName: "icon", isSignal: true, isRequired: false, transformFunction: null }, iconPosition: { classPropertyName: "iconPosition", publicName: "iconPosition", isSignal: true, isRequired: false, transformFunction: null }, label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null }, routerLink: { classPropertyName: "routerLink", publicName: "routerLink", isSignal: true, isRequired: false, transformFunction: null }, routerLinkOptions: { classPropertyName: "routerLinkOptions", publicName: "routerLinkOptions", isSignal: true, isRequired: false, transformFunction: null }, routerLinkActive: { classPropertyName: "routerLinkActive", publicName: "routerLinkActive", isSignal: true, isRequired: false, transformFunction: null }, queryParams: { classPropertyName: "queryParams", publicName: "queryParams", isSignal: true, isRequired: false, transformFunction: null }, queryParamsHandling: { classPropertyName: "queryParamsHandling", publicName: "queryParamsHandling", isSignal: true, isRequired: false, transformFunction: null }, fragment: { classPropertyName: "fragment", publicName: "fragment", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "@let iconVar = this.icon();\n@let routerLinkVar = this.routerLink();\n@let rotuerLinkActiveVar = this.routerLinkActive();\n@let queryParamsVar = this.queryParams();\n@let queryParamsHandlingVar = this.queryParamsHandling();\n@let routerLinkOptionsVar = routerLinkOptions();\n@let fragmentVar = this.fragment();\n<a\n\t[class]=\"componentClass\"\n\t[routerLink]=\"routerLinkVar\"\n\t[routerLinkActive]=\"rotuerLinkActiveVar\"\n\t[routerLinkActiveOptions]=\"routerLinkOptionsVar\"\n\t[queryParams]=\"queryParamsVar\"\n\t[queryParamsHandling]=\"queryParamsHandlingVar\"\n\t[fragment]=\"fragmentVar\"\n>\n\t@if (iconVar) {\n\t\t<st-icon [icon]=\"iconVar\" color=\"inherit\" size=\"md\"></st-icon>\n\t}\n\t<ng-content></ng-content>\n</a>\n", styles: [""], dependencies: [{ kind: "component", type: IconComponent, selector: "st-icon", inputs: ["color", "size", "classes", "icon"] }, { kind: "directive", type: RouterLinkActive, selector: "[routerLinkActive]", inputs: ["routerLinkActiveOptions", "ariaCurrentWhenActive", "routerLinkActive"], outputs: ["isActiveChange"], exportAs: ["routerLinkActive"] }, { kind: "directive", type: RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "ngmodule", type: FormsModule }, { kind: "ngmodule", type: CommonModule }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
215
59
  }
216
60
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.12", ngImport: i0, type: LinkComponent, decorators: [{
217
61
  type: Component,
218
- args: [{ selector: 'st-link', standalone: true, imports: [TypographyDirective, IconComponent, RouterLinkActive, RouterLink, FormsModule], changeDetection: ChangeDetectionStrategy.OnPush, template: "@let routeVar = this.route();\n@let childrenRoutesVar = this.childrenRoutes();\n@let fontSizeVar = this.fontSize();\n@let iconVar = this.icon();\n@let routerLinkActiveOptionsVar = this.routerLinkActiveOptions();\n@let variantVar = this.variant();\n\n@if (variantVar === 'btn-primary' || variantVar === 'btn-secondary' || variantVar === 'btn-warning' || variantVar === 'btn-error') {\n\t@if (routeVar !== undefined) {\n\t\t<a\n\t\t\t[class]=\"containerClass\"\n\t\t\t[routerLink]=\"routeVar.path\"\n\t\t\t[routerLinkActive]=\"activeClasses\"\n\t\t\t[routerLinkActiveOptions]=\"routerLinkActiveOptionsVar\"\n\t\t>\n\t\t\t@if (iconVar) {\n\t\t\t\t<span [class]=\"iconClass\">\n\t\t\t\t\t@if (this.label()) {\n\t\t\t\t\t\t<st-icon [icon]=\"iconVar ?? fallbackIcon\" color=\"inherit\" size=\"md\"></st-icon>\n\t\t\t\t\t\t<span typography [typographyVariant]=\"fontSizeVar\" [typographyColor]=\"'inherit'\" [typographyFontWeight]=\"'inherit'\">{{ label() }}</span>\n\t\t\t\t\t}\n\t\t\t\t\t@if (!this.label()) {\n\t\t\t\t\t\t<st-icon [icon]=\"iconVar ?? fallbackIcon\" color=\"inherit\" size=\"md\"></st-icon>\n\t\t\t\t\t}\n\t\t\t\t</span>\n\t\t\t}\n\t\t\t@if (!iconVar && this.label()) {\n\t\t\t\t<span typography [typographyVariant]=\"fontSizeVar\" [typographyColor]=\"'inherit'\" [typographyFontWeight]=\"'inherit'\">{{ label() }}</span>\n\t\t\t}\n\t\t</a>\n\t} @else {\n\t\t<a [class]=\"containerClass\">\n\t\t\t@if (iconVar) {\n\t\t\t\t<span [class]=\"iconClass\">\n\t\t\t\t\t@if (this.label()) {\n\t\t\t\t\t\t<st-icon [icon]=\"iconVar ?? fallbackIcon\" color=\"inherit\" size=\"md\"></st-icon>\n\t\t\t\t\t\t<span typography [typographyVariant]=\"fontSizeVar\" [typographyColor]=\"'inherit'\" [typographyFontWeight]=\"'inherit'\">{{ label() }}</span>\n\t\t\t\t\t}\n\t\t\t\t\t@if (!this.label()) {\n\t\t\t\t\t\t<st-icon [icon]=\"iconVar ?? fallbackIcon\" color=\"inherit\" size=\"md\"></st-icon>\n\t\t\t\t\t}\n\t\t\t\t</span>\n\t\t\t}\n\t\t\t@if (!iconVar && this.label()) {\n\t\t\t\t<span typography [typographyVariant]=\"fontSizeVar\" [typographyColor]=\"'inherit'\" [typographyFontWeight]=\"'inherit'\">{{ label() }}</span>\n\t\t\t}\n\t\t</a>\n\t}\n} @else if (variantVar === 'btn-collapsable-primary') {\n\t@if (routeVar !== undefined) {\n\t\t<button [class]=\"containerClass\" (click)=\"toggle()\">\n\t\t\t<div class=\"inline-flex items-center justify-start gap-2\">\n\t\t\t\t@if (iconVar) {\n\t\t\t\t\t<st-icon [icon]=\"iconVar ?? fallbackIcon\" color=\"inherit\" size=\"md\"></st-icon>\n\t\t\t\t}\n\t\t\t\t<span typography [typographyVariant]=\"fontSizeVar\" [typographyColor]=\"'inherit'\" [typographyFontWeight]=\"'inherit'\">{{\n\t\t\t\t\trouteVar.label\n\t\t\t\t}}</span>\n\t\t\t</div>\n\t\t\t<div [class]=\"isOpenedClass\">\n\t\t\t\t<st-icon [icon]=\"iconArrowRight\" color=\"inherit\" size=\"md\"></st-icon>\n\t\t\t</div>\n\t\t</button>\n\n\t\t<div [class]=\"dropdownClass\">\n\t\t\t<div class=\"ml-9 mr-2 h-full w-[2px] self-center bg-separator\"></div>\n\t\t\t<ul class=\"space-y-[5px]\">\n\t\t\t\t@for (item of childrenRoutesVar; track $index) {\n\t\t\t\t\t<li>\n\t\t\t\t\t\t<a\n\t\t\t\t\t\t\tclass=\"inline-flex h-auto min-h-12 w-full items-center justify-start gap-2 rounded-btn-md px-6 py-2 font-normal text-neutral hover:bg-primary hover:font-semibold hover:text-neutral-content focus:bg-primary focus:font-semibold focus:text-neutral-content active:hover:bg-primary active:hover:font-semibold active:hover:text-neutral-content active:focus:bg-primary active:focus:font-semibold active:focus:text-neutral-content\"\n\t\t\t\t\t\t\t[routerLink]=\"routeVar?.path ? routeVar?.path + item.path : '#'\"\n\t\t\t\t\t\t\t[routerLinkActive]=\"activeClasses\"\n\t\t\t\t\t\t\t[routerLinkActiveOptions]=\"routerLinkActiveOptionsVar\"\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t<span typography [typographyVariant]=\"fontSizeVar\" [typographyColor]=\"'inherit'\" [typographyFontWeight]=\"'inherit'\">{{\n\t\t\t\t\t\t\t\titem.label\n\t\t\t\t\t\t\t}}</span>\n\t\t\t\t\t\t</a>\n\t\t\t\t\t</li>\n\t\t\t\t}\n\t\t\t</ul>\n\t\t</div>\n\t} @else {\n\t\t<button [class]=\"containerClass\" (click)=\"toggle()\">\n\t\t\t<div class=\"inline-flex items-center justify-start gap-2\">\n\t\t\t\t@if (iconVar) {\n\t\t\t\t\t<st-icon [icon]=\"iconVar ?? fallbackIcon\" color=\"inherit\" size=\"md\"></st-icon>\n\t\t\t\t}\n\t\t\t\t<span typography [typographyVariant]=\"fontSizeVar\" [typographyColor]=\"'inherit'\" [typographyFontWeight]=\"'inherit'\">{{ 'Empty' }}</span>\n\t\t\t</div>\n\t\t\t<div [class]=\"isOpenedClass\">\n\t\t\t\t<st-icon [icon]=\"iconArrowRight\" color=\"inherit\" size=\"md\"></st-icon>\n\t\t\t</div>\n\t\t</button>\n\n\t\t<div [class]=\"dropdownClass\">\n\t\t\t<div class=\"ml-9 mr-2 h-full w-[2px] self-center bg-separator\"></div>\n\t\t\t<ul class=\"space-y-[5px]\">\n\t\t\t\t@for (item of childrenRoutesVar; track $index) {\n\t\t\t\t\t<li>\n\t\t\t\t\t\t<a\n\t\t\t\t\t\t\tclass=\"inline-flex h-auto min-h-12 w-full items-center justify-start gap-2 rounded-btn-md px-6 py-2 font-normal text-neutral hover:bg-primary hover:font-semibold hover:text-neutral-content focus:bg-primary focus:font-semibold focus:text-neutral-content active:hover:bg-primary active:hover:font-semibold active:hover:text-neutral-content active:focus:bg-primary active:focus:font-semibold active:focus:text-neutral-content\"\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t<span typography [typographyVariant]=\"fontSizeVar\" [typographyColor]=\"'inherit'\" [typographyFontWeight]=\"'inherit'\">{{\n\t\t\t\t\t\t\t\titem.label\n\t\t\t\t\t\t\t}}</span>\n\t\t\t\t\t\t</a>\n\t\t\t\t\t</li>\n\t\t\t\t}\n\t\t\t</ul>\n\t\t</div>\n\t}\n} @else {\n\t@if (routeVar !== undefined) {\n\t\t<a\n\t\t\t[class]=\"containerClass\"\n\t\t\t[routerLink]=\"routeVar.path\"\n\t\t\t[routerLinkActive]=\"activeClasses\"\n\t\t\t[routerLinkActiveOptions]=\"routerLinkActiveOptionsVar\"\n\t\t>\n\t\t\t@if (iconVar) {\n\t\t\t\t<span [class]=\"iconClass\">\n\t\t\t\t\t@if (this.label()) {\n\t\t\t\t\t\t<st-icon [icon]=\"iconVar ?? fallbackIcon\" color=\"inherit\" size=\"md\"></st-icon>\n\t\t\t\t\t\t<span typography [typographyVariant]=\"fontSizeVar\" [typographyColor]=\"'inherit'\" [typographyFontWeight]=\"'inherit'\">{{ label() }}</span>\n\t\t\t\t\t}\n\t\t\t\t\t@if (!this.label()) {\n\t\t\t\t\t\t<st-icon [icon]=\"iconVar ?? fallbackIcon\" color=\"inherit\" size=\"md\"></st-icon>\n\t\t\t\t\t}\n\t\t\t\t</span>\n\t\t\t}\n\t\t\t@if (!iconVar && this.label()) {\n\t\t\t\t<span typography [typographyVariant]=\"fontSizeVar\" [typographyColor]=\"'inherit'\" [typographyFontWeight]=\"'inherit'\">{{ label() }}</span>\n\t\t\t}\n\t\t</a>\n\t} @else {\n\t\t<a [class]=\"containerClass\">\n\t\t\t@if (iconVar) {\n\t\t\t\t<span [class]=\"iconClass\">\n\t\t\t\t\t@if (this.label()) {\n\t\t\t\t\t\t<st-icon [icon]=\"iconVar ?? fallbackIcon\" color=\"inherit\" size=\"md\"></st-icon>\n\t\t\t\t\t\t<span typography [typographyVariant]=\"fontSizeVar\" [typographyColor]=\"'inherit'\" [typographyFontWeight]=\"'inherit'\">{{ label() }}</span>\n\t\t\t\t\t}\n\t\t\t\t\t@if (!this.label()) {\n\t\t\t\t\t\t<st-icon [icon]=\"iconVar ?? fallbackIcon\" color=\"inherit\" size=\"md\"></st-icon>\n\t\t\t\t\t}\n\t\t\t\t</span>\n\t\t\t}\n\t\t\t@if (!iconVar && this.label()) {\n\t\t\t\t<span typography [typographyVariant]=\"fontSizeVar\" [typographyColor]=\"'inherit'\" [typographyFontWeight]=\"'inherit'\">{{ label() }}</span>\n\t\t\t}\n\t\t</a>\n\t}\n}\n" }]
62
+ args: [{ selector: 'st-link', standalone: true, imports: [IconComponent, RouterLinkActive, RouterLink, FormsModule, CommonModule], changeDetection: ChangeDetectionStrategy.OnPush, template: "@let iconVar = this.icon();\n@let routerLinkVar = this.routerLink();\n@let rotuerLinkActiveVar = this.routerLinkActive();\n@let queryParamsVar = this.queryParams();\n@let queryParamsHandlingVar = this.queryParamsHandling();\n@let routerLinkOptionsVar = routerLinkOptions();\n@let fragmentVar = this.fragment();\n<a\n\t[class]=\"componentClass\"\n\t[routerLink]=\"routerLinkVar\"\n\t[routerLinkActive]=\"rotuerLinkActiveVar\"\n\t[routerLinkActiveOptions]=\"routerLinkOptionsVar\"\n\t[queryParams]=\"queryParamsVar\"\n\t[queryParamsHandling]=\"queryParamsHandlingVar\"\n\t[fragment]=\"fragmentVar\"\n>\n\t@if (iconVar) {\n\t\t<st-icon [icon]=\"iconVar\" color=\"inherit\" size=\"md\"></st-icon>\n\t}\n\t<ng-content></ng-content>\n</a>\n" }]
219
63
  }], ctorParameters: () => [{ type: i1.Router }] });
220
64
 
221
65
  /**
222
66
  * Generated bundle index. Do not edit.
223
67
  */
224
68
 
225
- export { LinkComponent, linkComponent, linkContainer, linkIcon };
69
+ export { LinkComponent, linkComponent };
226
70
  //# sourceMappingURL=sixbell-telco-sdk-components-link.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"sixbell-telco-sdk-components-link.mjs","sources":["../../../projects/sdk/components/link/src/link.component.ts","../../../projects/sdk/components/link/src/link.component.html","../../../projects/sdk/components/link/sixbell-telco-sdk-components-link.ts"],"sourcesContent":["import { ChangeDetectionStrategy, Component, input, OnInit } from '@angular/core';\nimport { FormsModule } from '@angular/forms';\nimport { NavigationEnd, Router, RouterLink, RouterLinkActive } from '@angular/router';\nimport { IconComponent } from '@sixbell-telco/sdk/components/icon';\nimport { matHomeOutline, matKeyboardArrowRightOutline } from '@sixbell-telco/sdk/components/icon/material/outline';\nimport { TypographyDirective, TypographyVariantProps } from '@sixbell-telco/sdk/directives/typography';\nimport { cn } from '@sixbell-telco/sdk/utils/cn';\nimport { cva, cx } from 'class-variance-authority';\nimport { filter } from 'rxjs';\n\nexport type Route = {\n\tlabel: string;\n\tpath: string;\n};\n\nexport const linkContainer = cva([], {\n\tvariants: {\n\t\tvariant: {\n\t\t\tprimary: ['link', 'link-primary', 'no-underline'],\n\t\t\tsecondary: ['link', 'link-secondary', 'no-underline'],\n\t\t\taccent: ['link', 'link-accent', 'no-underline'],\n\t\t\tsuccess: ['link', 'link-success', 'no-underline'],\n\t\t\tinfo: ['link', 'link-info', 'no-underline'],\n\t\t\twarning: ['link', 'link-warning', 'no-underline'],\n\t\t\terror: ['link', 'link-error', 'no-underline'],\n\t\t\t'btn-primary': [\n\t\t\t\t'btn',\n\t\t\t\t'min-h-12',\n\t\t\t\t'btn-ghost',\n\t\t\t\t'h-auto',\n\t\t\t\t'font-normal',\n\t\t\t\t'text-neutral',\n\t\t\t\t'hover:font-semibold',\n\t\t\t\t'hover:text-primary-content',\n\t\t\t\t'hover:bg-primary',\n\t\t\t\t'active:hover:font-semibold',\n\t\t\t\t'active:hover:text-primary-content',\n\t\t\t\t'active:hover:bg-primary',\n\t\t\t\t'active:focus:font-semibold',\n\t\t\t\t'active:focus:text-primary-content',\n\t\t\t\t'active:focus:bg-primary',\n\t\t\t],\n\t\t\t'btn-secondary': [\n\t\t\t\t'btn',\n\t\t\t\t'min-h-12',\n\t\t\t\t'btn-ghost',\n\t\t\t\t'h-auto',\n\t\t\t\t'font-normal',\n\t\t\t\t'text-neutral',\n\t\t\t\t'hover:font-semibold',\n\t\t\t\t'hover:text-secondary-content',\n\t\t\t\t'hover:bg-secondary',\n\t\t\t\t'active:hover:font-semibold',\n\t\t\t\t'active:hover:text-secondary-content',\n\t\t\t\t'active:hover:bg-secondary',\n\t\t\t\t'active:focus:font-semibold',\n\t\t\t\t'active:focus:text-secondary-content',\n\t\t\t\t'active:focus:bg-secondary',\n\t\t\t],\n\t\t\t'btn-warning': [\n\t\t\t\t'btn',\n\t\t\t\t'min-h-12',\n\t\t\t\t'btn-ghost',\n\t\t\t\t'h-auto',\n\t\t\t\t'font-normal',\n\t\t\t\t'text-neutral',\n\t\t\t\t'hover:font-semibold',\n\t\t\t\t'hover:text-warning-content',\n\t\t\t\t'hover:bg-warning',\n\t\t\t\t'active:hover:font-semibold',\n\t\t\t\t'active:hover:text-warning-content',\n\t\t\t\t'active:hover:bg-warning',\n\t\t\t\t'active:focus:font-semibold',\n\t\t\t\t'active:focus:text-warning-content',\n\t\t\t\t'active:focus:bg-warning',\n\t\t\t],\n\t\t\t'btn-error': [\n\t\t\t\t'btn',\n\t\t\t\t'min-h-12',\n\t\t\t\t'btn-ghost',\n\t\t\t\t'h-auto',\n\t\t\t\t'font-normal',\n\t\t\t\t'text-neutral',\n\t\t\t\t'hover:font-semibold',\n\t\t\t\t'hover:text-error-content',\n\t\t\t\t'hover:bg-error',\n\t\t\t\t'active:hover:font-semibold',\n\t\t\t\t'active:hover:text-error-content',\n\t\t\t\t'active:hover:bg-error',\n\t\t\t\t'active:focus:font-semibold',\n\t\t\t\t'active:focus:text-error-content',\n\t\t\t\t'active:focus:bg-error',\n\t\t\t],\n\t\t\t'btn-collapsable-primary': [\n\t\t\t\t'btn',\n\t\t\t\t'min-h-12',\n\t\t\t\t'btn-ghost',\n\t\t\t\t'h-auto',\n\t\t\t\t'items-center',\n\t\t\t\t'gap-2',\n\t\t\t\t'font-normal',\n\t\t\t\t'text-neutral',\n\t\t\t\t'hover:font-semibold',\n\t\t\t\t'hover:text-neutral-content',\n\t\t\t\t'hover:bg-primary',\n\t\t\t\t'active:hover:font-semibold',\n\t\t\t\t'active:hover:text-neutral-content',\n\t\t\t\t'active:hover:bg-primary',\n\t\t\t\t'active:focus:font-semibold',\n\t\t\t\t'active:focus:text-neutral-content',\n\t\t\t\t'active:focus:bg-primary',\n\t\t\t],\n\t\t},\n\t\tshape: {\n\t\t\t'round-none': ['rounded-none'],\n\t\t\t'round-sm': ['rounded-btn-sm'],\n\t\t\t'round-md': ['rounded-btn-md'],\n\t\t\t'round-lg': ['rounded-btn-lg'],\n\t\t},\n\t\tpadding: {\n\t\t\tnone: [],\n\t\t\tsm: ['px-2', 'py-1'],\n\t\t\tmd: ['px-3', 'py-2'],\n\t\t\tlg: ['px-4', 'py-3'],\n\t\t},\n\t\talignment: {\n\t\t\tcenter: ['justify-center'],\n\t\t\tleft: ['justify-start'],\n\t\t\tright: ['justify-end'],\n\t\t\tbetween: ['justify-between'],\n\t\t},\n\t},\n\tcompoundVariants: [],\n\tdefaultVariants: {\n\t\tvariant: 'btn-primary',\n\t\tshape: 'round-md',\n\t\tpadding: 'md',\n\t\talignment: 'left',\n\t},\n});\n\nexport type LinkContainerVariantProps =\n\t| 'primary'\n\t| 'secondary'\n\t| 'accent'\n\t| 'success'\n\t| 'info'\n\t| 'warning'\n\t| 'error'\n\t| 'btn-primary'\n\t| 'btn-secondary'\n\t| 'btn-warning'\n\t| 'btn-error'\n\t| 'btn-collapsable-primary';\nexport type LinkContainerShapeProps = 'round-none' | 'round-sm' | 'round-md' | 'round-lg';\nexport type LinkContainerPaddingProps = 'none' | 'sm' | 'md' | 'lg';\nexport type LinkContainerAlignmentProps = 'center' | 'left' | 'right' | 'between';\n\nexport const linkIcon = cva(['inline-flex items-center'], {\n\tvariants: {\n\t\ticonPosition: {\n\t\t\tleft: ['flex-row gap-2'],\n\t\t\tright: ['flex-row-reverse gap-2'],\n\t\t},\n\t},\n\tcompoundVariants: [],\n\tdefaultVariants: {\n\t\ticonPosition: 'left',\n\t},\n});\n\nexport type LinkIconPositionProps = 'left' | 'right';\n\nexport type LinkProps = {\n\tvariant?: LinkContainerVariantProps;\n\tshape?: LinkContainerShapeProps;\n\tpadding?: LinkContainerPaddingProps;\n\talignment?: LinkContainerAlignmentProps;\n\ticonPosition?: LinkIconPositionProps;\n};\n\nexport const linkComponent = ({ variant, shape, padding, alignment, iconPosition }: LinkProps = {}) =>\n\tcx(linkContainer({ variant, shape, padding, alignment }), linkIcon({ iconPosition }));\n\n@Component({\n\tselector: 'st-link',\n\tstandalone: true,\n\timports: [TypographyDirective, IconComponent, RouterLinkActive, RouterLink, FormsModule],\n\ttemplateUrl: './link.component.html',\n\tstyles: '',\n\tchangeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class LinkComponent implements OnInit {\n\t// base\n\tvariant = input<LinkContainerVariantProps>();\n\tshape = input<LinkContainerShapeProps>();\n\tpadding = input<LinkContainerPaddingProps>();\n\talignment = input<LinkContainerAlignmentProps>();\n\ticonPosition = input<LinkIconPositionProps>();\n\tfontSize = input<TypographyVariantProps>('body-sm');\n\tcontainerClasses = input<string>('');\n\ticonClasses = input<string>('');\n\tlabel = input<string>('');\n\ticon = input<string | undefined>();\n\tfallbackIcon = matHomeOutline;\n\ticonArrowRight = matKeyboardArrowRightOutline;\n\topened: boolean = false;\n\tactiveClasses = 'bg-primary text-neutral-content font-semibold';\n\n\t// router\n\troute = input<Route>();\n\tchildrenRoutes = input<Route[]>();\n\trouterLinkActiveOptions = input<{ exact: boolean }>({ exact: false });\n\n\tconstructor(private router: Router) {}\n\n\tget containerClass() {\n\t\treturn cn(\n\t\t\tlinkContainer({\n\t\t\t\tvariant: this.variant(),\n\t\t\t\tshape: this.shape(),\n\t\t\t\tpadding: this.padding(),\n\t\t\t\talignment: this.alignment(),\n\t\t\t\tclass: this.containerClasses(),\n\t\t\t}),\n\t\t);\n\t}\n\n\tget iconClass() {\n\t\treturn cn(\n\t\t\tlinkIcon({\n\t\t\t\ticonPosition: this.iconPosition(),\n\t\t\t\tclass: this.iconClasses(),\n\t\t\t}),\n\t\t);\n\t}\n\n\tget dropdownClass() {\n\t\treturn cn({ 'invisible h-0 mt-[5px]': this.opened === false, 'visible h-auto mt-[5px] grid grid-cols-[max-content_1fr]': this.opened === true });\n\t}\n\n\tget isOpenedClass() {\n\t\treturn cn(\n\t\t\t{ 'rotate-0 transition-transform duration-150 ease-ease-out-back': this.opened === false },\n\t\t\t{ 'rotate-90 transition-transform duration-150 ease-ease-out-back': this.opened === true },\n\t\t);\n\t}\n\n\tngOnInit(): void {\n\t\tthis.router.events.pipe(filter((event) => event instanceof NavigationEnd)).subscribe(() => {\n\t\t\tconst currentPath = this.router.url;\n\t\t\tthis.updateOpenedState(currentPath);\n\t\t});\n\n\t\tconst lastOpenedNavlink = localStorage.getItem('lastOpenedNavlink');\n\t\tif (lastOpenedNavlink !== null) {\n\t\t\tthis.opened = this.childrenRoutes()?.some((route) => lastOpenedNavlink === this.route()?.path + route.path) ?? false;\n\t\t}\n\t}\n\n\tupdateOpenedState(currentPath: string): void {\n\t\tthis.opened = this.childrenRoutes()?.some((route) => currentPath.includes(this.route()?.path + route.path)) ?? false;\n\t\tlocalStorage.setItem('lastOpenedNavlink', currentPath);\n\t}\n\n\ttoggle() {\n\t\tthis.opened = !this.opened;\n\t}\n}\n","@let routeVar = this.route();\n@let childrenRoutesVar = this.childrenRoutes();\n@let fontSizeVar = this.fontSize();\n@let iconVar = this.icon();\n@let routerLinkActiveOptionsVar = this.routerLinkActiveOptions();\n@let variantVar = this.variant();\n\n@if (variantVar === 'btn-primary' || variantVar === 'btn-secondary' || variantVar === 'btn-warning' || variantVar === 'btn-error') {\n\t@if (routeVar !== undefined) {\n\t\t<a\n\t\t\t[class]=\"containerClass\"\n\t\t\t[routerLink]=\"routeVar.path\"\n\t\t\t[routerLinkActive]=\"activeClasses\"\n\t\t\t[routerLinkActiveOptions]=\"routerLinkActiveOptionsVar\"\n\t\t>\n\t\t\t@if (iconVar) {\n\t\t\t\t<span [class]=\"iconClass\">\n\t\t\t\t\t@if (this.label()) {\n\t\t\t\t\t\t<st-icon [icon]=\"iconVar ?? fallbackIcon\" color=\"inherit\" size=\"md\"></st-icon>\n\t\t\t\t\t\t<span typography [typographyVariant]=\"fontSizeVar\" [typographyColor]=\"'inherit'\" [typographyFontWeight]=\"'inherit'\">{{ label() }}</span>\n\t\t\t\t\t}\n\t\t\t\t\t@if (!this.label()) {\n\t\t\t\t\t\t<st-icon [icon]=\"iconVar ?? fallbackIcon\" color=\"inherit\" size=\"md\"></st-icon>\n\t\t\t\t\t}\n\t\t\t\t</span>\n\t\t\t}\n\t\t\t@if (!iconVar && this.label()) {\n\t\t\t\t<span typography [typographyVariant]=\"fontSizeVar\" [typographyColor]=\"'inherit'\" [typographyFontWeight]=\"'inherit'\">{{ label() }}</span>\n\t\t\t}\n\t\t</a>\n\t} @else {\n\t\t<a [class]=\"containerClass\">\n\t\t\t@if (iconVar) {\n\t\t\t\t<span [class]=\"iconClass\">\n\t\t\t\t\t@if (this.label()) {\n\t\t\t\t\t\t<st-icon [icon]=\"iconVar ?? fallbackIcon\" color=\"inherit\" size=\"md\"></st-icon>\n\t\t\t\t\t\t<span typography [typographyVariant]=\"fontSizeVar\" [typographyColor]=\"'inherit'\" [typographyFontWeight]=\"'inherit'\">{{ label() }}</span>\n\t\t\t\t\t}\n\t\t\t\t\t@if (!this.label()) {\n\t\t\t\t\t\t<st-icon [icon]=\"iconVar ?? fallbackIcon\" color=\"inherit\" size=\"md\"></st-icon>\n\t\t\t\t\t}\n\t\t\t\t</span>\n\t\t\t}\n\t\t\t@if (!iconVar && this.label()) {\n\t\t\t\t<span typography [typographyVariant]=\"fontSizeVar\" [typographyColor]=\"'inherit'\" [typographyFontWeight]=\"'inherit'\">{{ label() }}</span>\n\t\t\t}\n\t\t</a>\n\t}\n} @else if (variantVar === 'btn-collapsable-primary') {\n\t@if (routeVar !== undefined) {\n\t\t<button [class]=\"containerClass\" (click)=\"toggle()\">\n\t\t\t<div class=\"inline-flex items-center justify-start gap-2\">\n\t\t\t\t@if (iconVar) {\n\t\t\t\t\t<st-icon [icon]=\"iconVar ?? fallbackIcon\" color=\"inherit\" size=\"md\"></st-icon>\n\t\t\t\t}\n\t\t\t\t<span typography [typographyVariant]=\"fontSizeVar\" [typographyColor]=\"'inherit'\" [typographyFontWeight]=\"'inherit'\">{{\n\t\t\t\t\trouteVar.label\n\t\t\t\t}}</span>\n\t\t\t</div>\n\t\t\t<div [class]=\"isOpenedClass\">\n\t\t\t\t<st-icon [icon]=\"iconArrowRight\" color=\"inherit\" size=\"md\"></st-icon>\n\t\t\t</div>\n\t\t</button>\n\n\t\t<div [class]=\"dropdownClass\">\n\t\t\t<div class=\"ml-9 mr-2 h-full w-[2px] self-center bg-separator\"></div>\n\t\t\t<ul class=\"space-y-[5px]\">\n\t\t\t\t@for (item of childrenRoutesVar; track $index) {\n\t\t\t\t\t<li>\n\t\t\t\t\t\t<a\n\t\t\t\t\t\t\tclass=\"inline-flex h-auto min-h-12 w-full items-center justify-start gap-2 rounded-btn-md px-6 py-2 font-normal text-neutral hover:bg-primary hover:font-semibold hover:text-neutral-content focus:bg-primary focus:font-semibold focus:text-neutral-content active:hover:bg-primary active:hover:font-semibold active:hover:text-neutral-content active:focus:bg-primary active:focus:font-semibold active:focus:text-neutral-content\"\n\t\t\t\t\t\t\t[routerLink]=\"routeVar?.path ? routeVar?.path + item.path : '#'\"\n\t\t\t\t\t\t\t[routerLinkActive]=\"activeClasses\"\n\t\t\t\t\t\t\t[routerLinkActiveOptions]=\"routerLinkActiveOptionsVar\"\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t<span typography [typographyVariant]=\"fontSizeVar\" [typographyColor]=\"'inherit'\" [typographyFontWeight]=\"'inherit'\">{{\n\t\t\t\t\t\t\t\titem.label\n\t\t\t\t\t\t\t}}</span>\n\t\t\t\t\t\t</a>\n\t\t\t\t\t</li>\n\t\t\t\t}\n\t\t\t</ul>\n\t\t</div>\n\t} @else {\n\t\t<button [class]=\"containerClass\" (click)=\"toggle()\">\n\t\t\t<div class=\"inline-flex items-center justify-start gap-2\">\n\t\t\t\t@if (iconVar) {\n\t\t\t\t\t<st-icon [icon]=\"iconVar ?? fallbackIcon\" color=\"inherit\" size=\"md\"></st-icon>\n\t\t\t\t}\n\t\t\t\t<span typography [typographyVariant]=\"fontSizeVar\" [typographyColor]=\"'inherit'\" [typographyFontWeight]=\"'inherit'\">{{ 'Empty' }}</span>\n\t\t\t</div>\n\t\t\t<div [class]=\"isOpenedClass\">\n\t\t\t\t<st-icon [icon]=\"iconArrowRight\" color=\"inherit\" size=\"md\"></st-icon>\n\t\t\t</div>\n\t\t</button>\n\n\t\t<div [class]=\"dropdownClass\">\n\t\t\t<div class=\"ml-9 mr-2 h-full w-[2px] self-center bg-separator\"></div>\n\t\t\t<ul class=\"space-y-[5px]\">\n\t\t\t\t@for (item of childrenRoutesVar; track $index) {\n\t\t\t\t\t<li>\n\t\t\t\t\t\t<a\n\t\t\t\t\t\t\tclass=\"inline-flex h-auto min-h-12 w-full items-center justify-start gap-2 rounded-btn-md px-6 py-2 font-normal text-neutral hover:bg-primary hover:font-semibold hover:text-neutral-content focus:bg-primary focus:font-semibold focus:text-neutral-content active:hover:bg-primary active:hover:font-semibold active:hover:text-neutral-content active:focus:bg-primary active:focus:font-semibold active:focus:text-neutral-content\"\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t<span typography [typographyVariant]=\"fontSizeVar\" [typographyColor]=\"'inherit'\" [typographyFontWeight]=\"'inherit'\">{{\n\t\t\t\t\t\t\t\titem.label\n\t\t\t\t\t\t\t}}</span>\n\t\t\t\t\t\t</a>\n\t\t\t\t\t</li>\n\t\t\t\t}\n\t\t\t</ul>\n\t\t</div>\n\t}\n} @else {\n\t@if (routeVar !== undefined) {\n\t\t<a\n\t\t\t[class]=\"containerClass\"\n\t\t\t[routerLink]=\"routeVar.path\"\n\t\t\t[routerLinkActive]=\"activeClasses\"\n\t\t\t[routerLinkActiveOptions]=\"routerLinkActiveOptionsVar\"\n\t\t>\n\t\t\t@if (iconVar) {\n\t\t\t\t<span [class]=\"iconClass\">\n\t\t\t\t\t@if (this.label()) {\n\t\t\t\t\t\t<st-icon [icon]=\"iconVar ?? fallbackIcon\" color=\"inherit\" size=\"md\"></st-icon>\n\t\t\t\t\t\t<span typography [typographyVariant]=\"fontSizeVar\" [typographyColor]=\"'inherit'\" [typographyFontWeight]=\"'inherit'\">{{ label() }}</span>\n\t\t\t\t\t}\n\t\t\t\t\t@if (!this.label()) {\n\t\t\t\t\t\t<st-icon [icon]=\"iconVar ?? fallbackIcon\" color=\"inherit\" size=\"md\"></st-icon>\n\t\t\t\t\t}\n\t\t\t\t</span>\n\t\t\t}\n\t\t\t@if (!iconVar && this.label()) {\n\t\t\t\t<span typography [typographyVariant]=\"fontSizeVar\" [typographyColor]=\"'inherit'\" [typographyFontWeight]=\"'inherit'\">{{ label() }}</span>\n\t\t\t}\n\t\t</a>\n\t} @else {\n\t\t<a [class]=\"containerClass\">\n\t\t\t@if (iconVar) {\n\t\t\t\t<span [class]=\"iconClass\">\n\t\t\t\t\t@if (this.label()) {\n\t\t\t\t\t\t<st-icon [icon]=\"iconVar ?? fallbackIcon\" color=\"inherit\" size=\"md\"></st-icon>\n\t\t\t\t\t\t<span typography [typographyVariant]=\"fontSizeVar\" [typographyColor]=\"'inherit'\" [typographyFontWeight]=\"'inherit'\">{{ label() }}</span>\n\t\t\t\t\t}\n\t\t\t\t\t@if (!this.label()) {\n\t\t\t\t\t\t<st-icon [icon]=\"iconVar ?? fallbackIcon\" color=\"inherit\" size=\"md\"></st-icon>\n\t\t\t\t\t}\n\t\t\t\t</span>\n\t\t\t}\n\t\t\t@if (!iconVar && this.label()) {\n\t\t\t\t<span typography [typographyVariant]=\"fontSizeVar\" [typographyColor]=\"'inherit'\" [typographyFontWeight]=\"'inherit'\">{{ label() }}</span>\n\t\t\t}\n\t\t</a>\n\t}\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;;;;;AAea,MAAA,aAAa,GAAG,GAAG,CAAC,EAAE,EAAE;AACpC,IAAA,QAAQ,EAAE;AACT,QAAA,OAAO,EAAE;AACR,YAAA,OAAO,EAAE,CAAC,MAAM,EAAE,cAAc,EAAE,cAAc,CAAC;AACjD,YAAA,SAAS,EAAE,CAAC,MAAM,EAAE,gBAAgB,EAAE,cAAc,CAAC;AACrD,YAAA,MAAM,EAAE,CAAC,MAAM,EAAE,aAAa,EAAE,cAAc,CAAC;AAC/C,YAAA,OAAO,EAAE,CAAC,MAAM,EAAE,cAAc,EAAE,cAAc,CAAC;AACjD,YAAA,IAAI,EAAE,CAAC,MAAM,EAAE,WAAW,EAAE,cAAc,CAAC;AAC3C,YAAA,OAAO,EAAE,CAAC,MAAM,EAAE,cAAc,EAAE,cAAc,CAAC;AACjD,YAAA,KAAK,EAAE,CAAC,MAAM,EAAE,YAAY,EAAE,cAAc,CAAC;AAC7C,YAAA,aAAa,EAAE;gBACd,KAAK;gBACL,UAAU;gBACV,WAAW;gBACX,QAAQ;gBACR,aAAa;gBACb,cAAc;gBACd,qBAAqB;gBACrB,4BAA4B;gBAC5B,kBAAkB;gBAClB,4BAA4B;gBAC5B,mCAAmC;gBACnC,yBAAyB;gBACzB,4BAA4B;gBAC5B,mCAAmC;gBACnC,yBAAyB;AACzB,aAAA;AACD,YAAA,eAAe,EAAE;gBAChB,KAAK;gBACL,UAAU;gBACV,WAAW;gBACX,QAAQ;gBACR,aAAa;gBACb,c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;AAEG;;;;"}
1
+ {"version":3,"file":"sixbell-telco-sdk-components-link.mjs","sources":["../../../projects/sdk/components/link/src/link.component.ts","../../../projects/sdk/components/link/src/link.component.html","../../../projects/sdk/components/link/sixbell-telco-sdk-components-link.ts"],"sourcesContent":["import { CommonModule } from '@angular/common';\nimport { ChangeDetectionStrategy, Component, input } from '@angular/core';\nimport { FormsModule } from '@angular/forms';\nimport { Router, RouterLink, RouterLinkActive } from '@angular/router';\nimport { IconComponent } from '@sixbell-telco/sdk/components/icon';\nimport { cn } from '@sixbell-telco/sdk/utils/cn';\nimport { cva } from 'class-variance-authority';\n\nexport type Route = {\n\tlabel: string;\n\tpath: string;\n};\n\nexport const linkComponent = cva(['link', 'font-body', 'font-normal', 'inline-flex', 'items-center', 'leading-normal'], {\n\tvariants: {\n\t\tvariant: {\n\t\t\tprimary: ['link-primary', 'no-underline'],\n\t\t\tsecondary: ['link-secondary', 'no-underline'],\n\t\t\ttertiary: ['link-tertiary', 'no-underline'],\n\t\t\taccent: ['link-accent', 'no-underline'],\n\t\t\tsuccess: ['link-success', 'no-underline'],\n\t\t\tinfo: ['link-info', 'no-underline'],\n\t\t\twarning: ['link-warning', 'no-underline'],\n\t\t\terror: ['link-error', 'no-underline'],\n\t\t},\n\t\ticonPosition: {\n\t\t\tleft: [''],\n\t\t\tright: ['flex-row-reverse'],\n\t\t},\n\t},\n\tcompoundVariants: [],\n\tdefaultVariants: {\n\t\tvariant: 'primary',\n\t\ticonPosition: 'left',\n\t},\n});\n\nexport type LinkVariantProps = 'primary' | 'secondary' | 'tertiary' | 'accent' | 'success' | 'info' | 'warning' | 'error' | null | undefined;\nexport type LinkIconPositionProps = 'left' | 'right' | null | undefined;\n\nexport type LinkProps = {\n\tvariant?: LinkVariantProps;\n\ticonPosition?: LinkIconPositionProps;\n};\n\n@Component({\n\tselector: 'st-link',\n\tstandalone: true,\n\timports: [IconComponent, RouterLinkActive, RouterLink, FormsModule, CommonModule],\n\ttemplateUrl: './link.component.html',\n\tstyles: '',\n\tchangeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class LinkComponent {\n\t// base\n\tvariant = input<LinkVariantProps>();\n\ticon = input<string | undefined>();\n\ticonPosition = input<LinkIconPositionProps>();\n\tlabel = input<string>('');\n\n\t// router\n\trouterLink = input<RouterLink['routerLink']>(null);\n\trouterLinkOptions = input<RouterLinkActive['routerLinkActiveOptions']>({ exact: false });\n\trouterLinkActive = input<RouterLinkActive['routerLinkActive']>('active');\n\tqueryParams = input<RouterLink['queryParams']>(null);\n\tqueryParamsHandling = input<RouterLink['queryParamsHandling']>(null);\n\tfragment = input<RouterLink['fragment']>(undefined);\n\n\tconstructor(private router: Router) {}\n\n\tget componentClass() {\n\t\treturn cn(\n\t\t\tlinkComponent({\n\t\t\t\tvariant: this.variant(),\n\t\t\t\ticonPosition: this.iconPosition(),\n\t\t\t}),\n\t\t);\n\t}\n}\n","@let iconVar = this.icon();\n@let routerLinkVar = this.routerLink();\n@let rotuerLinkActiveVar = this.routerLinkActive();\n@let queryParamsVar = this.queryParams();\n@let queryParamsHandlingVar = this.queryParamsHandling();\n@let routerLinkOptionsVar = routerLinkOptions();\n@let fragmentVar = this.fragment();\n<a\n\t[class]=\"componentClass\"\n\t[routerLink]=\"routerLinkVar\"\n\t[routerLinkActive]=\"rotuerLinkActiveVar\"\n\t[routerLinkActiveOptions]=\"routerLinkOptionsVar\"\n\t[queryParams]=\"queryParamsVar\"\n\t[queryParamsHandling]=\"queryParamsHandlingVar\"\n\t[fragment]=\"fragmentVar\"\n>\n\t@if (iconVar) {\n\t\t<st-icon [icon]=\"iconVar\" color=\"inherit\" size=\"md\"></st-icon>\n\t}\n\t<ng-content></ng-content>\n</a>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;;;AAaa,MAAA,aAAa,GAAG,GAAG,CAAC,CAAC,MAAM,EAAE,WAAW,EAAE,aAAa,EAAE,aAAa,EAAE,cAAc,EAAE,gB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AAA,EAAA,MAAA,EAAA,CAAA,yBAAA,EAAA,uBAAA,EAAA,kBAAA,CAAA,EAAA,OAAA,EAAA,CAAA,gBAAA,CAAA,EAAA,QAAA,EAAA,CAAA,kBAAA,CAAA,EAAA,EAAA,EAAA,IAAA,EAAA,WAAA,EAAA,IAAA,EAAE,UAAU,EAAA,QAAA,EAAA,cAAA,EAAA,MAAA,EAAA,CAAA,QAAA,EAAA,aAAA,EAAA,UAAA,EAAA,qBAAA,EAAA,OAAA,EAAA,MAAA,EAAA,YAAA,EAAA,kBAAA,EAAA,oBAAA,EAAA,YAAA,EAAA,YAAA,CAAA,EAAA,EAAA,EAAA,IAAA,EAAA,UAAA,EAAA,IAAA,EAAE,WAAW,EAAA,EAAA,EAAA,IAAA,EAAA,UAAA,EAAA,IAAA,EAAE,YAAY,EAAA,CAAA,EAAA,eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,MAAA,EAAA,CAAA,CAAA;;4FAKpE,aAAa,EAAA,UAAA,EAAA,CAAA;kBARzB,SAAS;AACC,YAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,SAAS,cACP,IAAI,EAAA,OAAA,EACP,CAAC,aAAa,EAAE,gBAAgB,EAAE,UAAU,EAAE,WAAW,EAAE,YAAY,CAAC,EAGhE,eAAA,EAAA,uBAAuB,CAAC,MAAM,EAAA,QAAA,EAAA,guBAAA,EAAA,CAAA;;;AEnDhD;;AAEG;;;;"}
@@ -1,48 +1,73 @@
1
+ import { CommonModule } from '@angular/common';
1
2
  import * as i0 from '@angular/core';
2
- import { input, output, viewChild, effect, Component } from '@angular/core';
3
+ import { input, Component, ChangeDetectionStrategy, output, viewChild, model, effect } from '@angular/core';
3
4
  import { cn } from '@sixbell-telco/sdk/utils/cn';
5
+ import { TypographyDirective } from '@sixbell-telco/sdk/directives/typography';
6
+ import { matCloseOutline } from '@sixbell-telco/sdk/components/icon/material/outline';
4
7
  import { cva } from 'class-variance-authority';
5
8
 
6
- const modalComponent = cva([], {
9
+ class ModalActionsComponent {
10
+ // Base table properties
11
+ alignment = input('left');
12
+ get componentClass() {
13
+ return cn('modal-action', {
14
+ 'justify-start': this.alignment() === 'left',
15
+ 'justify-end': this.alignment() === 'right',
16
+ 'justify-center': this.alignment() === 'center',
17
+ });
18
+ }
19
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.12", ngImport: i0, type: ModalActionsComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
20
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "18.2.12", type: ModalActionsComponent, isStandalone: true, selector: "st-modal-actions", inputs: { alignment: { classPropertyName: "alignment", publicName: "alignment", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "<div [class]=\"componentClass\">\n\t<ng-content></ng-content>\n</div>\n", dependencies: [{ kind: "ngmodule", type: CommonModule }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
21
+ }
22
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.12", ngImport: i0, type: ModalActionsComponent, decorators: [{
23
+ type: Component,
24
+ args: [{ selector: 'st-modal-actions', standalone: true, imports: [CommonModule], changeDetection: ChangeDetectionStrategy.OnPush, template: "<div [class]=\"componentClass\">\n\t<ng-content></ng-content>\n</div>\n" }]
25
+ }] });
26
+
27
+ class ModalContentComponent {
28
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.12", ngImport: i0, type: ModalContentComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
29
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.12", type: ModalContentComponent, isStandalone: true, selector: "st-modal-content", ngImport: i0, template: "<ng-content></ng-content>\n", dependencies: [{ kind: "ngmodule", type: CommonModule }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
30
+ }
31
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.12", ngImport: i0, type: ModalContentComponent, decorators: [{
32
+ type: Component,
33
+ args: [{ selector: 'st-modal-content', standalone: true, imports: [CommonModule], changeDetection: ChangeDetectionStrategy.OnPush, template: "<ng-content></ng-content>\n" }]
34
+ }] });
35
+
36
+ class ModalTitleComponent {
37
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.12", ngImport: i0, type: ModalTitleComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
38
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "18.2.12", type: ModalTitleComponent, isStandalone: true, selector: "st-modal-title", ngImport: i0, template: "<div class=\"mb-6\">\n\t<div typography tyFontWeight=\"semibold\" tyColor=\"base\" tyVariant=\"h3\">\n\t\t<ng-content></ng-content>\n\t</div>\n</div>\n", dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: TypographyDirective, selector: "[typography]", inputs: ["tyVariant", "tyColor", "tyFontWeight"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
39
+ }
40
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.12", ngImport: i0, type: ModalTitleComponent, decorators: [{
41
+ type: Component,
42
+ args: [{ selector: 'st-modal-title', standalone: true, imports: [CommonModule, TypographyDirective], changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"mb-6\">\n\t<div typography tyFontWeight=\"semibold\" tyColor=\"base\" tyVariant=\"h3\">\n\t\t<ng-content></ng-content>\n\t</div>\n</div>\n" }]
43
+ }] });
44
+
45
+ const modalComponent = cva(['modal-box', 'bg-base-200', 'p-6', 'text-base-content'], {
7
46
  variants: {
8
- variant: {
9
- primary: ['modal-box'],
10
- },
11
- shape: {
12
- 'round-sm': ['rounded-box-sm'],
13
- 'round-md': ['rounded-box-md'],
14
- 'round-lg': ['rounded-box-lg'],
15
- },
16
- padding: {
17
- none: 'p-0',
18
- sm: ['p-4'],
19
- md: ['p-6'],
20
- lg: ['px-8'],
21
- },
22
47
  width: {
23
48
  full: ['w-full'],
24
49
  fit: ['w-fit', 'min-w-fit'],
25
50
  },
51
+ aligment: {
52
+ top: ['modal-top'],
53
+ center: ['modal-middle'],
54
+ bottom: ['modal-bottom'],
55
+ },
26
56
  },
27
57
  compoundVariants: [],
28
58
  defaultVariants: {
29
- variant: 'primary',
30
- shape: 'round-lg',
31
- padding: 'md',
32
59
  width: 'full',
60
+ aligment: 'center',
33
61
  },
34
62
  });
35
63
  class ModalComponent {
36
- variant = input();
37
- shape = input();
38
- padding = input();
39
64
  width = input();
40
- classes = input('');
41
- label = input('');
65
+ alignment = input('center');
42
66
  modalId = input.required();
43
67
  onClickOutside = output();
68
+ iconClose = matCloseOutline;
44
69
  dialog = viewChild('dialog');
45
- opened = input(false);
70
+ opened = model(false);
46
71
  openedEffect = effect(() => {
47
72
  if (this.opened()) {
48
73
  this.handleOpen();
@@ -53,30 +78,40 @@ class ModalComponent {
53
78
  });
54
79
  get componentClass() {
55
80
  return cn(modalComponent({
56
- variant: this.variant(),
57
- shape: this.shape(),
58
- padding: this.padding(),
59
81
  width: this.width(),
60
- class: this.classes(),
61
82
  }));
62
83
  }
84
+ get modalClass() {
85
+ return cn('modal', {
86
+ 'modal-top': this.alignment() === 'top',
87
+ 'modal-middle': this.alignment() === 'center',
88
+ 'modal-bottom': this.alignment() === 'bottom',
89
+ });
90
+ }
63
91
  handleOpen() {
64
92
  this.dialog()?.nativeElement.showModal();
65
93
  }
66
94
  handleClose() {
67
95
  this.dialog()?.nativeElement.close();
68
96
  }
97
+ handleCloseClick() {
98
+ this.opened.set(false);
99
+ }
100
+ handleCancelClick(event) {
101
+ event.preventDefault();
102
+ this.opened.set(false);
103
+ }
69
104
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.12", ngImport: i0, type: ModalComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
70
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.2.0", version: "18.2.12", type: ModalComponent, isStandalone: true, selector: "st-modal", inputs: { variant: { classPropertyName: "variant", publicName: "variant", isSignal: true, isRequired: false, transformFunction: null }, shape: { classPropertyName: "shape", publicName: "shape", isSignal: true, isRequired: false, transformFunction: null }, padding: { classPropertyName: "padding", publicName: "padding", isSignal: true, isRequired: false, transformFunction: null }, width: { classPropertyName: "width", publicName: "width", isSignal: true, isRequired: false, transformFunction: null }, classes: { classPropertyName: "classes", publicName: "classes", isSignal: true, isRequired: false, transformFunction: null }, label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null }, modalId: { classPropertyName: "modalId", publicName: "modalId", isSignal: true, isRequired: true, transformFunction: null }, opened: { classPropertyName: "opened", publicName: "opened", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { onClickOutside: "onClickOutside" }, viewQueries: [{ propertyName: "dialog", first: true, predicate: ["dialog"], descendants: true, isSignal: true }], ngImport: i0, template: "<dialog #dialog [id]=\"modalId()\" class=\"modal\">\n\t<div [class]=\"componentClass\">\n\t\t<ng-content />\n\t</div>\n\t<form method=\"dialog\" class=\"modal-backdrop\">\n\t\t<button (click)=\"onClickOutside.emit()\">close</button>\n\t</form>\n</dialog>\n", styles: [""] });
105
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.2.0", version: "18.2.12", type: ModalComponent, isStandalone: true, selector: "st-modal", inputs: { width: { classPropertyName: "width", publicName: "width", isSignal: true, isRequired: false, transformFunction: null }, alignment: { classPropertyName: "alignment", publicName: "alignment", isSignal: true, isRequired: false, transformFunction: null }, modalId: { classPropertyName: "modalId", publicName: "modalId", isSignal: true, isRequired: true, transformFunction: null }, opened: { classPropertyName: "opened", publicName: "opened", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { onClickOutside: "onClickOutside", opened: "openedChange" }, viewQueries: [{ propertyName: "dialog", first: true, predicate: ["dialog"], descendants: true, isSignal: true }], ngImport: i0, template: "<!-- eslint-disable @angular-eslint/template/elements-content -->\n<dialog #dialog [id]=\"modalId()\" [class]=\"modalClass\" (cancel)=\"handleCancelClick($event)\">\n\t<div [class]=\"componentClass\">\n\t\t<div class=\"absolute right-2 top-2\">\n\t\t\t<button class=\"btn btn-circle btn-ghost btn-sm absolute right-0 top-0\" (click)=\"handleCloseClick()\">\u2715</button>\n\t\t</div>\n\t\t<ng-content select=\"st-modal-title\"></ng-content>\n\t\t<ng-content select=\"st-modal-content\"></ng-content>\n\t\t<ng-content select=\"st-modal-actions\"></ng-content>\n\t</div>\n\t<form method=\"dialog\" class=\"modal-backdrop\">\n\t\t<button (click)=\"onClickOutside.emit()\"></button>\n\t</form>\n</dialog>\n", styles: [""] });
71
106
  }
72
107
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.12", ngImport: i0, type: ModalComponent, decorators: [{
73
108
  type: Component,
74
- args: [{ selector: 'st-modal', standalone: true, imports: [], template: "<dialog #dialog [id]=\"modalId()\" class=\"modal\">\n\t<div [class]=\"componentClass\">\n\t\t<ng-content />\n\t</div>\n\t<form method=\"dialog\" class=\"modal-backdrop\">\n\t\t<button (click)=\"onClickOutside.emit()\">close</button>\n\t</form>\n</dialog>\n" }]
109
+ args: [{ selector: 'st-modal', standalone: true, imports: [], template: "<!-- eslint-disable @angular-eslint/template/elements-content -->\n<dialog #dialog [id]=\"modalId()\" [class]=\"modalClass\" (cancel)=\"handleCancelClick($event)\">\n\t<div [class]=\"componentClass\">\n\t\t<div class=\"absolute right-2 top-2\">\n\t\t\t<button class=\"btn btn-circle btn-ghost btn-sm absolute right-0 top-0\" (click)=\"handleCloseClick()\">\u2715</button>\n\t\t</div>\n\t\t<ng-content select=\"st-modal-title\"></ng-content>\n\t\t<ng-content select=\"st-modal-content\"></ng-content>\n\t\t<ng-content select=\"st-modal-actions\"></ng-content>\n\t</div>\n\t<form method=\"dialog\" class=\"modal-backdrop\">\n\t\t<button (click)=\"onClickOutside.emit()\"></button>\n\t</form>\n</dialog>\n" }]
75
110
  }] });
76
111
 
77
112
  /**
78
113
  * Generated bundle index. Do not edit.
79
114
  */
80
115
 
81
- export { ModalComponent, modalComponent };
116
+ export { ModalActionsComponent, ModalComponent, ModalContentComponent, ModalTitleComponent, modalComponent };
82
117
  //# sourceMappingURL=sixbell-telco-sdk-components-modal.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"sixbell-telco-sdk-components-modal.mjs","sources":["../../../projects/sdk/components/modal/src/modal.component.ts","../../../projects/sdk/components/modal/src/modal.component.html","../../../projects/sdk/components/modal/sixbell-telco-sdk-components-modal.ts"],"sourcesContent":["import { Component, effect, ElementRef, input, output, viewChild } from '@angular/core';\nimport { cn } from '@sixbell-telco/sdk/utils/cn';\nimport { cva } from 'class-variance-authority';\n\nexport const modalComponent = cva([], {\n\tvariants: {\n\t\tvariant: {\n\t\t\tprimary: ['modal-box'],\n\t\t},\n\t\tshape: {\n\t\t\t'round-sm': ['rounded-box-sm'],\n\t\t\t'round-md': ['rounded-box-md'],\n\t\t\t'round-lg': ['rounded-box-lg'],\n\t\t},\n\t\tpadding: {\n\t\t\tnone: 'p-0',\n\t\t\tsm: ['p-4'],\n\t\t\tmd: ['p-6'],\n\t\t\tlg: ['px-8'],\n\t\t},\n\t\twidth: {\n\t\t\tfull: ['w-full'],\n\t\t\tfit: ['w-fit', 'min-w-fit'],\n\t\t},\n\t},\n\tcompoundVariants: [],\n\tdefaultVariants: {\n\t\tvariant: 'primary',\n\t\tshape: 'round-lg',\n\t\tpadding: 'md',\n\t\twidth: 'full',\n\t},\n});\n\nexport type ModalVariantProps = 'primary' | null | undefined;\nexport type ModalShapeProps = 'round-sm' | 'round-md' | 'round-lg' | null | undefined;\nexport type ModalPaddingProps = 'none' | 'sm' | 'md' | 'lg' | null | undefined;\nexport type ModalWidthProps = 'full' | 'fit' | null | undefined;\n\nexport type ModalProps = {\n\tvariant?: ModalVariantProps;\n\tshape?: ModalShapeProps;\n\tpadding?: ModalPaddingProps;\n\twidth?: ModalWidthProps;\n};\n\n@Component({\n\tselector: 'st-modal',\n\tstandalone: true,\n\timports: [],\n\ttemplateUrl: './modal.component.html',\n\tstyles: '',\n})\nexport class ModalComponent {\n\tvariant = input<ModalVariantProps>();\n\tshape = input<ModalShapeProps>();\n\tpadding = input<ModalPaddingProps>();\n\twidth = input<ModalWidthProps>();\n\tclasses = input<string>('');\n\tlabel = input<string>('');\n\tmodalId = input.required<string>();\n\tonClickOutside = output<void>();\n\n\tdialog = viewChild<ElementRef<HTMLDialogElement>>('dialog');\n\n\topened = input<boolean>(false);\n\topenedEffect = effect(() => {\n\t\tif (this.opened()) {\n\t\t\tthis.handleOpen();\n\t\t} else {\n\t\t\tthis.handleClose();\n\t\t}\n\t});\n\n\tget componentClass() {\n\t\treturn cn(\n\t\t\tmodalComponent({\n\t\t\t\tvariant: this.variant(),\n\t\t\t\tshape: this.shape(),\n\t\t\t\tpadding: this.padding(),\n\t\t\t\twidth: this.width(),\n\t\t\t\tclass: this.classes(),\n\t\t\t}),\n\t\t);\n\t}\n\n\thandleOpen() {\n\t\tthis.dialog()?.nativeElement.showModal();\n\t}\n\n\thandleClose() {\n\t\tthis.dialog()?.nativeElement.close();\n\t}\n}\n","<dialog #dialog [id]=\"modalId()\" class=\"modal\">\n\t<div [class]=\"componentClass\">\n\t\t<ng-content />\n\t</div>\n\t<form method=\"dialog\" class=\"modal-backdrop\">\n\t\t<button (click)=\"onClickOutside.emit()\">close</button>\n\t</form>\n</dialog>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;AAIa,MAAA,cAAc,GAAG,GAAG,CAAC,EAAE,EAAE;AACrC,IAAA,QAAQ,EAAE;AACT,QAAA,OAAO,EAAE;YACR,OAAO,EAAE,CAAC,WAAW,CAAC;AACtB,SAAA;AACD,QAAA,KAAK,EAAE;YACN,UAAU,EAAE,CAAC,gBAAgB,CAAC;YAC9B,UAAU,EAAE,CAAC,gBAAgB,CAAC;YAC9B,UAAU,EAAE,CAAC,gBAAgB,CAAC;AAC9B,SA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QACjB,OAAO,EAAE,CACR,cAAc,CAAC;AACd,YAAA,OAAO,EAAE,IAAI,CAAC,OAAO,EAAE;AACvB,YAAA,KAAK,EAAE,IAAI,CAAC,KAAK,EAAE;AACnB,YAAA,OAAO,EAAE,IAAI,CAAC,OAAO,EAAE;AACvB,YAAA,KAAK,EAAE,IAAI,CAAC,KAAK,EAAE;AACnB,YAAA,KAAK,EAAE,IAAI,CAAC,OAAO,EAAE;AACrB,SAAA,CAAC,CACF,CAAC;KACF;IAED,UAAU,GAAA;QACT,IAAI,CAAC,MAAM,EAAE,EAAE,aAAa,CAAC,SAAS,EAAE,CAAC;KACzC;IAED,WAAW,GAAA;QACV,IAAI,CAAC,MAAM,EAAE,EAAE,aAAa,CAAC,KAAK,EAAE,CAAC;KACrC;wGAvCW,cAAc,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;AAAd,IAAA,OAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,IAAA,EAAA,cAAc,2sCCrD3B,kQAQA,EAAA,MAAA,EAAA,CAAA,EAAA,CAAA,EAAA,CAAA,CAAA;;4FD6Ca,cAAc,EAAA,UAAA,EAAA,CAAA;kBAP1B,SAAS;+BACC,UAAU,EAAA,UAAA,EACR,IAAI,EAAA,OAAA,EACP,EAAE,EAAA,QAAA,EAAA,kQAAA,EAAA,CAAA;;;AEjDZ;;AAEG;;;;"}
1
+ {"version":3,"file":"sixbell-telco-sdk-components-modal.mjs","sources":["../../../projects/sdk/components/modal/modal-actions/modal-actions.component.ts","../../../projects/sdk/components/modal/modal-actions/modal-actions.component.html","../../../projects/sdk/components/modal/modal-content/modal-content.component.ts","../../../projects/sdk/components/modal/modal-content/modal-content.component.html","../../../projects/sdk/components/modal/modal-title/modal-title.component.ts","../../../projects/sdk/components/modal/modal-title/modal-title.component.html","../../../projects/sdk/components/modal/src/modal.component.ts","../../../projects/sdk/components/modal/src/modal.component.html","../../../projects/sdk/components/modal/sixbell-telco-sdk-components-modal.ts"],"sourcesContent":["import { CommonModule } from '@angular/common';\nimport { ChangeDetectionStrategy, Component, input } from '@angular/core';\nimport { cn } from '@sixbell-telco/sdk/utils/cn';\n\nexport type ModalActionsAligmentProps = 'left' | 'right' | 'center';\n\n@Component({\n\t// eslint-disable-next-line @angular-eslint/component-selector\n\tselector: 'st-modal-actions',\n\tstandalone: true,\n\timports: [CommonModule],\n\ttemplateUrl: './modal-actions.component.html',\n\tchangeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class ModalActionsComponent {\n\t// Base table properties\n\talignment = input<ModalActionsAligmentProps>('left');\n\n\tget componentClass() {\n\t\treturn cn('modal-action', {\n\t\t\t'justify-start': this.alignment() === 'left',\n\t\t\t'justify-end': this.alignment() === 'right',\n\t\t\t'justify-center': this.alignment() === 'center',\n\t\t});\n\t}\n}\n","<div [class]=\"componentClass\">\n\t<ng-content></ng-content>\n</div>\n","import { CommonModule } from '@angular/common';\nimport { ChangeDetectionStrategy, Component } from '@angular/core';\n\n@Component({\n\t// eslint-disable-next-line @angular-eslint/component-selector\n\tselector: 'st-modal-content',\n\tstandalone: true,\n\timports: [CommonModule],\n\ttemplateUrl: './modal-content.component.html',\n\tchangeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class ModalContentComponent {}\n","<ng-content></ng-content>\n","import { CommonModule } from '@angular/common';\nimport { ChangeDetectionStrategy, Component } from '@angular/core';\nimport { TypographyDirective } from '@sixbell-telco/sdk/directives/typography';\n\n@Component({\n\t// eslint-disable-next-line @angular-eslint/component-selector\n\tselector: 'st-modal-title',\n\tstandalone: true,\n\timports: [CommonModule, TypographyDirective],\n\ttemplateUrl: './modal-title.component.html',\n\tchangeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class ModalTitleComponent {}\n","<div class=\"mb-6\">\n\t<div typography tyFontWeight=\"semibold\" tyColor=\"base\" tyVariant=\"h3\">\n\t\t<ng-content></ng-content>\n\t</div>\n</div>\n","import { Component, effect, ElementRef, input, model, output, viewChild } from '@angular/core';\nimport { matCloseOutline } from '@sixbell-telco/sdk/components/icon/material/outline';\nimport { cn } from '@sixbell-telco/sdk/utils/cn';\nimport { cva } from 'class-variance-authority';\n\nexport const modalComponent = cva(['modal-box', 'bg-base-200', 'p-6', 'text-base-content'], {\n\tvariants: {\n\t\twidth: {\n\t\t\tfull: ['w-full'],\n\t\t\tfit: ['w-fit', 'min-w-fit'],\n\t\t},\n\t\taligment: {\n\t\t\ttop: ['modal-top'],\n\t\t\tcenter: ['modal-middle'],\n\t\t\tbottom: ['modal-bottom'],\n\t\t},\n\t},\n\tcompoundVariants: [],\n\tdefaultVariants: {\n\t\twidth: 'full',\n\t\taligment: 'center',\n\t},\n});\n\nexport type ModalPaddingProps = 'none' | 'sm' | 'md' | 'lg' | null | undefined;\nexport type ModalWidthProps = 'full' | 'fit' | null | undefined;\nexport type ModalAlignmentProps = 'top' | 'center' | 'bottom' | null | undefined;\n\nexport type ModalProps = {\n\tpadding?: ModalPaddingProps;\n\twidth?: ModalWidthProps;\n\talignment?: ModalAlignmentProps;\n};\n\n@Component({\n\tselector: 'st-modal',\n\tstandalone: true,\n\timports: [],\n\ttemplateUrl: './modal.component.html',\n\tstyles: '',\n})\nexport class ModalComponent {\n\twidth = input<ModalWidthProps>();\n\talignment = input<ModalAlignmentProps>('center');\n\tmodalId = input.required<string>();\n\tonClickOutside = output<void>();\n\n\ticonClose = matCloseOutline;\n\tdialog = viewChild<ElementRef<HTMLDialogElement>>('dialog');\n\n\topened = model<boolean>(false);\n\topenedEffect = effect(() => {\n\t\tif (this.opened()) {\n\t\t\tthis.handleOpen();\n\t\t} else {\n\t\t\tthis.handleClose();\n\t\t}\n\t});\n\n\tget componentClass() {\n\t\treturn cn(\n\t\t\tmodalComponent({\n\t\t\t\twidth: this.width(),\n\t\t\t}),\n\t\t);\n\t}\n\n\tget modalClass() {\n\t\treturn cn('modal', {\n\t\t\t'modal-top': this.alignment() === 'top',\n\t\t\t'modal-middle': this.alignment() === 'center',\n\t\t\t'modal-bottom': this.alignment() === 'bottom',\n\t\t});\n\t}\n\n\thandleOpen() {\n\t\tthis.dialog()?.nativeElement.showModal();\n\t}\n\n\thandleClose() {\n\t\tthis.dialog()?.nativeElement.close();\n\t}\n\n\thandleCloseClick() {\n\t\tthis.opened.set(false);\n\t}\n\n\thandleCancelClick(event: Event) {\n\t\tevent.preventDefault();\n\t\tthis.opened.set(false);\n\t}\n}\n","<!-- eslint-disable @angular-eslint/template/elements-content -->\n<dialog #dialog [id]=\"modalId()\" [class]=\"modalClass\" (cancel)=\"handleCancelClick($event)\">\n\t<div [class]=\"componentClass\">\n\t\t<div class=\"absolute right-2 top-2\">\n\t\t\t<button class=\"btn btn-circle btn-ghost btn-sm absolute right-0 top-0\" (click)=\"handleCloseClick()\">✕</button>\n\t\t</div>\n\t\t<ng-content select=\"st-modal-title\"></ng-content>\n\t\t<ng-content select=\"st-modal-content\"></ng-content>\n\t\t<ng-content select=\"st-modal-actions\"></ng-content>\n\t</div>\n\t<form method=\"dialog\" class=\"modal-backdrop\">\n\t\t<button (click)=\"onClickOutside.emit()\"></button>\n\t</form>\n</dialog>\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;MAca,qBAAqB,CAAA;;AAEjC,IAAA,SAAS,GAAG,KAAK,CAA4B,MAAM,CAAC,CAAC;AAErD,IAAA,IAAI,cAAc,GAAA;QACjB,OAAO,EAAE,CAAC,cAAc,EAAE;AACzB,YAAA,eAAe,EAAE,IAAI,CAAC,SAAS,EAAE,KAAK,MAAM;AAC5C,YAAA,aAAa,EAAE,IAAI,CAAC,SAAS,EAAE,KAAK,OAAO;AAC3C,YAAA,gBAAgB,EAAE,IAAI,CAAC,SAAS,EAAE,KAAK,QAAQ;AAC/C,SAAA,CAAC,CAAC;KACH;wGAVW,qBAAqB,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KACH;IAED,UAAU,GAAA;QACT,IAAI,CAAC,MAAM,EAAE,EAAE,aAAa,CAAC,SAAS,EAAE,CAAC;KACzC;IAED,WAAW,GAAA;QACV,IAAI,CAAC,MAAM,EAAE,EAAE,aAAa,CAAC,KAAK,EAAE,CAAC;KACrC;IAED,gBAAgB,GAAA;AACf,QAAA,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC;KACvB;AAED,IAAA,iBAAiB,CAAC,KAAY,EAAA;QAC7B,KAAK,CAAC,cAAc,EAAE,CAAC;AACvB,QAAA,IAAI,CAAC,MAAM,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC;KACvB;wGAjDW,cAAc,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;AAAd,IAAA,OAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,IAAA,EAAA,cAAc,6vBCzC3B,gsBAcA,EAAA,MAAA,EAAA,CAAA,EAAA,CAAA,EAAA,CAAA,CAAA;;4FD2Ba,cAAc,EAAA,UAAA,EAAA,CAAA;kBAP1B,SAAS;+BACC,UAAU,EAAA,UAAA,EACR,IAAI,EAAA,OAAA,EACP,EAAE,EAAA,QAAA,EAAA,gsBAAA,EAAA,CAAA;;;AErCZ;;AAEG;;;;"}
@@ -13,13 +13,10 @@ const notificationComponent = cva([], {
13
13
  'btn-circle',
14
14
  'btn-outline',
15
15
  'text-neutral',
16
- 'border-ring',
16
+ 'border-neutral-secondary',
17
17
  'hover:text-neutral',
18
18
  'active:hover:text-neutral-content',
19
- 'hover:border-ring-accent',
20
19
  'hover:bg-transparent',
21
- 'active:hover:bg-ring-accent',
22
- 'active:focus:border-ring-accent',
23
20
  ],
24
21
  },
25
22
  shape: {