diff --git a/src/quo/components/navigation/page_nav/style.cljs b/src/quo/components/navigation/page_nav/style.cljs index 9be23ab02886..0b2b73660170 100644 --- a/src/quo/components/navigation/page_nav/style.cljs +++ b/src/quo/components/navigation/page_nav/style.cljs @@ -22,13 +22,19 @@ :opacity center-opacity}) (def right-actions-container - {:flex-direction :row}) + {:flex-direction :row + :justify-content :flex-end}) (def right-actions-spacing {:width 12}) -(def right-content-min-size - {:min-width 32 :min-height 32}) +(defn right-content + [min-size?] + (merge + {:flex-grow 1 + :flex-basis 1} + (when min-size? + {:min-height 32}))) (def token-logo {:width 16 :height 16}) diff --git a/src/quo/components/navigation/page_nav/view.cljs b/src/quo/components/navigation/page_nav/view.cljs index 12b33c81d754..7b51dae3c19c 100644 --- a/src/quo/components/navigation/page_nav/view.cljs +++ b/src/quo/components/navigation/page_nav/view.cljs @@ -30,16 +30,17 @@ & children] (into [rn/view {:style (style/container margin-top)} (when icon-name - [button/button - {:type (button-type background) - :icon-only? true - :size 32 - :on-press on-press - :background (if behind-overlay? - :blur - (when (button-properties/backgrounds background) background)) - :accessibility-label accessibility-label} - icon-name])] + [rn/view {:flex-grow 1 :flex-basis 1} + [button/button + {:type (button-type background) + :icon-only? true + :size 32 + :on-press on-press + :background (if behind-overlay? + :blur + (when (button-properties/backgrounds background) background)) + :accessibility-label accessibility-label} + icon-name]])] children)) (defn- right-section-spacing [] [rn/view {:style style/right-actions-spacing}]) @@ -88,7 +89,7 @@ [{:keys [background content max-actions min-size? support-account-switcher? behind-overlay?] :or {support-account-switcher? true}}] - [rn/view (when min-size? {:style style/right-content-min-size}) + [rn/view (style/right-content min-size?) (when (coll? content) (into [rn/view {:style style/right-actions-container}] (add-right-buttons-xf max-actions background behind-overlay? support-account-switcher?)