diff --git a/autogpt_platform/frontend/src/app/(platform)/library/agents/[id]/components/NewAgentLibraryView/NewAgentLibraryView.tsx b/autogpt_platform/frontend/src/app/(platform)/library/agents/[id]/components/NewAgentLibraryView/NewAgentLibraryView.tsx
index b06901f860..f951c09522 100644
--- a/autogpt_platform/frontend/src/app/(platform)/library/agents/[id]/components/NewAgentLibraryView/NewAgentLibraryView.tsx
+++ b/autogpt_platform/frontend/src/app/(platform)/library/agents/[id]/components/NewAgentLibraryView/NewAgentLibraryView.tsx
@@ -72,7 +72,7 @@ export function NewAgentLibraryView() {
}
return (
-
+
0 ||
Object.keys(agentCredentialsInputFields || {}).length > 0;
+ const isTriggerRunType = defaultRunType.includes("trigger");
+
function handleInputChange(key: string, value: string) {
setInputValues((prev) => ({
...prev,
@@ -153,7 +155,7 @@ export function RunAgentModal({
- {!allRequiredInputsAreSet ? (
+ {isTriggerRunType ? null : !allRequiredInputsAreSet ? (
diff --git a/autogpt_platform/frontend/src/app/(platform)/library/agents/[id]/components/NewAgentLibraryView/components/other/EmptyTasks.tsx b/autogpt_platform/frontend/src/app/(platform)/library/agents/[id]/components/NewAgentLibraryView/components/other/EmptyTasks.tsx
index c0c2c900a1..62a75e4993 100644
--- a/autogpt_platform/frontend/src/app/(platform)/library/agents/[id]/components/NewAgentLibraryView/components/other/EmptyTasks.tsx
+++ b/autogpt_platform/frontend/src/app/(platform)/library/agents/[id]/components/NewAgentLibraryView/components/other/EmptyTasks.tsx
@@ -1,8 +1,14 @@
+"use client";
+
+import { getV1GetGraphVersion } from "@/app/api/__generated__/endpoints/graphs/graphs";
import { LibraryAgent } from "@/app/api/__generated__/models/libraryAgent";
import { Button } from "@/components/atoms/Button/Button";
import { Text } from "@/components/atoms/Text/Text";
import { ShowMoreText } from "@/components/molecules/ShowMoreText/ShowMoreText";
+import { useToast } from "@/components/molecules/Toast/use-toast";
+import { exportAsJSONFile } from "@/lib/utils";
import { formatDate } from "@/lib/utils/time";
+import Link from "next/link";
import { RunAgentModal } from "../modals/RunAgentModal/RunAgentModal";
import { RunDetailCard } from "../selected-views/RunDetailCard/RunDetailCard";
import { EmptyTasksIllustration } from "./EmptyTasksIllustration";
@@ -12,6 +18,30 @@ type Props = {
};
export function EmptyTasks({ agent }: Props) {
+ const { toast } = useToast();
+
+ async function handleExport() {
+ try {
+ const res = await getV1GetGraphVersion(
+ agent.graph_id,
+ agent.graph_version,
+ { for_export: true },
+ );
+ if (res.status === 200) {
+ const filename = `${agent.name}_v${agent.graph_version}.json`;
+ exportAsJSONFile(res.data as any, filename);
+ toast({ title: "Agent exported" });
+ } else {
+ toast({ title: "Failed to export agent", variant: "destructive" });
+ }
+ } catch (e: any) {
+ toast({
+ title: "Failed to export agent",
+ description: e?.message,
+ variant: "destructive",
+ });
+ }
+ }
const isPublished = Boolean(agent.marketplace_listing);
const createdAt = formatDate(agent.created_at);
const updatedAt = formatDate(agent.updated_at);
@@ -93,10 +123,15 @@ export function EmptyTasks({ agent }: Props) {
) : null}
-
diff --git a/autogpt_platform/frontend/src/app/(platform)/library/agents/[id]/components/NewAgentLibraryView/components/selected-views/AnchorLinksWrap.tsx b/autogpt_platform/frontend/src/app/(platform)/library/agents/[id]/components/NewAgentLibraryView/components/selected-views/AnchorLinksWrap.tsx
new file mode 100644
index 0000000000..6dae969142
--- /dev/null
+++ b/autogpt_platform/frontend/src/app/(platform)/library/agents/[id]/components/NewAgentLibraryView/components/selected-views/AnchorLinksWrap.tsx
@@ -0,0 +1,14 @@
+import { cn } from "@/lib/utils";
+import { AGENT_LIBRARY_SECTION_PADDING_X } from "../../helpers";
+
+type Props = {
+ children: React.ReactNode;
+};
+
+export function AnchorLinksWrap({ children }: Props) {
+ return (
+
+
+
+ );
+}
diff --git a/autogpt_platform/frontend/src/app/(platform)/library/agents/[id]/components/NewAgentLibraryView/components/selected-views/SelectedActionsWrap.tsx b/autogpt_platform/frontend/src/app/(platform)/library/agents/[id]/components/NewAgentLibraryView/components/selected-views/SelectedActionsWrap.tsx
new file mode 100644
index 0000000000..da7985e3e2
--- /dev/null
+++ b/autogpt_platform/frontend/src/app/(platform)/library/agents/[id]/components/NewAgentLibraryView/components/selected-views/SelectedActionsWrap.tsx
@@ -0,0 +1,11 @@
+type Props = {
+ children: React.ReactNode;
+};
+
+export function SelectedActionsWrap({ children }: Props) {
+ return (
+
+ {children}
+
+ );
+}
diff --git a/autogpt_platform/frontend/src/app/(platform)/library/agents/[id]/components/NewAgentLibraryView/components/selected-views/SelectedRunView/SelectedRunView.tsx b/autogpt_platform/frontend/src/app/(platform)/library/agents/[id]/components/NewAgentLibraryView/components/selected-views/SelectedRunView/SelectedRunView.tsx
index 1c7df0f680..97292b85ce 100644
--- a/autogpt_platform/frontend/src/app/(platform)/library/agents/[id]/components/NewAgentLibraryView/components/selected-views/SelectedRunView/SelectedRunView.tsx
+++ b/autogpt_platform/frontend/src/app/(platform)/library/agents/[id]/components/NewAgentLibraryView/components/selected-views/SelectedRunView/SelectedRunView.tsx
@@ -13,10 +13,11 @@ import {
import { ErrorCard } from "@/components/molecules/ErrorCard/ErrorCard";
import { PendingReviewsList } from "@/components/organisms/PendingReviewsList/PendingReviewsList";
import { usePendingReviewsForExecution } from "@/hooks/usePendingReviews";
+import { isLargeScreen, useBreakpoint } from "@/lib/hooks/useBreakpoint";
import { InfoIcon } from "@phosphor-icons/react";
import { useEffect } from "react";
-import { AGENT_LIBRARY_SECTION_PADDING_X } from "../../../helpers";
import { AgentInputsReadOnly } from "../../modals/AgentInputsReadOnly/AgentInputsReadOnly";
+import { AnchorLinksWrap } from "../AnchorLinksWrap";
import { LoadingSelectedContent } from "../LoadingSelectedContent";
import { RunDetailCard } from "../RunDetailCard/RunDetailCard";
import { RunDetailHeader } from "../RunDetailHeader/RunDetailHeader";
@@ -46,6 +47,9 @@ export function SelectedRunView({
const { run, preset, isLoading, responseError, httpError } =
useSelectedRunView(agent.graph_id, runId);
+ const breakpoint = useBreakpoint();
+ const isLgScreenUp = isLargeScreen(breakpoint);
+
const {
pendingReviews,
isLoading: reviewsLoading,
@@ -89,6 +93,15 @@ export function SelectedRunView({
+ {!isLgScreenUp ? (
+
+ ) : null}
+
{preset &&
agent.trigger_setup_info &&
preset.webhook_id &&
@@ -100,38 +113,36 @@ export function SelectedRunView({
)}
{/* Navigation Links */}
-
-
-
+ )}
+
{/* Summary Section */}
{withSummary && (
@@ -216,14 +227,16 @@ export function SelectedRunView({
-
-
-
+ {isLgScreenUp ? (
+
+
+
+ ) : null}
);
}
diff --git a/autogpt_platform/frontend/src/app/(platform)/library/agents/[id]/components/NewAgentLibraryView/components/selected-views/SelectedRunView/components/SelectedRunActions/SelectedRunActions.tsx b/autogpt_platform/frontend/src/app/(platform)/library/agents/[id]/components/NewAgentLibraryView/components/selected-views/SelectedRunView/components/SelectedRunActions/SelectedRunActions.tsx
index 7cbbd2ff09..7533577bf5 100644
--- a/autogpt_platform/frontend/src/app/(platform)/library/agents/[id]/components/NewAgentLibraryView/components/selected-views/SelectedRunView/components/SelectedRunActions/SelectedRunActions.tsx
+++ b/autogpt_platform/frontend/src/app/(platform)/library/agents/[id]/components/NewAgentLibraryView/components/selected-views/SelectedRunView/components/SelectedRunActions/SelectedRunActions.tsx
@@ -12,6 +12,7 @@ import {
StopIcon,
} from "@phosphor-icons/react";
import { AgentActionsDropdown } from "../../../AgentActionsDropdown";
+import { SelectedActionsWrap } from "../../../SelectedActionsWrap";
import { ShareRunButton } from "../../../ShareRunButton/ShareRunButton";
import { CreateTemplateModal } from "../CreateTemplateModal/CreateTemplateModal";
import { useSelectedRunActions } from "./useSelectedRunActions";
@@ -49,7 +50,7 @@ export function SelectedRunActions(props: Props) {
if (!props.run || !props.agent) return null;
return (
-
+
{!isRunning ? (
-
+
);
}
diff --git a/autogpt_platform/frontend/src/app/(platform)/library/agents/[id]/components/NewAgentLibraryView/components/selected-views/SelectedScheduleView/SelectedScheduleView.tsx b/autogpt_platform/frontend/src/app/(platform)/library/agents/[id]/components/NewAgentLibraryView/components/selected-views/SelectedScheduleView/SelectedScheduleView.tsx
index 841ff04df9..6563e19d5d 100644
--- a/autogpt_platform/frontend/src/app/(platform)/library/agents/[id]/components/NewAgentLibraryView/components/selected-views/SelectedScheduleView/SelectedScheduleView.tsx
+++ b/autogpt_platform/frontend/src/app/(platform)/library/agents/[id]/components/NewAgentLibraryView/components/selected-views/SelectedScheduleView/SelectedScheduleView.tsx
@@ -6,9 +6,10 @@ import { LoadingSpinner } from "@/components/atoms/LoadingSpinner/LoadingSpinner
import { Text } from "@/components/atoms/Text/Text";
import { ErrorCard } from "@/components/molecules/ErrorCard/ErrorCard";
import { humanizeCronExpression } from "@/lib/cron-expression-utils";
+import { isLargeScreen, useBreakpoint } from "@/lib/hooks/useBreakpoint";
import { formatInTimezone, getTimezoneDisplayName } from "@/lib/timezone-utils";
-import { AGENT_LIBRARY_SECTION_PADDING_X } from "../../../helpers";
import { AgentInputsReadOnly } from "../../modals/AgentInputsReadOnly/AgentInputsReadOnly";
+import { AnchorLinksWrap } from "../AnchorLinksWrap";
import { LoadingSelectedContent } from "../LoadingSelectedContent";
import { RunDetailCard } from "../RunDetailCard/RunDetailCard";
import { RunDetailHeader } from "../RunDetailHeader/RunDetailHeader";
@@ -41,6 +42,9 @@ export function SelectedScheduleView({
},
});
+ const breakpoint = useBreakpoint();
+ const isLgScreenUp = isLargeScreen(breakpoint);
+
function scrollToSection(id: string) {
const element = document.getElementById(id);
if (element) {
@@ -83,37 +87,42 @@ export function SelectedScheduleView({
-
-
-
-
+
+
+ {schedule && !isLgScreenUp ? (
+
+
+
+ ) : null}
{/* Navigation Links */}
-
-
-
+
+ scrollToSection("schedule")}
+ className={anchorStyles}
+ >
+ Schedule
+
+ scrollToSection("input")}
+ className={anchorStyles}
+ >
+ Your input
+
+
{/* Schedule Section */}
@@ -172,10 +181,6 @@ export function SelectedScheduleView({