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