Skip to content

TextField's toolbar menu theme #92092

Description

@petrnymsa

We developing application which partially wants to support "Dark mode" - that is, support Keyboard appearance a some part of application.

TextFields' popup menu (cut/copy/paste) honor's only Brightness and it is not possible to change its appearance.

Steps to Reproduce

Having following ColorScheme a Theme, which has Brightness set to "dark"

ThemeData createDarkTheme() {
  final colorScheme = ColorScheme(
    brightness: Brightness.dark,
    primary: Colors.purple.shade300,
    primaryVariant: Colors.purple.shade500,
    secondary: Colors.green,
    secondaryVariant: Colors.green.shade500,
    background: Colors.white,
    surface: Colors.red,
    onPrimary: Colors.black,
    onSecondary: Colors.black,
    onSurface: Colors.black,
    onBackground: Colors.black,
    onError: Colors.white,
    error: Colors.red.shade400,
  );

  return ThemeData.from(colorScheme: colorScheme).copyWith(
    applyElevationOverlayColor: false,
  );

As you can see on image, "toolbar" respects surface color but not onSurface color. Instead it honors Brightness a set White/Black color based on current brightness.
image

It makes unusable in our case where we have white screen with white input, but user has Dark mode enabled -> then the popup is blank white (with white text).

Activity

  1. darshankawar commented on Oct 20, 2021

    @darshankawar
    Member

    @petrnymsa
    There's similar open issue describing your case, #89939
    Please follow-up in it for further updates.
    Closing this as a duplicate.

  2. added
    r: duplicateIssue is closed as a duplicate of an existing issue
    and removed
    in triagePresently being triaged by the triage team
    on Oct 20, 2021
  3. github-actions commented on Nov 3, 2021

    @github-actions

    This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of flutter doctor -v and a minimal reproduction of the issue.

  4. locked as resolved and limited conversation to collaborators on Nov 3, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    r: duplicateIssue is closed as a duplicate of an existing issue

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions