Xamarin.Forms icon indicating copy to clipboard operation
Xamarin.Forms copied to clipboard

[Bug] iOS DatePicker with UIDatePickerStyle.Inline missing month information

Open mos379 opened this issue 3 years ago • 7 comments

Description

When changing the presentation of the DatePicker to UIDatePickerStyle.Inline on iOS the presentation is not sized correctly and cuts of the month and Year info

Steps to Reproduce

  1. custom renderer with UIDatePickerStyle.Inline
  2. open Picker

Expected Behavior

showing correct inline calendar with month and year info

Actual Behavior

only showing days with a fragment of the top info

Basic Information

  • Version with issue: 5.0
  • Last known good version: none
  • Platform Target Frameworks:
    • iOS: 14.x
  • NuGet Packages:
  • Affected Devices: all iOS

Screenshots

image

Related issue: #11963

mos379 avatar Jan 30 '21 15:01 mos379

Hi, @mos379 - thanks for submitting this issue! Have you tried running on other versions of iOS? If it looks different, would you be able to share relevant screenshots?

Also, if you could share your project or a sample project reproducing this issue, that would be incredibly helpful in helping us to better understand the issue. Thank you! :)

rachelkang avatar Feb 01 '21 18:02 rachelkang

I attached the sample project. It is the basic template from Visual studio where I added a datepicker in the mainPage and added a custom renderer wfor setting up the inline mode for the picker.

I'm currently not able to test on a different OS version PickerIssue.zip

mos379 avatar Feb 01 '21 20:02 mos379

I came across the same issue the day I updated iOS app to Xamarin.Forms 5.0.0.1874. Build 5.0.0.1874 'forced' the UIDatePickerStyle.Automatic, which is same as .Compact. The .Automatic look and feel is quite ugly, and confusing for the end user. I implement a Custom renderer for unrelated Date issue #13366, so I tried the .Inline style - not usable. Xamarin.Forms 5.0.0.1931'forces' UIDatePickerStyle.Wheels. My best guess, it was an awkward workaround the unsightly
UIDatePickerStyle.Compact. Since I use a CustomRenderer for the DatePicker anyway, I'd prefer the .Inline style work as expected. I currently settled for .Automatic as more functional than .Wheels . It took Apple a while to figure out end users need to know the Day of Week when selecting. Wheels doesn't show Day of Week, besides being cumbersome to use.

mikebikerider avatar Feb 02 '21 17:02 mikebikerider

@mos379 thanks for the sample and @mikebikerider thanks for sharing! I'm able to reproduce the behavior you're experiencing

rachelkang avatar Feb 02 '21 18:02 rachelkang

Hi all,

I am also experiencing this. Any workaround for the moment? With a renderer of some sort.

Thank you very much

gil-rodrigues avatar Apr 26 '21 15:04 gil-rodrigues

@rachelkang any update on this issue?

mos379 avatar Sep 11 '21 15:09 mos379

Any update so far?. I also experiencing the same. Thanks to @mikebikerider , by using .automatic style , can solve this issue, but the .automatic behaviour was not what i expected.

Alhaadi-IDB avatar Aug 30 '22 05:08 Alhaadi-IDB