diff options
author | Miguel Ángel Moreno <mail@migalmoreno.com> | 2024-01-28 12:28:10 +0100 |
---|---|---|
committer | Miguel Ángel Moreno <mail@migalmoreno.com> | 2024-01-28 12:28:10 +0100 |
commit | b899542494a4844de1e7f8bae09c83e011ebbda3 (patch) | |
tree | acd3388cea33fde49ef95c549c7e500c5ec6ef87 /src/frontend | |
parent | c0509cea30783da562647c15bcd4d902f08e68c2 (diff) |
fix(frontend): fix word wrapping
Diffstat (limited to 'src/frontend')
-rw-r--r-- | src/frontend/tubo/components/comments.cljs | 2 | ||||
-rw-r--r-- | src/frontend/tubo/components/items.cljs | 6 |
2 files changed, 5 insertions, 3 deletions
diff --git a/src/frontend/tubo/components/comments.cljs b/src/frontend/tubo/components/comments.cljs index 8e5e2ec..4f3a93a 100644 --- a/src/frontend/tubo/components/comments.cljs +++ b/src/frontend/tubo/components/comments.cljs @@ -31,7 +31,7 @@ (when uploader-verified? [:i.fa-solid.fa-circle-check.ml-2])] [:div.my-2 - [:p.break-words {:dangerouslySetInnerHTML {:__html text}}]] + [:p {:dangerouslySetInnerHTML {:__html text} :class "[overflow-wrap:anywhere]"}]] [:div..flex.items-center.my-2 [:div.mr-4 [:p (util/format-date-ago upload-date)]] diff --git a/src/frontend/tubo/components/items.cljs b/src/frontend/tubo/components/items.cljs index 39179e6..c207a04 100644 --- a/src/frontend/tubo/components/items.cljs +++ b/src/frontend/tubo/components/items.cljs @@ -30,14 +30,16 @@ (when name [:div.flex.items-center.my-2 [:a {:href item-route :title name} - [:h1.line-clamp-2.my-1.break-words {:style {:wordBreak "break-word"}} name]] + [:h1.line-clamp-2.my-1 {:class "[overflow-wrap:anywhere]"} name]] (when (and verified? (not uploader-url)) [:i.fa-solid.fa-circle-check.pl-2])]) [:div.flex.justify-between [:div.flex.items-center.my-2 (if uploader-url [:a {:href (rfe/href :tubo.routes/channel nil {:url uploader-url}) :title uploader-name} - [:h1.line-clamp-1.text-neutral-800.dark:text-gray-300.font-bold.pr-2.break-all uploader-name]] + [:h1.line-clamp-1.text-neutral-800.dark:text-gray-300.font-bold.pr-2.break-all + {:class "[overflow-wrap:anywhere]"} + uploader-name]] [:h1.line-clamp-1.text-neutral-800.dark:text-gray-300.font-bold.pr-2 uploader-name]) (when (and uploader-url verified?) [:i.fa-solid.fa-circle-check])] |