build-dxf 0.1.111 → 0.1.113

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.
Files changed (120) hide show
  1. package/package.json +1 -1
  2. package/src/build.js +3393 -3257
  3. package/src/{dxfSystem → dxf-system}/components/CorrectionDxf.d.ts +1 -1
  4. package/src/{dxfSystem → dxf-system}/components/Dxf.d.ts +3 -3
  5. package/src/{dxfSystem → dxf-system}/components/ThreeVJia.d.ts +1 -1
  6. package/src/{dxfSystem → dxf-system}/plugins/editor/components/CommandFlow/Default.d.ts +1 -1
  7. package/src/{dxfSystem → dxf-system}/plugins/editor/components/CommandFlow/DrawWindow.d.ts +1 -1
  8. package/src/{dxfSystem → dxf-system}/plugins/editor/components/CommandFlow/PropertiesPanel.d.ts +1 -1
  9. package/src/{dxfSystem → dxf-system}/plugins/editor/components/Editor.d.ts +1 -1
  10. package/src/{dxfSystem → dxf-system}/plugins/editor/components/RenderManager.d.ts +2 -2
  11. package/src/{dxfSystem → dxf-system}/plugins/editor/pages/EditorTool/EditorTool.vue.d.ts +1 -1
  12. package/src/{dxfSystem → dxf-system}/plugins/editor/pages/PropertiesPanel.vue.d.ts +1 -1
  13. package/src/{dxfSystem/utils/linePipeline/builtin/boundExt.d.ts → dxf-system/utils/BoundExt.d.ts} +5 -11
  14. package/src/{dxfSystem/utils/linePipeline/builtin → dxf-system/utils}/DoorFind.d.ts +5 -5
  15. package/src/{dxfSystem/utils/linePipeline/builtin → dxf-system/utils}/DoubleWallHelper.d.ts +3 -3
  16. package/src/{dxfSystem/utils/linePipeline/builtin → dxf-system/utils}/HeightQuery.d.ts +2 -2
  17. package/src/{dxfSystem/utils/threeVJiaPipeline.d.ts → dxf-system/utils/ThreeVJiaPipeline.d.ts} +1 -1
  18. package/src/dxf-system/utils/cad/DxfDataPlugin.d.ts +18 -0
  19. package/src/dxf-system/utils/cad/DxfDrawPlugin.d.ts +13 -0
  20. package/src/{dxfSystem/utils/CAD/drawDxfImage.d.ts → dxf-system/utils/cad/draw-dxf-image.d.ts} +1 -1
  21. package/src/{dxfSystem/utils/CAD/drawDxfString.d.ts → dxf-system/utils/cad/draw-dxf-string.d.ts} +1 -1
  22. package/src/{dxfSystem/utils/CAD → dxf-system/utils/cad}/index.d.ts +1 -27
  23. package/src/dxf-system/utils/index.d.ts +11 -0
  24. package/src/dxf-system/utils/line-pipeline/builtin/bound-ext.d.ts +8 -0
  25. package/src/{dxfSystem/utils/linePipeline/builtin/buildGroup → dxf-system/utils/line-pipeline/builtin/build-group}/index.d.ts +1 -1
  26. package/src/{dxfSystem/utils/linePipeline/builtin/doorToHole.d.ts → dxf-system/utils/line-pipeline/builtin/door-to-hole.d.ts} +1 -1
  27. package/src/{dxfSystem/utils/linePipeline/builtin/doubleWallAlignment.d.ts → dxf-system/utils/line-pipeline/builtin/double-wall-alignment.d.ts} +2 -2
  28. package/src/{dxfSystem/utils/linePipeline → dxf-system/utils/line-pipeline}/builtin/index.d.ts +7 -7
  29. package/src/{dxfSystem/utils/linePipeline → dxf-system/utils/line-pipeline}/builtin/init.d.ts +1 -1
  30. package/src/dxf-system/utils/line-pipeline/index.d.ts +20 -0
  31. package/src/{dxfSystem → dxf-system}/utils/tools.d.ts +1 -1
  32. package/src/index.css +50 -22
  33. package/src/index3.js +8 -8
  34. package/src/utils/algorithms/LineSegmentUtils.d.ts +15 -2
  35. package/src/utils/algorithms/PointSpatialHash.d.ts +21 -4
  36. package/src/utils/decorators/measure-time.d.ts +5 -0
  37. package/src/utils/index.d.ts +3 -3
  38. package/src/utils/modelScenario/scenario.d.ts +1 -1
  39. package/src/dxfSystem/utils/WallDrawManager.d.ts +0 -3
  40. package/src/dxfSystem/utils/index.d.ts +0 -11
  41. package/src/dxfSystem/utils/linePipeline/index.d.ts +0 -20
  42. /package/src/{dxfSystem → dxf-system}/DxfSystem.d.ts +0 -0
  43. /package/src/{dxfSystem → dxf-system}/build.d.ts +0 -0
  44. /package/src/{dxfSystem → dxf-system}/components/Variable.d.ts +0 -0
  45. /package/src/{dxfSystem → dxf-system}/index.d.ts +0 -0
  46. /package/src/{dxfSystem → dxf-system}/plugins/editor/EditorPlugin.d.ts +0 -0
  47. /package/src/{dxfSystem → dxf-system}/plugins/editor/components/CommandFlow/CFComponent.d.ts +0 -0
  48. /package/src/{dxfSystem → dxf-system}/plugins/editor/components/CommandFlow/ClippingLine.d.ts +0 -0
  49. /package/src/{dxfSystem → dxf-system}/plugins/editor/components/CommandFlow/DeleteSelectLine.d.ts +0 -0
  50. /package/src/{dxfSystem → dxf-system}/plugins/editor/components/CommandFlow/DrawDoorLine.d.ts +0 -0
  51. /package/src/{dxfSystem → dxf-system}/plugins/editor/components/CommandFlow/DrawLine.d.ts +0 -0
  52. /package/src/{dxfSystem → dxf-system}/plugins/editor/components/CommandFlow/ManualDistance.d.ts +0 -0
  53. /package/src/{dxfSystem → dxf-system}/plugins/editor/components/CommandFlow/MergeLine.d.ts +0 -0
  54. /package/src/{dxfSystem → dxf-system}/plugins/editor/components/CommandFlow/PointDrag/index.d.ts +0 -0
  55. /package/src/{dxfSystem → dxf-system}/plugins/editor/components/CommandFlow/PointDrag/modifyDoor.d.ts +0 -0
  56. /package/src/{dxfSystem → dxf-system}/plugins/editor/components/CommandFlow/PointDrag/modifyLine.d.ts +0 -0
  57. /package/src/{dxfSystem → dxf-system}/plugins/editor/components/CommandFlow/PointDrag/modifyWindow.d.ts +0 -0
  58. /package/src/{dxfSystem → dxf-system}/plugins/editor/components/CommandFlow/RayDistance.d.ts +0 -0
  59. /package/src/{dxfSystem → dxf-system}/plugins/editor/components/CommandFlow/SelectAll.d.ts +0 -0
  60. /package/src/{dxfSystem → dxf-system}/plugins/editor/components/CommandFlow/TwoLineConnectionLine.d.ts +0 -0
  61. /package/src/{dxfSystem → dxf-system}/plugins/editor/components/CommandFlow/TwoPointConnection.d.ts +0 -0
  62. /package/src/{dxfSystem → dxf-system}/plugins/editor/components/CommandFlow/VerticalCorr.d.ts +0 -0
  63. /package/src/{dxfSystem → dxf-system}/plugins/editor/components/CommandFlow/VerticalCorrContinue.d.ts +0 -0
  64. /package/src/{dxfSystem → dxf-system}/plugins/editor/components/CommandFlow/VerticalReferenceLine.d.ts +0 -0
  65. /package/src/{dxfSystem → dxf-system}/plugins/editor/components/CommandFlow/ViewAngle.d.ts +0 -0
  66. /package/src/{dxfSystem → dxf-system}/plugins/editor/components/UIService.d.ts +0 -0
  67. /package/src/{dxfSystem → dxf-system}/plugins/editor/components/index.d.ts +0 -0
  68. /package/src/{dxfSystem → dxf-system}/plugins/editor/index.d.ts +0 -0
  69. /package/src/{dxfSystem → dxf-system}/plugins/editor/pages/EditorTool/EditorToolContent.vue.d.ts +0 -0
  70. /package/src/{dxfSystem → dxf-system}/plugins/editor/pages/components/Input.vue.d.ts +0 -0
  71. /package/src/{dxfSystem → dxf-system}/plugins/editor/type.d.ts +0 -0
  72. /package/src/{dxfSystem → dxf-system}/plugins/index.d.ts +0 -0
  73. /package/src/{dxfSystem → dxf-system}/plugins/model3d/components/DxfLineModel.d.ts +0 -0
  74. /package/src/{dxfSystem → dxf-system}/plugins/model3d/components/WhiteModel.d.ts +0 -0
  75. /package/src/{dxfSystem → dxf-system}/plugins/model3d/components/index.d.ts +0 -0
  76. /package/src/{dxfSystem → dxf-system}/plugins/model3d/index.d.ts +0 -0
  77. /package/src/{dxfSystem → dxf-system}/plugins/renderer/components/DomContainer.d.ts +0 -0
  78. /package/src/{dxfSystem → dxf-system}/plugins/renderer/components/DomEventRegister.d.ts +0 -0
  79. /package/src/{dxfSystem → dxf-system}/plugins/renderer/components/EventInput.d.ts +0 -0
  80. /package/src/{dxfSystem → dxf-system}/plugins/renderer/components/ModelDataRender.d.ts +0 -0
  81. /package/src/{dxfSystem → dxf-system}/plugins/renderer/components/Renderer.d.ts +0 -0
  82. /package/src/{dxfSystem → dxf-system}/plugins/renderer/components/index.d.ts +0 -0
  83. /package/src/{dxfSystem → dxf-system}/plugins/renderer/index.d.ts +0 -0
  84. /package/src/{dxfSystem → dxf-system}/type.d.ts +0 -0
  85. /package/src/{dxfSystem → dxf-system}/utils/BayWindowHelper.d.ts +0 -0
  86. /package/src/{dxfSystem → dxf-system}/utils/LineGroupType.d.ts +0 -0
  87. /package/src/{dxfSystem → dxf-system}/utils/LoadModel.d.ts +0 -0
  88. /package/src/{dxfSystem → dxf-system}/utils/SceneAutoGenerat.d.ts +0 -0
  89. /package/src/{dxfSystem → dxf-system}/utils/WallGroupManager.d.ts +0 -0
  90. /package/src/{dxfSystem → dxf-system}/utils/WallInsertObject.d.ts +0 -0
  91. /package/src/{dxfSystem → dxf-system}/utils/WallInsertObjectDrawData.d.ts +0 -0
  92. /package/src/{dxfSystem → dxf-system}/utils/ZHouseMockData.d.ts +0 -0
  93. /package/src/{dxfSystem/utils/CAD/drawData.d.ts → dxf-system/utils/cad/draw-data.d.ts} +0 -0
  94. /package/src/{dxfSystem/utils/clippingDoubleWall.d.ts → dxf-system/utils/clipping-double-wall.d.ts} +0 -0
  95. /package/src/{dxfSystem/utils/clippingLineUserData.d.ts → dxf-system/utils/clipping-line-user-data.d.ts} +0 -0
  96. /package/src/{dxfSystem/utils/drawHelper.d.ts → dxf-system/utils/draw-helper.d.ts} +0 -0
  97. /package/src/{dxfSystem/utils/findDiscrete.d.ts → dxf-system/utils/find-discrete.d.ts} +0 -0
  98. /package/src/{dxfSystem/utils/findRooms.d.ts → dxf-system/utils/find-rooms.d.ts} +0 -0
  99. /package/src/{dxfSystem/utils/getWinDrawData.d.ts → dxf-system/utils/get-win-draw-data.d.ts} +0 -0
  100. /package/src/{dxfSystem/utils/lineSegmentClipping.d.ts → dxf-system/utils/line-clipping.d.ts} +0 -0
  101. /package/src/{dxfSystem/utils/mergeChains.d.ts → dxf-system/utils/line-merge-chains.d.ts} +0 -0
  102. /package/src/{dxfSystem/utils/mergeLineUserData.d.ts → dxf-system/utils/line-merge-user-data.d.ts} +0 -0
  103. /package/src/{dxfSystem/utils/linePipeline/builtin/axisAlignCorr.d.ts → dxf-system/utils/line-pipeline/builtin/axis-align-corr.d.ts} +0 -0
  104. /package/src/{dxfSystem/utils/linePipeline/builtin/buildGroup/bayWindow.d.ts → dxf-system/utils/line-pipeline/builtin/build-group/bay-window.d.ts} +0 -0
  105. /package/src/{dxfSystem/utils/linePipeline/builtin/buildGroup/doubleWall.d.ts → dxf-system/utils/line-pipeline/builtin/build-group/double-wall.d.ts} +0 -0
  106. /package/src/{dxfSystem/utils/linePipeline/builtin/doorSpaceHandle.d.ts → dxf-system/utils/line-pipeline/builtin/door-space-handle.d.ts} +0 -0
  107. /package/src/{dxfSystem/utils/linePipeline/builtin/removeShortDoubleWall.d.ts → dxf-system/utils/line-pipeline/builtin/remove-short-double-wall.d.ts} +0 -0
  108. /package/src/{dxfSystem/utils/linePipeline/builtin/wallHeightHandle.d.ts → dxf-system/utils/line-pipeline/builtin/wall-height-handle.d.ts} +0 -0
  109. /package/src/{dxfSystem/utils/removeDangline.d.ts → dxf-system/utils/remove-dangline.d.ts} +0 -0
  110. /package/src/utils/{tools → algorithms}/lazy.d.ts +0 -0
  111. /package/src/utils/{threeObject3D → three-object-3d}/ExtrudeMesh.d.ts +0 -0
  112. /package/src/utils/{threeObject3D → three-object-3d}/Lines.d.ts +0 -0
  113. /package/src/utils/{threeObject3D → three-object-3d}/Lines2.d.ts +0 -0
  114. /package/src/utils/tools/{cloneUserData.d.ts → clone-user-data.d.ts} +0 -0
  115. /package/src/utils/tools/{createHtml.d.ts → create-html.d.ts} +0 -0
  116. /package/src/utils/tools/{createPromise.d.ts → create-promise.d.ts} +0 -0
  117. /package/src/utils/tools/{getJson.d.ts → get-json.d.ts} +0 -0
  118. /package/src/utils/tools/{isMobile.d.ts → is-mobile.d.ts} +0 -0
  119. /package/src/utils/tools/{repetitiveTask.d.ts → repetitive-task.d.ts} +0 -0
  120. /package/src/utils/tools/{selectLocalFile.d.ts → selectLocal-file.d.ts} +0 -0
