Skip to content

Conversation

@AndrewKeepCoding
Copy link
Contributor

Fixes

Fixes #726

PR Type

What kind of change does this PR introduce?

  • Bugfix

What is the current behavior?

With the DefaultSegmentedStyle, SegmentedItem is not rendered when its visibility is Collapsed by default then toggled to Visible.

What is the new behavior?

SegmentedItems are rendered when toggled to Visible.

PR Checklist

Please check if your PR fulfills the following requirements:

  • Created a feature/dev branch in your fork (vs. submitting directly from a commit on main)
  • Based off latest main branch of toolkit
  • Tested code with current supported SDKs
  • Contains NO breaking changes

Other information

{
// If the parent is a Segmented control with an EqualPanel,
// we need to invalidate measure to update the layout.
if ((this.Parent as Segmented)?.ItemsPanelRoot is EqualPanel panel)
Copy link
Member

Choose a reason for hiding this comment

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

Could it just be any panel still? I can't imagine this issue would be unique to just the Equal Panel? Also, if we just invalidate our own measure, shouldn't that re-trigger the parent panel anyway?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Segmented] SegmentedItem stays hidden when visibility changes

2 participants