Homekit Infused 5 (HKI) v2023.1.3

I hope within 4 weeks, but it is quite a lot I need to rewrite. The base has already been setup, its mostly cleaning up and finding solutions for some of the elements (I recently found a solution which makes it possible to insert an infinite number of rooms, so there is no more limit of 30 rooms which was previously the case). I am now looking for a solution for the frontpage buttons. I have also made it completely tablet friendly (though it is still in an early stage, but is working on all views now dynamically).

I also fixed a lot of small issues like icons being cut off on ios, the header is fixed into place when scrolling down the view (which I happen to have fixed for ios as well) and much much more. All entities I used before are gone and most of the groups are as well.

In the new version you simply define custom attributes to the devices in customize.yaml (which if you followed my original instructions should already be setup). Then simply for each device you enter a room name e.g.

light.balcony:
  friendly_name: Balcony Lamp
  room: Balcony

Because of that special custom attribute I am able to filter out the correct entities without the need of any group at all. Most of the stuff that is currently accessible to change in the UI will however move. Most things can still be done though slightly different. The only thing that is going to remove is to hide the header or parts of it. The header will be fixed and the only thing that can be changed are titles/subtitles and icons.

The blocks on the frontpage will also be locked for now. However I might make card blocks so that people can insert their own cards on specific locations (not sure how and if Im going to do this).

Things like font size, family and justification settings will move to the theme settings (which will be split in 2 files, base and user). Note that most of these settings still do not require a HA restart.

Note that I will try to get it out sooner, but no promises. I want this release to be good so it will be ready when it is ready. I want this to be less maintenance heavy as the last version.

4 Likes

Homekit Infused Framework v3.0.0a (released)

NOTE: This is ONLY the framework, this does not include ANY card! You can get addons from the repo (at the time of writing there are only a few addons to choose from, the addons will be uploaded within the upcoming week!)

For full documentation please visit the repo

The following changes mentioned below only apply to the Framework!

  • Completely redesigned structure
  • Every single view can now have addons (see documentation)
  • Blazing fast compared to previous versions
  • Removed all UI options with the exception of theme settings
  • Moved header/button titles to the homekit-infused/user/config/header.yaml file
  • Removed all translations (since HKI 3.x.x is more like a lego house, translating can be done by anyone and will take only a minute or so)
  • Removed alarm view in favor of a popup on the frontpage (by pressing the lock icon)
  • Removed laundry view (you can use the cleaning view instead)
  • The menu is now a separate addon and can be removed if desired
  • The header is now sticky and will no longer slide up when scrolling down
  • The header is now compatible with desktop/tablet modes and will look much better
  • Changed a few theme colors, restarting home assistant or reloading lovelace will now show a readable red bar
  • Slimmed down the header code
  • Removed 1500+ entities (please read the documentation when installing on existing systems)
  • It is now easier than ever to create addons for HKI, please read the documentation.
  • Oh did I mention it is blazing fast? You had wished you had this months ago! (trust me on this!)

