Skip to content

Commit

Permalink
fix(footer): accept any icon (#359)
Browse files Browse the repository at this point in the history
  • Loading branch information
nowseemee authored May 25, 2021
1 parent fcad96d commit a94f90c
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 20 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ exports[`AppFooter should match snapshot 1`] = `
<mock:shadow-root>
<div class="footer--variant-standard footer-container">
<div class="footer-mask"></div>
<footer class="footer"><template></template>
<footer class="footer">
<div class="footer-content">
<div class="footer-branding">
<app-logo claim=""></app-logo>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,10 @@ export class AppFooter {
}}
>
{item.icon &&
renderIcon(item.icon, 'footer-navigation__item-link')}
renderIcon({
tag: `scale-icon-${item.icon}`,
attributes: { class: 'footer-navigation__item-link' },
})}
<span>{item.name}</span>
</a>
</li>
Expand All @@ -60,23 +63,6 @@ export class AppFooter {
);
}

iconDefs() {
return (
<template>
<svg>
<defs>
<g id="icon-alert-imprint-dataprivacy">
<path
d="M12 1l9.5 2.15v8c0 2.85-.95 5.55-2.6 7.75-2.6 3.4-5.85 4.35-6.9 4.65-4.2-1.2-6.25-3.8-6.7-4.4-1.75-2.25-2.8-5.05-2.8-8v-8zm0 1.5L4 4.35v6.8c0 4.95 3.3 9.35 8 10.8 4.7-1.45 8-5.85 8-10.8v-6.8zM10.6 13l1.4 1.4 1.4-1.4h1c.95 0 1.75.7 1.95 1.65l.15.85h-9l.15-.85C7.8 13.7 8.65 13 9.6 13zM12 6.5c1.4 0 2.5 1 2.5 2.5 0 1.55-1.05 3-2.5 3s-2.5-1.5-2.5-3 1.1-2.5 2.5-2.5z"
fill-rule="evenodd"
></path>
</g>
</defs>
</svg>
</template>
);
}

render() {
return (
<Host>
Expand All @@ -85,7 +71,6 @@ export class AppFooter {
<div class={this.getCssClassMap()}>
<div class="footer-mask"></div>
<footer class="footer">
{this.iconDefs()}
<div class="footer-content">
<div class="footer-branding">
<app-logo claim claimLang={this.claimLang}></app-logo>
Expand Down
1 change: 1 addition & 0 deletions packages/components/src/html/telekom/header.html
Original file line number Diff line number Diff line change
Expand Up @@ -460,6 +460,7 @@
name: 'Legal notice',
id: 'Legal notice',
href: '#legal-notice',
icon: 'action-add',
},
{
name: 'Data privacy',
Expand Down

0 comments on commit a94f90c

Please sign in to comment.