@pecb-ui/components 1.1.2

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 (56) hide show
  1. package/README.md +556 -0
  2. package/esm2022/lib/components/button/button.component.mjs +171 -0
  3. package/esm2022/lib/components/card/card.component.mjs +182 -0
  4. package/esm2022/lib/components/checkbox/checkbox.component.mjs +126 -0
  5. package/esm2022/lib/components/datepicker/datepicker.component.mjs +349 -0
  6. package/esm2022/lib/components/dropdown/dropdown.component.mjs +329 -0
  7. package/esm2022/lib/components/input/input.component.mjs +321 -0
  8. package/esm2022/lib/components/pagination/pagination.component.mjs +197 -0
  9. package/esm2022/lib/components/radio/radio.component.mjs +147 -0
  10. package/esm2022/lib/components/right-modal/right-modal.component.mjs +234 -0
  11. package/esm2022/lib/components/sidebar/sidebar.component.mjs +155 -0
  12. package/esm2022/lib/components/status/status.component.mjs +50 -0
  13. package/esm2022/lib/components/tab/tab.component.mjs +151 -0
  14. package/esm2022/lib/components/table/table.component.mjs +503 -0
  15. package/esm2022/lib/components/toggle/toggle.component.mjs +126 -0
  16. package/esm2022/lib/pecb-components.module.mjs +118 -0
  17. package/esm2022/lib/services/loading.service.mjs +182 -0
  18. package/esm2022/lib/services/notification.service.mjs +144 -0
  19. package/esm2022/lib/services/theme.service.mjs +232 -0
  20. package/esm2022/lib/shared/interfaces/component.interfaces.mjs +2 -0
  21. package/esm2022/lib/shared/types/common.types.mjs +6 -0
  22. package/esm2022/lib/shared/utils/accessibility.utils.mjs +223 -0
  23. package/esm2022/lib/shared/utils/dom.utils.mjs +240 -0
  24. package/esm2022/lib/shared/utils/error.utils.mjs +277 -0
  25. package/esm2022/lib/shared/utils/string.utils.mjs +204 -0
  26. package/esm2022/pecb-ui-components.mjs +5 -0
  27. package/esm2022/public-api.mjs +53 -0
  28. package/fesm2022/pecb-ui-components.mjs +4587 -0
  29. package/fesm2022/pecb-ui-components.mjs.map +1 -0
  30. package/index.d.ts +5 -0
  31. package/lib/components/button/button.component.d.ts +130 -0
  32. package/lib/components/card/card.component.d.ts +140 -0
  33. package/lib/components/checkbox/checkbox.component.d.ts +74 -0
  34. package/lib/components/datepicker/datepicker.component.d.ts +155 -0
  35. package/lib/components/dropdown/dropdown.component.d.ts +144 -0
  36. package/lib/components/input/input.component.d.ts +215 -0
  37. package/lib/components/pagination/pagination.component.d.ts +53 -0
  38. package/lib/components/radio/radio.component.d.ts +93 -0
  39. package/lib/components/right-modal/right-modal.component.d.ts +137 -0
  40. package/lib/components/sidebar/sidebar.component.d.ts +97 -0
  41. package/lib/components/status/status.component.d.ts +19 -0
  42. package/lib/components/tab/tab.component.d.ts +102 -0
  43. package/lib/components/table/table.component.d.ts +403 -0
  44. package/lib/components/toggle/toggle.component.d.ts +74 -0
  45. package/lib/pecb-components.module.d.ts +37 -0
  46. package/lib/services/loading.service.d.ts +129 -0
  47. package/lib/services/notification.service.d.ts +136 -0
  48. package/lib/services/theme.service.d.ts +142 -0
  49. package/lib/shared/interfaces/component.interfaces.d.ts +283 -0
  50. package/lib/shared/types/common.types.d.ts +86 -0
  51. package/lib/shared/utils/accessibility.utils.d.ts +167 -0
  52. package/lib/shared/utils/dom.utils.d.ts +108 -0
  53. package/lib/shared/utils/error.utils.d.ts +191 -0
  54. package/lib/shared/utils/string.utils.d.ts +144 -0
  55. package/package.json +61 -0
  56. package/public-api.d.ts +24 -0