Existing users:
Please read the documentation (there is a section named `Previous HKI Installs) as there is a bit of work to do, a lot of things have changed and the previous two major versions have taught me a lot.
This has also taught me that expanding v2.x.x was a bad idea as it would get slower and slower the more features I would add.
Instead I have separated the code. The framework can be used standalone and does not require any of the HKI cards to be installed.
Using the framework as standalone will give you the HKI header (notifications, greeting, sensors and lock), the footer (logged in username and home/menu button) and it will give you a preset of 27 usable views.
The number of views is fixed! If you want more views than 27, please do a feature request and I will add them. Did I already mention that the performance has increased so much that you might be able to run this on a rpi now?

Remember that this is ONLY the framework and it does NOT include cards, seasoned home assistant users will probably already want to play with this, but on a production setup Iā€™ll suggest to wait to merge it to the new version once all the addons (or the addons you need) are released.
This will NOT work as a second dashboard to your old setup! So there is no way to run them side by side. Backing up your current setup is never a stupid idea!

2 Likes

@jimz011 I just came here to read about new improvements, wasnā€™t disappointed :grinning:

Keep up the good work :+1:

@neliss You can already get the HKI framework 3.0.1 from my repo (itā€™s a bit hidden though under the branches).

@jimz011 hi, can you explain how you achieved this:

  • The header is now sticky and will no longer slide up when scrolling down

Iā€™m curious since I have my own notification area with markdown and button cards inside horizontal stacks. Which is not sticky. I looked through your code but couldnā€™t find it.

This is the code for the header, look for the style in the first card

1 Like

Do you need to install anything else beside card-mod? I tried your code (added an extra { that was missing at the bottom) but somehow the sticky code does not work. The ha-card part (with the shadow effect) does work, so I have the correct cardā€¦ I want to use this on a vertical-stack, and card-mod docs say I need to use custom:mod-card for that. Which does apply the shadows, but not the sticky.

Any advice?

          - type: custom:mod-card
            style: |
              ha-card {
                --ha-card-background: transparant;
                -webkit-box-shadow: 0px 14px 21px -15px rgba(0,0,0,0.75);
                -moz-box-shadow: 0px 14px 21px -15px rgba(0,0,0,0.75);
                box-shadow: 0px 14px 21px -15px rgba(0,0,0,0.75);
                background: var(--primary-color);
                border-radius: 0px !important;
              }
              .card-content {
                padding: 0
              }
              :host {
                z-index: 999;
                position: sticky;
                position: -webkit-sticky;
                top: 0;
              }
            card:
              type: vertical-stack
              cards:
                - HORIZONTAL STACK CARD HERE
                - HORIZONTAL STACK CARD HERE

This is my code btw

What browser are you using?

Using Edge (chromium) and tried on Safari iOS.

edit: I think I know what the issue is. Iā€™m trying stuff out and let you know when Iā€™m positive!

@jimz011 I found out what the issue is. I use lay-out card as the base in vertical mode with column_width set to 96%. I did this so I get paddings left and right in my entire view. But this code does not work when using it inside lay-out card apparently. I might try and set the notification area separate and put the rest inside a layout card, to have best of both.

Trying to install the latest v3.0.2 version from scratch but keep getting error:

invalid key: "OrderedDict ([("entity|default('input_boolean.dummy1')", None)])" in "/config/homekit-infused/base/templates/header/notification-template.yaml", line 12, column 0"

@appiekap653 do you have lovelace_gen installed?

I have the layout card second. This is basically my structure (I use panel: true)

  • vertical-stack
    • header (sticky)
    • layout-card
      • rest of the view
1 Like

Yes, I tried this just a minute ago and works flawlessly :grinning: Thanks a lot for the styling code, this was the one thing I wanted to fix so badly in my UI (proper notifications).

I have solved it. i had also dwains theme for a tablet installed. with the package folder from dwains theme deleted it start working. i also needed to put the alarm code in the secret file. that was not stated on the installation guide

There is an example configuration.yaml included which has an example alarm code which did not require the need of secrets. But if it is working that is good :rofl:

1 Like

lol, i got an error cannot find secret alarm_code. after added the alarm_code in secret file it started working

1 Like

Iā€™m not sure if I installed everything correctly, but I canā€™t find a way to add cards in the frontpage. Is there any way I can add cards like I would on default HA? With click of a button basically.

No, the project is in YAML mode which means you canā€™t use the UI. However you can create cards with the UI, copy the code and run it in HKI.

Hi Jim,

Great work. Thanks a lot. I followed every step. But after rebooting and opening the Homekit Infused entry in the left menu, I get a ā€œSecret alarm_code not definedā€.

configuration.yaml has the default settings:

alarm_control_panel:
  - platform: manual
    name: Home Alarm
    code: 123456
    delay_time: 0
    trigger_time: 100
    disarmed:
      trigger_time: 0
    armed_home:
      delay_time: 0
    disarm_after_trigger: false

Any idea what I missed?

Hm I have heard this before, so I will have to find it in the code somewhere. For now, open secrets.yaml and add the following line:

alarm_code: 123456

Restart HA afterwards, it might say that the secret isnt defined, if it does save the secrets.yaml file once more and then restart.

1 Like