Start on work towards the tutorial. Note that this code is BROKEN
This commit is contained in:
parent
a049fc57c6
commit
dbed1300ad
14 changed files with 338 additions and 63 deletions
|
@ -42,35 +42,62 @@ function PlansCtrl($scope, $location, UserService, PlanService) {
|
|||
};
|
||||
}
|
||||
|
||||
function GuideCtrl($scope, AngularTour, AngularTourSignals) {
|
||||
$scope.startTour = function() {
|
||||
AngularTour.start({
|
||||
'title': 'My Test Tour',
|
||||
'steps': [
|
||||
{
|
||||
'title': 'Welcome to the tour!',
|
||||
'content': 'Some cool content'
|
||||
},
|
||||
{
|
||||
'title': 'A step tied to a DOM element',
|
||||
'content': 'This is the best DOM element!',
|
||||
'element': '#test-element'
|
||||
},
|
||||
{
|
||||
'content': 'Waiting for the page to change',
|
||||
'signal': AngularTourSignals.matchesLocation('/repository/')
|
||||
},
|
||||
{
|
||||
'content': 'Waiting for the page to load',
|
||||
'signal': AngularTourSignals.elementAvaliable('*[data-repo="public/publicrepo"]')
|
||||
},
|
||||
{
|
||||
'content': 'Now click on the public repository',
|
||||
'signal': AngularTourSignals.matchesLocation('/repository/public/publicrepo'),
|
||||
'element': '*[data-repo="public/publicrepo"]'
|
||||
function GuideCtrl($scope) {
|
||||
}
|
||||
|
||||
function TutorialCtrl($scope, AngularTour, AngularTourSignals, UserService) {
|
||||
$scope.tour = {
|
||||
'title': 'Quay.io Tutorial',
|
||||
'steps': [
|
||||
{
|
||||
'title': 'Welcome to the Quay.io tutorial!',
|
||||
'templateUrl': '/static/tutorial/welcome.html'
|
||||
},
|
||||
{
|
||||
'title': 'Sign in to get started',
|
||||
'templateUrl': '/static/tutorial/signup.html',
|
||||
'signal': function($tourScope) {
|
||||
$tourScope.username = UserService.currentUser().username;
|
||||
$tourScope.email = UserService.currentUser().email;
|
||||
return !UserService.currentUser().anonymous;
|
||||
}
|
||||
]
|
||||
});
|
||||
},
|
||||
{
|
||||
'title': 'Step 1: Login to Quay.io',
|
||||
'templateUrl': '/static/tutorial/docker-login.html',
|
||||
'signal': AngularTourSignals.matchesLocation('/repository/'),
|
||||
'waitMessage': "Waiting for login"
|
||||
},
|
||||
{
|
||||
'title': 'Step 2: Create a new image',
|
||||
'templateUrl': '/static/tutorial/create-image.html'
|
||||
},
|
||||
{
|
||||
'title': 'Step 3: Push the image to Quay.io',
|
||||
'templateUrl': '/static/tutorial/push-image.html'
|
||||
},
|
||||
{
|
||||
'title': 'Step 4: View the repository on Quay.io',
|
||||
'templateUrl': '/static/tutorial/view-repo.html',
|
||||
'signal': AngularTourSignals.matchesLocation('/repository/'),
|
||||
'waitMessage': "Waiting for image push to complete"
|
||||
},
|
||||
{
|
||||
'content': 'Waiting for the page to load',
|
||||
'signal': AngularTourSignals.elementAvaliable('*[data-repo="{{username}}/{{repoName}}"]'),
|
||||
'overlayable': true
|
||||
},
|
||||
{
|
||||
'content': 'Select your new repository from the list',
|
||||
'signal': AngularTourSignals.matchesLocation('/repository/{{username}}/{{repoName}}'),
|
||||
'element': '*[data-repo="{{username}}/{{repoName}}"]',
|
||||
'overlayable': true
|
||||
},
|
||||
{
|
||||
'content': 'And done!',
|
||||
'overlayable': true
|
||||
}
|
||||
]
|
||||
};
|
||||
}
|
||||
|
||||
|
|
Reference in a new issue