Files
the-example-app-nodejs/views/mixins/_moduleCopy.pug
2017-11-07 17:33:32 +01:00

11 lines
571 B
Plaintext

mixin moduleCopy(module)
- const style = module.fields.visualStyle === 'Emphasized' ? `--emphasized` : ''
.module
div(class=`module-copy${style}`)
div(class=`module-copy__first${style}`)
h1(class=`module-copy__headline${style}`) #{module.fields.headline}
div(class=`module-copy__copy${style}`) !{helpers.markdown(module.fields.copy)}
div(class=`module-copy__second${style}`)
if module.fields.ctaTitle && module.fields.ctaLink
a.cta(class=`module-copy__cta${style}` href=module.fields.ctaLink)= module.fields.ctaTitle