UNPKG

@opencitylabs/bootstrap-italia

Version:

Bootstrap Italia templates for Form.io forms

44 lines (43 loc) 1.73 kB
Object.defineProperty(exports, "__esModule", { value: true }); exports.default=function(ctx) { var __t, __p = '', __j = Array.prototype.join; function print() { __p += __j.call(arguments, '') } if (ctx.component.type === 'email' || ctx.component.type === 'textfield' || ctx.component.type === 'number' || ctx.component.type === 'phoneNumber' || ctx.component.type === 'currency' || ctx.component.type === 'textarea' || ctx.component.type === 'dynamic_calendar' || ctx.component.type === 'password' || ctx.component.type === 'time' || ctx.component.type === 'calendar' || ctx.component.type === 'pagebreak') { ; __p += '\n\n'; } else { ; __p += '\n\n<label\n ref="label"\n class="col-form-label ' + ((__t = (ctx.label.className)) == null ? '' : __t) + '"\n for="' + ((__t = (ctx.instance.id)) == null ? '' : __t) + '-' + ((__t = (ctx.component.key)) == null ? '' : __t) + '"\n id="l-' + ((__t = (ctx.instance.id)) == null ? '' : __t) + '-' + ((__t = (ctx.component.key)) == null ? '' : __t) + '"\n>\n ' + ((__t = ( ctx.t(ctx.component.label, { _userInput: true }) )) == null ? '' : __t) + '\n '; if (ctx.component.type === 'number' || ctx.component.type === 'phoneNumber' || ctx.component.type === 'currency') { ; __p += '\n <span class="visually-hidden">, ' + ((__t = (ctx.t('numeric only'))) == null ? '' : __t) + ',</span>\n '; } ; __p += '\n '; if (ctx.component.tooltip || ctx.tooltip) { ; __p += '\n <i ref="tooltip" tabindex="0" class="' + ((__t = (ctx.iconClass('question-sign'))) == null ? '' : __t) + ' text-muted" data-tooltip="' + ((__t = (ctx.t(ctx.component.tooltip || ctx.tooltip))) == null ? '' : __t) + '"></i>\n '; } ; __p += '\n</label>\n'; } ; __p += '\n'; return __p }