@vibes.diy/prompts 14.3.244 → 14.3.246
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/generation-variety.d.ts +10 -0
- package/generation-variety.js +32 -3
- package/generation-variety.js.map +1 -1
- package/llms/callai.md +48 -1
- package/llms/reskin.md +10 -0
- package/llms/stripe.js +5 -1
- package/llms/stripe.js.map +1 -1
- package/llms/stripe.md +14 -1
- package/llms/web-audio.md +286 -163
- package/package.json +5 -5
- package/prompts.js +10 -1
- package/prompts.js.map +1 -1
- package/settings.d.ts +1 -0
- package/system-prompt-initial-oneshot.md +2 -2
- package/system-prompt-initial.md +1 -1
- package/system-prompt.md +1 -1
package/generation-variety.d.ts
CHANGED
|
@@ -54,3 +54,13 @@ export declare function renderLookPackageSection(look: {
|
|
|
54
54
|
} | undefined): string;
|
|
55
55
|
export declare function renderReskinDoseSection(dose: "light" | "full" | undefined): string;
|
|
56
56
|
export declare function renderTextureNoteSection(note: string | undefined): string;
|
|
57
|
+
export declare const INSTRUMENT_ARRANGEMENTS: readonly ["rows", "pad grid", "vertical rack"];
|
|
58
|
+
export type InstrumentArrangement = (typeof INSTRUMENT_ARRANGEMENTS)[number];
|
|
59
|
+
export declare function drawInstrumentArrangement(seed: string): InstrumentArrangement;
|
|
60
|
+
export declare function askNamesInstrumentLayout(text: string): boolean;
|
|
61
|
+
export declare function askIsBeatApp(text: string): boolean;
|
|
62
|
+
export declare function instrumentArrangementForTurn(args: {
|
|
63
|
+
readonly chatId: string;
|
|
64
|
+
readonly personWords: string;
|
|
65
|
+
}): InstrumentArrangement | undefined;
|
|
66
|
+
export declare function renderInstrumentArrangementSection(arrangement: InstrumentArrangement | undefined): string;
|
package/generation-variety.js
CHANGED
|
@@ -183,7 +183,7 @@ export function renderLookPackageSection(look) {
|
|
|
183
183
|
"",
|
|
184
184
|
`This app is served in the ${look.label} look. ${look.brief}`,
|
|
185
185
|
"",
|
|
186
|
-
"Write the app exactly as the brief above says, importing from `@vibes.diy/ui`: the served stylesheet draws those same components in this look, so never import a look's own package, restyle a component, or redraw a control by hand to get it. What is yours is the voice: write the title, headings, labels, empty states and sample data in a tone that suits this look.",
|
|
186
|
+
"Write the app exactly as the brief above says, importing from `@vibes.diy/ui`: the served stylesheet draws those same components in this look, so never import a look's own package, restyle a component, or redraw a control by hand to get it. An instrument face a skill teaches (`data-instrument`) is the one place you paint kit pads and draw knobs, from this look's tokens, as that skill shows. What is yours is the voice: write the title, headings, labels, empty states and sample data in a tone that suits this look.",
|
|
187
187
|
].join("\n");
|
|
188
188
|
}
|
|
189
189
|
export function renderReskinDoseSection(dose) {
|
|
@@ -193,13 +193,13 @@ export function renderReskinDoseSection(dose) {
|
|
|
193
193
|
return [
|
|
194
194
|
"## Reskin — light",
|
|
195
195
|
"",
|
|
196
|
-
"Give this app a light skin with the reskin skill: one `data-reskin` wrapper whose `<style>` loads a display web font for the headings and adds ONE signature touch that suits the app's subject (a texture, a border or rule treatment, a sticker or stamp, a capture-safe marquee). Leave everything else as the look serves it: the palette, the components, the spacing and the controls. Pick the font and the touch from what the app is about, so it reads as this app's own.",
|
|
196
|
+
"Give this app a light skin with the reskin skill: one `data-reskin` wrapper whose `<style>` loads a display web font for the headings and adds ONE signature touch that suits the app's subject (a texture, a border or rule treatment, a sticker or stamp, a capture-safe marquee). Leave everything else as the look serves it: the palette, the components, the spacing and the controls. Pick the font and the touch from what the app is about, so it reads as this app's own. An instrument face a skill teaches (`data-instrument`) stays its own panel: the skin dresses the page around it, and the face keeps its knobs, pads and token-painted colours.",
|
|
197
197
|
].join("\n");
|
|
198
198
|
}
|
|
199
199
|
return [
|
|
200
200
|
"## Reskin — full",
|
|
201
201
|
"",
|
|
202
|
-
"Dress this whole app in an appearance with the reskin skill, even though the person did not name one. Choose one named style that suits the app's subject and the look it is served in, say which in a line of your reply, and carry it through: fonts, borders, corners, texture, motion and a recomposed layout, all on the look's own components and tokens.",
|
|
202
|
+
"Dress this whole app in an appearance with the reskin skill, even though the person did not name one. Choose one named style that suits the app's subject and the look it is served in, say which in a line of your reply, and carry it through: fonts, borders, corners, texture, motion and a recomposed layout, all on the look's own components and tokens. An instrument face a skill teaches (`data-instrument`) stays its own panel: the skin dresses the page around it, and the face keeps its knobs, pads and token-painted colours.",
|
|
203
203
|
].join("\n");
|
|
204
204
|
}
|
|
205
205
|
export function renderTextureNoteSection(note) {
|
|
@@ -214,4 +214,33 @@ export function renderTextureNoteSection(note) {
|
|
|
214
214
|
"This is an emphasis note about what the user already asked for: it decides what dominates and what recedes, nothing more. Do NOT add a feature, screen, or field to satisfy it — if it names something the app doesn't have, express the emphasis with what the app does have. Express the weight through scale, position, order and prominence within the layout archetype above; never by writing a literal colour, size, shadow or font stack, which the owner could then never restyle.",
|
|
215
215
|
].join("\n");
|
|
216
216
|
}
|
|
217
|
+
export const INSTRUMENT_ARRANGEMENTS = ["rows", "pad grid", "vertical rack"];
|
|
218
|
+
export function drawInstrumentArrangement(seed) {
|
|
219
|
+
let h = 0x811c9dc5;
|
|
220
|
+
for (let i = 0; i < seed.length; i++) {
|
|
221
|
+
h ^= seed.charCodeAt(i);
|
|
222
|
+
h = Math.imul(h, 0x01000193) >>> 0;
|
|
223
|
+
}
|
|
224
|
+
return INSTRUMENT_ARRANGEMENTS[h % INSTRUMENT_ARRANGEMENTS.length];
|
|
225
|
+
}
|
|
226
|
+
export function askNamesInstrumentLayout(text) {
|
|
227
|
+
return /\b(mpc|808|909|707|groovebox|rack|rack-?mount|pads?|finger.?drum\w*|launchpad|rows?|grid|columns?)\b/i.test(text);
|
|
228
|
+
}
|
|
229
|
+
export function askIsBeatApp(text) {
|
|
230
|
+
return /\b(drums?|drum.?machines?|drum.?kits?|beat.?makers?|beat.?machines?|beat.?pads?|(?:step.?)?sequencers?|grooveboxe?s?|mpc|808|909|707|finger.?drum\w*)\b/i.test(text);
|
|
231
|
+
}
|
|
232
|
+
export function instrumentArrangementForTurn(args) {
|
|
233
|
+
if (askNamesInstrumentLayout(args.personWords))
|
|
234
|
+
return undefined;
|
|
235
|
+
return drawInstrumentArrangement(args.chatId);
|
|
236
|
+
}
|
|
237
|
+
export function renderInstrumentArrangementSection(arrangement) {
|
|
238
|
+
if (arrangement === undefined)
|
|
239
|
+
return "";
|
|
240
|
+
return [
|
|
241
|
+
"## Instrument arrangement",
|
|
242
|
+
"",
|
|
243
|
+
`Lay out this app's instrument face as a ${arrangement} (web-audio, "Make it yours") and name it in the picks line, unless the person's own words name a machine or a layout, which then decide.`,
|
|
244
|
+
].join("\n");
|
|
245
|
+
}
|
|
217
246
|
//# sourceMappingURL=generation-variety.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"generation-variety.js","sourceRoot":"","sources":["../jsr/generation-variety.ts"],"names":[],"mappings":"AA6EA,MAAM,CAAC,MAAM,iBAAiB,GAA+B;IAC3D;QACE,EAAE,EAAE,oBAAoB;QACxB,QAAQ,EACN,6RAA6R;KAChS;IACD;QACE,EAAE,EAAE,WAAW;QACf,QAAQ,EACN,4PAA4P;KAC/P;IACD;QACE,EAAE,EAAE,kBAAkB;QACtB,QAAQ,EACN,uPAAuP;KAC1P;IACD;QACE,EAAE,EAAE,mBAAmB;QACvB,QAAQ,EACN,yRAAyR;KAC5R;IACD;QACE,EAAE,EAAE,WAAW;QACf,QAAQ,EACN,+PAA+P;KAClQ;CACF,CAAC;AAuBF,MAAM,CAAC,MAAM,UAAU,GAAwB;IAC7C;QACE,EAAE,EAAE,YAAY;QAChB,QAAQ,EACN,yXAAyX;KAC5X;IACD;QACE,EAAE,EAAE,YAAY;QAChB,QAAQ,EACN,wSAAwS;KAC3S;IACD;QACE,EAAE,EAAE,aAAa;QACjB,QAAQ,EACN,mSAAmS;KACtS;IACD;QACE,EAAE,EAAE,YAAY;QAChB,QAAQ,EACN,mgBAAmgB;KACtgB;IACD;QACE,EAAE,EAAE,eAAe;QACnB,QAAQ,EACN,q7BAAq7B;KACx7B;IACD;QACE,EAAE,EAAE,aAAa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C;IACrC,CAAC;IACD,OAAO,uBAAuB,CAAC,CAAC,GAAG,uBAAuB,CAAC,MAAM,CAAC,CAAC;AACrE,CAAC;AAGD,MAAM,UAAU,wBAAwB,CAAC,IAAY;IACnD,OAAO,uGAAuG,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;AAC5H,CAAC;AAOD,MAAM,UAAU,YAAY,CAAC,IAAY;IACvC,OAAO,0JAA0J,CAAC,IAAI,CACpK,IAAI,CACL,CAAC;AACJ,CAAC;AAOD,MAAM,UAAU,4BAA4B,CAAC,IAG5C;IACC,IAAI,wBAAwB,CAAC,IAAI,CAAC,WAAW,CAAC;QAAE,OAAO,SAAS,CAAC;IACjE,OAAO,yBAAyB,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;AAChD,CAAC;AAMD,MAAM,UAAU,kCAAkC,CAAC,WAA8C;IAC/F,IAAI,WAAW,KAAK,SAAS;QAAE,OAAO,EAAE,CAAC;IACzC,OAAO;QACL,2BAA2B;QAC3B,EAAE;QACF,2CAA2C,WAAW,2IAA2I;KAClM,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;AACf,CAAC"}
|
package/llms/callai.md
CHANGED
|
@@ -229,7 +229,7 @@ async function askRecords(question) {
|
|
|
229
229
|
|
|
230
230
|
## Fill a form with a suggestion
|
|
231
231
|
|
|
232
|
-
Every form in the app carries one sparkle button that fills its fields with a suggestion from callAI, so the person can save without typing. Write it in the same pass as the form it belongs to: the fields, the submit and the sparkle land together, so the first version of the app already carries every form's sparkle. It is a quiet `IconButton` with `icon={<Icon name="sparkle" size="sm" />}` and a label in the app's own words ("Suggest an offer"), placed beside the form's submit action, one per form: the Add form, the edit view of a saved record and the sentence composer each carry their own. The press asks callAI for one plausible, specific example through the form's own schema (the same editable fields the form saves) and writes the normalized answer into the form's field state; the sparkle fills and the submit action saves. The person reads the suggestion, changes anything, and presses the form's own save; while a suggestion or a save is in flight the fields, the submit and the sparkle wait together, so a suggestion never lands over fresh typing or under a clear. A one-field form carries its sparkle too, and so does an app with no other use for callAI: a form that asks only for a name, a title or a label saves that value directly with no extraction, and it is still one press away from a specific suggested name, through a one-field schema and the same normalizer the form saves through. A suggestion is sized to its field: the prompt names the length the field expects (a name of two to four words, a note of one or two sentences, a number in the field's range), and the normalizer keeps it there, so a short box never fills with a paragraph. For a sentence composer the suggestion is one example sentence written into the box, which the Add action then extracts like typed words. Ask for variety so each press suggests something new, and reuse the form's schema and normalizer rather than writing a second pair for suggestions.
|
|
232
|
+
Every form in the app carries one sparkle button that fills its fields with a suggestion from callAI, so the person can save without typing. The one form without it holds where money goes — a payment handle, a $Cashtag, a Zelle or Venmo name, a bank or account number, a payout email: the owner types those, the fields start empty, and nothing suggests them, because an invented handle sends a real buyer's money to a stranger. Write it in the same pass as the form it belongs to: the fields, the submit and the sparkle land together, so the first version of the app already carries every form's sparkle. It is a quiet `IconButton` with `icon={<Icon name="sparkle" size="sm" />}` and a label in the app's own words ("Suggest an offer"), placed beside the form's submit action, one per form: the Add form, the edit view of a saved record and the sentence composer each carry their own. The press asks callAI for one plausible, specific example through the form's own schema (the same editable fields the form saves) and writes the normalized answer into the form's field state; the sparkle fills and the submit action saves. The person reads the suggestion, changes anything, and presses the form's own save; while a suggestion or a save is in flight the fields, the submit and the sparkle wait together, so a suggestion never lands over fresh typing or under a clear. A one-field form carries its sparkle too, and so does an app with no other use for callAI: a form that asks only for a name, a title or a label saves that value directly with no extraction, and it is still one press away from a specific suggested name, through a one-field schema and the same normalizer the form saves through. A suggestion is sized to its field: the prompt names the length the field expects (a name of two to four words, a note of one or two sentences, a number in the field's range), and the normalizer keeps it there, so a short box never fills with a paragraph. For a sentence composer the suggestion is one example sentence written into the box, which the Add action then extracts like typed words. Ask for variety so each press suggests something new, and reuse the form's schema and normalizer rather than writing a second pair for suggestions.
|
|
233
233
|
|
|
234
234
|
### `App.jsx`
|
|
235
235
|
```jsx
|
|
@@ -438,6 +438,53 @@ export default function App() {
|
|
|
438
438
|
|
|
439
439
|
For pictures, the image-gen skill's "Choosing a Model" section shows one `<ImgGen>` per image model, side by side.
|
|
440
440
|
|
|
441
|
+
## Signed-in visitors use the AI
|
|
442
|
+
|
|
443
|
+
An app's AI answers people who are signed in. A visitor who opens a shared app without signing in can read, browse and use every control that doesn't call AI; when they press one that does, the platform offers them sign-in right then, and the call rejects with an error whose `reason` is `"sign-in"` and whose message reads "Sign in to use AI in this app." When `error.reason === "sign-in"`, keep what the person typed and show one short line in the app's own words with a Sign in button wired to `useViewer().requestLogin()`; the same press works once they are signed in. Signing in can take the person to another page and back, so the box keeps their words in a draft the app saves to `localStorage` the moment they press, before calling AI, and reads back when it mounts: they return to their question waiting in the box, one press from the answer, and the draft clears once the answer arrives. Treat it as an invitation, never a failure: no error tone, no retry loop, and the rest of the app stays open.
|
|
444
|
+
|
|
445
|
+
```jsx
|
|
446
|
+
import { callAI } from "call-ai";
|
|
447
|
+
import { useViewer } from "use-vibes";
|
|
448
|
+
|
|
449
|
+
// The question's draft lives in this app's own storage, so it is still in the box after sign-in.
|
|
450
|
+
const DRAFT_KEY = "ask-draft";
|
|
451
|
+
function readDraft() {
|
|
452
|
+
try { return localStorage.getItem(DRAFT_KEY) ?? ""; } catch { return ""; }
|
|
453
|
+
}
|
|
454
|
+
function saveDraft(text) {
|
|
455
|
+
try { text ? localStorage.setItem(DRAFT_KEY, text) : localStorage.removeItem(DRAFT_KEY); } catch { /* the box still holds it */ }
|
|
456
|
+
}
|
|
457
|
+
|
|
458
|
+
function AskBox({ records }) {
|
|
459
|
+
const { requestLogin } = useViewer();
|
|
460
|
+
const [question, setQuestion] = React.useState(readDraft);
|
|
461
|
+
const [answer, setAnswer] = React.useState("");
|
|
462
|
+
const [signIn, setSignIn] = React.useState(false);
|
|
463
|
+
const [message, setMessage] = React.useState("");
|
|
464
|
+
async function ask() {
|
|
465
|
+
setSignIn(false); setMessage("");
|
|
466
|
+
// Saved before the call: the press may open sign-in on another page.
|
|
467
|
+
saveDraft(question);
|
|
468
|
+
try {
|
|
469
|
+
const response = await callAI(`Answer from these records: ${JSON.stringify(records)}. Question: ${question}`, {
|
|
470
|
+
schema: { properties: { answer: { type: "string" } } },
|
|
471
|
+
});
|
|
472
|
+
setAnswer(JSON.parse(response).answer);
|
|
473
|
+
saveDraft("");
|
|
474
|
+
} catch (error) {
|
|
475
|
+
// The question waits in the box and in its draft, ready for the same press after sign-in.
|
|
476
|
+
if (error.reason === "sign-in") setSignIn(true);
|
|
477
|
+
else setMessage(error.message);
|
|
478
|
+
}
|
|
479
|
+
}
|
|
480
|
+
return <Stack gap={2}>
|
|
481
|
+
<Row gap={2}><Input value={question} onChange={setQuestion} /><Button onClick={ask}>Ask</Button></Row>
|
|
482
|
+
{signIn && <Row gap={2} align="center" wrap><Text muted>Sign in to ask about these notes.</Text><Button size="sm" variant="quiet" onClick={requestLogin}>Sign in</Button></Row>}
|
|
483
|
+
<Text muted>{answer || message}</Text>
|
|
484
|
+
</Stack>;
|
|
485
|
+
}
|
|
486
|
+
```
|
|
487
|
+
|
|
441
488
|
## Error Handling
|
|
442
489
|
|
|
443
490
|
```javascript
|
package/llms/reskin.md
CHANGED
|
@@ -67,6 +67,16 @@ or a flicker starts from its visible state.
|
|
|
67
67
|
`Stack`, `Row` and `Grid` and their props, or with a plain wrapping `div`: a
|
|
68
68
|
centred narrow column, a two-pane window, a masthead over a three-column grid.
|
|
69
69
|
|
|
70
|
+
**An instrument keeps its face.** When the app has a `data-instrument` panel, or
|
|
71
|
+
is a first build whose skill teaches one
|
|
72
|
+
(a drum machine, a synth, a groovebox), the panel stays its own
|
|
73
|
+
`data-instrument` section with its own sheet, and the skin restyles it through
|
|
74
|
+
its picks: pad shape, panel material, LED colour role, transport layout,
|
|
75
|
+
beat-group colours, font. The face's colours stay `color-mix`es of the look's
|
|
76
|
+
tokens, and the skin adds no instrument-only colour token to the wrapper: the
|
|
77
|
+
face reads the shared look tokens that step 1 re-scopes, so the Look tab and
|
|
78
|
+
the look picker still repaint the machine after the skin lands.
|
|
79
|
+
|
|
70
80
|
The Look tab keeps working: the owner's palette picks still land on the tokens
|
|
71
81
|
the skin did not set, and every component, prop and record is untouched, so a
|
|
72
82
|
later build changes the app the ordinary way.
|
package/llms/stripe.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
export const stripeConfig = {
|
|
2
2
|
name: "stripe",
|
|
3
3
|
label: "Stripe payments",
|
|
4
|
-
description: "Taking real money through Stripe Checkout: load it whenever the person asks for money to move — pay the bill, split the check, a restaurant check, pay at the table or at the counter, a tip or a tip jar, donate or a donation page, sell tickets, sell products buyers pay for, buy now or purchase online, a charge, a deposit, dues, a checkout, a client paying an invoice online (pay an invoice, bill a client), pay with Stripe,
|
|
4
|
+
description: "Taking real money through Stripe Checkout: load it whenever the person asks for money to move — pay the bill, split the check, a restaurant check, pay at the table or at the counter, a tip or a tip jar, donate or a donation page, sell tickets, sell products buyers pay for, buy now or purchase online, a charge, a deposit, dues, a checkout, a client paying an invoice online (pay an invoice, bill a client), pay with Stripe, the word Stripe, or a named payment app buyers pay through (Apple Pay, Cash App, Zelle, Venmo, Chime: card, Apple Pay and Cash App Pay ride Checkout, and a P2P app the person keeps is a manual lane beside it whose handle the owner types) — one-time charges into the owner's own Stripe account through ctx.stripe, connected once with Connect Stripe (a monthly or yearly subscription is the stripe-subscriptions skill): what is for sale and its price is the owner's product catalog, product records in the app's database that only the owner writes (access.js) from the app's own Products screen, starting empty with the owner's first product, and backend.js charges the price it reads from the product the buyer names, never an amount from the browser or a constant in backend.js; guest checkout by default for paying a venue (a check, a tip, a donation, an invoice paid by link with a pay-by date and an overdue state — no sign-in, the payment keyed to the thing paid and its session, written by backend.js for the guest) and a signed-in order where the record is the buyer's to keep (dues on a roster, my orders), one payer paying the whole check by default with splitting as a second choice and the balance reserved with a revision-checked write before any session opens, the Connect Stripe setup item read from ctx.stripe.status(), test mode first with the order's mode passed on every call and live once the owner takes this app live, every Stripe call in backend.js with no Stripe.js in the page, one pending order then one Checkout Session opened in a new tab, an order marked paid only after the backend reads the session back from Stripe and matches it to the order, integer amounts in cents, and a scheduled sweep that settles orders whose buyer never came back. A storefront, plans page, booking page or invoice maker that only records orders or marks invoices paid by hand takes no payment and does not need this; offer it as the [pay] option instead",
|
|
5
5
|
cues: [
|
|
6
6
|
"stripe",
|
|
7
7
|
"take payments",
|
|
@@ -30,6 +30,10 @@ export const stripeConfig = {
|
|
|
30
30
|
"donation",
|
|
31
31
|
"donations",
|
|
32
32
|
"pay with stripe",
|
|
33
|
+
"apple pay",
|
|
34
|
+
"cash app",
|
|
35
|
+
"zelle",
|
|
36
|
+
"venmo",
|
|
33
37
|
"pay an invoice",
|
|
34
38
|
"pay the invoice",
|
|
35
39
|
"pay invoices",
|
package/llms/stripe.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"stripe.js","sourceRoot":"","sources":["../../jsr/llms/stripe.ts"],"names":[],"mappings":"AAWA,MAAM,CAAC,MAAM,YAAY,GAAc;IACrC,IAAI,EAAE,QAAQ;IACd,KAAK,EAAE,iBAAiB;IACxB,WAAW,EACT,
|
|
1
|
+
{"version":3,"file":"stripe.js","sourceRoot":"","sources":["../../jsr/llms/stripe.ts"],"names":[],"mappings":"AAWA,MAAM,CAAC,MAAM,YAAY,GAAc;IACrC,IAAI,EAAE,QAAQ;IACd,KAAK,EAAE,iBAAiB;IACxB,WAAW,EACT,m1EAAm1E;IACr1E,IAAI,EAAE;QACJ,QAAQ;QACR,eAAe;QACf,cAAc;QACd,iBAAiB;QACjB,eAAe;QACf,cAAc;QACd,aAAa;QACb,UAAU;QACV,SAAS;QACT,MAAM;QACN,cAAc;QACd,SAAS;QACT,YAAY;QACZ,iBAAiB;QACjB,iBAAiB;QACjB,QAAQ;QACR,SAAS;QACT,cAAc;QACd,iBAAiB;QACjB,kBAAkB;QAClB,kBAAkB;QAClB,oBAAoB;QACpB,SAAS;QACT,QAAQ;QACR,UAAU;QACV,WAAW;QACX,iBAAiB;QAIjB,WAAW;QACX,UAAU;QACV,OAAO;QACP,OAAO;QAGP,gBAAgB;QAChB,iBAAiB;QACjB,cAAc;QACd,mBAAmB;QACnB,gBAAgB;QAChB,iBAAiB;QACjB,kBAAkB;QAClB,eAAe;QACf,cAAc;QACd,iBAAiB;KAClB;IAKD,SAAS,EAAE;QACT,aAAa;QACb,gBAAgB;QAChB,YAAY;QACZ,cAAc;QACd,iBAAiB;QACjB,gBAAgB;QAChB,aAAa;QACb,cAAc;QACd,eAAe;QACf,cAAc;QACd,eAAe;QACf,eAAe;QACf,iBAAiB;KAClB;IAGD,aAAa,EAAE,CAAC,WAAW,EAAE,cAAc,EAAE,eAAe,EAAE,SAAS,EAAE,WAAW,EAAE,SAAS,CAAC;CACjG,CAAC"}
|
package/llms/stripe.md
CHANGED
|
@@ -19,13 +19,26 @@ closing row's capability option is `▸ [pay] Take card payments with Stripe`,
|
|
|
19
19
|
gold when nothing else fits better, and a tap on it is the ask. Words that are
|
|
20
20
|
the ask: "charge", "pay", "paid", "payment", "pay the bill", "split the check",
|
|
21
21
|
"tip", "donate", "deposit", "dues", "tickets", "sell", "buy now", "purchase online",
|
|
22
|
-
"checkout", "pay an invoice", "pay the invoice online", "bill a client", "Stripe"
|
|
22
|
+
"checkout", "pay an invoice", "pay the invoice online", "bill a client", "Stripe",
|
|
23
|
+
and a named payment app — "Apple Pay", "Cash App", "Zelle", "Venmo", "Chime".
|
|
23
24
|
Words that are not: "orders",
|
|
24
25
|
"price", "plans", "cart" — those describe records, not money moving. "Invoice"
|
|
25
26
|
on its own is not the ask either: an invoice maker where the owner writes
|
|
26
27
|
invoices and marks them paid by hand is bookkeeping, and stays that way until
|
|
27
28
|
the person asks for the client to pay through the app.
|
|
28
29
|
|
|
30
|
+
**Named payment apps are the ask too.** A person who names how buyers should
|
|
31
|
+
pay — Apple Pay, Google Pay, Cash App, Zelle, Venmo, Chime — is asking to take
|
|
32
|
+
money, and this skill answers it. Card, Apple Pay, Google Pay and Cash App Pay
|
|
33
|
+
all ride one Checkout Session and mark the order paid on their own, so Checkout
|
|
34
|
+
is the primary button and the reply says so in one line: "Card, Apple Pay and
|
|
35
|
+
Cash App Pay go through Stripe, which marks the pass paid by itself." Zelle,
|
|
36
|
+
Venmo and Chime have no checkout; when the person keeps one, it is a manual
|
|
37
|
+
lane beside Checkout, never in place of it: the owner types their own handle
|
|
38
|
+
on the Setup screen into an empty field with no sparkle and no example handle
|
|
39
|
+
(an invented handle sends a real buyer's money to a stranger), the buyer taps
|
|
40
|
+
**I sent it**, and the order waits for the owner's Approve.
|
|
41
|
+
|
|
29
42
|
**One-time charges only.** This recipe takes a payment and records that it
|
|
30
43
|
happened. It does not mirror a Stripe subscription — cancellation, a failed
|
|
31
44
|
renewal, an expiry — so a "subscription" or "paid tier" built on a permanently
|
package/llms/web-audio.md
CHANGED
|
@@ -415,11 +415,19 @@ The Play button names what it plays ("Play the drums"), the Stop button is besid
|
|
|
415
415
|
|
|
416
416
|
## 9) A complete drum machine — the shell every beat vibe starts from
|
|
417
417
|
|
|
418
|
-
|
|
418
|
+
Build the first version of any beat app (a drum machine, beat maker, step
|
|
419
|
+
sequencer or groovebox) from this section: the engine as written, and an
|
|
420
|
+
instrument face whose picks you choose (§ "Make it yours" below). The
|
|
421
|
+
`data-instrument` panel is how a drum machine looks from its very first build,
|
|
422
|
+
under any look, layout or skin the turn also carries. The `App.jsx` below
|
|
423
|
+
holds the parts every arrangement shares, followed by three short arrangement
|
|
424
|
+
sketches: pick one and write the app around it.
|
|
425
|
+
|
|
426
|
+
This is a two-file kit: a synthesized four-voice kit (kick,
|
|
419
427
|
snare, closed and open hat), a sixteen-step sequencer, tempo and swing, and
|
|
420
428
|
global saturation and volume on the master bus. No samples, no downloads —
|
|
421
429
|
every sound is built from oscillators and noise, so it plays the moment the
|
|
422
|
-
person taps. Start here for any drum machine, beat maker or groovebox and grow
|
|
430
|
+
person taps. Start here for any drum machine, beat maker, step sequencer or groovebox and grow
|
|
423
431
|
it: more voices, more steps, accents, pattern banks.
|
|
424
432
|
|
|
425
433
|
Why it sounds good, in four moves:
|
|
@@ -699,18 +707,17 @@ function noiseBuffer(ctx) {
|
|
|
699
707
|
```
|
|
700
708
|
|
|
701
709
|
A tap on a step toggles it, and while stopped it plays that sound so the
|
|
702
|
-
person hears what they placed. Every
|
|
710
|
+
person hears what they placed. Every knob writes through to the engine, and
|
|
703
711
|
the scheduler reads the settings on its next step, so edits land in time
|
|
704
712
|
without a restart. Grooves save to the database as one document each; the
|
|
705
713
|
save button waits on `can.create`, the same verdict the server enforces.
|
|
706
714
|
|
|
707
715
|
### `App.jsx`
|
|
708
716
|
```jsx
|
|
717
|
+
// The parts every arrangement shares. `App` composes them with one of the three arrangements below.
|
|
709
718
|
import React, { useEffect, useRef, useState } from "react";
|
|
710
|
-
import {
|
|
711
|
-
import {
|
|
712
|
-
import { Badge, Button, Card, Field, Heading, Input, Row, Skeleton, Spacer, Stack, Text } from "@vibes.diy/ui";
|
|
713
|
-
import { Slider, StepGrid } from "@vibes.diy/ui/interactive";
|
|
719
|
+
import { Button, Row, Spacer, Stack } from "@vibes.diy/ui";
|
|
720
|
+
import { StepGrid } from "@vibes.diy/ui/interactive";
|
|
714
721
|
import { STEPS, TRACKS, getDrums } from "./lib/drum-engine.js";
|
|
715
722
|
|
|
716
723
|
const START = {
|
|
@@ -720,28 +727,97 @@ const START = {
|
|
|
720
727
|
open: [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0],
|
|
721
728
|
};
|
|
722
729
|
|
|
723
|
-
|
|
724
|
-
|
|
730
|
+
const FACE = `
|
|
731
|
+
/* picks: arrangement = … · pad = … · panel = … · led = … · transport = … (name yours; this sheet's defaults are square key, brushed, --info) */
|
|
732
|
+
[data-instrument] {
|
|
733
|
+
--panel: color-mix(in oklab, var(--surface) 80%, var(--ink));
|
|
734
|
+
--well: color-mix(in oklab, var(--surface) 75%, var(--ink));
|
|
735
|
+
--screen: color-mix(in oklab, var(--surface) 88%, var(--ink));
|
|
736
|
+
--led: var(--info);
|
|
737
|
+
--pad-off: color-mix(in oklab, var(--surface) 90%, var(--ink));
|
|
738
|
+
position: relative; display: grid; gap: var(--s3); padding: var(--s5) var(--s3) var(--s3);
|
|
739
|
+
border: 2px solid var(--ink); border-radius: var(--r-card); color: var(--ink);
|
|
740
|
+
background: repeating-linear-gradient(90deg, var(--panel) 0 2px, color-mix(in oklab, var(--panel) 92%, var(--surface)) 2px 4px);
|
|
741
|
+
box-shadow: inset 0 1px 0 color-mix(in oklab, var(--surface) 60%, transparent), 0 6px 0 color-mix(in oklab, var(--ink) 70%, transparent);
|
|
742
|
+
}
|
|
743
|
+
[data-instrument] .ix-screw { position: absolute; width: 10px; height: 10px; border-radius: 50%; border: 1px solid var(--ink);
|
|
744
|
+
background: radial-gradient(circle at 35% 35%, var(--surface), var(--well)); }
|
|
745
|
+
[data-instrument] .ix-screw--tl { top: 8px; left: 8px; } [data-instrument] .ix-screw--tr { top: 8px; right: 8px; }
|
|
746
|
+
[data-instrument] .ix-screw--bl { bottom: 8px; left: 8px; } [data-instrument] .ix-screw--br { bottom: 8px; right: 8px; }
|
|
747
|
+
[data-instrument] .ix-plate { justify-self: start; padding: 4px 10px; border: 1px solid var(--ink); border-radius: var(--r-control);
|
|
748
|
+
background: var(--surface); font: 700 12px/1.3 var(--font-family); letter-spacing: .16em; text-transform: uppercase; }
|
|
749
|
+
[data-instrument] .ix-label { font-size: 11px; letter-spacing: .14em; text-transform: uppercase; color: color-mix(in oklab, var(--ink) 75%, var(--panel)); }
|
|
750
|
+
[data-instrument] .ix-well { display: grid; gap: var(--s2); padding: var(--s2); border-radius: var(--r-control); background: var(--well);
|
|
751
|
+
box-shadow: inset 0 2px 5px color-mix(in oklab, var(--ink) 45%, transparent); }
|
|
752
|
+
[data-instrument] .ix-lcd { padding: 4px 10px; border-radius: 4px; border: 1px solid var(--ink); background: var(--screen);
|
|
753
|
+
box-shadow: inset 0 2px 4px color-mix(in oklab, var(--ink) 35%, transparent); font: 700 18px/1.2 ui-monospace, monospace;
|
|
754
|
+
font-variant-numeric: tabular-nums; color: color-mix(in oklab, var(--ink) 80%, var(--led));
|
|
755
|
+
text-shadow: 0 0 6px color-mix(in oklab, var(--led) 50%, transparent); }
|
|
756
|
+
[data-instrument] .ix-lights { display: grid; grid-template-columns: repeat(16, 1fr); gap: 4px; }
|
|
757
|
+
[data-instrument] .ix-light { height: 6px; border-radius: 3px; background: color-mix(in oklab, var(--led) 18%, var(--well)); }
|
|
758
|
+
[data-instrument] .ix-light[data-on] { background: var(--led); box-shadow: 0 0 8px var(--led); }
|
|
759
|
+
[data-instrument] .ui-pad { border: 1px solid var(--ink); border-radius: 4px; box-shadow: 0 3px 0 var(--ink); }
|
|
760
|
+
[data-instrument] .ui-pad[data-state="off"] { background: var(--pad-off); }
|
|
761
|
+
[data-instrument] .ui-pad[data-state="on"][data-group="0"] { background: var(--purple); }
|
|
762
|
+
[data-instrument] .ui-pad[data-state="on"][data-group="1"] { background: var(--orange); }
|
|
763
|
+
[data-instrument] .ui-pad[data-state="on"][data-group="2"] { background: var(--up); }
|
|
764
|
+
[data-instrument] .ui-pad[data-state="on"][data-group="3"] { background: color-mix(in oklab, var(--purple) 50%, var(--orange)); }
|
|
765
|
+
[data-instrument] .ui-pad[data-state="on"] .ui-pad__led { background: var(--on-accent); box-shadow: 0 0 8px var(--on-accent); }
|
|
766
|
+
[data-instrument] .ui-pad__ring { box-shadow: inset 0 0 0 3px var(--led), 0 0 10px var(--led); }
|
|
767
|
+
[data-instrument] .ix-knob { display: grid; justify-items: center; gap: 4px; }
|
|
768
|
+
[data-instrument] .ix-knob__cap { position: relative; width: 56px; height: 56px; border-radius: 50%; border: 2px solid var(--ink);
|
|
769
|
+
touch-action: none; cursor: ns-resize; box-shadow: 0 3px 0 var(--ink);
|
|
770
|
+
background: radial-gradient(circle at 40% 35%, color-mix(in oklab, var(--surface) 92%, var(--ink)), var(--well) 72%);
|
|
771
|
+
transform: rotate(calc(-135deg + var(--turn) * 270deg)); }
|
|
772
|
+
[data-instrument] .ix-knob__cap::after { content: ""; position: absolute; left: calc(50% - 2px); top: 5px; width: 4px; height: 16px;
|
|
773
|
+
border-radius: 2px; background: var(--led); box-shadow: 0 0 6px var(--led); }
|
|
774
|
+
[data-instrument] .ix-knob__cap:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; }
|
|
775
|
+
/* arrangement helpers: a pad grid lays one voice's steps four by four; a rack stacks voice units */
|
|
776
|
+
[data-instrument] .ix-grid4 .ui-stepgrid { --ui-steps: 4; --ui-steps-narrow: 4; }
|
|
777
|
+
[data-instrument] .ix-voices { display: grid; grid-template-columns: repeat(2, 1fr); gap: var(--s2); }
|
|
778
|
+
[data-instrument] .ix-unit { position: relative; display: grid; gap: var(--s2); padding: var(--s3); border: 1px solid var(--ink);
|
|
779
|
+
border-radius: var(--r-control); background: var(--well); }
|
|
780
|
+
`;
|
|
781
|
+
|
|
782
|
+
// A knob turns: drag up to raise it, arrow keys step it. Its value shows on a small readout.
|
|
783
|
+
function Knob({ label, value, min, max, shown, onChange }) {
|
|
784
|
+
const drag = useRef(null);
|
|
785
|
+
const clamp = (v) => Math.min(max, Math.max(min, Math.round(v)));
|
|
786
|
+
const turn = { "--turn": (value - min) / (max - min) };
|
|
725
787
|
return (
|
|
726
|
-
<
|
|
727
|
-
<
|
|
728
|
-
|
|
729
|
-
|
|
730
|
-
|
|
731
|
-
|
|
732
|
-
|
|
733
|
-
|
|
734
|
-
|
|
735
|
-
|
|
788
|
+
<div className="ix-knob">
|
|
789
|
+
<div
|
|
790
|
+
role="slider"
|
|
791
|
+
tabIndex={0}
|
|
792
|
+
aria-label={label}
|
|
793
|
+
aria-valuemin={min}
|
|
794
|
+
aria-valuemax={max}
|
|
795
|
+
aria-valuenow={value}
|
|
796
|
+
className="ix-knob__cap"
|
|
797
|
+
style={turn}
|
|
798
|
+
onPointerDown={(e) => {
|
|
799
|
+
e.currentTarget.setPointerCapture(e.pointerId);
|
|
800
|
+
drag.current = { y: e.clientY, v: value };
|
|
801
|
+
}}
|
|
802
|
+
onPointerMove={(e) => drag.current && onChange(clamp(drag.current.v + ((drag.current.y - e.clientY) / 160) * (max - min)))}
|
|
803
|
+
onPointerUp={() => (drag.current = null)}
|
|
804
|
+
onPointerCancel={() => (drag.current = null)}
|
|
805
|
+
onKeyDown={(e) => {
|
|
806
|
+
const d = { ArrowUp: 1, ArrowRight: 1, ArrowDown: -1, ArrowLeft: -1 }[e.key];
|
|
807
|
+
if (d) {
|
|
808
|
+
e.preventDefault();
|
|
809
|
+
onChange(clamp(value + d));
|
|
810
|
+
}
|
|
811
|
+
}}
|
|
812
|
+
/>
|
|
813
|
+
<span className="ix-label">{label}</span>
|
|
814
|
+
<span className="ix-lcd">{shown}</span>
|
|
815
|
+
</div>
|
|
736
816
|
);
|
|
737
817
|
}
|
|
738
818
|
|
|
739
|
-
|
|
740
|
-
|
|
741
|
-
const { me, can, ready } = useVibe("drumMachine");
|
|
742
|
-
const { requestLogin, ViewerTag } = useViewer();
|
|
743
|
-
const { docs: grooves } = useLiveQuery("type", { key: "groove" });
|
|
744
|
-
|
|
819
|
+
// The engine wiring every arrangement shares: state, the iOS unlock, and a playhead that follows the sound.
|
|
820
|
+
function useDrumMachine() {
|
|
745
821
|
const [grid, setGrid] = useState(START);
|
|
746
822
|
const [bpm, setBpm] = useState(112);
|
|
747
823
|
const [swing, setSwing] = useState(0);
|
|
@@ -749,21 +825,13 @@ export default function App() {
|
|
|
749
825
|
const [volume, setVolume] = useState(80);
|
|
750
826
|
const [playing, setPlaying] = useState(false);
|
|
751
827
|
const [step, setStep] = useState(-1);
|
|
752
|
-
const [name, setName] = useState("");
|
|
753
|
-
const [saving, setSaving] = useState(false);
|
|
754
828
|
const drumsRef = useRef(null);
|
|
755
|
-
|
|
756
829
|
const settings = { pattern: grid, bpm, swing: swing / 100, drive: drive / 100, volume: volume / 100 };
|
|
757
830
|
|
|
758
|
-
// Every change reaches the engine; the scheduler reads it on its next step, so edits land in time.
|
|
759
831
|
useEffect(() => {
|
|
760
832
|
drumsRef.current?.update(settings);
|
|
761
833
|
}, [grid, bpm, swing, drive, volume]);
|
|
762
|
-
|
|
763
|
-
// Silence on leaving the page.
|
|
764
834
|
useEffect(() => () => drumsRef.current?.stop(), []);
|
|
765
|
-
|
|
766
|
-
// The lit step follows the sound: each frame asks the engine which step has reached the speakers.
|
|
767
835
|
useEffect(() => {
|
|
768
836
|
if (!playing) return;
|
|
769
837
|
let raf = 0;
|
|
@@ -775,169 +843,224 @@ export default function App() {
|
|
|
775
843
|
return () => cancelAnimationFrame(raf);
|
|
776
844
|
}, [playing]);
|
|
777
845
|
|
|
778
|
-
// Called synchronously at the top of
|
|
846
|
+
// Called synchronously at the top of every tap handler: that is what unlocks audio on iOS.
|
|
779
847
|
function drums() {
|
|
780
848
|
const engine = getDrums();
|
|
781
849
|
if (!drumsRef.current) engine.update(settings);
|
|
782
850
|
drumsRef.current = engine;
|
|
783
851
|
return engine;
|
|
784
852
|
}
|
|
785
|
-
|
|
786
853
|
function togglePlay() {
|
|
787
854
|
const engine = drums();
|
|
788
855
|
if (playing) {
|
|
789
856
|
engine.stop();
|
|
790
857
|
setStep(-1);
|
|
791
|
-
} else
|
|
792
|
-
engine.start();
|
|
793
|
-
}
|
|
858
|
+
} else engine.start();
|
|
794
859
|
setPlaying(!playing);
|
|
795
860
|
}
|
|
796
|
-
|
|
797
861
|
function toggleStep(track, i) {
|
|
798
862
|
const engine = drums();
|
|
799
863
|
const on = !grid[track][i];
|
|
800
864
|
setGrid({ ...grid, [track]: grid[track].map((v, j) => (j === i ? (on ? 1 : 0) : v)) });
|
|
801
865
|
if (on && !playing) engine.hit(track); // hear the sound you just placed
|
|
802
866
|
}
|
|
867
|
+
const hit = (track) => drums().hit(track);
|
|
868
|
+
const clear = () => setGrid(Object.fromEntries(TRACKS.map(({ id }) => [id, Array(STEPS).fill(0)])));
|
|
869
|
+
return { grid, setGrid, bpm, setBpm, swing, setSwing, drive, setDrive, volume, setVolume, playing, step, togglePlay, toggleStep, hit, clear };
|
|
870
|
+
}
|
|
803
871
|
|
|
804
|
-
|
|
805
|
-
|
|
806
|
-
|
|
807
|
-
|
|
808
|
-
setDrive(groove.drive ?? 30);
|
|
809
|
-
}
|
|
872
|
+
// Four corner screws; a rack unit carries its own set.
|
|
873
|
+
function Screws() {
|
|
874
|
+
return ["tl", "tr", "bl", "br"].map((at) => <span key={at} className={`ix-screw ix-screw--${at}`} aria-hidden="true" />);
|
|
875
|
+
}
|
|
810
876
|
|
|
811
|
-
|
|
812
|
-
|
|
877
|
+
// The panel itself: bezel, sheet, screws and a printed name plate.
|
|
878
|
+
function Panel({ label, plate, children }) {
|
|
879
|
+
return (
|
|
880
|
+
<section data-instrument aria-label={label}>
|
|
881
|
+
<style>{FACE}</style>
|
|
882
|
+
<Screws />
|
|
883
|
+
<span className="ix-plate">{plate}</span>
|
|
884
|
+
{children}
|
|
885
|
+
</section>
|
|
886
|
+
);
|
|
887
|
+
}
|
|
813
888
|
|
|
814
|
-
|
|
815
|
-
|
|
816
|
-
|
|
817
|
-
|
|
818
|
-
|
|
819
|
-
|
|
820
|
-
|
|
821
|
-
|
|
822
|
-
|
|
823
|
-
|
|
824
|
-
setSaving(false);
|
|
825
|
-
}
|
|
826
|
-
}
|
|
889
|
+
// Sixteen step lights; the lit one follows the playhead.
|
|
890
|
+
function Lights({ step }) {
|
|
891
|
+
return (
|
|
892
|
+
<div className="ix-lights" aria-hidden="true">
|
|
893
|
+
{Array.from({ length: STEPS }, (_, i) => (
|
|
894
|
+
<span key={i} className="ix-light" data-on={i === step || undefined} />
|
|
895
|
+
))}
|
|
896
|
+
</div>
|
|
897
|
+
);
|
|
898
|
+
}
|
|
827
899
|
|
|
900
|
+
// Play, Clear and the tempo readout.
|
|
901
|
+
function Transport({ m }) {
|
|
828
902
|
return (
|
|
829
|
-
<
|
|
830
|
-
<
|
|
831
|
-
|
|
832
|
-
|
|
833
|
-
|
|
834
|
-
|
|
835
|
-
|
|
836
|
-
|
|
837
|
-
<Card variant="tight">
|
|
838
|
-
<Stack gap={3}>
|
|
839
|
-
{TRACKS.map(({ id, label }) => (
|
|
840
|
-
<Stack key={id} gap={1}>
|
|
841
|
-
<Text size="sm" muted>
|
|
842
|
-
{label}
|
|
843
|
-
</Text>
|
|
844
|
-
{/* Square pads in beats of four, the lit one following the sound: sixteen across, eight a line on a phone. */}
|
|
845
|
-
<StepGrid label={label} steps={grid[id]} playhead={step} groupSize={4} onToggle={(i) => toggleStep(id, i)} />
|
|
846
|
-
</Stack>
|
|
847
|
-
))}
|
|
848
|
-
</Stack>
|
|
849
|
-
</Card>
|
|
850
|
-
|
|
851
|
-
<Card variant="tight">
|
|
852
|
-
<Stack gap={3}>
|
|
853
|
-
<Row gap={2} align="center">
|
|
854
|
-
<Button onClick={togglePlay}>{playing ? "Stop" : "Play the drums"}</Button>
|
|
855
|
-
<Spacer />
|
|
856
|
-
<Button size="sm" variant="quiet" onClick={() => setGrid(Object.fromEntries(TRACKS.map(({ id }) => [id, Array(STEPS).fill(0)])))}>
|
|
857
|
-
Clear
|
|
858
|
-
</Button>
|
|
859
|
-
</Row>
|
|
860
|
-
<Fader label="Tempo" value={bpm} min={60} max={180} shown={`${bpm} bpm`} onChange={setBpm} />
|
|
861
|
-
<Fader label="Swing" value={swing} min={0} max={100} shown={`${swing}%`} onChange={setSwing} />
|
|
862
|
-
<Fader label="Saturation" value={drive} min={0} max={100} shown={`${drive}%`} onChange={setDrive} />
|
|
863
|
-
<Fader label="Volume" value={volume} min={0} max={100} shown={`${volume}%`} onChange={setVolume} />
|
|
864
|
-
</Stack>
|
|
865
|
-
</Card>
|
|
866
|
-
|
|
867
|
-
<Card variant="tight">
|
|
868
|
-
<Stack gap={3}>
|
|
869
|
-
<Heading level={2}>Saved grooves</Heading>
|
|
870
|
-
{!ready && (
|
|
871
|
-
<div aria-busy="true">
|
|
872
|
-
<Skeleton variant="row" />
|
|
873
|
-
</div>
|
|
874
|
-
)}
|
|
875
|
-
{ready && !me && (
|
|
876
|
-
<Row gap={2} align="center" wrap>
|
|
877
|
-
<Text muted>Sign in to save this groove.</Text>
|
|
878
|
-
<Button size="sm" variant="quiet" onClick={requestLogin}>
|
|
879
|
-
Sign in
|
|
880
|
-
</Button>
|
|
881
|
-
</Row>
|
|
882
|
-
)}
|
|
883
|
-
{ready && me && verdict.ok && (
|
|
884
|
-
<Row gap={2} align="top" wrap>
|
|
885
|
-
<Field label="Groove name">{(id, d) => <Input id={id} describedBy={d} value={name} onChange={setName} />}</Field>
|
|
886
|
-
<Button size="sm" loading={saving} onClick={save}>
|
|
887
|
-
Save groove
|
|
888
|
-
</Button>
|
|
889
|
-
</Row>
|
|
890
|
-
)}
|
|
891
|
-
{ready && me && !verdict.ok && <Text muted>Saving grooves is closed here. You can still play and load the saved ones.</Text>}
|
|
892
|
-
{grooves.map((g) => (
|
|
893
|
-
<Row key={g._id} gap={2} align="center" wrap>
|
|
894
|
-
<Button size="sm" variant="quiet" onClick={() => load(g)}>
|
|
895
|
-
{g.name}
|
|
896
|
-
</Button>
|
|
897
|
-
<Text size="sm" muted num>
|
|
898
|
-
{g.bpm} bpm
|
|
899
|
-
</Text>
|
|
900
|
-
{g.authorHandle && <ViewerTag userHandle={g.authorHandle} />}
|
|
901
|
-
</Row>
|
|
902
|
-
))}
|
|
903
|
-
</Stack>
|
|
904
|
-
</Card>
|
|
905
|
-
</Stack>
|
|
906
|
-
</main>
|
|
903
|
+
<Row gap={3} align="center" wrap>
|
|
904
|
+
<Button onClick={m.togglePlay}>{m.playing ? "Stop" : "Play"}</Button>
|
|
905
|
+
<Button size="sm" variant="quiet" onClick={m.clear}>
|
|
906
|
+
Clear
|
|
907
|
+
</Button>
|
|
908
|
+
<Spacer />
|
|
909
|
+
<span className="ix-lcd">{String(m.bpm).padStart(3, "0")} BPM</span>
|
|
910
|
+
</Row>
|
|
907
911
|
);
|
|
908
912
|
}
|
|
909
|
-
```
|
|
910
913
|
|
|
911
|
-
|
|
914
|
+
// Tempo, Swing, Drive and Volume: four 56px knobs fit a phone's width in one row.
|
|
915
|
+
function Knobs({ m }) {
|
|
916
|
+
return (
|
|
917
|
+
<Row gap={2} align="center" justify="between">
|
|
918
|
+
<Knob label="Tempo" value={m.bpm} min={60} max={180} shown={m.bpm} onChange={m.setBpm} />
|
|
919
|
+
<Knob label="Swing" value={m.swing} min={0} max={100} shown={`${m.swing}%`} onChange={m.setSwing} />
|
|
920
|
+
<Knob label="Drive" value={m.drive} min={0} max={100} shown={`${m.drive}%`} onChange={m.setDrive} />
|
|
921
|
+
<Knob label="Volume" value={m.volume} min={0} max={100} shown={`${m.volume}%`} onChange={m.setVolume} />
|
|
922
|
+
</Row>
|
|
923
|
+
);
|
|
924
|
+
}
|
|
925
|
+
// Three arrangements. Choose one, name it in the picks line, and render it inside App after
|
|
926
|
+
// `const m = useDrumMachine();`. Saving, sharing and the list of saved beats are the app's own,
|
|
927
|
+
// built from the Fireproof and access docs as ordinary Cards outside the panel.
|
|
912
928
|
|
|
913
|
-
|
|
914
|
-
|
|
915
|
-
|
|
916
|
-
|
|
917
|
-
|
|
918
|
-
|
|
919
|
-
|
|
920
|
-
|
|
929
|
+
// Rows: every voice is a line of steps, the classic drum machine.
|
|
930
|
+
function RowsPanel({ m }) {
|
|
931
|
+
return (
|
|
932
|
+
<Panel label="Drum machine" plate="Jam box · 16-step">
|
|
933
|
+
<Transport m={m} />
|
|
934
|
+
<Knobs m={m} />
|
|
935
|
+
<Lights step={m.step} />
|
|
936
|
+
<div className="ix-well">
|
|
937
|
+
{TRACKS.map(({ id, label }) => (
|
|
938
|
+
<Stack key={id} gap={1}>
|
|
939
|
+
<span className="ix-label">{label}</span>
|
|
940
|
+
<StepGrid label={label} steps={m.grid[id]} playhead={m.step} onToggle={(i) => m.toggleStep(id, i)} />
|
|
941
|
+
</Stack>
|
|
942
|
+
))}
|
|
943
|
+
</div>
|
|
944
|
+
</Panel>
|
|
945
|
+
);
|
|
946
|
+
}
|
|
921
947
|
|
|
922
|
-
|
|
923
|
-
|
|
924
|
-
[
|
|
925
|
-
|
|
926
|
-
|
|
927
|
-
|
|
928
|
-
|
|
929
|
-
|
|
930
|
-
|
|
931
|
-
|
|
948
|
+
// Pad grid: big voice pads choose a sound (and play it); its sixteen steps sit four by four.
|
|
949
|
+
function PadGridPanel({ m }) {
|
|
950
|
+
const [voice, setVoice] = useState(TRACKS[0].id);
|
|
951
|
+
return (
|
|
952
|
+
<Panel label="Drum pads" plate="Pad 16">
|
|
953
|
+
<div className="ix-voices">
|
|
954
|
+
{TRACKS.map(({ id, label }) => (
|
|
955
|
+
<Button key={id} variant={voice === id ? undefined : "quiet"} onClick={() => { m.hit(id); setVoice(id); }}>
|
|
956
|
+
{label}
|
|
957
|
+
</Button>
|
|
958
|
+
))}
|
|
959
|
+
</div>
|
|
960
|
+
<div className="ix-well ix-grid4">
|
|
961
|
+
<StepGrid label={voice} steps={m.grid[voice]} playhead={m.step} onToggle={(i) => m.toggleStep(voice, i)} />
|
|
962
|
+
</div>
|
|
963
|
+
<Transport m={m} />
|
|
964
|
+
<Knobs m={m} />
|
|
965
|
+
</Panel>
|
|
966
|
+
);
|
|
967
|
+
}
|
|
932
968
|
|
|
933
|
-
|
|
969
|
+
// Vertical rack: each voice is its own rack unit, stacked, with its name plate and a hit button.
|
|
970
|
+
function RackPanel({ m }) {
|
|
934
971
|
return (
|
|
935
|
-
<
|
|
936
|
-
<
|
|
937
|
-
{
|
|
938
|
-
|
|
972
|
+
<Panel label="Drum rack" plate="Rack · 4 voices">
|
|
973
|
+
<Transport m={m} />
|
|
974
|
+
{TRACKS.map(({ id, label }) => (
|
|
975
|
+
<div key={id} className="ix-unit">
|
|
976
|
+
<Screws />
|
|
977
|
+
<Row gap={2} align="center">
|
|
978
|
+
<span className="ix-plate">{label}</span>
|
|
979
|
+
<Spacer />
|
|
980
|
+
<Button size="sm" variant="quiet" onClick={() => m.hit(id)}>
|
|
981
|
+
Hit
|
|
982
|
+
</Button>
|
|
983
|
+
</Row>
|
|
984
|
+
<StepGrid label={label} steps={m.grid[id]} playhead={m.step} onToggle={(i) => m.toggleStep(id, i)} />
|
|
985
|
+
</div>
|
|
986
|
+
))}
|
|
987
|
+
<Knobs m={m} />
|
|
988
|
+
</Panel>
|
|
939
989
|
);
|
|
940
990
|
}
|
|
941
991
|
```
|
|
942
992
|
|
|
993
|
+
### The instrument face — hardware painted from the look
|
|
994
|
+
|
|
995
|
+
Every drum machine wears an instrument face from its first build: one
|
|
996
|
+
`<section data-instrument>` panel that holds the pads, the transport and the
|
|
997
|
+
knobs, so it reads as a machine you could pick up. The face is the app's own
|
|
998
|
+
instrument, so a look brief, a layout archetype or a reskin dose on the same
|
|
999
|
+
turn dresses the page around it, and the face keeps its knobs, pads and
|
|
1000
|
+
token-painted panel. The heading, the save row and the saved list stay ordinary
|
|
1001
|
+
`Card`s outside the panel, so the rest of the app keeps the look's own
|
|
1002
|
+
components. When the person names a machine or a material ("an 808", "a
|
|
1003
|
+
vintage beat box", "an MPC", "brushed metal"), this face is how it gets there.
|
|
1004
|
+
|
|
1005
|
+
**Paint from the look's tokens.** Every colour in the face is a `color-mix` of
|
|
1006
|
+
the look's tokens: `--bg --surface --ink --purple --orange --info --up
|
|
1007
|
+
--on-accent`, with `--r-card --r-control` for corners and `--font-family` for
|
|
1008
|
+
type. The face assigns no value to a token and writes no hex colour, so the
|
|
1009
|
+
Look tab's colours and every look in the look picker, light and dark,
|
|
1010
|
+
repaint the whole machine, and each look gives the same
|
|
1011
|
+
drum machine a different body. **Every fill starts from `--surface`.** The panel,
|
|
1012
|
+
the well, the readout window, the knob caps and the unlit pads are `--surface`
|
|
1013
|
+
with a small share of `--ink` (75% `--surface` or more), so they stay a body
|
|
1014
|
+
the look's own colour on light looks and on dark ones like Terminal, where
|
|
1015
|
+
`--ink` is the light colour. Text, borders, bezels and shadows are where `--ink`
|
|
1016
|
+
leads. The readout is a recessed `--surface` window with `--ink` glyphs tinted
|
|
1017
|
+
by the LED colour, readable in both polarities; the LEDs are the LED role on
|
|
1018
|
+
that body. Focus outlines are `--ink`, since an LED colour can sit close to the
|
|
1019
|
+
panel.
|
|
1020
|
+
|
|
1021
|
+
**The pads stay `StepGrid`.** Style them from the panel through their hooks:
|
|
1022
|
+
`.ui-pad[data-state="on"]` and `[data-state="off"]` (give both a fill, because
|
|
1023
|
+
a look's button rule paints a pad otherwise), `[data-group]` (0 to 3 across a
|
|
1024
|
+
bar), `[data-playhead]`, `.ui-pad__led` and `.ui-pad__ring`.
|
|
1025
|
+
|
|
1026
|
+
**Make it yours: every first build chooses one per axis** and names the picks
|
|
1027
|
+
as the first line of `FACE`, in the reference's shape:
|
|
1028
|
+
`/* picks: arrangement = … · pad = … · panel = … · led = … · transport = … */`.
|
|
1029
|
+
Choose from what the person asked for and what the app is about; when the
|
|
1030
|
+
turn carries an "Instrument arrangement" section, that is this app's
|
|
1031
|
+
arrangement. The
|
|
1032
|
+
reference's picks are one combination; keep one only when it is the right one
|
|
1033
|
+
for this app, so two drum machines rarely share all five. Each pick is a few
|
|
1034
|
+
lines of the sheet or the markup.
|
|
1035
|
+
|
|
1036
|
+
- **Arrangement:** tracks as rows (one `StepGrid` per voice, stacked, as in the
|
|
1037
|
+
reference); a pad grid (four big voice pads choose which voice to edit, and a
|
|
1038
|
+
single `StepGrid` for that voice is laid out four by four with
|
|
1039
|
+
`--ui-steps: 4; --ui-steps-narrow: 4` on `.ui-stepgrid`, MPC style); or a
|
|
1040
|
+
vertical rack (each voice its own rack unit, stacked: a name plate, a mute
|
|
1041
|
+
or level knob and its step row, with a rail and screws per unit).
|
|
1042
|
+
|
|
1043
|
+
- **Pad shape:** square key (small radius, hard bottom edge), rubber pad
|
|
1044
|
+
(`border-radius: 30%`, inset shadow), or round cap (`50%`).
|
|
1045
|
+
- **Panel material:** flat plate, brushed metal (a `repeating-linear-gradient`
|
|
1046
|
+
of two `--surface`-led mixes), or wood cheeks (thick side borders mixed from `--orange`
|
|
1047
|
+
and `--ink`).
|
|
1048
|
+
- **LED colour role:** `--info`, `--orange` or `--up`, which lights the
|
|
1049
|
+
playhead ring, the step lights and the readout.
|
|
1050
|
+
- **Transport layout:** a strip above the grid, a deck below it, or a column
|
|
1051
|
+
beside it on wide screens.
|
|
1052
|
+
- **Beat-group colours:** four accents across the bar, two-tone by parity, or
|
|
1053
|
+
one tone with the lights doing the work.
|
|
1054
|
+
|
|
1055
|
+
**Hardware cues, all from tokens:** a bezel (`2px solid var(--ink)`,
|
|
1056
|
+
`var(--r-card)`), four screws, a printed name plate, a row of step lights over
|
|
1057
|
+
the grid, a readout for the tempo, and knobs. A knob is a plain `div` with
|
|
1058
|
+
`role="slider"`: drag up to turn it, arrow keys step it, at least 56px across.
|
|
1059
|
+
On a phone the grid runs eight pads a line, so every pad, button and knob stays
|
|
1060
|
+
thumb-sized.
|
|
1061
|
+
|
|
1062
|
+
The parts above carry this face (`FACE`, `Knob`, `Screws`, `Lights`,
|
|
1063
|
+
`Transport`, `Knobs`), and each sketch is one arrangement of them. A first build
|
|
1064
|
+
picks an arrangement and the other axes; keep every colour a token mix.
|
|
1065
|
+
|
|
943
1066
|
— End —
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vibes.diy/prompts",
|
|
3
|
-
"version": "14.3.
|
|
3
|
+
"version": "14.3.246",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"main": "./index.js",
|
|
6
6
|
"exports": {
|
|
@@ -39,10 +39,10 @@
|
|
|
39
39
|
"license": "Apache-2.0",
|
|
40
40
|
"dependencies": {
|
|
41
41
|
"@adviser/cement": "~0.5.34",
|
|
42
|
-
"@vibes.diy/api-types": "14.3.
|
|
43
|
-
"@vibes.diy/call-ai-v2": "14.3.
|
|
44
|
-
"@vibes.diy/identity": "14.3.
|
|
45
|
-
"@vibes.diy/use-vibes-types": "14.3.
|
|
42
|
+
"@vibes.diy/api-types": "14.3.246",
|
|
43
|
+
"@vibes.diy/call-ai-v2": "14.3.246",
|
|
44
|
+
"@vibes.diy/identity": "14.3.246",
|
|
45
|
+
"@vibes.diy/use-vibes-types": "14.3.246",
|
|
46
46
|
"arktype": "~2.2.8",
|
|
47
47
|
"json-schema-faker": "~0.6.3"
|
|
48
48
|
},
|
package/prompts.js
CHANGED
|
@@ -3,7 +3,7 @@ import { getLlmCatalog, getLlmCatalogNames } from "./json-docs.js";
|
|
|
3
3
|
import { canonicalSkillName } from "./llms/index.js";
|
|
4
4
|
import { getColorsetCatalogNames, getThemeCatalogNames, renderLookTokenDisciplineBlock } from "./themes/index.js";
|
|
5
5
|
import { hasLookBrief, hasOwnTokenRules, LOOK_BRIEF_ASSET_PATH, lookVarietyDialect } from "./themes/looks/index.js";
|
|
6
|
-
import { renderLookPackageSection, renderReskinDoseSection, renderTextureNoteSection, renderVarietySection, } from "./generation-variety.js";
|
|
6
|
+
import { renderLookPackageSection, renderReskinDoseSection, renderInstrumentArrangementSection, askIsBeatApp, askNamesInstrumentLayout, renderTextureNoteSection, renderVarietySection, } from "./generation-variety.js";
|
|
7
7
|
import { defaultStylePrompt } from "./style-prompts.js";
|
|
8
8
|
export async function getDefaultSkills() {
|
|
9
9
|
return ["fireproof", "callai", "image-gen", "use-vibe"];
|
|
@@ -194,11 +194,20 @@ export async function makeBaseSystemPrompt(model, sessionDoc) {
|
|
|
194
194
|
const textureNoteSection = renderTextureNoteSection(typeof sessionDoc?.textureNote === "string" ? sessionDoc.textureNote : undefined);
|
|
195
195
|
const lookPackageSection = renderLookPackageSection(sessionDoc?.lookPackage);
|
|
196
196
|
const reskinDoseSection = renderReskinDoseSection(sessionDoc?.reskinDose);
|
|
197
|
+
const beatAsk = [
|
|
198
|
+
sessionDoc?.title ?? "",
|
|
199
|
+
typeof sessionDoc?.enrichedPrompt === "string" ? sessionDoc.enrichedPrompt : "",
|
|
200
|
+
userPrompt,
|
|
201
|
+
].join("\n");
|
|
202
|
+
const instrumentArrangementSection = chosenLlms.some((l) => l.name === "web-audio") && askIsBeatApp(beatAsk) && askNamesInstrumentLayout(userPrompt) === false
|
|
203
|
+
? renderInstrumentArrangementSection(sessionDoc?.instrumentArrangement)
|
|
204
|
+
: "";
|
|
197
205
|
const themeDesignSection = [
|
|
198
206
|
themeTokenSection,
|
|
199
207
|
varietySectionForTurn,
|
|
200
208
|
lookPackageSection,
|
|
201
209
|
reskinDoseSection,
|
|
210
|
+
instrumentArrangementSection,
|
|
202
211
|
...(headLook.length > 0 ? [] : [textureNoteSection]),
|
|
203
212
|
]
|
|
204
213
|
.filter((s) => s.length > 0)
|
package/prompts.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"prompts.js","sourceRoot":"","sources":["../jsr/prompts.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,SAAS,EAAE,eAAe,EAAE,MAAM,iBAAiB,CAAC;AAC7D,OAAO,EAAE,aAAa,EAAE,kBAAkB,EAAmB,MAAM,gBAAgB,CAAC;AACpF,OAAO,EAAE,kBAAkB,EAAE,MAAM,iBAAiB,CAAC;AACrD,OAAO,EAAE,uBAAuB,EAAE,oBAAoB,EAAE,8BAA8B,EAAE,MAAM,mBAAmB,CAAC;AAClH,OAAO,EAAE,YAAY,EAAE,gBAAgB,EAAE,qBAAqB,EAAE,kBAAkB,EAAE,MAAM,yBAAyB,CAAC;AACpH,OAAO,EACL,wBAAwB,EACxB,uBAAuB,EACvB,wBAAwB,EACxB,oBAAoB,GACrB,MAAM,yBAAyB,CAAC;AAEjC,OAAO,EAAE,kBAAkB,EAAE,MAAM,oBAAoB,CAAC;AAExD,MAAM,CAAC,KAAK,UAAU,gBAAgB;IACpC,OAAO,CAAC,WAAW,EAAE,QAAQ,EAAE,WAAW,EAAE,UAAU,CAAC,CAAC;AAC1D,CAAC;AAmCD,MAAM,UAAU,cAAc,CAAC,OAA+C;IAG5E,IAAI,OAAO,KAAK,iBAAiB;QAAE,OAAO,EAAE,CAAC;IAC7C,MAAM,WAAW,GAAG,OAAO,KAAK,SAAS,IAAI,OAAO,K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ules they set for them; the page is
|
|
|
55
55
|
**The restraints.** A value the person already has in mind stays a direct control when setting or adjusting that value: use a picker, stepper, slider or toggle, and a critical value (a dose, a price, a deadline, a timer, a recipient) is never inferred from a sentence. Quantity steppers, claim buttons and toggles on existing records stay direct controls that complement sentence creation; ordinary quantities described in a new record, such as two tents or six servings, can be extracted, and the saved row retains its quantity control. Keep a simple message or a name direct when its text already is the whole record; a name-only list, a simple message and a timer stay direct, and extraction is for where the person would otherwise fill several fields. Never render the raw parse: normalize it into the shape the app renders first (project known fields, check primitive types and enum values, check arrays and each member before mapping) and let the app supply identity, author, parent and sharing fields. Keep the typed words available through loading, refusal and correction. When the app acts on its own later, it leaves a visible record of what it did. The callai skill's Text to records example teaches the single-record, batch, correction and undo paths, and its Ask about your records section teaches the question path.
|
|
56
56
|
- List data items on the main page of your app so people can browse and open each saved record, each one a card or row with direct editing.
|
|
57
57
|
- For an app with the callai skill, let an example chip put an example sentence into the same intake box; submitting it runs the same parser and automatic save path as the person's own words. Extraction of the person's facts into structured records is a default use of callAI, including when the request describes an ordinary useful app; additional analysis (such as sentiment scoring or inferred tags) is a feature the person requests. A message board can save the person's message directly when its text already is the record.
|
|
58
|
-
- Every form carries one sparkle button that fills its fields with a suggestion from callAI, so the person can save without typing, a one-field name form included (a name saved directly, with no extraction, still gets its sparkle), each suggestion sized to its field: the callai skill's Fill a form with a suggestion section shows the shape, the sparkle fills, and the form's own submit saves.{{DEMO_DATA}}
|
|
58
|
+
- Every form carries one sparkle button that fills its fields with a suggestion from callAI, so the person can save without typing, a one-field name form included (a name saved directly, with no extraction, still gets its sparkle), each suggestion sized to its field: the callai skill's Fill a form with a suggestion section shows the shape, the sparkle fills, and the form's own submit saves. A field that says where money goes — a payment handle, a $Cashtag, a Zelle or Venmo name, a bank or account number, a payout email — is the one the owner always types: its form carries no sparkle and the field starts empty, because an invented handle sends a real buyer's money to a stranger.{{DEMO_DATA}}
|
|
59
59
|
|
|
60
60
|
{{CONCATENATED_LLMS}}
|
|
61
61
|
IMPORTANT: Your main file is `App.jsx` (the React component). This is the **first turn** — `App.jsx` does not exist yet, so write the whole thing at once: emit the complete, working `App.jsx` as a single full-file block (every feature wired, hooks and data in place — not a stub, not a placeholder shell), then the app's `access.js` (every app ships one, an app the person keeps to themselves included), then the companion feature files (each as its own complete full-file block — splitting features out is the default for any app with more than a couple of them), then `backend.js` when the app needs server work, then a `seed.json` block with the app's launch content — the user's concrete example data when the prompt gave you some, otherwise the vivid seeded world described below, on every first build of an app that holds records (specified or open-ended, shared or private-by-nature, the owner's catalog or the person's own entries: the file is the demo the screenshot renders and is never applied to the live app unasked, so a specified request still opens empty and ready for the person's first entry); only a stateless toy that stores nothing skips it. That is the entire first turn — the whole app: one `App.jsx` block, its `access.js` when it has one, companion feature files if any, `backend.js` when it needs one, then `seed.json` (order: App.jsx → access.js when present → companion files → backend.js → seed.json). Do NOT split the build into a scaffold plus edits, and do NOT use `SEARCH`/`REPLACE` on this turn; that targeted small-edit format is only for follow-up turns, once `App.jsx` already exists.
|
|
@@ -91,7 +91,7 @@ The sandbox serves raw ES modules, so `App.jsx` can import local `.js`/`.jsx` fi
|
|
|
91
91
|
- The `<header>` with the real brand title and any always-visible chrome.
|
|
92
92
|
- One function component per feature, each fully wired: its hooks (`useFireproof`, `useLiveQuery`, `useVibe`), its data, its handlers, and its JSX — a working feature, not a heading stub. A feature with a form is written whole in one pass, in this order:
|
|
93
93
|
- its fields and its submit, saving through the form's own normalizer;
|
|
94
|
-
- its one sparkle button beside that submit: a quiet `IconButton` with the `sparkle` icon, wired to a `callAI` call through the form's own schema and normalizer that fills the form's fields, the submit still saving (the shared rule above and the callai skill's Fill a form with a suggestion section). A one-field name box is a form with its own sparkle too. The form is done when its sparkle sits beside its submit, so every form on screen lands in this first version with its sparkle.
|
|
94
|
+
- its one sparkle button beside that submit (every form but the owner's payment-destination form, per the shared rule above): a quiet `IconButton` with the `sparkle` icon, wired to a `callAI` call through the form's own schema and normalizer that fills the form's fields, the submit still saving (the shared rule above and the callai skill's Fill a form with a suggestion section). A one-field name box is a form with its own sparkle too. The form is done when its sparkle sits beside its submit, so every form on screen lands in this first version with its sparkle.
|
|
95
95
|
- A default-exported `App` function composing them inside `<main id="app">` with `<header id="app-header">`.
|
|
96
96
|
|
|
97
97
|
Every feature you described above should work when this one block lands. Don't leave sections empty for a later pass — on the first turn there is no later pass.
|
package/system-prompt-initial.md
CHANGED
|
@@ -55,7 +55,7 @@ An app is the person's own records and the rules they set for them; the page is
|
|
|
55
55
|
**The restraints.** A value the person already has in mind stays a direct control when setting or adjusting that value: use a picker, stepper, slider or toggle, and a critical value (a dose, a price, a deadline, a timer, a recipient) is never inferred from a sentence. Quantity steppers, claim buttons and toggles on existing records stay direct controls that complement sentence creation; ordinary quantities described in a new record, such as two tents or six servings, can be extracted, and the saved row retains its quantity control. Keep a simple message or a name direct when its text already is the whole record; a name-only list, a simple message and a timer stay direct, and extraction is for where the person would otherwise fill several fields. Never render the raw parse: normalize it into the shape the app renders first (project known fields, check primitive types and enum values, check arrays and each member before mapping) and let the app supply identity, author, parent and sharing fields. Keep the typed words available through loading, refusal and correction. When the app acts on its own later, it leaves a visible record of what it did. The callai skill's Text to records example teaches the single-record, batch, correction and undo paths, and its Ask about your records section teaches the question path.
|
|
56
56
|
- List data items on the main page of your app so people can browse and open each saved record, each one a card or row with direct editing.
|
|
57
57
|
- For an app with the callai skill, let an example chip put an example sentence into the same intake box; submitting it runs the same parser and automatic save path as the person's own words. Extraction of the person's facts into structured records is a default use of callAI, including when the request describes an ordinary useful app; additional analysis (such as sentiment scoring or inferred tags) is a feature the person requests. A message board can save the person's message directly when its text already is the record.
|
|
58
|
-
- Every form carries one sparkle button that fills its fields with a suggestion from callAI, so the person can save without typing, a one-field name form included (a name saved directly, with no extraction, still gets its sparkle), each suggestion sized to its field: the callai skill's Fill a form with a suggestion section shows the shape, the sparkle fills, and the form's own submit saves.{{DEMO_DATA}}
|
|
58
|
+
- Every form carries one sparkle button that fills its fields with a suggestion from callAI, so the person can save without typing, a one-field name form included (a name saved directly, with no extraction, still gets its sparkle), each suggestion sized to its field: the callai skill's Fill a form with a suggestion section shows the shape, the sparkle fills, and the form's own submit saves. A field that says where money goes — a payment handle, a $Cashtag, a Zelle or Venmo name, a bank or account number, a payout email — is the one the owner always types: its form carries no sparkle and the field starts empty, because an invented handle sends a real buyer's money to a stranger.{{DEMO_DATA}}
|
|
59
59
|
|
|
60
60
|
{{CONCATENATED_LLMS}}
|
|
61
61
|
IMPORTANT: Your main file is `App.jsx` (the React component). This is the **first turn** — `App.jsx` does not exist yet. Ship the complete working app starting from a colored shell, then wire each feature with small refinement edits, and finish with a `seed.json` block of launch content.
|
package/system-prompt.md
CHANGED
|
@@ -62,7 +62,7 @@ An app is the person's own records and the rules they set for them; the page is
|
|
|
62
62
|
**The restraints.** A value the person already has in mind stays a direct control when setting or adjusting that value: use a picker, stepper, slider or toggle, and a critical value (a dose, a price, a deadline, a timer, a recipient) is never inferred from a sentence. Quantity steppers, claim buttons and toggles on existing records stay direct controls that complement sentence creation; ordinary quantities described in a new record, such as two tents or six servings, can be extracted, and the saved row retains its quantity control. Keep a simple message or a name direct when its text already is the whole record; a name-only list, a simple message and a timer stay direct, and extraction is for where the person would otherwise fill several fields. Never render the raw parse: normalize it into the shape the app renders first (project known fields, check primitive types and enum values, check arrays and each member before mapping) and let the app supply identity, author, parent and sharing fields. Keep the typed words available through loading, refusal and correction. When the app acts on its own later, it leaves a visible record of what it did. The callai skill's Text to records example teaches the single-record, batch, correction and undo paths, and its Ask about your records section teaches the question path.
|
|
63
63
|
- List data items on the main page of your app so people can browse and open each saved record, each one a card or row with direct editing.
|
|
64
64
|
- For an app with the callai skill, let an example chip put an example sentence into the same intake box; submitting it runs the same parser and automatic save path as the person's own words. Extraction of the person's facts into structured records is a default use of callAI, including when the request describes an ordinary useful app; additional analysis (such as sentiment scoring or inferred tags) is a feature the person requests. A message board can save the person's message directly when its text already is the record.
|
|
65
|
-
- Every form carries one sparkle button that fills its fields with a suggestion from callAI, so the person can save without typing, a one-field name form included (a name saved directly, with no extraction, still gets its sparkle), each suggestion sized to its field: the callai skill's Fill a form with a suggestion section shows the shape, the sparkle fills, and the form's own submit saves.{{DEMO_DATA}}
|
|
65
|
+
- Every form carries one sparkle button that fills its fields with a suggestion from callAI, so the person can save without typing, a one-field name form included (a name saved directly, with no extraction, still gets its sparkle), each suggestion sized to its field: the callai skill's Fill a form with a suggestion section shows the shape, the sparkle fills, and the form's own submit saves. A field that says where money goes — a payment handle, a $Cashtag, a Zelle or Venmo name, a bank or account number, a payout email — is the one the owner always types: its form carries no sparkle and the field starts empty, because an invented handle sends a real buyer's money to a stranger.{{DEMO_DATA}}
|
|
66
66
|
|
|
67
67
|
{{CONCATENATED_LLMS}}
|
|
68
68
|
IMPORTANT: Your main file is `App.jsx` (the React component), and on this turn it already exists: the app's current files are in view, the person is looking at the app, and this turn changes it. Every edit turn lands code the person sees at once. A small change is one or more SEARCH/REPLACE edits to the file it touches, each with one prose line before it. A new feature is a new file emitted whole plus a small `App.jsx` edit that imports and renders it. A redesign the person asked for in so many words is a full-file block. Each edit leaves the app parsing, running and wearing the look it already wears: in an app built on the UI kit (its components import from `@vibes.diy/ui`), a component takes its `tone`, `size` and `variant` props and carries no `className`, and a colour an edit adds is a tone that names its meaning; in an app on another look, each component keeps the props and classes that look's brief gives it; in every look, an action an edit adds is a `Button`, a choice a `Select`, a modal a `Dialog` — so the design check after the edit has nothing to say. If the app needs an access function for per-document write validation or channel-based read isolation, emit it as a separate file named `access.js` — never put access function code inside `App.jsx`.
|