mirror of
https://github.com/home-assistant/frontend.git
synced 2025-07-23 01:06:35 +00:00
Lint
This commit is contained in:
parent
267c0d51e1
commit
e570c961e8
@ -22,7 +22,7 @@
|
|||||||
"watch_ru_core": "rollup --config rollup/core.js --watch --sourcemap inline",
|
"watch_ru_core": "rollup --config rollup/core.js --watch --sourcemap inline",
|
||||||
"watch_ru_demo": "rollup --config rollup/demo.js --watch --sourcemap inline",
|
"watch_ru_demo": "rollup --config rollup/demo.js --watch --sourcemap inline",
|
||||||
"lint_js": "eslint src panels --ext html",
|
"lint_js": "eslint src panels --ext html",
|
||||||
"lint_html": "ls -1 src/**/*.html panels/**/*.html | xargs polymer lint --input",
|
"lint_html": "ls -1 src/home-assistant.html panels/**/ha-panel-*.html | xargs polymer lint --input",
|
||||||
"test": "npm run lint_js && npm run lint_html"
|
"test": "npm run lint_js && npm run lint_html"
|
||||||
},
|
},
|
||||||
"author": "Paulus Schoutsen <Paulus@PaulusSchoutsen.nl> (http://paulusschoutsen.nl)",
|
"author": "Paulus Schoutsen <Paulus@PaulusSchoutsen.nl> (http://paulusschoutsen.nl)",
|
||||||
|
@ -75,14 +75,14 @@ Polymer({
|
|||||||
var bounds;
|
var bounds;
|
||||||
|
|
||||||
if (this._mapItems.length === 0) {
|
if (this._mapItems.length === 0) {
|
||||||
this._map.setView(new L.LatLng(this.hass.config.core.latitude,
|
this._map.setView(
|
||||||
this.hass.config.core.longitude), 14);
|
new window.L.LatLng(this.hass.config.core.latitude, this.hass.config.core.longitude),
|
||||||
|
14);
|
||||||
} else {
|
} else {
|
||||||
bounds = new window.L.latLngBounds(
|
bounds = new window.L.latLngBounds(
|
||||||
this._mapItems.map(function (item) { return item.getLatLng(); }));
|
this._mapItems.map(function (item) { return item.getLatLng(); }));
|
||||||
this._map.fitBounds(bounds.pad(0.5));
|
this._map.fitBounds(bounds.pad(0.5));
|
||||||
}
|
}
|
||||||
|
|
||||||
},
|
},
|
||||||
|
|
||||||
drawEntities: function (hass) {
|
drawEntities: function (hass) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user