@nexterajs/ui 0.0.2 → 0.1.0

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 (59) hide show
  1. package/README.md +279 -34
  2. package/fesm2022/nexterajs-ui-charts.mjs +1096 -0
  3. package/fesm2022/nexterajs-ui-charts.mjs.map +1 -0
  4. package/fesm2022/nexterajs-ui-core.mjs +652 -12
  5. package/fesm2022/nexterajs-ui-core.mjs.map +1 -1
  6. package/fesm2022/nexterajs-ui-display.mjs +1142 -0
  7. package/fesm2022/nexterajs-ui-display.mjs.map +1 -0
  8. package/fesm2022/nexterajs-ui-dropdowns.mjs +321 -33
  9. package/fesm2022/nexterajs-ui-dropdowns.mjs.map +1 -1
  10. package/fesm2022/nexterajs-ui-file-uploader.mjs +572 -10
  11. package/fesm2022/nexterajs-ui-file-uploader.mjs.map +1 -1
  12. package/fesm2022/nexterajs-ui-forms.mjs +2027 -136
  13. package/fesm2022/nexterajs-ui-forms.mjs.map +1 -1
  14. package/fesm2022/nexterajs-ui-grid.mjs +1222 -188
  15. package/fesm2022/nexterajs-ui-grid.mjs.map +1 -1
  16. package/fesm2022/nexterajs-ui-intl.mjs +103 -11
  17. package/fesm2022/nexterajs-ui-intl.mjs.map +1 -1
  18. package/fesm2022/nexterajs-ui-navigation.mjs +1054 -0
  19. package/fesm2022/nexterajs-ui-navigation.mjs.map +1 -0
  20. package/fesm2022/nexterajs-ui-notify.mjs +46 -44
  21. package/fesm2022/nexterajs-ui-notify.mjs.map +1 -1
  22. package/fesm2022/nexterajs-ui-overlay.mjs +1671 -0
  23. package/fesm2022/nexterajs-ui-overlay.mjs.map +1 -0
  24. package/fesm2022/nexterajs-ui-pivot.mjs +51 -26
  25. package/fesm2022/nexterajs-ui-pivot.mjs.map +1 -1
  26. package/fesm2022/nexterajs-ui-shell.mjs +542 -0
  27. package/fesm2022/nexterajs-ui-shell.mjs.map +1 -0
  28. package/fesm2022/nexterajs-ui-tree-view.mjs +5 -2
  29. package/fesm2022/nexterajs-ui-tree-view.mjs.map +1 -1
  30. package/fesm2022/nexterajs-ui-validation.mjs +42 -11
  31. package/fesm2022/nexterajs-ui-validation.mjs.map +1 -1
  32. package/fesm2022/nexterajs-ui.mjs +5 -0
  33. package/fesm2022/nexterajs-ui.mjs.map +1 -1
  34. package/package.json +33 -2
  35. package/styles/_dropdown.scss +5 -5
  36. package/styles/_editor.scss +52 -17
  37. package/styles/_mixins.scss +1 -1
  38. package/styles/_scrollbar.scss +5 -5
  39. package/styles/_status.scss +21 -0
  40. package/styles/_toast.scss +14 -14
  41. package/styles/_tokens.scss +420 -3
  42. package/styles/_widget.scss +14 -3
  43. package/styles/index.scss +6 -4
  44. package/types/nexterajs-ui-charts.d.ts +446 -0
  45. package/types/nexterajs-ui-core.d.ts +387 -22
  46. package/types/nexterajs-ui-display.d.ts +720 -0
  47. package/types/nexterajs-ui-dropdowns.d.ts +191 -48
  48. package/types/nexterajs-ui-file-uploader.d.ts +236 -7
  49. package/types/nexterajs-ui-forms.d.ts +675 -30
  50. package/types/nexterajs-ui-grid.d.ts +448 -93
  51. package/types/nexterajs-ui-intl.d.ts +39 -4
  52. package/types/nexterajs-ui-navigation.d.ts +531 -0
  53. package/types/nexterajs-ui-notify.d.ts +4 -2
  54. package/types/nexterajs-ui-overlay.d.ts +703 -0
  55. package/types/nexterajs-ui-pivot.d.ts +56 -48
  56. package/types/nexterajs-ui-shell.d.ts +294 -0
  57. package/types/nexterajs-ui-tree-view.d.ts +6 -3
  58. package/types/nexterajs-ui-validation.d.ts +20 -11
  59. package/types/nexterajs-ui.d.ts +5 -0
@@ -1,7 +1,8 @@
1
1
  import * as _angular_core from '@angular/core';
2
- import { InjectionToken, ElementRef, NgZone, TemplateRef } from '@angular/core';
2
+ import { InjectionToken, EnvironmentProviders, ElementRef, NgZone, TemplateRef } from '@angular/core';
3
3
  import * as _nexterajs_ui_core from '@nexterajs/ui/core';
4
4
  import { ControlValueAccessor } from '@angular/forms';
5
+ import { NxeNumberSeparators } from '@nexterajs/ui/intl';
5
6
 
