@scania-nl/tegel-angular-extensions 0.0.7 → 0.0.9
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/README.md +508 -54
- package/esm2022/index.mjs +9 -1
- package/esm2022/lib/components/tae-date-time-picker/tae-date-time-picker.component.mjs +366 -0
- package/esm2022/lib/components/tae-date-time-picker/tae-date-time-picker.constants.mjs +24 -0
- package/esm2022/lib/components/tae-date-time-picker/tae-date-time-picker.utils.mjs +148 -0
- package/esm2022/lib/directives/typed-template.directive.mjs +38 -0
- package/esm2022/lib/env/angular/provide-runtime-config.mjs +7 -5
- package/esm2022/lib/modal/components/modal/modal.component.mjs +128 -0
- package/esm2022/lib/modal/components/modal-host/modal-host.component.mjs +32 -0
- package/esm2022/lib/modal/directives/dynamic-component.directive.mjs +135 -0
- package/esm2022/lib/modal/modal.service.mjs +156 -0
- package/esm2022/lib/modal/provide-modal.mjs +25 -0
- package/esm2022/lib/modal/schema/modal-ref.mjs +2 -0
- package/esm2022/lib/modal/schema/modal.config.mjs +15 -0
- package/esm2022/lib/modal/schema/modal.model.mjs +2 -0
- package/esm2022/lib/modal/schema/modal.types.mjs +3 -0
- package/esm2022/lib/toast/provide-toast.mjs +7 -1
- package/esm2022/lib/utils/angular-component-io.mjs +2 -0
- package/index.d.ts +415 -4
- package/package.json +1 -1
package/index.d.ts
CHANGED
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import * as _angular_core from '@angular/core';
|
|
2
|
-
import { InjectionToken, EnvironmentProviders } from '@angular/core';
|
|
2
|
+
import { InjectionToken, EnvironmentProviders, InputSignal, OutputEmitterRef, TemplateRef, Type, ElementRef } from '@angular/core';
|
|
3
3
|
import z$1, { z } from 'zod';
|
|
4
4
|
import { zx } from '@traversable/zod';
|
|
5
5
|
import { Subject } from 'rxjs';
|
|
6
|
+
import { ControlValueAccessor } from '@angular/forms';
|
|
6
7
|
|
|
7
8
|
/**
|
|
8
9
|
* List of available toast types (inherited from Tegel)
|
|
@@ -47,6 +48,12 @@ interface ToastConfig {
|
|
|
47
48
|
declare const TOAST_CONFIG: InjectionToken<ToastConfig>;
|
|
48
49
|
declare const DEFAULT_TOAST_CONFIG: Required<ToastConfig>;
|
|
49
50
|
|
|
51
|
+
/**
|
|
52
|
+
* Provides toast configuration defaults and bootstraps the global toast host.
|
|
53
|
+
*
|
|
54
|
+
* @param config Optional config overrides applied on top of defaults.
|
|
55
|
+
* @returns EnvironmentProviders to register in application providers.
|
|
56
|
+
*/
|
|
50
57
|
declare function provideToast(config?: Partial<ToastConfig>): EnvironmentProviders;
|
|
51
58
|
|
|
52
59
|
/**
|
|
@@ -236,6 +243,247 @@ declare class ToastService {
|
|
|
236
243
|
static ɵprov: _angular_core.ɵɵInjectableDeclaration<ToastService>;
|
|
237
244
|
}
|
|
238
245
|
|
|
246
|
+
interface ModalRef {
|
|
247
|
+
/** Unique id for the modal instance. */
|
|
248
|
+
id: string;
|
|
249
|
+
/** Opens the modal instance. */
|
|
250
|
+
open: () => void;
|
|
251
|
+
/** Closes the modal instance. */
|
|
252
|
+
close: () => void;
|
|
253
|
+
/** Removes the modal instance from the DOM. */
|
|
254
|
+
remove: () => void;
|
|
255
|
+
}
|
|
256
|
+
|
|
257
|
+
/**
|
|
258
|
+
* Extracts the inner value type from an InputSignal.
|
|
259
|
+
* Example: InputSignal<string> -> string
|
|
260
|
+
*/
|
|
261
|
+
type ExtractInputValue<T> = T extends InputSignal<infer V> ? V : never;
|
|
262
|
+
/**
|
|
263
|
+
* Gets all property keys that are required input signals (`input.required<T>()`).
|
|
264
|
+
* These are InputSignals where `undefined` is NOT part of the value type.
|
|
265
|
+
*/
|
|
266
|
+
type RequiredInputKeys<T> = {
|
|
267
|
+
[K in keyof T]: T[K] extends InputSignal<infer V> ? undefined extends V ? never : K : never;
|
|
268
|
+
}[keyof T];
|
|
269
|
+
/**
|
|
270
|
+
* Gets all property keys that are optional input signals (`input<T | undefined>()`).
|
|
271
|
+
* These are InputSignals where `undefined` IS part of the value type.
|
|
272
|
+
*/
|
|
273
|
+
type OptionalInputKeys<T> = {
|
|
274
|
+
[K in keyof T]: T[K] extends InputSignal<infer V> ? undefined extends V ? K : never : never;
|
|
275
|
+
}[keyof T];
|
|
276
|
+
/**
|
|
277
|
+
* Creates a type representing the input values for an Angular component.
|
|
278
|
+
* - Required inputs (`input.required<T>()`) become required properties
|
|
279
|
+
* - Optional inputs (`input<T | undefined>()`) become optional properties
|
|
280
|
+
* - Non-input properties are excluded
|
|
281
|
+
*
|
|
282
|
+
* @example
|
|
283
|
+
* class MyComponent {
|
|
284
|
+
* name = input.required<string>();
|
|
285
|
+
* age = input<number | undefined>();
|
|
286
|
+
* }
|
|
287
|
+
*
|
|
288
|
+
* type Inputs = ComponentInputs<MyComponent>;
|
|
289
|
+
* // { name: string; age?: number | undefined }
|
|
290
|
+
*/
|
|
291
|
+
type ComponentInputs<T> = {
|
|
292
|
+
[K in RequiredInputKeys<T>]: ExtractInputValue<T[K]>;
|
|
293
|
+
} & {
|
|
294
|
+
[K in OptionalInputKeys<T>]?: ExtractInputValue<T[K]>;
|
|
295
|
+
};
|
|
296
|
+
/**
|
|
297
|
+
* Extracts the inner value type from an OutputEmitterRef.
|
|
298
|
+
* Example: OutputEmitterRef<string> -> string
|
|
299
|
+
*/
|
|
300
|
+
type ExtractOutputValue<T> = T extends OutputEmitterRef<infer V> ? V : never;
|
|
301
|
+
/**
|
|
302
|
+
* Gets all property keys that are output signals (`output<T>()`).
|
|
303
|
+
*/
|
|
304
|
+
type OutputKeys<T> = {
|
|
305
|
+
[K in keyof T]: T[K] extends OutputEmitterRef<unknown> ? K : never;
|
|
306
|
+
}[keyof T];
|
|
307
|
+
/**
|
|
308
|
+
* Creates a type representing the output event handlers for an Angular component.
|
|
309
|
+
* Converts output signals into callback functions that receive the emitted value.
|
|
310
|
+
*
|
|
311
|
+
* @example
|
|
312
|
+
* class MyComponent {
|
|
313
|
+
* closed = output<void>();
|
|
314
|
+
* valueChanged = output<string>();
|
|
315
|
+
* notAnOutput = 'regular property';
|
|
316
|
+
* }
|
|
317
|
+
*
|
|
318
|
+
* type Outputs = ComponentOutputs<MyComponent>;
|
|
319
|
+
* // { closed?: () => void; valueChanged?: (value: string) => void }
|
|
320
|
+
*/
|
|
321
|
+
type ComponentOutputs<T> = {
|
|
322
|
+
[K in OutputKeys<T>]?: (value: ExtractOutputValue<T[K]>) => void;
|
|
323
|
+
};
|
|
324
|
+
|
|
325
|
+
/** Pure domain/UI types for modal components. */
|
|
326
|
+
/** Supported modal sizes. */
|
|
327
|
+
type ModalSize = 'lg' | 'md' | 'sm' | 'xs';
|
|
328
|
+
/** Positioning behavior for the actions slot. */
|
|
329
|
+
type ModalActionsPosition = 'sticky' | 'static';
|
|
330
|
+
/** ARIA role used by the modal for accessibility. */
|
|
331
|
+
type ModalAlertDialogRole = 'dialog' | 'alertdialog';
|
|
332
|
+
/** Descriptor for a button rendered in the modal actions area. */
|
|
333
|
+
interface ModalButton {
|
|
334
|
+
/** Button label text. */
|
|
335
|
+
text: string;
|
|
336
|
+
/** Visual variant for the button. */
|
|
337
|
+
variant?: 'primary' | 'secondary' | 'success' | 'danger';
|
|
338
|
+
/** Size of the button. */
|
|
339
|
+
size?: 'xs' | 'sm' | 'md' | 'lg';
|
|
340
|
+
/** Whether the button is disabled. */
|
|
341
|
+
disabled?: boolean;
|
|
342
|
+
/** If true, clicking triggers modal dismissal. */
|
|
343
|
+
dismiss?: boolean;
|
|
344
|
+
/** Optional click handler (sync or async). */
|
|
345
|
+
onClick?: () => void | Promise<void>;
|
|
346
|
+
}
|
|
347
|
+
|
|
348
|
+
/**
|
|
349
|
+
* Configuration used by the modal service when creating modals.
|
|
350
|
+
* Individual modal options can override any of these values.
|
|
351
|
+
*/
|
|
352
|
+
interface ModalConfig {
|
|
353
|
+
/** Size of the modal dialog. */
|
|
354
|
+
size: ModalSize;
|
|
355
|
+
/** Positioning behavior for the actions area. */
|
|
356
|
+
actionsPosition: ModalActionsPosition;
|
|
357
|
+
/** Prevent closing when clicking the overlay. */
|
|
358
|
+
prevent: boolean;
|
|
359
|
+
/** Show or hide the close [X] button. */
|
|
360
|
+
closable: boolean;
|
|
361
|
+
/** ARIA role for the modal element. */
|
|
362
|
+
alertDialog: ModalAlertDialogRole;
|
|
363
|
+
/** If true, content is only rendered while open. */
|
|
364
|
+
lazy: boolean;
|
|
365
|
+
/** Whether a modal starts open */
|
|
366
|
+
startOpen: boolean;
|
|
367
|
+
/** Whether a modal should be removed from DOM on close */
|
|
368
|
+
removeOnClose: boolean;
|
|
369
|
+
}
|
|
370
|
+
/** Injection token for modal configuration defaults. */
|
|
371
|
+
declare const MODAL_CONFIG: InjectionToken<ModalConfig>;
|
|
372
|
+
/** Default modal configuration. */
|
|
373
|
+
declare const DEFAULT_MODAL_CONFIG: Required<ModalConfig>;
|
|
374
|
+
|
|
375
|
+
/** Component-based modal body with typed inputs/outputs. */
|
|
376
|
+
type ModalComponentBody<TComponent = unknown> = {
|
|
377
|
+
component: Type<TComponent>;
|
|
378
|
+
inputs: ComponentInputs<TComponent>;
|
|
379
|
+
outputs?: ComponentOutputs<TComponent>;
|
|
380
|
+
};
|
|
381
|
+
/** Template-based modal body with an optional context. */
|
|
382
|
+
type ModalTemplateBody<TContext = unknown> = {
|
|
383
|
+
template: TemplateRef<TContext>;
|
|
384
|
+
context?: TContext;
|
|
385
|
+
};
|
|
386
|
+
/** Union of supported modal body types. */
|
|
387
|
+
type ModalBody<T = unknown> = string | ModalTemplateBody<T> | ModalComponentBody<T>;
|
|
388
|
+
/** Public options used when creating a modal. */
|
|
389
|
+
type ModalOptions<T = unknown> = Partial<ModalConfig> & {
|
|
390
|
+
selector?: string;
|
|
391
|
+
referenceEl?: HTMLElement;
|
|
392
|
+
header?: string | TemplateRef<unknown>;
|
|
393
|
+
body?: ModalBody<T>;
|
|
394
|
+
buttons?: ModalButton[];
|
|
395
|
+
/** Callback fired when the modal is closed (user or programmatic). */
|
|
396
|
+
onClosed?: () => void;
|
|
397
|
+
/** Callback fired when the modal is removed from the DOM. */
|
|
398
|
+
onRemoved?: () => void;
|
|
399
|
+
};
|
|
400
|
+
/** Runtime modal state stored by the service. */
|
|
401
|
+
type Modal = Required<ModalConfig> & Omit<ModalOptions<unknown>, keyof ModalConfig> & {
|
|
402
|
+
id: string;
|
|
403
|
+
isOpen: boolean;
|
|
404
|
+
};
|
|
405
|
+
|
|
406
|
+
/**
|
|
407
|
+
* Central registry and lifecycle manager for modal instances.
|
|
408
|
+
*
|
|
409
|
+
* This service creates modals, tracks their state, and coordinates
|
|
410
|
+
* open/close/remove behavior across the application.
|
|
411
|
+
*/
|
|
412
|
+
declare class ModalService {
|
|
413
|
+
/** Default modal configuration injected via `MODAL_CONFIG`. */
|
|
414
|
+
private readonly config;
|
|
415
|
+
/** Incrementing counter for modal id generation. */
|
|
416
|
+
private id;
|
|
417
|
+
/** Internal store of modals keyed by id. */
|
|
418
|
+
private readonly _modals;
|
|
419
|
+
/** Read-only signal of all registered modals. */
|
|
420
|
+
readonly modals: _angular_core.Signal<Map<string, Modal>>;
|
|
421
|
+
/**
|
|
422
|
+
* Creates a new modal instance and registers it.
|
|
423
|
+
* @param options Modal options used to initialize the instance.
|
|
424
|
+
* @returns A ModalRef for controlling the instance.
|
|
425
|
+
*/
|
|
426
|
+
create<T>(options?: ModalOptions<T>): ModalRef;
|
|
427
|
+
/**
|
|
428
|
+
* Opens a modal by id.
|
|
429
|
+
* @param id Modal id.
|
|
430
|
+
*/
|
|
431
|
+
open(id: string): void;
|
|
432
|
+
/**
|
|
433
|
+
* Closes a modal by id.
|
|
434
|
+
* @param id Modal id.
|
|
435
|
+
*/
|
|
436
|
+
close(id: string): void;
|
|
437
|
+
/**
|
|
438
|
+
* Removes a modal from the registry and DOM.
|
|
439
|
+
* Closes the modal first if it is open.
|
|
440
|
+
* @param id Modal id.
|
|
441
|
+
*/
|
|
442
|
+
remove(id: string): void;
|
|
443
|
+
/**
|
|
444
|
+
* Closes all open modals.
|
|
445
|
+
*/
|
|
446
|
+
closeAll(): void;
|
|
447
|
+
/**
|
|
448
|
+
* Removes all modals from the registry.
|
|
449
|
+
*/
|
|
450
|
+
removeAll(): void;
|
|
451
|
+
/**
|
|
452
|
+
* Looks up a modal by id.
|
|
453
|
+
* @param id Modal id.
|
|
454
|
+
*/
|
|
455
|
+
private getModal;
|
|
456
|
+
/**
|
|
457
|
+
* Updates the open/closed state of a modal if it exists.
|
|
458
|
+
* @param id Modal id.
|
|
459
|
+
* @param isOpen Desired open state.
|
|
460
|
+
*/
|
|
461
|
+
private updateModalState;
|
|
462
|
+
/**
|
|
463
|
+
* Inserts or replaces a modal in the internal store.
|
|
464
|
+
* @param modal Modal to upsert.
|
|
465
|
+
*/
|
|
466
|
+
private upsertModal;
|
|
467
|
+
/**
|
|
468
|
+
* Builds a modal instance by merging defaults, existing state, and options.
|
|
469
|
+
* @param id Modal id.
|
|
470
|
+
* @param existing Existing modal state (if any).
|
|
471
|
+
* @param options New options to apply.
|
|
472
|
+
* @param isOpen Optional override for open state.
|
|
473
|
+
*/
|
|
474
|
+
private buildModal;
|
|
475
|
+
static ɵfac: _angular_core.ɵɵFactoryDeclaration<ModalService, never>;
|
|
476
|
+
static ɵprov: _angular_core.ɵɵInjectableDeclaration<ModalService>;
|
|
477
|
+
}
|
|
478
|
+
|
|
479
|
+
/**
|
|
480
|
+
* Provides modal configuration defaults and bootstraps the global modal host.
|
|
481
|
+
*
|
|
482
|
+
* @param config Optional config overrides applied on top of defaults.
|
|
483
|
+
* @returns EnvironmentProviders to register in application providers.
|
|
484
|
+
*/
|
|
485
|
+
declare function provideModal(config?: Partial<ModalConfig>): EnvironmentProviders;
|
|
486
|
+
|
|
239
487
|
/**
|
|
240
488
|
* Extracts the **output type** (validated runtime shape)
|
|
241
489
|
* from a Zod object schema — e.g. `z.output<typeof MySchema>`.
|
|
@@ -553,6 +801,169 @@ declare class HardRefreshDirective {
|
|
|
553
801
|
static ɵdir: _angular_core.ɵɵDirectiveDeclaration<HardRefreshDirective, "[taeHardRefresh]", never, { "clicksRequired": { "alias": "clicksRequired"; "required": false; "isSignal": true; }; "clickWindowMs": { "alias": "clickWindowMs"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
554
802
|
}
|
|
555
803
|
|
|
804
|
+
/**
|
|
805
|
+
* Directive that provides typed context for an `ng-template`.
|
|
806
|
+
*
|
|
807
|
+
* This is a compile-time helper: it does not affect runtime behavior,
|
|
808
|
+
* but it allows Angular's template type checker to infer the template context.
|
|
809
|
+
*
|
|
810
|
+
* Usage:
|
|
811
|
+
* ```html
|
|
812
|
+
* <ng-template #tpl let-data [typedContext]="someContext">...</ng-template>
|
|
813
|
+
* ```
|
|
814
|
+
*/
|
|
815
|
+
declare class TypedTemplateDirective<T> {
|
|
816
|
+
/**
|
|
817
|
+
* Typed context value used only for type inference.
|
|
818
|
+
* This input is not read at runtime.
|
|
819
|
+
*/
|
|
820
|
+
readonly typedContext: _angular_core.InputSignal<TemplateRef<T>>;
|
|
821
|
+
/**
|
|
822
|
+
* Template context guard to inform Angular's template type system.
|
|
823
|
+
* Always returns `true` at runtime; used purely for typing.
|
|
824
|
+
*/
|
|
825
|
+
static ngTemplateContextGuard<T>(dir: TypedTemplateDirective<T>, ctx: unknown): ctx is {
|
|
826
|
+
$implicit: T;
|
|
827
|
+
};
|
|
828
|
+
static ɵfac: _angular_core.ɵɵFactoryDeclaration<TypedTemplateDirective<any>, never>;
|
|
829
|
+
static ɵdir: _angular_core.ɵɵDirectiveDeclaration<TypedTemplateDirective<any>, "ng-template[typedContext]", never, { "typedContext": { "alias": "typedContext"; "required": true; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
830
|
+
}
|
|
831
|
+
|
|
832
|
+
/** A single day entry used by the calendar grid renderer. */
|
|
833
|
+
type CalendarDay = {
|
|
834
|
+
date: number;
|
|
835
|
+
month: number;
|
|
836
|
+
year: number;
|
|
837
|
+
isCurrentMonth: boolean;
|
|
838
|
+
isToday: boolean;
|
|
839
|
+
isSelected: boolean;
|
|
840
|
+
};
|
|
841
|
+
|
|
842
|
+
/**
|
|
843
|
+
* Standalone date/time picker that integrates with Angular forms via CVA.
|
|
844
|
+
*
|
|
845
|
+
* Supports `date`, `datetime`, and `time` modes, exposes a typed API via inputs,
|
|
846
|
+
* and emits form updates through the registered CVA callbacks.
|
|
847
|
+
*
|
|
848
|
+
* Adheres to Tegel design guidelines and can be used as a drop-in replacement.
|
|
849
|
+
*/
|
|
850
|
+
declare class TaeDateTimePickerComponent implements ControlValueAccessor {
|
|
851
|
+
private readonly elementRef;
|
|
852
|
+
readonly label: _angular_core.InputSignal<string>;
|
|
853
|
+
readonly labelPosition: _angular_core.InputSignal<"inside" | "outside" | "no-label">;
|
|
854
|
+
readonly size: _angular_core.InputSignal<"lg" | "md" | "sm">;
|
|
855
|
+
readonly state: _angular_core.InputSignal<"error" | undefined>;
|
|
856
|
+
readonly helper: _angular_core.InputSignal<string>;
|
|
857
|
+
readonly mode: _angular_core.InputSignal<"date" | "datetime" | "time">;
|
|
858
|
+
private readonly internalValue;
|
|
859
|
+
readonly displayValue: _angular_core.Signal<string>;
|
|
860
|
+
private readonly suppressChange;
|
|
861
|
+
readonly disabled: _angular_core.WritableSignal<boolean>;
|
|
862
|
+
readonly labelId: string;
|
|
863
|
+
readonly showPicker: _angular_core.WritableSignal<boolean>;
|
|
864
|
+
readonly currentMonth: _angular_core.WritableSignal<number>;
|
|
865
|
+
readonly currentYear: _angular_core.WritableSignal<number>;
|
|
866
|
+
readonly calendarDays: _angular_core.Signal<CalendarDay[]>;
|
|
867
|
+
readonly selectedDay: _angular_core.WritableSignal<number | null>;
|
|
868
|
+
readonly selectedMonth: _angular_core.WritableSignal<number | null>;
|
|
869
|
+
readonly selectedYear: _angular_core.WritableSignal<number | null>;
|
|
870
|
+
readonly selectedHour: _angular_core.WritableSignal<string | null>;
|
|
871
|
+
readonly selectedMinute: _angular_core.WritableSignal<string | null>;
|
|
872
|
+
readonly selectedSecond: _angular_core.WritableSignal<string | null>;
|
|
873
|
+
readonly weekDays: readonly ["Mo", "Tu", "We", "Th", "Fr", "Sa", "Su"];
|
|
874
|
+
readonly months: readonly ["January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"];
|
|
875
|
+
readonly hours: string[];
|
|
876
|
+
readonly minutes: string[];
|
|
877
|
+
readonly seconds: string[];
|
|
878
|
+
readonly placeholder: _angular_core.Signal<"dd-MM-YYYY HH:mm:ss" | "HH:mm:ss" | "dd-MM-YYYY">;
|
|
879
|
+
readonly currentMonthName: _angular_core.Signal<"January" | "February" | "March" | "April" | "May" | "June" | "July" | "August" | "September" | "October" | "November" | "December">;
|
|
880
|
+
private onChange;
|
|
881
|
+
private onTouched;
|
|
882
|
+
private updateScheduled;
|
|
883
|
+
constructor(elementRef: ElementRef);
|
|
884
|
+
/**
|
|
885
|
+
* Writes an ISO value from the outside into the picker state.
|
|
886
|
+
* @param value ISO date/datetime string.
|
|
887
|
+
*/
|
|
888
|
+
writeValue(value: string): void;
|
|
889
|
+
/**
|
|
890
|
+
* Registers the CVA change handler.
|
|
891
|
+
* @param fn Callback invoked on value changes.
|
|
892
|
+
*/
|
|
893
|
+
registerOnChange(fn: (value: string) => void): void;
|
|
894
|
+
/**
|
|
895
|
+
* Registers the CVA touched handler.
|
|
896
|
+
* @param fn Callback invoked on touch.
|
|
897
|
+
*/
|
|
898
|
+
registerOnTouched(fn: () => void): void;
|
|
899
|
+
/**
|
|
900
|
+
* Updates the disabled state for the control.
|
|
901
|
+
* @param isDisabled Whether the control is disabled.
|
|
902
|
+
*/
|
|
903
|
+
setDisabledState(isDisabled: boolean): void;
|
|
904
|
+
/**
|
|
905
|
+
* Closes the picker when clicking outside the component.
|
|
906
|
+
* @param event Document click event.
|
|
907
|
+
*/
|
|
908
|
+
onDocumentClick(event: MouseEvent): void;
|
|
909
|
+
/** Marks the control as touched. */
|
|
910
|
+
onBlur(): void;
|
|
911
|
+
/**
|
|
912
|
+
* Toggles the picker popover.
|
|
913
|
+
* @param event Click event from the control.
|
|
914
|
+
*/
|
|
915
|
+
togglePicker(event: Event): void;
|
|
916
|
+
/** Moves the calendar to the previous month. */
|
|
917
|
+
previousMonth(): void;
|
|
918
|
+
/** Moves the calendar to the next month. */
|
|
919
|
+
nextMonth(): void;
|
|
920
|
+
/**
|
|
921
|
+
* Builds the calendar day grid for the current month.
|
|
922
|
+
* @returns Calendar day entries for rendering.
|
|
923
|
+
*/
|
|
924
|
+
private buildCalendar;
|
|
925
|
+
/**
|
|
926
|
+
* Selects a date from the calendar grid.
|
|
927
|
+
* @param day Calendar day entry.
|
|
928
|
+
*/
|
|
929
|
+
selectDate(day: CalendarDay): void;
|
|
930
|
+
/**
|
|
931
|
+
* Selects an hour in datetime mode.
|
|
932
|
+
* @param hour Two-digit hour string.
|
|
933
|
+
*/
|
|
934
|
+
selectHour(hour: string): void;
|
|
935
|
+
/**
|
|
936
|
+
* Selects a minute in datetime mode.
|
|
937
|
+
* @param minute Two-digit minute string.
|
|
938
|
+
*/
|
|
939
|
+
selectMinute(minute: string): void;
|
|
940
|
+
/**
|
|
941
|
+
* Selects a second in datetime mode.
|
|
942
|
+
* @param second Two-digit second string.
|
|
943
|
+
*/
|
|
944
|
+
selectSecond(second: string): void;
|
|
945
|
+
/** Confirms the selection and closes the picker. */
|
|
946
|
+
confirm(): void;
|
|
947
|
+
/**
|
|
948
|
+
* Parses an ISO date segment into selected date parts.
|
|
949
|
+
* @param datePart ISO date segment.
|
|
950
|
+
*/
|
|
951
|
+
private parseDatePart;
|
|
952
|
+
/** Computes and emits the ISO value from current parts. */
|
|
953
|
+
private updateValue;
|
|
954
|
+
/** Resets all selected date/time parts to defaults. */
|
|
955
|
+
private resetSelection;
|
|
956
|
+
/**
|
|
957
|
+
* Returns current selected date parts when fully defined.
|
|
958
|
+
* @returns Date parts or `null` if incomplete.
|
|
959
|
+
*/
|
|
960
|
+
private getSelectedDateParts;
|
|
961
|
+
/** Returns today's date in local time. */
|
|
962
|
+
private getToday;
|
|
963
|
+
static ɵfac: _angular_core.ɵɵFactoryDeclaration<TaeDateTimePickerComponent, never>;
|
|
964
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<TaeDateTimePickerComponent, "tae-date-time-picker", never, { "label": { "alias": "label"; "required": false; "isSignal": true; }; "labelPosition": { "alias": "labelPosition"; "required": false; "isSignal": true; }; "size": { "alias": "size"; "required": false; "isSignal": true; }; "state": { "alias": "state"; "required": false; "isSignal": true; }; "helper": { "alias": "helper"; "required": false; "isSignal": true; }; "mode": { "alias": "mode"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
965
|
+
}
|
|
966
|
+
|
|
556
967
|
/**
|
|
557
968
|
* An enhanced standalone footer component based on the Tegel `TdsFooterComponent`.
|
|
558
969
|
*
|
|
@@ -577,7 +988,7 @@ declare class TaeFooterComponent {
|
|
|
577
988
|
*
|
|
578
989
|
* @default 'normal'
|
|
579
990
|
*/
|
|
580
|
-
readonly variant: _angular_core.InputSignal<"
|
|
991
|
+
readonly variant: _angular_core.InputSignal<"small" | "normal">;
|
|
581
992
|
/**
|
|
582
993
|
* Optional application version string to display in the footer.
|
|
583
994
|
*
|
|
@@ -593,5 +1004,5 @@ declare class TaeFooterComponent {
|
|
|
593
1004
|
static ɵcmp: _angular_core.ɵɵComponentDeclaration<TaeFooterComponent, "tae-footer", never, { "variant": { "alias": "variant"; "required": false; "isSignal": true; }; "version": { "alias": "version"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
594
1005
|
}
|
|
595
1006
|
|
|
596
|
-
export { BarcodeScannerDirective, DEFAULT_TOAST_CONFIG, HardRefreshDirective, TOAST_CONFIG, TaeFooterComponent, ToastService, createEnvKit, parseEnvFile, provideRuntimeConfig, provideStaticConfig, provideToast };
|
|
597
|
-
export type { Toast, ToastConfig, ToastOptions };
|
|
1007
|
+
export { BarcodeScannerDirective, DEFAULT_MODAL_CONFIG, DEFAULT_TOAST_CONFIG, HardRefreshDirective, MODAL_CONFIG, ModalService, TOAST_CONFIG, TaeDateTimePickerComponent, TaeFooterComponent, ToastService, TypedTemplateDirective, createEnvKit, parseEnvFile, provideModal, provideRuntimeConfig, provideStaticConfig, provideToast };
|
|
1008
|
+
export type { Modal, ModalActionsPosition, ModalAlertDialogRole, ModalButton, ModalConfig, ModalOptions, ModalRef, ModalSize, Toast, ToastConfig, ToastOptions };
|