diff --git a/apps/desktop/src/app/DesktopAppActivation.ts b/apps/desktop/src/app/DesktopAppActivation.ts index f63fdffedaef54e65079d8750ea9a94fcaa9ce0e..ba00ecbf0ee38bc94dbb1bdf8d647713cc3e27cc 100644 --- a/apps/desktop/src/app/DesktopAppActivation.ts +++ b/apps/desktop/src/app/DesktopAppActivation.ts @@ -213,6 +213,7 @@ export class DesktopAppActivation extends Context.Service< const { logWarning } = makeComponentLogger("desktop-app-activation"); +/** @public Service construction is part of the canonical Effect module API. */ export const make = Effect.gen(function* () { const desktopEnvironment = yield* DesktopEnvironment.DesktopEnvironment; const desktopWindow = yield* DesktopWindow.DesktopWindow; diff --git a/apps/desktop/src/app/DesktopAppIdentity.ts b/apps/desktop/src/app/DesktopAppIdentity.ts index c5adb8574a53a421cb4916e12b350d052338cbfb..9df14250f1aafb246d13027cb8b79b4dee8e288a 100644 --- a/apps/desktop/src/app/DesktopAppIdentity.ts +++ b/apps/desktop/src/app/DesktopAppIdentity.ts @@ -66,6 +66,7 @@ export const resolveUserDataPath = Effect.gen(function* () { : environment.path.join(environment.appDataDirectory, environment.userDataDirName); }).pipe(Effect.withSpan("desktop.appIdentity.resolveUserDataPath")); +/** @public Service construction is part of the canonical Effect module API. */ export const make = Effect.gen(function* () { const assets = yield* DesktopAssets.DesktopAssets; const electronApp = yield* ElectronApp.ElectronApp; diff --git a/apps/desktop/src/app/DesktopAssets.ts b/apps/desktop/src/app/DesktopAssets.ts index f1c6f1bb8f1f26cde0e23fb065d8d7725adfeac3..9abb013d0f764eaa2ee93496b6a27ce20b8f017c 100644 --- a/apps/desktop/src/app/DesktopAssets.ts +++ b/apps/desktop/src/app/DesktopAssets.ts @@ -119,6 +119,7 @@ const resolveIconPath = Effect.fn("desktop.assets.resolveIconPath")(function* ( return yield* resolveResourcePath(`icon.${ext}`); }); +/** @public Service construction is part of the canonical Effect module API. */ export const make = Effect.gen(function* () { const context = yield* Effect.context< FileSystem.FileSystem | DesktopEnvironment.DesktopEnvironment diff --git a/apps/desktop/src/app/DesktopClerk.ts b/apps/desktop/src/app/DesktopClerk.ts index d3c99e5e1d24f8f5fae681c733bfa49647ced8c6..57a042ca17718afefee2b8e1180fd131a6922f77 100644 --- a/apps/desktop/src/app/DesktopClerk.ts +++ b/apps/desktop/src/app/DesktopClerk.ts @@ -83,6 +83,7 @@ function createDesktopClerkBridge(stateDir: string, isDevelopment: boolean) { }); } +/** @public Service construction is part of the canonical Effect module API. */ export const make = Effect.gen(function* () { const environment = yield* DesktopEnvironment.DesktopEnvironment; const electronApp = yield* ElectronApp.ElectronApp; diff --git a/apps/desktop/src/app/DesktopConnectionCatalogStore.ts b/apps/desktop/src/app/DesktopConnectionCatalogStore.ts index 5ec2edb595ff7f52a8b56afe6ab7013f93b0f4a6..e94af7c16b3981141ec2bc7167a4030740635ec5 100644 --- a/apps/desktop/src/app/DesktopConnectionCatalogStore.ts +++ b/apps/desktop/src/app/DesktopConnectionCatalogStore.ts @@ -375,6 +375,7 @@ const migrateSavedEnvironmentRecords = Effect.fn( }; }); +/** @public Service construction is part of the canonical Effect module API. */ export const make = Effect.gen(function* () { const environment = yield* DesktopEnvironment.DesktopEnvironment; const fileSystem = yield* FileSystem.FileSystem; diff --git a/apps/desktop/src/app/DesktopLifecycle.ts b/apps/desktop/src/app/DesktopLifecycle.ts index 0a0cc6dca9339be96851961fd34467997d374029..6c7008a58ee235d4499987d2c5a7f33cf9a3a7eb 100644 --- a/apps/desktop/src/app/DesktopLifecycle.ts +++ b/apps/desktop/src/app/DesktopLifecycle.ts @@ -159,6 +159,7 @@ function quitFromSignal( ); } +/** @public Service construction is part of the canonical Effect module API. */ export const make = DesktopLifecycle.of({ relaunch: Effect.fn("desktop.lifecycle.relaunch")(function* (reason) { const electronApp = yield* ElectronApp.ElectronApp; diff --git a/apps/desktop/src/app/DesktopLinuxUrlHandler.ts b/apps/desktop/src/app/DesktopLinuxUrlHandler.ts index e531a54dfce6b60a67f8b51a82ed05a3bc45f563..626bf00eced4011779d6dcadd25135f7fe0d6dcd 100644 --- a/apps/desktop/src/app/DesktopLinuxUrlHandler.ts +++ b/apps/desktop/src/app/DesktopLinuxUrlHandler.ts @@ -20,7 +20,7 @@ import { makeComponentLogger } from "./DesktopObservability.ts"; // our own handler entry pointing at the current AppImage and claim the // scheme default via xdg-mime, exactly what the file manager's "set as // default" checkbox would record in mimeapps.list. -export const URL_HANDLER_DESKTOP_ENTRY_NAME = "t3code-url-handler.desktop"; +const URL_HANDLER_DESKTOP_ENTRY_NAME = "t3code-url-handler.desktop"; const { logInfo, logWarning } = makeComponentLogger("desktop-linux-url-handler"); @@ -92,6 +92,7 @@ export class DesktopLinuxUrlHandler extends Context.Service< } >()("@t3tools/desktop/app/DesktopLinuxUrlHandler") {} +/** @public Service construction is part of the canonical Effect module API. */ export const make = Effect.gen(function* () { const environment = yield* DesktopEnvironment.DesktopEnvironment; const fileSystem = yield* FileSystem.FileSystem; diff --git a/apps/desktop/src/app/DesktopPreReadyPlatform.ts b/apps/desktop/src/app/DesktopPreReadyPlatform.ts index 718f541150650356d729926bb3779ac7c8cd3462..151d754fa2f1758ce4aa06c6717b950fbbad29fe 100644 --- a/apps/desktop/src/app/DesktopPreReadyPlatform.ts +++ b/apps/desktop/src/app/DesktopPreReadyPlatform.ts @@ -46,6 +46,7 @@ export class DesktopPreReadyElectronOptions extends Context.Service< } >()("@t3tools/desktop/app/DesktopPreReadyPlatform/DesktopPreReadyElectronOptions") {} +/** @public Service construction is part of the canonical Effect module API. */ export const make = Effect.gen(function* () { const platform = yield* HostProcessPlatform; return yield* Effect.sync((): DesktopPreReadyElectronOptions["Service"] => { diff --git a/apps/desktop/src/shell/DesktopShellEnvironment.ts b/apps/desktop/src/shell/DesktopShellEnvironment.ts index b4610eee5c84749513c837af31decf66ea20cfc7..90ad739dbedc83d272e7f7d5bc70a3b61f2727ed 100644 --- a/apps/desktop/src/shell/DesktopShellEnvironment.ts +++ b/apps/desktop/src/shell/DesktopShellEnvironment.ts @@ -533,6 +533,7 @@ const installShellEnvironment = ( return Effect.void; }; +/** @public Service construction is part of the canonical Effect module API. */ export const make = Effect.gen(function* () { const environment = yield* DesktopEnvironment.DesktopEnvironment; const fileSystem = yield* FileSystem.FileSystem; diff --git a/apps/desktop/src/ssh/DesktopSshEnvironment.ts b/apps/desktop/src/ssh/DesktopSshEnvironment.ts index 2c9ab0c03e4882127a34d23e9a30f8ef68f3cabb..3b135eb2508f01bca53fc0246b14763a30993034 100644 --- a/apps/desktop/src/ssh/DesktopSshEnvironment.ts +++ b/apps/desktop/src/ssh/DesktopSshEnvironment.ts @@ -128,6 +128,7 @@ const makePasswordPrompt = ( prompts.request(request).pipe(Effect.mapError(toSshPasswordPromptError)), }); +/** @public Service construction is part of the canonical Effect module API. */ export const make = Effect.gen(function* () { const manager = yield* SshTunnel.SshEnvironmentManager; const prompts = yield* DesktopSshPasswordPrompts.DesktopSshPasswordPrompts; diff --git a/apps/desktop/src/ssh/DesktopSshPasswordPrompts.ts b/apps/desktop/src/ssh/DesktopSshPasswordPrompts.ts index aa25d8135c7a9a964f909d47e21213a2a111eb69..31baabc6c3544a5d71aac970e68e38beebbf9b38 100644 --- a/apps/desktop/src/ssh/DesktopSshPasswordPrompts.ts +++ b/apps/desktop/src/ssh/DesktopSshPasswordPrompts.ts @@ -222,6 +222,7 @@ const failPending = ( error: DesktopSshPasswordPromptRequestError, ) => Deferred.fail(pending.deferred, error).pipe(Effect.asVoid); +/** @public Service construction is part of the canonical Effect module API. */ export const make = Effect.fn("desktop.sshPasswordPrompts.make")(function* ( options: DesktopSshPasswordPromptsOptions = {}, ) { diff --git a/apps/desktop/src/updates/DesktopUpdates.ts b/apps/desktop/src/updates/DesktopUpdates.ts index 344d135a10247af394d0eb395ce4802d507ef145..a78a20b11b965a053c36f0b931aa2bbf07daf59e 100644 --- a/apps/desktop/src/updates/DesktopUpdates.ts +++ b/apps/desktop/src/updates/DesktopUpdates.ts @@ -271,6 +271,7 @@ function isArm64HostRunningIntelBuild(runtimeInfo: DesktopRuntimeInfo): boolean return runtimeInfo.hostArch === "arm64" && runtimeInfo.appArch === "x64"; } +/** @public Service construction is part of the canonical Effect module API. */ export const make = Effect.gen(function* () { const config = yield* DesktopConfig.DesktopConfig; const pool = yield* DesktopBackendPool.DesktopBackendPool; diff --git a/apps/desktop/src/updates/remoteUpdateFlow.ts b/apps/desktop/src/updates/remoteUpdateFlow.ts index 50b077313330e85947bd0fc3663e55eceb5e5638..20043ba22cca30c0263521db5da597215b1c0ebe 100644 --- a/apps/desktop/src/updates/remoteUpdateFlow.ts +++ b/apps/desktop/src/updates/remoteUpdateFlow.ts @@ -31,7 +31,7 @@ export const MAX_REMOTE_UPDATE_CHECKS = 2; export const MAX_REMOTE_UPDATE_DOWNLOADS = 3; /** Same predicate DesktopUpdates.installDownloadedUpdate uses for admission. */ -export function isInstallableDesktopUpdateState(state: DesktopUpdateState): boolean { +function isInstallableDesktopUpdateState(state: DesktopUpdateState): boolean { return ( state.downloadedVersion !== null && (state.status === "downloaded" || diff --git a/apps/desktop/src/updates/updateMachine.ts b/apps/desktop/src/updates/updateMachine.ts index 2e9ed5199a3e32a35ab138155c1eec1c08dc7be6..85d8782ea66887a5748e4dfed9b40a497557ecd6 100644 --- a/apps/desktop/src/updates/updateMachine.ts +++ b/apps/desktop/src/updates/updateMachine.ts @@ -5,13 +5,13 @@ import type { DesktopUpdateState, } from "@t3tools/contracts"; -export function nextStatusAfterDownloadFailure( +function nextStatusAfterDownloadFailure( currentState: DesktopUpdateState, ): DesktopUpdateState["status"] { return currentState.availableVersion ? "available" : "error"; } -export function getCanRetryAfterDownloadFailure(currentState: DesktopUpdateState): boolean { +function getCanRetryAfterDownloadFailure(currentState: DesktopUpdateState): boolean { return currentState.availableVersion !== null; } diff --git a/apps/desktop/src/window/DesktopApplicationMenu.ts b/apps/desktop/src/window/DesktopApplicationMenu.ts index 66244534debf42812d757bdcc46fcb4844fdc6b0..3ef9318bd4a5f0abee966e11eeeb15960969ec92 100644 --- a/apps/desktop/src/window/DesktopApplicationMenu.ts +++ b/apps/desktop/src/window/DesktopApplicationMenu.ts @@ -103,6 +103,7 @@ const handleCheckForUpdatesMenuClick = Effect.gen(function* () { yield* checkForUpdatesFromMenu; }).pipe(Effect.withSpan("desktop.menu.handleCheckForUpdatesClick")); +/** @public Service construction is part of the canonical Effect module API. */ export const make = Effect.gen(function* () { const electronApp = yield* ElectronApp.ElectronApp; const electronMenu = yield* ElectronMenu.ElectronMenu; diff --git a/apps/desktop/src/window/DesktopWindow.ts b/apps/desktop/src/window/DesktopWindow.ts index d87c74428a99426048f599b6c393a8cae8694ce5..f4c8debb8b1a28ac58413381d03833d9e82ea23a 100644 --- a/apps/desktop/src/window/DesktopWindow.ts +++ b/apps/desktop/src/window/DesktopWindow.ts @@ -278,6 +278,7 @@ function bindFirstRevealTrigger( } } +/** @public Service construction is part of the canonical Effect module API. */ export const make = Effect.gen(function* () { const environment = yield* DesktopEnvironment.DesktopEnvironment; const assets = yield* DesktopAssets.DesktopAssets;