MCPcopy Create free account
hub / github.com/triggerdotdev/jsonhero-web / ExampleUrl

Function ExampleUrl

app/components/ExampleUrl.tsx:3–28  ·  view source on GitHub ↗
({
  url,
  title,
  displayTitle,
}: {
  url: string;
  title: string;
  displayTitle?: string;
})

Source from the content-addressed store, hash-verified

1import { Form } from "remix";
2
3export function ExampleUrl({
4 url,
5 title,
6 displayTitle,
7}: {
8 url: string;
9 title: string;
10 displayTitle?: string;
11}) {
12 return (
13 <Form
14 method="post"
15 action="/actions/createFromUrl?utm_source=example_url"
16 reloadDocument
17 >
18 <input type="hidden" name="jsonUrl" value={url} />
19 <input type="hidden" name="title" value={title} />
20 <button
21 type="submit"
22 className="bg-slate-900 px-4 py-2 rounded-md whitespace-nowrap text-lime-300 transition hover:text-lime-500"
23 >
24 {displayTitle ?? title}
25 </button>
26 </Form>
27 );
28}

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected