@ks-digital/designsystem-angular 0.0.1-alpha.75 → 0.0.1-alpha.76

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 (77) hide show
  1. package/.npmignore +25 -0
  2. package/fesm2022/ks-digital-designsystem-angular-__internals.mjs +148 -78
  3. package/fesm2022/ks-digital-designsystem-angular-__internals.mjs.map +1 -1
  4. package/fesm2022/ks-digital-designsystem-angular-alert.mjs +59 -33
  5. package/fesm2022/ks-digital-designsystem-angular-alert.mjs.map +1 -1
  6. package/fesm2022/ks-digital-designsystem-angular-breadcrumbs.mjs +79 -43
  7. package/fesm2022/ks-digital-designsystem-angular-breadcrumbs.mjs.map +1 -1
  8. package/fesm2022/ks-digital-designsystem-angular-button.mjs +187 -61
  9. package/fesm2022/ks-digital-designsystem-angular-button.mjs.map +1 -1
  10. package/fesm2022/ks-digital-designsystem-angular-card.mjs +136 -86
  11. package/fesm2022/ks-digital-designsystem-angular-card.mjs.map +1 -1
  12. package/fesm2022/ks-digital-designsystem-angular-chip.mjs +76 -42
  13. package/fesm2022/ks-digital-designsystem-angular-chip.mjs.map +1 -1
  14. package/fesm2022/ks-digital-designsystem-angular-details.mjs +148 -64
  15. package/fesm2022/ks-digital-designsystem-angular-details.mjs.map +1 -1
  16. package/fesm2022/ks-digital-designsystem-angular-dialog.mjs +106 -48
  17. package/fesm2022/ks-digital-designsystem-angular-dialog.mjs.map +1 -1
  18. package/fesm2022/ks-digital-designsystem-angular-dropdown.mjs +147 -45
  19. package/fesm2022/ks-digital-designsystem-angular-dropdown.mjs.map +1 -1
  20. package/fesm2022/ks-digital-designsystem-angular-error-summary.mjs +83 -48
  21. package/fesm2022/ks-digital-designsystem-angular-error-summary.mjs.map +1 -1
  22. package/fesm2022/ks-digital-designsystem-angular-forms.mjs +495 -210
  23. package/fesm2022/ks-digital-designsystem-angular-forms.mjs.map +1 -1
  24. package/fesm2022/ks-digital-designsystem-angular-heading.mjs +69 -39
  25. package/fesm2022/ks-digital-designsystem-angular-heading.mjs.map +1 -1
  26. package/fesm2022/ks-digital-designsystem-angular-link.mjs +59 -30
  27. package/fesm2022/ks-digital-designsystem-angular-link.mjs.map +1 -1
  28. package/fesm2022/ks-digital-designsystem-angular-pagination.mjs +324 -157
  29. package/fesm2022/ks-digital-designsystem-angular-pagination.mjs.map +1 -1
  30. package/fesm2022/ks-digital-designsystem-angular-paragraph.mjs +41 -24
  31. package/fesm2022/ks-digital-designsystem-angular-paragraph.mjs.map +1 -1
  32. package/fesm2022/ks-digital-designsystem-angular-popover.mjs +147 -45
  33. package/fesm2022/ks-digital-designsystem-angular-popover.mjs.map +1 -1
  34. package/fesm2022/ks-digital-designsystem-angular-search.mjs +266 -144
  35. package/fesm2022/ks-digital-designsystem-angular-search.mjs.map +1 -1
  36. package/fesm2022/ks-digital-designsystem-angular-skeleton.mjs +78 -34
  37. package/fesm2022/ks-digital-designsystem-angular-skeleton.mjs.map +1 -1
  38. package/fesm2022/ks-digital-designsystem-angular-spinner.mjs +132 -53
  39. package/fesm2022/ks-digital-designsystem-angular-spinner.mjs.map +1 -1
  40. package/fesm2022/ks-digital-designsystem-angular-suggestion.mjs +561 -297
  41. package/fesm2022/ks-digital-designsystem-angular-suggestion.mjs.map +1 -1
  42. package/fesm2022/ks-digital-designsystem-angular-table.mjs +219 -76
  43. package/fesm2022/ks-digital-designsystem-angular-table.mjs.map +1 -1
  44. package/fesm2022/ks-digital-designsystem-angular-tabs.mjs +269 -120
  45. package/fesm2022/ks-digital-designsystem-angular-tabs.mjs.map +1 -1
  46. package/fesm2022/ks-digital-designsystem-angular-tag.mjs +84 -37
  47. package/fesm2022/ks-digital-designsystem-angular-tag.mjs.map +1 -1
  48. package/fesm2022/ks-digital-designsystem-angular-validation-message.mjs +42 -24
  49. package/fesm2022/ks-digital-designsystem-angular-validation-message.mjs.map +1 -1
  50. package/fesm2022/ks-digital-designsystem-angular.mjs +1 -6
  51. package/fesm2022/ks-digital-designsystem-angular.mjs.map +1 -1
  52. package/package.json +6 -5
  53. package/types/ks-digital-designsystem-angular-__internals.d.ts +51 -37
  54. package/types/ks-digital-designsystem-angular-alert.d.ts +18 -9
  55. package/types/ks-digital-designsystem-angular-breadcrumbs.d.ts +29 -13
  56. package/types/ks-digital-designsystem-angular-button.d.ts +67 -32
  57. package/types/ks-digital-designsystem-angular-card.d.ts +38 -23
  58. package/types/ks-digital-designsystem-angular-chip.d.ts +30 -15
  59. package/types/ks-digital-designsystem-angular-details.d.ts +32 -18
  60. package/types/ks-digital-designsystem-angular-dialog.d.ts +40 -18
  61. package/types/ks-digital-designsystem-angular-dropdown.d.ts +44 -13
  62. package/types/ks-digital-designsystem-angular-error-summary.d.ts +17 -14
  63. package/types/ks-digital-designsystem-angular-forms.d.ts +136 -71
  64. package/types/ks-digital-designsystem-angular-heading.d.ts +22 -19
  65. package/types/ks-digital-designsystem-angular-link.d.ts +18 -9
  66. package/types/ks-digital-designsystem-angular-pagination.d.ts +131 -75
  67. package/types/ks-digital-designsystem-angular-paragraph.d.ts +5 -8
  68. package/types/ks-digital-designsystem-angular-popover.d.ts +44 -13
  69. package/types/ks-digital-designsystem-angular-search.d.ts +62 -38
  70. package/types/ks-digital-designsystem-angular-skeleton.d.ts +18 -15
  71. package/types/ks-digital-designsystem-angular-spinner.d.ts +42 -23
  72. package/types/ks-digital-designsystem-angular-suggestion.d.ts +182 -116
  73. package/types/ks-digital-designsystem-angular-table.d.ts +67 -42
  74. package/types/ks-digital-designsystem-angular-tabs.d.ts +85 -56
  75. package/types/ks-digital-designsystem-angular-tag.d.ts +30 -15
  76. package/types/ks-digital-designsystem-angular-validation-message.d.ts +5 -8
  77. package/types/ks-digital-designsystem-angular.d.ts +2 -2
