@bytechain.cn/colamd-themes 0.5.9 → 0.6.1
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/README.md +85 -19
- package/dist/cli.js +70 -6
- package/dist/cli.js.map +1 -1
- package/dist/compat.d.ts +23 -3
- package/dist/compat.js +71 -12
- package/dist/compat.js.map +1 -1
- package/dist/dsh-plugin.js +1 -1
- package/dist/generator.d.ts +1 -1
- package/dist/generator.js +5 -2
- package/dist/generator.js.map +1 -1
- package/dist/models.d.ts +7 -1
- package/dist/models.js +1 -1
- package/dist/models.js.map +1 -1
- package/dist/renderer.d.ts +1 -1
- package/dist/renderer.js +21 -3
- package/dist/renderer.js.map +1 -1
- package/dist/slides-markdown.d.ts +45 -0
- package/dist/slides-markdown.js +515 -0
- package/dist/slides-markdown.js.map +1 -0
- package/dist/slides.d.ts +36 -0
- package/dist/slides.js +149 -0
- package/dist/slides.js.map +1 -0
- package/dist/templates/theme-template.hbs +11 -0
- package/dist/validators.d.ts +2 -2
- package/dist/validators.js +71 -4
- package/dist/validators.js.map +1 -1
- package/package.json +3 -2
- package/skills/build-skills.sh +224 -217
- package/skills/colamd-themes/SKILL.md +178 -6
- package/themes/8-bit-orbit.css +817 -0
- package/themes/README.md +69 -0
- package/themes/biennale-yellow.css +577 -0
- package/themes/block-frame.css +774 -0
- package/themes/blue-professional.css +741 -0
- package/themes/bold-poster.css +794 -0
- package/themes/broadside.css +837 -0
- package/themes/capsule.css +767 -0
- package/themes/cartesian.css +584 -0
- package/themes/cobalt-grid.css +632 -0
- package/themes/coral.css +699 -0
- package/themes/creative-mode.css +642 -0
- package/themes/daisy-days.css +1052 -0
- package/themes/editorial-forest.css +796 -0
- package/themes/editorial-tri-tone.css +811 -0
- package/themes/emerald-editorial.css +683 -0
- package/themes/grove.css +623 -0
- package/themes/indigo-deck.css +336 -0
- package/themes/indigo-porcelain-light.css +335 -0
- package/themes/long-table.css +782 -0
- package/themes/mat.css +848 -0
- package/themes/monochrome.css +782 -0
- package/themes/neo-grid-bold.css +838 -0
- package/themes/peoples-platform.css +843 -0
- package/themes/pin-and-paper.css +700 -0
- package/themes/pink-script-dark.css +648 -0
- package/themes/pink-script.css +290 -0
- package/themes/playful.css +774 -0
- package/themes/raw-grid.css +814 -0
- package/themes/retro-windows.css +767 -0
- package/themes/retro-zine.css +814 -0
- package/themes/sakura-chroma.css +775 -0
- package/themes/scatterbrain.css +726 -0
- package/themes/signal.css +872 -0
- package/themes/soft-editorial.css +788 -0
- package/themes/stencil-tablet.css +922 -0
- package/themes/studio.css +767 -0
- package/themes/swiss-lemon-dark.css +529 -0
- package/themes/swiss-lemon-light.css +375 -0
- package/themes/vellum.css +723 -0
package/skills/build-skills.sh
CHANGED
|
@@ -1,217 +1,224 @@
|
|
|
1
|
-
#!/usr/bin/env bash
|
|
2
|
-
#
|
|
3
|
-
# Build agent-specific skill files from the canonical source.
|
|
4
|
-
#
|
|
5
|
-
# Usage:
|
|
6
|
-
# bash skills/build-skills.sh # generate all
|
|
7
|
-
# bash skills/build-skills.sh claude # generate for one agent
|
|
8
|
-
#
|
|
9
|
-
# Source: skills/colamd-themes/SKILL.md
|
|
10
|
-
# Output: .{agent}/skills/colamd-themes/SKILL.md (or equivalent)
|
|
11
|
-
|
|
12
|
-
set -euo pipefail
|
|
13
|
-
cd "$(dirname "$0")/.."
|
|
14
|
-
|
|
15
|
-
SOURCE="skills/colamd-themes/SKILL.md"
|
|
16
|
-
if [[ ! -f "$SOURCE" ]]; then
|
|
17
|
-
echo "Error: Source skill not found: $SOURCE" >&2
|
|
18
|
-
exit 1
|
|
19
|
-
fi
|
|
20
|
-
|
|
21
|
-
# Read the body (everything after the first blank line following the heading).
|
|
22
|
-
# Strip CR first: on Windows checkouts the source may use CRLF, and sed's
|
|
23
|
-
# `/^$/` cannot match a "\r" line — silently producing an empty BODY and
|
|
24
|
-
# truncated skill files (regression shipped in 0.5.2).
|
|
25
|
-
BODY=$(sed 's/\r$//' "$SOURCE" | sed -n '/^$/,$ { /^# ColaMD/!p; }' | sed '1{/^$/d;}')
|
|
26
|
-
if [[ -z "$BODY" ]]; then
|
|
27
|
-
echo "Error: extracted body from $SOURCE is empty (line-ending issue?)" >&2
|
|
28
|
-
exit 1
|
|
29
|
-
fi
|
|
30
|
-
|
|
31
|
-
# ── Frontmatter templates ──
|
|
32
|
-
|
|
33
|
-
FRONT_CLAUDE='---
|
|
34
|
-
name: colamd-themes
|
|
35
|
-
description: >
|
|
36
|
-
Generate, validate, export, and manage ColaMD 2.7
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
-
|
|
54
|
-
-
|
|
55
|
-
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
---'
|
|
110
|
-
|
|
111
|
-
#
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
echo "
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
echo "
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
echo "
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
echo "
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
echo "
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
echo "
|
|
190
|
-
echo ""
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
echo "
|
|
1
|
+
#!/usr/bin/env bash
|
|
2
|
+
#
|
|
3
|
+
# Build agent-specific skill files from the canonical source.
|
|
4
|
+
#
|
|
5
|
+
# Usage:
|
|
6
|
+
# bash skills/build-skills.sh # generate all
|
|
7
|
+
# bash skills/build-skills.sh claude # generate for one agent
|
|
8
|
+
#
|
|
9
|
+
# Source: skills/colamd-themes/SKILL.md
|
|
10
|
+
# Output: .{agent}/skills/colamd-themes/SKILL.md (or equivalent)
|
|
11
|
+
|
|
12
|
+
set -euo pipefail
|
|
13
|
+
cd "$(dirname "$0")/.."
|
|
14
|
+
|
|
15
|
+
SOURCE="skills/colamd-themes/SKILL.md"
|
|
16
|
+
if [[ ! -f "$SOURCE" ]]; then
|
|
17
|
+
echo "Error: Source skill not found: $SOURCE" >&2
|
|
18
|
+
exit 1
|
|
19
|
+
fi
|
|
20
|
+
|
|
21
|
+
# Read the body (everything after the first blank line following the heading).
|
|
22
|
+
# Strip CR first: on Windows checkouts the source may use CRLF, and sed's
|
|
23
|
+
# `/^$/` cannot match a "\r" line — silently producing an empty BODY and
|
|
24
|
+
# truncated skill files (regression shipped in 0.5.2).
|
|
25
|
+
BODY=$(sed 's/\r$//' "$SOURCE" | sed -n '/^$/,$ { /^# ColaMD/!p; }' | sed '1{/^$/d;}')
|
|
26
|
+
if [[ -z "$BODY" ]]; then
|
|
27
|
+
echo "Error: extracted body from $SOURCE is empty (line-ending issue?)" >&2
|
|
28
|
+
exit 1
|
|
29
|
+
fi
|
|
30
|
+
|
|
31
|
+
# ── Frontmatter templates ──
|
|
32
|
+
|
|
33
|
+
FRONT_CLAUDE='---
|
|
34
|
+
name: colamd-themes
|
|
35
|
+
description: >
|
|
36
|
+
Generate, validate, export, and manage ColaMD 2.7 contract CSS themes
|
|
37
|
+
(2.7.13 anchor, slide layouts stable). Extract formatting from URLs,
|
|
38
|
+
DOCX, or PDF sources (optionally with PPT --slide-* styling); convert
|
|
39
|
+
Markdown into slide-deck Markdown; export Markdown to standalone HTML/PDF
|
|
40
|
+
with themes applied; batch export; manage theme configuration.
|
|
41
|
+
---'
|
|
42
|
+
|
|
43
|
+
FRONT_OPENCODE='---
|
|
44
|
+
name: colamd-themes
|
|
45
|
+
version: "1.0.0"
|
|
46
|
+
description: >
|
|
47
|
+
Generate, validate, export, and manage ColaMD 2.7 contract CSS themes
|
|
48
|
+
(2.7.13 anchor, slide layouts stable). Extract from URLs/DOCX/PDF
|
|
49
|
+
with optional PPT styling; convert Markdown to slide decks; export
|
|
50
|
+
Markdown to HTML/PDF; batch export.
|
|
51
|
+
user-invocable: true
|
|
52
|
+
allowed-tools:
|
|
53
|
+
- Read
|
|
54
|
+
- Write
|
|
55
|
+
- Edit
|
|
56
|
+
- Bash
|
|
57
|
+
- Glob
|
|
58
|
+
- Grep
|
|
59
|
+
---'
|
|
60
|
+
|
|
61
|
+
FRONT_OPENCLAW='---
|
|
62
|
+
id: colamd-themes
|
|
63
|
+
name: ColaMD Themes
|
|
64
|
+
description: >
|
|
65
|
+
Generate, validate, export, and manage ColaMD 2.7 contract CSS themes
|
|
66
|
+
(2.7.13 anchor, slide layouts stable). Extract from URLs/DOCX/PDF
|
|
67
|
+
with optional PPT styling; convert Markdown to slide decks; export
|
|
68
|
+
Markdown to HTML/PDF; batch export.
|
|
69
|
+
version: "1.0.0"
|
|
70
|
+
icon: "\U0001F3A8"
|
|
71
|
+
author: bytechain
|
|
72
|
+
homepage: https://github.com/byteuser1977/ColaMD-themes
|
|
73
|
+
user-invocable: true
|
|
74
|
+
metadata:
|
|
75
|
+
openclaw:
|
|
76
|
+
os: [darwin, linux, win32]
|
|
77
|
+
clawdbot:
|
|
78
|
+
emoji: "\U0001F3A8"
|
|
79
|
+
requires:
|
|
80
|
+
bins: [node, npm]
|
|
81
|
+
---'
|
|
82
|
+
|
|
83
|
+
FRONT_HERMES='---
|
|
84
|
+
name: colamd-themes
|
|
85
|
+
description: "Generate, validate, export, and manage ColaMD 2.7 contract CSS themes with PPT slide layouts; convert Markdown to slide decks; export HTML/PDF."
|
|
86
|
+
version: 1.0.0
|
|
87
|
+
author: bytechain
|
|
88
|
+
license: MIT
|
|
89
|
+
metadata:
|
|
90
|
+
hermes:
|
|
91
|
+
tags: [colamd, themes, css, markdown, export, pdf, html]
|
|
92
|
+
prerequisites:
|
|
93
|
+
commands: [node, npm]
|
|
94
|
+
---'
|
|
95
|
+
|
|
96
|
+
FRONT_DSH='---
|
|
97
|
+
name: colamd-themes
|
|
98
|
+
version: "1.0.0"
|
|
99
|
+
description: >
|
|
100
|
+
Generate, validate, export, and manage ColaMD 2.7 contract CSS themes
|
|
101
|
+
(2.7.13 anchor, slide layouts stable). Extract from URLs/DOCX/PDF
|
|
102
|
+
with optional PPT styling; convert Markdown to slide decks; export
|
|
103
|
+
Markdown to HTML/PDF; batch export.
|
|
104
|
+
metadata:
|
|
105
|
+
dsh:
|
|
106
|
+
tags: [colamd, themes, css, markdown, export, pdf, html]
|
|
107
|
+
prerequisites:
|
|
108
|
+
commands: [node, npm]
|
|
109
|
+
---'
|
|
110
|
+
|
|
111
|
+
# Trae project skill constraints: description is a single-line plain scalar,
|
|
112
|
+
# unquoted, with no ": ", "<", or ">" (router-visible trigger text).
|
|
113
|
+
FRONT_TRAE_SKILL='---
|
|
114
|
+
name: colamd-themes
|
|
115
|
+
description: Generate, validate, and export ColaMD contract CSS themes with PPT slide layout support — extract from URLs, DOCX or PDF (optionally with PPT --slide-* styling), convert Markdown to slide-deck Markdown, export Markdown to HTML or PDF. Use when the user asks to create, validate, export, or manage ColaMD themes, or to generate PPT slides from Markdown.
|
|
116
|
+
---'
|
|
117
|
+
|
|
118
|
+
# ── Generator functions ──
|
|
119
|
+
|
|
120
|
+
generate_claude() {
|
|
121
|
+
local dir=".claude/skills"
|
|
122
|
+
mkdir -p "$dir"
|
|
123
|
+
local file="$dir/colamd-themes.skill.md"
|
|
124
|
+
echo "$FRONT_CLAUDE" > "$file"
|
|
125
|
+
echo "" >> "$file"
|
|
126
|
+
echo "$BODY" >> "$file"
|
|
127
|
+
echo " → $file"
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
generate_opencode() {
|
|
131
|
+
local dir=".opencode/skills/colamd-themes"
|
|
132
|
+
mkdir -p "$dir"
|
|
133
|
+
local file="$dir/SKILL.md"
|
|
134
|
+
echo "$FRONT_OPENCODE" > "$file"
|
|
135
|
+
echo "" >> "$file"
|
|
136
|
+
echo "$BODY" >> "$file"
|
|
137
|
+
echo " → $file"
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
generate_openclaw() {
|
|
141
|
+
local dir=".openclaw/skills/colamd-themes"
|
|
142
|
+
mkdir -p "$dir"
|
|
143
|
+
local file="$dir/SKILL.md"
|
|
144
|
+
echo "$FRONT_OPENCLAW" > "$file"
|
|
145
|
+
echo "" >> "$file"
|
|
146
|
+
echo "$BODY" >> "$file"
|
|
147
|
+
echo " → $file"
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
generate_hermes() {
|
|
151
|
+
local dir=".hermes/skills/tools/colamd-themes"
|
|
152
|
+
mkdir -p "$dir"
|
|
153
|
+
local file="$dir/SKILL.md"
|
|
154
|
+
echo "$FRONT_HERMES" > "$file"
|
|
155
|
+
echo "" >> "$file"
|
|
156
|
+
echo "$BODY" >> "$file"
|
|
157
|
+
echo " → $file"
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
generate_dsh() {
|
|
161
|
+
local dir=".dsh/skills/colamd-themes"
|
|
162
|
+
mkdir -p "$dir"
|
|
163
|
+
local file="$dir/SKILL.md"
|
|
164
|
+
echo "$FRONT_DSH" > "$file"
|
|
165
|
+
echo "" >> "$file"
|
|
166
|
+
echo "$BODY" >> "$file"
|
|
167
|
+
echo " → $file"
|
|
168
|
+
}
|
|
169
|
+
|
|
170
|
+
generate_trae() {
|
|
171
|
+
local dir=".trae/rules"
|
|
172
|
+
mkdir -p "$dir"
|
|
173
|
+
local file="$dir/colamd-themes.md"
|
|
174
|
+
# Trae uses plain Markdown, no YAML frontmatter
|
|
175
|
+
echo "# ColaMD Themes Skill Instructions" > "$file"
|
|
176
|
+
echo "" >> "$file"
|
|
177
|
+
echo "When the user asks to create, validate, export, or manage ColaMD themes, use the following CLI tool:" >> "$file"
|
|
178
|
+
echo "" >> "$file"
|
|
179
|
+
echo "$BODY" >> "$file"
|
|
180
|
+
echo " → $file"
|
|
181
|
+
}
|
|
182
|
+
|
|
183
|
+
generate_trae_skill() {
|
|
184
|
+
local dir=".trae/skills/colamd-themes"
|
|
185
|
+
mkdir -p "$dir"
|
|
186
|
+
local file="$dir/SKILL.md"
|
|
187
|
+
echo "$FRONT_TRAE_SKILL" > "$file"
|
|
188
|
+
echo "" >> "$file"
|
|
189
|
+
echo "$BODY" >> "$file"
|
|
190
|
+
echo " → $file"
|
|
191
|
+
}
|
|
192
|
+
|
|
193
|
+
# ── Main ──
|
|
194
|
+
|
|
195
|
+
TARGET="${1:-all}"
|
|
196
|
+
echo "Building skill files from: $SOURCE"
|
|
197
|
+
echo ""
|
|
198
|
+
|
|
199
|
+
case "$TARGET" in
|
|
200
|
+
claude) generate_claude ;;
|
|
201
|
+
opencode) generate_opencode ;;
|
|
202
|
+
openclaw) generate_openclaw ;;
|
|
203
|
+
hermes) generate_hermes ;;
|
|
204
|
+
trae) generate_trae ;;
|
|
205
|
+
trae-skill) generate_trae_skill ;;
|
|
206
|
+
dsh) generate_dsh ;;
|
|
207
|
+
all)
|
|
208
|
+
generate_claude
|
|
209
|
+
generate_opencode
|
|
210
|
+
generate_openclaw
|
|
211
|
+
generate_hermes
|
|
212
|
+
generate_trae
|
|
213
|
+
generate_trae_skill
|
|
214
|
+
generate_dsh
|
|
215
|
+
;;
|
|
216
|
+
*)
|
|
217
|
+
echo "Unknown agent: $TARGET" >&2
|
|
218
|
+
echo "Usage: $0 [claude|opencode|openclaw|hermes|trae|trae-skill|dsh|all]" >&2
|
|
219
|
+
exit 1
|
|
220
|
+
;;
|
|
221
|
+
esac
|
|
222
|
+
|
|
223
|
+
echo ""
|
|
224
|
+
echo "Done. Skill files generated."
|