node-share: fix UI redirect
parent
4e6a2a1329
commit
b94e055abc
|
@ -768,6 +768,7 @@ export default defineComponent({
|
|||
data = await dav.getTagsData();
|
||||
} else if (dav.isSingleItem()) {
|
||||
data = await dav.getSingleItemData();
|
||||
this.$router.replace(utils.getViewerRoute(data[0]!.detail[0]));
|
||||
} else {
|
||||
// Try the cache
|
||||
try {
|
||||
|
|
|
@ -319,6 +319,11 @@ export default defineComponent({
|
|||
);
|
||||
},
|
||||
|
||||
/** Allow closing the viewer */
|
||||
allowClose(): boolean {
|
||||
return !this.editorOpen && !dav.isSingleItem();
|
||||
},
|
||||
|
||||
/** Get date taken string */
|
||||
currentDateTaken(): string | null {
|
||||
const date = this.currentPhoto?.imageInfo?.datetaken;
|
||||
|
@ -427,9 +432,12 @@ export default defineComponent({
|
|||
bgOpacity: 1,
|
||||
appendToEl: this.$refs.inner as HTMLElement,
|
||||
preload: [2, 2],
|
||||
clickToCloseNonZoomable: false,
|
||||
bgClickAction: "toggle-controls",
|
||||
|
||||
clickToCloseNonZoomable: false,
|
||||
pinchToClose: this.allowClose,
|
||||
closeOnVerticalDrag: this.allowClose,
|
||||
|
||||
easing: "cubic-bezier(.49,.85,.55,1)",
|
||||
showHideAnimationType: "zoom",
|
||||
showAnimationDuration: 250,
|
||||
|
|
|
@ -12,6 +12,7 @@ export async function getSingleItemData(): Promise<IDay[]> {
|
|||
return [];
|
||||
}
|
||||
|
||||
singleItem.key = singleItem.fileid;
|
||||
return [
|
||||
{
|
||||
dayid: singleItem.dayid,
|
||||
|
|
Loading…
Reference in New Issue