Make Company and Place chip inputs, add Seniority levels and Pay counts to the rail, and keep every filter on a company click
Company and Place are chipInputs on the suggest routes, their chips sent as company_keys and places and read back from the address, place tokens named through /api/places/labels. The old ?company= and ?place= show as a plain chip to take off. Seniority is a row of level chips with "and roles with no level", Pay keeps its select with "and roles that state no pay", each with its count from /api/roles/facets, asked after every reload. Feed rows show the seniority badge. More filters opens by default beside the feed and stays shut on a phone. A company's name now links to the list on screen with that company as its one chip. The strip's sentence says what ★ does, or did. setAffinity passes the route's answer to onChange, so the strip waits on its score_job. The rail's tag chips get their pill border back, which the quiet rail button rule had taken. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
fd89381caa
commit
ae7c0eeb0e
4 files changed
+359
-77
No files matched your search
@@ -70,8 +70,25 @@
|
||||
<details id="f-more" class="rail-more">
|
||||
<summary>More filters<span id="f-active" class="filter-active"></span></summary>
|
||||
<div class="rail-fields">
|
||||
<input type="text" id="f-company" placeholder="Company" aria-label="Company">
|
||||
<input type="text" id="f-place" placeholder="Place" aria-label="Place">
|
||||
{# Company and Place are chip inputs (static/chips.js), each pick a
|
||||
company key or a place token from the suggest routes. The chips
|
||||
of `?company=` and `?place=`, the substrings other pages link
|
||||
with, sit under them to be taken off; nothing types a new one. #}
|
||||
<div id="f-company"></div>
|
||||
<div id="f-company-text" class="rail-legacy" hidden></div>
|
||||
<div id="f-place"></div>
|
||||
<div id="f-place-text" class="rail-legacy" hidden></div>
|
||||
{# The levels come with their counts from /api/roles/facets, so the
|
||||
server's list is the one shown. "No level" is a question only
|
||||
once a level is pressed. #}
|
||||
<div class="rail-facet" role="group" aria-labelledby="f-seniority-label">
|
||||
<span class="rail-field" id="f-seniority-label">Seniority</span>
|
||||
<div id="f-seniority" class="rail-chips"></div>
|
||||
<label class="check" id="f-seniority-unknown-row" hidden>
|
||||
<input type="checkbox" id="f-seniority-unknown"> <span>and roles with no level<span
|
||||
class="count" id="f-seniority-unknown-count"></span></span>
|
||||
</label>
|
||||
</div>
|
||||
<select id="f-function" aria-label="Function">
|
||||
<option value="">Any function</option>
|
||||
{% for value, label in functions %}
|
||||
@@ -84,12 +101,18 @@
|
||||
<option value="{{ value }}">{{ label }}</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
<select id="f-pay" aria-label="Pay">
|
||||
<option value="">Any pay</option>
|
||||
{% for value, label in pay_options %}
|
||||
<option value="{{ value }}">{{ label }}</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
<div class="rail-facet">
|
||||
<select id="f-pay" aria-label="Pay">
|
||||
<option value="" data-label="Any pay">Any pay</option>
|
||||
{% for value, label in pay_options %}
|
||||
<option value="{{ value }}" data-label="{{ label }}">{{ label }}</option>
|
||||
{% endfor %}
|
||||
</select>
|
||||
<label class="check" id="f-pay-unknown-row" hidden>
|
||||
<input type="checkbox" id="f-pay-unknown"> <span>and roles that state no pay<span
|
||||
class="count" id="f-pay-unknown-count"></span></span>
|
||||
</label>
|
||||
</div>
|
||||
<select id="f-judged" aria-label="Judged">
|
||||
<option value="">Any vote</option>
|
||||
<option value="liked">Liked</option>
|
||||
@@ -127,6 +150,10 @@
|
||||
{% endblock %}
|
||||
|
||||
{% block scripts %}
|
||||
{# base.html has no block in its head; a stylesheet linked from the body
|
||||
applies all the same, and chips.css only adds to app.css. #}
|
||||
<link rel="stylesheet" href="{{ asset('chips.css') }}">
|
||||
<script src="{{ asset('chips.js') }}"></script>
|
||||
<script src="{{ asset('judge.js') }}"></script>
|
||||
<script src="{{ asset('roles.js') }}"></script>
|
||||
{% endblock %}
|
||||
Reference in new issue
Block a user