{"version":3,"file":"js/vendors-_yarn___virtual___react-spring-web-virtual-9322263b63_0_cache_react-spring-web-npm-9_-0e67f4.js?_t=7543911396d8e756dc0f","mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;;;;;;;;;;AC9RA;AACA;AACA;AACA;AACA;AACA;;;;;;;;;;;;;;;;;;;;ACLA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AC5CA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;;;;;;;;;;AC5YA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;;;;;;;;;;;;;;;ACrKA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;;;;;;;;;AClBA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;;;;;;;;ACZA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;;;;;;;;;;AC1JA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;;;;;;;;ACtEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;;;;;;;;;;;;;;;;;;;ACTA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;;;;;;;;;;;;;;;;ACxCA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;;;;;;;;;;;ACxDA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;;;;;;;;;;ACvBA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;;;;;;;;;;;;;AC3JA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;;;AC/DA;;;;;;;;;;;;;;;;;;;;ACAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;ACxCA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;ACzNA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA","sources":["webpack://@mlssoccer/netcore/./.yarn/__virtual__/@react-spring-web-virtual-9322263b63/0/cache/@react-spring-web-npm-9.0.0-rc.3-7aac39f962-7d44dbcb2b.zip/node_modules/@react-spring/web/index.js","webpack://@mlssoccer/netcore/./.yarn/__virtual__/react-layout-effect-virtual-7d00b9c06b/0/cache/react-layout-effect-npm-1.0.5-31bd3d3e71-767fcfa754.zip/node_modules/react-layout-effect/dist/esm/useLayoutEffect.js","webpack://@mlssoccer/netcore/./.yarn/__virtual__/use-memo-one-virtual-88b9d1a5c9/0/cache/use-memo-one-npm-1.1.3-b9dc77468a-8f08eba26d.zip/node_modules/use-memo-one/dist/use-memo-one.esm.js","webpack://@mlssoccer/netcore/./.yarn/cache/@react-spring-animated-npm-9.0.0-rc.3-11619a7812-e64aeaa567.zip/node_modules/@react-spring/animated/index.js","webpack://@mlssoccer/netcore/./.yarn/cache/@react-spring-shared-npm-9.0.0-rc.3-5e0d87d39f-c0ea0e2c50.zip/node_modules/@react-spring/shared/esm/FrameLoop.js","webpack://@mlssoccer/netcore/./.yarn/cache/@react-spring-shared-npm-9.0.0-rc.3-5e0d87d39f-c0ea0e2c50.zip/node_modules/@react-spring/shared/esm/colorMatchers.js","webpack://@mlssoccer/netcore/./.yarn/cache/@react-spring-shared-npm-9.0.0-rc.3-5e0d87d39f-c0ea0e2c50.zip/node_modules/@react-spring/shared/esm/colorToRgba.js","webpack://@mlssoccer/netcore/./.yarn/cache/@react-spring-shared-npm-9.0.0-rc.3-5e0d87d39f-c0ea0e2c50.zip/node_modules/@react-spring/shared/esm/colors.js","webpack://@mlssoccer/netcore/./.yarn/cache/@react-spring-shared-npm-9.0.0-rc.3-5e0d87d39f-c0ea0e2c50.zip/node_modules/@react-spring/shared/esm/createInterpolator.js","webpack://@mlssoccer/netcore/./.yarn/cache/@react-spring-shared-npm-9.0.0-rc.3-5e0d87d39f-c0ea0e2c50.zip/node_modules/@react-spring/shared/esm/deprecations.js","webpack://@mlssoccer/netcore/./.yarn/cache/@react-spring-shared-npm-9.0.0-rc.3-5e0d87d39f-c0ea0e2c50.zip/node_modules/@react-spring/shared/esm/globals.js","webpack://@mlssoccer/netcore/./.yarn/cache/@react-spring-shared-npm-9.0.0-rc.3-5e0d87d39f-c0ea0e2c50.zip/node_modules/@react-spring/shared/esm/helpers.js","webpack://@mlssoccer/netcore/./.yarn/cache/@react-spring-shared-npm-9.0.0-rc.3-5e0d87d39f-c0ea0e2c50.zip/node_modules/@react-spring/shared/esm/hooks.js","webpack://@mlssoccer/netcore/./.yarn/cache/@react-spring-shared-npm-9.0.0-rc.3-5e0d87d39f-c0ea0e2c50.zip/node_modules/@react-spring/shared/esm/normalizeColor.js","webpack://@mlssoccer/netcore/./.yarn/cache/@react-spring-shared-npm-9.0.0-rc.3-5e0d87d39f-c0ea0e2c50.zip/node_modules/@react-spring/shared/esm/stringInterpolation.js","webpack://@mlssoccer/netcore/./.yarn/cache/@react-spring-shared-npm-9.0.0-rc.3-5e0d87d39f-c0ea0e2c50.zip/node_modules/@react-spring/shared/esm/types.js","webpack://@mlssoccer/netcore/./.yarn/cache/fluids-npm-0.1.10-c9f5c3a6b8-05b21917ce.zip/node_modules/fluids/dist/esm/index.js","webpack://@mlssoccer/netcore/./.yarn/cache/tslib-npm-1.14.1-102499115e-7dbf34e6f5.zip/node_modules/tslib/tslib.es6.js","webpack://@mlssoccer/netcore/./.yarn/unplugged/@react-spring-core-npm-9.0.0-rc.3-2d21c99545/node_modules/@react-spring/core/index.js"],"sourcesContent":["import _objectWithoutPropertiesLoose from '@babel/runtime/helpers/esm/objectWithoutPropertiesLoose';\nimport { Globals as Globals$1 } from '@react-spring/core';\nexport * from '@react-spring/core';\nimport { unstable_batchedUpdates } from 'react-dom';\nimport { createStringInterpolator } from '@react-spring/shared/stringInterpolation';\nimport colorNames from '@react-spring/shared/colors';\nimport { AnimatedObject, createHost } from '@react-spring/animated';\nimport { Globals, each, is, toArray, FluidValue, getFluidValue, getFluidConfig } from '@react-spring/shared';\n\nconst isCustomPropRE = /^--/;\n\nfunction dangerousStyleValue(name, value) {\n if (value == null || typeof value === 'boolean' || value === '') return '';\n if (typeof value === 'number' && value !== 0 && !isCustomPropRE.test(name) && !(isUnitlessNumber.hasOwnProperty(name) && isUnitlessNumber[name])) return value + 'px'; // Presumes implicit 'px' suffix for unitless numbers\n\n return ('' + value).trim();\n}\n\nconst attributeCache = {};\nfunction applyAnimatedValues(instance, props) {\n if (!instance.nodeType || !instance.setAttribute) {\n return false;\n }\n\n const isFilterElement = instance.nodeName === 'filter' || instance.parentNode && instance.parentNode.nodeName === 'filter';\n\n const _ref = props,\n {\n style,\n children,\n scrollTop,\n scrollLeft\n } = _ref,\n attributes = _objectWithoutPropertiesLoose(_ref, [\"style\", \"children\", \"scrollTop\", \"scrollLeft\"]);\n\n const values = Object.values(attributes);\n const names = Object.keys(attributes).map(name => isFilterElement || instance.hasAttribute(name) ? name : attributeCache[name] || (attributeCache[name] = name.replace(/([A-Z])/g, // Attributes are written in dash case\n n => '-' + n.toLowerCase())));\n Globals.frameLoop.onWrite(() => {\n if (children !== void 0) {\n instance.textContent = children;\n } // Apply CSS styles\n\n\n for (let name in style) {\n if (style.hasOwnProperty(name)) {\n const value = dangerousStyleValue(name, style[name]);\n if (name === 'float') name = 'cssFloat';else if (isCustomPropRE.test(name)) {\n instance.style.setProperty(name, value);\n } else {\n instance.style[name] = value;\n }\n }\n } // Apply DOM attributes\n\n\n names.forEach((name, i) => {\n instance.setAttribute(name, values[i]);\n });\n\n if (scrollTop !== void 0) {\n instance.scrollTop = scrollTop;\n }\n\n if (scrollLeft !== void 0) {\n instance.scrollLeft = scrollLeft;\n }\n });\n}\nlet isUnitlessNumber = {\n animationIterationCount: true,\n borderImageOutset: true,\n borderImageSlice: true,\n borderImageWidth: true,\n boxFlex: true,\n boxFlexGroup: true,\n boxOrdinalGroup: true,\n columnCount: true,\n columns: true,\n flex: true,\n flexGrow: true,\n flexPositive: true,\n flexShrink: true,\n flexNegative: true,\n flexOrder: true,\n gridRow: true,\n gridRowEnd: true,\n gridRowSpan: true,\n gridRowStart: true,\n gridColumn: true,\n gridColumnEnd: true,\n gridColumnSpan: true,\n gridColumnStart: true,\n fontWeight: true,\n lineClamp: true,\n lineHeight: true,\n opacity: true,\n order: true,\n orphans: true,\n tabSize: true,\n widows: true,\n zIndex: true,\n zoom: true,\n // SVG-related properties\n fillOpacity: true,\n floodOpacity: true,\n stopOpacity: true,\n strokeDasharray: true,\n strokeDashoffset: true,\n strokeMiterlimit: true,\n strokeOpacity: true,\n strokeWidth: true\n};\n\nconst prefixKey = (prefix, key) => prefix + key.charAt(0).toUpperCase() + key.substring(1);\n\nconst prefixes = ['Webkit', 'Ms', 'Moz', 'O'];\nisUnitlessNumber = Object.keys(isUnitlessNumber).reduce((acc, prop) => {\n prefixes.forEach(prefix => acc[prefixKey(prefix, prop)] = acc[prop]);\n return acc;\n}, isUnitlessNumber);\n\n/** The transform-functions\n * (https://developer.mozilla.org/fr/docs/Web/CSS/transform-function)\n * that you can pass as keys to your animated component style and that will be\n * animated. Perspective has been left out as it would conflict with the\n * non-transform perspective style.\n */\n\nconst domTransforms = /^(matrix|translate|scale|rotate|skew)/; // These keys have \"px\" units by default\n\nconst pxTransforms = /^(translate)/; // These keys have \"deg\" units by default\n\nconst degTransforms = /^(rotate|skew)/;\n\n/** Add a unit to the value when the value is unit-less (eg: a number) */\nconst addUnit = (value, unit) => is.num(value) && value !== 0 ? value + unit : value;\n/**\n * Checks if the input value matches the identity value.\n *\n * isValueIdentity(0, 0) // => true\n * isValueIdentity('0px', 0) // => true\n * isValueIdentity([0, '0px', 0], 0) // => true\n */\n\n\nconst isValueIdentity = (value, id) => is.arr(value) ? value.every(v => isValueIdentity(v, id)) : is.num(value) ? value === id : parseFloat(value) === id;\n\n/**\n * This AnimatedStyle will simplify animated components transforms by\n * interpolating all transform function passed as keys in the style object\n * including shortcuts such as x, y and z for translateX/Y/Z\n */\nclass AnimatedStyle extends AnimatedObject {\n constructor(_ref) {\n let {\n x,\n y,\n z\n } = _ref,\n style = _objectWithoutPropertiesLoose(_ref, [\"x\", \"y\", \"z\"]);\n\n /**\n * An array of arrays that contains the values (static or fluid)\n * used by each transform function.\n */\n const inputs = [];\n /**\n * An array of functions that take a list of values (static or fluid)\n * and returns (1) a CSS transform string and (2) a boolean that's true\n * when the transform has no effect (eg: an identity transform).\n */\n\n const transforms = []; // Combine x/y/z into translate3d\n\n if (x || y || z) {\n inputs.push([x || 0, y || 0, z || 0]);\n transforms.push(xyz => [\"translate3d(\" + xyz.map(v => addUnit(v, 'px')).join(',') + \")\", // prettier-ignore\n isValueIdentity(xyz, 0)]);\n } // Pluck any other transform-related props\n\n\n each(style, (value, key) => {\n if (key === 'transform') {\n inputs.push([value || '']);\n transforms.push(transform => [transform, transform === '']);\n } else if (domTransforms.test(key)) {\n delete style[key];\n if (is.und(value)) return;\n const unit = pxTransforms.test(key) ? 'px' : degTransforms.test(key) ? 'deg' : '';\n inputs.push(toArray(value));\n transforms.push(key === 'rotate3d' ? ([x, y, z, deg]) => [\"rotate3d(\" + x + \",\" + y + \",\" + z + \",\" + addUnit(deg, unit) + \")\", isValueIdentity(deg, 0)] : input => [key + \"(\" + input.map(v => addUnit(v, unit)).join(',') + \")\", isValueIdentity(input, key.startsWith('scale') ? 1 : 0)]);\n }\n });\n\n if (inputs.length) {\n style.transform = new FluidTransform(inputs, transforms);\n }\n\n super(style);\n }\n\n}\n/** @internal */\n\nclass FluidTransform extends FluidValue {\n constructor(inputs, transforms) {\n super();\n this.inputs = inputs;\n this.transforms = transforms;\n this._value = null;\n this._children = new Set();\n }\n\n get() {\n return this._value || (this._value = this._get());\n }\n\n _get() {\n let transform = '';\n let identity = true;\n each(this.inputs, (input, i) => {\n const arg1 = getFluidValue(input[0]);\n const [t, id] = this.transforms[i](is.arr(arg1) ? arg1 : input.map(getFluidValue));\n transform += ' ' + t;\n identity = identity && id;\n });\n return identity ? 'none' : transform;\n }\n\n addChild(child) {\n if (!this._children.size) {\n // Start observing our inputs once we have an observer.\n each(this.inputs, input => each(input, value => {\n const config = getFluidConfig(value);\n if (config) config.addChild(this);\n }));\n }\n\n this._children.add(child);\n }\n\n removeChild(child) {\n this._children.delete(child);\n\n if (!this._children.size) {\n // Stop observing our inputs once we have no observers.\n each(this.inputs, input => each(input, value => {\n const config = getFluidConfig(value);\n if (config) config.removeChild(this);\n }));\n }\n }\n\n onParentChange(event) {\n if (event.type == 'change') {\n this._value = null;\n }\n\n each(this._children, child => {\n child.onParentChange(event);\n });\n }\n\n}\n\nconst primitives = ['a', 'abbr', 'address', 'area', 'article', 'aside', 'audio', 'b', 'base', 'bdi', 'bdo', 'big', 'blockquote', 'body', 'br', 'button', 'canvas', 'caption', 'cite', 'code', 'col', 'colgroup', 'data', 'datalist', 'dd', 'del', 'details', 'dfn', 'dialog', 'div', 'dl', 'dt', 'em', 'embed', 'fieldset', 'figcaption', 'figure', 'footer', 'form', 'h1', 'h2', 'h3', 'h4', 'h5', 'h6', 'head', 'header', 'hgroup', 'hr', 'html', 'i', 'iframe', 'img', 'input', 'ins', 'kbd', 'keygen', 'label', 'legend', 'li', 'link', 'main', 'map', 'mark', 'menu', 'menuitem', 'meta', 'meter', 'nav', 'noscript', 'object', 'ol', 'optgroup', 'option', 'output', 'p', 'param', 'picture', 'pre', 'progress', 'q', 'rp', 'rt', 'ruby', 's', 'samp', 'script', 'section', 'select', 'small', 'source', 'span', 'strong', 'style', 'sub', 'summary', 'sup', 'table', 'tbody', 'td', 'textarea', 'tfoot', 'th', 'thead', 'time', 'title', 'tr', 'track', 'u', 'ul', 'var', 'video', 'wbr', // SVG\n'circle', 'clipPath', 'defs', 'ellipse', 'foreignObject', 'g', 'image', 'line', 'linearGradient', 'mask', 'path', 'pattern', 'polygon', 'polyline', 'radialGradient', 'rect', 'stop', 'svg', 'text', 'tspan'];\n\nGlobals$1.assign({\n colorNames,\n createStringInterpolator,\n batchedUpdates: unstable_batchedUpdates\n});\nconst host = createHost(primitives, {\n applyAnimatedValues,\n createAnimatedStyle: style => new AnimatedStyle(style),\n getComponentProps: (_ref) => {\n let props = _objectWithoutPropertiesLoose(_ref, [\"scrollTop\", \"scrollLeft\"]);\n\n return props;\n }\n});\nconst animated = host.animated;\n\nexport { animated as a, animated };\n//# sourceMappingURL=index.js.map\n","import * as React from 'react';\nexport var useLayoutEffect = typeof window !== 'undefined' &&\n window.document &&\n window.document.createElement\n ? React.useLayoutEffect\n : React.useEffect;\n","import { useState, useRef, useEffect } from 'react';\n\nfunction areInputsEqual(newInputs, lastInputs) {\n if (newInputs.length !== lastInputs.length) {\n return false;\n }\n\n for (var i = 0; i < newInputs.length; i++) {\n if (newInputs[i] !== lastInputs[i]) {\n return false;\n }\n }\n\n return true;\n}\n\nfunction useMemoOne(getResult, inputs) {\n var initial = useState(function () {\n return {\n inputs: inputs,\n result: getResult()\n };\n })[0];\n var isFirstRun = useRef(true);\n var committed = useRef(initial);\n var useCache = isFirstRun.current || Boolean(inputs && committed.current.inputs && areInputsEqual(inputs, committed.current.inputs));\n var cache = useCache ? committed.current : {\n inputs: inputs,\n result: getResult()\n };\n useEffect(function () {\n isFirstRun.current = false;\n committed.current = cache;\n }, [cache]);\n return cache.result;\n}\nfunction useCallbackOne(callback, inputs) {\n return useMemoOne(function () {\n return callback;\n }, inputs);\n}\nvar useMemo = useMemoOne;\nvar useCallback = useCallbackOne;\n\nexport { useCallback, useCallbackOne, useMemo, useMemoOne };\n","import { defineHidden, is, createInterpolator, each, getFluidConfig, isAnimatedString, useForceUpdate } from '@react-spring/shared';\nimport _extends from '@babel/runtime/helpers/esm/extends';\nimport { frameLoop } from '@react-spring/shared/globals';\nimport { forwardRef, useRef, createElement } from 'react';\nimport { useLayoutEffect } from 'react-layout-effect';\n\nconst $node = Symbol.for('Animated:node');\nconst isAnimated = value => !!value && value[$node] === value;\n/** Get the owner's `Animated` node. */\n\nconst getAnimated = owner => owner && owner[$node];\n/** Set the owner's `Animated` node. */\n\nconst setAnimated = (owner, node) => defineHidden(owner, $node, node);\n/** Get every `AnimatedValue` in the owner's `Animated` node. */\n\nconst getPayload = owner => owner && owner[$node] && owner[$node].getPayload();\nclass Animated {\n /** The cache of animated values */\n constructor() {\n this.payload = void 0;\n // This makes \"isAnimated\" return true.\n setAnimated(this, this);\n }\n /** Get the current value. Pass `true` for only animated values. */\n\n\n /** Get every `AnimatedValue` used by this node. */\n getPayload() {\n return this.payload || [];\n }\n\n}\n\n/** An animated number or a native attribute value */\n\nclass AnimatedValue extends Animated {\n constructor(_value) {\n super();\n this._value = _value;\n this.done = true;\n this.elapsedTime = void 0;\n this.lastPosition = void 0;\n this.lastVelocity = void 0;\n this.v0 = void 0;\n\n if (is.num(this._value)) {\n this.lastPosition = this._value;\n }\n }\n\n static create(from, _to) {\n return new AnimatedValue(from);\n }\n\n getPayload() {\n return [this];\n }\n\n getValue() {\n return this._value;\n }\n /**\n * Set the current value and optionally round it.\n *\n * The `step` argument does nothing whenever it equals `undefined` or `0`.\n * It works with fractions and whole numbers. The best use case is (probably)\n * rounding to the pixel grid with a step of:\n *\n * 1 / window.devicePixelRatio\n */\n\n\n setValue(value, step) {\n if (is.num(value)) {\n this.lastPosition = value;\n\n if (step) {\n value = Math.round(value / step) * step;\n\n if (this.done) {\n this.lastPosition = value;\n }\n }\n }\n\n if (this._value === value) {\n return false;\n }\n\n this._value = value;\n return true;\n }\n\n reset() {\n const {\n done\n } = this;\n this.done = false;\n\n if (is.num(this._value)) {\n this.elapsedTime = 0;\n this.lastPosition = this._value;\n if (done) this.lastVelocity = null;\n this.v0 = null;\n }\n }\n\n}\n\nclass AnimatedString extends AnimatedValue {\n constructor(from, to) {\n super(0);\n this._value = void 0;\n this._string = null;\n this._toString = void 0;\n this._toString = createInterpolator({\n output: [from, to]\n });\n }\n\n static create(from, to = from) {\n if (is.str(from) && is.str(to)) {\n return new AnimatedString(from, to);\n }\n\n throw TypeError('Expected \"from\" and \"to\" to be strings');\n }\n\n getValue() {\n let value = this._string;\n return value == null ? this._string = this._toString(this._value) : value;\n }\n\n setValue(value) {\n if (!is.num(value)) {\n this._string = value;\n this._value = 1;\n } else if (super.setValue(value)) {\n this._string = null;\n } else {\n return false;\n }\n\n return true;\n }\n\n reset(goal) {\n if (goal) {\n this._toString = createInterpolator({\n output: [this.getValue(), goal]\n });\n }\n\n this._value = 0;\n super.reset();\n }\n\n}\n\nconst TreeContext = {\n current: null\n};\n\n/** An object containing `Animated` nodes */\nclass AnimatedObject extends Animated {\n constructor(source = null) {\n super();\n this.source = void 0;\n this.setValue(source);\n }\n\n getValue(animated) {\n if (!this.source) return null;\n const values = {};\n each(this.source, (source, key) => {\n if (isAnimated(source)) {\n values[key] = source.getValue(animated);\n } else {\n const config = getFluidConfig(source);\n\n if (config) {\n values[key] = config.get();\n } else if (!animated) {\n values[key] = source;\n }\n }\n });\n return values;\n }\n /** Replace the raw object data */\n\n\n setValue(source) {\n this.source = source;\n this.payload = this._makePayload(source);\n }\n\n reset() {\n if (this.payload) {\n each(this.payload, node => node.reset());\n }\n }\n /** Create a payload set. */\n\n\n _makePayload(source) {\n if (source) {\n const payload = new Set();\n each(source, this._addToPayload, payload);\n return Array.from(payload);\n }\n }\n /** Add to a payload set. */\n\n\n _addToPayload(source) {\n const config = getFluidConfig(source);\n\n if (config && TreeContext.current) {\n TreeContext.current.dependencies.add(source);\n }\n\n const payload = getPayload(source);\n\n if (payload) {\n each(payload, node => this.add(node));\n }\n }\n\n}\n\n/** An array of animated nodes */\nclass AnimatedArray extends AnimatedObject {\n constructor(from, to) {\n super(null);\n this.source = void 0;\n super.setValue(this._makeAnimated(from, to));\n }\n\n static create(from, to) {\n return new AnimatedArray(from, to);\n }\n\n getValue() {\n return this.source.map(node => node.getValue());\n }\n\n setValue(newValue) {\n const payload = this.getPayload(); // Reuse the payload when lengths are equal.\n\n if (newValue && newValue.length == payload.length) {\n each(payload, (node, i) => node.setValue(newValue[i]));\n } else {\n // Remake the payload when length changes.\n this.source = this._makeAnimated(newValue);\n this.payload = this._makePayload(this.source);\n }\n }\n /** Convert the `from` and `to` values to an array of `Animated` nodes */\n\n\n _makeAnimated(from, to = from) {\n return from ? from.map((from, i) => (isAnimatedString(from) ? AnimatedString : AnimatedValue).create(from, to[i])) : [];\n }\n\n}\n\nclass AnimatedProps extends AnimatedObject {\n /** Equals true when an update is scheduled for \"end of frame\" */\n constructor(update) {\n super(null);\n this.update = update;\n this.dirty = false;\n }\n\n setValue(props, context) {\n if (!props) return; // The constructor passes null.\n\n if (context) {\n TreeContext.current = context;\n\n if (props.style) {\n const {\n createAnimatedStyle\n } = context.host;\n props = _extends(_extends({}, props), {}, {\n style: createAnimatedStyle(props.style)\n });\n }\n }\n\n super.setValue(props);\n TreeContext.current = null;\n }\n /** @internal */\n\n\n onParentChange({\n type\n }) {\n if (!this.dirty && type === 'change') {\n this.dirty = true;\n frameLoop.onFrame(() => {\n this.dirty = false;\n this.update();\n });\n }\n }\n\n}\n\nconst withAnimated = (Component, host) => forwardRef((rawProps, ref) => {\n const instanceRef = useRef(null);\n const hasInstance = // Function components must use \"forwardRef\" to avoid being\n // re-rendered on every animation frame.\n !is.fun(Component) || Component.prototype && Component.prototype.isReactComponent;\n const forceUpdate = useForceUpdate();\n const props = new AnimatedProps(() => {\n const instance = instanceRef.current;\n\n if (hasInstance && !instance) {\n return; // The wrapped component forgot to forward its ref.\n }\n\n const didUpdate = instance ? host.applyAnimatedValues(instance, props.getValue(true)) : false; // Re-render the component when native updates fail.\n\n if (didUpdate === false) {\n forceUpdate();\n }\n });\n const dependencies = new Set();\n props.setValue(rawProps, {\n dependencies,\n host\n });\n useLayoutEffect(() => {\n each(dependencies, dep => dep.addChild(props));\n return () => each(dependencies, dep => dep.removeChild(props));\n });\n return /*#__PURE__*/createElement(Component, _extends({}, host.getComponentProps(props.getValue()), {\n ref: hasInstance && (value => {\n instanceRef.current = updateRef(ref, value);\n })\n }));\n});\n\nfunction updateRef(ref, value) {\n if (ref) {\n if (is.fun(ref)) ref(value);else ref.current = value;\n }\n\n return value;\n}\n\n// For storing the animated version on the original component\nconst cacheKey = Symbol.for('AnimatedComponent');\nconst createHost = (components, {\n applyAnimatedValues = () => false,\n createAnimatedStyle = style => new AnimatedObject(style),\n getComponentProps = props => props\n} = {}) => {\n const hostConfig = {\n applyAnimatedValues,\n createAnimatedStyle,\n getComponentProps\n };\n\n const animated = Component => {\n const displayName = getDisplayName(Component) || 'Anonymous';\n\n if (is.str(Component)) {\n Component = withAnimated(Component, hostConfig);\n } else {\n Component = Component[cacheKey] || (Component[cacheKey] = withAnimated(Component, hostConfig));\n }\n\n Component.displayName = \"Animated(\" + displayName + \")\";\n return Component;\n };\n\n each(components, (Component, key) => {\n if (!is.str(key)) {\n key = getDisplayName(Component);\n }\n\n animated[key] = animated(Component);\n });\n return {\n animated\n };\n};\n\nconst getDisplayName = arg => is.str(arg) ? arg : arg && is.str(arg.displayName) ? arg.displayName : is.fun(arg) && arg.name || null;\n\nexport { Animated, AnimatedArray, AnimatedObject, AnimatedProps, AnimatedString, AnimatedValue, createHost, getAnimated, getPayload, isAnimated, setAnimated };\n//# sourceMappingURL=index.js.map\n","import * as G from './globals';\n// The global `requestAnimationFrame` must be dereferenced to avoid \"Illegal invocation\" errors\nvar requestAnimationFrame = function (fn) {\n return (void 0, G.requestAnimationFrame)(fn);\n};\n/**\n * FrameLoop executes its animations in order of lowest priority first.\n * Animations are retained until idle.\n */\nvar FrameLoop = /** @class */ (function () {\n function FrameLoop(raf) {\n if (raf === void 0) { raf = requestAnimationFrame; }\n var idle = true;\n var writing = false;\n // The most recent framestamp\n var lastTime = 0;\n // The active animations for the current frame, sorted by lowest priority first\n var animations = [];\n // The priority of the currently advancing animation.\n // To protect against a race condition whenever a frame is being processed,\n // where the filtering of `animations` is corrupted with a shifting index,\n // causing animations to potentially advance 2x faster than intended.\n var priority = 0;\n // Animations starting on the next frame\n var startQueue = new Set();\n // Flushed after all animations are updated.\n // Used to dispatch events to an \"onFrame\" prop, for example.\n var frameQueue = new Set();\n // Flushed at the very end of each frame.\n // Used to avoid layout thrashing in @react-spring/web, for example.\n var writeQueue = new Set();\n // Add an animation to the frameloop\n var start = function (animation) {\n var index = animations.indexOf(animation);\n if (index < 0) {\n index = animations.findIndex(function (other) { return other.priority > animation.priority; });\n animations.splice(~index ? index : animations.length, 0, animation);\n }\n };\n var loop = function () {\n if (idle)\n return;\n try {\n advance();\n raf(loop);\n }\n catch (e) {\n console.error(e);\n }\n };\n // Start the frameloop\n var kickoff = function () {\n if (idle) {\n idle = false;\n // To minimize frame skips, the frameloop never stops.\n if (lastTime == 0) {\n lastTime = G.now();\n raf(loop);\n }\n }\n };\n var timeoutQueue = [];\n this.setTimeout = function (handler, ms) {\n var time = G.now() + ms;\n var cancel = function () {\n var index = timeoutQueue.findIndex(function (t) { return t.cancel == cancel; });\n if (index >= 0) {\n timeoutQueue.splice(index, 1);\n }\n };\n var index = findIndex(timeoutQueue, function (t) { return t.time > time; });\n var timeout = { time: time, handler: handler, cancel: cancel };\n timeoutQueue.splice(index, 0, timeout);\n kickoff();\n return timeout;\n };\n // Process the current frame.\n var advance = (this.advance = function () {\n var time = G.now();\n // Start animations that were added during last frame.\n if (startQueue.size) {\n startQueue.forEach(start);\n startQueue.clear();\n }\n // Flush the timeout queue.\n if (timeoutQueue.length) {\n G.batchedUpdates(function () {\n var count = findIndex(timeoutQueue, function (t) { return t.time > time; });\n timeoutQueue.splice(0, count).forEach(function (t) { return t.handler(); });\n });\n }\n if (time > lastTime) {\n // http://gafferongames.com/game-physics/fix-your-timestep/\n var dt_1 = Math.min(64, time - lastTime);\n lastTime = time;\n G.batchedUpdates(function () {\n // Animations can be added while the frameloop is updating,\n // but they need a higher priority to be started on this frame.\n if (animations.length) {\n G.willAdvance(animations);\n animations = animations.filter(function (animation) {\n priority = animation.priority;\n // Animations may go idle before the next frame.\n if (!animation.idle) {\n animation.advance(dt_1);\n }\n // Remove idle animations.\n return !animation.idle;\n });\n priority = 0;\n }\n if (frameQueue.size) {\n frameQueue.forEach(function (onFrame) { return onFrame(time); });\n frameQueue.clear();\n }\n if (writeQueue.size) {\n writing = true;\n writeQueue.forEach(function (write) { return write(time); });\n writeQueue.clear();\n writing = false;\n }\n });\n }\n });\n this.start = function (animation) {\n if (priority > animation.priority) {\n startQueue.add(animation);\n }\n else {\n start(animation);\n kickoff();\n }\n };\n this.onFrame = function (cb) {\n frameQueue.add(cb);\n kickoff();\n };\n this.onWrite = function (cb) {\n if (writing)\n cb(lastTime);\n else\n writeQueue.add(cb);\n };\n // Expose internals for testing.\n if (typeof process !== 'undefined' &&\n process.env.NODE_ENV !== 'production') {\n var dispose_1 = function () {\n idle = true;\n startQueue.clear();\n timeoutQueue.length = 0;\n };\n Object.defineProperties(this, {\n _animations: { get: function () { return animations; } },\n _dispose: { get: function () { return dispose_1; } },\n });\n }\n }\n return FrameLoop;\n}());\nexport { FrameLoop };\n/** Like `Array.prototype.findIndex` but returns `arr.length` instead of `-1` */\nfunction findIndex(arr, test) {\n var index = arr.findIndex(test);\n return index < 0 ? arr.length : index;\n}\n//# sourceMappingURL=FrameLoop.js.map","// const INTEGER = '[-+]?\\\\d+';\nvar NUMBER = '[-+]?\\\\d*\\\\.?\\\\d+';\nvar PERCENTAGE = NUMBER + '%';\nfunction call() {\n var parts = [];\n for (var _i = 0; _i < arguments.length; _i++) {\n parts[_i] = arguments[_i];\n }\n return '\\\\(\\\\s*(' + parts.join(')\\\\s*,\\\\s*(') + ')\\\\s*\\\\)';\n}\nexport var rgb = new RegExp('rgb' + call(NUMBER, NUMBER, NUMBER));\nexport var rgba = new RegExp('rgba' + call(NUMBER, NUMBER, NUMBER, NUMBER));\nexport var hsl = new RegExp('hsl' + call(NUMBER, PERCENTAGE, PERCENTAGE));\nexport var hsla = new RegExp('hsla' + call(NUMBER, PERCENTAGE, PERCENTAGE, NUMBER));\nexport var hex3 = /^#([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/;\nexport var hex4 = /^#([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/;\nexport var hex6 = /^#([0-9a-fA-F]{6})$/;\nexport var hex8 = /^#([0-9a-fA-F]{8})$/;\n//# sourceMappingURL=colorMatchers.js.map","import { normalizeColor } from './normalizeColor';\nexport function colorToRgba(input) {\n var int32Color = normalizeColor(input);\n if (int32Color === null)\n return input;\n int32Color = int32Color || 0;\n var r = (int32Color & 0xff000000) >>> 24;\n var g = (int32Color & 0x00ff0000) >>> 16;\n var b = (int32Color & 0x0000ff00) >>> 8;\n var a = (int32Color & 0x000000ff) / 255;\n return \"rgba(\" + r + \", \" + g + \", \" + b + \", \" + a + \")\";\n}\n//# sourceMappingURL=colorToRgba.js.map","// http://www.w3.org/TR/css3-color/#svg-color\nvar colors = {\n transparent: 0x00000000,\n aliceblue: 0xf0f8ffff,\n antiquewhite: 0xfaebd7ff,\n aqua: 0x00ffffff,\n aquamarine: 0x7fffd4ff,\n azure: 0xf0ffffff,\n beige: 0xf5f5dcff,\n bisque: 0xffe4c4ff,\n black: 0x000000ff,\n blanchedalmond: 0xffebcdff,\n blue: 0x0000ffff,\n blueviolet: 0x8a2be2ff,\n brown: 0xa52a2aff,\n burlywood: 0xdeb887ff,\n burntsienna: 0xea7e5dff,\n cadetblue: 0x5f9ea0ff,\n chartreuse: 0x7fff00ff,\n chocolate: 0xd2691eff,\n coral: 0xff7f50ff,\n cornflowerblue: 0x6495edff,\n cornsilk: 0xfff8dcff,\n crimson: 0xdc143cff,\n cyan: 0x00ffffff,\n darkblue: 0x00008bff,\n darkcyan: 0x008b8bff,\n darkgoldenrod: 0xb8860bff,\n darkgray: 0xa9a9a9ff,\n darkgreen: 0x006400ff,\n darkgrey: 0xa9a9a9ff,\n darkkhaki: 0xbdb76bff,\n darkmagenta: 0x8b008bff,\n darkolivegreen: 0x556b2fff,\n darkorange: 0xff8c00ff,\n darkorchid: 0x9932ccff,\n darkred: 0x8b0000ff,\n darksalmon: 0xe9967aff,\n darkseagreen: 0x8fbc8fff,\n darkslateblue: 0x483d8bff,\n darkslategray: 0x2f4f4fff,\n darkslategrey: 0x2f4f4fff,\n darkturquoise: 0x00ced1ff,\n darkviolet: 0x9400d3ff,\n deeppink: 0xff1493ff,\n deepskyblue: 0x00bfffff,\n dimgray: 0x696969ff,\n dimgrey: 0x696969ff,\n dodgerblue: 0x1e90ffff,\n firebrick: 0xb22222ff,\n floralwhite: 0xfffaf0ff,\n forestgreen: 0x228b22ff,\n fuchsia: 0xff00ffff,\n gainsboro: 0xdcdcdcff,\n ghostwhite: 0xf8f8ffff,\n gold: 0xffd700ff,\n goldenrod: 0xdaa520ff,\n gray: 0x808080ff,\n green: 0x008000ff,\n greenyellow: 0xadff2fff,\n grey: 0x808080ff,\n honeydew: 0xf0fff0ff,\n hotpink: 0xff69b4ff,\n indianred: 0xcd5c5cff,\n indigo: 0x4b0082ff,\n ivory: 0xfffff0ff,\n khaki: 0xf0e68cff,\n lavender: 0xe6e6faff,\n lavenderblush: 0xfff0f5ff,\n lawngreen: 0x7cfc00ff,\n lemonchiffon: 0xfffacdff,\n lightblue: 0xadd8e6ff,\n lightcoral: 0xf08080ff,\n lightcyan: 0xe0ffffff,\n lightgoldenrodyellow: 0xfafad2ff,\n lightgray: 0xd3d3d3ff,\n lightgreen: 0x90ee90ff,\n lightgrey: 0xd3d3d3ff,\n lightpink: 0xffb6c1ff,\n lightsalmon: 0xffa07aff,\n lightseagreen: 0x20b2aaff,\n lightskyblue: 0x87cefaff,\n lightslategray: 0x778899ff,\n lightslategrey: 0x778899ff,\n lightsteelblue: 0xb0c4deff,\n lightyellow: 0xffffe0ff,\n lime: 0x00ff00ff,\n limegreen: 0x32cd32ff,\n linen: 0xfaf0e6ff,\n magenta: 0xff00ffff,\n maroon: 0x800000ff,\n mediumaquamarine: 0x66cdaaff,\n mediumblue: 0x0000cdff,\n mediumorchid: 0xba55d3ff,\n mediumpurple: 0x9370dbff,\n mediumseagreen: 0x3cb371ff,\n mediumslateblue: 0x7b68eeff,\n mediumspringgreen: 0x00fa9aff,\n mediumturquoise: 0x48d1ccff,\n mediumvioletred: 0xc71585ff,\n midnightblue: 0x191970ff,\n mintcream: 0xf5fffaff,\n mistyrose: 0xffe4e1ff,\n moccasin: 0xffe4b5ff,\n navajowhite: 0xffdeadff,\n navy: 0x000080ff,\n oldlace: 0xfdf5e6ff,\n olive: 0x808000ff,\n olivedrab: 0x6b8e23ff,\n orange: 0xffa500ff,\n orangered: 0xff4500ff,\n orchid: 0xda70d6ff,\n palegoldenrod: 0xeee8aaff,\n palegreen: 0x98fb98ff,\n paleturquoise: 0xafeeeeff,\n palevioletred: 0xdb7093ff,\n papayawhip: 0xffefd5ff,\n peachpuff: 0xffdab9ff,\n peru: 0xcd853fff,\n pink: 0xffc0cbff,\n plum: 0xdda0ddff,\n powderblue: 0xb0e0e6ff,\n purple: 0x800080ff,\n rebeccapurple: 0x663399ff,\n red: 0xff0000ff,\n rosybrown: 0xbc8f8fff,\n royalblue: 0x4169e1ff,\n saddlebrown: 0x8b4513ff,\n salmon: 0xfa8072ff,\n sandybrown: 0xf4a460ff,\n seagreen: 0x2e8b57ff,\n seashell: 0xfff5eeff,\n sienna: 0xa0522dff,\n silver: 0xc0c0c0ff,\n skyblue: 0x87ceebff,\n slateblue: 0x6a5acdff,\n slategray: 0x708090ff,\n slategrey: 0x708090ff,\n snow: 0xfffafaff,\n springgreen: 0x00ff7fff,\n steelblue: 0x4682b4ff,\n tan: 0xd2b48cff,\n teal: 0x008080ff,\n thistle: 0xd8bfd8ff,\n tomato: 0xff6347ff,\n turquoise: 0x40e0d0ff,\n violet: 0xee82eeff,\n wheat: 0xf5deb3ff,\n white: 0xffffffff,\n whitesmoke: 0xf5f5f5ff,\n yellow: 0xffff00ff,\n yellowgreen: 0x9acd32ff,\n};\nexport default colors;\n//# sourceMappingURL=colors.js.map","import * as G from './globals';\nimport { is } from './helpers';\nexport var createInterpolator = function (range, output, extrapolate) {\n if (is.fun(range)) {\n return range;\n }\n if (is.arr(range)) {\n return createInterpolator({\n range: range,\n output: output,\n extrapolate: extrapolate,\n });\n }\n if (is.str(range.output[0])) {\n return G.createStringInterpolator(range);\n }\n var config = range;\n var outputRange = config.output;\n var inputRange = config.range || [0, 1];\n var extrapolateLeft = config.extrapolateLeft || config.extrapolate || 'extend';\n var extrapolateRight = config.extrapolateRight || config.extrapolate || 'extend';\n var easing = config.easing || (function (t) { return t; });\n return function (input) {\n var range = findRange(input, inputRange);\n return interpolate(input, inputRange[range], inputRange[range + 1], outputRange[range], outputRange[range + 1], easing, extrapolateLeft, extrapolateRight, config.map);\n };\n};\nfunction interpolate(input, inputMin, inputMax, outputMin, outputMax, easing, extrapolateLeft, extrapolateRight, map) {\n var result = map ? map(input) : input;\n // Extrapolate\n if (result < inputMin) {\n if (extrapolateLeft === 'identity')\n return result;\n else if (extrapolateLeft === 'clamp')\n result = inputMin;\n }\n if (result > inputMax) {\n if (extrapolateRight === 'identity')\n return result;\n else if (extrapolateRight === 'clamp')\n result = inputMax;\n }\n if (outputMin === outputMax)\n return outputMin;\n if (inputMin === inputMax)\n return input <= inputMin ? outputMin : outputMax;\n // Input Range\n if (inputMin === -Infinity)\n result = -result;\n else if (inputMax === Infinity)\n result = result - inputMin;\n else\n result = (result - inputMin) / (inputMax - inputMin);\n // Easing\n result = easing(result);\n // Output Range\n if (outputMin === -Infinity)\n result = -result;\n else if (outputMax === Infinity)\n result = result + outputMin;\n else\n result = result * (outputMax - outputMin) + outputMin;\n return result;\n}\nfunction findRange(input, inputRange) {\n for (var i = 1; i < inputRange.length - 1; ++i)\n if (inputRange[i] >= input)\n break;\n return i - 1;\n}\n//# sourceMappingURL=createInterpolator.js.map","var prefix = 'react-spring: ';\nvar flagInterpolate = false;\nexport function deprecateInterpolate() {\n if (!flagInterpolate) {\n flagInterpolate = true;\n console.warn(prefix +\n 'The \"interpolate\" function is deprecated in v10 (use \"to\" instead)');\n }\n}\n//# sourceMappingURL=deprecations.js.map","import { FrameLoop } from './FrameLoop';\nimport { noop } from './helpers';\n//\n// Required\n//\nexport var createStringInterpolator;\nexport var frameLoop = new FrameLoop();\n//\n// Optional\n//\nexport var to;\nexport var now = function () { return performance.now(); };\nexport var colorNames = null;\nexport var skipAnimation = false;\nexport var requestAnimationFrame = typeof window !== 'undefined' ? window.requestAnimationFrame : function () { return -1; };\nexport var batchedUpdates = function (callback) { return callback(); };\nexport var willAdvance = noop;\nexport var assign = function (globals) {\n var _a;\n return (_a = Object.assign({\n to: to,\n now: now,\n frameLoop: frameLoop,\n colorNames: colorNames,\n skipAnimation: skipAnimation,\n createStringInterpolator: createStringInterpolator,\n requestAnimationFrame: requestAnimationFrame,\n batchedUpdates: batchedUpdates,\n willAdvance: willAdvance,\n }, pluckDefined(globals)), to = _a.to, now = _a.now, frameLoop = _a.frameLoop, colorNames = _a.colorNames, skipAnimation = _a.skipAnimation, createStringInterpolator = _a.createStringInterpolator, requestAnimationFrame = _a.requestAnimationFrame, batchedUpdates = _a.batchedUpdates, willAdvance = _a.willAdvance, _a);\n};\n// Ignore undefined values\nfunction pluckDefined(globals) {\n var defined = {};\n for (var key in globals) {\n if (globals[key] !== undefined)\n defined[key] = globals[key];\n }\n return defined;\n}\n//# sourceMappingURL=globals.js.map","import * as G from './globals';\nexport var noop = function () { };\nexport var defineHidden = function (obj, key, value) {\n return Object.defineProperty(obj, key, { value: value, writable: true, configurable: true });\n};\nexport var is = {\n arr: Array.isArray,\n obj: function (a) {\n return !!a && a.constructor.name === 'Object';\n },\n fun: function (a) { return typeof a === 'function'; },\n str: function (a) { return typeof a === 'string'; },\n num: function (a) { return typeof a === 'number'; },\n und: function (a) { return a === undefined; },\n};\n/** Compare animatable values */\nexport function isEqual(a, b) {\n if (is.arr(a)) {\n if (!is.arr(b) || a.length !== b.length)\n return false;\n for (var i = 0; i < a.length; i++) {\n if (a[i] !== b[i])\n return false;\n }\n return true;\n }\n return a === b;\n}\n// Not all strings can be animated (eg: {display: \"none\"})\nexport var isAnimatedString = function (value) {\n return is.str(value) &&\n (value[0] == '#' ||\n /\\d/.test(value) ||\n !!(G.colorNames && G.colorNames[value]));\n};\n/** An unsafe object/array/set iterator that allows for better minification */\nexport var each = function (obj, cb, ctx) {\n if (is.fun(obj.forEach)) {\n obj.forEach(cb, ctx);\n }\n else {\n Object.keys(obj).forEach(function (key) {\n return cb.call(ctx, obj[key], key);\n });\n }\n};\nexport var toArray = function (a) {\n return is.und(a) ? [] : is.arr(a) ? a : [a];\n};\nexport function flush(queue, iterator) {\n if (queue.size) {\n var items = Array.from(queue);\n queue.clear();\n each(items, iterator);\n }\n}\n//# sourceMappingURL=helpers.js.map","import { useEffect, useRef, useState } from 'react';\nexport var useOnce = function (effect) { return useEffect(effect, []); };\n/** Return a function that re-renders this component, if still mounted */\nexport var useForceUpdate = function () {\n var update = useState(0)[1];\n var unmounted = useRef(false);\n useOnce(function () { return function () {\n unmounted.current = true;\n }; });\n return function () {\n if (!unmounted.current) {\n update({});\n }\n };\n};\n/** Use a value from the previous render */\nexport function usePrev(value) {\n var prevRef = useRef(undefined);\n useEffect(function () {\n prevRef.current = value;\n });\n return prevRef.current;\n}\n//# sourceMappingURL=hooks.js.map","/*\nhttps://github.com/react-community/normalize-css-color\n\nBSD 3-Clause License\n\nCopyright (c) 2016, React Community\nAll rights reserved.\n\nRedistribution and use in source and binary forms, with or without\nmodification, are permitted provided that the following conditions are met:\n\n* Redistributions of source code must retain the above copyright notice, this\n list of conditions and the following disclaimer.\n\n* Redistributions in binary form must reproduce the above copyright notice,\n this list of conditions and the following disclaimer in the documentation\n and/or other materials provided with the distribution.\n\n* Neither the name of the copyright holder nor the names of its\n contributors may be used to endorse or promote products derived from\n this software without specific prior written permission.\n\nTHIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS \"AS IS\"\nAND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE\nIMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE\nDISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE\nFOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL\nDAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR\nSERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER\nCAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,\nOR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE\nOF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\n*/\nimport * as matchers from './colorMatchers';\nimport * as G from './globals';\nexport function normalizeColor(color) {\n var match;\n if (typeof color === 'number') {\n return color >>> 0 === color && color >= 0 && color <= 0xffffffff\n ? color\n : null;\n }\n // Ordered based on occurrences on Facebook codebase\n if ((match = matchers.hex6.exec(color)))\n return parseInt(match[1] + 'ff', 16) >>> 0;\n if (G.colorNames && G.colorNames[color] !== undefined) {\n return G.colorNames[color];\n }\n if ((match = matchers.rgb.exec(color))) {\n return (((parse255(match[1]) << 24) | // r\n (parse255(match[2]) << 16) | // g\n (parse255(match[3]) << 8) | // b\n 0x000000ff) >>> // a\n 0);\n }\n if ((match = matchers.rgba.exec(color))) {\n return (((parse255(match[1]) << 24) | // r\n (parse255(match[2]) << 16) | // g\n (parse255(match[3]) << 8) | // b\n parse1(match[4])) >>> // a\n 0);\n }\n if ((match = matchers.hex3.exec(color))) {\n return (parseInt(match[1] +\n match[1] + // r\n match[2] +\n match[2] + // g\n match[3] +\n match[3] + // b\n 'ff', // a\n 16) >>> 0);\n }\n // https://drafts.csswg.org/css-color-4/#hex-notation\n if ((match = matchers.hex8.exec(color)))\n return parseInt(match[1], 16) >>> 0;\n if ((match = matchers.hex4.exec(color))) {\n return (parseInt(match[1] +\n match[1] + // r\n match[2] +\n match[2] + // g\n match[3] +\n match[3] + // b\n match[4] +\n match[4], // a\n 16) >>> 0);\n }\n if ((match = matchers.hsl.exec(color))) {\n return ((hslToRgb(parse360(match[1]), // h\n parsePercentage(match[2]), // s\n parsePercentage(match[3]) // l\n ) |\n 0x000000ff) >>> // a\n 0);\n }\n if ((match = matchers.hsla.exec(color))) {\n return ((hslToRgb(parse360(match[1]), // h\n parsePercentage(match[2]), // s\n parsePercentage(match[3]) // l\n ) |\n parse1(match[4])) >>> // a\n 0);\n }\n return null;\n}\nfunction hue2rgb(h, c, x) {\n if (h < 60)\n return [c, x, 0];\n if (h < 120)\n return [x, c, 0];\n if (h < 180)\n return [0, c, x];\n if (h < 240)\n return [0, x, c];\n if (h < 300)\n return [x, 0, c];\n return [c, 0, x];\n}\nfunction hslToRgb(h, s, l) {\n var C = (1 - Math.abs(2 * l - 1)) * s;\n var X = C * (1 - Math.abs(((h / 60) % 2) - 1));\n var M = l - C / 2;\n var _a = hue2rgb(h, C, X), R1 = _a[0], G1 = _a[1], B1 = _a[2];\n return ((Math.round((R1 + M) * 255) << 24) |\n (Math.round((G1 + M) * 255) << 16) |\n (Math.round((B1 + M) * 255) << 8));\n}\nfunction parse255(str) {\n var int = parseInt(str, 10);\n if (int < 0)\n return 0;\n if (int > 255)\n return 255;\n return int;\n}\nfunction parse360(str) {\n var int = parseFloat(str);\n return (((int % 360) + 360) % 360) / 360;\n}\nfunction parse1(str) {\n var num = parseFloat(str);\n if (num < 0)\n return 0;\n if (num > 1)\n return 255;\n return Math.round(num * 255);\n}\nfunction parsePercentage(str) {\n // parseFloat conveniently ignores the final %\n var int = parseFloat(str);\n if (int < 0)\n return 0;\n if (int > 100)\n return 1;\n return int / 100;\n}\n//# sourceMappingURL=normalizeColor.js.map","import { __assign } from \"tslib\";\nimport { getFluidValue } from 'fluids';\nimport { createInterpolator } from './createInterpolator';\nimport { colorToRgba } from './colorToRgba';\nimport * as G from './globals';\n// Problem: https://github.com/animatedjs/animated/pull/102\n// Solution: https://stackoverflow.com/questions/638565/parsing-scientific-notation-sensibly/658662\nvar numberRegex = /[+\\-]?(?:0|[1-9]\\d*)(?:\\.\\d*)?(?:[eE][+\\-]?\\d+)?/g;\n// Covers rgb, rgba, hsl, hsla\n// Taken from https://gist.github.com/olmokramer/82ccce673f86db7cda5e\nvar colorRegex = /(#(?:[0-9a-f]{2}){2,4}|(#[0-9a-f]{3})|(rgb|hsl)a?\\((-?\\d+%?[,\\s]+){2,3}\\s*[\\d\\.]+%?\\))/gi;\n// Covers color names (transparent, blue, etc.)\nvar colorNamesRegex;\n// rgba requires that the r,g,b are integers.... so we want to round them,\n// but we *dont* want to round the opacity (4th column).\nvar rgbaRegex = /rgba\\(([0-9\\.-]+), ([0-9\\.-]+), ([0-9\\.-]+), ([0-9\\.-]+)\\)/gi;\nvar rgbaRound = function (_, p1, p2, p3, p4) {\n return \"rgba(\" + Math.round(p1) + \", \" + Math.round(p2) + \", \" + Math.round(p3) + \", \" + p4 + \")\";\n};\n/**\n * Supports string shapes by extracting numbers so new values can be computed,\n * and recombines those values into new strings of the same shape. Supports\n * things like:\n *\n * \"rgba(123, 42, 99, 0.36)\" // colors\n * \"-45deg\" // values with units\n * \"0 2px 2px 0px rgba(0, 0, 0, 0.12)\" // CSS box-shadows\n * \"rotate(0deg) translate(2px, 3px)\" // CSS transforms\n */\nexport var createStringInterpolator = function (config) {\n if (!colorNamesRegex)\n colorNamesRegex = G.colorNames\n ? new RegExp(\"(\" + Object.keys(G.colorNames).join('|') + \")\", 'g')\n : /^\\b$/; // never match\n // Convert colors to rgba(...)\n var output = config.output.map(function (value) {\n return getFluidValue(value)\n .replace(colorRegex, colorToRgba)\n .replace(colorNamesRegex, colorToRgba);\n });\n // Convert [\"1px 2px\", \"0px 0px\"] into [[1, 2], [0, 0]]\n var keyframes = output.map(function (value) { return value.match(numberRegex).map(Number); });\n // Convert [\"1px 2px\", \"0px 0px\"] into [[1, 0], [2, 0]]\n var outputRanges = keyframes[0].map(function (_, i) {\n return keyframes.map(function (values) {\n if (!(i in values)) {\n throw Error('The arity of each \"output\" value must be equal');\n }\n return values[i];\n });\n });\n // Create an interpolator for each animated number\n var interpolators = outputRanges.map(function (output) {\n return createInterpolator(__assign(__assign({}, config), { output: output }));\n });\n // Use the first `output` as a template for each call\n return function (input) {\n var i = 0;\n return output[0]\n .replace(numberRegex, function () { return String(interpolators[i++](input)); })\n .replace(rgbaRegex, rgbaRound);\n };\n};\n//# sourceMappingURL=stringInterpolation.js.map","//# sourceMappingURL=types.js.map","var $config = Symbol.for('FluidValue:config');\nexport { hasFluidValue, getFluidValue, getFluidConfig, setFluidConfig, addFluidObserver, };\n/** Does the given value have a `FluidConfig` object? */\nvar hasFluidValue = function (arg) { return !!getFluidConfig(arg); };\nfunction getFluidValue(arg) {\n var config = getFluidConfig(arg);\n return config ? config.get() : arg;\n}\nfunction getFluidConfig(arg) {\n if (arg)\n return arg[$config];\n}\n/** Set the methods for observing the given object. */\nfunction setFluidConfig(target, config) {\n Object.defineProperty(target, $config, {\n value: config,\n configurable: true,\n });\n}\nfunction addFluidObserver(target, observer) {\n var config = getFluidConfig(target);\n if (config) {\n config.addChild(observer);\n return function () { return config.removeChild(observer); };\n }\n}\n/**\n * This class stores a single dynamic value, which can be observed by multiple `FluidObserver` objects.\n *\n * In order to support non-writable streams, this class doesn't expect a `set` method to exist.\n *\n * It can send *any* event to observers, not only change events.\n */\nvar FluidValue = /** @class */ (function () {\n function FluidValue() {\n setFluidConfig(this, this);\n }\n return FluidValue;\n}());\nexport { FluidValue };\n//# sourceMappingURL=index.js.map","/*! *****************************************************************************\r\nCopyright (c) Microsoft Corporation.\r\n\r\nPermission to use, copy, modify, and/or distribute this software for any\r\npurpose with or without fee is hereby granted.\r\n\r\nTHE SOFTWARE IS PROVIDED \"AS IS\" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH\r\nREGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY\r\nAND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,\r\nINDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM\r\nLOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR\r\nOTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR\r\nPERFORMANCE OF THIS SOFTWARE.\r\n***************************************************************************** */\r\n/* global Reflect, Promise */\r\n\r\nvar extendStatics = function(d, b) {\r\n extendStatics = Object.setPrototypeOf ||\r\n ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||\r\n function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };\r\n return extendStatics(d, b);\r\n};\r\n\r\nexport function __extends(d, b) {\r\n extendStatics(d, b);\r\n function __() { this.constructor = d; }\r\n d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());\r\n}\r\n\r\nexport var __assign = function() {\r\n __assign = Object.assign || function __assign(t) {\r\n for (var s, i = 1, n = arguments.length; i < n; i++) {\r\n s = arguments[i];\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];\r\n }\r\n return t;\r\n }\r\n return __assign.apply(this, arguments);\r\n}\r\n\r\nexport function __rest(s, e) {\r\n var t = {};\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)\r\n t[p] = s[p];\r\n if (s != null && typeof Object.getOwnPropertySymbols === \"function\")\r\n for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {\r\n if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))\r\n t[p[i]] = s[p[i]];\r\n }\r\n return t;\r\n}\r\n\r\nexport function __decorate(decorators, target, key, desc) {\r\n var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;\r\n if (typeof Reflect === \"object\" && typeof Reflect.decorate === \"function\") r = Reflect.decorate(decorators, target, key, desc);\r\n else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;\r\n return c > 3 && r && Object.defineProperty(target, key, r), r;\r\n}\r\n\r\nexport function __param(paramIndex, decorator) {\r\n return function (target, key) { decorator(target, key, paramIndex); }\r\n}\r\n\r\nexport function __metadata(metadataKey, metadataValue) {\r\n if (typeof Reflect === \"object\" && typeof Reflect.metadata === \"function\") return Reflect.metadata(metadataKey, metadataValue);\r\n}\r\n\r\nexport function __awaiter(thisArg, _arguments, P, generator) {\r\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\r\n return new (P || (P = Promise))(function (resolve, reject) {\r\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\r\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\r\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\r\n step((generator = generator.apply(thisArg, _arguments || [])).next());\r\n });\r\n}\r\n\r\nexport function __generator(thisArg, body) {\r\n var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;\r\n return g = { next: verb(0), \"throw\": verb(1), \"return\": verb(2) }, typeof Symbol === \"function\" && (g[Symbol.iterator] = function() { return this; }), g;\r\n function verb(n) { return function (v) { return step([n, v]); }; }\r\n function step(op) {\r\n if (f) throw new TypeError(\"Generator is already executing.\");\r\n while (_) try {\r\n if (f = 1, y && (t = op[0] & 2 ? y[\"return\"] : op[0] ? y[\"throw\"] || ((t = y[\"return\"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;\r\n if (y = 0, t) op = [op[0] & 2, t.value];\r\n switch (op[0]) {\r\n case 0: case 1: t = op; break;\r\n case 4: _.label++; return { value: op[1], done: false };\r\n case 5: _.label++; y = op[1]; op = [0]; continue;\r\n case 7: op = _.ops.pop(); _.trys.pop(); continue;\r\n default:\r\n if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }\r\n if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }\r\n if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }\r\n if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }\r\n if (t[2]) _.ops.pop();\r\n _.trys.pop(); continue;\r\n }\r\n op = body.call(thisArg, _);\r\n } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }\r\n if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };\r\n }\r\n}\r\n\r\nexport function __createBinding(o, m, k, k2) {\r\n if (k2 === undefined) k2 = k;\r\n o[k2] = m[k];\r\n}\r\n\r\nexport function __exportStar(m, exports) {\r\n for (var p in m) if (p !== \"default\" && !exports.hasOwnProperty(p)) exports[p] = m[p];\r\n}\r\n\r\nexport function __values(o) {\r\n var s = typeof Symbol === \"function\" && Symbol.iterator, m = s && o[s], i = 0;\r\n if (m) return m.call(o);\r\n if (o && typeof o.length === \"number\") return {\r\n next: function () {\r\n if (o && i >= o.length) o = void 0;\r\n return { value: o && o[i++], done: !o };\r\n }\r\n };\r\n throw new TypeError(s ? \"Object is not iterable.\" : \"Symbol.iterator is not defined.\");\r\n}\r\n\r\nexport function __read(o, n) {\r\n var m = typeof Symbol === \"function\" && o[Symbol.iterator];\r\n if (!m) return o;\r\n var i = m.call(o), r, ar = [], e;\r\n try {\r\n while ((n === void 0 || n-- > 0) && !(r = i.next()).done) ar.push(r.value);\r\n }\r\n catch (error) { e = { error: error }; }\r\n finally {\r\n try {\r\n if (r && !r.done && (m = i[\"return\"])) m.call(i);\r\n }\r\n finally { if (e) throw e.error; }\r\n }\r\n return ar;\r\n}\r\n\r\nexport function __spread() {\r\n for (var ar = [], i = 0; i < arguments.length; i++)\r\n ar = ar.concat(__read(arguments[i]));\r\n return ar;\r\n}\r\n\r\nexport function __spreadArrays() {\r\n for (var s = 0, i = 0, il = arguments.length; i < il; i++) s += arguments[i].length;\r\n for (var r = Array(s), k = 0, i = 0; i < il; i++)\r\n for (var a = arguments[i], j = 0, jl = a.length; j < jl; j++, k++)\r\n r[k] = a[j];\r\n return r;\r\n};\r\n\r\nexport function __await(v) {\r\n return this instanceof __await ? (this.v = v, this) : new __await(v);\r\n}\r\n\r\nexport function __asyncGenerator(thisArg, _arguments, generator) {\r\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\r\n var g = generator.apply(thisArg, _arguments || []), i, q = [];\r\n return i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i;\r\n function verb(n) { if (g[n]) i[n] = function (v) { return new Promise(function (a, b) { q.push([n, v, a, b]) > 1 || resume(n, v); }); }; }\r\n function resume(n, v) { try { step(g[n](v)); } catch (e) { settle(q[0][3], e); } }\r\n function step(r) { r.value instanceof __await ? Promise.resolve(r.value.v).then(fulfill, reject) : settle(q[0][2], r); }\r\n function fulfill(value) { resume(\"next\", value); }\r\n function reject(value) { resume(\"throw\", value); }\r\n function settle(f, v) { if (f(v), q.shift(), q.length) resume(q[0][0], q[0][1]); }\r\n}\r\n\r\nexport function __asyncDelegator(o) {\r\n var i, p;\r\n return i = {}, verb(\"next\"), verb(\"throw\", function (e) { throw e; }), verb(\"return\"), i[Symbol.iterator] = function () { return this; }, i;\r\n function verb(n, f) { i[n] = o[n] ? function (v) { return (p = !p) ? { value: __await(o[n](v)), done: n === \"return\" } : f ? f(v) : v; } : f; }\r\n}\r\n\r\nexport function __asyncValues(o) {\r\n if (!Symbol.asyncIterator) throw new TypeError(\"Symbol.asyncIterator is not defined.\");\r\n var m = o[Symbol.asyncIterator], i;\r\n return m ? m.call(o) : (o = typeof __values === \"function\" ? __values(o) : o[Symbol.iterator](), i = {}, verb(\"next\"), verb(\"throw\"), verb(\"return\"), i[Symbol.asyncIterator] = function () { return this; }, i);\r\n function verb(n) { i[n] = o[n] && function (v) { return new Promise(function (resolve, reject) { v = o[n](v), settle(resolve, reject, v.done, v.value); }); }; }\r\n function settle(resolve, reject, d, v) { Promise.resolve(v).then(function(v) { resolve({ value: v, done: d }); }, reject); }\r\n}\r\n\r\nexport function __makeTemplateObject(cooked, raw) {\r\n if (Object.defineProperty) { Object.defineProperty(cooked, \"raw\", { value: raw }); } else { cooked.raw = raw; }\r\n return cooked;\r\n};\r\n\r\nexport function __importStar(mod) {\r\n if (mod && mod.__esModule) return mod;\r\n var result = {};\r\n if (mod != null) for (var k in mod) if (Object.hasOwnProperty.call(mod, k)) result[k] = mod[k];\r\n result.default = mod;\r\n return result;\r\n}\r\n\r\nexport function __importDefault(mod) {\r\n return (mod && mod.__esModule) ? mod : { default: mod };\r\n}\r\n\r\nexport function __classPrivateFieldGet(receiver, privateMap) {\r\n if (!privateMap.has(receiver)) {\r\n throw new TypeError(\"attempted to get private field on non-instance\");\r\n }\r\n return privateMap.get(receiver);\r\n}\r\n\r\nexport function __classPrivateFieldSet(receiver, privateMap, value) {\r\n if (!privateMap.has(receiver)) {\r\n throw new TypeError(\"attempted to set private field on non-instance\");\r\n }\r\n privateMap.set(receiver, value);\r\n return value;\r\n}\r\n","import { useLayoutEffect } from 'react-layout-effect';\nimport { each, is, toArray, isAnimatedString, getFluidConfig, Globals, FluidValue, getFluidValue, flush, isEqual, noop, useForceUpdate, usePrev, useOnce, createInterpolator } from '@react-spring/shared';\nexport { FrameLoop, Globals, createInterpolator } from '@react-spring/shared';\nimport _extends from '@babel/runtime/helpers/esm/extends';\nimport { createContext, useContext, createElement, useRef, useState, useMemo as useMemo$1, useImperativeHandle, Fragment } from 'react';\nimport { getAnimated, AnimatedValue, getPayload, setAnimated, AnimatedArray, AnimatedString } from '@react-spring/animated';\nimport { createStringInterpolator, batchedUpdates, to as to$1, frameLoop, skipAnimation } from '@react-spring/shared/globals';\nimport { useMemoOne, useCallbackOne } from 'use-memo-one';\nimport { deprecateInterpolate } from '@react-spring/shared/deprecations';\nimport _objectWithoutPropertiesLoose from '@babel/runtime/helpers/esm/objectWithoutPropertiesLoose';\nimport { createStringInterpolator as createStringInterpolator$1 } from '@react-spring/shared/stringInterpolation';\nexport * from '@react-spring/shared/types';\n\n/** API\n * useChain(references, timeSteps, timeFrame)\n */\n\nfunction useChain(refs, timeSteps, timeFrame = 1000) {\n useLayoutEffect(() => {\n if (timeSteps) {\n let prevDelay = 0;\n each(refs, (ref, i) => {\n if (!ref.current) return;\n const {\n controllers\n } = ref.current;\n\n if (controllers.length) {\n let delay = timeFrame * timeSteps[i]; // Use the previous delay if none exists.\n\n if (isNaN(delay)) delay = prevDelay;else prevDelay = delay;\n each(controllers, ctrl => {\n each(ctrl.queue, props => {\n props.delay = delay + (props.delay || 0);\n });\n ctrl.start();\n });\n }\n });\n } else {\n let p = Promise.resolve();\n each(refs, ref => {\n const {\n controllers,\n start\n } = ref.current || {};\n\n if (controllers && controllers.length) {\n // Take the queue of each controller\n const updates = controllers.map(ctrl => {\n const q = ctrl.queue;\n ctrl.queue = [];\n return q;\n }); // Apply the queue when the previous ref stops animating\n\n p = p.then(() => {\n each(controllers, (ctrl, i) => ctrl.queue.push(...updates[i]));\n return start();\n });\n }\n });\n }\n });\n}\n\n// The `mass` prop defaults to 1\nconst config = {\n default: {\n tension: 170,\n friction: 26\n },\n gentle: {\n tension: 120,\n friction: 14\n },\n wobbly: {\n tension: 180,\n friction: 12\n },\n stiff: {\n tension: 210,\n friction: 20\n },\n slow: {\n tension: 280,\n friction: 60\n },\n molasses: {\n tension: 280,\n friction: 120\n }\n};\n\nconst linear = t => t;\n\nconst defaults = _extends(_extends({}, config.default), {}, {\n mass: 1,\n damping: 1,\n easing: linear,\n clamp: false\n});\n\nclass AnimationConfig {\n /**\n * With higher tension, the spring will resist bouncing and try harder to stop at its end value.\n *\n * When tension is zero, no animation occurs.\n */\n\n /**\n * The damping ratio coefficient, or just the damping ratio when `speed` is defined.\n *\n * When `speed` is defined, this value should be between 0 and 1.\n *\n * Higher friction means the spring will slow down faster.\n */\n\n /**\n * The natural frequency (in seconds), which dictates the number of bounces\n * per second when no damping exists.\n *\n * When defined, `tension` is derived from this, and `friction` is derived\n * from `tension` and `damping`.\n */\n\n /**\n * The damping ratio, which dictates how the spring slows down.\n *\n * Set to `0` to never slow down. Set to `1` to slow down without bouncing.\n * Between `0` and `1` is for you to explore.\n *\n * Only works when `frequency` is defined.\n *\n * Defaults to 1\n */\n\n /**\n * Higher mass means more friction is required to slow down.\n *\n * Defaults to 1, which works fine most of the time.\n */\n\n /**\n * The initial velocity of one or more values.\n */\n\n /**\n * The smallest velocity before the animation is considered \"not moving\".\n *\n * When undefined, `precision` is used instead.\n */\n\n /**\n * The smallest distance from a value before that distance is essentially zero.\n *\n * This helps in deciding when a spring is \"at rest\". The spring must be within\n * this distance from its final value, and its velocity must be lower than this\n * value too (unless `restVelocity` is defined).\n */\n\n /**\n * For `duration` animations only. Note: The `duration` is not affected\n * by this property.\n *\n * Defaults to `0`, which means \"start from the beginning\".\n *\n * Setting to `1+` makes an immediate animation.\n *\n * Setting to `0.5` means \"start from the middle of the easing function\".\n *\n * Any number `>= 0` and `<= 1` makes sense here.\n */\n\n /**\n * Animation length in number of milliseconds.\n */\n\n /**\n * The animation curve. Only used when `duration` is defined.\n *\n * Defaults to quadratic ease-in-out.\n */\n\n /**\n * Avoid overshooting by ending abruptly at the goal value.\n */\n\n /**\n * When above zero, the spring will bounce instead of overshooting when\n * exceeding its goal value. Its velocity is multiplied by `-1 + bounce`\n * whenever its current value equals or exceeds its goal. For example,\n * setting `bounce` to `0.5` chops the velocity in half on each bounce,\n * in addition to any friction.\n */\n\n /**\n * \"Decay animations\" decelerate without an explicit goal value.\n * Useful for scrolling animations.\n *\n * Use `true` for the default exponential decay factor (`0.998`).\n *\n * When a `number` between `0` and `1` is given, a lower number makes the\n * animation slow down faster. And setting to `1` would make an unending\n * animation.\n */\n\n /**\n * While animating, round to the nearest multiple of this number.\n * The `from` and `to` values are never rounded, as well as any value\n * passed to the `set` method of an animated value.\n */\n constructor() {\n this.tension = void 0;\n this.friction = void 0;\n this.frequency = void 0;\n this.damping = void 0;\n this.mass = void 0;\n this.velocity = 0;\n this.restVelocity = void 0;\n this.precision = void 0;\n this.progress = void 0;\n this.duration = void 0;\n this.easing = void 0;\n this.clamp = void 0;\n this.bounce = void 0;\n this.decay = void 0;\n this.round = void 0;\n Object.assign(this, defaults);\n }\n\n}\nfunction mergeConfig(config, newConfig, defaultConfig) {\n if (defaultConfig) {\n defaultConfig = _extends({}, defaultConfig);\n sanitizeConfig(defaultConfig, newConfig);\n newConfig = _extends(_extends({}, defaultConfig), newConfig);\n }\n\n sanitizeConfig(config, newConfig);\n Object.assign(config, newConfig);\n\n for (const key in defaults) {\n if (config[key] == null) {\n config[key] = defaults[key];\n }\n }\n\n let {\n mass,\n frequency,\n damping\n } = config;\n\n if (!is.und(frequency)) {\n if (frequency < 0.01) frequency = 0.01;\n if (damping < 0) damping = 0;\n config.tension = Math.pow(2 * Math.PI / frequency, 2) * mass;\n config.friction = 4 * Math.PI * damping * mass / frequency;\n }\n\n return config;\n} // Prevent a config from accidentally overriding new props.\n// This depends on which \"config\" props take precedence when defined.\n\nfunction sanitizeConfig(config, props) {\n if (!is.und(props.decay)) {\n config.duration = undefined;\n } else {\n const isTensionConfig = !is.und(props.tension) || !is.und(props.friction);\n\n if (isTensionConfig || !is.und(props.frequency) || !is.und(props.damping) || !is.und(props.mass)) {\n config.duration = undefined;\n config.decay = undefined;\n }\n\n if (isTensionConfig) {\n config.frequency = undefined;\n }\n }\n}\n\nconst emptyArray = [];\n/** @internal */\n\n/** An animation being executed by the frameloop */\nclass Animation {\n constructor() {\n this.changed = false;\n this.values = emptyArray;\n this.toValues = null;\n this.fromValues = emptyArray;\n this.to = void 0;\n this.from = void 0;\n this.config = new AnimationConfig();\n this.immediate = false;\n this.onStart = void 0;\n this.onChange = void 0;\n this.onRest = [];\n }\n\n}\n\n// @see https://github.com/alexreardon/use-memo-one/pull/10\nconst useMemo = (create, deps) => useMemoOne(create, deps || [{}]);\nfunction callProp(value, ...args) {\n return is.fun(value) ? value(...args) : value;\n}\n/** Try to coerce the given value into a boolean using the given key */\n\nconst matchProp = (value, key) => value === true || !!(key && value && (is.fun(value) ? value(key) : toArray(value).includes(key)));\nconst getProps = (props, i, arg) => props && (is.fun(props) ? props(i, arg) : is.arr(props) ? props[i] : _extends({}, props));\n/** Returns `true` if the given prop is having its default value set. */\n\nconst hasDefaultProp = (props, key) => !is.und(getDefaultProp(props, key));\n/** Get the default value being set for the given `key` */\n\nconst getDefaultProp = (props, key) => props.default === true ? props[key] : props.default ? props.default[key] : undefined;\n/**\n * Extract the default props from an update.\n *\n * When the `default` prop is falsy, this function still behaves as if\n * `default: true` was used. The `default` prop is always respected when\n * truthy.\n */\n\nconst getDefaultProps = (props, omitKeys = [], defaults = {}) => {\n let keys = DEFAULT_PROPS;\n\n if (props.default && props.default !== true) {\n props = props.default;\n keys = Object.keys(props);\n }\n\n for (const key of keys) {\n const value = props[key];\n\n if (!is.und(value) && !omitKeys.includes(key)) {\n defaults[key] = value;\n }\n }\n\n return defaults;\n};\n/** Merge the default props of an update into a props cache. */\n\nconst mergeDefaultProps = (defaults, props, omitKeys) => getDefaultProps(props, omitKeys, defaults);\n/** These props can have default values */\n\nconst DEFAULT_PROPS = ['pause', 'cancel', 'config', 'immediate', 'onDelayEnd', 'onProps', 'onStart', 'onChange', 'onRest'];\nconst RESERVED_PROPS = {\n config: 1,\n from: 1,\n to: 1,\n ref: 1,\n loop: 1,\n reset: 1,\n pause: 1,\n cancel: 1,\n reverse: 1,\n immediate: 1,\n default: 1,\n delay: 1,\n onDelayEnd: 1,\n onProps: 1,\n onStart: 1,\n onChange: 1,\n onRest: 1,\n // Transition props\n items: 1,\n trail: 1,\n sort: 1,\n expires: 1,\n initial: 1,\n enter: 1,\n update: 1,\n leave: 1,\n children: 1,\n // Internal props\n keys: 1,\n callId: 1,\n parentId: 1\n};\n/**\n * Extract any properties whose keys are *not* reserved for customizing your\n * animations. All hooks use this function, which means `useTransition` props\n * are reserved for `useSpring` calls, etc.\n */\n\nfunction getForwardProps(props) {\n const forward = {};\n let count = 0;\n each(props, (value, prop) => {\n if (!RESERVED_PROPS[prop]) {\n forward[prop] = value;\n count++;\n }\n });\n\n if (count) {\n return forward;\n }\n}\n/**\n * Clone the given `props` and move all non-reserved props\n * into the `to` prop.\n */\n\n\nfunction inferTo(props) {\n const to = getForwardProps(props);\n\n if (to) {\n const out = {\n to\n };\n each(props, (val, key) => key in to || (out[key] = val));\n return out;\n }\n\n return _extends({}, props);\n} // Compute the goal value, converting \"red\" to \"rgba(255, 0, 0, 1)\" in the process\n\nfunction computeGoal(value) {\n const config = getFluidConfig(value);\n return config ? computeGoal(config.get()) : is.arr(value) ? value.map(computeGoal) : isAnimatedString(value) ? createStringInterpolator({\n range: [0, 1],\n output: [value, value]\n })(1) : value;\n}\n\n/**\n * This function sets a timeout if both the `delay` prop exists and\n * the `cancel` prop is not `true`.\n *\n * The `actions.start` function must handle the `cancel` prop itself,\n * but the `pause` prop is taken care of.\n */\nfunction scheduleProps(callId, {\n key,\n props,\n state,\n actions\n}) {\n return new Promise((resolve, reject) => {\n let delay;\n let timeout;\n let pause = false;\n let cancel = matchProp(props.cancel, key);\n\n if (cancel) {\n onStart();\n } else {\n delay = callProp(props.delay || 0, key);\n pause = matchProp(props.pause, key);\n\n if (pause) {\n state.resumeQueue.add(onResume);\n actions.pause();\n } else {\n actions.resume();\n onResume();\n }\n }\n\n function onPause() {\n state.resumeQueue.add(onResume);\n timeout.cancel(); // Cache the remaining delay.\n\n delay = timeout.time - Globals.now();\n }\n\n function onResume() {\n if (delay > 0) {\n state.pauseQueue.add(onPause);\n timeout = Globals.frameLoop.setTimeout(onStart, delay);\n } else {\n onStart();\n }\n }\n\n function onStart() {\n state.pauseQueue.delete(onPause); // Maybe cancelled during its delay.\n\n if (callId <= (state.cancelId || 0)) {\n cancel = true;\n }\n\n try {\n actions.start(_extends(_extends({}, props), {}, {\n callId,\n delay,\n cancel,\n pause\n }), resolve);\n } catch (err) {\n reject(err);\n }\n }\n });\n}\n\n/** @internal */\n\n/** The object given to the `onRest` prop and `start` promise. */\n\n/** The promised result of an animation. */\n\n/** @internal */\nconst getCombinedResult = (target, results) => results.length == 1 ? results[0] : results.some(result => result.cancelled) ? getCancelledResult(target) : results.every(result => result.noop) ? getNoopResult(target) : getFinishedResult(target, results.every(result => result.finished));\n/** No-op results are for updates that never start an animation. */\n\nconst getNoopResult = (target, value = target.get()) => ({\n value,\n noop: true,\n finished: true,\n target\n});\nconst getFinishedResult = (target, finished, value = target.get()) => ({\n value,\n finished,\n target\n});\nconst getCancelledResult = (target, value = target.get()) => ({\n value,\n cancelled: true,\n target\n});\n\n/**\n * Start an async chain or an async script.\n *\n * Always call `runAsync` in the action callback of a `scheduleProps` call.\n *\n * The `T` parameter can be a set of animated values (as an object type)\n * or a primitive type for a single animated value.\n */\nasync function runAsync(to, props, state, target) {\n if (props.pause) {\n await new Promise(resume => {\n state.resumeQueue.add(resume);\n });\n }\n\n const {\n callId,\n parentId,\n onRest\n } = props;\n const {\n asyncTo: prevTo,\n promise: prevPromise\n } = state;\n\n if (!parentId && to === prevTo && !props.reset) {\n return prevPromise;\n }\n\n return state.promise = (async () => {\n state.asyncId = callId;\n state.asyncTo = to; // The default props of any `animate` calls.\n\n const defaultProps = getDefaultProps(props, [// The `onRest` prop is only called when the `runAsync` promise is resolved.\n 'onRest']);\n let preventBail;\n let bail; // This promise is rejected when the animation is interrupted.\n\n const bailPromise = new Promise((resolve, reject) => (preventBail = resolve, bail = reject)); // Stop animating when an error is caught.\n\n const withBailHandler = fn => (...args) => {\n const onError = err => {\n if (err instanceof BailSignal) {\n bail(err); // Stop animating.\n }\n\n throw err;\n };\n\n try {\n return fn(...args).catch(onError);\n } catch (err) {\n onError(err);\n }\n };\n\n const bailIfEnded = bailSignal => {\n const bailResult = // The `cancel` prop or `stop` method was used.\n callId <= (state.cancelId || 0) && getCancelledResult(target) || // The async `to` prop was replaced.\n callId !== state.asyncId && getFinishedResult(target, false);\n\n if (bailResult) {\n bailSignal.result = bailResult;\n throw bailSignal;\n }\n }; // Note: This function cannot use the `async` keyword, because we want the\n // `throw` statements to interrupt the caller.\n\n\n const animate = withBailHandler((arg1, arg2) => {\n const bailSignal = new BailSignal();\n bailIfEnded(bailSignal);\n const props = is.obj(arg1) ? _extends({}, arg1) : _extends(_extends({}, arg2), {}, {\n to: arg1\n });\n props.parentId = callId;\n each(defaultProps, (value, key) => {\n if (is.und(props[key])) {\n props[key] = value;\n }\n });\n return target.start(props).then(async result => {\n bailIfEnded(bailSignal);\n\n if (target.is('PAUSED')) {\n await new Promise(resume => {\n state.resumeQueue.add(resume);\n });\n }\n\n return result;\n });\n });\n let result;\n\n try {\n let animating; // Async sequence\n\n if (is.arr(to)) {\n animating = (async queue => {\n for (const props of queue) {\n await animate(props);\n }\n })(to);\n } // Async script\n else if (is.fun(to)) {\n animating = Promise.resolve(to(animate, target.stop.bind(target)));\n }\n\n await Promise.all([animating.then(preventBail), bailPromise]);\n result = getFinishedResult(target, true); // Bail handling\n } catch (err) {\n if (err instanceof BailSignal) {\n result = err.result;\n } else {\n throw err;\n } // Reset the async state.\n\n } finally {\n if (callId == state.asyncId) {\n state.asyncId = parentId;\n state.asyncTo = parentId ? prevTo : undefined;\n state.promise = parentId ? prevPromise : undefined;\n }\n }\n\n if (is.fun(onRest)) {\n batchedUpdates(() => {\n onRest(result);\n });\n }\n\n return result;\n })();\n}\nfunction cancelAsync(state, callId) {\n state.cancelId = callId;\n state.asyncId = state.asyncTo = state.promise = undefined;\n}\n/** This error is thrown to signal an interrupted async animation. */\n\nclass BailSignal extends Error {\n constructor() {\n super('An async animation has been interrupted. You see this error because you ' + 'forgot to use `await` or `.catch(...)` on its returned promise.');\n this.result = void 0;\n }\n\n}\n\nconst isFrameValue = value => value instanceof FrameValue;\nlet nextId = 1;\n/**\n * A kind of `FluidValue` that manages an `AnimatedValue` node.\n *\n * Its underlying value can be accessed and even observed.\n */\n\nclass FrameValue extends FluidValue {\n constructor(...args) {\n super(...args);\n this.id = nextId++;\n this.key = void 0;\n this._priority = 0;\n this._children = new Set();\n }\n\n get priority() {\n return this._priority;\n }\n\n set priority(priority) {\n if (this._priority != priority) {\n this._priority = priority;\n\n this._onPriorityChange(priority);\n }\n }\n /** Get the current value */\n\n\n get() {\n const node = getAnimated(this);\n return node && node.getValue();\n }\n /** Create a spring that maps our value to another value */\n\n\n to(...args) {\n return to$1(this, args);\n }\n /** @deprecated Use the `to` method instead. */\n\n\n interpolate(...args) {\n deprecateInterpolate();\n return to$1(this, args);\n }\n /** @internal */\n\n\n /** @internal */\n addChild(child) {\n if (!this._children.size) this._attach();\n\n this._children.add(child);\n }\n /** @internal */\n\n\n removeChild(child) {\n this._children.delete(child);\n\n if (!this._children.size) this._detach();\n }\n /** @internal */\n\n\n onParentChange({\n type\n }) {\n if (this.idle) {\n // Start animating when a parent does.\n if (type == 'start') {\n this._reset();\n\n this._start();\n }\n } // Reset our animation state when a parent does, but only when\n // our animation is active.\n else if (type == 'reset') {\n this._reset();\n }\n }\n /** Called when the first child is added. */\n\n\n _attach() {}\n /** Called when the last child is removed. */\n\n\n _detach() {}\n /**\n * Reset our animation state (eg: start values, velocity, etc)\n * and tell our children to do the same.\n *\n * This is called when our goal value is changed during (or before)\n * an animation.\n */\n\n\n _reset() {\n this._emit({\n type: 'reset',\n parent: this\n });\n }\n /**\n * Start animating if possible.\n *\n * Note: Be sure to call `_reset` first, or the animation will break.\n * This method would like to call `_reset` for you, but that would\n * interfere with paused animations.\n */\n\n\n _start() {\n this._emit({\n type: 'start',\n parent: this\n });\n }\n /** Tell our children about our new value */\n\n\n _onChange(value, idle = false) {\n this._emit({\n type: 'change',\n parent: this,\n value,\n idle\n });\n }\n /** Tell our children about our new priority */\n\n\n _onPriorityChange(priority) {\n if (!this.idle) {\n // Make the frameloop aware of our new priority.\n frameLoop.start(this);\n }\n\n this._emit({\n type: 'priority',\n parent: this,\n priority\n });\n }\n\n _emit(event) {\n // Clone \"_children\" so it can be safely mutated inside the loop.\n each(Array.from(this._children), child => {\n child.onParentChange(event);\n });\n }\n\n}\n\n// TODO: use \"const enum\" when Babel supports it\n\n/** The spring has not animated yet */\nconst CREATED = 'CREATED';\n/** The spring has animated before */\n\nconst IDLE = 'IDLE';\n/** The spring is animating */\n\nconst ACTIVE = 'ACTIVE';\n/** The spring is frozen in time */\n\nconst PAUSED = 'PAUSED';\n/** The spring cannot be animated */\n\nconst DISPOSED = 'DISPOSED';\n\n/**\n * Only numbers, strings, and arrays of numbers/strings are supported.\n * Non-animatable strings are also supported.\n */\nclass SpringValue extends FrameValue {\n /** The property name used when `to` or `from` is an object. Useful when debugging too. */\n\n /** The animation state */\n\n /** The queue of pending props */\n\n /** The lifecycle phase of this spring */\n\n /** The state for `runAsync` calls */\n\n /** Some props have customizable default values */\n\n /** The counter for tracking `scheduleProps` calls */\n\n /** The last `scheduleProps` call that changed the `to` prop */\n constructor(arg1, arg2) {\n super();\n this.key = void 0;\n this.animation = new Animation();\n this.queue = void 0;\n this._phase = CREATED;\n this._state = {\n pauseQueue: new Set(),\n resumeQueue: new Set()\n };\n this._defaultProps = {};\n this._lastCallId = 0;\n this._lastToId = 0;\n\n if (!is.und(arg1) || !is.und(arg2)) {\n const props = is.obj(arg1) ? _extends({}, arg1) : _extends(_extends({}, arg2), {}, {\n from: arg1\n });\n props.default = true;\n this.start(props);\n }\n }\n\n get idle() {\n return !this.is(ACTIVE) && !this._state.asyncTo;\n }\n\n get goal() {\n return getFluidValue(this.animation.to);\n }\n\n get velocity() {\n const node = getAnimated(this);\n return node instanceof AnimatedValue ? node.lastVelocity || 0 : node.getPayload().map(node => node.lastVelocity || 0);\n }\n /** Advance the current animation by a number of milliseconds */\n\n\n advance(dt) {\n let idle = true;\n let changed = false;\n const anim = this.animation;\n let {\n config,\n toValues\n } = anim;\n const payload = getPayload(anim.to);\n\n if (!payload) {\n const toConfig = getFluidConfig(anim.to);\n\n if (toConfig) {\n toValues = toArray(toConfig.get());\n }\n }\n\n anim.values.forEach((node, i) => {\n if (node.done) return; // The \"anim.toValues\" array must exist when no parent exists.\n\n let to = payload ? payload[i].lastPosition : toValues[i];\n let finished = anim.immediate;\n let position = to;\n\n if (!finished) {\n position = node.lastPosition; // Loose springs never move.\n\n if (config.tension <= 0) {\n node.done = true;\n return;\n }\n\n const elapsed = node.elapsedTime += dt;\n const from = anim.fromValues[i];\n const v0 = node.v0 != null ? node.v0 : node.v0 = is.arr(config.velocity) ? config.velocity[i] : config.velocity;\n let velocity; // Duration easing\n\n if (!is.und(config.duration)) {\n let p = config.progress || 0;\n if (config.duration <= 0) p = 1;else p += (1 - p) * Math.min(1, elapsed / config.duration);\n position = from + config.easing(p) * (to - from);\n velocity = (position - node.lastPosition) / dt;\n finished = p == 1;\n } // Decay easing\n else if (config.decay) {\n const decay = config.decay === true ? 0.998 : config.decay;\n const e = Math.exp(-(1 - decay) * elapsed);\n position = from + v0 / (1 - decay) * (1 - e);\n finished = Math.abs(node.lastPosition - position) < 0.1; // derivative of position\n\n velocity = v0 * e;\n } // Spring easing\n else {\n velocity = node.lastVelocity == null ? v0 : node.lastVelocity;\n /** The smallest distance from a value before being treated like said value. */\n\n const precision = config.precision || (from == to ? 0.005 : Math.min(1, Math.abs(to - from) * 0.001));\n /** The velocity at which movement is essentially none */\n\n const restVelocity = config.restVelocity || precision / 10; // Bouncing is opt-in (not to be confused with overshooting)\n\n const bounceFactor = config.clamp ? 0 : config.bounce;\n const canBounce = !is.und(bounceFactor);\n /** When `true`, the value is increasing over time */\n\n const isGrowing = from == to ? node.v0 > 0 : from < to;\n /** When `true`, the velocity is considered moving */\n\n let isMoving;\n /** When `true`, the velocity is being deflected or clamped */\n\n let isBouncing = false;\n const step = 1; // 1ms\n\n const numSteps = Math.ceil(dt / step);\n\n for (let n = 0; n < numSteps; ++n) {\n isMoving = Math.abs(velocity) > restVelocity;\n\n if (!isMoving) {\n finished = Math.abs(to - position) <= precision;\n\n if (finished) {\n break;\n }\n }\n\n if (canBounce) {\n isBouncing = position == to || position > to == isGrowing; // Invert the velocity with a magnitude, or clamp it.\n\n if (isBouncing) {\n velocity = -velocity * bounceFactor;\n position = to;\n }\n }\n\n const springForce = -config.tension * 0.000001 * (position - to);\n const dampingForce = -config.friction * 0.001 * velocity;\n const acceleration = (springForce + dampingForce) / config.mass; // pt/ms^2\n\n velocity = velocity + acceleration * step; // pt/ms\n\n position = position + velocity * step;\n }\n }\n\n node.lastVelocity = velocity;\n\n if (Number.isNaN(position)) {\n console.warn(\"Got NaN while animating:\", this);\n finished = true;\n }\n } // Parent springs must finish before their children can.\n\n\n if (payload && !payload[i].done) {\n finished = false;\n }\n\n if (finished) {\n node.done = true;\n } else {\n idle = false;\n }\n\n if (node.setValue(position, config.round)) {\n changed = true;\n }\n });\n\n if (idle) {\n this.finish();\n } else if (changed) {\n this._onChange(this.get());\n }\n\n return idle;\n }\n /** Check the current phase */\n\n\n is(phase) {\n return this._phase == phase;\n }\n /** Set the current value, while stopping the current animation */\n\n\n set(value) {\n batchedUpdates(() => {\n this._focus(value);\n\n if (this._set(value)) {\n // Ensure change observers are notified. When active,\n // the \"_stop\" method handles this.\n if (!this.is(ACTIVE)) {\n return this._onChange(this.get(), true);\n }\n }\n\n this._stop();\n });\n return this;\n }\n /**\n * Freeze the active animation in time.\n * This does nothing when not animating.\n */\n\n\n pause() {\n checkDisposed(this, 'pause');\n\n if (!this.is(PAUSED)) {\n this._phase = PAUSED;\n flush(this._state.pauseQueue, onPause => onPause());\n }\n }\n /** Resume the animation if paused. */\n\n\n resume() {\n checkDisposed(this, 'resume');\n\n if (this.is(PAUSED)) {\n this._start();\n\n flush(this._state.resumeQueue, onResume => onResume());\n }\n }\n /**\n * Skip to the end of the current animation.\n *\n * All `onRest` callbacks are passed `{finished: true}`\n */\n\n\n finish(to) {\n this.resume();\n\n if (this.is(ACTIVE)) {\n const anim = this.animation; // Decay animations have an implicit goal.\n\n if (!anim.config.decay && is.und(to)) {\n to = anim.to;\n } // Set the value if we can.\n\n\n if (!is.und(to)) {\n this._set(to);\n }\n\n batchedUpdates(() => {\n // Ensure the \"onStart\" and \"onRest\" props are called.\n if (!anim.changed) {\n anim.changed = true;\n\n if (anim.onStart) {\n anim.onStart(this);\n }\n } // Exit the frameloop.\n\n\n this._stop();\n });\n }\n\n return this;\n }\n /** Push props into the pending queue. */\n\n\n update(props) {\n checkDisposed(this, 'update');\n const queue = this.queue || (this.queue = []);\n queue.push(props);\n return this;\n }\n /**\n * Update this value's animation using the queue of pending props,\n * and unpause the current animation (if one is frozen).\n *\n * When arguments are passed, a new animation is created, and the\n * queued animations are left alone.\n */\n\n\n async start(to, arg2) {\n checkDisposed(this, 'start');\n let queue;\n\n if (!is.und(to)) {\n queue = [is.obj(to) ? to : _extends(_extends({}, arg2), {}, {\n to\n })];\n } else {\n queue = this.queue || [];\n this.queue = [];\n }\n\n const results = await Promise.all(queue.map(props => this._update(props)));\n return getCombinedResult(this, results);\n }\n /**\n * Stop the current animation, and cancel any delayed updates.\n *\n * Pass `true` to call `onRest` with `cancelled: true`.\n */\n\n\n stop(cancel) {\n if (!this.is(DISPOSED)) {\n cancelAsync(this._state, this._lastCallId); // Ensure the `to` value equals the current value.\n\n this._focus(this.get()); // Exit the frameloop and notify `onRest` listeners.\n\n\n batchedUpdates(() => this._stop(cancel));\n }\n\n return this;\n }\n /** Restart the animation. */\n\n\n reset() {\n this._update({\n reset: true\n });\n }\n /** Prevent future animations, and stop the current animation */\n\n\n dispose() {\n if (!this.is(DISPOSED)) {\n if (this.animation) {\n // Prevent \"onRest\" calls when disposed.\n this.animation.onRest = [];\n }\n\n this.stop();\n this._phase = DISPOSED;\n }\n }\n /** @internal */\n\n\n onParentChange(event) {\n super.onParentChange(event);\n\n if (event.type == 'change') {\n if (!this.is(ACTIVE)) {\n this._reset();\n\n if (!this.is(PAUSED)) {\n this._start();\n }\n }\n } else if (event.type == 'priority') {\n this.priority = event.priority + 1;\n }\n }\n /**\n * Parse the `to` and `from` range from the given `props` object.\n *\n * This also ensures the initial value is available to animated components\n * during the render phase.\n */\n\n\n _prepareNode({\n to,\n from,\n reverse\n }) {\n const key = this.key || '';\n to = !is.obj(to) || getFluidConfig(to) ? to : to[key];\n from = !is.obj(from) || getFluidConfig(from) ? from : from[key]; // Create the range now to avoid \"reverse\" logic.\n\n const range = {\n to,\n from\n }; // Before ever animating, this method ensures an `Animated` node\n // exists and keeps its value in sync with the \"from\" prop.\n\n if (this.is(CREATED)) {\n if (reverse) [to, from] = [from, to];\n from = getFluidValue(from);\n\n const node = this._updateNode(is.und(from) ? getFluidValue(to) : from);\n\n if (node && !is.und(from)) {\n node.setValue(from);\n }\n }\n\n return range;\n }\n /**\n * Create an `Animated` node if none exists or the given value has an\n * incompatible type. Do nothing if `value` is undefined.\n *\n * The newest `Animated` node is returned.\n */\n\n\n _updateNode(value) {\n let node = getAnimated(this);\n\n if (!is.und(value)) {\n const nodeType = this._getNodeType(value);\n\n if (!node || node.constructor !== nodeType) {\n setAnimated(this, node = nodeType.create(value));\n }\n }\n\n return node;\n }\n /** Return the `Animated` node constructor for a given value */\n\n\n _getNodeType(value) {\n const parentNode = getAnimated(value);\n return parentNode ? parentNode.constructor : is.arr(value) ? AnimatedArray : isAnimatedString(value) ? AnimatedString : AnimatedValue;\n }\n /** Schedule an animation to run after an optional delay */\n\n\n _update(props, isLoop) {\n const defaultProps = this._defaultProps;\n\n const mergeDefaultProp = key => {\n const value = getDefaultProp(props, key);\n\n if (!is.und(value)) {\n defaultProps[key] = value;\n } // For `cancel` and `pause`, a truthy default always wins.\n\n\n if (defaultProps[key]) {\n props[key] = defaultProps[key];\n }\n }; // These props are coerced into booleans by the `scheduleProps` function,\n // so they need their default values processed before then.\n\n\n mergeDefaultProp('cancel');\n mergeDefaultProp('pause'); // Ensure the initial value can be accessed by animated components.\n\n const range = this._prepareNode(props);\n\n return scheduleProps(++this._lastCallId, {\n key: this.key,\n props,\n state: this._state,\n actions: {\n pause: this.pause.bind(this),\n resume: this.resume.bind(this),\n start: this._merge.bind(this, range)\n }\n }).then(result => {\n if (props.loop && result.finished && !(isLoop && result.noop)) {\n const nextProps = createLoopUpdate(props);\n\n if (nextProps) {\n return this._update(nextProps, true);\n }\n }\n\n return result;\n });\n }\n /** Merge props into the current animation */\n\n\n _merge(range, props, resolve) {\n // The \"cancel\" prop cancels all pending delays and it forces the\n // active animation to stop where it is.\n if (props.cancel) {\n this.stop(true);\n return resolve(getCancelledResult(this));\n }\n\n const {\n key,\n animation: anim\n } = this;\n const defaultProps = this._defaultProps;\n /** The \"to\" prop is defined. */\n\n const hasToProp = !is.und(range.to);\n /** The \"from\" prop is defined. */\n\n const hasFromProp = !is.und(range.from); // Avoid merging other props if implicitly prevented, except\n // when both the \"to\" and \"from\" props are undefined.\n\n if (hasToProp || hasFromProp) {\n if (props.callId > this._lastToId) {\n this._lastToId = props.callId;\n } else {\n return resolve(getCancelledResult(this));\n }\n }\n /** Get the value of a prop, or its default value */\n\n\n const get = prop => !is.und(props[prop]) ? props[prop] : defaultProps[prop]; // Call \"onDelayEnd\" before merging props, but after cancellation checks.\n\n\n const onDelayEnd = coerceEventProp(get('onDelayEnd'), key);\n\n if (onDelayEnd) {\n onDelayEnd(props, this);\n }\n\n if (props.default) {\n mergeDefaultProps(defaultProps, props, ['pause', 'cancel']);\n }\n\n const {\n to: prevTo,\n from: prevFrom\n } = anim;\n let {\n to = prevTo,\n from = prevFrom\n } = range; // Focus the \"from\" value if changing without a \"to\" value.\n\n if (hasFromProp && !hasToProp) {\n to = from;\n } // Flip the current range if \"reverse\" is true.\n\n\n if (props.reverse) [to, from] = [from, to];\n /** The \"from\" value is changing. */\n\n const hasFromChanged = !isEqual(from, prevFrom);\n\n if (hasFromChanged) {\n anim.from = from;\n }\n /** The \"to\" value is changing. */\n\n\n const hasToChanged = !isEqual(to, prevTo);\n\n if (hasToChanged) {\n this._focus(to);\n } // Both \"from\" and \"to\" can use a fluid config (thanks to http://npmjs.org/fluids).\n\n\n const toConfig = getFluidConfig(to);\n const fromConfig = getFluidConfig(from);\n\n if (fromConfig) {\n from = fromConfig.get();\n }\n /** The \"to\" prop is async. */\n\n\n const hasAsyncTo = is.arr(props.to) || is.fun(props.to);\n const {\n config\n } = anim;\n const {\n decay,\n velocity\n } = config; // The \"runAsync\" function treats the \"config\" prop as a default,\n // so we must avoid merging it when the \"to\" prop is async.\n\n if (props.config && !hasAsyncTo) {\n mergeConfig(config, callProp(props.config, key), // Avoid calling the same \"config\" prop twice.\n props.config !== defaultProps.config ? callProp(defaultProps.config, key) : void 0);\n } // This instance might not have its Animated node yet. For example,\n // the constructor can be given props without a \"to\" or \"from\" value.\n\n\n let node = getAnimated(this);\n\n if (!node || is.und(to)) {\n return resolve(getFinishedResult(this, true));\n }\n /** When true, start at the \"from\" value. */\n\n\n const reset = // When `reset` is undefined, the `from` prop implies `reset: true`,\n // except for declarative updates. When `reset` is defined, there\n // must exist a value to animate from.\n is.und(props.reset) ? hasFromProp && !props.default : !is.und(from) && matchProp(props.reset, key); // The current value, where the animation starts from.\n\n const value = reset ? from : this.get(); // The animation ends at this value, unless \"to\" is fluid.\n\n const goal = computeGoal(to); // Only specific types can be animated to/from.\n\n const isAnimatable = is.num(goal) || is.arr(goal) || isAnimatedString(goal); // When true, the value changes instantly on the next frame.\n\n const immediate = !hasAsyncTo && (!isAnimatable || matchProp(defaultProps.immediate || props.immediate, key));\n\n if (hasToChanged) {\n if (immediate) {\n node = this._updateNode(goal);\n } else {\n const nodeType = this._getNodeType(to);\n\n if (nodeType !== node.constructor) {\n throw Error(\"Cannot animate between \" + node.constructor.name + \" and \" + nodeType.name + \", as the \\\"to\\\" prop suggests\");\n }\n }\n } // The type of Animated node for the goal value.\n\n\n const goalType = node.constructor; // When the goal value is fluid, we don't know if its value\n // will change before the next animation frame, so it always\n // starts the animation to be safe.\n\n let started = !!toConfig;\n let finished = false;\n\n if (!started) {\n // When true, the current value has probably changed.\n const hasValueChanged = reset || this.is(CREATED) && hasFromChanged; // When the \"to\" value or current value are changed,\n // start animating if not already finished.\n\n if (hasToChanged || hasValueChanged) {\n finished = isEqual(computeGoal(value), goal);\n started = !finished;\n } // Changing \"decay\" or \"velocity\" starts the animation.\n\n\n if (!isEqual(config.decay, decay) || !isEqual(config.velocity, velocity)) {\n started = true;\n }\n } // When an active animation changes its goal to its current value:\n\n\n if (finished && this.is(ACTIVE)) {\n // Avoid an abrupt stop unless the animation is being reset.\n if (anim.changed && !reset) {\n started = true;\n } // Stop the animation before its first frame.\n else if (!started) {\n this._stop();\n }\n }\n\n if (!hasAsyncTo) {\n // Make sure our \"toValues\" are updated even if our previous\n // \"to\" prop is a fluid value whose current value is also ours.\n if (started || getFluidConfig(prevTo)) {\n anim.values = node.getPayload();\n anim.toValues = toConfig ? null : goalType == AnimatedString ? [1] : toArray(goal);\n }\n\n anim.immediate = immediate;\n anim.onStart = coerceEventProp(get('onStart'), key);\n anim.onChange = coerceEventProp(get('onChange'), key); // The \"reset\" prop tries to reuse the old \"onRest\" prop,\n // unless you defined a new \"onRest\" prop.\n\n const onRestQueue = anim.onRest;\n const onRest = reset && !props.onRest ? onRestQueue[0] || noop : checkFinishedOnRest(coerceEventProp(get('onRest'), key), this); // In most cases, the animation after this one won't reuse our\n // \"onRest\" prop. Instead, the _default_ \"onRest\" prop is used\n // when the next animation has an undefined \"onRest\" prop.\n\n if (started) {\n anim.onRest = [onRest, checkFinishedOnRest(resolve, this)]; // Flush the \"onRest\" queue for the previous animation.\n\n let onRestIndex = reset ? 0 : 1;\n\n if (onRestIndex < onRestQueue.length) {\n batchedUpdates(() => {\n for (; onRestIndex < onRestQueue.length; onRestIndex++) {\n onRestQueue[onRestIndex]();\n }\n });\n }\n } // The \"onRest\" prop is always first, and it can be updated even\n // if a new animation is not started by this update.\n else if (reset || props.onRest) {\n anim.onRest[0] = onRest;\n }\n } // By this point, every prop has been merged.\n\n\n const onProps = coerceEventProp(get('onProps'), key);\n\n if (onProps) {\n onProps(props, this);\n } // Update our node even if the animation is idle.\n\n\n if (reset) {\n node.setValue(value);\n }\n\n if (hasAsyncTo) {\n resolve(runAsync(props.to, props, this._state, this));\n } // Start an animation\n else if (started) {\n // Must be idle for \"onStart\" to be called again.\n if (reset) this._phase = IDLE;\n\n this._reset();\n\n this._start();\n } // Postpone promise resolution until the animation is finished,\n // so that no-op updates still resolve at the expected time.\n else if (this.is(ACTIVE) && !hasToChanged) {\n anim.onRest.push(checkFinishedOnRest(resolve, this));\n } // Resolve our promise immediately.\n else {\n resolve(getNoopResult(this, value));\n }\n }\n /** Update the `animation.to` value, which might be a `FluidValue` */\n\n\n _focus(value) {\n const anim = this.animation;\n\n if (value !== anim.to) {\n let config = getFluidConfig(anim.to);\n\n if (config) {\n config.removeChild(this);\n }\n\n anim.to = value;\n let priority = 0;\n\n if (config = getFluidConfig(value)) {\n config.addChild(this);\n\n if (isFrameValue(value)) {\n priority = (value.priority || 0) + 1;\n }\n }\n\n this.priority = priority;\n }\n }\n /** Set the current value and our `node` if necessary. The `_onChange` method is *not* called. */\n\n\n _set(value) {\n const config = getFluidConfig(value);\n\n if (config) {\n value = config.get();\n }\n\n const node = getAnimated(this);\n const oldValue = node && node.getValue();\n\n if (node) {\n node.setValue(value);\n } else {\n this._updateNode(value);\n }\n\n return !isEqual(value, oldValue);\n }\n\n _onChange(value, idle = false) {\n const anim = this.animation; // The \"onStart\" prop is called on the first change after entering the\n // frameloop, but never for immediate animations.\n\n if (!anim.changed && !idle) {\n anim.changed = true;\n\n if (anim.onStart) {\n anim.onStart(this);\n }\n }\n\n if (anim.onChange) {\n anim.onChange(value, this);\n }\n\n super._onChange(value, idle);\n }\n\n _reset() {\n const anim = this.animation; // Reset the state of each Animated node.\n\n getAnimated(this).reset(anim.to); // Ensure the `onStart` prop will be called.\n\n if (!this.is(ACTIVE)) {\n anim.changed = false;\n } // Use the current values as the from values.\n\n\n if (!anim.immediate) {\n anim.fromValues = anim.values.map(node => node.lastPosition);\n }\n\n super._reset();\n }\n\n _start() {\n if (!this.is(ACTIVE)) {\n this._phase = ACTIVE;\n\n super._start(); // The \"skipAnimation\" global avoids the frameloop.\n\n\n if (skipAnimation) {\n this.finish();\n } else {\n frameLoop.start(this);\n }\n }\n }\n /**\n * Exit the frameloop and notify `onRest` listeners.\n *\n * Always wrap `_stop` calls with `batchedUpdates`.\n */\n\n\n _stop(cancel) {\n this.resume();\n\n if (this.is(ACTIVE)) {\n this._phase = IDLE; // Always let change observers know when a spring becomes idle.\n\n this._onChange(this.get(), true);\n\n const anim = this.animation;\n each(anim.values, node => {\n node.done = true;\n });\n const onRestQueue = anim.onRest;\n\n if (onRestQueue.length) {\n // Preserve the \"onRest\" prop when the goal is dynamic.\n anim.onRest = [anim.toValues ? noop : onRestQueue[0]]; // Never call the \"onRest\" prop for no-op animations.\n\n if (!anim.changed) {\n onRestQueue[0] = noop;\n }\n\n each(onRestQueue, onRest => onRest(cancel));\n }\n }\n }\n\n}\n\nfunction checkDisposed(spring, name) {\n if (spring.is(DISPOSED)) {\n throw Error(\"Cannot call \\\"\" + name + \"\\\" of disposed \\\"\" + spring.constructor.name + \"\\\" object\");\n }\n}\n/** Coerce an event prop to an event handler */\n\n\nfunction coerceEventProp(prop, key) {\n return is.fun(prop) ? prop : key && prop ? prop[key] : undefined;\n}\n/**\n * The \"finished\" value is determined by each \"onRest\" handler,\n * based on whether the current value equals the goal value that\n * was calculated at the time the \"onRest\" handler was set.\n */\n\n\nconst checkFinishedOnRest = (onRest, spring) => {\n const {\n to\n } = spring.animation;\n return onRest ? cancel => {\n if (cancel) {\n onRest(getCancelledResult(spring));\n } else {\n const goal = computeGoal(to);\n const value = computeGoal(spring.get());\n const finished = isEqual(value, goal);\n onRest(getFinishedResult(spring, finished));\n }\n } : noop;\n};\n\nfunction createLoopUpdate(props, loop = props.loop, to = props.to) {\n let loopRet = callProp(loop);\n\n if (loopRet) {\n const overrides = loopRet !== true && inferTo(loopRet);\n const reverse = (overrides || props).reverse;\n const reset = !overrides || overrides.reset;\n return createUpdate(_extends(_extends({}, props), {}, {\n loop,\n // Avoid updating default props when looping.\n default: false,\n // For the \"reverse\" prop to loop as expected, the \"to\" prop\n // must be undefined. The \"reverse\" prop is ignored when the\n // \"to\" prop is an array or function.\n to: !reverse || is.arr(to) || is.fun(to) ? to : undefined,\n // Avoid defining the \"from\" prop if a reset is unwanted.\n from: reset ? props.from : undefined,\n reset\n }, overrides));\n }\n}\n/**\n * Return a new object based on the given `props`.\n *\n * - All unreserved props are moved into the `to` prop object.\n * - The `to` and `from` props are deleted when falsy.\n * - The `keys` prop is set to an array of affected keys,\n * or `null` if all keys are affected.\n */\n\nfunction createUpdate(props) {\n const {\n to,\n from\n } = props = inferTo(props); // Collect the keys affected by this update.\n\n const keys = new Set();\n\n if (from) {\n findDefined(from, keys);\n } else {\n // Falsy values are deleted to avoid merging issues.\n delete props.from;\n }\n\n if (is.obj(to)) {\n findDefined(to, keys);\n } else if (!to) {\n // Falsy values are deleted to avoid merging issues.\n delete props.to;\n } // The \"keys\" prop helps in applying updates to affected keys only.\n\n\n props.keys = keys.size ? Array.from(keys) : null;\n return props;\n}\n/**\n * A modified version of `createUpdate` meant for declarative APIs.\n */\n\nfunction declareUpdate(props) {\n const update = createUpdate(props);\n\n if (is.und(update.default)) {\n update.default = getDefaultProps(update, [// Avoid forcing `immediate: true` onto imperative updates.\n update.immediate === true && 'immediate']);\n }\n\n return update;\n}\n/** Find keys with defined values */\n\nfunction findDefined(values, keys) {\n each(values, (value, key) => value != null && keys.add(key));\n}\n\n/** Events batched by the `Controller` class */\nconst BATCHED_EVENTS = ['onStart', 'onChange', 'onRest'];\nlet nextId$1 = 1;\n/** Queue of pending updates for a `Controller` instance. */\n\nclass Controller {\n /** The animated values */\n\n /** The queue of props passed to the `update` method. */\n\n /** Custom handler for flushing update queues */\n\n /** These props are used by all future spring values */\n\n /** The combined phase of our spring values */\n\n /** The counter for tracking `scheduleProps` calls */\n\n /** The values currently being animated */\n\n /** State used by the `runAsync` function */\n\n /** The event queues that are flushed once per frame maximum */\n constructor(props, flush) {\n this.id = nextId$1++;\n this.springs = {};\n this.queue = [];\n this._flush = void 0;\n this._initialProps = void 0;\n this._phase = CREATED;\n this._lastAsyncId = 0;\n this._active = new Set();\n this._state = {\n pauseQueue: new Set(),\n resumeQueue: new Set()\n };\n this._events = {\n onStart: new Set(),\n onChange: new Set(),\n onRest: new Map()\n };\n this._onFrame = this._onFrame.bind(this);\n\n if (flush) {\n this._flush = flush;\n }\n\n if (props) {\n this.start(props);\n }\n }\n /**\n * Equals `true` when no spring values are in the frameloop, and\n * no async animation is currently active.\n */\n\n\n get idle() {\n return !this._state.asyncTo && Object.values(this.springs).every(spring => spring.idle);\n }\n /** Check the current phase */\n\n\n is(phase) {\n return this._phase == phase;\n }\n /** Get the current values of our springs */\n\n\n get() {\n const values = {};\n this.each((spring, key) => values[key] = spring.get());\n return values;\n }\n /** Push an update onto the queue of each value. */\n\n\n update(props) {\n if (props) this.queue.push(createUpdate(props));\n return this;\n }\n /**\n * Start the queued animations for every spring, and resolve the returned\n * promise once all queued animations have finished or been cancelled.\n *\n * When you pass a queue (instead of nothing), that queue is used instead of\n * the queued animations added with the `update` method, which are left alone.\n */\n\n\n start(props) {\n const queue = props ? toArray(props).map(createUpdate) : this.queue;\n\n if (!props) {\n this.queue = [];\n }\n\n if (this._flush) {\n return this._flush(this, queue);\n }\n\n prepareKeys(this, queue);\n return flushUpdateQueue(this, queue);\n }\n /** Stop one animation, some animations, or all animations */\n\n\n stop(keys) {\n if (is.und(keys)) {\n this.each(spring => spring.stop());\n cancelAsync(this._state, this._lastAsyncId);\n } else {\n const springs = this.springs;\n each(toArray(keys), key => springs[key].stop());\n }\n\n return this;\n }\n /** Freeze the active animation in time */\n\n\n pause(keys) {\n if (is.und(keys)) {\n this.each(spring => spring.pause());\n } else {\n const springs = this.springs;\n each(toArray(keys), key => springs[key].pause());\n }\n\n return this;\n }\n /** Resume the animation if paused. */\n\n\n resume(keys) {\n if (is.und(keys)) {\n this.each(spring => spring.resume());\n } else {\n const springs = this.springs;\n each(toArray(keys), key => springs[key].resume());\n }\n\n return this;\n }\n /** Restart every animation. */\n\n\n reset() {\n this.each(spring => spring.reset()); // TODO: restart async \"to\" prop\n\n return this;\n }\n /** Call a function once per spring value */\n\n\n each(iterator) {\n each(this.springs, iterator);\n }\n /** Destroy every spring in this controller */\n\n\n dispose() {\n this._state.asyncTo = undefined;\n this.each(spring => spring.dispose());\n this.springs = {};\n }\n /** @internal Called at the end of every animation frame */\n\n\n _onFrame() {\n const {\n onStart,\n onChange,\n onRest\n } = this._events;\n const isActive = this._active.size > 0;\n\n if (isActive && this._phase != ACTIVE) {\n this._phase = ACTIVE;\n flush(onStart, onStart => onStart(this));\n }\n\n const values = (onChange.size || !isActive && onRest.size) && this.get();\n flush(onChange, onChange => onChange(values)); // The \"onRest\" queue is only flushed when all springs are idle.\n\n if (!isActive) {\n this._phase = IDLE;\n flush(onRest, ([onRest, result]) => {\n result.value = values;\n onRest(result);\n });\n }\n }\n /** @internal */\n\n\n onParentChange(event) {\n if (event.type == 'change') {\n this._active[event.idle ? 'delete' : 'add'](event.parent);\n\n frameLoop.onFrame(this._onFrame);\n }\n }\n\n}\n/**\n * Warning: Props might be mutated.\n */\n\nfunction flushUpdateQueue(ctrl, queue) {\n return Promise.all(queue.map(props => flushUpdate(ctrl, props))).then(results => getCombinedResult(ctrl, results));\n}\n/**\n * Warning: Props might be mutated.\n *\n * Process a single set of props using the given controller.\n *\n * The returned promise resolves to `true` once the update is\n * applied and any animations it starts are finished without being\n * stopped or cancelled.\n */\n\nfunction flushUpdate(ctrl, props, isLoop) {\n const {\n to,\n loop,\n onRest\n } = props; // Looping must be handled in this function, or else the values\n // would end up looping out-of-sync in many common cases.\n\n if (loop) {\n props.loop = false;\n }\n\n const asyncTo = is.arr(to) || is.fun(to) ? to : undefined;\n\n if (asyncTo) {\n props.to = undefined;\n props.onRest = undefined;\n } else {\n // For certain events, use batching to prevent multiple calls per frame.\n // However, batching is avoided when the `to` prop is async, because any\n // event props are used as default props instead.\n each(BATCHED_EVENTS, key => {\n const handler = props[key];\n\n if (is.fun(handler)) {\n const queue = ctrl['_events'][key];\n\n if (queue instanceof Set) {\n props[key] = () => queue.add(handler);\n } else {\n props[key] = ({\n finished,\n cancelled\n }) => {\n const result = queue.get(handler);\n\n if (result) {\n if (!finished) result.finished = false;\n if (cancelled) result.cancelled = true;\n } else {\n // The \"value\" is set before the \"handler\" is called.\n queue.set(handler, {\n value: null,\n finished,\n cancelled\n });\n }\n };\n }\n }\n });\n }\n\n const keys = props.keys || Object.keys(ctrl.springs);\n const promises = keys.map(key => ctrl.springs[key].start(props)); // Schedule the \"asyncTo\" if defined.\n\n const state = ctrl['_state'];\n\n if (asyncTo) {\n promises.push(scheduleProps(++ctrl['_lastAsyncId'], {\n props,\n state,\n actions: {\n pause: noop,\n resume: noop,\n\n start(props, resolve) {\n props.onRest = onRest;\n\n if (!props.cancel) {\n resolve(runAsync(asyncTo, props, state, ctrl));\n } // Prevent `cancel: true` from ending the current `runAsync` call,\n // except when the default `cancel` prop is being set.\n else if (hasDefaultProp(props, 'cancel')) {\n cancelAsync(state, props.callId);\n }\n }\n\n }\n }));\n } // Respect the `cancel` prop when no keys are affected.\n else if (!props.keys && props.cancel === true) {\n cancelAsync(state, ctrl['_lastAsyncId']);\n }\n\n return Promise.all(promises).then(results => {\n const result = getCombinedResult(ctrl, results);\n\n if (loop && result.finished && !(isLoop && result.noop)) {\n const nextProps = createLoopUpdate(props, loop, to);\n\n if (nextProps) {\n prepareKeys(ctrl, [nextProps]);\n return flushUpdate(ctrl, nextProps, true);\n }\n }\n\n return result;\n });\n}\n/**\n * From an array of updates, get the map of `SpringValue` objects\n * by their keys. Springs are created when any update wants to\n * animate a new key.\n *\n * Springs created by `getSprings` are neither cached nor observed\n * until they're given to `setSprings`.\n */\n\nfunction getSprings(ctrl, props) {\n const springs = _extends({}, ctrl.springs);\n\n if (props) {\n each(toArray(props), props => {\n if (is.und(props.keys)) {\n props = createUpdate(props);\n }\n\n if (!is.obj(props.to)) {\n // Avoid passing array/function to each spring.\n props = _extends(_extends({}, props), {}, {\n to: undefined\n });\n }\n\n prepareSprings(springs, props, key => {\n return createSpring(key);\n });\n });\n }\n\n return springs;\n}\n/**\n * Tell a controller to manage the given `SpringValue` objects\n * whose key is not already in use.\n */\n\nfunction setSprings(ctrl, springs) {\n each(springs, (spring, key) => {\n if (!ctrl.springs[key]) {\n ctrl.springs[key] = spring;\n spring.addChild(ctrl);\n }\n });\n}\n\nfunction createSpring(key, observer) {\n const spring = new SpringValue();\n spring.key = key;\n\n if (observer) {\n spring.addChild(observer);\n }\n\n return spring;\n}\n/**\n * Ensure spring objects exist for each defined key.\n *\n * Using the `props`, the `Animated` node of each `SpringValue` may\n * be created or updated.\n */\n\n\nfunction prepareSprings(springs, props, create) {\n if (props.keys) {\n each(props.keys, key => {\n const spring = springs[key] || (springs[key] = create(key));\n spring['_prepareNode'](props);\n });\n }\n}\n/**\n * Ensure spring objects exist for each defined key, and attach the\n * `ctrl` to them for observation.\n *\n * The queue is expected to contain `createUpdate` results.\n */\n\n\nfunction prepareKeys(ctrl, queue) {\n each(queue, props => {\n prepareSprings(ctrl.springs, props, key => {\n return createSpring(key, ctrl);\n });\n });\n}\n\n/**\n * This context affects all new and existing `SpringValue` objects\n * created with the hook API or the renderprops API.\n */\n\nconst ctx = createContext({});\nconst SpringContext = (_ref) => {\n let {\n children\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, [\"children\"]);\n\n const inherited = useContext(ctx); // Memoize the context to avoid unwanted renders.\n\n props = useMemo(() => _extends(_extends({}, inherited), props), [inherited, props.pause, props.cancel, props.immediate, props.config]);\n const {\n Provider\n } = ctx;\n return /*#__PURE__*/createElement(Provider, {\n value: props\n }, children);\n};\nSpringContext.Provider = ctx.Provider;\nSpringContext.Consumer = ctx.Consumer;\n/** Get the current values of nearest `SpringContext` component. */\n\nconst useSpringContext = () => useContext(ctx);\n\n/** Create an imperative API for manipulating an array of `Controller` objects. */\nconst SpringHandle = {\n create: getControllers => ({\n get controllers() {\n return getControllers();\n },\n\n update(props) {\n each(getControllers(), (ctrl, i) => {\n ctrl.update(getProps(props, i, ctrl));\n });\n return this;\n },\n\n async start(props) {\n const results = await Promise.all(getControllers().map((ctrl, i) => {\n const update = getProps(props, i, ctrl);\n return ctrl.start(update);\n }));\n return {\n value: results.map(result => result.value),\n finished: results.every(result => result.finished)\n };\n },\n\n stop: keys => each(getControllers(), ctrl => ctrl.stop(keys)),\n pause: keys => each(getControllers(), ctrl => ctrl.pause(keys)),\n resume: keys => each(getControllers(), ctrl => ctrl.resume(keys))\n })\n};\n\n/** @internal */\nfunction useSprings(length, props, deps) {\n const propsFn = is.fun(props) && props;\n if (propsFn && !deps) deps = [];\n // Set to 0 to prevent sync flush.\n const layoutId = useRef(0);\n const forceUpdate = useForceUpdate(); // State is updated on commit.\n\n const [state] = useState(() => ({\n ctrls: [],\n queue: [],\n\n flush(ctrl, updates) {\n const springs = getSprings(ctrl, updates); // Flushing is postponed until the component's commit phase\n // if a spring was created since the last commit.\n\n const canFlushSync = layoutId.current > 0 && !state.queue.length && !Object.keys(springs).some(key => !ctrl.springs[key]);\n return canFlushSync ? flushUpdateQueue(ctrl, updates) : new Promise(resolve => {\n setSprings(ctrl, springs);\n state.queue.push(() => {\n resolve(flushUpdateQueue(ctrl, updates));\n });\n forceUpdate();\n });\n }\n\n })); // The imperative API ref from the props of the first controller.\n\n const refProp = useRef();\n const ctrls = [...state.ctrls];\n const updates = []; // Cache old controllers to dispose in the commit phase.\n\n const prevLength = usePrev(length) || 0;\n const disposed = ctrls.slice(length, prevLength); // Create new controllers when \"length\" increases, and destroy\n // the affected controllers when \"length\" decreases.\n\n useMemo(() => {\n ctrls.length = length;\n declareUpdates(prevLength, length);\n }, [length]); // Update existing controllers when \"deps\" are changed.\n\n useMemo(() => {\n declareUpdates(0, Math.min(prevLength, length));\n }, deps);\n /** Fill the `updates` array with declarative updates for the given index range. */\n\n function declareUpdates(startIndex, endIndex) {\n for (let i = startIndex; i < endIndex; i++) {\n const ctrl = ctrls[i] || (ctrls[i] = new Controller(null, state.flush));\n let update = propsFn ? propsFn(i, ctrl) : props[i];\n\n if (update) {\n update = updates[i] = declareUpdate(update);\n\n if (i == 0) {\n refProp.current = update.ref;\n update.ref = undefined;\n }\n }\n }\n }\n\n const api = useMemo$1(() => {\n return SpringHandle.create(() => state.ctrls);\n }, []); // New springs are created during render so users can pass them to\n // their animated components, but new springs aren't cached until the\n // commit phase (see the `useLayoutEffect` callback below).\n\n const springs = ctrls.map((ctrl, i) => getSprings(ctrl, updates[i]));\n const context = useSpringContext();\n useLayoutEffect(() => {\n layoutId.current++; // Replace the cached controllers.\n\n state.ctrls = ctrls; // Update the ref prop.\n\n if (refProp.current) {\n refProp.current.current = api;\n } // Flush the commit queue.\n\n\n const {\n queue\n } = state;\n\n if (queue.length) {\n state.queue = [];\n each(queue, cb => cb());\n } // Dispose unused controllers.\n\n\n each(disposed, ctrl => ctrl.dispose()); // Update existing controllers.\n\n each(ctrls, (ctrl, i) => {\n const values = springs[i];\n setSprings(ctrl, values); // Update the default props.\n\n ctrl.start({\n default: context\n }); // Apply updates created during render.\n\n const update = updates[i];\n\n if (update) {\n // Start animating unless a ref exists.\n if (refProp.current) {\n ctrl.queue.push(update);\n } else {\n ctrl.start(update);\n }\n }\n });\n }); // Dispose all controllers on unmount.\n\n useOnce(() => () => {\n each(state.ctrls, ctrl => ctrl.dispose());\n }); // Return a deep copy of the `springs` array so the caller can\n // safely mutate it during render.\n\n const values = springs.map(x => _extends({}, x));\n return propsFn || arguments.length == 3 ? [values, api.start, api.stop] : values;\n}\n\n/**\n * The props that `useSpring` recognizes.\n */\n\n/** @internal */\nfunction useSpring(props, deps) {\n const isFn = is.fun(props);\n const [[values], update, stop] = useSprings(1, isFn ? props : [props], isFn ? deps || [] : deps);\n return isFn || arguments.length == 2 ? [values, update, stop] : values;\n}\n\nfunction useTrail(length, propsArg, deps) {\n const propsFn = is.fun(propsArg) && propsArg;\n if (propsFn && !deps) deps = [];\n const ctrls = [];\n const result = useSprings(length, (i, ctrl) => {\n ctrls[i] = ctrl;\n return getProps(propsArg, i, ctrl);\n }, // Ensure the props function is called when no deps exist.\n // This works around the 3 argument rule.\n deps || [{}]);\n useLayoutEffect(() => {\n const reverse = is.obj(propsArg) && propsArg.reverse;\n\n for (let i = 0; i < ctrls.length; i++) {\n const parent = ctrls[i + (reverse ? 1 : -1)];\n if (parent) ctrls[i].update({\n to: parent.springs\n }).start();\n }\n }, deps);\n\n if (propsFn || arguments.length == 3) {\n const update = result[1];\n result[1] = useCallbackOne(propsArg => {\n const reverse = is.obj(propsArg) && propsArg.reverse;\n return update((i, ctrl) => {\n const props = getProps(propsArg, i, ctrl);\n const parent = ctrls[i + (reverse ? 1 : -1)];\n if (parent) props.to = parent.springs;\n return props;\n });\n }, deps);\n return result;\n }\n\n return result[0];\n}\n\n// TODO: convert to \"const enum\" once Babel supports it\n\n/** This transition is being mounted */\nconst MOUNT = 'mount';\n/** This transition is entering or has entered */\n\nconst ENTER = 'enter';\n/** This transition had its animations updated */\n\nconst UPDATE = 'update';\n/** This transition will expire after animating */\n\nconst LEAVE = 'leave';\n\nfunction useTransition(data, props, deps) {\n const {\n ref,\n reset,\n sort,\n trail = 0,\n expires = true\n } = props; // Every item has its own transition.\n\n const items = toArray(data);\n const transitions = []; // Keys help with reusing transitions between renders.\n // The `key` prop can be undefined (which means the items themselves are used\n // as keys), or a function (which maps each item to its key), or an array of\n // keys (which are assigned to each item by index).\n\n const keys = getKeys(items, props); // The \"onRest\" callbacks need a ref to the latest transitions.\n\n const usedTransitions = useRef(null);\n const prevTransitions = reset ? null : usedTransitions.current;\n useLayoutEffect(() => {\n usedTransitions.current = transitions;\n }); // Destroy all transitions on dismount.\n\n useOnce(() => () => each(usedTransitions.current, t => {\n if (t.expired) {\n clearTimeout(t.expirationId);\n }\n\n t.ctrl.dispose();\n })); // Map old indices to new indices.\n\n const reused = [];\n if (prevTransitions) each(prevTransitions, (t, i) => {\n // Expired transitions are not rendered.\n if (t.expired) {\n clearTimeout(t.expirationId);\n } else {\n i = reused[i] = keys.indexOf(t.key);\n if (~i) transitions[i] = t;\n }\n }); // Mount new items with fresh transitions.\n\n each(items, (item, i) => {\n transitions[i] || (transitions[i] = {\n key: keys[i],\n item,\n phase: MOUNT,\n ctrl: new Controller()\n });\n }); // Update the item of any transition whose key still exists,\n // and ensure leaving transitions are rendered until they finish.\n\n if (reused.length) {\n let i = -1;\n each(reused, (keyIndex, prevIndex) => {\n const t = prevTransitions[prevIndex];\n\n if (~keyIndex) {\n i = transitions.indexOf(t);\n transitions[i] = _extends(_extends({}, t), {}, {\n item: items[keyIndex]\n });\n } else if (props.leave) {\n transitions.splice(++i, 0, t);\n }\n });\n }\n\n if (is.fun(sort)) {\n transitions.sort((a, b) => sort(a.item, b.item));\n } // Track cumulative delay for the \"trail\" prop.\n\n\n let delay = -trail; // Expired transitions use this to dismount.\n\n const forceUpdate = useForceUpdate(); // These props are inherited by every phase change.\n\n const defaultProps = getDefaultProps(props); // Generate changes to apply in useEffect.\n\n const changes = new Map();\n each(transitions, (t, i) => {\n const key = t.key;\n const prevPhase = t.phase;\n let to;\n let phase;\n\n if (prevPhase == MOUNT) {\n to = props.enter;\n phase = ENTER;\n } else {\n const isLeave = keys.indexOf(key) < 0;\n\n if (prevPhase != LEAVE) {\n if (isLeave) {\n to = props.leave;\n phase = LEAVE;\n } else if (to = props.update) {\n phase = UPDATE;\n } else return;\n } else if (!isLeave) {\n to = props.enter;\n phase = ENTER;\n } else return;\n } // When \"to\" is a function, it can return (1) an array of \"useSpring\" props,\n // (2) an async function, or (3) an object with any \"useSpring\" props.\n\n\n to = callProp(to, t.item, i);\n to = is.obj(to) ? inferTo(to) : {\n to\n };\n\n if (!to.config) {\n const config = props.config || defaultProps.config;\n to.config = callProp(config, t.item, i);\n } // The payload is used to update the spring props once the current render is committed.\n\n\n const payload = _extends(_extends({}, defaultProps), {}, {\n delay: delay += trail,\n // This prevents implied resets.\n reset: false\n }, to);\n\n if (phase == ENTER && is.und(payload.from)) {\n // The `initial` prop is used on the first render of our parent component,\n // as well as when `reset: true` is passed. It overrides the `from` prop\n // when defined, and it makes `enter` instant when null.\n const from = is.und(props.initial) || prevTransitions ? props.from : props.initial;\n payload.from = callProp(from, t.item, i);\n }\n\n const {\n onRest\n } = payload;\n\n payload.onRest = result => {\n const transitions = usedTransitions.current;\n const t = transitions.find(t => t.key === key);\n if (!t) return;\n\n if (is.fun(onRest)) {\n onRest(result, t);\n } // Reset the phase of a cancelled enter/leave transition, so it can\n // retry the animation on the next render.\n\n\n if (result.cancelled && t.phase != UPDATE) {\n t.phase = prevPhase;\n return;\n }\n\n if (t.ctrl.idle) {\n const idle = transitions.every(t => t.ctrl.idle);\n\n if (t.phase == LEAVE) {\n const expiry = callProp(expires, t.item);\n\n if (expiry !== false) {\n const expiryMs = expiry === true ? 0 : expiry;\n t.expired = true; // Force update once the expiration delay ends.\n\n if (!idle && expiryMs > 0) {\n // The maximum timeout is 2^31-1\n if (expiryMs <= 0x7fffffff) t.expirationId = setTimeout(forceUpdate, expiryMs);\n return;\n }\n }\n } // Force update once idle and expired items exist.\n\n\n if (idle && transitions.some(t => t.expired)) {\n forceUpdate();\n }\n }\n };\n\n const springs = getSprings(t.ctrl, payload);\n changes.set(t, {\n phase,\n springs,\n payload\n });\n }); // The prop overrides from an ancestor.\n\n const context = useSpringContext(); // Merge the context into each transition.\n\n useLayoutEffect(() => {\n each(transitions, t => {\n t.ctrl.start({\n default: context\n });\n });\n }, [context]);\n const api = useMemo$1(() => {\n return SpringHandle.create(() => {\n return usedTransitions.current.map(t => t.ctrl);\n });\n }, []);\n useImperativeHandle(ref, () => api);\n useLayoutEffect(() => {\n each(changes, ({\n phase,\n springs,\n payload\n }, t) => {\n setSprings(t.ctrl, springs);\n\n if (!context.cancel) {\n t.phase = phase;\n\n if (phase == ENTER) {\n t.ctrl.start({\n default: context\n });\n }\n\n t.ctrl[ref ? 'update' : 'start'](payload);\n }\n });\n }, reset ? void 0 : deps);\n\n const renderTransitions = render => /*#__PURE__*/createElement(Fragment, null, transitions.map((t, i) => {\n const {\n springs\n } = changes.get(t) || t.ctrl;\n const elem = render(_extends({}, springs), t.item, t, i);\n return elem && elem.type ? /*#__PURE__*/createElement(elem.type, _extends({}, elem.props, {\n key: is.str(t.key) || is.num(t.key) ? t.key : t.ctrl.id,\n ref: elem.ref\n })) : elem;\n }));\n\n return arguments.length == 3 ? [renderTransitions, api.start, api.stop] : renderTransitions;\n}\n\nfunction getKeys(items, {\n key,\n keys = key\n}) {\n return is.und(keys) ? items : is.fun(keys) ? items.map(keys) : toArray(keys);\n}\n\n/**\n * The `Spring` component passes `SpringValue` objects to your render prop.\n */\nfunction Spring(_ref) {\n let {\n children\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, [\"children\"]);\n\n return children(useSpring(props));\n}\n\nfunction Trail(_ref) {\n let {\n items,\n children\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, [\"items\", \"children\"]);\n\n const trails = useTrail(items.length, props);\n return items.map((item, index) => {\n const result = children(item, index);\n return is.fun(result) ? result(trails[index]) : result;\n });\n}\n\nfunction Transition(_ref) {\n let {\n items,\n children\n } = _ref,\n props = _objectWithoutPropertiesLoose(_ref, [\"items\", \"children\"]);\n\n return /*#__PURE__*/createElement(Fragment, null, useTransition(items, props)(children));\n}\n\n/**\n * An `Interpolation` is a memoized value that's computed whenever one of its\n * `FluidValue` dependencies has its value changed.\n *\n * Other `FrameValue` objects can depend on this. For example, passing an\n * `Interpolation` as the `to` prop of a `useSpring` call will trigger an\n * animation toward the memoized value.\n */\n\nclass Interpolation extends FrameValue {\n /** Useful for debugging. */\n\n /** Equals false when in the frameloop */\n\n /** The function that maps inputs values to output */\n constructor(source, args) {\n super();\n this.source = source;\n this.key = void 0;\n this.idle = true;\n this.calc = void 0;\n this.calc = createInterpolator(...args);\n\n const value = this._get();\n\n const nodeType = is.arr(value) ? AnimatedArray : AnimatedValue; // Assume the computed value never changes type.\n\n setAnimated(this, nodeType.create(value));\n }\n\n advance(_dt) {\n const value = this._get();\n\n const oldValue = this.get();\n\n if (!isEqual(value, oldValue)) {\n getAnimated(this).setValue(value);\n\n this._onChange(value, this.idle);\n }\n }\n\n _get() {\n const inputs = is.arr(this.source) ? this.source.map(node => node.get()) : toArray(this.source.get());\n return this.calc(...inputs);\n }\n\n _reset() {\n each(getPayload(this), node => node.reset());\n\n super._reset();\n }\n\n _start() {\n this.idle = false;\n\n super._start();\n\n if (skipAnimation) {\n this.idle = true;\n this.advance();\n } else {\n frameLoop.start(this);\n }\n }\n\n _attach() {\n // Start observing our \"source\" once we have an observer.\n let idle = true;\n let priority = 1;\n each(toArray(this.source), source => {\n if (isFrameValue(source)) {\n if (!source.idle) idle = false;\n priority = Math.max(priority, source.priority + 1);\n }\n\n source.addChild(this);\n });\n this.priority = priority;\n\n if (!idle) {\n this._reset();\n\n this._start();\n }\n }\n\n _detach() {\n // Stop observing our \"source\" once we have no observers.\n each(toArray(this.source), source => {\n source.removeChild(this);\n }); // This removes us from the frameloop.\n\n this.idle = true;\n }\n /** @internal */\n\n\n onParentChange(event) {\n // Ensure our start value respects our parent values, in case\n // any of their animations were restarted with the \"reset\" prop.\n if (event.type == 'start') {\n this.advance();\n } // Change events are useful for (1) reacting to non-animated parents\n // and (2) reacting to the last change in a parent animation.\n else if (event.type == 'change') {\n // If we're idle, we know for sure that this change is *not*\n // caused by an animation.\n if (this.idle) {\n this.advance();\n } // Leave the frameloop when all parents are done animating.\n else if (event.idle) {\n this.idle = toArray(this.source).every(source => source.idle !== false);\n\n if (this.idle) {\n this.advance();\n each(getPayload(this), node => {\n node.done = true;\n });\n }\n }\n } // Ensure our priority is greater than all parents, which means\n // our value won't be updated until our parents have updated.\n else if (event.type == 'priority') {\n this.priority = toArray(this.source).reduce((max, source) => Math.max(max, (source.priority || 0) + 1), 0);\n }\n\n super.onParentChange(event);\n }\n\n}\n\n/** Map the value of one or more dependencies */\n\nconst to = (source, ...args) => new Interpolation(source, args);\n/** @deprecated Use the `to` export instead */\n\nconst interpolate = (source, ...args) => (deprecateInterpolate(), new Interpolation(source, args));\n/** Extract the raw value types that are being interpolated */\n\nGlobals.assign({\n createStringInterpolator: createStringInterpolator$1,\n to: (source, args) => new Interpolation(source, args)\n});\n/** Advance all animations forward one frame */\n\nconst update = () => Globals.frameLoop.advance();\n\nexport { BailSignal, Controller, FrameValue, Interpolation, Spring, SpringContext, SpringHandle, SpringValue, Trail, Transition, config, inferTo, interpolate, to, update, useChain, useSpring, useSprings, useTrail, useTransition };\n//# sourceMappingURL=index.js.map\n"],"names":[],"sourceRoot":""}