@riil-frontend/component-topology 2.15.42 → 2.15.43

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -21,9 +21,11 @@ var ColorPicker = /*#__PURE__*/function (_Component) {
21
21
  var _this$props = _this.props,
22
22
  prevValue = _this$props.value,
23
23
  onChange = _this$props.onChange;
24
+ var value = color.hex; // const rgb = color.rgb;
25
+ // const rgba = `rgba(${rgb.r},${rgb.g},${rgb.b},${rgb.a})`
24
26
 
25
- if (prevValue !== color.hex) {
26
- onChange(color.hex);
27
+ if (value !== prevValue) {
28
+ onChange(value);
27
29
  }
28
30
  };
29
31
 
@@ -58,6 +60,7 @@ var ColorPicker = /*#__PURE__*/function (_Component) {
58
60
  }, /*#__PURE__*/React.createElement(SketchPicker, {
59
61
  color: value // width={230}
60
62
  ,
63
+ disableAlpha: true,
61
64
  styles: {
62
65
  'default': {
63
66
  picker: {
@@ -5,7 +5,7 @@ import _Field from "@alifd/next/es/field";
5
5
  import _extends from "@babel/runtime/helpers/extends";
6
6
  import _Collapse from "@alifd/next/es/collapse";
7
7
  import _Select from "@alifd/next/es/select";
8
- import React, { useState, useEffect } from 'react';
8
+ import React, { useEffect } from 'react';
9
9
  import NodeSizeInput from "../../common/NodeSizeInput/NodeSizeInput";
10
10
  import textStyles from "../../../../../common/text.module.scss";
11
11
  import NodeIconSelect from "./NodeIconSelect";
@@ -73,7 +73,7 @@ export default function NodePropertyView(props) {
73
73
  };
74
74
 
75
75
  var handleBindTopoChange = function handleBindTopoChange(value, data) {
76
- // 设置名称为拓扑名称
76
+ // 设置名称为拓扑名称,清空自定义名称
77
77
  node.a('name', data.label);
78
78
  node.a('customName', null);
79
79
  };
@@ -20,7 +20,7 @@ import { updateEdgeExpanded } from "../utils/edgeUtil";
20
20
  import PluginManager from "./PluginManager";
21
21
  import topoFactory from "./topoFactory"; // eslint-disable-next-line no-undef
22
22
 
23
- var version = typeof "2.15.42" === 'string' ? "2.15.42" : null;
23
+ var version = typeof "2.15.43" === 'string' ? "2.15.43" : null;
24
24
  console.info("\u62D3\u6251\u7248\u672C: " + version);
25
25
  /**
26
26
  * 拓扑显示和编辑
@@ -37,9 +37,11 @@ var ColorPicker = /*#__PURE__*/function (_Component) {
37
37
  var _this$props = _this.props,
38
38
  prevValue = _this$props.value,
39
39
  onChange = _this$props.onChange;
40
+ var value = color.hex; // const rgb = color.rgb;
41
+ // const rgba = `rgba(${rgb.r},${rgb.g},${rgb.b},${rgb.a})`
40
42
 
41
- if (prevValue !== color.hex) {
42
- onChange(color.hex);
43
+ if (value !== prevValue) {
44
+ onChange(value);
43
45
  }
44
46
  };
45
47
 
@@ -76,6 +78,7 @@ var ColorPicker = /*#__PURE__*/function (_Component) {
76
78
  }, /*#__PURE__*/_react["default"].createElement(_reactColor.SketchPicker, {
77
79
  color: value // width={230}
78
80
  ,
81
+ disableAlpha: true,
79
82
  styles: {
80
83
  'default': {
81
84
  picker: {
@@ -99,7 +99,7 @@ function NodePropertyView(props) {
99
99
  };
100
100
 
101
101
  var handleBindTopoChange = function handleBindTopoChange(value, data) {
102
- // 设置名称为拓扑名称
102
+ // 设置名称为拓扑名称,清空自定义名称
103
103
  node.a('name', data.label);
104
104
  node.a('customName', null);
105
105
  };
@@ -48,7 +48,7 @@ var _PluginManager = _interopRequireDefault(require("./PluginManager"));
48
48
  var _topoFactory = _interopRequireDefault(require("./topoFactory"));
49
49
 
50
50
  // eslint-disable-next-line no-undef
51
- var version = typeof "2.15.42" === 'string' ? "2.15.42" : null;
51
+ var version = typeof "2.15.43" === 'string' ? "2.15.43" : null;
52
52
  console.info("\u62D3\u6251\u7248\u672C: " + version);
53
53
  /**
54
54
  * 拓扑显示和编辑
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@riil-frontend/component-topology",
3
- "version": "2.15.42",
3
+ "version": "2.15.43",
4
4
  "description": "拓扑",
5
5
  "scripts": {
6
6
  "start": "build-scripts start",
@@ -110,6 +110,6 @@
110
110
  "access": "public"
111
111
  },
112
112
  "license": "MIT",
113
- "homepage": "https://unpkg.com/@riil-frontend/component-topology@2.15.42/build/index.html",
113
+ "homepage": "https://unpkg.com/@riil-frontend/component-topology@2.15.43/build/index.html",
114
114
  "gitHead": "2da19ffccbb7ca60a8acf396e39f542c68bb33f5"
115
115
  }