mirror of
https://github.com/outline/outline.git
synced 2026-11-22 22:02:35 +03:00
25 lines
734 B
TypeScript
25 lines
734 B
TypeScript
import styled from "styled-components";
|
|
import { breakpoint } from "@shared/styles/breakpoint";
|
|
import { IconTitleWrapper } from "@shared/components/Icon";
|
|
|
|
const Heading = styled.h1<{ as?: string; centered?: boolean }>`
|
|
display: flex;
|
|
align-items: center;
|
|
user-select: none;
|
|
${(props) => (props.as ? "" : "margin-top: 16px; font-weight: 600;")}
|
|
${(props) => (props.centered ? "text-align: center;" : "")}
|
|
|
|
/* On mobile the title icon sits above the title, so leave room for it. */
|
|
${breakpoint("mobile", "tablet")`
|
|
&:has(> ${IconTitleWrapper}) {
|
|
margin-top: 60px;
|
|
}
|
|
`};
|
|
|
|
${breakpoint("tablet")`
|
|
${(props: { as?: string }) => (props.as ? "" : "margin-top: 6vh;")}
|
|
`};
|
|
`;
|
|
|
|
export default Heading;
|