Angular-calendar: Resize calendar cells

Created on 18 Jul 2018  路  4Comments  路  Source: mattlewis92/angular-calendar

Describe the bug


Minimal reproduction of the problem with instructions

I want to resize my day-cell in order to be 50x50 px each.
I have tried to add some styles in my css file but it's not working like I need it to. As you can see, the cell is not a square.

How can I resolve this?

I have my code in stackblitz:

https://stackblitz.com/edit/angular-kjrkfu?embed=1&file=demo/demo.component.css

Screenshots

Versions

  • @angular/core:5
  • angular-calendar:0.24.1
  • Browser name and version:Chrome

Most helpful comment

@AMkiri,
I have created a new css file (included in my app, ofc) with the following code:

.cal-cell-row {
    height: 100%;
}
.ng-star-inserted { 
    height: 51px;
}
.cal-month-view .cal-day-cell {
     height: 51px;
     min-height: 0px;
}

I am not sure if this is the right way to handle this, but it worked for me. Hope it works for you too!! :)

All 4 comments

The same problem with cell height. Could you please write how you solved that issue?

@AMkiri,
I have created a new css file (included in my app, ofc) with the following code:

.cal-cell-row {
    height: 100%;
}
.ng-star-inserted { 
    height: 51px;
}
.cal-month-view .cal-day-cell {
     height: 51px;
     min-height: 0px;
}

I am not sure if this is the right way to handle this, but it worked for me. Hope it works for you too!! :)

Thanks a lot! It's also works if write directly in css where "~angular-calendar/css/angular-calendar.css" included.

thanks @teodoramalec it fixed my problem. however is there any proper way to change height of whole grid?

Was this page helpful?
0 / 5 - 0 ratings

Related issues

AstRonin picture AstRonin  路  4Comments

chaouiy picture chaouiy  路  3Comments

sylvain-fr picture sylvain-fr  路  3Comments

vinay13 picture vinay13  路  3Comments

ntsiatinis picture ntsiatinis  路  4Comments