diff --git a/app/globals.css b/app/globals.css
index df674ea..a8c214d 100644
--- a/app/globals.css
+++ b/app/globals.css
@@ -10,7 +10,7 @@
--card-foreground: 240 10% 3.9%;
--popover: 0 0% 100%;
--popover-foreground: 240 10% 3.9%;
- --primary: 240 5.9% 10%;
+ --primary: 201 100% 38%;
--primary-foreground: 0 0% 98%;
--secondary: 240 4.8% 95.9%;
--secondary-foreground: 240 5.9% 10%;
diff --git a/app/layout.tsx b/app/layout.tsx
index 6b51d27..96565d5 100644
--- a/app/layout.tsx
+++ b/app/layout.tsx
@@ -56,8 +56,6 @@ export default function RootLayout({
}>) {
return (
-
-
{children}
-
+
{/* */}
@@ -79,4 +77,4 @@ export default function RootLayout({
);
-}
+}
\ No newline at end of file
diff --git a/components/Script.tsx b/components/Script.tsx
index 6866b4b..7727b0b 100644
--- a/components/Script.tsx
+++ b/components/Script.tsx
@@ -32,7 +32,40 @@ function ScriptItem() {
function handleCopy(type: string, value: any) {
navigator.clipboard.writeText(value);
- toast(
+
+ let amountOfScriptsCopied = localStorage.getItem("amountOfScriptsCopied");
+
+ if (amountOfScriptsCopied === null) {
+ localStorage.setItem("amountOfScriptsCopied", "1");
+ } else if (parseInt(amountOfScriptsCopied) >= 3) {
+ ""
+ } else {
+ amountOfScriptsCopied = (parseInt(amountOfScriptsCopied) + 1).toString();
+ localStorage.setItem("amountOfScriptsCopied", amountOfScriptsCopied);
+
+ if (parseInt(amountOfScriptsCopied) === 3) {
+ setTimeout(() => {
+ toast.info(
+
+
+ If you find these scripts useful, please consider starring the
+ repository on GitHub. It helps a lot!
+
+
+
+
+ Star on GitHub 💫
+
+
+
+
,
+ { duration: 8000 },
+ );
+ }, 500);
+ }
+ }
+
+ toast.success(
Copied {type} to clipboard
@@ -40,6 +73,7 @@ function ScriptItem() {
);
}
+
function closeScript() {
// remove the id from the url and reset the state
window.history.pushState({}, document.title, window.location.pathname);