Skip to content

Commit

Permalink
moving to parrtial
Browse files Browse the repository at this point in the history
  • Loading branch information
jasonwang7517 committed Jan 5, 2025
1 parent 984b814 commit 74261dc
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 16 deletions.
8 changes: 8 additions & 0 deletions app/views/organizations/shared/_tooltip.html.erb
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
<div data-controller="tooltip" data-action="mouseenter->tooltip#showTooltip mouseleave->tooltip#hideTooltip" class="mb-3 ms-1" tabindex="0">
<i class="fe fe-help-circle"></i>
<div data-tooltip-target="tooltip" class="tooltip bs-tooltip-top fade" role="tooltip" style="display: none; position:absolute;">
<div class="tooltip-inner">
<%= text %>
</div>
</div>
</div>
18 changes: 2 additions & 16 deletions app/views/organizations/staff/pets/_form.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -83,27 +83,13 @@
<div class="form-check form-switch d-flex align-items-center ps-3">
<%= form.hidden_field :application_paused, value: false %>
<%= form.check_box :application_paused, { class: "form-check-input", role: "switch", id: "flexSwitchCheckChecked" }, true, false %>
<div data-controller="tooltip" data-action="mouseenter->tooltip#showTooltip mouseleave->tooltip#hideTooltip" class="mb-3 ms-1" tabindex="0">
<i class="fe fe-help-circle"></i>
<div data-tooltip-target="tooltip" class="tooltip bs-tooltip-top fade" role="tooltip" style="display: none; position:absolute;">
<div class="tooltip-inner">
Pet is visible to public but adopters cannot make applications
</div>
</div>
</div>
<%= render partial: "organizations/shared/tooltip", locals: {text: "Pet is visible to public but adopters cannot make applications" } %>
</div>

<div class="form-check form-switch ps-3">
<%= form.hidden_field :published, value: false %>
<%= form.check_box :published, { class: "form-check-input", role: "switch", required: false }, true, false %>
<div data-controller="tooltip" data-action="mouseenter->tooltip#showTooltip mouseleave->tooltip#hideTooltip" class="mb-3 ms-1" tabindex="0">
<i class="fe fe-help-circle"></i>
<div data-tooltip-target="tooltip" class="tooltip bs-tooltip-top fade" role="tooltip" style="display: none; position:absolute;">
<div class="tooltip-inner">
Pet is visible to public
</div>
</div>
</div>
<%= render partial: "organizations/shared/tooltip", locals: {text: "Pet is visible to public" } %>
</div>
</div>

Expand Down

0 comments on commit 74261dc

Please sign in to comment.