Add configurable theme colours to filesystem

This commit is contained in:
2024-09-05 14:58:26 +02:00
parent 41a157ae9e
commit 04efcb6505
9 changed files with 81 additions and 18 deletions

View File

@@ -27,7 +27,7 @@ export const copy_link = () => {
setTimeout(() => {link_copied = false}, 60000)
}
let share = async () => {
if (share_url === "") {
if (share_url === "" || navigator.share === undefined) {
edit_window.edit(nav.base, true, "share")
return
}
@@ -114,7 +114,8 @@ let expand = e => {
</button>
{/if}
{#if $nav.base.id !== "me"}
<!-- Share button is enabled when: The browser has a sharing API, or the user can edit the file (to enable sharing)-->
{#if $nav.base.id !== "me" && (navigator.share !== undefined || $nav.permissions.update === true)}
<button on:click={share}>
<i class="icon">share</i>
<span>Share</span>