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

feat: adjust typography component, fix theme types #3066

Merged
merged 13 commits into from
Feb 2, 2022

Conversation

Drakeoon
Copy link
Contributor

@Drakeoon Drakeoon commented Feb 1, 2022

Summary

This PR introduces a new way of approaching typography - a <Text> component with multiple variants that are Material 3 compliant

Usage

<Text variant="heading-large" />

Test plan

  1. Open the example app
  2. Navigate to Typography
  3. You will see old examples at the top (still supported)
  4. You will see new examples at the bottom (<Text variant="..."> usage)

image

@callstack-bot
Copy link

callstack-bot commented Feb 1, 2022

Hey @Drakeoon, thank you for your pull request 🤗. The documentation from this branch can be viewed here.

@Drakeoon Drakeoon force-pushed the feat/adjust-typography-component branch from cb2a5c9 to d8f980b Compare February 1, 2022 17:18
@Drakeoon Drakeoon changed the base branch from next to main February 1, 2022 17:18
@Drakeoon Drakeoon changed the base branch from main to next February 1, 2022 17:18
@Drakeoon Drakeoon changed the title WIP feat: adjust typography component feat: adjust typography component, fix theme types Feb 2, 2022
Comment on lines -37 to -69
const CustomDarkTheme = {
...DarkTheme,
colors: {
...DarkTheme.colors,
customColor: '#BADA55',
},
fonts: {
...DarkTheme.fonts,
superLight: { ...DarkTheme.fonts['light'] },
},
animation: {
...DarkTheme.animation,
customProperty: 1,
},
};

const CustomDefaultTheme = {
...DefaultTheme,
colors: {
...DefaultTheme.colors,
customColor: '#BADA55',
},
fonts: {
...DefaultTheme.fonts,
superLight: { ...DefaultTheme.fonts['light'] },
},
userDefinedThemeProperty: '',
animation: {
...DefaultTheme.animation,
customProperty: 1,
},
};

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@lukewalczak We need to keep that in mind and decide whether we still want to bring it back or maybe instead of this include a section in our docs on how to override themes

@Drakeoon Drakeoon requested a review from lukewalczak February 2, 2022 11:04
@Drakeoon Drakeoon force-pushed the feat/adjust-typography-component branch from c1d55c7 to a5ee163 Compare February 2, 2022 12:56
@Drakeoon
Copy link
Contributor Author

Drakeoon commented Feb 2, 2022

So it turns out our Expo Preview job either doesn't clear cache or uses a different dependency version (@babel/core, @babel/parser?) than when running the build locally. I spoke directly to @lukewalczak and we decided that we will move on and deal with this issue later, as it does not prevent us from developing MD3 components locally.

@Drakeoon Drakeoon requested a review from lukewalczak February 2, 2022 13:31
Copy link
Member

@lukewalczak lukewalczak left a comment

Choose a reason for hiding this comment

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

On the next iteration we need to:

  • refine the process of overriding themes
  • fix Expo Preview jo

@lukewalczak lukewalczak merged commit f0be14c into next Feb 2, 2022
@lukewalczak lukewalczak deleted the feat/adjust-typography-component branch February 2, 2022 13:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants