@bootkit/ng0 0.0.0-alpha.17 → 0.0.0-alpha.18

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 (72) hide show
  1. package/README.md +2 -2
  2. package/common/index.d.ts +60 -4
  3. package/components/list/index.d.ts +127 -0
  4. package/components/select/index.d.ts +120 -0
  5. package/components/table/index.d.ts +66 -10
  6. package/data/index.d.ts +171 -51
  7. package/fesm2022/bootkit-ng0-common.mjs +51 -1
  8. package/fesm2022/bootkit-ng0-common.mjs.map +1 -1
  9. package/fesm2022/bootkit-ng0-components-accordion.mjs +14 -14
  10. package/fesm2022/bootkit-ng0-components-accordion.mjs.map +1 -1
  11. package/fesm2022/bootkit-ng0-components-backdrop.mjs +4 -4
  12. package/fesm2022/bootkit-ng0-components-backdrop.mjs.map +1 -1
  13. package/fesm2022/bootkit-ng0-components-button.mjs +11 -11
  14. package/fesm2022/bootkit-ng0-components-button.mjs.map +1 -1
  15. package/fesm2022/bootkit-ng0-components-card.mjs +12 -12
  16. package/fesm2022/bootkit-ng0-components-card.mjs.map +1 -1
  17. package/fesm2022/bootkit-ng0-components-code.mjs +9 -9
  18. package/fesm2022/bootkit-ng0-components-code.mjs.map +1 -1
  19. package/fesm2022/bootkit-ng0-components-collapse.mjs +14 -14
  20. package/fesm2022/bootkit-ng0-components-collapse.mjs.map +1 -1
  21. package/fesm2022/bootkit-ng0-components-confirmation.mjs +14 -14
  22. package/fesm2022/bootkit-ng0-components-confirmation.mjs.map +1 -1
  23. package/fesm2022/bootkit-ng0-components-form-field.mjs +14 -14
  24. package/fesm2022/bootkit-ng0-components-form-field.mjs.map +1 -1
  25. package/fesm2022/bootkit-ng0-components-list.mjs +331 -0
  26. package/fesm2022/bootkit-ng0-components-list.mjs.map +1 -0
  27. package/fesm2022/bootkit-ng0-components-modal.mjs +13 -13
  28. package/fesm2022/bootkit-ng0-components-modal.mjs.map +1 -1
  29. package/fesm2022/bootkit-ng0-components-nav.mjs +27 -27
  30. package/fesm2022/bootkit-ng0-components-nav.mjs.map +1 -1
  31. package/fesm2022/bootkit-ng0-components-offcanvas.mjs +9 -9
  32. package/fesm2022/bootkit-ng0-components-offcanvas.mjs.map +1 -1
  33. package/fesm2022/bootkit-ng0-components-overlay.mjs.map +1 -1
  34. package/fesm2022/bootkit-ng0-components-pagination.mjs +15 -15
  35. package/fesm2022/bootkit-ng0-components-pagination.mjs.map +1 -1
  36. package/fesm2022/bootkit-ng0-components-popover.mjs +11 -11
  37. package/fesm2022/bootkit-ng0-components-popover.mjs.map +1 -1
  38. package/fesm2022/bootkit-ng0-components-select.mjs +394 -0
  39. package/fesm2022/bootkit-ng0-components-select.mjs.map +1 -0
  40. package/fesm2022/bootkit-ng0-components-sidenav.mjs +21 -21
  41. package/fesm2022/bootkit-ng0-components-sidenav.mjs.map +1 -1
  42. package/fesm2022/bootkit-ng0-components-stepper.mjs +13 -13
  43. package/fesm2022/bootkit-ng0-components-stepper.mjs.map +1 -1
  44. package/fesm2022/bootkit-ng0-components-table.mjs +170 -72
  45. package/fesm2022/bootkit-ng0-components-table.mjs.map +1 -1
  46. package/fesm2022/bootkit-ng0-components-toast.mjs +7 -7
  47. package/fesm2022/bootkit-ng0-components-toast.mjs.map +1 -1
  48. package/fesm2022/bootkit-ng0-components-tooltip.mjs +9 -9
  49. package/fesm2022/bootkit-ng0-components-tooltip.mjs.map +1 -1
  50. package/fesm2022/bootkit-ng0-components-vertical-menu.mjs +26 -26
  51. package/fesm2022/bootkit-ng0-components-vertical-menu.mjs.map +1 -1
  52. package/fesm2022/bootkit-ng0-data.mjs +177 -60
  53. package/fesm2022/bootkit-ng0-data.mjs.map +1 -1
  54. package/fesm2022/bootkit-ng0-date.mjs.map +1 -1
  55. package/fesm2022/bootkit-ng0-file.mjs.map +1 -1
  56. package/fesm2022/bootkit-ng0-form.mjs +36 -36
  57. package/fesm2022/bootkit-ng0-form.mjs.map +1 -1
  58. package/fesm2022/bootkit-ng0-http.mjs +3 -3
  59. package/fesm2022/bootkit-ng0-http.mjs.map +1 -1
  60. package/fesm2022/bootkit-ng0-localization-locales.mjs +20 -0
  61. package/fesm2022/bootkit-ng0-localization-locales.mjs.map +1 -1
  62. package/fesm2022/bootkit-ng0-localization.mjs +100 -35
  63. package/fesm2022/bootkit-ng0-localization.mjs.map +1 -1
  64. package/fesm2022/bootkit-ng0-platform-browser.mjs +7 -7
  65. package/fesm2022/bootkit-ng0-platform-browser.mjs.map +1 -1
  66. package/fesm2022/bootkit-ng0-script.mjs +3 -3
  67. package/fesm2022/bootkit-ng0-script.mjs.map +1 -1
  68. package/fesm2022/bootkit-ng0-security.mjs +15 -15
  69. package/fesm2022/bootkit-ng0-security.mjs.map +1 -1
  70. package/fesm2022/bootkit-ng0.mjs.map +1 -1
  71. package/localization/index.d.ts +63 -28
  72. package/package.json +22 -14
package/data/index.d.ts CHANGED
@@ -1,6 +1,26 @@
1
1
  import * as _angular_core from '@angular/core';
2
2
  import * as rxjs from 'rxjs';
3
- import { Observable } from 'rxjs';
3
+ import { Observable, Subject } from 'rxjs';
4
+
5
+ /**
6
+ * Boolean value comparer function type.
7
+ * @param a First value to compare.
8
+ * @param b Second value to compare.
9
+ * @returns true if a is considered equal to b else returns false
10
+ */
11
+ type BooleanValueComparer = (a: any, b: any) => boolean;
12
+ /**
13
+ * Boolean value comparer can be a function or a string representing the property name to compare.
14
+ */
15
+ type BooleanValueComparerLike = BooleanValueComparer | string;
16
+ /**
17
+ * Default value comparer function.
18
+ * @param a
19
+ * @param b
20
+ * @returns true if a === b else returns false
21
+ */
22
+ declare function defaultBooleanValueComparer(a: any, b: any): boolean;
23
+ declare function BooleanValueComparerAttribute(v: BooleanValueComparerLike): BooleanValueComparer;
4
24
 
5
25
  /**
6
26
  * DataRequest class represents a request for data with pagination, filtering, sorting, and field selection.
@@ -81,84 +101,184 @@ declare class DataResult<T = any> {
81
101
  constructor(data: T[], total?: number | undefined);
82
102
  }
83
103
 
84
- /**
85
- * Abstract base class for data sources.
86
- * This class provides a common interface for loading data from various sources.
87
- */
88
- declare abstract class DataSource<T = any> {
89
- protected loading: _angular_core.WritableSignal<boolean>;
90
- constructor();
91
- /**
92
- * Indicates whether the data source is currently loading data.
93
- */
94
- isLoading: _angular_core.Signal<boolean>;
95
- /**
96
- * Loads data from the data source.
97
- * @param request The data request object containing pagination, sorting, and filtering information.
98
- */
99
- abstract load(request: DataRequest): Observable<DataResult>;
100
- }
101
-
102
104
  /**
103
105
  * DataLoader is a function that takes a DataRequest and returns an Observable of DataResult.
104
106
  * It is used by AsyncDataSource to load data asynchronously.
105
107
  */
106
108
  type DataLoader<T = any> = (request: DataRequest) => Observable<DataResult<T>>;
107
109
  /**
108
- * AsyncDataSource is a DataSource that loads data asynchronously using a DataLoader function.
110
+ * RemoteDataSource is a DataSource that loads data asynchronously using a DataLoader function.
109
111
  * It is used to fetch data from a remote source, such as an API.
110
112
  */
