@buerli.io/react-cad 1.0.0 → 1.0.1-beta.1

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 (385) hide show
  1. package/README.md +1 -1
  2. package/build/components/UI/CAD/Constraints.d.ts +12 -12
  3. package/build/components/UI/CAD/Drawing.d.ts +16 -16
  4. package/build/components/UI/CAD/ListPlaceholder.d.ts +2 -2
  5. package/build/components/UI/CAD/Messages/Message.d.ts +5 -5
  6. package/build/components/UI/CAD/Messages/Messages.d.ts +9 -9
  7. package/build/components/UI/CAD/Messages/index.d.ts +1 -1
  8. package/build/components/UI/CAD/Messages/msgStore.d.ts +18 -18
  9. package/build/components/UI/CAD/ModelTree/AssemblyNode.d.ts +10 -10
  10. package/build/components/UI/CAD/ModelTree/FeatureList/Feature.d.ts +7 -7
  11. package/build/components/UI/CAD/ModelTree/FeatureList/FeatureList.d.ts +5 -5
  12. package/build/components/UI/CAD/ModelTree/FeatureList/index.d.ts +1 -1
  13. package/build/components/UI/CAD/ModelTree/FeatureList/utils.d.ts +7 -7
  14. package/build/components/UI/CAD/ModelTree/ModelTree.d.ts +13 -13
  15. package/build/components/UI/CAD/ModelTree/ModelTreeHeader.d.ts +16 -16
  16. package/build/components/UI/CAD/ModelTree/index.d.ts +1 -1
  17. package/build/components/UI/CAD/ModelTree/primitives.d.ts +9 -9
  18. package/build/components/UI/CAD/ModelTree/useContextMenuItems.d.ts +5 -5
  19. package/build/components/UI/CAD/PluginBounds.d.ts +8 -8
  20. package/build/components/UI/CAD/PluginTooltip.d.ts +5 -5
  21. package/build/components/UI/CAD/PluginsWindows.d.ts +23 -23
  22. package/build/components/UI/CAD/SideBar.d.ts +6 -6
  23. package/build/components/UI/CAD/Solids/Solids.d.ts +11 -11
  24. package/build/components/UI/CAD/Solids/index.d.ts +1 -1
  25. package/build/components/UI/CAD/Solids/useContextMenuItems.d.ts +5 -5
  26. package/build/components/UI/CAD/Solids/useVisibleSolids.d.ts +2 -2
  27. package/build/components/UI/CAD/ToolBar/AssemblyModeCmds.d.ts +3 -3
  28. package/build/components/UI/CAD/ToolBar/Icon.d.ts +4 -4
  29. package/build/components/UI/CAD/ToolBar/PartModeCmds.d.ts +3 -3
  30. package/build/components/UI/CAD/ToolBar/ToolBar.d.ts +6 -6
  31. package/build/components/UI/CAD/ToolBar/index.d.ts +1 -1
  32. package/build/components/UI/CAD/ToolBar/useCommands.d.ts +10 -10
  33. package/build/components/UI/CAD/ViewOptionsBar/ViewOptionButtons.d.ts +3 -3
  34. package/build/components/UI/CAD/ViewOptionsBar/useOptionCommands.d.ts +14 -14
  35. package/build/components/UI/CAD/ViewPlugButtons.d.ts +6 -6
  36. package/build/components/UI/CAD/ant-design-draggable-modal/DraggableModal.d.ts +19 -19
  37. package/build/components/UI/CAD/ant-design-draggable-modal/DraggableModal.test.d.ts +1 -1
  38. package/build/components/UI/CAD/ant-design-draggable-modal/DraggableModalContext.d.ts +9 -9
  39. package/build/components/UI/CAD/ant-design-draggable-modal/DraggableModalInner.d.ts +27 -27
  40. package/build/components/UI/CAD/ant-design-draggable-modal/DraggableModalProvider.d.ts +4 -4
  41. package/build/components/UI/CAD/ant-design-draggable-modal/ResizeHandle.d.ts +2 -2
  42. package/build/components/UI/CAD/ant-design-draggable-modal/clamp.d.ts +1 -1
  43. package/build/components/UI/CAD/ant-design-draggable-modal/draggableModalReducer.d.ts +123 -123
  44. package/build/components/UI/CAD/ant-design-draggable-modal/getWindowSize.d.ts +4 -4
  45. package/build/components/UI/CAD/ant-design-draggable-modal/index.d.ts +3 -3
  46. package/build/components/UI/CAD/ant-design-draggable-modal/useDrag.d.ts +5 -5
  47. package/build/components/UI/CAD/ant-design-draggable-modal/usePrevious.d.ts +1 -1
  48. package/build/components/UI/CAD/ant-design-draggable-modal/useResize.d.ts +7 -7
  49. package/build/components/UI/CAD/common/BlankDiv.d.ts +4 -4
  50. package/build/components/UI/CAD/common/Collapse.d.ts +8 -8
  51. package/build/components/UI/CAD/common/ContextMenu.d.ts +33 -33
  52. package/build/components/UI/CAD/common/Divider.d.ts +4 -4
  53. package/build/components/UI/CAD/common/EntityName.d.ts +9 -9
  54. package/build/components/UI/CAD/common/Icon.d.ts +5 -5
  55. package/build/components/UI/CAD/common/Img.d.ts +1 -1
  56. package/build/components/UI/CAD/common/LoadingScreen/LoadingScreen.d.ts +6 -6
  57. package/build/components/UI/CAD/common/LoadingScreen/Spinner.d.ts +2 -2
  58. package/build/components/UI/CAD/common/LoadingScreen/index.d.ts +1 -1
  59. package/build/components/UI/CAD/common/Menu.d.ts +29 -29
  60. package/build/components/UI/CAD/common/MultiSelect.d.ts +12 -12
  61. package/build/components/UI/CAD/common/NameEdit.d.ts +8 -8
  62. package/build/components/UI/CAD/common/SectionHeader.d.ts +4 -4
  63. package/build/components/UI/CAD/common/primitives.d.ts +10 -10
  64. package/build/components/UI/CAD/hooks/index.d.ts +13 -13
  65. package/build/components/UI/CAD/hooks/useContextMenuInteraction.d.ts +7 -7
  66. package/build/components/UI/CAD/hooks/useContextMenuItems.d.ts +5 -5
  67. package/build/components/UI/CAD/hooks/useCurrentInstance.d.ts +2 -2
  68. package/build/components/UI/CAD/hooks/useCurrentProduct.d.ts +2 -2
  69. package/build/components/UI/CAD/hooks/useEditMode.d.ts +7 -7
  70. package/build/components/UI/CAD/hooks/useGlobalMateInfo.d.ts +6 -6
  71. package/build/components/UI/CAD/hooks/useHasPending.d.ts +8 -8
  72. package/build/components/UI/CAD/hooks/useIsDisabled.d.ts +2 -2
  73. package/build/components/UI/CAD/hooks/useIsLoading.d.ts +8 -8
  74. package/build/components/UI/CAD/hooks/useIsSketchActive.d.ts +2 -2
  75. package/build/components/UI/CAD/hooks/useObjectDetails.d.ts +12 -12
  76. package/build/components/UI/CAD/hooks/useOperationSequence.d.ts +2 -2
  77. package/build/components/UI/CAD/hooks/useRollbackBar.d.ts +8 -8
  78. package/build/components/UI/CAD/hooks/useRoot.d.ts +2 -2
  79. package/build/components/UI/CAD/index.d.ts +17 -17
  80. package/build/components/UI/CAD/plugins/ProductManagement/ProdTable.d.ts +10 -10
  81. package/build/components/UI/CAD/plugins/ProductManagement/Root.d.ts +6 -6
  82. package/build/components/UI/CAD/plugins/ProductManagement/View.d.ts +6 -6
  83. package/build/components/UI/CAD/plugins/ProductManagement/index.d.ts +8 -8
  84. package/build/components/UI/CAD/plugins/ProductManagement/types.d.ts +4 -4
  85. package/build/components/UI/CAD/plugins/ProductManagement/useContextMenuItems.d.ts +5 -5
  86. package/build/components/UI/CAD/store/CADActions.d.ts +15 -15
  87. package/build/components/UI/CAD/store/CADStore.d.ts +26 -26
  88. package/build/components/UI/Readfile.d.ts +6 -6
  89. package/build/components/UI/editors/BooleanEditor/BooleanEditor.d.ts +8 -8
  90. package/build/components/UI/editors/BooleanEditor/index.d.ts +2 -2
  91. package/build/components/UI/editors/BooleanEditor/useBoolParam.d.ts +3 -3
  92. package/build/components/UI/editors/CSysEditor/CSysEditor.d.ts +11 -11
  93. package/build/components/UI/editors/CSysEditor/index.d.ts +2 -2
  94. package/build/components/UI/editors/CSysEditor/useCSysParam.d.ts +9 -9
  95. package/build/components/UI/editors/ColorEditor/ColorEditor.d.ts +9 -9
  96. package/build/components/UI/editors/ColorEditor/index.d.ts +2 -2
  97. package/build/components/UI/editors/ColorEditor/useColorParam.d.ts +9 -9
  98. package/build/components/UI/editors/ExpressionEditor/ExpressionEditor.d.ts +16 -16
  99. package/build/components/UI/editors/ExpressionEditor/index.d.ts +2 -2
  100. package/build/components/UI/editors/ExpressionEditor/useExpressionsParam.d.ts +5 -5
  101. package/build/components/UI/editors/NumberEditor/Inputs.d.ts +18 -18
  102. package/build/components/UI/editors/NumberEditor/Mentions.d.ts +11 -11
  103. package/build/components/UI/editors/NumberEditor/NumOrExpr.d.ts +12 -12
  104. package/build/components/UI/editors/NumberEditor/NumberEditor.d.ts +12 -12
  105. package/build/components/UI/editors/NumberEditor/index.d.ts +2 -2
  106. package/build/components/UI/editors/NumberEditor/useNumParam.d.ts +5 -5
  107. package/build/components/UI/editors/PointEditor/PointEditor.d.ts +10 -10
  108. package/build/components/UI/editors/PointEditor/index.d.ts +2 -2
  109. package/build/components/UI/editors/PointEditor/usePointParam.d.ts +5 -5
  110. package/build/components/UI/editors/RefsEditors/ChainFinder.d.ts +14 -14
  111. package/build/components/UI/editors/RefsEditors/MateEditor.d.ts +13 -13
  112. package/build/components/UI/editors/RefsEditors/MateOrientationEditor.d.ts +9 -9
  113. package/build/components/UI/editors/RefsEditors/RefEditor.d.ts +24 -24
  114. package/build/components/UI/editors/RefsEditors/RefsEditor.d.ts +16 -16
  115. package/build/components/UI/editors/RefsEditors/index.d.ts +8 -8
  116. package/build/components/UI/editors/RefsEditors/pickers.d.ts +4 -4
  117. package/build/components/UI/editors/RefsEditors/useIdParam.d.ts +3 -3
  118. package/build/components/UI/editors/RefsEditors/useMateParam.d.ts +10 -10
  119. package/build/components/UI/editors/RefsEditors/useModes.d.ts +11 -11
  120. package/build/components/UI/editors/RefsEditors/useRefsParam.d.ts +3 -3
  121. package/build/components/UI/editors/RefsEditors/useSelectedItems.d.ts +18 -18
  122. package/build/components/UI/editors/ToleranceEditor/ToleranceEditor.d.ts +7 -7
  123. package/build/components/UI/editors/ToleranceEditor/index.d.ts +2 -2
  124. package/build/components/UI/editors/ToleranceEditor/useToleranceParam.d.ts +3 -3
  125. package/build/components/UI/editors/TypeEditor/TypeEditor.d.ts +10 -10
  126. package/build/components/UI/editors/TypeEditor/index.d.ts +2 -2
  127. package/build/components/UI/editors/TypeEditor/useTypeParam.d.ts +3 -3
  128. package/build/components/UI/editors/TypeWrapper.d.ts +5 -5
  129. package/build/components/UI/editors/Wrapper.d.ts +9 -9
  130. package/build/components/UI/editors/useParam.d.ts +20 -20
  131. package/build/components/UI/editors/useValidation.d.ts +4 -4
  132. package/build/components/graphics/CSysDisplay.d.ts +50 -50
  133. package/build/components/graphics/CompositeCurveObj.d.ts +11 -11
  134. package/build/components/graphics/GeometryOverrides/GeometryOverridesManager.d.ts +5 -5
  135. package/build/components/graphics/GeometryOverrides/GeometryOverridesStore.d.ts +18 -18
  136. package/build/components/graphics/GeometryOverrides/index.d.ts +2 -2
  137. package/build/components/graphics/GeometryOverrides/useOverrideGeometryColor.d.ts +3 -3
  138. package/build/components/graphics/HUD.d.ts +4 -4
  139. package/build/components/graphics/HoveredConstraintDisplay.d.ts +5 -5
  140. package/build/components/graphics/InfinityPlane.d.ts +4 -4
  141. package/build/components/graphics/Outlines/AAPass.d.ts +8 -8
  142. package/build/components/graphics/Outlines/IDPass.d.ts +12 -12
  143. package/build/components/graphics/Outlines/Outline.d.ts +20 -20
  144. package/build/components/graphics/Outlines/OutlineEffect.d.ts +37 -37
  145. package/build/components/graphics/Outlines/OutlineMaterial.d.ts +9 -9
  146. package/build/components/graphics/Outlines/WidenPass.d.ts +17 -17
  147. package/build/components/graphics/PluginGeometryBounds.d.ts +8 -8
  148. package/build/components/graphics/SelectableMate.d.ts +3 -3
  149. package/build/components/graphics/SelectedMateObj.d.ts +12 -12
  150. package/build/components/graphics/WorkAxisObj.d.ts +10 -10
  151. package/build/components/graphics/WorkCSysObj.d.ts +11 -11
  152. package/build/components/graphics/WorkCoordSystemObj.d.ts +11 -11
  153. package/build/components/graphics/WorkPlaneObj.d.ts +11 -11
  154. package/build/components/graphics/WorkPointObj.d.ts +10 -10
  155. package/build/components/graphics/graphics.d.ts +61 -61
  156. package/build/components/graphics/utils/MatePathTransform.d.ts +10 -10
  157. package/build/components/graphics/utils/useCsysMatrix.d.ts +4 -4
  158. package/build/components/utils/CompValidation/ErrorBoundary.d.ts +28 -28
  159. package/build/components/utils/CompValidation/validators/CSysDisplayValidator.d.ts +12 -12
  160. package/build/components/utils/CompValidation/validators/DrawingValidator.d.ts +12 -12
  161. package/build/components/utils/CompValidation/validators/ExpressionsValidator.d.ts +12 -12
  162. package/build/components/utils/CompValidation/validators/FPluginValidator.d.ts +16 -16
  163. package/build/components/utils/CompValidation/validators/FeatureListValidator.d.ts +12 -12
  164. package/build/components/utils/CompValidation/validators/ProductManagementValidator.d.ts +14 -14
  165. package/build/components/utils/CompValidation/verifiers.d.ts +32 -32
  166. package/build/components/utils/FtVisibilityController.d.ts +6 -6
  167. package/build/index.cjs.js +480 -454
  168. package/build/index.d.ts +73 -73
  169. package/build/index.js +480 -454
  170. package/build/plugins/AppearanceEditor/Root.d.ts +7 -7
  171. package/build/plugins/AppearanceEditor/index.d.ts +7 -7
  172. package/build/plugins/Boolean/Root.d.ts +6 -6
  173. package/build/plugins/Boolean/index.d.ts +4 -4
  174. package/build/plugins/BoundingBoxInfo/Root.d.ts +7 -7
  175. package/build/plugins/BoundingBoxInfo/View.d.ts +6 -6
  176. package/build/plugins/BoundingBoxInfo/index.d.ts +5 -5
  177. package/build/plugins/Box/Root.d.ts +6 -6
  178. package/build/plugins/Box/index.d.ts +4 -4
  179. package/build/plugins/Chamfer/Root.d.ts +6 -6
  180. package/build/plugins/Chamfer/index.d.ts +4 -4
  181. package/build/plugins/CircularPattern/Root.d.ts +6 -6
  182. package/build/plugins/CircularPattern/index.d.ts +4 -4
  183. package/build/plugins/CompositeCurve/Root.d.ts +6 -6
  184. package/build/plugins/CompositeCurve/View.d.ts +6 -6
  185. package/build/plugins/CompositeCurve/index.d.ts +5 -5
  186. package/build/plugins/Cone/Root.d.ts +6 -6
  187. package/build/plugins/Cone/index.d.ts +4 -4
  188. package/build/plugins/Cylinder/Root.d.ts +6 -6
  189. package/build/plugins/Cylinder/index.d.ts +4 -4
  190. package/build/plugins/Dimensions/DimContext.d.ts +10 -10
  191. package/build/plugins/Dimensions/Root.d.ts +6 -6
  192. package/build/plugins/Dimensions/View.d.ts +6 -6
  193. package/build/plugins/Dimensions/graphics/DimGraphics.d.ts +7 -7
  194. package/build/plugins/Dimensions/graphics/DimensionSet.d.ts +8 -8
  195. package/build/plugins/Dimensions/graphics/primitives.d.ts +35 -35
  196. package/build/plugins/Dimensions/index.d.ts +5 -5
  197. package/build/plugins/Dimensions/utils.d.ts +5 -5
  198. package/build/plugins/EntityDeletion/Root.d.ts +6 -6
  199. package/build/plugins/EntityDeletion/index.d.ts +4 -4
  200. package/build/plugins/Expressions/Root.d.ts +6 -6
  201. package/build/plugins/Expressions/index.d.ts +4 -4
  202. package/build/plugins/Expressions/useContextMenuItems.d.ts +5 -5
  203. package/build/plugins/Extrusion/Root.d.ts +6 -6
  204. package/build/plugins/Extrusion/View.d.ts +6 -6
  205. package/build/plugins/Extrusion/index.d.ts +10 -10
  206. package/build/plugins/Fillet/Root.d.ts +6 -6
  207. package/build/plugins/Fillet/index.d.ts +4 -4
  208. package/build/plugins/HLConstraints/CircularPattern/Root.d.ts +6 -6
  209. package/build/plugins/HLConstraints/CircularPattern/View.d.ts +6 -6
  210. package/build/plugins/HLConstraints/CircularPattern/index.d.ts +5 -5
  211. package/build/plugins/HLConstraints/Cylindrical/Root.d.ts +6 -6
  212. package/build/plugins/HLConstraints/Cylindrical/View.d.ts +6 -6
  213. package/build/plugins/HLConstraints/Cylindrical/index.d.ts +5 -5
  214. package/build/plugins/HLConstraints/Fastened/Root.d.ts +6 -6
  215. package/build/plugins/HLConstraints/Fastened/View.d.ts +6 -6
  216. package/build/plugins/HLConstraints/Fastened/index.d.ts +5 -5
  217. package/build/plugins/HLConstraints/FastenedOrigin/Root.d.ts +6 -6
  218. package/build/plugins/HLConstraints/FastenedOrigin/View.d.ts +6 -6
  219. package/build/plugins/HLConstraints/FastenedOrigin/index.d.ts +5 -5
  220. package/build/plugins/HLConstraints/Gear/Root.d.ts +6 -6
  221. package/build/plugins/HLConstraints/Gear/View.d.ts +6 -6
  222. package/build/plugins/HLConstraints/Gear/index.d.ts +5 -5
  223. package/build/plugins/HLConstraints/Group/Root.d.ts +6 -6
  224. package/build/plugins/HLConstraints/Group/index.d.ts +4 -4
  225. package/build/plugins/HLConstraints/LinearPattern/Root.d.ts +6 -6
  226. package/build/plugins/HLConstraints/LinearPattern/View.d.ts +6 -6
  227. package/build/plugins/HLConstraints/LinearPattern/index.d.ts +5 -5
  228. package/build/plugins/HLConstraints/Parallel/Root.d.ts +6 -6
  229. package/build/plugins/HLConstraints/Parallel/View.d.ts +6 -6
  230. package/build/plugins/HLConstraints/Parallel/index.d.ts +5 -5
  231. package/build/plugins/HLConstraints/Planar/Root.d.ts +6 -6
  232. package/build/plugins/HLConstraints/Planar/View.d.ts +6 -6
  233. package/build/plugins/HLConstraints/Planar/index.d.ts +5 -5
  234. package/build/plugins/HLConstraints/Revolute/Root.d.ts +6 -6
  235. package/build/plugins/HLConstraints/Revolute/View.d.ts +6 -6
  236. package/build/plugins/HLConstraints/Revolute/index.d.ts +5 -5
  237. package/build/plugins/HLConstraints/Slider/Root.d.ts +6 -6
  238. package/build/plugins/HLConstraints/Slider/View.d.ts +6 -6
  239. package/build/plugins/HLConstraints/Slider/index.d.ts +5 -5
  240. package/build/plugins/HLConstraints/Spherical/Root.d.ts +6 -6
  241. package/build/plugins/HLConstraints/Spherical/View.d.ts +6 -6
  242. package/build/plugins/HLConstraints/Spherical/index.d.ts +5 -5
  243. package/build/plugins/HLConstraints/components/CSysDisplayWrapper.d.ts +7 -7
  244. package/build/plugins/HLConstraints/components/HLConstrIcon.d.ts +7 -7
  245. package/build/plugins/HLConstraints/components/LimitedValue.d.ts +12 -12
  246. package/build/plugins/HLConstraints/components/Limits.d.ts +25 -25
  247. package/build/plugins/HLConstraints/components/LimitsCollapse.d.ts +8 -8
  248. package/build/plugins/HLConstraints/validators.d.ts +2 -2
  249. package/build/plugins/Import/Root.d.ts +6 -6
  250. package/build/plugins/Import/index.d.ts +4 -4
  251. package/build/plugins/LinearPattern/Root.d.ts +6 -6
  252. package/build/plugins/LinearPattern/index.d.ts +4 -4
  253. package/build/plugins/Measure/Digits.d.ts +6 -6
  254. package/build/plugins/Measure/Root.d.ts +6 -6
  255. package/build/plugins/Measure/View.d.ts +10 -10
  256. package/build/plugins/Measure/config.d.ts +1 -1
  257. package/build/plugins/Measure/graphics/MeasureGraphics.d.ts +24 -24
  258. package/build/plugins/Measure/index.d.ts +9 -9
  259. package/build/plugins/Measure/utils.d.ts +1 -1
  260. package/build/plugins/Mirror/Root.d.ts +6 -6
  261. package/build/plugins/Mirror/index.d.ts +4 -4
  262. package/build/plugins/Revolve/Root.d.ts +6 -6
  263. package/build/plugins/Revolve/index.d.ts +4 -4
  264. package/build/plugins/Rotate/Root.d.ts +6 -6
  265. package/build/plugins/Rotate/index.d.ts +4 -4
  266. package/build/plugins/Sketch/Root/Constraints/Constraints.d.ts +2 -2
  267. package/build/plugins/Sketch/Root/Constraints/constraintsHelpers.d.ts +21 -21
  268. package/build/plugins/Sketch/Root/Constraints/index.d.ts +2 -2
  269. package/build/plugins/Sketch/Root/Constraints/utils.d.ts +6 -6
  270. package/build/plugins/Sketch/Root/CopyPatterns.d.ts +2 -2
  271. package/build/plugins/Sketch/Root/Details.d.ts +2 -2
  272. package/build/plugins/Sketch/Root/Handlers.d.ts +3 -3
  273. package/build/plugins/Sketch/Root/PlaneSelection.d.ts +7 -7
  274. package/build/plugins/Sketch/Root/Position.d.ts +2 -2
  275. package/build/plugins/Sketch/Root/Regions.d.ts +2 -2
  276. package/build/plugins/Sketch/Root/Root.d.ts +6 -6
  277. package/build/plugins/Sketch/Root/RootContext.d.ts +7 -7
  278. package/build/plugins/Sketch/Root/SketchGroup.d.ts +9 -9
  279. package/build/plugins/Sketch/Root/index.d.ts +1 -1
  280. package/build/plugins/Sketch/Root/useContextMenuItems.d.ts +5 -5
  281. package/build/plugins/Sketch/Root/useLayoutSize.d.ts +11 -11
  282. package/build/plugins/Sketch/View/View.d.ts +6 -6
  283. package/build/plugins/Sketch/View/ViewContext.d.ts +8 -8
  284. package/build/plugins/Sketch/View/graphics/Constraints.d.ts +5 -5
  285. package/build/plugins/Sketch/View/graphics/IconGroups.d.ts +7 -7
  286. package/build/plugins/Sketch/View/graphics/Merged/Arc.d.ts +12 -12
  287. package/build/plugins/Sketch/View/graphics/Merged/ArcGeometry.d.ts +2 -2
  288. package/build/plugins/Sketch/View/graphics/Merged/ArcMaterial.d.ts +2 -2
  289. package/build/plugins/Sketch/View/graphics/Merged/Circle.d.ts +8 -8
  290. package/build/plugins/Sketch/View/graphics/Merged/Line.d.ts +10 -10
  291. package/build/plugins/Sketch/View/graphics/Merged/MergedWrapper.d.ts +24 -24
  292. package/build/plugins/Sketch/View/graphics/Merged/Point.d.ts +8 -8
  293. package/build/plugins/Sketch/View/graphics/MousePosition.d.ts +2 -2
  294. package/build/plugins/Sketch/View/graphics/Regions.d.ts +5 -5
  295. package/build/plugins/Sketch/View/graphics/TmpAngularDimension.d.ts +8 -8
  296. package/build/plugins/Sketch/View/graphics/graphics.d.ts +5 -5
  297. package/build/plugins/Sketch/View/graphics/hooks.d.ts +38 -38
  298. package/build/plugins/Sketch/View/graphics/primitives.d.ts +34 -34
  299. package/build/plugins/Sketch/View/graphics/scale.d.ts +5 -5
  300. package/build/plugins/Sketch/View/graphics/tmpGraphics.d.ts +3 -3
  301. package/build/plugins/Sketch/View/handlers/CreateAngle.d.ts +3 -3
  302. package/build/plugins/Sketch/View/handlers/Drag.d.ts +3 -3
  303. package/build/plugins/Sketch/View/handlers/DrawArc.d.ts +3 -3
  304. package/build/plugins/Sketch/View/handlers/DrawCircle.d.ts +3 -3
  305. package/build/plugins/Sketch/View/handlers/DrawLine.d.ts +3 -3
  306. package/build/plugins/Sketch/View/handlers/DrawPoint.d.ts +3 -3
  307. package/build/plugins/Sketch/View/handlers/DrawRectangle.d.ts +3 -3
  308. package/build/plugins/Sketch/View/handlers/Fillet.d.ts +3 -3
  309. package/build/plugins/Sketch/View/handlers/HandlersConstructors.d.ts +28 -28
  310. package/build/plugins/Sketch/View/handlers/Hover.d.ts +3 -3
  311. package/build/plugins/Sketch/View/handlers/SSelect.d.ts +3 -3
  312. package/build/plugins/Sketch/View/handlers/Split.d.ts +3 -3
  313. package/build/plugins/Sketch/View/handlers/Trim.d.ts +3 -3
  314. package/build/plugins/Sketch/View/handlers/Use.d.ts +3 -3
  315. package/build/plugins/Sketch/View/handlers/filletHelpers.d.ts +22 -22
  316. package/build/plugins/Sketch/View/handlers/hoverHelpers.d.ts +3 -3
  317. package/build/plugins/Sketch/View/handlers/snapper.d.ts +11 -11
  318. package/build/plugins/Sketch/View/handlers/splitHelpers.d.ts +19 -19
  319. package/build/plugins/Sketch/View/index.d.ts +1 -1
  320. package/build/plugins/Sketch/constants.d.ts +5 -5
  321. package/build/plugins/Sketch/description.d.ts +2 -2
  322. package/build/plugins/Sketch/index.d.ts +4 -4
  323. package/build/plugins/Sketch/resources.d.ts +5 -5
  324. package/build/plugins/Sketch/types.d.ts +133 -133
  325. package/build/plugins/Sketch/utils/Interaction.d.ts +7 -7
  326. package/build/plugins/Sketch/utils/OverdefinedStateManager.d.ts +6 -6
  327. package/build/plugins/Sketch/utils/getSketchState.d.ts +3 -3
  328. package/build/plugins/Sketch/utils/useSketchRegions.d.ts +2 -2
  329. package/build/plugins/Sketch/utils/useSketchState.d.ts +4 -4
  330. package/build/plugins/Slice/Root.d.ts +6 -6
  331. package/build/plugins/Slice/index.d.ts +4 -4
  332. package/build/plugins/SliceBySheet/Root.d.ts +6 -6
  333. package/build/plugins/SliceBySheet/index.d.ts +4 -4
  334. package/build/plugins/Sphere/Root.d.ts +6 -6
  335. package/build/plugins/Sphere/index.d.ts +4 -4
  336. package/build/plugins/TransformByCsys/Root.d.ts +6 -6
  337. package/build/plugins/TransformByCsys/index.d.ts +4 -4
  338. package/build/plugins/Translate/Root.d.ts +6 -6
  339. package/build/plugins/Translate/index.d.ts +4 -4
  340. package/build/plugins/Twist/Root.d.ts +6 -6
  341. package/build/plugins/Twist/View.d.ts +6 -6
  342. package/build/plugins/Twist/index.d.ts +10 -10
  343. package/build/plugins/WorkAxis/Root.d.ts +6 -6
  344. package/build/plugins/WorkAxis/View.d.ts +6 -6
  345. package/build/plugins/WorkAxis/index.d.ts +5 -5
  346. package/build/plugins/WorkCSys/Root.d.ts +6 -6
  347. package/build/plugins/WorkCSys/View.d.ts +6 -6
  348. package/build/plugins/WorkCSys/index.d.ts +14 -14
  349. package/build/plugins/WorkCoordSystem/Root.d.ts +6 -6
  350. package/build/plugins/WorkCoordSystem/View.d.ts +6 -6
  351. package/build/plugins/WorkCoordSystem/index.d.ts +14 -14
  352. package/build/plugins/WorkPlane/Root.d.ts +6 -6
  353. package/build/plugins/WorkPlane/View.d.ts +6 -6
  354. package/build/plugins/WorkPlane/index.d.ts +5 -5
  355. package/build/plugins/WorkPlane/validators.d.ts +1 -1
  356. package/build/plugins/WorkPoint/Root.d.ts +6 -6
  357. package/build/plugins/WorkPoint/View.d.ts +6 -6
  358. package/build/plugins/WorkPoint/index.d.ts +5 -5
  359. package/build/plugins/components/PluginForm.d.ts +24 -24
  360. package/build/plugins/utils/useRefsReset.d.ts +2 -2
  361. package/build/types.d.ts +17 -17
  362. package/build/utils/FileUtils.d.ts +18 -18
  363. package/build/utils/conversionUtils.d.ts +16 -16
  364. package/build/utils/defaultValues.d.ts +3 -3
  365. package/build/utils/drawing/index.d.ts +3 -3
  366. package/build/utils/drawing/useDrawingArr.d.ts +10 -10
  367. package/build/utils/drawing/useDrawingCCId.d.ts +10 -10
  368. package/build/utils/drawing/useDrawingStr.d.ts +10 -10
  369. package/build/utils/getHighlightedColor.d.ts +1 -1
  370. package/build/utils/getMatePath.d.ts +2 -2
  371. package/build/utils/getMateRefIds.d.ts +2 -2
  372. package/build/utils/helpers.d.ts +18 -18
  373. package/build/utils/mateUtils.d.ts +2 -2
  374. package/build/utils/selection/filters.d.ts +12 -12
  375. package/build/utils/selection/scopes/mateSelection.d.ts +29 -29
  376. package/build/utils/selection/scopes/treeObjInteraction.d.ts +37 -37
  377. package/build/utils/selection/useSelectorsOrder.d.ts +12 -12
  378. package/build/utils/sketchIntersectionUtils.d.ts +29 -29
  379. package/build/utils/sketchUtils.d.ts +173 -173
  380. package/build/utils/useAllObjects.d.ts +2 -2
  381. package/build/utils/useIsUncommited.d.ts +2 -2
  382. package/build/utils/useRetainVisibility.d.ts +2 -2
  383. package/build/utils/useScale.d.ts +4 -4
  384. package/build/utils/validation.d.ts +11 -11
  385. package/package.json +107 -107
