"use strict"; var __defProp = Object.defineProperty; var __getOwnPropDesc = Object.getOwnPropertyDescriptor; var __getOwnPropNames = Object.getOwnPropertyNames; var __hasOwnProp = Object.prototype.hasOwnProperty; var __export = (target, all) => { for (var name in all) __defProp(target, name, { get: all[name], enumerable: true }); }; var __copyProps = (to, from, except, desc) => { if (from && typeof from === "object" || typeof from === "function") { for (let key of __getOwnPropNames(from)) if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable }); } return to; }; var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod); // src/index.ts var src_exports = {}; __export(src_exports, { hexo: () => hexo, hexoReverse: () => hexoReverse, hugo: () => hugo, hugoReverse: () => hugoReverse, jekyll: () => jekyll, jekyllReverse: () => jekyllReverse, mditVue: () => mditVue, mditVueReverse: () => mditVueReverse, nuxt: () => nuxt, nuxtReverse: () => nuxtReverse, nuxtThemeAlpine: () => nuxtThemeAlpine, nuxtThemeAlpineReverse: () => nuxtThemeAlpineReverse }); module.exports = __toCommonJS(src_exports); // src/common/hexo.ts var hexo = { /** @see {@link https://hexo.io/docs/front-matter.html#Categories-amp-Tags} */ categories: ({ categories }) => [...new Set(categories?.flat())], created: "date", flags: ({ comments, disableNunjucks, flags }) => [ ...flags ?? [], ...comments === false ? ["disable-comments"] : [], ...disableNunjucks === true ? ["disable-nunjunks"] : [] ], images: "photos", summary: "excerpt" }; var hexoReverse = { comments: ({ flags }) => !flags?.some((flag) => flag === "disable-comments"), date: "created", disableNunjunks: ({ flags }) => flags?.some((flag) => flag === "disable-nunjunks"), excerpt: "summary", photos: ({ images }) => images?.map((image) => typeof image === "string" ? image : image.src) }; // src/common/hugo.ts var hugo = { // TODO: images, videos flags: ({ draft, flags }) => [.../* @__PURE__ */ new Set([ ...flags ?? [], ...draft ? ["draft"] : [] ])], published: "publishDate", tags: ({ keywords, tags }) => [.../* @__PURE__ */ new Set([ ...tags ?? [], ...keywords ?? [] ])], updated: "lastmod" }; var hugoReverse = { // TODO: images, videos draft: ({ flags }) => flags?.includes("draft"), keywords: "tags", lastmod: "updated", publishDate: "published" }; // src/common/jekyll.ts var jekyll = { categories: ({ categories, category }) => [.../* @__PURE__ */ new Set([ category, ...categories ? typeof categories === "string" ? categories.split(" ") : categories : [] ])].filter((tag) => tag !== void 0), created: "date", tags: ({ tags }) => typeof tags === "string" ? tags.split(" ") : tags }; var jekyllReverse = { date: "created" }; // src/common/nuxt.ts var nuxt = { flags: ({ draft, flags }) => [.../* @__PURE__ */ new Set([...flags ?? [], ...draft ? ["draft"] : []])], summary: "description" }; var nuxtReverse = { description: "summary", draft: ({ flags }) => flags?.includes("draft") }; // src/common/nuxt-themes.ts var nuxtThemeAlpine = { authors: ({ author }) => author ? [{ avatar: author.avatarUrl, name: author.name, url: author.link }] : void 0, created: "date", image: "cover" }; var nuxtThemeAlpineReverse = { author: ({ authors }) => authors ? { avatarUrl: authors[0].avatar, link: authors[0].url, name: authors[0].name } : void 0, cover: "image", date: "created" }; // src/mdit/vue.ts var mditVue = { summary: "excerpt" }; var mditVueReverse = { excerpt: "summary" }; // Annotate the CommonJS export names for ESM import in node: 0 && (module.exports = { hexo, hexoReverse, hugo, hugoReverse, jekyll, jekyllReverse, mditVue, mditVueReverse, nuxt, nuxtReverse, nuxtThemeAlpine, nuxtThemeAlpineReverse });