UNPKG

@opensig/opendesign

Version:

16 lines (15 loc) 411 B
import { defineComponent } from "vue"; import { getFirstComponent } from "../_utils/vue-utils.mjs"; const OChildOnly = defineComponent({ name: "OChildOnly", setup(_props, { slots }) { return () => { var _a; const children = (_a = slots.default) == null ? void 0 : _a.call(slots); return children ? getFirstComponent(children) : null; }; } }); export { OChildOnly as default };