Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions dashboard-parent/dashboard-core/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,16 @@
<artifactId>xstream</artifactId>
</dependency>

<!-- WebJars -->
<dependency>
<groupId>de.agilecoders.wicket.webjars</groupId>
<artifactId>wicket-webjars</artifactId>
</dependency>
<dependency>
<groupId>org.webjars</groupId>
<artifactId>jquery-ui</artifactId>
</dependency>

<!-- Testing -->
<dependency>
<groupId>org.junit.jupiter</groupId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,5 @@
requires org.apache.wicket.util;
requires xstream;
requires com.google.gson;
requires de.agilecoders.wicket.webjars;
}
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
import org.apache.wicket.MetaDataKey;
import org.apache.wicket.request.resource.PackageResourceReference;
import org.apache.wicket.request.resource.ResourceReference;
import de.agilecoders.wicket.webjars.request.resource.WebjarsJavaScriptResourceReference;

/**
* {@link DashboardSettings} which allows to specify set of resources for inclusion in an page header
Expand All @@ -32,8 +33,7 @@ public class DashboardSettings {
DashboardSettings.class, "res/dashboard.css");
private ResourceReference rtlCssReference = new PackageResourceReference(
DashboardSettings.class, "res/dashboard-rtl.css");
private ResourceReference jqueryUIReference = new PackageResourceReference(
DashboardSettings.class, "res/jquery-ui-1.13.0.min.js");
private ResourceReference jqueryUIReference = new WebjarsJavaScriptResourceReference("jquery-ui/current/jquery-ui.js");

private boolean includeJQueryUI = true;
private boolean includeJavaScript = true;
Expand Down

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
import static org.hamcrest.CoreMatchers.nullValue;
import static org.hamcrest.MatcherAssert.assertThat;

import de.agilecoders.wicket.webjars.WicketWebjars;
import org.apache.wicket.Application;
import org.apache.wicket.MetaDataKey;
import org.apache.wicket.Page;
Expand Down Expand Up @@ -36,6 +37,7 @@ public Class<? extends Page> getHomePage() {
@Override
protected void init() {
super.init();
WicketWebjars.install(this);
DashboardContext dashboardContext = this.getMetaData(DashboardContextInitializer.DASHBOARD_CONTEXT_KEY);
WidgetDescriptor widgetDescriptor;
dashboardContext.getWidgetRegistry().registerWidget(widgetDescriptor = new MyWidgetDescriptor());
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@

import static org.wicketstuff.dashboard.DashboardContextInitializer.getDashboardContext;

import de.agilecoders.wicket.webjars.WicketWebjars;
import org.apache.wicket.Page;
import org.apache.wicket.protocol.http.WebApplication;
import org.wicketstuff.dashboard.Dashboard;
Expand All @@ -39,6 +40,7 @@ public static WicketApplication get() {
@Override
public void init() {
super.init();
WicketWebjars.install(this);

getCspSettings().blocking().disabled();

Expand Down