ant-design-vue
Version:
An enterprise-class UI design language and Vue-based implementation
65 lines • 1.44 kB
JavaScript
import { inject, provide } from 'vue';
import PropTypes from '../_util/vue-types';
export var GlobalFormContextKey = Symbol('GlobalFormContextKey');
export var useProvideGlobalForm = function useProvideGlobalForm(state) {
provide(GlobalFormContextKey, state);
};
export var useInjectGlobalForm = function useInjectGlobalForm() {
return inject(GlobalFormContextKey, {});
};
export var GlobalConfigContextKey = Symbol('GlobalConfigContextKey');
export var configProviderProps = function configProviderProps() {
return {
getTargetContainer: {
type: Function
},
getPopupContainer: {
type: Function
},
prefixCls: String,
getPrefixCls: {
type: Function
},
renderEmpty: {
type: Function
},
transformCellText: {
type: Function
},
csp: {
type: Object,
default: undefined
},
input: {
type: Object
},
autoInsertSpaceInButton: PropTypes.looseBool,
locale: {
type: Object,
default: undefined
},
pageHeader: {
type: Object
},
componentSize: {
type: String
},
direction: {
type: String
},
space: {
type: Object
},
virtual: PropTypes.looseBool,
dropdownMatchSelectWidth: {
type: [Number, Boolean],
default: true
},
form: {
type: Object,
default: undefined
},
// internal use
notUpdateGlobalConfig: Boolean
};
};