From 2bde92264da2452dc9e010984ab82bc620b00471 Mon Sep 17 00:00:00 2001 From: Jan Potoms <2109932+Janpot@users.noreply.github.com> Date: Sun, 6 Nov 2022 13:05:26 +0100 Subject: [PATCH 01/24] WIP --- docs/package.json | 2 +- package.json | 2 +- packages/toolpad-app/package.json | 4 +- packages/toolpad-app/src/components/Link.tsx | 16 +- renovate.json | 5 - yarn.lock | 255 ++++++++++--------- 6 files changed, 148 insertions(+), 136 deletions(-) diff --git a/docs/package.json b/docs/package.json index f1f4ffbcba..ada0bf195d 100644 --- a/docs/package.json +++ b/docs/package.json @@ -60,7 +60,7 @@ "lz-string": "^1.4.4", "markdown-to-jsx": "^7.1.7", "marked": "^4.2.2", - "next": "12.2.2", + "next": "13.0.2", "next-transpile-modules": "^10.0.0", "nprogress": "^0.2.0", "postcss": "^8.4.18", diff --git a/package.json b/package.json index daaa3a16e5..90b8f71648 100644 --- a/package.json +++ b/package.json @@ -41,7 +41,7 @@ }, "devDependencies": { "@mui/monorepo": "https://github.com/mui/material-ui.git", - "@next/eslint-plugin-next": "12.3.1", + "@next/eslint-plugin-next": "13.0.2", "@playwright/test": "^1.27.1", "@swc/helpers": "^0.4.12", "@testing-library/jest-dom": "^5.16.5", diff --git a/packages/toolpad-app/package.json b/packages/toolpad-app/package.json index 431a1a13de..f3ff93cfa4 100644 --- a/packages/toolpad-app/package.json +++ b/packages/toolpad-app/package.json @@ -81,7 +81,7 @@ "lodash-es": "^4.17.21", "mitt": "^3.0.0", "monaco-editor": "0.34.1", - "next": "12.2.2", + "next": "13.0.2", "node-fetch": "^2.6.7", "node-fetch-har": "^1.0.1", "path-to-regexp": "^6.2.1", @@ -130,7 +130,7 @@ "@types/whatwg-url": "^11.0.0", "ajv": "^8.11.0", "eslint": "8.26.0", - "eslint-config-next": "^12.3.1", + "eslint-config-next": "^13.0.2", "eslint-config-prettier": "^8.5.0", "eslint-plugin-import": "^2.26.0", "formidable": "^2.0.1", diff --git a/packages/toolpad-app/src/components/Link.tsx b/packages/toolpad-app/src/components/Link.tsx index 9efeecde0d..b4d10bff70 100644 --- a/packages/toolpad-app/src/components/Link.tsx +++ b/packages/toolpad-app/src/components/Link.tsx @@ -10,15 +10,24 @@ const Anchor = styled('a')({}); interface NextLinkComposedProps extends Omit, 'href'>, - Omit { + Omit { to: NextLinkProps['href']; linkAs?: NextLinkProps['as']; - href?: NextLinkProps['href']; } export const NextLinkComposed = React.forwardRef( function NextLinkComposed(props, ref) { - const { to, linkAs, href, replace, scroll, shallow, prefetch, locale, ...other } = props; + const { + to, + linkAs, + replace, + scroll, + shallow, + prefetch, + legacyBehavior = true, + locale, + ...other + } = props; return ( diff --git a/renovate.json b/renovate.json index 84454cd375..0c84d68f39 100644 --- a/renovate.json +++ b/renovate.json @@ -69,11 +69,6 @@ "matchPackageNames": ["core-js"], "allowedVersions": "< 2.0.0" }, - { - "groupName": "next", - "matchPackageNames": ["next", "@next/eslint-plugin-next", "eslint-config-next"], - "allowedVersions": "1.2.2" - }, { "matchDepTypes": ["action"], "pinDigests": true diff --git a/yarn.lock b/yarn.lock index 177a834835..606900ea0e 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2033,82 +2033,82 @@ dependencies: webpack-bundle-analyzer "4.3.0" -"@next/env@12.2.2": - version "12.2.2" - resolved "https://registry.yarnpkg.com/@next/env/-/env-12.2.2.tgz#cc1a0a445bd254499e30f632968c03192455f4cc" - integrity sha512-BqDwE4gDl1F608TpnNxZqrCn6g48MBjvmWFEmeX5wEXDXh3IkAOw6ASKUgjT8H4OUePYFqghDFUss5ZhnbOUjw== +"@next/env@13.0.2": + version "13.0.2" + resolved "https://registry.yarnpkg.com/@next/env/-/env-13.0.2.tgz#5fbd7b4146175ae406edfb4a38b62de8c880c09d" + integrity sha512-Qb6WPuRriGIQ19qd6NBxpcrFOfj8ziN7l9eZUfwff5gl4zLXluqtuZPddYZM/oWjN53ZYcuRXzL+oowKyJeYtA== -"@next/eslint-plugin-next@12.3.1": - version "12.3.1" - resolved "https://registry.yarnpkg.com/@next/eslint-plugin-next/-/eslint-plugin-next-12.3.1.tgz#b821f27b0f175954d8d18e5d323fce040ecc79a6" - integrity sha512-sw+lTf6r6P0j+g/n9y4qdWWI2syPqZx+uc0+B/fRENqfR3KpSid6MIKqc9gNwGhJASazEQ5b3w8h4cAET213jw== +"@next/eslint-plugin-next@13.0.2": + version "13.0.2" + resolved "https://registry.yarnpkg.com/@next/eslint-plugin-next/-/eslint-plugin-next-13.0.2.tgz#89fe2144b37896f926e2bd9bed675396f1f697ce" + integrity sha512-W+fIIIaFU7Kct7Okx91C7XDRGolv/w2RUenX2yZFeeNVcuVzDIKUcNmckrYbYcwrNQUSXmtwrs3g8xwast0YtA== dependencies: glob "7.1.7" -"@next/swc-android-arm-eabi@12.2.2": - version "12.2.2" - resolved "https://registry.yarnpkg.com/@next/swc-android-arm-eabi/-/swc-android-arm-eabi-12.2.2.tgz#f6c4111e6371f73af6bf80c9accb3d96850a92cd" - integrity sha512-VHjuCHeq9qCprUZbsRxxM/VqSW8MmsUtqB5nEpGEgUNnQi/BTm/2aK8tl7R4D0twGKRh6g1AAeFuWtXzk9Z/vQ== - -"@next/swc-android-arm64@12.2.2": - version "12.2.2" - resolved "https://registry.yarnpkg.com/@next/swc-android-arm64/-/swc-android-arm64-12.2.2.tgz#b69de59c51e631a7600439e7a8993d6e82f3369e" - integrity sha512-v5EYzXUOSv0r9mO/2PX6mOcF53k8ndlu9yeFHVAWW1Dhw2jaJcvTRcCAwYYN8Q3tDg0nH3NbEltJDLKmcJOuVA== - -"@next/swc-darwin-arm64@12.2.2": - version "12.2.2" - resolved "https://registry.yarnpkg.com/@next/swc-darwin-arm64/-/swc-darwin-arm64-12.2.2.tgz#80157c91668eff95b72d052428c353eab0fc4c50" - integrity sha512-JCoGySHKGt+YBk7xRTFGx1QjrnCcwYxIo3yGepcOq64MoiocTM3yllQWeOAJU2/k9MH0+B5E9WUSme4rOCBbpA== - -"@next/swc-darwin-x64@12.2.2": - version "12.2.2" - resolved "https://registry.yarnpkg.com/@next/swc-darwin-x64/-/swc-darwin-x64-12.2.2.tgz#12be2f58e676fccff3d48a62921b9927ed295133" - integrity sha512-dztDtvfkhUqiqpXvrWVccfGhLe44yQ5tQ7B4tBfnsOR6vxzI9DNPHTlEOgRN9qDqTAcFyPxvg86mn4l8bB9Jcw== - -"@next/swc-freebsd-x64@12.2.2": - version "12.2.2" - resolved "https://registry.yarnpkg.com/@next/swc-freebsd-x64/-/swc-freebsd-x64-12.2.2.tgz#de1363431a49059f1efb8c0f86ce6a79c53b3a95" - integrity sha512-JUnXB+2xfxqsAvhFLPJpU1NeyDsvJrKoOjpV7g3Dxbno2Riu4tDKn3kKF886yleAuD/1qNTUCpqubTvbbT2VoA== - -"@next/swc-linux-arm-gnueabihf@12.2.2": - version "12.2.2" - resolved "https://registry.yarnpkg.com/@next/swc-linux-arm-gnueabihf/-/swc-linux-arm-gnueabihf-12.2.2.tgz#d5b8e0d1bb55bbd9db4d2fec018217471dc8b9e6" - integrity sha512-XeYC/qqPLz58R4pjkb+x8sUUxuGLnx9QruC7/IGkK68yW4G17PHwKI/1njFYVfXTXUukpWjcfBuauWwxp9ke7Q== - -"@next/swc-linux-arm64-gnu@12.2.2": - version "12.2.2" - resolved "https://registry.yarnpkg.com/@next/swc-linux-arm64-gnu/-/swc-linux-arm64-gnu-12.2.2.tgz#3bc75984e1d5ec8f59eb53702cc382d8e1be2061" - integrity sha512-d6jT8xgfKYFkzR7J0OHo2D+kFvY/6W8qEo6/hmdrTt6AKAqxs//rbbcdoyn3YQq1x6FVUUd39zzpezZntg9Naw== - -"@next/swc-linux-arm64-musl@12.2.2": - version "12.2.2" - resolved "https://registry.yarnpkg.com/@next/swc-linux-arm64-musl/-/swc-linux-arm64-musl-12.2.2.tgz#270db73e07a18d999f61e79a917943fa5bc1ef56" - integrity sha512-rIZRFxI9N/502auJT1i7coas0HTHUM+HaXMyJiCpnY8Rimbo0495ir24tzzHo3nQqJwcflcPTwEh/DV17sdv9A== - -"@next/swc-linux-x64-gnu@12.2.2": - version "12.2.2" - resolved "https://registry.yarnpkg.com/@next/swc-linux-x64-gnu/-/swc-linux-x64-gnu-12.2.2.tgz#e6c72fa20478552e898c434f4d4c0c5e89d2ea78" - integrity sha512-ir1vNadlUDj7eQk15AvfhG5BjVizuCHks9uZwBfUgT5jyeDCeRvaDCo1+Q6+0CLOAnYDR/nqSCvBgzG2UdFh9A== - -"@next/swc-linux-x64-musl@12.2.2": - version "12.2.2" - resolved "https://registry.yarnpkg.com/@next/swc-linux-x64-musl/-/swc-linux-x64-musl-12.2.2.tgz#b9ef9efe2c401839cdefa5e70402386aafdce15a" - integrity sha512-bte5n2GzLN3O8JdSFYWZzMgEgDHZmRz5wiispiiDssj4ik3l8E7wq/czNi8RmIF+ioj2sYVokUNa/ekLzrESWw== - -"@next/swc-win32-arm64-msvc@12.2.2": - version "12.2.2" - resolved "https://registry.yarnpkg.com/@next/swc-win32-arm64-msvc/-/swc-win32-arm64-msvc-12.2.2.tgz#18fa7ec7248da3a7926a0601d9ececc53ac83157" - integrity sha512-ZUGCmcDmdPVSAlwJ/aD+1F9lYW8vttseiv4n2+VCDv5JloxiX9aY32kYZaJJO7hmTLNrprvXkb4OvNuHdN22Jg== - -"@next/swc-win32-ia32-msvc@12.2.2": - version "12.2.2" - resolved "https://registry.yarnpkg.com/@next/swc-win32-ia32-msvc/-/swc-win32-ia32-msvc-12.2.2.tgz#54936e84f4a219441d051940354da7cd3eafbb4f" - integrity sha512-v7ykeEDbr9eXiblGSZiEYYkWoig6sRhAbLKHUHQtk8vEWWVEqeXFcxmw6LRrKu5rCN1DY357UlYWToCGPQPCRA== - -"@next/swc-win32-x64-msvc@12.2.2": - version "12.2.2" - resolved "https://registry.yarnpkg.com/@next/swc-win32-x64-msvc/-/swc-win32-x64-msvc-12.2.2.tgz#7460be700a60d75816f01109400b51fe929d7e89" - integrity sha512-2D2iinWUL6xx8D9LYVZ5qi7FP6uLAoWymt8m8aaG2Ld/Ka8/k723fJfiklfuAcwOxfufPJI+nRbT5VcgHGzHAQ== +"@next/swc-android-arm-eabi@13.0.2": + version "13.0.2" + resolved "https://registry.yarnpkg.com/@next/swc-android-arm-eabi/-/swc-android-arm-eabi-13.0.2.tgz#66669b8aab5062f554b8e9905d855679aabf0342" + integrity sha512-X54UQCTFyOGnJP//Z71dPPlp4BCYcQL2ncikKXQcPzVpqPs4C3m+tKC8ivBNH6edAXkppwsLRz1/yQwgSZ9Swg== + +"@next/swc-android-arm64@13.0.2": + version "13.0.2" + resolved "https://registry.yarnpkg.com/@next/swc-android-arm64/-/swc-android-arm64-13.0.2.tgz#c0641d30525e0fb22bf1e2baf6c461d2d9e52f1a" + integrity sha512-1P00Kv8uKaLubqo7JzPrTqgFAzSOmfb8iwqJrOb9in5IvTRtNGlkR4hU0sXzqbQNM/+SaYxze6Z5ry1IDyb/cQ== + +"@next/swc-darwin-arm64@13.0.2": + version "13.0.2" + resolved "https://registry.yarnpkg.com/@next/swc-darwin-arm64/-/swc-darwin-arm64-13.0.2.tgz#d7e01a33393e83456dbfdc41446bb8a923968ff7" + integrity sha512-1zGIOkInkOLRv0QQGZ+3wffYsyKI4vIy62LYTvDWUn7TAYqnmXwougp9NSLqDeagLwgsv2URrykyAFixA/YqxA== + +"@next/swc-darwin-x64@13.0.2": + version "13.0.2" + resolved "https://registry.yarnpkg.com/@next/swc-darwin-x64/-/swc-darwin-x64-13.0.2.tgz#d4a3fbe51edf871a675d89a7afdc78174d1e5841" + integrity sha512-ECDAjoMP1Y90cARaelS6X+k6BQx+MikAYJ8f/eaJrLur44NIOYc9HA/dgcTp5jenguY4yT8V+HCquLjAVle6fA== + +"@next/swc-freebsd-x64@13.0.2": + version "13.0.2" + resolved "https://registry.yarnpkg.com/@next/swc-freebsd-x64/-/swc-freebsd-x64-13.0.2.tgz#1b54c3f38d3b36f86663a8dfcc81ea05e01f5172" + integrity sha512-2DcL/ofQdBnQX3IoI9sjlIAyLCD1oZoUBuhrhWbejvBQjutWrI0JTEv9uG69WcxWhVMm3BCsjv8GK2/68OKp7A== + +"@next/swc-linux-arm-gnueabihf@13.0.2": + version "13.0.2" + resolved "https://registry.yarnpkg.com/@next/swc-linux-arm-gnueabihf/-/swc-linux-arm-gnueabihf-13.0.2.tgz#18495cff32c0b2182cfbf677614219d7072214da" + integrity sha512-Y3OQF1CSBSWW2vGkmvOIuOUNqOq8qX7f1ZpcKUVWP3/Uq++DZmVi9d18lgnSe1I3QFqc+nXWyun9ljsN83j0sw== + +"@next/swc-linux-arm64-gnu@13.0.2": + version "13.0.2" + resolved "https://registry.yarnpkg.com/@next/swc-linux-arm64-gnu/-/swc-linux-arm64-gnu-13.0.2.tgz#5fb2563651166c3c6f32bf9e2f9cc6a16a9ef783" + integrity sha512-mNyzwsFF6kwZYEjnGicx9ksDZYEZvyzEc1BtCu8vdZi/v8UeixQwCiAT6FyYX9uxMPEkzk8qiU0t0u9gvltsKw== + +"@next/swc-linux-arm64-musl@13.0.2": + version "13.0.2" + resolved "https://registry.yarnpkg.com/@next/swc-linux-arm64-musl/-/swc-linux-arm64-musl-13.0.2.tgz#b9f33c5e17cfe04aa5769b717284cf80865761e6" + integrity sha512-M6SdYjWgRrY3tJBxz0663zCRPTu5BRONmxlftKWWHv9LjAJ59neTLaGj4rp0A08DkJglZIoCkLOzLrzST6TGag== + +"@next/swc-linux-x64-gnu@13.0.2": + version "13.0.2" + resolved "https://registry.yarnpkg.com/@next/swc-linux-x64-gnu/-/swc-linux-x64-gnu-13.0.2.tgz#29efcc2fd0122689d7e06c5b6b0883fe495db2bf" + integrity sha512-pi63RoxvG4ES1KS06Zpm0MATVIXTs/TIbLbdckeLoM40u1d3mQl/+hSSrLRSxzc2OtyL8fh92sM4gkJrQXAMAw== + +"@next/swc-linux-x64-musl@13.0.2": + version "13.0.2" + resolved "https://registry.yarnpkg.com/@next/swc-linux-x64-musl/-/swc-linux-x64-musl-13.0.2.tgz#d68fdf6eefc57813fa91559c7089b49d6131ecab" + integrity sha512-9Pv91gfYnDONgjtRm78n64b/c54+azeHtlnqBLTnIFWSMBDRl1/WDkhKWIj3fBGPLimtK7Tko3ULR3og9RRUPw== + +"@next/swc-win32-arm64-msvc@13.0.2": + version "13.0.2" + resolved "https://registry.yarnpkg.com/@next/swc-win32-arm64-msvc/-/swc-win32-arm64-msvc-13.0.2.tgz#acdcb3023045f60cca510f659a2349895e6405bd" + integrity sha512-Nvewe6YZaizAkGHHprbMkYqQulBjZCHKBGKeFPwoPtOA+a2Qi4pZzc/qXFyC5/2A6Z0mr2U1zg9rd04WBYMwBw== + +"@next/swc-win32-ia32-msvc@13.0.2": + version "13.0.2" + resolved "https://registry.yarnpkg.com/@next/swc-win32-ia32-msvc/-/swc-win32-ia32-msvc-13.0.2.tgz#a78ee9211471768febac9df915c2a8dbbcd05e41" + integrity sha512-ZUBYGZw5G3QrqDpRq1EWi3aHmvPZM8ijK5TFL6UbH16cYQ0JpANmuG2P66KB93Qe/lWWzbeAZk/tj1XqwoCuPA== + +"@next/swc-win32-x64-msvc@13.0.2": + version "13.0.2" + resolved "https://registry.yarnpkg.com/@next/swc-win32-x64-msvc/-/swc-win32-x64-msvc-13.0.2.tgz#e86c2de910cd68a17974db5556d4588737412c68" + integrity sha512-fA9uW1dm7C0mEYGcKlbmLcVm2sKcye+1kPxh2cM4jVR+kQQMtHWsjIzeSpe2grQLSDan06z4n6hbr8b1c3hA8w== "@nodelib/fs.scandir@2.1.5": version "2.1.5" @@ -2612,10 +2612,10 @@ dependencies: "@sinonjs/commons" "^1.7.0" -"@swc/helpers@0.4.2": - version "0.4.2" - resolved "https://registry.yarnpkg.com/@swc/helpers/-/helpers-0.4.2.tgz#ed1f6997ffbc22396665d9ba74e2a5c0a2d782f8" - integrity sha512-556Az0VX7WR6UdoTn4htt/l3zPQ7bsQWK+HqdG4swV7beUCxo/BqmvbOpUkTIm/9ih86LIf1qsUnywNL3obGHw== +"@swc/helpers@0.4.11": + version "0.4.11" + resolved "https://registry.yarnpkg.com/@swc/helpers/-/helpers-0.4.11.tgz#db23a376761b3d31c26502122f349a21b592c8de" + integrity sha512-rEUrBSGIoSFuYxwBYtlUFMlE2CwGhmW+w9355/5oduSw8e5h2+Tj4UrAGNNgP9915++wj5vkQo0UuOBqOAq4nw== dependencies: tslib "^2.4.0" @@ -4385,11 +4385,16 @@ camelize@^1.0.0: resolved "https://registry.yarnpkg.com/camelize/-/camelize-1.0.0.tgz#164a5483e630fa4321e5af07020e531831b2609b" integrity sha512-W2lPwkBkMZwFlPCXhIlYgxu+7gC/NUlCtdK652DAJ1JdgV0sTrvuPFshNPrFa1TY2JOkLhgdeEBplB4ezEa+xg== -caniuse-lite@^1.0.30001332, caniuse-lite@^1.0.30001400, caniuse-lite@^1.0.30001426: +caniuse-lite@^1.0.30001400, caniuse-lite@^1.0.30001426: version "1.0.30001427" resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001427.tgz#d3a749f74be7ae0671fbec3a4eea18576e8ad646" integrity sha512-lfXQ73oB9c8DP5Suxaszm+Ta2sr/4tf8+381GkIm1MLj/YdLf+rEDyDSRCzeltuyTVGm+/s18gdZ0q+Wmp8VsQ== +caniuse-lite@^1.0.30001406: + version "1.0.30001430" + resolved "https://registry.yarnpkg.com/caniuse-lite/-/caniuse-lite-1.0.30001430.tgz#638a8ae00b5a8a97e66ff43733b2701f81b101fa" + integrity sha512-IB1BXTZKPDVPM7cnV4iaKaHxckvdr/3xtctB3f7Hmenx3qYBhGtTZ//7EllK66aKXW98Lx0+7Yr0kxBtIt3tzg== + chainsaw@~0.1.0: version "0.1.0" resolved "https://registry.yarnpkg.com/chainsaw/-/chainsaw-0.1.0.tgz#5eab50b28afe58074d0d58291388828b5e5fbc98" @@ -4543,6 +4548,11 @@ cli-width@^4.0.0: resolved "https://registry.yarnpkg.com/cli-width/-/cli-width-4.0.0.tgz#a5622f6a3b0a9e3e711a25f099bf2399f608caf6" integrity sha512-ZksGS2xpa/bYkNzN3BAw1wEjsLV/ZKOf/CCrJ/QOBsxx6fOARIkwTutxp1XIOIohi6HKmOFjMoK/XaqDVUpEEw== +client-only@0.0.1: + version "0.0.1" + resolved "https://registry.yarnpkg.com/client-only/-/client-only-0.0.1.tgz#38bba5d403c41ab150bff64a95c85013cf73bca1" + integrity sha512-IV3Ou0jSMzZrd3pZ48nLkT9DA7Ag1pnPzaiQhpW7c3RbcqqzvzzVu+L8gfqMp/8IM2MQtSiqaCxrrcfu8I8rMA== + clipboard-copy@^4.0.1: version "4.0.1" resolved "https://registry.yarnpkg.com/clipboard-copy/-/clipboard-copy-4.0.1.tgz#326ef9726d4ffe72d9a82a7bbe19379de692017d" @@ -5746,12 +5756,12 @@ eslint-config-airbnb@^18.2.0: object.assign "^4.1.2" object.entries "^1.1.2" -eslint-config-next@^12.3.1: - version "12.3.1" - resolved "https://registry.yarnpkg.com/eslint-config-next/-/eslint-config-next-12.3.1.tgz#5d4eb0b7903cea81fd0d5106601d3afb0a453ff4" - integrity sha512-EN/xwKPU6jz1G0Qi6Bd/BqMnHLyRAL0VsaQaWA7F3KkjAgZHi4f1uL1JKGWNxdQpHTW/sdGONBd0bzxUka/DJg== +eslint-config-next@^13.0.2: + version "13.0.2" + resolved "https://registry.yarnpkg.com/eslint-config-next/-/eslint-config-next-13.0.2.tgz#7c87837821ea7468e018ca41f3bf6fa37d53db68" + integrity sha512-SrrHp+zBDYLjOFZdM5b9aW/pliK687Xxfa+qpDuL08Z04ReHhmz3L+maXaAqgrEVZHQximP7nh0El4yNDJW+CA== dependencies: - "@next/eslint-plugin-next" "12.3.1" + "@next/eslint-plugin-next" "13.0.2" "@rushstack/eslint-patch" "^1.1.3" "@typescript-eslint/parser" "^5.21.0" eslint-import-resolver-node "^0.3.6" @@ -9081,7 +9091,7 @@ nanoid@^2.0.3: resolved "https://registry.yarnpkg.com/nanoid/-/nanoid-2.1.11.tgz#ec24b8a758d591561531b4176a01e3ab4f0f0280" integrity sha512-s/snB+WGm6uwi0WjsZdaVcuf3KJXlfGl2LcxgwkEwJF0D/BWzVWAZW/XY4bFaiR7s0Jk3FPvlnepg1H1b1UwlA== -nanoid@^3.1.30, nanoid@^3.3.4: +nanoid@^3.3.4: version "3.3.4" resolved "https://registry.yarnpkg.com/nanoid/-/nanoid-3.3.4.tgz#730b67e3cd09e2deacf03c027c81c9d9dbc5e8ab" integrity sha512-MqBkQh/OHTS2egovRtLk45wEyNXwF+cokD+1YPf9u5VfJiRdAiRwB2froX5Co9Rh20xs4siNPm8naNotSD6RBw== @@ -9113,31 +9123,31 @@ next-transpile-modules@^10.0.0: dependencies: enhanced-resolve "^5.10.0" -next@12.2.2: - version "12.2.2" - resolved "https://registry.yarnpkg.com/next/-/next-12.2.2.tgz#029bf5e4a18a891ca5d05b189b7cd983fd22c072" - integrity sha512-zAYFY45aBry/PlKONqtlloRFqU/We3zWYdn2NoGvDZkoYUYQSJC8WMcalS5C19MxbCZLUVCX7D7a6gTGgl2yLg== - dependencies: - "@next/env" "12.2.2" - "@swc/helpers" "0.4.2" - caniuse-lite "^1.0.30001332" - postcss "8.4.5" - styled-jsx "5.0.2" - use-sync-external-store "1.1.0" +next@13.0.2: + version "13.0.2" + resolved "https://registry.yarnpkg.com/next/-/next-13.0.2.tgz#b8c8642c70f736ed91105645391d335fc51c8f62" + integrity sha512-uQ5z5e4D9mOe8+upy6bQdYYjo/kk1v3jMW87kTy2TgAyAsEO+CkwRnMgyZ4JoHEnhPZLHwh7dk0XymRNLe1gFw== + dependencies: + "@next/env" "13.0.2" + "@swc/helpers" "0.4.11" + caniuse-lite "^1.0.30001406" + postcss "8.4.14" + styled-jsx "5.1.0" + use-sync-external-store "1.2.0" optionalDependencies: - "@next/swc-android-arm-eabi" "12.2.2" - "@next/swc-android-arm64" "12.2.2" - "@next/swc-darwin-arm64" "12.2.2" - "@next/swc-darwin-x64" "12.2.2" - "@next/swc-freebsd-x64" "12.2.2" - "@next/swc-linux-arm-gnueabihf" "12.2.2" - "@next/swc-linux-arm64-gnu" "12.2.2" - "@next/swc-linux-arm64-musl" "12.2.2" - "@next/swc-linux-x64-gnu" "12.2.2" - "@next/swc-linux-x64-musl" "12.2.2" - "@next/swc-win32-arm64-msvc" "12.2.2" - "@next/swc-win32-ia32-msvc" "12.2.2" - "@next/swc-win32-x64-msvc" "12.2.2" + "@next/swc-android-arm-eabi" "13.0.2" + "@next/swc-android-arm64" "13.0.2" + "@next/swc-darwin-arm64" "13.0.2" + "@next/swc-darwin-x64" "13.0.2" + "@next/swc-freebsd-x64" "13.0.2" + "@next/swc-linux-arm-gnueabihf" "13.0.2" + "@next/swc-linux-arm64-gnu" "13.0.2" + "@next/swc-linux-arm64-musl" "13.0.2" + "@next/swc-linux-x64-gnu" "13.0.2" + "@next/swc-linux-x64-musl" "13.0.2" + "@next/swc-win32-arm64-msvc" "13.0.2" + "@next/swc-win32-ia32-msvc" "13.0.2" + "@next/swc-win32-x64-msvc" "13.0.2" node-addon-api@^3.2.1: version "3.2.1" @@ -10093,14 +10103,14 @@ postcss-value-parser@^4.0.2, postcss-value-parser@^4.2.0: resolved "https://registry.yarnpkg.com/postcss-value-parser/-/postcss-value-parser-4.2.0.tgz#723c09920836ba6d3e5af019f92bc0971c02e514" integrity sha512-1NNCs6uurfkVbeXG4S8JFT9t19m45ICnif8zWLd5oPSZ50QnwMfK+H3jv408d4jw/7Bttv5axS5IiHoLaVNHeQ== -postcss@8.4.5: - version "8.4.5" - resolved "https://registry.yarnpkg.com/postcss/-/postcss-8.4.5.tgz#bae665764dfd4c6fcc24dc0fdf7e7aa00cc77f95" - integrity sha512-jBDboWM8qpaqwkMwItqTQTiFikhs/67OYVvblFFTM7MrZjt6yMKd6r2kgXizEbTTljacm4NldIlZnhbjr84QYg== +postcss@8.4.14: + version "8.4.14" + resolved "https://registry.yarnpkg.com/postcss/-/postcss-8.4.14.tgz#ee9274d5622b4858c1007a74d76e42e56fd21caf" + integrity sha512-E398TUmfAYFPBSdzgeieK2Y1+1cpdxJx8yXbK/m57nRhKSmk1GB2tO4lbLBtlkfPQTDKfe4Xqv1ASWPpayPEig== dependencies: - nanoid "^3.1.30" + nanoid "^3.3.4" picocolors "^1.0.0" - source-map-js "^1.0.1" + source-map-js "^1.0.2" postcss@^8.4.18: version "8.4.18" @@ -11134,7 +11144,7 @@ source-map-js@^0.6.2: resolved "https://registry.yarnpkg.com/source-map-js/-/source-map-js-0.6.2.tgz#0bb5de631b41cfbda6cfba8bd05a80efdfd2385e" integrity sha512-/3GptzWzu0+0MBQFrDKzw/DvvMTUORvgY6k6jd/VS6iCR4RDTKWH6v6WPwQoUO8667uQEf9Oe38DxAYWY5F/Ug== -source-map-js@^1.0.1, source-map-js@^1.0.2: +source-map-js@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/source-map-js/-/source-map-js-1.0.2.tgz#adbc361d9c62df380125e7f161f71c826f1e490c" integrity sha512-R0XvVJ9WusLiqTCEiGCmICCMplcCkIwwR11mOSD9CR5u+IXYdiseeEuXCVAjS54zqwkLcPNnmU4OeJ6tUrWhDw== @@ -11479,10 +11489,12 @@ styled-components@^5.3.6: shallowequal "^1.1.0" supports-color "^5.5.0" -styled-jsx@5.0.2: - version "5.0.2" - resolved "https://registry.yarnpkg.com/styled-jsx/-/styled-jsx-5.0.2.tgz#ff230fd593b737e9e68b630a694d460425478729" - integrity sha512-LqPQrbBh3egD57NBcHET4qcgshPks+yblyhPlH2GY8oaDgKs8SK4C3dBh3oSJjgzJ3G5t1SYEZGHkP+QEpX9EQ== +styled-jsx@5.1.0: + version "5.1.0" + resolved "https://registry.yarnpkg.com/styled-jsx/-/styled-jsx-5.1.0.tgz#4a5622ab9714bd3fcfaeec292aa555871f057563" + integrity sha512-/iHaRJt9U7T+5tp6TRelLnqBqiaIT0HsO0+vgyj8hK2KUk7aejFqRrumqPUlAqDwAj8IbS/1hk3IhBAAK/FCUQ== + dependencies: + client-only "0.0.1" "stylis-plugin-rtl-sc@npm:stylis-plugin-rtl@^2.1.1", stylis-plugin-rtl@^2.1.1: version "2.1.1" @@ -12031,12 +12043,7 @@ url-template@^2.0.8: resolved "https://registry.yarnpkg.com/url-template/-/url-template-2.0.8.tgz#fc565a3cccbff7730c775f5641f9555791439f21" integrity sha512-XdVKMF4SJ0nP/O7XIPB0JwAEuT9lDIYnNsK8yGVe43y0AWoKeJNdv3ZNWh7ksJ6KqQFjOO6ox/VEitLnaVNufw== -use-sync-external-store@1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/use-sync-external-store/-/use-sync-external-store-1.1.0.tgz#3343c3fe7f7e404db70f8c687adf5c1652d34e82" - integrity sha512-SEnieB2FPKEVne66NpXPd1Np4R1lTNKfjuy3XdIoPQKYBAFdzbzSZlSn1KJZUiihQLQC5Znot4SBz1EOTBwQAQ== - -use-sync-external-store@^1.2.0: +use-sync-external-store@1.2.0, use-sync-external-store@^1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/use-sync-external-store/-/use-sync-external-store-1.2.0.tgz#7dbefd6ef3fe4e767a0cf5d7287aacfb5846928a" integrity sha512-eEgnFxGQ1Ife9bzYs6VLi8/4X6CObHMw9Qr9tPY43iKwsPw8xE8+EFsf/2cFZ5S3esXgpWgtSCtLNS41F+sKPA== From 07c2f3b76ac435c2f57f8a38ea9cbca3936bddbe Mon Sep 17 00:00:00 2001 From: Jan Potoms <2109932+Janpot@users.noreply.github.com> Date: Sun, 6 Nov 2022 13:53:42 +0100 Subject: [PATCH 02/24] monorepo --- docs/package.json | 2 +- yarn.lock | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/docs/package.json b/docs/package.json index ada0bf195d..3fa93dc7a6 100644 --- a/docs/package.json +++ b/docs/package.json @@ -28,7 +28,7 @@ "@emotion/styled": "^11.10.5", "@mui/icons-material": "^5.10.9", "@mui/material": "^5.10.12", - "@mui/monorepo": "https://github.com/mui/material-ui.git", + "@mui/monorepo": "https://github.com/mnajdova/material-ui.git#docs/upgrade-nextjs-13", "@mui/styles": "^5.10.10", "@mui/utils": "^5.10.9", "@trendmicro/react-interpolate": "^0.5.5", diff --git a/yarn.lock b/yarn.lock index 606900ea0e..6fc0cd1537 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1853,6 +1853,10 @@ react-is "^18.2.0" react-transition-group "^4.4.5" +"@mui/monorepo@https://github.com/mnajdova/material-ui.git#docs/upgrade-nextjs-13": + version "5.10.12" + resolved "https://github.com/mnajdova/material-ui.git#07c5477bfe688260da62ff851bdb1879e593ac37" + "@mui/monorepo@https://github.com/mui/material-ui.git": version "5.10.9" resolved "https://github.com/mui/material-ui.git#27f9a61821a3d4d76ca0a085f9c779356ccd7753" From 8b97c6a76e1f9a1f56fd5d88331add91904387b7 Mon Sep 17 00:00:00 2001 From: Jan Potoms <2109932+Janpot@users.noreply.github.com> Date: Sun, 6 Nov 2022 13:57:20 +0100 Subject: [PATCH 03/24] remove legacy --- packages/toolpad-app/middleware.ts | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) diff --git a/packages/toolpad-app/middleware.ts b/packages/toolpad-app/middleware.ts index e72c8ededd..1d33b042b0 100644 --- a/packages/toolpad-app/middleware.ts +++ b/packages/toolpad-app/middleware.ts @@ -1,16 +1,6 @@ -import { - NextRequest, - NextResponse, - // @ts-expect-error - // TODO: As soon as next/server exports this member: - // - remove ` as NextURLPattern` from this line - // - remove the line below with `const URLPattern = ...` - URLPattern as NextURLPattern, -} from 'next/server'; +import { NextRequest, NextResponse, URLPattern } from 'next/server'; import { checkBasicAuthHeader } from './src/server/basicAuth'; -const URLPattern = NextURLPattern || (global as any).URLPattern; - const BASIC_AUTH_WHITELIST = [ // Healthcheck must always be public new URLPattern({ pathname: '/health-check' }), From 0218d24dbeb5c74c0b34c5dbc75dbde7060885a0 Mon Sep 17 00:00:00 2001 From: Jan Potoms <2109932+Janpot@users.noreply.github.com> Date: Sun, 6 Nov 2022 15:31:28 +0100 Subject: [PATCH 04/24] Try to scope further down --- packages/toolpad-app/next.config.mjs | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/packages/toolpad-app/next.config.mjs b/packages/toolpad-app/next.config.mjs index df6d5062bb..7f4346e2d2 100644 --- a/packages/toolpad-app/next.config.mjs +++ b/packages/toolpad-app/next.config.mjs @@ -132,8 +132,10 @@ export default withBundleAnalyzer( { // Support global CSS in monaco-editor // Adapted from next-transpile-modules. - const extraCssIssuer = /(\/|\\)node_modules(\/|\\)monaco-editor(\/|\\)/; - const modulesPaths = [path.dirname(require.resolve('monaco-editor/package.json'))]; + const extraCssIssuer = /(\/|\\)node_modules(\/|\\)monaco-editor(\/|\\).*\.js$/; + const modulesPaths = [ + path.resolve(path.dirname(require.resolve('monaco-editor/package.json')), './esm'), + ]; config.module = config.module ?? {}; config.module.rules = config.module.rules ?? []; From bf9530b4baacd6fcdccc83fe69163f52bdfd03c8 Mon Sep 17 00:00:00 2001 From: Jan Potoms <2109932+Janpot@users.noreply.github.com> Date: Sun, 6 Nov 2022 15:44:05 +0100 Subject: [PATCH 05/24] try removing css support --- packages/toolpad-app/next.config.mjs | 80 ++++++++++++++-------------- 1 file changed, 40 insertions(+), 40 deletions(-) diff --git a/packages/toolpad-app/next.config.mjs b/packages/toolpad-app/next.config.mjs index 7f4346e2d2..39b0d3f57b 100644 --- a/packages/toolpad-app/next.config.mjs +++ b/packages/toolpad-app/next.config.mjs @@ -129,46 +129,46 @@ export default withBundleAnalyzer( path: false, }; - { - // Support global CSS in monaco-editor - // Adapted from next-transpile-modules. - const extraCssIssuer = /(\/|\\)node_modules(\/|\\)monaco-editor(\/|\\).*\.js$/; - const modulesPaths = [ - path.resolve(path.dirname(require.resolve('monaco-editor/package.json')), './esm'), - ]; - - config.module = config.module ?? {}; - config.module.rules = config.module.rules ?? []; - const nextCssLoaders = /** @type {import('webpack').RuleSetRule} */ ( - config.module.rules.find( - (rule) => typeof rule === 'object' && typeof rule.oneOf === 'object', - ) - ); - - // Add support for Global CSS imports in transpiled modules - if (nextCssLoaders) { - const nextGlobalCssLoader = nextCssLoaders.oneOf?.find( - (rule) => - rule.sideEffects === true && - rule.test instanceof RegExp && - regexEqual(rule.test, /(? typeof rule === 'object' && typeof rule.oneOf === 'object', + // ) + // ); + // + // // Add support for Global CSS imports in transpiled modules + // if (nextCssLoaders) { + // const nextGlobalCssLoader = nextCssLoaders.oneOf?.find( + // (rule) => + // rule.sideEffects === true && + // rule.test instanceof RegExp && + // regexEqual(rule.test, /(? Date: Sun, 6 Nov 2022 15:50:31 +0100 Subject: [PATCH 06/24] sjhf --- packages/toolpad-app/next.config.mjs | 82 ++++++++++++++-------------- 1 file changed, 42 insertions(+), 40 deletions(-) diff --git a/packages/toolpad-app/next.config.mjs b/packages/toolpad-app/next.config.mjs index 39b0d3f57b..82c6d295b1 100644 --- a/packages/toolpad-app/next.config.mjs +++ b/packages/toolpad-app/next.config.mjs @@ -3,6 +3,8 @@ import * as path from 'path'; import { withSentryConfig } from '@sentry/nextjs'; import createBundleAnalyzer from '@next/bundle-analyzer'; +const DO_CSS = false; + const withBundleAnalyzer = createBundleAnalyzer({ enabled: !!process.env.ANALYZE }); // TODO: remove when https://github.com/getsentry/sentry-javascript/issues/3852 gets resolved @@ -129,46 +131,46 @@ export default withBundleAnalyzer( path: false, }; - // { - // // Support global CSS in monaco-editor - // // Adapted from next-transpile-modules. - // const extraCssIssuer = /(\/|\\)node_modules(\/|\\)monaco-editor(\/|\\).*\.js$/; - // const modulesPaths = [ - // path.resolve(path.dirname(require.resolve('monaco-editor/package.json')), './esm'), - // ]; - // - // config.module = config.module ?? {}; - // config.module.rules = config.module.rules ?? []; - // const nextCssLoaders = /** @type {import('webpack').RuleSetRule} */ ( - // config.module.rules.find( - // (rule) => typeof rule === 'object' && typeof rule.oneOf === 'object', - // ) - // ); - // - // // Add support for Global CSS imports in transpiled modules - // if (nextCssLoaders) { - // const nextGlobalCssLoader = nextCssLoaders.oneOf?.find( - // (rule) => - // rule.sideEffects === true && - // rule.test instanceof RegExp && - // regexEqual(rule.test, /(? typeof rule === 'object' && typeof rule.oneOf === 'object', + ) + ); + + // Add support for Global CSS imports in transpiled modules + if (nextCssLoaders) { + const nextGlobalCssLoader = nextCssLoaders.oneOf?.find( + (rule) => + rule.sideEffects === true && + rule.test instanceof RegExp && + regexEqual(rule.test, /(? Date: Sun, 6 Nov 2022 16:23:46 +0100 Subject: [PATCH 07/24] sourcemaps --- packages/toolpad-app/next.config.mjs | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/packages/toolpad-app/next.config.mjs b/packages/toolpad-app/next.config.mjs index 82c6d295b1..fc94f320f0 100644 --- a/packages/toolpad-app/next.config.mjs +++ b/packages/toolpad-app/next.config.mjs @@ -3,8 +3,6 @@ import * as path from 'path'; import { withSentryConfig } from '@sentry/nextjs'; import createBundleAnalyzer from '@next/bundle-analyzer'; -const DO_CSS = false; - const withBundleAnalyzer = createBundleAnalyzer({ enabled: !!process.env.ANALYZE }); // TODO: remove when https://github.com/getsentry/sentry-javascript/issues/3852 gets resolved @@ -108,7 +106,7 @@ export default withBundleAnalyzer( /** @type {import('next').NextConfig} */ ({ reactStrictMode: true, poweredByHeader: false, - productionBrowserSourceMaps: true, + // productionBrowserSourceMaps: true, eslint: { // We're running this as part of the monorepo eslint ignoreDuringBuilds: true, @@ -131,7 +129,7 @@ export default withBundleAnalyzer( path: false, }; - if (DO_CSS) { + { // Support global CSS in monaco-editor // Adapted from next-transpile-modules. const extraCssIssuer = /(\/|\\)node_modules(\/|\\)monaco-editor(\/|\\).*\.js$/; From 28d92dcbb468bd92b2d9dff3d2c1cb8f03f6f924 Mon Sep 17 00:00:00 2001 From: Jan Potoms <2109932+Janpot@users.noreply.github.com> Date: Sun, 6 Nov 2022 16:33:22 +0100 Subject: [PATCH 08/24] zis --- packages/toolpad-app/next.config.mjs | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/packages/toolpad-app/next.config.mjs b/packages/toolpad-app/next.config.mjs index fc94f320f0..444cda448b 100644 --- a/packages/toolpad-app/next.config.mjs +++ b/packages/toolpad-app/next.config.mjs @@ -1,8 +1,10 @@ import { createRequire } from 'module'; import * as path from 'path'; -import { withSentryConfig } from '@sentry/nextjs'; +// import { withSentryConfig } from '@sentry/nextjs'; import createBundleAnalyzer from '@next/bundle-analyzer'; +const withSentryConfig = (/** @type {import("next").NextConfig} */ cfg) => cfg; + const withBundleAnalyzer = createBundleAnalyzer({ enabled: !!process.env.ANALYZE }); // TODO: remove when https://github.com/getsentry/sentry-javascript/issues/3852 gets resolved @@ -106,7 +108,7 @@ export default withBundleAnalyzer( /** @type {import('next').NextConfig} */ ({ reactStrictMode: true, poweredByHeader: false, - // productionBrowserSourceMaps: true, + productionBrowserSourceMaps: true, eslint: { // We're running this as part of the monorepo eslint ignoreDuringBuilds: true, From 3c769cdd48a126f4483765b93a41609135524e0b Mon Sep 17 00:00:00 2001 From: Jan Potoms <2109932+Janpot@users.noreply.github.com> Date: Sun, 6 Nov 2022 16:39:25 +0100 Subject: [PATCH 09/24] dkajs --- packages/toolpad-app/next.config.mjs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/packages/toolpad-app/next.config.mjs b/packages/toolpad-app/next.config.mjs index 444cda448b..999e710b3d 100644 --- a/packages/toolpad-app/next.config.mjs +++ b/packages/toolpad-app/next.config.mjs @@ -3,7 +3,9 @@ import * as path from 'path'; // import { withSentryConfig } from '@sentry/nextjs'; import createBundleAnalyzer from '@next/bundle-analyzer'; -const withSentryConfig = (/** @type {import("next").NextConfig} */ cfg) => cfg; +// eslint-disable-next-line @typescript-eslint/no-unused-vars +const withSentryConfig = (/** @type {import("next").NextConfig} */ cfg, /** @type {any} */ opts) => + cfg; const withBundleAnalyzer = createBundleAnalyzer({ enabled: !!process.env.ANALYZE }); From da9eb51f093f28d3b95ecafe6f4dbefcb37d86b9 Mon Sep 17 00:00:00 2001 From: Jan Potoms <2109932+Janpot@users.noreply.github.com> Date: Sun, 6 Nov 2022 16:45:55 +0100 Subject: [PATCH 10/24] beef up CI machine --- .circleci/config.yml | 2 +- packages/toolpad-app/next.config.mjs | 6 +----- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index dfaceb9749..9867d867c1 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -129,7 +129,7 @@ jobs: command: yarn markdownlint test_static: <<: *defaults - resource_class: medium+ + resource_class: large steps: - checkout - install_js diff --git a/packages/toolpad-app/next.config.mjs b/packages/toolpad-app/next.config.mjs index 999e710b3d..7f4346e2d2 100644 --- a/packages/toolpad-app/next.config.mjs +++ b/packages/toolpad-app/next.config.mjs @@ -1,12 +1,8 @@ import { createRequire } from 'module'; import * as path from 'path'; -// import { withSentryConfig } from '@sentry/nextjs'; +import { withSentryConfig } from '@sentry/nextjs'; import createBundleAnalyzer from '@next/bundle-analyzer'; -// eslint-disable-next-line @typescript-eslint/no-unused-vars -const withSentryConfig = (/** @type {import("next").NextConfig} */ cfg, /** @type {any} */ opts) => - cfg; - const withBundleAnalyzer = createBundleAnalyzer({ enabled: !!process.env.ANALYZE }); // TODO: remove when https://github.com/getsentry/sentry-javascript/issues/3852 gets resolved From 76ae92f0f1ff51d816a4786b8afde81481e85183 Mon Sep 17 00:00:00 2001 From: Jan Potoms <2109932+Janpot@users.noreply.github.com> Date: Sun, 6 Nov 2022 17:51:33 +0100 Subject: [PATCH 11/24] try increasing heap size --- .circleci/config.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.circleci/config.yml b/.circleci/config.yml index 9867d867c1..2d50d8f6a9 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -130,6 +130,8 @@ jobs: test_static: <<: *defaults resource_class: large + environment: + - NODE_OPTIONS: '--max-old-space-size=10240' steps: - checkout - install_js From e8326da4a2ef7af1a6c73ee2bc05600c74d2f7ec Mon Sep 17 00:00:00 2001 From: Jan Potoms <2109932+Janpot@users.noreply.github.com> Date: Sun, 6 Nov 2022 18:02:24 +0100 Subject: [PATCH 12/24] cdsfwe --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 2d50d8f6a9..7f57bb84a7 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -131,7 +131,7 @@ jobs: <<: *defaults resource_class: large environment: - - NODE_OPTIONS: '--max-old-space-size=10240' + - NODE_OPTIONS: '--max-old-space-size=16192' steps: - checkout - install_js From 826de82953fa1c968ef6a3bf54c93303b83ac43c Mon Sep 17 00:00:00 2001 From: Jan Potoms <2109932+Janpot@users.noreply.github.com> Date: Mon, 7 Nov 2022 09:21:35 +0100 Subject: [PATCH 13/24] hail mary --- .circleci/config.yml | 4 +--- docs/next.config.js | 3 +++ 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 7f57bb84a7..dfaceb9749 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -129,9 +129,7 @@ jobs: command: yarn markdownlint test_static: <<: *defaults - resource_class: large - environment: - - NODE_OPTIONS: '--max-old-space-size=16192' + resource_class: medium+ steps: - checkout - install_js diff --git a/docs/next.config.js b/docs/next.config.js index 78160d9635..d8b541ee4b 100644 --- a/docs/next.config.js +++ b/docs/next.config.js @@ -33,6 +33,9 @@ const MONOREPO_PACKAGES = { module.exports = withTM( withDocsInfra({ + experimental: { + esmExternals: false, + }, // Avoid conflicts with the other Next.js apps hosted under https://mui.com/ assetPrefix: process.env.DEPLOY_ENV === 'development' ? '' : '/toolpad', env: { From 2d9b5934ee7073e9942879653ebeac87ccc728e5 Mon Sep 17 00:00:00 2001 From: Jan Potoms <2109932+Janpot@users.noreply.github.com> Date: Mon, 7 Nov 2022 09:33:01 +0100 Subject: [PATCH 14/24] remove --- docs/next.config.js | 3 --- 1 file changed, 3 deletions(-) diff --git a/docs/next.config.js b/docs/next.config.js index d8b541ee4b..78160d9635 100644 --- a/docs/next.config.js +++ b/docs/next.config.js @@ -33,9 +33,6 @@ const MONOREPO_PACKAGES = { module.exports = withTM( withDocsInfra({ - experimental: { - esmExternals: false, - }, // Avoid conflicts with the other Next.js apps hosted under https://mui.com/ assetPrefix: process.env.DEPLOY_ENV === 'development' ? '' : '/toolpad', env: { From 14f075a2ce85fc5084f1a5f50348cfba0f557023 Mon Sep 17 00:00:00 2001 From: Jan Potoms <2109932+Janpot@users.noreply.github.com> Date: Mon, 7 Nov 2022 09:40:16 +0100 Subject: [PATCH 15/24] xfgsfg --- .../src/components/MonacoEditor.tsx | 401 +----------------- 1 file changed, 7 insertions(+), 394 deletions(-) diff --git a/packages/toolpad-app/src/components/MonacoEditor.tsx b/packages/toolpad-app/src/components/MonacoEditor.tsx index 79d79721b3..922800cbaa 100644 --- a/packages/toolpad-app/src/components/MonacoEditor.tsx +++ b/packages/toolpad-app/src/components/MonacoEditor.tsx @@ -1,213 +1,18 @@ +/* eslint-disable react/no-unused-prop-types */ /** * NOTE: This file can't SSR (use lazyComponent to load it) */ import '../utils/browserOnly'; import * as React from 'react'; -import * as monaco from 'monaco-editor'; -import { styled, SxProps } from '@mui/material'; -import clsx from 'clsx'; -import cuid from 'cuid'; -import invariant from 'invariant'; -import { - conf as jsonBasicConf, - language as jsonBasicLanguage, -} from 'monaco-editor/esm/vs/basic-languages/javascript/javascript'; -import { - conf as typescriptBasicConf, - language as typescriptBasicLanguage, -} from 'monaco-editor/esm/vs/basic-languages/typescript/typescript'; -import { useTheme, Theme, lighten, rgbToHex } from '@mui/material/styles'; -import { getDesignTokens } from '../theme'; +import type * as monaco from 'monaco-editor'; +import { SxProps } from '@mui/material'; export interface ExtraLib { content: string; filePath?: string; } -function getExtension(language: string): string { - switch (language) { - case 'typescript': - return '.tsx'; - case 'json': - return '.json'; - case 'javascript': - return '.jsx'; - case 'css': - return '.css'; - case 'html': - return '.html'; - case 'plaintext': - return '.txt'; - default: - return '.jsx'; - } -} - -declare global { - interface Window { - MonacoEnvironment?: monaco.Environment | undefined; - } -} - -const designTokensDark = getDesignTokens('dark'); - -invariant( - designTokensDark.palette?.background?.default && - designTokensDark.palette?.background?.paper && - designTokensDark.palette?.divider, - 'dark theme tokens missing', -); - -const editorBackground = rgbToHex(lighten(designTokensDark.palette.background.default, 0.05)); -const paperBackground = rgbToHex(designTokensDark.palette.background.paper); -const dividerColor = rgbToHex(designTokensDark.palette.divider); - -monaco.editor.defineTheme('vs-toolpad-dark', { - base: 'vs-dark', - inherit: true, - rules: [], - colors: { - // See https://code.visualstudio.com/api/references/theme-color - 'editor.background': editorBackground, - 'menu.background': paperBackground, - 'menu.border': dividerColor, - 'menu.separatorBackground': dividerColor, - 'editorWidget.background': paperBackground, - 'editorWidget.border': dividerColor, - 'editor.lineHighlightBorder': dividerColor, - }, -}); - -monaco.editor.defineTheme('vs-toolpad-light', { - base: 'vs', - inherit: true, - rules: [], - colors: {}, -}); - -window.MonacoEnvironment = { - async getWorker(_, label) { - if (label === 'typescript') { - return new Worker( - new URL(`monaco-editor/esm/vs/language/typescript/ts.worker`, import.meta.url), - ); - } - if (label === 'json') { - return new Worker(new URL(`monaco-editor/esm/vs/language/json/json.worker`, import.meta.url)); - } - if (label === 'html') { - return new Worker(new URL(`monaco-editor/esm/vs/language/html/html.worker`, import.meta.url)); - } - if (label === 'css') { - return new Worker(new URL(`monaco-editor/esm/vs/language/css/css.worker`, import.meta.url)); - } - if (label === 'editorWorkerService') { - return new Worker(new URL('monaco-editor/esm/vs/editor/editor.worker', import.meta.url)); - } - throw new Error(`Failed to resolve worker with label "${label}"`); - }, -} as monaco.Environment; - -function registerLanguage( - langId: string, - language: monaco.languages.IMonarchLanguage, - conf: monaco.languages.LanguageConfiguration, -) { - monaco.languages.register({ id: langId }); - monaco.languages.registerTokensProviderFactory(langId, { - create: async (): Promise => language, - }); - monaco.languages.onLanguage(langId, async () => { - monaco.languages.setLanguageConfiguration(langId, conf); - }); -} - -/** - * Monaco language services are singletons, we can't set language options per editor instance. - * We're working around this limitiation by only considering diagnostics for the focused editor. - * Unfocused editors will be configured with a syntax-coloring-only language which are registered below. - * See https://github.com/microsoft/monaco-editor/issues/1105 - */ -registerLanguage('jsonBasic', jsonBasicLanguage, jsonBasicConf); -registerLanguage('typescriptBasic', typescriptBasicLanguage, typescriptBasicConf); - -const JSON_DEFAULT_DIAGNOSTICS_OPTIONS: monaco.languages.json.DiagnosticsOptions = {}; - -monaco.languages.json.jsonDefaults.setDiagnosticsOptions(JSON_DEFAULT_DIAGNOSTICS_OPTIONS); - -const TYPESCRIPT_DEFAULT_DIAGNOSTICS_OPTIONS: monaco.languages.typescript.DiagnosticsOptions = { - noSemanticValidation: false, - noSyntaxValidation: false, -}; - -monaco.languages.typescript.typescriptDefaults.setDiagnosticsOptions( - TYPESCRIPT_DEFAULT_DIAGNOSTICS_OPTIONS, -); - -const TYPESCRIPT_DEFAULT_COMPILER_OPTIONS: monaco.languages.typescript.CompilerOptions = { - target: monaco.languages.typescript.ScriptTarget.Latest, - allowNonTsExtensions: true, - moduleResolution: monaco.languages.typescript.ModuleResolutionKind.NodeJs, - module: monaco.languages.typescript.ModuleKind.ESNext, - noEmit: true, - esModuleInterop: true, - jsx: monaco.languages.typescript.JsxEmit.React, - reactNamespace: 'React', - allowJs: true, - lib: ['es2020'], - typeRoots: ['node_modules/@types'], -}; - -monaco.languages.typescript.typescriptDefaults.setCompilerOptions( - TYPESCRIPT_DEFAULT_COMPILER_OPTIONS, -); - -const classes = { - monacoHost: 'Toolpad_MonacoEditorMonacoHost', - overlay: 'Toolpad_MonacoEditorOverlay', - disabled: 'Toolpad_MonacoEditorDisabled', -}; - -const EditorRoot = styled('div')(({ theme }) => ({ - height: '100%', - position: 'relative', - - [`& .${classes.monacoHost}`]: { - position: 'absolute', - inset: '0 0 0 0', - }, - - [`& .${classes.overlay}`]: { - position: 'absolute', - inset: '0 0 0 0', - background: theme.palette.background.default, - opacity: 0.5, - display: 'none', - }, - - [`&.${classes.disabled}`]: { - pointerEvents: 'none', - }, - - [`&.${classes.disabled} .${classes.overlay}`]: { - display: 'block', - }, -})); - -let overflowWidgetsDomNode: HTMLDivElement | null = null; -function getOverflowWidgetsDomNode(theme: Theme): HTMLDivElement { - if (!overflowWidgetsDomNode) { - overflowWidgetsDomNode = document.createElement('div'); - // See https://github.com/microsoft/monaco-editor/issues/2233#issuecomment-913170212 - overflowWidgetsDomNode.classList.add('monaco-editor'); - overflowWidgetsDomNode.style.zIndex = String(theme.zIndex.tooltip + 1); - document.body.append(overflowWidgetsDomNode); - } - - return overflowWidgetsDomNode; -} - export interface MonacoEditorHandle { editor: monaco.editor.IStandaloneCodeEditor; monaco: typeof monaco; @@ -250,202 +55,10 @@ export type MonacoEditorProps = MonacoEditorBaseProps & ); export default React.forwardRef(function MonacoEditor( - { - value, - onChange, - sx, - language = 'plaintext', - diagnostics, - compilerOptions, - extraLibs, - onFocus, - onBlur, - className, - disabled, - options, - autoFocus, - }, + // eslint-disable-next-line @typescript-eslint/no-unused-vars + props, + // eslint-disable-next-line @typescript-eslint/no-unused-vars ref, ) { - const rootRef = React.useRef(null); - const instanceRef = React.useRef(null); - const theme = useTheme(); - const monacoTheme = theme.palette.mode === 'dark' ? 'vs-toolpad-dark' : 'vs-toolpad-light'; - - const [isFocused, setIsFocused] = React.useState(false); - - React.useEffect(() => { - /** - * Update the language and diagnostics of the currently focused editor. Non-focused editors - * will get a syntax-coloring-only version of the language. - * This is our workaround for having different diagnostics options per editor instance. - * See https://github.com/microsoft/monaco-editor/issues/1105 - */ - const model = instanceRef.current?.getModel(); - if (!model) { - return; - } - - if (language === 'json') { - if (isFocused) { - monaco.editor.setModelLanguage(model, 'json'); - monaco.languages.json.jsonDefaults.setDiagnosticsOptions({ - ...JSON_DEFAULT_DIAGNOSTICS_OPTIONS, - ...(diagnostics as monaco.languages.json.DiagnosticsOptions), - }); - } else { - monaco.editor.setModelLanguage(model, 'jsonBasic'); - } - } else if (language === 'typescript') { - if (isFocused) { - monaco.editor.setModelLanguage(model, 'typescript'); - monaco.languages.typescript.typescriptDefaults.setDiagnosticsOptions({ - ...TYPESCRIPT_DEFAULT_DIAGNOSTICS_OPTIONS, - ...(diagnostics as monaco.languages.typescript.DiagnosticsOptions), - }); - monaco.languages.typescript.typescriptDefaults.setCompilerOptions({ - ...TYPESCRIPT_DEFAULT_COMPILER_OPTIONS, - ...compilerOptions, - }); - monaco.languages.typescript.typescriptDefaults.setExtraLibs(extraLibs || []); - } else { - monaco.editor.setModelLanguage(model, 'typescriptBasic'); - } - } else { - monaco.editor.setModelLanguage(model, language); - } - }, [isFocused, language, diagnostics, extraLibs, compilerOptions]); - - React.useEffect(() => { - invariant(rootRef.current, 'Ref not attached'); - - const extraOptions: EditorOptions = { - readOnly: disabled, - theme: monacoTheme, - scrollbar: { - alwaysConsumeMouseWheel: false, - ...options?.scrollbar, - }, - ...options, - }; - - let instance = instanceRef.current; - - if (instance) { - instance.updateOptions(extraOptions); - - const model = instance.getModel(); - if (typeof value === 'string' && model) { - const actualValue = model.getValue(); - - if (value !== actualValue) { - // Used to restore cursor position - const state = instance.saveViewState(); - - instance.executeEdits(null, [ - { - range: model.getFullModelRange(), - text: value, - }, - ]); - - if (state) { - instance.restoreViewState(state); - } - } - } - } else { - const pathUri = monaco.Uri.parse(`./scripts/${cuid()}${getExtension(language)}`); - const model = monaco.editor.createModel(value || '', language, pathUri); - - instance = monaco.editor.create(rootRef.current, { - model, - language, - minimap: { enabled: false }, - accessibilitySupport: 'off', - tabSize: 2, - automaticLayout: true, - fixedOverflowWidgets: true, - // See https://github.com/microsoft/monaco-editor/issues/181 - overflowWidgetsDomNode: getOverflowWidgetsDomNode(theme), - ...extraOptions, - }); - - instanceRef.current = instance; - - instance.onDidFocusEditorWidget(() => setIsFocused(true)); - instance.onDidBlurEditorWidget(() => setIsFocused(false)); - - if (autoFocus && !disabled) { - instance.focus(); - } - } - }, [language, value, options, disabled, autoFocus, theme, monacoTheme]); - - React.useEffect(() => { - const editor = instanceRef.current; - - const onDidChangeModelContentSub = editor?.onDidChangeModelContent(() => { - const editorValue = editor.getValue(); - - if (onChange && value !== editorValue) { - onChange(editorValue); - } - }); - - return () => onDidChangeModelContentSub?.dispose(); - }, [onChange, value]); - - React.useEffect(() => { - const editor = instanceRef.current; - - if (onFocus) { - const onDidFocusEditorTextSub = editor?.onDidFocusEditorText(onFocus); - return () => onDidFocusEditorTextSub?.dispose(); - } - return () => {}; - }, [onFocus]); - - React.useEffect(() => { - const editor = instanceRef.current; - if (onBlur) { - const onDidBlurEditorTextSub = editor?.onDidBlurEditorText(onBlur); - return () => onDidBlurEditorTextSub?.dispose(); - } - return () => {}; - }, [onBlur]); - - React.useEffect(() => { - return () => { - instanceRef.current?.getModel()?.dispose(); - instanceRef.current?.dispose(); - instanceRef.current = null; - }; - }, []); - - React.useImperativeHandle( - ref, - () => { - return { - get editor() { - const editor = instanceRef.current; - if (!editor) { - throw new Error('Editor not created yet'); - } - return editor; - }, - get monaco() { - return monaco; - }, - }; - }, - [], - ); - - return ( - -
-
- - ); + return null; }); From be5b80ad27d057888f6a87cb0d5464cdd80d7ae0 Mon Sep 17 00:00:00 2001 From: Jan Potoms <2109932+Janpot@users.noreply.github.com> Date: Mon, 7 Nov 2022 09:40:40 +0100 Subject: [PATCH 16/24] Revert "xfgsfg" This reverts commit 14f075a2ce85fc5084f1a5f50348cfba0f557023. --- .../src/components/MonacoEditor.tsx | 401 +++++++++++++++++- 1 file changed, 394 insertions(+), 7 deletions(-) diff --git a/packages/toolpad-app/src/components/MonacoEditor.tsx b/packages/toolpad-app/src/components/MonacoEditor.tsx index 922800cbaa..79d79721b3 100644 --- a/packages/toolpad-app/src/components/MonacoEditor.tsx +++ b/packages/toolpad-app/src/components/MonacoEditor.tsx @@ -1,18 +1,213 @@ -/* eslint-disable react/no-unused-prop-types */ /** * NOTE: This file can't SSR (use lazyComponent to load it) */ import '../utils/browserOnly'; import * as React from 'react'; -import type * as monaco from 'monaco-editor'; -import { SxProps } from '@mui/material'; +import * as monaco from 'monaco-editor'; +import { styled, SxProps } from '@mui/material'; +import clsx from 'clsx'; +import cuid from 'cuid'; +import invariant from 'invariant'; +import { + conf as jsonBasicConf, + language as jsonBasicLanguage, +} from 'monaco-editor/esm/vs/basic-languages/javascript/javascript'; +import { + conf as typescriptBasicConf, + language as typescriptBasicLanguage, +} from 'monaco-editor/esm/vs/basic-languages/typescript/typescript'; +import { useTheme, Theme, lighten, rgbToHex } from '@mui/material/styles'; +import { getDesignTokens } from '../theme'; export interface ExtraLib { content: string; filePath?: string; } +function getExtension(language: string): string { + switch (language) { + case 'typescript': + return '.tsx'; + case 'json': + return '.json'; + case 'javascript': + return '.jsx'; + case 'css': + return '.css'; + case 'html': + return '.html'; + case 'plaintext': + return '.txt'; + default: + return '.jsx'; + } +} + +declare global { + interface Window { + MonacoEnvironment?: monaco.Environment | undefined; + } +} + +const designTokensDark = getDesignTokens('dark'); + +invariant( + designTokensDark.palette?.background?.default && + designTokensDark.palette?.background?.paper && + designTokensDark.palette?.divider, + 'dark theme tokens missing', +); + +const editorBackground = rgbToHex(lighten(designTokensDark.palette.background.default, 0.05)); +const paperBackground = rgbToHex(designTokensDark.palette.background.paper); +const dividerColor = rgbToHex(designTokensDark.palette.divider); + +monaco.editor.defineTheme('vs-toolpad-dark', { + base: 'vs-dark', + inherit: true, + rules: [], + colors: { + // See https://code.visualstudio.com/api/references/theme-color + 'editor.background': editorBackground, + 'menu.background': paperBackground, + 'menu.border': dividerColor, + 'menu.separatorBackground': dividerColor, + 'editorWidget.background': paperBackground, + 'editorWidget.border': dividerColor, + 'editor.lineHighlightBorder': dividerColor, + }, +}); + +monaco.editor.defineTheme('vs-toolpad-light', { + base: 'vs', + inherit: true, + rules: [], + colors: {}, +}); + +window.MonacoEnvironment = { + async getWorker(_, label) { + if (label === 'typescript') { + return new Worker( + new URL(`monaco-editor/esm/vs/language/typescript/ts.worker`, import.meta.url), + ); + } + if (label === 'json') { + return new Worker(new URL(`monaco-editor/esm/vs/language/json/json.worker`, import.meta.url)); + } + if (label === 'html') { + return new Worker(new URL(`monaco-editor/esm/vs/language/html/html.worker`, import.meta.url)); + } + if (label === 'css') { + return new Worker(new URL(`monaco-editor/esm/vs/language/css/css.worker`, import.meta.url)); + } + if (label === 'editorWorkerService') { + return new Worker(new URL('monaco-editor/esm/vs/editor/editor.worker', import.meta.url)); + } + throw new Error(`Failed to resolve worker with label "${label}"`); + }, +} as monaco.Environment; + +function registerLanguage( + langId: string, + language: monaco.languages.IMonarchLanguage, + conf: monaco.languages.LanguageConfiguration, +) { + monaco.languages.register({ id: langId }); + monaco.languages.registerTokensProviderFactory(langId, { + create: async (): Promise => language, + }); + monaco.languages.onLanguage(langId, async () => { + monaco.languages.setLanguageConfiguration(langId, conf); + }); +} + +/** + * Monaco language services are singletons, we can't set language options per editor instance. + * We're working around this limitiation by only considering diagnostics for the focused editor. + * Unfocused editors will be configured with a syntax-coloring-only language which are registered below. + * See https://github.com/microsoft/monaco-editor/issues/1105 + */ +registerLanguage('jsonBasic', jsonBasicLanguage, jsonBasicConf); +registerLanguage('typescriptBasic', typescriptBasicLanguage, typescriptBasicConf); + +const JSON_DEFAULT_DIAGNOSTICS_OPTIONS: monaco.languages.json.DiagnosticsOptions = {}; + +monaco.languages.json.jsonDefaults.setDiagnosticsOptions(JSON_DEFAULT_DIAGNOSTICS_OPTIONS); + +const TYPESCRIPT_DEFAULT_DIAGNOSTICS_OPTIONS: monaco.languages.typescript.DiagnosticsOptions = { + noSemanticValidation: false, + noSyntaxValidation: false, +}; + +monaco.languages.typescript.typescriptDefaults.setDiagnosticsOptions( + TYPESCRIPT_DEFAULT_DIAGNOSTICS_OPTIONS, +); + +const TYPESCRIPT_DEFAULT_COMPILER_OPTIONS: monaco.languages.typescript.CompilerOptions = { + target: monaco.languages.typescript.ScriptTarget.Latest, + allowNonTsExtensions: true, + moduleResolution: monaco.languages.typescript.ModuleResolutionKind.NodeJs, + module: monaco.languages.typescript.ModuleKind.ESNext, + noEmit: true, + esModuleInterop: true, + jsx: monaco.languages.typescript.JsxEmit.React, + reactNamespace: 'React', + allowJs: true, + lib: ['es2020'], + typeRoots: ['node_modules/@types'], +}; + +monaco.languages.typescript.typescriptDefaults.setCompilerOptions( + TYPESCRIPT_DEFAULT_COMPILER_OPTIONS, +); + +const classes = { + monacoHost: 'Toolpad_MonacoEditorMonacoHost', + overlay: 'Toolpad_MonacoEditorOverlay', + disabled: 'Toolpad_MonacoEditorDisabled', +}; + +const EditorRoot = styled('div')(({ theme }) => ({ + height: '100%', + position: 'relative', + + [`& .${classes.monacoHost}`]: { + position: 'absolute', + inset: '0 0 0 0', + }, + + [`& .${classes.overlay}`]: { + position: 'absolute', + inset: '0 0 0 0', + background: theme.palette.background.default, + opacity: 0.5, + display: 'none', + }, + + [`&.${classes.disabled}`]: { + pointerEvents: 'none', + }, + + [`&.${classes.disabled} .${classes.overlay}`]: { + display: 'block', + }, +})); + +let overflowWidgetsDomNode: HTMLDivElement | null = null; +function getOverflowWidgetsDomNode(theme: Theme): HTMLDivElement { + if (!overflowWidgetsDomNode) { + overflowWidgetsDomNode = document.createElement('div'); + // See https://github.com/microsoft/monaco-editor/issues/2233#issuecomment-913170212 + overflowWidgetsDomNode.classList.add('monaco-editor'); + overflowWidgetsDomNode.style.zIndex = String(theme.zIndex.tooltip + 1); + document.body.append(overflowWidgetsDomNode); + } + + return overflowWidgetsDomNode; +} + export interface MonacoEditorHandle { editor: monaco.editor.IStandaloneCodeEditor; monaco: typeof monaco; @@ -55,10 +250,202 @@ export type MonacoEditorProps = MonacoEditorBaseProps & ); export default React.forwardRef(function MonacoEditor( - // eslint-disable-next-line @typescript-eslint/no-unused-vars - props, - // eslint-disable-next-line @typescript-eslint/no-unused-vars + { + value, + onChange, + sx, + language = 'plaintext', + diagnostics, + compilerOptions, + extraLibs, + onFocus, + onBlur, + className, + disabled, + options, + autoFocus, + }, ref, ) { - return null; + const rootRef = React.useRef(null); + const instanceRef = React.useRef(null); + const theme = useTheme(); + const monacoTheme = theme.palette.mode === 'dark' ? 'vs-toolpad-dark' : 'vs-toolpad-light'; + + const [isFocused, setIsFocused] = React.useState(false); + + React.useEffect(() => { + /** + * Update the language and diagnostics of the currently focused editor. Non-focused editors + * will get a syntax-coloring-only version of the language. + * This is our workaround for having different diagnostics options per editor instance. + * See https://github.com/microsoft/monaco-editor/issues/1105 + */ + const model = instanceRef.current?.getModel(); + if (!model) { + return; + } + + if (language === 'json') { + if (isFocused) { + monaco.editor.setModelLanguage(model, 'json'); + monaco.languages.json.jsonDefaults.setDiagnosticsOptions({ + ...JSON_DEFAULT_DIAGNOSTICS_OPTIONS, + ...(diagnostics as monaco.languages.json.DiagnosticsOptions), + }); + } else { + monaco.editor.setModelLanguage(model, 'jsonBasic'); + } + } else if (language === 'typescript') { + if (isFocused) { + monaco.editor.setModelLanguage(model, 'typescript'); + monaco.languages.typescript.typescriptDefaults.setDiagnosticsOptions({ + ...TYPESCRIPT_DEFAULT_DIAGNOSTICS_OPTIONS, + ...(diagnostics as monaco.languages.typescript.DiagnosticsOptions), + }); + monaco.languages.typescript.typescriptDefaults.setCompilerOptions({ + ...TYPESCRIPT_DEFAULT_COMPILER_OPTIONS, + ...compilerOptions, + }); + monaco.languages.typescript.typescriptDefaults.setExtraLibs(extraLibs || []); + } else { + monaco.editor.setModelLanguage(model, 'typescriptBasic'); + } + } else { + monaco.editor.setModelLanguage(model, language); + } + }, [isFocused, language, diagnostics, extraLibs, compilerOptions]); + + React.useEffect(() => { + invariant(rootRef.current, 'Ref not attached'); + + const extraOptions: EditorOptions = { + readOnly: disabled, + theme: monacoTheme, + scrollbar: { + alwaysConsumeMouseWheel: false, + ...options?.scrollbar, + }, + ...options, + }; + + let instance = instanceRef.current; + + if (instance) { + instance.updateOptions(extraOptions); + + const model = instance.getModel(); + if (typeof value === 'string' && model) { + const actualValue = model.getValue(); + + if (value !== actualValue) { + // Used to restore cursor position + const state = instance.saveViewState(); + + instance.executeEdits(null, [ + { + range: model.getFullModelRange(), + text: value, + }, + ]); + + if (state) { + instance.restoreViewState(state); + } + } + } + } else { + const pathUri = monaco.Uri.parse(`./scripts/${cuid()}${getExtension(language)}`); + const model = monaco.editor.createModel(value || '', language, pathUri); + + instance = monaco.editor.create(rootRef.current, { + model, + language, + minimap: { enabled: false }, + accessibilitySupport: 'off', + tabSize: 2, + automaticLayout: true, + fixedOverflowWidgets: true, + // See https://github.com/microsoft/monaco-editor/issues/181 + overflowWidgetsDomNode: getOverflowWidgetsDomNode(theme), + ...extraOptions, + }); + + instanceRef.current = instance; + + instance.onDidFocusEditorWidget(() => setIsFocused(true)); + instance.onDidBlurEditorWidget(() => setIsFocused(false)); + + if (autoFocus && !disabled) { + instance.focus(); + } + } + }, [language, value, options, disabled, autoFocus, theme, monacoTheme]); + + React.useEffect(() => { + const editor = instanceRef.current; + + const onDidChangeModelContentSub = editor?.onDidChangeModelContent(() => { + const editorValue = editor.getValue(); + + if (onChange && value !== editorValue) { + onChange(editorValue); + } + }); + + return () => onDidChangeModelContentSub?.dispose(); + }, [onChange, value]); + + React.useEffect(() => { + const editor = instanceRef.current; + + if (onFocus) { + const onDidFocusEditorTextSub = editor?.onDidFocusEditorText(onFocus); + return () => onDidFocusEditorTextSub?.dispose(); + } + return () => {}; + }, [onFocus]); + + React.useEffect(() => { + const editor = instanceRef.current; + if (onBlur) { + const onDidBlurEditorTextSub = editor?.onDidBlurEditorText(onBlur); + return () => onDidBlurEditorTextSub?.dispose(); + } + return () => {}; + }, [onBlur]); + + React.useEffect(() => { + return () => { + instanceRef.current?.getModel()?.dispose(); + instanceRef.current?.dispose(); + instanceRef.current = null; + }; + }, []); + + React.useImperativeHandle( + ref, + () => { + return { + get editor() { + const editor = instanceRef.current; + if (!editor) { + throw new Error('Editor not created yet'); + } + return editor; + }, + get monaco() { + return monaco; + }, + }; + }, + [], + ); + + return ( + +
+
+ + ); }); From e6157a0b73fd7760076c8977bb9b73b7cdafe20c Mon Sep 17 00:00:00 2001 From: Jan Potoms <2109932+Janpot@users.noreply.github.com> Date: Mon, 7 Nov 2022 09:58:30 +0100 Subject: [PATCH 17/24] dew --- packages/toolpad-app/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/toolpad-app/package.json b/packages/toolpad-app/package.json index f3ff93cfa4..14de0ea675 100644 --- a/packages/toolpad-app/package.json +++ b/packages/toolpad-app/package.json @@ -9,7 +9,7 @@ "lint": "next lint && prettier --check .", "fix": "next lint --fix && prettier --write .", "prisma": "prisma", - "build:next": "next build", + "build:next": "NODE_OPTIONS=--max-old-space-size=8192 next build", "build:react-devtools": "rimraf ./public/reactDevtools && esbuild ./reactDevtools/bootstrap.ts --target=es6 --bundle --outdir=./public/reactDevtools", "build:typings": "ts-node ./scripts/typings.ts", "build:function-runtime": "rimraf ./src/toolpadDataSources/function/dist && esbuild ./src/toolpadDataSources/function/runtime/index.ts --target=es2020 --bundle --outdir=./src/toolpadDataSources/function/dist", From adcc4884b28a3b19e8c1580c672fecbbd9e3661a Mon Sep 17 00:00:00 2001 From: Jan Potoms <2109932+Janpot@users.noreply.github.com> Date: Mon, 7 Nov 2022 13:53:22 +0100 Subject: [PATCH 18/24] race condition? --- test/models/ToolpadHome.ts | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/test/models/ToolpadHome.ts b/test/models/ToolpadHome.ts index 8e53716d41..c9f91959e2 100644 --- a/test/models/ToolpadHome.ts +++ b/test/models/ToolpadHome.ts @@ -78,9 +78,10 @@ export class ToolpadHome { await this.newAppDomInput.fill(JSON.stringify(dom)); } - await this.newAppDomCreateBtn.click(); - - await this.page.waitForNavigation({ url: /\/_toolpad\/app\/[^/]+\/pages\/[^/]+/ }); + await Promise.all([ + this.newAppDomCreateBtn.click(), + this.page.waitForNavigation({ url: /\/_toolpad\/app\/[^/]+\/pages\/[^/]+/ }), + ]); const { pathname } = new URL(this.page.url()); const idMatch = /^\/_toolpad\/app\/([^/]+)\//.exec(pathname); From c3bc9cb69137afb28be0c31265c2aac11c70e4a7 Mon Sep 17 00:00:00 2001 From: Jan Potoms <2109932+Janpot@users.noreply.github.com> Date: Mon, 7 Nov 2022 16:01:28 +0100 Subject: [PATCH 19/24] signal --- .../toolpad-app/src/server/getLatestRelease.ts | 16 ++-------------- 1 file changed, 2 insertions(+), 14 deletions(-) diff --git a/packages/toolpad-app/src/server/getLatestRelease.ts b/packages/toolpad-app/src/server/getLatestRelease.ts index 608fc3e009..bf802a09ac 100644 --- a/packages/toolpad-app/src/server/getLatestRelease.ts +++ b/packages/toolpad-app/src/server/getLatestRelease.ts @@ -5,23 +5,11 @@ interface GithubRelease { url: string; } -function abortSignalTimeout(ms: number): AbortSignal { - // @ts-expect-error See https://github.com/microsoft/TypeScript/issues/48003 - if (AbortSignal.timeout) { - console.warn('Next.js support AbortSignal.timeout, remove this polyfill'); - // @ts-expect-error See https://github.com/microsoft/TypeScript/issues/48003 - return AbortSignal.timeout(ms); - } - - const controller = new AbortController(); - setTimeout(() => controller.abort(), ms); - return controller.signal; -} - async function fetchRelease(): Promise { const response = await fetch(LATEST_RELEASE_API_URL, { // Abort the request after 30 seconds - signal: abortSignalTimeout(30_000), + // @ts-expect-error See https://github.com/microsoft/TypeScript/issues/48003 + signal: AbortSignal.timeout(30_000), }); if (response.ok) { From 059410d4aae5d2da0ce8e28c60c1fd59c065487e Mon Sep 17 00:00:00 2001 From: Jan Potoms <2109932+Janpot@users.noreply.github.com> Date: Mon, 7 Nov 2022 16:17:21 +0100 Subject: [PATCH 20/24] latest playwright --- package.json | 2 +- yarn.lock | 18 +++++++++--------- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/package.json b/package.json index 90b8f71648..c4cd8ca062 100644 --- a/package.json +++ b/package.json @@ -42,7 +42,7 @@ "devDependencies": { "@mui/monorepo": "https://github.com/mui/material-ui.git", "@next/eslint-plugin-next": "13.0.2", - "@playwright/test": "^1.27.1", + "@playwright/test": "next", "@swc/helpers": "^0.4.12", "@testing-library/jest-dom": "^5.16.5", "@testing-library/react": "^13.4.0", diff --git a/yarn.lock b/yarn.lock index 6fc0cd1537..926acaf7c6 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2415,13 +2415,13 @@ dependencies: esquery "^1.0.1" -"@playwright/test@^1.27.1": - version "1.27.1" - resolved "https://registry.yarnpkg.com/@playwright/test/-/test-1.27.1.tgz#9364d1e02021261211c8ff586d903faa79ce95c4" - integrity sha512-mrL2q0an/7tVqniQQF6RBL2saskjljXzqNcCOVMUjRIgE6Y38nCNaP+Dc2FBW06bcpD3tqIws/HT9qiMHbNU0A== +"@playwright/test@next": + version "1.28.0-alpha-nov-7-2022" + resolved "https://registry.yarnpkg.com/@playwright/test/-/test-1.28.0-alpha-nov-7-2022.tgz#27d702fddaf5f71521501199a9c698c7c4a4d6b4" + integrity sha512-BO33CR/2oLpQ7Fy7qq7ZU261sK7JmK7RN7fiQIzOOf2Fw6yt6Jo7u4U/eF9YSoTszzRrKWlKV3NXbyT36ElU/A== dependencies: "@types/node" "*" - playwright-core "1.27.1" + playwright-core "1.28.0-alpha-nov-7-2022" "@polka/url@^1.0.0-next.20": version "1.0.0-next.21" @@ -10092,10 +10092,10 @@ pkg-up@^3.1.0: dependencies: find-up "^3.0.0" -playwright-core@1.27.1: - version "1.27.1" - resolved "https://registry.yarnpkg.com/playwright-core/-/playwright-core-1.27.1.tgz#840ef662e55a3ed759d8b5d3d00a5f885a7184f4" - integrity sha512-9EmeXDncC2Pmp/z+teoVYlvmPWUC6ejSSYZUln7YaP89Z6lpAaiaAnqroUt/BoLo8tn7WYShcfaCh+xofZa44Q== +playwright-core@1.28.0-alpha-nov-7-2022: + version "1.28.0-alpha-nov-7-2022" + resolved "https://registry.yarnpkg.com/playwright-core/-/playwright-core-1.28.0-alpha-nov-7-2022.tgz#59dd67a82ffea5311f36fb998ae1996e8de5c8e1" + integrity sha512-KhFZfgE6TCVNNU2ncxIg0woFtgeofhPqHujm2BYkq2qEf1Uv/qd5u2m+HMJyZUDXRO+yhLTxH00ndV2ypt+vZw== pluralize@^3.1.0: version "3.1.0" From a81ae95a2d7425b7bc0d9adc0fa5a25f7abd6b4b Mon Sep 17 00:00:00 2001 From: Jan Potoms <2109932+Janpot@users.noreply.github.com> Date: Mon, 7 Nov 2022 16:30:39 +0100 Subject: [PATCH 21/24] focal --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index dfaceb9749..082406abd7 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -186,7 +186,7 @@ jobs: -v "$CIRCLE_WORKING_DIRECTORY:/tests" \ -w /tests \ -e PLAYWRIGHT_TEST_BASE_URL=http://172.17.0.1:3000/ \ - mcr.microsoft.com/playwright:v1.27.0-focal \ + mcr.microsoft.com/playwright:v1.28.0-alpha-nov-7-2022-focal \ yarn test:integration --forbid-only docker-compose -f ./docker-compose.test.yml down From 1496d42f2f609d6be902e724c40c959dc35700ae Mon Sep 17 00:00:00 2001 From: Jan Potoms <2109932+Janpot@users.noreply.github.com> Date: Tue, 8 Nov 2022 09:38:36 +0100 Subject: [PATCH 22/24] next canary --- packages/toolpad-app/package.json | 2 +- yarn.lock | 96 +++++++++++++++++++++++++++++++ 2 files changed, 97 insertions(+), 1 deletion(-) diff --git a/packages/toolpad-app/package.json b/packages/toolpad-app/package.json index 476ababdcd..1dbadf80d2 100644 --- a/packages/toolpad-app/package.json +++ b/packages/toolpad-app/package.json @@ -81,7 +81,7 @@ "lodash-es": "^4.17.21", "mitt": "^3.0.0", "monaco-editor": "0.34.1", - "next": "13.0.2", + "next": "canary", "node-fetch": "^2.6.7", "node-fetch-har": "^1.0.1", "path-to-regexp": "^6.2.1", diff --git a/yarn.lock b/yarn.lock index be1a89d198..8ac8cc204c 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2042,6 +2042,11 @@ resolved "https://registry.yarnpkg.com/@next/env/-/env-13.0.2.tgz#5fbd7b4146175ae406edfb4a38b62de8c880c09d" integrity sha512-Qb6WPuRriGIQ19qd6NBxpcrFOfj8ziN7l9eZUfwff5gl4zLXluqtuZPddYZM/oWjN53ZYcuRXzL+oowKyJeYtA== +"@next/env@13.0.3-canary.1": + version "13.0.3-canary.1" + resolved "https://registry.yarnpkg.com/@next/env/-/env-13.0.3-canary.1.tgz#d3708076dc410eb2f3ba208c3504ce0e842a1d50" + integrity sha512-/CmSfWbkdbGRfQP4A/9+BNZuzxNW4e6fJSLdQxl93gwP8RcFaQ/hYUR1weqId+KNM/ZQyJO52trSsenrOxeT4g== + "@next/eslint-plugin-next@13.0.2": version "13.0.2" resolved "https://registry.yarnpkg.com/@next/eslint-plugin-next/-/eslint-plugin-next-13.0.2.tgz#89fe2144b37896f926e2bd9bed675396f1f697ce" @@ -2054,66 +2059,131 @@ resolved "https://registry.yarnpkg.com/@next/swc-android-arm-eabi/-/swc-android-arm-eabi-13.0.2.tgz#66669b8aab5062f554b8e9905d855679aabf0342" integrity sha512-X54UQCTFyOGnJP//Z71dPPlp4BCYcQL2ncikKXQcPzVpqPs4C3m+tKC8ivBNH6edAXkppwsLRz1/yQwgSZ9Swg== +"@next/swc-android-arm-eabi@13.0.3-canary.1": + version "13.0.3-canary.1" + resolved "https://registry.yarnpkg.com/@next/swc-android-arm-eabi/-/swc-android-arm-eabi-13.0.3-canary.1.tgz#108e80e2b0a5a67ded86c00aa8b16e6a4e213779" + integrity sha512-Igw1lXoPS5EnZQ7o5npsNUWXDFnMiizhTU7+M54QUaajS7HUSc8slYeqgYj8mnMBp6Pm/x4sJgi8n3MrDECAbw== + "@next/swc-android-arm64@13.0.2": version "13.0.2" resolved "https://registry.yarnpkg.com/@next/swc-android-arm64/-/swc-android-arm64-13.0.2.tgz#c0641d30525e0fb22bf1e2baf6c461d2d9e52f1a" integrity sha512-1P00Kv8uKaLubqo7JzPrTqgFAzSOmfb8iwqJrOb9in5IvTRtNGlkR4hU0sXzqbQNM/+SaYxze6Z5ry1IDyb/cQ== +"@next/swc-android-arm64@13.0.3-canary.1": + version "13.0.3-canary.1" + resolved "https://registry.yarnpkg.com/@next/swc-android-arm64/-/swc-android-arm64-13.0.3-canary.1.tgz#396ea7e73a4708355d1e58a3513da3a69cc7639a" + integrity sha512-CTNLjmnSVje8RvRUKR2kM9iuCKq66qfgwLDgWpG/kRARcBtOHp+AKxCqkBBSGyiHesw3KV2wdDLMf4rMiooTBg== + "@next/swc-darwin-arm64@13.0.2": version "13.0.2" resolved "https://registry.yarnpkg.com/@next/swc-darwin-arm64/-/swc-darwin-arm64-13.0.2.tgz#d7e01a33393e83456dbfdc41446bb8a923968ff7" integrity sha512-1zGIOkInkOLRv0QQGZ+3wffYsyKI4vIy62LYTvDWUn7TAYqnmXwougp9NSLqDeagLwgsv2URrykyAFixA/YqxA== +"@next/swc-darwin-arm64@13.0.3-canary.1": + version "13.0.3-canary.1" + resolved "https://registry.yarnpkg.com/@next/swc-darwin-arm64/-/swc-darwin-arm64-13.0.3-canary.1.tgz#fb2db32628301b2caf861c9fb4a977d01ee51c20" + integrity sha512-DFPsJnPAk9xzkBzBKz0l1fFB8ia+wQTUkXKg+PiZgiVVjoGFFuXqLsKS+De2pF+/mSAPBlcg73SAgB/Xd81vaQ== + "@next/swc-darwin-x64@13.0.2": version "13.0.2" resolved "https://registry.yarnpkg.com/@next/swc-darwin-x64/-/swc-darwin-x64-13.0.2.tgz#d4a3fbe51edf871a675d89a7afdc78174d1e5841" integrity sha512-ECDAjoMP1Y90cARaelS6X+k6BQx+MikAYJ8f/eaJrLur44NIOYc9HA/dgcTp5jenguY4yT8V+HCquLjAVle6fA== +"@next/swc-darwin-x64@13.0.3-canary.1": + version "13.0.3-canary.1" + resolved "https://registry.yarnpkg.com/@next/swc-darwin-x64/-/swc-darwin-x64-13.0.3-canary.1.tgz#23e5fa0c9892dbecaf234068bacdd1852174332d" + integrity sha512-hgtjVm8gPpqrmLpM1DOBkJjuBZvYB693c9K21uzE8TF8FFLl2/wAunmDFYBgnabAzq+vuzQKwmz5TV7svLDYjQ== + "@next/swc-freebsd-x64@13.0.2": version "13.0.2" resolved "https://registry.yarnpkg.com/@next/swc-freebsd-x64/-/swc-freebsd-x64-13.0.2.tgz#1b54c3f38d3b36f86663a8dfcc81ea05e01f5172" integrity sha512-2DcL/ofQdBnQX3IoI9sjlIAyLCD1oZoUBuhrhWbejvBQjutWrI0JTEv9uG69WcxWhVMm3BCsjv8GK2/68OKp7A== +"@next/swc-freebsd-x64@13.0.3-canary.1": + version "13.0.3-canary.1" + resolved "https://registry.yarnpkg.com/@next/swc-freebsd-x64/-/swc-freebsd-x64-13.0.3-canary.1.tgz#aec7efe8c1c7860a821e3abc9a434d6a3009aac5" + integrity sha512-PfpCCbPH5/fAURJHDXNWgGJkPUJ4UuNFk+t8ojxOnFOArLucDnLEl1dX058C/l2KUoSUVe+25eMYfGP8DlUr8A== + "@next/swc-linux-arm-gnueabihf@13.0.2": version "13.0.2" resolved "https://registry.yarnpkg.com/@next/swc-linux-arm-gnueabihf/-/swc-linux-arm-gnueabihf-13.0.2.tgz#18495cff32c0b2182cfbf677614219d7072214da" integrity sha512-Y3OQF1CSBSWW2vGkmvOIuOUNqOq8qX7f1ZpcKUVWP3/Uq++DZmVi9d18lgnSe1I3QFqc+nXWyun9ljsN83j0sw== +"@next/swc-linux-arm-gnueabihf@13.0.3-canary.1": + version "13.0.3-canary.1" + resolved "https://registry.yarnpkg.com/@next/swc-linux-arm-gnueabihf/-/swc-linux-arm-gnueabihf-13.0.3-canary.1.tgz#671fc7918846d7e84ab1151e86152785baa6af2b" + integrity sha512-cpRfril/NfPrUEAC9Auoz5ZYsrPjyCBzPRB0qWNUtyBY/553+W9uUwQJb9SwchHxz36zLMwEwLqyD7Ci9ib0qg== + "@next/swc-linux-arm64-gnu@13.0.2": version "13.0.2" resolved "https://registry.yarnpkg.com/@next/swc-linux-arm64-gnu/-/swc-linux-arm64-gnu-13.0.2.tgz#5fb2563651166c3c6f32bf9e2f9cc6a16a9ef783" integrity sha512-mNyzwsFF6kwZYEjnGicx9ksDZYEZvyzEc1BtCu8vdZi/v8UeixQwCiAT6FyYX9uxMPEkzk8qiU0t0u9gvltsKw== +"@next/swc-linux-arm64-gnu@13.0.3-canary.1": + version "13.0.3-canary.1" + resolved "https://registry.yarnpkg.com/@next/swc-linux-arm64-gnu/-/swc-linux-arm64-gnu-13.0.3-canary.1.tgz#a81530bb31b6ca04e6d476bbaefa41e10a57f7f5" + integrity sha512-9n09Eb1ApX+PFZv3oTzN8uNX+jeKgpc+PlNeJLyoK3UQx86xlUZCO/hMwMU8s+RT3bdHc73DciBPRQs9vD63Vw== + "@next/swc-linux-arm64-musl@13.0.2": version "13.0.2" resolved "https://registry.yarnpkg.com/@next/swc-linux-arm64-musl/-/swc-linux-arm64-musl-13.0.2.tgz#b9f33c5e17cfe04aa5769b717284cf80865761e6" integrity sha512-M6SdYjWgRrY3tJBxz0663zCRPTu5BRONmxlftKWWHv9LjAJ59neTLaGj4rp0A08DkJglZIoCkLOzLrzST6TGag== +"@next/swc-linux-arm64-musl@13.0.3-canary.1": + version "13.0.3-canary.1" + resolved "https://registry.yarnpkg.com/@next/swc-linux-arm64-musl/-/swc-linux-arm64-musl-13.0.3-canary.1.tgz#48e9fd2026bb4d158b8a4ed3d3466da69551ae2c" + integrity sha512-ojGdNQgvr+0auuS8w/a7pyVgEv7P+OuJz9SZqJ2YI7ksVE5FOuvedpZ/0IBT8hqE1N73ek8ueQ9p8JXtjGIQ4w== + "@next/swc-linux-x64-gnu@13.0.2": version "13.0.2" resolved "https://registry.yarnpkg.com/@next/swc-linux-x64-gnu/-/swc-linux-x64-gnu-13.0.2.tgz#29efcc2fd0122689d7e06c5b6b0883fe495db2bf" integrity sha512-pi63RoxvG4ES1KS06Zpm0MATVIXTs/TIbLbdckeLoM40u1d3mQl/+hSSrLRSxzc2OtyL8fh92sM4gkJrQXAMAw== +"@next/swc-linux-x64-gnu@13.0.3-canary.1": + version "13.0.3-canary.1" + resolved "https://registry.yarnpkg.com/@next/swc-linux-x64-gnu/-/swc-linux-x64-gnu-13.0.3-canary.1.tgz#a65db77b8b60b8c28f94535d8fccb49452ef35f7" + integrity sha512-1WPonLZm/RjUDfxfeRwBzwoXxQo01qqsDuOAvEyIbC0C0Vw4BAoyAX9tPa6REHbL5NzO+bKvW8iI01djNqYF2A== + "@next/swc-linux-x64-musl@13.0.2": version "13.0.2" resolved "https://registry.yarnpkg.com/@next/swc-linux-x64-musl/-/swc-linux-x64-musl-13.0.2.tgz#d68fdf6eefc57813fa91559c7089b49d6131ecab" integrity sha512-9Pv91gfYnDONgjtRm78n64b/c54+azeHtlnqBLTnIFWSMBDRl1/WDkhKWIj3fBGPLimtK7Tko3ULR3og9RRUPw== +"@next/swc-linux-x64-musl@13.0.3-canary.1": + version "13.0.3-canary.1" + resolved "https://registry.yarnpkg.com/@next/swc-linux-x64-musl/-/swc-linux-x64-musl-13.0.3-canary.1.tgz#86488b25977efb7d81b184dd8d09ad198bd50c34" + integrity sha512-Y5FOZAwZoKRdvHGKg6g5l0Vs0Jgxb1t0Y1g+ZPdPaVzYbGKNywm8L4zO2OFdGb0umpJzwmcn2GQEasm8ADTnZQ== + "@next/swc-win32-arm64-msvc@13.0.2": version "13.0.2" resolved "https://registry.yarnpkg.com/@next/swc-win32-arm64-msvc/-/swc-win32-arm64-msvc-13.0.2.tgz#acdcb3023045f60cca510f659a2349895e6405bd" integrity sha512-Nvewe6YZaizAkGHHprbMkYqQulBjZCHKBGKeFPwoPtOA+a2Qi4pZzc/qXFyC5/2A6Z0mr2U1zg9rd04WBYMwBw== +"@next/swc-win32-arm64-msvc@13.0.3-canary.1": + version "13.0.3-canary.1" + resolved "https://registry.yarnpkg.com/@next/swc-win32-arm64-msvc/-/swc-win32-arm64-msvc-13.0.3-canary.1.tgz#9db47746aacdbe794aa1197af0b0061b30fccd84" + integrity sha512-iVzm3051kyvUxA6ZeV3nBz1x0lRHR3v1bBMVpT939axOAFZDAVTy25FXnYLqXQ9t7dEraJTKMb9bZVnY8gw1yg== + "@next/swc-win32-ia32-msvc@13.0.2": version "13.0.2" resolved "https://registry.yarnpkg.com/@next/swc-win32-ia32-msvc/-/swc-win32-ia32-msvc-13.0.2.tgz#a78ee9211471768febac9df915c2a8dbbcd05e41" integrity sha512-ZUBYGZw5G3QrqDpRq1EWi3aHmvPZM8ijK5TFL6UbH16cYQ0JpANmuG2P66KB93Qe/lWWzbeAZk/tj1XqwoCuPA== +"@next/swc-win32-ia32-msvc@13.0.3-canary.1": + version "13.0.3-canary.1" + resolved "https://registry.yarnpkg.com/@next/swc-win32-ia32-msvc/-/swc-win32-ia32-msvc-13.0.3-canary.1.tgz#a56f2e816a7a9cb1563d079d9c22c20f82b632df" + integrity sha512-JV5WGfzrgcxuLjvcuGQiganSzrBkZuK8r+DBbjt7S0ABi8IMDc7cyYmq4Ck1T8baZosLyTjgP4o9MBG+Q9OAdw== + "@next/swc-win32-x64-msvc@13.0.2": version "13.0.2" resolved "https://registry.yarnpkg.com/@next/swc-win32-x64-msvc/-/swc-win32-x64-msvc-13.0.2.tgz#e86c2de910cd68a17974db5556d4588737412c68" integrity sha512-fA9uW1dm7C0mEYGcKlbmLcVm2sKcye+1kPxh2cM4jVR+kQQMtHWsjIzeSpe2grQLSDan06z4n6hbr8b1c3hA8w== +"@next/swc-win32-x64-msvc@13.0.3-canary.1": + version "13.0.3-canary.1" + resolved "https://registry.yarnpkg.com/@next/swc-win32-x64-msvc/-/swc-win32-x64-msvc-13.0.3-canary.1.tgz#760658db36623d0856d4ff0fb1a131c09e5b3893" + integrity sha512-7dNRSvMpvwBwh7n4ba6eXMXYw3fFRs92qtcJ2Kn9bsJk0jH8lBijRUAArL2PQ/4oAQD8go4dTkmcr4lMJ/Ivzg== + "@nodelib/fs.scandir@2.1.5": version "2.1.5" resolved "https://registry.yarnpkg.com/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz#7619c2eb21b25483f6d167548b4cfd5a7488c3d5" @@ -9159,6 +9229,32 @@ next@13.0.2: "@next/swc-win32-ia32-msvc" "13.0.2" "@next/swc-win32-x64-msvc" "13.0.2" +next@canary: + version "13.0.3-canary.1" + resolved "https://registry.yarnpkg.com/next/-/next-13.0.3-canary.1.tgz#ef5baa0d371e761089212af3a6a9516d162cfaff" + integrity sha512-ZgtbfQ3Dhf6xS0Weug7Yt+oeRFRFl/MDHCGQMZPftd5tbpFqiowLJWZ+N9926e8J7hP8n4m2BKIJEqVqoKJigA== + dependencies: + "@next/env" "13.0.3-canary.1" + "@swc/helpers" "0.4.11" + caniuse-lite "^1.0.30001406" + postcss "8.4.14" + styled-jsx "5.1.0" + use-sync-external-store "1.2.0" + optionalDependencies: + "@next/swc-android-arm-eabi" "13.0.3-canary.1" + "@next/swc-android-arm64" "13.0.3-canary.1" + "@next/swc-darwin-arm64" "13.0.3-canary.1" + "@next/swc-darwin-x64" "13.0.3-canary.1" + "@next/swc-freebsd-x64" "13.0.3-canary.1" + "@next/swc-linux-arm-gnueabihf" "13.0.3-canary.1" + "@next/swc-linux-arm64-gnu" "13.0.3-canary.1" + "@next/swc-linux-arm64-musl" "13.0.3-canary.1" + "@next/swc-linux-x64-gnu" "13.0.3-canary.1" + "@next/swc-linux-x64-musl" "13.0.3-canary.1" + "@next/swc-win32-arm64-msvc" "13.0.3-canary.1" + "@next/swc-win32-ia32-msvc" "13.0.3-canary.1" + "@next/swc-win32-x64-msvc" "13.0.3-canary.1" + node-addon-api@^3.2.1: version "3.2.1" resolved "https://registry.yarnpkg.com/node-addon-api/-/node-addon-api-3.2.1.tgz#81325e0a2117789c0128dab65e7e38f07ceba161" From d8c5ea52ef1e9901f184f3efd6798450b0e806c7 Mon Sep 17 00:00:00 2001 From: Jan Potoms <2109932+Janpot@users.noreply.github.com> Date: Mon, 14 Nov 2022 09:41:05 +0100 Subject: [PATCH 23/24] reset versions --- .circleci/config.yml | 2 +- package.json | 4 +- packages/toolpad-app/package.json | 4 +- yarn.lock | 188 +++++++++++++++--------------- 4 files changed, 99 insertions(+), 99 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index ec02ee7d9f..8a71d34fb5 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -187,7 +187,7 @@ jobs: -w /tests \ -e PLAYWRIGHT_TEST_BASE_URL=http://172.17.0.1:3000/ \ -e HTTPBIN_BASEURL=http://httpbin/ \ - mcr.microsoft.com/playwright:v1.28.0-alpha-nov-7-2022-focal \ + mcr.microsoft.com/playwright:v1.27.0-focal \ yarn test:integration --forbid-only docker-compose -f ./docker-compose.test.yml logs toolpad docker-compose -f ./docker-compose.test.yml down diff --git a/package.json b/package.json index 0827aec41b..36bd098e74 100644 --- a/package.json +++ b/package.json @@ -41,8 +41,8 @@ }, "devDependencies": { "@mui/monorepo": "https://github.com/mui/material-ui.git", - "@next/eslint-plugin-next": "13.0.2", - "@playwright/test": "next", + "@next/eslint-plugin-next": "13.0.3", + "@playwright/test": "^1.27.1", "@swc/helpers": "^0.4.12", "@testing-library/jest-dom": "^5.16.5", "@testing-library/react": "^13.4.0", diff --git a/packages/toolpad-app/package.json b/packages/toolpad-app/package.json index c0bd4d59ed..526be3a12f 100644 --- a/packages/toolpad-app/package.json +++ b/packages/toolpad-app/package.json @@ -81,7 +81,7 @@ "lodash-es": "^4.17.21", "mitt": "^3.0.0", "monaco-editor": "0.34.1", - "next": "canary", + "next": "^13.0.3", "node-fetch": "^2.6.7", "node-fetch-har": "^1.0.1", "path-to-regexp": "^6.2.1", @@ -130,7 +130,7 @@ "@types/whatwg-url": "^11.0.0", "ajv": "^8.11.0", "eslint": "8.27.0", - "eslint-config-next": "^13.0.2", + "eslint-config-next": "^13.0.3", "eslint-config-prettier": "^8.5.0", "eslint-plugin-import": "^2.26.0", "formidable": "^2.0.1", diff --git a/yarn.lock b/yarn.lock index ccf2250637..2773801ede 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2038,15 +2038,15 @@ resolved "https://registry.yarnpkg.com/@next/env/-/env-13.0.2.tgz#5fbd7b4146175ae406edfb4a38b62de8c880c09d" integrity sha512-Qb6WPuRriGIQ19qd6NBxpcrFOfj8ziN7l9eZUfwff5gl4zLXluqtuZPddYZM/oWjN53ZYcuRXzL+oowKyJeYtA== -"@next/env@13.0.3-canary.1": - version "13.0.3-canary.1" - resolved "https://registry.yarnpkg.com/@next/env/-/env-13.0.3-canary.1.tgz#d3708076dc410eb2f3ba208c3504ce0e842a1d50" - integrity sha512-/CmSfWbkdbGRfQP4A/9+BNZuzxNW4e6fJSLdQxl93gwP8RcFaQ/hYUR1weqId+KNM/ZQyJO52trSsenrOxeT4g== +"@next/env@13.0.3": + version "13.0.3" + resolved "https://registry.yarnpkg.com/@next/env/-/env-13.0.3.tgz#f2ecec9a6634aed28dca9e7b79bd65d9c516a1b4" + integrity sha512-/4WzeG61Ot/PxsghXkSqQJ6UohFfwXoZ3dtsypmR9EBP+OIax9JRq0trq8Z/LCT9Aq4JbihVkaazRWguORjTAw== -"@next/eslint-plugin-next@13.0.2": - version "13.0.2" - resolved "https://registry.yarnpkg.com/@next/eslint-plugin-next/-/eslint-plugin-next-13.0.2.tgz#89fe2144b37896f926e2bd9bed675396f1f697ce" - integrity sha512-W+fIIIaFU7Kct7Okx91C7XDRGolv/w2RUenX2yZFeeNVcuVzDIKUcNmckrYbYcwrNQUSXmtwrs3g8xwast0YtA== +"@next/eslint-plugin-next@13.0.3": + version "13.0.3" + resolved "https://registry.yarnpkg.com/@next/eslint-plugin-next/-/eslint-plugin-next-13.0.3.tgz#b81ff1f90d8fba7f02fcbe01e87275b0d6e77e4f" + integrity sha512-slmTAHNKDyc7jhx4VF8lFbmOPWJ3PShtUUWpb6x9+ga59CyOxgP6AdcDhxfapnWYACKe/TwYiaveufu7LqXgZg== dependencies: glob "7.1.7" @@ -2055,130 +2055,130 @@ resolved "https://registry.yarnpkg.com/@next/swc-android-arm-eabi/-/swc-android-arm-eabi-13.0.2.tgz#66669b8aab5062f554b8e9905d855679aabf0342" integrity sha512-X54UQCTFyOGnJP//Z71dPPlp4BCYcQL2ncikKXQcPzVpqPs4C3m+tKC8ivBNH6edAXkppwsLRz1/yQwgSZ9Swg== -"@next/swc-android-arm-eabi@13.0.3-canary.1": - version "13.0.3-canary.1" - resolved "https://registry.yarnpkg.com/@next/swc-android-arm-eabi/-/swc-android-arm-eabi-13.0.3-canary.1.tgz#108e80e2b0a5a67ded86c00aa8b16e6a4e213779" - integrity sha512-Igw1lXoPS5EnZQ7o5npsNUWXDFnMiizhTU7+M54QUaajS7HUSc8slYeqgYj8mnMBp6Pm/x4sJgi8n3MrDECAbw== +"@next/swc-android-arm-eabi@13.0.3": + version "13.0.3" + resolved "https://registry.yarnpkg.com/@next/swc-android-arm-eabi/-/swc-android-arm-eabi-13.0.3.tgz#87ce3b7d81ec198f5360f4393e5e03f112758696" + integrity sha512-uxfUoj65CdFc1gX2q7GtBX3DhKv9Kn343LMqGNvXyuTpYTGMmIiVY7b9yF8oLWRV0gVKqhZBZifUmoPE8SJU6Q== "@next/swc-android-arm64@13.0.2": version "13.0.2" resolved "https://registry.yarnpkg.com/@next/swc-android-arm64/-/swc-android-arm64-13.0.2.tgz#c0641d30525e0fb22bf1e2baf6c461d2d9e52f1a" integrity sha512-1P00Kv8uKaLubqo7JzPrTqgFAzSOmfb8iwqJrOb9in5IvTRtNGlkR4hU0sXzqbQNM/+SaYxze6Z5ry1IDyb/cQ== -"@next/swc-android-arm64@13.0.3-canary.1": - version "13.0.3-canary.1" - resolved "https://registry.yarnpkg.com/@next/swc-android-arm64/-/swc-android-arm64-13.0.3-canary.1.tgz#396ea7e73a4708355d1e58a3513da3a69cc7639a" - integrity sha512-CTNLjmnSVje8RvRUKR2kM9iuCKq66qfgwLDgWpG/kRARcBtOHp+AKxCqkBBSGyiHesw3KV2wdDLMf4rMiooTBg== +"@next/swc-android-arm64@13.0.3": + version "13.0.3" + resolved "https://registry.yarnpkg.com/@next/swc-android-arm64/-/swc-android-arm64-13.0.3.tgz#2029f759cb3e85082da15ced94704a68e390a0e9" + integrity sha512-t2k+WDfg7Cq2z/EnalKGsd/9E5F4Hdo1xu+UzZXYDpKUI9zgE6Bz8ajQb8m8txv3qOaWdKuDa5j5ziq9Acd1Xw== "@next/swc-darwin-arm64@13.0.2": version "13.0.2" resolved "https://registry.yarnpkg.com/@next/swc-darwin-arm64/-/swc-darwin-arm64-13.0.2.tgz#d7e01a33393e83456dbfdc41446bb8a923968ff7" integrity sha512-1zGIOkInkOLRv0QQGZ+3wffYsyKI4vIy62LYTvDWUn7TAYqnmXwougp9NSLqDeagLwgsv2URrykyAFixA/YqxA== -"@next/swc-darwin-arm64@13.0.3-canary.1": - version "13.0.3-canary.1" - resolved "https://registry.yarnpkg.com/@next/swc-darwin-arm64/-/swc-darwin-arm64-13.0.3-canary.1.tgz#fb2db32628301b2caf861c9fb4a977d01ee51c20" - integrity sha512-DFPsJnPAk9xzkBzBKz0l1fFB8ia+wQTUkXKg+PiZgiVVjoGFFuXqLsKS+De2pF+/mSAPBlcg73SAgB/Xd81vaQ== +"@next/swc-darwin-arm64@13.0.3": + version "13.0.3" + resolved "https://registry.yarnpkg.com/@next/swc-darwin-arm64/-/swc-darwin-arm64-13.0.3.tgz#f5deafd3feccf7c24b81df9a6a06d4d13bec254f" + integrity sha512-wV6j6SZ1bc/YHOLCLk9JVqaZTCCey6HBV7inl2DriHsHqIcO6F3+QiYf0KXwRP9BE0GSZZrYd5mZQm2JPTHdJA== "@next/swc-darwin-x64@13.0.2": version "13.0.2" resolved "https://registry.yarnpkg.com/@next/swc-darwin-x64/-/swc-darwin-x64-13.0.2.tgz#d4a3fbe51edf871a675d89a7afdc78174d1e5841" integrity sha512-ECDAjoMP1Y90cARaelS6X+k6BQx+MikAYJ8f/eaJrLur44NIOYc9HA/dgcTp5jenguY4yT8V+HCquLjAVle6fA== -"@next/swc-darwin-x64@13.0.3-canary.1": - version "13.0.3-canary.1" - resolved "https://registry.yarnpkg.com/@next/swc-darwin-x64/-/swc-darwin-x64-13.0.3-canary.1.tgz#23e5fa0c9892dbecaf234068bacdd1852174332d" - integrity sha512-hgtjVm8gPpqrmLpM1DOBkJjuBZvYB693c9K21uzE8TF8FFLl2/wAunmDFYBgnabAzq+vuzQKwmz5TV7svLDYjQ== +"@next/swc-darwin-x64@13.0.3": + version "13.0.3" + resolved "https://registry.yarnpkg.com/@next/swc-darwin-x64/-/swc-darwin-x64-13.0.3.tgz#4d4321c02b88fdd052e7a0cc8b3719ac16f8ad4b" + integrity sha512-jaI2CMuYWvUtRixV3AIjUhnxUDU1FKOR+8hADMhYt3Yz+pCKuj4RZ0n0nY5qUf3qT1AtvnJXEgyatSFJhSp/wQ== "@next/swc-freebsd-x64@13.0.2": version "13.0.2" resolved "https://registry.yarnpkg.com/@next/swc-freebsd-x64/-/swc-freebsd-x64-13.0.2.tgz#1b54c3f38d3b36f86663a8dfcc81ea05e01f5172" integrity sha512-2DcL/ofQdBnQX3IoI9sjlIAyLCD1oZoUBuhrhWbejvBQjutWrI0JTEv9uG69WcxWhVMm3BCsjv8GK2/68OKp7A== -"@next/swc-freebsd-x64@13.0.3-canary.1": - version "13.0.3-canary.1" - resolved "https://registry.yarnpkg.com/@next/swc-freebsd-x64/-/swc-freebsd-x64-13.0.3-canary.1.tgz#aec7efe8c1c7860a821e3abc9a434d6a3009aac5" - integrity sha512-PfpCCbPH5/fAURJHDXNWgGJkPUJ4UuNFk+t8ojxOnFOArLucDnLEl1dX058C/l2KUoSUVe+25eMYfGP8DlUr8A== +"@next/swc-freebsd-x64@13.0.3": + version "13.0.3" + resolved "https://registry.yarnpkg.com/@next/swc-freebsd-x64/-/swc-freebsd-x64-13.0.3.tgz#f2cbac9dc03172ef94275a6380cdd4d08024fcd4" + integrity sha512-nbyT0toBTJrcj5TCB9pVnQpGJ3utGyQj4CWegZs1ulaeUQ5Z7CS/qt8nRyYyOKYHtOdSCJ9Nw5F/RgKNkdpOdw== "@next/swc-linux-arm-gnueabihf@13.0.2": version "13.0.2" resolved "https://registry.yarnpkg.com/@next/swc-linux-arm-gnueabihf/-/swc-linux-arm-gnueabihf-13.0.2.tgz#18495cff32c0b2182cfbf677614219d7072214da" integrity sha512-Y3OQF1CSBSWW2vGkmvOIuOUNqOq8qX7f1ZpcKUVWP3/Uq++DZmVi9d18lgnSe1I3QFqc+nXWyun9ljsN83j0sw== -"@next/swc-linux-arm-gnueabihf@13.0.3-canary.1": - version "13.0.3-canary.1" - resolved "https://registry.yarnpkg.com/@next/swc-linux-arm-gnueabihf/-/swc-linux-arm-gnueabihf-13.0.3-canary.1.tgz#671fc7918846d7e84ab1151e86152785baa6af2b" - integrity sha512-cpRfril/NfPrUEAC9Auoz5ZYsrPjyCBzPRB0qWNUtyBY/553+W9uUwQJb9SwchHxz36zLMwEwLqyD7Ci9ib0qg== +"@next/swc-linux-arm-gnueabihf@13.0.3": + version "13.0.3" + resolved "https://registry.yarnpkg.com/@next/swc-linux-arm-gnueabihf/-/swc-linux-arm-gnueabihf-13.0.3.tgz#1b12006a25518ddc6ee9c58852149f82639876cf" + integrity sha512-1naLxYvRUQCoFCU1nMkcQueRc0Iux9xBv1L5pzH2ejtIWFg8BrSgyuluJG4nyAhFCx4WG863IEIkAaefOowVdA== "@next/swc-linux-arm64-gnu@13.0.2": version "13.0.2" resolved "https://registry.yarnpkg.com/@next/swc-linux-arm64-gnu/-/swc-linux-arm64-gnu-13.0.2.tgz#5fb2563651166c3c6f32bf9e2f9cc6a16a9ef783" integrity sha512-mNyzwsFF6kwZYEjnGicx9ksDZYEZvyzEc1BtCu8vdZi/v8UeixQwCiAT6FyYX9uxMPEkzk8qiU0t0u9gvltsKw== -"@next/swc-linux-arm64-gnu@13.0.3-canary.1": - version "13.0.3-canary.1" - resolved "https://registry.yarnpkg.com/@next/swc-linux-arm64-gnu/-/swc-linux-arm64-gnu-13.0.3-canary.1.tgz#a81530bb31b6ca04e6d476bbaefa41e10a57f7f5" - integrity sha512-9n09Eb1ApX+PFZv3oTzN8uNX+jeKgpc+PlNeJLyoK3UQx86xlUZCO/hMwMU8s+RT3bdHc73DciBPRQs9vD63Vw== +"@next/swc-linux-arm64-gnu@13.0.3": + version "13.0.3" + resolved "https://registry.yarnpkg.com/@next/swc-linux-arm64-gnu/-/swc-linux-arm64-gnu-13.0.3.tgz#f44a34fc073b91ad2ab7dd757c063e764e642ddc" + integrity sha512-3Z4A8JkuGWpMVbUhUPQInK/SLY+kijTT78Q/NZCrhLlyvwrVxaQALJNlXzxDLraUgv4oVH0Wz/FIw1W9PUUhxA== "@next/swc-linux-arm64-musl@13.0.2": version "13.0.2" resolved "https://registry.yarnpkg.com/@next/swc-linux-arm64-musl/-/swc-linux-arm64-musl-13.0.2.tgz#b9f33c5e17cfe04aa5769b717284cf80865761e6" integrity sha512-M6SdYjWgRrY3tJBxz0663zCRPTu5BRONmxlftKWWHv9LjAJ59neTLaGj4rp0A08DkJglZIoCkLOzLrzST6TGag== -"@next/swc-linux-arm64-musl@13.0.3-canary.1": - version "13.0.3-canary.1" - resolved "https://registry.yarnpkg.com/@next/swc-linux-arm64-musl/-/swc-linux-arm64-musl-13.0.3-canary.1.tgz#48e9fd2026bb4d158b8a4ed3d3466da69551ae2c" - integrity sha512-ojGdNQgvr+0auuS8w/a7pyVgEv7P+OuJz9SZqJ2YI7ksVE5FOuvedpZ/0IBT8hqE1N73ek8ueQ9p8JXtjGIQ4w== +"@next/swc-linux-arm64-musl@13.0.3": + version "13.0.3" + resolved "https://registry.yarnpkg.com/@next/swc-linux-arm64-musl/-/swc-linux-arm64-musl-13.0.3.tgz#5fd31e1149f151393b98239b5a6a96316459d19a" + integrity sha512-MoYe9SM40UaunTjC+01c9OILLH3uSoeri58kDMu3KF/EFEvn1LZ6ODeDj+SLGlAc95wn46hrRJS2BPmDDE+jFQ== "@next/swc-linux-x64-gnu@13.0.2": version "13.0.2" resolved "https://registry.yarnpkg.com/@next/swc-linux-x64-gnu/-/swc-linux-x64-gnu-13.0.2.tgz#29efcc2fd0122689d7e06c5b6b0883fe495db2bf" integrity sha512-pi63RoxvG4ES1KS06Zpm0MATVIXTs/TIbLbdckeLoM40u1d3mQl/+hSSrLRSxzc2OtyL8fh92sM4gkJrQXAMAw== -"@next/swc-linux-x64-gnu@13.0.3-canary.1": - version "13.0.3-canary.1" - resolved "https://registry.yarnpkg.com/@next/swc-linux-x64-gnu/-/swc-linux-x64-gnu-13.0.3-canary.1.tgz#a65db77b8b60b8c28f94535d8fccb49452ef35f7" - integrity sha512-1WPonLZm/RjUDfxfeRwBzwoXxQo01qqsDuOAvEyIbC0C0Vw4BAoyAX9tPa6REHbL5NzO+bKvW8iI01djNqYF2A== +"@next/swc-linux-x64-gnu@13.0.3": + version "13.0.3" + resolved "https://registry.yarnpkg.com/@next/swc-linux-x64-gnu/-/swc-linux-x64-gnu-13.0.3.tgz#a9b414123f26912fc830e5a65dd02e1ca56e2ead" + integrity sha512-z22T5WGnRanjLMXdF0NaNjSpBlEzzY43t5Ysp3nW1oI6gOkub6WdQNZeHIY7A2JwkgSWZmtjLtf+Fzzz38LHeQ== "@next/swc-linux-x64-musl@13.0.2": version "13.0.2" resolved "https://registry.yarnpkg.com/@next/swc-linux-x64-musl/-/swc-linux-x64-musl-13.0.2.tgz#d68fdf6eefc57813fa91559c7089b49d6131ecab" integrity sha512-9Pv91gfYnDONgjtRm78n64b/c54+azeHtlnqBLTnIFWSMBDRl1/WDkhKWIj3fBGPLimtK7Tko3ULR3og9RRUPw== -"@next/swc-linux-x64-musl@13.0.3-canary.1": - version "13.0.3-canary.1" - resolved "https://registry.yarnpkg.com/@next/swc-linux-x64-musl/-/swc-linux-x64-musl-13.0.3-canary.1.tgz#86488b25977efb7d81b184dd8d09ad198bd50c34" - integrity sha512-Y5FOZAwZoKRdvHGKg6g5l0Vs0Jgxb1t0Y1g+ZPdPaVzYbGKNywm8L4zO2OFdGb0umpJzwmcn2GQEasm8ADTnZQ== +"@next/swc-linux-x64-musl@13.0.3": + version "13.0.3" + resolved "https://registry.yarnpkg.com/@next/swc-linux-x64-musl/-/swc-linux-x64-musl-13.0.3.tgz#113f896de5e818ab40e6ec046538203cdd07dab0" + integrity sha512-ZOMT7zjBFmkusAtr47k8xs/oTLsNlTH6xvYb+iux7yly2hZGwhfBLzPGBsbeMZukZ96IphJTagT+C033s6LNVA== "@next/swc-win32-arm64-msvc@13.0.2": version "13.0.2" resolved "https://registry.yarnpkg.com/@next/swc-win32-arm64-msvc/-/swc-win32-arm64-msvc-13.0.2.tgz#acdcb3023045f60cca510f659a2349895e6405bd" integrity sha512-Nvewe6YZaizAkGHHprbMkYqQulBjZCHKBGKeFPwoPtOA+a2Qi4pZzc/qXFyC5/2A6Z0mr2U1zg9rd04WBYMwBw== -"@next/swc-win32-arm64-msvc@13.0.3-canary.1": - version "13.0.3-canary.1" - resolved "https://registry.yarnpkg.com/@next/swc-win32-arm64-msvc/-/swc-win32-arm64-msvc-13.0.3-canary.1.tgz#9db47746aacdbe794aa1197af0b0061b30fccd84" - integrity sha512-iVzm3051kyvUxA6ZeV3nBz1x0lRHR3v1bBMVpT939axOAFZDAVTy25FXnYLqXQ9t7dEraJTKMb9bZVnY8gw1yg== +"@next/swc-win32-arm64-msvc@13.0.3": + version "13.0.3" + resolved "https://registry.yarnpkg.com/@next/swc-win32-arm64-msvc/-/swc-win32-arm64-msvc-13.0.3.tgz#2ae5abe61f982a10f7742e97ac57f166751734aa" + integrity sha512-Q4BM16Djl+Oah9UdGrvjFYgoftYB2jNd+rtRGPX5Mmxo09Ry/KiLbOZnoUyoIxKc1xPyfqMXuaVsAFQLYs0KEQ== "@next/swc-win32-ia32-msvc@13.0.2": version "13.0.2" resolved "https://registry.yarnpkg.com/@next/swc-win32-ia32-msvc/-/swc-win32-ia32-msvc-13.0.2.tgz#a78ee9211471768febac9df915c2a8dbbcd05e41" integrity sha512-ZUBYGZw5G3QrqDpRq1EWi3aHmvPZM8ijK5TFL6UbH16cYQ0JpANmuG2P66KB93Qe/lWWzbeAZk/tj1XqwoCuPA== -"@next/swc-win32-ia32-msvc@13.0.3-canary.1": - version "13.0.3-canary.1" - resolved "https://registry.yarnpkg.com/@next/swc-win32-ia32-msvc/-/swc-win32-ia32-msvc-13.0.3-canary.1.tgz#a56f2e816a7a9cb1563d079d9c22c20f82b632df" - integrity sha512-JV5WGfzrgcxuLjvcuGQiganSzrBkZuK8r+DBbjt7S0ABi8IMDc7cyYmq4Ck1T8baZosLyTjgP4o9MBG+Q9OAdw== +"@next/swc-win32-ia32-msvc@13.0.3": + version "13.0.3" + resolved "https://registry.yarnpkg.com/@next/swc-win32-ia32-msvc/-/swc-win32-ia32-msvc-13.0.3.tgz#1a9c0d36c7dab1620257e85ada702c5acd9875d6" + integrity sha512-Sa8yGkNeRUsic8Qjf7MLIAfP0p0+einK/wIqJ8UO1y76j+8rRQu42AMs5H4Ax1fm9GEYq6I8njHtY59TVpTtGQ== "@next/swc-win32-x64-msvc@13.0.2": version "13.0.2" resolved "https://registry.yarnpkg.com/@next/swc-win32-x64-msvc/-/swc-win32-x64-msvc-13.0.2.tgz#e86c2de910cd68a17974db5556d4588737412c68" integrity sha512-fA9uW1dm7C0mEYGcKlbmLcVm2sKcye+1kPxh2cM4jVR+kQQMtHWsjIzeSpe2grQLSDan06z4n6hbr8b1c3hA8w== -"@next/swc-win32-x64-msvc@13.0.3-canary.1": - version "13.0.3-canary.1" - resolved "https://registry.yarnpkg.com/@next/swc-win32-x64-msvc/-/swc-win32-x64-msvc-13.0.3-canary.1.tgz#760658db36623d0856d4ff0fb1a131c09e5b3893" - integrity sha512-7dNRSvMpvwBwh7n4ba6eXMXYw3fFRs92qtcJ2Kn9bsJk0jH8lBijRUAArL2PQ/4oAQD8go4dTkmcr4lMJ/Ivzg== +"@next/swc-win32-x64-msvc@13.0.3": + version "13.0.3" + resolved "https://registry.yarnpkg.com/@next/swc-win32-x64-msvc/-/swc-win32-x64-msvc-13.0.3.tgz#7db0adbea7b4aafdbe2a7745d2c7c048903876ad" + integrity sha512-IAptmSqA7k4tQzaw2NAkoEjj3+Dz9ceuvlEHwYh770MMDL4V0ku2m+UHrmn5HUCEDHhgwwjg2nyf6728q2jr1w== "@nodelib/fs.scandir@2.1.5": version "2.1.5" @@ -2481,13 +2481,13 @@ dependencies: esquery "^1.0.1" -"@playwright/test@next": - version "1.28.0-alpha-nov-7-2022" - resolved "https://registry.yarnpkg.com/@playwright/test/-/test-1.28.0-alpha-nov-7-2022.tgz#27d702fddaf5f71521501199a9c698c7c4a4d6b4" - integrity sha512-BO33CR/2oLpQ7Fy7qq7ZU261sK7JmK7RN7fiQIzOOf2Fw6yt6Jo7u4U/eF9YSoTszzRrKWlKV3NXbyT36ElU/A== +"@playwright/test@^1.27.1": + version "1.27.1" + resolved "https://registry.yarnpkg.com/@playwright/test/-/test-1.27.1.tgz#9364d1e02021261211c8ff586d903faa79ce95c4" + integrity sha512-mrL2q0an/7tVqniQQF6RBL2saskjljXzqNcCOVMUjRIgE6Y38nCNaP+Dc2FBW06bcpD3tqIws/HT9qiMHbNU0A== dependencies: "@types/node" "*" - playwright-core "1.28.0-alpha-nov-7-2022" + playwright-core "1.27.1" "@polka/url@^1.0.0-next.20": version "1.0.0-next.21" @@ -3208,7 +3208,7 @@ "@typescript-eslint/typescript-estree" "4.33.0" debug "^4.3.1" -"@typescript-eslint/parser@^5.21.0", "@typescript-eslint/parser@^5.42.1": +"@typescript-eslint/parser@^5.42.0", "@typescript-eslint/parser@^5.42.1": version "5.42.1" resolved "https://registry.yarnpkg.com/@typescript-eslint/parser/-/parser-5.42.1.tgz#3e66156f2f74b11690b45950d8f5f28a62751d35" integrity sha512-kAV+NiNBWVQDY9gDJDToTE/NO8BHi4f6b7zTsVAJoTkmB/zlfOpiEVBzHOKtlgTndCKe8vj9F/PuolemZSh50Q== @@ -5827,14 +5827,14 @@ eslint-config-airbnb@^18.2.0: object.assign "^4.1.2" object.entries "^1.1.2" -eslint-config-next@^13.0.2: - version "13.0.2" - resolved "https://registry.yarnpkg.com/eslint-config-next/-/eslint-config-next-13.0.2.tgz#7c87837821ea7468e018ca41f3bf6fa37d53db68" - integrity sha512-SrrHp+zBDYLjOFZdM5b9aW/pliK687Xxfa+qpDuL08Z04ReHhmz3L+maXaAqgrEVZHQximP7nh0El4yNDJW+CA== +eslint-config-next@^13.0.3: + version "13.0.3" + resolved "https://registry.yarnpkg.com/eslint-config-next/-/eslint-config-next-13.0.3.tgz#f601bf8d64457e335a130ba1518bfd41942e142d" + integrity sha512-i2JoQP8gGv303GjXTonA27fm1ckRRkRoAP1WYEQgN0D2DDoFeBPqlJgHlMHnXKWjmNct/sW8jQEvy9am2juc8g== dependencies: - "@next/eslint-plugin-next" "13.0.2" + "@next/eslint-plugin-next" "13.0.3" "@rushstack/eslint-patch" "^1.1.3" - "@typescript-eslint/parser" "^5.21.0" + "@typescript-eslint/parser" "^5.42.0" eslint-import-resolver-node "^0.3.6" eslint-import-resolver-typescript "^2.7.1" eslint-plugin-import "^2.26.0" @@ -9225,31 +9225,31 @@ next@13.0.2: "@next/swc-win32-ia32-msvc" "13.0.2" "@next/swc-win32-x64-msvc" "13.0.2" -next@canary: - version "13.0.3-canary.1" - resolved "https://registry.yarnpkg.com/next/-/next-13.0.3-canary.1.tgz#ef5baa0d371e761089212af3a6a9516d162cfaff" - integrity sha512-ZgtbfQ3Dhf6xS0Weug7Yt+oeRFRFl/MDHCGQMZPftd5tbpFqiowLJWZ+N9926e8J7hP8n4m2BKIJEqVqoKJigA== +next@^13.0.3: + version "13.0.3" + resolved "https://registry.yarnpkg.com/next/-/next-13.0.3.tgz#577e2f7cdd9c9dba79353cd57fd854fe7e506a44" + integrity sha512-rFQeepcenRxKzeKlh1CsmEnxsJwhIERtbUjmYnKZyDInZsU06lvaGw5DT44rlNp1Rv2MT/e9vffZ8vK+ytwXHA== dependencies: - "@next/env" "13.0.3-canary.1" + "@next/env" "13.0.3" "@swc/helpers" "0.4.11" caniuse-lite "^1.0.30001406" postcss "8.4.14" styled-jsx "5.1.0" use-sync-external-store "1.2.0" optionalDependencies: - "@next/swc-android-arm-eabi" "13.0.3-canary.1" - "@next/swc-android-arm64" "13.0.3-canary.1" - "@next/swc-darwin-arm64" "13.0.3-canary.1" - "@next/swc-darwin-x64" "13.0.3-canary.1" - "@next/swc-freebsd-x64" "13.0.3-canary.1" - "@next/swc-linux-arm-gnueabihf" "13.0.3-canary.1" - "@next/swc-linux-arm64-gnu" "13.0.3-canary.1" - "@next/swc-linux-arm64-musl" "13.0.3-canary.1" - "@next/swc-linux-x64-gnu" "13.0.3-canary.1" - "@next/swc-linux-x64-musl" "13.0.3-canary.1" - "@next/swc-win32-arm64-msvc" "13.0.3-canary.1" - "@next/swc-win32-ia32-msvc" "13.0.3-canary.1" - "@next/swc-win32-x64-msvc" "13.0.3-canary.1" + "@next/swc-android-arm-eabi" "13.0.3" + "@next/swc-android-arm64" "13.0.3" + "@next/swc-darwin-arm64" "13.0.3" + "@next/swc-darwin-x64" "13.0.3" + "@next/swc-freebsd-x64" "13.0.3" + "@next/swc-linux-arm-gnueabihf" "13.0.3" + "@next/swc-linux-arm64-gnu" "13.0.3" + "@next/swc-linux-arm64-musl" "13.0.3" + "@next/swc-linux-x64-gnu" "13.0.3" + "@next/swc-linux-x64-musl" "13.0.3" + "@next/swc-win32-arm64-msvc" "13.0.3" + "@next/swc-win32-ia32-msvc" "13.0.3" + "@next/swc-win32-x64-msvc" "13.0.3" node-addon-api@^3.2.1: version "3.2.1" @@ -10190,10 +10190,10 @@ pkg-up@^3.1.0: dependencies: find-up "^3.0.0" -playwright-core@1.28.0-alpha-nov-7-2022: - version "1.28.0-alpha-nov-7-2022" - resolved "https://registry.yarnpkg.com/playwright-core/-/playwright-core-1.28.0-alpha-nov-7-2022.tgz#59dd67a82ffea5311f36fb998ae1996e8de5c8e1" - integrity sha512-KhFZfgE6TCVNNU2ncxIg0woFtgeofhPqHujm2BYkq2qEf1Uv/qd5u2m+HMJyZUDXRO+yhLTxH00ndV2ypt+vZw== +playwright-core@1.27.1: + version "1.27.1" + resolved "https://registry.yarnpkg.com/playwright-core/-/playwright-core-1.27.1.tgz#840ef662e55a3ed759d8b5d3d00a5f885a7184f4" + integrity sha512-9EmeXDncC2Pmp/z+teoVYlvmPWUC6ejSSYZUln7YaP89Z6lpAaiaAnqroUt/BoLo8tn7WYShcfaCh+xofZa44Q== pluralize@^3.1.0: version "3.1.0" From fc1bb1225d05d64b7cc152c957335d87830d2796 Mon Sep 17 00:00:00 2001 From: Jan Potoms <2109932+Janpot@users.noreply.github.com> Date: Mon, 14 Nov 2022 09:41:30 +0100 Subject: [PATCH 24/24] whitespace --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 8a71d34fb5..a90356da19 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -187,7 +187,7 @@ jobs: -w /tests \ -e PLAYWRIGHT_TEST_BASE_URL=http://172.17.0.1:3000/ \ -e HTTPBIN_BASEURL=http://httpbin/ \ - mcr.microsoft.com/playwright:v1.27.0-focal \ + mcr.microsoft.com/playwright:v1.27.0-focal \ yarn test:integration --forbid-only docker-compose -f ./docker-compose.test.yml logs toolpad docker-compose -f ./docker-compose.test.yml down