From 664184915e7c4076e87191c5059aae3ac572dd21 Mon Sep 17 00:00:00 2001 From: Lucas Oliveira Date: Wed, 5 Jun 2024 16:01:32 -0300 Subject: [PATCH] Added shadow to node --- src/frontend/src/customNodes/genericNode/index.tsx | 4 +++- src/frontend/src/style/applies.css | 2 +- src/frontend/tailwind.config.js | 1 + 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/src/frontend/src/customNodes/genericNode/index.tsx b/src/frontend/src/customNodes/genericNode/index.tsx index 89fb6166d..066798df0 100644 --- a/src/frontend/src/customNodes/genericNode/index.tsx +++ b/src/frontend/src/customNodes/genericNode/index.tsx @@ -339,7 +339,9 @@ export default function GenericNode({ }; const getBaseBorderClass = (selected) => { - let className = selected ? "border border-ring" : "border"; + let className = selected + ? "border border-ring shadow-node" + : "border hover:shadow-node"; let frozenClass = selected ? "border-ring-frozen" : "border-frozen"; return data.node?.frozen ? frozenClass : className; }; diff --git a/src/frontend/src/style/applies.css b/src/frontend/src/style/applies.css index 07ab9b592..920351836 100644 --- a/src/frontend/src/style/applies.css +++ b/src/frontend/src/style/applies.css @@ -330,7 +330,7 @@ @apply grid w-full gap-4 p-4 md:grid-cols-2 lg:grid-cols-4; } .generic-node-div { - @apply relative flex flex-col justify-center bg-background; + @apply relative flex flex-col justify-center bg-background transition-all; } .generic-node-div-title { @apply flex w-full items-center gap-2 border-b bg-muted p-4; diff --git a/src/frontend/tailwind.config.js b/src/frontend/tailwind.config.js index ee6413292..6f99f7b58 100644 --- a/src/frontend/tailwind.config.js +++ b/src/frontend/tailwind.config.js @@ -143,6 +143,7 @@ module.exports = { }, boxShadow: { "frozen-ring": "0 0 10px 2px rgba(128, 190, 230, 0.5)", + node: "0 0px 15px -3px rgb(0 0 0 / 0.1), 0 0px 6px -4px rgb(0 0 0 / 0.1);", "frosted-ring": "0 0 10px 2px rgba(128, 190, 230, 0.7)", }, backdropBlur: {