fix(ui): truncate long slug in event type card#28535
Open
pranavv00 wants to merge 2 commits intocalcom:mainfrom
Open
fix(ui): truncate long slug in event type card#28535pranavv00 wants to merge 2 commits intocalcom:mainfrom
pranavv00 wants to merge 2 commits intocalcom:mainfrom
Conversation
Contributor
There was a problem hiding this comment.
1 issue found across 1 file
Prompt for AI agents (unresolved issues)
Check if these issues are valid — if so, understand the root cause of each and fix them. If appropriate, use sub-agents to investigate and fix each issue separately.
<file name="apps/web/modules/event-types/views/event-types-listing-view.tsx">
<violation number="1" location="apps/web/modules/event-types/views/event-types-listing-view.tsx:197">
P2: `truncate` won’t show ellipsis on inline `span`/`small` elements; they need a constrained box (block/inline-block or flex item with width) for `text-overflow` to work. As-is, long titles/slugs will be hard-clipped by the parent overflow instead of showing an ellipsis.</violation>
</file>
Reply with feedback, questions, or to request a fix. Tag @cubic-dev-ai to re-run a review.
| <div> | ||
| <span | ||
| className="text-default break-words font-semibold ltr:mr-1 rtl:ml-1" | ||
| className="text-default truncate font-semibold ltr:mr-1 rtl:ml-1" |
Contributor
There was a problem hiding this comment.
P2: truncate won’t show ellipsis on inline span/small elements; they need a constrained box (block/inline-block or flex item with width) for text-overflow to work. As-is, long titles/slugs will be hard-clipped by the parent overflow instead of showing an ellipsis.
Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. At apps/web/modules/event-types/views/event-types-listing-view.tsx, line 197:
<comment>`truncate` won’t show ellipsis on inline `span`/`small` elements; they need a constrained box (block/inline-block or flex item with width) for `text-overflow` to work. As-is, long titles/slugs will be hard-clipped by the parent overflow instead of showing an ellipsis.</comment>
<file context>
@@ -194,13 +194,13 @@ const Item = ({
<div>
<span
- className="text-default break-words font-semibold ltr:mr-1 rtl:ml-1"
+ className="text-default truncate font-semibold ltr:mr-1 rtl:ml-1"
data-testid={`event-type-title-${type.id}`}>
{type.title}
</file context>
Suggested change
| className="text-default truncate font-semibold ltr:mr-1 rtl:ml-1" | |
| className="text-default inline-block max-w-full truncate font-semibold ltr:mr-1 rtl:ml-1" |
Member
sahitya-chandra
left a comment
There was a problem hiding this comment.
Can you add a before and after video demo of the UI changes?
3 tasks
Ryukemeister
requested changes
Mar 23, 2026
Contributor
Ryukemeister
left a comment
There was a problem hiding this comment.
hi there, thank you for your contribution. can you add a visual demo of the fix before and after, thanks!
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fix issue- #28533
Long slug/URL text in the event type card could overflow its container and break layout.
This change replaces
break-wordswith Tailwind'struncateutility on the text elements to ensure long text is properly truncated with ellipsis, preventing overflow while preserving the existing layout and responsiveness.No structural or layout changes were introduced.