@dxos/plugin-settings 0.8.4-main.9be5663bfe → 0.8.4-main.abd8ff62ef

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 (48) hide show
  1. package/dist/lib/browser/SettingsPlugin-RTO4UYCL.mjs +19 -0
  2. package/dist/lib/browser/SettingsPlugin-RTO4UYCL.mjs.map +7 -0
  3. package/dist/lib/browser/index.mjs +16 -31
  4. package/dist/lib/browser/index.mjs.map +4 -4
  5. package/dist/lib/browser/meta.json +1 -1
  6. package/dist/lib/browser/translations.mjs +15 -0
  7. package/dist/lib/browser/translations.mjs.map +7 -0
  8. package/dist/lib/browser/types/index.mjs.map +2 -2
  9. package/dist/lib/node-esm/SettingsPlugin-EQGHMM4D.mjs +21 -0
  10. package/dist/lib/node-esm/SettingsPlugin-EQGHMM4D.mjs.map +7 -0
  11. package/dist/lib/node-esm/index.mjs +16 -31
  12. package/dist/lib/node-esm/index.mjs.map +4 -4
  13. package/dist/lib/node-esm/meta.json +1 -1
  14. package/dist/lib/node-esm/translations.mjs +17 -0
  15. package/dist/lib/node-esm/translations.mjs.map +7 -0
  16. package/dist/lib/node-esm/types/index.mjs.map +2 -2
  17. package/dist/types/src/SettingsPlugin.d.ts +1 -0
  18. package/dist/types/src/SettingsPlugin.d.ts.map +1 -1
  19. package/dist/types/src/SettingsPlugin.test.d.ts +2 -0
  20. package/dist/types/src/SettingsPlugin.test.d.ts.map +1 -0
  21. package/dist/types/src/actions.d.ts.map +1 -1
  22. package/dist/types/src/capabilities/app-graph-builder.d.ts.map +1 -1
  23. package/dist/types/src/capabilities/index.d.ts +1 -1
  24. package/dist/types/src/capabilities/index.d.ts.map +1 -1
  25. package/dist/types/src/capabilities/operation-handler.d.ts +1 -1
  26. package/dist/types/src/capabilities/operation-handler.d.ts.map +1 -1
  27. package/dist/types/src/index.d.ts +3 -1
  28. package/dist/types/src/index.d.ts.map +1 -1
  29. package/dist/types/src/operations/index.d.ts +1 -1
  30. package/dist/types/src/operations/index.d.ts.map +1 -1
  31. package/dist/types/src/operations/open-plugin-registry.d.ts +1 -1
  32. package/dist/types/src/operations/open-plugin-registry.d.ts.map +1 -1
  33. package/dist/types/src/operations/open.d.ts +1 -1
  34. package/dist/types/src/operations/open.d.ts.map +1 -1
  35. package/dist/types/src/translations.d.ts +2 -4
  36. package/dist/types/src/translations.d.ts.map +1 -1
  37. package/dist/types/tsconfig.tsbuildinfo +1 -1
  38. package/package.json +16 -14
  39. package/src/SettingsPlugin.test.ts +33 -0
  40. package/src/SettingsPlugin.ts +3 -2
  41. package/src/capabilities/app-graph-builder.ts +3 -3
  42. package/src/capabilities/index.ts +1 -1
  43. package/src/capabilities/operation-handler.ts +1 -1
  44. package/src/index.ts +8 -1
  45. package/src/operations/index.ts +1 -1
  46. package/src/operations/open-plugin-registry.ts +1 -1
  47. package/src/operations/open.ts +1 -1
  48. package/src/translations.ts +1 -2
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dxos/plugin-settings",
3
- "version": "0.8.4-main.9be5663bfe",
3
+ "version": "0.8.4-main.abd8ff62ef",
4
4
  "description": "DXOS Settings plugin for managing application settings.",
5
5
  "homepage": "https://dxos.org",
6
6
  "bugs": "https://github.com/dxos/dxos/issues",
@@ -13,9 +13,11 @@
13
13
  "sideEffects": true,
14
14
  "type": "module",
15
15
  "imports": {
16
+ "#plugin": "./src/SettingsPlugin.ts",
16
17
  "#capabilities": "./src/capabilities/index.ts",
17
18
  "#meta": "./src/meta.ts",
18
19
  "#operations": "./src/operations/index.ts",
20
+ "#translations": "./src/translations.ts",
19
21
  "#types": "./src/types/index.ts"
20
22
  },
21
23
  "exports": {
@@ -25,6 +27,12 @@
25
27
  "node": "./dist/lib/node-esm/index.mjs",
26
28
  "types": "./dist/types/src/index.d.ts"
27
29
  },
