Why Gemfury? Push, build, and install  RubyGems npm packages Python packages Maven artifacts PHP packages Go Modules Debian packages RPM packages NuGet packages

Repository URL to install this package:

Details    
ui-component-library / dist / forms / input / plugins / Simple / LabelInput.js
Size: Mime:
"use strict";
var __importDefault = (this && this.__importDefault) || function (mod) {
    return (mod && mod.__esModule) ? mod : { "default": mod };
};
Object.defineProperty(exports, "__esModule", { value: true });
const react_1 = __importDefault(require("react"));
const index_1 = require("molecules/LabelWithAction/index");
const InputChain_1 = require("../../InputChain");
class LabelInput extends InputChain_1.InputChain {
    static isSatisfiedByProps(props) {
        return props.type === 'label';
    }
    render() {
        const props = this.get('props');
        const state = this.get('state');
        console.log('LabelInput', props);
        const { onClick, classes, icon, labelText, text, value, label } = props;
        const computedText = labelText || text || value || label;
        const attributes = Object.assign({}, props, { text: computedText, onClick,
            classes,
            icon });
        return react_1.default.createElement(index_1.LabelWithAction, Object.assign({}, attributes, { key: computedText }));
    }
}
exports.LabelInput = LabelInput;
exports.default = LabelInput;
//# sourceMappingURL=LabelInput.js.map