mirror of
https://github.com/sussy-code/smov.git
synced 2026-03-30 14:38:42 +00:00
This commit updates the import statements in the codebase to comply with ESLint rules for import ordering. All imports have been sorted alphabetically and grouped according to the specified import groups in the ESLint configuration. This improves the codebase's consistency and maintainability.
30 lines
970 B
TypeScript
30 lines
970 B
TypeScript
import { useSettings } from "@/state/settings";
|
|
|
|
import { Icon, Icons } from "./Icon";
|
|
|
|
export const colors = ["#ffffff", "#00ffff", "#ffff00"];
|
|
export default function CaptionColorSelector({ color }: { color: string }) {
|
|
const { captionSettings, setCaptionColor } = useSettings();
|
|
return (
|
|
<div
|
|
className={`flex h-8 w-8 items-center justify-center rounded transition-[background-color,transform] duration-100 hover:bg-[#1c161b79] active:scale-110 ${
|
|
color === captionSettings.style.color ? "bg-[#1C161B]" : ""
|
|
}`}
|
|
onClick={() => setCaptionColor(color)}
|
|
>
|
|
<div
|
|
className="h-4 w-4 cursor-pointer appearance-none rounded-full"
|
|
style={{
|
|
backgroundColor: color,
|
|
}}
|
|
/>
|
|
<Icon
|
|
className={[
|
|
"absolute text-xs text-[#1C161B]",
|
|
color === captionSettings.style.color ? "" : "hidden",
|
|
].join(" ")}
|
|
icon={Icons.CHECKMARK}
|
|
/>
|
|
</div>
|
|
);
|
|
}
|