/
githubmirror
/
carbon
Обзор
Документация
Войти
/
githubmirror
/
carbon
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
main
components/Toolbar.js
38 строк
807 B
Mike Fix
fix snippet toolbar logic
15 май 2022, 00:15
Не верифицирован
15 май 2022, 00:15
859abfe
Код
Авторство
О чём код?
import React from 'react' const Toolbar = props => ( <div className="toolbar" style={props.style}> {props.children} <style jsx> {` .toolbar { width: 100%; height: 40px; margin-bottom: 1rem; display: flex; position: relative; z-index: 3; font-size: 14px; } .toolbar > :global(div:not(:last-child)) { margin-right: 8px; } @media (max-width: 920px) { .toolbar { max-width: 100%; height: auto; flex-direction: column; } .toolbar > :global(div:not(:last-of-type)) { margin-right: 0; margin-bottom: 1rem; } } `} </style> </div> ) export default Toolbar