Files
photo-live/apps/admin/src/env.d.ts
T
浅念 0238f505c4 feat(admin): embed slot management with code snippet
P4b Task 5:/system/embed-slots 管理页(Task 8/9 页面模式:useCursorList
游标累积 + 对话框治理)。列表(名称/绑定相册/启停/configVersion/更新时间,
启停开关行内 PATCH → configVersion+1 toast 提示)+ 新建/编辑对话框
(设置表单位置/尺寸/间隔/语言/默认收起,intervalMs 契约区间夹取;编辑按
整体替换语义提交完整 settings)+ 绑定相册对话框(相册标题/ID 搜索选中 →
确认框携带 A22 文案「configVersion 将递增,官网无需改动」;清空即解绑)+
嵌入代码卡({EMBED_ORIGIN}/embed/v1/loader.js + data-slot 令牌,一键复制;
EMBED_ORIGIN=VITE_EMBED_ORIGIN 缺省本机 viewer dev,.env.example 登记)。

- API 层 src/api/embedSlots.ts + types/api/embedSlot.d.ts(契约镜像)
- vitest 9 例:表单→载荷(缺省+夹取)、编辑载荷收敛、snippet 拼接、
  环境基址兜底、绑定变更分类、zh/en 键一致 + A22 短语断言
- Playwright e2e(真实 cn+ov 后端):新建→绑定(gov-photos 直种 +
  seed-fixture 新增 sync-flush 模式经 bootstrap/真实发送管线投影 photos_ov)
  →嵌入代码卡含 token→ov 公开 feed 返回相册照片→换绑 configVersion+1 +
  feed 切换(A22)→停用 feed 404;admin playwright 配置补 ov webServer
- i18n zh/en(embedSlotsManage.* + menus.system.embedSlots)

Co-Authored-By: Claude Code <noreply@anthropic.com>
2026-09-20 23:25:59 +08:00

47 lines
1.1 KiB
TypeScript
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
/// <reference types="vite/client" />
// Vite 环境变量类型增补(vite/client 的 ImportMetaEnv 声明合并)
interface ImportMetaEnv {
/** viewer 部署基址(分享链接卡;缺省兜底 http://127.0.0.1:5175) */
readonly VITE_VIEWER_BASE?: string
/** 嵌入组件部署基址(展示位嵌入代码卡;缺省兜底同 viewer dev 5175) */
readonly VITE_EMBED_ORIGIN?: string
}
interface ImportMeta {
readonly env: ImportMetaEnv
}
declare module 'nprogress'
declare module 'crypto-js'
declare module 'vue-img-cutter'
declare module 'file-saver'
declare module 'qrcode.vue' {
export type Level = 'L' | 'M' | 'Q' | 'H'
export type RenderAs = 'canvas' | 'svg'
export type GradientType = 'linear' | 'radial'
export interface ImageSettings {
src: string
height: number
width: number
excavate: boolean
}
export interface QRCodeProps {
value: string
size?: number
level?: Level
background?: string
foreground?: string
renderAs?: RenderAs
}
const QrcodeVue: any
export default QrcodeVue
}
// 全局变量声明
declare const __APP_VERSION__: string // 版本号