Files
FastapiAdmin/frontend/web/src/env.d.ts
T
zhangtao 096fa8e6da refactor: 清理无用导入、重构组件路径与统一依赖导入
1.  移除 .prettierignore 和 tsconfig.json 中对 src/types/import/ 的配置
2.  全局替换 @/utils/message 导入为直接从 element-plus 导入组件
3.  移动并统一组件路径:将 widget/fa-icon-button 迁移至 others/fa-icon-button
4.  新增多环境配置示例文件与docker部署配置
5.  补充类型导入与类型文件统一导出
6.  修复卡片样式与布局细节问题
7.  移除过时的 initIconify 同步初始化函数
2026-07-24 02:03:07 +08:00

107 lines
2.3 KiB
TypeScript
Executable File
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" />
/// <reference types="element-plus/global" />
// https://cn.vitejs.dev/guide/env-and-mode
// TypeScript 类型提示都为 string: https://github.com/vitejs/vite/issues/6930
interface ImportMetaEnv {
/** 环境标识 */
VITE_APP_ENV: string;
/** 项目名称 */
VITE_APP_TITLE: string;
/** API 请求基础路径 */
VITE_API_URL: string;
/** 开发环境代理目标地址 */
VITE_API_BASE_URL: string;
/** 代理前缀 */
VITE_APP_BASE_API: string;
/** 开发服务器端口 */
VITE_PORT: number;
/** 网络请求超时时间(毫秒) */
VITE_API_TIMEOUT: number;
/** WebSocket 端点 */
VITE_APP_WS_ENDPOINT: string;
/** 应用部署基础路径 */
VITE_BASE_URL: string;
/** 权限模式 */
VITE_ACCESS_MODE: string;
/** 跨域请求是否携带 Cookie */
VITE_WITH_CREDENTIALS: string;
/** 是否在控制台输出路由信息 */
VITE_OPEN_ROUTE_INFO: string;
/** 锁屏加密密钥 */
VITE_LOCK_ENCRYPT_KEY: string;
/** 是否删除控制台输出 */
VITE_DROP_CONSOLE: string;
/** 应用版本号 */
VITE_VERSION: string;
}
// Vite 环境变量类型提示
interface ImportMeta {
readonly env: ImportMetaEnv;
}
// 平台的名称、版本、运行所需的`node`版本、依赖、构建时间的类型提示
declare const __APP_INFO__: {
pkg: {
name: string;
version: string;
engines: {
node: string;
};
dependencies: Record<string, string>;
devDependencies: Record<string, string>;
};
buildTimestamp: number;
};
// 进度条类型提示
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;
}