From e73c8311672b31c137a7421d222875105b742f4a Mon Sep 17 00:00:00 2001 From: Qiutong Shen Date: Mon, 11 May 2026 16:48:12 +0800 Subject: [PATCH 1/3] fix(develop): duplicate blocks and mislabeled snippets Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- hub/apps/develop/feeds/implement-feed-provider-win32.md | 2 +- hub/apps/develop/security/use-cases.md | 4 ++-- hub/apps/develop/ui/controls/commanding.md | 8 -------- 3 files changed, 3 insertions(+), 11 deletions(-) diff --git a/hub/apps/develop/feeds/implement-feed-provider-win32.md b/hub/apps/develop/feeds/implement-feed-provider-win32.md index a4aef2db82..ca71fe4304 100644 --- a/hub/apps/develop/feeds/implement-feed-provider-win32.md +++ b/hub/apps/develop/feeds/implement-feed-provider-win32.md @@ -137,7 +137,7 @@ namespace winrt The **OnFeedProviderEnabled** method is invoked when a feed associated with the provider is created by the Widgets Board host. In the implementation of this method, generate a query string with the parameters that will be passed to the URL that provides the feed content, including any necessary authentication tokens. Create an instance of **CustomQueryParametersUpdateOptions**, passing in the **FeedProviderDefinitionId** from the event args that identifies the feed that has been enabled and the query string. Get the default **FeedManager** and call **SetCustomQueryParameters** to register the query string parameters with the Widgets Board. -```csharp +```cpp // FeedProvider.cs void FeedProvider::OnFeedProviderEnabled(winrt::Microsoft::Windows::Widgets::Feeds::Providers::FeedProviderEnabledArgs args) { diff --git a/hub/apps/develop/security/use-cases.md b/hub/apps/develop/security/use-cases.md index 514613b9e0..2af70571ef 100644 --- a/hub/apps/develop/security/use-cases.md +++ b/hub/apps/develop/security/use-cases.md @@ -242,10 +242,10 @@ navigator.credentials.get({ rpId: ..., allowCredentials: [{ type: "public-key", - id: new UInt8Array([21, 31, 56, ...]).buffer, + id: new Uint8Array([21, 31, 56, ...]).buffer, }, { type: "public-key", - id: new UInt8Array([21, 31, 56, ...]).buffer, + id: new Uint8Array([21, 31, 56, ...]).buffer, }, { ... }], diff --git a/hub/apps/develop/ui/controls/commanding.md b/hub/apps/develop/ui/controls/commanding.md index cbcb222447..3727281966 100644 --- a/hub/apps/develop/ui/controls/commanding.md +++ b/hub/apps/develop/ui/controls/commanding.md @@ -369,9 +369,6 @@ If you need to create a command that isn't defined by the [StandardUICommand](/w *XamlUICommandSample* -| Download the code for this example | -| -------------------- | -| [WinUI commanding sample (XamlUICommand)](https://github.com/MicrosoftDocs/windows-topic-specific-samples/archive/uwp-commanding-xamluicommand.zip) | | Download the code for this example | | -------------------- | | [Commanding sample (XamlUICommand)](https://github.com/MicrosoftDocs/windows-topic-specific-samples/archive/uwp-commanding-xamluicommand.zip) | @@ -622,10 +619,6 @@ Standard WinUI controls (button, list, selection, calendar, predictive text) pro In this basic example, we demonstrate how a single command can be invoked with a button click, a keyboard accelerator, and rotating a mouse wheel. -| Download the code for this example | -| -------------------- | -| [Commanding sample (ICommand)](https://github.com/MicrosoftDocs/windows-topic-specific-samples/archive/uwp-commanding-icommand.zip) | - ```xaml Date: Mon, 11 May 2026 16:58:21 +0800 Subject: [PATCH 2/3] fix(develop): duplicate blocks and mislabeled snippets Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- .../feeds/implement-feed-provider-win32.md | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/hub/apps/develop/feeds/implement-feed-provider-win32.md b/hub/apps/develop/feeds/implement-feed-provider-win32.md index ca71fe4304..ecde14348f 100644 --- a/hub/apps/develop/feeds/implement-feed-provider-win32.md +++ b/hub/apps/develop/feeds/implement-feed-provider-win32.md @@ -138,7 +138,7 @@ namespace winrt The **OnFeedProviderEnabled** method is invoked when a feed associated with the provider is created by the Widgets Board host. In the implementation of this method, generate a query string with the parameters that will be passed to the URL that provides the feed content, including any necessary authentication tokens. Create an instance of **CustomQueryParametersUpdateOptions**, passing in the **FeedProviderDefinitionId** from the event args that identifies the feed that has been enabled and the query string. Get the default **FeedManager** and call **SetCustomQueryParameters** to register the query string parameters with the Widgets Board. ```cpp -// FeedProvider.cs +// FeedProvider.cpp void FeedProvider::OnFeedProviderEnabled(winrt::Microsoft::Windows::Widgets::Feeds::Providers::FeedProviderEnabledArgs args) { std::wstringstream wstringstream; @@ -155,8 +155,8 @@ wstringstream << args.FeedProviderDefinitionId().c_str() << L" feed provider was **OnFeedProviderDisabled** is called when the Widgets Board when all of the feeds for this provider have been disabled. Feed providers are not required to perform any actions in response to these this method call. The method invocation can be used for telemetry purposes or to update the query string parameters or revoke authentication tokens, if needed. If the app only supports a single feed provider or if all feed providers supported by the app have been disabled, then the app can exit in response to this callback. -```csharp -// FeedProvider.cs +```cpp +// FeedProvider.cpp void FeedProvider::OnFeedProviderDisabled(winrt::Microsoft::Windows::Widgets::Feeds::Providers::FeedProviderDisabledArgs args) { @@ -170,8 +170,8 @@ void FeedProvider::OnFeedProviderDisabled(winrt::Microsoft::Windows::Widgets::Fe **OnFeedEnabled** and **OnFeedDisabled** are invoked by the Widgets Board when a feed is enabled or disabled. Feed providers are not required to perform any actions in response to these method calls. The method invocation can be used for telemetry purposes or to update the query string parameters or revoke authentication tokens, if needed. -```csharp -// FeedProvider.cs +```cpp +// FeedProvider.cpp void FeedProvider::OnFeedEnabled(winrt::Microsoft::Windows::Widgets::Feeds::Providers::FeedEnabledArgs args) { @@ -181,8 +181,8 @@ void FeedProvider::OnFeedEnabled(winrt::Microsoft::Windows::Widgets::Feeds::Prov } ``` -```csharp -// FeedProvider.cs +```cpp +// FeedProvider.cpp void FeedProvider::OnFeedDisabled(winrt::Microsoft::Windows::Widgets::Feeds::Providers::FeedDisabledArgs args) { @@ -196,8 +196,8 @@ void FeedProvider::OnFeedDisabled(winrt::Microsoft::Windows::Widgets::Feeds::Pro **OnCustomQueryParametersRequested** is raised when the Widgets Board determines that the custom query parameters associated with the feed provider need to be refreshed. For example, this method may be raised if the operation to fetch feed content from the remote web service fails. The **FeedProviderDefinitionId** property of the **CustomQueryParametersRequestedArgs** passed into this method specifies the feed for which query string params are being requested. The provider should regenerate the query string and pass it back to the Widgets Board by calling **SetCustomQueryParameters**. -```csharp -// FeedProvider.cs +```cpp +// FeedProvider.cpp void FeedProvider::OnCustomQueryParametersRequested(winrt::Microsoft::Windows::Widgets::Feeds::Providers::CustomQueryParametersRequestedArgs args) { From 098ac8eb47591aeedd3d593d4b23cb2cb9702366 Mon Sep 17 00:00:00 2001 From: Qiutong Shen Date: Tue, 12 May 2026 10:46:17 +0800 Subject: [PATCH 3/3] fix(develop): remove duplicate paragraph in ICommand section Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- hub/apps/develop/ui/controls/commanding.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hub/apps/develop/ui/controls/commanding.md b/hub/apps/develop/ui/controls/commanding.md index 3727281966..0ee020f6dd 100644 --- a/hub/apps/develop/ui/controls/commanding.md +++ b/hub/apps/develop/ui/controls/commanding.md @@ -606,7 +606,7 @@ The most basic way to support a structured commanding experience is to define an > [!NOTE] > In some cases, it might be just as efficient to bind a method to the Click event and a property to the IsEnabled property. -Standard WinUI controls (button, list, selection, calendar, predictive text) provide the basis for many common command experiences. For a complete list of control types, see [Controls and patterns for Windows apps](../../../design/controls/index.md). + #### Example ![Command interface example](images/commanding/icommand.gif)