aboutsummaryrefslogtreecommitdiffstats
path: root/packages/meshbay-hub/src/meshbay_hub/static/photos-app.js
diff options
context:
space:
mode:
Diffstat (limited to 'packages/meshbay-hub/src/meshbay_hub/static/photos-app.js')
-rw-r--r--packages/meshbay-hub/src/meshbay_hub/static/photos-app.js13
1 files changed, 5 insertions, 8 deletions
diff --git a/packages/meshbay-hub/src/meshbay_hub/static/photos-app.js b/packages/meshbay-hub/src/meshbay_hub/static/photos-app.js
index df207ab..6dd2310 100644
--- a/packages/meshbay-hub/src/meshbay_hub/static/photos-app.js
+++ b/packages/meshbay-hub/src/meshbay_hub/static/photos-app.js
@@ -180,7 +180,7 @@ const ZOOM_MAX = 400;
const SLIDESHOW_MS = 5000;
function Lightbox({
- photos, index, transportRef, gekRef, onClose, onNav, linkFor, onDelete, onPlay,
+ photos, index, transportRef, gekRef, onClose, onNav, linkFor, onPlay,
}) {
const entry = photos[index];
// A video is shown by its thumbnail and played in the group's video
@@ -330,10 +330,6 @@ function Lightbox({
<button class="video-close" onClick=${() => copyLink(linkFor(entry))}
title=${t('link.copy')} aria-label=${t('link.copy')}>
<${Icon} name="link" /></button>`}
- ${onDelete && onDelete(entry) && html`
- <button class="video-close" onClick=${onDelete(entry)}
- title=${t('group.delete')} aria-label=${t('group.delete')}>
- <${Icon} name="trash" /></button>`}
<button class="video-close" onClick=${onClose} title=${t('video.close')}>
<${Icon} name="close" /></button>
</div>
@@ -375,8 +371,9 @@ function AlbumView({
album, entries, transportRef, gekRef, setError, onBack, readOnly, linkFor, onDelete, onPlay,
}) {
const [lightboxIndex, setLightboxIndex] = useState(null);
- // Right-click a photo for its link, or to delete it. A tile has no dots to
- // press, so on a touchscreen both are in the lightbox's bar instead.
+ // Right-click a photo, or press and hold it, for its link or to delete it.
+ // Deleting is here only: the lightbox's bar has no room left for it on a
+ // phone, where it pushed the close button off the screen.
const { menu, openAt, close: closeMenu } = useMenu();
const onTileMenu = (e, entry) => {
const link = linkFor ? linkFor(entry) : null;
@@ -442,7 +439,7 @@ function AlbumView({
<${Lightbox} photos=${album.photos} index=${lightboxIndex}
transportRef=${transportRef} gekRef=${gekRef}
onClose=${() => setLightboxIndex(null)} onNav=${navigate} linkFor=${linkFor}
- onDelete=${onDelete} onPlay=${onPlay} />
+ onPlay=${onPlay} />
`}
${menu && html`<${Menu} ...${menu} onClose=${closeMenu} />`}
`;