6
7
  /**
7
8
  * DevExtreme-compatible value-change event payload.
@@ -34,6 +35,298 @@ interface NxeEditorEvent {
34
35
  element: HTMLElement;
35
36
  }
36
37
 
38
+ /**
39
+ * Every user-visible string the library renders, in English.
40
+ *
41
+ * Flat keys, namespaced by component (`grid.pager.info`). `{0}`, `{1}`... are positional
42
+ * arguments filled by `NxeMessageService.t(key, ...args)`. English is the default bundle and
43
+ * the fallback for any key a custom bundle leaves out, so the library renders exactly what it
44
+ * always did until an application opts into another locale.
45
+ *
46
+ * The key set is the type: `NxeMessageKey` is derived from it and the Indonesian bundle is
47
+ * checked against it, so a key added here without a translation fails to compile.
48
+ */
49
+ declare const NXE_MESSAGES_EN: {
50
+ readonly 'common.search': "Search";
51
+ readonly 'common.clear': "Clear";
52
+ readonly 'common.close': "Close";
53
+ readonly 'common.ok': "OK";
54
+ readonly 'common.cancel': "Cancel";
55
+ readonly 'common.confirm': "Confirm";
56
+ readonly 'common.yes': "Yes";
57
+ readonly 'common.no': "No";
58
+ readonly 'common.all': "(All)";
59
+ readonly 'common.selectAll': "Select All";
60
+ readonly 'common.blanks': "(Blanks)";
61
+ readonly 'grid.noData': "No data";
62
+ readonly 'grid.groupPanel': "Drag a column header here to group by that column";
63
+ readonly 'grid.edit': "Edit";
64
+ readonly 'grid.save': "Save";
65
+ readonly 'grid.cancel': "Cancel";
66
+ readonly 'grid.expand': "Expand";
67
+ readonly 'grid.collapse': "Collapse";
68
+ readonly 'grid.expandedRow': "Expanded row";
69
+ readonly 'grid.collapsedRow': "Collapsed row";
70
+ readonly 'grid.editableCell': "Editable";
71
+ readonly 'grid.filterRow.operation': "Filter operation";
72
+ readonly 'grid.filterRow.reset': "Reset";
73
+ readonly 'grid.filterRow.true': "true";
74
+ readonly 'grid.filterRow.false': "false";
75
+ readonly 'grid.op.contains': "Contains";
76
+ readonly 'grid.op.notContains': "Does not contain";
77
+ readonly 'grid.op.startsWith': "Starts with";
78
+ readonly 'grid.op.endsWith': "Ends with";
79
+ readonly 'grid.op.equals': "Equals";
80
+ readonly 'grid.op.notEquals': "Does not equal";
81
+ readonly 'grid.op.lessThan': "Less than";
82
+ readonly 'grid.op.greaterThan': "Greater than";
83
+ readonly 'grid.op.lessThanOrEqual': "Less than or equal to";
84
+ readonly 'grid.op.greaterThanOrEqual': "Greater than or equal to";
85
+ readonly 'grid.op.between': "Between";
86
+ readonly 'grid.pager.info': "Page {0} of {1} ({2} items)";
87
+ readonly 'grid.pager.navigation': "Page navigation";
88
+ readonly 'grid.pager.pageSize': "Page size";
89
+ readonly 'grid.pager.itemsPerPage': "Items per page: {0}";
90
+ readonly 'grid.pager.previous': "Previous page";
91
+ readonly 'grid.pager.next': "Next page";
92
+ readonly 'grid.pager.page': "Page {0}";
93
+ readonly 'grid.pager.first': "First page";
94
+ readonly 'grid.pager.last': "Last page";
95
+ readonly 'grid.pager.total': "{0} items";
96
+ readonly 'grid.remote.loading': "Loading";
97
+ readonly 'grid.remote.error': "The data could not be loaded.";
98
+ readonly 'grid.remote.retry': "Retry";
99
+ readonly 'uploader.selectFile': "Select File";
100
+ readonly 'uploader.dropHere': "or Drop here";
101
+ readonly 'uploader.cancel': "Cancel";
102
+ readonly 'uploader.sizeB': "{0} b";
103
+ readonly 'uploader.sizeKb': "{0} Kb";
104
+ readonly 'uploader.sizeMb': "{0} Mb";
105
+ readonly 'validation.rule.required': "Required";
106
+ readonly 'validation.rule.email': "Email is invalid";
107
+ readonly 'validation.rule.pattern': "Value does not match pattern";
108
+ readonly 'validation.rule.range': "Value is out of range";
109
+ readonly 'validation.rule.compare': "Values do not match";
110
+ readonly 'validation.rule.custom': "Value is invalid";
111
+ readonly 'validation.field.required': "This field is required.";
112
+ readonly 'validation.field.email': "Enter a valid email address.";
113
+ readonly 'validation.field.minlength': "Enter at least {0} characters.";
114
+ readonly 'validation.field.maxlength': "Enter no more than {0} characters.";
115
+ readonly 'validation.field.min': "Must be at least {0}.";
116
+ readonly 'validation.field.max': "Must be at most {0}.";
117
+ readonly 'validation.field.pattern': "Enter a value in the expected format.";
118
+ readonly 'validation.field.invalid': "This value is not valid.";
119
+ readonly 'date.now': "Now";
120
+ readonly 'date.done': "Done";
121
+ readonly 'date.hour': "Hour";
122
+ readonly 'date.minute': "Minute";
123
+ readonly 'dateRange.start': "Start date";
124
+ readonly 'dateRange.end': "End date";
125
+ readonly 'dateRange.startPlaceholder': "Start date";
126
+ readonly 'dateRange.endPlaceholder': "End date";
127
+ readonly 'dateRange.dialog': "Choose a date range";
128
+ readonly 'dateRange.previousMonth': "Previous month";
129
+ readonly 'dateRange.nextMonth': "Next month";
130
+ readonly 'dateRange.presets': "Quick ranges";
131
+ readonly 'dateRange.pickStart': "Select the start date";
132
+ readonly 'dateRange.pickEnd': "Select the end date";
133
+ readonly 'dateRange.preset.today': "Today";
134
+ readonly 'dateRange.preset.yesterday': "Yesterday";
135
+ readonly 'dateRange.preset.last7Days': "Last 7 days";
136
+ readonly 'dateRange.preset.last30Days': "Last 30 days";
137
+ readonly 'dateRange.preset.thisMonth': "This month";
138
+ readonly 'dateRange.preset.lastMonth': "Last month";
139
+ readonly 'dateRange.preset.thisYear': "This year";
140
+ readonly 'dropdown.noData': "No data to display";
141
+ readonly 'dropdown.selectAll': "Select All";
142
+ readonly 'uploader.selectFiles': "Select files";
143
+ readonly 'uploader.dropFiles': "or drop files here";
144
+ readonly 'uploader.listLabel': "Attached files";
145
+ readonly 'uploader.acceptHint': "Accepted: {0}";
146
+ readonly 'uploader.maxSizeHint': "Up to {0} each";
147
+ readonly 'uploader.maxFilesHint': "Up to {0} files";
148
+ readonly 'uploader.statusPending': "Waiting to upload";
149
+ readonly 'uploader.statusUploading': "Uploading {0}%";
150
+ readonly 'uploader.statusUploaded': "Uploaded";
151
+ readonly 'uploader.statusFailed': "Upload failed";
152
+ readonly 'uploader.uploadingFile': "Uploading {0}";
153
+ readonly 'uploader.uploadFailed': "The upload failed.";
154
+ readonly 'uploader.cancelled': "Upload cancelled.";
155
+ readonly 'uploader.cancelFile': "Cancel upload of {0}";
156
+ readonly 'uploader.retryFile': "Retry upload of {0}";
157
+ readonly 'uploader.removeFile': "Remove {0}";
158
+ readonly 'uploader.retry': "Retry";
159
+ readonly 'uploader.remove': "Remove";
160
+ readonly 'uploader.rejectType': "{0} is not an accepted file type.";
161
+ readonly 'uploader.rejectSize': "{0} is larger than {1}.";
162
+ readonly 'uploader.rejectCount': "{0} is over the limit of {1} files.";
163
+ readonly 'uploader.announceAdded': "{0} added";
164
+ readonly 'uploader.announceRemoved': "{0} removed";
165
+ readonly 'validation.field.fileType': "Only these file types are accepted: {0}.";
166
+ readonly 'validation.field.fileSize': "Each file must be {0} or smaller.";
167
+ readonly 'validation.field.maxFiles': "Attach at most {0} files.";
168
+ readonly 'validation.field.uploading': "Wait for the uploads to finish.";
169
+ readonly 'validation.field.uploadFailed': "Retry or remove the files that failed to upload.";
170
+ readonly 'timeline.pending': "Pending";
171
+ readonly 'stepper.listLabel': "Steps";
172
+ readonly 'stepper.stepOf': "Step {0} of {1}: {2}";
173
+ readonly 'stepper.completed': "Completed";
174
+ readonly 'stepper.error': "Has errors";
175
+ readonly 'stepper.optional': "Optional";
176
+ readonly 'stepper.blocked': "Step {0} is not complete. Fix the highlighted fields to continue.";
177
+ readonly 'notify.close': "Close notification";
178
+ readonly 'shell.skipToContent': "Skip to content";
179
+ readonly 'shell.mainNavigation': "Main navigation";
180
+ readonly 'shell.toggleNavigation': "Toggle navigation";
181
+ readonly 'shell.closeNavigation': "Close navigation";
182
+ readonly 'shell.collapseSidebar': "Collapse sidebar";
183
+ readonly 'shell.expandSidebar': "Expand sidebar";
184
+ readonly 'pivot.grandTotal': "Grand Total";
185
+ readonly 'pivot.total': "{0} Total";
186
+ readonly 'pivot.noData': "No data";
187
+ readonly 'pivot.showFieldChooser': "Show Field Chooser";
188
+ readonly 'pivot.chooser.title': "Field Chooser";
189
+ readonly 'pivot.chooser.allFields': "All Fields";
190
+ readonly 'pivot.chooser.rowFields': "Row Fields";
191
+ readonly 'pivot.chooser.columnFields': "Column Fields";
192
+ readonly 'pivot.chooser.filterFields': "Filter Fields";
193
+ readonly 'pivot.chooser.dataFields': "Data Fields";
194
+ readonly 'pivot.chooser.checkState': "Check state";
195
+ readonly 'pivot.panel.dropFilter': "Drop Filter Fields Here";
196
+ readonly 'pivot.panel.dropData': "Drop Data Fields Here";
197
+ readonly 'pivot.panel.dropColumn': "Drop Column Fields Here";
198
+ readonly 'pivot.panel.dropRow': "Drop Row Fields Here";
199
+ readonly 'forms.password.show': "Show password";
200
+ readonly 'forms.password.hide': "Hide password";
201
+ readonly 'forms.textArea.charactersLeft': "{0} characters left";
202
+ readonly 'forms.textArea.charactersOver': "{0} characters over the limit";
203
+ readonly 'forms.numberBox.increase': "Increase";
204
+ readonly 'forms.numberBox.decrease': "Decrease";
205
+ readonly 'display.noValue': "No value";
206
+ readonly 'charts.other': "Other";
207
+ readonly 'charts.total': "Total";
208
+ readonly 'charts.empty': "No data to chart";
209
+ readonly 'charts.legend': "Legend";
210
+ readonly 'charts.viewAsTable': "View as table";
211
+ readonly 'charts.viewAsChart': "View as chart";
212
+ readonly 'charts.navigate': "Chart data. Use the arrow keys to move between points, Escape to leave.";
213
+ readonly 'charts.navigateSegments': "Chart segments. Use the arrow keys to move between segments, Escape to leave.";
214
+ readonly 'charts.summary.line': "Line chart, {0} series, {1} points from {2} to {3}.";
215
+ readonly 'charts.summary.area': "Area chart, {0} series, {1} points from {2} to {3}.";
216
+ readonly 'charts.summary.stackedArea': "Stacked area chart, {0} series, {1} points from {2} to {3}.";
217
+ readonly 'charts.summary.series': "{0}: from {1} to {2}, lowest {3}, highest {4}.";
218
+ readonly 'charts.summary.donut': "Donut chart, {0} segments, total {1}.";
219
+ readonly 'charts.summary.segment': "{0}: {1}, {2}.";
220
+ readonly 'charts.table.category': "Category";
221
+ readonly 'charts.table.segment': "Segment";
222
+ readonly 'charts.table.value': "Value";
223
+ readonly 'charts.table.share': "Share";
224
+ readonly 'avatar.status.online': "Online";
225
+ readonly 'avatar.status.away': "Away";
226
+ readonly 'avatar.status.busy': "Busy";
227
+ readonly 'avatar.status.offline': "Offline";
228
+ readonly 'avatar.more': "{0} more";
229
+ readonly 'breadcrumb.label': "Breadcrumb";
230
+ readonly 'breadcrumb.more': "Show hidden levels";
231
+ };
232
+ /** A key of the message bundle. */
233
+ type NxeMessageKey = keyof typeof NXE_MESSAGES_EN;
234
+ /** A complete message bundle: every key, one string each. */
235
+ type NxeMessages = Readonly<Record<NxeMessageKey, string>>;
236
+
237
+ /** What an application states once at bootstrap; see {@link provideNxeMessages}. */
238
+ interface NxeMessagesConfig {
239
+ /** Initial locale (`'en'`, `'id'`, `'id-ID'`...). Default `'en'`. */
240
+ locale?: string;
241
+ /** Partial bundle layered over the active language's bundle, whatever the language. */
242
+ overrides?: Partial<NxeMessages>;
243
+ /**
244
+ * Extra or replacement bundles by language (`{ fr: { 'common.cancel': 'Annuler' } }`). A bundle
245
+ * may be partial: keys it leaves out fall back to English.
246
+ */
247
+ bundles?: Readonly<Record<string, Partial<NxeMessages>>>;
248
+ /**
249
+ * Set Luxon's `Settings.defaultLocale` to the active locale, so month and weekday names (and
250
+ * every `MMM` in a display format) follow the language. Default `true`; `false` leaves Luxon
251
+ * alone. Luxon's previous default is restored when the service is destroyed.
252
+ */
253
+ luxon?: boolean;
254
+ /**
255
+ * Make number separators follow the locale: `true` uses `1.234,5` for `id` and `1,234.5`
256
+ * otherwise, or pass your own `{ [language]: separators }` map. It takes effect through
257
+ * {@link provideNxeMessages}, which then provides {@link NXE_NUMBER_SEPARATORS} as a live view
258
+ * of the active locale. Default off: numbers keep whatever `NXE_NUMBER_SEPARATORS` says.
259
+ */
260
+ separators?: boolean | Readonly<Record<string, NxeNumberSeparators>>;
261
+ }
262
+ /**
263
+ * The library's initial message configuration, provided by {@link provideNxeMessages}. Absent,
264
+ * the service starts in English with nothing overridden.
265
+ */
266
+ declare const NXE_MESSAGES: InjectionToken<NxeMessagesConfig>;
267
+ /**
268
+ * Runtime-switchable messages for every `nxe-*` component.
269
+ *
270
+ * State is signals, so a component that reads {@link t} (or {@link messages}) inside a template or
271
+ * a `computed` re-renders when the language changes: no reload, no recreation. That is also what
272
+ * makes it safe under zoneless OnPush, because the template's reactive consumer tracks the read.
273
+ *
274
+ * ```ts
275
+ * const messages = inject(NxeMessageService);
276
+ * messages.use('id');
277
+ * messages.t('grid.pager.info', 1, 5, 42); // 'Halaman 1 dari 5 (42 item)'
278
+ * ```
279
+ */
280
+ declare class NxeMessageService {
281
+ private readonly config;
282
+ private readonly localeState;
283
+ private readonly customBundle;
284
+ private readonly overrideState;
285
+ /** The active locale as the application stated it (`'id'`, `'en-US'`...). */
286
+ readonly locale: _angular_core.Signal<string>;
287
+ /** The active language (`'id'` for `'id-ID'`); what picks the bundle. */
288
+ readonly language: _angular_core.Signal<string>;
289
+ /** The bundle in force: English, under the language's bundle, under the overrides. */
290
+ readonly messages: _angular_core.Signal<Readonly<Record<"common.search" | "common.clear" | "common.close" | "common.ok" | "common.cancel" | "common.confirm" | "common.yes" | "common.no" | "common.all" | "common.selectAll" | "common.blanks" | "grid.noData" | "grid.groupPanel" | "grid.edit" | "grid.save" | "grid.cancel" | "grid.expand" | "grid.collapse" | "grid.expandedRow" | "grid.collapsedRow" | "grid.editableCell" | "grid.filterRow.operation" | "grid.filterRow.reset" | "grid.filterRow.true" | "grid.filterRow.false" | "grid.op.contains" | "grid.op.notContains" | "grid.op.startsWith" | "grid.op.endsWith" | "grid.op.equals" | "grid.op.notEquals" | "grid.op.lessThan" | "grid.op.greaterThan" | "grid.op.lessThanOrEqual" | "grid.op.greaterThanOrEqual" | "grid.op.between" | "grid.pager.info" | "grid.pager.navigation" | "grid.pager.pageSize" | "grid.pager.itemsPerPage" | "grid.pager.previous" | "grid.pager.next" | "grid.pager.page" | "grid.pager.first" | "grid.pager.last" | "grid.pager.total" | "grid.remote.loading" | "grid.remote.error" | "grid.remote.retry" | "uploader.selectFile" | "uploader.dropHere" | "uploader.cancel" | "uploader.sizeB" | "uploader.sizeKb" | "uploader.sizeMb" | "validation.rule.required" | "validation.rule.email" | "validation.rule.pattern" | "validation.rule.range" | "validation.rule.compare" | "validation.rule.custom" | "validation.field.required" | "validation.field.email" | "validation.field.minlength" | "validation.field.maxlength" | "validation.field.min" | "validation.field.max" | "validation.field.pattern" | "validation.field.invalid" | "date.now" | "date.done" | "date.hour" | "date.minute" | "dateRange.start" | "dateRange.end" | "dateRange.startPlaceholder" | "dateRange.endPlaceholder" | "dateRange.dialog" | "dateRange.previousMonth" | "dateRange.nextMonth" | "dateRange.presets" | "dateRange.pickStart" | "dateRange.pickEnd" | "dateRange.preset.today" | "dateRange.preset.yesterday" | "dateRange.preset.last7Days" | "dateRange.preset.last30Days" | "dateRange.preset.thisMonth" | "dateRange.preset.lastMonth" | "dateRange.preset.thisYear" | "dropdown.noData" | "dropdown.selectAll" | "uploader.selectFiles" | "uploader.dropFiles" | "uploader.listLabel" | "uploader.acceptHint" | "uploader.maxSizeHint" | "uploader.maxFilesHint" | "uploader.statusPending" | "uploader.statusUploading" | "uploader.statusUploaded" | "uploader.statusFailed" | "uploader.uploadingFile" | "uploader.uploadFailed" | "uploader.cancelled" | "uploader.cancelFile" | "uploader.retryFile" | "uploader.removeFile" | "uploader.retry" | "uploader.remove" | "uploader.rejectType" | "uploader.rejectSize" | "uploader.rejectCount" | "uploader.announceAdded" | "uploader.announceRemoved" | "validation.field.fileType" | "validation.field.fileSize" | "validation.field.maxFiles" | "validation.field.uploading" | "validation.field.uploadFailed" | "timeline.pending" | "stepper.listLabel" | "stepper.stepOf" | "stepper.completed" | "stepper.error" | "stepper.optional" | "stepper.blocked" | "notify.close" | "shell.skipToContent" | "shell.mainNavigation" | "shell.toggleNavigation" | "shell.closeNavigation" | "shell.collapseSidebar" | "shell.expandSidebar" | "pivot.grandTotal" | "pivot.total" | "pivot.noData" | "pivot.showFieldChooser" | "pivot.chooser.title" | "pivot.chooser.allFields" | "pivot.chooser.rowFields" | "pivot.chooser.columnFields" | "pivot.chooser.filterFields" | "pivot.chooser.dataFields" | "pivot.chooser.checkState" | "pivot.panel.dropFilter" | "pivot.panel.dropData" | "pivot.panel.dropColumn" | "pivot.panel.dropRow" | "forms.password.show" | "forms.password.hide" | "forms.textArea.charactersLeft" | "forms.textArea.charactersOver" | "forms.numberBox.increase" | "forms.numberBox.decrease" | "display.noValue" | "charts.other" | "charts.total" | "charts.empty" | "charts.legend" | "charts.viewAsTable" | "charts.viewAsChart" | "charts.navigate" | "charts.navigateSegments" | "charts.summary.line" | "charts.summary.area" | "charts.summary.stackedArea" | "charts.summary.series" | "charts.summary.donut" | "charts.summary.segment" | "charts.table.category" | "charts.table.segment" | "charts.table.value" | "charts.table.share" | "avatar.status.online" | "avatar.status.away" | "avatar.status.busy" | "avatar.status.offline" | "avatar.more" | "breadcrumb.label" | "breadcrumb.more", string>>>;
291
+ /** Separators for the active locale; en-US for a language with none. */
292
+ readonly separators: _angular_core.Signal<NxeNumberSeparators>;
293
+ private readonly luxonSync;
294
+ private readonly luxonBefore;
295
+ constructor();
296
+ /**
297
+ * Switch language. A string picks a built-in or configured bundle (`'id'`, `'en'`); a bundle
298
+ * object replaces the language's bundle outright (keys it leaves out fall back to English),
299
+ * under the locale named by the second argument, or the current one.
300
+ */
301
+ use(locale: string): void;
302
+ use(bundle: Partial<NxeMessages>, locale?: string): void;
303
+ /** Layer messages over the active bundle. They merge with earlier overrides and survive {@link use}. */
304
+ override(messages: Partial<NxeMessages>): void;
305
+ /** Drop every override added since bootstrap; the ones in the configuration stay. */
306
+ clearOverrides(): void;
307
+ /**
308
+ * One message, with `{0}`, `{1}`... replaced by `args`. Reactive: reading it in a template or a
309
+ * `computed` subscribes that consumer to the language.
310
+ */
311
+ t(key: NxeMessageKey, ...args: readonly unknown[]): string;
312
+ /** Fill `{n}` placeholders; one without an argument is left as written. */
313
+ static format(template: string, args: readonly unknown[]): string;
314
+ private setLocale;
315
+ static ɵfac: _angular_core.ɵɵFactoryDeclaration<NxeMessageService, never>;
316
+ static ɵprov: _angular_core.ɵɵInjectableDeclaration<NxeMessageService>;
317
+ }
318
+ /**
319
+ * Registers the library's messages for the application:
320
+ *
321
+ * ```ts
322
+ * provideNxeMessages({ locale: 'id', overrides: { 'grid.noData': 'Belum ada data' } })
323
+ * ```
324
+ *
325
+ * With `separators` set it also provides {@link NXE_NUMBER_SEPARATORS} as a live view of the active
326
+ * locale's separators, so grids and number boxes go from `1,234.5` to `1.234,5` with the language.
327
+ */
328
+ declare function provideNxeMessages(config?: NxeMessagesConfig): EnvironmentProviders;
329
+
37
330
  /** A single failed validation rule. */
