From eb37c2f6f8c6b3970bc57610282dffc11ebb1a57 Mon Sep 17 00:00:00 2001
From: Laux Dev <2201104208@student.buksu.edu.ph>
Date: Wed, 4 Mar 2026 16:26:53 +0800
Subject: [PATCH] Added feature
---
.../src/app/components/checkbox/CheckBox.jsx | 5 +-
.../app/components/fields/styles.module.css | 10 ++++
frontend/src/app/components/icons/copy.jsx | 27 ++++++++++
frontend/src/app/organization/add/page.jsx | 5 +-
.../app/organization/add/styles.module.css | 7 +++
.../projects/view/add-from-scratch/page.jsx | 53 +++++++++++++++----
frontend/src/app/projects/view/page.jsx | 9 +++-
.../src/app/projects/view/styles.module.css | 29 ++++++++++
8 files changed, 131 insertions(+), 14 deletions(-)
create mode 100644 frontend/src/app/components/icons/copy.jsx
diff --git a/frontend/src/app/components/checkbox/CheckBox.jsx b/frontend/src/app/components/checkbox/CheckBox.jsx
index e1a10e6..bdf11ac 100644
--- a/frontend/src/app/components/checkbox/CheckBox.jsx
+++ b/frontend/src/app/components/checkbox/CheckBox.jsx
@@ -6,7 +6,7 @@ import CloseIcon from "../icons/close";
import CheckedIcon from "../icons/switchIcons/checked";
import UnCheckedIcon from "../icons/switchIcons/unchecked";
-const CustomCheckbox = ({ checked, onChange, id }) => {
+const CustomCheckbox = ({ checked, setChecked, id, ...props }) => {
const [isChecked, setIsChecked] = useState(false);
return (
<>
@@ -17,8 +17,9 @@ const CustomCheckbox = ({ checked, onChange, id }) => {
checked={checked}
onChange={() => {
setIsChecked(!isChecked);
- onChange;
+ setChecked();
}}
+ {...props}
/>
diff --git a/frontend/src/app/organization/add/styles.module.css b/frontend/src/app/organization/add/styles.module.css
index 5433706..7824d5a 100644
--- a/frontend/src/app/organization/add/styles.module.css
+++ b/frontend/src/app/organization/add/styles.module.css
@@ -89,6 +89,13 @@
box-shadow: 0 0 6px 0 rgba(0, 0, 0, 0.25);
border-radius: 100px;
background: #696b95;
+ transition: all 0.1;
+ cursor: pointer;
+}
+.addIconContainer:hover {
+ border-radius: 100px;
+ border: 1px solid #959aff;
+ background: linear-gradient(180deg, #696b95 0%, #20202d 100%);
}
.labels {
display: flex;
diff --git a/frontend/src/app/projects/view/add-from-scratch/page.jsx b/frontend/src/app/projects/view/add-from-scratch/page.jsx
index ad9d51e..2eff235 100644
--- a/frontend/src/app/projects/view/add-from-scratch/page.jsx
+++ b/frontend/src/app/projects/view/add-from-scratch/page.jsx
@@ -16,6 +16,9 @@ const AddServices = () => {
const [triggerAddVariable, setTriggerAddVariable] = useState(false);
const [triggerAddVolume, setTriggerAddVolume] = useState(false);
const [triggeAddConfigMap, setTriggerAddConfigMap] = useState(false);
+ const [disableScaling, setDisableScaling] = useState(true);
+ const [disableReadiness, setDisableReadiness] = useState(true);
+ const [disableLiveness, setDisableLiveness] = useState(true);
return (
{triggerAddVariable && (
@@ -136,7 +139,10 @@ const AddServices = () => {
Auto Scaling
-
+
setDisableScaling(!disableScaling)}
+ />
@@ -145,11 +151,17 @@ const AddServices = () => {
@@ -161,7 +173,12 @@ const AddServices = () => {
Readiness
-
+
+ setDisableReadiness(!disableReadiness)
+ }
+ />
@@ -170,11 +187,17 @@ const AddServices = () => {
@@ -186,7 +209,13 @@ const AddServices = () => {
Liveness
-
+
{
+ console.log("alsdjhfkjas");
+ setDisableLiveness(!disableLiveness);
+ }}
+ />
@@ -194,12 +223,18 @@ const AddServices = () => {
diff --git a/frontend/src/app/projects/view/page.jsx b/frontend/src/app/projects/view/page.jsx
index 2587121..c18db89 100644
--- a/frontend/src/app/projects/view/page.jsx
+++ b/frontend/src/app/projects/view/page.jsx
@@ -5,6 +5,7 @@ import TopHeader from "@/app/components/topHeader/TopHeader";
import styles from "./styles.module.css";
import AddServicesModal from "./AddServicesModal/AddServicesModal";
import { useRouter, usePathname } from "next/navigation";
+import CopyIcon from "@/app/components/icons/copy";
const AddProject = () => {
const [triggerAddServicesModal, setTriggerAddServicesModal] = useState(false);
const router = useRouter();
@@ -270,7 +271,13 @@ const AddProject = () => {
- {services.image} |
+
+
+ {services.image}
+ |
{services.ingress} |
{services.ports} |
diff --git a/frontend/src/app/projects/view/styles.module.css b/frontend/src/app/projects/view/styles.module.css
index ab3a65a..2e2466f 100644
--- a/frontend/src/app/projects/view/styles.module.css
+++ b/frontend/src/app/projects/view/styles.module.css
@@ -151,3 +151,32 @@
.iconButton:hover path {
stroke: white;
}
+.imageText {
+ transition: all 0.15s;
+ position: relative;
+}
+.tableContainer > .imageText {
+ padding: 0px;
+}
+.imageText > div {
+ display: flex;
+ padding: 4px 8px;
+ justify-content: center;
+ align-items: center;
+ gap: 4px;
+ position: absolute;
+ right: 50%;
+ top: 50%;
+ transform: translateX(50%) translateY(-50%);
+ border-radius: 100px;
+ background: #fff;
+ box-shadow: 0 0 10px 0 #000;
+ color: black;
+ opacity: 0;
+}
+.imageText > p {
+ height: 100%;
+}
+.imageText:hover > div {
+ opacity: 1;
+}
|