@celljs/ta-web 4.30.0 → 4.31.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 +1 -1
- package/README.md +1 -1
- package/esm/browser/account/account-side.js +1 -1
- package/esm/browser/account/device-account.d.ts +8 -0
- package/esm/browser/account/device-account.js +26 -0
- package/esm/browser/components/account-menu.d.ts +1 -1
- package/esm/browser/components/account-menu.js +8 -4
- package/esm/browser/components/account-view.d.ts +7 -0
- package/esm/browser/components/account-view.js +90 -10
- package/esm/browser/components/chat-tag.d.ts +13 -5
- package/esm/browser/components/chat-tag.js +23 -6
- package/esm/browser/components/cloud-sign-in-view.d.ts +1 -1
- package/esm/browser/components/composer-box.js +6 -2
- package/esm/browser/components/host-view.d.ts +1 -1
- package/esm/browser/components/host-view.js +3 -3
- package/esm/browser/components/me-rows.d.ts +2 -0
- package/esm/browser/components/me-rows.js +1 -1
- package/esm/browser/components/scan-screen.js +10 -0
- package/esm/browser/components/session-view.js +1 -1
- package/esm/browser/components/tool-view.js +10 -4
- package/esm/browser/components/voice-button.d.ts +7 -0
- package/esm/browser/components/voice-button.js +25 -2
- package/esm/browser/components/voice-talk.js +1 -1
- package/esm/browser/components/workbench-view.js +2 -2
- package/esm/browser/device/back-stack.d.ts +7 -0
- package/esm/browser/device/back-stack.js +13 -1
- package/esm/browser/device/code-scan.d.ts +5 -2
- package/esm/browser/device/code-scan.js +22 -2
- package/esm/browser/device/mini-program.d.ts +69 -0
- package/esm/browser/device/mini-program.js +251 -0
- package/esm/browser/device/sheet-swipe.js +4 -1
- package/esm/browser/device/swipe-util.d.ts +2 -0
- package/esm/browser/device/swipe-util.js +5 -0
- package/esm/browser/extension/extension-view.d.ts +1 -1
- package/esm/browser/extension/icons.js +2 -1
- package/esm/browser/extension/web-api-chats.d.ts +2 -0
- package/esm/browser/extension/web-api-components.d.ts +10 -1
- package/esm/browser/extension/web-api-storage.d.ts +20 -0
- package/esm/browser/extension/web-api-storage.js +3 -0
- package/esm/browser/extension/web-extension-api.d.ts +3 -27
- package/esm/browser/extension/web-extension-context.js +1 -1
- package/esm/browser/extension/web-home.d.ts +1 -1
- package/esm/browser/extension/web-home.js +7 -2
- package/esm/browser/extension/web-pages.js +2 -2
- package/esm/browser/i18n/en/account.d.ts +3 -1
- package/esm/browser/i18n/en/account.js +3 -1
- package/esm/browser/i18n/en/chat.d.ts +2 -0
- package/esm/browser/i18n/en/chat.js +3 -1
- package/esm/browser/i18n/en/common.d.ts +1 -0
- package/esm/browser/i18n/en/common.js +1 -0
- package/esm/browser/i18n/ja/account.js +3 -1
- package/esm/browser/i18n/ja/chat.js +3 -1
- package/esm/browser/i18n/ja/common.js +1 -0
- package/esm/browser/i18n/locales.d.ts +7 -2
- package/esm/browser/i18n/messages.d.ts +6 -1
- package/esm/browser/i18n/zh/account.js +3 -1
- package/esm/browser/i18n/zh/chat.js +3 -1
- package/esm/browser/i18n/zh/common.js +1 -0
- package/esm/browser/i18n/zh-tw/account.js +3 -1
- package/esm/browser/i18n/zh-tw/chat.js +3 -1
- package/esm/browser/i18n/zh-tw/common.js +1 -0
- package/esm/browser/links/links.d.ts +4 -1
- package/esm/browser/links/links.js +10 -1
- package/esm/browser/settings/settings.js +3 -0
- package/esm/browser/style/chat-list.d.ts +1 -1
- package/esm/browser/style/chat-list.js +2 -0
- package/esm/browser/style/dialogs.d.ts +1 -1
- package/esm/browser/style/dialogs.js +0 -1
- package/esm/browser/util/tool.d.ts +6 -2
- package/esm/browser/util/tool.js +28 -5
- package/esm/browser/util/voice.d.ts +9 -0
- package/esm/browser/util/voice.js +20 -0
- package/esm/browser/workbench-util.d.ts +5 -0
- package/esm/browser/workbench-util.js +9 -0
- package/esm/browser/workbench.js +6 -1
- package/lib/browser/account/account-side.js +1 -1
- package/lib/browser/account/device-account.d.ts +8 -0
- package/lib/browser/account/device-account.js +26 -0
- package/lib/browser/components/account-menu.d.ts +1 -1
- package/lib/browser/components/account-menu.js +6 -2
- package/lib/browser/components/account-view.d.ts +7 -0
- package/lib/browser/components/account-view.js +91 -10
- package/lib/browser/components/chat-tag.d.ts +13 -5
- package/lib/browser/components/chat-tag.js +22 -5
- package/lib/browser/components/cloud-sign-in-view.d.ts +1 -1
- package/lib/browser/components/composer-box.js +5 -1
- package/lib/browser/components/host-view.d.ts +1 -1
- package/lib/browser/components/host-view.js +3 -3
- package/lib/browser/components/me-rows.d.ts +2 -0
- package/lib/browser/components/me-rows.js +1 -1
- package/lib/browser/components/scan-screen.js +10 -0
- package/lib/browser/components/session-view.js +1 -1
- package/lib/browser/components/tool-view.js +10 -4
- package/lib/browser/components/voice-button.d.ts +7 -0
- package/lib/browser/components/voice-button.js +26 -2
- package/lib/browser/components/voice-talk.js +1 -1
- package/lib/browser/components/workbench-view.js +2 -2
- package/lib/browser/device/back-stack.d.ts +7 -0
- package/lib/browser/device/back-stack.js +13 -1
- package/lib/browser/device/code-scan.d.ts +5 -2
- package/lib/browser/device/code-scan.js +22 -2
- package/lib/browser/device/mini-program.d.ts +70 -0
- package/lib/browser/device/mini-program.js +254 -0
- package/lib/browser/device/sheet-swipe.js +4 -1
- package/lib/browser/device/swipe-util.d.ts +2 -0
- package/lib/browser/device/swipe-util.js +5 -0
- package/lib/browser/extension/extension-view.d.ts +1 -1
- package/lib/browser/extension/icons.js +1 -0
- package/lib/browser/extension/web-api-chats.d.ts +2 -0
- package/lib/browser/extension/web-api-components.d.ts +10 -1
- package/lib/browser/extension/web-api-storage.d.ts +21 -0
- package/lib/browser/extension/web-api-storage.js +4 -0
- package/lib/browser/extension/web-extension-api.d.ts +3 -27
- package/lib/browser/extension/web-extension-context.js +1 -1
- package/lib/browser/extension/web-home.d.ts +1 -1
- package/lib/browser/extension/web-home.js +7 -2
- package/lib/browser/extension/web-pages.js +1 -1
- package/lib/browser/i18n/en/account.d.ts +3 -1
- package/lib/browser/i18n/en/account.js +3 -1
- package/lib/browser/i18n/en/chat.d.ts +2 -0
- package/lib/browser/i18n/en/chat.js +3 -1
- package/lib/browser/i18n/en/common.d.ts +1 -0
- package/lib/browser/i18n/en/common.js +1 -0
- package/lib/browser/i18n/ja/account.js +3 -1
- package/lib/browser/i18n/ja/chat.js +3 -1
- package/lib/browser/i18n/ja/common.js +1 -0
- package/lib/browser/i18n/locales.d.ts +7 -2
- package/lib/browser/i18n/messages.d.ts +6 -1
- package/lib/browser/i18n/zh/account.js +3 -1
- package/lib/browser/i18n/zh/chat.js +3 -1
- package/lib/browser/i18n/zh/common.js +1 -0
- package/lib/browser/i18n/zh-tw/account.js +3 -1
- package/lib/browser/i18n/zh-tw/chat.js +3 -1
- package/lib/browser/i18n/zh-tw/common.js +1 -0
- package/lib/browser/links/links.d.ts +4 -1
- package/lib/browser/links/links.js +10 -1
- package/lib/browser/settings/settings.js +3 -0
- package/lib/browser/style/chat-list.d.ts +1 -1
- package/lib/browser/style/chat-list.js +2 -0
- package/lib/browser/style/dialogs.d.ts +1 -1
- package/lib/browser/style/dialogs.js +0 -1
- package/lib/browser/util/tool.d.ts +6 -2
- package/lib/browser/util/tool.js +28 -5
- package/lib/browser/util/voice.d.ts +9 -0
- package/lib/browser/util/voice.js +20 -0
- package/lib/browser/workbench-util.d.ts +5 -0
- package/lib/browser/workbench-util.js +9 -0
- package/lib/browser/workbench.js +6 -1
- package/package.json +10 -10
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Ta's web page in the web-view of Ta's WeChat mini program (apps/ta-weapp, docs/design/ta-weapp.md). The web-view has no
|
|
3
|
+
* camera of its own and hears nothing of its mini program while open: Scan goes to the scan page of the mini program
|
|
4
|
+
* (`wx.scanCode`), which opens the page again with what it read, a computer to pair with as `#pair=`
|
|
5
|
+
* (WorkbenchUtil.fromFragment) and any other code as `#scan=`, opened as a code scanned in the Ta app (CodeScan.open)
|
|
6
|
+
* once the page is connected. Its bar (WeChat's, over the web-view: a web-view has no bar of its own) is coloured as
|
|
7
|
+
* Ta's theme by the look page of the mini program (`paint`). Speech is heard by the voice page of the mini program
|
|
8
|
+
* (WeChat's recognizer, the WechatSI plugin: the web-view's own always refuses), which gives the words back in the
|
|
9
|
+
* fragment of the page (`#say=`), changed alone so that the page stays as it is (`dictate`).
|
|
10
|
+
*/
|
|
11
|
+
export declare namespace MiniProgram {
|
|
12
|
+
/** WeChat's JS-SDK, loaded in the mini program alone: what lets the page go to a page of the mini program. */
|
|
13
|
+
const SDK = "https://res.wx.qq.com/open/js/jweixin-1.6.0.js";
|
|
14
|
+
/** The scan page of apps/ta-weapp. */
|
|
15
|
+
const SCAN_PAGE = "/pages/scan/scan";
|
|
16
|
+
/** The page of apps/ta-weapp that colours the bar of the mini program, keeps the colour and goes back at once. */
|
|
17
|
+
const LOOK_PAGE = "/pages/look/look";
|
|
18
|
+
/** The page of apps/ta-weapp that listens and gives the page what it heard. */
|
|
19
|
+
const VOICE_PAGE = "/pages/voice/voice";
|
|
20
|
+
/** What the mini program says it has (`#can=`), kept: its fragment is read once, and the page may load again without it. */
|
|
21
|
+
const CAN_KEY = "ta.miniProgram.can";
|
|
22
|
+
/** The theme is applied a few times as the page starts (its look of the last time, then the computer's): the bar waits for the last. */
|
|
23
|
+
const PAINT_MS = 400;
|
|
24
|
+
/** Pure: whether a user agent is that of the web-view of a mini program (WeChat says `miniProgram` there, since 7.0). */
|
|
25
|
+
function isAgent(agent: string): boolean;
|
|
26
|
+
/** Whether this page is in the web-view of a mini program. */
|
|
27
|
+
function inside(): boolean;
|
|
28
|
+
/** Pure: the code the scan page of the mini program read, from the fragment it opened the page with. */
|
|
29
|
+
function scanned(fragment: URLSearchParams): string | undefined;
|
|
30
|
+
/** Pure: the colour of the bar the mini program opened the page under (`bar=`, six hex digits), as `#rrggbb`. */
|
|
31
|
+
function barOf(fragment: URLSearchParams): string | undefined;
|
|
32
|
+
/** Pure: the look page that colours the bar `color` (`#rrggbb`), its title and the clock white over a dark one. */
|
|
33
|
+
function lookUrl(color: string, dark: boolean): string;
|
|
34
|
+
/** Pure: what the mini program says it has, from its fragment (`can=voice,…`); undefined when it says nothing. */
|
|
35
|
+
function canOf(fragment: URLSearchParams): string[] | undefined;
|
|
36
|
+
/** Pure: the words its voice page heard (`say=`). */
|
|
37
|
+
function saidOf(fragment: URLSearchParams): string | undefined;
|
|
38
|
+
/** Pure: the language WeChat's recognizer hears, for the page's (Mandarin unless English: it has no other of Ta's). */
|
|
39
|
+
function voiceLanguage(language: string): string;
|
|
40
|
+
/**
|
|
41
|
+
* Keeps the code the page was opened with, in the mini program alone (a link elsewhere opens nothing by itself);
|
|
42
|
+
* whether the fragment said anything to the mini program's page (a code, its bar), to take out of the address.
|
|
43
|
+
*/
|
|
44
|
+
function arrive(fragment: URLSearchParams): boolean;
|
|
45
|
+
/** Whether the mini program hears speech for the page (its voice page). */
|
|
46
|
+
function canDictate(): boolean;
|
|
47
|
+
/**
|
|
48
|
+
* Opens the voice page of the mini program, which listens in `language` (the page's) and gives `onWords` what it
|
|
49
|
+
* heard; nothing when the user cancels. False where it could not open.
|
|
50
|
+
*/
|
|
51
|
+
function dictate(language: string, onWords: (words: string) => void): Promise<boolean>;
|
|
52
|
+
/** What was said while the page loaded again, once: to put into the box. */
|
|
53
|
+
function takeSaid(): string | undefined;
|
|
54
|
+
/**
|
|
55
|
+
* The history moved: whether to the words the voice page gave back (`#say=`), which go to what asked for them, the
|
|
56
|
+
* entry of the history they came in taken back (it is no layer of the page's, BackStack). The rest is the page's.
|
|
57
|
+
*/
|
|
58
|
+
function hears(): boolean;
|
|
59
|
+
/**
|
|
60
|
+
* The bar of the mini program in `color` (`#rrggbb`), the colour at the top of Ta's page: WeChat gives a web-view
|
|
61
|
+
* no way to colour it, so the look page does, pushed and gone at once, only when the colour changes (its last is
|
|
62
|
+
* kept by the mini program, which opens the page under it the next time).
|
|
63
|
+
*/
|
|
64
|
+
function paint(color: string, dark: boolean): void;
|
|
65
|
+
/** The code the page was opened with, once: to open once connected. */
|
|
66
|
+
function take(): string | undefined;
|
|
67
|
+
/** Goes to the scan page of the mini program, which opens this page again with the code; false where it could not. */
|
|
68
|
+
function scan(): Promise<boolean>;
|
|
69
|
+
}
|
|
70
|
+
//# sourceMappingURL=mini-program.d.ts.map
|
|
@@ -0,0 +1,254 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.MiniProgram = void 0;
|
|
4
|
+
/**
|
|
5
|
+
* Ta's web page in the web-view of Ta's WeChat mini program (apps/ta-weapp, docs/design/ta-weapp.md). The web-view has no
|
|
6
|
+
* camera of its own and hears nothing of its mini program while open: Scan goes to the scan page of the mini program
|
|
7
|
+
* (`wx.scanCode`), which opens the page again with what it read, a computer to pair with as `#pair=`
|
|
8
|
+
* (WorkbenchUtil.fromFragment) and any other code as `#scan=`, opened as a code scanned in the Ta app (CodeScan.open)
|
|
9
|
+
* once the page is connected. Its bar (WeChat's, over the web-view: a web-view has no bar of its own) is coloured as
|
|
10
|
+
* Ta's theme by the look page of the mini program (`paint`). Speech is heard by the voice page of the mini program
|
|
11
|
+
* (WeChat's recognizer, the WechatSI plugin: the web-view's own always refuses), which gives the words back in the
|
|
12
|
+
* fragment of the page (`#say=`), changed alone so that the page stays as it is (`dictate`).
|
|
13
|
+
*/
|
|
14
|
+
var MiniProgram;
|
|
15
|
+
(function (MiniProgram) {
|
|
16
|
+
/** WeChat's JS-SDK, loaded in the mini program alone: what lets the page go to a page of the mini program. */
|
|
17
|
+
MiniProgram.SDK = 'https://res.wx.qq.com/open/js/jweixin-1.6.0.js';
|
|
18
|
+
/** The scan page of apps/ta-weapp. */
|
|
19
|
+
MiniProgram.SCAN_PAGE = '/pages/scan/scan';
|
|
20
|
+
/** The page of apps/ta-weapp that colours the bar of the mini program, keeps the colour and goes back at once. */
|
|
21
|
+
MiniProgram.LOOK_PAGE = '/pages/look/look';
|
|
22
|
+
/** The page of apps/ta-weapp that listens and gives the page what it heard. */
|
|
23
|
+
MiniProgram.VOICE_PAGE = '/pages/voice/voice';
|
|
24
|
+
/** What the mini program says it has (`#can=`), kept: its fragment is read once, and the page may load again without it. */
|
|
25
|
+
MiniProgram.CAN_KEY = 'ta.miniProgram.can';
|
|
26
|
+
/** The theme is applied a few times as the page starts (its look of the last time, then the computer's): the bar waits for the last. */
|
|
27
|
+
MiniProgram.PAINT_MS = 400;
|
|
28
|
+
/** Pure: whether a user agent is that of the web-view of a mini program (WeChat says `miniProgram` there, since 7.0). */
|
|
29
|
+
function isAgent(agent) {
|
|
30
|
+
return /miniProgram/i.test(agent);
|
|
31
|
+
}
|
|
32
|
+
MiniProgram.isAgent = isAgent;
|
|
33
|
+
/** Whether this page is in the web-view of a mini program. */
|
|
34
|
+
function inside() {
|
|
35
|
+
if (typeof navigator === 'undefined') {
|
|
36
|
+
return false;
|
|
37
|
+
}
|
|
38
|
+
return isAgent(navigator.userAgent) || globalThis.__wxjs_environment === 'miniprogram';
|
|
39
|
+
}
|
|
40
|
+
MiniProgram.inside = inside;
|
|
41
|
+
/** Pure: the code the scan page of the mini program read, from the fragment it opened the page with. */
|
|
42
|
+
function scanned(fragment) {
|
|
43
|
+
var _a;
|
|
44
|
+
return ((_a = fragment.get('scan')) === null || _a === void 0 ? void 0 : _a.trim()) || undefined;
|
|
45
|
+
}
|
|
46
|
+
MiniProgram.scanned = scanned;
|
|
47
|
+
/** Pure: the colour of the bar the mini program opened the page under (`bar=`, six hex digits), as `#rrggbb`. */
|
|
48
|
+
function barOf(fragment) {
|
|
49
|
+
var _a;
|
|
50
|
+
const bar = (_a = fragment.get('bar')) === null || _a === void 0 ? void 0 : _a.trim().toLowerCase();
|
|
51
|
+
return bar && /^[0-9a-f]{6}$/.test(bar) ? `#${bar}` : undefined;
|
|
52
|
+
}
|
|
53
|
+
MiniProgram.barOf = barOf;
|
|
54
|
+
/** Pure: the look page that colours the bar `color` (`#rrggbb`), its title and the clock white over a dark one. */
|
|
55
|
+
function lookUrl(color, dark) {
|
|
56
|
+
return `${MiniProgram.LOOK_PAGE}?bar=${color.slice(1)}&text=${dark ? 'white' : 'black'}`;
|
|
57
|
+
}
|
|
58
|
+
MiniProgram.lookUrl = lookUrl;
|
|
59
|
+
/** Pure: what the mini program says it has, from its fragment (`can=voice,…`); undefined when it says nothing. */
|
|
60
|
+
function canOf(fragment) {
|
|
61
|
+
const can = fragment.get('can');
|
|
62
|
+
return can === null ? undefined : can.split(',').filter(Boolean);
|
|
63
|
+
}
|
|
64
|
+
MiniProgram.canOf = canOf;
|
|
65
|
+
/** Pure: the words its voice page heard (`say=`). */
|
|
66
|
+
function saidOf(fragment) {
|
|
67
|
+
var _a;
|
|
68
|
+
return ((_a = fragment.get('say')) === null || _a === void 0 ? void 0 : _a.trim()) || undefined;
|
|
69
|
+
}
|
|
70
|
+
MiniProgram.saidOf = saidOf;
|
|
71
|
+
/** Pure: the language WeChat's recognizer hears, for the page's (Mandarin unless English: it has no other of Ta's). */
|
|
72
|
+
function voiceLanguage(language) {
|
|
73
|
+
return /^en\b/i.test(language) ? 'en_US' : 'zh_CN';
|
|
74
|
+
}
|
|
75
|
+
MiniProgram.voiceLanguage = voiceLanguage;
|
|
76
|
+
let arrived;
|
|
77
|
+
let said;
|
|
78
|
+
let hearing;
|
|
79
|
+
/** How long the history was when the voice page opened: the words given back push an entry of their own, or not. */
|
|
80
|
+
let lengthBefore = 0;
|
|
81
|
+
let heardHash;
|
|
82
|
+
/** The colour of the bar now: as the mini program opened the page, then as the page asked. */
|
|
83
|
+
let bar = typeof location === 'undefined' || !inside() ? undefined : barOf(new URLSearchParams(location.hash.slice(1)));
|
|
84
|
+
let painting;
|
|
85
|
+
/**
|
|
86
|
+
* Keeps the code the page was opened with, in the mini program alone (a link elsewhere opens nothing by itself);
|
|
87
|
+
* whether the fragment said anything to the mini program's page (a code, its bar), to take out of the address.
|
|
88
|
+
*/
|
|
89
|
+
function arrive(fragment) {
|
|
90
|
+
var _a;
|
|
91
|
+
if (!inside()) {
|
|
92
|
+
return false;
|
|
93
|
+
}
|
|
94
|
+
const text = scanned(fragment);
|
|
95
|
+
arrived = text !== null && text !== void 0 ? text : arrived;
|
|
96
|
+
const can = canOf(fragment);
|
|
97
|
+
if (can) {
|
|
98
|
+
try {
|
|
99
|
+
localStorage.setItem(MiniProgram.CAN_KEY, can.join(','));
|
|
100
|
+
}
|
|
101
|
+
catch (_b) {
|
|
102
|
+
// Not kept: until the page loads again.
|
|
103
|
+
}
|
|
104
|
+
}
|
|
105
|
+
// The page loaded again with what was said (a web-view that reloads for a fragment): kept for the box.
|
|
106
|
+
said = (_a = saidOf(fragment)) !== null && _a !== void 0 ? _a : said;
|
|
107
|
+
return text !== undefined || barOf(fragment) !== undefined || can !== undefined || fragment.has('say');
|
|
108
|
+
}
|
|
109
|
+
MiniProgram.arrive = arrive;
|
|
110
|
+
/** Whether the mini program hears speech for the page (its voice page). */
|
|
111
|
+
function canDictate() {
|
|
112
|
+
var _a;
|
|
113
|
+
if (!inside()) {
|
|
114
|
+
return false;
|
|
115
|
+
}
|
|
116
|
+
try {
|
|
117
|
+
return ((_a = localStorage.getItem(MiniProgram.CAN_KEY)) !== null && _a !== void 0 ? _a : '').split(',').includes('voice');
|
|
118
|
+
}
|
|
119
|
+
catch (_b) {
|
|
120
|
+
return false;
|
|
121
|
+
}
|
|
122
|
+
}
|
|
123
|
+
MiniProgram.canDictate = canDictate;
|
|
124
|
+
/**
|
|
125
|
+
* Opens the voice page of the mini program, which listens in `language` (the page's) and gives `onWords` what it
|
|
126
|
+
* heard; nothing when the user cancels. False where it could not open.
|
|
127
|
+
*/
|
|
128
|
+
async function dictate(language, onWords) {
|
|
129
|
+
const mini = await api();
|
|
130
|
+
if (!mini) {
|
|
131
|
+
return false;
|
|
132
|
+
}
|
|
133
|
+
hearing = onWords;
|
|
134
|
+
lengthBefore = history.length;
|
|
135
|
+
return new Promise(resolve => mini.navigateTo({ url: `${MiniProgram.VOICE_PAGE}?lang=${voiceLanguage(language)}`, success: () => resolve(true), fail: () => resolve(false) }));
|
|
136
|
+
}
|
|
137
|
+
MiniProgram.dictate = dictate;
|
|
138
|
+
/** What was said while the page loaded again, once: to put into the box. */
|
|
139
|
+
function takeSaid() {
|
|
140
|
+
const words = said;
|
|
141
|
+
said = undefined;
|
|
142
|
+
return words;
|
|
143
|
+
}
|
|
144
|
+
MiniProgram.takeSaid = takeSaid;
|
|
145
|
+
/**
|
|
146
|
+
* The history moved: whether to the words the voice page gave back (`#say=`), which go to what asked for them, the
|
|
147
|
+
* entry of the history they came in taken back (it is no layer of the page's, BackStack). The rest is the page's.
|
|
148
|
+
*/
|
|
149
|
+
function hears() {
|
|
150
|
+
if (!inside()) {
|
|
151
|
+
return false;
|
|
152
|
+
}
|
|
153
|
+
const words = saidOf(new URLSearchParams(location.hash.slice(1)));
|
|
154
|
+
if (words === undefined) {
|
|
155
|
+
return false;
|
|
156
|
+
}
|
|
157
|
+
// Heard once, by popstate or hashchange (both come, and the history goes back later).
|
|
158
|
+
if (location.hash === heardHash) {
|
|
159
|
+
return true;
|
|
160
|
+
}
|
|
161
|
+
heardHash = location.hash;
|
|
162
|
+
if (history.length > lengthBefore && lengthBefore > 0) {
|
|
163
|
+
history.back();
|
|
164
|
+
}
|
|
165
|
+
else {
|
|
166
|
+
history.replaceState(history.state, '', location.pathname + location.search);
|
|
167
|
+
}
|
|
168
|
+
lengthBefore = 0;
|
|
169
|
+
const to = hearing;
|
|
170
|
+
hearing = undefined;
|
|
171
|
+
if (to) {
|
|
172
|
+
to(words);
|
|
173
|
+
}
|
|
174
|
+
else {
|
|
175
|
+
said = words;
|
|
176
|
+
}
|
|
177
|
+
return true;
|
|
178
|
+
}
|
|
179
|
+
MiniProgram.hears = hears;
|
|
180
|
+
/**
|
|
181
|
+
* The bar of the mini program in `color` (`#rrggbb`), the colour at the top of Ta's page: WeChat gives a web-view
|
|
182
|
+
* no way to colour it, so the look page does, pushed and gone at once, only when the colour changes (its last is
|
|
183
|
+
* kept by the mini program, which opens the page under it the next time).
|
|
184
|
+
*/
|
|
185
|
+
function paint(color, dark) {
|
|
186
|
+
if (!inside()) {
|
|
187
|
+
return;
|
|
188
|
+
}
|
|
189
|
+
clearTimeout(painting);
|
|
190
|
+
painting = setTimeout(() => {
|
|
191
|
+
if (color === bar) {
|
|
192
|
+
return;
|
|
193
|
+
}
|
|
194
|
+
// Behind the scan page, or WeChat in the background: once the page shows again.
|
|
195
|
+
if (document.visibilityState !== 'visible') {
|
|
196
|
+
document.addEventListener('visibilitychange', () => paint(color, dark), { once: true });
|
|
197
|
+
return;
|
|
198
|
+
}
|
|
199
|
+
const before = bar;
|
|
200
|
+
bar = color;
|
|
201
|
+
void api().then(mini => {
|
|
202
|
+
if (!mini) {
|
|
203
|
+
bar = before;
|
|
204
|
+
return;
|
|
205
|
+
}
|
|
206
|
+
mini.navigateTo({
|
|
207
|
+
url: lookUrl(color, dark),
|
|
208
|
+
// A mini program of before the look page: as it was.
|
|
209
|
+
fail: () => {
|
|
210
|
+
bar = before;
|
|
211
|
+
},
|
|
212
|
+
});
|
|
213
|
+
});
|
|
214
|
+
}, MiniProgram.PAINT_MS);
|
|
215
|
+
}
|
|
216
|
+
MiniProgram.paint = paint;
|
|
217
|
+
/** The code the page was opened with, once: to open once connected. */
|
|
218
|
+
function take() {
|
|
219
|
+
const text = arrived;
|
|
220
|
+
arrived = undefined;
|
|
221
|
+
return text;
|
|
222
|
+
}
|
|
223
|
+
MiniProgram.take = take;
|
|
224
|
+
let sdk;
|
|
225
|
+
function api() {
|
|
226
|
+
const found = () => { var _a; return (_a = globalThis.wx) === null || _a === void 0 ? void 0 : _a.miniProgram; };
|
|
227
|
+
sdk !== null && sdk !== void 0 ? sdk : (sdk = new Promise(resolve => {
|
|
228
|
+
if (found()) {
|
|
229
|
+
resolve(found());
|
|
230
|
+
return;
|
|
231
|
+
}
|
|
232
|
+
const script = document.createElement('script');
|
|
233
|
+
script.src = MiniProgram.SDK;
|
|
234
|
+
script.onload = () => resolve(found());
|
|
235
|
+
script.onerror = () => {
|
|
236
|
+
// Tried again on the next scan: the network may be back.
|
|
237
|
+
sdk = undefined;
|
|
238
|
+
resolve(undefined);
|
|
239
|
+
};
|
|
240
|
+
document.head.append(script);
|
|
241
|
+
}));
|
|
242
|
+
return sdk;
|
|
243
|
+
}
|
|
244
|
+
/** Goes to the scan page of the mini program, which opens this page again with the code; false where it could not. */
|
|
245
|
+
async function scan() {
|
|
246
|
+
const mini = await api();
|
|
247
|
+
if (!mini) {
|
|
248
|
+
return false;
|
|
249
|
+
}
|
|
250
|
+
return new Promise(resolve => mini.navigateTo({ url: MiniProgram.SCAN_PAGE, success: () => resolve(true), fail: () => resolve(false) }));
|
|
251
|
+
}
|
|
252
|
+
MiniProgram.scan = scan;
|
|
253
|
+
})(MiniProgram || (exports.MiniProgram = MiniProgram = {}));
|
|
254
|
+
//# sourceMappingURL=mini-program.js.map
|
|
@@ -35,6 +35,7 @@ var __importStar = (this && this.__importStar) || (function () {
|
|
|
35
35
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
36
36
|
exports.useSheetSwipe = useSheetSwipe;
|
|
37
37
|
const React = __importStar(require("react"));
|
|
38
|
+
const back_stack_1 = require("./back-stack");
|
|
38
39
|
const own_gestures_1 = require("./own-gestures");
|
|
39
40
|
const swipe_finger_1 = require("./swipe-finger");
|
|
40
41
|
const swipe_settle_1 = require("./swipe-settle");
|
|
@@ -257,7 +258,9 @@ function useSheetSwipe(options) {
|
|
|
257
258
|
return;
|
|
258
259
|
}
|
|
259
260
|
const at = point(event, touch);
|
|
260
|
-
|
|
261
|
+
// The web view's own swipe back, which would move the page with the sheet: left to it (BackLayers.webViewSwipesBack).
|
|
262
|
+
const theirs = back_stack_1.Back.size > 0 && swipe_util_1.SwipeUtil.fromBackEdge(sheet, at, current.open) && back_stack_1.BackLayers.webViewSwipesBack();
|
|
263
|
+
if (!theirs && swipe_util_1.SwipeUtil.starts(sheet, at, current.open, window.innerWidth) && finger.follow(event, from.doc)) {
|
|
261
264
|
start = at;
|
|
262
265
|
velocity.start(at);
|
|
263
266
|
}
|
|
@@ -31,6 +31,8 @@ export declare namespace SwipeUtil {
|
|
|
31
31
|
const VELOCITY_MS = 80;
|
|
32
32
|
/** 1 when the finger moves right to bring the sheet out, -1 when left. */
|
|
33
33
|
function outward(sheet: SheetSwipe): 1 | -1;
|
|
34
|
+
/** Whether a touch at `start` moving the sheet would be a swipe to the right from the left edge: the back of iOS. */
|
|
35
|
+
function fromBackEdge(sheet: SheetSwipe, start: TouchPoint, open: boolean): boolean;
|
|
34
36
|
/** Whether a touch at `start` may move the sheet, on a screen `width` wide. */
|
|
35
37
|
function starts(sheet: SheetSwipe, start: TouchPoint, open: boolean, width: number): boolean;
|
|
36
38
|
/** Whether the move so far is the sheet's (more sideways than down, the right way); undefined until it is told. */
|
|
@@ -28,6 +28,11 @@ var SwipeUtil;
|
|
|
28
28
|
function way(sheet, open) {
|
|
29
29
|
return open ? -outward(sheet) : outward(sheet);
|
|
30
30
|
}
|
|
31
|
+
/** Whether a touch at `start` moving the sheet would be a swipe to the right from the left edge: the back of iOS. */
|
|
32
|
+
function fromBackEdge(sheet, start, open) {
|
|
33
|
+
return start.x <= SwipeUtil.EDGE_PX && way(sheet, open) > 0;
|
|
34
|
+
}
|
|
35
|
+
SwipeUtil.fromBackEdge = fromBackEdge;
|
|
31
36
|
/** Whether a touch at `start` may move the sheet, on a screen `width` wide. */
|
|
32
37
|
function starts(sheet, start, open, width) {
|
|
33
38
|
const from = open ? sheet.closesFrom : sheet.opensFrom;
|
|
@@ -18,7 +18,7 @@ export declare const ChatTags: React.Context<{
|
|
|
18
18
|
version: number;
|
|
19
19
|
}>;
|
|
20
20
|
/** The avatars that web extensions registered for the sessions of their groups. */
|
|
21
|
-
export declare const SessionAvatars: React.Context<Record<string, React.ComponentType<import("./web-
|
|
21
|
+
export declare const SessionAvatars: React.Context<Record<string, React.ComponentType<import("./web-api-components").WebAvatarProps>>>;
|
|
22
22
|
/** The group of the conversations calls are answered in (WebExtensionsState.callGroup): shown as the record of a call. */
|
|
23
23
|
export declare const CallGroup: React.Context<string | undefined>;
|
|
24
24
|
/** What web extensions add to the menu of a conversation of a list (WebExtensionAPI.registerSessionMenu). */
|
|
@@ -114,6 +114,7 @@ exports.WEB_ICONS = Object.freeze({
|
|
|
114
114
|
MonitorSmartphone: lucide_react_1.MonitorSmartphone,
|
|
115
115
|
MousePointer2: lucide_react_1.MousePointer2,
|
|
116
116
|
MousePointerClick: lucide_react_1.MousePointerClick,
|
|
117
|
+
Navigation: lucide_react_1.Navigation,
|
|
117
118
|
Package: lucide_react_1.Package,
|
|
118
119
|
PackageOpen: lucide_react_1.PackageOpen,
|
|
119
120
|
Paperclip: lucide_react_1.Paperclip,
|
|
@@ -57,6 +57,8 @@ export interface WebChatTagSource {
|
|
|
57
57
|
tag(chat: WebChat): WebChatTag | undefined;
|
|
58
58
|
/** What `tag` answers changed: the lists draw their rows again. */
|
|
59
59
|
subscribe?(listener: () => void): () => void;
|
|
60
|
+
/** The tag on top of a conversation was tapped: show what it means and how to change it. */
|
|
61
|
+
open?(chat: WebChat): void;
|
|
60
62
|
}
|
|
61
63
|
/** What a web extension adds to the conversations of the lists (WebExtensionAPI extends it). */
|
|
62
64
|
export interface WebChatTagsAPI {
|
|
@@ -1,5 +1,7 @@
|
|
|
1
|
-
/** Part of the web extension API (web-extension-api.ts, which exports it all): the props of the components of `ui
|
|
1
|
+
/** Part of the web extension API (web-extension-api.ts, which exports it all): the props of the components of `ui`, and of the avatar an extension gives (registerAvatar). */
|
|
2
|
+
import type { TaSessionInfo } from '@celljs/ta-protocol';
|
|
2
3
|
import type * as React from 'react';
|
|
4
|
+
import type { Mood } from '../avatar/dino-avatar';
|
|
3
5
|
import type { TextSelection, WebIcon, WebTask } from './web-extension-api';
|
|
4
6
|
export interface WebModelPickerProps {
|
|
5
7
|
/** The directory whose settings give the models and the default; default: that of ta serve. */
|
|
@@ -404,4 +406,11 @@ export interface WebConversationViewProps {
|
|
|
404
406
|
/** The pictures of the workspace its replies show, as URLs by the path written in them. */
|
|
405
407
|
files?: Readonly<Record<string, string>>;
|
|
406
408
|
}
|
|
409
|
+
export interface WebAvatarProps {
|
|
410
|
+
session: TaSessionInfo;
|
|
411
|
+
/** What the agent does at the time, as ta's avatar shows it. */
|
|
412
|
+
mood: Mood;
|
|
413
|
+
/** In pixels. */
|
|
414
|
+
size: number;
|
|
415
|
+
}
|
|
407
416
|
//# sourceMappingURL=web-api-components.d.ts.map
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
/** Part of the web extension API (web-extension-api.ts, which exports it all): the data a package keeps on the server. */
|
|
2
|
+
export interface WebStorage {
|
|
3
|
+
get<T = unknown>(key: string): Promise<T | undefined>;
|
|
4
|
+
/** `null` removes the key. */
|
|
5
|
+
set(key: string, value: unknown): Promise<void>;
|
|
6
|
+
/**
|
|
7
|
+
* Keys that changed, by this page, another page, or the package on the server; a few times a second
|
|
8
|
+
* at most, with the keys of that time together. It hears them once the page read one of its keys.
|
|
9
|
+
* Stops when the extension unloads.
|
|
10
|
+
*/
|
|
11
|
+
onChange(listener: (keys: string[]) => void): () => void;
|
|
12
|
+
}
|
|
13
|
+
export interface WebPackageStorage extends WebStorage {
|
|
14
|
+
/**
|
|
15
|
+
* The values of the package for one directory (`ui.useCwd()`), with keys of their own: what belongs
|
|
16
|
+
* to it, as the folders open in an explorer, found again in any browser that shows that directory.
|
|
17
|
+
* The same directory on another execution environment is another one.
|
|
18
|
+
*/
|
|
19
|
+
directory(cwd: string): WebStorage;
|
|
20
|
+
}
|
|
21
|
+
//# sourceMappingURL=web-api-storage.d.ts.map
|
|
@@ -6,13 +6,14 @@ import type { GameProps } from '../game/game-protocol';
|
|
|
6
6
|
import type { Game3DProps } from '../game/game3d-protocol';
|
|
7
7
|
import type { ScreenPartSpec, TaScreen } from '../screen/screen-protocol';
|
|
8
8
|
import type { Language, Theme } from '../settings/settings-protocol';
|
|
9
|
-
import type { CodeEditorProps, DiffEditorProps, WebChatImagesProps, WebComposerProps, WebConversationViewProps, WebDialogProps, WebEmptyProps, WebFaceProps, WebFolderPickerProps, WebFullScreenProps, WebGroupFaceProps, WebHoldToTalkProps, WebImageViewerProps, WebLoadingProps, WebModelPickerProps, WebPictureCardsProps, WebPictureProps, WebSelectBarProps, WebSelectCheckProps, WebShareSheetProps, WebStackProps, WebSwipeRowProps, WebSwitchProps, WebTaskIconProps, WebVoice } from './web-api-components';
|
|
9
|
+
import type { CodeEditorProps, DiffEditorProps, WebAvatarProps, WebChatImagesProps, WebComposerProps, WebConversationViewProps, WebDialogProps, WebEmptyProps, WebFaceProps, WebFolderPickerProps, WebFullScreenProps, WebGroupFaceProps, WebHoldToTalkProps, WebImageViewerProps, WebLoadingProps, WebModelPickerProps, WebPictureCardsProps, WebPictureProps, WebSelectBarProps, WebSelectCheckProps, WebShareSheetProps, WebStackProps, WebSwipeRowProps, WebSwitchProps, WebTaskIconProps, WebVoice } from './web-api-components';
|
|
10
10
|
import type { WebAsk, WebCallsAPI, WebChatIconSource, WebChatTagsAPI, WebCodeRendererOptions, WebCodeRendererProps, WebComposerAddon, WebCustomMessage, WebHomeSource, WebInitiative, WebMenuItem, WebOpener, WebOpenerOptions, WebRoomAddon, WebRoomAddonEntry, WebSearchSource, WebSessionNotice, WebSettingsSection, WebShareTarget, WebTaskEntry, WebTaskRemoval, WebTaskSource, WebTool, WebToolRendererResolver, WebView, WebViewInfo, WidgetOptions } from './web-api-contributions';
|
|
11
11
|
import type { WebDesktop, WebDeviceUI, WebFileDrag } from './web-api-desktop';
|
|
12
12
|
import type { WebEditorsUI } from './web-api-editors';
|
|
13
13
|
import type { WebHomeUI, WebPartnersAPI, WebPartnersUI } from './web-api-home';
|
|
14
14
|
import type { WebFileRef, WebMenus } from './web-api-menus';
|
|
15
15
|
import type { WebServices } from './web-api-services';
|
|
16
|
+
import type { WebPackageStorage } from './web-api-storage';
|
|
16
17
|
import type { WebTerminal, WebTerminalOptions } from './web-api-terminal';
|
|
17
18
|
import type { WebPageInfo } from './web-pages';
|
|
18
19
|
export type { Mood } from '../avatar/dino-avatar';
|
|
@@ -28,6 +29,7 @@ export type * from './web-api-editors';
|
|
|
28
29
|
export type * from './web-api-home';
|
|
29
30
|
export type * from './web-api-menus';
|
|
30
31
|
export type * from './web-api-services';
|
|
32
|
+
export type * from './web-api-storage';
|
|
31
33
|
export type * from './web-api-terminal';
|
|
32
34
|
export type { WebPageInfo, WebPageState } from './web-pages';
|
|
33
35
|
/**
|
|
@@ -173,32 +175,6 @@ export interface WebSessionOpening {
|
|
|
173
175
|
/** Its session file, when known: what the device kept of the conversation shows while it opens, and while the computer cannot be reached. */
|
|
174
176
|
sessionFile?: string;
|
|
175
177
|
}
|
|
176
|
-
export interface WebStorage {
|
|
177
|
-
get<T = unknown>(key: string): Promise<T | undefined>;
|
|
178
|
-
/** `null` removes the key. */
|
|
179
|
-
set(key: string, value: unknown): Promise<void>;
|
|
180
|
-
/**
|
|
181
|
-
* Keys that changed, by this page, another page, or the package on the server; a few times a second
|
|
182
|
-
* at most, with the keys of that time together. It hears them once the page read one of its keys.
|
|
183
|
-
* Stops when the extension unloads.
|
|
184
|
-
*/
|
|
185
|
-
onChange(listener: (keys: string[]) => void): () => void;
|
|
186
|
-
}
|
|
187
|
-
export interface WebPackageStorage extends WebStorage {
|
|
188
|
-
/**
|
|
189
|
-
* The values of the package for one directory (`ui.useCwd()`), with keys of their own: what belongs
|
|
190
|
-
* to it, as the folders open in an explorer, found again in any browser that shows that directory.
|
|
191
|
-
* The same directory on another execution environment is another one.
|
|
192
|
-
*/
|
|
193
|
-
directory(cwd: string): WebStorage;
|
|
194
|
-
}
|
|
195
|
-
export interface WebAvatarProps {
|
|
196
|
-
session: TaSessionInfo;
|
|
197
|
-
/** What the agent does at the time, as ta's avatar shows it. */
|
|
198
|
-
mood: Mood;
|
|
199
|
-
/** In pixels. */
|
|
200
|
-
size: number;
|
|
201
|
-
}
|
|
202
178
|
/** An icon, drawn at `size` pixels in `currentColor`. */
|
|
203
179
|
export type WebIcon = React.ComponentType<{
|
|
204
180
|
size?: number | string;
|
|
@@ -397,7 +397,7 @@ class WebExtensionContext {
|
|
|
397
397
|
return [menu, openSections];
|
|
398
398
|
},
|
|
399
399
|
attachMenu: context_menu_1.ContextMenuUtil.attach,
|
|
400
|
-
scanCode: code_scan_1.CodeScan.
|
|
400
|
+
scanCode: code_scan_1.CodeScan.readable()
|
|
401
401
|
? instructions => (run.stopped ? Promise.resolve(undefined) : code_scan_1.CodeScan.read(instructions, (0, messages_1.message)(settings.state.language, 'ta.cancel')))
|
|
402
402
|
: undefined,
|
|
403
403
|
saveFile: file_save_1.FileSave.available() ? (file, name) => (run.stopped ? Promise.resolve('cancelled') : file_save_1.FileSave.save(file, name)) : undefined,
|
|
@@ -7,7 +7,7 @@ export declare namespace WebHomeUtil {
|
|
|
7
7
|
function shown(state: Pick<WebExtensionsState, 'page' | 'pageHidden' | 'pageFrom'>): string | undefined;
|
|
8
8
|
/**
|
|
9
9
|
* What an extension's lists read of the double's home (WebHomeUI), its tasks, and the start of a chat with partners
|
|
10
|
-
* (`extension`, whose partner one picked already is); opening
|
|
10
|
+
* (`extension`, whose partner one picked already is); opening nothing, the picker neither, once it stopped.
|
|
11
11
|
*/
|
|
12
12
|
function ui(extensions: TaWebExtensions, stopped: () => boolean, extension: string): WebHomeUI & WebPartnersUI & Pick<WebExtensionUI, 'useTasks'>;
|
|
13
13
|
}
|
|
@@ -46,7 +46,7 @@ var WebHomeUtil;
|
|
|
46
46
|
WebHomeUtil.shown = shown;
|
|
47
47
|
/**
|
|
48
48
|
* What an extension's lists read of the double's home (WebHomeUI), its tasks, and the start of a chat with partners
|
|
49
|
-
* (`extension`, whose partner one picked already is); opening
|
|
49
|
+
* (`extension`, whose partner one picked already is); opening nothing, the picker neither, once it stopped.
|
|
50
50
|
*/
|
|
51
51
|
function ui(extensions, stopped, extension) {
|
|
52
52
|
const subscribe = (listener) => extensions.subscribe(listener);
|
|
@@ -56,7 +56,12 @@ var WebHomeUtil;
|
|
|
56
56
|
openHome: entry => (stopped() ? Promise.resolve() : extensions.openHome(entry)),
|
|
57
57
|
useHomeShown: () => React.useSyncExternalStore(subscribe, read, read),
|
|
58
58
|
useTasks: () => React.useSyncExternalStore(extensions.tasks.subscribe, extensions.tasks.tasks, extensions.tasks.tasks),
|
|
59
|
-
startGroup: partner =>
|
|
59
|
+
startGroup: partner => {
|
|
60
|
+
if (stopped()) {
|
|
61
|
+
return;
|
|
62
|
+
}
|
|
63
|
+
(0, group_picker_1.openGroupPicker)(extensions, partner === undefined ? undefined : extensions.partners.partners().find(each => each.key === `${extension}/${partner}`));
|
|
64
|
+
},
|
|
60
65
|
openPartner: async (id, kind) => {
|
|
61
66
|
const partner = extensions.partners.partners().find(each => each.id === id && (!kind || each.kind === kind));
|
|
62
67
|
if (!partner || stopped()) {
|
|
@@ -11,7 +11,7 @@ var WebPagesUtil;
|
|
|
11
11
|
/** A temporary package tells the server it was used at most this often: what clears it counts in days. */
|
|
12
12
|
WebPagesUtil.TELL_SERVER_MS = 60 * 60 * 1000;
|
|
13
13
|
WebPagesUtil.USED = {
|
|
14
|
-
key:
|
|
14
|
+
key: ta_protocol_1.TA_PAGES_USED.key,
|
|
15
15
|
tier: 'user',
|
|
16
16
|
passive: true,
|
|
17
17
|
initial: {},
|
|
@@ -117,10 +117,12 @@ export declare const ACCOUNT_EN: {
|
|
|
117
117
|
'ta.myDevices.signOutConfirmComputer': string;
|
|
118
118
|
'ta.myDevices.none': string;
|
|
119
119
|
'ta.myDevices.open': string;
|
|
120
|
-
'ta.myDevices.signInAccount': string;
|
|
121
120
|
'ta.myDevices.others': string;
|
|
122
121
|
'ta.myDevices.computersComing': string;
|
|
123
122
|
'ta.me.profile': string;
|
|
123
|
+
'ta.me.signIn': string;
|
|
124
|
+
'ta.me.signInAs': string;
|
|
125
|
+
'ta.me.signInAsHint': string;
|
|
124
126
|
'ta.me.picture': string;
|
|
125
127
|
'ta.me.name': string;
|
|
126
128
|
'ta.me.nameHint': string;
|
|
@@ -122,10 +122,12 @@ exports.ACCOUNT_EN = {
|
|
|
122
122
|
'ta.myDevices.signOutConfirmComputer': 'Sign out of the account? This computer leaves it, and the devices it added can no longer reach it.',
|
|
123
123
|
'ta.myDevices.none': 'Only this device so far. Sign in to the same account on your other computers and phone.',
|
|
124
124
|
'ta.myDevices.open': 'Open',
|
|
125
|
-
'ta.myDevices.signInAccount': 'Sign in with an account',
|
|
126
125
|
'ta.myDevices.others': 'Other devices',
|
|
127
126
|
'ta.myDevices.computersComing': 'Sign in to the same account in Ta on your computer: it shows up here by itself.',
|
|
128
127
|
'ta.me.profile': 'Profile',
|
|
128
|
+
'ta.me.signIn': 'Sign in to an account',
|
|
129
|
+
'ta.me.signInAs': 'Sign in as {name}',
|
|
130
|
+
'ta.me.signInAsHint': 'The account of {computer}: no page to sign in on, {computer} lets this device in.',
|
|
129
131
|
'ta.me.picture': 'Picture',
|
|
130
132
|
'ta.me.name': 'Name',
|
|
131
133
|
'ta.me.nameHint': 'The name friends and group chats see',
|
|
@@ -160,6 +160,7 @@ export declare const CHAT_EN: {
|
|
|
160
160
|
'ta.composer.voiceStop': string;
|
|
161
161
|
'ta.composer.listening': string;
|
|
162
162
|
'ta.composer.voiceDenied': string;
|
|
163
|
+
'ta.composer.voiceUnavailable': string;
|
|
163
164
|
'ta.composer.voiceFailed': string;
|
|
164
165
|
'ta.talk.listening': string;
|
|
165
166
|
'ta.talk.edit': string;
|
|
@@ -210,5 +211,6 @@ export declare const CHAT_EN: {
|
|
|
210
211
|
'ta.composer.queue.remove': string;
|
|
211
212
|
'ta.chat.replyingFor': string;
|
|
212
213
|
'ta.chats.busy': string;
|
|
214
|
+
'ta.chat.tagOpen': string;
|
|
213
215
|
};
|
|
214
216
|
//# sourceMappingURL=chat.d.ts.map
|
|
@@ -162,7 +162,8 @@ exports.CHAT_EN = {
|
|
|
162
162
|
'ta.composer.voice': 'Voice input',
|
|
163
163
|
'ta.composer.voiceStop': 'Stop listening',
|
|
164
164
|
'ta.composer.listening': 'Listening…',
|
|
165
|
-
'ta.composer.voiceDenied': 'Ta may not use the microphone or speech recognition.
|
|
165
|
+
'ta.composer.voiceDenied': 'Ta may not use the microphone or speech recognition. If they are allowed already, this browser may have no speech recognition: try Safari, Chrome or the Ta app.',
|
|
166
|
+
'ta.composer.voiceUnavailable': 'Speech recognition is not available in this browser (on an iPhone, turn on Siri & Dictation). Try Safari, Chrome or the Ta app.',
|
|
166
167
|
'ta.composer.voiceFailed': 'Speech recognition failed: {error}',
|
|
167
168
|
'ta.talk.listening': 'Listening…',
|
|
168
169
|
'ta.talk.edit': 'Edit',
|
|
@@ -213,5 +214,6 @@ exports.CHAT_EN = {
|
|
|
213
214
|
'ta.composer.queue.remove': 'Remove',
|
|
214
215
|
'ta.chat.replyingFor': '{names} · answering',
|
|
215
216
|
'ta.chats.busy': 'Conversations going on',
|
|
217
|
+
'ta.chat.tagOpen': 'What this means, and how to change it',
|
|
216
218
|
};
|
|
217
219
|
//# sourceMappingURL=chat.js.map
|
|
@@ -38,6 +38,7 @@ exports.COMMON_EN = {
|
|
|
38
38
|
'ta.link.openFolder': 'Click to show in the explorer',
|
|
39
39
|
'ta.link.external': 'Ctrl + click to open in your browser',
|
|
40
40
|
'ta.link.externalMac': 'Cmd + click to open in your browser',
|
|
41
|
+
'ta.link.copiedToOpen': 'Link copied: open it in a browser',
|
|
41
42
|
'ta.link.ask': 'Open this page in your browser?',
|
|
42
43
|
'ta.link.open': 'Open',
|
|
43
44
|
'ta.link.trust': 'Trust {host}',
|