@@ -18,7 +18,6 @@ require('antd/dist/antd.css');
18
18
  var styled = require('styled-components');
19
19
  var Dropdown = require('antd/lib/dropdown');
20
20
  var DOMPurify = require('dompurify');
21
- var styleInject = require('../node_modules/style-inject/dist/style-inject.es.js');
22
21
  var _objectWithoutProperties = require('@babel/runtime/helpers/objectWithoutProperties');
23
22
  var reactDom = require('react-dom');
24
23
  var antd = require('antd');
@@ -68,39 +67,39 @@ const EMPTYARRAY = [];
68
67
  const NOCCID = Number.MIN_SAFE_INTEGER;
69
68
  const EMPTYSTR = '';
70
69
 
71
- /**
72
- * Wrapper around useDrawing which allows to avoid ReferenceErrors.
73
- * Use useDrawingArr if you want to get an array from store. It returns EMPTYARRAY if requested one is undefined.
74
- *
75
- * @param drawingId
76
- * @param selector
77
- * @returns requested by selector array or EMPTYARRAY if requested is undefined or null
70
+ /**
71
+ * Wrapper around useDrawing which allows to avoid ReferenceErrors.
72
+ * Use useDrawingArr if you want to get an array from store. It returns EMPTYARRAY if requested one is undefined.
73
+ *
74
+ * @param drawingId
75
+ * @param selector
76
+ * @returns requested by selector array or EMPTYARRAY if requested is undefined or null
78
77
  */
