import { MetadataLicenseType } from "@hey/indexer"; import { Link } from "react-router"; import { Select, Tooltip } from "@/components/Shared/UI"; import getAssetLicense from "@/helpers/getAssetLicense"; import { usePostLicenseStore } from "@/store/non-persisted/post/usePostLicenseStore"; const LicensePicker = () => { const { license, setLicense } = usePostLicenseStore(); const otherOptions: { label: string; selected: boolean; value: MetadataLicenseType; }[] = Object.values(MetadataLicenseType) .filter((type) => getAssetLicense(type)) .map((type) => ({ label: getAssetLicense(type)?.label ?? "", selected: license === type, value: type })); const options: { label: string; selected: boolean; value: MetadataLicenseType | null; }[] = [ { label: "All rights reserved", selected: license === null, value: null }, ...otherOptions ]; return (