set image max width to avoid overflow (#13211)

squashed and merged
This commit is contained in:
Siddarth Kumar 2022-04-08 21:11:43 +05:30 committed by GitHub
parent 6314038634
commit 2ddf4cf924
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 0 deletions

View File

@ -33,7 +33,9 @@
(let [width (reagent/atom nil)] (let [width (reagent/atom nil)]
(fn [uri show-close?] (fn [uri show-close?]
[react/view {:style {:width @width [react/view {:style {:width @width
:align-items :center
:height image-max-dimension :height image-max-dimension
:max-width :100%
:overflow :hidden :overflow :hidden
:opacity (if @width 1 0) :opacity (if @width 1 0)
:border-radius 16 :border-radius 16