use of com.vaadin.flow.component.textfield.TextField in project karnak by OsiriX-Foundation.
the class NotificationComponent method buildNotifyObjectValues.
/**
* Notify Object Values
*/
private void buildNotifyObjectValues() {
notifyObjectValues = new TextField(String.format("Notif.: subject values (Default: %s)", Notification.DEFAULT_SUBJECT_VALUES));
notifyObjectValues.setWidth("24%");
UIS.setTooltip(notifyObjectValues, String.format("Values injected in the pattern [PatientID StudyDescription StudyDate StudyInstanceUID]. Default value: %s", Notification.DEFAULT_SUBJECT_VALUES));
}
use of com.vaadin.flow.component.textfield.TextField in project karnak by OsiriX-Foundation.
the class SourceView method buildComponentsLayout.
/**
* Create components, layout and add the layout of the view
*/
private void buildComponentsLayout() {
setSizeFull();
gridSourceNode = new GridSourceNode();
filter = new TextField();
newSourceNode = new Button(LABEL_NEW_SOURCE_NODE);
layoutFilterButton = new HorizontalLayout(filter, newSourceNode);
layoutFilterButton.setVerticalComponentAlignment(Alignment.START, filter);
layoutFilterButton.expand(filter);
setTextFieldFilter();
setButtonNewDestinationDICOM();
add(UIS.setWidthFull(layoutFilterButton), UIS.setWidthFull(gridSourceNode));
}
use of com.vaadin.flow.component.textfield.TextField in project WebComponentKit by itsoulltd.
the class AbstractBeanEditor method getValueField.
protected HasValue getValueField(Property prop) {
HasValue hasValue = null;
if (prop.getType() == DataType.BOOL) {
Checkbox box = new Checkbox();
box.setLabel(prop.getKey());
if (prop.getValue() != null)
box.setValue((Boolean) prop.getValue());
else
box.setIndeterminate(true);
hasValue = box;
} else if (prop.getType() == DataType.SQLDATE) {
DatePicker datePicker = new DatePicker();
datePicker.setValue(LocalDate.now());
datePicker.setClearButtonVisible(true);
hasValue = datePicker;
} else if (prop.getType() == DataType.SQLTIMESTAMP) {
TimePicker timePicker = new TimePicker();
timePicker.setValue(LocalTime.now());
timePicker.setClearButtonVisible(true);
hasValue = timePicker;
} else {
TextField field = new TextField();
field.setLabel(prop.getKey());
hasValue = field;
}
return hasValue;
}
use of com.vaadin.flow.component.textfield.TextField in project aire-components by aire-ux.
the class AddFeatureFlagOverlay method addContent.
private void addContent() {
val form = new FormLayout();
keyInputField = new TextField("Key");
nameInputField = new TextField("Name");
descriptionInput = new TextArea("Description");
pathInputField = new Select<>();
pathInputField.setLabel("Extension Path");
pathInputField.setItems(getExtensionKeys());
tagInputField = new TextField("Tags");
enabledSwitch = new Switch("Enabled");
form.add(keyInputField, nameInputField, pathInputField, enabledSwitch, tagInputField, descriptionInput);
form.setColspan(descriptionInput, 2);
addContent(form);
}
use of com.vaadin.flow.component.textfield.TextField in project aire-components by aire-ux.
the class FeatureList method createMenuBar.
private Component createMenuBar() {
val result = new MenuBar();
result.addThemeVariants(MenuBarVariant.LUMO_SMALL, MenuBarVariant.LUMO_ICON, MenuBarVariant.LUMO_TERTIARY_INLINE);
searchField = new TextField();
searchField.setPlaceholder("Search");
searchField.setClearButtonVisible(true);
searchField.setPrefixComponent(VaadinIcon.SEARCH.create());
searchField.setValueChangeMode(ValueChangeMode.EAGER);
searchField.addValueChangeListener(this);
result.addItem(searchField);
val addButton = new Button("Add Feature Flag", VaadinIcon.PLUS.create());
addButton.addClickListener(click -> {
val overlay = Overlays.open(this, AddFeatureFlagOverlay.class);
overlay.addOverlayClosedEventListener(event -> {
if (!event.isCancelled()) {
featureManager.registerFeature(overlay.getValue());
grid.getDataProvider().refreshAll();
}
});
});
result.addItem(addButton);
return result;
}
Aggregations