@Override
protected FormComponentLabel addComponentForRegular() {
fileUploadField = createFileUploadField(ID_SCALAR_VALUE);
fileUploadField.setLabel(Model.of(getModel().getName()));
final FormComponentLabel labelIfRegular = new FormComponentLabel(ID_SCALAR_IF_REGULAR, fileUploadField);
labelIfRegular.add(fileUploadField);
final Label scalarUploadLabel = new Label(ID_SCALAR_IF_REGULAR_UPLOAD, "Upload");
labelIfRegular.add(scalarUploadLabel);
final Label scalarName = new Label(ID_SCALAR_NAME, getModel().getName());
labelIfRegular.add(scalarName);
wicketImage = asWicketImage(ID_IMAGE);
if(wicketImage != null) {
wicketImage.setOutputMarkupId(true);
labelIfRegular.addOrReplace(wicketImage);
} else {
Components.permanentlyHide(labelIfRegular, ID_IMAGE);
}
updateDownloadLink(ID_SCALAR_IF_REGULAR_DOWNLOAD, labelIfRegular);