mirror of
https://github.com/kerberos-io/agent.git
synced 2026-11-21 22:50:39 +00:00
* ui: migrate from Create React App to Vite
react-scripts 5 is unmaintained and pins vulnerable versions of
webpack-dev-server, webpack-dev-middleware, postcss 7 and svgo.
- build and dev server: Vite 8 with @vitejs/plugin-react
- tests: Vitest 4 with jsdom (jest.* -> vi.*; mocked default exports
now return { default })
- index.html moves to ui/ and loads src/index.jsx as a module
- REACT_APP_ENVIRONMENT is replaced by import.meta.env.PROD/MODE, and
REACT_APP_AGENT_API_PORT is renamed to VITE_AGENT_API_PORT
- bundled output goes to static/ so it does not mix with public/assets
- package.json is not "type": "module": that would switch CommonJS
interop to Node semantics and break default imports such as
@giantmachines/redux-websocket
- sass 1.54 -> 1.108 (Vite needs the modern compiler API); sass-loader
removed
- requires Node >= 20.19
`yarn build` still writes to machinery/www, so the Dockerfile and CI
workflow are unchanged.
Clears the remaining 9 react-scripts Dependabot alerts. Five alerts for
svgo 1 and decode-uri-component 0.2 remain; they come from build-tool
dependencies of @kerberos-io/ui and are not part of the bundle.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* ui: vendor @kerberos-io/ui 1.77.1 to clear the last Dependabot alerts
@kerberos-io/ui 1.77.1 moves its build tools (@svgr/webpack,
svg-react-loader, sass-loader, Storybook, Rollup plugins) out of its
runtime dependencies. Those pulled svgo 1 and decode-uri-component 0.2
into the agent's lockfile.
1.77.1 is tagged on GitHub but was never published to npm, so install
it from a tarball built from kerberos-io/ui@ae1faa7 (tag v1.77.1) and
committed under ui/vendor. Compared with the published 1.77.0 the
exports are identical; the only code change is the bundled uuid (8 -> 11).
The Dockerfile copies ui/vendor before `yarn --frozen-lockfile`.
ui/vendor/README.md records the checksum and how to switch back to the
registry once a fixed version is published.
Clears the remaining 5 Dependabot alerts (svgo, decode-uri-component).
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* ui: install @kerberos-io/ui 1.77.1 from its GitHub release
Replace the vendored tarball with the one attached to the kerberos-io/ui
v1.77.1 GitHub release, as uug-ai/factory already does. That tarball is
built by the ui repo's release workflow and ships with a .sha256 file
(e9f94f44...); yarn.lock pins it by hash.
Its JS is identical to the locally built tarball, and its CSS differs
only in selector order within @extend-generated rules.
This removes ui/vendor and the extra COPY line in the Dockerfile.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* ui: address lint findings in the Vite migration
- vite.config.mjs: disable import/no-unresolved; eslint-plugin-import 2.x
cannot resolve packages that only define "exports" (vite, plugin-react)
- ui/README.md: turn the scripts table into a list to keep lines short
- README.md: wrap the edited UI paragraph
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
74 lines
2.1 KiB
JSON
74 lines
2.1 KiB
JSON
{
|
|
"name": "agent-ui",
|
|
"version": "0.1.0",
|
|
"engines": {
|
|
"node": ">=20.19.0"
|
|
},
|
|
"dependencies": {
|
|
"@giantmachines/redux-websocket": "^1.5.1",
|
|
"@kerberos-io/ui": "https://github.com/kerberos-io/ui/releases/download/v1.77.1/kerberos-io-ui-1.77.1.tgz",
|
|
"@material-ui/core": "^4.12.4",
|
|
"@material-ui/icons": "^4.11.3",
|
|
"@testing-library/jest-dom": "^5.16.5",
|
|
"@testing-library/react": "^11.2.7",
|
|
"@testing-library/user-event": "^12.8.3",
|
|
"axios": "^0.33.0",
|
|
"classnames": "^2.3.1",
|
|
"connected-react-router": "^6.9.3",
|
|
"eslint-config-prettier": "8.5.*",
|
|
"eslint-plugin-prettier": "4.2.*",
|
|
"eslint-watch": "^7.0.0",
|
|
"history": "4.10.1",
|
|
"i18next": "^21.9.1",
|
|
"i18next-browser-languagedetector": "^6.1.5",
|
|
"i18next-xhr-backend": "^3.2.2",
|
|
"md5": "^2.3.0",
|
|
"prettier": "^2.7.1",
|
|
"prop-types": "^15.8.1",
|
|
"react": "^17.0.1",
|
|
"react-dom": "^17.0.2",
|
|
"react-i18next": "^11.18.5",
|
|
"react-redux": "^7.2.8",
|
|
"react-router": "^5.2.0",
|
|
"react-router-dom": "^5.3.3",
|
|
"react-router-redux": "^4.0.8",
|
|
"react-tooltip": "^4.2.21",
|
|
"redux": "^4.2.0",
|
|
"redux-devtools-extension": "^2.13.9",
|
|
"redux-thunk": "^2.4.1",
|
|
"rxjs": "^7.5.6",
|
|
"typeface-roboto": "^1.1.13",
|
|
"uuid": "^11.1.1",
|
|
"vott-ct": "^2.3.3",
|
|
"web-vitals": "^0.2.4"
|
|
},
|
|
"browser": {
|
|
"crypto": false
|
|
},
|
|
"scripts": {
|
|
"start": "vite",
|
|
"build": "vite build && rm -rf ../machinery/www && mv build ../machinery/www",
|
|
"preview": "vite preview --outDir ../machinery/www",
|
|
"test": "vitest run",
|
|
"test:watch": "vitest",
|
|
"lint": "eslint --debug 'src/**/*.{js,jsx,ts,tsx}'",
|
|
"format": "prettier --write \"**/*.{js,jsx,json,md}\""
|
|
},
|
|
"devDependencies": {
|
|
"@vitejs/plugin-react": "^6.3.0",
|
|
"eslint": "^7.32.0",
|
|
"eslint-config-airbnb": "^18.2.1",
|
|
"eslint-plugin-import": "^2.26.0",
|
|
"eslint-plugin-jsx-a11y": "^6.6.1",
|
|
"eslint-plugin-react": "^7.30.1",
|
|
"eslint-plugin-react-hooks": "^4.6.0",
|
|
"jsdom": "^29.1.1",
|
|
"sass": "^1.108.2",
|
|
"vite": "^8.3.8",
|
|
"vitest": "^4.1.12"
|
|
},
|
|
"resolutions": {
|
|
"uuid": "^11.1.1"
|
|
}
|
|
}
|