fix: col error when not in row

This commit is contained in:
tanjinzhou 2021-06-09 11:21:49 +08:00
parent 617e534fda
commit a2e5d966e1

View File

@ -1,3 +1,4 @@
import { computed } from 'vue';
import { Ref, inject, InjectionKey, provide, ComputedRef } from 'vue';
export interface RowContext {
@ -13,7 +14,11 @@ const useProvideRow = (state: RowContext) => {
};
const useInjectRow = () => {
return inject(RowContextKey);
return inject(RowContextKey, {
gutter: computed(() => undefined),
wrap: computed(() => undefined),
supportFlexGap: computed(() => undefined),
});
};
export { useInjectRow, useProvideRow };