angular-ui-controls 0.0.0-stage → 0.1.0-rc.4

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 (42) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +126 -2
  3. package/docs/api/README.md +29 -0
  4. package/docs/api/abbreviation-textarea.md +118 -0
  5. package/docs/api/action-menu.md +86 -0
  6. package/docs/api/advanced-select.md +214 -0
  7. package/docs/api/autocomplete.md +134 -0
  8. package/docs/api/checkbox.md +98 -0
  9. package/docs/api/date-picker.md +152 -0
  10. package/docs/api/date-range-picker.md +175 -0
  11. package/docs/api/date-time-picker.md +159 -0
  12. package/docs/api/file-upload.md +85 -0
  13. package/docs/api/number-input.md +162 -0
  14. package/docs/api/password-input.md +142 -0
  15. package/docs/api/pdf-viewer.md +50 -0
  16. package/docs/api/radio-group.md +126 -0
  17. package/docs/api/rich-text-editor.md +86 -0
  18. package/docs/api/search-filter.md +192 -0
  19. package/docs/api/search-input.md +160 -0
  20. package/docs/api/searchable-select.md +195 -0
  21. package/docs/api/segmented-control.md +93 -0
  22. package/docs/api/selection-list.md +120 -0
  23. package/docs/api/slide-toggle.md +105 -0
  24. package/docs/api/text-area.md +148 -0
  25. package/docs/api/text-input.md +159 -0
  26. package/docs/api/time-input.md +99 -0
  27. package/docs/api/time-picker.md +130 -0
  28. package/fesm2022/angular-ui-controls-editor-build-Cm2HSXEy.mjs +2 -0
  29. package/fesm2022/angular-ui-controls-editor-build-Cm2HSXEy.mjs.map +1 -0
  30. package/fesm2022/angular-ui-controls-forms.mjs +865 -0
  31. package/fesm2022/angular-ui-controls-forms.mjs.map +1 -0
  32. package/fesm2022/angular-ui-controls-text-input.mjs +1210 -0
  33. package/fesm2022/angular-ui-controls-text-input.mjs.map +1 -0
  34. package/fesm2022/angular-ui-controls.mjs +7181 -0
  35. package/fesm2022/angular-ui-controls.mjs.map +1 -0
  36. package/forms/index.d.ts +425 -0
  37. package/forms/index.d.ts.map +1 -0
  38. package/index.d.ts +4345 -0
  39. package/index.d.ts.map +1 -0
  40. package/package.json +82 -3
  41. package/text-input/index.d.ts +609 -0
  42. package/text-input/index.d.ts.map +1 -0
