@nice2dev/erp-adapter 1.1.9 → 1.2.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.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,143 @@
1
1
  # @nice2dev/erp-adapter — Changelog
2
2
 
3
+ ## 1.2.0
4
+
5
+ ### Minor Changes
6
+
7
+ - 3a4939d: 1.2.0 — the API cleanup announced for this version, dictionaries per language by default, and
8
+ three new controls. **Breaking:** every removal has a replacement, listed name by name in
9
+ `documentation/omniverk/OMNIVERK_UPGRADE_1.2.0.md`.
10
+
11
+ **Removed (breaking).** All 118 `@deprecated` names: the aliases without the `Nice` prefix in
12
+ `ui-audio`, `ui-graphics` and `ui-3d`; `NiceBarcodeGenerator` (→ `NiceBarcode`), `NiceFloorPlanCanvas`
13
+ (→ `NiceSpatialEditor` in `@nice2dev/ui-buildings`), the v2 props and types of `NiceTopNav`,
14
+ `NiceProgress.showLabel`, `NiceCountryPicker.showDialCode` / `showFlag`, `type` on
15
+ `NiceDateTimePicker` / `NiceDateRangeBox` (→ `dateFormatPreset`); `ZoneOccupancy` in
16
+ `ui-buildings` and `events`, the `SmartHome*` types; the icon variant `flat` (→ `cutout`) and
17
+ `NiceIconEditor` (→ `NiceVectorEditor`); `NiceSizeLegacy`; the `snapGrid` module of `ui-diagrams` (→
18
+ `@nice2dev/spatial-core`); the opt-in stylesheet `@nice2dev/ui/css/legacy-bg-text-aliases.css`, which
19
+ formed an alias cycle with `style.css`. Props that were accepted and never read — 19 on
20
+ `NiceModuleGrid`, and more on `NiceAutocomplete`, `NiceTaskInbox`, `NiceConsentBanner`, the
21
+ building and communication controls, four `ui-audio` panels and `NiceStreamDashboard` — are gone
22
+ from the types. `NiceResourceAllocation` in `ui-erp` is `NiceCapacityPlanner` (the one in `ui`
23
+ keeps its name); `NiceGenericPlayerStageVisualizer` (→ `NiceStageVisualizer`) and
24
+ `NiceCubeBrowserProps` are removed. The `@nice2dev/ui/overlays` entry calls its modal, drawer,
25
+ bottom sheet and context menu `NiceOverlayModal`, `NiceOverlayDrawer`, `NiceOverlayBottomSheet` and
26
+ `NiceOverlayContextMenu`: the old names belonged to different components of `@nice2dev/ui`.
27
+
28
+ **Dictionaries per language.** `NiceI18nProvider` loads only the language in use, with `import()`
29
+ (it was `NiceI18nLazyProvider` in 1.1.10, which stays as the same component); the controls show their
30
+ built-in English until it arrives — `await loadNiceDictionary(lang)` before the first render to start
31
+ in the language. Nothing on the main entry of `@nice2dev/i18n` imports a dictionary any more:
32
+ `NICE_I18N_DICTIONARIES`, `createTranslator`, `NICE_I18N_VARIANTS` / `resolvePlVariant` and the
33
+ translation tooling moved to the new entry `@nice2dev/i18n/all`, and `@nice2dev/ui-core` no longer
34
+ re-exports the dictionary map. `@nice2dev/ui` with what it bundles: 1283 kB → 952 kB gzip loaded up
35
+ front. The `ui-audio` controls read the app's `NiceI18nProvider` now; their own provider overrides it.
36
+
37
+ **New controls.** `NiceRecurrenceEditor`, `NiceStopwatch`, `NiceCountdownTimer` (`@nice2dev/ui`) and
38
+ `NicePasswordGenerator` (`@nice2dev/auth`), plus `recurrenceDates()` and `generatePassword()`.
39
+ `NiceScheduler` honours a weekly rule's `byDay`, which it ignored.
40
+
41
+ **Visible changes.** The palette meets WCAG AA for text on every fill: darker fills in the light
42
+ theme, dark text on the fills of the dark theme (new `--nice-text-on-success` / `-error` / `-info` /
43
+ `-accent` / `-warning`; `NiceThemeText` takes `onSuccess`, `onError`, `onInfo`, `onWarning`). Mobile
44
+ and platform panels follow the app theme instead of `prefers-color-scheme`. Swipes in
45
+ `NiceSwipeActions`, `NiceTouchTable` and `NiceMobileCalendar` work with a mouse and a pen. The
46
+ `ui-forms` editors have the intended spacing (it was four times too large). `NiceMAM`,
47
+ `NiceTranscoder`, `NiceVideoAnnotator` and `NiceStreamDashboard` use `nice-`-prefixed BEM classes.
48
+
49
+ **Fixes.** Controls that invented results ask the host instead: `NiceIntegrationHub`,
50
+ `NiceMLStudio` (`onExperimentRun` may return metrics), `NiceRemoteManagement`
51
+ (`onCaptureScreenshot`), `NicePoseDetector` (`detector`), `NiceBatchScannerProvider`,
52
+ `NiceCacheStrategies`; `NiceLowCodeStudio` accepts dropped components. Controls that did nothing
53
+ work or say why they are off: `NiceStreamDashboard` adds sources, sends chat and runs the chosen
54
+ transition (new `onAddPlatform`, `onSendChatMessage`, `onTransition`, `onScreenshot`,
55
+ `onOpenAudioMixer`, `onOpenSettings`; `receiveChatMessage` feeds incoming chat), `NiceMLStudio`
56
+ downloads through `onModelDownload`, `NiceETLBuilder` saves through `onSave` (its Save button had
57
+ no handler), `NiceTranscoder` makes jobs of picked and dropped files, `NiceAutomationEditor` offers
58
+ the trigger types its model has. Texts of about fifty components go
59
+ through `t()` in six languages, among them the AI data grid, chart and form builders, the ML
60
+ studio, the report designer, the song picker, `NiceProtocolConfig`, `NiceETLBuilder` and
61
+ `NiceInlineHelp` — every key the controls pass to `t()` now has a dictionary entry, so none of
62
+ them stays English under another language; `NiceDataGridAI` sorts on a query in any language, not
63
+ only in English. `NiceWindow`, `NiceConsole`, `NiceFileManager` and `NiceGitManager` no longer
64
+ crash when `accessMode` switches to or from `'hidden'`. Ids come from `createId()` (`@nice2dev/ui-core`), so nothing throws
65
+ outside a secure context as `crypto.randomUUID()` did on plain http. `ui-3d` runs on three r183
66
+ without its deprecation warnings. `NiceRemoteManagement` calls the handlers of the latest render.
67
+ The AI hint popover and the `ui-platform` panels follow the app theme, not the system's or a
68
+ `.dark` class on the host. `NiceCommandPalette` has styles and its search filters;
69
+ `NiceTimeoutFeedback` starts its clock; `NiceOfflineBanner` takes `online`; Monaco's workers in
70
+ `NiceCodeEditor` load; the `ui-audio` panels that used Bootstrap classes use Nice controls; colours
71
+ that reached a canvas as `var(…)` (karaoke lanes and notes) are resolved first.
72
+
73
+ ## 1.1.10
74
+
75
+ ### Patch Changes
76
+
77
+ - 1.1.10 — the additive part of OmniVerk's 1.2.0 list: ui-audio builds without optional packages, one
78
+ i18n context, dictionaries per language, data props optional. No breaking changes.
79
+
80
+ **`@nice2dev/ui-audio` no longer breaks the consumer's build.** It imported `react-bootstrap`,
81
+ `recharts`, `react-window`, `react-youtube` and `pitchy` statically while declaring none of them
82
+ (only optional entries in `peerDependenciesMeta`), so a Vite app without them failed with "failed to
83
+ resolve import". Loading them with `import()` is no way out: Vite 8 (Rolldown) resolves dynamic
84
+ imports at build time and fails the same way, which made `hls.js` and `phaser` mandatory too.
85
+ `react-bootstrap`, `recharts`, `react-window` and `phaser` are now gone from the code
86
+ (`NiceBarFillEditor` uses Nice controls, `NiceVocalPerformanceReport` uses `NiceChart` /
87
+ `NicePieChart`, the karaoke editor list uses `NiceVirtualScroller`, `NiceKaraokePhaserRenderer`
88
+ renders with the DOM and keeps its name); `pitchy`, `react-youtube` and `hls.js` are regular
89
+ `dependencies`. Found on the way: in live mode the vocal performance report subtracted UltraStar note
90
+ numbers from MIDI pitch, so every singer got thousands of cents of deviation and 0 % accuracy — it now
91
+ compares pitch within the octave, as the scoring does; `NiceBarFillEditor` put a colour into a
92
+ percentage slider.
93
+
94
+ **Every package declares what its bundle imports.** A new CI gate checks every `import`, `import()`
95
+ and `require()` in the published `dist` against `dependencies` and non-optional `peerDependencies`.
96
+ To reach zero: `@nice2dev/licensing` no longer has `require('webpack')` in its main bundle (the webpack
97
+ plugin uses `compiler.webpack`; webpack 4 gets a warning instead of feature flags) and `react` is a
98
+ required peer; `@nice2dev/erp-adapter` lists `@microsoft/signalr` in `dependencies` (still loaded on
99
+ first use); `@nice2dev/icons-cursor` declares its `react-dom` peer; `@nice2dev/ui-printing` treats
100
+ `@nice2dev/ui` as a required peer.
101
+
102
+ **One copy of each package, one i18n context.** `@nice2dev/ui` carried its own copy of
103
+ `@nice2dev/ui-core` and `@nice2dev/i18n`, and `ui-forms`, `ui-api`, `ui-bi`, `ui-designers`, `ui-math`
104
+ and `ui-video` each carried a copy of all of `@nice2dev/ui` (about 4.4 MB each). Every copy had its own
105
+ React contexts: a `NiceI18nProvider` imported from `@nice2dev/i18n` did not reach the controls of
106
+ `@nice2dev/ui`, which kept their English defaults and `lang` `'en'`, and the dictionaries ended up in
107
+ an app several times. These packages now import `@nice2dev/*` instead (`ui-forms` 4.4 MB → 82 kB).
108
+ Keep every `@nice2dev/*` package on the same version.
109
+
110
+ **Dictionaries per language.** `NiceI18nLazyProvider` takes the same props as `NiceI18nProvider`
111
+ (`t`, `lang`, `overrides`, plus `fallback` and `onError`) but loads only the active language's
112
+ dictionary, with `import()`; until it arrives the controls show their built-in English (or
113
+ `fallback`), and with `t` nothing is loaded at all. Also `loadNiceDictionary(lang)`, to start in a
114
+ language without a flash of English, and `getLoadedNiceDictionary(lang)`. Exported from
115
+ `@nice2dev/i18n`, `@nice2dev/ui-core` and `@nice2dev/ui`; in the `i18n` build every language is its own
116
+ file. `NiceI18nProvider` and `NICE_I18N_DICTIONARIES` are unchanged and still bring all 30 dictionaries.
117
+ `NiceTestWrapper` (ui-core) and `NiceShowcase` (ui) use the lazy provider now, so they no longer pull
118
+ every dictionary into the apps that bundle them.
119
+
120
+ **Data props are optional.** These controls threw a `TypeError` without data and now render empty:
121
+ `NiceTreeView.nodes`, `NiceAccordion.items`, `NiceCascadeSelect.options`, `NiceAutocomplete.options`,
122
+ `NiceAuditLog.entries`, `NiceDocumentVersionList.versions`, `NicePermissionMatrix.roles` / `actions`,
123
+ `WizardStep.content`, `NiceDiagramViewer.document`, `NiceOrgChartVisualizer.data`,
124
+ `NiceSpatialViewer.document`, and in `@nice2dev/events` the lists of `NiceGiftRegistry`,
125
+ `NiceParticipantList`, `NiceExpenseSplit`, `NiceSeatingChart`, `NiceMediaCollage` and `NiceEventMedia`.
126
+ `NiceMap` without `center` centres on its markers (the whole world without markers), `NiceCountdown`
127
+ without `targetDate` shows zero and never calls `onComplete`, `NiceChat` without `onSend` is read-only
128
+ (no input), and `NiceInvitationDesigner` gains `defaultTemplate`. A CI ratchet counts the required
129
+ array props that remain.
130
+
131
+ **Smaller fixes.** `NicePieChart` draws a 100 % slice as a full circle instead of nothing. In
132
+ development `NiceThemeProvider` warns when `--nice-primary` / `--nice-color-primary` (or another linked
133
+ pair) resolves to nothing on `:root` — usually an alias cycle in the app's CSS; the theming guides say
134
+ which side to set. `@nice2dev/game-engine` exports `createAnimationClip`, `AnimatorController` and
135
+ `createAnimatorController` (two modules exported each name, so `export *` dropped all three); the other
136
+ implementations are `StateMachineAnimatorController`, `createStateMachineAnimatorController`,
137
+ `createTimelineAnimationClip` and `createRetargetingAnimationClip`.
138
+
139
+ Nothing was renamed or removed.
140
+
3
141
  ## 1.1.9
