Skip to content

Commit

Permalink
Scale image on x if img x <= 210. (mozilla-services#3728)
Browse files Browse the repository at this point in the history
  • Loading branch information
chenba committed Nov 22, 2017
1 parent 2a3c0a5 commit 72d0637
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions server/src/pages/shotindex/view.js
Original file line number Diff line number Diff line change
Expand Up @@ -336,10 +336,10 @@ class Card extends React.Component {
}

getClipType(dimensions) {
if ((dimensions.x / dimensions.y) > (3 / 4)) {
return "landscape";
if ((dimensions.x / dimensions.y) <= (3 / 4) || dimensions.x <= 210) {
return "portrait";
}
return "portrait";
return "landscape";
}

setPanelState(state) {
Expand Down

0 comments on commit 72d0637

Please # to comment.