File tree Expand file tree Collapse file tree 2 files changed +8
-2
lines changed
packages/uikit-workshop/src/scripts/lit-components Expand file tree Collapse file tree 2 files changed +8
-2
lines changed Original file line number Diff line number Diff line change 11/* eslint-disable no-unused-vars, no-param-reassign */
22import { store } from '../../store.js' ; // connect to redux
3+ import { ifDefined } from 'lit-html/directives/if-defined' ;
34import { html } from 'lit-html' ;
45import { BaseLitComponent } from '../../components/base-component' ;
56import { customElement } from 'lit-element' ;
@@ -116,7 +117,8 @@ class Header extends BaseLitComponent {
116117 : window . config ?. theme ?. logo ?. url || '/' } "
117118 alt-text ="${ window . config ?. theme ?. logo ?. altText || '' } "
118119 theme ="${ this . themeMode } "
119- ratio ="${ window . config ?. theme ?. logo ?. ratio || '' } "
120+ width ="${ ifDefined ( window . config ?. theme ?. logo ?. width ) } "
121+ height ="${ ifDefined ( window . config ?. theme ?. logo ?. height ) } "
120122 text ="${ window . config ?. theme ?. logo ?. text === '' ||
121123 window . config ?. theme ?. logo ?. text === false ||
122124 window . config ?. theme ?. logo ?. text === 'none'
Original file line number Diff line number Diff line change 11import { store } from '../../store.js' ; // connect to redux
2+ import { ifDefined } from 'lit-html/directives/if-defined' ;
23import { html } from 'lit-html' ;
34import { customElement } from 'lit-element' ;
45import { BaseLitComponent } from '../../components/base-component' ;
@@ -20,7 +21,8 @@ class Logo extends BaseLitComponent {
2021
2122 static get properties ( ) {
2223 return {
23- ratio : String ,
24+ width : String ,
25+ height : String ,
2426 theme : String ,
2527 url : String ,
2628 text : String ,
@@ -48,6 +50,8 @@ class Logo extends BaseLitComponent {
4850 alt =${ this . altText || 'Pattern Lab Logo' }
4951 src =${ imageSrc }
5052 class="pl-c-logo__img"
53+ width="${ ifDefined ( this . width ) } "
54+ height="${ ifDefined ( this . height ) } "
5155 />
5256 ${ this . text && this . text !== ''
5357 ? html `
You can’t perform that action at this time.
0 commit comments