@dxos/plugin-native 0.8.4-main.5ea62a8 → 0.8.4-main.ae835ea

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.
@@ -0,0 +1,15 @@
1
+ // src/meta.ts
2
+ import { trim } from "@dxos/util";
3
+ var meta = {
4
+ id: "dxos.org/plugin/native",
5
+ name: "Native",
6
+ description: trim`
7
+ Native platform integration providing desktop-specific features and system-level capabilities.
8
+ Access native file dialogs, notifications, and OS integrations.
9
+ `
10
+ };
11
+
12
+ export {
13
+ meta
14
+ };
15
+ //# sourceMappingURL=chunk-SP3MEGKI.mjs.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../src/meta.ts"],
4
+ "sourcesContent": ["//\n// Copyright 2023 DXOS.org\n//\n\nimport { type PluginMeta } from '@dxos/app-framework';\nimport { trim } from '@dxos/util';\n\nexport const meta: PluginMeta = {\n id: 'dxos.org/plugin/native',\n name: 'Native',\n description: trim`\n Native platform integration providing desktop-specific features and system-level capabilities.\n Access native file dialogs, notifications, and OS integrations.\n `,\n};\n"],
5
+ "mappings": ";AAKA,SAASA,YAAY;AAEd,IAAMC,OAAmB;EAC9BC,IAAI;EACJC,MAAM;EACNC,aAAaC;;;;AAIf;",
6
+ "names": ["trim", "meta", "id", "name", "description", "trim"]
7
+ }
@@ -1,7 +1,6 @@
1
1
  import {
2
- NATIVE_PLUGIN,
3
2
  meta
4
- } from "./chunk-E2JDGVJI.mjs";
3
+ } from "./chunk-SP3MEGKI.mjs";
5
4
 
6
5
  // src/NativePlugin.tsx
7
6
  import { Capabilities, Events, contributes, defineModule, definePlugin } from "@dxos/app-framework";
@@ -9,9 +8,9 @@ import { AssistantEvents } from "@dxos/plugin-assistant";
9
8
 
10
9
  // src/capabilities/index.ts
11
10
  import { lazy } from "@dxos/app-framework";
12
- var Ollama = lazy(() => import("./ollama-7VZCJLY5.mjs"));
13
- var Updater = lazy(() => import("./updater-MCAQYHED.mjs"));
14
- var Window = lazy(() => import("./window-5EBHZJJ4.mjs"));
11
+ var Ollama = lazy(() => import("./ollama-CQE7ZIWL.mjs"));
12
+ var Updater = lazy(() => import("./updater-SDBPTCXA.mjs"));
13
+ var Window = lazy(() => import("./window-6G542FZL.mjs"));
15
14
 
16
15
  // src/translations.ts
17
16
  var translations = [
@@ -28,7 +27,7 @@ var translations = [
28
27
  ];
29
28
 
30
29
  // src/NativePlugin.tsx
31
- var NativePlugin = () => definePlugin(meta, [
30
+ var NativePlugin = definePlugin(meta, () => [
32
31
  defineModule({
33
32
  id: `${meta.id}/module/translations`,
34
33
  activatesOn: Events.SetupTranslations,
@@ -51,7 +50,6 @@ var NativePlugin = () => definePlugin(meta, [
51
50
  })
52
51
  ]);
53
52
  export {
54
- NATIVE_PLUGIN,
55
53
  NativePlugin,
56
54
  meta
57
55
  };
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../../src/NativePlugin.tsx", "../../../src/capabilities/index.ts", "../../../src/translations.ts"],
4
- "sourcesContent": ["//\n// Copyright 2023 DXOS.org\n//\n\nimport { Capabilities, Events, contributes, defineModule, definePlugin } from '@dxos/app-framework';\nimport { AssistantEvents } from '@dxos/plugin-assistant';\n\nimport { Ollama, Updater, Window } from './capabilities';\nimport { meta } from './meta';\nimport { translations } from './translations';\n\nexport const NativePlugin = () =>\n definePlugin(meta, [\n defineModule({\n id: `${meta.id}/module/translations`,\n activatesOn: Events.SetupTranslations,\n activate: () => contributes(Capabilities.Translations, translations),\n }),\n defineModule({\n id: `${meta.id}/module/updater`,\n activatesOn: Events.DispatcherReady,\n activate: Updater,\n }),\n defineModule({\n id: `${meta.id}/module/window`,\n activatesOn: Events.DispatcherReady,\n activate: Window,\n }),\n defineModule({\n id: `${meta.id}/module/ollama`,\n activatesOn: AssistantEvents.SetupAiServiceProviders,\n activate: Ollama,\n }),\n ]);\n", "//\n// Copyright 2025 DXOS.org\n//\n\nimport { lazy } from '@dxos/app-framework';\n\nexport const Ollama = lazy(() => import('./ollama'));\nexport const Updater = lazy(() => import('./updater'));\nexport const Window = lazy(() => import('./window'));\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport { type Resource } from '@dxos/react-ui';\n\nimport { meta } from './meta';\n\nexport const translations = [\n {\n 'en-US': {\n [meta.id]: {\n 'update ready label': 'Ready to update',\n 'update ready description': 'A new version of Composer is available.',\n 'update label': 'Update',\n 'update alt': 'Relaunch the app to update',\n },\n },\n },\n] as const satisfies Resource[];\n"],
5
- "mappings": ";;;;;;AAIA,SAASA,cAAcC,QAAQC,aAAaC,cAAcC,oBAAoB;AAC9E,SAASC,uBAAuB;;;ACDhC,SAASC,YAAY;AAEd,IAAMC,SAASC,KAAK,MAAM,OAAO,uBAAA,CAAA;AACjC,IAAMC,UAAUD,KAAK,MAAM,OAAO,wBAAA,CAAA;AAClC,IAAME,SAASF,KAAK,MAAM,OAAO,uBAAA,CAAA;;;ACAjC,IAAMG,eAAe;EAC1B;IACE,SAAS;MACP,CAACC,KAAKC,EAAE,GAAG;QACT,sBAAsB;QACtB,4BAA4B;QAC5B,gBAAgB;QAChB,cAAc;MAChB;IACF;EACF;;;;AFPK,IAAMC,eAAe,MAC1BC,aAAaC,MAAM;EACjBC,aAAa;IACXC,IAAI,GAAGF,KAAKE,EAAE;IACdC,aAAaC,OAAOC;IACpBC,UAAU,MAAMC,YAAYC,aAAaC,cAAcC,YAAAA;EACzD,CAAA;EACAT,aAAa;IACXC,IAAI,GAAGF,KAAKE,EAAE;IACdC,aAAaC,OAAOO;IACpBL,UAAUM;EACZ,CAAA;EACAX,aAAa;IACXC,IAAI,GAAGF,KAAKE,EAAE;IACdC,aAAaC,OAAOO;IACpBL,UAAUO;EACZ,CAAA;EACAZ,aAAa;IACXC,IAAI,GAAGF,KAAKE,EAAE;IACdC,aAAaW,gBAAgBC;IAC7BT,UAAUU;EACZ,CAAA;CACD;",
4
+ "sourcesContent": ["//\n// Copyright 2023 DXOS.org\n//\n\nimport { Capabilities, Events, contributes, defineModule, definePlugin } from '@dxos/app-framework';\nimport { AssistantEvents } from '@dxos/plugin-assistant';\n\nimport { Ollama, Updater, Window } from './capabilities';\nimport { meta } from './meta';\nimport { translations } from './translations';\n\nexport const NativePlugin = definePlugin(meta, () => [\n defineModule({\n id: `${meta.id}/module/translations`,\n activatesOn: Events.SetupTranslations,\n activate: () => contributes(Capabilities.Translations, translations),\n }),\n defineModule({\n id: `${meta.id}/module/updater`,\n activatesOn: Events.DispatcherReady,\n activate: Updater,\n }),\n defineModule({\n id: `${meta.id}/module/window`,\n activatesOn: Events.DispatcherReady,\n activate: Window,\n }),\n defineModule({\n id: `${meta.id}/module/ollama`,\n activatesOn: AssistantEvents.SetupAiServiceProviders,\n activate: Ollama,\n }),\n]);\n", "//\n// Copyright 2025 DXOS.org\n//\n\nimport { lazy } from '@dxos/app-framework';\n\nexport const Ollama = lazy(() => import('./ollama'));\nexport const Updater = lazy(() => import('./updater'));\nexport const Window = lazy(() => import('./window'));\n", "//\n// Copyright 2023 DXOS.org\n//\n\nimport { type Resource } from '@dxos/react-ui';\n\nimport { meta } from './meta';\n\nexport const translations = [\n {\n 'en-US': {\n [meta.id]: {\n 'update ready label': 'Ready to update',\n 'update ready description': 'A new version of Composer is available.',\n 'update label': 'Update',\n 'update alt': 'Relaunch the app to update',\n },\n },\n },\n] as const satisfies Resource[];\n"],
5
+ "mappings": ";;;;;AAIA,SAASA,cAAcC,QAAQC,aAAaC,cAAcC,oBAAoB;AAC9E,SAASC,uBAAuB;;;ACDhC,SAASC,YAAY;AAEd,IAAMC,SAASC,KAAK,MAAM,OAAO,uBAAA,CAAA;AACjC,IAAMC,UAAUD,KAAK,MAAM,OAAO,wBAAA,CAAA;AAClC,IAAME,SAASF,KAAK,MAAM,OAAO,uBAAA,CAAA;;;ACAjC,IAAMG,eAAe;EAC1B;IACE,SAAS;MACP,CAACC,KAAKC,EAAE,GAAG;QACT,sBAAsB;QACtB,4BAA4B;QAC5B,gBAAgB;QAChB,cAAc;MAChB;IACF;EACF;;;;AFPK,IAAMC,eAAeC,aAAaC,MAAM,MAAM;EACnDC,aAAa;IACXC,IAAI,GAAGF,KAAKE,EAAE;IACdC,aAAaC,OAAOC;IACpBC,UAAU,MAAMC,YAAYC,aAAaC,cAAcC,YAAAA;EACzD,CAAA;EACAT,aAAa;IACXC,IAAI,GAAGF,KAAKE,EAAE;IACdC,aAAaC,OAAOO;IACpBL,UAAUM;EACZ,CAAA;EACAX,aAAa;IACXC,IAAI,GAAGF,KAAKE,EAAE;IACdC,aAAaC,OAAOO;IACpBL,UAAUO;EACZ,CAAA;EACAZ,aAAa;IACXC,IAAI,GAAGF,KAAKE,EAAE;IACdC,aAAaW,gBAAgBC;IAC7BT,UAAUU;EACZ,CAAA;CACD;",
6
6
  "names": ["Capabilities", "Events", "contributes", "defineModule", "definePlugin", "AssistantEvents", "lazy", "Ollama", "lazy", "Updater", "Window", "translations", "meta", "id", "NativePlugin", "definePlugin", "meta", "defineModule", "id", "activatesOn", "Events", "SetupTranslations", "activate", "contributes", "Capabilities", "Translations", "translations", "DispatcherReady", "Updater", "Window", "AssistantEvents", "SetupAiServiceProviders", "Ollama"]
7
7
  }
@@ -1 +1 @@
1
- {"inputs":{"src/meta.ts":{"bytes":914,"imports":[],"format":"esm"},"src/capabilities/ollama.ts":{"bytes":10053,"imports":[{"path":"@effect/platform","kind":"import-statement","external":true},{"path":"@tauri-apps/plugin-shell","kind":"import-statement","external":true},{"path":"effect","kind":"import-statement","external":true},{"path":"@dxos/ai","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/log","kind":"import-statement","external":true},{"path":"@dxos/plugin-assistant","kind":"import-statement","external":true}],"format":"esm"},"src/capabilities/updater.ts":{"bytes":11521,"imports":[{"path":"@tauri-apps/plugin-os","kind":"import-statement","external":true},{"path":"@tauri-apps/plugin-process","kind":"import-statement","external":true},{"path":"@tauri-apps/plugin-updater","kind":"import-statement","external":true},{"path":"effect","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/log","kind":"import-statement","external":true},{"path":"src/meta.ts","kind":"import-statement","original":"../meta"}],"format":"esm"},"src/capabilities/window.ts":{"bytes":5689,"imports":[{"path":"@tauri-apps/api/window","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true}],"format":"esm"},"src/capabilities/index.ts":{"bytes":1148,"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"src/capabilities/ollama.ts","kind":"dynamic-import","original":"./ollama"},{"path":"src/capabilities/updater.ts","kind":"dynamic-import","original":"./updater"},{"path":"src/capabilities/window.ts","kind":"dynamic-import","original":"./window"}],"format":"esm"},"src/translations.ts":{"bytes":1625,"imports":[{"path":"src/meta.ts","kind":"import-statement","original":"./meta"}],"format":"esm"},"src/NativePlugin.tsx":{"bytes":4037,"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/plugin-assistant","kind":"import-statement","external":true},{"path":"src/capabilities/index.ts","kind":"import-statement","original":"./capabilities"},{"path":"src/meta.ts","kind":"import-statement","original":"./meta"},{"path":"src/translations.ts","kind":"import-statement","original":"./translations"}],"format":"esm"},"src/index.ts":{"bytes":549,"imports":[{"path":"src/meta.ts","kind":"import-statement","original":"./meta"},{"path":"src/NativePlugin.tsx","kind":"import-statement","original":"./NativePlugin"}],"format":"esm"}},"outputs":{"dist/lib/browser/index.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":3147},"dist/lib/browser/index.mjs":{"imports":[{"path":"dist/lib/browser/chunk-E2JDGVJI.mjs","kind":"import-statement"},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/plugin-assistant","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"dist/lib/browser/ollama-7VZCJLY5.mjs","kind":"dynamic-import"},{"path":"dist/lib/browser/updater-MCAQYHED.mjs","kind":"dynamic-import"},{"path":"dist/lib/browser/window-5EBHZJJ4.mjs","kind":"dynamic-import"}],"exports":["NATIVE_PLUGIN","NativePlugin","meta"],"entryPoint":"src/index.ts","inputs":{"src/index.ts":{"bytesInOutput":0},"src/NativePlugin.tsx":{"bytesInOutput":771},"src/capabilities/index.ts":{"bytesInOutput":220},"src/translations.ts":{"bytesInOutput":293}},"bytes":1539},"dist/lib/browser/ollama-7VZCJLY5.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":5088},"dist/lib/browser/ollama-7VZCJLY5.mjs":{"imports":[{"path":"@effect/platform","kind":"import-statement","external":true},{"path":"@tauri-apps/plugin-shell","kind":"import-statement","external":true},{"path":"effect","kind":"import-statement","external":true},{"path":"@dxos/ai","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/log","kind":"import-statement","external":true},{"path":"@dxos/plugin-assistant","kind":"import-statement","external":true}],"exports":["default"],"entryPoint":"src/capabilities/ollama.ts","inputs":{"src/capabilities/ollama.ts":{"bytesInOutput":2669}},"bytes":2784},"dist/lib/browser/updater-MCAQYHED.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":5370},"dist/lib/browser/updater-MCAQYHED.mjs":{"imports":[{"path":"dist/lib/browser/chunk-E2JDGVJI.mjs","kind":"import-statement"},{"path":"@tauri-apps/plugin-os","kind":"import-statement","external":true},{"path":"@tauri-apps/plugin-process","kind":"import-statement","external":true},{"path":"@tauri-apps/plugin-updater","kind":"import-statement","external":true},{"path":"effect","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/log","kind":"import-statement","external":true}],"exports":["default"],"entryPoint":"src/capabilities/updater.ts","inputs":{"src/capabilities/updater.ts":{"bytesInOutput":3402}},"bytes":3577},"dist/lib/browser/chunk-E2JDGVJI.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":454},"dist/lib/browser/chunk-E2JDGVJI.mjs":{"imports":[],"exports":["NATIVE_PLUGIN","meta"],"inputs":{"src/meta.ts":{"bytesInOutput":100}},"bytes":196},"dist/lib/browser/window-5EBHZJJ4.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":2974},"dist/lib/browser/window-5EBHZJJ4.mjs":{"imports":[{"path":"@tauri-apps/api/window","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true}],"exports":["default"],"entryPoint":"src/capabilities/window.ts","inputs":{"src/capabilities/window.ts":{"bytesInOutput":1212}},"bytes":1327}}}
1
+ {"inputs":{"src/meta.ts":{"bytes":1396,"imports":[{"path":"@dxos/util","kind":"import-statement","external":true}],"format":"esm"},"src/capabilities/ollama.ts":{"bytes":10161,"imports":[{"path":"@effect/platform/FetchHttpClient","kind":"import-statement","external":true},{"path":"@effect/platform/HttpClient","kind":"import-statement","external":true},{"path":"@tauri-apps/plugin-shell","kind":"import-statement","external":true},{"path":"effect/Context","kind":"import-statement","external":true},{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"effect/Layer","kind":"import-statement","external":true},{"path":"effect/ManagedRuntime","kind":"import-statement","external":true},{"path":"@dxos/ai/AiServiceRouter","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/log","kind":"import-statement","external":true}],"format":"esm"},"src/capabilities/updater.ts":{"bytes":12408,"imports":[{"path":"@tauri-apps/plugin-os","kind":"import-statement","external":true},{"path":"@tauri-apps/plugin-process","kind":"import-statement","external":true},{"path":"@tauri-apps/plugin-updater","kind":"import-statement","external":true},{"path":"effect/Duration","kind":"import-statement","external":true},{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"effect/Fiber","kind":"import-statement","external":true},{"path":"effect/Function","kind":"import-statement","external":true},{"path":"effect/Match","kind":"import-statement","external":true},{"path":"effect/Schedule","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/log","kind":"import-statement","external":true},{"path":"src/meta.ts","kind":"import-statement","original":"../meta"}],"format":"esm"},"src/capabilities/window.ts":{"bytes":5689,"imports":[{"path":"@tauri-apps/api/window","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true}],"format":"esm"},"src/capabilities/index.ts":{"bytes":1148,"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"src/capabilities/ollama.ts","kind":"dynamic-import","original":"./ollama"},{"path":"src/capabilities/updater.ts","kind":"dynamic-import","original":"./updater"},{"path":"src/capabilities/window.ts","kind":"dynamic-import","original":"./window"}],"format":"esm"},"src/translations.ts":{"bytes":1625,"imports":[{"path":"src/meta.ts","kind":"import-statement","original":"./meta"}],"format":"esm"},"src/NativePlugin.tsx":{"bytes":3973,"imports":[{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/plugin-assistant","kind":"import-statement","external":true},{"path":"src/capabilities/index.ts","kind":"import-statement","original":"./capabilities"},{"path":"src/meta.ts","kind":"import-statement","original":"./meta"},{"path":"src/translations.ts","kind":"import-statement","original":"./translations"}],"format":"esm"},"src/index.ts":{"bytes":549,"imports":[{"path":"src/meta.ts","kind":"import-statement","original":"./meta"},{"path":"src/NativePlugin.tsx","kind":"import-statement","original":"./NativePlugin"}],"format":"esm"}},"outputs":{"dist/lib/browser/index.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":3100},"dist/lib/browser/index.mjs":{"imports":[{"path":"dist/lib/browser/chunk-SP3MEGKI.mjs","kind":"import-statement"},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/plugin-assistant","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"dist/lib/browser/ollama-CQE7ZIWL.mjs","kind":"dynamic-import"},{"path":"dist/lib/browser/updater-SDBPTCXA.mjs","kind":"dynamic-import"},{"path":"dist/lib/browser/window-6G542FZL.mjs","kind":"dynamic-import"}],"exports":["NativePlugin","meta"],"entryPoint":"src/index.ts","inputs":{"src/index.ts":{"bytesInOutput":0},"src/NativePlugin.tsx":{"bytesInOutput":771},"src/capabilities/index.ts":{"bytesInOutput":220},"src/translations.ts":{"bytesInOutput":293}},"bytes":1505},"dist/lib/browser/ollama-CQE7ZIWL.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":5092},"dist/lib/browser/ollama-CQE7ZIWL.mjs":{"imports":[{"path":"@effect/platform/FetchHttpClient","kind":"import-statement","external":true},{"path":"@effect/platform/HttpClient","kind":"import-statement","external":true},{"path":"@tauri-apps/plugin-shell","kind":"import-statement","external":true},{"path":"effect/Context","kind":"import-statement","external":true},{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"effect/Layer","kind":"import-statement","external":true},{"path":"effect/ManagedRuntime","kind":"import-statement","external":true},{"path":"@dxos/ai/AiServiceRouter","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/log","kind":"import-statement","external":true}],"exports":["default"],"entryPoint":"src/capabilities/ollama.ts","inputs":{"src/capabilities/ollama.ts":{"bytesInOutput":2600}},"bytes":2715},"dist/lib/browser/updater-SDBPTCXA.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":5657},"dist/lib/browser/updater-SDBPTCXA.mjs":{"imports":[{"path":"dist/lib/browser/chunk-SP3MEGKI.mjs","kind":"import-statement"},{"path":"@tauri-apps/plugin-os","kind":"import-statement","external":true},{"path":"@tauri-apps/plugin-process","kind":"import-statement","external":true},{"path":"@tauri-apps/plugin-updater","kind":"import-statement","external":true},{"path":"effect/Duration","kind":"import-statement","external":true},{"path":"effect/Effect","kind":"import-statement","external":true},{"path":"effect/Fiber","kind":"import-statement","external":true},{"path":"effect/Function","kind":"import-statement","external":true},{"path":"effect/Match","kind":"import-statement","external":true},{"path":"effect/Schedule","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true},{"path":"@dxos/log","kind":"import-statement","external":true}],"exports":["default"],"entryPoint":"src/capabilities/updater.ts","inputs":{"src/capabilities/updater.ts":{"bytesInOutput":3611}},"bytes":3777},"dist/lib/browser/chunk-SP3MEGKI.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":665},"dist/lib/browser/chunk-SP3MEGKI.mjs":{"imports":[{"path":"@dxos/util","kind":"import-statement","external":true}],"exports":["meta"],"inputs":{"src/meta.ts":{"bytesInOutput":293}},"bytes":372},"dist/lib/browser/window-6G542FZL.mjs.map":{"imports":[],"exports":[],"inputs":{},"bytes":2974},"dist/lib/browser/window-6G542FZL.mjs":{"imports":[{"path":"@tauri-apps/api/window","kind":"import-statement","external":true},{"path":"@dxos/app-framework","kind":"import-statement","external":true}],"exports":["default"],"entryPoint":"src/capabilities/window.ts","inputs":{"src/capabilities/window.ts":{"bytesInOutput":1214}},"bytes":1329}}}
@@ -0,0 +1,76 @@
1
+ // src/capabilities/ollama.ts
2
+ import * as FetchHttpClient from "@effect/platform/FetchHttpClient";
3
+ import * as HttpClient from "@effect/platform/HttpClient";
4
+ import { Command } from "@tauri-apps/plugin-shell";
5
+ import * as Context from "effect/Context";
6
+ import * as Effect from "effect/Effect";
7
+ import * as Layer from "effect/Layer";
8
+ import * as ManagedRuntime from "effect/ManagedRuntime";
9
+ import * as AiServiceRouter from "@dxos/ai/AiServiceRouter";
10
+ import { Capabilities, contributes } from "@dxos/app-framework";
11
+ import { log } from "@dxos/log";
12
+ var __dxlog_file = "/__w/dxos/dxos/packages/plugins/plugin-native/src/capabilities/ollama.ts";
13
+ var OLLAMA_HOST = "http://localhost:21434";
14
+ var ollama_default = ((_context) => {
15
+ const runtime = ManagedRuntime.make(OllamaSidecar.layerLive);
16
+ const sidecarLayer = Layer.effectContext(runtime.runtimeEffect.pipe(Effect.map((rt) => rt.context.pipe(Context.pick(OllamaSidecar)))));
17
+ return contributes(Capabilities.AiModelResolver, OllamaSidecarModelResolver.pipe(Layer.provide(sidecarLayer)), async () => {
18
+ await runtime.dispose();
19
+ });
20
+ });
21
+ var OllamaSidecar = class _OllamaSidecar extends Context.Tag("@dxos/plugin-native/OllamaSidecar")() {
22
+ static layerLive = Layer.scoped(_OllamaSidecar, Effect.gen(function* () {
23
+ const command = Command.sidecar("sidecar/ollama", [
24
+ "serve"
25
+ ], {
26
+ env: {
27
+ OLLAMA_HOST,
28
+ OLLAMA_ORIGINS: "*"
29
+ }
30
+ });
31
+ command.stdout.on("data", (data) => console.log("[ollama]", data.toString()));
32
+ command.stderr.on("data", (data) => console.error("[ollama]", data.toString()));
33
+ command.on("close", (code) => log.info("Ollama process exited", {
34
+ code
35
+ }, {
36
+ F: __dxlog_file,
37
+ L: 56,
38
+ S: this,
39
+ C: (f, a) => f(...a)
40
+ }));
41
+ command.on("error", (error) => log.error("Ollama error", {
42
+ error
43
+ }, {
44
+ F: __dxlog_file,
45
+ L: 57,
46
+ S: this,
47
+ C: (f, a) => f(...a)
48
+ }));
49
+ const child = yield* Effect.promise(() => command.spawn());
50
+ yield* Effect.addFinalizer(Effect.fn(function* () {
51
+ yield* Effect.promise(() => child.kill());
52
+ }));
53
+ log.info("Running ollama", {
54
+ pid: child.pid
55
+ }, {
56
+ F: __dxlog_file,
57
+ L: 64,
58
+ S: this,
59
+ C: (f, a) => f(...a)
60
+ });
61
+ return {
62
+ endpoint: OLLAMA_HOST
63
+ };
64
+ }));
65
+ };
66
+ var OllamaSidecarModelResolver = Layer.unwrapEffect(Effect.gen(function* () {
67
+ const { endpoint } = yield* OllamaSidecar;
68
+ return AiServiceRouter.OllamaResolver({
69
+ host: endpoint,
70
+ transformClient: HttpClient.withTracerPropagation(false)
71
+ });
72
+ })).pipe(Layer.provide(FetchHttpClient.layer));
73
+ export {
74
+ ollama_default as default
75
+ };
76
+ //# sourceMappingURL=ollama-CQE7ZIWL.mjs.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../src/capabilities/ollama.ts"],
4
+ "sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport * as FetchHttpClient from '@effect/platform/FetchHttpClient';\nimport * as HttpClient from '@effect/platform/HttpClient';\nimport { Command } from '@tauri-apps/plugin-shell';\nimport * as Context from 'effect/Context';\nimport * as Effect from 'effect/Effect';\nimport * as Layer from 'effect/Layer';\nimport * as ManagedRuntime from 'effect/ManagedRuntime';\n\nimport * as AiServiceRouter from '@dxos/ai/AiServiceRouter';\nimport { Capabilities, type Capability, type PluginContext, contributes } from '@dxos/app-framework';\nimport { log } from '@dxos/log';\n\n// Running ollama on non-standard port.\nconst OLLAMA_HOST = 'http://localhost:21434';\n\nexport default (_context: PluginContext): Capability<any> => {\n const runtime = ManagedRuntime.make(OllamaSidecar.layerLive);\n\n // Layer for the sidecar but the lifecycle is managed by the runtime.\n const sidecarLayer = Layer.effectContext(\n runtime.runtimeEffect.pipe(Effect.map((rt) => rt.context.pipe(Context.pick(OllamaSidecar)))),\n );\n\n return contributes(\n Capabilities.AiModelResolver,\n OllamaSidecarModelResolver.pipe(Layer.provide(sidecarLayer)),\n async () => {\n await runtime.dispose();\n },\n );\n};\n\nclass OllamaSidecar extends Context.Tag('@dxos/plugin-native/OllamaSidecar')<\n OllamaSidecar,\n {\n endpoint: string;\n }\n>() {\n static layerLive = Layer.scoped(\n OllamaSidecar,\n Effect.gen(function* () {\n const command = Command.sidecar('sidecar/ollama', ['serve'], {\n env: {\n OLLAMA_HOST,\n OLLAMA_ORIGINS: '*', // CORS\n },\n });\n\n // NOTE: Keeping those as console.log for consistent formatting.\n command.stdout.on('data', (data) => console.log('[ollama]', data.toString()));\n command.stderr.on('data', (data) => console.error('[ollama]', data.toString()));\n command.on('close', (code) => log.info('Ollama process exited', { code }));\n command.on('error', (error) => log.error('Ollama error', { error }));\n const child = yield* Effect.promise(() => command.spawn());\n yield* Effect.addFinalizer(\n Effect.fn(function* () {\n yield* Effect.promise(() => child.kill());\n }),\n );\n log.info('Running ollama', { pid: child.pid });\n\n return {\n endpoint: OLLAMA_HOST,\n };\n }),\n );\n}\n\nconst OllamaSidecarModelResolver: Layer.Layer<AiServiceRouter.AiModelResolver, never, OllamaSidecar> =\n Layer.unwrapEffect(\n Effect.gen(function* () {\n const { endpoint } = yield* OllamaSidecar;\n return AiServiceRouter.OllamaResolver({\n host: endpoint,\n transformClient: HttpClient.withTracerPropagation(false),\n });\n }),\n ).pipe(Layer.provide(FetchHttpClient.layer));\n"],
5
+ "mappings": ";AAIA,YAAYA,qBAAqB;AACjC,YAAYC,gBAAgB;AAC5B,SAASC,eAAe;AACxB,YAAYC,aAAa;AACzB,YAAYC,YAAY;AACxB,YAAYC,WAAW;AACvB,YAAYC,oBAAoB;AAEhC,YAAYC,qBAAqB;AACjC,SAASC,cAAmDC,mBAAmB;AAC/E,SAASC,WAAW;;AAGpB,IAAMC,cAAc;AAEpB,IAAA,kBAAe,CAACC,aAAAA;AACd,QAAMC,UAAyBC,oBAAKC,cAAcC,SAAS;AAG3D,QAAMC,eAAqBC,oBACzBL,QAAQM,cAAcC,KAAYC,WAAI,CAACC,OAAOA,GAAGC,QAAQH,KAAaI,aAAKT,aAAAA,CAAAA,CAAAA,CAAAA,CAAAA;AAG7E,SAAON,YACLD,aAAaiB,iBACbC,2BAA2BN,KAAWO,cAAQV,YAAAA,CAAAA,GAC9C,YAAA;AACE,UAAMJ,QAAQe,QAAO;EACvB,CAAA;AAEJ;AAEA,IAAMb,gBAAN,MAAMA,uBAA8Bc,YAAI,mCAAA,EAAA,EAAA;EAMtC,OAAOb,YAAkBc,aACvBf,gBACOgB,WAAI,aAAA;AACT,UAAMC,UAAU9B,QAAQ+B,QAAQ,kBAAkB;MAAC;OAAU;MAC3DC,KAAK;QACHvB;QACAwB,gBAAgB;MAClB;IACF,CAAA;AAGAH,YAAQI,OAAOC,GAAG,QAAQ,CAACC,SAASC,QAAQ7B,IAAI,YAAY4B,KAAKE,SAAQ,CAAA,CAAA;AACzER,YAAQS,OAAOJ,GAAG,QAAQ,CAACC,SAASC,QAAQG,MAAM,YAAYJ,KAAKE,SAAQ,CAAA,CAAA;AAC3ER,YAAQK,GAAG,SAAS,CAACM,SAASjC,IAAIkC,KAAK,yBAAyB;MAAED;IAAK,GAAA;;;;;;AACvEX,YAAQK,GAAG,SAAS,CAACK,UAAUhC,IAAIgC,MAAM,gBAAgB;MAAEA;IAAM,GAAA;;;;;;AACjE,UAAMG,QAAQ,OAAcC,eAAQ,MAAMd,QAAQe,MAAK,CAAA;AACvD,WAAcC,oBACLC,UAAG,aAAA;AACR,aAAcH,eAAQ,MAAMD,MAAMK,KAAI,CAAA;IACxC,CAAA,CAAA;AAEFxC,QAAIkC,KAAK,kBAAkB;MAAEO,KAAKN,MAAMM;IAAI,GAAA;;;;;;AAE5C,WAAO;MACLC,UAAUzC;IACZ;EACF,CAAA,CAAA;AAEJ;AAEA,IAAMe,6BACE2B,mBACGtB,WAAI,aAAA;AACT,QAAM,EAAEqB,SAAQ,IAAK,OAAOrC;AAC5B,SAAuBuC,+BAAe;IACpCC,MAAMH;IACNI,iBAA4BC,iCAAsB,KAAA;EACpD,CAAA;AACF,CAAA,CAAA,EACArC,KAAWO,cAAwB+B,qBAAK,CAAA;",
6
+ "names": ["FetchHttpClient", "HttpClient", "Command", "Context", "Effect", "Layer", "ManagedRuntime", "AiServiceRouter", "Capabilities", "contributes", "log", "OLLAMA_HOST", "_context", "runtime", "make", "OllamaSidecar", "layerLive", "sidecarLayer", "effectContext", "runtimeEffect", "pipe", "map", "rt", "context", "pick", "AiModelResolver", "OllamaSidecarModelResolver", "provide", "dispose", "Tag", "scoped", "gen", "command", "sidecar", "env", "OLLAMA_ORIGINS", "stdout", "on", "data", "console", "toString", "stderr", "error", "code", "info", "child", "promise", "spawn", "addFinalizer", "fn", "kill", "pid", "endpoint", "unwrapEffect", "OllamaResolver", "host", "transformClient", "withTracerPropagation", "layer"]
7
+ }
@@ -1,12 +1,17 @@
1
1
  import {
2
- NATIVE_PLUGIN
3
- } from "./chunk-E2JDGVJI.mjs";
2
+ meta
3
+ } from "./chunk-SP3MEGKI.mjs";
4
4
 
5
5
  // src/capabilities/updater.ts
6
6
  import { type } from "@tauri-apps/plugin-os";
7
7
  import { relaunch } from "@tauri-apps/plugin-process";
8
8
  import { check } from "@tauri-apps/plugin-updater";
9
- import { Duration, Effect, Fiber, Match, Schedule, pipe } from "effect";
9
+ import * as Duration from "effect/Duration";
10
+ import * as Effect from "effect/Effect";
11
+ import * as Fiber from "effect/Fiber";
12
+ import * as Function from "effect/Function";
13
+ import * as Match from "effect/Match";
14
+ import * as Schedule from "effect/Schedule";
10
15
  import { Capabilities, LayoutAction, contributes, createIntent } from "@dxos/app-framework";
11
16
  import { log } from "@dxos/log";
12
17
  var __dxlog_file = "/__w/dxos/dxos/packages/plugins/plugin-native/src/capabilities/updater.ts";
@@ -15,16 +20,16 @@ var SUPPORTS_OTA = [
15
20
  "macos",
16
21
  "windows"
17
22
  ];
18
- var updater_default = (context) => {
23
+ var updater_default = ((context) => {
19
24
  const platform = type();
20
- if (!SUPPORTS_OTA.includes(platform)) {
25
+ if (!SUPPORTS_OTA.includes(platform) || window.location.hostname === "localhost") {
21
26
  return contributes(Capabilities.Null, null);
22
27
  }
23
28
  const { dispatch } = context.getCapability(Capabilities.IntentDispatcher);
24
29
  const action = Effect.gen(function* () {
25
30
  log.info("checking for updates", void 0, {
26
31
  F: __dxlog_file,
27
- L: 27,
32
+ L: 33,
28
33
  S: this,
29
34
  C: (f, a) => f(...a)
30
35
  });
@@ -34,14 +39,14 @@ var updater_default = (context) => {
34
39
  currentVersion: update?.currentVersion
35
40
  }, {
36
41
  F: __dxlog_file,
37
- L: 29,
42
+ L: 35,
38
43
  S: this,
39
44
  C: (f, a) => f(...a)
40
45
  });
41
46
  if (update) {
42
47
  log.info("update available", update, {
43
48
  F: __dxlog_file,
44
- L: 31,
49
+ L: 37,
45
50
  S: this,
46
51
  C: (f, a) => f(...a)
47
52
  });
@@ -55,7 +60,7 @@ var updater_default = (context) => {
55
60
  contentLength
56
61
  }, {
57
62
  F: __dxlog_file,
58
- L: 38,
63
+ L: 44,
59
64
  S: this,
60
65
  C: (f, a) => f(...a)
61
66
  });
@@ -63,12 +68,12 @@ var updater_default = (context) => {
63
68
  event: "Progress"
64
69
  }, (event) => {
65
70
  downloaded += event.data.chunkLength;
66
- log.info("download progress", {
71
+ log.verbose("download progress", {
67
72
  downloaded,
68
73
  contentLength
69
74
  }, {
70
75
  F: __dxlog_file,
71
- L: 42,
76
+ L: 48,
72
77
  S: this,
73
78
  C: (f, a) => f(...a)
74
79
  });
@@ -77,7 +82,7 @@ var updater_default = (context) => {
77
82
  }, () => {
78
83
  log.info("download completed", void 0, {
79
84
  F: __dxlog_file,
80
- L: 45,
85
+ L: 51,
81
86
  S: this,
82
87
  C: (f, a) => f(...a)
83
88
  });
@@ -86,30 +91,30 @@ var updater_default = (context) => {
86
91
  yield* dispatch(createIntent(LayoutAction.AddToast, {
87
92
  part: "toast",
88
93
  subject: {
89
- id: `${NATIVE_PLUGIN}/update-ready`,
94
+ id: `${meta.id}/update-ready`,
90
95
  title: [
91
96
  "update ready label",
92
97
  {
93
- ns: NATIVE_PLUGIN
98
+ ns: meta.id
94
99
  }
95
100
  ],
96
101
  description: [
97
102
  "update ready description",
98
103
  {
99
- ns: NATIVE_PLUGIN
104
+ ns: meta.id
100
105
  }
101
106
  ],
102
107
  duration: Infinity,
103
108
  actionLabel: [
104
109
  "update label",
105
110
  {
106
- ns: NATIVE_PLUGIN
111
+ ns: meta.id
107
112
  }
108
113
  ],
109
114
  actionAlt: [
110
115
  "update alt",
111
116
  {
112
- ns: NATIVE_PLUGIN
117
+ ns: meta.id
113
118
  }
114
119
  ],
115
120
  onAction: () => relaunch()
@@ -117,7 +122,7 @@ var updater_default = (context) => {
117
122
  }));
118
123
  }
119
124
  });
120
- const fiber = pipe(
125
+ const fiber = Function.pipe(
121
126
  // prettier-ignore
122
127
  action,
123
128
  Effect.repeat(Schedule.fixed(Duration.hours(1))),
@@ -126,8 +131,8 @@ var updater_default = (context) => {
126
131
  return contributes(Capabilities.Null, null, () => {
127
132
  Effect.runSync(Fiber.interrupt(fiber));
128
133
  });
129
- };
134
+ });
130
135
  export {
131
136
  updater_default as default
132
137
  };
133
- //# sourceMappingURL=updater-MCAQYHED.mjs.map
138
+ //# sourceMappingURL=updater-SDBPTCXA.mjs.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../../src/capabilities/updater.ts"],
4
+ "sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport { type } from '@tauri-apps/plugin-os';\nimport { relaunch } from '@tauri-apps/plugin-process';\nimport { type DownloadEvent, check } from '@tauri-apps/plugin-updater';\nimport * as Duration from 'effect/Duration';\nimport * as Effect from 'effect/Effect';\nimport * as Fiber from 'effect/Fiber';\nimport * as Function from 'effect/Function';\nimport * as Match from 'effect/Match';\nimport * as Schedule from 'effect/Schedule';\n\nimport { Capabilities, LayoutAction, type PluginContext, contributes, createIntent } from '@dxos/app-framework';\nimport { log } from '@dxos/log';\n\nimport { meta } from '../meta';\n\nconst SUPPORTS_OTA = ['linux', 'macos', 'windows'];\n\nexport default (context: PluginContext) => {\n // Skip updates if not supported or in dev mode.\n const platform = type();\n if (!SUPPORTS_OTA.includes(platform) || window.location.hostname === 'localhost') {\n return contributes(Capabilities.Null, null);\n }\n\n const { dispatch } = context.getCapability(Capabilities.IntentDispatcher);\n\n // https://tauri.app/plugin/updater/#checking-for-updates\n const action = Effect.gen(function* () {\n log.info('checking for updates');\n const update = yield* Effect.tryPromise(() => check());\n log.info('checked for updates', { version: update?.version, currentVersion: update?.currentVersion });\n if (update) {\n log.info('update available', update);\n let downloaded = 0;\n let contentLength = 0;\n\n const handleDownload = Match.type<DownloadEvent>().pipe(\n Match.when({ event: 'Started' }, (event) => {\n contentLength = event.data.contentLength ?? 0;\n log.info('download started', { contentLength });\n }),\n Match.when({ event: 'Progress' }, (event) => {\n downloaded += event.data.chunkLength;\n log.verbose('download progress', { downloaded, contentLength });\n }),\n Match.when({ event: 'Finished' }, () => {\n log.info('download completed');\n }),\n Match.exhaustive,\n );\n\n yield* Effect.tryPromise(() => update.downloadAndInstall(handleDownload));\n\n yield* dispatch(\n createIntent(LayoutAction.AddToast, {\n part: 'toast',\n subject: {\n id: `${meta.id}/update-ready`,\n title: ['update ready label', { ns: meta.id }],\n description: ['update ready description', { ns: meta.id }],\n duration: Infinity,\n actionLabel: ['update label', { ns: meta.id }],\n actionAlt: ['update alt', { ns: meta.id }],\n onAction: () => relaunch(),\n },\n }),\n );\n }\n });\n\n const fiber = Function.pipe(\n // prettier-ignore\n action,\n Effect.repeat(Schedule.fixed(Duration.hours(1))),\n Effect.runFork,\n );\n\n return contributes(Capabilities.Null, null, () => {\n Effect.runSync(Fiber.interrupt(fiber));\n });\n};\n"],
5
+ "mappings": ";;;;;AAIA,SAASA,YAAY;AACrB,SAASC,gBAAgB;AACzB,SAA6BC,aAAa;AAC1C,YAAYC,cAAc;AAC1B,YAAYC,YAAY;AACxB,YAAYC,WAAW;AACvB,YAAYC,cAAc;AAC1B,YAAYC,WAAW;AACvB,YAAYC,cAAc;AAE1B,SAASC,cAAcC,cAAkCC,aAAaC,oBAAoB;AAC1F,SAASC,WAAW;;AAIpB,IAAMC,eAAe;EAAC;EAAS;EAAS;;AAExC,IAAA,mBAAe,CAACC,YAAAA;AAEd,QAAMC,WAAWC,KAAAA;AACjB,MAAI,CAACH,aAAaI,SAASF,QAAAA,KAAaG,OAAOC,SAASC,aAAa,aAAa;AAChF,WAAOC,YAAYC,aAAaC,MAAM,IAAA;EACxC;AAEA,QAAM,EAAEC,SAAQ,IAAKV,QAAQW,cAAcH,aAAaI,gBAAgB;AAGxE,QAAMC,SAAgBC,WAAI,aAAA;AACxBC,QAAIC,KAAK,wBAAA,QAAA;;;;;;AACT,UAAMC,SAAS,OAAcC,kBAAW,MAAMC,MAAAA,CAAAA;AAC9CJ,QAAIC,KAAK,uBAAuB;MAAEI,SAASH,QAAQG;MAASC,gBAAgBJ,QAAQI;IAAe,GAAA;;;;;;AACnG,QAAIJ,QAAQ;AACVF,UAAIC,KAAK,oBAAoBC,QAAAA;;;;;;AAC7B,UAAIK,aAAa;AACjB,UAAIC,gBAAgB;AAEpB,YAAMC,iBAAuBtB,WAAI,EAAkBuB,KAC3CC,WAAK;QAAEC,OAAO;MAAU,GAAG,CAACA,UAAAA;AAChCJ,wBAAgBI,MAAMC,KAAKL,iBAAiB;AAC5CR,YAAIC,KAAK,oBAAoB;UAAEO;QAAc,GAAA;;;;;;MAC/C,CAAA,GACMG,WAAK;QAAEC,OAAO;MAAW,GAAG,CAACA,UAAAA;AACjCL,sBAAcK,MAAMC,KAAKC;AACzBd,YAAIe,QAAQ,qBAAqB;UAAER;UAAYC;QAAc,GAAA;;;;;;MAC/D,CAAA,GACMG,WAAK;QAAEC,OAAO;MAAW,GAAG,MAAA;AAChCZ,YAAIC,KAAK,sBAAA,QAAA;;;;;;MACX,CAAA,GACMe,gBAAU;AAGlB,aAAcb,kBAAW,MAAMD,OAAOe,mBAAmBR,cAAAA,CAAAA;AAEzD,aAAOd,SACLuB,aAAaC,aAAaC,UAAU;QAClCC,MAAM;QACNC,SAAS;UACPC,IAAI,GAAGC,KAAKD,EAAE;UACdE,OAAO;YAAC;YAAsB;cAAEC,IAAIF,KAAKD;YAAG;;UAC5CI,aAAa;YAAC;YAA4B;cAAED,IAAIF,KAAKD;YAAG;;UACxDK,UAAUC;UACVC,aAAa;YAAC;YAAgB;cAAEJ,IAAIF,KAAKD;YAAG;;UAC5CQ,WAAW;YAAC;YAAc;cAAEL,IAAIF,KAAKD;YAAG;;UACxCS,UAAU,MAAMC,SAAAA;QAClB;MACF,CAAA,CAAA;IAEJ;EACF,CAAA;AAEA,QAAMC,QAAiBxB;;IAErBZ;IACOqC,cAAgBC,eAAeC,eAAM,CAAA,CAAA,CAAA;IACrCC;EAAO;AAGhB,SAAO9C,YAAYC,aAAaC,MAAM,MAAM,MAAA;AAC1C6C,IAAOC,eAAcC,gBAAUP,KAAAA,CAAAA;EACjC,CAAA;AACF;",
6
+ "names": ["type", "relaunch", "check", "Duration", "Effect", "Fiber", "Function", "Match", "Schedule", "Capabilities", "LayoutAction", "contributes", "createIntent", "log", "SUPPORTS_OTA", "context", "platform", "type", "includes", "window", "location", "hostname", "contributes", "Capabilities", "Null", "dispatch", "getCapability", "IntentDispatcher", "action", "gen", "log", "info", "update", "tryPromise", "check", "version", "currentVersion", "downloaded", "contentLength", "handleDownload", "pipe", "when", "event", "data", "chunkLength", "verbose", "exhaustive", "downloadAndInstall", "createIntent", "LayoutAction", "AddToast", "part", "subject", "id", "meta", "title", "ns", "description", "duration", "Infinity", "actionLabel", "actionAlt", "onAction", "relaunch", "fiber", "repeat", "fixed", "hours", "runFork", "Effect", "runSync", "interrupt"]
7
+ }
@@ -1,7 +1,7 @@
1
1
  // src/capabilities/window.ts
2
2
  import { LogicalPosition, LogicalSize, getCurrentWindow } from "@tauri-apps/api/window";
3
3
  import { Capabilities, contributes } from "@dxos/app-framework";
4
- var window_default = (_context) => {
4
+ var window_default = ((_context) => {
5
5
  return contributes(Capabilities.Null, null, () => {
6
6
  const appWindow = getCurrentWindow();
7
7
  async function saveWindowState() {
@@ -27,8 +27,8 @@ var window_default = (_context) => {
27
27
  document.addEventListener("DOMContentLoaded", restoreWindowState);
28
28
  window.addEventListener("beforeunload", saveWindowState);
29
29
  });
30
- };
30
+ });
31
31
  export {
32
32
  window_default as default
33
33
  };
34
- //# sourceMappingURL=window-5EBHZJJ4.mjs.map
34
+ //# sourceMappingURL=window-6G542FZL.mjs.map
@@ -2,6 +2,6 @@
2
2
  "version": 3,
3
3
  "sources": ["../../../src/capabilities/window.ts"],
4
4
  "sourcesContent": ["//\n// Copyright 2025 DXOS.org\n//\n\nimport { LogicalPosition, LogicalSize, getCurrentWindow } from '@tauri-apps/api/window';\n\nimport { Capabilities, type PluginContext, contributes } from '@dxos/app-framework';\n\nexport default (_context: PluginContext) => {\n return contributes(Capabilities.Null, null, () => {\n const appWindow = getCurrentWindow();\n\n // Save window state to localStorage.\n async function saveWindowState() {\n const size = await appWindow.innerSize();\n const position = await appWindow.innerPosition();\n localStorage.setItem(\n 'windowState',\n JSON.stringify({\n width: size.width,\n height: size.height,\n x: position.x,\n y: position.y,\n }),\n );\n }\n\n // Restore window state from localStorage.\n async function restoreWindowState() {\n const savedState = localStorage.getItem('windowState');\n if (savedState) {\n const state = JSON.parse(savedState);\n\n await appWindow.setSize(new LogicalSize(state.width, state.height));\n await appWindow.setPosition(new LogicalPosition(state.x, state.y));\n }\n }\n\n // Listen for window events and save state.\n void appWindow.listen('tauri://resize', saveWindowState);\n void appWindow.listen('tauri://move', saveWindowState);\n\n // Restore state when app loads.\n document.addEventListener('DOMContentLoaded', restoreWindowState);\n\n // Save state before closing.\n window.addEventListener('beforeunload', saveWindowState);\n });\n};\n"],
5
- "mappings": ";AAIA,SAASA,iBAAiBC,aAAaC,wBAAwB;AAE/D,SAASC,cAAkCC,mBAAmB;AAE9D,IAAA,iBAAe,CAACC,aAAAA;AACd,SAAOC,YAAYC,aAAaC,MAAM,MAAM,MAAA;AAC1C,UAAMC,YAAYC,iBAAAA;AAGlB,mBAAeC,kBAAAA;AACb,YAAMC,OAAO,MAAMH,UAAUI,UAAS;AACtC,YAAMC,WAAW,MAAML,UAAUM,cAAa;AAC9CC,mBAAaC,QACX,eACAC,KAAKC,UAAU;QACbC,OAAOR,KAAKQ;QACZC,QAAQT,KAAKS;QACbC,GAAGR,SAASQ;QACZC,GAAGT,SAASS;MACd,CAAA,CAAA;IAEJ;AAGA,mBAAeC,qBAAAA;AACb,YAAMC,aAAaT,aAAaU,QAAQ,aAAA;AACxC,UAAID,YAAY;AACd,cAAME,QAAQT,KAAKU,MAAMH,UAAAA;AAEzB,cAAMhB,UAAUoB,QAAQ,IAAIC,YAAYH,MAAMP,OAAOO,MAAMN,MAAM,CAAA;AACjE,cAAMZ,UAAUsB,YAAY,IAAIC,gBAAgBL,MAAML,GAAGK,MAAMJ,CAAC,CAAA;MAClE;IACF;AAGA,SAAKd,UAAUwB,OAAO,kBAAkBtB,eAAAA;AACxC,SAAKF,UAAUwB,OAAO,gBAAgBtB,eAAAA;AAGtCuB,aAASC,iBAAiB,oBAAoBX,kBAAAA;AAG9CY,WAAOD,iBAAiB,gBAAgBxB,eAAAA;EAC1C,CAAA;AACF;",
5
+ "mappings": ";AAIA,SAASA,iBAAiBC,aAAaC,wBAAwB;AAE/D,SAASC,cAAkCC,mBAAmB;AAE9D,IAAA,kBAAe,CAACC,aAAAA;AACd,SAAOC,YAAYC,aAAaC,MAAM,MAAM,MAAA;AAC1C,UAAMC,YAAYC,iBAAAA;AAGlB,mBAAeC,kBAAAA;AACb,YAAMC,OAAO,MAAMH,UAAUI,UAAS;AACtC,YAAMC,WAAW,MAAML,UAAUM,cAAa;AAC9CC,mBAAaC,QACX,eACAC,KAAKC,UAAU;QACbC,OAAOR,KAAKQ;QACZC,QAAQT,KAAKS;QACbC,GAAGR,SAASQ;QACZC,GAAGT,SAASS;MACd,CAAA,CAAA;IAEJ;AAGA,mBAAeC,qBAAAA;AACb,YAAMC,aAAaT,aAAaU,QAAQ,aAAA;AACxC,UAAID,YAAY;AACd,cAAME,QAAQT,KAAKU,MAAMH,UAAAA;AAEzB,cAAMhB,UAAUoB,QAAQ,IAAIC,YAAYH,MAAMP,OAAOO,MAAMN,MAAM,CAAA;AACjE,cAAMZ,UAAUsB,YAAY,IAAIC,gBAAgBL,MAAML,GAAGK,MAAMJ,CAAC,CAAA;MAClE;IACF;AAGA,SAAKd,UAAUwB,OAAO,kBAAkBtB,eAAAA;AACxC,SAAKF,UAAUwB,OAAO,gBAAgBtB,eAAAA;AAGtCuB,aAASC,iBAAiB,oBAAoBX,kBAAAA;AAG9CY,WAAOD,iBAAiB,gBAAgBxB,eAAAA;EAC1C,CAAA;AACF;",
6
6
  "names": ["LogicalPosition", "LogicalSize", "getCurrentWindow", "Capabilities", "contributes", "_context", "contributes", "Capabilities", "Null", "appWindow", "getCurrentWindow", "saveWindowState", "size", "innerSize", "position", "innerPosition", "localStorage", "setItem", "JSON", "stringify", "width", "height", "x", "y", "restoreWindowState", "savedState", "getItem", "state", "parse", "setSize", "LogicalSize", "setPosition", "LogicalPosition", "listen", "document", "addEventListener", "window"]
7
7
  }
@@ -1,2 +1,2 @@
1
- export declare const NativePlugin: () => import("@dxos/app-framework").Plugin;
1
+ export declare const NativePlugin: import("@dxos/app-framework").PluginFactory<void>;
2
2
  //# sourceMappingURL=NativePlugin.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"NativePlugin.d.ts","sourceRoot":"","sources":["../../../src/NativePlugin.tsx"],"names":[],"mappings":"AAWA,eAAO,MAAM,YAAY,4CAsBrB,CAAC"}
1
+ {"version":3,"file":"NativePlugin.d.ts","sourceRoot":"","sources":["../../../src/NativePlugin.tsx"],"names":[],"mappings":"AAWA,eAAO,MAAM,YAAY,mDAqBvB,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"ollama.d.ts","sourceRoot":"","sources":["../../../../src/capabilities/ollama.ts"],"names":[],"mappings":"AASA,OAAO,EAAE,KAAK,UAAU,EAAE,KAAK,aAAa,EAAe,MAAM,qBAAqB,CAAC;yBAOvE,UAAU,aAAa,KAAG,UAAU,CAAC,GAAG,CAAC;AAAzD,wBAeE"}
1
+ {"version":3,"file":"ollama.d.ts","sourceRoot":"","sources":["../../../../src/capabilities/ollama.ts"],"names":[],"mappings":"AAaA,OAAO,EAAgB,KAAK,UAAU,EAAE,KAAK,aAAa,EAAe,MAAM,qBAAqB,CAAC;yBAMrF,UAAU,aAAa,KAAG,UAAU,CAAC,GAAG,CAAC;AAAzD,wBAeE"}
@@ -1 +1 @@
1
- {"version":3,"file":"updater.d.ts","sourceRoot":"","sources":["../../../../src/capabilities/updater.ts"],"names":[],"mappings":"AASA,OAAO,EAA8B,KAAK,aAAa,EAA6B,MAAM,qBAAqB,CAAC;yBAOhG,SAAS,aAAa;AAAtC,wBA8DE"}
1
+ {"version":3,"file":"updater.d.ts","sourceRoot":"","sources":["../../../../src/capabilities/updater.ts"],"names":[],"mappings":"AAcA,OAAO,EAA8B,KAAK,aAAa,EAA6B,MAAM,qBAAqB,CAAC;yBAOhG,SAAS,aAAa;AAAtC,wBA+DE"}
@@ -1,4 +1,3 @@
1
1
  import { type PluginMeta } from '@dxos/app-framework';
2
- export declare const NATIVE_PLUGIN = "dxos.org/plugin/native";
3
2
  export declare const meta: PluginMeta;
4
3
  //# sourceMappingURL=meta.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"meta.d.ts","sourceRoot":"","sources":["../../../src/meta.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,KAAK,UAAU,EAAE,MAAM,qBAAqB,CAAC;AAEtD,eAAO,MAAM,aAAa,2BAA2B,CAAC;AAEtD,eAAO,MAAM,IAAI,EAAE,UAGlB,CAAC"}
1
+ {"version":3,"file":"meta.d.ts","sourceRoot":"","sources":["../../../src/meta.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,KAAK,UAAU,EAAE,MAAM,qBAAqB,CAAC;AAGtD,eAAO,MAAM,IAAI,EAAE,UAOlB,CAAC"}