diff --git a/locales/ja-JP.yml b/locales/ja-JP.yml index a073d789a2..ec767aafa9 100644 --- a/locales/ja-JP.yml +++ b/locales/ja-JP.yml @@ -732,6 +732,7 @@ _widgets: activity: "アクティビティ" photos: "フォト" digitalClock: "デジタル時計" + federation: "連合" _cw: hide: "隠す" diff --git a/src/client/components/avatar.vue b/src/client/components/avatar.vue index a116a23182..3a2cc35e38 100644 --- a/src/client/components/avatar.vue +++ b/src/client/components/avatar.vue @@ -40,7 +40,24 @@ export default defineComponent({ : this.user.avatarUrl; }, }, + watch: { + 'user.avatarBlurhash'() { + this.$el.style.color = this.getBlurhashAvgColor(this.user.avatarBlurhash); + } + }, + mounted() { + this.$el.style.color = this.getBlurhashAvgColor(this.user.avatarBlurhash); + }, methods: { + getBlurhashAvgColor(s) { + return typeof s == 'string' + ? '#' + [...s.slice(2, 6)] + .map(x => '0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz#$%*+,-.:;=?@[]^_{|}~'.indexOf(x)) + .reduce((a, c) => a * 83 + c, 0) + .toString(16) + .padStart(6, '0') + : undefined; + }, onClick(e) { this.$emit('click', e); } diff --git a/src/client/components/deck/direct-column.vue b/src/client/components/deck/direct-column.vue index 8a85a69cbd..41471e0c5e 100644 --- a/src/client/components/deck/direct-column.vue +++ b/src/client/components/deck/direct-column.vue @@ -2,20 +2,21 @@ - + diff --git a/src/client/components/deck/mentions-column.vue b/src/client/components/deck/mentions-column.vue index 5c32e83d21..c3961396ec 100644 --- a/src/client/components/deck/mentions-column.vue +++ b/src/client/components/deck/mentions-column.vue @@ -2,20 +2,21 @@ - + diff --git a/src/client/components/note.vue b/src/client/components/note.vue index 284bd25e2f..7f01a4facc 100644 --- a/src/client/components/note.vue +++ b/src/client/components/note.vue @@ -34,19 +34,19 @@
- +

- +

({{ $t('private') }}) - + RN:
diff --git a/src/client/pages/instance/federation.instance.vue b/src/client/pages/instance/federation.instance.vue index eea10ee7b1..cb72b4fd85 100644 --- a/src/client/pages/instance/federation.instance.vue +++ b/src/client/pages/instance/federation.instance.vue @@ -1,5 +1,5 @@