Self-hosted personal gallery application with online photo management and albums, supporting Live/Motion Photos, EXIF parsing, geolocation recognition, and an explore map.
TypeScript albumsexif-extractiongeocodinglive-photomotion-photophoto-galleryphoto-sharingwebgl-viewer
import { createResourceReader } from '@chronoframe/core'
import { createCloudResourceRepository } from '@chronoframe/database/cloud-resources'
import type { MediaDatabase } from '@chronoframe/database/cloud-media'
import {
definePlatformHandler,
platformDatabase,
} from '../../../../shared/platform/runtime'
import { publicSiteContext } from '../../../../shared/platform/context'
export default definePlatformHandler(async (event) => {
const context = await publicSiteContext(event)
return {
photos: await createResourceReader(
createCloudResourceRepository(
platformDatabase(event) as unknown as MediaDatabase,
context.site,
'/api/public/media',
),
).listVisiblePhotos(),
}
})