问题
I am trying to give custom CSS for bs-datepicker. But, its not accepting any change from component.css. I tried adding a class name in the node file of bs-datepicker in node_modules and making css changes using that class name, but the changes are not reflecting when I build the application using ng-build. Whatever change I make in node modules, they are reflecting in ng serve local view, but in ng-build , no changes are reflecting.The image of bs-datepicker is attached here
I want to change the positioning, padding, and margin of the datepicker.
.bs-datepicker {
border-radius: 0 0 4px 4px;
display: flex;
align-items: stretch;
flex-flow: row wrap;
background: #fff;
box-shadow: 0 0 0px 0 #aaa;
position: relative;
z-index: 1;
left: 50%;
margin-top: 50px;
}
This CSS I want to give to my bs-datepicker
the datepicker is binded to input like
<input id="datepicker" [(ngModel)]="datepicker" class="form-control" type="text" #JourneyDatepicker="bsDatepicker" bsDatepicker [bsConfig]="datePickerConfig" [minDate]="minDate"autocapitalize='off' name="journey" placeholder="Onward Date" autocomplete="off" readonly/>
来源:https://stackoverflow.com/questions/50393854/unable-to-change-or-give-custom-css-for-ng-datepicker