ant-design-vue
Version:
An enterprise-class UI design language and Vue-based implementation
33 lines (29 loc) • 964 B
JavaScript
import _mergeJSXProps from 'babel-helper-vue-jsx-merge-props';
import _defineProperty from 'babel-runtime/helpers/defineProperty';
import PropTypes from '../_util/vue-types';
import { ConfigConsumerProps } from '../config-provider';
import { getListeners } from '../_util/props-util';
export default {
name: 'ACardGrid',
__ANT_CARD_GRID: true,
props: {
prefixCls: PropTypes.string
},
inject: {
configProvider: { 'default': function _default() {
return ConfigConsumerProps;
} }
},
render: function render() {
var h = arguments[0];
var customizePrefixCls = this.$props.prefixCls;
var getPrefixCls = this.configProvider.getPrefixCls;
var prefixCls = getPrefixCls('card', customizePrefixCls);
var classString = _defineProperty({}, prefixCls + '-grid', true);
return h(
'div',
_mergeJSXProps([{ on: getListeners(this) }, { 'class': classString }]),
[this.$slots['default']]
);
}
};