Skip to content

Commit

Permalink
Migrate from Webpack to Vite (#386)
Browse files Browse the repository at this point in the history
* fix(deps): update dependency @aws-amplify/auth to v4 (#352)

Co-authored-by: Renovate Bot <[email protected]>

* Feature: Added Dark theme (#365)

* Theme provider to Syllabus & context to containers

* Add context on components in Syllabus which may require fix for dark mode

* feat: replace @reach/router to react-router v6

* feat: update header for all apps

* fix: reinstall react-router-dom v6 and history after rebase

* feat: add new themes

* fix: lock files

* feat: install TailwindCSS on Campus

* feat: install TailwindCSS on Syllabus

* feat: change theme-toggle color according to current theme

* fix: change locations of tailwind import; remove unused log

* feat: dark theme on Timetable

* Feat: Added new sidebar icons from material ui icons

* Feat: Separated icons into different component

* fix: added package json and pnpm lock updates

* feat: pass isDark property to styled components

* feat: dark theme on Syllabus (CourseItem not yet)

* fix: wrap ThemeProvider on Nav; use new theme colors

* fix: use className instead of passing theme as props

* feat: dark theme on CourseInfo (not completed)

* fix: Made theme types exportable

* fix: created sidebar wrapper locally instead of bit

* fix: Fixed styling of icon group button

* feat: added user profile icon

* feat: Added dark mode styling to other links

* fix: moved browser router wrapper outside to fix navigation

* fix: used const instead of let for navigation hook

* fix: fixed import order

* feat: CourseInfo dark mode

* feat: Made title logo svg into a component

* fix: made title logo text colour change when theme toggle

* fix: fixed extra stylings when dark mode

* fix: updated package versions and pnpm lock file

* feat: update loading-spinner & solve background color flicker while loading page in dark mode

* feat: added dark mode styling to about us pages

* feat: added dark mode styling to extra pages

* feat: dark theme to mobile bottom nav

* feat: update header & loading-spinner & body tag background color

* feat: added dark mode background

* fix: fixed title logo on sidebar not changing colours when switching modes

* fix: added tab colours when dark mode

* fix: added dark mode colours to partner page text

* feat: dark mode for Labs

* fix: related courses width

* feat: update spinner in Syllabus; dark mode for Campus

* fix: timetable course item scrollable space height

* feat: make timetable course item darker in dark mode

* feat: install tailwind in feeds (not used yet)

* feat: redirecting page styling

* feat: update sign in modal

* feat: updated header component and pnpm lock file accordingly

* fix: updated colors and header dependencies

* fix: eslint fixes for campus folder

* feat: added dark mode styling to campus folder

* fix: eslint fixes in syllabus folder

* fix: updated dark mode styling

* fix: updated dark mode syllabus

* fix: updated dark mode styling root folder

* fix: syllabus border & step arrow color

* fix: fixed styling for social media icons in partners

* fix: removed unused imports

* fix: Or-button dark mode color

* fix: remove FilterWarningsPlugin

* fix: update lock files

* fix: remove -y option

* fix: update lock files

* fix: update @aws-amplify/auth in syllabus

* fix: update loading spinner in Feeds

* fix: add theme prop to LoadingSpinner in Feeds

Co-authored-by: YHhaoareyou <[email protected]>

* fix: clear search keywords when onclick related courses

* Debug: mobile dark mode debug (#373)

* feat: dark mode & new messages on welcome modal

* fix: dark mode on sign in modal & user login icon

* chore(deps): update dependency eslint-plugin-react to v7.29.4 (#361)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update dependency ts-loader to v9.2.8 (#359)

Co-authored-by: Renovate Bot <[email protected]>

* feat: remove unused dependencies (#377)

* Feature/darktheme colors (#378)

* feat: added quarterColors for both light and dark mode

* feat: Added google analytics to theme changes

* fix: fixed user profile icon to make it consistent

* fix: code refactoring

* fix: code refactoring in syllabus

* feat: added dark semantic colors

* fix: added colors based on numbers too

* fix: added a todo comment

* fix: fix semantic text colors dark mode

* feat: update quarter switch colors & icons

* feat: update timetable course items and color selector with new theme colors

Co-authored-by: Nicholas Narmada <[email protected]>

* Feature: Timetable dark theme (#379)

* feat: Dark mode for pro tips and colors selector popup in Timetable

* feat: update theme colors dependency for all apps

* feat: add the hovering effect to the member cards (#381)

* feat: update the hovering effect for member cards

* fix: remove unused libraries; fix html background color in dark mode; disable card's hyperlink

* fix: makes the code shorter and neater

* fix: syllabus pnpm lock file

* fix: syllabus pnpm lock file

Co-authored-by: YHhaoareyou <[email protected]>

* Migrate from Webpack to Vite (#382)

* feat: vite tested by career folder

* feat: replace systemjs import with dynamic import to import vite project

* feat: ignore dynamic import problem caused by webpack

* feat: Migrate Campus from Webpack to Vite

* fix: restore career

* feat: register vite app campus by single-spa-layout

* feat: migrate Syllabus to vite (error unsolved)

* fix: fix lockfile

* fix: solve "exportStar not a function", "undefined global" and use Vite envvar

* feat: migrate syllabus to vite (done)

* remove webpack from all apps except root

* feat: migrate root to vite

* feat: remove webpack related scripts & solve import-map not supported problem in Safari

* feat: import static assets; solve errors of custom props passed to dom

* fix: run eslint fix

* fix: build script & config

* feat: build config & debug global var

* fix: output asset files path

* feat: disable css code split in build

* fix: run eslint fix

* feat: preload css from mf apps to root; replace react-s-alert with react-toastify

* feat: configure public path & env var for each app

* fix: run eslint fix

* feat: service-worker

* fix: eslint fix

* update lock files

* fix: missing package

* fix: externalize styles from other mf app

* fix: campus room badge styles

Co-authored-by: AustinZhu <[email protected]>

* fix: env without using dotenv explicitly (#385)

* fix: packages version

* fix: change env var name

* fix: remove systemjs package; add peer dependencies

* fix: feeds domain on staging/prod

* Feature: About Us page link from Home page & split Home from Root-config (#387)

* fix: remove custom sw

* feat: add link to aboutus page from home

* fix: eslint

* Feature/fix card padding (#388)

* fix: fixing the responsive design for members card

* fix: fixing the responsive design for members card

* fix: font color, repeated className, figure tag

* fix: install missing dependency: @aws-amplify/core

* fix: remove course function

* feat: alert translation

* fix: eslint

* feat: add workbox runtimeCaching config

* Fix service worker to enable it to replace old one (#389)

* fix: add cleanupOutdatedCaches option

* use custom sw & force update

* skipWaiting and claim before cleanupOutdatedCaches

* add ts files to NetworkFirst cache

* remove ts from cache

* register sw on index.html

* change sw from ts to js

* test updates to trigger build

* registerSW in index.html

* remove unused code and comment of registering sw

* update files to trigger build

* feat: add a profile card component; add hover & click effect; add a closing tab on cards (#390)

* feat: add a profile card component;
add hover & click effect;
add closing tab on cards

* fix: rename profile card & prop; type for useState

* fix: syllabus minor styling issues

* Update README.md

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Renovate Bot <[email protected]>
Co-authored-by: Nicholas Narmada <[email protected]>
Co-authored-by: Nicholas Narmada <[email protected]>
Co-authored-by: Xinyue Tao <[email protected]>
Co-authored-by: AustinZhu <[email protected]>
  • Loading branch information
7 people authored May 29, 2022
1 parent d0bf85a commit 156663d
Show file tree
Hide file tree
Showing 112 changed files with 9,904 additions and 10,439 deletions.
15 changes: 12 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,12 @@ Installation with other ways: https://pnpm.io/installation

3. Then install Bit on your computer (local): https://docs.bit.dev/docs/installation

4. Check your Bit authentication token with the following command:
4. Login to Bit on your terminal
```
bit login
```

5. Check your Bit authentication token with the following command:
```
bit config
```
Expand Down Expand Up @@ -226,7 +231,9 @@ Whenever there is some progress in your work, commit it.
## Create a new app (micro-app) in WasedaTime
*For new big features which is obviously less related to other existing apps (syllabus, campus, feeds)*
*This section is being moved to internal documentation since it is an instruction for creating new & big features, which would be leave to our team members.*
<!--
1. Install `create-single-spa`
```bash
Expand Down Expand Up @@ -275,6 +282,8 @@ pnpm i
```
Then run `pnpm run local` inside root folder. This runs all app at the same time. Open http://localhost:9000 to see the result.
-->
# Contributors
<!-- ALL-CONTRIBUTORS-LIST:START - Do not remove or modify this section -->
Expand Down Expand Up @@ -321,4 +330,4 @@ This project follows the [all-contributors](https://github.com/kentcdodds/all-co
This project is licensed under the MIT License - see the [LICENSE.md](LICENSE.md) file for details
[![FOSSA Status](https://app.fossa.com/api/projects/git%2Bgithub.com%2Fwasedatime%2Fwasedatime-web.svg?type=large)](https://app.fossa.com/projects/git%2Bgithub.com%2Fwasedatime%2Fwasedatime-web?ref=badge_large)
[![FOSSA Status](https://app.fossa.com/api/projects/git%2Bgithub.com%2Fwasedatime%2Fwasedatime-web.svg?type=large)](https://app.fossa.com/projects/git%2Bgithub.com%2Fwasedatime%2Fwasedatime-web?ref=badge_large)
63 changes: 38 additions & 25 deletions campus/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,13 @@
"name": "@wasedatime/campus",
"scripts": {
"preinstall": "npx only-allow pnpm",
"start": "webpack serve --port 8081 --env isLocal",
"start:standalone": "webpack serve --env standalone",
"start": "vite --port 8081",
"build": "vite build",
"build-dev": "vite build --mode staging",
"preview": "vite preview --port 8081",
"preview-dev": "vite preview --mode staging --port 8081",
"tsc": "tsc",
"local": "concurrently --kill-others \"pnpm start\" \"cd ../root && pnpm start\"",
"build": "webpack --mode=production",
"build-dev": "webpack --mode=production --env isDev",
"analyze": "webpack --mode=production --env analyze",
"fix": "pnpm run format && pnpm run lint:fix",
"lint": "eslint src --ext \"**/*.{js,ts,tsx}\"",
"lint:fix": "eslint --fix \"**/*.{js,ts,tsx}\"",
Expand All @@ -16,19 +17,23 @@
"devDependencies": {
"@babel/core": "7.17.5",
"@babel/eslint-parser": "7.17.0",
"@babel/plugin-syntax-flow": "^7.16.7",
"@babel/plugin-transform-react-jsx": "^7.17.3",
"@babel/plugin-transform-runtime": "7.17.0",
"@babel/preset-env": "7.16.11",
"@babel/preset-react": "7.16.7",
"@babel/preset-typescript": "7.16.7",
"@babel/runtime": "7.17.2",
"@types/systemjs": "6.1.1",
"@fortawesome/fontawesome-svg-core": "1.3.0",
"@popperjs/core": "^2.11.5",
"@types/node": "17.0.21",
"@typescript-eslint/eslint-plugin": "5.14.0",
"@typescript-eslint/parser": "5.14.0",
"autoprefixer": "10.4.2",
"babel-plugin-styled-components": "2.0.6",
"concurrently": "7.0.0",
"css-loader": "6.7.1",
"cssnano": "5.1.0",
"dotenv": "^16.0.0",
"eslint": "8.10.0",
"eslint-config-airbnb": "19.0.4",
"eslint-config-prettier": "8.5.0",
Expand All @@ -38,39 +43,32 @@
"eslint-plugin-prefer-arrow": "1.2.3",
"eslint-plugin-prettier": "4.0.0",
"eslint-plugin-react": "7.29.4",
"eslint-plugin-react-hooks": "4.3.0",
"postcss": "8.4.8",
"postcss-loader": "5.3.0",
"prettier": "2.5.1",
"prettier-eslint": "13.0.0",
"prop-types": "^15.8.1",
"react-is": "^18.1.0",
"react-native": "^0.68.1",
"sass": "1.49.9",
"sass-loader": "12.6.0",
"style-loader": "3.3.1",
"tailwindcss": "3.0.23",
"ts-config-single-spa": "2.0.1",
"ts-loader": "9.2.8",
"typescript": "4.6.2",
"webpack": "5.70.0",
"webpack-cli": "4.9.2",
"webpack-config-single-spa-react-ts": "4.0.3",
"webpack-dev-server": "4.7.4",
"webpack-merge": "5.8.0"
"typescript": "4.6.2"
},
"dependencies": {
"@aws-amplify/auth": "4.4.4",
"@bit/wasedatime.core.assets.img.logo": "0.0.1",
"@bit/wasedatime.core.theme.colors": "0.0.5",
"@bit/wasedatime.core.theme.colors": "0.0.4",
"@bit/wasedatime.core.ts.constants.langs": "0.0.5",
"@bit/wasedatime.core.ts.ui.header": "0.2.17",
"@bit/wasedatime.core.ts.ui.loading-spinner": "0.1.2",
"@bit/wasedatime.core.ts.ui.header": "0.2.21",
"@bit/wasedatime.core.ts.ui.loading-spinner": "0.1.5",
"@bit/wasedatime.core.ts.utils.i18n": "0.0.4",
"@bit/wasedatime.core.ts.utils.responsive-utils": "0.0.1",
"@fortawesome/free-solid-svg-icons": "6.0.0",
"@fortawesome/react-fontawesome": "0.1.17",
"@types/react": "17.0.39",
"@types/react-dom": "17.0.13",
"@types/styled-components": "5.1.24",
"@types/systemjs": "6.1.1",
"@types/webpack-env": "1.16.3",
"@vitejs/plugin-react-refresh": "^1.3.6",
"bootstrap": "5.1.3",
"i18next": "19.9.2",
"react": "17.0.2",
Expand All @@ -80,8 +78,23 @@
"react-ga": "3.3.0",
"react-helmet": "6.1.0",
"react-i18next": "11.15.6",
"react-router-dom": "^6.2.2",
"react-router-dom": "^6.3.0",
"single-spa-react": "3.2.0",
"styled-components": "5.3.3"
"styled-components": "5.3.3",
"vite": "^2.9.8",
"vite-plugin-dynamic-import": "^0.7.1"
},
"resolutions": {
"esbuild": "0.14.34"
},
"peerDependencies": {
"@babel/plugin-syntax-flow": "^7.16.7",
"@babel/plugin-transform-react-jsx": "^7.17.3",
"@fortawesome/fontawesome-svg-core": "1.3.0",
"@popperjs/core": "^2.11.5",
"eslint-plugin-react-hooks": "4.3.0",
"prop-types": "^15.8.1",
"react-is": "^18.1.0",
"react-native": "^0.68.1"
}
}
Loading

0 comments on commit 156663d

Please sign in to comment.