Skip to content

Commit

Permalink
[nested-grid] Fix ellipsis overflow for row-headers
Browse files Browse the repository at this point in the history
  • Loading branch information
kimo-k committed Nov 8, 2024
1 parent c0c7ca0 commit c8f75fd
Showing 1 changed file with 11 additions and 3 deletions.
14 changes: 11 additions & 3 deletions src/re_com/theme/default.cljs
Original file line number Diff line number Diff line change
Expand Up @@ -85,20 +85,25 @@
(defmethod base ::nested-grid/column-header-wrapper [props _]
(update props :style merge
{:user-select "none"
:width "100%"
:height "100%"}))
:width "100%"
:height "100%"}))

(defmethod base ::nested-grid/row-header
[props {{:keys [sticky? sticky-top]} :state}]
(update props :style merge {:width "100%"
:text-overflow :ellipsis
:overflow :hidden
:white-space :nowrap
:position :sticky
:top sticky-top}))

(defmethod base ::nested-grid/column-header
[props _]
(update props :style merge {:height "100%"}))
(update props :style merge {:height "100%"
:text-overflow :ellipsis
:overflow :hidden
:whitespace :nowrap}))


(defmethod base :default [props {:keys [state part transition!]
{:keys [sm-2]} :variables
Expand Down Expand Up @@ -295,6 +300,9 @@
{:style {:padding-top sm-3
:padding-right sm-4
:padding-left sm-4
:white-space :nowrap
:text-overflow :ellipsis
:overflow :hidden
:background-color light-background
:color "#666"
:text-align (or align-column-header align-column align :center)
Expand Down

0 comments on commit c8f75fd

Please sign in to comment.