diff --git a/components/dashboard/src/components/ContextMenu.tsx b/components/dashboard/src/components/ContextMenu.tsx index 194070519ad2c8..55d955c6f07e70 100644 --- a/components/dashboard/src/components/ContextMenu.tsx +++ b/components/dashboard/src/components/ContextMenu.tsx @@ -184,7 +184,7 @@ export const MenuEntry: FunctionComponent = ({ customFontStyle || "text-gray-600 dark:text-gray-400 hover:text-gray-800 dark:hover:text-gray-100", { "cursor-pointer hover:bg-gray-100 dark:hover:bg-gray-700": clickable, - "bg-gray-50 dark:bg-gray-800": active, + "bg-pk-surface-secondary": active, "rounded-t-lg": isFirst, "rounded-b-lg": isLast, "border-b border-gray-200 dark:border-gray-800": separator, diff --git a/components/dashboard/src/components/EmptyMessage.tsx b/components/dashboard/src/components/EmptyMessage.tsx index 7a773d82419571..4da20218788e6c 100644 --- a/components/dashboard/src/components/EmptyMessage.tsx +++ b/components/dashboard/src/components/EmptyMessage.tsx @@ -5,7 +5,7 @@ */ import classNames from "classnames"; -import { FC, ReactNode, useCallback } from "react"; +import { FC, ReactNode } from "react"; import { Button } from "@podkit/buttons/Button"; import { Heading2, Subheading } from "./typography/headings"; @@ -17,20 +17,17 @@ type Props = { className?: string; }; export const EmptyMessage: FC = ({ title, subtitle, buttonText, onClick, className }) => { - const handleClick = useCallback(() => { - onClick && onClick(); - }, [onClick]); return (
- {title && {title}} + {title && {title}} {subtitle && {subtitle}} - {buttonText && } + {buttonText && }
); diff --git a/components/dashboard/src/components/ItemsList.tsx b/components/dashboard/src/components/ItemsList.tsx index 3457f31e57fe02..285a91d95127d2 100644 --- a/components/dashboard/src/components/ItemsList.tsx +++ b/components/dashboard/src/components/ItemsList.tsx @@ -4,6 +4,7 @@ * See License.AGPL.txt in the project root for license information. */ +import { cn } from "@podkit/lib/cn"; import ContextMenu, { ContextMenuEntry } from "./ContextMenu"; export function ItemsList(props: { children?: React.ReactNode; className?: string }) { @@ -18,14 +19,17 @@ export function Item(props: { children?: React.ReactNode; className?: string; he } // cursor-pointer hover:bg-gray-100 dark:hover:bg-gray-700 - const solidClassName = props.solid ? "bg-gray-100 dark:bg-gray-800" : "hover:bg-gray-100 dark:hover:bg-gray-800"; + const solidClassName = props.solid ? "bg-pk-surface-secondary" : "hover:bg-gray-100 dark:hover:bg-gray-800"; const headerClassName = "text-sm text-gray-400 border-t border-b border-gray-200 dark:border-gray-800"; const notHeaderClassName = "rounded-xl focus:bg-kumquat-light " + solidClassName; return (
{props.children}
@@ -50,9 +54,11 @@ export function ItemFieldContextMenu(props: { return (
diff --git a/components/dashboard/src/components/PrebuildLogs.tsx b/components/dashboard/src/components/PrebuildLogs.tsx index e2a9cd21c25980..1a0c3b1830fbf8 100644 --- a/components/dashboard/src/components/PrebuildLogs.tsx +++ b/components/dashboard/src/components/PrebuildLogs.tsx @@ -171,7 +171,7 @@ export default function PrebuildLogs(props: PrebuildLogsProps) { }, [logsEmitter, props.workspaceId, workspace?.instanceId, workspace?.phase]); return ( -
+
}>
-
+
{prebuild && }
{props.children} diff --git a/components/dashboard/src/components/UsageBasedBillingConfig.tsx b/components/dashboard/src/components/UsageBasedBillingConfig.tsx index 8f8995237db163..c8a95a358903d8 100644 --- a/components/dashboard/src/components/UsageBasedBillingConfig.tsx +++ b/components/dashboard/src/components/UsageBasedBillingConfig.tsx @@ -240,21 +240,21 @@ export default function UsageBasedBillingConfig({ hideSubheading = false }: Prop )} {showSpinner && ( -
-
Balance
+
+
Balance
)} {showBalance && ( -
-
Balance
+
+
Balance
{balance.toLocaleString(undefined, { maximumFractionDigits: 2 })} - Credits + Credits
-
+
{typeof currentUsage === "number" && typeof usageLimit === "number" && @@ -273,10 +273,10 @@ export default function UsageBasedBillingConfig({ hideSubheading = false }: Prop
-
+
-
Current Period
-
+
Current Period
+
{billingCycleFrom.format("MMM D, YYYY")} {" "} @@ -302,29 +302,27 @@ export default function UsageBasedBillingConfig({ hideSubheading = false }: Prop )} {showUpgradeTeam && ( <> -
-
Current Plan
-
+
+
Current Plan
+
{freePlanName}
-
+
- - {usageLimit} credits - + {usageLimit} credits {usageLimit / 10} hours of Standard workspace usage.
-
-
Upgrade Plan
-
+
+
Upgrade Plan
+
Pay-as-you-go
-
+
{priceInformation}
@@ -346,12 +344,12 @@ export default function UsageBasedBillingConfig({ hideSubheading = false }: Prop )} {showManageBilling && (
-
-
Current Plan
-
+
+
Current Plan
+
Pay-as-you-go
-
+
{priceInformation} diff --git a/components/dashboard/src/components/typography/headings.tsx b/components/dashboard/src/components/typography/headings.tsx index e9631a0e0eefe7..b45a41cabde121 100644 --- a/components/dashboard/src/components/typography/headings.tsx +++ b/components/dashboard/src/components/typography/headings.tsx @@ -4,7 +4,7 @@ * See License.AGPL.txt in the project root for license information. */ -import classNames from "classnames"; +import { cn } from "@podkit/lib/cn"; import { FC } from "react"; type HeadingProps = { @@ -18,8 +18,8 @@ export const Heading1: FC = ({ id, color, tracking, className, chi return (

= ({ id, color, tracking, className, chi return (

{children}

@@ -45,7 +45,7 @@ export const Heading3: FC = ({ id, color, tracking, className, chi return (

{children}

@@ -55,16 +55,12 @@ export const Heading3: FC = ({ id, color, tracking, className, chi // Intended to be placed beneath a heading to provide more context export const Subheading: FC = ({ id, tracking, className, children }) => { return ( -

+

{children}

); }; -function getHeadingColor(color: HeadingProps["color"] = "dark") { - return color === "dark" ? "text-gray-800 dark:text-gray-100" : "text-gray-500 dark:text-gray-400"; -} - function getTracking(tracking: HeadingProps["tracking"]) { if (tracking === "wide") { return "tracking-wide"; diff --git a/components/dashboard/src/feedback-form/FeedbackComponent.tsx b/components/dashboard/src/feedback-form/FeedbackComponent.tsx index ac23fc6369d45a..955ed8db79b341 100644 --- a/components/dashboard/src/feedback-form/FeedbackComponent.tsx +++ b/components/dashboard/src/feedback-form/FeedbackComponent.tsx @@ -84,7 +84,7 @@ function FeedbackComponent(props: {