30
+ "./translations": {
31
+ "source": "./src/translations.ts",
32
+ "types": "./dist/types/src/translations.d.ts",
33
+ "browser": "./dist/lib/browser/translations.mjs",
34
+ "node": "./dist/lib/node-esm/translations.mjs"
35
+ },
28
36
  "./types": {
29
37
  "source": "./src/types/index.ts",
30
38
  "types": "./dist/types/src/types/index.d.ts",
@@ -33,28 +41,22 @@
33
41
  }
34
42
  },
35
43
  "types": "dist/types/src/index.d.ts",
36
- "typesVersions": {
37
- "*": {
38
- "types": [
39
- "dist/types/src/types/index.d.ts"
40
- ]
41
- }
42
- },
43
44
  "files": [
44
45
  "dist",
45
46
  "src"
46
47
  ],
47
48
  "dependencies": {
48
- "@dxos/app-framework": "0.8.4-main.9be5663bfe",
49
- "@dxos/operation": "0.8.4-main.9be5663bfe",
50
- "@dxos/app-graph": "0.8.4-main.9be5663bfe",
51
- "@dxos/app-toolkit": "0.8.4-main.9be5663bfe",
52
- "@dxos/util": "0.8.4-main.9be5663bfe"
49
+ "@dxos/app-graph": "0.8.4-main.abd8ff62ef",
50
+ "@dxos/app-toolkit": "0.8.4-main.abd8ff62ef",
51
+ "@dxos/app-framework": "0.8.4-main.abd8ff62ef",
52
+ "@dxos/compute": "0.8.4-main.abd8ff62ef",
53
+ "@dxos/util": "0.8.4-main.abd8ff62ef"
53
54
  },
54
55
  "devDependencies": {
55
56
  "@types/react": "~19.2.7",
56
57
  "effect": "3.20.0",
57
- "react": "~19.2.3"
58
+ "react": "~19.2.3",
59
+ "@dxos/plugin-graph": "0.8.4-main.abd8ff62ef"
58
60
  },