38
331
  interface NxeBrokenRule {
39
332
  type: string;
@@ -101,20 +394,45 @@ declare abstract class NxeFormControlBase<T> implements ControlValueAccessor, Nx
101
394
  protected readonly ngZone: NgZone;
102
395
  /** Application-wide defaults; each editor resolves `binding ?? this ?? literal`. */
103
396
  protected readonly nxeDefaults: _nexterajs_ui_core.NxeDefaultOptions;
397
+ /** The library's runtime-switchable messages; read them in a template or a computed. */
398
+ protected readonly nxeMessages: NxeMessageService;
104
399
  /**
105
400
  * The current value — single source of truth. Two-way bindable as `[(value)]` (DevExtreme
106
401
  * parity) and also driven by `writeValue` for `ngModel`/`formControlName`.
107
402
  */
108
- readonly value: _angular_core.ModelSignal<T>;
403
+ readonly value: _angular_core.ModelSignal<T | null>;
109
404
  /** Disabled via the `[disabled]` input (DevExtreme parity); OR-combined with forms disabled. */
110
405
  readonly disabledInput: _angular_core.InputSignalWithTransform<boolean, unknown>;
111
406
  private readonly disabledByForm;
112
407
  /** Effective disabled state (input OR reactive-forms `setDisabledState`). */
113
408
  readonly disabled: _angular_core.Signal<boolean>;
114
409
  /** Read-only state (DevExtreme `[readOnly]`). */
115
- readonly readOnly: _angular_core.InputSignalWithTransform<boolean, unknown>;
410
+ readonly readOnlyInput: _angular_core.InputSignalWithTransform<boolean, unknown>;
411
+ /**
412
+ * Lower-case spelling of {@link readOnlyInput}: it is the name Signal Forms (`[formField]`)
413
+ * binds a `readonly()` rule to, and the HTML attribute name.
414
+ */
415
+ readonly readonlyInput: _angular_core.InputSignalWithTransform<boolean, unknown>;
416
+ /** Effective read-only state: `readOnly` OR `readonly`. */
417
+ readonly readOnly: _angular_core.Signal<boolean>;
418
+ /**
419
+ * Signal Forms hides a field with `hidden()` and binds it by this name; also usable on its own.
420
+ * Hides the host, like `visible=false`.
421
+ */
422
+ readonly hiddenInput: _angular_core.InputSignalWithTransform<boolean, unknown>;
423
+ /**
424
+ * Signal Forms state, bound by name when the editor carries `[formField]` (and settable by hand).
425
+ * `invalid` and `errors` put the editor in its invalid state (`nxe-invalid`, `aria-invalid`) once
426
+ * it is {@link touched}; the message text is `nxe-form-field`'s job.
427
+ */
428
+ readonly invalidInput: _angular_core.InputSignalWithTransform<boolean, unknown>;
429
+ readonly errorsInput: _angular_core.InputSignal<readonly {
430
+ readonly kind: string;
431
+ readonly message?: string;
432
+ }[] | null | undefined>;
433
+ protected readonly touchedInput: _angular_core.InputSignalWithTransform<boolean, unknown>;
116
434
  /** Validation group this editor belongs to (its nested `nxe-validator` registers here). */
117
- readonly validationGroupInput: _angular_core.InputSignal<string>;
435
+ readonly validationGroupInput: _angular_core.InputSignal<string | undefined>;
118
436
  /**
119
437
  * `id` for the INNER control, not the host.
120
438
  *
@@ -122,9 +440,9 @@ declare abstract class NxeFormControlBase<T> implements ControlValueAccessor, Nx
122
440
  * a custom element is not it. Without this an editor cannot be labelled at all, which is why
123
441
  * `aria-label` sits beside it: one of the two has to be available.
124
442
  */
125
- readonly inputId: _angular_core.InputSignal<string>;
126
- readonly ariaLabel: _angular_core.InputSignal<string>;
127
- readonly ariaLabelledBy: _angular_core.InputSignal<string>;
443
+ readonly inputId: _angular_core.InputSignal<string | undefined>;
444
+ readonly ariaLabel: _angular_core.InputSignal<string | undefined>;
445
+ readonly ariaLabelledBy: _angular_core.InputSignal<string | undefined>;
128
446
  /** Stable per instance, so the inner control always has an id something can point at. */
129
447
  private readonly fallbackId;
130
448
  readonly controlId: _angular_core.Signal<string>;
@@ -142,12 +460,25 @@ declare abstract class NxeFormControlBase<T> implements ControlValueAccessor, Nx
142
460
  * Set by the validator rather than declared on the editor: the rule is where the requirement
143
461
  * is actually stated, and duplicating it as an input would let the two disagree.
144
462
  */
145
- readonly required: _angular_core.WritableSignal<boolean>;
463
+ private readonly requiredByRule;
464
+ /**
465
+ * A `required` input, which is what Signal Forms binds a `required()` rule to, so a form that
466
+ * is not driven by `nxe-validator` can state it too.
467
+ */
468
+ readonly requiredInput: _angular_core.InputSignalWithTransform<boolean, unknown>;
469
+ /** Whether the editor is required: the `required` input OR a nested validator's `required` rule. */
470
+ readonly required: _angular_core.Signal<boolean>;
146
471
  setRequired(value: boolean): void;
147
472
  /** The current validation error message (set by a nested `nxe-validator`), or null. */
148
- readonly validationError: _angular_core.WritableSignal<string>;
149
- /** Whether the control has been blurred at least once. */
150
- readonly touched: _angular_core.WritableSignal<boolean>;
473
+ readonly validationError: _angular_core.WritableSignal<string | null>;
474
+ private readonly touchedByUser;
475
+ /** Whether the control has been blurred at least once, or a form says the field was touched. */
476
+ readonly touched: _angular_core.Signal<boolean>;
477
+ /**
478
+ * Whether the editor shows its invalid look: a nested validator's message, or a form's
479
+ * `invalid`/`errors` once the field is touched (so an untouched, empty required field is not red).
480
+ */
481
+ readonly invalidState: _angular_core.Signal<boolean>;
151
482
  /** Whether the value has been changed by the user at least once. */
152
483
  readonly dirty: _angular_core.WritableSignal<boolean>;
153
484
  /** DevExtreme-compatible value-change event. */
@@ -177,14 +508,14 @@ declare abstract class NxeFormControlBase<T> implements ControlValueAccessor, Nx
177
508
  */
178
509
  readonly valueChangeEvent: _angular_core.InputSignal<"keyup" | "input" | "change">;
179
510
  /** dx universal widget options. */
180
- readonly hint: _angular_core.InputSignal<string>;
181
- readonly width: _angular_core.InputSignal<string | number>;
511
+ readonly hint: _angular_core.InputSignal<string | undefined>;
512
+ readonly width: _angular_core.InputSignal<string | number | undefined>;
182
513
  readonly visible: _angular_core.InputSignalWithTransform<boolean, unknown>;
183
- readonly tabIndex: _angular_core.InputSignal<number>;
184
- readonly elementAttr: _angular_core.InputSignal<Record<string, string>>;
185
- protected readonly widthStyle: _angular_core.Signal<string>;
186
- protected readonly elementAttrClass: _angular_core.Signal<string>;
187
- protected readonly elementAttrId: _angular_core.Signal<string>;
514
+ readonly tabIndex: _angular_core.InputSignal<number | undefined>;
515
+ readonly elementAttr: _angular_core.InputSignal<Record<string, string> | undefined>;
516
+ protected readonly widthStyle: _angular_core.Signal<string | null>;
517
+ protected readonly elementAttrClass: _angular_core.Signal<string | null>;
518
+ protected readonly elementAttrId: _angular_core.Signal<string | null>;
188
519
  private _onChange;
189
520
  private _onTouched;
190
521
  /** Host element (the DevExtreme event payload `element`). */
@@ -202,6 +533,24 @@ declare abstract class NxeFormControlBase<T> implements ControlValueAccessor, Nx
202
533
  * DevExtreme-shaped `onValueChanged`. No-op when the value is unchanged.
203
534
  */
204
535
  protected commitValue(next: T | null, event?: Event | null): void;
536
+ /**
537
+ * Commit whatever the user has typed but not yet committed, now and synchronously.
538
+ *
539
+ * With the default `valueChangeEvent` a typed value commits on blur, so a programmatic submit
540
+ * (or anything else that reads the model while the field still has focus) would see the old
541
+ * value. Call this first. It is a no-op when nothing is pending, so it never emits
542
+ * `onValueChanged` twice for one change, and it does not blur the field or mark it touched.
543
+ */
544
+ commit(): void;
545
+ /** Alias of {@link commit}. */
546
+ flush(): void;
547
+ /**
548
+ * Editors with text that can be typed but not yet committed override this to commit it through
549
+ * {@link commitValue}. The default is for editors that commit on every interaction.
550
+ */
551
+ protected commitPending(_event: Event | null): void;
552
+ /** Whether Enter in this editor commits the pending text. Multi-line editors narrow it. */
553
+ protected commitsOnEnter(_event: KeyboardEvent): boolean;
205
554
  /**
206
555
  * Re-emit a native event in dx's shape.
207
556
  *
@@ -219,7 +568,7 @@ declare abstract class NxeFormControlBase<T> implements ControlValueAccessor, Nx
219
568
  /** Mark the control as touched (e.g. on blur), notifying Angular forms exactly once. */
220
569
  protected markAsTouched(): void;
221
570
  static ɵfac: _angular_core.ɵɵFactoryDeclaration<NxeFormControlBase<any>, never>;
222
- static ɵdir: _angular_core.ɵɵDirectiveDeclaration<NxeFormControlBase<any>, never, never, { "value": { "alias": "value"; "required": false; "isSignal": true; }; "disabledInput": { "alias": "disabled"; "required": false; "isSignal": true; }; "readOnly": { "alias": "readOnly"; "required": false; "isSignal": true; }; "validationGroupInput": { "alias": "validationGroup"; "required": false; "isSignal": true; }; "inputId": { "alias": "inputId"; "required": false; "isSignal": true; }; "ariaLabel": { "alias": "aria-label"; "required": false; "isSignal": true; }; "ariaLabelledBy": { "alias": "aria-labelledby"; "required": false; "isSignal": true; }; "valueChangeEvent": { "alias": "valueChangeEvent"; "required": false; "isSignal": true; }; "hint": { "alias": "hint"; "required": false; "isSignal": true; }; "width": { "alias": "width"; "required": false; "isSignal": true; }; "visible": { "alias": "visible"; "required": false; "isSignal": true; }; "tabIndex": { "alias": "tabIndex"; "required": false; "isSignal": true; }; "elementAttr": { "alias": "elementAttr"; "required": false; "isSignal": true; }; }, { "value": "valueChange"; "onValueChanged": "onValueChanged"; "onKeyDown": "onKeyDown"; "onKeyUp": "onKeyUp"; "onEnterKey": "onEnterKey"; "onInput": "onInput"; "onChange": "onChange"; "onFocusIn": "onFocusIn"; "onFocusOut": "onFocusOut"; }, never, never, true, never>;
571
+ static ɵdir: _angular_core.ɵɵDirectiveDeclaration<NxeFormControlBase<any>, never, never, { "value": { "alias": "value"; "required": false; "isSignal": true; }; "disabledInput": { "alias": "disabled"; "required": false; "isSignal": true; }; "readOnlyInput": { "alias": "readOnly"; "required": false; "isSignal": true; }; "readonlyInput": { "alias": "readonly"; "required": false; "isSignal": true; }; "hiddenInput": { "alias": "hidden"; "required": false; "isSignal": true; }; "invalidInput": { "alias": "invalid"; "required": false; "isSignal": true; }; "errorsInput": { "alias": "errors"; "required": false; "isSignal": true; }; "touchedInput": { "alias": "touched"; "required": false; "isSignal": true; }; "validationGroupInput": { "alias": "validationGroup"; "required": false; "isSignal": true; }; "inputId": { "alias": "inputId"; "required": false; "isSignal": true; }; "ariaLabel": { "alias": "aria-label"; "required": false; "isSignal": true; }; "ariaLabelledBy": { "alias": "aria-labelledby"; "required": false; "isSignal": true; }; "requiredInput": { "alias": "required"; "required": false; "isSignal": true; }; "valueChangeEvent": { "alias": "valueChangeEvent"; "required": false; "isSignal": true; }; "hint": { "alias": "hint"; "required": false; "isSignal": true; }; "width": { "alias": "width"; "required": false; "isSignal": true; }; "visible": { "alias": "visible"; "required": false; "isSignal": true; }; "tabIndex": { "alias": "tabIndex"; "required": false; "isSignal": true; }; "elementAttr": { "alias": "elementAttr"; "required": false; "isSignal": true; }; }, { "value": "valueChange"; "onValueChanged": "onValueChanged"; "onKeyDown": "onKeyDown"; "onKeyUp": "onKeyUp"; "onEnterKey": "onEnterKey"; "onInput": "onInput"; "onChange": "onChange"; "onFocusIn": "onFocusIn"; "onFocusOut": "onFocusOut"; }, never, never, true, never>;
223
572
  }
