@docmd/template-summer 0.8.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +90 -0
- package/dist/assets/css/summer.css +3418 -0
- package/dist/assets/js/summer.js +660 -0
- package/dist/index.d.ts +28 -0
- package/dist/index.js +79 -0
- package/dist/templates/404.ejs +156 -0
- package/dist/templates/layout.ejs +609 -0
- package/dist/templates/partials/footer.ejs +69 -0
- package/dist/templates/partials/menubar.ejs +92 -0
- package/dist/templates/partials/options-menu.ejs +45 -0
- package/dist/templates/toc.ejs +53 -0
- package/package.json +61 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2025-present docmd.io
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
ADDED
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
# @docmd/template-summer
|
|
2
|
+
|
|
3
|
+
> A bright, hopeful, summer-feel layout for [docmd](https://docmd.io) **0.8.7+**.
|
|
4
|
+
|
|
5
|
+
Summer is the first in the [docmd template seasons](../) series. It is built on the new **template plugin system** introduced in 0.8.7, which means it is a regular `@docmd/*` package with the `template` capability.
|
|
6
|
+
|
|
7
|
+
## Highlights
|
|
8
|
+
|
|
9
|
+
- **Centred search bar** in the top header — the focal point of the layout
|
|
10
|
+
- **Menubar relocated** to the bottom of the logo bar (default docmd has it above)
|
|
11
|
+
- **Airier content** with right-rail TOC, more vertical rhythm
|
|
12
|
+
- **Centred footer** with `last updated` + edit-this-page
|
|
13
|
+
- **Built on `@docmd/ui` defaults** — only 3 partials overridden; the rest fall back automatically
|
|
14
|
+
|
|
15
|
+
## Install
|
|
16
|
+
|
|
17
|
+
```bash
|
|
18
|
+
npm install @docmd/template-summer
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
## Enable
|
|
22
|
+
|
|
23
|
+
```json
|
|
24
|
+
{
|
|
25
|
+
"theme": {
|
|
26
|
+
"template": "summer"
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
Or pass the full package name (also accepted):
|
|
32
|
+
|
|
33
|
+
```json
|
|
34
|
+
{
|
|
35
|
+
"theme": {
|
|
36
|
+
"template": "@docmd/template-summer"
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
## Per-page override
|
|
42
|
+
|
|
43
|
+
```markdown
|
|
44
|
+
---
|
|
45
|
+
title: "Changelog"
|
|
46
|
+
template: "template-changelog"
|
|
47
|
+
---
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
## Customise
|
|
51
|
+
|
|
52
|
+
Drop your own CSS into `theme.customCss` — it always wins at priority 15. Do not use `!important` so the user can always override your template.
|
|
53
|
+
|
|
54
|
+
```json
|
|
55
|
+
{
|
|
56
|
+
"theme": {
|
|
57
|
+
"template": "summer",
|
|
58
|
+
"customCss": ["/assets/css/my-summer-tweaks.css"]
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
```
|
|
62
|
+
|
|
63
|
+
## Slots this template overrides
|
|
64
|
+
|
|
65
|
+
| Slot | Source |
|
|
66
|
+
|---|---|
|
|
67
|
+
| `layout` | [`templates/layout.ejs`](templates/layout.ejs) |
|
|
68
|
+
| `menubar` | [`templates/partials/menubar.ejs`](templates/partials/menubar.ejs) |
|
|
69
|
+
| `footer` | [`templates/partials/footer.ejs`](templates/partials/footer.ejs) |
|
|
70
|
+
|
|
71
|
+
All other slots (sidebar, TOC, options menu, header, etc.) inherit from `@docmd/ui`.
|
|
72
|
+
|
|
73
|
+
## Asset priority
|
|
74
|
+
|
|
75
|
+
This template ships one CSS file and one JS file, both at **priority 10** (the new default for templates). The load order is:
|
|
76
|
+
|
|
77
|
+
1. `docmd-main.css` (0) — base
|
|
78
|
+
2. `docmd-theme-sky.css` etc. (5) — your theme
|
|
79
|
+
3. `summer.css` (10) — this template
|
|
80
|
+
4. Your `customCss` (15) — wins
|
|
81
|
+
5. Plugin CSS (20) — last
|
|
82
|
+
|
|
83
|
+
## Requirements
|
|
84
|
+
|
|
85
|
+
- `docmd >= 0.8.7`
|
|
86
|
+
- Node.js >= 18
|
|
87
|
+
|
|
88
|
+
## License
|
|
89
|
+
|
|
90
|
+
MIT
|