The account page (was "Your keys") shows the last thirty days of the person's own use - requests, tokens, spend and tokens per day - and, for each place they can spend, what they used there and a bar for every budget that applies: their own, a per-member one, or a project's, team's or organization's shared with others, named as such. Bars turn amber past four-fifths and red when spent. It sits under the keys now, above the password form. Spend is read from the usage table for the pool each limit counts against, from the start of its period. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
31 lines
1.4 KiB
HTML
31 lines
1.4 KiB
HTML
{{/* The one menu every signed-in page draws. The order never changes and the
|
|
page you are on is marked, not offered, so moving between pages reads as
|
|
moving within one program. */}}
|
|
{{define "nav"}}<nav class="menu" aria-label="Main">
|
|
{{- if and .Org (not .Admin)}}
|
|
<a href="/org"{{if eq .Current "org"}} aria-current="page"{{end}}>Organization</a>
|
|
<span class="menu-gap" aria-hidden="true"></span>
|
|
{{- end}}
|
|
{{- if .Admin}}
|
|
<a href="/admin"{{if eq .Current "cluster"}} aria-current="page"{{end}}>Cluster</a>
|
|
<a href="/admin/users"{{if eq .Current "people"}} aria-current="page"{{end}}>People</a>
|
|
{{- if .Quotas}}
|
|
<a href="/admin/quotas"{{if eq .Current "quotas"}} aria-current="page"{{end}}>Quotas</a>
|
|
<a href="/admin/usage"{{if eq .Current "usage"}} aria-current="page"{{end}}>Usage</a>
|
|
{{- end}}
|
|
{{- if .Mirror}}
|
|
<a href="/admin/mirror"{{if eq .Current "mirror"}} aria-current="page"{{end}}>Mirror</a>
|
|
{{- end}}
|
|
{{- if .Org}}
|
|
<a href="/org"{{if eq .Current "org"}} aria-current="page"{{end}}>Organizations</a>
|
|
{{- end}}
|
|
<span class="menu-gap" aria-hidden="true"></span>
|
|
{{- end}}
|
|
<a href="/chat"{{if eq .Current "chat"}} aria-current="page"{{end}}>Chat</a>
|
|
<a href="/profile"{{if eq .Current "keys"}} aria-current="page"{{end}}>Account</a>
|
|
<form method="post" action="/logout" class="inline">
|
|
<input type="hidden" name="csrf" value="{{.CSRF}}">
|
|
<button type="submit" class="link">Sign out</button>
|
|
</form>
|
|
</nav>{{end}}
|