@luzmo/ngx-lucero 2.3.0-beta.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.
@@ -1,8 +1,8 @@
1
1
  import { OnChanges, SimpleChanges } from '@angular/core';
2
2
  import '@luzmo/lucero/progress-steps';
3
- import type { LuzmoProgressSteps as LuzmoProgressStepsHostElement, ProgressStepsLabels, ProgressTreeNode } from '@luzmo/lucero/progress-steps';
3
+ import type { LuzmoProgressSteps as LuzmoProgressStepsHostElement, ProgressStepsDisplayMode, ProgressStepsLabels, ProgressTreeNode } from '@luzmo/lucero/progress-steps';
4
4
  import * as i0 from "@angular/core";
5
- export type { LocalizedString, ProgressStepsLabels, ProgressStepsStatuses, ProgressTreeNode, ProgressTreeNodeDescriptionMetadata } from '@luzmo/lucero/progress-steps';
5
+ export type { LocalizedString, ProgressStepsDisplayMode, ProgressStepsLabels, ProgressStepsStatuses, ProgressStepsToggleDetail, ProgressTreeNode, ProgressTreeNodeDescriptionMetadata } from '@luzmo/lucero/progress-steps';
6
6
  export declare class LuzmoProgressSteps implements OnChanges {
7
7
  private readonly elementRef;
8
8
  private readonly renderer;
@@ -11,25 +11,26 @@ export declare class LuzmoProgressSteps implements OnChanges {
11
11
  private readonly listenerCleanup;
12
12
  /** The underlying custom element instance. Use to call imperative methods. */
13
13
  get nativeElement(): LuzmoProgressStepsHostElement;
14
- /** The progress tree from the backend. The root node's children are rendered as main steps. */
14
+ /** The progress tree. The root's children are the main steps. Replace the whole tree on every update; keep the root `id` for the same run. */
15
15
  progress?: ProgressTreeNode | null;
16
- /** Locale for resolving localized strings in description metadata. Defaults to 'en'. */
16
+ /** Locale for resolving localized strings in description metadata. */
17
17
  locale?: string;
18
- /** When true, collapses all auto-expanded steps. Manually expanded steps remain open. */
18
+ /** Signals that the run has finished. The summary line then settles as soon as no step is running, instead of after a short quiet period. */
19
19
  collapsed?: boolean;
20
- /** Display mode for the progress steps. - 'detailed' (default): Shows full descriptions and substeps with expand/collapse - 'compact': Shows only step names without substeps or expand/collapse */
21
- displayMode?: ('detailed' | 'compact');
22
- /** When true, hides all steps behind a single "{n} steps completed" toggle line. Clicking the toggle expands/collapses the full step list. */
20
+ /** 'detailed' (default): the history lists main steps with their substeps - 'compact': the history lists main steps only */
21
+ displayMode?: ProgressStepsDisplayMode;
23
22
  condensed?: boolean;
24
- /** Labels used for visible text and screen readers. The default values are in English and can be overridden to localize the content. Use `{{count}}` in `stepCompleted` / `stepsCompleted` as a placeholder for the step count. */
25
- labels?: ProgressStepsLabels;
26
- /** When true, disables all entry animations (stepFadeIn, substepFadeIn). */
23
+ /** Visible and announced copy. Partial overrides are merged over the English defaults. `{{count}}` is replaced in the count labels. */
24
+ labels?: Partial<ProgressStepsLabels>;
25
+ /** Disables the shimmer and transitions. */
27
26
  noAnimate?: boolean;
27
+ /** Whether the step history is shown. Closes when a run with another root `id` starts. */
28
+ open?: boolean;
28
29
  size?: ('xxs' | 'xs' | 's' | 'm' | 'l' | 'xl' | 'xxl');
29
- /** Fired when a step is collapsed */
30
- readonly luzmoStepCollapsed: import("@angular/core").OutputEmitterRef<CustomEvent<unknown>>;
31
- /** Fired when a step is expanded */
30
+ /** The user opened the step history. `detail.nodeId` is the progress root id. */
32
31
  readonly luzmoStepExpanded: import("@angular/core").OutputEmitterRef<CustomEvent<unknown>>;
32
+ /** The user closed the step history. `detail.nodeId` is the progress root id. */
33
+ readonly luzmoStepCollapsed: import("@angular/core").OutputEmitterRef<CustomEvent<unknown>>;
33
34
  constructor();
34
35
  ngOnChanges(changes: SimpleChanges): void;
35
36
  /**
@@ -41,7 +42,7 @@ export declare class LuzmoProgressSteps implements OnChanges {
41
42
  private setHostProperty;
42
43
  private bindEvents;
43
44
  static ɵfac: i0.ɵɵFactoryDeclaration<LuzmoProgressSteps, never>;
44
- static ɵcmp: i0.ɵɵComponentDeclaration<LuzmoProgressSteps, "luzmo-progress-steps", ["luzmoProgressSteps"], { "progress": { "alias": "progress"; "required": false; }; "locale": { "alias": "locale"; "required": false; }; "collapsed": { "alias": "collapsed"; "required": false; }; "displayMode": { "alias": "displayMode"; "required": false; }; "condensed": { "alias": "condensed"; "required": false; }; "labels": { "alias": "labels"; "required": false; }; "noAnimate": { "alias": "noAnimate"; "required": false; }; "size": { "alias": "size"; "required": false; }; }, { "luzmoStepCollapsed": "luzmo-step-collapsed"; "luzmoStepExpanded": "luzmo-step-expanded"; }, never, ["*"], true, never>;
45
+ static ɵcmp: i0.ɵɵComponentDeclaration<LuzmoProgressSteps, "luzmo-progress-steps", ["luzmoProgressSteps"], { "progress": { "alias": "progress"; "required": false; }; "locale": { "alias": "locale"; "required": false; }; "collapsed": { "alias": "collapsed"; "required": false; }; "displayMode": { "alias": "displayMode"; "required": false; }; "condensed": { "alias": "condensed"; "required": false; }; "labels": { "alias": "labels"; "required": false; }; "noAnimate": { "alias": "noAnimate"; "required": false; }; "open": { "alias": "open"; "required": false; }; "size": { "alias": "size"; "required": false; }; }, { "luzmoStepExpanded": "luzmo-step-expanded"; "luzmoStepCollapsed": "luzmo-step-collapsed"; }, never, ["*"], true, never>;
45
46
  }
46
47
  /** The underlying custom element type for LuzmoProgressSteps */
47
48
  export type LuzmoProgressStepsElement = LuzmoProgressStepsHostElement;
@@ -15,25 +15,26 @@ export class LuzmoProgressSteps {
15
15
  get nativeElement() {
16
16
  return this.host;
17
17
  }
18
- /** The progress tree from the backend. The root node's children are rendered as main steps. */
18
+ /** The progress tree. The root's children are the main steps. Replace the whole tree on every update; keep the root `id` for the same run. */
19
19
  progress;
20
- /** Locale for resolving localized strings in description metadata. Defaults to 'en'. */
20
+ /** Locale for resolving localized strings in description metadata. */
21
21
  locale;
22
- /** When true, collapses all auto-expanded steps. Manually expanded steps remain open. */
22
+ /** Signals that the run has finished. The summary line then settles as soon as no step is running, instead of after a short quiet period. */
23
23
  collapsed;
24
- /** Display mode for the progress steps. - 'detailed' (default): Shows full descriptions and substeps with expand/collapse - 'compact': Shows only step names without substeps or expand/collapse */
24
+ /** 'detailed' (default): the history lists main steps with their substeps - 'compact': the history lists main steps only */
25
25
  displayMode;
26
- /** When true, hides all steps behind a single "{n} steps completed" toggle line. Clicking the toggle expands/collapses the full step list. */
27
26
  condensed;
28
- /** Labels used for visible text and screen readers. The default values are in English and can be overridden to localize the content. Use `{{count}}` in `stepCompleted` / `stepsCompleted` as a placeholder for the step count. */
27
+ /** Visible and announced copy. Partial overrides are merged over the English defaults. `{{count}}` is replaced in the count labels. */
29
28
  labels;
30
- /** When true, disables all entry animations (stepFadeIn, substepFadeIn). */
29
+ /** Disables the shimmer and transitions. */
31
30
  noAnimate;
31
+ /** Whether the step history is shown. Closes when a run with another root `id` starts. */
32
+ open;
32
33
  size;
33
- /** Fired when a step is collapsed */
34
- luzmoStepCollapsed = output({ alias: 'luzmo-step-collapsed' });
35
- /** Fired when a step is expanded */
34
+ /** The user opened the step history. `detail.nodeId` is the progress root id. */
36
35
  luzmoStepExpanded = output({ alias: 'luzmo-step-expanded' });
36
+ /** The user closed the step history. `detail.nodeId` is the progress root id. */
37
+ luzmoStepCollapsed = output({ alias: 'luzmo-step-collapsed' });
37
38
  constructor() {
38
39
  this.bindEvents();
39
40
  this.destroyRef.onDestroy(() => {
@@ -66,6 +67,9 @@ export class LuzmoProgressSteps {
66
67
  case 'noAnimate':
67
68
  this.setHostProperty('noAnimate', changes['noAnimate'].currentValue);
68
69
  break;
70
+ case 'open':
71
+ this.setHostProperty('open', changes['open'].currentValue);
72
+ break;
69
73
  case 'size':
70
74
  this.setHostProperty('size', changes['size'].currentValue);
71
75
  break;
@@ -84,15 +88,15 @@ export class LuzmoProgressSteps {
84
88
  this.renderer.setProperty(this.host, key, value);
85
89
  }
86
90
  bindEvents() {
87
- this.listenerCleanup.push(this.renderer.listen(this.host, 'luzmo-step-collapsed', (event) => {
88
- this.luzmoStepCollapsed.emit(event);
89
- }));
90
91
  this.listenerCleanup.push(this.renderer.listen(this.host, 'luzmo-step-expanded', (event) => {
91
92
  this.luzmoStepExpanded.emit(event);
92
93
  }));
94
+ this.listenerCleanup.push(this.renderer.listen(this.host, 'luzmo-step-collapsed', (event) => {
95
+ this.luzmoStepCollapsed.emit(event);
96
+ }));
93
97
  }
94
98
  static ɵfac = function LuzmoProgressSteps_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || LuzmoProgressSteps)(); };
95
- static ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: LuzmoProgressSteps, selectors: [["luzmo-progress-steps"]], inputs: { progress: "progress", locale: "locale", collapsed: "collapsed", displayMode: "displayMode", condensed: "condensed", labels: "labels", noAnimate: "noAnimate", size: "size" }, outputs: { luzmoStepCollapsed: "luzmo-step-collapsed", luzmoStepExpanded: "luzmo-step-expanded" }, exportAs: ["luzmoProgressSteps"], features: [i0.ɵɵNgOnChangesFeature], ngContentSelectors: _c0, decls: 1, vars: 0, template: function LuzmoProgressSteps_Template(rf, ctx) { if (rf & 1) {
99
+ static ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: LuzmoProgressSteps, selectors: [["luzmo-progress-steps"]], inputs: { progress: "progress", locale: "locale", collapsed: "collapsed", displayMode: "displayMode", condensed: "condensed", labels: "labels", noAnimate: "noAnimate", open: "open", size: "size" }, outputs: { luzmoStepExpanded: "luzmo-step-expanded", luzmoStepCollapsed: "luzmo-step-collapsed" }, exportAs: ["luzmoProgressSteps"], features: [i0.ɵɵNgOnChangesFeature], ngContentSelectors: _c0, decls: 1, vars: 0, template: function LuzmoProgressSteps_Template(rf, ctx) { if (rf & 1) {
96
100
  i0.ɵɵprojectionDef();
97
101
  i0.ɵɵprojection(0);
98
102
  } }, encapsulation: 2 });
@@ -127,8 +131,11 @@ export class LuzmoProgressSteps {
127
131
  }], noAnimate: [{
128
132
  type: Input,
129
133
  args: [{ alias: 'noAnimate' }]
134
+ }], open: [{
135
+ type: Input,
136
+ args: [{ alias: 'open' }]
130
137
  }], size: [{
131
138
  type: Input,
132
139
  args: [{ alias: 'size' }]
133
- }], luzmoStepCollapsed: [{ type: i0.Output, args: ["luzmo-step-collapsed"] }], luzmoStepExpanded: [{ type: i0.Output, args: ["luzmo-step-expanded"] }] }); })();
140
+ }], luzmoStepExpanded: [{ type: i0.Output, args: ["luzmo-step-expanded"] }], luzmoStepCollapsed: [{ type: i0.Output, args: ["luzmo-step-collapsed"] }] }); })();
134
141
  (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(LuzmoProgressSteps, { className: "LuzmoProgressSteps", filePath: "components/progress-steps.ts", lineNumber: 16 }); })();
package/package.json CHANGED
@@ -29,9 +29,9 @@
29
29
  "peerDependencies": {
30
30
  "@angular/core": "^17.3.0 || ^18.0.0 || ^19.0.0 || ^20.0.0 || ^21.0.0 || ^22.0.0",
31
31
  "@angular/forms": "^17.3.0 || ^18.0.0 || ^19.0.0 || ^20.0.0 || ^21.0.0 || ^22.0.0",
32
- "@luzmo/lucero": "2.3.0-beta.0"
32
+ "@luzmo/lucero": "2.4.0"
33
33
  },
34
- "version": "2.3.0-beta.0",
34
+ "version": "2.4.0",
35
35
  "peerDependenciesMeta": {
36
36
  "@angular/forms": {
37
37
  "optional": true