Skip to content
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

ListDetailsView now uses the Two-Pane View #4197

Merged
merged 4 commits into from
Aug 30, 2021
Merged

ListDetailsView now uses the Two-Pane View #4197

merged 4 commits into from
Aug 30, 2021

Conversation

COM8
Copy link
Contributor

@COM8 COM8 commented Aug 27, 2021

PR Type

What kind of change does this PR introduce?

  • Feature
  • Refactoring

What is the current behavior?

The ListDetailsView does not take advantage of multiple screens and is not spanning aware.

What is the new behavior?

The new and refactored ListDetailsView control is aware of multiple screens.
We archive this by replacing the current grid-based layout with the new Two-pane view based layout.

Additional changes

  • I added additional properties: DetailsPaneBackground, DetailsContentTemplateSelector, ListPaneEmptyContent, ListPaneEmptyContentTemplate and ListPaneItemTemplateSelector.

PR Checklist

Please check if your PR fulfills the following requirements:

  • Tested code with current supported SDKs
  • Pull Request has been submitted to the documentation repository instructions. Link: #559
  • Sample in sample app has been added / updated (for bug fixes / features)
  • New major technical changes in the toolkit have or will be added to the Wiki e.g. build changes, source generators, testing infrastructure, sample creation changes, etc...
  • Tests for the changes have been added (for bug fixes / features) (if applicable)
  • Header has been added to all new source files (run build/UpdateHeaders.bat)
  • Contains NO breaking changes

Other information

Old behavior

Old Toolkit

New behavior

New Toolkit

@ghost
Copy link

ghost commented Aug 27, 2021

Thanks COM8 for opening a Pull Request! The reviewers will test the PR and highlight if there is any conflict or changes required. If the PR is approved we will proceed to merge the pull request 🙌

@ghost ghost requested review from michael-hawker, azchohfi and Rosuavio August 27, 2021 14:04
@michael-hawker michael-hawker added this to the 7.1 milestone Aug 27, 2021
@michael-hawker michael-hawker added controls 🎛️ improvements ✨ next preview ✈️ Label for marking what we want to include in the next preview release for developers to try. labels Aug 27, 2021
Copy link
Member

@michael-hawker michael-hawker left a comment

Choose a reason for hiding this comment

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

We should update the names of a few of the properties and parts.

}
else if (previousState == ListDetailsViewState.Details)
{
if ((BackButtonBehavior == BackButtonBehavior.Inline) && (_inlineBackButton != null))
Copy link
Contributor

Choose a reason for hiding this comment

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

Same as above, extra parentheses

@ghost
Copy link

ghost commented Aug 28, 2021

This PR has been marked as "needs attention 👋" and awaiting a response from the team.

@michael-hawker
Copy link
Member

Looking good to me! Think only thing missing (which may have been from the WinUI 2.6 transition) is that there's no visual edge between the two sides, like in the previous we had a line:

image

We may just want a different coloring or something on one side? Not sure what the best practice would be here. We can fix this outside this PR though and open an issue.

@ghost ghost removed the needs attention 👋 label Aug 30, 2021
@michael-hawker michael-hawker merged commit 10e7668 into CommunityToolkit:main Aug 30, 2021
@michael-hawker
Copy link
Member

Thanks @COM8 for these improvements! Sorry it took so long for us to move forward on them, but appreciate you working with us on getting everything together to be integrated. 🎉🎉🎉

@COM8
Copy link
Contributor Author

COM8 commented Aug 31, 2021

Cool!
In case people have feature requests or find bugs regarding this control, just let me know and I will work on them 😁.

We may just want a different coloring or something on one side? Not sure what the best practice would be here. We can fix this outside this PR though and open an issue.

Yes, I'm aware of that and I'm having a look at it right now.
If we want something more Windows 10 like, we can go with different colors.
image

Or rounded edges, so we are ready for Windows 11 :)
image

@michael-hawker
Copy link
Member

@JustinXinLiu any comments on styling choices? I think aligning more with the 2.6 WinUI updates to NavigationView would make sense, eh?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
controls 🎛️ improvements ✨ next preview ✈️ Label for marking what we want to include in the next preview release for developers to try.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants