UNPKG

@tomino/dynamic-form-semantic-ui

Version:

Semantic UI form renderer based on dynamic form generation

39 lines 1.62 kB
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); const tslib_1 = require("tslib"); const react_1 = tslib_1.__importDefault(require("react")); const editor_common_1 = require("../editor/editor_common"); const stack_view_1 = require("./stack_view"); const droppable_editor_1 = require("../editor/droppable_editor"); exports.StackEditorComponent = props => (react_1.default.createElement(droppable_editor_1.DropComponentEditor, Object.assign({}, props, { Component: stack_view_1.StackView.Component, layout: props.formElement.props.layout }))); exports.StackEditor = { Component: exports.StackEditorComponent, control: 'Stack', icon: 'align justify', title: 'Stack Layout', group: 'Layout', defaultProps: { layout: 'column' }, props: editor_common_1.propGroup('Stack', { layout: editor_common_1.prop({ documentation: 'Items can either be stacked in rows or columns', label: 'Layout', control: 'Select', type: 'string', $enum: [{ text: 'Rows', value: 'row' }, { text: 'Columns', value: 'column' }] }), final: editor_common_1.prop({ type: 'boolean', documentation: 'Prohibits adding new elements to the stack. This is used mostly in editor for visual appeal.' }), gap: editor_common_1.gapProp({ documentation: 'Spacing between cells' }), padding: editor_common_1.gapProp({ documentation: 'Cell padding', label: 'Padding' }) }) }; //# sourceMappingURL=stack_editor.js.map