mirror of
https://github.com/penpot/penpot.git
synced 2025-01-22 14:39:45 -05:00
✨ Fix html-lang-missing accesibility issues
This commit is contained in:
parent
4ef876bf58
commit
6a329fac27
2 changed files with 5 additions and 0 deletions
|
@ -53,6 +53,10 @@
|
|||
[^string title]
|
||||
(set! (.-title globals/document) title))
|
||||
|
||||
(defn set-html-lang!
|
||||
[^string lang]
|
||||
(.setAttribute (.querySelector js/document "html") "lang" lang))
|
||||
|
||||
(defn set-html-theme-color
|
||||
[^string color scheme]
|
||||
(let [meta-node (.querySelector js/document "meta[name='theme-color']")]
|
||||
|
|
|
@ -105,6 +105,7 @@
|
|||
(add-watch locale ::browser-font
|
||||
(fn [_ _ _ locale]
|
||||
(log/info :hint "locale changed" :locale locale)
|
||||
(dom/set-html-lang! locale)
|
||||
(let [node (dom/get-body)]
|
||||
(if (or (= locale "fa")
|
||||
(= locale "ar"))
|
||||
|
|
Loading…
Add table
Reference in a new issue