updated pannels

This commit is contained in:
Nalvazhuthi 2025-03-25 14:25:51 +05:30
parent 61b3c4ee2c
commit a84fe40486
7 changed files with 289 additions and 393 deletions

View File

@ -5,7 +5,7 @@ import Widgets3D from "./Widgets3D";
import WidgetsFloating from "./WidgetsFloating"; import WidgetsFloating from "./WidgetsFloating";
const Widgets = () => { const Widgets = () => {
const [activeOption, setActiveOption] = useState("Floating"); const [activeOption, setActiveOption] = useState("2D");
const handleToggleClick = (option: string) => { const handleToggleClick = (option: string) => {
setActiveOption(option); setActiveOption(option);

View File

@ -57,78 +57,80 @@ const Tools: React.FC = () => {
return ( return (
<div className="tools-container"> <div className="tools-container">
<div className="drop-down-icons"> {!isPlaying && (
<div className="activeDropicon"> <div className="drop-down-icons">
{activeSubTool == "cursor" && ( <div className="activeDropicon">
<div {activeSubTool == "cursor" && (
className={`tool-button ${ <div
activeTool === "cursor" ? "active" : "" className={`tool-button ${
}`} activeTool === "cursor" ? "active" : ""
onClick={() => { }`}
setActiveTool("cursor"); onClick={() => {
}} setActiveTool("cursor");
> }}
<CursorIcon isActive={activeTool === "cursor"} /> >
</div> <CursorIcon isActive={activeTool === "cursor"} />
)} </div>
{activeSubTool == "free-hand" && ( )}
<div {activeSubTool == "free-hand" && (
className={`tool-button ${ <div
activeTool === "free-hand" ? "active" : "" className={`tool-button ${
}`} activeTool === "free-hand" ? "active" : ""
onClick={() => { }`}
setActiveTool("free-hand"); onClick={() => {
}} setActiveTool("free-hand");
> }}
<FreeMoveIcon isActive={activeTool === "free-hand"} /> >
</div> <FreeMoveIcon isActive={activeTool === "free-hand"} />
)} </div>
{activeModule !== "visualization" && ( )}
<div {activeModule !== "visualization" && (
className="drop-down-option-button" <div
ref={dropdownRef} className="drop-down-option-button"
onClick={() => { ref={dropdownRef}
setOpenDrop(!openDrop); onClick={() => {
console.log(openDrop); setOpenDrop(!openDrop);
}} console.log(openDrop);
> }}
<ArrowIcon /> >
{openDrop && ( <ArrowIcon />
<div className="drop-down-container"> {openDrop && (
<div <div className="drop-down-container">
className="option-list" <div
onClick={() => { className="option-list"
setOpenDrop(false); onClick={() => {
setActiveTool("cursor"); setOpenDrop(false);
setActiveSubTool("cursor"); setActiveTool("cursor");
}} setActiveSubTool("cursor");
> }}
<div className="active-option"> >
{activeSubTool === "cursor" && <TickIcon />} <div className="active-option">
{activeSubTool === "cursor" && <TickIcon />}
</div>
<CursorIcon isActive={false} />
<div className="option">Cursor</div>
</div> </div>
<CursorIcon isActive={false} /> <div
<div className="option">Cursor</div> className="option-list"
</div> onClick={() => {
<div setOpenDrop(false);
className="option-list" setActiveTool("free-hand");
onClick={() => { setActiveSubTool("free-hand");
setOpenDrop(false); }}
setActiveTool("free-hand"); >
setActiveSubTool("free-hand"); <div className="active-option">
}} {activeSubTool === "free-hand" && <TickIcon />}
> </div>
<div className="active-option"> <FreeMoveIcon isActive={false} />
{activeSubTool === "free-hand" && <TickIcon />} <div className="option">Free Hand</div>
</div> </div>
<FreeMoveIcon isActive={false} />
<div className="option">Free Hand</div>
</div> </div>
</div> )}
)} </div>
</div> )}
)} </div>
</div> </div>
</div> )}
{!toggleThreeD && activeModule === "builder" && ( {!toggleThreeD && activeModule === "builder" && (
<> <>
<div className="split"></div> <div className="split"></div>
@ -191,7 +193,7 @@ const Tools: React.FC = () => {
</div> </div>
</> </>
)} )}
{activeModule === "visualization" && ( {activeModule === "visualization" && !isPlaying && (
<> <>
<div className="split"></div> <div className="split"></div>
<div className="draw-tools"> <div className="draw-tools">
@ -210,40 +212,51 @@ const Tools: React.FC = () => {
</div> </div>
</> </>
)} )}
<div className="split"></div> {!isPlaying && (
<div className="general-options"> <>
<div <div className="split"></div>
className={`tool-button ${activeTool === "comment" ? "active" : ""}`} <div className="general-options">
onClick={() => { <div
setActiveTool("comment"); className={`tool-button ${
}} activeTool === "comment" ? "active" : ""
> }`}
<CommentIcon isActive={activeTool === "comment"} /> onClick={() => {
setActiveTool("comment");
}}
>
<CommentIcon isActive={activeTool === "comment"} />
</div>
<div
className={`tool-button ${activeTool === "play" ? "active" : ""}`}
onClick={() => {
setActiveTool("play");
setIsPlaying(!isPlaying);
}}
>
<PlayIcon isActive={activeTool === "play"} />
</div>
</div>
<div className="split"></div>
<div
className={`toggle-threed-button${toggleThreeD ? " toggled" : ""}`}
onClick={() => {
setToggleThreeD(!toggleThreeD);
}}
>
<div className={`toggle-option${!toggleThreeD ? " active" : ""}`}>
2d
</div>
<div className={`toggle-option${toggleThreeD ? " active" : ""}`}>
3d
</div>
</div>
</>
)}
{isPlaying && (
<div className="exitPlay" onClick={() => setIsPlaying(false)}>
X
</div> </div>
<div )}
className={`tool-button ${activeTool === "play" ? "active" : ""}`}
onClick={() => {
setActiveTool("play");
setIsPlaying(!isPlaying);
}}
>
<PlayIcon isActive={activeTool === "play"} />
</div>
</div>
<div className="split"></div>
<div
className={`toggle-threed-button${toggleThreeD ? " toggled" : ""}`}
onClick={() => {
setToggleThreeD(!toggleThreeD);
}}
>
<div className={`toggle-option${!toggleThreeD ? " active" : ""}`}>
2d
</div>
<div className={`toggle-option${toggleThreeD ? " active" : ""}`}>
3d
</div>
</div>
</div> </div>
); );
}; };

View File

@ -49,29 +49,30 @@ const Panel: React.FC<PanelProps> = ({ selectedZone, setSelectedZone }) => {
const rightActive = previousPanels.includes("right"); const rightActive = previousPanels.includes("right");
const topActive = previousPanels.includes("top"); const topActive = previousPanels.includes("top");
const bottomActive = previousPanels.includes("bottom"); const bottomActive = previousPanels.includes("bottom");
const panelSize = isPlaying ? 355 : 305;
switch (side) { switch (side) {
case "top": case "top":
case "bottom": case "bottom":
return { return {
width: `calc(100% - ${ width: `calc(100% - ${
(leftActive ? 204 : 0) + (rightActive ? 204 : 0) (leftActive ? panelSize : 0) + (rightActive ? panelSize : 0)
}px)`, }px)`,
left: leftActive ? "204px" : "0", height: `${panelSize - 5}px`,
right: rightActive ? "204px" : "0", left: leftActive ? `${panelSize}px` : "0",
right: rightActive ? `${panelSize}px` : "0",
[side]: "0", [side]: "0",
height: "200px",
}; };
case "left": case "left":
case "right": case "right":
return { return {
width: `${panelSize - 5}px`,
height: `calc(100% - ${ height: `calc(100% - ${
(topActive ? 204 : 0) + (bottomActive ? 204 : 0) (topActive ? panelSize : 0) + (bottomActive ? panelSize : 0)
}px)`, }px)`,
top: topActive ? "204px" : "0", top: topActive ? `${panelSize}px` : "0",
bottom: bottomActive ? "204px" : "0", bottom: bottomActive ? `${panelSize}px` : "0",
[side]: "0", [side]: "0",
width: "200px",
}; };
default: default:
return {}; return {};
@ -83,53 +84,51 @@ const Panel: React.FC<PanelProps> = ({ selectedZone, setSelectedZone }) => {
const handleDrop = (e: React.DragEvent, panel: Side) => { const handleDrop = (e: React.DragEvent, panel: Side) => {
e.preventDefault(); e.preventDefault();
const { draggedAsset } = useWidgetStore.getState(); const { draggedAsset } = useWidgetStore.getState();
if (!draggedAsset) return; if (!draggedAsset) return;
if (isPanelLocked(panel)) return; if (isPanelLocked(panel)) return;
const currentWidgetsCount = getCurrentWidgetCount(panel); const currentWidgetsCount = getCurrentWidgetCount(panel);
const maxCapacity = calculatePanelCapacity(panel); const maxCapacity = calculatePanelCapacity(panel);
if (currentWidgetsCount >= maxCapacity) return; if (currentWidgetsCount >= maxCapacity) return;
addWidgetToPanel(draggedAsset, panel); addWidgetToPanel(draggedAsset, panel);
}; };
// Helper functions const isPanelLocked = (panel: Side) =>
const isPanelLocked = (panel: Side) =>
selectedZone.lockedPanels.includes(panel); selectedZone.lockedPanels.includes(panel);
const getCurrentWidgetCount = (panel: Side) => const getCurrentWidgetCount = (panel: Side) =>
selectedZone.widgets.filter(w => w.panel === panel).length; selectedZone.widgets.filter((w) => w.panel === panel).length;
const calculatePanelCapacity = (panel: Side) => { const calculatePanelCapacity = (panel: Side) => {
const CHART_WIDTH = 200; const CHART_WIDTH = 250;
const CHART_HEIGHT = 200; const CHART_HEIGHT = 250;
const FALLBACK_HORIZONTAL_CAPACITY = 5; const FALLBACK_HORIZONTAL_CAPACITY = 5;
const FALLBACK_VERTICAL_CAPACITY = 3; const FALLBACK_VERTICAL_CAPACITY = 3;
const dimensions = panelDimensions[panel]; const dimensions = panelDimensions[panel];
if (!dimensions) { if (!dimensions) {
return panel === "top" || panel === "bottom" return panel === "top" || panel === "bottom"
? FALLBACK_HORIZONTAL_CAPACITY ? FALLBACK_HORIZONTAL_CAPACITY
: FALLBACK_VERTICAL_CAPACITY; : FALLBACK_VERTICAL_CAPACITY;
} }
return panel === "top" || panel === "bottom" return panel === "top" || panel === "bottom"
? Math.floor(dimensions.width / CHART_WIDTH) ? Math.floor(dimensions.width / CHART_WIDTH)
: Math.floor(dimensions.height / CHART_HEIGHT); : Math.floor(dimensions.height / CHART_HEIGHT);
}; };
const addWidgetToPanel = (asset: any, panel: Side) => { const addWidgetToPanel = (asset: any, panel: Side) => {
const newWidget = { const newWidget = {
...asset, ...asset,
id: generateUniqueId(), id: generateUniqueId(),
panel, panel,
}; };
setSelectedZone(prev => ({ setSelectedZone((prev) => ({
...prev, ...prev,
widgets: [...prev.widgets, newWidget] widgets: [...prev.widgets, newWidget],
})); }));
}; };
@ -187,7 +186,6 @@ const Panel: React.FC<PanelProps> = ({ selectedZone, setSelectedZone }) => {
opacity: selectedZone.lockedPanels.includes(side) ? "0.8" : "1", opacity: selectedZone.lockedPanels.includes(side) ? "0.8" : "1",
}} }}
> >
<>{}</>
{selectedZone.widgets {selectedZone.widgets
.filter((w) => w.panel === side) .filter((w) => w.panel === side)
.map((widget) => ( .map((widget) => (
@ -200,4 +198,4 @@ const Panel: React.FC<PanelProps> = ({ selectedZone, setSelectedZone }) => {
); );
}; };
export default Panel; export default Panel;

View File

@ -72,7 +72,7 @@ const RealTimeVisulization: React.FC = () => {
<div <div
ref={containerRef} ref={containerRef}
id="real-time-vis-canvas" id="real-time-vis-canvas"
className="realTime-viz canvas" className={`realTime-viz canvas ${!isPlaying ? "playActiveFalse" : ""}`}
style={{ style={{
height: isPlaying ? "100vh" : "", height: isPlaying ? "100vh" : "",
width: isPlaying ? "100%" : "", width: isPlaying ? "100%" : "",

View File

@ -7,7 +7,7 @@ interface ModuleStore {
} }
const useModuleStore = create<ModuleStore>((set) => ({ const useModuleStore = create<ModuleStore>((set) => ({
activeModule: "builder", // Initial state activeModule: "visualization", // Initial state
setActiveModule: (module) => set({ activeModule: module }), // Update state setActiveModule: (module) => set({ activeModule: module }), // Update state
})); }));

View File

@ -4,7 +4,7 @@
.tools-container { .tools-container {
@include flex-center; @include flex-center;
position: fixed; position: fixed;
bottom: 32px; bottom: 50px;
left: 50%; left: 50%;
transform: translate(-50%, 0); transform: translate(-50%, 0);
padding: 8px; padding: 8px;
@ -14,12 +14,14 @@
width: fit-content; width: fit-content;
transition: width 0.2s; transition: width 0.2s;
background-color: var(--background-color); background-color: var(--background-color);
.split { .split {
height: 20px; height: 20px;
width: 2px; width: 2px;
border-radius: 2px; border-radius: 2px;
background: var(--highlight-accent-color); background: var(--highlight-accent-color);
} }
.draw-tools, .draw-tools,
.general-options, .general-options,
.activeDropicon { .activeDropicon {
@ -29,42 +31,46 @@
width: 0; width: 0;
opacity: 0; opacity: 0;
animation: expandWidth 0.2s ease-in-out forwards; animation: expandWidth 0.2s ease-in-out forwards;
.tool-button { .tool-button {
@include flex-center; @include flex-center;
height: 28px; height: 28px;
width: 28px; width: 28px;
cursor: pointer; cursor: pointer;
border-radius: #{$border-radius-small}; border-radius: #{$border-radius-small};
&:hover { &:hover {
background: color-mix( background: color-mix(in srgb,
in srgb, var(--highlight-accent-color) 60%,
var(--highlight-accent-color) 60%, transparent);
transparent
);
} }
} }
.active { .active {
background-color: var(--accent-color); background-color: var(--accent-color);
&:hover { &:hover {
background-color: var(--accent-color); background-color: var(--accent-color);
} }
} }
} }
.activeDropicon { .activeDropicon {
gap: 2px; gap: 2px;
.drop-down-option-button { .drop-down-option-button {
@include flex-center; @include flex-center;
height: 28px; height: 28px;
cursor: pointer; cursor: pointer;
border-radius: #{$border-radius-small}; border-radius: #{$border-radius-small};
position: relative; position: relative;
&:hover { &:hover {
background: color-mix( background: color-mix(in srgb,
in srgb, var(--highlight-accent-color) 60%,
var(--highlight-accent-color) 60%, transparent);
transparent
);
} }
.drop-down-container { .drop-down-container {
position: absolute; position: absolute;
bottom: 40px; bottom: 40px;
@ -72,6 +78,7 @@
box-shadow: #{$box-shadow-medium}; box-shadow: #{$box-shadow-medium};
padding: 8px; padding: 8px;
border-radius: #{$border-radius-large}; border-radius: #{$border-radius-large};
.option-list { .option-list {
margin: 4px 0; margin: 4px 0;
display: flex; display: flex;
@ -80,18 +87,22 @@
border-radius: #{$border-radius-medium}; border-radius: #{$border-radius-medium};
gap: 6px; gap: 6px;
padding: 4px; padding: 4px;
&:hover { &:hover {
background-color: var(--highlight-accent-color); background-color: var(--highlight-accent-color);
color: var(--accent-color); color: var(--accent-color);
path { path {
stroke: var(--accent-color); stroke: var(--accent-color);
} }
} }
.active-option { .active-option {
height: 12px; height: 12px;
width: 12px; width: 12px;
@include flex-center; @include flex-center;
} }
.option { .option {
color: inherit; color: inherit;
} }
@ -99,6 +110,7 @@
} }
} }
} }
.toggle-threed-button { .toggle-threed-button {
@include flex-center; @include flex-center;
padding: 3px; padding: 3px;
@ -106,12 +118,14 @@
background-color: var(--highlight-accent-color); background-color: var(--highlight-accent-color);
gap: 2px; gap: 2px;
position: relative; position: relative;
.toggle-option { .toggle-option {
font-size: var(--font-size-small); font-size: var(--font-size-small);
padding: 2px; padding: 2px;
z-index: 1; z-index: 1;
transition: all 0.2s; transition: all 0.2s;
} }
&::after { &::after {
content: ""; content: "";
position: absolute; position: absolute;
@ -123,15 +137,38 @@
border-radius: #{$border-radius-small}; border-radius: #{$border-radius-small};
transition: all 0.2s; transition: all 0.2s;
} }
.active { .active {
color: var(--highlight-accent-color); color: var(--highlight-accent-color);
} }
} }
.toggled { .toggled {
&::after { &::after {
left: 24px; left: 24px;
} }
} }
.exitPlay {
width: 30px;
height: 30px;
border-radius: 50%;
background-color: var(--accent-color);
display: flex;
justify-content: center;
align-items: center;
cursor: pointer;
position: relative;
transition: background-color 0.3s, transform 0.3s;
color: var(--background-color);
}
.exitPlay:hover {
background-color: var(--accent-color);
transform: scale(1.1);
}
} }
@keyframes expandWidth { @keyframes expandWidth {
@ -139,8 +176,9 @@
width: 0; width: 0;
opacity: 0; opacity: 0;
} }
to { to {
width: fit-content; width: fit-content;
opacity: 1; opacity: 1;
} }
} }

View File

@ -1,148 +1,26 @@
@use "../abstracts/variables.scss" as *; @use "../abstracts/variables.scss" as *;
@use "../abstracts/mixins.scss" as *;
// Main Container // Main Container
.realTime-viz { .realTime-viz {
background-color: var(--background-color); background-color: var(--background-color);
border-radius: 20px; border-radius: 20px;
box-shadow: $box-shadow-medium; box-shadow: $box-shadow-medium;
width: calc(100% - (320px + 270px + 90px)); width: 100%;
height: calc(100% - (200px + 80px)); height: 100%;
position: absolute; position: absolute;
top: 50%; top: 0;
left: calc(270px + 45px); left: 0;
transform: translate(0, -50%); transform: scale(1);
.icon {
display: flex;
align-items: center;
position: relative;
}
.icons-container {
.icon {
&:first-child {
&::after {
display: none;
}
}
}
}
.zoon-wrapper {
display: flex;
background-color: var(--background-color);
position: absolute;
bottom: 10px;
left: 50%;
transform: translate(-50%, 0);
gap: 6px;
padding: 4px;
border-radius: 8px;
max-width: 80%;
overflow: auto;
max-width: calc(100% - 450px);
&::-webkit-scrollbar {
display: none;
}
.zone {
width: auto;
background-color: var(--background-color);
border-radius: 6px;
padding: 4px 8px;
white-space: nowrap;
font-size: $small;
}
.active {
background-color: var(--accent-color);
color: var(--background-color);
// color: #FCFDFD !important;
}
}
.zoon-wrapper.bottom {
bottom: 210px;
}
@media (max-width: 1024px) {
width: 80%; // Increase width to take more space on smaller screens
height: 500px; // Reduce height to fit smaller screens
left: 50%; // Center horizontally
.main-container {
margin: 0 15px; // Reduce margin for better spacing
}
.zoon-wrapper {
bottom: 5px; // Adjust position for smaller screens
&.bottom {
bottom: 150px; // Adjust for bottom placement
}
}
}
.content-container {
display: flex;
height: 100vh;
transition: all 0.3s ease;
}
.main-container {
position: relative;
flex: 1;
height: 600px;
background-color: rgb(235, 235, 235);
margin: 0 30px;
transition: height 0.3s ease, margin 0.3s ease;
.zoon-wrapper {
display: flex;
background-color: rgba(224, 223, 255, 0.5);
position: absolute;
bottom: 10px;
left: 50%;
transform: translate(-50%, 0);
gap: 6px;
padding: 4px;
border-radius: 8px;
max-width: 80%;
overflow: auto;
transition: transform 0.3s ease;
&::-webkit-scrollbar {
display: none;
}
.zone {
width: auto;
background-color: $background-color;
border-radius: 6px;
padding: 4px 8px;
white-space: nowrap;
cursor: pointer;
transition: background-color 0.3s ease;
&.active {
background-color: var(--primary-color);
color: var(--accent-color);
}
}
&.bottom {
bottom: 210px;
}
}
}
// Panels
.panel { .panel {
position: absolute; position: absolute;
background: white; background: white;
box-shadow: 0 0 10px rgba(0, 0, 0, 0.1); box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
transition: all 0.3s ease; transition: all 0.3s ease;
border-radius: 6px; border-radius: 6px;
overflow: visible !important; overflow: hidden;
.panel-content { .panel-content {
position: relative; position: relative;
@ -159,7 +37,7 @@
} }
.chart-container { .chart-container {
width: 100%; width: 229px;
height: 200px; height: 200px;
max-height: 100%; max-height: 100%;
border: 1px dotted #a9a9a9; border: 1px dotted #a9a9a9;
@ -179,53 +57,89 @@
color: var(--primary-color); color: var(--primary-color);
} }
} }
}
// Panels for each side
.left-panel,
.right-panel {
.chart-container {
padding: 10px;
width: 100% !important;
height: 250px !important;
&.top-panel,
&.bottom-panel {
left: 0;
right: 0;
.fullScreen {
background-color: red;
}
.panel-content {
display: flex;
flex-direction: row;
.chart-container {
height: 100%;
width: 200px;
}
}
}
&.top-panel {
top: 0;
}
&.bottom-panel {
bottom: 0;
}
&.left-panel {
left: 0;
top: 0;
bottom: 0;
.chart-container {
width: 100%;
height: 180px;
}
}
&.right-panel {
right: 0;
top: 0;
bottom: 0;
} }
} }
.top-panel,
.bottom-panel {
.chart-container {
padding: 10px;
width: 300px !important;
height: 100% !important;
}
}
// Zone Wrapper
.zoon-wrapper {
display: flex;
background-color: var(--background-color);
position: absolute;
bottom: 10px;
left: 50%;
transform: translate(-50%, 0);
gap: 6px;
padding: 4px;
border-radius: 8px;
max-width: 80%;
overflow: auto;
max-width: calc(100% - 450px);
&::-webkit-scrollbar {
display: none;
}
.zone {
width: auto;
background-color: var(--background-color);
border-radius: 6px;
padding: 4px 8px;
white-space: nowrap;
font-size: $small;
}
.active {
background-color: var(--accent-color);
color: var(--background-color);
}
}
.zoon-wrapper.bottom {
bottom: 210px;
}
.content-container {
display: flex;
height: 100vh;
transition: all 0.3s ease;
}
.main-container {
position: relative;
flex: 1;
height: 600px;
background-color: rgb(235, 235, 235);
margin: 0 30px;
transition: height 0.3s ease, margin 0.3s ease;
}
}
.playActiveFalse {
position: absolute;
top: 50%;
left: calc(270px + 45px);
transform: translate(0, -50%) scaleX(0.6) scaleY(0.65);
transform-origin: left;
width: 100%;
} }
// Side Buttons // Side Buttons
@ -267,7 +181,6 @@
height: 18px; height: 18px;
display: flex; display: flex;
justify-content: center; justify-content: center;
// align-items: center;
background-color: var(--accent-color); background-color: var(--accent-color);
border: none; border: none;
color: var(--background-color); color: var(--background-color);
@ -307,84 +220,18 @@
} }
} }
.right.side-button-container { .right.side-button-container,
.extra-Bs {
flex-direction: column;
}
}
.left.side-button-container { .left.side-button-container {
.extra-Bs { .extra-Bs {
flex-direction: column; flex-direction: column;
} }
} }
// Theme Container .top-panel,
.theme-container { .bottom-panel {
width: 250px; .panel-content {
padding: 12px;
box-shadow: 1px -3px 4px 0px rgba(0, 0, 0, 0.11);
border-radius: 8px;
background-color: white;
position: absolute;
top: 20px;
right: -100%;
transform: translate(-0%, 0);
h2 {
font-size: 12px;
margin-bottom: 8px;
color: #2b3344;
}
.theme-preset-wrapper {
display: flex; display: flex;
gap: 5px; flex-direction: row !important;
flex-wrap: wrap;
.theme-preset {
display: flex;
gap: 2px;
margin-bottom: 10px;
border: 1px solid $border-color;
padding: 5px 10px;
border-radius: 4px;
transition: border 0.3s ease;
&.active {
border: 1px solid var(--primary-color);
&::after {
content: "";
position: absolute;
top: 1px;
left: 1px;
width: 10px;
height: 10px;
background-color: var(--primary-color);
border-radius: 50%;
}
}
}
}
.custom-color {
display: flex;
justify-content: space-between;
.color-displayer {
display: flex;
gap: 5px;
align-items: center;
border: 1px solid var(--accent-color);
border-radius: 4px;
padding: 0 5px;
input {
border: none;
outline: none;
border-radius: 50%;
}
}
} }
} }