backend:
  name: github
  branch: main
  repo: RolinShmily/SrP-BloG
  site_domain: blog.srprolin.top
  base_url: https://gh-oauth.srprolin.top
  auth_endpoint: auth

  commit_messages:
    create: "CMS:Create {{collection}} “{{slug}}”"
    update: "CMS:Update {{collection}} “{{slug}}”"
    delete: "CMS:Delete {{collection}} “{{slug}}”"
    uploadMedia: "CMS:Upload “{{path}}”"
    deleteMedia: "CMS:Delete “{{path}}”"
    openAuthoring: "CMS:{{message}}"

logo_url: https://blog.srprolin.top/favicon/favicon.ico

site_url: https://blog.srprolin.top
display_url: https://blog.srprolin.top

# This line should *not* be indented
media_folder: "src/content/assets/images" # Media files will be stored in the repo under images/uploads
public_folder: "../assets/images"

collections:
  - name: "posts" # Used in routes, e.g., /admin/collections/blog
    label: "Posts" # Used in the UI
    folder: "src/content/posts" # The path to the folder where the documents are stored
    create: true # Allow users to create new documents in this collection
    slug: "{{year}}-{{month}}-{{day}}-{{slug}}" # Filename template
    fields: # The fields for each document, usually in front matter
      - { label: "标题", name: "title", widget: "string" }
      - {
          label: "发布日期",
          name: "published",
          widget: "datetime",
          format: "YYYY-MM-DD",
        }
      - {
          label: "置顶",
          name: "pinned",
          widget: "boolean",
          default: false,
          required: false,
        }
      - {
          label: "摘要",
          name: "description",
          widget: "string",
          required: false,
        }
      - { label: "封面", name: "image", widget: "image", required: false }
      - {
          label: "标签",
          name: "tags",
          widget: "list",
          minimize_collapsed: true,
          required: false,
        }
      - { label: "分类", name: "categories", widget: "list", required: false }
      - {
          label: "草稿",
          name: "draft",
          widget: "boolean",
          default: false,
          required: false,
        }
      - {
          label: "语言",
          name: "lang",
          widget: "string",
          default: "",
          required: false,
        }
      - { label: "正文", name: "body", widget: "markdown", required: false }

  - name: "pages"
    label: "Pages"
    files:
      - file: "src/content/spec/about.md"
        name: "about"
        label: "关于"
        fields:
          - { label: "内容", name: "body", widget: "markdown", required: false }
      - file: "src/content/spec/frlinks.md"
        name: "frlinks"
        label: "友链"
        fields:
          - { label: "内容", name: "body", widget: "markdown", required: false }
      - file: "src/content/spec/anime.md"
        name: "anime"
        label: "番剧"
        fields:
          - { label: "内容", name: "body", widget: "markdown", required: false }
      - file: "src/content/spec/web.md"
        name: "web"
        label: "网页"
        fields:
          - { label: "内容", name: "body", widget: "markdown", required: false }