79
78
  function useDrawingArr(drawingId, selector) {
80
79
  const res = react.useDrawing(drawingId, selector);
81
80
  return res || EMPTYARRAY;
82
81
  }
83
82
 
84
- /**
85
- * Wrapper around useDrawing which allows to avoid ReferenceErrors.
86
- * Use useDrawingCCId if you want to get an object id from store. It returns NOCCID if requested one is undefined or null.
87
- *
88
- * @param drawingId
89
- * @param selector
90
- * @returns requested by selector object id or NOCCID if requested is undefined or null
83
+ /**
84
+ * Wrapper around useDrawing which allows to avoid ReferenceErrors.
85
+ * Use useDrawingCCId if you want to get an object id from store. It returns NOCCID if requested one is undefined or null.
86
+ *
87
+ * @param drawingId
88
+ * @param selector
89
+ * @returns requested by selector object id or NOCCID if requested is undefined or null
91
90
  */
92
91
  function useDrawingCCId(drawingId, selector) {
93
92
  const res = react.useDrawing(drawingId, selector);
94
93
  return res || NOCCID;
95
94
  }
96
95
 
97
- /**
98
- * Wrapper around useDrawing which allows to avoid ReferenceErrors.
99
- * Use useDrawingStr if you want to get a string from store. It returns EMPTYSTR if requested one is undefined.
100
- *
101
- * @param drawingId
102
- * @param selector
103
- * @returns requested by selector string or EMPTYSTRING if requested one is undefined or null
96
+ /**
97
+ * Wrapper around useDrawing which allows to avoid ReferenceErrors.
98
+ * Use useDrawingStr if you want to get a string from store. It returns EMPTYSTR if requested one is undefined.
99
+ *
100
+ * @param drawingId
101
+ * @param selector
102
+ * @returns requested by selector string or EMPTYSTRING if requested one is undefined or null
104
103
  */
