mirror of
https://github.com/fosrl/pangolin.git
synced 2026-03-01 00:06:38 +00:00
@@ -164,6 +164,10 @@ function MaintenanceSectionForm({
|
|||||||
return isEnterpriseNotLicensed || isSaasNotSubscribed;
|
return isEnterpriseNotLicensed || isSaasNotSubscribed;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
if (!resource.http) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<SettingsSection>
|
<SettingsSection>
|
||||||
<SettingsSectionHeader>
|
<SettingsSectionHeader>
|
||||||
@@ -437,9 +441,16 @@ export default function GeneralForm() {
|
|||||||
);
|
);
|
||||||
|
|
||||||
const resourceFullDomainName = useMemo(() => {
|
const resourceFullDomainName = useMemo(() => {
|
||||||
const url = new URL(resourceFullDomain);
|
if (!resource.fullDomain) {
|
||||||
return url.hostname;
|
return "";
|
||||||
}, [resourceFullDomain]);
|
}
|
||||||
|
try {
|
||||||
|
const url = new URL(resourceFullDomain);
|
||||||
|
return url.hostname;
|
||||||
|
} catch {
|
||||||
|
return "";
|
||||||
|
}
|
||||||
|
}, [resourceFullDomain, resource.fullDomain]);
|
||||||
|
|
||||||
const [selectedDomain, setSelectedDomain] = useState<{
|
const [selectedDomain, setSelectedDomain] = useState<{
|
||||||
domainId: string;
|
domainId: string;
|
||||||
|
|||||||
@@ -32,12 +32,6 @@ export default function ResourceInfoBox({}: ResourceInfoBoxType) {
|
|||||||
<InfoSections
|
<InfoSections
|
||||||
cols={resource.http && env.flags.usePangolinDns ? 5 : 4}
|
cols={resource.http && env.flags.usePangolinDns ? 5 : 4}
|
||||||
>
|
>
|
||||||
<InfoSection>
|
|
||||||
<InfoSectionTitle>URL</InfoSectionTitle>
|
|
||||||
<InfoSectionContent>
|
|
||||||
<CopyToClipboard text={fullUrl} isLink={true} />
|
|
||||||
</InfoSectionContent>
|
|
||||||
</InfoSection>
|
|
||||||
<InfoSection>
|
<InfoSection>
|
||||||
<InfoSectionTitle>{t("identifier")}</InfoSectionTitle>
|
<InfoSectionTitle>{t("identifier")}</InfoSectionTitle>
|
||||||
<InfoSectionContent>
|
<InfoSectionContent>
|
||||||
@@ -46,6 +40,12 @@ export default function ResourceInfoBox({}: ResourceInfoBoxType) {
|
|||||||
</InfoSection>
|
</InfoSection>
|
||||||
{resource.http ? (
|
{resource.http ? (
|
||||||
<>
|
<>
|
||||||
|
<InfoSection>
|
||||||
|
<InfoSectionTitle>URL</InfoSectionTitle>
|
||||||
|
<InfoSectionContent>
|
||||||
|
<CopyToClipboard text={fullUrl} isLink={true} />
|
||||||
|
</InfoSectionContent>
|
||||||
|
</InfoSection>
|
||||||
<InfoSection>
|
<InfoSection>
|
||||||
<InfoSectionTitle>
|
<InfoSectionTitle>
|
||||||
{t("authentication")}
|
{t("authentication")}
|
||||||
|
|||||||
Reference in New Issue
Block a user