xctc-utils 1.6.48 → 1.6.49
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.
- package/dist/canvas/index.js +9 -7
- package/package.json +1 -1
package/dist/canvas/index.js
CHANGED
|
@@ -392,8 +392,13 @@ var CanvasHooks = /** @class */ (function () {
|
|
|
392
392
|
// 注册鼠标移动事件
|
|
393
393
|
CanvasHooks.prototype.registerMouseMoveEventFn = function (options) {
|
|
394
394
|
var _ = this;
|
|
395
|
+
// 监听鼠标是否在画布范围内移动
|
|
396
|
+
var pointer = _.canvasDataSource.getPointer(options.e);
|
|
397
|
+
var inRange = pointer.x >= 0 && pointer.x <= _.canvasDataSource.width &&
|
|
398
|
+
pointer.y >= 0 && pointer.y <= _.canvasDataSource.height;
|
|
399
|
+
_.mouseCanvasInRangeStatus = inRange;
|
|
395
400
|
// 鼠标不在画布内,终止行为
|
|
396
|
-
if (!
|
|
401
|
+
if (!inRange) {
|
|
397
402
|
return;
|
|
398
403
|
}
|
|
399
404
|
var activeTarget = options.target || options.activeTarget;
|
|
@@ -861,12 +866,9 @@ var CanvasHooks = /** @class */ (function () {
|
|
|
861
866
|
element.style.backgroundColor = "#fff";
|
|
862
867
|
element.style.color = "#333";
|
|
863
868
|
}
|
|
864
|
-
|
|
865
|
-
|
|
866
|
-
|
|
867
|
-
this.style.color = '#fff';
|
|
868
|
-
// @ts-ignore
|
|
869
|
-
this.style.fontWeight = "bold";
|
|
869
|
+
liItem.style.backgroundColor = '#0AC496';
|
|
870
|
+
liItem.style.color = '#fff';
|
|
871
|
+
liItem.style.fontWeight = "bold";
|
|
870
872
|
});
|
|
871
873
|
ulBox_1.appendChild(liItem);
|
|
872
874
|
});
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "xctc-utils",
|
|
3
|
-
"version": "1.6.
|
|
3
|
+
"version": "1.6.49",
|
|
4
4
|
"description": "localStorage存储\r ```\r sessionStorage存储\r ```\r crypto-js加密、解密\r ```\r 微信授权登录、微信分享\r ```\r 设备环境获取\r ```\r 是否是微信浏览器\r ```\r 时间戳转时间,字符串转时间戳",
|
|
5
5
|
"main": "./dist/index.js",
|
|
6
6
|
"types": "./dist/index.d.ts",
|