Skip to content

Conversation

@hellkun
Copy link

@hellkun hellkun commented Mar 10, 2021

Hi there, thanks you making this great package.

In my experience, it's rather difficult to make the color of texts suitable for both light and dark theme. For example, texts of deep grey look good on light theme, but hardly readable on dark theme.
Maybe we could support apply colors defined in colorScheme, e.g. primary, onPrimary, surface, onSurface, etc, to keep the same level of readability regradless of which theme is applied.

This PR might have a workaround for use cases like above, which defines a mapping for themed color, like:

  • ::primary -> colorScheme.primary
  • ::onPrimary -> colorScheme.onPrimary
  • ::surface -> colorScheme.surface
  • ::onSurface -> colorScheme.onSurface
    ...

There's also limitation: The exported json has to be manually modified, as the code has not idea about the developer's intention (a constant hex color, or a color picked from colorScheme)

@yashmittalJTG
Copy link

Missing concrete implementations of 'WidgetParser.export' and 'getter WidgetParser.widgetType'.
any solution for this error?

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