Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,10 @@ node_modules
.env.development.local
.env.test.local
.env.production.local
/apps/xi.web/.env.local
/apps/xi.web/.env.development.local
/apps/xi.web/.env.test.local
/apps/xi.web/.env.production.local

# Testing
coverage
Expand Down
84 changes: 42 additions & 42 deletions apps/xi.web/src/routeTree.gen.ts
Original file line number Diff line number Diff line change
Expand Up @@ -181,27 +181,27 @@ export interface FileRoutesByFullPath {
'/reset-password/$resetToken': typeof authResetPasswordResetTokenRoute
'/deployments/$deploymentId/enable': typeof DeploymentsDeploymentIdEnableRoute
'/': typeof appLayoutIndexRoute
'/reset-password': typeof authResetPasswordIndexRoute
'/signin': typeof authSigninIndexRoute
'/signup': typeof authSignupIndexRoute
'/reset-password/': typeof authResetPasswordIndexRoute
'/signin/': typeof authSigninIndexRoute
'/signup/': typeof authSignupIndexRoute
'/board/$boardId': typeof appLayoutBoardBoardIdRoute
'/call/$callId': typeof appLayoutCallCallIdRoute
'/confirm-email/$emailId': typeof commonLayoutConfirmEmailEmailIdRoute
'/invite/$inviteId': typeof commonLayoutInviteInviteIdRoute
'/welcome/email/$emailId': typeof commonWelcomeEmailEmailIdRoute
'/calendar': typeof appLayoutCalendarIndexRoute
'/call': typeof appLayoutCallIndexRoute
'/classrooms': typeof appLayoutClassroomsIndexRoute
'/materials': typeof appLayoutMaterialsIndexRoute
'/payments': typeof appLayoutPaymentsIndexRoute
'/welcome/role': typeof commonWelcomeRoleIndexRoute
'/welcome/socials': typeof commonWelcomeSocialsIndexRoute
'/welcome/user': typeof commonWelcomeUserIndexRoute
'/classrooms/$classroomId': typeof appLayoutClassroomsClassroomIdIndexRoute
'/calendar/': typeof appLayoutCalendarIndexRoute
'/call/': typeof appLayoutCallIndexRoute
'/classrooms/': typeof appLayoutClassroomsIndexRoute
'/materials/': typeof appLayoutMaterialsIndexRoute
'/payments/': typeof appLayoutPaymentsIndexRoute
'/welcome/role/': typeof commonWelcomeRoleIndexRoute
'/welcome/socials/': typeof commonWelcomeSocialsIndexRoute
'/welcome/user/': typeof commonWelcomeUserIndexRoute
'/classrooms/$classroomId/': typeof appLayoutClassroomsClassroomIdIndexRoute
'/classrooms/$classroomId/boards/$boardId': typeof appLayoutClassroomsClassroomIdBoardsBoardIdRoute
'/classrooms/$classroomId/notes/$noteId': typeof appLayoutClassroomsClassroomIdNotesNoteIdRoute
'/materials/$materialId/board': typeof appLayoutMaterialsMaterialIdBoardIndexRoute
'/materials/$materialId/note': typeof appLayoutMaterialsMaterialIdNoteIndexRoute
'/materials/$materialId/board/': typeof appLayoutMaterialsMaterialIdBoardIndexRoute
'/materials/$materialId/note/': typeof appLayoutMaterialsMaterialIdNoteIndexRoute
}
export interface FileRoutesByTo {
'/reset-password/$resetToken': typeof authResetPasswordResetTokenRoute
Expand Down Expand Up @@ -264,27 +264,27 @@ export interface FileRouteTypes {
| '/reset-password/$resetToken'
| '/deployments/$deploymentId/enable'
| '/'
| '/reset-password'
| '/signin'
| '/signup'
| '/reset-password/'
| '/signin/'
| '/signup/'
| '/board/$boardId'
| '/call/$callId'
| '/confirm-email/$emailId'
| '/invite/$inviteId'
| '/welcome/email/$emailId'
| '/calendar'
| '/call'
| '/classrooms'
| '/materials'
| '/payments'
| '/welcome/role'
| '/welcome/socials'
| '/welcome/user'
| '/classrooms/$classroomId'
| '/calendar/'
| '/call/'
| '/classrooms/'
| '/materials/'
| '/payments/'
| '/welcome/role/'
| '/welcome/socials/'
| '/welcome/user/'
| '/classrooms/$classroomId/'
| '/classrooms/$classroomId/boards/$boardId'
| '/classrooms/$classroomId/notes/$noteId'
| '/materials/$materialId/board'
| '/materials/$materialId/note'
| '/materials/$materialId/board/'
| '/materials/$materialId/note/'
fileRoutesByTo: FileRoutesByTo
to:
| '/reset-password/$resetToken'
Expand Down Expand Up @@ -374,21 +374,21 @@ declare module '@tanstack/react-router' {
'/(auth)/signup/': {
id: '/(auth)/signup/'
path: '/signup'
fullPath: '/signup'
fullPath: '/signup/'
preLoaderRoute: typeof authSignupIndexRouteImport
parentRoute: typeof rootRouteImport
}
'/(auth)/signin/': {
id: '/(auth)/signin/'
path: '/signin'
fullPath: '/signin'
fullPath: '/signin/'
preLoaderRoute: typeof authSigninIndexRouteImport
parentRoute: typeof rootRouteImport
}
'/(auth)/reset-password/': {
id: '/(auth)/reset-password/'
path: '/reset-password'
fullPath: '/reset-password'
fullPath: '/reset-password/'
preLoaderRoute: typeof authResetPasswordIndexRouteImport
parentRoute: typeof rootRouteImport
}
Expand Down Expand Up @@ -416,56 +416,56 @@ declare module '@tanstack/react-router' {
'/(common)/welcome/user/': {
id: '/(common)/welcome/user/'
path: '/welcome/user'
fullPath: '/welcome/user'
fullPath: '/welcome/user/'
preLoaderRoute: typeof commonWelcomeUserIndexRouteImport
parentRoute: typeof rootRouteImport
}
'/(common)/welcome/socials/': {
id: '/(common)/welcome/socials/'
path: '/welcome/socials'
fullPath: '/welcome/socials'
fullPath: '/welcome/socials/'
preLoaderRoute: typeof commonWelcomeSocialsIndexRouteImport
parentRoute: typeof rootRouteImport
}
'/(common)/welcome/role/': {
id: '/(common)/welcome/role/'
path: '/welcome/role'
fullPath: '/welcome/role'
fullPath: '/welcome/role/'
preLoaderRoute: typeof commonWelcomeRoleIndexRouteImport
parentRoute: typeof rootRouteImport
}
'/(app)/_layout/payments/': {
id: '/(app)/_layout/payments/'
path: '/payments'
fullPath: '/payments'
fullPath: '/payments/'
preLoaderRoute: typeof appLayoutPaymentsIndexRouteImport
parentRoute: typeof appLayoutRoute
}
'/(app)/_layout/materials/': {
id: '/(app)/_layout/materials/'
path: '/materials'
fullPath: '/materials'
fullPath: '/materials/'
preLoaderRoute: typeof appLayoutMaterialsIndexRouteImport
parentRoute: typeof appLayoutRoute
}
'/(app)/_layout/classrooms/': {
id: '/(app)/_layout/classrooms/'
path: '/classrooms'
fullPath: '/classrooms'
fullPath: '/classrooms/'
preLoaderRoute: typeof appLayoutClassroomsIndexRouteImport
parentRoute: typeof appLayoutRoute
}
'/(app)/_layout/call/': {
id: '/(app)/_layout/call/'
path: '/call'
fullPath: '/call'
fullPath: '/call/'
preLoaderRoute: typeof appLayoutCallIndexRouteImport
parentRoute: typeof appLayoutRoute
}
'/(app)/_layout/calendar/': {
id: '/(app)/_layout/calendar/'
path: '/calendar'
fullPath: '/calendar'
fullPath: '/calendar/'
preLoaderRoute: typeof appLayoutCalendarIndexRouteImport
parentRoute: typeof appLayoutRoute
}
Expand Down Expand Up @@ -507,21 +507,21 @@ declare module '@tanstack/react-router' {
'/(app)/_layout/classrooms/$classroomId/': {
id: '/(app)/_layout/classrooms/$classroomId/'
path: '/classrooms/$classroomId'
fullPath: '/classrooms/$classroomId'
fullPath: '/classrooms/$classroomId/'
preLoaderRoute: typeof appLayoutClassroomsClassroomIdIndexRouteImport
parentRoute: typeof appLayoutRoute
}
'/(app)/_layout/materials/$materialId/note/': {
id: '/(app)/_layout/materials/$materialId/note/'
path: '/materials/$materialId/note'
fullPath: '/materials/$materialId/note'
fullPath: '/materials/$materialId/note/'
preLoaderRoute: typeof appLayoutMaterialsMaterialIdNoteIndexRouteImport
parentRoute: typeof appLayoutRoute
}
'/(app)/_layout/materials/$materialId/board/': {
id: '/(app)/_layout/materials/$materialId/board/'
path: '/materials/$materialId/board'
fullPath: '/materials/$materialId/board'
fullPath: '/materials/$materialId/board/'
preLoaderRoute: typeof appLayoutMaterialsMaterialIdBoardIndexRouteImport
parentRoute: typeof appLayoutRoute
}
Expand Down
42 changes: 21 additions & 21 deletions apps/xi.web/vite.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { ConfigEnv, defineConfig, searchForWorkspaceRoot } from 'vite';
import react from '@vitejs/plugin-react';
import { tanstackRouter } from '@tanstack/router-plugin/vite';
import tailwindcss from '@tailwindcss/vite';
// import { VitePWA } from 'vite-plugin-pwa';
import { VitePWA } from 'vite-plugin-pwa';

// https://vite.dev/config/
export default defineConfig(({ mode }: ConfigEnv) => {
Expand All @@ -11,26 +11,26 @@ export default defineConfig(({ mode }: ConfigEnv) => {
tanstackRouter({ target: 'react', autoCodeSplitting: true }),
react(),
tailwindcss(),
// VitePWA({
// registerType: 'autoUpdate',
// injectRegister: 'auto',
// // Отключаем регистрацию SW в dev режиме, чтобы избежать ошибок
// devOptions: {
// enabled: false,
// },
// workbox: {
// globPatterns: ['**/*.{js,css,html,ico,png,svg}'],
// maximumFileSizeToCacheInBytes: 10 * 1024 * 1024, // 10 MB (по умолчанию 2 MB)
// runtimeCaching: [
// {
// handler: 'NetworkOnly',
// urlPattern: /\/deployments\/.*/,
// method: 'GET',
// },
// ],
// navigateFallbackDenylist: [/^\/deployments\/.*/],
// },
// }),
VitePWA({
registerType: 'autoUpdate',
injectRegister: 'auto',
// Отключаем регистрацию SW в dev режиме, чтобы избежать ошибок
devOptions: {
enabled: false,
},
workbox: {
globPatterns: ['**/*.{js,css,html,ico,png,svg}'],
maximumFileSizeToCacheInBytes: 10 * 1024 * 1024, // 10 MB (по умолчанию 2 MB)
runtimeCaching: [
{
handler: 'NetworkOnly',
urlPattern: /\/deployments\/.*/,
method: 'GET',
},
],
navigateFallbackDenylist: [/^\/deployments\/.*/],
},
}),
],
build: {
chunkSizeWarningLimit: 1000,
Expand Down
2 changes: 2 additions & 0 deletions packages/common.env/src/env/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,8 @@ const env = {
VITE_GLITCHTIP_DSN: asString(import.meta.env.VITE_GLITCHTIP_DSN, ''),
};

console.log('env', env);

const checkEnv = (envKey: keyof typeof env): boolean => {
if (envKey in env) return true;
console.error(`%c• ${envKey} isn't defined`, 'color: red');
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ export const useRequestPasswordReset = () => {
data: { email },
headers: {
'Content-Type': 'application/json',
'X-Testing': env.VITE_ENABLE_X_TESTING ? env.VITE_ENABLE_X_TESTING : 'false',
'X-Testing': !env.VITE_ENABLE_X_TESTING ? 'false' : env.VITE_ENABLE_X_TESTING,
},
});

Expand Down
2 changes: 1 addition & 1 deletion packages/common.services/src/auth/useSignin.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ export const useSignin = () => {
data: { email, password },
headers: {
'Content-Type': 'application/json',
'X-Testing': env.VITE_ENABLE_X_TESTING ? env.VITE_ENABLE_X_TESTING : 'false',
'X-Testing': !env.VITE_ENABLE_X_TESTING ? 'false' : env.VITE_ENABLE_X_TESTING,
},
});

Expand Down
2 changes: 1 addition & 1 deletion packages/common.services/src/auth/useSignout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ export const useSignout = () => {
url: authApiConfig[AuthQueryKey.Signout].getUrl(),
headers: {
'Content-Type': 'application/json',
'X-Testing': env.VITE_ENABLE_X_TESTING ? env.VITE_ENABLE_X_TESTING : 'false',
'X-Testing': !env.VITE_ENABLE_X_TESTING ? 'false' : env.VITE_ENABLE_X_TESTING,
},
});

Expand Down
2 changes: 1 addition & 1 deletion packages/common.services/src/auth/useSignup.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ export const useSignup = () => {
data: userData,
headers: {
'Content-Type': 'application/json',
'X-Testing': env.VITE_ENABLE_X_TESTING ? env.VITE_ENABLE_X_TESTING : 'false',
'X-Testing': !env.VITE_ENABLE_X_TESTING ? 'false' : env.VITE_ENABLE_X_TESTING,
},
});

Expand Down
2 changes: 1 addition & 1 deletion packages/common.ui/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
"dependencies": {
"@tanstack/react-router": "1.128.8",
"@xipkg/button": "3.2.0",
"@xipkg/icons": "^2.7.0",
"@xipkg/icons": "^3.0.1",
"@xipkg/link": "2.0.12",
"@xipkg/utils": "1.8.0",
"common.env": "*",
Expand Down
2 changes: 1 addition & 1 deletion packages/features.avatar.editor/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
"common.ui": "*",
"i18next": "24.2.2",
"react-i18next": "15.4.1",
"@xipkg/icons": "^2.7.0",
"@xipkg/icons": "^3.0.1",
"@xipkg/utils": "1.8.0",
"@xipkg/slider": "2.0.12",
"common.config": "*",
Expand Down
2 changes: 1 addition & 1 deletion packages/features.group.invite/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
"@tanstack/react-query": "^5.73.3",
"@tanstack/react-router": "^1.128.8",
"@xipkg/button": "^3.1.8",
"@xipkg/icons": "^2.7.0",
"@xipkg/icons": "^3.0.1",
"@xipkg/input": "^2.2.9",
"@xipkg/modal": "^4.3.1",
"@xipkg/scrollarea": "^2.2.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/features.group.manage/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
"@tanstack/react-query": "^5.73.3",
"@tanstack/react-router": "^1.128.8",
"@xipkg/button": "^3.1.8",
"@xipkg/icons": "^2.7.0",
"@xipkg/icons": "^3.0.1",
"@xipkg/input": "^2.2.9",
"@xipkg/modal": "^4.3.1",
"@xipkg/scrollarea": "^2.2.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/features.invites/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
},
"dependencies": {
"@xipkg/button": "^3.1.8",
"@xipkg/icons": "^2.7.0",
"@xipkg/icons": "^3.0.1",
"@xipkg/modal": "^4.3.1",
"@xipkg/utils": "^1.8.0",
"common.env": "*",
Expand Down
2 changes: 1 addition & 1 deletion packages/features.materials.add/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"dependencies": {
"@xipkg/button": "^3.1.8",
"@xipkg/dropdown": "^3.0.12",
"@xipkg/icons": "^2.7.0",
"@xipkg/icons": "^3.0.1",
"@xipkg/utils": "^1.8.0"
},
"devDependencies": {
Expand Down
2 changes: 1 addition & 1 deletion packages/features.materials.card/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
"@xipkg/button": "^3.1.8",
"@xipkg/badge": "2.0.12",
"@xipkg/dropdown": "^3.0.12",
"@xipkg/icons": "^2.7.0",
"@xipkg/icons": "^3.0.1",
"@xipkg/utils": "^1.8.0",
"common.services": "*",
"common.types": "*",
Expand Down
2 changes: 1 addition & 1 deletion packages/features.materials.duplicate/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"dependencies": {
"@xipkg/button": "^3.1.8",
"@xipkg/dropdown": "^3.0.12",
"@xipkg/icons": "^2.7.0",
"@xipkg/icons": "^3.0.1",
"@xipkg/utils": "^1.8.0",
"@xipkg/select": "^2.2.5",
"@xipkg/modal": "4.3.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/features.students.list/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"dependencies": {
"@tanstack/react-query": "^5.73.3",
"@xipkg/button": "^3.1.8",
"@xipkg/icons": "^2.7.0",
"@xipkg/icons": "^3.0.1",
"@xipkg/input": "^2.2.9",
"@xipkg/modal": "^4.3.1",
"@xipkg/scrollarea": "^2.2.0",
Expand Down
Loading
Loading