tiberiuzuld / angular-gridster2

Angular gridster 2
https://tiberiuzuld.github.io/angular-gridster2
MIT License
1.28k stars 376 forks source link

How to fill the margin lines between cells #366

Open shyambhiogade opened 6 years ago

shyambhiogade commented 6 years ago

hi @tiberiuzuld , how to fill the lines between cells with different color, right now it just show the background color of grid.

shyambhiogade commented 6 years ago

@tiberiuzuld can you please reply if its possible easily. gridstermargin

tiberiuzuld commented 5 years ago

Hi @shyambhiogade , You can't at the moment, will consider adding this feature.

admir86 commented 5 years ago

please add also a possibility to change the grid lines color. for now I can use :host gridster /deep/ .gridster-column but deep is deprecated.

https://angular.io/guide/component-styles#deprecated-deep--and-ng-deep

tiberiuzuld commented 5 years ago

That should work without deep since the grid is using encapsulation: ViewEncapsulation.None

admir86 commented 5 years ago

without deep it works only if the style definition is in the global css. but not if the style is defined in the css of my dashboard component.

tiberiuzuld commented 5 years ago

True, but I don't think is worth it to make an api for all the css values properties out there. Those values should be changed from css not from JS api. This initial issues is about the structure of how the grid lines are formed to enable to color the lines between widgets. As a mater of fact got an idea on how do it from css without any change in the library. hey @shyambhiogade , You can use this css to make your lines a different color

gridster .gridster-column {
    border-left: 1px solid red;
    border-right: 1px solid red;
    outline: 10px solid red;
}
gridster .gridster-row {
    border-top: 1px solid red;
    border-bottom: 1px solid red;
    outline: 10px solid red;
}

image

Let me know if this works for your use case.

tomazk8 commented 3 years ago

@tiberiuzuld Although an old post, it looks like this is still not possible. I want to change the grid line color but am unable to do it. Tried your CSS but didn't work. Any idea how to acomplish this?