From 0210f413ab9e2dd4acf5fef5c79089c6ac9226bc Mon Sep 17 00:00:00 2001 From: Andrey Shovkoplyas Date: Fri, 23 Aug 2019 11:08:45 +0300 Subject: [PATCH] list-item fix Signed-off-by: Andrey Shovkoplyas --- fiddle/src/fiddle/views/list_items.cljs | 20 ++++++++++++++++++- .../ui/components/list_item/views.cljs | 3 +-- 2 files changed, 20 insertions(+), 3 deletions(-) diff --git a/fiddle/src/fiddle/views/list_items.cljs b/fiddle/src/fiddle/views/list_items.cljs index a3e9841984..d4d0cb6fc8 100644 --- a/fiddle/src/fiddle/views/list_items.cljs +++ b/fiddle/src/fiddle/views/list_items.cljs @@ -125,4 +125,22 @@ :background-color colors/blue :align-items :center :justify-content :center} [react/text {:style {:color colors/white :font-size 12}} "1"]] - :chevron]}]]]]) \ No newline at end of file + :chevron]}]]] + [react/view {:margin-right 10} + [item "Long title" + [list-item/list-item {:title "loooooooooong looooooong looooooong title" + :subtitle "ENS name" + :icon :main-icons/address + :accessories [:chevron] + :on-press #()}]] + [item "Long subtitle" + [list-item/list-item {:title "alex.stateofus.eth" + :subtitle "loooooooooooong loooooong looooooong subtitle" + :icon :main-icons/address + :accessories [:chevron] + :on-press #()}]] + [item "Long accessories" + [list-item/list-item {:title "From" + :type :small + :accessories ["loooooooooooongloooooonglooo00oooongaccessories"] + :on-press #()}]]]]) \ No newline at end of file diff --git a/src/status_im/ui/components/list_item/views.cljs b/src/status_im/ui/components/list_item/views.cljs index dbd176031e..44a716c9f2 100644 --- a/src/status_im/ui/components/list_item/views.cljs +++ b/src/status_im/ui/components/list_item/views.cljs @@ -34,7 +34,7 @@ :style (styles/photo 40)}]]) ;;Title (when title - [react/view {:style {:margin-left 16 :margin-right 16}} + [react/view {:style {:margin-left 16 :margin-right 16 :flex 1 :min-width 50}} [react/text {:style (merge (styles/title small? subtitle) (when (= theme :action) st/action-button-label) (when (= theme :action-red) st/action-button-label-red)) @@ -52,7 +52,6 @@ (if (vector? content) content [content])) - [react/view {:flex 1}] ;;Accessories (for [accessory accessories] (when-not (nil? accessory)