@drunkcoding/agents-and-skills 0.0.13 → 0.0.15
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/.claude-plugin/marketplace.json +9 -6
- package/README.md +1 -1
- package/package.json +1 -1
- package/plugins/html-effectiveness/.claude-plugin/plugin.json +1 -1
- package/plugins/html-effectiveness/README.md +9 -4
- package/plugins/html-effectiveness/agents/report-builder.md +4 -0
- package/plugins/html-effectiveness/assets/base.css +40 -20
- package/plugins/html-effectiveness/docs/template-gallery.md +28 -0
- package/plugins/html-effectiveness/scripts/_tmp.js +37 -0
- package/plugins/html-effectiveness/scripts/catalog.js +47 -0
- package/plugins/html-effectiveness/scripts/extract.js +104 -0
- package/plugins/html-effectiveness/scripts/render.js +2 -2
- package/plugins/html-effectiveness/skills/html-effectiveness/SKILL.md +4 -4
- package/plugins/html-effectiveness/templates/01-exploration-code-approaches.html.tmpl +400 -0
- package/plugins/html-effectiveness/templates/02-exploration-visual-designs.html.tmpl +456 -0
- package/plugins/html-effectiveness/templates/03-code-review-pr.html.tmpl +581 -0
- package/plugins/html-effectiveness/templates/04-code-understanding.html.tmpl +443 -0
- package/plugins/html-effectiveness/templates/05-design-system.html.tmpl +578 -0
- package/plugins/html-effectiveness/templates/06-component-variants.html.tmpl +557 -0
- package/plugins/html-effectiveness/templates/07-prototype-animation.html.tmpl +417 -0
- package/plugins/html-effectiveness/templates/08-prototype-interaction.html.tmpl +363 -0
- package/plugins/html-effectiveness/templates/09-slide-deck.html.tmpl +535 -0
- package/plugins/html-effectiveness/templates/10-svg-illustrations.html.tmpl +444 -0
- package/plugins/html-effectiveness/templates/11-status-report.html.tmpl +152 -0
- package/plugins/html-effectiveness/templates/12-incident-report.html.tmpl +547 -0
- package/plugins/html-effectiveness/templates/13-flowchart-diagram.html.tmpl +361 -0
- package/plugins/html-effectiveness/templates/14-research-feature-explainer.html.tmpl +348 -0
- package/plugins/html-effectiveness/templates/15-research-concept-explainer.html.tmpl +334 -0
- package/plugins/html-effectiveness/templates/16-implementation-plan.html.tmpl +657 -0
- package/plugins/html-effectiveness/templates/17-pr-writeup.html.tmpl +553 -0
- package/plugins/html-effectiveness/templates/18-editor-triage-board.html.tmpl +541 -0
- package/plugins/html-effectiveness/templates/19-editor-feature-flags.html.tmpl +627 -0
- package/plugins/html-effectiveness/templates/20-editor-prompt-tuner.html.tmpl +687 -0
- package/plugins/html-effectiveness/templates/manifest.json +436 -2
- package/plugins/html-effectiveness/tests/_tmp.test.js +58 -0
- package/plugins/html-effectiveness/tests/fixtures/01-exploration-code-approaches.data.json +3 -0
- package/plugins/html-effectiveness/tests/fixtures/02-exploration-visual-designs.data.json +3 -0
- package/plugins/html-effectiveness/tests/fixtures/03-code-review-pr.data.json +3 -0
- package/plugins/html-effectiveness/tests/fixtures/04-code-understanding.data.json +3 -0
- package/plugins/html-effectiveness/tests/fixtures/05-design-system.data.json +3 -0
- package/plugins/html-effectiveness/tests/fixtures/06-component-variants.data.json +3 -0
- package/plugins/html-effectiveness/tests/fixtures/07-prototype-animation.data.json +3 -0
- package/plugins/html-effectiveness/tests/fixtures/08-prototype-interaction.data.json +3 -0
- package/plugins/html-effectiveness/tests/fixtures/09-slide-deck.data.json +3 -0
- package/plugins/html-effectiveness/tests/fixtures/10-svg-illustrations.data.json +3 -0
- package/plugins/html-effectiveness/tests/fixtures/11-status-report.data.json +37 -0
- package/plugins/html-effectiveness/tests/fixtures/12-incident-report.data.json +3 -0
- package/plugins/html-effectiveness/tests/fixtures/13-flowchart-diagram.data.json +3 -0
- package/plugins/html-effectiveness/tests/fixtures/14-research-feature-explainer.data.json +3 -0
- package/plugins/html-effectiveness/tests/fixtures/15-research-concept-explainer.data.json +3 -0
- package/plugins/html-effectiveness/tests/fixtures/16-implementation-plan.data.json +3 -0
- package/plugins/html-effectiveness/tests/fixtures/17-pr-writeup.data.json +3 -0
- package/plugins/html-effectiveness/tests/fixtures/18-editor-triage-board.data.json +3 -0
- package/plugins/html-effectiveness/tests/fixtures/19-editor-feature-flags.data.json +3 -0
- package/plugins/html-effectiveness/tests/fixtures/20-editor-prompt-tuner.data.json +3 -0
- package/plugins/html-effectiveness/tests/manifest.test.js +61 -0
- package/plugins/plugin-validator/.claude-plugin/plugin.json +1 -1
- package/plugins/plugin-validator/skills/validate-agents/SKILL.md +2 -2
- package/plugins/plugin-validator/skills/validate-commands/SKILL.md +2 -2
- package/plugins/plugin-validator/skills/validate-hooks/SKILL.md +57 -18
- package/plugins/team-superpower/.claude-plugin/plugin.json +7 -39
- package/plugins/team-superpower/README.md +85 -24
- package/plugins/team-superpower/agents/backend-developer.md +82 -0
- package/plugins/team-superpower/agents/designer.md +5 -1
- package/plugins/team-superpower/agents/frontend-developer.md +96 -0
- package/plugins/team-superpower/agents/planner.md +144 -16
- package/plugins/team-superpower/agents/qa-engineer.md +30 -0
- package/plugins/team-superpower/agents/reviewer.md +68 -22
- package/plugins/team-superpower/agents/security-engineer.md +110 -0
- package/plugins/team-superpower/agents/software-architect.md +30 -0
- package/plugins/team-superpower/assets/CLAUDE.md.template +96 -0
- package/plugins/team-superpower/assets/ESCALATION.md +19 -5
- package/plugins/team-superpower/assets/SESSION_README.md +119 -11
- package/plugins/team-superpower/commands/team-feature-resume.md +72 -6
- package/plugins/team-superpower/commands/team-feature.md +329 -28
- package/plugins/team-superpower/hooks/hooks.json +0 -3
- package/plugins/team-superpower/hooks/task-completed.sh +54 -5
- package/plugins/team-superpower/hooks/task-created.sh +79 -4
- package/plugins/team-superpower/scripts/detect-stack.sh +434 -0
- package/plugins/team-superpower/scripts/parse-claudemd.sh +194 -0
- package/plugins/tech-graph/.claude-plugin/plugin.json +1 -1
- package/plugins/tech-graph/agents/tech-graph.md +8 -0
- package/plugins/team-superpower/agents/implementer.md +0 -46
|
@@ -0,0 +1,557 @@
|
|
|
1
|
+
<!--
|
|
2
|
+
template: 06-component-variants
|
|
3
|
+
upstream: 06-component-variants.html
|
|
4
|
+
slots:
|
|
5
|
+
title: string # replaces first <h1> innerHTML
|
|
6
|
+
-->
|
|
7
|
+
<div class="page">
|
|
8
|
+
|
|
9
|
+
<header>
|
|
10
|
+
<h1>{{title}}</h1>
|
|
11
|
+
<p>Six structural treatments of the Acme <code style="font-family:var(--mono);font-size:13px"><Card /></code> component. Adjust density and emphasis with the controls, hover a variant to see its prop combo.</p>
|
|
12
|
+
</header>
|
|
13
|
+
|
|
14
|
+
<!-- ---------- Toolbar ---------- -->
|
|
15
|
+
<div class="toolbar">
|
|
16
|
+
<div class="control">
|
|
17
|
+
<span class="control-label">Padding</span>
|
|
18
|
+
<input id="ctl-pad" type="range" min="12" max="32" value="20" step="2">
|
|
19
|
+
<span class="control-value" id="pad-out">20px</span>
|
|
20
|
+
</div>
|
|
21
|
+
|
|
22
|
+
<div class="control">
|
|
23
|
+
<span class="control-label">Border</span>
|
|
24
|
+
<div class="radio-group">
|
|
25
|
+
<label><input type="radio" name="border" value="none"><span>none</span></label>
|
|
26
|
+
<label><input type="radio" name="border" value="hairline" checked><span>hairline</span></label>
|
|
27
|
+
<label><input type="radio" name="border" value="solid"><span>solid</span></label>
|
|
28
|
+
</div>
|
|
29
|
+
</div>
|
|
30
|
+
|
|
31
|
+
<div class="control">
|
|
32
|
+
<label class="check">
|
|
33
|
+
<input id="ctl-shadow" type="checkbox" checked>
|
|
34
|
+
Show shadow
|
|
35
|
+
</label>
|
|
36
|
+
</div>
|
|
37
|
+
</div>
|
|
38
|
+
|
|
39
|
+
<!-- ---------- Grid ---------- -->
|
|
40
|
+
<div class="grid" id="grid">
|
|
41
|
+
|
|
42
|
+
<!-- A: Flat -->
|
|
43
|
+
<div class="cell">
|
|
44
|
+
<span class="variant-label">A · Flat</span>
|
|
45
|
+
<div class="card v-flat"
|
|
46
|
+
data-snippet='<Card variant="flat" padding={PAD}>
|
|
47
|
+
<Card.Header avatar title="Weekly planning" subtitle="12 tasks · due Friday" />
|
|
48
|
+
<Card.Meta tags={["Q2", "Roadmap"]} />
|
|
49
|
+
<Button variant="ghost">Open</Button>
|
|
50
|
+
</Card>'>
|
|
51
|
+
<div class="card-head">
|
|
52
|
+
<div class="avatar">WP</div>
|
|
53
|
+
<div class="card-titles">
|
|
54
|
+
<p class="card-title">Weekly planning</p>
|
|
55
|
+
<p class="card-sub">12 tasks · due Friday</p>
|
|
56
|
+
</div>
|
|
57
|
+
</div>
|
|
58
|
+
<div class="chips">
|
|
59
|
+
<span class="chip">Q2</span>
|
|
60
|
+
<span class="chip olive">Roadmap</span>
|
|
61
|
+
</div>
|
|
62
|
+
<button class="ghost-btn">Open</button>
|
|
63
|
+
</div>
|
|
64
|
+
<p class="variant-note">best for: dense lists on tinted backgrounds</p>
|
|
65
|
+
</div>
|
|
66
|
+
|
|
67
|
+
<!-- B: Outlined -->
|
|
68
|
+
<div class="cell">
|
|
69
|
+
<span class="variant-label">B · Outlined</span>
|
|
70
|
+
<div class="card v-outlined"
|
|
71
|
+
data-snippet='<Card variant="outlined" padding={PAD} border="BORDER">
|
|
72
|
+
<Card.Header avatar title="Weekly planning" subtitle="12 tasks · due Friday" />
|
|
73
|
+
<Card.Meta tags={["Q2", "Roadmap"]} />
|
|
74
|
+
<Button variant="ghost">Open</Button>
|
|
75
|
+
</Card>'>
|
|
76
|
+
<div class="card-head">
|
|
77
|
+
<div class="avatar">WP</div>
|
|
78
|
+
<div class="card-titles">
|
|
79
|
+
<p class="card-title">Weekly planning</p>
|
|
80
|
+
<p class="card-sub">12 tasks · due Friday</p>
|
|
81
|
+
</div>
|
|
82
|
+
</div>
|
|
83
|
+
<div class="chips">
|
|
84
|
+
<span class="chip">Q2</span>
|
|
85
|
+
<span class="chip olive">Roadmap</span>
|
|
86
|
+
</div>
|
|
87
|
+
<button class="ghost-btn">Open</button>
|
|
88
|
+
</div>
|
|
89
|
+
<p class="variant-note">best for: default content cards on ivory</p>
|
|
90
|
+
</div>
|
|
91
|
+
|
|
92
|
+
<!-- C: Elevated -->
|
|
93
|
+
<div class="cell">
|
|
94
|
+
<span class="variant-label">C · Elevated</span>
|
|
95
|
+
<div class="card v-elevated"
|
|
96
|
+
data-snippet='<Card variant="elevated" padding={PAD} shadow="md">
|
|
97
|
+
<Card.Header avatar title="Weekly planning" subtitle="12 tasks · due Friday" />
|
|
98
|
+
<Card.Meta tags={["Q2", "Roadmap"]} />
|
|
99
|
+
<Button variant="ghost">Open</Button>
|
|
100
|
+
</Card>'>
|
|
101
|
+
<div class="card-head">
|
|
102
|
+
<div class="avatar">WP</div>
|
|
103
|
+
<div class="card-titles">
|
|
104
|
+
<p class="card-title">Weekly planning</p>
|
|
105
|
+
<p class="card-sub">12 tasks · due Friday</p>
|
|
106
|
+
</div>
|
|
107
|
+
</div>
|
|
108
|
+
<div class="chips">
|
|
109
|
+
<span class="chip">Q2</span>
|
|
110
|
+
<span class="chip olive">Roadmap</span>
|
|
111
|
+
</div>
|
|
112
|
+
<button class="ghost-btn">Open</button>
|
|
113
|
+
</div>
|
|
114
|
+
<p class="variant-note">best for: draggable items, popovers</p>
|
|
115
|
+
</div>
|
|
116
|
+
|
|
117
|
+
<!-- D: Accent stripe -->
|
|
118
|
+
<div class="cell">
|
|
119
|
+
<span class="variant-label">D · Accent stripe</span>
|
|
120
|
+
<div class="card v-stripe"
|
|
121
|
+
data-snippet='<Card variant="outlined" accent="clay" padding={PAD} border="BORDER">
|
|
122
|
+
<Card.Header avatar title="Weekly planning" subtitle="12 tasks · due Friday" />
|
|
123
|
+
<Card.Meta tags={["Q2", "Roadmap"]} />
|
|
124
|
+
<Button variant="ghost">Open</Button>
|
|
125
|
+
</Card>'>
|
|
126
|
+
<div class="card-head">
|
|
127
|
+
<div class="avatar">WP</div>
|
|
128
|
+
<div class="card-titles">
|
|
129
|
+
<p class="card-title">Weekly planning</p>
|
|
130
|
+
<p class="card-sub">12 tasks · due Friday</p>
|
|
131
|
+
</div>
|
|
132
|
+
</div>
|
|
133
|
+
<div class="chips">
|
|
134
|
+
<span class="chip">Q2</span>
|
|
135
|
+
<span class="chip olive">Roadmap</span>
|
|
136
|
+
</div>
|
|
137
|
+
<button class="ghost-btn">Open</button>
|
|
138
|
+
</div>
|
|
139
|
+
<p class="variant-note">best for: pinned or priority items</p>
|
|
140
|
+
</div>
|
|
141
|
+
|
|
142
|
+
<!-- E: Inset / filled -->
|
|
143
|
+
<div class="cell">
|
|
144
|
+
<span class="variant-label">E · Inset</span>
|
|
145
|
+
<div class="card v-inset"
|
|
146
|
+
data-snippet='<Card variant="filled" tone="oat" padding={PAD}>
|
|
147
|
+
<Card.Header avatar title="Weekly planning" subtitle="12 tasks · due Friday" />
|
|
148
|
+
<Card.Meta tags={["Q2", "Roadmap"]} />
|
|
149
|
+
<Button variant="ghost">Open</Button>
|
|
150
|
+
</Card>'>
|
|
151
|
+
<div class="card-head">
|
|
152
|
+
<div class="avatar">WP</div>
|
|
153
|
+
<div class="card-titles">
|
|
154
|
+
<p class="card-title">Weekly planning</p>
|
|
155
|
+
<p class="card-sub">12 tasks · due Friday</p>
|
|
156
|
+
</div>
|
|
157
|
+
</div>
|
|
158
|
+
<div class="chips">
|
|
159
|
+
<span class="chip">Q2</span>
|
|
160
|
+
<span class="chip olive">Roadmap</span>
|
|
161
|
+
</div>
|
|
162
|
+
<button class="ghost-btn">Open</button>
|
|
163
|
+
</div>
|
|
164
|
+
<p class="variant-note">best for: nested cards inside white panels</p>
|
|
165
|
+
</div>
|
|
166
|
+
|
|
167
|
+
<!-- F: Horizontal / compact -->
|
|
168
|
+
<div class="cell">
|
|
169
|
+
<span class="variant-label">F · Horizontal</span>
|
|
170
|
+
<div class="card v-horizontal"
|
|
171
|
+
data-snippet='<Card variant="outlined" layout="row" padding={PAD} border="BORDER">
|
|
172
|
+
<Card.Header avatar title="Weekly planning" />
|
|
173
|
+
<Card.Meta tags={["Q2", "Roadmap"]} />
|
|
174
|
+
<Button variant="ghost">Open</Button>
|
|
175
|
+
</Card>'>
|
|
176
|
+
<div class="card-head">
|
|
177
|
+
<div class="avatar">WP</div>
|
|
178
|
+
<div class="card-titles">
|
|
179
|
+
<p class="card-title">Weekly planning</p>
|
|
180
|
+
<p class="card-sub">12 tasks · due Friday</p>
|
|
181
|
+
</div>
|
|
182
|
+
</div>
|
|
183
|
+
<div class="chips">
|
|
184
|
+
<span class="chip">Q2</span>
|
|
185
|
+
<span class="chip olive">Roadmap</span>
|
|
186
|
+
</div>
|
|
187
|
+
<button class="ghost-btn">Open</button>
|
|
188
|
+
</div>
|
|
189
|
+
<p class="variant-note">best for: compact row lists, sidebars</p>
|
|
190
|
+
</div>
|
|
191
|
+
|
|
192
|
+
</div>
|
|
193
|
+
|
|
194
|
+
<!-- ---------- Snippet ---------- -->
|
|
195
|
+
<div class="snippet-panel">
|
|
196
|
+
<div class="snippet-head">JSX — hover a variant above</div>
|
|
197
|
+
<pre id="snippet">// hover a card to preview its props</pre>
|
|
198
|
+
</div>
|
|
199
|
+
|
|
200
|
+
</div>
|
|
201
|
+
|
|
202
|
+
<style>
|
|
203
|
+
* { box-sizing: border-box; }
|
|
204
|
+
.page {
|
|
205
|
+
max-width: 1100px;
|
|
206
|
+
margin: 0 auto;
|
|
207
|
+
padding: 0 28px 80px;
|
|
208
|
+
}
|
|
209
|
+
header {
|
|
210
|
+
padding: 48px 0 20px;
|
|
211
|
+
}
|
|
212
|
+
header h1 {
|
|
213
|
+
font-family: var(--serif);
|
|
214
|
+
font-weight: 500;
|
|
215
|
+
font-size: 36px;
|
|
216
|
+
letter-spacing: -0.01em;
|
|
217
|
+
margin: 0 0 6px;
|
|
218
|
+
}
|
|
219
|
+
header p {
|
|
220
|
+
color: var(--gray-500);
|
|
221
|
+
font-size: 14px;
|
|
222
|
+
margin: 0;
|
|
223
|
+
max-width: 640px;
|
|
224
|
+
}
|
|
225
|
+
/* ---------- Toolbar ---------- */
|
|
226
|
+
.toolbar {
|
|
227
|
+
position: sticky;
|
|
228
|
+
top: 0;
|
|
229
|
+
z-index: 10;
|
|
230
|
+
display: flex;
|
|
231
|
+
flex-wrap: wrap;
|
|
232
|
+
align-items: center;
|
|
233
|
+
gap: 28px;
|
|
234
|
+
padding: 16px 20px;
|
|
235
|
+
margin: 24px 0 36px;
|
|
236
|
+
background: var(--white);
|
|
237
|
+
border: 1.5px solid var(--gray-300);
|
|
238
|
+
border-radius: 12px;
|
|
239
|
+
}
|
|
240
|
+
.control {
|
|
241
|
+
display: flex;
|
|
242
|
+
align-items: center;
|
|
243
|
+
gap: 10px;
|
|
244
|
+
}
|
|
245
|
+
.control-label {
|
|
246
|
+
font-family: var(--mono);
|
|
247
|
+
font-size: 12px;
|
|
248
|
+
color: var(--gray-700);
|
|
249
|
+
}
|
|
250
|
+
.control-value {
|
|
251
|
+
font-family: var(--mono);
|
|
252
|
+
font-size: 12px;
|
|
253
|
+
color: var(--gray-500);
|
|
254
|
+
min-width: 36px;
|
|
255
|
+
}
|
|
256
|
+
input[type="range"] {
|
|
257
|
+
appearance: none;
|
|
258
|
+
width: 140px;
|
|
259
|
+
height: 4px;
|
|
260
|
+
background: var(--gray-300);
|
|
261
|
+
border-radius: 2px;
|
|
262
|
+
outline: none;
|
|
263
|
+
}
|
|
264
|
+
input[type="range"]::-webkit-slider-thumb {
|
|
265
|
+
appearance: none;
|
|
266
|
+
width: 16px; height: 16px;
|
|
267
|
+
background: var(--clay);
|
|
268
|
+
border-radius: 50%;
|
|
269
|
+
cursor: pointer;
|
|
270
|
+
}
|
|
271
|
+
input[type="range"]::-moz-range-thumb {
|
|
272
|
+
width: 16px; height: 16px;
|
|
273
|
+
background: var(--clay);
|
|
274
|
+
border: none;
|
|
275
|
+
border-radius: 50%;
|
|
276
|
+
cursor: pointer;
|
|
277
|
+
}
|
|
278
|
+
.radio-group {
|
|
279
|
+
display: inline-flex;
|
|
280
|
+
border: 1.5px solid var(--gray-300);
|
|
281
|
+
border-radius: 8px;
|
|
282
|
+
overflow: hidden;
|
|
283
|
+
}
|
|
284
|
+
.radio-group label {
|
|
285
|
+
padding: 6px 12px;
|
|
286
|
+
font-size: 13px;
|
|
287
|
+
cursor: pointer;
|
|
288
|
+
user-select: none;
|
|
289
|
+
color: var(--gray-700);
|
|
290
|
+
border-right: 1px solid var(--gray-300);
|
|
291
|
+
}
|
|
292
|
+
.radio-group label:last-child { border-right: none; }
|
|
293
|
+
.radio-group input { display: none; }
|
|
294
|
+
.radio-group input:checked + span {
|
|
295
|
+
color: var(--slate);
|
|
296
|
+
}
|
|
297
|
+
.radio-group label:has(input:checked) {
|
|
298
|
+
background: var(--gray-100);
|
|
299
|
+
}
|
|
300
|
+
.check {
|
|
301
|
+
display: inline-flex;
|
|
302
|
+
align-items: center;
|
|
303
|
+
gap: 8px;
|
|
304
|
+
font-size: 13px;
|
|
305
|
+
cursor: pointer;
|
|
306
|
+
user-select: none;
|
|
307
|
+
}
|
|
308
|
+
.check input {
|
|
309
|
+
appearance: none;
|
|
310
|
+
width: 16px; height: 16px;
|
|
311
|
+
border: 1.5px solid var(--gray-300);
|
|
312
|
+
border-radius: 4px;
|
|
313
|
+
margin: 0;
|
|
314
|
+
cursor: pointer;
|
|
315
|
+
position: relative;
|
|
316
|
+
}
|
|
317
|
+
.check input:checked {
|
|
318
|
+
background: var(--clay);
|
|
319
|
+
border-color: var(--clay);
|
|
320
|
+
}
|
|
321
|
+
.check input:checked::after {
|
|
322
|
+
content: "";
|
|
323
|
+
position: absolute;
|
|
324
|
+
left: 4px; top: 0;
|
|
325
|
+
width: 4px; height: 9px;
|
|
326
|
+
border: solid var(--white);
|
|
327
|
+
border-width: 0 2px 2px 0;
|
|
328
|
+
transform: rotate(45deg);
|
|
329
|
+
}
|
|
330
|
+
/* ---------- Grid ---------- */
|
|
331
|
+
.grid {
|
|
332
|
+
display: grid;
|
|
333
|
+
grid-template-columns: repeat(3, 1fr);
|
|
334
|
+
gap: 28px;
|
|
335
|
+
}
|
|
336
|
+
@media (max-width: 960px) {
|
|
337
|
+
.grid { grid-template-columns: repeat(2, 1fr); }
|
|
338
|
+
}
|
|
339
|
+
@media (max-width: 640px) {
|
|
340
|
+
.grid { grid-template-columns: 1fr; }
|
|
341
|
+
}
|
|
342
|
+
.cell {}
|
|
343
|
+
.variant-label {
|
|
344
|
+
display: inline-flex;
|
|
345
|
+
align-items: center;
|
|
346
|
+
height: 22px;
|
|
347
|
+
padding: 0 9px;
|
|
348
|
+
font-family: var(--mono);
|
|
349
|
+
font-size: 11px;
|
|
350
|
+
font-weight: 500;
|
|
351
|
+
color: var(--gray-700);
|
|
352
|
+
background: var(--gray-100);
|
|
353
|
+
border-radius: 999px;
|
|
354
|
+
margin-bottom: 10px;
|
|
355
|
+
}
|
|
356
|
+
.variant-note {
|
|
357
|
+
font-size: 12px;
|
|
358
|
+
color: var(--gray-500);
|
|
359
|
+
margin-top: 10px;
|
|
360
|
+
}
|
|
361
|
+
/* ---------- Card base ---------- */
|
|
362
|
+
.card {
|
|
363
|
+
border-radius: 12px;
|
|
364
|
+
padding: var(--card-pad);
|
|
365
|
+
transition: padding 0.15s ease, box-shadow 0.15s ease, border 0.15s ease;
|
|
366
|
+
cursor: pointer;
|
|
367
|
+
}
|
|
368
|
+
.card:hover { outline: 2px solid var(--clay); outline-offset: 2px; }
|
|
369
|
+
.card-head {
|
|
370
|
+
display: flex;
|
|
371
|
+
align-items: center;
|
|
372
|
+
gap: 12px;
|
|
373
|
+
margin-bottom: 12px;
|
|
374
|
+
}
|
|
375
|
+
.avatar {
|
|
376
|
+
width: 36px; height: 36px;
|
|
377
|
+
border-radius: 50%;
|
|
378
|
+
background: var(--oat);
|
|
379
|
+
flex-shrink: 0;
|
|
380
|
+
display: flex;
|
|
381
|
+
align-items: center;
|
|
382
|
+
justify-content: center;
|
|
383
|
+
font-size: 13px;
|
|
384
|
+
font-weight: 600;
|
|
385
|
+
color: var(--gray-700);
|
|
386
|
+
}
|
|
387
|
+
.card-titles { min-width: 0; }
|
|
388
|
+
.card-title {
|
|
389
|
+
font-family: var(--serif);
|
|
390
|
+
font-size: 17px;
|
|
391
|
+
font-weight: 500;
|
|
392
|
+
margin: 0 0 2px;
|
|
393
|
+
line-height: 1.3;
|
|
394
|
+
}
|
|
395
|
+
.card-sub {
|
|
396
|
+
font-size: 13px;
|
|
397
|
+
color: var(--gray-500);
|
|
398
|
+
margin: 0;
|
|
399
|
+
white-space: nowrap;
|
|
400
|
+
overflow: hidden;
|
|
401
|
+
text-overflow: ellipsis;
|
|
402
|
+
}
|
|
403
|
+
.chips {
|
|
404
|
+
display: flex;
|
|
405
|
+
gap: 6px;
|
|
406
|
+
margin-bottom: 14px;
|
|
407
|
+
}
|
|
408
|
+
.chip {
|
|
409
|
+
display: inline-flex;
|
|
410
|
+
align-items: center;
|
|
411
|
+
height: 20px;
|
|
412
|
+
padding: 0 8px;
|
|
413
|
+
font-size: 11px;
|
|
414
|
+
font-weight: 500;
|
|
415
|
+
border-radius: 999px;
|
|
416
|
+
background: var(--gray-100);
|
|
417
|
+
color: var(--gray-700);
|
|
418
|
+
}
|
|
419
|
+
.chip.olive { background: rgba(120,140,93,0.16); color: var(--olive); }
|
|
420
|
+
.ghost-btn {
|
|
421
|
+
display: inline-flex;
|
|
422
|
+
align-items: center;
|
|
423
|
+
height: 30px;
|
|
424
|
+
padding: 0 12px;
|
|
425
|
+
font-size: 13px;
|
|
426
|
+
font-weight: 500;
|
|
427
|
+
color: var(--gray-700);
|
|
428
|
+
background: transparent;
|
|
429
|
+
border: 1.5px solid var(--gray-300);
|
|
430
|
+
border-radius: 8px;
|
|
431
|
+
cursor: pointer;
|
|
432
|
+
}
|
|
433
|
+
.ghost-btn:hover { background: var(--gray-100); }
|
|
434
|
+
/* ---------- Variant treatments ---------- */
|
|
435
|
+
.v-flat {
|
|
436
|
+
background: var(--white);
|
|
437
|
+
border: none;
|
|
438
|
+
box-shadow: none;
|
|
439
|
+
}
|
|
440
|
+
.v-outlined {
|
|
441
|
+
background: var(--white);
|
|
442
|
+
border: var(--card-border);
|
|
443
|
+
box-shadow: none;
|
|
444
|
+
}
|
|
445
|
+
.v-elevated {
|
|
446
|
+
background: var(--white);
|
|
447
|
+
border: none;
|
|
448
|
+
box-shadow: var(--card-shadow);
|
|
449
|
+
}
|
|
450
|
+
.v-stripe {
|
|
451
|
+
background: var(--white);
|
|
452
|
+
border: var(--card-border);
|
|
453
|
+
box-shadow: none;
|
|
454
|
+
position: relative;
|
|
455
|
+
overflow: hidden;
|
|
456
|
+
}
|
|
457
|
+
.v-stripe::before {
|
|
458
|
+
content: "";
|
|
459
|
+
position: absolute;
|
|
460
|
+
left: 0; right: 0; top: 0;
|
|
461
|
+
height: 4px;
|
|
462
|
+
background: var(--clay);
|
|
463
|
+
}
|
|
464
|
+
.v-inset {
|
|
465
|
+
background: var(--oat);
|
|
466
|
+
border: none;
|
|
467
|
+
box-shadow: none;
|
|
468
|
+
}
|
|
469
|
+
.v-inset .chip { background: rgba(255,255,255,0.6); }
|
|
470
|
+
.v-inset .ghost-btn { border-color: rgba(20,20,19,0.15); }
|
|
471
|
+
.v-inset .avatar { background: var(--white); }
|
|
472
|
+
.v-horizontal {
|
|
473
|
+
background: var(--white);
|
|
474
|
+
border: var(--card-border);
|
|
475
|
+
box-shadow: none;
|
|
476
|
+
display: flex;
|
|
477
|
+
align-items: center;
|
|
478
|
+
gap: 14px;
|
|
479
|
+
}
|
|
480
|
+
.v-horizontal .card-head { margin: 0; flex: 1; min-width: 0; }
|
|
481
|
+
.v-horizontal .chips { margin: 0; }
|
|
482
|
+
.v-horizontal .card-sub { display: none; }
|
|
483
|
+
.v-horizontal .ghost-btn { flex-shrink: 0; }
|
|
484
|
+
/* ---------- Snippet panel ---------- */
|
|
485
|
+
.snippet-panel {
|
|
486
|
+
margin-top: 40px;
|
|
487
|
+
border: 1.5px solid var(--gray-300);
|
|
488
|
+
border-radius: 12px;
|
|
489
|
+
overflow: hidden;
|
|
490
|
+
}
|
|
491
|
+
.snippet-head {
|
|
492
|
+
padding: 10px 16px;
|
|
493
|
+
font-family: var(--mono);
|
|
494
|
+
font-size: 12px;
|
|
495
|
+
color: var(--gray-500);
|
|
496
|
+
background: var(--gray-100);
|
|
497
|
+
border-bottom: 1px solid var(--gray-300);
|
|
498
|
+
}
|
|
499
|
+
pre#snippet {
|
|
500
|
+
margin: 0;
|
|
501
|
+
padding: 20px;
|
|
502
|
+
background: var(--slate);
|
|
503
|
+
color: var(--ivory);
|
|
504
|
+
font-family: var(--mono);
|
|
505
|
+
font-size: 13px;
|
|
506
|
+
line-height: 1.6;
|
|
507
|
+
overflow-x: auto;
|
|
508
|
+
min-height: 120px;
|
|
509
|
+
}
|
|
510
|
+
</style>
|
|
511
|
+
|
|
512
|
+
<script>
|
|
513
|
+
(function () {
|
|
514
|
+
var root = document.documentElement;
|
|
515
|
+
var pad = document.getElementById('ctl-pad');
|
|
516
|
+
var padOut = document.getElementById('pad-out');
|
|
517
|
+
var shadow = document.getElementById('ctl-shadow');
|
|
518
|
+
var snippet = document.getElementById('snippet');
|
|
519
|
+
var currentBorder = 'hairline';
|
|
520
|
+
|
|
521
|
+
var borderMap = {
|
|
522
|
+
none: 'none',
|
|
523
|
+
hairline: '1px solid var(--gray-300)',
|
|
524
|
+
solid: '1.5px solid var(--gray-300)'
|
|
525
|
+
};
|
|
526
|
+
|
|
527
|
+
function applyPad() {
|
|
528
|
+
root.style.setProperty('--card-pad', pad.value + 'px');
|
|
529
|
+
padOut.textContent = pad.value + 'px';
|
|
530
|
+
}
|
|
531
|
+
function applyBorder(v) {
|
|
532
|
+
currentBorder = v;
|
|
533
|
+
root.style.setProperty('--card-border', borderMap[v]);
|
|
534
|
+
}
|
|
535
|
+
function applyShadow() {
|
|
536
|
+
root.style.setProperty('--card-shadow',
|
|
537
|
+
shadow.checked ? '0 4px 14px rgba(20,20,19,0.08)' : 'none');
|
|
538
|
+
}
|
|
539
|
+
|
|
540
|
+
pad.addEventListener('input', applyPad);
|
|
541
|
+
shadow.addEventListener('change', applyShadow);
|
|
542
|
+
document.querySelectorAll('input[name="border"]').forEach(function (r) {
|
|
543
|
+
r.addEventListener('change', function () { applyBorder(r.value); });
|
|
544
|
+
});
|
|
545
|
+
|
|
546
|
+
document.querySelectorAll('.card').forEach(function (card) {
|
|
547
|
+
card.addEventListener('mouseenter', function () {
|
|
548
|
+
var raw = card.getAttribute('data-snippet') || '';
|
|
549
|
+
snippet.textContent = raw
|
|
550
|
+
.replace(/PAD/g, pad.value)
|
|
551
|
+
.replace(/BORDER/g, currentBorder);
|
|
552
|
+
});
|
|
553
|
+
});
|
|
554
|
+
|
|
555
|
+
applyPad(); applyBorder('hairline'); applyShadow();
|
|
556
|
+
})();
|
|
557
|
+
</script>
|