@@ -18,11 +18,19 @@ export declare class LineSegmentUtils {
18
18
  * @param lines
19
19
  */
20
20
  static getLinesCenter(lines: LineSegment[]): Point<Record<string, any>>;
21
+ /** 合并分组和处理
22
+ * @param groups
23
+ * @returns
24
+ */
25
+ static GroupBuilder<T = any, K extends PropertyKey = string>(groups: Partial<Record<K, LineSegment<T>[]>>): {
26
+ handle(k: K, fn: (lines: LineSegment<T>[]) => LineSegment<T>[]): /*elided*/ any;
27
+ merge(): LineSegment<T>[];
28
+ };
21
29
  /** 自定义分组
22
30
  * @param lines
23
31
  * @returns
24
32
  */
25
- static group<T = any, K extends string | number | symbol = string>(lines: LineSegment<T>[], callBackFun: (line: LineSegment<T>) => K): Partial<Record<K, LineSegment<T>[]>>;
33
+ static group<T = any, K extends PropertyKey = string>(lines: LineSegment<T>[], fn: (line: LineSegment<T>) => K): Partial<Record<K, LineSegment<T>[]>>;
26
34
  /** 通过在同一路径上且平行的线段分组
27
35
  * @param lines
28
36
  */
@@ -113,7 +121,7 @@ export declare class LineSegmentUtils {
113
121
  * @returns
114
122
  */
115
123
  static flatPoints(lines: LineSegment[] | LineSegment): any[];
116
- static resolveIntersection<T>(lines: LineSegment[], onClip?: (target: LineSegment<T>, newLines: LineSegment<T>[]) => void): LineSegment<T>[];
124
+ static splitIntersections<T>(lines: LineSegment[], onClip?: (target: LineSegment<T>, newLines: LineSegment<T>[]) => void): LineSegment<T>[];
117
125
  /** 对线段组统计,找到主导方向线
118
126
  * @param lineSegments
119
127
  * @returns
@@ -127,4 +135,9 @@ export declare class LineSegmentUtils {
127
135
  readonly modify: () => void;
128
136
  clear(): void;
129
137
  };
138
+ /** 转为虚线
139
+ * @param line
140
+ * @param pattern
141
+ */
142
+ static dash(line: LineSegment, pattern: number[]): LineSegment<Record<string, any>>[];
130
143
  }
@@ -37,9 +37,9 @@ export declare class PointSpatialHash<T = Record<string, any>> {
37
37
  */
38
38
  remove(point: Point): this;
39
39
  /** 移除点
40
- * @param point
40
+ * @param points
41
41
  */
42
- removes(point: Point[]): this;
42
+ removes(points: Point[]): this;
43
43
  update(point: Point): boolean;
44
44
  updates(point: Point[]): void;
45
45
  /**
@@ -53,6 +53,14 @@ export declare class PointSpatialHash<T = Record<string, any>> {
53
53
  * 清空所有数据
54
54
  */
55
55
  clear(): void;
56
+ /** 遍历网格
57
+ * @param minI
58
+ * @param maxI
59
+ * @param minJ
60
+ * @param maxJ
61
+ * @param callback
62
+ */
63
+ private forEachGrid;
56
64
  /**
57
65
  * 查询与矩形相交的点
58
66
  * @param rectangle 矩形
@@ -83,7 +91,12 @@ export declare class PointSpatialHash<T = Record<string, any>> {
83
91
  * @param point
84
92
  */
85
93
  queryPoint(point: Point, excludeOneself?: boolean): PvgList<T>;
86
- queryPoints(points: Point[], excludeOneself?: boolean): Target<T>[];
94
+ /** 批量查询点
95
+ * @param points
96
+ * @param excludeOneself
97
+ * @returns
98
+ */
99
+ queryPoints(points: Point[], excludeOneself?: boolean): PvgList<T>;
87
100
  /** 获取多边形内的点
88
101
  * @param polygon
89
102
  */
@@ -99,6 +112,10 @@ export declare class PointSpatialHash<T = Record<string, any>> {
99
112
  point: Point;
100
113
  userData: T;
101
114
  } | null;
115
+ /** 通过点,从近到远辐射查找,同一格子,不保证远近
116
+ * 返回第一个满足条件的目标
117
+ */
118
+ nearestSearch(point: Point, fn: (target: Target<T>) => boolean, maxRing?: number): Target<T> | null;
102
119
  /**
103
120
  * @param point
104
121
  */
@@ -113,7 +130,7 @@ export declare class PointSpatialHash<T = Record<string, any>> {
113
130
  * @param lines
114
131
  * @returns
115
132
  */
116
- static from(points: Point[]): PointSpatialHash<number>;
133
+ static from(points: Point[], gridSize?: number): PointSpatialHash<number>;
117
134
  /** 通过线段快速创建
118
135
  * @param lines
119
136
  * @returns
@@ -0,0 +1,5 @@
1
+ /**
2
+ * 老版 TypeScript 装饰器(experimentalDecorators)
3
+ * 打印函数执行耗时
4
+ */
5
+ export declare function MeasureTime(): (target: any, propertyKey: string, descriptor: PropertyDescriptor) => PropertyDescriptor;
@@ -2,7 +2,7 @@ export * from './algorithms/Box2';
2
2
  export * from './algorithms/LineIndexGenerator';
3
3
  export * from './algorithms/LineSegment';
4
4
  export * from './algorithms/LineSegmentUtils';
5
- export * from './threeObject3D/Lines';
5
+ export * from './three-object-3d/Lines';
6
6
  export * from './algorithms/Map';
7
7
  export * from './algorithms/Point';
8
8
  export * from './algorithms/PointUtils';
@@ -11,8 +11,8 @@ export * from './algorithms/Quadtree';
11
11
  export * from './algorithms/Rectangle';
12
12
  export * from './algorithms/UndirectedGraph';
13
13
  export * from './algorithms/UnionFindSet';
14
- export * from './tools/cloneUserData';
15
- export * from './tools/selectLocalFile';
14
+ export * from './tools/clone-user-data';
15
+ export * from './tools/selectLocal-file';
16
16
  export * from './algorithms/PointSpatialHash';
17
17
  export * from './command';
18
18
  export * from './ecs';
@@ -1,6 +1,6 @@
1
1
  import { OrbitControls } from 'three/examples/jsm/controls/OrbitControls.js';
2
2
  import { LineSegment } from '../algorithms/LineSegment';
3
- import { LineUserData } from '../../dxfSystem/type';
3
+ import { LineUserData } from '../../dxf-system/type';
4
4
  import { Brush } from 'three-bvh-csg';
5
5
  import { Point } from '../algorithms/Point';
6
6
  import * as THREE from 'three';
@@ -1,3 +0,0 @@
1
- export declare class WallDrawManager {
2
- constructor();
3
- }
@@ -1,11 +0,0 @@
1
- export * from './lineSegmentClipping';
2
- export * from './linePipeline/builtin/DoubleWallHelper';
3
- export * from './clippingDoubleWall';
4
- export * from './clippingLineUserData';
5
- export * from './findDiscrete';
6
- export * from './mergeLineUserData';
7
- export * from './LineGroupType';
8
- export * from './SceneAutoGenerat';
9
- export * from './threeVJiaPipeline';
10
- export { BoundExt } from './linePipeline/builtin/boundExt';
11
- export * as tools from './tools';
@@ -1,20 +0,0 @@
1
- import { LineSegment } from '../../../utils/algorithms/LineSegment';
2
- import { Pipeline } from '../../../utils/algorithms/Pipeline';
3
- import { LineUserData, SetDataOption } from '../../type';
4
- export declare class LinePipeline<T = SetDataOption> extends Pipeline<LineSegment[], T> {
5
- static get builtin(): {
6
- init: typeof import('./builtin/init').init;
7
- DoorToHole: typeof import('./builtin/doorToHole').doorToHole;
8
- AxisAlignCorr: typeof import('./builtin/axisAlignCorr').axisAlignCorr;
9
- DoorFind: (lines: LineSegment[]) => LineSegment<Record<string, any>>[];
10
- BoundExt: typeof import('./builtin/boundExt').boundExt;
11
- DoubleWallAlignment: typeof import('./builtin/doubleWallAlignment').doubleWallAlignment;
12
- WallHeightHandle: typeof import('./builtin/wallHeightHandle').wallHeightHandle;
13
- DoorSpaceHandle: typeof import('./builtin/doorSpaceHandle').doorSpaceHandle;
14
- RemoveShortDoubleWall: typeof import('./builtin/removeShortDoubleWall').removeShortDoubleWall;
15
- };
16
- constructor();
17
- add(handle: (lines: LineSegment<LineUserData>[], option: T) => LineSegment<LineUserData>[]): this;
18
- clear(): this;
19
- execute(data: LineSegment<Record<string, any>>[], option: T): LineSegment<Record<string, any>>[];
20
- }
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes