From 7baca4341e5e1a98270a937e02d4e3c218e25189 Mon Sep 17 00:00:00 2001 From: jonathanbataire Date: Tue, 4 Jun 2024 18:05:25 +0300 Subject: [PATCH 1/5] :hammer: forms --- src/liquid/app/form_switch.html | 30 ++- src/liquid/app/fragment_edit.html | 2 +- src/liquid/app/view.html | 5 +- src/liquid/components/actions.html | 2 +- src/liquid/components/contact_type_dob.html | 32 ++- .../components/contact_type_property.html | 9 +- src/liquid/components/filter_tag.html | 3 +- src/liquid/components/move_result.html | 63 +++--- src/liquid/components/search_input.html | 7 +- src/liquid/components/search_results.html | 29 +-- src/liquid/place/bulk_create_form.html | 198 ++++++++---------- src/liquid/place/create_form.html | 16 +- src/liquid/place/list_lazy.html | 6 +- src/liquid/place/move_form.html | 19 +- src/public/css/custom-bootstrap.min.css | 2 +- src/public/css/datepicker.min.css | 1 + src/public/css/styles.css | 2 +- src/public/icons/calendar.svg | 11 + src/public/scripts/datepicker.min.js | 1 + src/scss/_buttons.scss | 95 ++++++--- src/scss/_directives.scss | 17 ++ src/scss/_input-forms.scss | 125 +++++++++-- src/scss/_mixins.scss | 13 ++ src/scss/_spinner.scss | 85 ++++---- src/scss/styles.scss | 3 + 25 files changed, 465 insertions(+), 311 deletions(-) create mode 100644 src/public/css/datepicker.min.css create mode 100644 src/public/icons/calendar.svg create mode 100644 src/public/scripts/datepicker.min.js diff --git a/src/liquid/app/form_switch.html b/src/liquid/app/form_switch.html index f4656a26..87f51983 100644 --- a/src/liquid/app/form_switch.html +++ b/src/liquid/app/form_switch.html @@ -1,26 +1,22 @@
{% capture header_caption %} - {% if op == "bulk" %} Bulk Load from CSV - {% elsif op == "replace"%} Replace Existing - {% elsif op == "move"%} Move - {% elsif op == "edit" %} Edit - {% else %} New - {% endif %} + {% if op == "bulk" %} Bulk Load from CSV + {% elsif op == "replace"%} Replace Existing + {% elsif op == "move"%} Move + {% elsif op == "edit" %} Edit + {% else %} New + {% endif %} {% endcapture %} - -
-
-

- {{header_caption}} {{contactType.contact_friendly | default: contactType.friendly }} -

-
-
+ +

+ {{header_caption}} {{contactType.contact_friendly | default: contactType.friendly }} +

{% if op == "bulk" %} - {% include "place/bulk_create_form.html" %} + {% include "place/bulk_create_form.html" %} {% elsif op == "move" %} - {% include "place/move_form.html" %} + {% include "place/move_form.html" %} {% else %} - {% include "place/create_form.html" %} + {% include "place/create_form.html" %} {% endif %}
\ No newline at end of file diff --git a/src/liquid/app/fragment_edit.html b/src/liquid/app/fragment_edit.html index 302b0cf7..e0183f64 100644 --- a/src/liquid/app/fragment_edit.html +++ b/src/liquid/app/fragment_edit.html @@ -1,3 +1,3 @@ -
+
{% include "place/create_form.html" %}
\ No newline at end of file diff --git a/src/liquid/app/view.html b/src/liquid/app/view.html index 48ed2e3f..d62d60db 100644 --- a/src/liquid/app/view.html +++ b/src/liquid/app/view.html @@ -5,12 +5,13 @@ CHT User Management Tool - + + @@ -18,7 +19,7 @@ {% include "app/header.html" %}
-
+
{% if view == "list" %} {% include "app/fragment_home.html" %} {% else %} diff --git a/src/liquid/components/actions.html b/src/liquid/components/actions.html index 7801c299..b87f656c 100644 --- a/src/liquid/components/actions.html +++ b/src/liquid/components/actions.html @@ -16,7 +16,7 @@
{% if directiveModel.validationErrorCount > 0 or directiveModel.totalCount == 0 %}
- diff --git a/src/liquid/components/contact_type_dob.html b/src/liquid/components/contact_type_dob.html index 55ef06c3..d56da803 100644 --- a/src/liquid/components/contact_type_dob.html +++ b/src/liquid/components/contact_type_dob.html @@ -1,14 +1,10 @@ -
- + -
- -
-
+
-
\ No newline at end of file +
+ + \ No newline at end of file diff --git a/src/liquid/components/contact_type_property.html b/src/liquid/components/contact_type_property.html index eb421d2f..7ac964c2 100644 --- a/src/liquid/components/contact_type_property.html +++ b/src/liquid/components/contact_type_property.html @@ -1,9 +1,9 @@ {% if include.prop.type != 'generated' %} {% capture prop_name %}{{ include.prefix }}{{include.prop.property_name}}{% endcapture %} -
-