111
- declare class AsyncDataSource extends DataSource {
113
+ declare class RemoteDataSource extends DataSource {
112
114
  private readonly loader;
115
+ readonly type = "remote";
113
116
  constructor(loader: DataLoader);
114
117
  load(request: DataRequest): Observable<DataResult<any>>;
115
118
  }
116
119
 
120
+ /**
121
+ * DataSourceLike is a type that can be used to represent any data source
122
+ * that can be used with the table, autocomplete, dropdown and any component that requires data.
123
+ * It can be an array of data, a function that returns an observable of data,
124
+ * or an instance of DataSource.
125
+ */
126
+ type DataSourceLike<T = any> = Array<any> | DataLoader<T> | DataSource<T> | Record<string, string | number> | // enum: extract enum or object values
127
+ undefined | null;
128
+ /**
129
+ * Converts a DataSourceLike to a DataSource instance.
130
+ * @param source The data source to convert.
131
+ * @returns A DataSource instance.
132
+ */
133
+ declare function dataSourceAttribute<T>(source: DataSourceLike): DataSource<T>;
134
+ /**
135
+ * LogicalOperator is a list of predefined logical operators that can be used in data requests to filter data.
136
+ */
137
+ type LogicalOperator = 'contains' | 'endsWith' | 'startsWith' | 'like' | 'eq' | 'ne' | 'gt' | 'gte' | 'lt' | 'lte';
138
+ interface DataSourceChange {
139
+ type: 'insert' | 'replace' | 'remove';
140
+ }
141
+ interface DataSourceItemInsert extends DataSourceChange {
142
+ type: 'insert';
143
+ /** Insert index */
144
+ index?: number;
145
+ items: any[];
146
+ }
147
+ interface DataSourceItemReplace extends DataSourceChange {
148
+ type: 'replace';
149
+ index: number;
150
+ value: any;
151
+ }
152
+ interface DataSourceItemRemove extends DataSourceChange {
153
+ type: 'remove';
154
+ index: number;
155
+ count?: number;
156
+ }
157
+ interface DataSourceChangeEvent {
158
+ changes: Array<DataSourceItemInsert | DataSourceItemReplace | DataSourceItemRemove>;
159
+ }
160
+
161
+ /**
162
+ * Value extractor function type.
163
+ */
164
+ type ValueExtractor = (a: any) => any;
165
+ /**
166
+ * Value extractor can be a function or a string representing the property name to extract.
167
+ */
168
+ type ValueExtractorLike = ValueExtractor | string;
169
+ /**
170
+ * Default value extractor function.
171
+ * @param a The input value
172
+ * @returns the input value
173
+ */
174
+ declare function defaultValueExtractor(a: any): any;
175
+ /**
176
+ * Converts a ValueExtractorLike to a ValueExtractorFunction.
177
+ * @param v The value extractor to convert.
178
+ * @returns A function that extracts the desired value.
179
+ */
180
+ declare function ValueExtractorAttribute(v: ValueExtractorLike): ValueExtractor;
181
+
117
182
  /**
118
183
  * An implementation of DataSource that uses an array as the data source.
119
184
  * This is useful for static data or when you want to manage the data manually.
120
185
  */
121
- declare class ArrayDataSource extends DataSource {
186
+ declare class LocalDataSource extends DataSource {
122
187
  private items;
123
- private _insertSubject;
124
- private _updateSubject;
125
- private _removeSubject;
126
- readonly inserted: rxjs.Observable<{
127
- items: any[];
128
- }>;
129
- readonly removed: rxjs.Observable<{
130
- item: any;
131
- index: number;
132
- }>;
133
- readonly updated: rxjs.Observable<{
134
- item: any;
135
- index: number;
136
- }>;
188
+ readonly type = "local";
189
+ valueExtractor: (initialValue: ValueExtractor, options?: _angular_core.CreateSignalOptions<ValueExtractor> | undefined) => _angular_core.WritableSignal<ValueExtractor>;
137
190
  constructor(items: any[]);
138
191
  load(request: DataRequest): rxjs.Observable<DataResult<any>>;
139
- remove(item: any): void;
140
- insert(...items: any[]): void;
192
+ remove(index: any): void;
193
+ insert(index: number, ...items: any[]): void;
194
+ push(...items: any[]): void;
195
+ replace(index: number, newValue: any): void;
196
+ }
197
+
198
+ /**
199
+ * Abstract base class for data sources.
200
+ * This class provides a common interface for loading data from various sources.
201
+ */
202
+ declare abstract class DataSource<T = any> {
203
+ abstract readonly type: 'local' | 'remote';
204
+ protected changeSubject: Subject<DataSourceChangeEvent>;
205
+ protected loading: _angular_core.WritableSignal<boolean>;
206
+ /**
207
+ *
208
+ */
209
+ readonly change: Observable<DataSourceChangeEvent>;
210
+ /**
211
+ * Indicates whether the data source is currently loading data.
212
+ */
213
+ isLoading: _angular_core.Signal<boolean>;
214
+ /**
215
+ * Loads data from the data source.
216
+ * @param request The data request object containing pagination, sorting, and filtering information.
217
+ */
218
+ abstract load(request: DataRequest): Observable<DataResult>;
219
+ /**
220
+ * Creates a LocalDataSource from enum values.
221
+ * @param enumClass The enum class to extract values from.
222
+ * @returns A LocalDataSource containing the enum values.
223
+ */
224
+ static fromEnum(enumClass: Record<string, string | number>): LocalDataSource;
141
225
  }
142
226
 
143
227
  declare function toDataResult<T = any>(dr: DataRequest): (source: Observable<any>) => Observable<DataResult<T>>;
144
228
 
145
229
  /**
146
- * DataSourceLike is a type that can be used to represent any data source
147
- * that can be used with the table, autocomplete, dropdown and any component that requires data.
148
- * It can be an array of data, a function that returns an observable of data,
149
- * or an instance of DataSource.
230
+ * A comparison function type that defines an ordering relation between two values.
231
+ * @param a The first value to compare.
232
+ * @param b The second value to compare.
233
+ * @returns
234
+ * - A negative number if `a` should come before `b`
235
+ * - A positive number if `a` should come after `b`
236
+ * - Zero if `a` and `b` are considered equal
150
237
  */
151
- type DataSourceLike<T = any> = Array<any> | DataLoader<T> | DataSource<T> | undefined | null;
238
+ type ValueComparer = (a: any, b: any) => number;
152
239
  /**
153
- * Converts a data source like an array, function, or DataSource into a DataSource instance.
154
- * @param source The data source to convert.
155
- * @returns A DataSource instance.
240
+ * Value comparer can be a function or a string representing the property name to compare.
156
241
  */
157
- declare function convertToDataSource<T>(source: DataSourceLike): DataSource<T>;
242
+ type ValueComparerLike = ValueComparer | string;
158
243
  /**
159
- * LogicalOperator is a list of predefined logical operators that can be used in data requests to filter data.
244
+ * Default value comparer function.
245
+ * @param a
246
+ * @param b
247
+ * @returns -1 if a < b, 1 if a > b, 0 if a === b
160
248
  */
161
- type LogicalOperator = 'contains' | 'endsWith' | 'startsWith' | 'like' | 'eq' | 'ne' | 'gt' | 'gte' | 'lt' | 'lte';
249
+ declare function defaultValueComparer(a: any, b: any): number;
250
+ /**
251
+ * Converts a ValueComparerLike to a ValueComparerFunction.
252
+ * @param v The value comparer to convert.
253
+ * @returns A function that compares two values.
254
+ */
255
+ declare function ValueComparerAttribute(v: ValueComparerLike): ValueComparer;
256
+
257
+ /**
258
+ * Filter predicate function type.
259
+ * @param item The item to test against the filter.
260
+ * @param params Additional parameters to pass to the filter function.
261
+ * @returns True if the item matches the filter, false otherwise.
262
+ */
263
+ type FilterPredicate = (item: any, ...params: any[]) => boolean;
264
+ /**
265
+ * Filter predicate can be a function or a string representing the property name to filter.
266
+ */
267
+ type FilterPredicateLike = FilterPredicate | string;
268
+ /**
269
+ * A filter predicate that checks if a string contains the filter criteria (case insensitive).
270
+ * @param item The item to test against the filter.
271
+ * @param criteria The filter criteria.
272
+ * @returns True if the item matches the filter, false otherwise.
273
+ */
274
+ declare const stringFilter: FilterPredicate;
275
+ /**
276
+ * Converts a FilterPredicateLike to a FilterPredicate function.
277
+ * If the input is a string, it creates a predicate that checks the property with that name.
278
+ * @param v The FilterPredicateLike to convert.
279
+ * @returns The corresponding FilterPredicate function.
280
+ */
281
+ declare function FilterPredicateAttribute(v: FilterPredicateLike): FilterPredicate;
162
282
 
163
- export { ArrayDataSource, AsyncDataSource, DataRequest, DataResult, DataSource, convertToDataSource, toDataResult };
164
- export type { DataLoader, DataRequestFilter, DataRequestPage, DataRequestSort, DataSourceLike, LogicalOperator };
283
+ export { BooleanValueComparerAttribute, DataRequest, DataResult, DataSource, FilterPredicateAttribute, LocalDataSource, RemoteDataSource, ValueComparerAttribute, ValueExtractorAttribute, dataSourceAttribute, defaultBooleanValueComparer, defaultValueComparer, defaultValueExtractor, stringFilter, toDataResult };
284
+ export type { BooleanValueComparer, BooleanValueComparerLike, DataLoader, DataRequestFilter, DataRequestPage, DataRequestSort, DataSourceChange, DataSourceChangeEvent, DataSourceItemInsert, DataSourceItemRemove, DataSourceItemReplace, DataSourceLike, FilterPredicate, FilterPredicateLike, LogicalOperator, ValueComparer, ValueComparerLike, ValueExtractor, ValueExtractorLike };
@@ -53,9 +53,59 @@ function toObservable(value) {
53
53
  }
54
54
  }
55
55
 
56
+ /**
57
+ * Creates an array of numbers within a specified range.
58
+ * @param start The starting number of the range (inclusive).
59
+ * @param end The ending number of the range (inclusive).
60
+ * @returns An array of numbers within the specified range.
61
+ */
62
+ function numberArray(start, end) {
63
+ return Array.from({ length: end - start + 1 }, (_, i) => i + start);
64
+ }
65
+
66
+ function getEnumValues(enumClass) {
67
+ return Object.keys(enumClass)
68
+ .filter(k => isNaN(Number(k))) // remove reverse-mapping keys
69
+ .map(k => enumClass[k]);
70
+ }
71
+ ;
72
+
73
+ let _idCounter = 0;
74
+ class _IdGenerator {
75
+ static _idCounter = 0;
76
+ static next() {
77
+ return _IdGenerator._idCounter++;
78
+ }
79
+ }
80
+ /**
81
+ * Creates a sequential ID generator function with an optional prefix.
82
+ * @param prefix Optional prefix for the generated IDs.
83
+ * @returns A function that generates sequential IDs with the given prefix.
84
+ */
85
+ function sequentialIdGenerator(prefix) {
86
+ return (item) => `${prefix || ''}${_idCounter++}`;
87
+ }
88
+
89
+ /**
90
+ * Converts a CssClassLike to a CssClassGetter function.
91
+ * @param v The CssClassLike to convert.
92
+ * @returns A function that returns the desired CSS class.
93
+ */
94
+ function CssClassAttribute(v) {
95
+ if (typeof v === 'function')
96
+ return v;
97
+ if (typeof v === 'string') {
98
+ return (item) => v;
99
+ }
100
+ else if (v === undefined || v === null) {
101
+ return (item) => undefined;
102
+ }
103
+ throw Error('invalid css class getter');
104
+ }
105
+
56
106
  /**
57
107
  * Generated bundle index. Do not edit.
58
108
  */
59
109
 
60
- export { RTL, flipPlacement, formatString, toObservable };
110
+ export { CssClassAttribute, RTL, _IdGenerator, flipPlacement, formatString, getEnumValues, numberArray, sequentialIdGenerator, toObservable };
61
111
  //# sourceMappingURL=bootkit-ng0-common.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"bootkit-ng0-common.mjs","sources":["../../../projects/ng0/common/types.ts","../../../projects/ng0/common/utils.ts","../../../projects/ng0/common/string-utils.ts","../../../projects/ng0/common/rxjs-utils.ts","../../../projects/ng0/common/bootkit-ng0-common.ts"],"sourcesContent":["import { InjectionToken } from \"@angular/core\";\n\nexport type Placement = 'start' | 'end' | 'top' | 'bottom';\nexport type Alignment = 'start' | 'center' | 'end';\nexport const RTL = new InjectionToken<boolean>('RTL Direction');","import { Placement } from \"./types\";\n\n/**\n * Flips the placement direction.\n * @param placement The placement direction to flip.\n * @returns The flipped placement direction.\n */\nexport function flipPlacement(placement: Placement) {\n switch (placement) {\n case 'bottom':\n return 'top'\n case 'top':\n return 'bottom'\n case 'start':\n return 'end'\n case 'end':\n return 'start'\n }\n}\n","/**\n * Formats a string by replacing placeholders with the provided arguments.\n * @param str The string to format, containing placeholders in the form of {0}, {1}, etc.\n * @param args The values to replace the placeholders with.\n * @returns The formatted string.\n */\nexport function formatString(str: string, ...args: any[]) {\n return str.replace(/\\{(\\d+)\\}/g, function (match, index) {\n return args[index];\n });\n}\n","import { from, Observable, of } from 'rxjs';\n\n/**\n * Converts a value to an Observable.\n * If the value is already an Observable, it returns it directly.\n * If the value is a Promise, it converts it to an Observable.\n * If the value is neither, it wraps it in an Observable using `of`.\n * @param value The value to convert.\n * @returns An Observable that emits the value.\n */\nexport function toObservable<T>(value: T | Observable<T> | Promise<T>): Observable<T> {\n if (value instanceof Observable) {\n return value;\n } else if (value instanceof Promise) {\n return from(value);\n } else {\n return of(value);\n }\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;MAIa,GAAG,GAAG,IAAI,cAAc,CAAU,eAAe;;ACF9D;;;;AAIG;AACG,SAAU,aAAa,CAAC,SAAoB,EAAA;IAC9C,QAAQ,SAAS;AACb,QAAA,KAAK,QAAQ;AACT,YAAA,OAAO,KAAK;AAChB,QAAA,KAAK,KAAK;AACN,YAAA,OAAO,QAAQ;AACnB,QAAA,KAAK,OAAO;AACR,YAAA,OAAO,KAAK;AAChB,QAAA,KAAK,KAAK;AACN,YAAA,OAAO,OAAO;;AAE1B;;AClBA;;;;;AAKG;SACa,YAAY,CAAC,GAAW,EAAE,GAAG,IAAW,EAAA;IACpD,OAAO,GAAG,CAAC,OAAO,CAAC,YAAY,EAAE,UAAU,KAAK,EAAE,KAAK,EAAA;AACnD,QAAA,OAAO,IAAI,CAAC,KAAK,CAAC;AACtB,KAAC,CAAC;AACN;;ACRA;;;;;;;AAOG;AACG,SAAU,YAAY,CAAI,KAAqC,EAAA;AACjE,IAAA,IAAI,KAAK,YAAY,UAAU,EAAE;AAC7B,QAAA,OAAO,KAAK;;AACT,SAAA,IAAI,KAAK,YAAY,OAAO,EAAE;AACjC,QAAA,OAAO,IAAI,CAAC,KAAK,CAAC;;SACf;AACH,QAAA,OAAO,EAAE,CAAC,KAAK,CAAC;;AAExB;;AClBA;;AAEG;;;;"}
1
+ {"version":3,"file":"bootkit-ng0-common.mjs","sources":["../../../projects/ng0/common/types.ts","../../../projects/ng0/common/layout.ts","../../../projects/ng0/common/string-utils.ts","../../../projects/ng0/common/rxjs-utils.ts","../../../projects/ng0/common/array-utils.ts","../../../projects/ng0/common/enum.ts","../../../projects/ng0/common/id-generator.ts","../../../projects/ng0/common/css-class.ts","../../../projects/ng0/common/bootkit-ng0-common.ts"],"sourcesContent":["import { InjectionToken } from \"@angular/core\";\r\n\r\nexport const RTL = new InjectionToken<boolean>('RTL Direction');\r\n\r\n/**\r\n * List item interface.\r\n */\r\nexport interface SelectOption {\r\n id: string,\r\n value: any,\r\n show?: boolean,\r\n}\r\n\r\n\r\n","export type Placement = 'start' | 'end' | 'top' | 'bottom';\r\nexport type Alignment = 'start' | 'center' | 'end';\r\n\r\n/**\r\n * Flips the placement direction.\r\n * @param placement The placement direction to flip.\r\n * @returns The flipped placement direction.\r\n */\r\nexport function flipPlacement(placement: Placement) {\r\n switch (placement) {\r\n case 'bottom':\r\n return 'top'\r\n case 'top':\r\n return 'bottom'\r\n case 'start':\r\n return 'end'\r\n case 'end':\r\n return 'start'\r\n }\r\n}\r\n\r\n\r\n","/**\r\n * Formats a string by replacing placeholders with the provided arguments.\r\n * @param str The string to format, containing placeholders in the form of {0}, {1}, etc.\r\n * @param args The values to replace the placeholders with.\r\n * @returns The formatted string.\r\n */\r\nexport function formatString(str: string, ...args: any[]) {\r\n return str.replace(/\\{(\\d+)\\}/g, function (match, index) {\r\n return args[index];\r\n });\r\n}\r\n","import { from, Observable, of } from 'rxjs';\r\n\r\n/**\r\n * Converts a value to an Observable.\r\n * If the value is already an Observable, it returns it directly.\r\n * If the value is a Promise, it converts it to an Observable.\r\n * If the value is neither, it wraps it in an Observable using `of`.\r\n * @param value The value to convert.\r\n * @returns An Observable that emits the value.\r\n */\r\nexport function toObservable<T>(value: T | Observable<T> | Promise<T>): Observable<T> {\r\n if (value instanceof Observable) {\r\n return value;\r\n } else if (value instanceof Promise) {\r\n return from(value);\r\n } else {\r\n return of(value);\r\n }\r\n}\r\n","/**\r\n * Creates an array of numbers within a specified range.\r\n * @param start The starting number of the range (inclusive).\r\n * @param end The ending number of the range (inclusive).\r\n * @returns An array of numbers within the specified range.\r\n */\r\nexport function numberArray(start: number, end: number) {\r\n return Array.from({ length: end - start + 1 }, (_, i) => i + start)\r\n}","\r\nexport function getEnumValues(enumClass: Record<string, string | number>): Array<string | number> {\r\n return Object.keys(enumClass)\r\n .filter(k => isNaN(Number(k))) // remove reverse-mapping keys\r\n .map(k => enumClass[k]);\r\n};\r\n","let _idCounter = 0;\r\n\r\nexport abstract class _IdGenerator {\r\n private static _idCounter = 0;\r\n\r\n public static next(): number {\r\n return _IdGenerator._idCounter++;\r\n }\r\n}\r\n\r\n/**\r\n * Type definition for an ID generator function.\r\n */\r\nexport type IdGenerator = (param?: any) => string;\r\n\r\n/**\r\n * Creates a sequential ID generator function with an optional prefix.\r\n * @param prefix Optional prefix for the generated IDs.\r\n * @returns A function that generates sequential IDs with the given prefix.\r\n */\r\nexport function sequentialIdGenerator(prefix?: string): IdGenerator {\r\n return (item?: any) => `${prefix || ''}${_idCounter++}`;\r\n}\r\n","/**\r\n * CSS class type which can be a string, array of strings, set of strings, or an object with class names as keys.\r\n */\r\nexport type CssClass = string | string[] | Set<string> | { [klass: string]: any } | null | undefined;\r\n\r\n\r\n/**\r\n * A function that takes an item and returns a CssClass.\r\n * @param item The item to get the CSS class for.\r\n * @returns The CSS class for the item.\r\n */\r\nexport type CssClassGetter = (item: any) => CssClass;\r\n\r\n/**\r\n * A type that represents a CSS class or a function that returns a CSS class.\r\n */\r\nexport type CssClassLike = CssClass | CssClassGetter | null | undefined;\r\n\r\n\r\n/**\r\n * Converts a CssClassLike to a CssClassGetter function.\r\n * @param v The CssClassLike to convert.\r\n * @returns A function that returns the desired CSS class.\r\n */\r\nexport function CssClassAttribute(v: CssClassLike): CssClassGetter {\r\n if (typeof v === 'function')\r\n return v as CssClassGetter;\r\n if (typeof v === 'string') {\r\n return (item: any) => v;\r\n } else if (v === undefined || v === null) {\r\n return (item: any) => undefined;\r\n }\r\n\r\n throw Error('invalid css class getter');\r\n}\r\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;MAEa,GAAG,GAAG,IAAI,cAAc,CAAU,eAAe;;ACC9D;;;;AAIG;AACG,SAAU,aAAa,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AEI,YAAY,CAAA;AACtB,IAAA,OAAO,UAAU,GAAG,CAAC;AAEtB,IAAA,OAAO,IAAI,GAAA;AACd,QAAA,OAAO,YAAY,CAAC,UAAU,EAAE;IACpC;;AAQJ;;;;AAIG;AACG,SAAU,qBAAqB,CAAC,MAAe,EAAA;AACjD,IAAA,OAAO,CAAC,IAAU,KAAK,CAAA,EAAG,MAAM,IAAI,EAAE,CAAA,EAAG,UAAU,EAAE,EAAE;AAC3D;;ACHA;;;;AAIG;AACG,SAAU,iBAAiB,CAAC,CAAe,EAAA;IAC7C,IAAI,OAAO,CAAC,KAAK,UAAU;AACvB,QAAA,OAAO,CAAmB;AAC9B,IAAA,IAAI,OAAO,CAAC,KAAK,QAAQ,EAAE;AACvB,QAAA,OAAO,CAAC,IAAS,KAAK,CAAC;IAC3B;SAAO,IAAI,CAAC,KAAK,SAAS,IAAI,CAAC,KAAK,IAAI,EAAE;AACtC,QAAA,OAAO,CAAC,IAAS,KAAK,SAAS;IACnC;AAEA,IAAA,MAAM,KAAK,CAAC,0BAA0B,CAAC;AAC3C;;AClCA;;AAEG;;;;"}
@@ -6,8 +6,8 @@ class AccordionItemComponent {
6
6
  _element;
7
7
  _renderer;
8
8
  _accordion;
9
- header = input();
10
- collapsed = model(true);
9
+ header = input(...(ngDevMode ? [undefined, { debugName: "header" }] : []));
10
+ collapsed = model(true, ...(ngDevMode ? [{ debugName: "collapsed" }] : []));
11
11
  constructor(_element, _renderer, _accordion) {
12
12
  this._element = _element;
13
13
  this._renderer = _renderer;
@@ -22,31 +22,31 @@ class AccordionItemComponent {
22
22
  }
23
23
  }, { allowSignalWrites: true });
24
24
  }
25
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.0.6", ngImport: i0, type: AccordionItemComponent, deps: [{ token: i0.ElementRef }, { token: i0.Renderer2 }, { token: AccordionComponent }], target: i0.ɵɵFactoryTarget.Component });
26
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "20.0.6", type: AccordionItemComponent, isStandalone: true, selector: "ng0-accordion-item", inputs: { header: { classPropertyName: "header", publicName: "header", isSignal: true, isRequired: false, transformFunction: null }, collapsed: { classPropertyName: "collapsed", publicName: "collapsed", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { collapsed: "collapsedChange" }, exportAs: ["ng0AccordionItem"], ngImport: i0, template: "<h6 class=\"accordion-header\">\n <button class=\"accordion-button\" type=\"button\" [class.collapsed]=\"collapsed()\" (click)=\"collapsed.set(!collapsed())\">\n {{header()}}\n </button>\n</h6>\n\n<ng0-collapse [collapsed]=\"collapsed()\">\n <div class=\"accordion-body\">\n <ng-content></ng-content>\n </div>\n</ng0-collapse>", styles: [":host{display:block}\n"], dependencies: [{ kind: "component", type: CollapseComponent, selector: "ng0-collapse", inputs: ["collapsed", "timings"], outputs: ["collapsedChange"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
25
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.2.1", ngImport: i0, type: AccordionItemComponent, deps: [{ token: i0.ElementRef }, { token: i0.Renderer2 }, { token: AccordionComponent }], target: i0.ɵɵFactoryTarget.Component });
26
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "20.2.1", type: AccordionItemComponent, isStandalone: true, selector: "ng0-accordion-item", inputs: { header: { classPropertyName: "header", publicName: "header", isSignal: true, isRequired: false, transformFunction: null }, collapsed: { classPropertyName: "collapsed", publicName: "collapsed", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { collapsed: "collapsedChange" }, exportAs: ["ng0AccordionItem"], ngImport: i0, template: "<h6 class=\"accordion-header\">\r\n <button class=\"accordion-button\" type=\"button\" [class.collapsed]=\"collapsed()\" (click)=\"collapsed.set(!collapsed())\">\r\n {{header()}}\r\n </button>\r\n</h6>\r\n\r\n<ng0-collapse [collapsed]=\"collapsed()\">\r\n <div class=\"accordion-body\">\r\n <ng-content></ng-content>\r\n </div>\r\n</ng0-collapse>", styles: [":host{display:block}\n"], dependencies: [{ kind: "component", type: CollapseComponent, selector: "ng0-collapse", inputs: ["collapsed", "timings"], outputs: ["collapsedChange"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
27
27
  }
28
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.6", ngImport: i0, type: AccordionItemComponent, decorators: [{
28
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.2.1", ngImport: i0, type: AccordionItemComponent, decorators: [{
29
29
  type: Component,
30
30
  args: [{ selector: 'ng0-accordion-item', exportAs: 'ng0AccordionItem', standalone: true, changeDetection: ChangeDetectionStrategy.OnPush, imports: [
31
31
  CollapseComponent
32
- ], template: "<h6 class=\"accordion-header\">\n <button class=\"accordion-button\" type=\"button\" [class.collapsed]=\"collapsed()\" (click)=\"collapsed.set(!collapsed())\">\n {{header()}}\n </button>\n</h6>\n\n<ng0-collapse [collapsed]=\"collapsed()\">\n <div class=\"accordion-body\">\n <ng-content></ng-content>\n </div>\n</ng0-collapse>", styles: [":host{display:block}\n"] }]
32
+ ], template: "<h6 class=\"accordion-header\">\r\n <button class=\"accordion-button\" type=\"button\" [class.collapsed]=\"collapsed()\" (click)=\"collapsed.set(!collapsed())\">\r\n {{header()}}\r\n </button>\r\n</h6>\r\n\r\n<ng0-collapse [collapsed]=\"collapsed()\">\r\n <div class=\"accordion-body\">\r\n <ng-content></ng-content>\r\n </div>\r\n</ng0-collapse>", styles: [":host{display:block}\n"] }]
33
33
  }], ctorParameters: () => [{ type: i0.ElementRef }, { type: i0.Renderer2 }, { type: AccordionComponent }] });
34
34
 
35
35
  class AccordionComponent {
36
36
  _element;
37
37
  _renderer;
38
38
  /** Items open mode */
39
- mode = input('single');
39
+ mode = input('single', ...(ngDevMode ? [{ debugName: "mode" }] : []));
40
40
  items;
41
41
  constructor(_element, _renderer) {
42
42
  this._element = _element;
43
43
  this._renderer = _renderer;
44
44
  this._renderer.addClass(this._element.nativeElement, 'accordion');
45
45
  }
46
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.0.6", ngImport: i0, type: AccordionComponent, deps: [{ token: i0.ElementRef }, { token: i0.Renderer2 }], target: i0.ɵɵFactoryTarget.Component });
47
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "20.0.6", type: AccordionComponent, isStandalone: true, selector: "ng0-accordion", inputs: { mode: { classPropertyName: "mode", publicName: "mode", isSignal: true, isRequired: false, transformFunction: null } }, queries: [{ propertyName: "items", predicate: AccordionItemComponent }], exportAs: ["ng0Accordion"], ngImport: i0, template: "<ng-content></ng-content>", styles: [":host{display:block}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush });
46
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.2.1", ngImport: i0, type: AccordionComponent, deps: [{ token: i0.ElementRef }, { token: i0.Renderer2 }], target: i0.ɵɵFactoryTarget.Component });
47
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "20.2.1", type: AccordionComponent, isStandalone: true, selector: "ng0-accordion", inputs: { mode: { classPropertyName: "mode", publicName: "mode", isSignal: true, isRequired: false, transformFunction: null } }, queries: [{ propertyName: "items", predicate: AccordionItemComponent }], exportAs: ["ng0Accordion"], ngImport: i0, template: "<ng-content></ng-content>", styles: [":host{display:block}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush });
48
48
  }
49
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.6", ngImport: i0, type: AccordionComponent, decorators: [{
49
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.2.1", ngImport: i0, type: AccordionComponent, decorators: [{
50
50
  type: Component,
51
51
  args: [{ selector: 'ng0-accordion', exportAs: 'ng0Accordion', standalone: true, changeDetection: ChangeDetectionStrategy.OnPush, template: "<ng-content></ng-content>", styles: [":host{display:block}\n"] }]
52
52
  }], ctorParameters: () => [{ type: i0.ElementRef }, { type: i0.Renderer2 }], propDecorators: { items: [{
@@ -55,13 +55,13 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.6", ngImpor
55
55
  }] } });
56
56
 
57
57
  class AccordionModule {
58
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.0.6", ngImport: i0, type: AccordionModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
59
- static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "20.0.6", ngImport: i0, type: AccordionModule, imports: [AccordionComponent,
58
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.2.1", ngImport: i0, type: AccordionModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
59
+ static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "20.2.1", ngImport: i0, type: AccordionModule, imports: [AccordionComponent,
60
60
  AccordionItemComponent], exports: [AccordionComponent,
61
61
  AccordionItemComponent] });
62
- static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "20.0.6", ngImport: i0, type: AccordionModule, imports: [AccordionItemComponent] });
62
+ static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "20.2.1", ngImport: i0, type: AccordionModule, imports: [AccordionItemComponent] });
63
63
  }
