de.agilecoders.wicket.core.settings.IBootstrapSettings Java Examples

The following examples show how to use de.agilecoders.wicket.core.settings.IBootstrapSettings. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: WicketApplicationBase.java    From webanno with Apache License 2.0 6 votes vote down vote up
protected void initBootstrap()
{
    SassCompilerOptionsFactory sassOptionsFactory = () -> {
        Options options = new Options();
        options.setOutputStyle(DEPLOYMENT.equals(getConfigurationType()) ? EXPANDED : NESTED);
        return options;
    };
    
    WicketWebjars.install(this);

    BootstrapSass.install(this, sassOptionsFactory);
    // Install a customized cache manager which can deal with SCSS files in JARs
    SassCacheManager cacheManager = new SassCacheManager(sassOptionsFactory);
    cacheManager.install(this);

    
    Bootstrap.install(this);
    
    IBootstrapSettings settings = Bootstrap.getSettings(this);
    settings.setCssResourceReference(CustomBootstrapSassReference.get());
}
 
Example #2
Source File: BootstrapAwareJQueryUIJavaScriptResourceReference.java    From webanno with Apache License 2.0 5 votes vote down vote up
@Override
public List<HeaderItem> getDependencies()
{
    IBootstrapSettings settings = Bootstrap.getSettings();
    final JavaScriptReferenceHeaderItem jsReference = JavaScriptHeaderItem.forReference(
            settings.getJsResourceReference(), new PageParameters(), "bootstrap-js",
            settings.deferJavascript());
    return Dependencies.combine(super.getDependencies(), jsReference);
}
 
Example #3
Source File: ToDoApplication.java    From isis-app-todoapp with Apache License 2.0 5 votes vote down vote up
@Override
protected void init() {
    super.init();

    final IBootstrapSettings settings = Bootstrap.getSettings();
    settings.setThemeProvider(new BootswatchThemeProvider(BootswatchTheme.Flatly));

    settings.setActiveThemeProvider(new UserSettingsThemeProvider(settings));
}
 
Example #4
Source File: BootstrapJavascriptBehavior.java    From onedev with MIT License 4 votes vote down vote up
@Override
public void renderHead(IBootstrapSettings settings, IHeaderResponse headerResponse) {
    super.renderHead(settings, headerResponse);
}
 
Example #5
Source File: UserSettingsThemeProvider.java    From isis-app-todoapp with Apache License 2.0 4 votes vote down vote up
public UserSettingsThemeProvider(final IBootstrapSettings settings) {
    this.settings = settings;
}