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

Rewrite ActionPanel to use Home Assistant default panel #1076

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

MrBearPresident
Copy link
Collaborator

@MrBearPresident MrBearPresident commented Dec 22, 2024

Breaking change

  • None

Proposed change

  • Rewriting the ActionPanel to use Home Assistant default panel
    • Rename 'makeTapActionPanel' to makeActionPanel to be more in line with function.
    • Remove of how action panels where made.
    • Reuse home-assistant default action panel instead.
    • Rewrite how changed-actions are saved.

Type of change

  • Bugfix (non-breaking change which fixes an issue)
  • New feature (thank you!)
  • Breaking change (fix/feature causing existing functionality to break)
  • Code quality improvements to existing code or addition of tests

Example configuration

Everything was made in with the new action panels

type: custom:bubble-card
card_type: button
button_type: state
entity: sun.sun
tap_action:
  action: more-info
double_tap_action:
  action: navigate
  navigation_path: "#1"
hold_action:
  action: perform-action
  perform_action: input_boolean.toggle
  target:
    entity_id:
      - input_boolean.help_house_testboolean_01
      - input_boolean.help_house_testboolean_03
      - input_boolean.help_house_testboolean_02
sub_button:
  - entity: input_boolean.help_house_testboolean_01
    hold_action:
      action: url
      url_path: "#2"
    tap_action:
      action: toggle
    double_tap_action:
      action: more-info
button_action:
  tap_action:
    action: more-info
  double_tap_action:
    action: assist
    start_listening: true
  hold_action:
    action: none

Example printscreens/gif

image

Additional information

Additional documentation needed.

  • None

Checklist

  • The code change is tested and works locally.
  • There is no commented out code in this PR.
  • Tests screenshots/gifs have been added to verify that the new code works.

If user exposed functionality or configuration variables are added/changed:

  • Documentation added/updated for readme.

…ith function.

- Remove of how action panels where made.
- Reuse home-assistant default action panel instead.
- Rewrite how changed-actions are saved.
@Clooos
Copy link
Owner

Clooos commented Dec 22, 2024

Thank you so much! This was probably the worst part of the editor 😅

I can't wait to try this! 🎉

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants