aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/App.scss4
-rw-r--r--src/components/follow_list/follow_list.js4
-rw-r--r--src/components/follow_list/follow_list.vue3
-rw-r--r--src/components/settings/settings.js3
-rw-r--r--src/components/settings/settings.vue2
-rw-r--r--src/components/status/status.vue2
-rw-r--r--src/components/user_card/user_card.js7
-rw-r--r--src/components/user_card/user_card.vue102
-rw-r--r--src/components/user_card_content/user_card_content.vue2
-rw-r--r--src/i18n/en.json2
-rw-r--r--src/i18n/ja.json28
-rw-r--r--src/services/api/api.service.js2
12 files changed, 101 insertions, 60 deletions
diff --git a/src/App.scss b/src/App.scss
index 52484f59..e7784329 100644
--- a/src/App.scss
+++ b/src/App.scss
@@ -739,3 +739,7 @@ nav {
width: 100%;
}
}
+
+.btn.btn-default {
+ min-height: 28px;
+}
diff --git a/src/components/follow_list/follow_list.js b/src/components/follow_list/follow_list.js
index acdb216d..51327e2f 100644
--- a/src/components/follow_list/follow_list.js
+++ b/src/components/follow_list/follow_list.js
@@ -26,7 +26,9 @@ const FollowList = {
entries () {
return this.showFollowers ? this.user.followers : this.user.friends
},
- showActions () { return this.$store.state.users.currentUser.id === this.userId }
+ showFollowsYou () {
+ return !this.showFollowers || (this.showFollowers && this.userId !== this.$store.state.users.currentUser.id)
+ }
},
methods: {
fetchEntries () {
diff --git a/src/components/follow_list/follow_list.vue b/src/components/follow_list/follow_list.vue
index 7be2e7b7..27102edf 100644
--- a/src/components/follow_list/follow_list.vue
+++ b/src/components/follow_list/follow_list.vue
@@ -3,8 +3,7 @@
<user-card
v-for="entry in entries"
:key="entry.id" :user="entry"
- :showFollows="!showFollowers"
- :showActions="showActions"
+ :noFollowsYou="!showFollowsYou"
/>
<div class="text-center panel-footer">
<a v-if="error" @click="fetchEntries" class="alert error">
diff --git a/src/components/settings/settings.js b/src/components/settings/settings.js
index 534a9839..23c1acdb 100644
--- a/src/components/settings/settings.js
+++ b/src/components/settings/settings.js
@@ -91,7 +91,8 @@ const settings = {
},
currentSaveStateNotice () {
return this.$store.state.interface.settings.currentSaveStateNotice
- }
+ },
+ instanceSpecificPanelPresent () { return this.$store.state.instance.showInstanceSpecificPanel }
},
watch: {
hideAttachmentsLocal (value) {
diff --git a/src/components/settings/settings.vue b/src/components/settings/settings.vue
index 91232382..f5e00995 100644
--- a/src/components/settings/settings.vue
+++ b/src/components/settings/settings.vue
@@ -27,7 +27,7 @@
<li>
<interface-language-switcher />
</li>
- <li>
+ <li v-if="instanceSpecificPanelPresent">
<input type="checkbox" id="hideISP" v-model="hideISPLocal">
<label for="hideISP">{{$t('settings.hide_isp')}}</label>
</li>
diff --git a/src/components/status/status.vue b/src/components/status/status.vue
index aae365d1..3fc5b486 100644
--- a/src/components/status/status.vue
+++ b/src/components/status/status.vue
@@ -554,7 +554,7 @@ a.unmute {
.timeline > {
.status-el:last-child {
- border-bottom-radius: 0 0 $fallback--panelRadius $fallback--panelRadius;;
+ border-radius: 0 0 $fallback--panelRadius $fallback--panelRadius;
border-radius: 0 0 var(--panelRadius, $fallback--panelRadius) var(--panelRadius, $fallback--panelRadius);
border-bottom: none;
}
diff --git a/src/components/user_card/user_card.js b/src/components/user_card/user_card.js
index a4c84716..28e22f09 100644
--- a/src/components/user_card/user_card.js
+++ b/src/components/user_card/user_card.js
@@ -6,9 +6,8 @@ import { requestFollow, requestUnfollow } from '../../services/follow_manipulate
const UserCard = {
props: [
'user',
- 'showFollows',
- 'showApproval',
- 'showActions'
+ 'noFollowsYou',
+ 'showApproval'
],
data () {
return {
@@ -26,7 +25,7 @@ const UserCard = {
currentUser () { return this.$store.state.users.currentUser },
following () { return this.updated ? this.updated.following : this.user.following },
showFollow () {
- return this.showActions && (!this.showFollows && !this.following || this.updated && !this.updated.following)
+ return !this.showApproval && (!this.following || this.updated && !this.updated.following)
}
},
methods: {
diff --git a/src/components/user_card/user_card.vue b/src/components/user_card/user_card.vue
index 12960c02..ce4edb3c 100644
--- a/src/components/user_card/user_card.vue
+++ b/src/components/user_card/user_card.vue
@@ -1,27 +1,31 @@
<template>
<div class="card">
<router-link :to="userProfileLink(user)">
- <UserAvatar class="avatar" :compact="true" @click.prevent.native="toggleUserExpanded" :src="user.profile_image_url"/>
+ <UserAvatar class="avatar" @click.prevent.native="toggleUserExpanded" :src="user.profile_image_url"/>
</router-link>
- <div class="usercard" v-if="userExpanded">
- <user-card-content :user="user" :switcher="false"></user-card-content>
- </div>
- <div class="name-and-screen-name" v-else>
- <div :title="user.name" class="user-name">
- <span v-if="user.name_html" v-html="user.name_html"></span>
- <span v-else>{{ user.name }}</span>
- <span class="follows-you" v-if="!userExpanded && showFollows && user.follows_you">
+ <div class="user-card-main-content">
+ <div class="usercard" v-if="userExpanded">
+ <user-card-content :user="user" :switcher="false"></user-card-content>
+ </div>
+ <div class="name-and-screen-name" v-if="!userExpanded">
+ <div :title="user.name" class="user-name">
+ <span v-if="user.name_html" v-html="user.name_html"></span>
+ <span v-else>{{ user.name }}</span>
+ </div>
+ <div class="user-link-action">
+ <router-link class='user-screen-name' :to="userProfileLink(user)">
+ @{{user.screen_name}}
+ </router-link>
+ </div>
+ </div>
+ <div class="follow-box" v-if="!userExpanded">
+ <span class="faint" v-if="!noFollowsYou && user.follows_you">
{{ currentUser.id == user.id ? $t('user_card.its_you') : $t('user_card.follows_you') }}
</span>
- </div>
- <div class="user-link-action">
- <router-link class='user-screen-name' :to="userProfileLink(user)">
- @{{user.screen_name}}
- </router-link>
- <button
- v-if="showFollow"
- class="btn btn-default"
- @click="followUser"
+ <button
+ v-if="showFollow"
+ class="btn btn-default"
+ @click="followUser"
:disabled="followRequestInProgress"
:title="followRequestSent ? $t('user_card.follow_again') : ''"
>
@@ -35,7 +39,7 @@
{{ $t('user_card.follow') }}
</template>
</button>
- <button v-if="showActions && showFollows && following" class="btn btn-default" @click="unfollowUser" :disabled="followRequestInProgress">
+ <button v-if="following" class="btn btn-default pressed" @click="unfollowUser" :disabled="followRequestInProgress">
<template v-if="followRequestInProgress">
{{ $t('user_card.follow_progress') }}
</template>
@@ -44,10 +48,10 @@
</template>
</button>
</div>
- </div>
- <div class="approval" v-if="showApproval">
- <button class="btn btn-default" @click="approveUser">{{ $t('user_card.approve') }}</button>
- <button class="btn btn-default" @click="denyUser">{{ $t('user_card.deny') }}</button>
+ <div class="approval" v-if="showApproval">
+ <button class="btn btn-default" @click="approveUser">{{ $t('user_card.approve') }}</button>
+ <button class="btn btn-default" @click="denyUser">{{ $t('user_card.deny') }}</button>
+ </div>
</div>
</div>
</template>
@@ -57,15 +61,19 @@
<style lang="scss">
@import '../../_variables.scss';
-.name-and-screen-name {
+.user-card-main-content {
+ display: flex;
+ flex-direction: column;
+ flex: 1 1 100%;
margin-left: 0.7em;
- margin-top:0.0em;
+ min-width: 0;
+}
+
+.name-and-screen-name {
text-align: left;
width: 100%;
- .user-name {
- display: flex;
- justify-content: space-between;
+ .user-name {
img {
object-fit: contain;
height: 16px;
@@ -73,21 +81,14 @@
vertical-align: middle;
}
}
-
+
.user-link-action {
display: flex;
align-items: flex-start;
justify-content: space-between;
-
- button {
- margin-top: 3px;
- }
}
}
-.follows-you {
- margin-left: 2em;
-}
.card {
display: flex;
@@ -99,16 +100,31 @@
border-bottom: 1px solid;
margin: 0;
border-bottom-color: $fallback--border;
- border-bottom-color: var(--border, $fallback--border);
+ border-bottom-color: var(--border, $fallback--border);
.avatar {
padding: 0;
}
+
+ .follow-box {
+ text-align: center;
+ flex-shrink: 0;
+ display: flex;
+ flex-direction: row;
+ justify-content: space-between;
+ flex-wrap: wrap;
+ line-height: 1.5em;
+
+ .btn {
+ margin-top: 0.5em;
+ margin-left: auto;
+ width: 10em;
+ }
+ }
}
.usercard {
width: fill-available;
- margin: 0.2em 0 0 0.7em;
border-radius: $fallback--panelRadius;
border-radius: var(--panelRadius, $fallback--panelRadius);
border-style: solid;
@@ -129,9 +145,15 @@
}
.approval {
+ display: flex;
+ flex-direction: row;
+ flex-wrap: wrap;
button {
- width: 100%;
- margin-bottom: 0.5em;
+ margin-top: 0.5em;
+ margin-right: 0.5em;
+ flex: 1 1;
+ max-width: 12em;
+ min-width: 8em;
}
}
</style>
diff --git a/src/components/user_card_content/user_card_content.vue b/src/components/user_card_content/user_card_content.vue
index 7f9909c4..4d1950c5 100644
--- a/src/components/user_card_content/user_card_content.vue
+++ b/src/components/user_card_content/user_card_content.vue
@@ -386,6 +386,4 @@
}
}
-.floater {
-}
</style>
diff --git a/src/i18n/en.json b/src/i18n/en.json
index af62acfc..2067e6db 100644
--- a/src/i18n/en.json
+++ b/src/i18n/en.json
@@ -350,7 +350,7 @@
"follow_sent": "Request sent!",
"follow_progress": "Requesting…",
"follow_again": "Send request again?",
- "follow_unfollow": "Stop following",
+ "follow_unfollow": "Unfollow",
"followees": "Following",
"followers": "Followers",
"following": "Following!",
diff --git a/src/i18n/ja.json b/src/i18n/ja.json
index afce03a4..7849aa20 100644
--- a/src/i18n/ja.json
+++ b/src/i18n/ja.json
@@ -17,7 +17,9 @@
},
"general": {
"apply": "てきよう",
- "submit": "そうしん"
+ "submit": "そうしん",
+ "more": "つづき",
+ "generic_error": "エラーになりました"
},
"login": {
"login": "ログイン",
@@ -26,7 +28,8 @@
"password": "パスワード",
"placeholder": "れい: lain",
"register": "はじめる",
- "username": "ユーザーめい"
+ "username": "ユーザーめい",
+ "hint": "はなしあいにくわわるには、ログインしてください"
},
"nav": {
"about": "これはなに?",
@@ -49,7 +52,8 @@
"load_older": "ふるいつうちをみる",
"notifications": "つうち",
"read": "よんだ!",
- "repeated_you": "あなたのステータスがリピートされました"
+ "repeated_you": "あなたのステータスがリピートされました",
+ "no_more_notifications": "つうちはありません"
},
"post_status": {
"new_status": "とうこうする",
@@ -117,6 +121,7 @@
"delete_account_description": "あなたのアカウントとメッセージが、きえます。",
"delete_account_error": "アカウントをけすことが、できなかったかもしれません。インスタンスのかんりしゃに、れんらくしてください。",
"delete_account_instructions": "ほんとうにアカウントをけしてもいいなら、パスワードをかいてください。",
+ "avatar_size_instruction": "アバターのおおきさは、150×150ピクセルか、それよりもおおきくするといいです。",
"export_theme": "セーブ",
"filtering": "フィルタリング",
"filtering_explanation": "これらのことばをふくむすべてのものがミュートされます。1ぎょうに1つのことばをかいてください。",
@@ -132,8 +137,10 @@
"hide_attachments_in_tl": "タイムラインのファイルをかくす",
"hide_isp": "インスタンススペシフィックパネルをかくす",
"preload_images": "がぞうをさきよみする",
+ "use_one_click_nsfw": "NSFWなファイルを1クリックでひらく",
"hide_post_stats": "とうこうのとうけいをかくす (れい: おきにいりのかず)",
"hide_user_stats": "ユーザーのとうけいをかくす (れい: フォロワーのかず)",
+ "hide_filtered_statuses": "フィルターされたとうこうをかくす",
"import_followers_from_a_csv_file": "CSVファイルからフォローをインポートする",
"import_theme": "ロード",
"inputRadius": "インプットフィールド",
@@ -148,6 +155,8 @@
"lock_account_description": "あなたがみとめたひとだけ、あなたのアカウントをフォローできる",
"loop_video": "ビデオをくりかえす",
"loop_video_silent_only": "おとのないビデオだけくりかえす",
+ "play_videos_in_modal": "ビデオをメディアビューアーでみる",
+ "use_contain_fit": "がぞうのサムネイルを、きりぬかない",
"name": "なまえ",
"name_bio": "なまえとプロフィール",
"new_password": "あたらしいパスワード",
@@ -157,8 +166,10 @@
"notification_visibility_mentions": "メンション",
"notification_visibility_repeats": "リピート",
"no_rich_text_description": "リッチテキストをつかわない",
- "hide_follows_description": "フォローしている人を表示しない",
- "hide_followers_description": "フォローしている人を表示しない",
+ "hide_follows_description": "フォローしているひとをみせない",
+ "hide_followers_description": "フォロワーをみせない",
+ "show_admin_badge": "アドミンのしるしをみる",
+ "show_moderator_badge": "モデレーターのしるしをみる",
"nsfw_clickthrough": "NSFWなファイルをかくす",
"panelRadius": "パネル",
"pause_on_unfocused": "タブにフォーカスがないときストリーミングをとめる",
@@ -185,6 +196,8 @@
"subject_line_email": "メールふう: \"re: サブジェクト\"",
"subject_line_mastodon": "マストドンふう: そのままコピー",
"subject_line_noop": "コピーしない",
+ "post_status_content_type": "とうこうのコンテントタイプ",
+ "status_content_type_plain": "プレーンテキスト",
"stop_gifs": "カーソルをかさねたとき、GIFをうごかす",
"streaming": "うえまでスクロールしたとき、じどうてきにストリーミングする",
"text": "もじ",
@@ -318,13 +331,15 @@
"no_retweet_hint": "とうこうを「フォロワーのみ」または「ダイレクト」にすると、リピートできなくなります",
"repeated": "リピート",
"show_new": "よみこみ",
- "up_to_date": "さいしん"
+ "up_to_date": "さいしん",
+ "no_more_statuses": "これでおわりです"
},
"user_card": {
"approve": "うけいれ",
"block": "ブロック",
"blocked": "ブロックしています!",
"deny": "おことわり",
+ "favorites": "おきにいり",
"follow": "フォロー",
"follow_sent": "リクエストを、おくりました!",
"follow_progress": "リクエストしています…",
@@ -335,6 +350,7 @@
"following": "フォローしています!",
"follows_you": "フォローされました!",
"its_you": "これはあなたです!",
+ "media": "メディア",
"mute": "ミュート",
"muted": "ミュートしています!",
"per_day": "/日",
diff --git a/src/services/api/api.service.js b/src/services/api/api.service.js
index 92daa04e..13d31d91 100644
--- a/src/services/api/api.service.js
+++ b/src/services/api/api.service.js
@@ -258,7 +258,7 @@ const fetchFriends = ({id, page, credentials}) => {
}
const exportFriends = ({id, credentials}) => {
- let url = `${FRIENDS_URL}?user_id=${id}&export=true`
+ let url = `${FRIENDS_URL}?user_id=${id}&all=true`
return fetch(url, { headers: authHeaders(credentials) })
.then((data) => data.json())
.then((data) => data.map(parseUser))