Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
5deb1cb
H-5839: Extract Monaco setup into dedicated module with async loading
kube Feb 19, 2026
16ab539
H-5839: Consolidate checker into self-contained module
kube Feb 19, 2026
61de262
H-5839: Fix import paths after checker move and remove debug delay
kube Feb 19, 2026
27509b8
H-5839: Move checker to WebWorker with JSON-RPC protocol
kube Feb 19, 2026
3eb9d44
H-5839: Bundle TypeScript into worker and remove CDN/polyfill workaro…
kube Feb 19, 2026
be47f6c
H-5839: Remove @dnd-kit and feature flags
kube Feb 19, 2026
806b1c7
H-5839: Remove rollup-plugin-visualizer dependency
kube Feb 19, 2026
56eba32
H-5839: Wire checker diagnostics into Monaco editors as inline markers
kube Feb 19, 2026
0ef8aa7
H-5839: Add completions, hover, and signature help providers to Monac…
kube Feb 20, 2026
bc53261
H-5839: Adopt LSP-like protocol and reuse TS LanguageService across S…
kube Feb 26, 2026
201124e
H-5839: Adopt vscode-languageserver-types for standard LSP protocol t…
kube Feb 26, 2026
f98b7d2
H-5839: Add changeset for LSP language service layer
kube Feb 26, 2026
b1ef02a
H-5839: Modernize LanguageClientProvider to React 19 patterns
kube Feb 26, 2026
c36007d
H-5839: Fix ESLint errors across checker and Monaco sync components
kube Feb 26, 2026
edf90bf
H-5839: Consolidate document URI mapping into single shared module
kube Feb 26, 2026
441087f
H-5839: Extract TS-to-LSP conversion functions into testable module
kube Feb 26, 2026
e6188e6
H-5839: Rename checker/ to lsp/ and checker.worker to language-server…
kube Feb 26, 2026
65446c0
H-5839: Fix position mapping to use user content instead of prefix+co…
kube Feb 26, 2026
088e22b
H-5839: Reset LanguageClientProvider when petriNetId changes
kube Feb 26, 2026
8c61cd0
Lint
kube Feb 26, 2026
fdc56a8
H-5839: Sync document content to worker before LSP requests
kube Feb 26, 2026
d86a788
H-5839: Clamp `positionToOffset` to `text.length` for symmetry with `…
kube Feb 26, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .changeset/bright-ideas-flow.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@hashintel/petrinaut": minor
---

Add LSP-based language service layer for Monaco code editors with diagnostics, completions, hover, and signature help
14 changes: 0 additions & 14 deletions apps/hash-frontend/next.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -219,20 +219,6 @@ export default withSentryConfig(
// eslint-disable-next-line no-param-reassign
webpackConfig.resolve.alias.canvas = false;

if (!isServer) {
// Stub Node.js built-ins for browser — needed by `typescript` (used by
// @hashintel/petrinaut's in-browser language service)
// eslint-disable-next-line no-param-reassign
webpackConfig.resolve.fallback = {
...webpackConfig.resolve.fallback,
module: false,
fs: false,
path: false,
os: false,
perf_hooks: false,
};
}

webpackConfig.plugins.push(
new DefinePlugin({
__SENTRY_DEBUG__: false,
Expand Down
13 changes: 1 addition & 12 deletions apps/hash-frontend/src/lib/csp.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,19 +24,13 @@ export const buildCspHeader = (nonce: string): string => {
"https://apis.google.com",
// Vercel toolbar / live preview widget
"https://vercel.live",
// @todo FE-488 will make this unnecessary
// Monaco Editor loaded from CDN by @monaco-editor/react (used by petrinaut)
"https://cdn.jsdelivr.net",
],

"style-src": [
"'self'",
// Required for Emotion/MUI CSS-in-JS inline style injection.
// @todo Use nonce-based approach via Emotion's cache `nonce` option.
"'unsafe-inline'",
// @todo FE-488 will make this unnecessary
// Monaco Editor stylesheet loaded from CDN by @monaco-editor/react (used by petrinaut)
"https://cdn.jsdelivr.net",
],

"img-src": [
Expand All @@ -51,12 +45,7 @@ export const buildCspHeader = (nonce: string): string => {
...(process.env.NODE_ENV === "development" ? ["http:"] : []),
],

"font-src": [
"'self'",
// @todo FE-488 will make this unnecessary
// Monaco Editor CSS embeds the Codicon icon font as an inline base64 data URI
"data:",
],
"font-src": ["'self'"],

"connect-src": [
"'self'",
Expand Down
1 change: 1 addition & 0 deletions libs/@hashintel/petrinaut/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@
"reactflow": "11.11.4",
"typescript": "5.9.3",
"uuid": "13.0.0",
"vscode-languageserver-types": "3.17.5",
"web-worker": "1.4.1"
},
"devDependencies": {
Expand Down
3 changes: 0 additions & 3 deletions libs/@hashintel/petrinaut/src/feature-flags.ts

This file was deleted.

Loading
Loading