-
Notifications
You must be signed in to change notification settings - Fork 132
HeaderedControls #109
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
Merged
Merged
HeaderedControls #109
Changes from all commits
Commits
Show all changes
13 commits
Select commit
Hold shift + click to select a range
4778f2a
Init
niels9001 d880a88
Remove other files
niels9001 267ce9f
Adding TreeView sample
niels9001 18f3a48
XAML styler
niels9001 b320b60
Adding TreeView icon
niels9001 74c2d71
XAML styler
niels9001 b3c08cc
Some more XAML styling
niels9001 d551bdb
Addressing feedback
niels9001 9815567
XAML styler
niels9001 e5068c3
xaml styler
niels9001 4196eef
Fix for mismatch in WUX/MUXC TreeViewItem type in Sample
michael-hawker 0ef6882
Fix test, sample
niels9001 d3a452e
Include Controls in PackageId
Arlodotexe File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
75 changes: 0 additions & 75 deletions
75
components/HeaderedContentControl/samples/HeaderedContentControl.md
This file was deleted.
Oops, something went wrong.
13 changes: 0 additions & 13 deletions
13
components/HeaderedContentControl/src/AdditionalAssemblyInfo.cs
This file was deleted.
Oops, something went wrong.
17 changes: 0 additions & 17 deletions
17
.../HeaderedContentControl/src/CommunityToolkit.WinUI.Controls.HeaderedContentControl.csproj
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
11 changes: 0 additions & 11 deletions
11
components/HeaderedContentControl/tests/HeaderedContentControl.Tests.projitems
This file was deleted.
Oops, something went wrong.
13 changes: 0 additions & 13 deletions
13
components/HeaderedContentControl/tests/HeaderedContentControl.Tests.shproj
This file was deleted.
Oops, something went wrong.
File renamed without changes.
File renamed without changes
File renamed without changes
File renamed without changes
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
File renamed without changes
File renamed without changes.
37 changes: 37 additions & 0 deletions
37
components/HeaderedControls/samples/HeaderedContentControl.md
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,37 @@ | ||
| --- | ||
| title: HeaderedContentControl | ||
| author: skendrot | ||
| description: The HeaderedContentControl allows content to be displayed with a specified header. | ||
| keywords: HeaderedContentControl, Control, headered | ||
| dev_langs: | ||
| - csharp | ||
| category: Controls | ||
| subcategory: Layout | ||
| discussion-id: 0 | ||
| issue-id: 0 | ||
| icon: Assets/HeaderedContentControl.png | ||
| --- | ||
|
|
||
| The `Header` property can be any object and you can use the `HeaderTemplate` to specify a custom look to the header. Content for the HeaderedContentControl will align to the top left. This is to maintain the same functionality as the ContentControl. | ||
|
|
||
| > [!NOTE] | ||
| > Setting the `Background`, `BorderBrush` and `BorderThickness` properties will not have any effect on the HeaderedContentControl. This is to maintain the same functionality as the ContentControl. | ||
|
|
||
| > [!Sample HeaderedContentControlSample] | ||
|
|
||
| > [!Sample HeaderedContentControlTextSample] | ||
|
|
||
| > [!Sample HeaderedContentControlImageSample] | ||
|
|
||
| > [!Sample HeaderedContentControlComplexSample] | ||
|
|
||
| ## Syntax | ||
|
|
||
| ```xaml | ||
| <Page ... | ||
| xmlns:controls="using:CommunityToolkit.WinUI.Controls"/> | ||
|
|
||
| <controls:HeaderedContentControl> | ||
| <!-- Header content or HeaderTemplate content --> | ||
| </controls:HeaderedContentControl> | ||
| ``` |
2 changes: 1 addition & 1 deletion
2
.../HeaderedContentControlComplexSample.xaml → .../HeaderedContentControlComplexSample.xaml
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
File renamed without changes.
2 changes: 1 addition & 1 deletion
2
...es/HeaderedContentControlImageSample.xaml → ...es/HeaderedContentControlImageSample.xaml
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
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion
2
...les/HeaderedContentControl.Samples.csproj → ...s/samples/HeaderedControls.Samples.csproj
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
30 changes: 30 additions & 0 deletions
30
components/HeaderedControls/samples/HeaderedItemsControl.md
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,30 @@ | ||
| --- | ||
| title: HeaderedItemsControl | ||
| author: skendrot | ||
| description: The HeaderedItemsControl allows items to be displayed with a specified header. | ||
| keywords: HeaderedItemsControl, Control, Layout | ||
| dev_langs: | ||
| - csharp | ||
| category: Controls | ||
| subcategory: Layout | ||
| discussion-id: 0 | ||
| issue-id: 0 | ||
| icon: Assets/HeaderedItemsControl.png | ||
| --- | ||
| The `Header` property can be any object and you can use the `HeaderTemplate` to specify a custom look to the header. Similiar objects can be set for the `Footer` and `FooterTemplate`. | ||
|
|
||
| > [!NOTE] | ||
| > Setting the `Background`, `BorderBrush` and `BorderThickness` properties will not have any effect on the HeaderedItemsControl. This is to maintain the same functionality as the ItemsControl. | ||
|
|
||
| > [!Sample HeaderedItemsControlSample] | ||
|
|
||
| ## Syntax | ||
|
|
||
| ```xaml | ||
| <Page ... | ||
| xmlns:controls="using:CommunityToolkit.WinUI.Controls"/> | ||
|
|
||
| <controls:HeaderedItemsControl> | ||
| <!-- Header content or HeaderTemplate content --> | ||
| </controls:HeaderedItemsControl> | ||
| ``` |
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
File renamed without changes.
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,28 @@ | ||
| --- | ||
| title: HeaderedTreeView | ||
| author: michaelhawker | ||
| description: The HeaderedTreeView allows a treeview to be displayed with a specified header. | ||
| keywords: HeaderedTreeView, Control, Layout, treeview | ||
| dev_langs: | ||
| - csharp | ||
| category: Controls | ||
| subcategory: Layout | ||
| discussion-id: 0 | ||
| issue-id: 0 | ||
| icon: Assets/HeaderedTreeView.png | ||
| --- | ||
| The `Header` property can be any object and you can use the `HeaderTemplate` to specify a custom look to the header. Similiar objects can be set for the `Footer` and `FooterTemplate`. | ||
|
|
||
|
|
||
| > [!Sample HeaderedTreeViewSample] | ||
|
|
||
| ## Syntax | ||
|
|
||
| ```xaml | ||
| <Page ... | ||
| xmlns:controls="using:CommunityToolkit.WinUI.Controls"/> | ||
|
|
||
| <controls:HeaderedTreeView> | ||
| <!-- Header content or HeaderTemplate content --> | ||
| </controls:HeaderedTreeView> | ||
| ``` |
37 changes: 37 additions & 0 deletions
37
components/HeaderedControls/samples/HeaderedTreeViewSample.xaml
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,37 @@ | ||
| <!-- Licensed to the .NET Foundation under one or more agreements. The .NET Foundation licenses this file to you under the MIT license. See the LICENSE file in the project root for more information. --> | ||
| <Page x:Class="HeaderedItemsControlExperiment.Samples.HeaderedTreeViewSample" | ||
| xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" | ||
| xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" | ||
| xmlns:controls="using:CommunityToolkit.WinUI.Controls" | ||
| xmlns:d="http://schemas.microsoft.com/expression/blend/2008" | ||
| xmlns:local="using:HeaderedItemsControlExperiment.Samples" | ||
| xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" | ||
| xmlns:muxc="using:Microsoft.UI.Xaml.Controls" | ||
| mc:Ignorable="d"> | ||
|
|
||
| <Grid> | ||
| <controls:HeaderedTreeView Footer="Footer" | ||
| Header="Header" | ||
| ItemsSource="{x:Bind Items, Mode=OneWay}"> | ||
| <controls:HeaderedTreeView.HeaderTemplate> | ||
| <DataTemplate> | ||
| <TextBlock FontWeight="SemiBold" | ||
| Text="{Binding}" /> | ||
| </DataTemplate> | ||
| </controls:HeaderedTreeView.HeaderTemplate> | ||
| <controls:HeaderedTreeView.FooterTemplate> | ||
| <DataTemplate> | ||
| <TextBlock FontWeight="SemiBold" | ||
| Text="{Binding}" /> | ||
| </DataTemplate> | ||
| </controls:HeaderedTreeView.FooterTemplate> | ||
| <controls:HeaderedTreeView.ItemTemplate> | ||
| <DataTemplate x:DataType="local:ExplorerItem"> | ||
| <muxc:TreeViewItem Content="{x:Bind Name}" | ||
| IsExpanded="True" | ||
| ItemsSource="{x:Bind Children}" /> | ||
| </DataTemplate> | ||
| </controls:HeaderedTreeView.ItemTemplate> | ||
| </controls:HeaderedTreeView> | ||
| </Grid> | ||
| </Page> |
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.