From 2906c02dd920634e9e04fd4f57fed8b01b98a26c Mon Sep 17 00:00:00 2001 From: Priyanshu1035 Date: Fri, 4 Oct 2024 19:43:43 +0530 Subject: [PATCH 1/3] addedpushbutton --- lib/CommonPushButton.tsx | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 lib/CommonPushButton.tsx diff --git a/lib/CommonPushButton.tsx b/lib/CommonPushButton.tsx new file mode 100644 index 0000000..890607f --- /dev/null +++ b/lib/CommonPushButton.tsx @@ -0,0 +1,27 @@ +import { Cylinder, Cuboid } from "jscad-fiber" + +const buttonRadius = 0.4 +const buttonHeight = 0.2 + +const baseLength = 0.8 +const baseWidth = 0.8 +const baseHeight = 0.1 + +export const PushButton = () => { + return ( + <> + + + + + ) +} From 0533d388624766340b838c95799a07b0b4212efb Mon Sep 17 00:00:00 2001 From: Priyanshu1035 Date: Tue, 8 Oct 2024 19:48:12 +0530 Subject: [PATCH 2/3] addedexample --- examples/Pushbutton.example.tsx | 10 ++++++++++ lib/{CommonPushButton.tsx => PushButton.tsx} | 0 2 files changed, 10 insertions(+) create mode 100644 examples/Pushbutton.example.tsx rename lib/{CommonPushButton.tsx => PushButton.tsx} (100%) diff --git a/examples/Pushbutton.example.tsx b/examples/Pushbutton.example.tsx new file mode 100644 index 0000000..12366fa --- /dev/null +++ b/examples/Pushbutton.example.tsx @@ -0,0 +1,10 @@ +import { PushButton } from "../lib/PushButton"; +import { JsCadFixture } from "jscad-fiber"; + +export default () => { + return ( + + + + ); +}; diff --git a/lib/CommonPushButton.tsx b/lib/PushButton.tsx similarity index 100% rename from lib/CommonPushButton.tsx rename to lib/PushButton.tsx From 2544b39b07971c6ef9ac49ff0c6a09c5635a7f88 Mon Sep 17 00:00:00 2001 From: Priyanshu1035 Date: Wed, 9 Oct 2024 11:11:29 +0530 Subject: [PATCH 3/3] addedpins --- lib/PushButton.tsx | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/lib/PushButton.tsx b/lib/PushButton.tsx index 890607f..86f97bb 100644 --- a/lib/PushButton.tsx +++ b/lib/PushButton.tsx @@ -7,6 +7,9 @@ const baseLength = 0.8 const baseWidth = 0.8 const baseHeight = 0.1 +const pinRadius = 0.05 +const pinHeight = 0.1 + export const PushButton = () => { return ( <> @@ -22,6 +25,31 @@ export const PushButton = () => { offset={[0, 0, baseHeight / 2]} color="#ccc" /> + + + + + ) }