Skip to content

Conversation

@TyrellHaywood
Copy link
Contributor

Description:

Fixes asset names overlapping with the "Latest Run" field in the DAG list view by adding maxWidth constraints to HStack containers in the AssetSchedule component.

When DAGs have asset-based schedules with long asset names, the names were extending beyond their column boundaries and overlapping with the "Latest Run" timestamp field, making it difficult to read.

This change adds maxWidth="200px" to the HStack containers wrapping asset names in the AssetSchedule component, ensuring proper text truncation and preventing overlap with adjacent columns.

closes: #56669


^ Add meaningful description above
Read the Pull Request Guidelines for more information.
In case of fundamental code changes, an Airflow Improvement Proposal (AIP) is needed.
In case of a new dependency, check compliance with the ASF 3rd Party License Policy.
In case of backwards incompatible changes please leave a note in a newsfragment file, named {pr_number}.significant.rst or {issue_number}.significant.rst, in airflow-core/newsfragments.

@boring-cyborg boring-cyborg bot added the area:UI Related to UI/UX. For Frontend Developers. label Oct 22, 2025
Copy link
Member

@pierrejeambrun pierrejeambrun left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you add a screenshot after this change?

I'm not a fan of adding hard coded width in pixel. That could still happen on small screens I guess. Instead we could wrap/word break if it's too big.

@pierrejeambrun pierrejeambrun added this to the Airflow 3.1.2 milestone Oct 23, 2025
@pierrejeambrun pierrejeambrun added the backport-to-v3-1-test Mark PR with this label to backport to v3-1-test branch label Oct 23, 2025
- Add maxWidth constraint to HStack containers in AssetSchedule component
- Prevents asset names from overlapping with Latest Run column
@TyrellHaywood
Copy link
Contributor Author

@pierrejeambrun

Thanks for the feedback! Yes that makes more sense. I've updated the approach to use word-break instead of a hard-coded pixel width. The asset names now wrap to a maximum of 2 lines before truncating with ellipsis, which prevents overflow while keeping the layout clean.

Here's a screenshot showing the fix with long asset names:
image

Let me know if this looks good!

@pierrejeambrun
Copy link
Member

pierrejeambrun commented Oct 27, 2025

I just pushed a commit to use the existing component instead:
Screenshot 2025-10-27 at 16 07 42

@pierrejeambrun pierrejeambrun merged commit 9fa4462 into apache:main Oct 27, 2025
58 checks passed
@boring-cyborg
Copy link

boring-cyborg bot commented Oct 27, 2025

Awesome work, congrats on your first merged pull request! You are invited to check our Issue Tracker for additional contributions.

github-actions bot pushed a commit that referenced this pull request Oct 27, 2025
* Fix asset name overflow in DAG list view

- Add maxWidth constraint to HStack containers in AssetSchedule component
- Prevents asset names from overlapping with Latest Run column

* Fix asset name overflow with word-break and line clamping

* Use TruncatedText component instead

---------
(cherry picked from commit 9fa4462)

Co-authored-by: Tyrell H <73722828+TyrellHaywood@users.noreply.github.com>
Co-authored-by: pierrejeambrun <pierrejbrun@gmail.com>
@github-actions
Copy link

Backport successfully created: v3-1-test

Status Branch Result
v3-1-test PR Link

github-actions bot pushed a commit to aws-mwaa/upstream-to-airflow that referenced this pull request Oct 27, 2025
* Fix asset name overflow in DAG list view

- Add maxWidth constraint to HStack containers in AssetSchedule component
- Prevents asset names from overlapping with Latest Run column

* Fix asset name overflow with word-break and line clamping

* Use TruncatedText component instead

---------
(cherry picked from commit 9fa4462)

Co-authored-by: Tyrell H <73722828+TyrellHaywood@users.noreply.github.com>
Co-authored-by: pierrejeambrun <pierrejbrun@gmail.com>
jscheffl pushed a commit that referenced this pull request Oct 27, 2025
* Fix asset name overflow in DAG list view

- Add maxWidth constraint to HStack containers in AssetSchedule component
- Prevents asset names from overlapping with Latest Run column

* Fix asset name overflow with word-break and line clamping

* Use TruncatedText component instead

---------
(cherry picked from commit 9fa4462)

Co-authored-by: Tyrell H <73722828+TyrellHaywood@users.noreply.github.com>
Co-authored-by: pierrejeambrun <pierrejbrun@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:UI Related to UI/UX. For Frontend Developers. backport-to-v3-1-test Mark PR with this label to backport to v3-1-test branch

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Dag schedules with longer asset names overlap with the entry in the latest run field in dag list

2 participants