refactor(core): set vue flow version as regular string instead of ref
Signed-off-by: braks <78412429+bcakmakoglu@users.noreply.github.com>
This commit is contained in:
@@ -61,6 +61,7 @@ export class Storage {
|
|||||||
...toRefs(reactiveState),
|
...toRefs(reactiveState),
|
||||||
emits,
|
emits,
|
||||||
id,
|
id,
|
||||||
|
vueFlowVersion: typeof __VUE_FLOW_VERSION__ !== 'undefined' ? __VUE_FLOW_VERSION__ : 'UNKNOWN',
|
||||||
$destroy: () => {
|
$destroy: () => {
|
||||||
this.remove(id)
|
this.remove(id)
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -132,8 +132,6 @@ function defaultState(): State {
|
|||||||
__experimentalFeatures: {
|
__experimentalFeatures: {
|
||||||
nestedFlow: false,
|
nestedFlow: false,
|
||||||
},
|
},
|
||||||
|
|
||||||
vueFlowVersion: typeof __VUE_FLOW_VERSION__ !== 'undefined' ? __VUE_FLOW_VERSION__ : '-',
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -143,9 +143,6 @@ export interface State extends Omit<FlowOptions, 'id' | 'modelValue'> {
|
|||||||
disableKeyboardA11y: boolean
|
disableKeyboardA11y: boolean
|
||||||
|
|
||||||
ariaLiveMessage: string
|
ariaLiveMessage: string
|
||||||
|
|
||||||
/** current vue flow version you're using */
|
|
||||||
readonly vueFlowVersion: string
|
|
||||||
}
|
}
|
||||||
|
|
||||||
export type SetElements = (elements: Elements | ((elements: FlowElements) => Elements)) => void
|
export type SetElements = (elements: Elements | ((elements: FlowElements) => Elements)) => void
|
||||||
@@ -311,6 +308,8 @@ export type ComputedGetters = {
|
|||||||
export type VueFlowStore = {
|
export type VueFlowStore = {
|
||||||
readonly id: string
|
readonly id: string
|
||||||
readonly emits: FlowHooksEmit
|
readonly emits: FlowHooksEmit
|
||||||
|
/** current vue flow version you're using */
|
||||||
|
readonly vueFlowVersion: string
|
||||||
} & FlowHooksOn &
|
} & FlowHooksOn &
|
||||||
ToRefs<State> &
|
ToRefs<State> &
|
||||||
Readonly<ComputedGetters> &
|
Readonly<ComputedGetters> &
|
||||||
|
|||||||
Reference in New Issue
Block a user