Skip to content

Commit bb77070

Browse files
committed
Merge branch 'master' of https://github.com/grafana/grafana into ds-conf-box
2 parents c051ff3 + ac5f7ec commit bb77070

File tree

28 files changed

+220
-50
lines changed

28 files changed

+220
-50
lines changed

examples/nginx-app/.gitignore

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
.DS_Store
2+
3+
node_modules
4+
tmp/*
5+
npm-debug.log
6+
dist/*
7+

examples/nginx-app/.jscs.json

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
{
2+
"disallowImplicitTypeConversion": ["string"],
3+
"disallowKeywords": ["with"],
4+
"disallowMultipleLineBreaks": true,
5+
"disallowMixedSpacesAndTabs": true,
6+
"disallowTrailingWhitespace": true,
7+
"requireSpacesInFunctionExpression": {
8+
"beforeOpeningCurlyBrace": true
9+
},
10+
"disallowSpacesInsideArrayBrackets": true,
11+
"disallowSpacesInsideParentheses": true,
12+
"validateIndentation": 2
13+
}

examples/nginx-app/.jshintrc

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
{
2+
"browser": true,
3+
"esnext": true,
4+
5+
"bitwise":false,
6+
"curly": true,
7+
"eqnull": true,
8+
"devel": true,
9+
"eqeqeq": true,
10+
"forin": false,
11+
"immed": true,
12+
"supernew": true,
13+
"expr": true,
14+
"indent": 2,
15+
"latedef": true,
16+
"newcap": true,
17+
"noarg": true,
18+
"noempty": true,
19+
"undef": true,
20+
"boss": true,
21+
"trailing": true,
22+
"laxbreak": true,
23+
"laxcomma": true,
24+
"sub": true,
25+
"unused": true,
26+
"maxdepth": 6,
27+
"maxlen": 140,
28+
29+
"globals": {
30+
"System": true,
31+
"define": true,
32+
"require": true,
33+
"Chromath": false,
34+
"setImmediate": true
35+
}
36+
}

examples/nginx-app/Gruntfile.js

Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
module.exports = function(grunt) {
2+
3+
require('load-grunt-tasks')(grunt);
4+
5+
grunt.loadNpmTasks('grunt-execute');
6+
grunt.loadNpmTasks('grunt-contrib-clean');
7+
8+
grunt.initConfig({
9+
10+
clean: ["dist"],
11+
12+
copy: {
13+
src_to_dist: {
14+
cwd: 'src',
15+
expand: true,
16+
src: ['**/*', '!**/*.js', '!**/*.scss'],
17+
dest: 'dist'
18+
},
19+
pluginDef: {
20+
expand: true,
21+
src: 'plugin.json',
22+
dest: 'dist',
23+
}
24+
},
25+
26+
watch: {
27+
rebuild_all: {
28+
files: ['src/**/*', 'plugin.json'],
29+
tasks: ['default'],
30+
options: {spawn: false}
31+
},
32+
},
33+
34+
babel: {
35+
options: {
36+
sourceMap: true,
37+
presets: ["es2015"],
38+
plugins: ['transform-es2015-modules-systemjs', "transform-es2015-for-of"],
39+
},
40+
dist: {
41+
files: [{
42+
cwd: 'src',
43+
expand: true,
44+
src: ['**/*.js'],
45+
dest: 'dist',
46+
ext:'.js'
47+
}]
48+
},
49+
},
50+
51+
});
52+
53+
grunt.registerTask('default', ['clean', 'copy:src_to_dist', 'copy:pluginDef', 'babel']);
54+
};

examples/nginx-app/module.js

Lines changed: 0 additions & 20 deletions
This file was deleted.

