GithubHelp home page GithubHelp logo

heymp / aframe-dialog-popup-component Goto Github PK

View Code? Open in Web Editor NEW

This project forked from editvr/aframe-dialog-popup-component

0.0 2.0 0.0 735 KB

Provides a component that constructs a toggle-able dialog with a title, description, image, and close button.

License: GNU General Public License v3.0

JavaScript 80.23% HTML 19.77%

aframe-dialog-popup-component's Introduction

aframe-dialog-popup-component

Version CircleCI License

Provides a component that constructs a toggle-able dialog with a title, description, image, and close button.

For A-Frame.

API

Property Description Default Value
title String containing title. New Dialog
titleColor Text color of title. black
titleFont Title font. mozillavr
titleWrapCount Title entity wrap count. 24
body String containing body. This dialog has no body yet.
bodyColor Text color of body. black
bodyFont Body font. mozillavr
bodyWrapCount Body entity wrap count. 30
openOn Open/Close event. click
active Turn dialog on/off. true
openIconImage Icon image for open button. None
openIconRadius Radius for open icon. 0.3
openIconColor Color for open icon. white
closeIconImage Icon image for open button. None
closeIconRadius Radius for close icon. 0.3
closeIconColor Color for close icon. white
image Path to Dialog hero image. None
imageWidth Dialog hero image width. 2
imageHeight Dialog hero image height. 2
dialogBoxWidth Dialog box width. 4
dialogBoxHeight Dialog box height. 4
dialogBoxColor Dialog box background color. white
dialogBoxPadding Dialog box padding. 0.2

Installation

Browser

Install and use by directly including the browser files:

<head>
  <title>My A-Frame Scene</title>
  <script src="https://aframe.io/releases/0.8.2/aframe.min.js"></script>
  <script src="https://unpkg.com/@editvr/[email protected]/dist/aframe-dialog-popup-component.min.js"></script>
</head>

<body>
  <a-scene>
    <a-entity dialog-popup="title: My Title; body: My Body"></a-entity>
  </a-scene>
</body>

npm

Install via npm:

npm install @editvr/aframe-dialog-popup-component

Then require and use.

require('aframe');
require('@editvr/aframe-dialog-popup-component');

Example

Closed

Closed

Opened

Open

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.