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

Use ImageFile width and height in MediaAttachments(#525) #628

Merged
merged 14 commits into from
Oct 13, 2023

Conversation

unixfall
Copy link
Contributor

@unixfall unixfall commented Oct 3, 2023

Resolves #525

Synopsis

Картинки с большой шириной отображаются некорректно

Solution

По флагу менять BoxContain на cover, когда ширина больше чем в 3 раза больше высоты картинки, на contain - в обратном случае.

Checklist

  • Created PR:
    • In draft mode
    • Name contains issue reference
    • Has type and k:: labels applied
  • Before review:
    • Documentation is updated (if required)
    • Tests are updated (if required)
    • Changes conform code style
    • CHANGELOG entry is added (if required)
    • FCM (final commit message) is posted or updated
    • Draft mode is removed
  • Review is completed and changes are approved
    • FCM (final commit message) is approved
  • Before merge:
    • Milestone is set
    • PR's name and description are correct and up-to-date
    • All temporary labels are removed

@unixfall unixfall changed the title Use ImageFile width and height in MediaAttachments#525 Use ImageFile width and height in MediaAttachments Oct 3, 2023
@unixfall unixfall changed the title Use ImageFile width and height in MediaAttachments Use ImageFile width and height in MediaAttachments(#525) Oct 3, 2023
@unixfall unixfall added bug Bugs and incorrectness problems k::UI/UX UI (user interface) and UX (user experience) changes labels Oct 3, 2023
@unixfall unixfall modified the milestone: 0.1.0-alpha.10 Oct 3, 2023
android/messenger_android.iml Outdated Show resolved Hide resolved
lib/ui/page/home/page/chat/widget/chat_item.dart Outdated Show resolved Hide resolved
macos/Podfile.lock Outdated Show resolved Hide resolved
@unixfall
Copy link
Contributor Author

unixfall commented Oct 3, 2023

FCM

Use `BoxFit.contain` for `MediaAttachment`s with big aspect ratio (#628, #525)

- add `NativeFile.dimensions` field for images
- decode `NativeFile` representing images in `readFile` method

android/messenger_android.iml Outdated Show resolved Hide resolved
@unixfall unixfall added enhancement Improvement of existing features or bugfix and removed bug Bugs and incorrectness problems labels Oct 4, 2023
@unixfall unixfall self-assigned this Oct 4, 2023
CHANGELOG.md Outdated Show resolved Hide resolved
lib/ui/page/home/page/chat/widget/chat_item.dart Outdated Show resolved Hide resolved
@SleepySquash SleepySquash enabled auto-merge (squash) October 13, 2023 16:55
@SleepySquash SleepySquash merged commit 3c6f8d1 into main Oct 13, 2023
21 checks passed
@SleepySquash SleepySquash deleted the 525-fix-chatimage-display branch October 13, 2023 16:57
github-actions bot added a commit that referenced this pull request Oct 13, 2023
…, #525)

- add `NativeFile.dimensions` field for images
- decode `NativeFile` representing images in `readFile` method

Co-authored-by: SleepySquash <nordnikita@icloud.com> 3c6f8d1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Improvement of existing features or bugfix k::UI/UX UI (user interface) and UX (user experience) changes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Use ImageFile width and height in MediaAttachments
2 participants