Skip to content

Commit

Permalink
Merge pull request #121 from osstotalsoft/upgarde-packages
Browse files Browse the repository at this point in the history
upgrade material-ui
  • Loading branch information
alexandra-c authored Jul 11, 2024
2 parents c4583fc + 41903e5 commit c74184b
Show file tree
Hide file tree
Showing 6 changed files with 1,646 additions and 165 deletions.
2 changes: 1 addition & 1 deletion .vscode/launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
"request": "launch",
"runtimeExecutable": "yarn",
"runtimeArgs": ["run", "test"],
"args": ["--verbose", "-i", "--no-cache", "--testPathPattern", "${fileBasename}"],
"args": ["--verbose", "-i", "--no-cache", "--testPathPattern", "/${fileBasename}"],
"cwd": "${fileDirname}",
"console": "integratedTerminal",
"internalConsoleOptions": "neverOpen"
Expand Down
19 changes: 10 additions & 9 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -56,17 +56,17 @@
"verbose": true
},
"dependencies": {
"@emotion/react": "^11.10.6",
"@emotion/styled": "^11.10.6",
"@mui/icons-material": "^5.11.16",
"@mui/lab": "^5.0.0-alpha.127",
"@mui/material": "^5.12.1",
"@mui/system": "^5.12.1",
"@mui/types": "^7.2.4",
"@emotion/react": "^11.11.4",
"@emotion/styled": "^11.11.5",
"@mui/icons-material": "^5.16.0",
"@mui/lab": "^5.0.0-alpha.171",
"@mui/material": "^5.16.0",
"@mui/system": "^5.16.0",
"@mui/types": "^7.2.14",
"@mui/x-date-pickers": "5.0.0-beta.6",
"attr-accept": "^2.2.2",
"chart.js": "3.9.1",
"classnames": "^2.3.2",
"classnames": "^2.5.1",
"date-fns": "^2.30.0",
"i18next": "^22.4.15",
"lodash": "^4.17.21",
Expand All @@ -81,7 +81,7 @@
},
"devDependencies": {
"@babel/core": "^7.21.4",
"@emotion/css": "^11.10.6",
"@emotion/css": "^11.11.2",
"@nrwl/js": "^15.9.2",
"@storybook/addon-essentials": "7.0.20",
"@storybook/addon-interactions": "7.0.20",
Expand Down Expand Up @@ -122,6 +122,7 @@
"identity-obj-proxy": "^3.0.0",
"jest": "^29.5.0",
"jest-environment-jsdom": "^29.5.0",
"jest-runner-vscode": "^3.0.1",
"prettier": "^2.8.7",
"prop-types": "15.8.1",
"react-syntax-highlighter": "^15.5.0",
Expand Down
2 changes: 1 addition & 1 deletion src/components/buttons/Button/Button.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ const Button: React.FC<ButtonProps> = ({
[classes.gradient]: gradient
})

const classNames = `${classes.button} ${btnClasses}`
const classNames = btnClasses ? `${classes.button} ${btnClasses}` : classes?.button || {}

const Comp = useMemo(() => createButton(loading), [loading])

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import { Validator } from './types'
const verifiedFileType = curry(flip(accepts))
const invalidFileType = curry(pipe(verifiedFileType, not)) as (arg1: string) => (arg2: File) => boolean

const getSize = prop<number>('size')
const getSize = prop<any>('size') as (file: File) => number
const totalSize = pipe(map(getSize), sum) as (files: unknown) => number

const biggerItems = curry((maxItemSize, file) => lt(maxItemSize, getSize(file)))
Expand Down
4 changes: 2 additions & 2 deletions src/components/dataDisplay/Typography/Typography.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ const emphasisToCSSProps = {
'line-through': { textDecoration: 'line-through' },
underline: { textDecoration: 'underline' }
}
const getCSSPropsFromEmphasis = (emphasis: string) => R.prop<React.CSSProperties>(emphasis, emphasisToCSSProps)
const getCSSPropsFromEmphasis = (emphasis: Emphasis) => emphasisToCSSProps?.[emphasis]

const parseEmphasis = (emphasis?: Emphasis | Emphasis[]): React.CSSProperties => {
if (!emphasis) return {}
Expand All @@ -22,7 +22,7 @@ const parseEmphasis = (emphasis?: Emphasis | Emphasis[]): React.CSSProperties =>
return R.reduce<string, React.CSSProperties>(
(acc, elem) => {
// Retrieves the associated CSS object for an emphasis value
const cssObj = getCSSPropsFromEmphasis(elem)
const cssObj = getCSSPropsFromEmphasis(elem as Emphasis)
/**
* If 2 or more CSS objects have the same property, we need to merge their values
* e.g.
Expand Down
Loading

0 comments on commit c74184b

Please sign in to comment.