Skip to content

🪢 Open source agent evals & observability: Trace, evaluate, and improve LLM applications with one open platform.

chore: upgrade prism (#8083)

Max Deichmannbb06e079ebd9
diff --git a/package.json b/package.json
index 0551a7e12e..d3ae8d75d5 100644
--- a/package.json
+++ b/package.json
@@ -91,8 +91,7 @@
"nanoid": "^3.3.8",
"katex": "^0.16.21",
"tar-fs": "^2.1.2",
- "rollup@^4.0.0": "^4.22.4",
- "react-syntax-highlighter>prismjs": "1.30.0"
+ "rollup@^4.0.0": "^4.22.4"
},
"patchedDependencies": {
diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml
index 6654e96eaf..2a186ad5d4 100644
--- a/pnpm-lock.yaml
+++ b/pnpm-lock.yaml
@@ -9,7 +9,6 @@ overrides:
katex: ^0.16.21
tar-fs: ^2.1.2
rollup@^4.0.0: ^4.22.4
- react-syntax-highlighter>prismjs: 1.30.0
patchedDependencies:
@@ -61,7 +60,7 @@ importers:
next-auth:
specifier: ^4.24.11
zod:
specifier: ^3.25.62
version: 3.25.62
@@ -235,7 +234,7 @@ importers:
version: 4.1.1
next-auth:
specifier: ^4.24.11
nodemailer:
specifier: ^6.9.15
version: 6.9.15
@@ -623,7 +622,7 @@ importers:
next-auth:
specifier: ^4.24.11
next-query-params:
specifier: ^5.0.1
@@ -639,6 +638,9 @@ importers:
prexit:
specifier: ^2.2.0
version: 2.2.0
+ prism-react-renderer:
+ specifier: ^2.4.1
+ version: 2.4.1([email protected])
prisma:
specifier: ^6.10.1
version: 6.10.1([email protected])
@@ -675,9 +677,6 @@ importers:
react-responsive:
specifier: ^10.0.0
version: 10.0.0([email protected])
- react-syntax-highlighter:
- specifier: ^15.6.1
- version: 15.6.1([email protected])
react18-json-view:
specifier: ^0.2.8-canary.6
version: 0.2.8-canary.6([email protected])
@@ -793,9 +792,6 @@ importers:
'@types/react-grid-layout':
specifier: ^1.3.5
version: 1.3.5
- '@types/react-syntax-highlighter':
- specifier: ^15.5.13
- version: 15.5.13
'@types/uuid':
specifier: ^9.0.8
version: 9.0.8
@@ -5359,9 +5355,6 @@ packages:
resolution: {integrity: sha512-ynRvcq6wvqexJ9brDMS4BnBLzmr0e14d6ZJTEShTBWKymQiHwlAyGu0ZPEFI2Fh1U53F7tN9ufClWM5KvqkKOw==}
- '@types/[email protected]':
- resolution: {integrity: sha512-McWspRw8xx8J9HurkVBfYj0xKoE25tOFlHGdx4MJ5xORQrMGZNqJhVQWaIbm6Oyla5kYOXtDiopzKRJzEOkwJw==}
-
resolution: {integrity: sha512-WPs+bbQw5aCj+x6laNGWLH3wviHtoCv/P3+otBhbOhJgG8qtpdAMlTCxLtsTWA7LH1Oh/bFCHsBn0TPS5m30EQ==}
@@ -5440,6 +5433,9 @@ packages:
resolution: {integrity: sha512-1Kc4oAGzAl7uqUStZCDvaLFqZrW9qWSjXOmBfdgyBP5La7Us6Mg4GBvRlSoaZMhQF/zSj1C8CtKMBkoiT8eL8w==}
+ '@types/[email protected]':
+ resolution: {integrity: sha512-AUZTa7hQ2KY5L7AmtSiqxlhWxb4ina0yd8hNbl4TWuqnv/pFP0nDMb3YrfSBf4hJVGLh2YEIBfKaBW/9UEl6IQ==}
+
resolution: {integrity: sha512-5zvhXYtRNRluoE/jAp4GVsSduVUzNWKkOZrCDBWYtE7biZywwdC2AcEzg+cSMLFRfVgeAFqpfNabiPjxFddV1Q==}
@@ -5461,9 +5457,6 @@ packages:
resolution: {integrity: sha512-WH/po1gcEcoR6y857yAnPGug+ZhkF4PaTUxgAbwfeSH/QOgVSakKHBXoPGad/sEznmkiaK3pqHk+etdWisoeBQ==}
- '@types/[email protected]':
- resolution: {integrity: sha512-uLGJ87j6Sz8UaBAooU0T6lWJ0dBmjZgN1PZTrj05TNql2/XpC6+4HhMT5syIdFUUt+FASfCeLLv4kBygNU+8qA==}
-
resolution: {integrity: sha512-RM05tAniPZ5DZPzzNFP+DmrcOdD0efDUxMy3145oljWSl3x9ZV5vhme98gTxFrj2lhXvmGNnUiuDyJgY9IKkNA==}
@@ -6348,21 +6341,12 @@ packages:
resolution: {integrity: sha512-1v7fgQRj6hnSwFpq1Eu0ynr/CDEw0rXo2B61qXrLNdHZmPKgb7fqS1a2JwF0rISo9q77jDI8VMEHoApn8qDoZA==}
- resolution: {integrity: sha512-3Xnr+7ZFS1uxeiUDvV02wQ+QDbc55o97tIV5zHScSPJpcLm/r0DFPcoY3tYRp+VZukxuMeKgXYmsXQHO05zQeA==}
-
resolution: {integrity: sha512-RpPp0asT/6ufRm//AJVwpViZbGM/MkjQFxJccQRHmISF/22NBtsHqAWmL+/pmkPWoIUJdWyeVleTl1wydHATVQ==}
- resolution: {integrity: sha512-iBMyeEHxfVnIakwOuDXpVkc54HijNgCyQB2w0VfGQThle6NXn50zU6V/u+LDhxHcDUPojn6Kpga3PTAD8W1bQw==}
-
resolution: {integrity: sha512-shx7oQ0Awen/BRIdkjkvz54PnEEI/EjwXDSIZp86/KKdbafHh1Df/RYGBhn4hbe2+uKC9FnT5UCEdyPz3ai9hQ==}
- resolution: {integrity: sha512-mKKUkUbhPpQlCOfIuZkvSEgktjPFIsZKRRbC6KWVEMvlzblj3i3asQv5ODsrwt0N3pHAEvjP8KTQPHkp0+6jOg==}
-
resolution: {integrity: sha512-iBZ4F4wRbyORVsu0jPV7gXkOsGYjGHPmAyv+HiHG8gi5PtC9KI2j1+v8/tlibRvjoWX027ypmG/n0HtO5t7unw==}
@@ -6530,9 +6514,6 @@ packages:
resolution: {integrity: sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==}
engines: {node: '>= 0.8'}
- resolution: {integrity: sha512-GHuDRO12Sypu2cV70d1dkA2EUmXHgntrzbpvOB+Qy+49ypNfGgFQIC2fhhXbnyrJRynDCAARsT7Ou0M6hirpfw==}
-
resolution: {integrity: sha512-Fu4hJdvzeylCfQPp9SGWidpzrMs7tTrlu6Vb8XGaRGck8QSNZJJp538Wrb60Lax4fPwR64ViY468OIUTbRlGZg==}
@@ -7725,9 +7706,6 @@ packages:
resolution: {integrity: sha512-sRVD3lWVIXWg6By68ZN7vho9a1pQcN/WBFaAAsDDFzlJjvoGx0P8z7V1t72grFJfJhu3YPZBuu25f7Kaw2jN1w==}
- resolution: {integrity: sha512-CJ0HCB5tL5fYTEA7ToAq5+kTwd++Borf1/bifxd9iT70QcXr4MRrO3Llf8Ifs70q+SJcGHFtnIE/Nw6giCtECA==}
-
resolution: {integrity: sha512-p5161BqbuCaSnB8jIbzQHOlpgsPmK5rJVDfDKO91Axs5NC1uu3HRQm6wt9cd9/+GtQQIO53JdGXXoyDpTAsgYA==}
@@ -7824,10 +7802,6 @@ packages:
resolution: {integrity: sha512-hGfm/slu0ZabnNt4oaRZ6uREyfCj6P4fT/n6A1rGV+Z0VdGXjfOhVUpkn6qVQONHGIFwmveGXyDs75+nr6FM8w==}
engines: {node: '>= 6'}
- resolution: {integrity: sha512-wzsgA6WOq+09wrU1tsJ09udeR/YZRaeArL9e1wPbFg3GG2yDnC2ldKpxs4xunpFF9DgqCqOIra3bc1HWrJ37Ww==}
- engines: {node: '>=0.4.x'}
-
resolution: {integrity: sha512-0iirZp3uVDjVGt9p49aTaqjk84TrglENEDuqfdlZQ1roC9CWlPk6Avf8EEnZNcAqPonwkG35x4n3ww/1THYAeQ==}
engines: {node: '>= 12.20'}
@@ -8112,18 +8086,12 @@ packages:
resolution: {integrity: sha512-0hJU9SCPvmMzIBdZFqNPXWa6dqh7WdH0cII9y+CyS8rG3nL48Bclra9HmKhVVUHyPWNH5Y7xDwAB7bfgSjkUMQ==}
engines: {node: '>= 0.4'}
- resolution: {integrity: sha512-7j6mrk/qqkSehsM92wQjdIgWM2/BW61u/53G6xmC8i1OmEdKLHbk419QKQUjz6LglWsfqoiHmyMRkP1BGjecNQ==}
-
resolution: {integrity: sha512-H/y0+IWPdsLLS738P8tDnrQ8Z+dj12zQQ6WC11TIM21C8WFVoIxcqWXf2H3hiTVZjF1AWqoimGwrTWecWrnmRQ==}
resolution: {integrity: sha512-88JUN06ipLwsnv+dVn+OIYOvAuvBMy/Qoi6O7mQHxdPXpjy+Cd6xRkWwux7DKO+4sYILtLBRIKgsdpS2gQc7qw==}
- resolution: {integrity: sha512-nDM6bvd7lIqDUiYEiu5Sl/+6ReP0BMk/2f4U/Rooccxkj0P5nm+acM5PrGJ/t5I8qPGiqZSE6hVAwZEdZIvP4w==}
-
resolution: {integrity: sha512-IScLbePpkvO846sIwOtOTDjutRMWdXdJmXdMvk6gCBHxFO8d+QKOQedyZSxFTTFYRSmlgSTDtXqqq4pcenBXLQ==}
@@ -8131,12 +8099,6 @@ packages:
resolution: {integrity: sha512-g+HZqgfbpXdCkme/Cd/mZkV0aV3BZZZSugecH03kl38m/Kmdx8jKjBikpDj2cr+Iynv4KpYEviojNdTJActJAg==}
engines: {node: '>=16.0.0'}
- resolution: {integrity: sha512-tzcUFauisWKNHaRkN4Wjl/ZA07gENAjFl3J/c480dprkGTg5EQstgaNFqBfUqCq54kZRIEcreTsAgF/m2quD7A==}
-
- resolution: {integrity: sha512-PDEfEF102G23vHmPhLyPboFCD+BkMGu+GuJe2d9/eH4FsCwvgBpnc9n0pGE+ffKdph38s6foEZiEjdgHdzp+IA==}
-
resolution: {integrity: sha512-/gGivxi8JPKWNm/W0jSmzcMPpfpPLc3dY/6GxhX2hQ9iGj3aDfklV4ET7NjKpSinLpJ5vafa9iiGIEZg10SfBw==}
@@ -8323,15 +8285,9 @@ packages:
resolution: {integrity: sha512-0KI/607xoxSToH7GjN1FfSbLoU0+btTicjsQSWQlh/hZykN8KpmMf7uYwPW3R+akZ6R/w18ZlXSHBYXiYUPO3g==}
engines: {node: '>= 0.10'}
- resolution: {integrity: sha512-DwzsA04LQ10FHTZuL0/grVDk4rFoVH1pjAToYwBrHSxcrBIGQuXrQMtD5U1b0U2XVgKZCTLLP8u2Qxqhy3l2Vg==}
-
resolution: {integrity: sha512-FWyyY60MeTNyeSRpkM2Iry0G9hpr7/9kD40mD/cGQEuilcZYS4okz8SN2Q6rLCJ8gbCt6fN+rC+6tMGS99LaxQ==}
- resolution: {integrity: sha512-UzoZUr+XfVz3t3v4KyGEniVL9BDRoQtY7tOyrRybkVNjDFWyo1yhXNGrrBTQxp3ib9BLAWs7k2YKBQsFRkZG9A==}
-
resolution: {integrity: sha512-hmbYhX/9MUMF5uh7tOXyK/n0ZvWpad5caBA17GsC6vyuCqaWliRG5K1qS9inmUhEMaOBIW7/whAnSwveW/LtZw==}
@@ -8384,9 +8340,6 @@ packages:
resolution: {integrity: sha512-9YQaSxsAiSwcvS33MBk3wTCVnWK+HhF8VZR2jRxehM16QcVOdHqPn4VPHmRK4lSr38n9JriurInLcP90xsYNfQ==}
engines: {node: '>= 0.4'}
- resolution: {integrity: sha512-RGdriMmQQvZ2aqaQq3awNA6dCGtKpiDFcOzrTWrDAT2MiWrKQVPmxLGHl7Y2nNu6led0kEyoX0enY0qXYsv9zw==}
-
resolution: {integrity: sha512-AAB9hiomQs5DXWcRB1rqsxGUstbRroFOPPVAomNk/3XHR5JyEZChOyTWe2oayKnsSsr/kcGqF+z6yuH6HHpN0A==}
@@ -8423,9 +8376,6 @@ packages:
resolution: {integrity: sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==}
engines: {node: '>=0.10.0'}
- resolution: {integrity: sha512-gyPJuv83bHMpocVYoqof5VDiZveEoGoFL8m3BXNb2VW8Xs+rz9kqO8LOQ5DH6EsuvilT1ApazU0pyl+ytbPtlw==}
-
resolution: {integrity: sha512-DgZQp241c8oO6cA1SbTEWiXeoxV42vlcJxgH+B3hi1AiqqKruZR3ZGF8In3fj4+/y/7rHvlOZLZtgJ/4ttYGZg==}
@@ -9157,9 +9107,6 @@ packages:
resolution: {integrity: sha512-wJzkKwJrheKtknCOKNEtDK4iqg/MxmZheEMtSTYvnzRdEYaZzmgH976nenp8WdJRdx5Vc1X/9MO0Oszl6ezeXg==}
- resolution: {integrity: sha512-8Ktj+prEb1RoCPkEOrPMYUN/nCggB7qAWe3a7OpMjWQkh3l2RD5wKRQ+o8Q8YuI9RG/xs95waaI/E6ym/7NsTw==}
-
resolution: {integrity: sha512-JNAzZcXrCt42VGLuYz0zfAzDfAvJWW6AfYlDBQyDV5DClI2m5sAmK+OIO7s59XfsRsWHp02jAJrRadPRGTt6SQ==}
@@ -9947,9 +9894,6 @@ packages:
resolution: {integrity: sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g==}
engines: {node: '>=6'}
- resolution: {integrity: sha512-kkywGpCcRYhqQIchaWqZ875wzpS/bMKhz5HnN3p7wveJTkTtyAB/AlnS0f8DFSqYW1T82t6yEAkEcB+A1I3MbQ==}
-
resolution: {integrity: sha512-SWzvYcSJh4d/SGLIOQfZ/CoNv6BTlI6YEQ7Nj82oDVnRpwe/Z/F1EMx42x3JAOwGBlCjeCH0BRJQbQ/opHL17w==}
@@ -10342,6 +10286,11 @@ packages:
resolution: {integrity: sha512-MrkWg5/0XFTM0txQtPFZlhk3qhMtyd+bP1vXJKQqOOYcdQ8/Wl5+G0Utxv69TLfH0PMm/ushn0YTYQ2SH2WzJg==}
+ resolution: {integrity: sha512-ey8Ls/+Di31eqzUxC46h8MksNuGx/n0AAC8uKpwFau4RPDYLuE3EXTp8N8G2vX2N7UC/+IXeNUnlWBGGcAG+Ig==}
+ peerDependencies:
+ react: '>=16.0.0'
+
resolution: {integrity: sha512-abo2EBIjqJALfjm8p+uOsQk38DlU3rlLJA9/cOvcLLt8A9bjMkRwlqaZDAD/iXVZcXJRJPgJ98fEviTa+w8oTQ==}
engines: {node: '>=14'}
@@ -10368,10 +10317,6 @@ packages:
typescript:
optional: true
- resolution: {integrity: sha512-t13BGPUlFDR7wRB5kQDG4jjl7XeuH6jbJGt11JHPL96qwsEHNX2+68tFXqc1/k+/jALsbSWJKUOT/hcYAZ5LkA==}
- engines: {node: '>=6'}
-
resolution: {integrity: sha512-DEvV2ZF2r2/63V+tK8hQvrR2ZGn10srHbXviTlcv7Kpzw8jWiNTqbVgjO3IY8RxrrOUF8VPMQQFysYYYv0YZxw==}
engines: {node: '>=6'}
@@ -10390,9 +10335,6 @@ packages:
resolution: {integrity: sha512-oj87CgZICdulUohogVAR7AjlC0327U4el4L6eAvOqCeudMDVU0NThNaV+b9Df4dXgSP1gXMTnPdhfe/2qDH5cg==}
- resolution: {integrity: sha512-YUHSPk+A30YPv+0Qf8i9Mbfe/C0hdPXk1s1jPVToV8pk8BQtpw10ct89Eo7OWkutrwqvT0eicAxlOg3dOAu8JA==}
-
resolution: {integrity: sha512-PgTgs/BlvHxOu8QuEN7wi5A0OmXaBcHpmCSTehcs6Uuu9IkDIEo13Hy7n898RHfrQ49vKCoGeWZSaAK01nwVig==}
@@ -10590,11 +10532,6 @@ packages:
'@types/react':
optional: true
- resolution: {integrity: sha512-OqJ2/vL7lEeV5zTJyG7kmARppUjiB9h9udl4qHQjjgEos66z00Ia0OckwYfRxCSFrW8RJIBnsBwQsHZbVPspqg==}
- peerDependencies:
- react: '>= 0.14.0'
-
resolution: {integrity: sha512-pZcd1MCJoiKiBR2NRxeCRg13uCXbydPnmB4EOeRrY7480qNWO8IIgQG6zlDkm6uRMsURXPuKq0GWtiM59a5Q6g==}
peerDependencies:
@@ -10675,9 +10612,6 @@ packages:
resolution: {integrity: sha512-fmfw4XgoDke3kdI6h4xcUz1dG8uaiv5q9gcEwLS4Pnth2kxT+GZ7YehS1JTMGBQmtV7Y4GFGbs2re2NqhdozUg==}
engines: {node: '>= 0.4'}
- resolution: {integrity: sha512-MY9W41IOWxxk31o+YvFCNyNzdkc9M20NoZK5vq6jkv4I/uh2zkWcfudj0Q1fovjUQJrNewS9NMzeTtqPf+n5EA==}
-
resolution: {integrity: sha512-dYnhHh0nJoMfnkZs6GmmhFknAGRrLznOu5nc9ML+EJxGvrx6H7teuevqVqCuPcPK//3eDrrjQhehXVx9cnkGdw==}
@@ -11081,9 +11015,6 @@ packages:
resolution: {integrity: sha512-l3BikUxvPOcn5E74dZiq5BGsTb5yEwhaTSzccU6t4sDOH8NWJCstKO5QT2CvtFoK6F0saL7p9xHAqHOlCPJygA==}
engines: {node: '>= 8'}
- resolution: {integrity: sha512-q/JSVd1Lptzhf5bkYm4ob4iWPjx0KiRe3sRFBNrVqbJkFaBm5vbbowy1mymoPNLRa52+oadOhJ+K49wsSeSjTA==}
-
resolution: {integrity: sha512-PEGlAwrG8yXGXRjW32fGbg66JAlOAwbObuqVoJpv/mRgoWDQfgH1wDPvtzWyUSNAXBGSk8h755YDbbcEy3SH2Q==}
@@ -15160,7 +15091,7 @@ snapshots:
dependencies:
dependencies:
@@ -18066,10 +17997,6 @@ snapshots:
'@types/[email protected]': {}
- '@types/[email protected]':
- dependencies:
- '@types/unist': 2.0.10
-
dependencies:
'@types/unist': 3.0.2
@@ -18161,6 +18088,8 @@ snapshots:
pg-protocol: 1.7.0
pg-types: 2.2.0
+ '@types/[email protected]': {}
+
'@types/[email protected]': {}
'@types/[email protected]': {}
@@ -18179,10 +18108,6 @@ snapshots:
dependencies:
'@types/react': 18.2.79
- '@types/[email protected]':
- dependencies:
- '@types/react': 18.2.79
-
dependencies:
'@types/react': 18.2.79
@@ -18523,7 +18448,7 @@ snapshots:
'@typescript-eslint/eslint-plugin': 7.3.1(@typescript-eslint/[email protected]([email protected])([email protected]))([email protected])([email protected])
'@typescript-eslint/parser': 7.12.0([email protected])([email protected])
eslint-config-prettier: 9.1.0([email protected])
+ eslint-import-resolver-alias: 1.1.2([email protected](@typescript-eslint/[email protected]([email protected])([email protected]))([email protected]))
eslint-import-resolver-typescript: 3.6.1(@typescript-eslint/[email protected]([email protected])([email protected]))([email protected])([email protected])
eslint-plugin-eslint-comments: 3.2.0([email protected])
@@ -19332,16 +19257,10 @@ snapshots:
-
-
-
@@ -19550,8 +19469,6 @@ snapshots:
dependencies:
delayed-stream: 1.0.0
-
@@ -20508,7 +20425,7 @@ snapshots:
eslint-plugin-turbo: 2.5.4([email protected])([email protected])
turbo: 2.5.4
dependencies:
@@ -20599,7 +20516,7 @@ snapshots:
doctrine: 2.1.0
eslint: 8.57.0
eslint-import-resolver-node: 0.3.9
hasown: 2.0.2
is-core-module: 2.15.1
is-glob: 4.0.3
@@ -20626,7 +20543,7 @@ snapshots:
doctrine: 2.1.0
eslint: 8.57.0
eslint-import-resolver-node: 0.3.9
hasown: 2.0.2
is-core-module: 2.15.1
is-glob: 4.0.3
@@ -21039,10 +20956,6 @@ snapshots:
dependencies:
reusify: 1.0.4
- dependencies:
- format: 0.2.2
-
dependencies:
bser: 2.1.1
@@ -21141,8 +21054,6 @@ snapshots:
es-set-tostringtag: 2.1.0
mime-types: 2.1.35
-
dependencies:
node-domexception: 1.0.0
@@ -21470,8 +21381,6 @@ snapshots:
dependencies:
function-bind: 1.1.2
-
dependencies:
'@types/estree': 1.0.6
@@ -21496,22 +21405,10 @@ snapshots:
dependencies:
'@types/hast': 3.0.4
- dependencies:
- '@types/hast': 2.3.10
- comma-separated-tokens: 1.0.8
- hast-util-parse-selector: 2.2.5
- property-information: 5.6.0
- space-separated-tokens: 1.1.5
-
-
-
dependencies:
react-is: 16.13.1
@@ -21731,15 +21628,8 @@ snapshots:
-
- dependencies:
- is-alphabetical: 1.0.4
- is-decimal: 1.0.4
-
dependencies:
is-alphabetical: 2.0.1
@@ -21793,8 +21683,6 @@ snapshots:
dependencies:
has-tostringtag: 1.0.2
-
@@ -21819,8 +21707,6 @@ snapshots:
dependencies:
is-extglob: 2.1.1
-
@@ -22724,11 +22610,6 @@ snapshots:
- dependencies:
- fault: 1.0.4
- highlight.js: 10.7.3
-
@@ -23345,7 +23226,7 @@ snapshots:
dependencies:
type-fest: 2.19.0
dependencies:
'@babel/runtime': 7.26.0
'@panva/hkdf': 1.1.1
@@ -23755,15 +23636,6 @@ snapshots:
dependencies:
callsites: 3.1.0
- dependencies:
- character-entities: 1.2.4
- character-entities-legacy: 1.1.4
- character-reference-invalid: 1.1.4
- is-alphanumerical: 1.0.4
- is-decimal: 1.0.4
- is-hexadecimal: 1.0.4
-
dependencies:
'@types/unist': 2.0.10
@@ -24088,6 +23960,12 @@ snapshots:
+ dependencies:
+ '@types/prismjs': 1.26.5
+ clsx: 2.1.1
+ react: 18.2.0
+
dependencies:
'@mermaid-js/mermaid-cli': 10.8.0([email protected])
@@ -24123,8 +24001,6 @@ snapshots:
optionalDependencies:
typescript: 5.4.5
-
@@ -24142,10 +24018,6 @@ snapshots:
object-assign: 4.1.1
react-is: 16.13.1
- dependencies:
- xtend: 4.0.2
-
@@ -24399,16 +24271,6 @@ snapshots:
optionalDependencies:
'@types/react': 18.2.79
- dependencies:
- '@babel/runtime': 7.27.6
- highlight.js: 10.7.3
- highlightjs-vue: 1.0.0
- lowlight: 1.20.0
- prismjs: 1.30.0
- react: 18.2.0
- refractor: 3.6.0
-
dependencies:
'@babel/runtime': 7.25.7
@@ -24516,12 +24378,6 @@ snapshots:
globalthis: 1.0.4
which-builtin-type: 1.1.3
- dependencies:
- hastscript: 6.0.0
- parse-entities: 2.0.0
- prismjs: 1.27.0
-
@@ -25027,8 +24883,6 @@ snapshots:
-
diff --git a/web/package.json b/web/package.json
index 517efac845..66063c91e6 100644
--- a/web/package.json
+++ b/web/package.json
@@ -125,6 +125,7 @@
"posthog-js": "^1.176.0",
"posthog-node": "^4.3.1",
"prexit": "^2.2.0",
+ "prism-react-renderer": "^2.4.1",
"prisma": "^6.10.1",
"protobufjs": "^7.4.0",
"rate-limiter-flexible": "^5.0.3",
@@ -137,7 +138,6 @@
"react-markdown": "^9.0.1",
"react-resizable-panels": "^2.1.1",
"react-responsive": "^10.0.0",
- "react-syntax-highlighter": "^15.6.1",
"react18-json-view": "^0.2.8-canary.6",
"recharts": "^2.15.2",
"remark-gfm": "^4.0.0",
@@ -178,7 +178,6 @@
"@types/react": "~18.2.79",
"@types/react-dom": "~18.2.25",
"@types/react-grid-layout": "^1.3.5",
- "@types/react-syntax-highlighter": "^15.5.13",
"@types/uuid": "^9.0.8",
"@typescript-eslint/eslint-plugin": "^6.21.0",
"@typescript-eslint/parser": "^7.12.0",
diff --git a/web/src/components/ui/Codeblock.tsx b/web/src/components/ui/Codeblock.tsx
index 77e101a5cb..9b67f573b4 100644
--- a/web/src/components/ui/Codeblock.tsx
+++ b/web/src/components/ui/Codeblock.tsx
@@ -3,11 +3,7 @@ import { copyTextToClipboard } from "@/src/utils/clipboard";
import { cn } from "@/src/utils/tailwind";
import { Check, Copy } from "lucide-react";
import { type FC, memo, useState } from "react";
-import { Prism as SyntaxHighlighter } from "react-syntax-highlighter";
-import {
- coldarkDark,
- solarizedlight,
-} from "react-syntax-highlighter/dist/cjs/styles/prism";
+import { Highlight, themes } from "prism-react-renderer";
interface Props {
language: string;
@@ -80,26 +76,35 @@ const CodeBlock: FC<Props> = memo(({ language, value, theme, className }) => {
</Button>
</div>
</div>
- <SyntaxHighlighter
+ <Highlight
+ theme={theme === "dark" ? themes.vsDark : themes.github}
+ code={value}
language={language}
- style={theme === "dark" ? coldarkDark : solarizedlight}
- PreTag="div"
- customStyle={{
- margin: 0,
- width: "100%",
- background: "transparent",
- padding: "0.5rem",
- }}
- codeTagProps={{
- style: {
- fontSize: "0.75rem",
- fontFamily: "var(--font-mono)",
- display: "block",
- },
- }}
>
- {value}
- </SyntaxHighlighter>
+ {({ className, style, tokens, getLineProps, getTokenProps }) => (
+ <pre
+ className={className}
+ style={{
+ ...style,
+ margin: 0,
+ width: "100%",
+ background: "transparent",
+ padding: "0.5rem",
+ fontSize: "0.75rem",
+ fontFamily: "var(--font-mono)",
+ overflow: "auto",
+ }}
+ >
+ {tokens.map((line, i) => (
+ <div key={i} {...getLineProps({ line })}>
+ {line.map((token, key) => (
+ <span key={key} {...getTokenProps({ token })} />
+ ))}
+ </div>
+ ))}
+ </pre>
+ )}
+ </Highlight>
</div>
);
});