59
61
  "peerDependencies": {
60
62
  "effect": "3.20.0",
@@ -0,0 +1,33 @@
1
+ //
2
+ // Copyright 2026 DXOS.org
3
+ //
4
+
5
+ import { describe, test } from 'vitest';
6
+
7
+ import { OperationPlugin, RuntimePlugin } from '@dxos/app-framework';
8
+ import { createTestApp } from '@dxos/app-framework/testing';
9
+ import { GraphPlugin } from '@dxos/plugin-graph';
10
+
11
+ import { SettingsPlugin } from '#plugin';
12
+
13
+ import { meta } from './meta';
14
+
15
+ const moduleId = (name: string) => `${meta.id}.module.${name}`;
16
+
17
+ describe('SettingsPlugin', () => {
18
+ test('modules activate on the expected events', async ({ expect }) => {
19
+ // Use createTestApp directly to avoid a circular dep with plugin-testing.
20
+ // GraphPlugin fires SetupAppGraph (via firesBeforeActivation) during Startup,
21
+ // activating SettingsAppGraphBuilder. OperationPlugin fires SetupOperationHandler
22
+ // during Startup, activating OperationHandler.
23
+ await using harness = await createTestApp({
24
+ plugins: [GraphPlugin(), OperationPlugin(), RuntimePlugin(), SettingsPlugin()],
25
+ });
26
+
27
+ // SettingsAppGraphBuilder activates on SetupAppGraph (fired by GraphPlugin during Startup).
28
+ // OperationHandler activates on SetupOperationHandler (fired by OperationPlugin during Startup).
29
+ expect(harness.manager.getActive()).toEqual(
30
+ expect.arrayContaining([moduleId('SettingsAppGraphBuilder'), moduleId('OperationHandler')]),
31
+ );
32
+ });
33
+ });
@@ -7,8 +7,7 @@ import { AppPlugin } from '@dxos/app-toolkit';
7
7
 
8
8
  import { OperationHandler, SettingsAppGraphBuilder } from '#capabilities';
9
9
  import { meta } from '#meta';
10
-
11
- import { translations } from './translations';
10
+ import { translations } from '#translations';
12
11
 
13
12
  export const SettingsPlugin = Plugin.define(meta).pipe(
14
13
  AppPlugin.addAppGraphModule({ activate: SettingsAppGraphBuilder }),
@@ -16,3 +15,5 @@ export const SettingsPlugin = Plugin.define(meta).pipe(
16
15
  AppPlugin.addTranslationsModule({ translations }),
17
16
  Plugin.make,
18
17
  );
18
+
19
+ export default SettingsPlugin;
@@ -7,7 +7,7 @@ import * as Effect from 'effect/Effect';
7
7
  import { Capabilities, Capability, type Plugin as Plugin$ } from '@dxos/app-framework';
8
8
  import { GraphBuilder, Node, NodeMatcher } from '@dxos/app-graph';
9
9
  import { AppCapabilities, SettingsOperation, getSpacePath } from '@dxos/app-toolkit';
10
- import { Operation } from '@dxos/operation';
10
+ import { Operation } from '@dxos/compute';
11
11
  import { isNonNullable } from '@dxos/util';
12
12
 
13
13
  import { meta } from '#meta';
@@ -31,7 +31,7 @@ export default Capability.makeModule(
31
31
  id: 'root',
32
32
  data: () => Operation.invoke(SettingsOperation.Open, {}),
33
33
  properties: {
34
- label: ['open-settings.label', { ns: meta.id }],
34
+ label: ['plugin-settings.label', { ns: meta.id }],
35
35
  icon: 'ph--gear--regular',
36
36
  disposition: 'menu',
37
37
  keyBinding: {
@@ -51,7 +51,7 @@ export default Capability.makeModule(
51
51
  id: SETTINGS_ID,
52
52
  type: meta.id,
53
53
  properties: {
54
- label: ['app-settings.label', { ns: meta.id }],
54
+ label: ['plugin-settings.label', { ns: meta.id }],
55
55
  icon: 'ph--gear--regular',
56
56
  disposition: 'pin-end',
57
57
  position: 'hoist',
@@ -3,7 +3,7 @@
3
3
  //
4
4
 
5
5
  import { Capability } from '@dxos/app-framework';
6
- import { OperationHandlerSet } from '@dxos/operation';
6
+ import { OperationHandlerSet } from '@dxos/compute';
7
7
 
8
8
  export const SettingsAppGraphBuilder = Capability.lazy('SettingsAppGraphBuilder', () => import('./app-graph-builder'));
9
9
  export const OperationHandler = Capability.lazy<OperationHandlerSet.OperationHandlerSet>(
@@ -5,7 +5,7 @@
5
5
  import * as Effect from 'effect/Effect';
6
6
 
7
7
  import { Capabilities, Capability } from '@dxos/app-framework';
8
- import type { OperationHandlerSet } from '@dxos/operation';
8
+ import type { OperationHandlerSet } from '@dxos/compute';
9
9
 
10
10
  import { SettingsOperationHandlerSet } from '#operations';
11
11
 
package/src/index.ts CHANGED
@@ -2,5 +2,12 @@
2
2
  // Copyright 2024 DXOS.org
3
3
  //
4
4
 
5
+ import { Plugin } from '@dxos/app-framework';
6
+
7
+ import { meta } from './meta';
8
+
9
+ export const SettingsPlugin = Plugin.lazy(meta, () => import('./SettingsPlugin'));
10
+
11
+ export * from './meta';
12
+
5
13
  export * from './actions';
6
- export * from './SettingsPlugin';
@@ -2,7 +2,7 @@
2
2
  // Copyright 2025 DXOS.org
3
3
  //
4
4
 
5
- import { OperationHandlerSet } from '@dxos/operation';
5
+ import { OperationHandlerSet } from '@dxos/compute';
6
6
 
7
7
  export const SettingsOperationHandlerSet = OperationHandlerSet.lazy(
8
8
  () => import('./open'),
@@ -6,7 +6,7 @@ import * as Effect from 'effect/Effect';
6
6
 
7
7
  import { Capabilities, Capability } from '@dxos/app-framework';
8
8
  import { LayoutOperation, SettingsOperation, getSpacePath } from '@dxos/app-toolkit';
9
- import { Operation } from '@dxos/operation';
9
+ import { Operation } from '@dxos/compute';
10
10
 
11
11
  import { SETTINGS_ID, SETTINGS_KEY } from '../actions';
12
12
 
@@ -6,7 +6,7 @@ import * as Effect from 'effect/Effect';
6
6
 
7
7
  import { Capabilities, Capability } from '@dxos/app-framework';
8
8
  import { LayoutOperation, SettingsOperation, getSpacePath } from '@dxos/app-toolkit';
9
- import { Operation } from '@dxos/operation';
9
+ import { Operation } from '@dxos/compute';
10
10
 
11
11
  import { SETTINGS_ID, SETTINGS_KEY } from '../actions';
12
12
 
@@ -10,8 +10,7 @@ export const translations = [
10
10
  {
11
11
  'en-US': {
12
12
  [meta.id]: {
13
- 'open-settings.label': 'Open settings',
14
- 'app-settings.label': 'Settings',
13
+ 'plugin-settings.label': 'Plugin Settings',
15
14
  },
16
15
  },
17
16
  },