decap CMS additions

This commit is contained in:
tyler :3
2024-04-07 18:08:52 +01:00
parent 40e6ecc2e7
commit 1d5dbe5971
4 changed files with 33 additions and 8 deletions

19
admin/config.yml Normal file
View File

@@ -0,0 +1,19 @@
backend:
name: github
branch: master
repo: shrapnelnet/blog
media_folder: "assets/uploads"
collections:
- name: 'blog'
label: 'shr4pnelblog'
folder: '_posts/'
create: true
slug: '{{year}}-{{month}}-{{day}}-{{slug}}'
editor:
preview: false
fields:
- { label: 'Layout', name: 'layout', widget: 'hidden', default: 'post' }
- { label: 'Title', name: 'title', widget: 'string' }
- { label: 'Publish Date', name: 'date', widget: 'datetime' }
- { label: "Permalink", name: "permalink", widget: "string" }
- { label: 'Body', name: 'body', widget: 'markdown' }

12
admin/index.html Normal file
View File

@@ -0,0 +1,12 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Content Manager</title>
<script src="https://identity.netlify.com/v1/netlify-identity-widget.js" type="text/javascript"></script>
</head>
<body>
<script src="https://unpkg.com/decap-cms@^3.0.0/dist/decap-cms.js"></script>
</body>
</html>