@raqm/ui 0.0.0-stage → 0.1.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 (178) hide show
  1. package/CHANGELOG.md +22 -0
  2. package/LICENSE +21 -0
  3. package/NOTICE.md +28 -0
  4. package/README.md +126 -3
  5. package/combobox/README.md +17 -0
  6. package/fesm2022/raqm-ui-accordion.mjs +414 -0
  7. package/fesm2022/raqm-ui-accordion.mjs.map +1 -0
  8. package/fesm2022/raqm-ui-alert-dialog.mjs +457 -0
  9. package/fesm2022/raqm-ui-alert-dialog.mjs.map +1 -0
  10. package/fesm2022/raqm-ui-alert.mjs +195 -0
  11. package/fesm2022/raqm-ui-alert.mjs.map +1 -0
  12. package/fesm2022/raqm-ui-aspect-ratio.mjs +66 -0
  13. package/fesm2022/raqm-ui-aspect-ratio.mjs.map +1 -0
  14. package/fesm2022/raqm-ui-attachment.mjs +435 -0
  15. package/fesm2022/raqm-ui-attachment.mjs.map +1 -0
  16. package/fesm2022/raqm-ui-avatar.mjs +337 -0
  17. package/fesm2022/raqm-ui-avatar.mjs.map +1 -0
  18. package/fesm2022/raqm-ui-badge.mjs +68 -0
  19. package/fesm2022/raqm-ui-badge.mjs.map +1 -0
  20. package/fesm2022/raqm-ui-breadcrumb.mjs +309 -0
  21. package/fesm2022/raqm-ui-breadcrumb.mjs.map +1 -0
  22. package/fesm2022/raqm-ui-button-group.mjs +138 -0
  23. package/fesm2022/raqm-ui-button-group.mjs.map +1 -0
  24. package/fesm2022/raqm-ui-button.mjs +295 -0
  25. package/fesm2022/raqm-ui-button.mjs.map +1 -0
  26. package/fesm2022/raqm-ui-calendar.mjs +1394 -0
  27. package/fesm2022/raqm-ui-calendar.mjs.map +1 -0
  28. package/fesm2022/raqm-ui-card.mjs +331 -0
  29. package/fesm2022/raqm-ui-card.mjs.map +1 -0
  30. package/fesm2022/raqm-ui-carousel.mjs +410 -0
  31. package/fesm2022/raqm-ui-carousel.mjs.map +1 -0
  32. package/fesm2022/raqm-ui-checkbox.mjs +86 -0
  33. package/fesm2022/raqm-ui-checkbox.mjs.map +1 -0
  34. package/fesm2022/raqm-ui-collapsible.mjs +266 -0
  35. package/fesm2022/raqm-ui-collapsible.mjs.map +1 -0
  36. package/fesm2022/raqm-ui-combobox.mjs +1584 -0
  37. package/fesm2022/raqm-ui-combobox.mjs.map +1 -0
  38. package/fesm2022/raqm-ui-command.mjs +1210 -0
  39. package/fesm2022/raqm-ui-command.mjs.map +1 -0
  40. package/fesm2022/raqm-ui-context-menu.mjs +723 -0
  41. package/fesm2022/raqm-ui-context-menu.mjs.map +1 -0
  42. package/fesm2022/raqm-ui-dialog.mjs +1214 -0
  43. package/fesm2022/raqm-ui-dialog.mjs.map +1 -0
  44. package/fesm2022/raqm-ui-drawer.mjs +687 -0
  45. package/fesm2022/raqm-ui-drawer.mjs.map +1 -0
  46. package/fesm2022/raqm-ui-dropdown-menu.mjs +1168 -0
  47. package/fesm2022/raqm-ui-dropdown-menu.mjs.map +1 -0
  48. package/fesm2022/raqm-ui-empty.mjs +272 -0
  49. package/fesm2022/raqm-ui-empty.mjs.map +1 -0
  50. package/fesm2022/raqm-ui-field.mjs +517 -0
  51. package/fesm2022/raqm-ui-field.mjs.map +1 -0
  52. package/fesm2022/raqm-ui-hover-card.mjs +828 -0
  53. package/fesm2022/raqm-ui-hover-card.mjs.map +1 -0
  54. package/fesm2022/raqm-ui-input-group.mjs +270 -0
  55. package/fesm2022/raqm-ui-input-group.mjs.map +1 -0
  56. package/fesm2022/raqm-ui-input-otp.mjs +788 -0
  57. package/fesm2022/raqm-ui-input-otp.mjs.map +1 -0
  58. package/fesm2022/raqm-ui-input.mjs +73 -0
  59. package/fesm2022/raqm-ui-input.mjs.map +1 -0
  60. package/fesm2022/raqm-ui-item.mjs +495 -0
  61. package/fesm2022/raqm-ui-item.mjs.map +1 -0
  62. package/fesm2022/raqm-ui-kbd.mjs +80 -0
  63. package/fesm2022/raqm-ui-kbd.mjs.map +1 -0
  64. package/fesm2022/raqm-ui-label.mjs +44 -0
  65. package/fesm2022/raqm-ui-label.mjs.map +1 -0
  66. package/fesm2022/raqm-ui-menubar.mjs +536 -0
  67. package/fesm2022/raqm-ui-menubar.mjs.map +1 -0
  68. package/fesm2022/raqm-ui-native-select.mjs +131 -0
  69. package/fesm2022/raqm-ui-native-select.mjs.map +1 -0
  70. package/fesm2022/raqm-ui-navigation-menu.mjs +1399 -0
  71. package/fesm2022/raqm-ui-navigation-menu.mjs.map +1 -0
  72. package/fesm2022/raqm-ui-overlay-internal.mjs +185 -0
  73. package/fesm2022/raqm-ui-overlay-internal.mjs.map +1 -0
  74. package/fesm2022/raqm-ui-pagination.mjs +440 -0
  75. package/fesm2022/raqm-ui-pagination.mjs.map +1 -0
  76. package/fesm2022/raqm-ui-popover.mjs +1495 -0
  77. package/fesm2022/raqm-ui-popover.mjs.map +1 -0
  78. package/fesm2022/raqm-ui-progress.mjs +369 -0
  79. package/fesm2022/raqm-ui-progress.mjs.map +1 -0
  80. package/fesm2022/raqm-ui-questionnaire.mjs +1005 -0
  81. package/fesm2022/raqm-ui-questionnaire.mjs.map +1 -0
  82. package/fesm2022/raqm-ui-radio-group.mjs +151 -0
  83. package/fesm2022/raqm-ui-radio-group.mjs.map +1 -0
  84. package/fesm2022/raqm-ui-resizable.mjs +439 -0
  85. package/fesm2022/raqm-ui-resizable.mjs.map +1 -0
  86. package/fesm2022/raqm-ui-scroll-area.mjs +510 -0
  87. package/fesm2022/raqm-ui-scroll-area.mjs.map +1 -0
  88. package/fesm2022/raqm-ui-select.mjs +1073 -0
  89. package/fesm2022/raqm-ui-select.mjs.map +1 -0
  90. package/fesm2022/raqm-ui-separator.mjs +103 -0
  91. package/fesm2022/raqm-ui-separator.mjs.map +1 -0
  92. package/fesm2022/raqm-ui-sheet.mjs +411 -0
  93. package/fesm2022/raqm-ui-sheet.mjs.map +1 -0
  94. package/fesm2022/raqm-ui-sidebar.mjs +1784 -0
  95. package/fesm2022/raqm-ui-sidebar.mjs.map +1 -0
  96. package/fesm2022/raqm-ui-skeleton.mjs +50 -0
  97. package/fesm2022/raqm-ui-skeleton.mjs.map +1 -0
  98. package/fesm2022/raqm-ui-slider.mjs +609 -0
  99. package/fesm2022/raqm-ui-slider.mjs.map +1 -0
  100. package/fesm2022/raqm-ui-spinner.mjs +137 -0
  101. package/fesm2022/raqm-ui-spinner.mjs.map +1 -0
  102. package/fesm2022/raqm-ui-switch.mjs +109 -0
  103. package/fesm2022/raqm-ui-switch.mjs.map +1 -0
  104. package/fesm2022/raqm-ui-table.mjs +271 -0
  105. package/fesm2022/raqm-ui-table.mjs.map +1 -0
  106. package/fesm2022/raqm-ui-tabs.mjs +536 -0
  107. package/fesm2022/raqm-ui-tabs.mjs.map +1 -0
  108. package/fesm2022/raqm-ui-textarea.mjs +37 -0
  109. package/fesm2022/raqm-ui-textarea.mjs.map +1 -0
  110. package/fesm2022/raqm-ui-toast.mjs +918 -0
  111. package/fesm2022/raqm-ui-toast.mjs.map +1 -0
  112. package/fesm2022/raqm-ui-toggle-group.mjs +462 -0
  113. package/fesm2022/raqm-ui-toggle-group.mjs.map +1 -0
  114. package/fesm2022/raqm-ui-toggle.mjs +158 -0
  115. package/fesm2022/raqm-ui-toggle.mjs.map +1 -0
  116. package/fesm2022/raqm-ui-tooltip.mjs +1226 -0
  117. package/fesm2022/raqm-ui-tooltip.mjs.map +1 -0
  118. package/fesm2022/raqm-ui.mjs +50 -0
  119. package/input-otp/README.md +12 -0
  120. package/package.json +275 -3
  121. package/styles/theme.css +4324 -0
  122. package/types/raqm-ui-accordion.d.ts +124 -0
  123. package/types/raqm-ui-alert-dialog.d.ts +81 -0
  124. package/types/raqm-ui-alert.d.ts +29 -0
  125. package/types/raqm-ui-aspect-ratio.d.ts +13 -0
  126. package/types/raqm-ui-attachment.d.ts +72 -0
  127. package/types/raqm-ui-avatar.d.ts +67 -0
  128. package/types/raqm-ui-badge.d.ts +20 -0
  129. package/types/raqm-ui-breadcrumb.d.ts +35 -0
  130. package/types/raqm-ui-button-group.d.ts +27 -0
  131. package/types/raqm-ui-button.d.ts +80 -0
  132. package/types/raqm-ui-calendar.d.ts +359 -0
  133. package/types/raqm-ui-card.d.ts +34 -0
  134. package/types/raqm-ui-carousel.d.ts +81 -0
  135. package/types/raqm-ui-checkbox.d.ts +24 -0
  136. package/types/raqm-ui-collapsible.d.ts +72 -0
  137. package/types/raqm-ui-combobox.d.ts +405 -0
  138. package/types/raqm-ui-command.d.ts +256 -0
  139. package/types/raqm-ui-context-menu.d.ts +196 -0
  140. package/types/raqm-ui-dialog.d.ts +232 -0
  141. package/types/raqm-ui-drawer.d.ts +121 -0
  142. package/types/raqm-ui-dropdown-menu.d.ts +319 -0
  143. package/types/raqm-ui-empty.d.ts +35 -0
  144. package/types/raqm-ui-field.d.ts +88 -0
  145. package/types/raqm-ui-hover-card.d.ts +139 -0
  146. package/types/raqm-ui-input-group.d.ts +45 -0
  147. package/types/raqm-ui-input-otp.d.ts +197 -0
  148. package/types/raqm-ui-input.d.ts +16 -0
  149. package/types/raqm-ui-item.d.ts +71 -0
  150. package/types/raqm-ui-kbd.d.ts +12 -0
  151. package/types/raqm-ui-label.d.ts +6 -0
  152. package/types/raqm-ui-menubar.d.ts +159 -0
  153. package/types/raqm-ui-native-select.d.ts +23 -0
  154. package/types/raqm-ui-navigation-menu.d.ts +230 -0
  155. package/types/raqm-ui-overlay-internal.d.ts +5 -0
  156. package/types/raqm-ui-pagination.d.ts +84 -0
  157. package/types/raqm-ui-popover.d.ts +235 -0
  158. package/types/raqm-ui-progress.d.ts +79 -0
  159. package/types/raqm-ui-questionnaire.d.ts +217 -0
  160. package/types/raqm-ui-radio-group.d.ts +48 -0
  161. package/types/raqm-ui-resizable.d.ts +98 -0
  162. package/types/raqm-ui-scroll-area.d.ts +132 -0
  163. package/types/raqm-ui-select.d.ts +205 -0
  164. package/types/raqm-ui-separator.d.ts +21 -0
  165. package/types/raqm-ui-sheet.d.ts +79 -0
  166. package/types/raqm-ui-sidebar.d.ts +285 -0
  167. package/types/raqm-ui-skeleton.d.ts +6 -0
  168. package/types/raqm-ui-slider.d.ts +129 -0
  169. package/types/raqm-ui-spinner.d.ts +32 -0
  170. package/types/raqm-ui-switch.d.ts +32 -0
  171. package/types/raqm-ui-table.d.ts +36 -0
  172. package/types/raqm-ui-tabs.d.ts +154 -0
  173. package/types/raqm-ui-textarea.d.ts +6 -0
  174. package/types/raqm-ui-toast.d.ts +190 -0
  175. package/types/raqm-ui-toggle-group.d.ts +167 -0
  176. package/types/raqm-ui-toggle.d.ts +42 -0
  177. package/types/raqm-ui-tooltip.d.ts +207 -0
  178. package/types/raqm-ui.d.ts +50 -0
