1.0.7 • Published 5 years ago

@prismadelabs/prismaidtutorial v1.0.7

Weekly downloads
1
License
MIT
Repository
github
Last release
5 years ago

PrismaID Tutorial

Version Size Types

Overview

The PrismaID Tutorial is intended to be used in a web application and it provides visual hints how to use a PrismaID tag.

Using this component

  • Put a script tag <script src='https://unpkg.com/@prismadelabs/prismaidtutorial@1.0.5/dist/prismaidtutorial.js'></script> in the head of your index.html
  • Then you can use the element anywhere in your template, JSX, html etc

Use Tutorial in HTML

<!DOCTYPE html>
<html lang="en" dir="ltr">

<head>
    <meta charset="UTF-8">
    <title>PrismaID Tutorial</title>
    <meta name="viewport" content="viewport-fit=cover, width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no">
    <script src="https://unpkg.com/@prismadelabs/prismaidtutorial@1.0.5/dist/prismaidtutorial.js"></script>
</head>

<body style="margin: 0px">
    <prismaid-tutorial></prismaid-tutorial>
    <!-- you could specify parameters directly or later somewhere in script -->
    <!-- <prismaid-tutorial welcome-title="Hello Tutorial!"></prismaid-tutorial> -->
</body>

</html>

Use Tutorial in Javascript

Once included you could work with the tutorial component the same way as you do with other components.

const tutorialElement = document.querySelector('prismaid-tutorial')

tutorialElement.welcomTitle = "Hello Tutorial!"

tutorialElement.addEventListener('tutorialCompleted', () => {
    // do some action
})

Assets

Texture Packer

Properties

PropertyAttributeDescriptionTypeDefault
finishButtonTitlefinish-button-titleFinish screen "FINISH" button titlestring"CHECK"
finishTextfinish-textFinish screen "TEXT" - contentstring"Finish Screen Text"
holdTexthold-textHold screen "TEXT" - contentstring"Hold Screen Text"
nextButtonTitlenext-button-titleWelcome screen "NEXT" button titlestring"NEXT"
placementTextplacement-textPlacement screen "TEXT" - contentstring"Placement Screen Text"
slideToPageslide-to-pageAllows to scroll smoothly (false) or just by page - swipe gesture (true)booleanfalse
swipeTextswipe-textSwipe screen "TEXT" - contentstring"Swipe Screen Text"
themeColortheme-colorColor used to colorize buttons and background image, please use hex code format e.g. #043487string""
useSlidesuse-slidesDefines a set of slides to be used.Valid values are: welcome,hold,swipe,fingerplacement,finish,nosupportstring""
videoUrlvideo-urlVideo path used on the finish screenstring""
welcomeSubtitlewelcome-subtitleWelcome screen "Sub Title" textstring"Welcome to"
welcomeTextwelcome-textWelcome screen "TEXT" - contentstring"Welcome Screen Text"
welcomeTitlewelcome-titleWelcome screen "Title" textstring"DEMO"

Events

EventDescriptionType
tutorialCompletedInvoked after the "FINISH" button is pressedCustomEvent<void>

1.0.7

5 years ago

1.0.6-beta.3

5 years ago

1.0.6-beta.2

5 years ago

1.0.6-beta.1

5 years ago

1.0.6

5 years ago

1.0.5

5 years ago

1.0.4

5 years ago

1.0.3

5 years ago

1.0.2

5 years ago

1.0.1

5 years ago

1.0.0

5 years ago