дзеркало
https://github.com/l0ng-ai/openidea.git
синхронізовано 2026-12-03 16:51:16 +02:00
Adds Editor Only / Editor and Preview / Preview Only layouts for .mdx files. - Safe Static Mode on open: frontmatter, GFM, math, Mermaid, MDX comments and documentation tags (Steps, CardGroup, Note, Tabs, Accordion) render through the sanitized Markdown pipeline with scroll sync and no script execution. - Run JSX (or Trust Project in Restricted Mode) lazy-loads @mdx-js/mdx and sucrase and evaluates JSX, workspace/tsconfig/node_modules imports, .mdx transclusions, stylesheets, assets and custom layouts inside an opaque-origin sandboxed iframe with its own CSP, no network and no IPC. - The host-guest bridge is a per-document MessagePort; image, media, module and link resolution stay inside the window's project roots, checked lexically and after canonicalization (new fs_canonicalize command, which rejects parent traversal). - Execution requires a current, affirmative trust result for the file's owning project, including attached workspace members, whose trust changes now emit ProjectTrustChanged. - External links open only from a real click on an anchor in the frame and always go through a confirmation dialog showing the parsed destination. - Settings > Languages & Frameworks > Markdown adds MDX component execution (Ask before running / Run automatically in trusted projects / Disabled), a user-only setting that project settings cannot enable. Closes #6876 Co-authored-by: dengliu <[email protected]>
132 рядки
5.1 KiB
JSON
132 рядки
5.1 KiB
JSON
{
|
|
"name": "openidea",
|
|
"private": true,
|
|
"description": "An open-source IDE inspired by IntelliJ IDEA",
|
|
"version": "0.1.56",
|
|
"license": "Apache-2.0",
|
|
"type": "module",
|
|
"scripts": {
|
|
"dev": "vite",
|
|
"build": "node --max-old-space-size=4096 node_modules/typescript/bin/tsc --noEmit && vite build && node scripts/check-webkit.ts",
|
|
"preview": "vite preview",
|
|
"tauri": "node scripts/tauri.ts",
|
|
"test": "vitest run",
|
|
"test:watch": "vitest",
|
|
"smoke": "vitest run --config smoke/vitest.config.ts",
|
|
"lint": "oxlint",
|
|
"format": "oxfmt",
|
|
"format:check": "oxfmt --check",
|
|
"knip": "knip",
|
|
"typecheck": "tsrs --noEmit && tsrs -p tsconfig.node.json --noEmit && tsrs -p perf --noEmit && tsrs -p evals --noEmit && tsrs -p scripts --noEmit && tsrs -p smoke --noEmit && tsrs -p e2e --noEmit",
|
|
"gen:bindings": "cargo test -p openidea --test export_bindings",
|
|
"gen:windows-icons": "node scripts/gen-windows-icons.ts",
|
|
"gen:angular-grammar": "lezer-generator src/editor/core/cm/angular/angular.grammar --typeScript -o src/editor/core/cm/angular/parser.ts",
|
|
"gen:jsp-grammar": "lezer-generator src/editor/core/cm/jsp/jsp.grammar --typeScript -o src/editor/core/cm/jsp/parser.ts",
|
|
"gen:django-grammar": "lezer-generator src/editor/core/cm/django/django.grammar --typeScript -o src/editor/core/cm/django/parser.ts",
|
|
"gen:freemarker-grammar": "lezer-generator src/editor/core/cm/freemarker/freemarker.grammar --typeScript -o src/editor/core/cm/freemarker/parser.ts",
|
|
"gen:astro-grammar": "lezer-generator src/editor/core/cm/astro/astro.grammar --typeScript -o src/editor/core/cm/astro/parser.ts",
|
|
"gen:theme-docs": "node scripts/theme/gen-docs.ts",
|
|
"gen:plugin-catalog": "node scripts/gen-plugin-catalog.ts",
|
|
"theme:import-intellij": "node scripts/theme/import-intellij-theme.ts",
|
|
"dev:app": "node scripts/tauri.ts dev --config src-tauri/tauri.dev.conf.json",
|
|
"dev:status": "node scripts/dev-status.ts",
|
|
"e2e": "playwright test",
|
|
"perf": "node perf/run.ts",
|
|
"perf:rust": "node perf/rust.ts",
|
|
"eval": "node evals/run.ts",
|
|
"release:prepare": "node scripts/release-prepare.ts",
|
|
"dogfood:local": "node scripts/dogfood.ts local",
|
|
"dogfood:remote": "node scripts/dogfood-remote.ts",
|
|
"dogfood:all": "node scripts/dogfood.ts all"
|
|
},
|
|
"simple-git-hooks": {
|
|
"pre-commit": "pnpm lint-staged"
|
|
},
|
|
"lint-staged": {
|
|
"*.{js,jsx,mjs,cjs,ts,tsx,mts,cts}": "oxlint --fix --no-error-on-unmatched-pattern",
|
|
"*": "oxfmt --no-error-on-unmatched-pattern",
|
|
"*.rs": "rustfmt --edition 2024"
|
|
},
|
|
"dependencies": {
|
|
"@codemirror/autocomplete": "^6.20.3",
|
|
"@codemirror/commands": "^6.11.1",
|
|
"@codemirror/lang-html": "^6.4.12",
|
|
"@codemirror/lang-java": "^6.0.2",
|
|
"@codemirror/lang-javascript": "^6.2.5",
|
|
"@codemirror/lang-jinja": "^6.0.1",
|
|
"@codemirror/lang-less": "^6.0.2",
|
|
"@codemirror/lang-markdown": "^6.5.2",
|
|
"@codemirror/lang-sass": "^6.0.2",
|
|
"@codemirror/lang-sql": "^6.10.0",
|
|
"@codemirror/lang-vue": "^0.1.3",
|
|
"@codemirror/language": "^6.13.1",
|
|
"@codemirror/language-data": "^6.5.2",
|
|
"@codemirror/legacy-modes": "^6.5.5",
|
|
"@codemirror/lint": "^6.9.7",
|
|
"@codemirror/merge": "^6.12.2",
|
|
"@codemirror/search": "^6.7.2",
|
|
"@codemirror/state": "^6.7.6",
|
|
"@codemirror/view": "^6.44.2",
|
|
"@floating-ui/react-dom": "^2.1.9",
|
|
"@fontsource-variable/inter": "^5.3.0",
|
|
"@fontsource-variable/jetbrains-mono": "^5.3.0",
|
|
"@lezer/common": "^1.5.6",
|
|
"@lezer/highlight": "^1.2.5",
|
|
"@lezer/lr": "^1.4.11",
|
|
"@mathjax/mathjax-tex-font": "4.1.3",
|
|
"@mathjax/src": "4.1.3",
|
|
"@mdx-js/mdx": "^3.1.0",
|
|
"@mdx-js/react": "^3.1.0",
|
|
"@plutojl/lang-julia": "^1.2.0",
|
|
"@replit/codemirror-vim": "6.4.0",
|
|
"@tanstack/react-virtual": "^3.14.21",
|
|
"@tauri-apps/api": "^2",
|
|
"@tauri-apps/plugin-dialog": "^2.8.3",
|
|
"@tauri-apps/plugin-opener": "^2",
|
|
"@xterm/addon-fit": "0.12.0-beta.334",
|
|
"@xterm/addon-search": "0.17.0-beta.332",
|
|
"@xterm/xterm": "6.1.0-beta.338",
|
|
"anser": "^2.3.5",
|
|
"clsx": "^2.1.1",
|
|
"dompurify": "^3.4.17",
|
|
"elkjs": "0.9.3",
|
|
"emmet": "2.4.11",
|
|
"immer": "^11.1.21",
|
|
"katex": "^0.19.1",
|
|
"marked": "^18.1.1",
|
|
"mermaid": "12.1.0",
|
|
"react": "^19.1.0",
|
|
"react-colorful": "5.6.1",
|
|
"react-dom": "^19.1.0",
|
|
"react-resizable-panels": "^4.14.6",
|
|
"remark-frontmatter": "^5.0.0",
|
|
"remark-gfm": "^4.0.1",
|
|
"sucrase": "^3.35.0",
|
|
"zustand": "^5.0.15"
|
|
},
|
|
"devDependencies": {
|
|
"@lezer/generator": "^1.8.1",
|
|
"@noble/hashes": "^2.4.0",
|
|
"@playwright/test": "^1.64.1",
|
|
"@tauri-apps/cli": "^2",
|
|
"@testing-library/jest-dom": "^7.0.1",
|
|
"@testing-library/react": "^16.3.3",
|
|
"@testing-library/user-event": "^14.6.8",
|
|
"@types/node": "^26.6.5",
|
|
"@types/react": "^19.1.8",
|
|
"@types/react-dom": "^19.1.6",
|
|
"@vitejs/plugin-react": "^6.0.2",
|
|
"jsdom": "^30.1.3",
|
|
"knip": "^6.43.0",
|
|
"lint-staged": "^17.6.0",
|
|
"oxfmt": "^0.74.0",
|
|
"oxlint": "^1.89.0",
|
|
"simple-git-hooks": "^2.14.0",
|
|
"tsrs": "^0.20.0-ts7.1.0-beta",
|
|
"typescript": "~6.0.3",
|
|
"vite": "^8.0.16",
|
|
"vitest": "^5.0.5",
|
|
"yaml": "^2.9.1"
|
|
}
|
|
}
|