Skip to content

Saleor Core: the high performance, composable, headless commerce API.

Fix inconsistent 'add' button style

dominik-zegleneb6bf51cbca9
diff --git a/templates/dashboard/discount/sale/list.html b/templates/dashboard/discount/sale/list.html
index 2b9bcd84d6..2635152073 100644
--- a/templates/dashboard/discount/sale/list.html
+++ b/templates/dashboard/discount/sale/list.html
@@ -3,6 +3,7 @@
{% load prices_i18n %}
{% load materializecss %}
{% load utils %}
+{% load static %}
{% block title %}
{% trans "Sales" %} - {{ block.super }}
@@ -21,14 +22,15 @@
{% block menu_discounts_class %} active{% endblock %}
{% block content %}
+ {% if perms.sale.edit_sale %}
+ <div class="fixed-action-btn">
+ <a href="{% url 'dashboard:sale-add' %}" class="btn-fab btn-floating btn-large waves-effect waves-light"
+ title="{% trans "Add sale" context "Sale (discount) list add button text" %}">
+ <svg data-src="{% static "dashboard/images/add.svg" %}" />
+ </a>
+ </div>
+ {% endif %}
<div class="card">
- {% if perms.sale.edit_sale %}
- <div class="data-table-header-action">
- <a href="{% url 'dashboard:sale-add' %}" class="btn btn-data-table btn-flat" title="{% trans "Add sale" context "Sale (discount) list add button text" %}">
- {% trans "Add" context "Dashboard add action" %}
- </a>
- </div>
- {% endif %}
<div class="data-table-container">
<table class="bordered highlight responsive data-table">
<thead>
diff --git a/templates/dashboard/discount/voucher/list.html b/templates/dashboard/discount/voucher/list.html
index 65a46ad7b3..827fed8300 100644
--- a/templates/dashboard/discount/voucher/list.html
+++ b/templates/dashboard/discount/voucher/list.html
@@ -3,6 +3,7 @@
{% load prices_i18n %}
{% load materializecss %}
{% load utils %}
+{% load static %}
{% block title %}
{% trans "Vouchers" context "Dashboard vouchers list" %} - {{ block.super }}
@@ -23,14 +24,15 @@
{% block menu_discounts_class %} active{% endblock %}
{% block content %}
+ {% if perms.voucher.edit_voucher %}
+ <div class="fixed-action-btn">
+ <a href="{% url 'dashboard:voucher-add' %}" class="btn-fab btn-floating btn-large waves-effect waves-light"
+ title="{% trans "Add voucher" context "Voucher list add button text" %}">
+ <svg data-src="{% static "dashboard/images/add.svg" %}" />
+ </a>
+ </div>
+ {% endif %}
<div class="card">
- {% if perms.voucher.edit_voucher %}
- <div class="data-table-header-action">
- <a href="{% url 'dashboard:voucher-add' %}" class="btn btn-data-table btn-flat" title="{% trans "Add voucher" context "Voucher list add button text" %}">
- {% trans "Add" context "Dashboard add action" %}
- </a>
- </div>
- {% endif %}
<div class="data-table-container">
<table class="bordered highlight responsive data-table">
{% if vouchers %}
diff --git a/templates/dashboard/shipping/list.html b/templates/dashboard/shipping/list.html
index 6e08238d47..e9b57f5254 100644
--- a/templates/dashboard/shipping/list.html
+++ b/templates/dashboard/shipping/list.html
@@ -3,6 +3,7 @@
{% load prices_i18n %}
{% load status %}
{% load utils %}
+{% load static %}
{% block title %}
{% trans "Shipping methods" context "Dashboard shipping methods list" %} - {{ block.super }}
@@ -21,14 +22,16 @@
{% endblock %}
{% block content %}
+ <div class="fixed-action-btn">
+ <a href="{% url 'dashboard:shipping-method-add' %}"
+ class="btn-fab btn-floating btn-large waves-effect waves-light"
+ title="{% trans "Add method" context "Shipping method list add button text" %}">
+ <svg data-src="{% static "dashboard/images/add.svg" %}" />
+ </a>
+ </div>
<div class="row">
<div class="col s12">
<div class="card">
- <div class="data-table-header-action">
- <a href="{% url 'dashboard:shipping-method-add' %}" class="btn btn-data-table btn-flat" title="{% trans "Add method" context "Shipping method list add button text" %}">
- {% trans "Add" context "Dashboard add action" %}
- </a>
- </div>
<div class="data-table-container">
<table class="bordered highlight responsive data-table">
{% if shipping_methods %}