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

Minor UI fixes #1386

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open

Minor UI fixes #1386

wants to merge 3 commits into from

Conversation

k3-cat
Copy link

@k3-cat k3-cat commented Oct 4, 2024

Thank you so much for your contribution to FluffyChat ❤️❤️❤️

Please make sure that your Pull Request meet the following acceptance criteria:

  • Code formatting and import sorting has been done with dart format lib/ test/ and dart run import_sorter:main --no-comments
  • The commit message uses the format of Conventional Commits
  • The commit message describes what has been changed, why it has been changed and how it has been changed
  • Every new feature or change of the design/GUI is linked to an approved design proposal in an issue
  • Every new feature in the app or the build system has a strategy how this will be tested and maintained from now on for every release, e.g. a volunteer who takes over maintainership

Pull Request has been tested on:

  • Android
  • iOS
  • Browser (Chromium based)
  • Browser (Firefox based)
  • Browser (WebKit based)
  • Desktop Linux
  • Desktop Windows
  • Desktop macOS

Sorry for the missing test on iOS, I couldn't build for it.

@@ -461,6 +461,10 @@ class InputBar extends StatelessWidget {
final data = content.data;
if (data == null) return;

if (content.mimeType.startsWith("image/")) {
onSubmitImage!(data);
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I use this feature mostly with the GBoard when sending a sticker or GIF. Having a dialog every time would be just overhead IMO

Copy link
Author

@k3-cat k3-cat Oct 7, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah... that will be very inconvenient....

But I think media is a bit expensive for the matrix. Currently both Android and web can upload images by pasting. So without visual confirmation, users might accidentally upload contents either they don't want or in its original quality (average screenshot takes about 7M, and in most case it's unnecessary to keep the original quality). Thus, putting more burden on home-level servers.

What if we only show the dialog for images larger than a certain size (e.g. 1M)?

@@ -72,6 +73,10 @@ abstract class FluffyThemes {
useMaterial3: true,
brightness: brightness,
colorScheme: colorScheme,
cupertinoOverrideTheme: const CupertinoThemeData(
// This is required by adaptive_dialog
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you explain here, why it is required?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The issue:
image

The fix:
I thought this should be a common issue, so I've searched if there are any instructions.
and...
The change is guided by the readme of adaptive_dialog https://pub.dev/packages/adaptive_dialog#the-input-text-color-same-with-backgound-when-using-cupertinotextinputdialog

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.

2 participants