UNPKG

@ark-ui/vue

Version:

A collection of unstyled, accessible UI components for Vue, utilizing state machines for seamless interaction.

21 lines (18 loc) 692 B
import { defineComponent, createBlock, openBlock, unref, mergeProps } from 'vue'; import { ark } from '../factory.js'; import { useForwardExpose } from '../../utils/use-forward-expose.js'; import { useAvatarContext } from './use-avatar-context.js'; const _sfc_main = /* @__PURE__ */ defineComponent({ __name: "avatar-image", props: { asChild: { type: Boolean } }, setup(__props) { const avatar = useAvatarContext(); useForwardExpose(); return (_ctx, _cache) => { return openBlock(), createBlock(unref(ark).img, mergeProps(unref(avatar).getImageProps(), { "as-child": __props.asChild }), null, 16, ["as-child"]); }; } }); export { _sfc_main as default };