@celljs/ta-web 4.9.0 → 4.9.1
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/README.en.md +1 -1
- package/README.md +1 -1
- package/esm/browser/assistant/assistant-extension.js +13 -5
- package/esm/browser/assistant/assistant-task-source.d.ts +2 -0
- package/esm/browser/assistant/assistant-task-source.js +2 -0
- package/esm/browser/assistant/assistant-task-util.d.ts +6 -0
- package/esm/browser/assistant/assistant-task-util.js +8 -0
- package/esm/browser/assistant/assistant-tasks.js +3 -2
- package/esm/browser/assistant/assistant.d.ts +20 -0
- package/esm/browser/assistant/assistant.js +45 -1
- package/esm/browser/assistant/task-views.d.ts +40 -6
- package/esm/browser/assistant/task-views.js +73 -21
- package/esm/browser/avatar/dino-avatar.d.ts +3 -4
- package/esm/browser/avatar/dino-avatar.js +4 -178
- package/esm/browser/avatar/dino-face.d.ts +19 -0
- package/esm/browser/avatar/dino-face.js +142 -0
- package/esm/browser/avatar/dino-geometry.d.ts +11 -0
- package/esm/browser/avatar/dino-geometry.js +38 -0
- package/esm/browser/avatar/dino-kinds.d.ts +15 -0
- package/esm/browser/avatar/dino-kinds.js +544 -0
- package/esm/browser/avatar/dino-motion.js +1 -1
- package/esm/browser/avatar/dino-shape.d.ts +80 -0
- package/esm/browser/avatar/dino-shape.js +113 -0
- package/esm/browser/avatar/dino-species.d.ts +1 -61
- package/esm/browser/avatar/dino-species.js +2 -653
- package/esm/browser/components/access-view.js +1 -1
- package/esm/browser/components/account-menu.js +1 -1
- package/esm/browser/components/app-shell-hooks.d.ts +47 -0
- package/esm/browser/components/app-shell-hooks.js +165 -0
- package/esm/browser/components/app-view.js +6 -151
- package/esm/browser/components/auth-view.js +1 -1
- package/esm/browser/components/composer.js +17 -10
- package/esm/browser/components/dino.js +1 -1
- package/esm/browser/components/folder-picker.js +4 -1
- package/esm/browser/components/host-view.d.ts +1 -1
- package/esm/browser/components/host-view.js +1 -1
- package/esm/browser/components/select-bar.d.ts +9 -0
- package/esm/browser/components/select-bar.js +24 -0
- package/esm/browser/components/settings-choices.d.ts +35 -0
- package/esm/browser/components/settings-choices.js +117 -0
- package/esm/browser/components/settings-parts.d.ts +21 -0
- package/esm/browser/components/settings-parts.js +300 -0
- package/esm/browser/components/settings-view.d.ts +0 -6
- package/esm/browser/components/settings-view.js +4 -406
- package/esm/browser/components/workbench-view.js +1 -1
- package/esm/browser/extension/icons.js +2 -1
- package/esm/browser/extension/web-extension-api.d.ts +38 -1
- package/esm/browser/extension/web-extensions.js +6 -1
- package/esm/browser/extension/web-tasks.d.ts +9 -1
- package/esm/browser/extension/web-tasks.js +24 -0
- package/esm/browser/hooks.d.ts +3 -1
- package/esm/browser/hooks.js +8 -0
- package/esm/browser/i18n/locales.d.ts +6 -1
- package/esm/browser/i18n/messages.d.ts +5 -0
- package/esm/browser/i18n/messages.js +10 -0
- package/esm/browser/style/device.js +16 -0
- package/esm/browser/style/shell.d.ts +1 -1
- package/esm/browser/style/shell.js +1 -0
- package/esm/browser/style/tasks.d.ts +1 -1
- package/esm/browser/style/tasks.js +2 -0
- package/esm/browser/workbench-util.d.ts +61 -0
- package/esm/browser/workbench-util.js +138 -0
- package/esm/browser/workbench.d.ts +1 -37
- package/esm/browser/workbench.js +2 -136
- package/lib/browser/assistant/assistant-extension.js +13 -5
- package/lib/browser/assistant/assistant-task-source.d.ts +2 -0
- package/lib/browser/assistant/assistant-task-source.js +2 -0
- package/lib/browser/assistant/assistant-task-util.d.ts +6 -0
- package/lib/browser/assistant/assistant-task-util.js +8 -0
- package/lib/browser/assistant/assistant-tasks.js +2 -1
- package/lib/browser/assistant/assistant.d.ts +20 -0
- package/lib/browser/assistant/assistant.js +45 -1
- package/lib/browser/assistant/task-views.d.ts +40 -6
- package/lib/browser/assistant/task-views.js +74 -21
- package/lib/browser/avatar/dino-avatar.d.ts +3 -4
- package/lib/browser/avatar/dino-avatar.js +27 -202
- package/lib/browser/avatar/dino-face.d.ts +20 -0
- package/lib/browser/avatar/dino-face.js +148 -0
- package/lib/browser/avatar/dino-geometry.d.ts +12 -0
- package/lib/browser/avatar/dino-geometry.js +47 -0
- package/lib/browser/avatar/dino-kinds.d.ts +16 -0
- package/lib/browser/avatar/dino-kinds.js +547 -0
- package/lib/browser/avatar/dino-motion.js +2 -2
- package/lib/browser/avatar/dino-shape.d.ts +81 -0
- package/lib/browser/avatar/dino-shape.js +126 -0
- package/lib/browser/avatar/dino-species.d.ts +1 -61
- package/lib/browser/avatar/dino-species.js +34 -687
- package/lib/browser/components/access-view.js +2 -2
- package/lib/browser/components/account-menu.js +2 -2
- package/lib/browser/components/app-shell-hooks.d.ts +48 -0
- package/lib/browser/components/app-shell-hooks.js +207 -0
- package/lib/browser/components/app-view.js +16 -161
- package/lib/browser/components/auth-view.js +3 -3
- package/lib/browser/components/composer.js +17 -10
- package/lib/browser/components/dino.js +3 -3
- package/lib/browser/components/folder-picker.js +4 -1
- package/lib/browser/components/host-view.d.ts +1 -1
- package/lib/browser/components/host-view.js +5 -5
- package/lib/browser/components/select-bar.d.ts +10 -0
- package/lib/browser/components/select-bar.js +61 -0
- package/lib/browser/components/settings-choices.d.ts +36 -0
- package/lib/browser/components/settings-choices.js +156 -0
- package/lib/browser/components/settings-parts.d.ts +22 -0
- package/lib/browser/components/settings-parts.js +336 -0
- package/lib/browser/components/settings-view.d.ts +0 -6
- package/lib/browser/components/settings-view.js +2 -405
- package/lib/browser/components/workbench-view.js +3 -3
- package/lib/browser/extension/icons.js +1 -0
- package/lib/browser/extension/web-extension-api.d.ts +38 -1
- package/lib/browser/extension/web-extensions.js +5 -0
- package/lib/browser/extension/web-tasks.d.ts +9 -1
- package/lib/browser/extension/web-tasks.js +24 -0
- package/lib/browser/hooks.d.ts +3 -1
- package/lib/browser/hooks.js +9 -0
- package/lib/browser/i18n/locales.d.ts +6 -1
- package/lib/browser/i18n/messages.d.ts +5 -0
- package/lib/browser/i18n/messages.js +10 -0
- package/lib/browser/style/device.js +16 -0
- package/lib/browser/style/shell.d.ts +1 -1
- package/lib/browser/style/shell.js +1 -0
- package/lib/browser/style/tasks.d.ts +1 -1
- package/lib/browser/style/tasks.js +2 -0
- package/lib/browser/workbench-util.d.ts +62 -0
- package/lib/browser/workbench-util.js +144 -0
- package/lib/browser/workbench.d.ts +1 -37
- package/lib/browser/workbench.js +24 -159
- package/package.json +7 -7
|
@@ -37,16 +37,16 @@ exports.DINO_GREEN = void 0;
|
|
|
37
37
|
exports.Dino = Dino;
|
|
38
38
|
exports.dinoFavicon = dinoFavicon;
|
|
39
39
|
const React = __importStar(require("react"));
|
|
40
|
-
const
|
|
40
|
+
const dino_shape_1 = require("../avatar/dino-shape");
|
|
41
41
|
exports.DINO_GREEN = '#10B981';
|
|
42
42
|
/** Cell's dinosaur as assets/logo.svg draws it: the mark of ta. */
|
|
43
43
|
function Dino({ size = 32 }) {
|
|
44
44
|
return (React.createElement("svg", { width: size, height: size, viewBox: "0 0 256 256", "aria-label": "ta", role: "img" },
|
|
45
|
-
React.createElement("path", { d:
|
|
45
|
+
React.createElement("path", { d: dino_shape_1.LOGO_PATH, fill: exports.DINO_GREEN, fillRule: "evenodd" })));
|
|
46
46
|
}
|
|
47
47
|
/** The same picture as the icon of the tab. */
|
|
48
48
|
function dinoFavicon() {
|
|
49
|
-
const svg = `<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256"><path d="${
|
|
49
|
+
const svg = `<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 256 256"><path d="${dino_shape_1.LOGO_PATH}" fill="${exports.DINO_GREEN}" fill-rule="evenodd"/></svg>`;
|
|
50
50
|
return `data:image/svg+xml,${encodeURIComponent(svg)}`;
|
|
51
51
|
}
|
|
52
52
|
//# sourceMappingURL=dino.js.map
|
|
@@ -41,6 +41,7 @@ const ta_protocol_1 = require("@celljs/ta-protocol");
|
|
|
41
41
|
const lucide_react_1 = require("lucide-react");
|
|
42
42
|
const React = __importStar(require("react"));
|
|
43
43
|
const react_dom_1 = require("react-dom");
|
|
44
|
+
const device_1 = require("../device/device");
|
|
44
45
|
const use_t_1 = require("../i18n/use-t");
|
|
45
46
|
const message_1 = require("../util/message");
|
|
46
47
|
const empty_state_1 = require("./empty-state");
|
|
@@ -152,6 +153,8 @@ function Machines({ host, hosts, onPick }) {
|
|
|
152
153
|
function FolderPicker({ list, initial, onPick, onClose, remote: bench }) {
|
|
153
154
|
var _a;
|
|
154
155
|
const t = (0, use_t_1.useT)();
|
|
156
|
+
// On a touch screen the keyboard would cover the folders: the user goes folder by folder there.
|
|
157
|
+
const touch = (0, device_1.useDevice)(device => device.touch);
|
|
155
158
|
const [path, setPath] = React.useState(initial);
|
|
156
159
|
const [input, setInput] = React.useState(ta_protocol_1.TaLocation.path(initial));
|
|
157
160
|
const [folders, setFolders] = React.useState();
|
|
@@ -225,7 +228,7 @@ function FolderPicker({ list, initial, onPick, onClose, remote: bench }) {
|
|
|
225
228
|
} },
|
|
226
229
|
React.createElement(icon_1.IconButton, { icon: lucide_react_1.CornerLeftUp, label: t('ta.folder.up'), disabled: !up, onClick: () => up && go(up) }),
|
|
227
230
|
React.createElement("label", { className: "ta-field ta-field-small" },
|
|
228
|
-
React.createElement("input", { autoFocus:
|
|
231
|
+
React.createElement("input", { autoFocus: !touch, spellCheck: false, value: input, "aria-label": t('ta.folder.path'), title: t('ta.folder.path'), onChange: event => setInput(event.target.value) }))),
|
|
229
232
|
React.createElement("ul", { className: "ta-folder-list" },
|
|
230
233
|
(folders === undefined || (loading && connecting)) && !failed && (React.createElement("li", { className: "ta-folder-note" },
|
|
231
234
|
React.createElement("span", { className: "ta-spinner" }),
|
|
@@ -4,7 +4,7 @@ import type { SavedHost } from '../workbench-protocol';
|
|
|
4
4
|
/** Adding a computer by its code or link: what the sign-in and the sheet of the computers share. */
|
|
5
5
|
export declare function useAddHost(): {
|
|
6
6
|
busy: boolean;
|
|
7
|
-
error: "ta.access.add" | "ta.access.addHint" | "ta.access.added" | "ta.access.allow" | "ta.access.bind" | "ta.access.bindHint" | "ta.access.browser" | "ta.access.dismiss" | "ta.access.fromEnv" | "ta.access.lastUsed" | "ta.access.none" | "ta.access.noneHint" | "ta.access.remove" | "ta.access.removeAccount" | "ta.access.removeConfirm" | "ta.access.removeDetail" | "ta.access.requested" | "ta.access.signOut" | "ta.access.thisBrowser" | "ta.access.title" | "ta.account" | "ta.account.menu" | "ta.account.service" | "ta.ask.no" | "ta.ask.start" | "ta.ask.title" | "ta.ask.waiting" | "ta.assistant.attention" | "ta.assistant.busy" | "ta.assistant.confirmOn" | "ta.assistant.copied" | "ta.assistant.copyCwd" | "ta.assistant.cwdTitle" | "ta.assistant.endedTasks" | "ta.assistant.export" | "ta.assistant.hello" | "ta.assistant.look" | "ta.assistant.me" | "ta.assistant.noTasks" | "ta.assistant.noTasksHint" | "ta.assistant.nothingToExport" | "ta.assistant.placeholder" | "ta.assistant.poke" | "ta.assistant.prompt" | "ta.assistant.promptTitle" | "ta.assistant.rename" | "ta.assistant.restart" | "ta.assistant.restartHint" | "ta.assistant.restartTitle" | "ta.assistant.runningTasks" | "ta.assistant.showTasks" | "ta.assistant.speakOff" | "ta.assistant.speakOn" | "ta.assistant.step.run" | "ta.assistant.step.say" | "ta.assistant.step.tell" | "ta.assistant.stop" | "ta.assistant.taskEnded" | "ta.assistant.tasks" | "ta.assistant.tasksTool" | "ta.assistant.waking" | "ta.assistant.working" | "ta.assistant.you" | "ta.auth.account" | "ta.auth.accounts" | "ta.auth.accountsExample" | "ta.auth.accountsTitle" | "ta.auth.apiKey" | "ta.auth.back" | "ta.auth.continue" | "ta.auth.copyAndOpen" | "ta.auth.copyCode" | "ta.auth.copyLink" | "ta.auth.deviceHint" | "ta.auth.done" | "ta.auth.enterKey" | "ta.auth.failed" | "ta.auth.hint" | "ta.auth.hintRemote" | "ta.auth.keys" | "ta.auth.keysExample" | "ta.auth.later" | "ta.auth.manualCode" | "ta.auth.manualCodeRemote" | "ta.auth.none" | "ta.auth.openHint" | "ta.auth.openPage" | "ta.auth.search" | "ta.auth.signOut" | "ta.auth.signOutConfirm" | "ta.auth.signedIn" | "ta.auth.subscription" | "ta.auth.title" | "ta.auth.waiting" | "ta.back" | "ta.board" | "ta.board.add" | "ta.board.done" | "ta.board.edit" | "ta.board.empty" | "ta.board.emptyHint" | "ta.board.moreTasks" | "ta.board.move" | "ta.board.noTasks" | "ta.board.none" | "ta.board.noneHint" | "ta.board.put" | "ta.board.remove" | "ta.board.tasks" | "ta.builtin.assistant" | "ta.builtin.assistantHint" | "ta.cancel" | "ta.chat" | "ta.chat.byDirectory" | "ta.chat.cwdTitle" | "ta.chat.doubleTag" | "ta.chat.doubleTagTitle" | "ta.chat.handToDouble" | "ta.chat.hint" | "ta.chat.new" | "ta.chat.newIn" | "ta.chat.noMatch" | "ta.chat.none" | "ta.chat.noneHint" | "ta.chat.open" | "ta.chat.opening" | "ta.chat.remove" | "ta.chat.removeShort" | "ta.chat.removed" | "ta.chat.restore" | "ta.chat.restoreShort" | "ta.chat.search" | "ta.chat.suggest.1" | "ta.chat.suggest.1.label" | "ta.chat.suggest.2" | "ta.chat.suggest.2.label" | "ta.chat.suggest.3" | "ta.chat.suggest.3.label" | "ta.chat.title" | "ta.close" | "ta.composer.addImage" | "ta.composer.commands" | "ta.composer.filesUnavailable" | "ta.composer.filter" | "ta.composer.image.count" | "ta.composer.image.size" | "ta.composer.image.type" | "ta.composer.imageLoading" | "ta.composer.label" | "ta.composer.listening" | "ta.composer.mentionFile" | "ta.composer.more" | "ta.composer.noFiles" | "ta.composer.noMatch" | "ta.composer.placeholder" | "ta.composer.placeholderTouch" | "ta.composer.queue.count" | "ta.composer.queue.editTitle" | "ta.composer.queue.followUp" | "ta.composer.queue.remove" | "ta.composer.queue.steering" | "ta.composer.queue.takeBackAll" | "ta.composer.queue.takeBackTitle" | "ta.composer.removeImage" | "ta.composer.steerPlaceholder" | "ta.composer.steerPlaceholderTouch" | "ta.composer.steerTitle" | "ta.composer.stopTitle" | "ta.composer.voice" | "ta.composer.voiceDenied" | "ta.composer.voiceFailed" | "ta.composer.voiceStop" | "ta.connection.away" | "ta.connection.back" | "ta.connection.lost" | "ta.connection.notDone" | "ta.connection.notDoneHint" | "ta.connection.retry" | "ta.connection.retryIn" | "ta.connection.retryNow" | "ta.connection.retrying" | "ta.copied" | "ta.copy" | "ta.discover" | "ta.discover.empty" | "ta.discover.emptyHint" | "ta.discover.hint" | "ta.dismiss" | "ta.editor" | "ta.editor.close" | "ta.editor.discardClose" | "ta.editor.failed" | "ta.editor.loading" | "ta.editor.unsavedManyTitle" | "ta.editor.unsavedMessage" | "ta.editor.unsavedTitle" | "ta.environment.connect" | "ta.environment.connections" | "ta.environment.failed" | "ta.environment.failedTitle" | "ta.environment.none" | "ta.environment.own" | "ta.environment.ownDetail" | "ta.environment.ownHint" | "ta.environment.restart" | "ta.environment.restartConfirm" | "ta.environment.restartDetail" | "ta.environment.retry" | "ta.environment.running" | "ta.environment.sandbox" | "ta.environment.starting" | "ta.environment.stop" | "ta.environment.stopConfirm" | "ta.environment.stopDetail" | "ta.environment.stopped" | "ta.environment.switch" | "ta.environment.switchConfirm" | "ta.environment.switchDetail" | "ta.environment.title" | "ta.environment.token" | "ta.environment.url" | "ta.environment.where" | "ta.environment.whereHint" | "ta.error.messageConflict" | "ta.error.modelNotFound" | "ta.error.sessionLocked" | "ta.error.sessionNotFound" | "ta.error.tooManySessions" | "ta.folder.empty" | "ta.folder.failed" | "ta.folder.open" | "ta.folder.path" | "ta.folder.title" | "ta.folder.up" | "ta.gait.bounce" | "ta.gait.sneak" | "ta.gait.strut" | "ta.gait.waddle" | "ta.gait.walk" | "ta.home" | "ta.host.title" | "ta.hosts.cameraDenied" | "ta.hosts.connecting" | "ta.hosts.notPairing" | "ta.hosts.paste" | "ta.hosts.refused" | "ta.hosts.remove" | "ta.hosts.removeConfirm" | "ta.hosts.rename" | "ta.hosts.saved" | "ta.hosts.scan" | "ta.hosts.scanFailed" | "ta.hosts.scanHint" | "ta.hosts.scanInstructions" | "ta.hosts.scanShort" | "ta.hosts.switching" | "ta.hosts.thisServer" | "ta.hosts.title" | "ta.hosts.unreachable" | "ta.launch.failed" | "ta.launch.open" | "ta.launch.ready" | "ta.launcher" | "ta.launcher.back" | "ta.launcher.clear" | "ta.launcher.noResults" | "ta.launcher.place.discover" | "ta.launcher.place.launcher" | "ta.launcher.place.list" | "ta.launcher.place.navigation" | "ta.launcher.search" | "ta.launcher.searchHint" | "ta.launcher.searchPlaceholder" | "ta.layout.editor" | "ta.layout.panel" | "ta.layout.resize" | "ta.layout.sidebar" | "ta.link.ask" | "ta.link.copied" | "ta.link.external" | "ta.link.externalMac" | "ta.link.noOpener" | "ta.link.notFound" | "ta.link.open" | "ta.link.openFile" | "ta.link.openFolder" | "ta.link.trust" | "ta.link.trustHint" | "ta.look.gait" | "ta.look.premium" | "ta.look.species" | "ta.look.title" | "ta.manage.about" | "ta.manage.accounts" | "ta.manage.packages" | "ta.manage.relay" | "ta.manage.shortcuts" | "ta.manage.workingDirectory" | "ta.markdown.diagram" | "ta.markdown.download" | "ta.markdown.enlarge" | "ta.markdown.exitFullscreen" | "ta.markdown.fullscreen" | "ta.markdown.missing" | "ta.markdown.source" | "ta.me" | "ta.menu" | "ta.message.branch" | "ta.message.compacted" | "ta.message.debug" | "ta.message.debugCopied" | "ta.message.forkAt" | "ta.message.forkBefore" | "ta.message.forked" | "ta.message.images" | "ta.message.notSaved" | "ta.message.rewind" | "ta.message.rewindConfirm" | "ta.message.rewindDetail" | "ta.message.selectText" | "ta.message.skill" | "ta.message.stopped" | "ta.message.thinking" | "ta.message.usageTitle" | "ta.message.used" | "ta.model.default" | "ta.model.defaultNone" | "ta.model.search" | "ta.mood.attention" | "ta.mood.done" | "ta.mood.idle" | "ta.mood.listening" | "ta.mood.sleeping" | "ta.mood.speaking" | "ta.mood.thinking" | "ta.mood.working" | "ta.more" | "ta.nav.fold" | "ta.nav.open" | "ta.nav.pin" | "ta.nav.settings" | "ta.no" | "ta.notice.picture" | "ta.notices" | "ta.off" | "ta.ok" | "ta.on" | "ta.online" | "ta.open.failed" | "ta.open.notALink" | "ta.open.open" | "ta.open.published" | "ta.open.relayed" | "ta.open.title" | "ta.packages" | "ta.packages.builtin" | "ta.packages.builtinTitle" | "ta.packages.failed" | "ta.packages.hint" | "ta.packages.installed" | "ta.packages.none" | "ta.packages.noneHint" | "ta.packages.reload" | "ta.packages.reloaded" | "ta.packages.remove" | "ta.packages.removeConfirm" | "ta.packages.removeDetail" | "ta.packages.removed" | "ta.packages.scope.project" | "ta.packages.scope.user" | "ta.panel.hide" | "ta.panel.show" | "ta.process.done" | "ta.process.earlier" | "ta.process.failed" | "ta.process.running" | "ta.process.thinking" | "ta.process.thought" | "ta.progress.calling" | "ta.progress.compacting" | "ta.progress.input" | "ta.progress.output" | "ta.progress.retrying" | "ta.progress.waiting" | "ta.pwa.install" | "ta.reconnecting" | "ta.relay.devices" | "ta.relay.done" | "ta.relay.hint" | "ta.relay.offline" | "ta.relay.online" | "ta.relay.pair" | "ta.relay.phone" | "ta.relay.scan" | "ta.relay.title" | "ta.relay.unpair" | "ta.relay.unpairConfirm" | "ta.remote.add" | "ta.remote.addHint" | "ta.remote.added" | "ta.remote.closePort" | "ta.remote.connect" | "ta.remote.connected" | "ta.remote.connectedTo" | "ta.remote.connecting" | "ta.remote.description" | "ta.remote.disconnect" | "ta.remote.disconnected" | "ta.remote.failed" | "ta.remote.forwarded" | "ta.remote.fromConfig" | "ta.remote.invalid" | "ta.remote.local" | "ta.remote.lost" | "ta.remote.none" | "ta.remote.noneHint" | "ta.remote.options" | "ta.remote.port" | "ta.remote.prompt.continue" | "ta.remote.prompt.title" | "ta.remote.prompt.trust" | "ta.remote.remove" | "ta.remote.step.checking" | "ta.remote.step.connecting" | "ta.remote.step.copying-server" | "ta.remote.step.installing-node" | "ta.remote.step.starting" | "ta.remote.title" | "ta.search.all" | "ta.search.failed" | "ta.search.loading" | "ta.search.more" | "ta.search.pages" | "ta.send" | "ta.session.compact" | "ta.session.compactTitle" | "ta.session.earlier" | "ta.session.empty" | "ta.session.model" | "ta.session.noModel" | "ta.session.phase.thinking" | "ta.session.phase.working" | "ta.session.phase.writing" | "ta.session.thinking" | "ta.session.title" | "ta.session.toBottom" | "ta.session.waitingClientTool" | "ta.session.working" | "ta.setting.codemode.mode" | "ta.setting.codemode.mode.hint" | "ta.setting.codemode.mode.on" | "ta.setting.codemode.mode.only" | "ta.setting.compaction.enabled" | "ta.setting.compaction.enabled.hint" | "ta.setting.compaction.keepRecentTokens" | "ta.setting.compaction.keepRecentTokens.hint" | "ta.setting.compaction.reserveTokens" | "ta.setting.compaction.reserveTokens.hint" | "ta.setting.defaultThinkingLevel" | "ta.setting.defaultThinkingLevel.high" | "ta.setting.defaultThinkingLevel.hint" | "ta.setting.defaultThinkingLevel.low" | "ta.setting.defaultThinkingLevel.max" | "ta.setting.defaultThinkingLevel.medium" | "ta.setting.defaultThinkingLevel.minimal" | "ta.setting.defaultThinkingLevel.off" | "ta.setting.defaultThinkingLevel.xhigh" | "ta.setting.enableSkillCommands" | "ta.setting.enableSkillCommands.hint" | "ta.setting.followUpMode" | "ta.setting.followUpMode.all" | "ta.setting.followUpMode.hint" | "ta.setting.followUpMode.one-at-a-time" | "ta.setting.images.autoResize" | "ta.setting.images.autoResize.hint" | "ta.setting.images.blockImages" | "ta.setting.images.blockImages.hint" | "ta.setting.model" | "ta.setting.model.hint" | "ta.setting.retry.enabled" | "ta.setting.retry.enabled.hint" | "ta.setting.retry.maxRetries" | "ta.setting.shellCommandPrefix" | "ta.setting.shellCommandPrefix.hint" | "ta.setting.shellPath" | "ta.setting.shellPath.hint" | "ta.setting.steeringMode" | "ta.setting.steeringMode.all" | "ta.setting.steeringMode.hint" | "ta.setting.steeringMode.one-at-a-time" | "ta.setting.transport" | "ta.setting.transport.auto" | "ta.setting.transport.hint" | "ta.settings" | "ta.settings.about" | "ta.settings.accounts" | "ta.settings.accountsDescription" | "ta.settings.agent" | "ta.settings.appearance" | "ta.settings.assistant" | "ta.settings.assistantModel" | "ta.settings.assistantModelHint" | "ta.settings.chatFontSize" | "ta.settings.chatFontSizeHint" | "ta.settings.confirmTasks" | "ta.settings.confirmTasksHint" | "ta.settings.cwd" | "ta.settings.cwdChange" | "ta.settings.cwdDescription" | "ta.settings.days" | "ta.settings.decides" | "ta.settings.default" | "ta.settings.displayLanguage" | "ta.settings.failed" | "ta.settings.fontSize" | "ta.settings.fontSize.large" | "ta.settings.fontSize.small" | "ta.settings.fontSize.standard" | "ta.settings.fontSize.xlarge" | "ta.settings.fontSizeHint" | "ta.settings.fromUser" | "ta.settings.group.context" | "ta.settings.group.conversation" | "ta.settings.group.model" | "ta.settings.group.tools" | "ta.settings.keepAlive" | "ta.settings.keepAliveDescription" | "ta.settings.language" | "ta.settings.language.system" | "ta.settings.links" | "ta.settings.loading" | "ta.settings.manageAccounts" | "ta.settings.maxTasks" | "ta.settings.maxTasksAny" | "ta.settings.maxTasksHint" | "ta.settings.minutes" | "ta.settings.modified" | "ta.settings.more" | "ta.settings.motion" | "ta.settings.motionHint" | "ta.settings.navigation" | "ta.settings.navigation.folded" | "ta.settings.navigation.inNav" | "ta.settings.navigation.none" | "ta.settings.navigation.overflow" | "ta.settings.navigation.pinned" | "ta.settings.navigation.reset" | "ta.settings.navigation.resetButton" | "ta.settings.navigation.resetHint" | "ta.settings.navigation.show" | "ta.settings.navigation.slots" | "ta.settings.navigation.slotsHint" | "ta.settings.never" | "ta.settings.noMatch" | "ta.settings.off" | "ta.settings.offline" | "ta.settings.on" | "ta.settings.relay" | "ta.settings.relayDescription" | "ta.settings.reset" | "ta.settings.retention" | "ta.settings.retentionDescription" | "ta.settings.scope.project" | "ta.settings.scope.user" | "ta.settings.scopeHint.project" | "ta.settings.scopeHint.user" | "ta.settings.search" | "ta.settings.server" | "ta.settings.shortcuts" | "ta.settings.signOut" | "ta.settings.speak" | "ta.settings.speakHint" | "ta.settings.taskModel" | "ta.settings.taskModelHint" | "ta.settings.theme" | "ta.settings.theme.dark" | "ta.settings.theme.light" | "ta.settings.theme.system" | "ta.settings.trustedDomains" | "ta.settings.trustedDomainsAdd" | "ta.settings.trustedDomainsEmpty" | "ta.settings.trustedDomainsEmptyHint" | "ta.settings.trustedDomainsHint" | "ta.settings.trustedDomainsRemove" | "ta.settings.untrusted" | "ta.settings.version" | "ta.settings.voice" | "ta.settings.web" | "ta.settings.webHint" | "ta.share.cannot" | "ta.share.copied" | "ta.share.copy" | "ta.share.making" | "ta.share.published" | "ta.share.qr" | "ta.share.relayed" | "ta.share.send" | "ta.share.stop" | "ta.share.stopHint" | "ta.share.stopTitle" | "ta.share.title" | "ta.shortcut.commands" | "ta.shortcut.files" | "ta.shortcut.followUp" | "ta.shortcut.newline" | "ta.shortcut.save" | "ta.shortcut.send" | "ta.shortcut.settings" | "ta.shortcut.sidebar" | "ta.shortcut.stop" | "ta.sidebar" | "ta.sidebar.closeTitle" | "ta.signin.accountsHint" | "ta.signin.connect" | "ta.signin.denied" | "ta.signin.failed" | "ta.signin.hint" | "ta.signin.hintRemote" | "ta.signin.orToken" | "ta.signin.pairHint" | "ta.signin.pairRefused" | "ta.signin.pairing" | "ta.signin.refused" | "ta.signin.title" | "ta.signin.token" | "ta.signin.wechat" | "ta.signin.with" | "ta.species.ankylosaurus" | "ta.species.brachiosaurus" | "ta.species.dragon" | "ta.species.parasaurolophus" | "ta.species.pteranodon" | "ta.species.stegosaurus" | "ta.species.trex" | "ta.species.triceratops" | "ta.species.velociraptor" | "ta.stop" | "ta.suggest.1" | "ta.suggest.1.label" | "ta.suggest.2" | "ta.suggest.2.label" | "ta.suggest.3" | "ta.suggest.3.label" | "ta.tab.close" | "ta.tab.closeAll" | "ta.tab.closeLeft" | "ta.tab.closeOthers" | "ta.tab.closeRight" | "ta.tab.closeSaved" | "ta.tab.keepOpen" | "ta.task.allTasks" | "ta.task.done" | "ta.task.ended" | "ta.task.failed" | "ta.task.remove" | "ta.task.removeHint" | "ta.task.removeTitle" | "ta.task.running" | "ta.task.stopped" | "ta.task.takeOver" | "ta.task.takeOverHint" | "ta.task.takenOver" | "ta.task.waiting" | "ta.tasks.all" | "ta.tasks.ended" | "ta.tasks.fewer" | "ta.tasks.running" | "ta.tasks.runningCount" | "ta.tasks.waiting" | "ta.tasks.waitingCount" | "ta.terminal.openLink" | "ta.terminal.openLinkMac" | "ta.terminal.openUrl" | "ta.terminal.openUrlMac" | "ta.time.dayBefore" | "ta.time.earlier" | "ta.time.today" | "ta.time.week" | "ta.time.yesterday" | "ta.tool.earlier" | "ta.tool.hideScript" | "ta.tool.showScript" | "ta.tool.verb.bash" | "ta.tool.verb.codemode" | "ta.tool.verb.edit" | "ta.tool.verb.find" | "ta.tool.verb.getTask" | "ta.tool.verb.grep" | "ta.tool.verb.listTasks" | "ta.tool.verb.ls" | "ta.tool.verb.messageTask" | "ta.tool.verb.read" | "ta.tool.verb.startTask" | "ta.tool.verb.stopTask" | "ta.tool.verb.write" | "ta.unreachable" | "ta.widget.failed" | "ta.workbench" | "ta.workbench.cards" | "ta.workbench.empty" | "ta.workbench.emptyHint" | "ta.workbench.maximize" | "ta.workbench.noCards" | "ta.workbench.noCardsHint" | "ta.workbench.open" | "ta.workbench.restore" | "ta.workbench.tabs" | "ta.workingDirectory.changed" | "ta.yes" | undefined;
|
|
7
|
+
error: "ta.access.add" | "ta.access.addHint" | "ta.access.added" | "ta.access.allow" | "ta.access.bind" | "ta.access.bindHint" | "ta.access.browser" | "ta.access.dismiss" | "ta.access.fromEnv" | "ta.access.lastUsed" | "ta.access.none" | "ta.access.noneHint" | "ta.access.remove" | "ta.access.removeAccount" | "ta.access.removeConfirm" | "ta.access.removeDetail" | "ta.access.requested" | "ta.access.signOut" | "ta.access.thisBrowser" | "ta.access.title" | "ta.account" | "ta.account.menu" | "ta.account.service" | "ta.ask.no" | "ta.ask.start" | "ta.ask.title" | "ta.ask.waiting" | "ta.assistant.attention" | "ta.assistant.busy" | "ta.assistant.confirmOn" | "ta.assistant.copied" | "ta.assistant.copyCwd" | "ta.assistant.cwdTitle" | "ta.assistant.endedTasks" | "ta.assistant.export" | "ta.assistant.hello" | "ta.assistant.look" | "ta.assistant.me" | "ta.assistant.noTasks" | "ta.assistant.noTasksHint" | "ta.assistant.nothingToExport" | "ta.assistant.placeholder" | "ta.assistant.poke" | "ta.assistant.prompt" | "ta.assistant.promptTitle" | "ta.assistant.rename" | "ta.assistant.restart" | "ta.assistant.restartHint" | "ta.assistant.restartTitle" | "ta.assistant.runningTasks" | "ta.assistant.showTasks" | "ta.assistant.speakOff" | "ta.assistant.speakOn" | "ta.assistant.step.run" | "ta.assistant.step.say" | "ta.assistant.step.tell" | "ta.assistant.stop" | "ta.assistant.taskEnded" | "ta.assistant.tasks" | "ta.assistant.tasksTool" | "ta.assistant.waking" | "ta.assistant.working" | "ta.assistant.you" | "ta.auth.account" | "ta.auth.accounts" | "ta.auth.accountsExample" | "ta.auth.accountsTitle" | "ta.auth.apiKey" | "ta.auth.back" | "ta.auth.continue" | "ta.auth.copyAndOpen" | "ta.auth.copyCode" | "ta.auth.copyLink" | "ta.auth.deviceHint" | "ta.auth.done" | "ta.auth.enterKey" | "ta.auth.failed" | "ta.auth.hint" | "ta.auth.hintRemote" | "ta.auth.keys" | "ta.auth.keysExample" | "ta.auth.later" | "ta.auth.manualCode" | "ta.auth.manualCodeRemote" | "ta.auth.none" | "ta.auth.openHint" | "ta.auth.openPage" | "ta.auth.search" | "ta.auth.signOut" | "ta.auth.signOutConfirm" | "ta.auth.signedIn" | "ta.auth.subscription" | "ta.auth.title" | "ta.auth.waiting" | "ta.back" | "ta.board" | "ta.board.add" | "ta.board.done" | "ta.board.edit" | "ta.board.empty" | "ta.board.emptyHint" | "ta.board.moreTasks" | "ta.board.move" | "ta.board.noTasks" | "ta.board.none" | "ta.board.noneHint" | "ta.board.put" | "ta.board.remove" | "ta.board.tasks" | "ta.builtin.assistant" | "ta.builtin.assistantHint" | "ta.cancel" | "ta.chat" | "ta.chat.byDirectory" | "ta.chat.cwdTitle" | "ta.chat.doubleTag" | "ta.chat.doubleTagTitle" | "ta.chat.handToDouble" | "ta.chat.hint" | "ta.chat.new" | "ta.chat.newIn" | "ta.chat.noMatch" | "ta.chat.none" | "ta.chat.noneHint" | "ta.chat.open" | "ta.chat.opening" | "ta.chat.remove" | "ta.chat.removeShort" | "ta.chat.removed" | "ta.chat.restore" | "ta.chat.restoreShort" | "ta.chat.search" | "ta.chat.suggest.1" | "ta.chat.suggest.1.label" | "ta.chat.suggest.2" | "ta.chat.suggest.2.label" | "ta.chat.suggest.3" | "ta.chat.suggest.3.label" | "ta.chat.title" | "ta.close" | "ta.composer.addImage" | "ta.composer.commands" | "ta.composer.filesUnavailable" | "ta.composer.filter" | "ta.composer.image.count" | "ta.composer.image.size" | "ta.composer.image.type" | "ta.composer.imageLoading" | "ta.composer.label" | "ta.composer.listening" | "ta.composer.mentionFile" | "ta.composer.more" | "ta.composer.noFiles" | "ta.composer.noMatch" | "ta.composer.placeholder" | "ta.composer.placeholderTouch" | "ta.composer.queue.count" | "ta.composer.queue.editTitle" | "ta.composer.queue.followUp" | "ta.composer.queue.remove" | "ta.composer.queue.steering" | "ta.composer.queue.takeBackAll" | "ta.composer.queue.takeBackTitle" | "ta.composer.removeImage" | "ta.composer.steerPlaceholder" | "ta.composer.steerPlaceholderTouch" | "ta.composer.steerTitle" | "ta.composer.stopTitle" | "ta.composer.voice" | "ta.composer.voiceDenied" | "ta.composer.voiceFailed" | "ta.composer.voiceStop" | "ta.connection.away" | "ta.connection.back" | "ta.connection.lost" | "ta.connection.notDone" | "ta.connection.notDoneHint" | "ta.connection.retry" | "ta.connection.retryIn" | "ta.connection.retryNow" | "ta.connection.retrying" | "ta.copied" | "ta.copy" | "ta.discover" | "ta.discover.empty" | "ta.discover.emptyHint" | "ta.discover.hint" | "ta.dismiss" | "ta.editor" | "ta.editor.close" | "ta.editor.discardClose" | "ta.editor.failed" | "ta.editor.loading" | "ta.editor.unsavedManyTitle" | "ta.editor.unsavedMessage" | "ta.editor.unsavedTitle" | "ta.environment.connect" | "ta.environment.connections" | "ta.environment.failed" | "ta.environment.failedTitle" | "ta.environment.none" | "ta.environment.own" | "ta.environment.ownDetail" | "ta.environment.ownHint" | "ta.environment.restart" | "ta.environment.restartConfirm" | "ta.environment.restartDetail" | "ta.environment.retry" | "ta.environment.running" | "ta.environment.sandbox" | "ta.environment.starting" | "ta.environment.stop" | "ta.environment.stopConfirm" | "ta.environment.stopDetail" | "ta.environment.stopped" | "ta.environment.switch" | "ta.environment.switchConfirm" | "ta.environment.switchDetail" | "ta.environment.title" | "ta.environment.token" | "ta.environment.url" | "ta.environment.where" | "ta.environment.whereHint" | "ta.error.messageConflict" | "ta.error.modelNotFound" | "ta.error.sessionLocked" | "ta.error.sessionNotFound" | "ta.error.tooManySessions" | "ta.folder.empty" | "ta.folder.failed" | "ta.folder.open" | "ta.folder.path" | "ta.folder.title" | "ta.folder.up" | "ta.gait.bounce" | "ta.gait.sneak" | "ta.gait.strut" | "ta.gait.waddle" | "ta.gait.walk" | "ta.home" | "ta.host.title" | "ta.hosts.cameraDenied" | "ta.hosts.connecting" | "ta.hosts.notPairing" | "ta.hosts.paste" | "ta.hosts.refused" | "ta.hosts.remove" | "ta.hosts.removeConfirm" | "ta.hosts.rename" | "ta.hosts.saved" | "ta.hosts.scan" | "ta.hosts.scanFailed" | "ta.hosts.scanHint" | "ta.hosts.scanInstructions" | "ta.hosts.scanShort" | "ta.hosts.switching" | "ta.hosts.thisServer" | "ta.hosts.title" | "ta.hosts.unreachable" | "ta.launch.failed" | "ta.launch.open" | "ta.launch.ready" | "ta.launcher" | "ta.launcher.back" | "ta.launcher.clear" | "ta.launcher.noResults" | "ta.launcher.place.discover" | "ta.launcher.place.launcher" | "ta.launcher.place.list" | "ta.launcher.place.navigation" | "ta.launcher.search" | "ta.launcher.searchHint" | "ta.launcher.searchPlaceholder" | "ta.layout.editor" | "ta.layout.panel" | "ta.layout.resize" | "ta.layout.sidebar" | "ta.link.ask" | "ta.link.copied" | "ta.link.external" | "ta.link.externalMac" | "ta.link.noOpener" | "ta.link.notFound" | "ta.link.open" | "ta.link.openFile" | "ta.link.openFolder" | "ta.link.trust" | "ta.link.trustHint" | "ta.look.gait" | "ta.look.premium" | "ta.look.species" | "ta.look.title" | "ta.manage.about" | "ta.manage.accounts" | "ta.manage.packages" | "ta.manage.relay" | "ta.manage.shortcuts" | "ta.manage.workingDirectory" | "ta.markdown.diagram" | "ta.markdown.download" | "ta.markdown.enlarge" | "ta.markdown.exitFullscreen" | "ta.markdown.fullscreen" | "ta.markdown.missing" | "ta.markdown.source" | "ta.me" | "ta.menu" | "ta.message.branch" | "ta.message.compacted" | "ta.message.debug" | "ta.message.debugCopied" | "ta.message.forkAt" | "ta.message.forkBefore" | "ta.message.forked" | "ta.message.images" | "ta.message.notSaved" | "ta.message.rewind" | "ta.message.rewindConfirm" | "ta.message.rewindDetail" | "ta.message.selectText" | "ta.message.skill" | "ta.message.stopped" | "ta.message.thinking" | "ta.message.usageTitle" | "ta.message.used" | "ta.model.default" | "ta.model.defaultNone" | "ta.model.search" | "ta.mood.attention" | "ta.mood.done" | "ta.mood.idle" | "ta.mood.listening" | "ta.mood.sleeping" | "ta.mood.speaking" | "ta.mood.thinking" | "ta.mood.working" | "ta.more" | "ta.nav.fold" | "ta.nav.open" | "ta.nav.pin" | "ta.nav.settings" | "ta.no" | "ta.notice.picture" | "ta.notices" | "ta.off" | "ta.ok" | "ta.on" | "ta.online" | "ta.open.failed" | "ta.open.notALink" | "ta.open.open" | "ta.open.published" | "ta.open.relayed" | "ta.open.title" | "ta.packages" | "ta.packages.builtin" | "ta.packages.builtinTitle" | "ta.packages.failed" | "ta.packages.hint" | "ta.packages.installed" | "ta.packages.none" | "ta.packages.noneHint" | "ta.packages.reload" | "ta.packages.reloaded" | "ta.packages.remove" | "ta.packages.removeConfirm" | "ta.packages.removeDetail" | "ta.packages.removed" | "ta.packages.scope.project" | "ta.packages.scope.user" | "ta.panel.hide" | "ta.panel.show" | "ta.process.done" | "ta.process.earlier" | "ta.process.failed" | "ta.process.running" | "ta.process.thinking" | "ta.process.thought" | "ta.progress.calling" | "ta.progress.compacting" | "ta.progress.input" | "ta.progress.output" | "ta.progress.retrying" | "ta.progress.waiting" | "ta.pwa.install" | "ta.reconnecting" | "ta.relay.devices" | "ta.relay.done" | "ta.relay.hint" | "ta.relay.offline" | "ta.relay.online" | "ta.relay.pair" | "ta.relay.phone" | "ta.relay.scan" | "ta.relay.title" | "ta.relay.unpair" | "ta.relay.unpairConfirm" | "ta.remote.add" | "ta.remote.addHint" | "ta.remote.added" | "ta.remote.closePort" | "ta.remote.connect" | "ta.remote.connected" | "ta.remote.connectedTo" | "ta.remote.connecting" | "ta.remote.description" | "ta.remote.disconnect" | "ta.remote.disconnected" | "ta.remote.failed" | "ta.remote.forwarded" | "ta.remote.fromConfig" | "ta.remote.invalid" | "ta.remote.local" | "ta.remote.lost" | "ta.remote.none" | "ta.remote.noneHint" | "ta.remote.options" | "ta.remote.port" | "ta.remote.prompt.continue" | "ta.remote.prompt.title" | "ta.remote.prompt.trust" | "ta.remote.remove" | "ta.remote.step.checking" | "ta.remote.step.connecting" | "ta.remote.step.copying-server" | "ta.remote.step.installing-node" | "ta.remote.step.starting" | "ta.remote.title" | "ta.search.all" | "ta.search.failed" | "ta.search.loading" | "ta.search.more" | "ta.search.pages" | "ta.select.all" | "ta.select.count" | "ta.select.done" | "ta.send" | "ta.session.compact" | "ta.session.compactTitle" | "ta.session.earlier" | "ta.session.empty" | "ta.session.model" | "ta.session.noModel" | "ta.session.phase.thinking" | "ta.session.phase.working" | "ta.session.phase.writing" | "ta.session.thinking" | "ta.session.title" | "ta.session.toBottom" | "ta.session.waitingClientTool" | "ta.session.working" | "ta.setting.codemode.mode" | "ta.setting.codemode.mode.hint" | "ta.setting.codemode.mode.on" | "ta.setting.codemode.mode.only" | "ta.setting.compaction.enabled" | "ta.setting.compaction.enabled.hint" | "ta.setting.compaction.keepRecentTokens" | "ta.setting.compaction.keepRecentTokens.hint" | "ta.setting.compaction.reserveTokens" | "ta.setting.compaction.reserveTokens.hint" | "ta.setting.defaultThinkingLevel" | "ta.setting.defaultThinkingLevel.high" | "ta.setting.defaultThinkingLevel.hint" | "ta.setting.defaultThinkingLevel.low" | "ta.setting.defaultThinkingLevel.max" | "ta.setting.defaultThinkingLevel.medium" | "ta.setting.defaultThinkingLevel.minimal" | "ta.setting.defaultThinkingLevel.off" | "ta.setting.defaultThinkingLevel.xhigh" | "ta.setting.enableSkillCommands" | "ta.setting.enableSkillCommands.hint" | "ta.setting.followUpMode" | "ta.setting.followUpMode.all" | "ta.setting.followUpMode.hint" | "ta.setting.followUpMode.one-at-a-time" | "ta.setting.images.autoResize" | "ta.setting.images.autoResize.hint" | "ta.setting.images.blockImages" | "ta.setting.images.blockImages.hint" | "ta.setting.model" | "ta.setting.model.hint" | "ta.setting.retry.enabled" | "ta.setting.retry.enabled.hint" | "ta.setting.retry.maxRetries" | "ta.setting.shellCommandPrefix" | "ta.setting.shellCommandPrefix.hint" | "ta.setting.shellPath" | "ta.setting.shellPath.hint" | "ta.setting.steeringMode" | "ta.setting.steeringMode.all" | "ta.setting.steeringMode.hint" | "ta.setting.steeringMode.one-at-a-time" | "ta.setting.transport" | "ta.setting.transport.auto" | "ta.setting.transport.hint" | "ta.settings" | "ta.settings.about" | "ta.settings.accounts" | "ta.settings.accountsDescription" | "ta.settings.agent" | "ta.settings.appearance" | "ta.settings.assistant" | "ta.settings.assistantModel" | "ta.settings.assistantModelHint" | "ta.settings.chatFontSize" | "ta.settings.chatFontSizeHint" | "ta.settings.confirmTasks" | "ta.settings.confirmTasksHint" | "ta.settings.cwd" | "ta.settings.cwdChange" | "ta.settings.cwdDescription" | "ta.settings.days" | "ta.settings.decides" | "ta.settings.default" | "ta.settings.displayLanguage" | "ta.settings.failed" | "ta.settings.fontSize" | "ta.settings.fontSize.large" | "ta.settings.fontSize.small" | "ta.settings.fontSize.standard" | "ta.settings.fontSize.xlarge" | "ta.settings.fontSizeHint" | "ta.settings.fromUser" | "ta.settings.group.context" | "ta.settings.group.conversation" | "ta.settings.group.model" | "ta.settings.group.tools" | "ta.settings.keepAlive" | "ta.settings.keepAliveDescription" | "ta.settings.language" | "ta.settings.language.system" | "ta.settings.links" | "ta.settings.loading" | "ta.settings.manageAccounts" | "ta.settings.maxTasks" | "ta.settings.maxTasksAny" | "ta.settings.maxTasksHint" | "ta.settings.minutes" | "ta.settings.modified" | "ta.settings.more" | "ta.settings.motion" | "ta.settings.motionHint" | "ta.settings.navigation" | "ta.settings.navigation.folded" | "ta.settings.navigation.inNav" | "ta.settings.navigation.none" | "ta.settings.navigation.overflow" | "ta.settings.navigation.pinned" | "ta.settings.navigation.reset" | "ta.settings.navigation.resetButton" | "ta.settings.navigation.resetHint" | "ta.settings.navigation.show" | "ta.settings.navigation.slots" | "ta.settings.navigation.slotsHint" | "ta.settings.never" | "ta.settings.noMatch" | "ta.settings.off" | "ta.settings.offline" | "ta.settings.on" | "ta.settings.relay" | "ta.settings.relayDescription" | "ta.settings.reset" | "ta.settings.retention" | "ta.settings.retentionDescription" | "ta.settings.scope.project" | "ta.settings.scope.user" | "ta.settings.scopeHint.project" | "ta.settings.scopeHint.user" | "ta.settings.search" | "ta.settings.server" | "ta.settings.shortcuts" | "ta.settings.signOut" | "ta.settings.speak" | "ta.settings.speakHint" | "ta.settings.taskModel" | "ta.settings.taskModelHint" | "ta.settings.theme" | "ta.settings.theme.dark" | "ta.settings.theme.light" | "ta.settings.theme.system" | "ta.settings.trustedDomains" | "ta.settings.trustedDomainsAdd" | "ta.settings.trustedDomainsEmpty" | "ta.settings.trustedDomainsEmptyHint" | "ta.settings.trustedDomainsHint" | "ta.settings.trustedDomainsRemove" | "ta.settings.untrusted" | "ta.settings.version" | "ta.settings.voice" | "ta.settings.web" | "ta.settings.webHint" | "ta.share.cannot" | "ta.share.copied" | "ta.share.copy" | "ta.share.making" | "ta.share.published" | "ta.share.qr" | "ta.share.relayed" | "ta.share.send" | "ta.share.stop" | "ta.share.stopHint" | "ta.share.stopTitle" | "ta.share.title" | "ta.shortcut.commands" | "ta.shortcut.files" | "ta.shortcut.followUp" | "ta.shortcut.newline" | "ta.shortcut.save" | "ta.shortcut.send" | "ta.shortcut.settings" | "ta.shortcut.sidebar" | "ta.shortcut.stop" | "ta.sidebar" | "ta.sidebar.closeTitle" | "ta.signin.accountsHint" | "ta.signin.connect" | "ta.signin.denied" | "ta.signin.failed" | "ta.signin.hint" | "ta.signin.hintRemote" | "ta.signin.orToken" | "ta.signin.pairHint" | "ta.signin.pairRefused" | "ta.signin.pairing" | "ta.signin.refused" | "ta.signin.title" | "ta.signin.token" | "ta.signin.wechat" | "ta.signin.with" | "ta.species.ankylosaurus" | "ta.species.brachiosaurus" | "ta.species.dragon" | "ta.species.parasaurolophus" | "ta.species.pteranodon" | "ta.species.stegosaurus" | "ta.species.trex" | "ta.species.triceratops" | "ta.species.velociraptor" | "ta.stop" | "ta.suggest.1" | "ta.suggest.1.label" | "ta.suggest.2" | "ta.suggest.2.label" | "ta.suggest.3" | "ta.suggest.3.label" | "ta.tab.close" | "ta.tab.closeAll" | "ta.tab.closeLeft" | "ta.tab.closeOthers" | "ta.tab.closeRight" | "ta.tab.closeSaved" | "ta.tab.keepOpen" | "ta.task.allTasks" | "ta.task.done" | "ta.task.ended" | "ta.task.failed" | "ta.task.remove" | "ta.task.removeHint" | "ta.task.removeTitle" | "ta.task.running" | "ta.task.stopped" | "ta.task.takeOver" | "ta.task.takeOverHint" | "ta.task.takenOver" | "ta.task.waiting" | "ta.tasks.all" | "ta.tasks.ended" | "ta.tasks.fewer" | "ta.tasks.removeTitle" | "ta.tasks.running" | "ta.tasks.runningCount" | "ta.tasks.select" | "ta.tasks.waiting" | "ta.tasks.waitingCount" | "ta.terminal.openLink" | "ta.terminal.openLinkMac" | "ta.terminal.openUrl" | "ta.terminal.openUrlMac" | "ta.time.dayBefore" | "ta.time.earlier" | "ta.time.today" | "ta.time.week" | "ta.time.yesterday" | "ta.tool.earlier" | "ta.tool.hideScript" | "ta.tool.showScript" | "ta.tool.verb.bash" | "ta.tool.verb.codemode" | "ta.tool.verb.edit" | "ta.tool.verb.find" | "ta.tool.verb.getTask" | "ta.tool.verb.grep" | "ta.tool.verb.listTasks" | "ta.tool.verb.ls" | "ta.tool.verb.messageTask" | "ta.tool.verb.read" | "ta.tool.verb.startTask" | "ta.tool.verb.stopTask" | "ta.tool.verb.write" | "ta.unreachable" | "ta.widget.failed" | "ta.workbench" | "ta.workbench.cards" | "ta.workbench.empty" | "ta.workbench.emptyHint" | "ta.workbench.maximize" | "ta.workbench.noCards" | "ta.workbench.noCardsHint" | "ta.workbench.open" | "ta.workbench.restore" | "ta.workbench.tabs" | "ta.workingDirectory.changed" | "ta.yes" | undefined;
|
|
8
8
|
add: (text: string, scanned?: boolean) => Promise<void>;
|
|
9
9
|
scan: () => Promise<void>;
|
|
10
10
|
canScan: boolean;
|
|
@@ -45,7 +45,7 @@ const scanner_1 = require("../device/scanner");
|
|
|
45
45
|
const hooks_1 = require("../hooks");
|
|
46
46
|
const hosts_1 = require("../hosts");
|
|
47
47
|
const use_t_1 = require("../i18n/use-t");
|
|
48
|
-
const
|
|
48
|
+
const workbench_util_1 = require("../workbench-util");
|
|
49
49
|
const callout_1 = require("./callout");
|
|
50
50
|
const chat_list_1 = require("./chat-list");
|
|
51
51
|
const context_menu_1 = require("./context-menu");
|
|
@@ -63,9 +63,9 @@ function useAddHost() {
|
|
|
63
63
|
const [busy, setBusy] = React.useState(false);
|
|
64
64
|
const [error, setError] = React.useState();
|
|
65
65
|
const add = React.useCallback(async (text, scanned = false) => {
|
|
66
|
-
const credential =
|
|
66
|
+
const credential = workbench_util_1.WorkbenchUtil.credential(text);
|
|
67
67
|
// The app has no ta serve of its page to give a token to; a code is always a pairing.
|
|
68
|
-
if (!('pairing' in credential) && (scanned ||
|
|
68
|
+
if (!('pairing' in credential) && (scanned || workbench_util_1.WorkbenchUtil.isApp())) {
|
|
69
69
|
setError('ta.hosts.notPairing');
|
|
70
70
|
return;
|
|
71
71
|
}
|
|
@@ -75,7 +75,7 @@ function useAddHost() {
|
|
|
75
75
|
await bench.signIn(text);
|
|
76
76
|
}
|
|
77
77
|
catch (failure) {
|
|
78
|
-
setError(failure instanceof
|
|
78
|
+
setError(failure instanceof workbench_util_1.WorkbenchError && failure.reason === 'refused' ? 'ta.hosts.refused' : 'ta.hosts.unreachable');
|
|
79
79
|
}
|
|
80
80
|
finally {
|
|
81
81
|
setBusy(false);
|
|
@@ -199,7 +199,7 @@ function AddHostPanel({ error }) {
|
|
|
199
199
|
adding.busy ? React.createElement("span", { className: "ta-spinner" }) : React.createElement(icon_1.Icon, { icon: lucide_react_1.ScanLine, size: 18 }),
|
|
200
200
|
" ",
|
|
201
201
|
t('ta.hosts.scan'))),
|
|
202
|
-
pasting ? (React.createElement(LinkForm, { busy: adding.busy, autoFocus: !adding.canScan, placeholder: t(
|
|
202
|
+
pasting ? (React.createElement(LinkForm, { busy: adding.busy, autoFocus: !adding.canScan, placeholder: t(workbench_util_1.WorkbenchUtil.isApp() ? 'ta.signin.pairing' : 'ta.signin.token'), onSubmit: text => void adding.add(text) })) : (React.createElement("button", { type: "button", className: "ta-link-button", onClick: () => setPasting(true) }, t('ta.hosts.paste'))),
|
|
203
203
|
shown && React.createElement(callout_1.Callout, { level: "error" }, t(shown)),
|
|
204
204
|
hosts.length > 0 && (React.createElement("section", { className: "ta-host-saved" },
|
|
205
205
|
React.createElement("h2", null, t('ta.hosts.saved')),
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import type { WebSelectBarProps, WebSelectCheckProps } from '../extension/web-extension-api';
|
|
3
|
+
/** The round mark at the start of a row while its list is selecting, as WeChat's: filled once chosen. */
|
|
4
|
+
export declare function SelectCheck({ checked, disabled }: WebSelectCheckProps): React.JSX.Element;
|
|
5
|
+
/**
|
|
6
|
+
* Under a list that is selecting: Select all (or none, once all are), how many are chosen, what can be done
|
|
7
|
+
* with them and Done. Every list of the page and of web extensions (`ui.SelectBar`) takes it.
|
|
8
|
+
*/
|
|
9
|
+
export declare function SelectBar({ count, total, onSelectAll, onDone, actions }: WebSelectBarProps): React.JSX.Element;
|
|
10
|
+
//# sourceMappingURL=select-bar.d.ts.map
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
19
|
+
var ownKeys = function(o) {
|
|
20
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
21
|
+
var ar = [];
|
|
22
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
23
|
+
return ar;
|
|
24
|
+
};
|
|
25
|
+
return ownKeys(o);
|
|
26
|
+
};
|
|
27
|
+
return function (mod) {
|
|
28
|
+
if (mod && mod.__esModule) return mod;
|
|
29
|
+
var result = {};
|
|
30
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
31
|
+
__setModuleDefault(result, mod);
|
|
32
|
+
return result;
|
|
33
|
+
};
|
|
34
|
+
})();
|
|
35
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
36
|
+
exports.SelectCheck = SelectCheck;
|
|
37
|
+
exports.SelectBar = SelectBar;
|
|
38
|
+
const lucide_react_1 = require("lucide-react");
|
|
39
|
+
const React = __importStar(require("react"));
|
|
40
|
+
const use_t_1 = require("../i18n/use-t");
|
|
41
|
+
const icon_1 = require("./icon");
|
|
42
|
+
/** The round mark at the start of a row while its list is selecting, as WeChat's: filled once chosen. */
|
|
43
|
+
function SelectCheck({ checked, disabled }) {
|
|
44
|
+
return (React.createElement("span", { className: "ta-select-check", "data-checked": checked ? '' : undefined, "data-disabled": disabled ? '' : undefined, "aria-hidden": "true" }, checked && React.createElement(icon_1.Icon, { icon: lucide_react_1.Check, size: 12 })));
|
|
45
|
+
}
|
|
46
|
+
/**
|
|
47
|
+
* Under a list that is selecting: Select all (or none, once all are), how many are chosen, what can be done
|
|
48
|
+
* with them and Done. Every list of the page and of web extensions (`ui.SelectBar`) takes it.
|
|
49
|
+
*/
|
|
50
|
+
function SelectBar({ count, total, onSelectAll, onDone, actions }) {
|
|
51
|
+
const t = (0, use_t_1.useT)();
|
|
52
|
+
const all = total > 0 && count >= total;
|
|
53
|
+
return (React.createElement("div", { className: "ta-select-bar", role: "toolbar", "aria-label": t('ta.select.count', { count }) },
|
|
54
|
+
React.createElement("button", { type: "button", className: "ta-select-bar-all", disabled: total === 0, onClick: () => onSelectAll(!all) },
|
|
55
|
+
React.createElement(SelectCheck, { checked: all }),
|
|
56
|
+
t('ta.select.all')),
|
|
57
|
+
React.createElement("span", { className: "ta-select-bar-count", "aria-live": "polite" }, t('ta.select.count', { count })),
|
|
58
|
+
actions.map(action => (React.createElement("button", { key: action.key, type: "button", className: `ta-button ta-select-bar-action${action.danger ? ' ta-danger' : ''}`, disabled: count === 0, onClick: action.run }, action.label))),
|
|
59
|
+
React.createElement("button", { type: "button", className: "ta-button ta-select-bar-done", onClick: onDone }, t('ta.select.done'))));
|
|
60
|
+
}
|
|
61
|
+
//# sourceMappingURL=select-bar.js.map
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import { type TaPackageInfo } from '@celljs/ta-protocol';
|
|
2
|
+
import { type LucideIcon } from 'lucide-react';
|
|
3
|
+
import type { MessageId } from '../i18n/messages';
|
|
4
|
+
import type { useT } from '../i18n/use-t';
|
|
5
|
+
import type { FontSize, LanguageSetting, ThemeSetting } from '../settings/settings-protocol';
|
|
6
|
+
import type { Navigation } from './nav-places';
|
|
7
|
+
import { type Choice, type RowEntry } from './settings-controls';
|
|
8
|
+
export declare const THEMES: Choice<ThemeSetting>[];
|
|
9
|
+
export declare const FONT_SIZES: Choice<FontSize>[];
|
|
10
|
+
export declare const LANGUAGES: Choice<LanguageSetting>[];
|
|
11
|
+
export declare const GROUP_ICONS: Record<string, LucideIcon>;
|
|
12
|
+
/** The keys of the page and of the message box; `Mod` is ⌘ on a Mac, Ctrl elsewhere. */
|
|
13
|
+
export declare const SHORTCUTS: {
|
|
14
|
+
keys: string;
|
|
15
|
+
label: MessageId;
|
|
16
|
+
}[];
|
|
17
|
+
/**
|
|
18
|
+
* The packages pi loads, as the server lists them, those turned off too: the built-in ones turn off and
|
|
19
|
+
* stay; the others turn off and on, and go.
|
|
20
|
+
*/
|
|
21
|
+
export declare function usePackages(): {
|
|
22
|
+
packages: TaPackageInfo[];
|
|
23
|
+
toggle: (pkg: TaPackageInfo, on: boolean) => Promise<void>;
|
|
24
|
+
remove: (pkg: TaPackageInfo) => Promise<void>;
|
|
25
|
+
read: () => Promise<void>;
|
|
26
|
+
};
|
|
27
|
+
export declare const SLOTS: Choice<string>[];
|
|
28
|
+
/** The rows of the navigation: how many pages it shows, and where each page is. */
|
|
29
|
+
export declare function navigationRows(navigation: Navigation, t: ReturnType<typeof useT>): RowEntry[];
|
|
30
|
+
/** How a package shows in a row: what it calls itself for people, else its name and the description of its package.json. */
|
|
31
|
+
export declare function packageLabel(pkg: TaPackageInfo, language: string): {
|
|
32
|
+
title: string;
|
|
33
|
+
summary: string | undefined;
|
|
34
|
+
icon: import("..").WebIcon;
|
|
35
|
+
};
|
|
36
|
+
//# sourceMappingURL=settings-choices.d.ts.map
|
|
@@ -0,0 +1,156 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
19
|
+
var ownKeys = function(o) {
|
|
20
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
21
|
+
var ar = [];
|
|
22
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
23
|
+
return ar;
|
|
24
|
+
};
|
|
25
|
+
return ownKeys(o);
|
|
26
|
+
};
|
|
27
|
+
return function (mod) {
|
|
28
|
+
if (mod && mod.__esModule) return mod;
|
|
29
|
+
var result = {};
|
|
30
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
31
|
+
__setModuleDefault(result, mod);
|
|
32
|
+
return result;
|
|
33
|
+
};
|
|
34
|
+
})();
|
|
35
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
36
|
+
exports.SLOTS = exports.SHORTCUTS = exports.GROUP_ICONS = exports.LANGUAGES = exports.FONT_SIZES = exports.THEMES = void 0;
|
|
37
|
+
exports.usePackages = usePackages;
|
|
38
|
+
exports.navigationRows = navigationRows;
|
|
39
|
+
exports.packageLabel = packageLabel;
|
|
40
|
+
const ta_protocol_1 = require("@celljs/ta-protocol");
|
|
41
|
+
const lucide_react_1 = require("lucide-react");
|
|
42
|
+
const React = __importStar(require("react"));
|
|
43
|
+
const icons_1 = require("../extension/icons");
|
|
44
|
+
const web_extension_protocol_1 = require("../extension/web-extension-protocol");
|
|
45
|
+
const hooks_1 = require("../hooks");
|
|
46
|
+
const navigation_1 = require("../settings/navigation");
|
|
47
|
+
const icon_1 = require("./icon");
|
|
48
|
+
const settings_controls_1 = require("./settings-controls");
|
|
49
|
+
exports.THEMES = [
|
|
50
|
+
{ value: 'system', icon: lucide_react_1.Monitor, label: 'ta.settings.theme.system' },
|
|
51
|
+
{ value: 'light', icon: lucide_react_1.Sun, label: 'ta.settings.theme.light' },
|
|
52
|
+
{ value: 'dark', icon: lucide_react_1.Moon, label: 'ta.settings.theme.dark' },
|
|
53
|
+
];
|
|
54
|
+
exports.FONT_SIZES = [
|
|
55
|
+
{ value: 'small', label: 'ta.settings.fontSize.small' },
|
|
56
|
+
{ value: 'standard', label: 'ta.settings.fontSize.standard' },
|
|
57
|
+
{ value: 'large', label: 'ta.settings.fontSize.large' },
|
|
58
|
+
{ value: 'xlarge', label: 'ta.settings.fontSize.xlarge' },
|
|
59
|
+
];
|
|
60
|
+
exports.LANGUAGES = [
|
|
61
|
+
{ value: 'system', icon: lucide_react_1.Globe, label: 'ta.settings.language.system' },
|
|
62
|
+
{ value: 'zh-CN', label: '简体中文' },
|
|
63
|
+
{ value: 'en-US', label: 'English' },
|
|
64
|
+
];
|
|
65
|
+
exports.GROUP_ICONS = { model: lucide_react_1.Sparkles, conversation: lucide_react_1.MessagesSquare, context: lucide_react_1.Layers, tools: lucide_react_1.Wrench };
|
|
66
|
+
/** The keys of the page and of the message box; `Mod` is ⌘ on a Mac, Ctrl elsewhere. */
|
|
67
|
+
exports.SHORTCUTS = [
|
|
68
|
+
{ keys: 'Mod+,', label: 'ta.shortcut.settings' },
|
|
69
|
+
{ keys: 'Mod+B', label: 'ta.shortcut.sidebar' },
|
|
70
|
+
{ keys: 'Enter', label: 'ta.shortcut.send' },
|
|
71
|
+
{ keys: 'Shift+Enter', label: 'ta.shortcut.newline' },
|
|
72
|
+
{ keys: 'Alt+Enter', label: 'ta.shortcut.followUp' },
|
|
73
|
+
{ keys: 'Esc', label: 'ta.shortcut.stop' },
|
|
74
|
+
{ keys: '/', label: 'ta.shortcut.commands' },
|
|
75
|
+
{ keys: '@', label: 'ta.shortcut.files' },
|
|
76
|
+
{ keys: 'Mod+S', label: 'ta.shortcut.save' },
|
|
77
|
+
];
|
|
78
|
+
/**
|
|
79
|
+
* The packages pi loads, as the server lists them, those turned off too: the built-in ones turn off and
|
|
80
|
+
* stay; the others turn off and on, and go.
|
|
81
|
+
*/
|
|
82
|
+
function usePackages() {
|
|
83
|
+
const [workbench, bench] = (0, hooks_1.useWorkbench)();
|
|
84
|
+
const [, host] = (0, hooks_1.useWebExtensions)();
|
|
85
|
+
const [packages, setPackages] = React.useState([]);
|
|
86
|
+
const read = React.useCallback(() => bench.packages.listPackages().then(setPackages), [bench]);
|
|
87
|
+
React.useEffect(() => {
|
|
88
|
+
if (workbench.status === 'online') {
|
|
89
|
+
read().catch(() => undefined);
|
|
90
|
+
}
|
|
91
|
+
}, [workbench.status, read]);
|
|
92
|
+
const changed = async () => {
|
|
93
|
+
await host.reloadPackages();
|
|
94
|
+
await read();
|
|
95
|
+
};
|
|
96
|
+
/** By the name of a built-in package, by the id of another. */
|
|
97
|
+
const toggle = async (pkg, on) => {
|
|
98
|
+
setPackages(current => current.map(other => (other.id === pkg.id ? { ...other, enabled: on } : other)));
|
|
99
|
+
await bench.packages.setPackageEnabled(pkg.origin === 'builtin' ? pkg.name : pkg.id, on);
|
|
100
|
+
await changed();
|
|
101
|
+
};
|
|
102
|
+
const remove = async (pkg) => {
|
|
103
|
+
await bench.packages.removePackage(pkg.id);
|
|
104
|
+
await changed();
|
|
105
|
+
};
|
|
106
|
+
return { packages, toggle, remove, read };
|
|
107
|
+
}
|
|
108
|
+
exports.SLOTS = Array.from({ length: navigation_1.NavigationUtil.MAX_SLOTS - navigation_1.NavigationUtil.MIN_SLOTS + 1 }, (_, index) => {
|
|
109
|
+
const value = String(navigation_1.NavigationUtil.MIN_SLOTS + index);
|
|
110
|
+
return { value, label: value };
|
|
111
|
+
});
|
|
112
|
+
/** The rows of the navigation: how many pages it shows, and where each page is. */
|
|
113
|
+
function navigationRows(navigation, t) {
|
|
114
|
+
const { setting } = navigation;
|
|
115
|
+
const where = (id, byDefault) => {
|
|
116
|
+
if (setting.pinned.includes(id) && navigation.nav.some(page => page.id === id)) {
|
|
117
|
+
return t('ta.settings.navigation.pinned');
|
|
118
|
+
}
|
|
119
|
+
if (navigation.nav.some(page => page.id === id)) {
|
|
120
|
+
return t('ta.settings.navigation.inNav');
|
|
121
|
+
}
|
|
122
|
+
return t(setting.discover.includes(id) || byDefault ? 'ta.settings.navigation.folded' : 'ta.settings.navigation.overflow');
|
|
123
|
+
};
|
|
124
|
+
return [
|
|
125
|
+
(0, settings_controls_1.row)('navigation-slots', [t('ta.settings.navigation.slots'), t('ta.settings.navigation.slotsHint'), t('ta.discover')], React.createElement(settings_controls_1.Row, { label: t('ta.settings.navigation.slots'), description: t('ta.settings.navigation.slotsHint'), stacked: true },
|
|
126
|
+
React.createElement(settings_controls_1.Segmented, { label: t('ta.settings.navigation.slots'), value: String(setting.slots), choices: exports.SLOTS, onChange: slots => navigation.update({ ...setting, slots: Number(slots) }) }))),
|
|
127
|
+
...navigation.pages.map(page => {
|
|
128
|
+
const title = web_extension_protocol_1.WebLabelUtil.text(page.title);
|
|
129
|
+
const shown = navigation.nav.includes(page);
|
|
130
|
+
return (0, settings_controls_1.row)(`navigation:${page.id}`, [title, t('ta.settings.navigation')], React.createElement(settings_controls_1.Row, { label: title, description: where(page.id, page.discover) },
|
|
131
|
+
React.createElement(settings_controls_1.Switch, { label: `${t('ta.settings.navigation.show')} · ${title}`, checked: shown, onChange: on => (on ? navigation.pin(page.id) : navigation.fold(page.id)) })));
|
|
132
|
+
}),
|
|
133
|
+
...(navigation.pages.length === 0
|
|
134
|
+
? [(0, settings_controls_1.row)('navigation:none', [t('ta.settings.navigation.none')], React.createElement(settings_controls_1.EmptyRow, { title: t('ta.settings.navigation.none') }))]
|
|
135
|
+
: []),
|
|
136
|
+
...(navigation_1.NavigationUtil.moved(setting)
|
|
137
|
+
? [
|
|
138
|
+
(0, settings_controls_1.row)('navigation-reset', [t('ta.settings.navigation.reset')], React.createElement(settings_controls_1.Row, { label: t('ta.settings.navigation.reset'), description: t('ta.settings.navigation.resetHint') },
|
|
139
|
+
React.createElement("button", { type: "button", className: "ta-button", onClick: () => navigation.update(navigation_1.NavigationUtil.reset(setting)) },
|
|
140
|
+
React.createElement(icon_1.Icon, { icon: lucide_react_1.RefreshCw, size: 14 }),
|
|
141
|
+
" ",
|
|
142
|
+
t('ta.settings.navigation.resetButton')))),
|
|
143
|
+
]
|
|
144
|
+
: []),
|
|
145
|
+
];
|
|
146
|
+
}
|
|
147
|
+
/** How a package shows in a row: what it calls itself for people, else its name and the description of its package.json. */
|
|
148
|
+
function packageLabel(pkg, language) {
|
|
149
|
+
var _a, _b;
|
|
150
|
+
return {
|
|
151
|
+
title: (_a = ta_protocol_1.TaPackageTextUtil.pick(pkg.title, language)) !== null && _a !== void 0 ? _a : pkg.name,
|
|
152
|
+
summary: (_b = ta_protocol_1.TaPackageTextUtil.pick(pkg.summary, language)) !== null && _b !== void 0 ? _b : pkg.description,
|
|
153
|
+
icon: (pkg.icon && icons_1.WEB_ICONS[pkg.icon]) || lucide_react_1.Puzzle,
|
|
154
|
+
};
|
|
155
|
+
}
|
|
156
|
+
//# sourceMappingURL=settings-choices.js.map
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import type { TaSettingsScope } from '@celljs/ta-protocol';
|
|
2
|
+
import { type LucideIcon } from 'lucide-react';
|
|
3
|
+
import * as React from 'react';
|
|
4
|
+
import { type RowEntry } from './settings-controls';
|
|
5
|
+
export interface SectionEntry {
|
|
6
|
+
id: string;
|
|
7
|
+
title: string;
|
|
8
|
+
icon: LucideIcon;
|
|
9
|
+
rows: RowEntry[];
|
|
10
|
+
}
|
|
11
|
+
export interface Part {
|
|
12
|
+
id: string;
|
|
13
|
+
title: string;
|
|
14
|
+
sections: SectionEntry[];
|
|
15
|
+
/** Drawn above its sections, whatever the search, and on a phone above each: the scope of the settings of ta. */
|
|
16
|
+
lead?: React.ReactNode;
|
|
17
|
+
}
|
|
18
|
+
/** What a row of the settings opens over them. */
|
|
19
|
+
export type SettingsDialog = 'accounts' | 'directory' | 'relay';
|
|
20
|
+
/** The sections of the page and of ta, by part, with their rows. */
|
|
21
|
+
export declare function useParts(scope: TaSettingsScope, onScope: (scope: TaSettingsScope) => void, onClose: () => void, onDialog: (dialog: SettingsDialog) => void): Part[];
|
|
22
|
+
//# sourceMappingURL=settings-parts.d.ts.map
|