@@ -0,0 +1,215 @@
1
+ import { EventEmitter, ElementRef, ChangeDetectorRef } from '@angular/core';
2
+ import { DomSanitizer, SafeHtml } from '@angular/platform-browser';
3
+ import { ControlValueAccessor } from '@angular/forms';
4
+ import * as i0 from "@angular/core";
5
+ export type InputType = 'text' | 'email' | 'password' | 'number' | 'tel' | 'url' | 'search';
6
+ export type InputSize = 'sm' | 'md' | 'lg';
7
+ /**
8
+ * A professional input component with floating label and multiple types.
9
+ * Fully accessible with WCAG 2.1 AA compliance and reactive forms support.
10
+ *
11
+ * @example
12
+ * ```html
13
+ * <pecb-input
14
+ * label="Email"
15
+ * type="email"
16
+ * placeholder="Enter your email"
17
+ * [(ngModel)]="email"
18
+ * ></pecb-input>
19
+ *
20
+ * <!-- With predefined icon -->
21
+ * <pecb-input
22
+ * label="Email"
23
+ * type="email"
24
+ * icon="email"
25
+ * iconPosition="left"
26
+ * ></pecb-input>
27
+ *
28
+ * <!-- With custom SVG icon -->
29
+ * <pecb-input
30
+ * label="Phone"
31
+ * type="tel"
32
+ * [icon]="'<svg>...</svg>'"
33
+ * iconPosition="left"
34
+ * ></pecb-input>
35
+ *
36
+ * <!-- With error state -->
37
+ * <pecb-input
38
+ * label="Password"
39
+ * type="password"
40
+ * [error]="true"
41
+ * errorMessage="Password is required"
42
+ * ></pecb-input>
43
+ * ```
44
+ *
45
+ * @publicApi
46
+ */
47
+ export declare class InputComponent implements ControlValueAccessor {
48
+ private cdr;
49
+ private sanitizer;
50
+ inputElement?: ElementRef<HTMLInputElement>;
51
+ /**
52
+ * Unique ID for the input element
53
+ */
54
+ id: string;
55
+ /**
56
+ * Input type
57
+ */
58
+ type: InputType;
59
+ /**
60
+ * Label text to display
61
+ */
62
+ label?: string;
63
+ /**
64
+ * Placeholder text (shown when label is not present)
65
+ */
66
+ placeholder: string;
67
+ /**
68
+ * The size of the input
69
+ */
70
+ size: InputSize;
71
+ /**
72
+ * Whether the field is required
73
+ */
74
+ required: boolean;
75
+ /**
76
+ * Whether the input is disabled
77
+ */
78
+ disabled: boolean;
79
+ /**
80
+ * Whether the input is readonly
81
+ */
82
+ readonly: boolean;
83
+ /**
84
+ * Whether to show error state
85
+ */
86
+ error: boolean;
87
+ /**
88
+ * Error message to display
89
+ */
90
+ errorMessage?: string;
91
+ /**
92
+ * Helper text to display below input
93
+ */
94
+ helperText?: string;
95
+ /**
96
+ * Icon to display - can be a predefined name ('email', 'search', 'user') or custom SVG string
97
+ */
98
+ icon?: string;
99
+ /**
100
+ * Icon position (left or right)
101
+ */
102
+ iconPosition: 'left' | 'right';
103
+ /**
104
+ * Left icon name or HTML (deprecated - use icon with iconPosition instead)
105
+ */
106
+ leftIcon?: string;
107
+ /**
108
+ * Right icon name or HTML (deprecated - use icon with iconPosition instead)
109
+ */
110
+ rightIcon?: string;
111
+ /**
112
+ * Whether to show clear button
113
+ */
114
+ clearable: boolean;
115
+ /**
116
+ * Maximum length of input
117
+ */
118
+ maxLength?: number;
119
+ /**
120
+ * Minimum value (for number type)
121
+ */
122
+ min?: number;
123
+ /**
124
+ * Maximum value (for number type)
125
+ */
126
+ max?: number;
127
+ /**
128
+ * Step value (for number type)
129
+ */
130
+ step?: number;
131
+ /**
132
+ * Autocomplete attribute
133
+ */
134
+ autocomplete?: string;
135
+ /**
136
+ * Event emitted when value changes
137
+ */
138
+ valueChange: EventEmitter<string>;
139
+ /**
140
+ * Event emitted on blur
141
+ */
142
+ blurred: EventEmitter<void>;
143
+ /**
144
+ * Event emitted on focus
145
+ */
146
+ focused: EventEmitter<void>;
147
+ /**
148
+ * Event emitted when clear button is clicked
149
+ */
150
+ cleared: EventEmitter<void>;
151
+ value: string;
152
+ isFocused: boolean;
153
+ showPassword: boolean;
154
+ private onChange;
155
+ private onTouched;
156
+ constructor(cdr: ChangeDetectorRef, sanitizer: DomSanitizer);
157
+ /**
158
+ * Get CSS classes for the input wrapper
159
+ */
160
+ get wrapperClasses(): string[];
161
+ /**
162
+ * Get the actual input type (handles password visibility toggle)
163
+ */
164
+ get inputType(): string;
165
+ /**
166
+ * Check if clear button should be shown
167
+ */
168
+ get showClearButton(): boolean;
169
+ /**
170
+ * Check if password toggle should be shown
171
+ */
172
+ get showPasswordToggle(): boolean;
173
+ /**
174
+ * Get computed left icon
175
+ */
176
+ get computedLeftIcon(): string | undefined;
177
+ /**
178
+ * Get computed right icon
179
+ */
180
+ get computedRightIcon(): string | undefined;
181
+ /**
182
+ * Handle input change
183
+ */
184
+ onInput(event: Event): void;
185
+ /**
186
+ * Handle focus event
187
+ */
188
+ onFocus(): void;
189
+ /**
190
+ * Handle blur event
191
+ */
192
+ onBlur(): void;
193
+ /**
194
+ * Clear input value
195
+ */
196
+ clearValue(event: MouseEvent): void;
197
+ /**
198
+ * Toggle password visibility
199
+ */
200
+ togglePasswordVisibility(event: MouseEvent): void;
201
+ /**
202
+ * Focus the input
203
+ */
204
+ focus(): void;
205
+ /**
206
+ * Sanitize custom icon HTML/SVG
207
+ */
208
+ sanitizeIcon(icon: string | undefined): SafeHtml;
209
+ writeValue(value: string): void;
210
+ registerOnChange(fn: (value: string) => void): void;
211
+ registerOnTouched(fn: () => void): void;
212
+ setDisabledState(isDisabled: boolean): void;
213
+ static ɵfac: i0.ɵɵFactoryDeclaration<InputComponent, never>;
214
+ static ɵcmp: i0.ɵɵComponentDeclaration<InputComponent, "pecb-input", never, { "id": { "alias": "id"; "required": false; }; "type": { "alias": "type"; "required": false; }; "label": { "alias": "label"; "required": false; }; "placeholder": { "alias": "placeholder"; "required": false; }; "size": { "alias": "size"; "required": false; }; "required": { "alias": "required"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; "readonly": { "alias": "readonly"; "required": false; }; "error": { "alias": "error"; "required": false; }; "errorMessage": { "alias": "errorMessage"; "required": false; }; "helperText": { "alias": "helperText"; "required": false; }; "icon": { "alias": "icon"; "required": false; }; "iconPosition": { "alias": "iconPosition"; "required": false; }; "leftIcon": { "alias": "leftIcon"; "required": false; }; "rightIcon": { "alias": "rightIcon"; "required": false; }; "clearable": { "alias": "clearable"; "required": false; }; "maxLength": { "alias": "maxLength"; "required": false; }; "min": { "alias": "min"; "required": false; }; "max": { "alias": "max"; "required": false; }; "step": { "alias": "step"; "required": false; }; "autocomplete": { "alias": "autocomplete"; "required": false; }; }, { "valueChange": "valueChange"; "blurred": "blurred"; "focused": "focused"; "cleared": "cleared"; }, never, never, true, never>;
215
+ }
@@ -0,0 +1,53 @@
1
+ import { EventEmitter, OnChanges, SimpleChanges, ElementRef } from '@angular/core';
2
+ import * as i0 from "@angular/core";
3
+ export type PaginationSize = 'sm' | 'md' | 'lg';
4
+ export type PaginationVariant = 'full' | 'compact' | 'minimal' | 'centered';
5
+ export interface PageChangeEvent {
6
+ page: number;
7
+ pageSize: number;
8
+ startIndex: number;
9
+ endIndex: number;
10
+ }
11
+ export declare class PaginationComponent implements OnChanges {
12
+ private elementRef;
13
+ totalItems: number;
14
+ pageSize: number;
15
+ currentPage: number;
16
+ pageSizeOptions: number[];
17
+ size: PaginationSize;
18
+ variant: PaginationVariant;
19
+ showPageSizeSelector: boolean;
20
+ showItemsInfo: boolean;
21
+ maxVisiblePages: number;
22
+ disabled: boolean;
23
+ ariaLabel: string;
24
+ pageChange: EventEmitter<PageChangeEvent>;
25
+ pageSizeChange: EventEmitter<number>;
26
+ totalPages: number;
27
+ visiblePages: (number | string)[];
28
+ isDropdownOpen: boolean;
29
+ constructor(elementRef: ElementRef);
30
+ onDocumentClick(event: MouseEvent): void;
31
+ ngOnChanges(changes: SimpleChanges): void;
32
+ get containerClasses(): string[];
33
+ get showPages(): boolean;
34
+ get showPageSize(): boolean;
35
+ get itemsInfoText(): string;
36
+ get startIndex(): number;
37
+ get endIndex(): number;
38
+ get canGoPrevious(): boolean;
39
+ get canGoNext(): boolean;
40
+ private calculateTotalPages;
41
+ private updateVisiblePages;
42
+ goToPage(page: number): void;
43
+ goToPrevious(): void;
44
+ goToNext(): void;
45
+ onPageSizeChange(newSize: number): void;
46
+ toggleDropdown(): void;
47
+ closeDropdown(): void;
48
+ private emitPageChange;
49
+ isNumber(value: number | string): boolean;
50
+ trackByPage(index: number, page: number | string): number | string;
51
+ static ɵfac: i0.ɵɵFactoryDeclaration<PaginationComponent, never>;
52
+ static ɵcmp: i0.ɵɵComponentDeclaration<PaginationComponent, "pecb-pagination", never, { "totalItems": { "alias": "totalItems"; "required": false; }; "pageSize": { "alias": "pageSize"; "required": false; }; "currentPage": { "alias": "currentPage"; "required": false; }; "pageSizeOptions": { "alias": "pageSizeOptions"; "required": false; }; "size": { "alias": "size"; "required": false; }; "variant": { "alias": "variant"; "required": false; }; "showPageSizeSelector": { "alias": "showPageSizeSelector"; "required": false; }; "showItemsInfo": { "alias": "showItemsInfo"; "required": false; }; "maxVisiblePages": { "alias": "maxVisiblePages"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; "ariaLabel": { "alias": "aria-label"; "required": false; }; }, { "pageChange": "pageChange"; "pageSizeChange": "pageSizeChange"; }, never, never, true, never>;
53
+ }
@@ -0,0 +1,93 @@
1
+ import { EventEmitter, ChangeDetectorRef } from '@angular/core';
2
+ import { ControlValueAccessor } from '@angular/forms';
3
+ import * as i0 from "@angular/core";
4
+ export type RadioVariant = 'dot' | 'filled';
5
+ export type RadioLabelPosition = 'right' | 'left';
6
+ /**
7
+ * A professional radio button component with label and description support.
8
+ * Fully accessible with WCAG 2.1 AA compliance and reactive forms support.
9
+ *
10
+ * @example
11
+ * ```html
12
+ * <!-- Default variant with inner dot -->
13
+ * <pecb-radio
14
+ * label="Option 1"
15
+ * description="This is a description"
16
+ * [(ngModel)]="selectedValue"
17
+ * value="option1"
18
+ * ></pecb-radio>
19
+ *
20
+ * <!-- Filled variant -->
21
+ * <pecb-radio
22
+ * label="Option 1"
23
+ * variant="filled"
24
+ * [(ngModel)]="selectedValue"
25
+ * value="option1"
26
+ * ></pecb-radio>
27
+ * ```
28
+ *
29
+ * @publicApi
30
+ */
31
+ export declare class RadioComponent implements ControlValueAccessor {
32
+ private cdr;
33
+ /**
34
+ * Unique ID for the radio element
35
+ */
36
+ id: string;
37
+ /**
38
+ * Name attribute for the radio group
39
+ */
40
+ name?: string;
41
+ /**
42
+ * Value of this radio button
43
+ */
44
+ value: unknown;
45
+ /**
46
+ * Visual variant of the radio button
47
+ */
48
+ variant: RadioVariant;
49
+ /**
50
+ * Label text to display
51
+ */
52
+ label?: string;
53
+ /**
54
+ * Description text to display below label
55
+ */
56
+ description?: string;
57
+ /**
58
+ * Position of the label relative to the radio control.
59
+ * 'right' (default): [radio] Title Description
60
+ * 'left': Title Description [radio]
61
+ */
62
+ labelPosition: RadioLabelPosition;
63
+ /**
64
+ * Whether the radio is disabled
65
+ */
66
+ disabled: boolean;
67
+ /**
68
+ * Event emitted when selection changes
69
+ */
70
+ selectionChange: EventEmitter<unknown>;
71
+ checked: boolean;
72
+ private onChange;
73
+ private onTouched;
74
+ constructor(cdr: ChangeDetectorRef);
75
+ /**
76
+ * Get CSS classes for the radio wrapper
77
+ */
78
+ get wrapperClasses(): string[];
79
+ /**
80
+ * Handle radio selection
81
+ */
82
+ onRadioChange(event: Event): void;
83
+ /**
84
+ * Handle blur event
85
+ */
86
+ onBlur(): void;
87
+ writeValue(value: unknown): void;
88
+ registerOnChange(fn: (value: unknown) => void): void;
89
+ registerOnTouched(fn: () => void): void;
90
+ setDisabledState(isDisabled: boolean): void;
91
+ static ɵfac: i0.ɵɵFactoryDeclaration<RadioComponent, never>;
92
+ static ɵcmp: i0.ɵɵComponentDeclaration<RadioComponent, "pecb-radio", never, { "id": { "alias": "id"; "required": false; }; "name": { "alias": "name"; "required": false; }; "value": { "alias": "value"; "required": false; }; "variant": { "alias": "variant"; "required": false; }; "label": { "alias": "label"; "required": false; }; "description": { "alias": "description"; "required": false; }; "labelPosition": { "alias": "labelPosition"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; }, { "selectionChange": "selectionChange"; }, never, never, true, never>;
93
+ }
@@ -0,0 +1,137 @@
1
+ import { EventEmitter, OnInit, OnDestroy, ElementRef, AfterViewInit } from '@angular/core';
2
+ import * as i0 from "@angular/core";
3
+ export type RightModalSize = 'sm' | 'md' | 'lg';
4
+ /**
5
+ * A right-side sliding modal/drawer component.
6
+ * Slides in from the right edge of the screen with backdrop overlay.
7
+ * Fully accessible with WCAG 2.1 AA compliance.
8
+ *
9
+ * @example
10
+ * ```html
11
+ * <pecb-right-modal
12
+ * [isOpen]="isModalOpen"
13
+ * (closed)="onModalClose()"
14
+ * ariaLabel="Exam Details"
15
+ * >
16
+ * <div pecbRightModalHeader>
17
+ * <h2>Exam Details</h2>
18
+ * </div>
19
+ * <div pecbRightModalContent>
20
+ * <p>Modal content goes here</p>
21
+ * </div>
22
+ * <div pecbRightModalFooter>
23
+ * <button>Action</button>
24
+ * </div>
25
+ * </pecb-right-modal>
26
+ * ```
27
+ *
28
+ * @publicApi
29
+ */
30
+ export declare class RightModalComponent implements OnInit, OnDestroy, AfterViewInit {
31
+ /**
32
+ * Unique ID for the modal element
33
+ */
34
+ id: string;
35
+ /**
36
+ * Whether the modal is open
37
+ */
38
+ isOpen: boolean;
39
+ /**
40
+ * Size of the modal panel
41
+ */
42
+ size: RightModalSize;
43
+ /**
44
+ * Whether clicking the backdrop closes the modal
45
+ */
46
+ closeOnBackdropClick: boolean;
47
+ /**
48
+ * Whether pressing Escape closes the modal
49
+ */
50
+ closeOnEscape: boolean;
51
+ /**
52
+ * Whether to show the close button
53
+ */
54
+ showCloseButton: boolean;
55
+ /**
56
+ * Accessible label for the modal
57
+ */
58
+ ariaLabel?: string;
59
+ /**
60
+ * ID of element that labels this modal
61
+ */
62
+ ariaLabelledBy?: string;
63
+ /**
64
+ * ID of element that describes this modal
65
+ */
66
+ ariaDescribedBy?: string;
67
+ /**
68
+ * Emitted when the modal is closed
69
+ */
70
+ closed: EventEmitter<void>;
71
+ /**
72
+ * Emitted when the modal is opened
73
+ */
74
+ opened: EventEmitter<void>;
75
+ modalPanel: ElementRef<HTMLElement>;
76
+ private cleanupFocusTrap;
77
+ private cleanupBodyScroll;
78
+ private previousActiveElement;
79
+ ngOnInit(): void;
80
+ ngAfterViewInit(): void;
81
+ ngOnDestroy(): void;
82
+ /**
83
+ * Get CSS classes for the modal container
84
+ */
85
+ get modalClasses(): string[];
86
+ /**
87
+ * Get CSS classes for the modal panel
88
+ */
89
+ get panelClasses(): string[];
90
+ /**
91
+ * Handle backdrop click
92
+ */
93
+ onBackdropClick(event: MouseEvent): void;
94
+ /**
95
+ * Handle keyboard events
96
+ */
97
+ onKeydown(event: KeyboardEvent): void;
98
+ /**
99
+ * Close the modal
100
+ */
101
+ close(): void;
102
+ /**
103
+ * Called when modal opens
104
+ */
105
+ private onOpen;
106
+ /**
107
+ * Setup focus trap after view is ready
108
+ */
109
+ private setupFocusTrap;
110
+ /**
111
+ * Cleanup resources
112
+ */
113
+ private cleanup;
114
+ static ɵfac: i0.ɵɵFactoryDeclaration<RightModalComponent, never>;
115
+ static ɵcmp: i0.ɵɵComponentDeclaration<RightModalComponent, "pecb-right-modal", never, { "id": { "alias": "id"; "required": false; }; "isOpen": { "alias": "isOpen"; "required": false; }; "size": { "alias": "size"; "required": false; }; "closeOnBackdropClick": { "alias": "closeOnBackdropClick"; "required": false; }; "closeOnEscape": { "alias": "closeOnEscape"; "required": false; }; "showCloseButton": { "alias": "showCloseButton"; "required": false; }; "ariaLabel": { "alias": "ariaLabel"; "required": false; }; "ariaLabelledBy": { "alias": "ariaLabelledBy"; "required": false; }; "ariaDescribedBy": { "alias": "ariaDescribedBy"; "required": false; }; }, { "closed": "closed"; "opened": "opened"; }, never, ["[pecbRightModalHeader]", "[pecbRightModalContent]", "*", "[pecbRightModalFooter]"], true, never>;
116
+ }
117
+ /**
118
+ * Header directive for right modal
119
+ */
120
+ export declare class RightModalHeaderDirective {
121
+ static ɵfac: i0.ɵɵFactoryDeclaration<RightModalHeaderDirective, never>;
122
+ static ɵdir: i0.ɵɵDirectiveDeclaration<RightModalHeaderDirective, "[pecbRightModalHeader]", never, {}, {}, never, never, true, never>;
123
+ }
124
+ /**
125
+ * Content directive for right modal
126
+ */
127
+ export declare class RightModalContentDirective {
128
+ static ɵfac: i0.ɵɵFactoryDeclaration<RightModalContentDirective, never>;
129
+ static ɵdir: i0.ɵɵDirectiveDeclaration<RightModalContentDirective, "[pecbRightModalContent]", never, {}, {}, never, never, true, never>;
130
+ }
131
+ /**
132
+ * Footer directive for right modal
133
+ */
134
+ export declare class RightModalFooterDirective {
135
+ static ɵfac: i0.ɵɵFactoryDeclaration<RightModalFooterDirective, never>;
136
+ static ɵdir: i0.ɵɵDirectiveDeclaration<RightModalFooterDirective, "[pecbRightModalFooter]", never, {}, {}, never, never, true, never>;
137
+ }
@@ -0,0 +1,97 @@
1
+ import { EventEmitter } from '@angular/core';
2
+ import { DomSanitizer, SafeHtml } from '@angular/platform-browser';
3
+ import * as i0 from "@angular/core";
4
+ export interface SidebarMenuItem {
5
+ id: string;
6
+ label: string;
7
+ icon?: string;
8
+ route?: string;
9
+ active?: boolean;
10
+ children?: SidebarMenuItem[];
11
+ expanded?: boolean;
12
+ }
13
+ export interface SidebarSection {
14
+ id: string;
15
+ title?: string;
16
+ items: SidebarMenuItem[];
17
+ }
18
+ /**
19
+ * A professional sidebar navigation component with collapsible sections and nested items.
20
+ * Perfect for application navigation with hierarchical menu structures.
21
+ *
22
+ * @example
23
+ * ```html
24
+ * <!-- Basic sidebar -->
25
+ * <pecb-sidebar
26
+ * [sections]="menuSections"
27
+ * (itemClick)="onMenuItemClick($event)"
28
+ * ></pecb-sidebar>
29
+ *
30
+ * <!-- With logo header -->
31
+ * <pecb-sidebar
32
+ * [sections]="menuSections"
33
+ * [showHeader]="true"
34
+ * [sidebarLogo]="logoSvg"
35
+ * ></pecb-sidebar>
36
+ * ```
37
+ *
38
+ * @publicApi
39
+ */
40
+ export declare class SidebarComponent {
41
+ private sanitizer;
42
+ constructor(sanitizer: DomSanitizer);
43
+ /**
44
+ * Array of sidebar sections with menu items
45
+ */
46
+ sections: SidebarSection[];
47
+ /**
48
+ * Whether to show the header section
49
+ */
50
+ showHeader: boolean;
51
+ /**
52
+ * Sidebar logo as an SVG string. Rendered in the header area.
53
+ */
54
+ sidebarLogo?: string;
55
+ /**
56
+ * Whether to show the footer section
57
+ */
58
+ showFooter: boolean;
59
+ /**
60
+ * Whether the sidebar is collapsed
61
+ */
62
+ collapsed: boolean;
63
+ /**
64
+ * Event emitted when a menu item is clicked
65
+ */
66
+ itemClick: EventEmitter<SidebarMenuItem>;
67
+ /**
68
+ * Event emitted when the sidebar collapse state changes
69
+ */
70
+ collapseChange: EventEmitter<boolean>;
71
+ /**
72
+ * Handle menu item click
73
+ */
74
+ onItemClick(item: SidebarMenuItem, event: Event): void;
75
+ /**
76
+ * Toggle sidebar collapse state
77
+ */
78
+ toggleCollapse(): void;
79
+ /**
80
+ * Sanitize icon SVG HTML to prevent Angular from stripping SVG elements
81
+ */
82
+ getSafeIcon(icon: string): SafeHtml;
83
+ /**
84
+ * TrackBy for sections
85
+ */
86
+ trackBySection(_index: number, section: SidebarSection): string;
87
+ /**
88
+ * TrackBy for menu items
89
+ */
90
+ trackByItem(_index: number, item: SidebarMenuItem): string;
91
+ /**
92
+ * Get CSS classes for a menu item
93
+ */
94
+ getItemClasses(item: SidebarMenuItem, isChild?: boolean, isNested?: boolean): string[];
95
+ static ɵfac: i0.ɵɵFactoryDeclaration<SidebarComponent, never>;
96
+ static ɵcmp: i0.ɵɵComponentDeclaration<SidebarComponent, "pecb-sidebar", never, { "sections": { "alias": "sections"; "required": false; }; "showHeader": { "alias": "showHeader"; "required": false; }; "sidebarLogo": { "alias": "sidebarLogo"; "required": false; }; "showFooter": { "alias": "showFooter"; "required": false; }; "collapsed": { "alias": "collapsed"; "required": false; }; }, { "itemClick": "itemClick"; "collapseChange": "collapseChange"; }, never, ["[sidebar-header]", "[sidebar-footer]"], true, never>;
97
+ }
@@ -0,0 +1,19 @@
1
+ import * as i0 from "@angular/core";
2
+ export type StatusType = 'warning' | 'action' | 'success' | 'error' | 'different' | 'disabled' | 'neutral';
3
+ export type StatusVariant = 'accent' | 'filled' | 'outline' | 'custom';
4
+ export type StatusSize = 'sm' | 'md' | 'lg';
5
+ export declare class StatusComponent {
6
+ private _id;
7
+ type: StatusType;
8
+ variant: StatusVariant;
9
+ size: StatusSize;
10
+ ariaLabel?: string;
11
+ /** Text content to display (alternative to ng-content, useful for dynamic components) */
12
+ text?: string;
13
+ /** Custom CSS class(es) to add to the status element */
14
+ customClass?: string;
15
+ get id(): string;
16
+ get statusClasses(): string[];
17
+ static ɵfac: i0.ɵɵFactoryDeclaration<StatusComponent, never>;
18
+ static ɵcmp: i0.ɵɵComponentDeclaration<StatusComponent, "pecb-status", never, { "type": { "alias": "type"; "required": false; }; "variant": { "alias": "variant"; "required": false; }; "size": { "alias": "size"; "required": false; }; "ariaLabel": { "alias": "ariaLabel"; "required": false; }; "text": { "alias": "text"; "required": false; }; "customClass": { "alias": "customClass"; "required": false; }; }, {}, never, ["*"], true, never>;
19
+ }