64
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.6", ngImport: i0, type: AccordionModule, decorators: [{
64
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.2.1", ngImport: i0, type: AccordionModule, decorators: [{
65
65
  type: NgModule,
66
66
  args: [{
67
67
  imports: [
@@ -1 +1 @@
1
- {"version":3,"file":"bootkit-ng0-components-accordion.mjs","sources":["../../../projects/ng0/components/accordion/accordion-item.component.ts","../../../projects/ng0/components/accordion/accordion-item.component.html","../../../projects/ng0/components/accordion/accordion.component.ts","../../../projects/ng0/components/accordion/accordion.component.html","../../../projects/ng0/components/accordion/accordion.module.ts","../../../projects/ng0/components/accordion/bootkit-ng0-components-accordion.ts"],"sourcesContent":["import { ChangeDetectionStrategy, Component, effect, ElementRef, input, model, Renderer2 } from '@angular/core';\nimport { CollapseComponent } from '@bootkit/ng0/components/collapse';\nimport { AccordionComponent } from './accordion.component';\n\n@Component({\n selector: 'ng0-accordion-item',\n exportAs: 'ng0AccordionItem',\n templateUrl: './accordion-item.component.html',\n standalone: true,\n changeDetection: ChangeDetectionStrategy.OnPush,\n styles: `:host {display: block;}`,\n imports: [\n CollapseComponent\n ]\n})\nexport class AccordionItemComponent {\n public header = input<string>();\n public collapsed = model(true);\n\n constructor(private _element: ElementRef, private _renderer: Renderer2, private _accordion: AccordionComponent) {\n this._renderer.addClass(this._element.nativeElement, 'accordion-item');\n\n effect(() => {\n var collapsed = this.collapsed();\n \n if(_accordion.mode() == 'single') {\n if(!collapsed) {\n this._accordion.items.filter(x => x !== this).forEach(x => x.collapsed.update(x => true));\n }\n }\n }, {allowSignalWrites: true})\n }\n}\n","<h6 class=\"accordion-header\">\n <button class=\"accordion-button\" type=\"button\" [class.collapsed]=\"collapsed()\" (click)=\"collapsed.set(!collapsed())\">\n {{header()}}\n </button>\n</h6>\n\n<ng0-collapse [collapsed]=\"collapsed()\">\n <div class=\"accordion-body\">\n <ng-content></ng-content>\n </div>\n</ng0-collapse>","import { ChangeDetectionStrategy, Component, ContentChildren, ElementRef, input, QueryList, Renderer2 } from '@angular/core';\nimport { AccordionItemComponent } from './accordion-item.component';\n\n@Component({\n selector: 'ng0-accordion',\n exportAs: 'ng0Accordion',\n templateUrl: './accordion.component.html',\n standalone: true,\n changeDetection: ChangeDetectionStrategy.OnPush,\n styles: `:host {display: block;}`\n})\nexport class AccordionComponent {\n /** Items open mode */\n public mode = input<'single' | 'multiple'>('single');\n\n @ContentChildren(AccordionItemComponent)\n public readonly items!: QueryList<AccordionItemComponent>;\n\n constructor(private _element: ElementRef, private _renderer: Renderer2) {\n this._renderer.addClass(this._element.nativeElement, 'accordion');\n }\n}\n","<ng-content></ng-content>","import { NgModule } from '@angular/core';\nimport { AccordionComponent } from './accordion.component';\nimport { AccordionItemComponent } from './accordion-item.component';\n\n@NgModule({\n imports: [\n AccordionComponent,\n AccordionItemComponent,\n ],\n exports: [\n AccordionComponent,\n AccordionItemComponent,\n ]\n})\nexport class AccordionModule {\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":["i1.AccordionComponent"],"mappings":";;;;MAea,sBAAsB,CAAA;AAIX,IAAA,QAAA;AAA8B,IAAA,SAAA;AAA8B,IAAA,UAAA;IAHzE,MAAM,GAAG,KAAK,EAAU;AACxB,IAAA,SAAS,GAAG,KAAK,CAAC,IAAI,CAAC;AAE9B,IAAA,WAAA,CAAoB,QAAoB,EAAU,SAAoB,EAAU,UAA8B,EAAA;QAA1F,IAAQ,CAAA,QAAA,GAAR,QAAQ;QAAsB,IAAS,CAAA,SAAA,GAAT,SAAS;QAAqB,IAAU,CAAA,UAAA,GAAV,UAAU;AACtF,QAAA,IAAI,CAAC,SAAS,CAAC,QAAQ,CAAC,IAAI,CAAC,QAAQ,CAAC,aAAa,EAAE,gBAAgB,CAAC;QAEtE,MAAM,CAAC,MAAK;AACR,YAAA,IAAI,SAAS,GAAG,IAAI,CAAC,SAAS,EAAE;AAEhC,YAAA,IAAG,UAAU,CAAC,IAAI,EAAE,IAAI,QAAQ,EAAE;gBAC9B,IAAG,CAAC,SAAS,EAAE;AACX,oBAAA,IAAI,CAAC,UAAU,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC,IAAI,CAAC,KAAK,IAAI,CAAC,CAAC,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS,CAAC,MAAM,CAAC,CAAC,IAAI,IAAI,CAAC,CAAC;;;AAGrG,SAAC,EAAE,EAAC,iBAAiB,EAAE,IAAI,EAAC,CAAC;;uGAfxB,sBAAsB,EAAA,IAAA,EAAA,CAAA,EAAA,KAAA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ACC,eAAA,EAAA,uBAAuB,CAAC,MAAM,EAAA,QAAA,EAAA,2BAAA,EAAA,MAAA,EAAA,CAAA,wBAAA,CAAA,EAAA;uGAQ/B,KAAK,EAAA,CAAA;sBADpB,eAAe;uBAAC,sBAAsB;;;MED9B,eAAe,CAAA;uGAAf,eAAe,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA;AAAf,IAAA,OAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,eAAe,YARpB,kBAAkB;AAClB,YAAA,sBAAsB,aAGtB,kBAAkB;YAClB,sBAAsB,CAAA,EAAA,CAAA;AAGjB,IAAA,OAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,eAAe,YAPpB,sBAAsB,CAAA,EAAA,CAAA;;2FAOjB,eAAe,EAAA,UAAA,EAAA,CAAA;kBAV3B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACN,oBAAA,OAAO,EAAE;wBACL,kBAAkB;wBAClB,sBAAsB;AACzB,qBAAA;AACD,oBAAA,OAAO,EAAE;wBACL,kBAAkB;wBAClB,sBAAsB;AACzB;AACJ,iBAAA;;;ACbD;;AAEG;;;;"}
1
+ {"version":3,"file":"bootkit-ng0-components-accordion.mjs","sources":["../../../projects/ng0/components/accordion/accordion-item.component.ts","../../../projects/ng0/components/accordion/accordion-item.component.html","../../../projects/ng0/components/accordion/accordion.component.ts","../../../projects/ng0/components/accordion/accordion.component.html","../../../projects/ng0/components/accordion/accordion.module.ts","../../../projects/ng0/components/accordion/bootkit-ng0-components-accordion.ts"],"sourcesContent":["import { ChangeDetectionStrategy, Component, effect, ElementRef, input, model, Renderer2 } from '@angular/core';\r\nimport { CollapseComponent } from '@bootkit/ng0/components/collapse';\r\nimport { AccordionComponent } from './accordion.component';\r\n\r\n@Component({\r\n selector: 'ng0-accordion-item',\r\n exportAs: 'ng0AccordionItem',\r\n templateUrl: './accordion-item.component.html',\r\n standalone: true,\r\n changeDetection: ChangeDetectionStrategy.OnPush,\r\n styles: `:host {display: block;}`,\r\n imports: [\r\n CollapseComponent\r\n ]\r\n})\r\nexport class AccordionItemComponent {\r\n public header = input<string>();\r\n public collapsed = model(true);\r\n\r\n constructor(private _element: ElementRef, private _renderer: Renderer2, private _accordion: AccordionComponent) {\r\n this._renderer.addClass(this._element.nativeElement, 'accordion-item');\r\n\r\n effect(() => {\r\n var collapsed = this.collapsed();\r\n \r\n if(_accordion.mode() == 'single') {\r\n if(!collapsed) {\r\n this._accordion.items.filter(x => x !== this).forEach(x => x.collapsed.update(x => true));\r\n }\r\n }\r\n }, {allowSignalWrites: true})\r\n }\r\n}\r\n","<h6 class=\"accordion-header\">\r\n <button class=\"accordion-button\" type=\"button\" [class.collapsed]=\"collapsed()\" (click)=\"collapsed.set(!collapsed())\">\r\n {{header()}}\r\n </button>\r\n</h6>\r\n\r\n<ng0-collapse [collapsed]=\"collapsed()\">\r\n <div class=\"accordion-body\">\r\n <ng-content></ng-content>\r\n </div>\r\n</ng0-collapse>","import { ChangeDetectionStrategy, Component, ContentChildren, ElementRef, input, QueryList, Renderer2 } from '@angular/core';\r\nimport { AccordionItemComponent } from './accordion-item.component';\r\n\r\n@Component({\r\n selector: 'ng0-accordion',\r\n exportAs: 'ng0Accordion',\r\n templateUrl: './accordion.component.html',\r\n standalone: true,\r\n changeDetection: ChangeDetectionStrategy.OnPush,\r\n styles: `:host {display: block;}`\r\n})\r\nexport class AccordionComponent {\r\n /** Items open mode */\r\n public mode = input<'single' | 'multiple'>('single');\r\n\r\n @ContentChildren(AccordionItemComponent)\r\n public readonly items!: QueryList<AccordionItemComponent>;\r\n\r\n constructor(private _element: ElementRef, private _renderer: Renderer2) {\r\n this._renderer.addClass(this._element.nativeElement, 'accordion');\r\n }\r\n}\r\n","<ng-content></ng-content>","import { NgModule } from '@angular/core';\r\nimport { AccordionComponent } from './accordion.component';\r\nimport { AccordionItemComponent } from './accordion-item.component';\r\n\r\n@NgModule({\r\n imports: [\r\n AccordionComponent,\r\n AccordionItemComponent,\r\n ],\r\n exports: [\r\n AccordionComponent,\r\n AccordionItemComponent,\r\n ]\r\n})\r\nexport class AccordionModule {\r\n}\r\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":["i1.AccordionComponent"],"mappings":";;;;MAea,sBAAsB,CAAA;AAIX,IAAA,QAAA;AAA8B,IAAA,SAAA;AAA8B,IAAA,UAAA;IAHzE,MAAM,GAAG,KAAK,CAAA,IAAA,SAAA,GAAA,CAAA,SAAA,EAAA,EAAA,SAAA,EAAA,QAAA,EAAA,CAAA,GAAA,EAAA,CAAA,CAAU;AACxB,IAAA,SAAS,GAAG,KAAK,CAAC,IAAI,qDAAC;AAE9B,IAAA,WAAA,CAAoB,QAAoB,EAAU,SAAoB,EAAU,UAA8B,EAAA;QAA1F,IAAA,CAAA,QAAQ,GAAR,QAAQ;QAAsB,IAAA,CAAA,SAAS,GAAT,SAAS;QAAqB,IAAA,CAAA,UAAU,GAAV,UAAU;AACtF,QAAA,IAAI,CAAC,SAAS,CAAC,QAAQ,CAAC,IAAI,CAAC,QAAQ,CAAC,aAAa,EAAE,gBAAgB,CAAC;QAEtE,MAAM,CAAC,MAAK;AACR,YAAA,IAAI,SAAS,GAAG,IAAI,CAAC,SAAS,EAAE;AAEhC,YAAA,IAAG,UAAU,CAAC,IAAI,EAAE,IAAI,QAAQ,EAAE;gBAC9B,IAAG,CAAC,SAAS,EAAE;AACX,oBAAA,IAAI,CAAC,UAAU,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC,IAAI,CAAC,KAAK,IAAI,CAAC,CAAC,OAAO,CAAC,CAAC,IAAI,CA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eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,MAAA,EAAA,CAAA;;2FDWZ,kBAAkB,EAAA,UAAA,EAAA,CAAA;kBAR9B,SAAS;AACI,YAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,eAAe,YACf,cAAc,EAAA,UAAA,EAEZ,IAAI,EAAA,eAAA,EACC,uBAAuB,CAAC,MAAM,EAAA,QAAA,EAAA,2BAAA,EAAA,MAAA,EAAA,CAAA,wBAAA,CAAA,EAAA;uGAQ/B,KAAK,EAAA,CAAA;sBADpB,eAAe;uBAAC,sBAAsB;;;MED9B,eAAe,CAAA;uGAAf,eAAe,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA;AAAf,IAAA,OAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,eAAe,YARpB,kBAAkB;AAClB,YAAA,sBAAsB,aAGtB,kBAAkB;YAClB,sBAAsB,CAAA,EAAA,CAAA;AAGjB,IAAA,OAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,eAAe,YAPpB,sBAAsB,CAAA,EAAA,CAAA;;2FAOjB,eAAe,EAAA,UAAA,EAAA,CAAA;kBAV3B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACN,oBAAA,OAAO,EAAE;wBACL,kBAAkB;wBAClB,sBAAsB;AACzB,qBAAA;AACD,oBAAA,OAAO,EAAE;wBACL,kBAAkB;wBAClB,sBAAsB;AACzB;AACJ,iBAAA;;;ACbD;;AAEG;;;;"}
@@ -6,9 +6,9 @@ import { trigger, transition, style, animate } from '@angular/animations';
6
6
  * This component is used to display a backdrop behind another component.
7
7
  */
8
8
  class BackdropComponent {
9
- fixed = signal(false);
10
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.0.6", ngImport: i0, type: BackdropComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
11
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "20.0.6", type: BackdropComponent, isStandalone: true, selector: "ng0-backdrop", host: { properties: { "@fade": "", "class.fixed": "fixed()" } }, ngImport: i0, template: '', isInline: true, styles: [":host{--ng0-backdrop-background: rgba(0, 0, 0, .5);position:absolute;inset:0;background:var(--ng0-backdrop-background)}:host.fixed{position:fixed}\n"], animations: [
9
+ fixed = signal(false, ...(ngDevMode ? [{ debugName: "fixed" }] : []));
10
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.2.1", ngImport: i0, type: BackdropComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
11
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "20.2.1", type: BackdropComponent, isStandalone: true, selector: "ng0-backdrop", host: { properties: { "@fade": "", "class.fixed": "fixed()" } }, ngImport: i0, template: '', isInline: true, styles: [":host{--ng0-backdrop-background: rgba(0, 0, 0, .5);position:absolute;inset:0;background:var(--ng0-backdrop-background)}:host.fixed{position:fixed}\n"], animations: [
12
12
  trigger('fade', [
13
13
  transition(':enter', [
14
14
  style({ opacity: 0 }),
@@ -20,7 +20,7 @@ class BackdropComponent {
20
20
  ]),
21
21
  ], changeDetection: i0.ChangeDetectionStrategy.OnPush });
22
22
  }
23
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.6", ngImport: i0, type: BackdropComponent, decorators: [{
23
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.2.1", ngImport: i0, type: BackdropComponent, decorators: [{
24
24
  type: Component,
25
25
  args: [{ selector: 'ng0-backdrop', template: '', standalone: true, changeDetection: ChangeDetectionStrategy.OnPush, animations: [
26
26
  trigger('fade', [
@@ -1 +1 @@
1
- {"version":3,"file":"bootkit-ng0-components-backdrop.mjs","sources":["../../../projects/ng0/components/backdrop/backdrop.component.ts","../../../projects/ng0/components/backdrop/bootkit-ng0-components-backdrop.ts"],"sourcesContent":["import { ChangeDetectionStrategy, Component, signal } from '@angular/core';\nimport {\n trigger,\n transition,\n style,\n animate,\n} from '@angular/animations';\n\n/**\n * This component is used to display a backdrop behind another component.\n */\n@Component({\n selector: 'ng0-backdrop',\n template: '',\n styleUrl: 'backdrop.component.scss',\n standalone: true,\n changeDetection: ChangeDetectionStrategy.OnPush,\n animations: [\n trigger('fade', [\n transition(':enter', [\n style({ opacity: 0 }),\n animate('150ms ease', style({ opacity: 1 })),\n ]),\n transition(':leave', [\n animate('150ms ease', style({ opacity: 0 })),\n ]),\n ]),\n ],\n host: {\n '[@fade]': '', // Binds the animation trigger to the host\n '[class.fixed]': \"fixed()\"\n }\n})\nexport class BackdropComponent {\n public readonly fixed = signal(false);\n}","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;AAQA;;AAEG;MAuBU,iBAAiB,CAAA;AACZ,IAAA,KAAK,GAAG,MAAM,CAAC,KAAK,CAAC;uGAD1B,iBAAiB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA;2FAAjB,iBAAiB,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,cAAA,EAAA,IAAA,EAAA,EAAA,UAAA,EAAA,EAAA,OAAA,EAAA,EAAA,EAAA,aAAA,EAAA,SAAA,EAAA,EAAA,EAAA,QAAA,EAAA,EAAA,EAAA,QAAA,EApBlB,EAAE,EAIA,QAAA,EAAA,IAAA,EAAA,MAAA,EAAA,CAAA,sJAAA,CAAA,EAAA,UAAA,EAAA;YACV,OAAO,CAAC,MAAM,EAAE;gBACd,UAAU,CAAC,QAAQ,EAAE;AACnB,oBAAA,KAAK,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE,CAAC;oBACrB,OAAO,CAAC,YAAY,EAAE,KAAK,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE,CAAC,CAAC;iBAC7C,CAAC;gBACF,UAAU,CAAC,QAAQ,EAAE;oBACnB,OAAO,CAAC,YAAY,EAAE,KAAK,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE,CAAC,CAAC;iBAC7C,CAAC;aACH,CAAC;AACH,SAAA,EAAA,eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,MAAA,EAAA,CAAA;;2FAMU,iBAAiB,EAAA,UAAA,EAAA,CAAA;kBAtB7B,SAAS;+BACE,cAAc,EAAA,QAAA,EACd,EAAE,EAEA,UAAA,EAAA,IAAI,mBACC,uBAAuB,CAAC,MAAM,EACnC,UAAA,EAAA;wBACV,OAAO,CAAC,MAAM,EAAE;4BACd,UAAU,CAAC,QAAQ,EAAE;AACnB,gCAAA,KAAK,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE,CAAC;gCACrB,OAAO,CAAC,YAAY,EAAE,KAAK,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE,CAAC,CAAC;6BAC7C,CAAC;4BACF,UAAU,CAAC,QAAQ,EAAE;gCACnB,OAAO,CAAC,YAAY,EAAE,KAAK,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE,CAAC,CAAC;6BAC7C,CAAC;yBACH,CAAC;qBACH,EACK,IAAA,EAAA;wBACJ,SAAS,EAAE,EAAE;AACb,wBAAA,eAAe,EAAE;AAClB,qBAAA,EAAA,MAAA,EAAA,CAAA,sJAAA,CAAA,EAAA;;;AC/BH;;AAEG;;;;"}
1
+ {"version":3,"file":"bootkit-ng0-components-backdrop.mjs","sources":["../../../projects/ng0/components/backdrop/backdrop.component.ts","../../../projects/ng0/components/backdrop/bootkit-ng0-components-backdrop.ts"],"sourcesContent":["import { ChangeDetectionStrategy, Component, signal } from '@angular/core';\r\nimport {\r\n trigger,\r\n transition,\r\n style,\r\n animate,\r\n} from '@angular/animations';\r\n\r\n/**\r\n * This component is used to display a backdrop behind another component.\r\n */\r\n@Component({\r\n selector: 'ng0-backdrop',\r\n template: '',\r\n styleUrl: 'backdrop.component.scss',\r\n standalone: true,\r\n changeDetection: ChangeDetectionStrategy.OnPush,\r\n animations: [\r\n trigger('fade', [\r\n transition(':enter', [\r\n style({ opacity: 0 }),\r\n animate('150ms ease', style({ opacity: 1 })),\r\n ]),\r\n transition(':leave', [\r\n animate('150ms ease', style({ opacity: 0 })),\r\n ]),\r\n ]),\r\n ],\r\n host: {\r\n '[@fade]': '', // Binds the animation trigger to the host\r\n '[class.fixed]': \"fixed()\"\r\n }\r\n})\r\nexport class BackdropComponent {\r\n public readonly fixed = signal(false);\r\n}","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;AAQA;;AAEG;MAuBU,iBAAiB,CAAA;AACZ,IAAA,KAAK,GAAG,MAAM,CAAC,KAAK,iDAAC;uGAD1B,iBAAiB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA;2FAAjB,iBAAiB,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,cAAA,EAAA,IAAA,EAAA,EAAA,UAAA,EAAA,EAAA,OAAA,EAAA,EAAA,EAAA,aAAA,EAAA,SAAA,EAAA,EAAA,EAAA,QAAA,EAAA,EAAA,EAAA,QAAA,EApBlB,EAAE,EAAA,QAAA,EAAA,IAAA,EAAA,MAAA,EAAA,CAAA,sJAAA,CAAA,EAAA,UAAA,EAIA;YACV,OAAO,CAAC,MAAM,EAAE;gBACd,UAAU,CAAC,QAAQ,EAAE;AACnB,oBAAA,KAAK,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE,CAAC;oBACrB,OAAO,CAAC,YAAY,EAAE,KAAK,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE,CAAC,CAAC;iBAC7C,CAAC;gBACF,UAAU,CAAC,QAAQ,EAAE;oBACnB,OAAO,CAAC,YAAY,EAAE,KAAK,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE,CAAC,CAAC;iBAC7C,CAAC;aACH,CAAC;AACH,SAAA,EAAA,eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,MAAA,EAAA,CAAA;;2FAMU,iBAAiB,EAAA,UAAA,EAAA,CAAA;kBAtB7B,SAAS;+BACE,cAAc,EAAA,QAAA,EACd,EAAE,EAAA,UAAA,EAEA,IAAI,mBACC,uBAAuB,CAAC,MAAM,EAAA,UAAA,EACnC;wBACV,OAAO,CAAC,MAAM,EAAE;4BACd,UAAU,CAAC,QAAQ,EAAE;AACnB,gCAAA,KAAK,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE,CAAC;gCACrB,OAAO,CAAC,YAAY,EAAE,KAAK,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE,CAAC,CAAC;6BAC7C,CAAC;4BACF,UAAU,CAAC,QAAQ,EAAE;gCACnB,OAAO,CAAC,YAAY,EAAE,KAAK,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE,CAAC,CAAC;6BAC7C,CAAC;yBACH,CAAC;qBACH,EAAA,IAAA,EACK;wBACJ,SAAS,EAAE,EAAE;AACb,wBAAA,eAAe,EAAE;AAClB,qBAAA,EAAA,MAAA,EAAA,CAAA,sJAAA,CAAA,EAAA;;;AC/BH;;AAEG;;;;"}
@@ -13,24 +13,24 @@ class ButtonDirective {
13
13
  * The IDs of the HTTP requests that this button listens to.
14
14
  * If one of these requests is in progress, it will show a loading indicator or will be disabled based on 'showLoading' and 'disableOnLoading' properties.
15
15
  */
16
- request = input(undefined);
16
+ request = input(undefined, ...(ngDevMode ? [{ debugName: "request" }] : []));
17
17
  /**
18
18
  * Whether the button is disabled or not.
19
19
  */
20
- disabled = model(false);
20
+ disabled = model(false, ...(ngDevMode ? [{ debugName: "disabled" }] : []));
21
21
  /**
22
22
  * Whether to wait for the HTTP response before enabling the button again.
23
23
  * If true, the button will remain disabled until the HTTP request completes.
24
24
  * This is useful for preventing multiple clicks while waiting for a response.
25
25
  * Default is true.
26
26
  */
27
- disableDuringRequest = input(true, { transform: booleanAttribute });
27
+ disableDuringRequest = input(true, ...(ngDevMode ? [{ debugName: "disableDuringRequest", transform: booleanAttribute }] : [{ transform: booleanAttribute }]));
28
28
  /**
29
29
  * Whether to show a loading indicator when the HTTP request is in progress.
30
30
  * If true, a loading spinner will be displayed on the button while the request is being processed.
31
31
  * Default is true.
32
32
  */
33
- loadingIndicator = input(false, { transform: booleanAttribute });
33
+ loadingIndicator = input(false, ...(ngDevMode ? [{ debugName: "loadingIndicator", transform: booleanAttribute }] : [{ transform: booleanAttribute }]));
34
34
  constructor(_element, _renderer, _http, _destroyRef) {
35
35
  this._element = _element;
36
36
  this._renderer = _renderer;
@@ -76,10 +76,10 @@ class ButtonDirective {
76
76
  }
77
77
  ngOnDestroy() {
78
78
  }
79
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.0.6", ngImport: i0, type: ButtonDirective, deps: [{ token: i0.ElementRef }, { token: i0.Renderer2 }, { token: i1.HttpService }, { token: i0.DestroyRef }], target: i0.ɵɵFactoryTarget.Directive });
80
- static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "20.0.6", type: ButtonDirective, isStandalone: true, selector: "button[ng0Button], a[ng0Button], input[type=button][ng0Button], input[type=submit][ng0Button], input[type=reset][ng0Button]", inputs: { request: { classPropertyName: "request", publicName: "request", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, disableDuringRequest: { classPropertyName: "disableDuringRequest", publicName: "disableDuringRequest", isSignal: true, isRequired: false, transformFunction: null }, loadingIndicator: { classPropertyName: "loadingIndicator", publicName: "loadingIndicator", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { disabled: "disabledChange" }, host: { properties: { "class.disabled": "disabled()", "prop.disabled": "disabled()", "attr.aria-disabled": "disabled()", "attr.tabindex": "disabled() ? \"-1\" : \"\" " } }, exportAs: ["ng0Button"], ngImport: i0 });
79
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.2.1", ngImport: i0, type: ButtonDirective, deps: [{ token: i0.ElementRef }, { token: i0.Renderer2 }, { token: i1.HttpService }, { token: i0.DestroyRef }], target: i0.ɵɵFactoryTarget.Directive });
80
+ static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "20.2.1", type: ButtonDirective, isStandalone: true, selector: "button[ng0Button], a[ng0Button], input[type=button][ng0Button], input[type=submit][ng0Button], input[type=reset][ng0Button]", inputs: { request: { classPropertyName: "request", publicName: "request", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, disableDuringRequest: { classPropertyName: "disableDuringRequest", publicName: "disableDuringRequest", isSignal: true, isRequired: false, transformFunction: null }, loadingIndicator: { classPropertyName: "loadingIndicator", publicName: "loadingIndicator", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { disabled: "disabledChange" }, host: { properties: { "class.disabled": "disabled()", "prop.disabled": "disabled()", "attr.aria-disabled": "disabled()", "attr.tabindex": "disabled() ? \"-1\" : \"\" " } }, exportAs: ["ng0Button"], ngImport: i0 });
81
81
  }
82
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.6", ngImport: i0, type: ButtonDirective, decorators: [{
82
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.2.1", ngImport: i0, type: ButtonDirective, decorators: [{
83
83
  type: Directive,
84
84
  args: [{
85
85
  selector: 'button[ng0Button], a[ng0Button], input[type=button][ng0Button], input[type=submit][ng0Button], input[type=reset][ng0Button]',
@@ -95,11 +95,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.6", ngImpor
95
95
  }], ctorParameters: () => [{ type: i0.ElementRef }, { type: i0.Renderer2 }, { type: i1.HttpService }, { type: i0.DestroyRef }] });
96
96
 
97
97
  class ButtonModule {
98
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.0.6", ngImport: i0, type: ButtonModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
99
- static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "20.0.6", ngImport: i0, type: ButtonModule, imports: [ButtonDirective], exports: [ButtonDirective] });
100
- static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "20.0.6", ngImport: i0, type: ButtonModule });
98
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.2.1", ngImport: i0, type: ButtonModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
99
+ static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "20.2.1", ngImport: i0, type: ButtonModule, imports: [ButtonDirective], exports: [ButtonDirective] });
100
+ static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "20.2.1", ngImport: i0, type: ButtonModule });
101
101
  }
102
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.6", ngImport: i0, type: ButtonModule, decorators: [{
102
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.2.1", ngImport: i0, type: ButtonModule, decorators: [{
103
103
  type: NgModule,
104
104
  args: [{
105
105
  imports: [