From 20aa46de19c9c93d263d19352fbeb62947a20a2e Mon Sep 17 00:00:00 2001 From: DBuit Date: Mon, 8 May 2023 09:22:39 +0200 Subject: [PATCH] Fix gap on the left --- dist/sidebar-card.js | 20 ++------------------ src/sidebar-card.ts | 1 + 2 files changed, 3 insertions(+), 18 deletions(-) diff --git a/dist/sidebar-card.js b/dist/sidebar-card.js index 61a720d..400e083 100644 --- a/dist/sidebar-card.js +++ b/dist/sidebar-card.js @@ -29,7 +29,6 @@ const removeNodes = (container, start, end = null) => { start = n; } }; -//# sourceMappingURL=dom.js.map /** * @license @@ -245,7 +244,6 @@ const createMarker = () => document.createComment(''); const lastAttributeNameRegex = // eslint-disable-next-line no-control-regex /([ \x09\x0a\x0c\x0d])([^\0-\x1F\x7F-\x9F "'>=/]+)([ \x09\x0a\x0c\x0d]*=[ \x09\x0a\x0c\x0d]*(?:[^ \x09\x0a\x0c\x0d"'`<>=]*|"[^"]*|'[^']*))$/; -//# sourceMappingURL=template.js.map /** * @license @@ -370,7 +368,6 @@ function insertNodeIntoTemplate(template, node, refNode = null) { } } } -//# sourceMappingURL=modify-template.js.map /** * @license @@ -389,7 +386,6 @@ const directives = new WeakMap(); const isDirective = (o) => { return typeof o === 'function' && directives.has(o); }; -//# sourceMappingURL=directive.js.map /** * @license @@ -413,7 +409,6 @@ const noChange = {}; * A sentinel value that signals a NodePart to fully clear its content. */ const nothing = {}; -//# sourceMappingURL=part.js.map /** * @license @@ -546,7 +541,6 @@ class TemplateInstance { return fragment; } } -//# sourceMappingURL=template-instance.js.map /** * @license @@ -653,7 +647,6 @@ class TemplateResult { return template; } } -//# sourceMappingURL=template-result.js.map /** * @license @@ -1124,7 +1117,6 @@ const getOptions = (o) => o && (eventOptionsSupported ? { capture: o.capture, passive: o.passive, once: o.once } : o.capture); -//# sourceMappingURL=parts.js.map /** * @license @@ -1172,7 +1164,6 @@ function templateFactory(result) { return template; } const templateCaches = new Map(); -//# sourceMappingURL=template-factory.js.map /** * @license @@ -1213,7 +1204,6 @@ const render = (result, container, options) => { part.setValue(result); part.commit(); }; -//# sourceMappingURL=render.js.map /** * @license @@ -1265,7 +1255,6 @@ class DefaultTemplateProcessor { } } const defaultTemplateProcessor = new DefaultTemplateProcessor(); -//# sourceMappingURL=default-template-processor.js.map /** * @license @@ -1291,7 +1280,6 @@ if (typeof window !== 'undefined') { * render to and update a container. */ const html = (strings, ...values) => new TemplateResult(strings, values, 'html', defaultTemplateProcessor); -//# sourceMappingURL=lit-html.js.map /** * @license @@ -1561,7 +1549,6 @@ const render$1 = (result, container, options) => { window.ShadyCSS.styleElement(container.host); } }; -//# sourceMappingURL=shady-render.js.map /** * @license @@ -2235,7 +2222,6 @@ _a = finalized; * Marks class as having finished creating properties. */ UpdatingElement[_a] = true; -//# sourceMappingURL=updating-element.js.map /** @license @@ -2314,7 +2300,6 @@ const css = (strings, ...values) => { const cssText = values.reduce((acc, v, idx) => acc + textFromCSSResult(v) + strings[idx + 1], strings[0]); return new CSSResult(cssText, constructionToken); }; -//# sourceMappingURL=css-tag.js.map /** * @license @@ -2540,7 +2525,6 @@ LitElement['finalized'] = true; * @nocollapse */ LitElement.render = render$1; -//# sourceMappingURL=lit-element.js.map function hass() { if(document.querySelector('hc-main')) @@ -17852,9 +17836,8 @@ var fecha = { setGlobalDateI18n: setGlobalDateI18n, setGlobalDateMasks: setGlobalDateMasks }; -//# sourceMappingURL=fecha.js.map -var a=function(){try{(new Date).toLocaleDateString("i");}catch(e){return "RangeError"===e.name}return !1}()?function(e,t){return e.toLocaleDateString(t,{year:"numeric",month:"long",day:"numeric"})}:function(t){return fecha.format(t,"mediumDate")},r=function(){try{(new Date).toLocaleString("i");}catch(e){return "RangeError"===e.name}return !1}()?function(e,t){return e.toLocaleString(t,{year:"numeric",month:"long",day:"numeric",hour:"numeric",minute:"2-digit"})}:function(t){return fecha.format(t,"haDateTime")},n=function(){try{(new Date).toLocaleTimeString("i");}catch(e){return "RangeError"===e.name}return !1}()?function(e,t){return e.toLocaleTimeString(t,{hour:"numeric",minute:"2-digit"})}:function(t){return fecha.format(t,"shortTime")};function f(e){return e.substr(0,e.indexOf("."))}var D=["closed","locked","off"],q=function(e,t,a,r){r=r||{},a=null==a?{}:a;var n=new Event(t,{bubbles:void 0===r.bubbles||r.bubbles,cancelable:Boolean(r.cancelable),composed:void 0===r.composed||r.composed});return n.detail=a,e.dispatchEvent(n),n};var B=function(e){q(window,"haptic",e);},U=function(e,t,a){void 0===a&&(a=!1),a?history.replaceState(null,"",t):history.pushState(null,"",t),q(window,"location-changed",{replace:a});},V=function(e,t,a){void 0===a&&(a=!0);var r,n=f(t),s="group"===n?"homeassistant":n;switch(n){case"lock":r=a?"unlock":"lock";break;case"cover":r=a?"open_cover":"close_cover";break;default:r=a?"turn_on":"turn_off";}return e.callService(s,r,{entity_id:t})},W=function(e,t){var a=D.includes(e.states[t].state);return V(e,t,a)};//# sourceMappingURL=index.m.js.map +var a=function(){try{(new Date).toLocaleDateString("i");}catch(e){return "RangeError"===e.name}return !1}()?function(e,t){return e.toLocaleDateString(t,{year:"numeric",month:"long",day:"numeric"})}:function(t){return fecha.format(t,"mediumDate")},r=function(){try{(new Date).toLocaleString("i");}catch(e){return "RangeError"===e.name}return !1}()?function(e,t){return e.toLocaleString(t,{year:"numeric",month:"long",day:"numeric",hour:"numeric",minute:"2-digit"})}:function(t){return fecha.format(t,"haDateTime")},n=function(){try{(new Date).toLocaleTimeString("i");}catch(e){return "RangeError"===e.name}return !1}()?function(e,t){return e.toLocaleTimeString(t,{hour:"numeric",minute:"2-digit"})}:function(t){return fecha.format(t,"shortTime")};function f(e){return e.substr(0,e.indexOf("."))}var D=["closed","locked","off"],q=function(e,t,a,r){r=r||{},a=null==a?{}:a;var n=new Event(t,{bubbles:void 0===r.bubbles||r.bubbles,cancelable:Boolean(r.cancelable),composed:void 0===r.composed||r.composed});return n.detail=a,e.dispatchEvent(n),n};var B=function(e){q(window,"haptic",e);},U=function(e,t,a){void 0===a&&(a=!1),a?history.replaceState(null,"",t):history.pushState(null,"",t),q(window,"location-changed",{replace:a});},V=function(e,t,a){void 0===a&&(a=!0);var r,n=f(t),s="group"===n?"homeassistant":n;switch(n){case"lock":r=a?"unlock":"lock";break;case"cover":r=a?"open_cover":"close_cover";break;default:r=a?"turn_on":"turn_off";}return e.callService(s,r,{entity_id:t})},W=function(e,t){var a=D.includes(e.states[t].state);return V(e,t,a)}; // ------------------------------------------------------------------------------------------ // SIDEBAR-CARD @@ -18815,6 +18798,7 @@ async function buildSidebar() { } if (appDrawerLayout) { appDrawerLayout.style.marginLeft = '0'; + appDrawerLayout.style.paddingLeft = '0'; } if (appDrawer) { appDrawer.style.display = 'none'; diff --git a/src/sidebar-card.ts b/src/sidebar-card.ts index a261ea7..2c329b6 100644 --- a/src/sidebar-card.ts +++ b/src/sidebar-card.ts @@ -1025,6 +1025,7 @@ async function buildSidebar() { } if (appDrawerLayout) { appDrawerLayout.style.marginLeft = '0'; + appDrawerLayout.style.paddingLeft = '0'; } if (appDrawer) { appDrawer.style.display = 'none';