@educarehq/solaris-components 0.3.9 → 0.4.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@educarehq/solaris-components",
3
- "version": "0.3.9",
3
+ "version": "0.4.1",
4
4
  "peerDependencies": {
5
5
  "@angular/core": "^21.1.0",
6
6
  "intl-tel-input": "^26.0.9",
@@ -1,7 +1,7 @@
1
1
  import * as i0 from '@angular/core';
2
- import { ElementRef, TemplateRef, AfterContentInit, OnDestroy, EventEmitter, QueryList, OnChanges, SimpleChanges, InjectionToken, EnvironmentProviders, OnInit, AfterViewInit, WritableSignal } from '@angular/core';
3
- import { SolarisTranslationParams } from '@educarehq/solaris-services';
2
+ import { ElementRef, TemplateRef, AfterContentInit, OnDestroy, EventEmitter, OnChanges, ChangeDetectorRef, SimpleChanges, QueryList, InjectionToken, EnvironmentProviders, OnInit, AfterViewInit, WritableSignal } from '@angular/core';
4
3
  import * as _educarehq_solaris_components from '@educarehq/solaris-components';
4
+ import { SolarisTranslationParams } from '@educarehq/solaris-services';
5
5
  import { ControlValueAccessor, Validator, ValidationErrors, AbstractControl, NgControl } from '@angular/forms';
6
6
 
7
7
  declare class SolarisDropdownContentTriggerDirective {
@@ -124,6 +124,117 @@ declare class SolarisBreadcrumb {
124
124
  static ɵcmp: i0.ɵɵComponentDeclaration<SolarisBreadcrumb, "solaris-breadcrumb", never, { "minItems": { "alias": "min-items"; "required": false; }; "maxItems": { "alias": "max-items"; "required": false; }; "responsive": { "alias": "responsive"; "required": false; }; "items": { "alias": "items"; "required": true; }; }, { "itemSelect": "itemSelect"; }, never, never, true, never>;
125
125
  }
126
126
 
127
+ type SolarisSizePreset = 'sm' | 'md' | 'lg';
128
+ type SolarisRadiusPreset = 'none' | 'sm' | 'md' | 'lg' | 'full';
129
+ type SolarisColorPreset = 'primary' | 'surface' | 'success' | 'warning' | 'error' | 'info' | 'gradient';
130
+
131
+ type BadgeVariant = 'solid' | 'subtle' | 'outline';
132
+ type BadgeColorInput = SolarisColorPreset | string & {
133
+ readonly __solarisCustom?: unique symbol;
134
+ };
135
+
136
+ type SolarisStepperOrientation = 'horizontal' | 'vertical';
137
+ type SolarisStepperAppearance = 'default' | 'compact';
138
+ type SolarisStepperPhase = 'pending' | 'current' | 'completed';
139
+ type SolarisStepperStatus = 'default' | 'warning' | 'error' | 'disabled' | 'locked';
140
+ type SolarisStepperChangeReason = 'header' | 'next' | 'previous' | 'programmatic';
141
+ interface SolarisStepperChangeEvent {
142
+ previousIndex: number;
143
+ currentIndex: number;
144
+ reason: SolarisStepperChangeReason;
145
+ }
146
+
147
+ declare class SolarisStepperItem {
148
+ stepId?: string;
149
+ label?: string;
150
+ labelKey?: string;
151
+ title?: string;
152
+ titleKey?: string;
153
+ description?: string;
154
+ descriptionKey?: string;
155
+ icon?: string;
156
+ optional: boolean;
157
+ phase: SolarisStepperPhase | null;
158
+ status: SolarisStepperStatus;
159
+ badgeText?: string;
160
+ badgeTextKey?: string;
161
+ badgeColor?: BadgeColorInput;
162
+ badgeVariant: BadgeVariant;
163
+ badgeSize: SolarisSizePreset;
164
+ badgePill: boolean;
165
+ active: boolean;
166
+ index: number;
167
+ headerId: string;
168
+ panelId: string;
169
+ static ɵfac: i0.ɵɵFactoryDeclaration<SolarisStepperItem, never>;
170
+ static ɵcmp: i0.ɵɵComponentDeclaration<SolarisStepperItem, "solaris-stepper-item", never, { "stepId": { "alias": "stepId"; "required": false; }; "label": { "alias": "label"; "required": false; }; "labelKey": { "alias": "labelKey"; "required": false; }; "title": { "alias": "title"; "required": false; }; "titleKey": { "alias": "titleKey"; "required": false; }; "description": { "alias": "description"; "required": false; }; "descriptionKey": { "alias": "descriptionKey"; "required": false; }; "icon": { "alias": "icon"; "required": false; }; "optional": { "alias": "optional"; "required": false; }; "phase": { "alias": "phase"; "required": false; }; "status": { "alias": "status"; "required": false; }; "badgeText": { "alias": "badgeText"; "required": false; }; "badgeTextKey": { "alias": "badgeTextKey"; "required": false; }; "badgeColor": { "alias": "badgeColor"; "required": false; }; "badgeVariant": { "alias": "badgeVariant"; "required": false; }; "badgeSize": { "alias": "badgeSize"; "required": false; }; "badgePill": { "alias": "badgePill"; "required": false; }; }, {}, never, ["*"], true, never>;
171
+ }
172
+
173
+ declare class SolarisStepper implements AfterContentInit, OnChanges {
174
+ private readonly changeDetectorRef;
175
+ private readonly destroyRef;
176
+ private static nextId;
177
+ orientation: SolarisStepperOrientation;
178
+ appearance: SolarisStepperAppearance;
179
+ linear: boolean;
180
+ interactive: boolean;
181
+ activeIndex: number | null;
182
+ defaultActiveIndex: number;
183
+ allowBackNavigation: boolean;
184
+ allowFutureNavigation: boolean;
185
+ allowSkip: boolean;
186
+ renderPanels: boolean;
187
+ showStateBadges: boolean;
188
+ readonly activeIndexChange: EventEmitter<number>;
189
+ readonly nextChange: EventEmitter<number>;
190
+ readonly previousChange: EventEmitter<number>;
191
+ readonly stepChange: EventEmitter<SolarisStepperChangeEvent>;
192
+ private readonly itemsQuery?;
193
+ private readonly stepButtons?;
194
+ items: SolarisStepperItem[];
195
+ private readonly uid;
196
+ private internalActiveIndex;
197
+ get currentIndex(): number;
198
+ constructor(changeDetectorRef: ChangeDetectorRef);
199
+ ngAfterContentInit(): void;
200
+ ngOnChanges(changes: SimpleChanges): void;
201
+ next(): void;
202
+ previous(): void;
203
+ setActiveStep(index: number): void;
204
+ onStepHeaderClick(index: number): void;
205
+ onStepKeydown(event: KeyboardEvent, index: number): void;
206
+ isCurrent(index: number): boolean;
207
+ isCompleted(index: number): boolean;
208
+ isPending(index: number): boolean;
209
+ resolvePhase(item: SolarisStepperItem, index: number): SolarisStepperPhase;
210
+ getStepClasses(item: SolarisStepperItem, index: number): Record<string, boolean>;
211
+ getConnectorClasses(index: number): Record<string, boolean>;
212
+ getMarkerIcon(item: SolarisStepperItem, index: number): string | null;
213
+ getMarkerText(item: SolarisStepperItem, index: number): string | null;
214
+ hasBadge(item: SolarisStepperItem, index: number): boolean;
215
+ getResolvedLabel(item: SolarisStepperItem, index: number): string | null;
216
+ getResolvedBadgeColor(item: SolarisStepperItem, index: number): _educarehq_solaris_components.BadgeColorInput;
217
+ getResolvedBadgeVariant(item: SolarisStepperItem): _educarehq_solaris_components.BadgeVariant;
218
+ getAutoBadgeTranslationKey(item: SolarisStepperItem, index: number): string;
219
+ getTitle(item: SolarisStepperItem): string;
220
+ getDescription(item: SolarisStepperItem): string;
221
+ getStepAriaLabel(item: SolarisStepperItem, index: number): string;
222
+ trackByIndex(index: number): number;
223
+ private syncItems;
224
+ private commitIndexChange;
225
+ private canActivateByHeaderClick;
226
+ private isProgrammaticallyNavigable;
227
+ private findAdjacentNavigableIndex;
228
+ private isDisabledLike;
229
+ private isControlled;
230
+ private isInBounds;
231
+ private normalizeIndex;
232
+ private focusRelativeButton;
233
+ private focusButton;
234
+ static ɵfac: i0.ɵɵFactoryDeclaration<SolarisStepper, never>;
235
+ static ɵcmp: i0.ɵɵComponentDeclaration<SolarisStepper, "solaris-stepper", never, { "orientation": { "alias": "orientation"; "required": false; }; "appearance": { "alias": "appearance"; "required": false; }; "linear": { "alias": "linear"; "required": false; }; "interactive": { "alias": "interactive"; "required": false; }; "activeIndex": { "alias": "activeIndex"; "required": false; }; "defaultActiveIndex": { "alias": "defaultActiveIndex"; "required": false; }; "allowBackNavigation": { "alias": "allowBackNavigation"; "required": false; }; "allowFutureNavigation": { "alias": "allowFutureNavigation"; "required": false; }; "allowSkip": { "alias": "allowSkip"; "required": false; }; "renderPanels": { "alias": "renderPanels"; "required": false; }; "showStateBadges": { "alias": "showStateBadges"; "required": false; }; }, { "activeIndexChange": "activeIndexChange"; "nextChange": "next"; "previousChange": "previous"; "stepChange": "stepChange"; }, ["itemsQuery"], ["*"], true, never>;
236
+ }
237
+
127
238
  declare class SolarisPopoverTriggerDirective {
128
239
  readonly elementRef: ElementRef<HTMLElement>;
129
240
  static ɵfac: i0.ɵɵFactoryDeclaration<SolarisPopoverTriggerDirective, never>;
@@ -279,10 +390,6 @@ declare class SolarisNotificationIntlService {
279
390
  static ɵprov: i0.ɵɵInjectableDeclaration<SolarisNotificationIntlService>;
280
391
  }
281
392
 
282
- type SolarisSizePreset = 'sm' | 'md' | 'lg';
283
- type SolarisRadiusPreset = 'none' | 'sm' | 'md' | 'lg' | 'full';
284
- type SolarisColorPreset = 'primary' | 'surface' | 'success' | 'warning' | 'error' | 'info' | 'gradient';
285
-
286
393
  type SolarisButtonVariant = 'solid' | 'outline' | 'ghost' | 'soft';
287
394
  type SolarisRadiusInput = SolarisRadiusPreset | SolarisCustomString;
288
395
  type SolarisButtonColorInput = SolarisColorPreset | SolarisCustomString;
@@ -436,7 +543,7 @@ declare class SolarisNotificationItemComponent {
436
543
  readonly paused: i0.Signal<boolean>;
437
544
  readonly secondsLeft: i0.Signal<number>;
438
545
  readonly progress: i0.Signal<number>;
439
- readonly iconClass: i0.Signal<"ph-check-circle" | "ph-warning-circle" | "ph-x-circle" | "ph-info">;
546
+ readonly iconClass: i0.Signal<"ph-x-circle" | "ph-warning-circle" | "ph-check-circle" | "ph-info">;
440
547
  protected readonly isCompactHeader: i0.Signal<boolean>;
441
548
  toggleExpanded(): void;
442
549
  toggleUserPause(): void;
@@ -501,11 +608,6 @@ type Spoke = {
501
608
  opacity: number;
502
609
  };
503
610
 
504
- type BadgeVariant = 'solid' | 'subtle' | 'outline';
505
- type BadgeColorInput = SolarisColorPreset | string & {
506
- readonly __solarisCustom?: unique symbol;
507
- };
508
-
509
611
  declare class SolarisBadge {
510
612
  pill: boolean;
511
613
  customTextColor?: string;
@@ -1475,5 +1577,5 @@ declare class SolarisSelect implements OnInit, ControlValueAccessor, AfterViewIn
1475
1577
  static ɵcmp: i0.ɵɵComponentDeclaration<SolarisSelect, "solaris-select", never, { "items": { "alias": "items"; "required": false; }; "multiple": { "alias": "multiple"; "required": false; }; "valueKey": { "alias": "valueKey"; "required": false; }; "backKey": { "alias": "backKey"; "required": false; }; "placeholder": { "alias": "placeholder"; "required": false; }; "placeholderKey": { "alias": "placeholderKey"; "required": false; }; "searchable": { "alias": "searchable"; "required": false; }; "selectedCountKey": { "alias": "selectedCountKey"; "required": false; }; "selectedFirst": { "alias": "selectedFirst"; "required": false; }; "searchPlaceholder": { "alias": "searchPlaceholder"; "required": false; }; "selectedCountText": { "alias": "selectedCountText"; "required": false; }; "panelMaxHeight": { "alias": "panelMaxHeight"; "required": false; }; "searchPlaceholderKey": { "alias": "searchPlaceholderKey"; "required": false; }; "selectionSeparator": { "alias": "selectionSeparator"; "required": false; }; "compareWith": { "alias": "compareWith"; "required": false; }; "backText": { "alias": "backText"; "required": false; }; "selectionDisplay": { "alias": "selectionDisplay"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; }, {}, never, never, true, never>;
1476
1578
  }
1477
1579
 
1478
- export { ButtonDirective, ButtonGroupDirective, FieldErrorComponent, FormField, InputTextDirective, PasswordToggle, SOLARIS_FORM_FIELD_CONTROLLER, SOLARIS_FORM_FIELD_FEATURES, SOLARIS_INPUT, SOLARIS_NOTIFICATION_CONFIG, SOLARIS_NOTIFICATION_DEFAULT_CONFIG, SOLARIS_NOTIFICATION_POSITIONS, SolarisBadge, SolarisBodyDirective, SolarisBreadcrumb, SolarisCheckbox, SolarisColumnCellDef, SolarisColumnHeaderDef, SolarisControlBridgeDirective, SolarisDivider, SolarisDrawer, SolarisDrawerFooterDirective, SolarisDrawerHeaderDirective, SolarisDropdownContent, SolarisDropdownContentPanelDirective, SolarisDropdownContentRegistry, SolarisDropdownContentTriggerDirective, SolarisEmailDirective, SolarisFilterBar, SolarisFilterChip, SolarisFilterField, SolarisFilterPanel, SolarisFilterPanelFooterDirective, SolarisFooterDirective, SolarisFormFieldController, SolarisHeaderDirective, SolarisIdGenerator, SolarisImageSliderComponent, SolarisLoading, SolarisLoadingOverlay, SolarisNotificationCenterComponent, SolarisNotificationHostComponent, SolarisNotificationIntlService, SolarisNotificationItemComponent, SolarisNotificationService, SolarisPage, SolarisPageHeader, SolarisPageHeaderBreadcrumbDirective, SolarisPageHeaderDescriptionDirective, SolarisPageHeaderTitle, SolarisPageHeaderTitleDirective, SolarisPasswordDirective, SolarisPhoneInput, SolarisPopover, SolarisPopoverPanelDirective, SolarisPopoverTriggerDirective, SolarisPrefixDirective, SolarisRowComponent, SolarisSectionComponent, SolarisSelect, SolarisSuffixDirective, SolarisTab, SolarisTable, SolarisTableColumn, SolarisTableFilters, SolarisTableSkeleton, SolarisTabs, computePopoverPosition, provideSolarisNotifications, uniqueId };
1479
- export type { BadgeColorInput, BadgeVariant, CheckboxAppearance, CheckboxColorInput, CheckboxVariant, DividerLabelAlign, DividerOrientation, DividerSpacing, DividerStrength, DividerVariant, Iso2, LoadingType, PhoneFormat, SelectionDisplay, SolarisAlign, SolarisBreadcrumbItem, SolarisBreadcrumbTarget, SolarisButtonColorInput, SolarisButtonVariant, SolarisCheckCustomString, SolarisColorPreset, SolarisCustomString, SolarisDrawerSide, SolarisDropdownContentInterface, SolarisDropdownWidthMode, SolarisFilterPanelRadius, SolarisFormFieldAppearance, SolarisFormFieldControllerLike, SolarisFormFieldFeature, SolarisFormFieldRadius, SolarisFormFieldShowErrors, SolarisInputApi, SolarisLoadingColor, SolarisLoadingDashDensity, SolarisLoadingEasing, SolarisLoadingPresetColor, SolarisLoadingSize, SolarisLoadingSpeed, SolarisLoadingTrail, SolarisNotificationAction, SolarisNotificationActionContext, SolarisNotificationConfig, SolarisNotificationConfigInput, SolarisNotificationInput, SolarisNotificationKind, SolarisNotificationPosition, SolarisNotificationRecord, SolarisNotificationRef, SolarisNotificationState, SolarisPageChange, SolarisPopoverPlacement, SolarisPopoverPositionConfiguration, SolarisPopoverPositionResult, SolarisRadiusInput, SolarisRadiusPreset, SolarisRowKey, SolarisSelectDivider, SolarisSelectGroup, SolarisSelectItem, SolarisSelectNode, SolarisSelectRow, SolarisSizePreset, SolarisSliderItem, SolarisSliderOverlayContext, SolarisSort, SolarisSortDirection, SolarisTableI18n, SolarisTableVariant, StackLevel, TabsSize, TabsVariant };
1580
+ export { ButtonDirective, ButtonGroupDirective, FieldErrorComponent, FormField, InputTextDirective, PasswordToggle, SOLARIS_FORM_FIELD_CONTROLLER, SOLARIS_FORM_FIELD_FEATURES, SOLARIS_INPUT, SOLARIS_NOTIFICATION_CONFIG, SOLARIS_NOTIFICATION_DEFAULT_CONFIG, SOLARIS_NOTIFICATION_POSITIONS, SolarisBadge, SolarisBodyDirective, SolarisBreadcrumb, SolarisCheckbox, SolarisColumnCellDef, SolarisColumnHeaderDef, SolarisControlBridgeDirective, SolarisDivider, SolarisDrawer, SolarisDrawerFooterDirective, SolarisDrawerHeaderDirective, SolarisDropdownContent, SolarisDropdownContentPanelDirective, SolarisDropdownContentRegistry, SolarisDropdownContentTriggerDirective, SolarisEmailDirective, SolarisFilterBar, SolarisFilterChip, SolarisFilterField, SolarisFilterPanel, SolarisFilterPanelFooterDirective, SolarisFooterDirective, SolarisFormFieldController, SolarisHeaderDirective, SolarisIdGenerator, SolarisImageSliderComponent, SolarisLoading, SolarisLoadingOverlay, SolarisNotificationCenterComponent, SolarisNotificationHostComponent, SolarisNotificationIntlService, SolarisNotificationItemComponent, SolarisNotificationService, SolarisPage, SolarisPageHeader, SolarisPageHeaderBreadcrumbDirective, SolarisPageHeaderDescriptionDirective, SolarisPageHeaderTitle, SolarisPageHeaderTitleDirective, SolarisPasswordDirective, SolarisPhoneInput, SolarisPopover, SolarisPopoverPanelDirective, SolarisPopoverTriggerDirective, SolarisPrefixDirective, SolarisRowComponent, SolarisSectionComponent, SolarisSelect, SolarisStepper, SolarisStepperItem, SolarisSuffixDirective, SolarisTab, SolarisTable, SolarisTableColumn, SolarisTableFilters, SolarisTableSkeleton, SolarisTabs, computePopoverPosition, provideSolarisNotifications, uniqueId };
1581
+ export type { BadgeColorInput, BadgeVariant, CheckboxAppearance, CheckboxColorInput, CheckboxVariant, DividerLabelAlign, DividerOrientation, DividerSpacing, DividerStrength, DividerVariant, Iso2, LoadingType, PhoneFormat, SelectionDisplay, SolarisAlign, SolarisBreadcrumbItem, SolarisBreadcrumbTarget, SolarisButtonColorInput, SolarisButtonVariant, SolarisCheckCustomString, SolarisColorPreset, SolarisCustomString, SolarisDrawerSide, SolarisDropdownContentInterface, SolarisDropdownWidthMode, SolarisFilterPanelRadius, SolarisFormFieldAppearance, SolarisFormFieldControllerLike, SolarisFormFieldFeature, SolarisFormFieldRadius, SolarisFormFieldShowErrors, SolarisInputApi, SolarisLoadingColor, SolarisLoadingDashDensity, SolarisLoadingEasing, SolarisLoadingPresetColor, SolarisLoadingSize, SolarisLoadingSpeed, SolarisLoadingTrail, SolarisNotificationAction, SolarisNotificationActionContext, SolarisNotificationConfig, SolarisNotificationConfigInput, SolarisNotificationInput, SolarisNotificationKind, SolarisNotificationPosition, SolarisNotificationRecord, SolarisNotificationRef, SolarisNotificationState, SolarisPageChange, SolarisPopoverPlacement, SolarisPopoverPositionConfiguration, SolarisPopoverPositionResult, SolarisRadiusInput, SolarisRadiusPreset, SolarisRowKey, SolarisSelectDivider, SolarisSelectGroup, SolarisSelectItem, SolarisSelectNode, SolarisSelectRow, SolarisSizePreset, SolarisSliderItem, SolarisSliderOverlayContext, SolarisSort, SolarisSortDirection, SolarisStepperAppearance, SolarisStepperChangeEvent, SolarisStepperChangeReason, SolarisStepperOrientation, SolarisStepperPhase, SolarisStepperStatus, SolarisTableI18n, SolarisTableVariant, StackLevel, TabsSize, TabsVariant };