Skip to content

Next

  • Projects
  • Groups
  • Snippets
  • Help
  • Sign in / Register
Minds Backend - Engine
Minds Backend - Engine
  • Project
  • Repository
  • Issues 290
  • Merge Requests 38
  • CI / CD
  • Security & Compliance
  • Packages
  • Wiki
  • Snippets
  • Members
  • Collapse sidebar
  • Graph
  • Charts
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
  • Minds
  • Minds Backend - EngineMinds Backend - Engine
  • Merge Requests
  • !386

Merged
Opened 6 days ago by Ben Hayward@benhayward.ben
Report abuse

[Sprint/QuietQuail](fix): GIF resize and cropping.

Closes #907 (closed)

Summary

On production, if you upload a gif as your avatar, 2 things:

  1. The resize is broken. If you take the image URL and change between large and small, there is no difference.
  2. The GIF will not be cropped, so if it's wide or long, it will be malformed in older areas like "create new blog".
  3. The GIF will likely appear as a quite a glitchy still-frame. (it should be a still-frame but not glitchy)
Prod

image

Testing

Firstly, I recommend you grab a testing gif. I used the following.

longishgif

Try setting that as your avatar on production to see the issue, also head over to 'Create Blog' which is an older page that does not have front-end validation to stop the image from covering an extra-wide space.

For testing, try it on a sandbox, check all the places your avatar will be. Post it a few places and make sure the gif isn't messed with and image files can all still be uploaded fine around the site. I could not find any outliers where this did not cover it.

Sandbox

image

Request to merge fix/gif-resize into master
Pipeline #92580689 passed for 357e54c4 on fix/gif-resize
          Merge request approved. Approved by
          Xander Miller
          Xander Miller
          Mark Harding
          Mark Harding
          Rami Albatal
          Rami Albatal
          Emiliano Balbuena
          Emiliano Balbuena
          Marcelo Rivera
          Marcelo Rivera
          Olivia Madrid
          Olivia Madrid
          Martin Santangelo
          Martin Santangelo

          Merged by Mark Harding 34 minutes ago

          The changes were merged into master with af77626a

          The source branch has been deleted

          Closed #907 (closed)

          Pipeline #93845010 waiting for manual action for af77626a on master
                        • Discussion 4
                        • Commits 4
                        • Pipelines 3
                        • Changes 1
                        • Ben Hayward @benhayward.ben added MR::Awaiting Review Squad::Yellow scoped labels 6 days ago

                          added scoped labels

                        • Ben Hayward
                          Ben Hayward @benhayward.ben · 6 days ago
                          Developer

                          Because the sizes were broken on prod, I think the blog section is using a small image when it should be using a medium. This might require a quick change in addition to this to sharpen it.

                        • Ben Hayward @benhayward.ben added 1 commit 6 days ago

                          added 1 commit

                          • 357e54c4 - Linted

                          Compare with previous version

                        • Mark Harding @markeharding added MR::Ready to Merge scoped label and automatically removed MR::Awaiting Review label 6 hours ago

                          added scoped label and automatically removed label

                        • Mark Harding
                          Mark Harding @markeharding · 6 hours ago
                          Owner

                          @xander-miller please give approval when a happy

                        • Mark Harding @markeharding approved this merge request 6 hours ago

                          approved this merge request

                        • Mark Harding @markeharding assigned to @xander-miller 6 hours ago

                          assigned to @xander-miller

                        • Xander Miller
                          Xander Miller @xander-miller · 1 hour ago
                          Developer

                          I used my own gif image. :kissing_cat:

                          mua

                          Requirements need a bit more clarification.

                          • Gif is correctly resized.
                          • Gif is correctly cropped.

                          image

                          However, on hard refresh gif is not animated and while avatar on old posts updates, old comments continue to use previous avatar.

                          image

                          It meets the criteria set out in the issue but we should know if old comment avatars should update and whether we permit animated avatars.

                        • Xander Miller
                          Xander Miller @xander-miller · 1 hour ago
                          Developer
                          1. Animated avatars are not allowed.
                          2. Comment avatar is avatar when comment created while post avatar is the current channel avatar. This will be addressed in front!628
                        • Xander Miller @xander-miller approved this merge request 1 hour ago

                          approved this merge request

                        • Mark Harding @markeharding mentioned in commit af77626a 34 minutes ago

                          mentioned in commit af77626a

                        • Mark Harding @markeharding merged 34 minutes ago

                          merged

                        Please register or sign in to reply
                        Assignee
                        Xander Miller's avatar
                        Xander Miller @xander-miller
                        None
                        Milestone
                        None
                        Time tracking
                        No estimate or time spent
                        2
                        Labels
                        MR::Ready to Merge Squad::Yellow
                        Lock merge request
                        Unlocked
                        10
                        10 participants
                        user avatar
                        Rami Albatal
                        user avatar
                        Emiliano Balbuena
                        user avatar
                        Marcelo Rivera
                        user avatar
                        Olivia Madrid
                        user avatar
                        Martin Santangelo
                        user avatar
                        Guy Thouret
                        user avatar
                        Brian Hatchet
                        Reference: minds/engine!386