/* * THIS FILE WAS GENERATED BY "@atproto/lex". DO NOT EDIT. */ import { l } from "@atproto/lex"; import * as EmbedDefs from "./defs.defs.js"; const $nsid = "app.bsky.embed.images"; export { $nsid }; type Main = { $type?: "app.bsky.embed.images";"images":(Image)[] }; export type { Main }; const main = /*#__PURE__*/ l.typedObject
($nsid, "main", /*#__PURE__*/ l.object({"images":/*#__PURE__*/ l.array(/*#__PURE__*/ l.ref((() => image) as any), {"maxLength":4})})); export { main }; export const $type = $nsid; export const $isTypeOf = /*#__PURE__*/ main.isTypeOf.bind(main); export const $build = /*#__PURE__*/ main.build.bind(main); export const $assert = /*#__PURE__*/ main.assert.bind(main); export const $check = /*#__PURE__*/ main.check.bind(main); export const $cast = /*#__PURE__*/ main.cast.bind(main); export const $ifMatches = /*#__PURE__*/ main.ifMatches.bind(main); export const $matches = /*#__PURE__*/ main.matches.bind(main); export const $parse = /*#__PURE__*/ main.parse.bind(main); export const $safeParse = /*#__PURE__*/ main.safeParse.bind(main); export const $validate = /*#__PURE__*/ main.validate.bind(main); export const $safeValidate = /*#__PURE__*/ main.safeValidate.bind(main); type View = { $type?: "app.bsky.embed.images#view";"images":(ViewImage)[] }; export type { View }; const view = /*#__PURE__*/ l.typedObject($nsid, "view", /*#__PURE__*/ l.object({"images":/*#__PURE__*/ l.array(/*#__PURE__*/ l.ref((() => viewImage) as any), {"maxLength":4})})); export { view }; type Image = { $type?: "app.bsky.embed.images#image"; /** * Alt text description of the image, for accessibility. */ "alt":string; /** * The raw image file. May be up to 2 MB, formerly limited to 1 MB. */ "image":l.BlobRef;"aspectRatio"?:EmbedDefs.AspectRatio }; export type { Image }; const image = /*#__PURE__*/ l.typedObject($nsid, "image", /*#__PURE__*/ l.object({"alt":/*#__PURE__*/ l.string(),"image":/*#__PURE__*/ l.blob({"accept":["image/*"],"maxSize":2000000}),"aspectRatio":/*#__PURE__*/ l.optional(/*#__PURE__*/ l.ref((() => EmbedDefs.aspectRatio) as any))})); export { image }; type ViewImage = { $type?: "app.bsky.embed.images#viewImage"; /** * Alt text description of the image, for accessibility. */ "alt":string; /** * Fully-qualified URL where a thumbnail of the image can be fetched. For example, CDN location provided by the App View. */ "thumb":l.UriString; /** * Fully-qualified URL where a large version of the image can be fetched. May or may not be the exact original blob. For example, CDN location provided by the App View. */ "fullsize":l.UriString;"aspectRatio"?:EmbedDefs.AspectRatio }; export type { ViewImage }; const viewImage = /*#__PURE__*/ l.typedObject($nsid, "viewImage", /*#__PURE__*/ l.object({"alt":/*#__PURE__*/ l.string(),"thumb":/*#__PURE__*/ l.string({"format":"uri"}),"fullsize":/*#__PURE__*/ l.string({"format":"uri"}),"aspectRatio":/*#__PURE__*/ l.optional(/*#__PURE__*/ l.ref((() => EmbedDefs.aspectRatio) as any))})); export { viewImage };