11<!DOCTYPE html>
2- < html lang ="en ">
2+ < html lang ="en " data-ng-app =" myApp " >
33< head >
44 < meta charset ="utf-8 ">
5- < title > Defining with JSON configuration </ title >
5+ < title > Port of intro.js to Angular </ title >
66 < meta name ="viewport " content ="width=device-width, initial-scale=1.0 ">
77 < meta name ="description " content ="Intro.js - Better introductions for websites and features with a step-by-step guide for your projects. ">
88 < meta name ="author " content ="Afshin Mehrabani (@afshinmeh) in usabli.ca group ">
99
1010 <!-- styles -->
1111 < link href ="assets/css/bootstrap.min.css " rel ="stylesheet ">
1212 < link href ="assets/css/demo.css " rel ="stylesheet ">
13+ < link href ="assets/css/bootstrap-responsive.min.css " rel ="stylesheet ">
1314
1415 <!-- Add IntroJs styles -->
1516 < link href ="../lib/introjs.css " rel ="stylesheet ">
1617
17- < link href =" assets/css/bootstrap-responsive.min.css " rel =" stylesheet " >
18+
1819</ head >
1920
20- < body >
21+ < body >
2122
22- < div class ="container-narrow ">
23+ < div class ="container-narrow " ng-controller =" MyController " ng-intro ng-intro-options =" IntroSnippets " ng-intro-function =" StartTheTour " >
2324
2425 < div class ="masthead ">
2526 < ul id ="step5 " class ="nav nav-pills pull-right ">
@@ -35,7 +36,7 @@ <h3 class="muted">Intro.js</h3>
3536 < div class ="jumbotron ">
3637 < h1 id ="step1 "> Programmatic</ h1 >
3738 < p id ="step4 " class ="lead "> In this example we are going to define steps with JSON configuration.</ p >
38- < a class ="btn btn-large btn-success " href =" javascript:void(0); " onclick =" startIntro (); "> Show me how</ a >
39+ < a class ="btn btn-large btn-success " ng-click =" StartTheTour (); "> Show me how</ a >
3940 </ div >
4041
4142 < hr >
@@ -69,39 +70,11 @@ <h4>Section Six</h4>
6970
7071</ div >
7172< script type ="text/javascript " src ="../lib/intro.min.js "> </ script >
72- < script type ="text/javascript ">
73- function startIntro ( ) {
74- var intro = introJs ( ) ;
75- intro . setOptions ( {
76- steps : [
77- {
78- element : document . querySelector ( '#step1' ) ,
79- intro : "This is a tooltip."
80- } ,
81- {
82- element : document . querySelectorAll ( '#step2' ) [ 0 ] ,
83- intro : "Ok, wasn't that fun?" ,
84- position : 'right'
85- } ,
86- {
87- element : '#step3' ,
88- intro : 'More features, more fun.' ,
89- position : 'left'
90- } ,
91- {
92- element : '#step4' ,
93- intro : "Another step." ,
94- position : 'bottom'
95- } ,
96- {
97- element : '#step5' ,
98- intro : 'Get it, use it.'
99- }
100- ]
101- } ) ;
102-
103- intro . start ( ) ;
104- }
105- </ script >
73+
74+
75+ < script src ="https://ajax.googleapis.com/ajax/libs/angularjs/1.0.8/angular.min.js "> </ script >
76+ < script src ="../angular-intro.js "> </ script >
77+ < script src ="../lib/app.js "> </ script >
78+
10679</ body >
10780</ html >
0 commit comments