From 21111878bec750c936e5791dc34dc46060412ecb Mon Sep 17 00:00:00 2001
From: shpuld <shpuld@gmail.com>
Date: Fri, 10 Mar 2017 23:28:55 +0200
Subject: Give link attachments a rounded border, give images and links base03
 border.

---
 src/components/attachment/attachment.vue | 19 +++++++++----------
 1 file changed, 9 insertions(+), 10 deletions(-)

(limited to 'src/components/attachment/attachment.vue')

diff --git a/src/components/attachment/attachment.vue b/src/components/attachment/attachment.vue
index 8f51b891..6af23391 100644
--- a/src/components/attachment/attachment.vue
+++ b/src/components/attachment/attachment.vue
@@ -1,5 +1,5 @@
 <template>
-  <div class="attachment" :class="{[type]: true, loading}" :style="autoHeight">
+  <div class="attachment base03-border" :class="{[type]: true, loading}" :style="autoHeight">
     <a class="image-attachment" v-if="hidden" @click.prevent="toggleHidden()">
       <img :key="nsfwImage" :src="nsfwImage"/>
     </a>
@@ -8,7 +8,7 @@
     </div>
 
     <a v-if="type === 'image' && !hidden" class="image-attachment" :href="attachment.url" target="_blank">
-      <img class="base05-border" referrerpolicy="no-referrer" :src="attachment.large_thumb_url || attachment.url"/>
+      <img class="base03-border" referrerpolicy="no-referrer" :src="attachment.large_thumb_url || attachment.url"/>
     </a>
 
     <video v-if="type === 'video' && !hidden" :src="attachment.url" controls></video>
@@ -76,19 +76,18 @@
               border-radius: 5px;
           }
 
-
           .oembed {
+              border: 1px solid;
+              border-radius: 5px;
+              border-color: inherit;
+              width: 100%;
+              margin-right: 15px;
+              display: flex;
+
               img {
                   width: 100%;
               }
-              margin-right: 15px;
-          }
 
-          .oembed {
-              border: 1px solid;
-              width: 100%;
-
-              display: flex;
               .image {
                   flex: 1;
                   img {
-- 
cgit v1.2.3-70-g09d2


From 05dfd9657138f9cff555a65e76c67ecac0864af0 Mon Sep 17 00:00:00 2001
From: Shpuld Shpuldson <shpuld@gmail.com>
Date: Sun, 9 Apr 2017 14:28:21 +0300
Subject: Revert nsfw image sizing, give attachments max-height to reduce
 scrolling

---
 src/components/attachment/attachment.js  | 2 +-
 src/components/attachment/attachment.vue | 4 +++-
 2 files changed, 4 insertions(+), 2 deletions(-)

(limited to 'src/components/attachment/attachment.vue')

diff --git a/src/components/attachment/attachment.js b/src/components/attachment/attachment.js
index 7715add5..ccf26b79 100644
--- a/src/components/attachment/attachment.js
+++ b/src/components/attachment/attachment.js
@@ -26,7 +26,7 @@ const Attachment = {
     autoHeight () {
       if (this.type === 'image' && this.nsfw) {
         return {
-          'min-height': '311px'
+          'min-height': '109px'
         }
       }
     }
diff --git a/src/components/attachment/attachment.vue b/src/components/attachment/attachment.vue
index 6af23391..e2fc65ba 100644
--- a/src/components/attachment/attachment.vue
+++ b/src/components/attachment/attachment.vue
@@ -116,8 +116,10 @@
                   border-style: solid;
                   border-width: 1px;
                   border-radius: 5px;
+                  object-fit: contain;
                   width: 100%;
-                  height: 100%; /* If this isn't here, chrome will stretch the images */
+                  //height: 100%; /* If this isn't here, chrome will stretch the images */
+                  max-height: 500px;
               }
           }
       }
-- 
cgit v1.2.3-70-g09d2


From f3ca011fbedb2ce6271bcc887d290828ccd1d284 Mon Sep 17 00:00:00 2001
From: lambadalambda <gitgud@rogerbraun.net>
Date: Sun, 9 Apr 2017 08:26:30 -0400
Subject: Add chrome picture stretching fix back in.

---
 src/components/attachment/attachment.vue | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

(limited to 'src/components/attachment/attachment.vue')

diff --git a/src/components/attachment/attachment.vue b/src/components/attachment/attachment.vue
index e2fc65ba..1ba1c02a 100644
--- a/src/components/attachment/attachment.vue
+++ b/src/components/attachment/attachment.vue
@@ -118,7 +118,7 @@
                   border-radius: 5px;
                   object-fit: contain;
                   width: 100%;
-                  //height: 100%; /* If this isn't here, chrome will stretch the images */
+                  height: 100%; /* If this isn't here, chrome will stretch the images */
                   max-height: 500px;
               }
           }
-- 
cgit v1.2.3-70-g09d2

