Skip to content

Differentiate selected and hovered table rows #2675

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 2 commits into
base: develop
Choose a base branch
from

Conversation

jackherbst0
Copy link

What type of PR is this? (Check all that apply)

  • 🛠 Refactor
  • [ x] ✨ Feature
  • 🐛 Bug Fix
  • ⚡ Optimization
  • 📝 Documentation Update

Description

For tables with striped rows: selected rows will revert to 100% opacity (from 50%) to prevent confusion when hovering over adjacent rows. When a selected row is at 50% opacity, it is difficult to differentiate from a row which is being hovered over.

Related Tickets & Documents

How to reproduce the issue

Run table_example.py in taipy/doc/examples. Switch to light mode and select a striped row before hovering over the row above or below it.

Backporting

This change should be backported to:

  • 3.0
  • 3.1
  • 4.0
  • [x ] develop

Checklist

We encourage keeping the code coverage percentage at 80% or above.

  • ✅ This solution meets the acceptance criteria of the related issue.
  • 📝 The related issue checklist is completed.
  • 🧪 This PR includes unit tests for the developed code.
    If not, explain why:
    Would still like to make additional changes
  • 🔄 End-to-End tests have been added or updated.
    If not, explain why:
    Would still like to make additional changes
  • 📚 The documentation has been updated, or a dedicated issue has been created.
    If not, explain why:
    Would still like to make additional changes
  • 📌 The release notes have been updated.
    If not, explain why:
    Would still like to make additional changes

Pipfile Outdated
Copy link
Member

Choose a reason for hiding this comment

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

please don't modify building configuration

Copy link
Member

Choose a reason for hiding this comment

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

a new example file should follow the same structure as the other ones (comments, run parameters ...)

with tgb.Page() as page:
tgb.toggle(theme=True)

tgb.table("{data}", selected="{selected}", on_action=num_on_action)
Copy link
Member

Choose a reason for hiding this comment

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

is this needed ?


tgb.table("{data}", selected="{selected}", on_action=num_on_action)

tgb.table("{data}", selected="{selected}", on_action=num_on_action, class_name="rows-similar rows-bordered")
Copy link
Member

Choose a reason for hiding this comment

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

default behavior should be the same as before so we don't have breaking changes ?

@@ -73,3 +73,8 @@
background: var(--color-background);
opacity: var(--table-stripe-opacity, 0.5);
}

/* Override stripe opacity when row is selected */
.taipy-table:where(:not(.rows-similar)) tbody tr.selected:nth-child(odd)::after {
Copy link
Member

Choose a reason for hiding this comment

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

default behavior should be the same as before so we don't have breaking changes ?

taipy.sqlite3.db Outdated
Copy link
Member

Choose a reason for hiding this comment

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

no need to commit this

Copy link
Contributor

This PR has been labelled as "🥶Waiting for contributor" because it has been inactive for more than 14 days. If you would like to continue working on this PR, then please add new commit or another comment, otherwise this PR will be closed in 14 days. For more information please refer to the contributing guidelines.

@github-actions github-actions bot added the 🥶Waiting for contributor Issues or PRs waiting for a long time label Jun 18, 2025
@github-actions github-actions bot removed the 🥶Waiting for contributor Issues or PRs waiting for a long time label Jun 19, 2025
Copy link
Contributor

github-actions bot commented Jul 3, 2025

This PR has been labelled as "🥶Waiting for contributor" because it has been inactive for more than 14 days. If you would like to continue working on this PR, then please add new commit or another comment, otherwise this PR will be closed in 14 days. For more information please refer to the contributing guidelines.

@github-actions github-actions bot added the 🥶Waiting for contributor Issues or PRs waiting for a long time label Jul 3, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
GUI UX 🖰 GUI Related to GUI 📈 Improvement Improvement of a feature. 🥶Waiting for contributor Issues or PRs waiting for a long time
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants