use of com.helger.html.hc.html.textlevel.HCSmall in project phoss-directory by phax.
the class PDLoginManager method createLoginScreen.
@Override
protected IHTMLProvider createLoginScreen(final boolean bLoginError, @Nonnull final ICredentialValidationResult aLoginResult) {
return new BootstrapLoginHTMLProvider(bLoginError, aLoginResult, getPageTitle()) {
@Override
@Nullable
protected IHCNode createFormFooter(@Nonnull final ISimpleWebExecutionContext aSWEC) {
final HCDiv aDiv = new HCDiv().addClass(CBootstrapCSS.D_FLEX).addClass(CBootstrapCSS.MT_5);
aDiv.addChild(new HCSmall().addChild(CPDPublisher.getApplicationTitleWithVersion() + " / " + CDirectoryVersion.BUILD_TIMESTAMP));
return aDiv;
}
};
}
use of com.helger.html.hc.html.textlevel.HCSmall in project phoss-directory by phax.
the class SecureHTMLProvider method getContent.
@Nonnull
public static IHCNode getContent(@Nonnull final LayoutExecutionContext aLEC) {
final HCNodeList ret = new HCNodeList();
// Header
ret.addChild(_getNavbar(aLEC));
final BootstrapContainer aOuterContainer = ret.addAndReturnChild(new BootstrapContainer().setFluid(true));
// Breadcrumbs
{
final BootstrapBreadcrumb aBreadcrumbs = BootstrapBreadcrumbProvider.createBreadcrumb(aLEC);
aBreadcrumbs.addClasses(CBootstrapCSS.D_NONE, CBootstrapCSS.D_SM_BLOCK);
aOuterContainer.addChild(aBreadcrumbs);
}
// Content
{
final HCDiv aRow = aOuterContainer.addAndReturnChild(new HCDiv().addClass(CBootstrapCSS.D_MD_FLEX));
final HCDiv aCol1 = aRow.addAndReturnChild(new HCDiv().addClass(CBootstrapCSS.D_MD_FLEX).addClass(CBootstrapCSS.MR_2));
final HCDiv aCol2 = aRow.addAndReturnChild(new HCDiv().addClass(CBootstrapCSS.FLEX_FILL));
// left
// We need a wrapper span for easy AJAX content replacement
aCol1.addClass(CBootstrapCSS.D_PRINT_NONE).addChild(new HCSpan().setID(CLayout.LAYOUT_AREAID_MENU).addChild(getMenuContent(aLEC)).addChild(new HCDiv().addChild(new HCSmall().addChild(CDirectoryVersion.BUILD_VERSION))).addChild(new HCDiv().addChild(new HCSmall().addChild(CDirectoryVersion.BUILD_TIMESTAMP))));
aCol1.addChild(new HCDiv().setID(CLayout.LAYOUT_AREAID_SPECIAL));
// content - determine is exactly same as for view
aCol2.addChild(BootstrapPageRenderer.getPageContent(aLEC));
}
return ret;
}
use of com.helger.html.hc.html.textlevel.HCSmall in project phoss-directory by phax.
the class NiceNameUI method _createFormattedID.
@Nonnull
private static IHCNode _createFormattedID(@Nonnull final String sID, @Nullable final String sName, @Nullable final EBootstrapBadgeType eType, final boolean bIsDeprecated, final boolean bInDetails) {
if (sName == null) {
// No nice name present
if (bInDetails)
return new HCCode().addChild(sID);
return new HCTextNode(sID);
}
final HCNodeList ret = new HCNodeList();
ret.addChild(new BootstrapBadge(eType).addChild(sName));
if (bIsDeprecated) {
ret.addChild(" ").addChild(new BootstrapBadge(EBootstrapBadgeType.WARNING).addChild("Identifier is deprecated"));
}
if (bInDetails) {
ret.addChild(new HCSmall().addChild(" (").addChild(new HCCode().addChild(sID)).addChild(")"));
}
return ret;
}
use of com.helger.html.hc.html.textlevel.HCSmall in project phoss-smp by phax.
the class NiceNameUI method createFormattedID.
@Nonnull
private static IHCNode createFormattedID(@Nonnull final String sID, @Nullable final String sName, @Nullable final EBootstrapBadgeType eType, final boolean bIsDeprecated, final boolean bInDetails) {
if (sName == null) {
// No nice name present
if (bInDetails)
return new HCCode().addChild(sID);
return new HCTextNode(sID);
}
final HCNodeList ret = new HCNodeList();
ret.addChild(new BootstrapBadge(eType).addChild(sName));
if (bIsDeprecated) {
ret.addChild(" ").addChild(new BootstrapBadge(EBootstrapBadgeType.WARNING).addChild("Identifier is deprecated"));
}
if (bInDetails) {
ret.addChild(new HCSmall().addChild(" (").addChild(new HCCode().addChild(sID)).addChild(")"));
}
return ret;
}
use of com.helger.html.hc.html.textlevel.HCSmall in project phoss-smp by phax.
the class SMPLoginHTMLProvider method createFormFooter.
@Override
@Nullable
protected IHCNode createFormFooter(@Nonnull final ISimpleWebExecutionContext aSWEC) {
final HCDiv aDiv = new HCDiv().addClass(CBootstrapCSS.D_FLEX).addClass(CBootstrapCSS.MT_3);
aDiv.addChild(new HCSmall().addChild(CSMP.getApplicationTitleAndVersion()));
return aDiv;
}
Aggregations