Как вывести глобальные стили в простор для эмоций?CSS

Разбираемся в CSS
Ответить
Anonymous
 Как вывести глобальные стили в простор для эмоций?

Сообщение Anonymous »


I'm currently need to integrate common components of a library into multiples websites. The component Library currently have a Global styles. That they inject in the following way:

I want there "Global styles" only available for the components of this library. They are only on a part of the page.

So I've try this:

const Styles = styled.div` div { padding: 0; } `; const Page = () => ( ); But it seems that everything in Styles has the priority. Then if the component has padding: 10px; it will take padding: 0; of Styles

Here is the issue reproduced:
I know it's a css issue but I want to solve it with emotion

I've already saw:

Источник: https://stackoverflow.com/questions/605 ... or-emotion
Ответить

Быстрый ответ

Изменение регистра текста: 
Смайлики
:) :( :oops: :roll: :wink: :muza: :clever: :sorry: :angel: :read: *x)
Ещё смайлики…
   
К этому ответу прикреплено по крайней мере одно вложение.

Если вы не хотите добавлять вложения, оставьте поля пустыми.

Максимально разрешённый размер вложения: 15 МБ.

Вернуться в «CSS»