``` ~/go/bin/sourcemapper -output ddb -jsurl https://media.dndbeyond.com/character-app/static/js/main.90aa78c5.js ```
22 lines
596 B
TypeScript
22 lines
596 B
TypeScript
import clsx from "clsx";
|
|
import { FC, HTMLAttributes, ReactNode } from "react";
|
|
|
|
import { AnimatedLoadingRingSvg } from "~/tools/js/smartComponents/Svg";
|
|
|
|
interface SpinnerProps extends HTMLAttributes<HTMLDivElement> {
|
|
label?: ReactNode;
|
|
}
|
|
|
|
export const Spinner: FC<SpinnerProps> = ({
|
|
label = "Loading",
|
|
className,
|
|
...props
|
|
}) => {
|
|
return (
|
|
<div className={clsx(["ddbc-loading-placeholder", className])} {...props}>
|
|
<AnimatedLoadingRingSvg className="ddbc-loading-placeholder__icon" />
|
|
<span className="ddbc-loading-placeholder__label">{label}</span>
|
|
</div>
|
|
);
|
|
};
|