Compare commits

..
Author SHA1 Message Date
Nikita Veselov 839b6337d4 build: vendor UI kit 3.0.0 for React 19 alpha testing 2026-11-30 15:16:24 +03:00
11 changed files with 4411 additions and 593 deletions

No files matched your search

+2 -1
View File
@@ -26,7 +26,8 @@
},
"ecmaVersion": "latest",
"sourceType": "module",
"project": "./tsconfig.json"
"project": "./tsconfig.json",
"tsconfigRootDir": "./"
},
"plugins": [
"react",
-3
View File
@@ -9,9 +9,6 @@
- Устранены уязвимости зависимостей библиотеки, обновлены Storybook и React Router, закреплены исправленные версии DOMPurify, KaTeX и инструментов разработки
- Исправлена работа браузерного парсера JSON Schema в JSONViewer: добавлен минимальный полифил Buffer
- Библиотека react-router-dom (7.18.7) для совместимости с isp-admin-ui-kit
- Исправлено
- устранены уязвимости зависимостей по результатам аудита, обновлены Vite и React Router, закреплены исправленные версии вложенных пакетов.
- сохранена работа Monaco, Mermaid, ReDoc и JSON Schema с минимальными браузерными полифилами; добавлена проверка совместимости зависимостей.
## 1.0.15
- Обновлено
+2
View File
@@ -5,6 +5,8 @@ WORKDIR /usr/src/app
FROM base as deps
COPY vendor/ ./vendor/
RUN --mount=type=bind,source=package.json,target=package.json \
--mount=type=bind,source=package-lock.json,target=package-lock.json \
--mount=type=cache,target=/root/.npm \
+1 -17
View File
@@ -28,20 +28,4 @@ export default {
- Replace `plugin:@typescript-eslint/recommended` to `plugin:@typescript-eslint/recommended-type-checked` or `plugin:@typescript-eslint/strict-type-checked`
- Optionally add `plugin:@typescript-eslint/stylistic-type-checked`
- Install [eslint-plugin-react](https://github.com/jsx-eslint/eslint-plugin-react) and add `plugin:react/recommended` & `plugin:react/jsx-runtime` to the `extends` list
1
### Проверка совместимости зависимостей
После обновления зависимостей выполните `npm ci`, `npm run lint`, `npm run build`
и `npm run test:dependencies`. Последняя команда собирает отдельную проверочную
страницу. Запустите `npm run preview -- --outDir build/dependency-smoke --port 4174`
и откройте `http://localhost:4174/tests/dependency-smoke.html`.
Успешный результат — `Dependency checks passed`. Проверяются DOMPurify, Mermaid
(включая формулы), KaTeX, JSON Schema/RJSF, ReDoc, Router и JSON worker Monaco.
Страница проверки не входит в основную production-сборку.
В `overrides` закреплены исправленные DOMPurify и KaTeX без обновления Monaco и
Mermaid на новые основные версии. Overrides minimatch/glob относятся к инструментам
разработки. Библиотека `isp-admin-ui-kit` поддерживает Router 7.
React остаётся в ветке 18. Вместо всех Node-полифилов подключаются только Buffer/process и браузерные реализации path/http/url,
необходимые парсерам JSON Schema/OpenAPI и ReDoc. Криптографические полифилы удалены.
1
+4362 -522
View File
File diff suppressed because it is too large. Load diff
+23 -26
View File
@@ -11,42 +11,39 @@
"fix:prettier": "prettier --write \"src/**/*.{ts,tsx, js}\"",
"lint:fix": "eslint --fix .",
"analyze": "source-map-explorer 'build/static/js/*.js'",
"prepare": "husky || true",
"test:dependencies": "vite build --config tests/dependency-smoke.config.ts"
"prepare": "husky || true"
},
"dependencies": {
"@monaco-editor/react": "^4.6.0",
"@reduxjs/toolkit": "^2.2.3",
"@monaco-editor/react": "^4.7.0",
"@reduxjs/toolkit": "^2.12.0",
"axios": "^1.20.0",
"buffer": "^6.0.3",
"dayjs": "^1.11.10",
"isp-admin-ui-kit": "^1.16.0",
"isp-ui-kit": "^2.3.3",
"dayjs": "^1.11.21",
"isp-admin-ui-kit": "file:vendor/isp-admin-ui-kit-3.0.0.tgz",
"isp-ui-kit": "^3.0.0",
"monaco-editor": "^0.55.1",
"path-browserify": "^1.0.1",
"process": "^0.11.10",
"react": "^18.2.0",
"react-dom": "^18.2.0",
"react-hook-form": "^7.51.2",
"react-redux": "^9.1.0",
"react-resizable": "^3.0.5",
"react-router-dom": "^7.18.7",
"react": "^19.3.1",
"react-dom": "^19.3.1",
"react-hook-form": "^7.78.0",
"react-redux": "^9.3.0",
"react-resizable": "^4.0.1",
"react-router-dom": "^7.18.6",
"simplebar": "^6.2.5",
"simplebar-react": "^3.2.4",
"stream-http": "^3.2.0",
"url": "^0.11.4"
"simplebar-react": "^3.2.4"
},
"devDependencies": {
"@trivago/prettier-plugin-sort-imports": "^4.3.0",
"@types/deep-equal": "^1.0.4",
"@types/lodash.clonedeep": "^4.5.9",
"@types/node": "^20.12.4",
"@types/react": "^18.2.74",
"@types/react-dom": "^18.2.24",
"@types/react": "^19.3.3",
"@types/react-dom": "^19.3.0",
"@types/react-resizable": "^3.0.7",
"@typescript-eslint/eslint-plugin": "^8.74.0",
"@typescript-eslint/parser": "^8.74.0",
"@types/react-router-dom": "^5.3.3",
"@typescript-eslint/eslint-plugin": "^7.5.0",
"@typescript-eslint/parser": "^7.5.0",
"@vitejs/plugin-legacy": "^5.3.2",
"@vitejs/plugin-react": "^4.2.1",
"@vitejs/plugin-react-swc": "^3.6.0",
"antd": "6.4.3",
"eslint": "^8.57.0",
"eslint-config-prettier": "^9.1.0",
@@ -61,8 +58,9 @@
"sass": "1.74.1",
"terser": "^5.30.3",
"typescript": "^5.4.3",
"vite": "^6.4.6",
"vite": "^5.4.10",
"vite-bundle-visualizer": "^1.2.1",
"vite-plugin-node-polyfills": "^0.21.0",
"vite-plugin-style-import": "^2.0.0",
"vite-plugin-svgr": "^4.2.0",
"vite-tsconfig-paths": "^4.3.2"
@@ -83,7 +81,6 @@
"dompurify": "~3.4.18",
"katex": "~0.18.2",
"minimatch@>=7 <11": "^11.0.1",
"glob@>=9 <14.0.2": "^14.0.2",
"react-router-dom": "$react-router-dom"
"glob@>=9 <14.0.2": "^14.0.2"
}
}
-11
View File
@@ -1,11 +0,0 @@
import { Buffer } from 'buffer'
import process from 'process'
// OpenAPI/JSON Schema browser builds still use these Node globals.
// Load only the required shims, without Node's crypto modules.
if (typeof globalThis.Buffer === 'undefined') {
Object.assign(globalThis, { Buffer })
}
if (typeof globalThis.process === 'undefined') {
Object.assign(globalThis, { process })
}
+2 -4
View File
@@ -1,8 +1,6 @@
import './browser-polyfills'
import { loader } from '@monaco-editor/react'
import { setupListeners } from '@reduxjs/toolkit/query'
import { locale } from 'dayjs'
import dayjs from 'dayjs'
import 'dayjs/locale/ru'
import { AdminBase, baseSetupStore } from 'isp-admin-ui-kit'
import * as monaco from 'monaco-editor'
@@ -40,7 +38,7 @@ loader.config({ monaco })
loader.init().then()
locale('ru')
dayjs.locale('ru')
const store = baseSetupStore()
setupListeners(store.dispatch)
const root = createRoot(document.getElementById('root') as HTMLElement)
+12
View File
@@ -0,0 +1,12 @@
# Admin UI kit alpha package
- Package: `isp-admin-ui-kit@3.0.0`
- Source branch: `redesign-form-saving`
- Source commit: `2a39e7b4b38ebbca7d97f509b8c032251e298f9f`
- SHA-256: `09de5669110a47f91593e5652b4b33f6ec1256be8755611c7f8d4c79fd1737ac`
Built with `npm run build:prod` and `npm pack`. The archive contains production CJS/ESM bundles and TypeScript declarations, without source maps or test fixtures.
Install using `npm ci` from the application root. `package.json` and `package-lock.json` pin the archive in this directory. Docker copies `vendor/` before installing dependencies.
To return to a published release, install the desired registry version of `isp-admin-ui-kit` and regenerate the lock-file.
Binary file not shown.
+7 -9
View File
@@ -1,5 +1,6 @@
import react from '@vitejs/plugin-react'
import { defineConfig, loadEnv } from 'vite'
import { nodePolyfills } from 'vite-plugin-node-polyfills'
import svgr from 'vite-plugin-svgr'
import tsconfigPaths from 'vite-tsconfig-paths'
@@ -11,14 +12,6 @@ export default defineConfig(({ mode }) => {
return {
base: env.PUBLIC_PATH || '/',
optimizeDeps: { exclude: [] },
resolve: {
alias: {
path: 'path-browserify',
http: 'stream-http',
url: 'url/',
process: 'process/browser'
}
},
define: {
__APP_ENV__: env.APP_ENV,
APP_VERSION: JSON.stringify(process.env.npm_package_version)
@@ -45,6 +38,11 @@ export default defineConfig(({ mode }) => {
'/api': env.PROXY_URL
}
},
plugins: [react(), svgr(), tsconfigPaths()]
plugins: [
react(),
svgr(),
tsconfigPaths(),
nodePolyfills({ globals: { process: true } })
]
}
})