From 654b2549b61c941a66a65cc313846e3544e5ca98 Mon Sep 17 00:00:00 2001 From: Ned Zimmerman Date: Fri, 31 Jan 2020 10:35:24 -0700 Subject: [PATCH] feat: add internal/external variants --- .../01-atoms/06-call-to-action/call-to-action.config.js | 6 ++++++ .../01-atoms/06-call-to-action/call-to-action.njk | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/src/components/01-atoms/06-call-to-action/call-to-action.config.js b/src/components/01-atoms/06-call-to-action/call-to-action.config.js index 116ac148..0aefb630 100644 --- a/src/components/01-atoms/06-call-to-action/call-to-action.config.js +++ b/src/components/01-atoms/06-call-to-action/call-to-action.config.js @@ -7,6 +7,12 @@ module.exports = { standAlone: false }, variants: [ + { + name: 'External', + context: { + external: true, + } + }, { name: 'Inverse', context: { diff --git a/src/components/01-atoms/06-call-to-action/call-to-action.njk b/src/components/01-atoms/06-call-to-action/call-to-action.njk index f24b87c0..beaefd54 100644 --- a/src/components/01-atoms/06-call-to-action/call-to-action.njk +++ b/src/components/01-atoms/06-call-to-action/call-to-action.njk @@ -1,4 +1,4 @@ {% if not standAlone %}{% endif %}

- {{ label }}{% render '@svg', {svg: 'external'}, true %} + {{ label }}{% if external %}{% render '@svg', {svg: 'external'}, true %}{% endif %}