Skip to content

Add kiosk sign-out quick-pick for recently-used categories#48

Open
OSPFNeighbour wants to merge 2 commits into
mainfrom
pr48
Open

Add kiosk sign-out quick-pick for recently-used categories#48
OSPFNeighbour wants to merge 2 commits into
mainfrom
pr48

Conversation

@OSPFNeighbour

@OSPFNeighbour OSPFNeighbour commented Jul 21, 2026

Copy link
Copy Markdown
Collaborator

Adds a config-gated screen between member scan-out and the full category
tree, showing touch-friendly shortcuts for the categories most frequently
used recently at this location (with who last used each one) and by this
member, ranked by frequency then recency. Falls through to the existing
full category tree via "More categories", or automatically when there's
nothing to suggest yet (e.g. a brand new location or member).

Stacks on the admin OptionList/OptionRow restyle so the new
'Quick pick categories' rollout flag can reuse the shared option-row
component.

  • api: Location.recentCategories / Person.recentCategories GraphQL fields,
    ranked over a bounded recent-periods window via the existing
    start_time-sorted GSIs (no DB schema change), with unit tests for the
    ranking/dedupe/enabled-category logic
  • web/kiosk: new ScanScreenQuickPick screen wired into ScanController's
    scan -> quick pick -> categories -> adjust flow, gated behind a new
    quickPickCategories session config flag (default off)
  • web/admin: 'Quick pick categories' checkbox on the kiosk session form

Stack created with Sapling. Best reviewed with ReviewStack.

…w primitive

Unifies the Mode and Options checklists in the kiosk session admin form
(and the location selector) onto shared OptionList/OptionRow/OptionButtonRow
components instead of ad-hoc bordered divs, for a consistent bordered-list
look and less duplicated markup.
Adds a config-gated screen between member scan-out and the full category
tree, showing touch-friendly shortcuts for the categories most frequently
used recently at this location (with who last used each one) and by this
member, ranked by frequency then recency. Falls through to the existing
full category tree via "More categories", or automatically when there's
nothing to suggest yet (e.g. a brand new location or member).

Stacks on the admin OptionList/OptionRow restyle so the new
'Quick pick categories' rollout flag can reuse the shared option-row
component.

- api: Location.recentCategories / Person.recentCategories GraphQL fields,
  ranked over a bounded recent-periods window via the existing
  start_time-sorted GSIs (no DB schema change), with unit tests for the
  ranking/dedupe/enabled-category logic
- web/kiosk: new ScanScreenQuickPick screen wired into ScanController's
  scan -> quick pick -> categories -> adjust flow, gated behind a new
  quickPickCategories session config flag (default off)
- web/admin: 'Quick pick categories' checkbox on the kiosk session form
@jacksgithubacct

Copy link
Copy Markdown

This looks great, and it matches our experience that the parent/child drill-down
is the slowest part of a sign-out.

For what it's worth: we've been running essentially this feature as an interim
Tampermonkey userscript at BME and BMW since mid-May, so a couple of months of
real muster-night use. It reads periods and injects a "Recently used" row into
the category screen. Obviously a native, config-gated screen is the right home
for it - happy to retire ours once this lands. A few things we learned the hard
way that might be worth considering:

Exclude the trainer/assessor branches. We skip anything under Trainer,
Assessor and Workshop - Trainer. Those roles sign out against a lot of
distinct categories, and without the exclusion they crowd out the picks the
majority of members actually need. Might be worth making the excluded parents
configurable per location.

Rank by most recent activity, not just frequency. We order by
max(startTime, endTime), counting endTime only when it is in the past (a
genuine completed sign-out) rather than a scheduled/future end. The effect is
that as soon as the first person signs out of an activity, that category is top
of the list for the next twenty people doing the same thing on the same night.
Pure frequency over a long window tends to lag the activity that's actually
happening tonight. "Frequency then recency" may already cover this, but the
ordering mattered a lot for us.

Disambiguate child names by parent. Several child categories share a name
across parents - Other exists under multiple parents. A quick-pick tile
showing only the child name is genuinely ambiguous, so we show the child name on
the tile with the parent underneath it. Worth surfacing the parent somewhere in
ScanScreenQuickPick.

Showing who last used each one is a nice touch we don't have, and the fallback
to the full tree when there isn't enough data is definitely the right call.

Ours is here if any of it is useful:
https://github.com/jacksgithubacct/seslogin-tools (quick-tiles.user.js).
It's a DOM-level hack against the kiosk markup, so treat it as a description of
the behaviour rather than an implementation to copy.

Happy to test this at our units once it's merged if that would help.

@OSPFNeighbour

OSPFNeighbour commented Jul 25, 2026 via email

Copy link
Copy Markdown
Collaborator Author

@jacksgithubacct

Copy link
Copy Markdown

Yeah, different ways of skinning the same cat. I purely went down the path of 'the last 6 used' by the unit, so didnt
want to have a Trainer/Assessor one first in the queue and then a number of student clicking that one.
With your logic, the 20 participants should outrank the 1 trainer and not show up in the list

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants