Skip to content

Commit

Permalink
clean up
Browse files Browse the repository at this point in the history
  • Loading branch information
jonathanbataire committed May 15, 2024
1 parent 553072d commit 9e7f5b3
Show file tree
Hide file tree
Showing 3 changed files with 31 additions and 30 deletions.
47 changes: 24 additions & 23 deletions src/liquid/components/actions.html
Original file line number Diff line number Diff line change
@@ -1,30 +1,31 @@
<div class="actions">

<div class="top">
<div class="dropdown-button">
<button class="clear-btn"><img src="/public/images/plus.svg"> {{contactType.friendly}}</button>
<div class="dropdown-content">
<a href="/add-place?type={{ contactType.name }}&op=new">Create New</a>
<a href="/add-place?type={{ contactType.name }}&op=replace">Replace Existing</a>
<a href="/add-place?type={{ contactType.name }}&op=bulk">Upload from CSV</a>
</div>
<div class="top">
<div class="dropdown-button">
<button class="clear-btn"><img src="/public/images/plus.svg"> {{contactType.friendly}}</button>
<div class="dropdown-content">
<a href="/add-place?type={{ contactType.name }}&op=new">Create New</a>
<a href="/add-place?type={{ contactType.name }}&op=replace">Replace Existing</a>
<a href="/add-place?type={{ contactType.name }}&op=bulk">Upload from CSV</a>
</div>
<button class="clear-btn" onclick="window.location.href='/move/{{ contactType.name }}'">
<img src="/public/images/move.svg">Move {{contactType.friendly}}
</button>
</div>
<div id = "action_buttons_{{contactType.name}}" hx-swap-oob="true" class="bottom">
{% if directiveModel.validationErrorCount > 0 or directiveModel.totalCount == 0 %}
<div data-toggle="tooltip" title="Fix invalid users">
<button class="clear-btn disabled" hx-post="/app/apply-changes?type={{ contactType.name }}" hx-swap="none" disabled>
<img src="/public/images/upload-users.svg"> Upload All
</button>
</div>
{% else %}
<button class="clear-btn" hx-post="/app/apply-changes?type={{ contactType.name }}" hx-swap="none">
<button class="clear-btn" onclick="window.location.href='/move/{{ contactType.name }}'">
<img src="/public/images/move.svg">Move {{contactType.friendly}}
</button>
</div>
<div class="bottom" id="action_buttons_{{contactType.name}}" hx-swap-oob="true">
{% if directiveModel.validationErrorCount > 0 or directiveModel.totalCount == 0 %}
<div data-toggle="tooltip" title="Fix invalid users">
<button class="clear-btn disabled" hx-post="/app/apply-changes?type={{ contactType.name }}" hx-swap="none"
disabled>
<img src="/public/images/upload-users.svg"> Upload All
</button>
{% endif %}
{% include "components/button_save_credentials.html" %}
</div>
</div>
{% else %}
<button class="clear-btn" hx-post="/app/apply-changes?type={{ contactType.name }}" hx-swap="none">
<img src="/public/images/upload-users.svg"> Upload All
</button>
{% endif %}
{% include "components/button_save_credentials.html" %}
</div>
</div>
1 change: 0 additions & 1 deletion src/liquid/place/directive.html
Original file line number Diff line number Diff line change
Expand Up @@ -49,4 +49,3 @@
</div>
{% endif %}
</div>
</div>
13 changes: 7 additions & 6 deletions src/liquid/place/directive_validation_errors.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
<h3>
Oops...!
</h3>
<p>
<img src="public/images/error.svg"> Looks like you have <b class="error-text"><i>{{directiveModel.validationErrorCount}} Invalid user(s)</i></b>.
Fix them below.
</p>
Oops...!
</h3>
<p>
<img src="public/images/error.svg"> Looks like you have
<b class="error-text"><i>{{directiveModel.validationErrorCount}} Invalid user(s)</i></b>.
Fix them below.
</p>

0 comments on commit 9e7f5b3

Please sign in to comment.