@allbluecn/web-app 0.27.5 → 0.27.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/components/quick-capture/__tests__/quick-capture-panel.test.tsx +64 -6
- package/src/components/quick-capture/quick-capture-panel.tsx +91 -21
- package/src/lib/changelog/sdk-versions.ts +1 -1
- package/src/lib/desktop-bridge-types.ts +4 -0
- package/src/paraglide/messages/_index.js +3 -0
- package/src/paraglide/messages/quick_capture_comingsoon1.js +30 -0
- package/src/paraglide/messages/quick_capture_hint.js +3 -3
- package/src/paraglide/messages/quick_capture_tabbug1.js +30 -0
- package/src/paraglide/messages/quick_capture_tabtask1.js +30 -0
package/package.json
CHANGED
|
@@ -33,7 +33,7 @@
|
|
|
33
33
|
// 15) 请求在途期间再 Enter 不重复提交
|
|
34
34
|
// 富文本编辑器 / AI 工具栏 / 内联编辑器在 jsdom 以替身注入。
|
|
35
35
|
import { afterEach, beforeEach, describe, expect, it, vi } from 'vitest'
|
|
36
|
-
import { act, cleanup, render, screen, waitFor } from '@testing-library/react'
|
|
36
|
+
import { act, cleanup, fireEvent, render, screen, waitFor } from '@testing-library/react'
|
|
37
37
|
import userEvent from '@testing-library/user-event'
|
|
38
38
|
import { QueryClient, QueryClientProvider } from '@tanstack/react-query'
|
|
39
39
|
|
|
@@ -48,9 +48,11 @@ const listLabelsFnMock = vi.hoisted(() => vi.fn())
|
|
|
48
48
|
const bridgeStub = vi.hoisted(() => {
|
|
49
49
|
const unsubMiniPanelMode = vi.fn()
|
|
50
50
|
const unsubMiniPanelPinned = vi.fn()
|
|
51
|
+
const unsubMiniPanelShown = vi.fn()
|
|
51
52
|
return {
|
|
52
53
|
unsubMiniPanelMode,
|
|
53
54
|
unsubMiniPanelPinned,
|
|
55
|
+
unsubMiniPanelShown,
|
|
54
56
|
window: vi.fn(),
|
|
55
57
|
notifyQuickCapture: vi.fn(),
|
|
56
58
|
setMiniPanelPinned: vi.fn(),
|
|
@@ -59,6 +61,7 @@ const bridgeStub = vi.hoisted(() => {
|
|
|
59
61
|
quitApp: vi.fn(),
|
|
60
62
|
onMiniPanelMode: vi.fn((_cb: (mode: string) => void) => unsubMiniPanelMode),
|
|
61
63
|
onMiniPanelPinned: vi.fn((_cb: (pinned: boolean) => void) => unsubMiniPanelPinned),
|
|
64
|
+
onMiniPanelShown: vi.fn((_cb: () => void) => unsubMiniPanelShown),
|
|
62
65
|
}
|
|
63
66
|
})
|
|
64
67
|
|
|
@@ -156,16 +159,32 @@ beforeEach(() => {
|
|
|
156
159
|
afterEach(() => cleanup())
|
|
157
160
|
|
|
158
161
|
describe('QuickCapturePanel', () => {
|
|
159
|
-
it('渲染顶部栏(logo + mini
|
|
162
|
+
it('渲染顶部栏(logo + mini 面板)、三个类型 tab、默认预选独立需求与快捷键文案', async () => {
|
|
160
163
|
renderPanel()
|
|
161
164
|
expect(screen.getAllByAltText('AllBlue').length).toBeGreaterThan(0)
|
|
162
165
|
expect(screen.getByText('mini 面板')).toBeTruthy()
|
|
163
|
-
//
|
|
164
|
-
expect(screen.
|
|
165
|
-
expect(screen.
|
|
166
|
+
// 类型 tab:需求/灵感(当前)、BUG、任务(占位)
|
|
167
|
+
expect(screen.getByRole('button', { name: '需求/灵感' })).toBeTruthy()
|
|
168
|
+
expect(screen.getByRole('button', { name: 'BUG' })).toBeTruthy()
|
|
169
|
+
expect(screen.getByRole('button', { name: '任务' })).toBeTruthy()
|
|
166
170
|
expect(await screen.findByText('独立需求')).toBeTruthy()
|
|
167
171
|
expect(screen.getByPlaceholderText('标题')).toBeTruthy()
|
|
168
|
-
expect(screen.getByText('Enter 记录 ·
|
|
172
|
+
expect(screen.getByText('Enter 记录 · ⌘+Enter 编辑区提交 · Esc 关闭')).toBeTruthy()
|
|
173
|
+
})
|
|
174
|
+
|
|
175
|
+
it('类型 tab:切到 BUG/任务显示占位,切回需求/灵感表单仍在', async () => {
|
|
176
|
+
const user = userEvent.setup()
|
|
177
|
+
const { container } = renderPanel()
|
|
178
|
+
await screen.findByText('独立需求')
|
|
179
|
+
expect(container.querySelector('input[placeholder="标题"]')).toBeTruthy()
|
|
180
|
+
await user.click(screen.getByRole('button', { name: 'BUG' }))
|
|
181
|
+
expect(screen.getByText('该类型记录即将上线,敬请期待')).toBeTruthy()
|
|
182
|
+
expect(container.querySelector('input[placeholder="标题"]')).toBeNull()
|
|
183
|
+
expect(screen.queryByRole('button', { name: '记录' })).toBeNull()
|
|
184
|
+
await user.click(screen.getByRole('button', { name: '任务' }))
|
|
185
|
+
expect(screen.getByText('该类型记录即将上线,敬请期待')).toBeTruthy()
|
|
186
|
+
await user.click(screen.getByRole('button', { name: '需求/灵感' }))
|
|
187
|
+
expect(container.querySelector('input[placeholder="标题"]')).toBeTruthy()
|
|
169
188
|
})
|
|
170
189
|
|
|
171
190
|
it('标题 Enter 提交:带默认独立需求 projectId 与内联字段缺省值', async () => {
|
|
@@ -197,6 +216,45 @@ describe('QuickCapturePanel', () => {
|
|
|
197
216
|
expect(quickCaptureStoryFnMock).not.toHaveBeenCalled()
|
|
198
217
|
})
|
|
199
218
|
|
|
219
|
+
it('失焦状态(焦点不在输入框)Enter 也提交', async () => {
|
|
220
|
+
const { container } = renderPanel()
|
|
221
|
+
await screen.findByText('独立需求')
|
|
222
|
+
fireEvent.change(screen.getByPlaceholderText('标题'), { target: { value: '失焦提交' } })
|
|
223
|
+
// 模拟焦点移到面板容器(非输入框、非按钮)后按 Enter
|
|
224
|
+
fireEvent.keyDown(container.firstElementChild as HTMLElement, { key: 'Enter' })
|
|
225
|
+
await waitFor(() =>
|
|
226
|
+
expect(quickCaptureStoryFnMock).toHaveBeenCalledWith({
|
|
227
|
+
data: expect.objectContaining({ name: '失焦提交' }),
|
|
228
|
+
}),
|
|
229
|
+
)
|
|
230
|
+
})
|
|
231
|
+
|
|
232
|
+
it('描述编辑器内:Enter 换行不提交,⌘+Enter 提交', async () => {
|
|
233
|
+
renderPanel()
|
|
234
|
+
await screen.findByText('独立需求')
|
|
235
|
+
fireEvent.change(screen.getByPlaceholderText('标题'), { target: { value: '编辑器提交' } })
|
|
236
|
+
const editor = screen.getByTestId('description-editor')
|
|
237
|
+
fireEvent.keyDown(editor, { key: 'Enter' })
|
|
238
|
+
expect(quickCaptureStoryFnMock).not.toHaveBeenCalled()
|
|
239
|
+
fireEvent.keyDown(editor, { key: 'Enter', metaKey: true })
|
|
240
|
+
await waitFor(() =>
|
|
241
|
+
expect(quickCaptureStoryFnMock).toHaveBeenCalledWith({
|
|
242
|
+
data: expect.objectContaining({ name: '编辑器提交' }),
|
|
243
|
+
}),
|
|
244
|
+
)
|
|
245
|
+
})
|
|
246
|
+
|
|
247
|
+
it('main 推送 panel-shown → 标题框重新聚焦', async () => {
|
|
248
|
+
renderPanel()
|
|
249
|
+
await screen.findByText('独立需求')
|
|
250
|
+
const input = screen.getByPlaceholderText('标题') as HTMLInputElement
|
|
251
|
+
input.blur()
|
|
252
|
+
const shownCb = bridgeStub.onMiniPanelShown.mock.calls[0]?.[0]
|
|
253
|
+
expect(shownCb).toBeTypeOf('function')
|
|
254
|
+
act(() => shownCb?.())
|
|
255
|
+
expect(document.activeElement).toBe(input)
|
|
256
|
+
})
|
|
257
|
+
|
|
200
258
|
it('项目下拉选中「灵感箱」:Popover 自动关闭,保存传 kind=inspiration 且无 projectId', async () => {
|
|
201
259
|
const user = userEvent.setup()
|
|
202
260
|
renderPanel()
|
|
@@ -66,6 +66,9 @@ import {
|
|
|
66
66
|
|
|
67
67
|
export type QuickCaptureMode = "story" | "inspiration"
|
|
68
68
|
|
|
69
|
+
/** 面板类型 tab:需求/灵感(story/inspiration 共用)、BUG、任务 */
|
|
70
|
+
type QuickCaptureTab = "story" | "bug" | "task"
|
|
71
|
+
|
|
69
72
|
/** 保存成功反馈(已记录 IDENTIFIER)自动清除时长 */
|
|
70
73
|
const FEEDBACK_CLEAR_MS = 1500
|
|
71
74
|
|
|
@@ -109,6 +112,8 @@ export function QuickCapturePanel({ initialMode }: { initialMode: QuickCaptureMo
|
|
|
109
112
|
// 表现为 Enter/Esc 时好时坏)。挂载后再渲染工具栏。
|
|
110
113
|
const [mounted, setMounted] = useState(false)
|
|
111
114
|
const [appVersion, setAppVersion] = useState("")
|
|
115
|
+
// 类型 tab:story = 需求/灵感(本期),bug / task 占位(后续完善)
|
|
116
|
+
const [activeTab, setActiveTab] = useState<QuickCaptureTab>("story")
|
|
112
117
|
|
|
113
118
|
const feedbackTimerRef = useRef<ReturnType<typeof setTimeout> | null>(null)
|
|
114
119
|
// 保存防重:请求在途(标题尚未清空)期间忽略再次提交,防重复落库
|
|
@@ -171,6 +176,8 @@ export function QuickCapturePanel({ initialMode }: { initialMode: QuickCaptureMo
|
|
|
171
176
|
const unsubscribe = bridge?.onMiniPanelMode?.((next) => {
|
|
172
177
|
const pick = pickForMode(next)
|
|
173
178
|
if (pick) setProjectPick(pick)
|
|
179
|
+
// 托盘菜单「快捷记录」→ 始终切回需求/灵感 tab
|
|
180
|
+
setActiveTab("story")
|
|
174
181
|
})
|
|
175
182
|
return () => unsubscribe?.()
|
|
176
183
|
}, [pickForMode])
|
|
@@ -187,19 +194,34 @@ export function QuickCapturePanel({ initialMode }: { initialMode: QuickCaptureMo
|
|
|
187
194
|
setMounted(true)
|
|
188
195
|
}, [])
|
|
189
196
|
|
|
190
|
-
//
|
|
191
|
-
//
|
|
192
|
-
//
|
|
193
|
-
//
|
|
197
|
+
// 焦点管理:面板每次显示/获得焦点时把焦点放到标题框。否则焦点停在第一个
|
|
198
|
+
// 可聚焦元素(顶部图钉按钮)——表现为图钉出现 focus ring、Enter/Esc 落到
|
|
199
|
+
// 按钮上(快捷键像失效)。三重触发覆盖窗口生命周期:
|
|
200
|
+
// ① mount(首次加载);② main 每次 presentPanel 推送 shown(mini 窗口单例
|
|
201
|
+
// 复用、组件不重挂载,mount 只跑一次——这是用户实测「还是落在图钉上」的根因);
|
|
202
|
+
// ③ visibilitychange(窗口 hide→show 的可见性切换兜底)。
|
|
203
|
+
// 用户正在其他输入控件里编辑时不抢焦点。
|
|
194
204
|
useEffect(() => {
|
|
195
205
|
const focusTitle = () => {
|
|
196
|
-
const active = document.activeElement
|
|
197
|
-
|
|
206
|
+
const active = document.activeElement as HTMLElement | null
|
|
207
|
+
const isEditing =
|
|
208
|
+
!!active &&
|
|
209
|
+
(active.tagName === 'INPUT' ||
|
|
210
|
+
active.tagName === 'TEXTAREA' ||
|
|
211
|
+
active.isContentEditable)
|
|
212
|
+
if (isEditing && active !== titleInputRef.current) return
|
|
198
213
|
titleInputRef.current?.focus()
|
|
199
214
|
}
|
|
200
215
|
focusTitle()
|
|
201
216
|
window.addEventListener('focus', focusTitle)
|
|
202
|
-
|
|
217
|
+
document.addEventListener('visibilitychange', focusTitle)
|
|
218
|
+
const bridge = getDesktopBridge()
|
|
219
|
+
const unsubscribe = bridge?.onMiniPanelShown?.(focusTitle)
|
|
220
|
+
return () => {
|
|
221
|
+
window.removeEventListener('focus', focusTitle)
|
|
222
|
+
document.removeEventListener('visibilitychange', focusTitle)
|
|
223
|
+
unsubscribe?.()
|
|
224
|
+
}
|
|
203
225
|
}, [])
|
|
204
226
|
|
|
205
227
|
useEffect(() => {
|
|
@@ -292,20 +314,31 @@ export function QuickCapturePanel({ initialMode }: { initialMode: QuickCaptureMo
|
|
|
292
314
|
}
|
|
293
315
|
|
|
294
316
|
const handlePanelKeyDown = (e: KeyboardEvent<HTMLDivElement>) => {
|
|
295
|
-
if (e.key
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
e.preventDefault()
|
|
299
|
-
const bridge = getDesktopBridge()
|
|
300
|
-
bridge?.window?.("hide")
|
|
301
|
-
}
|
|
302
|
-
|
|
303
|
-
// 标题框 Enter 提交(Shift+Enter 不拦截);描述编辑器内 Enter/Shift+Enter 由 TipTap 换行
|
|
304
|
-
const handleTitleKeyDown = (e: KeyboardEvent<HTMLInputElement>) => {
|
|
305
|
-
if (e.key === "Enter" && !e.shiftKey) {
|
|
317
|
+
if (e.key === "Escape") {
|
|
318
|
+
// 项目 Popover 展开时 Esc 只关 Popover(Base UI 自行处理),不收起整个面板
|
|
319
|
+
if (projectOpen) return
|
|
306
320
|
e.preventDefault()
|
|
307
|
-
|
|
321
|
+
const bridge = getDesktopBridge()
|
|
322
|
+
bridge?.window?.("hide")
|
|
323
|
+
return
|
|
324
|
+
}
|
|
325
|
+
if (e.key !== "Enter") return
|
|
326
|
+
const target = e.target as HTMLElement | null
|
|
327
|
+
// 描述编辑器内:普通 Enter 交给 TipTap 换行,仅 Mod+Enter(⌘/Ctrl)提交
|
|
328
|
+
if (editorWrapRef.current?.contains(target as Node)) {
|
|
329
|
+
if (e.metaKey || e.ctrlKey) {
|
|
330
|
+
e.preventDefault()
|
|
331
|
+
void save()
|
|
332
|
+
}
|
|
333
|
+
return
|
|
308
334
|
}
|
|
335
|
+
// 按钮上的 Enter 交给按钮自身(避免「钉按钮 + 记录」双重动作)
|
|
336
|
+
if (target?.tagName === "BUTTON") return
|
|
337
|
+
// 其余位置(标题框 / 失焦后的面板任意处):Enter 提交(Shift+Enter 不再
|
|
338
|
+
// 作为换行快捷键——描述框内换行直接用 Enter)
|
|
339
|
+
if (e.shiftKey) return
|
|
340
|
+
e.preventDefault()
|
|
341
|
+
void save()
|
|
309
342
|
}
|
|
310
343
|
|
|
311
344
|
const handlePickProject = (pick: ProjectPick) => {
|
|
@@ -315,6 +348,8 @@ export function QuickCapturePanel({ initialMode }: { initialMode: QuickCaptureMo
|
|
|
315
348
|
setExtraLabels([])
|
|
316
349
|
setProjectPick(pick)
|
|
317
350
|
setProjectOpen(false)
|
|
351
|
+
// 托盘菜单/设置菜单的「快捷记录需求/灵感」始终回到需求/灵感 tab
|
|
352
|
+
setActiveTab("story")
|
|
318
353
|
}
|
|
319
354
|
|
|
320
355
|
const togglePinned = () => {
|
|
@@ -403,7 +438,36 @@ export function QuickCapturePanel({ initialMode }: { initialMode: QuickCaptureMo
|
|
|
403
438
|
</div>
|
|
404
439
|
</header>
|
|
405
440
|
|
|
406
|
-
|
|
441
|
+
{/* 类型 tab:需求/灵感(本期)、BUG / 任务(占位,后续完善) */}
|
|
442
|
+
<div className="flex items-center gap-1 border-b border-border px-2 py-1.5">
|
|
443
|
+
<Button
|
|
444
|
+
type="button"
|
|
445
|
+
size="sm"
|
|
446
|
+
variant={activeTab === "story" ? "secondary" : "ghost"}
|
|
447
|
+
onClick={() => setActiveTab("story")}
|
|
448
|
+
>
|
|
449
|
+
{m.quick_capture_tabUnified()}
|
|
450
|
+
</Button>
|
|
451
|
+
<Button
|
|
452
|
+
type="button"
|
|
453
|
+
size="sm"
|
|
454
|
+
variant={activeTab === "bug" ? "secondary" : "ghost"}
|
|
455
|
+
onClick={() => setActiveTab("bug")}
|
|
456
|
+
>
|
|
457
|
+
{m.quick_capture_tabBug()}
|
|
458
|
+
</Button>
|
|
459
|
+
<Button
|
|
460
|
+
type="button"
|
|
461
|
+
size="sm"
|
|
462
|
+
variant={activeTab === "task" ? "secondary" : "ghost"}
|
|
463
|
+
onClick={() => setActiveTab("task")}
|
|
464
|
+
>
|
|
465
|
+
{m.quick_capture_tabTask()}
|
|
466
|
+
</Button>
|
|
467
|
+
</div>
|
|
468
|
+
|
|
469
|
+
{activeTab === "story" ? (
|
|
470
|
+
<div className="flex-1 space-y-3 overflow-y-auto p-3">
|
|
407
471
|
<Popover open={projectOpen} onOpenChange={setProjectOpen}>
|
|
408
472
|
<PopoverTrigger
|
|
409
473
|
render={
|
|
@@ -468,7 +532,6 @@ export function QuickCapturePanel({ initialMode }: { initialMode: QuickCaptureMo
|
|
|
468
532
|
ref={titleInputRef}
|
|
469
533
|
value={name}
|
|
470
534
|
onChange={(e) => setName(e.target.value)}
|
|
471
|
-
onKeyDown={handleTitleKeyDown}
|
|
472
535
|
placeholder={m.story_column_title()}
|
|
473
536
|
maxLength={200}
|
|
474
537
|
className="h-10 text-base md:text-lg"
|
|
@@ -552,7 +615,13 @@ export function QuickCapturePanel({ initialMode }: { initialMode: QuickCaptureMo
|
|
|
552
615
|
/>
|
|
553
616
|
</div>
|
|
554
617
|
</div>
|
|
618
|
+
) : (
|
|
619
|
+
<div className="flex flex-1 items-center justify-center p-4 text-center text-sm text-muted-foreground">
|
|
620
|
+
{m.quick_capture_comingSoon()}
|
|
621
|
+
</div>
|
|
622
|
+
)}
|
|
555
623
|
|
|
624
|
+
{activeTab === "story" && (
|
|
556
625
|
<footer className="space-y-1.5 border-t border-border p-2">
|
|
557
626
|
<Button
|
|
558
627
|
type="button"
|
|
@@ -568,6 +637,7 @@ export function QuickCapturePanel({ initialMode }: { initialMode: QuickCaptureMo
|
|
|
568
637
|
: m.quick_capture_hint()}
|
|
569
638
|
</div>
|
|
570
639
|
</footer>
|
|
640
|
+
)}
|
|
571
641
|
</div>
|
|
572
642
|
)
|
|
573
643
|
}
|
|
@@ -112,7 +112,7 @@ export const SDK_GROUPS: SdkGroup[] = [
|
|
|
112
112
|
"items": [
|
|
113
113
|
{
|
|
114
114
|
"name": "@allbluecn/web-app",
|
|
115
|
-
"version": "v0.27.
|
|
115
|
+
"version": "v0.27.6",
|
|
116
116
|
"lastUpdate": "Nov 5, 2026",
|
|
117
117
|
"source": "apps/web/package.json",
|
|
118
118
|
"docsUrl": "https://github.com/allbluecn/allblue"
|
|
@@ -110,6 +110,10 @@ export interface DesktopBridgeApi {
|
|
|
110
110
|
setMiniPanelPinned?: (pinned: boolean) => void
|
|
111
111
|
onMiniPanelPinned?: (cb: (pinned: boolean) => void) => () => void
|
|
112
112
|
popUpTrayMenu?: () => void
|
|
113
|
+
/** mini 面板每次显示(presentPanel)推送的**无参信号**:面板窗口单例复用、
|
|
114
|
+
* 组件不重挂载,渲染端据此重新聚焦标题框(否则 mini 窗口重新打开后焦点
|
|
115
|
+
* 仍停在最后一个聚焦元素/图钉按钮上)。订阅返回 unsubscribe。 */
|
|
116
|
+
onMiniPanelShown?: (cb: () => void) => () => void
|
|
113
117
|
/** mini 面板设置菜单(2026-11-05 追加,add-only):
|
|
114
118
|
* - openMainWindow:打开/前置主窗(菜单项「打开 AllBlue」);
|
|
115
119
|
* - quitApp:退出应用(菜单项「退出 AllBlue」,复用 before-quit 清理链)。
|
|
@@ -3547,6 +3547,7 @@ export * from './prototypepanel_mobile1.js'
|
|
|
3547
3547
|
export * from './prototypepanel_saving1.js'
|
|
3548
3548
|
export * from './prototypepanel_tablet1.js'
|
|
3549
3549
|
export * from './prototypepanel_title1.js'
|
|
3550
|
+
export * from './quick_capture_comingsoon1.js'
|
|
3550
3551
|
export * from './quick_capture_failed.js'
|
|
3551
3552
|
export * from './quick_capture_hint.js'
|
|
3552
3553
|
export * from './quick_capture_inbox.js'
|
|
@@ -3559,6 +3560,8 @@ export * from './quick_capture_quit.js'
|
|
|
3559
3560
|
export * from './quick_capture_saved.js'
|
|
3560
3561
|
export * from './quick_capture_settings.js'
|
|
3561
3562
|
export * from './quick_capture_submit.js'
|
|
3563
|
+
export * from './quick_capture_tabbug1.js'
|
|
3564
|
+
export * from './quick_capture_tabtask1.js'
|
|
3562
3565
|
export * from './quick_capture_tabunified1.js'
|
|
3563
3566
|
export * from './rightsidebar_collapse1.js'
|
|
3564
3567
|
export * from './rightsidebar_expand1.js'
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
/* eslint-disable */
|
|
2
|
+
import { getLocale, experimentalStaticLocale } from '../runtime.js';
|
|
3
|
+
|
|
4
|
+
/** @typedef {import('../runtime.js').LocalizedString} LocalizedString */
|
|
5
|
+
|
|
6
|
+
/** @typedef {{}} Quick_Capture_Comingsoon1Inputs */
|
|
7
|
+
|
|
8
|
+
const zh_quick_capture_comingsoon1 = /** @type {(inputs: Quick_Capture_Comingsoon1Inputs) => LocalizedString} */ () => {
|
|
9
|
+
return /** @type {LocalizedString} */ (`该类型记录即将上线,敬请期待`)
|
|
10
|
+
};
|
|
11
|
+
|
|
12
|
+
const en_quick_capture_comingsoon1 = /** @type {(inputs: Quick_Capture_Comingsoon1Inputs) => LocalizedString} */ () => {
|
|
13
|
+
return /** @type {LocalizedString} */ (`This record type is coming soon`)
|
|
14
|
+
};
|
|
15
|
+
|
|
16
|
+
/**
|
|
17
|
+
* | output |
|
|
18
|
+
* | --- |
|
|
19
|
+
* | "This record type is coming soon" |
|
|
20
|
+
*
|
|
21
|
+
* @param {Quick_Capture_Comingsoon1Inputs} inputs
|
|
22
|
+
* @param {{ locale?: "zh" | "en" }} options
|
|
23
|
+
* @returns {LocalizedString}
|
|
24
|
+
*/
|
|
25
|
+
const quick_capture_comingsoon1 = /** @type {((inputs?: Quick_Capture_Comingsoon1Inputs, options?: { locale?: "zh" | "en" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Quick_Capture_Comingsoon1Inputs, { locale?: "zh" | "en" }, {}>} */ ((inputs = {}, options = {}) => {
|
|
26
|
+
const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
|
|
27
|
+
if (locale === "en") return en_quick_capture_comingsoon1(inputs)
|
|
28
|
+
return zh_quick_capture_comingsoon1(inputs)
|
|
29
|
+
});
|
|
30
|
+
export { quick_capture_comingsoon1 as "quick_capture_comingSoon" }
|
|
@@ -6,17 +6,17 @@ import { getLocale, experimentalStaticLocale } from '../runtime.js';
|
|
|
6
6
|
/** @typedef {{}} Quick_Capture_HintInputs */
|
|
7
7
|
|
|
8
8
|
const zh_quick_capture_hint = /** @type {(inputs: Quick_Capture_HintInputs) => LocalizedString} */ () => {
|
|
9
|
-
return /** @type {LocalizedString} */ (`Enter 记录 ·
|
|
9
|
+
return /** @type {LocalizedString} */ (`Enter 记录 · ⌘+Enter 编辑区提交 · Esc 关闭`)
|
|
10
10
|
};
|
|
11
11
|
|
|
12
12
|
const en_quick_capture_hint = /** @type {(inputs: Quick_Capture_HintInputs) => LocalizedString} */ () => {
|
|
13
|
-
return /** @type {LocalizedString} */ (`Enter to save ·
|
|
13
|
+
return /** @type {LocalizedString} */ (`Enter to save · ⌘+Enter in editor · Esc to close`)
|
|
14
14
|
};
|
|
15
15
|
|
|
16
16
|
/**
|
|
17
17
|
* | output |
|
|
18
18
|
* | --- |
|
|
19
|
-
* | "Enter to save ·
|
|
19
|
+
* | "Enter to save · ⌘+Enter in editor · Esc to close" |
|
|
20
20
|
*
|
|
21
21
|
* @param {Quick_Capture_HintInputs} inputs
|
|
22
22
|
* @param {{ locale?: "zh" | "en" }} options
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
/* eslint-disable */
|
|
2
|
+
import { getLocale, experimentalStaticLocale } from '../runtime.js';
|
|
3
|
+
|
|
4
|
+
/** @typedef {import('../runtime.js').LocalizedString} LocalizedString */
|
|
5
|
+
|
|
6
|
+
/** @typedef {{}} Quick_Capture_Tabbug1Inputs */
|
|
7
|
+
|
|
8
|
+
const zh_quick_capture_tabbug1 = /** @type {(inputs: Quick_Capture_Tabbug1Inputs) => LocalizedString} */ () => {
|
|
9
|
+
return /** @type {LocalizedString} */ (`BUG`)
|
|
10
|
+
};
|
|
11
|
+
|
|
12
|
+
const en_quick_capture_tabbug1 = /** @type {(inputs: Quick_Capture_Tabbug1Inputs) => LocalizedString} */ () => {
|
|
13
|
+
return /** @type {LocalizedString} */ (`Bug`)
|
|
14
|
+
};
|
|
15
|
+
|
|
16
|
+
/**
|
|
17
|
+
* | output |
|
|
18
|
+
* | --- |
|
|
19
|
+
* | "Bug" |
|
|
20
|
+
*
|
|
21
|
+
* @param {Quick_Capture_Tabbug1Inputs} inputs
|
|
22
|
+
* @param {{ locale?: "zh" | "en" }} options
|
|
23
|
+
* @returns {LocalizedString}
|
|
24
|
+
*/
|
|
25
|
+
const quick_capture_tabbug1 = /** @type {((inputs?: Quick_Capture_Tabbug1Inputs, options?: { locale?: "zh" | "en" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Quick_Capture_Tabbug1Inputs, { locale?: "zh" | "en" }, {}>} */ ((inputs = {}, options = {}) => {
|
|
26
|
+
const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
|
|
27
|
+
if (locale === "en") return en_quick_capture_tabbug1(inputs)
|
|
28
|
+
return zh_quick_capture_tabbug1(inputs)
|
|
29
|
+
});
|
|
30
|
+
export { quick_capture_tabbug1 as "quick_capture_tabBug" }
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
/* eslint-disable */
|
|
2
|
+
import { getLocale, experimentalStaticLocale } from '../runtime.js';
|
|
3
|
+
|
|
4
|
+
/** @typedef {import('../runtime.js').LocalizedString} LocalizedString */
|
|
5
|
+
|
|
6
|
+
/** @typedef {{}} Quick_Capture_Tabtask1Inputs */
|
|
7
|
+
|
|
8
|
+
const zh_quick_capture_tabtask1 = /** @type {(inputs: Quick_Capture_Tabtask1Inputs) => LocalizedString} */ () => {
|
|
9
|
+
return /** @type {LocalizedString} */ (`任务`)
|
|
10
|
+
};
|
|
11
|
+
|
|
12
|
+
const en_quick_capture_tabtask1 = /** @type {(inputs: Quick_Capture_Tabtask1Inputs) => LocalizedString} */ () => {
|
|
13
|
+
return /** @type {LocalizedString} */ (`Task`)
|
|
14
|
+
};
|
|
15
|
+
|
|
16
|
+
/**
|
|
17
|
+
* | output |
|
|
18
|
+
* | --- |
|
|
19
|
+
* | "Task" |
|
|
20
|
+
*
|
|
21
|
+
* @param {Quick_Capture_Tabtask1Inputs} inputs
|
|
22
|
+
* @param {{ locale?: "zh" | "en" }} options
|
|
23
|
+
* @returns {LocalizedString}
|
|
24
|
+
*/
|
|
25
|
+
const quick_capture_tabtask1 = /** @type {((inputs?: Quick_Capture_Tabtask1Inputs, options?: { locale?: "zh" | "en" }) => LocalizedString) & import('../runtime.js').MessageMetadata<Quick_Capture_Tabtask1Inputs, { locale?: "zh" | "en" }, {}>} */ ((inputs = {}, options = {}) => {
|
|
26
|
+
const locale = experimentalStaticLocale ?? options.locale ?? getLocale()
|
|
27
|
+
if (locale === "en") return en_quick_capture_tabtask1(inputs)
|
|
28
|
+
return zh_quick_capture_tabtask1(inputs)
|
|
29
|
+
});
|
|
30
|
+
export { quick_capture_tabtask1 as "quick_capture_tabTask" }
|