vis-core 0.33.14 → 0.33.15

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.
package/dist/index.d.ts CHANGED
@@ -4678,7 +4678,12 @@ export declare function remapProjectMaterialIds<T extends VisSceneDocument>(docu
4678
4678
  * 复制一组场景并为它们分配新 ID,同时保持文档内部的场景跳转关系。
4679
4679
  * 用于把完整模板追加到另一个场景文档中。
4680
4680
  */
4681
- export declare function remapSceneDocumentIds(document: VisSceneDocument, createSceneId: (scene: SceneViewportDocument, index: number) => string): RemappedSceneDocument;
4681
+ export declare function remapSceneDocumentIds(document: VisSceneDocument, createSceneId: (scene: SceneViewportDocument, index: number) => string, options?: {
4682
+ /** Leave authored definitions in the library until the selected scene loads. */
4683
+ materialize?: boolean;
4684
+ /** Resolve cross-project material collisions in the same ownership pass. */
4685
+ occupiedMaterialIds?: Iterable<string>;
4686
+ }): RemappedSceneDocument;
4682
4687
 
4683
4688
  export declare const remapSceneMaterialReferencesCopy: <T>(scene: T, previous: string, next: string) => T;
4684
4689
 
@@ -4872,6 +4877,8 @@ declare class ResourceScope {
4872
4877
  }
4873
4878
 
4874
4879
  declare interface RestoreBaseObjectOptions {
4880
+ /** Image loading boundaries, before native materials and scene objects are restored. */
4881
+ onResourceLoad?: (phase: 'start' | 'done') => void | Promise<void>;
4875
4882
  /** Transfer an exclusively owned snapshot between packages; restoration may mutate it. */
4876
4883
  consumeInput?: boolean;
4877
4884
  /** The caller must validate equality with the serialized resource definitions. */
@@ -5103,7 +5110,12 @@ export declare class SceneManager extends Event_2 {
5103
5110
  commitSceneStructure(prepared: PreparedSceneStructure): void;
5104
5111
  /** Commit scalar material history without accepting or copying caller object graphs. */
5105
5112
  patchMaterialDefinitions(assets: MaterialAsset[], scenes: Pick<SceneViewportDocument, 'id'>[], scope?: MaterialDefinitionScope): void;
5106
- load(documentOrUrl: VisSceneDocument | VisSceneManifest | string, hooks?: Record<string, any>): Promise<Base_3>;
5113
+ load(documentOrUrl: VisSceneDocument | VisSceneManifest | string, hooks?: Record<string, any>, options?: {
5114
+ /** Transfer a detached document to the manager; the caller must not mutate it afterwards. */
5115
+ consumeInput?: boolean;
5116
+ /** Restore a saved active scene without changing the project's entry scene. */
5117
+ sceneId?: string;
5118
+ }): Promise<Base_3>;
5107
5119
  /**
5108
5120
  * 创建一个没有快照输入的运行时页面,并在可选构建步骤完成后将其导出为
5109
5121
  * 标准单场景文档。主要供编辑器新建和旧模板迁移使用。
@@ -5398,18 +5410,22 @@ export declare interface SceneStructurePatch {
5398
5410
  set?: Partial<Record<SceneStructureGraphKey, any>>;
5399
5411
  unset?: SceneStructureGraphKey[];
5400
5412
  };
5413
+ /** Optional order lists every final row identity, including unchanged rows. */
5401
5414
  resources?: Partial<Record<SceneStructureResource, {
5402
5415
  upsert?: Record<string, any>[];
5403
5416
  remove?: string[];
5417
+ order?: string[];
5404
5418
  unset?: true;
5405
5419
  }>>;
5406
5420
  assets?: {
5407
5421
  upsert?: MaterialAsset[];
5408
5422
  remove?: string[];
5423
+ order?: string[];
5409
5424
  };
5410
5425
  prefabs?: {
5411
5426
  upsert?: PrefabAsset[];
5412
5427
  remove?: string[];
5428
+ order?: string[];
5413
5429
  };
5414
5430
  }
5415
5431
 
@@ -5811,7 +5827,7 @@ declare class UseMaterial extends PointerEvent_2 {
5811
5827
 
5812
5828
  declare type ValuesOf<T extends readonly any[]> = T[number];
5813
5829
 
5814
- export declare const VERSION = "0.33.14";
5830
+ export declare const VERSION = "0.33.15";
5815
5831
 
5816
5832
  declare interface Viewport {
5817
5833
  left: number;