@exhaustive-ui/mcp 0.0.0-stage → 3.0.0-alpha.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 (121) hide show
  1. package/LICENSE +23 -0
  2. package/README.md +167 -2
  3. package/data/components/accordion.md +421 -0
  4. package/data/components/animateonscroll.md +163 -0
  5. package/data/components/autocomplete.md +1077 -0
  6. package/data/components/autofocus.md +38 -0
  7. package/data/components/avatar.md +417 -0
  8. package/data/components/badge.md +234 -0
  9. package/data/components/blockui.md +108 -0
  10. package/data/components/breadcrumb.md +178 -0
  11. package/data/components/button.md +774 -0
  12. package/data/components/card.md +138 -0
  13. package/data/components/carousel.md +440 -0
  14. package/data/components/cascadeselect.md +1387 -0
  15. package/data/components/chart.md +1178 -0
  16. package/data/components/checkbox.md +529 -0
  17. package/data/components/chip.md +180 -0
  18. package/data/components/colorpicker.md +301 -0
  19. package/data/components/confirmdialog.md +287 -0
  20. package/data/components/confirmpopup.md +417 -0
  21. package/data/components/contextmenu.md +491 -0
  22. package/data/components/dataview.md +600 -0
  23. package/data/components/datepicker.md +1262 -0
  24. package/data/components/dialog.md +622 -0
  25. package/data/components/divider.md +250 -0
  26. package/data/components/dock.md +500 -0
  27. package/data/components/dragdrop.md +285 -0
  28. package/data/components/drawer.md +510 -0
  29. package/data/components/dynamicdialog.md +109 -0
  30. package/data/components/editor.md +291 -0
  31. package/data/components/fieldset.md +182 -0
  32. package/data/components/fileupload.md +430 -0
  33. package/data/components/floatlabel.md +155 -0
  34. package/data/components/fluid.md +72 -0
  35. package/data/components/focustrap.md +65 -0
  36. package/data/components/galleria.md +627 -0
  37. package/data/components/iconfield.md +246 -0
  38. package/data/components/iftalabel.md +105 -0
  39. package/data/components/imagecompare.md +97 -0
  40. package/data/components/inplace.md +233 -0
  41. package/data/components/inputgroup.md +306 -0
  42. package/data/components/inputmask.md +518 -0
  43. package/data/components/inputnumber.md +675 -0
  44. package/data/components/inputotp.md +336 -0
  45. package/data/components/inputtext.md +488 -0
  46. package/data/components/keyfilter.md +85 -0
  47. package/data/components/knob.md +462 -0
  48. package/data/components/listbox.md +798 -0
  49. package/data/components/llms.md +28 -0
  50. package/data/components/megamenu.md +587 -0
  51. package/data/components/menu.md +483 -0
  52. package/data/components/menubar.md +462 -0
  53. package/data/components/message.md +449 -0
  54. package/data/components/metergroup.md +241 -0
  55. package/data/components/multiselect.md +1047 -0
  56. package/data/components/orderlist.md +342 -0
  57. package/data/components/organizationchart.md +197 -0
  58. package/data/components/overlay.md +217 -0
  59. package/data/components/paginator.md +314 -0
  60. package/data/components/panel.md +214 -0
  61. package/data/components/panelmenu.md +699 -0
  62. package/data/components/password.md +570 -0
  63. package/data/components/picklist.md +420 -0
  64. package/data/components/popover.md +378 -0
  65. package/data/components/progressbar.md +181 -0
  66. package/data/components/progressspinner.md +91 -0
  67. package/data/components/radiobutton.md +377 -0
  68. package/data/components/rating.md +312 -0
  69. package/data/components/ripple.md +89 -0
  70. package/data/components/scroller.md +122 -0
  71. package/data/components/scrollpanel.md +149 -0
  72. package/data/components/scrolltop.md +105 -0
  73. package/data/components/select.md +1206 -0
  74. package/data/components/selectbutton.md +356 -0
  75. package/data/components/skeleton.md +242 -0
  76. package/data/components/slider.md +337 -0
  77. package/data/components/speeddial.md +589 -0
  78. package/data/components/splitbutton.md +945 -0
  79. package/data/components/splitter.md +196 -0
  80. package/data/components/stepper.md +411 -0
  81. package/data/components/styleclass.md +126 -0
  82. package/data/components/table.md +4557 -0
  83. package/data/components/tabs.md +467 -0
  84. package/data/components/tag.md +200 -0
  85. package/data/components/terminal.md +118 -0
  86. package/data/components/textarea.md +416 -0
  87. package/data/components/tieredmenu.md +578 -0
  88. package/data/components/timeline.md +310 -0
  89. package/data/components/toast.md +596 -0
  90. package/data/components/togglebutton.md +356 -0
  91. package/data/components/toggleswitch.md +285 -0
  92. package/data/components/toolbar.md +182 -0
  93. package/data/components/tooltip.md +211 -0
  94. package/data/components/tree.md +746 -0
  95. package/data/components/treeselect.md +912 -0
  96. package/data/components/treetable.md +2814 -0
  97. package/data/components.json +43751 -0
  98. package/data/llms-full.txt +47433 -0
  99. package/data/llms.txt +121 -0
  100. package/data/manifest.json +46513 -0
  101. package/data/pages/accessibility.md +28 -0
  102. package/data/pages/animations.md +28 -0
  103. package/data/pages/configuration.md +210 -0
  104. package/data/pages/contribution.md +20 -0
  105. package/data/pages/customicons.md +20 -0
  106. package/data/pages/faq.md +20 -0
  107. package/data/pages/icons.md +66 -0
  108. package/data/pages/installation.md +71 -0
  109. package/data/pages/llms.md +61 -0
  110. package/data/pages/passthrough.md +32 -0
  111. package/data/pages/philosophy.md +28 -0
  112. package/data/pages/primeflex.md +20 -0
  113. package/data/pages/rtl.md +12 -0
  114. package/data/pages/styled.md +132 -0
  115. package/data/pages/tailwind.md +40 -0
  116. package/data/pages/unstyled.md +39 -0
  117. package/data/snapshot.json +9 -0
  118. package/dist/index.d.mts +448 -0
  119. package/dist/index.mjs +2501 -0
  120. package/dist/index.mjs.map +1 -0
  121. package/package.json +67 -3
