Skip to content

Instantly share code, notes, and snippets.

@BenevidesLecontes
Created March 28, 2018 14:00
Show Gist options
  • Save BenevidesLecontes/0081b1e39f9b82eb01434d1219ebcefc to your computer and use it in GitHub Desktop.
Save BenevidesLecontes/0081b1e39f9b82eb01434d1219ebcefc to your computer and use it in GitHub Desktop.
import { getDomElementById, scrolltoGivenElementView } from "../../formModelsUtils";
const seguroResidencialFormLudicoInputs = [
{
label: 'Qual o seu CPF?',
name: 'cpf',
type: 'text',
containerClassName: 'col-acel-2',
className: 'form-control big',
isRequired: true,
id: 'clientCPF',
confirmButton: true,
},
{
label: 'Qual o CEP da sua moradia?',
name: 'cep',
type: 'text',
containerClassName: 'col-acel-2',
className: 'form-control big',
isRequired: true,
id: 'clientCep',
confirmButton: true,
},
{
groupTitle: 'Qual tipo de imóvel que você deseja proteger?',
type: 'radio',
containerClassName: 'acel-input-radio',
isRequired: true,
confirmButton: false,
radioGroup: [
{
label: 'Casa',
value: 'Casa',
name: 'question3',
click: (elementId) => {
const element = getDomElementById(elementId);
if (element) {
scrolltoGivenElementView(element);
}
},
id: 'question3-option1',
},
{
label: 'Apartamento',
value: 'Apartamento',
name: 'question3',
click: (elementId) => {
const element = getDomElementById(elementId);
if (element) {
scrolltoGivenElementView(element);
}
},
id: 'question3-option2',
},
{
label: 'Casa em condomínio fechado',
value: 'Casa em condomínio fechado',
name: 'question3',
click: (elementId) => {
const element = getDomElementById(elementId);
if (element) {
scrolltoGivenElementView(element);
}
},
id: 'question3-option3',
},
],
},
{
groupTitle: 'Qual o tipo de construção do imóvel?',
type: 'radio',
containerClassName: 'acel-input-radio',
isRequired: true,
confirmButton: false,
radioGroup: [
{
label: 'Alvenaria',
value: 'Alvenaria',
name: 'question4',
click: (elementId) => {
const element = getDomElementById(elementId);
if (element) {
scrolltoGivenElementView(element);
}
},
id: 'question4-option1',
},
{
label: 'Madeira',
value: 'Madeira',
name: 'question4',
click: (elementId) => {
const element = getDomElementById(elementId);
if (element) {
scrolltoGivenElementView(element);
}
},
id: 'question4-option2',
},
],
},
{
groupTitle: 'Qual a frequência de utilização da casa?',
type: 'radio',
containerClassName: 'acel-input-radio',
isRequired: true,
confirmButton: false,
radioGroup: [
{
label: 'Diariamente',
value: 'Diariamente',
name: 'question5',
click: (elementId) => {
const element = getDomElementById(elementId);
if (element) {
scrolltoGivenElementView(element);
}
},
id: 'question5-option1',
},
{
label: 'Finais de semana/Férias',
value: 'Finais de semana/Férias',
name: 'question5',
click: (elementId) => {
const element = getDomElementById(elementId);
if (element) {
scrolltoGivenElementView(element);
}
},
id: 'question5-option2',
},
],
},
{
groupTitle: 'Pratica ciclismo ou algum outro tipo de esporte?',
type: 'radio',
containerClassName: 'acel-input-radio',
isRequired: true,
confirmButton: false,
radioGroup: [
{
label: 'Ciclismo',
value: 'Ciclismo',
name: 'question8',
click: (elementId) => {
const element = getDomElementById(elementId);
if (element) {
scrolltoGivenElementView(element);
}
},
id: 'question8-option1',
},
{
label: 'Outros esportes',
value: 'Outros esportes',
name: 'question8',
click: (elementId) => {
const element = getDomElementById(elementId);
if (element) {
scrolltoGivenElementView(element);
}
},
id: 'question8-option2',
},
{
label: 'Não pratica',
value: 'Não pratica',
name: 'question8',
click: (elementId) => {
const element = getDomElementById(elementId);
if (element) {
scrolltoGivenElementView(element);
}
},
id: 'question8-option3',
},
],
},
{
groupTitle: 'Possui portas, janelas, sacadas ou box de vidro?',
type: 'radio',
containerClassName: 'acel-input-radio',
isRequired: true,
confirmButton: false,
radioGroup: [
{
label: 'Somente box e janelas',
value: 'somente box e janelas',
name: 'question10',
click: (elementId) => {
const element = getDomElementById(elementId);
if (element) {
scrolltoGivenElementView(element);
}
},
id: 'question10-option1',
},
{
label: 'Box, janelas e sacadas ou portas',
value: 'Box, janelas e sacadas ou portas',
name: 'question10',
click: (elementId) => {
const element = getDomElementById(elementId);
if (element) {
scrolltoGivenElementView(element);
}
},
id: 'question10-option2',
},
{
label: 'Não possuo',
value: 'Não possuo',
name: 'question10',
click: (elementId) => {
const element = getDomElementById(elementId);
if (element) {
scrolltoGivenElementView(element);
}
},
id: 'question10-option3',
},
],
},
{
label: 'No caso de um acidente, quanto você estima que gastaria para reconstruir o imóvel que você mora?',
name: 'accidentExpenses',
type: 'range',
containerClassName: 'container-range',
isRequired: true,
confirmButton: true,
},
{
label: 'Quanto valem seus equipamentos eletro eletrônicos (Linha branca, TV, vídeo-game e informática)?',
name: 'equipments',
type: 'range',
containerClassName: 'container-range',
isRequired: true,
confirmButton: true,
},
{
label: 'Qual o valor da(s) sua(s) bicicleta(s)?',
name: 'bicycleValue',
type: 'range',
containerClassName: 'container-range',
isRequired: true,
confirmButton: true,
},
];
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment