From 39b56d9546fde9495637c5e0a13117ebfda566e5 Mon Sep 17 00:00:00 2001
From: Chris Lawton <chris.lawton@torchbox.com>
Date: Thu, 10 Jan 2019 10:09:24 +0000
Subject: [PATCH] switch filter button elements to buttons

---
 .../funds/templates/funds/base_submissions_table.html     | 6 +++---
 .../static_src/src/sass/apply/components/_button.scss     | 2 ++
 .../static_src/src/sass/apply/components/_filters.scss    | 8 ++++++++
 3 files changed, 13 insertions(+), 3 deletions(-)

diff --git a/opentech/apply/funds/templates/funds/base_submissions_table.html b/opentech/apply/funds/templates/funds/base_submissions_table.html
index d99ee9082..1aa5a97ed 100644
--- a/opentech/apply/funds/templates/funds/base_submissions_table.html
+++ b/opentech/apply/funds/templates/funds/base_submissions_table.html
@@ -10,16 +10,16 @@
     {% block table %}
     <div class="wrapper wrapper--table-actions">
         {% if table.data or active_filters %}
-            <div class="button button--filters button--contains-icons js-toggle-filters">Filters</div>
+            <button class="button button--filters button--contains-icons js-toggle-filters">Filters</button>
         {% endif %}
     </div>
 
         {% if table.data or active_filters %}
             <div class="filters">
                 <div class="filters__header">
-                    <div class="js-clear-filters">Clear</div>
+                    <button class="filters__button js-clear-filters">Clear</button>
                     <div>Filter by</div>
-                    <div class="js-close-filters">Close</div>
+                    <button class="filters__button js-close-filters">Close</button>
                 </div>
 
                 <form action="" method="get" class="form form--filters">
diff --git a/opentech/static_src/src/sass/apply/components/_button.scss b/opentech/static_src/src/sass/apply/components/_button.scss
index f5c5fd05f..280373f09 100644
--- a/opentech/static_src/src/sass/apply/components/_button.scss
+++ b/opentech/static_src/src/sass/apply/components/_button.scss
@@ -78,6 +78,7 @@
         background: url('./../../images/filters.svg') $color--white no-repeat 93% center;
         border: 1px solid $color--light-mid-grey;
         transition: none;
+        width: 100%;
 
         @include media-query(tablet-landscape) {
             background: none;
@@ -86,6 +87,7 @@
             align-items: center;
             justify-content: flex-start;
             max-width: initial;
+            width: auto;
 
             &::before {
                 content: '';
diff --git a/opentech/static_src/src/sass/apply/components/_filters.scss b/opentech/static_src/src/sass/apply/components/_filters.scss
index f63af306c..8a0dbb5de 100644
--- a/opentech/static_src/src/sass/apply/components/_filters.scss
+++ b/opentech/static_src/src/sass/apply/components/_filters.scss
@@ -50,4 +50,12 @@
             }
         }
     }
+
+    &__button {
+        appearance: none;
+        -webkit-appearance: none; // sass-lint:disable-line no-vendor-prefixes
+        border: 0;
+        color: $color--primary;
+        background: transparent;
+    }
 }
-- 
GitLab