Skip to content
This repository was archived by the owner on Sep 30, 2025. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion src/assets/icons/iconist/README.md

This file was deleted.

3 changes: 0 additions & 3 deletions src/assets/icons/iconist/search_iconist.svg

This file was deleted.

Binary file added src/assets/icons/macStyle.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added src/assets/icons/winStyle.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 2 additions & 0 deletions src/main.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ import CauseError from "./screens/ErrorBoundary/CauseError";
import UpdateAvailable from "./screens/App/updateChecker/UpdateAvailable";
import JenkinsConnectionFailedView from "./screens/App/JenkinsConnectionChecker/JenkinsConnectionFailedView";
import FullConsoleLog from "./screens/Jarvis/Views/ConsoleView/FullConsoleLogView";
import OnboardingStep4 from "./screens/Onboarding/OnboardingStep4";

function AppContainer() {
return (
Expand All @@ -33,6 +34,7 @@ function AppContainer() {
<Route path="/onboarding/step_1" element={<OnboardingStep1 />} />
<Route path="/onboarding/step_2" element={<OnboardingStep2 />} />
<Route path="/onboarding/step_3" element={<OnboardingStep3 />} />
<Route path="/onboarding/step_4" element={<OnboardingStep4 />} />
<Route path="/onboarding/complete" element={<OnboardingComplete />} />
<Route path="/updateAvailable" element={<UpdateAvailable />} />
<Route path="/jenkinsUnavailable" element={<JenkinsConnectionFailedView />} />
Expand Down
26 changes: 13 additions & 13 deletions src/screens/Onboarding/OnboardingStep1.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -48,25 +48,25 @@ const OnboardingStep1: React.FC = () => {
});
return;
}

if (username === "") {
notification.showNotification("Invalid Username", "Please check again.", "error", {
soundOn: true,
soundType: "error",
});
return;
}

if (apiToken === "") {
notification.showNotification("Invalid API Token", "Please check again.", "error", {
soundOn: true,
soundType: "error",
});
return;
}

const response = await checkAuthentication(baseUrl, username, apiToken);

if (response === false) {
notification.showNotification("Authentication failed", "Please check your Credentials.", "error", {
soundOn: true,
Expand Down Expand Up @@ -106,7 +106,7 @@ const OnboardingStep1: React.FC = () => {
transition={{ duration: 0.5, delay: 0.5 }}
>
<label htmlFor="baseUrl" className="block text-sm font-medium text-comment-color">
Base URL
Base URL
</label>
<input
type="url"
Expand All @@ -126,7 +126,7 @@ const OnboardingStep1: React.FC = () => {
>
<div className="flex flex-row">
<label htmlFor="userName" className="block text-sm font-medium text-comment-color">
User Name
User Name
</label>
</div>
<input
Expand All @@ -146,7 +146,7 @@ const OnboardingStep1: React.FC = () => {
transition={{ duration: 0.5, delay: 1.5 }}
>
<label htmlFor="apitoken" className="block text-sm font-medium text-comment-color">
API Token
API Token
</label>
<input
type="password"
Expand All @@ -172,15 +172,15 @@ const OnboardingStep1: React.FC = () => {
}
}}
>
Continue
Continue
</motion.button>

{/* Help Modal */}
<p
onClick={() => setShowHelpModal(true)}
className="absolute bottom-4 right-8 text-sm text-comment-color transition hover:brightness-75 active:brightness-90"
>
Need help?
Need help?
</p>

{showHelpModal && (
Expand Down Expand Up @@ -221,16 +221,16 @@ const OnboardingStep1: React.FC = () => {
<div className="ml-4 text-comment-color">
<p>You can create an API Token by goint to</p>
<p>
Profile
Profile
{">"}
{" "}
Configure
Configure
{">"}
{" "}
API Token
API Token
{">"}
{" "}
Add new Token
Add new Token
</p>
</div>
</details>
Expand Down
56 changes: 41 additions & 15 deletions src/screens/Onboarding/OnboardingStep3.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,33 +6,59 @@ import "./Onboarding.css";
import { useNavigate } from "react-router-dom";
import { motion } from "framer-motion";

import macStyle from "@assets/icons/macStyle.png"
import windowsStyle from "@assets/icons/winStyle.png"
import StorageManager from "@/helpers/StorageManager";

const OnboardingStep3: React.FC = () => {
const navigate = useNavigate();
const [titlebarStyle, setTitlebarStyle] = React.useState("");

useEffect(() => {
// Set screen size to 300px width and 400px height
const size = new LogicalSize(700, 550);
appWindow.setSize(size).then(() => appWindow.center());
const init = async () => {
// Set screen size to 300px width and 400px height
const size = new LogicalSize(700, 550);
appWindow.setSize(size).then(() => appWindow.center());

const titlebarStyle = await StorageManager.get("titlebarStyle")
setTitlebarStyle(titlebarStyle || "macStyle")
}

init()
}, []);

const setTitlebarStyleAndSave = async (style: string) => {
await StorageManager.save("titlebarStyle", style)
setTitlebarStyle(style)
}

const continueOnboarding = async () => {
navigate("/onboarding/complete");
navigate("/onboarding/step_4");
};

return (
<div className="flex flex-col bg-background-view items-center justify-center h-screen select-none">
<img src={icon} alt="Welcome icon" className="absolute top-8 w-8 h-8" />
<p className="absolute top-24 font-medium text-xl">Selected Titlebar Style</p>
<div className="flex flex-row w-[85%] space-x-4">
<div
onClick={() => setTitlebarStyleAndSave("macStyle")}
className={`w-2/3 rounded-xl space-y-2 onboarding-custom-scroll border-border border-2 min-h-[200px] transition hover:bg-background-card-selected ${titlebarStyle === "macStyle" ? "bg-background-card-selected" : ""}`}
style={{
backgroundImage: `url(${macStyle})`,
backgroundSize: "cover",
}}>
</div>
<div
onClick={() => setTitlebarStyleAndSave("winStyle")}
className={`w-2/3 rounded-xl space-y-2 onboarding-custom-scroll border-border border-2 min-h-[200px] transition hover:bg-background-card-selected ${titlebarStyle === "winStyle" ? "bg-background-card-selected" : ""}`}
style={{
backgroundImage: `url(${windowsStyle})`,
backgroundSize: "cover",
}}>
</div>
</div>

<motion.iframe
initial={{ opacity: 0 }}
animate={{ opacity: 1 }}
transition={{ duration: 0.5, delay: 0.5 }}
width="560"
height="315"
src="https://www.youtube.com/embed/mi6j6CIPRcw?si=3VmTzPpG1XajLKPp"
title="YouTube video player"
allow="autoplay"
/>

<motion.button
initial={{ opacity: 0 }}
Expand All @@ -46,7 +72,7 @@ const OnboardingStep3: React.FC = () => {
}
}}
>
Continue
Continue
</motion.button>
</div>
);
Expand Down
55 changes: 55 additions & 0 deletions src/screens/Onboarding/OnboardingStep4.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
import React, { useEffect } from "react";
import { appWindow, LogicalSize } from "@tauri-apps/api/window";
import icon from "../../assets/brand/ico_bow.svg";

import "./Onboarding.css";
import { useNavigate } from "react-router-dom";
import { motion } from "framer-motion";

const OnboardingStep4: React.FC = () => {
const navigate = useNavigate();

useEffect(() => {
// Set screen size to 300px width and 400px height
const size = new LogicalSize(700, 550);
appWindow.setSize(size).then(() => appWindow.center());
}, []);

const continueOnboarding = async () => {
navigate("/onboarding/complete");
};

return (
<div className="flex flex-col bg-background-view items-center justify-center h-screen select-none">
<img src={icon} alt="Welcome icon" className="absolute top-8 w-8 h-8" />

<motion.iframe
initial={{ opacity: 0 }}
animate={{ opacity: 1 }}
transition={{ duration: 0.5, delay: 0.5 }}
width="560"
height="315"
src="https://www.youtube.com/embed/mi6j6CIPRcw?si=3VmTzPpG1XajLKPp"
title="YouTube video player"
allow="autoplay"
/>

<motion.button
initial={{ opacity: 0 }}
animate={{ opacity: 1 }}
transition={{ duration: 0.5, delay: 1 }}
className="button absolute bottom-[35px]"
onClick={() => continueOnboarding()}
onKeyPress={(e) => {
if (e.key === "Enter") {
continueOnboarding();
}
}}
>
Continue
</motion.button>
</div>
);
};

export default OnboardingStep4;
3 changes: 3 additions & 0 deletions tailwind.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,9 @@ export default {
class: {
"big-sidebar": "bg-red-200",
},
backgroundImage: {
"windowStyleIcons": "url('/assets/images/windowStyleIcons.png')",
}
},
},
plugins: [],
Expand Down