Skip to content

Commit

Permalink
fix: ratings (#87)
Browse files Browse the repository at this point in the history
make rating empty by default
and remove hover effect

test: downgrade cypress
    see cypress-io/cypress#28982
  • Loading branch information
swouf authored Feb 22, 2024
1 parent 14a027b commit a470d10
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 14 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@
"@vitejs/plugin-react": "^4.2.1",
"@vitest/browser": "^1.3.0",
"concurrently": "8.2.2",
"cypress": "13.6.5",
"cypress": "13.6.4",
"env-cmd": "10.1.0",
"eslint": "8.56.0",
"eslint-config-airbnb": "19.0.4",
Expand Down
5 changes: 1 addition & 4 deletions src/modules/common/LikertScale.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,6 @@ const LikertRating = styled(Rating)(({ theme }) => ({
'& .MuiRating-iconFilled': {
color: theme.palette.primary.main,
},
'& .MuiRating-iconHover': {
color: theme.palette.primary.dark,
},
}));

const Label = styled(Typography)(() => ({
Expand Down Expand Up @@ -61,7 +58,7 @@ const LikertScale = (props: LikertScaleProps): JSX.Element => {
</Label>
<LikertRating
name="likert-rating"
value={value ?? Math.ceil(levels / 2)}
value={value ?? 0}
precision={1}
icon={<RadioButtonCheckedIcon fontSize="inherit" />}
emptyIcon={<RadioButtonUncheckedIcon fontSize="inherit" />}
Expand Down
18 changes: 9 additions & 9 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -5287,7 +5287,7 @@ __metadata:
languageName: node
linkType: hard

"buffer@npm:^5.5.0, buffer@npm:^5.7.1":
"buffer@npm:^5.5.0, buffer@npm:^5.6.0":
version: 5.7.1
resolution: "buffer@npm:5.7.1"
dependencies:
Expand Down Expand Up @@ -6106,9 +6106,9 @@ __metadata:
languageName: node
linkType: hard

"cypress@npm:13.6.5":
version: 13.6.5
resolution: "cypress@npm:13.6.5"
"cypress@npm:13.6.4":
version: 13.6.4
resolution: "cypress@npm:13.6.4"
dependencies:
"@cypress/request": "npm:^3.0.0"
"@cypress/xvfb": "npm:^1.2.4"
Expand All @@ -6117,7 +6117,7 @@ __metadata:
arch: "npm:^2.2.0"
blob-util: "npm:^2.0.2"
bluebird: "npm:^3.7.2"
buffer: "npm:^5.7.1"
buffer: "npm:^5.6.0"
cachedir: "npm:^2.3.0"
chalk: "npm:^4.1.0"
check-more-types: "npm:^2.24.0"
Expand All @@ -6135,7 +6135,7 @@ __metadata:
figures: "npm:^3.2.0"
fs-extra: "npm:^9.1.0"
getos: "npm:^3.2.1"
is-ci: "npm:^3.0.1"
is-ci: "npm:^3.0.0"
is-installed-globally: "npm:~0.4.0"
lazy-ass: "npm:^1.6.0"
listr2: "npm:^3.8.3"
Expand All @@ -6154,7 +6154,7 @@ __metadata:
yauzl: "npm:^2.10.0"
bin:
cypress: bin/cypress
checksum: 10/df11ec229eaab173dd513b7ee59202407450aaf2900798fe09e076636ffae6a86fea8265c608756f1c44f1b0db6096115e2d7007a48bf196c192462c13e9f339
checksum: 10/acdc246cf41bf77b95ab78a26ae7cb000c64abfd768ad7cef54830e1fa8d7e89cee64a56d00a9a389ac36ff6ec8bd704d6fa1d5d92123123c8d96ebae6328b8b
languageName: node
linkType: hard

Expand Down Expand Up @@ -8430,7 +8430,7 @@ __metadata:
"@vitejs/plugin-react": "npm:^4.2.1"
"@vitest/browser": "npm:^1.3.0"
concurrently: "npm:8.2.2"
cypress: "npm:13.6.5"
cypress: "npm:13.6.4"
date-fns: "npm:^3.3.1"
env-cmd: "npm:10.1.0"
eslint: "npm:8.56.0"
Expand Down Expand Up @@ -8958,7 +8958,7 @@ __metadata:
languageName: node
linkType: hard

"is-ci@npm:^3.0.1":
"is-ci@npm:^3.0.0":
version: 3.0.1
resolution: "is-ci@npm:3.0.1"
dependencies:
Expand Down

0 comments on commit a470d10

Please sign in to comment.