shirkasoft-ui-components 1.13.18 → 2.0.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.
Files changed (98) hide show
  1. package/README.md +415 -42
  2. package/fesm2022/shirkasoft-ui-components-breadcrumb.mjs +189 -100
  3. package/fesm2022/shirkasoft-ui-components-breadcrumb.mjs.map +1 -1
  4. package/fesm2022/shirkasoft-ui-components-button.mjs +367 -73
  5. package/fesm2022/shirkasoft-ui-components-button.mjs.map +1 -1
  6. package/fesm2022/shirkasoft-ui-components-chart.mjs +206 -142
  7. package/fesm2022/shirkasoft-ui-components-chart.mjs.map +1 -1
  8. package/fesm2022/shirkasoft-ui-components-config.mjs +976 -0
  9. package/fesm2022/shirkasoft-ui-components-config.mjs.map +1 -0
  10. package/fesm2022/shirkasoft-ui-components-confirm-dialog.mjs +307 -142
  11. package/fesm2022/shirkasoft-ui-components-confirm-dialog.mjs.map +1 -1
  12. package/fesm2022/shirkasoft-ui-components-date-picker.mjs +1624 -1400
  13. package/fesm2022/shirkasoft-ui-components-date-picker.mjs.map +1 -1
  14. package/fesm2022/shirkasoft-ui-components-fieldset.mjs +347 -92
  15. package/fesm2022/shirkasoft-ui-components-fieldset.mjs.map +1 -1
  16. package/fesm2022/shirkasoft-ui-components-file-upload.mjs +484 -293
  17. package/fesm2022/shirkasoft-ui-components-file-upload.mjs.map +1 -1
  18. package/fesm2022/shirkasoft-ui-components-icons.mjs +1141 -0
  19. package/fesm2022/shirkasoft-ui-components-icons.mjs.map +1 -0
  20. package/fesm2022/shirkasoft-ui-components-knob.mjs +395 -180
  21. package/fesm2022/shirkasoft-ui-components-knob.mjs.map +1 -1
  22. package/fesm2022/shirkasoft-ui-components-loading.mjs +505 -128
  23. package/fesm2022/shirkasoft-ui-components-loading.mjs.map +1 -1
  24. package/fesm2022/shirkasoft-ui-components-modal.mjs +311 -303
  25. package/fesm2022/shirkasoft-ui-components-modal.mjs.map +1 -1
  26. package/fesm2022/shirkasoft-ui-components-notification.mjs +188 -142
  27. package/fesm2022/shirkasoft-ui-components-notification.mjs.map +1 -1
  28. package/fesm2022/shirkasoft-ui-components-price-input.mjs +517 -277
  29. package/fesm2022/shirkasoft-ui-components-price-input.mjs.map +1 -1
  30. package/fesm2022/shirkasoft-ui-components-rail-sidebar.mjs +669 -289
  31. package/fesm2022/shirkasoft-ui-components-rail-sidebar.mjs.map +1 -1
  32. package/fesm2022/shirkasoft-ui-components-select.mjs +1014 -814
  33. package/fesm2022/shirkasoft-ui-components-select.mjs.map +1 -1
  34. package/fesm2022/shirkasoft-ui-components-sidebar.mjs +508 -184
  35. package/fesm2022/shirkasoft-ui-components-sidebar.mjs.map +1 -1
  36. package/fesm2022/shirkasoft-ui-components-skeleton.mjs +197 -57
  37. package/fesm2022/shirkasoft-ui-components-skeleton.mjs.map +1 -1
  38. package/fesm2022/shirkasoft-ui-components-table.mjs +1918 -1676
  39. package/fesm2022/shirkasoft-ui-components-table.mjs.map +1 -1
  40. package/fesm2022/shirkasoft-ui-components-tabs.mjs +419 -177
  41. package/fesm2022/shirkasoft-ui-components-tabs.mjs.map +1 -1
  42. package/fesm2022/shirkasoft-ui-components-tag.mjs +177 -51
  43. package/fesm2022/shirkasoft-ui-components-tag.mjs.map +1 -1
  44. package/fesm2022/shirkasoft-ui-components-text-field.mjs +687 -369
  45. package/fesm2022/shirkasoft-ui-components-text-field.mjs.map +1 -1
  46. package/fesm2022/shirkasoft-ui-components-theme-picker.mjs +466 -0
  47. package/fesm2022/shirkasoft-ui-components-theme-picker.mjs.map +1 -0
  48. package/fesm2022/shirkasoft-ui-components-theme.mjs +147 -0
  49. package/fesm2022/shirkasoft-ui-components-theme.mjs.map +1 -0
  50. package/fesm2022/shirkasoft-ui-components-timeline.mjs +791 -215
  51. package/fesm2022/shirkasoft-ui-components-timeline.mjs.map +1 -1
  52. package/fesm2022/shirkasoft-ui-components-toggle.mjs +205 -128
  53. package/fesm2022/shirkasoft-ui-components-toggle.mjs.map +1 -1
  54. package/fesm2022/shirkasoft-ui-components-tooltip.mjs +244 -180
  55. package/fesm2022/shirkasoft-ui-components-tooltip.mjs.map +1 -1
  56. package/fesm2022/shirkasoft-ui-components-utils.mjs +97 -125
  57. package/fesm2022/shirkasoft-ui-components-utils.mjs.map +1 -1
  58. package/fesm2022/shirkasoft-ui-components-wizard.mjs +673 -166
  59. package/fesm2022/shirkasoft-ui-components-wizard.mjs.map +1 -1
  60. package/fesm2022/shirkasoft-ui-components.mjs +0 -9
  61. package/package.json +37 -7
  62. package/src/baseline.css +2472 -0
  63. package/src/theme.css +15 -543
  64. package/src/themes/ocean.css +56 -0
  65. package/src/themes/sunset.css +55 -0
  66. package/src/themes/violet.css +25 -0
  67. package/src/tokens.css +612 -0
  68. package/types/shirkasoft-ui-components-breadcrumb.d.ts +59 -44
  69. package/types/shirkasoft-ui-components-button.d.ts +142 -49
  70. package/types/shirkasoft-ui-components-chart.d.ts +59 -44
  71. package/types/shirkasoft-ui-components-config.d.ts +357 -0
  72. package/types/shirkasoft-ui-components-confirm-dialog.d.ts +107 -65
  73. package/types/shirkasoft-ui-components-date-picker.d.ts +527 -373
  74. package/types/shirkasoft-ui-components-fieldset.d.ts +135 -59
  75. package/types/shirkasoft-ui-components-file-upload.d.ts +176 -106
  76. package/types/shirkasoft-ui-components-icons.d.ts +1430 -0
  77. package/types/shirkasoft-ui-components-knob.d.ts +151 -64
  78. package/types/shirkasoft-ui-components-loading.d.ts +155 -64
  79. package/types/shirkasoft-ui-components-modal.d.ts +134 -132
  80. package/types/shirkasoft-ui-components-notification.d.ts +63 -58
  81. package/types/shirkasoft-ui-components-price-input.d.ts +198 -85
  82. package/types/shirkasoft-ui-components-rail-sidebar.d.ts +262 -142
  83. package/types/shirkasoft-ui-components-select.d.ts +301 -192
  84. package/types/shirkasoft-ui-components-sidebar.d.ts +198 -92
  85. package/types/shirkasoft-ui-components-skeleton.d.ts +68 -27
  86. package/types/shirkasoft-ui-components-table.d.ts +849 -649
  87. package/types/shirkasoft-ui-components-tabs.d.ts +102 -61
  88. package/types/shirkasoft-ui-components-tag.d.ts +54 -23
  89. package/types/shirkasoft-ui-components-text-field.d.ts +231 -111
  90. package/types/shirkasoft-ui-components-theme-picker.d.ts +117 -0
  91. package/types/shirkasoft-ui-components-theme.d.ts +80 -0
  92. package/types/shirkasoft-ui-components-timeline.d.ts +326 -150
  93. package/types/shirkasoft-ui-components-toggle.d.ts +76 -45
  94. package/types/shirkasoft-ui-components-tooltip.d.ts +64 -43
  95. package/types/shirkasoft-ui-components-utils.d.ts +26 -17
  96. package/types/shirkasoft-ui-components-wizard.d.ts +236 -86
  97. package/types/shirkasoft-ui-components.d.ts +1 -2
  98. package/fesm2022/shirkasoft-ui-components.mjs.map +0 -1
