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

Update AttachedShadow example and future doc links #4260

Merged
merged 3 commits into from
Sep 21, 2021
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,10 @@
<Image ui:Effects.Shadow="{StaticResource CommonShadow}"
Height="100" Width="100"
Source="ms-appx:///Assets/Photos/Owl.jpg"/>
<!-- The AttachedDropShadow supports masking of text! -->
<TextBlock ui:Effects.Shadow="{StaticResource CommonShadow}"
Text="This is some text with a Shadow!"
HorizontalAlignment="Center"/>
<!-- You can still apply a Shadow directly and even use binding with it to manipulate at runtime! -->
<Rectangle RadiusX="32" RadiusY="32"
Height="100" Width="100"
Expand All @@ -41,8 +45,10 @@
<ImageBrush ImageSource="ms-appx:///Assets/Photos/Owl.jpg"/>
</Rectangle.Fill>
<ui:Effects.Shadow>
<!-- If doing a rectangular/rounded shadow, set IsMasked to False for better performance -->
michael-hawker marked this conversation as resolved.
Show resolved Hide resolved
<ui:AttachedDropShadow BlurRadius="@[BlurRadius:DoubleSlider:8.0:0.0-10.0]"
CornerRadius="32"
IsMasked="False"
Color="@[Color:Brush:Black]"
Offset="@[Offset:Vector3:4,4]"
Opacity="@[Opacity:DoubleSlider:1.0:0.0-1.0]"
Expand Down
6 changes: 3 additions & 3 deletions Microsoft.Toolkit.Uwp.SampleApp/SamplePages/samples.json
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@
"CodeUrl": "https://github.com/CommunityToolkit/WindowsCommunityToolkit/tree/main/Microsoft.Toolkit.Uwp.UI/Shadows",
"XamlCodeFile": "/SamplePages/Shadows/AttachedShadowCompositionXaml.bind",
"Icon": "/SamplePages/Shadows/DropShadowPanel.png",
"DocumentationUrl": "https://raw.githubusercontent.com/MicrosoftDocs/WindowsCommunityToolkitDocs/master/docs/controls/DropShadowPanel.md"
"DocumentationUrl": "https://raw.githubusercontent.com/MicrosoftDocs/WindowsCommunityToolkitDocs/master/docs/helpers/AttachedShadows.md"
},
{
"Name": "AttachedCardShadow (Win2D)",
Expand All @@ -202,7 +202,7 @@
"CodeUrl": "https://github.com/CommunityToolkit/WindowsCommunityToolkit/tree/main/Microsoft.Toolkit.Uwp.UI.Media/Shadows",
"XamlCodeFile": "/SamplePages/Shadows/AttachedShadowWin2DXaml.bind",
"Icon": "/SamplePages/Shadows/DropShadowPanel.png",
"DocumentationUrl": "https://raw.githubusercontent.com/MicrosoftDocs/WindowsCommunityToolkitDocs/master/docs/controls/DropShadowPanel.md",
"DocumentationUrl": "https://raw.githubusercontent.com/MicrosoftDocs/WindowsCommunityToolkitDocs/master/docs/helpers/AttachedShadows.md",
"BadgeUpdateVersionRequired": "May 2019 update required",
"ApiCheck": "Windows.UI.Composition.CompositionVisualSurface"
},
Expand Down Expand Up @@ -670,7 +670,7 @@
"CodeUrl": "https://github.com/CommunityToolkit/WindowsCommunityToolkit/tree/main/Microsoft.Toolkit.Uwp.UI.Animations/Xaml/Shadows",
"XamlCodeFile": "/SamplePages/Animations/Shadows/AnimatedCardShadowXaml.bind",
"Icon": "/SamplePages/Shadows/DropShadowPanel.png",
"DocumentationUrl": "https://raw.githubusercontent.com/MicrosoftDocs/WindowsCommunityToolkitDocs/master/docs/animations/ConnectedAnimations.md"
"DocumentationUrl": "https://raw.githubusercontent.com/MicrosoftDocs/WindowsCommunityToolkitDocs/master/docs/helpers/AttachedShadows.md"
}
]
},
Expand Down