Flow / 05. Creating components
Updated: 18. January 2018
Author: Peter Širka

05. Creating components

Professional Support Chat with contributors

Coming soon.

Client-side events

ON('open.componentname', function(component, options) {
    // Settings will be open
});

ON('save.componentname', function(component, options) {
    // Settings will be save
});

ON('select.componentname', function(component) {
    // A component has been selected in designer.
});

ON('click.componentname', function(component) {
    // Performed "click" 
});

ON('add.componentname', function(component) {
    // A component has been added.
});

ON('rem.componentname', function(component) {
    // A component has been removed.
});

ON('apply', function() {
    // Designer will be sent to server and then will be applied
});

Changing a count of outputs/inputs dynamically

v3.0.0+ This is only possible on client-side.

ON('save.componentname', function(component, options) {

    component.output = 5;
    // component.input = 3;

    // or
    component.output = ['green', 'red', 'blue'];
    // component.input = ['green', 'red', 'blue'];

    // or set output to default
    component.output = null;
    // component.input = null;
});

Components: jComponent +v14.0.0

Bellow jComponents can be used in Settings form:

  • autocomplete (declared body)
  • binder (declared in body)
  • calendar (declared in body)
  • checkbox
  • checkboxlist
  • codemirror
  • colorpicker (declared in body)
  • confirm (declared in body)
  • contextmenu (declared in body)
  • dropdown
  • dropdowncheckbox
  • error
  • exec (declared in body)
  • form
  • importer
  • keyvalue
  • loading
  • message (declared in body)
  • nosqlcounter
  • repeater
  • repeater-group
  • search
  • selectbox
  • textbox
  • textboxlist
  • validation
  • visible
  • multioptions
  • dragdropfiles
  • filereader

References: