drop.chapril.org-firefoxsend/app/ui/promo.js

41 lines
1.1 KiB
JavaScript
Raw Normal View History

const html = require('choo/html');
const Component = require('choo/component');
const assets = require('../../common/assets');
class Promo extends Component {
constructor(name, state) {
super(name);
this.state = state;
}
update() {
return false;
}
createElement() {
return html`
<send-promo
2019-03-13 19:16:58 +01:00
class="w-full flex-none flex-row items-center content-center justify-center text-sm bg-grey-light leading-tight text-grey-darkest px-4 py-3 hidden md:flex"
>
<div class="flex items-center mx-auto">
<img
2019-05-30 04:22:03 +02:00
src="${assets.get('master-logo.svg')}"
class="w-6"
alt="Firefox"
/>
<span class="ml-3">
2019-05-30 04:22:03 +02:00
${this.state.translate('trailheadPromo')}${' '}
<a
class="text-blue"
2019-05-30 04:22:03 +02:00
href="http://www.mozilla.org/firefox/accounts/?utm_source=send.firefox.com&utm_medium=banner&utm_campaign=trailhead&utm_content=protect-your-privacy"
>${this.state.translate('learnMore')}</a
>
</span>
</div>
</send-promo>
`;
}
}
module.exports = Promo;