forked from ionic-team/ionic-cli
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathions.js
More file actions
65 lines (54 loc) · 1.58 KB
/
ions.js
File metadata and controls
65 lines (54 loc) · 1.58 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
var argv = require('optimist').argv,
IonicProject = require('./project'),
Task = require('./task').Task,
IonicStats = require('./stats').IonicStats,
_ = require('underscore');
var ions = [
{
ion: 'ionic-ion-header-shrink',
name: 'Header Shrink',
description: 'A shrinking header effect like Facebook\'s'
},
{
ion: 'ionic-ion-drawer',
name: 'Android Drawer',
description: 'Android-style drawer menu'
},
{
ion: 'ionic-ion-ios-buttons',
name: 'iOS Rounded Buttons',
description: 'iOS "Squircle" style icons'
},
{
ion: 'ionic-ion-swipe-cards',
name: 'Swipeable Cards',
description: 'Swiping interaction as seen in Jelly'
},
{
ion: 'ionic-ion-tinder-cards',
name: 'Tinder Cards',
description: 'Tinder style card swiping interaction'
}
]
var IonicTask = function() {};
IonicTask.prototype = new Task();
IonicTask.prototype.run = function(ionic) {
console.log('Ionic Ions - ions power your app to be awesome.');
console.log('A curated collection of useful addons, components, and ux interactions for extending ionic.')
console.log('\n')
_.each(ions, function(ion) {
var rightColumn = 20;
var dots = '';
var indent = '';
var x, arg;
var startStr = ion.name;
while( (startStr + dots).length < rightColumn + 1) {
dots += '.';
}
// Header Shrink ... A shrinking header effect like Facebook\'s ..
var installStr = ['\'ionic add ', ion.ion, '\''].join('')
console.log(ion.name, dots, installStr)
console.log(ion.description, '\n')
})
}
exports.IonicTask = IonicTask;