PopupInner.js 894 B

12345678910111213141516171819202122232425262728293031323334
  1. import _mergeJSXProps from 'babel-helper-vue-jsx-merge-props';
  2. import PropTypes from '../_util/vue-types';
  3. import LazyRenderBox from './LazyRenderBox';
  4. import { getListeners } from '../_util/props-util';
  5. export default {
  6. props: {
  7. hiddenClassName: PropTypes.string.def(''),
  8. prefixCls: PropTypes.string,
  9. visible: PropTypes.bool
  10. },
  11. render: function render() {
  12. var h = arguments[0];
  13. var _$props = this.$props,
  14. prefixCls = _$props.prefixCls,
  15. visible = _$props.visible,
  16. hiddenClassName = _$props.hiddenClassName;
  17. var divProps = {
  18. on: getListeners(this)
  19. };
  20. return h(
  21. 'div',
  22. _mergeJSXProps([divProps, { 'class': !visible ? hiddenClassName : '' }]),
  23. [h(
  24. LazyRenderBox,
  25. { 'class': prefixCls + '-content', attrs: { visible: visible }
  26. },
  27. [this.$slots['default']]
  28. )]
  29. );
  30. }
  31. };