From 9f477549ddbf6bf5b892df993fd44f8e1cf0f2bc Mon Sep 17 00:00:00 2001 From: syuilo Date: Wed, 30 Aug 2017 01:37:33 +0900 Subject: [PATCH] :v: --- CHANGELOG.md | 6 +- locales/en.yml | 14 ++ locales/ja.yml | 14 ++ src/web/app/mobile/router.js | 2 +- src/web/app/mobile/tags/user.tag | 260 ++++++++++++++++++++++++++++++- 5 files changed, 291 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index c42008de5..6b6c80bf7 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,8 +2,12 @@ ChangeLog (Release Notes) ========================= 主に notable な changes を書いていきます -2498 (2017/08/29) +unreleased ---------- +* New: モバイルのユーザーページを刷新 + +2498 (2017/08/29) +----------------- * Fix: repostのborder-radiusが効いていない (#743) * テーマカラーを赤に戻してみた * ユーザビリティの向上 diff --git a/locales/en.yml b/locales/en.yml index 5e11339db..231fc640e 100644 --- a/locales/en.yml +++ b/locales/en.yml @@ -472,9 +472,23 @@ mobile: is-followed: "Followed you" following: "Following" followers: "Followers" + overview: "Overview" posts: "Timeline" media: "Media" + mk-user-overview: + recent-posts: "Recent posts" + images: "Images" + activity: "Activity" + + mk-user-overview-posts: + loading: "Loading" + no-posts: "No posts" + + mk-user-overview-photos: + loading: "Loading" + no-photos: "No photos" + mk-users-list: all: "All" known: "You know" diff --git a/locales/ja.yml b/locales/ja.yml index 62ac4cb81..651f529fb 100644 --- a/locales/ja.yml +++ b/locales/ja.yml @@ -472,10 +472,24 @@ mobile: is-followed: "フォローされています" following: "フォロー" followers: "フォロワー" + overview: "概要" posts: "タイムライン" posts-count: "ポスト" media: "メディア" + mk-user-overview: + recent-posts: "最近の投稿" + images: "画像" + activity: "アクティビティ" + + mk-user-overview-posts: + loading: "読み込み中" + no-posts: "投稿はありません" + + mk-user-overview-photos: + loading: "読み込み中" + no-photos: "写真はありません" + mk-users-list: all: "すべて" known: "知り合い" diff --git a/src/web/app/mobile/router.js b/src/web/app/mobile/router.js index de4108a59..d59b2ec3a 100644 --- a/src/web/app/mobile/router.js +++ b/src/web/app/mobile/router.js @@ -23,7 +23,7 @@ export default me => { route('/post/new', newPost); route('/post::post', post); route('/search::query', search); - route('/:user', user.bind(null, 'posts')); + route('/:user', user.bind(null, 'overview')); route('/:user/graphs', user.bind(null, 'graphs')); route('/:user/followers', userFollowers); route('/:user/following', userFollowing); diff --git a/src/web/app/mobile/tags/user.tag b/src/web/app/mobile/tags/user.tag index fbf2f690a..7d8895784 100644 --- a/src/web/app/mobile/tags/user.tag +++ b/src/web/app/mobile/tags/user.tag @@ -37,14 +37,15 @@ %i18n:mobile.tags.mk-user.followers% -
+
@@ -55,6 +56,8 @@ > .user > header + box-shadow 0 4px 4px rgba(0, 0, 0, 0.3) + > .banner padding-bottom 33.3% background-color #1b1b1b @@ -159,7 +162,6 @@ justify-content center margin 0 auto max-width 600px - border-bottom solid 1px rgba(0, 0, 0, 0.2) > a display block @@ -190,7 +192,7 @@ this.mixin('api'); this.username = this.opts.user; - this.page = this.opts.page ? this.opts.page : 'posts'; + this.page = this.opts.page ? this.opts.page : 'overview'; this.fetching = true; this.on('mount', () => { @@ -211,3 +213,255 @@ }; + + +
+

%i18n:mobile.tags.mk-user-overview.recent-posts%

+
+ +
+
+
+

%i18n:mobile.tags.mk-user-overview.images%

+
+ +
+
+
+

%i18n:mobile.tags.mk-user-overview.activity%

+
+ +
+
+ + +
+ + +

%i18n:mobile.tags.mk-user-overview-posts.loading%

+
0 }> + + + +
+

%i18n:mobile.tags.mk-user-overview-posts.no-posts%

+ + +
+ + + +
+ avatar

{ post.user.name }

+
+
+ { text } +
+ +
+ + +
+ + +

%i18n:mobile.tags.mk-user-overview-photos.loading%

+
0 }> + + + +
+

%i18n:mobile.tags.mk-user-overview-photos.no-photos%

+ + +