224
573
 
225
574
  /**
@@ -288,6 +637,12 @@ interface NxeGridDefaultOptions {
288
637
  showBorders?: boolean;
289
638
  wordWrapEnabled?: boolean;
290
639
  noDataText?: string;
640
+ /**
641
+ * Widget-mode column resizing: when a manual resize leaves the columns narrower than the grid,
642
+ * the trailing column takes the rest, while dragging and after, so no blank strip shows on the
643
+ * right. dx (and the default) lets the table end short of the grid.
644
+ */
645
+ resizeFillsGrid?: boolean;
291
646
  }
292
647
  interface NxePickerDefaultOptions {
293
648
  displayExpr?: string;
@@ -372,7 +727,7 @@ declare class NxeTemplateDirective {
372
727
  /** Attribute-form name (`nxeTemplate="name"`); empty in microsyntax usage. */
373
728
  readonly attrName: _angular_core.InputSignal<string>;
374
729
  /** Microsyntax-form name (`*nxeTemplate="let x of 'name'"` binds `nxeTemplateOf`). */
375
- readonly ofName: _angular_core.InputSignal<string>;
730
+ readonly ofName: _angular_core.InputSignal<string | undefined>;
376
731
  /** The template's lookup name, whichever form supplied it. */
377
732
  readonly name: _angular_core.Signal<string>;
378
733
  readonly templateRef: TemplateRef<unknown>;
@@ -444,5 +799,15 @@ declare class NxeValidationGroupRegistry {
444
799
  static ɵprov: _angular_core.ɵɵInjectableDeclaration<NxeValidationGroupRegistry>;
445
800
  }
446
801
 
447
- export { NXE_DEFAULT_OPTIONS, NXE_OPTION, NXE_VALIDATION_GROUP, NXE_VALIDATION_TARGET, NxeConfigOptionBase, NxeFormControlBase, NxeTemplateDirective, NxeValidationGroupRegistry, coerceArray, nxeOptionalBoolean, nxeResolveExpr, nxeResolveText };
448
- export type { NxeBrokenRule, NxeConfigOption, NxeDefaultOptions, NxeEditorEvent, NxeEditorEventKind, NxeExpr, NxeGridDefaultOptions, NxePickerDefaultOptions, NxeValidatedEvent, NxeValidationGroupMember, NxeValidationGroupScope, NxeValidationResult, NxeValidationTarget, NxeValueChangedEvent };
802
+ /** Indonesian bundle (Bahasa Indonesia), checked against the English key set. */
803
+ declare const NXE_MESSAGES_ID: NxeMessages;
804
+
805
+ /**
806
+ * A byte count as the library writes it in the active language: "512 b", "1.5 Kb", "2.0 Mb" in English,
807
+ * "512 B", "1,5 KB" in Indonesian (the `uploader.size*` messages). Used by the file input and by the
808
+ * file-size message of `nxe-form-field`.
809
+ */
810
+ declare function nxeFormatFileSize(bytes: number, messages: NxeMessageService): string;
811
+
812
+ export { NXE_DEFAULT_OPTIONS, NXE_MESSAGES, NXE_MESSAGES_EN, NXE_MESSAGES_ID, NXE_OPTION, NXE_VALIDATION_GROUP, NXE_VALIDATION_TARGET, NxeConfigOptionBase, NxeFormControlBase, NxeMessageService, NxeTemplateDirective, NxeValidationGroupRegistry, coerceArray, nxeFormatFileSize, nxeOptionalBoolean, nxeResolveExpr, nxeResolveText, provideNxeMessages };
813
+ export type { NxeBrokenRule, NxeConfigOption, NxeDefaultOptions, NxeEditorEvent, NxeEditorEventKind, NxeExpr, NxeGridDefaultOptions, NxeMessageKey, NxeMessages, NxeMessagesConfig, NxePickerDefaultOptions, NxeValidatedEvent, NxeValidationGroupMember, NxeValidationGroupScope, NxeValidationResult, NxeValidationTarget, NxeValueChangedEvent };