@bastani/atomic 0.10.5 → 0.10.6
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 +58 -0
- package/dist/THIRD_PARTY_NOTICES.md +1 -1
- package/dist/_shared/APEv2Parser-APXNTTFS.js.map +1 -1
- package/dist/_shared/AsfParser-AP272OWG.js +1 -1
- package/dist/_shared/DsfParser-FTOZZCZP.js +2 -2
- package/dist/_shared/FlacParser-WJATCQT6.js +2 -2
- package/dist/_shared/FlacParser-WJATCQT6.js.map +1 -1
- package/dist/_shared/ID3v1Parser-XVX6XPGB.js +1 -1
- package/dist/_shared/ID3v2Parser-DB2T4Z6M.js +2 -2
- package/dist/_shared/MP4Parser-2TZWZV4K.js +3 -3
- package/dist/_shared/MP4Parser-2TZWZV4K.js.map +1 -1
- package/dist/_shared/MatroskaParser-V22CGP72.js.map +1 -1
- package/dist/_shared/MusepackParser-XEUVYWNQ.js +2 -2
- package/dist/_shared/MusepackParser-XEUVYWNQ.js.map +1 -1
- package/dist/_shared/OggParser-Y7FSZNTO.js +1 -1
- package/dist/_shared/OggParser-Y7FSZNTO.js.map +1 -1
- package/dist/_shared/ParseError-VXOGXIIE.js +2 -2
- package/dist/_shared/ParseError-VXOGXIIE.js.map +1 -1
- package/dist/_shared/WavPackParser-ZYK4CLSW.js +1 -1
- package/dist/_shared/WaveParser-VA3P7P3H.js +2 -2
- package/dist/_shared/dist-KOELCESV.js +55 -63
- package/dist/_shared/dist-KOELCESV.js.map +1 -1
- package/dist/_shared/fork-row-index-UAUAQRD5.js +3 -3
- package/dist/_shared/full.umd-CBF7UGXV.js +7 -6
- package/dist/_shared/full.umd-CBF7UGXV.js.map +1 -1
- package/dist/_shared/http-YFAPTIZD.js +2 -2
- package/dist/_shared/http-YFAPTIZD.js.map +1 -1
- package/dist/_shared/http-undici-FVPTZA4G.js +19 -20
- package/dist/_shared/http-undici-FVPTZA4G.js.map +1 -1
- package/dist/_shared/lib-4PES5P4V.js +8 -8
- package/dist/_shared/lib-4PES5P4V.js.map +1 -1
- package/dist/_shared/mode-interactive-sdk-7KXUFI2F.js +5 -4
- package/dist/_shared/mode-interactive-sdk-7KXUFI2F.js.map +1 -1
- package/dist/_shared/mode-rpc-sdk-IOPGDYR4.js +20 -20
- package/dist/_shared/mode-rpc-sdk-IOPGDYR4.js.map +1 -1
- package/dist/_shared/mode-shared-2QJSCUM6.js +441 -341
- package/dist/_shared/mode-shared-2QJSCUM6.js.map +1 -1
- package/dist/_shared/p0-cli-BB45ZQY6.js +8 -12
- package/dist/_shared/p0-cli-BB45ZQY6.js.map +1 -1
- package/dist/_shared/p1a-prewarm-UQY3X2UK.js +8 -8
- package/dist/_shared/p1b-elig-ENCUPKKJ.js +17 -17
- package/dist/_shared/p1b-elig-ENCUPKKJ.js.map +1 -1
- package/dist/_shared/p2-shell-TJBYQMCJ.js +27 -28
- package/dist/_shared/p2-shell-TJBYQMCJ.js.map +1 -1
- package/dist/_shared/p2-shell-main-B2WIALFD.js +44 -47
- package/dist/_shared/p2-shell-main-B2WIALFD.js.map +1 -1
- package/dist/_shared/rolldown-runtime-BGM3D5V3.js +4 -4
- package/dist/_shared/runtime-O4KCSG4C.js +7 -7
- package/dist/_shared/runtime-O4KCSG4C.js.map +1 -1
- package/dist/_shared/sdk-WQIOHVKO.js +24 -24
- package/dist/_shared/sdk-WQIOHVKO.js.map +1 -1
- package/dist/_shared/session-data-AHTU7IS6.js +4 -4
- package/dist/_shared/session-manager-list-2BLEEZVG.js +3 -3
- package/dist/_shared/{settings-startup-65YEWRV2.js → settings-startup-4QCVCI53.js} +2 -32
- package/dist/_shared/settings-startup-4QCVCI53.js.map +1 -0
- package/dist/_shared/settings-startup-8-DNZ2RIHM.js +35 -0
- package/dist/_shared/settings-startup-8-DNZ2RIHM.js.map +1 -0
- package/dist/_shared/sql-session-store-5FD3WBMZ.js +12 -12
- package/dist/_shared/startup-0-0-TYUFUOJZ.js +143 -115
- package/dist/_shared/startup-0-0-TYUFUOJZ.js.map +1 -1
- package/dist/_shared/{startup-0-1-D4LGGINF.js → startup-0-1-W2G2UY7R.js} +365 -27
- package/dist/_shared/startup-0-1-W2G2UY7R.js.map +1 -0
- package/dist/_shared/startup-0-2-SZGQIWHI.js +19 -24
- package/dist/_shared/startup-0-2-SZGQIWHI.js.map +1 -1
- package/dist/_shared/startup-0-3-T4DVFYWX.js +7 -7
- package/dist/_shared/startup-0-3-T4DVFYWX.js.map +1 -1
- package/dist/_shared/startup-0-4-HN5EB4K7.js +7 -7
- package/dist/_shared/startup-0-4-HN5EB4K7.js.map +1 -1
- package/dist/_shared/startup-0-5-OHJNE6JH.js +157 -92
- package/dist/_shared/startup-0-5-OHJNE6JH.js.map +1 -1
- package/dist/_shared/startup-10-0-TDQNBDDL.js +4 -4
- package/dist/_shared/startup-10-0-TDQNBDDL.js.map +1 -1
- package/dist/_shared/startup-14-0-MLX36RBG.js +19 -19
- package/dist/_shared/startup-14-0-MLX36RBG.js.map +1 -1
- package/dist/_shared/startup-15-0-YUKGAC63.js +17 -16
- package/dist/_shared/startup-15-0-YUKGAC63.js.map +1 -1
- package/dist/_shared/startup-15-1-4S7FLMNG.js +5 -5
- package/dist/_shared/startup-15-1-4S7FLMNG.js.map +1 -1
- package/dist/_shared/startup-8-0-34CBHPZH.js +23 -23
- package/dist/_shared/startup-8-0-34CBHPZH.js.map +1 -1
- package/dist/_shared/startup-8-1-SJW2GMAM.js +113 -114
- package/dist/_shared/startup-8-1-SJW2GMAM.js.map +1 -1
- package/dist/_shared/storage-command-7MGXLJGZ.js +15 -14
- package/dist/_shared/storage-command-7MGXLJGZ.js.map +1 -1
- package/dist/_shared/task-reference-stream-JWMUZSJX.js +7 -7
- package/dist/_shared/task-reference-stream-JWMUZSJX.js.map +1 -1
- package/dist/_shared/task-unsaved-answer-VJ2KTB4V.js +2 -2
- package/dist/_shared/tree-outline-MUEPK5B7.js +4 -4
- package/dist/_shared/turndown.cjs-7Z43JOED.js +7 -10
- package/dist/_shared/turndown.cjs-7Z43JOED.js.map +1 -1
- package/dist/builtin/intercom/CHANGELOG.md +12 -0
- package/dist/builtin/intercom/index.bundle.mjs +2 -2
- package/dist/builtin/intercom/package.json +1 -1
- package/dist/builtin/mcp/index.bundle.mjs +1 -1
- package/dist/builtin/mcp/package.json +1 -1
- package/dist/builtin/subagents/CHANGELOG.md +12 -0
- package/dist/builtin/subagents/package.json +1 -1
- package/dist/builtin/subagents/src/extension/index.bundle.mjs +15 -12
- package/dist/builtin/web-access/index.bundle.mjs +1 -1
- package/dist/builtin/web-access/package.json +1 -1
- package/dist/cli/args.js +1 -1
- package/dist/cli/auth-cli.code.js +10 -13
- package/dist/cli/auth-cli.code.js.map +1 -1
- package/dist/cli/auth-cli.impl.js +3 -3
- package/dist/cli/auth-cli.js +3 -3
- package/dist/cli/blueprint-command.code.js +8 -8
- package/dist/cli/blueprint-command.impl.js +3 -3
- package/dist/cli/blueprint-command.js +3 -3
- package/dist/cli/intercom-command.code.js +2 -2
- package/dist/cli/intercom-command.impl.js +3 -3
- package/dist/cli/intercom-command.js +3 -3
- package/dist/cli/list-models.code.js +3 -3
- package/dist/cli/list-models.impl.js +3 -3
- package/dist/cli/list-models.js +3 -3
- package/dist/cli/session-picker.code.js +3 -3
- package/dist/cli/session-picker.impl.js +3 -3
- package/dist/cli/session-picker.js +3 -3
- package/dist/cli/settings-startup.js +1 -1
- package/dist/cli/startup-ui.impl.js +3 -3
- package/dist/cli/startup-ui.js +3 -3
- package/dist/cli/storage-command.impl.js +3 -3
- package/dist/cli/storage-command.js +3 -3
- package/dist/cli/storage-search-session.code.js +4 -4
- package/dist/cli/storage-search-session.impl.js +3 -3
- package/dist/cli/storage-search-session.js +3 -3
- package/dist/cli/team-command.code.js +3 -3
- package/dist/cli/team-command.impl.js +3 -3
- package/dist/cli/team-command.js +3 -3
- package/dist/cli.js +2 -2
- package/dist/cli.js.map +1 -1
- package/dist/core/debug.impl.js +3 -3
- package/dist/core/debug.js +3 -3
- package/dist/core/export-html/card-projection.code.js +2 -2
- package/dist/core/export-html/card-projection.code.js.map +1 -1
- package/dist/core/export-html/card-projection.impl.js +3 -3
- package/dist/core/export-html/card-projection.js +3 -3
- package/dist/core/export-html/index.code.js +9 -9
- package/dist/core/export-html/index.code.js.map +1 -1
- package/dist/core/export-html/index.impl.js +3 -3
- package/dist/core/export-html/index.js +3 -3
- package/dist/core/export-html/json-spans.impl.js +3 -3
- package/dist/core/export-html/json-spans.js +3 -3
- package/dist/core/export-html/oversized-render-inputs.code.js +1 -1
- package/dist/core/export-html/oversized-render-inputs.impl.js +3 -3
- package/dist/core/export-html/oversized-render-inputs.js +3 -3
- package/dist/core/export-html/tool-renderer.code.js +1 -1
- package/dist/core/export-html/tool-renderer.impl.js +3 -3
- package/dist/core/export-html/tool-renderer.js +3 -3
- package/dist/core/extensions/jiti-loader.impl.js +3 -3
- package/dist/core/extensions/jiti-loader.js +3 -3
- package/dist/core/extensions/jiti-static-loader.impl.js +3 -3
- package/dist/core/extensions/jiti-static-loader.js +3 -3
- package/dist/core/extensions/loader-host-modules.code.js +1 -1
- package/dist/core/extensions/loader-host-modules.impl.js +3 -3
- package/dist/core/extensions/loader-host-modules.js +3 -3
- package/dist/core/extensions/loader-virtual-modules.js +1 -1
- package/dist/core/extensions/runner-context.js +5 -5
- package/dist/core/extensions/runner-context.js.map +1 -1
- package/dist/core/http-dispatcher.js +2 -0
- package/dist/core/intercom-broker-control-host.impl.js +3 -3
- package/dist/core/intercom-broker-control-host.js +3 -3
- package/dist/core/intercom-broker-control.code.js +3 -3
- package/dist/core/intercom-broker-control.impl.js +3 -3
- package/dist/core/intercom-broker-control.js +3 -3
- package/dist/core/package-manager-storage-adapters.impl.js +3 -3
- package/dist/core/package-manager-storage-adapters.js +3 -3
- package/dist/core/sdk.code.js +1 -1
- package/dist/core/sdk.impl.js +3 -3
- package/dist/core/sdk.js +3 -3
- package/dist/core/session-manager-core.js +15 -15
- package/dist/core/session-manager-core.js.map +1 -1
- package/dist/core/session-manager-list.impl.js +3 -3
- package/dist/core/session-manager-list.js +3 -3
- package/dist/core/session-manager.code.js +1 -1
- package/dist/core/session-manager.impl.js +3 -3
- package/dist/core/session-manager.js +3 -3
- package/dist/core/session-storage.impl.js +3 -3
- package/dist/core/session-storage.js +3 -3
- package/dist/core/storage/index.js +2 -2
- package/dist/core/storage/node-sqlite-thread.js +2 -2
- package/dist/core/storage/node-sqlite.js +2 -2
- package/dist/core/storage/offline-snapshot-file.code.js +1 -1
- package/dist/core/storage/offline-snapshot-file.impl.js +3 -3
- package/dist/core/storage/offline-snapshot-file.js +3 -3
- package/dist/core/storage/provider.js +2 -2
- package/dist/core/storage/selection.js +2 -2
- package/dist/core/storage/session/branch-fork-source.code.js +3 -3
- package/dist/core/storage/session/branch-fork-source.impl.js +3 -3
- package/dist/core/storage/session/branch-fork-source.js +3 -3
- package/dist/core/storage/session/card-view.impl.js +3 -3
- package/dist/core/storage/session/card-view.js +3 -3
- package/dist/core/storage/session/child-reader.code.js +5 -4
- package/dist/core/storage/session/child-reader.code.js.map +1 -1
- package/dist/core/storage/session/child-reader.impl.js +3 -3
- package/dist/core/storage/session/child-reader.js +3 -3
- package/dist/core/storage/session/chunked-resume-projection.impl.js +3 -3
- package/dist/core/storage/session/chunked-resume-projection.js +3 -3
- package/dist/core/storage/session/errors.js +1 -0
- package/dist/core/storage/session/errors.js.map +1 -1
- package/dist/core/storage/session/expanded-child-details.code.js +4 -4
- package/dist/core/storage/session/expanded-child-details.impl.js +3 -3
- package/dist/core/storage/session/expanded-child-details.js +3 -3
- package/dist/core/storage/session/fork-row-bytes.impl.js +3 -3
- package/dist/core/storage/session/fork-row-bytes.js +3 -3
- package/dist/core/storage/session/fork-row-index.impl.js +3 -3
- package/dist/core/storage/session/fork-row-index.js +3 -3
- package/dist/core/storage/session/fork-staging.code.js +5 -4
- package/dist/core/storage/session/fork-staging.code.js.map +1 -1
- package/dist/core/storage/session/fork-staging.impl.js +3 -3
- package/dist/core/storage/session/fork-staging.js +3 -3
- package/dist/core/storage/session/fork-window.code.js +3 -3
- package/dist/core/storage/session/fork-window.impl.js +3 -3
- package/dist/core/storage/session/fork-window.js +3 -3
- package/dist/core/storage/session/history-pages.impl.js +3 -3
- package/dist/core/storage/session/history-pages.js +3 -3
- package/dist/core/storage/session/jsonl-entry-projection.impl.js +3 -3
- package/dist/core/storage/session/jsonl-entry-projection.js +3 -3
- package/dist/core/storage/session/jsonl-session-store.impl.js +3 -3
- package/dist/core/storage/session/jsonl-session-store.js +3 -3
- package/dist/core/storage/session/memory-session-store.impl.js +3 -3
- package/dist/core/storage/session/memory-session-store.js +3 -3
- package/dist/core/storage/session/pinned-branch-resume.code.js +2 -2
- package/dist/core/storage/session/pinned-branch-resume.impl.js +3 -3
- package/dist/core/storage/session/pinned-branch-resume.js +3 -3
- package/dist/core/storage/session/released-history-files.code.js +12 -12
- package/dist/core/storage/session/released-history-files.code.js.map +1 -1
- package/dist/core/storage/session/released-history-files.impl.js +3 -3
- package/dist/core/storage/session/released-history-files.js +3 -3
- package/dist/core/storage/session/resident-fork-rows.code.js +1 -1
- package/dist/core/storage/session/resident-fork-rows.impl.js +3 -3
- package/dist/core/storage/session/resident-fork-rows.js +3 -3
- package/dist/core/storage/session/session-resume.impl.js +3 -3
- package/dist/core/storage/session/session-resume.js +3 -3
- package/dist/core/storage/session/snapshot-cut.impl.js +3 -3
- package/dist/core/storage/session/snapshot-cut.js +3 -3
- package/dist/core/storage/session/snapshot-history.code.js +3 -3
- package/dist/core/storage/session/snapshot-history.impl.js +3 -3
- package/dist/core/storage/session/snapshot-history.js +3 -3
- package/dist/core/storage/session/sql-session-store.impl.js +3 -3
- package/dist/core/storage/session/sql-session-store.js +3 -3
- package/dist/core/storage/session/tree-outline.impl.js +3 -3
- package/dist/core/storage/session/tree-outline.js +3 -3
- package/dist/core/storage/session/tree-presentation.impl.js +3 -3
- package/dist/core/storage/session/tree-presentation.js +3 -3
- package/dist/core/storage/storage-status.impl.js +3 -3
- package/dist/core/storage/storage-status.js +3 -3
- package/dist/core/storage/team.impl.js +3 -3
- package/dist/core/storage/team.js +3 -3
- package/dist/core/structured-output/index.impl.js +3 -3
- package/dist/core/structured-output/index.js +3 -3
- package/dist/core/tasks/task-completion-entry.impl.js +3 -3
- package/dist/core/tasks/task-completion-entry.js +3 -3
- package/dist/core/tasks/task-file-history.code.js +5 -5
- package/dist/core/tasks/task-file-history.code.js.map +1 -1
- package/dist/core/tasks/task-file-history.impl.js +3 -3
- package/dist/core/tasks/task-file-history.js +3 -3
- package/dist/core/tasks/task-reference-archive.code.js +11 -11
- package/dist/core/tasks/task-reference-archive.code.js.map +1 -1
- package/dist/core/tasks/task-reference-archive.js +3 -3
- package/dist/core/tasks/task-reference-identity.code.js +2 -2
- package/dist/core/tasks/task-reference-identity.js +3 -3
- package/dist/core/tasks/task-reference-stream.impl.js +3 -3
- package/dist/core/tasks/task-reference-stream.js +3 -3
- package/dist/core/tasks/task-unsaved-answer.impl.js +3 -3
- package/dist/core/tasks/task-unsaved-answer.js +3 -3
- package/dist/core/tasks/task-view-source.impl.js +3 -3
- package/dist/core/tasks/task-view-source.js +3 -3
- package/dist/core/tools/read-url.code.js +9 -9
- package/dist/core/tools/read-url.impl.js +3 -3
- package/dist/core/tools/read-url.js +3 -3
- package/dist/core/worktree-snapshot/blob-store.js +2 -2
- package/dist/core/worktree-snapshot/errors.code.js +1 -1
- package/dist/core/worktree-snapshot/errors.impl.js +3 -3
- package/dist/core/worktree-snapshot/errors.js +3 -3
- package/dist/core/worktree-snapshot/session-index-reset.impl.js +3 -3
- package/dist/core/worktree-snapshot/session-index-reset.js +3 -3
- package/dist/extensions/codemode/execute.code.js +3 -3
- package/dist/extensions/codemode/execute.impl.js +3 -3
- package/dist/extensions/codemode/execute.js +3 -3
- package/dist/extensions/codemode/renderer.code.js +1 -1
- package/dist/extensions/codemode/renderer.impl.js +3 -3
- package/dist/extensions/codemode/renderer.js +3 -3
- package/dist/extensions/mcp/cli.code.js +7 -7
- package/dist/extensions/mcp/cli.impl.js +3 -3
- package/dist/extensions/mcp/cli.js +3 -3
- package/dist/extensions/mcp/cli.lazy.code.js +2 -2
- package/dist/extensions/mcp/cli.lazy.impl.js +3 -3
- package/dist/extensions/mcp/cli.lazy.js +3 -3
- package/dist/extensions/mcp/runtime.impl.js +3 -3
- package/dist/extensions/mcp/runtime.js +3 -3
- package/dist/index.js +2 -2
- package/dist/main-first-time-setup.impl.js +3 -3
- package/dist/main-first-time-setup.js +3 -3
- package/dist/modes/interactive/components/stored-tree-view.code.js +2 -2
- package/dist/modes/interactive/components/stored-tree-view.impl.js +3 -3
- package/dist/modes/interactive/components/stored-tree-view.js +3 -3
- package/dist/modes/interactive/components/task-inspector.d.ts +10 -2
- package/dist/modes/interactive/components/user-message-selector-archive.impl.js +3 -3
- package/dist/modes/interactive/components/user-message-selector-archive.js +3 -3
- package/dist/package-manager-cli.code.js +14 -14
- package/dist/package-manager-cli.impl.js +3 -3
- package/dist/package-manager-cli.js +3 -3
- package/dist/rpc-entry.js +3 -3
- package/dist/startup-files.json +1 -1
- package/dist/startup-stages/7.js +1 -1
- package/dist/utils/startup-database-spare.code.js +5 -5
- package/dist/utils/startup-database-spare.impl.js +3 -3
- package/dist/utils/startup-database-spare.js +3 -3
- package/dist/utils/tools-manager.code.js +1 -1
- package/dist/utils/tools-manager.impl.js +3 -3
- package/dist/utils/tools-manager.js +3 -3
- package/docs/background-tasks.md +2 -2
- package/package.json +9 -9
- package/dist/_shared/settings-startup-65YEWRV2.js.map +0 -1
- package/dist/_shared/startup-0-1-D4LGGINF.js.map +0 -1
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import
|
|
1
|
+
import "./rolldown-runtime-BGM3D5V3.js";
|
|
2
2
|
import { ENV_TIMING, createModuleRequire, getAgentDir, getCustomThemesDir, getEnvValue, getThemesDir, stripBom } from "./p0-cli-BB45ZQY6.js";
|
|
3
3
|
import { readFile, realpath } from "node:fs/promises";
|
|
4
4
|
import { existsSync, readFileSync } from "fs";
|
|
5
|
-
import * as path
|
|
5
|
+
import * as path from "path";
|
|
6
6
|
import { join } from "path";
|
|
7
|
-
import * as path$
|
|
7
|
+
import * as path$1 from "node:path";
|
|
8
8
|
import { dirname as dirname$1, resolve as resolve$1 } from "node:path";
|
|
9
|
-
import * as fs$
|
|
9
|
+
import * as fs$1 from "node:fs";
|
|
10
10
|
import { realpathSync as realpathSync$1, watch } from "node:fs";
|
|
11
|
-
import { KeybindingsManager, TUI_KEYBINDINGS, clickableHintText, clickableKeyTextHint, clickableKeysHint, colorToHex, colorToOkhsl, colorToOklch, colorToRgb, getKeybindings, hintKeyParts, hintKeyParts as hintKeyParts$1, okhslColor, oklabToOkhslLightness, oklchColor, parseColor, rgbColor, slashCommandHint, truncateToWidth, visibleWidth } from "@bastani/atomic-tui";
|
|
11
|
+
import { KeybindingsManager as KeybindingsManager$1, TUI_KEYBINDINGS, clickableHintText, clickableKeyTextHint, clickableKeysHint, colorToHex, colorToOkhsl, colorToOklch, colorToRgb, getKeybindings, hintKeyParts, hintKeyParts as hintKeyParts$1, okhslColor, oklabToOkhslLightness, oklchColor, parseColor, rgbColor, slashCommandHint, truncateToWidth, visibleWidth } from "@bastani/atomic-tui";
|
|
12
12
|
import { Chalk } from "chalk";
|
|
13
13
|
import { access as access$1, readFile as readFile$1 } from "fs/promises";
|
|
14
14
|
import { memoizeAsync } from "../utils/memoize-async.js";
|
|
@@ -399,10 +399,7 @@ function parseRawConfig(content) {
|
|
|
399
399
|
const parsed = JSON.parse(stripBom(content));
|
|
400
400
|
return isRecord(parsed) ? parsed : void 0;
|
|
401
401
|
}
|
|
402
|
-
var KeybindingsManager
|
|
403
|
-
static {
|
|
404
|
-
__name(this, "KeybindingsManager");
|
|
405
|
-
}
|
|
402
|
+
var KeybindingsManager = class KeybindingsManager extends KeybindingsManager$1 {
|
|
406
403
|
configPath;
|
|
407
404
|
constructor(userBindings = {}, configPath) {
|
|
408
405
|
super(KEYBINDINGS, userBindings);
|
|
@@ -410,22 +407,22 @@ var KeybindingsManager$1 = class KeybindingsManager$1 extends KeybindingsManager
|
|
|
410
407
|
}
|
|
411
408
|
static create(agentDir = getAgentDir()) {
|
|
412
409
|
const configPath = join(agentDir, "keybindings.json");
|
|
413
|
-
const userBindings = KeybindingsManager
|
|
414
|
-
return new KeybindingsManager
|
|
410
|
+
const userBindings = KeybindingsManager.loadFromFile(configPath);
|
|
411
|
+
return new KeybindingsManager(userBindings, configPath);
|
|
415
412
|
}
|
|
416
413
|
reload() {
|
|
417
414
|
if (!this.configPath) return;
|
|
418
|
-
this.setUserBindings(KeybindingsManager
|
|
415
|
+
this.setUserBindings(KeybindingsManager.loadFromFile(this.configPath));
|
|
419
416
|
}
|
|
420
417
|
async reloadAsync() {
|
|
421
418
|
if (!this.configPath) return;
|
|
422
|
-
this.setUserBindings(KeybindingsManager
|
|
419
|
+
this.setUserBindings(KeybindingsManager.toUserBindings(await loadRawConfigAsync(this.configPath)));
|
|
423
420
|
}
|
|
424
421
|
getEffectiveConfig() {
|
|
425
422
|
return this.getResolvedBindings();
|
|
426
423
|
}
|
|
427
424
|
static loadFromFile(path) {
|
|
428
|
-
return KeybindingsManager
|
|
425
|
+
return KeybindingsManager.toUserBindings(loadRawConfig(path));
|
|
429
426
|
}
|
|
430
427
|
static toUserBindings(rawConfig) {
|
|
431
428
|
if (!rawConfig) return {};
|
|
@@ -943,7 +940,7 @@ const CUBE_VALUES = [
|
|
|
943
940
|
];
|
|
944
941
|
const GRAY_VALUES = Array.from({ length: 24 }, (_, i) => 8 + i * 10);
|
|
945
942
|
function findClosestCubeIndex(value) {
|
|
946
|
-
let minDist =
|
|
943
|
+
let minDist = 1e400;
|
|
947
944
|
let minIdx = 0;
|
|
948
945
|
for (let i = 0; i < CUBE_VALUES.length; i++) {
|
|
949
946
|
const dist = Math.abs(value - CUBE_VALUES[i]);
|
|
@@ -955,7 +952,7 @@ function findClosestCubeIndex(value) {
|
|
|
955
952
|
return minIdx;
|
|
956
953
|
}
|
|
957
954
|
function findClosestGrayIndex(r, g, b) {
|
|
958
|
-
let minDist =
|
|
955
|
+
let minDist = 1e400;
|
|
959
956
|
let minIdx = 0;
|
|
960
957
|
for (let i = 0; i < GRAY_VALUES.length; i++) {
|
|
961
958
|
const value = GRAY_VALUES[i];
|
|
@@ -1005,7 +1002,7 @@ function strongestChannels(r, g, b) {
|
|
|
1005
1002
|
}
|
|
1006
1003
|
function rgbTo256PreservingHue(r, g, b) {
|
|
1007
1004
|
const channels = strongestChannels(r, g, b);
|
|
1008
|
-
let minDist =
|
|
1005
|
+
let minDist = 1e400;
|
|
1009
1006
|
let minIndex = 16;
|
|
1010
1007
|
for (const entry of PALETTE_256) {
|
|
1011
1008
|
if (strongestChannels(entry.r, entry.g, entry.b) !== channels) continue;
|
|
@@ -2870,10 +2867,10 @@ function loadedBuiltinThemes() {
|
|
|
2870
2867
|
function readBuiltinThemes() {
|
|
2871
2868
|
const themesDir = getThemesDir();
|
|
2872
2869
|
const themes = {};
|
|
2873
|
-
for (const file of fs$
|
|
2870
|
+
for (const file of fs$1.readdirSync(themesDir).sort()) {
|
|
2874
2871
|
if (!file.endsWith(".json")) continue;
|
|
2875
|
-
const themePath = path$
|
|
2876
|
-
const themeJson = parseThemeJsonContent(themePath, fs$
|
|
2872
|
+
const themePath = path$1.join(themesDir, file);
|
|
2873
|
+
const themeJson = parseThemeJsonContent(themePath, fs$1.readFileSync(themePath, "utf-8"));
|
|
2877
2874
|
themes[themeJson.name] = themeJson;
|
|
2878
2875
|
}
|
|
2879
2876
|
return {
|
|
@@ -2893,17 +2890,17 @@ function readCustomThemeFiles(customThemesDir) {
|
|
|
2893
2890
|
const files = /* @__PURE__ */ new Map();
|
|
2894
2891
|
let entries;
|
|
2895
2892
|
try {
|
|
2896
|
-
entries = fs$
|
|
2893
|
+
entries = fs$1.readdirSync(customThemesDir);
|
|
2897
2894
|
} catch {
|
|
2898
2895
|
return files;
|
|
2899
2896
|
}
|
|
2900
2897
|
for (const file of entries) {
|
|
2901
2898
|
if (!file.endsWith(".json")) continue;
|
|
2902
|
-
const themePath = path$
|
|
2899
|
+
const themePath = path$1.join(customThemesDir, file);
|
|
2903
2900
|
try {
|
|
2904
2901
|
files.set(file, {
|
|
2905
2902
|
path: themePath,
|
|
2906
|
-
content: fs$
|
|
2903
|
+
content: fs$1.readFileSync(themePath, "utf-8")
|
|
2907
2904
|
});
|
|
2908
2905
|
} catch {}
|
|
2909
2906
|
}
|
|
@@ -2918,15 +2915,15 @@ async function refreshCustomThemes() {
|
|
|
2918
2915
|
const files = /* @__PURE__ */ new Map();
|
|
2919
2916
|
let entries = [];
|
|
2920
2917
|
try {
|
|
2921
|
-
entries = await fs$
|
|
2918
|
+
entries = await fs$1.promises.readdir(customThemesDir);
|
|
2922
2919
|
} catch {}
|
|
2923
2920
|
for (const file of entries) {
|
|
2924
2921
|
if (!file.endsWith(".json")) continue;
|
|
2925
|
-
const themePath = path$
|
|
2922
|
+
const themePath = path$1.join(customThemesDir, file);
|
|
2926
2923
|
try {
|
|
2927
2924
|
files.set(file, {
|
|
2928
2925
|
path: themePath,
|
|
2929
|
-
content: await fs$
|
|
2926
|
+
content: await fs$1.promises.readFile(themePath, "utf-8")
|
|
2930
2927
|
});
|
|
2931
2928
|
} catch {}
|
|
2932
2929
|
}
|
|
@@ -2938,7 +2935,7 @@ async function refreshCustomThemes() {
|
|
|
2938
2935
|
function hasCustomThemeFile(name) {
|
|
2939
2936
|
const fileName = `${name}.json`;
|
|
2940
2937
|
if (getCustomThemeFiles().has(fileName)) return true;
|
|
2941
|
-
return registeredThemes.get(name)?.sourcePath === path$
|
|
2938
|
+
return registeredThemes.get(name)?.sourcePath === path$1.join(getCustomThemesDir(), fileName);
|
|
2942
2939
|
}
|
|
2943
2940
|
function getAvailableThemes() {
|
|
2944
2941
|
return getAvailableThemesWithPaths().map(({ name }) => name);
|
|
@@ -2958,7 +2955,7 @@ function getAvailableThemesWithPaths() {
|
|
|
2958
2955
|
});
|
|
2959
2956
|
for (const name of Object.keys(builtinThemes.themes)) addTheme({
|
|
2960
2957
|
name,
|
|
2961
|
-
path: path$
|
|
2958
|
+
path: path$1.join(builtinThemes.directory, `${name}.json`)
|
|
2962
2959
|
});
|
|
2963
2960
|
for (const info of getCustomThemeInfos()) addTheme(info);
|
|
2964
2961
|
for (const [name, theme] of registeredThemes.entries()) addTheme({
|
|
@@ -3117,13 +3114,13 @@ function startThemeWatcher() {
|
|
|
3117
3114
|
const customThemesDir = getCustomThemesDir();
|
|
3118
3115
|
const watchedThemeName = currentThemeName;
|
|
3119
3116
|
const watchedFileName = `${watchedThemeName}.json`;
|
|
3120
|
-
const themeFile = path$
|
|
3117
|
+
const themeFile = path$1.join(customThemesDir, watchedFileName);
|
|
3121
3118
|
const generation = themeWatcherGeneration;
|
|
3122
3119
|
if (!hasCustomThemeFile(watchedThemeName)) return;
|
|
3123
3120
|
const reload = async () => {
|
|
3124
3121
|
let content;
|
|
3125
3122
|
try {
|
|
3126
|
-
content = await fs$
|
|
3123
|
+
content = await fs$1.promises.readFile(themeFile, "utf-8");
|
|
3127
3124
|
} catch {
|
|
3128
3125
|
return;
|
|
3129
3126
|
}
|
|
@@ -3150,7 +3147,7 @@ function startThemeWatcher() {
|
|
|
3150
3147
|
themeWatchFileListener = (current, previous) => {
|
|
3151
3148
|
if (current.mtimeMs !== previous.mtimeMs || current.ctimeMs !== previous.ctimeMs || current.size !== previous.size) scheduleReload();
|
|
3152
3149
|
};
|
|
3153
|
-
fs$
|
|
3150
|
+
fs$1.watchFile(themeFile, { interval: 1e3 }, themeWatchFileListener);
|
|
3154
3151
|
};
|
|
3155
3152
|
let failed = false;
|
|
3156
3153
|
watchWithErrorHandlerAsync(customThemesDir, (_eventType, filename) => {
|
|
@@ -3183,7 +3180,7 @@ function stopThemeWatcher() {
|
|
|
3183
3180
|
}
|
|
3184
3181
|
closeWatcher(themeWatcher);
|
|
3185
3182
|
themeWatcher = void 0;
|
|
3186
|
-
if (themeWatchFilePath && themeWatchFileListener) fs$
|
|
3183
|
+
if (themeWatchFilePath && themeWatchFileListener) fs$1.unwatchFile(themeWatchFilePath, themeWatchFileListener);
|
|
3187
3184
|
themeWatchFilePath = void 0;
|
|
3188
3185
|
themeWatchFileListener = void 0;
|
|
3189
3186
|
}
|
|
@@ -3778,7 +3775,7 @@ function navEntryKeys(keybindings, entry, taken) {
|
|
|
3778
3775
|
}
|
|
3779
3776
|
/** {@link navEntryKeys} split by key, each part with the key a click on it presses. */
|
|
3780
3777
|
function navEntryKeyParts(keybindings, entry, taken) {
|
|
3781
|
-
if (entry.action === void 0) return hintKeyParts(entry.keys ?? "");
|
|
3778
|
+
if (entry.action === void 0) return hintKeyParts$1(entry.keys ?? "");
|
|
3782
3779
|
const keys = (keybindings?.getKeys?.(entry.action) ?? []).filter((key) => !taken?.has(key));
|
|
3783
3780
|
for (const key of keys) taken?.add(key);
|
|
3784
3781
|
return boundKeyParts(keys);
|
|
@@ -4132,7 +4129,7 @@ function getSettingsListTheme() {
|
|
|
4132
4129
|
label: (text, selected) => selected ? theme.fg("accent", text) : text,
|
|
4133
4130
|
value: (text, selected) => selected ? theme.fg("accent", text) : theme.fg("muted", text),
|
|
4134
4131
|
description: (text) => theme.fg("dim", text),
|
|
4135
|
-
cursor: theme.fg("accent", "
|
|
4132
|
+
cursor: theme.fg("accent", theme.bold("∀ ")),
|
|
4136
4133
|
hint: (text) => theme.fg("dim", text)
|
|
4137
4134
|
};
|
|
4138
4135
|
}
|
|
@@ -4247,7 +4244,7 @@ function parenthesizedKeyHint(keybinding, description, prefix) {
|
|
|
4247
4244
|
}
|
|
4248
4245
|
/** A hint for a key that is not a keybinding, such as `↑↓ navigate`. A click on a key's text presses that key. */
|
|
4249
4246
|
function rawKeyHint(key, description) {
|
|
4250
|
-
const parts = hintKeyParts
|
|
4247
|
+
const parts = hintKeyParts(formatKeyText(key)).map((part) => ({
|
|
4251
4248
|
...part,
|
|
4252
4249
|
text: theme.fg("dim", part.text)
|
|
4253
4250
|
}));
|
|
@@ -4256,8 +4253,8 @@ function rawKeyHint(key, description) {
|
|
|
4256
4253
|
// dist/utils/photon.js
|
|
4257
4254
|
const __atomicDistModuleUrl = new URL("../utils/photon.js", import.meta.url).href;
|
|
4258
4255
|
const requireFromHere = createRequire(__atomicDistModuleUrl);
|
|
4259
|
-
const fs
|
|
4260
|
-
const unpatchedReadFile = fs
|
|
4256
|
+
const fs = requireFromHere("fs");
|
|
4257
|
+
const unpatchedReadFile = fs.readFileSync.bind(fs);
|
|
4261
4258
|
const WASM_FILENAME = "photon_rs_bg.wasm";
|
|
4262
4259
|
function pathOrNull(file) {
|
|
4263
4260
|
if (typeof file === "string") return file;
|
|
@@ -4265,18 +4262,18 @@ function pathOrNull(file) {
|
|
|
4265
4262
|
return null;
|
|
4266
4263
|
}
|
|
4267
4264
|
function getFallbackWasmPaths() {
|
|
4268
|
-
const execDir = path
|
|
4265
|
+
const execDir = path.dirname(process.execPath);
|
|
4269
4266
|
return [
|
|
4270
|
-
path
|
|
4271
|
-
path
|
|
4272
|
-
path
|
|
4267
|
+
path.join(execDir, WASM_FILENAME),
|
|
4268
|
+
path.join(execDir, "photon", WASM_FILENAME),
|
|
4269
|
+
path.join(process.cwd(), WASM_FILENAME)
|
|
4273
4270
|
];
|
|
4274
4271
|
}
|
|
4275
4272
|
function getCandidateWasmPaths() {
|
|
4276
4273
|
const candidates = [];
|
|
4277
4274
|
try {
|
|
4278
4275
|
const entryPath = requireFromHere.resolve("@silvia-odwyer/photon-node");
|
|
4279
|
-
candidates.push(path
|
|
4276
|
+
candidates.push(path.join(path.dirname(entryPath), WASM_FILENAME));
|
|
4280
4277
|
} catch {}
|
|
4281
4278
|
candidates.push(...getFallbackWasmPaths());
|
|
4282
4279
|
return candidates;
|
|
@@ -4305,9 +4302,9 @@ function installPhotonWasmRead(wasmBytes) {
|
|
|
4305
4302
|
return unpatchedReadFile(...args);
|
|
4306
4303
|
};
|
|
4307
4304
|
try {
|
|
4308
|
-
fs
|
|
4305
|
+
fs.readFileSync = interceptedReadFile;
|
|
4309
4306
|
} catch {
|
|
4310
|
-
Object.defineProperty(fs
|
|
4307
|
+
Object.defineProperty(fs, "readFileSync", {
|
|
4311
4308
|
value: interceptedReadFile,
|
|
4312
4309
|
writable: true,
|
|
4313
4310
|
configurable: true
|
|
@@ -4315,9 +4312,9 @@ function installPhotonWasmRead(wasmBytes) {
|
|
|
4315
4312
|
}
|
|
4316
4313
|
return () => {
|
|
4317
4314
|
try {
|
|
4318
|
-
fs
|
|
4315
|
+
fs.readFileSync = unpatchedReadFile;
|
|
4319
4316
|
} catch {
|
|
4320
|
-
Object.defineProperty(fs
|
|
4317
|
+
Object.defineProperty(fs, "readFileSync", {
|
|
4321
4318
|
value: unpatchedReadFile,
|
|
4322
4319
|
writable: true,
|
|
4323
4320
|
configurable: true
|
|
@@ -4554,6 +4551,6 @@ function keybindingIdentity(key) {
|
|
|
4554
4551
|
"super"
|
|
4555
4552
|
].filter((modifier) => parts.includes(modifier)), canonicalBase].join("+");
|
|
4556
4553
|
}
|
|
4557
|
-
export { CodeHighlighter, FS_WATCH_RETRY_DELAY_MS, KEYBINDINGS, KeybindingsManager
|
|
4554
|
+
export { CodeHighlighter, FS_WATCH_RETRY_DELAY_MS, KEYBINDINGS, KeybindingsManager, NAV_CONFIRM_WINDOW_MS, OVERLAY_ACTIVE_ROW_MARKER, SAFE_FS_WATCH_CANONICALIZATION_FAILED, SAFE_FS_WATCH_UNSAFE_WINDOWS_SHORT_PATH, SYSTEM_THEME_NAME, TerminalTextSanitizer, Theme, TwoPressConfirm, ansi256ToHex, applyEarlyInputChunk, clickableHintText, clickableKeyTextHint, closeWatcher, colorEnvironment, consumeStartupInput, detectTerminalThemeForAuto, endTimingSpan, fgAnsi, formatKeyText, getAvailableThemes, getAvailableThemesWithPaths, getCurrentThemeName, getEditorTheme, getGlobalTheme, getLanguageFromPath, getMarkdownTheme, getResolvedThemeColors, getSelectListTheme, getSettingsListTheme, getTerminalTheme, getThemeByName, getThemeExportColors, graphemeAt, hexColorAnsi, hexToRgb, highlightCode, hintKeyParts, initTheme, isLightTheme, isNavHelpKey, isSafeFsWatchPathError, isUnsafeWindowsShortPath, keepStartupDialogDraft, keyDisplayText, keyHint, keyHintIfBound, keyText, keyTextHint, keybindingIdentity, linkStartupShell, loadAllHighlightLanguages, loadPhoton, loadThemeFromContent, markTerminalColorsPending, migrateKeybindingsConfig, navActionText, navEntryKeyParts, navEntryKeys, navFirstKeyText, navKeyText, onThemeChange, parenthesizedKeyHint, parseAutoThemeSetting, printTimings, rawKeyHint, recordTimeSinceReset, recordTimingLines, refreshCustomThemes, renderAutocompleteHintLine, renderNavHintLine, renderNavKeyOverlay, resetTimings, resolveColorMode, resolveNativeWatchPath, resolveThemeSetting, sanitizeTerminalText, setRegisteredThemes, setTerminalColorScheme, setTerminalColors, setTheme, setThemeInstance, singleLineDisplayText, slashCommandHint, startEarlyInputCapture, startTimingSpan, stopThemeWatcher, stripOsc133Marks, stripOverlayActiveRowMarker, terminalDisplayCursor, terminalDisplayText, theme, time, watchWithErrorHandler, watchWithErrorHandlerAsync, withEarlyInputHeldForStartupDialog };
|
|
4558
4555
|
|
|
4559
4556
|
//# sourceMappingURL=p2-shell-main-B2WIALFD.js.map
|