@@ -0,0 +1,148 @@
1
+ # TextAreaComponent
2
+
3
+ Multiline text with optional highlighting.
4
+
5
+ Selector `ui-text-area`.
6
+
7
+ ## Usage
8
+
9
+ ```ts
10
+ import { TextAreaComponent } from 'angular-ui-controls';
11
+ ```
12
+
13
+ Add `TextAreaComponent` to the host component's imports. Add `FormsModule` for this example.
14
+
15
+ ```html
16
+ <ui-text-area
17
+ inputId="notes"
18
+ label="Notes"
19
+ [(ngModel)]="notes"
20
+ [useAbbreviationHighlight]="true"
21
+ [abbreviationList]="abbreviations"
22
+ [restrictedWords]="restricted"
23
+ [maxLength]="300"
24
+ />
25
+ ```
26
+
27
+ Example fields in the host component.
28
+
29
+ ```ts
30
+ notes = 'API integration';
31
+ abbreviations = [{ abbreviation: 'API', remarks: 'Application Programming Interface' }];
32
+ restricted = [{ word: 'restricted' }];
33
+ ```
34
+
35
+ Use Angular Forms or `[(value)]` for binding. The tables include inherited bindings. The Required column refers to whether the template must supply the input.
36
+
37
+ ## Inputs
38
+
39
+ | Input | Type | Required | Default | Description |
40
+ | --------------------------- | ------------------------------------- | -------- | ------------------------------------------------------------------------------ | --------------------------------------------------------------------------------------------------------------------------------- |
41
+ | `inputId` | `string` | Yes | — | Identifier assigned to the inner control. Set `idPrefix` to add a prefix. |
42
+ | `showExpandButton` | `boolean` | No | `false` | Show the optional inline editor expansion action. |
43
+ | `resize` | `boolean` | No | `false` | Enables or disables textarea resize. |
44
+ | `preventCopyPasteCut` | `boolean` | No | `false` | Blocks copy, cut, and paste on the field when enabled. |
45
+ | `minRows` | `number` | No | `3` | Minimum visible textarea rows passed to the existing textarea configuration. |
46
+ | `maxRows` | `number` | No | `6` | Maximum textarea rows passed to the existing textarea configuration. |
47
+ | `columns` | `number` | No | `0` | Textarea column count passed to the native cols attribute. |
48
+ | `label` | `string` | No | `''` | Label text or translation key displayed for this control. |
49
+ | `maxLength` | `number` | No | `0` | Maximum allowed characters. |
50
+ | `showCharacterCount` | `boolean` | No | `true` | Controls display of the existing character-count indicator. |
51
+ | `errorMessage` | `string` | No | `''` | Error message or translation key displayed when validation fails. |
52
+ | `required` | `boolean` | No | `false` | Marks the control as required. Configure any parent-form validators separately. |
53
+ | `showRemainingCharacters` | `boolean` | No | `false` | Shows the remaining-character indicator when the existing focus/maxLength conditions allow it. |
54
+ | `fieldName` | `string \| number \| undefined` | No | `undefined` | Consumer-defined field identifier included in event metadata. |
55
+ | `placeholder` | `string` | No | `''` | Hint text or translation key displayed while the control is empty. |
56
+ | `readonly` | `boolean` | No | `false` | Requests the existing read-only behavior without disabling the parent form control. |
57
+ | `mentionsList` | `any` | No | `[]` | Mention list for @ mentions. |
58
+ | `mentionConfig` | `MentionConfig` | No | `{ labelKey: 'abbreviation', mentionSelect: this.onMentionSelect, }` | Mention configuration. |
59
+ | `useAbbreviationHighlight` | `boolean` | No | `false` | Enables abbreviation highlight textarea. |
60
+ | `abbreviationList` | `AbbreviationEntry[]` | No | `[]` | Allowed abbreviations. |
61
+ | `enableArabicInput` | `boolean` | No | `false` | Passes the Arabic typing flag to the existing utility directive. |
62
+ | `restrictedWords` | `AbbreviationEntry[]` | No | `[]` | Restricted words list. |
63
+ | `abbreviationMentionConfig` | `AbbreviationMentionConfig[] \| null` | No | `null` | Optional replacement configuration for abbreviation mentions; null uses the component-built configuration. |
64
+ | `trimOnBlur` | `boolean` | No | `false` | Trims leading and trailing whitespace when the textarea loses focus. |
65
+ | `assistantFieldId` | `string` | No | `''` | Value written to the existing ChatGptAttr DOM attribute for field discovery. |
66
+ | `disabled` | `boolean` | No | `false` | Disables the control. Angular Forms can also update this state through setDisabledState. Uses Angular boolean attribute coercion. |
67
+ | `idPrefix` | `string` | No | `''` | Optional namespace prepended to inner control IDs to distinguish repeated instances. |
68
+ | `value` | `any` | No | `null` | Canonical value binding. Programmatic writes never emit user change events. |
69
+
70
+ ## Outputs
71
+
72
+ | Output | Payload | When it fires |
73
+ | ----------------- | ------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
74
+ | `valueChanged` | `any` | Emits the existing value-change payload; remains separate from modelChange. Emits `{ value: any; textFieldName: string \| number \| undefined; labelField: string; }`. |
75
+ | `expandRequested` | `any` | Emits when the expand or collapse action changes the textarea size. Payload `{ expanded: boolean; value: any; }`. |
76
+ | `inputChanged` | `any` | Emits when the user edits the field. Emits `{ changeEvent: Event; modelValue: any; fieldName: string \| number \| undefined; }`. |
77
+ | `itemSelected` | `any` | Emits when an abbreviation is picked from the mention list. |
78
+ | `valueChange` | `any` | Emits the raw value once per committed user edit. Supports `[(value)]`. |
79
+
80
+ ## Local option and event types
81
+
82
+ These declarations describe the payload and option shapes. Import availability depends on the package entry point.
83
+
84
+ ```ts
85
+ export interface AbbreviationEntry extends HighlightEntry {}
86
+
87
+ export interface HighlightEntry {
88
+ abbreviation?: string;
89
+ word?: string;
90
+ text?: string;
91
+ remarks?: string;
92
+ [key: string]: unknown;
93
+ }
94
+
95
+ export interface AbbreviationMentionConfig {
96
+ items: any[];
97
+ triggerChar?: string;
98
+ labelKey?: string;
99
+ isShortCut?: boolean;
100
+ mentionSelect?: (item: any) => string;
101
+ }
102
+ ```
103
+
104
+ ## Public instance properties
105
+
106
+ These TypeScript properties include state exposed by the class. Use the Inputs and Outputs tables for Angular template bindings.
107
+
108
+ | Property | Type | Description |
109
+ | ---------------------------------- | ----------------------------- | ------------------------------------------------------------------------------------------ |
110
+ | `container` | `ViewContainerRef` | — |
111
+ | `expandInput` | `boolean` | Indicates whether expandable view is active. |
112
+ | `modelValue` | `any` | Internal model getter/setter backed by the shared control value. |
113
+ | `selectedLanguage` | `Language` | — |
114
+ | `arabicLanguage` | `string` | — |
115
+ | `isFocused` | `boolean` | — |
116
+ | `showWordsLimitLabel` | `boolean` | **Deprecated.** Use isFocused when inspecting focus state. |
117
+ | `shouldShowRemainingCharacters` | `boolean` | — |
118
+ | `characterCount` | `number` | — |
119
+ | `remainingCharacters` | `number` | — |
120
+ | `abbreviationHighlightMentionList` | `AbbreviationMentionConfig[]` | — |
121
+ | `onChange` | `(value: any) => void` | — |
122
+ | `onTouched` | `() => void` | — |
123
+ | `onChangeCallback` | `(value: T \| null) => void` | Standard change and touch callbacks. |
124
+ | `onTouchedCallback` | `() => void` | — |
125
+ | `effectiveId` | `string` | Plain string property bound in template [id]="effectiveId" (zero function or CD overhead). |
126
+
127
+ ## Public instance methods
128
+
129
+ The list includes Angular Forms plumbing and component event handlers as well as methods called directly by consumers.
130
+
131
+ | Method | Signature | Description |
132
+ | ------------------------ | ------------------------------------------- | ---------------------------------------------------------------------------------------- |
133
+ | `updateChanges` | `(): void` | Emits value changes and updates form control. |
134
+ | `changeTextareaValue` | `(e: Event): void` | Handles native textarea input change. |
135
+ | `writeValue` | `(value: any): void` | Writes value from form control. |
136
+ | `onTextAreaFocus` | `(): void` | Shows remaining characters on focus. |
137
+ | `onTextAreaBlur` | `(): void` | Hides remaining characters on blur. |
138
+ | `openExpandableTextArea` | `(): void` | Toggle the inline expanded editor and notify consumers. |
139
+ | `expandButton` | `(): void` | — |
140
+ | `onMentionSelect` | `(selection: { remarks: string; }): string` | Handles mention selection. |
141
+ | `configureId` | `(): void` | — |
142
+ | `commitValue` | `(value?: any \| null): void` | Commit a view edit after the inner control has updated its local model. |
143
+ | `handleFocusOut` | `(event: FocusEvent): void` | Touch the outer control only when focus leaves the whole composite control. |
144
+ | `registerOnChange` | `(fn: (value: any \| null) => void): void` | Registers a callback function that is called when the control's value changes in the UI. |
145
+ | `registerOnTouched` | `(fn: () => void): void` | Registers a callback function that is called when the control is touched. |
146
+ | `setDisabledState` | `(isDisabled: boolean): void` | Updates the disabled state from the form model. |
147
+
148
+ [Component source](https://github.com/Abhilash-A-S/angular-ui-controls/blob/develop/projects/ui-controls/src/lib/component/text-area/text-area.component.ts) · [Playground example](https://github.com/Abhilash-A-S/angular-ui-controls/blob/develop/projects/demo/src/app.component.html)
@@ -0,0 +1,159 @@
1
+ # TextInputComponent
2
+
3
+ Single-line text.
4
+
5
+ Selector `ui-text-input`.
6
+
7
+ ## Usage
8
+
9
+ ```ts
10
+ import { TextInputComponent } from 'angular-ui-controls/text-input';
11
+ ```
12
+
13
+ Add `TextInputComponent` to the host component's imports. Add `FormsModule` for this example.
14
+
15
+ ```html
16
+ <ui-text-input inputId="name" label="Your name" [(ngModel)]="name" />
17
+ ```
18
+
19
+ Example fields in the host component.
20
+
21
+ ```ts
22
+ name = '';
23
+ ```
24
+
25
+ Use Angular Forms or `[(value)]` for binding. The tables include inherited bindings. The Required column refers to whether the template must supply the input.
26
+
27
+ ## Inputs
28
+
29
+ | Input | Type | Required | Default | Description |
30
+ | --------------------- | ------------------ | -------- | ----------- | --------------------------------------------------------------------------------------------------------------------------------- |
31
+ | `preventCopyPasteCut` | `boolean` | No | `false` | Blocks copy, cut, and paste on the field when enabled. |
32
+ | `inputId` | `string` | Yes | — | Identifier assigned to the inner control. Set `idPrefix` to add a prefix. |
33
+ | `tooltip` | `string` | No | `''` | Legacy tooltip-text input. Use `showTooltip` to display the current value. |
34
+ | `label` | `string` | No | `''` | Label text or translation key displayed for this control. |
35
+ | `errorMessage` | `string` | No | `''` | Validation error message. |
36
+ | `required` | `boolean` | No | `false` | Marks the control as required. Configure any parent-form validators separately. |
37
+ | `fieldName` | `string \| number` | No | `undefined` | Consumer-defined field identifier included in event metadata. |
38
+ | `placeholder` | `string` | No | `''` | Hint text or translation key displayed while the control is empty. |
39
+ | `readonly` | `boolean` | No | `false` | Requests the existing read-only behavior without disabling the parent form control. |
40
+ | `maxLength` | `number` | No | `undefined` | Maximum number of characters allowed. |
41
+ | `showTooltip` | `boolean` | No | `false` | Shows the current input value in the tooltip when enabled. |
42
+ | `assistantFieldId` | `string` | No | `''` | Value written to the existing ChatGptAttr DOM attribute for field discovery. |
43
+ | `onlyAlphabets` | `boolean` | No | `false` | Restricts typing to letters using the input rules directive. |
44
+ | `enableArabicInput` | `boolean` | No | `false` | Passes the Arabic typing flag to the existing utility directive. |
45
+ | `prefix` | `string` | No | `''` | Text displayed before the input value (e.g. '$', '+91', 'kg'). |
46
+ | `showPrefix` | `boolean` | No | `false` | Controls whether the prefix is rendered. Set to `true` only when the prefix should be visible. |
47
+ | `suffix` | `string` | No | `''` | Text displayed after the input, such as a unit or percentage sign. |
48
+ | `showSuffix` | `boolean` | No | `false` | Controls whether the suffix is rendered. |
49
+ | `disabled` | `boolean` | No | `false` | Disables the control. Angular Forms can also update this state through setDisabledState. Uses Angular boolean attribute coercion. |
50
+ | `idPrefix` | `string` | No | `''` | Optional namespace prepended to inner control IDs to distinguish repeated instances. |
51
+ | `value` | `string \| null` | No | `null` | Canonical value binding. Programmatic writes never emit user change events. |
52
+
53
+ ## Outputs
54
+
55
+ | Output | Payload | When it fires |
56
+ | -------------- | --------------------------- | ----------------------------------------------------------------------- |
57
+ | `modelChange` | `TextInputModelChangeEvent` | Emits a model-change event with field metadata. |
58
+ | `inputChanged` | `TextInputInputEvent` | Emits when the user edits the field. |
59
+ | `focusGained` | `TextInputFocusEvent` | Emits when the inner field gains focus. |
60
+ | `focusLost` | `TextInputBlurEvent` | Emits when the inner field loses focus. |
61
+ | `keyPressed` | `TextInputKeydownEvent` | Emits on the inner field keydown event. |
62
+ | `keyReleased` | `TextInputKeyupEvent` | Emits on the inner field keyup event. |
63
+ | `enterPressed` | `TextInputKeyEnterEvent` | Emits when Enter is released in the inner field. |
64
+ | `inputClicked` | `TextInputClickEvent` | Emits when the inner input is clicked. |
65
+ | `valueChange` | `string \| null` | Emits the raw value once per committed user edit. Supports `[(value)]`. |
66
+
67
+ ## Local option and event types
68
+
69
+ These declarations describe the payload and option shapes. Import availability depends on the package entry point.
70
+
71
+ ```ts
72
+ export interface TextInputModelChangeEvent extends TextInputFieldInfo {
73
+ /** Updated input value */
74
+ modelChangeEvent: any;
75
+ }
76
+
77
+ export interface TextInputFieldInfo {
78
+ /** Current input value */
79
+ modelValue: any;
80
+
81
+ /** Field identifier used by parent component */
82
+ fieldName: string | number;
83
+
84
+ /** Native input element reference (if inputId is provided) */
85
+ inputRef?: Element | null;
86
+ }
87
+
88
+ export interface TextInputInputEvent extends TextInputFieldInfo {
89
+ /** Native input/change event */
90
+ changeEvent: Event;
91
+ }
92
+
93
+ export interface TextInputFocusEvent extends TextInputFieldInfo {
94
+ /** Native focus event */
95
+ focusEvent: FocusEvent;
96
+ }
97
+
98
+ export interface TextInputBlurEvent extends TextInputFieldInfo {
99
+ /** Native blur event */
100
+ blurEvent: FocusEvent;
101
+ }
102
+
103
+ export interface TextInputKeydownEvent extends TextInputFieldInfo {
104
+ /** Native keyboard event */
105
+ keyDownEvent: KeyboardEvent;
106
+ }
107
+
108
+ export interface TextInputKeyupEvent extends TextInputFieldInfo {
109
+ /** Native keyboard event */
110
+ keyUpEvent: KeyboardEvent;
111
+ }
112
+
113
+ export interface TextInputKeyEnterEvent extends TextInputFieldInfo {
114
+ /** Enter key or input-related event */
115
+ keyEnterEvent: Event;
116
+ }
117
+
118
+ export interface TextInputClickEvent extends TextInputFieldInfo {
119
+ /** Mouse click event */
120
+ clickEvent: MouseEvent;
121
+ }
122
+ ```
123
+
124
+ ## Public instance properties
125
+
126
+ These TypeScript properties include state exposed by the class. Use the Inputs and Outputs tables for Angular template bindings.
127
+
128
+ | Property | Type | Description |
129
+ | ------------------- | ---------------------------- | ------------------------------------------------------------------------------------------ |
130
+ | `modelValue` | `any` | Internal model getter/setter backed by the shared control value. |
131
+ | `enablePrefix` | `boolean` | — |
132
+ | `enablePostfix` | `boolean` | — |
133
+ | `onChangeCallback` | `(value: T \| null) => void` | Standard change and touch callbacks. |
134
+ | `onTouchedCallback` | `() => void` | — |
135
+ | `effectiveId` | `string` | Plain string property bound in template [id]="effectiveId" (zero function or CD overhead). |
136
+
137
+ ## Public instance methods
138
+
139
+ The list includes Angular Forms plumbing and component event handlers as well as methods called directly by consumers.
140
+
141
+ | Method | Signature | Description |
142
+ | ------------------- | --------------------------------------------- | ---------------------------------------------------------------------------------------- |
143
+ | `modelValueChange` | `(modelChangeEvent: string): void` | Emits when the model value changes. |
144
+ | `inputChange` | `(changeValue: Event): void` | Emits on input value change. |
145
+ | `focusChange` | `(onFocusEvent: FocusEvent): void` | Emits when input gains focus. |
146
+ | `blurChange` | `(blurEvent: FocusEvent): void` | Emits when input loses focus. |
147
+ | `keydownHandle` | `(keyDownEvent: KeyboardEvent): void` | Emits on keydown action. |
148
+ | `keyupHandle` | `(keyUpEvent: KeyboardEvent): void` | Emits on keyup action. |
149
+ | `keyEnterHandle` | `(event: Event): void` | Emits when Enter key is pressed. |
150
+ | `inputClick` | `(clickEvent: MouseEvent): void` | Emits when input field is clicked. |
151
+ | `configureId` | `(): void` | — |
152
+ | `commitValue` | `(value?: string \| null): void` | Commit a view edit after the inner control has updated its local model. |
153
+ | `handleFocusOut` | `(event: FocusEvent): void` | Touch the outer control only when focus leaves the whole composite control. |
154
+ | `writeValue` | `(value: string \| null): void` | Writes a new value from the form model to the view. |
155
+ | `registerOnChange` | `(fn: (value: string \| null) => void): void` | Registers a callback function that is called when the control's value changes in the UI. |
156
+ | `registerOnTouched` | `(fn: () => void): void` | Registers a callback function that is called when the control is touched. |
157
+ | `setDisabledState` | `(isDisabled: boolean): void` | Updates the disabled state from the form model. |
158
+
159
+ [Component source](https://github.com/Abhilash-A-S/angular-ui-controls/blob/develop/projects/ui-controls/src/lib/component/text-input/text-input.component.ts) · [Playground example](https://github.com/Abhilash-A-S/angular-ui-controls/blob/develop/projects/demo/src/app.component.html)
@@ -0,0 +1,99 @@
1
+ # TimeInputComponent
2
+
3
+ Separate hour and minute inputs.
4
+
5
+ Selector `ui-time-input`.
6
+
7
+ ## Usage
8
+
9
+ ```ts
10
+ import { TimeInputComponent } from 'angular-ui-controls';
11
+ ```
12
+
13
+ Add `TimeInputComponent` to the host component's imports. Add `FormsModule` for this example.
14
+
15
+ ```html
16
+ <ui-time-input
17
+ hoursInputId="timeHr"
18
+ minutesInputId="timeMin"
19
+ label="Duration (HH:MM)"
20
+ [(ngModel)]="time"
21
+ />
22
+ ```
23
+
24
+ Example fields in the host component.
25
+
26
+ ```ts
27
+ time = '';
28
+ ```
29
+
30
+ Use Angular Forms or `[(value)]` for binding. The tables include inherited bindings. The Required column refers to whether the template must supply the input.
31
+
32
+ ## Inputs
33
+
34
+ | Input | Type | Required | Default | Description |
35
+ | --------------------- | ------------------ | -------- | ----------- | --------------------------------------------------------------------------------------------------------------------------------- |
36
+ | `preventCopyPasteCut` | `boolean` | No | `false` | Blocks copy, cut, and paste on the field when enabled. |
37
+ | `hoursInputId` | `string` | Yes | — | Identifier for the hours input, combined with idPrefix when supplied. |
38
+ | `minutesInputId` | `string` | Yes | — | Identifier for the minutes input, combined with idPrefix when supplied. |
39
+ | `errorMessage` | `string` | No | `''` | Validation error message. |
40
+ | `required` | `boolean` | No | `false` | Marks the control as required. Configure any parent-form validators separately. |
41
+ | `fieldName` | `string \| number` | No | `undefined` | Consumer-defined field identifier included in event metadata. |
42
+ | `readonly` | `boolean` | No | `false` | Requests the existing read-only behavior without disabling the parent form control. |
43
+ | `disabled` | `boolean` | No | `false` | Disables the control. Angular Forms can also update this state through setDisabledState. Uses Angular boolean attribute coercion. |
44
+ | `idPrefix` | `string` | No | `''` | Optional namespace prepended to inner control IDs to distinguish repeated instances. |
45
+ | `value` | `string \| null` | No | `null` | Canonical value binding. Programmatic writes never emit user change events. |
46
+
47
+ ## Outputs
48
+
49
+ | Output | Payload | When it fires |
50
+ | -------------- | ---------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------- |
51
+ | `modelChange` | `any` | Emits a model-change event with field metadata. Emits `{ modelChangeEvent: string \| null; modelValue: string \| null; textFieldName: string \| number; }`. |
52
+ | `inputChanged` | `any` | Emits when the user edits the field. Emits `{ changeEvent: Event; modelValue: string \| null; textFieldName: string \| number; }`. |
53
+ | `focusGained` | `any` | Emits when the inner field gains focus. Emits `{ focusEvent: FocusEvent; modelValue: string \| null; textFieldName: string \| number; }`. |
54
+ | `focusLost` | `any` | Emits when the inner field loses focus. Emits `{ blurEvent: FocusEvent; modelValue: string \| null; textFieldName: string \| number; }`. |
55
+ | `keyPressed` | `any` | Emits on the inner field keydown event. Emits `{ keyDownEvent: KeyboardEvent; modelValue: string \| null; textFieldName: string \| number; }`. |
56
+ | `keyReleased` | `any` | Emits on the inner field keyup event. Emits `{ keyUpEvent: KeyboardEvent; modelValue: string \| null; textFieldName: string \| number; }`. |
57
+ | `enterPressed` | `any` | Emits when Enter is released in the inner field. Emits `{ keyEnterEvent: Event; modelValue: string \| null; textFieldName: string \| number; }`. |
58
+ | `valueChange` | `string \| null` | Emits the raw value once per committed user edit. Supports `[(value)]`. |
59
+
60
+ ## Public instance properties
61
+
62
+ These TypeScript properties include state exposed by the class. Use the Inputs and Outputs tables for Angular template bindings.
63
+
64
+ | Property | Type | Description |
65
+ | ------------------- | ---------------------------- | ------------------------------------------------------------------------------------------ |
66
+ | `effectiveIdHr` | `string` | — |
67
+ | `effectiveIdMin` | `string` | — |
68
+ | `hours` | `string` | — |
69
+ | `minutes` | `string` | — |
70
+ | `modelValue` | `string` | Internal model getter/setter backed by the shared control value. |
71
+ | `onChangeCallback` | `(value: T \| null) => void` | Standard change and touch callbacks. |
72
+ | `onTouchedCallback` | `() => void` | — |
73
+ | `effectiveId` | `string` | Plain string property bound in template [id]="effectiveId" (zero function or CD overhead). |
74
+
75
+ ## Public instance methods
76
+
77
+ The list includes Angular Forms plumbing and component event handlers as well as methods called directly by consumers.
78
+
79
+ | Method | Signature | Description |
80
+ | ------------------- | ----------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------- |
81
+ | `configureId` | `(): void` | — |
82
+ | `writeValue` | `(savedTime: string \| null): void` | — |
83
+ | `modelValueChange` | `(_modelChange: unknown): void` | Emits when the model value changes. |
84
+ | `inputChange` | `(changeValue: Event): void` | Emits when the input value changes. |
85
+ | `focusChange` | `(onFocus: FocusEvent): void` | Emits when input gains focus. |
86
+ | `blurChange` | `(blurEvent: FocusEvent): void` | Emits when input loses focus. |
87
+ | `keydownHandle` | `(event: KeyboardEvent): void` | Emits on keydown action. |
88
+ | `keyupHandle` | `(event: KeyboardEvent): void` | Emits on keyup action. |
89
+ | `keyEnterHandle` | `(event: Event): void` | Emits when Enter key is pressed. |
90
+ | `onKeyUp` | `(event: KeyboardEvent, restrictNumber: number, field: "hours" \| "minutes"): void` | — |
91
+ | `setZeroBefore` | `(): void` | — |
92
+ | `acceptNumberOnly` | `(event: KeyboardEvent): boolean` | — |
93
+ | `commitValue` | `(value?: string \| null): void` | Commit a view edit after the inner control has updated its local model. |
94
+ | `handleFocusOut` | `(event: FocusEvent): void` | Touch the outer control only when focus leaves the whole composite control. |
95
+ | `registerOnChange` | `(fn: (value: string \| null) => void): void` | Registers a callback function that is called when the control's value changes in the UI. |
96
+ | `registerOnTouched` | `(fn: () => void): void` | Registers a callback function that is called when the control is touched. |
97
+ | `setDisabledState` | `(isDisabled: boolean): void` | Updates the disabled state from the form model. |
98
+
99
+ [Component source](https://github.com/Abhilash-A-S/angular-ui-controls/blob/develop/projects/ui-controls/src/lib/component/time-input/time-input.component.ts) · [Playground example](https://github.com/Abhilash-A-S/angular-ui-controls/blob/develop/projects/demo/src/app.component.html)
@@ -0,0 +1,130 @@
1
+ # TimePickerComponent
2
+
3
+ Time of day.
4
+
5
+ Selector `ui-time-picker`.
6
+
7
+ ## Usage
8
+
9
+ ```ts
10
+ import { TimePickerComponent } from 'angular-ui-controls';
11
+ ```
12
+
13
+ Add `TimePickerComponent` to the host component's imports. Add `FormsModule` for this example.
14
+
15
+ ```html
16
+ <ui-time-picker inputId="timePicker" label="Time picker (native 24h)" [(ngModel)]="timePicker" />
17
+ ```
18
+
19
+ Example fields in the host component.
20
+
21
+ ```ts
22
+ timePicker = '';
23
+ ```
24
+
25
+ Use Angular Forms or `[(value)]` for binding. The tables include inherited bindings. The Required column refers to whether the template must supply the input.
26
+
27
+ ## Inputs
28
+
29
+ | Input | Type | Required | Default | Description |
30
+ | -------------- | ------------------ | -------- | ----------- | --------------------------------------------------------------------------------------------------------------------------------- |
31
+ | `inputId` | `string` | Yes | — | Identifier assigned to the inner control. Set `idPrefix` to add a prefix. |
32
+ | `label` | `string` | No | `''` | Label text or translation key displayed for this control. |
33
+ | `errorMessage` | `string` | No | `''` | Validation error message. |
34
+ | `required` | `boolean` | No | `false` | Marks the control as required. Configure any parent-form validators separately. |
35
+ | `fieldName` | `string \| number` | No | `undefined` | Consumer-defined field identifier included in event metadata. |
36
+ | `placeholder` | `string` | No | `''` | Hint text or translation key displayed while the control is empty. |
37
+ | `readonly` | `boolean` | No | `false` | Requests the existing read-only behavior without disabling the parent form control. |
38
+ | `minTime` | `string` | No | `undefined` | Minimum selectable time. |
39
+ | `maxTime` | `string` | No | `undefined` | Maximum selectable time. |
40
+ | `disabled` | `boolean` | No | `false` | Disables the control. Angular Forms can also update this state through setDisabledState. Uses Angular boolean attribute coercion. |
41
+ | `idPrefix` | `string` | No | `''` | Optional namespace prepended to inner control IDs to distinguish repeated instances. |
42
+ | `value` | `string \| null` | No | `null` | Canonical value binding. Programmatic writes never emit user change events. |
43
+
44
+ ## Outputs
45
+
46
+ | Output | Payload | When it fires |
47
+ | ----------------- | ------------------------- | ----------------------------------------------------------------------- |
48
+ | `modelChange` | `TimePickerFieldInfo` | Emits a model-change event with field metadata. |
49
+ | `changeCommitted` | `TimePickerChange` | Emits from the existing change handler. |
50
+ | `inputChanged` | `TimePickerChangeEvent` | Emits when the user edits the field. |
51
+ | `focusGained` | `TimePickerFocusEvent` | Emits when the inner field gains focus. |
52
+ | `focusLost` | `TimePickerFocusEvent` | Emits when the inner field loses focus. |
53
+ | `keyPressed` | `TimePickerKeyboardEvent` | Emits on the inner field keydown event. |
54
+ | `keyReleased` | `TimePickerKeyboardEvent` | Emits on the inner field keyup event. |
55
+ | `enterPressed` | `TimePickerKeyboardEvent` | Emits when Enter is released in the inner field. |
56
+ | `valueChange` | `string \| null` | Emits the raw value once per committed user edit. Supports `[(value)]`. |
57
+
58
+ ## Local option and event types
59
+
60
+ These declarations describe the payload and option shapes. Import availability depends on the package entry point.
61
+
62
+ ```ts
63
+ export interface TimePickerFieldInfo {
64
+ /** Selected time value (model value) */
65
+ modelValue: string;
66
+
67
+ /** Field identifier used by parent components */
68
+ textFieldName: string | number;
69
+
70
+ /** Optional reference to the input element */
71
+ inputRef?: HTMLElement | null;
72
+ }
73
+
74
+ export interface TimePickerChange extends TimePickerFieldInfo {
75
+ /** Native input or change event */
76
+ changeEvent?: Event;
77
+ }
78
+
79
+ export interface TimePickerChangeEvent extends TimePickerFieldInfo {
80
+ /** Native input or change event */
81
+ changeEvent?: Event;
82
+ }
83
+
84
+ export interface TimePickerFocusEvent extends TimePickerFieldInfo {
85
+ /** Native focus or blur event */
86
+ focusEvent?: FocusEvent;
87
+ }
88
+
89
+ export interface TimePickerKeyboardEvent extends TimePickerFieldInfo {
90
+ /** Keyboard event object */
91
+ keyboardEvent?: KeyboardEvent;
92
+ }
93
+ ```
94
+
95
+ ## Public instance properties
96
+
97
+ These TypeScript properties include state exposed by the class. Use the Inputs and Outputs tables for Angular template bindings.
98
+
99
+ | Property | Type | Description |
100
+ | ------------------- | ------------------------------ | ------------------------------------------------------------------------------------------ |
101
+ | `timeInput` | `ElementRef<HTMLInputElement>` | — |
102
+ | `modelValue` | `string` | Internal model getter/setter backed by the shared control value. |
103
+ | `onChangeCallback` | `(value: T \| null) => void` | Standard change and touch callbacks. |
104
+ | `onTouchedCallback` | `() => void` | — |
105
+ | `effectiveId` | `string` | Plain string property bound in template [id]="effectiveId" (zero function or CD overhead). |
106
+
107
+ ## Public instance methods
108
+
109
+ The list includes Angular Forms plumbing and component event handlers as well as methods called directly by consumers.
110
+
111
+ | Method | Signature | Description |
112
+ | ------------------- | --------------------------------------------- | ---------------------------------------------------------------------------------------- |
113
+ | `openTimePicker` | `(): void` | Opens the browser native time picker popup window. |
114
+ | `handleModelChange` | `(event: any): void` | Handles ngModel value change. |
115
+ | `onFocus` | `(): void` | Handles focus event. |
116
+ | `onBlur` | `(): void` | Handles blur event. |
117
+ | `onKeyUp` | `(event: KeyboardEvent): void` | Handles keyup event. |
118
+ | `onKeyDown` | `(event: KeyboardEvent): void` | Handles keydown event. |
119
+ | `onInput` | `(event: Event): void` | Handles input event. |
120
+ | `onChangeHandler` | `(event: any): void` | Handles change event. |
121
+ | `onEnter` | `(event: Event): void` | — |
122
+ | `configureId` | `(): void` | — |
123
+ | `commitValue` | `(value?: string \| null): void` | Commit a view edit after the inner control has updated its local model. |
124
+ | `handleFocusOut` | `(event: FocusEvent): void` | Touch the outer control only when focus leaves the whole composite control. |
125
+ | `writeValue` | `(value: string \| null): void` | Writes a new value from the form model to the view. |
126
+ | `registerOnChange` | `(fn: (value: string \| null) => void): void` | Registers a callback function that is called when the control's value changes in the UI. |
127
+ | `registerOnTouched` | `(fn: () => void): void` | Registers a callback function that is called when the control is touched. |
128
+ | `setDisabledState` | `(isDisabled: boolean): void` | Updates the disabled state from the form model. |
129
+
130
+ [Component source](https://github.com/Abhilash-A-S/angular-ui-controls/blob/develop/projects/ui-controls/src/lib/component/time-picker/time-picker.component.ts) · [Playground example](https://github.com/Abhilash-A-S/angular-ui-controls/blob/develop/projects/demo/src/app.component.html)
@@ -0,0 +1,2 @@
1
+ export { Alignment, BlockQuote, Bold, DecoupledEditor, Essentials, Font, Heading, Image, ImageCaption, ImageResize, ImageStyle, ImageToolbar, ImageUpload, Indent, IndentBlock, Italic, Link, List, ListProperties, Paragraph, Strikethrough, Table, TableToolbar, Underline } from 'ckeditor5';
2
+ //# sourceMappingURL=angular-ui-controls-editor-build-Cm2HSXEy.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"angular-ui-controls-editor-build-Cm2HSXEy.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":""}