Skip to content

Commit

Permalink
🩹 (#2345): use nextcloud button instead of html button
Browse files Browse the repository at this point in the history
Signed-off-by: Vinicius Reis <vinicius.reis@nextcloud.com>
  • Loading branch information
Vinicius Reis committed May 31, 2022
1 parent 4ad919a commit 6345231
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 5 deletions.
11 changes: 9 additions & 2 deletions src/components/Menu/ActionEntry.scss
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
border-radius: 100%;
position: absolute;
background: var(--color-primary-element);
bottom: 3px;
bottom: 0;
height: 6px;
width: 6px;
content: '';
Expand All @@ -19,11 +19,12 @@
height: 44px;
margin: 0;
border: 0;
opacity: 0.5;
// opacity: 0.5;
position: relative;
color: var(--color-main-text);
background-color: transparent;
vertical-align: top;
box-shadow: none;
padding: 0;

p {
Expand All @@ -42,12 +43,18 @@
&:focus,
&:active {
background-color: var(--color-background-dark);
&:not(:disabled) {
box-shadow: var(--color-primary);
}
}

&:hover,
&:focus {
opacity: 1;
}
&:focus-visible {
box-shadow: var(--color-primary);
}

&.is-active {
@extend %text__is-active-item-btn;
Expand Down
10 changes: 7 additions & 3 deletions src/components/Menu/EmojiPickerAction.vue
Original file line number Diff line number Diff line change
Expand Up @@ -23,24 +23,28 @@
<EmojiPicker class="entry-action entry-action__emoji"
:data-text-action-entry="actionEntry.key"
@selectData="addEmoji">
<button v-tooltip="actionEntry.label"
<Button v-tooltip="actionEntry.label"
class="entry-action__button"
:title="actionEntry.label"
:aria-label="actionEntry.label"
:aria-haspopup="true">
<component :is="icon" />
</button>
<template #icon>
<component :is="icon" />
</template>
</Button>
</EmojiPicker>
</template>

<script>
import { BaseActionEntry } from './BaseActionEntry.js'
import EmojiPicker from '@nextcloud/vue/dist/Components/EmojiPicker'
import Button from '@nextcloud/vue/dist/Components/Button'

export default {
name: 'EmojiPickerAction',
components: {
EmojiPicker,
Button,
},
extends: BaseActionEntry,
methods: {
Expand Down

0 comments on commit 6345231

Please sign in to comment.