@@ -1,13 +1,44 @@
1
- import * as _angular_core from '@angular/core';
2
- import * as i1 from '@ks-digital/designsystem-angular/__internals';
3
-
4
- declare class Popover {
5
- readonly autoPlacement: _angular_core.InputSignalWithTransform<boolean, unknown>;
6
- readonly variant: _angular_core.InputSignal<"tinted" | "default">;
7
- readonly placement: _angular_core.InputSignal<"bottom" | "bottom-end" | "bottom-start" | "left" | "left-end" | "left-start" | "right" | "right-end" | "right-start" | "top" | "top-end" | "top-start">;
8
- readonly popover: _angular_core.InputSignal<"auto" | "manual">;
9
- static ɵfac: _angular_core.ɵɵFactoryDeclaration<Popover, never>;
10
- static ɵdir: _angular_core.ɵɵDirectiveDeclaration<Popover, "[ksd-popover]", never, { "autoPlacement": { "alias": "autoPlacement"; "required": false; "isSignal": true; }; "variant": { "alias": "data-variant"; "required": false; "isSignal": true; }; "placement": { "alias": "data-placement"; "required": false; "isSignal": true; }; "popover": { "alias": "popover"; "required": false; "isSignal": true; }; }, {}, never, never, true, [{ directive: typeof i1.HostSize; inputs: { "data-size": "data-size"; }; outputs: {}; }, { directive: typeof i1.HostColor; inputs: { "data-color": "data-color"; }; outputs: {}; }]>;
11
- }
12
-
13
- export { Popover };
1
+ import "@digdir/designsystemet-web/popover";
2
+ import * as i0 from "@angular/core";
3
+ import * as i1 from "@ks-digital/designsystem-angular/__internals";
4
+ export declare class Popover {
5
+ readonly autoPlacement: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
6
+ readonly variant: import("@angular/core").InputSignal<"tinted" | "default">;
7
+ readonly placement: import("@angular/core").InputSignal<"bottom" | "bottom-end" | "bottom-start" | "left" | "left-end" | "left-start" | "right" | "right-end" | "right-start" | "top" | "top-end" | "top-start">;
8
+ readonly popover: import("@angular/core").InputSignal<"auto" | "manual">;
9
+ static ɵfac: i0.ɵɵFactoryDeclaration<Popover, never>;
10
+ static ɵdir: i0.ɵɵDirectiveDeclaration<Popover, "[ksd-popover]", never, {
11
+ "autoPlacement": {
12
+ "alias": "autoPlacement";
13
+ "required": false;
14
+ "isSignal": true;
15
+ };
16
+ "variant": {
17
+ "alias": "data-variant";
18
+ "required": false;
19
+ "isSignal": true;
20
+ };
21
+ "placement": {
22
+ "alias": "data-placement";
23
+ "required": false;
24
+ "isSignal": true;
25
+ };
26
+ "popover": {
27
+ "alias": "popover";
28
+ "required": false;
29
+ "isSignal": true;
30
+ };
31
+ }, {}, never, never, true, [{
32
+ directive: typeof i1.HostSize;
33
+ inputs: {
34
+ "data-size": "data-size";
35
+ };
36
+ outputs: {};
37
+ }, {
38
+ directive: typeof i1.HostColor;
39
+ inputs: {
40
+ "data-color": "data-color";
41
+ };
42
+ outputs: {};
43
+ }]>;
44
+ }
@@ -1,6 +1,6 @@
1
- import * as i0 from '@angular/core';
2
- import * as i1 from '@ks-digital/designsystem-angular/__internals';
3
-
1
+ import "@digdir/designsystemet-web";
2
+ import * as i0 from "@angular/core";
3
+ import * as i1 from "@ks-digital/designsystem-angular/__internals";
4
4
  /**
5
5
  * Search Component
6
6
  *
@@ -14,13 +14,24 @@ import * as i1 from '@ks-digital/designsystem-angular/__internals';
14
14
  * <button ksd-search-button></button>
15
15
  * </div>
16
16
  */
