formiojs
Version:
Common js library for client side interaction with <form.io>
85 lines (81 loc) • 1.93 kB
JavaScript
;
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.default = void 0;
var _builder = _interopRequireDefault(require("../../../utils/builder"));
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
var _default = [{
type: 'select',
input: true,
label: 'Options Label Position',
key: 'optionsLabelPosition',
tooltip: 'Position for the label for options for this field.',
dataSrc: 'values',
weight: 32,
defaultValue: 'right',
data: {
values: [{
label: 'Top',
value: 'top'
}, {
label: 'Left',
value: 'left'
}, {
label: 'Right',
value: 'right'
}, {
label: 'Bottom',
value: 'bottom'
}]
}
}, {
type: 'datagrid',
input: true,
label: 'Values',
key: 'values',
tooltip: 'The radio button values that can be picked for this field. Values are text submitted with the form data. Labels are text that appears next to the radio buttons on the form.',
weight: 33,
defaultValue: [{
label: '',
value: ''
}],
components: [{
label: 'Label',
key: 'label',
input: true,
type: 'textfield'
}, {
label: 'Value',
key: 'value',
input: true,
type: 'textfield',
allowCalculateOverride: true,
calculateValue: {
_camelCase: [{
var: 'row.label'
}]
}
}, {
type: 'select',
input: true,
weight: 180,
label: 'Shortcut',
key: 'shortcut',
tooltip: 'The shortcut key for this option.',
dataSrc: 'custom',
data: {
custom: function custom(values, component, data, row, utils, instance, form) {
return _builder.default.getAvailableShortcuts(form, component);
}
}
}]
}, {
type: 'checkbox',
input: true,
key: 'inline',
label: 'Inline Layout',
tooltip: 'Displays the checkboxes/radios horizontally.',
weight: 650
}];
exports.default = _default;