mirror of
https://github.com/labring/FastGPT.git
synced 2026-05-07 01:02:55 +08:00
3df8908851
* style: re-component Editor * style: re-component Editor * feat: sandbox file preview support with binary detection and mime type handling * feat: preview support for markdown, svg, and html files in sandbox editor * feat(sandbox): support multimedia preview and source/preview toggle in editor * fix: XSS SVG rendering with MyPhotoView * refactor: blob URL lifecycle management, improve filename encoding in downloads * feat: implement S3-based HTML preview for sandbox editor and add PDF support to binary file detection * refactor: improve sandbox editor stability by adding file size validation * feat: introduce fileService to encapsulate sandbox file operations and add unit tests * refactor: secure HTML sandbox preview by fetching content from server and injecting CSP meta tags * refactor: replace unified file operation API with dedicated endpoints for list, read, write, and download operations * chore: remove packageManager field from package.json * fix: sandbox file read error message * refactor: improve sandbox editor UI styling, type safety, and CSP security policy * feat: HTML preview link API and standardize sandbox request/response types * fix: improve log view layout responsiveness by adding overflow handling and flex constraints * perf: fix review --------- Co-authored-by: archer <545436317@qq.com>
58 lines
1.9 KiB
JSON
58 lines
1.9 KiB
JSON
{
|
|
"name": "fastgpt",
|
|
"version": "4.0",
|
|
"private": true,
|
|
"scripts": {
|
|
"prepare": "husky install",
|
|
"format-code": "prettier --config \"./.prettierrc.js\" --write \"./**/src/**/*.{ts,tsx,scss}\"",
|
|
"format-doc": "zhlint --dir ./document/ *.mdx --fix",
|
|
"initDocTime": "node ./document/script/initDocTime.js",
|
|
"initDocToc": "node ./document/lib/generateToc.js",
|
|
"gen:theme-typings": "chakra-cli tokens packages/web/styles/theme.ts --out node_modules/.pnpm/node_modules/@chakra-ui/styled-system/dist/theming.types.d.ts",
|
|
"gen:deploy": "node deploy/init.mjs",
|
|
"postinstall": "pnpm gen:theme-typings",
|
|
"initIcon": "node ./scripts/icon/init.js && prettier --config \"./.prettierrc.js\" --write \"packages/web/components/common/Icon/constants.ts\"",
|
|
"previewIcon": "node ./scripts/icon/index.js",
|
|
"create:i18n": "node ./scripts/i18n/index.js",
|
|
"lint": "eslint \"**/*.{ts,tsx}\" --fix --ignore-path .eslintignore",
|
|
"test": "vitest run --coverage",
|
|
"test:vector": "vitest run --config test/integrationTest/vectorDB/vitest.config.mts"
|
|
},
|
|
"devDependencies": {
|
|
"@chakra-ui/cli": "^2.4.1",
|
|
"@typescript-eslint/eslint-plugin": "^6.21.0",
|
|
"@typescript-eslint/parser": "^6.21.0",
|
|
"@vitest/coverage-v8": "^3.0.9",
|
|
"eslint": "catalog:",
|
|
"eslint-config-next": "catalog:",
|
|
"husky": "^8.0.3",
|
|
"i18next": "catalog:",
|
|
"js-yaml": "catalog:",
|
|
"lint-staged": "^13.3.0",
|
|
"mongodb-memory-server": "^10.1.4",
|
|
"next-i18next": "catalog:",
|
|
"prettier": "3.2.4",
|
|
"react-i18next": "catalog:",
|
|
"typescript": "^5.1.3",
|
|
"vitest": "^3.0.9",
|
|
"zhlint": "^0.7.4"
|
|
},
|
|
"lint-staged": {
|
|
"./**/**/*.{ts,tsx,scss}": [
|
|
"pnpm format-code"
|
|
],
|
|
"./**/**/*.{ts,tsx}": [
|
|
"pnpm lint"
|
|
],
|
|
"./document/**/**/*.mdx": [
|
|
"pnpm format-doc",
|
|
"pnpm initDocTime",
|
|
"pnpm initDocToc",
|
|
"git add ."
|
|
]
|
|
},
|
|
"engines": {
|
|
"node": ">=20",
|
|
"pnpm": "9.x"
|
|
}
|
|
} |