Skip to content

Spinner

This JavaScript web component is the recommended way to implement the Spinner on your website.

  1. Include the following script-tag in your HTML, preferably at the end of the body:

    js
    <script
      type="module"
      src="https://spinner.photo-motion.com/lib/photo-motion-spinner.js"
    ></script>
  2. Add the following HTML where you want the spinner to appear:

    html
    <photo-motion-spinner article-hash="9541cfc3-92f6-4f1f-aef4-ab74f45b4651"
    ></photo-motion-spinner>

Options

AttributeDescriptionOptions
article-hashHash of the vehicle you wish to display. See Spinner
buttons-placementPosition of the buttonstop bottom
viewer-modeOrientation of spinnerlandscape portrait
can-scrollActivate the ability to zoom in and out via the mouse-wheeltrue false
can-fullscreenActivate the ability to go fullscreentrue false
clean-uiHide all UI-elementstrue false

Hide buttons

The following attributes can be used to hide individual buttons on the spinner. By default all available features/buttons are visible. To hide all UI-elements, use the clean-ui-attribute instead.

hide-zoom hide-interior hide-gallery hide-doors hide-lightshide-showcase hide-hotspots

Iframe

html
<iframe
  src="https://spinner.photo-motion.com/1e9e04a5-01c7-455f-9faf-f309134fed4e"
  width="600"
  allowfullscreen="true"
  style="aspect-ratio: 3/2"
></iframe>

Dimensions

The width and height of the iframe can be controlled through its width and height properties, or by using CSS.

It is recommended to always use a 3 x 2-ratio for width x height.

iOS devices

On iOS-devices (e.g. iPhones and iPads) it is not possible to display an iframe fullscreen. On these devices the full screen option is hidden.