{"project":"spring","branch":"main","commit":"281fccfb7a59153036a206145555f49767b2adac","component":{"name":"demo-1","nodes":{"root":{"tag":"div","type":"element","children":["jJn7cadx-G5nm6lB8xq7g","OXKPNzESgH7wdLHAxCFXG","fq85zwIGhIn9W-mZoLH0m","uNv5GNYOMhDgWIJkfPiZz","7nSecwwTW3dT3JF9Ihxtn"],"classes":{"eHpzdO":{"formula":{"type":"value","value":true}}},"customProperties":{}},"7F8UrmSsHMEM1yOMCbmw6":{"tag":"path","type":"element","attrs":{"d":{"type":"value","value":"M12 2a10 10 0 0 1 .324 19.995l-.324 .005l-.324 -.005a10 10 0 0 1 .324 -19.995zm.707 5.293a1 1 0 0 0 -1.414 0l-4 4a1.048 1.048 0 0 0 -.083 .094l-.064 .092l-.052 .098l-.044 .11l-.03 .112l-.017 .126l-.003 .075l.004 .09l.007 .058l.025 .118l.035 .105l.054 .113l.043 .07l.071 .095l.054 .058l4 4l.094 .083a1 1 0 0 0 1.32 -1.497l-2.292 -2.293h5.585l.117 -.007a1 1 0 0 0 -.117 -1.993h-5.586l2.293 -2.293l.083 -.094a1 1 0 0 0 -.083 -1.32z"},"fill":{"type":"value","value":"currentColor"},"stroke-width":{"type":"value","value":"0"}},"customProperties":{}},"7nSecwwTW3dT3JF9Ihxtn":{"tag":"div","type":"element","customProperties":{}},"AItq_jegI7oPNMAfP-xLK":{"tag":"svg","type":"element","attrs":{"fill":{"type":"value","value":"none"},"width":{"type":"value","value":"44"},"xmlns":{"type":"value","value":"http://www.w3.org/2000/svg"},"height":{"type":"value","value":"44"},"stroke":{"type":"value","value":"currentColor"},"viewBox":{"type":"value","value":"0 0 24 24"},"stroke-width":{"type":"value","value":"1.5"},"stroke-linecap":{"type":"value","value":"round"},"stroke-linejoin":{"type":"value","value":"round"}},"children":["lg1lD0aA5rlr-UDaEjoRO","7F8UrmSsHMEM1yOMCbmw6"],"customProperties":{}},"Eonvva7QcxHXtt4_BfBxz":{"tag":"path","type":"element","attrs":{"d":{"type":"value","value":"M12 2l.324 .005a10 10 0 1 1 -.648 0l.324 -.005zm.613 5.21a1 1 0 0 0 -1.32 1.497l2.291 2.293h-5.584l-.117 .007a1 1 0 0 0 .117 1.993h5.584l-2.291 2.293l-.083 .094a1 1 0 0 0 1.497 1.32l4 -4l.073 -.082l.064 -.089l.062 -.113l.044 -.11l.03 -.112l.017 -.126l.003 -.075l-.007 -.118l-.029 -.148l-.035 -.105l-.054 -.113l-.071 -.111a1.008 1.008 0 0 0 -.097 -.112l-4 -4z"},"fill":{"type":"value","value":"currentColor"},"stroke-width":{"type":"value","value":"0"}},"customProperties":{}},"H6KaoSu9CXrJw87QV_KRC":{"tag":"path","type":"element","attrs":{"d":{"type":"value","value":"M0 0h24v24H0z"},"fill":{"type":"value","value":"none"},"stroke":{"type":"value","value":"none"}},"customProperties":{}},"OXKPNzESgH7wdLHAxCFXG":{"name":"editor-button","type":"component","attrs":{"component":{"type":"value","value":"demo1"}},"customProperties":{}},"Qba_7PESEu_MB6HpbBjbq":{"tag":"svg","type":"element","attrs":{"fill":{"type":"value","value":"none"},"width":{"type":"value","value":44},"xmlns":{"type":"value","value":"http://www.w3.org/2000/svg"},"height":{"type":"value","value":44},"stroke":{"type":"value","value":"currentcolor"},"viewBox":{"type":"value","value":"0 0 24 24"},"stroke-width":{"type":"value","value":"1.5"},"stroke-linecap":{"type":"value","value":"round"},"stroke-linejoin":{"type":"value","value":"round"}},"children":["H6KaoSu9CXrJw87QV_KRC","Eonvva7QcxHXtt4_BfBxz"],"customProperties":{}},"fq85zwIGhIn9W-mZoLH0m":{"tag":"a","type":"element","attrs":{"href":{"type":"value","value":"/"},"data-prerender":{"type":"value","value":"moderate"}},"children":["AItq_jegI7oPNMAfP-xLK"],"classes":{"eIpGYG":{"formula":{"type":"value","value":true}}},"customProperties":{}},"jJn7cadx-G5nm6lB8xq7g":{"name":"demo1","type":"component","customProperties":{}},"lg1lD0aA5rlr-UDaEjoRO":{"tag":"path","type":"element","attrs":{"d":{"type":"value","value":"M0 0h24v24H0z"},"fill":{"type":"value","value":"none"},"stroke":{"type":"value","value":"none"}},"customProperties":{}},"uNv5GNYOMhDgWIJkfPiZz":{"tag":"a","type":"element","attrs":{"href":{"type":"value","value":"/demo-2"},"data-prerender":{"type":"value","value":"moderate"}},"children":["Qba_7PESEu_MB6HpbBjbq"],"classes":{"cATehx":{"formula":{"type":"value","value":true}}},"customProperties":{}}},"route":{"info":{"title":{"formula":{"type":"value","value":"Demo 1 - spring"}},"description":{"formula":{"type":"value","value":"A toddle package for creating spring animations"}}},"path":[{"name":"demo-1","type":"static"}],"query":{}}},"components":[{"name":"editor-button","nodes":{"root":{"tag":"a","type":"element","attrs":{"href":{"name":"@toddle/concatenate","type":"function","arguments":[{"name":"0","type":{"type":"Union","types":[{"type":"String"},{"type":"Array","ofType":{"type":"Any"}}]},"formula":{"type":"value","value":"https://toddle.dev/projects/spring/branches/main/components/"}},{"name":"0","type":{"type":"Union","types":[{"type":"String"},{"type":"Array","ofType":{"type":"Any"}}]},"formula":{"path":["Attributes","component"],"type":"path"}}],"display_name":"Concatenate","variableArguments":true},"target":{"type":"value","value":"_blank"},"data-prerender":{"type":"value","value":"moderate"}},"children":["NiZzBfRyFeP29W2catiHe"],"classes":{"ckrKkO":{"formula":{"type":"value","value":true}}},"customProperties":{}},"NiZzBfRyFeP29W2catiHe":{"type":"text","value":{"type":"value","value":"View in editor"}}},"attributes":{"component":{"name":"component"}}},{"name":"demo1","nodes":{"root":{"tag":"div","type":"element","children":["K_OMQE-k537Ei6WMtB4tl","qbaaNRzygKZFTYidCR6dJ"],"classes":{"cBoNkX":{"formula":{"type":"value","value":true}}},"customProperties":{}},"0ZRAcgNFmrYVKoo-M2CL1":{"type":"text","value":{"type":"value","value":"B"},"events":null},"1hdKsve95oNwIvtTBIthg":{"tag":"p","type":"element","children":["5K7C3x3DwOmBwNIsaa6Mq"],"classes":{"GjPOv":{"formula":{"type":"value","value":true}}},"customProperties":{}},"5K7C3x3DwOmBwNIsaa6Mq":{"type":"text","value":{"type":"value","value":"A"},"events":null},"5bT2-TgK56LgElRHMj4m3":{"tag":"img","type":"element","attrs":{"alt":{"type":"value","value":""},"src":{"type":"value","value":"/cdn-cgi/imagedelivery/ZIty0Vhmkm0nD-fBKJrTZQ/spring:0b23f898914f40035f51b636f4edb717.webp/public"}},"style-variables":[{"name":"pos-x","unit":"px","formula":{"path":["Variables","Position"],"type":"path"},"category":"spacing"}],"classes":{"bNunzx":{"formula":{"type":"value","value":true}}},"customProperties":{}},"8avjWcNkFskLiM3Uk5qWS":{"type":"text","value":{"type":"value","value":"Mass"},"events":null},"AMraahUO1tnNrYJWj9sSO":{"tag":"div","type":"element","children":["q-_UI5k-sm_cqkon8qoWt","JBOgMu4ptItStXIGqTFag"],"classes":{"fxGcDJ":{"formula":{"type":"value","value":true}}},"customProperties":{}},"F3H2ihH_llbx3A3ofa3XY":{"tag":"div","type":"element","children":["1hdKsve95oNwIvtTBIthg","iKTc4_v07RcgsDpAVBJdt","um0eNULhtLPPQsLT28RpP"],"classes":{"dimZik":{"formula":{"type":"value","value":true}}},"customProperties":{}},"FBdfIsEyuO8cfIMwdK9zv":{"tag":"div","type":"element","children":["5bT2-TgK56LgElRHMj4m3"],"classes":{"eaJNHM":{"formula":{"type":"value","value":true}}},"customProperties":{}},"JBOgMu4ptItStXIGqTFag":{"tag":"input","type":"element","attrs":{"id":{"type":"value","value":"range-input"},"max":{"type":"value","value":100},"min":{"type":"value","value":0},"type":{"type":"value","value":"range"},"value":{"path":["Variables","Damping"],"type":"path"},"placeholder":{"type":"value","value":"Input field"}},"events":{"input":{"actions":[{"data":{"path":["Event","target","value"],"type":"path"},"type":"SetVariable","variable":"Damping"}],"trigger":"input"}},"classes":{"cxAUuy":{"formula":{"type":"value","value":true}}},"customProperties":{}},"K_OMQE-k537Ei6WMtB4tl":{"tag":"div","type":"element","attrs":{"id":{"type":"value","value":"demo1-container"}},"children":["Y5qGcvCA__4KZtmGkxlup"],"style-variables":[{"name":"pos-x","unit":"px","formula":{"type":"value","value":100},"category":"spacing"}],"classes":{"dknzbY":{"formula":{"type":"value","value":true}}},"customProperties":{}},"KqOZzCwKaCgnP8SIUdVwZ":{"type":"text","value":{"type":"value","value":"Stiffness"},"events":null},"MNacnRrwrs-q2cUkx9GMI":{"tag":"div","type":"element","children":["_uyUxL9o_xkeHOW18NZV2"],"classes":{"esbYdA":{"formula":{"type":"value","value":true}}},"customProperties":{}},"RXveH4piScn81Ka3G29gy":{"tag":"label","type":"element","attrs":{"for":{"type":"value","value":"range-input"},"title":{"type":"value","value":"Last name"}},"children":["8avjWcNkFskLiM3Uk5qWS"],"classes":{"facVuj":{"formula":{"type":"value","value":true}}},"customProperties":{}},"TtdWcmTFZM8quBjMn5ceg":{"tag":"svg","type":"element","attrs":{"fill":{"type":"value","value":"none"},"width":{"type":"value","value":300},"xmlns":{"type":"value","value":"http://www.w3.org/2000/svg"},"height":{"type":"value","value":300},"stroke":{"type":"value","value":"currentcolor"},"viewBox":{"type":"value","value":"0 0 300 300"},"stroke-width":{"type":"value","value":"1.5"},"stroke-linecap":{"type":"value","value":"round"},"stroke-linejoin":{"type":"value","value":"round"}},"children":["rhfdEFxX-gloTOcJVT2A2"],"classes":{"chyvKf":{"formula":{"type":"value","value":true}}},"customProperties":{}},"Y5qGcvCA__4KZtmGkxlup":{"tag":"div","type":"element","children":["FBdfIsEyuO8cfIMwdK9zv","F3H2ihH_llbx3A3ofa3XY","MNacnRrwrs-q2cUkx9GMI","TtdWcmTFZM8quBjMn5ceg"],"classes":{"cIjnzS":{"formula":{"type":"value","value":true}}},"customProperties":{}},"_uyUxL9o_xkeHOW18NZV2":{"tag":"button","type":"element","events":{"click":{"actions":[{"data":{"type":"array","arguments":[]},"type":"SetVariable","variable":"chart"},{"data":{"type":"switch","cases":[{"formula":{"type":"value","value":280},"condition":{"name":"@toddle/equals","type":"function","arguments":[{"name":"First","type":{"type":"Any"},"formula":{"path":["Variables","target"],"type":"path"}},{"name":"Second","type":{"type":"Any"},"formula":{"type":"value","value":0}}],"display_name":"Equals"}}],"default":{"type":"value","value":0}},"type":"SetVariable","variable":"target"},{"name":"spring","events":{"end":{"actions":[],"dummyEvent":{"id":"demo-1-x","mass":1,"value":498,"target":498,"damping":10,"stopped":true,"lastTime":3877.1,"velocity":0.08496219215236757,"stiffness":100}},"update":{"actions":[{"data":{"name":"@toddle/append","type":"function","arguments":[{"name":"Array","type":{"type":"Array"},"formula":{"path":["Variables","chart"],"type":"path"}},{"name":"Item","type":{"type":"Any"},"formula":{"path":["Event","value"],"type":"path"}}],"display_name":"Append"},"type":"SetVariable","variable":"chart"},{"data":{"path":["Event","value"],"type":"path"},"type":"SetVariable","variable":"Position"}],"trigger":"update","dummyEvent":{"id":"demo-1-x","mass":1,"value":300,"target":498,"damping":10,"stopped":false,"lastTime":3877.1,"velocity":0.08496219215236757,"stiffness":100}}},"version":2,"arguments":[{"name":"id","formula":{"type":"value","value":"demo1"}},{"name":"target","formula":{"path":["Variables","target"],"type":"path"}},{"name":"initialValue","formula":{"type":"value","value":0}},{"name":"stiffness","formula":{"path":["Variables","Stiffness"],"type":"path"}},{"name":"damping","formula":{"path":["Variables","Damping"],"type":"path"}},{"name":"mass","formula":{"path":["Variables","Mass"],"type":"path"}}]}],"trigger":"click"}},"children":["e_IJONxh-CcMEZn_eJ50y"],"classes":{"eEsMcO":{"formula":{"type":"value","value":true}}},"customProperties":{}},"c0MlB26v0ZDM_EqQKdQ-H":{"type":"text","value":{"type":"value","value":"Damping"},"events":null},"e_IJONxh-CcMEZn_eJ50y":{"type":"text","value":{"type":"value","value":"Switch"},"events":null},"fB8mvURkt5TA9Hf-Beelu":{"tag":"label","type":"element","attrs":{"for":{"type":"value","value":"range-input"},"title":{"type":"value","value":"Last name"}},"children":["KqOZzCwKaCgnP8SIUdVwZ"],"classes":{"facVuj":{"formula":{"type":"value","value":true}}},"customProperties":{}},"h1gQXjz6DcRQdYmxyOO6U":{"tag":"input","type":"element","attrs":{"id":{"type":"value","value":"range-input"},"max":{"type":"value","value":20},"min":{"type":"value","value":0.2},"type":{"type":"value","value":"range"},"value":{"path":["Variables","Mass"],"type":"path"},"placeholder":{"type":"value","value":"Input field"}},"events":{"input":{"actions":[{"data":{"path":["Event","target","value"],"type":"path"},"type":"SetVariable","variable":"Mass"}],"trigger":"input"}},"classes":{"cxAUuy":{"formula":{"type":"value","value":true}}},"customProperties":{}},"iKTc4_v07RcgsDpAVBJdt":{"tag":"div","type":"element","classes":{"bgKAYd":{"formula":{"type":"value","value":true}}},"customProperties":{}},"ihkuUSeouixXxDyT5YP_q":{"tag":"input","type":"element","attrs":{"id":{"type":"value","value":"range-input"},"max":{"type":"value","value":500},"min":{"type":"value","value":10},"type":{"type":"value","value":"range"},"value":{"path":["Variables","Stiffness"],"type":"path"},"placeholder":{"type":"value","value":"Input field"}},"events":{"input":{"actions":[{"data":{"path":["Event","target","value"],"type":"path"},"type":"SetVariable","variable":"Stiffness"}],"trigger":"input"}},"classes":{"fbHzga":{"formula":{"type":"value","value":true}}},"customProperties":{}},"q-_UI5k-sm_cqkon8qoWt":{"tag":"label","type":"element","attrs":{"for":{"type":"value","value":"range-input"},"title":{"type":"value","value":"Last name"}},"children":["c0MlB26v0ZDM_EqQKdQ-H"],"classes":{"facVuj":{"formula":{"type":"value","value":true}}},"customProperties":{}},"qTfpFduJBEjHpSggVwsBh":{"tag":"div","type":"element","children":["RXveH4piScn81Ka3G29gy","h1gQXjz6DcRQdYmxyOO6U"],"classes":{"fxGcDJ":{"formula":{"type":"value","value":true}}},"customProperties":{}},"qbaaNRzygKZFTYidCR6dJ":{"tag":"form","type":"element","children":["r5GgE76Hdi8TeJwsdjPAv","AMraahUO1tnNrYJWj9sSO","qTfpFduJBEjHpSggVwsBh"],"classes":{"ZfQSk":{"formula":{"type":"value","value":true}}},"customProperties":{}},"r5GgE76Hdi8TeJwsdjPAv":{"tag":"div","type":"element","children":["fB8mvURkt5TA9Hf-Beelu","ihkuUSeouixXxDyT5YP_q"],"classes":{"fxGcDJ":{"formula":{"type":"value","value":true}}},"customProperties":{}},"rhfdEFxX-gloTOcJVT2A2":{"tag":"polyline","type":"element","attrs":{"points":{"name":"@toddle/join","type":"function","arguments":[{"name":"Array","type":{"type":"Array"},"formula":{"name":"@toddle/map","type":"function","arguments":[{"name":"Array","type":{"type":"Array"},"formula":{"path":["Variables","chart"],"type":"path"}},{"name":"Formula","type":{"type":"Formula"},"formula":{"name":"@toddle/concatenate","type":"function","arguments":[{"name":"0","type":{"type":"Union","types":[{"type":"String"},{"type":"Array","ofType":{"type":"Any"}}]},"formula":{"name":"@toddle/multiply","type":"function","arguments":[{"name":"0","type":{"type":"Number"},"formula":{"name":"@toddle/divide","type":"function","arguments":[{"name":"Dividend","type":{"type":"Number"},"formula":{"path":["Args","index"],"type":"path"}},{"name":"Divisor","type":{"type":"Number"},"formula":{"name":"@toddle/size","type":"function","arguments":[{"name":"Collection","type":{"type":"Union","types":[{"type":"String"},{"type":"Array"},{"type":"Object"}]},"formula":{"path":["Variables","chart"],"type":"path"}}],"display_name":"Size"}}],"display_name":"Divide"}},{"name":"1","type":{"type":"Number"},"formula":{"type":"value","value":300}}],"display_name":"Multiply","variableArguments":true}},{"name":"0","type":{"type":"Union","types":[{"type":"String"},{"type":"Array","ofType":{"type":"Any"}}]},"formula":{"type":"value","value":","}},{"name":"0","type":{"type":"Union","types":[{"type":"String"},{"type":"Array","ofType":{"type":"Any"}}]},"formula":{"name":"@toddle/round","type":"function","arguments":[{"name":"Input","type":{"type":"Number"},"formula":{"name":"@toddle/minus","type":"function","arguments":[{"name":"Minuend","type":{"type":"Number"},"formula":{"type":"value","value":200}},{"name":"Substrahend","type":{"type":"Number"},"formula":{"name":"@toddle/multiply","type":"function","arguments":[{"name":"0","type":{"type":"Number"},"formula":{"name":"@toddle/divide","type":"function","arguments":[{"name":"Dividend","type":{"type":"Number"},"formula":{"path":["Args","item"],"type":"path"}},{"name":"Divisor","type":{"type":"Number"},"formula":{"name":"OTjh8iSr7JCI8yyw-x8Q1","type":"apply","arguments":[]}}],"display_name":"Divide"}},{"name":"1","type":{"type":"Number"},"formula":{"type":"value","value":100}}],"display_name":"Multiply","variableArguments":true}}],"display_name":"Minus"}},{"name":"Decimals","type":{"type":"Number"},"formula":{"type":"value","value":0}}],"display_name":"Round"}}],"display_name":"Concatenate","variableArguments":true},"isFunction":true}],"display_name":"Map"}},{"name":"Separator","type":{"type":"String"},"formula":{"type":"value","value":" "}}],"display_name":"Join"}},"customProperties":{}},"um0eNULhtLPPQsLT28RpP":{"tag":"p","type":"element","children":["0ZRAcgNFmrYVKoo-M2CL1"],"classes":{"GjPOv":{"formula":{"type":"value","value":true}}},"customProperties":{}}},"__type":"components","onLoad":{"actions":[],"trigger":"Load"},"formulas":{"OTjh8iSr7JCI8yyw-x8Q1":{"name":"max-chart-value","formula":{"name":"@toddle/reduce","type":"function","arguments":[{"name":"Array","type":{"type":"Union","types":[{"type":"Array"},{"type":"Object"}]},"formula":{"path":["Variables","chart"],"type":"path"}},{"name":"Formula","type":{"type":"Formula"},"formula":{"name":"@toddle/max","type":"function","arguments":[{"name":"0","type":{"type":"Number"},"formula":{"path":["Args","item"],"type":"path"}},{"name":"1","type":{"type":"Number"},"formula":{"path":["Args","result"],"type":"path"}}],"display_name":"Max","variableArguments":true},"isFunction":true},{"name":"Accumulator","type":{"type":"Any"},"formula":{"path":["Variables","chart","0"],"type":"path"}}],"display_name":"Reduce"},"memoize":false,"arguments":[]}},"variables":{"Mass":{"initialValue":{"type":"value","value":1}},"chart":{"initialValue":{"type":"array","arguments":[]}},"target":{"initialValue":{"type":"value","value":0}},"Damping":{"initialValue":{"type":"value","value":10}},"Dragging":{"initialValue":{"type":"value","value":false}},"Position":{"initialValue":{"type":"value","value":0}},"Stiffness":{"initialValue":{"type":"value","value":100}}}}]}