Skip to content

Commit

Permalink
feat(welcome-guide): 💥 add welcome guide
Browse files Browse the repository at this point in the history
  • Loading branch information
gokhangunduz committed Sep 19, 2023
1 parent 62d90d0 commit 13a3003
Show file tree
Hide file tree
Showing 5 changed files with 42 additions and 1 deletion.
14 changes: 14 additions & 0 deletions public/css/style.css
Original file line number Diff line number Diff line change
Expand Up @@ -1457,6 +1457,20 @@ video {
transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));
}

.scale-105 {
--tw-scale-x: 1.05;
--tw-scale-y: 1.05;
-webkit-transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));
transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));
}

.scale-110 {
--tw-scale-x: 1.1;
--tw-scale-y: 1.1;
-webkit-transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));
transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));
}

.transform {
-webkit-transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));
transform: translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));
Expand Down
5 changes: 4 additions & 1 deletion src/components/RobotHeaderTabs/RobotHeaderTabs.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,10 @@ export default function RobotHeaderTabs(): ReactElement {
isSettedCookie
),
isHidden:
envOnPremiseRobot || (responseRobot && !responseRobot?.bridgeEnabled),
// hidden for now
true ||
envOnPremiseRobot ||
(responseRobot && !responseRobot?.bridgeEnabled),
},
{
name: "Teleoperation",
Expand Down
15 changes: 15 additions & 0 deletions src/components/WelcomeGuide/WelcomeGuide.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
import React, { ReactElement } from "react";

export default function WelcomeGuide(): ReactElement {
return (
<div className="flex flex-col items-center text-center gap-2">
<img className="w-40 scale-110" src="/images/rocket.svg" alt="logo" />
<h3 className="text-xl font-semibold ">Welcome to Robolaunch</h3>
<p>
robolaunch is a Cloud-Native Robotics Platform that provides the
end-to-end infrastructure, software stack and tools for developing,
simulating, deploying and operating ROS/ROS2 robots at scale.
</p>{" "}
</div>
);
}
8 changes: 8 additions & 0 deletions src/functions/handleGuide.tsx
Original file line number Diff line number Diff line change
@@ -1,11 +1,19 @@
import GuideContainer from "../components/GuideContainer/GuideContainer";
import WelcomeGuide from "../components/WelcomeGuide/WelcomeGuide";
import { envOnPremiseFleet, envOnPremiseRobot } from "../helpers/envProvider";

export function getGuideItem(guide: string) {
switch (guide) {
case "welcome":
return {
selector: guide,
content: () => <WelcomeGuide />,
};

case '[data-tut="marketplace-sidebar-menu-item"]':
return {
selector: guide,
position: "center",
content: () => (
<GuideContainer
title="Marketplace"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -111,6 +111,7 @@ export default function MainDashboardPage(): ReactElement {
<TourGuide
type="main"
tourConfig={[
getGuideItem("welcome"),
getGuideItem('[data-tut="organization-sidebar-menu-item"]'),
getGuideItem('[data-tut="roboticscloud-sidebar-menu-item"]'),
getGuideItem('[data-tut="instance-sidebar-menu-item"]'),
Expand Down

0 comments on commit 13a3003

Please sign in to comment.