···11+import { Dialog } from "@bigmoves/bff/components";
22+33+export function ExifInfoDialog() {
44+ return (
55+ <Dialog class="z-100">
66+ <Dialog.Content class="dark:bg-zinc-950 relative">
77+ <Dialog.Title>EXIF Info</Dialog.Title>
88+ <Dialog.X class="fill-zinc-950 dark:fill-zinc-50" />
99+ <div class="text-sm mt-2">
1010+ <p>
1111+ When you upload photos to Grain, we extract a small set of standard
1212+ EXIF metadata from each image. This information is used to help
1313+ organize photos by date taken, camera make, lens make, etc. This is
1414+ a list of tags we currently support.
1515+ </p>
1616+ <ul class="list-disc ml-6 mt-2">
1717+ <li>
1818+ <b>DateTimeOriginal</b>: When the photo was taken
1919+ </li>
2020+ <li>
2121+ <b>ExposureTime</b>: Shutter speed (e.g., 1/250s)
2222+ </li>
2323+ <li>
2424+ <b>FNumber</b>: Aperture (f-stop)
2525+ </li>
2626+ <li>
2727+ <b>Flash</b>: Whether the flash fired
2828+ </li>
2929+ <li>
3030+ <b>FocalLengthIn35mmFormat</b>: Lens focal length (35mm
3131+ equivalent)
3232+ </li>
3333+ <li>
3434+ <b>ISO</b>: ISO sensitivity setting
3535+ </li>
3636+ <li>
3737+ <b>LensMake</b>: Lens manufacturer
3838+ </li>
3939+ <li>
4040+ <b>LensModel</b>: Lens model
4141+ </li>
4242+ <li>
4343+ <b>Make</b>: Camera manufacturer
4444+ </li>
4545+ <li>
4646+ <b>Model</b>: Camera model
4747+ </li>
4848+ </ul>
4949+ <p class="mt-2">
5050+ No GPS or location data is collected, and we do not store any
5151+ personally identifiable information. The EXIF data is used solely to
5252+ enhance your photo organization and discovery experience on Grain.
5353+ </p>
5454+ <p class="mt-2">
5555+ If you want to remove EXIF data from your photo after uploading, you
5656+ can delete the photo and re-upload with the "Include image metadata"
5757+ checkbox unchecked.
5858+ </p>
5959+ <p class="mt-2">
6060+ You can learn more about the types of metadata commonly embedded in
6161+ photos at{" "}
6262+ <a
6363+ href="https://exiv2.org/tags.html"
6464+ className="text-sky-500 hover:underline"
6565+ target="_blank"
6666+ rel="noopener noreferrer"
6767+ >
6868+ exiv2.org
6969+ </a>
7070+ .
7171+ </p>
7272+ </div>
7373+ </Dialog.Content>
7474+ </Dialog>
7575+ );
7676+}
···169169 </p>
170170 </Section>
171171172172- {
173173- /* Coming soon */
174174- /* <Section title="EXIF Metadata">
172172+ <Section title="EXIF Metadata">
175173 <p>
176176- We optionally collect and display EXIF metadata (excluding location)
177177- from your photos. At upload time, you can choose whether to allow this
178178- metadata to be collected. The metadata is stored according to standard
179179- AT Protocol storage mechanisms and is not retained outside the
180180- protocol or used for other purposes.
174174+ We optionally collect and display EXIF metadata from your photos. At
175175+ upload time, you can choose whether to allow this metadata to be
176176+ collected. The metadata is stored according to standard AT Protocol
177177+ storage mechanisms and is not retained outside the protocol or used
178178+ for other purposes. We do not collect GPS or location data from your
179179+ photos.
181180 </p>
182181 <p>
183182 You can learn more about the types of metadata commonly embedded in
···192191 </a>
193192 .
194193 </p>
195195- </Section> */
196196- }
194194+ </Section>
197195198196 <Section title="Analytics">
199197 <p>
+15-2
src/lib/actor.ts
···66import { Record as Favorite } from "$lexicon/types/social/grain/favorite.ts";
77import { Record as Gallery } from "$lexicon/types/social/grain/gallery.ts";
88import { Record as Photo } from "$lexicon/types/social/grain/photo.ts";
99+import { Record as PhotoExif } from "$lexicon/types/social/grain/photo/exif.ts";
910import { Un$Typed } from "$lexicon/util.ts";
1011import { BffContext, WithBffMeta } from "@bigmoves/bff";
1112import { galleryToView, getGalleryItemsAndPhotos } from "./gallery.ts";
···5455 orderBy: [{ field: "createdAt", direction: "desc" }],
5556 },
5657 );
5757-5858- return photos.items.map((photo) => photoToView(photo.did, photo));
5858+ const exif = ctx.indexService.getRecords<WithBffMeta<PhotoExif>>(
5959+ "social.grain.photo.exif",
6060+ {
6161+ where: [{ field: "photo", in: photos.items.map((p) => p.uri) }],
6262+ },
6363+ );
6464+ const exifMap = new Map<string, WithBffMeta<PhotoExif>>();
6565+ exif.items.forEach((e) => {
6666+ exifMap.set(e.photo, e);
6767+ });
6868+ return photos.items.map((photo) => {
6969+ const exifData = exifMap.get(photo.uri);
7070+ return photoToView(photo.did, photo, exifData);
7171+ });
5972}
60736174export function getActorGalleries(handleOrDid: string, ctx: BffContext) {