@celljs/ta-web 4.10.0 → 4.11.0
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 +7 -7
- package/README.md +7 -7
- package/esm/browser/assistant/assistant-chat-list.d.ts +11 -0
- package/esm/browser/assistant/assistant-chat-list.js +12 -0
- package/esm/browser/assistant/assistant-extension.js +5 -0
- package/esm/browser/assistant/assistant-protocol.d.ts +2 -1
- package/esm/browser/assistant/assistant-task-book.d.ts +12 -2
- package/esm/browser/assistant/assistant-task-book.js +23 -4
- package/esm/browser/assistant/assistant-task-source.d.ts +1 -1
- package/esm/browser/assistant/assistant-task-source.js +5 -10
- package/esm/browser/assistant/assistant-task-util.d.ts +13 -3
- package/esm/browser/assistant/assistant-task-util.js +59 -12
- package/esm/browser/assistant/assistant-view.js +44 -23
- package/esm/browser/assistant/assistant.d.ts +18 -4
- package/esm/browser/assistant/assistant.js +52 -17
- package/esm/browser/avatar/dino-face.js +1 -2
- package/esm/browser/chat/chat-protocol.d.ts +5 -0
- package/esm/browser/chat/chat-stores.d.ts +8 -5
- package/esm/browser/chat/chat-stores.js +17 -9
- package/esm/browser/chat/chat-view.js +18 -11
- package/esm/browser/chat/chat.d.ts +16 -8
- package/esm/browser/chat/chat.js +86 -51
- package/esm/browser/components/account-menu.d.ts +0 -2
- package/esm/browser/components/account-menu.js +1 -27
- package/esm/browser/components/agent-settings-view.d.ts +3 -2
- package/esm/browser/components/agent-settings-view.js +2 -1
- package/esm/browser/components/app-nav.d.ts +5 -2
- package/esm/browser/components/app-nav.js +22 -9
- package/esm/browser/components/app-shell-hooks.js +5 -3
- package/esm/browser/components/app-view.js +76 -16
- package/esm/browser/components/busy.d.ts +25 -0
- package/esm/browser/components/busy.js +52 -0
- package/esm/browser/components/chat-icon.d.ts +29 -0
- package/esm/browser/components/chat-icon.js +78 -0
- package/esm/browser/components/chat-list.d.ts +73 -6
- package/esm/browser/components/chat-list.js +295 -60
- package/esm/browser/components/chat-seen.d.ts +53 -0
- package/esm/browser/components/chat-seen.js +101 -0
- package/esm/browser/components/composer-box.d.ts +14 -4
- package/esm/browser/components/composer-box.js +104 -64
- package/esm/browser/components/composer.d.ts +6 -6
- package/esm/browser/components/composer.js +5 -3
- package/esm/browser/components/conversation-scroll.d.ts +7 -0
- package/esm/browser/components/conversation-scroll.js +46 -7
- package/esm/browser/components/custom-host.d.ts +3 -0
- package/esm/browser/components/custom-host.js +14 -0
- package/esm/browser/components/directory-commands.d.ts +6 -0
- package/esm/browser/components/directory-commands.js +34 -0
- package/esm/browser/components/discover-view.d.ts +11 -4
- package/esm/browser/components/discover-view.js +20 -11
- package/esm/browser/components/dismiss.d.ts +3 -0
- package/esm/browser/components/dismiss.js +29 -0
- package/esm/browser/components/earlier-messages.d.ts +34 -3
- package/esm/browser/components/earlier-messages.js +42 -8
- package/esm/browser/components/editor-area.d.ts +6 -22
- package/esm/browser/components/editor-area.js +10 -97
- package/esm/browser/components/fold-text.d.ts +20 -0
- package/esm/browser/components/fold-text.js +66 -0
- package/esm/browser/components/folder-picker.d.ts +1 -1
- package/esm/browser/components/folder-picker.js +1 -1
- package/esm/browser/components/full-screen.d.ts +9 -0
- package/esm/browser/components/full-screen.js +26 -0
- package/esm/browser/components/grow-box.d.ts +9 -0
- package/esm/browser/components/grow-box.js +50 -0
- package/esm/browser/components/hold-to-talk.d.ts +22 -0
- package/esm/browser/components/hold-to-talk.js +29 -0
- package/esm/browser/components/host-view.d.ts +1 -1
- package/esm/browser/components/icon.d.ts +3 -1
- package/esm/browser/components/icon.js +4 -3
- package/esm/browser/components/image-viewer.d.ts +10 -2
- package/esm/browser/components/image-viewer.js +48 -11
- package/esm/browser/components/launcher-search-util.d.ts +4 -3
- package/esm/browser/components/launcher-search-util.js +12 -4
- package/esm/browser/components/lightbox.d.ts +5 -2
- package/esm/browser/components/lightbox.js +4 -3
- package/esm/browser/components/list-rows.d.ts +9 -1
- package/esm/browser/components/list-rows.js +17 -3
- package/esm/browser/components/markdown.js +36 -4
- package/esm/browser/components/media.js +19 -2
- package/esm/browser/components/message-actions.js +2 -0
- package/esm/browser/components/message-footer.d.ts +6 -0
- package/esm/browser/components/message-footer.js +20 -3
- package/esm/browser/components/message-list.d.ts +57 -6
- package/esm/browser/components/message-list.js +152 -36
- package/esm/browser/components/message-menu.js +6 -1
- package/esm/browser/components/model-picker.js +1 -0
- package/esm/browser/components/nav-places.d.ts +21 -2
- package/esm/browser/components/nav-places.js +20 -4
- package/esm/browser/components/notice-center.js +34 -0
- package/esm/browser/components/notice-face.d.ts +10 -0
- package/esm/browser/components/notice-face.js +28 -0
- package/esm/browser/components/phone-shell.d.ts +23 -1
- package/esm/browser/components/phone-shell.js +96 -9
- package/esm/browser/components/picture.d.ts +8 -1
- package/esm/browser/components/picture.js +12 -1
- package/esm/browser/components/plus-menu.d.ts +23 -0
- package/esm/browser/components/plus-menu.js +90 -0
- package/esm/browser/components/recent-shot.d.ts +15 -0
- package/esm/browser/components/recent-shot.js +174 -0
- package/esm/browser/components/relay-view.js +10 -3
- package/esm/browser/components/run-status.d.ts +1 -1
- package/esm/browser/components/run-status.js +17 -29
- package/esm/browser/components/said-text.d.ts +6 -0
- package/esm/browser/components/said-text.js +14 -0
- package/esm/browser/components/scan-screen.d.ts +10 -0
- package/esm/browser/components/scan-screen.js +230 -0
- package/esm/browser/components/search-page.js +10 -6
- package/esm/browser/components/session-settings.d.ts +2 -3
- package/esm/browser/components/session-settings.js +1 -0
- package/esm/browser/components/session-view.js +29 -19
- package/esm/browser/components/settings-choices.d.ts +1 -0
- package/esm/browser/components/settings-choices.js +3 -2
- package/esm/browser/components/settings-controls.d.ts +5 -3
- package/esm/browser/components/settings-controls.js +10 -1
- package/esm/browser/components/settings-parts.js +45 -14
- package/esm/browser/components/tool-view.js +7 -2
- package/esm/browser/components/unseen-drop.d.ts +39 -0
- package/esm/browser/components/unseen-drop.js +219 -0
- package/esm/browser/components/use-seen-chats.d.ts +8 -0
- package/esm/browser/components/use-seen-chats.js +49 -0
- package/esm/browser/components/voice-button.d.ts +7 -1
- package/esm/browser/components/voice-button.js +15 -2
- package/esm/browser/components/voice-picker.d.ts +6 -0
- package/esm/browser/components/voice-picker.js +53 -0
- package/esm/browser/components/voice-talk.d.ts +11 -3
- package/esm/browser/components/voice-talk.js +24 -4
- package/esm/browser/components/web-composer.d.ts +4 -2
- package/esm/browser/components/web-composer.js +8 -4
- package/esm/browser/components/workbench-tabs.d.ts +41 -0
- package/esm/browser/components/workbench-tabs.js +193 -0
- package/esm/browser/components/workbench-toggle.d.ts +0 -13
- package/esm/browser/components/workbench-toggle.js +1 -28
- package/esm/browser/device/code-scan.d.ts +55 -0
- package/esm/browser/device/code-scan.js +137 -0
- package/esm/browser/device/code-vision.d.ts +51 -0
- package/esm/browser/device/code-vision.js +100 -0
- package/esm/browser/device/hold.js +4 -6
- package/esm/browser/device/long-press.d.ts +10 -0
- package/esm/browser/device/long-press.js +28 -12
- package/esm/browser/device/own-gestures.d.ts +25 -0
- package/esm/browser/device/own-gestures.js +39 -0
- package/esm/browser/device/pull-down.js +3 -2
- package/esm/browser/device/recent-shots.d.ts +45 -0
- package/esm/browser/device/recent-shots.js +142 -0
- package/esm/browser/device/row-swipe.js +6 -1
- package/esm/browser/device/sheet-swipe.js +8 -1
- package/esm/browser/extension/extension-view.d.ts +10 -0
- package/esm/browser/extension/extension-view.js +6 -0
- package/esm/browser/extension/icons.js +15 -2
- package/esm/browser/extension/web-api-components.d.ts +269 -0
- package/esm/browser/extension/web-api-components.js +2 -0
- package/esm/browser/extension/web-api-contributions.d.ts +385 -0
- package/esm/browser/extension/web-api-contributions.js +2 -0
- package/esm/browser/extension/web-api-desktop.d.ts +55 -0
- package/esm/browser/extension/web-api-desktop.js +2 -0
- package/esm/browser/extension/web-api-terminal.d.ts +71 -0
- package/esm/browser/extension/web-api-terminal.js +2 -0
- package/esm/browser/extension/web-editor-tabs.d.ts +42 -0
- package/esm/browser/extension/web-editor-tabs.js +137 -0
- package/esm/browser/extension/web-extension-api.d.ts +166 -565
- package/esm/browser/extension/web-extension-context.d.ts +78 -0
- package/esm/browser/extension/web-extension-context.js +346 -0
- package/esm/browser/extension/web-extension-protocol.d.ts +44 -6
- package/esm/browser/extension/web-extension-protocol.js +33 -0
- package/esm/browser/extension/web-extension-run.d.ts +54 -0
- package/esm/browser/extension/web-extension-run.js +120 -0
- package/esm/browser/extension/web-extensions.d.ts +29 -69
- package/esm/browser/extension/web-extensions.js +118 -516
- package/esm/browser/extension/web-home.d.ts +19 -0
- package/esm/browser/extension/web-home.js +72 -0
- package/esm/browser/extension/web-pages.d.ts +13 -3
- package/esm/browser/extension/web-pages.js +23 -3
- package/esm/browser/extension/web-session-notices.d.ts +36 -0
- package/esm/browser/extension/web-session-notices.js +174 -0
- package/esm/browser/extension/web-sharing.d.ts +2 -0
- package/esm/browser/extension/web-sharing.js +4 -0
- package/esm/browser/game/game-host.d.ts +27 -0
- package/esm/browser/game/game-host.js +127 -0
- package/esm/browser/game/game-loader.d.ts +10 -0
- package/esm/browser/game/game-loader.js +28 -0
- package/esm/browser/game/game-protocol.d.ts +49 -0
- package/esm/browser/game/game-protocol.js +2 -0
- package/esm/browser/game/game-runner.d.ts +27 -0
- package/esm/browser/game/game-runner.js +60 -0
- package/esm/browser/game/game-util.d.ts +29 -0
- package/esm/browser/game/game-util.js +180 -0
- package/esm/browser/game/game-view.d.ts +12 -0
- package/esm/browser/game/game-view.js +31 -0
- package/esm/browser/game/game3d-protocol.d.ts +51 -0
- package/esm/browser/game/game3d-protocol.js +2 -0
- package/esm/browser/game/game3d-runner.d.ts +27 -0
- package/esm/browser/game/game3d-runner.js +149 -0
- package/esm/browser/hooks.d.ts +5 -1
- package/esm/browser/hooks.js +13 -2
- package/esm/browser/i18n/locales.d.ts +82 -2
- package/esm/browser/i18n/messages.d.ts +81 -1
- package/esm/browser/i18n/messages.js +167 -7
- package/esm/browser/index.d.ts +9 -0
- package/esm/browser/index.js +9 -0
- package/esm/browser/links/links-protocol.d.ts +5 -0
- package/esm/browser/links/links.d.ts +19 -7
- package/esm/browser/links/links.js +57 -11
- package/esm/browser/markdown/code-renderers.d.ts +4 -0
- package/esm/browser/markdown/code-renderers.js +4 -0
- package/esm/browser/notices/notices-protocol.d.ts +17 -0
- package/esm/browser/notices/notices.d.ts +1 -1
- package/esm/browser/notices/notices.js +6 -2
- package/esm/browser/notices/session-notices.d.ts +69 -0
- package/esm/browser/notices/session-notices.js +92 -0
- package/esm/browser/offline/device-values.js +12 -3
- package/esm/browser/offline/offline-reads.js +3 -1
- package/esm/browser/settings/navigation.d.ts +3 -2
- package/esm/browser/settings/navigation.js +4 -3
- package/esm/browser/settings/settings-protocol.d.ts +15 -0
- package/esm/browser/settings/settings-protocol.js +18 -4
- package/esm/browser/state/state-protocol.d.ts +8 -1
- package/esm/browser/state/state.d.ts +2 -0
- package/esm/browser/state/state.js +21 -2
- package/esm/browser/style/base.d.ts +1 -1
- package/esm/browser/style/base.js +27 -1
- package/esm/browser/style/conversation.d.ts +1 -1
- package/esm/browser/style/conversation.js +43 -5
- package/esm/browser/style/device.js +15 -1
- package/esm/browser/style/layout.d.ts +1 -1
- package/esm/browser/style/layout.js +189 -56
- package/esm/browser/style/pages.d.ts +1 -1
- package/esm/browser/style/pages.js +36 -1
- package/esm/browser/style/phone.d.ts +1 -1
- package/esm/browser/style/phone.js +15 -0
- package/esm/browser/style/shell.d.ts +1 -1
- package/esm/browser/style/shell.js +30 -6
- package/esm/browser/style/surfaces.d.ts +1 -1
- package/esm/browser/style/surfaces.js +2 -2
- package/esm/browser/style/tints.d.ts +27 -0
- package/esm/browser/style/tints.js +56 -0
- package/esm/browser/style.js +13 -1
- package/esm/browser/util/composer.d.ts +6 -0
- package/esm/browser/util/composer.js +16 -0
- package/esm/browser/util/desktop.d.ts +19 -1
- package/esm/browser/util/desktop.js +15 -0
- package/esm/browser/util/link.d.ts +18 -0
- package/esm/browser/util/link.js +66 -1
- package/esm/browser/util/markdown.d.ts +4 -1
- package/esm/browser/util/markdown.js +1 -1
- package/esm/browser/util/message.d.ts +5 -0
- package/esm/browser/util/message.js +30 -0
- package/esm/browser/util/process.d.ts +14 -2
- package/esm/browser/util/process.js +39 -8
- package/esm/browser/util/progress.d.ts +19 -1
- package/esm/browser/util/progress.js +57 -4
- package/esm/browser/util/quote.d.ts +19 -0
- package/esm/browser/util/quote.js +58 -0
- package/esm/browser/util/tool.d.ts +19 -2
- package/esm/browser/util/tool.js +70 -2
- package/esm/browser/util/voice.d.ts +47 -7
- package/esm/browser/util/voice.js +269 -27
- package/esm/browser/workbench-calls.d.ts +6 -4
- package/esm/browser/workbench-calls.js +15 -10
- package/esm/browser/workbench-protocol.d.ts +31 -2
- package/esm/browser/workbench-util.d.ts +15 -4
- package/esm/browser/workbench-util.js +28 -5
- package/esm/browser/workbench.d.ts +33 -1
- package/esm/browser/workbench.js +142 -14
- package/lib/browser/assistant/assistant-chat-list.d.ts +11 -0
- package/lib/browser/assistant/assistant-chat-list.js +13 -0
- package/lib/browser/assistant/assistant-extension.js +5 -0
- package/lib/browser/assistant/assistant-protocol.d.ts +2 -1
- package/lib/browser/assistant/assistant-task-book.d.ts +12 -2
- package/lib/browser/assistant/assistant-task-book.js +23 -4
- package/lib/browser/assistant/assistant-task-source.d.ts +1 -1
- package/lib/browser/assistant/assistant-task-source.js +5 -10
- package/lib/browser/assistant/assistant-task-util.d.ts +13 -3
- package/lib/browser/assistant/assistant-task-util.js +59 -12
- package/lib/browser/assistant/assistant-view.js +42 -21
- package/lib/browser/assistant/assistant.d.ts +18 -4
- package/lib/browser/assistant/assistant.js +52 -17
- package/lib/browser/avatar/dino-face.js +1 -2
- package/lib/browser/chat/chat-protocol.d.ts +5 -0
- package/lib/browser/chat/chat-stores.d.ts +8 -5
- package/lib/browser/chat/chat-stores.js +17 -9
- package/lib/browser/chat/chat-view.js +17 -10
- package/lib/browser/chat/chat.d.ts +16 -8
- package/lib/browser/chat/chat.js +86 -51
- package/lib/browser/components/account-menu.d.ts +0 -2
- package/lib/browser/components/account-menu.js +2 -29
- package/lib/browser/components/agent-settings-view.d.ts +3 -2
- package/lib/browser/components/agent-settings-view.js +2 -1
- package/lib/browser/components/app-nav.d.ts +5 -2
- package/lib/browser/components/app-nav.js +18 -5
- package/lib/browser/components/app-shell-hooks.js +5 -3
- package/lib/browser/components/app-view.js +72 -12
- package/lib/browser/components/busy.d.ts +26 -0
- package/lib/browser/components/busy.js +91 -0
- package/lib/browser/components/chat-icon.d.ts +30 -0
- package/lib/browser/components/chat-icon.js +117 -0
- package/lib/browser/components/chat-list.d.ts +73 -6
- package/lib/browser/components/chat-list.js +295 -59
- package/lib/browser/components/chat-seen.d.ts +54 -0
- package/lib/browser/components/chat-seen.js +104 -0
- package/lib/browser/components/composer-box.d.ts +14 -4
- package/lib/browser/components/composer-box.js +102 -62
- package/lib/browser/components/composer.d.ts +6 -6
- package/lib/browser/components/composer.js +4 -2
- package/lib/browser/components/conversation-scroll.d.ts +7 -0
- package/lib/browser/components/conversation-scroll.js +46 -7
- package/lib/browser/components/custom-host.d.ts +4 -0
- package/lib/browser/components/custom-host.js +50 -0
- package/lib/browser/components/directory-commands.d.ts +7 -0
- package/lib/browser/components/directory-commands.js +70 -0
- package/lib/browser/components/discover-view.d.ts +11 -4
- package/lib/browser/components/discover-view.js +19 -10
- package/lib/browser/components/dismiss.d.ts +4 -0
- package/lib/browser/components/dismiss.js +65 -0
- package/lib/browser/components/earlier-messages.d.ts +34 -3
- package/lib/browser/components/earlier-messages.js +44 -9
- package/lib/browser/components/editor-area.d.ts +6 -22
- package/lib/browser/components/editor-area.js +11 -98
- package/lib/browser/components/fold-text.d.ts +21 -0
- package/lib/browser/components/fold-text.js +103 -0
- package/lib/browser/components/folder-picker.d.ts +1 -1
- package/lib/browser/components/folder-picker.js +1 -1
- package/lib/browser/components/full-screen.d.ts +10 -0
- package/lib/browser/components/full-screen.js +62 -0
- package/lib/browser/components/grow-box.d.ts +10 -0
- package/lib/browser/components/grow-box.js +86 -0
- package/lib/browser/components/hold-to-talk.d.ts +23 -0
- package/lib/browser/components/hold-to-talk.js +65 -0
- package/lib/browser/components/host-view.d.ts +1 -1
- package/lib/browser/components/icon.d.ts +3 -1
- package/lib/browser/components/icon.js +4 -3
- package/lib/browser/components/image-viewer.d.ts +10 -2
- package/lib/browser/components/image-viewer.js +47 -10
- package/lib/browser/components/launcher-search-util.d.ts +4 -3
- package/lib/browser/components/launcher-search-util.js +12 -4
- package/lib/browser/components/lightbox.d.ts +5 -2
- package/lib/browser/components/lightbox.js +4 -3
- package/lib/browser/components/list-rows.d.ts +9 -1
- package/lib/browser/components/list-rows.js +18 -3
- package/lib/browser/components/markdown.js +36 -4
- package/lib/browser/components/media.js +19 -2
- package/lib/browser/components/message-actions.js +2 -0
- package/lib/browser/components/message-footer.d.ts +6 -0
- package/lib/browser/components/message-footer.js +20 -2
- package/lib/browser/components/message-list.d.ts +57 -6
- package/lib/browser/components/message-list.js +153 -34
- package/lib/browser/components/message-menu.js +6 -1
- package/lib/browser/components/model-picker.js +1 -0
- package/lib/browser/components/nav-places.d.ts +21 -2
- package/lib/browser/components/nav-places.js +22 -4
- package/lib/browser/components/notice-center.js +34 -0
- package/lib/browser/components/notice-face.d.ts +11 -0
- package/lib/browser/components/notice-face.js +64 -0
- package/lib/browser/components/phone-shell.d.ts +23 -1
- package/lib/browser/components/phone-shell.js +97 -10
- package/lib/browser/components/picture.d.ts +8 -1
- package/lib/browser/components/picture.js +13 -1
- package/lib/browser/components/plus-menu.d.ts +24 -0
- package/lib/browser/components/plus-menu.js +126 -0
- package/lib/browser/components/recent-shot.d.ts +16 -0
- package/lib/browser/components/recent-shot.js +210 -0
- package/lib/browser/components/relay-view.js +10 -3
- package/lib/browser/components/run-status.d.ts +1 -1
- package/lib/browser/components/run-status.js +17 -29
- package/lib/browser/components/said-text.d.ts +7 -0
- package/lib/browser/components/said-text.js +50 -0
- package/lib/browser/components/scan-screen.d.ts +11 -0
- package/lib/browser/components/scan-screen.js +266 -0
- package/lib/browser/components/search-page.js +10 -6
- package/lib/browser/components/session-settings.d.ts +2 -3
- package/lib/browser/components/session-settings.js +1 -0
- package/lib/browser/components/session-view.js +26 -16
- package/lib/browser/components/settings-choices.d.ts +1 -0
- package/lib/browser/components/settings-choices.js +2 -1
- package/lib/browser/components/settings-controls.d.ts +5 -3
- package/lib/browser/components/settings-controls.js +10 -1
- package/lib/browser/components/settings-parts.js +43 -12
- package/lib/browser/components/tool-view.js +7 -2
- package/lib/browser/components/unseen-drop.d.ts +40 -0
- package/lib/browser/components/unseen-drop.js +256 -0
- package/lib/browser/components/use-seen-chats.d.ts +9 -0
- package/lib/browser/components/use-seen-chats.js +85 -0
- package/lib/browser/components/voice-button.d.ts +7 -1
- package/lib/browser/components/voice-button.js +16 -2
- package/lib/browser/components/voice-picker.d.ts +7 -0
- package/lib/browser/components/voice-picker.js +89 -0
- package/lib/browser/components/voice-talk.d.ts +11 -3
- package/lib/browser/components/voice-talk.js +25 -4
- package/lib/browser/components/web-composer.d.ts +4 -2
- package/lib/browser/components/web-composer.js +7 -3
- package/lib/browser/components/workbench-tabs.d.ts +42 -0
- package/lib/browser/components/workbench-tabs.js +232 -0
- package/lib/browser/components/workbench-toggle.d.ts +0 -13
- package/lib/browser/components/workbench-toggle.js +1 -29
- package/lib/browser/device/code-scan.d.ts +56 -0
- package/lib/browser/device/code-scan.js +141 -0
- package/lib/browser/device/code-vision.d.ts +52 -0
- package/lib/browser/device/code-vision.js +103 -0
- package/lib/browser/device/hold.js +4 -6
- package/lib/browser/device/long-press.d.ts +10 -0
- package/lib/browser/device/long-press.js +28 -12
- package/lib/browser/device/own-gestures.d.ts +26 -0
- package/lib/browser/device/own-gestures.js +42 -0
- package/lib/browser/device/pull-down.js +3 -2
- package/lib/browser/device/recent-shots.d.ts +46 -0
- package/lib/browser/device/recent-shots.js +145 -0
- package/lib/browser/device/row-swipe.js +6 -1
- package/lib/browser/device/sheet-swipe.js +8 -1
- package/lib/browser/extension/extension-view.d.ts +10 -0
- package/lib/browser/extension/extension-view.js +7 -1
- package/lib/browser/extension/icons.js +14 -1
- package/lib/browser/extension/web-api-components.d.ts +270 -0
- package/lib/browser/extension/web-api-components.js +3 -0
- package/lib/browser/extension/web-api-contributions.d.ts +386 -0
- package/lib/browser/extension/web-api-contributions.js +3 -0
- package/lib/browser/extension/web-api-desktop.d.ts +56 -0
- package/lib/browser/extension/web-api-desktop.js +3 -0
- package/lib/browser/extension/web-api-terminal.d.ts +72 -0
- package/lib/browser/extension/web-api-terminal.js +3 -0
- package/lib/browser/extension/web-editor-tabs.d.ts +43 -0
- package/lib/browser/extension/web-editor-tabs.js +141 -0
- package/lib/browser/extension/web-extension-api.d.ts +166 -565
- package/lib/browser/extension/web-extension-context.d.ts +79 -0
- package/lib/browser/extension/web-extension-context.js +383 -0
- package/lib/browser/extension/web-extension-protocol.d.ts +44 -6
- package/lib/browser/extension/web-extension-protocol.js +34 -1
- package/lib/browser/extension/web-extension-run.d.ts +55 -0
- package/lib/browser/extension/web-extension-run.js +123 -0
- package/lib/browser/extension/web-extensions.d.ts +29 -69
- package/lib/browser/extension/web-extensions.js +114 -545
- package/lib/browser/extension/web-home.d.ts +20 -0
- package/lib/browser/extension/web-home.js +76 -0
- package/lib/browser/extension/web-pages.d.ts +13 -3
- package/lib/browser/extension/web-pages.js +23 -3
- package/lib/browser/extension/web-session-notices.d.ts +37 -0
- package/lib/browser/extension/web-session-notices.js +177 -0
- package/lib/browser/extension/web-sharing.d.ts +2 -0
- package/lib/browser/extension/web-sharing.js +4 -0
- package/lib/browser/game/game-host.d.ts +28 -0
- package/lib/browser/game/game-host.js +163 -0
- package/lib/browser/game/game-loader.d.ts +11 -0
- package/lib/browser/game/game-loader.js +31 -0
- package/lib/browser/game/game-protocol.d.ts +50 -0
- package/lib/browser/game/game-protocol.js +3 -0
- package/lib/browser/game/game-runner.d.ts +28 -0
- package/lib/browser/game/game-runner.js +64 -0
- package/lib/browser/game/game-util.d.ts +30 -0
- package/lib/browser/game/game-util.js +183 -0
- package/lib/browser/game/game-view.d.ts +13 -0
- package/lib/browser/game/game-view.js +68 -0
- package/lib/browser/game/game3d-protocol.d.ts +52 -0
- package/lib/browser/game/game3d-protocol.js +3 -0
- package/lib/browser/game/game3d-runner.d.ts +28 -0
- package/lib/browser/game/game3d-runner.js +153 -0
- package/lib/browser/hooks.d.ts +5 -1
- package/lib/browser/hooks.js +14 -2
- package/lib/browser/i18n/locales.d.ts +82 -2
- package/lib/browser/i18n/messages.d.ts +81 -1
- package/lib/browser/i18n/messages.js +167 -7
- package/lib/browser/index.d.ts +9 -0
- package/lib/browser/index.js +9 -0
- package/lib/browser/links/links-protocol.d.ts +5 -0
- package/lib/browser/links/links.d.ts +19 -7
- package/lib/browser/links/links.js +57 -11
- package/lib/browser/markdown/code-renderers.d.ts +5 -0
- package/lib/browser/markdown/code-renderers.js +40 -0
- package/lib/browser/notices/notices-protocol.d.ts +17 -0
- package/lib/browser/notices/notices.d.ts +1 -1
- package/lib/browser/notices/notices.js +6 -2
- package/lib/browser/notices/session-notices.d.ts +70 -0
- package/lib/browser/notices/session-notices.js +96 -0
- package/lib/browser/offline/device-values.js +12 -3
- package/lib/browser/offline/offline-reads.js +3 -1
- package/lib/browser/settings/navigation.d.ts +3 -2
- package/lib/browser/settings/navigation.js +4 -3
- package/lib/browser/settings/settings-protocol.d.ts +15 -0
- package/lib/browser/settings/settings-protocol.js +19 -5
- package/lib/browser/state/state-protocol.d.ts +8 -1
- package/lib/browser/state/state.d.ts +2 -0
- package/lib/browser/state/state.js +21 -2
- package/lib/browser/style/base.d.ts +1 -1
- package/lib/browser/style/base.js +27 -1
- package/lib/browser/style/conversation.d.ts +1 -1
- package/lib/browser/style/conversation.js +43 -5
- package/lib/browser/style/device.js +15 -1
- package/lib/browser/style/layout.d.ts +1 -1
- package/lib/browser/style/layout.js +189 -56
- package/lib/browser/style/pages.d.ts +1 -1
- package/lib/browser/style/pages.js +36 -1
- package/lib/browser/style/phone.d.ts +1 -1
- package/lib/browser/style/phone.js +15 -0
- package/lib/browser/style/shell.d.ts +1 -1
- package/lib/browser/style/shell.js +30 -6
- package/lib/browser/style/surfaces.d.ts +1 -1
- package/lib/browser/style/surfaces.js +2 -2
- package/lib/browser/style/tints.d.ts +28 -0
- package/lib/browser/style/tints.js +59 -0
- package/lib/browser/style.js +13 -1
- package/lib/browser/util/composer.d.ts +6 -0
- package/lib/browser/util/composer.js +16 -0
- package/lib/browser/util/desktop.d.ts +19 -1
- package/lib/browser/util/desktop.js +15 -0
- package/lib/browser/util/link.d.ts +18 -0
- package/lib/browser/util/link.js +66 -1
- package/lib/browser/util/markdown.d.ts +4 -1
- package/lib/browser/util/markdown.js +1 -1
- package/lib/browser/util/message.d.ts +5 -0
- package/lib/browser/util/message.js +30 -0
- package/lib/browser/util/process.d.ts +14 -2
- package/lib/browser/util/process.js +39 -8
- package/lib/browser/util/progress.d.ts +19 -1
- package/lib/browser/util/progress.js +57 -4
- package/lib/browser/util/quote.d.ts +20 -0
- package/lib/browser/util/quote.js +61 -0
- package/lib/browser/util/tool.d.ts +19 -2
- package/lib/browser/util/tool.js +70 -2
- package/lib/browser/util/voice.d.ts +47 -7
- package/lib/browser/util/voice.js +269 -27
- package/lib/browser/workbench-calls.d.ts +6 -4
- package/lib/browser/workbench-calls.js +15 -10
- package/lib/browser/workbench-protocol.d.ts +31 -2
- package/lib/browser/workbench-util.d.ts +15 -4
- package/lib/browser/workbench-util.js +28 -5
- package/lib/browser/workbench.d.ts +33 -1
- package/lib/browser/workbench.js +140 -12
- package/package.json +11 -8
|
@@ -1,8 +1,9 @@
|
|
|
1
|
-
import { TaImageNote, TaMessageContext, TaSkillUse } from '@celljs/ta-protocol';
|
|
1
|
+
import { TaImageNote, TaImageSize, TaMessageContext, TaSkillUse } from '@celljs/ta-protocol';
|
|
2
2
|
import { ChevronRight, CircleAlert, Sparkles } from 'lucide-react';
|
|
3
3
|
import * as React from 'react';
|
|
4
4
|
import { CustomMessage, ExtensionBoundary, MessageRenderers, SessionAvatars } from '../extension/extension-view.js';
|
|
5
5
|
import { useT } from '../i18n/use-t.js';
|
|
6
|
+
import { Recent } from '../markdown/lazy.js';
|
|
6
7
|
import { MessageUtil } from '../util/message.js';
|
|
7
8
|
import { ProcessUtil } from '../util/process.js';
|
|
8
9
|
import { ToolUtil } from '../util/tool.js';
|
|
@@ -11,9 +12,10 @@ import { ASK_CLASS } from './conversation-scroll.js';
|
|
|
11
12
|
import { Icon } from './icon.js';
|
|
12
13
|
import { Lightbox } from './lightbox.js';
|
|
13
14
|
import { Markdown } from './markdown.js';
|
|
14
|
-
import { TimeBreak, TurnFooter, UserFooter } from './message-footer.js';
|
|
15
|
+
import { ModelBreak, TimeBreak, TurnFooter, UserFooter } from './message-footer.js';
|
|
15
16
|
import { useMessageMenu } from './message-menu.js';
|
|
16
17
|
import { RunStatus } from './run-status.js';
|
|
18
|
+
import { SaidText } from './said-text.js';
|
|
17
19
|
import { TaAvatar } from './ta-avatar.js';
|
|
18
20
|
import { ToolView } from './tool-view.js';
|
|
19
21
|
/** The session of the conversation: who answers in it may be drawn by the extension of its group. */
|
|
@@ -44,6 +46,8 @@ export function TurnAvatar({ mood }) {
|
|
|
44
46
|
React.createElement(Avatar, { session: session, mood: mood, size: 24 })));
|
|
45
47
|
}
|
|
46
48
|
const TASK_UPDATE = /^<task_update id="[^"]+" title="([^"]*)" status="(\w+)">\n?([\s\S]*?)\n?<\/task_update>$/;
|
|
49
|
+
/** AssistantTaskUtil.renamedNote. */
|
|
50
|
+
const TASK_RENAMED = /^<task_renamed id="[^"]+" was="[^"]+"/;
|
|
47
51
|
/** What the double of the web client told ta about a task that ended: a note, not something the user said. */
|
|
48
52
|
function TaskUpdate({ title, status, result }) {
|
|
49
53
|
const t = useT();
|
|
@@ -54,58 +58,153 @@ function TaskUpdate({ title, status, result }) {
|
|
|
54
58
|
t(`ta.task.${status}`)),
|
|
55
59
|
React.createElement(Markdown, { text: result })));
|
|
56
60
|
}
|
|
57
|
-
/**
|
|
58
|
-
|
|
59
|
-
|
|
61
|
+
/**
|
|
62
|
+
* Where the images of the messages of the user come from that the conversation gave without their bytes
|
|
63
|
+
* (TaShownImage): by the timestamp of the message and the index of the block. Without it they show as their place.
|
|
64
|
+
*/
|
|
65
|
+
export const MessageImages = React.createContext(undefined);
|
|
66
|
+
/** The images shown lately, by message and block: drawn again at once, in this conversation or another view of it. */
|
|
67
|
+
const shownImages = new Recent(48);
|
|
68
|
+
/** The size of the images with their bytes, read once. */
|
|
69
|
+
const sizes = new WeakMap();
|
|
70
|
+
/** How large one image of a message is drawn, at most. */
|
|
71
|
+
const ONE_IMAGE = { width: 220, height: 280 };
|
|
72
|
+
export var UserImageUtil;
|
|
73
|
+
(function (UserImageUtil) {
|
|
74
|
+
/** The images of a message the page can show, with their index among its blocks: with their bytes, or without (TaShownImage). */
|
|
75
|
+
function images(blocks) {
|
|
76
|
+
return blocks.flatMap((block, index) => { var _a; return block.type === 'image' && ((_a = block.mimeType) === null || _a === void 0 ? void 0 : _a.startsWith('image/')) && typeof block.data === 'string' ? [{ block: block, index }] : []; });
|
|
77
|
+
}
|
|
78
|
+
UserImageUtil.images = images;
|
|
79
|
+
/** Its size in pixels: given (TaShownImage), or read from its bytes. */
|
|
80
|
+
function size(block) {
|
|
81
|
+
if (block.width && block.height) {
|
|
82
|
+
return { width: block.width, height: block.height };
|
|
83
|
+
}
|
|
84
|
+
if (!block.data) {
|
|
85
|
+
return undefined;
|
|
86
|
+
}
|
|
87
|
+
if (!sizes.has(block)) {
|
|
88
|
+
sizes.set(block, TaImageSize.of(block.data));
|
|
89
|
+
}
|
|
90
|
+
return sizes.get(block);
|
|
91
|
+
}
|
|
92
|
+
UserImageUtil.size = size;
|
|
93
|
+
/** The box of one image alone, its shape kept, before it loads: nothing moves when it comes. */
|
|
94
|
+
function box(size) {
|
|
95
|
+
if (!size) {
|
|
96
|
+
return undefined;
|
|
97
|
+
}
|
|
98
|
+
const scale = Math.min(1, ONE_IMAGE.width / size.width, ONE_IMAGE.height / size.height);
|
|
99
|
+
return { width: Math.max(1, Math.round(size.width * scale)), aspectRatio: `${size.width} / ${size.height}` };
|
|
100
|
+
}
|
|
101
|
+
UserImageUtil.box = box;
|
|
102
|
+
})(UserImageUtil || (UserImageUtil = {}));
|
|
103
|
+
/** The URLs of the images of a message: those with their bytes at once, the others as `MessageImages` gives them. */
|
|
104
|
+
function useImageSources(images, timestamp) {
|
|
105
|
+
const load = React.useContext(MessageImages);
|
|
106
|
+
const keyOf = (index) => (timestamp === undefined ? undefined : `${timestamp}:${index}`);
|
|
107
|
+
const own = images.map(({ block, index }) => {
|
|
108
|
+
const key = keyOf(index);
|
|
109
|
+
return block.data ? `data:${block.mimeType};base64,${block.data}` : key ? shownImages.get(key) : undefined;
|
|
110
|
+
});
|
|
111
|
+
const [loaded, setLoaded] = React.useState({});
|
|
112
|
+
const wanted = images.filter((image, at) => !own[at] && !loaded[image.index]).map(image => image.index);
|
|
113
|
+
const missing = wanted.join(',');
|
|
114
|
+
// Asked again only for other images: `missing` says which.
|
|
115
|
+
React.useEffect(() => {
|
|
116
|
+
if (!load || timestamp === undefined || !missing) {
|
|
117
|
+
return;
|
|
118
|
+
}
|
|
119
|
+
let live = true;
|
|
120
|
+
for (const index of missing.split(',').map(Number)) {
|
|
121
|
+
load(timestamp, index).then(image => {
|
|
122
|
+
if (image === null || image === void 0 ? void 0 : image.data) {
|
|
123
|
+
const url = `data:${image.mimeType};base64,${image.data}`;
|
|
124
|
+
shownImages.set(`${timestamp}:${index}`, url);
|
|
125
|
+
if (live) {
|
|
126
|
+
setLoaded(current => ({ ...current, [index]: url }));
|
|
127
|
+
}
|
|
128
|
+
}
|
|
129
|
+
}, () => undefined);
|
|
130
|
+
}
|
|
131
|
+
return () => {
|
|
132
|
+
live = false;
|
|
133
|
+
};
|
|
134
|
+
}, [load, timestamp, missing]);
|
|
135
|
+
// Those with their bytes are kept too: the same message given again without them (the conversation read again) shows them at once.
|
|
136
|
+
React.useEffect(() => {
|
|
137
|
+
images.forEach(({ block, index }, at) => {
|
|
138
|
+
const key = keyOf(index);
|
|
139
|
+
if (block.data && key && own[at]) {
|
|
140
|
+
shownImages.set(key, own[at]);
|
|
141
|
+
}
|
|
142
|
+
});
|
|
143
|
+
});
|
|
144
|
+
return images.map(({ index }, at) => { var _a; return (_a = own[at]) !== null && _a !== void 0 ? _a : loaded[index]; });
|
|
60
145
|
}
|
|
61
146
|
/**
|
|
62
147
|
* The images of a message of the user: one keeps its own shape at the size of a bubble, a few stand as
|
|
63
|
-
* squares of one size, and a click on any of them opens it full size over the page.
|
|
148
|
+
* squares of one size, and a click on any of them opens it full size over the page. Each has its place
|
|
149
|
+
* before it loads (its size is known), so that nothing moves as it comes. `timestamp`: of the message,
|
|
150
|
+
* for those given without their bytes (MessageImages).
|
|
64
151
|
*/
|
|
65
|
-
export function UserImages({ blocks }) {
|
|
152
|
+
export function UserImages({ blocks, timestamp }) {
|
|
66
153
|
const t = useT();
|
|
67
154
|
const [open, setOpen] = React.useState();
|
|
68
|
-
const images =
|
|
155
|
+
const images = UserImageUtil.images(blocks);
|
|
156
|
+
const sources = useImageSources(images, timestamp);
|
|
69
157
|
if (images.length === 0) {
|
|
70
158
|
return null;
|
|
71
159
|
}
|
|
72
|
-
const
|
|
160
|
+
const single = images.length === 1 ? UserImageUtil.box(UserImageUtil.size(images[0].block)) : undefined;
|
|
161
|
+
const shown = open !== undefined ? sources[open] : undefined;
|
|
73
162
|
return (React.createElement("div", { className: "ta-user-images", "data-count": Math.min(images.length, 3) },
|
|
74
|
-
images.map((
|
|
75
|
-
|
|
76
|
-
open !== undefined && images[open] && React.createElement(Lightbox, { src: src(images[open]), alt: "", onClose: () => setOpen(undefined) })));
|
|
163
|
+
images.map(({ index }, at) => (React.createElement("button", { key: index, type: "button", className: "ta-user-image", title: t('ta.markdown.enlarge'), disabled: !sources[at], onClick: () => setOpen(at) }, sources[at] ? (React.createElement("img", { className: "ta-thumb", src: sources[at], alt: "", style: single })) : (React.createElement("span", { className: "ta-thumb ta-thumb-waiting", style: single }))))),
|
|
164
|
+
open !== undefined && shown && (React.createElement(Lightbox, { src: shown, alt: "", onClose: () => setOpen(undefined), onPrevious: open > 0 && sources[open - 1] ? () => setOpen(open - 1) : undefined, onNext: open < images.length - 1 && sources[open + 1] ? () => setOpen(open + 1) : undefined }))));
|
|
77
165
|
}
|
|
78
166
|
/**
|
|
79
167
|
* What the user said, in the bubble of a message of theirs, with the pictures they sent with it in the same
|
|
80
168
|
* bubble: the pictures first, the words under them. A message of pictures alone has no bubble of its own.
|
|
81
169
|
* `bubble` is the class of that bubble, which a conversation and the double have of their own.
|
|
82
170
|
*/
|
|
83
|
-
export function UserSaid({ blocks, text, bubble = 'ta-bubble' }) {
|
|
84
|
-
if (
|
|
85
|
-
return text ? React.createElement("div", { className: bubble },
|
|
171
|
+
export function UserSaid({ blocks, text, bubble = 'ta-bubble', timestamp }) {
|
|
172
|
+
if (UserImageUtil.images(blocks).length === 0) {
|
|
173
|
+
return text ? (React.createElement("div", { className: bubble },
|
|
174
|
+
React.createElement(SaidText, { text: text }))) : null;
|
|
86
175
|
}
|
|
87
176
|
return (React.createElement("div", { className: `${bubble} ta-bubble-media${text ? '' : ' ta-bubble-bare'}` },
|
|
88
|
-
React.createElement(UserImages, { blocks: blocks }),
|
|
89
|
-
text && React.createElement(
|
|
177
|
+
React.createElement(UserImages, { blocks: blocks, timestamp: timestamp }),
|
|
178
|
+
text && React.createElement(SaidText, { text: text, className: "ta-bubble-text" })));
|
|
90
179
|
}
|
|
91
180
|
function UserMessage({ message }) {
|
|
92
|
-
var _a;
|
|
93
181
|
const blocks = MessageUtil.blocks(message);
|
|
94
|
-
const
|
|
182
|
+
const said = MessageUtil.text(blocks).trim();
|
|
183
|
+
if (TASK_RENAMED.test(said)) {
|
|
184
|
+
// The double's conversation opened as a conversation: what told it a task's new id is for it only.
|
|
185
|
+
return null;
|
|
186
|
+
}
|
|
187
|
+
const update = TASK_UPDATE.exec(said);
|
|
95
188
|
if (update) {
|
|
96
189
|
return React.createElement(TaskUpdate, { title: update[1], status: update[2], result: update[3] });
|
|
97
190
|
}
|
|
98
|
-
const
|
|
191
|
+
const { text, copied, skill } = userWords(blocks);
|
|
192
|
+
return React.createElement(UserBubble, { message: message, blocks: blocks, text: text, copied: copied, skill: skill });
|
|
193
|
+
}
|
|
194
|
+
/**
|
|
195
|
+
* What a message of the user's shows, in a conversation and the double alike: without the context and the notes of
|
|
196
|
+
* pictures sent with it, a skill they ran (`/skill:name`) taken out of the words as the skill; `copied` is what they typed.
|
|
197
|
+
*/
|
|
198
|
+
export function userWords(blocks) {
|
|
199
|
+
var _a;
|
|
200
|
+
const said = TaImageNote.strip(TaMessageContext.strip(MessageUtil.text(blocks))).trim();
|
|
99
201
|
const skill = TaSkillUse.parse(said);
|
|
100
|
-
|
|
101
|
-
return React.createElement(UserBubble, { message: message, blocks: blocks, text: (_a = skill.message) !== null && _a !== void 0 ? _a : '', copied: TaSkillUse.command(skill), skill: skill });
|
|
102
|
-
}
|
|
103
|
-
return React.createElement(UserBubble, { message: message, blocks: blocks, text: said, copied: said });
|
|
202
|
+
return skill ? { text: (_a = skill.message) !== null && _a !== void 0 ? _a : '', copied: TaSkillUse.command(skill), skill } : { text: said, copied: said };
|
|
104
203
|
}
|
|
105
204
|
/** pi's first line of a skill it read, for the model: the path is in the title of the skill's line. */
|
|
106
205
|
const SKILL_BASE = /^References are relative to [^\n]*\n+/;
|
|
107
206
|
/** A skill the user ran: one line with its name, which opens to the skill's file, as a tool call opens. */
|
|
108
|
-
function SkillUse({ skill }) {
|
|
207
|
+
export function SkillUse({ skill }) {
|
|
109
208
|
const t = useT();
|
|
110
209
|
const [open, setOpen] = React.useState(false);
|
|
111
210
|
return (React.createElement("div", { className: "ta-skill-use" },
|
|
@@ -124,12 +223,12 @@ function UserBubble({ message, blocks, text, copied, skill, }) {
|
|
|
124
223
|
if (sent) {
|
|
125
224
|
// Not in the session yet: nothing to branch from or rewind to.
|
|
126
225
|
return (React.createElement("div", { className: `ta-message ta-user ${sent.failed ? 'ta-user-failed' : 'ta-user-sending'}` },
|
|
127
|
-
React.createElement(UserSaid, { blocks: blocks, text: text }),
|
|
226
|
+
React.createElement(UserSaid, { blocks: blocks, text: text, timestamp: message.timestamp }),
|
|
128
227
|
sent.failed ? React.createElement(SendFailed, { sent: sent, actions: outbox.actions }) : React.createElement("div", { className: "ta-footer" })));
|
|
129
228
|
}
|
|
130
229
|
return (React.createElement("div", { className: "ta-message ta-user", onContextMenu: onContextMenu },
|
|
131
230
|
skill && React.createElement(SkillUse, { skill: skill }),
|
|
132
|
-
React.createElement(UserSaid, { blocks: blocks, text: text }),
|
|
231
|
+
React.createElement(UserSaid, { blocks: blocks, text: text, timestamp: message.timestamp }),
|
|
133
232
|
React.createElement(UserFooter, { message: message, text: copied }),
|
|
134
233
|
menu));
|
|
135
234
|
}
|
|
@@ -245,6 +344,8 @@ export function Process({ steps, active, results, tools, leading, status, }) {
|
|
|
245
344
|
const open = manual !== null && manual !== void 0 ? manual : active;
|
|
246
345
|
const shown = useFold(open && steps.length > 0, stepsRef, !active);
|
|
247
346
|
const folded = ProcessUtil.fold(steps, active, showAll);
|
|
347
|
+
// The earlier steps count as the head does: the calls among them, not the thoughts.
|
|
348
|
+
const earlier = folded.hidden ? ToolUtil.count(ProcessUtil.tools(steps.slice(0, folded.hidden)), results, tools).steps : 0;
|
|
248
349
|
// Only thoughts: the head already says so, the steps need not say it again.
|
|
249
350
|
const thoughtOnly = steps.every(step => step.kind === 'thinking');
|
|
250
351
|
const title = count ? t(active ? 'ta.process.running' : 'ta.process.done', { count }) : t(active ? 'ta.process.thinking' : 'ta.process.thought');
|
|
@@ -258,13 +359,21 @@ export function Process({ steps, active, results, tools, leading, status, }) {
|
|
|
258
359
|
t('ta.process.failed', { count: failed })),
|
|
259
360
|
React.createElement(Icon, { icon: ChevronRight, size: 14, className: "ta-process-chevron" }))) : (status)),
|
|
260
361
|
shown && (React.createElement("div", { id: id, ref: stepsRef, className: "ta-process-steps" },
|
|
261
|
-
folded.hidden > 0 && (React.createElement("button", { type: "button", className: "ta-link ta-more", onClick: () => setShowAll(true) }, t('ta.process.earlier', { count:
|
|
362
|
+
folded.hidden > 0 && (React.createElement("button", { type: "button", className: "ta-link ta-more", onClick: () => setShowAll(true) }, earlier ? t('ta.process.earlier', { count: earlier }) : t('ta.process.showAll'))),
|
|
262
363
|
folded.steps.map(step => (React.createElement(Step, { key: step.key, step: step, results: results, tools: tools, tagged: !thoughtOnly })))))));
|
|
263
364
|
}
|
|
264
365
|
/** A turn that has shown nothing yet: what ta does goes on its head. */
|
|
265
366
|
export function quiet(item) {
|
|
266
367
|
return (item === null || item === void 0 ? void 0 : item.kind) === 'turn' && item.active && !item.steps.length && !item.reply.some(text => text.trim());
|
|
267
368
|
}
|
|
369
|
+
/**
|
|
370
|
+
* A turn that ends with its steps, no words after them: the line of what ta does is one more of its steps
|
|
371
|
+
* (.ta-run-steps). Said by the class, not by `:last-child` in `:has()`: WebKit does not style the line
|
|
372
|
+
* again when the words under the steps go into them, and it stayed out of line until something else drew.
|
|
373
|
+
*/
|
|
374
|
+
export function endsInSteps(item) {
|
|
375
|
+
return (item === null || item === void 0 ? void 0 : item.kind) === 'turn' && item.steps.length > 0 && !item.reply.length;
|
|
376
|
+
}
|
|
268
377
|
function Turn({ item, tools, mood, status, latest, }) {
|
|
269
378
|
var _a;
|
|
270
379
|
const t = useT();
|
|
@@ -337,20 +446,26 @@ const ThreadRow = React.memo(function ThreadRow({ item, tools, mood, status, lat
|
|
|
337
446
|
(next.item.kind === 'message' || !next.item.active || previous.tools === next.tools));
|
|
338
447
|
/** The last rows, which change and are in view, are always laid out. */
|
|
339
448
|
const SETTLED_AFTER = 4;
|
|
340
|
-
/** The conversation; tool results show with the calls they answer. */
|
|
341
|
-
export function MessageList({ state, outbox }) {
|
|
449
|
+
/** The conversation; tool results show with the calls they answer. `rows`: only its latest rows are drawn, more as asked. */
|
|
450
|
+
export function MessageList({ state, outbox, rows }) {
|
|
342
451
|
var _a;
|
|
343
|
-
const items = React.useMemo(() => ProcessUtil.items(state.messages, state.working, state.start), [state.messages, state.working, state.start]);
|
|
344
452
|
const renderers = React.useContext(MessageRenderers);
|
|
453
|
+
const items = React.useMemo(() => ProcessUtil.items(state.messages, state.working, state.start, renderers), [state.messages, state.working, state.start, renderers]);
|
|
345
454
|
const breaks = React.useMemo(() => ProcessUtil.timeBreaks(ProcessUtil.starts(items), index => ProcessUtil.shown(items[index], renderers)), [items, renderers]);
|
|
455
|
+
const models = React.useMemo(() => ProcessUtil.modelBreaks(items), [items]);
|
|
346
456
|
const sent = React.useMemo(() => { var _a; return ({ of: new Map(((_a = state.outbox) !== null && _a !== void 0 ? _a : []).map(message => [message.message, message])), actions: outbox }); }, [state.outbox, outbox]);
|
|
457
|
+
// The rows held back: those before the latest `rows.rows`.
|
|
458
|
+
const from = rows ? Math.max(0, items.length - rows.rows) : 0;
|
|
459
|
+
if (rows) {
|
|
460
|
+
rows.hidden.current = from;
|
|
461
|
+
}
|
|
347
462
|
// Rows of earlier messages put in front are laid out once before they may skip it (content-visibility):
|
|
348
463
|
// their height is then known, and the view does not move as they come near it.
|
|
349
|
-
const firstKey = React.useRef((_a = items[
|
|
350
|
-
const front = Math.max(
|
|
464
|
+
const firstKey = React.useRef((_a = items[from]) === null || _a === void 0 ? void 0 : _a.key);
|
|
465
|
+
const front = Math.max(from, items.findIndex(item => item.key === firstKey.current));
|
|
351
466
|
React.useLayoutEffect(() => {
|
|
352
467
|
var _a;
|
|
353
|
-
firstKey.current = (_a = items[
|
|
468
|
+
firstKey.current = (_a = items[from]) === null || _a === void 0 ? void 0 : _a.key;
|
|
354
469
|
});
|
|
355
470
|
// Rows that come after the list is drawn come in with a motion; those of a conversation opened or loaded again, still.
|
|
356
471
|
const still = React.useRef(items.length);
|
|
@@ -369,7 +484,7 @@ export function MessageList({ state, outbox }) {
|
|
|
369
484
|
const status = state.working || state.compacting ? React.createElement(RunStatus, { state: state }) : undefined;
|
|
370
485
|
const onHead = status && quiet(last);
|
|
371
486
|
return (React.createElement(Outbox.Provider, { value: sent },
|
|
372
|
-
items.map((item, index) => (React.createElement("div", { key: item.key, className: [
|
|
487
|
+
items.map((item, index) => index < from ? null : (React.createElement("div", { key: item.key, className: [
|
|
373
488
|
'ta-thread-item',
|
|
374
489
|
index >= front && index < items.length - SETTLED_AFTER && 'ta-settled',
|
|
375
490
|
index === items.length - 1 && 'ta-thread-last',
|
|
@@ -379,7 +494,8 @@ export function MessageList({ state, outbox }) {
|
|
|
379
494
|
.filter(Boolean)
|
|
380
495
|
.join(' ') },
|
|
381
496
|
breaks[index] !== undefined && React.createElement(TimeBreak, { timestamp: breaks[index] }),
|
|
497
|
+
models[index] && React.createElement(ModelBreak, { model: models[index] }),
|
|
382
498
|
React.createElement(ThreadRow, { item: item, tools: state.tools, mood: item.kind === 'turn' ? ProcessUtil.mood(item, index === lastTurn, waiting) : 'idle', status: onHead && item === last ? status : undefined, latest: index === lastTurn })))),
|
|
383
|
-
status && !onHead && React.createElement("div", { className:
|
|
499
|
+
status && !onHead && React.createElement("div", { className: `ta-run-line ${endsInSteps(last) ? 'ta-run-steps' : ''}` }, status)));
|
|
384
500
|
}
|
|
385
501
|
//# sourceMappingURL=message-list.js.map
|
|
@@ -37,7 +37,12 @@ export function useMessageMenu(subject) {
|
|
|
37
37
|
const items = [];
|
|
38
38
|
const text = subject.kind === 'user' ? subject.text : subject.reply;
|
|
39
39
|
if (text) {
|
|
40
|
-
items.push({ label: t('ta.copy'), run: () => copy(text) }
|
|
40
|
+
items.push({ label: t('ta.copy'), run: () => copy(text) });
|
|
41
|
+
if (actions === null || actions === void 0 ? void 0 : actions.quote) {
|
|
42
|
+
const quote = actions.quote;
|
|
43
|
+
items.push({ label: t('ta.message.quote'), run: () => quote(text) });
|
|
44
|
+
}
|
|
45
|
+
items.push({ label: t('ta.message.selectText'), run: () => setSelecting(text) });
|
|
41
46
|
}
|
|
42
47
|
if (subject.kind === 'user' && branches) {
|
|
43
48
|
items.push('-', { label: t('ta.message.forkBefore'), run: () => actions.fork(subject.message, 'before') }, { label: t('ta.message.rewind'), run: () => actions.rewind(subject.message) });
|
|
@@ -60,6 +60,7 @@ export var ModelPickerUtil;
|
|
|
60
60
|
key: 'model',
|
|
61
61
|
label: t('ta.session.model'),
|
|
62
62
|
icon: React.createElement(Icon, { icon: Box, size: 16 }),
|
|
63
|
+
setting: true,
|
|
63
64
|
detail: value ? name(source, value) : t('ta.session.noModel'),
|
|
64
65
|
searchLabel: t('ta.model.search'),
|
|
65
66
|
items: options(source, value).map(option => ({ ...option, run: () => pick(option.key) })),
|
|
@@ -1,5 +1,7 @@
|
|
|
1
|
+
import type { TaWebExtensionInfo } from '@celljs/ta-protocol';
|
|
1
2
|
import type { Hold } from '../device/hold.js';
|
|
2
3
|
import { type WebViewEntry } from '../extension/web-extension-protocol.js';
|
|
4
|
+
import { type WebPageInfo } from '../extension/web-pages.js';
|
|
3
5
|
import { type NavigationSetting } from '../settings/navigation.js';
|
|
4
6
|
import type { ContextMenuItem } from './context-menu.js';
|
|
5
7
|
import type { PhoneTab } from './phone-shell.js';
|
|
@@ -37,13 +39,30 @@ export interface Navigation {
|
|
|
37
39
|
/** Those in the navigation, and those under Discover (NavigationUtil.arrange). */
|
|
38
40
|
nav: WebViewEntry[];
|
|
39
41
|
discover: WebViewEntry[];
|
|
42
|
+
/**
|
|
43
|
+
* The pages of installed extensions started on open (ta-launcher.md): under Discover after `discover`,
|
|
44
|
+
* never in the navigation, their extensions loaded only when opened.
|
|
45
|
+
*/
|
|
46
|
+
onOpen: WebPageInfo[];
|
|
40
47
|
setting: NavigationSetting;
|
|
41
48
|
pin(id: string): void;
|
|
42
49
|
fold(id: string): void;
|
|
43
50
|
update(setting: NavigationSetting): void;
|
|
44
51
|
}
|
|
45
|
-
/**
|
|
46
|
-
|
|
52
|
+
/**
|
|
53
|
+
* Where the pages of the rail go: the double's first when no sidebar view lists it, the rest as the user put them
|
|
54
|
+
* in the room there is. `own`: Discover lists pages of extensions started on open, so it is there in any case.
|
|
55
|
+
*/
|
|
56
|
+
export declare function places(views: WebViewEntry[], setting: NavigationSetting, handheld: boolean, own?: boolean): Pick<Navigation, 'home' | 'pages' | 'nav' | 'discover'>;
|
|
57
|
+
/**
|
|
58
|
+
* Where each page of the extensions is on this device (WebPageInfo.place): in the navigation, under Discover, or
|
|
59
|
+
* in a list; the pages of a kind that a page lists (the Games page) are only there.
|
|
60
|
+
*/
|
|
61
|
+
export declare function arrangeViews(views: readonly WebViewEntry[], onOpen: readonly {
|
|
62
|
+
info: TaWebExtensionInfo;
|
|
63
|
+
}[], setting: NavigationSetting, handheld: boolean, infoOf: (extensionId: string) => TaWebExtensionInfo | undefined, kinds: ReadonlySet<string>): (view: WebViewEntry) => 'navigation' | 'discover' | 'list';
|
|
64
|
+
/** Discover is in the navigation: some pages are under it. */
|
|
65
|
+
export declare function hasDiscover(navigation: Pick<Navigation, 'discover' | 'onOpen'>): boolean;
|
|
47
66
|
export interface PhoneTabLabels {
|
|
48
67
|
discover: string;
|
|
49
68
|
me: string;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { Compass, PanelTop, User } from 'lucide-react';
|
|
2
2
|
import { WebLabelUtil } from '../extension/web-extension-protocol.js';
|
|
3
|
+
import { WebPagesUtil } from '../extension/web-pages.js';
|
|
3
4
|
import { NavigationUtil } from '../settings/navigation.js';
|
|
4
5
|
import { DOUBLE_PAGE } from './side-lists.js';
|
|
5
6
|
/* The places of the navigation, the same on the rail and in the tabs of a phone: which pages, in what order. */
|
|
@@ -26,13 +27,28 @@ export const ME_TAB = 'ta/me';
|
|
|
26
27
|
export function fixedTabs(views) {
|
|
27
28
|
return views.filter(view => view.location === 'sidebar').length + 2;
|
|
28
29
|
}
|
|
29
|
-
/**
|
|
30
|
-
|
|
30
|
+
/**
|
|
31
|
+
* Where the pages of the rail go: the double's first when no sidebar view lists it, the rest as the user put them
|
|
32
|
+
* in the room there is. `own`: Discover lists pages of extensions started on open, so it is there in any case.
|
|
33
|
+
*/
|
|
34
|
+
export function places(views, setting, handheld, own = false) {
|
|
31
35
|
const all = railPages(views);
|
|
32
36
|
const home = all.find(view => view.id === DOUBLE_PAGE);
|
|
33
37
|
const pages = home ? all.filter(view => view !== home) : all;
|
|
34
38
|
const room = handheld ? Math.max(1, NavigationUtil.PHONE_TABS - fixedTabs(views) - (home ? 1 : 0)) : undefined;
|
|
35
|
-
return { home, pages, ...NavigationUtil.arrange(pages, setting, room) };
|
|
39
|
+
return { home, pages, ...NavigationUtil.arrange(pages, setting, room, own) };
|
|
40
|
+
}
|
|
41
|
+
/**
|
|
42
|
+
* Where each page of the extensions is on this device (WebPageInfo.place): in the navigation, under Discover, or
|
|
43
|
+
* in a list; the pages of a kind that a page lists (the Games page) are only there.
|
|
44
|
+
*/
|
|
45
|
+
export function arrangeViews(views, onOpen, setting, handheld, infoOf, kinds) {
|
|
46
|
+
const arranged = places(views.filter(view => !WebPagesUtil.listed(infoOf(view.extension), kinds)), setting, handheld, onOpen.some(entry => !entry.info.temporary && !WebPagesUtil.listed(entry.info, kinds)));
|
|
47
|
+
return view => (view === arranged.home || arranged.nav.includes(view) ? 'navigation' : arranged.discover.includes(view) ? 'discover' : 'list');
|
|
48
|
+
}
|
|
49
|
+
/** Discover is in the navigation: some pages are under it. */
|
|
50
|
+
export function hasDiscover(navigation) {
|
|
51
|
+
return navigation.discover.length > 0 || navigation.onOpen.length > 0;
|
|
36
52
|
}
|
|
37
53
|
/**
|
|
38
54
|
* The tabs at the bottom of a phone, as a messaging app has them: the lists of the sidebar, the chats, the pages
|
|
@@ -51,7 +67,7 @@ export function phoneTabs(lists, navigation, labels) {
|
|
|
51
67
|
...(navigation.home ? [{ ...tab(navigation.home), double: true, hold: labels.holds.double }] : []),
|
|
52
68
|
...lists.map(list),
|
|
53
69
|
...navigation.nav.map(view => tab(view, [{ label: labels.fold, run: () => navigation.fold(view.id) }, '-', labels.settings])),
|
|
54
|
-
...(navigation
|
|
70
|
+
...(hasDiscover(navigation) ? [{ id: DISCOVER, label: labels.discover, icon: Compass, menu: [labels.settings] }] : []),
|
|
55
71
|
{ id: ME_TAB, label: labels.me, icon: User },
|
|
56
72
|
];
|
|
57
73
|
}
|
|
@@ -6,6 +6,7 @@ import { useT } from '../i18n/use-t.js';
|
|
|
6
6
|
import { NoticesUtil } from '../notices/notices.js';
|
|
7
7
|
import { LEVEL_ICONS } from './callout.js';
|
|
8
8
|
import { Icon, IconButton } from './icon.js';
|
|
9
|
+
import { NoticeFace } from './notice-face.js';
|
|
9
10
|
import { TerminalArt } from './terminal-art.js';
|
|
10
11
|
/** How long a notice takes to go, in style.ts. */
|
|
11
12
|
const LEAVE_MS = 160;
|
|
@@ -42,6 +43,36 @@ function useLifetime(notice, leave) {
|
|
|
42
43
|
onBlur: () => setHeld(false),
|
|
43
44
|
};
|
|
44
45
|
}
|
|
46
|
+
/**
|
|
47
|
+
* What a conversation said, as a messenger's banner: its face and name, what it asks beside it, the message in two
|
|
48
|
+
* lines; a tap opens it, its answers are buttons under it.
|
|
49
|
+
*/
|
|
50
|
+
function SessionToast({ notice, leaving, leave, hold, }) {
|
|
51
|
+
var _a;
|
|
52
|
+
const t = useT();
|
|
53
|
+
const { from } = notice;
|
|
54
|
+
const actions = [...((_a = notice.actions) !== null && _a !== void 0 ? _a : []), ...(notice.action ? [notice.action] : [])];
|
|
55
|
+
const open = () => {
|
|
56
|
+
from.open();
|
|
57
|
+
leave();
|
|
58
|
+
};
|
|
59
|
+
return (React.createElement("div", { className: `ta-toast ta-toast-session${leaving ? ' ta-leaving' : ''}`, role: from.status ? 'alert' : 'status', ...hold },
|
|
60
|
+
React.createElement("button", { type: "button", className: "ta-toast-open", onClick: open },
|
|
61
|
+
React.createElement("span", { className: "ta-toast-face" },
|
|
62
|
+
React.createElement(NoticeFace, { from: from, size: 38 })),
|
|
63
|
+
React.createElement("span", { className: "ta-toast-text" },
|
|
64
|
+
React.createElement("span", { className: "ta-toast-head" },
|
|
65
|
+
React.createElement("span", { className: "ta-toast-title" }, from.title),
|
|
66
|
+
from.status && (React.createElement("span", { className: `ta-chat-state ${from.status === 'ask' ? 'ta-waiting' : 'ta-failed'}` },
|
|
67
|
+
React.createElement("span", { className: `ta-status ${from.status === 'ask' ? 'ta-status-waiting' : 'ta-status-error'}` }),
|
|
68
|
+
t(from.status === 'ask' ? 'ta.task.waiting' : 'ta.task.failed')))),
|
|
69
|
+
React.createElement("span", { className: "ta-toast-message" }, notice.message))),
|
|
70
|
+
actions.length > 0 && (React.createElement("div", { className: "ta-toast-actions" }, actions.map(action => (React.createElement("button", { key: action.label, type: "button", className: "ta-toast-action", onClick: () => {
|
|
71
|
+
action.run();
|
|
72
|
+
leave();
|
|
73
|
+
} }, action.label))))),
|
|
74
|
+
React.createElement(IconButton, { icon: X, label: t('ta.dismiss'), className: "ta-toast-close", onClick: leave })));
|
|
75
|
+
}
|
|
45
76
|
function Toast({ notice, notices }) {
|
|
46
77
|
const t = useT();
|
|
47
78
|
const [leaving, setLeaving] = React.useState(false);
|
|
@@ -50,6 +81,9 @@ function Toast({ notice, notices }) {
|
|
|
50
81
|
setTimeout(() => notices.dismiss(notice.id), LEAVE_MS);
|
|
51
82
|
}, [notices, notice.id]);
|
|
52
83
|
const hold = useLifetime(notice, leave);
|
|
84
|
+
if (notice.from) {
|
|
85
|
+
return React.createElement(SessionToast, { notice: notice, leaving: leaving, leave: leave, hold: hold });
|
|
86
|
+
}
|
|
53
87
|
return (React.createElement("div", { className: `ta-toast ta-level-${notice.level}${notice.art ? ' ta-toast-with-art' : ''}${leaving ? ' ta-leaving' : ''}`, role: notice.level === 'error' ? 'alert' : 'status', ...hold },
|
|
54
88
|
React.createElement(Icon, { icon: LEVEL_ICONS[notice.level], size: 16, className: "ta-level-icon" }),
|
|
55
89
|
React.createElement("div", { className: "ta-toast-text" },
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import type { NoticeFrom } from '../notices/notices-protocol.js';
|
|
3
|
+
/**
|
|
4
|
+
* The face a conversation has in the lists, for a notice it gave (NoticeFrom): the double's, an agent's, else the
|
|
5
|
+
* letter of its directory in its color. Nothing while the lists do not have it.
|
|
6
|
+
*/
|
|
7
|
+
export declare function NoticeFace({ from, size }: {
|
|
8
|
+
from: NoticeFrom;
|
|
9
|
+
size: number;
|
|
10
|
+
}): React.JSX.Element | null;
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import { useAssistant } from '../assistant/assistant-hooks.js';
|
|
3
|
+
import { SessionAvatars } from '../extension/extension-view.js';
|
|
4
|
+
import { useWorkbench } from '../hooks.js';
|
|
5
|
+
import { ChatAvatar, ChatListUtil } from './chat-list.js';
|
|
6
|
+
/**
|
|
7
|
+
* The face a conversation has in the lists, for a notice it gave (NoticeFrom): the double's, an agent's, else the
|
|
8
|
+
* letter of its directory in its color. Nothing while the lists do not have it.
|
|
9
|
+
*/
|
|
10
|
+
export function NoticeFace({ from, size }) {
|
|
11
|
+
var _a;
|
|
12
|
+
var _b;
|
|
13
|
+
const [{ sessions, saved }] = useWorkbench();
|
|
14
|
+
const [, assistant] = useAssistant();
|
|
15
|
+
const avatars = React.useContext(SessionAvatars);
|
|
16
|
+
const all = React.useMemo(() => [...sessions, ...saved], [sessions, saved]);
|
|
17
|
+
const session = (_b = all.find(entry => ChatListUtil.isOpen(entry) && entry.sessionId === from.sessionId)) !== null && _b !== void 0 ? _b : all.find(entry => !!from.sessionFile && entry.sessionFile === from.sessionFile);
|
|
18
|
+
const sources = React.useMemo(() => ChatListUtil.sources(all), [all]);
|
|
19
|
+
if (!session) {
|
|
20
|
+
return null;
|
|
21
|
+
}
|
|
22
|
+
const source = sources.find(candidate => candidate.key === ChatListUtil.sourceKey(session));
|
|
23
|
+
const double = (!!assistant.sessionFile && session.sessionFile === assistant.sessionFile) ||
|
|
24
|
+
(ChatListUtil.isOpen(session) && ((_a = assistant.store()) === null || _a === void 0 ? void 0 : _a.sessionId) === session.sessionId);
|
|
25
|
+
const who = double ? { kind: 'double', name: from.title } : session.group && avatars[session.group] ? { kind: 'agent' } : undefined;
|
|
26
|
+
return source ? React.createElement(ChatAvatar, { session: session, source: source, who: who, size: size, mood: from.status === 'ask' ? 'attention' : 'idle' }) : null;
|
|
27
|
+
}
|
|
28
|
+
//# sourceMappingURL=notice-face.js.map
|
|
@@ -13,6 +13,10 @@ export interface PhoneTab {
|
|
|
13
13
|
menu?: ContextMenuItem[];
|
|
14
14
|
/** What it does while it is held instead: the double listens, the chats open a new conversation. */
|
|
15
15
|
hold?: Hold;
|
|
16
|
+
/** Something in it the user has not seen: an amber dot on its icon, as on the rows of its list. */
|
|
17
|
+
unseen?: boolean;
|
|
18
|
+
/** Sees all of it, as the user drags its dot away (UnseenDrop); the dot stays put without. */
|
|
19
|
+
onSeeAll?(): void;
|
|
16
20
|
}
|
|
17
21
|
export interface PhoneShellProps {
|
|
18
22
|
tabs: PhoneTab[];
|
|
@@ -41,6 +45,13 @@ export interface PhoneShellProps {
|
|
|
41
45
|
}
|
|
42
46
|
/** What comes out over the first tab: the launcher (pulled down), the board (from the right). */
|
|
43
47
|
export type PhoneSurface = 'launcher' | 'board';
|
|
48
|
+
/** A screen pushed over the screen of the phone (PhoneStack): the shell closes it with a swipe or the back of the system. */
|
|
49
|
+
export interface StackLayer {
|
|
50
|
+
close(): void;
|
|
51
|
+
}
|
|
52
|
+
type StackRegister = React.Dispatch<React.SetStateAction<StackLayer | undefined>>;
|
|
53
|
+
/** The page of an extension a PhoneStack is in (PageView): its head shows back while one is pushed, on any device. */
|
|
54
|
+
export declare const PageStackContext: React.Context<StackRegister | undefined>;
|
|
44
55
|
/**
|
|
45
56
|
* Whether the screen of the phone is still sliding in (false elsewhere): what it shows then should be light, a
|
|
46
57
|
* long conversation drawn in its first frames would hold the slide still. True from the render that opens it.
|
|
@@ -66,10 +77,21 @@ export interface PhoneStackProps {
|
|
|
66
77
|
* A screen pushed over the screen of a phone, as iOS pushes a page of its settings over their list: it slides
|
|
67
78
|
* in from the right and goes back with its button, a swipe from the left edge or the back of the system, as
|
|
68
79
|
* the screen under it does (PhoneShell follows the finger and keeps it in the history). Outside a PhoneShell
|
|
69
|
-
* it only slides.
|
|
80
|
+
* it only slides. In the page of an extension (`ui.Stack`), the head of the page shows back while it is open.
|
|
70
81
|
*/
|
|
71
82
|
export declare function PhoneStack({ base, top, open, onClose }: PhoneStackProps): React.JSX.Element;
|
|
72
83
|
export declare namespace PhoneUtil {
|
|
84
|
+
/** Two taps of a tab within this are one double tap. */
|
|
85
|
+
const DOUBLE_TAP_MS = 350;
|
|
86
|
+
/** What marks a row with a dot of something unseen, in any list of the tabs (an extension's too). */
|
|
87
|
+
const UNSEEN = "[data-unseen]";
|
|
88
|
+
/**
|
|
89
|
+
* Scrolls the list of the tab to its next row with a dot, below the top of what shows, else from the first
|
|
90
|
+
* again: each tap one further, as WeChat's. Those all on the screen already are not scrolled to, only lit up.
|
|
91
|
+
* False when it has none.
|
|
92
|
+
*/
|
|
93
|
+
function locate(home: Element | null): boolean;
|
|
73
94
|
/** The tab shown tapped again: what it scrolled goes back to its top, as in the apps of a phone. */
|
|
74
95
|
function toTop(home: Element | null): void;
|
|
75
96
|
}
|
|
97
|
+
export {};
|