viewer: hide controls on public share
parent
139136d3c0
commit
2dc38dee26
|
@ -20,15 +20,16 @@
|
||||||
container=".memories_viewer .pswp"
|
container=".memories_viewer .pswp"
|
||||||
>
|
>
|
||||||
<NcActionButton
|
<NcActionButton
|
||||||
|
v-if="canShare"
|
||||||
:aria-label="t('memories', 'Share')"
|
:aria-label="t('memories', 'Share')"
|
||||||
@click="shareCurrent"
|
@click="shareCurrent"
|
||||||
:close-after-click="true"
|
:close-after-click="true"
|
||||||
v-if="canShare"
|
|
||||||
>
|
>
|
||||||
{{ t("memories", "Share") }}
|
{{ t("memories", "Share") }}
|
||||||
<template #icon> <ShareIcon :size="24" /> </template>
|
<template #icon> <ShareIcon :size="24" /> </template>
|
||||||
</NcActionButton>
|
</NcActionButton>
|
||||||
<NcActionButton
|
<NcActionButton
|
||||||
|
v-if="!routeIsPublic"
|
||||||
:aria-label="t('memories', 'Delete')"
|
:aria-label="t('memories', 'Delete')"
|
||||||
@click="deleteCurrent"
|
@click="deleteCurrent"
|
||||||
:close-after-click="true"
|
:close-after-click="true"
|
||||||
|
@ -37,6 +38,7 @@
|
||||||
<template #icon> <DeleteIcon :size="24" /> </template>
|
<template #icon> <DeleteIcon :size="24" /> </template>
|
||||||
</NcActionButton>
|
</NcActionButton>
|
||||||
<NcActionButton
|
<NcActionButton
|
||||||
|
v-if="!routeIsPublic"
|
||||||
:aria-label="t('memories', 'Favorite')"
|
:aria-label="t('memories', 'Favorite')"
|
||||||
@click="favoriteCurrent"
|
@click="favoriteCurrent"
|
||||||
:close-after-click="true"
|
:close-after-click="true"
|
||||||
|
@ -48,6 +50,7 @@
|
||||||
</template>
|
</template>
|
||||||
</NcActionButton>
|
</NcActionButton>
|
||||||
<NcActionButton
|
<NcActionButton
|
||||||
|
v-if="!routeIsPublic"
|
||||||
:aria-label="t('memories', 'Sidebar')"
|
:aria-label="t('memories', 'Sidebar')"
|
||||||
@click="toggleSidebar"
|
@click="toggleSidebar"
|
||||||
:close-after-click="true"
|
:close-after-click="true"
|
||||||
|
@ -58,8 +61,8 @@
|
||||||
</template>
|
</template>
|
||||||
</NcActionButton>
|
</NcActionButton>
|
||||||
<NcActionButton
|
<NcActionButton
|
||||||
|
v-if="canEdit && !routeIsPublic"
|
||||||
:aria-label="t('memories', 'Edit')"
|
:aria-label="t('memories', 'Edit')"
|
||||||
v-if="canEdit"
|
|
||||||
@click="openEditor"
|
@click="openEditor"
|
||||||
:close-after-click="true"
|
:close-after-click="true"
|
||||||
>
|
>
|
||||||
|
@ -79,6 +82,7 @@
|
||||||
</template>
|
</template>
|
||||||
</NcActionButton>
|
</NcActionButton>
|
||||||
<NcActionButton
|
<NcActionButton
|
||||||
|
v-if="!routeIsPublic"
|
||||||
:aria-label="t('memories', 'View in folder')"
|
:aria-label="t('memories', 'View in folder')"
|
||||||
@click="viewInFolder"
|
@click="viewInFolder"
|
||||||
:close-after-click="true"
|
:close-after-click="true"
|
||||||
|
@ -195,6 +199,11 @@ export default class Viewer extends Mixins(GlobalMixin) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/** Route is public */
|
||||||
|
get routeIsPublic() {
|
||||||
|
return this.$route.name === "folder-share";
|
||||||
|
}
|
||||||
|
|
||||||
/** Update the document title */
|
/** Update the document title */
|
||||||
private updateTitle(photo: IPhoto | undefined) {
|
private updateTitle(photo: IPhoto | undefined) {
|
||||||
if (!this.originalTitle) {
|
if (!this.originalTitle) {
|
||||||
|
|
Loading…
Reference in New Issue