From b5ec6da59e016e6f3f98dcb3ef3925c3fb5338a3 Mon Sep 17 00:00:00 2001 From: Gavin Henderson Date: Sat, 3 Aug 2024 15:30:56 +0100 Subject: [PATCH] Add WIP --- package.json | 3 + src/app/creator/page.js | 20 + src/app/form/[slug]/page.js | 9 +- src/app/page.js | 6 +- src/app/results/[slug]/page.js | 44 + src/components/survey-list-item.js | 15 +- src/data/cancellation.js | 1057 +++++++++++- src/data/index.js | 16 +- src/data/job.js | 203 +-- src/data/medical.js | 2414 +++++++++++++--------------- src/data/nps.js | 1692 +++++++++++++++++-- src/data/patient.js | 968 +++++------ src/data/pizza.js | 538 +++---- src/data/product-feedback.js | 372 ++--- src/generate-fake-results.js | 255 +++ src/utils.js | 3 - yarn.lock | 178 ++ 17 files changed, 5212 insertions(+), 2581 deletions(-) create mode 100644 src/app/creator/page.js create mode 100644 src/app/results/[slug]/page.js create mode 100644 src/generate-fake-results.js delete mode 100644 src/utils.js diff --git a/package.json b/package.json index a9a3606..cef606b 100644 --- a/package.json +++ b/package.json @@ -12,7 +12,10 @@ "next": "14.2.5", "react": "^18", "react-dom": "^18", + "survey-analytics": "^1.11.8", "survey-core": "^1.11.8", + "survey-creator-core": "^1.11.8", + "survey-creator-react": "^1.11.8", "survey-react-ui": "^1.11.8" } } diff --git a/src/app/creator/page.js b/src/app/creator/page.js new file mode 100644 index 0000000..f73abd6 --- /dev/null +++ b/src/app/creator/page.js @@ -0,0 +1,20 @@ +"use client"; + +import { useEffect, useState } from "react"; +import { SurveyCreatorComponent, SurveyCreator } from "survey-creator-react"; +import "survey-core/defaultV2.css"; +import "survey-creator-core/survey-creator-core.css"; + +export default function Page() { + let [creator, setCreator] = useState(); + + useEffect(() => { + const newCreator = new SurveyCreator({ + showLogicTab: true, + showTranslationTab: true, + }); + setCreator(newCreator); + }, []); + + return
{creator && }
; +} diff --git a/src/app/form/[slug]/page.js b/src/app/form/[slug]/page.js index 96f05b4..fa38fef 100644 --- a/src/app/form/[slug]/page.js +++ b/src/app/form/[slug]/page.js @@ -1,16 +1,13 @@ "use client"; -import { slugify } from "@/utils"; import { Model } from "survey-core"; import { Survey } from "survey-react-ui"; import { surveys } from "@/data"; - -import styles from "./page.module.css"; +import "survey-core/defaultV2.css"; export default function Page({ params: { slug } }) { - const survey = surveys.find((x) => slugify(x.title) == slug); - - const model = new Model(survey); + const survey = surveys.find((x) => x.slug === slug); + const model = new Model(survey.survey); return (
diff --git a/src/app/page.js b/src/app/page.js index d1b7563..fd6f7ba 100644 --- a/src/app/page.js +++ b/src/app/page.js @@ -1,13 +1,15 @@ import { surveys } from "@/data"; -import styles from "./page.module.css"; import { SurveyListItem } from "@/components/survey-list-item"; +import Link from "next/link"; +import styles from "./page.module.css"; export default function Home() { return (
+ Create a new survey
    {surveys.map((survey) => { - return ; + return ; })}
diff --git a/src/app/results/[slug]/page.js b/src/app/results/[slug]/page.js new file mode 100644 index 0000000..36f9bf5 --- /dev/null +++ b/src/app/results/[slug]/page.js @@ -0,0 +1,44 @@ +"use client"; + +import { VisualizationPanel } from "survey-analytics"; +import { Model } from "survey-core"; +import "survey-analytics/survey.analytics.min.css"; + +import { surveys } from "@/data"; +import { useEffect, useState } from "react"; + +export default function Page({ params: { slug } }) { + const [survey, setSurvey] = useState(null); + const [vizPanel, setVizPanel] = useState(null); + + useEffect(() => { + const currentSurvey = surveys.find((x) => x.slug == slug); + const survey = new Model(currentSurvey.survey); + setSurvey(survey); + + const currentPanel = new VisualizationPanel( + survey.getAllQuestions(), + currentSurvey.results, + { + allowHideQuestions: false, + } + ); + setVizPanel(currentPanel); + }, [slug]); + + useEffect(() => { + if (vizPanel) { + vizPanel.render("surveyVizPanel"); + } + + return () => { + document.getElementById("surveyVizPanel").innerHTML = ""; + }; + }, [vizPanel]); + + return ( +
+
+
+ ); +} diff --git a/src/components/survey-list-item.js b/src/components/survey-list-item.js index 60633f4..9d7f443 100644 --- a/src/components/survey-list-item.js +++ b/src/components/survey-list-item.js @@ -1,12 +1,19 @@ -import { slugify } from "@/utils"; import Link from "next/link"; export const SurveyListItem = ({ survey }) => { - console.log(survey); return (
-

{survey.title}

- Fill out form +

{survey.survey.title}

+
    +
  • + Fill out form +
  • + {survey.results.length > 0 && ( +
  • + Results +
  • + )} +
); }; diff --git a/src/data/cancellation.js b/src/data/cancellation.js index a514893..5e6da1f 100644 --- a/src/data/cancellation.js +++ b/src/data/cancellation.js @@ -1,92 +1,975 @@ export const cancellation = { - title: "Cancellation Survey", - description: - "Thank you for using our service. We would highly appreciate if you would take the time to fill our cancellation survey. This would help us improve the service.", - pages: [ - { - name: "page1", - elements: [ - { - type: "radiogroup", - name: "using_duration", - title: "How long have you been using the service?", - choices: [ - "Less than a month", - "1-6 months", - "7-12 months", - "1-3 years", - "Over 3 years", - ], - }, - { - type: "radiogroup", - name: "using_frequency", - title: "How often did you use the service?", - choices: [ - "Once a week", - "2 or 3 times a month", - "Once a month", - "Less than once a month", - ], - }, - { - type: "radiogroup", - name: "cancel_reason", - title: "What was the main reason for cancelling the service?", - choices: [ - "No longer need it", - "It didn't meet my needs", - "Found a better alternative", - "Found a cheaper alternative", - "Quality was less than expected", - "Ease of use was less than expected", - "Access to the service was less than expected", - "Customer service was less than expected", - ], - showOtherItem: true, - }, - { - type: "radiogroup", - name: "satisfaction", - title: "Overall, how satisfied were you with the service?", - choices: [ - "Very Satisfied", - "Satisfied", - "Neutral", - "Unsatisfied", - "Very Unsatisfied", - ], - }, - { - type: "matrix", - name: "future_using", - titleLocation: "hidden", - columns: [ - "Definitely", - "Probably", - "Not Sure", - "Probably Not", - "Definitely Not", - ], - rows: [ - { - value: "use_in_future", - text: "Will you use our service in the future?", - }, - { - value: "recommend", - text: "Will you recommend our service to others?", - }, - ], - }, - { - type: "comment", - name: "service_improvements", - title: "How can we improve our service?", - maxLength: 500, - }, + slug: "cancellation-survey", + results: [ + { + using_duration: "7-12 months", + using_frequency: "2 or 3 times a month", + cancel_reason: "Quality was less than expected", + satisfaction: "Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "1-3 years", + using_frequency: "Once a week", + cancel_reason: "Quality was less than expected", + satisfaction: "Neutral", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "1-3 years", + using_frequency: "2 or 3 times a month", + cancel_reason: "Quality was less than expected", + satisfaction: "Neutral", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "1-3 years", + using_frequency: "2 or 3 times a month", + cancel_reason: "Ease of use was less than expected", + satisfaction: "Neutral", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "1-3 years", + using_frequency: "Less than once a month", + cancel_reason: "Quality was less than expected", + satisfaction: "Satisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "7-12 months", + using_frequency: "2 or 3 times a month", + cancel_reason: "Quality was less than expected", + satisfaction: "Very Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "1-6 months", + using_frequency: "Less than once a month", + cancel_reason: "Customer service was less than expected", + satisfaction: "Satisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "7-12 months", + using_frequency: "Once a week", + cancel_reason: "Quality was less than expected", + satisfaction: "Neutral", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "1-6 months", + using_frequency: "Less than once a month", + cancel_reason: "Access to the service was less than expected", + satisfaction: "Satisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Less than a month", + using_frequency: "Less than once a month", + cancel_reason: "Customer service was less than expected", + satisfaction: "Neutral", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "1-6 months", + using_frequency: "Once a week", + cancel_reason: "It didn't meet my needs", + satisfaction: "Very Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "7-12 months", + using_frequency: "2 or 3 times a month", + cancel_reason: "It didn't meet my needs", + satisfaction: "Very Satisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "1-6 months", + using_frequency: "2 or 3 times a month", + cancel_reason: "Customer service was less than expected", + satisfaction: "Neutral", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "7-12 months", + using_frequency: "Once a month", + cancel_reason: "It didn't meet my needs", + satisfaction: "Very Satisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "7-12 months", + using_frequency: "Once a week", + cancel_reason: "Found a better alternative", + satisfaction: "Very Satisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Less than a month", + using_frequency: "2 or 3 times a month", + cancel_reason: "Customer service was less than expected", + satisfaction: "Satisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "7-12 months", + using_frequency: "2 or 3 times a month", + cancel_reason: "No longer need it", + satisfaction: "Very Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Less than a month", + using_frequency: "Once a week", + cancel_reason: "Quality was less than expected", + satisfaction: "Neutral", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "1-6 months", + using_frequency: "Once a month", + cancel_reason: "Found a cheaper alternative", + satisfaction: "Very Satisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Less than a month", + using_frequency: "Less than once a month", + cancel_reason: "Quality was less than expected", + satisfaction: "Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "7-12 months", + using_frequency: "Once a week", + cancel_reason: "No longer need it", + satisfaction: "Neutral", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Over 3 years", + using_frequency: "Once a month", + cancel_reason: "Found a better alternative", + satisfaction: "Very Satisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "1-6 months", + using_frequency: "Once a month", + cancel_reason: "It didn't meet my needs", + satisfaction: "Satisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Over 3 years", + using_frequency: "Less than once a month", + cancel_reason: "Customer service was less than expected", + satisfaction: "Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "1-3 years", + using_frequency: "Less than once a month", + cancel_reason: "Access to the service was less than expected", + satisfaction: "Very Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "7-12 months", + using_frequency: "Once a month", + cancel_reason: "Found a better alternative", + satisfaction: "Very Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Over 3 years", + using_frequency: "Once a month", + cancel_reason: "Access to the service was less than expected", + satisfaction: "Satisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Over 3 years", + using_frequency: "Once a month", + cancel_reason: "Found a cheaper alternative", + satisfaction: "Very Satisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Less than a month", + using_frequency: "Once a month", + cancel_reason: "Ease of use was less than expected", + satisfaction: "Very Satisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Over 3 years", + using_frequency: "Once a week", + cancel_reason: "No longer need it", + satisfaction: "Neutral", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "7-12 months", + using_frequency: "Once a month", + cancel_reason: "Access to the service was less than expected", + satisfaction: "Neutral", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "1-6 months", + using_frequency: "2 or 3 times a month", + cancel_reason: "Quality was less than expected", + satisfaction: "Neutral", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Less than a month", + using_frequency: "Once a week", + cancel_reason: "It didn't meet my needs", + satisfaction: "Very Satisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "1-6 months", + using_frequency: "Once a week", + cancel_reason: "Quality was less than expected", + satisfaction: "Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Less than a month", + using_frequency: "Once a week", + cancel_reason: "Found a better alternative", + satisfaction: "Satisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "7-12 months", + using_frequency: "2 or 3 times a month", + cancel_reason: "It didn't meet my needs", + satisfaction: "Very Satisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Over 3 years", + using_frequency: "Once a month", + cancel_reason: "It didn't meet my needs", + satisfaction: "Very Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Less than a month", + using_frequency: "Once a month", + cancel_reason: "Quality was less than expected", + satisfaction: "Neutral", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Less than a month", + using_frequency: "Once a month", + cancel_reason: "It didn't meet my needs", + satisfaction: "Very Satisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "1-6 months", + using_frequency: "Once a week", + cancel_reason: "Found a better alternative", + satisfaction: "Very Satisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "1-6 months", + using_frequency: "Once a week", + cancel_reason: "Quality was less than expected", + satisfaction: "Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Less than a month", + using_frequency: "Once a week", + cancel_reason: "No longer need it", + satisfaction: "Neutral", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Over 3 years", + using_frequency: "Once a week", + cancel_reason: "Quality was less than expected", + satisfaction: "Satisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Less than a month", + using_frequency: "2 or 3 times a month", + cancel_reason: "No longer need it", + satisfaction: "Very Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Less than a month", + using_frequency: "Once a month", + cancel_reason: "No longer need it", + satisfaction: "Neutral", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Less than a month", + using_frequency: "Once a month", + cancel_reason: "No longer need it", + satisfaction: "Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "1-3 years", + using_frequency: "Once a week", + cancel_reason: "No longer need it", + satisfaction: "Very Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "1-3 years", + using_frequency: "Once a month", + cancel_reason: "Ease of use was less than expected", + satisfaction: "Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Less than a month", + using_frequency: "Once a week", + cancel_reason: "No longer need it", + satisfaction: "Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Over 3 years", + using_frequency: "Once a month", + cancel_reason: "Ease of use was less than expected", + satisfaction: "Satisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "1-3 years", + using_frequency: "Once a week", + cancel_reason: "Access to the service was less than expected", + satisfaction: "Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Less than a month", + using_frequency: "Once a week", + cancel_reason: "It didn't meet my needs", + satisfaction: "Very Satisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Less than a month", + using_frequency: "Once a week", + cancel_reason: "Quality was less than expected", + satisfaction: "Very Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Less than a month", + using_frequency: "Once a week", + cancel_reason: "Quality was less than expected", + satisfaction: "Neutral", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Over 3 years", + using_frequency: "Less than once a month", + cancel_reason: "Ease of use was less than expected", + satisfaction: "Very Satisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Over 3 years", + using_frequency: "Less than once a month", + cancel_reason: "Found a cheaper alternative", + satisfaction: "Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Over 3 years", + using_frequency: "2 or 3 times a month", + cancel_reason: "Found a cheaper alternative", + satisfaction: "Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "7-12 months", + using_frequency: "Once a month", + cancel_reason: "Found a better alternative", + satisfaction: "Neutral", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Over 3 years", + using_frequency: "2 or 3 times a month", + cancel_reason: "Found a cheaper alternative", + satisfaction: "Very Satisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "1-3 years", + using_frequency: "Once a month", + cancel_reason: "Found a cheaper alternative", + satisfaction: "Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "1-3 years", + using_frequency: "Less than once a month", + cancel_reason: "Ease of use was less than expected", + satisfaction: "Satisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Less than a month", + using_frequency: "Less than once a month", + cancel_reason: "Found a cheaper alternative", + satisfaction: "Very Satisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Over 3 years", + using_frequency: "2 or 3 times a month", + cancel_reason: "Found a cheaper alternative", + satisfaction: "Very Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "7-12 months", + using_frequency: "Once a month", + cancel_reason: "Access to the service was less than expected", + satisfaction: "Neutral", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Over 3 years", + using_frequency: "Less than once a month", + cancel_reason: "Access to the service was less than expected", + satisfaction: "Very Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Less than a month", + using_frequency: "2 or 3 times a month", + cancel_reason: "Found a better alternative", + satisfaction: "Very Satisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "1-6 months", + using_frequency: "Once a week", + cancel_reason: "Ease of use was less than expected", + satisfaction: "Very Satisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Over 3 years", + using_frequency: "Less than once a month", + cancel_reason: "Quality was less than expected", + satisfaction: "Very Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "1-3 years", + using_frequency: "Less than once a month", + cancel_reason: "Access to the service was less than expected", + satisfaction: "Very Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "7-12 months", + using_frequency: "2 or 3 times a month", + cancel_reason: "Access to the service was less than expected", + satisfaction: "Very Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "7-12 months", + using_frequency: "Less than once a month", + cancel_reason: "Quality was less than expected", + satisfaction: "Very Satisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Less than a month", + using_frequency: "Once a week", + cancel_reason: "Quality was less than expected", + satisfaction: "Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "1-6 months", + using_frequency: "2 or 3 times a month", + cancel_reason: "Found a cheaper alternative", + satisfaction: "Neutral", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "1-6 months", + using_frequency: "2 or 3 times a month", + cancel_reason: "Customer service was less than expected", + satisfaction: "Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "1-3 years", + using_frequency: "2 or 3 times a month", + cancel_reason: "Customer service was less than expected", + satisfaction: "Satisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "7-12 months", + using_frequency: "2 or 3 times a month", + cancel_reason: "Customer service was less than expected", + satisfaction: "Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "1-6 months", + using_frequency: "Once a week", + cancel_reason: "Ease of use was less than expected", + satisfaction: "Very Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Over 3 years", + using_frequency: "Once a month", + cancel_reason: "Access to the service was less than expected", + satisfaction: "Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "7-12 months", + using_frequency: "Once a week", + cancel_reason: "Ease of use was less than expected", + satisfaction: "Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "1-3 years", + using_frequency: "Once a week", + cancel_reason: "Quality was less than expected", + satisfaction: "Very Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Over 3 years", + using_frequency: "Less than once a month", + cancel_reason: "Found a cheaper alternative", + satisfaction: "Neutral", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Less than a month", + using_frequency: "Less than once a month", + cancel_reason: "Customer service was less than expected", + satisfaction: "Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "1-6 months", + using_frequency: "Less than once a month", + cancel_reason: "Found a cheaper alternative", + satisfaction: "Neutral", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "7-12 months", + using_frequency: "2 or 3 times a month", + cancel_reason: "Ease of use was less than expected", + satisfaction: "Very Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Less than a month", + using_frequency: "Less than once a month", + cancel_reason: "Found a cheaper alternative", + satisfaction: "Very Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "7-12 months", + using_frequency: "Once a week", + cancel_reason: "Access to the service was less than expected", + satisfaction: "Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Over 3 years", + using_frequency: "2 or 3 times a month", + cancel_reason: "Found a better alternative", + satisfaction: "Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "1-3 years", + using_frequency: "Once a month", + cancel_reason: "Found a better alternative", + satisfaction: "Very Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Over 3 years", + using_frequency: "2 or 3 times a month", + cancel_reason: "Found a better alternative", + satisfaction: "Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "1-3 years", + using_frequency: "Less than once a month", + cancel_reason: "Customer service was less than expected", + satisfaction: "Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Over 3 years", + using_frequency: "2 or 3 times a month", + cancel_reason: "Found a better alternative", + satisfaction: "Satisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Less than a month", + using_frequency: "Once a week", + cancel_reason: "Quality was less than expected", + satisfaction: "Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Less than a month", + using_frequency: "Once a week", + cancel_reason: "Customer service was less than expected", + satisfaction: "Very Satisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "Less than a month", + using_frequency: "Once a week", + cancel_reason: "No longer need it", + satisfaction: "Very Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "7-12 months", + using_frequency: "Once a month", + cancel_reason: "No longer need it", + satisfaction: "Very Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "1-3 years", + using_frequency: "Less than once a month", + cancel_reason: "Found a cheaper alternative", + satisfaction: "Satisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "7-12 months", + using_frequency: "Once a month", + cancel_reason: "Ease of use was less than expected", + satisfaction: "Unsatisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "1-3 years", + using_frequency: "Once a month", + cancel_reason: "Found a cheaper alternative", + satisfaction: "Very Satisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "1-3 years", + using_frequency: "Once a week", + cancel_reason: "Customer service was less than expected", + satisfaction: "Satisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", + ], + }, + { + using_duration: "7-12 months", + using_frequency: "Once a month", + cancel_reason: "Found a better alternative", + satisfaction: "Satisfied", + service_improvements: [ + "The service is great, i highly recommend you use it.", ], }, ], - showQuestionNumbers: "off", + survey: { + title: "Cancellation Survey", + description: + "Thank you for using our service. We would highly appreciate if you would take the time to fill our cancellation survey. This would help us improve the service.", + pages: [ + { + name: "page1", + elements: [ + { + type: "radiogroup", + name: "using_duration", + title: "How long have you been using the service?", + choices: [ + "Less than a month", + "1-6 months", + "7-12 months", + "1-3 years", + "Over 3 years", + ], + }, + { + type: "radiogroup", + name: "using_frequency", + title: "How often did you use the service?", + choices: [ + "Once a week", + "2 or 3 times a month", + "Once a month", + "Less than once a month", + ], + }, + { + type: "radiogroup", + name: "cancel_reason", + title: "What was the main reason for cancelling the service?", + choices: [ + "No longer need it", + "It didn't meet my needs", + "Found a better alternative", + "Found a cheaper alternative", + "Quality was less than expected", + "Ease of use was less than expected", + "Access to the service was less than expected", + "Customer service was less than expected", + ], + showOtherItem: true, + }, + { + type: "radiogroup", + name: "satisfaction", + title: "Overall, how satisfied were you with the service?", + choices: [ + "Very Satisfied", + "Satisfied", + "Neutral", + "Unsatisfied", + "Very Unsatisfied", + ], + }, + { + type: "comment", + name: "service_improvements", + title: "How can we improve our service?", + maxLength: 500, + }, + ], + }, + ], + showQuestionNumbers: "off", + }, }; diff --git a/src/data/index.js b/src/data/index.js index 3efa99e..17e6f5b 100644 --- a/src/data/index.js +++ b/src/data/index.js @@ -7,11 +7,11 @@ import { pizza } from "./pizza"; import { productFeedback } from "./product-feedback"; export const surveys = [ - nps, - cancellation, - productFeedback, - medical, - pizza, - patient, - job -] \ No newline at end of file + nps, + cancellation, + productFeedback, + medical, + pizza, + patient, + job, +]; diff --git a/src/data/job.js b/src/data/job.js index 8742a62..b66d7bf 100644 --- a/src/data/job.js +++ b/src/data/job.js @@ -1,138 +1,143 @@ export const job = { - "title": "Job Application Form", - "description": "Thank you for your interest in working with us. Please fill out the form and send your application. We will get back to you within a week.", - "logo": "https://api.surveyjs.io/private/Surveys/files?name=b4b071f2-c1f1-4887-a1de-8323825141b6", - "logoHeight": "100px", - "logoFit": "cover", - "logoPosition": "right", - "pages": [ + slug: "job", + results: [], + survey: { + title: "Job Application Form", + description: + "Thank you for your interest in working with us. Please fill out the form and send your application. We will get back to you within a week.", + logo: "https://api.surveyjs.io/private/Surveys/files?name=b4b071f2-c1f1-4887-a1de-8323825141b6", + logoHeight: "100px", + logoFit: "cover", + logoPosition: "right", + pages: [ { - "name": "page1", - "elements": [ + name: "page1", + elements: [ { - "type": "panel", - "name": "personal-info", - "title": "Personal Information", - "elements": [ + type: "panel", + name: "personal-info", + title: "Personal Information", + elements: [ { - "type": "text", - "name": "first-name", - "title": "First name", - "isRequired": true + type: "text", + name: "first-name", + title: "First name", + isRequired: true, }, { - "type": "text", - "name": "last-name", - "startWithNewLine": false, - "title": "Last name", - "isRequired": true + type: "text", + name: "last-name", + startWithNewLine: false, + title: "Last name", + isRequired: true, }, { - "type": "text", - "name": "birthdate", - "title": "Date of birth", - "isRequired": true, - "inputType": "date" - } - ] + type: "text", + name: "birthdate", + title: "Date of birth", + isRequired: true, + inputType: "date", + }, + ], }, { - "type": "panel", - "name": "location", - "title": "Your Location", - "elements": [ + type: "panel", + name: "location", + title: "Your Location", + elements: [ { - "type": "dropdown", - "name": "country", - "title": "Country", - "choicesByUrl": { - "url": "https://surveyjs.io/api/CountriesExample" - } + type: "dropdown", + name: "country", + title: "Country", + choicesByUrl: { + url: "https://surveyjs.io/api/CountriesExample", + }, }, { - "type": "text", - "name": "city", - "title": "City/Town" + type: "text", + name: "city", + title: "City/Town", }, { - "type": "text", - "name": "zip", - "startWithNewLine": false, - "title": "Zip code", - "validators": [ + type: "text", + name: "zip", + startWithNewLine: false, + title: "Zip code", + validators: [ { - "type": "numeric" - } + type: "numeric", + }, ], - "inputType": "number" + inputType: "number", }, { - "type": "text", - "name": "address", - "title": "Street address" - } - ] + type: "text", + name: "address", + title: "Street address", + }, + ], }, { - "type": "text", - "name": "email", - "title": "Email", - "inputType": "email", - "placeholder": "mail@example.com" + type: "text", + name: "email", + title: "Email", + inputType: "email", + placeholder: "mail@example.com", }, { - "type": "text", - "name": "salary", - "title": "Expected salary (in US dollars)", - "validators": [ + type: "text", + name: "salary", + title: "Expected salary (in US dollars)", + validators: [ { - "type": "numeric" - } + type: "numeric", + }, ], - "inputType": "number" + inputType: "number", }, { - "type": "dropdown", - "name": "position", - "title": "What position are you applying for?", - "choices": [ + type: "dropdown", + name: "position", + title: "What position are you applying for?", + choices: [ { - "value": "frontend", - "text": "Frontend Developer" + value: "frontend", + text: "Frontend Developer", }, { - "value": "backend", - "text": "Backend Developer" + value: "backend", + text: "Backend Developer", }, { - "value": "fullstack", - "text": "Full-Stack Developer" + value: "fullstack", + text: "Full-Stack Developer", }, { - "value": "intern", - "text": "Intern" - } - ] + value: "intern", + text: "Intern", + }, + ], }, { - "type": "text", - "name": "start-date", - "title": "Date available to start work", - "isRequired": true, - "inputType": "date" + type: "text", + name: "start-date", + title: "Date available to start work", + isRequired: true, + inputType: "date", }, { - "type": "file", - "name": "resume", - "title": "Upload your resume", - "acceptedTypes": "application/pdf" - } - ] - } + type: "file", + name: "resume", + title: "Upload your resume", + acceptedTypes: "application/pdf", + }, + ], + }, ], - "showQuestionNumbers": "off", - "questionErrorLocation": "bottom", - "completeText": "Send", - "widthMode": "static", - "width": "800px" - } \ No newline at end of file + showQuestionNumbers: "off", + questionErrorLocation: "bottom", + completeText: "Send", + widthMode: "static", + width: "800px", + }, +}; diff --git a/src/data/medical.js b/src/data/medical.js index bcd7c3f..4bdd5e8 100644 --- a/src/data/medical.js +++ b/src/data/medical.js @@ -1,256 +1,257 @@ +export const medicalResults = []; + export const medical = { - "title": "Patient Past Medical, Social & Family History", - "pages": [ + slug: "medical", + results: [], + survey: { + title: "Patient Past Medical, Social & Family History", + pages: [ { - "name": "introduction", - "title": "Introduction", - "elements": [ + name: "introduction", + title: "Introduction", + elements: [ { - "type": "panel", - "name": "patienName", - "questionTitleLocation": "bottom", - "title": "Patient Name", - "elements": [ - { - "type": "text", - "name": "patientLastName", - "title": "(Last)", - "isRequired": true - }, - { - "type": "text", - "name": "patienFirstName", - "startWithNewLine": false, - "title": "(First)", - "isRequired": true - }, - { - "type": "text", - "name": "patientMiddleName", - "title": "(M.I)" - } - ] + type: "panel", + name: "patienName", + questionTitleLocation: "bottom", + title: "Patient Name", + elements: [ + { + type: "text", + name: "patientLastName", + title: "(Last)", + isRequired: true, + }, + { + type: "text", + name: "patienFirstName", + startWithNewLine: false, + title: "(First)", + isRequired: true, + }, + { + type: "text", + name: "patientMiddleName", + title: "(M.I)", + }, + ], }, { - "type": "panel", - "name": "panel2", - "questionTitleLocation": "left", - "title": "Social Security & Birth Date", - "elements": [ - { - "type": "text", - "name": "socialsecurity", - "title": "Social Security #:", - "isRequired": true - }, - { - "type": "text", - "name": "birthDate", - "startWithNewLine": false, - "title": "Date of birth:", - "isRequired": true, - "inputType": "date" - }, - { - "type": "radiogroup", - "name": "sex", - "title": "Sex:", - "isRequired": true, - "choices": [ + type: "panel", + name: "panel2", + questionTitleLocation: "left", + title: "Social Security & Birth Date", + elements: [ + { + type: "text", + name: "socialsecurity", + title: "Social Security #:", + isRequired: true, + }, + { + type: "text", + name: "birthDate", + startWithNewLine: false, + title: "Date of birth:", + isRequired: true, + inputType: "date", + }, + { + type: "radiogroup", + name: "sex", + title: "Sex:", + isRequired: true, + choices: [ { - "value": "male", - "text": "Male" + value: "male", + text: "Male", }, { - "value": "female", - "text": "Female" - } + value: "female", + text: "Female", + }, ], - "colCount": 0 - } - ] + colCount: 0, + }, + ], }, { - "type": "panel", - "name": "panel1", - "title": "Completed By", - "elements": [ - { - "type": "radiogroup", - "name": "completedBy", - "title": "Who completed this form:", - "isRequired": true, - "choices": [ + type: "panel", + name: "panel1", + title: "Completed By", + elements: [ + { + type: "radiogroup", + name: "completedBy", + title: "Who completed this form:", + isRequired: true, + choices: [ { - "value": "patient", - "text": "Patient" + value: "patient", + text: "Patient", }, { - "value": "spouse", - "text": "Spouse" - } + value: "spouse", + text: "Spouse", + }, ], - "showOtherItem": true, - "otherText": "Other (specify)", - "colCount": 0 - }, - { - "type": "text", - "name": "completedByOtherName", - "visibleIf": "{completedBy} != \"patient\"", - "startWithNewLine": false, - "title": "Name (if other than patient):", - "isRequired": true - } - ] - } - ] + showOtherItem: true, + otherText: "Other (specify)", + colCount: 0, + }, + { + type: "text", + name: "completedByOtherName", + visibleIf: '{completedBy} != "patient"', + startWithNewLine: false, + title: "Name (if other than patient):", + isRequired: true, + }, + ], + }, + ], }, { - "name": "medicalHistory", - "questionTitleLocation": "left", - "title": "Past Medical History", - "elements": [ + name: "medicalHistory", + questionTitleLocation: "left", + title: "Past Medical History", + elements: [ { - "type": "radiogroup", - "name": "everhospitalized", - "title": "Have you ever been hospitalized?", - "isRequired": true, - "choices": [ - { - "value": "no", - "text": "No" + type: "radiogroup", + name: "everhospitalized", + title: "Have you ever been hospitalized?", + isRequired: true, + choices: [ + { + value: "no", + text: "No", }, { - "value": "yes", - "text": "Yes" - } + value: "yes", + text: "Yes", + }, ], - "colCount": 0 + colCount: 0, }, { - "type": "radiogroup", - "name": "injuriesbrokenbones", - "title": "Have you had any serious injuries and/or broken bones?", - "isRequired": true, - "choices": [ - { - "value": "no", - "text": "No" + type: "radiogroup", + name: "injuriesbrokenbones", + title: "Have you had any serious injuries and/or broken bones?", + isRequired: true, + choices: [ + { + value: "no", + text: "No", }, { - "value": "yes", - "text": "Yes" - } + value: "yes", + text: "Yes", + }, ], - "colCount": 0 + colCount: 0, }, { - "type": "comment", - "name": "injuriesbrokenbones_describe", - "visible": false, - "visibleIf": "{injuriesbrokenbones} = \"yes\"", - "startWithNewLine": false, - "title": "Describe", - "isRequired": true + type: "comment", + name: "injuriesbrokenbones_describe", + visible: false, + visibleIf: '{injuriesbrokenbones} = "yes"', + startWithNewLine: false, + title: "Describe", + isRequired: true, }, { - "type": "radiogroup", - "name": "bloodtransfusion", - "title": "Have you ever received a blood transfusion?", - "isRequired": true, - "choices": [ - { - "value": "unknown", - "text": "Unknown" + type: "radiogroup", + name: "bloodtransfusion", + title: "Have you ever received a blood transfusion?", + isRequired: true, + choices: [ + { + value: "unknown", + text: "Unknown", }, { - "value": "no", - "text": "No" + value: "no", + text: "No", }, { - "value": "yes", - "text": "Yes" - } + value: "yes", + text: "Yes", + }, ], - "colCount": 0 + colCount: 0, }, { - "type": "text", - "name": "bloodtransfusion_years", - "visible": false, - "visibleIf": "{bloodtransfusion}=\"yes\"", - "startWithNewLine": false, - "title": "Approximate year(s)" + type: "text", + name: "bloodtransfusion_years", + visible: false, + visibleIf: '{bloodtransfusion}="yes"', + startWithNewLine: false, + title: "Approximate year(s)", }, { - "type": "radiogroup", - "name": "ousideUSACanada", - "title": "Have you ever traveled or lived outside the United States or Canada?", - "isRequired": true, - "choices": [ - { - "value": "no", - "text": "No" + type: "radiogroup", + name: "ousideUSACanada", + title: + "Have you ever traveled or lived outside the United States or Canada?", + isRequired: true, + choices: [ + { + value: "no", + text: "No", }, { - "value": "yes", - "text": "Yes" - } + value: "yes", + text: "Yes", + }, ], - "colCount": 0 + colCount: 0, }, { - "type": "comment", - "name": "ousideUSACanada_describe", - "visible": false, - "visibleIf": "{ousideUSACanada} = \"yes\"", - "startWithNewLine": false, - "title": "Describe", - "isRequired": true + type: "comment", + name: "ousideUSACanada_describe", + visible: false, + visibleIf: '{ousideUSACanada} = "yes"', + startWithNewLine: false, + title: "Describe", + isRequired: true, }, { - "type": "matrixdropdown", - "name": "immunizations", - "title": "Have you received the following IMMUNIZATIONS? If yes, indicate the approximate year it was last given:", - "titleLocation": "top", - "columns": [ - { - "name": "answer", - "title": "Please select", - "cellType": "radiogroup", - "isRequired": true, - "choices": [ + type: "matrixdropdown", + name: "immunizations", + title: + "Have you received the following IMMUNIZATIONS? If yes, indicate the approximate year it was last given:", + titleLocation: "top", + columns: [ + { + name: "answer", + title: "Please select", + cellType: "radiogroup", + isRequired: true, + choices: [ { - "value": "unknown", - "text": "Unknown" + value: "unknown", + text: "Unknown", }, { - "value": "no", - "text": "No" + value: "no", + text: "No", }, { - "value": "yes", - "text": "Yes" - } - ] - }, - { - "name": "year", - "title": "Year", - "cellType": "text", - "isRequired": true, - "visibleIf": "{row.answer} = \"yes\"" - } - ], - "choices": [ - 1, - 2, - 3, - 4, - 5 + value: "yes", + text: "Yes", + }, + ], + }, + { + name: "year", + title: "Year", + cellType: "text", + isRequired: true, + visibleIf: '{row.answer} = "yes"', + }, ], - "rows": [ + choices: [1, 2, 3, 4, 5], + rows: [ "Pneumococcal (for pneumonia)", "Hepatitis A", "Hepatitis B", @@ -259,20 +260,20 @@ export const medical = { "Measles", "Mumps", "Rubella", - "Polio" - ] + "Polio", + ], }, { - "type": "matrixdynamic", - "name": "problems1", - "title": "Have you ever had any of the following?", - "titleLocation": "top", - "columns": [ - { - "name": "problem", - "title": "Problem", - "cellType": "dropdown", - "choices": [ + type: "matrixdynamic", + name: "problems1", + title: "Have you ever had any of the following?", + titleLocation: "top", + columns: [ + { + name: "problem", + title: "Problem", + cellType: "dropdown", + choices: [ "Abnormal chest x-ray", "Anesthesia complications", "Anxiety, depression or mental illness", @@ -285,55 +286,50 @@ export const medical = { "Stroke or TIA", "Treatment for alcohol and/or drug abuse", "Tuberculosis or positive tuberculin skin test", - "Cosmetic or plastic surgery" - ] + "Cosmetic or plastic surgery", + ], }, { - "name": "answer", - "title": "Please answer", - "cellType": "radiogroup", - "isRequired": true, - "choices": [ + name: "answer", + title: "Please answer", + cellType: "radiogroup", + isRequired: true, + choices: [ { - "value": "no", - "text": "No" + value: "no", + text: "No", }, { - "value": "yes", - "text": "Yes" - } - ] - }, - { - "name": "description", - "title": "Describe the problem", - "cellType": "comment", - "isRequired": true, - "visibleIf": "{row.answer} = \"yes\"" - } - ], - "choices": [ - 1, - 2, - 3, - 4, - 5 + value: "yes", + text: "Yes", + }, + ], + }, + { + name: "description", + title: "Describe the problem", + cellType: "comment", + isRequired: true, + visibleIf: '{row.answer} = "yes"', + }, ], - "rowCount": 1 + choices: [1, 2, 3, 4, 5], + rowCount: 1, }, { - "type": "matrixdynamic", - "name": "problems2", - "title": "Indicate whether you have ever had a medical problem and/or surgery related to each of the following", - "titleLocation": "top", - "columns": [ - { - "name": "problem", - "title": "Problem", - "cellType": "dropdown", - "isRequired": true, - "maxWidth": "300px", - "choices": [ + type: "matrixdynamic", + name: "problems2", + title: + "Indicate whether you have ever had a medical problem and/or surgery related to each of the following", + titleLocation: "top", + columns: [ + { + name: "problem", + title: "Problem", + cellType: "dropdown", + isRequired: true, + maxWidth: "300px", + choices: [ "Eyes (cataracts, glaucoma)", "Ears, nose, sinuses, or tonsils", "Thyroid or parathyroid glands", @@ -355,451 +351,403 @@ export const medical = { "Breasts", "Females: uterus, tubes, ovaries", "Males: prostate, penis, testes, vasectomy", - "Other: Describe" + "Other: Describe", ], - "choicesOrder": "asc" + choicesOrder: "asc", }, { - "name": "type", - "title": "Type", - "cellType": "checkbox", - "isRequired": true, - "choices": [ + name: "type", + title: "Type", + cellType: "checkbox", + isRequired: true, + choices: [ { - "value": "medical", - "text": "Medical Problem" + value: "medical", + text: "Medical Problem", }, { - "value": "surgery", - "text": "Surgery" - } - ] + value: "surgery", + text: "Surgery", + }, + ], }, { - "name": "year", - "title": "Year(s) of Surgery", - "cellType": "text", - "isRequired": true, - "visibleIf": "{row.type} contains \"surgery\"" + name: "year", + title: "Year(s) of Surgery", + cellType: "text", + isRequired: true, + visibleIf: '{row.type} contains "surgery"', }, { - "name": "describe", - "title": "Describe", - "cellType": "comment", - "isRequired": true - } - ], - "choices": [ - 1, - 2, - 3, - 4, - 5 + name: "describe", + title: "Describe", + cellType: "comment", + isRequired: true, + }, ], - "rowCount": 1, - "addRowText": "Add Problem" - } - ] + choices: [1, 2, 3, 4, 5], + rowCount: 1, + addRowText: "Add Problem", + }, + ], }, { - "name": "socialHistory", - "questionTitleLocation": "left", - "title": "Social History", - "elements": [ + name: "socialHistory", + questionTitleLocation: "left", + title: "Social History", + elements: [ { - "type": "panel", - "name": "education", - "title": "Education", - "elements": [ - { - "type": "dropdown", - "name": "schoolYearsCompleted", - "title": "How many yeas of school have you completed?", - "isRequired": true, - "choicesMax": 12 - } - ] + type: "panel", + name: "education", + title: "Education", + elements: [ + { + type: "dropdown", + name: "schoolYearsCompleted", + title: "How many yeas of school have you completed?", + isRequired: true, + choicesMax: 12, + }, + ], }, { - "type": "panel", - "name": "occupations", - "title": "Occupations", - "elements": [ - { - "type": "radiogroup", - "name": "employmentStatus", - "title": "Your current employment status:", - "isRequired": true, - "choices": [ - "Retired", - "Unemployed", - "Homemaker", - "Employed" - ], - "colCount": 0 + type: "panel", + name: "occupations", + title: "Occupations", + elements: [ + { + type: "radiogroup", + name: "employmentStatus", + title: "Your current employment status:", + isRequired: true, + choices: ["Retired", "Unemployed", "Homemaker", "Employed"], + colCount: 0, }, { - "type": "text", - "name": "currentOcupation", - "visible": false, - "visibleIf": "{employmentStatus} = 'Employed'", - "title": "Current Ocupation(s):", - "isRequired": true + type: "text", + name: "currentOcupation", + visible: false, + visibleIf: "{employmentStatus} = 'Employed'", + title: "Current Ocupation(s):", + isRequired: true, }, { - "type": "comment", - "name": "previousOccupations", - "title": "Previous Occupations/Jobs:" - } - ] + type: "comment", + name: "previousOccupations", + title: "Previous Occupations/Jobs:", + }, + ], }, { - "type": "panel", - "name": "disability", - "title": "Disability", - "elements": [ - { - "type": "radiogroup", - "name": "disabled", - "title": "Are you disabled?", - "isRequired": true, - "choices": [ - "No", - "Yes" - ], - "colCount": 0 + type: "panel", + name: "disability", + title: "Disability", + elements: [ + { + type: "radiogroup", + name: "disabled", + title: "Are you disabled?", + isRequired: true, + choices: ["No", "Yes"], + colCount: 0, }, { - "type": "comment", - "name": "disableInfo", - "visible": false, - "visibleIf": "{disabled} = 'Yes'", - "title": "Info:" - } - ] + type: "comment", + name: "disableInfo", + visible: false, + visibleIf: "{disabled} = 'Yes'", + title: "Info:", + }, + ], }, { - "type": "panel", - "name": "abuse", - "title": "Abuse", - "elements": [ - { - "type": "radiogroup", - "name": "abused", - "title": "Have you even been physically, sexually, or emotionally abused?", - "isRequired": true, - "choices": [ - "No", - "Yes" - ], - "colCount": 0 + type: "panel", + name: "abuse", + title: "Abuse", + elements: [ + { + type: "radiogroup", + name: "abused", + title: + "Have you even been physically, sexually, or emotionally abused?", + isRequired: true, + choices: ["No", "Yes"], + colCount: 0, }, { - "type": "comment", - "name": "abusedInfo", - "visible": false, - "visibleIf": "{abused} = 'Yes'", - "title": "Info:" + type: "comment", + name: "abusedInfo", + visible: false, + visibleIf: "{abused} = 'Yes'", + title: "Info:", }, { - "type": "matrixdropdown", - "name": "subsctancesUsing", - "title": "Have you used any of the following substances?", - "titleLocation": "top", - "columns": [ + type: "matrixdropdown", + name: "subsctancesUsing", + title: "Have you used any of the following substances?", + titleLocation: "top", + columns: [ { - "name": "current", - "title": "Currently Use?", - "cellType": "radiogroup", - "isRequired": true, - "width": "200px", - "choices": [ - "No", - "Yes" - ] + name: "current", + title: "Currently Use?", + cellType: "radiogroup", + isRequired: true, + width: "200px", + choices: ["No", "Yes"], }, { - "name": "previous", - "title": "Previously Used?", - "cellType": "radiogroup", - "isRequired": true, - "width": "200px", - "choices": [ - "No", - "Yes" - ] + name: "previous", + title: "Previously Used?", + cellType: "radiogroup", + isRequired: true, + width: "200px", + choices: ["No", "Yes"], }, { - "name": "amount", - "title": "Type/Amount/Frequancy", - "cellType": "text", - "isRequired": true, - "width": "200px", - "visibleIf": "{row.current} = 'Yes' or {row.previous} = 'Yes'" + name: "amount", + title: "Type/Amount/Frequancy", + cellType: "text", + isRequired: true, + width: "200px", + visibleIf: + "{row.current} = 'Yes' or {row.previous} = 'Yes'", }, { - "name": "long", - "title": "How Long? (Years)", - "cellType": "text", - "isRequired": true, - "width": "200px", - "visibleIf": "{row.current} = 'Yes' or {row.previous} = 'Yes'" + name: "long", + title: "How Long? (Years)", + cellType: "text", + isRequired: true, + width: "200px", + visibleIf: + "{row.current} = 'Yes' or {row.previous} = 'Yes'", }, { - "name": "stopped", - "title": "When stopped? (Year)", - "cellType": "text", - "isRequired": true, - "width": "200px", - "visibleIf": "{row.previous} = 'Yes'" - } - ], - "choices": [ - 1, - 2, - 3, - 4, - 5 + name: "stopped", + title: "When stopped? (Year)", + cellType: "text", + isRequired: true, + width: "200px", + visibleIf: "{row.previous} = 'Yes'", + }, ], - "rows": [ + choices: [1, 2, 3, 4, 5], + rows: [ "Caffeine: coffee, tea, soda", "Tobacco", "Alcohol - bear, wine, liquor", - "Recreational/Street drugs" + "Recreational/Street drugs", ], - "rowTitleWidth": "200px" - } - ] + rowTitleWidth: "200px", + }, + ], }, { - "type": "panel", - "name": "maritalStatus", - "title": "Marital Status", - "elements": [ - { - "type": "radiogroup", - "name": "currentlyMarried", - "title": "Are you currently married?", - "isRequired": true, - "choices": [ - "No", - "Yes" - ], - "colCount": 0 + type: "panel", + name: "maritalStatus", + title: "Marital Status", + elements: [ + { + type: "radiogroup", + name: "currentlyMarried", + title: "Are you currently married?", + isRequired: true, + choices: ["No", "Yes"], + colCount: 0, }, { - "type": "text", - "name": "currentMarriageYear", - "visible": false, - "visibleIf": "{currentlyMarried} = 'Yes'", - "startWithNewLine": false, - "title": "In what year did this marriage occure?", - "isRequired": true + type: "text", + name: "currentMarriageYear", + visible: false, + visibleIf: "{currentlyMarried} = 'Yes'", + startWithNewLine: false, + title: "In what year did this marriage occure?", + isRequired: true, }, { - "type": "paneldynamic", - "name": "previousMarriages", - "title": "List all previous marriages", - "templateElements": [ + type: "paneldynamic", + name: "previousMarriages", + title: "List all previous marriages", + templateElements: [ { - "type": "text", - "name": "previousMarriageYear", - "title": "Year married:", - "isRequired": true + type: "text", + name: "previousMarriageYear", + title: "Year married:", + isRequired: true, }, { - "type": "text", - "name": "previousMarriageDuration", - "startWithNewLine": false, - "title": "Duration (in Years):", - "isRequired": true - } + type: "text", + name: "previousMarriageDuration", + startWithNewLine: false, + title: "Duration (in Years):", + isRequired: true, + }, ], - "panelCount": 1, - "panelAddText": "Add marriage" + panelCount: 1, + panelAddText: "Add marriage", }, { - "type": "panel", - "name": "currentSpouse", - "title": "Current Spouse Information", - "elements": [ + type: "panel", + name: "currentSpouse", + title: "Current Spouse Information", + elements: [ { - "type": "radiogroup", - "name": "currentSpouseStatus", - "title": " ", - "isRequired": true, - "choices": [ - "Not applicable", - "Alive", - "Deceased" - ], - "colCount": 0 + type: "radiogroup", + name: "currentSpouseStatus", + title: " ", + isRequired: true, + choices: ["Not applicable", "Alive", "Deceased"], + colCount: 0, }, { - "type": "text", - "name": "currentSpouseAge", - "visible": false, - "visibleIf": "{currentSpouseStatus} = 'Alive'", - "startWithNewLine": false, - "title": "Age", - "isRequired": true + type: "text", + name: "currentSpouseAge", + visible: false, + visibleIf: "{currentSpouseStatus} = 'Alive'", + startWithNewLine: false, + title: "Age", + isRequired: true, }, { - "type": "comment", - "name": "currentSpouseHelthProblems", - "visibleIf": "{currentSpouseStatus} != 'Not applicable' ", - "title": "Health problems or cause of death:", - "isRequired": true, - "rows": 2 + type: "comment", + name: "currentSpouseHelthProblems", + visibleIf: "{currentSpouseStatus} != 'Not applicable' ", + title: "Health problems or cause of death:", + isRequired: true, + rows: 2, }, { - "type": "radiogroup", - "name": "currentSpouseEmploymentStatus", - "visible": false, - "visibleIf": "{currentSpouseStatus} = 'Alive'", - "title": "Current employment status:", - "isRequired": true, - "choices": [ - "Retired", - "Unemployed", - "Homemaker", - "Employed" - ], - "colCount": 0 - } - ] - }, - { - "type": "text", - "name": "currentSpouseOccupation", - "visible": false, - "visibleIf": "{currentSpouseEmploymentStatus} = 'Employed'", - "title": "Current occupation(s):", - "isRequired": true - } - ] - } - ] + type: "radiogroup", + name: "currentSpouseEmploymentStatus", + visible: false, + visibleIf: "{currentSpouseStatus} = 'Alive'", + title: "Current employment status:", + isRequired: true, + choices: ["Retired", "Unemployed", "Homemaker", "Employed"], + colCount: 0, + }, + ], + }, + { + type: "text", + name: "currentSpouseOccupation", + visible: false, + visibleIf: "{currentSpouseEmploymentStatus} = 'Employed'", + title: "Current occupation(s):", + isRequired: true, + }, + ], + }, + ], }, { - "name": "familyHistory", - "questionTitleLocation": "left", - "title": "Family History", - "elements": [ + name: "familyHistory", + questionTitleLocation: "left", + title: "Family History", + elements: [ { - "type": "radiogroup", - "name": "adopted", - "title": "Are you adopted?", - "isRequired": true, - "choices": [ - "Yes", - "No" - ], - "colCount": 0 + type: "radiogroup", + name: "adopted", + title: "Are you adopted?", + isRequired: true, + choices: ["Yes", "No"], + colCount: 0, }, { - "type": "html", - "name": "adoptedInfo", - "visible": false, - "visibleIf": "{adopted} = 'Yes'", - "html": "If known, complete the following information about your blood relatives (include children). Exclude adoptive parents, siblings and adopted children." + type: "html", + name: "adoptedInfo", + visible: false, + visibleIf: "{adopted} = 'Yes'", + html: "If known, complete the following information about your blood relatives (include children). Exclude adoptive parents, siblings and adopted children.", }, { - "type": "html", - "name": "nonAdoptedInfo", - "visible": false, - "visibleIf": "{adopted} = 'No'", - "html": "Complete the following information about your blood relatives. Exclude adoptive siblings and adopted children. " + type: "html", + name: "nonAdoptedInfo", + visible: false, + visibleIf: "{adopted} = 'No'", + html: "Complete the following information about your blood relatives. Exclude adoptive siblings and adopted children. ", }, { - "type": "paneldynamic", - "name": "bloodRelativesInfo", - "title": "Blood relatives information", - "templateElements": [ - { - "type": "dropdown", - "name": "relativeType", - "title": "Blood Relative:", - "isRequired": true, - "choices": [ + type: "paneldynamic", + name: "bloodRelativesInfo", + title: "Blood relatives information", + templateElements: [ + { + type: "dropdown", + name: "relativeType", + title: "Blood Relative:", + isRequired: true, + choices: [ "Father", "Mother", "Brother", "Sister", "Son", - "Daughter" - ] - }, - { - "type": "radiogroup", - "name": "relativeStatus", - "startWithNewLine": false, - "title": "Is he/she:", - "isRequired": true, - "choices": [ - "Alive", - "Deceased", - "Unknown" + "Daughter", ], - "colCount": 0 }, { - "type": "text", - "name": "relativeAge", - "visible": false, - "visibleIf": "{panel.relativeStatus} = 'Alive'", - "startWithNewLine": false, - "title": "Current age:", - "isRequired": true + type: "radiogroup", + name: "relativeStatus", + startWithNewLine: false, + title: "Is he/she:", + isRequired: true, + choices: ["Alive", "Deceased", "Unknown"], + colCount: 0, + }, + { + type: "text", + name: "relativeAge", + visible: false, + visibleIf: "{panel.relativeStatus} = 'Alive'", + startWithNewLine: false, + title: "Current age:", + isRequired: true, }, { - "type": "text", - "name": "relativeAgeOfDeath", - "visible": false, - "visibleIf": "{panel.relativeStatus} = 'Deceased'", - "startWithNewLine": false, - "title": "Age of death:", - "isRequired": true + type: "text", + name: "relativeAgeOfDeath", + visible: false, + visibleIf: "{panel.relativeStatus} = 'Deceased'", + startWithNewLine: false, + title: "Age of death:", + isRequired: true, }, { - "type": "panel", - "name": "relativeDeathInfo", - "visible": false, - "visibleIf": "{panel.relativeStatus} = 'Deceased'", - "elements": [ + type: "panel", + name: "relativeDeathInfo", + visible: false, + visibleIf: "{panel.relativeStatus} = 'Deceased'", + elements: [ { - "type": "radiogroup", - "name": "relativeCauseOfDeath", - "title": "Cause of death:", - "isRequired": true, - "choices": [ - "Known", - "Unknown" - ], - "colCount": 0 + type: "radiogroup", + name: "relativeCauseOfDeath", + title: "Cause of death:", + isRequired: true, + choices: ["Known", "Unknown"], + colCount: 0, }, { - "type": "comment", - "name": "relativeCauseOfDeathDescription", - "visible": false, - "visibleIf": "{panel.relativeCauseOfDeath} = 'Known'", - "title": "Description:", - "isRequired": true - } - ] - }, - { - "type": "matrixdynamic", - "name": "relativeCondition", - "title": "Describe the illness or conditios", - "titleLocation": "top", - "columns": [ + type: "comment", + name: "relativeCauseOfDeathDescription", + visible: false, + visibleIf: "{panel.relativeCauseOfDeath} = 'Known'", + title: "Description:", + isRequired: true, + }, + ], + }, + { + type: "matrixdynamic", + name: "relativeCondition", + title: "Describe the illness or conditios", + titleLocation: "top", + columns: [ { - "name": "name", - "title": "Illness/Condition", - "cellType": "dropdown", - "isRequired": true, - "choices": [ + name: "name", + title: "Illness/Condition", + cellType: "dropdown", + isRequired: true, + choices: [ "Cancer", "Heart Disease", "Diabetes", @@ -812,503 +760,436 @@ export const medical = { "Tuberculosis", "Anesthesia Complications", "Genetic Disorder", - "Other" - ] + "Other", + ], }, { - "name": "description", - "title": "Describe", - "cellType": "comment", - "isRequired": true - } - ], - "choices": [ - 1, - 2, - 3, - 4, - 5 + name: "description", + title: "Describe", + cellType: "comment", + isRequired: true, + }, ], - "rowCount": 1, - "addRowText": "Add illness" - } + choices: [1, 2, 3, 4, 5], + rowCount: 1, + addRowText: "Add illness", + }, ], - "panelCount": 1, - "panelAddText": "Add Family Member" + panelCount: 1, + panelAddText: "Add Family Member", }, { - "type": "comment", - "name": "relativesAdditionalInfo", - "title": "Other information about your family which you want us to know: " - } - ] + type: "comment", + name: "relativesAdditionalInfo", + title: + "Other information about your family which you want us to know: ", + }, + ], }, { - "name": "healthcareProvider", - "questionTitleLocation": "left", - "title": "Healthcare Provider Information", - "elements": [ + name: "healthcareProvider", + questionTitleLocation: "left", + title: "Healthcare Provider Information", + elements: [ { - "type": "radiogroup", - "name": "primaryCareProvider", - "title": "Do you have a Primary Care Provider?", - "isRequired": true, - "choices": [ - "No", - "Yes" - ], - "colCount": 0 + type: "radiogroup", + name: "primaryCareProvider", + title: "Do you have a Primary Care Provider?", + isRequired: true, + choices: ["No", "Yes"], + colCount: 0, }, { - "type": "panel", - "name": "primaryCareProviderInfo", - "visible": false, - "visibleIf": "{primaryCareProvider} = 'Yes'", - "title": "Primary Care Provider", - "elements": [ - { - "type": "text", - "name": "primaryCareProviderName", - "title": "Name:", - "isRequired": true - }, - { - "type": "text", - "name": "primaryCareProviderPhone", - "startWithNewLine": false, - "title": "Phone:", - "isRequired": true - }, - { - "type": "comment", - "name": "primaryCareProviderAddress", - "title": "Address:" - }, - { - "type": "radiogroup", - "name": "primaryCareProviderSent", - "title": "Do you want a summary of your visit sent to this person?", - "isRequired": true, - "choices": [ - "No", - "Yes" - ], - "colCount": 0 - } - ] + type: "panel", + name: "primaryCareProviderInfo", + visible: false, + visibleIf: "{primaryCareProvider} = 'Yes'", + title: "Primary Care Provider", + elements: [ + { + type: "text", + name: "primaryCareProviderName", + title: "Name:", + isRequired: true, + }, + { + type: "text", + name: "primaryCareProviderPhone", + startWithNewLine: false, + title: "Phone:", + isRequired: true, + }, + { + type: "comment", + name: "primaryCareProviderAddress", + title: "Address:", + }, + { + type: "radiogroup", + name: "primaryCareProviderSent", + title: + "Do you want a summary of your visit sent to this person?", + isRequired: true, + choices: ["No", "Yes"], + colCount: 0, + }, + ], }, { - "type": "radiogroup", - "name": "primaryCareProviderRecommend", - "title": "Did a non-Vanderbilt physician or healthcare provider recommend or arrange this visit for you?", - "isRequired": true, - "choices": [ - "No", - "Yes" - ], - "colCount": 0 + type: "radiogroup", + name: "primaryCareProviderRecommend", + title: + "Did a non-Vanderbilt physician or healthcare provider recommend or arrange this visit for you?", + isRequired: true, + choices: ["No", "Yes"], + colCount: 0, }, { - "type": "panel", - "name": "primaryCareProviderRecommendInfo", - "visible": false, - "visibleIf": "{primaryCareProviderRecommend} = 'Yes'", - "elements": [ - { - "type": "radiogroup", - "name": "primaryCareProviderWhoSent", - "title": "Who sent you?", - "isRequired": true, - "choices": [ + type: "panel", + name: "primaryCareProviderRecommendInfo", + visible: false, + visibleIf: "{primaryCareProviderRecommend} = 'Yes'", + elements: [ + { + type: "radiogroup", + name: "primaryCareProviderWhoSent", + title: "Who sent you?", + isRequired: true, + choices: [ { - "value": "primary", - "text": "Your Primary Care Provider (as listed above) " + value: "primary", + text: "Your Primary Care Provider (as listed above) ", }, { - "value": "other", - "text": "Other physician or healthcare provider" - } + value: "other", + text: "Other physician or healthcare provider", + }, ], - "colCount": 0 + colCount: 0, }, { - "type": "panel", - "name": "primaryCareProviderOtherInfo", - "visible": false, - "visibleIf": "{primaryCareProviderWhoSent} = 'other'", - "title": "Other physician or healthcare provider", - "elements": [ + type: "panel", + name: "primaryCareProviderOtherInfo", + visible: false, + visibleIf: "{primaryCareProviderWhoSent} = 'other'", + title: "Other physician or healthcare provider", + elements: [ { - "type": "text", - "name": "primaryCareProviderOtherName", - "title": "Name:", - "isRequired": true + type: "text", + name: "primaryCareProviderOtherName", + title: "Name:", + isRequired: true, }, { - "type": "text", - "name": "primaryCareProviderOtherPhone", - "startWithNewLine": false, - "title": "Phone:", - "isRequired": true + type: "text", + name: "primaryCareProviderOtherPhone", + startWithNewLine: false, + title: "Phone:", + isRequired: true, }, { - "type": "comment", - "name": "primaryCareProviderOtherAddress", - "title": "Address:" + type: "comment", + name: "primaryCareProviderOtherAddress", + title: "Address:", }, { - "type": "radiogroup", - "name": "primaryCareProviderOtherSent", - "title": "Do you want a summary of your visit sent to this person?", - "isRequired": true, - "choices": [ - "No", - "Yes" - ], - "colCount": 0 - } - ] - } - ] - } - ] + type: "radiogroup", + name: "primaryCareProviderOtherSent", + title: + "Do you want a summary of your visit sent to this person?", + isRequired: true, + choices: ["No", "Yes"], + colCount: 0, + }, + ], + }, + ], + }, + ], }, { - "name": "medications", - "title": "Medications", - "elements": [ + name: "medications", + title: "Medications", + elements: [ { - "type": "panel", - "name": "currentUsingMedication", - "title": "Medications currently using", - "elements": [ - { - "type": "radiogroup", - "name": "currentMedication", - "title": "Are you currently taking any prescription and/or non-prescription medications including vitamins, nutritional supplements, oral contraceptives, pain relievers, diuretics, laxatives, herbal remedies, and cold medications? ", - "isRequired": true, - "choices": [ - "No", - "Yes" - ], - "colCount": 0 + type: "panel", + name: "currentUsingMedication", + title: "Medications currently using", + elements: [ + { + type: "radiogroup", + name: "currentMedication", + title: + "Are you currently taking any prescription and/or non-prescription medications including vitamins, nutritional supplements, oral contraceptives, pain relievers, diuretics, laxatives, herbal remedies, and cold medications? ", + isRequired: true, + choices: ["No", "Yes"], + colCount: 0, }, { - "type": "matrixdynamic", - "name": "currentMedicationList", - "visible": false, - "visibleIf": "{currentMedication} = 'Yes'", - "title": "Medication list", - "description": "Please add all medication you are currently taking", - "columns": [ + type: "matrixdynamic", + name: "currentMedicationList", + visible: false, + visibleIf: "{currentMedication} = 'Yes'", + title: "Medication list", + description: + "Please add all medication you are currently taking", + columns: [ { - "name": "name", - "title": "Name of Medication", - "cellType": "text", - "isRequired": true + name: "name", + title: "Name of Medication", + cellType: "text", + isRequired: true, }, { - "name": "dose", - "title": "Dose", - "cellType": "text", - "isRequired": true + name: "dose", + title: "Dose", + cellType: "text", + isRequired: true, }, { - "name": "often", - "title": "How Often Taken", - "cellType": "text", - "isRequired": true - } - ], - "choices": [ - 1, - 2, - 3, - 4, - 5 + name: "often", + title: "How Often Taken", + cellType: "text", + isRequired: true, + }, ], - "rowCount": 1, - "addRowText": "Add medication" - } - ] + choices: [1, 2, 3, 4, 5], + rowCount: 1, + addRowText: "Add medication", + }, + ], }, { - "type": "panel", - "name": "recentlyUsedMedication", - "title": "Medication recently used", - "elements": [ - { - "type": "radiogroup", - "name": "recentlyUsedMedication", - "title": "Are there other medications you have recently used?", - "isRequired": true, - "choices": [ - "No", - "Yes" - ], - "colCount": 0 + type: "panel", + name: "recentlyUsedMedication", + title: "Medication recently used", + elements: [ + { + type: "radiogroup", + name: "recentlyUsedMedication", + title: "Are there other medications you have recently used?", + isRequired: true, + choices: ["No", "Yes"], + colCount: 0, }, { - "type": "matrixdynamic", - "name": "recentlyUsedMedicationList", - "visible": false, - "visibleIf": "{recentlyUsedMedication} = 'Yes'", - "title": "Medication list", - "description": "Please add all medication you have recently used", - "columns": [ + type: "matrixdynamic", + name: "recentlyUsedMedicationList", + visible: false, + visibleIf: "{recentlyUsedMedication} = 'Yes'", + title: "Medication list", + description: "Please add all medication you have recently used", + columns: [ { - "name": "name", - "title": "Name of Medication", - "cellType": "text", - "isRequired": true + name: "name", + title: "Name of Medication", + cellType: "text", + isRequired: true, }, { - "name": "dose", - "title": "Dose", - "cellType": "text", - "isRequired": true + name: "dose", + title: "Dose", + cellType: "text", + isRequired: true, }, { - "name": "often", - "title": "How Often Taken", - "cellType": "text", - "isRequired": true - } - ], - "choices": [ - 1, - 2, - 3, - 4, - 5 + name: "often", + title: "How Often Taken", + cellType: "text", + isRequired: true, + }, ], - "rowCount": 1, - "addRowText": "Add medication" - } - ] + choices: [1, 2, 3, 4, 5], + rowCount: 1, + addRowText: "Add medication", + }, + ], }, { - "type": "radiogroup", - "name": "aspirinContainingProducts", - "title": "Have you taken aspirin-containing products in the last two weeks?", - "isRequired": true, - "choices": [ - "No", - "Yes" - ], - "colCount": 0 + type: "radiogroup", + name: "aspirinContainingProducts", + title: + "Have you taken aspirin-containing products in the last two weeks?", + isRequired: true, + choices: ["No", "Yes"], + colCount: 0, }, { - "type": "radiogroup", - "name": "steroidDrugs", - "title": "Have you taken steroid or cortisone-type drugs within the last year?", - "isRequired": true, - "choices": [ - "No", - "Yes" - ], - "colCount": 0 - } - ] + type: "radiogroup", + name: "steroidDrugs", + title: + "Have you taken steroid or cortisone-type drugs within the last year?", + isRequired: true, + choices: ["No", "Yes"], + colCount: 0, + }, + ], }, { - "name": "allergies", - "title": "Allergies", - "elements": [ + name: "allergies", + title: "Allergies", + elements: [ { - "type": "panel", - "name": "allergiesMedication", - "title": "Allergies to Medication", - "elements": [ - { - "type": "radiogroup", - "name": "hasAllergiesMedication", - "title": "Have you had hives, skin rash, breathing problems, or other allergic reactions to medications?", - "isRequired": true, - "choices": [ - "No", - "Yes" - ], - "colCount": 0 + type: "panel", + name: "allergiesMedication", + title: "Allergies to Medication", + elements: [ + { + type: "radiogroup", + name: "hasAllergiesMedication", + title: + "Have you had hives, skin rash, breathing problems, or other allergic reactions to medications?", + isRequired: true, + choices: ["No", "Yes"], + colCount: 0, }, { - "type": "matrixdynamic", - "name": "allergiesMedicationList", - "visible": false, - "visibleIf": "{hasAllergiesMedication} = 'Yes'", - "title": "Medication list", - "columns": [ + type: "matrixdynamic", + name: "allergiesMedicationList", + visible: false, + visibleIf: "{hasAllergiesMedication} = 'Yes'", + title: "Medication list", + columns: [ { - "name": "name", - "title": "Name of Medication", - "cellType": "text", - "isRequired": true + name: "name", + title: "Name of Medication", + cellType: "text", + isRequired: true, }, { - "name": "description", - "title": "Describe Allergic Reaction", - "cellType": "comment", - "isRequired": true - } - ], - "choices": [ - 1, - 2, - 3, - 4, - 5 + name: "description", + title: "Describe Allergic Reaction", + cellType: "comment", + isRequired: true, + }, ], - "rowCount": 1, - "addRowText": "Add medication" - } - ] + choices: [1, 2, 3, 4, 5], + rowCount: 1, + addRowText: "Add medication", + }, + ], }, { - "type": "panel", - "name": "unpleasentToMedication", - "title": "Unpleasant Side Effects to Medications", - "elements": [ - { - "type": "radiogroup", - "name": "hasUnpleasantMedication", - "title": "Are there medications, other than those you are allergic to, that you would prefer not to take due to prior unpleasant side effects?", - "isRequired": true, - "choices": [ - "No", - "Yes" - ], - "colCount": 0 + type: "panel", + name: "unpleasentToMedication", + title: "Unpleasant Side Effects to Medications", + elements: [ + { + type: "radiogroup", + name: "hasUnpleasantMedication", + title: + "Are there medications, other than those you are allergic to, that you would prefer not to take due to prior unpleasant side effects?", + isRequired: true, + choices: ["No", "Yes"], + colCount: 0, }, { - "type": "matrixdynamic", - "name": "unpleasantMedicationList", - "visible": false, - "visibleIf": "{hasUnpleasantMedication} = 'Yes'", - "title": "Medication list", - "columns": [ + type: "matrixdynamic", + name: "unpleasantMedicationList", + visible: false, + visibleIf: "{hasUnpleasantMedication} = 'Yes'", + title: "Medication list", + columns: [ { - "name": "name", - "title": "Name of Medication", - "cellType": "text", - "isRequired": true + name: "name", + title: "Name of Medication", + cellType: "text", + isRequired: true, }, { - "name": "description", - "title": "Describe the Reaction", - "cellType": "text", - "isRequired": true - } - ], - "choices": [ - 1, - 2, - 3, - 4, - 5 + name: "description", + title: "Describe the Reaction", + cellType: "text", + isRequired: true, + }, ], - "rowCount": 1, - "addRowText": "Add medication" + choices: [1, 2, 3, 4, 5], + rowCount: 1, + addRowText: "Add medication", }, { - "type": "panel", - "name": "allergiesReaction", - "questionTitleLocation": "left", - "title": "Have you had an allergic reaction to:", - "elements": [ + type: "panel", + name: "allergiesReaction", + questionTitleLocation: "left", + title: "Have you had an allergic reaction to:", + elements: [ { - "type": "radiogroup", - "name": "allergicReactionXRay", - "title": "Iodine or X-ray contrast dye", - "isRequired": true, - "choices": [ - "No", - "Yes" - ], - "colCount": 0 + type: "radiogroup", + name: "allergicReactionXRay", + title: "Iodine or X-ray contrast dye", + isRequired: true, + choices: ["No", "Yes"], + colCount: 0, }, { - "type": "radiogroup", - "name": "allergicReactionBee", - "startWithNewLine": false, - "title": "Bee or wasp stings", - "isRequired": true, - "choices": [ - "No", - "Yes" - ], - "colCount": 0 + type: "radiogroup", + name: "allergicReactionBee", + startWithNewLine: false, + title: "Bee or wasp stings", + isRequired: true, + choices: ["No", "Yes"], + colCount: 0, }, { - "type": "radiogroup", - "name": "allergicReactionLatext", - "title": "Latex or Rubber", - "isRequired": true, - "choices": [ - "No", - "Yes" - ], - "colCount": 0 + type: "radiogroup", + name: "allergicReactionLatext", + title: "Latex or Rubber", + isRequired: true, + choices: ["No", "Yes"], + colCount: 0, }, { - "type": "radiogroup", - "name": "allergicReactionTape", - "startWithNewLine": false, - "title": "Adhesive tape", - "isRequired": true, - "choices": [ - "No", - "Yes" - ], - "colCount": 0 - } - ] - } - ] + type: "radiogroup", + name: "allergicReactionTape", + startWithNewLine: false, + title: "Adhesive tape", + isRequired: true, + choices: ["No", "Yes"], + colCount: 0, + }, + ], + }, + ], }, { - "type": "panel", - "name": "foodAllergiesInfo", - "questionTitleLocation": "left", - "title": "Food Allergies", - "elements": [ - { - "type": "radiogroup", - "name": "hasFoodAllergies", - "title": "Do you have any food allergies?", - "isRequired": true, - "choices": [ - "No", - "Yes" - ], - "colCount": 0 - }, - { - "type": "comment", - "name": "foodAllergiesDescription", - "visible": false, - "visibleIf": "{hasFoodAllergies} = 'Yes'", - "title": "Describe" - } - ] - } - ] + type: "panel", + name: "foodAllergiesInfo", + questionTitleLocation: "left", + title: "Food Allergies", + elements: [ + { + type: "radiogroup", + name: "hasFoodAllergies", + title: "Do you have any food allergies?", + isRequired: true, + choices: ["No", "Yes"], + colCount: 0, + }, + { + type: "comment", + name: "foodAllergiesDescription", + visible: false, + visibleIf: "{hasFoodAllergies} = 'Yes'", + title: "Describe", + }, + ], + }, + ], }, { - "name": "systemsReview", - "questionTitleLocation": "left", - "title": "System Review", - "elements": [ + name: "systemsReview", + questionTitleLocation: "left", + title: "System Review", + elements: [ { - "type": "matrix", - "name": "sympthoms", - "title": "Indicate whether you have experienced the following symptoms during recent months, unless otherwise specified", - "titleLocation": "top", - "isRequired": true, - "columns": [ - "No", - "Yes" - ], - "rows": [ + type: "matrix", + name: "sympthoms", + title: + "Indicate whether you have experienced the following symptoms during recent months, unless otherwise specified", + titleLocation: "top", + isRequired: true, + columns: ["No", "Yes"], + rows: [ "Skin rash, sore, excessive bruising or change of a mole?", "Excessive thirst or urination?", "Change in sexual drive or performance?", @@ -1316,8 +1197,8 @@ export const medical = { "Eye problems such as double or blurred vision, cataracts or glaucoma?", "Diminished hearing, dizziness, hoarseness or sinus problems?", { - "value": "dentures", - "text": "Do you wear dentures?" + value: "dentures", + text: "Do you wear dentures?", }, "Bothered with cough, shortness of breath, wheezing or asthma?", "Coughing up sputum or blood?", @@ -1330,12 +1211,12 @@ export const medical = { "Difficulty with swallowing, heartburn, nausea, vomiting or stomach trouble?", "Significant problems with constipation, diarrhea, blood/changes in bowel movements?", { - "value": "colon_rectum_x-ray", - "text": "Have you had a colon or rectum x-ray or instrument examination (proctoscopy, sigmoidoscopy, colonoscopy)?" + value: "colon_rectum_x-ray", + text: "Have you had a colon or rectum x-ray or instrument examination (proctoscopy, sigmoidoscopy, colonoscopy)?", }, { - "value": "endoscopy", - "text": "Have you had an upper endoscopy to evaluate the stomach for varices?" + value: "endoscopy", + text: "Have you had an upper endoscopy to evaluate the stomach for varices?", }, "Have you had any treatment for varices? (sclerotherapy, banding)", "Difficulty starting your urinary stream, completely emptying your bladder or leaking urine from your bladder?", @@ -1350,320 +1231,288 @@ export const medical = { "Problems falling asleep, staying asleep, sleep apnea or disruptive snoring?", "Have you ever felt a need to cut down on your alcohol consumption?", "Do relatives/friends worry or complain about your alcohol consumption?", - "Have you been physically, sexually, or emotionally abused?" + "Have you been physically, sexually, or emotionally abused?", ], - "isAllRowRequired": true + isAllRowRequired: true, }, { - "type": "radiogroup", - "name": "howWearDentures", - "visible": false, - "visibleIf": "{sympthoms.dentures} = 'Yes'", - "title": "How do you wear dentures?", - "isRequired": true, - "choices": [ - " Ful", - "Upper", - "Lower", - "Partial" - ], - "colCount": 0 + type: "radiogroup", + name: "howWearDentures", + visible: false, + visibleIf: "{sympthoms.dentures} = 'Yes'", + title: "How do you wear dentures?", + isRequired: true, + choices: [" Ful", "Upper", "Lower", "Partial"], + colCount: 0, }, { - "type": "multipletext", - "name": "colonRectumDate", - "visible": false, - "visibleIf": "{sympthoms.colon_rectum_x-ray} = 'Yes'", - "title": "Whe did you do a colon or rectum x-ray or instrument examination (proctoscopy, sigmoidoscopy, colonoscopy)? Approximate date:", - "isRequired": true, - "items": [ - { - "name": "mo", - "title": "Month" + type: "multipletext", + name: "colonRectumDate", + visible: false, + visibleIf: "{sympthoms.colon_rectum_x-ray} = 'Yes'", + title: + "Whe did you do a colon or rectum x-ray or instrument examination (proctoscopy, sigmoidoscopy, colonoscopy)? Approximate date:", + isRequired: true, + items: [ + { + name: "mo", + title: "Month", }, { - "name": "year", - "title": "Year" - } + name: "year", + title: "Year", + }, ], - "colCount": 2 + colCount: 2, }, { - "type": "multipletext", - "name": "endoscopyDate", - "visible": false, - "visibleIf": "{sympthoms.endoscopy} = 'Yes'", - "title": "Whe did you have an upper endoscopy to evaluate the stomach for varices? Approximate date:", - "isRequired": true, - "items": [ - { - "name": "mo", - "title": "Month" + type: "multipletext", + name: "endoscopyDate", + visible: false, + visibleIf: "{sympthoms.endoscopy} = 'Yes'", + title: + "Whe did you have an upper endoscopy to evaluate the stomach for varices? Approximate date:", + isRequired: true, + items: [ + { + name: "mo", + title: "Month", }, { - "name": "year", - "title": "Year" - } + name: "year", + title: "Year", + }, ], - "colCount": 2 + colCount: 2, }, { - "type": "panel", - "name": "questionsToFemale", - "visible": false, - "visibleIf": "{sex} = 'female'", - "title": "For Female Patients", - "elements": [ - { - "type": "radiogroup", - "name": "abnormalPapSmear", - "title": "Have you ever had an abnormal Pap smear?", - "isRequired": true, - "choices": [ - "Unknown", - "No", - "Yes" - ], - "colCount": 0 + type: "panel", + name: "questionsToFemale", + visible: false, + visibleIf: "{sex} = 'female'", + title: "For Female Patients", + elements: [ + { + type: "radiogroup", + name: "abnormalPapSmear", + title: "Have you ever had an abnormal Pap smear?", + isRequired: true, + choices: ["Unknown", "No", "Yes"], + colCount: 0, }, { - "type": "radiogroup", - "name": "menopause", - "title": "Have you experienced menopause or had a hysterectomy?", - "isRequired": true, - "choices": [ - "No", - "Yes" - ], - "colCount": 0 + type: "radiogroup", + name: "menopause", + title: "Have you experienced menopause or had a hysterectomy?", + isRequired: true, + choices: ["No", "Yes"], + colCount: 0, }, { - "type": "panel", - "name": "panelNoMenopause", - "visible": false, - "visibleIf": "{menopause} = 'No'", - "elements": [ + type: "panel", + name: "panelNoMenopause", + visible: false, + visibleIf: "{menopause} = 'No'", + elements: [ { - "type": "radiogroup", - "name": "concernedAboutMenstrualPeriods", - "title": "Are you concerned about your menstrual periods?", - "isRequired": true, - "choices": [ - "No", - "Yes" - ], - "colCount": 0 + type: "radiogroup", + name: "concernedAboutMenstrualPeriods", + title: "Are you concerned about your menstrual periods?", + isRequired: true, + choices: ["No", "Yes"], + colCount: 0, }, { - "type": "radiogroup", - "name": "pregnant", - "title": "Might you be pregnant at this time?", - "isRequired": true, - "choices": [ - "No", - "Yes" - ], - "colCount": 0 + type: "radiogroup", + name: "pregnant", + title: "Might you be pregnant at this time?", + isRequired: true, + choices: ["No", "Yes"], + colCount: 0, }, { - "type": "text", - "name": "lastMenstrualPeriod", - "title": "Date of onset of your last menstrual period:", - "inputType": "date" + type: "text", + name: "lastMenstrualPeriod", + title: "Date of onset of your last menstrual period:", + inputType: "date", }, { - "type": "panel", - "name": "panelPapSmearExam", - "elements": [ + type: "panel", + name: "panelPapSmearExam", + elements: [ { - "type": "radiogroup", - "name": "papSmearExam", - "title": "Have you ever done Pap smear and pelvic exam:", - "isRequired": true, - "choices": [ - "No", - "Yes" - ], - "colCount": 0 + type: "radiogroup", + name: "papSmearExam", + title: "Have you ever done Pap smear and pelvic exam:", + isRequired: true, + choices: ["No", "Yes"], + colCount: 0, }, { - "type": "multipletext", - "name": "papSmearExamDate", - "visible": false, - "visibleIf": "{papSmearExam} = 'Yes'", - "title": "Approximate date of your last Pap smear and pelvic exam:", - "isRequired": true, - "items": [ + type: "multipletext", + name: "papSmearExamDate", + visible: false, + visibleIf: "{papSmearExam} = 'Yes'", + title: + "Approximate date of your last Pap smear and pelvic exam:", + isRequired: true, + items: [ { - "name": "mo", - "title": "Month" + name: "mo", + title: "Month", }, { - "name": "year", - "title": "Year" - } + name: "year", + title: "Year", + }, ], - "colCount": 2 + colCount: 2, }, { - "type": "radiogroup", - "name": "mammogram", - "title": "Have you ever done mammogram:", - "isRequired": true, - "choices": [ - "No", - "Yes" - ], - "colCount": 0 + type: "radiogroup", + name: "mammogram", + title: "Have you ever done mammogram:", + isRequired: true, + choices: ["No", "Yes"], + colCount: 0, }, { - "type": "multipletext", - "name": "mammogramDate", - "visible": false, - "visibleIf": "{mammogram} = 'Yes'", - "title": "Approximate date of your last mammogram:", - "isRequired": true, - "items": [ + type: "multipletext", + name: "mammogramDate", + visible: false, + visibleIf: "{mammogram} = 'Yes'", + title: "Approximate date of your last mammogram:", + isRequired: true, + items: [ { - "name": "mo", - "title": "Month" + name: "mo", + title: "Month", }, { - "name": "year", - "title": "Year" - } + name: "year", + title: "Year", + }, ], - "colCount": 2 - } - ] + colCount: 2, + }, + ], }, { - "type": "panel", - "name": "panelPregnancies", - "title": "Number of:", - "elements": [ + type: "panel", + name: "panelPregnancies", + title: "Number of:", + elements: [ { - "type": "text", - "name": "pregnancies", - "title": "Pregnancies:", - "isRequired": true, - "inputType": "number" + type: "text", + name: "pregnancies", + title: "Pregnancies:", + isRequired: true, + inputType: "number", }, { - "type": "text", - "name": "liveBirths", - "startWithNewLine": false, - "title": "Live Births:", - "isRequired": true, - "inputType": "number" + type: "text", + name: "liveBirths", + startWithNewLine: false, + title: "Live Births:", + isRequired: true, + inputType: "number", }, { - "type": "text", - "name": "abortions", - "startWithNewLine": false, - "title": "Miscarriages/abortions:", - "isRequired": true, - "inputType": "number", - "min": 0 - } - ] - } - ] - } - ] - } - ] + type: "text", + name: "abortions", + startWithNewLine: false, + title: "Miscarriages/abortions:", + isRequired: true, + inputType: "number", + min: 0, + }, + ], + }, + ], + }, + ], + }, + ], }, { - "name": "selfCare", - "questionTitleLocation": "top", - "title": "Self-Care/Home Environment Assessment", - "elements": [ + name: "selfCare", + questionTitleLocation: "top", + title: "Self-Care/Home Environment Assessment", + elements: [ { - "type": "matrix", - "name": "performingActivities", - "title": "Do you have difficulty performing these activities by YOURSELF?", - "columns": [ - "No", - "Yes" - ], - "rows": [ + type: "matrix", + name: "performingActivities", + title: + "Do you have difficulty performing these activities by YOURSELF?", + columns: ["No", "Yes"], + rows: [ "Eating", "Bathing", "Dressing", "Walking", "Using Toilet", - "Housekeeping" + "Housekeeping", ], - "isAllRowRequired": true + isAllRowRequired: true, }, { - "type": "radiogroup", - "name": "specialDietary", - "title": "Do you have any special dietary needs?", - "isRequired": true, - "choices": [ - "No", - "Yes" - ], - "colCount": 0 + type: "radiogroup", + name: "specialDietary", + title: "Do you have any special dietary needs?", + isRequired: true, + choices: ["No", "Yes"], + colCount: 0, }, { - "type": "comment", - "name": "specialDietaryDescription", - "visibleIf": "{specialDietary} = 'Yes'", - "title": "Please describe your special dietery:", - "isRequired": true + type: "comment", + name: "specialDietaryDescription", + visibleIf: "{specialDietary} = 'Yes'", + title: "Please describe your special dietery:", + isRequired: true, }, { - "type": "radiogroup", - "name": "livingArrangement", - "title": "What is your current living arrangement?", - "isRequired": true, - "choices": [ - "House", - "Apartment", - "Nursing Home" - ], - "showOtherItem": true, - "colCount": 0 + type: "radiogroup", + name: "livingArrangement", + title: "What is your current living arrangement?", + isRequired: true, + choices: ["House", "Apartment", "Nursing Home"], + showOtherItem: true, + colCount: 0, }, { - "type": "radiogroup", - "name": "liveWithWhom", - "title": "Do you live?", - "isRequired": true, - "choices": [ - "Alone", - "With Spouse/Family", - "With others" - ], - "colCount": 0 + type: "radiogroup", + name: "liveWithWhom", + title: "Do you live?", + isRequired: true, + choices: ["Alone", "With Spouse/Family", "With others"], + colCount: 0, }, { - "type": "comment", - "name": "liveWithWhomDescription", - "visibleIf": "{liveWithWhom} = 'With others'", - "title": "Please describe with whom do you live:", - "isRequired": true + type: "comment", + name: "liveWithWhomDescription", + visibleIf: "{liveWithWhom} = 'With others'", + title: "Please describe with whom do you live:", + isRequired: true, }, { - "type": "comment", - "name": "peopleProvidedAssistence", - "title": "List family or friends able to provide assistance with your homecare needs if you would ever require such assistance:", - "titleLocation": "top" - } - ] + type: "comment", + name: "peopleProvidedAssistence", + title: + "List family or friends able to provide assistance with your homecare needs if you would ever require such assistance:", + titleLocation: "top", + }, + ], }, { - "name": "educationalNeeds", - "title": "Educational Needs", - "elements": [ + name: "educationalNeeds", + title: "Educational Needs", + elements: [ { - "type": "checkbox", - "name": "interestedInTopics", - "title": "Are you interested in more information about a specific topic(s)?", - "choices": [ + type: "checkbox", + name: "interestedInTopics", + title: + "Are you interested in more information about a specific topic(s)?", + choices: [ "How to stop smoking", "Exercise", "Stress", @@ -1674,15 +1523,16 @@ export const medical = { "Violent & abusive behavior", "Living wills", "Diabetes", - "Cancer screening " + "Cancer screening ", ], - "showOtherItem": true, - "colCount": 3 - } - ] - } + showOtherItem: true, + colCount: 3, + }, + ], + }, ], - "showQuestionNumbers": "off", - "questionErrorLocation": "bottom", - "showProgressBar": "top" - } \ No newline at end of file + showQuestionNumbers: "off", + questionErrorLocation: "bottom", + showProgressBar: "top", + }, +}; diff --git a/src/data/nps.js b/src/data/nps.js index 71015ea..eb99b6c 100644 --- a/src/data/nps.js +++ b/src/data/nps.js @@ -1,206 +1,1590 @@ export const nps = { - "title": "NPS Demo", - "completedHtmlOnCondition": [ + slug: "nps", + results: [ + { + "nps-score": 9, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["ui"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + { + "nps-score": 0, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["complete-functionality"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 4, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["stability"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 0, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["learning-materials"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + { + "nps-score": 8, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["learning-materials"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + { + "nps-score": 0, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["stability"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 3, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["ui"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 5, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["stability"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 2, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["performance"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + { + "nps-score": 6, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["learning-materials"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + { + "nps-score": 3, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["stability"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + { + "nps-score": 2, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["support"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 9, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["complete-functionality"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + { + "nps-score": 0, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["support"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 0, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["complete-functionality"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + { + "nps-score": 8, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["complete-functionality"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 3, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["ui"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 4, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["support"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + { + "nps-score": 3, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["complete-functionality"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + { + "nps-score": 2, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["support"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 3, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["stability"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 2, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["performance"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 3, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["ui"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 7, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["learning-materials"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + { + "nps-score": 4, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["learning-materials"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 5, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["support"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + { + "nps-score": 3, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["ui"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + { + "nps-score": 3, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["learning-materials"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 6, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["stability"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 6, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["complete-functionality"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + { + "nps-score": 9, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["complete-functionality"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 2, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["performance"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 2, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["ui"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 1, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["performance"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 0, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["complete-functionality"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + { + "nps-score": 6, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["support"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + { + "nps-score": 8, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["stability"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 8, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["support"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 5, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["learning-materials"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 6, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["complete-functionality"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + { + "nps-score": 9, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["performance"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + { + "nps-score": 1, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["ui"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + { + "nps-score": 0, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["stability"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 4, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["learning-materials"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 9, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["complete-functionality"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 2, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["performance"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + { + "nps-score": 4, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["stability"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + { + "nps-score": 8, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["learning-materials"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + { + "nps-score": 2, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["complete-functionality"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 3, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["complete-functionality"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + { + "nps-score": 3, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["stability"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 8, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["complete-functionality"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + { + "nps-score": 7, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["support"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 0, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["performance"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + { + "nps-score": 1, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["complete-functionality"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 0, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["support"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + { + "nps-score": 9, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["stability"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + { + "nps-score": 0, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["ui"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + { + "nps-score": 3, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["ui"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + { + "nps-score": 2, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["complete-functionality"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 0, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["stability"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + { + "nps-score": 4, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["ui"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + { + "nps-score": 2, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["learning-materials"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 2, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["stability"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 2, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["learning-materials"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 9, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["performance"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + { + "nps-score": 9, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["complete-functionality"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + { + "nps-score": 9, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["performance"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 0, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["complete-functionality"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + { + "nps-score": 8, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["support"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + { + "nps-score": 8, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["complete-functionality"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 5, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["ui"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 0, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["learning-materials"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 0, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["ui"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 5, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["stability"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 0, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["complete-functionality"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 9, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["learning-materials"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + { + "nps-score": 8, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["ui"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 1, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["performance"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 8, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["learning-materials"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + { + "nps-score": 1, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["complete-functionality"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 8, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["ui"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 6, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["support"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 4, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["support"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + { + "nps-score": 2, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["support"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 6, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["ui"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 1, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["performance"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 8, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["ui"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + { + "nps-score": 8, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["support"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 5, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["support"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 0, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["stability"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 3, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["ui"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 9, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["learning-materials"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 6, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["complete-functionality"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + { + "nps-score": 3, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["performance"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 6, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["ui"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 0, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["stability"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + { + "nps-score": 7, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["learning-materials"], + rebuy: [true, false], + testimonial: { + value: "yes", + text: { default: "Sure!", fr: "Bien sur!" }, + }, + }, + { + "nps-score": 0, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["ui"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + { + "nps-score": 7, + "disappointing-experience": [ + "The service is great, i highly recommend you use it.", + ], + "improvements-required": [ + "The service is great, i highly recommend you use it.", + ], + "promoter-features": ["ui"], + rebuy: [true, false], + testimonial: { value: "no", text: { default: "No", fr: "Non merci." } }, + }, + ], + survey: { + title: "NPS Demo", + completedHtmlOnCondition: [ { - "expression": "{nps-score} <= 6 or {rebuy} = false", - "html": { - "default": "Thanks for your feedback! We highly value all ideas and suggestions from our customers, whether they're positive or critical. In the future, our team might reach out to you to learn more about how we can further improve our product so that it exceeds your expectations.", - "fr": "Merci pour vos commentaires! Nous accordons une grande importance à toutes les idées et suggestions de nos clients, qu'elles soient positives ou critiques. À l'avenir, notre équipe pourrait vous contacter pour en savoir plus sur la façon dont nous pouvons encore améliorer notre produit afin qu'il dépasse vos attentes." - } + expression: "{nps-score} <= 6 or {rebuy} = false", + html: { + default: + "Thanks for your feedback! We highly value all ideas and suggestions from our customers, whether they're positive or critical. In the future, our team might reach out to you to learn more about how we can further improve our product so that it exceeds your expectations.", + fr: "Merci pour vos commentaires! Nous accordons une grande importance à toutes les idées et suggestions de nos clients, qu'elles soient positives ou critiques. À l'avenir, notre équipe pourrait vous contacter pour en savoir plus sur la façon dont nous pouvons encore améliorer notre produit afin qu'il dépasse vos attentes.", + }, }, { - "expression": "{nps-score} = 6 or {nps-score} = 7", - "html": { - "default": "Thanks for your feedback. Our goal is to create the best possible product, and your thoughts, ideas, and suggestions play a major role in helping us identify opportunities to improve.", - "fr": "Merci pour vos commentaires. Notre objectif est de créer le meilleur produit possible, et vos réflexions, idées et suggestions jouent un rôle majeur pour nous aider à identifier les opportunités d'amélioration." - } + expression: "{nps-score} = 6 or {nps-score} = 7", + html: { + default: + "Thanks for your feedback. Our goal is to create the best possible product, and your thoughts, ideas, and suggestions play a major role in helping us identify opportunities to improve.", + fr: "Merci pour vos commentaires. Notre objectif est de créer le meilleur produit possible, et vos réflexions, idées et suggestions jouent un rôle majeur pour nous aider à identifier les opportunités d'amélioration.", + }, }, { - "expression": "{nps-score} >= 8", - "html": { - "default": "Thanks for your feedback. It's great to hear that you're a fan of our product. Your feedback helps us discover new opportunities to improve it and make sure you have the best possible experience.", - "fr": "Merci pour vos commentaires. Nous sommes ravis d'entendre que vous avez apprécié notre produit. Vos commentaires nous aident à découvrir de nouvelles opportunités pour l'améliorer et vous assurer la meilleure expérience possible." - } - } + expression: "{nps-score} >= 8", + html: { + default: + "Thanks for your feedback. It's great to hear that you're a fan of our product. Your feedback helps us discover new opportunities to improve it and make sure you have the best possible experience.", + fr: "Merci pour vos commentaires. Nous sommes ravis d'entendre que vous avez apprécié notre produit. Vos commentaires nous aident à découvrir de nouvelles opportunités pour l'améliorer et vous assurer la meilleure expérience possible.", + }, + }, ], - "pages": [ + pages: [ { - "name": "page1", - "elements": [ + name: "page1", + elements: [ { - "type": "rating", - "name": "nps-score", - "title": { - "default": "On a scale from 0 to 10, how likely are you to recommend us to a friend or colleague?", - "fr": "Sur une échelle de 0 à 10, quelle est la probabilité que vous recommandiez notre produit à un ami ou à un collègue?" + type: "rating", + name: "nps-score", + title: { + default: + "On a scale from 0 to 10, how likely are you to recommend us to a friend or colleague?", + fr: "Sur une échelle de 0 à 10, quelle est la probabilité que vous recommandiez notre produit à un ami ou à un collègue?", }, - "rateCount": 11, - "rateMin": 0, - "rateMax": 10, - "minRateDescription": { - "default": "Very unlikely", - "fr": "Très improbable" + rateCount: 11, + rateMin: 0, + rateMax: 10, + minRateDescription: { + default: "Very unlikely", + fr: "Très improbable", }, - "maxRateDescription": { - "default": "Very likely", - "fr": "Très probable" + maxRateDescription: { + default: "Very likely", + fr: "Très probable", }, - "rateDescriptionLocation": "bottom" + rateDescriptionLocation: "bottom", }, { - "type": "comment", - "name": "disappointing-experience", - "visibleIf": "{nps-score} <= 5", - "title": { - "default": "How did we disappoint you and what can we do to make things right?", - "fr": "Nous n'avons pas été a la hauteur de vos attentes, comment pouvons-nous améliorer?" + type: "comment", + name: "disappointing-experience", + visibleIf: "{nps-score} <= 5", + title: { + default: + "How did we disappoint you and what can we do to make things right?", + fr: "Nous n'avons pas été a la hauteur de vos attentes, comment pouvons-nous améliorer?", }, - "maxLength": 300 + maxLength: 300, }, { - "type": "comment", - "name": "improvements-required", - "visibleIf": "{nps-score} >= 6", - "title": { - "default": "What can we do to make your experience more satisfying?", - "fr": "Que pouvons-nous faire pour rendre votre expérience plus satisfaisante?" + type: "comment", + name: "improvements-required", + visibleIf: "{nps-score} >= 6", + title: { + default: + "What can we do to make your experience more satisfying?", + fr: "Que pouvons-nous faire pour rendre votre expérience plus satisfaisante?", }, - "maxLength": 300 + maxLength: 300, }, { - "type": "checkbox", - "name": "promoter-features", - "visibleIf": "{nps-score} >= 9", - "title": { - "default": "Which of the following features do you value the most?", - "fr": "Laquelle des fonctionnalités suivantes appréciez-vous le plus ?" + type: "checkbox", + name: "promoter-features", + visibleIf: "{nps-score} >= 9", + title: { + default: "Which of the following features do you value the most?", + fr: "Laquelle des fonctionnalités suivantes appréciez-vous le plus ?", }, - "description": { - "default": "Please select no more than three features.", - "fr": "Veuillez ne pas sélectionner plus de trois fonctionnalités." + description: { + default: "Please select no more than three features.", + fr: "Veuillez ne pas sélectionner plus de trois fonctionnalités.", }, - "isRequired": true, - "choices": [ + isRequired: true, + choices: [ { - "value": "performance", - "text": "Performance" + value: "performance", + text: "Performance", }, { - "value": "stability", - "text": { - "default": "Stability", - "fr": "Stabilité" - } + value: "stability", + text: { + default: "Stability", + fr: "Stabilité", + }, }, { - "value": "ui", - "text": { - "default": "User interface", - "fr": "Interface utilisateur" - } + value: "ui", + text: { + default: "User interface", + fr: "Interface utilisateur", + }, }, { - "value": "complete-functionality", - "text": { - "default": "Complete functionality", - "fr": "Ensemble des fonctionnalités" - } + value: "complete-functionality", + text: { + default: "Complete functionality", + fr: "Ensemble des fonctionnalités", + }, }, { - "value": "learning-materials", - "text": { - "default": "Learning materials (documentation, demos, code examples)", - "fr": "Matériel d'apprentissage (documentation, démos, exemples de code)" - } + value: "learning-materials", + text: { + default: + "Learning materials (documentation, demos, code examples)", + fr: "Matériel d'apprentissage (documentation, démos, exemples de code)", + }, }, { - "value": "support", - "text": { - "default": "Quality support", - "fr": "Accompagnement de qualité" - } - } + value: "support", + text: { + default: "Quality support", + fr: "Accompagnement de qualité", + }, + }, ], - "showOtherItem": true, - "otherPlaceholder": { - "default": "Please specify...", - "fr": "Veuillez préciser..." + showOtherItem: true, + otherPlaceholder: { + default: "Please specify...", + fr: "Veuillez préciser...", }, - "otherText": { - "default": "Other features", - "fr": "Autres fonctionnalités" + otherText: { + default: "Other features", + fr: "Autres fonctionnalités", }, - "colCount": 2, - "maxSelectedChoices": 3 - } - ] + colCount: 2, + maxSelectedChoices: 3, + }, + ], }, { - "name": "page2", - "elements": [ + name: "page2", + elements: [ { - "type": "boolean", - "name": "rebuy", - "title": { - "default": "Would you buy our product again?", - "fr": "Achèteriez-vous à nouveau notre produit?" - } - } - ] + type: "boolean", + name: "rebuy", + title: { + default: "Would you buy our product again?", + fr: "Achèteriez-vous à nouveau notre produit?", + }, + }, + ], }, { - "name": "page3", - "elements": [ + name: "page3", + elements: [ { - "type": "radiogroup", - "name": "testimonial", - "title": { - "default": "Would you mind providing us a brief testimonial for the website?", - "fr": "Accepteriez-vous de rédiger un bref commentaire pour notre site Internet?" + type: "radiogroup", + name: "testimonial", + title: { + default: + "Would you mind providing us a brief testimonial for the website?", + fr: "Accepteriez-vous de rédiger un bref commentaire pour notre site Internet?", }, - "choices": [ + choices: [ { - "value": "yes", - "text": { - "default": "Sure!", - "fr": "Bien sur!" - } + value: "yes", + text: { + default: "Sure!", + fr: "Bien sur!", + }, }, { - "value": "no", - "text": { - "default": "No", - "fr": "Non merci." - } - } - ] + value: "no", + text: { + default: "No", + fr: "Non merci.", + }, + }, + ], }, { - "type": "text", - "name": "email", - "visibleIf": "{testimonial} = 'yes'", - "title": { - "default": "What is your email address?", - "fr": "Quelle est votre adresse e-mail?" + type: "text", + name: "email", + visibleIf: "{testimonial} = 'yes'", + title: { + default: "What is your email address?", + fr: "Quelle est votre adresse e-mail?", }, - "validators": [ + validators: [ { - "type": "email" - } + type: "email", + }, ], - "placeholder": { - "default": "Enter your email here", - "fr": "Veuillez saisir votre adresse e-mail ici" - } - } - ] - } + placeholder: { + default: "Enter your email here", + fr: "Veuillez saisir votre adresse e-mail ici", + }, + }, + ], + }, ], - "showPrevButton": false, - "showQuestionNumbers": "off", - "completeText": { - "fr": "Envoyer" - }, - "widthMode": "static", - "width": "1000px" - } \ No newline at end of file + showPrevButton: false, + showQuestionNumbers: "off", + completeText: { + fr: "Envoyer", + }, + widthMode: "static", + width: "1000px", + }, +}; diff --git a/src/data/patient.js b/src/data/patient.js index 7a62b2b..420a22f 100644 --- a/src/data/patient.js +++ b/src/data/patient.js @@ -1,654 +1,665 @@ +export const patientResults = []; + export const patient = { - "title": "Patient Assessment Form", - "logoPosition": "right", - "pages": [ + slug: "patient", + results: [], + survey: { + title: "Patient Assessment Form", + logoPosition: "right", + pages: [ { - "name": "Patient information", - "title": "Patient information", - "elements": [ + name: "Patient information", + title: "Patient information", + elements: [ { - "type": "panel", - "name": "patient-information", - "title": "All fields with an asterisk (*) are required fields, and must be filled out in order to process the information in strict confidentiality.", - "elements": [ + type: "panel", + name: "patient-information", + title: + "All fields with an asterisk (*) are required fields, and must be filled out in order to process the information in strict confidentiality.", + elements: [ { - "type": "text", - "name": "first-name", - "title": "First name", - "isRequired": true + type: "text", + name: "first-name", + title: "First name", + isRequired: true, }, { - "type": "text", - "name": "last-name", - "startWithNewLine": false, - "title": "Last name", - "isRequired": true + type: "text", + name: "last-name", + startWithNewLine: false, + title: "Last name", + isRequired: true, }, { - "type": "text", - "name": "ssn", - "title": "Social Security number", - "isRequired": true, - "requiredErrorText": "You SSN must be a 9-digit number.", - "validators": [ + type: "text", + name: "ssn", + title: "Social Security number", + isRequired: true, + requiredErrorText: "You SSN must be a 9-digit number.", + validators: [ { - "type": "regex", - "text": "Your SSN must be a 9-digit number", - "regex": "^(?!0{3})(?!6{3})[0-8]\\d{2}-?(?!0{2})\\d{2}-?(?!0{4})\\d{4}$" - } + type: "regex", + text: "Your SSN must be a 9-digit number", + regex: + "^(?!0{3})(?!6{3})[0-8]\\d{2}-?(?!0{2})\\d{2}-?(?!0{4})\\d{4}$", + }, ], - "maxLength": 9 + maxLength: 9, }, { - "type": "text", - "name": "birthdate", - "startWithNewLine": false, - "title": "Date of birth", - "isRequired": true, - "inputType": "date" + type: "text", + name: "birthdate", + startWithNewLine: false, + title: "Date of birth", + isRequired: true, + inputType: "date", }, { - "type": "text", - "name": "concerns", - "title": "List any concerns you want to talk about during your visit" - } - ] - } - ] + type: "text", + name: "concerns", + title: + "List any concerns you want to talk about during your visit", + }, + ], + }, + ], }, { - "name": "Health history", - "title": "Health history", - "elements": [ + name: "Health history", + title: "Health history", + elements: [ { - "type": "panel", - "name": "health-history", - "elements": [ + type: "panel", + name: "health-history", + elements: [ { - "type": "boolean", - "name": "diabetes", - "startWithNewLine": false, - "title": "Do you have diabetes?" + type: "boolean", + name: "diabetes", + startWithNewLine: false, + title: "Do you have diabetes?", }, { - "type": "boolean", - "name": "high-blood-pressure", - "startWithNewLine": false, - "title": "High blood pressure?" + type: "boolean", + name: "high-blood-pressure", + startWithNewLine: false, + title: "High blood pressure?", }, { - "type": "boolean", - "name": "high-cholesterol", - "startWithNewLine": false, - "title": "High cholesterol?" + type: "boolean", + name: "high-cholesterol", + startWithNewLine: false, + title: "High cholesterol?", }, { - "type": "comment", - "name": "other-health-conditions", - "title": "Do you have other health conditions?", - "maxLength": 300 - } - ] - } - ] + type: "comment", + name: "other-health-conditions", + title: "Do you have other health conditions?", + maxLength: 300, + }, + ], + }, + ], }, { - "name": "Social history", - "title": "Social history", - "elements": [ + name: "Social history", + title: "Social history", + elements: [ { - "type": "panel", - "name": "social-history", - "elements": [ + type: "panel", + name: "social-history", + elements: [ { - "type": "panel", - "name": "smoking", - "elements": [ + type: "panel", + name: "smoking", + elements: [ { - "type": "radiogroup", - "name": "cigarettes", - "title": "Do you smoke cigarettes?", - "choices": [ + type: "radiogroup", + name: "cigarettes", + title: "Do you smoke cigarettes?", + choices: [ { - "value": "never", - "text": "Never" + value: "never", + text: "Never", }, { - "value": "yes", - "text": "Yes" + value: "yes", + text: "Yes", }, { - "value": "quit", - "text": "Quit" - } - ] + value: "quit", + text: "Quit", + }, + ], }, { - "type": "text", - "name": "packs-a-day", - "visibleIf": "{cigarettes} = 'yes'", - "title": "How many packs a day?", - "inputType": "number", - "min": 0 + type: "text", + name: "packs-a-day", + visibleIf: "{cigarettes} = 'yes'", + title: "How many packs a day?", + inputType: "number", + min: 0, }, { - "type": "multipletext", - "name": "smoking-history", - "visibleIf": "{cigarettes} = 'quit'", - "titleLocation": "hidden", - "items": [ - { - "name": "date-quit", - "inputType": "date", - "title": "Date quit", - "maxValueExpression": "today()" - }, - { - "name": "years-smoked", - "inputType": "number", - "title": "Years smoked" - } - ] + type: "multipletext", + name: "smoking-history", + visibleIf: "{cigarettes} = 'quit'", + titleLocation: "hidden", + items: [ + { + name: "date-quit", + inputType: "date", + title: "Date quit", + maxValueExpression: "today()", + }, + { + name: "years-smoked", + inputType: "number", + title: "Years smoked", + }, + ], }, { - "type": "boolean", - "name": "vape", - "title": "Do you vape (e-cigarettes)?" - } - ] + type: "boolean", + name: "vape", + title: "Do you vape (e-cigarettes)?", + }, + ], }, { - "type": "panel", - "name": "alcohol-use-history", - "startWithNewLine": false, - "elements": [ + type: "panel", + name: "alcohol-use-history", + startWithNewLine: false, + elements: [ { - "type": "boolean", - "name": "alcohol", - "title": "Do you drink alcohol?" + type: "boolean", + name: "alcohol", + title: "Do you drink alcohol?", }, { - "type": "text", - "name": "drinks-per-week", - "visibleIf": "{alcohol} = true", - "title": "How many drinks per week?" - } - ] + type: "text", + name: "drinks-per-week", + visibleIf: "{alcohol} = true", + title: "How many drinks per week?", + }, + ], }, { - "type": "panel", - "name": "drug-use-history", - "elements": [ + type: "panel", + name: "drug-use-history", + elements: [ { - "type": "checkbox", - "name": "recreational-drugs", - "title": "Do you use recreational drugs?", - "choices": [ + type: "checkbox", + name: "recreational-drugs", + title: "Do you use recreational drugs?", + choices: [ { - "value": "rarely", - "text": "Rarely" + value: "rarely", + text: "Rarely", }, { - "value": "marijuana", - "text": "Marijuana" + value: "marijuana", + text: "Marijuana", }, { - "value": "cocaine", - "text": "Cocaine" + value: "cocaine", + text: "Cocaine", }, { - "value": "opioids", - "text": "Opioids" - } + value: "opioids", + text: "Opioids", + }, ], - "showOtherItem": true, - "showNoneItem": true, - "otherPlaceholder": "Please specify... ", - "noneText": "Never", - "otherText": "Other", - "colCount": 3 + showOtherItem: true, + showNoneItem: true, + otherPlaceholder: "Please specify... ", + noneText: "Never", + otherText: "Other", + colCount: 3, }, { - "type": "text", - "name": "drug-use-times-per-month", - "visibleIf": "{recreational-drugs} anyof ['rarely', 'marijuana', 'cocaine', 'opioids', 'other']", - "title": "How many times per month", - "description": "If you take different types of drugs, please specify the frequency of use for each in a 'drug - # times/month' format." - } - ] + type: "text", + name: "drug-use-times-per-month", + visibleIf: + "{recreational-drugs} anyof ['rarely', 'marijuana', 'cocaine', 'opioids', 'other']", + title: "How many times per month", + description: + "If you take different types of drugs, please specify the frequency of use for each in a 'drug - # times/month' format.", + }, + ], }, { - "type": "panel", - "name": "personal-info", - "elements": [ + type: "panel", + name: "personal-info", + elements: [ { - "type": "dropdown", - "name": "education", - "title": "What is your highest level of education completed?", - "choices": [ + type: "dropdown", + name: "education", + title: "What is your highest level of education completed?", + choices: [ { - "value": "high-school", - "text": "High School" + value: "high-school", + text: "High School", }, { - "value": "trade-school", - "text": "Trade School" + value: "trade-school", + text: "Trade School", }, { - "value": "college", - "text": "College" + value: "college", + text: "College", }, { - "value": "post-graduate", - "text": "Post-graduate degree(s)" - } - ] + value: "post-graduate", + text: "Post-graduate degree(s)", + }, + ], }, { - "type": "dropdown", - "name": "marital-status", - "title": "What is your marital status?", - "choices": [ + type: "dropdown", + name: "marital-status", + title: "What is your marital status?", + choices: [ { - "value": "married", - "text": "Married" + value: "married", + text: "Married", }, { - "value": "partnership", - "text": "Partnership" + value: "partnership", + text: "Partnership", }, { - "value": "divorced", - "text": "Divorced" + value: "divorced", + text: "Divorced", }, { - "value": "separated", - "text": "Separated" + value: "separated", + text: "Separated", }, { - "value": "single", - "text": "Single" + value: "single", + text: "Single", }, { - "value": "widow", - "text": "Widow(er)" - } - ] + value: "widow", + text: "Widow(er)", + }, + ], }, { - "type": "panel", - "name": "sexual-life", - "elements": [ + type: "panel", + name: "sexual-life", + elements: [ { - "type": "boolean", - "name": "sexually-active", - "title": "Are you sexually active?" + type: "boolean", + name: "sexually-active", + title: "Are you sexually active?", }, { - "type": "text", - "name": "sexual-partners-number", - "title": "How many sexual partners do you have?", - "inputType": "number", - "min": 0 + type: "text", + name: "sexual-partners-number", + title: "How many sexual partners do you have?", + inputType: "number", + min: 0, }, { - "type": "radiogroup", - "name": "sexual-partners-gender", - "titleLocation": "hidden", - "choices": [ + type: "radiogroup", + name: "sexual-partners-gender", + titleLocation: "hidden", + choices: [ { - "value": "men", - "text": "Men" + value: "men", + text: "Men", }, { - "value": "women", - "text": "Women" + value: "women", + text: "Women", }, { - "value": "both", - "text": "Both" - } + value: "both", + text: "Both", + }, ], - "colCount": 3 + colCount: 3, }, { - "type": "radiogroup", - "name": "contraception", - "title": "Do you use contraception?", - "showCommentArea": true, - "commentText": "If yes, what method?", - "choices": [ + type: "radiogroup", + name: "contraception", + title: "Do you use contraception?", + showCommentArea: true, + commentText: "If yes, what method?", + choices: [ { - "value": "yes", - "text": "Yes" + value: "yes", + text: "Yes", }, { - "value": "no", - "text": "No" - } - ] - } - ] - } - ] + value: "no", + text: "No", + }, + ], + }, + ], + }, + ], }, { - "type": "panel", - "name": "employment-exercises-children", - "startWithNewLine": false, - "elements": [ + type: "panel", + name: "employment-exercises-children", + startWithNewLine: false, + elements: [ { - "type": "radiogroup", - "name": "employment", - "title": "Are you employed?", - "showCommentArea": true, - "commentText": "Type of work", - "choices": [ + type: "radiogroup", + name: "employment", + title: "Are you employed?", + showCommentArea: true, + commentText: "Type of work", + choices: [ { - "value": "yes", - "text": "Yes" + value: "yes", + text: "Yes", }, { - "value": "no", - "text": "No" + value: "no", + text: "No", }, { - "value": "retired", - "text": "Retired" - } + value: "retired", + text: "Retired", + }, ], - "colCount": 3 + colCount: 3, }, { - "type": "panel", - "name": "physical-activity", - "elements": [ - { - "type": "radiogroup", - "name": "do-exercise", - "title": "Do you exercise?", - "choices": [ + type: "panel", + name: "physical-activity", + elements: [ + { + type: "radiogroup", + name: "do-exercise", + title: "Do you exercise?", + choices: [ { - "value": "yes", - "text": "Yes" + value: "yes", + text: "Yes", }, { - "value": "no", - "text": "No" - } + value: "no", + text: "No", + }, ], - "colCount": 2 + colCount: 2, }, { - "type": "multipletext", - "name": "activities", - "visibleIf": "{do-exercise} = 'yes'", - "titleLocation": "hidden", - "items": [ + type: "multipletext", + name: "activities", + visibleIf: "{do-exercise} = 'yes'", + titleLocation: "hidden", + items: [ { - "name": "activity-type", - "title": "Type of activity" + name: "activity-type", + title: "Type of activity", }, { - "name": "activity-frequency", - "title": "How often" + name: "activity-frequency", + title: "How often", }, { - "name": "activity-duration", - "title": "How long per activity" - } - ] - } - ] + name: "activity-duration", + title: "How long per activity", + }, + ], + }, + ], }, { - "type": "panel", - "name": "children", - "elements": [ + type: "panel", + name: "children", + elements: [ { - "type": "boolean", - "name": "have-children", - "title": "Do you have children?" + type: "boolean", + name: "have-children", + title: "Do you have children?", }, { - "type": "multipletext", - "name": "children-ages", - "visibleIf": "{have-children} = true", - "titleLocation": "hidden", - "items": [ + type: "multipletext", + name: "children-ages", + visibleIf: "{have-children} = true", + titleLocation: "hidden", + items: [ { - "name": "children-number", - "title": "# of children" + name: "children-number", + title: "# of children", }, { - "name": "ages", - "title": "Their ages" - } - ] - } - ] - } - ] - } - ] - } - ] + name: "ages", + title: "Their ages", + }, + ], + }, + ], + }, + ], + }, + ], + }, + ], }, { - "name": "Surgical history / recent hospitalizations", - "title": "Surgical history / recent hospitalizations", - "elements": [ + name: "Surgical history / recent hospitalizations", + title: "Surgical history / recent hospitalizations", + elements: [ { - "type": "comment", - "name": "surgery-description", - "title": "Date and type of surgery / procedure" - } - ] + type: "comment", + name: "surgery-description", + title: "Date and type of surgery / procedure", + }, + ], }, { - "name": "Family history", - "title": "Family history", - "elements": [ + name: "Family history", + title: "Family history", + elements: [ { - "type": "matrixdynamic", - "name": "family-history", - "titleLocation": "hidden", - "columns": [ + type: "matrixdynamic", + name: "family-history", + titleLocation: "hidden", + columns: [ { - "name": "relation", - "title": "Relation" + name: "relation", + title: "Relation", }, { - "name": "health-conditions", - "title": "Health conditions" + name: "health-conditions", + title: "Health conditions", }, { - "name": "cancer-history", - "title": "Family history of cancer" - } + name: "cancer-history", + title: "Family history of cancer", + }, ], - "cellType": "text" - } - ] + cellType: "text", + }, + ], }, { - "name": "Preventive care", - "title": "Preventive care", - "elements": [ + name: "Preventive care", + title: "Preventive care", + elements: [ { - "type": "panel", - "name": "preventive-care", - "elements": [ + type: "panel", + name: "preventive-care", + elements: [ { - "type": "panel", - "name": "recent-shots-panel", - "elements": [ + type: "panel", + name: "recent-shots-panel", + elements: [ { - "type": "matrixdropdown", - "name": "recent-shots", - "title": "Recent shots from a doctor or pharmacist", - "columns": [ + type: "matrixdropdown", + name: "recent-shots", + title: "Recent shots from a doctor or pharmacist", + columns: [ { - "name": "date", - "title": "Date" + name: "date", + title: "Date", }, { - "name": "place", - "title": "Place" - } + name: "place", + title: "Place", + }, ], - "cellType": "text", - "rows": [ + cellType: "text", + rows: [ { - "value": "flu", - "text": "Flu" + value: "flu", + text: "Flu", }, { - "value": "shingles", - "text": "Shingles" + value: "shingles", + text: "Shingles", }, { - "value": "pneumonia", - "text": "Pneumonia" + value: "pneumonia", + text: "Pneumonia", }, { - "value": "tetanus", - "text": "Tetanus" + value: "tetanus", + text: "Tetanus", }, { - "value": "other", - "text": "Other" - } - ] - } - ] + value: "other", + text: "Other", + }, + ], + }, + ], }, { - "type": "panel", - "name": "recent-tests-panel", - "startWithNewLine": false, - "elements": [ + type: "panel", + name: "recent-tests-panel", + startWithNewLine: false, + elements: [ { - "type": "matrixdropdown", - "name": "recent-tests", - "title": "Recent tests or procedures", - "columns": [ + type: "matrixdropdown", + name: "recent-tests", + title: "Recent tests or procedures", + columns: [ { - "name": "date", - "title": "Date" + name: "date", + title: "Date", }, { - "name": "place", - "title": "Place" - } + name: "place", + title: "Place", + }, ], - "cellType": "text", - "rows": [ + cellType: "text", + rows: [ { - "value": "colonoscopy", - "text": "Colonoscopy" + value: "colonoscopy", + text: "Colonoscopy", }, { - "value": "cologuard", - "text": "Cologuard" + value: "cologuard", + text: "Cologuard", }, { - "value": "mammogram", - "text": "Mammogram" + value: "mammogram", + text: "Mammogram", }, { - "value": "pap", - "text": "PAP" + value: "pap", + text: "PAP", }, { - "value": "other", - "text": "Other" - } - ] - } - ] + value: "other", + text: "Other", + }, + ], + }, + ], }, { - "type": "panel", - "name": "specialists-panel", - "elements": [ + type: "panel", + name: "specialists-panel", + elements: [ { - "type": "matrixdynamic", - "name": "specialists", - "title": "Specialists", - "columns": [ + type: "matrixdynamic", + name: "specialists", + title: "Specialists", + columns: [ { - "name": "provider", - "title": "Provider's first and last name" + name: "provider", + title: "Provider's first and last name", }, { - "name": "speciality", - "title": "Speciality" + name: "speciality", + title: "Speciality", }, { - "name": "city", - "title": "Town/City" - } + name: "city", + title: "Town/City", + }, ], - "cellType": "text", - "rowCount": 1 - } - ] + cellType: "text", + rowCount: 1, + }, + ], }, { - "type": "panel", - "name": "medications-and-allergies", - "elements": [ + type: "panel", + name: "medications-and-allergies", + elements: [ { - "type": "multipletext", - "name": "medications", - "title": "Medications", - "items": [ + type: "multipletext", + name: "medications", + title: "Medications", + items: [ { - "name": "medication-name", - "title": "Name" + name: "medication-name", + title: "Name", }, { - "name": "medication-dose", - "title": "Dose" + name: "medication-dose", + title: "Dose", }, { - "name": "medication-times-per-day", - "title": "Times per day" - } - ] + name: "medication-times-per-day", + title: "Times per day", + }, + ], }, { - "type": "multipletext", - "name": "allergies", - "startWithNewLine": false, - "title": "Allergies", - "items": [ - { - "name": "allergy-type", - "title": "Type" - }, - { - "name": "allergy-reaction", - "title": "Reaction" - } - ] - } - ] - } - ] - } - ] + type: "multipletext", + name: "allergies", + startWithNewLine: false, + title: "Allergies", + items: [ + { + name: "allergy-type", + title: "Type", + }, + { + name: "allergy-reaction", + title: "Reaction", + }, + ], + }, + ], + }, + ], + }, + ], }, { - "name": "Symptoms", - "title": "Symptoms", - "elements": [ + name: "Symptoms", + title: "Symptoms", + elements: [ { - "type": "tagbox", - "name": "symptoms", - "title": "Please select any symptoms you have now or have had in the past month.", - "choices": [ + type: "tagbox", + name: "symptoms", + title: + "Please select any symptoms you have now or have had in the past month.", + choices: [ "Fever", "Chills", "Feeling poorly", @@ -671,32 +682,33 @@ export const patient = { "Rash", "Itching", "Change in a mole", - "Unusual growth/spot" - ] + "Unusual growth/spot", + ], }, { - "type": "signaturepad", - "name": "signature", - "title": "Signature:", - "titleLocation": "left" + type: "signaturepad", + name: "signature", + title: "Signature:", + titleLocation: "left", }, { - "type": "text", - "name": "current-date", - "startWithNewLine": false, - "title": "Today's date:", - "titleLocation": "left", - "defaultValueExpression": "today()", - "inputType": "date" - } - ] - } + type: "text", + name: "current-date", + startWithNewLine: false, + title: "Today's date:", + titleLocation: "left", + defaultValueExpression: "today()", + inputType: "date", + }, + ], + }, ], - "showQuestionNumbers": "off", - "questionErrorLocation": "bottom", - "showTOC": true, - "completeText": "Submit", - "showPreviewBeforeComplete": "showAllQuestions", - "widthMode": "static", - "width": "1200px" - } \ No newline at end of file + showQuestionNumbers: "off", + questionErrorLocation: "bottom", + showTOC: true, + completeText: "Submit", + showPreviewBeforeComplete: "showAllQuestions", + widthMode: "static", + width: "1200px", + }, +}; diff --git a/src/data/pizza.js b/src/data/pizza.js index bbd37bf..a7e5183 100644 --- a/src/data/pizza.js +++ b/src/data/pizza.js @@ -1,361 +1,353 @@ export const pizza = { - "title": "Pizza Order Form", - "logoPosition": "right", - "completedHtml": "

Thank you for placing the order!

", - "pages": [ + slug: "pizza", + results: [], + survey: { + title: "Pizza Order Form", + logoPosition: "right", + completedHtml: "

Thank you for placing the order!

", + pages: [ { - "name": "page1", - "elements": [ + name: "page1", + elements: [ { - "type": "panel", - "name": "neapolitan", - "elements": [ + type: "panel", + name: "neapolitan", + elements: [ { - "type": "expression", - "name": "price_n", - "minWidth": "220px", - "title": "Pizza Neapolitan", - "description": "tomato sauce, mozzarella, anchovies, bazil", - "descriptionLocation": "underTitle", - "expression": "5 + {size_n}", - "displayStyle": "currency" + type: "expression", + name: "price_n", + minWidth: "220px", + title: "Pizza Neapolitan", + description: "tomato sauce, mozzarella, anchovies, bazil", + descriptionLocation: "underTitle", + expression: "5 + {size_n}", + displayStyle: "currency", }, { - "type": "image", - "name": "pic_n", - "width": "180px", - "minWidth": "180px", - "maxWidth": "180px", - "startWithNewLine": false, - "imageLink": "https://api.surveyjs.io/private/Surveys/files?name=c5b0302a-d6c8-46b4-ac57-7d519d0df0d1", - "contentMode": "image", - "imageFit": "cover", - "imageHeight": 80, - "imageWidth": 180 + type: "image", + name: "pic_n", + width: "180px", + minWidth: "180px", + maxWidth: "180px", + startWithNewLine: false, + imageLink: + "https://api.surveyjs.io/private/Surveys/files?name=c5b0302a-d6c8-46b4-ac57-7d519d0df0d1", + contentMode: "image", + imageFit: "cover", + imageHeight: 80, + imageWidth: 180, }, { - "type": "dropdown", - "name": "size_n", - "minWidth": "220px", - "title": "Size", - "titleLocation": "left", - "defaultValue": 1, - "choices": [ + type: "dropdown", + name: "size_n", + minWidth: "220px", + title: "Size", + titleLocation: "left", + defaultValue: 1, + choices: [ { - "value": 0, - "text": "Small" + value: 0, + text: "Small", }, { - "value": 1, - "text": "Medium" + value: 1, + text: "Medium", }, { - "value": 2, - "text": "Large" - } + value: 2, + text: "Large", + }, ], - "allowClear": false + allowClear: false, }, { - "type": "dropdown", - "name": "qty_n", - "minWidth": "220px", - "startWithNewLine": false, - "title": "Qty", - "titleLocation": "left", - "choices": [ - 1, - 2, - 3, - 4, - 5 - ] - } - ] + type: "dropdown", + name: "qty_n", + minWidth: "220px", + startWithNewLine: false, + title: "Qty", + titleLocation: "left", + choices: [1, 2, 3, 4, 5], + }, + ], }, { - "type": "panel", - "name": "pepperoni", - "elements": [ + type: "panel", + name: "pepperoni", + elements: [ { - "type": "expression", - "name": "price_p", - "title": "Pepperoni", - "titleLocation": "top", - "description": "tomato sauce, pepperoni, red peppers, onion", - "expression": "5 + {size_p}", - "displayStyle": "currency" + type: "expression", + name: "price_p", + title: "Pepperoni", + titleLocation: "top", + description: "tomato sauce, pepperoni, red peppers, onion", + expression: "5 + {size_p}", + displayStyle: "currency", }, { - "type": "image", - "name": "pic_p", - "width": "180px", - "minWidth": "180px", - "maxWidth": "180px", - "startWithNewLine": false, - "imageLink": "https://api.surveyjs.io/private/Surveys/files?name=8bcd88b7-df19-466d-8622-19100e400383", - "contentMode": "image", - "imageFit": "cover", - "imageHeight": 80, - "imageWidth": 180 + type: "image", + name: "pic_p", + width: "180px", + minWidth: "180px", + maxWidth: "180px", + startWithNewLine: false, + imageLink: + "https://api.surveyjs.io/private/Surveys/files?name=8bcd88b7-df19-466d-8622-19100e400383", + contentMode: "image", + imageFit: "cover", + imageHeight: 80, + imageWidth: 180, }, { - "type": "dropdown", - "name": "size_p", - "minWidth": "220px", - "title": "Size", - "titleLocation": "left", - "defaultValue": 1, - "choices": [ + type: "dropdown", + name: "size_p", + minWidth: "220px", + title: "Size", + titleLocation: "left", + defaultValue: 1, + choices: [ { - "value": 0, - "text": "Small" + value: 0, + text: "Small", }, { - "value": 1, - "text": "Medium" + value: 1, + text: "Medium", }, { - "value": 2, - "text": "Large" - } + value: 2, + text: "Large", + }, ], - "allowClear": false + allowClear: false, }, { - "type": "dropdown", - "name": "qty_p", - "minWidth": "220px", - "startWithNewLine": false, - "title": "Qty", - "titleLocation": "left", - "choices": [ - 1, - 2, - 3, - 4, - 5 - ] - } - ] + type: "dropdown", + name: "qty_p", + minWidth: "220px", + startWithNewLine: false, + title: "Qty", + titleLocation: "left", + choices: [1, 2, 3, 4, 5], + }, + ], }, { - "type": "panel", - "name": "marinara", - "elements": [ + type: "panel", + name: "marinara", + elements: [ { - "type": "expression", - "name": "price_m", - "title": "Marinara", - "description": "tomato sauce, tuna, shrimps, mushrooms, cheese, onion", - "expression": "5 + {size_m}", - "displayStyle": "currency" + type: "expression", + name: "price_m", + title: "Marinara", + description: + "tomato sauce, tuna, shrimps, mushrooms, cheese, onion", + expression: "5 + {size_m}", + displayStyle: "currency", }, { - "type": "image", - "name": "pic_m", - "width": "180px", - "minWidth": "180px", - "maxWidth": "180px", - "startWithNewLine": false, - "imageLink": "https://api.surveyjs.io/private/Surveys/files?name=24735b69-0ffe-4e49-9c90-1d9db1c8b83b", - "contentMode": "image", - "imageFit": "cover", - "imageHeight": 80, - "imageWidth": 180 + type: "image", + name: "pic_m", + width: "180px", + minWidth: "180px", + maxWidth: "180px", + startWithNewLine: false, + imageLink: + "https://api.surveyjs.io/private/Surveys/files?name=24735b69-0ffe-4e49-9c90-1d9db1c8b83b", + contentMode: "image", + imageFit: "cover", + imageHeight: 80, + imageWidth: 180, }, { - "type": "dropdown", - "name": "size_m", - "minWidth": "220px", - "title": "Size", - "titleLocation": "left", - "defaultValue": 1, - "choices": [ + type: "dropdown", + name: "size_m", + minWidth: "220px", + title: "Size", + titleLocation: "left", + defaultValue: 1, + choices: [ { - "value": 0, - "text": "Small" + value: 0, + text: "Small", }, { - "value": 1, - "text": "Medium" + value: 1, + text: "Medium", }, { - "value": 2, - "text": "Large" - } + value: 2, + text: "Large", + }, ], - "allowClear": false + allowClear: false, }, { - "type": "dropdown", - "name": "qty_m", - "minWidth": "220px", - "startWithNewLine": false, - "title": "Qty", - "titleLocation": "left", - "choices": [ - 1, - 2, - 3, - 4, - 5 - ] - } - ] + type: "dropdown", + name: "qty_m", + minWidth: "220px", + startWithNewLine: false, + title: "Qty", + titleLocation: "left", + choices: [1, 2, 3, 4, 5], + }, + ], }, { - "type": "expression", - "name": "question5", - "title": "Total", - "expression": "{price_n} * {qty_n} + {price_m} * {qty_m} + {price_p} * {qty_p}", - "displayStyle": "currency" - } - ] + type: "expression", + name: "question5", + title: "Total", + expression: + "{price_n} * {qty_n} + {price_m} * {qty_m} + {price_p} * {qty_p}", + displayStyle: "currency", + }, + ], }, { - "name": "page2", - "elements": [ + name: "page2", + elements: [ { - "type": "panel", - "name": "toppings-panel", - "elements": [ + type: "panel", + name: "toppings-panel", + elements: [ { - "type": "checkbox", - "name": "toppings", - "title": "Toppings", - "choices": [ + type: "checkbox", + name: "toppings", + title: "Toppings", + choices: [ "Olives", "Mozzarella", "Mushrooms", "Red pepper", "Pepperoni", - "Shrimps" + "Shrimps", ], - "colCount": 3 - } - ] + colCount: 3, + }, + ], }, { - "type": "panel", - "name": "delivery-panel", - "elements": [ + type: "panel", + name: "delivery-panel", + elements: [ { - "type": "boolean", - "name": "need-delivery", - "title": "Would you like the order delivered?", - "defaultValue": "false" + type: "boolean", + name: "need-delivery", + title: "Would you like the order delivered?", + defaultValue: "false", }, { - "type": "text", - "name": "pickup-date", - "visibleIf": "{need-delivery} = false", - "title": "Pickup Date", - "inputType": "date" + type: "text", + name: "pickup-date", + visibleIf: "{need-delivery} = false", + title: "Pickup Date", + inputType: "date", }, { - "type": "text", - "name": "Pickup-time", - "visibleIf": "{need-delivery} = false", - "startWithNewLine": false, - "title": "Pickup Time", - "isRequired": true, - "inputType": "time" + type: "text", + name: "Pickup-time", + visibleIf: "{need-delivery} = false", + startWithNewLine: false, + title: "Pickup Time", + isRequired: true, + inputType: "time", }, { - "type": "text", - "name": "delivery-address", - "visibleIf": "{need-delivery} = true", - "title": "Delivery Address" + type: "text", + name: "delivery-address", + visibleIf: "{need-delivery} = true", + title: "Delivery Address", }, { - "type": "text", - "name": "delivery-date", - "visibleIf": "{need-delivery} = true", - "title": "Delivery Date", - "isRequired": true, - "inputType": "date" + type: "text", + name: "delivery-date", + visibleIf: "{need-delivery} = true", + title: "Delivery Date", + isRequired: true, + inputType: "date", }, { - "type": "text", - "name": "delivery-time", - "visibleIf": "{need-delivery} = true", - "startWithNewLine": false, - "title": "Delivery Time", - "isRequired": true, - "inputType": "time" - } - ] - } - ] + type: "text", + name: "delivery-time", + visibleIf: "{need-delivery} = true", + startWithNewLine: false, + title: "Delivery Time", + isRequired: true, + inputType: "time", + }, + ], + }, + ], }, { - "name": "page3", - "elements": [ + name: "page3", + elements: [ { - "type": "panel", - "name": "contacts", - "elements": [ + type: "panel", + name: "contacts", + elements: [ { - "type": "text", - "name": "phone", - "title": "Phone number", - "autocomplete": "tel", - "maskType": "pattern", - "maskSettings": { - "saveMaskedValue": true, - "pattern": "+1 (999) 999-99-99" - } + type: "text", + name: "phone", + title: "Phone number", + autocomplete: "tel", + maskType: "pattern", + maskSettings: { + saveMaskedValue: true, + pattern: "+1 (999) 999-99-99", + }, }, { - "type": "text", - "name": "email", - "startWithNewLine": false, - "title": "Email", - "validators": [ + type: "text", + name: "email", + startWithNewLine: false, + title: "Email", + validators: [ { - "type": "email", - "text": "Please enter a valid email in the example@example.com format." - } + type: "email", + text: "Please enter a valid email in the example@example.com format.", + }, ], - "inputType": "email", - "autocomplete": "email", - "placeholder": "Enter your email to receive an order confirmation and a receipt" - } - ] + inputType: "email", + autocomplete: "email", + placeholder: + "Enter your email to receive an order confirmation and a receipt", + }, + ], }, { - "type": "panel", - "name": "full-name-panel", - "elements": [ + type: "panel", + name: "full-name-panel", + elements: [ { - "type": "multipletext", - "name": "full-name", - "title": "Full name", - "items": [ + type: "multipletext", + name: "full-name", + title: "Full name", + items: [ { - "name": "first-name", - "title": "First name" + name: "first-name", + title: "First name", }, { - "name": "last-name", - "title": "Last name" - } - ] - } - ] + name: "last-name", + title: "Last name", + }, + ], + }, + ], }, { - "type": "html", - "name": "question4", - "html": "