From a19992771ae445fd548540698000cae26c8b4664 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bart=C5=82omiej=20Krakowski?= Date: Tue, 1 Oct 2019 11:08:42 +0200 Subject: [PATCH 1/5] wip() --- src/_includes/components/button.html | 3 +++ src/_sass/components/_button-fill.scss | 13 +++++++++++++ src/_sass/components/_button.scss | 12 ++++++++++++ src/_sass/segment.scss | 2 ++ src/styleguide.md | 3 +++ 5 files changed, 33 insertions(+) create mode 100644 src/_includes/components/button.html create mode 100644 src/_sass/components/_button-fill.scss create mode 100644 src/_sass/components/_button.scss diff --git a/src/_includes/components/button.html b/src/_includes/components/button.html new file mode 100644 index 0000000000..7648e85887 --- /dev/null +++ b/src/_includes/components/button.html @@ -0,0 +1,3 @@ + + {{ include.text }} + diff --git a/src/_sass/components/_button-fill.scss b/src/_sass/components/_button-fill.scss new file mode 100644 index 0000000000..c0f1200479 --- /dev/null +++ b/src/_sass/components/_button-fill.scss @@ -0,0 +1,13 @@ +.button-fill { + border-radius: 4px; + background-color: color(primary); + transition: box-shadow 0.3s; + + &:hover { + box-shadow: 0 4px 8px 0 rgba(82, 189, 149, 0.08); + } + + &--white { + background-color: color(white); + } +} diff --git a/src/_sass/components/_button.scss b/src/_sass/components/_button.scss new file mode 100644 index 0000000000..511f07c945 --- /dev/null +++ b/src/_sass/components/_button.scss @@ -0,0 +1,12 @@ +.button { + font-size: 16px; + font-weight: 500; + line-height: 1.5; + text-align: center; + + &--small { + font-size: 14px; + font-weight: 500; + line-height: 1.14; + } +} diff --git a/src/_sass/segment.scss b/src/_sass/segment.scss index b02acc551b..b1105c3e16 100644 --- a/src/_sass/segment.scss +++ b/src/_sass/segment.scss @@ -44,6 +44,8 @@ @import "components/note"; @import "components/button-link"; @import "components/alert"; +@import "components/button"; +@import "components/button-fill"; // Pages // ================================================= diff --git a/src/styleguide.md b/src/styleguide.md index b2a0236106..09ff12b77a 100644 --- a/src/styleguide.md +++ b/src/styleguide.md @@ -47,3 +47,6 @@ layout: page {% include components/alert.html type="success" content="This is my sample note." %} {% include components/alert.html type="warning" content="This is my sample note." %} {% include components/alert.html type="error" content="This is my sample note." %} + +{% include components/button.html size="standard" text="Sign up" href="https://segment.com" %} +{% include components/button.html size="small" text="Yes" href="https://segment.com" %} From eb4817255ceabc4b73750cfa948147965a49218f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bart=C5=82omiej=20Krakowski?= Date: Tue, 1 Oct 2019 13:52:59 +0200 Subject: [PATCH 2/5] wip(): Icon --- src/_includes/components/alert.html | 2 +- src/_includes/components/button.html | 7 ++++++- src/_sass/components/_button-fill.scss | 13 +++++++++++++ src/_sass/components/_button.scss | 11 +++++++++++ src/assets/icons/symbols/thumb-down.svg | 3 +++ src/assets/icons/symbols/thumb-up.svg | 3 +++ src/styleguide.md | 2 +- 7 files changed, 38 insertions(+), 3 deletions(-) create mode 100644 src/assets/icons/symbols/thumb-down.svg create mode 100644 src/assets/icons/symbols/thumb-up.svg diff --git a/src/_includes/components/alert.html b/src/_includes/components/alert.html index 411a7f1a53..0d7904b495 100644 --- a/src/_includes/components/alert.html +++ b/src/_includes/components/alert.html @@ -1,4 +1,4 @@ -