UNPKG

@extclp/vexip-ui

Version:

A Vue 3 UI library, Highly customizability, full TypeScript, performance pretty good

49 lines (48 loc) 1.32 kB
import { defineComponent as i, inject as f, reactive as l, watch as s, onBeforeUnmount as a, renderSlot as m } from "vue"; import { useProps as y } from "@vexip-ui/config"; import { tourStepProps as u } from "./props.mjs"; import { TOUR_STATE as P } from "./symbol.mjs"; const S = Object.keys(u), T = [], b = ["renderer"], g = { default: null, isFunc: !0, static: !0 }, R = i({ name: "TourStep", props: u, setup(c, { slots: o }) { const n = y("tourStep", c, { target: { default: null, static: !0 }, placement: "bottom", title: "", content: "", order: { default: 0, static: !0 }, type: "default", renderer: g }), e = f(P, null), r = l({}); for (const t of S) b.includes(t) || s( () => n[t], (d) => { r[t] = d; }, { immediate: !0, deep: T.includes(t) } ); s(() => n.renderer, p), p(), e == null || e.increaseStep(r), a(() => { e == null || e.decreaseStep(r); }); function p() { typeof o.default == "function" ? r.renderer = (t) => m(o, "default", t) : typeof n.renderer == "function" ? r.renderer = n.renderer : r.renderer = void 0; } return () => null; } }); export { R as default }; //# sourceMappingURL=tour-step.mjs.map