Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@wonder-partners/ar-button

Package Overview
Dependencies
Maintainers
3
Versions
12
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@wonder-partners/ar-button

A web component to easily display 3D models in native AR across browsers and mobile devices

  • 0.1.0
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
151
increased by38.53%
Maintainers
3
Weekly downloads
 
Created
Source

AR Button

A web-component to display a 3D model in augmented reality using the native Quick Look on iOS and Scene Viewer on Android. Heavily inspired by model-viewer and @leoncvlt/ar-button.

Quick Start

<!-- Import the component -->
<script type="module" src="https://unpkg.com/@wonder-partners/ar-button"></script>

<!-- Default stylesheet (optional) -->
<link rel="stylesheet" href="https://unpkg.com/@wonder-partners/ar-button/styles.css">

<!-- Use it like any other HTML element -->
<ar-button
    src="https://your.model.glb"
    ios-src="https://your.model.usdz">
 	View in your space
</ar-button>

Attributes

srcuri (Android)

The URL to the 3D model for Android platform. Only glTF/GLB models are supported.

linkuri (Android)

A URL for an external webpage. If present, a button will be surfaced in the UI that intents to this URL when clicked.

titlestring (Android)

A name for the model. If present, it will be displayed in the UI. The name will be truncated with ellipses after 60 characters.

fallback-urluri (Android)

When the Google app is not present on the device, this is the URL that the browser navigates to.

ios-srcuri (iOS)

The URL to the 3D model for iOS platform. Only USDZ models are supported.

checkout-titlestring (iOS)

A name for the model. If present, it will be displayed in the UI. Only works if supplied alongside checkout-subtitle, price, and call-to-action.

checkout-subtitlestring (iOS)

If present, it will be displayed in the UI. Only works if supplied alongside checkout-subtitle, price, and call-to-action.

price string (iOS)

If present, it will be displayed in the UI. Only works if supplied alongside checkout-subtitle, price, and call-to-action. AR Quick Look displays the subtitle and price separated by a comma below the title. Price should include the currency symbol.

call-to-actionuri (iOS)

If present, display this text as a button the quick look default UI. Only works when supplied alongside checkout-title, checkout-subtitle and price.

Keywords

FAQs

Package last updated on 04 Apr 2022

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc