ant-design-x-vue-next
Version:
Ant Design X for Vue — community continuation aligned with @ant-design/x
72 lines (71 loc) • 1.73 kB
JavaScript
import { q as m } from "../../chunks/module-chunk.mjs";
import "../../_util/cssinjs/StyleContext.mjs";
import "vue";
import "../../_util/cssinjs/theme/ThemeCache.mjs";
import "../../_util/warning.mjs";
import e from "../../_util/cssinjs/Keyframes.mjs";
import "../../_util/cssinjs/transformers/legacyLogicalProperties.mjs";
import { initMotion as s } from "./init.mjs";
const c = new e("antXFadeInLeft", {
"0%": {
maskPosition: "100% 0"
},
"100%": {
maskPosition: "0% 0%"
}
}), p = new e("antXFadeIn", {
"0%": {
opacity: 0
},
"100%": {
opacity: 1
}
}), r = new e("antXFadeOut", {
"0%": {
opacity: 1
},
"100%": {
opacity: 0
}
}), C = (n, i = !1) => {
const { antCls: a } = n, t = `${a}-x-fade-left`, o = i ? "&" : "";
return [
{
[n.componentCls]: {
...s(t, c, r, "1s", i),
[`${o}${t}-enter,${o}${t}-appear`]: {
transitionProperty: "mask-position",
animationTimingFunction: "linear",
maskImage: `linear-gradient(90deg, ${n.colorTextBase} 33%, ${new m(n.colorTextBase).setA(0)} 66%)`,
maskSize: "300% 100%",
maskPosition: "100% 0%"
},
[`${o}${t}-leave`]: {
animationTimingFunction: "linear"
}
}
}
];
}, g = (n, i = !1) => {
const { antCls: a } = n, t = `${a}-x-fade`, o = i ? "&" : "";
return [
{
[n.componentCls]: {
...s(t, p, r, "1.2s", i),
[`${o}${t}-enter,${o}${t}-appear`]: {
opacity: 0
},
[`${o}${t}-leave`]: {
animationTimingFunction: "linear"
}
}
}
];
};
export {
p as fadeIn,
c as fadeInLeft,
r as fadeOut,
C as initFadeLeftMotion,
g as initFadeMotion
};