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

fix: Uno Platform - Avoid square border around RangeSelector Thumbs #400

Merged

Conversation

MartinZikmund
Copy link
Contributor

@MartinZikmund MartinZikmund commented Apr 12, 2024

Fixes #386

PR Type

What kind of change does this PR introduce?

  • Bugfix

What is the current behavior?

There is a square around Thumbs

What is the new behavior?

No square around thumbs, This workaround is for unoplatform/uno#6457

PR Checklist

Please check if your PR fulfills the following requirements:

  • Created a feature/dev branch in your fork (vs. submitting directly from a commit on main)
  • Based off latest main branch of toolkit
  • Tested code with current supported SDKs
  • New component
    • Documentation has been added
    • Sample in sample app has been added
    • Analyzers are passing for documentation and samples
    • Icon has been created (if new sample) following the Thumbnail Style Guide and templates
  • Tests for the changes have been added (if applicable)
  • Header has been added to all new source files
  • Contains NO breaking changes

Other information

@michael-hawker
Copy link
Member

Thanks @MartinZikmund, guess we don't expect the Uno issue to get resolved in the near-term? I saw you applied a similar fix to the ColorPicker control for Uno, don't think our revamped ColorPicker in the toolkit we added was effected by this, eh @Arlodotexe?

@MartinZikmund
Copy link
Contributor Author

@michael-hawker indeed, especially on WASM it is pretty tricky... ColorPicker was not affected as it does not use the linear gradient

@Arlodotexe
Copy link
Member

Thanks @MartinZikmund, looks like there's an error here:

2024-04-24T02:02:26.1277663Z        "C:\a\Windows\Windows\components\RangeSelector\src\CommunityToolkit.WinUI.Controls.RangeSelector.csproj" (default target) (34:39) ->
2024-04-24T02:02:26.1278246Z        "C:\a\Windows\Windows\components\RangeSelector\src\CommunityToolkit.WinUI.Controls.RangeSelector.csproj" (Build target) (34:45) ->
2024-04-24T02:02:26.1278408Z        (MarkupCompilePass1 target) -> 
2024-04-24T02:02:26.1279940Z          C:\a\Windows\Windows\components\RangeSelector\src\RangeSelector.xaml(33,34): XamlCompiler error WMC0001: Unknown type 'Setter' in XML namespace 'http://uno.ui/not_win' [C:\a\Windows\Windows\components\RangeSelector\src\CommunityToolkit.WinUI.Controls.RangeSelector.csproj::TargetFramework=uap10.0.17763]

@MartinZikmund
Copy link
Contributor Author

@Arlodotexe forgot the mc:Ignorable, please retry, should help

@MartinZikmund
Copy link
Contributor Author

MartinZikmund commented Apr 28, 2024

@Arlodotexe and once more for styling, hopefully will work out this time 😅

Wanted to verify with the sample app, but getting:

1>D:\Work\CommunityToolkitWindows\tooling\ProjectHeads\AllComponents\Wasm\obj\Debug\net7.0\CommunityToolkit.Tooling.SampleGen\CommunityToolkit.Tooling.SampleGen.ToolkitSampleMetadataGenerator\ToolkitSampleRegistry.g.cs(38,781,38,796): error CS1744: Named argument 'showAsNumberBox' specifies a parameter for which a positional argument has already been given
1>D:\Work\CommunityToolkitWindows\tooling\ProjectHeads\AllComponents\Wasm\obj\Debug\net7.0\CommunityToolkit.Tooling.SampleGen\CommunityToolkit.Tooling.SampleGen.ToolkitSampleMetadataGenerator\ToolkitSampleRegistry.g.cs(42,569,42,572): error CS8323: Named argument 'min' is used out-of-position but is followed by an unnamed argument

@Arlodotexe
Copy link
Member

@Arlodotexe and once more for styling, hopefully will work out this time 😅

Wanted to verify with the sample app, but getting:

1>D:\Work\CommunityToolkitWindows\tooling\ProjectHeads\AllComponents\Wasm\obj\Debug\net7.0\CommunityToolkit.Tooling.SampleGen\CommunityToolkit.Tooling.SampleGen.ToolkitSampleMetadataGenerator\ToolkitSampleRegistry.g.cs(38,781,38,796): error CS1744: Named argument 'showAsNumberBox' specifies a parameter for which a positional argument has already been given
1>D:\Work\CommunityToolkitWindows\tooling\ProjectHeads\AllComponents\Wasm\obj\Debug\net7.0\CommunityToolkit.Tooling.SampleGen\CommunityToolkit.Tooling.SampleGen.ToolkitSampleMetadataGenerator\ToolkitSampleRegistry.g.cs(42,569,42,572): error CS8323: Named argument 'min' is used out-of-position but is followed by an unnamed argument

That's odd, it looks like our SampleGen tooling is generating invalid metadata for a [ToolkitSampleNumericOption(...)] somewhere, likely for the RangeSelector. It may be a transient error, if CI doesn't pass I can give a hand.

@MartinZikmund
Copy link
Contributor Author

@Arlodotexe the error now seems unrelated, or not?

@Arlodotexe
Copy link
Member

@Arlodotexe the error now seems unrelated, or not?

Fixed this CI error recently in #411, should be good now.

@MartinZikmund
Copy link
Contributor Author

@Arlodotexe seems it helped 👍👍

@Arlodotexe
Copy link
Member

@Arlodotexe seems it helped 👍👍

Great! Tested on WebAssembly, looks like this did the trick. Thanks @MartinZikmund!

image

@Arlodotexe Arlodotexe merged commit d67f7ae into CommunityToolkit:main May 18, 2024
9 checks passed
@MartinZikmund MartinZikmund deleted the dev/mazi/square-thumbs branch May 27, 2024 10:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

[RangeSelector] on WASM draws squares around track controls
3 participants