@goodandready/dsh-dsml-artifact-guard 0.2.10 → 0.2.12
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 +12 -0
- package/lib/client.js +2 -2
- package/lib/index.js +13 -5
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -7,6 +7,18 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
7
7
|
|
|
8
8
|
---
|
|
9
9
|
|
|
10
|
+
## [0.2.12] - 2026-10-15
|
|
11
|
+
|
|
12
|
+
### Fixed
|
|
13
|
+
- **Settings Form Entry ID Query**: in `lib/client.js` `PluginCard`, changed `_ctx.configForms.get(...)` to query strictly `ROW_ID` (`'dsh-dsml-artifact-guard'`), removing fallback to package name `NS` (`'@goodandready/dsh-dsml-artifact-guard'`) (#64).
|
|
14
|
+
- **Settings Scope Binding**: bound `_ctx.settingsScope` using `namespace: ROW_ID`, fixing settings form read failure and resolving `dshmarket` verifier warning for unserved config namespaces (#64).
|
|
15
|
+
|
|
16
|
+
## [0.2.11] - 2026-10-15
|
|
17
|
+
|
|
18
|
+
### Fixed
|
|
19
|
+
- **Settings Policy Owner Attribution**: passed `ctx.fiber` as the owner argument to `ctx.settings.configure({ auto: false }, ctx.fiber)`, ensuring settings policy correctly attributes to the plugin fiber and suppresses generic duplicate form generation (#62).
|
|
20
|
+
- **Live Configuration Updates via Volatile Event**: subscribed to `loader/volatile-update` in `apply()`, allowing live settings mutations saved in the Web UI card to take effect in place without requiring a server restart (#62).
|
|
21
|
+
|
|
10
22
|
## [0.2.10] - 2026-10-07
|
|
11
23
|
|
|
12
24
|
### Removed
|
package/lib/client.js
CHANGED
|
@@ -122,9 +122,9 @@ window.__ModuleLoader__.load({
|
|
|
122
122
|
if (!scopeRef.current && _ctx) {
|
|
123
123
|
try {
|
|
124
124
|
if (_ctx.configForms && typeof _ctx.configForms.get === 'function') {
|
|
125
|
-
scopeRef.current = _ctx.configForms.get(ROW_ID)
|
|
125
|
+
scopeRef.current = _ctx.configForms.get(ROW_ID);
|
|
126
126
|
} else if (_ctx.settingsScope && typeof _ctx.settingsScope.bind === 'function') {
|
|
127
|
-
scopeRef.current = _ctx.settingsScope.bind({ namespace:
|
|
127
|
+
scopeRef.current = _ctx.settingsScope.bind({ namespace: ROW_ID });
|
|
128
128
|
}
|
|
129
129
|
} catch (e) {
|
|
130
130
|
scopeRef.current = null;
|
package/lib/index.js
CHANGED
|
@@ -172,16 +172,24 @@ export function apply(ctx, initialConfig = {}) {
|
|
|
172
172
|
|
|
173
173
|
let getConfig = () => (typeof initialConfig?.get === 'function' ? unwrapConfig(initialConfig) : activeConfig);
|
|
174
174
|
|
|
175
|
-
// Live config subscription from the plugin fiber
|
|
175
|
+
// Live config subscription from the plugin fiber (re-read volatile entries on loader/volatile-update)
|
|
176
176
|
if (typeof ctx.on === 'function') {
|
|
177
|
-
|
|
178
|
-
activeConfig = unwrapConfig(nextConfig);
|
|
179
|
-
}
|
|
177
|
+
const syncConfig = (nextConfig) => {
|
|
178
|
+
activeConfig = unwrapConfig(nextConfig || initialConfig);
|
|
179
|
+
};
|
|
180
|
+
ctx.effect(() => {
|
|
181
|
+
const unsubVolatile = ctx.on('loader/volatile-update', () => syncConfig());
|
|
182
|
+
const unsubConfig = ctx.on('config', (nextConfig) => syncConfig(nextConfig));
|
|
183
|
+
return () => {
|
|
184
|
+
if (typeof unsubVolatile === 'function') unsubVolatile();
|
|
185
|
+
if (typeof unsubConfig === 'function') unsubConfig();
|
|
186
|
+
};
|
|
187
|
+
}, 'dsh-dsml-artifact-guard: live config');
|
|
180
188
|
}
|
|
181
189
|
|
|
182
190
|
// DSH 0.1.7 SettingsForms: suppress generic duplicate form, custom card mounts in plugins seat
|
|
183
191
|
if (ctx.settings && typeof ctx.settings.configure === 'function') {
|
|
184
|
-
ctx.effect(() => ctx.settings.configure({ auto: false }), 'dsh-dsml-artifact-guard: settings policy');
|
|
192
|
+
ctx.effect(() => ctx.settings.configure({ auto: false }, ctx.fiber), 'dsh-dsml-artifact-guard: settings policy');
|
|
185
193
|
}
|
|
186
194
|
// Register one-click updater endpoint
|
|
187
195
|
if (ctx.webServer && typeof ctx.webServer.register === 'function') {
|