feat: use keyboard to change
This commit is contained in:
parent
72be3f922e
commit
0378e6346a
|
@ -57,10 +57,11 @@ export default {
|
||||||
methods: {
|
methods: {
|
||||||
init() {
|
init() {
|
||||||
const canvas = this.$refs.canvas
|
const canvas = this.$refs.canvas
|
||||||
|
const dialog = document.querySelector('#tiny-engine-chart')
|
||||||
this.bpmnModeler = new BpmnModeler({
|
this.bpmnModeler = new BpmnModeler({
|
||||||
container: canvas,
|
container: canvas,
|
||||||
keyboard: {
|
keyboard: {
|
||||||
bindTo: window
|
bindTo: dialog
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
|
|
|
@ -98,13 +98,15 @@
|
||||||
|
|
||||||
<tiny-dialog-box
|
<tiny-dialog-box
|
||||||
class="tiny-engine-chart"
|
class="tiny-engine-chart"
|
||||||
|
id="tiny-engine-chart"
|
||||||
v-model:visible="state.chart"
|
v-model:visible="state.chart"
|
||||||
append-to-body="true"
|
append-to-body="true"
|
||||||
width="100%"
|
width="100%"
|
||||||
top="5vh"
|
top="5vh"
|
||||||
maxHeight="90vh"
|
maxHeight="90vh"
|
||||||
|
tabindex="0"
|
||||||
>
|
>
|
||||||
<design-chart />
|
<design-chart v-if="state.chart" />
|
||||||
</tiny-dialog-box>
|
</tiny-dialog-box>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
Loading…
Reference in New Issue