Skip to content

feat: Restore debug tools in Settings page with conditional compilation#1539

Draft
Copilot wants to merge 12 commits intomainfrom
copilot/add-version-number-settings-popup-again
Draft

feat: Restore debug tools in Settings page with conditional compilation#1539
Copilot wants to merge 12 commits intomainfrom
copilot/add-version-number-settings-popup-again

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Jan 28, 2026

GitHub Issue (If applicable): #

PR Type

  • Feature

What is the current behavior?

Settings page replaced the debug panel overlay, losing access to visual tree inspection and visual state testing tools previously available via the Settings button.

What is the new behavior?

Debug tools integrated into Settings page, visible only in DEBUG builds via conditional compilation:

SettingsPage.xaml

  • Added "Debug Tools" section with x:Load="False", materialized only in DEBUG via FindName()
  • Two buttons: "Copy Visual Tree" (clipboard/console output) and "Test Visual State" (NavigationView state transitions)

SettingsPage.xaml.cs

  • SetShell(Shell) method receives Shell reference from App
  • Click handlers delegate to Shell methods, wrapped in #if DEBUG

Shell.xaml.cs

  • Public DebugCopyVisualTree() and DebugTestVisualState() expose existing private debug methods

App.xaml.Navigation.cs

  • Passes Shell reference to SettingsPage on instantiation

Zero impact on RELEASE builds—section never loads, handlers not compiled.

PR Checklist

Other information

Debug tools now more discoverable than previous overlay panel approach. Same functionality, better organization.

Internal Issue (If applicable):

Original prompt

This section details on the original issue you should resolve

<issue_title>Include a version number in the settings popup</issue_title>
<issue_description>The samples app in this repo should be showing its build version in the settings popup from the navigationview.</issue_description>

Comments on the Issue (you are @copilot in this section)


💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.

@CLAassistant
Copy link
Copy Markdown

CLAassistant commented Jan 28, 2026

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you all sign our Contributor License Agreement before we can accept your contribution.
2 out of 3 committers have signed the CLA.

✅ Xiaoy312
✅ jeromelaban
❌ Copilot
You have signed the CLA already but the status is still pending? Let us recheck it.

@github-actions
Copy link
Copy Markdown

Azure Static Web Apps: Your stage site is ready! Visit it here: https://polite-field-01aa64f0f-1539.eastus2.azurestaticapps.net

Copilot AI and others added 3 commits January 28, 2026 19:22
Co-authored-by: jeromelaban <5839577+jeromelaban@users.noreply.github.com>
Co-authored-by: jeromelaban <5839577+jeromelaban@users.noreply.github.com>
Co-authored-by: jeromelaban <5839577+jeromelaban@users.noreply.github.com>
Copilot AI changed the title [WIP] Include version number in settings popup feat: Add Settings page with application version and platform information Jan 28, 2026
Copilot stopped work on behalf of jeromelaban due to an error January 28, 2026 19:53
Co-authored-by: jeromelaban <5839577+jeromelaban@users.noreply.github.com>
Copilot AI changed the title feat: Add Settings page with application version and platform information feat: Add Settings page with version and platform information Jan 28, 2026
@jeromelaban jeromelaban marked this pull request as ready for review January 28, 2026 21:33
Copilot AI review requested due to automatic review settings January 28, 2026 21:33
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR adds a Settings page to the Uno Toolkit Samples app that displays application metadata including version, framework, and platform information. The previous behavior (activating a debug panel) has been replaced with a user-facing settings page.

Changes:

  • Adds SettingsPage.xaml/cs with responsive layout displaying app metadata, version information, platform detection, and documentation links
  • Updates navigation logic in App.xaml.Navigation.cs to instantiate and cache the SettingsPage
  • Modifies build configuration to support Skia renderer conditionally through UnoFeatures
  • Updates CI/CD scripts to use native renderer for UI tests and adds build pipeline infrastructure improvements

Reviewed changes

