/**
 * ldesign v0.4.6
 * (c) 2023 ldesign
 * @license MIT
 */

import _defineProperty from '@babel/runtime/helpers/defineProperty';
import { defineComponent, computed } from '@vue/composition-api';
import { usePrefixClass } from '../../hooks/useConfig.js';
import { useTNodeJSX } from '../../hooks/tnode.js';
import '../../config-provider/useConfig.js';
import '../../config-provider/context.js';
import 'lodash/merge';
import 'lodash/mergeWith';
import '../../_common/js/global-config/default-config.js';
import '../../_common/js/global-config/locale/zh_CN.js';
import '@babel/runtime/helpers/typeof';
import '../../_chunks/dep-be599ec8.js';
import 'dayjs';
import '../../_chunks/dep-67ff4010.js';
import '../../config-provider/type.js';
import 'lodash/isEmpty';
import 'lodash/isFunction';
import 'lodash/camelCase';
import 'lodash/kebabCase';
import '../../hooks/render-tnode.js';
import 'lodash/isString';
import 'lodash/isObject';

var propHandler = {
  type: Function,
  "default": function _default() {
    return function () {};
  }
};
var TImageViewerIcon = defineComponent({
  name: "TImageModalIcon",
  props: {
    disabled: Boolean,
    clickHandler: propHandler,
    label: String,
    icon: Function
  },
  setup: function setup(props) {
    var classPrefix = usePrefixClass();
    var renderTNodeJSX = useTNodeJSX();
    var wrapClass = computed(function () {
      return ["".concat(classPrefix.value, "-image-viewer__modal-icon"), _defineProperty({}, "".concat(classPrefix.value, "-is-disabled"), props.disabled)];
    });
    return {
      wrapClass: wrapClass,
      classPrefix: classPrefix,
      renderTNodeJSX: renderTNodeJSX
    };
  },
  render: function render() {
    var h = arguments[0];
    return h("div", {
      "class": this.wrapClass,
      "on": {
        "click": this.clickHandler
      }
    }, [this.renderTNodeJSX("icon"), this.label && h("span", {
      "class": "".concat(this.classPrefix, "-image-viewer__modal-icon-label")
    }, [this.label])]);
  }
});

export { TImageViewerIcon as default };
//# sourceMappingURL=ImageModalIcon.js.map
