| 12345678910111213141516171819202122232425262728 |
- import "./index.scss";
- export default {
- name: "VciFadeFlow",
- props: {
- direction: {
- type: String,
- default: "ltr"
- }
- },
- mounted() {
- const cls = `vci-amt-fade-flow-${this.direction}`;
- this.$el.addEventListener(
- "animationend",
- () => {
- this.$el.classList.remove(cls);
- this.$emit("complete");
- },
- {
- once: true
- }
- );
- this.$el.classList.add(cls);
- },
- render() {
- return this.$scopedSlots.default ? this.$scopedSlots.default() : null;
- }
- };
|