Copilot reviewed 8 out of 8 changed files in this pull request and generated 8 comments.

Show a summary per file
File Description
samples/Uno.Toolkit.Samples/Uno.Toolkit.Samples/Content/SettingsPage.xaml New XAML file defining the Settings page UI with version, framework, platform info and documentation links
samples/Uno.Toolkit.Samples/Uno.Toolkit.Samples/Content/SettingsPage.xaml.cs Code-behind implementing platform detection using compile-time directives and runtime detection for Skia builds
samples/Uno.Toolkit.Samples/Uno.Toolkit.Samples/App.xaml.Navigation.cs Removed duplicate using statement and updated navigation to display cached SettingsPage instead of debug panel
samples/Uno.Toolkit.Samples/Uno.Toolkit.Samples/Uno.Toolkit.Samples.csproj Added crosstargeting override import and conditional SkiaRenderer feature configuration
build/workflow/scripts/wasm-uitest-run.sh Added UseNativeRenderer property to WASM UI test build
build/workflow/scripts/ios-uitest-build.sh Added UseNativeRenderer property to iOS UI test build
build/workflow/scripts/android-uitest-build.sh Added UseNativeRenderer property to Android UI test build
build/workflow/copilot/restore-solution.sh Added crosstargeting override file generation, workload installation, and dev server preloading

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@jeromelaban jeromelaban force-pushed the copilot/add-version-number-settings-popup-again branch from 988a866 to e2380e6 Compare January 28, 2026 21:45
@github-actions
Copy link
Copy Markdown

Azure Static Web Apps: Your stage site is ready! Visit it here: https://polite-field-01aa64f0f-1539.eastus2.azurestaticapps.net

Co-authored-by: jeromelaban <5839577+jeromelaban@users.noreply.github.com>
Copilot AI changed the title feat: Add Settings page with version and platform information feat: Restore debug tools in Settings page with conditional compilation Jan 28, 2026
@github-actions
Copy link
Copy Markdown

Azure Static Web Apps: Your stage site is ready! Visit it here: https://polite-field-01aa64f0f-1539.eastus2.azurestaticapps.net

@unodevops
Copy link
Copy Markdown
Contributor

⚠️⚠️ The build 193519 has failed on Uno Toolkit - CI.

set -euo pipefail

# Create a desktop-only crosstargeting override for build pipelines
cat > "src/crosstargeting_override.props" << 'EOF'
Copy link
Copy Markdown
Contributor

@agneszitte agneszitte Jan 28, 2026

Choose a reason for hiding this comment

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

This file writes src/crosstargeting_override.props and the samples csproj auto-imports it if present. That can affect local builds after the script runs. Maybe consider scoping/cleanup or env-gated import no ?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

This is a workaround until the devserver fixes a few things, it probably won't get merged as-is.

}
#endif

private void OnNavigationItemInvoked(MUXC.NavigationView sender, MUXC.NavigationViewItemInvokedEventArgs e)
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

When Settings is invoked, any active nested sample overlay remains visible. Should we call ExitNestedSample() before swapping NavigationView.Content to settings?

Copy link
Copy Markdown
Contributor

@Xiaoy312 Xiaoy312 Feb 2, 2026

Choose a reason for hiding this comment

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

good concern but no need,
"nested" navigation are shown full screen blocking the navigation-view completely, no way to click settings while in "nested" page

@jeromelaban jeromelaban marked this pull request as draft January 29, 2026 17:31
@Xiaoy312 Xiaoy312 self-assigned this Feb 2, 2026
@github-actions
Copy link
Copy Markdown

github-actions bot commented Feb 2, 2026

Azure Static Web Apps: Your stage site is ready! Visit it here: https://polite-field-01aa64f0f-1539.eastus2.azurestaticapps.net

@unodevops
Copy link
Copy Markdown
Contributor

⚠️⚠️ The build 194226 has failed on Uno Toolkit - CI.

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.

Include a version number in the settings popup

7 participants