import * as react from 'react'; import { ReactNode } from 'react'; import { P as ModelViewerProps, Z as SemanticComparisonOptions, v as ConfigurationComparisonReport, a3 as ViewerCameraProps, a8 as ViewerReadyState, l as CaptureImageOptions, m as CaptureVideoOptions, a6 as ViewerObjectInfo, a1 as UseViewerCameraOptions, _ as ShareableViewerState, a4 as ViewerConfiguration, aa as ViewerStateStorage, K as ModelViewerModelEntry, k as AssetTransform, h as AssetDiagnosticsReport, a9 as ViewerRuntimeStats } from './modelViewerProps-H_K454u_.js'; export { A as ARExportOptions, a as ARHandoffOptions, b as ARHandoffRequest, c as ARHandoffStatus, d as ARSnapshot, e as ARSnapshotSource, f as AnnotationMarker, g as AssetDiagnosticIssue, i as AssetDiagnosticsSource, j as AssetTextureDiagnostic, C as CameraControllerType, n as CinematicConfig, o as CinematicWaypoint, p as ComparisonCategory, q as ComparisonChange, r as ComparisonHighlight, s as ComparisonObject, t as ComparisonStatus, u as ConfigurationComparisonInput, w as CustomObjectBindingDataPanelProps, x as CustomSceneObjectsPanelProps, D as DecalMoveTarget, F as FocusObjectOptions, G as GroupedModelViewerProps, H as HomeCameraState, I as InspectAssetOptions, L as LicenseResult, y as LicenseStatus, M as MAX_VIEWER_STATE_BYTES, z as MODEL_VIEWER_PRESETS, B as ModelMergeSource, E as ModelViewerControlsOptions, J as ModelViewerDecoderOptions, N as ModelViewerPerfOptions, O as ModelViewerPreset, Q as ModelViewerTilesOptions, R as ModelViewerToolsOptions, S as ModelViewerUiOptions, T as ModelViewerXrOptions, U as MouseControllerPosition, V as ObjectTransformSpace, W as PerformanceProfile, X as RendererBackend, $ as StreamingDiagnostics, a0 as TexturePositioningControls, a2 as ViewerCameraPreset, a5 as ViewerEngagementEvent, a7 as ViewerProductOptions, ab as XRScaleMode, ac as compareViewerConfigurations, ad as groundAsset, ae as parseAssetTransform, af as parseViewerState, ag as prepareViewerState, ah as serializeViewerState, ai as snapAssetToGrid, aj as useViewerCamera } from './modelViewerProps-H_K454u_.js'; import { P as ObjectBinding, _ as ObjectBindingTarget, W as ObjectBindingPatch, B as BindingEdit, T as ObjectBindingMaterial, a0 as ObjectBindingTextureSlot, $ as ObjectBindingTextureChannel, a1 as ObjectBindingTransform, S as ObjectBindingDecal, aE as SceneConfig, aG as SceneConfigPatch, aJ as SceneLight, aK as SceneLightAttachment, bh as ViewerIsolation, Q as ObjectBindingAction, N as ObjectActionEvent, be as ViewerAnimationsProps, bj as ViewerModelBounds, p as MaterialVariantGroup, bk as ViewerModelInfo, bg as ViewerCameraState, af as ProductDefinition, ad as ProductConfiguration, am as ProductOptionState, ap as ProductSelections, an as ProductPrice, a7 as ProductAvailability, ac as ProductCommerceResult, aa as ProductCommerceAdapter, b3 as SequenceControls, b7 as SequencePlaybackState } from './modelFileResolver-An1aQ0D3.js'; export { A as AnimationAction, a as AnimationActionEffect, b as AnimationClipInfo, c as AnimationClipState, d as AnimationClipStatus, e as AnimationControls, f as AnimationLoopMode, g as AnimationPlayOptions, h as AnimationPlaybackState, C as CameraAction, i as CameraActionEffect, j as CameraLimits, D as DEFAULT_MODEL_VIEWER_LABELS, k as DEFAULT_SCENE_CONFIG, l as DEFAULT_SECTION_CONFIG, m as DeepPartial, E as EnvironmentPreset, F as FloorOutline, G as GlitchModeName, I as IsolatedObjectBindings, n as IsolationActionEffect, K as KernelSizeName, M as MATERIAL_BLENDING_MODES, o as MATERIAL_SIDES, q as MaterialVariantOption, r as MeasurementAnchor, s as MeasurementCollection, t as MeasurementPoint, u as MeasurementPosition, v as MeasurementResult, w as MeasurementSettings, x as MeasurementStatus, y as MeasurementTool, z as MeasurementUnit, H as ModelFormat, J as ModelViewerLabelKey, L as ModelViewerLabels, O as ObjectActionEffect, R as ObjectBindingCameraState, U as ObjectBindingMaterialBlendingMode, V as ObjectBindingMaterialSide, X as ObjectBindingSelector, Y as ObjectBindingStatus, Z as ObjectBindingStyle, a2 as ObjectBindingType, a3 as ObjectBindingsActionEffect, a4 as ObjectPointerEvent, a5 as ObjectSurfacePoint, a6 as ProductAppearance, a8 as ProductCheckoutContext, a9 as ProductCheckoutLink, ab as ProductCommerceContext, ae as ProductConfigurationIssue, ag as ProductDefinitionWarning, ah as ProductGroupDisplay, ai as ProductOption, aj as ProductOptionGroup, ak as ProductOptionRef, al as ProductOptionRule, ao as ProductPricing, aq as ProductSku, ar as RampTypeName, as as ReducedMotionSetting, at as SavedMeasurement, au as SceneAnimationClipConfig, av as SceneAnimationConfig, aw as SceneAnnotationCameraView, ax as SceneAnnotationImage, ay as SceneAnnotationLink, az as SceneAnnotationMarker, aA as SceneBackgroundConfig, aB as SceneCameraConfig, aC as SceneCinematicConfig, aD as SceneCinematicWaypoint, aF as SceneConfigActionEffect, aH as SceneEnvironmentConfig, aI as SceneGroundShadowConfig, aL as SceneLightType, aM as SceneLightingConfig, aN as SceneModelConfig, aO as SceneModelRenderer, aP as ScenePostProcessingConfig, aQ as SceneProductConfig, aR as SceneSectionAxis, aS as SceneSectionConfig, aT as SceneSectionPlane, aU as SceneSectionPreset, aV as SceneSectionSettings, aW as SceneSelectionSet, aX as SceneSequence, aY as SceneShadowConfig, aZ as SceneStyleColorScale, a_ as SceneStyleCondition, a$ as SceneStylePulse, b0 as SceneStyleRule, b1 as SceneWireframeConfig, b2 as SequenceCameraView, b4 as SequenceEasing, b5 as SequenceKeyframe, b6 as SequenceObjectProperty, b8 as SequenceTarget, b9 as SequenceTrack, ba as SequenceValue, bb as SequenceVector3, bc as StyledObjectBindings, bd as StyledObjectPulse, bf as ViewerCameraConfig, bi as ViewerLoading, bl as ViewerReveal, bm as VisibilityActionEffect, bn as applyIsolation, bo as applyStyleRules, bp as chooseMaterialVariant, bq as colorScaleValue, br as isolatedBindingKeys, bs as material, bt as parseSelectionSets, bu as patchBindings, bv as patchSceneConfig, bw as selectBindingKeys, bx as selectBindings, by as useViewerAnimations } from './modelFileResolver-An1aQ0D3.js'; import { SceneLightInput } from './utils.js'; export { ACTION_CATALOG, ActionCatalogEntry, ActionHandling, MEASUREMENT_UNITS, ObjectBindingActionId, ObjectBindingKey, SEQUENCE_EASINGS, SEQUENCE_OBJECT_PROPERTIES, ViewerHierarchyNode, applyProductOptions, buildBindingsFromNodes, calibrateMeasurements, collectObjectHierarchy, copyBindingStyle, createARHandoffUrl, createDefaultBinding, decodeProductSelections, defaultProductSelections, defineObjectBindings, encodeProductSelections, evaluateProductConfiguration, exportConfiguredUSDZ, findCatalogAction, formatProductPrice, generateProductSkus, inferType, inspectAsset, measurementResult, measurementScale, measurementValue, measurementsToCsv, parseMeasurements, parseProductConfiguration, parseProductDefinition, parseSceneProduct, parseSectionConfig, parseSequences, pasteBindingStyle, productCheckoutUrl, productDefinitionWarnings, productOptionStates, productPriceFromDefinition, readARHandoffUrl, resolveProductSelections, sampleSequenceTrack, sceneLight, sectionSnapshot, serializeMeasurements, serializeProductConfiguration, upsertSequenceKeyframe } from './utils.js'; import 'three'; import '@react-three/drei'; declare function PublicModelViewer(props: ModelViewerProps): react.JSX.Element; /** One side of a comparison: any ModelViewer props, over the shared ones. */ type CompareViewerSide = Partial & { /** Shown over this side. Defaults to "Before" and "After". */ label?: string; }; type CompareViewerProps = Partial & { licenseKey: string; /** Opt in to authored object/scene change details and bounds outlines. */ semanticComparison?: boolean | SemanticComparisonOptions; /** Show colored comparison bounds. Default true; controlled when supplied. */ showComparisonOutlines?: boolean; onComparisonOutlinesChange?: (enabled: boolean) => void; /** Inspect both sides with the same cut. Defaults to true with semantic comparison. */ linkSections?: boolean; onComparisonChange?: (report: ConfigurationComparisonReport) => void; /** The left side: the shared props with these on top. */ before: CompareViewerSide; /** The right side. */ after: CompareViewerSide; /** * `"slider"` lays the two views over each other with a divider to drag * across; `"side-by-side"` shows them next to each other. Default * `"slider"`. */ layout?: "slider" | "side-by-side"; /** Where the slider's divider is, from 0 (left edge) to 1. Default 0.5. */ split?: number; onSplitChange?: (split: number) => void; }; /** * Two ModelViewers showing two configurations of a model (or two models) with * one camera: moving either view moves both. */ declare function CompareViewer(props: CompareViewerProps): react.JSX.Element; type HiddenObjectsState = Record; type ObjectBindingsController = { objectBindings: Record; setObjectBindings: React.Dispatch>>; updateObjectBindings: { (target: ObjectBindingTarget, patch: ObjectBindingPatch): void; (edits: BindingEdit[]): void; }; setMaterial: (target: ObjectBindingTarget, material: ObjectBindingMaterial) => void; setBaseColor: (target: ObjectBindingTarget, color: string) => void; setTexture: (target: ObjectBindingTarget, texture: string | ObjectBindingTextureSlot, channel?: ObjectBindingTextureChannel) => void; clearTexture: (target: ObjectBindingTarget, channel?: ObjectBindingTextureChannel) => void; copyMaterial: (source: string, target: ObjectBindingTarget) => void; resetMaterial: (target: ObjectBindingTarget) => void; getMaterial: (objectId: string) => ObjectBindingMaterial | null; setTransform: (target: ObjectBindingTarget, transform: ObjectBindingTransform) => void; resetTransform: (target: ObjectBindingTarget) => void; updateMetadata: (target: ObjectBindingTarget, metadata: Record) => void; /** * Prints an image or text on the target objects and returns the decal's id * (the one passed, or a generated one). */ addDecal: (target: ObjectBindingTarget, decal: Omit & { id?: string; }) => string; updateDecal: (target: ObjectBindingTarget, decalId: string, patch: Partial>) => void; removeDecal: (target: ObjectBindingTarget, decalId: string) => void; selectObjectBindings: (target: ObjectBindingTarget) => ObjectBinding[]; selectObjectBindingIds: (target: ObjectBindingTarget) => string[]; hiddenObjects: HiddenObjectsState; hiddenObjectIds: string[]; hideObject: (target: ObjectBindingTarget) => void; showObject: (target: ObjectBindingTarget) => void; toggleObjectVisibility: (target: ObjectBindingTarget) => void; isObjectHidden: (objectId: string) => boolean; clearHiddenObjects: () => void; }; /** * Owns object-binding state and exposes field-level, material, and visibility * operations over the same functional state updater. * * Consecutive calls in the same tick compose instead of overwriting each other, * including calls across material and visibility concerns. */ declare function useObjectBindings(initialBindings: Record | (() => Record)): ObjectBindingsController; type SceneConfigUpdate = SceneConfigPatch | ((current: SceneConfig) => SceneConfigPatch); type SceneConfigController = { sceneConfig: SceneConfig; setSceneConfig: React.Dispatch>; updateSceneConfig: (update: SceneConfigUpdate) => void; resetSceneConfig: () => void; lights: SceneLightsController; }; type SceneLightPatch = Partial>; type SceneLightsController = { items: SceneLight[]; get: (id: string) => SceneLight | undefined; add: (light: SceneLightInput) => void; update: (id: string, patch: SceneLightPatch) => void; remove: (id: string) => void; setIntensity: (id: string, intensity: number) => void; setColor: (id: string, color: string) => void; show: (id: string) => void; hide: (id: string) => void; toggle: (id: string) => void; attach: (id: string, attachment: SceneLightAttachment) => void; detach: (id: string) => void; }; /** * Owns scene-config state and applies nested patches through functional React * updates, so consecutive calls in the same tick compose safely. */ declare function useSceneConfig(initialSceneConfig: SceneConfig | (() => SceneConfig)): SceneConfigController; type ViewerIsolationProps = { /** The current isolation, or `null` when every object shows normally. */ isolation: ViewerIsolation | null; /** Focuses on the target's objects, ghosting (or hiding) the rest. */ isolate: (target: ObjectBindingTarget, options?: Omit) => void; clearIsolation: () => void; /** Pass to `ModelViewer`'s `onIsolationChange`. */ handleIsolationChange: (isolation: ViewerIsolation | null) => void; }; /** * State for `ModelViewer`'s `isolation` prop: * * ```tsx * const isolation = useViewerIsolation(); * ; * isolation.isolate({ group: "engine" }); * ``` */ declare function useViewerIsolation(initialIsolation?: ViewerIsolation | null): ViewerIsolationProps; type ViewerActionBindingsController = Pick; type ViewerActionSceneController = Pick; type ViewerActionCameraController = Pick; type ViewerActionAnimationController = Pick; type ViewerActionIsolationController = Pick; type ViewerActionsOptions = { bindings: ViewerActionBindingsController; scene?: ViewerActionSceneController; camera?: ViewerActionCameraController; animations?: ViewerActionAnimationController; isolation?: ViewerActionIsolationController; onAction?: (event: ObjectActionEvent) => void | Promise; }; type ViewerActionsProps = { getActionsForObject: (objectId: string) => ObjectBindingAction[]; handleAction: (event: ObjectActionEvent) => Promise; runAction: (objectId: string, actionId: string) => Promise; }; /** * Resolves object actions and executes their declarative binding, scene, * visibility, camera, and animation effects in declaration order. */ declare function useViewerActions({ bindings, scene, camera, animations, isolation, onAction, }: ViewerActionsOptions): ViewerActionsProps; type ViewerReadyHandler = (viewer: ViewerReadyState) => void; type ViewerReadyConsumer = ViewerReadyHandler | { handleViewerReady: ViewerReadyHandler; } | null | undefined; type ViewerConnectionController = { /** The single callback to pass to ModelViewer's onViewerReady prop. */ handleViewerReady: ViewerReadyHandler; /** Returns the latest live viewer without causing camera-change rerenders. */ getViewer: () => ViewerReadyState | null; /** Fly to a visible annotation and open its card. False before readiness or for an unavailable ID. */ goToAnnotation: (annotationId: number) => Promise; /** Start AR from a user gesture. False when unavailable/not ready; launch errors reject. */ startAR: () => Promise; /** Captures the connected viewer, or rejects when it is not ready yet. */ captureImage: (options?: CaptureImageOptions) => Promise; /** Records the connected viewer, or rejects when not ready/unsupported. */ captureVideo: (options?: CaptureVideoOptions) => Promise; /** Requests a frame from the connected viewer. */ invalidate: () => boolean; }; /** * Composes camera, effects, and custom viewer-ready consumers into one typed * ModelViewer connection. Pass the returned handleViewerReady to ModelViewer. */ declare function useViewerConnection(...consumers: readonly ViewerReadyConsumer[]): ViewerConnectionController; type ViewerEffectTarget = ObjectBindingTarget; type ViewerVector3 = readonly [number, number, number]; type ViewerEffectRange = readonly [number, number]; type RuntimeMaterialPatch = { baseColor?: string; emissive?: string; emissiveIntensity?: number; opacity?: number; metalness?: number; roughness?: number; transmission?: number; clearcoat?: number; clearcoatRoughness?: number; ior?: number; thickness?: number; transparent?: boolean; }; type RuntimeTransformPatch = { position?: ViewerVector3; rotation?: ViewerVector3; scale?: ViewerVector3 | number; visible?: boolean; }; type RuntimeMaterialRanges = Partial>; type RuntimeTransformRanges = { position?: readonly [ViewerVector3, ViewerVector3]; rotation?: readonly [ViewerVector3, ViewerVector3]; scale?: readonly [ViewerVector3, ViewerVector3]; }; type ViewerMaterialEffectChannel = { targets: ViewerEffectTarget; values: RuntimeMaterialRanges; }; type ViewerTransformEffectChannel = { targets: ViewerEffectTarget; values: RuntimeTransformRanges; }; type ViewerLightEffectChannel = { lights: string | readonly string[]; intensity: ViewerEffectRange; }; type ViewerEffectChannels = { materials?: ViewerMaterialEffectChannel[]; transforms?: ViewerTransformEffectChannel[]; lights?: ViewerLightEffectChannel[]; }; type ViewerEffectEasing = "linear" | "ease-in" | "ease-out" | "ease-in-out"; type ViewerTransitionOptions = { id?: string; duration?: number; easing?: ViewerEffectEasing; onComplete?: () => void; }; type ViewerTimelineStep = { channels: ViewerEffectChannels; duration: number; hold?: number; easing?: ViewerEffectEasing; }; type ViewerTimelineOptions = { id?: string; repeat?: number; onComplete?: () => void; }; type ViewerPulseOptions = { id?: string; duration?: number; minLevel?: number; maxLevel?: number; repeat?: number; synchronized?: boolean; onComplete?: () => void; }; type ViewerFlickerOptions = { id?: string; minLevel?: number; maxLevel?: number; interval?: number | ViewerEffectRange; response?: number; blackoutChance?: number; flashChance?: number; flashLevel?: number; synchronized?: boolean; duration?: number; onComplete?: () => void; }; type RuntimePointLightOptions = { id: string; target: string; color?: string; intensity?: number; distance?: number; decay?: number; offset?: ViewerVector3; castShadow?: boolean; }; type RuntimePointLightPatch = Partial>; type UseViewerEffectsOptions = { onViewerReady?: (viewer: ViewerReadyState) => void; }; type ViewerEffectsController = { handleViewerReady: (viewer: ViewerReadyState) => void; setMaterial: (target: ViewerEffectTarget, patch: RuntimeMaterialPatch) => boolean; setTransform: (target: ViewerEffectTarget, patch: RuntimeTransformPatch) => boolean; getWorldPosition: (target: string) => ViewerVector3 | null; addPointLight: (options: RuntimePointLightOptions) => boolean; updatePointLight: (id: string, patch: RuntimePointLightPatch) => boolean; removePointLight: (id: string) => boolean; transition: (channels: ViewerEffectChannels, options?: ViewerTransitionOptions) => string; timeline: (steps: readonly ViewerTimelineStep[], options?: ViewerTimelineOptions) => string; pulse: (channels: ViewerEffectChannels, options?: ViewerPulseOptions) => string; flicker: (channels: ViewerEffectChannels, options?: ViewerFlickerOptions) => string; overrideEffect: (id: string, level: number, duration: number) => boolean; stopEffect: (id: string) => boolean; stopAllEffects: () => void; resetRuntime: () => void; }; /** * Applies live material, transform, and point-light effects without putting * frame-by-frame values in React state or exposing Three.js objects to the app. */ declare function useViewerEffects(options?: UseViewerEffectsOptions): ViewerEffectsController; type ViewerHoverProps = { hoveredObjectBinding: ObjectBinding | null; handleHoveredObject: (binding: ObjectBinding | null) => void; }; declare function useViewerHover(): ViewerHoverProps; type ViewerModelProps = { isLoading: boolean; isReady: boolean; error: unknown; bounds: ViewerModelBounds | null; objectCount: number; /** * The model's glTF material variants, by name; empty when it has none. Show * them by setting `sceneConfig.model.activeVariants`. */ materialVariants: string[]; /** The same variants as option groups, with labels and swatches. */ materialVariantGroups: MaterialVariantGroup[]; /** * Every bindable object in the model (see `ViewerObjectInfo`). Filled by * `handleObjectCatalog`, so pass that to `ModelViewer`'s `onObjectCatalog`. */ objects: ViewerObjectInfo[]; handleModelLoaded: (model: ViewerModelInfo) => void; handleObjectCatalog: (objects: ViewerObjectInfo[]) => void; handleLoadError: (error: unknown) => void; resetModelState: () => void; }; declare function useViewerModel(): ViewerModelProps; type ViewerSelectionProps = { selectedObjectBinding: ObjectBinding | null; setSelectedObjectBinding: (binding: ObjectBinding | null) => void; handleObjectSelect: (binding: ObjectBinding | null) => void; clearSelection: () => void; }; declare function useViewerSelection(initialSelectedObjectBinding?: ObjectBinding | null): ViewerSelectionProps; type UseViewerOptions = { /** * The starting bindings. Defaults to `"auto"`: a binding for every mesh, * generated when the model loads. */ bindings?: Record | (() => Record) | "auto"; /** The starting scene config (lighting, environment, post-processing, ...). */ sceneConfig?: SceneConfig | (() => SceneConfig); /** Initial camera position, target and named presets. */ camera?: UseViewerCameraOptions; /** Called for every action button, after built-in behavior and effects. */ onAction?: (event: ObjectActionEvent) => void | Promise; onObjectSelect?: (binding: ObjectBinding | null) => void; onObjectHover?: (binding: ObjectBinding | null) => void; onLoadError?: (error: unknown) => void; }; /** The ModelViewer props that connect it to `useViewer`; spread them onto it. */ type UseViewerProps = Required> & { isolation: ModelViewerProps["isolation"]; objectBindings: Record; sceneConfig?: SceneConfig; onSceneConfigChange: (config: SceneConfig) => void; }; type UseViewerResult = { /** Spread onto ModelViewer: ``. */ props: UseViewerProps; bindings: ObjectBindingsController; selection: ViewerSelectionProps; hover: ViewerHoverProps; camera: ViewerCameraProps; model: ViewerModelProps; animations: ViewerAnimationsProps; actions: ViewerActionsProps; scene: SceneConfigController; /** Focus on some objects, ghosting or hiding the rest. */ isolation: ViewerIsolationProps; effects: ViewerEffectsController; /** The live viewer, image/video capture and redraw requests. */ connection: ViewerConnectionController; }; /** * All of the viewer hooks in one, already connected to each other and to * ModelViewer: * * ```tsx * const viewer = useViewer(); * ; * viewer.bindings.setBaseColor({ group: "paint" }, "#b91c1c"); * ``` * * Each part is the result of the hook it's named after (`viewer.camera` is * `useViewerCamera()`'s result, and so on), so everything those hooks offer is * available here too. */ declare function useViewer(options?: UseViewerOptions): UseViewerResult; declare function useObjectBinding(objectBindings: Record, objectId: string | null | undefined): ObjectBinding | null; declare function useObjectBindingIds(objectBindings: Record): string[]; type UseShareableViewerStateOptions = { cameraState: ViewerCameraState | null; setCameraState: (state: ViewerCameraState, enableTransition?: boolean) => Promise; objectBindings: Record; onObjectBindingsChange: (next: Record) => void; selectedObjectBinding: ObjectBinding | null; setSelectedObjectBinding: (binding: ObjectBinding | null) => void; /** Controlled props to include: scene settings, model sources, isolation, etc. */ configuration?: ViewerConfiguration; /** Apply configuration to the same controlled props passed to ModelViewer. */ onConfigurationChange?: (next: ViewerConfiguration) => void; /** Set false while the active model is loading; restoration resumes when true. */ isReady?: boolean; /** Defaults to configuration when configuration is supplied, otherwise compact legacy view mode. */ mode?: "configuration" | "view"; /** Application-owned storage for asynchronous short links. No server is required by the SDK. */ storage?: ViewerStateStorage; /** Maximum inline URL length. Default 65536; use storage or JSON for larger states. */ maxUrlLength?: number; /** Reports background auto-sync, hashchange and pending-restore failures. */ onError?: (error: Error) => void; paramKey?: string; debounceMs?: number; /** Sync starts after the incoming link has been read and fully restored. */ autoSync?: boolean; }; type ShareableViewerStateProps = { /** Detached, versioned snapshot for JSON saving or application persistence. */ getState: () => ShareableViewerState; /** Includes live local texture/decal images as portable data URLs. */ getStateAsync: () => Promise; /** Restore JSON or parsed saved state. False while waiting for the model/configuration. */ restoreState: (state: unknown) => Promise; getShareUrl: () => string; /** Uses storage when provided; otherwise returns an inline link. */ createShareUrl: () => Promise; syncUrl: () => void; restoreFromUrl: () => Promise; }; declare function useShareableViewerState(options: UseShareableViewerStateOptions): ShareableViewerStateProps; /** Owns independent instances, their bindings/settings, placement and active selection. */ declare function useViewerModels(initialModels: ModelViewerModelEntry[]): { modelUrl: string; models: ModelViewerModelEntry[]; activeModelId: string; onModelChange: (url: string) => void; onActiveModelChange: react.Dispatch>; objectBindings: Record; onObjectBindingsChange: (next: Record) => void; sceneConfig: SceneConfig | undefined; onSceneConfigChange: (sceneConfig: SceneConfig) => void; addModel: (model: ModelViewerModelEntry) => string; duplicateModel: (id: string) => string | null; removeModel: (id: string) => void; updateModelTransform: (id: string, transform: AssetTransform) => void; }; type UseProductConfiguratorOptions = { product: ProductDefinition; selections?: ProductSelections; initialSelections?: ProductSelections; onSelectionsChange?: (selections: ProductSelections) => void; adapter?: ProductCommerceAdapter; objectBindings?: Record; sceneConfig?: SceneConfig; initialQuantity?: number; }; type ProductConfigurator = { product: ProductDefinition; configuration: ProductConfiguration; optionStates: ProductOptionState[]; selectOption: (groupId: string, optionId: string | null) => boolean; /** Chooses an option, also changing whatever a rule needs for it to be allowed. */ selectOptionWithFix: (groupId: string, optionId: string) => boolean; setSelections: (selections: ProductSelections) => void; reset: () => void; setQuantity: (quantity: number) => void; exportConfiguration: () => string; importConfiguration: (input: unknown) => void; viewerProps: { objectBindings?: Record; sceneConfig: SceneConfig; }; status: "idle" | "loading" | "ready" | "error"; /** From the pricing service if there is one, otherwise the definition's own pricing. */ price: ProductPrice | null; /** Where to buy this configuration, from the definition's checkout link. */ checkoutUrl: string | null; availability: ProductAvailability | null; error: string | null; readOnly: boolean; pendingAction: "cart" | "quote" | null; result: ProductCommerceResult | null; canAddToCart: boolean; canRequestQuote: boolean; hasCommerce: boolean; hasCart: boolean; hasQuote: boolean; addToCart: () => Promise; requestQuote: () => Promise; refresh: () => void; }; /** Owns choices and an abortable commerce lifecycle; services remain application-owned. */ declare function useProductConfigurator(options: UseProductConfiguratorOptions): ProductConfigurator; type ProductOptionsProps = { configurator: ProductConfigurator; className?: string; /** Show the price, quantity and buying actions. */ showCommerce?: boolean; /** Extra actions beside the buying actions, such as a share button. */ actions?: ReactNode; }; /** Optional accessible UI; the hook can also drive application-owned controls. */ declare function ProductOptions({ configurator: c, className, showCommerce, actions }: ProductOptionsProps): react.JSX.Element; type AssetDiagnosticsPanelProps = { report: AssetDiagnosticsReport | null; runtimeStats?: ViewerRuntimeStats | null; onRefresh?: () => void; onSelectObject?: (name: string) => void; }; /** Read-only report UI, reusable outside the editor. No scene data is sent anywhere. */ declare function AssetDiagnosticsPanel({ report, runtimeStats: runtime, onRefresh, onSelectObject }: AssetDiagnosticsPanelProps): react.JSX.Element; type ViewerSequencesProps = { controls: SequenceControls | null; playback: SequencePlaybackState; handleSequencesReady: (controls: SequenceControls | null) => void; play: (id?: string) => boolean; pause: () => void; stop: () => void; seek: (time: number) => boolean; select: (id: string) => boolean; }; /** Connect to ModelViewer.onSequencesReady for programmatic sequence playback. */ declare function useViewerSequences(): ViewerSequencesProps; export { AssetDiagnosticsPanel, type AssetDiagnosticsPanelProps, AssetDiagnosticsReport, AssetTransform, BindingEdit, CaptureImageOptions, CaptureVideoOptions, CompareViewer, type CompareViewerProps, type CompareViewerSide, ConfigurationComparisonReport, type HiddenObjectsState, MaterialVariantGroup, PublicModelViewer as ModelViewer, ModelViewerModelEntry, ModelViewerProps, ObjectActionEvent, ObjectBinding, ObjectBindingAction, ObjectBindingDecal, ObjectBindingMaterial, ObjectBindingPatch, ObjectBindingTarget, ObjectBindingTextureChannel, ObjectBindingTextureSlot, ObjectBindingTransform, type ObjectBindingsController, ProductAvailability, ProductCommerceAdapter, ProductCommerceResult, ProductConfiguration, type ProductConfigurator, ProductDefinition, ProductOptionState, ProductOptions, type ProductOptionsProps, ProductPrice, ProductSelections, type RuntimeMaterialPatch, type RuntimeMaterialRanges, type RuntimePointLightOptions, type RuntimePointLightPatch, type RuntimeTransformPatch, type RuntimeTransformRanges, SceneConfig, type SceneConfigController, SceneConfigPatch, type SceneConfigUpdate, SceneLight, SceneLightAttachment, SceneLightInput, type SceneLightPatch, type SceneLightsController, SemanticComparisonOptions, SequenceControls, SequencePlaybackState, ShareableViewerState, type ShareableViewerStateProps, type UseProductConfiguratorOptions, type UseShareableViewerStateOptions, UseViewerCameraOptions, type UseViewerEffectsOptions, type UseViewerOptions, type UseViewerProps, type UseViewerResult, type ViewerActionAnimationController, type ViewerActionBindingsController, type ViewerActionCameraController, type ViewerActionIsolationController, type ViewerActionSceneController, type ViewerActionsOptions, type ViewerActionsProps, ViewerAnimationsProps, ViewerCameraProps, ViewerCameraState, ViewerConfiguration, type ViewerConnectionController, type ViewerEffectChannels, type ViewerEffectEasing, type ViewerEffectRange, type ViewerEffectTarget, type ViewerEffectsController, type ViewerFlickerOptions, type ViewerHoverProps, ViewerIsolation, type ViewerIsolationProps, type ViewerLightEffectChannel, type ViewerMaterialEffectChannel, ViewerModelBounds, ViewerModelInfo, type ViewerModelProps, ViewerObjectInfo, type ViewerPulseOptions, type ViewerReadyConsumer, type ViewerReadyHandler, ViewerReadyState, ViewerRuntimeStats, type ViewerSelectionProps, type ViewerSequencesProps, ViewerStateStorage, type ViewerTimelineOptions, type ViewerTimelineStep, type ViewerTransformEffectChannel, type ViewerTransitionOptions, type ViewerVector3, useObjectBinding, useObjectBindingIds, useObjectBindings, useProductConfigurator, useSceneConfig, useShareableViewerState, useViewer, useViewerActions, useViewerConnection, useViewerEffects, useViewerHover, useViewerIsolation, useViewerModel, useViewerModels, useViewerSelection, useViewerSequences };