timetable-app

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | README | LICENSE

commit 39d2d139ff6ce940bae54d022542363635c18871
parent e810454772bd47c70222d3f4c3597074a2997e38
Author: Yuukin256 <52195426+Yuukin256@users.noreply.github.com>
Date:   Sun,  7 Apr 2024 00:07:16 +0900

時間割のExcelデータをアプリ内の保存形式に変換するツールを実装 (#28)

* パッケージアップデート等

* 曜日時限時間割データのExcelファイルをアプリの保存形式に変換するツールを作成

* 曜日時限時間割データ変換ツールのデータ形式を変更し、ツールの説明を追加

* クラス時間割データのExcelをアプリの保存形式に変換するツールを作成

* /tools ページを作成
Diffstat:
Mpackage.json | 13+++++++------
Mpnpm-lock.yaml | 430++++++++++++++++++++++++++++++++++---------------------------------------------
Asrc/client/features/tools/classStandardExcelToCode/hooks/useClassStandardDataInput.ts | 29+++++++++++++++++++++++++++++
Asrc/client/features/tools/classStandardExcelToCode/hooks/useClassStandardDataOutput.ts | 917+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Asrc/client/features/tools/classStandardExcelToCode/index.tsx | 70++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Asrc/client/features/tools/classStandardExcelToCode/schema.ts | 12++++++++++++
Asrc/client/features/tools/dayPeriodExcelToCode/hooks/useDayPeriodDataInput.ts | 29+++++++++++++++++++++++++++++
Asrc/client/features/tools/dayPeriodExcelToCode/hooks/useDayPeriodDataOutput.ts | 59+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Asrc/client/features/tools/dayPeriodExcelToCode/index.tsx | 70++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Asrc/client/features/tools/dayPeriodExcelToCode/schema.ts | 29+++++++++++++++++++++++++++++
Msrc/common/types/index.ts | 2+-
Asrc/pages/tools/class-standard-excel-to-code.tsx | 51+++++++++++++++++++++++++++++++++++++++++++++++++++
Asrc/pages/tools/day-period-excel-to-code.tsx | 47+++++++++++++++++++++++++++++++++++++++++++++++
Asrc/pages/tools/index.tsx | 42++++++++++++++++++++++++++++++++++++++++++
14 files changed, 1548 insertions(+), 252 deletions(-)

diff --git a/package.json b/package.json @@ -18,9 +18,9 @@ "@emotion/react": "^11.11.4", "@emotion/styled": "^11.11.0", "@hookform/resolvers": "^3.3.4", - "@mantine/hooks": "^6.0.21", + "@mantine/hooks": "^7.6.2", "@mui/icons-material": "^5.15.14", - "@mui/lab": "5.0.0-alpha.130", + "@mui/lab": "5.0.0-alpha.169", "@mui/material": "^5.15.14", "@mui/system": "^5.15.14", "@mui/x-date-pickers": "^6.19.8", @@ -47,14 +47,15 @@ "superjson": "^1.13.3", "swiper": "^8.4.7", "usehooks-ts": "^2.16.0", - "webpack": "^5.90.3", + "valibot": "^0.30.0", + "webpack": "^5.91.0", "zod": "^3.22.4" }, "devDependencies": { "@next/eslint-plugin-next": "^13.5.6", "@types/lodash": "^4.17.0", "@types/node": "^20.11.30", - "@types/react": "^18.2.67", + "@types/react": "^18.2.70", "@types/react-dom": "^18.2.22", "@typescript-eslint/eslint-plugin": "^5.62.0", "@typescript-eslint/parser": "^5.62.0", @@ -67,10 +68,10 @@ "eslint-plugin-unused-imports": "^2.0.0", "husky": "^8.0.3", "lint-staged": "^13.3.0", - "prettier": "^2.8.8", + "prettier": "^3.2.5", "prisma": "^5.11.0", "tsx": "^3.14.0", - "typescript": "^5.4.2" + "typescript": "^5.4.3" }, "packageManager": "pnpm@8.15.5" } diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml @@ -13,31 +13,31 @@ dependencies: version: 11.11.0 '@emotion/react': specifier: ^11.11.4 - version: 11.11.4(@types/react@18.2.67)(react@18.2.0) + version: 11.11.4(@types/react@18.2.70)(react@18.2.0) '@emotion/styled': specifier: ^11.11.0 - version: 11.11.0(@emotion/react@11.11.4)(@types/react@18.2.67)(react@18.2.0) + version: 11.11.0(@emotion/react@11.11.4)(@types/react@18.2.70)(react@18.2.0) '@hookform/resolvers': specifier: ^3.3.4 version: 3.3.4(react-hook-form@7.51.1) '@mantine/hooks': - specifier: ^6.0.21 - version: 6.0.21(react@18.2.0) + specifier: ^7.6.2 + version: 7.6.2(react@18.2.0) '@mui/icons-material': specifier: ^5.15.14 - version: 5.15.14(@mui/material@5.15.14)(@types/react@18.2.67)(react@18.2.0) + version: 5.15.14(@mui/material@5.15.14)(@types/react@18.2.70)(react@18.2.0) '@mui/lab': - specifier: 5.0.0-alpha.130 - version: 5.0.0-alpha.130(@emotion/react@11.11.4)(@emotion/styled@11.11.0)(@mui/material@5.15.14)(@types/react@18.2.67)(react-dom@18.2.0)(react@18.2.0) + specifier: 5.0.0-alpha.169 + version: 5.0.0-alpha.169(@emotion/react@11.11.4)(@emotion/styled@11.11.0)(@mui/material@5.15.14)(@types/react@18.2.70)(react-dom@18.2.0)(react@18.2.0) '@mui/material': specifier: ^5.15.14 - version: 5.15.14(@emotion/react@11.11.4)(@emotion/styled@11.11.0)(@types/react@18.2.67)(react-dom@18.2.0)(react@18.2.0) + version: 5.15.14(@emotion/react@11.11.4)(@emotion/styled@11.11.0)(@types/react@18.2.70)(react-dom@18.2.0)(react@18.2.0) '@mui/system': specifier: ^5.15.14 - version: 5.15.14(@emotion/react@11.11.4)(@emotion/styled@11.11.0)(@types/react@18.2.67)(react@18.2.0) + version: 5.15.14(@emotion/react@11.11.4)(@emotion/styled@11.11.0)(@types/react@18.2.70)(react@18.2.0) '@mui/x-date-pickers': specifier: ^6.19.8 - version: 6.19.8(@emotion/react@11.11.4)(@emotion/styled@11.11.0)(@mui/material@5.15.14)(@mui/system@5.15.14)(@types/react@18.2.67)(date-fns@3.6.0)(react-dom@18.2.0)(react@18.2.0) + version: 6.19.8(@emotion/react@11.11.4)(@emotion/styled@11.11.0)(@mui/material@5.15.14)(@mui/system@5.15.14)(@types/react@18.2.70)(date-fns@3.6.0)(react-dom@18.2.0)(react@18.2.0) '@prisma/client': specifier: ^5.11.0 version: 5.11.0(prisma@5.11.0) @@ -67,7 +67,7 @@ dependencies: version: 3.6.0 jotai: specifier: ^2.7.1 - version: 2.7.1(@types/react@18.2.67)(react@18.2.0) + version: 2.7.1(@types/react@18.2.70)(react@18.2.0) lodash: specifier: ^4.17.21 version: 4.17.21 @@ -76,7 +76,7 @@ dependencies: version: 13.4.1(@babel/core@7.24.3)(react-dom@18.2.0)(react@18.2.0) next-pwa: specifier: ^5.6.0 - version: 5.6.0(@babel/core@7.24.3)(next@13.4.1)(webpack@5.90.3) + version: 5.6.0(@babel/core@7.24.3)(next@13.4.1)(webpack@5.91.0) next-superjson-plugin: specifier: 0.5.7 version: 0.5.7(next@13.4.1)(superjson@1.13.3) @@ -107,9 +107,12 @@ dependencies: usehooks-ts: specifier: ^2.16.0 version: 2.16.0(react@18.2.0) + valibot: + specifier: ^0.30.0 + version: 0.30.0 webpack: - specifier: ^5.90.3 - version: 5.90.3 + specifier: ^5.91.0 + version: 5.91.0 zod: specifier: ^3.22.4 version: 3.22.4 @@ -125,23 +128,23 @@ devDependencies: specifier: ^20.11.30 version: 20.11.30 '@types/react': - specifier: ^18.2.67 - version: 18.2.67 + specifier: ^18.2.70 + version: 18.2.70 '@types/react-dom': specifier: ^18.2.22 version: 18.2.22 '@typescript-eslint/eslint-plugin': specifier: ^5.62.0 - version: 5.62.0(@typescript-eslint/parser@5.62.0)(eslint@8.57.0)(typescript@5.4.2) + version: 5.62.0(@typescript-eslint/parser@5.62.0)(eslint@8.57.0)(typescript@5.4.3) '@typescript-eslint/parser': specifier: ^5.62.0 - version: 5.62.0(eslint@8.57.0)(typescript@5.4.2) + version: 5.62.0(eslint@8.57.0)(typescript@5.4.3) eslint: specifier: ^8.57.0 version: 8.57.0 eslint-config-next: specifier: ^13.5.6 - version: 13.5.6(eslint@8.57.0)(typescript@5.4.2) + version: 13.5.6(eslint@8.57.0)(typescript@5.4.3) eslint-config-prettier: specifier: ^8.10.0 version: 8.10.0(eslint@8.57.0) @@ -164,8 +167,8 @@ devDependencies: specifier: ^13.3.0 version: 13.3.0 prettier: - specifier: ^2.8.8 - version: 2.8.8 + specifier: ^3.2.5 + version: 3.2.5 prisma: specifier: ^5.11.0 version: 5.11.0 @@ -173,8 +176,8 @@ devDependencies: specifier: ^3.14.0 version: 3.14.0 typescript: - specifier: ^5.4.2 - version: 5.4.2 + specifier: ^5.4.3 + version: 5.4.3 packages: @@ -1407,7 +1410,7 @@ packages: resolution: {integrity: sha512-W2P2c/VRW1/1tLox0mVUalvnWXxavmv/Oum2aPsRcoDJuob75FC3Y8FbpfLwUegRcxINtGUMPq0tFCvYNTBXNA==} dev: false - /@emotion/react@11.11.4(@types/react@18.2.67)(react@18.2.0): + /@emotion/react@11.11.4(@types/react@18.2.70)(react@18.2.0): resolution: {integrity: sha512-t8AjMlF0gHpvvxk5mAtCqR4vmxiGHCeJBaQO6gncUSdklELOgtwjerNY2yuJNfwnc6vi16U/+uMF+afIawJ9iw==} peerDependencies: '@types/react': '*' @@ -1423,7 +1426,7 @@ packages: '@emotion/use-insertion-effect-with-fallbacks': 1.0.1(react@18.2.0) '@emotion/utils': 1.2.1 '@emotion/weak-memoize': 0.3.1 - '@types/react': 18.2.67 + '@types/react': 18.2.70 hoist-non-react-statics: 3.3.2 react: 18.2.0 dev: false @@ -1442,7 +1445,7 @@ packages: resolution: {integrity: sha512-0QBtGvaqtWi+nx6doRwDdBIzhNdZrXUppvTM4dtZZWEGTXL/XE/yJxLMGlDT1Gt+UHH5IX1n+jkXyytE/av7OA==} dev: false - /@emotion/styled@11.11.0(@emotion/react@11.11.4)(@types/react@18.2.67)(react@18.2.0): + /@emotion/styled@11.11.0(@emotion/react@11.11.4)(@types/react@18.2.70)(react@18.2.0): resolution: {integrity: sha512-hM5Nnvu9P3midq5aaXj4I+lnSfNi7Pmd4EWk1fOZ3pxookaQTNew6bp4JaCBYM4HVFZF9g7UjJmsUmC2JlxOng==} peerDependencies: '@emotion/react': ^11.0.0-rc.0 @@ -1455,11 +1458,11 @@ packages: '@babel/runtime': 7.24.1 '@emotion/babel-plugin': 11.11.0 '@emotion/is-prop-valid': 1.2.2 - '@emotion/react': 11.11.4(@types/react@18.2.67)(react@18.2.0) + '@emotion/react': 11.11.4(@types/react@18.2.70)(react@18.2.0) '@emotion/serialize': 1.1.3 '@emotion/use-insertion-effect-with-fallbacks': 1.0.1(react@18.2.0) '@emotion/utils': 1.2.1 - '@types/react': 18.2.67 + '@types/react': 18.2.70 react: 18.2.0 dev: false @@ -1811,39 +1814,15 @@ packages: '@jridgewell/sourcemap-codec': 1.4.15 dev: false - /@mantine/hooks@6.0.21(react@18.2.0): - resolution: {integrity: sha512-sYwt5wai25W6VnqHbS5eamey30/HD5dNXaZuaVEAJ2i2bBv8C0cCiczygMDpAFiSYdXoSMRr/SZ2CrrPTzeNew==} + /@mantine/hooks@7.6.2(react@18.2.0): + resolution: {integrity: sha512-ZrOgrZHoIGCDKrr2/9njDgK0al+jjusYQFlmR0YyEFyRtgY6eNSI4zuYLcAPx1haHmUm5RsLBrqY6Iy/TLdGXA==} peerDependencies: - react: '>=16.8.0' - dependencies: - react: 18.2.0 - dev: false - - /@mui/base@5.0.0-beta.1(@types/react@18.2.67)(react-dom@18.2.0)(react@18.2.0): - resolution: {integrity: sha512-xrkDCeu3JQE+JjJUnJnOrdQJMXwKhbV4AW+FRjMIj5i9cHK3BAuatG/iqbf1M+jklVWLk0KdbgioKwK+03aYbA==} - engines: {node: '>=12.0.0'} - peerDependencies: - '@types/react': ^17.0.0 || ^18.0.0 - react: ^17.0.0 || ^18.0.0 - react-dom: ^17.0.0 || ^18.0.0 - peerDependenciesMeta: - '@types/react': - optional: true + react: ^18.2.0 dependencies: - '@babel/runtime': 7.24.1 - '@emotion/is-prop-valid': 1.2.2 - '@mui/types': 7.2.14(@types/react@18.2.67) - '@mui/utils': 5.15.14(@types/react@18.2.67)(react@18.2.0) - '@popperjs/core': 2.11.8 - '@types/react': 18.2.67 - clsx: 1.2.1 - prop-types: 15.8.1 react: 18.2.0 - react-dom: 18.2.0(react@18.2.0) - react-is: 18.2.0 dev: false - /@mui/base@5.0.0-beta.40(@types/react@18.2.67)(react-dom@18.2.0)(react@18.2.0): + /@mui/base@5.0.0-beta.40(@types/react@18.2.70)(react-dom@18.2.0)(react@18.2.0): resolution: {integrity: sha512-I/lGHztkCzvwlXpjD2+SNmvNQvB4227xBXhISPjEaJUXGImOQ9f3D2Yj/T3KasSI/h0MLWy74X0J6clhPmsRbQ==} engines: {node: '>=12.0.0'} peerDependencies: @@ -1856,10 +1835,10 @@ packages: dependencies: '@babel/runtime': 7.24.1 '@floating-ui/react-dom': 2.0.8(react-dom@18.2.0)(react@18.2.0) - '@mui/types': 7.2.14(@types/react@18.2.67) - '@mui/utils': 5.15.14(@types/react@18.2.67)(react@18.2.0) + '@mui/types': 7.2.14(@types/react@18.2.70) + '@mui/utils': 5.15.14(@types/react@18.2.70)(react@18.2.0) '@popperjs/core': 2.11.8 - '@types/react': 18.2.67 + '@types/react': 18.2.70 clsx: 2.1.0 prop-types: 15.8.1 react: 18.2.0 @@ -1870,7 +1849,7 @@ packages: resolution: {integrity: sha512-on75VMd0XqZfaQW+9pGjSNiqW+ghc5E2ZSLRBXwcXl/C4YzjfyjrLPhrEpKnR9Uym9KXBvxrhoHfPcczYHweyA==} dev: false - /@mui/icons-material@5.15.14(@mui/material@5.15.14)(@types/react@18.2.67)(react@18.2.0): + /@mui/icons-material@5.15.14(@mui/material@5.15.14)(@types/react@18.2.70)(react@18.2.0): resolution: {integrity: sha512-vj/51k7MdFmt+XVw94sl30SCvGx6+wJLsNYjZRgxhS6y3UtnWnypMOsm3Kmg8TN+P0dqwsjy4/fX7B1HufJIhw==} engines: {node: '>=12.0.0'} peerDependencies: @@ -1882,18 +1861,18 @@ packages: optional: true dependencies: '@babel/runtime': 7.24.1 - '@mui/material': 5.15.14(@emotion/react@11.11.4)(@emotion/styled@11.11.0)(@types/react@18.2.67)(react-dom@18.2.0)(react@18.2.0) - '@types/react': 18.2.67 + '@mui/material': 5.15.14(@emotion/react@11.11.4)(@emotion/styled@11.11.0)(@types/react@18.2.70)(react-dom@18.2.0)(react@18.2.0) + '@types/react': 18.2.70 react: 18.2.0 dev: false - /@mui/lab@5.0.0-alpha.130(@emotion/react@11.11.4)(@emotion/styled@11.11.0)(@mui/material@5.15.14)(@types/react@18.2.67)(react-dom@18.2.0)(react@18.2.0): - resolution: {integrity: sha512-pBZGIVXCzafvu7nwjfuKA3MhFyXnB4CIexfr8X4qS0GOY0UcDkO5LemWeeBKGXK2IanbQN4toO5mv8kzQIbp9Q==} + /@mui/lab@5.0.0-alpha.169(@emotion/react@11.11.4)(@emotion/styled@11.11.0)(@mui/material@5.15.14)(@types/react@18.2.70)(react-dom@18.2.0)(react@18.2.0): + resolution: {integrity: sha512-h6xe1K6ISKUbyxTDgdvql4qoDP6+q8ad5fg9nXQxGLUrIeT2jVrBuT/jRECSTufbnhzP+V5kulvYxaMfM8rEdA==} engines: {node: '>=12.0.0'} peerDependencies: '@emotion/react': ^11.5.0 '@emotion/styled': ^11.3.0 - '@mui/material': ^5.0.0 + '@mui/material': '>=5.15.0' '@types/react': ^17.0.0 || ^18.0.0 react: ^17.0.0 || ^18.0.0 react-dom: ^17.0.0 || ^18.0.0 @@ -1906,22 +1885,21 @@ packages: optional: true dependencies: '@babel/runtime': 7.24.1 - '@emotion/react': 11.11.4(@types/react@18.2.67)(react@18.2.0) - '@emotion/styled': 11.11.0(@emotion/react@11.11.4)(@types/react@18.2.67)(react@18.2.0) - '@mui/base': 5.0.0-beta.1(@types/react@18.2.67)(react-dom@18.2.0)(react@18.2.0) - '@mui/material': 5.15.14(@emotion/react@11.11.4)(@emotion/styled@11.11.0)(@types/react@18.2.67)(react-dom@18.2.0)(react@18.2.0) - '@mui/system': 5.15.14(@emotion/react@11.11.4)(@emotion/styled@11.11.0)(@types/react@18.2.67)(react@18.2.0) - '@mui/types': 7.2.14(@types/react@18.2.67) - '@mui/utils': 5.15.14(@types/react@18.2.67)(react@18.2.0) - '@types/react': 18.2.67 - clsx: 1.2.1 + '@emotion/react': 11.11.4(@types/react@18.2.70)(react@18.2.0) + '@emotion/styled': 11.11.0(@emotion/react@11.11.4)(@types/react@18.2.70)(react@18.2.0) + '@mui/base': 5.0.0-beta.40(@types/react@18.2.70)(react-dom@18.2.0)(react@18.2.0) + '@mui/material': 5.15.14(@emotion/react@11.11.4)(@emotion/styled@11.11.0)(@types/react@18.2.70)(react-dom@18.2.0)(react@18.2.0) + '@mui/system': 5.15.14(@emotion/react@11.11.4)(@emotion/styled@11.11.0)(@types/react@18.2.70)(react@18.2.0) + '@mui/types': 7.2.14(@types/react@18.2.70) + '@mui/utils': 5.15.14(@types/react@18.2.70)(react@18.2.0) + '@types/react': 18.2.70 + clsx: 2.1.0 prop-types: 15.8.1 react: 18.2.0 react-dom: 18.2.0(react@18.2.0) - react-is: 18.2.0 dev: false - /@mui/material@5.15.14(@emotion/react@11.11.4)(@emotion/styled@11.11.0)(@types/react@18.2.67)(react-dom@18.2.0)(react@18.2.0): + /@mui/material@5.15.14(@emotion/react@11.11.4)(@emotion/styled@11.11.0)(@types/react@18.2.70)(react-dom@18.2.0)(react@18.2.0): resolution: {integrity: sha512-kEbRw6fASdQ1SQ7LVdWR5OlWV3y7Y54ZxkLzd6LV5tmz+NpO3MJKZXSfgR0LHMP7meKsPiMm4AuzV0pXDpk/BQ==} engines: {node: '>=12.0.0'} peerDependencies: @@ -1939,14 +1917,14 @@ packages: optional: true dependencies: '@babel/runtime': 7.24.1 - '@emotion/react': 11.11.4(@types/react@18.2.67)(react@18.2.0) - '@emotion/styled': 11.11.0(@emotion/react@11.11.4)(@types/react@18.2.67)(react@18.2.0) - '@mui/base': 5.0.0-beta.40(@types/react@18.2.67)(react-dom@18.2.0)(react@18.2.0) + '@emotion/react': 11.11.4(@types/react@18.2.70)(react@18.2.0) + '@emotion/styled': 11.11.0(@emotion/react@11.11.4)(@types/react@18.2.70)(react@18.2.0) + '@mui/base': 5.0.0-beta.40(@types/react@18.2.70)(react-dom@18.2.0)(react@18.2.0) '@mui/core-downloads-tracker': 5.15.14 - '@mui/system': 5.15.14(@emotion/react@11.11.4)(@emotion/styled@11.11.0)(@types/react@18.2.67)(react@18.2.0) - '@mui/types': 7.2.14(@types/react@18.2.67) - '@mui/utils': 5.15.14(@types/react@18.2.67)(react@18.2.0) - '@types/react': 18.2.67 + '@mui/system': 5.15.14(@emotion/react@11.11.4)(@emotion/styled@11.11.0)(@types/react@18.2.70)(react@18.2.0) + '@mui/types': 7.2.14(@types/react@18.2.70) + '@mui/utils': 5.15.14(@types/react@18.2.70)(react@18.2.0) + '@types/react': 18.2.70 '@types/react-transition-group': 4.4.10 clsx: 2.1.0 csstype: 3.1.3 @@ -1957,7 +1935,7 @@ packages: react-transition-group: 4.4.5(react-dom@18.2.0)(react@18.2.0) dev: false - /@mui/private-theming@5.15.14(@types/react@18.2.67)(react@18.2.0): + /@mui/private-theming@5.15.14(@types/react@18.2.70)(react@18.2.0): resolution: {integrity: sha512-UH0EiZckOWcxiXLX3Jbb0K7rC8mxTr9L9l6QhOZxYc4r8FHUkefltV9VDGLrzCaWh30SQiJvAEd7djX3XXY6Xw==} engines: {node: '>=12.0.0'} peerDependencies: @@ -1968,8 +1946,8 @@ packages: optional: true dependencies: '@babel/runtime': 7.24.1 - '@mui/utils': 5.15.14(@types/react@18.2.67)(react@18.2.0) - '@types/react': 18.2.67 + '@mui/utils': 5.15.14(@types/react@18.2.70)(react@18.2.0) + '@types/react': 18.2.70 prop-types: 15.8.1 react: 18.2.0 dev: false @@ -1989,14 +1967,14 @@ packages: dependencies: '@babel/runtime': 7.24.1 '@emotion/cache': 11.11.0 - '@emotion/react': 11.11.4(@types/react@18.2.67)(react@18.2.0) - '@emotion/styled': 11.11.0(@emotion/react@11.11.4)(@types/react@18.2.67)(react@18.2.0) + '@emotion/react': 11.11.4(@types/react@18.2.70)(react@18.2.0) + '@emotion/styled': 11.11.0(@emotion/react@11.11.4)(@types/react@18.2.70)(react@18.2.0) csstype: 3.1.3 prop-types: 15.8.1 react: 18.2.0 dev: false - /@mui/system@5.15.14(@emotion/react@11.11.4)(@emotion/styled@11.11.0)(@types/react@18.2.67)(react@18.2.0): + /@mui/system@5.15.14(@emotion/react@11.11.4)(@emotion/styled@11.11.0)(@types/react@18.2.70)(react@18.2.0): resolution: {integrity: sha512-auXLXzUaCSSOLqJXmsAaq7P96VPRXg2Rrz6OHNV7lr+kB8lobUF+/N84Vd9C4G/wvCXYPs5TYuuGBRhcGbiBGg==} engines: {node: '>=12.0.0'} peerDependencies: @@ -2013,20 +1991,20 @@ packages: optional: true dependencies: '@babel/runtime': 7.24.1 - '@emotion/react': 11.11.4(@types/react@18.2.67)(react@18.2.0) - '@emotion/styled': 11.11.0(@emotion/react@11.11.4)(@types/react@18.2.67)(react@18.2.0) - '@mui/private-theming': 5.15.14(@types/react@18.2.67)(react@18.2.0) + '@emotion/react': 11.11.4(@types/react@18.2.70)(react@18.2.0) + '@emotion/styled': 11.11.0(@emotion/react@11.11.4)(@types/react@18.2.70)(react@18.2.0) + '@mui/private-theming': 5.15.14(@types/react@18.2.70)(react@18.2.0) '@mui/styled-engine': 5.15.14(@emotion/react@11.11.4)(@emotion/styled@11.11.0)(react@18.2.0) - '@mui/types': 7.2.14(@types/react@18.2.67) - '@mui/utils': 5.15.14(@types/react@18.2.67)(react@18.2.0) - '@types/react': 18.2.67 + '@mui/types': 7.2.14(@types/react@18.2.70) + '@mui/utils': 5.15.14(@types/react@18.2.70)(react@18.2.0) + '@types/react': 18.2.70 clsx: 2.1.0 csstype: 3.1.3 prop-types: 15.8.1 react: 18.2.0 dev: false - /@mui/types@7.2.14(@types/react@18.2.67): + /@mui/types@7.2.14(@types/react@18.2.70): resolution: {integrity: sha512-MZsBZ4q4HfzBsywtXgM1Ksj6HDThtiwmOKUXH1pKYISI9gAVXCNHNpo7TlGoGrBaYWZTdNoirIN7JsQcQUjmQQ==} peerDependencies: '@types/react': ^17.0.0 || ^18.0.0 @@ -2034,10 +2012,10 @@ packages: '@types/react': optional: true dependencies: - '@types/react': 18.2.67 + '@types/react': 18.2.70 dev: false - /@mui/utils@5.15.14(@types/react@18.2.67)(react@18.2.0): + /@mui/utils@5.15.14(@types/react@18.2.70)(react@18.2.0): resolution: {integrity: sha512-0lF/7Hh/ezDv5X7Pry6enMsbYyGKjADzvHyo3Qrc/SSlTsQ1VkbDMbH0m2t3OR5iIVLwMoxwM7yGd+6FCMtTFA==} engines: {node: '>=12.0.0'} peerDependencies: @@ -2048,14 +2026,14 @@ packages: optional: true dependencies: '@babel/runtime': 7.24.1 - '@types/prop-types': 15.7.11 - '@types/react': 18.2.67 + '@types/prop-types': 15.7.12 + '@types/react': 18.2.70 prop-types: 15.8.1 react: 18.2.0 react-is: 18.2.0 dev: false - /@mui/x-date-pickers@6.19.8(@emotion/react@11.11.4)(@emotion/styled@11.11.0)(@mui/material@5.15.14)(@mui/system@5.15.14)(@types/react@18.2.67)(date-fns@3.6.0)(react-dom@18.2.0)(react@18.2.0): + /@mui/x-date-pickers@6.19.8(@emotion/react@11.11.4)(@emotion/styled@11.11.0)(@mui/material@5.15.14)(@mui/system@5.15.14)(@types/react@18.2.70)(date-fns@3.6.0)(react-dom@18.2.0)(react@18.2.0): resolution: {integrity: sha512-6wgc2DoRTR9/mKesku4CVCKr9yYkY3FI2Oy/wshLTs2rFkw2Z10uxXFHBR9ugEtNPNCQv0qqwldElenYI97wsA==} engines: {node: '>=14.0.0'} peerDependencies: @@ -2093,12 +2071,12 @@ packages: optional: true dependencies: '@babel/runtime': 7.24.1 - '@emotion/react': 11.11.4(@types/react@18.2.67)(react@18.2.0) - '@emotion/styled': 11.11.0(@emotion/react@11.11.4)(@types/react@18.2.67)(react@18.2.0) - '@mui/base': 5.0.0-beta.40(@types/react@18.2.67)(react-dom@18.2.0)(react@18.2.0) - '@mui/material': 5.15.14(@emotion/react@11.11.4)(@emotion/styled@11.11.0)(@types/react@18.2.67)(react-dom@18.2.0)(react@18.2.0) - '@mui/system': 5.15.14(@emotion/react@11.11.4)(@emotion/styled@11.11.0)(@types/react@18.2.67)(react@18.2.0) - '@mui/utils': 5.15.14(@types/react@18.2.67)(react@18.2.0) + '@emotion/react': 11.11.4(@types/react@18.2.70)(react@18.2.0) + '@emotion/styled': 11.11.0(@emotion/react@11.11.4)(@types/react@18.2.70)(react@18.2.0) + '@mui/base': 5.0.0-beta.40(@types/react@18.2.70)(react-dom@18.2.0)(react@18.2.0) + '@mui/material': 5.15.14(@emotion/react@11.11.4)(@emotion/styled@11.11.0)(@types/react@18.2.70)(react-dom@18.2.0)(react@18.2.0) + '@mui/system': 5.15.14(@emotion/react@11.11.4)(@emotion/styled@11.11.0)(@types/react@18.2.70)(react@18.2.0) + '@mui/utils': 5.15.14(@types/react@18.2.70)(react@18.2.0) '@types/react-transition-group': 4.4.10 clsx: 2.1.0 date-fns: 3.6.0 @@ -2442,7 +2420,7 @@ packages: /@types/hoist-non-react-statics@3.3.5: resolution: {integrity: sha512-SbcrWzkKBw2cdwRTwQAswfpB9g9LJWfjtUeW/jvNwbhC8cpmmNYVePa+ncbUe0rGTQ7G3Ff6mYUN2VMfLVr+Sg==} dependencies: - '@types/react': 18.2.67 + '@types/react': 18.2.70 hoist-non-react-statics: 3.3.2 dev: false @@ -2470,25 +2448,25 @@ packages: resolution: {integrity: sha512-dISoDXWWQwUquiKsyZ4Ng+HX2KsPL7LyHKHQwgGFEA3IaKac4Obd+h2a/a6waisAoepJlBcx9paWqjA8/HVjCw==} dev: false - /@types/prop-types@15.7.11: - resolution: {integrity: sha512-ga8y9v9uyeiLdpKddhxYQkxNDrfvuPrlFb0N1qnZZByvcElJaXthF1UhvCh9TLWJBEHeNtdnbysW7Y6Uq8CVng==} + /@types/prop-types@15.7.12: + resolution: {integrity: sha512-5zvhXYtRNRluoE/jAp4GVsSduVUzNWKkOZrCDBWYtE7biZywwdC2AcEzg+cSMLFRfVgeAFqpfNabiPjxFddV1Q==} /@types/react-dom@18.2.22: resolution: {integrity: sha512-fHkBXPeNtfvri6gdsMYyW+dW7RXFo6Ad09nLFK0VQWR7yGLai/Cyvyj696gbwYvBnhGtevUG9cET0pmUbMtoPQ==} dependencies: - '@types/react': 18.2.67 + '@types/react': 18.2.70 dev: true /@types/react-transition-group@4.4.10: resolution: {integrity: sha512-hT/+s0VQs2ojCX823m60m5f0sL5idt9SO6Tj6Dg+rdphGPIeJbJ6CxvBYkgkGKrYeDjvIpKTR38UzmtHJOGW3Q==} dependencies: - '@types/react': 18.2.67 + '@types/react': 18.2.70 dev: false - /@types/react@18.2.67: - resolution: {integrity: sha512-vkIE2vTIMHQ/xL0rgmuoECBCkZFZeHr49HeWSc24AptMbNRo7pwSBvj73rlJJs9fGKj0koS+V7kQB1jHS0uCgw==} + /@types/react@18.2.70: + resolution: {integrity: sha512-hjlM2hho2vqklPhopNkXkdkeq6Lv8WSZTpr7956zY+3WS5cfYUewtCzsJLsbW5dEv3lfSeQ4W14ZFeKC437JRQ==} dependencies: - '@types/prop-types': 15.7.11 + '@types/prop-types': 15.7.12 '@types/scheduler': 0.16.8 csstype: 3.1.3 @@ -2509,7 +2487,7 @@ packages: resolution: {integrity: sha512-ScaPdn1dQczgbl0QFTeTOmVHFULt394XJgOQNoyVhZ6r2vLnMLJfBPd53SB52T/3G36VI1/g2MZaX0cwDuXsfw==} dev: false - /@typescript-eslint/eslint-plugin@5.62.0(@typescript-eslint/parser@5.62.0)(eslint@8.57.0)(typescript@5.4.2): + /@typescript-eslint/eslint-plugin@5.62.0(@typescript-eslint/parser@5.62.0)(eslint@8.57.0)(typescript@5.4.3): resolution: {integrity: sha512-TiZzBSJja/LbhNPvk6yc0JrX9XqhQ0hdh6M2svYfsHGejaKFIAGd9MQ+ERIMzLGlN/kZoYIgdxFV0PuljTKXag==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} peerDependencies: @@ -2521,23 +2499,23 @@ packages: optional: true dependencies: '@eslint-community/regexpp': 4.10.0 - '@typescript-eslint/parser': 5.62.0(eslint@8.57.0)(typescript@5.4.2) + '@typescript-eslint/parser': 5.62.0(eslint@8.57.0)(typescript@5.4.3) '@typescript-eslint/scope-manager': 5.62.0 - '@typescript-eslint/type-utils': 5.62.0(eslint@8.57.0)(typescript@5.4.2) - '@typescript-eslint/utils': 5.62.0(eslint@8.57.0)(typescript@5.4.2) + '@typescript-eslint/type-utils': 5.62.0(eslint@8.57.0)(typescript@5.4.3) + '@typescript-eslint/utils': 5.62.0(eslint@8.57.0)(typescript@5.4.3) debug: 4.3.4 eslint: 8.57.0 graphemer: 1.4.0 ignore: 5.3.1 natural-compare-lite: 1.4.0 semver: 7.6.0 - tsutils: 3.21.0(typescript@5.4.2) - typescript: 5.4.2 + tsutils: 3.21.0(typescript@5.4.3) + typescript: 5.4.3 transitivePeerDependencies: - supports-color dev: true - /@typescript-eslint/parser@5.62.0(eslint@8.57.0)(typescript@5.4.2): + /@typescript-eslint/parser@5.62.0(eslint@8.57.0)(typescript@5.4.3): resolution: {integrity: sha512-VlJEV0fOQ7BExOsHYAGrgbEiZoi8D+Bl2+f6V2RrXerRSylnp+ZBHmPvaIa8cz0Ajx7WO7Z5RqfgYg7ED1nRhA==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} peerDependencies: @@ -2549,10 +2527,10 @@ packages: dependencies: '@typescript-eslint/scope-manager': 5.62.0 '@typescript-eslint/types': 5.62.0 - '@typescript-eslint/typescript-estree': 5.62.0(typescript@5.4.2) + '@typescript-eslint/typescript-estree': 5.62.0(typescript@5.4.3) debug: 4.3.4 eslint: 8.57.0 - typescript: 5.4.2 + typescript: 5.4.3 transitivePeerDependencies: - supports-color dev: true @@ -2565,7 +2543,7 @@ packages: '@typescript-eslint/visitor-keys': 5.62.0 dev: true - /@typescript-eslint/type-utils@5.62.0(eslint@8.57.0)(typescript@5.4.2): + /@typescript-eslint/type-utils@5.62.0(eslint@8.57.0)(typescript@5.4.3): resolution: {integrity: sha512-xsSQreu+VnfbqQpW5vnCJdq1Z3Q0U31qiWmRhr98ONQmcp/yhiPJFPq8MXiJVLiksmOKSjIldZzkebzHuCGzew==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} peerDependencies: @@ -2575,12 +2553,12 @@ packages: typescript: optional: true dependencies: - '@typescript-eslint/typescript-estree': 5.62.0(typescript@5.4.2) - '@typescript-eslint/utils': 5.62.0(eslint@8.57.0)(typescript@5.4.2) + '@typescript-eslint/typescript-estree': 5.62.0(typescript@5.4.3) + '@typescript-eslint/utils': 5.62.0(eslint@8.57.0)(typescript@5.4.3) debug: 4.3.4 eslint: 8.57.0 - tsutils: 3.21.0(typescript@5.4.2) - typescript: 5.4.2 + tsutils: 3.21.0(typescript@5.4.3) + typescript: 5.4.3 transitivePeerDependencies: - supports-color dev: true @@ -2590,7 +2568,7 @@ packages: engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} dev: true - /@typescript-eslint/typescript-estree@5.62.0(typescript@5.4.2): + /@typescript-eslint/typescript-estree@5.62.0(typescript@5.4.3): resolution: {integrity: sha512-CmcQ6uY7b9y694lKdRB8FEel7JbU/40iSAPomu++SjLMntB+2Leay2LO6i8VnJk58MtE9/nQSFIH6jpyRWyYzA==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} peerDependencies: @@ -2605,13 +2583,13 @@ packages: globby: 11.1.0 is-glob: 4.0.3 semver: 7.6.0 - tsutils: 3.21.0(typescript@5.4.2) - typescript: 5.4.2 + tsutils: 3.21.0(typescript@5.4.3) + typescript: 5.4.3 transitivePeerDependencies: - supports-color dev: true - /@typescript-eslint/utils@5.62.0(eslint@8.57.0)(typescript@5.4.2): + /@typescript-eslint/utils@5.62.0(eslint@8.57.0)(typescript@5.4.3): resolution: {integrity: sha512-n8oxjeb5aIbPFEtmQxQYOLI0i9n5ySBEY/ZEHHZqKQSFnxio1rv6dthascc9dLuwrL0RC5mPCxB7vnAVGAYWAQ==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} peerDependencies: @@ -2622,7 +2600,7 @@ packages: '@types/semver': 7.5.8 '@typescript-eslint/scope-manager': 5.62.0 '@typescript-eslint/types': 5.62.0 - '@typescript-eslint/typescript-estree': 5.62.0(typescript@5.4.2) + '@typescript-eslint/typescript-estree': 5.62.0(typescript@5.4.3) eslint: 8.57.0 eslint-scope: 5.1.1 semver: 7.6.0 @@ -2855,13 +2833,14 @@ packages: call-bind: 1.0.7 is-array-buffer: 3.0.4 - /array-includes@3.1.7: - resolution: {integrity: sha512-dlcsNBIiWhPkHdOEEKnehA+RNUWDc4UqFtnIXU4uuYDPtA4LDkr7qip2p0VvFAEXNDr0yWZ9PJyIRiGjRLQzwQ==} + /array-includes@3.1.8: + resolution: {integrity: sha512-itaWrbYbqpGXkGhZPGUulwnhVf5Hpy1xiCFsGqyIGglbBxmG5vSjxQen3/WGOjPpNEv1RtBLKxbmVXm8HpJStQ==} engines: {node: '>= 0.4'} dependencies: call-bind: 1.0.7 define-properties: 1.2.1 - es-abstract: 1.22.5 + es-abstract: 1.23.2 + es-object-atoms: 1.0.0 get-intrinsic: 1.2.4 is-string: 1.0.7 dev: true @@ -2912,7 +2891,7 @@ packages: dependencies: call-bind: 1.0.7 define-properties: 1.2.1 - es-abstract: 1.22.5 + es-abstract: 1.23.2 es-shim-unscopables: 1.0.2 dev: true @@ -2922,7 +2901,7 @@ packages: dependencies: call-bind: 1.0.7 define-properties: 1.2.1 - es-abstract: 1.22.5 + es-abstract: 1.23.2 es-shim-unscopables: 1.0.2 dev: true @@ -2931,7 +2910,7 @@ packages: dependencies: call-bind: 1.0.7 define-properties: 1.2.1 - es-abstract: 1.22.5 + es-abstract: 1.23.2 es-shim-unscopables: 1.0.2 dev: true @@ -2940,7 +2919,7 @@ packages: dependencies: call-bind: 1.0.7 define-properties: 1.2.1 - es-abstract: 1.22.5 + es-abstract: 1.23.2 es-errors: 1.3.0 es-shim-unscopables: 1.0.2 dev: true @@ -2952,7 +2931,7 @@ packages: array-buffer-byte-length: 1.0.1 call-bind: 1.0.7 define-properties: 1.2.1 - es-abstract: 1.22.5 + es-abstract: 1.23.2 es-errors: 1.3.0 get-intrinsic: 1.2.4 is-array-buffer: 3.0.4 @@ -2988,7 +2967,7 @@ packages: dequal: 2.0.3 dev: true - /babel-loader@8.3.0(@babel/core@7.24.3)(webpack@5.90.3): + /babel-loader@8.3.0(@babel/core@7.24.3)(webpack@5.91.0): resolution: {integrity: sha512-H8SvsMF+m9t15HNLMipppzkC+Y2Yq+v3SonZyU70RBL/h1gxPkH08Ot8pEE9Z4Kd+czyWJClmFS8qzIP9OZ04Q==} engines: {node: '>= 8.9'} peerDependencies: @@ -3000,7 +2979,7 @@ packages: loader-utils: 2.0.4 make-dir: 3.1.0 schema-utils: 2.7.1 - webpack: 5.90.3 + webpack: 5.91.0 dev: false /babel-plugin-macros@3.1.0: @@ -3078,8 +3057,8 @@ packages: engines: {node: ^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7} hasBin: true dependencies: - caniuse-lite: 1.0.30001599 - electron-to-chromium: 1.4.711 + caniuse-lite: 1.0.30001600 + electron-to-chromium: 1.4.715 node-releases: 2.0.14 update-browserslist-db: 1.0.13(browserslist@4.23.0) dev: false @@ -3113,8 +3092,8 @@ packages: resolution: {integrity: sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ==} engines: {node: '>=6'} - /caniuse-lite@1.0.30001599: - resolution: {integrity: sha512-LRAQHZ4yT1+f9LemSMeqdMpMxZcc4RMWdj4tiFe3G8tNkWK+E58g+/tzotb5cU6TbcVJLr4fySiAW7XmxQvZQA==} + /caniuse-lite@1.0.30001600: + resolution: {integrity: sha512-+2S9/2JFhYmYaDpZvo0lKkfvuKIglrx68MwOBqMGHhQsNkLjB5xtc/TGoEPs+MxjSyN/72qer2g97nzR641mOQ==} dev: false /chalk@2.4.2: @@ -3143,14 +3122,14 @@ packages: engines: {node: '>=6.0'} dev: false - /clean-webpack-plugin@4.0.0(webpack@5.90.3): + /clean-webpack-plugin@4.0.0(webpack@5.91.0): resolution: {integrity: sha512-WuWE1nyTNAyW5T7oNyys2EN0cfP2fdRxhxnIQWiAp0bMabPdHhoGxM8A6YL2GhqwgrPnnaemVE7nv5XJ2Fhh2w==} engines: {node: '>=10.0.0'} peerDependencies: webpack: '>=4.0.0 <6.0.0' dependencies: del: 4.1.1 - webpack: 5.90.3 + webpack: 5.91.0 dev: false /cli-cursor@4.0.0: @@ -3422,8 +3401,8 @@ packages: jake: 10.8.7 dev: false - /electron-to-chromium@1.4.711: - resolution: {integrity: sha512-hRg81qzvUEibX2lDxnFlVCHACa+LtrCPIsWAxo161LDYIB3jauf57RGsMZV9mvGwE98yGH06icj3zBEoOkxd/w==} + /electron-to-chromium@1.4.715: + resolution: {integrity: sha512-XzWNH4ZSa9BwVUQSDorPWAUQ5WGuYz7zJUNpNif40zFCiCl20t8zgylmreNmn26h5kiyw2lg7RfTmeMBsDklqg==} dev: false /emoji-regex@9.2.2: @@ -3448,52 +3427,6 @@ packages: is-arrayish: 0.2.1 dev: false - /es-abstract@1.22.5: - resolution: {integrity: sha512-oW69R+4q2wG+Hc3KZePPZxOiisRIqfKBVo/HLx94QcJeWGU/8sZhCvc829rd1kS366vlJbzBfXf9yWwf0+Ko7w==} - engines: {node: '>= 0.4'} - dependencies: - array-buffer-byte-length: 1.0.1 - arraybuffer.prototype.slice: 1.0.3 - available-typed-arrays: 1.0.7 - call-bind: 1.0.7 - es-define-property: 1.0.0 - es-errors: 1.3.0 - es-set-tostringtag: 2.0.3 - es-to-primitive: 1.2.1 - function.prototype.name: 1.1.6 - get-intrinsic: 1.2.4 - get-symbol-description: 1.0.2 - globalthis: 1.0.3 - gopd: 1.0.1 - has-property-descriptors: 1.0.2 - has-proto: 1.0.3 - has-symbols: 1.0.3 - hasown: 2.0.2 - internal-slot: 1.0.7 - is-array-buffer: 3.0.4 - is-callable: 1.2.7 - is-negative-zero: 2.0.3 - is-regex: 1.1.4 - is-shared-array-buffer: 1.0.3 - is-string: 1.0.7 - is-typed-array: 1.1.13 - is-weakref: 1.0.2 - object-inspect: 1.13.1 - object-keys: 1.1.1 - object.assign: 4.1.5 - regexp.prototype.flags: 1.5.2 - safe-array-concat: 1.1.2 - safe-regex-test: 1.0.3 - string.prototype.trim: 1.2.9 - string.prototype.trimend: 1.0.8 - string.prototype.trimstart: 1.0.7 - typed-array-buffer: 1.0.2 - typed-array-byte-length: 1.0.1 - typed-array-byte-offset: 1.0.2 - typed-array-length: 1.0.5 - unbox-primitive: 1.0.2 - which-typed-array: 1.1.15 - /es-abstract@1.23.2: resolution: {integrity: sha512-60s3Xv2T2p1ICykc7c+DNDPLDMm9t4QxCOUU0K9JxiLjM3C1zB9YVdN7tjxrFd4+AkZ8CdX1ovUga4P2+1e+/w==} engines: {node: '>= 0.4'} @@ -3537,11 +3470,11 @@ packages: safe-regex-test: 1.0.3 string.prototype.trim: 1.2.9 string.prototype.trimend: 1.0.8 - string.prototype.trimstart: 1.0.7 + string.prototype.trimstart: 1.0.8 typed-array-buffer: 1.0.2 typed-array-byte-length: 1.0.1 typed-array-byte-offset: 1.0.2 - typed-array-length: 1.0.5 + typed-array-length: 1.0.6 unbox-primitive: 1.0.2 which-typed-array: 1.1.15 @@ -3651,7 +3584,7 @@ packages: resolution: {integrity: sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==} engines: {node: '>=10'} - /eslint-config-next@13.5.6(eslint@8.57.0)(typescript@5.4.2): + /eslint-config-next@13.5.6(eslint@8.57.0)(typescript@5.4.3): resolution: {integrity: sha512-o8pQsUHTo9aHqJ2YiZDym5gQAMRf7O2HndHo/JZeY7TDD+W4hk6Ma8Vw54RHiBeb7OWWO5dPirQB+Is/aVQ7Kg==} peerDependencies: eslint: ^7.23.0 || ^8.0.0 @@ -3662,7 +3595,7 @@ packages: dependencies: '@next/eslint-plugin-next': 13.5.6 '@rushstack/eslint-patch': 1.8.0 - '@typescript-eslint/parser': 5.62.0(eslint@8.57.0)(typescript@5.4.2) + '@typescript-eslint/parser': 5.62.0(eslint@8.57.0)(typescript@5.4.3) eslint: 8.57.0 eslint-import-resolver-node: 0.3.9 eslint-import-resolver-typescript: 3.6.1(@typescript-eslint/parser@5.62.0)(eslint-import-resolver-node@0.3.9)(eslint-plugin-import@2.29.1)(eslint@8.57.0) @@ -3670,7 +3603,7 @@ packages: eslint-plugin-jsx-a11y: 6.8.0(eslint@8.57.0) eslint-plugin-react: 7.34.1(eslint@8.57.0) eslint-plugin-react-hooks: 4.6.0(eslint@8.57.0) - typescript: 5.4.2 + typescript: 5.4.3 transitivePeerDependencies: - eslint-import-resolver-webpack - supports-color @@ -3739,7 +3672,7 @@ packages: eslint-import-resolver-webpack: optional: true dependencies: - '@typescript-eslint/parser': 5.62.0(eslint@8.57.0)(typescript@5.4.2) + '@typescript-eslint/parser': 5.62.0(eslint@8.57.0)(typescript@5.4.3) debug: 3.2.7 eslint: 8.57.0 eslint-import-resolver-node: 0.3.9 @@ -3766,8 +3699,8 @@ packages: '@typescript-eslint/parser': optional: true dependencies: - '@typescript-eslint/parser': 5.62.0(eslint@8.57.0)(typescript@5.4.2) - array-includes: 3.1.7 + '@typescript-eslint/parser': 5.62.0(eslint@8.57.0)(typescript@5.4.3) + array-includes: 3.1.8 array.prototype.findlastindex: 1.2.5 array.prototype.flat: 1.3.2 array.prototype.flatmap: 1.3.2 @@ -3799,7 +3732,7 @@ packages: dependencies: '@babel/runtime': 7.24.1 aria-query: 5.3.0 - array-includes: 3.1.7 + array-includes: 3.1.8 array.prototype.flatmap: 1.3.2 ast-types-flow: 0.0.8 axe-core: 4.7.0 @@ -3831,7 +3764,7 @@ packages: peerDependencies: eslint: ^3 || ^4 || ^5 || ^6 || ^7 || ^8 dependencies: - array-includes: 3.1.7 + array-includes: 3.1.8 array.prototype.findlast: 1.2.5 array.prototype.flatmap: 1.3.2 array.prototype.toreversed: 1.1.2 @@ -3844,7 +3777,7 @@ packages: minimatch: 3.1.2 object.entries: 1.1.8 object.fromentries: 2.0.8 - object.hasown: 1.1.3 + object.hasown: 1.1.4 object.values: 1.2.0 prop-types: 15.8.1 resolve: 2.0.0-next.5 @@ -3862,7 +3795,7 @@ packages: '@typescript-eslint/eslint-plugin': optional: true dependencies: - '@typescript-eslint/eslint-plugin': 5.62.0(@typescript-eslint/parser@5.62.0)(eslint@8.57.0)(typescript@5.4.2) + '@typescript-eslint/eslint-plugin': 5.62.0(@typescript-eslint/parser@5.62.0)(eslint@8.57.0)(typescript@5.4.3) eslint: 8.57.0 eslint-rule-composer: 0.3.0 dev: true @@ -4121,7 +4054,7 @@ packages: dependencies: call-bind: 1.0.7 define-properties: 1.2.1 - es-abstract: 1.22.5 + es-abstract: 1.23.2 functions-have-names: 1.2.3 /functions-have-names@1.2.3: @@ -4605,7 +4538,7 @@ packages: supports-color: 8.1.1 dev: false - /jotai@2.7.1(@types/react@18.2.67)(react@18.2.0): + /jotai@2.7.1(@types/react@18.2.70)(react@18.2.0): resolution: {integrity: sha512-bsaTPn02nFgWNP6cBtg/htZhCu4s0wxqoklRHePp6l/vlsypR9eLn7diRliwXYWMXDpPvW/LLA2afI8vwgFFaw==} engines: {node: '>=12.20.0'} peerDependencies: @@ -4617,7 +4550,7 @@ packages: react: optional: true dependencies: - '@types/react': 18.2.67 + '@types/react': 18.2.70 react: 18.2.0 dev: false @@ -4695,7 +4628,7 @@ packages: resolution: {integrity: sha512-ZZow9HBI5O6EPgSJLUb8n2NKgmVWTwCvHGwFuJlMjvLFqlGG6pjirPhtdsseaLZjSibD8eegzmYpUZwoIlj2cQ==} engines: {node: '>=4.0'} dependencies: - array-includes: 3.1.7 + array-includes: 3.1.8 array.prototype.flat: 1.3.2 object.assign: 4.1.5 object.values: 1.2.0 @@ -4941,17 +4874,17 @@ packages: resolution: {integrity: sha512-Yd3UES5mWCSqR+qNT93S3UoYUkqAZ9lLg8a7g9rimsWmYGK8cVToA4/sF3RrshdyV3sAGMXVUmpMYOw+dLpOuw==} dev: false - /next-pwa@5.6.0(@babel/core@7.24.3)(next@13.4.1)(webpack@5.90.3): + /next-pwa@5.6.0(@babel/core@7.24.3)(next@13.4.1)(webpack@5.91.0): resolution: {integrity: sha512-XV8g8C6B7UmViXU8askMEYhWwQ4qc/XqJGnexbLV68hzKaGHZDMtHsm2TNxFcbR7+ypVuth/wwpiIlMwpRJJ5A==} peerDependencies: next: '>=9.0.0' dependencies: - babel-loader: 8.3.0(@babel/core@7.24.3)(webpack@5.90.3) - clean-webpack-plugin: 4.0.0(webpack@5.90.3) + babel-loader: 8.3.0(@babel/core@7.24.3)(webpack@5.91.0) + clean-webpack-plugin: 4.0.0(webpack@5.91.0) globby: 11.1.0 next: 13.4.1(@babel/core@7.24.3)(react-dom@18.2.0)(react@18.2.0) - terser-webpack-plugin: 5.3.10(webpack@5.90.3) - workbox-webpack-plugin: 6.6.0(webpack@5.90.3) + terser-webpack-plugin: 5.3.10(webpack@5.91.0) + workbox-webpack-plugin: 6.6.0(webpack@5.91.0) workbox-window: 6.6.0 transitivePeerDependencies: - '@babel/core' @@ -4998,7 +4931,7 @@ packages: '@next/env': 13.4.1 '@swc/helpers': 0.5.1 busboy: 1.6.0 - caniuse-lite: 1.0.30001599 + caniuse-lite: 1.0.30001600 postcss: 8.4.14 react: 18.2.0 react-dom: 18.2.0(react@18.2.0) @@ -5093,11 +5026,13 @@ packages: es-abstract: 1.23.2 dev: true - /object.hasown@1.1.3: - resolution: {integrity: sha512-fFI4VcYpRHvSLXxP7yiZOMAd331cPfd2p7PFDVbgUsYOfCT3tICVqXWngbjr4m49OvsBwUBQ6O2uQoJvy3RexA==} + /object.hasown@1.1.4: + resolution: {integrity: sha512-FZ9LZt9/RHzGySlBARE3VF+gE26TxR38SdmqOqliuTnl9wrKulaQs+4dee1V+Io8VfxqzAfHu6YuRgUy8OHoTg==} + engines: {node: '>= 0.4'} dependencies: define-properties: 1.2.1 - es-abstract: 1.22.5 + es-abstract: 1.23.2 + es-object-atoms: 1.0.0 dev: true /object.values@1.2.0: @@ -5284,9 +5219,9 @@ packages: engines: {node: '>= 0.8.0'} dev: true - /prettier@2.8.8: - resolution: {integrity: sha512-tdN8qQGvNjw4CHbY+XXk0JgCXn9QiF21a55rBe5LJAU+kDyC4WQn4+awm2Xfk2lQMk5fKup9XgzTZtGkjBdP9Q==} - engines: {node: '>=10.13.0'} + /prettier@3.2.5: + resolution: {integrity: sha512-3/GWa9aOC0YeD7LUfvOG2NiDyhOWRvt1k+rcKhOuYnMY24iiCphgneUfJDyFXd6rZCAnuLBv6UeAULtrhT/F4A==} + engines: {node: '>=14'} hasBin: true dev: true @@ -5359,9 +5294,9 @@ packages: '@mui/x-date-pickers': optional: true dependencies: - '@mui/icons-material': 5.15.14(@mui/material@5.15.14)(@types/react@18.2.67)(react@18.2.0) - '@mui/material': 5.15.14(@emotion/react@11.11.4)(@emotion/styled@11.11.0)(@types/react@18.2.67)(react-dom@18.2.0)(react@18.2.0) - '@mui/x-date-pickers': 6.19.8(@emotion/react@11.11.4)(@emotion/styled@11.11.0)(@mui/material@5.15.14)(@mui/system@5.15.14)(@types/react@18.2.67)(date-fns@3.6.0)(react-dom@18.2.0)(react@18.2.0) + '@mui/icons-material': 5.15.14(@mui/material@5.15.14)(@types/react@18.2.70)(react@18.2.0) + '@mui/material': 5.15.14(@emotion/react@11.11.4)(@emotion/styled@11.11.0)(@types/react@18.2.70)(react-dom@18.2.0)(react@18.2.0) + '@mui/x-date-pickers': 6.19.8(@emotion/react@11.11.4)(@emotion/styled@11.11.0)(@mui/material@5.15.14)(@mui/system@5.15.14)(@types/react@18.2.70)(date-fns@3.6.0)(react-dom@18.2.0)(react@18.2.0) react: 18.2.0 react-hook-form: 7.51.1(react@18.2.0) dev: false @@ -5768,12 +5703,13 @@ packages: define-properties: 1.2.1 es-object-atoms: 1.0.0 - /string.prototype.trimstart@1.0.7: - resolution: {integrity: sha512-NGhtDFu3jCEm7B4Fy0DpLewdJQOZcQ0rGbwQ/+stjnrp2i+rlKeCvos9hOIeCmqwratM47OBxY7uFZzjxHXmrg==} + /string.prototype.trimstart@1.0.8: + resolution: {integrity: sha512-UXSH262CSZY1tfu3G3Secr6uGLCFVPMhIqHjlgCUtCCcgihYc/xKs9djMTMUOb2j1mVSeU8EU6NWc/iQKU6Gfg==} + engines: {node: '>= 0.4'} dependencies: call-bind: 1.0.7 define-properties: 1.2.1 - es-abstract: 1.22.5 + es-object-atoms: 1.0.0 /stringify-object@3.3.0: resolution: {integrity: sha512-rHqiFh1elqCQ9WPLIC8I0Q/g/wj5J1eMkyoiD6eoQApWHP0FtlK7rqnhmabL5VUY9JQCcqwwvlOaSuutekgyrw==} @@ -5899,7 +5835,7 @@ packages: unique-string: 2.0.0 dev: false - /terser-webpack-plugin@5.3.10(webpack@5.90.3): + /terser-webpack-plugin@5.3.10(webpack@5.91.0): resolution: {integrity: sha512-BKFPWlPDndPs+NGGCr1U59t0XScL5317Y0UReNrHaw9/FwhPENlq6bfgs+4yPfyP51vqC1bQ4rp1EfXW5ZSH9w==} engines: {node: '>= 10.13.0'} peerDependencies: @@ -5920,7 +5856,7 @@ packages: schema-utils: 3.3.0 serialize-javascript: 6.0.2 terser: 5.29.2 - webpack: 5.90.3 + webpack: 5.91.0 dev: false /terser@5.29.2: @@ -5972,14 +5908,14 @@ packages: resolution: {integrity: sha512-AEYxH93jGFPn/a2iVAwW87VuUIkR1FVUKB77NwMF7nBTDkDrrT/Hpt/IrCJ0QXhW27jTBDcf5ZY7w6RiqTMw2Q==} dev: false - /tsutils@3.21.0(typescript@5.4.2): + /tsutils@3.21.0(typescript@5.4.3): resolution: {integrity: sha512-mHKK3iUXL+3UF6xL5k0PEhKRUBKPBCv/+RkEOpjRWxxx27KKRBmmA60A9pgOUvMi8GKhRMPEmjBRPzs2W7O1OA==} engines: {node: '>= 6'} peerDependencies: typescript: '>=2.8.0 || >= 3.2.0-dev || >= 3.3.0-dev || >= 3.4.0-dev || >= 3.5.0-dev || >= 3.6.0-dev || >= 3.6.0-beta || >= 3.7.0-dev || >= 3.7.0-beta' dependencies: tslib: 1.14.1 - typescript: 5.4.2 + typescript: 5.4.3 dev: true /tsx@3.14.0: @@ -6044,8 +5980,8 @@ packages: has-proto: 1.0.3 is-typed-array: 1.1.13 - /typed-array-length@1.0.5: - resolution: {integrity: sha512-yMi0PlwuznKHxKmcpoOdeLwxBoVPkqZxd7q2FgMkmD3bNwvF5VW0+UlUQ1k1vmktTu4Yu13Q0RIxEP8+B+wloA==} + /typed-array-length@1.0.6: + resolution: {integrity: sha512-/OxDN6OtAk5KBpGb28T+HZc2M+ADtvRxXrKKbUwtsLgdoxgX13hyy7ek6bFRl5+aBs2yZzB0c4CnQfAtVypW/g==} engines: {node: '>= 0.4'} dependencies: call-bind: 1.0.7 @@ -6055,8 +5991,8 @@ packages: is-typed-array: 1.1.13 possible-typed-array-names: 1.0.0 - /typescript@5.4.2: - resolution: {integrity: sha512-+2/g0Fds1ERlP6JsakQQDXjZdZMM+rqpamFZJEKh4kwTIn3iDkgKtby0CeNd5ATNZ4Ry1ax15TMx0W2V+miizQ==} + /typescript@5.4.3: + resolution: {integrity: sha512-KrPd3PKaCLr78MalgiwJnA25Nm8HAmdwN3mYUYZgG/wizIo9EainNVQI9/yDavtVFRN2h3k8uf3GLHuhDMgEHg==} engines: {node: '>=14.17'} hasBin: true dev: true @@ -6153,6 +6089,10 @@ packages: react: 18.2.0 dev: false + /valibot@0.30.0: + resolution: {integrity: sha512-5POBdbSkM+3nvJ6ZlyQHsggisfRtyT4tVTo1EIIShs6qCdXJnyWU5TJ68vr8iTg5zpOLjXLRiBqNx+9zwZz/rA==} + dev: false + /watchpack@2.4.1: resolution: {integrity: sha512-8wrBCMtVhqcXP2Sup1ctSkga6uc2Bx0IIvKyT7yTFier5AXHooSI+QyQQAtTb7+E0IUCCKyTFmXqdqgum2XWGg==} engines: {node: '>=10.13.0'} @@ -6177,8 +6117,8 @@ packages: engines: {node: '>=10.13.0'} dev: false - /webpack@5.90.3: - resolution: {integrity: sha512-h6uDYlWCctQRuXBs1oYpVe6sFcWedl0dpcVaTf/YF67J9bKvwJajFulMVSYKHrksMB3I/pIagRzDxwxkebuzKA==} + /webpack@5.91.0: + resolution: {integrity: sha512-rzVwlLeBWHJbmgTC/8TvAcu5vpJNII+MelQpylD4jNERPwpBJOE2lEcko1zJX3QJeLjTTAnQxn/OJ8bjDzVQaw==} engines: {node: '>=10.13.0'} hasBin: true peerDependencies: @@ -6208,7 +6148,7 @@ packages: neo-async: 2.6.2 schema-utils: 3.3.0 tapable: 2.2.1 - terser-webpack-plugin: 5.3.10(webpack@5.90.3) + terser-webpack-plugin: 5.3.10(webpack@5.91.0) watchpack: 2.4.1 webpack-sources: 3.2.3 transitivePeerDependencies: @@ -6419,7 +6359,7 @@ packages: resolution: {integrity: sha512-R2IkwDokbtHUE4Kus8pKO5+VkPHD2oqTgl+XJwh4zbF1HyjAbgNmK/FneZHVU7p03XUt9ICfuGDYISWG9qV/CQ==} dev: false - /workbox-webpack-plugin@6.6.0(webpack@5.90.3): + /workbox-webpack-plugin@6.6.0(webpack@5.91.0): resolution: {integrity: sha512-xNZIZHalboZU66Wa7x1YkjIqEy1gTR+zPM+kjrYJzqN7iurYZBctBLISyScjhkJKYuRrZUP0iqViZTh8rS0+3A==} engines: {node: '>=10.0.0'} peerDependencies: @@ -6428,7 +6368,7 @@ packages: fast-json-stable-stringify: 2.1.0 pretty-bytes: 5.6.0 upath: 1.2.0 - webpack: 5.90.3 + webpack: 5.91.0 webpack-sources: 1.4.3 workbox-build: 6.6.0 transitivePeerDependencies: diff --git a/src/client/features/tools/classStandardExcelToCode/hooks/useClassStandardDataInput.ts b/src/client/features/tools/classStandardExcelToCode/hooks/useClassStandardDataInput.ts @@ -0,0 +1,29 @@ +import { useState } from 'react'; +import { safeParse } from 'valibot'; + +import { InputSchema } from '../schema'; + +import type { InputSchemaSafeParseResult } from '../schema'; +import type { Dispatch, SetStateAction } from 'react'; + +type Result = { + input: string; + setInput: Dispatch<SetStateAction<string>>; + parseResult: InputSchemaSafeParseResult; +}; + +const useDayPeriodDataInput = (): Result => { + const [value, setValue] = useState(''); + + const rows = value.split('\n').map((row) => row.split('\t')); + + const result = safeParse(InputSchema, rows); + + return { + input: value, + setInput: setValue, + parseResult: result, + }; +}; + +export default useDayPeriodDataInput; diff --git a/src/client/features/tools/classStandardExcelToCode/hooks/useClassStandardDataOutput.ts b/src/client/features/tools/classStandardExcelToCode/hooks/useClassStandardDataOutput.ts @@ -0,0 +1,917 @@ +import { useState } from 'react'; + +import { DAY_PERIOD_JA, GRADE_CLASSES } from 'common/constant'; + +import type { InputSchema } from '../schema'; +import type { ClassStandardTimetable, GradeClass } from 'common/types'; + +type Result = { + output: Record<GradeClass, ClassStandardTimetable>; + transformIntoObject: (data: InputSchema) => void; +}; + +const useDayPeriodDataOutput = (): Result => { + const [value, setValue] = + useState<Record<GradeClass, ClassStandardTimetable>>(initialData); + + const transformIntoObject = (data: InputSchema) => { + const output = structuredClone(initialData); + + // 横方向曜日時限、縦方向クラスの2次元配列に転置する + const transposedData = data[0]?.map((_, i) => data.map((row) => row[i])); + + // 各クラスについて実行 + transposedData?.map((row, i) => { + const gradeClass = GRADE_CLASSES[i]; + + // 各曜日時限について実行 + row.map((subjects, j) => { + const dayPeriod = DAY_PERIOD_JA[j]; + if (gradeClass && dayPeriod && subjects) { + output[gradeClass][dayPeriod] = subjects + .split('/') + .map((subject) => ({ + dayPeriod, + shortName: subject, + })); + } + }); + }); + + setValue(output); + }; + + return { + output: value, + transformIntoObject, + }; +}; + +export default useDayPeriodDataOutput; + +const initialData: Record<GradeClass, ClassStandardTimetable> = { + '1-1': { + 月1: [], + 月2: [], + 月3: [], + 月4: [], + 月5: [], + 月6: [], + 月7: [], + 火1: [], + 火2: [], + 火3: [], + 火4: [], + 火5: [], + 火6: [], + 火7: [], + 水1: [], + 水2: [], + 水3: [], + 水4: [], + 水5: [], + 水6: [], + 水7: [], + 木1: [], + 木2: [], + 木3: [], + 木4: [], + 木5: [], + 木6: [], + 金1: [], + 金2: [], + 金3: [], + 金4: [], + 金5: [], + 金6: [], + 金7: [], + }, + '1-2': { + 月1: [], + 月2: [], + 月3: [], + 月4: [], + 月5: [], + 月6: [], + 月7: [], + 火1: [], + 火2: [], + 火3: [], + 火4: [], + 火5: [], + 火6: [], + 火7: [], + 水1: [], + 水2: [], + 水3: [], + 水4: [], + 水5: [], + 水6: [], + 水7: [], + 木1: [], + 木2: [], + 木3: [], + 木4: [], + 木5: [], + 木6: [], + 金1: [], + 金2: [], + 金3: [], + 金4: [], + 金5: [], + 金6: [], + 金7: [], + }, + '1-3': { + 月1: [], + 月2: [], + 月3: [], + 月4: [], + 月5: [], + 月6: [], + 月7: [], + 火1: [], + 火2: [], + 火3: [], + 火4: [], + 火5: [], + 火6: [], + 火7: [], + 水1: [], + 水2: [], + 水3: [], + 水4: [], + 水5: [], + 水6: [], + 水7: [], + 木1: [], + 木2: [], + 木3: [], + 木4: [], + 木5: [], + 木6: [], + 金1: [], + 金2: [], + 金3: [], + 金4: [], + 金5: [], + 金6: [], + 金7: [], + }, + '1-4': { + 月1: [], + 月2: [], + 月3: [], + 月4: [], + 月5: [], + 月6: [], + 月7: [], + 火1: [], + 火2: [], + 火3: [], + 火4: [], + 火5: [], + 火6: [], + 火7: [], + 水1: [], + 水2: [], + 水3: [], + 水4: [], + 水5: [], + 水6: [], + 水7: [], + 木1: [], + 木2: [], + 木3: [], + 木4: [], + 木5: [], + 木6: [], + 金1: [], + 金2: [], + 金3: [], + 金4: [], + 金5: [], + 金6: [], + 金7: [], + }, + '1-5': { + 月1: [], + 月2: [], + 月3: [], + 月4: [], + 月5: [], + 月6: [], + 月7: [], + 火1: [], + 火2: [], + 火3: [], + 火4: [], + 火5: [], + 火6: [], + 火7: [], + 水1: [], + 水2: [], + 水3: [], + 水4: [], + 水5: [], + 水6: [], + 水7: [], + 木1: [], + 木2: [], + 木3: [], + 木4: [], + 木5: [], + 木6: [], + 金1: [], + 金2: [], + 金3: [], + 金4: [], + 金5: [], + 金6: [], + 金7: [], + }, + '1-6': { + 月1: [], + 月2: [], + 月3: [], + 月4: [], + 月5: [], + 月6: [], + 月7: [], + 火1: [], + 火2: [], + 火3: [], + 火4: [], + 火5: [], + 火6: [], + 火7: [], + 水1: [], + 水2: [], + 水3: [], + 水4: [], + 水5: [], + 水6: [], + 水7: [], + 木1: [], + 木2: [], + 木3: [], + 木4: [], + 木5: [], + 木6: [], + 金1: [], + 金2: [], + 金3: [], + 金4: [], + 金5: [], + 金6: [], + 金7: [], + }, + '1-7': { + 月1: [], + 月2: [], + 月3: [], + 月4: [], + 月5: [], + 月6: [], + 月7: [], + 火1: [], + 火2: [], + 火3: [], + 火4: [], + 火5: [], + 火6: [], + 火7: [], + 水1: [], + 水2: [], + 水3: [], + 水4: [], + 水5: [], + 水6: [], + 水7: [], + 木1: [], + 木2: [], + 木3: [], + 木4: [], + 木5: [], + 木6: [], + 金1: [], + 金2: [], + 金3: [], + 金4: [], + 金5: [], + 金6: [], + 金7: [], + }, + '1-8': { + 月1: [], + 月2: [], + 月3: [], + 月4: [], + 月5: [], + 月6: [], + 月7: [], + 火1: [], + 火2: [], + 火3: [], + 火4: [], + 火5: [], + 火6: [], + 火7: [], + 水1: [], + 水2: [], + 水3: [], + 水4: [], + 水5: [], + 水6: [], + 水7: [], + 木1: [], + 木2: [], + 木3: [], + 木4: [], + 木5: [], + 木6: [], + 金1: [], + 金2: [], + 金3: [], + 金4: [], + 金5: [], + 金6: [], + 金7: [], + }, + '2-1': { + 月1: [], + 月2: [], + 月3: [], + 月4: [], + 月5: [], + 月6: [], + 月7: [], + 火1: [], + 火2: [], + 火3: [], + 火4: [], + 火5: [], + 火6: [], + 火7: [], + 水1: [], + 水2: [], + 水3: [], + 水4: [], + 水5: [], + 水6: [], + 水7: [], + 木1: [], + 木2: [], + 木3: [], + 木4: [], + 木5: [], + 木6: [], + 金1: [], + 金2: [], + 金3: [], + 金4: [], + 金5: [], + 金6: [], + 金7: [], + }, + '2-2': { + 月1: [], + 月2: [], + 月3: [], + 月4: [], + 月5: [], + 月6: [], + 月7: [], + 火1: [], + 火2: [], + 火3: [], + 火4: [], + 火5: [], + 火6: [], + 火7: [], + 水1: [], + 水2: [], + 水3: [], + 水4: [], + 水5: [], + 水6: [], + 水7: [], + 木1: [], + 木2: [], + 木3: [], + 木4: [], + 木5: [], + 木6: [], + 金1: [], + 金2: [], + 金3: [], + 金4: [], + 金5: [], + 金6: [], + 金7: [], + }, + '2-3': { + 月1: [], + 月2: [], + 月3: [], + 月4: [], + 月5: [], + 月6: [], + 月7: [], + 火1: [], + 火2: [], + 火3: [], + 火4: [], + 火5: [], + 火6: [], + 火7: [], + 水1: [], + 水2: [], + 水3: [], + 水4: [], + 水5: [], + 水6: [], + 水7: [], + 木1: [], + 木2: [], + 木3: [], + 木4: [], + 木5: [], + 木6: [], + 金1: [], + 金2: [], + 金3: [], + 金4: [], + 金5: [], + 金6: [], + 金7: [], + }, + '2-4': { + 月1: [], + 月2: [], + 月3: [], + 月4: [], + 月5: [], + 月6: [], + 月7: [], + 火1: [], + 火2: [], + 火3: [], + 火4: [], + 火5: [], + 火6: [], + 火7: [], + 水1: [], + 水2: [], + 水3: [], + 水4: [], + 水5: [], + 水6: [], + 水7: [], + 木1: [], + 木2: [], + 木3: [], + 木4: [], + 木5: [], + 木6: [], + 金1: [], + 金2: [], + 金3: [], + 金4: [], + 金5: [], + 金6: [], + 金7: [], + }, + '2-5': { + 月1: [], + 月2: [], + 月3: [], + 月4: [], + 月5: [], + 月6: [], + 月7: [], + 火1: [], + 火2: [], + 火3: [], + 火4: [], + 火5: [], + 火6: [], + 火7: [], + 水1: [], + 水2: [], + 水3: [], + 水4: [], + 水5: [], + 水6: [], + 水7: [], + 木1: [], + 木2: [], + 木3: [], + 木4: [], + 木5: [], + 木6: [], + 金1: [], + 金2: [], + 金3: [], + 金4: [], + 金5: [], + 金6: [], + 金7: [], + }, + '2-6': { + 月1: [], + 月2: [], + 月3: [], + 月4: [], + 月5: [], + 月6: [], + 月7: [], + 火1: [], + 火2: [], + 火3: [], + 火4: [], + 火5: [], + 火6: [], + 火7: [], + 水1: [], + 水2: [], + 水3: [], + 水4: [], + 水5: [], + 水6: [], + 水7: [], + 木1: [], + 木2: [], + 木3: [], + 木4: [], + 木5: [], + 木6: [], + 金1: [], + 金2: [], + 金3: [], + 金4: [], + 金5: [], + 金6: [], + 金7: [], + }, + '2-7': { + 月1: [], + 月2: [], + 月3: [], + 月4: [], + 月5: [], + 月6: [], + 月7: [], + 火1: [], + 火2: [], + 火3: [], + 火4: [], + 火5: [], + 火6: [], + 火7: [], + 水1: [], + 水2: [], + 水3: [], + 水4: [], + 水5: [], + 水6: [], + 水7: [], + 木1: [], + 木2: [], + 木3: [], + 木4: [], + 木5: [], + 木6: [], + 金1: [], + 金2: [], + 金3: [], + 金4: [], + 金5: [], + 金6: [], + 金7: [], + }, + '2-8': { + 月1: [], + 月2: [], + 月3: [], + 月4: [], + 月5: [], + 月6: [], + 月7: [], + 火1: [], + 火2: [], + 火3: [], + 火4: [], + 火5: [], + 火6: [], + 火7: [], + 水1: [], + 水2: [], + 水3: [], + 水4: [], + 水5: [], + 水6: [], + 水7: [], + 木1: [], + 木2: [], + 木3: [], + 木4: [], + 木5: [], + 木6: [], + 金1: [], + 金2: [], + 金3: [], + 金4: [], + 金5: [], + 金6: [], + 金7: [], + }, + '3-1': { + 月1: [], + 月2: [], + 月3: [], + 月4: [], + 月5: [], + 月6: [], + 月7: [], + 火1: [], + 火2: [], + 火3: [], + 火4: [], + 火5: [], + 火6: [], + 火7: [], + 水1: [], + 水2: [], + 水3: [], + 水4: [], + 水5: [], + 水6: [], + 水7: [], + 木1: [], + 木2: [], + 木3: [], + 木4: [], + 木5: [], + 木6: [], + 金1: [], + 金2: [], + 金3: [], + 金4: [], + 金5: [], + 金6: [], + 金7: [], + }, + '3-2': { + 月1: [], + 月2: [], + 月3: [], + 月4: [], + 月5: [], + 月6: [], + 月7: [], + 火1: [], + 火2: [], + 火3: [], + 火4: [], + 火5: [], + 火6: [], + 火7: [], + 水1: [], + 水2: [], + 水3: [], + 水4: [], + 水5: [], + 水6: [], + 水7: [], + 木1: [], + 木2: [], + 木3: [], + 木4: [], + 木5: [], + 木6: [], + 金1: [], + 金2: [], + 金3: [], + 金4: [], + 金5: [], + 金6: [], + 金7: [], + }, + '3-3': { + 月1: [], + 月2: [], + 月3: [], + 月4: [], + 月5: [], + 月6: [], + 月7: [], + 火1: [], + 火2: [], + 火3: [], + 火4: [], + 火5: [], + 火6: [], + 火7: [], + 水1: [], + 水2: [], + 水3: [], + 水4: [], + 水5: [], + 水6: [], + 水7: [], + 木1: [], + 木2: [], + 木3: [], + 木4: [], + 木5: [], + 木6: [], + 金1: [], + 金2: [], + 金3: [], + 金4: [], + 金5: [], + 金6: [], + 金7: [], + }, + '3-4': { + 月1: [], + 月2: [], + 月3: [], + 月4: [], + 月5: [], + 月6: [], + 月7: [], + 火1: [], + 火2: [], + 火3: [], + 火4: [], + 火5: [], + 火6: [], + 火7: [], + 水1: [], + 水2: [], + 水3: [], + 水4: [], + 水5: [], + 水6: [], + 水7: [], + 木1: [], + 木2: [], + 木3: [], + 木4: [], + 木5: [], + 木6: [], + 金1: [], + 金2: [], + 金3: [], + 金4: [], + 金5: [], + 金6: [], + 金7: [], + }, + '3-5': { + 月1: [], + 月2: [], + 月3: [], + 月4: [], + 月5: [], + 月6: [], + 月7: [], + 火1: [], + 火2: [], + 火3: [], + 火4: [], + 火5: [], + 火6: [], + 火7: [], + 水1: [], + 水2: [], + 水3: [], + 水4: [], + 水5: [], + 水6: [], + 水7: [], + 木1: [], + 木2: [], + 木3: [], + 木4: [], + 木5: [], + 木6: [], + 金1: [], + 金2: [], + 金3: [], + 金4: [], + 金5: [], + 金6: [], + 金7: [], + }, + '3-6': { + 月1: [], + 月2: [], + 月3: [], + 月4: [], + 月5: [], + 月6: [], + 月7: [], + 火1: [], + 火2: [], + 火3: [], + 火4: [], + 火5: [], + 火6: [], + 火7: [], + 水1: [], + 水2: [], + 水3: [], + 水4: [], + 水5: [], + 水6: [], + 水7: [], + 木1: [], + 木2: [], + 木3: [], + 木4: [], + 木5: [], + 木6: [], + 金1: [], + 金2: [], + 金3: [], + 金4: [], + 金5: [], + 金6: [], + 金7: [], + }, + '3-7': { + 月1: [], + 月2: [], + 月3: [], + 月4: [], + 月5: [], + 月6: [], + 月7: [], + 火1: [], + 火2: [], + 火3: [], + 火4: [], + 火5: [], + 火6: [], + 火7: [], + 水1: [], + 水2: [], + 水3: [], + 水4: [], + 水5: [], + 水6: [], + 水7: [], + 木1: [], + 木2: [], + 木3: [], + 木4: [], + 木5: [], + 木6: [], + 金1: [], + 金2: [], + 金3: [], + 金4: [], + 金5: [], + 金6: [], + 金7: [], + }, + '3-8': { + 月1: [], + 月2: [], + 月3: [], + 月4: [], + 月5: [], + 月6: [], + 月7: [], + 火1: [], + 火2: [], + 火3: [], + 火4: [], + 火5: [], + 火6: [], + 火7: [], + 水1: [], + 水2: [], + 水3: [], + 水4: [], + 水5: [], + 水6: [], + 水7: [], + 木1: [], + 木2: [], + 木3: [], + 木4: [], + 木5: [], + 木6: [], + 金1: [], + 金2: [], + 金3: [], + 金4: [], + 金5: [], + 金6: [], + 金7: [], + }, +} as const; diff --git a/src/client/features/tools/classStandardExcelToCode/index.tsx b/src/client/features/tools/classStandardExcelToCode/index.tsx @@ -0,0 +1,70 @@ +import { Box, Button, Paper, Stack, TextField } from '@mui/material'; +import prettierPluginBabel from 'prettier/plugins/babel'; +// eslint-disable-next-line import/default +import prettierPluginEstree from 'prettier/plugins/estree'; +import { format } from 'prettier/standalone'; +import { useEffect, useState } from 'react'; + +import useClassStandardDataInput from './hooks/useClassStandardDataInput'; +import useClassStandardDataOutput from './hooks/useClassStandardDataOutput'; + +/** 変換結果を表示するコンポーネント */ +function Output({ data }: { data: unknown }) { + const [output, setOutput] = useState(''); + useEffect(() => { + format(JSON.stringify(data), { + useTabs: true, + parser: 'json', + plugins: [prettierPluginBabel, prettierPluginEstree], + }) + .then((v) => { + setOutput(v); + }) + .catch((err) => { + console.log(err); + }); + }, [data]); + + return ( + <Paper component={Box} p={2} height={400} overflow='auto'> + <pre>{output}</pre> + </Paper> + ); +} + +export default function ClassStandardExcelToCodeForm() { + const { input, setInput, parseResult } = useClassStandardDataInput(); + const { output, transformIntoObject } = useClassStandardDataOutput(); + + return ( + <Stack spacing={4} my={4}> + <TextField + label='クラス時間割データ' + placeholder='クラス標準時間割表のExcelシートをここにペースト' + variant='filled' + multiline + rows={8} + value={input} + onChange={(event: React.ChangeEvent<HTMLInputElement>) => { + setInput(event.target.value); + }} + error={input !== '' && !parseResult.success} + helperText={input !== '' && parseResult.issues?.[0].message} + /> + + <Box> + <Button + variant='contained' + disabled={input === '' || !parseResult.success} + onClick={() => + parseResult.success && transformIntoObject(parseResult.output) + } + > + 変換する + </Button> + </Box> + + <Output data={output} /> + </Stack> + ); +} diff --git a/src/client/features/tools/classStandardExcelToCode/schema.ts b/src/client/features/tools/classStandardExcelToCode/schema.ts @@ -0,0 +1,12 @@ +import { array, length, string } from 'valibot'; + +import type { Output, SafeParseResult } from 'valibot'; + +// 転置前 +export const InputSchema = array( + array(string(), [length(24, '横24列のデータを入力してください')]), + [length(34, '縦34行のデータを入力してください')], +); + +export type InputSchema = Output<typeof InputSchema>; +export type InputSchemaSafeParseResult = SafeParseResult<typeof InputSchema>; diff --git a/src/client/features/tools/dayPeriodExcelToCode/hooks/useDayPeriodDataInput.ts b/src/client/features/tools/dayPeriodExcelToCode/hooks/useDayPeriodDataInput.ts @@ -0,0 +1,29 @@ +import { useState } from 'react'; +import { safeParse } from 'valibot'; + +import { InputSchema } from '../schema'; + +import type { InputSchemaSafeParseResult } from '../schema'; +import type { Dispatch, SetStateAction } from 'react'; + +type Result = { + input: string; + setInput: Dispatch<SetStateAction<string>>; + parseResult: InputSchemaSafeParseResult; +}; + +const useDayPeriodDataInput = (): Result => { + const [value, setValue] = useState(''); + + const rows = value.split('\n').map((row) => row.split('\t')); + + const result = safeParse(InputSchema, rows); + + return { + input: value, + setInput: setValue, + parseResult: result, + }; +}; + +export default useDayPeriodDataInput; diff --git a/src/client/features/tools/dayPeriodExcelToCode/hooks/useDayPeriodDataOutput.ts b/src/client/features/tools/dayPeriodExcelToCode/hooks/useDayPeriodDataOutput.ts @@ -0,0 +1,59 @@ +import { useState } from 'react'; + +import type { InputSchema } from '../schema'; +import type { DaySchedulesByGrade } from 'common/types'; + +type Result = { + output: Record<string, DaySchedulesByGrade>; + transformIntoObject: (data: InputSchema) => void; +}; + +const useDayPeriodDataOutput = (): Result => { + const [value, setValue] = useState<Record<string, DaySchedulesByGrade>>({}); + + const transformIntoObject = (data: InputSchema) => { + const output: Record<string, DaySchedulesByGrade> = {}; + data.forEach(([date, ...schedules]) => { + const result: DaySchedulesByGrade = {}; + const grade1: DaySchedulesByGrade['grade1'] = {}; + const grade2: DaySchedulesByGrade['grade2'] = {}; + const grade3: DaySchedulesByGrade['grade3'] = {}; + + if (schedules[0] !== '') grade1.period1 = schedules[0]; + if (schedules[1] !== '') grade1.period2 = schedules[1]; + if (schedules[2] !== '') grade1.period3 = schedules[2]; + if (schedules[3] !== '') grade1.period4 = schedules[3]; + if (schedules[4] !== '') grade1.period5 = schedules[4]; + if (schedules[5] !== '') grade1.period6 = schedules[5]; + if (schedules[6] !== '') grade1.period7 = schedules[6]; + if (schedules[7] !== '') grade2.period1 = schedules[7]; + if (schedules[8] !== '') grade2.period2 = schedules[8]; + if (schedules[9] !== '') grade2.period3 = schedules[9]; + if (schedules[10] !== '') grade2.period4 = schedules[10]; + if (schedules[11] !== '') grade2.period5 = schedules[11]; + if (schedules[12] !== '') grade2.period6 = schedules[12]; + if (schedules[13] !== '') grade2.period7 = schedules[13]; + if (schedules[14] !== '') grade3.period1 = schedules[14]; + if (schedules[15] !== '') grade3.period2 = schedules[15]; + if (schedules[16] !== '') grade3.period3 = schedules[16]; + if (schedules[17] !== '') grade3.period4 = schedules[17]; + if (schedules[18] !== '') grade3.period5 = schedules[18]; + if (schedules[19] !== '') grade3.period6 = schedules[19]; + if (schedules[20] !== '') grade3.period7 = schedules[20]; + + if (Object.entries(grade1).length) result.grade1 = grade1; + if (Object.entries(grade2).length) result.grade2 = grade2; + if (Object.entries(grade3).length) result.grade3 = grade3; + + if (Object.entries(result).length) output[date] = result; + }); + setValue(output); + }; + + return { + output: value, + transformIntoObject, + }; +}; + +export default useDayPeriodDataOutput; diff --git a/src/client/features/tools/dayPeriodExcelToCode/index.tsx b/src/client/features/tools/dayPeriodExcelToCode/index.tsx @@ -0,0 +1,70 @@ +import { Box, Button, Paper, Stack, TextField } from '@mui/material'; +import prettierPluginBabel from 'prettier/plugins/babel'; +// eslint-disable-next-line import/default +import prettierPluginEstree from 'prettier/plugins/estree'; +import { format } from 'prettier/standalone'; +import { useEffect, useState } from 'react'; + +import useDayPeriodDataInput from './hooks/useDayPeriodDataInput'; +import useDayPeriodDataOutput from './hooks/useDayPeriodDataOutput'; + +/** 変換結果を表示するコンポーネント */ +function Output({ data }: { data: unknown }) { + const [output, setOutput] = useState(''); + useEffect(() => { + format(JSON.stringify(data), { + useTabs: true, + parser: 'json', + plugins: [prettierPluginBabel, prettierPluginEstree], + }) + .then((v) => { + setOutput(v); + }) + .catch((err) => { + console.log(err); + }); + }, [data]); + + return ( + <Paper component={Box} p={2} height={400} overflow='auto'> + <pre>{output}</pre> + </Paper> + ); +} + +export default function DayPeriodExcelToCodeForm() { + const { input, setInput, parseResult } = useDayPeriodDataInput(); + const { output, transformIntoObject } = useDayPeriodDataOutput(); + + return ( + <Stack spacing={4} my={4}> + <TextField + label='曜日時限時間割データ' + placeholder='曜日時限時間割表のExcelシートをここにペースト' + variant='filled' + multiline + rows={8} + value={input} + onChange={(event: React.ChangeEvent<HTMLInputElement>) => { + setInput(event.target.value); + }} + error={input !== '' && !parseResult.success} + helperText={input !== '' && parseResult.issues?.[0].message} + /> + + <Box> + <Button + variant='contained' + disabled={input === '' || !parseResult.success} + onClick={() => + parseResult.success && transformIntoObject(parseResult.output) + } + > + 変換する + </Button> + </Box> + + <Output data={output} /> + </Stack> + ); +} diff --git a/src/client/features/tools/dayPeriodExcelToCode/schema.ts b/src/client/features/tools/dayPeriodExcelToCode/schema.ts @@ -0,0 +1,29 @@ +import { + array, + isoDate, + length, + literal, + picklist, + string, + tuple, + union, +} from 'valibot'; + +import { DAY_PERIOD_JA } from 'common/constant'; + +import type { Output, SafeParseResult } from 'valibot'; + +export const InputSchema = array( + union([ + tuple( + [string([isoDate('1列目は "yyyy-mm-dd" 形式の日付です')])], + picklist(['', ...DAY_PERIOD_JA], '曜日時限を入力してください'), + '何かが間違っています', + [length(22, '横22列のデータを入力してください')], + ), + tuple([literal('')]), + ]), +); + +export type InputSchema = Output<typeof InputSchema>; +export type InputSchemaSafeParseResult = SafeParseResult<typeof InputSchema>; diff --git a/src/common/types/index.ts b/src/common/types/index.ts @@ -28,7 +28,7 @@ export type DayPeriodJa = ArrayToUnion<typeof DAY_PERIOD_JA>; export type Course = { dayPeriod: DayPeriodJa; - name: string; + name?: string; shortName: string; room?: string; instructorID?: string; diff --git a/src/pages/tools/class-standard-excel-to-code.tsx b/src/pages/tools/class-standard-excel-to-code.tsx @@ -0,0 +1,51 @@ +import NavigateNextIcon from '@mui/icons-material/NavigateNext'; +import Box from '@mui/material/Box'; +import Breadcrumbs from '@mui/material/Breadcrumbs'; +import Container from '@mui/material/Container'; +import Typography from '@mui/material/Typography'; + +import Head from 'client/components/Head'; +import Link from 'client/components/Link'; +import ClassStandardExcelToCodeForm from 'client/features/tools/classStandardExcelToCode'; + +export default function ClassStandardExcelToCodePage() { + return ( + <> + <Head title='クラス標準時間割表 変換ツール' /> + <Container maxWidth='lg' component={Box} py={2}> + <Breadcrumbs + separator={<NavigateNextIcon fontSize='small' />} + aria-label='breadcrumb' + > + <Link underline='hover' color='inherit' href='/'> + トップ + </Link> + <Link underline='hover' color='inherit' href='/tools'> + ツール + </Link> + <Typography color='text.primary' variant='h2'> + クラス標準時間割表 変換ツール + </Typography> + </Breadcrumbs> + + <p> + クラス標準時間割のExcel形式のデータを、アプリ内部でデータを保存している形式に変換するツールです。入力された科目名がデータの{' '} + <code>shortName</code>{' '} + に対応します。入力データは以下の構造のtsvテキストに対応しています。 + <ul> + <li>横方向: 1年1組~3年8組(24列)</li> + <li> + 縦方向: 月1~金7(34行) + ※途中にあるヘッダー行や木7の行は含めないように注意する。 + </li> + <li> + 各データはそのクラスの曜日時限における科目名で、複数ある場合はスラッシュ区切り。「課題研究」などのセル結合は解除し、該当するすべてのセルにデータを入力する必要がある。 + </li> + </ul> + </p> + + <ClassStandardExcelToCodeForm /> + </Container> + </> + ); +} diff --git a/src/pages/tools/day-period-excel-to-code.tsx b/src/pages/tools/day-period-excel-to-code.tsx @@ -0,0 +1,47 @@ +import NavigateNextIcon from '@mui/icons-material/NavigateNext'; +import Box from '@mui/material/Box'; +import Breadcrumbs from '@mui/material/Breadcrumbs'; +import Container from '@mui/material/Container'; +import Typography from '@mui/material/Typography'; + +import Head from 'client/components/Head'; +import Link from 'client/components/Link'; +import DayPeriodExcelToCodeForm from 'client/features/tools/dayPeriodExcelToCode'; + +export default function DayPeriodExcelToCodePage() { + return ( + <> + <Head title='曜日時限時間割表 変換ツール' /> + <Container maxWidth='lg' component={Box} py={2}> + <Breadcrumbs + separator={<NavigateNextIcon fontSize='small' />} + aria-label='breadcrumb' + > + <Link underline='hover' color='inherit' href='/'> + トップ + </Link> + <Link underline='hover' color='inherit' href='/tools'> + ツール + </Link> + <Typography color='text.primary' variant='h2'> + 曜日時限時間割表 変換ツール + </Typography> + </Breadcrumbs> + + <p> + 曜日時限時間割(日程)のExcel形式のデータを、アプリ内部でデータを保存している形式に変換するツールです。入力データは以下の構造のtsvテキストに対応しています。 + <ul> + <li> + 1列目: 日付(<code>yyyy-mm-dd</code> 形式) + </li> + <li>2~8列目: 1年生の1~7限の曜日時限</li> + <li>9~15列目: 2年生の1~7限の曜日時限</li> + <li>16~22列目: 3年生の1~7限の曜日時限</li> + </ul> + </p> + + <DayPeriodExcelToCodeForm /> + </Container> + </> + ); +} diff --git a/src/pages/tools/index.tsx b/src/pages/tools/index.tsx @@ -0,0 +1,42 @@ +import NavigateNextIcon from '@mui/icons-material/NavigateNext'; +import { Typography } from '@mui/material'; +import Box from '@mui/material/Box'; +import Breadcrumbs from '@mui/material/Breadcrumbs'; +import Container from '@mui/material/Container'; + +import Head from 'client/components/Head'; +import Link from 'client/components/Link'; + +export default function Tools() { + return ( + <> + <Head title='ツール' /> + <Container maxWidth='lg' component={Box} py={2}> + <Breadcrumbs + separator={<NavigateNextIcon fontSize='small' />} + aria-label='breadcrumb' + > + <Link underline='hover' color='inherit' href='/'> + トップ + </Link> + <Typography color='text.primary' variant='h2'> + ツール + </Typography> + </Breadcrumbs> + + <ul> + <li> + <Link href='/tools/day-period-excel-to-code'> + 曜日時限時間割表 変換ツール + </Link> + </li> + <li> + <Link href='/tools/class-standard-excel-to-code'> + クラス標準時間割表 変換ツール + </Link> + </li> + </ul> + </Container> + </> + ); +}