mirror of
https://github.com/penpot/penpot.git
synced 2025-05-17 23:26:10 +02:00
✨ Improve login accessibility
This commit is contained in:
parent
8bc265a598
commit
95a18fce8d
20 changed files with 978 additions and 251 deletions
20
frontend/src/app/main/ui/components/link.cljs
Normal file
20
frontend/src/app/main/ui/components/link.cljs
Normal file
|
@ -0,0 +1,20 @@
|
|||
;; This Source Code Form is subject to the terms of the Mozilla Public
|
||||
;; License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
;; file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||
;;
|
||||
;; Copyright (c) KALEIDOS INC
|
||||
|
||||
(ns app.main.ui.components.link
|
||||
(:require
|
||||
[app.util.keyboard :as kbd]
|
||||
[rumext.v2 :as mf]))
|
||||
|
||||
(mf/defc link [{:keys [action name klass data-test]}]
|
||||
[:a {:on-click action
|
||||
:klass klass
|
||||
:on-key-down (fn [event]
|
||||
(when (kbd/enter? event)
|
||||
(action event)))
|
||||
:tabindex "0"
|
||||
:data-test data-test}
|
||||
name])
|
Loading…
Add table
Add a link
Reference in a new issue