Skip to content

Commit

Permalink
fix: settings icon color on hover
Browse files Browse the repository at this point in the history
  • Loading branch information
gabaldon committed Feb 29, 2024
1 parent afbc9a9 commit d36e16e
Show file tree
Hide file tree
Showing 5 changed files with 50 additions and 13 deletions.
11 changes: 9 additions & 2 deletions src/resources/svg/close-btn-dark.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
11 changes: 9 additions & 2 deletions src/resources/svg/close-btn-light-dark.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
11 changes: 9 additions & 2 deletions src/resources/svg/close-btn-light.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
11 changes: 9 additions & 2 deletions src/resources/svg/close-btn.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
19 changes: 14 additions & 5 deletions src/views/Settings.vue
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,12 @@
@mouseleave="mouseLeaveAction"
@click="close"
>
<CustomIcon class-name="cross" :name="btnUrl" />
<CustomIcon
v-if="!showLightIcon"
class-name="cross"
:name="'close-btn'"
/>
<CustomIcon v-else :name="'close-btn-light'" />
</div>
<Version />
</div>
Expand Down Expand Up @@ -50,7 +55,7 @@ export default {
data() {
return {
previousRoute: '',
btnUrl: 'close-btn',
showLightIcon: false,
}
},
computed: {
Expand Down Expand Up @@ -116,10 +121,10 @@ export default {
this.$router.push(this.previousRoute)
},
hoverAction() {
this.btnUrl = 'close-btn-light'
this.showLightIcon = true
},
mouseLeaveAction() {
this.btnUrl = 'close-btn'
this.showLightIcon = false
},
},
}
Expand Down Expand Up @@ -150,13 +155,17 @@ export default {
}
.close {
border: 2px solid $grey-2;
border: 1px solid $grey-2;
border-radius: 50%;
cursor: pointer;
height: 36px;
width: 36px;
padding: 8px;
position: absolute;
right: 0;
display: flex;
align-items: center;
justify-content: center;
top: 32px;
&:hover {
Expand Down

0 comments on commit d36e16e

Please sign in to comment.