Skip to content

Commit 8ca22e0

Browse files
committed
docs: update docs
1 parent 839a7f6 commit 8ca22e0

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

site/components/demoBox.vue

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,6 @@ export default {
4646
isIframe: Boolean,
4747
},
4848
inject: {
49-
_store: { default: {}},
5049
iframeDemo: { default: {}},
5150
demoContext: { default: {}},
5251
},
@@ -66,10 +65,10 @@ export default {
6665
const iframeDemoKey = usTitle.split(' ').join('-').toLowerCase()
6766
const id = ['components', name.replace(/-cn\/?$/, ''), 'demo', ...usTitle.split(' ')].join('-').toLowerCase()
6867
69-
if (this._store.store) {
70-
const { currentSubMenu } = this._store.store.getState()
68+
if (this.demoContext.store) {
69+
const { currentSubMenu } = this.demoContext.store.getState()
7170
// id = `${id}-${currentSubMenu.length + 1}`
72-
this._store.store.setState({ currentSubMenu: [...currentSubMenu, { cnTitle, usTitle, id }] })
71+
this.demoContext.store.setState({ currentSubMenu: [...currentSubMenu, { cnTitle, usTitle, id }] })
7372
}
7473
return {
7574
isOpen: false,

0 commit comments

Comments
 (0)