feat(ui): add desktop footer, legal custom link and about dialog
This commit is contained in:
1 parent
bc7bdc481e
commit
c181ffea54
12 files changed
+179
-13
No files matched your search
@@ -28,7 +28,9 @@ export const LegalLinks: React.FC<LegalLinksProps> = ({ legal, className = '', c
|
||||
}))
|
||||
.filter((e) => e.url || e.hasContent);
|
||||
|
||||
if (entries.length === 0 && !children) return null;
|
||||
const customHref = legal?.customLinkUrl && safeHref(legal.customLinkUrl);
|
||||
|
||||
if (entries.length === 0 && !children && !customHref) return null;
|
||||
|
||||
const openText = async (type: LegalType) => {
|
||||
setError(null);
|
||||
@@ -52,6 +54,16 @@ export const LegalLinks: React.FC<LegalLinksProps> = ({ legal, className = '', c
|
||||
</button>
|
||||
)
|
||||
)}
|
||||
{customHref && (
|
||||
<a
|
||||
href={customHref as string}
|
||||
target="_blank"
|
||||
rel="noopener noreferrer"
|
||||
className="hover:text-main underline-offset-2 hover:underline"
|
||||
>
|
||||
{legal?.customLinkLabel || legal?.customLinkUrl}
|
||||
</a>
|
||||
)}
|
||||
{children}
|
||||
{error && <span className="text-status-err">{error}</span>}
|
||||
{open && (
|
||||
|
||||
Reference in new issue
Block a user