Skip to content

Commit

Permalink
improved cms
Browse files Browse the repository at this point in the history
  • Loading branch information
oscarotero committed Aug 11, 2024
1 parent 8823d6c commit 679ea03
Show file tree
Hide file tree
Showing 3 changed files with 26 additions and 4 deletions.
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,10 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](http://keepachangelog.com/) and this
project adheres to [Semantic Versioning](http://semver.org/).

## [0.9.3] - Unreleased
### Added
- Settings to CMS to configure a default extra_head and language.

## [0.9.2] - 2024-08-08
### Added
- Fix passing options to plugins.
Expand Down Expand Up @@ -137,6 +141,7 @@ First version
[#8]: https://github.com/lumeland/theme-simple-wiki/issues/8
[#9]: https://github.com/lumeland/theme-simple-wiki/issues/9

[0.9.3]: https://github.com/lumeland/theme-simple-wiki/compare/v0.9.2...HEAD
[0.9.2]: https://github.com/lumeland/theme-simple-wiki/compare/v0.9.1...v0.9.2
[0.9.1]: https://github.com/lumeland/theme-simple-wiki/compare/v0.9.0...v0.9.1
[0.9.0]: https://github.com/lumeland/theme-simple-wiki/compare/v0.8.2...v0.9.0
Expand Down
20 changes: 16 additions & 4 deletions _cms.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,16 +7,28 @@ cms.document(
"src:index.md",
[
{
name: "logo",
type: "file",
description: "Logo of the site. It's applied to all pages.",
name: "extra_head",
type: "code",
description: "Extra content to include in the <head> tag",
},
"content: markdown",
],
);

cms.document(
"settings: Global settings for the site",
"src:_data.yml",
[
{
name: "lang",
type: "text",
label: "Language",
},
{
name: "extra_head",
type: "code",
description: "Extra content to include in the <head> tag",
},
"content: markdown",
],
);

Expand Down
5 changes: 5 additions & 0 deletions _config.ts
Original file line number Diff line number Diff line change
@@ -1,9 +1,14 @@
import lume from "lume/mod.ts";
import notes from "./mod.ts";
import ogimages from "lume/plugins/og_images.ts";
import metas from "lume/plugins/metas.ts";

const site = lume({
src: "./src",
});

site.use(notes());
site.use(ogimages());
site.use(metas());

export default site;

0 comments on commit 679ea03

Please sign in to comment.