4
142
 
5
143
  No changes in this release.
@@ -10,7 +10,8 @@ export interface ErpSignalRAdapter {
10
10
  onStatusChange(cb: (status: SignalRStatus) => void): () => void;
11
11
  }
12
12
  /**
13
- * Create a SignalR adapter using dynamic import of @microsoft/signalr.
14
- * This keeps the dependency optional — consumers must install it themselves.
13
+ * Create a SignalR adapter. @microsoft/signalr is loaded with import() on first use, so it
14
+ * stays out of the initial bundle — but it is a dependency of this package: as an optional
15
+ * one the consumer had to install, every Vite app without it failed to build.
15
16
  */
16
17
  export declare function createSignalRAdapter(config: ErpSignalRConfig): Promise<ErpSignalRAdapter>;
@@ -4,7 +4,7 @@
4
4
  *
5
5
  * @since 1.0.6
6
6
  */
7
- export type IconStyle = 'solid' | 'outline' | 'duotone' | 'flat';
7
+ export type IconStyle = 'solid' | 'outline' | 'duotone' | 'cutout';
8
8
  export type IconPackage = '@nice2dev/icons' | '@nice2dev/icons-business' | '@nice2dev/icons-all' | '@nice2dev/icons-cursor' | '@nice2dev/icons-education' | '@nice2dev/icons-filetypes' | '@nice2dev/icons-game' | '@nice2dev/icons-gaming' | '@nice2dev/icons-life' | '@nice2dev/icons-math' | '@nice2dev/icons-media' | '@nice2dev/icons-science' | '@nice2dev/icons-social' | '@nice2dev/icons-tech';
9
9
  export interface IconRef {
10
10
  /** Icon component name, e.g. "NtdBriefcase" or "CustomerIcon" */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nice2dev/erp-adapter",
3
- "version": "1.1.9",
3
+ "version": "1.2.0",
4
4
  "description": "Adapter layer connecting OmniVerk .NET backend with @nice2dev/* React components",
5
5
  "type": "module",
6
6
  "main": "dist/index.cjs",
@@ -35,6 +35,9 @@
35
35
  ],
36
36
  "author": "NiceToDev",
37
37
  "license": "SEE LICENSE IN LICENSE",
38
+ "dependencies": {
39
+ "@microsoft/signalr": "^10.0.11"
40
+ },
38
41
  "peerDependencies": {
39
42
  "react": ">=17.0.0",
40
43
  "react-dom": ">=17.0.0"