@tekus/design-system 5.36.0 → 5.38.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/assets/tokens/tk-foundations.json +4 -0
- package/fesm2022/tekus-design-system-components-autocomplete.mjs +7 -17
- package/fesm2022/tekus-design-system-components-autocomplete.mjs.map +1 -1
- package/fesm2022/tekus-design-system-components-avatar.mjs +120 -0
- package/fesm2022/tekus-design-system-components-avatar.mjs.map +1 -0
- package/fesm2022/tekus-design-system-components-button.mjs +2 -2
- package/fesm2022/tekus-design-system-components-button.mjs.map +1 -1
- package/fesm2022/tekus-design-system-components-card.mjs +1 -1
- package/fesm2022/tekus-design-system-components-card.mjs.map +1 -1
- package/fesm2022/tekus-design-system-components-checkbox.mjs +9 -3
- package/fesm2022/tekus-design-system-components-checkbox.mjs.map +1 -1
- package/fesm2022/tekus-design-system-components-color-picker.mjs +203 -29
- package/fesm2022/tekus-design-system-components-color-picker.mjs.map +1 -1
- package/fesm2022/tekus-design-system-components-date-picker.mjs +16 -3
- package/fesm2022/tekus-design-system-components-date-picker.mjs.map +1 -1
- package/fesm2022/tekus-design-system-components-grid-container.mjs +181 -0
- package/fesm2022/tekus-design-system-components-grid-container.mjs.map +1 -0
- package/fesm2022/tekus-design-system-components-input-number.mjs +37 -3
- package/fesm2022/tekus-design-system-components-input-number.mjs.map +1 -1
- package/fesm2022/tekus-design-system-components-input-text.mjs +2 -2
- package/fesm2022/tekus-design-system-components-input-text.mjs.map +1 -1
- package/fesm2022/tekus-design-system-components-menu.mjs +2 -2
- package/fesm2022/tekus-design-system-components-menu.mjs.map +1 -1
- package/fesm2022/tekus-design-system-components-multiselect.mjs +2 -2
- package/fesm2022/tekus-design-system-components-multiselect.mjs.map +1 -1
- package/fesm2022/tekus-design-system-components-panel-menu.mjs +2 -2
- package/fesm2022/tekus-design-system-components-panel-menu.mjs.map +1 -1
- package/fesm2022/tekus-design-system-components-radio-button.mjs +9 -3
- package/fesm2022/tekus-design-system-components-radio-button.mjs.map +1 -1
- package/fesm2022/tekus-design-system-components-section.mjs +63 -0
- package/fesm2022/tekus-design-system-components-section.mjs.map +1 -0
- package/fesm2022/tekus-design-system-components-select.mjs +37 -32
- package/fesm2022/tekus-design-system-components-select.mjs.map +1 -1
- package/fesm2022/tekus-design-system-components-sidebar-layout.mjs +2 -2
- package/fesm2022/tekus-design-system-components-sidebar-layout.mjs.map +1 -1
- package/fesm2022/tekus-design-system-components-table.mjs +1 -1
- package/fesm2022/tekus-design-system-components-table.mjs.map +1 -1
- package/fesm2022/tekus-design-system-components-tabs.mjs +2 -2
- package/fesm2022/tekus-design-system-components-tabs.mjs.map +1 -1
- package/fesm2022/tekus-design-system-components-textarea.mjs +2 -2
- package/fesm2022/tekus-design-system-components-textarea.mjs.map +1 -1
- package/fesm2022/tekus-design-system-components-time-picker.mjs +13 -3
- package/fesm2022/tekus-design-system-components-time-picker.mjs.map +1 -1
- package/fesm2022/tekus-design-system-components-toggle.mjs +4 -3
- package/fesm2022/tekus-design-system-components-toggle.mjs.map +1 -1
- package/fesm2022/tekus-design-system-components-toolbar.mjs +2 -2
- package/fesm2022/tekus-design-system-components-toolbar.mjs.map +1 -1
- package/fesm2022/tekus-design-system-components-topbar.mjs +2 -2
- package/fesm2022/tekus-design-system-components-topbar.mjs.map +1 -1
- package/fesm2022/tekus-design-system-components-tree-table.mjs +94 -0
- package/fesm2022/tekus-design-system-components-tree-table.mjs.map +1 -0
- package/fesm2022/tekus-design-system-core-types.mjs +26 -10
- package/fesm2022/tekus-design-system-core-types.mjs.map +1 -1
- package/fesm2022/tekus-design-system-core.mjs +26 -10
- package/fesm2022/tekus-design-system-core.mjs.map +1 -1
- package/fesm2022/tekus-design-system-directives-gird-item.mjs +1 -1
- package/fesm2022/tekus-design-system-directives-gird-item.mjs.map +1 -1
- package/package.json +17 -1
- package/scss/_config.scss +242 -0
- package/scss/tk-bundle.scss +105 -0
- package/styles/variables.css +1 -0
- package/types/tekus-design-system-components-autocomplete.d.ts +3 -12
- package/types/tekus-design-system-components-avatar.d.ts +104 -0
- package/types/tekus-design-system-components-checkbox.d.ts +7 -1
- package/types/tekus-design-system-components-color-picker.d.ts +75 -12
- package/types/tekus-design-system-components-date-picker.d.ts +11 -1
- package/types/tekus-design-system-components-grid-container.d.ts +123 -0
- package/types/tekus-design-system-components-input-number.d.ts +35 -1
- package/types/tekus-design-system-components-radio-button.d.ts +7 -1
- package/types/tekus-design-system-components-section.d.ts +45 -0
- package/types/tekus-design-system-components-select.d.ts +2 -6
- package/types/tekus-design-system-components-time-picker.d.ts +8 -1
- package/types/tekus-design-system-components-toggle.d.ts +2 -1
- package/types/tekus-design-system-components-tree-table.d.ts +62 -0
- package/types/tekus-design-system-core-types.d.ts +7 -7
- package/types/tekus-design-system-core.d.ts +7 -7
- package/types/tekus-design-system-directives-gird-item.d.ts +1 -1
|
@@ -68,16 +68,6 @@ declare class AutocompleteComponent<T = unknown> implements ControlValueAccessor
|
|
|
68
68
|
* Allows usage with the syntax: `[(model)]="myValue"`.
|
|
69
69
|
*/
|
|
70
70
|
model: _angular_core.ModelSignal<AutocompleteValue<T> | undefined>;
|
|
71
|
-
/**
|
|
72
|
-
* @event modelChange
|
|
73
|
-
* @description
|
|
74
|
-
* Emits whenever the value changes.
|
|
75
|
-
* Payload: the selected item(s) of type `AutocompleteValue<T>`.
|
|
76
|
-
*
|
|
77
|
-
* @example
|
|
78
|
-
* <tk-autocomplete (modelChange)="onChange($event)"></tk-autocomplete>
|
|
79
|
-
*/
|
|
80
|
-
modelChange: _angular_core.OutputEmitterRef<AutocompleteValue<T>>;
|
|
81
71
|
private onChangeFn;
|
|
82
72
|
private onTouchedFn;
|
|
83
73
|
private readonly init;
|
|
@@ -121,7 +111,8 @@ declare class AutocompleteComponent<T = unknown> implements ControlValueAccessor
|
|
|
121
111
|
* @method handleChange
|
|
122
112
|
* @description
|
|
123
113
|
* Handles value changes from the autocomplete component.
|
|
124
|
-
* Updates Angular Forms
|
|
114
|
+
* Updates Angular Forms and Signals. `model.set()` emits the model's
|
|
115
|
+
* auto-generated `modelChange` output — no separate emit needed.
|
|
125
116
|
*
|
|
126
117
|
* @param {AutocompleteValue<T>} value - The new selected value(s).
|
|
127
118
|
*/
|
|
@@ -150,7 +141,7 @@ declare class AutocompleteComponent<T = unknown> implements ControlValueAccessor
|
|
|
150
141
|
*/
|
|
151
142
|
get effectiveControl(): FormControl | undefined;
|
|
152
143
|
static ɵfac: _angular_core.ɵɵFactoryDeclaration<AutocompleteComponent<any>, never>;
|
|
153
|
-
static ɵcmp: _angular_core.ɵɵComponentDeclaration<AutocompleteComponent<any>, "tk-autocomplete", never, { "id": { "alias": "id"; "required": false; "isSignal": true; }; "icon": { "alias": "icon"; "required": false; "isSignal": true; }; "control": { "alias": "control"; "required": false; "isSignal": true; }; "label": { "alias": "label"; "required": false; "isSignal": true; }; "disabled": { "alias": "disabled"; "required": false; "isSignal": true; }; "errorMessage": { "alias": "errorMessage"; "required": false; "isSignal": true; }; "hint": { "alias": "hint"; "required": false; "isSignal": true; }; "model": { "alias": "model"; "required": false; "isSignal": true; }; }, { "model": "modelChange";
|
|
144
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<AutocompleteComponent<any>, "tk-autocomplete", never, { "id": { "alias": "id"; "required": false; "isSignal": true; }; "icon": { "alias": "icon"; "required": false; "isSignal": true; }; "control": { "alias": "control"; "required": false; "isSignal": true; }; "label": { "alias": "label"; "required": false; "isSignal": true; }; "disabled": { "alias": "disabled"; "required": false; "isSignal": true; }; "errorMessage": { "alias": "errorMessage"; "required": false; "isSignal": true; }; "hint": { "alias": "hint"; "required": false; "isSignal": true; }; "model": { "alias": "model"; "required": false; "isSignal": true; }; }, { "model": "modelChange"; }, never, never, true, never>;
|
|
154
145
|
}
|
|
155
146
|
|
|
156
147
|
export { AutocompleteComponent };
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
import * as _angular_core from '@angular/core';
|
|
2
|
+
|
|
3
|
+
type AvatarVariant = 'text' | 'icon' | 'image';
|
|
4
|
+
type AvatarSeverity = 'secondary' | 'primary' | 'contrast';
|
|
5
|
+
type AvatarSize = 's' | 'm' | 'l' | 'xl';
|
|
6
|
+
/**
|
|
7
|
+
* Maximum number of characters rendered by the `'text'` variant. This variant is
|
|
8
|
+
* designed for initials (e.g. `'AB'`); longer strings break the layout at every
|
|
9
|
+
* size, so `value` is always truncated to this length rather than allowed to overflow.
|
|
10
|
+
*/
|
|
11
|
+
declare const AVATAR_TEXT_MAX_LENGTH = 2;
|
|
12
|
+
/**
|
|
13
|
+
* @component AvatarComponent
|
|
14
|
+
* @description
|
|
15
|
+
* A component used to represent a user, entity, or placeholder with initials, an icon, or an image.
|
|
16
|
+
*
|
|
17
|
+
* This component supports:
|
|
18
|
+
* - `variant`: What the avatar displays. Options: `'text' | 'icon' | 'image'`.
|
|
19
|
+
* - `severity`: The color scheme of the avatar. Options: `'secondary' | 'primary' | 'contrast'`. Ignored when `variant` is `'image'`.
|
|
20
|
+
* - `size`: The size of the avatar. Options: `'s' | 'm' | 'l' | 'xl'`.
|
|
21
|
+
* - `value`: The initials to display for the `'text'` variant. Limited to 2 characters — longer values are truncated.
|
|
22
|
+
* - `icon`: The icon name to display for the `'icon'` variant, rendered via `tk-icon`.
|
|
23
|
+
* - `image` / `alt`: The image source and accessible text for the `'image'` variant.
|
|
24
|
+
* - `ariaLabel`: The accessible name for the `'text'` and `'icon'` variants.
|
|
25
|
+
*
|
|
26
|
+
* @usage
|
|
27
|
+
* ### Basic Usage
|
|
28
|
+
* ```html
|
|
29
|
+
* <tk-avatar variant="text" value="AB" severity="primary" size="m" ariaLabel="Ana Bermúdez"></tk-avatar>
|
|
30
|
+
* <tk-avatar variant="icon" icon="user" severity="secondary" size="m" ariaLabel="Usuario sin foto"></tk-avatar>
|
|
31
|
+
* <tk-avatar variant="image" image="/assets/avatar.png" alt="Ana Bermúdez" size="m"></tk-avatar>
|
|
32
|
+
* ```
|
|
33
|
+
*/
|
|
34
|
+
declare class AvatarComponent {
|
|
35
|
+
/**
|
|
36
|
+
* What the avatar displays.
|
|
37
|
+
* @default 'text'
|
|
38
|
+
*/
|
|
39
|
+
variant: _angular_core.InputSignal<AvatarVariant>;
|
|
40
|
+
/**
|
|
41
|
+
* The color scheme of the avatar. Ignored when `variant` is `'image'`.
|
|
42
|
+
* @default 'secondary'
|
|
43
|
+
*/
|
|
44
|
+
severity: _angular_core.InputSignal<AvatarSeverity>;
|
|
45
|
+
/**
|
|
46
|
+
* The size of the avatar.
|
|
47
|
+
* @default 'm'
|
|
48
|
+
*/
|
|
49
|
+
size: _angular_core.InputSignal<AvatarSize>;
|
|
50
|
+
/**
|
|
51
|
+
* The initials to display. Only used when `variant` is `'text'`.
|
|
52
|
+
*
|
|
53
|
+
* Limited to {@link AVATAR_TEXT_MAX_LENGTH} characters — this variant is meant
|
|
54
|
+
* for initials (e.g. `'AB'`), not arbitrary text. Longer values are silently
|
|
55
|
+
* truncated (see `displayValue`) since they overflow the avatar at every size.
|
|
56
|
+
*/
|
|
57
|
+
value: _angular_core.InputSignal<string>;
|
|
58
|
+
/** The icon name to display, forwarded to `tk-icon`. Only used when `variant` is `'icon'`. */
|
|
59
|
+
icon: _angular_core.InputSignal<string>;
|
|
60
|
+
/** The image source. Only used when `variant` is `'image'`. */
|
|
61
|
+
image: _angular_core.InputSignal<string>;
|
|
62
|
+
/** The accessible alt text for the image. Only used when `variant` is `'image'`. */
|
|
63
|
+
alt: _angular_core.InputSignal<string>;
|
|
64
|
+
/**
|
|
65
|
+
* The accessible name announced by screen readers, for the `'text'` and
|
|
66
|
+
* `'icon'` variants. Should be the entity the avatar stands for (e.g. the
|
|
67
|
+
* user's full name), not a description of the graphic.
|
|
68
|
+
*
|
|
69
|
+
* Always worth setting: neither variant carries a meaningful name on its own —
|
|
70
|
+
* `'text'` would otherwise announce bare initials and `'icon'` the raw icon
|
|
71
|
+
* name. The `'image'` variant ignores this input and uses `alt` instead,
|
|
72
|
+
* since its `<img>` already provides the accessible name.
|
|
73
|
+
*/
|
|
74
|
+
ariaLabel: _angular_core.InputSignal<string>;
|
|
75
|
+
/**
|
|
76
|
+
* The `value` truncated to {@link AVATAR_TEXT_MAX_LENGTH} characters. This is
|
|
77
|
+
* what actually gets rendered for the `'text'` variant.
|
|
78
|
+
*/
|
|
79
|
+
displayValue: _angular_core.Signal<string>;
|
|
80
|
+
/**
|
|
81
|
+
* Whether the avatar exposes itself as a labelled image to assistive tech.
|
|
82
|
+
* True for every variant except `'image'`, which is excluded because its
|
|
83
|
+
* `<img [alt]>` already carries the accessible name — adding `role="img"`
|
|
84
|
+
* plus a label on the wrapper too would announce the avatar twice.
|
|
85
|
+
*/
|
|
86
|
+
isLabelled: _angular_core.Signal<boolean>;
|
|
87
|
+
/**
|
|
88
|
+
* The accessible name actually rendered for the `'text'` and `'icon'`
|
|
89
|
+
* variants. Falls back to the displayed initials or the icon name when
|
|
90
|
+
* `ariaLabel` is not provided, so the avatar is never fully silent.
|
|
91
|
+
*/
|
|
92
|
+
accessibleLabel: _angular_core.Signal<string>;
|
|
93
|
+
/**
|
|
94
|
+
* Computed host class (BEM block + modifiers) combining `variant` and `size`
|
|
95
|
+
* always, plus `severity` unless `variant` is `'image'` (severity doesn't
|
|
96
|
+
* apply to images).
|
|
97
|
+
*/
|
|
98
|
+
hostClass: _angular_core.Signal<string>;
|
|
99
|
+
static ɵfac: _angular_core.ɵɵFactoryDeclaration<AvatarComponent, never>;
|
|
100
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<AvatarComponent, "tk-avatar", never, { "variant": { "alias": "variant"; "required": false; "isSignal": true; }; "severity": { "alias": "severity"; "required": false; "isSignal": true; }; "size": { "alias": "size"; "required": false; "isSignal": true; }; "value": { "alias": "value"; "required": false; "isSignal": true; }; "icon": { "alias": "icon"; "required": false; "isSignal": true; }; "image": { "alias": "image"; "required": false; "isSignal": true; }; "alt": { "alias": "alt"; "required": false; "isSignal": true; }; "ariaLabel": { "alias": "ariaLabel"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
export { AVATAR_TEXT_MAX_LENGTH, AvatarComponent };
|
|
104
|
+
export type { AvatarSeverity, AvatarSize, AvatarVariant };
|
|
@@ -58,6 +58,12 @@ declare class CheckboxComponent implements ControlValueAccessor, OnInit {
|
|
|
58
58
|
* Message to display when the control is invalid and touched.
|
|
59
59
|
*/
|
|
60
60
|
errorMessage: _angular_core.InputSignal<string>;
|
|
61
|
+
/**
|
|
62
|
+
* @property {InputSignal<string>} hint
|
|
63
|
+
* @description
|
|
64
|
+
* Hint text to display below the checkbox when there is no error.
|
|
65
|
+
*/
|
|
66
|
+
hint: _angular_core.InputSignal<string>;
|
|
61
67
|
/**
|
|
62
68
|
* @property {ModelSignal<boolean>} indeterminate
|
|
63
69
|
* @description
|
|
@@ -101,7 +107,7 @@ declare class CheckboxComponent implements ControlValueAccessor, OnInit {
|
|
|
101
107
|
*/
|
|
102
108
|
onBlur(): void;
|
|
103
109
|
static ɵfac: _angular_core.ɵɵFactoryDeclaration<CheckboxComponent, never>;
|
|
104
|
-
static ɵcmp: _angular_core.ɵɵComponentDeclaration<CheckboxComponent, "tk-checkbox", never, { "model": { "alias": "model"; "required": false; "isSignal": true; }; "value": { "alias": "value"; "required": false; "isSignal": true; }; "label": { "alias": "label"; "required": false; "isSignal": true; }; "name": { "alias": "name"; "required": false; "isSignal": true; }; "inputId": { "alias": "inputId"; "required": false; "isSignal": true; }; "binary": { "alias": "binary"; "required": false; "isSignal": true; }; "control": { "alias": "control"; "required": false; "isSignal": true; }; "errorMessage": { "alias": "errorMessage"; "required": false; "isSignal": true; }; "indeterminate": { "alias": "indeterminate"; "required": false; "isSignal": true; }; "disabled": { "alias": "disabled"; "required": false; "isSignal": true; }; }, { "model": "modelChange"; "indeterminate": "indeterminateChange"; "disabled": "disabledChange"; }, never, never, true, never>;
|
|
110
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<CheckboxComponent, "tk-checkbox", never, { "model": { "alias": "model"; "required": false; "isSignal": true; }; "value": { "alias": "value"; "required": false; "isSignal": true; }; "label": { "alias": "label"; "required": false; "isSignal": true; }; "name": { "alias": "name"; "required": false; "isSignal": true; }; "inputId": { "alias": "inputId"; "required": false; "isSignal": true; }; "binary": { "alias": "binary"; "required": false; "isSignal": true; }; "control": { "alias": "control"; "required": false; "isSignal": true; }; "errorMessage": { "alias": "errorMessage"; "required": false; "isSignal": true; }; "hint": { "alias": "hint"; "required": false; "isSignal": true; }; "indeterminate": { "alias": "indeterminate"; "required": false; "isSignal": true; }; "disabled": { "alias": "disabled"; "required": false; "isSignal": true; }; }, { "model": "modelChange"; "indeterminate": "indeterminateChange"; "disabled": "disabledChange"; }, never, never, true, never>;
|
|
105
111
|
}
|
|
106
112
|
|
|
107
113
|
export { CheckboxComponent };
|
|
@@ -11,9 +11,19 @@ import { ContrastResult } from '@tekus/design-system/utils/wcag-contrast';
|
|
|
11
11
|
type ColorPickerVariant = 'input' | 'swatch';
|
|
12
12
|
/**
|
|
13
13
|
* Reason the picker popover was closed.
|
|
14
|
-
* - `accept`: the selection was confirmed.
|
|
14
|
+
* - `accept`: the selection was confirmed (Enter, click-outside).
|
|
15
|
+
* - `cancel`: the selection was discarded and restored to its prior value
|
|
16
|
+
* (Escape, or another `tk-color-picker` instance opening in the same view).
|
|
15
17
|
*/
|
|
16
|
-
type ColorPickerCloseReason = 'accept';
|
|
18
|
+
type ColorPickerCloseReason = 'accept' | 'cancel';
|
|
19
|
+
/**
|
|
20
|
+
* Emission strategy for `colorChange` / `textColorChange` / `value`.
|
|
21
|
+
* - `live`: emit on every valid draft change (default, current behavior).
|
|
22
|
+
* - `onClose`: emit once, with the final value, only when the popover closes
|
|
23
|
+
* by confirmation (Enter / click-outside). Escape or being closed by
|
|
24
|
+
* another instance never emits.
|
|
25
|
+
*/
|
|
26
|
+
type ColorPickerEmitMode = 'live' | 'onClose';
|
|
17
27
|
/**
|
|
18
28
|
* Enables or disables each section of the picker popover.
|
|
19
29
|
* Every flag defaults to `true`; disabled sections are not rendered.
|
|
@@ -83,6 +93,7 @@ declare class ColorPickerComponent implements ControlValueAccessor {
|
|
|
83
93
|
readonly ngControl: NgControl | null;
|
|
84
94
|
private readonly destroyRef;
|
|
85
95
|
private readonly el;
|
|
96
|
+
private readonly registry;
|
|
86
97
|
private readonly init;
|
|
87
98
|
/**
|
|
88
99
|
* @property {ColorPickerVariant} variant
|
|
@@ -170,6 +181,25 @@ declare class ColorPickerComponent implements ControlValueAccessor {
|
|
|
170
181
|
* @default `''`
|
|
171
182
|
*/
|
|
172
183
|
errorMessage: _angular_core.InputSignal<string>;
|
|
184
|
+
/**
|
|
185
|
+
* @property {ColorPickerEmitMode} emitMode
|
|
186
|
+
* @description
|
|
187
|
+
* Emission strategy for `colorChange`/`textColorChange`/`value`:
|
|
188
|
+
* `'live'` emits on every valid draft change (default, unchanged behavior).
|
|
189
|
+
* `'onClose'` emits once, with the final value, only when the popover
|
|
190
|
+
* closes by confirmation (Enter / click-outside) — Escape, or being closed
|
|
191
|
+
* by another `tk-color-picker` instance opening in the same view, never
|
|
192
|
+
* emits.
|
|
193
|
+
*
|
|
194
|
+
* Exception: editing the trigger HEX field directly while the popover is
|
|
195
|
+
* closed (`variant="input"`) has no popover session to defer to, so under
|
|
196
|
+
* `'onClose'` it commits on its own equivalent of "close" — Enter, or
|
|
197
|
+
* losing focus (blur) — not on every debounce tick while still typing.
|
|
198
|
+
* This avoids firing on each momentarily-complete-looking HEX mid-edit,
|
|
199
|
+
* which matters when `colorChange` is wired straight to an API call.
|
|
200
|
+
* @default `'live'`
|
|
201
|
+
*/
|
|
202
|
+
emitMode: _angular_core.InputSignal<ColorPickerEmitMode>;
|
|
173
203
|
/**
|
|
174
204
|
* @property {ColorPickerTexts} texts
|
|
175
205
|
* @description
|
|
@@ -197,17 +227,22 @@ declare class ColorPickerComponent implements ControlValueAccessor {
|
|
|
197
227
|
/**
|
|
198
228
|
* @event colorChange
|
|
199
229
|
* @description
|
|
200
|
-
* Emits the confirmed background hex color
|
|
201
|
-
* on every valid change (
|
|
202
|
-
*
|
|
230
|
+
* Emits the confirmed background hex color. Timing depends on `emitMode()`:
|
|
231
|
+
* `'live'` emits on every valid change (drag, keystroke, swatch pick, or
|
|
232
|
+
* trigger HEX edit while closed); `'onClose'` emits once, with the final
|
|
233
|
+
* value, only when the popover closes by confirmation (Enter /
|
|
234
|
+
* click-outside). Never emits on Escape, when another instance forces this
|
|
235
|
+
* one to close, on invalid values, on hydration, or while disabled. Always
|
|
236
|
+
* emitted together with `textColorChange` in the same synchronous call, so
|
|
237
|
+
* both values belong to the same commit.
|
|
203
238
|
*/
|
|
204
239
|
colorChange: _angular_core.OutputEmitterRef<string>;
|
|
205
240
|
/**
|
|
206
241
|
* @event textColorChange
|
|
207
242
|
* @description
|
|
208
|
-
* Emits together with `colorChange
|
|
209
|
-
* confirmed background (`#000000` on light colors,
|
|
210
|
-
* or the `contrastColor` override when provided).
|
|
243
|
+
* Emits together with `colorChange`, same timing, same commit: the ideal
|
|
244
|
+
* text color over the confirmed background (`#000000` on light colors,
|
|
245
|
+
* `#ffffff` on dark ones, or the `contrastColor` override when provided).
|
|
211
246
|
*/
|
|
212
247
|
textColorChange: _angular_core.OutputEmitterRef<string>;
|
|
213
248
|
/**
|
|
@@ -228,7 +263,7 @@ declare class ColorPickerComponent implements ControlValueAccessor {
|
|
|
228
263
|
* Emits when the popover closes, with the close reason
|
|
229
264
|
* (`accept` confirmed, `cancel` discarded/restored).
|
|
230
265
|
*/
|
|
231
|
-
closed: _angular_core.OutputEmitterRef<
|
|
266
|
+
closed: _angular_core.OutputEmitterRef<ColorPickerCloseReason>;
|
|
232
267
|
popover: _angular_core.Signal<Popover | undefined>;
|
|
233
268
|
private swatchBtnRef;
|
|
234
269
|
private inputTriggerRef;
|
|
@@ -251,6 +286,14 @@ declare class ColorPickerComponent implements ControlValueAccessor {
|
|
|
251
286
|
protected readonly resolvedSections: _angular_core.Signal<Required<ColorPickerSections>>;
|
|
252
287
|
protected readonly t: _angular_core.Signal<Required<ColorPickerTexts>>;
|
|
253
288
|
/** Valid draft hex to paint swatches, or null → neutral fallback via CSS. */
|
|
289
|
+
/**
|
|
290
|
+
* Always reflects `draftHex()`, not `value()` — independent of `emitMode`
|
|
291
|
+
* and of whether the popover is open. `draftHex` tracks every keystroke
|
|
292
|
+
* (trigger or panel HEX field, spectrum/hue/swatch picks) in real time, so
|
|
293
|
+
* the swatch gives immediate visual feedback while the user is still
|
|
294
|
+
* typing, even under `emitMode="onClose"` where the actual commit/emit is
|
|
295
|
+
* deferred to Enter/blur/click-outside.
|
|
296
|
+
*/
|
|
254
297
|
protected readonly swatchColor: _angular_core.Signal<string | null>;
|
|
255
298
|
/**
|
|
256
299
|
* Text color of the contrast pair: the `contrastColor` override when valid,
|
|
@@ -268,6 +311,8 @@ declare class ColorPickerComponent implements ControlValueAccessor {
|
|
|
268
311
|
protected readonly errorId: string;
|
|
269
312
|
private static instanceCount;
|
|
270
313
|
private originalValue;
|
|
314
|
+
private closeReason;
|
|
315
|
+
private suppressNextHideCommit;
|
|
271
316
|
private readonly customColorWritePtr;
|
|
272
317
|
private readonly hexInput$;
|
|
273
318
|
onChange: (value: string) => void;
|
|
@@ -308,7 +353,17 @@ declare class ColorPickerComponent implements ControlValueAccessor {
|
|
|
308
353
|
private fixPanelPosition;
|
|
309
354
|
protected onPopoverHide(): void;
|
|
310
355
|
protected onPanelEnter(event: Event): void;
|
|
356
|
+
/** Bound to `(keydown.escape)` on the popover panel: intercepts Escape
|
|
357
|
+
* before it can bubble to PrimeNG's own document-level close handler, so
|
|
358
|
+
* the close reason is already recorded as `cancel` by the time `onHide`
|
|
359
|
+
* fires. */
|
|
360
|
+
protected onPanelEscape(event: Event): void;
|
|
311
361
|
private confirmAndClose;
|
|
362
|
+
/** Closes the popover as a cancellation: `onPopoverHide()` will restore
|
|
363
|
+
* `originalValue` and emit nothing. Shared by Escape and by the registry
|
|
364
|
+
* when another `tk-color-picker` instance opens in the same view. */
|
|
365
|
+
private cancelAndClose;
|
|
366
|
+
private restoreOriginalValue;
|
|
312
367
|
protected onSpectrumChange(change: {
|
|
313
368
|
saturation: number;
|
|
314
369
|
brightness: number;
|
|
@@ -340,7 +395,15 @@ declare class ColorPickerComponent implements ControlValueAccessor {
|
|
|
340
395
|
private setFromHex;
|
|
341
396
|
private applyHsv;
|
|
342
397
|
/**
|
|
343
|
-
* Commits the draft color immediately
|
|
398
|
+
* Commits the draft color immediately, but only in `'live'` emitMode.
|
|
399
|
+
* In `'onClose'` mode, mid-edit draft changes never commit here — not even
|
|
400
|
+
* for the trigger HEX field edited while the popover is closed. That path
|
|
401
|
+
* still needs an explicit "I'm done" signal, just like a popover session
|
|
402
|
+
* does: Enter (`onHexKeydown`) or losing focus (`onHexBlur`), both of which
|
|
403
|
+
* commit unconditionally regardless of `emitMode()`. Committing on every
|
|
404
|
+
* debounce tick while the field still has focus would fire on each
|
|
405
|
+
* completed-looking HEX mid-typing — exactly the noise `'onClose'` exists
|
|
406
|
+
* to avoid (e.g. a consumer wiring this straight to an API call).
|
|
344
407
|
*/
|
|
345
408
|
private maybeCommit;
|
|
346
409
|
private commitDraft;
|
|
@@ -349,8 +412,8 @@ declare class ColorPickerComponent implements ControlValueAccessor {
|
|
|
349
412
|
private hexToHsv;
|
|
350
413
|
private hsvToHex;
|
|
351
414
|
static ɵfac: _angular_core.ɵɵFactoryDeclaration<ColorPickerComponent, never>;
|
|
352
|
-
static ɵcmp: _angular_core.ɵɵComponentDeclaration<ColorPickerComponent, "tk-color-picker", never, { "variant": { "alias": "variant"; "required": false; "isSignal": true; }; "label": { "alias": "label"; "required": false; "isSignal": true; }; "hint": { "alias": "hint"; "required": false; "isSignal": true; }; "disabled": { "alias": "disabled"; "required": false; "isSignal": true; }; "required": { "alias": "required"; "required": false; "isSignal": true; }; "sections": { "alias": "sections"; "required": false; "isSignal": true; }; "presetColors": { "alias": "presetColors"; "required": false; "isSignal": true; }; "contrastColor": { "alias": "contrastColor"; "required": false; "isSignal": true; }; "maxCustomColors": { "alias": "maxCustomColors"; "required": false; "isSignal": true; }; "placement": { "alias": "placement"; "required": false; "isSignal": true; }; "errorMessage": { "alias": "errorMessage"; "required": false; "isSignal": true; }; "texts": { "alias": "texts"; "required": false; "isSignal": true; }; "value": { "alias": "value"; "required": false; "isSignal": true; }; "customColors": { "alias": "customColors"; "required": false; "isSignal": true; }; }, { "value": "valueChange"; "customColors": "customColorsChange"; "colorChange": "colorChange"; "textColorChange": "textColorChange"; "validChange": "validChange"; "opened": "opened"; "closed": "closed"; }, never, never, true, never>;
|
|
415
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<ColorPickerComponent, "tk-color-picker", never, { "variant": { "alias": "variant"; "required": false; "isSignal": true; }; "label": { "alias": "label"; "required": false; "isSignal": true; }; "hint": { "alias": "hint"; "required": false; "isSignal": true; }; "disabled": { "alias": "disabled"; "required": false; "isSignal": true; }; "required": { "alias": "required"; "required": false; "isSignal": true; }; "sections": { "alias": "sections"; "required": false; "isSignal": true; }; "presetColors": { "alias": "presetColors"; "required": false; "isSignal": true; }; "contrastColor": { "alias": "contrastColor"; "required": false; "isSignal": true; }; "maxCustomColors": { "alias": "maxCustomColors"; "required": false; "isSignal": true; }; "placement": { "alias": "placement"; "required": false; "isSignal": true; }; "errorMessage": { "alias": "errorMessage"; "required": false; "isSignal": true; }; "emitMode": { "alias": "emitMode"; "required": false; "isSignal": true; }; "texts": { "alias": "texts"; "required": false; "isSignal": true; }; "value": { "alias": "value"; "required": false; "isSignal": true; }; "customColors": { "alias": "customColors"; "required": false; "isSignal": true; }; }, { "value": "valueChange"; "customColors": "customColorsChange"; "colorChange": "colorChange"; "textColorChange": "textColorChange"; "validChange": "validChange"; "opened": "opened"; "closed": "closed"; }, never, never, true, never>;
|
|
353
416
|
}
|
|
354
417
|
|
|
355
418
|
export { ColorPickerComponent };
|
|
356
|
-
export type { ColorPickerCloseReason, ColorPickerSections, ColorPickerTexts, ColorPickerVariant };
|
|
419
|
+
export type { ColorPickerCloseReason, ColorPickerEmitMode, ColorPickerSections, ColorPickerTexts, ColorPickerVariant };
|
|
@@ -213,6 +213,16 @@ declare class DatePickerComponent implements OnInit, ControlValueAccessor, Valid
|
|
|
213
213
|
* <tk-date-picker [minDate]="minDate" errorMessage="Date is required" />
|
|
214
214
|
*/
|
|
215
215
|
errorMessage: _angular_core.InputSignal<string | null>;
|
|
216
|
+
/**
|
|
217
|
+
* @description
|
|
218
|
+
* Hint text rendered beneath the field when there is no error to show.
|
|
219
|
+
*
|
|
220
|
+
* @default null
|
|
221
|
+
*
|
|
222
|
+
* @example
|
|
223
|
+
* <tk-date-picker hint="Format: dd/mm/yyyy" />
|
|
224
|
+
*/
|
|
225
|
+
hint: _angular_core.InputSignal<string | null>;
|
|
216
226
|
/**
|
|
217
227
|
* @description
|
|
218
228
|
* Optional external `FormControl` to bind when not using the standard
|
|
@@ -312,7 +322,7 @@ declare class DatePickerComponent implements OnInit, ControlValueAccessor, Valid
|
|
|
312
322
|
*/
|
|
313
323
|
private applyTimeCascading;
|
|
314
324
|
static ɵfac: _angular_core.ɵɵFactoryDeclaration<DatePickerComponent, never>;
|
|
315
|
-
static ɵcmp: _angular_core.ɵɵComponentDeclaration<DatePickerComponent, "tk-date-picker", never, { "required": { "alias": "required"; "required": false; "isSignal": true; }; "selectionMode": { "alias": "selectionMode"; "required": false; "isSignal": true; }; "showClear": { "alias": "showClear"; "required": false; "isSignal": true; }; "showIcon": { "alias": "showIcon"; "required": false; "isSignal": true; }; "dateFormat": { "alias": "dateFormat"; "required": false; "isSignal": true; }; "stepHour": { "alias": "stepHour"; "required": false; "isSignal": true; }; "stepMinute": { "alias": "stepMinute"; "required": false; "isSignal": true; }; "stepSecond": { "alias": "stepSecond"; "required": false; "isSignal": true; }; "showSeconds": { "alias": "showSeconds"; "required": false; "isSignal": true; }; "disabled": { "alias": "disabled"; "required": false; "isSignal": true; }; "inline": { "alias": "inline"; "required": false; "isSignal": true; }; "showTime": { "alias": "showTime"; "required": false; "isSignal": true; }; "hourFormat": { "alias": "hourFormat"; "required": false; "isSignal": true; }; "appendTo": { "alias": "appendTo"; "required": false; "isSignal": true; }; "baseZIndex": { "alias": "baseZIndex"; "required": false; "isSignal": true; }; "maxDate": { "alias": "maxDate"; "required": false; "isSignal": true; }; "minDate": { "alias": "minDate"; "required": false; "isSignal": true; }; "labelText": { "alias": "labelText"; "required": false; "isSignal": true; }; "errorMessage": { "alias": "errorMessage"; "required": false; "isSignal": true; }; "control": { "alias": "control"; "required": false; "isSignal": true; }; "modelValue": { "alias": "modelValue"; "required": false; "isSignal": true; }; }, { "modelValue": "modelValueChange"; "handleSelect": "handleSelect"; "handleClear": "handleClear"; }, never, never, true, never>;
|
|
325
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<DatePickerComponent, "tk-date-picker", never, { "required": { "alias": "required"; "required": false; "isSignal": true; }; "selectionMode": { "alias": "selectionMode"; "required": false; "isSignal": true; }; "showClear": { "alias": "showClear"; "required": false; "isSignal": true; }; "showIcon": { "alias": "showIcon"; "required": false; "isSignal": true; }; "dateFormat": { "alias": "dateFormat"; "required": false; "isSignal": true; }; "stepHour": { "alias": "stepHour"; "required": false; "isSignal": true; }; "stepMinute": { "alias": "stepMinute"; "required": false; "isSignal": true; }; "stepSecond": { "alias": "stepSecond"; "required": false; "isSignal": true; }; "showSeconds": { "alias": "showSeconds"; "required": false; "isSignal": true; }; "disabled": { "alias": "disabled"; "required": false; "isSignal": true; }; "inline": { "alias": "inline"; "required": false; "isSignal": true; }; "showTime": { "alias": "showTime"; "required": false; "isSignal": true; }; "hourFormat": { "alias": "hourFormat"; "required": false; "isSignal": true; }; "appendTo": { "alias": "appendTo"; "required": false; "isSignal": true; }; "baseZIndex": { "alias": "baseZIndex"; "required": false; "isSignal": true; }; "maxDate": { "alias": "maxDate"; "required": false; "isSignal": true; }; "minDate": { "alias": "minDate"; "required": false; "isSignal": true; }; "labelText": { "alias": "labelText"; "required": false; "isSignal": true; }; "errorMessage": { "alias": "errorMessage"; "required": false; "isSignal": true; }; "hint": { "alias": "hint"; "required": false; "isSignal": true; }; "control": { "alias": "control"; "required": false; "isSignal": true; }; "modelValue": { "alias": "modelValue"; "required": false; "isSignal": true; }; }, { "modelValue": "modelValueChange"; "handleSelect": "handleSelect"; "handleClear": "handleClear"; }, never, never, true, never>;
|
|
316
326
|
}
|
|
317
327
|
|
|
318
328
|
export { DatePickerComponent };
|
|
@@ -0,0 +1,123 @@
|
|
|
1
|
+
import * as _angular_cdk_layout from '@angular/cdk/layout';
|
|
2
|
+
import * as _angular_core from '@angular/core';
|
|
3
|
+
import { GridColumns, GutterType, ComposeSize, ContainerType, GapGutter, FixedGridProps, AutoFillGridProps } from '@tekus/design-system/core/types';
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* A responsive CSS Grid container that exposes typed, two-way models to control
|
|
7
|
+
* column count, track size, inter-item gutter, and container padding.
|
|
8
|
+
*
|
|
9
|
+
* Behavior:
|
|
10
|
+
* - columns: GridColumns (default 12). Numeric values are capped per Breakpoints
|
|
11
|
+
* (2/3/4/8 for mobileSmall/mobileLarge/tabletVertical/tabletHorizontal). No cap when size is minmax().
|
|
12
|
+
* - size: ComposeSize (default '1fr'). Required to be minmax() when columns is 'auto-fill', otherwise an error is thrown.
|
|
13
|
+
* - gutter: Gutter (default 'normal'), mapped to GapGutter for host gap.
|
|
14
|
+
* - containerType: ContainerType (default 'medium'), mapped to PaddingGridContainer for host padding.
|
|
15
|
+
*
|
|
16
|
+
* Host bindings:
|
|
17
|
+
* - style.grid-template-columns via repeat(...) from computed columns/size.
|
|
18
|
+
* - style.gap via GapGutter.
|
|
19
|
+
* - style.padding via PaddingGridContainer.
|
|
20
|
+
*
|
|
21
|
+
* Intended to wrap GridItemDirective children. Public type is compatible with FixedGridProps | AutoFillGridProps.
|
|
22
|
+
* @selector tk-grid-container
|
|
23
|
+
*/
|
|
24
|
+
declare class GridContainerComponent {
|
|
25
|
+
/**
|
|
26
|
+
* Two-way bound model defining the number of columns in the grid.
|
|
27
|
+
*
|
|
28
|
+
* The value is capped based on the current screen breakpoint. If the `size` model
|
|
29
|
+
* is a `minmax()` function, the column cap is disabled.
|
|
30
|
+
*
|
|
31
|
+
* @default 12
|
|
32
|
+
* @see GridColumns
|
|
33
|
+
*/
|
|
34
|
+
columns: _angular_core.ModelSignal<GridColumns>;
|
|
35
|
+
/**
|
|
36
|
+
* Two-way bound model defining the spacing between grid items.
|
|
37
|
+
*
|
|
38
|
+
* The value is mapped to a CSS `gap` property based on the `Gutter` type.
|
|
39
|
+
*
|
|
40
|
+
* @default Gutter.normal
|
|
41
|
+
* @see Gutter
|
|
42
|
+
* @see GutterType
|
|
43
|
+
*/
|
|
44
|
+
gutter: _angular_core.ModelSignal<GutterType>;
|
|
45
|
+
/**
|
|
46
|
+
* Two-way bound model defining the grid track size.
|
|
47
|
+
*
|
|
48
|
+
* Accepts any ComposeSize value (e.g., '1fr', fixed lengths, or minmax()) and
|
|
49
|
+
* drives the computed grid template for the container.
|
|
50
|
+
*
|
|
51
|
+
* @default '1fr'
|
|
52
|
+
* @see ComposeSize
|
|
53
|
+
*/
|
|
54
|
+
size: _angular_core.ModelSignal<ComposeSize>;
|
|
55
|
+
/**
|
|
56
|
+
* Two-way bound model defining the internal spacing of the grid container.
|
|
57
|
+
*
|
|
58
|
+
* The value is mapped to a CSS `padding` property based on the `PaddingGridContainer` type.
|
|
59
|
+
*
|
|
60
|
+
* @default 'medium'
|
|
61
|
+
* @see ContainerType
|
|
62
|
+
*/
|
|
63
|
+
containerType: _angular_core.ModelSignal<ContainerType>;
|
|
64
|
+
/**
|
|
65
|
+
* A private static RegExp to validate strings that match the `minmax()` function.
|
|
66
|
+
*/
|
|
67
|
+
readonly MINMAX_RE: RegExp;
|
|
68
|
+
/**
|
|
69
|
+
* A private service injection to observe screen breakpoint changes.
|
|
70
|
+
*/
|
|
71
|
+
private readonly breakpointObserver;
|
|
72
|
+
/**
|
|
73
|
+
* A signal derived from `breakpointObserver` to reactively track changes
|
|
74
|
+
* across all defined breakpoints.
|
|
75
|
+
*/
|
|
76
|
+
screenChanges: _angular_core.Signal<_angular_cdk_layout.BreakpointState | undefined>;
|
|
77
|
+
/**
|
|
78
|
+
* A computed signal that determines the final number of columns for the grid.
|
|
79
|
+
*
|
|
80
|
+
* It caps the `columns` model value based on the current screen breakpoint,
|
|
81
|
+
* unless the `size` model is a `minmax()` function.
|
|
82
|
+
*/
|
|
83
|
+
readonly finalColumns: _angular_core.Signal<GridColumns>;
|
|
84
|
+
/**
|
|
85
|
+
* Host binding that maps the `gutter` model to the host element's `style.gap` property.
|
|
86
|
+
*/
|
|
87
|
+
readonly hostGap: _angular_core.Signal<GapGutter>;
|
|
88
|
+
/**
|
|
89
|
+
* Host binding that sets the `style.grid-template-columns` property based on
|
|
90
|
+
* the computed column count and track size.
|
|
91
|
+
*/
|
|
92
|
+
readonly gridColumns: _angular_core.Signal<string>;
|
|
93
|
+
/**
|
|
94
|
+
* Host binding that sets the `style.padding` property based on the `containerType` model.
|
|
95
|
+
*/
|
|
96
|
+
readonly containerPadding: _angular_core.Signal<string>;
|
|
97
|
+
/**
|
|
98
|
+
* Computes the final `grid-template-columns` string for the host element.
|
|
99
|
+
*
|
|
100
|
+
* It handles both fixed and `auto-fill` column types and validates that the `size`
|
|
101
|
+
* model is a `minmax()` function when `columns` is set to `'auto-fill'`.
|
|
102
|
+
* @returns The CSS value for the `grid-template-columns` property.
|
|
103
|
+
*/
|
|
104
|
+
computeGridTemplateColumns(): string;
|
|
105
|
+
/**
|
|
106
|
+
* A private helper method to check if a given value is a valid `minmax()` function string.
|
|
107
|
+
* @param value The value to check.
|
|
108
|
+
* @returns `true` if the value is a valid `minmax()` string, `false` otherwise.
|
|
109
|
+
*/
|
|
110
|
+
private isMinMax;
|
|
111
|
+
static ɵfac: _angular_core.ɵɵFactoryDeclaration<GridContainerComponent, never>;
|
|
112
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<GridContainerComponent, "tk-grid-container", never, { "columns": { "alias": "columns"; "required": false; "isSignal": true; }; "gutter": { "alias": "gutter"; "required": false; "isSignal": true; }; "size": { "alias": "size"; "required": false; "isSignal": true; }; "containerType": { "alias": "containerType"; "required": false; "isSignal": true; }; }, { "columns": "columnsChange"; "gutter": "gutterChange"; "size": "sizeChange"; "containerType": "containerTypeChange"; }, never, ["*"], true, never>;
|
|
113
|
+
}
|
|
114
|
+
/**
|
|
115
|
+
* A public type to represent an instance of the `GridContainerComponent` class,
|
|
116
|
+
* combined with its public input properties.
|
|
117
|
+
*
|
|
118
|
+
* This allows for better type-checking when the component is used in a template.
|
|
119
|
+
*/
|
|
120
|
+
type GridComponent = new () => GridContainerComponent & (FixedGridProps | AutoFillGridProps);
|
|
121
|
+
|
|
122
|
+
export { GridContainerComponent };
|
|
123
|
+
export type { GridComponent };
|
|
@@ -38,6 +38,12 @@ declare class InputNumberComponent implements ControlValueAccessor, OnInit {
|
|
|
38
38
|
* Message to display when the control is invalid and touched.
|
|
39
39
|
*/
|
|
40
40
|
errorMessage: _angular_core.InputSignal<string>;
|
|
41
|
+
/**
|
|
42
|
+
* @property {InputSignal<string>} hint
|
|
43
|
+
* @description
|
|
44
|
+
* Hint text to display below the input.
|
|
45
|
+
*/
|
|
46
|
+
hint: _angular_core.InputSignal<string>;
|
|
41
47
|
/**
|
|
42
48
|
* @property {InputSignal<boolean>} showButtons
|
|
43
49
|
* @description
|
|
@@ -45,6 +51,34 @@ declare class InputNumberComponent implements ControlValueAccessor, OnInit {
|
|
|
45
51
|
* @default false
|
|
46
52
|
*/
|
|
47
53
|
showButtons: _angular_core.InputSignal<boolean>;
|
|
54
|
+
/**
|
|
55
|
+
* @property {InputSignal<boolean>} useGrouping
|
|
56
|
+
* @description
|
|
57
|
+
* Whether to display thousands separators.
|
|
58
|
+
* @default false
|
|
59
|
+
*/
|
|
60
|
+
useGrouping: _angular_core.InputSignal<boolean>;
|
|
61
|
+
/**
|
|
62
|
+
* @property {InputSignal<number | null>} minFractionDigits
|
|
63
|
+
* @description
|
|
64
|
+
* Minimum number of decimal digits allowed.
|
|
65
|
+
*/
|
|
66
|
+
minFractionDigits: _angular_core.InputSignal<number | null>;
|
|
67
|
+
/**
|
|
68
|
+
* @property {InputSignal<number | null>} maxFractionDigits
|
|
69
|
+
* @description
|
|
70
|
+
* Maximum number of decimal digits allowed. Left unset (`null`) by
|
|
71
|
+
* default — integer entry only, matching prior behavior — and safe for
|
|
72
|
+
* already-bound decimal values (Intl.NumberFormat applies its own default
|
|
73
|
+
* of up to 3 decimal places for display when this isn't set, so no
|
|
74
|
+
* rounding happens). PrimeNG's InputNumber only lets the user *type* a new
|
|
75
|
+
* decimal separator when this is explicitly set to a value greater than 0
|
|
76
|
+
* — set it (e.g. `[maxFractionDigits]="2"`) to accept typed decimal
|
|
77
|
+
* input. Set to 0 only if you deliberately want to force integer-only
|
|
78
|
+
* display too — it rounds any already-bound decimal value.
|
|
79
|
+
* @default null
|
|
80
|
+
*/
|
|
81
|
+
maxFractionDigits: _angular_core.InputSignal<number | null>;
|
|
48
82
|
/**
|
|
49
83
|
* @property {boolean} disabled
|
|
50
84
|
* @description
|
|
@@ -98,7 +132,7 @@ declare class InputNumberComponent implements ControlValueAccessor, OnInit {
|
|
|
98
132
|
*/
|
|
99
133
|
onBlur(): void;
|
|
100
134
|
static ɵfac: _angular_core.ɵɵFactoryDeclaration<InputNumberComponent, never>;
|
|
101
|
-
static ɵcmp: _angular_core.ɵɵComponentDeclaration<InputNumberComponent, "tk-input-number", never, { "value": { "alias": "value"; "required": false; "isSignal": true; }; "control": { "alias": "control"; "required": false; "isSignal": true; }; "label": { "alias": "label"; "required": false; "isSignal": true; }; "id": { "alias": "id"; "required": false; "isSignal": true; }; "errorMessage": { "alias": "errorMessage"; "required": false; "isSignal": true; }; "showButtons": { "alias": "showButtons"; "required": false; "isSignal": true; }; }, { "value": "valueChange"; }, never, never, true, never>;
|
|
135
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<InputNumberComponent, "tk-input-number", never, { "value": { "alias": "value"; "required": false; "isSignal": true; }; "control": { "alias": "control"; "required": false; "isSignal": true; }; "label": { "alias": "label"; "required": false; "isSignal": true; }; "id": { "alias": "id"; "required": false; "isSignal": true; }; "errorMessage": { "alias": "errorMessage"; "required": false; "isSignal": true; }; "hint": { "alias": "hint"; "required": false; "isSignal": true; }; "showButtons": { "alias": "showButtons"; "required": false; "isSignal": true; }; "useGrouping": { "alias": "useGrouping"; "required": false; "isSignal": true; }; "minFractionDigits": { "alias": "minFractionDigits"; "required": false; "isSignal": true; }; "maxFractionDigits": { "alias": "maxFractionDigits"; "required": false; "isSignal": true; }; }, { "value": "valueChange"; }, never, never, true, never>;
|
|
102
136
|
}
|
|
103
137
|
|
|
104
138
|
export { InputNumberComponent };
|
|
@@ -53,6 +53,12 @@ declare class RadioButtonComponent implements ControlValueAccessor, OnInit {
|
|
|
53
53
|
* Message to display when the control is invalid and touched.
|
|
54
54
|
*/
|
|
55
55
|
errorMessage: _angular_core.InputSignal<string>;
|
|
56
|
+
/**
|
|
57
|
+
* @property {InputSignal<string>} hint
|
|
58
|
+
* @description
|
|
59
|
+
* Hint text to display below the radio button when there is no error.
|
|
60
|
+
*/
|
|
61
|
+
hint: _angular_core.InputSignal<string>;
|
|
56
62
|
/**
|
|
57
63
|
* @property {ModelSignal<boolean>} disabled
|
|
58
64
|
* @description
|
|
@@ -94,7 +100,7 @@ declare class RadioButtonComponent implements ControlValueAccessor, OnInit {
|
|
|
94
100
|
*/
|
|
95
101
|
onBlur(): void;
|
|
96
102
|
static ɵfac: _angular_core.ɵɵFactoryDeclaration<RadioButtonComponent, never>;
|
|
97
|
-
static ɵcmp: _angular_core.ɵɵComponentDeclaration<RadioButtonComponent, "tk-radio-button", never, { "model": { "alias": "model"; "required": false; "isSignal": true; }; "value": { "alias": "value"; "required": false; "isSignal": true; }; "label": { "alias": "label"; "required": false; "isSignal": true; }; "name": { "alias": "name"; "required": false; "isSignal": true; }; "inputId": { "alias": "inputId"; "required": false; "isSignal": true; }; "control": { "alias": "control"; "required": false; "isSignal": true; }; "errorMessage": { "alias": "errorMessage"; "required": false; "isSignal": true; }; "disabled": { "alias": "disabled"; "required": false; "isSignal": true; }; }, { "model": "modelChange"; "disabled": "disabledChange"; }, never, never, true, never>;
|
|
103
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<RadioButtonComponent, "tk-radio-button", never, { "model": { "alias": "model"; "required": false; "isSignal": true; }; "value": { "alias": "value"; "required": false; "isSignal": true; }; "label": { "alias": "label"; "required": false; "isSignal": true; }; "name": { "alias": "name"; "required": false; "isSignal": true; }; "inputId": { "alias": "inputId"; "required": false; "isSignal": true; }; "control": { "alias": "control"; "required": false; "isSignal": true; }; "errorMessage": { "alias": "errorMessage"; "required": false; "isSignal": true; }; "hint": { "alias": "hint"; "required": false; "isSignal": true; }; "disabled": { "alias": "disabled"; "required": false; "isSignal": true; }; }, { "model": "modelChange"; "disabled": "disabledChange"; }, never, never, true, never>;
|
|
98
104
|
}
|
|
99
105
|
|
|
100
106
|
export { RadioButtonComponent };
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import * as _angular_core from '@angular/core';
|
|
2
|
+
import { TagSeverity } from '@tekus/design-system/components/tag';
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* @component SectionComponent
|
|
6
|
+
* @description
|
|
7
|
+
* The Section component provides a structured, responsive layout block with an optional header and content area.
|
|
8
|
+
* It supports standard layouts, split layouts (two columns or two rows) with independent scrollable areas,
|
|
9
|
+
* and custom transclusion slots for headers, tags, and actions.
|
|
10
|
+
*
|
|
11
|
+
* @usage
|
|
12
|
+
* ```html
|
|
13
|
+
* <tk-section title="Licensing" tagText="Active" tagSeverity="success" icon="pi-cog">
|
|
14
|
+
* <div>Standard content area</div>
|
|
15
|
+
* </tk-section>
|
|
16
|
+
* ```
|
|
17
|
+
*/
|
|
18
|
+
declare class SectionComponent {
|
|
19
|
+
/** The primary title of the section. Optional. If omitted, the header is not rendered. */
|
|
20
|
+
title: _angular_core.InputSignal<string | undefined>;
|
|
21
|
+
/** Optional fixed height for the section (e.g. '300px', '100%'). If content exceeds this height, it scrolls. */
|
|
22
|
+
height: _angular_core.InputSignal<string | undefined>;
|
|
23
|
+
/** Optional tag text displayed next to the title. */
|
|
24
|
+
tagText: _angular_core.InputSignal<string | undefined>;
|
|
25
|
+
/** Optional tag severity for color styling. Defaults to 'info'. */
|
|
26
|
+
tagSeverity: _angular_core.InputSignal<TagSeverity>;
|
|
27
|
+
/** Optional prefix icon class (e.g. 'pi-plus'). Shows a circular prefix icon in the header if set. */
|
|
28
|
+
icon: _angular_core.InputSignal<string | undefined>;
|
|
29
|
+
/** Additional info text for the right side of the main header */
|
|
30
|
+
infoText: _angular_core.InputSignal<string | undefined>;
|
|
31
|
+
/** Icon for the right side of the main header */
|
|
32
|
+
infoIcon: _angular_core.InputSignal<string | undefined>;
|
|
33
|
+
/** Severity color for the main header info text ('default', 'danger', etc.) */
|
|
34
|
+
infoSeverity: _angular_core.InputSignal<"success" | "info" | "danger" | "default" | "warning">;
|
|
35
|
+
/** If true, the section body is split into two panels (left/right or top/bottom). */
|
|
36
|
+
split: _angular_core.InputSignal<boolean>;
|
|
37
|
+
/** Layout direction for the split panels: 'row' (side-by-side) or 'column' (stacked). Defaults to 'row'. */
|
|
38
|
+
direction: _angular_core.InputSignal<"row" | "column">;
|
|
39
|
+
/** If true and split mode is enabled, each panel will scroll independently when content overflows. */
|
|
40
|
+
scrollable: _angular_core.InputSignal<boolean>;
|
|
41
|
+
static ɵfac: _angular_core.ɵɵFactoryDeclaration<SectionComponent, never>;
|
|
42
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<SectionComponent, "tk-section", never, { "title": { "alias": "title"; "required": false; "isSignal": true; }; "height": { "alias": "height"; "required": false; "isSignal": true; }; "tagText": { "alias": "tagText"; "required": false; "isSignal": true; }; "tagSeverity": { "alias": "tagSeverity"; "required": false; "isSignal": true; }; "icon": { "alias": "icon"; "required": false; "isSignal": true; }; "infoText": { "alias": "infoText"; "required": false; "isSignal": true; }; "infoIcon": { "alias": "infoIcon"; "required": false; "isSignal": true; }; "infoSeverity": { "alias": "infoSeverity"; "required": false; "isSignal": true; }; "split": { "alias": "split"; "required": false; "isSignal": true; }; "direction": { "alias": "direction"; "required": false; "isSignal": true; }; "scrollable": { "alias": "scrollable"; "required": false; "isSignal": true; }; }, {}, never, ["[headerIcon]", "[headerTag]", "[actions]", "*", "[left]", "[right]"], true, never>;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
export { SectionComponent };
|