Comparaison
Sortie en direct du vrai moteur de rendu — modifiez les réglages et elle se met à jour instantanément.
Résultat de test A/B
motion design
Deux cartes de variantes arrivent de chaque côté, les deux résultats s'incrémentent et le contour du gagnant se dessine.
Idéal pour : Une expérience et sa variante gagnante.
Réglages
Police
Thème
Taille
Humeur
L'utiliser dans un film
Ce que vous pouvez changer :
titleaLabelaValuebLabelbValueliftPour les développeurs (MCP et JSON)
Voici la scène exacte à envoyer à create_animation (MCP) : gardez la structure, changez les mots et écrivez la narration — c'est la voix qui fixe la durée de la scène. Collez-la dans update_storyboard avec set_data pour modifier un film déjà fait.
{
"visual": "motion",
"heading": "A/B test",
"narration": "Write the sentence the voice says over this scene; its length is the scene's.",
"data": {
"motion": {
"spec": {
"version": 1,
"name": "A/B test result",
"intent": "which variant won, and by how much",
"exit": "mirror",
"params": [
{
"name": "title",
"type": "text",
"label": "Title",
"default": "New checkout page, two weeks",
"maxLength": 32
},
{
"name": "aLabel",
"type": "text",
"label": "Variant A",
"default": "Old page",
"maxLength": 14
},
{
"name": "aValue",
"type": "text",
"label": "A result",
"default": "2.1%",
"maxLength": 7
},
{
"name": "bLabel",
"type": "text",
"label": "Variant B",
"default": "New page",
"maxLength": 14
},
{
"name": "bValue",
"type": "text",
"label": "B result",
"default": "3.4%",
"maxLength": 7
},
{
"name": "lift",
"type": "text",
"label": "Lift",
"default": "+62% conversion",
"maxLength": 18
}
],
"layers": [
{
"id": "title",
"kind": "text",
"text": "{{title}}",
"role": "headline",
"align": "center",
"maxLines": 1,
"box": {
"col": 0,
"row": 0,
"cols": 12,
"rows": 1.8
},
"tall": {
"col": 0,
"row": 0.2,
"cols": 12,
"rows": 2
},
"enter": {
"primitive": "slideIn",
"from": "top",
"distance": "nudge"
}
},
{
"id": "aCard",
"kind": "shape",
"shape": "rect",
"fill": "surface",
"radius": "lg",
"elevation": 1,
"box": {
"col": 0,
"row": 2.2,
"cols": 5.8,
"rows": 7.4
},
"tall": {
"col": 0.5,
"row": 2.5,
"cols": 11,
"rows": 3.8
},
"enter": {
"primitive": "slideIn",
"from": "left",
"distance": "rise",
"order": 1
},
"exit": {
"primitive": "slideOut"
}
},
{
"id": "bCard",
"kind": "shape",
"shape": "rect",
"fill": "surface",
"radius": "lg",
"elevation": 3,
"box": {
"col": 6.2,
"row": 2.2,
"cols": 5.8,
"rows": 7.4
},
"tall": {
"col": 0.5,
"row": 6.6,
"cols": 11,
"rows": 3.8
},
"enter": {
"primitive": "slideIn",
"from": "right",
"distance": "rise",
"order": 1
},
"exit": {
"primitive": "slideOut"
}
},
{
"id": "aLabel",
"kind": "text",
"text": "{{aLabel}}",
"role": "title",
"color": "sub",
"align": "center",
"maxLines": 1,
"box": {
"col": 0,
"row": 2.6,
"cols": 5.8,
"rows": 1.3
},
"tall": {
"col": 0.5,
"row": 2.7,
"cols": 11,
"rows": 1
},
"enter": {
"primitive": "slideIn",
"from": "left",
"distance": "nudge",
"order": 2
}
},
{
"id": "bLabel",
"kind": "text",
"text": "{{bLabel}}",
"role": "title",
"color": "c1",
"align": "center",
"maxLines": 1,
"box": {
"col": 6.2,
"row": 2.6,
"cols": 5.8,
"rows": 1.3
},
"tall": {
"col": 0.5,
"row": 6.8,
"cols": 11,
"rows": 1
},
"enter": {
"primitive": "slideIn",
"from": "right",
"distance": "nudge",
"order": 2
}
},
{
"id": "aValue",
"kind": "number",
"value": "{{aValue}}",
"role": "display",
"color": "sub",
"align": "center",
"box": {
"col": 0,
"row": 4.3,
"cols": 5.8,
"rows": 4.8
},
"tall": {
"col": 0.5,
"row": 3.9,
"cols": 11,
"rows": 2.2
},
"enter": {
"primitive": "countUp",
"order": 2
}
},
{
"id": "bValue",
"kind": "number",
"value": "{{bValue}}",
"role": "display",
"color": "gradient",
"align": "center",
"box": {
"col": 6.2,
"row": 4.3,
"cols": 5.8,
"rows": 4.8
},
"tall": {
"col": 0.5,
"row": 8,
"cols": 11,
"rows": 2.2
},
"enter": {
"primitive": "countUp",
"order": 2
}
},
{
"id": "win",
"kind": "shape",
"shape": "rect",
"fill": "none",
"stroke": "c1",
"strokeWidth": "bold",
"radius": "lg",
"box": {
"col": 6.2,
"row": 2.2,
"cols": 5.8,
"rows": 7.4
},
"tall": {
"col": 0.5,
"row": 6.6,
"cols": 11,
"rows": 3.8
},
"enter": {
"primitive": "drawOn",
"order": 3
}
},
{
"id": "lift",
"kind": "text",
"text": "{{lift}}",
"role": "headline",
"color": "c1",
"align": "center",
"maxLines": 1,
"box": {
"col": 0,
"row": 10,
"cols": 12,
"rows": 2
},
"tall": {
"col": 0,
"row": 10.6,
"cols": 12,
"rows": 1.3
},
"enter": {
"primitive": "slideIn",
"from": "bottom",
"distance": "nudge",
"order": 4
}
}
]
},
"name": "A/B test result"
}
}
}Réutilisez-la : enregistrez data.motion.spec une fois avec save_motion_spec (vérifiée comme avec validate_motion_spec), puis toute scène peut utiliser le visuel « motion » avec data.motion.specId et ses propres paramètres. Nom de la spec : « A/B test result ».