@das-fed/utils 6.4.0-test.10 → 6.4.0-test.11

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.
@@ -0,0 +1 @@
1
+ export declare const calcTextWidth: (text: string, fontSize: number) => any;
@@ -0,0 +1,10 @@
1
+ const n = (t, i) => {
2
+ if (!t) return 0;
3
+ var e = document.createElement("div");
4
+ e.style.visibility = "hidden", e.style.whiteSpace = "pre", e.style.display = "inline-block", e.style.fontSize = i + "px", e.textContent = t, document.body.appendChild(e);
5
+ var d = e.offsetWidth;
6
+ return document.body.removeChild(e), d;
7
+ };
8
+ export {
9
+ n as calcTextWidth
10
+ };
@@ -10,3 +10,4 @@ export * from '@das-fed/utils/common-tools/platform-tools';
10
10
  export * from '@das-fed/utils/common-tools/update-fav-icon';
11
11
  export * from '@das-fed/utils/common-tools/update-browser-title';
12
12
  export * from '@das-fed/utils/common-tools/extract-file-name';
13
+ export * from '@das-fed/utils/common-tools/calc-text-width';
@@ -10,3 +10,4 @@ export * from "@das-fed/utils/common-tools/platform-tools";
10
10
  export * from "@das-fed/utils/common-tools/update-fav-icon";
11
11
  export * from "@das-fed/utils/common-tools/update-browser-title";
12
12
  export * from "@das-fed/utils/common-tools/extract-file-name";
13
+ export * from "@das-fed/utils/common-tools/calc-text-width";
@@ -1,6 +1,6 @@
1
1
  import { Directive } from 'vue';
2
2
 
3
3
  /**
4
- * 指令:鼠标移入移除dom事件
4
+ * 指令:鼠标移入移出dom事件
5
5
  */
6
6
  export declare const vHoverInside: Directive<HTMLElement>;
package/esm-map.json CHANGED
@@ -139,5 +139,6 @@
139
139
  "setBrowseTitle": "/common-tools/update-browser-title/index",
140
140
  "getPersonalConfig": "/common-info/index",
141
141
  "getProjectMessage": "/common-info/index",
142
- "analyApi": "/api-services/modules/iot/index"
142
+ "analyApi": "/api-services/modules/iot/index",
143
+ "calcTextWidth": "/common-tools/calc-text-width/index"
143
144
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@das-fed/utils",
3
- "version": "6.4.0-test.10",
3
+ "version": "6.4.0-test.11",
4
4
  "description": "",
5
5
  "type": "module",
6
6
  "main": "./index.js",
@@ -9,7 +9,7 @@
9
9
  "license": "ISC",
10
10
  "dependencies": {
11
11
  "@antv/x6": "^2.18.1",
12
- "@das-fed/utils": "6.4.0-test.10",
12
+ "@das-fed/utils": "6.4.0-test.11",
13
13
  "@vue/shared": "^3.4.21",
14
14
  "@vueuse/core": "^9.6.0",
15
15
  "axios": "^1.6.7",
@@ -21,8 +21,8 @@
21
21
  "vue": "^3.4.21"
22
22
  },
23
23
  "devDependencies": {
24
- "@das-fed/cli": "6.4.0-test.10",
25
- "@das-fed/web": "6.4.0-test.10",
24
+ "@das-fed/cli": "6.4.0-test.11",
25
+ "@das-fed/web": "6.4.0-test.11",
26
26
  "@types/js-cookie": "^3.0.6",
27
27
  "@types/lodash-es": "^4.17.12",
28
28
  "@types/qs": "^6.9.15",