@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.
- package/LICENSE +23 -0
- package/README.md +167 -2
- package/data/components/accordion.md +421 -0
- package/data/components/animateonscroll.md +163 -0
- package/data/components/autocomplete.md +1077 -0
- package/data/components/autofocus.md +38 -0
- package/data/components/avatar.md +417 -0
- package/data/components/badge.md +234 -0
- package/data/components/blockui.md +108 -0
- package/data/components/breadcrumb.md +178 -0
- package/data/components/button.md +774 -0
- package/data/components/card.md +138 -0
- package/data/components/carousel.md +440 -0
- package/data/components/cascadeselect.md +1387 -0
- package/data/components/chart.md +1178 -0
- package/data/components/checkbox.md +529 -0
- package/data/components/chip.md +180 -0
- package/data/components/colorpicker.md +301 -0
- package/data/components/confirmdialog.md +287 -0
- package/data/components/confirmpopup.md +417 -0
- package/data/components/contextmenu.md +491 -0
- package/data/components/dataview.md +600 -0
- package/data/components/datepicker.md +1262 -0
- package/data/components/dialog.md +622 -0
- package/data/components/divider.md +250 -0
- package/data/components/dock.md +500 -0
- package/data/components/dragdrop.md +285 -0
- package/data/components/drawer.md +510 -0
- package/data/components/dynamicdialog.md +109 -0
- package/data/components/editor.md +291 -0
- package/data/components/fieldset.md +182 -0
- package/data/components/fileupload.md +430 -0
- package/data/components/floatlabel.md +155 -0
- package/data/components/fluid.md +72 -0
- package/data/components/focustrap.md +65 -0
- package/data/components/galleria.md +627 -0
- package/data/components/iconfield.md +246 -0
- package/data/components/iftalabel.md +105 -0
- package/data/components/imagecompare.md +97 -0
- package/data/components/inplace.md +233 -0
- package/data/components/inputgroup.md +306 -0
- package/data/components/inputmask.md +518 -0
- package/data/components/inputnumber.md +675 -0
- package/data/components/inputotp.md +336 -0
- package/data/components/inputtext.md +488 -0
- package/data/components/keyfilter.md +85 -0
- package/data/components/knob.md +462 -0
- package/data/components/listbox.md +798 -0
- package/data/components/llms.md +28 -0
- package/data/components/megamenu.md +587 -0
- package/data/components/menu.md +483 -0
- package/data/components/menubar.md +462 -0
- package/data/components/message.md +449 -0
- package/data/components/metergroup.md +241 -0
- package/data/components/multiselect.md +1047 -0
- package/data/components/orderlist.md +342 -0
- package/data/components/organizationchart.md +197 -0
- package/data/components/overlay.md +217 -0
- package/data/components/paginator.md +314 -0
- package/data/components/panel.md +214 -0
- package/data/components/panelmenu.md +699 -0
- package/data/components/password.md +570 -0
- package/data/components/picklist.md +420 -0
- package/data/components/popover.md +378 -0
- package/data/components/progressbar.md +181 -0
- package/data/components/progressspinner.md +91 -0
- package/data/components/radiobutton.md +377 -0
- package/data/components/rating.md +312 -0
- package/data/components/ripple.md +89 -0
- package/data/components/scroller.md +122 -0
- package/data/components/scrollpanel.md +149 -0
- package/data/components/scrolltop.md +105 -0
- package/data/components/select.md +1206 -0
- package/data/components/selectbutton.md +356 -0
- package/data/components/skeleton.md +242 -0
- package/data/components/slider.md +337 -0
- package/data/components/speeddial.md +589 -0
- package/data/components/splitbutton.md +945 -0
- package/data/components/splitter.md +196 -0
- package/data/components/stepper.md +411 -0
- package/data/components/styleclass.md +126 -0
- package/data/components/table.md +4557 -0
- package/data/components/tabs.md +467 -0
- package/data/components/tag.md +200 -0
- package/data/components/terminal.md +118 -0
- package/data/components/textarea.md +416 -0
- package/data/components/tieredmenu.md +578 -0
- package/data/components/timeline.md +310 -0
- package/data/components/toast.md +596 -0
- package/data/components/togglebutton.md +356 -0
- package/data/components/toggleswitch.md +285 -0
- package/data/components/toolbar.md +182 -0
- package/data/components/tooltip.md +211 -0
- package/data/components/tree.md +746 -0
- package/data/components/treeselect.md +912 -0
- package/data/components/treetable.md +2814 -0
- package/data/components.json +43751 -0
- package/data/llms-full.txt +47433 -0
- package/data/llms.txt +121 -0
- package/data/manifest.json +46513 -0
- package/data/pages/accessibility.md +28 -0
- package/data/pages/animations.md +28 -0
- package/data/pages/configuration.md +210 -0
- package/data/pages/contribution.md +20 -0
- package/data/pages/customicons.md +20 -0
- package/data/pages/faq.md +20 -0
- package/data/pages/icons.md +66 -0
- package/data/pages/installation.md +71 -0
- package/data/pages/llms.md +61 -0
- package/data/pages/passthrough.md +32 -0
- package/data/pages/philosophy.md +28 -0
- package/data/pages/primeflex.md +20 -0
- package/data/pages/rtl.md +12 -0
- package/data/pages/styled.md +132 -0
- package/data/pages/tailwind.md +40 -0
- package/data/pages/unstyled.md +39 -0
- package/data/snapshot.json +9 -0
- package/dist/index.d.mts +448 -0
- package/dist/index.mjs +2501 -0
- package/dist/index.mjs.map +1 -0
- package/package.json +67 -3
|
@@ -0,0 +1,196 @@
|
|
|
1
|
+
# Angular Splitter Component
|
|
2
|
+
|
|
3
|
+
Splitter is utilized to separate and resize panels.
|
|
4
|
+
|
|
5
|
+
## Accessibility
|
|
6
|
+
|
|
7
|
+
Screen Reader Splitter bar defines separator as the role with aria-orientation set to either horizontal or vertical. Keyboard Support Key Function tab Moves focus through the splitter bar. down arrow Moves a vertical splitter down. up arrow Moves a vertical splitter up. left arrow Moves a vertical splitter to the left. right arrow Moves a vertical splitter to the right.
|
|
8
|
+
|
|
9
|
+
## Horizontal
|
|
10
|
+
|
|
11
|
+
Splitter requires two SplitterPanel components as children which are displayed horizontally by default.
|
|
12
|
+
|
|
13
|
+
```typescript
|
|
14
|
+
import { Component } from '@angular/core';
|
|
15
|
+
import { SplitterModule } from '@exhaustive-ui/core/splitter';
|
|
16
|
+
|
|
17
|
+
@Component({
|
|
18
|
+
template: `
|
|
19
|
+
<div class="card">
|
|
20
|
+
<p-splitter [style]="{ height: '300px' }" class="mb-8">
|
|
21
|
+
<ng-template #panel>
|
|
22
|
+
<div class="flex items-center justify-center h-full">Panel 1</div>
|
|
23
|
+
</ng-template>
|
|
24
|
+
<ng-template #panel>
|
|
25
|
+
<div class="flex items-center justify-center h-full">Panel 2</div>
|
|
26
|
+
</ng-template>
|
|
27
|
+
</p-splitter>
|
|
28
|
+
</div>
|
|
29
|
+
`,
|
|
30
|
+
standalone: true,
|
|
31
|
+
imports: [SplitterModule]
|
|
32
|
+
})
|
|
33
|
+
export class SplitterHorizontalDemo {}
|
|
34
|
+
```
|
|
35
|
+
|
|
36
|
+
## Nested
|
|
37
|
+
|
|
38
|
+
Splitters can be combined to create advanced layouts.
|
|
39
|
+
|
|
40
|
+
```typescript
|
|
41
|
+
import { Component } from '@angular/core';
|
|
42
|
+
import { SplitterModule } from '@exhaustive-ui/core/splitter';
|
|
43
|
+
|
|
44
|
+
@Component({
|
|
45
|
+
template: `
|
|
46
|
+
<div class="card">
|
|
47
|
+
<p-splitter [style]="{ height: '300px' }" [panelSizes]="[20, 80]" [minSizes]="[10, 0]" class="mb-8">
|
|
48
|
+
<ng-template #panel>
|
|
49
|
+
<div class="col flex w-full items-center justify-center">Panel 1</div>
|
|
50
|
+
</ng-template>
|
|
51
|
+
<ng-template #panel>
|
|
52
|
+
<p-splitter layout="vertical" [panelSizes]="[50, 50]">
|
|
53
|
+
<ng-template #panel>
|
|
54
|
+
<div style="flex-grow: 1;" class="flex items-center justify-center">Panel 2</div>
|
|
55
|
+
</ng-template>
|
|
56
|
+
<ng-template #panel>
|
|
57
|
+
<p-splitter [panelSizes]="[20, 80]">
|
|
58
|
+
<ng-template #panel>
|
|
59
|
+
<div class="col h-full flex items-center justify-center">Panel 3</div>
|
|
60
|
+
</ng-template>
|
|
61
|
+
<ng-template #panel>
|
|
62
|
+
<div class="col h-full flex items-center justify-center">Panel 4</div>
|
|
63
|
+
</ng-template>
|
|
64
|
+
</p-splitter>
|
|
65
|
+
</ng-template>
|
|
66
|
+
</p-splitter>
|
|
67
|
+
</ng-template>
|
|
68
|
+
</p-splitter>
|
|
69
|
+
</div>
|
|
70
|
+
`,
|
|
71
|
+
standalone: true,
|
|
72
|
+
imports: [SplitterModule]
|
|
73
|
+
})
|
|
74
|
+
export class SplitterNestedDemo {}
|
|
75
|
+
```
|
|
76
|
+
|
|
77
|
+
## Size
|
|
78
|
+
|
|
79
|
+
When no panelSizes are defined, panels are split 50/50, use the panelSizes property to give relative widths e.g. [25, 75].
|
|
80
|
+
|
|
81
|
+
```typescript
|
|
82
|
+
import { Component } from '@angular/core';
|
|
83
|
+
import { SplitterModule } from '@exhaustive-ui/core/splitter';
|
|
84
|
+
|
|
85
|
+
@Component({
|
|
86
|
+
template: `
|
|
87
|
+
<div class="card">
|
|
88
|
+
<p-splitter [panelSizes]="[25, 75]" [style]="{ height: '300px' }" class="mb-8">
|
|
89
|
+
<ng-template #panel>
|
|
90
|
+
<div class="flex items-center justify-center h-full">Panel 1</div>
|
|
91
|
+
</ng-template>
|
|
92
|
+
<ng-template #panel>
|
|
93
|
+
<div class="flex items-center justify-center h-full">Panel 2</div>
|
|
94
|
+
</ng-template>
|
|
95
|
+
</p-splitter>
|
|
96
|
+
</div>
|
|
97
|
+
`,
|
|
98
|
+
standalone: true,
|
|
99
|
+
imports: [SplitterModule]
|
|
100
|
+
})
|
|
101
|
+
export class SplitterSizeDemo {}
|
|
102
|
+
```
|
|
103
|
+
|
|
104
|
+
## Vertical
|
|
105
|
+
|
|
106
|
+
Panels are displayed as stacked by setting the layout to vertical .
|
|
107
|
+
|
|
108
|
+
```typescript
|
|
109
|
+
import { Component } from '@angular/core';
|
|
110
|
+
import { SplitterModule } from '@exhaustive-ui/core/splitter';
|
|
111
|
+
|
|
112
|
+
@Component({
|
|
113
|
+
template: `
|
|
114
|
+
<div class="card">
|
|
115
|
+
<p-splitter [style]="{ height: '300px' }" class="mb-8" [panelSizes]="[50, 50]" layout="vertical">
|
|
116
|
+
<ng-template #panel>
|
|
117
|
+
<div class="flex items-center justify-center h-full">Panel 1</div>
|
|
118
|
+
</ng-template>
|
|
119
|
+
<ng-template #panel>
|
|
120
|
+
<div class="flex items-center justify-center h-full">Panel 2</div>
|
|
121
|
+
</ng-template>
|
|
122
|
+
</p-splitter>
|
|
123
|
+
</div>
|
|
124
|
+
`,
|
|
125
|
+
standalone: true,
|
|
126
|
+
imports: [SplitterModule]
|
|
127
|
+
})
|
|
128
|
+
export class SplitterVerticalDemo {}
|
|
129
|
+
```
|
|
130
|
+
|
|
131
|
+
## Splitter
|
|
132
|
+
|
|
133
|
+
Splitter is utilized to separate and resize panels.
|
|
134
|
+
|
|
135
|
+
### Props
|
|
136
|
+
|
|
137
|
+
| Name | Type | Default | Description |
|
|
138
|
+
|------|------|---------|-------------|
|
|
139
|
+
| dt | InputSignal<Object> | undefined | Defines scoped design tokens of the component. |
|
|
140
|
+
| unstyled | InputSignal<boolean> | undefined | Indicates whether the component should be rendered without styles. |
|
|
141
|
+
| pt | InputSignal<SplitterPassThrough> | undefined | Used to pass attributes to DOM elements inside the component. |
|
|
142
|
+
| ptOptions | InputSignal<PassThroughOptions> | undefined | Used to configure passthrough(pt) options of the component. |
|
|
143
|
+
| panelStyleClass | InputSignal<string> | ... | Style class of the panel. |
|
|
144
|
+
| panelStyle | InputSignal<{ [klass: string]: any }> | ... | Inline style of the panel. |
|
|
145
|
+
| stateStorage | InputSignal<string> | ... | Defines where a stateful splitter keeps its state, valid values are 'session' for sessionStorage and 'local' for localStorage. |
|
|
146
|
+
| stateKey | InputSignal<string> | ... | Storage identifier of a stateful Splitter. |
|
|
147
|
+
| layout | InputSignal<string> | ... | Orientation of the panels. Valid values are 'horizontal' and 'vertical'. |
|
|
148
|
+
| gutterSize | InputSignalWithTransform<number, unknown> | ... | Size of the divider in pixels. |
|
|
149
|
+
| step | InputSignalWithTransform<number, unknown> | ... | Step factor to increment/decrement the size of the panels while pressing the arrow keys. |
|
|
150
|
+
| minSizes | InputSignal<number[]> | ... | Minimum size of the elements relative to 100%. |
|
|
151
|
+
| panelSizes | InputSignal<number[]> | ... | Size of the elements relative to 100%. |
|
|
152
|
+
|
|
153
|
+
### Emits
|
|
154
|
+
|
|
155
|
+
| Name | Parameters | Description |
|
|
156
|
+
|------|------------|-------------|
|
|
157
|
+
| onResizeEnd | event: SplitterResizeEndEvent | Callback to invoke when resize ends. |
|
|
158
|
+
| onResizeStart | event: SplitterResizeStartEvent | Callback to invoke when resize starts. |
|
|
159
|
+
|
|
160
|
+
## Pass Through Options
|
|
161
|
+
|
|
162
|
+
| Name | Type | Description |
|
|
163
|
+
|------|------|-------------|
|
|
164
|
+
| root | PassThroughOption<HTMLElement, I> | Used to pass attributes to the root's DOM element. |
|
|
165
|
+
| panel | PassThroughOption<HTMLDivElement, I> | Used to pass attributes to the panel's DOM element. |
|
|
166
|
+
| gutter | PassThroughOption<HTMLDivElement, I> | Used to pass attributes to the gutter's DOM element. |
|
|
167
|
+
| gutterHandle | PassThroughOption<HTMLDivElement, I> | Used to pass attributes to the gutter handle's DOM element. |
|
|
168
|
+
|
|
169
|
+
## Theming
|
|
170
|
+
|
|
171
|
+
### CSS Classes
|
|
172
|
+
|
|
173
|
+
| Class | Description |
|
|
174
|
+
|-------|-------------|
|
|
175
|
+
| p-splitter | Class name of the root element |
|
|
176
|
+
| p-splitter-gutter | Class name of the gutter element |
|
|
177
|
+
| p-splitter-gutter-handle | Class name of the gutter handle element |
|
|
178
|
+
|
|
179
|
+
### Design Tokens
|
|
180
|
+
|
|
181
|
+
| Token | CSS Variable | Description |
|
|
182
|
+
|-------|--------------|-------------|
|
|
183
|
+
| splitter.background | --p-splitter-background | Background of root |
|
|
184
|
+
| splitter.border.color | --p-splitter-border-color | Border color of root |
|
|
185
|
+
| splitter.color | --p-splitter-color | Color of root |
|
|
186
|
+
| splitter.transition.duration | --p-splitter-transition-duration | Transition duration of root |
|
|
187
|
+
| splitter.gutter.background | --p-splitter-gutter-background | Background of gutter |
|
|
188
|
+
| splitter.handle.size | --p-splitter-handle-size | Size of handle |
|
|
189
|
+
| splitter.handle.background | --p-splitter-handle-background | Background of handle |
|
|
190
|
+
| splitter.handle.border.radius | --p-splitter-handle-border-radius | Border radius of handle |
|
|
191
|
+
| splitter.handle.focus.ring.width | --p-splitter-handle-focus-ring-width | Focus ring width of handle |
|
|
192
|
+
| splitter.handle.focus.ring.style | --p-splitter-handle-focus-ring-style | Focus ring style of handle |
|
|
193
|
+
| splitter.handle.focus.ring.color | --p-splitter-handle-focus-ring-color | Focus ring color of handle |
|
|
194
|
+
| splitter.handle.focus.ring.offset | --p-splitter-handle-focus-ring-offset | Focus ring offset of handle |
|
|
195
|
+
| splitter.handle.focus.ring.shadow | --p-splitter-handle-focus-ring-shadow | Focus ring shadow of handle |
|
|
196
|
+
|
|
@@ -0,0 +1,411 @@
|
|
|
1
|
+
# Angular Stepper Component
|
|
2
|
+
|
|
3
|
+
The Stepper component displays a wizard-like workflow by guiding users through the multi-step progression.
|
|
4
|
+
|
|
5
|
+
## Accessibility
|
|
6
|
+
|
|
7
|
+
Screen Reader Stepper 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 Stepper. Each stepper header has a tab role and aria-controls to refer to the corresponding stepper content element. The content element of each stepper 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 stepper header. space Activates the focused stepper header.
|
|
8
|
+
|
|
9
|
+
## basic-doc
|
|
10
|
+
|
|
11
|
+
Stepper consists of a combination of StepList , Step , StepPanels and StepPanel components. The value property is essential for associating Step and StepPanel with each other.
|
|
12
|
+
|
|
13
|
+
```typescript
|
|
14
|
+
import { Component } from '@angular/core';
|
|
15
|
+
import { ButtonModule } from '@exhaustive-ui/core/button';
|
|
16
|
+
import { StepperModule } from '@exhaustive-ui/core/stepper';
|
|
17
|
+
|
|
18
|
+
@Component({
|
|
19
|
+
template: `
|
|
20
|
+
<div class="card flex justify-center">
|
|
21
|
+
<p-stepper [value]="1" class="basis-[50rem]">
|
|
22
|
+
<p-step-list>
|
|
23
|
+
<p-step [value]="1">Header I</p-step>
|
|
24
|
+
<p-step [value]="2">Header II</p-step>
|
|
25
|
+
<p-step [value]="3">Header II</p-step>
|
|
26
|
+
</p-step-list>
|
|
27
|
+
<p-step-panels>
|
|
28
|
+
<p-step-panel [value]="1">
|
|
29
|
+
<ng-template #content let-activateCallback="activateCallback">
|
|
30
|
+
<div class="flex flex-col h-48">
|
|
31
|
+
<div class="border-2 border-dashed border-surface-200 dark:border-surface-700 rounded bg-surface-50 dark:bg-surface-950 flex-auto flex justify-center items-center font-medium">Content I</div>
|
|
32
|
+
</div>
|
|
33
|
+
<div class="flex pt-6 justify-end">
|
|
34
|
+
<p-button label="Next" icon="pi pi-arrow-right" iconPos="right" (onClick)="activateCallback(2)" />
|
|
35
|
+
</div>
|
|
36
|
+
</ng-template>
|
|
37
|
+
</p-step-panel>
|
|
38
|
+
<p-step-panel [value]="2">
|
|
39
|
+
<ng-template #content let-activateCallback="activateCallback">
|
|
40
|
+
<div class="flex flex-col h-48">
|
|
41
|
+
<div class="border-2 border-dashed border-surface-200 dark:border-surface-700 rounded bg-surface-50 dark:bg-surface-950 flex-auto flex justify-center items-center font-medium">Content II</div>
|
|
42
|
+
</div>
|
|
43
|
+
<div class="flex pt-6 justify-between">
|
|
44
|
+
<p-button label="Back" severity="secondary" icon="pi pi-arrow-left" (onClick)="activateCallback(1)" />
|
|
45
|
+
<p-button label="Next" icon="pi pi-arrow-right" iconPos="right" (onClick)="activateCallback(3)" />
|
|
46
|
+
</div>
|
|
47
|
+
</ng-template>
|
|
48
|
+
</p-step-panel>
|
|
49
|
+
<p-step-panel [value]="3">
|
|
50
|
+
<ng-template #content let-activateCallback="activateCallback">
|
|
51
|
+
<div class="flex flex-col h-48">
|
|
52
|
+
<div class="border-2 border-dashed border-surface-200 dark:border-surface-700 rounded bg-surface-50 dark:bg-surface-950 flex-auto flex justify-center items-center font-medium">Content III</div>
|
|
53
|
+
</div>
|
|
54
|
+
<div class="flex pt-6 justify-start">
|
|
55
|
+
<p-button label="Back" icon="pi pi-arrow-left" iconPos="right" (onClick)="activateCallback(2)" />
|
|
56
|
+
</div>
|
|
57
|
+
</ng-template>
|
|
58
|
+
</p-step-panel>
|
|
59
|
+
</p-step-panels>
|
|
60
|
+
</p-stepper>
|
|
61
|
+
</div>
|
|
62
|
+
`,
|
|
63
|
+
standalone: true,
|
|
64
|
+
imports: [ButtonModule, StepperModule]
|
|
65
|
+
})
|
|
66
|
+
export class StepperBasicDemo {}
|
|
67
|
+
```
|
|
68
|
+
|
|
69
|
+
## Linear
|
|
70
|
+
|
|
71
|
+
When linear property is set to true, current step must be completed in order to move to the next step.
|
|
72
|
+
|
|
73
|
+
```typescript
|
|
74
|
+
import { Component } from '@angular/core';
|
|
75
|
+
import { ButtonModule } from '@exhaustive-ui/core/button';
|
|
76
|
+
import { StepperModule } from '@exhaustive-ui/core/stepper';
|
|
77
|
+
|
|
78
|
+
@Component({
|
|
79
|
+
template: `
|
|
80
|
+
<div class="card flex justify-center">
|
|
81
|
+
<p-stepper [value]="1" class="basis-[50rem]" [linear]="true">
|
|
82
|
+
<p-step-list>
|
|
83
|
+
<p-step [value]="1">Header I</p-step>
|
|
84
|
+
<p-step [value]="2">Header II</p-step>
|
|
85
|
+
<p-step [value]="3">Header II</p-step>
|
|
86
|
+
</p-step-list>
|
|
87
|
+
<p-step-panels>
|
|
88
|
+
<p-step-panel [value]="1">
|
|
89
|
+
<ng-template #content let-activateCallback="activateCallback">
|
|
90
|
+
<div class="flex flex-col h-48">
|
|
91
|
+
<div class="border-2 border-dashed border-surface-200 dark:border-surface-700 rounded bg-surface-50 dark:bg-surface-950 flex-auto flex justify-center items-center font-medium">Content I</div>
|
|
92
|
+
</div>
|
|
93
|
+
<div class="flex pt-6 justify-end">
|
|
94
|
+
<p-button label="Next" icon="pi pi-arrow-right" iconPos="right" (onClick)="activateCallback(2)" />
|
|
95
|
+
</div>
|
|
96
|
+
</ng-template>
|
|
97
|
+
</p-step-panel>
|
|
98
|
+
<p-step-panel [value]="2">
|
|
99
|
+
<ng-template #content let-activateCallback="activateCallback">
|
|
100
|
+
<div class="flex flex-col h-48">
|
|
101
|
+
<div class="border-2 border-dashed border-surface-200 dark:border-surface-700 rounded bg-surface-50 dark:bg-surface-950 flex-auto flex justify-center items-center font-medium">Content II</div>
|
|
102
|
+
</div>
|
|
103
|
+
<div class="flex pt-6 justify-between">
|
|
104
|
+
<p-button label="Back" severity="secondary" icon="pi pi-arrow-left" (onClick)="activateCallback(1)" />
|
|
105
|
+
<p-button label="Next" icon="pi pi-arrow-right" iconPos="right" (onClick)="activateCallback(3)" />
|
|
106
|
+
</div>
|
|
107
|
+
</ng-template>
|
|
108
|
+
</p-step-panel>
|
|
109
|
+
<p-step-panel [value]="3">
|
|
110
|
+
<ng-template #content let-activateCallback="activateCallback">
|
|
111
|
+
<div class="flex flex-col h-48">
|
|
112
|
+
<div class="border-2 border-dashed border-surface-200 dark:border-surface-700 rounded bg-surface-50 dark:bg-surface-950 flex-auto flex justify-center items-center font-medium">Content III</div>
|
|
113
|
+
</div>
|
|
114
|
+
<div class="flex pt-6 justify-start">
|
|
115
|
+
<p-button label="Back" icon="pi pi-arrow-left" iconPos="right" (onClick)="activateCallback(2)" />
|
|
116
|
+
</div>
|
|
117
|
+
</ng-template>
|
|
118
|
+
</p-step-panel>
|
|
119
|
+
</p-step-panels>
|
|
120
|
+
</p-stepper>
|
|
121
|
+
</div>
|
|
122
|
+
`,
|
|
123
|
+
standalone: true,
|
|
124
|
+
imports: [ButtonModule, StepperModule]
|
|
125
|
+
})
|
|
126
|
+
export class StepperLinearDemo {}
|
|
127
|
+
```
|
|
128
|
+
|
|
129
|
+
## stepsonly
|
|
130
|
+
|
|
131
|
+
Use Stepper with a StepList only for custom requirements where a progress indicator is needed.
|
|
132
|
+
|
|
133
|
+
## Template
|
|
134
|
+
|
|
135
|
+
Stepper provides various templating options to customize the default UI design.
|
|
136
|
+
|
|
137
|
+
```typescript
|
|
138
|
+
import { Component } from '@angular/core';
|
|
139
|
+
import { FormsModule } from '@angular/forms';
|
|
140
|
+
import { ButtonModule } from '@exhaustive-ui/core/button';
|
|
141
|
+
import { PasswordModule } from '@exhaustive-ui/core/password';
|
|
142
|
+
import { StepperModule } from '@exhaustive-ui/core/stepper';
|
|
143
|
+
import { ToggleButtonModule } from '@exhaustive-ui/core/togglebutton';
|
|
144
|
+
import { InputTextModule } from '@exhaustive-ui/core/inputtext';
|
|
145
|
+
|
|
146
|
+
@Component({
|
|
147
|
+
template: `
|
|
148
|
+
<div class="card flex justify-center">
|
|
149
|
+
<p-stepper [(value)]="activeStep" class="basis-[40rem]">
|
|
150
|
+
<p-step-list>
|
|
151
|
+
<p-step [value]="1" class="flex flex-row flex-auto gap-2">
|
|
152
|
+
<ng-template #content let-activateCallback="activateCallback" let-value="value">
|
|
153
|
+
<button class="bg-transparent border-0 inline-flex flex-col gap-2" (click)="activateCallback()">
|
|
154
|
+
<span
|
|
155
|
+
class="rounded-full border-2 w-12 h-12 inline-flex items-center justify-center"
|
|
156
|
+
[ngClass]="{
|
|
157
|
+
'bg-primary text-primary-contrast border-primary': value <= activeStep,
|
|
158
|
+
'border-surface': value > activeStep
|
|
159
|
+
}"
|
|
160
|
+
>
|
|
161
|
+
<i class="pi pi-user"></i>
|
|
162
|
+
</span>
|
|
163
|
+
</button>
|
|
164
|
+
</ng-template>
|
|
165
|
+
</p-step>
|
|
166
|
+
<p-step [value]="2" class="flex flex-row flex-auto gap-2">
|
|
167
|
+
<ng-template #content let-activateCallback="activateCallback" let-value="value">
|
|
168
|
+
<button class="bg-transparent border-0 inline-flex flex-col gap-2" (click)="activateCallback()">
|
|
169
|
+
<span
|
|
170
|
+
class="rounded-full border-2 w-12 h-12 inline-flex items-center justify-center"
|
|
171
|
+
[ngClass]="{
|
|
172
|
+
'bg-primary text-primary-contrast border-primary': value <= activeStep,
|
|
173
|
+
'border-surface': value > activeStep
|
|
174
|
+
}"
|
|
175
|
+
>
|
|
176
|
+
<i class="pi pi-star"></i>
|
|
177
|
+
</span>
|
|
178
|
+
</button>
|
|
179
|
+
</ng-template>
|
|
180
|
+
</p-step>
|
|
181
|
+
<p-step [value]="3" class="flex flex-row flex-auto gap-2">
|
|
182
|
+
<ng-template #content let-activateCallback="activateCallback" let-value="value">
|
|
183
|
+
<button class="bg-transparent border-0 inline-flex flex-col gap-2" (click)="activateCallback()">
|
|
184
|
+
<span
|
|
185
|
+
class="rounded-full border-2 w-12 h-12 inline-flex items-center justify-center"
|
|
186
|
+
[ngClass]="{
|
|
187
|
+
'bg-primary text-primary-contrast border-primary': value <= activeStep,
|
|
188
|
+
'border-surface': value > activeStep
|
|
189
|
+
}"
|
|
190
|
+
>
|
|
191
|
+
<i class="pi pi-id-card"></i>
|
|
192
|
+
</span>
|
|
193
|
+
</button>
|
|
194
|
+
</ng-template>
|
|
195
|
+
</p-step>
|
|
196
|
+
</p-step-list>
|
|
197
|
+
<p-step-panels>
|
|
198
|
+
<p-step-panel [value]="1">
|
|
199
|
+
<ng-template #content let-activateCallback="activateCallback">
|
|
200
|
+
<div class="flex flex-col gap-2 mx-auto" style="min-height: 16rem; max-width: 20rem">
|
|
201
|
+
<div class="text-center mt-4 mb-4 text-xl font-semibold">Create your account</div>
|
|
202
|
+
<div class="field">
|
|
203
|
+
<input [(ngModel)]="name" pInputText id="input" type="text" placeholder="Name" fluid />
|
|
204
|
+
</div>
|
|
205
|
+
<div class="field">
|
|
206
|
+
<input [(ngModel)]="email" pInputText id="email" type="email" placeholder="Email" fluid />
|
|
207
|
+
</div>
|
|
208
|
+
<div class="field">
|
|
209
|
+
<p-password [(ngModel)]="password" placeholder="Password" fluid />
|
|
210
|
+
</div>
|
|
211
|
+
</div>
|
|
212
|
+
<div class="flex pt-6 justify-end">
|
|
213
|
+
<p-button (onClick)="activateCallback(2)" label="Next" icon="pi pi-arrow-right" iconPos="right" />
|
|
214
|
+
</div>
|
|
215
|
+
</ng-template>
|
|
216
|
+
</p-step-panel>
|
|
217
|
+
<p-step-panel [value]="2">
|
|
218
|
+
<ng-template #content let-activateCallback="activateCallback">
|
|
219
|
+
<div class="flex flex-col gap-2 mx-auto" style="min-height: 16rem; max-width: 24rem">
|
|
220
|
+
<div class="text-center mt-4 mb-4 text-xl font-semibold">Choose your interests</div>
|
|
221
|
+
<div class="flex flex-wrap justify-center gap-4">
|
|
222
|
+
<p-togglebutton [(ngModel)]="option1" onLabel="Nature" offLabel="Nature" />
|
|
223
|
+
<p-togglebutton [(ngModel)]="option2" onLabel="Art" offLabel="Art" />
|
|
224
|
+
<p-togglebutton [(ngModel)]="option3" onLabel="Music" offLabel="Music" />
|
|
225
|
+
<p-togglebutton [(ngModel)]="option4" onLabel="Design" offLabel="Design" />
|
|
226
|
+
<p-togglebutton [(ngModel)]="option5" onLabel="Photography" offLabel="Photography" />
|
|
227
|
+
<p-togglebutton [(ngModel)]="option6" onLabel="Movies" offLabel="Movies" />
|
|
228
|
+
<p-togglebutton [(ngModel)]="option7" onLabel="Sports" offLabel="Sports" />
|
|
229
|
+
<p-togglebutton [(ngModel)]="option8" onLabel="Gaming" offLabel="Gaming" />
|
|
230
|
+
<p-togglebutton [(ngModel)]="option9" onLabel="Traveling" offLabel="Traveling" />
|
|
231
|
+
<p-togglebutton [(ngModel)]="option10" onLabel="Dancing" offLabel="Dancing" />
|
|
232
|
+
</div>
|
|
233
|
+
</div>
|
|
234
|
+
<div class="flex pt-6 justify-between">
|
|
235
|
+
<p-button (onClick)="activateCallback(1)" label="Back" severity="secondary" icon="pi pi-arrow-left" />
|
|
236
|
+
<p-button (onClick)="activateCallback(3)" label="Next" icon="pi pi-arrow-right" iconPos="right" />
|
|
237
|
+
</div>
|
|
238
|
+
</ng-template>
|
|
239
|
+
</p-step-panel>
|
|
240
|
+
<p-step-panel [value]="3">
|
|
241
|
+
<ng-template #content let-activateCallback="activateCallback">
|
|
242
|
+
<div class="flex flex-col items-center gap-2 mx-auto" style="min-height: 16rem; max-width: 24rem">
|
|
243
|
+
<div class="text-center mt-4 mb-4 text-xl font-semibold">Account created successfully</div>
|
|
244
|
+
<div class="text-center">
|
|
245
|
+
<img alt="logo" src="https://exhaustive-ui.e-xiste.com/demo/stepper/content.svg" />
|
|
246
|
+
</div>
|
|
247
|
+
</div>
|
|
248
|
+
<div class="flex pt-6 justify-start">
|
|
249
|
+
<p-button (onClick)="activateCallback(2)" label="Back" severity="secondary" icon="pi pi-arrow-left" />
|
|
250
|
+
</div>
|
|
251
|
+
</ng-template>
|
|
252
|
+
</p-step-panel>
|
|
253
|
+
</p-step-panels>
|
|
254
|
+
</p-stepper>
|
|
255
|
+
</div>
|
|
256
|
+
`,
|
|
257
|
+
standalone: true,
|
|
258
|
+
imports: [ButtonModule, PasswordModule, StepperModule, ToggleButtonModule, InputTextModule, FormsModule]
|
|
259
|
+
})
|
|
260
|
+
export class StepperTemplateDemo {
|
|
261
|
+
activeStep: number = 1;
|
|
262
|
+
name: string | undefined = null;
|
|
263
|
+
email: string | undefined = null;
|
|
264
|
+
password: string | undefined = null;
|
|
265
|
+
option1: boolean | undefined = false;
|
|
266
|
+
option2: boolean | undefined = false;
|
|
267
|
+
option3: boolean | undefined = false;
|
|
268
|
+
option4: boolean | undefined = false;
|
|
269
|
+
option5: boolean | undefined = false;
|
|
270
|
+
option6: boolean | undefined = false;
|
|
271
|
+
option7: boolean | undefined = false;
|
|
272
|
+
option8: boolean | undefined = false;
|
|
273
|
+
option9: boolean | undefined = false;
|
|
274
|
+
option10: boolean | undefined = false;
|
|
275
|
+
}
|
|
276
|
+
```
|
|
277
|
+
|
|
278
|
+
## Vertical
|
|
279
|
+
|
|
280
|
+
Vertical layout requires StepItem as a wrapper of Step and StepPanel components.
|
|
281
|
+
|
|
282
|
+
```typescript
|
|
283
|
+
import { Component } from '@angular/core';
|
|
284
|
+
import { ButtonModule } from '@exhaustive-ui/core/button';
|
|
285
|
+
import { StepperModule } from '@exhaustive-ui/core/stepper';
|
|
286
|
+
|
|
287
|
+
@Component({
|
|
288
|
+
template: `
|
|
289
|
+
<div class="card">
|
|
290
|
+
<p-stepper [value]="1">
|
|
291
|
+
<p-step-item [value]="1">
|
|
292
|
+
<p-step>Header I</p-step>
|
|
293
|
+
<p-step-panel>
|
|
294
|
+
<ng-template #content let-activateCallback="activateCallback">
|
|
295
|
+
<div class="flex flex-col h-48">
|
|
296
|
+
<div class="border-2 border-dashed border-surface-200 dark:border-surface-700 rounded bg-surface-50 dark:bg-surface-950 flex-auto flex justify-center items-center font-medium">Content I</div>
|
|
297
|
+
</div>
|
|
298
|
+
<div class="py-6">
|
|
299
|
+
<p-button label="Next" (onClick)="activateCallback(2)" />
|
|
300
|
+
</div>
|
|
301
|
+
</ng-template>
|
|
302
|
+
</p-step-panel>
|
|
303
|
+
</p-step-item>
|
|
304
|
+
<p-step-item [value]="2">
|
|
305
|
+
<p-step>Header II</p-step>
|
|
306
|
+
<p-step-panel>
|
|
307
|
+
<ng-template #content let-activateCallback="activateCallback">
|
|
308
|
+
<div class="flex flex-col h-48">
|
|
309
|
+
<div class="border-2 border-dashed border-surface-200 dark:border-surface-700 rounded bg-surface-50 dark:bg-surface-950 flex-auto flex justify-center items-center font-medium">Content II</div>
|
|
310
|
+
</div>
|
|
311
|
+
<div class="flex py-6 gap-2">
|
|
312
|
+
<p-button label="Back" severity="secondary" (onClick)="activateCallback(1)" />
|
|
313
|
+
<p-button label="Next" (onClick)="activateCallback(3)" />
|
|
314
|
+
</div>
|
|
315
|
+
</ng-template>
|
|
316
|
+
</p-step-panel>
|
|
317
|
+
</p-step-item>
|
|
318
|
+
<p-step-item [value]="3">
|
|
319
|
+
<p-step>Header III</p-step>
|
|
320
|
+
<p-step-panel>
|
|
321
|
+
<ng-template #content let-activateCallback="activateCallback">
|
|
322
|
+
<div class="flex flex-col h-48">
|
|
323
|
+
<div class="border-2 border-dashed border-surface-200 dark:border-surface-700 rounded bg-surface-50 dark:bg-surface-950 flex-auto flex justify-center items-center font-medium">Content III</div>
|
|
324
|
+
</div>
|
|
325
|
+
<div class="py-6">
|
|
326
|
+
<p-button label="Back" severity="secondary" (onClick)="activateCallback(2)" />
|
|
327
|
+
</div>
|
|
328
|
+
</ng-template>
|
|
329
|
+
</p-step-panel>
|
|
330
|
+
</p-step-item>
|
|
331
|
+
</p-stepper>
|
|
332
|
+
</div>
|
|
333
|
+
`,
|
|
334
|
+
standalone: true,
|
|
335
|
+
imports: [ButtonModule, StepperModule]
|
|
336
|
+
})
|
|
337
|
+
export class StepperVerticalDemo {}
|
|
338
|
+
```
|
|
339
|
+
|
|
340
|
+
## Stepper
|
|
341
|
+
|
|
342
|
+
Stepper is a component that streamlines a wizard-like workflow, organizing content into coherent steps and visually guiding users through a numbered progression in a multistep process.
|
|
343
|
+
|
|
344
|
+
### Props
|
|
345
|
+
|
|
346
|
+
| Name | Type | Default | Description |
|
|
347
|
+
|------|------|---------|-------------|
|
|
348
|
+
| dt | InputSignal<Object> | undefined | Defines scoped design tokens of the component. |
|
|
349
|
+
| unstyled | InputSignal<boolean> | undefined | Indicates whether the component should be rendered without styles. |
|
|
350
|
+
| pt | InputSignal<StepperPassThrough> | undefined | Used to pass attributes to DOM elements inside the component. |
|
|
351
|
+
| ptOptions | InputSignal<PassThroughOptions> | undefined | Used to configure passthrough(pt) options of the component. |
|
|
352
|
+
| value | ModelSignal<number> | undefined | A model that can hold a numeric value or be undefined. |
|
|
353
|
+
| linear | InputSignalWithTransform<any, boolean> | false | A boolean variable that captures user input. |
|
|
354
|
+
| transitionOptions | InputSignal<string> | 400ms cubic-bezier(0.86, 0, 0.07, 1) | Transition options of the animation. **(Deprecated)** |
|
|
355
|
+
| motionOptions | InputSignal<MotionOptions> | ... | The motion options. |
|
|
356
|
+
|
|
357
|
+
## Pass Through Options
|
|
358
|
+
|
|
359
|
+
| Name | Type | Description |
|
|
360
|
+
|------|------|-------------|
|
|
361
|
+
| root | PassThroughOption<HTMLElement, I> | Used to pass attributes to the root's DOM element. |
|
|
362
|
+
| motion | MotionOptions | Used to pass options to the motion component/directive. |
|
|
363
|
+
|
|
364
|
+
## Theming
|
|
365
|
+
|
|
366
|
+
### CSS Classes
|
|
367
|
+
|
|
368
|
+
| Class | Description |
|
|
369
|
+
|-------|-------------|
|
|
370
|
+
| p-stepper | Class name of the root element |
|
|
371
|
+
| p-stepper-separator | Class name of the separator element |
|
|
372
|
+
|
|
373
|
+
### Design Tokens
|
|
374
|
+
|
|
375
|
+
| Token | CSS Variable | Description |
|
|
376
|
+
|-------|--------------|-------------|
|
|
377
|
+
| stepper.transition.duration | --p-stepper-transition-duration | Transition duration of root |
|
|
378
|
+
| stepper.separator.background | --p-stepper-separator-background | Background of separator |
|
|
379
|
+
| stepper.separator.active.background | --p-stepper-separator-active-background | Active background of separator |
|
|
380
|
+
| stepper.separator.margin | --p-stepper-separator-margin | Margin of separator |
|
|
381
|
+
| stepper.separator.size | --p-stepper-separator-size | Size of separator |
|
|
382
|
+
| stepper.step.padding | --p-stepper-step-padding | Padding of step |
|
|
383
|
+
| stepper.step.gap | --p-stepper-step-gap | Gap of step |
|
|
384
|
+
| stepper.step.header.padding | --p-stepper-step-header-padding | Padding of step header |
|
|
385
|
+
| stepper.step.header.border.radius | --p-stepper-step-header-border-radius | Border radius of step header |
|
|
386
|
+
| stepper.step.header.focus.ring.width | --p-stepper-step-header-focus-ring-width | Focus ring width of step header |
|
|
387
|
+
| stepper.step.header.focus.ring.style | --p-stepper-step-header-focus-ring-style | Focus ring style of step header |
|
|
388
|
+
| stepper.step.header.focus.ring.color | --p-stepper-step-header-focus-ring-color | Focus ring color of step header |
|
|
389
|
+
| stepper.step.header.focus.ring.offset | --p-stepper-step-header-focus-ring-offset | Focus ring offset of step header |
|
|
390
|
+
| stepper.step.header.focus.ring.shadow | --p-stepper-step-header-focus-ring-shadow | Focus ring shadow of step header |
|
|
391
|
+
| stepper.step.header.gap | --p-stepper-step-header-gap | Gap of step header |
|
|
392
|
+
| stepper.step.title.color | --p-stepper-step-title-color | Color of step title |
|
|
393
|
+
| stepper.step.title.active.color | --p-stepper-step-title-active-color | Active color of step title |
|
|
394
|
+
| stepper.step.title.font.weight | --p-stepper-step-title-font-weight | Font weight of step title |
|
|
395
|
+
| stepper.step.number.background | --p-stepper-step-number-background | Background of step number |
|
|
396
|
+
| stepper.step.number.active.background | --p-stepper-step-number-active-background | Active background of step number |
|
|
397
|
+
| stepper.step.number.border.color | --p-stepper-step-number-border-color | Border color of step number |
|
|
398
|
+
| stepper.step.number.active.border.color | --p-stepper-step-number-active-border-color | Active border color of step number |
|
|
399
|
+
| stepper.step.number.color | --p-stepper-step-number-color | Color of step number |
|
|
400
|
+
| stepper.step.number.active.color | --p-stepper-step-number-active-color | Active color of step number |
|
|
401
|
+
| stepper.step.number.size | --p-stepper-step-number-size | Size of step number |
|
|
402
|
+
| stepper.step.number.font.size | --p-stepper-step-number-font-size | Font size of step number |
|
|
403
|
+
| stepper.step.number.font.weight | --p-stepper-step-number-font-weight | Font weight of step number |
|
|
404
|
+
| stepper.step.number.border.radius | --p-stepper-step-number-border-radius | Border radius of step number |
|
|
405
|
+
| stepper.step.number.shadow | --p-stepper-step-number-shadow | Shadow of step number |
|
|
406
|
+
| stepper.steppanels.padding | --p-stepper-steppanels-padding | Padding of steppanels |
|
|
407
|
+
| stepper.steppanel.background | --p-stepper-steppanel-background | Background of steppanel |
|
|
408
|
+
| stepper.steppanel.color | --p-stepper-steppanel-color | Color of steppanel |
|
|
409
|
+
| stepper.steppanel.padding | --p-stepper-steppanel-padding | Padding of steppanel |
|
|
410
|
+
| stepper.steppanel.indent | --p-stepper-steppanel-indent | Indent of steppanel |
|
|
411
|
+
|