Skip to content

Commit

Permalink
Merge pull request #1019 from AppQuality/develop
Browse files Browse the repository at this point in the history
Add translations functionality, update major dependencies (design system, node), switch to vite
  • Loading branch information
cannarocks authored Oct 24, 2024
2 parents 7836b80 + 95fb1d1 commit 3a96d00
Show file tree
Hide file tree
Showing 147 changed files with 9,293 additions and 16,811 deletions.
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ RUN rm -f .npmrc
COPY . .

RUN echo REACT_APP_STRAPI_API_TOKEN=${STRAPI_TOKEN} > .env.local

ENV PUBLIC_URL=/
RUN ["yarn", "build"]
RUN ["yarn", "sentry:sourcemaps"]

Expand Down
11 changes: 0 additions & 11 deletions Makefile

This file was deleted.

39 changes: 0 additions & 39 deletions craco.config.js

This file was deleted.

2 changes: 1 addition & 1 deletion public/index.html → index.html
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@
></script>

<title>Unguess | Be smart from the start</title>
</head>
<script type="module" src="src/index"></script></head>
<body>
<noscript>You need to enable JavaScript to run this app.</noscript>
<div id="root">
Expand Down
47 changes: 17 additions & 30 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,16 +3,11 @@
"version": "1.4.0",
"private": true,
"dependencies": {
"@appquality/unguess-design-system": "3.1.114",
"@appquality/languages": "1.4.3",
"@appquality/unguess-design-system": "4.0.5",
"@headwayapp/react-widget": "^0.0.4",
"@reduxjs/toolkit": "^1.8.0",
"@rtk-query/codegen-openapi": "1.2.0",
"@sentry/react": "^8.32.0",
"@zendeskgarden/react-datepickers": "8.49.0",
"@zendeskgarden/react-dropdowns": "8.49.0",
"@zendeskgarden/react-forms": "8.49.0",
"@zendeskgarden/react-tables": "8.62.0",
"@zendeskgarden/react-theming": "8.76.7",
"@zendeskgarden/svg-icons": "^7.2.0",
"date-fns": "^2.28.0",
"formik": "^2.2.9",
Expand All @@ -28,7 +23,6 @@
"react-i18next": "^15.0.2",
"react-redux": "^7.2.6",
"react-router-dom": "^6.4.0",
"react-scripts": "4.0.3",
"react-scroll": "^1.9.0",
"styled-components": "^6.1.1",
"typescript": "^4.6.2",
Expand All @@ -37,12 +31,9 @@
"yup": "^0.32.11"
},
"scripts": {
"start": "craco start",
"start:ssl": "craco --openssl-legacy-provider start",
"build": "craco build",
"test": "react-scripts test",
"start": "vite",
"build": "vite build",
"test:e2e:ui": "npx playwright test --headed",
"test:watch": "react-scripts test --watch",
"test:e2e": "npx playwright test",
"recover": "yarn install --check-files",
"translate": "i18next 'src/**/*.{js,jsx,ts,tsx}' ",
Expand All @@ -57,7 +48,8 @@
"lint": "eslint --ext .tsx,.ts .",
"validate": "run-p lint type:check format:check",
"prepare": "husky install",
"sentry:sourcemaps": "sentry-cli sourcemaps inject --org appquality-srl --project unguess-react ./build && sentry-cli sourcemaps upload --org appquality-srl --project unguess-react ./build"
"sentry:sourcemaps": "sentry-cli sourcemaps inject --org appquality-srl --project unguess-react ./build && sentry-cli sourcemaps upload --org appquality-srl --project unguess-react ./build",
"dev": "vite --mode development"
},
"browserslist": {
"production": [
Expand All @@ -72,19 +64,15 @@
]
},
"devDependencies": {
"@babel/core": "7.16.0",
"@babel/plugin-proposal-private-property-in-object": "^7.21.11",
"@babel/plugin-transform-logical-assignment-operators": "^7.24.7",
"@babel/plugin-transform-nullish-coalescing-operator": "^7.24.7",
"@babel/plugin-transform-optional-chaining": "^7.24.8",
"@babel/preset-env": "7.16.0",
"@craco/craco": "6.4.2",
"@currents/playwright": "^1.5.6",
"@playwright/test": "^1.46.0",
"@rtk-query/codegen-openapi": "1.2.0",
"@sentry/cli": "^2.23.0",
"@sentry/types": "^8.32.0",
"@svgr/core": "^8.1.0",
"@svgr/plugin-jsx": "^8.1.0",
"@testing-library/jest-dom": "^5.16.2",
"@types/node": "^22.7.4",
"@types/node": "^20.14.2",
"@types/qs": "^6.9.7",
"@types/react": "^18.3.9",
"@types/react-dom": "^18.3.0",
Expand All @@ -93,10 +81,11 @@
"@types/react-scroll": "^1.8.10",
"@types/react-transition-group": "^4.4.5",
"@types/uuid": "^10.0.0",
"@typescript-eslint/eslint-plugin": "^5.26.0",
"@typescript-eslint/parser": "^5.26.0",
"@typescript-eslint/eslint-plugin": "^5.0.0",
"@typescript-eslint/parser": "^5.0.0",
"@vitejs/plugin-react": "^4.3.1",
"cz-conventional-changelog": "3.3.0",
"eslint": "^7.32.0",
"eslint": "^8.1.0",
"eslint-config-airbnb": "^19.0.4",
"eslint-config-prettier": "^8.5.0",
"eslint-import-resolver-typescript": "^2.7.1",
Expand All @@ -113,7 +102,8 @@
"openapi-typescript": "^5.1.0",
"playwright-i18next-fixture": "^1.0.0",
"prettier": "^2.6.2",
"ts-node": "^10.9.1"
"vite": "^5.2.13",
"vite-tsconfig-paths": "^4.3.2"
},
"config": {
"commitizen": {
Expand All @@ -122,10 +112,7 @@
},
"resolutions": {
"//": "See https://github.com/facebook/create-react-app/issues/11773",
"react-error-overlay": "6.0.9",
"styled-components": "^6.1.1",
"@types/react": "18.3.9",
"@babel/core": "7.16.0"
"react-error-overlay": "6.0.9"
},
"lint-staged": {
"*.{tsx,ts,js,css,md}": "prettier --write"
Expand Down
4 changes: 1 addition & 3 deletions playwright.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -75,9 +75,7 @@ export default defineConfig({

/* Run your local dev server before starting the tests */
webServer: {
command: process.env.CI
? 'export NODE_ENV=test && yarn start:ssl'
: 'export NODE_ENV=test && yarn start:ssl',
command: 'export NODE_ENV=test && yarn dev',
url: 'http://127.0.0.1:3000',
reuseExistingServer: !process.env.CI,
timeout: 120 * 1000,
Expand Down
15 changes: 9 additions & 6 deletions src/app/App.tsx
Original file line number Diff line number Diff line change
@@ -1,11 +1,14 @@
import '../i18n';
import { GlobalStyle, ToastProvider } from '@appquality/unguess-design-system';
import { ThemeProvider } from '@zendeskgarden/react-theming';
import { useTranslation } from 'react-i18next';
import {
GlobalStyle,
ThemeProvider,
ToastProvider,
} from '@appquality/unguess-design-system';
import Helmet from 'react-helmet';
import Pages from 'src/common/Pages';
import { appTheme } from 'src/app/theme';
import { useTranslation } from 'react-i18next';
import { Provider } from 'react-redux';
import { appTheme } from 'src/app/theme';
import Pages from 'src/common/Pages';
import '../i18n';
import { store } from './store';

const App = () => {
Expand Down
11 changes: 11 additions & 0 deletions src/assets/icons/ai-icon.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading

0 comments on commit 3a96d00

Please sign in to comment.