wrap items in accounts header

fixes mobile layout.
pull/75/head
Harvey Tindall 4 years ago
parent b91de3f319
commit cfa7947020
No known key found for this signature in database
GPG Key ID: BBC65952848FB1A2

@ -448,4 +448,5 @@ a:hover:not(.lang-link):not(.\~urge), a:active:not(.lang-link):not(.\~urge) {
.search { .search {
max-width: 15rem; max-width: 15rem;
min-width: 10rem;
} }

@ -396,17 +396,17 @@
</div> </div>
<div id="tab-accounts" class="unfocused"> <div id="tab-accounts" class="unfocused">
<div class="card ~neutral !low accounts mb-1"> <div class="card ~neutral !low accounts mb-1">
<div class="flex-expand"> <div class="flex-expand row">
<div class="flex-row"> <div class="row">
<span class="heading">{{ .strings.accounts }}</span> <span class="heading mr-1 col">{{ .strings.accounts }}</span>
<input type="search" class="field ~neutral !normal input search ml-1 mr-1" id="accounts-search" placeholder="{{ .strings.search }}"> <input type="search" class="col field ~neutral !normal input search ml-1 mr-1" id="accounts-search" placeholder="{{ .strings.search }}">
</div> </div>
<div> <div class="row">
<span class="button ~neutral !normal mb-half" id="accounts-add-user">{{ .quantityStrings.addUser.Singular }}</span> <span class="col button ~neutral !normal mb-half" id="accounts-add-user">{{ .quantityStrings.addUser.Singular }}</span>
<span class="button ~info !normal mb-half" id="accounts-announce">{{ .strings.announce }}</span> <span class="col button ~info !normal mb-half" id="accounts-announce">{{ .strings.announce }}</span>
<span class="button ~urge !normal mb-half" id="accounts-modify-user">{{ .strings.modifySettings }}</span> <span class="col button ~urge !normal mb-half" id="accounts-modify-user">{{ .strings.modifySettings }}</span>
<span class="button ~warning !normal mb-half" id="accounts-extend-expiry">{{ .strings.extendExpiry }}</span> <span class="col button ~warning !normal mb-half" id="accounts-extend-expiry">{{ .strings.extendExpiry }}</span>
<span class="button ~critical !normal mb-half" id="accounts-delete-user">{{ .quantityStrings.deleteUser.Singular }}</span> <span class="col button ~critical !normal mb-half" id="accounts-delete-user">{{ .quantityStrings.deleteUser.Singular }}</span>
</div> </div>
</div> </div>
<div class="card ~neutral !normal accounts-header table-responsive mt-half"> <div class="card ~neutral !normal accounts-header table-responsive mt-half">

@ -8,6 +8,7 @@ import (
"path/filepath" "path/filepath"
"strconv" "strconv"
"strings" "strings"
"sync"
"time" "time"
"github.com/hrfee/jfa-go/mediabrowser" "github.com/hrfee/jfa-go/mediabrowser"
@ -25,6 +26,7 @@ type Storage struct {
policy mediabrowser.Policy policy mediabrowser.Policy
configuration mediabrowser.Configuration configuration mediabrowser.Configuration
lang Lang lang Lang
invitesLock sync.Mutex
} }
type customEmails struct { type customEmails struct {
@ -402,10 +404,14 @@ func (st *Storage) loadLangEmail(filesystems ...fs.FS) error {
type Invites map[string]Invite type Invites map[string]Invite
func (st *Storage) loadInvites() error { func (st *Storage) loadInvites() error {
st.invitesLock.Lock()
defer st.invitesLock.Unlock()
return loadJSON(st.invite_path, &st.invites) return loadJSON(st.invite_path, &st.invites)
} }
func (st *Storage) storeInvites() error { func (st *Storage) storeInvites() error {
st.invitesLock.Lock()
defer st.invitesLock.Unlock()
return storeJSON(st.invite_path, st.invites) return storeJSON(st.invite_path, st.invites)
} }

Loading…
Cancel
Save