@@ -0,0 +1,467 @@
1
+ # Angular Tabs Component
2
+
3
+ Tabs is a container component to group content with tabs.
4
+
5
+ ## Accessibility
6
+
7
+ Screen Reader Tabs container is defined with the tablist role, as any attribute is passed to the container element aria-labelledby can be optionally used to specify an element to describe the Tabs. Each tab header has a tab role along with aria-selected state attribute and aria-controls to refer to the corresponding tab content element. The content element of each tab has tabpanel role, an id to match the aria-controls of the header and aria-labelledby reference to the header as the accessible name. Tab Header Keyboard Support Key Function tab Moves focus through the header. enter Activates the focused tab header. space Activates the focused tab header. right arrow Moves focus to the next header. left arrow Moves focus to the previous header. home Moves focus to the last header. end Moves focus to the first header.
8
+
9
+ ## Basic
10
+
11
+ Tabs is defined using TabList , Tab , TabPanels and TabPanel components. Tab and TabPanel components are associated with their value properties
12
+
13
+ ```typescript
14
+ import { Component } from '@angular/core';
15
+ import { TabsModule } from '@exhaustive-ui/core/tabs';
16
+
17
+ @Component({
18
+ template: `
19
+ <div class="card">
20
+ <p-tabs value="0">
21
+ <p-tablist>
22
+ <p-tab value="0">Header I</p-tab>
23
+ <p-tab value="1">Header II</p-tab>
24
+ <p-tab value="2">Header III</p-tab>
25
+ </p-tablist>
26
+ <p-tabpanels>
27
+ <p-tabpanel value="0">
28
+ <p class="m-0">
29
+ Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo
30
+ consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est
31
+ laborum.
32
+ </p>
33
+ </p-tabpanel>
34
+ <p-tabpanel value="1">
35
+ <p class="m-0">
36
+ Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam, eaque ipsa quae ab illo inventore veritatis et quasi architecto beatae vitae dicta sunt explicabo. Nemo
37
+ enim ipsam voluptatem quia voluptas sit aspernatur aut odit aut fugit, sed quia consequuntur magni dolores eos qui ratione voluptatem sequi nesciunt. Consectetur, adipisci velit, sed quia non numquam eius modi.
38
+ </p>
39
+ </p-tabpanel>
40
+ <p-tabpanel value="2">
41
+ <p class="m-0">
42
+ At vero eos et accusamus et iusto odio dignissimos ducimus qui blanditiis praesentium voluptatum deleniti atque corrupti quos dolores et quas molestias excepturi sint occaecati cupiditate non provident, similique sunt in
43
+ culpa qui officia deserunt mollitia animi, id est laborum et dolorum fuga. Et harum quidem rerum facilis est et expedita distinctio. Nam libero tempore, cum soluta nobis est eligendi optio cumque nihil impedit quo minus.
44
+ </p>
45
+ </p-tabpanel>
46
+ </p-tabpanels>
47
+ </p-tabs>
48
+ </div>
49
+ `,
50
+ standalone: true,
51
+ imports: [TabsModule]
52
+ })
53
+ export class TabsBasicDemo {}
54
+ ```
55
+
56
+ ## Controlled
57
+
58
+ Tabs can be controlled programmatically using value property as a model.
59
+
60
+ ```typescript
61
+ import { Component } from '@angular/core';
62
+ import { ButtonModule } from '@exhaustive-ui/core/button';
63
+ import { TabsModule } from '@exhaustive-ui/core/tabs';
64
+
65
+ @Component({
66
+ template: `
67
+ <div class="card">
68
+ <div class="flex mb-2 gap-2 justify-end">
69
+ <p-button (onClick)="value = 0" rounded="true" styleClass="w-8 h-8 p-0" [outlined]="value !== 0" label="1" />
70
+ <p-button (onClick)="value = 1" rounded="true" styleClass="w-8 h-8 p-0" [outlined]="value !== 1" label="2" />
71
+ <p-button (onClick)="value = 2" rounded="true" styleClass="w-8 h-8 p-0" [outlined]="value !== 2" label="3" />
72
+ </div>
73
+ <p-tabs [(value)]="value">
74
+ <p-tablist>
75
+ <p-tab [value]="0">Header I</p-tab>
76
+ <p-tab [value]="1">Header II</p-tab>
77
+ <p-tab [value]="2">Header III</p-tab>
78
+ </p-tablist>
79
+ <p-tabpanels>
80
+ <p-tabpanel [value]="0">
81
+ <p class="m-0">
82
+ Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo
83
+ consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est
84
+ laborum.
85
+ </p>
86
+ </p-tabpanel>
87
+ <p-tabpanel [value]="1">
88
+ <p class="m-0">
89
+ Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam, eaque ipsa quae ab illo inventore veritatis et quasi architecto beatae vitae dicta sunt explicabo. Nemo
90
+ enim ipsam voluptatem quia voluptas sit aspernatur aut odit aut fugit, sed quia consequuntur magni dolores eos qui ratione voluptatem sequi nesciunt. Consectetur, adipisci velit, sed quia non numquam eius modi.
91
+ </p>
92
+ </p-tabpanel>
93
+ <p-tabpanel [value]="2">
94
+ <p class="m-0">
95
+ At vero eos et accusamus et iusto odio dignissimos ducimus qui blanditiis praesentium voluptatum deleniti atque corrupti quos dolores et quas molestias excepturi sint occaecati cupiditate non provident, similique sunt in
96
+ culpa qui officia deserunt mollitia animi, id est laborum et dolorum fuga. Et harum quidem rerum facilis est et expedita distinctio. Nam libero tempore, cum soluta nobis est eligendi optio cumque nihil impedit quo minus.
97
+ </p>
98
+ </p-tabpanel>
99
+ </p-tabpanels>
100
+ </p-tabs>
101
+ </div>
102
+ `,
103
+ standalone: true,
104
+ imports: [ButtonModule, TabsModule]
105
+ })
106
+ export class TabsControlledDemo {
107
+ value: number = 0;
108
+ }
109
+ ```
110
+
111
+ ## customtemplate-doc
112
+
113
+ Custom content for a tab is defined with the default ng-content.
114
+
115
+ ```typescript
116
+ import { Component } from '@angular/core';
117
+ import { AvatarModule } from '@exhaustive-ui/core/avatar';
118
+ import { BadgeModule } from '@exhaustive-ui/core/badge';
119
+ import { TabsModule } from '@exhaustive-ui/core/tabs';
120
+
121
+ @Component({
122
+ template: `
123
+ <div class="card">
124
+ <p-tabs value="0" scrollable>
125
+ <p-tablist>
126
+ <ng-template #previcon>
127
+ <i class="pi pi-minus"></i>
128
+ </ng-template>
129
+ <p-tab value="0" class="flex items-center !gap-2">
130
+ <p-avatar image="https://exhaustive-ui.e-xiste.com/demo/avatar/amyelsner.png" shape="circle" />
131
+ <span class="font-bold whitespace-nowrap">Amy Elsner</span>
132
+ </p-tab>
133
+ <p-tab value="1" class="flex items-center !gap-2">
134
+ <p-avatar image="https://exhaustive-ui.e-xiste.com/demo/avatar/onyamalimba.png" shape="circle" />
135
+ <span class="font-bold whitespace-nowrap">Onyama Limba</span>
136
+ </p-tab>
137
+ <p-tab value="2" class="flex items-center !gap-2">
138
+ <p-avatar image="https://exhaustive-ui.e-xiste.com/demo/avatar/ionibowcher.png" shape="circle" />
139
+ <span class="font-bold whitespace-nowrap">Ioni Bowcher</span>
140
+ <p-badge value="2" />
141
+ </p-tab>
142
+ <ng-template #nexticon>
143
+ <i class="pi pi-plus"></i>
144
+ </ng-template>
145
+ </p-tablist>
146
+ <p-tabpanels>
147
+ <p-tabpanel value="0">
148
+ <p class="m-0">
149
+ Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo
150
+ consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est
151
+ laborum.
152
+ </p>
153
+ </p-tabpanel>
154
+ <p-tabpanel value="1">
155
+ <p class="m-0">
156
+ Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam, eaque ipsa quae ab illo inventore veritatis et quasi architecto beatae vitae dicta sunt explicabo. Nemo
157
+ enim ipsam voluptatem quia voluptas sit aspernatur aut odit aut fugit, sed quia consequuntur magni dolores eos qui ratione voluptatem sequi nesciunt. Consectetur, adipisci velit, sed quia non numquam eius modi.
158
+ </p>
159
+ </p-tabpanel>
160
+ <p-tabpanel value="2">
161
+ <p class="m-0">
162
+ At vero eos et accusamus et iusto odio dignissimos ducimus qui blanditiis praesentium voluptatum deleniti atque corrupti quos dolores et quas molestias excepturi sint occaecati cupiditate non provident, similique sunt in
163
+ culpa qui officia deserunt mollitia animi, id est laborum et dolorum fuga. Et harum quidem rerum facilis est et expedita distinctio. Nam libero tempore, cum soluta nobis est eligendi optio cumque nihil impedit quo minus.
164
+ </p>
165
+ </p-tabpanel>
166
+ </p-tabpanels>
167
+ </p-tabs>
168
+ </div>
169
+ `,
170
+ standalone: true,
171
+ imports: [AvatarModule, BadgeModule, TabsModule]
172
+ })
173
+ export class TabsCustomtemplateDemo {}
174
+ ```
175
+
176
+ ## Disabled
177
+
178
+ Setting the disabled property prevents tab activation or selection, while pointer-based interactions such as pTooltip hover remain available.
179
+
180
+ ```typescript
181
+ import { Component } from '@angular/core';
182
+ import { TabsModule } from '@exhaustive-ui/core/tabs';
183
+
184
+ @Component({
185
+ template: `
186
+ <div class="card">
187
+ <p-tabs value="0">
188
+ <p-tablist>
189
+ <p-tab value="0">Header I</p-tab>
190
+ <p-tab value="1">Header II</p-tab>
191
+ <p-tab value="2">Header III</p-tab>
192
+ <p-tab disabled>Header IV</p-tab>
193
+ </p-tablist>
194
+ <p-tabpanels>
195
+ <p-tabpanel value="0">
196
+ <p class="m-0">
197
+ Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo
198
+ consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est
199
+ laborum.
200
+ </p>
201
+ </p-tabpanel>
202
+ <p-tabpanel value="1">
203
+ <p class="m-0">
204
+ Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam, eaque ipsa quae ab illo inventore veritatis et quasi architecto beatae vitae dicta sunt explicabo. Nemo
205
+ enim ipsam voluptatem quia voluptas sit aspernatur aut odit aut fugit, sed quia consequuntur magni dolores eos qui ratione voluptatem sequi nesciunt. Consectetur, adipisci velit, sed quia non numquam eius modi.
206
+ </p>
207
+ </p-tabpanel>
208
+ <p-tabpanel value="2">
209
+ <p class="m-0">
210
+ At vero eos et accusamus et iusto odio dignissimos ducimus qui blanditiis praesentium voluptatum deleniti atque corrupti quos dolores et quas molestias excepturi sint occaecati cupiditate non provident, similique sunt in
211
+ culpa qui officia deserunt mollitia animi, id est laborum et dolorum fuga. Et harum quidem rerum facilis est et expedita distinctio. Nam libero tempore, cum soluta nobis est eligendi optio cumque nihil impedit quo minus.
212
+ </p>
213
+ </p-tabpanel>
214
+ </p-tabpanels>
215
+ </p-tabs>
216
+ </div>
217
+ `,
218
+ standalone: true,
219
+ imports: [TabsModule]
220
+ })
221
+ export class TabsDisabledDemo {}
222
+ ```
223
+
224
+ ## Dynamic
225
+
226
+ Tabs can be generated dynamically using the standard &#64;for block.
227
+
228
+ ```typescript
229
+ import { Component, OnInit } from '@angular/core';
230
+ import { TabsModule } from '@exhaustive-ui/core/tabs';
231
+
232
+ @Component({
233
+ template: `
234
+ <div class="card">
235
+ <p-tabs value="0">
236
+ <p-tablist>
237
+ @for (tab of tabs; track tab.value) {
238
+ <p-tab [value]="tab.value">{{ tab.title }}</p-tab>
239
+ }
240
+ </p-tablist>
241
+ <p-tabpanels>
242
+ @for (tab of tabs; track tab.value) {
243
+ <p-tabpanel [value]="tab.value">
244
+ <p class="m-0">{{ tab.content }}</p>
245
+ </p-tabpanel>
246
+ }
247
+ </p-tabpanels>
248
+ </p-tabs>
249
+ </div>
250
+ `,
251
+ standalone: true,
252
+ imports: [TabsModule]
253
+ })
254
+ export class TabsDynamicDemo implements OnInit {
255
+ ngOnInit() {
256
+ this.tabs = [
257
+ { title: 'Tab 1', value: '0', content: 'Tab 1 Content' },
258
+ { title: 'Tab 2', value: '1', content: 'Tab 2 Content' },
259
+ { title: 'Tab 3', value: '2', content: 'Tab 3 Content' }
260
+ ];
261
+ }
262
+ }
263
+ ```
264
+
265
+ ## Lazy
266
+
267
+ By default, inactive tab's content is rendered (but hidden). You can use the lazy input (either globally on Tabs or individually on a TabPanel ) to change this behavior so that content is only rendered when the tab becomes active. If a lazy tab contains complex components that should only be initialized when the tab is activated, you should wrap the content inside: &lt;ng-template #content&gt;your content&lt;/ng-template&gt; .
268
+
269
+ ```typescript
270
+ import { Component } from '@angular/core';
271
+ import { TabsModule } from '@exhaustive-ui/core/tabs';
272
+
273
+ @Component({
274
+ template: `
275
+ <div class="card">
276
+ <p-tabs lazy value="0">
277
+ <p-tablist>
278
+ <p-tab value="0">Header I</p-tab>
279
+ <p-tab value="1">Header II</p-tab>
280
+ <p-tab value="2">Header III</p-tab>
281
+ </p-tablist>
282
+ <p-tabpanels>
283
+ <p-tabpanel value="0">
284
+ <p class="m-0">
285
+ Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo
286
+ consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est
287
+ laborum.
288
+ </p>
289
+ </p-tabpanel>
290
+ <p-tabpanel value="1">
291
+ <p class="m-0">
292
+ Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam, eaque ipsa quae ab illo inventore veritatis et quasi architecto beatae vitae dicta sunt explicabo. Nemo
293
+ enim ipsam voluptatem quia voluptas sit aspernatur aut odit aut fugit, sed quia consequuntur magni dolores eos qui ratione voluptatem sequi nesciunt. Consectetur, adipisci velit, sed quia non numquam eius modi.
294
+ </p>
295
+ </p-tabpanel>
296
+ <p-tabpanel value="2">
297
+ <ng-template #content>Complex components that should only be initialized when the tab becomes active</ng-template>
298
+ </p-tabpanel>
299
+ </p-tabpanels>
300
+ </p-tabs>
301
+ </div>
302
+ `,
303
+ standalone: true,
304
+ imports: [TabsModule]
305
+ })
306
+ export class TabsLazyDemo {}
307
+ ```
308
+
309
+ ## Scrollable
310
+
311
+ Adding scrollable property displays navigational buttons at each side to scroll between tabs.
312
+
313
+ ```typescript
314
+ import { Component } from '@angular/core';
315
+ import { TabsModule } from '@exhaustive-ui/core/tabs';
316
+
317
+ @Component({
318
+ template: `
319
+ <div class="card">
320
+ <p-tabs value="0" scrollable>
321
+ <p-tablist>
322
+ @for (tab of scrollableTabs; track tab.value) {
323
+ <p-tab [value]="tab.value">
324
+ {{ tab.title }}
325
+ </p-tab>
326
+ }
327
+ </p-tablist>
328
+ <p-tabpanels>
329
+ @for (tab of scrollableTabs; track tab.value) {
330
+ <p-tabpanel [value]="tab.value">
331
+ <p class="m-0">{{ tab.content }}</p>
332
+ </p-tabpanel>
333
+ }
334
+ </p-tabpanels>
335
+ </p-tabs>
336
+ </div>
337
+ `,
338
+ standalone: true,
339
+ imports: [TabsModule]
340
+ })
341
+ export class TabsScrollableDemo {
342
+ scrollableTabs: any[];
343
+ }
344
+ ```
345
+
346
+ ## Tab Menu
347
+
348
+ A navigation menu is implemented using tabs without the panels where the content of a tab is provided by a route component like router-outlet . For the purpose of this demo, router-outlet is not included.
349
+
350
+ ```typescript
351
+ import { Component } from '@angular/core';
352
+ import { TabsModule } from '@exhaustive-ui/core/tabs';
353
+
354
+ @Component({
355
+ template: `
356
+ <div class="card">
357
+ <p-tabs value="dashboard">
358
+ <p-tablist>
359
+ @for (tab of tabs; track tab.route) {
360
+ <p-tab [value]="tab.route" class="flex items-center !gap-2 text-inherit">
361
+ <i [class]="tab.icon"></i>
362
+ <span>{{ tab.label }}</span>
363
+ </p-tab>
364
+ }
365
+ </p-tablist>
366
+ </p-tabs>
367
+ <!--<router-outlet></router-outlet>-->
368
+ </div>
369
+ `,
370
+ standalone: true,
371
+ imports: [TabsModule]
372
+ })
373
+ export class TabsTabmenuDemo {
374
+ tabs: any[];
375
+ }
376
+ ```
377
+
378
+ ## Tabs
379
+
380
+ Tabs facilitates seamless switching between different views.
381
+
382
+ ### Props
383
+
384
+ | Name | Type | Default | Description |
385
+ |------|------|---------|-------------|
386
+ | dt | InputSignal<Object> | undefined | Defines scoped design tokens of the component. |
387
+ | unstyled | InputSignal<boolean> | undefined | Indicates whether the component should be rendered without styles. |
388
+ | pt | InputSignal<TabsPassThrough> | undefined | Used to pass attributes to DOM elements inside the component. |
389
+ | ptOptions | InputSignal<PassThroughOptions> | undefined | Used to configure passthrough(pt) options of the component. |
390
+ | value | ModelSignal<string \| number> | undefined | Value of the active tab. |
391
+ | scrollable | InputSignalWithTransform<boolean, unknown> | false | When specified, enables horizontal and/or vertical scrolling. |
392
+ | lazy | InputSignalWithTransform<boolean, unknown> | false | When enabled, tabs are not rendered until activation. |
393
+ | selectOnFocus | InputSignalWithTransform<boolean, unknown> | false | When enabled, the focused tab is activated. |
394
+ | showNavigators | InputSignalWithTransform<boolean, unknown> | true | Whether to display navigation buttons in container when scrollable is enabled. |
395
+ | tabindex | InputSignalWithTransform<number, unknown> | 0 | Tabindex of the tab buttons. |
396
+
397
+ ## Pass Through Options
398
+
399
+ | Name | Type | Description |
400
+ |------|------|-------------|
401
+ | root | PassThroughOption<HTMLElement, I> | Used to pass attributes to the root's DOM element. |
402
+
403
+ ## Theming
404
+
405
+ ### CSS Classes
406
+
407
+ | Class | Description |
408
+ |-------|-------------|
409
+ | p-tabs | Class name of the root element |
410
+ | p-tablist | Class name of the wrapper element |
411
+ | p-tablist-content | Class name of the content element |
412
+ | p-tablist-tab-list | Class name of the tab list element |
413
+ | p-tab | Class name of the tab list element |
414
+ | p-tablist-active-bar | Class name of the inkbar element |
415
+ | p-tablist-nav-button | Class name of the navigation buttons |
416
+ | p-tabpanels | Class name of the tab panels wrapper |
417
+ | p-tabs-panel | Class name of the tab panel element |
418
+
419
+ ### Design Tokens
420
+
421
+ | Token | CSS Variable | Description |
422
+ |-------|--------------|-------------|
423
+ | tabs.transition.duration | --p-tabs-transition-duration | Transition duration of root |
424
+ | tabs.tablist.border.width | --p-tabs-tablist-border-width | Border width of tablist |
425
+ | tabs.tablist.background | --p-tabs-tablist-background | Background of tablist |
426
+ | tabs.tablist.border.color | --p-tabs-tablist-border-color | Border color of tablist |
427
+ | tabs.tab.background | --p-tabs-tab-background | Background of tab |
428
+ | tabs.tab.hover.background | --p-tabs-tab-hover-background | Hover background of tab |
429
+ | tabs.tab.active.background | --p-tabs-tab-active-background | Active background of tab |
430
+ | tabs.tab.border.width | --p-tabs-tab-border-width | Border width of tab |
431
+ | tabs.tab.border.color | --p-tabs-tab-border-color | Border color of tab |
432
+ | tabs.tab.hover.border.color | --p-tabs-tab-hover-border-color | Hover border color of tab |
433
+ | tabs.tab.active.border.color | --p-tabs-tab-active-border-color | Active border color of tab |
434
+ | tabs.tab.color | --p-tabs-tab-color | Color of tab |
435
+ | tabs.tab.hover.color | --p-tabs-tab-hover-color | Hover color of tab |
436
+ | tabs.tab.active.color | --p-tabs-tab-active-color | Active color of tab |
437
+ | tabs.tab.padding | --p-tabs-tab-padding | Padding of tab |
438
+ | tabs.tab.font.weight | --p-tabs-tab-font-weight | Font weight of tab |
439
+ | tabs.tab.margin | --p-tabs-tab-margin | Margin of tab |
440
+ | tabs.tab.gap | --p-tabs-tab-gap | Gap of tab |
441
+ | tabs.tab.focus.ring.width | --p-tabs-tab-focus-ring-width | Focus ring width of tab |
442
+ | tabs.tab.focus.ring.style | --p-tabs-tab-focus-ring-style | Focus ring style of tab |
443
+ | tabs.tab.focus.ring.color | --p-tabs-tab-focus-ring-color | Focus ring color of tab |
444
+ | tabs.tab.focus.ring.offset | --p-tabs-tab-focus-ring-offset | Focus ring offset of tab |
445
+ | tabs.tab.focus.ring.shadow | --p-tabs-tab-focus-ring-shadow | Focus ring shadow of tab |
446
+ | tabs.tabpanel.background | --p-tabs-tabpanel-background | Background of tabpanel |
447
+ | tabs.tabpanel.color | --p-tabs-tabpanel-color | Color of tabpanel |
448
+ | tabs.tabpanel.padding | --p-tabs-tabpanel-padding | Padding of tabpanel |
449
+ | tabs.tabpanel.focus.ring.width | --p-tabs-tabpanel-focus-ring-width | Focus ring width of tabpanel |
450
+ | tabs.tabpanel.focus.ring.style | --p-tabs-tabpanel-focus-ring-style | Focus ring style of tabpanel |
451
+ | tabs.tabpanel.focus.ring.color | --p-tabs-tabpanel-focus-ring-color | Focus ring color of tabpanel |
452
+ | tabs.tabpanel.focus.ring.offset | --p-tabs-tabpanel-focus-ring-offset | Focus ring offset of tabpanel |
453
+ | tabs.tabpanel.focus.ring.shadow | --p-tabs-tabpanel-focus-ring-shadow | Focus ring shadow of tabpanel |
454
+ | tabs.nav.button.background | --p-tabs-nav-button-background | Background of nav button |
455
+ | tabs.nav.button.color | --p-tabs-nav-button-color | Color of nav button |
456
+ | tabs.nav.button.hover.color | --p-tabs-nav-button-hover-color | Hover color of nav button |
457
+ | tabs.nav.button.width | --p-tabs-nav-button-width | Width of nav button |
458
+ | tabs.nav.button.focus.ring.width | --p-tabs-nav-button-focus-ring-width | Focus ring width of nav button |
459
+ | tabs.nav.button.focus.ring.style | --p-tabs-nav-button-focus-ring-style | Focus ring style of nav button |
460
+ | tabs.nav.button.focus.ring.color | --p-tabs-nav-button-focus-ring-color | Focus ring color of nav button |
461
+ | tabs.nav.button.focus.ring.offset | --p-tabs-nav-button-focus-ring-offset | Focus ring offset of nav button |
462
+ | tabs.nav.button.focus.ring.shadow | --p-tabs-nav-button-focus-ring-shadow | Focus ring shadow of nav button |
463
+ | tabs.nav.button.shadow | --p-tabs-nav-button-shadow | Shadow of nav button |
464
+ | tabs.active.bar.height | --p-tabs-active-bar-height | Height of active bar |
465
+ | tabs.active.bar.bottom | --p-tabs-active-bar-bottom | Bottom of active bar |
466
+ | tabs.active.bar.background | --p-tabs-active-bar-background | Background of active bar |
467
+
@@ -0,0 +1,200 @@
1
+ # Angular Tag Component
2
+
3
+ Tag component is used to categorize content.
4
+
5
+ ## Accessibility
6
+
7
+ Screen Reader Tag does not include any roles and attributes by default, any attribute is passed to the root element so aria roles and attributes can be added if required. If the tags are dynamic, aria-live may be utilized as well. In case badges need to be tabbable, tabIndex can be added to implement custom key handlers. Keyboard Support Component does not include any interactive elements.
8
+
9
+ ## Basic
10
+
11
+ Label of the tag is defined with the value property.
12
+
13
+ ```typescript
14
+ import { Component } from '@angular/core';
15
+ import { TagModule } from '@exhaustive-ui/core/tag';
16
+
17
+ @Component({
18
+ template: `
19
+ <div class="card flex justify-center">
20
+ <p-tag value="New" />
21
+ </div>
22
+ `,
23
+ standalone: true,
24
+ imports: [TagModule]
25
+ })
26
+ export class TagBasicDemo {}
27
+ ```
28
+
29
+ ## Icon
30
+
31
+ A font icon next to the value can be displayed with the icon property.
32
+
33
+ ```typescript
34
+ import { Component } from '@angular/core';
35
+ import { TagModule } from '@exhaustive-ui/core/tag';
36
+
37
+ @Component({
38
+ template: `
39
+ <div class="card flex flex-wrap justify-center gap-2">
40
+ <p-tag icon="pi pi-user" value="Primary" />
41
+ <p-tag icon="pi pi-search" severity="secondary" value="Secondary" />
42
+ <p-tag icon="pi pi-check" severity="success" value="Success" />
43
+ <p-tag icon="pi pi-info-circle" severity="info" value="Info" />
44
+ <p-tag icon="pi pi-exclamation-triangle" severity="warn" value="Warn" />
45
+ <p-tag icon="pi pi-times" severity="danger" value="Danger" />
46
+ <p-tag icon="pi pi-cog" severity="contrast" value="Contrast" />
47
+ </div>
48
+ `,
49
+ standalone: true,
50
+ imports: [TagModule]
51
+ })
52
+ export class TagIconDemo {}
53
+ ```
54
+
55
+ ## Pill
56
+
57
+ Enabling rounded , displays a tag as a pill.
58
+
59
+ ```typescript
60
+ import { Component } from '@angular/core';
61
+ import { TagModule } from '@exhaustive-ui/core/tag';
62
+
63
+ @Component({
64
+ template: `
65
+ <div class="card flex justify-center gap-2">
66
+ <p-tag value="Primary" [rounded]="true" />
67
+ <p-tag severity="secondary" value="Secondary" [rounded]="true" />
68
+ <p-tag severity="success" value="Success" [rounded]="true" />
69
+ <p-tag severity="info" value="Info" [rounded]="true" />
70
+ <p-tag severity="warn" value="Warn" [rounded]="true" />
71
+ <p-tag severity="danger" value="Danger" [rounded]="true" />
72
+ <p-tag severity="contrast" value="Contrast" [rounded]="true" />
73
+ </div>
74
+ `,
75
+ standalone: true,
76
+ imports: [TagModule]
77
+ })
78
+ export class TagPillDemo {}
79
+ ```
80
+
81
+ ## Severity
82
+
83
+ Severity defines the color of the tag, possible values are success , info , warn and danger in addition to the default theme color.
84
+
85
+ ```typescript
86
+ import { Component } from '@angular/core';
87
+ import { TagModule } from '@exhaustive-ui/core/tag';
88
+
89
+ @Component({
90
+ template: `
91
+ <div class="card flex justify-center gap-2">
92
+ <p-tag value="Primary" />
93
+ <p-tag severity="secondary" value="Secondary" />
94
+ <p-tag severity="success" value="Success" />
95
+ <p-tag severity="info" value="Info" />
96
+ <p-tag severity="warn" value="Warn" />
97
+ <p-tag severity="danger" value="Danger" />
98
+ <p-tag severity="contrast" value="Contrast" />
99
+ </div>
100
+ `,
101
+ standalone: true,
102
+ imports: [TagModule]
103
+ })
104
+ export class TagSeverityDemo {}
105
+ ```
106
+
107
+ ## Template
108
+
109
+ Children of the component are passed as the content for templating.
110
+
111
+ ```typescript
112
+ import { Component } from '@angular/core';
113
+ import { TagModule } from '@exhaustive-ui/core/tag';
114
+ import { Country } from '@/domain/customer';
115
+
116
+ @Component({
117
+ template: `
118
+ <div class="card flex justify-center">
119
+ <p-tag [style]="{ border: '2px solid var(--border-color)', background: 'transparent', color: 'var(--text-color)' }">
120
+ <div class="flex items-center gap-2 px-1">
121
+ <img alt="Country" src="https://exhaustive-ui.e-xiste.com/demo/flag/flag_placeholder.png" class="flag flag-it" style="width: 18px" />
122
+ <span class="text-base">Italy</span>
123
+ </div>
124
+ </p-tag>
125
+ </div>
126
+ `,
127
+ standalone: true,
128
+ imports: [TagModule]
129
+ })
130
+ export class TagTemplateDemo {}
131
+ ```
132
+
133
+ ## Tag
134
+
135
+ Tag component is used to categorize content.
136
+
137
+ ### Props
138
+
139
+ | Name | Type | Default | Description |
140
+ |------|------|---------|-------------|
141
+ | dt | InputSignal<Object> | undefined | Defines scoped design tokens of the component. |
142
+ | unstyled | InputSignal<boolean> | undefined | Indicates whether the component should be rendered without styles. |
143
+ | pt | InputSignal<TagPassThrough> | undefined | Used to pass attributes to DOM elements inside the component. |
144
+ | ptOptions | InputSignal<PassThroughOptions> | undefined | Used to configure passthrough(pt) options of the component. |
145
+ | severity | InputSignal<BadgeSeverity> | ... | Severity type of the tag. |
146
+ | value | InputSignal<string> | ... | Value to display inside the tag. |
147
+ | icon | InputSignal<string> | ... | Icon of the tag to display next to the value. |
148
+ | rounded | InputSignalWithTransform<boolean, unknown> | ... | Whether the corners of the tag are rounded. |
149
+
150
+ ### Templates
151
+
152
+ | Name | Type | Description |
153
+ |------|------|-------------|
154
+ | icon | TemplateRef<void> | Custom icon template. |
155
+
156
+ ## Pass Through Options
157
+
158
+ | Name | Type | Description |
159
+ |------|------|-------------|
160
+ | host | PassThroughOption<HTMLElement, I> | Used to pass attributes to the host's DOM element. |
161
+ | root | PassThroughOption<HTMLSpanElement, I> | Used to pass attributes to the root's DOM element. |
162
+ | icon | PassThroughOption<HTMLSpanElement, I> | Used to pass attributes to the icon's DOM element. |
163
+ | label | PassThroughOption<HTMLSpanElement, I> | Used to pass attributes to the label's DOM element. |
164
+
165
+ ## Theming
166
+
167
+ ### CSS Classes
168
+
169
+ | Class | Description |
170
+ |-------|-------------|
171
+ | p-tag | Class name of the root element |
172
+ | p-tag-icon | Class name of the icon element |
173
+ | p-tag-label | Class name of the label element |
174
+
175
+ ### Design Tokens
176
+
177
+ | Token | CSS Variable | Description |
178
+ |-------|--------------|-------------|
179
+ | tag.font.size | --p-tag-font-size | Font size of root |
180
+ | tag.font.weight | --p-tag-font-weight | Font weight of root |
181
+ | tag.padding | --p-tag-padding | Padding of root |
182
+ | tag.gap | --p-tag-gap | Gap of root |
183
+ | tag.border.radius | --p-tag-border-radius | Border radius of root |
184
+ | tag.rounded.border.radius | --p-tag-rounded-border-radius | Rounded border radius of root |
185
+ | tag.icon.size | --p-tag-icon-size | Size of icon |
186
+ | tag.primary.background | --p-tag-primary-background | Background of primary |
187
+ | tag.primary.color | --p-tag-primary-color | Color of primary |
188
+ | tag.secondary.background | --p-tag-secondary-background | Background of secondary |
189
+ | tag.secondary.color | --p-tag-secondary-color | Color of secondary |
190
+ | tag.success.background | --p-tag-success-background | Background of success |
191
+ | tag.success.color | --p-tag-success-color | Color of success |
192
+ | tag.info.background | --p-tag-info-background | Background of info |
193
+ | tag.info.color | --p-tag-info-color | Color of info |
194
+ | tag.warn.background | --p-tag-warn-background | Background of warn |
195
+ | tag.warn.color | --p-tag-warn-color | Color of warn |
196
+ | tag.danger.background | --p-tag-danger-background | Background of danger |
197
+ | tag.danger.color | --p-tag-danger-color | Color of danger |
198
+ | tag.contrast.background | --p-tag-contrast-background | Background of contrast |
199
+ | tag.contrast.color | --p-tag-contrast-color | Color of contrast |
200
+