105
104
  function useDrawingStr(drawingId, selector) {
106
105
  const res = react.useDrawing(drawingId, selector);
@@ -135,17 +134,17 @@ function getGraphicId(tree, refOrObjId) {
135
134
  return res;
136
135
  }
137
136
 
138
- /**
139
- * Creates Selected Items for the feature references and id of a geometry.
140
- * If there is no corresponding graphics in the cache the empty array will be returned.
141
- * This hook check cache stamp,
142
- * so when the new graphics will be downloaded this hook returns refreshed array.
143
- *
144
- * An array of @see SelectedItem will be returned.
145
- *
146
- * @param drawingId The drawing id.
147
- * @param refOrObjIds The ids of the objects or references to find.
148
- * @returns An array of @see SelectedItem
137
+ /**
138
+ * Creates Selected Items for the feature references and id of a geometry.
139
+ * If there is no corresponding graphics in the cache the empty array will be returned.
140
+ * This hook check cache stamp,
141
+ * so when the new graphics will be downloaded this hook returns refreshed array.
142
+ *
143
+ * An array of @see SelectedItem will be returned.
144
+ *
145
+ * @param drawingId The drawing id.
146
+ * @param refOrObjIds The ids of the objects or references to find.
147
+ * @returns An array of @see SelectedItem
149
148
  */
150
149
 
151
150
  function useSelectedItems(drawingId, refOrObjIds) {
@@ -157,11 +156,11 @@ function useSelectedItems(drawingId, refOrObjIds) {
157
156
  const cacheStamp = react.useDrawing(drawingId, d => d.geometry.stamp);
158
157
  const cache = core.getDrawing(drawingId).geometry.cache;
159
158
  const sortedContainerIds = React.useMemo(() => {
160
- /**
161
- * The containers must be sorted according to the following rules:
162
- 1. In descending order (historical)
163
- 2. The visible containers must be treated first
164
- 3. Remove duplicats from elems array
159
+ /**
160
+ * The containers must be sorted according to the following rules:
161
+ 1. In descending order (historical)
162
+ 2. The visible containers must be treated first
163
+ 3. Remove duplicats from elems array
165
164
  */
166
165
  const allContainers = Object.getOwnPropertyNames(cache).map(n => Number(n)).sort((a, b) => b - a);
167
166
  const sortedContainerIds_ = [...activeContainers, ...visibleContainers, ...allContainers];
@@ -669,7 +668,34 @@ const Wrapper = ({
669
668
  }, children);
670
669
  };
671
670
 
672
- var css_248z$6 = ".expression-text-wrapper, .expression-text-wrapper-focused {\r\n display: block;\r\n box-sizing: border-box;\r\n position: relative;\r\n width: 100%;\r\n height: 25px;\r\n min-width: 0px;\r\n flex: 1 1 25%;\r\n border: 1px solid rgb(217, 217, 217);\r\n border-radius: 2px;\r\n background-color: rgb(255, 255, 255);\r\n padding: 1px 18px 4px 11px;\r\n margin: 2px 1px;\r\n overflow: hidden;\r\n text-wrap-mode: nowrap;\r\n transition: all 0.3s;\r\n}\r\n\r\n.expression-text-wrapper:hover {\r\n border-color: rgb(64, 169, 255);\r\n}\r\n\r\n.expression-text-wrapper-focused, .expression-text-wrapper-menu-open {\r\n border-color: rgb(64, 169, 255);\r\n box-shadow: 0 0 0 2px rgba(24, 144, 255, 0.2);\r\n}\r\n\r\n.expression-text-input {\r\n display: block;\r\n box-sizing: border-box;\r\n width: 100%;\r\n height: 18px;\r\n min-width: 0px;\r\n flex: 1 1 25%;\r\n line-height: 18px;\r\n outline: none;\r\n color: rgba(0, 0, 0, 0.85);\r\n margin: 2px 0px;\r\n line-clamp: 1;\r\n overflow-wrap: break-word;\r\n text-wrap-mode: nowrap;\r\n word-break: break-all;\r\n white-space: nowrap;\r\n overflow-x: auto;\r\n\t-webkit-scrollbar-width: none;\r\n\tscrollbar-width: none; \r\n\t-ms-overflow-style: none;\r\n}\r\n\r\n.expression-text-input .expression-span {\r\n display: inline-block;\r\n padding: 0px 1px;\r\n background: rgb(212, 212, 212);\r\n border-radius: 4px;\r\n cursor: pointer;\r\n transition: all 0.3s;\r\n}\r\n\r\n.expression-text-input .expression-span-selected {\r\n background: rgb(184, 184, 184);\r\n /* background: rgb(149, 122, 184); */\r\n cursor: text;\r\n}\r\n\r\n.expression-text-input .expression-span-inactive {\r\n cursor: text;\r\n}\r\n\r\n.expression-text-input .expression-span:hover {\r\n background: rgb(184, 184, 184);\r\n}\r\n\r\n.expression-text-input .expression-span-inactive:hover {\r\n background: rgb(212, 212, 212);\r\n}\r\n\r\n.expression-text-input .expression-span .expression-tag {\r\n font-size: 12px;\r\n color: rgba(0, 0, 0, 0.6);\r\n}\r\n ";
671
+ function styleInject(css, ref) {
672
+ if ( ref === void 0 ) ref = {};
673
+ var insertAt = ref.insertAt;
674
+
675
+ if (!css || typeof document === 'undefined') { return; }
676
+
677
+ var head = document.head || document.getElementsByTagName('head')[0];
678
+ var style = document.createElement('style');
679
+ style.type = 'text/css';
680
+
681
+ if (insertAt === 'top') {
682
+ if (head.firstChild) {
683
+ head.insertBefore(style, head.firstChild);
684
+ } else {
685
+ head.appendChild(style);
686
+ }
687
+ } else {
688
+ head.appendChild(style);
689
+ }
690
+
691
+ if (style.styleSheet) {
692
+ style.styleSheet.cssText = css;
693
+ } else {
694
+ style.appendChild(document.createTextNode(css));
695
+ }
696
+ }
697
+
698
+ var css_248z$6 = ".expression-text-wrapper, .expression-text-wrapper-focused {\n display: block;\n box-sizing: border-box;\n position: relative;\n width: 100%;\n height: 25px;\n min-width: 0px;\n flex: 1 1 25%;\n border: 1px solid rgb(217, 217, 217);\n border-radius: 2px;\n background-color: rgb(255, 255, 255);\n padding: 1px 18px 4px 11px;\n margin: 2px 1px;\n overflow: hidden;\n text-wrap-mode: nowrap;\n transition: all 0.3s;\n}\n\n.expression-text-wrapper:hover {\n border-color: rgb(64, 169, 255);\n}\n\n.expression-text-wrapper-focused, .expression-text-wrapper-menu-open {\n border-color: rgb(64, 169, 255);\n box-shadow: 0 0 0 2px rgba(24, 144, 255, 0.2);\n}\n\n.expression-text-input {\n display: block;\n box-sizing: border-box;\n width: 100%;\n height: 18px;\n min-width: 0px;\n flex: 1 1 25%;\n line-height: 18px;\n outline: none;\n color: rgba(0, 0, 0, 0.85);\n margin: 2px 0px;\n line-clamp: 1;\n overflow-wrap: break-word;\n text-wrap-mode: nowrap;\n word-break: break-all;\n white-space: nowrap;\n overflow-x: auto;\n\t-webkit-scrollbar-width: none;\n\tscrollbar-width: none; \n\t-ms-overflow-style: none;\n}\n\n.expression-text-input .expression-span {\n display: inline-block;\n padding: 0px 1px;\n background: rgb(212, 212, 212);\n border-radius: 4px;\n cursor: pointer;\n transition: all 0.3s;\n}\n\n.expression-text-input .expression-span-selected {\n background: rgb(184, 184, 184);\n /* background: rgb(149, 122, 184); */\n cursor: text;\n}\n\n.expression-text-input .expression-span-inactive {\n cursor: text;\n}\n\n.expression-text-input .expression-span:hover {\n background: rgb(184, 184, 184);\n}\n\n.expression-text-input .expression-span-inactive:hover {\n background: rgb(212, 212, 212);\n}\n\n.expression-text-input .expression-span .expression-tag {\n font-size: 12px;\n color: rgba(0, 0, 0, 0.6);\n}\n ";
673
699
  styleInject(css_248z$6);
674
700
 
675
701
  function ownKeys$v(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
@@ -1093,24 +1119,24 @@ const Mentions = ({
1093
1119
  ref.current.focus();
1094
1120
  }, [onChange, curExprLink]);
1095
1121
 
1096
- /* const onBlur = React.useCallback(() => {
1097
- window.console.log('inputblur')
1098
- let i = 0
1099
- const textContent = ref.current.textContent || ''
1100
- const textArr = textContent.split(/(@expr\.\w*)/)
1101
- for (const fragment of textArr) {
1102
- if (fragment.length > 0 && fragment.indexOf('@expr.') === 0) {
1103
- const exprLink = fragment.slice(6)
1104
- if (options.findIndex(option => option.key === exprLink) === -1) {
1105
- const { start, end } = linkRangeRef.current[i]
1106
- const textContentNew = textContent.slice(0, start) + textContent.slice(end)
1107
- setCurExprLink(-1)
1108
- setActiveMenuIndex(0)
1109
- onChange(textContentNew)
1110
- }
1111
- i++
1112
- }
1113
- }
1122
+ /* const onBlur = React.useCallback(() => {
1123
+ window.console.log('inputblur')
1124
+ let i = 0
1125
+ const textContent = ref.current.textContent || ''
1126
+ const textArr = textContent.split(/(@expr\.\w*)/)
1127
+ for (const fragment of textArr) {
1128
+ if (fragment.length > 0 && fragment.indexOf('@expr.') === 0) {
1129
+ const exprLink = fragment.slice(6)
1130
+ if (options.findIndex(option => option.key === exprLink) === -1) {
1131
+ const { start, end } = linkRangeRef.current[i]
1132
+ const textContentNew = textContent.slice(0, start) + textContent.slice(end)
1133
+ setCurExprLink(-1)
1134
+ setActiveMenuIndex(0)
1135
+ onChange(textContentNew)
1136
+ }
1137
+ i++
1138
+ }
1139
+ }
1114
1140
  }, [onChange, options]) */
1115
1141
 
1116
1142
  const [isFocused, setIsFocused] = React.useState(false);
@@ -1576,18 +1602,18 @@ function useValidation(userValue) {
1576
1602
  };
1577
1603
  }
1578
1604
 
1579
- /**
1580
- * Wrapper for a parameter which will be used in an editor.
1581
- * @param param - an object which should contain next props:
1582
- * {
1583
- * userValue - value shown for the user
1584
- * setUserValue - userValue setter
1585
- defaults - default value
1586
- isChanged - function shows whether value is changed or not
1587
- * }
1588
- * @param getServValue - if value should be converted (e.g. deg -> rad) pass this function, it will be called right before classCAD API call.
1589
- * @param validation - Custom validation (used in useMateParam, useRefsParam. - these params has an array in userValue, so we need to apply validateF for each element from array).
1590
- * @returns
1605
+ /**
1606
+ * Wrapper for a parameter which will be used in an editor.
1607
+ * @param param - an object which should contain next props:
1608
+ * {
1609
+ * userValue - value shown for the user
1610
+ * setUserValue - userValue setter
1611
+ defaults - default value
1612
+ isChanged - function shows whether value is changed or not
1613
+ * }
1614
+ * @param getServValue - if value should be converted (e.g. deg -> rad) pass this function, it will be called right before classCAD API call.
1615
+ * @param validation - Custom validation (used in useMateParam, useRefsParam. - these params has an array in userValue, so we need to apply validateF for each element from array).
1616
+ * @returns
1591
1617
  */
1592
1618
  function useParam(param, getServValue, validation, options) {
1593
1619
  // TODO: use validator functions here
@@ -1828,8 +1854,8 @@ const createAppState = (set, get) => ({
1828
1854
  api: appApi(set, get)
1829
1855
  });
1830
1856
  const CADApi = vanilla((set, get) => createAppState(set, get));
1831
- /**
1832
- * We need separate store for CAD components. It might contain auxiliary information like stack of current products or camera api.
1857
+ /**
1858
+ * We need separate store for CAD components. It might contain auxiliary information like stack of current products or camera api.
1833
1859
  */
1834
1860
  const useCADStore = create(CADApi);
1835
1861
  const useVisibleMap = () => useCADStore(s => s.assemblyTree.visibleMap);
@@ -2660,16 +2686,16 @@ const DimensionSet = ({
2660
2686
  }))));
2661
2687
  };
2662
2688
 
2663
- /**
2664
- * @see https://reactjs.org/docs/error-boundaries.html
2689
+ /**
2690
+ * @see https://reactjs.org/docs/error-boundaries.html
2665
2691
  */
2666
2692
  const isDev = process.env.NODE_ENV === 'development';
2667
2693
 
2668
- /**
2669
- * Wrapper for components which are exported from package.
2670
- * It's intended to catch all errors and show friendly fallback to the user instead of error log.
2671
- * By default it returns null in error case. You have to pass showHtml prop to show message to the user.
2672
- * TODO: implement message showing.
2694
+ /**
2695
+ * Wrapper for components which are exported from package.
2696
+ * It's intended to catch all errors and show friendly fallback to the user instead of error log.
2697
+ * By default it returns null in error case. You have to pass showHtml prop to show message to the user.
2698
+ * TODO: implement message showing.
2673
2699
  */
2674
2700
  class ErrorBoundary extends React.Component {
2675
2701
  constructor(props) {
@@ -2939,11 +2965,11 @@ function useRefsParam(drawingId, objId, memberName) {
2939
2965
  });
2940
2966
  }
2941
2967
 
2942
- /**
2943
- * Checks if the currently active plugin is CC_Sketch.
2944
- *
2945
- * @param drawingId The drawing id.
2946
- * @returns True if CC_Sketch is active, false otherwise.
2968
+ /**
2969
+ * Checks if the currently active plugin is CC_Sketch.
2970
+ *
2971
+ * @param drawingId The drawing id.
2972
+ * @returns True if CC_Sketch is active, false otherwise.
2947
2973
  */
2948
2974
  const isSketchActive = drawingId => {
2949
2975
  var _drawing$structure$tr;
@@ -2953,13 +2979,13 @@ const isSketchActive = drawingId => {
2953
2979
  return classcad.ccUtils.base.isA(objClass, classcad.ScgClassType.CCSketch);
2954
2980
  };
2955
2981
 
2956
- /**
2957
- * Calculates the tangent vector of a CC_Line / CC_Arc / CC_Circle at the specified point.
2958
- *
2959
- * @param drawingId The drawing id.
2960
- * @param curveId Id of a CC_Line / CC_Arc / CC_Circle.
2961
- * @param point Point at which the tangent touches a curve.
2962
- * @returns Tangent vector value.
2982
+ /**
2983
+ * Calculates the tangent vector of a CC_Line / CC_Arc / CC_Circle at the specified point.
2984
+ *
2985
+ * @param drawingId The drawing id.
2986
+ * @param curveId Id of a CC_Line / CC_Arc / CC_Circle.
2987
+ * @param point Point at which the tangent touches a curve.
2988
+ * @returns Tangent vector value.
2963
2989
  */
2964
2990
  const calculateTangent = (drawingId, curveId, point) => {
2965
2991
  var _curve$children;
@@ -2993,11 +3019,11 @@ const calculateTangent = (drawingId, curveId, point) => {
2993
3019
  return undefined;
2994
3020
  };
2995
3021
 
2996
- /**
2997
- * Checks if the object represents a sketch geometry.
2998
- *
2999
- * @param arg A structure object or CCClass of a structure object.
3000
- * @returns True if the object represents a sketch geometry, false otherwise.
3022
+ /**
3023
+ * Checks if the object represents a sketch geometry.
3024
+ *
3025
+ * @param arg A structure object or CCClass of a structure object.
3026
+ * @returns True if the object represents a sketch geometry, false otherwise.
3001
3027
  */
3002
3028
  const isSketchGeometry = arg => {
3003
3029
  if (arg === undefined) {
@@ -3008,11 +3034,11 @@ const isSketchGeometry = arg => {
3008
3034
  return classcad.ccUtils.base.isA(objClass, classcad.ScgClassType.CCPoint) || classcad.ccUtils.base.isA(objClass, classcad.ScgClassType.CCLine) || classcad.ccUtils.base.isA(objClass, classcad.ScgClassType.CCArc) || classcad.ccUtils.base.isA(objClass, classcad.ScgClassType.CCCircle);
3009
3035
  };
3010
3036
 
3011
- /**
3012
- * Checks if the object represents a 2d constraint.
3013
- *
3014
- * @param arg A structure object or CCClass of a structure object.
3015
- * @returns True if the object represents a 2d constraint, false otherwise.
3037
+ /**
3038
+ * Checks if the object represents a 2d constraint.
3039
+ *
3040
+ * @param arg A structure object or CCClass of a structure object.
3041
+ * @returns True if the object represents a 2d constraint, false otherwise.
3016
3042
  */
3017
3043
  const is2DConstraint = arg => {
3018
3044
  if (arg === undefined) {
@@ -3022,11 +3048,11 @@ const is2DConstraint = arg => {
3022
3048
  return classcad.ccUtils.base.isA(objClass, classcad.ScgClassType.CC2DConstraint);
3023
3049
  };
3024
3050
 
3025
- /**
3026
- * Checks if the object represents a sketch geometry or 2d constraint or a sketch itself.
3027
- *
3028
- * @param arg A structure object or CCClass of a structure object.
3029
- * @returns True if the object represents a sketch or a sketch geometry or a 2d constraint, false otherwise.
3051
+ /**
3052
+ * Checks if the object represents a sketch geometry or 2d constraint or a sketch itself.
3053
+ *
3054
+ * @param arg A structure object or CCClass of a structure object.
3055
+ * @returns True if the object represents a sketch or a sketch geometry or a 2d constraint, false otherwise.
3030
3056
  */
3031
3057
  const isSketchObj = arg => {
3032
3058
  if (arg === undefined) {
@@ -3036,11 +3062,11 @@ const isSketchObj = arg => {
3036
3062
  return classcad.ccUtils.base.isA(objClass, classcad.ScgClassType.CCSketch) || isSketchGeometry(objClass) || is2DConstraint(objClass);
3037
3063
  };
3038
3064
 
3039
- /**
3040
- * Checks if the object represents a sketch region.
3041
- *
3042
- * @param arg A structure object or CCClass of a structure object.
3043
- * @returns True if the object represents a sketch region, false otherwise.
3065
+ /**
3066
+ * Checks if the object represents a sketch region.
3067
+ *
3068
+ * @param arg A structure object or CCClass of a structure object.
3069
+ * @returns True if the object represents a sketch region, false otherwise.
3044
3070
  */
3045
3071
  const isSketchRegion = arg => {
3046
3072
  if (arg === undefined) {
@@ -3050,12 +3076,12 @@ const isSketchRegion = arg => {
3050
3076
  return classcad.ccUtils.base.isA(objClass, classcad.ScgClassType.CCSketchRegion);
3051
3077
  };
3052
3078
 
3053
- /**
3054
- * Searches for the sketch which nests the specified object.
3055
- *
3056
- * @param drawingId The drawing id.
3057
- * @param objId Id of an object which (supposedly) is nested within some sketch.
3058
- * @returns Id of the sketch which nests the specified object, or -1 if it wasn't found.
3079
+ /**
3080
+ * Searches for the sketch which nests the specified object.
3081
+ *
3082
+ * @param drawingId The drawing id.
3083
+ * @param objId Id of an object which (supposedly) is nested within some sketch.
3084
+ * @returns Id of the sketch which nests the specified object, or -1 if it wasn't found.
3059
3085
  */
3060
3086
  const getSketchId = (drawingId, objId) => {
3061
3087
  const tree = core.getDrawing(drawingId).structure.tree;
@@ -3066,13 +3092,13 @@ const getSketchId = (drawingId, objId) => {
3066
3092
  return objId && isSketchObj(obj) && classcad.ccUtils.base.getAncestorIdByClass(drawingId, objId, classcad.ScgClassType.CCSketch) || -1;
3067
3093
  };
3068
3094
 
3069
- /**
3070
- * Takes ids of 2 CC_Points and if they belong to the same line, returns the id of that line; otherwise, returns ids of these points.
3071
- *
3072
- * @param drawingId The drawing id.
3073
- * @param id1 Id of the first CC_Point.
3074
- * @param id2 Id of the seconds CC_Point.
3075
- * @returns An array with a single id of the CC_Line if both points belong to the same one, or an array [id1, id2] otherwise.
3095
+ /**
3096
+ * Takes ids of 2 CC_Points and if they belong to the same line, returns the id of that line; otherwise, returns ids of these points.
3097
+ *
3098
+ * @param drawingId The drawing id.
3099
+ * @param id1 Id of the first CC_Point.
3100
+ * @param id2 Id of the seconds CC_Point.
3101
+ * @returns An array with a single id of the CC_Line if both points belong to the same one, or an array [id1, id2] otherwise.
3076
3102
  */
3077
3103
  const rollUpPoints = (drawingId, id1, id2) => {
3078
3104
  const tree = core.getDrawing(drawingId).structure.tree;
@@ -3082,12 +3108,12 @@ const rollUpPoints = (drawingId, id1, id2) => {
3082
3108
  return classcad.ccUtils.base.isA(obj1 == null ? void 0 : obj1.class, classcad.ScgClassType.CCPoint) && classcad.ccUtils.base.isA(obj2 == null ? void 0 : obj2.class, classcad.ScgClassType.CCPoint) && obj1.parent === obj2.parent && classcad.ccUtils.base.isA((parent == null ? void 0 : parent.class) || '', classcad.ScgClassType.CCLine) ? [obj1.parent] : [id1, id2];
3083
3109
  };
3084
3110
 
3085
- /**
3086
- * Looks up for entities of a 2d constraint / sketch region.
3087
- *
3088
- * @param drawingId The drawing id.
3089
- * @param objectId Id of a 2d constraint / sketch region.
3090
- * @returns Ids of geometry entities linked to the specified 2d constraint / sketch region.
3111
+ /**
3112
+ * Looks up for entities of a 2d constraint / sketch region.
3113
+ *
3114
+ * @param drawingId The drawing id.
3115
+ * @param objectId Id of a 2d constraint / sketch region.
3116
+ * @returns Ids of geometry entities linked to the specified 2d constraint / sketch region.
3091
3117
  */
3092
3118
  const getEntities = (drawingId, objectId) => {
3093
3119
  var _obj$members2;
@@ -3130,11 +3156,11 @@ const getEntities = (drawingId, objectId) => {
3130
3156
  return entities;
3131
3157
  };
3132
3158
 
3133
- /**
3134
- * Defines a numeric priority of sketch objects and regions, which may be used for sorting them or as a polygon offset for rendering.
3135
- *
3136
- * @param arg A structure object or CCClass of a structure object.
3137
- * @returns A number value (1-5) which represents the sketch object's priority, or -1 if arg is not a sketch object.
3159
+ /**
3160
+ * Defines a numeric priority of sketch objects and regions, which may be used for sorting them or as a polygon offset for rendering.
3161
+ *
3162
+ * @param arg A structure object or CCClass of a structure object.
3163
+ * @returns A number value (1-5) which represents the sketch object's priority, or -1 if arg is not a sketch object.
3138
3164
  */
3139
3165
  const getSketchPriority = arg => {
3140
3166
  if (arg === undefined) {
@@ -3159,13 +3185,13 @@ const getSketchPriority = arg => {
3159
3185
  return -1;
3160
3186
  };
3161
3187
 
3162
- /**
3163
- * Projects a point onto the specified sketch geometry.
3164
- *
3165
- * @param drawingId The drawing id.
3166
- * @param geometryId Id of a sketch geometry.
3167
- * @param point A point to be projected.
3168
- * @returns A projected point.
3188
+ /**
3189
+ * Projects a point onto the specified sketch geometry.
3190
+ *
3191
+ * @param drawingId The drawing id.
3192
+ * @param geometryId Id of a sketch geometry.
3193
+ * @param point A point to be projected.
3194
+ * @returns A projected point.
3169
3195
  */
3170
3196
  const projectPointOnGeometry = (drawingId, geometryId, point) => {
3171
3197
  const tree = core.getDrawing(drawingId).structure.tree;
@@ -3191,12 +3217,12 @@ const projectPointOnGeometry = (drawingId, geometryId, point) => {
3191
3217
  return point.clone();
3192
3218
  };
3193
3219
 
3194
- /**
3195
- * Calculates an object's center point.
3196
- *
3197
- * @param drawingId The drawing id.
3198
- * @param geometryId Id of a sketch geometry.
3199
- * @returns A center point of specified sketch geometry.
3220
+ /**
3221
+ * Calculates an object's center point.
3222
+ *
3223
+ * @param drawingId The drawing id.
3224
+ * @param geometryId Id of a sketch geometry.
3225
+ * @returns A center point of specified sketch geometry.
3200
3226
  */
3201
3227
  const getObjCenterPoint = (drawingId, geometryId) => {
3202
3228
  const tree = core.getDrawing(drawingId).structure.tree;
@@ -3219,14 +3245,14 @@ const getObjCenterPoint = (drawingId, geometryId) => {
3219
3245
  return new THREE__namespace.Vector3();
3220
3246
  };
3221
3247
 
3222
- /**
3223
- * Calculates arc midpoint, radius, startAngle, endAngle and bulge values.
3224
- *
3225
- * @param start Start point of an arc.
3226
- * @param end End point of an arc.
3227
- * @param center Center point of an arc.
3228
- * @param clockwise True if the direction from start to end is clockwise, false otherwise.
3229
- * @returns An object with center, mid, radius, startAngle, endAngle and bulge values.
3248
+ /**
3249
+ * Calculates arc midpoint, radius, startAngle, endAngle and bulge values.
3250
+ *
3251
+ * @param start Start point of an arc.
3252
+ * @param end End point of an arc.
3253
+ * @param center Center point of an arc.
3254
+ * @param clockwise True if the direction from start to end is clockwise, false otherwise.
3255
+ * @returns An object with center, mid, radius, startAngle, endAngle and bulge values.
3230
3256
  */
3231
3257
  const getArcInfo = (start, end, center, clockwise) => {
3232
3258
  const vecStart = start.clone().sub(center);
@@ -3254,14 +3280,14 @@ const getArcInfo = (start, end, center, clockwise) => {
3254
3280
  };
3255
3281
  };
3256
3282
 
3257
- /**
3258
- * Finds the sector (indexed 0-3) to which the dimPos belongs to. Sectors are divided by dir0 and dir1 vectors and their negations.
3259
- *
3260
- * @param dimPos A point
3261
- * @param dir0 The first direction.
3262
- * @param dir1 The second direction.
3263
- * @param center A center point of the arc.
3264
- * @returns A sector index (0-3) to which the dimPos belongs to.
3283
+ /**
3284
+ * Finds the sector (indexed 0-3) to which the dimPos belongs to. Sectors are divided by dir0 and dir1 vectors and their negations.
3285
+ *
3286
+ * @param dimPos A point
3287
+ * @param dir0 The first direction.
3288
+ * @param dir1 The second direction.
3289
+ * @param center A center point of the arc.
3290
+ * @returns A sector index (0-3) to which the dimPos belongs to.
3265
3291
  */
3266
3292
  const getArcSector = (dimPos, dir0, dir1, center) => {
3267
3293
  const dir = dimPos.clone().sub(center).normalize();
@@ -3283,14 +3309,14 @@ const getArcSector = (dimPos, dir0, dir1, center) => {
3283
3309
  return angleToDir0IsNegative ? angleToDir1IsPositive ? 0 : 1 : angleToDir1IsPositive ? 3 : 2;
3284
3310
  };
3285
3311
 
3286
- /**
3287
- * Calculates the angle between dir0 and dir1 or their negations depending on sector and reflex values.
3288
- *
3289
- * @param dir0 The first direction.
3290
- * @param dir1 The second direction.
3291
- * @param sector The sector index (0-3).
3292
- * @param reflex A flag for changing angle coverage from the current sector to the opposite 3.
3293
- * @returns The resulting angle between dir0 and dir1.
3312
+ /**
3313
+ * Calculates the angle between dir0 and dir1 or their negations depending on sector and reflex values.
3314
+ *
3315
+ * @param dir0 The first direction.
3316
+ * @param dir1 The second direction.
3317
+ * @param sector The sector index (0-3).
3318
+ * @param reflex A flag for changing angle coverage from the current sector to the opposite 3.
3319
+ * @returns The resulting angle between dir0 and dir1.
3294
3320
  */
3295
3321
  const getArcPreviewValue = (dir0, dir1, sector, reflex) => {
3296
3322
  let previewValue = dir0.angleTo(dir1);
@@ -3300,11 +3326,11 @@ const getArcPreviewValue = (dir0, dir1, sector, reflex) => {
3300
3326
  return Math.abs(previewValue);
3301
3327
  };
3302
3328
 
3303
- /**
3304
- * Looks up for sketch's bounds values.
3305
- *
3306
- * @param boundsMember The sketch.boundingBox member.
3307
- * @returns An object containing the center, radius and box values.
3329
+ /**
3330
+ * Looks up for sketch's bounds values.
3331
+ *
3332
+ * @param boundsMember The sketch.boundingBox member.
3333
+ * @returns An object containing the center, radius and box values.
3308
3334
  */
3309
3335
  const getSketchBounds = boundsMember => {
3310
3336
  const [min, max] = boundsMember.members.map(memb => convertToVector(memb));
@@ -3350,13 +3376,13 @@ const getSketchBoundsInfo = (drawingId, sketchId) => {
3350
3376
  };
3351
3377
  };
3352
3378
 
3353
- /**
3354
- * Calculates the global bounding box, camera position, camera target and camera up vector to fit the camera for the given sketch.
3355
- *
3356
- * @param drawingId The drawing id.
3357
- * @param sketchId Id of the sketch.
3358
- * @param radiusMultiplier A multiplier for the distance between camera and sketch.
3359
- * @returns An object with globBox, position, target and up values.
3379
+ /**
3380
+ * Calculates the global bounding box, camera position, camera target and camera up vector to fit the camera for the given sketch.
3381
+ *
3382
+ * @param drawingId The drawing id.
3383
+ * @param sketchId Id of the sketch.
3384
+ * @param radiusMultiplier A multiplier for the distance between camera and sketch.
3385
+ * @returns An object with globBox, position, target and up values.
3360
3386
  */
3361
3387
  const getSketchFitInfo = (drawingId, sketchId, radiusMultiplier = 1) => {
3362
3388
  const drawing = core.getDrawing(drawingId);
@@ -3381,14 +3407,14 @@ const getSketchFitInfo = (drawingId, sketchId, radiusMultiplier = 1) => {
3381
3407
  };
3382
3408
  };
3383
3409
 
3384
- /**
3385
- * Calculates the global bounding box, camera position, camera target and camera up vector for the given sketch to target some point with camera oriented orthogonally to it.
3386
- *
3387
- * @param drawingId The drawing id.
3388
- * @param sketchId Id of the sketch.
3389
- * @param targetPos A point near the sketch plane to use as the camera target.
3390
- * @param distance The distance value to set between camera and sketch.
3391
- * @returns An object with globBox, position, target and up values.
3410
+ /**
3411
+ * Calculates the global bounding box, camera position, camera target and camera up vector for the given sketch to target some point with camera oriented orthogonally to it.
3412
+ *
3413
+ * @param drawingId The drawing id.
3414
+ * @param sketchId Id of the sketch.
3415
+ * @param targetPos A point near the sketch plane to use as the camera target.
3416
+ * @param distance The distance value to set between camera and sketch.
3417
+ * @returns An object with globBox, position, target and up values.
3392
3418
  */
3393
3419
  const getSketchNormalViewInfo = (drawingId, sketchId, targetPos, distance) => {
3394
3420
  const drawing = core.getDrawing(drawingId);
@@ -3584,14 +3610,14 @@ const useEditMode = drawingId => {
3584
3610
  function ownKeys$t(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
3585
3611
  function _objectSpread$t(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys$t(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys$t(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
3586
3612
 
3587
- /**
3588
- * Implies the following data structure:
3589
- * data: {
3590
- * path: ObjectID[],
3591
- * csys: ScgObject,
3592
- * flip: FlipType,
3593
- * reorient: ReorientedType,
3594
- * }
3613
+ /**
3614
+ * Implies the following data structure:
3615
+ * data: {
3616
+ * path: ObjectID[],
3617
+ * csys: ScgObject,
3618
+ * flip: FlipType,
3619
+ * reorient: ReorientedType,
3620
+ * }
3595
3621
  */
3596
3622
  const MateScope = 'HLConstraintScope';
3597
3623
  const createMateItem = (path, csys, flip, reorient) => {
@@ -3730,11 +3756,11 @@ const useGlobalMateInfo = (drawingId, instances, includeSelected) => {
3730
3756
  }, [drawingId, currentProduct, instanceChildren, instances, selectors, activeSelector, includeSelected]);
3731
3757
  };
3732
3758
 
3733
- /**
3734
- * Check if ClassCAD is busy with one or multiple pending requests.
3735
- *
3736
- * @param drawingId The drawing id
3737
- * @returns true, if some requests are pending
3759
+ /**
3760
+ * Check if ClassCAD is busy with one or multiple pending requests.
3761
+ *
3762
+ * @param drawingId The drawing id
3763
+ * @returns true, if some requests are pending
3738
3764
  */
3739
3765
  const useHasPending = drawingId => {
3740
3766
  return react.useDrawing(drawingId, d => d.cad.pending.length > 0);
@@ -3742,11 +3768,11 @@ const useHasPending = drawingId => {
3742
3768
 
3743
3769
  const EMPTYARR = [];
3744
3770
 
3745
- /**
3746
- * Check if ClassCAD is busy with loading something.
3747
- *
3748
- * @param drawingId The drawing id
3749
- * @returns true, if something is loading
3771
+ /**
3772
+ * Check if ClassCAD is busy with loading something.
3773
+ *
3774
+ * @param drawingId The drawing id
3775
+ * @returns true, if something is loading
3750
3776
  */
3751
3777
  const useIsLoading = drawingId => {
3752
3778
  const pending = react.useDrawing(drawingId, d => d.cad.pending) || EMPTYARR;
@@ -3886,11 +3912,11 @@ const MultiSelect = ({
3886
3912
  function ownKeys$s(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
3887
3913
  function _objectSpread$s(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys$s(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys$s(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
3888
3914
 
3889
- /**
3890
- * Implies the following data structure:
3891
- * data: {
3892
- * object: ScgObject
3893
- * }
3915
+ /**
3916
+ * Implies the following data structure:
3917
+ * data: {
3918
+ * object: ScgObject
3919
+ * }
3894
3920
  */
3895
3921
  const TreeObjScope = 'TreeObjScope';
3896
3922
  const createTreeObjSelItem = (productId, object) => {
@@ -4075,17 +4101,17 @@ function useIsSHovered(drawingId, objId) {
4075
4101
  return isSelectable && isHovered;
4076
4102
  }
4077
4103
 
4078
- /**
4079
- * Returns true if object in tree is currently selected in active selection.
4080
- *
4081
- * This hook leads to re-rendering of each element uses it.
4082
- * It happens because it uses items of the active selection,
4083
- * and it's not possible to check if objId is selected inside of useDrawing selector
4084
- * because of performance reasone (it requires traversing through all of selectedItems).
4085
- *
4086
- * @param drawingId
4087
- * @param objId
4088
- * @returns
4104
+ /**
4105
+ * Returns true if object in tree is currently selected in active selection.
4106
+ *
4107
+ * This hook leads to re-rendering of each element uses it.
4108
+ * It happens because it uses items of the active selection,
4109
+ * and it's not possible to check if objId is selected inside of useDrawing selector
4110
+ * because of performance reasone (it requires traversing through all of selectedItems).
4111
+ *
4112
+ * @param drawingId
4113
+ * @param objId
4114
+ * @returns
4089
4115
  */
4090
4116
  function useIsSSelected(drawingId, objId) {
4091
4117
  // Re-render if selItems is changed
@@ -5261,16 +5287,16 @@ function validateParams(params) {
5261
5287
  return warnings;
5262
5288
  }
5263
5289
 
5264
- /**
5265
- * @param drawingId - id of the drawing.
5266
- * @param update - a function which will be called when user presses "Update" button.
5267
- * @param params - all params which should be sent to the server. PluginForm validates each of them.
5268
- * @param validator - smart validation (check https://awv-informatik.atlassian.net/wiki/spaces/CLAS/pages/2428076033/Validation for mor details)
5269
- * @param autoClose - (optional) if true plugin will closed after update. Default is true.
5270
- * @param forceUpdateEnabled - if plugin is opened for the recently created feature it contains default values.
5271
- * User should be able to click "Update" button (clicking on close will remove the feature). Since there is no params changed by the user validator disables "Update" button.
5272
- * To make "Update" button enabled with default values pass true to forceUpdateEnabled
5273
- * @returns
5290
+ /**
5291
+ * @param drawingId - id of the drawing.
5292
+ * @param update - a function which will be called when user presses "Update" button.
5293
+ * @param params - all params which should be sent to the server. PluginForm validates each of them.
5294
+ * @param validator - smart validation (check https://awv-informatik.atlassian.net/wiki/spaces/CLAS/pages/2428076033/Validation for mor details)
5295
+ * @param autoClose - (optional) if true plugin will closed after update. Default is true.
5296
+ * @param forceUpdateEnabled - if plugin is opened for the recently created feature it contains default values.
5297
+ * User should be able to click "Update" button (clicking on close will remove the feature). Since there is no params changed by the user validator disables "Update" button.
5298
+ * To make "Update" button enabled with default values pass true to forceUpdateEnabled
5299
+ * @returns
5274
5300
  */
5275
5301
  const PluginForm = ({
5276
5302
  update,
@@ -5392,10 +5418,10 @@ const TypeEditor = ({
5392
5418
  }, Object.keys(types).filter(t => readonlyTypes.indexOf(parseInt(t)) === -1).map(t => types[parseInt(t)]));
5393
5419
  };
5394
5420
 
5395
- /**
5396
- * Allows to automatically enable all selectors in form one by one.
5397
- * @param drawingId
5398
- * @returns
5421
+ /**
5422
+ * Allows to automatically enable all selectors in form one by one.
5423
+ * @param drawingId
5424
+ * @returns
5399
5425
  */
5400
5426
  function useSelectorsOrder(drawingId) {
5401
5427
  const selectors = React.useRef([]);
@@ -5431,23 +5457,23 @@ function useSelectorsOrder(drawingId) {
5431
5457
  }), [addSelector, removeSelector, switchToNext]);
5432
5458
  }
5433
5459
 
5434
- /**
5435
- * !!! Important !!!
5436
- *
5437
- * Functions in this file are called outside of ErrorBoundary,
5438
- * so an error appearing in such function will break whole application.
5439
- *
5440
- * This is why all point operators should be guarded by question mark.
5441
- * And this is the reasone why we should not use any "regular" hooks, or just functions
5442
- * which are already used in components exported from @buerli.io/react-cad.
5443
- *
5444
- * There should not be any hard logic, verifiers are just checking if tree contains particular data
5445
- * (e.g. useCurProductVerifier checks if currentProduct exists in drawing.structure, and corresponding
5446
- * object exists in drawing.structure.tree, otherwise it adds warning).
5447
- *
5448
- * If you need to reuse non trivial existing function, it's better to copypaste code of the function
5449
- * and guard all access operator by question marks like it's already done in usePartAndAssemblyContVerifier
5450
- * for useAllObjects.
5460
+ /**
5461
+ * !!! Important !!!
5462
+ *
5463
+ * Functions in this file are called outside of ErrorBoundary,
5464
+ * so an error appearing in such function will break whole application.
5465
+ *
5466
+ * This is why all point operators should be guarded by question mark.
5467
+ * And this is the reasone why we should not use any "regular" hooks, or just functions
5468
+ * which are already used in components exported from @buerli.io/react-cad.
5469
+ *
5470
+ * There should not be any hard logic, verifiers are just checking if tree contains particular data
5471
+ * (e.g. useCurProductVerifier checks if currentProduct exists in drawing.structure, and corresponding
5472
+ * object exists in drawing.structure.tree, otherwise it adds warning).
5473
+ *
5474
+ * If you need to reuse non trivial existing function, it's better to copypaste code of the function
5475
+ * and guard all access operator by question marks like it's already done in usePartAndAssemblyContVerifier
5476
+ * for useAllObjects.
5451
5477
  */
5452
5478
 
5453
5479
  function useDrawingVerifier(drawingId, warnings) {
@@ -5633,13 +5659,13 @@ function useExprSetVerifier(drawingId, warnings) {
5633
5659
  }
5634
5660
  }
5635
5661
 
5636
- /**
5637
- * Validator for feature plugins. Checks drawing, currentProduct and corresponding feature existance.
5638
- *
5639
- * @param drawingId
5640
- * @param pluginId
5641
- * @param isCanvas used for showing different output for DOM component and for threeJS component.
5642
- * @returns
5662
+ /**
5663
+ * Validator for feature plugins. Checks drawing, currentProduct and corresponding feature existance.
5664
+ *
5665
+ * @param drawingId
5666
+ * @param pluginId
5667
+ * @param isCanvas used for showing different output for DOM component and for threeJS component.
5668
+ * @returns
5643
5669
  */
5644
5670
  const FtPluginValidator = ({
5645
5671
  drawingId,
@@ -9334,8 +9360,8 @@ const ViewContext = /*#__PURE__*/React.createContext({
9334
9360
 
9335
9361
  const tolerance$8 = 1e-6;
9336
9362
 
9337
- /**
9338
- * Allowed pixel offset for onClick handler events in case the pointer was slightly moved
9363
+ /**
9364
+ * Allowed pixel offset for onClick handler events in case the pointer was slightly moved
9339
9365
  */
9340
9366
  const deltaTolerance = 4;
9341
9367
 
@@ -12463,10 +12489,10 @@ const getColor = (object, objState) => {
12463
12489
  return 0x000000;
12464
12490
  };
12465
12491
 
12466
- /**
12467
- * Return pointerHandlers of currently enabled sketch Handler.
12468
- * @param objId
12469
- * @returns
12492
+ /**
12493
+ * Return pointerHandlers of currently enabled sketch Handler.
12494
+ * @param objId
12495
+ * @returns
12470
12496
  */
12471
12497
  const useSketchHandlers = objId => {
12472
12498
  const {
@@ -12593,14 +12619,14 @@ function useScale(drawingId, pluginId, getVector) {
12593
12619
  return ref;
12594
12620
  }
12595
12621
 
12596
- /*
12597
- * For correct drawing of objects that lie in the same plane, polygonOffset is used.
12598
- * https://www.khronos.org/registry/OpenGL-Refpages/gl4/html/glPolygonOffset.xhtml
12599
- * offset = factor * DZ + r * units
12600
- * Where DZ is a measurement of the change in depth relative to the screen area of the polygon,
12601
- * and r is the smallest value that is guaranteed to produce a resolvable offset for a given implementation.
12602
- * The offset is added before the depth test is performed and before the value is written into the depth buffer.
12603
- * factor parameter is redundant for this purpose, so only units parameter is used.
12622
+ /*
12623
+ * For correct drawing of objects that lie in the same plane, polygonOffset is used.
12624
+ * https://www.khronos.org/registry/OpenGL-Refpages/gl4/html/glPolygonOffset.xhtml
12625
+ * offset = factor * DZ + r * units
12626
+ * Where DZ is a measurement of the change in depth relative to the screen area of the polygon,
12627
+ * and r is the smallest value that is guaranteed to produce a resolvable offset for a given implementation.
12628
+ * The offset is added before the depth test is performed and before the value is written into the depth buffer.
12629
+ * factor parameter is redundant for this purpose, so only units parameter is used.
12604
12630
  */
12605
12631
 
12606
12632
  const iconSize = 2.5;
@@ -13015,10 +13041,10 @@ const InstancedGeometry = ({
13015
13041
  }, children));
13016
13042
  };
13017
13043
 
13018
- /**
13019
- * Component which implements InstancedMesh from three.js.
13020
- * Merged component from drei takes globaly created meshes and then passes corresponding "mocked" components via function props (MockCylinder and MockSphere) to children.
13021
- * "mocked" components are used for saying drei where to draw instances.
13044
+ /**
13045
+ * Component which implements InstancedMesh from three.js.
13046
+ * Merged component from drei takes globaly created meshes and then passes corresponding "mocked" components via function props (MockCylinder and MockSphere) to children.
13047
+ * "mocked" components are used for saying drei where to draw instances.
13022
13048
  */
13023
13049
  const MergedWrapper = ({
13024
13050
  children
@@ -13276,70 +13302,70 @@ const Point = ({
13276
13302
  };
13277
13303
 
13278
13304
  // Another raycast approach, should be more performant (not really in practice) but less precise
13279
- /* const arcRaycast = React.useCallback(
13280
- function (this: THREE.Mesh, raycaster: THREE.Raycaster, intersects: THREE.Intersection[]) {
13281
- const matrixWtoL = this.matrixWorld.clone().invert()
13282
- const rayL = raycaster.ray.clone().applyMatrix4(matrixWtoL)
13283
-
13284
- const sketchScale = getScale(drawingId, pluginId)
13285
- const tubeRadius_ = arcCoef * sketchScale
13286
-
13287
- const halfWidth = radius + tubeRadius_
13288
- bBoxMin.set(-halfWidth, -halfWidth, -tubeRadius_)
13289
- bBoxMax.set(halfWidth, halfWidth, tubeRadius_)
13290
- bBox.set(bBoxMin, bBoxMax)
13291
-
13292
- const mayIntersect = rayL.intersectBox(bBox, target) !== null
13293
- if (!mayIntersect) {
13294
- return
13295
- }
13296
-
13297
- let intersections: THREE.Vector3[]
13298
- if (1 - Math.abs(rayL.direction.z) < 1e-6) {
13299
- const intersection = rayL.origin.clone().setZ(0.0).normalize().multiplyScalar(radius)
13300
- intersections = [intersection]
13301
- } else {
13302
- // Origin and direction projected on the arc plane
13303
- const originP = rayL.origin.clone().setZ(0.0)
13304
- const dirP = rayL.direction.clone().setZ(0.0)
13305
-
13306
- const a = dirP.lengthSq()
13307
- const b = 2 * dirP.dot(originP)
13308
- const c = originP.lengthSq() - radius * radius
13309
-
13310
- const v1 = b * b - 4 * a * c
13311
- if (v1 < 0) {
13312
- return
13313
- }
13314
-
13315
- const w = Math.sqrt(v1)
13316
- const t1 = (-b - w) / (2 * a)
13317
- const t2 = (-b + w) / (2 * a)
13318
-
13319
- intersections = [t1, t2].map(t => originP.clone().addScaledVector(dirP, t))
13320
- }
13321
-
13322
- intersections = intersections.filter(posL => {
13323
- let angle = Math.atan2(posL.y, posL.x)
13324
- angle = angularLength >= 0 && angle < 0 ? angle + 2 * Math.PI : angle
13325
- angle = angularLength < 0 && angle >= 0 ? angle - 2 * Math.PI : angle
13326
- const u = angle / angularLength
13327
- return u >= 0 && u <= 1
13328
- })
13329
- const distances = intersections.map(posL => rayL.distanceToPoint(posL))
13330
- const dist = distances.sort()[0]
13331
-
13332
- if (dist !== undefined && dist < arcCoef * sketchScale) {
13333
- const pos = raycaster.ray.origin.clone().addScaledVector(raycaster.ray.direction, dist)
13334
- intersects.push({
13335
- distance: dist,
13336
- point: pos,
13337
- face: null,
13338
- object: this,
13339
- })
13340
- }
13341
- },
13342
- [radius, angularLength, drawingId, pluginId],
13305
+ /* const arcRaycast = React.useCallback(
13306
+ function (this: THREE.Mesh, raycaster: THREE.Raycaster, intersects: THREE.Intersection[]) {
13307
+ const matrixWtoL = this.matrixWorld.clone().invert()
13308
+ const rayL = raycaster.ray.clone().applyMatrix4(matrixWtoL)
13309
+
13310
+ const sketchScale = getScale(drawingId, pluginId)
13311
+ const tubeRadius_ = arcCoef * sketchScale
13312
+
13313
+ const halfWidth = radius + tubeRadius_
13314
+ bBoxMin.set(-halfWidth, -halfWidth, -tubeRadius_)
13315
+ bBoxMax.set(halfWidth, halfWidth, tubeRadius_)
13316
+ bBox.set(bBoxMin, bBoxMax)
13317
+
13318
+ const mayIntersect = rayL.intersectBox(bBox, target) !== null
13319
+ if (!mayIntersect) {
13320
+ return
13321
+ }
13322
+
13323
+ let intersections: THREE.Vector3[]
13324
+ if (1 - Math.abs(rayL.direction.z) < 1e-6) {
13325
+ const intersection = rayL.origin.clone().setZ(0.0).normalize().multiplyScalar(radius)
13326
+ intersections = [intersection]
13327
+ } else {
13328
+ // Origin and direction projected on the arc plane
13329
+ const originP = rayL.origin.clone().setZ(0.0)
13330
+ const dirP = rayL.direction.clone().setZ(0.0)
13331
+
13332
+ const a = dirP.lengthSq()
13333
+ const b = 2 * dirP.dot(originP)
13334
+ const c = originP.lengthSq() - radius * radius
13335
+
13336
+ const v1 = b * b - 4 * a * c
13337
+ if (v1 < 0) {
13338
+ return
13339
+ }
13340
+
13341
+ const w = Math.sqrt(v1)
13342
+ const t1 = (-b - w) / (2 * a)
13343
+ const t2 = (-b + w) / (2 * a)
13344
+
13345
+ intersections = [t1, t2].map(t => originP.clone().addScaledVector(dirP, t))
13346
+ }
13347
+
13348
+ intersections = intersections.filter(posL => {
13349
+ let angle = Math.atan2(posL.y, posL.x)
13350
+ angle = angularLength >= 0 && angle < 0 ? angle + 2 * Math.PI : angle
13351
+ angle = angularLength < 0 && angle >= 0 ? angle - 2 * Math.PI : angle
13352
+ const u = angle / angularLength
13353
+ return u >= 0 && u <= 1
13354
+ })
13355
+ const distances = intersections.map(posL => rayL.distanceToPoint(posL))
13356
+ const dist = distances.sort()[0]
13357
+
13358
+ if (dist !== undefined && dist < arcCoef * sketchScale) {
13359
+ const pos = raycaster.ray.origin.clone().addScaledVector(raycaster.ray.direction, dist)
13360
+ intersects.push({
13361
+ distance: dist,
13362
+ point: pos,
13363
+ face: null,
13364
+ object: this,
13365
+ })
13366
+ }
13367
+ },
13368
+ [radius, angularLength, drawingId, pluginId],
13343
13369
  )*/
13344
13370
 
13345
13371
  const bBox$1 = new THREE__namespace.Box3();
@@ -13571,16 +13597,16 @@ const Regions$1 = ({
13571
13597
  function ownKeys$f(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
13572
13598
  function _objectSpread$f(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys$f(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys$f(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
13573
13599
 
13574
- /*
13575
- * !polygonOffset!
13576
- * For correct drawing of objects that lie in the same plane, polygonOffset is used.
13577
- * https://www.khronos.org/registry/OpenGL-Refpages/gl4/html/glPolygonOffset.xhtml
13578
- * offset = factor * DZ + r * units
13579
- * Where DZ is a measurement of the change in depth relative to the screen area of the polygon,
13580
- * and r is an implementation-specific value to create a constant depth offset.
13581
- * The offset is added before the depth test is performed and before the value is written into the depth buffer.
13582
- *
13583
- * Factor parameter is redundant for this purpose, so only units parameter is used.
13600
+ /*
13601
+ * !polygonOffset!
13602
+ * For correct drawing of objects that lie in the same plane, polygonOffset is used.
13603
+ * https://www.khronos.org/registry/OpenGL-Refpages/gl4/html/glPolygonOffset.xhtml
13604
+ * offset = factor * DZ + r * units
13605
+ * Where DZ is a measurement of the change in depth relative to the screen area of the polygon,
13606
+ * and r is an implementation-specific value to create a constant depth offset.
13607
+ * The offset is added before the depth test is performed and before the value is written into the depth buffer.
13608
+ *
13609
+ * Factor parameter is redundant for this purpose, so only units parameter is used.
13584
13610
  */
13585
13611
 
13586
13612
  fiber.extend({
@@ -15019,10 +15045,10 @@ const SketchGroup = ({
15019
15045
  }))), isDisplayed && /*#__PURE__*/React.createElement(ContentSpace, null, children));
15020
15046
  };
15021
15047
 
15022
- /**
15023
- *
15024
- * @param ref reference to a div element; Its size will be used for calculations
15025
- * @returns object containing width, proposed side padding and margin for icons
15048
+ /**
15049
+ *
15050
+ * @param ref reference to a div element; Its size will be used for calculations
15051
+ * @returns object containing width, proposed side padding and margin for icons
15026
15052
  */
15027
15053
  const useLayoutSize = ref => {
15028
15054
  const {
@@ -16062,7 +16088,7 @@ const Constraints$1 = () => {
16062
16088
  })))));
16063
16089
  };
16064
16090
 
16065
- var css_248z$5 = ".handlers-dropdown .ant-dropdown-menu-root {\r\n border: 1px solid rgba(127, 127, 127, 1);\r\n border-top: 1px solid rgba(255, 255, 255, 1);\r\n border-radius: 0px;\r\n padding: 0px;\r\n margin-top: -2px;\r\n margin-left: -3px;\r\n}\r\n\r\n.handlers-dropdown .ant-dropdown-menu-root .ant-dropdown-menu-item {\r\n background-color: initial;\r\n padding: 0px;\r\n margin-top: 0px;\r\n}\r\n";
16091
+ var css_248z$5 = ".handlers-dropdown .ant-dropdown-menu-root {\n border: 1px solid rgba(127, 127, 127, 1);\n border-top: 1px solid rgba(255, 255, 255, 1);\n border-radius: 0px;\n padding: 0px;\n margin-top: -2px;\n margin-left: -3px;\n}\n\n.handlers-dropdown .ant-dropdown-menu-root .ant-dropdown-menu-item {\n background-color: initial;\n padding: 0px;\n margin-top: 0px;\n}\n";
16066
16092
  styleInject(css_248z$5);
16067
16093
 
16068
16094
  const _excluded$4 = ["handlerName", "sideEffect"];
@@ -16318,7 +16344,7 @@ const PlaneSelection = ({
16318
16344
  }));
16319
16345
  };
16320
16346
 
16321
- var css_248z$4 = ".contextmenu-submenu .ant-dropdown-menu-sub {\r\n border: 1px solid #e0e0e0;\r\n margin: -5px 0px 0px -2px;\r\n padding: 2px 0px;\r\n}\r\n\r\n.contextmenu-submenu .ant-dropdown-menu-sub .ant-dropdown-menu-item {\r\n padding: 2px 12px;\r\n}\r\n";
16347
+ var css_248z$4 = ".contextmenu-submenu .ant-dropdown-menu-sub {\n border: 1px solid #e0e0e0;\n margin: -5px 0px 0px -2px;\n padding: 2px 0px;\n}\n\n.contextmenu-submenu .ant-dropdown-menu-sub .ant-dropdown-menu-item {\n padding: 2px 12px;\n}\n";
16322
16348
  styleInject(css_248z$4);
16323
16349
 
16324
16350
  const _excluded$3 = ["items", "menuInfo", "caption", "icon", "onHide", "children"];
@@ -16910,8 +16936,8 @@ const ObjTitle = ({
16910
16936
  e.preventDefault();
16911
16937
  }, []);
16912
16938
 
16913
- /* const onMouseEnter = React.useCallback(() => {
16914
- hover(drawingId, pluginId, [objId])
16939
+ /* const onMouseEnter = React.useCallback(() => {
16940
+ hover(drawingId, pluginId, [objId])
16915
16941
  }, [drawingId, pluginId, objId]) */
16916
16942
 
16917
16943
  const onMouseLeave = React.useCallback(() => {
@@ -20161,11 +20187,11 @@ function useExpressionsParam() {
20161
20187
  });
20162
20188
  }
20163
20189
 
20164
- /**
20165
- * Validator for Expressions plugin. Checks drawing and currentProduct existance.
20166
- *
20167
- * @param drawingId
20168
- * @returns
20190
+ /**
20191
+ * Validator for Expressions plugin. Checks drawing and currentProduct existance.
20192
+ *
20193
+ * @param drawingId
20194
+ * @returns
20169
20195
  */
20170
20196
  const ExpressionsValidator = ({
20171
20197
  drawingId,
@@ -20235,11 +20261,11 @@ const SolverState = ({
20235
20261
  }, component);
20236
20262
  };
20237
20263
 
20238
- /**
20239
- * Shows list of 3d constraints which are contained by currentProduct.
20240
- *
20241
- * @param drawingId - id of a drawing in which currentProduct will be found.
20242
- * @returns
20264
+ /**
20265
+ * Shows list of 3d constraints which are contained by currentProduct.
20266
+ *
20267
+ * @param drawingId - id of a drawing in which currentProduct will be found.
20268
+ * @returns
20243
20269
  */
20244
20270
  const Constraints = ({
20245
20271
  drawingId
@@ -20413,11 +20439,11 @@ const List$2 = ({
20413
20439
  }))));
20414
20440
  };
20415
20441
 
20416
- /**
20417
- * Validator for Drawing component. Checks drawing existence.
20418
- *
20419
- * @param drawingId
20420
- * @returns
20442
+ /**
20443
+ * Validator for Drawing component. Checks drawing existence.
20444
+ *
20445
+ * @param drawingId
20446
+ * @returns
20421
20447
  */
20422
20448
  const DrawingValidator = ({
20423
20449
  drawingId,
@@ -20655,9 +20681,9 @@ function getMenuHeader(drawingId, objId) {
20655
20681
  };
20656
20682
  }
20657
20683
 
20658
- /**
20659
- * Goal of this component is to manage visibility of individual features when interacting with RollbackBar
20660
- * TODO: change the component name?
20684
+ /**
20685
+ * Goal of this component is to manage visibility of individual features when interacting with RollbackBar
20686
+ * TODO: change the component name?
20661
20687
  */
20662
20688
  const VisibilityController = ({
20663
20689
  drawingId,
@@ -20681,8 +20707,8 @@ const VisibilityController = ({
20681
20707
  return null;
20682
20708
  };
20683
20709
 
20684
- /**
20685
- * Goal of this component is to manage visibility of existing features when interacting with Selection or RollbackBar
20710
+ /**
20711
+ * Goal of this component is to manage visibility of existing features when interacting with Selection or RollbackBar
20686
20712
  */
20687
20713
  const FtVisibilityControllerImpl = ({
20688
20714
  drawingId
@@ -21603,7 +21629,7 @@ const draggableModalReducer = (state, action) => {
21603
21629
  }
21604
21630
  };
21605
21631
 
21606
- var css_248z$3 = "/**\r\n * NOTE: This is not compiled.\r\n */\r\n\r\n.ant-design-draggable-modal {\r\n pointer-events: none;\r\n overflow: hidden !important;\r\n}\r\n\r\n.ant-design-draggable-modal .ant-modal {\r\n display: flex;\r\n max-width: none;\r\n transform-origin: 50% 50% !important;\r\n}\r\n\r\n.ant-design-draggable-modal .ant-modal-content {\r\n flex: 1;\r\n display: flex;\r\n flex-direction: column;\r\n}\r\n\r\n.ant-design-draggable-modal .ant-modal-header {\r\n flex: 0;\r\n padding: 0;\r\n}\r\n\r\n.ant-design-draggable-modal .ant-modal-footer {\r\n flex: 0;\r\n padding: 16px;\r\n}\r\n\r\n.ant-design-draggable-modal .ant-design-draggable-modal-title {\r\n cursor: move;\r\n padding: 16px;\r\n}\r\n\r\n.ant-design-draggable-modal .ant-design-draggable-modal-title::before {\r\n content: '\\00a0';\r\n}\r\n\r\n.ant-design-draggable-modal .ant-modal-body {\r\n flex: 1;\r\n overflow-x: hidden;\r\n overflow-y: auto;\r\n padding: 16px;\r\n}\r\n\r\n.ant-design-draggable-modal-resize-handle-inner {\r\n width: 12px;\r\n right: 14px;\r\n border: 2px solid grey;\r\n height: 12px;\r\n bottom: 14px;\r\n position: absolute;\r\n border-top: 0;\r\n border-left: 0;\r\n}\r\n\r\n.ant-design-draggable-modal-resize-handle {\r\n right: -10px;\r\n width: 44px;\r\n bottom: -10px;\r\n cursor: se-resize;\r\n height: 44px;\r\n position: absolute;\r\n}\r\n";
21632
+ var css_248z$3 = "/**\n * NOTE: This is not compiled.\n */\n\n.ant-design-draggable-modal {\n pointer-events: none;\n overflow: hidden !important;\n}\n\n.ant-design-draggable-modal .ant-modal {\n display: flex;\n max-width: none;\n transform-origin: 50% 50% !important;\n}\n\n.ant-design-draggable-modal .ant-modal-content {\n flex: 1;\n display: flex;\n flex-direction: column;\n}\n\n.ant-design-draggable-modal .ant-modal-header {\n flex: 0;\n padding: 0;\n}\n\n.ant-design-draggable-modal .ant-modal-footer {\n flex: 0;\n padding: 16px;\n}\n\n.ant-design-draggable-modal .ant-design-draggable-modal-title {\n cursor: move;\n padding: 16px;\n}\n\n.ant-design-draggable-modal .ant-design-draggable-modal-title::before {\n content: '\\00a0';\n}\n\n.ant-design-draggable-modal .ant-modal-body {\n flex: 1;\n overflow-x: hidden;\n overflow-y: auto;\n padding: 16px;\n}\n\n.ant-design-draggable-modal-resize-handle-inner {\n width: 12px;\n right: 14px;\n border: 2px solid grey;\n height: 12px;\n bottom: 14px;\n position: absolute;\n border-top: 0;\n border-left: 0;\n}\n\n.ant-design-draggable-modal-resize-handle {\n right: -10px;\n width: 44px;\n bottom: -10px;\n cursor: se-resize;\n height: 44px;\n position: absolute;\n}\n";
21607
21633
  styleInject(css_248z$3);
21608
21634
 
21609
21635
  function ownKeys$3(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
@@ -22007,11 +22033,11 @@ const Feature = ({
22007
22033
  }, content) : /*#__PURE__*/React.createElement(React.Fragment, null, content);
22008
22034
  };
22009
22035
 
22010
- /**
22011
- * Validator for FeatureList component. Checks drawing and currentProduct existance.
22012
- *
22013
- * @param drawingId
22014
- * @returns
22036
+ /**
22037
+ * Validator for FeatureList component. Checks drawing and currentProduct existance.
22038
+ *
22039
+ * @param drawingId
22040
+ * @returns
22015
22041
  */
22016
22042
  const FeatureListValidator = ({
22017
22043
  drawingId,
@@ -22827,7 +22853,7 @@ const ListPlaceholder = () => {
22827
22853
  })));
22828
22854
  };
22829
22855
 
22830
- var css_248z$2 = ".header-dropdown .ant-dropdown-menu-root {\r\n margin-left: -10px;\r\n}\r\n";
22856
+ var css_248z$2 = ".header-dropdown .ant-dropdown-menu-root {\n margin-left: -10px;\n}\n";
22831
22857
  styleInject(css_248z$2);
22832
22858
 
22833
22859
  // TODO: Move to buerli/packages/react or buerli/packages/core
@@ -22861,16 +22887,16 @@ function readFile(file, type) {
22861
22887
  });
22862
22888
  }
22863
22889
 
22864
- /**
22865
- * Simple helper functions for file interaction.
22890
+ /**
22891
+ * Simple helper functions for file interaction.
22866
22892
  */
22867
22893
  const FileUtils = {
22868
- /**
22869
- * Loads a file from the file system.
22870
- * It uses @see document and is therefore directly dependent on the DOM.
22871
- *
22872
- * @param onLoad The callback.
22873
- * @param type The content type.
22894
+ /**
22895
+ * Loads a file from the file system.
22896
+ * It uses @see document and is therefore directly dependent on the DOM.
22897
+ *
22898
+ * @param onLoad The callback.
22899
+ * @param type The content type.
22874
22900
  */
22875
22901
  loadFile: (onLoad, type, multiple) => {
22876
22902
  const handler = event => {
@@ -22928,15 +22954,15 @@ const FileUtils = {
22928
22954
 
22929
22955
  const fileTypes = ['ofb', 'stp', 'stl'];
22930
22956
 
22931
- /**
22932
- * The model tree header.
22933
- *
22934
- * Responsibility:
22935
- * - Show name of current instance
22936
- * - Show back button
22937
- * - Show assembly node menu
22938
- * - Provide convert to template functionality
22939
- * - Provide import/add functionality
22957
+ /**
22958
+ * The model tree header.
22959
+ *
22960
+ * Responsibility:
22961
+ * - Show name of current instance
22962
+ * - Show back button
22963
+ * - Show assembly node menu
22964
+ * - Provide convert to template functionality
22965
+ * - Provide import/add functionality
22940
22966
  */
22941
22967
  const ModelTreeHeader = ({
22942
22968
  drawingId
@@ -23061,8 +23087,8 @@ const ModelTreeHeader = ({
23061
23087
  }));
23062
23088
  };
23063
23089
 
23064
- /**
23065
- * Modal dialog to define the name of the new created assembly tempate.
23090
+ /**
23091
+ * Modal dialog to define the name of the new created assembly tempate.
23066
23092
  */
23067
23093
  const NameChoice = ({
23068
23094
  drawingId,
@@ -23116,13 +23142,13 @@ const ModelTreeImpl = ({
23116
23142
  })), mode === exports.EditMode.None && /*#__PURE__*/React.createElement(ListPlaceholder, null));
23117
23143
  };
23118
23144
 
23119
- /**
23120
- * Component which shows structure of model.
23121
- * In part mode a list of part features is shown. In assembly mode a tree of assembly nodes is shown.
23122
- * It checks root and currentProduct to understand which mode is currently enabled. Check useEditMode hook for more details.
23123
- *
23124
- * @param drawingId
23125
- * @returns
23145
+ /**
23146
+ * Component which shows structure of model.
23147
+ * In part mode a list of part features is shown. In assembly mode a tree of assembly nodes is shown.
23148
+ * It checks root and currentProduct to understand which mode is currently enabled. Check useEditMode hook for more details.
23149
+ *
23150
+ * @param drawingId
23151
+ * @returns
23126
23152
  */
23127
23153
  const ModelTree = ({
23128
23154
  drawingId
@@ -23460,11 +23486,11 @@ const List = ({
23460
23486
  }))));
23461
23487
  };
23462
23488
 
23463
- /**
23464
- * Shows list of solids available in the current application context.
23465
- *
23466
- * @param drawingId - id of a drawing.
23467
- * @returns
23489
+ /**
23490
+ * Shows list of solids available in the current application context.
23491
+ *
23492
+ * @param drawingId - id of a drawing.
23493
+ * @returns
23468
23494
  */
23469
23495
  const Solids = ({
23470
23496
  drawingId
@@ -23525,7 +23551,7 @@ const SideBar = ({
23525
23551
  }));
23526
23552
  };
23527
23553
 
23528
- var css_248z$1 = ".toolbar-dropdown .ant-dropdown-menu-root {\r\n margin-left: -24px;\r\n}\r\n";
23554
+ var css_248z$1 = ".toolbar-dropdown .ant-dropdown-menu-root {\n margin-left: -24px;\n}\n";
23529
23555
  styleInject(css_248z$1);
23530
23556
 
23531
23557
  var img$B = "data:image/svg+xml,%3c%3fxml version='1.0' encoding='UTF-8'%3f%3e%3csvg width='100' height='100' version='1.1' viewBox='0 0 100 100' xmlns='http://www.w3.org/2000/svg'%3e %3cg stroke='black' stroke-width='5'%3e %3cpath d='m20 20 20 20c-37.015 3.8681-19.657 36.676 0 30l20-40c27.5 15 15 15 0 30l20 20' fill='none' stroke-linecap='round' stroke-linejoin='round' style='paint-order:stroke markers fill'/%3e %3cpath d='m88 80a8 8 0 0 1-8 8 8 8 0 0 1-8-8 8 8 0 0 1 8-8 8 8 0 0 1 8 8zm-60-60a8 8 0 0 1-8 8 8 8 0 0 1-8-8 8 8 0 0 1 8-8 8 8 0 0 1 8 8z' fill='white' style='paint-order:markers fill stroke'/%3e %3cpath d='m63 60a3 3 0 0 1-3 3 3 3 0 0 1-3-3 3 3 0 0 1 3-3 3 3 0 0 1 3 3zm0-30a3 3 0 0 1-3 3 3 3 0 0 1-3-3 3 3 0 0 1 3-3 3 3 0 0 1 3 3zm-20 40a3 3 0 0 1-3 3 3 3 0 0 1-3-3 3 3 0 0 1 3-3 3 3 0 0 1 3 3zm0-30a3 3 0 0 1-3 3 3 3 0 0 1-3-3 3 3 0 0 1 3-3 3 3 0 0 1 3 3z' style='paint-order:markers fill stroke'/%3e %3c/g%3e%3c/svg%3e";
@@ -24261,13 +24287,13 @@ const Header = ({
24261
24287
  })));
24262
24288
  };
24263
24289
 
24264
- /**
24265
- * Component which provides convenient UI for working with models which is loaded to existing drawing.
24266
- * It includes ModelTree, Constraints and Solids components and toolbar for creating new features/3dconstraints
24267
- * Drawing doesn't contain canvas component, so all graphics should be provided as children.
24268
- *
24269
- * @param drawingId - id of an existing drawing.
24270
- * @param Menu - you can pass custom file menu which will be shown at the left top corner.
24290
+ /**
24291
+ * Component which provides convenient UI for working with models which is loaded to existing drawing.
24292
+ * It includes ModelTree, Constraints and Solids components and toolbar for creating new features/3dconstraints
24293
+ * Drawing doesn't contain canvas component, so all graphics should be provided as children.
24294
+ *
24295
+ * @param drawingId - id of an existing drawing.
24296
+ * @param Menu - you can pass custom file menu which will be shown at the left top corner.
24271
24297
  */
24272
24298
  const Drawing = ({
24273
24299
  drawingId,
@@ -24305,16 +24331,16 @@ const Drawing = ({
24305
24331
  };
24306
24332
 
24307
24333
  const _excluded$1 = ["items", "children"];
24308
- /**
24309
- * Context menu. By default it's rendered as thee dots "...", when user hovers it the menuitems is shown.
24310
- * It's possible to show an icon instead of "..." - just render an icon you whant to show as a Menu child.
24311
- *
24312
- * If you want to have nested level of menu items you need to fill children prop of a menu item with SubMenuItems (check src/components/UI/CAD/plugin/ProductManagement/useMenuItems.tsx:"export")
24313
- *
24314
- * @param items - Object contains items you whant to show in the menu. An item should contain caption and callback, it also migh has optional props: icon and children.
24315
- * @param children - Any component which will be shown as a button which opens menu, if no children passed three dots "..." are shown.
24316
- * @param DropDownProps - Since Menu is implemented using DropDown from "antd" you can pass any of DropDown props (except 'overltay') to customize the menu.
24317
- * @returns
24334
+ /**
24335
+ * Context menu. By default it's rendered as thee dots "...", when user hovers it the menuitems is shown.
24336
+ * It's possible to show an icon instead of "..." - just render an icon you whant to show as a Menu child.
24337
+ *
24338
+ * If you want to have nested level of menu items you need to fill children prop of a menu item with SubMenuItems (check src/components/UI/CAD/plugin/ProductManagement/useMenuItems.tsx:"export")
24339
+ *
24340
+ * @param items - Object contains items you whant to show in the menu. An item should contain caption and callback, it also migh has optional props: icon and children.
24341
+ * @param children - Any component which will be shown as a button which opens menu, if no children passed three dots "..." are shown.
24342
+ * @param DropDownProps - Since Menu is implemented using DropDown from "antd" you can pass any of DropDown props (except 'overltay') to customize the menu.
24343
+ * @returns
24318
24344
  */
24319
24345
 
24320
24346
  const Menu = _ref => {
@@ -24668,7 +24694,7 @@ var index$g = /*#__PURE__*/Object.freeze({
24668
24694
  description: description$g
24669
24695
  });
24670
24696
 
24671
- var css_248z = "/*\r\n The only way to customize color picker from react-colorful is using css classes, so we need this file here.\r\n*/\r\n.colorPicker {\r\n padding: 6px;\r\n}\r\n\r\n.colorPicker .react-colorful {\r\n width: 100%;\r\n height: auto;\r\n}\r\n\r\n.colorPicker .react-colorful__saturation {\r\n width: 100%;\r\n height: auto !important;\r\n aspect-ratio: 1 / 1;\r\n border-radius: 4px 4px 0 0;\r\n}\r\n\r\n.colorPicker .react-colorful__hue {\r\n height: 20px;\r\n}\r\n\r\n.colorPicker .react-colorful__pointer {\r\n width: 20px;\r\n height: 20px;\r\n}\r\n\r\n.colorPicker .react-colorful__last-control {\r\n border-radius: 0 0 4px 4px;\r\n}\r\n";
24697
+ var css_248z = "/*\n The only way to customize color picker from react-colorful is using css classes, so we need this file here.\n*/\n.colorPicker {\n padding: 6px;\n}\n\n.colorPicker .react-colorful {\n width: 100%;\n height: auto;\n}\n\n.colorPicker .react-colorful__saturation {\n width: 100%;\n height: auto !important;\n aspect-ratio: 1 / 1;\n border-radius: 4px 4px 0 0;\n}\n\n.colorPicker .react-colorful__hue {\n height: 20px;\n}\n\n.colorPicker .react-colorful__pointer {\n width: 20px;\n height: 20px;\n}\n\n.colorPicker .react-colorful__last-control {\n border-radius: 0 0 4px 4px;\n}\n";
24672
24698
  styleInject(css_248z);
24673
24699
 
24674
24700
  function ownKeys$1(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
@@ -25209,11 +25235,11 @@ const Root$e = ({
25209
25235
  }));
25210
25236
  };
25211
25237
 
25212
- /**
25213
- * Validator for CSysDisplay component. Checks drawing and currentInstance existance.
25214
- *
25215
- * @param drawingId
25216
- * @returns
25238
+ /**
25239
+ * Validator for CSysDisplay component. Checks drawing and currentInstance existance.
25240
+ *
25241
+ * @param drawingId
25242
+ * @returns
25217
25243
  */
25218
25244
  const CSysDisplayValidator = ({
25219
25245
  drawingId,
@@ -28317,11 +28343,11 @@ const ProdList = ({
28317
28343
  }));
28318
28344
  };
28319
28345
 
28320
- /**
28321
- * Validator for ProductManagement plugin. Checks drawing, root, partContainer and AssemblyContainer existance.
28322
- *
28323
- * @param drawingId
28324
- * @returns
28346
+ /**
28347
+ * Validator for ProductManagement plugin. Checks drawing, root, partContainer and AssemblyContainer existance.
28348
+ *
28349
+ * @param drawingId
28350
+ * @returns
28325
28351
  */
28326
28352
  const ProductManagementValidator = ({
28327
28353
  drawingId,
@@ -28618,8 +28644,8 @@ const View = ({
28618
28644
  }));
28619
28645
  };
28620
28646
 
28621
- /**
28622
- * ProductManagement plugin is responsible for showing/creation/deletion parts and assemblies
28647
+ /**
28648
+ * ProductManagement plugin is responsible for showing/creation/deletion parts and assemblies
28623
28649
  */
28624
28650
  const description = {
28625
28651
  name: 'Product Management',
@@ -28731,8 +28757,8 @@ const RecalcIfChanged = ({
28731
28757
  return null;
28732
28758
  };
28733
28759
 
28734
- /**
28735
- * Contains combined visible plugin geometry bounding box
28760
+ /**
28761
+ * Contains combined visible plugin geometry bounding box
28736
28762
  */
28737
28763
  const PluginGeometryBounds = ({
28738
28764
  drawingId