From 433962321a1c30ae11a73ceac18692acb7f328be Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=A9my=20M?= Date: Fri, 30 Jun 2023 08:26:06 +0200 Subject: [PATCH] feat: onboarding ui flow (#464) * feat: onboarding ui flow * fix: route naming and auth * fix: clean unused imports * fix: remove react.fc * fix: infra dev remove package.json * fix: remove usefull memoization * fix: button stories * fix: use type instead of interface * fix: remove debug --- .vscode/settings.json | 1 - front/.storybook/main.js | 5 +- front/.storybook/preview-head.html | 5 +- front/package.json | 3 + front/src/App.tsx | 38 ++- front/src/AppWrapper.tsx | 23 -- front/src/index.css | 2 +- front/src/index.tsx | 20 +- .../modules/auth/components/ui/FooterNote.tsx | 10 +- .../modules/auth/components/ui/InputLabel.tsx | 16 -- front/src/modules/auth/components/ui/Logo.tsx | 11 +- .../src/modules/auth/components/ui/Modal.tsx | 18 +- .../modules/auth/components/ui/Section.tsx | 31 +++ .../src/modules/auth/components/ui/Title.tsx | 20 +- .../src/modules/ui/components/board/Board.tsx | 4 +- .../modules/ui/components/buttons/Button.tsx | 152 ++++++++++++ .../ui/components/buttons/MainButton.tsx | 87 +++++++ .../ui/components/buttons/PrimaryButton.tsx | 42 ---- .../ui/components/buttons/SecondaryButton.tsx | 43 ---- .../buttons/__stories__/Button.stories.tsx | 230 ++++++++++++++++++ .../__stories__/MainButton.stories.tsx | 104 ++++++++ .../__stories__/PrimaryButton.stories.tsx | 47 ---- .../__stories__/SecondaryButton.stories.tsx | 47 ---- .../editable-cell/types/EditableDate.tsx | 4 +- .../ui/components/inputs/ImageInput.tsx | 123 ++++++++++ .../ui/components/inputs/TextInput.tsx | 57 +++-- .../src/modules/ui/components/modal/Modal.tsx | 69 ++++-- .../ui/components/motion/AnimatedEaseIn.tsx | 29 +++ .../ui/components/motion/AnimatedTextWord.tsx | 70 ++++++ front/src/modules/ui/icons/index.ts | 2 + front/src/modules/ui/layout/AuthLayout.tsx | 11 + .../ui/layout/navbar/NavCollapseButton.tsx | 4 +- .../ui/layout/navbar/NavbarContainer.tsx | 16 +- front/src/modules/ui/themes/boxShadow.ts | 2 + front/src/modules/ui/themes/colors.ts | 1 + front/src/pages/auth/CreateProfile.tsx | 92 +++++++ front/src/pages/auth/CreateWorkspace.tsx | 74 ++++++ front/src/pages/auth/Index.tsx | 92 ++++--- front/src/pages/auth/PasswordLogin.tsx | 78 +++--- front/src/providers/apollo/ApolloProvider.tsx | 6 +- front/src/providers/user/UserProvider.tsx | 6 +- front/yarn.lock | 147 ++++++++++- infra/dev/package-lock.json | 6 - server/package.json | 4 +- server/yarn.lock | 10 + 45 files changed, 1461 insertions(+), 401 deletions(-) delete mode 100644 front/src/AppWrapper.tsx delete mode 100644 front/src/modules/auth/components/ui/InputLabel.tsx create mode 100644 front/src/modules/auth/components/ui/Section.tsx create mode 100644 front/src/modules/ui/components/buttons/Button.tsx create mode 100644 front/src/modules/ui/components/buttons/MainButton.tsx delete mode 100644 front/src/modules/ui/components/buttons/PrimaryButton.tsx delete mode 100644 front/src/modules/ui/components/buttons/SecondaryButton.tsx create mode 100644 front/src/modules/ui/components/buttons/__stories__/Button.stories.tsx create mode 100644 front/src/modules/ui/components/buttons/__stories__/MainButton.stories.tsx delete mode 100644 front/src/modules/ui/components/buttons/__stories__/PrimaryButton.stories.tsx delete mode 100644 front/src/modules/ui/components/buttons/__stories__/SecondaryButton.stories.tsx create mode 100644 front/src/modules/ui/components/inputs/ImageInput.tsx create mode 100644 front/src/modules/ui/components/motion/AnimatedEaseIn.tsx create mode 100644 front/src/modules/ui/components/motion/AnimatedTextWord.tsx create mode 100644 front/src/modules/ui/layout/AuthLayout.tsx create mode 100644 front/src/pages/auth/CreateProfile.tsx create mode 100644 front/src/pages/auth/CreateWorkspace.tsx delete mode 100644 infra/dev/package-lock.json diff --git a/.vscode/settings.json b/.vscode/settings.json index 2311f1916..9696c8c80 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -31,7 +31,6 @@ "!javascript", "!json", "!typescript", - "!typescriptreact", "md", "mdx" ], diff --git a/front/.storybook/main.js b/front/.storybook/main.js index 4d4d827e6..fc1005781 100644 --- a/front/.storybook/main.js +++ b/front/.storybook/main.js @@ -52,8 +52,9 @@ module.exports = { "@storybook/addon-essentials", "@storybook/addon-interactions", "@storybook/addon-coverage", - "@storybook/addon-styling" - + "@storybook/addon-styling", + "@storybook/addon-knobs", + "storybook-addon-pseudo-states", ], framework: { name: '@storybook/react-webpack5', diff --git a/front/.storybook/preview-head.html b/front/.storybook/preview-head.html index 5d0269ace..38d225385 100644 --- a/front/.storybook/preview-head.html +++ b/front/.storybook/preview-head.html @@ -1,4 +1,7 @@ - +