{"_id":"@artezio/surveybuilder","_rev":"3-48e3383bd0e5e8e359ceaeed2ae02a20","name":"@artezio/surveybuilder","dist-tags":{"latest":"1.0.6"},"versions":{"1.0.4":{"name":"@artezio/surveybuilder","main":"./dist/bundle.js","version":"1.0.4","license":"MIT","publishConfig":{"access":"public"},"scripts":{"build":"webpack"},"dependencies":{"@artezio/designer":"^0.1.14","@artezio/fhir-converter":"^1.0.7","@artezio/models":"^0.1.13","@artezio/observable":"^1.0.5","@artezio/observable-react":"^1.0.7","@artezio/player":"^0.1.9"},"peerDependencies":{"react":"^16.8.3"},"devDependencies":{"bootstrap":"^4.3.1","bootstrap-scss":"4.3.1","css-loader":"2.1.1","sass-loader":"7.2.0","style-loader":"1.0.0","ts-loader":"^6.1.0","typescript":"^3.6.2","webpack":"4.40.2","webpack-cli":"^3.3.9"},"gitHead":"86244b4790327a8830bb3ec86f1347864a8ac62d","description":"FHIR R4 compatibly questionnaire designer/player. If you are not familiar with medical standard FHIR R4 check out the [following refs](#interesting-references).","_id":"@artezio/surveybuilder@1.0.4","_nodeVersion":"10.16.3","_npmVersion":"6.11.2","dist":{"integrity":"sha512-pKL+oi/gWY4gGjoV5v+IZQb6ajgZHobi8Q1KfYymOHKLBnO6ygzX0nFuz3jC07UcTvO88E/UceGLUJrM7kox4g==","shasum":"645f6172ae330c9cd7481c866188fe0a4e799910","tarball":"https://registry.npmjs.org/@artezio/surveybuilder/-/surveybuilder-1.0.4.tgz","fileCount":9,"unpackedSize":331703,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJeANWOCRA9TVsSAnZWagAA/MoP/2TLhZ1ThKiRp0NDOXje\nwe6MDCVvjlcZ1qRgpm6kOcSk6+B528p6fNPPcjlWqRvribz+taIduuYpiIea\nOSoHqXUWm5tuZKmyKXDjj/Yk+mkLaNt71WMd+9HfXTIq9wmmzqLuVwjlkrDL\nrhWyIerhBCdmVUCYZgDw+2IOmQPMJ769Bv6f+5qviYfFzE0b1hagipmGmwKK\nn07bjsOsYwSki8z0yb4JlwzPPDHCFUWUggbA8Iy2GiVidHPFf98zmceLhl7w\nolY05bThYggHZmQIO4lc6r6aH09jvxxhFAc1Cn+96XRGcllaOjS8Y+T8i5Qe\nV12ihj/uibwBlXBXhMpMJYOe3tNzV6AlcjRTZZZzATrHYsaoH99S21n1CgYd\noLJL6vcS3kISTAReJB7GLZE1BKPsDzHqlJLDVB45bwkiPgMnRxQLW9mAxEBP\nzNpT0XzXdXg3w80evuH0OgusUwCLdUOmXT+qUCJJK2pqp7i56GEU2GCjVp2H\nQZidkUAlbTJY1bOCvpYlm2NAJhQO197oDKnPsry5/FHb0qVOqdfUb8gkAVMZ\nJuxoF7Q4nMxv/wHISwbGhl5mT3xmXSoYUICiYwZK30RWS+E83BH/fWtGjjYA\nKJyTPDRuDFwZj8PRyaD4uzprA0KKMkaUrWf8kpMgafQ2tfGdt8tykAwJj4ul\nRuUY\r\n=M1fU\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDziV80gBJZ0HF25gwwJ4dyykTB5lwEZYA3AD5Ogzj0rQIgDBDtC2B8RVG+8LHqtIJtFqxK22Xw8teegtRikqPXYd0="}]},"maintainers":[{"name":"daniil_yakovenko","email":"Daniil.Yakovenko@artezio.com"},{"name":"kluiko","email":"support@artezio.com"}],"_npmUser":{"name":"daniil_yakovenko","email":"Daniil.Yakovenko@artezio.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/surveybuilder_1.0.4_1577112973978_0.035016055908532406"},"_hasShrinkwrap":false},"1.0.5":{"name":"@artezio/surveybuilder","main":"./dist/bundle.js","version":"1.0.5","license":"MIT","publishConfig":{"access":"public"},"scripts":{"build":"webpack"},"repository":{"type":"git","url":"git+https://github.com/Artezio/SURVEYBUILDER.git"},"dependencies":{"@artezio/designer":"^0.1.15","@artezio/fhir-converter":"^1.0.8","@artezio/models":"^0.1.14","@artezio/observable":"^1.0.6","@artezio/observable-react":"^1.0.8","@artezio/player":"^0.1.10"},"peerDependencies":{"react":"^16.8.3"},"devDependencies":{"bootstrap":"^4.3.1","bootstrap-scss":"4.3.1","css-loader":"2.1.1","sass-loader":"7.2.0","style-loader":"1.0.0","ts-loader":"^6.1.0","typescript":"^3.6.2","webpack":"4.40.2","webpack-cli":"^3.3.9"},"gitHead":"30605a263113e9f29a90a65952bc18ba1b657813","description":"FHIR R4 compatibly questionnaire designer/player. If you are not familiar with medical standard FHIR R4 check out the [following refs](#interesting-references).","bugs":{"url":"https://github.com/Artezio/SURVEYBUILDER/issues"},"homepage":"https://github.com/Artezio/SURVEYBUILDER#readme","_id":"@artezio/surveybuilder@1.0.5","_nodeVersion":"10.16.3","_npmVersion":"lerna/3.19.0/node@v10.16.3+x64 (win32)","dist":{"integrity":"sha512-Gp2wabIgKpcZcFl56bvljK1FU9UZUaUrDUBtUqnprGiFgB1iO4nKjKnemNHpi3lOT7nI1aLFNNDA9j+LjY03Gw==","shasum":"9dec69990a4d5ea6bfc6c712fb9271aa5a216e7d","tarball":"https://registry.npmjs.org/@artezio/surveybuilder/-/surveybuilder-1.0.5.tgz","fileCount":9,"unpackedSize":331800,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJeAbulCRA9TVsSAnZWagAA/EEP+wfv9rHkgwoPUGZzTKyt\nTFR+kkDsE9Tdog13T/rzin3swMSuW/CtXslDFxMQkgdeooYR+oQkcDuemekP\nyOxvm96eCLiOgm2KTs6NL1WR9iG7OHB/KyoxSHakhzUzkiommc+zc/+Mvw+P\nxvOar9NaqEawhvjgqrsfWmp7RnfdeOvmzl7thjw3wsgpQb8E85CulMwFdm2r\nU9/DQb5T3eWw29l3mcB3+refcEUaF81Rno82qMpukshWNPaJrs1FjT3XrRX2\nQsck+hXxgpr8iTPJkADGLxDRhigoEY2XhbKqHj5hJ+ClM0FFMQQOierbiEXV\n9B7B1wY9wB5o6PBtKyizYUBGPQJfmOrEDAiRxBhuP1XRx388GiygyXc22dU3\nXdh6Ez7mXEjdBMD/WFe3Xxp4IfuVVTf2Dq+1Y9codpEuYSNAzX1UgtQQdmz+\nD+mSz/mvodPyFSzso6Z493p2wXE0DdGqdY7jZMQ1vk1X77+6PD9tA1kk0RTZ\n12YqTqmXzIveoMFgiP8LfWzzsSupiaPfKh1H/EsAuYyXMjs67LfSLkKabsrP\nEJdYeDJz9ohu/EB696sU5wKkKPijrxmloTjiDKUc+ZlQF2Irgzo6g+cV09Ey\nIkKjJkOWRzubh2KG6v8bevBO/43BxFVCu1NtBMTaGkmI1gGPI/kaWDXxSahe\n5iaf\r\n=HTeQ\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIETgdg/REYdG7XJ5PIQLHTTkNGMv9IOt9xgeMlwEh7fvAiByJdZwYER2rTFauneAoXXOFyY+OVMEfwFc3c/MezQbIA=="}]},"maintainers":[{"name":"daniil_yakovenko","email":"Daniil.Yakovenko@artezio.com"},{"name":"kluiko","email":"support@artezio.com"}],"_npmUser":{"name":"daniil_yakovenko","email":"Daniil.Yakovenko@artezio.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/surveybuilder_1.0.5_1577171876635_0.8857043891330967"},"_hasShrinkwrap":false},"1.0.6":{"name":"@artezio/surveybuilder","main":"./dist/bundle.js","version":"1.0.6","license":"MIT","publishConfig":{"access":"public"},"scripts":{"build":"webpack"},"repository":{"type":"git","url":"git+https://github.com/Artezio/SURVEYBUILDER.git"},"dependencies":{"@artezio/designer":"^0.1.15","@artezio/fhir-converter":"^1.0.8","@artezio/models":"^0.1.14","@artezio/observable":"^1.0.6","@artezio/observable-react":"^1.0.8","@artezio/player":"^0.1.11"},"peerDependencies":{"react":"^16.8.3"},"devDependencies":{"bootstrap":"^4.3.1","bootstrap-scss":"4.3.1","css-loader":"2.1.1","sass-loader":"7.2.0","style-loader":"1.0.0","ts-loader":"^6.1.0","typescript":"^3.6.2","webpack":"4.40.2","webpack-cli":"^3.3.9"},"gitHead":"a70b15968f447789ab728cf619408d175be1ce0f","description":"FHIR R4 compatibly questionnaire designer/player. If you are not familiar with medical standard FHIR R4 check out the [following refs](#interesting-references).","bugs":{"url":"https://github.com/Artezio/SURVEYBUILDER/issues"},"homepage":"https://github.com/Artezio/SURVEYBUILDER#readme","_id":"@artezio/surveybuilder@1.0.6","_nodeVersion":"12.16.1","_npmVersion":"lerna/3.19.0/node@v12.16.1+x64 (win32)","dist":{"integrity":"sha512-nQGNdOaitEjQgChjxR9rJDN6qTTttQ5TrukMb7eYSXCScsxMQ1bVYhkcH1BRGk24H0905yg7i6FDxFjz46Lzkg==","shasum":"abcec3cb035732d959b81af6158febab9766055c","tarball":"https://registry.npmjs.org/@artezio/surveybuilder/-/surveybuilder-1.0.6.tgz","fileCount":9,"unpackedSize":331995,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJeg0VgCRA9TVsSAnZWagAAnsEQAJ0ORtZUAaVcTq8MaFog\nrGdYJaLsHusRL6diouK3WeRSJ4RYmazIlLdQHvyMy6YVRKCzxDId8zqTsIFQ\ndDHTKJWdqOSSqiCbXlwRd3P1XiX82oBUoHu23brV0GkaQX9zhh6I3MmVXzb6\n49teK6t+/kOHK8wP2KuI7JH011P3Su85JS5JxIu5ew39kfhEqw0Kt4ooxTOV\nit8tNClz2KzBgHXFywvoMnxiufC1ZZKI5W8WJmeHiATUfpLvxoOQ7PcvMhnS\n1X3zXDHCf/K0eUb+8Q1zoQbLTdpp6EKf7wruYV9CccVzIZmaf9fkPz2rMlcg\nSC5j9dfPlhlafbUk//xWo/ZWOx8vpR3kXYT8aT25+JcZRvwvd1emc3bvfoYk\nWzNSv8d4zgQuWzJbJD+FlwjrFtG5wVwfVXgbxMBIZZlm/y8q+LhsD4+D4kYm\nWxCh6zHt9bmrvxxD9Smk5e0ZCL0oEWpF7cMfQYORZt243WWx4ZkN1V9fJxuG\n0bOpTv5jclVuokY7JaUKs6yNlcptMRsUwrbr7BP3JLndUTNILvbs+LIkLHg7\nDgg9JpH2wFrncuI3RRscVe6KStispooO+WN+zuwkRXqJGbzuim81aRa9IbQ2\njJmJfYHp1gryaSk9gOJdAaYDoKuA/9LUEdnGKj4MHx1Vb+UrKOaTjd9ceoG0\nqSgI\r\n=yBV2\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDBGlwqntDNIysmUrh3bUAc+K/pjweCxNV77jad/XtuowIhAJp3SFi0JMzStCpcJeTx5EaPEvoXNEZDOlgDsgzZ3XeH"}]},"maintainers":[{"name":"daniil_yakovenko","email":"Daniil.Yakovenko@artezio.com"},{"name":"kluiko","email":"support@artezio.com"}],"_npmUser":{"name":"daniil_yakovenko","email":"Daniil.Yakovenko@artezio.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/surveybuilder_1.0.6_1585661279621_0.3205528359542895"},"_hasShrinkwrap":false}},"time":{"created":"2019-12-23T14:56:13.749Z","1.0.4":"2019-12-23T14:56:14.109Z","modified":"2022-04-04T15:37:12.490Z","1.0.5":"2019-12-24T07:17:56.775Z","1.0.6":"2020-03-31T13:27:59.721Z"},"maintainers":[{"name":"daniil_yakovenko","email":"Daniil.Yakovenko@artezio.com"},{"name":"kluiko","email":"support@artezio.com"}],"description":"FHIR R4 compatibly questionnaire designer/player. If you are not familiar with medical standard FHIR R4 check out the [following refs](#interesting-references).","license":"MIT","readme":"# **SURVEYBUILDER**\r\nFHIR R4 compatibly questionnaire designer/player. If you are not familiar with medical standard FHIR R4 check out the [following refs](#interesting-references).\r\n\r\nSurveybuilder is a set of typescript packages. It presents two react components: \"Questionnaire Designer\" and \"Questionnaire Player\". Questionnaire designer is designed to create/update questionnaires. Questionnaire player is designed to answer questionnaires. Components are designed in bootstrap style, so you can easily add bootstrap themes to change there appearance. This components work with our observable models from models package, but this models are fully compatible with FHIR R4 standard. All models can be converted to FHIR R4 standard and back via fhir-converter package. Surveybuilder can be also used in other spheres. To serialize models to another format different from FHIR R4 you must use your custom converter. See how to add your converter in section [below](#applying-custom-converter).\r\n\r\n# Interesting references\r\n\r\n* HL7 FHIR - http://hl7.org/fhir/\r\n* Questionnaire FHIR model - https://www.hl7.org/fhir/questionnaire.html\r\n* Questionnaire response FHIR model - https://www.hl7.org/fhir/questionnaireresponse.html\r\n\r\n\r\n# Installation\r\n\r\nUsing npm:\r\n>$ npm install @artezio/surveybuilder\r\n\r\nUsing yarn:\r\n>$ yarn add @artezio/surveybuilder\r\n\r\n# Usage \r\n\r\nDesigner\r\n```TSX\r\nimport { render } from 'react-dom';\r\nimport { Questionnaire, QuestionnaireDesigner } from '@artezio/surveybuilder';\r\n\r\nconst questionnaireModel = new Questionnaire();\r\nrender(<QuestionnaireDesigner questionnaireModel={questionnaireModel} />, document.getElementById('root'));\r\n```\r\n\r\nPlayer\r\n```TSX\r\nimport { render } from 'react-dom';\r\nimport { QuestionnaireResponse, QuestionnairePlayer } from '@artezio/surveybuilder';\r\n\r\nconst questionnaire = { \r\n    title: 'My Questionnaire', \r\n    items: [\r\n        { test: 'Do you smoke?', type: 'BOOLEAN' }\r\n    ] \r\n};\r\nconst questionnaireResponseModel = new QuestionnaireResponse(questionnaire);\r\nrender(<QuestionnairePlayer questionnaireResponseModel={questionnaireModel} questionnaire={questionnaire} />, document.getElementById('root'));\r\n```\r\n\r\nRead instructions how to use packages separately in [section below](#learn-more-about-packages).\r\n\r\n# Components diagram\r\n\r\n![uml diagram](./doc/Uml-diagram-modules.jpg)\r\n\r\n# Learn more about packages\r\n* [designer](https://github.com/Artezio/SURVEYBUILDER/tree/master/packages/designer/README.md \"@artezio/designer package\")\r\n* [player](https://github.com/Artezio/SURVEYBUILDER/tree/master/packages/player/README.md \"@artezio/player package\")\r\n* [models](https://github.com/Artezio/SURVEYBUILDER/tree/master/packages/models/README.md \"@artezio/models package\")\r\n* [fhir-converter](https://github.com/Artezio/SURVEYBUILDER/tree/master/packages/fhir-converter/README.md \"@artezio/fhir-converter package\")\r\n* [observable](https://github.com/Artezio/SURVEYBUILDER/tree/master/packages/observable/README.md \"@artezio/observable package\")\r\n* [observable-react](https://github.com/Artezio/SURVEYBUILDER/tree/master/packages/observable-react/README.md)\r\n\r\n\r\n&nbsp;\r\n# What does it look like\r\nWe created demo app to show you how our components can be used.\r\n* ## Demo\r\n    https://surveybuilder.now.sh/\r\n\r\n* ## Demo with code in sandbox\r\n    https://codesandbox.io/s/github/Artezio/SURVEYBUILDER/tree/master/demo-app?fontsize=14&hidenavigation=1&theme=dark\r\n\r\n* ## Launch on your computer\r\n    First clone the repository. Then you are to download all dependencies, to do it run following command in the root dir(surveybuilder/): \r\n\r\n    > $ yarn\r\n\r\n    To find out how to run it follow the link [README.md](https://github.com/Artezio/SURVEYBUILDER/tree/master/demo-app/README.md).\r\n\r\n\r\n# Applying custom converter\r\n\r\nYour custom converter must have 2 objects: questionnaire converter and questionnaire response converter. For example lets consider how they are used with fhir-converter:\r\n\r\n```javascript\r\nimport { questionnaireConverter } from \"@artezio/fhir-converter\";\r\n\r\nconst questionnaireModel = {\r\n    \"id\": '1',\r\n    \"title\": 'Questionnaire',\r\n    \"items\": [\r\n        {\r\n            \"id\": 'item_1',\r\n            \"type\": 'CHOICE'\r\n        }\r\n    ]\r\n};\r\nconst questionnaireFhirR4Model = questionnaireConverter.fromModel(questionnaireModel);\r\n```\r\n\r\n```javascript\r\nimport { questionnaireResponseConverter } from \"@artezio/fhir-converter\";\r\n\r\nconst responseFhirR4Model = {\r\n    \"resourceType\": \"QuestionnaireResponse\",\r\n    \"id\": \"3141\",\r\n    \"item\": [\r\n        {\r\n        \"linkId\": \"1\"\r\n        }\r\n    ]\r\n};\r\nconst responseModel = questionnaireResponseConverter.toModel(responseFhirR4Model);\r\n```\r\n\r\nEach converter must have 2 functions:\r\n\r\n| Name | argument | Description | \r\n| :---- | :-------- | :----- |\r\n| toModel | customModel | This function must receive custom mode and return model in format described below |\r\n| fromModel | model | This function must receive model in format described below and return custom model |\r\n\r\nModels interfaces are described in [models package](https://github.com/Artezio/SURVEYBUILDER/tree/master/packages/models/README.md \"@artezio/models package\") in \"Detailed description for models\" section.","readmeFilename":"README.md","homepage":"https://github.com/Artezio/SURVEYBUILDER#readme","repository":{"type":"git","url":"git+https://github.com/Artezio/SURVEYBUILDER.git"},"bugs":{"url":"https://github.com/Artezio/SURVEYBUILDER/issues"}}