Skip to content

Commit

Permalink
feat!: remove immutable (#38)
Browse files Browse the repository at this point in the history
  • Loading branch information
pyphilia authored Nov 3, 2023
1 parent 9f1a0b8 commit 1064593
Show file tree
Hide file tree
Showing 5 changed files with 155 additions and 1,662 deletions.
13 changes: 5 additions & 8 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,10 @@
"@emotion/cache": "11.11.0",
"@emotion/react": "11.11.1",
"@emotion/styled": "11.11.0",
"@graasp/chatbox": "2.0.1",
"@graasp/query-client": "1.11.1",
"@graasp/sdk": "1.9.2",
"@graasp/query-client": "2.0.0",
"@graasp/sdk": "2.0.0",
"@graasp/translations": "1.19.4",
"@graasp/ui": "3.7.0",
"@graasp/ui": "4.0.0",
"@mui/icons-material": "5.14.16",
"@mui/lab": "5.0.0-alpha.151",
"@mui/material": "5.14.16",
Expand All @@ -42,7 +41,7 @@
"qs": "6.11.2",
"react": "18.2.0",
"react-dom": "18.2.0",
"react-i18next": "13.2.2",
"react-i18next": "^13.3.1",
"react-image-crop": "9.1.1",
"react-router": "6.16.0",
"react-router-dom": "6.16.0",
Expand Down Expand Up @@ -117,15 +116,13 @@
"eslint-plugin-react": "7.33.2",
"eslint-plugin-react-hooks": "4.6.0",
"husky": "8.0.3",
"npm-run-all": "4.1.5",
"prettier": "3.0.3",
"rollup-plugin-visualizer": "^5.9.2",
"standard-version": "9.5.0",
"typescript": "5.2.2",
"vite": "4.5.0",
"vite-plugin-checker": "0.6.2",
"vite-plugin-istanbul": "5.0.0",
"wait-on": "7.0.1"
"vite-plugin-istanbul": "5.0.0"
},
"packageManager": "[email protected]"
}
4 changes: 2 additions & 2 deletions src/components/common/UserSwitchWrapper.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { MemberRecord } from '@graasp/sdk/frontend';
import { Member } from '@graasp/sdk';
import { UserSwitchWrapper as GraaspUserSwitch } from '@graasp/ui';

import { GRAASP_AUTH_HOST } from '../../config/constants';
Expand All @@ -16,7 +16,7 @@ const UserSwitchWrapper = ({ ButtonContent }: Props): JSX.Element => {
// todo: does not exist on mutations since we use httpOnly Cookie
// const { mutate: switchMember } = mutations.useSwitchMember();

const renderAvatar = (m?: MemberRecord) => <MemberAvatar id={m?.id} />;
const renderAvatar = (m?: Member | null) => <MemberAvatar id={m?.id} />;

return (
<GraaspUserSwitch
Expand Down
4 changes: 1 addition & 3 deletions src/components/main/Subscriptions.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@ import CssBaseline from '@mui/material/CssBaseline';
import Grid from '@mui/material/Grid';
import Typography from '@mui/material/Typography';

import { List } from 'immutable';

import { DEFAULT_CURRENCY } from '../../config/constants';
import { PAYMENT_CONFIRM_PATH } from '../../config/paths';
import { hooks } from '../../config/queryClient';
Expand All @@ -33,7 +31,7 @@ const { usePlans, useOwnPlan } = hooks;
const Subscriptions = () => {
const { t } = useTranslation();

const { data: plans = List() } = usePlans();
const { data: plans = [] } = usePlans();

const { data: currentPlan } = useOwnPlan();

Expand Down
1 change: 1 addition & 0 deletions src/config/queryClient.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ const {
} = configureQueryClient({
API_HOST,
notifier,
defaultQueryOptions: {},
});
export {
useQueryClient,
Expand Down
Loading

0 comments on commit 1064593

Please sign in to comment.