@@ -1,6 +1,9 @@
1
- import * as _angular_core from '@angular/core';
2
- import { ControlValueAccessor, FormControl } from '@angular/forms';
3
-
1
+ /**
2
+ * Generated bundle index. Do not edit.
3
+ */
4
+ import { ControlValueAccessor, FormControl } from "@angular/forms";
5
+ import { FormValueControl } from "@angular/forms/signals";
6
+ import * as i0 from "@angular/core";
4
7
  /**
5
8
  * Shirkasoft UI Components.
6
9
  * Authors: Roberto Valladares Martin (Ansem13), Julio César García García (Sanjuli14).
@@ -16,85 +19,195 @@ import { ControlValueAccessor, FormControl } from '@angular/forms';
16
19
  * Text-based input (`type="text"` + `inputmode="decimal"`) with decimal
17
20
  * precision control, min/max clamping on blur and thousands formatting.
18
21
  */
19
- declare class PriceInputComponent implements ControlValueAccessor {
20
- /** Reactive control. When provided it takes precedence over `value`/`valueChange`. */
21
- control: _angular_core.InputSignal<FormControl<number | null> | undefined>;
22
- /** Numeric value (two-way), used when no `control` is bound. */
23
- value: _angular_core.ModelSignal<number | null>;
24
- /** Whether the input works as a percentage (two-way). */
25
- isPercentage: _angular_core.ModelSignal<boolean>;
26
- /** Label displayed above the field. */
27
- label: _angular_core.InputSignal<string>;
28
- /** id attribute applied to the native input. */
29
- inputId: _angular_core.InputSignal<string>;
30
- /** Marks the field as required. */
31
- required: _angular_core.InputSignal<boolean>;
32
- /** Disables the input. */
33
- disabled: _angular_core.InputSignal<boolean>;
34
- /** Minimum allowed value (clamped on blur). */
35
- min: _angular_core.InputSignal<number>;
36
- /** Maximum allowed value (clamped on blur). */
37
- max: _angular_core.InputSignal<number>;
38
- /** Maximum number of decimal places (0 = integer). */
39
- decimals: _angular_core.InputSignal<number>;
40
- /** Symbol shown in the mode toggle button when not a percentage. */
41
- currency: _angular_core.InputSignal<string>;
42
- /** Placeholder text of the native input. */
43
- placeholder: _angular_core.InputSignal<string>;
44
- /** Accessible label; falls back to `label`. */
45
- ariaLabel: _angular_core.InputSignal<string>;
46
- /** Blocks the minus sign from being typed. */
47
- preventNegative: _angular_core.InputSignal<boolean>;
48
- /** Shows the error styling on the field. */
49
- showError: _angular_core.InputSignal<boolean>;
50
- /** Message rendered when the field is in error state. */
51
- errorMessage: _angular_core.InputSignal<string>;
52
- private destroyRef;
53
- private transloco;
54
- /** Text currently shown in the input (raw while focused, formatted on blur). */
55
- displayText: _angular_core.WritableSignal<string>;
56
- /** Whether the native input currently has focus. */
57
- focused: _angular_core.WritableSignal<boolean>;
58
- /** Disabled state coming from the reactive control. */
59
- private controlDisabled;
60
- /** Prevents re-subscribing to the same form control. */
61
- private ctrlSubscribed;
62
- /** Bumped on control status changes / blur so error computeds refresh. */
63
- private statusTick;
64
- /**
65
- * Whether the error state is shown: forced with `showError`, or when the
66
- * bound `control` is invalid and has been touched or modified.
67
- */
68
- hasError: _angular_core.Signal<boolean>;
69
- /** Message shown under the field: `errorMessage` or one derived from the control errors. */
70
- errorText: _angular_core.Signal<string>;
71
- /** Effective disabled state combining the input and the form binding. */
72
- isDisabled: _angular_core.Signal<boolean>;
73
- /** Callbacks used by the ControlValueAccessor contract. */
74
- private onChange;
75
- private onTouched;
76
- constructor();
77
- /** Toggles between amount and percentage modes (unless disabled). */
78
- toggleMode(): void;
79
- /** Selects the whole value on focus so the user can type over it. */
80
- onFocus(event: FocusEvent): void;
81
- /** Clamps, rounds and formats the value when the field loses focus. */
82
- onBlur(): void;
83
- /** Blocks characters that would break the numeric format. */
84
- onKeydown(event: KeyboardEvent): void;
85
- /** Sanitizes the raw input (digits + one separator + optional sign) and writes the value once. */
86
- onInput(event: Event): void;
87
- /** Writes the value to the effective binding source. */
88
- private setValue;
89
- private roundTo;
90
- /** Formats a number with thousands separator and up to `decimals` places. */
91
- private formatNumber;
92
- writeValue(value: any): void;
93
- registerOnChange(fn: any): void;
94
- registerOnTouched(fn: any): void;
95
- setDisabledState(isDisabled: boolean): void;
96
- static ɵfac: _angular_core.ɵɵFactoryDeclaration<PriceInputComponent, never>;
97
- static ɵcmp: _angular_core.ɵɵComponentDeclaration<PriceInputComponent, "shk-price-input", never, { "control": { "alias": "control"; "required": false; "isSignal": true; }; "value": { "alias": "value"; "required": false; "isSignal": true; }; "isPercentage": { "alias": "isPercentage"; "required": false; "isSignal": true; }; "label": { "alias": "label"; "required": false; "isSignal": true; }; "inputId": { "alias": "inputId"; "required": false; "isSignal": true; }; "required": { "alias": "required"; "required": false; "isSignal": true; }; "disabled": { "alias": "disabled"; "required": false; "isSignal": true; }; "min": { "alias": "min"; "required": false; "isSignal": true; }; "max": { "alias": "max"; "required": false; "isSignal": true; }; "decimals": { "alias": "decimals"; "required": false; "isSignal": true; }; "currency": { "alias": "currency"; "required": false; "isSignal": true; }; "placeholder": { "alias": "placeholder"; "required": false; "isSignal": true; }; "ariaLabel": { "alias": "ariaLabel"; "required": false; "isSignal": true; }; "preventNegative": { "alias": "preventNegative"; "required": false; "isSignal": true; }; "showError": { "alias": "showError"; "required": false; "isSignal": true; }; "errorMessage": { "alias": "errorMessage"; "required": false; "isSignal": true; }; }, { "value": "valueChange"; "isPercentage": "isPercentageChange"; }, never, never, true, never>;
98
- }
99
-
100
- export { PriceInputComponent };
22
+ export declare class PriceInputComponent implements ControlValueAccessor, FormValueControl<number | null> {
23
+ /** Reactive control. When provided it takes precedence over `value`/`valueChange`. */
24
+ control: import("@angular/core").InputSignal<FormControl<number | null> | undefined>;
25
+ /** Numeric value (two-way), used when no `control` is bound. */
26
+ value: import("@angular/core").ModelSignal<number | null>;
27
+ /** Whether the input works as a percentage (two-way). */
28
+ isPercentage: import("@angular/core").ModelSignal<boolean>;
29
+ /** Label displayed above the field. */
30
+ label: import("@angular/core").InputSignal<string>;
31
+ /** id attribute applied to the native input. */
32
+ inputId: import("@angular/core").InputSignal<string>;
33
+ /** Marks the field as required. */
34
+ required: import("@angular/core").InputSignal<boolean>;
35
+ /** Disables the input. */
36
+ disabled: import("@angular/core").InputSignal<boolean>;
37
+ /** Minimum allowed value (clamped on blur). */
38
+ min: import("@angular/core").InputSignal<number | undefined>;
39
+ /** Maximum allowed value (clamped on blur). */
40
+ max: import("@angular/core").InputSignal<number | undefined>;
41
+ /**
42
+ * Maximum number of decimal places (0 = integer). Unset = the `numbers.decimals`
43
+ * option, else the digits of the `numbers.currency` option (2 for USD).
44
+ */
45
+ decimals: import("@angular/core").InputSignal<number | undefined>;
46
+ /**
47
+ * Symbol shown in the mode toggle button when not a percentage. Empty = the
48
+ * `numbers.currencySymbol` option, else the symbol of `numbers.currency` ('$').
49
+ */
50
+ currency: import("@angular/core").InputSignal<string>;
51
+ /** Placeholder text of the native input. */
52
+ placeholder: import("@angular/core").InputSignal<string>;
53
+ /** Accessible label; falls back to `label`. */
54
+ ariaLabel: import("@angular/core").InputSignal<string>;
55
+ /** Blocks the minus sign from being typed. */
56
+ preventNegative: import("@angular/core").InputSignal<boolean>;
57
+ /** Shows the error styling on the field. */
58
+ showError: import("@angular/core").InputSignal<boolean>;
59
+ /** Message rendered when the field is in error state. */
60
+ errorMessage: import("@angular/core").InputSignal<string>;
61
+ /** Emitted on blur so Signal Forms can mark the field as touched. */
62
+ touch: import("@angular/core").OutputEmitterRef<void>;
63
+ private destroyRef;
64
+ private transloco;
65
+ /** Library-wide options: currency, decimals and number separators. */
66
+ private readonly config;
67
+ /** Decimal places actually used. */
68
+ private readonly effectiveDecimals;
69
+ /** Locale of the grouping/decimal separators. */
70
+ private readonly numbersLocale;
71
+ /** Decimal separator of the locale (`.` or `,`), used while editing. */
72
+ private readonly decimalSeparator;
73
+ /** Symbol shown in the toggle: input, `numbers.currencySymbol`, or the currency's symbol. */
74
+ readonly displaySymbol: import("@angular/core").Signal<string>;
75
+ /** Text currently shown in the input (raw while focused, formatted on blur). */
76
+ displayText: import("@angular/core").WritableSignal<string>;
77
+ /** Whether the native input currently has focus. */
78
+ focused: import("@angular/core").WritableSignal<boolean>;
79
+ /** Disabled state coming from the reactive control. */
80
+ private controlDisabled;
81
+ /** Prevents re-subscribing to the same form control. */
82
+ private ctrlSubscribed;
83
+ /** Bumped on control status changes / blur so error computeds refresh. */
84
+ private statusTick;
85
+ /**
86
+ * Whether the error state is shown: forced with `showError`, or when the
87
+ * bound `control` is invalid and has been touched or modified.
88
+ */
89
+ hasError: import("@angular/core").Signal<boolean>;
90
+ /** Message shown under the field: `errorMessage` or one derived from the control errors. */
91
+ errorText: import("@angular/core").Signal<string>;
92
+ /** Effective disabled state combining the input and the form binding. */
93
+ isDisabled: import("@angular/core").Signal<boolean>;
94
+ /** Callbacks used by the ControlValueAccessor contract. */
95
+ private onChange;
96
+ private onTouched;
97
+ constructor();
98
+ /** Toggles between amount and percentage modes (unless disabled). */
99
+ toggleMode(): void;
100
+ /**
101
+ * Switches to the editable form (no grouping, locale decimal separator) and
102
+ * selects it so the user can type over it or edit in the middle safely.
103
+ */
104
+ onFocus(event: FocusEvent): void;
105
+ /** Clamps, rounds and formats the value when the field loses focus. */
106
+ onBlur(): void;
107
+ /** Blocks characters that would break the numeric format. */
108
+ onKeydown(event: KeyboardEvent): void;
109
+ /** Sanitizes the raw input (digits + one separator + optional sign) and writes the value once. */
110
+ onInput(event: Event): void;
111
+ /** Writes the value to the effective binding source. */
112
+ private setValue;
113
+ private roundTo;
114
+ /** Formats a number with the locale's separators and up to `decimals` places. */
115
+ private formatNumber;
116
+ /** Number as edited: no grouping, locale decimal separator ("1234,5" for es-ES). */
117
+ private editableNumber;
118
+ /** Parses the editable text back to a number (either separator is accepted). */
119
+ private parseEditable;
120
+ /** Value of the effective binding source (control or `value`). */
121
+ private currentValue;
122
+ writeValue(value: any): void;
123
+ registerOnChange(fn: any): void;
124
+ registerOnTouched(fn: any): void;
125
+ setDisabledState(isDisabled: boolean): void;
126
+ static ɵfac: i0.ɵɵFactoryDeclaration<PriceInputComponent, never>;
127
+ static ɵcmp: i0.ɵɵComponentDeclaration<PriceInputComponent, "shk-price-input", never, {
128
+ "control": {
129
+ "alias": "control";
130
+ "required": false;
131
+ "isSignal": true;
132
+ };
133
+ "value": {
134
+ "alias": "value";
135
+ "required": false;
136
+ "isSignal": true;
137
+ };
138
+ "isPercentage": {
139
+ "alias": "isPercentage";
140
+ "required": false;
141
+ "isSignal": true;
142
+ };
143
+ "label": {
144
+ "alias": "label";
145
+ "required": false;
146
+ "isSignal": true;
147
+ };
148
+ "inputId": {
149
+ "alias": "inputId";
150
+ "required": false;
151
+ "isSignal": true;
152
+ };
153
+ "required": {
154
+ "alias": "required";
155
+ "required": false;
156
+ "isSignal": true;
157
+ };
158
+ "disabled": {
159
+ "alias": "disabled";
160
+ "required": false;
161
+ "isSignal": true;
162
+ };
163
+ "min": {
164
+ "alias": "min";
165
+ "required": false;
166
+ "isSignal": true;
167
+ };
168
+ "max": {
169
+ "alias": "max";
170
+ "required": false;
171
+ "isSignal": true;
172
+ };
173
+ "decimals": {
174
+ "alias": "decimals";
175
+ "required": false;
176
+ "isSignal": true;
177
+ };
178
+ "currency": {
179
+ "alias": "currency";
180
+ "required": false;
181
+ "isSignal": true;
182
+ };
183
+ "placeholder": {
184
+ "alias": "placeholder";
185
+ "required": false;
186
+ "isSignal": true;
187
+ };
188
+ "ariaLabel": {
189
+ "alias": "ariaLabel";
190
+ "required": false;
191
+ "isSignal": true;
192
+ };
193
+ "preventNegative": {
194
+ "alias": "preventNegative";
195
+ "required": false;
196
+ "isSignal": true;
197
+ };
198
+ "showError": {
199
+ "alias": "showError";
200
+ "required": false;
201
+ "isSignal": true;
202
+ };
203
+ "errorMessage": {
204
+ "alias": "errorMessage";
205
+ "required": false;
206
+ "isSignal": true;
207
+ };
208
+ }, {
209
+ "value": "valueChange";
210
+ "isPercentage": "isPercentageChange";
211
+ "touch": "touch";
212
+ }, never, never, true, never>;
213
+ }