import * as React from "react"; import { LinkSelectorProps } from "./types"; import { GoToUrl } from "@sc/modules/v2/Properties/components/sections/BehaviorsAndActions/subselectors"; /** * A component for collecting the page/url the user wants to link to */ const LinkSelector: React.FC = ({ onChange = () => null, onBlur = () => null, data = [ { name: "Testing Content", slug: "testing", type: "content" }, { name: "Testing Launch", slug: "testing", type: "launch" }, ], label, value, }) => { return (
{ console.log({ action, payload, linkPayload }); onChange(linkPayload.href); onBlur(linkPayload.href); }} data={data} />
); }; export default LinkSelector;