2015-07-13 01:57:15 +02:00
|
|
|
<link rel="import" href="../../bower_components/polymer/polymer.html">
|
|
|
|
|
2016-08-19 09:28:35 +02:00
|
|
|
<link rel="import" href="state-card-climate.html">
|
2015-07-13 01:57:15 +02:00
|
|
|
<link rel="import" href="state-card-configurator.html">
|
2016-08-24 03:24:12 +02:00
|
|
|
<link rel="import" href="state-card-cover.html">
|
2016-01-31 20:57:58 +01:00
|
|
|
<link rel="import" href="state-card-display.html">
|
2016-01-31 22:36:40 +01:00
|
|
|
<link rel="import" href="state-card-input_select.html">
|
2016-03-15 19:40:08 +01:00
|
|
|
<link rel="import" href="state-card-input_slider.html">
|
2015-07-13 01:57:15 +02:00
|
|
|
<link rel="import" href="state-card-media_player.html">
|
2016-01-31 20:57:58 +01:00
|
|
|
<link rel="import" href="state-card-scene.html">
|
2016-02-28 08:12:57 +01:00
|
|
|
<link rel="import" href="state-card-script.html">
|
2016-01-31 20:57:58 +01:00
|
|
|
<link rel="import" href="state-card-toggle.html">
|
|
|
|
<link rel="import" href="state-card-weblink.html">
|
2016-07-18 08:18:48 +02:00
|
|
|
|
|
|
|
<script>
|
|
|
|
Polymer({
|
|
|
|
is: 'state-card-content',
|
|
|
|
|
|
|
|
properties: {
|
|
|
|
hass: {
|
|
|
|
type: Object,
|
|
|
|
},
|
|
|
|
|
|
|
|
inDialog: {
|
|
|
|
type: Boolean,
|
|
|
|
value: false,
|
|
|
|
},
|
|
|
|
|
|
|
|
stateObj: {
|
|
|
|
type: Object,
|
|
|
|
},
|
|
|
|
},
|
|
|
|
|
|
|
|
observers: [
|
|
|
|
'inputChanged(hass, inDialog, stateObj)',
|
|
|
|
],
|
|
|
|
|
|
|
|
inputChanged: function (hass, inDialog, stateObj) {
|
2017-01-30 03:34:45 +01:00
|
|
|
if (!stateObj || !hass) return;
|
2016-07-18 08:18:48 +02:00
|
|
|
|
|
|
|
window.hassUtil.dynamicContentUpdater(
|
|
|
|
this,
|
|
|
|
('STATE-CARD-' +
|
2017-01-30 03:34:45 +01:00
|
|
|
window.hassUtil.stateCardType(hass, stateObj).toUpperCase()),
|
2016-07-18 08:18:48 +02:00
|
|
|
{
|
|
|
|
hass: hass,
|
|
|
|
stateObj: stateObj,
|
|
|
|
inDialog: inDialog,
|
|
|
|
});
|
|
|
|
},
|
|
|
|
});
|
|
|
|
</script>
|