import * as react from 'react'; import { RefObject } from 'react'; import { o as ObjectBinding, a1 as SceneConfig } from './rendererBackend-QwMzISTn.js'; import { B as BindingBuilderProps } from './publicProps-tJuWZgT3.js'; import { Object3D } from 'three'; import { l as ModelViewerProps } from './modelViewerProps-CIZ2R_Fv.js'; import './materialVariants-DnZe9eMC.js'; import './modelInfo-XfUQO7C_.js'; import '@react-three/drei'; declare const TEXTURE_KEYS: readonly ["texture", "metalnessMap", "roughnessMap", "emissiveMap", "alphaMap", "normalMap", "bumpMap", "aoMap", "displacementMap", "clearcoatMap", "clearcoatRoughnessMap", "clearcoatNormalMap", "anisotropyMap", "transmissionMap", "thicknessMap", "sheenColorMap", "sheenRoughnessMap", "specularIntensityMap", "specularColorMap"]; type MaterialTextureKey = (typeof TEXTURE_KEYS)[number]; /** * The full viewer's props: the public ones plus those only Liveroom's project * editor passes, through the "/hosted" entry. The published ModelViewer * (PublicModelViewer.tsx) drops the rest; publicProps.ts lists them. */ type ProjectModelViewerProps = ModelViewerProps & { /** * Validates the licence against this deployment's own API rather than the * licence service. The response must carry a grant signed by the licence * service, so this cannot approve a licence by itself. */ licenseValidationUrl?: string; /** Reports transform-gizmo edit leases for collaborative hosts. */ onObjectEditLeaseChange?: (binding: ObjectBinding, editing: boolean) => void; /** The loaded three.js scene, which the editor builds bindings from. */ onSceneLoaded?: (scene: Object3D) => void; /** * Reports the object and texture slot being repositioned in Move/Zoom mode * (double-click a textured object), or null once it ends, so the editor's * texture fields know positioning is live. */ onTexturePositioningChange?: (target: { objectKey: string; textureKey: MaterialTextureKey; } | null) => void; /** * Receives a function that ends Move/Zoom mode the way a plain canvas click * does, for the editor's own "Done positioning" button. */ endTexturePositioningRef?: RefObject<(() => void) | null>; }; declare function ProjectModelViewer(props: ProjectModelViewerProps): react.JSX.Element; type BindingBuilderProjectModel = { url: string; name?: string; assetId?: string | null; /** * Optional streamable model manifest. The current viewer uses `url`; large * model renderers can use this value without changing the saved project * shape. */ tilesetUrl?: string | null; assetVersion?: string | null; }; type BindingBuilderProject = { id: string; revision: number; model: BindingBuilderProjectModel; objectBindings: Record; sceneConfig: SceneConfig; }; type BindingBuilderProjectSnapshot = { projectId: string; baseRevision: number; model: BindingBuilderProjectModel; objectBindings: Record; sceneConfig: SceneConfig; }; type BindingBuilderProjectChangeOrigin = "local" | "remote"; /** * The full editor's props: the public ones plus those only Liveroom's project * editor passes, through the "/hosted" entry. The published BindingBuilder * (BindingBuilder.tsx) neither declares nor forwards the rest. */ type ProjectBindingBuilderProps = BindingBuilderProps & { /** * Validates the licence against this deployment's own API rather than the * licence service, so the public demo licence works on local and preview * deployments. The response must carry a grant signed by the licence * service, so this cannot approve a licence by itself. */ licenseValidationUrl?: string; /** * Optional server-backed project. When supplied, the editor hydrates from * this snapshot and applies newer revisions without remounting. */ project?: BindingBuilderProject | null; /** * Reports debounced, serializable editor snapshots. Persistence and * collaboration transports remain owned by the host application. */ onProjectChange?: (snapshot: BindingBuilderProjectSnapshot, origin: BindingBuilderProjectChangeOrigin) => void; /** Delay before reporting local project changes. Defaults to 350ms. */ projectChangeDebounceMs?: number; /** * Lets a hosted editor upload a selected model before it is loaded. Return * the durable model URL/version that should be saved with the project. */ onModelUpload?: (file: File) => Promise; onTextureUpload?: (file: File, objectId: string) => Promise; /** Requests/releases a short collaborative lease around gizmo edits. */ onEditLeaseChange?: (featureId: string, editing: boolean) => void; /** * Whether the model itself may be replaced or removed. False hides the * Remove model and Upload controls and ignores picked or dropped files; * bindings and scene settings stay editable. Defaults to true. Remove model * never appears with a `project`, which always has a model. */ allowModelChange?: boolean; }; declare function ProjectBindingBuilder({ licenseKey, licenseValidationUrl, dracoDecoderPath, ktx2TranscoderPath, meshopt, project, onProjectChange, projectChangeDebounceMs, onModelUpload, onTextureUpload, onEditLeaseChange, allowModelChange, }: ProjectBindingBuilderProps): react.JSX.Element; export { type BindingBuilderProject, type BindingBuilderProjectChangeOrigin, type BindingBuilderProjectModel, type BindingBuilderProjectSnapshot, ProjectBindingBuilder, type ProjectBindingBuilderProps, ProjectModelViewer, type ProjectModelViewerProps };