From: Paul Hänsch Date: Mon, 15 Feb 2021 13:38:20 +0000 (+0100) Subject: top link in client list X-Git-Url: https://git.plutz.net/?a=commitdiff_plain;h=be67cb59512145a0fa5b8c6686996f3876618570;p=lobster top link in client list --- diff --git a/cards/index.cgi b/cards/index.cgi index 0bb4f82..b48e54e 100755 --- a/cards/index.cgi +++ b/cards/index.cgi @@ -22,9 +22,9 @@ list_hi_companies(){ { w_filter_diag printf ' [form class="newcard" action="/cards/new_card.sh" method="POST" - [a href="#top" . %s] [button type="submit" %s] - ]' "$(l10n top)" "$(l10n newcard)" + [a href="#top" . %s] + ]' "$(l10n newcard)" "$(l10n page_top)" [ "$edit" ] && edit_card "$edit" list_cards } | yield_page cards #/cards/cards.css diff --git a/l10n.sh b/l10n.sh index cab5bde..66cafc7 100755 --- a/l10n.sh +++ b/l10n.sh @@ -92,6 +92,7 @@ l10n_global() { edit_addfieldtext) printf %s "Neues Feld";; edit_addfield) printf %s "+";; edit_deletefield) printf %s "X";; + page_top) printf %s "⬆ Seitenanfang";; filter_label) printf %s "Filter";; filter_item) printf %s "Eingrenzung nach";; diff --git a/style.css b/style.css index 5edc969..8644f0b 100644 --- a/style.css +++ b/style.css @@ -45,8 +45,14 @@ form.filter button[value=export_csv] { margin-left: 1em; } body.courses form .order { display: inline-block; margin-right: 2em;} -body.cards form.newcard { display: flex; } +body.cards form.newcard { + position: sticky; + top: 0; + background-color: #FFF; + z-index: 2; +} body.cards form.newcard input[name=seed] { flex: 1; } +body.cards form.newcard a[href="#top"] { float: right; } /* ============ LIST ITEMS, Generic ============= */