Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added label field to options #14

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .vs/ProjectSettings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"CurrentProjectSetting": null
}
9 changes: 9 additions & 0 deletions .vs/VSWorkspaceState.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"ExpandedNodes": [
"",
"\\dist",
"\\src"
],
"SelectedNode": "\\src\\pictureit_ctrl.js",
"PreviewInSolutionExplorer": false
}
1,031 changes: 1,031 additions & 0 deletions .vs/config/applicationhost.config

Large diffs are not rendered by default.

Binary file added .vs/grafana-pictureit/v15/.suo
Binary file not shown.
Binary file added .vs/slnx.sqlite
Binary file not shown.
2 changes: 1 addition & 1 deletion dist/angular-sprintf.js.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 5 additions & 0 deletions dist/editor.html
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,11 @@ <h5 class="section-heading">&nbsp</h5>
</div>
<div class="section gf-form-group">
<h5 class="section-heading">Metric</h5>
<div class="gf-form" max-width-25>
<label class="gf-form-label width-5">Label</label>
<input type="text" class="input-small gf-form-input " ng-model="sensor.label" ng-change="ctrl.render()" ng-model-onblur />
</div>

<div class="gf-form" max-width-25>
<label class="gf-form-label width-5">Name</label>
<input type="text" class="input-small gf-form-input " ng-model="sensor.name" ng-change="ctrl.render()" ng-model-onblur />
Expand Down
9 changes: 7 additions & 2 deletions dist/module.html
Original file line number Diff line number Diff line change
@@ -1,8 +1,13 @@
<div ng-style="{height:ctrl.panel.height,width:'100%','background-repeat':'no-repeat','background-image':'url('+ctrl.panel.bgimage+')'}">
<div ng-style="{height:ctrl.panel.height,width:'100%','background-repeat':'no-repeat','background-image':'url('+ctrl.panel.bgimage+')', 'background-size':'contain'}">
<div ng-repeat="sensor in ctrl.panel.sensors">
<div ng-if="sensor.visible">
<div ng-style="{position: 'relative', left:sensor.xlocationStr, top:sensor.ylocationStr, 'font-size':sensor.sizeStr,color:sensor.color}">
<div ng-style="{position: 'absolute', top: 0, left: 0,'background-color': sensor.bgcolor,'border-style':'solid','border-color':sensor.bordercolor,'border-width':'1px',padding:'5px'}">
<div ng-style="{position: 'absolute',
top: 0,
left: 0,
'background-color': sensor.bgcolor,
'border-style':'solid','border-color':sensor.bordercolor,'border-width':'1px',padding:'5px'}">
<span style="color: {{sensor.color}}">{{sensor.label}}</span>
<a href="{{sensor.link_url}}" bs-tooltip="sensor.link_hover" style="color: {{sensor.color}}">
{{sensor.valueFormatted}} {{sensor.valueUnit}}
</a>
Expand Down
2 changes: 1 addition & 1 deletion dist/module.js.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/pictureit_ctrl.js.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/sprintf.js.map

Large diffs are not rendered by default.

35 changes: 18 additions & 17 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,25 +16,26 @@
"author": "Bessler",
"license": "MIT",
"devDependencies": {
"babel": "~6.5.1",
"babel-eslint": "^6.0.0",
"babel-plugin-transform-es2015-modules-systemjs": "^6.5.0",
"babel-preset-es2015": "^6.5.0",
"eslint": "^2.5.1",
"eslint-config-airbnb": "^6.2.0",
"eslint-plugin-import": "^1.4.0",
"grunt": "~0.4.5",
"grunt-babel": "~6.0.0",
"babel": "^6.23.0",
"babel-eslint": "^8.0.1",
"babel-plugin-transform-es2015-modules-systemjs": "^6.24.1",
"babel-preset-es2015": "^6.24.1",
"eslint": "^4.10.0",
"eslint-config-airbnb": "^16.1.0",
"eslint-plugin-import": "^2.8.0",
"grunt": "^1.0.1",
"grunt-babel": "^7.0.0",
"grunt-cli": "^1.2.0",
"grunt-contrib-clean": "~0.6.0",
"grunt-contrib-copy": "~0.8.2",
"grunt-contrib-uglify": "~0.11.0",
"grunt-contrib-watch": "^0.6.1",
"grunt-execute": "~0.2.2",
"grunt-systemjs-builder": "^0.2.5",
"load-grunt-tasks": "~3.2.0"
"grunt-contrib-clean": "^1.1.0",
"grunt-contrib-copy": "^1.0.0",
"grunt-contrib-uglify": "^3.1.0",
"grunt-contrib-watch": "^1.0.0",
"grunt-execute": "^0.2.2",
"grunt-systemjs-builder": "^1.0.0",
"load-grunt-tasks": "^3.5.2"
},
"dependencies": {
"lodash": "~4.0.0"
"load-grunt-tasks": "^3.2.0",
"lodash": "^4.17.4"
}
}
5 changes: 5 additions & 0 deletions src/editor.html
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,11 @@ <h5 class="section-heading">&nbsp</h5>
</div>
<div class="section gf-form-group">
<h5 class="section-heading">Metric</h5>
<div class="gf-form" max-width-25>
<label class="gf-form-label width-5">Label</label>
<input type="text" class="input-small gf-form-input " ng-model="sensor.label" ng-change="ctrl.render()" ng-model-onblur />
</div>

<div class="gf-form" max-width-25>
<label class="gf-form-label width-5">Name</label>
<input type="text" class="input-small gf-form-input " ng-model="sensor.name" ng-change="ctrl.render()" ng-model-onblur />
Expand Down
9 changes: 7 additions & 2 deletions src/module.html
Original file line number Diff line number Diff line change
@@ -1,8 +1,13 @@
<div ng-style="{height:ctrl.panel.height,width:'100%','background-repeat':'no-repeat','background-image':'url('+ctrl.panel.bgimage+')'}">
<div ng-style="{height:ctrl.panel.height,width:'100%','background-repeat':'no-repeat','background-image':'url('+ctrl.panel.bgimage+')', 'background-size':'contain'}">
<div ng-repeat="sensor in ctrl.panel.sensors">
<div ng-if="sensor.visible">
<div ng-style="{position: 'relative', left:sensor.xlocationStr, top:sensor.ylocationStr, 'font-size':sensor.sizeStr,color:sensor.color}">
<div ng-style="{position: 'absolute', top: 0, left: 0,'background-color': sensor.bgcolor,'border-style':'solid','border-color':sensor.bordercolor,'border-width':'1px',padding:'5px'}">
<div ng-style="{position: 'absolute',
top: 0,
left: 0,
'background-color': sensor.bgcolor,
'border-style':'solid','border-color':sensor.bordercolor,'border-width':'1px',padding:'5px'}">
<span style="color: {{sensor.color}}">{{sensor.label}}</span>
<a href="{{sensor.link_url}}" bs-tooltip="sensor.link_hover" style="color: {{sensor.color}}">
{{sensor.valueFormatted}} {{sensor.valueUnit}}
</a>
Expand Down