Skip to content

Instantly share code, notes, and snippets.

@Mariusthvdb
Mariusthvdb / text-input-full-row.js
Last active May 1, 2023 07:57
experimental rebuild of text-input-row to use Lit in stead of Polymer
const Name = "Text-input-full-row";
const Version = "2023.5.01";
const Description = "adapted to use local Lit";
const Url = "https://github.com/Mariusthvdb/text-input-full-row";
console.info(
`%c ${Name} \n%c Version ${Version} ${Description}`,
"color: gold; font-weight: bold; background: black",
"color: white; font-weight: bold; background: steelblue"
);
@Mariusthvdb
Mariusthvdb / buttons_dashboard_menu.yaml
Last active March 31, 2023 14:25
Buttons for dashboard menu
type: horizontal-stack
cards:
- type: custom:button-card
template: button_dashboard_menu
variables:
path: home
board: ui-overzicht
# view: >
# [[[ return window.location.pathname.split('/')[2]; ]]]
# dash: >
@Mariusthvdb
Mariusthvdb / include_temp_humidity.yaml
Created October 26, 2022 07:33
tem and humid iste
type: entities
entities:
- type: custom:mod-card
card_mod:
style: |
:host {
--stack-card-margin: 0px;
}
card:
@Mariusthvdb
Mariusthvdb / themes.yaml
Last active January 8, 2024 14:06
Themes
##########################################################################################
# My themes file, using some anchors to set generic parts for all themes, and dedicated
# sections for dark and light themes. NOT using the dark_mode functionality, which doesnt
# fit my needs.
# config:
#
# frontend:
# themes: !include_dir_merge_named /config/frontend_themes
#
# @mariusthvdb
@Mariusthvdb
Mariusthvdb / custom_header_template.yaml
Last active January 16, 2024 08:32
Custom header theme
template:
- sensor:
- unique_id: custom_header_option_template
name: Custom header template
state: >
{% if is_state('input_boolean.menu_options_template','on') %}
{% if states('sensor.your_browsermod_id') not in ['unknown','unavailable'] %} /*replace with correct sensor id */
{{state_attr('sensor.your_browsermod_id','path')
@Mariusthvdb
Mariusthvdb / buttons_shortcut_menu.yaml
Last active January 16, 2022 21:38
Shortcut menu bar
type: vertical-stack
cards:
- type: custom:stack-in-card
mode: horizontal
keep:
background: true
cards:
#history.back(-1)
@Mariusthvdb
Mariusthvdb / button_card_templates.yaml
Last active July 25, 2023 09:30
My Button card templates
# https://css-tricks.com/almanac/properties/a/aspect-ratio/
##########################################################################################
# 'module' templates used in Button templates
##########################################################################################
action_default:
tap_action:
action: toggle
haptic: light
hold_action: