@seniorsistemas/components-ai 2.3.0 → 2.4.0

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.
@@ -0,0 +1,63 @@
1
+ import { EventEmitter, OnChanges, SimpleChanges, ElementRef, AfterViewInit, OnDestroy, ChangeDetectorRef } from '@angular/core';
2
+ import * as i0 from "@angular/core";
3
+ export interface StepItem {
4
+ id?: string;
5
+ label: string;
6
+ icon?: string;
7
+ styleClass?: string;
8
+ disabled?: boolean;
9
+ metadata?: Record<string, unknown>;
10
+ }
11
+ export declare class StepsComponent implements OnChanges, AfterViewInit, OnDestroy {
12
+ private cdr;
13
+ /** Lista de steps a serem exibidos */
14
+ steps: StepItem[];
15
+ /** Índice do step ativo */
16
+ activeIndex: number;
17
+ /** Se permite clicar nos steps para navegar */
18
+ readonly: boolean;
19
+ /** Quantidade máxima de steps visíveis. 'auto' calcula com base no container */
20
+ maxVisible: number | 'auto';
21
+ /** Largura mínima de cada step em pixels (usado no cálculo automático) */
22
+ stepMinWidth: number;
23
+ /** Se mostra animação de transição ao navegar */
24
+ animated: boolean;
25
+ /** Modo de navegação das setas: 'step' altera o activeIndex, 'scroll' apenas desloca a janela visível */
26
+ navigationMode: 'step' | 'scroll';
27
+ /** Esquema de cores aplicado aos steps. Altera as cores do ativo e completados */
28
+ colorScheme: 'default' | 'success' | 'danger' | 'warning' | 'info';
29
+ /** Classe CSS customizada para o wrapper */
30
+ styleClass: string;
31
+ /** Emite quando o activeIndex muda por clique */
32
+ activeIndexChange: EventEmitter<number>;
33
+ /** Emite o StepItem clicado */
34
+ stepClick: EventEmitter<StepItem>;
35
+ stepsContainer: ElementRef<HTMLElement>;
36
+ visibleSteps: StepItem[];
37
+ visibleStartIndex: number;
38
+ visibleEndIndex: number;
39
+ hasOverflowLeft: boolean;
40
+ hasOverflowRight: boolean;
41
+ calculatedMaxVisible: number;
42
+ private resizeObserver;
43
+ constructor(cdr: ChangeDetectorRef);
44
+ ngOnChanges(changes: SimpleChanges): void;
45
+ ngAfterViewInit(): void;
46
+ ngOnDestroy(): void;
47
+ onStepClick(step: StepItem, visibleIndex: number): void;
48
+ navigateLeft(): void;
49
+ navigateRight(): void;
50
+ /** Desloca a janela visível para um novo startIndex sem alterar o activeIndex */
51
+ private scrollWindow;
52
+ getStepState(visibleIndex: number): 'completed' | 'active' | 'pending';
53
+ getRealIndex(visibleIndex: number): number;
54
+ get hiddenLeftCount(): number;
55
+ get hiddenRightCount(): number;
56
+ trackByIndex(index: number): number;
57
+ private setupResizeObserver;
58
+ private recalculate;
59
+ private getMaxVisible;
60
+ private calculateVisibleWindow;
61
+ static ɵfac: i0.ɵɵFactoryDeclaration<StepsComponent, never>;
62
+ static ɵcmp: i0.ɵɵComponentDeclaration<StepsComponent, "sia-steps", never, { "steps": { "alias": "steps"; "required": false; }; "activeIndex": { "alias": "activeIndex"; "required": false; }; "readonly": { "alias": "readonly"; "required": false; }; "maxVisible": { "alias": "maxVisible"; "required": false; }; "stepMinWidth": { "alias": "stepMinWidth"; "required": false; }; "animated": { "alias": "animated"; "required": false; }; "navigationMode": { "alias": "navigationMode"; "required": false; }; "colorScheme": { "alias": "colorScheme"; "required": false; }; "styleClass": { "alias": "styleClass"; "required": false; }; }, { "activeIndexChange": "activeIndexChange"; "stepClick": "stepClick"; }, never, never, true, never>;
63
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@seniorsistemas/components-ai",
3
- "version": "2.3.0",
3
+ "version": "2.4.0",
4
4
  "description": "Biblioteca de componentes reutilizáveis com IA para aplicações Angular da Senior Sistemas",
5
5
  "keywords": [
6
6
  "angular",
package/public-api.d.ts CHANGED
@@ -16,6 +16,7 @@ export { LoadingComponent } from './lib/components/loading/loading.component';
16
16
  export { IassistIconComponent } from './lib/components/loading/iassist-icon.component';
17
17
  export { EntityListBaseComponent } from './lib/components/base/entity-list-base.component';
18
18
  export { KanbanBoardComponent, type KanbanColumn, type KanbanItem, type KanbanTag, type KanbanDropEvent } from './lib/components/kanban-board/kanban-board.component';
19
+ export { StepsComponent, type StepItem } from './lib/components/steps/steps.component';
19
20
  export { DynamicFormComponent } from './lib/components/dynamic-form/dynamic-form.component';
20
21
  export * from './lib/components/dynamic-form/models/dynamic-form.models';
21
22
  export * from './lib/components/dynamic-form/fields';