refactor: improve relation api

This commit is contained in:
chenjiahan
2020-08-23 15:36:16 +08:00
parent ff3a5d66ab
commit 50fc123b3e
4 changed files with 30 additions and 25 deletions
+2 -2
View File
@@ -1,5 +1,5 @@
import { createNamespace } from '../utils';
import { useParent } from '../api/use-relation';
import { useChildren } from '../api/use-relation';
const [createComponent, bem] = createNamespace('action-bar');
@@ -14,7 +14,7 @@ export default createComponent({
},
setup(props, { slots }) {
useParent(ACTION_BAR_KEY);
useChildren(ACTION_BAR_KEY);
return () => (
<div class={bem({ unfit: !props.safeAreaInsetBottom })}>