@@ -0,0 +1,536 @@
1
+ import * as i0 from "@angular/core";
2
+ import { ChangeDetectionStrategy, Component, DestroyRef, ElementRef, InjectionToken, booleanAttribute, computed, inject, input, isDevMode, model, signal } from "@angular/core";
3
+ const RAQM_TABS = new InjectionToken("RaqmTabs");
4
+ function moveTabsFocus(host, trigger, event) {
5
+ const enabled = host.enabled();
6
+ const index = enabled.indexOf(trigger);
7
+ if (index === -1) return;
8
+ let target;
9
+ switch (event.key) {
10
+ case "Home":
11
+ target = enabled[0];
12
+ break;
13
+ case "End":
14
+ target = enabled[enabled.length - 1];
15
+ break;
16
+ case "ArrowLeft":
17
+ case "ArrowRight":
18
+ if (host.vertical()) return;
19
+ target = enabled[(index + (event.key === (host.isRtl() ? "ArrowLeft" : "ArrowRight") ? 1 : -1) + enabled.length) % enabled.length];
20
+ break;
21
+ case "ArrowUp":
22
+ case "ArrowDown":
23
+ if (!host.vertical()) return;
24
+ target = enabled[(index + (event.key === "ArrowDown" ? 1 : -1) + enabled.length) % enabled.length];
25
+ break;
26
+ default: return;
27
+ }
28
+ if (target === void 0) return;
29
+ event.preventDefault();
30
+ host.setFocused(target);
31
+ target.host.focus();
32
+ }
33
+ var RaqmTabsContentComponent = class RaqmTabsContentComponent {
34
+ tabs = inject(RAQM_TABS, { optional: true });
35
+ value = input.required(...ngDevMode ? [{ debugName: "value" }] : /* istanbul ignore next */ []);
36
+ selected = computed(() => this.tabs?.isSelected(this.value()) ?? true, ...ngDevMode ? [{ debugName: "selected" }] : /* istanbul ignore next */ []);
37
+ panelId = computed(() => this.tabs?.panelIdFor(this.value()) ?? null, ...ngDevMode ? [{ debugName: "panelId" }] : /* istanbul ignore next */ []);
38
+ triggerId = computed(() => this.tabs?.triggerIdFor(this.value()) ?? null, ...ngDevMode ? [{ debugName: "triggerId" }] : /* istanbul ignore next */ []);
39
+ constructor() {
40
+ if (isDevMode() && this.tabs === null) console.error("[raqm-tabs-content] No parent <raqm-tabs> found; the panel cannot know its selected state.");
41
+ }
42
+ static ɵfac = i0.ɵɵngDeclareFactory({
43
+ minVersion: "12.0.0",
44
+ version: "22.2.2",
45
+ ngImport: i0,
46
+ type: RaqmTabsContentComponent,
47
+ deps: [],
48
+ target: i0.ɵɵFactoryTarget.Component
49
+ });
50
+ static ɵcmp = i0.ɵɵngDeclareComponent({
51
+ minVersion: "17.1.0",
52
+ version: "22.2.2",
53
+ type: RaqmTabsContentComponent,
54
+ isStandalone: true,
55
+ selector: "raqm-tabs-content",
56
+ inputs: { value: {
57
+ classPropertyName: "value",
58
+ publicName: "value",
59
+ isSignal: true,
60
+ isRequired: true,
61
+ transformFunction: null
62
+ } },
63
+ host: {
64
+ attributes: { "role": "tabpanel" },
65
+ properties: {
66
+ "attr.id": "panelId()",
67
+ "attr.aria-labelledby": "triggerId()",
68
+ "attr.tabindex": "selected() ? 0 : -1",
69
+ "attr.hidden": "selected() ? null : \"\""
70
+ },
71
+ classAttribute: "raqm-tabs-content"
72
+ },
73
+ ngImport: i0,
74
+ template: "<ng-content />",
75
+ isInline: true,
76
+ styles: [":host{display:block;flex:1 1 0%;outline:none;font-size:var(--raqm-font-size-sm);line-height:calc(var(--raqm-spacing) * 5)}:host([hidden]){display:none}\n"],
77
+ changeDetection: i0.ChangeDetectionStrategy.OnPush
78
+ });
79
+ };
80
+ i0.ɵɵngDeclareClassMetadata({
81
+ minVersion: "12.0.0",
82
+ version: "22.2.2",
83
+ ngImport: i0,
84
+ type: RaqmTabsContentComponent,
85
+ decorators: [{
86
+ type: Component,
87
+ args: [{
88
+ selector: "raqm-tabs-content",
89
+ template: "<ng-content />",
90
+ changeDetection: ChangeDetectionStrategy.OnPush,
91
+ host: {
92
+ class: "raqm-tabs-content",
93
+ role: "tabpanel",
94
+ "[attr.id]": "panelId()",
95
+ "[attr.aria-labelledby]": "triggerId()",
96
+ "[attr.tabindex]": "selected() ? 0 : -1",
97
+ "[attr.hidden]": "selected() ? null : \"\""
98
+ },
99
+ styles: [":host{display:block;flex:1 1 0%;outline:none;font-size:var(--raqm-font-size-sm);line-height:calc(var(--raqm-spacing) * 5)}:host([hidden]){display:none}\n"]
100
+ }]
101
+ }],
102
+ ctorParameters: () => [],
103
+ propDecorators: { value: [{
104
+ type: i0.Input,
105
+ args: [{
106
+ isSignal: true,
107
+ alias: "value",
108
+ required: true
109
+ }]
110
+ }] }
111
+ });
112
+ var RaqmTabsListComponent = class RaqmTabsListComponent {
113
+ tabs = inject(RAQM_TABS, { optional: true });
114
+ line = computed(() => this.tabs?.line() ?? false, ...ngDevMode ? [{ debugName: "line" }] : /* istanbul ignore next */ []);
115
+ vertical = computed(() => this.tabs?.vertical() ?? false, ...ngDevMode ? [{ debugName: "vertical" }] : /* istanbul ignore next */ []);
116
+ ariaOrientation = computed(() => this.vertical() ? "vertical" : null, ...ngDevMode ? [{ debugName: "ariaOrientation" }] : /* istanbul ignore next */ []);
117
+ constructor() {
118
+ if (isDevMode() && this.tabs === null) console.error("[raqm-tabs-list] No parent <raqm-tabs> found; the list has no tabs to own.");
119
+ }
120
+ static ɵfac = i0.ɵɵngDeclareFactory({
121
+ minVersion: "12.0.0",
122
+ version: "22.2.2",
123
+ ngImport: i0,
124
+ type: RaqmTabsListComponent,
125
+ deps: [],
126
+ target: i0.ɵɵFactoryTarget.Component
127
+ });
128
+ static ɵcmp = i0.ɵɵngDeclareComponent({
129
+ minVersion: "14.0.0",
130
+ version: "22.2.2",
131
+ type: RaqmTabsListComponent,
132
+ isStandalone: true,
133
+ selector: "raqm-tabs-list",
134
+ host: {
135
+ attributes: { "role": "tablist" },
136
+ properties: {
137
+ "attr.aria-orientation": "ariaOrientation()",
138
+ "attr.data-raqm-line": "line() ? \"\" : null",
139
+ "attr.data-raqm-vertical": "vertical() ? \"\" : null"
140
+ },
141
+ classAttribute: "raqm-tabs-list"
142
+ },
143
+ ngImport: i0,
144
+ template: "<ng-content />",
145
+ isInline: true,
146
+ styles: [":host{display:inline-flex;box-sizing:border-box;inline-size:fit-content;align-items:center;justify-content:center;color:var(--raqm-muted-foreground);border-radius:var(--raqm-radius-lg);padding:3px;block-size:calc(var(--raqm-spacing) * 8);background-color:var(--raqm-muted)}:host([data-raqm-line]){gap:calc(var(--raqm-spacing) * 1);border-radius:0;background-color:transparent}:host([data-raqm-vertical]){flex-direction:column;block-size:fit-content;inline-size:100%}\n"],
147
+ changeDetection: i0.ChangeDetectionStrategy.OnPush
148
+ });
149
+ };
150
+ i0.ɵɵngDeclareClassMetadata({
151
+ minVersion: "12.0.0",
152
+ version: "22.2.2",
153
+ ngImport: i0,
154
+ type: RaqmTabsListComponent,
155
+ decorators: [{
156
+ type: Component,
157
+ args: [{
158
+ selector: "raqm-tabs-list",
159
+ template: "<ng-content />",
160
+ changeDetection: ChangeDetectionStrategy.OnPush,
161
+ host: {
162
+ class: "raqm-tabs-list",
163
+ role: "tablist",
164
+ "[attr.aria-orientation]": "ariaOrientation()",
165
+ "[attr.data-raqm-line]": "line() ? \"\" : null",
166
+ "[attr.data-raqm-vertical]": "vertical() ? \"\" : null"
167
+ },
168
+ styles: [":host{display:inline-flex;box-sizing:border-box;inline-size:fit-content;align-items:center;justify-content:center;color:var(--raqm-muted-foreground);border-radius:var(--raqm-radius-lg);padding:3px;block-size:calc(var(--raqm-spacing) * 8);background-color:var(--raqm-muted)}:host([data-raqm-line]){gap:calc(var(--raqm-spacing) * 1);border-radius:0;background-color:transparent}:host([data-raqm-vertical]){flex-direction:column;block-size:fit-content;inline-size:100%}\n"]
169
+ }]
170
+ }],
171
+ ctorParameters: () => []
172
+ });
173
+ var RaqmTabsTriggerComponent = class RaqmTabsTriggerComponent {
174
+ host = inject(ElementRef);
175
+ authoredDisabled = this.host.nativeElement.disabled;
176
+ tabs = inject(RAQM_TABS, { optional: true });
177
+ destroyRef = inject(DestroyRef);
178
+ value = input.required(...ngDevMode ? [{ debugName: "value" }] : /* istanbul ignore next */ []);
179
+ disabled = input(false, {
180
+ ...ngDevMode ? { debugName: "disabled" } : /* istanbul ignore next */ {},
181
+ transform: booleanAttribute
182
+ });
183
+ ref = (() => {
184
+ const self = this;
185
+ return {
186
+ get value() {
187
+ return self.value();
188
+ },
189
+ disabled: this.disabled,
190
+ get host() {
191
+ return self.host.nativeElement;
192
+ }
193
+ };
194
+ })();
195
+ vertical = computed(() => this.tabs?.vertical() ?? false, ...ngDevMode ? [{ debugName: "vertical" }] : /* istanbul ignore next */ []);
196
+ disabledAttribute = computed(() => this.disabled() || this.authoredDisabled ? "" : null, ...ngDevMode ? [{ debugName: "disabledAttribute" }] : /* istanbul ignore next */ []);
197
+ selected = computed(() => this.tabs?.isSelected(this.value()) ?? false, ...ngDevMode ? [{ debugName: "selected" }] : /* istanbul ignore next */ []);
198
+ id = computed(() => this.tabs?.triggerIdOf(this.ref) ?? null, ...ngDevMode ? [{ debugName: "id" }] : /* istanbul ignore next */ []);
199
+ panelId = computed(() => this.tabs?.panelIdFor(this.value()) ?? null, ...ngDevMode ? [{ debugName: "panelId" }] : /* istanbul ignore next */ []);
200
+ tabIndex = computed(() => {
201
+ if (this.tabs === null) return 0;
202
+ return this.tabs.isTabStop(this.ref) ? 0 : -1;
203
+ }, ...ngDevMode ? [{ debugName: "tabIndex" }] : /* istanbul ignore next */ []);
204
+ constructor() {
205
+ if (isDevMode() && this.tabs === null) console.error("[raqm-tabs-trigger] No parent <raqm-tabs> found; the trigger has no selection state.");
206
+ this.destroyRef.onDestroy(() => this.tabs?.unregister(this.ref));
207
+ }
208
+ ngOnInit() {
209
+ this.tabs?.register(this.ref);
210
+ }
211
+ onClick() {
212
+ if (this.disabled()) return;
213
+ this.tabs?.select(this.value());
214
+ }
215
+ onKeydown(event) {
216
+ this.tabs?.moveFocus(this.ref, event);
217
+ }
218
+ onFocus() {
219
+ this.tabs?.noteFocus(this.ref);
220
+ }
221
+ static ɵfac = i0.ɵɵngDeclareFactory({
222
+ minVersion: "12.0.0",
223
+ version: "22.2.2",
224
+ ngImport: i0,
225
+ type: RaqmTabsTriggerComponent,
226
+ deps: [],
227
+ target: i0.ɵɵFactoryTarget.Component
228
+ });
229
+ static ɵcmp = i0.ɵɵngDeclareComponent({
230
+ minVersion: "17.1.0",
231
+ version: "22.2.2",
232
+ type: RaqmTabsTriggerComponent,
233
+ isStandalone: true,
234
+ selector: "button[raqm-tabs-trigger]",
235
+ inputs: {
236
+ value: {
237
+ classPropertyName: "value",
238
+ publicName: "value",
239
+ isSignal: true,
240
+ isRequired: true,
241
+ transformFunction: null
242
+ },
243
+ disabled: {
244
+ classPropertyName: "disabled",
245
+ publicName: "disabled",
246
+ isSignal: true,
247
+ isRequired: false,
248
+ transformFunction: null
249
+ }
250
+ },
251
+ host: {
252
+ attributes: {
253
+ "role": "tab",
254
+ "type": "button"
255
+ },
256
+ listeners: {
257
+ "click": "onClick()",
258
+ "keydown": "onKeydown($event)",
259
+ "focus": "onFocus()"
260
+ },
261
+ properties: {
262
+ "attr.aria-selected": "selected() ? \"true\" : \"false\"",
263
+ "attr.aria-controls": "panelId()",
264
+ "attr.id": "id()",
265
+ "attr.tabindex": "tabIndex()",
266
+ "attr.data-raqm-vertical": "vertical() ? \"\" : null",
267
+ "attr.data-raqm-state": "selected() ? \"active\" : \"inactive\"",
268
+ "attr.disabled": "disabledAttribute()",
269
+ "attr.data-raqm-disabled": "disabled() ? \"\" : null"
270
+ },
271
+ classAttribute: "raqm-tabs-trigger"
272
+ },
273
+ ngImport: i0,
274
+ template: "<ng-content />",
275
+ isInline: true,
276
+ styles: [":host{position:relative;display:inline-flex;flex:1 1 0%;block-size:calc(100% - 1px);align-items:center;justify-content:center;white-space:nowrap;gap:calc(var(--raqm-spacing) * 1.5);border:1px solid transparent;border-radius:var(--raqm-radius-md);padding-block:calc(var(--raqm-spacing) * .5);padding-inline:calc(var(--raqm-spacing) * 1.5);font-size:var(--raqm-font-size-sm);font-weight:var(--raqm-font-weight-medium);line-height:calc(var(--raqm-spacing) * 5);color:color-mix(in oklch,var(--raqm-foreground) 60%,transparent);background-color:transparent;outline:none;transition-property:color,background-color,border-color,box-shadow;transition-duration:var(--raqm-duration-base);transition-timing-function:var(--raqm-ease-standard)}:host([data-raqm-vertical]){inline-size:100%;justify-content:flex-start}:host(:hover){color:var(--raqm-foreground)}:host([data-raqm-state=active]){background-color:var(--raqm-background);color:var(--raqm-foreground);box-shadow:var(--raqm-shadow-sm)}:host(:focus-visible){border-color:var(--raqm-ring);box-shadow:0 0 0 var(--raqm-focus-ring-width) var(--raqm-focus-ring-color);outline:1px solid var(--raqm-ring)}:host(:disabled),:host([aria-disabled=true]){pointer-events:none;opacity:var(--raqm-disabled-opacity)}:host:after{content:\"\";position:absolute;inset-inline:0;inset-block-end:-5px;block-size:calc(var(--raqm-spacing) * .5);background-color:var(--raqm-foreground);opacity:0;transition:opacity var(--raqm-duration-base) var(--raqm-ease-standard)}:host([data-raqm-vertical]):after{inset-block:0;inset-inline:auto calc(var(--raqm-spacing) * -1);inline-size:calc(var(--raqm-spacing) * .5);block-size:auto}\n"],
277
+ changeDetection: i0.ChangeDetectionStrategy.OnPush
278
+ });
279
+ };
280
+ i0.ɵɵngDeclareClassMetadata({
281
+ minVersion: "12.0.0",
282
+ version: "22.2.2",
283
+ ngImport: i0,
284
+ type: RaqmTabsTriggerComponent,
285
+ decorators: [{
286
+ type: Component,
287
+ args: [{
288
+ selector: "button[raqm-tabs-trigger]",
289
+ template: "<ng-content />",
290
+ changeDetection: ChangeDetectionStrategy.OnPush,
291
+ host: {
292
+ class: "raqm-tabs-trigger",
293
+ role: "tab",
294
+ type: "button",
295
+ "[attr.aria-selected]": "selected() ? \"true\" : \"false\"",
296
+ "[attr.aria-controls]": "panelId()",
297
+ "[attr.id]": "id()",
298
+ "[attr.tabindex]": "tabIndex()",
299
+ "[attr.data-raqm-vertical]": "vertical() ? \"\" : null",
300
+ "[attr.data-raqm-state]": "selected() ? \"active\" : \"inactive\"",
301
+ "[attr.disabled]": "disabledAttribute()",
302
+ "[attr.data-raqm-disabled]": "disabled() ? \"\" : null",
303
+ "(click)": "onClick()",
304
+ "(keydown)": "onKeydown($event)",
305
+ "(focus)": "onFocus()"
306
+ },
307
+ styles: [":host{position:relative;display:inline-flex;flex:1 1 0%;block-size:calc(100% - 1px);align-items:center;justify-content:center;white-space:nowrap;gap:calc(var(--raqm-spacing) * 1.5);border:1px solid transparent;border-radius:var(--raqm-radius-md);padding-block:calc(var(--raqm-spacing) * .5);padding-inline:calc(var(--raqm-spacing) * 1.5);font-size:var(--raqm-font-size-sm);font-weight:var(--raqm-font-weight-medium);line-height:calc(var(--raqm-spacing) * 5);color:color-mix(in oklch,var(--raqm-foreground) 60%,transparent);background-color:transparent;outline:none;transition-property:color,background-color,border-color,box-shadow;transition-duration:var(--raqm-duration-base);transition-timing-function:var(--raqm-ease-standard)}:host([data-raqm-vertical]){inline-size:100%;justify-content:flex-start}:host(:hover){color:var(--raqm-foreground)}:host([data-raqm-state=active]){background-color:var(--raqm-background);color:var(--raqm-foreground);box-shadow:var(--raqm-shadow-sm)}:host(:focus-visible){border-color:var(--raqm-ring);box-shadow:0 0 0 var(--raqm-focus-ring-width) var(--raqm-focus-ring-color);outline:1px solid var(--raqm-ring)}:host(:disabled),:host([aria-disabled=true]){pointer-events:none;opacity:var(--raqm-disabled-opacity)}:host:after{content:\"\";position:absolute;inset-inline:0;inset-block-end:-5px;block-size:calc(var(--raqm-spacing) * .5);background-color:var(--raqm-foreground);opacity:0;transition:opacity var(--raqm-duration-base) var(--raqm-ease-standard)}:host([data-raqm-vertical]):after{inset-block:0;inset-inline:auto calc(var(--raqm-spacing) * -1);inline-size:calc(var(--raqm-spacing) * .5);block-size:auto}\n"]
308
+ }]
309
+ }],
310
+ ctorParameters: () => [],
311
+ propDecorators: {
312
+ value: [{
313
+ type: i0.Input,
314
+ args: [{
315
+ isSignal: true,
316
+ alias: "value",
317
+ required: true
318
+ }]
319
+ }],
320
+ disabled: [{
321
+ type: i0.Input,
322
+ args: [{
323
+ isSignal: true,
324
+ alias: "disabled",
325
+ required: false
326
+ }]
327
+ }]
328
+ }
329
+ });
330
+ let nextTabsId = 0;
331
+ var RaqmTabsComponent = class RaqmTabsComponent {
332
+ host = inject(ElementRef);
333
+ value = model(void 0, ...ngDevMode ? [{ debugName: "value" }] : /* istanbul ignore next */ []);
334
+ defaultValue = input(void 0, ...ngDevMode ? [{ debugName: "defaultValue" }] : /* istanbul ignore next */ []);
335
+ vertical = input(false, {
336
+ ...ngDevMode ? { debugName: "vertical" } : /* istanbul ignore next */ {},
337
+ transform: booleanAttribute
338
+ });
339
+ line = input(false, {
340
+ ...ngDevMode ? { debugName: "line" } : /* istanbul ignore next */ {},
341
+ transform: booleanAttribute
342
+ });
343
+ tabs = signal([], ...ngDevMode ? [{ debugName: "tabs" }] : /* istanbul ignore next */ []);
344
+ rootId = `raqm-tabs-${++nextTabsId}`;
345
+ sequence = 0;
346
+ enabledTabs = computed(() => this.tabs().filter((tab) => !tab.ref.disabled()).map((tab) => tab.ref), ...ngDevMode ? [{ debugName: "enabledTabs" }] : /* istanbul ignore next */ []);
347
+ focused = signal(null, ...ngDevMode ? [{ debugName: "focused" }] : /* istanbul ignore next */ []);
348
+ selectedValue = computed(() => {
349
+ const declared = this.value() ?? this.defaultValue();
350
+ if (declared !== void 0) return declared;
351
+ return this.enabledTabs()[0]?.value;
352
+ }, ...ngDevMode ? [{ debugName: "selectedValue" }] : /* istanbul ignore next */ []);
353
+ tabStop = computed(() => {
354
+ const enabled = this.enabledTabs();
355
+ const focused = this.focused();
356
+ if (focused !== null && enabled.includes(focused)) return focused;
357
+ const selected = this.selectedValue();
358
+ return enabled.find((trigger) => trigger.value === selected) ?? enabled[0] ?? null;
359
+ }, ...ngDevMode ? [{ debugName: "tabStop" }] : /* istanbul ignore next */ []);
360
+ keyboard = {
361
+ enabled: () => this.enabledTabs(),
362
+ vertical: () => this.vertical(),
363
+ isRtl: () => this.isRtl(),
364
+ setFocused: (trigger) => this.focused.set(trigger)
365
+ };
366
+ isSelected(value) {
367
+ return this.selectedValue() === value;
368
+ }
369
+ select(value) {
370
+ if (this.isSelected(value)) return;
371
+ const tab = this.tabs().find((registered) => registered.ref.value === value);
372
+ if (tab === void 0 || tab.ref.disabled()) return;
373
+ this.value.set(value);
374
+ }
375
+ register(trigger) {
376
+ if (isDevMode() && this.tabs().some((registered) => registered.ref.value === trigger.value)) console.error(`[raqm-tabs] Duplicate trigger value "${trigger.value}"; Tabs trigger values must be unique.`);
377
+ const sequence = ++this.sequence;
378
+ this.tabs.update((tabs) => [...tabs, {
379
+ ref: trigger,
380
+ triggerId: `${this.rootId}-tab-${sequence}`,
381
+ panelId: `${this.rootId}-panel-${sequence}`
382
+ }]);
383
+ }
384
+ unregister(trigger) {
385
+ this.tabs.update((tabs) => tabs.filter((registered) => registered.ref !== trigger));
386
+ }
387
+ isTabStop(trigger) {
388
+ return this.tabStop() === trigger;
389
+ }
390
+ triggerIdOf(trigger) {
391
+ return this.tabs().find((registered) => registered.ref === trigger)?.triggerId ?? null;
392
+ }
393
+ triggerIdFor(value) {
394
+ return this.tabs().find((registered) => registered.ref.value === value)?.triggerId ?? null;
395
+ }
396
+ panelIdFor(value) {
397
+ return this.tabs().find((registered) => registered.ref.value === value)?.panelId ?? null;
398
+ }
399
+ noteFocus(trigger) {
400
+ this.focused.set(trigger);
401
+ }
402
+ moveFocus(trigger, event) {
403
+ moveTabsFocus(this.keyboard, trigger, event);
404
+ }
405
+ isRtl() {
406
+ return getComputedStyle(this.host.nativeElement).direction === "rtl";
407
+ }
408
+ static ɵfac = i0.ɵɵngDeclareFactory({
409
+ minVersion: "12.0.0",
410
+ version: "22.2.2",
411
+ ngImport: i0,
412
+ type: RaqmTabsComponent,
413
+ deps: [],
414
+ target: i0.ɵɵFactoryTarget.Component
415
+ });
416
+ static ɵcmp = i0.ɵɵngDeclareComponent({
417
+ minVersion: "17.1.0",
418
+ version: "22.2.2",
419
+ type: RaqmTabsComponent,
420
+ isStandalone: true,
421
+ selector: "raqm-tabs",
422
+ inputs: {
423
+ value: {
424
+ classPropertyName: "value",
425
+ publicName: "value",
426
+ isSignal: true,
427
+ isRequired: false,
428
+ transformFunction: null
429
+ },
430
+ defaultValue: {
431
+ classPropertyName: "defaultValue",
432
+ publicName: "defaultValue",
433
+ isSignal: true,
434
+ isRequired: false,
435
+ transformFunction: null
436
+ },
437
+ vertical: {
438
+ classPropertyName: "vertical",
439
+ publicName: "vertical",
440
+ isSignal: true,
441
+ isRequired: false,
442
+ transformFunction: null
443
+ },
444
+ line: {
445
+ classPropertyName: "line",
446
+ publicName: "line",
447
+ isSignal: true,
448
+ isRequired: false,
449
+ transformFunction: null
450
+ }
451
+ },
452
+ outputs: { value: "valueChange" },
453
+ host: {
454
+ properties: { "attr.data-raqm-vertical": "vertical() ? \"\" : null" },
455
+ classAttribute: "raqm-tabs"
456
+ },
457
+ providers: [{
458
+ provide: RAQM_TABS,
459
+ useExisting: RaqmTabsComponent
460
+ }],
461
+ ngImport: i0,
462
+ template: "<ng-content />",
463
+ isInline: true,
464
+ styles: [":host{display:flex;flex-direction:column;gap:calc(var(--raqm-spacing) * 2)}:host([data-raqm-vertical]){flex-direction:row}\n"],
465
+ changeDetection: i0.ChangeDetectionStrategy.OnPush
466
+ });
467
+ };
468
+ i0.ɵɵngDeclareClassMetadata({
469
+ minVersion: "12.0.0",
470
+ version: "22.2.2",
471
+ ngImport: i0,
472
+ type: RaqmTabsComponent,
473
+ decorators: [{
474
+ type: Component,
475
+ args: [{
476
+ selector: "raqm-tabs",
477
+ template: "<ng-content />",
478
+ changeDetection: ChangeDetectionStrategy.OnPush,
479
+ host: {
480
+ class: "raqm-tabs",
481
+ "[attr.data-raqm-vertical]": "vertical() ? \"\" : null"
482
+ },
483
+ providers: [{
484
+ provide: RAQM_TABS,
485
+ useExisting: RaqmTabsComponent
486
+ }],
487
+ styles: [":host{display:flex;flex-direction:column;gap:calc(var(--raqm-spacing) * 2)}:host([data-raqm-vertical]){flex-direction:row}\n"]
488
+ }]
489
+ }],
490
+ propDecorators: {
491
+ value: [{
492
+ type: i0.Input,
493
+ args: [{
494
+ isSignal: true,
495
+ alias: "value",
496
+ required: false
497
+ }]
498
+ }, {
499
+ type: i0.Output,
500
+ args: ["valueChange"]
501
+ }],
502
+ defaultValue: [{
503
+ type: i0.Input,
504
+ args: [{
505
+ isSignal: true,
506
+ alias: "defaultValue",
507
+ required: false
508
+ }]
509
+ }],
510
+ vertical: [{
511
+ type: i0.Input,
512
+ args: [{
513
+ isSignal: true,
514
+ alias: "vertical",
515
+ required: false
516
+ }]
517
+ }],
518
+ line: [{
519
+ type: i0.Input,
520
+ args: [{
521
+ isSignal: true,
522
+ alias: "line",
523
+ required: false
524
+ }]
525
+ }]
526
+ }
527
+ });
528
+ const RaqmTabs = [
529
+ RaqmTabsComponent,
530
+ RaqmTabsListComponent,
531
+ RaqmTabsTriggerComponent,
532
+ RaqmTabsContentComponent
533
+ ];
534
+ export { RaqmTabs, RaqmTabsComponent, RaqmTabsContentComponent, RaqmTabsListComponent, RaqmTabsTriggerComponent };
535
+
536
+ //# sourceMappingURL=raqm-ui-tabs.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"raqm-ui-tabs.mjs","names":[],"sources":["../../../projects/ui/tabs/tabs-context.ts","../../../projects/ui/tabs/tabs-keyboard.ts","../../../projects/ui/tabs/tabs-content.component.ts","../../../projects/ui/tabs/tabs-list.component.ts","../../../projects/ui/tabs/tabs-trigger.component.ts","../../../projects/ui/tabs/tabs.ts","../../../projects/ui/tabs/public-api.ts"],"sourcesContent":["// Tabs contract: the trigger reference the root registers, the root context every part reads\r\n// and the token that publishes it.\r\n\r\nimport { InjectionToken, Signal } from '@angular/core';\r\n\r\nexport interface RaqmTabsTriggerRef {\r\n /** Unique, non-empty trigger value used by the root's selection contract. */\r\n readonly value: string;\r\n /** Disabled triggers are skipped by the tab stop and arrows. */\r\n readonly disabled: Signal<boolean>;\r\n /** The trigger's native `<button>`, used only to move focus. */\r\n readonly host: HTMLElement;\r\n}\r\n\r\n/** Root contract published under {@link RAQM_TABS}; the dedicated token avoids a runtime module cycle. */\r\nexport interface RaqmTabsContext {\r\n /** Used for `aria-orientation` and arrow-key mapping. */\r\n readonly vertical: Signal<boolean>;\r\n readonly line: Signal<boolean>;\r\n /** Bound model, else seed, else the first enabled trigger. */\r\n readonly selectedValue: Signal<string | undefined>;\r\n isSelected(value: string): boolean;\r\n /** Missing, disabled or already-selected values are a no-op. */\r\n select(value: string): void;\r\n register(trigger: RaqmTabsTriggerRef): void;\r\n /** Never changes the selection. */\r\n unregister(trigger: RaqmTabsTriggerRef): void;\r\n isTabStop(trigger: RaqmTabsTriggerRef): boolean;\r\n /** Records the roving tab stop without changing the selection. */\r\n noteFocus(trigger: RaqmTabsTriggerRef): void;\r\n /** Moves focus without selecting (manual activation). */\r\n moveFocus(trigger: RaqmTabsTriggerRef, event: KeyboardEvent): void;\r\n triggerIdOf(trigger: RaqmTabsTriggerRef): string | null;\r\n triggerIdFor(value: string): string | null;\r\n panelIdFor(value: string): string | null;\r\n}\r\n\r\n/** Root token; injected optionally so a misplaced part renders and only logs a dev-mode error. */\r\nexport const RAQM_TABS = new InjectionToken<RaqmTabsContext>('RaqmTabs');\r\n","// Tabs keyboard: the arrow/Home/End walk over the enabled triggers, with the horizontal axis\r\n// following the resolved direction.\r\n\r\nimport { RaqmTabsTriggerRef } from './tabs-context';\r\n\r\nexport interface RaqmTabsKeyboardHost {\r\n /** Enabled triggers in DOM order. */\r\n enabled(): readonly RaqmTabsTriggerRef[];\r\n vertical(): boolean;\r\n /** The root's resolved reading direction, read at keydown time. */\r\n isRtl(): boolean;\r\n /** Records the new roving tab stop without touching the selection. */\r\n setFocused(trigger: RaqmTabsTriggerRef): void;\r\n}\r\n\r\n/** Moves focus among enabled triggers with wrapping; Left/Right follow the resolved direction (RTL reverses them). */\r\nexport function moveTabsFocus(\r\n host: RaqmTabsKeyboardHost,\r\n trigger: RaqmTabsTriggerRef,\r\n event: KeyboardEvent,\r\n): void {\r\n const enabled = host.enabled();\r\n const index = enabled.indexOf(trigger);\r\n if (index === -1) {\r\n return;\r\n }\r\n\r\n let target: RaqmTabsTriggerRef | undefined;\r\n switch (event.key) {\r\n case 'Home':\r\n target = enabled[0];\r\n break;\r\n case 'End':\r\n target = enabled[enabled.length - 1];\r\n break;\r\n case 'ArrowLeft':\r\n case 'ArrowRight': {\r\n if (host.vertical()) {\r\n return;\r\n }\r\n const forward = event.key === (host.isRtl() ? 'ArrowLeft' : 'ArrowRight');\r\n target = enabled[(index + (forward ? 1 : -1) + enabled.length) % enabled.length];\r\n break;\r\n }\r\n case 'ArrowUp':\r\n case 'ArrowDown': {\r\n if (!host.vertical()) {\r\n return;\r\n }\r\n const forward = event.key === 'ArrowDown';\r\n target = enabled[(index + (forward ? 1 : -1) + enabled.length) % enabled.length];\r\n break;\r\n }\r\n default:\r\n return;\r\n }\r\n\r\n if (target === undefined) {\r\n return;\r\n }\r\n event.preventDefault();\r\n host.setFocused(target);\r\n target.host.focus();\r\n}\r\n","// Tabs panel: `role=\"tabpanel\"` paired by the ids the root minted, mounted but hidden when\r\n// unselected.\r\n\r\nimport {\r\n ChangeDetectionStrategy,\r\n Component,\r\n computed,\r\n inject,\r\n input,\r\n isDevMode,\r\n} from '@angular/core';\r\n\r\nimport { RAQM_TABS, RaqmTabsContext } from './tabs-context';\r\n\r\n/** Tabs panel; `role=\"tabpanel\"` paired by owned ids. Panels stay mounted, `hidden` when unselected, and only the visible panel is a tab stop. */\r\n@Component({\r\n selector: 'raqm-tabs-content',\r\n template: '<ng-content />',\r\n styles: [\r\n `\r\n :host {\r\n display: block;\r\n flex: 1 1 0%;\r\n outline: none;\r\n font-size: var(--raqm-font-size-sm);\r\n line-height: calc(var(--raqm-spacing) * 5);\r\n }\r\n\r\n :host([hidden]) {\r\n display: none;\r\n }\r\n `,\r\n ],\r\n changeDetection: ChangeDetectionStrategy.OnPush,\r\n host: {\r\n class: 'raqm-tabs-content',\r\n role: 'tabpanel',\r\n '[attr.id]': 'panelId()',\r\n '[attr.aria-labelledby]': 'triggerId()',\r\n '[attr.tabindex]': 'selected() ? 0 : -1',\r\n // Inactive panels stay mounted but are hidden, so consumer state survives.\r\n '[attr.hidden]': 'selected() ? null : \"\"',\r\n },\r\n})\r\nexport class RaqmTabsContentComponent {\r\n private readonly tabs = inject<RaqmTabsContext | null>(RAQM_TABS, { optional: true });\r\n\r\n readonly value = input.required<string>();\r\n\r\n protected readonly selected = computed(() => this.tabs?.isSelected(this.value()) ?? true);\r\n\r\n protected readonly panelId = computed(() => this.tabs?.panelIdFor(this.value()) ?? null);\r\n\r\n protected readonly triggerId = computed(() => this.tabs?.triggerIdFor(this.value()) ?? null);\r\n\r\n constructor() {\r\n if (isDevMode() && this.tabs === null) {\r\n console.error(\r\n '[raqm-tabs-content] No parent <raqm-tabs> found; the panel cannot know its selected state.',\r\n );\r\n }\r\n }\r\n}\r\n","// Tabs list: the real `tablist` role, with appearance mirrored from the root context.\r\n\r\nimport { ChangeDetectionStrategy, Component, computed, inject, isDevMode } from '@angular/core';\r\n\r\nimport { RAQM_TABS, RaqmTabsContext } from './tabs-context';\r\n\r\n/** Tabs list; the real `role=\"tablist\"`, and appearance comes from the root context so list and triggers cannot drift. */\r\n@Component({\r\n selector: 'raqm-tabs-list',\r\n template: '<ng-content />',\r\n styleUrl: './tabs-list.component.scss',\r\n changeDetection: ChangeDetectionStrategy.OnPush,\r\n host: {\r\n class: 'raqm-tabs-list',\r\n // The real tablist role sits on the list, never on the root.\r\n role: 'tablist',\r\n // Set only for a vertical list, so assistive technology keeps the ARIA default.\r\n '[attr.aria-orientation]': 'ariaOrientation()',\r\n '[attr.data-raqm-line]': 'line() ? \"\" : null',\r\n '[attr.data-raqm-vertical]': 'vertical() ? \"\" : null',\r\n },\r\n})\r\nexport class RaqmTabsListComponent {\r\n private readonly tabs = inject<RaqmTabsContext | null>(RAQM_TABS, { optional: true });\r\n\r\n protected readonly line = computed(() => this.tabs?.line() ?? false);\r\n\r\n protected readonly vertical = computed(() => this.tabs?.vertical() ?? false);\r\n\r\n protected readonly ariaOrientation = computed(() => (this.vertical() ? 'vertical' : null));\r\n\r\n constructor() {\r\n if (isDevMode() && this.tabs === null) {\r\n console.error('[raqm-tabs-list] No parent <raqm-tabs> found; the list has no tabs to own.');\r\n }\r\n }\r\n}\r\n","// Tabs trigger: ARIA, owned ids and the roving tab stop all come from the root.\r\n\r\nimport {\r\n ChangeDetectionStrategy,\r\n Component,\r\n DestroyRef,\r\n ElementRef,\r\n OnInit,\r\n booleanAttribute,\r\n computed,\r\n inject,\r\n input,\r\n isDevMode,\r\n} from '@angular/core';\r\n\r\nimport { RAQM_TABS, RaqmTabsContext, RaqmTabsTriggerRef } from './tabs-context';\r\n\r\n/** Tabs trigger on the native `<button>`; ARIA, owned id and roving `tabindex` come from the root, and it registers from `ngOnInit`. */\r\n@Component({\r\n selector: 'button[raqm-tabs-trigger]',\r\n template: '<ng-content />',\r\n styleUrl: './tabs-trigger.component.scss',\r\n changeDetection: ChangeDetectionStrategy.OnPush,\r\n host: {\r\n class: 'raqm-tabs-trigger',\r\n role: 'tab',\r\n // A tab never submits a form.\r\n type: 'button',\r\n '[attr.aria-selected]': 'selected() ? \"true\" : \"false\"',\r\n '[attr.aria-controls]': 'panelId()',\r\n '[attr.id]': 'id()',\r\n // Roving tabindex: only the root's single tab stop gets `0`.\r\n '[attr.tabindex]': 'tabIndex()',\r\n '[attr.data-raqm-vertical]': 'vertical() ? \"\" : null',\r\n '[attr.data-raqm-state]': 'selected() ? \"active\" : \"inactive\"',\r\n // Native state OR-ed with an app-authored `disabled`.\r\n '[attr.disabled]': 'disabledAttribute()',\r\n '[attr.data-raqm-disabled]': 'disabled() ? \"\" : null',\r\n '(click)': 'onClick()',\r\n // Arrow/Home/End move focus only (manual activation).\r\n '(keydown)': 'onKeydown($event)',\r\n // Focusing a tab makes it the roving tab stop.\r\n '(focus)': 'onFocus()',\r\n },\r\n})\r\nexport class RaqmTabsTriggerComponent implements OnInit {\r\n private readonly host = inject(ElementRef<HTMLButtonElement>);\r\n\r\n // Read at creation: the tab can add its own disabled state but never clears this one.\r\n private readonly authoredDisabled = this.host.nativeElement.disabled;\r\n\r\n private readonly tabs = inject<RaqmTabsContext | null>(RAQM_TABS, { optional: true });\r\n\r\n private readonly destroyRef = inject(DestroyRef);\r\n\r\n readonly value = input.required<string>();\r\n\r\n readonly disabled = input(false, { transform: booleanAttribute });\r\n\r\n // Reads the live input, so registration always sees the bound value.\r\n private readonly ref: RaqmTabsTriggerRef = (() => {\r\n const self = this;\r\n return {\r\n get value(): string {\r\n return self.value();\r\n },\r\n disabled: this.disabled,\r\n get host(): HTMLElement {\r\n return self.host.nativeElement;\r\n },\r\n };\r\n })();\r\n\r\n protected readonly vertical = computed(() => this.tabs?.vertical() ?? false);\r\n\r\n protected readonly disabledAttribute = computed(() =>\r\n this.disabled() || this.authoredDisabled ? '' : null,\r\n );\r\n\r\n protected readonly selected = computed(() => this.tabs?.isSelected(this.value()) ?? false);\r\n\r\n protected readonly id = computed(() => this.tabs?.triggerIdOf(this.ref) ?? null);\r\n\r\n protected readonly panelId = computed(() => this.tabs?.panelIdFor(this.value()) ?? null);\r\n\r\n protected readonly tabIndex = computed(() => {\r\n if (this.tabs === null) {\r\n return 0;\r\n }\r\n return this.tabs.isTabStop(this.ref) ? 0 : -1;\r\n });\r\n\r\n constructor() {\r\n if (isDevMode() && this.tabs === null) {\r\n console.error(\r\n '[raqm-tabs-trigger] No parent <raqm-tabs> found; the trigger has no selection state.',\r\n );\r\n }\r\n\r\n // Registration deliberately lives in `ngOnInit`, never here.\r\n this.destroyRef.onDestroy(() => this.tabs?.unregister(this.ref));\r\n }\r\n\r\n ngOnInit(): void {\r\n this.tabs?.register(this.ref);\r\n }\r\n\r\n protected onClick(): void {\r\n if (this.disabled()) {\r\n return;\r\n }\r\n this.tabs?.select(this.value());\r\n }\r\n\r\n protected onKeydown(event: KeyboardEvent): void {\r\n this.tabs?.moveFocus(this.ref, event);\r\n }\r\n\r\n protected onFocus(): void {\r\n this.tabs?.noteFocus(this.ref);\r\n }\r\n}\r\n","// Tabs root: selection, trigger registration, id minting and the single roving tab stop; the\r\n// list, trigger and panel parts live in their own files and re-export through this module.\r\n\r\nimport {\r\n ChangeDetectionStrategy,\r\n Component,\r\n ElementRef,\r\n booleanAttribute,\r\n computed,\r\n inject,\r\n input,\r\n isDevMode,\r\n model,\r\n signal,\r\n} from '@angular/core';\r\n\r\nimport { RAQM_TABS, RaqmTabsContext, RaqmTabsTriggerRef } from './tabs-context';\r\nimport { moveTabsFocus, RaqmTabsKeyboardHost } from './tabs-keyboard';\r\n\r\nexport { RaqmTabsContentComponent } from './tabs-content.component';\r\nexport { RaqmTabsListComponent } from './tabs-list.component';\r\nexport { RaqmTabsTriggerComponent } from './tabs-trigger.component';\r\nexport { RAQM_TABS } from './tabs-context';\r\nexport type { RaqmTabsContext, RaqmTabsTriggerRef } from './tabs-context';\r\n\r\nlet nextTabsId = 0;\r\n\r\n// One registered trigger with the two element ids the root minted for it.\r\ninterface RegisteredTab {\r\n readonly ref: RaqmTabsTriggerRef;\r\n readonly triggerId: string;\r\n readonly panelId: string;\r\n}\r\n\r\n/** Tabs root; carries no ARIA role (`tablist` belongs on the list) and uses roving tabindex with manual activation: arrows move focus, Space/Enter selects. */\r\n@Component({\r\n selector: 'raqm-tabs',\r\n template: '<ng-content />',\r\n styles: [\r\n `\r\n :host {\r\n display: flex;\r\n flex-direction: column;\r\n gap: calc(var(--raqm-spacing) * 2);\r\n }\r\n\r\n :host([data-raqm-vertical]) {\r\n flex-direction: row;\r\n }\r\n `,\r\n ],\r\n changeDetection: ChangeDetectionStrategy.OnPush,\r\n host: {\r\n class: 'raqm-tabs',\r\n // Boolean axis for the row/column rules and the parts' mirrors.\r\n '[attr.data-raqm-vertical]': 'vertical() ? \"\" : null',\r\n },\r\n providers: [{ provide: RAQM_TABS, useExisting: RaqmTabsComponent }],\r\n})\r\nexport class RaqmTabsComponent implements RaqmTabsContext {\r\n // Resolves the nearest writing direction for horizontal arrow keys.\r\n private readonly host = inject(ElementRef<HTMLElement>);\r\n\r\n // `undefined` means nothing explicitly selected.\r\n readonly value = model<string | undefined>(undefined);\r\n\r\n readonly defaultValue = input<string | undefined>(undefined);\r\n\r\n readonly vertical = input(false, { transform: booleanAttribute });\r\n\r\n readonly line = input(false, { transform: booleanAttribute });\r\n\r\n // A signal so the tab stop and arrows follow dynamic parts.\r\n private readonly tabs = signal<readonly RegisteredTab[]>([]);\r\n\r\n private readonly rootId = `raqm-tabs-${++nextTabsId}`;\r\n private sequence = 0;\r\n\r\n private readonly enabledTabs = computed<readonly RaqmTabsTriggerRef[]>(() =>\r\n this.tabs()\r\n .filter((tab) => !tab.ref.disabled())\r\n .map((tab) => tab.ref),\r\n );\r\n\r\n private readonly focused = signal<RaqmTabsTriggerRef | null>(null);\r\n\r\n // Bound model, then seed, then the first enabled trigger; a declared value is never replaced by the fallback.\r\n readonly selectedValue = computed<string | undefined>(() => {\r\n const declared = this.value() ?? this.defaultValue();\r\n if (declared !== undefined) {\r\n return declared;\r\n }\r\n return this.enabledTabs()[0]?.value;\r\n });\r\n\r\n // The single roving tab stop: focused, else selected, else first enabled; `null` when none.\r\n private readonly tabStop = computed<RaqmTabsTriggerRef | null>(() => {\r\n const enabled = this.enabledTabs();\r\n const focused = this.focused();\r\n if (focused !== null && enabled.includes(focused)) {\r\n return focused;\r\n }\r\n const selected = this.selectedValue();\r\n return enabled.find((trigger) => trigger.value === selected) ?? enabled[0] ?? null;\r\n });\r\n\r\n private readonly keyboard: RaqmTabsKeyboardHost = {\r\n enabled: () => this.enabledTabs(),\r\n vertical: () => this.vertical(),\r\n isRtl: () => this.isRtl(),\r\n setFocused: (trigger) => this.focused.set(trigger),\r\n };\r\n\r\n isSelected(value: string): boolean {\r\n return this.selectedValue() === value;\r\n }\r\n\r\n select(value: string): void {\r\n if (this.isSelected(value)) {\r\n return;\r\n }\r\n const tab = this.tabs().find((registered) => registered.ref.value === value);\r\n if (tab === undefined || tab.ref.disabled()) {\r\n return;\r\n }\r\n this.value.set(value);\r\n }\r\n\r\n /** Registers a trigger in DOM order, minting its ids; called from `ngOnInit` so `value` is bound. */\r\n register(trigger: RaqmTabsTriggerRef): void {\r\n if (isDevMode() && this.tabs().some((registered) => registered.ref.value === trigger.value)) {\r\n console.error(\r\n `[raqm-tabs] Duplicate trigger value \"${trigger.value}\"; Tabs trigger values must be unique.`,\r\n );\r\n }\r\n const sequence = ++this.sequence;\r\n this.tabs.update((tabs) => [\r\n ...tabs,\r\n {\r\n ref: trigger,\r\n triggerId: `${this.rootId}-tab-${sequence}`,\r\n panelId: `${this.rootId}-panel-${sequence}`,\r\n },\r\n ]);\r\n }\r\n\r\n /** Unregisters a trigger on destroy; survives keep their minted ids. */\r\n unregister(trigger: RaqmTabsTriggerRef): void {\r\n this.tabs.update((tabs) => tabs.filter((registered) => registered.ref !== trigger));\r\n }\r\n\r\n /** Whether the trigger is the set's single roving tab stop. */\r\n isTabStop(trigger: RaqmTabsTriggerRef): boolean {\r\n return this.tabStop() === trigger;\r\n }\r\n\r\n triggerIdOf(trigger: RaqmTabsTriggerRef): string | null {\r\n return this.tabs().find((registered) => registered.ref === trigger)?.triggerId ?? null;\r\n }\r\n\r\n triggerIdFor(value: string): string | null {\r\n return this.tabs().find((registered) => registered.ref.value === value)?.triggerId ?? null;\r\n }\r\n\r\n panelIdFor(value: string): string | null {\r\n return this.tabs().find((registered) => registered.ref.value === value)?.panelId ?? null;\r\n }\r\n\r\n /** Records the last focused trigger as the roving tab stop; manual activation, so no selection change. */\r\n noteFocus(trigger: RaqmTabsTriggerRef): void {\r\n this.focused.set(trigger);\r\n }\r\n\r\n /** Moves focus among enabled triggers with wrapping; Left/Right follow the resolved direction (RTL reverses them). */\r\n moveFocus(trigger: RaqmTabsTriggerRef, event: KeyboardEvent): void {\r\n moveTabsFocus(this.keyboard, trigger, event);\r\n }\r\n\r\n // Follows the actual reading direction without a document query or global listener.\r\n private isRtl(): boolean {\r\n return getComputedStyle(this.host.nativeElement).direction === 'rtl';\r\n }\r\n}\r\n","// Public API for the `@raqm/ui/tabs` secondary entry point; also re-exported by the root.\r\nimport {\r\n RaqmTabsComponent,\r\n RaqmTabsContentComponent,\r\n RaqmTabsListComponent,\r\n RaqmTabsTriggerComponent,\r\n} from './tabs';\r\n\r\nexport {\r\n RaqmTabsComponent,\r\n RaqmTabsContentComponent,\r\n RaqmTabsListComponent,\r\n RaqmTabsTriggerComponent,\r\n};\r\n\r\n// A nested readonly array is accepted by Angular `imports`, so the whole family imports as one entry.\r\nexport const RaqmTabs = [\r\n RaqmTabsComponent,\r\n RaqmTabsListComponent,\r\n RaqmTabsTriggerComponent,\r\n RaqmTabsContentComponent,\r\n] as const;\r\n"],"mappings":";;AAsCA,MAAa,YAAY,IAAI,eAAgC,UAAU;ACtBvE,SAAgB,cACd,MACA,SACA,OAAoB;CAEpB,MAAM,UAAU,KAAK,QAAO;CAC5B,MAAM,QAAQ,QAAQ,QAAQ,OAAO;CACrC,IAAI,UAAU,IACZ;CAGF,IAAI;CACJ,QAAQ,MAAM,KAAd;EACE,KAAK;GACH,SAAS,QAAQ;GACjB;EACF,KAAK;GACH,SAAS,QAAQ,QAAQ,SAAS;GAClC;EACF,KAAK;EACL,KAAK;GACH,IAAI,KAAK,SAAQ,GACf;GAGF,SAAS,SAAS,SADF,MAAM,SAAS,KAAK,MAA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AAgB,iBAcT,wBAAwB;GAAM,MACzC;IACJ,OAAO;IAEP,6BAA6B;GAC9B;GAAA,WACU,CAAC;IAAE,SAAS;IAAW,aAAW;GAAmB,CAAE;GAAC,QAAA,CAAA,8HAAA;EAAA,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;ACzCrE,MAAa,WAAW;CACtB;CACA;CACA;CACA;AACQ"}
@@ -0,0 +1,37 @@
1
+ import * as i0 from "@angular/core";
2
+ import { Directive } from "@angular/core";
3
+ var RaqmTextarea = class RaqmTextarea {
4
+ static ɵfac = i0.ɵɵngDeclareFactory({
5
+ minVersion: "12.0.0",
6
+ version: "22.2.2",
7
+ ngImport: i0,
8
+ type: RaqmTextarea,
9
+ deps: [],
10
+ target: i0.ɵɵFactoryTarget.Directive
11
+ });
12
+ static ɵdir = i0.ɵɵngDeclareDirective({
13
+ minVersion: "14.0.0",
14
+ version: "22.2.2",
15
+ type: RaqmTextarea,
16
+ isStandalone: true,
17
+ selector: "textarea[raqm-textarea]",
18
+ host: { classAttribute: "raqm-textarea" },
19
+ ngImport: i0
20
+ });
21
+ };
22
+ i0.ɵɵngDeclareClassMetadata({
23
+ minVersion: "12.0.0",
24
+ version: "22.2.2",
25
+ ngImport: i0,
26
+ type: RaqmTextarea,
27
+ decorators: [{
28
+ type: Directive,
29
+ args: [{
30
+ selector: "textarea[raqm-textarea]",
31
+ host: { class: "raqm-textarea" }
32
+ }]
33
+ }]
34
+ });
35
+ export { RaqmTextarea };
36
+
37
+ //# sourceMappingURL=raqm-ui-textarea.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"raqm-ui-textarea.mjs","names":[],"sources":["../../../projects/ui/textarea/textarea.ts"],"sourcesContent":["import { Directive } from '@angular/core';\r\n\r\n/** Native `<textarea>` host; value, validation and IME stay browser- and Forms-owned. */\r\n@Directive({\r\n selector: 'textarea[raqm-textarea]',\r\n host: {\r\n class: 'raqm-textarea',\r\n },\r\n})\r\nexport class RaqmTextarea {}\r\n"],"mappings":";;AASA,IAAa,eAAb,MAAa,aAAY;CAAZ,OAAA,OAAA,GAAA,mBAAA;EAAA,YAAA;EAAA,SAAA;EAAA,UAAA;EAAA,MAAA;EAAY,MAAA,CAAA;EAAA,QAAA,GAAA,gBAAA;CAAA,CAAA;CAAZ,OAAA,OAAA,GAAA,qBAAA;EAAA,YAAA;EAAA,SAAA;EAAA,MAAA;EAAY,cAAA;EAAA,UAAA;EAAA,MAAA,EAAA,gBAAA,gBAAA;EAAA,UAAA;CAAA,CAAA;;AAAZ,GAAA,yBAAA;CAAA,YAAA;CAAA,SAAA;CAAA,UAAA;CAAA,MAAA;CAAY,YAAA,CAAA;EANxB,MAAA;EAAU,MAAA,CAAA;GACT,UAAU;GACV,MAAM,EACJ,OAAO,gBACR;EACF,CAAA"}