0
0
Fork 0

Add expand/compress image button on image view box (#15068)

* add zoom image button

* enhance zoom algorithm & add translation

* code structure

* code structure

* code structure

* enhance grab performance

* rm useless state

* fix behavior on Firefox & scroll lock & horizontal scroll with mousewheel

* remove scroll lock on MouseWheelEvent

* code structure

* enhance algorithm and code structure

* rm Gemfile.lock from tree

* codeclimate

* fix a stupid mistake
This commit is contained in:
Mashiro 2020-11-03 04:16:38 +08:00 committed by GitHub
parent 4b2ec4a2dc
commit 6a2db10f76
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
79 changed files with 2029 additions and 23 deletions

View file

@ -1720,6 +1720,20 @@ a.account__display-name {
align-items: center;
justify-content: center;
flex-direction: column;
scrollbar-width: none; /* Firefox */
-ms-overflow-style: none; /* IE 10+ */
* {
scrollbar-width: none; /* Firefox */
-ms-overflow-style: none; /* IE 10+ */
}
&::-webkit-scrollbar,
*::-webkit-scrollbar {
width: 0;
height: 0;
background: transparent; /* Chrome/Safari/Webkit */
}
.image-loader__preview-canvas {
max-width: $media-modal-media-max-width;
@ -4606,6 +4620,21 @@ a.status-card.compact:hover {
z-index: 100;
}
.media-modal__zoom-button {
position: absolute;
right: 64px;
top: 8px;
z-index: 100;
pointer-events: auto;
transition: opacity 0.3s linear;
will-change: opacity;
}
.media-modal__zoom-button--hidden {
pointer-events: none;
opacity: 0;
}
.onboarding-modal,
.error-modal,
.embed-modal {