UNPKG

@intility/bifrost-react

Version:

React library for Intility's design system, Bifrost.

17 lines (16 loc) 702 B
import { PropsWithChildren } from "react"; export type BreakpointValue = BreakpointProps["from"]; export type BreakpointProps = PropsWithChildren<{ /** Content will only be displayed for screens wider than `from` */ from?: "small" | "medium" | "large" | "xl" | "xxl"; /** Content will only be displayed for screens narrower than `to` */ to?: "small" | "medium" | "large" | "xl" | "xxl"; }>; /** Render a `<div>` that will only be displayed for certain screen sizes: * `small` = 600px, * `medium` = 960px, * `large` = 1280px, * `xl` = 1600px, * `xxl` = 1920px */ export default function Breakpoint({ children, from, to }: BreakpointProps): import("react/jsx-runtime").JSX.Element;