Skip to content

v0.7.0

Compare
Choose a tag to compare
@cdata cdata released this 21 Oct 19:22
· 993 commits to master since this release

New features

  • 🆕 Use camera-target to configure where the camera is looking #733
  • 🆕 Use env(window-scroll-y) to sync camera controls to page scrolling #739
    • Percentages and calc() syntax is also supported now #755 #739
  • 🆕 New default interaction prompt that "wiggles" the model #788 #834
    • Use interaction-prompt-style="basic" to select previous default prompt behavior
    • Old prompt SVG is attached below in the "assets" section
  • 🆕 Configure the time before auto-rotate starts with auto-rotate-delay #831

Bugfixes

  • Models no longer load if <model-viewer> is not in the render tree #833
  • Models with skinned meshes now load properly #791
  • Models with zero width or height will now render properly when resized #735 #755
  • AR button will appear as intended in iOS 13 Safari #779
    • This fix has been backported to v0.6.x and v0.5.x
  • Status text intended for screen readers is now properly hidden #771
  • Fixed support for KHR_materials_pbrSpecularGlossiness #510
  • Fixed rendering of double-sided materials on some devices #740
  • Zooming no longer allows you to zoom "into" the model #729

Other notable changes

  • ✋BREAKING CHANGE: New model framing strategy avoids clipping in many scenarios but has subtle differences compared to previous defaults #755
  • ✋BREAKING CHANGE: The theta value reported by getCameraOrbit now wraps instead of growing indefinitely as the camera orbits #756
  • ✋BREAKING CHANGE: When disabling auto-rotate, the turntable rotation no longer resets to 0 #827 #833
    • Use modelViewer.resetTurntableRotation when removing auto-rotate to achieve the previous behavior
  • ✋BREAKING CHANGE: align-model has been removed in favor of camera-target
    • You can set camera-target="0m 0m 0m" to achieve a similar result to align-model="origin"
  • ✋BREAKING CHANGE: Zooming behavior now changes the field of view, where previously it changed the radius of the camera from its target #729
  • ✋BREAKING CHANGE: The new default for interaction-prompt causes it to display regardless of focus
    • Set interaction-prompt="when-focused" to use the previous default
  • ✋BREAKING CHANGE: stage-light-intensity and environment-intensity have been removed
    • It is recommended that you adjust exposure and select an appropriate environment-image in order to achieve satisfying lighting
    • Many free, high-quality environment images can be found at https://hdrihaven.com/hdris/
    • A 1K resolution image should yield satisfying results
  • ✋BREAKING CHANGE: The controls-prompt slot has been renamed to interaction-prompt
  • Many new rendering and performance improvements via #750
  • Previously undocumented error events are now documented #829
  • Examples have been added for customizing UI via slots #748
  • Updated Three.js dependency to r108 #744

Deprecation notices

  • The magic-leap and unstable-webxr attributes will be consolidated with the ar attribute in a future release #541
  • A new loading attribute will supersede the preload attribute in a future release #832
  • modelViewer.modelIsVisible has been deemed a confusing API and is highly likely to be changed significantly in the future #773