'use strict';

Object.defineProperty(exports, '__esModule', { value: true });

var vue = require('vue');
require('../../../hooks/index.js');
require('../../../tokens/index.js');
var arrow = require('./arrow.js');
require('./arrow.vue_vue_type_style_index_0_scoped_true_lang.js');
var pluginVue_exportHelper = require('../../../_virtual/plugin-vue_export-helper.js');
var index = require('../../../hooks/use-namespace/index.js');
var popper = require('../../../tokens/popper.js');

const __default__ = vue.defineComponent({
  name: "ElPopperArrow",
  inheritAttrs: false
});
const _sfc_main = /* @__PURE__ */ vue.defineComponent({
  ...__default__,
  props: arrow.popperArrowProps,
  setup(__props, { expose }) {
    const props = __props;
    vue.useCssVars((_ctx) => ({
      "7faf8140-background": vue.unref(background),
      "7faf8140-border": vue.unref(border)
    }));
    const ns = index.useNamespace("popper");
    const { arrowOffset, arrowRef } = vue.inject(popper.POPPER_CONTENT_INJECTION_KEY, void 0);
    vue.watch(() => props.arrowOffset, (val) => {
      arrowOffset.value = val;
    });
    vue.onBeforeUnmount(() => {
      arrowRef.value = void 0;
    });
    const customStyle = vue.inject("$custom-style-filter", vue.reactive({}));
    const { border, background } = vue.toRefs(customStyle);
    expose({
      arrowRef
    });
    return (_ctx, _cache) => {
      return vue.openBlock(), vue.createElementBlock("span", {
        ref_key: "arrowRef",
        ref: arrowRef,
        class: vue.normalizeClass([vue.unref(ns).e("arrow"), vue.unref(background) && "custom-bg", vue.unref(border) && "custom-br"]),
        "data-popper-arrow": ""
      }, null, 2);
    };
  }
});
var ElPopperArrow = /* @__PURE__ */ pluginVue_exportHelper["default"](_sfc_main, [["__scopeId", "data-v-7faf8140"], ["__file", "/Users/st/Desktop/vue/nxx-ui/packages/components/popper/src/arrow.vue"]]);

exports["default"] = ElPopperArrow;
//# sourceMappingURL=arrow2.js.map
