egatari 0.6.6 → 0.6.7-rc.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/NOTICE +6 -0
- package/README.ja.md +3 -3
- package/README.md +3 -3
- package/bin/egatari.mjs +2 -2
- package/components.lock.json +33 -15
- package/components2.lock.json +409 -1
- package/kit/build.mjs +28 -4
- package/kit/check-messages.mjs +14 -0
- package/kit/check.mjs +21 -0
- package/kit/core/build-core.mjs +84 -19
- package/kit/core/colab-core.mjs +3 -1
- package/kit/core/fill-measure.mjs +79 -0
- package/kit/core/font-coverage.mjs +52 -0
- package/kit/core/font-subset-core.mjs +101 -0
- package/kit/core/llm-fix.mjs +3 -2
- package/kit/core/llm-pack-data.mjs +39 -41
- package/kit/core/parts2.mjs +34 -0
- package/kit/core/portable.mjs +30 -2
- package/kit/core/scorm.mjs +109 -0
- package/kit/core/tier-a.mjs +72 -26
- package/kit/core/zip-write.mjs +57 -0
- package/kit/deck.js +118 -29
- package/kit/fill-scan.mjs +95 -0
- package/kit/font-subset.mjs +33 -0
- package/kit/instruction-version.json +1 -1
- package/kit/live.js +3 -1
- package/kit/llm-pack.mjs +15 -14
- package/kit/panes.js +26 -14
- package/kit/player.json +1 -1
- package/kit/player.lock.json +2 -2
- package/kit/tools.js +20 -23
- package/kit/track.js +11 -5
- package/package.json +4 -2
- package/render/audio-track.mjs +112 -0
- package/render/render.mjs +99 -51
- package/tools/video.mjs +17 -9
- package/vendor/components/CATALOG.md +2 -2
- package/vendor/components/sha256/0787c5bbf2e61801398aeefc39a3674b1fc0e556173c450b85cafa4201cb44a6/README.en.md +40 -0
- package/vendor/components/sha256/0787c5bbf2e61801398aeefc39a3674b1fc0e556173c450b85cafa4201cb44a6/index.js +348 -0
- package/vendor/components/sha256/0cab77d128c5f304c2d2ba32841b0bc5adc54b4e72f6681e0a0dda68c96b5d7e/README.en.md +32 -0
- package/vendor/components/sha256/0cab77d128c5f304c2d2ba32841b0bc5adc54b4e72f6681e0a0dda68c96b5d7e/index.js +222 -0
- package/vendor/components/sha256/25eab59287c5c52f9d2f8a7cee3d61ed513cc1c9ca846bba96b45cd59b39f822/README.en.md +42 -0
- package/vendor/components/sha256/25eab59287c5c52f9d2f8a7cee3d61ed513cc1c9ca846bba96b45cd59b39f822/index.js +481 -0
- package/vendor/components/sha256/28238c4fa50a377b96ce8a130ce5bdbf7bfc0536ed9c331499ea22377c43adb6/README.en.md +39 -0
- package/vendor/components/sha256/28238c4fa50a377b96ce8a130ce5bdbf7bfc0536ed9c331499ea22377c43adb6/index.js +323 -0
- package/vendor/components/sha256/2f1c797ecd028d04ce12b3d55d8ef9d5a4180d564aa99afb492d0bfc9cd39c94/README.en.md +42 -0
- package/vendor/components/sha256/2f1c797ecd028d04ce12b3d55d8ef9d5a4180d564aa99afb492d0bfc9cd39c94/index.js +267 -0
- package/vendor/components/sha256/389ab61c0dafed88074c0c459ed40b6738bec05ebf6e4566bba1394405f2392e/README.en.md +52 -0
- package/vendor/components/sha256/389ab61c0dafed88074c0c459ed40b6738bec05ebf6e4566bba1394405f2392e/index.js +219 -0
- package/vendor/components/sha256/3df7d0ec0c3ed4a6b06fbe3befec78b65a2202e5571580d8b28700a14b7b4321/README.en.md +66 -0
- package/vendor/components/sha256/3df7d0ec0c3ed4a6b06fbe3befec78b65a2202e5571580d8b28700a14b7b4321/index.js +920 -0
- package/vendor/components/sha256/40571cbc11cd649c447da73ede0f89937da344b05d4386abeb4afeecedfe7d3e/README.en.md +32 -0
- package/vendor/components/sha256/40571cbc11cd649c447da73ede0f89937da344b05d4386abeb4afeecedfe7d3e/index.js +352 -0
- package/vendor/components/sha256/4dd7e6a02f4128e90d4e2a86cccd9bf267a02cebcff1cdf36e0aaff8848af66e/README.en.md +31 -0
- package/vendor/components/sha256/4dd7e6a02f4128e90d4e2a86cccd9bf267a02cebcff1cdf36e0aaff8848af66e/index.js +232 -0
- package/vendor/components/sha256/520606a746b0d38fdc1aa380e665a1b95eead2487b11f389d2ebac4abe8f07cb/README.en.md +48 -0
- package/vendor/components/sha256/520606a746b0d38fdc1aa380e665a1b95eead2487b11f389d2ebac4abe8f07cb/index.js +384 -0
- package/vendor/components/sha256/554ed56e1ec963627be86ba1f573099ff57cf4cb22e8e10ce00e2128e30d39e2/README.en.md +42 -0
- package/vendor/components/sha256/554ed56e1ec963627be86ba1f573099ff57cf4cb22e8e10ce00e2128e30d39e2/index.js +481 -0
- package/vendor/components/sha256/782ae2154247b00451fc30aa140bf386d3a7a56ac4ad9ee04916f4bd1d29dda0/README.en.md +37 -0
- package/vendor/components/sha256/782ae2154247b00451fc30aa140bf386d3a7a56ac4ad9ee04916f4bd1d29dda0/index.js +424 -0
- package/vendor/components/sha256/808f748e76833742bb12a80482b37cb3dedaf3dcd592ee477d611cb40e95b094/README.en.md +44 -0
- package/vendor/components/sha256/808f748e76833742bb12a80482b37cb3dedaf3dcd592ee477d611cb40e95b094/index.js +304 -0
- package/vendor/components/sha256/8c3d7e9921f249cf45ce26d5a449f2b01fef683f500afed69d0b189312c4464e/index.js +904 -0
- package/vendor/components/sha256/96ad8eaf0ea7c23a31b72657964f23a02165765845991cafc41ee2835b97e40f/README.en.md +42 -0
- package/vendor/components/sha256/96ad8eaf0ea7c23a31b72657964f23a02165765845991cafc41ee2835b97e40f/index.js +170 -0
- package/vendor/components/sha256/b86c0e95622ff3be5fb0b208672ebca5018c34fd192e1b431cfd0fe912df2a7f/index.js +916 -0
- package/vendor/components/sha256/bec04685638f8fc1217c380d361fd9a425ffeade0291a4f2b2d4e41a5628e0ef/index.js +809 -0
- package/vendor/components/sha256/c3d3d56101f430f3468a8f281055c3ea5093fc5c77a35f14fabeb85ad363e209/README.en.md +37 -0
- package/vendor/components/sha256/c3d3d56101f430f3468a8f281055c3ea5093fc5c77a35f14fabeb85ad363e209/index.js +424 -0
- package/vendor/components/sha256/e1a0240f83e1925ee59ef2752662e2b0ec27f69251c012f8bab682aadcd8695f/README.en.md +34 -0
- package/vendor/components/sha256/e1a0240f83e1925ee59ef2752662e2b0ec27f69251c012f8bab682aadcd8695f/index.js +244 -0
- package/vendor/components/sha256/e2181655ed2050668133e08eb14b5683cda48d6af8d76fd7b551c58798c95287/README.en.md +50 -0
- package/vendor/components/sha256/e2181655ed2050668133e08eb14b5683cda48d6af8d76fd7b551c58798c95287/index.js +171 -0
- package/vendor/components/sha256/ef9c8c77ddf2b3953376a2db700c1277f550ea2606eab11cd8e18056dcba84c1/README.en.md +35 -0
- package/vendor/components/sha256/ef9c8c77ddf2b3953376a2db700c1277f550ea2606eab11cd8e18056dcba84c1/index.js +179 -0
- package/vendor/components/sha256/f3d5b6ce53f40c5f355a67538ff11b9cd28297da6292125ccb6e055aeddef906/README.en.md +51 -0
- package/vendor/components/sha256/f3d5b6ce53f40c5f355a67538ff11b9cd28297da6292125ccb6e055aeddef906/index.js +228 -0
- package/vendor/components-2/manifest-2.4.3.json +1962 -0
- package/vendor/components-2/manifest-2.4.4.json +1911 -0
- package/vendor/components-2/manifest-2.5.0.json +1911 -0
|
@@ -748,9 +748,9 @@ export const PACK = {
|
|
|
748
748
|
"m-collect",
|
|
749
749
|
"m-kakijun"
|
|
750
750
|
],
|
|
751
|
-
"partsSrc": "https://github.com/egatari/components/blob/v2.
|
|
751
|
+
"partsSrc": "https://github.com/egatari/components/blob/v2.5.0/components/",
|
|
752
752
|
"en": {
|
|
753
|
-
"common": "# Instructions for the AI\n\nPack version: `2dcfdea9`\n\nYou will write one short **Egatari lesson**: an HTML slide deck with step-by-step reveals (`deck.html`) and a spoken script for it (`narration.md`). Both files are built and quality-checked automatically; anything not described here is not available. Write the lesson in the language the user asks for (slides and narration in the same language). Standards have ids such as **R-fit**; a fix request names the standards a draft broke. The user's request is in **What I want** at the end (or in the conversation before it): choose sensibly for any field that is empty or missing, and if both A and B are left, follow the one with content.\n\n**Before you start (the most common failures):**\n\n- **Both code blocks must be complete and closed.** Never stop in the middle of a block (R-output). Without an outline, keep the lesson short (5–8 slides). When the request gives an outline and a range of its slides, write exactly the slides of that range: the editor asks for at most 6 at a time, so they fit.\n- **Sizes on the 1280×720 slide** (the quality checker measures them, R-fit): the body area is 1184 × 443 px (to 565 px; 1184 × 558 with `noconcl`). Body text is 32 px with 46 px per line, so about **8 lines** fit; every overflowing 46 px is one line to cut. **All text, also inside figures and components, is at least 24 px.**\n- **Charts and figures:** components draw their labels at 24–28 px whatever their size (their SVG uses their own pixels), so size the component, not the text. A component of 380 px leaves room for one short line; with two lines, use 330 px.\n- **Inline `<svg>`:** its text is scaled by displayed width ÷ viewBox width, so write the viewBox in the pixels it is shown at, e.g. `<svg viewBox=\"0 0 560 320\" width=\"560\" height=\"320\">`, with `font-size` ≥ 24. Never combine `width:100%` with another viewBox width (a 600-wide viewBox shown 580 px wide turns 24 into 23.2 px). Prefer a component when one fits.\n\n## 1. Output format\n\n- **R-output** Reply with **exactly two fenced code blocks**, in this order, labelled `deck.html` and `narration.md` (the opening lines are ```` ```deck.html ```` and ```` ```narration.md ````). Put nothing between them; a one-line note before or after is fine. Never split a file over several blocks. Do not output files, a canvas or attachments: write both code blocks in the body of your chat message. Do not reference other files (no images, no `{{FIG:…}}`, no `{{JSON:…}}`, no external URLs, no `<link>`), and never stop in the middle of a block: if the deck would be too long, make fewer slides (but for a range of an outline, write exactly the requested slides).\n- **R-outline** When the request asks for an **outline only** (a long lesson made in two passes), reply with exactly one fenced code block labelled `outline` (the opening line is ```` ```outline ````) and no `deck.html` or `narration.md`: a Markdown table with the columns `#`, heading and point (one line), one row per slide, every slide of the lesson in order. Each later request names a range (“slides 7–12 of the outline”): write exactly those slides, following their headings and points.\n- **R-noids** Do **not** write slide ids. Write `<section class=\"slide\">` without `id`, and narration headings without `{#…}`. The editor adds ids after import. When you are given a deck that already has ids (a fix request), keep every existing `id=\"…\"` and `{#…}` exactly as it is.\n\n## 2. deck.html\n\n### 2.1 Skeleton\n\n```html\n<!DOCTYPE html>\n<html lang=\"en\" data-theme=\"default\">\n<head>\n<meta charset=\"utf-8\">\n<meta name=\"viewport\" content=\"width=device-width, initial-scale=1\">\n<title>Lesson title</title>\n</head>\n<body>\n<div id=\"stage\">\n <section class=\"slide cover noconcl static\"> … </section>\n <section class=\"slide\"> … </section>\n</div>\n</body>\n</html>\n```\n\n- `lang`: `en`, `ja`, … (the language of the lesson). `data-theme`: `sumi` for business and pitch decks, `kokugo` for Japanese language arts, otherwise `default`.\n- No `<script>` except component data (§2.6), no `<link>`. A `<style>` block is allowed only for layout (sizes, gaps), never colors.\n\n### 2.2 Slides\n\n- Normal slide: `<h2>` heading, `<div class=\"body\">…</div>`, then `<div class=\"concl\"><span>…</span></div>` (the conclusion line: one short sentence).\n- Cover: `<section class=\"slide cover noconcl static\">` with optional `<div class=\"venue\">…</div>`, `<h1>title</h1>`, optional `<div class=\"au\">…</div>`.\n- Chapter divider: `<section class=\"slide sec noconcl static\"><h1>chapter title</h1></section>`.\n- Classes on `<section>`: `noconcl` (no conclusion line), `static` (no steps), `nostep` (all list items visible from the start), `layout-tate` (Japanese vertical writing; only with the kokugo part set, which describes it), and the `data-morph` attribute (§2.5).\n- Inside `.body`: `<p class=\"sub\">` sub-heading, `<div class=\"big\">` main equation, `<p class=\"note\">` note, `<div class=\"thm\">` theorem box, `<div class=\"cols\">` side-by-side columns, ordinary `<p>`, `<ul>`, `<ol>`, `<table>`.\n- Inline emphasis (the only way to color text): `term` (term or question), `emph` (conclusion, problem, goal), `muted` (known result, de-emphasized), `b` (bold).\n- **R-headings** Every slide heading (`h1` on the cover and dividers, `h2` elsewhere) is **different** from all the others (add a word if two would be the same), and the narration section of that slide starts with `## ` followed by **exactly the same heading text** (tags such as `<br>` dropped).\n- **R-colors** Colors only through the theme: the classes above and the math macros `\\hlE` `\\hlT` `\\hlM`; no hex, `rgb()`, named colors, `\\color` or `\\textcolor`. In a component or inline SVG: **Use only the theme's CSS variables for colors**: `var(--fg)` `var(--term)` `var(--emph)` `var(--muted)` `var(--accent2)` `var(--line)`. In SVG write `style=\"stroke:var(--emph)\"` rather than an attribute (`DECK.el` moves `fill` and `stroke` into style automatically when they contain `var(`)\n\n### 2.3 Steps (reveal order = speaking order)\n\n- **R-steps** Step 0 is the slide as it first appears: context only (heading, sub-heading, one framing sentence). An element with `data-step=\"k\"` (k = 1, 2, …) appears at step k; material (list items, equations, table rows, figure parts) appears in the order you talk about it. An equation and the sentence that introduces it share one step (wrap both in `<div data-step=\"k\">`). About 5 steps per slide at most.\n- The conclusion line automatically becomes the **last step**, `concl`; never put `data-step` on it.\n- If a slide has **no** `data-step` anywhere, its top-level list items (`.body > ul > li`, `.body > ol > li`) are numbered 1, 2, … automatically. As soon as any element has `data-step`, nothing is automatic: give every revealed element its `data-step`.\n- A component adds its own steps (§3), starting at its `data-from` (default 1).\n- So the steps of a slide are `0 … max` plus `concl` if it has a conclusion line. A `static` slide has only step 0.\n\n### 2.4 Math (KaTeX, rendered at build time)\n\n- **R-math** Inline `\\( … \\)`, display `\\[ … \\]`. Write `<` as `\\lt` and `>` as `\\gt` inside math. Allowed macros besides standard KaTeX: `\\hlE{…}` (emph) `\\hlT{…}` (term) `\\hlM{…}` (muted), `\\htmlId{ID}{…}`, `\\htmlData{mark=ID}{…}`, `\\htmlClass{…}{…}`, `\\morph{ID}{…}`. No `\\newcommand`, no `\\color`. Define each symbol where it is first used (`\\(\\mu\\)`: the mean).\n\n### 2.5 Attention marks and morphs\n\n- **R-marks** The narration’s `{mark:ID}` (§4) marks a target on the **same slide**. Targets: an element in the slide with `id=\"ID\"` or `data-mark=\"ID\"`. For part of an equation, KaTeX's `\\htmlId{ID}{…}` / `\\htmlData{mark=ID}{…}` (the build allows only these two and `\\htmlClass`). If the same ID is used on several slides, use `data-mark` (ids must be unique in the document)\n- Morph (optional): `<section class=\"slide\" data-morph>` slides elements from the previous slide into place; pair elements with the same `data-id=\"…\"` on both slides, or equation parts with `\\morph{ID}{…}` on both. Only elements visible at step 0 move.\n\n### 2.6 Components\n\n- **R-components** Animated figures are the Web Components `<m-…>` of the catalog (§3), used inside `.body`. Give each a height (`style=\"height:380px\"`) and an `aria-label`. Data goes in **one** child `<script type=\"application/json\">…</script>` written inline (never `{{JSON:…}}`). **Numbers in figures must be correct** (compute them; never invent values for looks; label made-up business figures as fictional). Function formulas are arithmetic expressions only (`Math.exp(x)`, `x**2`); they are never run as code. Use components only where motion explains something; most slides need none.\n\n### 2.7 Choosing a representation\n\n- **R-purpose** Choose the representation from what the slide must say, not from habit. If the author names a chart type, use it. The table lists every part; use only those in the text you were given (§3, and the part sets included). If a part that is not included would fit better, say so in a one-line note.\n\n{{PURPOSES}}\n\n- **R-whole** Lists, KPI cards and pies are shown whole; do not reveal them line by line unless the narration discusses each item in turn (for a list, give it one `data-step` or put `nostep` on the slide).\n\n### 2.8 Fitting the slide (1280×720; the quality checker reports errors)\n\n- **R-title** Heading: Japanese at most 26 units (full-width character = 1, ASCII = 0.5); English at most 60 characters. Never ends with a colon.\n- **R-concl** Conclusion line: Japanese at most 35 units; English at most 70 characters. One line.\n- **R-fit** The body must end above 565 px (680 px with `noconcl`): about 8 lines / 100 Japanese characters / 60 English words per slide, or one `big` equation and 3 short bullets, or a component of height ≤ 380 px and one short line (≤ 330 px with two). If it does not fit, split the slide; never shrink text and never set font sizes. Text in figures is at least 24 px.\n- **R-style** Japanese slides: plain style (だ・である, 体言止め), no です・ます on slides, one punctuation style in the whole deck (`、。` or `,.`). English slides: short phrases, sentence case.\n\n## 3. Component catalog\n\nThese standard components may be used in any lesson; a part set, when it is included after §6, adds the components of its kind of material. Generated from the component READMEs (their notes are in Japanese). “steps” is how many slide steps a component uses (from `data-from`, default 1). Timing attributes (durations and delays in seconds) are not listed; their defaults fit the narration. Attribute values of type json are written as JSON in the attribute (`values=\"[0.1,0.5]\"`). In “data shape”, `?` marks an optional field; where no type is written, label, tex, note and tone are str, step is int and at is num. In a name or label, `*…*` is italic and `_` `^` make only the next character a subscript or superscript; to show the symbol itself, write the full-width _ ^ *.\n\n{{CATALOG}}\n\n## 4. narration.md\n\n```markdown\n# Narration: <lesson title>\n\n## The decay law\n[0] Here is the decay law. We follow how many atoms are left.\n[1] The number left is the starting number times a shrinking exponential.\n[2] {mark:n0|circle}{N₀|N naught} is the number at the start, at time zero.\n[concl] The half-life depends only on the decay constant.\n```\n\n- One section per slide, **in slide order, for every slide (cover included)**: `## <slide heading>` (R-headings), no `{#id}` (R-noids).\n- **R-narr-steps** Step markers `[0]`, `[1]`, … and `[concl]`. **Every step of every slide has narration** (step 0 to max, and `[concl]` if the slide has a conclusion line), and there are **no markers for steps that do not exist** (a `static` cover has only `[0]`; a slide without a conclusion line has no `[concl]`; never `[01]`). Within a step, talk only about what appears at that step.\n- **R-dialogue** **One narrator by default**: write no speaker names. Write a dialogue only when asked (if asked for three or more speakers, keep two roles and say so first): lines start with `Expert:` or `Novice:` (continuation lines indented; a line without a speaker is Expert), shaped as a cognitive apprenticeship:\n - Novice is never a mere backchannel: Novice voices the question a learner is likely to have, or paraphrases (“So …, is that right?”)\n - Expert answers and adds one example or analogy, or confirms (or corrects) the paraphrase and takes one step further\n - Only at a comprehension fork (where learners tend to misunderstand, or a “why” remains): at most one exchange per slide, 2–3 turns. Elsewhere Expert alone\n - Never a turn that is only “I see”, or that repeats the previous turn. Example: `Novice: So a larger rate always gets there faster?` `Expert: Not always. Too large, and each step jumps across the valley, like striding downhill onto the opposite slope.`\n- `{note:…}`: presenter directions.\n- `{cue}`: a sync point inside a step, one per entry of the component’s `cues(k)` (only where a component’s README asks for it; otherwise omit).\n- `{mark:ID}`, `{mark:ID|effect}`, `{mark:ID|effect|hold=seconds}`, `{mark:clear}`: placed **right before** the words about the target; at most 1–2 per step; still say the thing in words. Effects: `underline` (default; a hand-drawn underline from left to right), `circle` (a hand-drawn circle), `box` (a rounded frame), `spot` (dims everything except the area around the target with the background color), `laser` (a dot of light slides to below the target and stays briefly)\n- **R-reading** `{display|reading}` gives the reading of **one symbol or one term**: `{θ|theta}`, `{N₀|N naught}`, `{x̄|x bar}`, `{論語|ろんご}`. One symbol may carry a star, a prime, a subscript or superscript, or a hat/bar/tilde (`{Q*|Q star}`, `{x′|x prime}`, `{θ̂|theta hat}`). Write the display part in plain Unicode, not LaTeX, and never as an expression or several symbols (`{1-η|…}`, `{a*b|…}` and `{θとη|…}` are wrong: give each symbol its own reading and say the relation in words).\n- **R-formula** **Never read an equation aloud**: no LaTeX, no `\\`, `^`, `_`, and no strings such as `a + b = c` in the narration. Say what the equation means (“the number left is the starting number times a shrinking exponential”).\n- Japanese narration is polite spoken Japanese (です・ます); English narration is plain spoken English. About 5 Japanese characters or 2.5 English words per second; 1–3 sentences per turn.\n\n## 5. Fix requests\n\nWhen the user pastes a **fix request** (a list of findings with the ids of the standards, followed by the current files), fix exactly those findings, keep everything else, keep every `id=\"…\"` and `{#…}` unchanged (R-noids), and reply again with the two blocks (R-output). If the request contains only some slides, return only those `<section>` elements in the `deck.html` block (no `<html>`) and only their sections in the `narration.md` block; the editor puts them back in place by id.\n\n## 6. Worked example\n\nA small lesson, fictional, showing the structure only (do not copy its content). Note how the steps add up: the list of 2 items gives steps 1–2 and `[concl]`<!--part:m-flow-->; the `m-flow` with 4 boxes gives steps 1–4<!--/part-->. The static cover has `[0]` only. Some part sets end with an example of their own.\n\n### Common (English, default theme, marks<!--part:m-flow-->, m-flow<!--/part-->)\n\n```deck.html\n<!DOCTYPE html>\n<html lang=\"en\" data-theme=\"default\">\n<head>\n<meta charset=\"utf-8\">\n<meta name=\"viewport\" content=\"width=device-width, initial-scale=1\">\n<title>How a web page arrives</title>\n</head>\n<body>\n<div id=\"stage\">\n\n<section class=\"slide cover noconcl static\">\n <div class=\"venue\">Computing basics, lesson 1 (a fictional course)</div>\n <h1>How a web page arrives</h1>\n</section>\n\n<section class=\"slide\">\n <h2>Two programs take part</h2>\n <div class=\"body\">\n <p>Opening a page is a conversation between two programs.</p>\n <ul>\n <li id=\"browser\">The <span class=\"term\">browser</span> asks for the page and draws it</li>\n <li id=\"server\">The <span class=\"term\">server</span> keeps the page and sends it back</li>\n </ul>\n </div>\n <div class=\"concl\"><span>Every page load is a request and a reply</span></div>\n</section><!--part:m-flow-->\n\n<section class=\"slide\">\n <h2>From the address to the screen</h2>\n <div class=\"body\">\n <m-flow style=\"height:300px\" aria-label=\"Four stages: type the address, send a request, send the page back, draw the page\">\n <script type=\"application/json\">{\"nodes\": [\n {\"id\": \"a\", \"label\": \"Type the\\naddress\", \"x\": 10, \"y\": 100, \"w\": 250, \"h\": 110, \"step\": 1},\n {\"id\": \"b\", \"label\": \"Send a\\nrequest\", \"x\": 315, \"y\": 100, \"w\": 250, \"h\": 110, \"step\": 2},\n {\"id\": \"c\", \"label\": \"Send the\\npage back\", \"x\": 620, \"y\": 100, \"w\": 250, \"h\": 110, \"step\": 3, \"tone\": \"term\"},\n {\"id\": \"d\", \"label\": \"Draw the\\npage\", \"x\": 925, \"y\": 100, \"w\": 250, \"h\": 110, \"step\": 4, \"tone\": \"emph\"}\n ], \"edges\": [\n {\"from\": \"a\", \"to\": \"b\"}, {\"from\": \"b\", \"to\": \"c\"}, {\"from\": \"c\", \"to\": \"d\"}\n ]}</script>\n </m-flow>\n </div>\n <div class=\"concl\"><span>A slow page is slow in one of these four stages</span></div>\n</section><!--/part-->\n\n</div>\n</body>\n</html>\n```\n\n```narration.md\n# Narration: How a web page arrives\n\n## How a web page arrives\n[0] Today we follow a web page on its way from a server to your screen.\n\n## Two programs take part\n[0] Opening a page is a conversation between two programs.\n[1] {mark:browser}The browser is the program you look at. It asks for the page and then draws it.\n[2] {mark:server}The server is a program on another computer. It keeps the page and sends it back when asked.\n[concl] Every page load is a request and a reply.<!--part:m-flow-->\n\n## From the address to the screen\n[0] Let us put the steps in order.\n[1] First you type the address of the page.\n[2] The browser turns it into a request and sends it to the server.\n[3] The server finds the page and sends it back.\n[4] The browser draws the page on the screen.\n[concl] When a page is slow, one of these four stages is taking the time.<!--/part-->\n```",
|
|
753
|
+
"common": "# Instructions for the AI\n\nPack version: `69c736a1`\n\nYou will write one short **Egatari lesson**: an HTML slide deck with step-by-step reveals (`deck.html`) and a spoken script for it (`narration.md`). Both files are built and quality-checked automatically; anything not described here is not available. Write the lesson in the language the user asks for (slides and narration in the same language). Standards have ids such as **R-fit**; a fix request names the standards a draft broke. The user's request is in **What I want** at the end (or in the conversation before it): choose sensibly for any field that is empty or missing, and if both A and B are left, follow the one with content.\n\n**Before you start (the most common failures):**\n\n- **Both code blocks must be complete and closed.** Never stop in the middle of a block (R-output). Without an outline, keep the lesson short (5–8 slides). When the request gives an outline and a range of its slides, write exactly the slides of that range: the editor asks for at most 6 at a time, so they fit.\n- **Sizes on the 1280×720 slide** (the quality checker measures them, R-fit): the body area is 1184 × 443 px (to 565 px; 1184 × 558 with `noconcl`). Body text is 32 px with 46 px per line, so about **8 lines** fit; every overflowing 46 px is one line to cut. **All text, also inside figures and components, is at least 24 px.**\n- **Charts and figures:** components draw their labels at 24–28 px whatever their size (their SVG uses their own pixels), so size the component, not the text. A component of 380 px leaves room for one short line; with two lines, use 330 px.\n- **Inline `<svg>`:** its text is scaled by displayed width ÷ viewBox width, so write the viewBox in the pixels it is shown at, e.g. `<svg viewBox=\"0 0 560 320\" width=\"560\" height=\"320\">`, with `font-size` ≥ 24. Never combine `width:100%` with another viewBox width (a 600-wide viewBox shown 580 px wide turns 24 into 23.2 px). Prefer a component when one fits.\n\n## 1. Output format\n\n- **R-output** Reply with **exactly two fenced code blocks**, in this order, labelled `deck.html` and `narration.md` (the opening lines are ```` ```deck.html ```` and ```` ```narration.md ````). Put nothing between them; a one-line note before or after is fine. Never split a file over several blocks. Do not output files, a canvas or attachments: write both code blocks in the body of your chat message. Do not reference other files (no images, no `{{FIG:…}}`, no `{{JSON:…}}`, no external URLs, no `<link>`), and never stop in the middle of a block: if the deck would be too long, make fewer slides (but for a range of an outline, write exactly the requested slides).\n- **R-outline** When the request asks for an **outline only** (a long lesson made in two passes), reply with exactly one fenced code block labelled `outline` (the opening line is ```` ```outline ````) and no `deck.html` or `narration.md`: a Markdown table with the columns `#`, heading and point (one line), one row per slide, every slide of the lesson in order. Each later request names a range (“slides 7–12 of the outline”): write exactly those slides, following their headings and points.\n- **R-noids** Do **not** write slide ids. Write `<section class=\"slide\">` without `id`, and narration headings without `{#…}`. The editor adds ids after import. When you are given a deck that already has ids (a fix request), keep every existing `id=\"…\"` and `{#…}` exactly as it is.\n\n## 2. deck.html\n\n### 2.1 Skeleton\n\n```html\n<!DOCTYPE html>\n<html lang=\"en\" data-theme=\"default\">\n<head>\n<meta charset=\"utf-8\">\n<meta name=\"viewport\" content=\"width=device-width, initial-scale=1\">\n<title>Lesson title</title>\n</head>\n<body>\n<div id=\"stage\">\n <section class=\"slide cover noconcl static\"> … </section>\n <section class=\"slide\"> … </section>\n</div>\n</body>\n</html>\n```\n\n- `lang`: `en`, `ja`, … (the language of the lesson). `data-theme`: `sumi` for business and pitch decks, `kokugo` for Japanese language arts, otherwise `default`.\n- No `<script>` except component data (§2.6), no `<link>`. A `<style>` block is allowed only for layout (sizes, gaps), never colors.\n\n### 2.2 Slides\n\n- Normal slide: `<h2>` heading, `<div class=\"body\">…</div>`, then `<div class=\"concl\"><span>…</span></div>` (the conclusion line: one short sentence).\n- Cover: `<section class=\"slide cover noconcl static\">` with optional `<div class=\"venue\">…</div>`, `<h1>title</h1>`, optional `<div class=\"au\">…</div>`.\n- Chapter divider: `<section class=\"slide sec noconcl static\"><h1>chapter title</h1></section>`.\n- Classes on `<section>`: `noconcl` (no conclusion line), `static` (no steps), `nostep` (all list items visible from the start), `layout-tate` (Japanese vertical writing; only with the kokugo part set, which describes it), and the `data-morph` attribute (§2.5).\n- Inside `.body`: `<p class=\"sub\">` sub-heading, `<div class=\"big\">` main equation, `<p class=\"note\">` note, `<div class=\"thm\">` theorem box, `<div class=\"cols\">` side-by-side columns, ordinary `<p>`, `<ul>`, `<ol>`, `<table>`.\n- Inline emphasis (the only way to color text): `term` (term or question), `emph` (conclusion, problem, goal), `muted` (known result, de-emphasized), `b` (bold).\n- **R-headings** Every slide heading (`h1` on the cover and dividers, `h2` elsewhere) is **different** from all the others (add a word if two would be the same), and the narration section of that slide starts with `## ` followed by **exactly the same heading text** (tags such as `<br>` dropped).\n- **R-colors** Colors only through the theme: the classes above and the math macros `\\hlE` `\\hlT` `\\hlM`; no hex, `rgb()`, named colors, `\\color` or `\\textcolor`. In a component or inline SVG: **Use only the theme's CSS variables for colors**: `var(--fg)` `var(--term)` `var(--emph)` `var(--muted)` `var(--accent2)` `var(--line)`. In SVG write `style=\"stroke:var(--emph)\"` rather than an attribute (`DECK.el` moves `fill` and `stroke` into style automatically when they contain `var(`)\n\n### 2.3 Steps (reveal order = speaking order)\n\n- **R-steps** Step 0 is the slide as it first appears: context only (heading, sub-heading, one framing sentence). An element with `data-step=\"k\"` (k = 1, 2, …) appears at step k; material (list items, equations, table rows, figure parts) appears in the order you talk about it. An equation and the sentence that introduces it share one step (wrap both in `<div data-step=\"k\">`). About 5 steps per slide at most.\n- The conclusion line automatically becomes the **last step**, `concl`; never put `data-step` on it.\n- If a slide has **no** `data-step` anywhere, its top-level list items (`.body > ul > li`, `.body > ol > li`) are numbered 1, 2, … automatically. As soon as any element has `data-step`, nothing is automatic: give every revealed element its `data-step`.\n- A component adds its own steps (§3), starting at its `data-from` (default 1).\n- So the steps of a slide are `0 … max` plus `concl` if it has a conclusion line. A `static` slide has only step 0.\n\n### 2.4 Math (KaTeX, rendered at build time)\n\n- **R-math** Inline `\\( … \\)`, display `\\[ … \\]`. Write `<` as `\\lt` and `>` as `\\gt` inside math. Allowed macros besides standard KaTeX: `\\hlE{…}` (emph) `\\hlT{…}` (term) `\\hlM{…}` (muted), `\\htmlId{ID}{…}`, `\\htmlData{mark=ID}{…}`, `\\htmlClass{…}{…}`, `\\morph{ID}{…}`. No `\\newcommand`, no `\\color`. Define each symbol where it is first used (`\\(\\mu\\)`: the mean).\n\n### 2.5 Attention marks and morphs\n\n- **R-marks** The narration’s `{mark:ID}` (§4) marks a target on the **same slide**. Targets: an element in the slide with `id=\"ID\"` or `data-mark=\"ID\"`. For part of an equation, KaTeX's `\\htmlId{ID}{…}` / `\\htmlData{mark=ID}{…}` (the build allows only these two and `\\htmlClass`). If the same ID is used on several slides, use `data-mark` (ids must be unique in the document)\n- Morph (optional): `<section class=\"slide\" data-morph>` slides elements from the previous slide into place; pair elements with the same `data-id=\"…\"` on both slides, or equation parts with `\\morph{ID}{…}` on both. Only elements visible at step 0 move.\n\n### 2.6 Components\n\n- **R-components** Animated figures are the Web Components `<m-…>` of the catalog (§3), used inside `.body`. Give each a height (`style=\"height:380px\"`) and an `aria-label`. Data goes in **one** child `<script type=\"application/json\">…</script>` written inline (never `{{JSON:…}}`). **Numbers in figures must be correct** (compute them; never invent values for looks; label made-up business figures as fictional). Function formulas are arithmetic expressions only (`Math.exp(x)`, `x**2`); they are never run as code. Use components only where motion explains something; most slides need none.\n\n### 2.7 Choosing a representation\n\n- **R-purpose** Choose the representation from what the slide must say, not from habit. If the author names a chart type, use it. The table lists every part; use only those in the text you were given (§3, and the part sets included). If a part that is not included would fit better, say so in a one-line note.\n\n{{PURPOSES}}\n\n- **R-whole** Lists, KPI cards and pies are shown whole; do not reveal them line by line unless the narration discusses each item in turn (for a list, give it one `data-step` or put `nostep` on the slide).\n\n### 2.8 Fitting the slide (1280×720; the quality checker reports errors)\n\n- **R-title** Heading: Japanese at most 26 units (full-width character = 1, ASCII = 0.5); English at most 60 characters. Never ends with a colon.\n- **R-concl** Conclusion line: Japanese at most 35 units; English at most 70 characters. One line.\n- **R-fit** The body must end above 565 px (680 px with `noconcl`): about 8 lines / 100 Japanese characters / 60 English words per slide, or one `big` equation and 3 short bullets, or a component of height ≤ 380 px and one short line (≤ 330 px with two). If it does not fit, split the slide; never shrink text and never set font sizes. Text in figures is at least 24 px.\n- **R-style** Japanese slides: plain style (だ・である, 体言止め), no です・ます on slides, one punctuation style in the whole deck (`、。` or `,.`). English slides: short phrases, sentence case.\n\n## 3. Component catalog\n\nThese standard components may be used in any lesson; a part set, when it is included after §6, adds the components of its kind of material. Generated from the component READMEs (their notes are in Japanese). “steps” is how many slide steps a component uses (from `data-from`, default 1). Timing attributes (durations and delays in seconds) are not listed; their defaults fit the narration. Attribute values of type json are written as JSON in the attribute (`values=\"[0.1,0.5]\"`). In “data shape”, `?` marks an optional field; where no type is written, label, tex, note and tone are str, step is int and at is num. In a name or label, `*…*` is italic and `_` `^` make only the next character a subscript or superscript; to show the symbol itself, write the full-width _ ^ *.\n\n{{CATALOG}}\n\n## 4. narration.md\n\n```markdown\n# Narration: <lesson title>\n\n## The decay law\n[0] Here is the decay law. We follow how many atoms are left.\n[1] The number left is the starting number times a shrinking exponential.\n[2] {mark:n0|circle}{N₀|N naught} is the number at the start, at time zero.\n[concl] The half-life depends only on the decay constant.\n```\n\n- One section per slide, **in slide order, for every slide (cover included)**: `## <slide heading>` (R-headings), no `{#id}` (R-noids).\n- **R-narr-steps** Step markers `[0]`, `[1]`, … and `[concl]`. **Every step of every slide has narration** (step 0 to max, and `[concl]` if the slide has a conclusion line), and there are **no markers for steps that do not exist** (a `static` cover has only `[0]`; a slide without a conclusion line has no `[concl]`; never `[01]`). Within a step, talk only about what appears at that step.\n- **R-dialogue** **One narrator by default**: write no speaker names. Write a dialogue only when asked (if asked for three or more speakers, keep two roles and say so first): lines start with `Expert:` or `Novice:` (continuation lines indented; a line without a speaker is Expert), shaped as a cognitive apprenticeship:\n - Novice is never a mere backchannel: Novice voices the question a learner is likely to have, or paraphrases (“So …, is that right?”)\n - Expert answers and adds one example or analogy, or confirms (or corrects) the paraphrase and takes one step further\n - Only at a comprehension fork (where learners tend to misunderstand, or a “why” remains): at most one exchange per slide, 2–3 turns. Elsewhere Expert alone\n - Never a turn that is only “I see”, or that repeats the previous turn. Example: `Novice: So a larger rate always gets there faster?` `Expert: Not always. Too large, and each step jumps across the valley, like striding downhill onto the opposite slope.`\n- `{note:…}`: presenter directions.\n- `{cue}`: a sync point inside a step, one per entry of the component’s `cues(k)` (only where a component’s README asks for it; otherwise omit).\n- `{mark:ID}`, `{mark:ID|effect}`, `{mark:ID|effect|hold=seconds}`, `{mark:clear}`: placed **right before** the words about the target; at most 1–2 per step; still say the thing in words. Effects: `underline` (default; a hand-drawn underline from left to right), `circle` (a hand-drawn circle), `box` (a rounded frame), `spot` (dims everything except the area around the target with the background color), `laser` (a dot of light slides to below the target and stays briefly)\n- **R-reading** `{display|reading}` gives the reading of **one symbol or one term**: `{θ|theta}`, `{N₀|N naught}`, `{x̄|x bar}`, `{論語|ろんご}`. One symbol may carry a star, a prime, a subscript or superscript, or a hat/bar/tilde (`{Q*|Q star}`, `{x′|x prime}`, `{θ̂|theta hat}`). Write the display part in plain Unicode, not LaTeX, and never as an expression or several symbols (`{1-η|…}`, `{a*b|…}` and `{θとη|…}` are wrong: give each symbol its own reading and say the relation in words).\n- **R-formula** **Never read an equation aloud**: no LaTeX, no `\\`, `^`, `_`, and no strings such as `a + b = c` in the narration. Say what the equation means (“the number left is the starting number times a shrinking exponential”).\n- Japanese narration is polite spoken Japanese (です・ます); English narration is plain spoken English. About 5 Japanese characters or 2.5 English words per second; 1–3 sentences per turn.\n\n## 5. Fix requests\n\nWhen the user pastes a **fix request** (a list of findings with the ids of the standards, followed by the current files), fix exactly those findings, keep everything else, keep every `id=\"…\"` and `{#…}` unchanged (R-noids), and reply again with the two blocks (R-output). If the request contains only some slides, return only those `<section>` elements in the `deck.html` block (no `<html>`) and only their sections in the `narration.md` block; the editor puts them back in place by id.\n\n## 6. Worked example\n\nA small lesson, fictional, showing the structure only (do not copy its content). Note how the steps add up: the list of 2 items gives steps 1–2 and `[concl]`<!--part:m-flow-->; the `m-flow` with 4 boxes gives steps 1–4<!--/part-->. The static cover has `[0]` only. Some part sets end with an example of their own.\n\n### Common (English, default theme, marks<!--part:m-flow-->, m-flow<!--/part-->)\n\n```deck.html\n<!DOCTYPE html>\n<html lang=\"en\" data-theme=\"default\">\n<head>\n<meta charset=\"utf-8\">\n<meta name=\"viewport\" content=\"width=device-width, initial-scale=1\">\n<title>How a web page arrives</title>\n</head>\n<body>\n<div id=\"stage\">\n\n<section class=\"slide cover noconcl static\">\n <div class=\"venue\">Computing basics, lesson 1 (a fictional course)</div>\n <h1>How a web page arrives</h1>\n</section>\n\n<section class=\"slide\">\n <h2>Two programs take part</h2>\n <div class=\"body\">\n <p>Opening a page is a conversation between two programs.</p>\n <ul>\n <li id=\"browser\">The <span class=\"term\">browser</span> asks for the page and draws it</li>\n <li id=\"server\">The <span class=\"term\">server</span> keeps the page and sends it back</li>\n </ul>\n </div>\n <div class=\"concl\"><span>Every page load is a request and a reply</span></div>\n</section><!--part:m-flow-->\n\n<section class=\"slide\">\n <h2>From the address to the screen</h2>\n <div class=\"body\">\n <m-flow style=\"height:300px\" aria-label=\"Four stages: type the address, send a request, send the page back, draw the page\">\n <script type=\"application/json\">{\"nodes\": [\n {\"id\": \"a\", \"label\": \"Type the\\naddress\", \"x\": 10, \"y\": 100, \"w\": 250, \"h\": 110, \"step\": 1},\n {\"id\": \"b\", \"label\": \"Send a\\nrequest\", \"x\": 315, \"y\": 100, \"w\": 250, \"h\": 110, \"step\": 2},\n {\"id\": \"c\", \"label\": \"Send the\\npage back\", \"x\": 620, \"y\": 100, \"w\": 250, \"h\": 110, \"step\": 3, \"tone\": \"term\"},\n {\"id\": \"d\", \"label\": \"Draw the\\npage\", \"x\": 925, \"y\": 100, \"w\": 250, \"h\": 110, \"step\": 4, \"tone\": \"emph\"}\n ], \"edges\": [\n {\"from\": \"a\", \"to\": \"b\"}, {\"from\": \"b\", \"to\": \"c\"}, {\"from\": \"c\", \"to\": \"d\"}\n ]}</script>\n </m-flow>\n </div>\n <div class=\"concl\"><span>A slow page is slow in one of these four stages</span></div>\n</section><!--/part-->\n\n</div>\n</body>\n</html>\n```\n\n```narration.md\n# Narration: How a web page arrives\n\n## How a web page arrives\n[0] Today we follow a web page on its way from a server to your screen.\n\n## Two programs take part\n[0] Opening a page is a conversation between two programs.\n[1] {mark:browser}The browser is the program you look at. It asks for the page and then draws it.\n[2] {mark:server}The server is a program on another computer. It keeps the page and sends it back when asked.\n[concl] Every page load is a request and a reply.<!--part:m-flow-->\n\n## From the address to the screen\n[0] Let us put the steps in order.\n[1] First you type the address of the page.\n[2] The browser turns it into a request and sends it to the server.\n[3] The server finds the page and sends it back.\n[4] The browser draws the page on the screen.\n[concl] When a page is slow, one of these four stages is taking the time.<!--/part-->\n```",
|
|
754
754
|
"request": "# What I want\n\n*(Fill in A or B and delete the other; delete fields you leave empty.)*\n\n**A. Make a new lesson**\n\n- Title (used as is on the cover):\n- Audience:\n- Length (slides or minutes):\n- Language:\n- Speakers: one narrator\n- Other wishes:\n\n**B. From the material and discussion in this chat**\n\nMake the lesson from the material given in this chat and what we have discussed so far.\n\n- Title (used as is on the cover):\n- Audience:\n- Length (slides or minutes):\n- Language:\n- Speakers: one narrator\n- Other wishes:",
|
|
755
755
|
"sets": {
|
|
756
756
|
"stats": "## Part set: stats (statistics charts)\n\nFor lessons and talks with data: distributions, box plots, heatmaps, and a distribution updated one observation at a time. Use the `default` theme. Give the source and the size of every data set on the slide or in the narration, and never invent data that looks real (R-components).\n\n- **Axis charts** (<!--part:m-hist-->`m-hist`, <!--/part--><!--part:m-boxplot-->`m-boxplot`, <!--/part--><!--part:m-seq-->`m-seq`, <!--/part-->and the like) reserve 86 px at the left and 80 px in all at the top and bottom for ticks and axis names: give them a height of **300–380 px** and a width of **at least 560 px** (in `<div class=\"cols\">`, give the chart column at least 55%).\n- Make the axis ranges contain every plotted value (computed as R-components says).\n\nComponents of this set, in addition to those of §3:\n\n{{CATALOG}}\n\n{{EXTENSIONS}}",
|
|
@@ -766,8 +766,8 @@ export const PACK = {
|
|
|
766
766
|
"components": {
|
|
767
767
|
"m-bars": {
|
|
768
768
|
"set": "standard",
|
|
769
|
-
"row": "| `<m-bars>` |
|
|
770
|
-
"entry": "### `<m-bars>`\n\nData example (child `<script type=\"application/json\">`): `{\"series\":[{\"label\":\"
|
|
769
|
+
"row": "| `<m-bars>` | Bars grow from 0 by step (vertical, horizontal, grouped, stacked); the axis max can widen by step | max group/scale step (default 1 group = 1 step) | `{groups:[{label?,value?:num,values?:num[],step?,at?,tone?} (value or values),…],series?:{label?,tone?}[],scale?:{step,max?:num,at?}[],max?:num}` |",
|
|
770
|
+
"entry": "### `<m-bars>`\n\nData example (child `<script type=\"application/json\">`): `{\"series\":[{\"label\":\"Sales\"}],\"groups\":[{\"label\":\"Year 1\",\"value\":1.2},{\"label\":\"Year 2\",\"value\":3.4}]}`\n\n| prop | type | default | meaning |\n|---|---|---|---|\n| `orient` | string | `\"v\"` | v or h |\n| `max` | number | `0` | axis max (0 = auto) |\n| `unit` | string | `\"\"` | value unit |\n| `digits` | number | `0` | decimals |\n| `per-step` | number | `1` | groups per step (0 = all) |\n| `count` | bool | `false` | count values up |\n| `ticks` | bool | `true` | ticks and grid |\n| `al` | string | `\"\"` | axis title |\n| `stack` | bool | `false` | stack values; \"percent\" = 100 % |\n\nFor quantities shown and compared one at a time: yearly sales, ranked answers, before/after.\n\n- group: `label` (`\\n` = 2 lines), `value` or `values` (one per series), `step`, `at` (start s), `tone` (bar and value colour)\n- series: `label` (2+ series: on the first group's bars; no legend), `tone` (default `--series-1..4`)\n- scale: `[{\"step\": 3, \"max\": 27, \"at\": 0.4}]`: the max moves to `max` over `zoom` s; the old range stays as a faint band; taller bars stop at the top and grow as it widens\n- `orient=\"h\"`: names left, values right; `ticks=\"false\"` for ranks\n- `stack=\"true\"` (`\"percent\"` = 100 %): a group's `values` in one bar; total at the end, values inside segments; values ≥ 0\n\nNotes\n\n- Values appear once a bar is fully grown; `count=\"true\"` counts them up\n- Series names sit on the first group's bars: keep to 2–3 series"
|
|
771
771
|
},
|
|
772
772
|
"m-boxplot": {
|
|
773
773
|
"set": "stats",
|
|
@@ -777,36 +777,35 @@ export const PACK = {
|
|
|
777
777
|
},
|
|
778
778
|
"m-cards": {
|
|
779
779
|
"set": "standard",
|
|
780
|
-
"row": "| `<m-cards>` |
|
|
781
|
-
"entry": "### `<m-cards>`\n\nData example (child `<script type=\"application/json\">`): `{\"cards\":[{\"icon\":\"user\",\"title\":\"
|
|
780
|
+
"row": "| `<m-cards>` | Icon cards in a row or 2 rows, by step; arrows for order | largest card step (default 1 card = 1 step) | `{cards:{n?:str,icon?:str,title:str,text?:str,step?,tone?}[]}` |",
|
|
781
|
+
"entry": "### `<m-cards>`\n\nData example (child `<script type=\"application/json\">`): `{\"cards\":[{\"icon\":\"user\",\"title\":\"Listen\",\"text\":\"Hear the problem\"},{\"icon\":\"bulb\",\"title\":\"Think\",\"text\":\"Find 3 ideas\"},{\"icon\":\"rocket\",\"title\":\"Try\",\"text\":\"Build small, show\"}]}`\n\n| prop | type | default | meaning |\n|---|---|---|---|\n| `layout` | enum | `\"row\"` | row, or grid (2×2; 3×2 for 5–6) |\n| `arrows` | bool | `false` | order arrows (grid: Z order) |\n| `nums` | bool | `false` | number circles |\n| `hilite` | string | `\"\"` | last or a number (from 1) |\n| `per-step` | number | `1` | cards per step (0 = all) |\n\n3–4 short equal points or a 2×2: try cards over bullets; short steps: cards with arrows. Long or unequal items: bullets.\n\n(2–6 cards).\n\n- `title`: required, ≤ 2 lines. `text`: wraps; overflow cut with …, reported\n- `icon`: Tabler name (below); unknown = dashed box, reported\n- `n`: circle text (`\"A\"`, `\"1\"`); `nums` numbers the rest 1, 2, 3 …\n- `tone`: circle and icon colour (`term`, `emph`, `accent2`, `series-1..4`)\n- `arrows`; `hilite=\"last\"` or `\"3\"`: `--emph` frame and fill\n- `variant`: `rise` (default), `fade`, `draw`\n\nIcons:\n\n- People: user users user-check user-plus user-circle friends mood-smile man woman id-badge\n- Data: chart-bar chart-line chart-pie chart-dots trending-up trending-down table database filter adjustments percentage sum\n- Money: coin cash credit-card wallet receipt pig-money building-bank report-money shopping-cart tag\n- Time: clock calendar calendar-event calendar-time hourglass history alarm stopwatch\n- Place: map-pin map world home building building-factory building-store route truck\n- Flow: arrow-right arrows-right-left refresh repeat circle-check checklist list-numbers git-branch target flag rocket hand-click\n- Talk: message messages mail phone bell speakerphone share world-www microphone presentation\n- Docs: file file-text files notebook book clipboard-list folder news certificate award\n- Tools: tool settings hammer bulb puzzle cpu device-laptop device-mobile robot code scale\n- Nature: leaf tree plant sun moon cloud cloud-rain droplet flame snowflake\n- Safety: shield shield-check lock key alert-triangle first-aid-kit heart heart-rate-monitor eye\n- Learning: school pencil ruler math-function atom flask microscope palette music language"
|
|
782
782
|
},
|
|
783
783
|
"m-compare": {
|
|
784
784
|
"set": "standard",
|
|
785
|
-
"row": "| `<m-compare>` | 2
|
|
786
|
-
"entry": "### `<m-compare>`\n\nData example (child `<script type=\"application/json\">`): `{\"sides\":[{\"label\":\"
|
|
785
|
+
"row": "| `<m-compare>` | Table comparing 2–3 things: one column, the other, then row differences | columns + 1 (diff step; none if no diff/better) | `{sides:{label,tone?,step?}[],rows:{label?,values:(str\\|num)[],diff?:str,better?:int}[]}` |",
|
|
786
|
+
"entry": "### `<m-compare>`\n\nData example (child `<script type=\"application/json\">`): `{\"sides\":[{\"label\":\"Paper form\",\"tone\":\"muted\"},{\"label\":\"Online form\"}],\"rows\":[{\"label\":\"Hours\",\"values\":[\"Weekdays 9–17\",\"24 h\"],\"better\":1,\"diff\":\"Any time\"}]}`\n\n| prop | type | default | meaning |\n|---|---|---|---|\n| `size` | number | `28` | value text px (shrinks to 24) |\n| `diff-label` | string | `\"\"` | diff column heading |\n\n<!--part:m-bars,m-kpi-->2–3 things on the same points (old vs new, A vs B). Bars: `m-bars`; one number: `m-kpi`.<!--/part-->\n\n- `sides`: 2 or 3; `label` = column heading; `tone` (`term`, `emph`, `muted`, `accent2`, `series-1..4`; default `term`, `accent2`, `series-4`); `muted` = old\n- `rows`: `label` = point (optional); `values` in column order (text/number; `\\n`), count = `sides` (else error card)\n- `diff`: short difference, `--emph`, right column\n- `better`: better column index (from 0): bold, `--emph` frame at diff step\n- Steps: column 1 (+ point names) → 2 → (3) → diffs; column `step` overrides\n- `variant`: `fade` (default), `slide`, `reveal` (row by row); same steps"
|
|
787
787
|
},
|
|
788
788
|
"m-curves": {
|
|
789
789
|
"set": "standard",
|
|
790
|
-
"row": "| `<m-curves>` |
|
|
791
|
-
"entry": "### `<m-curves>`\n\nData example (child `<script type=\"application/json\">`): `[{\"label\":\"
|
|
792
|
-
"sup": true
|
|
790
|
+
"row": "| `<m-curves>` | Lines drawn one at a time on shared axes, each named at its end (no legend) | largest step (default: number of series) | `[{label?,f?:str,pts?:[num,num][],tone?,step?,labelAt?:num,color?:str,dash?:bool,xr?:[num,num],at?,anchor?:\"right\"\\|\"left\"\\|\"above\"\\|\"below\"\\|\"top\"\\|\"bottom\"\\|\"start\"\\|\"middle\"\\|\"end\",dx?:num,dy?:num,ly?:num} (f or pts),…]` — the data is the array itself, not {\"series\": […]}; axes go in attributes (xr=\"[0,10]\" xl=\"…\"); the expression field is f in x (not fn, not u) |",
|
|
791
|
+
"entry": "### `<m-curves>`\n\nData example (child `<script type=\"application/json\">`): `[{\"label\":\"Demand D\",\"f\":\"10 - x\"},{\"label\":\"Supply S\",\"f\":\"2 + x\"},{\"label\":\"Equilibrium\",\"pts\":[[4,0],[4,6]],\"dash\":true}]`\n\n| prop | type | default | meaning |\n|---|---|---|---|\n| `xr` | json | `[0, 1]` | x range |\n| `yr` | json | `[0, 1]` | y range |\n| `xt` | json | `[]` | x ticks |\n| `yt` | json | `[]` | y ticks |\n| `xf` | number | | x tick decimals |\n| `yf` | number | | y tick decimals |\n| `xl` | string | `\"\"` | x title |\n| `yl` | string | `\"\"` | y title |\n| `n` | number | `300` | samples |\n| `lw` | number | `3.5` | line width |\n| `size` | number | `0` | text px (≥ 24; 0 = default) |\n\nOne comparison at a time in one figure: mean, median, quantiles; losses one by one.\n\nSeries: a JSON array in a child script. One series = one step; same `step` = together.\n\n| Field | Meaning |\n|---|---|\n| `label` | line name |\n| `f` | expression in x (see below) |\n| `pts` | points `[[x, y], …]` |\n| `tone` | `term` `emph` `accent2` `muted` `fg` `series-1..4` |\n| `dash` | dashed |\n| `labelAt` / `anchor` / `dx` / `dy` / `ly` | name at x = `labelAt` (default: end); `anchor` `right` `left` `above` `below`; `ly` = y |\n\n`f` is arithmetic, not code: numbers, `x`, `Math` functions/constants (`sin(x)`, `PI`; no `random`), `N(x, mean, sd)`, `+ - * / % **`, comparisons, `&& || !`, `? :`. Powers: `**`. An unreadable `f` shows a card."
|
|
793
792
|
},
|
|
794
793
|
"m-cycle": {
|
|
795
794
|
"set": "standard",
|
|
796
|
-
"row": "| `<m-cycle>` |
|
|
797
|
-
"entry": "### `<m-cycle>`\n\nData example (child `<script type=\"application/json\">`): `{\"center\":{\"label\":\"PDCA\"},\"nodes\":[{\"label\":\"
|
|
795
|
+
"row": "| `<m-cycle>` | Cycle diagram: stage boxes on a circle clockwise from 12, joined by arc arrows (last back to first too) | number of stages (default 1 per step; per-step n each; node step wins) | `{nodes:{id?:str\\|int,label?,tex?,note?,tone?,step?,at?}[],center?:{label?,tex?,note?,tone?,step?,at?},edges?:{from:str\\|int,to:str\\|int,label?,tone?,dash?:bool,step?,at?}[]}` |",
|
|
796
|
+
"entry": "### `<m-cycle>`\n\nData example (child `<script type=\"application/json\">`): `{\"center\":{\"label\":\"PDCA\"},\"nodes\":[{\"label\":\"Plan\"},{\"label\":\"Do\"},{\"label\":\"Check\"},{\"label\":\"Act\"}]}`\n\n| prop | type | default | meaning |\n|---|---|---|---|\n| `per-step` | number | `1` | stages per step (0 = all) |\n| `size` | number | `26` | box text px (shrinks to 24) |\n\nStages that repeat in order: PDCA, water cycle, cell cycle. No coordinates; list stages in order (conventions §2).\n\n(`center`, `edges` optional).\n\n- `nodes`: stages (3–8), in order clockwise from 12; arcs to the next, last→first automatic\n - `label` (`\\n`) or `tex` (KaTeX), `note` (small 2nd line, `--muted`), `tone` (`term` default, `emph`, `muted`, `accent2`, `series-1..4`), `step`, `at`, `id`\n- <!--part:m-pie-->`center`: middle name, an object (`{\"label\": \"PDCA\", \"note\": \"…\"}`); appears with stage 1 (`center.step`). `m-pie`'s `center` is a string<!--/part-->\n - same fields as nodes, no `id`; `tone: emph` box: `--emph-tint` fill, `--emph` frame/text\n- `edges`: extra links (`from` `to` = node `id`s, `label` `tone` `dash` `step`); dashed arrows edge to edge\n- Arrows `--muted`, 3 px\n\nLayout:\n\n- Wide spaces: ellipse up to 1.9× wider (never taller); sized to fit the element\n- Incoming arrow appears with its box; last→first after the last box\n- `variant`: `fade` (default), `draw` (arrows first), `grow`; same steps and end\n- `cues(k)`: start times of 2nd+ boxes in one step"
|
|
798
797
|
},
|
|
799
798
|
"m-fishbone": {
|
|
800
799
|
"set": "standard",
|
|
801
|
-
"row": "| `<m-fishbone>` |
|
|
802
|
-
"entry": "### `<m-fishbone>`\n\nData example (child `<script type=\"application/json\">`): `{\"effect\":{\"label\":\"
|
|
800
|
+
"row": "| `<m-fishbone>` | Fishbone (cause-and-effect) diagram, one main bone at a time, head last; auto layout | bones + 1 (head), or the largest step | `{effect:{label?,tex?,note?,tone?,step?,at?},nodes:{id:str\\|int,label?,tex?,note?,tone?,parent?:str\\|int,step?,at?}[],edges?:{from:str\\|int,to:str\\|int,label?,tone?,dash?:bool,step?,at?}[]}` — nodes without parent are main bones (categories); their children are causes, grandchildren finer causes (3 levels max) |",
|
|
801
|
+
"entry": "### `<m-fishbone>`\n\nData example (child `<script type=\"application/json\">`): `{\"effect\":{\"label\":\"Late delivery\"},\"nodes\":[{\"id\":\"p\",\"label\":\"People\"},{\"id\":\"p1\",\"label\":\"Short-staffed\",\"parent\":\"p\"},{\"id\":\"m\",\"label\":\"Machines\"},{\"id\":\"m1\",\"label\":\"Truck breakdown\",\"parent\":\"m\"}]}`\n\n| prop | type | default | meaning |\n|---|---|---|---|\n| `order` | string | `\"causes-first\"` | causes-first (default) or effect-first |\n| `size` | number | `0` | box text px (0 = 27, shrink to 24) |\n\nGrouped causes of one effect (e.g. 4M: people, machines, methods, materials). No coordinates.\n\n(`edges` optional).\n\n- effect (head): `label` (`\\n`) or `tex`, `note` (under box), `tone` (default `emph`), `step`, `at`\n- node: `id`, `label` (or `tex`), `note`, `parent`, `tone`, `step`, `at`. No `parent` = main bone; child = cause; grandchild = sub-cause (3 levels)\n - Bones in array order, left to right, top/bottom alternating; name boxed at the outer end (`note` outside)\n - Cause `tex` = KaTeX; `note` small after the name (`--muted`)\n - `tone`: bone = box and bone; cause = text and line (`emph` bold)\n- edge: extra cause links (`from` `to` `label` `tone` `dash` `step`), dashed arrow bulging left of text; best within one bone\n- `order`: `causes-first` or `effect-first` (head, spine first); node `step` wins\n- `variant`: `fade` (default), `draw` (lines first), `grow` (boxes grow in); moves ≤ 12 px\n- Fit (1280×720 body, ~440 px high): ≤ 3 rows (causes + sub-causes) per bone (4 if short), 4–6 bones, causes ≤ ~10 chars. Text ≥ 24 px; overflow spills and is reported. Too many: split or shorten"
|
|
803
802
|
},
|
|
804
803
|
"m-flow": {
|
|
805
804
|
"set": "standard",
|
|
806
|
-
"row": "| `<m-flow>` |
|
|
807
|
-
"entry": "### `<m-flow>`\n\nData example (child `<script type=\"application/json\">`): `{\"nodes\":[{\"id\":\"a\",\"label\":\"
|
|
805
|
+
"row": "| `<m-flow>` | Flow chart: boxes and arrows by step | largest node/edge step | `{nodes:{id:str\\|int,label?,tex?,x:num,y:num,w:num,h:num,step?,tone?,at?,shape?:str}[],edges?:{from:str\\|int,to:str\\|int,step?,label?,tone?,dash?:bool,kind?:\"money\"\\|\"service\"\\|\"data\",amount?:str\\|num,shift?:num,pulse?:bool\\|any[],pulseAt?:num,offset?:num,at?,loop?:bool\\|str}[]}` |",
|
|
806
|
+
"entry": "### `<m-flow>`\n\nData example (child `<script type=\"application/json\">`): `{\"nodes\":[{\"id\":\"a\",\"label\":\"Observe\",\"x\":20,\"y\":40,\"w\":200,\"h\":70,\"step\":1},{\"id\":\"b\",\"label\":\"Update\",\"x\":320,\"y\":40,\"w\":200,\"h\":70,\"step\":2}],\"edges\":[{\"from\":\"a\",\"to\":\"b\",\"step\":2}]}`\n\n| prop | type | default | meaning |\n|---|---|---|---|\n| `size` | number | `26` | box text px |\n| `pulse-n` | number | `3` | pulse dots |\n| `label-gap` | number | `12` | min label–box gap px |\n\n; px; `x`, `y` = box top-left, `w`, `h` = size.\n\n- node: `id`, `label` (`\\n`) or `tex` (KaTeX), `step`, `tone` (`term`/`emph`/`muted`), `at` (start s), `shape:\"diamond\"` (decision; ~2× text width)\n- edge: `from` `to` `step` (default: later end), `label`, `tone`, `dash`, `offset` (label gap), `at`, `loop` (back edge: `\"left\"` `\"right\"` `\"top\"` `\"bottom\"` or `true` = auto)",
|
|
808
807
|
"ext": {
|
|
809
|
-
"business": "
|
|
808
|
+
"business": "Business-model edges:\n\n- `kind`: `money` (thick), `service`, `data` (dashed); `tone`/`dash` win\n- `amount`: bold figure\n- `shift`: px right of travel; both directions = 2 parallel lines\n- `pulse`: `pulse-n` dots run start→end in `pulse-dur` s; `true` = once after drawing; `[step, …]` = once per step; pulse steps count"
|
|
810
809
|
}
|
|
811
810
|
},
|
|
812
811
|
"m-gendai": {
|
|
@@ -847,8 +846,8 @@ export const PACK = {
|
|
|
847
846
|
},
|
|
848
847
|
"m-kpi": {
|
|
849
848
|
"set": "standard",
|
|
850
|
-
"row": "| `<m-kpi>` |
|
|
851
|
-
"entry": "### `<m-kpi>`\n\n| prop | type | default | meaning |\n|---|---|---|---|\n| `cols` | number | `0` |
|
|
849
|
+
"row": "| `<m-kpi>` | KPI cards by step; count-up, change arrow, note | largest card step (default 1 card = 1 step) | `{cards:{label?,value:num,digits?:int,unit?:str,prefix?:str,from?:num,tone?,delta?:{dir?:\"up\"\\|\"down\",text?:str,good?:bool},note?,step?,at?}[]}` |",
|
|
850
|
+
"entry": "### `<m-kpi>`\n\n| prop | type | default | meaning |\n|---|---|---|---|\n| `cols` | number | `0` | cards per row (0 = count, ≤ 4) |\n| `digits` | number | `0` | decimals (card wins) |\n| `per-step` | number | `1` | cards per step (0 = all) |\n| `count` | bool | `true` | count up |\n| `size` | number | `0` | number px (0 = auto) |\n\n- `label`: above. `value` (`digits`, commas). `unit`: after. `prefix`: before (`+`, `~`). Negative `value` has its own −: no `prefix` `−` (−−12); `prefix: \"−\"` only with a positive decrease\n- `from`: count start (default 0; may count down)\n- `tone`: number, top band (`term`, `emph`, `accent2`, `series-1..4`)\n- `delta`: `{\"dir\": \"up\" | \"down\", \"text\": \"+4\", \"good\": true}`: ▲/▼ + text; good (default `up`) `--term`, bad `--emph`\n- `note`: bottom line\n- `variant`: `count` (default), `rise`, `flip`, `underline`; `count=\"false\"` → `rise`\n- `cues(k)`: start times of 2nd+ cards in a step (for `{cue}`)"
|
|
852
851
|
},
|
|
853
852
|
"m-map-japan": {
|
|
854
853
|
"set": "maps",
|
|
@@ -867,8 +866,8 @@ export const PACK = {
|
|
|
867
866
|
},
|
|
868
867
|
"m-menu": {
|
|
869
868
|
"set": "standard",
|
|
870
|
-
"row": "| `<m-menu>` |
|
|
871
|
-
"entry": "### `<m-menu>`\n\n| prop | type | default | meaning |\n|---|---|---|---|\n| `cols` | number | `0` |
|
|
869
|
+
"row": "| `<m-menu>` | Grid of slide-link cards (contents); plain <a href=\"#<slide id>\">; visited mark | ceil(cards / per-step) (per-step=\"0\": 0) | child `<a href>` links (not JSON) |",
|
|
870
|
+
"entry": "### `<m-menu>`\n\n| prop | type | default | meaning |\n|---|---|---|---|\n| `cols` | number | `0` | columns (0 = auto) |\n| `per-step` | number | `0` | cards per step (0 = all, no steps) |\n| `size` | number | `34` | title px |\n| `visited` | bool | `true` | mark visited cards |\n\nContents; choosing where to start. Add the menu after import; in the first draft use a plain list.\n```html\n<m-menu cols=\"3\" aria-label=\"Today\">\n <a href=\"#s-njd4kp\" data-icon=\"1\" data-sub=\"Poet\">Poem A</a>\n <a href=\"#s-uhqygr:2\" data-icon=\"2\" data-sub=\"Order\">Poem B</a>\n</m-menu>\n```\n\n- One child `<a href>` = one card. `href`: `#<slide id>` (step 0) or `#<id>:<step>` (`0`, `1`, … `concl`); ids are added on import; content = title\n- `data-icon`: circle text (`1`, `A`). `data-sub`: subtitle\n- `per-step=\"n\"`: n cards per step (from `data-from`); unshown cards inert. `0` = all at once\n- `cols` default: ≤ 3 cards 1 row, 4 → 2, more → 3. Min height `--mm-h` (104px), gap `--mm-gap` (18px). Fill, centred: `style=\"height:100%;align-content:center;--mm-h:150px\"`"
|
|
872
871
|
},
|
|
873
872
|
"m-numberline": {
|
|
874
873
|
"set": "math",
|
|
@@ -887,24 +886,23 @@ export const PACK = {
|
|
|
887
886
|
},
|
|
888
887
|
"m-pie": {
|
|
889
888
|
"set": "standard",
|
|
890
|
-
"row": "| `<m-pie>` |
|
|
891
|
-
"entry": "### `<m-pie>`\n\nData example (child `<script type=\"application/json\">`): `{\"slices\":[{\"label\":\"
|
|
889
|
+
"row": "| `<m-pie>` | Pie/donut; labels inside big slices, leader lines for small | 1 (all at once); per-step n slices; or slice step | `{slices:{label?,value:num,tone?,step?,place?:\"auto\"\\|\"in\"\\|\"out\"}[],center?:str}` — the slices go in \"slices\" (not \"data\" or \"groups\"); value is a number, not a percentage string; the slices are drawn clockwise from 12 o'clock in the written order |",
|
|
890
|
+
"entry": "### `<m-pie>`\n\nData example (child `<script type=\"application/json\">`): `{\"slices\":[{\"label\":\"Food\",\"value\":7.2},{\"label\":\"Housing\",\"value\":8.5},{\"label\":\"Other\",\"value\":2.1,\"tone\":\"muted\"}]}`\n\n| prop | type | default | meaning |\n|---|---|---|---|\n| `donut` | number | `0` | inner radius ratio (0 = pie) |\n| `unit` | string | `\"\"` | value unit |\n| `digits` | number | `0` | value decimals |\n| `pct-digits` | number | `0` | percent decimals |\n| `show` | string | `\"pct\"` | pct, value, both or none |\n| `per-step` | number | `0` | slices per step (0 = all) |\n\n<!--part:m-bars-->Shares of a whole, all at once. Fine comparison: `m-bars`.<!--/part-->\n\n- slice: `label`, `value` (percent computed), `tone` (`term` `emph` `accent2` `muted` `fg` `series-1..4`), `step`, `place` (`auto` default, `in`, `out`)\n - Clockwise from 12 in order; \"Other\" last, `\"tone\": \"muted\"`\n - ≤ 6–7 slices\n- <!--part:m-cycle-->`center`: hole text, a string (`\\n`; `{total}` = sum, e.g. `\"Answers\\n{total}\"`); `m-cycle`'s `center` is an object<!--/part-->\n- `donut`: `0.5`–`0.6`\n- `show` (under name): `pct` (default), `value`, `both`, `none`\n- `unit` `digits`: value unit, decimals; `pct-digits` (default 0). Percents rounded to sum to 100%\n- Steps: all at step 1; `per-step=\"1\"` only if narrated slice by slice (outline faint). Slice `step` wins\n- `variant`: `fade` (default), `sweep` (clockwise from 12), `grow` (rim grows out)"
|
|
892
891
|
},
|
|
893
892
|
"m-predict": {
|
|
894
893
|
"set": "standard",
|
|
895
|
-
"row": "| `<m-predict>` |
|
|
896
|
-
"entry": "### `<m-predict>`\n\nData example (child `<script type=\"application/json\">`): `{\"question\":\"
|
|
894
|
+
"row": "| `<m-predict>` | Predict, reveal; votes as bars, answer framed | 0 question, 1 bars, answer-step (2) | `{question?:str,choices:{label,tone?}[],answer:int,counts?:int[],note?}` — choices are objects {\"label\": …} (not strings); answer is the 0-based index of the right choice; counts (optional) has one whole number ≥ 0 per choice |",
|
|
895
|
+
"entry": "### `<m-predict>`\n\nData example (child `<script type=\"application/json\">`): `{\"question\":\"Which falls first?\",\"choices\":[{\"label\":\"Heavy\"},{\"label\":\"Light\"},{\"label\":\"Same\"}],\"answer\":2,\"counts\":[14,3,9],\"note\":\"No air: same\"}`\n\n| prop | type | default | meaning |\n|---|---|---|---|\n| `answer-step` | number | `2` | answer step |\n| `unit` | string | `\"\"` | count unit |\n| `poll` | string | `\"\"` | poll id (no live counts yet) |\n| `ticks` | bool | `true` | grid |\n\n- 2–6 choices. Video/print/start show `counts` (or 0)\n- Script uses `counts`; vote at `{note:hands up}` (parens get read)\n- `poll=\"p1\"`: reserved; no live reveals yet (`ctx.live.poll(id)` is null), so viewer/author counts are used"
|
|
897
896
|
},
|
|
898
897
|
"m-quad": {
|
|
899
898
|
"set": "standard",
|
|
900
|
-
"row": "| `<m-quad>` | 2
|
|
901
|
-
"entry": "### `<m-quad>`\n\nData example (child `<script type=\"application/json\">`): `{\"x\":{\"lo\":\"
|
|
899
|
+
"row": "| `<m-quad>` | 2-axis positioning map (4 quadrants); points one per step | largest step / to.step (1 point = 1 step) | `{x?:{lo?:str,hi?:str},y?:{lo?:str,hi?:str},quads?:{tr?:str,tl?:str,bl?:str,br?:str,fill?:str},items:{label?,x:num,y:num,step?,at?,tone?,anchor?:\"right\"\\|\"left\"\\|\"above\"\\|\"below\",r?:num,self?:bool,to?:{x:num,y:num,label?,step?,at?}}[]}` |",
|
|
900
|
+
"entry": "### `<m-quad>`\n\nData example (child `<script type=\"application/json\">`): `{\"x\":{\"lo\":\"Manual\",\"hi\":\"Auto\"},\"y\":{\"lo\":\"Costly\",\"hi\":\"Cheap\"},\"items\":[{\"label\":\"Co. A\",\"x\":0.25,\"y\":0.7},{\"label\":\"Us\",\"x\":0.8,\"y\":0.82,\"self\":true}]}`\n\n| prop | type | default | meaning |\n|---|---|---|---|\n| `size` | number | `26` | label px |\n| `quads-step` | number | `0` | quadrant-name step (0 = start) |\n\nPositioning, effect×effort, SWOT: show the empty space.\n\n- `x` `y`: axis end words (step 0)\n- `quads`: names (tr = top-right, tl, bl, br); `fill: \"tr\"` tints one; names at `quads-step`\n- item: `label`, `x` `y` (0–1; 0.5 = axis cross), `step` (default next), `at`, `tone` (`term`/`fg`; default muted), `anchor` (`right`, `left`, `above`, `below`), `r`\n- `self: true`: big `--emph` point, ring pulse\n- `to: {\"x\", \"y\", \"label\", \"step\", \"at\"}`: slides at `to.step` (default next), dashed trail; `label` on arrival\n- `cues(k)`: start times of 2nd+ points in a step, for `{cue}`\n\nNotes\n\n- Quadrant names avoid points and labels (else labels move, or `ctx.report`)\n- Label overlaps not fixed: change `anchor` or shift"
|
|
902
901
|
},
|
|
903
902
|
"m-scatter": {
|
|
904
903
|
"set": "standard",
|
|
905
|
-
"row": "| `<m-scatter>` |
|
|
906
|
-
"entry": "### `<m-scatter>`\n\nData example (child `<script type=\"application/json\">`): `{\"series\":[{\"label\":\"
|
|
907
|
-
"sup": true
|
|
904
|
+
"row": "| `<m-scatter>` | Scatter plot; point series by step, then a trend line (least squares or 2 points) | series + trend (default 1 series = 1 step, lines 1 step) | `{series:{label?,tone?,step?,at?,points:([num,num]\\|{x:num,y:num,label?,anchor?:\"right\"\\|\"left\"\\|\"above\"\\|\"below\"\\|\"top\"\\|\"bottom\",tone?})[]}[],trend?:str\\|{fit?:\"linear\",pts?:[[num,num],[num,num]],series?:int\\|any[],label?,tone?,dash?:bool,step?,at?,digits?:int}\\|[the same {…},…]}` — points are [x, y] or {\"x\", \"y\", \"label\"}; axes go in attributes (xr=\"[0,10]\" xl=\"…\"); trend is \"linear\" or {\"fit\": \"linear\", \"label\": \"…\"} or {\"pts\": [[x0, y0], [x1, y1]]} |",
|
|
905
|
+
"entry": "### `<m-scatter>`\n\nData example (child `<script type=\"application/json\">`): `{\"series\":[{\"label\":\"Sunny\",\"points\":[[24,210],[28,380],[31,560],{\"x\":34,\"y\":690,\"label\":\"Heatwave\"}]}],\"trend\":\"linear\"}`\n\n| prop | type | default | meaning |\n|---|---|---|---|\n| `xr` | json | `null` | x range |\n| `yr` | json | `null` | y range |\n| `xt` | json | `null` | x ticks |\n| `yt` | json | `null` | y ticks |\n| `xf` | number | | x tick decimals |\n| `yf` | number | | y tick decimals |\n| `xl` | string | `\"\"` | x title |\n| `yl` | string | `\"\"` | y title |\n| `r` | number | `9` | point radius px |\n\nRelation of two quantities (heat vs sales). Points, then trend.\n\n- series: `points` (`[x, y]` or `{\"x\", \"y\", \"label\", \"anchor\", \"tone\"}`), `label` (series name, top with marker), `tone` (`term` `emph` `accent2` `muted` `fg` `series-1..4`), `step` (1 series = 1 step; same = together), `at` (start s)\n - Point `label` placed clear of overlaps (`anchor` = first try: `right` `left` `above` `below`); outliers only\n - Marker shape per series; repeats after 4, so ≤ 4 series\n- trend: `\"linear\"` (least squares on all points), or `{\"fit\": \"linear\", \"series\": 0, \"label\", \"tone\", \"dash\", \"step\", \"at\", \"digits\"}`, or `{\"pts\": [[x0, y0], [x1, y1]]}` (segment; exactly 2 points; vertical OK); several = array\n - `series`: fitted series index from 0, or array (default all)\n - `label`: `{r}` correlation, `{a}` slope, `{b}` intercept (`digits`, default 2), e.g. `\"Trend (r = {r})\"`\n - `step`: default after the last series\n - Clipped to the plot; lines outside reported. Vertical `pts`: `{a}` `{b}` empty; `{r}` only for fits\n- Axes: `xr` `yr` range, `xt` `yt` ticks, `xf` `yf` decimals, `xl` `yl` titles; range/ticks auto if omitted\n- `variant`: `fade` (default), `sweep` (left to right), `grow` (points grow, line from the middle)\n- Lecture view (`ctx.preview`): later points and lines faint"
|
|
908
906
|
},
|
|
909
907
|
"m-score": {
|
|
910
908
|
"set": "music",
|
|
@@ -935,8 +933,8 @@ export const PACK = {
|
|
|
935
933
|
},
|
|
936
934
|
"m-timeline": {
|
|
937
935
|
"set": "standard",
|
|
938
|
-
"row": "| `<m-timeline>` |
|
|
939
|
-
"entry": "### `<m-timeline>`\n\nData example (child `<script type=\"application/json\">`): `{\"nodes\":[{\"id\":\"a\",\"label\":\"
|
|
936
|
+
"row": "| `<m-timeline>` | Timeline; events one by one; periods as bands, overlaps stacked; end exclusive (\"1912\" = start of 1912) | event count (default 1 per step in time order; per-step n each; node step wins) | `{nodes:{id?:str\\|int,label?,tex?,note?,tone?,when:num\\|str,whenLabel?:str,end?:num\\|str,lane?:str,step?,at?,after?:(str\\|int)[],progress?:num}[],edges?:{from:str\\|int,to:str\\|int,label?,tone?,dash?:bool,step?,at?}[]}` — when / end: a number or \"YYYY\", \"YYYY-MM\", \"YYYY-MM-DD\"; end is exclusive (\"1912\" is the start of 1912). whenLabel: the date text shown instead of the computed one (when still sets the position). A node with end is a period (a band); lane groups bands into named lanes |",
|
|
937
|
+
"entry": "### `<m-timeline>`\n\nData example (child `<script type=\"application/json\">`): `{\"nodes\":[{\"id\":\"a\",\"label\":\"Meiji Restoration\",\"when\":\"1868\",\"whenLabel\":\"Meiji 1\"},{\"id\":\"b\",\"label\":\"Constitution\",\"when\":\"1889\",\"note\":\"Feb 11\"},{\"id\":\"c\",\"label\":\"Sino-Japanese War\",\"when\":\"1894\",\"end\":\"1895\",\"tone\":\"emph\"}]}`\n\n| prop | type | default | meaning |\n|---|---|---|---|\n| `orient` | string | `\"h\"` | h or v |\n| `scale` | string | `\"time\"` | time or even |\n| `per-step` | number | `1` | events per step (0 = all) |\n| `size` | number | `26` | label px (shrinks to 24) |\n| `unit` | string | `\"\"` | ticks: day, week, month |\n| `today` | string | `\"\"` | today line (YYYY-MM-DD) |\n\nHistory, lives, schedules. No coordinates; content and times only.\n\n(`edges` optional).\n\n- `when`: number (`1868`, `-500`, `0.5`) or `\"YYYY\"` `\"YYYY-MM\"` `\"YYYY-MM-DD\"`; shown as the date line\n- `whenLabel`: text replacing the date (\"Meiji 1\"); `when` still sets position\n- `label` (`\\n`) or `tex` (KaTeX)\n- `note`: small last line in the box (`--muted`); after the name for periods/milestones\n- `tone`: `term` (default), `emph`, `muted`, `accent2`, `series-1..4`\n- `end`: period, a band below the axis; name inside (or beside); `\\n` names thicken it\n- `end` is exclusive: Meiji 1868–1912 and Taishō 1912–1926 share a row; through December = next month (`\"2027-01\"`)\n- `lane`: named group of rows (\"Eras\", \"Authors\"); overlaps stack within; `lane` without `end` = milestone (◆)\n- `step`, `at` (start s)\n- `edges`: extra links (`from` `to` `label` `tone` `dash` `step`); dashed arrows (`dash: false` solid)\n- Schedules: `after: [\"id\", …]` (arrow end→start), `progress` (0–100 %); `today` line; tick `unit`\n - `after` only between periods and milestones; `today` needs a period\n\nLayout:\n\n- `orient`: `h` (default) or `v`; `scale`: `time` (default) or `even` (very uneven gaps)\n- Events (no `end` or `lane`): axis dot plus date-and-name box, alternating sides (`v`: left/right); 2 rows when crowded\n- With periods: round ticks; event boxes all above the axis\n- Steps: time order, periods and events together; the axis comes with the first\n- `variant`: `fade` (default), `draw` (lines first, bands drawn), `grow` (boxes grow, bands stretch); same steps and end\n- Lecture view (`ctx.preview`): later items faint\n- `cues(k)`: start times of 2nd+ items in a step (for `{cue}`)"
|
|
940
938
|
},
|
|
941
939
|
"m-timer": {
|
|
942
940
|
"set": "tools",
|
|
@@ -945,13 +943,13 @@ export const PACK = {
|
|
|
945
943
|
},
|
|
946
944
|
"m-tree": {
|
|
947
945
|
"set": "standard",
|
|
948
|
-
"row": "| `<m-tree>` |
|
|
949
|
-
"entry": "### `<m-tree>`\n\nData example (child `<script type=\"application/json\">`): `{\"nodes\":[{\"id\":\"r\",\"label\":\"
|
|
946
|
+
"row": "| `<m-tree>` | Hierarchy tree (org chart, taxonomy), built level by level from the root; auto layout | depth (by=\"level\") or node count (by=\"node\"); or the largest step | `{nodes:{id:str\\|int,label?,tex?,note?,tone?,parent?:str\\|int,branch?:str,step?,at?}[],edges?:{from:str\\|int,to:str\\|int,label?,tone?,dash?:bool,step?,at?}[],path?:(str\\|int)[],pathStep?:int,pathNote?:str}` — exactly one node without parent (the root) |",
|
|
947
|
+
"entry": "### `<m-tree>`\n\nData example (child `<script type=\"application/json\">`): `{\"nodes\":[{\"id\":\"r\",\"label\":\"Animals\"},{\"id\":\"a\",\"label\":\"Vertebrates\",\"parent\":\"r\"},{\"id\":\"b\",\"label\":\"Invertebrates\",\"parent\":\"r\"}]}`\n\n| prop | type | default | meaning |\n|---|---|---|---|\n| `orient` | string | `\"down\"` | down (default) or right |\n| `by` | string | `\"level\"` | level (default) or node (depth-first) |\n| `link` | string | `\"elbow\"` | elbow (default) or straight |\n| `size` | number | `0` | box text px (0 = 27, shrink to 24) |\n\nParent–child structures (org charts, taxonomies, outlines). No coordinates; laid out without overlaps.\n\n(`edges` optional).\n\n- node: `id`, `label` (`\\n`) or `tex` (KaTeX), `parent` (parent `id`; exactly one root without `parent`), `note` (small, **under** box), `tone` (`term` default, `emph`, `muted`, `accent2`, `series-1..4`), `step`, `at` (start s)\n- Children in array order; parent centred over them\n- edge: extra links (`from` `to` `label` `tone` `dash` `step`), dashed arrow outside the tree; best at same depth; step: later end\n- Child `branch`: line text (e.g. probability). `path`: root-first `id`s highlighted in turn (default 1 step per line, after the tree; `pathStep`: in one step; `pathNote`: end note)\n- `orient=\"right\"` for wide taxonomies. `by=\"node\"`: one at a time, depth-first (to follow a branch). Node `step` wins\n- Lines `--muted`, 3 px; `tone: emph` box: `--emph-tint` fill\n- Fit (~440 px high): ~8 four-character boxes per level (`down`), ~7 (`right`); ~5 levels. More leaves: 2 staggered rows (~16 / ~11), then 2-line names. Text ≥ 24 px; overflow spills, reported. Too many: split\n- `variant`: `fade` (default), `draw` (lines first), `grow`\n- Lecture view (`ctx.preview`): later parts faint"
|
|
950
948
|
},
|
|
951
949
|
"m-venn": {
|
|
952
950
|
"set": "standard",
|
|
953
|
-
"row": "| `<m-venn>` |
|
|
954
|
-
"entry": "### `<m-venn>`\n\nData example (child `<script type=\"application/json\">`): `{\"sets\":[{\"label\":\"
|
|
951
|
+
"row": "| `<m-venn>` | Venn of 2–3 sets, one by one; then overlaps with items | sets + 1 (overlaps=\"each\": sets + overlaps with items, or all overlaps if none) | `{sets:{label,tone?}[],regions?:{A?:str[]\\|str,B?:str[]\\|str,C?:str[]\\|str,AB?:str[]\\|str,AC?:str[]\\|str,BC?:str[]\\|str,ABC?:str[]\\|str}}` |",
|
|
952
|
+
"entry": "### `<m-venn>`\n\nData example (child `<script type=\"application/json\">`): `{\"sets\":[{\"label\":\"Mammals\"},{\"label\":\"Sea animals\"}],\"regions\":{\"A\":[\"Lion\"],\"B\":[\"Tuna\"],\"AB\":[\"Whale\",\"Dolphin\"]}}`\n\n| prop | type | default | meaning |\n|---|---|---|---|\n| `size` | number | `26` | item text px (shrinks to 24) |\n| `spread` | number | `1` | centre distance ÷ radius (0.7–1.3) |\n| `overlaps` | string | `\"together\"` | together or each |\n\n<!--part:m-compare-->Shared and distinct traits. Per-point values: `m-compare`.<!--/part-->\n\n- `sets`: 2 or 3; `label` outside; `tone` (`term`, `emph`, `muted`, `accent2`, `series-1..4`; default `term`, `accent2`, `series-4`). Avoid `emph` (used for overlaps)\n- `regions`: items per region (array or `\\n` text). Keys: letters in alphabetical order, A B C = `sets` order:\n - `A`: only A; `AB`: A and B (with 3 sets, not C); `ABC`: all three\n - 2 sets: `A` `B` `AB`; 3: `A` `B` `C` `AB` `AC` `BC` `ABC`; all optional. C keys with 2 sets: error card\n- Area not to scale. `spread` (default 1): smaller = more overlap\n- Overlap items bold; 1–2 words with 3 sets\n- Steps: each set with its own items → overlaps (those with items tinted `--emph`, outlined, items shown; if none have items, all). `overlaps=\"each\"`: one by one (`AB`, `AC`, `BC`, `ABC`)\n- `variant`: `fade` (default), `draw` (outlines first)"
|
|
955
953
|
}
|
|
956
954
|
},
|
|
957
955
|
"tableHead": "| component | what it shows | steps | data shape |\n|---|---|---|---|",
|
|
@@ -960,7 +958,7 @@ export const PACK = {
|
|
|
960
958
|
"extHead": "### `<{name}>`: extension for this part set (the component is described in §3)"
|
|
961
959
|
},
|
|
962
960
|
"ja": {
|
|
963
|
-
"common": "# AI への指示\n\n指示の版:`2dcfdea9`\n\n短い **Egatari の教材**を 1 つ書いてください。段階ごとに出る HTML のスライド(`deck.html`)と口述原稿(`narration.md`)で、どちらも自動で組まれ、品質チェックを受けます。ここにないものは使えません。教材は頼まれた言語で書きます(スライドと口述原稿は同じ言語)。規格には **R-fit** のような名前があり、修正依頼は破った規格を名前で示します。依頼は最後の **頼みたいこと**(かその前の会話)にあります。空の項目やない項目はほどよく決め、A と B が両方残っていれば書き込みのある方に従います。\n\n**よくある失敗:**\n\n- **2 つの囲みはどちらも最後まで書いて閉じる。**囲みの途中で終わらない(R-output)。構成案がなければ、教材は短くする(5〜8 枚)。頼む文に構成案とその範囲があれば、その範囲のスライドをちょうどその枚数だけ書く(エディタは 1 回に 6 枚までしか頼まないので、収まる)\n- **1280×720 のスライドの大きさ**(品質チェックが測る。R-fit):本文の場所は 1184 × 443 px(565 px まで。`noconcl` なら 1184 × 558)。字は 32 px・1 行 46 px で、入るのは**およそ 8 行**。はみ出す 46 px ごとに 1 行を削る。**図や部品の中も含め、字はすべて 24 px 以上**\n- **グラフと図:**部品は大きさによらず字を 24〜28 px で描くので、決めるのは部品の大きさ(R-fit)\n- **その場で書く `<svg>`:**字は「表示の幅 ÷ viewBox の幅」で縮むので、viewBox を表示の画素で書く(`<svg viewBox=\"0 0 560 320\" width=\"560\" height=\"320\">`)。`font-size` は 24 以上。`width:100%` と別の幅の viewBox を組み合わせない。合う部品があれば部品を使う\n\n## 1. 出力の形\n\n- **R-output** 返事は**ちょうど 2 つのコードの囲み**にし、この順で、名前を `deck.html` と `narration.md` にする(始まりの行は ```` ```deck.html ```` と ```` ```narration.md ````)。間には何も書かない(前後に 1 行の添え書きはよい)。1 つのファイルを囲みに分けない。ファイル・キャンバス・添付にせず、返事の本文に書く。ほかのファイルを参照しない(画像・`{{FIG:…}}`・`{{JSON:…}}`・外の URL・`<link>` は使わない)。囲みの途中で終わらない(長すぎるなら枚数を減らす。ただし構成案の範囲を頼まれたら、ちょうどその枚数)\n- **R-outline** **構成案だけ**を頼まれたら(長い教材を 2 回に分けて作るとき)、`outline` という名前の囲み 1 つ(始まりの行は ```` ```outline ````)だけで返し、`deck.html` と `narration.md` は書かない:列が「番号」「見出し」「要点(1 行)」の Markdown の表で、スライドごとに 1 行、全スライドを順に。その後の頼む文は範囲を示す(「構成案の 7〜12 枚目」)ので、その見出しと要点のとおりに、ちょうどそのスライドを書く\n- **R-noids** スライドの id を**書かない**。`<section class=\"slide\">` に `id` を付けず、口述原稿の見出しにも `{#…}` を付けない。id は取り込みでエディタが付ける。id のあるデッキを渡されたとき(修正依頼)は、今ある `id=\"…\"` と `{#…}` をそのまま残す\n\n## 2. deck.html\n\n### 2.1 骨組み\n\n```html\n<!DOCTYPE html>\n<html lang=\"ja\" data-theme=\"default\">\n<head>\n<meta charset=\"utf-8\">\n<meta name=\"viewport\" content=\"width=device-width, initial-scale=1\">\n<title>教材の題名</title>\n</head>\n<body>\n<div id=\"stage\">\n <section class=\"slide cover noconcl static\"> … </section>\n <section class=\"slide\"> … </section>\n</div>\n</body>\n</html>\n```\n\n- `lang`:`ja`・`en` など(教材の言語)。`data-theme`:ビジネス・ピッチは `sumi`、国語は `kokugo`、ほかは `default`\n- `<script>` は部品のデータ(§2.6)だけ。`<style>` は配置(大きさ・間隔)だけに使い、色は書かない\n\n### 2.2 スライド\n\n- 普通のスライド:`<h2>` の見出し、`<div class=\"body\">…</div>`、`<div class=\"concl\"><span>…</span></div>`(結論の行。短い 1 文)\n- 表紙:`<section class=\"slide cover noconcl static\">` に、あれば `<div class=\"venue\">…</div>`、`<h1>題名</h1>`、あれば `<div class=\"au\">…</div>`\n- 章の扉:`<section class=\"slide sec noconcl static\"><h1>章の題</h1></section>`\n- `<section>` の class:`noconcl`(結論の行なし)、`static`(段階なし)、`nostep`(箇条書きも初めから全部)、`layout-tate`(縦書き。kokugo の束があるときだけ)、属性 `data-morph`(§2.5)\n- `.body` の中:`<p class=\"sub\">` 小見出し、`<div class=\"big\">` 主要な式、`<p class=\"note\">` 補足、`<div class=\"thm\">` 定理の枠、`<div class=\"cols\">` 横並び、普通の `<p>` `<ul>` `<ol>` `<table>`\n- 字の強調(色を付ける唯一の方法):`term`(用語・問い)、`emph`(結論・問題・目標)、`muted`(既知の結果・控えめ)、`b`(太字)\n- **R-headings** スライドの見出し(表紙と扉は `h1`、ほかは `h2`)は**すべて違う**ものにする(同じなら語を足す)。そのスライドの口述原稿の節は `## ` に続けて**見出しとまったく同じ文字列**で始める(`<br>` などのタグは除く)\n- **R-colors** 色はテーマだけで:上の class と式のマクロ `\\hlE` `\\hlT` `\\hlM`。16 進・`rgb()`・色の名前・`\\color`・`\\textcolor` は使わない。部品や SVG の中では:**色はテーマの CSS 変数だけ**を使う:`var(--fg)` `var(--term)` `var(--emph)` `var(--muted)` `var(--accent2)` `var(--line)`。SVG では属性ではなく `style=\"stroke:var(--emph)\"` で書く(`DECK.el` は `fill` `stroke` に `var(` があれば自動で style に回す)\n\n### 2.3 段階(出す順 = 話す順)\n\n- **R-steps** 段階 0 は現れたときの姿で、文脈だけ(見出し・小見出し・導入の 1 文)。`data-step=\"k\"`(k = 1, 2, …)の要素は段階 k で現れる。材料(箇条書きの項目・式・表の行・図の部分)は話す順に出す。式とそれを導く 1 文は同じ段階(`<div data-step=\"k\">` で一緒に囲む)。1 枚の段階は 5 前後まで\n- 結論の行は自動で**最後の段階** `concl` になる(`data-step` を付けない)\n- `data-step` が 1 つもないスライドでは、上の階層の箇条書きの項目(`.body > ul > li`・`.body > ol > li`)に 1, 2, … が自動で付く。1 つでもあれば自動にならないので、出すものすべてに付ける\n- 部品は自分の段階を足す(§3)。`data-from`(既定 1)から始まる\n- つまり段階は `0 … max` と、結論の行があれば `concl`。`static` のスライドは段階 0 だけ\n\n### 2.4 数式(KaTeX)\n\n- **R-math** 行内は `\\( … \\)`、別行は `\\[ … \\]`。式の中の `<` は `\\lt`、`>` は `\\gt`。標準のほかに使えるマクロ:`\\hlE{…}`(emph)`\\hlT{…}`(term)`\\hlM{…}`(muted)、`\\htmlId{ID}{…}`、`\\htmlData{mark=ID}{…}`、`\\htmlClass{…}{…}`、`\\morph{ID}{…}`。`\\newcommand` と `\\color` は使わない。記号は最初に使う所で定義する(`\\(\\mu\\)`:母平均)\n\n### 2.5 注目の演出とモーフ\n\n- **R-marks** 口述原稿の `{mark:ID}`(§4)は、**同じスライド**の目印に印を付ける。目印:スライドの中の `id=\"ID\"` か `data-mark=\"ID\"` の要素。式の一部は KaTeX の `\\htmlId{ID}{…}` / `\\htmlData{mark=ID}{…}`(build はこの 2 つと `\\htmlClass` だけを許す)。同じ ID を何枚かで使うなら `data-mark` にする(id は文書の中で一意に)\n- モーフ(なくてよい):`<section class=\"slide\" data-morph>` は前のスライドの要素を今の位置へ滑らせる。両方のスライドの要素に同じ `data-id=\"…\"`、式の一部は両方に `\\morph{ID}{…}`。段階 0 で見えている要素だけが動く\n\n### 2.6 部品\n\n- **R-components** 動く図は一覧(§3)の Web Components `<m-…>` で、`.body` の中に置く。どれにも高さ(`style=\"height:380px\"`)と `aria-label` を付ける。データは子の `<script type=\"application/json\">…</script>` **1 つ**にその場で書く。**図の数字は正しく**(計算する。見た目のために値を作らない。架空の数字は架空と書く)。関数の式は算術の式だけで、コードとしては実行されない(`Math.exp(x)`・`x**2`)。動きが説明になる所だけに使う(たいていのスライドには要らない)\n\n### 2.7 表し方を選ぶ\n\n- **R-purpose** 表し方は習慣でなく、そのスライドで言いたいことから選ぶ。作者がグラフの種類を言っていればそれに従う。表は全パーツの一覧を兼ねる。使うのは渡された文章にあるパーツだけ(§3 と、入っている束)。入っていないパーツの方が合うときは、1 行のメモでそう伝える\n\n{{PURPOSES}}\n\n- **R-whole** 箇条書き・数字の札・円グラフは全体を一度に見せる。台本が 1 つずつ取り上げるときだけ 1 行ずつ出す(箇条書きなら全体に 1 つの `data-step` を付けるか、スライドに `nostep`)\n\n### 2.8 スライドに収める(品質チェックのエラー)\n\n- **R-title** 見出し:日本語は 26 字まで(全角 1・半角 0.5)、英語は 60 文字まで。コロンで終えない\n- **R-concl** 結論の行:日本語は 35 字まで、英語は 70 文字まで。1 行\n- **R-fit** 本文は 565 px(`noconcl` なら 680 px)より上で終える:1 枚におよそ 8 行・100 字・英語 60 語、または `big` の式 1 つと短い箇条書き 3 つ、または高さ 380 px までの部品と短い 1 行(2 行なら 330 px まで)。入らなければスライドを分ける。字を縮めず、字の大きさを書かない。図の中の字は 24 px 以上\n- **R-style** 日本語のスライドは常体(だ・である、体言止め)で、です・ます を使わない。句読点はデッキ全体で 1 つの組(`、。` か `,.`)。英語のスライドは短い句で\n\n## 3. 部品の一覧\n\nどの教材でも使える標準の部品。§6 の後に束の指示があれば、その種類の材料の部品が加わる。「steps」は部品が使うスライドの段階の数(`data-from` から。既定 1)。秒で測る属性(動きの長さ・ずれ)は載せない(既定で口述原稿に合う)。型が json の属性は、値に JSON を書く(`values=\"[0.1,0.5]\"`)。「データの形」の `?` は省略できる欄。型を書いていない label・tex・note・tone は str、step は int、at は num。名前やラベルの `*…*` は斜体、`_` `^` は次の 1 字だけ下付き・上付き。記号のまま出すなら全角の _ ^ *。\n\n{{CATALOG}}\n\n## 4. narration.md\n\n```markdown\n# 口述原稿:<教材の題名>\n\n## 減衰の式\n[0] 減衰の式です。時刻ごとに残っている原子の数を考えます。\n[1] 残る数は、はじめの数に、時間とともに小さくなる指数関数を掛けたものです。\n[2] {mark:n0|circle}{N₀|エヌゼロ} は、時刻ゼロのときの、はじめの数です。\n[concl] 半分になるまでの時間は、崩壊定数だけで決まります。\n```\n\n- スライドごとに 1 つの節を、**スライドの順に、すべてのスライド(表紙も)について**:`## <スライドの見出し>`(R-headings)。`{#id}` は付けない(R-noids)\n- **R-narr-steps** 段階の印は `[0]` `[1]` … と `[concl]`。**どのスライドのどの段階にも口述原稿を書き**(段階 0 から max まで、結論の行があれば `[concl]`)、**ない段階の印は書かない**(`static` の表紙は `[0]` だけ。結論の行がなければ `[concl]` もない。`[01]` とは書かない)。段階の中では、その段階で現れるものだけを話す\n- **R-dialogue** **既定は話者 1 人**で、話者名を書かない。掛け合いは頼まれたときだけ(3 人以上を頼まれても 2 役にし、最初にそう書く):行を `Expert:` か `Novice:` で始め(続きの行は字下げ。話者なしは Expert)、認知的徒弟制の形にする:\n - Novice は相づち役にせず、学習者の疑問を代弁するか、「つまり〜ということですか」と言い換える\n - Expert は答えて具体例か比喩を 1 つ足すか、言い換えを確かめて(違えば直して)1 歩進める\n - 理解の分かれ目(誤解しやすい所、「なぜ」が残る所)にだけ、1 枚に 1 回・2〜3 発言まで。ほかは Expert 1 人\n - 「なるほど」だけの発言、前の発言のくり返しは書かない。例:`Novice: つまり、大きいほど早く着くのですか。` `Expert: いつもではありません。大きすぎると谷を飛び越えます。大股で坂を下りすぎて、向こうの斜面に足が着くように。`\n- `{note:…}` 発表者用\n- `{cue}`:段階の中の同期点。部品の `cues(k)` の 1 つに 1 つ(部品の説明が求めるときだけ)\n- `{mark:ID}`・`{mark:ID|効果}`・`{mark:ID|効果|hold=秒}`・`{mark:clear}`:目印のことを言う言葉の**すぐ前**に置く。1 段階に 1〜2 個まで。言葉でも言う。効果:`underline`(既定。手描きの下線を左から右へ)、`circle`(手描きの囲み)、`box`(角丸の枠)、`spot`(対象のまわり以外を背景色で薄くする)、`laser`(光の点が対象の下へ滑ってきて少し留まる)\n- **R-reading** `{表示|読み}` は **1 つの記号か 1 つの用語**の読み:`{θ|シータ}`、`{N₀|エヌゼロ}`、`{論語|ろんご}`。1 つの記号に星・プライム・添え字・ハットやバーが付いていてもよい(`{Q*|キュースター}`、`{θ̂|シータハット}`)。表示は普通の文字で書き、LaTeX にせず、式やいくつもの記号にしない(`{1-η|…}`・`{θとη|…}` は誤り:記号ごとに読みを付け、関係は言葉で言う)\n- **R-formula** **式を読み上げない**:口述原稿に LaTeX・`\\`・`^`・`_`・`a + b = c` のような文字列を書かない。式の意味を言葉で言う(§4 の見本の [1])\n- 日本語の口述原稿は話し言葉の です・ます。英語は話し言葉の英語。目安は 1 秒に日本語 5 字・英語 2.5 語。1 回の発言は 1〜3 文\n\n## 5. 修正依頼\n\n利用者が**修正依頼**(規格の名前の付いた指摘の一覧と、今のファイル)を貼り付けたら、その指摘だけを直し、ほかは変えず、`id=\"…\"` と `{#…}` をすべてそのまま残し(R-noids)、また 2 つの囲みで返す(R-output)。依頼に一部のスライドしかなければ、そのスライドの `<section>` だけ(`<html>` なし)とその節だけを 2 つの囲みで返す(エディタが id で元の場所に戻す)。\n\n## 6. 見本\n\n小さな教材の見本(架空。形を見るためで、中身は写さない)。段階の数え方:2 項目の箇条書きは段階 1〜2 と `[concl]`<!--part:m-flow-->、箱が 4 つの `m-flow` は段階 1〜4<!--/part-->。いくつかの束の指示の最後にも見本がある。\n\n### 共通(英語・default テーマ・注目の演出<!--part:m-flow-->・m-flow<!--/part-->)\n\n```deck.html\n<!DOCTYPE html>\n<html lang=\"en\" data-theme=\"default\">\n<head>\n<meta charset=\"utf-8\">\n<meta name=\"viewport\" content=\"width=device-width, initial-scale=1\">\n<title>How a web page arrives</title>\n</head>\n<body>\n<div id=\"stage\">\n\n<section class=\"slide cover noconcl static\">\n <div class=\"venue\">Computing basics, lesson 1 (a fictional course)</div>\n <h1>How a web page arrives</h1>\n</section>\n\n<section class=\"slide\">\n <h2>Two programs take part</h2>\n <div class=\"body\">\n <p>Opening a page is a conversation between two programs.</p>\n <ul>\n <li id=\"browser\">The <span class=\"term\">browser</span> asks for the page and draws it</li>\n <li id=\"server\">The <span class=\"term\">server</span> keeps the page and sends it back</li>\n </ul>\n </div>\n <div class=\"concl\"><span>Every page load is a request and a reply</span></div>\n</section><!--part:m-flow-->\n\n<section class=\"slide\">\n <h2>From the address to the screen</h2>\n <div class=\"body\">\n <m-flow style=\"height:300px\" aria-label=\"Four stages: type the address, send a request, send the page back, draw the page\">\n <script type=\"application/json\">{\"nodes\": [\n {\"id\": \"a\", \"label\": \"Type the\\naddress\", \"x\": 10, \"y\": 100, \"w\": 250, \"h\": 110, \"step\": 1},\n {\"id\": \"b\", \"label\": \"Send a\\nrequest\", \"x\": 315, \"y\": 100, \"w\": 250, \"h\": 110, \"step\": 2},\n {\"id\": \"c\", \"label\": \"Send the\\npage back\", \"x\": 620, \"y\": 100, \"w\": 250, \"h\": 110, \"step\": 3, \"tone\": \"term\"},\n {\"id\": \"d\", \"label\": \"Draw the\\npage\", \"x\": 925, \"y\": 100, \"w\": 250, \"h\": 110, \"step\": 4, \"tone\": \"emph\"}\n ], \"edges\": [\n {\"from\": \"a\", \"to\": \"b\"}, {\"from\": \"b\", \"to\": \"c\"}, {\"from\": \"c\", \"to\": \"d\"}\n ]}</script>\n </m-flow>\n </div>\n <div class=\"concl\"><span>A slow page is slow in one of these four stages</span></div>\n</section><!--/part-->\n\n</div>\n</body>\n</html>\n```\n\n```narration.md\n# Narration: How a web page arrives\n\n## How a web page arrives\n[0] Today we follow a web page on its way from a server to your screen.\n\n## Two programs take part\n[0] Opening a page is a conversation between two programs.\n[1] {mark:browser}The browser is the program you look at. It asks for the page and then draws it.\n[2] {mark:server}The server is a program on another computer. It keeps the page and sends it back when asked.\n[concl] Every page load is a request and a reply.<!--part:m-flow-->\n\n## From the address to the screen\n[0] Let us put the steps in order.\n[1] First you type the address of the page.\n[2] The browser turns it into a request and sends it to the server.\n[3] The server finds the page and sends it back.\n[4] The browser draws the page on the screen.\n[concl] When a page is slow, one of these four stages is taking the time.<!--/part-->\n```",
|
|
961
|
+
"common": "# AI への指示\n\n指示の版:`69c736a1`\n\n短い **Egatari の教材**を 1 つ書いてください。段階ごとに出る HTML のスライド(`deck.html`)と口述原稿(`narration.md`)で、どちらも自動で組まれ、品質チェックを受けます。ここにないものは使えません。教材は頼まれた言語で書きます(スライドと口述原稿は同じ言語)。規格には **R-fit** のような名前があり、修正依頼は破った規格を名前で示します。依頼は最後の **頼みたいこと**(かその前の会話)にあります。空の項目やない項目はほどよく決め、A と B が両方残っていれば書き込みのある方に従います。\n\n**よくある失敗:**\n\n- **2 つの囲みはどちらも最後まで書いて閉じる。**囲みの途中で終わらない(R-output)。構成案がなければ、教材は短くする(5〜8 枚)。頼む文に構成案とその範囲があれば、その範囲のスライドをちょうどその枚数だけ書く(エディタは 1 回に 6 枚までしか頼まないので、収まる)\n- **1280×720 のスライドの大きさ**(品質チェックが測る。R-fit):本文の場所は 1184 × 443 px(565 px まで。`noconcl` なら 1184 × 558)。字は 32 px・1 行 46 px で、入るのは**およそ 8 行**。はみ出す 46 px ごとに 1 行を削る。**図や部品の中も含め、字はすべて 24 px 以上**\n- **グラフと図:**部品は大きさによらず字を 24〜28 px で描くので、決めるのは部品の大きさ(R-fit)\n- **その場で書く `<svg>`:**字は「表示の幅 ÷ viewBox の幅」で縮むので、viewBox を表示の画素で書く(`<svg viewBox=\"0 0 560 320\" width=\"560\" height=\"320\">`)。`font-size` は 24 以上。`width:100%` と別の幅の viewBox を組み合わせない。合う部品があれば部品を使う\n\n## 1. 出力の形\n\n- **R-output** 返事は**ちょうど 2 つのコードの囲み**にし、この順で、名前を `deck.html` と `narration.md` にする(始まりの行は ```` ```deck.html ```` と ```` ```narration.md ````)。間には何も書かない(前後に 1 行の添え書きはよい)。1 つのファイルを囲みに分けない。ファイル・キャンバス・添付にせず、返事の本文に書く。ほかのファイルを参照しない(画像・`{{FIG:…}}`・`{{JSON:…}}`・外の URL・`<link>` は使わない)。囲みの途中で終わらない(長すぎるなら枚数を減らす。ただし構成案の範囲を頼まれたら、ちょうどその枚数)\n- **R-outline** **構成案だけ**を頼まれたら(長い教材を 2 回に分けて作るとき)、`outline` という名前の囲み 1 つ(始まりの行は ```` ```outline ````)だけで返し、`deck.html` と `narration.md` は書かない:列が「番号」「見出し」「要点(1 行)」の Markdown の表で、スライドごとに 1 行、全スライドを順に。その後の頼む文は範囲を示す(「構成案の 7〜12 枚目」)ので、その見出しと要点のとおりに、ちょうどそのスライドを書く\n- **R-noids** スライドの id を**書かない**。`<section class=\"slide\">` に `id` を付けず、口述原稿の見出しにも `{#…}` を付けない。id は取り込みでエディタが付ける。id のあるデッキを渡されたとき(修正依頼)は、今ある `id=\"…\"` と `{#…}` をそのまま残す\n\n## 2. deck.html\n\n### 2.1 骨組み\n\n```html\n<!DOCTYPE html>\n<html lang=\"ja\" data-theme=\"default\">\n<head>\n<meta charset=\"utf-8\">\n<meta name=\"viewport\" content=\"width=device-width, initial-scale=1\">\n<title>教材の題名</title>\n</head>\n<body>\n<div id=\"stage\">\n <section class=\"slide cover noconcl static\"> … </section>\n <section class=\"slide\"> … </section>\n</div>\n</body>\n</html>\n```\n\n- `lang`:`ja`・`en` など(教材の言語)。`data-theme`:ビジネス・ピッチは `sumi`、国語は `kokugo`、ほかは `default`\n- `<script>` は部品のデータ(§2.6)だけ。`<style>` は配置(大きさ・間隔)だけに使い、色は書かない\n\n### 2.2 スライド\n\n- 普通のスライド:`<h2>` の見出し、`<div class=\"body\">…</div>`、`<div class=\"concl\"><span>…</span></div>`(結論の行。短い 1 文)\n- 表紙:`<section class=\"slide cover noconcl static\">` に、あれば `<div class=\"venue\">…</div>`、`<h1>題名</h1>`、あれば `<div class=\"au\">…</div>`\n- 章の扉:`<section class=\"slide sec noconcl static\"><h1>章の題</h1></section>`\n- `<section>` の class:`noconcl`(結論の行なし)、`static`(段階なし)、`nostep`(箇条書きも初めから全部)、`layout-tate`(縦書き。kokugo の束があるときだけ)、属性 `data-morph`(§2.5)\n- `.body` の中:`<p class=\"sub\">` 小見出し、`<div class=\"big\">` 主要な式、`<p class=\"note\">` 補足、`<div class=\"thm\">` 定理の枠、`<div class=\"cols\">` 横並び、普通の `<p>` `<ul>` `<ol>` `<table>`\n- 字の強調(色を付ける唯一の方法):`term`(用語・問い)、`emph`(結論・問題・目標)、`muted`(既知の結果・控えめ)、`b`(太字)\n- **R-headings** スライドの見出し(表紙と扉は `h1`、ほかは `h2`)は**すべて違う**ものにする(同じなら語を足す)。そのスライドの口述原稿の節は `## ` に続けて**見出しとまったく同じ文字列**で始める(`<br>` などのタグは除く)\n- **R-colors** 色はテーマだけで:上の class と式のマクロ `\\hlE` `\\hlT` `\\hlM`。16 進・`rgb()`・色の名前・`\\color`・`\\textcolor` は使わない。部品や SVG の中では:**色はテーマの CSS 変数だけ**を使う:`var(--fg)` `var(--term)` `var(--emph)` `var(--muted)` `var(--accent2)` `var(--line)`。SVG では属性ではなく `style=\"stroke:var(--emph)\"` で書く(`DECK.el` は `fill` `stroke` に `var(` があれば自動で style に回す)\n\n### 2.3 段階(出す順 = 話す順)\n\n- **R-steps** 段階 0 は現れたときの姿で、文脈だけ(見出し・小見出し・導入の 1 文)。`data-step=\"k\"`(k = 1, 2, …)の要素は段階 k で現れる。材料(箇条書きの項目・式・表の行・図の部分)は話す順に出す。式とそれを導く 1 文は同じ段階(`<div data-step=\"k\">` で一緒に囲む)。1 枚の段階は 5 前後まで\n- 結論の行は自動で**最後の段階** `concl` になる(`data-step` を付けない)\n- `data-step` が 1 つもないスライドでは、上の階層の箇条書きの項目(`.body > ul > li`・`.body > ol > li`)に 1, 2, … が自動で付く。1 つでもあれば自動にならないので、出すものすべてに付ける\n- 部品は自分の段階を足す(§3)。`data-from`(既定 1)から始まる\n- つまり段階は `0 … max` と、結論の行があれば `concl`。`static` のスライドは段階 0 だけ\n\n### 2.4 数式(KaTeX)\n\n- **R-math** 行内は `\\( … \\)`、別行は `\\[ … \\]`。式の中の `<` は `\\lt`、`>` は `\\gt`。標準のほかに使えるマクロ:`\\hlE{…}`(emph)`\\hlT{…}`(term)`\\hlM{…}`(muted)、`\\htmlId{ID}{…}`、`\\htmlData{mark=ID}{…}`、`\\htmlClass{…}{…}`、`\\morph{ID}{…}`。`\\newcommand` と `\\color` は使わない。記号は最初に使う所で定義する(`\\(\\mu\\)`:母平均)\n\n### 2.5 注目の演出とモーフ\n\n- **R-marks** 口述原稿の `{mark:ID}`(§4)は、**同じスライド**の目印に印を付ける。目印:スライドの中の `id=\"ID\"` か `data-mark=\"ID\"` の要素。式の一部は KaTeX の `\\htmlId{ID}{…}` / `\\htmlData{mark=ID}{…}`(build はこの 2 つと `\\htmlClass` だけを許す)。同じ ID を何枚かで使うなら `data-mark` にする(id は文書の中で一意に)\n- モーフ(なくてよい):`<section class=\"slide\" data-morph>` は前のスライドの要素を今の位置へ滑らせる。両方のスライドの要素に同じ `data-id=\"…\"`、式の一部は両方に `\\morph{ID}{…}`。段階 0 で見えている要素だけが動く\n\n### 2.6 部品\n\n- **R-components** 動く図は一覧(§3)の Web Components `<m-…>` で、`.body` の中に置く。どれにも高さ(`style=\"height:380px\"`)と `aria-label` を付ける。データは子の `<script type=\"application/json\">…</script>` **1 つ**にその場で書く。**図の数字は正しく**(計算する。見た目のために値を作らない。架空の数字は架空と書く)。関数の式は算術の式だけで、コードとしては実行されない(`Math.exp(x)`・`x**2`)。動きが説明になる所だけに使う(たいていのスライドには要らない)\n\n### 2.7 表し方を選ぶ\n\n- **R-purpose** 表し方は習慣でなく、そのスライドで言いたいことから選ぶ。作者がグラフの種類を言っていればそれに従う。表は全パーツの一覧を兼ねる。使うのは渡された文章にあるパーツだけ(§3 と、入っている束)。入っていないパーツの方が合うときは、1 行のメモでそう伝える\n\n{{PURPOSES}}\n\n- **R-whole** 箇条書き・数字の札・円グラフは全体を一度に見せる。台本が 1 つずつ取り上げるときだけ 1 行ずつ出す(箇条書きなら全体に 1 つの `data-step` を付けるか、スライドに `nostep`)\n\n### 2.8 スライドに収める(品質チェックのエラー)\n\n- **R-title** 見出し:日本語は 26 字まで(全角 1・半角 0.5)、英語は 60 文字まで。コロンで終えない\n- **R-concl** 結論の行:日本語は 35 字まで、英語は 70 文字まで。1 行\n- **R-fit** 本文は 565 px(`noconcl` なら 680 px)より上で終える:1 枚におよそ 8 行・100 字・英語 60 語、または `big` の式 1 つと短い箇条書き 3 つ、または高さ 380 px までの部品と短い 1 行(2 行なら 330 px まで)。入らなければスライドを分ける。字を縮めず、字の大きさを書かない。図の中の字は 24 px 以上\n- **R-style** 日本語のスライドは常体(だ・である、体言止め)で、です・ます を使わない。句読点はデッキ全体で 1 つの組(`、。` か `,.`)。英語のスライドは短い句で\n\n## 3. 部品の一覧\n\nどの教材でも使える標準の部品。§6 の後に束の指示があれば、その種類の材料の部品が加わる。「steps」は部品が使うスライドの段階の数(`data-from` から。既定 1)。秒で測る属性(動きの長さ・ずれ)は載せない(既定で口述原稿に合う)。型が json の属性は、値に JSON を書く(`values=\"[0.1,0.5]\"`)。「データの形」の `?` は省略できる欄。型を書いていない label・tex・note・tone は str、step は int、at は num。名前やラベルの `*…*` は斜体、`_` `^` は次の 1 字だけ下付き・上付き。記号のまま出すなら全角の _ ^ *。\n\n{{CATALOG}}\n\n## 4. narration.md\n\n```markdown\n# 口述原稿:<教材の題名>\n\n## 減衰の式\n[0] 減衰の式です。時刻ごとに残っている原子の数を考えます。\n[1] 残る数は、はじめの数に、時間とともに小さくなる指数関数を掛けたものです。\n[2] {mark:n0|circle}{N₀|エヌゼロ} は、時刻ゼロのときの、はじめの数です。\n[concl] 半分になるまでの時間は、崩壊定数だけで決まります。\n```\n\n- スライドごとに 1 つの節を、**スライドの順に、すべてのスライド(表紙も)について**:`## <スライドの見出し>`(R-headings)。`{#id}` は付けない(R-noids)\n- **R-narr-steps** 段階の印は `[0]` `[1]` … と `[concl]`。**どのスライドのどの段階にも口述原稿を書き**(段階 0 から max まで、結論の行があれば `[concl]`)、**ない段階の印は書かない**(`static` の表紙は `[0]` だけ。結論の行がなければ `[concl]` もない。`[01]` とは書かない)。段階の中では、その段階で現れるものだけを話す\n- **R-dialogue** **既定は話者 1 人**で、話者名を書かない。掛け合いは頼まれたときだけ(3 人以上を頼まれても 2 役にし、最初にそう書く):行を `Expert:` か `Novice:` で始め(続きの行は字下げ。話者なしは Expert)、認知的徒弟制の形にする:\n - Novice は相づち役にせず、学習者の疑問を代弁するか、「つまり〜ということですか」と言い換える\n - Expert は答えて具体例か比喩を 1 つ足すか、言い換えを確かめて(違えば直して)1 歩進める\n - 理解の分かれ目(誤解しやすい所、「なぜ」が残る所)にだけ、1 枚に 1 回・2〜3 発言まで。ほかは Expert 1 人\n - 「なるほど」だけの発言、前の発言のくり返しは書かない。例:`Novice: つまり、大きいほど早く着くのですか。` `Expert: いつもではありません。大きすぎると谷を飛び越えます。大股で坂を下りすぎて、向こうの斜面に足が着くように。`\n- `{note:…}` 発表者用\n- `{cue}`:段階の中の同期点。部品の `cues(k)` の 1 つに 1 つ(部品の説明が求めるときだけ)\n- `{mark:ID}`・`{mark:ID|効果}`・`{mark:ID|効果|hold=秒}`・`{mark:clear}`:目印のことを言う言葉の**すぐ前**に置く。1 段階に 1〜2 個まで。言葉でも言う。効果:`underline`(既定。手描きの下線を左から右へ)、`circle`(手描きの囲み)、`box`(角丸の枠)、`spot`(対象のまわり以外を背景色で薄くする)、`laser`(光の点が対象の下へ滑ってきて少し留まる)\n- **R-reading** `{表示|読み}` は **1 つの記号か 1 つの用語**の読み:`{θ|シータ}`、`{N₀|エヌゼロ}`、`{論語|ろんご}`。1 つの記号に星・プライム・添え字・ハットやバーが付いていてもよい(`{Q*|キュースター}`、`{θ̂|シータハット}`)。表示は普通の文字で書き、LaTeX にせず、式やいくつもの記号にしない(`{1-η|…}`・`{θとη|…}` は誤り:記号ごとに読みを付け、関係は言葉で言う)\n- **R-formula** **式を読み上げない**:口述原稿に LaTeX・`\\`・`^`・`_`・`a + b = c` のような文字列を書かない。式の意味を言葉で言う(§4 の見本の [1])\n- 日本語の口述原稿は話し言葉の です・ます。英語は話し言葉の英語。目安は 1 秒に日本語 5 字・英語 2.5 語。1 回の発言は 1〜3 文\n\n## 5. 修正依頼\n\n利用者が**修正依頼**(規格の名前の付いた指摘の一覧と、今のファイル)を貼り付けたら、その指摘だけを直し、ほかは変えず、`id=\"…\"` と `{#…}` をすべてそのまま残し(R-noids)、また 2 つの囲みで返す(R-output)。依頼に一部のスライドしかなければ、そのスライドの `<section>` だけ(`<html>` なし)とその節だけを 2 つの囲みで返す(エディタが id で元の場所に戻す)。\n\n## 6. 見本\n\n小さな教材の見本(架空。形を見るためで、中身は写さない)。段階の数え方:2 項目の箇条書きは段階 1〜2 と `[concl]`<!--part:m-flow-->、箱が 4 つの `m-flow` は段階 1〜4<!--/part-->。いくつかの束の指示の最後にも見本がある。\n\n### 共通(英語・default テーマ・注目の演出<!--part:m-flow-->・m-flow<!--/part-->)\n\n```deck.html\n<!DOCTYPE html>\n<html lang=\"en\" data-theme=\"default\">\n<head>\n<meta charset=\"utf-8\">\n<meta name=\"viewport\" content=\"width=device-width, initial-scale=1\">\n<title>How a web page arrives</title>\n</head>\n<body>\n<div id=\"stage\">\n\n<section class=\"slide cover noconcl static\">\n <div class=\"venue\">Computing basics, lesson 1 (a fictional course)</div>\n <h1>How a web page arrives</h1>\n</section>\n\n<section class=\"slide\">\n <h2>Two programs take part</h2>\n <div class=\"body\">\n <p>Opening a page is a conversation between two programs.</p>\n <ul>\n <li id=\"browser\">The <span class=\"term\">browser</span> asks for the page and draws it</li>\n <li id=\"server\">The <span class=\"term\">server</span> keeps the page and sends it back</li>\n </ul>\n </div>\n <div class=\"concl\"><span>Every page load is a request and a reply</span></div>\n</section><!--part:m-flow-->\n\n<section class=\"slide\">\n <h2>From the address to the screen</h2>\n <div class=\"body\">\n <m-flow style=\"height:300px\" aria-label=\"Four stages: type the address, send a request, send the page back, draw the page\">\n <script type=\"application/json\">{\"nodes\": [\n {\"id\": \"a\", \"label\": \"Type the\\naddress\", \"x\": 10, \"y\": 100, \"w\": 250, \"h\": 110, \"step\": 1},\n {\"id\": \"b\", \"label\": \"Send a\\nrequest\", \"x\": 315, \"y\": 100, \"w\": 250, \"h\": 110, \"step\": 2},\n {\"id\": \"c\", \"label\": \"Send the\\npage back\", \"x\": 620, \"y\": 100, \"w\": 250, \"h\": 110, \"step\": 3, \"tone\": \"term\"},\n {\"id\": \"d\", \"label\": \"Draw the\\npage\", \"x\": 925, \"y\": 100, \"w\": 250, \"h\": 110, \"step\": 4, \"tone\": \"emph\"}\n ], \"edges\": [\n {\"from\": \"a\", \"to\": \"b\"}, {\"from\": \"b\", \"to\": \"c\"}, {\"from\": \"c\", \"to\": \"d\"}\n ]}</script>\n </m-flow>\n </div>\n <div class=\"concl\"><span>A slow page is slow in one of these four stages</span></div>\n</section><!--/part-->\n\n</div>\n</body>\n</html>\n```\n\n```narration.md\n# Narration: How a web page arrives\n\n## How a web page arrives\n[0] Today we follow a web page on its way from a server to your screen.\n\n## Two programs take part\n[0] Opening a page is a conversation between two programs.\n[1] {mark:browser}The browser is the program you look at. It asks for the page and then draws it.\n[2] {mark:server}The server is a program on another computer. It keeps the page and sends it back when asked.\n[concl] Every page load is a request and a reply.<!--part:m-flow-->\n\n## From the address to the screen\n[0] Let us put the steps in order.\n[1] First you type the address of the page.\n[2] The browser turns it into a request and sends it to the server.\n[3] The server finds the page and sends it back.\n[4] The browser draws the page on the screen.\n[concl] When a page is slow, one of these four stages is taking the time.<!--/part-->\n```",
|
|
964
962
|
"request": "# 頼みたいこと\n\n*(A か B を埋め、もう一方は消します。書かない項目は消してかまいません)*\n\n**A. 新しく作る**\n\n- タイトル(表紙にそのまま使う):\n- 対象(だれ向け):\n- 長さ(枚数か分):\n- 言語:\n- 話者:1 人\n- そのほかの希望:\n\n**B. 渡した資料と話し合いの内容で作る**\n\nこのチャットで渡した資料と、ここまでの話し合いの内容で、教材を作ってください。\n\n- タイトル(表紙にそのまま使う):\n- 対象(だれ向け):\n- 長さ(枚数か分):\n- 言語:\n- 話者:1 人\n- そのほかの希望:",
|
|
965
963
|
"sets": {
|
|
966
964
|
"stats": "## 部品の束:stats(統計の図)\n\nデータを見せる教材・発表向け。分布、箱ひげ図、ヒートマップ、観測が 1 つずつ加わって変わる分布を見せる。テーマは `default`。データの出どころと数(何人・何件)をスライドか口述原稿に書き、本物らしく見えるデータを作らない(R-components)。\n\n- **軸のある図**(<!--part:m-hist-->`m-hist`・<!--/part--><!--part:m-boxplot-->`m-boxplot`・<!--/part--><!--part:m-seq-->`m-seq`・<!--/part-->など)は目盛りと軸の名前に左 86 px、上下合わせて 80 px を使うので、高さ **300〜380 px**、幅 **560 px 以上**にする(`<div class=\"cols\">` なら図の列を 55% 以上に)\n- 軸の範囲には、図の値(R-components のとおり計算したもの)がすべて入るようにする\n\nこの束の部品(§3 の部品に加えて):\n\n{{CATALOG}}\n\n{{EXTENSIONS}}",
|
|
@@ -988,7 +986,7 @@ export const PACK = {
|
|
|
988
986
|
"m-cards": {
|
|
989
987
|
"set": "standard",
|
|
990
988
|
"row": "| `<m-cards>` | カード(番号の丸・アイコン・見出し・説明)を横一列か 2 段に並べ、段階ごとに出す。矢印で順を、枠の色で強調を見せる | カードの step の最大(既定はカード 1 枚 = 1 段階。per-step で n 枚ずつ) | `{cards:{n?:str,icon?:str,title:str,text?:str,step?,tone?}[]}` |",
|
|
991
|
-
"entry": "### `<m-cards>`\n\nデータ(子の `<script type=\"application/json\">`)の見本: `{\"cards\":[{\"icon\":\"user\",\"title\":\"聞く\",\"text\":\"相手の困りごとを聞く\"},{\"icon\":\"bulb\",\"title\":\"考える\",\"text\":\"案を 3 つ出す\"},{\"icon\":\"rocket\",\"title\":\"試す\",\"text\":\"小さく作って見せる\"}]}`\n\n| 値 | 型 | 既定 | 意味 |\n|---|---|---|---|\n| `layout` | enum | `\"row\"` | row:横一列。grid:2 段(4 枚までは 2×2、5〜6 枚は 3×2) |\n| `arrows` | bool | `false` | カードの間に順の矢印(grid では 1→2→3→4 の Z の順) |\n| `nums` | bool | `false` | 番号の丸を出す(カードの n が優先。n だけ書いたカードはそれを出す) |\n| `hilite` | string | `\"\"` | 強調するカード:last か番号(1 から)。--emph の枠と地 |\n| `per-step` | number | `1` | 1 段階に出すカードの数(0 = 全部を段階 1 で) |\n\n
|
|
989
|
+
"entry": "### `<m-cards>`\n\nデータ(子の `<script type=\"application/json\">`)の見本: `{\"cards\":[{\"icon\":\"user\",\"title\":\"聞く\",\"text\":\"相手の困りごとを聞く\"},{\"icon\":\"bulb\",\"title\":\"考える\",\"text\":\"案を 3 つ出す\"},{\"icon\":\"rocket\",\"title\":\"試す\",\"text\":\"小さく作って見せる\"}]}`\n\n| 値 | 型 | 既定 | 意味 |\n|---|---|---|---|\n| `layout` | enum | `\"row\"` | row:横一列。grid:2 段(4 枚までは 2×2、5〜6 枚は 3×2) |\n| `arrows` | bool | `false` | カードの間に順の矢印(grid では 1→2→3→4 の Z の順) |\n| `nums` | bool | `false` | 番号の丸を出す(カードの n が優先。n だけ書いたカードはそれを出す) |\n| `hilite` | string | `\"\"` | 強調するカード:last か番号(1 から)。--emph の枠と地 |\n| `per-step` | number | `1` | 1 段階に出すカードの数(0 = 全部を段階 1 で) |\n\n同じ重さの短い要点が 3〜4 個なら、箇条書きよりカード(アイコン付き)を検討する。事例の 2×2 にも。短い手順は arrows で順を示す。長い文や重さの違う項目は箇条書きのまま。\n\n子の JSON の並び:2〜6 枚。\n\n- `title`:見出し(必須。2 行まで)。`text`:説明(入るだけ折り返す。入らなければ … で切って知らせる)\n- `icon`:アイコンの名前(Tabler Icons の線の形。下の一覧から。ほかの名前も使えるが、ない名前は点線の四角になって知らせる)\n- `n`:番号の丸に出す字(`\"A\"` `\"1\"` など)。`nums` を付けると n のないカードに 1, 2, 3 … を出す\n- `tone`:番号の丸とアイコンの色(`term`(既定)・`emph`・`accent2`・`series-1..4`)\n- `layout=\"grid\"`:2 段(4 枚までは 2×2、5〜6 枚は 3×2)。横に広いカードは 番号・アイコン・見出しを 1 行に並べる\n- `arrows`:カードの間に順の矢印(grid では 1→2→3→4 の Z の順)。`hilite=\"last\"` か `hilite=\"3\"`:そのカードを `--emph` の枠と地で強調\n- 見せ方(`variant`):`rise`・`fade`・`draw`。書かなければ資料のシード値で選ばれる(書かなくてよい)\n\nアイコンの名前(よく使うもの):\n\n- 人:user users user-check user-plus user-circle friends mood-smile man woman id-badge\n- データ:chart-bar chart-line chart-pie chart-dots trending-up trending-down table database filter adjustments percentage sum\n- お金:coin cash credit-card wallet receipt pig-money building-bank report-money shopping-cart tag\n- 時間:clock calendar calendar-event calendar-time hourglass history alarm stopwatch\n- 場所:map-pin map world home building building-factory building-store route truck\n- 進め方:arrow-right arrows-right-left refresh repeat circle-check checklist list-numbers git-branch target flag rocket hand-click\n- 伝える:message messages mail phone bell speakerphone share world-www microphone presentation\n- 書類:file file-text files notebook book clipboard-list folder news certificate award\n- 道具:tool settings hammer bulb puzzle cpu device-laptop device-mobile robot code scale\n- 自然:leaf tree plant sun moon cloud cloud-rain droplet flame snowflake\n- 安全:shield shield-check lock key alert-triangle first-aid-kit heart heart-rate-monitor eye\n- 学び:school pencil ruler math-function atom flask microscope palette music language"
|
|
992
990
|
},
|
|
993
991
|
"m-compare": {
|
|
994
992
|
"set": "standard",
|
|
@@ -1169,9 +1167,9 @@ export const PACK = {
|
|
|
1169
1167
|
"briefNote": "下に説明の節がない部品は、表の「データの形」のとおりに子の JSON か属性を書き、ほかの属性は既定のままにする。",
|
|
1170
1168
|
"extHead": "### `<{name}>`:この束の拡張(部品の説明は §3)"
|
|
1171
1169
|
},
|
|
1172
|
-
"version": "
|
|
1170
|
+
"version": "69c736a1",
|
|
1173
1171
|
"tiers": {
|
|
1174
|
-
"catalogue": "2.
|
|
1172
|
+
"catalogue": "2.5.0",
|
|
1175
1173
|
"parts": {
|
|
1176
1174
|
"m-bars": {
|
|
1177
1175
|
"tier": "standard",
|