From 960ed9540d443e0d577d7aefe1918b74343f4e0e Mon Sep 17 00:00:00 2001 From: shpuld Date: Sat, 25 Feb 2017 14:34:05 +0200 Subject: Make use of template literals instead of string concat. --- src/components/user_card_content/user_card_content.vue | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src') diff --git a/src/components/user_card_content/user_card_content.vue b/src/components/user_card_content/user_card_content.vue index a30eadf5..4dc1c6f1 100644 --- a/src/components/user_card_content/user_card_content.vue +++ b/src/components/user_card_content/user_card_content.vue @@ -63,15 +63,15 @@ headingStyle () { let rgb = this.$store.state.config.colors['base00'].match(/\d+/g) return { - backgroundColor: 'rgb(' + Math.floor(rgb[0] * 0.53) + ', ' + - Math.floor(rgb[1] * 0.56) + ', ' + - Math.floor(rgb[2] * 0.59) + ')', + backgroundColor: `rgb(${Math.floor(rgb[0] * 0.53)}, + ${Math.floor(rgb[1] * 0.56)}, + ${Math.floor(rgb[2] * 0.59)})`, backgroundImage: `url(${this.user.cover_photo})` } }, bodyStyle () { return { - background: 'linear-gradient(to bottom, rgba(0, 0, 0, 0), ' + this.$store.state.config.colors['base00'] + ' 80%)' + background: `linear-gradient(to bottom, rgba(0, 0, 0, 0), ${this.$store.state.config.colors['base00']} 80%)` } }, isOtherUser () { -- cgit v1.2.3-70-g09d2 From 8c43b3f505c6bee344a85dc33a927f123062a268 Mon Sep 17 00:00:00 2001 From: shpuld Date: Sun, 26 Feb 2017 22:42:22 +0200 Subject: Remove newlines from template literal. --- src/components/user_card_content/user_card_content.vue | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'src') diff --git a/src/components/user_card_content/user_card_content.vue b/src/components/user_card_content/user_card_content.vue index 4dc1c6f1..6b01133c 100644 --- a/src/components/user_card_content/user_card_content.vue +++ b/src/components/user_card_content/user_card_content.vue @@ -63,9 +63,7 @@ headingStyle () { let rgb = this.$store.state.config.colors['base00'].match(/\d+/g) return { - backgroundColor: `rgb(${Math.floor(rgb[0] * 0.53)}, - ${Math.floor(rgb[1] * 0.56)}, - ${Math.floor(rgb[2] * 0.59)})`, + backgroundColor: `rgb(${Math.floor(rgb[0] * 0.53)}, ${Math.floor(rgb[1] * 0.56)}, ${Math.floor(rgb[2] * 0.59)})`, backgroundImage: `url(${this.user.cover_photo})` } }, -- cgit v1.2.3-70-g09d2 From 4d1183cc1f0909f3d0aa459d1a38b6548bccfba2 Mon Sep 17 00:00:00 2001 From: shpuld Date: Mon, 27 Feb 2017 19:21:40 +0200 Subject: Fix the very visible padding offset in unread notification caused by the border. --- src/components/notifications/notifications.scss | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) (limited to 'src') diff --git a/src/components/notifications/notifications.scss b/src/components/notifications/notifications.scss index 5da6d495..100349eb 100644 --- a/src/components/notifications/notifications.scss +++ b/src/components/notifications/notifications.scss @@ -13,12 +13,12 @@ } } - .unseen { - border-left: 4px solid rgba(255, 48, 16, 0.65); - } - .notification { - padding: 0.4em 0 0 0.7em; + // Will have to use pixels here to ensure consistent distance with + // pad alone and pad + border, browsers bad at rounding this with em, + // they love to give a 1 pixel ghost offset with 0.7em vs 0.3em + 0.4em, + // which does not happen with 10px vs 4px + 6px. + padding: 0.4em 0 0 10px; display: flex; border-bottom: 1px solid silver; @@ -62,4 +62,9 @@ border: none } } + + .unseen { + border-left: 4px solid rgba(255, 48, 16, 0.65); + padding-left: 6px; + } } -- cgit v1.2.3-70-g09d2 From a4c58aab13db901197ec20ef2bc8b79578141b92 Mon Sep 17 00:00:00 2001 From: Roger Braun Date: Wed, 1 Mar 2017 20:36:37 +0100 Subject: Unify notice timelines to make changes easier. --- .../friends_timeline/friends_timeline.vue | 7 +---- src/components/mentions/mentions.vue | 7 +---- .../public_and_external_timeline.vue | 7 +---- src/components/public_timeline/public_timeline.vue | 7 +---- src/components/timeline/timeline.js | 3 +- src/components/timeline/timeline.vue | 35 ++++++++++++---------- 6 files changed, 26 insertions(+), 40 deletions(-) (limited to 'src') diff --git a/src/components/friends_timeline/friends_timeline.vue b/src/components/friends_timeline/friends_timeline.vue index afe5cc89..3bf3b543 100644 --- a/src/components/friends_timeline/friends_timeline.vue +++ b/src/components/friends_timeline/friends_timeline.vue @@ -1,10 +1,5 @@ diff --git a/src/components/mentions/mentions.vue b/src/components/mentions/mentions.vue index 59f00241..7af402ce 100644 --- a/src/components/mentions/mentions.vue +++ b/src/components/mentions/mentions.vue @@ -1,10 +1,5 @@ diff --git a/src/components/public_and_external_timeline/public_and_external_timeline.vue b/src/components/public_and_external_timeline/public_and_external_timeline.vue index bda51153..fd696938 100644 --- a/src/components/public_and_external_timeline/public_and_external_timeline.vue +++ b/src/components/public_and_external_timeline/public_and_external_timeline.vue @@ -1,10 +1,5 @@ diff --git a/src/components/public_timeline/public_timeline.vue b/src/components/public_timeline/public_timeline.vue index d05695b2..bd6a23ed 100644 --- a/src/components/public_timeline/public_timeline.vue +++ b/src/components/public_timeline/public_timeline.vue @@ -1,10 +1,5 @@ diff --git a/src/components/timeline/timeline.js b/src/components/timeline/timeline.js index addd0255..b4e80fe1 100644 --- a/src/components/timeline/timeline.js +++ b/src/components/timeline/timeline.js @@ -5,7 +5,8 @@ import StatusOrConversation from '../status_or_conversation/status_or_conversati const Timeline = { props: [ 'timeline', - 'timelineName' + 'timelineName', + 'title' ], components: { Status, diff --git a/src/components/timeline/timeline.vue b/src/components/timeline/timeline.vue index 45886f6c..15ac5ff8 100644 --- a/src/components/timeline/timeline.vue +++ b/src/components/timeline/timeline.vue @@ -1,20 +1,25 @@ -- cgit v1.2.3-70-g09d2 From 9107facaca414f5f3ea6cf5cb306fb0fa241e1bd Mon Sep 17 00:00:00 2001 From: xj9 Date: Thu, 2 Mar 2017 20:01:19 -0700 Subject: issue #1 - better nsfw image loading preload the image when it is toggled, but wait to replace it until it has loaded. --- .gitignore | 1 + src/components/attachment/attachment.js | 6 +++++- 2 files changed, 6 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/.gitignore b/.gitignore index bc9103de..faf39252 100644 --- a/.gitignore +++ b/.gitignore @@ -5,3 +5,4 @@ npm-debug.log test/unit/coverage test/e2e/reports selenium-debug.log +.idea/ diff --git a/src/components/attachment/attachment.js b/src/components/attachment/attachment.js index f4f6aebf..c3f52f57 100644 --- a/src/components/attachment/attachment.js +++ b/src/components/attachment/attachment.js @@ -29,7 +29,11 @@ const Attachment = { } }, toggleHidden () { - this.showHidden = !this.showHidden + let img = document.createElement('img') + img.src = this.attachment.url + img.onload = () => { + this.showHidden = !this.showHidden + } } } } -- cgit v1.2.3-70-g09d2