@celljs/ta-web 4.9.1 → 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 +8 -7
- package/README.md +8 -7
- package/esm/browser/assistant/assistant-chat-list.d.ts +11 -0
- package/esm/browser/assistant/assistant-chat-list.js +20 -2
- package/esm/browser/assistant/assistant-extension.d.ts +8 -1
- package/esm/browser/assistant/assistant-extension.js +25 -0
- package/esm/browser/assistant/assistant-protocol.d.ts +5 -2
- 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 +14 -2
- package/esm/browser/assistant/assistant-task-util.js +62 -13
- package/esm/browser/assistant/assistant-view.js +117 -71
- package/esm/browser/assistant/assistant.d.ts +28 -5
- package/esm/browser/assistant/assistant.js +96 -22
- package/esm/browser/avatar/dino-face.js +1 -2
- package/esm/browser/chat/chat-packages.d.ts +39 -0
- package/esm/browser/chat/chat-packages.js +70 -0
- package/esm/browser/chat/chat-protocol.d.ts +28 -1
- package/esm/browser/chat/chat-stores.d.ts +62 -0
- package/esm/browser/chat/chat-stores.js +129 -0
- package/esm/browser/chat/chat-util.d.ts +17 -0
- package/esm/browser/chat/chat-util.js +61 -0
- package/esm/browser/chat/chat-view.js +45 -17
- package/esm/browser/chat/chat.d.ts +41 -41
- package/esm/browser/chat/chat.js +276 -190
- 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 +11 -5
- package/esm/browser/components/app-nav.js +39 -17
- package/esm/browser/components/app-shell-hooks.d.ts +2 -2
- package/esm/browser/components/app-shell-hooks.js +12 -6
- package/esm/browser/components/app-view.js +150 -36
- 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 +93 -8
- package/esm/browser/components/chat-list.js +411 -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 +18 -8
- package/esm/browser/components/composer-box.js +199 -52
- package/esm/browser/components/composer.d.ts +13 -6
- package/esm/browser/components/composer.js +8 -5
- package/esm/browser/components/connection-bar.js +50 -17
- package/esm/browser/components/context-menu.d.ts +30 -4
- package/esm/browser/components/context-menu.js +199 -37
- package/esm/browser/components/conversation-scroll.d.ts +136 -6
- package/esm/browser/components/conversation-scroll.js +467 -108
- 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 -2
- package/esm/browser/components/earlier-messages.js +42 -23
- package/esm/browser/components/editor-area.d.ts +6 -20
- package/esm/browser/components/editor-area.js +10 -96
- package/esm/browser/components/empty-pictures.d.ts +0 -2
- package/esm/browser/components/empty-pictures.js +0 -16
- 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 +6 -3
- package/esm/browser/components/folder-picker.js +27 -9
- 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/held-talk.d.ts +28 -0
- package/esm/browser/components/held-talk.js +76 -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 +5 -3
- package/esm/browser/components/icon.js +9 -9
- package/esm/browser/components/image-viewer.d.ts +132 -0
- package/esm/browser/components/image-viewer.js +434 -0
- 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 +14 -0
- package/esm/browser/components/lightbox.js +25 -0
- package/esm/browser/components/list-rows.d.ts +9 -1
- package/esm/browser/components/list-rows.js +17 -3
- package/esm/browser/components/markdown.d.ts +6 -2
- package/esm/browser/components/markdown.js +60 -14
- package/esm/browser/components/media.js +20 -12
- package/esm/browser/components/message-actions.js +2 -0
- package/esm/browser/components/message-footer.d.ts +22 -2
- package/esm/browser/components/message-footer.js +47 -13
- package/esm/browser/components/message-list.d.ts +78 -6
- package/esm/browser/components/message-list.js +281 -36
- package/esm/browser/components/message-menu.d.ts +3 -1
- package/esm/browser/components/message-menu.js +24 -4
- package/esm/browser/components/model-picker.js +1 -0
- package/esm/browser/components/nav-places.d.ts +37 -3
- package/esm/browser/components/nav-places.js +32 -7
- 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 +27 -2
- package/esm/browser/components/phone-shell.js +98 -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 +8 -3
- package/esm/browser/components/session-settings.js +15 -1
- package/esm/browser/components/session-view.js +36 -22
- 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.d.ts +2 -2
- package/esm/browser/components/settings-parts.js +69 -15
- package/esm/browser/components/swipe-row.d.ts +2 -2
- package/esm/browser/components/swipe-row.js +7 -3
- package/esm/browser/components/tool-view.js +21 -14
- 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 +51 -0
- package/esm/browser/components/voice-talk.js +242 -0
- 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/device.d.ts +3 -0
- package/esm/browser/device/device.js +11 -1
- package/esm/browser/device/hold.d.ts +42 -0
- package/esm/browser/device/hold.js +134 -0
- package/esm/browser/device/launch-screen.d.ts +1 -1
- package/esm/browser/device/launch-screen.js +1 -1
- package/esm/browser/device/long-press.d.ts +12 -0
- package/esm/browser/device/long-press.js +44 -13
- 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.d.ts +4 -2
- package/esm/browser/device/pull-down.js +67 -78
- 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.d.ts +35 -10
- package/esm/browser/device/row-swipe.js +154 -71
- package/esm/browser/device/shake-undo.d.ts +16 -0
- package/esm/browser/device/shake-undo.js +59 -0
- package/esm/browser/device/sheet-swipe.d.ts +118 -18
- package/esm/browser/device/sheet-swipe.js +414 -108
- 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 +218 -521
- package/esm/browser/extension/web-extension-code.d.ts +6 -0
- package/esm/browser/extension/web-extension-code.js +24 -0
- 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 +66 -6
- package/esm/browser/extension/web-extension-protocol.js +41 -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 +41 -68
- package/esm/browser/extension/web-extensions.js +188 -487
- 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/files/files-protocol.d.ts +25 -0
- package/esm/browser/files/files-protocol.js +2 -0
- package/esm/browser/files/files.d.ts +35 -0
- package/esm/browser/files/files.js +119 -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 +105 -3
- package/esm/browser/i18n/messages.d.ts +104 -2
- package/esm/browser/i18n/messages.js +215 -11
- package/esm/browser/index.d.ts +15 -0
- package/esm/browser/index.js +15 -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 +26 -1
- package/esm/browser/notices/notices.d.ts +3 -1
- package/esm/browser/notices/notices.js +26 -12
- 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.d.ts +55 -0
- package/esm/browser/offline/device-values.js +151 -0
- package/esm/browser/offline/kept-chats-protocol.d.ts +17 -0
- package/esm/browser/offline/kept-chats-protocol.js +2 -0
- package/esm/browser/offline/kept-chats.d.ts +47 -0
- package/esm/browser/offline/kept-chats.js +146 -0
- package/esm/browser/offline/offline-reads.d.ts +44 -0
- package/esm/browser/offline/offline-reads.js +109 -0
- 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 +17 -0
- package/esm/browser/settings/settings-protocol.js +20 -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 +95 -17
- package/esm/browser/style/device.js +42 -5
- package/esm/browser/style/layout.d.ts +1 -1
- package/esm/browser/style/layout.js +252 -67
- package/esm/browser/style/pages.d.ts +1 -1
- package/esm/browser/style/pages.js +38 -2
- 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 +76 -9
- 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/frame.d.ts +5 -4
- package/esm/browser/util/frame.js +5 -4
- package/esm/browser/util/link.d.ts +18 -0
- package/esm/browser/util/link.js +66 -1
- package/esm/browser/util/markdown.d.ts +22 -2
- package/esm/browser/util/markdown.js +120 -6
- package/esm/browser/util/message.d.ts +5 -0
- package/esm/browser/util/message.js +30 -0
- package/esm/browser/util/process.d.ts +35 -2
- package/esm/browser/util/process.js +79 -4
- 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 +49 -6
- package/esm/browser/util/voice.js +271 -26
- package/esm/browser/util/zoom.d.ts +46 -0
- package/esm/browser/util/zoom.js +96 -0
- package/esm/browser/workbench-calls.d.ts +61 -0
- package/esm/browser/workbench-calls.js +146 -0
- package/esm/browser/workbench-protocol.d.ts +36 -3
- package/esm/browser/workbench-util.d.ts +22 -4
- package/esm/browser/workbench-util.js +37 -7
- package/esm/browser/workbench.d.ts +47 -6
- package/esm/browser/workbench.js +191 -43
- package/lib/browser/assistant/assistant-chat-list.d.ts +11 -0
- package/lib/browser/assistant/assistant-chat-list.js +21 -2
- package/lib/browser/assistant/assistant-extension.d.ts +8 -1
- package/lib/browser/assistant/assistant-extension.js +25 -0
- package/lib/browser/assistant/assistant-protocol.d.ts +5 -2
- 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 +14 -2
- package/lib/browser/assistant/assistant-task-util.js +62 -13
- package/lib/browser/assistant/assistant-view.js +113 -67
- package/lib/browser/assistant/assistant.d.ts +28 -5
- package/lib/browser/assistant/assistant.js +96 -22
- package/lib/browser/avatar/dino-face.js +1 -2
- package/lib/browser/chat/chat-packages.d.ts +40 -0
- package/lib/browser/chat/chat-packages.js +74 -0
- package/lib/browser/chat/chat-protocol.d.ts +28 -1
- package/lib/browser/chat/chat-stores.d.ts +63 -0
- package/lib/browser/chat/chat-stores.js +133 -0
- package/lib/browser/chat/chat-util.d.ts +18 -0
- package/lib/browser/chat/chat-util.js +64 -0
- package/lib/browser/chat/chat-view.js +44 -16
- package/lib/browser/chat/chat.d.ts +41 -41
- package/lib/browser/chat/chat.js +277 -191
- 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 +11 -5
- package/lib/browser/components/app-nav.js +35 -13
- package/lib/browser/components/app-shell-hooks.d.ts +2 -2
- package/lib/browser/components/app-shell-hooks.js +12 -6
- package/lib/browser/components/app-view.js +145 -31
- 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 +93 -8
- package/lib/browser/components/chat-list.js +412 -60
- 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 +18 -8
- package/lib/browser/components/composer-box.js +198 -51
- package/lib/browser/components/composer.d.ts +13 -6
- package/lib/browser/components/composer.js +7 -4
- package/lib/browser/components/connection-bar.js +48 -15
- package/lib/browser/components/context-menu.d.ts +30 -4
- package/lib/browser/components/context-menu.js +198 -36
- package/lib/browser/components/conversation-scroll.d.ts +136 -6
- package/lib/browser/components/conversation-scroll.js +469 -109
- 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 -2
- package/lib/browser/components/earlier-messages.js +44 -24
- package/lib/browser/components/editor-area.d.ts +6 -20
- package/lib/browser/components/editor-area.js +11 -97
- package/lib/browser/components/empty-pictures.d.ts +0 -2
- package/lib/browser/components/empty-pictures.js +0 -17
- 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 +6 -3
- package/lib/browser/components/folder-picker.js +27 -9
- 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/held-talk.d.ts +29 -0
- package/lib/browser/components/held-talk.js +79 -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 +5 -3
- package/lib/browser/components/icon.js +11 -9
- package/lib/browser/components/image-viewer.d.ts +133 -0
- package/lib/browser/components/image-viewer.js +472 -0
- 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 +15 -0
- package/lib/browser/components/lightbox.js +61 -0
- package/lib/browser/components/list-rows.d.ts +9 -1
- package/lib/browser/components/list-rows.js +18 -3
- package/lib/browser/components/markdown.d.ts +6 -2
- package/lib/browser/components/markdown.js +60 -14
- package/lib/browser/components/media.js +21 -13
- package/lib/browser/components/message-actions.js +2 -0
- package/lib/browser/components/message-footer.d.ts +22 -2
- package/lib/browser/components/message-footer.js +49 -12
- package/lib/browser/components/message-list.d.ts +78 -6
- package/lib/browser/components/message-list.js +281 -32
- package/lib/browser/components/message-menu.d.ts +3 -1
- package/lib/browser/components/message-menu.js +23 -3
- package/lib/browser/components/model-picker.js +1 -0
- package/lib/browser/components/nav-places.d.ts +37 -3
- package/lib/browser/components/nav-places.js +35 -7
- 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 +27 -2
- package/lib/browser/components/phone-shell.js +99 -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 +8 -3
- package/lib/browser/components/session-settings.js +15 -1
- package/lib/browser/components/session-view.js +32 -18
- 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.d.ts +2 -2
- package/lib/browser/components/settings-parts.js +67 -13
- package/lib/browser/components/swipe-row.d.ts +2 -2
- package/lib/browser/components/swipe-row.js +7 -3
- package/lib/browser/components/tool-view.js +21 -14
- 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 +52 -0
- package/lib/browser/components/voice-talk.js +281 -0
- 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/device.d.ts +3 -0
- package/lib/browser/device/device.js +11 -1
- package/lib/browser/device/hold.d.ts +43 -0
- package/lib/browser/device/hold.js +171 -0
- package/lib/browser/device/launch-screen.d.ts +1 -1
- package/lib/browser/device/launch-screen.js +1 -1
- package/lib/browser/device/long-press.d.ts +12 -0
- package/lib/browser/device/long-press.js +44 -13
- 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.d.ts +4 -2
- package/lib/browser/device/pull-down.js +66 -77
- 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.d.ts +35 -10
- package/lib/browser/device/row-swipe.js +153 -70
- package/lib/browser/device/shake-undo.d.ts +17 -0
- package/lib/browser/device/shake-undo.js +63 -0
- package/lib/browser/device/sheet-swipe.d.ts +118 -18
- package/lib/browser/device/sheet-swipe.js +418 -109
- 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 +218 -521
- package/lib/browser/extension/web-extension-code.d.ts +6 -0
- package/lib/browser/extension/web-extension-code.js +24 -0
- 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 +66 -6
- package/lib/browser/extension/web-extension-protocol.js +42 -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 +41 -68
- package/lib/browser/extension/web-extensions.js +184 -516
- 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/files/files-protocol.d.ts +26 -0
- package/lib/browser/files/files-protocol.js +5 -0
- package/lib/browser/files/files.d.ts +36 -0
- package/lib/browser/files/files.js +122 -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 +105 -3
- package/lib/browser/i18n/messages.d.ts +104 -2
- package/lib/browser/i18n/messages.js +215 -11
- package/lib/browser/index.d.ts +15 -0
- package/lib/browser/index.js +15 -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 +26 -1
- package/lib/browser/notices/notices.d.ts +3 -1
- package/lib/browser/notices/notices.js +26 -12
- 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.d.ts +56 -0
- package/lib/browser/offline/device-values.js +157 -0
- package/lib/browser/offline/kept-chats-protocol.d.ts +18 -0
- package/lib/browser/offline/kept-chats-protocol.js +5 -0
- package/lib/browser/offline/kept-chats.d.ts +48 -0
- package/lib/browser/offline/kept-chats.js +149 -0
- package/lib/browser/offline/offline-reads.d.ts +45 -0
- package/lib/browser/offline/offline-reads.js +113 -0
- 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 +17 -0
- package/lib/browser/settings/settings-protocol.js +21 -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 +95 -17
- package/lib/browser/style/device.js +42 -5
- package/lib/browser/style/layout.d.ts +1 -1
- package/lib/browser/style/layout.js +252 -67
- package/lib/browser/style/pages.d.ts +1 -1
- package/lib/browser/style/pages.js +38 -2
- 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 +76 -9
- 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/frame.d.ts +5 -4
- package/lib/browser/util/frame.js +5 -4
- package/lib/browser/util/link.d.ts +18 -0
- package/lib/browser/util/link.js +66 -1
- package/lib/browser/util/markdown.d.ts +22 -2
- package/lib/browser/util/markdown.js +120 -6
- package/lib/browser/util/message.d.ts +5 -0
- package/lib/browser/util/message.js +30 -0
- package/lib/browser/util/process.d.ts +35 -2
- package/lib/browser/util/process.js +80 -5
- 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 +49 -6
- package/lib/browser/util/voice.js +271 -26
- package/lib/browser/util/zoom.d.ts +47 -0
- package/lib/browser/util/zoom.js +99 -0
- package/lib/browser/workbench-calls.d.ts +62 -0
- package/lib/browser/workbench-calls.js +150 -0
- package/lib/browser/workbench-protocol.d.ts +36 -3
- package/lib/browser/workbench-util.d.ts +22 -4
- package/lib/browser/workbench-util.js +38 -8
- package/lib/browser/workbench.d.ts +47 -6
- package/lib/browser/workbench.js +189 -41
- package/package.json +14 -11
- package/public/launch.svg +46 -42
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
import type { TaWebExtensions } from '../extension/web-extension-protocol.js';
|
|
2
|
+
import { type MessageId } from '../i18n/messages.js';
|
|
3
|
+
import type { TaLinks } from '../links/links-protocol.js';
|
|
4
|
+
import type { TaNotices } from '../notices/notices-protocol.js';
|
|
5
|
+
import type { TaSettings } from '../settings/settings-protocol.js';
|
|
6
|
+
import type { TaWorkbench } from '../workbench-protocol.js';
|
|
7
|
+
/** Whether the scan screen of the page is open: ScanHost (components/scan-screen.tsx) draws it, CodeScan opens it. */
|
|
8
|
+
export declare namespace ScanScreen {
|
|
9
|
+
const isOpen: () => boolean;
|
|
10
|
+
const show: () => void;
|
|
11
|
+
const hide: () => void;
|
|
12
|
+
function subscribe(listener: () => void): () => void;
|
|
13
|
+
}
|
|
14
|
+
/** What a scanned code carries, as WeChat's Scan reads it: a computer to pair with, a link of an extension, a page of the web, or text. */
|
|
15
|
+
export type ScannedCode = {
|
|
16
|
+
kind: 'pairing';
|
|
17
|
+
} | {
|
|
18
|
+
kind: 'extension';
|
|
19
|
+
} | {
|
|
20
|
+
kind: 'web';
|
|
21
|
+
url: string;
|
|
22
|
+
} | {
|
|
23
|
+
kind: 'text';
|
|
24
|
+
text: string;
|
|
25
|
+
};
|
|
26
|
+
export declare namespace CodeScanUtil {
|
|
27
|
+
/** Pure, for the tests. A plain URL of a page is a page, not an extension of Git: only a link of Ta names one. */
|
|
28
|
+
function read(text: string): ScannedCode;
|
|
29
|
+
}
|
|
30
|
+
/** What the scan of the page uses (the services of the page; a web extension's context has them). */
|
|
31
|
+
export interface CodeScanHost {
|
|
32
|
+
readonly workbench: TaWorkbench;
|
|
33
|
+
readonly notices: TaNotices;
|
|
34
|
+
readonly links: TaLinks;
|
|
35
|
+
readonly extensions: Pick<TaWebExtensions, 'openShared'>;
|
|
36
|
+
readonly settings: TaSettings;
|
|
37
|
+
}
|
|
38
|
+
/**
|
|
39
|
+
* Scan, as WeChat's: the scan screen of the page where the app reads codes (CodeVision), else the scanner of the
|
|
40
|
+
* app's plugin (an app built before); then what the code carries opens. A computer is connected to and
|
|
41
|
+
* switched to once the user said so, an extension opens as its link does (asking first), a page of the web
|
|
42
|
+
* after the question of every link going out of Ta, other text shows to copy.
|
|
43
|
+
*/
|
|
44
|
+
export declare class CodeScan {
|
|
45
|
+
protected readonly host: CodeScanHost;
|
|
46
|
+
constructor(host: CodeScanHost);
|
|
47
|
+
/** Only the Ta app has a camera to scan with. */
|
|
48
|
+
static available(): boolean;
|
|
49
|
+
scan(): Promise<void>;
|
|
50
|
+
/** What a code scanned carries. */
|
|
51
|
+
open(text: string): Promise<void>;
|
|
52
|
+
protected pair(link: string): Promise<void>;
|
|
53
|
+
protected show(text: string): Promise<void>;
|
|
54
|
+
protected say(id: MessageId): string;
|
|
55
|
+
}
|
|
@@ -0,0 +1,137 @@
|
|
|
1
|
+
import { message } from '../i18n/messages.js';
|
|
2
|
+
import { ShareLinkUtil } from '../util/share-link.js';
|
|
3
|
+
import { pageHost, WorkbenchError, WorkbenchUtil } from '../workbench-util.js';
|
|
4
|
+
import { CodeVision } from './code-vision.js';
|
|
5
|
+
import { ScanError, Scanner } from './scanner.js';
|
|
6
|
+
/** Whether the scan screen of the page is open: ScanHost (components/scan-screen.tsx) draws it, CodeScan opens it. */
|
|
7
|
+
export var ScanScreen;
|
|
8
|
+
(function (ScanScreen) {
|
|
9
|
+
let open = false;
|
|
10
|
+
const listeners = new Set();
|
|
11
|
+
const set = (value) => {
|
|
12
|
+
open = value;
|
|
13
|
+
for (const listener of listeners) {
|
|
14
|
+
listener();
|
|
15
|
+
}
|
|
16
|
+
};
|
|
17
|
+
ScanScreen.isOpen = () => open;
|
|
18
|
+
ScanScreen.show = () => set(true);
|
|
19
|
+
ScanScreen.hide = () => set(false);
|
|
20
|
+
function subscribe(listener) {
|
|
21
|
+
listeners.add(listener);
|
|
22
|
+
return () => listeners.delete(listener);
|
|
23
|
+
}
|
|
24
|
+
ScanScreen.subscribe = subscribe;
|
|
25
|
+
})(ScanScreen || (ScanScreen = {}));
|
|
26
|
+
const WEB = /^https?:\/\/\S+$/i;
|
|
27
|
+
export var CodeScanUtil;
|
|
28
|
+
(function (CodeScanUtil) {
|
|
29
|
+
/** Pure, for the tests. A plain URL of a page is a page, not an extension of Git: only a link of Ta names one. */
|
|
30
|
+
function read(text) {
|
|
31
|
+
const trimmed = text.trim();
|
|
32
|
+
if ('pairing' in WorkbenchUtil.credential(trimmed)) {
|
|
33
|
+
return { kind: 'pairing' };
|
|
34
|
+
}
|
|
35
|
+
const source = ShareLinkUtil.sourceOf(trimmed);
|
|
36
|
+
if (source && (source !== trimmed || !WEB.test(trimmed) || ShareLinkUtil.relayed(trimmed))) {
|
|
37
|
+
return { kind: 'extension' };
|
|
38
|
+
}
|
|
39
|
+
if (WEB.test(trimmed)) {
|
|
40
|
+
try {
|
|
41
|
+
return { kind: 'web', url: new URL(trimmed).href };
|
|
42
|
+
}
|
|
43
|
+
catch (_a) {
|
|
44
|
+
// Not a URL after all: text.
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
return { kind: 'text', text: trimmed };
|
|
48
|
+
}
|
|
49
|
+
CodeScanUtil.read = read;
|
|
50
|
+
})(CodeScanUtil || (CodeScanUtil = {}));
|
|
51
|
+
/**
|
|
52
|
+
* Scan, as WeChat's: the scan screen of the page where the app reads codes (CodeVision), else the scanner of the
|
|
53
|
+
* app's plugin (an app built before); then what the code carries opens. A computer is connected to and
|
|
54
|
+
* switched to once the user said so, an extension opens as its link does (asking first), a page of the web
|
|
55
|
+
* after the question of every link going out of Ta, other text shows to copy.
|
|
56
|
+
*/
|
|
57
|
+
export class CodeScan {
|
|
58
|
+
constructor(host) {
|
|
59
|
+
this.host = host;
|
|
60
|
+
}
|
|
61
|
+
/** Only the Ta app has a camera to scan with. */
|
|
62
|
+
static available() {
|
|
63
|
+
return CodeVision.available() || Scanner.available();
|
|
64
|
+
}
|
|
65
|
+
async scan() {
|
|
66
|
+
if (CodeVision.available()) {
|
|
67
|
+
ScanScreen.show();
|
|
68
|
+
return;
|
|
69
|
+
}
|
|
70
|
+
let text;
|
|
71
|
+
try {
|
|
72
|
+
text = await Scanner.scan(this.say('ta.scan.instructions'), this.say('ta.cancel'));
|
|
73
|
+
}
|
|
74
|
+
catch (failure) {
|
|
75
|
+
const denied = failure instanceof ScanError && failure.reason === 'denied';
|
|
76
|
+
this.host.notices.notify(this.say(denied ? 'ta.hosts.cameraDenied' : 'ta.scan.failed'), { level: 'error' });
|
|
77
|
+
return;
|
|
78
|
+
}
|
|
79
|
+
if (text) {
|
|
80
|
+
await this.open(text);
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
/** What a code scanned carries. */
|
|
84
|
+
async open(text) {
|
|
85
|
+
const code = CodeScanUtil.read(text);
|
|
86
|
+
switch (code.kind) {
|
|
87
|
+
case 'pairing':
|
|
88
|
+
return this.pair(text.trim());
|
|
89
|
+
case 'extension':
|
|
90
|
+
await this.host.extensions.openShared(text);
|
|
91
|
+
return;
|
|
92
|
+
case 'web':
|
|
93
|
+
return this.host.links.open({ type: 'url', url: code.url }, { external: true });
|
|
94
|
+
case 'text':
|
|
95
|
+
return this.show(code.text);
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
async pair(link) {
|
|
99
|
+
const { workbench, notices } = this.host;
|
|
100
|
+
const id = WorkbenchUtil.serverOf(WorkbenchUtil.credential(link), pageHost());
|
|
101
|
+
if (id === workbench.state.host && workbench.state.status !== 'signed-out') {
|
|
102
|
+
notices.notify(this.say('ta.scan.sameHost'));
|
|
103
|
+
return;
|
|
104
|
+
}
|
|
105
|
+
const yes = await notices.confirm({
|
|
106
|
+
title: this.say('ta.scan.pairTitle'),
|
|
107
|
+
message: this.say('ta.scan.pairMessage'),
|
|
108
|
+
confirmLabel: this.say('ta.signin.connect'),
|
|
109
|
+
});
|
|
110
|
+
if (!yes) {
|
|
111
|
+
return;
|
|
112
|
+
}
|
|
113
|
+
try {
|
|
114
|
+
await workbench.signIn(link);
|
|
115
|
+
}
|
|
116
|
+
catch (failure) {
|
|
117
|
+
const refused = failure instanceof WorkbenchError && failure.reason === 'refused';
|
|
118
|
+
notices.notify(this.say(refused ? 'ta.hosts.refused' : 'ta.hosts.unreachable'), { level: 'error' });
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
async show(text) {
|
|
122
|
+
const { notices } = this.host;
|
|
123
|
+
if (await notices.confirm({ title: this.say('ta.scan.result'), message: text, confirmLabel: this.say('ta.copy') })) {
|
|
124
|
+
try {
|
|
125
|
+
await navigator.clipboard.writeText(text);
|
|
126
|
+
notices.notify(this.say('ta.copied'), { level: 'success' });
|
|
127
|
+
}
|
|
128
|
+
catch (_a) {
|
|
129
|
+
notices.notify(this.say('ta.scan.copyFailed'), { level: 'error' });
|
|
130
|
+
}
|
|
131
|
+
}
|
|
132
|
+
}
|
|
133
|
+
say(id) {
|
|
134
|
+
return message(this.host.settings.state.language, id);
|
|
135
|
+
}
|
|
136
|
+
}
|
|
137
|
+
//# sourceMappingURL=code-scan.js.map
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
/** A code found in a picture: its text, and where it is, as fractions of the picture (0 to 1 from its top left). */
|
|
2
|
+
export interface FoundCode {
|
|
3
|
+
text: string;
|
|
4
|
+
x: number;
|
|
5
|
+
y: number;
|
|
6
|
+
width: number;
|
|
7
|
+
height: number;
|
|
8
|
+
}
|
|
9
|
+
/** Where a picture of `width` by `height` is drawn to cover a box of `boxWidth` by `boxHeight` (`object-fit: cover`). */
|
|
10
|
+
export interface CoverPlace {
|
|
11
|
+
scale: number;
|
|
12
|
+
left: number;
|
|
13
|
+
top: number;
|
|
14
|
+
}
|
|
15
|
+
/**
|
|
16
|
+
* Codes read from pictures by the Ta app (Apple's Vision, which reads a QR code from any angle and in poor light),
|
|
17
|
+
* for the camera of the scan screen and the pictures of the album: no decoder bundled in the page. Pure helpers
|
|
18
|
+
* besides, for the tests.
|
|
19
|
+
*/
|
|
20
|
+
export declare namespace CodeVision {
|
|
21
|
+
/** The window event the Ta app answers with. */
|
|
22
|
+
const EVENT = "ta-vision";
|
|
23
|
+
/** The app reads codes and the page has a camera: the scan screen of the page. */
|
|
24
|
+
function available(): boolean;
|
|
25
|
+
/** The codes of a picture (a data URL of a JPEG); none where the app cannot read them. */
|
|
26
|
+
function detect(image: string): Promise<FoundCode[]>;
|
|
27
|
+
/** What the app answered, only codes with text and a place inside the picture. */
|
|
28
|
+
function codesOf(codes: unknown): FoundCode[];
|
|
29
|
+
function cover(width: number, height: number, boxWidth: number, boxHeight: number): CoverPlace;
|
|
30
|
+
/**
|
|
31
|
+
* The middle of a code on the screen, the picture (`width` by `height`) covering a box of `boxWidth` by
|
|
32
|
+
* `boxHeight`, `mirrored` as the front camera shows; where the green dot goes, as in WeChat.
|
|
33
|
+
*/
|
|
34
|
+
function centre(code: FoundCode, width: number, height: number, boxWidth: number, boxHeight: number, mirrored?: boolean): {
|
|
35
|
+
x: number;
|
|
36
|
+
y: number;
|
|
37
|
+
};
|
|
38
|
+
/** The size of a picture whose longer side is at most `longest`, its shape kept. */
|
|
39
|
+
function fit(width: number, height: number, longest: number): {
|
|
40
|
+
width: number;
|
|
41
|
+
height: number;
|
|
42
|
+
};
|
|
43
|
+
/** A JPEG of what `source` shows (a frame of the camera, a picture), its longer side at most `longest`. */
|
|
44
|
+
function jpeg(source: CanvasImageSource, width: number, height: number, longest: number, quality: number): string;
|
|
45
|
+
/** A data URL as an image of a message: its base64 and its type. */
|
|
46
|
+
function image(dataUrl: string): {
|
|
47
|
+
type: 'image';
|
|
48
|
+
data: string;
|
|
49
|
+
mimeType: string;
|
|
50
|
+
};
|
|
51
|
+
}
|
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Codes read from pictures by the Ta app (Apple's Vision, which reads a QR code from any angle and in poor light),
|
|
3
|
+
* for the camera of the scan screen and the pictures of the album: no decoder bundled in the page. Pure helpers
|
|
4
|
+
* besides, for the tests.
|
|
5
|
+
*/
|
|
6
|
+
export var CodeVision;
|
|
7
|
+
(function (CodeVision) {
|
|
8
|
+
/** The window event the Ta app answers with. */
|
|
9
|
+
CodeVision.EVENT = 'ta-vision';
|
|
10
|
+
/** A picture the app has not answered in this long has no code (an app that went to the background). */
|
|
11
|
+
const WAIT_MS = 5000;
|
|
12
|
+
let next = 0;
|
|
13
|
+
function native() {
|
|
14
|
+
var _a, _b;
|
|
15
|
+
return (_b = (_a = globalThis.webkit) === null || _a === void 0 ? void 0 : _a.messageHandlers) === null || _b === void 0 ? void 0 : _b.taVision;
|
|
16
|
+
}
|
|
17
|
+
/** The app reads codes and the page has a camera: the scan screen of the page. */
|
|
18
|
+
function available() {
|
|
19
|
+
var _a;
|
|
20
|
+
return native() !== undefined && typeof navigator !== 'undefined' && !!((_a = navigator.mediaDevices) === null || _a === void 0 ? void 0 : _a.getUserMedia);
|
|
21
|
+
}
|
|
22
|
+
CodeVision.available = available;
|
|
23
|
+
/** The codes of a picture (a data URL of a JPEG); none where the app cannot read them. */
|
|
24
|
+
function detect(image) {
|
|
25
|
+
const vision = native();
|
|
26
|
+
if (!vision) {
|
|
27
|
+
return Promise.resolve([]);
|
|
28
|
+
}
|
|
29
|
+
const id = `v${++next}`;
|
|
30
|
+
return new Promise(resolve => {
|
|
31
|
+
const done = (codes) => {
|
|
32
|
+
clearTimeout(timer);
|
|
33
|
+
globalThis.removeEventListener(CodeVision.EVENT, onEvent);
|
|
34
|
+
resolve(codes);
|
|
35
|
+
};
|
|
36
|
+
const onEvent = (event) => {
|
|
37
|
+
const detail = event.detail;
|
|
38
|
+
if ((detail === null || detail === void 0 ? void 0 : detail.id) === id) {
|
|
39
|
+
done(codesOf(detail.codes));
|
|
40
|
+
}
|
|
41
|
+
};
|
|
42
|
+
const timer = setTimeout(() => done([]), WAIT_MS);
|
|
43
|
+
globalThis.addEventListener(CodeVision.EVENT, onEvent);
|
|
44
|
+
vision.postMessage({ id, image });
|
|
45
|
+
});
|
|
46
|
+
}
|
|
47
|
+
CodeVision.detect = detect;
|
|
48
|
+
/** What the app answered, only codes with text and a place inside the picture. */
|
|
49
|
+
function codesOf(codes) {
|
|
50
|
+
if (!Array.isArray(codes)) {
|
|
51
|
+
return [];
|
|
52
|
+
}
|
|
53
|
+
return codes.filter((code) => typeof (code === null || code === void 0 ? void 0 : code.text) === 'string' &&
|
|
54
|
+
code.text.length > 0 &&
|
|
55
|
+
[code.x, code.y, code.width, code.height].every(value => typeof value === 'number' && Number.isFinite(value)));
|
|
56
|
+
}
|
|
57
|
+
CodeVision.codesOf = codesOf;
|
|
58
|
+
function cover(width, height, boxWidth, boxHeight) {
|
|
59
|
+
const scale = Math.max(boxWidth / width, boxHeight / height);
|
|
60
|
+
return { scale, left: (boxWidth - width * scale) / 2, top: (boxHeight - height * scale) / 2 };
|
|
61
|
+
}
|
|
62
|
+
CodeVision.cover = cover;
|
|
63
|
+
/**
|
|
64
|
+
* The middle of a code on the screen, the picture (`width` by `height`) covering a box of `boxWidth` by
|
|
65
|
+
* `boxHeight`, `mirrored` as the front camera shows; where the green dot goes, as in WeChat.
|
|
66
|
+
*/
|
|
67
|
+
function centre(code, width, height, boxWidth, boxHeight, mirrored = false) {
|
|
68
|
+
const place = cover(width, height, boxWidth, boxHeight);
|
|
69
|
+
const x = code.x + code.width / 2;
|
|
70
|
+
return { x: place.left + (mirrored ? 1 - x : x) * width * place.scale, y: place.top + (code.y + code.height / 2) * height * place.scale };
|
|
71
|
+
}
|
|
72
|
+
CodeVision.centre = centre;
|
|
73
|
+
/** The size of a picture whose longer side is at most `longest`, its shape kept. */
|
|
74
|
+
function fit(width, height, longest) {
|
|
75
|
+
const scale = Math.min(1, longest / Math.max(width, height, 1));
|
|
76
|
+
return { width: Math.max(1, Math.round(width * scale)), height: Math.max(1, Math.round(height * scale)) };
|
|
77
|
+
}
|
|
78
|
+
CodeVision.fit = fit;
|
|
79
|
+
/** A JPEG of what `source` shows (a frame of the camera, a picture), its longer side at most `longest`. */
|
|
80
|
+
function jpeg(source, width, height, longest, quality) {
|
|
81
|
+
var _a;
|
|
82
|
+
const size = fit(width, height, longest);
|
|
83
|
+
const canvas = document.createElement('canvas');
|
|
84
|
+
canvas.width = size.width;
|
|
85
|
+
canvas.height = size.height;
|
|
86
|
+
(_a = canvas.getContext('2d')) === null || _a === void 0 ? void 0 : _a.drawImage(source, 0, 0, size.width, size.height);
|
|
87
|
+
return canvas.toDataURL('image/jpeg', quality);
|
|
88
|
+
}
|
|
89
|
+
CodeVision.jpeg = jpeg;
|
|
90
|
+
/** A data URL as an image of a message: its base64 and its type. */
|
|
91
|
+
function image(dataUrl) {
|
|
92
|
+
var _a;
|
|
93
|
+
var _b;
|
|
94
|
+
const comma = dataUrl.indexOf(',');
|
|
95
|
+
const mimeType = (_b = (_a = /^data:([^;,]+)/.exec(dataUrl)) === null || _a === void 0 ? void 0 : _a[1]) !== null && _b !== void 0 ? _b : 'image/jpeg';
|
|
96
|
+
return { type: 'image', data: dataUrl.slice(comma + 1), mimeType };
|
|
97
|
+
}
|
|
98
|
+
CodeVision.image = image;
|
|
99
|
+
})(CodeVision || (CodeVision = {}));
|
|
100
|
+
//# sourceMappingURL=code-vision.js.map
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import { type DeviceLayout, type DeviceState } from './device-protocol.js';
|
|
3
3
|
import { type NewLineBridge } from './new-line.js';
|
|
4
|
+
import { type ShakeUndoBridge } from './shake-undo.js';
|
|
4
5
|
/** What the observer reads of the browser; tests give their own. */
|
|
5
6
|
export interface DeviceEnvironment {
|
|
6
7
|
matchMedia(query: string): {
|
|
@@ -33,6 +34,8 @@ export interface DeviceEnvironment {
|
|
|
33
34
|
readonly keyboard?: (listener: (height: number) => void) => void;
|
|
34
35
|
/** The edit menu of the app on iOS, which offers New Line in the message box (new-line.ts); none elsewhere. */
|
|
35
36
|
readonly newLine?: NewLineBridge;
|
|
37
|
+
/** Shake to Undo of the app on iOS, offered only while a field has text (shake-undo.ts); none elsewhere. */
|
|
38
|
+
readonly shakeUndo?: ShakeUndoBridge;
|
|
36
39
|
}
|
|
37
40
|
export declare namespace DeviceUtil {
|
|
38
41
|
/** Where the page is not in a browser (tests, the server). */
|
|
@@ -3,6 +3,7 @@ import { DeviceMedia, DeviceMotion } from './device-protocol.js';
|
|
|
3
3
|
import { startFieldDismiss } from './field-dismiss.js';
|
|
4
4
|
import { startLongPress } from './long-press.js';
|
|
5
5
|
import { startNewLine } from './new-line.js';
|
|
6
|
+
import { startShakeUndo } from './shake-undo.js';
|
|
6
7
|
/** How much of the height the keyboard has to take before it counts as open: more than the bars of a browser. */
|
|
7
8
|
const KEYBOARD_PX = 80;
|
|
8
9
|
export var DeviceUtil;
|
|
@@ -95,6 +96,9 @@ export class DeviceObserver {
|
|
|
95
96
|
if (env.newLine) {
|
|
96
97
|
startNewLine(env.document, env.newLine);
|
|
97
98
|
}
|
|
99
|
+
if (env.shakeUndo) {
|
|
100
|
+
startShakeUndo(env.document, env.shakeUndo);
|
|
101
|
+
}
|
|
98
102
|
}
|
|
99
103
|
if (env.keyboard) {
|
|
100
104
|
env.keyboard(height => this.moveKeyboard(height));
|
|
@@ -194,9 +198,15 @@ function browser() {
|
|
|
194
198
|
root: document.documentElement,
|
|
195
199
|
native: nativeBridge(),
|
|
196
200
|
keyboard: nativeKeyboard(),
|
|
197
|
-
newLine: (
|
|
201
|
+
newLine: (_a = messageHandlers()) === null || _a === void 0 ? void 0 : _a.taEditing,
|
|
202
|
+
shakeUndo: (_b = messageHandlers()) === null || _b === void 0 ? void 0 : _b.taUndo,
|
|
198
203
|
};
|
|
199
204
|
}
|
|
205
|
+
/** What the Ta app on iOS listens to from the page (TaBridgeViewController of apps/ta-mobile); none elsewhere. */
|
|
206
|
+
function messageHandlers() {
|
|
207
|
+
var _a;
|
|
208
|
+
return (_a = window.webkit) === null || _a === void 0 ? void 0 : _a.messageHandlers;
|
|
209
|
+
}
|
|
200
210
|
/** One plugin of the Ta app (Capacitor), when the app has it; none in a browser, or in an app built before it. */
|
|
201
211
|
export function nativePlugin(name) {
|
|
202
212
|
var _a;
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
/**
|
|
3
|
+
* What a held finger does, as the talk button of a phone's chat: it starts once the finger has been kept still
|
|
4
|
+
* for PRESS_MS, follows the finger while it stays, and ends when it lets go.
|
|
5
|
+
*/
|
|
6
|
+
export interface Hold {
|
|
7
|
+
/** Whether a press is the hold's (a field, a button of its own are not); every press is, without it. */
|
|
8
|
+
accepts?(event: React.PointerEvent): boolean;
|
|
9
|
+
start(): void;
|
|
10
|
+
/** Where the finger is while it is held, in the coordinates of the page. */
|
|
11
|
+
move?(x: number, y: number): void;
|
|
12
|
+
/** The finger let go. */
|
|
13
|
+
end(): void;
|
|
14
|
+
/** The system took the finger (a gesture of its own, a call): nothing is given. */
|
|
15
|
+
cancel(): void;
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* What an element takes of the pointer, for the hold it has. `data-held` takes the panning of a finger from the
|
|
19
|
+
* browser (style/device.ts): it decides that as the finger lands, too early for a hold, and a pan it began takes
|
|
20
|
+
* the finger from the page (pointercancel) as soon as it slides toward 取消.
|
|
21
|
+
*/
|
|
22
|
+
export interface HeldProps {
|
|
23
|
+
onPointerDown?(event: React.PointerEvent): void;
|
|
24
|
+
onContextMenu?(event: React.MouseEvent): void;
|
|
25
|
+
'data-held'?: '';
|
|
26
|
+
}
|
|
27
|
+
/**
|
|
28
|
+
* Something done while an element is held. A press that moves first scrolls, and one let go before PRESS_MS
|
|
29
|
+
* starts nothing, so that a tap stays a tap. Once held, the finger is the hold's until it lets go: the page does
|
|
30
|
+
* not scroll under it, the system's menu and selection do not come, the click of the finger let go is not a tap
|
|
31
|
+
* of what was under it, and the hold outlives the element (a tab bar that a page slides over).
|
|
32
|
+
*/
|
|
33
|
+
export declare function useHeld(): (hold: Hold | undefined) => HeldProps;
|
|
34
|
+
export declare namespace HeldUtil {
|
|
35
|
+
/** A light tap of the haptic engine as a held finger comes onto something (取消, 编辑): the app's, or a phone's. */
|
|
36
|
+
function tick(): void;
|
|
37
|
+
/**
|
|
38
|
+
* The click that follows a finger let go after a hold: not a tap of what was under it. A browser that sends
|
|
39
|
+
* none (a long press is no tap to it) leaves the next press its own.
|
|
40
|
+
*/
|
|
41
|
+
function swallowClick(): void;
|
|
42
|
+
}
|
|
@@ -0,0 +1,134 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import { nativePlugin } from './device.js';
|
|
3
|
+
import { LongPressUtil } from './long-press.js';
|
|
4
|
+
/**
|
|
5
|
+
* Something done while an element is held. A press that moves first scrolls, and one let go before PRESS_MS
|
|
6
|
+
* starts nothing, so that a tap stays a tap. Once held, the finger is the hold's until it lets go: the page does
|
|
7
|
+
* not scroll under it, the system's menu and selection do not come, the click of the finger let go is not a tap
|
|
8
|
+
* of what was under it, and the hold outlives the element (a tab bar that a page slides over).
|
|
9
|
+
*/
|
|
10
|
+
export function useHeld() {
|
|
11
|
+
const current = React.useRef(undefined);
|
|
12
|
+
// Gone before it held, the press is nothing; once held, it ends when the finger lets go.
|
|
13
|
+
React.useEffect(() => () => {
|
|
14
|
+
const press = current.current;
|
|
15
|
+
if (press && !press.held) {
|
|
16
|
+
clearTimeout(press.timer);
|
|
17
|
+
press.off();
|
|
18
|
+
current.current = undefined;
|
|
19
|
+
}
|
|
20
|
+
}, []);
|
|
21
|
+
return React.useCallback((hold) => {
|
|
22
|
+
if (!hold) {
|
|
23
|
+
return {};
|
|
24
|
+
}
|
|
25
|
+
return {
|
|
26
|
+
'data-held': '',
|
|
27
|
+
onPointerDown: event => {
|
|
28
|
+
if (current.current || !event.isPrimary || event.button !== 0 || (hold.accepts && !hold.accepts(event))) {
|
|
29
|
+
return;
|
|
30
|
+
}
|
|
31
|
+
const from = { x: event.clientX, y: event.clientY };
|
|
32
|
+
const finish = (how) => {
|
|
33
|
+
if (current.current !== press) {
|
|
34
|
+
return;
|
|
35
|
+
}
|
|
36
|
+
current.current = undefined;
|
|
37
|
+
clearTimeout(press.timer);
|
|
38
|
+
press.off();
|
|
39
|
+
LongPressUtil.release(document);
|
|
40
|
+
if (!press.held || how === 'none') {
|
|
41
|
+
return;
|
|
42
|
+
}
|
|
43
|
+
HeldUtil.swallowClick();
|
|
44
|
+
if (how === 'end') {
|
|
45
|
+
hold.end();
|
|
46
|
+
}
|
|
47
|
+
else {
|
|
48
|
+
hold.cancel();
|
|
49
|
+
}
|
|
50
|
+
};
|
|
51
|
+
const onUp = () => finish('end');
|
|
52
|
+
const onCancel = () => finish('cancel');
|
|
53
|
+
const onMove = (moved) => {
|
|
54
|
+
var _a;
|
|
55
|
+
if (press.held) {
|
|
56
|
+
(_a = hold.move) === null || _a === void 0 ? void 0 : _a.call(hold, moved.clientX, moved.clientY);
|
|
57
|
+
}
|
|
58
|
+
else if (LongPressUtil.moved(from, moved)) {
|
|
59
|
+
finish('none');
|
|
60
|
+
}
|
|
61
|
+
};
|
|
62
|
+
// Held, the finger drags nothing: no scroll, which would take it from the hold (pointercancel).
|
|
63
|
+
const onTouchMove = (touch) => press.held && touch.cancelable && touch.preventDefault();
|
|
64
|
+
const press = {
|
|
65
|
+
hold,
|
|
66
|
+
held: false,
|
|
67
|
+
timer: setTimeout(() => {
|
|
68
|
+
var _a;
|
|
69
|
+
press.held = true;
|
|
70
|
+
LongPressUtil.take(document);
|
|
71
|
+
hold.start();
|
|
72
|
+
(_a = hold.move) === null || _a === void 0 ? void 0 : _a.call(hold, from.x, from.y);
|
|
73
|
+
}, LongPressUtil.PRESS_MS),
|
|
74
|
+
off: () => {
|
|
75
|
+
document.removeEventListener('pointerup', onUp);
|
|
76
|
+
document.removeEventListener('pointercancel', onCancel);
|
|
77
|
+
document.removeEventListener('pointermove', onMove);
|
|
78
|
+
document.removeEventListener('touchmove', onTouchMove);
|
|
79
|
+
},
|
|
80
|
+
};
|
|
81
|
+
current.current = press;
|
|
82
|
+
document.addEventListener('pointerup', onUp);
|
|
83
|
+
document.addEventListener('pointercancel', onCancel);
|
|
84
|
+
document.addEventListener('pointermove', onMove);
|
|
85
|
+
document.addEventListener('touchmove', onTouchMove, { passive: false });
|
|
86
|
+
},
|
|
87
|
+
// The long press of a finger (the system's, or startLongPress's) is the hold's: no menu. Taken, it is
|
|
88
|
+
// also what gives the light tap of the haptic engine in the app. A right click is the browser's.
|
|
89
|
+
onContextMenu: event => {
|
|
90
|
+
if (current.current) {
|
|
91
|
+
event.preventDefault();
|
|
92
|
+
}
|
|
93
|
+
},
|
|
94
|
+
};
|
|
95
|
+
}, []);
|
|
96
|
+
}
|
|
97
|
+
export var HeldUtil;
|
|
98
|
+
(function (HeldUtil) {
|
|
99
|
+
/** A light tap of the haptic engine as a held finger comes onto something (取消, 编辑): the app's, or a phone's. */
|
|
100
|
+
function tick() {
|
|
101
|
+
var _a, _b;
|
|
102
|
+
const haptics = nativePlugin('Haptics');
|
|
103
|
+
if (haptics) {
|
|
104
|
+
haptics('impact', { style: 'LIGHT' }).catch(() => undefined);
|
|
105
|
+
}
|
|
106
|
+
else {
|
|
107
|
+
(_b = (_a = globalThis.navigator) === null || _a === void 0 ? void 0 : _a.vibrate) === null || _b === void 0 ? void 0 : _b.call(_a, 8);
|
|
108
|
+
}
|
|
109
|
+
}
|
|
110
|
+
HeldUtil.tick = tick;
|
|
111
|
+
/**
|
|
112
|
+
* The click that follows a finger let go after a hold: not a tap of what was under it. A browser that sends
|
|
113
|
+
* none (a long press is no tap to it) leaves the next press its own.
|
|
114
|
+
*/
|
|
115
|
+
function swallowClick() {
|
|
116
|
+
const until = Date.now() + LongPressUtil.CLICK_GUARD_MS;
|
|
117
|
+
const off = () => {
|
|
118
|
+
document.removeEventListener('click', swallow, true);
|
|
119
|
+
document.removeEventListener('pointerdown', off, true);
|
|
120
|
+
};
|
|
121
|
+
const swallow = (event) => {
|
|
122
|
+
off();
|
|
123
|
+
if (Date.now() < until) {
|
|
124
|
+
event.preventDefault();
|
|
125
|
+
event.stopPropagation();
|
|
126
|
+
}
|
|
127
|
+
};
|
|
128
|
+
document.addEventListener('click', swallow, true);
|
|
129
|
+
document.addEventListener('pointerdown', off, true);
|
|
130
|
+
setTimeout(off, LongPressUtil.CLICK_GUARD_MS);
|
|
131
|
+
}
|
|
132
|
+
HeldUtil.swallowClick = swallowClick;
|
|
133
|
+
})(HeldUtil || (HeldUtil = {}));
|
|
134
|
+
//# sourceMappingURL=hold.js.map
|
|
@@ -17,7 +17,7 @@ export interface LaunchEnvironment {
|
|
|
17
17
|
*/
|
|
18
18
|
export declare class LaunchScreen {
|
|
19
19
|
protected readonly env: LaunchEnvironment;
|
|
20
|
-
static readonly MAX =
|
|
20
|
+
static readonly MAX = 2000;
|
|
21
21
|
static readonly FADE = 320;
|
|
22
22
|
protected done: boolean;
|
|
23
23
|
protected stops: (() => void)[];
|
|
@@ -11,6 +11,8 @@ export declare namespace LongPressUtil {
|
|
|
11
11
|
const MOVE_PX = 10;
|
|
12
12
|
/** After a menu opened, the click of the finger let go is not a tap of what was under it. */
|
|
13
13
|
const CLICK_GUARD_MS = 800;
|
|
14
|
+
/** What the finger of a long press that opened a menu pressed, while it is still down. */
|
|
15
|
+
function held(): Element | undefined;
|
|
14
16
|
function moved(from: {
|
|
15
17
|
x: number;
|
|
16
18
|
y: number;
|
|
@@ -18,6 +20,16 @@ export declare namespace LongPressUtil {
|
|
|
18
20
|
x: number;
|
|
19
21
|
y: number;
|
|
20
22
|
}): boolean;
|
|
23
|
+
/**
|
|
24
|
+
* Set on the root while a press is the page's (a menu took it, a hold holds it): nothing on the page is
|
|
25
|
+
* selectable then (style/device.ts). iOS selects the word under a held finger some 200ms after the menu
|
|
26
|
+
* opened, firing no `selectstart`, and asks the styles of that moment: a selection cleared or a
|
|
27
|
+
* `selectstart` stopped does not keep it away, `user-select` does.
|
|
28
|
+
*/
|
|
29
|
+
const TAKEN = "data-long-press";
|
|
30
|
+
function take(doc: Document): void;
|
|
31
|
+
/** The finger let go: the page is selectable again, and what the system selected meanwhile is let go too. */
|
|
32
|
+
function release(doc: Document): void;
|
|
21
33
|
/** Where a held finger is the system's: it moves the caret, selects, and pastes there. Mark more with `data-native-press`. */
|
|
22
34
|
function native(target: Element | null): boolean;
|
|
23
35
|
}
|