examples/nginx-app/package.json

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
{
2+
"name": "kentik-app",
3+
"private": true,
4+
"version": "1.0.0",
5+
"description": "",
6+
"main": "index.js",
7+
"scripts": {
8+
"test": "echo \"Error: no test specified\" && exit 1"
9+
},
10+
"repository": {
11+
"type": "git",
12+
"url": "git+https://github.com/raintank/kentik-app-poc.git"
13+
},
14+
"author": "",
15+
"license": "ISC",
16+
"bugs": {
17+
"url": "https://github.com/raintank/kentik-app-poc/issues"
18+
},
19+
"devDependencies": {
20+
"grunt": "~0.4.5",
21+
"babel": "~6.5.1",
22+
"grunt-babel": "~6.0.0",
23+
"grunt-contrib-copy": "~0.8.2",
24+
"grunt-contrib-watch": "^0.6.1",
25+
"grunt-contrib-uglify": "~0.11.0",
26+
"grunt-systemjs-builder": "^0.2.5",
27+
"load-grunt-tasks": "~3.2.0",
28+
"grunt-execute": "~0.2.2",
29+
"grunt-contrib-clean": "~0.6.0"
30+
},
31+
"dependencies": {
32+
"babel-plugin-transform-es2015-modules-systemjs": "^6.5.0",
33+
"babel-preset-es2015": "^6.5.0",
34+
"lodash": "~4.0.0"
35+
},
36+
"homepage": "https://github.com/raintank/kentik-app-poc#readme"
37+
}

examples/nginx-app/panel/module.js

Lines changed: 0 additions & 21 deletions
This file was deleted.

examples/nginx-app/partials/config.html

Lines changed: 0 additions & 1 deletion
This file was deleted.

examples/nginx-app/partials/logs.html

Lines changed: 0 additions & 2 deletions
This file was deleted.

examples/nginx-app/partials/stream.html

Lines changed: 0 additions & 1 deletion
This file was deleted.
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
<h3>
2+
Nginx config!
3+
</h3>
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
2+
export class NginxAppConfigCtrl {
3+
}
4+
NginxAppConfigCtrl.templateUrl = 'components/config.html';
5+
6+
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
<h3>
2+
Logs page!
3+
</h3>
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
2+
export class LogsPageCtrl {
3+
}
4+
LogsPageCtrl.templateUrl = 'components/logs.html';
5+
6+
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
<h3>
2+
Stream page!
3+
</h3>
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
2+
export class StreamPageCtrl {
3+
}
4+
StreamPageCtrl.templateUrl = 'components/stream.html';
5+
6+
File renamed without changes.
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
require([
2+
], function () {
3+
4+
function Dashboard() {
5+
6+
this.getInputs = function() {
7+
8+
};
9+
10+
this.buildDashboard = function() {
11+
12+
};
13+
}
14+
15+
return Dashboard;
16+
});
17+

examples/nginx-app/src/module.js

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
import {LogsPageCtrl} from './components/logs';
2+
import {StreamPageCtrl} from './components/stream';
3+
import {NginxAppConfigCtrl} from './components/config';
4+
5+
export {
6+
NginxAppConfigCtrl as ConfigCtrl,
7+
StreamPageCtrl,
8+
LogsPageCtrl
9+
};
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
import {PanelCtrl} from 'app/plugins/sdk';
2+
3+
class NginxPanelCtrl extends PanelCtrl {
4+
5+
constructor($scope, $injector) {
6+
super($scope, $injector);
7+
}
8+
9+
}
10+
NginxPanelCtrl.template = '<h2>nginx!</h2>';
11+
12+
export {
13+
NginxPanelCtrl as PanelCtrl
14+
};
15+

public/app/features/panel/panel_directive.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ var panelTemplate = `
3232
<div class="gf-box-header">
3333
<div class="gf-box-title">
3434
<i ng-class="ctrl.icon"></i>
35-
{{ctrl.name}}
35+
{{ctrl.pluginName}}
3636
</div>
3737
3838
<div ng-model="ctrl.editorTabIndex" bs-tabs>

public/app/features/panel/partials/soloPanel.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22
<div class="row-fluid">
33
<div class="span12">
44
<div class="panel nospace" ng-if="panel" style="width: 100%">
5-
<panel-loader dashboard="dashboard" row="row" panel="panel">
6-
</panel-loader>
5+
<plugin-component type="panel">
6+
</plugin-component>
77
</div>
88
</div>
99
</div>

public/app/partials/signup_step2.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
<div class="login-box">
77

88
<div class="login-box-logo">
9-
<img src="img/logo_transparent_200x75.png">
9+
<img src="public/img/logo_transparent_200x75.png">
1010
</div>
1111

1212
<div class="invite-box">

public/app/plugins/datasource/graphite/add_graphite_func.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ function (angular, _, $, gfunc) {
9999
submenu: _.map(list, function(value) {
100100
return {
101101
text: value.name,
102-
click: "addFunction('" + value.name + "')",
102+
click: "ctrl.addFunction('" + value.name + "')",
103103
};
104104
})
105105
};

0 commit comments

Comments
 (0)