mxcad-app 1.0.58 → 1.0.59

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.
Binary file
Binary file
package/dist/index.cjs.gz CHANGED
Binary file
package/dist/index.d.ts CHANGED
@@ -239,10 +239,16 @@ declare module '@tiptap/core' {
239
239
 
240
240
  declare module '@tiptap/core' {
241
241
  interface Commands<ReturnType> {
242
- Underline: {
243
- setUnderline: () => ReturnType;
244
- unsetUnderline: () => ReturnType;
245
- toggleUnderline: () => ReturnType;
242
+ Overline: {
243
+ /**
244
+ * Set the font size attribute
245
+ */
246
+ setOverline: () => ReturnType;
247
+ /**
248
+ * Unset the font size attribute
249
+ */
250
+ unsetOverline: () => ReturnType;
251
+ toggleOverline: () => ReturnType;
246
252
  };
247
253
  }
248
254
  }
@@ -250,16 +256,15 @@ declare module '@tiptap/core' {
250
256
 
251
257
  declare module '@tiptap/core' {
252
258
  interface Commands<ReturnType> {
253
- Overline: {
259
+ fontSize: {
254
260
  /**
255
261
  * Set the font size attribute
256
262
  */
257
- setOverline: () => ReturnType;
263
+ setFontSize: (size: string) => ReturnType;
258
264
  /**
259
265
  * Unset the font size attribute
260
266
  */
261
- unsetOverline: () => ReturnType;
262
- toggleOverline: () => ReturnType;
267
+ unsetFontSize: () => ReturnType;
263
268
  };
264
269
  }
265
270
  }
@@ -293,15 +298,10 @@ declare module "@tiptap/core" {
293
298
 
294
299
  declare module '@tiptap/core' {
295
300
  interface Commands<ReturnType> {
296
- fontSize: {
297
- /**
298
- * Set the font size attribute
299
- */
300
- setFontSize: (size: string) => ReturnType;
301
- /**
302
- * Unset the font size attribute
303
- */
304
- unsetFontSize: () => ReturnType;
301
+ Underline: {
302
+ setUnderline: () => ReturnType;
303
+ unsetUnderline: () => ReturnType;
304
+ toggleUnderline: () => ReturnType;
305
305
  };
306
306
  }
307
307
  }
Binary file
package/dist/mxcad.d.ts CHANGED
@@ -12945,6 +12945,27 @@ declare module "mxcad" {
12945
12945
  * ```
12946
12946
  */
12947
12947
  loadImage(imageUrl: string, call: (image: any) => void, imageFileName?: string, fileType?: string): void;
12948
+ /**
12949
+ * 加载Base64图片。
12950
+ * @param imageUrl 图片路径
12951
+ * @param call 回调函数
12952
+ * @example
12953
+ * ```ts
12954
+ import { MxCpp, McObject } from "mxcad"
12955
+ const mxcad: McObject = MxCpp.getCurrentMxCAD()
12956
+ mxcad.loadImage(imagUrl, (image) => {
12957
+ if (!image) {
12958
+ console.log("loadImage failed");
12959
+ return;
12960
+ }
12961
+ let width = mxcad.mxdraw.viewCoordLong2Cad(100);
12962
+ let height = (image.height / image.width) * width;
12963
+ idImage = mxcad.drawImage((pt as any).x, (pt as any).y, width, height, 0, imagUrl,true);
12964
+ mxcad.updateDisplay();
12965
+ });
12966
+ * ```
12967
+ */
12968
+ loadImageBase64(sImageBase64: string, imageFileName: string, call: (image: any) => void): void;
12948
12969
  /**
12949
12970
  * 绘制一个图片
12950
12971
  * @param dPosX 图片 X 坐标
@@ -13361,6 +13382,10 @@ declare module "mxcad" {
13361
13382
  * 得到当前布局ID
13362
13383
  */
13363
13384
  getCurrentLayoutId(): McObjectId;
13385
+ /**
13386
+ * 得到当前openWebFile打开的文件,的文件名,如果打开是一个流数据,该变量会取服务器返回请求头的filename的值。
13387
+ */
13388
+ GetDocumentFileName(): string;
13364
13389
  /**
13365
13390
  * 返加MxCpp对象,它会在MxDraw模块中调用。
13366
13391
  */
package/dist/mxdraw.d.ts CHANGED
@@ -1030,7 +1030,7 @@ declare module "mxdraw" {
1030
1030
  msCmdTip: string;
1031
1031
  msCmdDisplay: string;
1032
1032
  msCmdText: string;
1033
- }) => void) | undefined;
1033
+ }) => void) | undefined | Array<any>;
1034
1034
  mxFunObject: undefined;
1035
1035
  mountUpDisplayFun: (fun: ((data: {
1036
1036
  msCmdTip: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "mxcad-app",
3
- "version": "1.0.58",
3
+ "version": "1.0.59",
4
4
  "main": "./dist/index.cjs",
5
5
  "module": "./dist/index.js",
6
6
  "types": "./dist/index.d.ts",