Skip to content
This repository has been archived by the owner on Mar 19, 2024. It is now read-only.

Commit

Permalink
Disable hover for touch devices
Browse files Browse the repository at this point in the history
  • Loading branch information
dreit-p committed Nov 10, 2020
1 parent 392be4a commit e4d8cbb
Show file tree
Hide file tree
Showing 6 changed files with 28 additions and 26 deletions.
8 changes: 0 additions & 8 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,16 +5,9 @@
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
},
"repository": {
"type": "git",
"url": "git+https://github.com/dreit-p/soundstage.git"
},
"keywords": [],
"author": "",
"license": "ISC",
"bugs": {
"url": "https://github.com/dreit-p/soundstage/issues"
},
"browserslist": [
"last 2 Chrome versions",
"last 7 Firefox versions",
Expand All @@ -23,7 +16,6 @@
"Edge 16",
"last 5 iOS versions"
],
"homepage": "https://www.soundstage.fm/",
"description": "",
"devDependencies": {
"@babel/core": "^7.7.0",
Expand Down
10 changes: 6 additions & 4 deletions src/components/appeal/appeal.scss
Original file line number Diff line number Diff line change
Expand Up @@ -48,10 +48,12 @@ article.appeal {
transform: translateY(calc(100% - 4px));
transition: transform .3s;
}
&:hover {
&:after {
transition-duration: .2s;
transform: translateY(0px);
@media (hover: hover) and (pointer: fine) {
&:hover {
&:after {
transition-duration: .2s;
transform: translateY(0px);
}
}
}
}
Expand Down
2 changes: 1 addition & 1 deletion src/components/cases/cases.scss
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ article.cases {
opacity: 0;
transition: transform .4s, opacity .4s;
}
@media (min-width: 951px) {
@media (min-width: 951px) and (hover: hover) and (pointer: fine) {
&:hover {
.description {
opacity: 1;
Expand Down
16 changes: 10 additions & 6 deletions src/components/footer/footer.scss
Original file line number Diff line number Diff line change
Expand Up @@ -140,10 +140,12 @@ footer.main-footer {
transform: rotate(-90deg) translateX(70%);
}
}
&:hover {
color: hsl(281 70% 70% / 1);
.arrow {
transform: translateX(5px);
@media (hover: hover) and (pointer: fine) {
&:hover {
color: hsl(281 70% 70% / 1);
.arrow {
transform: translateX(5px);
}
}
}
}
Expand Down Expand Up @@ -181,8 +183,10 @@ footer.main-footer {
width: 30px;
height: 30px;
}
&:hover {
color: hsl(281 70% 70% / 1);
@media (hover: hover) and (pointer: fine) {
&:hover {
color: hsl(281 70% 70% / 1);
}
}
}
}
Expand Down
6 changes: 4 additions & 2 deletions src/components/modals/contents/menu.scss
Original file line number Diff line number Diff line change
Expand Up @@ -77,8 +77,10 @@
text-decoration: none;
padding: 6px 0;
margin: 6px 0;
&:hover {
text-decoration: underline;
@media (hover: hover) and (pointer: fine) {
&:hover {
text-decoration: underline;
}
}
}
}
Expand Down
12 changes: 7 additions & 5 deletions src/components/ui-elems/buttons.scss
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,13 @@
opacity: 1;
transition: transform .3s, opacity .3s;
}
&:hover {
&:after {
opacity: .4;
transform: translateX(-100%);
transition-timing-function: ease-out;
@media (hover: hover) and (pointer: fine) {
&:hover {
&:after {
opacity: .4;
transform: translateX(-100%);
transition-timing-function: ease-out;
}
}
}
}
Expand Down

0 comments on commit e4d8cbb

Please sign in to comment.