upload
upload copied to clipboard
Update FormatTextPreview.php
Fixes #0000
Changes proposed in this pull request: Fixes the "expand" button's misbehavior while using Text Preview.
Confirmed
- [x] Frontend changes: tested on a local Flarum installation.
- [x] Backend changes: tests are green (run
composer test
).
Required changes:
- [ ] Related Flarum core extension PR's: (Omit this section if irrelevant)
Hi @edgeinfinity1 thanks for your contribution! Please provide steps to reproduce the issue, and maybe add some screenshots/screencasts before and after the change. Thanks!
Hi @edgeinfinity1 thanks for your contribution! Please provide steps to reproduce the issue, and maybe add some screenshots/screencasts before and after the change. Thanks!
I'm sorry for not being able to provide screenshots before the change, because my forum is already in production state. It's very easy to reproduce the problem:
- use "Text Preview" for mime text files.
- upload a file within 5 lines, and the expand button shows and does nothing.
- upload a file more than 5 lines, and there is no expand button at all.
this problem is obviously because of a misjudgement in rather the file should be expandable, or say just reversed.