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

[regression/8.0.0-preview.4.8333] Borderless Entry Handler Not Working in .NET MAUI 8.0 #17448

Closed
mistrypragnesh40 opened this issue Sep 18, 2023 · 8 comments · Fixed by #17778
Assignees
Labels
area-controls-entry Entry custom-handler fixed-in-8.0.6 Look for this fix in 8.0.6 SR1! i/regression This issue described a confirmed regression on a currently supported version p/1 Work that is important, and has been scheduled for release in this or an upcoming sprint platform/android 🤖 platform/iOS 🍎 s/triaged Issue has been reviewed s/verified Verified / Reproducible Issue ready for Engineering Triage t/bug Something isn't working
Milestone

Comments

@mistrypragnesh40
Copy link

mistrypragnesh40 commented Sep 18, 2023

Description

Here is the code.

        Microsoft.Maui.Handlers.EntryHandler.Mapper.AppendToMapping(nameof(CustomEntry), (handler, view) =>
            {
#if ANDROID
                handler.PlatformView.Background = null;
                handler.PlatformView.SetBackgroundColor(Android.Graphics.Color.Transparent);
#elif IOS
            handler.PlatformView.BackgroundColor = UIKit.UIColor.Clear;
            handler.PlatformView.Layer.BorderWidth = 0;
            handler.PlatformView.BorderStyle = UIKit.UITextBorderStyle.None;
#endif
            });```
            
            

### Steps to Reproduce

1. Create CustomEntry Class that inherit Entry Class.
2. Use That Handler in UI.
3. Add Handler Mapping on App.xaml.cs


    Microsoft.Maui.Handlers.EntryHandler.Mapper.AppendToMapping(nameof(CustomEntry), (handler, view) =>
        {

#if ANDROID
handler.PlatformView.Background = null;
handler.PlatformView.SetBackgroundColor(Android.Graphics.Color.Transparent);
#elif IOS
handler.PlatformView.BackgroundColor = UIKit.UIColor.Clear;
handler.PlatformView.Layer.BorderWidth = 0;
handler.PlatformView.BorderStyle = UIKit.UITextBorderStyle.None;
#endif
});```

Link to public reproduction project repository

No response

Version with bug

8.0.0-preview.4.8333

Is this a regression from previous behavior?

Yes, this used to work in .NET MAUI

Last version that worked well

8.0.0-preview.3.8149

Affected platforms

iOS, Android

Affected platform versions

No response

Did you find any workaround?

handler.PlatformView.BackgroundTintList = Android.Content.Res.ColorStateList.ValueOf(Colors.Transparent.ToAndroid());

Relevant log output

No response

@mistrypragnesh40 mistrypragnesh40 added the t/bug Something isn't working label Sep 18, 2023
@ghost ghost added the legacy-area-controls Label, Button, CheckBox, Slider, Stepper, Switch, Picker, Entry, Editor label Sep 18, 2023
@jsuarezruiz jsuarezruiz added platform/android 🤖 and removed legacy-area-controls Label, Button, CheckBox, Slider, Stepper, Switch, Picker, Entry, Editor labels Sep 18, 2023
@Eilon Eilon added the legacy-area-controls Label, Button, CheckBox, Slider, Stepper, Switch, Picker, Entry, Editor label Sep 18, 2023
@samhouts samhouts added the potential-regression This issue described a possible regression on a currently supported version., verification pending label Sep 18, 2023
@samhouts samhouts added this to the .NET 8 GA milestone Sep 18, 2023
@samhouts samhouts changed the title Borderless Entry Handler Not Working in .NET MAUI 8.0 [regression/8.0.0] Borderless Entry Handler Not Working in .NET MAUI 8.0 Sep 19, 2023
@RonnyRos
Copy link

yes does not work.

@samhouts samhouts added the s/needs-repro Attach a solution or code which reproduces the issue label Sep 19, 2023
@ghost
Copy link

ghost commented Sep 19, 2023

