lukx / home-assistant-jukebox

Home-Assistant Radio Station and Stream Selector Card
65 stars 33 forks source link

Instances of paper-button need to be replaced with mwc-button #2

Closed froz closed 4 years ago

froz commented 5 years ago

Paper button was removed from homeassistant in 0.88

--- \Desktop\jukebox.js Sun Feb 24 07:50:33 2019
+++ \Homeassistant Config\www\jukebox.js    Fri Feb 22 14:32:51 2019
@@ -171,7 +171,7 @@
     }

     buildStationSwitch(name, url) {
-        const btn = document.createElement('paper-button');
+        const btn = document.createElement('mwc-button');
         btn.stationUrl = url;
         btn.className = 'juke-toggle';
         btn.innerText = name;
@@ -270,7 +270,7 @@
         padding: 10px 20px;
     }

-    paper-button.juke-toggle[raised] {
+    mwc-button.juke-toggle[raised] {
         background-color: var(--primary-color);
         color: var(--text-primary-color);
     }
@@ -288,4 +288,5 @@
     return frag;
 }

+
 customElements.define('jukebox-card', JukeboxCard);
lukx commented 4 years ago

I hadn't been able to reproduce this problem at the time; however in today's release the button is working with newer versions