Add accessibility label for community options button (#15484)
This commit is contained in:
parent
394dfde87b
commit
e825f930fa
|
@ -150,13 +150,15 @@
|
||||||
:justify-content :flex-end)}
|
:justify-content :flex-end)}
|
||||||
(let [last-icon-index (-> right-section-buttons count dec)]
|
(let [last-icon-index (-> right-section-buttons count dec)]
|
||||||
(map-indexed (fn [index
|
(map-indexed (fn [index
|
||||||
{:keys [icon on-press type style icon-override-theme]
|
{:keys [icon on-press type style icon-override-theme accessibility-label]
|
||||||
:or {type :grey}}]
|
:or {type :grey}}]
|
||||||
^{:key index}
|
^{:key index}
|
||||||
[rn/view
|
[rn/view
|
||||||
{:style (assoc style
|
(cond-> {:style (assoc style
|
||||||
:margin-right
|
:margin-right
|
||||||
(if (= index last-icon-index) 0 8))}
|
(if (= index last-icon-index) 0 8))}
|
||||||
|
accessibility-label (assoc :accessibility-label accessibility-label
|
||||||
|
:accessible true))
|
||||||
[button/button
|
[button/button
|
||||||
{:on-press on-press
|
{:on-press on-press
|
||||||
:icon true
|
:icon true
|
||||||
|
|
|
@ -295,14 +295,14 @@
|
||||||
|
|
||||||
(defn page-nav-right-section-buttons
|
(defn page-nav-right-section-buttons
|
||||||
[id]
|
[id]
|
||||||
[{:icon :i/options
|
[{:icon :i/options
|
||||||
:background-color (scroll-page/icon-color)
|
:background-color (scroll-page/icon-color)
|
||||||
:on-press #(rf/dispatch
|
:accessibility-label :community-options-for-community
|
||||||
[:bottom-sheet/show-sheet
|
:on-press #(rf/dispatch
|
||||||
{:content
|
[:bottom-sheet/show-sheet
|
||||||
(fn []
|
{:content (fn []
|
||||||
[options/community-options-bottom-sheet
|
[options/community-options-bottom-sheet
|
||||||
id])}])}])
|
id])}])}])
|
||||||
|
|
||||||
(defn pick-first-category-by-height
|
(defn pick-first-category-by-height
|
||||||
[scroll-height first-channel-height categories-heights]
|
[scroll-height first-channel-height categories-heights]
|
||||||
|
|
Loading…
Reference in New Issue