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

DB UI overrides font style of non db-ui components #2733

Open
1 of 7 tasks
robruh opened this issue Jun 10, 2024 · 2 comments
Open
1 of 7 tasks

DB UI overrides font style of non db-ui components #2733

robruh opened this issue Jun 10, 2024 · 2 comments
Labels
👩‍👧‍👦community feedback Feedback from community ❓question Further information is requested

Comments

@robruh
Copy link

robruh commented Jun 10, 2024

Which generators are impacted?

  • All
  • HTML
  • React
  • Angular
  • Vue
  • Web components
  • Power Apps

Reproduction case

It seems that the css from db-ui (@db-ui/components/build/styles/db-ui-42.css or any other) overrides our fonts of non db-ui components. I also tried other db-ui css to solve the problem with the fonts, but either certain styles were missing or the fonts were also overwritten. Additionally, we are using a font in our project that is also used in the DB UI.

Expected Behaviour

Our fonts in non db-ui components are not being overwritten by the db-ui css.

Screenshots

I cannot provide screenshots for privacy reasons.

Browser version

None

Add any other context about the problem here.

No response

@mfranzke mfranzke added ❓question Further information is requested 👩‍👧‍👦community feedback Feedback from community labels Jun 10, 2024
@mfranzke mfranzke added this to the Guidelines 3.0 RC milestone Jun 10, 2024
@nmerget
Copy link
Member

nmerget commented Jun 17, 2024

@robruh thanks for your feedback.

Currently, we provide a required file that sets the default font size to the root and inherits all the font size for all components. We do this to make sure that all HTML tags like p, a, and also input or button will use the correct font size + line height.

We bundle everything inside db-ui-42.css for a quick start. If you need some customization you can check this. It describes how to split the db-ui-42.css. Basically, you shouldn't include @db-ui/foundations/build/css/init/required.css or at least not every line.

Another option would be to keep the db-ui-42.css and overwrite your non db-ui-components like this.

@mfranzke
Copy link
Member

@robruh is this a viable solution for you and/or do you have some other suggestion or solution in mind ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
👩‍👧‍👦community feedback Feedback from community ❓question Further information is requested
Projects
None yet
Development

No branches or pull requests

3 participants