summaryrefslogtreecommitdiff
path: root/packages/frontend/src/components/MkReactionsViewer.details.vue
diff options
context:
space:
mode:
authorsyuilo <Syuilotan@yahoo.co.jp>2023-01-14 17:23:49 +0900
committersyuilo <Syuilotan@yahoo.co.jp>2023-01-14 17:23:49 +0900
commitc41879c542f0a1a5c3d5a92d5fbabca61b9b161c (patch)
tree25cfb23909dcb2da6085ba8b028862dc3bd46557 /packages/frontend/src/components/MkReactionsViewer.details.vue
parentUpdate CHANGELOG.md (diff)
downloadmisskey-c41879c542f0a1a5c3d5a92d5fbabca61b9b161c.tar.gz
misskey-c41879c542f0a1a5c3d5a92d5fbabca61b9b161c.tar.bz2
misskey-c41879c542f0a1a5c3d5a92d5fbabca61b9b161c.zip
refactor(client): use css modules
Diffstat (limited to 'packages/frontend/src/components/MkReactionsViewer.details.vue')
-rw-r--r--packages/frontend/src/components/MkReactionsViewer.details.vue98
1 files changed, 49 insertions, 49 deletions
diff --git a/packages/frontend/src/components/MkReactionsViewer.details.vue b/packages/frontend/src/components/MkReactionsViewer.details.vue
index 6ec227b0ed..b4210be911 100644
--- a/packages/frontend/src/components/MkReactionsViewer.details.vue
+++ b/packages/frontend/src/components/MkReactionsViewer.details.vue
@@ -1,16 +1,16 @@
<template>
<MkTooltip ref="tooltip" :showing="showing" :target-element="targetElement" :max-width="340" @closed="emit('closed')">
- <div class="bqxuuuey">
- <div class="reaction">
- <MkReactionIcon :reaction="reaction" class="icon" :no-style="true"/>
- <div class="name">{{ getReactionName(reaction) }}</div>
+ <div :class="$style.root">
+ <div :class="$style.reaction">
+ <MkReactionIcon :reaction="reaction" :class="$style.reactionIcon" :no-style="true"/>
+ <div :class="$style.reactionName">{{ getReactionName(reaction) }}</div>
</div>
- <div class="users">
- <div v-for="u in users" :key="u.id" class="user">
- <MkAvatar class="avatar" :user="u"/>
- <MkUserName class="name" :user="u" :nowrap="true"/>
+ <div :class="$style.users">
+ <div v-for="u in users" :key="u.id" :class="$style.user">
+ <MkAvatar :class="$style.avatar" :user="u"/>
+ <MkUserName :user="u" :nowrap="true"/>
</div>
- <div v-if="users.length > 10" class="omitted">+{{ count - 10 }}</div>
+ <div v-if="users.length > 10">+{{ count - 10 }}</div>
</div>
</div>
</MkTooltip>
@@ -43,53 +43,53 @@ function getReactionName(reaction: string): string {
}
</script>
-<style lang="scss" scoped>
-.bqxuuuey {
+<style lang="scss" module>
+.root {
display: flex;
+}
- > .reaction {
- max-width: 100px;
- text-align: center;
-
- > .icon {
- display: block;
- width: 60px;
- font-size: 60px; // unicodeな絵文字についてはwidthが効かないため
- object-fit: contain;
- margin: 0 auto;
- }
+.reaction {
+ max-width: 100px;
+ text-align: center;
+}
- > .name {
- font-size: 1em;
- }
- }
+.reactionIcon {
+ display: block;
+ width: 60px;
+ font-size: 60px; // unicodeな絵文字についてはwidthが効かないため
+ object-fit: contain;
+ margin: 0 auto;
+}
- > .users {
- flex: 1;
- min-width: 0;
- font-size: 0.95em;
- border-left: solid 0.5px var(--divider);
- padding-left: 10px;
- margin-left: 10px;
- margin-right: 14px;
- text-align: left;
+.reactionName {
+ font-size: 1em;
+}
- > .user {
- line-height: 24px;
- white-space: nowrap;
- overflow: hidden;
- text-overflow: ellipsis;
+.users {
+ flex: 1;
+ min-width: 0;
+ font-size: 0.95em;
+ border-left: solid 0.5px var(--divider);
+ padding-left: 10px;
+ margin-left: 10px;
+ margin-right: 14px;
+ text-align: left;
+}
- &:not(:last-child) {
- margin-bottom: 3px;
- }
+.user {
+ line-height: 24px;
+ white-space: nowrap;
+ overflow: hidden;
+ text-overflow: ellipsis;
- > .avatar {
- width: 24px;
- height: 24px;
- margin-right: 3px;
- }
- }
+ &:not(:last-child) {
+ margin-bottom: 3px;
}
}
+
+.avatar {
+ width: 24px;
+ height: 24px;
+ margin-right: 3px;
+}
</style>