chore: lint files

This commit is contained in:
Braks
2022-05-11 22:10:40 +02:00
parent 447d24c5a8
commit 22845c210d
133 changed files with 461 additions and 381 deletions
+5 -2
View File
@@ -1,10 +1,11 @@
<script lang="ts" setup>
import { templateRef } from '@vueuse/core'
import type { Elements, FlowInstance } from '@braks/vue-flow'
import { VueFlow } from '@braks/vue-flow'
import RGBNode from './RGBNode.vue'
import RGBOutputNode from './RGBOutputNode.vue'
import { Elements, FlowInstance, VueFlow } from '@braks/vue-flow'
type Colors = {
interface Colors {
red: number
green: number
blue: number
@@ -31,6 +32,7 @@ const color = ref<Colors>({
})
const onChange = ({ color: c, val }: { color: keyof Colors; val: number }) => (color.value[c] = Number(val))
</script>
<template>
<div ref="page" class="demo-flow">
<VueFlow v-model="elements" @pane-ready="onLoad">
@@ -43,6 +45,7 @@ const onChange = ({ color: c, val }: { color: keyof Colors; val: number }) => (c
</VueFlow>
</div>
</template>
<style>
.demo-flow {
display: flex;
+5 -2
View File
@@ -1,6 +1,7 @@
<script lang="ts" setup>
import { CSSProperties } from 'vue'
import { Handle, NodeProps, Position } from '@braks/vue-flow'
import type { CSSProperties } from 'vue'
import type { NodeProps } from '@braks/vue-flow'
import { Handle, Position } from '@braks/vue-flow'
interface RGBNodeProps extends NodeProps {
data: {
@@ -37,6 +38,7 @@ const colorVal = computed({
const style = { '--color': color } as CSSProperties
</script>
<template>
<div class="wrapper">
<div class="text-md" :style="{ color }">{{ `${color} Amount`.toUpperCase() }}</div>
@@ -44,6 +46,7 @@ const style = { '--color': color } as CSSProperties
<Handle type="source" :position="Position.Right" :style="{ backgroundColor: color }" />
</div>
</template>
<style>
.wrapper {
padding: 16px;
+4 -1
View File
@@ -1,5 +1,6 @@
<script lang="ts" setup>
import { Handle, NodeProps, Position } from '@braks/vue-flow'
import type { NodeProps } from '@braks/vue-flow'
import { Handle, Position } from '@braks/vue-flow'
interface RBGOutputNodeProps extends NodeProps {
rgb: string
@@ -7,12 +8,14 @@ interface RBGOutputNodeProps extends NodeProps {
const props = defineProps<RBGOutputNodeProps>()
</script>
<template>
<div :style="{ backgroundColor: props.rgb }" class="rgb-output-node">
<div class="text-md uppercase">{{ props.rgb }}</div>
<Handle type="target" :position="Position.Left" />
</div>
</template>
<style>
.rgb-output-node {
padding: 9px;