Questions tagged [ngb-datepicker]

82 questions
2
votes
1 answer

How to change datepicker date format like dd/mm/yyyy in ngbdatepicker

I am using ng-boostrap for datepicker:https://ng-bootstrap.github.io/#/components/datepicker/api But i do not know how to change date format like dd/mm/yyyy. Now it is displaying yyyy/mm/dd but i want like dd/mm/yyyy.Please help…
Pappa S
  • 303
  • 1
  • 8
  • 21
2
votes
1 answer

How can I change the color to the arrows navigation of the ngb-datapicker?

I am using this datapicker (the range selection) on a project and the blue color of the arrows in the navigation bar is not the right one and I want to change it. I searched on google and here and I can not found an answer that solve my problem. I…
Jose Mosquera
  • 23
  • 1
  • 5
2
votes
0 answers

Angular 4: Custom style for ngbdatepicker select year dropdown

I'm using ngbDatepicker in my angular application.
Abhishek
  • 1,974
  • 5
  • 31
  • 67
2
votes
3 answers

how to disable existing dates from ngbdatepicker angular

I have array existing data. how to disable existing data when picking date from ngbdatepicker? here's my disable code from past date var current = new Date(); current.setDate(current.getDate()); this.minDates = { year:…
Soni Silalahi
  • 249
  • 2
  • 5
  • 15
2
votes
1 answer

ngb-datepicker change tooltips language

I've got a multi-language app which uses a custom NgbDatePickerI18n: @Injectable() export class CustomDatepickerService extends NgbDatepickerI18n { constructor(private translateService: TranslateService) { super(); } …
2
votes
1 answer

How to update the input box date through ngModel in ngb-Datepicker?

I have an input box which uses ngb-datepicker for the date. When I am trying to get the value from date picker through ngModel, it is working. But it is not working when I am trying to update ngModel from the function, input box is not getting…
DEV1205
  • 352
  • 1
  • 6
  • 18
1
vote
1 answer

Angular ngbDatepicker: How to include context in markDisabled

I have an input field defined as ngbDatepicker. Some of the days should be disabled which is why I use [markDisabled]="getDisabledDays" like this:
Alex
  • 81
  • 6
1
vote
1 answer

How do I add custom styling to days outside of current month?

I have an issue with not being able to make the days outside of 'current' month look disabled with ngbdatepicker. The newer version seems to have support for this, but I have not been able to reproduce it. I want to style 'outsideDays' to look grey,…
1
vote
1 answer

Converting a NgDateStruct object into a String

I am having a variable which is a NgbDateStruct object in the typescript file and would like to convert it into a String of the following format: "YYYY-MM-DD". currentDate: NgbDateStruct; When I console.log(this.currentDate) it is showing a Moment…
Nic
  • 127
  • 1
  • 11
1
vote
2 answers

How to disable all days except the 'Mondays' in ngb-datepicker?

I want to disable all days except the 'Mondays' or 'Fridays' etc... in ngb-datepicker? Template: Component: this.isDisabled = (date: NgbDate) =>(date.day) !==…
1
vote
1 answer

ngbDatepicker set current month and year dropdown

In my Angular application, I used a datepicker called ngbDatePicker. It seems that it has a bug because the default selected month and year dropdowns is not correct. See screenshot below: As you can see, the selected month is January and the year…
yapzy
  • 95
  • 1
  • 10
1
vote
0 answers

Angular - Year Picker Only

How to use reactive form and set form-control value (e.g.2018) in ngb-datepicker as only year picker? I used below link code but can't set/selected value in year picker. Please See this link :…
1
vote
1 answer

ngbDatepicker with fromgroup not able to preset value (Native Date)

I am really stuck here and I hope you could help me out. I have the following problem: I have a reactive form with a date, using the ngBootstrap datePicker, and I am using the NgbDateNativeAdapter, so that my datepicker all work with native Dates.…
1
vote
3 answers

Are there no DateTime picker for Angular 7?

I couldn't find any DateTime picker for Angular 7. So I decided to combine the Date Picker and Time Picker https://ng-bootstrap.github.io/#/components/datepicker https://ng-bootstrap.github.io/#/components/timepicker
1
vote
3 answers

Angular Bootstrap - ngbDatepicker - Convert selected Date into Date Object

in form, for date field using angular bootstrap - ngbDatepicker
Manu
  • 1,243
  • 5
  • 17
  • 43