backend:
    name: github
    repo: StepanovPlaton/AboutMe
    branch: main
    site_domain: stepanovplaton.ru
    base_url: https://stepanovplaton.ru
    auth_endpoint: oauth

# Явно указываем site_url для правильного формирования OAuth callback URL
# Это предотвращает добавление порта 8091 к OAuth ссылкам
site_url: https://stepanovplaton.ru
media_folder: "public/images"
public_folder: "/images"
collections:

    -   name: "posts"
        label: "Posts"
        folder: "src/content/posts"
        create: true
        slug: "{{slug}}"
        fields:
            -   {label: "Title", name: "title", widget: "string"}
            -   {label: "Published Date", name: "published", widget: "datetime"}
            -   {label: "Updated Date", name: "updated", widget: "datetime", required: false}
            -   {label: "Description", name: "description", widget: "text", required: false}
            -   {label: "Cover", name: "cover", widget: "image", required: false}
            -   {label: "Tags", name: "tags", widget: "list", default: [], required: false}
            -   {label: "Category", name: "category", widget: "string", required: false}
            -   {label: "Draft", name: "draft", widget: "boolean", default: false}
            -   {label: "Body", name: "body", widget: "markdown"}

    -   name: "projects"
        label: "Projects"
        folder: "src/content/projects"
        create: true
        slug: "{{slug}}"
        format: "json"
        fields:
            -   { label: "Title", name: "title", widget: "string" }
            -   { label: "Description", name: "description", widget: "text" }
            -   { label: "Image", name: "image", widget: "image", required: false }
            -   { label: "Category", name: "category", widget: "select", options: ["library","ai","software","website","game"] }
            -   { label: "Tech Stack", name: "techStack", widget: "list", default: [] }
            -   { label: "Status", name: "status", widget: "select", options: ["completed","in-progress","planned"] }
            -   { label: "Live Demo", name: "liveDemo", widget: "string", required: false }
            -   { label: "Source Code", name: "sourceCode", widget: "string", required: false }
            -   { label: "Start Date", name: "startDate", widget: "datetime" }
            -   { label: "End Date", name: "endDate", widget: "datetime", required: false }
            -   { label: "Featured", name: "featured", widget: "boolean", required: false, default: false }
            -   { label: "Tags", name: "tags", widget: "list", required: false, default: [] }

    -   name: "skills"
        label: "Skills"
        folder: "src/content/skills"
        create: true
        slug: "{{slug}}"
        format: "json"
        fields:
            -   { label: "Name", name: "name", widget: "string" }
            -   { label: "Description", name: "description", widget: "text" }
            -   { label: "Icon", name: "icon", widget: "string" }
            -   { label: "Category", name: "category", widget: "select", options: ["ai","backend","client","frontend","database","engines","tools","others"] }
            -   { label: "Level", name: "level", widget: "select", options: ["beginner","intermediate","advanced","expert"] }
            -   label: "Experience"
                name: "experience"
                widget: "object"
                fields:
                    -   { label: "Years", name: "years", widget: "number", value_type: "int", min: 0 }
                    -   { label: "Months", name: "months", widget: "number", value_type: "int", min: 0, max: 11 }
            -  { label: "Projects", name: "projects", widget: "list", required: false, default: [] }
            -  { label: "Certifications", name: "certifications", widget: "list", required: false, default: [] }
            -  { label: "Color", name: "color", widget: "string", required: false }

    -   name: "timeline"
        label: "Timeline"
        folder: "src/content/timeline"
        create: true
        slug: "{{slug}}"
        format: "json"
        fields:
            -   { label: "Title", name: "title", widget: "string" }
            -   { label: "Description", name: "description", widget: "text" }
            -   { label: "Type", name: "type", widget: "select", options: ["education","work","project","achievement"] }
            -   { label: "Start Date", name: "startDate", widget: "datetime" }
            -   { label: "End Date", name: "endDate", widget: "datetime", required: false }
            -   { label: "Location", name: "location", widget: "string", required: false }
            -   { label: "Organization", name: "organization", widget: "string", required: false }
            -   { label: "Position", name: "position", widget: "string", required: false }
            -   { label: "Skills", name: "skills", widget: "list", required: false, default: [] }
            -   { label: "Achievements", name: "achievements", widget: "list", required: false, default: [] }
            -   label: "Links"
                name: "links"
                widget: "list"
                required: false
                fields:
                    -   { label: "Name", name: "name", widget: "string" }
                    -   { label: "URL", name: "url", widget: "string" }
                    -   { label: "Type", name: "type", widget: "select", options: ["certificate","project","other"] }
            -   { label: "Icon", name: "icon", widget: "string", required: false }
            -   { label: "Color", name: "color", widget: "string", required: false }

    -   name: "diary"
        label: "Diary"
        folder: "src/content/diary"
        create: true
        slug: "{{year}}-{{month}}-{{day}}-{{hour}}-{{minute}}"
        format: "json"
        fields:
            -   { label: "Content", name: "content", widget: "text" }
            -   { label: "Date", name: "date", widget: "datetime" }
            -   label: "Images"
                name: "images"
                widget: "list"
                required: false
                default: []
                field: { label: "Image", name: "image", widget: "image" }

    -   name: "albums"
        label: "Albums"
        folder: "src/content/albums"
        create: true
        slug: "{{slug}}"
        format: "json"
        fields:
            -   { label: "Title", name: "title", widget: "string" }
            -   { label: "Description", name: "description", widget: "text", required: false }
            -   { label: "Cover", name: "cover", widget: "image" }
            -   { label: "Date", name: "date", widget: "datetime" }
            -   { label: "Location", name: "location", widget: "string", required: false }
            -   { label: "Tags", name: "tags", widget: "list", required: false, default: [] }
            -   { label: "Layout", name: "layout", widget: "select", options: ["grid", "masonry", "list"], default: "grid" }
            -   { label: "Columns", name: "columns", widget: "number", default: 3, value_type: "int", min: 1, max: 6 }
            -   label: "Photos"
                name: "photos"
                widget: "list"
                required: false
                fields:
                    -   { label: "Image", name: "src", widget: "image" }
                    -   { label: "Caption", name: "alt", widget: "string", required: false }
                    -   { label: "Title", name: "title", widget: "string", required: false }
                    -   { label: "Description", name: "description", widget: "text", required: false }
                    -   { label: "Tags", name: "tags", widget: "list", required: false, default: [] }
                    -   { label: "Date", name: "date", widget: "datetime", required: false }
            -   { label: "Visible", name: "visible", widget: "boolean", default: true, required: false }

    -   name: "friends"
        label: "Friends"
        folder: "src/content/friends"
        create: true
        slug: "{{slug}}"
        format: "json"
        fields:
            -   { label: "Title", name: "title", widget: "string" }
            -   { label: "Avatar URL", name: "imgurl", widget: "string" }
            -   { label: "Description", name: "desc", widget: "text" }
            -   { label: "Site URL", name: "siteurl", widget: "string" }
            -   { label: "Tags", name: "tags", widget: "list", required: false, default: [] }


editor:
    preview: true