chore: lint files
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
<script lang="ts" setup>
|
||||
import { VueFlow, MiniMap, Controls, Background, isNode, useVueFlow, Elements } from '@braks/vue-flow'
|
||||
import type { Elements } from '@braks/vue-flow'
|
||||
import { Background, Controls, MiniMap, VueFlow, isNode, useVueFlow } from '@braks/vue-flow'
|
||||
|
||||
const elements = ref<Elements>([
|
||||
{ id: '1', type: 'input', label: 'Node 1', position: { x: 250, y: 5 }, class: 'light' },
|
||||
@@ -35,6 +36,7 @@ const logToObject = () => console.log(instance.value?.toObject())
|
||||
const resetTransform = () => instance.value?.setTransform({ x: 0, y: 0, zoom: 1 })
|
||||
const toggleclass = () => elements.value.forEach((el) => (el.class = el.class === 'light' ? 'dark' : 'light'))
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<VueFlow v-model="elements" class="vue-flow-basic-example">
|
||||
<Background />
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
<script lang="ts">
|
||||
import { VueFlow, Background, MiniMap, Controls, Elements, FlowEvents, FlowInstance, isNode, addEdge } from '@braks/vue-flow'
|
||||
import type { Elements, FlowEvents, FlowInstance } from '@braks/vue-flow'
|
||||
import { Background, Controls, MiniMap, VueFlow, addEdge, isNode } from '@braks/vue-flow'
|
||||
|
||||
export default defineComponent({
|
||||
name: 'BasicOptionsAPI',
|
||||
@@ -50,6 +51,7 @@ export default defineComponent({
|
||||
},
|
||||
})
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<VueFlow
|
||||
v-model="elements"
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
<script lang="ts" setup>
|
||||
import { Position, Handle, ValidConnectionFunc } from '@braks/vue-flow'
|
||||
import type { Position, ValidConnectionFunc } from '@braks/vue-flow'
|
||||
import { Handle } from '@braks/vue-flow'
|
||||
|
||||
interface Props {
|
||||
id: string
|
||||
@@ -17,12 +18,14 @@ const props = withDefaults(defineProps<Props>(), {
|
||||
targetPosition: 'top' as Position,
|
||||
})
|
||||
</script>
|
||||
|
||||
<script lang="ts">
|
||||
export default {
|
||||
name: 'ResizableNode',
|
||||
inheritAttrs: false,
|
||||
}
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<Handle
|
||||
type="target"
|
||||
@@ -41,6 +44,7 @@ export default {
|
||||
:is-valid-connection="props.isValidSourcePos"
|
||||
/>
|
||||
</template>
|
||||
|
||||
<style>
|
||||
.resize-node {
|
||||
padding: 1rem;
|
||||
|
||||
Reference in New Issue
Block a user