17
- declare class Search {
18
- private readonly input;
19
- constructor();
20
- static ɵfac: i0.ɵɵFactoryDeclaration<Search, never>;
21
- static ɵcmp: i0.ɵɵComponentDeclaration<Search, "ksd-search", never, {}, {}, ["input"], ["[ksd-search-input]", "[ksd-search-clear]", "[ksd-search-button]"], true, [{ directive: typeof i1.HostSize; inputs: { "data-size": "data-size"; }; outputs: {}; }, { directive: typeof i1.HostColor; inputs: { "data-color": "data-color"; }; outputs: {}; }]>;
17
+ export declare class Search {
18
+ private readonly input;
19
+ constructor();
20
+ static ɵfac: i0.ɵɵFactoryDeclaration<Search, never>;
21
+ static ɵcmp: i0.ɵɵComponentDeclaration<Search, "ksd-search", never, {}, {}, ["input"], ["[ksd-search-input]", "[ksd-search-clear]", "[ksd-search-button]"], true, [{
22
+ directive: typeof i1.HostSize;
23
+ inputs: {
24
+ "data-size": "data-size";
25
+ };
26
+ outputs: {};
27
+ }, {
28
+ directive: typeof i1.HostColor;
29
+ inputs: {
30
+ "data-color": "data-color";
31
+ };
32
+ outputs: {};
33
+ }]>;
22
34
  }
23
-
24
35
  /**
25
36
  * Search button
26
37
  *
@@ -30,21 +41,31 @@ declare class Search {
30
41
  * @param {string} [aria-label] - Aria label for the button
31
42
  *
32
43
  */
33
- declare class SearchButton {
34
- /**
35
- * Specify which button variant to use
36
- *
37
- * @default 'primary'
38
- */
39
- readonly variant: i0.InputSignal<"primary" | "secondary">;
40
- /**
41
- * Aria label for the button
42
- */
43
- readonly ariaLabel: i0.InputSignal<string>;
44
- static ɵfac: i0.ɵɵFactoryDeclaration<SearchButton, never>;
45
- static ɵdir: i0.ɵɵDirectiveDeclaration<SearchButton, "button[ksd-search-button]", never, { "variant": { "alias": "variant"; "required": false; "isSignal": true; }; "ariaLabel": { "alias": "aria-label"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
44
+ export declare class SearchButton {
45
+ /**
46
+ * Specify which button variant to use
47
+ *
48
+ * @default 'primary'
49
+ */
50
+ readonly variant: import("@angular/core").InputSignal<"primary" | "secondary">;
51
+ /**
52
+ * Aria label for the button
53
+ */
54
+ readonly ariaLabel: import("@angular/core").InputSignal<string>;
55
+ static ɵfac: i0.ɵɵFactoryDeclaration<SearchButton, never>;
56
+ static ɵdir: i0.ɵɵDirectiveDeclaration<SearchButton, "button[ksd-search-button]", never, {
57
+ "variant": {
58
+ "alias": "variant";
59
+ "required": false;
60
+ "isSignal": true;
61
+ };
62
+ "ariaLabel": {
63
+ "alias": "aria-label";
64
+ "required": false;
65
+ "isSignal": true;
66
+ };
67
+ }, {}, never, never, true, never>;
46
68
  }
47
-
48
69
  /**
49
70
  * Search clear button
50
71
  *
@@ -53,24 +74,27 @@ declare class SearchButton {
53
74
  *
54
75
  * @param {string} [aria-label] - Aria label for the button.
55
76
  */
56
- declare class SearchClear {
57
- /**
58
- * Aria label for the button
59
- * @default 'Tøm'
60
- */
61
- readonly ariaLabel: i0.InputSignal<string>;
62
- static ɵfac: i0.ɵɵFactoryDeclaration<SearchClear, never>;
63
- static ɵdir: i0.ɵɵDirectiveDeclaration<SearchClear, "button[ksd-search-clear]", never, { "ariaLabel": { "alias": "aria-label"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
77
+ export declare class SearchClear {
78
+ /**
79
+ * Aria label for the button
80
+ * @default 'Tøm'
81
+ */
82
+ readonly ariaLabel: import("@angular/core").InputSignal<string>;
83
+ static ɵfac: i0.ɵɵFactoryDeclaration<SearchClear, never>;
84
+ static ɵdir: i0.ɵɵDirectiveDeclaration<SearchClear, "button[ksd-search-clear]", never, {
85
+ "ariaLabel": {
86
+ "alias": "aria-label";
87
+ "required": false;
88
+ "isSignal": true;
89
+ };
90
+ }, {}, never, never, true, never>;
64
91
  }
65
-
66
92
  /**
67
93
  * Search input
68
94
  *
69
95
  * Used within Search to provide a search input.
70
96
  */
71
- declare class SearchInput {
72
- static ɵfac: i0.ɵɵFactoryDeclaration<SearchInput, never>;
73
- static ɵdir: i0.ɵɵDirectiveDeclaration<SearchInput, "input[ksd-search-input]", never, {}, {}, never, never, true, never>;
74
- }
75
-
76
- export { Search, SearchButton, SearchClear, SearchInput };
97
+ export declare class SearchInput {
98
+ static ɵfac: i0.ɵɵFactoryDeclaration<SearchInput, never>;
99
+ static ɵdir: i0.ɵɵDirectiveDeclaration<SearchInput, "input[ksd-search-input]", never, {}, {}, never, never, true, never>;
100
+ }
@@ -1,18 +1,21 @@
1
- import * as _angular_core from '@angular/core';
2
-
1
+ import * as i0 from "@angular/core";
3
2
  /**
4
3
  * Skeleton is used to represent a draft of a page while the content loads.
5
4
  */
6
- declare class Skeleton {
7
- /**
8
- * Specify which variant to use
9
- * @default 'rectangle'
10
- */
11
- readonly variant: _angular_core.InputSignal<"rectangle" | "circle" | "text">;
12
- readonly isText: _angular_core.Signal<boolean>;
13
- readonly dataText: _angular_core.Signal<"-" | null>;
14
- static ɵfac: _angular_core.ɵɵFactoryDeclaration<Skeleton, never>;
15
- static ɵcmp: _angular_core.ɵɵComponentDeclaration<Skeleton, "ksd-skeleton", never, { "variant": { "alias": "data-variant"; "required": false; "isSignal": true; }; }, {}, never, ["*"], true, never>;
16
- }
17
-
18
- export { Skeleton };
5
+ export declare class Skeleton {
6
+ /**
7
+ * Specify which variant to use
8
+ * @default 'rectangle'
9
+ */
10
+ readonly variant: import("@angular/core").InputSignal<"rectangle" | "circle" | "text">;
11
+ readonly isText: import("@angular/core").Signal<boolean>;
12
+ readonly dataText: import("@angular/core").Signal<"-" | null>;
13
+ static ɵfac: i0.ɵɵFactoryDeclaration<Skeleton, never>;
14
+ static ɵcmp: i0.ɵɵComponentDeclaration<Skeleton, "ksd-skeleton", never, {
15
+ "variant": {
16
+ "alias": "data-variant";
17
+ "required": false;
18
+ "isSignal": true;
19
+ };
20
+ }, {}, never, ["*"], true, never>;
21
+ }
@@ -1,23 +1,42 @@
1
- import * as _angular_core from '@angular/core';
2
- import * as i1 from '@ks-digital/designsystem-angular/__internals';
3
-
4
- declare class Spinner {
5
- /**
6
- * Aria-label for the spinner
7
- */
8
- readonly ariaLabel: _angular_core.InputSignal<string | undefined>;
9
- /**
10
- * Aria-hidden for the spinner
11
- */
12
- readonly ariaHidden: _angular_core.InputSignalWithTransform<boolean | undefined, unknown>;
13
- constructor();
14
- /**
15
- * Changes size for descendant Designsystemet components. Select from predefined sizes.
16
- * @attribute data-size
17
- */
18
- readonly dataSize: _angular_core.InputSignal<any>;
19
- static ɵfac: _angular_core.ɵɵFactoryDeclaration<Spinner, never>;
20
- static ɵcmp: _angular_core.ɵɵComponentDeclaration<Spinner, "ksd-spinner", never, { "ariaLabel": { "alias": "aria-label"; "required": false; "isSignal": true; }; "ariaHidden": { "alias": "aria-hidden"; "required": false; "isSignal": true; }; "dataSize": { "alias": "data-size"; "required": false; "isSignal": true; }; }, {}, never, never, true, [{ directive: typeof i1.HostColor; inputs: { "data-color": "data-color"; }; outputs: {}; }]>;
21
- }
22
-
23
- export { Spinner };
1
+ import * as i0 from "@angular/core";
2
+ import * as i1 from "@ks-digital/designsystem-angular/__internals";
3
+ export declare class Spinner {
4
+ /**
5
+ * Aria-label for the spinner
6
+ */
7
+ readonly ariaLabel: import("@angular/core").InputSignal<string | undefined>;
8
+ /**
9
+ * Aria-hidden for the spinner
10
+ */
11
+ readonly ariaHidden: import("@angular/core").InputSignalWithTransform<boolean | undefined, unknown>;
12
+ constructor();
13
+ /**
14
+ * Changes size for descendant Designsystemet components. Select from predefined sizes.
15
+ * @attribute data-size
16
+ */
17
+ readonly dataSize: import("@angular/core").InputSignal<any>;
18
+ static ɵfac: i0.ɵɵFactoryDeclaration<Spinner, never>;
19
+ static ɵcmp: i0.ɵɵComponentDeclaration<Spinner, "ksd-spinner", never, {
20
+ "ariaLabel": {
21
+ "alias": "aria-label";
22
+ "required": false;
23
+ "isSignal": true;
24
+ };
25
+ "ariaHidden": {
26
+ "alias": "aria-hidden";
27
+ "required": false;
28
+ "isSignal": true;
29
+ };
30
+ "dataSize": {
31
+ "alias": "data-size";
32
+ "required": false;
33
+ "isSignal": true;
34
+ };
35
+ }, {}, never, never, true, [{
36
+ directive: typeof i1.HostColor;
37
+ inputs: {
38
+ "data-color": "data-color";
39
+ };
40
+ outputs: {};
41
+ }]>;
42
+ }
@@ -1,52 +1,65 @@
1
- import * as _ks_digital_designsystem_angular_suggestion from '@ks-digital/designsystem-angular/suggestion';
2
- import * as _angular_core from '@angular/core';
3
- import { TemplateRef } from '@angular/core';
4
- import { FormValueControl } from '@angular/forms/signals';
5
- import * as i1 from '@ks-digital/designsystem-angular/__internals';
6
-
7
- declare class SuggestionListEmpty {
8
- /**
9
- * Hack to get the content from parent component so that we can
10
- * keep the dom structure needed without additional host elements
11
- */
12
- templateRef: _angular_core.Signal<TemplateRef<unknown> | undefined>;
13
- static ɵfac: _angular_core.ɵɵFactoryDeclaration<SuggestionListEmpty, never>;
14
- static ɵcmp: _angular_core.ɵɵComponentDeclaration<SuggestionListEmpty, "ksd-suggestion-list-empty", never, {}, {}, never, ["*"], true, never>;
1
+ import { FormValueControl } from "@angular/forms/signals";
2
+ import "@digdir/designsystemet-web";
3
+ import * as i0 from "@angular/core";
4
+ import { TemplateRef } from "@angular/core";
5
+ import * as i1 from "@ks-digital/designsystem-angular/__internals";
6
+ export declare class SuggestionListEmpty {
7
+ /**
8
+ * Hack to get the content from parent component so that we can
9
+ * keep the dom structure needed without additional host elements
10
+ */
11
+ templateRef: import("@angular/core").Signal<TemplateRef<unknown> | undefined>;
12
+ static ɵfac: i0.ɵɵFactoryDeclaration<SuggestionListEmpty, never>;
13
+ static ɵcmp: i0.ɵɵComponentDeclaration<SuggestionListEmpty, "ksd-suggestion-list-empty", never, {}, {}, never, ["*"], true, never>;
15
14
  }
16
-
17
- declare class SuggestionListOption {
18
- /**
19
- * Hack to get the content from parent component so that we can
20
- * keep the dom structure needed without additional host elements
21
- */
22
- templateRef: _angular_core.Signal<TemplateRef<unknown> | undefined>;
23
- value: _angular_core.InputSignal<string>;
24
- static ɵfac: _angular_core.ɵɵFactoryDeclaration<SuggestionListOption, never>;
25
- static ɵcmp: _angular_core.ɵɵComponentDeclaration<SuggestionListOption, "ksd-suggestion-list-option", never, { "value": { "alias": "value"; "required": true; "isSignal": true; }; }, {}, never, ["*"], true, never>;
15
+ export declare class SuggestionListOption {
16
+ /**
17
+ * Hack to get the content from parent component so that we can
18
+ * keep the dom structure needed without additional host elements
19
+ */
20
+ templateRef: import("@angular/core").Signal<TemplateRef<unknown> | undefined>;
21
+ value: import("@angular/core").InputSignal<string>;
22
+ static ɵfac: i0.ɵɵFactoryDeclaration<SuggestionListOption, never>;
23
+ static ɵcmp: i0.ɵɵComponentDeclaration<SuggestionListOption, "ksd-suggestion-list-option", never, {
24
+ "value": {
25
+ "alias": "value";
26
+ "required": true;
27
+ "isSignal": true;
28
+ };
29
+ }, {}, never, ["*"], true, never>;
26
30
  }
27
-
28
- declare class SuggestionList {
29
- /**
30
- * Screen reader announcement template for singular result count.
31
- *
32
- * @default '%d forslag'
33
- */
34
- readonly singular: _angular_core.InputSignal<string>;
35
- /**
36
- * Screen reader announcement template for plural result count.
37
- *
38
- * @default '%d forslag'
39
- */
40
- readonly plural: _angular_core.InputSignal<string>;
41
- readonly options: _angular_core.Signal<readonly SuggestionListOption[]>;
42
- readonly empty: _angular_core.Signal<SuggestionListEmpty | undefined>;
43
- static ɵfac: _angular_core.ɵɵFactoryDeclaration<SuggestionList, never>;
44
- static ɵcmp: _angular_core.ɵɵComponentDeclaration<SuggestionList, "ksd-suggestion-list", never, { "singular": { "alias": "singular"; "required": false; "isSignal": true; }; "plural": { "alias": "plural"; "required": false; "isSignal": true; }; }, {}, ["options", "empty"], never, true, never>;
31
+ export declare class SuggestionList {
32
+ /**
33
+ * Screen reader announcement template for singular result count.
34
+ *
35
+ * @default '%d forslag'
36
+ */
37
+ readonly singular: import("@angular/core").InputSignal<string>;
38
+ /**
39
+ * Screen reader announcement template for plural result count.
40
+ *
41
+ * @default '%d forslag'
42
+ */
43
+ readonly plural: import("@angular/core").InputSignal<string>;
44
+ readonly options: import("@angular/core").Signal<readonly SuggestionListOption[]>;
45
+ readonly empty: import("@angular/core").Signal<SuggestionListEmpty | undefined>;
46
+ static ɵfac: i0.ɵɵFactoryDeclaration<SuggestionList, never>;
47
+ static ɵcmp: i0.ɵɵComponentDeclaration<SuggestionList, "ksd-suggestion-list", never, {
48
+ "singular": {
49
+ "alias": "singular";
50
+ "required": false;
51
+ "isSignal": true;
52
+ };
53
+ "plural": {
54
+ "alias": "plural";
55
+ "required": false;
56
+ "isSignal": true;
57
+ };
58
+ }, {}, ["options", "empty"], never, true, never>;
45
59
  }
46
-
47
60
  type SuggestionItem = {
48
- label: string;
49
- value: string;
61
+ label: string;
62
+ value: string;
50
63
  };
51
64
  /** Value of the `value` model and Angular signal forms. Always primitive. */
52
65
  type SuggestionValue = string | string[] | undefined;
@@ -55,78 +68,131 @@ type SuggestionSelectedInput = SuggestionItem | SuggestionItem[] | string | stri
55
68
  /** Emitted by `(selectedChange)`. Always resolved items. */
56
69
  type SuggestionSelected = SuggestionItem | SuggestionItem[] | undefined;
57
70
  type SuggestionFilterArgs = {
58
- index: number;
59
- label: string;
60
- text: string;
61
- value: string;
62
- optionElement: HTMLOptionElement;
63
- input: HTMLInputElement;
71
+ index: number;
72
+ label: string;
73
+ text: string;
74
+ value: string;
75
+ optionElement: HTMLOptionElement;
76
+ input: HTMLInputElement;
64
77
  };
65
78
  type SuggestionFilter = (args: SuggestionFilterArgs) => boolean;
66
-
67
79
  declare const UNSET: unique symbol;
68
- declare class Suggestion implements FormValueControl<SuggestionValue> {
69
- /**
70
- * Allows the user to select multiple items
71
- *
72
- * @default false
73
- */
74
- multiple: _angular_core.InputSignalWithTransform<boolean, unknown>;
75
- /**
76
- * Allows the user to create new items
77
- *
78
- * @default false
79
- */
80
- creatable: _angular_core.InputSignalWithTransform<boolean, unknown>;
81
- /**
82
- * Filter options; boolean or a custom callback.
83
- *
84
- * @default true
85
- */
86
- filter: _angular_core.InputSignal<boolean | SuggestionFilter>;
87
- /**
88
- * Current value, as primitive option values. Bound by Angular signal forms.
89
- *
90
- * @default undefined
91
- */
92
- readonly value: _angular_core.ModelSignal<SuggestionValue>;
93
- /**
94
- * Controlled selection. Accepts items or raw option values.
95
- *
96
- * @default undefined
97
- */
98
- readonly selected: _angular_core.InputSignal<SuggestionSelectedInput | typeof UNSET>;
99
- /**
100
- * Emits the resolved selection whenever the user changes it.
101
- */
102
- readonly selectedChange: _angular_core.OutputEmitterRef<SuggestionSelected>;
103
- /**
104
- * Form-control dirty state.
105
- *
106
- * @default false
107
- */
108
- readonly dirty: _angular_core.InputSignalWithTransform<boolean, unknown>;
109
- /**
110
- * Whether the control has been touched. Synced with Angular signal forms.
111
- *
112
- * @default false
113
- */
114
- readonly touched: _angular_core.ModelSignal<boolean>;
115
- protected selectedArray: _angular_core.Signal<_ks_digital_designsystem_angular_suggestion.SuggestionItem[]>;
116
- private readonly suggestionElement;
117
- private readonly labels;
118
- private readonly query;
119
- protected readonly suggestionList: _angular_core.Signal<SuggestionList | undefined>;
120
- constructor();
121
- protected onSelect(event: Event): void;
122
- protected onFocusOut(event: FocusEvent): void;
123
- protected onInput(event: Event): void;
124
- private setValue;
125
- private learnLabels;
126
- private syncOptions;
127
- static ɵfac: _angular_core.ɵɵFactoryDeclaration<Suggestion, never>;
128
- static ɵcmp: _angular_core.ɵɵComponentDeclaration<Suggestion, "ksd-suggestion", never, { "multiple": { "alias": "multiple"; "required": false; "isSignal": true; }; "creatable": { "alias": "creatable"; "required": false; "isSignal": true; }; "filter": { "alias": "filter"; "required": false; "isSignal": true; }; "value": { "alias": "value"; "required": false; "isSignal": true; }; "selected": { "alias": "selected"; "required": false; "isSignal": true; }; "dirty": { "alias": "dirty"; "required": false; "isSignal": true; }; "touched": { "alias": "touched"; "required": false; "isSignal": true; }; }, { "value": "valueChange"; "selectedChange": "selectedChange"; "touched": "touchedChange"; }, ["suggestionList"], ["*"], true, [{ directive: typeof i1.HostSize; inputs: { "data-size": "data-size"; }; outputs: {}; }, { directive: typeof i1.HostColor; inputs: { "data-color": "data-color"; }; outputs: {}; }]>;
80
+ export declare class Suggestion implements FormValueControl<SuggestionValue> {
81
+ /**
82
+ * Allows the user to select multiple items
83
+ *
84
+ * @default false
85
+ */
86
+ multiple: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
87
+ /**
88
+ * Allows the user to create new items
89
+ *
90
+ * @default false
91
+ */
92
+ creatable: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
93
+ /**
94
+ * Filter options; boolean or a custom callback.
95
+ *
96
+ * @default true
97
+ */
98
+ filter: import("@angular/core").InputSignal<boolean | SuggestionFilter>;
99
+ /**
100
+ * Current value, as primitive option values. Bound by Angular signal forms.
101
+ *
102
+ * @default undefined
103
+ */
104
+ readonly value: import("@angular/core").ModelSignal<SuggestionValue>;
105
+ /**
106
+ * Controlled selection. Accepts items or raw option values.
107
+ *
108
+ * @default undefined
109
+ */
110
+ readonly selected: import("@angular/core").InputSignal<SuggestionSelectedInput | typeof UNSET>;
111
+ /**
112
+ * Emits the resolved selection whenever the user changes it.
113
+ */
114
+ readonly selectedChange: import("@angular/core").OutputEmitterRef<SuggestionSelected>;
115
+ /**
116
+ * Form-control dirty state.
117
+ *
118
+ * @default false
119
+ */
120
+ readonly dirty: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
121
+ /**
122
+ * Whether the control has been touched. Bound by Angular signal forms.
123
+ *
124
+ * @default false
125
+ */
126
+ readonly touched: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
127
+ /**
128
+ * Emits when focus leaves the control, marking the bound form field as touched.
129
+ */
130
+ readonly touch: import("@angular/core").OutputEmitterRef<void>;
131
+ protected selectedArray: import("@angular/core").Signal<import("@ks-digital/designsystem-angular/suggestion").SuggestionItem[]>;
132
+ private readonly suggestionElement;
133
+ private readonly labels;
134
+ private readonly query;
135
+ protected readonly suggestionList: import("@angular/core").Signal<SuggestionList | undefined>;
136
+ constructor();
137
+ protected onSelect(event: Event): void;
138
+ protected onFocusOut(event: FocusEvent): void;
139
+ protected onInput(event: Event): void;
140
+ private setValue;
141
+ private learnLabels;
142
+ private syncOptions;
143
+ static ɵfac: i0.ɵɵFactoryDeclaration<Suggestion, never>;
144
+ static ɵcmp: i0.ɵɵComponentDeclaration<Suggestion, "ksd-suggestion", never, {
145
+ "multiple": {
146
+ "alias": "multiple";
147
+ "required": false;
148
+ "isSignal": true;
149
+ };
150
+ "creatable": {
151
+ "alias": "creatable";
152
+ "required": false;
153
+ "isSignal": true;
154
+ };
155
+ "filter": {
156
+ "alias": "filter";
157
+ "required": false;
158
+ "isSignal": true;
159
+ };
160
+ "value": {
161
+ "alias": "value";
162
+ "required": false;
163
+ "isSignal": true;
164
+ };
165
+ "selected": {
166
+ "alias": "selected";
167
+ "required": false;
168
+ "isSignal": true;
169
+ };
170
+ "dirty": {
171
+ "alias": "dirty";
172
+ "required": false;
173
+ "isSignal": true;
174
+ };
175
+ "touched": {
176
+ "alias": "touched";
177
+ "required": false;
178
+ "isSignal": true;
179
+ };
180
+ }, {
181
+ "value": "valueChange";
182
+ "selectedChange": "selectedChange";
183
+ "touch": "touch";
184
+ }, ["suggestionList"], ["*"], true, [{
185
+ directive: typeof i1.HostSize;
186
+ inputs: {
187
+ "data-size": "data-size";
188
+ };
189
+ outputs: {};
190
+ }, {
191
+ directive: typeof i1.HostColor;
192
+ inputs: {
193
+ "data-color": "data-color";
194
+ };
195
+ outputs: {};
196
+ }]>;
129
197
  }
130
-
131
- export { Suggestion, SuggestionList, SuggestionListEmpty, SuggestionListOption };
132
- export type { SuggestionFilter, SuggestionFilterArgs, SuggestionItem, SuggestionSelected, SuggestionSelectedInput, SuggestionValue };
198
+ export type { SuggestionFilter, SuggestionFilterArgs, SuggestionItem, SuggestionSelected, SuggestionSelectedInput, SuggestionValue };