@12ui/design 0.2.86 → 0.2.88
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/SKILL.md +1 -1
- package/codex-plugin/plugin.json +44 -44
- package/dist/cli-auth-onboarding.d.ts +0 -5
- package/dist/cli-auth-onboarding.d.ts.map +1 -1
- package/dist/cli-auth-onboarding.js +0 -8
- package/dist/cli-auth-onboarding.js.map +1 -1
- package/dist/cli-cli-command.d.ts +3 -4
- package/dist/cli-cli-command.d.ts.map +1 -1
- package/dist/cli-cli-command.js +5 -21
- package/dist/cli-cli-command.js.map +1 -1
- package/dist/cli-conversion-engine.d.ts +19 -0
- package/dist/cli-conversion-engine.d.ts.map +1 -1
- package/dist/cli-conversion-engine.js +49 -2
- package/dist/cli-conversion-engine.js.map +1 -1
- package/dist/cli-convert-command.d.ts.map +1 -1
- package/dist/cli-convert-command.js +17 -0
- package/dist/cli-convert-command.js.map +1 -1
- package/dist/cli-local-conversion.d.ts.map +1 -1
- package/dist/cli-local-conversion.js +7 -2
- package/dist/cli-local-conversion.js.map +1 -1
- package/dist/cli-skill-command.d.ts.map +1 -1
- package/dist/cli-skill-command.js +9 -2
- package/dist/cli-skill-command.js.map +1 -1
- package/dist/legacy-skill-catalog.d.ts.map +1 -1
- package/dist/legacy-skill-catalog.js +11 -0
- package/dist/legacy-skill-catalog.js.map +1 -1
- package/dist/mcp-slate-command.d.ts +6 -0
- package/dist/mcp-slate-command.d.ts.map +1 -1
- package/dist/mcp-slate-command.js +8 -2
- package/dist/mcp-slate-command.js.map +1 -1
- package/dist/mcp-slate-ui-copy.d.ts +4 -0
- package/dist/mcp-slate-ui-copy.d.ts.map +1 -1
- package/dist/mcp-slate-ui-copy.js +2 -0
- package/dist/mcp-slate-ui-copy.js.map +1 -1
- package/dist/mcp-slate-ui-locales/de-DE.d.ts.map +1 -1
- package/dist/mcp-slate-ui-locales/de-DE.js +2 -0
- package/dist/mcp-slate-ui-locales/de-DE.js.map +1 -1
- package/dist/mcp-slate-ui-locales/es-419.d.ts.map +1 -1
- package/dist/mcp-slate-ui-locales/es-419.js +2 -0
- package/dist/mcp-slate-ui-locales/es-419.js.map +1 -1
- package/dist/mcp-slate-ui-locales/es-ES.d.ts.map +1 -1
- package/dist/mcp-slate-ui-locales/es-ES.js +2 -0
- package/dist/mcp-slate-ui-locales/es-ES.js.map +1 -1
- package/dist/mcp-slate-ui-locales/fr-FR.d.ts.map +1 -1
- package/dist/mcp-slate-ui-locales/fr-FR.js +2 -0
- package/dist/mcp-slate-ui-locales/fr-FR.js.map +1 -1
- package/dist/mcp-slate-ui-locales/hi-IN.d.ts.map +1 -1
- package/dist/mcp-slate-ui-locales/hi-IN.js +2 -0
- package/dist/mcp-slate-ui-locales/hi-IN.js.map +1 -1
- package/dist/mcp-slate-ui-locales/it-IT.d.ts.map +1 -1
- package/dist/mcp-slate-ui-locales/it-IT.js +2 -0
- package/dist/mcp-slate-ui-locales/it-IT.js.map +1 -1
- package/dist/mcp-slate-ui-locales/ja-JP.d.ts.map +1 -1
- package/dist/mcp-slate-ui-locales/ja-JP.js +2 -0
- package/dist/mcp-slate-ui-locales/ja-JP.js.map +1 -1
- package/dist/mcp-slate-ui-locales/ko-KR.d.ts.map +1 -1
- package/dist/mcp-slate-ui-locales/ko-KR.js +2 -0
- package/dist/mcp-slate-ui-locales/ko-KR.js.map +1 -1
- package/dist/mcp-slate-ui-locales/pt-BR.d.ts.map +1 -1
- package/dist/mcp-slate-ui-locales/pt-BR.js +2 -0
- package/dist/mcp-slate-ui-locales/pt-BR.js.map +1 -1
- package/dist/mcp-slate-ui-locales/zh-CN.d.ts.map +1 -1
- package/dist/mcp-slate-ui-locales/zh-CN.js +2 -0
- package/dist/mcp-slate-ui-locales/zh-CN.js.map +1 -1
- package/dist/mcp-slate-ui-locales/zh-TW.d.ts.map +1 -1
- package/dist/mcp-slate-ui-locales/zh-TW.js +2 -0
- package/dist/mcp-slate-ui-locales/zh-TW.js.map +1 -1
- package/dist/mcp-slate-ui-script-remote.d.ts.map +1 -1
- package/dist/mcp-slate-ui-script-remote.js +3 -2
- package/dist/mcp-slate-ui-script-remote.js.map +1 -1
- package/dist/slate-view-contract.d.ts +1 -1
- package/dist/slate-view-contract.d.ts.map +1 -1
- package/dist/slate-view-contract.js +2 -1
- package/dist/slate-view-contract.js.map +1 -1
- package/dist/workspace-draw-branch.d.ts +5 -0
- package/dist/workspace-draw-branch.d.ts.map +1 -1
- package/dist/workspace-draw-branch.js +23 -2
- package/dist/workspace-draw-branch.js.map +1 -1
- package/dist/workspace-draw-client.d.ts.map +1 -1
- package/dist/workspace-draw-client.js +3 -1
- package/dist/workspace-draw-client.js.map +1 -1
- package/dist/workspace-draw-messages.d.ts +4 -0
- package/dist/workspace-draw-messages.d.ts.map +1 -1
- package/dist/workspace-draw-messages.js +6 -0
- package/dist/workspace-draw-messages.js.map +1 -1
- package/dist/workspace-draw-run.d.ts +2 -0
- package/dist/workspace-draw-run.d.ts.map +1 -1
- package/dist/workspace-draw-run.js +1 -0
- package/dist/workspace-draw-run.js.map +1 -1
- package/open-design.json +2 -2
- package/package.json +1 -1
- package/skills/12ui-design/SKILL.md +5 -5
package/SKILL.md
CHANGED
|
@@ -23,7 +23,7 @@ candidates.
|
|
|
23
23
|
Use `12ui` when it is available on `PATH`. Otherwise invoke the pinned CLI that
|
|
24
24
|
the plugin's `open-design.json` MCP entry uses:
|
|
25
25
|
|
|
26
|
-
npx -y @12ui/design@0.2.
|
|
26
|
+
npx -y @12ui/design@0.2.88 <command> ...
|
|
27
27
|
|
|
28
28
|
Run `12ui auth status --json` (or its pinned `npx` equivalent) first. A desktop user can authenticate with `12ui auth login`; a headless
|
|
29
29
|
run supplies `TWELVE_UI_API_KEY`. Never put a credential into project files,
|
package/codex-plugin/plugin.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "12ui",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.3",
|
|
4
4
|
"description": "A Design workspace in your Codex thread: see design options for a UI as images, select one, ask for more, edit with a scribble, search design references and hand an option off to be built. Your agent runs the 12ui command line once per request, which draws every option at once with your own Codex sign-in.",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "12ui",
|
|
@@ -20,8 +20,8 @@
|
|
|
20
20
|
"mcpServers": "./.mcp.json",
|
|
21
21
|
"interface": {
|
|
22
22
|
"displayName": "12ui Design",
|
|
23
|
-
"shortDescription": "Design
|
|
24
|
-
"longDescription": "
|
|
23
|
+
"shortDescription": "Design your UI, then build it",
|
|
24
|
+
"longDescription": "Design your app or website without leaving Codex. Describe what you want and a Design workspace opens in your thread with six options drawn as real images, side by side. Steer them with real design: search 12ui's collection of more than 20,000 designs, or pick from live screenshots of real websites suggested for your brief. Then shape the one you like: ask for more options, scribble on an option and say what to change, or branch a design into its full page and the rest of your screens in the same style.\n\nWhen a design is right, press Build this. In a few minutes, 12ui turns the image into code with your own Codex: a structured plan of the page's layout, text and artwork, the artwork extracted as real image files, and responsive HTML your agent can work with. Your agent spends its effort fitting the page into your project, not recreating it from a picture.\n\nYour Codex agent runs the 12ui command line once per request. It draws every option at once with your own Codex sign-in and image generation, and each option appears as soon as it is ready; nothing is drawn in the thread. Drawing, editing and Build this need no 12ui account: a workspace is reached through a private handle held in your thread. Branching a design into more screens asks you to sign in to 12ui. Images are stored for up to 30 days and removed after 14 days without use.\n\nWorks in Codex on a computer with Node.js; your agent installs the 12ui command line once. The draw command runs outside the sandbox, with network access to design.12ui.com, which Codex may ask you to approve.",
|
|
25
25
|
"developerName": "12ui",
|
|
26
26
|
"category": "Creativity",
|
|
27
27
|
"capabilities": [
|
|
@@ -51,34 +51,34 @@
|
|
|
51
51
|
"test_cases": {
|
|
52
52
|
"positive": [
|
|
53
53
|
{
|
|
54
|
-
"description": "Open a workspace and receive options",
|
|
55
|
-
"prompt": "Open a Design workspace for a meditation app landing page.",
|
|
56
|
-
"tools_triggered": "design.slate.create",
|
|
57
|
-
"expected_behavior": "The Design workspace card appears in the thread with
|
|
54
|
+
"description": "Open a workspace and receive six options",
|
|
55
|
+
"prompt": "Open a Design workspace for a meditation app landing page. When the workspace appears on its Inspiration tab, open the References tab, then click Continue.",
|
|
56
|
+
"tools_triggered": "design.slate.create, design.slate.run",
|
|
57
|
+
"expected_behavior": "The Design workspace card appears in the thread on its Inspiration tab, with references picked for the first round and a countdown beside Continue. The agent runs the 12ui draw command once. The References tab fills with live screenshots of real websites as they are captured, or says No websites. After Continue (or when the countdown ends) the card moves to the Designs tab and six options appear as Round 1, each as soon as it is ready. No 12ui account or sign-in is asked for."
|
|
58
58
|
},
|
|
59
59
|
{
|
|
60
|
-
"description": "Generate more options
|
|
61
|
-
"prompt": "Open a Design workspace for a bakery website. When the options appear, click
|
|
60
|
+
"description": "Generate more options",
|
|
61
|
+
"prompt": "Open a Design workspace for a bakery website. When the workspace appears on its Inspiration tab, click Continue. When the six options appear, click More at the right of the Round 1 heading (6 is selected beside it). If the Inspiration tab opens with a countdown, click Continue.",
|
|
62
62
|
"tools_triggered": "design.slate.create, design.slate.run, design.slate.data",
|
|
63
|
-
"expected_behavior": "
|
|
63
|
+
"expected_behavior": "Six loading tiles appear as Round 2 and fill in as six new options. The workspace runner the first draw left on the Mac draws them, or, when none is running, the agent is told, reads the request with design.slate.data and runs the 12ui draw command once. Clicking 12 beside More instead draws a round of twelve."
|
|
64
64
|
},
|
|
65
65
|
{
|
|
66
66
|
"description": "Edit an option with a scribble",
|
|
67
|
-
"prompt": "Open a Design workspace for a fitness app onboarding screen. When the options appear,
|
|
67
|
+
"prompt": "Open a Design workspace for a fitness app onboarding screen. When the workspace appears on its Inspiration tab, click Continue. When the options appear, click option A to open it large, click Edit, draw a circle around the headline, type 'Make the headline larger' in the Describe a change field and press Enter (or click Apply, the arrow at its right).",
|
|
68
68
|
"tools_triggered": "design.slate.create, design.slate.run, design.slate.data",
|
|
69
|
-
"expected_behavior": "The agent reads the request with design.slate.data and runs the 12ui draw command once
|
|
69
|
+
"expected_behavior": "A loading tile appears right after option A and fills in as version A2, from A, with a larger headline. The workspace runner draws it, or the agent reads the request with design.slate.data and runs the 12ui draw command once."
|
|
70
70
|
},
|
|
71
71
|
{
|
|
72
72
|
"description": "Search inspiration and steer a round",
|
|
73
|
-
"prompt": "Open a Design workspace for a travel booking site. When the
|
|
74
|
-
"tools_triggered": "design.slate.create, design.slate.
|
|
75
|
-
"expected_behavior": "
|
|
73
|
+
"prompt": "Open a Design workspace for a travel booking site. When the workspace appears on its Inspiration tab, click Continue. When the options appear, type 'minimal dashboard' in the Design prompt field above the tabs and click Search. In the Inspiration tab, click two references to select them, then click Generate in the tray below.",
|
|
74
|
+
"tools_triggered": "design.slate.create, design.slate.run, design.slate.inspire, design.slate.reference, design.slate.inspiration, design.slate.data",
|
|
75
|
+
"expected_behavior": "The Inspiration tab shows reference thumbnails for the search, and the two selected references show in the tray. After Generate the card moves to the Designs tab, where a new round of six options draws from the two references, which show in the round's heading."
|
|
76
76
|
},
|
|
77
77
|
{
|
|
78
|
-
"description": "
|
|
79
|
-
"prompt": "Open a Design workspace for a recipe app home screen. When the options appear,
|
|
80
|
-
"tools_triggered": "design.slate.create, design.slate.pick, design.slate.handoff, design.slate.data",
|
|
81
|
-
"expected_behavior": "
|
|
78
|
+
"description": "Build an option",
|
|
79
|
+
"prompt": "Open a Design workspace for a recipe app home screen. When the workspace appears on its Inspiration tab, click Continue. When the options appear, click option B to open it large and click Build this.",
|
|
80
|
+
"tools_triggered": "design.slate.create, design.slate.run, design.slate.pick, design.slate.handoff, design.slate.data",
|
|
81
|
+
"expected_behavior": "Option B shows a check and ring, and its button reads Building. The agent is told 'I chose design B. Build it.', reads the request with design.slate.data, saves option B's image and runs 12ui convert on it with the reviewer's own Codex, then adds the HTML page and its image files to the project. No 12ui account or sign-in is asked for."
|
|
82
82
|
}
|
|
83
83
|
],
|
|
84
84
|
"negative": [
|
|
@@ -100,55 +100,55 @@
|
|
|
100
100
|
"commerce_description": "This plugin has no paid features and no payment flow."
|
|
101
101
|
},
|
|
102
102
|
"publication": {
|
|
103
|
-
"release_notes": "
|
|
103
|
+
"release_notes": "1.0.3: reviewer cases match the current screen; the listing says branching asks for a 12ui sign-in.",
|
|
104
104
|
"translations": {
|
|
105
105
|
"es-419": {
|
|
106
|
-
"subtitle": "
|
|
107
|
-
"description": "
|
|
106
|
+
"subtitle": "Diseña tu UI y luego créala",
|
|
107
|
+
"description": "Diseña tu app o sitio web sin salir de Codex. Describe lo que quieres y se abre un espacio de trabajo de diseño en tu hilo con seis opciones dibujadas como imágenes reales, una al lado de la otra. Oriéntalas con diseño real: busca en la colección de 12ui de más de 20,000 diseños o elige entre capturas en vivo de sitios web reales sugeridos según tu descripción. Luego dale forma a la que te guste: pide más opciones, haz un garabato sobre una opción y di qué cambiar, o amplía un diseño a su página completa y al resto de tus pantallas con el mismo estilo.\n\nCuando un diseño te convenza, presiona “Crear esto”. En pocos minutos, 12ui convierte la imagen en código con tu propio Codex: un plan estructurado del diseño, los textos y los gráficos de la página, los gráficos extraídos como archivos de imagen reales y HTML adaptable con el que tu agente puede trabajar. Tu agente dedica su esfuerzo a integrar la página en tu proyecto, no a recrearla a partir de una imagen.\n\nTu agente de Codex ejecuta la herramienta de línea de comandos de 12ui una vez por solicitud. La herramienta dibuja todas las opciones a la vez con tu propio inicio de sesión de Codex y la generación de imágenes de Codex, y cada opción aparece en cuanto está lista; no se dibuja nada en el hilo. Dibujar, editar y “Crear esto” no requieren una cuenta de 12ui: a cada espacio de trabajo se accede mediante un identificador privado que se guarda en tu hilo. Para ampliar un diseño a más pantallas, se te pedirá iniciar sesión en 12ui. Las imágenes se guardan hasta 30 días y se eliminan después de 14 días sin uso.\n\nFunciona en Codex en una computadora con Node.js; tu agente instala la herramienta de línea de comandos de 12ui una sola vez. El comando draw se ejecuta fuera del sandbox, con acceso de red a design.12ui.com, algo que Codex puede pedirte que apruebes."
|
|
108
108
|
},
|
|
109
109
|
"es-ES": {
|
|
110
|
-
"subtitle": "
|
|
111
|
-
"description": "
|
|
110
|
+
"subtitle": "Diseña tu UI y después créala",
|
|
111
|
+
"description": "Diseña tu app o tu web sin salir de Codex. Describe lo que quieres y se abre un espacio de trabajo de diseño en tu hilo con seis opciones dibujadas como imágenes reales, una junto a otra. Oriéntalas con diseño real: busca en la colección de 12ui de más de 20.000 diseños o elige entre capturas en directo de webs reales sugeridas a partir de tu descripción. Después, da forma a la que te guste: pide más opciones, haz un garabato sobre una opción y di qué cambiar, o amplía un diseño a su página completa y al resto de tus pantallas con el mismo estilo.\n\nCuando un diseño te convenza, pulsa «Crear esto». En pocos minutos, 12ui convierte la imagen en código con tu propio Codex: un plan estructurado de la maquetación, los textos y los gráficos de la página, los gráficos extraídos como archivos de imagen reales y HTML adaptable con el que tu agente puede trabajar. Tu agente dedica su esfuerzo a integrar la página en tu proyecto, no a recrearla a partir de una imagen.\n\nTu agente de Codex ejecuta la herramienta de línea de comandos de 12ui una vez por solicitud. La herramienta dibuja todas las opciones a la vez con tu propio inicio de sesión de Codex y la generación de imágenes de Codex, y cada opción aparece en cuanto está lista; no se dibuja nada en el hilo. Dibujar, editar y «Crear esto» no requieren una cuenta de 12ui: a cada espacio de trabajo se accede mediante un identificador privado que se guarda en tu hilo. Para ampliar un diseño a más pantallas, se te pedirá que inicies sesión en 12ui. Las imágenes se guardan hasta 30 días y se eliminan tras 14 días sin uso.\n\nFunciona en Codex en un ordenador con Node.js; tu agente instala la herramienta de línea de comandos de 12ui una sola vez. El comando draw se ejecuta fuera del sandbox, con acceso de red a design.12ui.com, algo que Codex puede pedirte que apruebes."
|
|
112
112
|
},
|
|
113
113
|
"fr-FR": {
|
|
114
|
-
"subtitle": "
|
|
115
|
-
"description": "
|
|
114
|
+
"subtitle": "Concevez puis créez votre UI",
|
|
115
|
+
"description": "Concevez votre app ou votre site web sans quitter Codex. Décrivez ce que vous voulez : un espace de travail de design s’ouvre dans votre fil avec six options dessinées sous forme de vraies images, côte à côte. Orientez-les avec du vrai design : recherchez parmi plus de 20 000 designs de la collection 12ui, ou choisissez parmi des captures en direct de vrais sites web suggérés pour votre brief. Façonnez ensuite celle qui vous plaît : demandez d’autres options, gribouillez sur une option et dites ce qu’il faut changer, ou étendez un design à sa page complète et au reste de vos écrans, dans le même style.\n\nQuand un design vous convient, appuyez sur « Construire ceci ». En quelques minutes, 12ui transforme l’image en code avec votre propre Codex : un plan structuré de la mise en page, des textes et des visuels de la page, les visuels extraits sous forme de vrais fichiers image, et du HTML responsive avec lequel votre agent peut travailler. Votre agent consacre ses efforts à intégrer la page à votre projet, pas à la recréer à partir d’une image.\n\nVotre agent Codex exécute l’outil en ligne de commande 12ui une fois par demande. Celui-ci dessine toutes les options en même temps avec votre propre session Codex et la génération d’images de Codex, et chaque option apparaît dès qu’elle est prête ; rien n’est dessiné dans le fil. Dessiner, modifier et « Construire ceci » ne demandent aucun compte 12ui : on accède à un espace de travail grâce à un identifiant privé conservé dans votre fil. Pour étendre un design à d’autres écrans, il vous sera demandé de vous connecter à 12ui. Les images sont conservées jusqu’à 30 jours et supprimées après 14 jours sans utilisation.\n\nFonctionne dans Codex sur un ordinateur équipé de Node.js ; votre agent installe l’outil en ligne de commande 12ui une seule fois. La commande draw s’exécute hors du bac à sable, avec un accès réseau à design.12ui.com, ce que Codex peut vous demander d’approuver."
|
|
116
116
|
},
|
|
117
117
|
"fr-CA": {
|
|
118
|
-
"subtitle": "
|
|
119
|
-
"description": "
|
|
118
|
+
"subtitle": "Concevez puis créez votre UI",
|
|
119
|
+
"description": "Concevez votre application ou votre site Web sans quitter Codex. Décrivez ce que vous voulez : un espace de travail de design s’ouvre dans votre fil avec six options dessinées sous forme de vraies images, côte à côte. Orientez-les avec du vrai design : cherchez parmi plus de 20 000 designs de la collection 12ui, ou choisissez parmi des captures d’écran en direct de vrais sites Web suggérés selon votre demande. Peaufinez ensuite celle qui vous plaît : demandez d’autres options, gribouillez sur une option et indiquez ce qu’il faut changer, ou étendez un design à sa page complète et au reste de vos écrans, dans le même style.\n\nQuand un design vous convient, cliquez sur « Construire ceci ». En quelques minutes, 12ui transforme l’image en code avec votre propre Codex : un plan structuré de la mise en page, des textes et des visuels de la page, les visuels extraits sous forme de vrais fichiers image, et du HTML adaptatif avec lequel votre agent peut travailler. Votre agent consacre ses efforts à intégrer la page à votre projet, plutôt qu’à la recréer à partir d’une image.\n\nVotre agent Codex exécute l’outil en ligne de commande 12ui une fois par demande. Celui-ci dessine toutes les options en même temps avec votre propre session Codex et la génération d’images de Codex, et chaque option apparaît dès qu’elle est prête; rien n’est dessiné dans le fil. Dessiner, modifier et « Construire ceci » ne demandent aucun compte 12ui : on accède à un espace de travail grâce à un identifiant privé conservé dans votre fil. Pour étendre un design à d’autres écrans, il vous sera demandé de vous connecter à 12ui. Les images sont conservées jusqu’à 30 jours et supprimées après 14 jours sans utilisation.\n\nFonctionne dans Codex sur un ordinateur équipé de Node.js; votre agent installe l’outil en ligne de commande 12ui une seule fois. La commande draw s’exécute hors du bac à sable, avec un accès réseau à design.12ui.com, ce que Codex peut vous demander d’approuver."
|
|
120
120
|
},
|
|
121
121
|
"de-DE": {
|
|
122
|
-
"subtitle": "
|
|
123
|
-
"description": "
|
|
122
|
+
"subtitle": "UI gestalten, dann umsetzen",
|
|
123
|
+
"description": "Gestalte deine App oder Website, ohne Codex zu verlassen. Beschreibe, was du willst, und in deinem Thread öffnet sich ein Design-Workspace mit sechs Optionen, gezeichnet als echte Bilder und nebeneinander gezeigt. Lenke sie mit echtem Design: Durchsuche die 12ui-Sammlung mit mehr als 20.000 Designs oder wähle aus Live-Screenshots echter Websites, die passend zu deinem Briefing vorgeschlagen werden. Forme dann die Option, die dir gefällt: Fordere weitere Optionen an, kritzle auf eine Option und sag, was sich ändern soll, oder erweitere ein Design zu seiner vollständigen Seite und zu deinen übrigen Screens im selben Stil.\n\nWenn ein Design passt, klicke auf „Das erstellen“. In wenigen Minuten macht 12ui mit deinem eigenen Codex aus dem Bild Code: einen strukturierten Plan von Layout, Text und Grafiken der Seite, die Grafiken als echte Bilddateien extrahiert und responsives HTML, mit dem dein Agent arbeiten kann. Dein Agent konzentriert sich darauf, die Seite in dein Projekt einzubauen, statt sie aus einem Bild nachzubauen.\n\nDein Codex-Agent führt das 12ui-Befehlszeilentool einmal pro Anfrage aus. Es zeichnet alle Optionen auf einmal mit deiner eigenen Codex-Anmeldung und der Bildgenerierung von Codex, und jede Option erscheint, sobald sie fertig ist; im Thread wird nichts gezeichnet. Zeichnen, Bearbeiten und „Das erstellen“ brauchen kein 12ui-Konto: Ein Workspace wird über eine private Kennung erreicht, die in deinem Thread gespeichert ist. Wenn du ein Design auf weitere Screens erweiterst, wirst du gebeten, dich bei 12ui anzumelden. Bilder werden bis zu 30 Tage gespeichert und nach 14 Tagen ohne Nutzung entfernt.\n\nFunktioniert in Codex auf einem Computer mit Node.js; dein Agent installiert das 12ui-Befehlszeilentool einmalig. Der draw-Befehl läuft außerhalb der Sandbox mit Netzwerkzugriff auf design.12ui.com; Codex bittet dich dafür möglicherweise um Freigabe."
|
|
124
124
|
},
|
|
125
125
|
"it-IT": {
|
|
126
|
-
"subtitle": "
|
|
127
|
-
"description": "
|
|
126
|
+
"subtitle": "Progetta la tua UI, poi creala",
|
|
127
|
+
"description": "Progetta la tua app o il tuo sito web senza uscire da Codex. Descrivi ciò che vuoi e nel tuo thread si apre uno spazio di lavoro di design con sei opzioni disegnate come immagini reali, una accanto all’altra. Orientale con design reali: cerca nella raccolta di 12ui con oltre 20.000 design, oppure scegli tra screenshot dal vivo di siti web reali suggeriti in base alla tua richiesta. Poi dai forma a quella che ti piace: chiedi altre opzioni, scarabocchia su un’opzione e di’ cosa cambiare, oppure espandi un design nella sua pagina completa e nelle altre schermate, nello stesso stile.\n\nQuando un design ti convince, premi «Crea questo». In pochi minuti 12ui trasforma l’immagine in codice con il tuo Codex: un piano strutturato di layout, testi e grafica della pagina, la grafica estratta come veri file immagine e HTML responsive con cui il tuo agente può lavorare. Il tuo agente dedica il suo impegno a inserire la pagina nel tuo progetto, non a ricrearla partendo da un’immagine.\n\nIl tuo agente Codex esegue lo strumento da riga di comando 12ui una volta per richiesta. Lo strumento disegna tutte le opzioni contemporaneamente con il tuo accesso a Codex e la generazione di immagini di Codex, e ogni opzione compare non appena è pronta; nel thread non viene disegnato nulla. Disegnare, modificare e «Crea questo» non richiedono un account 12ui: uno spazio di lavoro si raggiunge tramite un identificativo privato conservato nel tuo thread. Per espandere un design in altre schermate ti verrà chiesto di accedere a 12ui. Le immagini vengono conservate fino a 30 giorni ed eliminate dopo 14 giorni di inutilizzo.\n\nFunziona in Codex su un computer con Node.js; il tuo agente installa lo strumento da riga di comando 12ui una sola volta. Il comando draw viene eseguito fuori dalla sandbox, con accesso di rete a design.12ui.com, e Codex potrebbe chiederti di approvarlo."
|
|
128
128
|
},
|
|
129
129
|
"pt-BR": {
|
|
130
|
-
"subtitle": "
|
|
131
|
-
"description": "
|
|
130
|
+
"subtitle": "Projete a UI e depois construa",
|
|
131
|
+
"description": "Projete seu app ou site sem sair do Codex. Descreva o que você quer e um espaço de trabalho de design se abre na sua thread com seis opções desenhadas como imagens reais, lado a lado. Oriente as opções com design real: pesquise na coleção do 12ui com mais de 20.000 designs ou escolha entre capturas de tela ao vivo de sites reais sugeridos para o seu briefing. Depois, refine a que você preferir: peça mais opções, rabisque sobre uma opção e diga o que mudar, ou expanda um design para a página completa e para o restante das suas telas no mesmo estilo.\n\nQuando um design estiver do jeito certo, clique em “Criar isto”. Em poucos minutos, o 12ui transforma a imagem em código com o seu próprio Codex: um plano estruturado do layout, dos textos e das artes da página, as artes extraídas como arquivos de imagem reais e HTML responsivo com o qual seu agente pode trabalhar. Seu agente dedica o esforço a encaixar a página no seu projeto, e não a recriá-la a partir de uma imagem.\n\nSeu agente do Codex executa a ferramenta de linha de comando do 12ui uma vez por pedido. Ela desenha todas as opções de uma só vez com seu próprio login do Codex e a geração de imagens do Codex, e cada opção aparece assim que fica pronta; nada é desenhado na thread. Desenhar, editar e “Criar isto” não exigem conta do 12ui: um espaço de trabalho é acessado por meio de um identificador privado guardado na sua thread. Para expandir um design em mais telas, será pedido que você entre no 12ui. As imagens ficam armazenadas por até 30 dias e são removidas após 14 dias sem uso.\n\nFunciona no Codex em um computador com Node.js; seu agente instala a ferramenta de linha de comando do 12ui uma única vez. O comando draw é executado fora do sandbox, com acesso de rede a design.12ui.com, e o Codex pode pedir que você aprove isso."
|
|
132
132
|
},
|
|
133
133
|
"ja-JP": {
|
|
134
|
-
"subtitle": "
|
|
135
|
-
"description": "Codex
|
|
134
|
+
"subtitle": "UIをデザインして、そのまま実装",
|
|
135
|
+
"description": "Codexを離れずに、アプリやWebサイトをデザインできます。作りたいものを伝えると、スレッド内にデザインワークスペースが開き、実際の画像として描かれた6案が並んで表示されます。本物のデザインを手がかりに方向性を決めましょう。12uiの2万点を超えるデザインコレクションを検索したり、依頼内容に合わせて提案された実在のWebサイトのライブスクリーンショットから選んだりできます。気に入った案は、追加の案を依頼する、案に手書きで書き込んで変更点を伝える、デザインをページ全体や同じスタイルの残りの画面へ展開する、といった形で仕上げられます。\n\nデザインが決まったら「これをビルド」を押します。数分で12uiが、あなた自身のCodexを使って画像をコードに変換します。ページのレイアウト、テキスト、アートワークをまとめた構造化プラン、実際の画像ファイルとして切り出したアートワーク、そしてエージェントがそのまま扱えるレスポンシブHTMLが手に入ります。エージェントは画像からページを作り直すのではなく、ページをプロジェクトに組み込むことに力を注げます。\n\nCodexエージェントはリクエストごとに12uiのコマンドラインツールを1回実行します。このツールは、あなた自身のCodexのサインインと画像生成を使ってすべての案を一度に描き、各案は完成した時点で表示されます。スレッド内で描かれるものはありません。描画、編集、「これをビルド」には12uiのアカウントは不要です。ワークスペースには、スレッド内に保持される非公開の識別子でアクセスします。デザインをさらに多くの画面へ展開するときは、12uiへのサインインを求められます。画像は最大30日間保存され、14日間使われないと削除されます。\n\nNode.jsが入ったコンピューター上のCodexで動作します。エージェントが12uiのコマンドラインツールを一度だけインストールします。drawコマンドはサンドボックスの外で実行され、design.12ui.comへのネットワークアクセスを伴います。これについてCodexから承認を求められる場合があります。"
|
|
136
136
|
},
|
|
137
137
|
"ko-KR": {
|
|
138
|
-
"subtitle": "
|
|
139
|
-
"description": "Codex
|
|
138
|
+
"subtitle": "UI를 디자인하고 바로 구현하세요",
|
|
139
|
+
"description": "Codex를 벗어나지 않고 앱이나 웹사이트를 디자인하세요. 원하는 것을 설명하면 스레드에 디자인 워크스페이스가 열리고, 실제 이미지로 그려진 시안 6개가 나란히 표시됩니다. 실제 디자인으로 방향을 잡으세요. 2만 개가 넘는 12ui 디자인 컬렉션을 검색하거나, 요청 내용에 맞춰 추천된 실제 웹사이트의 라이브 스크린샷 중에서 고를 수 있습니다. 그런 다음 마음에 드는 시안을 다듬으세요. 시안을 더 요청하거나, 시안 위에 직접 그리고 바꿀 점을 말하거나, 디자인을 전체 페이지와 같은 스타일의 나머지 화면으로 확장할 수 있습니다.\n\n디자인이 마음에 들면 '이걸로 빌드'를 누르세요. 몇 분 안에 12ui가 내 Codex로 이미지를 코드로 바꿉니다. 페이지의 레이아웃, 텍스트, 아트워크를 담은 구조화된 계획, 실제 이미지 파일로 추출된 아트워크, 그리고 에이전트가 바로 작업할 수 있는 반응형 HTML이 제공됩니다. 에이전트는 그림을 보고 페이지를 다시 만드는 대신, 페이지를 프로젝트에 맞춰 넣는 데 힘을 쏟습니다.\n\nCodex 에이전트는 요청마다 12ui 명령줄 도구를 한 번 실행합니다. 이 도구는 내 Codex 로그인과 이미지 생성 기능으로 모든 시안을 한꺼번에 그리며, 각 시안은 준비되는 즉시 나타납니다. 스레드 안에서는 아무것도 그리지 않습니다. 그리기, 편집, '이걸로 빌드'에는 12ui 계정이 필요 없습니다. 워크스페이스에는 스레드에 보관된 비공개 식별자로 접근합니다. 디자인을 더 많은 화면으로 확장할 때는 12ui에 로그인하라는 요청이 표시됩니다. 이미지는 최대 30일간 저장되며, 14일 동안 사용하지 않으면 삭제됩니다.\n\nNode.js가 설치된 컴퓨터의 Codex에서 작동하며, 에이전트가 12ui 명령줄 도구를 한 번만 설치합니다. draw 명령은 샌드박스 밖에서 실행되고 design.12ui.com에 네트워크로 접근하며, Codex가 이에 대한 승인을 요청할 수 있습니다."
|
|
140
140
|
},
|
|
141
141
|
"zh-CN": {
|
|
142
|
-
"subtitle": "
|
|
143
|
-
"description": "
|
|
142
|
+
"subtitle": "先设计你的 UI,再把它构建出来",
|
|
143
|
+
"description": "无需离开 Codex,即可设计你的应用或网站。描述你想要的效果,对话中就会打开设计工作区,以真实图片并排展示六个方案。用真实的设计引导方向:搜索 12ui 收录的超过 2 万个设计,或从根据你的需求推荐的真实网站实时截图中挑选。然后打磨你喜欢的方案:请求更多方案,在方案上涂鸦并说明要改什么,或将设计扩展为完整页面,并以相同风格生成其余界面。\n\n对设计满意后,点击“构建此设计”。几分钟内,12ui 就会用你自己的 Codex 把图片变成代码:涵盖页面布局、文字和图形素材的结构化规划,提取为真实图片文件的图形素材,以及你的智能体可以直接使用的响应式 HTML。你的智能体可以把精力放在将页面融入你的项目上,而不是照着图片重新制作。\n\n你的 Codex 智能体每次请求时运行一次 12ui 命令行工具。该工具使用你自己的 Codex 登录和图像生成能力,一次性绘制所有方案,每个方案一完成就会显示出来;对话中不会绘制任何内容。绘制、编辑和“构建此设计”都无需 12ui 账号:工作区通过保存在你对话中的私有标识访问。将设计扩展到更多界面时,会请你登录 12ui。图片最多保存 30 天,连续 14 天未使用即会删除。\n\n可在装有 Node.js 的电脑上的 Codex 中使用;你的智能体只需安装一次 12ui 命令行工具。draw 命令在沙箱外运行,并通过网络访问 design.12ui.com,Codex 可能会请你批准。"
|
|
144
144
|
},
|
|
145
145
|
"zh-TW": {
|
|
146
|
-
"subtitle": "
|
|
147
|
-
"description": "
|
|
146
|
+
"subtitle": "先設計你的 UI,再把它建置出來",
|
|
147
|
+
"description": "不必離開 Codex,就能設計你的 App 或網站。描述你想要的效果,對話中就會開啟設計工作區,以真實圖片並排呈現六個方案。用真實的設計引導方向:搜尋 12ui 收錄的超過 2 萬個設計,或從依你的需求推薦的真實網站即時截圖中挑選。接著雕琢你喜歡的方案:要求更多方案、在方案上塗鴉並說明要改什麼,或將設計擴充為完整頁面,並以相同風格產生其餘畫面。\n\n對設計滿意後,按下「建置此設計」。幾分鐘內,12ui 就會用你自己的 Codex 把圖片轉成程式碼:涵蓋頁面版面、文字與圖像素材的結構化規劃、擷取為真實圖檔的圖像素材,以及你的代理程式可以直接運用的響應式 HTML。你的代理程式能把心力放在將頁面整合進你的專案,而不是照著圖片重做。\n\n你的 Codex 代理程式每次收到請求時會執行一次 12ui 命令列工具。該工具使用你自己的 Codex 登入與影像生成功能,一次繪製所有方案,每個方案一完成就會顯示;對話中不會繪製任何內容。繪製、編輯和「建置此設計」都不需要 12ui 帳號:工作區透過保存在你對話中的私密識別碼存取。將設計擴充到更多畫面時,會請你登入 12ui。圖片最多保存 30 天,連續 14 天未使用即會刪除。\n\n可在安裝了 Node.js 的電腦上的 Codex 中使用;你的代理程式只需安裝一次 12ui 命令列工具。draw 指令會在沙箱外執行,並透過網路存取 design.12ui.com,Codex 可能會請你核准。"
|
|
148
148
|
},
|
|
149
149
|
"hi-IN": {
|
|
150
|
-
"subtitle": "
|
|
151
|
-
"description": "अपने
|
|
150
|
+
"subtitle": "UI डिज़ाइन करें, फिर बनाएँ",
|
|
151
|
+
"description": "Codex छोड़े बिना अपने ऐप या वेबसाइट का डिज़ाइन बनाएँ। बताएँ कि आपको क्या चाहिए, और आपके थ्रेड में एक डिज़ाइन वर्कस्पेस खुल जाता है, जिसमें असली इमेज के रूप में बनाए गए छह विकल्प साथ-साथ दिखते हैं। असली डिज़ाइन से उन्हें दिशा दें: 12ui के 20,000 से ज़्यादा डिज़ाइनों के संग्रह में खोजें, या आपके ब्रीफ़ के लिए सुझाई गई असली वेबसाइटों के लाइव स्क्रीनशॉट में से चुनें। फिर जो विकल्प पसंद आए उसे निखारें: और विकल्प माँगें, किसी विकल्प पर स्क्रिबल करके बताएँ कि क्या बदलना है, या किसी डिज़ाइन को उसके पूरे पेज और उसी स्टाइल में आपकी बाकी स्क्रीनों तक विस्तार दें।\n\nजब कोई डिज़ाइन सही लगे, तो “इसे बनाएँ” दबाएँ। कुछ ही मिनटों में 12ui आपके अपने Codex से इमेज को कोड में बदल देता है: पेज के लेआउट, टेक्स्ट और आर्टवर्क की एक संरचित योजना, असली इमेज फ़ाइलों के रूप में निकाला गया आर्टवर्क, और रिस्पॉन्सिव HTML जिस पर आपका एजेंट काम कर सकता है। आपका एजेंट तस्वीर से पेज दोबारा बनाने के बजाय उसे आपके प्रोजेक्ट में फ़िट करने पर ध्यान देता है।\n\nआपका Codex एजेंट हर अनुरोध पर 12ui कमांड लाइन टूल को एक बार चलाता है। यह टूल आपके अपने Codex साइन-इन और इमेज जनरेशन से सभी विकल्प एक साथ बनाता है, और हर विकल्प तैयार होते ही दिख जाता है; थ्रेड में कुछ भी नहीं बनाया जाता। ड्रॉ करने, एडिट करने और “इसे बनाएँ” के लिए 12ui खाते की ज़रूरत नहीं है: वर्कस्पेस तक आपके थ्रेड में रखे एक निजी पहचानकर्ता के ज़रिए पहुँचा जाता है। किसी डिज़ाइन को और स्क्रीनों तक विस्तार देने पर आपसे 12ui में साइन इन करने को कहा जाता है। इमेज अधिकतम 30 दिनों तक रखी जाती हैं और 14 दिनों तक इस्तेमाल न होने पर हटा दी जाती हैं।\n\nNode.js वाले कंप्यूटर पर Codex में काम करता है; आपका एजेंट 12ui कमांड लाइन टूल को एक बार इंस्टॉल करता है। draw कमांड सैंडबॉक्स के बाहर चलती है और उसे design.12ui.com तक नेटवर्क एक्सेस मिलता है। Codex इसके लिए आपसे मंज़ूरी माँग सकता है।"
|
|
152
152
|
}
|
|
153
153
|
}
|
|
154
154
|
}
|
|
@@ -10,11 +10,6 @@ export declare const authOnboardingMessage: (options?: {
|
|
|
10
10
|
failure?: AuthOnboardingFailure;
|
|
11
11
|
staticFallback?: boolean;
|
|
12
12
|
}) => string;
|
|
13
|
-
export declare const printAuthOnboarding: (options?: {
|
|
14
|
-
approvalUrl?: string;
|
|
15
|
-
failure?: AuthOnboardingFailure;
|
|
16
|
-
staticFallback?: boolean;
|
|
17
|
-
}) => void;
|
|
18
13
|
export declare class MissingTwelveUiCredentialError extends Error {
|
|
19
14
|
readonly journalErrorClass?: string;
|
|
20
15
|
constructor(options?: string | {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cli-auth-onboarding.d.ts","sourceRoot":"","sources":["../src/cli-auth-onboarding.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,yBAAyB,iCAAiC,CAAC;AAExE,MAAM,MAAM,qBAAqB,GAAG;IAClC,UAAU,EAAE,MAAM,CAAC;IACnB,MAAM,EAAE,MAAM,CAAC;IACf,KAAK,EAAE,kBAAkB,GAAG,yBAAyB,CAAC;CACvD,CAAC;AAsBF,eAAO,MAAM,qBAAqB,GAAI,UAAS;IAC7C,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,OAAO,CAAC,EAAE,qBAAqB,CAAC;IAChC,cAAc,CAAC,EAAE,OAAO,CAAC;CACrB,KAAG,MAcR,CAAC;AAEF,
|
|
1
|
+
{"version":3,"file":"cli-auth-onboarding.d.ts","sourceRoot":"","sources":["../src/cli-auth-onboarding.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,yBAAyB,iCAAiC,CAAC;AAExE,MAAM,MAAM,qBAAqB,GAAG;IAClC,UAAU,EAAE,MAAM,CAAC;IACnB,MAAM,EAAE,MAAM,CAAC;IACf,KAAK,EAAE,kBAAkB,GAAG,yBAAyB,CAAC;CACvD,CAAC;AAsBF,eAAO,MAAM,qBAAqB,GAAI,UAAS;IAC7C,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,OAAO,CAAC,EAAE,qBAAqB,CAAC;IAChC,cAAc,CAAC,EAAE,OAAO,CAAC;CACrB,KAAG,MAcR,CAAC;AAEF,qBAAa,8BAA+B,SAAQ,KAAK;IACvD,QAAQ,CAAC,iBAAiB,CAAC,EAAE,MAAM,CAAC;gBAExB,OAAO,GAAE,MAAM,GAAG;QAC5B,WAAW,CAAC,EAAE,MAAM,CAAC;QACrB,OAAO,CAAC,EAAE,qBAAqB,CAAC;QAChC,cAAc,CAAC,EAAE,OAAO,CAAC;KACrB;CAWP"}
|
|
@@ -30,14 +30,6 @@ export const authOnboardingMessage = (options = {}) => {
|
|
|
30
30
|
: 'Agent: Give this coded link to your user, then retry after they approve it.',
|
|
31
31
|
].join('\n');
|
|
32
32
|
};
|
|
33
|
-
export const printAuthOnboarding = (options = {}) => {
|
|
34
|
-
for (const line of ownerAuthOnboardingLines({
|
|
35
|
-
approvalUrl: options.approvalUrl ?? TWELVE_UI_CONNECT_CLI_URL,
|
|
36
|
-
staticFallback: options.staticFallback,
|
|
37
|
-
failure: options.failure,
|
|
38
|
-
}))
|
|
39
|
-
console.log(line);
|
|
40
|
-
};
|
|
41
33
|
export class MissingTwelveUiCredentialError extends Error {
|
|
42
34
|
journalErrorClass;
|
|
43
35
|
constructor(options = {}) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cli-auth-onboarding.js","sourceRoot":"","sources":["../src/cli-auth-onboarding.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,MAAM,yBAAyB,GAAG,8BAA8B,CAAC;AAQxE,MAAM,wBAAwB,GAAG,CAAC,OAIjC,EAAqB,EAAE;IACtB,IAAI,OAAO,CAAC,cAAc,EAAE,CAAC;QAC3B,OAAO;YACL,OAAO,CAAC,OAAO,EAAE,MAAM;mBAClB,4GAA4G;YACjH,gEAAgE;YAChE,wBAAwB,OAAO,CAAC,WAAW,4DAA4D;SACxG,CAAC;IACJ,CAAC;IACD,OAAO;QACL,mDAAmD,OAAO,CAAC,WAAW,EAAE;QACxE,gDAAgD;QAChD,GAAG,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,OAAO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AAC,MAAM,qBAAqB,GAAG,CAAC,UAKlC,EAAE,EAAU,EAAE;IAChB,MAAM,WAAW,GAAG,OAAO,CAAC,WAAW,IAAI,yBAAyB,CAAC;IACrE,MAAM,KAAK,GAAG,wBAAwB,CAAC;QACrC,WAAW;QACX,cAAc,EAAE,OAAO,CAAC,cAAc;QACtC,OAAO,EAAE,OAAO,CAAC,OAAO;KACzB,CAAC,CAAC;IACH,IAAI,CAAC,OAAO,CAAC,WAAW;QAAE,OAAO,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IAClD,OAAO;QACL,GAAG,KAAK;QACR,OAAO,CAAC,cAAc;YACpB,CAAC,CAAC,oHAAoH;YACtH,CAAC,CAAC,6EAA6E;KAClF,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;AACf,CAAC,CAAC;AAEF,MAAM,OAAO,8BAA+B,SAAQ,KAAK;IAC9C,iBAAiB,CAAU;IAEpC,YAAY,UAIR,EAAE;QACJ,MAAM,UAAU,GAAG,OAAO,OAAO,KAAK,QAAQ,CAAC,CAAC,CAAC,EAAE,WAAW,EAAE,OAAO,EAAE,CAAC,CAAC,CAAC,OAAO,CAAC;QACpF,KAAK,CAAC,qBAAqB,CAAC;YAC1B,WAAW,EAAE,IAAI;YACjB,WAAW,EAAE,UAAU,CAAC,WAAW;YACnC,OAAO,EAAE,UAAU,CAAC,OAAO;YAC3B,cAAc,EAAE,UAAU,CAAC,cAAc;SAC1C,CAAC,CAAC,CAAC;QACJ,IAAI,CAAC,IAAI,GAAG,gCAAgC,CAAC;QAC7C,IAAI,CAAC,iBAAiB,GAAG,UAAU,CAAC,OAAO,EAAE,UAAU,CAAC;IAC1D,CAAC;CACF"}
|
|
@@ -1,15 +1,14 @@
|
|
|
1
1
|
import { type CliFlags } from './cli-arguments.js';
|
|
2
|
-
import { prepareAuthOnboardingLink } from './cli-pending-auth.js';
|
|
3
2
|
import { type CliPersistenceResult, type PinnedCliSnapshot } from './cli-persistence.js';
|
|
4
3
|
export type CliCommandDependencies = {
|
|
5
|
-
hasCredentials?: (apiKeyOverride?: string) => boolean;
|
|
6
4
|
persistCli?: () => Promise<CliPersistenceResult>;
|
|
7
|
-
prepareOnboarding?: typeof prepareAuthOnboardingLink;
|
|
8
5
|
readPinned?: () => Promise<PinnedCliSnapshot>;
|
|
9
6
|
};
|
|
10
7
|
/**
|
|
11
8
|
* `12ui cli` installs and reports the pinned CLI binary and nothing else: no
|
|
12
|
-
* skills are written and no
|
|
9
|
+
* skills are written, no sign-in is started and no link is printed. It is the
|
|
10
|
+
* skill's first step, and the Design workspace flow needs no 12ui account, so a
|
|
11
|
+
* sign-in is asked for only by a hosted operation that needs one, when it runs. It shares `persistCurrentCli`
|
|
13
12
|
* with `skill install`, so both routes produce byte-identical installations —
|
|
14
13
|
* the difference is only what else the surrounding command does.
|
|
15
14
|
*
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cli-cli-command.d.ts","sourceRoot":"","sources":["../src/cli-cli-command.ts"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"cli-cli-command.d.ts","sourceRoot":"","sources":["../src/cli-cli-command.ts"],"names":[],"mappings":"AAAA,OAAO,EAAe,KAAK,QAAQ,EAAE,MAAM,oBAAoB,CAAC;AAChE,OAAO,EAGL,KAAK,oBAAoB,EACzB,KAAK,iBAAiB,EACvB,MAAM,sBAAsB,CAAC;AAI9B,MAAM,MAAM,sBAAsB,GAAG;IACnC,UAAU,CAAC,EAAE,MAAM,OAAO,CAAC,oBAAoB,CAAC,CAAC;IACjD,UAAU,CAAC,EAAE,MAAM,OAAO,CAAC,iBAAiB,CAAC,CAAC;CAC/C,CAAC;AAkBF;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,aAAa,GACxB,QAAQ,MAAM,GAAG,SAAS,EAC1B,OAAO,QAAQ,EACf,eAAc,sBAA2B,KACxC,OAAO,CAAC,IAAI,CAqBd,CAAC"}
|
package/dist/cli-cli-command.js
CHANGED
|
@@ -1,7 +1,4 @@
|
|
|
1
|
-
import { booleanFlag
|
|
2
|
-
import { printAuthOnboarding } from './cli-auth-onboarding.js';
|
|
3
|
-
import { prepareAuthOnboardingLink } from './cli-pending-auth.js';
|
|
4
|
-
import { hasConfiguredConversionCredential } from './config.js';
|
|
1
|
+
import { booleanFlag } from './cli-arguments.js';
|
|
5
2
|
import { persistCurrentCli, readPinnedCli, } from './cli-persistence.js';
|
|
6
3
|
import { cliPersistenceLines } from './cli-persistence-report.js';
|
|
7
4
|
import { usageRefusal } from './cli-usage.js';
|
|
@@ -22,7 +19,9 @@ const printStatus = (snapshot, json) => {
|
|
|
22
19
|
};
|
|
23
20
|
/**
|
|
24
21
|
* `12ui cli` installs and reports the pinned CLI binary and nothing else: no
|
|
25
|
-
* skills are written and no
|
|
22
|
+
* skills are written, no sign-in is started and no link is printed. It is the
|
|
23
|
+
* skill's first step, and the Design workspace flow needs no 12ui account, so a
|
|
24
|
+
* sign-in is asked for only by a hosted operation that needs one, when it runs. It shares `persistCurrentCli`
|
|
26
25
|
* with `skill install`, so both routes produce byte-identical installations —
|
|
27
26
|
* the difference is only what else the surrounding command does.
|
|
28
27
|
*
|
|
@@ -53,21 +52,6 @@ export const runCliCommand = async (action, flags, dependencies = {}) => {
|
|
|
53
52
|
});
|
|
54
53
|
for (const line of lines)
|
|
55
54
|
console.log(line);
|
|
56
|
-
console.log('No skills were installed
|
|
57
|
-
const hasCredentials = dependencies.hasCredentials ?? hasConfiguredConversionCredential;
|
|
58
|
-
if (hasCredentials(stringFlag(flags, 'api-key'))) {
|
|
59
|
-
console.log('Next: 12ui auth login to connect an account, then 12ui skill install'
|
|
60
|
-
+ ' for the agent skills.');
|
|
61
|
-
return;
|
|
62
|
-
}
|
|
63
|
-
const onboarding = await (dependencies.prepareOnboarding ?? prepareAuthOnboardingLink)({
|
|
64
|
-
origin: stringFlag(flags, 'origin'),
|
|
65
|
-
loginOrigin: stringFlag(flags, 'login-origin'),
|
|
66
|
-
});
|
|
67
|
-
printAuthOnboarding({
|
|
68
|
-
approvalUrl: onboarding.approvalUrl,
|
|
69
|
-
failure: onboarding.failure,
|
|
70
|
-
staticFallback: onboarding.source === 'static',
|
|
71
|
-
});
|
|
55
|
+
console.log('No skills were installed. Sign-in is needed only for hosted 12ui features.');
|
|
72
56
|
};
|
|
73
57
|
//# sourceMappingURL=cli-cli-command.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cli-cli-command.js","sourceRoot":"","sources":["../src/cli-cli-command.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,
|
|
1
|
+
{"version":3,"file":"cli-cli-command.js","sourceRoot":"","sources":["../src/cli-cli-command.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAiB,MAAM,oBAAoB,CAAC;AAChE,OAAO,EACL,iBAAiB,EACjB,aAAa,GAGd,MAAM,sBAAsB,CAAC;AAC9B,OAAO,EAAE,mBAAmB,EAAE,MAAM,6BAA6B,CAAC;AAClE,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAO9C,MAAM,WAAW,GAAG,CAAC,QAA2B,EAAE,IAAa,EAAQ,EAAE;IACvE,IAAI,IAAI,EAAE,CAAC;QACT,OAAO,CAAC,GAAG,CAAC,IAAI,CAAC,SAAS,CAAC;YACzB,aAAa,EAAE,CAAC;YAChB,OAAO,EAAE,QAAQ,CAAC,OAAO;YACzB,QAAQ,EAAE,QAAQ,CAAC,QAAQ;YAC3B,QAAQ,EAAE,QAAQ,CAAC,QAAQ;SAC5B,EAAE,IAAI,EAAE,CAAC,CAAC,CAAC,CAAC;QACb,OAAO;IACT,CAAC;IACD,OAAO,CAAC,GAAG,CAAC,QAAQ,CAAC,OAAO,KAAK,IAAI;QACnC,CAAC,CAAC,oCAAoC,QAAQ,CAAC,QAAQ,yBAAyB;QAChF,CAAC,CAAC,gBAAgB,QAAQ,CAAC,OAAO,iBAAiB,QAAQ,CAAC,QAAQ,GAAG;c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ments.js';
|
|
2
2
|
export declare const LOCAL_CONVERSION_FLAGS: Set<string>;
|
|
3
3
|
export declare const localConversionDirectory: (source: string, flags: CliFlags) => string;
|
|
4
|
+
/**
|
|
5
|
+
* Whether a folder holds a saved hosted run: its journal records a hosted operation the service actually took on — a
|
|
6
|
+
* line naming a service-side run id or a purchase. A journal of an attempt that never dispatched (no sign-in, a refused
|
|
7
|
+
* flag) records neither, so it does not pin the folder to the hosted engine. A journal this reader cannot fully read
|
|
8
|
+
* keeps the pin: a dispatched run is resumed, never bought again (CLAUDE.md item 3).
|
|
9
|
+
*/
|
|
10
|
+
export declare function savedHostedRun(directory: string): Promise<boolean>;
|
|
11
|
+
/**
|
|
12
|
+
* The service-side run a folder's journal records for these exact bytes: the newest convert line naming a run id and
|
|
13
|
+
* this source digest. A re-run of the same convert resumes it rather than buying a second conversion (CLAUDE.md item 3).
|
|
14
|
+
*/
|
|
15
|
+
export declare function savedHostedRunId(directory: string, sourceSha256: string): Promise<string | null>;
|
|
16
|
+
/**
|
|
17
|
+
* Frees a folder that holds nothing but the journal of finished hosted attempts that never dispatched (the 0.2.83-0.2.87
|
|
18
|
+
* Build this left one in `<version>-html` on a machine with no 12ui sign-in), so a local run can be created there. The
|
|
19
|
+
* journal is kept beside the folder, as the local run's receipt is, and the emptied folder is removed. Any other file,
|
|
20
|
+
* a record still open or torn, or a dispatch leaves the folder as it is and returns null.
|
|
21
|
+
*/
|
|
22
|
+
export declare function retireUnsentHostedAttempt(directory: string): Promise<string | null>;
|
|
4
23
|
/** Only explicitly requested options belong in flags; defaults must not imply hosted intent. */
|
|
5
24
|
export declare function chooseConversionEngine({ source, flags, runDir }: {
|
|
6
25
|
source: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cli-conversion-engine.d.ts","sourceRoot":"","sources":["../src/cli-conversion-engine.ts"],"names":[],"mappings":"AAEA,OAAO,EAAc,KAAK,QAAQ,EAAE,MAAM,oBAAoB,CAAC;
|
|
1
|
+
{"version":3,"file":"cli-conversion-engine.d.ts","sourceRoot":"","sources":["../src/cli-conversion-engine.ts"],"names":[],"mappings":"AAEA,OAAO,EAAc,KAAK,QAAQ,EAAE,MAAM,oBAAoB,CAAC;AAK/D,eAAO,MAAM,sBAAsB,aAAyI,CAAC;AAC7K,eAAO,MAAM,wBAAwB,GAAI,QAAQ,MAAM,EAAE,OAAO,QAAQ,KAAG,MAAoI,CAAC;AAChN;;;;;GAKG;AACH,wBAAsB,cAAc,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO,CAAC,CAKxE;AAED;;;GAGG;AACH,wBAAsB,gBAAgB,CAAC,SAAS,EAAE,MAAM,EAAE,YAAY,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,GAAC,IAAI,CAAC,CAIpG;AACD;;;;;GAKG;AACH,wBAAsB,yBAAyB,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,GAAC,IAAI,CAAC,CAYvF;AACD,gGAAgG;AAChG,wBAAsB,sBAAsB,CAAC,EAAC,MAAM,EAAC,KAAK,EAAC,MAAM,EAAC,EAAE;IAAC,MAAM,EAAC,MAAM,CAAC;IAAA,KAAK,EAAC,QAAQ,CAAC;IAAA,MAAM,CAAC,EAAC,MAAM,CAAA;CAAC,sDAmBhH;AACD,wBAAgB,wBAAwB,CAAC,KAAK,EAAC,QAAQ,GAAG,IAAI,CAG7D"}
|
|
@@ -1,16 +1,63 @@
|
|
|
1
1
|
import path from 'node:path';
|
|
2
|
-
import { stat } from 'node:fs/promises';
|
|
2
|
+
import { readdir, rename, rmdir, stat } from 'node:fs/promises';
|
|
3
3
|
import { stringFlag } from './cli-arguments.js';
|
|
4
4
|
import { selectEngine } from './cli-engine.js';
|
|
5
5
|
import { readLocalRecord } from './cli-local-record.js';
|
|
6
6
|
import { CliRefusal } from './cli-refusal.js';
|
|
7
|
+
import { readRunJournal, runJournalPath, RUN_JOURNAL_FILENAME } from './run-journal.js';
|
|
7
8
|
export const LOCAL_CONVERSION_FLAGS = new Set(['engine', 'codex-bin', 'codex-home', 'output', 'out-dir', 'image-backend', 'clean-assets', 'timeout-ms', 'reasoning', 'json', 'quiet']);
|
|
8
9
|
export const localConversionDirectory = (source, flags) => path.resolve(stringFlag(flags, 'out-dir') ?? path.join(path.dirname(path.resolve(source)), path.parse(source).name + '-12ui'));
|
|
10
|
+
/**
|
|
11
|
+
* Whether a folder holds a saved hosted run: its journal records a hosted operation the service actually took on — a
|
|
12
|
+
* line naming a service-side run id or a purchase. A journal of an attempt that never dispatched (no sign-in, a refused
|
|
13
|
+
* flag) records neither, so it does not pin the folder to the hosted engine. A journal this reader cannot fully read
|
|
14
|
+
* keeps the pin: a dispatched run is resumed, never bought again (CLAUDE.md item 3).
|
|
15
|
+
*/
|
|
16
|
+
export async function savedHostedRun(directory) {
|
|
17
|
+
if (!(await stat(runJournalPath(directory)).catch(() => null)))
|
|
18
|
+
return false;
|
|
19
|
+
const journal = await readRunJournal({ workspace: directory }).catch(() => null);
|
|
20
|
+
if (!journal || journal.skipped.length > 0)
|
|
21
|
+
return true;
|
|
22
|
+
return journal.entries.some(dispatched);
|
|
23
|
+
}
|
|
24
|
+
const dispatched = (entry) => entry.run_id !== undefined || (entry.purchased?.length ?? 0) > 0;
|
|
25
|
+
/**
|
|
26
|
+
* The service-side run a folder's journal records for these exact bytes: the newest convert line naming a run id and
|
|
27
|
+
* this source digest. A re-run of the same convert resumes it rather than buying a second conversion (CLAUDE.md item 3).
|
|
28
|
+
*/
|
|
29
|
+
export async function savedHostedRunId(directory, sourceSha256) {
|
|
30
|
+
const journal = await readRunJournal({ workspace: directory }).catch(() => null);
|
|
31
|
+
const entry = journal?.entries.filter(line => line.cmd === 'convert' && line.run_id !== undefined && line.source_sha256 === sourceSha256).at(-1);
|
|
32
|
+
return entry?.run_id ?? null;
|
|
33
|
+
}
|
|
34
|
+
/**
|
|
35
|
+
* Frees a folder that holds nothing but the journal of finished hosted attempts that never dispatched (the 0.2.83-0.2.87
|
|
36
|
+
* Build this left one in `<version>-html` on a machine with no 12ui sign-in), so a local run can be created there. The
|
|
37
|
+
* journal is kept beside the folder, as the local run's receipt is, and the emptied folder is removed. Any other file,
|
|
38
|
+
* a record still open or torn, or a dispatch leaves the folder as it is and returns null.
|
|
39
|
+
*/
|
|
40
|
+
export async function retireUnsentHostedAttempt(directory) {
|
|
41
|
+
const names = await readdir(directory).catch(() => null);
|
|
42
|
+
if (!names || names.length !== 1 || names[0] !== RUN_JOURNAL_FILENAME)
|
|
43
|
+
return null;
|
|
44
|
+
const journal = await readRunJournal({ workspace: directory }).catch(() => null);
|
|
45
|
+
if (!journal || journal.torn || journal.skipped.length > 0 || journal.entries.length === 0 || journal.entries.some(dispatched))
|
|
46
|
+
return null;
|
|
47
|
+
const count = (event) => journal.entries.filter(entry => entry.event === event).length;
|
|
48
|
+
if (count('start') !== count('end'))
|
|
49
|
+
return null;
|
|
50
|
+
const base = path.resolve(directory);
|
|
51
|
+
const target = (await stat(`${base}.unsent-journal.jsonl`).catch(() => null)) ? `${base}.unsent-journal-${Date.now()}.jsonl` : `${base}.unsent-journal.jsonl`;
|
|
52
|
+
await rename(runJournalPath(directory), target);
|
|
53
|
+
await rmdir(directory);
|
|
54
|
+
return target;
|
|
55
|
+
}
|
|
9
56
|
/** Only explicitly requested options belong in flags; defaults must not imply hosted intent. */
|
|
10
57
|
export async function chooseConversionEngine({ source, flags, runDir }) {
|
|
11
58
|
const directory = runDir ?? localConversionDirectory(source, flags);
|
|
12
59
|
const saved = await readLocalRecord(directory);
|
|
13
|
-
const hosted = !saved && await
|
|
60
|
+
const hosted = !saved && await savedHostedRun(directory);
|
|
14
61
|
const requested = stringFlag(flags, 'engine') ?? process.env.TWELVE_UI_ENGINE ?? 'auto';
|
|
15
62
|
const unsupported = Object.keys(flags).filter(key => !LOCAL_CONVERSION_FLAGS.has(key));
|
|
16
63
|
if (!saved && !hosted && requested === 'codex' && unsupported.length) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cli-conversion-engine.js","sourceRoot":"","sources":["../src/cli-conversion-engine.ts"],"names":[],"mappings":"AAAA,OAAO,IAAI,MAAM,WAAW,CAAC;AAC7B,OAAO,EAAE,IAAI,EAAE,MAAM,kBAAkB,CAAC;
|
|
1
|
+
{"version":3,"file":"cli-conversion-engine.js","sourceRoot":"","sources":["../src/cli-conversion-engine.ts"],"names":[],"mappings":"AAAA,OAAO,IAAI,MAAM,WAAW,CAAC;AAC7B,OAAO,EAAE,OAAO,EAAE,MAAM,EAAE,KAAK,EAAE,IAAI,EAAE,MAAM,kBAAkB,CAAC;AAChE,OAAO,EAAE,UAAU,EAAiB,MAAM,oBAAoB,CAAC;AAC/D,OAAO,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAC/C,OAAO,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AACxD,OAAO,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAC9C,OAAO,EAAE,cAAc,EAAE,cAAc,EAAE,oBAAoB,EAAwB,MAAM,kBAAkB,CAAC;AAC9G,MAAM,CAAC,MAAM,sBAAsB,GAAG,IAAI,GAAG,CAAC,CAAC,QAAQ,EAAC,WAAW,EAAC,YAAY,EAAC,QAAQ,EAAC,SAAS,EAAC,eAAe,EAAC,cAAc,EAAC,YAAY,EAAC,WAAW,EAAC,MAAM,EAAC,OAAO,CAAC,CAAC,CAAC;AAC7K,MAAM,CAAC,MAAM,wBAAwB,GAAG,CAAC,MAAc,EAAE,KAAe,EAAU,EAAE,CAAC,IAAI,CAAC,OAAO,CAAC,UAAU,CAAC,KAAK,EAAC,SAAS,CAAC,IAAI,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,OAAO,CAAC,MAAM,CAAC,CAAC,EAAC,IAAI,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC,IAAI,GAAC,OAAO,CAAC,CAAC,CAAC;AAChN;;;;;GAKG;AACH,MAAM,CAAC,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-5,6 +5,7 @@ import { materializeConversionArtifacts } from './artifact-materializer.js';
|
|
|
5
5
|
import { booleanFlag, stringFlag } from './cli-arguments.js';
|
|
6
6
|
import { prepareOutputDirectory, prepareOutputFile } from './cli-output-paths.js';
|
|
7
7
|
import { runConversionDerivation } from './cli-conversion-derivation.js';
|
|
8
|
+
import { savedHostedRunId } from './cli-conversion-engine.js';
|
|
8
9
|
import { CONVERSION_DURATION_HINTS, createLongRunningProgress, } from './cli-progress.js';
|
|
9
10
|
import { refuseUsage, usage, usageRefusal } from './cli-usage.js';
|
|
10
11
|
import { readConversionConfig } from './config.js';
|
|
@@ -707,6 +708,22 @@ export const runConversionCommand = async (command, flags, journal, dependencies
|
|
|
707
708
|
? CONVERSION_DURATION_HINTS.convertFast
|
|
708
709
|
: CONVERSION_DURATION_HINTS.convert;
|
|
709
710
|
const sourceSha256 = createHash('sha256').update(inputBytes).digest('hex');
|
|
711
|
+
// These exact bytes were already bought into this folder: collect that run, exactly as `12ui resume <run_id>` does,
|
|
712
|
+
// rather than buy a second conversion (CLAUDE.md item 3). Only a run the service reports failed or expired is retried.
|
|
713
|
+
const boughtRunId = await savedHostedRunId(workspace, sourceSha256);
|
|
714
|
+
if (boughtRunId) {
|
|
715
|
+
const bought = await conversionClient().getConversion(boughtRunId).catch(() => null);
|
|
716
|
+
if (bought?.status !== 'failed' && bought?.status !== 'expired') {
|
|
717
|
+
if (!quiet) {
|
|
718
|
+
process.stderr.write(`These exact bytes were already bought here as conversion ${boughtRunId};`
|
|
719
|
+
+ ` resuming it (12ui resume ${boughtRunId}) instead of buying a second conversion.\n`);
|
|
720
|
+
}
|
|
721
|
+
const resumeFlags = Object.fromEntries(Object.entries(flags)
|
|
722
|
+
.filter(([name]) => ['origin', 'api-key', 'timeout-ms', 'quiet', 'out-dir'].includes(name)));
|
|
723
|
+
await runConversionCommand(['resume', boughtRunId], resumeFlags, journal, dependencies);
|
|
724
|
+
return;
|
|
725
|
+
}
|
|
726
|
+
}
|
|
710
727
|
journal.note({
|
|
711
728
|
sourceSha256,
|
|
712
729
|
writes: exportOutFile ? [outFile, exportOutFile] : [outFile],
|