{"version":3,"sources":["jsdelivr-header.js","https://cdn.615873.xyz/npm/ractive-transitions-fly@0.3.0/dist/ractive-transitions-fly.umd.js"],"names":[],"mappings":"AAAA;AACA;AACA;AACA;AACA;AACA;AACA,CCNC,SAAU,EAAQ,GACC,iBAAZ,SAA0C,oBAAX,OAAyB,OAAO,QAAU,IAC9D,mBAAX,QAAyB,OAAO,IAAM,OAAO,GACpD,EAAO,QAAQ,YAAY,IAAM,GAClC,CAJA,CAIE,MAAM,WAAc,aAErB,IAAI,EAAW,CACd,SAAU,IACV,OAAQ,UACR,QAAS,EACT,GAAI,IACJ,EAAG,GAGJ,SAAS,EAAM,GACd,OAAY,IAAR,GAA4B,iBAAR,EAChB,EAGD,EAAM,IACd,CA2BA,OA1BA,SAAa,EAAG,GAGf,IAGI,EAAY,CACf,UAAW,aAJJ,GAFR,EAAS,EAAE,cAAc,EAAQ,IAEZ,GAIU,IAHvB,EAAM,EAAO,GAGoB,IACxC,QAAS,GAGN,OAAS,EAET,EAAE,SAEL,EAAS,EAAE,SAAS,CAAC,UAAW,cAGhC,EAAE,SAAS,IAEX,EAAS,EAGV,EAAE,aAAa,EAAQ,GAAQ,KAAK,EAAE,SACvC,CAID","file":"https://cdn.615873.xyz/npm/ractive-transitions-fly@0.3.0/dist/ractive-transitions-fly.umd.js","sourceRoot":"","sourcesContent":["https://cdn.615873.xyz/**\n * Minified by jsDelivr using Terser v5.39.0.\n * Original file: /npm/ractive-transitions-fly@0.3.0/dist/ractive-transitions-fly.umd.js\n *\n * Do NOT use SRI with dynamically generated files! More information: https://www.jsdelivr.com/using-sri-with-dynamic-files\n */\n","(function (global, factory) {\n\ttypeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :\n\ttypeof define === 'function' && define.amd ? define(factory) :\n\tglobal.Ractive.transitions.fly = factory();\n}(this, function () { 'use strict';\n\n\tvar DEFAULTS = {\n\t\tduration: 400,\n\t\teasing: 'easeOut',\n\t\topacity: 0,\n\t\tx: -500,\n\t\ty: 0\n\t};\n\n\tfunction addPx(num) {\n\t\tif (num === 0 || typeof num === 'string') {\n\t\t\treturn num;\n\t\t}\n\n\t\treturn num + 'px';\n\t}\n\tfunction fly(t, params) {\n\t\tparams = t.processParams(params, DEFAULTS);\n\n\t\tvar x = addPx(params.x);\n\t\tvar y = addPx(params.y);\n\n\t\tvar offscreen = {\n\t\t\ttransform: 'translate(' + x + ',' + y + ')',\n\t\t\topacity: 0\n\t\t};\n\n\t\tvar target = undefined;\n\n\t\tif (t.isIntro) {\n\t\t\t// animate to the current style\n\t\t\ttarget = t.getStyle(['opacity', 'transform']);\n\n\t\t\t// set offscreen style\n\t\t\tt.setStyle(offscreen);\n\t\t} else {\n\t\t\ttarget = offscreen;\n\t\t}\n\n\t\tt.animateStyle(target, params).then(t.complete);\n\t}\n\n\treturn fly;\n\n}));"]}