Hi @mistrypragnesh40. We have added the "s/needs-repro" label to this issue, which indicates that we require steps and sample code to reproduce the issue before we can take further action. Please try to create a minimal sample project/solution or code samples which reproduce the issue, ideally as a GitHub repo that we can clone. See more details about creating repros here: https://github.com/dotnet/maui/blob/main/.github/repro.md

This issue will be closed automatically in 7 days if we do not hear back from you by then - please feel free to re-open it if you come back to this issue after that time.

@mistrypragnesh40
Copy link
Author

Hello,
Here is the repo link : https://github.com/mistrypragnesh40/BorderlessEntryDemo

@ghost ghost added s/needs-attention Issue has more information and needs another look and removed s/needs-repro Attach a solution or code which reproduces the issue labels Sep 20, 2023
@XamlTest XamlTest added s/verified Verified / Reproducible Issue ready for Engineering Triage s/triaged Issue has been reviewed labels Sep 21, 2023
@XamlTest
Copy link

Verified this on Visual Studio Enterprise 17.8.0 Preview 2.0(8.0.0-rc.1.23419.4). Repro on Windows 11 and Android 13.0-API33, not repro on iOS 16.4 with below Project:
BorderlessEntryDemo.zip

Windows:
image
Android:
image
iOS:
image

@samhouts samhouts added i/regression This issue described a confirmed regression on a currently supported version and removed potential-regression This issue described a possible regression on a currently supported version., verification pending s/needs-attention Issue has more information and needs another look labels Sep 29, 2023
@samhouts
Copy link
Member

samhouts commented Sep 29, 2023

Confirmed that this regressed on Android between 8.0.0-preview.3.8149 and 8.0.0-preview.4.8333. #12227 seems sus, though that doesn't explain the Windows issue.

@samhouts samhouts changed the title [regression/8.0.0] Borderless Entry Handler Not Working in .NET MAUI 8.0 [regression/8.0.0-preview.4.8333] Borderless Entry Handler Not Working in .NET MAUI 8.0 Sep 29, 2023
@PureWeen PureWeen removed this from the .NET 8 GA milestone Sep 30, 2023
@PureWeen PureWeen added this to the .NET 8 SR1 milestone Sep 30, 2023
@jsuarezruiz jsuarezruiz moved this from Todo to In Progress in MAUI SDK Ongoing Oct 2, 2023
@samhouts samhouts added the p/1 Work that is important, and has been scheduled for release in this or an upcoming sprint label Oct 3, 2023
@npostma
Copy link

npostma commented Oct 5, 2023

I've tested the fix (pullrequest) in combination with the net8.0 branch. Looks nice again :-)

image

@npostma
Copy link

npostma commented Nov 16, 2023

@samhouts How/When can we expect this fix in a upcoming update? Ive build my app with the latest version of MAUI 8.0.3 on VS2022 Preview. But i still have the borders on android.

@ghost
Copy link

ghost commented Nov 16, 2023

Hello lovely human, thank you for your comment on this issue. Because this issue has been closed for a period of time, please strongly consider opening a new issue linking to this issue instead to ensure better visibility of your comment. Thank you!

@github-actions github-actions bot locked and limited conversation to collaborators Dec 16, 2023
@samhouts samhouts added the fixed-in-8.0.6 Look for this fix in 8.0.6 SR1! label Jan 31, 2024
@Eilon Eilon removed the legacy-area-controls Label, Button, CheckBox, Slider, Stepper, Switch, Picker, Entry, Editor label May 10, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-controls-entry Entry custom-handler fixed-in-8.0.6 Look for this fix in 8.0.6 SR1! i/regression This issue described a confirmed regression on a currently supported version p/1 Work that is important, and has been scheduled for release in this or an upcoming sprint platform/android 🤖 platform/iOS 🍎 s/triaged Issue has been reviewed s/verified Verified / Reproducible Issue ready for Engineering Triage t/bug Something isn't working
Projects
Status: Done
Development

Successfully merging a pull request may close this issue.

8 participants