style(ui): simplify scan input and normalize form text

- Remove check-in and add links from scan input partial
- Add "or" separator between camera and text input
- Remove redundant text-sm from input fields (now in .input-field CSS)
- Fix label text size and color in check-in form
This commit is contained in:
Jon Seager 2026-02-07 20:59:02 +00:00
parent 3741d2e281
commit 4ee89e2336
No known key found for this signature in database
3 changed files with 6 additions and 19 deletions

View file

@ -203,7 +203,7 @@ block title %}Brewlog · Check In{% endblock %} {% block head %}
<!-- Saved cafes -->
{% if !cafe_options.is_empty() %}
<div class="mt-3 border-t pt-3" data-show="!$_reviewingCafe">
<p class="mb-2 text-xs text-text-muted">Or choose a saved cafe:</p>
<p class="mb-2 text-sm text-text-secondary">Or choose a saved cafe:</p>
<searchable-select
name="saved_cafe_id"
placeholder="Type to search saved cafes&hellip;"
@ -257,7 +257,7 @@ block title %}Brewlog · Check In{% endblock %} {% block head %}
{% if !roast_options.is_empty() %}
<div class="border-t pt-3">
<p class="text-xs text-text-muted mb-2">Or select an existing roast:</p>
<p class="text-sm text-text-secondary mb-2">Or select an existing roast:</p>
<searchable-select
name="roast_id"
placeholder="Type to search existing roasts&hellip;"

View file

@ -47,14 +47,14 @@ const locateUser = (triggerEl) => {
<span data-show="$_locating" style="display: none">{{ icons::spinner("h-5 w-5") }}</span>
</button>
<input type="text" data-bind:_city-name
class="input-field w-full text-sm"
class="input-field w-full"
data-attr:placeholder="$_locationFound ? 'Using your location (' + $_userLat.toFixed(2) + ', ' + $_userLng.toFixed(2) + ')' : 'Name of city or area'"
data-attr:disabled="$_locationFound"
data-on:input__debounce.350ms="$_cityName.length >= 2 && $_cafeSearch.length >= 2 && @get('/api/v1/nearby-cafes?near=' + encodeURIComponent($_cityName) + '&q=' + encodeURIComponent($_cafeSearch), {responseOverrides: {selector: '#nearby-results', mode: 'replace'}})"
/>
</div>
<input type="text" data-bind:_cafe-search
class="input-field w-full text-sm"
class="input-field w-full"
placeholder="Search for a cafe&hellip;"
data-on:input__debounce.350ms="if ($_locationFound) { @get('/api/v1/nearby-cafes?lat=' + $_userLat + '&lng=' + $_userLng + '&q=' + encodeURIComponent($_cafeSearch), {responseOverrides: {selector: '#nearby-results', mode: 'replace'}}) } else { $_cityName.length >= 2 && $_cafeSearch.length >= 2 && @get('/api/v1/nearby-cafes?near=' + encodeURIComponent($_cityName) + '&q=' + encodeURIComponent($_cafeSearch), {responseOverrides: {selector: '#nearby-results', mode: 'replace'}}) }"
/>

View file

@ -9,24 +9,11 @@
>
{{ icons::camera("h-5 w-5") }}
</brew-photo-capture>
<a href="/check-in"
class="shrink-0 inline-flex items-center justify-center rounded-md border p-2.5 text-accent transition hover:bg-surface-alt"
title="Check in at a cafe"
aria-label="Check in at a cafe"
>
{{ icons::location("h-5 w-5") }}
</a>
<a href="/add"
class="shrink-0 inline-flex items-center justify-center rounded-md border p-2.5 text-accent transition hover:bg-surface-alt"
title="Add manually"
aria-label="Add manually"
>
{{ icons::plus("h-5 w-5") }}
</a>
<span class="text-xs text-text-muted" style="font-variant: small-caps">or</span>
<input
type="text"
name="prompt"
class="input-field w-full text-sm"
class="input-field w-full"
placeholder="{{ placeholder }}"
/>
</div>