Skip to content

Commit

Permalink
refactor: hide dashboard spacing api temporarily (#6831)
Browse files Browse the repository at this point in the history
* refactor: hide dashboard spacing api temporarily

* fix: make helpers public

* fix: make helpers public

* test: revert deletion of helper and use spacing property directly
  • Loading branch information
ugur-vaadin authored Nov 20, 2024
1 parent ba11f24 commit 96dabb7
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,8 @@ public DashboardItemResizePage() {
dashboard.setMinimumRowHeight("200px");
dashboard.setMinimumColumnWidth("250px");
dashboard.setMaximumColumnWidth("250px");
dashboard.setSpacing("0px");
// Use setSpacing when it is made public
getStyle().set("--vaadin-dashboard-spacing", "0px");

DashboardWidget widget = new DashboardWidget();
widget.setTitle("Widget");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
* Dashboard is a responsive layout component that allows users to organize
* widgets either directly within the dashboard or optionally group them into
* sections. The component supports customizable layout options like maximum
* column count and spacing.
* column count.
* <p>
* Internationalization (i18n) is supported through {@link DashboardI18n},
* allowing customization of accessible names for the dashboard controls. The
Expand Down Expand Up @@ -319,7 +319,7 @@ public void setMinimumRowHeight(String minRowHeight) {
*
* @return the spacing of the dashboard
*/
public String getSpacing() {
String getSpacing() {
return getStyle().get("--vaadin-dashboard-spacing");
}

Expand All @@ -331,7 +331,7 @@ public String getSpacing() {
* the new spacing. Pass in {@code null} to set the spacing back
* to the default value.
*/
public void setSpacing(String spacing) {
void setSpacing(String spacing) {
getStyle().set("--vaadin-dashboard-spacing", spacing);
}

Expand Down

0 comments on commit 96dabb7

Please sign in to comment.