nutella_framework 0.4.13 → 0.4.16
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile +1 -1
- data/VERSION +1 -1
- data/framework_components/order.json +2 -1
- data/framework_components/roomcast-bot/data/default/channels-data.json +1 -0
- data/framework_components/roomcast-bot/data/default/channels.json +1 -0
- data/framework_components/roomcast-bot/data/default/configs.json +1 -0
- data/framework_components/roomcast-bot/data/default/mapping.json +1 -0
- data/framework_components/roomcast-bot/roomcast_bot.rb +178 -0
- data/framework_components/roomcast-bot/startup +5 -0
- data/framework_components/roomcast-channel-creator/.gitignore +2 -0
- data/framework_components/roomcast-channel-creator/README.md +9 -0
- data/framework_components/roomcast-channel-creator/dist/app.js +29607 -0
- data/framework_components/roomcast-channel-creator/dist/css/font-awesome.min.css +4 -0
- data/framework_components/roomcast-channel-creator/dist/css/ionicons.min.css +11 -0
- data/framework_components/roomcast-channel-creator/dist/fonts/FontAwesome.otf +0 -0
- data/framework_components/roomcast-channel-creator/dist/fonts/fontawesome-webfont.eot +0 -0
- data/framework_components/roomcast-channel-creator/dist/fonts/fontawesome-webfont.svg +565 -0
- data/framework_components/roomcast-channel-creator/dist/fonts/fontawesome-webfont.ttf +0 -0
- data/framework_components/roomcast-channel-creator/dist/fonts/fontawesome-webfont.woff +0 -0
- data/framework_components/roomcast-channel-creator/dist/fonts/fontawesome-webfont.woff2 +0 -0
- data/framework_components/roomcast-channel-creator/dist/fonts/ionicons.eot +0 -0
- data/framework_components/roomcast-channel-creator/dist/fonts/ionicons.svg +2230 -0
- data/framework_components/roomcast-channel-creator/dist/fonts/ionicons.ttf +0 -0
- data/framework_components/roomcast-channel-creator/dist/fonts/ionicons.woff +0 -0
- data/framework_components/roomcast-channel-creator/dist/main.css +3304 -0
- data/framework_components/roomcast-channel-creator/dist/nutella_lib.js +5068 -0
- data/framework_components/roomcast-channel-creator/gulp/config.js +51 -0
- data/framework_components/roomcast-channel-creator/gulp/tasks/browserify.js +77 -0
- data/framework_components/roomcast-channel-creator/gulp/tasks/build.js +3 -0
- data/framework_components/roomcast-channel-creator/gulp/tasks/css.js +7 -0
- data/framework_components/roomcast-channel-creator/gulp/tasks/default.js +3 -0
- data/framework_components/roomcast-channel-creator/gulp/tasks/fonts.js +7 -0
- data/framework_components/roomcast-channel-creator/gulp/tasks/less.js +16 -0
- data/framework_components/roomcast-channel-creator/gulp/tasks/mui-fonts.js +7 -0
- data/framework_components/roomcast-channel-creator/gulp/tasks/nutella.js +7 -0
- data/framework_components/roomcast-channel-creator/gulp/tasks/setWatch.js +5 -0
- data/framework_components/roomcast-channel-creator/gulp/tasks/svgs.js +7 -0
- data/framework_components/roomcast-channel-creator/gulp/tasks/watch.js +12 -0
- data/framework_components/roomcast-channel-creator/gulp/util/bundleLogger.js +21 -0
- data/framework_components/roomcast-channel-creator/gulp/util/handleErrors.js +15 -0
- data/framework_components/roomcast-channel-creator/gulpfile.js +16 -0
- data/framework_components/roomcast-channel-creator/index.html +52 -0
- data/framework_components/roomcast-channel-creator/nutella.json +6 -0
- data/framework_components/roomcast-channel-creator/package.json +37 -0
- data/framework_components/roomcast-channel-creator/src/app/app.js +22 -0
- data/framework_components/roomcast-channel-creator/src/app/components/AnimationMixin.js +44 -0
- data/framework_components/roomcast-channel-creator/src/app/components/CataloguePage.js +130 -0
- data/framework_components/roomcast-channel-creator/src/app/components/Channel.js +378 -0
- data/framework_components/roomcast-channel-creator/src/app/components/ColorCell.js +28 -0
- data/framework_components/roomcast-channel-creator/src/app/components/ColorPicker.js +53 -0
- data/framework_components/roomcast-channel-creator/src/app/components/DetailPage.js +66 -0
- data/framework_components/roomcast-channel-creator/src/app/components/NutellaMixin.js +40 -0
- data/framework_components/roomcast-channel-creator/src/app/components/PageSliderMixin.js +68 -0
- data/framework_components/roomcast-channel-creator/src/app/components/Router.js +52 -0
- data/framework_components/roomcast-channel-creator/src/app/components/TopBar.js +86 -0
- data/framework_components/roomcast-channel-creator/src/app/components/main.js +333 -0
- data/framework_components/roomcast-channel-creator/src/css/font-awesome.min.css +4 -0
- data/framework_components/roomcast-channel-creator/src/css/ionicons.min.css +11 -0
- data/framework_components/roomcast-channel-creator/src/fonts/FontAwesome.otf +0 -0
- data/framework_components/roomcast-channel-creator/src/fonts/fontawesome-webfont.eot +0 -0
- data/framework_components/roomcast-channel-creator/src/fonts/fontawesome-webfont.svg +565 -0
- data/framework_components/roomcast-channel-creator/src/fonts/fontawesome-webfont.ttf +0 -0
- data/framework_components/roomcast-channel-creator/src/fonts/fontawesome-webfont.woff +0 -0
- data/framework_components/roomcast-channel-creator/src/fonts/fontawesome-webfont.woff2 +0 -0
- data/framework_components/roomcast-channel-creator/src/fonts/ionicons.eot +0 -0
- data/framework_components/roomcast-channel-creator/src/fonts/ionicons.svg +2230 -0
- data/framework_components/roomcast-channel-creator/src/fonts/ionicons.ttf +0 -0
- data/framework_components/roomcast-channel-creator/src/fonts/ionicons.woff +0 -0
- data/framework_components/roomcast-channel-creator/src/less/main.less +500 -0
- data/framework_components/roomcast-channel-creator/src/less/my_overrides.less +14 -0
- data/framework_components/roomcast-package-creator/.gitignore +2 -0
- data/framework_components/roomcast-package-creator/README.md +9 -0
- data/framework_components/roomcast-package-creator/dist/app.js +36624 -0
- data/framework_components/roomcast-package-creator/dist/css/font-awesome.min.css +4 -0
- data/framework_components/roomcast-package-creator/dist/css/ionicons.min.css +11 -0
- data/framework_components/roomcast-package-creator/dist/fonts/FontAwesome.otf +0 -0
- data/framework_components/roomcast-package-creator/dist/fonts/fontawesome-webfont.eot +0 -0
- data/framework_components/roomcast-package-creator/dist/fonts/fontawesome-webfont.svg +565 -0
- data/framework_components/roomcast-package-creator/dist/fonts/fontawesome-webfont.ttf +0 -0
- data/framework_components/roomcast-package-creator/dist/fonts/fontawesome-webfont.woff +0 -0
- data/framework_components/roomcast-package-creator/dist/fonts/fontawesome-webfont.woff2 +0 -0
- data/framework_components/roomcast-package-creator/dist/fonts/ionicons.eot +0 -0
- data/framework_components/roomcast-package-creator/dist/fonts/ionicons.svg +2230 -0
- data/framework_components/roomcast-package-creator/dist/fonts/ionicons.ttf +0 -0
- data/framework_components/roomcast-package-creator/dist/fonts/ionicons.woff +0 -0
- data/framework_components/roomcast-package-creator/dist/fonts/material-ui-icons.eot +0 -0
- data/framework_components/roomcast-package-creator/dist/fonts/material-ui-icons.svg +14 -0
- data/framework_components/roomcast-package-creator/dist/fonts/material-ui-icons.ttf +0 -0
- data/framework_components/roomcast-package-creator/dist/fonts/material-ui-icons.woff +0 -0
- data/framework_components/roomcast-package-creator/dist/main.css +5932 -0
- data/framework_components/roomcast-package-creator/dist/nutella_lib.js +5068 -0
- data/framework_components/roomcast-package-creator/gulp/config.js +51 -0
- data/framework_components/roomcast-package-creator/gulp/tasks/browserify.js +77 -0
- data/framework_components/roomcast-package-creator/gulp/tasks/build.js +3 -0
- data/framework_components/roomcast-package-creator/gulp/tasks/css.js +7 -0
- data/framework_components/roomcast-package-creator/gulp/tasks/default.js +3 -0
- data/framework_components/roomcast-package-creator/gulp/tasks/fonts.js +7 -0
- data/framework_components/roomcast-package-creator/gulp/tasks/less.js +16 -0
- data/framework_components/roomcast-package-creator/gulp/tasks/mui-fonts.js +7 -0
- data/framework_components/roomcast-package-creator/gulp/tasks/nutella.js +7 -0
- data/framework_components/roomcast-package-creator/gulp/tasks/setWatch.js +5 -0
- data/framework_components/roomcast-package-creator/gulp/tasks/svgs.js +7 -0
- data/framework_components/roomcast-package-creator/gulp/tasks/watch.js +12 -0
- data/framework_components/roomcast-package-creator/gulp/util/bundleLogger.js +21 -0
- data/framework_components/roomcast-package-creator/gulp/util/handleErrors.js +15 -0
- data/framework_components/roomcast-package-creator/gulpfile.js +16 -0
- data/framework_components/roomcast-package-creator/index.html +51 -0
- data/framework_components/roomcast-package-creator/nutella.json +6 -0
- data/framework_components/roomcast-package-creator/package.json +38 -0
- data/framework_components/roomcast-package-creator/src/app/app.js +19 -0
- data/framework_components/roomcast-package-creator/src/app/components/ButtonInteractionsMixin.js +45 -0
- data/framework_components/roomcast-package-creator/src/app/components/ChannelCard.js +87 -0
- data/framework_components/roomcast-package-creator/src/app/components/ChannelItem.js +71 -0
- data/framework_components/roomcast-package-creator/src/app/components/ChannelsCatalogue.js +64 -0
- data/framework_components/roomcast-package-creator/src/app/components/ChannelsPanel.js +127 -0
- data/framework_components/roomcast-package-creator/src/app/components/ConfigField.js +50 -0
- data/framework_components/roomcast-package-creator/src/app/components/ConfigurationsPanel.js +114 -0
- data/framework_components/roomcast-package-creator/src/app/components/ContextButton.js +37 -0
- data/framework_components/roomcast-package-creator/src/app/components/GlobalButton.js +26 -0
- data/framework_components/roomcast-package-creator/src/app/components/NutellaMixin.js +23 -0
- data/framework_components/roomcast-package-creator/src/app/components/PoolHeader.js +67 -0
- data/framework_components/roomcast-package-creator/src/app/components/PoolRow.js +160 -0
- data/framework_components/roomcast-package-creator/src/app/components/ResourceFamilyPool.js +168 -0
- data/framework_components/roomcast-package-creator/src/app/components/ResourcesPanel.js +76 -0
- data/framework_components/roomcast-package-creator/src/app/components/main.js +222 -0
- data/framework_components/roomcast-package-creator/src/app/components/material-ui/dialog_.jsx +66 -0
- data/framework_components/roomcast-package-creator/src/app/components/material-ui/drop-down-menu.jsx +163 -0
- data/framework_components/roomcast-package-creator/src/app/components/material-ui/enhanced-textarea.jsx +113 -0
- data/framework_components/roomcast-package-creator/src/app/components/material-ui/floating-action-button_.jsx +73 -0
- data/framework_components/roomcast-package-creator/src/app/components/material-ui/menu-item.jsx +100 -0
- data/framework_components/roomcast-package-creator/src/app/components/material-ui/menu.jsx +209 -0
- data/framework_components/roomcast-package-creator/src/app/components/material-ui/overlay.jsx +21 -0
- data/framework_components/roomcast-package-creator/src/app/components/material-ui/raised-button_.jsx +72 -0
- data/framework_components/roomcast-package-creator/src/app/components/material-ui/right-nav.jsx +108 -0
- data/framework_components/roomcast-package-creator/src/app/components/material-ui/svg-icons/drop-down-arrow.jsx +17 -0
- data/framework_components/roomcast-package-creator/src/app/components/material-ui/svg-icons/navigation-chevron-left.jsx +16 -0
- data/framework_components/roomcast-package-creator/src/app/components/material-ui/svg-icons/navigation-chevron-right.jsx +17 -0
- data/framework_components/roomcast-package-creator/src/app/components/material-ui/svg-icons/navigation-menu.jsx +16 -0
- data/framework_components/roomcast-package-creator/src/app/components/material-ui/svg-icons/svg-icon.jsx +23 -0
- data/framework_components/roomcast-package-creator/src/app/components/material-ui/svg-icons/toggle-check-box-checked.jsx +16 -0
- data/framework_components/roomcast-package-creator/src/app/components/material-ui/svg-icons/toggle-check-box-outline-blank.jsx +16 -0
- data/framework_components/roomcast-package-creator/src/app/components/material-ui/svg-icons/toggle-radio-button-off.jsx +16 -0
- data/framework_components/roomcast-package-creator/src/app/components/material-ui/svg-icons/toggle-radio-button-on.jsx +16 -0
- data/framework_components/roomcast-package-creator/src/app/components/material-ui/text-field.jsx +215 -0
- data/framework_components/roomcast-package-creator/src/app/components/material-ui/utils/css-event.js +52 -0
- data/framework_components/roomcast-package-creator/src/app/components/material-ui/utils/date-time.js +132 -0
- data/framework_components/roomcast-package-creator/src/app/components/material-ui/utils/dom.js +71 -0
- data/framework_components/roomcast-package-creator/src/app/components/material-ui/utils/events.js +34 -0
- data/framework_components/roomcast-package-creator/src/app/components/material-ui/utils/key-code.js +10 -0
- data/framework_components/roomcast-package-creator/src/app/components/material-ui/utils/key-line.js +13 -0
- data/framework_components/roomcast-package-creator/src/app/components/material-ui/utils/unique-id.js +7 -0
- data/framework_components/roomcast-package-creator/src/css/font-awesome.min.css +4 -0
- data/framework_components/roomcast-package-creator/src/css/ionicons.min.css +11 -0
- data/framework_components/roomcast-package-creator/src/fonts/FontAwesome.otf +0 -0
- data/framework_components/roomcast-package-creator/src/fonts/fontawesome-webfont.eot +0 -0
- data/framework_components/roomcast-package-creator/src/fonts/fontawesome-webfont.svg +565 -0
- data/framework_components/roomcast-package-creator/src/fonts/fontawesome-webfont.ttf +0 -0
- data/framework_components/roomcast-package-creator/src/fonts/fontawesome-webfont.woff +0 -0
- data/framework_components/roomcast-package-creator/src/fonts/fontawesome-webfont.woff2 +0 -0
- data/framework_components/roomcast-package-creator/src/fonts/ionicons.eot +0 -0
- data/framework_components/roomcast-package-creator/src/fonts/ionicons.svg +2230 -0
- data/framework_components/roomcast-package-creator/src/fonts/ionicons.ttf +0 -0
- data/framework_components/roomcast-package-creator/src/fonts/ionicons.woff +0 -0
- data/framework_components/roomcast-package-creator/src/less/drop-down-icon.less +43 -0
- data/framework_components/roomcast-package-creator/src/less/drop-down-menu.less +77 -0
- data/framework_components/roomcast-package-creator/src/less/enhanced-textarea.less +16 -0
- data/framework_components/roomcast-package-creator/src/less/main.less +491 -0
- data/framework_components/roomcast-package-creator/src/less/menu-item.less +69 -0
- data/framework_components/roomcast-package-creator/src/less/menu.less +50 -0
- data/framework_components/roomcast-package-creator/src/less/my_overrides.less +15 -0
- data/framework_components/roomcast-package-creator/src/less/svg-icon.less +11 -0
- data/framework_components/roomcast-package-creator/src/less/text-field.less +168 -0
- data/lib/commands/checkup.rb +1 -1
- data/nutella_lib/framework_net.rb +0 -1
- metadata +173 -4
@@ -0,0 +1,51 @@
|
|
1
|
+
var dest = './dist',
|
2
|
+
src = './src',
|
3
|
+
mui = './node_modules/material-ui/src';
|
4
|
+
|
5
|
+
module.exports = {
|
6
|
+
browserSync: {
|
7
|
+
server: {
|
8
|
+
// We're serving the src folder as well
|
9
|
+
// for sass sourcemap linking
|
10
|
+
baseDir: [dest, src]
|
11
|
+
},
|
12
|
+
files: [
|
13
|
+
dest + '/**'
|
14
|
+
]
|
15
|
+
},
|
16
|
+
less: {
|
17
|
+
src: src + '/less/main.less',
|
18
|
+
watch: [
|
19
|
+
src + '/less/**',
|
20
|
+
mui + '/less/**'
|
21
|
+
],
|
22
|
+
dest: dest
|
23
|
+
},
|
24
|
+
css: {
|
25
|
+
src: src + "/css/**",
|
26
|
+
dest: dest + "/css"
|
27
|
+
},
|
28
|
+
fonts: {
|
29
|
+
src: src + '/fonts/**',
|
30
|
+
dest: dest + '/fonts'
|
31
|
+
},
|
32
|
+
muiFonts: {
|
33
|
+
src: mui + '/less/material-ui-icons/fonts/**',
|
34
|
+
dest: dest + '/fonts'
|
35
|
+
},
|
36
|
+
nutella: {
|
37
|
+
src: './node_modules/nutella_lib/dist/nutella_lib.js',
|
38
|
+
dest: dest
|
39
|
+
},
|
40
|
+
browserify: {
|
41
|
+
// Enable source maps
|
42
|
+
debug: true,
|
43
|
+
// A separate bundle will be generated for each
|
44
|
+
// bundle config in the list below
|
45
|
+
bundleConfigs: [{
|
46
|
+
entries: src + '/app/app.js',
|
47
|
+
dest: dest,
|
48
|
+
outputName: 'app.js'
|
49
|
+
}]
|
50
|
+
}
|
51
|
+
};
|
@@ -0,0 +1,77 @@
|
|
1
|
+
/* browserify task
|
2
|
+
---------------
|
3
|
+
Bundle javascripty things with browserify!
|
4
|
+
This task is set up to generate multiple separate bundles, from
|
5
|
+
different sources, and to use Watchify when run from the default task.
|
6
|
+
See browserify.bundleConfigs in gulp/config.js
|
7
|
+
*/
|
8
|
+
|
9
|
+
var browserify = require('browserify');
|
10
|
+
var watchify = require('watchify');
|
11
|
+
var bundleLogger = require('../util/bundleLogger');
|
12
|
+
var gulp = require('gulp');
|
13
|
+
var handleErrors = require('../util/handleErrors');
|
14
|
+
var source = require('vinyl-source-stream');
|
15
|
+
var config = require('../config').browserify;
|
16
|
+
|
17
|
+
gulp.task('browserify', function(callback) {
|
18
|
+
|
19
|
+
var bundleQueue = config.bundleConfigs.length;
|
20
|
+
|
21
|
+
var browserifyThis = function(bundleConfig) {
|
22
|
+
|
23
|
+
var bundler = browserify({
|
24
|
+
// Required watchify args
|
25
|
+
cache: {}, packageCache: {}, fullPaths: false,
|
26
|
+
// Specify the entry point of your app
|
27
|
+
entries: bundleConfig.entries,
|
28
|
+
// Add file extentions to make optional in your requires
|
29
|
+
extensions: config.extensions,
|
30
|
+
// Enable source maps!
|
31
|
+
debug: config.debug
|
32
|
+
});
|
33
|
+
|
34
|
+
var bundle = function() {
|
35
|
+
// Log when bundling starts
|
36
|
+
bundleLogger.start(bundleConfig.outputName);
|
37
|
+
|
38
|
+
return bundler
|
39
|
+
.bundle()
|
40
|
+
// Report compile errors
|
41
|
+
.on('error', handleErrors)
|
42
|
+
// Use vinyl-source-stream to make the
|
43
|
+
// stream gulp compatible. Specifiy the
|
44
|
+
// desired output filename here.
|
45
|
+
.pipe(source(bundleConfig.outputName))
|
46
|
+
// Specify the output destination
|
47
|
+
.pipe(gulp.dest(bundleConfig.dest))
|
48
|
+
.on('end', reportFinished);
|
49
|
+
};
|
50
|
+
|
51
|
+
if(global.isWatching) {
|
52
|
+
// Wrap with watchify and rebundle on changes
|
53
|
+
bundler = watchify(bundler);
|
54
|
+
// Rebundle on update
|
55
|
+
bundler.on('update', bundle);
|
56
|
+
}
|
57
|
+
|
58
|
+
var reportFinished = function() {
|
59
|
+
// Log when bundling completes
|
60
|
+
bundleLogger.end(bundleConfig.outputName);
|
61
|
+
|
62
|
+
if(bundleQueue) {
|
63
|
+
bundleQueue--;
|
64
|
+
if(bundleQueue === 0) {
|
65
|
+
// If queue is empty, tell gulp the task is complete.
|
66
|
+
// https://github.com/gulpjs/gulp/blob/master/docs/API.md#accept-a-callback
|
67
|
+
callback();
|
68
|
+
}
|
69
|
+
}
|
70
|
+
};
|
71
|
+
|
72
|
+
return bundle();
|
73
|
+
};
|
74
|
+
|
75
|
+
// Start bundling with Browserify for each bundleConfig specified
|
76
|
+
config.bundleConfigs.forEach(browserifyThis);
|
77
|
+
});
|
@@ -0,0 +1,16 @@
|
|
1
|
+
var gulp = require('gulp'),
|
2
|
+
less = require('gulp-less'),
|
3
|
+
autoprefixer = require('gulp-autoprefixer'),
|
4
|
+
sourcemaps = require('gulp-sourcemaps'),
|
5
|
+
handleErrors = require('../util/handleErrors'),
|
6
|
+
config = require('../config').less;
|
7
|
+
|
8
|
+
gulp.task('less', function() {
|
9
|
+
return gulp.src(config.src)
|
10
|
+
.pipe(sourcemaps.init())
|
11
|
+
.pipe(less())
|
12
|
+
.on('error', handleErrors)
|
13
|
+
.pipe(autoprefixer({cascade: false, browsers: ['last 2 versions']}))
|
14
|
+
.pipe(sourcemaps.write())
|
15
|
+
.pipe(gulp.dest(config.dest));
|
16
|
+
});
|
@@ -0,0 +1,12 @@
|
|
1
|
+
|
2
|
+
/* Notes:
|
3
|
+
- gulp/tasks/browserify.js handles js recompiling with watchify
|
4
|
+
- gulp/tasks/browserSync.js watches and reloads compiled files
|
5
|
+
*/
|
6
|
+
|
7
|
+
var gulp = require('gulp');
|
8
|
+
var config = require('../config');
|
9
|
+
|
10
|
+
gulp.task('watch', ['setWatch'], function() {
|
11
|
+
gulp.watch(config.less.watch, ['less']);
|
12
|
+
});
|
@@ -0,0 +1,21 @@
|
|
1
|
+
/* bundleLogger
|
2
|
+
------------
|
3
|
+
Provides gulp style logs to the bundle method in browserify.js
|
4
|
+
*/
|
5
|
+
|
6
|
+
var gutil = require('gulp-util');
|
7
|
+
var prettyHrtime = require('pretty-hrtime');
|
8
|
+
var startTime;
|
9
|
+
|
10
|
+
module.exports = {
|
11
|
+
start: function(filepath) {
|
12
|
+
startTime = process.hrtime();
|
13
|
+
gutil.log('Bundling', gutil.colors.green(filepath) + '...');
|
14
|
+
},
|
15
|
+
|
16
|
+
end: function(filepath) {
|
17
|
+
var taskTime = process.hrtime(startTime);
|
18
|
+
var prettyTime = prettyHrtime(taskTime);
|
19
|
+
gutil.log('Bundled', gutil.colors.green(filepath), 'in', gutil.colors.magenta(prettyTime));
|
20
|
+
}
|
21
|
+
};
|
@@ -0,0 +1,15 @@
|
|
1
|
+
var notify = require("gulp-notify");
|
2
|
+
|
3
|
+
module.exports = function() {
|
4
|
+
|
5
|
+
var args = Array.prototype.slice.call(arguments);
|
6
|
+
|
7
|
+
// Send error to notification center with gulp-notify
|
8
|
+
notify.onError({
|
9
|
+
title: "Compile Error",
|
10
|
+
message: "<%= error.message %>"
|
11
|
+
}).apply(this, args);
|
12
|
+
|
13
|
+
// Keep gulp from hanging on this task
|
14
|
+
this.emit('end');
|
15
|
+
};
|
@@ -0,0 +1,16 @@
|
|
1
|
+
/*
|
2
|
+
gulpfile.js
|
3
|
+
===========
|
4
|
+
Rather than manage one giant configuration file responsible
|
5
|
+
for creating multiple tasks, each task has been broken out into
|
6
|
+
its own file in gulp/tasks. Any files in that directory get
|
7
|
+
automatically required below.
|
8
|
+
To add a new task, simply add a new task file that directory.
|
9
|
+
gulp/tasks/default.js specifies the default set of tasks to run
|
10
|
+
when you run `gulp`.
|
11
|
+
*/
|
12
|
+
|
13
|
+
var requireDir = require('require-dir');
|
14
|
+
|
15
|
+
// Require all tasks in gulp/tasks, including subfolders
|
16
|
+
requireDir('./gulp/tasks', { recurse: true });
|
@@ -0,0 +1,51 @@
|
|
1
|
+
<!doctype html>
|
2
|
+
<html class="no-js" lang="">
|
3
|
+
|
4
|
+
<head>
|
5
|
+
<meta charset="utf-8">
|
6
|
+
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
7
|
+
<title>Configuration Interface</title>
|
8
|
+
<meta name="description" content="This interface allows the user to set the mapping of the available channels on the resources.">
|
9
|
+
<meta name="viewport" content="width=device-width, initial-scale=1">
|
10
|
+
<link rel="stylesheet" type="text/css" href="dist/main.css">
|
11
|
+
<link rel="stylesheet" type="text/css" href="dist/css/font-awesome.min.css">
|
12
|
+
<link rel="stylesheet" type="text/css" href="dist/css/ionicons.min.css">
|
13
|
+
</head>
|
14
|
+
|
15
|
+
<body>
|
16
|
+
|
17
|
+
<!-- Nutella -->
|
18
|
+
<script src="dist/nutella_lib.js" type="text/javascript" charset="utf-8"></script>
|
19
|
+
<script type="text/javascript">
|
20
|
+
|
21
|
+
// Parse the query parameters
|
22
|
+
var query_parameters = NUTELLA.parseURLParameters();
|
23
|
+
|
24
|
+
// Get an instance of nutella.
|
25
|
+
var nutella = NUTELLA.init(query_parameters.broker, query_parameters.app_id, query_parameters.run_id, 'configuration-interface');
|
26
|
+
|
27
|
+
</script>
|
28
|
+
|
29
|
+
<!-- This script adds the Roboto font to our project. For more detail go to this site: http://www.google.com/fonts#UsePlace:use/Collection:Roboto:400,300,500 -->
|
30
|
+
<script>
|
31
|
+
var WebFontConfig = {
|
32
|
+
google: {
|
33
|
+
families: ['Roboto:400,300,200,100,500:latin']
|
34
|
+
}
|
35
|
+
};
|
36
|
+
(function () {
|
37
|
+
var wf = document.createElement('script');
|
38
|
+
wf.src = ('https:' == document.location.protocol ? 'https' : 'http') +
|
39
|
+
'://ajax.googleapis.com/ajax/libs/webfont/1/webfont.js';
|
40
|
+
wf.type = 'text/javascript';
|
41
|
+
wf.async = 'true';
|
42
|
+
var s = document.getElementsByTagName('script')[0];
|
43
|
+
s.parentNode.insertBefore(wf, s);
|
44
|
+
})();
|
45
|
+
</script>
|
46
|
+
|
47
|
+
<script src="dist/app.js"></script>
|
48
|
+
|
49
|
+
</body>
|
50
|
+
|
51
|
+
</html>
|
@@ -0,0 +1,38 @@
|
|
1
|
+
{
|
2
|
+
"name": "material-ui-example",
|
3
|
+
"version": "0.0.1",
|
4
|
+
"description": "Sample project that uses material-ui",
|
5
|
+
"browserify": {
|
6
|
+
"transform": [
|
7
|
+
[
|
8
|
+
"reactify",
|
9
|
+
{
|
10
|
+
"es6": true
|
11
|
+
}
|
12
|
+
]
|
13
|
+
]
|
14
|
+
},
|
15
|
+
"devDependencies": {
|
16
|
+
"browser-sync": "^1.8.1",
|
17
|
+
"browserify": "^7.0.3",
|
18
|
+
"gulp": "^3.8.10",
|
19
|
+
"gulp-autoprefixer": "^2.0.0",
|
20
|
+
"gulp-less": "^3.0.3",
|
21
|
+
"gulp-notify": "^2.1.0",
|
22
|
+
"gulp-sourcemaps": "^1.2.8",
|
23
|
+
"gulp-util": "^3.0.1",
|
24
|
+
"pretty-hrtime": "^0.2.2",
|
25
|
+
"reactify": "^0.17.1",
|
26
|
+
"require-dir": "^0.1.0",
|
27
|
+
"underscore": "^1.7.0",
|
28
|
+
"vinyl-source-stream": "^1.0.0",
|
29
|
+
"watchify": "^2.2.1"
|
30
|
+
},
|
31
|
+
"dependencies": {
|
32
|
+
"d3": "^3.5.5",
|
33
|
+
"material-ui": "^0.4.1",
|
34
|
+
"nutella_lib": "^0.5.1",
|
35
|
+
"react": "^0.12.2",
|
36
|
+
"react-tap-event-plugin": "^0.1.3"
|
37
|
+
}
|
38
|
+
}
|
@@ -0,0 +1,19 @@
|
|
1
|
+
(function () {
|
2
|
+
var React = require('react'),
|
3
|
+
injectTapEventPlugin = require("react-tap-event-plugin"),
|
4
|
+
Main = require('./components/main.js');
|
5
|
+
|
6
|
+
//Needed for React Developer Tools
|
7
|
+
window.React = React;
|
8
|
+
|
9
|
+
//Needed for onTouchTap
|
10
|
+
//Can go away when react 1.0 release
|
11
|
+
//Check this repo:
|
12
|
+
//https://github.com/zilverline/react-tap-event-plugin
|
13
|
+
injectTapEventPlugin();
|
14
|
+
|
15
|
+
// Render the main app react component into the document body.
|
16
|
+
// For more details see: https://facebook.github.io/react/docs/top-level-api.html#react.render
|
17
|
+
window.ReactMain = React.render( <Main /> , document.body);
|
18
|
+
|
19
|
+
})();
|
data/framework_components/roomcast-package-creator/src/app/components/ButtonInteractionsMixin.js
ADDED
@@ -0,0 +1,45 @@
|
|
1
|
+
|
2
|
+
var ButtonInteractionsMixin = {
|
3
|
+
|
4
|
+
insertNewChannel: function(channels, chId) {
|
5
|
+
|
6
|
+
var newChannels = [];
|
7
|
+
var found = false;
|
8
|
+
for(var i=0; i<channels.length; i++) {
|
9
|
+
if (+chId === +channels[i]) {
|
10
|
+
return channels;
|
11
|
+
}
|
12
|
+
if(+chId < +channels[i] && !found) {
|
13
|
+
newChannels.push(chId);
|
14
|
+
newChannels.push(channels[i]);
|
15
|
+
found = true;
|
16
|
+
} else {
|
17
|
+
newChannels.push(channels[i]);
|
18
|
+
}
|
19
|
+
}
|
20
|
+
if(!found) {
|
21
|
+
newChannels.push(chId);
|
22
|
+
}
|
23
|
+
|
24
|
+
return newChannels;
|
25
|
+
},
|
26
|
+
|
27
|
+
removeChannel: function(channels, chId) {
|
28
|
+
|
29
|
+
var newChannels = [];
|
30
|
+
for(var ch in channels) {
|
31
|
+
newChannels.push(channels[ch]);
|
32
|
+
}
|
33
|
+
for(var i = newChannels.length; i>=0; i--) {
|
34
|
+
if(newChannels[i] === chId) {
|
35
|
+
newChannels.splice(i, 1);
|
36
|
+
}
|
37
|
+
}
|
38
|
+
|
39
|
+
return newChannels;
|
40
|
+
|
41
|
+
}
|
42
|
+
|
43
|
+
};
|
44
|
+
|
45
|
+
module.exports = ButtonInteractionsMixin;
|
@@ -0,0 +1,87 @@
|
|
1
|
+
var React = require('react');
|
2
|
+
var Mui = require('material-ui');
|
3
|
+
var Paper = Mui.Paper;
|
4
|
+
|
5
|
+
/**
|
6
|
+
* @prop selectedChannel
|
7
|
+
* @prop channels
|
8
|
+
*/
|
9
|
+
var ChannelCard = React.createClass({
|
10
|
+
|
11
|
+
handleSelectCard: function() {
|
12
|
+
|
13
|
+
if(this.props.currentSelectedChannel && this.props.currentSelectedChannel.id === this.props.channelId) {
|
14
|
+
this.props.onSelectedChannel(null);
|
15
|
+
} else {
|
16
|
+
// set selected channel (state)
|
17
|
+
var newSelected = {
|
18
|
+
id: this.props.channelId,
|
19
|
+
belongsTo: 'channels',
|
20
|
+
imgNode: null,
|
21
|
+
channel: null,
|
22
|
+
channelData: this.props.channelData
|
23
|
+
};
|
24
|
+
this.props.onSelectedChannel(newSelected);
|
25
|
+
|
26
|
+
}
|
27
|
+
|
28
|
+
},
|
29
|
+
|
30
|
+
render: function() {
|
31
|
+
|
32
|
+
var style = {
|
33
|
+
backgroundImage: 'url(' + this.props.channelData.screenshot + ')',
|
34
|
+
backgroundSize: '100% 100%'
|
35
|
+
};
|
36
|
+
|
37
|
+
if(this.props.currentSelectedChannel) {
|
38
|
+
if(this.props.currentSelectedChannel.id !== this.props.channelId) {
|
39
|
+
style.opacity = '0.5';
|
40
|
+
}
|
41
|
+
}
|
42
|
+
|
43
|
+
var iconStyle = {
|
44
|
+
backgroundColor: this.props.channelData.icon
|
45
|
+
};
|
46
|
+
|
47
|
+
var description =
|
48
|
+
<p className='channel-description'> {this.props.channelData.description} </p>;
|
49
|
+
|
50
|
+
return (
|
51
|
+
|
52
|
+
<div className="col-1-3" >
|
53
|
+
|
54
|
+
<Paper className='channel-card'
|
55
|
+
ref={'channel' + this.props.channelId}
|
56
|
+
zDepth={3}
|
57
|
+
style={style}
|
58
|
+
onTouchTap={this.handleSelectCard} >
|
59
|
+
|
60
|
+
<div className='channel-div'>
|
61
|
+
|
62
|
+
<div className='channel-caption'>
|
63
|
+
|
64
|
+
<div className='icon-name-wrapper'>
|
65
|
+
|
66
|
+
<div className='channel-icon' ref='channelIcon' style={iconStyle} > </div>
|
67
|
+
|
68
|
+
<div className='name-wrapper'>
|
69
|
+
<p className='channel-name'> {this.props.channelData.name} </p>
|
70
|
+
</div>
|
71
|
+
|
72
|
+
</div>
|
73
|
+
|
74
|
+
</div>
|
75
|
+
|
76
|
+
</div>
|
77
|
+
|
78
|
+
</Paper>
|
79
|
+
|
80
|
+
</div>);
|
81
|
+
|
82
|
+
}
|
83
|
+
|
84
|
+
});
|
85
|
+
|
86
|
+
module.exports = ChannelCard;
|
87
|
+
|
@@ -0,0 +1,71 @@
|
|
1
|
+
var React = require('react');
|
2
|
+
var Mui = require('material-ui');
|
3
|
+
var d3 = require('d3');
|
4
|
+
var Paper = Mui.Paper;
|
5
|
+
|
6
|
+
/**
|
7
|
+
* @prop id
|
8
|
+
* @prop name
|
9
|
+
* @prop imgPath
|
10
|
+
* @prop onSelectedChannel
|
11
|
+
* @prop currentSelectedChannel
|
12
|
+
* @prop belongsTo
|
13
|
+
*/
|
14
|
+
var ChannelItem = React.createClass({
|
15
|
+
|
16
|
+
/**
|
17
|
+
* Manages the interactions with the channels.
|
18
|
+
*/
|
19
|
+
handleSelectedChannel: function() {
|
20
|
+
|
21
|
+
var imgNode = this.refs.channelIcon.getDOMNode();
|
22
|
+
var currentSelected = this.props.currentSelectedChannel;
|
23
|
+
|
24
|
+
if(currentSelected && currentSelected.imgNode && currentSelected.id === this.props.id && currentSelected.imgNode == imgNode) {
|
25
|
+
|
26
|
+
// set not selected
|
27
|
+
this.props.onSelectedChannel(null);
|
28
|
+
|
29
|
+
} else {
|
30
|
+
|
31
|
+
// set selected channel (state)
|
32
|
+
var newSelected = {
|
33
|
+
id: this.props.id,
|
34
|
+
belongsTo: this.props.belongsTo,
|
35
|
+
imgNode: imgNode,
|
36
|
+
channel: this,
|
37
|
+
channelData: this.props.channelData
|
38
|
+
};
|
39
|
+
this.props.onSelectedChannel(newSelected);
|
40
|
+
}
|
41
|
+
|
42
|
+
},
|
43
|
+
|
44
|
+
render: function() {
|
45
|
+
|
46
|
+
var iconStyle = {
|
47
|
+
backgroundColor: this.props.channelData.icon
|
48
|
+
};
|
49
|
+
|
50
|
+
// style channels in resources list
|
51
|
+
if(this.props.belongsTo==='resources') {
|
52
|
+
var currentSelected = this.props.currentSelectedChannel;
|
53
|
+
if(currentSelected && (currentSelected.channel == this) && currentSelected.id === this.props.id) {
|
54
|
+
iconStyle.border = '3px solid black';
|
55
|
+
}
|
56
|
+
|
57
|
+
}
|
58
|
+
|
59
|
+
return (
|
60
|
+
<div className='channel-item' onClick={this.handleSelectedChannel}>
|
61
|
+
<div className='channel-icon' ref='channelIcon' style={iconStyle} > </div>
|
62
|
+
<span> {this.props.name} </span>
|
63
|
+
</div>
|
64
|
+
);
|
65
|
+
|
66
|
+
}
|
67
|
+
|
68
|
+
});
|
69
|
+
|
70
|
+
module.exports = ChannelItem;
|
71
|
+
|
@@ -0,0 +1,64 @@
|
|
1
|
+
var React = require('react');
|
2
|
+
var Mui = require('material-ui');
|
3
|
+
var ChannelCard = require('./ChannelCard');
|
4
|
+
|
5
|
+
var ChannelsCatalogue = React.createClass({
|
6
|
+
|
7
|
+
handleSelectedChannel: function(ch) {
|
8
|
+
this.props.onSelectedChannel(ch);
|
9
|
+
},
|
10
|
+
|
11
|
+
handleStyleRespectiveChannel: function() {
|
12
|
+
var selected = this.props.selectedChannel;
|
13
|
+
for(ref in this.refs) {
|
14
|
+
console.log(ref, selected);
|
15
|
+
if(this.refs[ref].props.id===selected.id) {
|
16
|
+
console.log(selected.imgNode);
|
17
|
+
break;
|
18
|
+
}
|
19
|
+
}
|
20
|
+
},
|
21
|
+
|
22
|
+
render: function() {
|
23
|
+
|
24
|
+
var channels = [];
|
25
|
+
var chs = this.props.channels;
|
26
|
+
var keys = Object.keys(chs).sort();
|
27
|
+
for(var i = 0; i < keys.length; i++) {
|
28
|
+
var key = keys[i];
|
29
|
+
|
30
|
+
// set respective selected channel in channels list
|
31
|
+
var respectiveSelected = null;
|
32
|
+
if(this.props.selectedChannel && key===this.props.selectedChannel.id) {
|
33
|
+
respectiveSelected = true;
|
34
|
+
}
|
35
|
+
|
36
|
+
channels.push(<ChannelCard
|
37
|
+
id={key}
|
38
|
+
key={key}
|
39
|
+
channelData={chs[key]}
|
40
|
+
channelId={key}
|
41
|
+
currentSelectedChannel={this.props.selectedChannel}
|
42
|
+
respectiveSelected={respectiveSelected}
|
43
|
+
onSelectedChannel={this.handleSelectedChannel} />
|
44
|
+
);
|
45
|
+
}
|
46
|
+
|
47
|
+
var backgroundMessage = null; //TODO
|
48
|
+
|
49
|
+
return (
|
50
|
+
<div className='content-div'>
|
51
|
+
|
52
|
+
{backgroundMessage}
|
53
|
+
|
54
|
+
<div className="grid" ref='gridRef' >
|
55
|
+
{channels}
|
56
|
+
</div>
|
57
|
+
</div>
|
58
|
+
)
|
59
|
+
}
|
60
|
+
|
61
|
+
});
|
62
|
+
|
63
|
+
module.exports = ChannelsCatalogue;
|
64
|
+
|