Gate shares behind magic-link sessions, add comments and new-photo email digests
This commit is contained in:
@@ -3,7 +3,7 @@
|
||||
// top-level `let`s. Layout / scroll-tuning constants live here too because
|
||||
// they are read by multiple modules. SVG icon strings live in `icons.ts`.
|
||||
|
||||
import type { GalleryItem, LightboxConfig, MetadataConfig, GroupByDateMode } from '../shared/types.js'
|
||||
import type { CommentsConfig, GalleryItem, LightboxConfig, MetadataConfig, GroupByDateMode } from '../shared/types.js'
|
||||
|
||||
// ----- layout / scroll tuning ----------------------------------------------
|
||||
|
||||
@@ -28,6 +28,8 @@ export const LONG_PRESS_MS = 500
|
||||
export const SIDEBAR_STORAGE_KEY = 'ipp-sidebar-open'
|
||||
// Width of the sidebar when docked (must match the CSS rule)
|
||||
export const SIDEBAR_WIDTH = 360
|
||||
// Height of the sidebar as a bottom sheet, as a fraction of the viewport (must match the CSS 60vh)
|
||||
export const SIDEBAR_SHEET_FRACTION = 0.6
|
||||
|
||||
// ----- mutable state -------------------------------------------------------
|
||||
|
||||
@@ -95,6 +97,8 @@ export const state = {
|
||||
sidebarOpen: false,
|
||||
// Base URL (`/share/meta/<key>`) for the on-demand per-asset metadata route.
|
||||
metaBase: '',
|
||||
// Comments API and per-photo counts; null when commenting isn't available
|
||||
comments: null as CommentsConfig | null,
|
||||
// Re-render callbacks registered by lightbox UI elements (sidebar, caption,
|
||||
// download button). Each re-renders for the current slide. Invoked after a
|
||||
// lazy item's detail arrives so the just-opened slide reflects it.
|
||||
|
||||
Reference in New Issue
Block a user