mirror of
https://github.com/Equicord/Equicord.git
synced 2025-02-20 15:18:50 -05:00
17 lines
459 B
TypeScript
17 lines
459 B
TypeScript
import type { React } from "../webpack/common";
|
|
|
|
export function Flex(props: React.PropsWithChildren<{
|
|
flexDirection?: React.CSSProperties["flexDirection"];
|
|
style?: React.CSSProperties;
|
|
className?: string;
|
|
}>) {
|
|
props.style ??= {};
|
|
props.style.flexDirection ||= props.flexDirection;
|
|
props.style.gap ??= "1em";
|
|
props.style.display = "flex";
|
|
return (
|
|
<div {...props}>
|
|
{props.children}
|
|
</div>
|
|
);
|
|
}
|