Reorganize workout view for desktop and compact session details
This commit is contained in:
@@ -1,12 +1,12 @@
|
||||
<tr id="topset-{{ topset_id }}">
|
||||
<tr class="workout-set-row" id="topset-{{ topset_id }}">
|
||||
<td class="p-0 sm:p-4 text-sm font-semibold text-gray-900 break-normal">
|
||||
{% if is_edit|default(false, true) == false %}
|
||||
<div class="flex items-center space-x-2">
|
||||
<div class="workout-exercise-name">
|
||||
<span class="cursor-pointer" hx-get="{{ url_for('tags.goto_tag') }}"
|
||||
hx-vals='{"filter": "?exercise_id={{ exercise_id }}", "person_id" : "{{ person_id }}" }'
|
||||
hx-target="#container" hx-swap="innerHTML" hx-push-url="true"
|
||||
_='on click trigger closeModalWithoutRefresh'>{{ exercise_name }}</span>
|
||||
<div class="flex flex-col sm:flex-row space-y-1 sm:space-y-0 sm:space-x-1">
|
||||
<div class="workout-exercise-tools">
|
||||
<button
|
||||
class="inline-flex justify-center p-1 text-gray-500 rounded cursor-pointer hover:text-gray-900 hover:bg-gray-100 dark:text-gray-400 dark:hover:text-white dark:hover:bg-gray-600"
|
||||
title="Show Progress Graph"
|
||||
@@ -17,7 +17,7 @@
|
||||
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"
|
||||
d="M13 7h8m0 0v8m0-8l-8 8-4-4-6 6"></path>
|
||||
</svg>
|
||||
<span class="sr-only">Show Progress Graph</span>
|
||||
<span class="workout-tool-label">Progress</span>
|
||||
</button>
|
||||
<button
|
||||
class="inline-flex justify-center p-1 text-gray-500 rounded cursor-pointer hover:text-gray-900 hover:bg-gray-100 dark:text-gray-400 dark:hover:text-white dark:hover:bg-gray-600"
|
||||
@@ -29,7 +29,7 @@
|
||||
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2"
|
||||
d="M4 6h16M4 10h16M4 14h16M4 18h16"></path>
|
||||
</svg>
|
||||
<span class="sr-only">Show History</span>
|
||||
<span class="workout-tool-label">History</span>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
@@ -57,11 +57,11 @@
|
||||
<div class="flex items-center flex-col sm:flex-row">
|
||||
<input type="number"
|
||||
class="bg-gray-50 border border-gray-300 text-gray-900 text-sm rounded-lg focus:ring-blue-500 focus:border-blue-500 block w-full pl-4 sm:pl-10 p-2.5 "
|
||||
name="repetitions" value="{{ repetitions }}">
|
||||
aria-label="Repetitions" name="repetitions" value="{{ repetitions }}">
|
||||
<p class="px-2">x</p>
|
||||
<input type="number"
|
||||
class="bg-gray-50 border border-gray-300 text-gray-900 text-sm rounded-lg focus:ring-blue-500 focus:border-blue-500 block w-full pl-4 sm:pl-10 p-2.5 "
|
||||
name="weight" value="{{ weight }}">
|
||||
aria-label="Weight in kilograms" step="any" name="weight" value="{{ weight }}">
|
||||
<p class="px-2">kg</p>
|
||||
</div>
|
||||
{% endif %}
|
||||
@@ -118,7 +118,7 @@
|
||||
</td>
|
||||
</tr>
|
||||
{# Target row modified for dismissible extra content (graph or history) #}
|
||||
<tr id="extra-target-{{ topset_id }}">
|
||||
<tr id="extra-target-{{ topset_id }}" {% if existing_row|default(false) or is_edit|default(false) %}hx-swap-oob="outerHTML"{% endif %}>
|
||||
<td colspan="3" class="p-0 relative">
|
||||
<div id="extra-content-{{ topset_id }}" class="extra-content-container" _="
|
||||
on htmx:afterSwap
|
||||
|
||||
Reference in New Issue
Block a user