aboutsummaryrefslogtreecommitdiffstats
path: root/apps
diff options
context:
space:
mode:
authorFerdinand Thiessen <opensource@fthiessen.de>2024-06-13 18:13:45 +0200
committerJohn Molakvoæ <skjnldsv@users.noreply.github.com>2024-06-14 11:02:27 +0200
commitfab4542b57331df633bd697feb872cd2548d7be0 (patch)
tree76ca2bfb7b16caed784d8fe9f76a06781fbfa1d2 /apps
parent3187425ca5ad83f1a4bff80246d6a57dbdf67f09 (diff)
downloadnextcloud-server-fab4542b57331df633bd697feb872cd2548d7be0.tar.gz
nextcloud-server-fab4542b57331df633bd697feb872cd2548d7be0.zip
fix(comments): Use proper icon components instead of icon classes to fix dark mode
Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
Diffstat (limited to 'apps')
-rw-r--r--apps/comments/src/components/Comment.vue29
-rw-r--r--apps/comments/src/views/ActivityCommentEntry.vue3
2 files changed, 21 insertions, 11 deletions
diff --git a/apps/comments/src/components/Comment.vue b/apps/comments/src/components/Comment.vue
index 97e3adea1a4..8fb5bacf4d7 100644
--- a/apps/comments/src/components/Comment.vue
+++ b/apps/comments/src/components/Comment.vue
@@ -40,22 +40,27 @@
show if we have a message id and current user is author -->
<NcActions v-if="isOwnComment && id && !loading" class="comment__actions">
<template v-if="!editing">
- <NcActionButton :close-after-click="true"
- icon="icon-rename"
+ <NcActionButton close-after-click
@click="onEdit">
+ <template #icon>
+ <IconEdit :size="20" />
+ </template>
{{ t('comments', 'Edit comment') }}
</NcActionButton>
<NcActionSeparator />
- <NcActionButton :close-after-click="true"
- icon="icon-delete"
+ <NcActionButton close-after-click
@click="onDeleteWithUndo">
+ <template #icon>
+ <IconDelete :size="20" />
+ </template>
{{ t('comments', 'Delete comment') }}
</NcActionButton>
</template>
- <NcActionButton v-else
- icon="icon-close"
- @click="onEditCancel">
+ <NcActionButton v-else @click="onEditCancel">
+ <template #icon>
+ <IconClose :size="20" />
+ </template>
{{ t('comments', 'Cancel edit') }}
</NcActionButton>
</NcActions>
@@ -87,8 +92,8 @@
:disabled="isEmptyMessage"
@click="onSubmit">
<template #icon>
- <span v-if="loading" class="icon-loading-small" />
- <ArrowRight v-else :size="20" />
+ <NcLoadingIcon v-if="loading" />
+ <IconArrowRight v-else :size="20" />
</template>
</NcButton>
</div>
@@ -122,7 +127,11 @@ import NcActionSeparator from '@nextcloud/vue/dist/Components/NcActionSeparator.
import NcAvatar from '@nextcloud/vue/dist/Components/NcAvatar.js'
import NcButton from '@nextcloud/vue/dist/Components/NcButton.js'
import RichEditorMixin from '@nextcloud/vue/dist/Mixins/richEditor.js'
-import ArrowRight from 'vue-material-design-icons/ArrowRight.vue'
+
+import IconArrowRight from 'vue-material-design-icons/ArrowRight.vue'
+import IconClose from 'vue-material-design-icons/Close.vue'
+import IconDelete from 'vue-material-design-icons/Delete.vue'
+import IconEdit from 'vue-material-design-icons/Pencil.vue'
import Moment from './Moment.vue'
import CommentMixin from '../mixins/CommentMixin.js'
diff --git a/apps/comments/src/views/ActivityCommentEntry.vue b/apps/comments/src/views/ActivityCommentEntry.vue
index 38fc2d5f1ef..55af0d5bc1e 100644
--- a/apps/comments/src/views/ActivityCommentEntry.vue
+++ b/apps/comments/src/views/ActivityCommentEntry.vue
@@ -34,6 +34,7 @@
</template>
<script lang="ts">
+import type { PropType } from 'vue'
import { translate as t } from '@nextcloud/l10n'
import Comment from '../components/Comment.vue'
@@ -53,7 +54,7 @@ export default {
required: true,
},
reloadCallback: {
- type: Function,
+ type: Function as PropType<() => void>,
required: true,
},
},