antv-X6-Vue3总结03-Vue节点配置

部分源代码:https://gitee.com/eadela/x6-example.git

channelReferral.vue 节点组件

<template>
  <!-- 多波次 -->
  <div class="node-box">
    <Icon type="cancel-questionnaire" class="icon" />
    <p> 渠道转介 </p>

    <div class="child">
      <Button type="text" @click="edit">
        编辑
      </Button>
      <Button type="text" @click="del" class="m-l-1">
        删除
      </Button>
    </div>
  </div>
</template>

<script lang="ts" setup>
/*eslint-disable */
import { Icon, Button } from '@bairong/uxd-ui'
import { defineProps } from 'vue'

const props = defineProps({
  icon: {
    type: String
    // required: true
  },
  text: {
    type: String
    // required: true
  }
})

defineExpose({
  ...props
})

const edit = () => {
  console.log(123123)
}
const del = () => {
  console.log(456456)
}

/*eslint-disable */
</script>

<style scoped lang="less">
.child {
  width: 150px;
  min-height: 100px;
  background: #fff;
  position: absolute;
  left: 60px;
  top: 0;
  display: none;
}
.node-box {
  width: 64px;
  height: 64px;
  border: 1px solid #136fff;
  border-radius: 5px;
  background: #fff;
  text-align: center;
  padding-top: 6px;
  position: relative;
  &:hover {
    background: #136fff;
    color: #fff;
    .child {
      // display: block;
      color: #000;
    }
    .icon {
      color: #fff;
    }
  }
  .icon {
    font-size: 22px;
    color: #136fff;
  }
}
</style>

常量

// 所有节点组
export const ShapeComs = {
  HEEL_NODE: 'HeelNode', // 客群筛选
  SEC_SCREENING: 'SecScreening', // 二次筛选
  SEC_CREATE: 'SecCreate', // 二次筛选裂变产生 -- 特殊节点
  AB_TEST: 'AbTest', // AB测试
  AB_CREATE: 'AbCreate', // AB测试裂变产生  -- 特殊节点
  EXTERNAL_DATA: 'ExternalData', // 外部数据
  FINANCIAL_MANAGER: 'FinancialManager', // 理财经理
  MANUAL_OUTBOUND_CALL: 'ManualOutboundCall', // 人工外呼
  SHORT_MESSAGE
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

eadela

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值