Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Resize preview image and implement zoom in/out #1036

Merged
merged 2 commits into from
May 3, 2023

Conversation

ner00
Copy link
Contributor

@ner00 ner00 commented May 2, 2023

This achieves a similar goal as #1032, which aims at resizing the image to fit the window, while also adding zoom in/out functionality purely in CSS and with minimal changes to the current code.

Note that this change also appears (falsely) to offer zoom functionality to images that by default already fit the window's dimensions, this is because there is no code determining if the image scale was limited or not; I opted to not attempt that at this point because I assumed that it would make the resulting code unnecessarily complex.

Demo

css_resize_zoom_in-out.mp4

@xololunatic
Copy link
Contributor

This is a way much better solution. Developer @prasathmani should add this in the code.

@prasathmani prasathmani merged commit 7ec19c1 into prasathmani:master May 3, 2023
ner00 added a commit to ner00/tinyfilemanager that referenced this pull request May 6, 2023
* Resize preview image and implement zoom in/out

* Remove redundant class name
ner00 added a commit to ner00/tinyfilemanager that referenced this pull request May 6, 2023
* Resize preview image and implement zoom in/out

* Remove redundant class name
ner00 added a commit to ner00/tinyfilemanager that referenced this pull request May 7, 2023
* Resize preview image and implement zoom in/out

* Remove redundant class name
ner00 added a commit to ner00/tinyfilemanager that referenced this pull request May 7, 2023
* Resize preview image and implement zoom in/out

* Remove redundant class name
ner00 added a commit to ner00/tinyfilemanager that referenced this pull request May 7, 2023
* Resize preview image and implement zoom in/out

* Remove redundant class name
ner00 added a commit to ner00/tinyfilemanager that referenced this pull request May 7, 2023
* Resize preview image and implement zoom in/out

* Remove redundant class name
prasathmani added a commit that referenced this pull request May 7, 2023
* publish additional docker tags (#975)

* Update Romanian translations (#981)

* Update tinyfilemanager.php

* Prevent logout issue after page was cached (#1004)

Logout may not work otherwise, browser reloads cached page from disk instead of sending GET request ?logout=1 to server.

* tell git to always commit .php in unix-newlines (#1017)

so hopefully we don't get a repeat of #994 (comment)

* Check if posix_getpwuid/posix_getgrgid calls were successful (#1023)

* use stream_copy_to_stream (#1014)

* use stream_copy_to_stream

it's simpler, and should be faster.
For example, stream_copy_to_stream can use sendfile ( https://man7.org/linux/man-pages/man2/sendfile.2.html ) on operating systems supporting it, which is faster and use less RAM than fread()+fwrite() (because it avoids copying data to/from userland, doing the copy entirely in-kernel~)

* fix loop early return, and workaround bug

* use feof

ref #1016 (comment)

* added bengali translation (#1018)

* Fix upload of existing files (#1026)

* Fix typo. (#1028)

* login (Redirecting to Main domain of website instead of tfm.php) fix (#1031)

When logged in it takes to the website's main URL. For example, if I have tfm in www.example.com/tfm/index.php (index.php is tfm) then after logging in it redirects to www.example.com and then have to press back on the browser then it takes to www.example.com/tfm/index.php

* Add configurable path display modes for better privacy and clarity (#1034)

* Resize preview image and implement zoom in/out (#1036)

* Resize preview image and implement zoom in/out

* Remove redundant class name

---------

Co-authored-by: ssams <6338356+ssams@users.noreply.github.com>
Co-authored-by: Sergiu Bivol <sergiu@cip.md>
Co-authored-by: Prasath Mani <prasathmani@users.noreply.github.com>
Co-authored-by: divinity76 <divinity76@gmail.com>
Co-authored-by: Micha Ober <github@ober-mail.de>
Co-authored-by: Joy Biswas <74253956+joybiswas007@users.noreply.github.com>
Co-authored-by: Micha Ober <git@ober-mail.de>
Co-authored-by: Caleb Mazalevskis <maikuolan@gmail.com>
Co-authored-by: xololunatic <97784387+xololunatic@users.noreply.github.com>
Co-authored-by: DannyDaemonic <DannyDaemonic@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants