WebRTC
WebRTC copied to clipboard
[FEATURE REQUEST] Add button like picture glance
Very useful for opening gates, switch lights or tts
Try ;)
Thanks, but was better directly in webrtc ui
You can check this in latest master version: https://github.com/AlexxIT/WebRTC/pull/169
Thanks, it's already on the latest release?
No. Only in master version
Not works 021-12-08 07:50:45 ERROR (MainThread) [frontend.js.latest.202112060] https://xxxxxxxxxxxxxxxxxxxxxxxxxx:8123/webrtc/webrtc-camera.js?v2.0.2:332:22 Uncaught TypeError: Cannot read properties of undefined (reading 'callService')
Not works 021-12-08 07:50:45 ERROR (MainThread) [frontend.js.latest.202112060] https://xxxxxxxxxxxxxxxxxxxxxxxxxx:8123/webrtc/webrtc-camera.js?v2.0.2:332:22 Uncaught TypeError: Cannot read properties of undefined (reading 'callService')
Settings and file content please. So what version of hass do you have?
Not works 021-12-08 07:50:45 ERROR (MainThread) [frontend.js.latest.202112060] https://xxxxxxxxxxxxxxxxxxxxxxxxxx:8123/webrtc/webrtc-camera.js?v2.0.2:332:22 Uncaught TypeError: Cannot read properties of undefined (reading 'callService')
Settings and file content please. So what version of hass do you have?
Everything is fine, I didn't add a feature: ui: true
with buttons it shows entity state, is possible to have the same thing here? like with picture glance?
through card-mod you can do
example:
type: custom:webrtc-camera
style: |
.shortcuts > .shortcut-0 {
color: {% if is_state('switch.xiaomi_dafang_record', 'on') %}
#df4d1d
{% else %}
white
{% endif %};
animation: {% if is_state('switch.xiaomi_dafang_record', 'on') %}
1s ease 0s infinite normal none running pulse;
{% else %}
none
{% endif %};
}
.shortcuts > .shortcut-1 {
color: {% if is_state('switch.dafang_night_mode_2', 'on') %}
var(--paper-item-icon-active-color, #fdd835)
{% else %}
white
{% endif %};
}
entity: camera.dafang3
ui: true
shortcuts:
- name: Запись
icon: mdi:record-circle-outline
service: switch.toggle
service_data:
entity_id: switch.xiaomi_dafang_record
- name: Ночной режим
icon: mdi:theme-light-dark
service: switch.toggle
service_data:
entity_id: switch.dafang_night_mode_2
- name: Перезагрузить
icon: mdi:refresh-circle
service: switch.toggle
service_data:
entity_id: switch.xiaomi_dafang_power
Thanks
Does the shortcuts also support entity states where icons change color for example the cameras motion?
Does the shortcuts also support entity states where icons change color for example the cameras motion?
o wrote above. you can use card_mode
But with that I can't see other status, like images for plex or light color
Thought it would be easier and cleaner if it was built in since the function already exists in HA instead of adding custom CSS
it will turn out a little differently and it will be necessary to re-saw all the js that is connected. but such a principle is possible.
Hi, I'm trying to add my presets ONVIF, but how can chage position (bottom center) and text (white) and background (black) to my shortcuts? Thanks!
Hi, I'm trying to add my presets ONVIF, but how can chage position (bottom center) and text (white) and background (black) to my shortcuts? Thanks!
first, you need the version from the wizard. secondly, the card-mod component is required.
Hi, I'm trying to add my presets ONVIF, but how can chage position (bottom center) and text (white) and background (black) to my shortcuts? Thanks!
first, you need the version from the wizard. secondly, the card-mod component is required.
Thanks! I did not know about card mod!
can you do somehow picture-elements, so you have an overlay of say a temperature sensor icon and value on the camera image?
Is there any way to put sensor icons overlayed on the webrtc-camera card eg change an icon (ideally the icon and colour) when there's motion detected?
I haven't been able to get things like this to work:
title: Drive Cam via WebRTC
type: custom:webrtc-camera
entity: camera.drive_camera
muted: true
ui: true
shortcuts:
top: 25
left: 5
services:
- name: Motion
icon: >
{% if is_state('binary_sensor.drive_camera_motion', 'Detected') return
'mdi:motion-sensor'; else return 'mdi:motion-sensor-off'; %}
@Liam-Whiteside I think you can solve it with template sensor
style
settings supported from integration v3