MCPcopy Index your code
hub / github.com/coder/coder / TaskPromptLoadingError

Function TaskPromptLoadingError

site/src/modules/tasks/TaskPrompt/TaskPrompt.tsx:85–102  ·  view source on GitHub ↗
({ error, onRetry })

Source from the content-addressed store, hash-verified

83 error: unknown;
84 onRetry: () => void;
85}> = ({ error, onRetry }) => {
86 return (
87 <div className="border border-solid rounded-lg w-full min-h-80 flex items-center justify-center">
88 <div className="flex flex-col items-center">
89 <h3 className="m-0 font-medium text-content-primary text-base">
90 {getErrorMessage(error, "Error loading Task templates")}
91 </h3>
92 <span className="text-content-secondary text-sm">
93 {getErrorDetail(error) ?? "Please try again"}
94 </span>
95 <Button size="sm" onClick={onRetry} className="mt-4">
96 <RotateCcwIcon />
97 Try again
98 </Button>
99 </div>
100 </div>
101 );
102};
103
104const TaskPromptSkeleton: FC = () => {
105 return (

Callers

nothing calls this directly

Calls 2

getErrorMessageFunction · 0.90
getErrorDetailFunction · 0.90

Tested by

no test coverage detected