forked from epicmaxco/vuestic-admin
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Notifications page - toasts (epicmaxco#95)
* feat(toasts): toasts form UI * feat(toasts): toasts styles * feat(toasts): vuestic-toasted mixin * feat(toasts): notifications page - sample toast * feat(toasts): notifications page controls bindings * fix(toasts): full-screen mode * fix(toasts): toasts swipe opacity fix * fix(toasts): toasts swipe opacity fix epicmaxco#2 * feat(toasts): fix some styles * feat(toasts): toasts i18n * feat(dashboard): epicmax toast * feat(toasts): disabble epicmax toast
- Loading branch information
1 parent
35aea6b
commit 47b71b0
Showing
12 changed files
with
323 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,94 @@ | ||
<template> | ||
<div class="toast-position-picker"> | ||
<div class="position-boxes-row"> | ||
<div class="position-box" | ||
@click="updatePosition('top-left')" | ||
:class="{'selected': isBoxSelected('top-left')}"> | ||
</div> | ||
<div class="position-box" | ||
@click="updatePosition('top-center')" | ||
:class="{'selected': isBoxSelected('top-center')}"> | ||
</div> | ||
<div class="position-box" | ||
@click="updatePosition('top-right')" | ||
:class="{'selected': isBoxSelected('top-right')}"> | ||
</div> | ||
</div> | ||
<div class="position-boxes-row"> | ||
<div class="position-box" | ||
@click="updatePosition('bottom-left')" | ||
:class="{'selected': isBoxSelected('bottom-left')}"> | ||
</div> | ||
<div class="position-box" | ||
@click="updatePosition('bottom-center')" | ||
:class="{'selected': isBoxSelected('bottom-center')}"> | ||
</div> | ||
<div class="position-box" | ||
@click="updatePosition('bottom-right')" | ||
:class="{'selected': isBoxSelected('bottom-right')}"> | ||
</div> | ||
</div> | ||
</div> | ||
</template> | ||
|
||
<script> | ||
export default { | ||
name: 'toast-position-picker', | ||
props: { | ||
value: { | ||
type: String, | ||
default: 'bottom-center' | ||
} | ||
}, | ||
methods: { | ||
updatePosition (position) { | ||
this.$emit('input', position) | ||
}, | ||
isBoxSelected (position) { | ||
return this.value === position | ||
} | ||
} | ||
} | ||
</script> | ||
|
||
<style lang='scss' scoped> | ||
@import '../../../sass/_variables.scss'; | ||
.toast-position-picker { | ||
width: 112px; | ||
height: 76px; | ||
} | ||
.position-boxes-row { | ||
display: flex; | ||
flex-direction: row; | ||
&:first-child { | ||
margin-bottom: 2px; | ||
} | ||
} | ||
.position-box { | ||
height: 36px; | ||
width: 36px; | ||
margin-right: 2px; | ||
cursor: pointer; | ||
background-color: $brand-primary; | ||
opacity: 0.3; | ||
&:last-child { | ||
margin-right: 0; | ||
} | ||
&:hover { | ||
opacity: 0.6; | ||
} | ||
&.selected { | ||
opacity: 1; | ||
} | ||
} | ||
</style> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.