mirror of
https://github.com/excalidraw/excalidraw.git
synced 2025-08-03 10:16:26 -04:00
19 lines
348 B
TypeScript
19 lines
348 B
TypeScript
export const Ellipsify = ({
|
|
children,
|
|
...rest
|
|
}: { children: React.ReactNode } & React.HTMLAttributes<HTMLSpanElement>) => {
|
|
return (
|
|
<span
|
|
{...rest}
|
|
style={{
|
|
textOverflow: "ellipsis",
|
|
overflow: "hidden",
|
|
whiteSpace: "nowrap",
|
|
...rest.style,
|
|
}}
|
|
>
|
|
{children}
|
|
</span>
|
|
);
|
|
};
|