Skip to content

Commit

Permalink
Merge pull request #64 from flypapertech/fix-dark-mode
Browse files Browse the repository at this point in the history
Fixes display on dark mode
  • Loading branch information
shiv19 authored Feb 20, 2020
2 parents 16076e2 + b5a2745 commit f6f6e5b
Show file tree
Hide file tree
Showing 4 changed files with 2,273 additions and 187 deletions.
9 changes: 8 additions & 1 deletion src/modal-datetimepicker.ios.ts
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,14 @@ export class ModalDatetimepicker {
);

pickerHolderView = UIView.alloc().init();
pickerHolderView.backgroundColor = UIColor.whiteColor;
const appearance = application.systemAppearance();
if (appearance) {
pickerHolderView.backgroundColor =
appearance === "dark" ? UIColor.blackColor : UIColor.whiteColor;
} else {
pickerHolderView.backgroundColor = UIColor.whiteColor;
}

pickerHolderView.frame = CGRectMake(
0,
0,
Expand Down
Loading

0 comments on commit f6f6e5b

Please sign in to comment.