@manycore/custom-sdk 2.1.0 → 3.0.0-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 (3) hide show
  1. package/index.d.ts +17 -152
  2. package/index.js +15 -15
  3. package/package.json +1 -1
package/index.d.ts CHANGED
@@ -1,4 +1,3 @@
1
- import { IExportModelData } from '@manycore/custom-miniapp-sdk';
2
1
  import { IParamModelPhotoResponse } from '@manycore/custom-miniapp-sdk';
3
2
  import { IServClientService } from 'servkit';
4
3
  import { Number2 as Number2_2 } from '@manycore/custom-miniapp-sdk';
@@ -755,38 +754,6 @@ export declare enum EProductDirection {
755
754
  XZ = 2
756
755
  }
757
756
 
758
- /**
759
- * 处理选中的内容
760
- */
761
- export declare enum ESelectedType {
762
- /**
763
- * 未选中模型
764
- */
765
- NULL = 0,
766
- /**
767
- * 模型或商品
768
- */
769
- MODEL = 1,
770
- /**
771
- * 五金信息
772
- */
773
- CASBIN = 2
774
- }
775
-
776
- /**
777
- * 设置选中内容类型
778
- */
779
- export declare enum ESetSelectType {
780
- /**
781
- * 模型或商品
782
- */
783
- MODEL = 1,
784
- /**
785
- * 五金
786
- */
787
- CASBIN = 2
788
- }
789
-
790
757
  /**
791
758
  * 定制行业工具线
792
759
  */
@@ -847,6 +814,16 @@ export declare enum ETriggerType {
847
814
  DB_CLICK = 'double_click',
848
815
  }
849
816
 
817
+ /** @ignore */
818
+ export declare enum Face {
819
+ Bottom = 'bottom',
820
+ Front = 'front',
821
+ Left = 'left',
822
+ Right = 'right',
823
+ Back = 'back',
824
+ Top = 'top',
825
+ }
826
+
850
827
  /**
851
828
  * 附加通用参数-几何体颜色key
852
829
  * @default 孔:0x00ff00 槽:0x1e90ff 五金槽:0x1e90ff
@@ -2665,34 +2642,6 @@ export declare class FittingDesignService extends BaseService {
2665
2642
  */
2666
2643
  export declare type ISceneSelectOption = IElement;
2667
2644
 
2668
- /**
2669
- * 当前选中的数据
2670
- */
2671
- export declare interface ISelected {
2672
- /**
2673
- * 选中的数据内容
2674
- */
2675
- data: IExportModelData[] | IHardwareData[];
2676
- /**
2677
- * 选中的数据类型
2678
- */
2679
- type: ESelectedType;
2680
- }
2681
-
2682
- /**
2683
- * 通过ID选中模型参数
2684
- */
2685
- export declare interface ISetSelectedByIdOption {
2686
- /**
2687
- * 模型ID/五金ID
2688
- */
2689
- id: string;
2690
- /**
2691
- * 选中的类型
2692
- */
2693
- type: ESetSelectType;
2694
- }
2695
-
2696
2645
  /**
2697
2646
  * 场景中,模型的颜色配置能力
2698
2647
  *
@@ -3122,6 +3071,12 @@ export declare class FittingDesignService extends BaseService {
3122
3071
  * ```
3123
3072
  */
3124
3073
  moveCamera(direction: ECameraMoveDirection): void;
3074
+ /**
3075
+ * 相机视角调整
3076
+ * @param face
3077
+ * @ignore
3078
+ */
3079
+ focusFace(face: Face): void;
3125
3080
  }
3126
3081
 
3127
3082
  /**
@@ -3249,6 +3204,7 @@ export declare class FittingDesignService extends BaseService {
3249
3204
  * ```
3250
3205
  *
3251
3206
  * @param options
3207
+ * @deprecated 该API即将废弃,后续不再维护,请使用`IDP.Custom.Design.Export.getModelJsonAsyncV2` API代替,可获得更好的性能优化
3252
3208
  */
3253
3209
  getParamData(options?: IGetParamModelJsonOption): Promise<any>;
3254
3210
  /**
@@ -3298,97 +3254,6 @@ export declare class FittingDesignService extends BaseService {
3298
3254
  }): Promise<IModelValidateResult | undefined>;
3299
3255
  }
3300
3256
 
3301
- /**
3302
- * 主要是用来与场景交互的,监听当前选中的对象, 获取选中的内容
3303
- *
3304
- * @example
3305
- * ```typescript
3306
- * const viewerSelectionService = application.getService(ModelViewerSelectionService);
3307
- * ```
3308
- */
3309
- export declare class ModelViewerSelectionService extends BaseService {
3310
- /**
3311
- * if watch EVENT_SELECT_CHANGED event
3312
- *
3313
- * @ignore
3314
- */
3315
- private hasWatchSelectionChange;
3316
- /**
3317
- * 获取当前选中的数据
3318
- */
3319
- getSelected(): ISelected;
3320
- /**
3321
- * 设置选中的模型
3322
- * 同时选中多个模型暂未支持,请勿使用
3323
- * @param option ISetSelectedByIdOption
3324
- * @example
3325
- * ```
3326
- * const viewerSelectionService = application.getService(ModelViewerSelectionService);
3327
- * const selectOption = {
3328
- * id: 'modelId...',
3329
- * type: ESetSelectType.MODEL,
3330
- * };
3331
- *
3332
- * viewerSelectionService.select(selectOption);
3333
- * ```
3334
- */
3335
- select(option: ISetSelectedByIdOption | ISetSelectedByIdOption[]): void;
3336
- /**
3337
- * 取消场景当中选中内容
3338
- * 同时取消多个模型暂未支持,请勿使用
3339
- * @param option
3340
- * @example
3341
- * ```
3342
- * const viewerSelectionService = application.getService(ModelViewerSelectionService);
3343
- * const selectOption = {
3344
- * id: 'modelId...',
3345
- * type: ESetSelectType.MODEL,
3346
- * };
3347
- *
3348
- * // 取消指定选中模型
3349
- * viewerSelectionService.unSelect(selectOption);
3350
- * // 默认取消全部选中模型
3351
- * viewerSelectionService.unSelect();
3352
- * ```
3353
- */
3354
- unSelect(option?: ISetSelectedByIdOption | ISetSelectedByIdOption[]): void;
3355
- /**
3356
- * 根据参数生成entity
3357
- * @param option
3358
- * @returns entity
3359
- * @private
3360
- * @ignore
3361
- */
3362
- private __generateEntity;
3363
- /**
3364
- * @ignore
3365
- */
3366
- private startWatchSelectedChangedEvent;
3367
- /**
3368
- * @ignore
3369
- */
3370
- private onSelectedChanged;
3371
- /**
3372
- * 监听当前选中内容
3373
- * @param fn
3374
- */
3375
- on(fn: (param: ISelected) => any): void;
3376
- /**
3377
- * 取消监听选中变化
3378
- * @param fn
3379
- */
3380
- off(fn?: (param: ISelected) => any): void;
3381
- /**
3382
- * 监听当前选中的内容(触发一次后自动取消)
3383
- * @param fn
3384
- */
3385
- once(fn: (param: ISelected) => any): void;
3386
- /**
3387
- * @ignore
3388
- */
3389
- __onDestroy(): void;
3390
- }
3391
-
3392
3257
  /**
3393
3258
  * ModelViewerSelectionService v2版本: 作为范围为场景内五金孔槽、参数化组合、参数化模型
3394
3259
  *