This project follows Semantic Versioning.
- Fixed a bug that code.system was not set correctly when exporting data as DiagnosticReport.
- Support for rendering-xhtml on item.prefix
- Added tests for FHIRPath expressions to work with "coding" items in R5.
- Matrix layout radio group tab issue.
- Upgraded to nodejs version 22.
- Updated checkForInvalidHtml to allow more tags/attributes.
- Fixed a bug that help text and copyright text could be out of position if they are too long.
- Fixed a bug that the QuestionnaireResponse data could be modified when passed in to the mergeFHIRDataIntoLForms function.
- Support for rendering-xhtml on answerOption.
- Errors with attempting to access undefined environment variables when evaluating FHIRPath expressions where the variables are evaluated asynchronously.
- Added support of disabledDisplay in R5 Questionnaire.
- Added a function, 'getSupportedItemControl', to return an object containing a list of supported item controls.
- Fixed a bug that loaded data on repeating, readonly items could be deleted.
- Support for asynchronous FHIRPath expressions.
- Support for rendering-xhtml on item.text.
- Added new template option allowHTML. allowHTMLInInstructions is deprecated.
- Copy questionnaire-ordinalValue (STU3), ordinalValue (R4) and itemWeight (R5) extensions to questionnaire response.
- Allow ValueSets to load without a FHIR Context if a terminology server is on the form.
- Set 500ms delay for SNOMED requests on autocomplete Search instance.
- support for maxdecimalplaces extension.
- addFormToPage() can optionally take a questionnaire response in options to reduce number of lforms API calls.
- Error message for missing enableWhen.question.
- Removed accidental creation of global variable "self", which caused Google Analytics to throw exceptions when a link was clicked.
- Preserve id field in questionnaire items.
- CSS tweaks in attachment fields to align with other fields.
- Support for the FHIR observation-extract-category extension which sets Observation.category when an Observation is extracted from the Questionnaire.
- Updated fhirpath.js to version 3.13.2 to get resource node data types using
the
fhirpath.types(nodes)
function.
- Remove "Add another" on buttons.
- Fixed a bug that repeating items that have answer list and have child items are not rendered correctly.
- Fetching of ValueSets needs to specify JSON.
- Fixed a bug to catch and throw an error when an enableWhen field in Questionnaire points to an invalid linkId.
- Fixed a position issue of the validation messages.
- Guard against loading wc-lhc-form webcomponent more than once.
- Removed data types 'CNE' and 'CWE' from the lforms internal data structure, and replaced them with type 'CODING' and an 'answerConstraint' attribute. 'CNE' and 'CWE' data types are still supported in legacy data files.
- Added the support of 'answerContraint' in R5. Only 'optionsOnly' and 'optionsOrString are supported. 'OptionsOrType' is not supported yet.
- Added the support of item.type changes R5. Added 'coding' and removed 'choice' and 'open-choice'.
- Fixed a bug in "npm run start-public"
- Upgraded angular to v17
- Upgraded cypress to v13
- Added the support for detecting invalid html tags and attributes in the html version of the help text.
- Updated autocomplete-lhc version to include loading indicator.
- autocomplete-lhc version.
- answerValueSet items in repeated groups was not rendered properly.
- Fixed a bug that enableWhen breaks when there is a loop of references to the items in enableWhen.question.
- QuestionnaireResponse no longer contains answers to child questions of unanswered parent questions. See https://jira.hl7.org/browse/FHIR-32665. Although the change of the cardinality of item.answer.value to 1..1 was an R5 change, it was the intention all along, so we have made the change for R4 & STU3 as well. Although we regard this as a fix, it could be a breaking change for some, which is the reason for the major version increment.
- Added the support for using image data in the 'contained' when a local ID is used in the 'src' attribute of a 'img' in the value of the 'rendering-xhtml' extension for help text.
- Added support for regex strings without '/' in validations
- Changed the option, showQuestionCode, to control the display of all of the codes of an item, not just the first code.
- Updated styles to display newlines and spaces in coding instructions.
- Support for the exporting of QuestionnnaireResponse.questionnaire.
- Fixed a bug that copyright is not displayed when there is no code.
- Added support for FHIR verison R4B.
- The FHIR extension for setting the preferred terminology server now works on the root of the Questionnaire as well as on items.
- Fiex a bug that number 0 in QuestionnaireResponse is not imported when the QuestionnaireResponse is loaded into the corresponding Questionnaire.
- Fixed a bug in LForms.Util.guessFHIRVersion() to detect STU3 when initial fields are specified.
- Fixed a bug that when an item has the sdc-questionnaire-unitOpen extension set to 'optionsOrString', a user typed unit would be cleared in the UI even it is still available in the QuestionnaireResonse.
- jQuery is no longer leaked to the containing app. This might be a breaking change for users who were relying on jQuery being defined as a result of loading the lforms package. Apps can either load jQuery themselves or use LForms.jQuery (which is where the lforms jQuery moved to) but note that we would like to remove the jQuery dependency in the future if possible. If we do that, it will be another major-version increment to signal the breaking change.
- The sourcemap file for lhc-forms.js now works.
- The URI for the "preferred terminology server" FHIR extension, which was previously updated too soon to a new URI that has not gotten into the published documentation yet. Either will still work on import; this change affects what is exported.
- Updated autocomplete-lhc to 18.6.1, to get a fix for a bug with the list positioning which could happen if lforms was inside a dialog box.
- Support for %qitem in FHIRPath expressions.
- Fixed a bug that copyright is not handled in import and export functions.
- Fixed a bug that the 'system' value is missing in QuestionnaireResponse when an item has an answerValueSet and it also has a questionnaire-item-control extension that is 'autocomplete' (search field).
- Fixed a bug that FHIRPath expressions could run on a QuestionnaireResponse where the data are invalid. It now throws an error.
- Fixed a bug that when a QuestionnaireResponse with saved values from an answerValueSet is loaded back into the Questionnaire, the saved values are not restored.
- Fixed a bug in updating meta.profile in exported questionnaire based on it version such as STU3, R4 etc.
- Fixed a bug that initial values were not displayed in the matrix layout ("Vertical Answer Table"/"table" in itemControl, http://hl7.org/fhir/questionnaire-item-control).
- Fixed a 508 compliance issue related to the matrix layout.
- Fixed a bug that changes from FHIRPath expressions did not update treeline status.
- Changed the design of the boolean component. It's now rendered as 3 radio buttons to support the concept of "no answer".
- Added the support of enableWhen on string, integer, date and time typed items that have an answer list.
- Added a template option to control whether to display scores along with texts for answers that have scores.
- FHIR Expressions were being run on form load once per item with an autocompletion list. It now will only run an extra time (on form load) once for each item of type quantity which has a unit list, which is still more often that should be needed, but this fix by itself should help speed up the loading of many forms.
- Fixed a bug that hidden items in a questionnaire are displayed when a questionnaire response is loaded/merged into the questionnaire.
- Added support for answerExpression on items whose types are string, integer, date and time.
- Fixed a configuration issue in webpack dev server that FHIR js files failed to load through a proxy in dev mode.
- Updated angular from v12 to v14
- Removed the support for IE 11.
- Only ES2017 files (no ES5 files) are in the build files. The concatnated js file name is now lhc-forms.js, not lhc-forms.es5.js or lhc-forms.es2015.js
- Made item.dataType in lforms internal format required (a breaking change).
- Made initial[x] values and the initialSelected on answerOption both work when the item.type is choice or open-choice.
- Added support for string, date, time and integer values in answerOption (R4) and option (STU3), including the support for related extensions (optionPrefix, ordinalValue, and itemControl) and the initial[x] values.
- Fixed a bug in a custom cypress command.
- Fixed a bug in importing a DiagnosticReport resource.
- When running e2e tests, webpack-dev-server now serves the files so that changes to source files are more quickly recompiled and updated for the test runner.
- Fixed a bug in the construction of the URL for a FHIR ValueSet $expand operation, though there was already a work-around in place, so the only result was a single failed network call logged to the console (which then can cause a problem for Cypress tests).
- Cypress has been updated to version 10.
- Fixed a bug that enableWhen does not work on the values calculated from FHIRPath expressions.
- Added support the currenly published URI for the preferred terminology server extension, though that URI will be changing (https://jira.hl7.org/browse/FHIR-23977).
- Added support the entryFormat extension
- Removed item._modifiedAnswers and use item.answers directly.
- Removed fast-deep-equal package that is causing failed e2e tests in cypress.
- Fixed a bug that a user typed value on open-choice item is not set as a string value.
- Moved the URI for the custom FHIR extension lforms generates to store the "externallyDefined" setting out of the HL7 namespace.
- Minor refactoring of the SDC import code, which should not impact users, except that for STU3 item.definition will no longer be lost if you convert to LForms format and and back to FHIR. (The R4 import did not have that issue.)
- Updated fhirpath.js to 3.0.0 to get a fix for #102
- Removed a feature in which the autocompletion list fields would default to the answer list value if there were just one answer in the list.
- Changed the implementation on how the data changes in questionnaire data are handled.
- Added the active row indicator for the radio buttons and checkboxes.
- A very minor fix to the formatting of the form title, probably not visible to a user, but which was causing a test to fail in another package.
- FHIR Quantities with a comparator can no longer be stored or loaded into a Questionnaire. This change is in line with https://jira.hl7.org/browse/FHIR-37468.
- Fixes for handling Quantities in expressions.
- Added a button on the test page (test/pages/lforms_testpage.html) to batch convert lforms to FHIR questionnaires or vice versa, where both input and output are zip files
- Fixed a bug that FHIRPath expressions are not calculated on newly added repeating items.
- Fixed a bug that enableWhen is not working on prepopulated answers.
- The beginnings of support to show error messages for individual fields.
- Added support for answerOption.initialSelected in R4 Questionnaire
- Updated angular to v12 and ng-zorro-antd to v12.
- Fixed a bug that the radio button of "Other" of the CWE typed items lost its checked state when users typed in the input field.
- Off-list string values from an open-choice field are now usable in an expression for another open-choice field.
- Support for multiple values coming from intialExpression or calculateExpresion on fields that are of type string or coding.
- Fixed a bug that the initial value of boolean type was not imported correctly when it was false.
- Adjusted the styles of readonly items
- Fixed a bug that observations were extracted from items that were either hidden or had no values.
- Fixed a bug that boolean value false was not extracted correctly.
- Fixed a performance issue in the initial loading of a Questionnaire when it contains a lot of choice and/or open-choice items.
- Fixed a bug that the values of date or dateTime items in a repeating group are not checked when adding a new repeating group.
- Fixed a style issue for the first item in a group.
- Added options to hide tree line styles, indentation or repetition numbers.
- Fixed answerExpression and calculatedExpression processing so that for list fields, both answers and answer lists can be set by an expression that depends on the answers of another field.
Official release of the new Web Component version of lforms. See a list of changed features in changed-features.md.
- Fixed a minor style issue
- Code refactoring and clean up.
- Made most commands in package.json work on Windows.
- Fixed a bug that the user saved data was overwritten by the values from initialExpression.
- Added back the support of a CSS selector as the element parameter for LForms.Util functions such as getFormData, getUserData and getFormFHIRData.
- Removed the redundant resourceType parameter in the LForms.Util.mergeFHIRDataIntoLForms function.
- Fixed a bug that saved user data in a form are lost when answer lists are updated by FHIRPath expression.
- Support for the newer launchContext "name" data type, valueCoding. For backward compatibility, valueId is still supported. (https://build.fhir.org/ig/HL7/sdc/StructureDefinition-sdc-questionnaire-launchContext.html)
- Support for arbitrary launchContext names and resource types. A second parameter has been added to LForms.Util.setFHIRContext which is a map between launchContext variable names and FHIR resource instances (as objects). This allows an application that is familiar with a partictular Questionnaire to pass in the needed resources.
- Fixed a a bug that repeating rows in horizontal table (gtable) are not added at the end of the table.
- Added the support of the questionnaire-hidden extension on the horizontal tables (gtable) and the matrix (table).
- calculatedExpression no longer forces fields to be read-only.
- Added an onError event, that returns an error when FHIR resources fail to load, or when there is an exception during the initialization.
- Added cypress for e2e tests.
- Removed locale files from moment.js
- Code refactoring on the initial release.
- Fixed a style issue on items with a single unit.
- Included the initial release of the Web Component version of the LHC-Forms widget in the "next" directory. This will be reorganized out of the "next" directory prior to the non-beta release.
- If a form contained an attachment type question, hitting enter in another field opened up the attachment options.
- Support for the FHIR enableWhenExpression extension.
- Fixed a typo in the error message introduced in 29.2.2.
- The LForms.Util.addFormToPage function will now display an error message in the cases where it does not render the form. The previous behavior was that the form area was simply blank, so this is judged a "fix" over that.
- Updated the URI for the FHIR "initialExpression" extension, but the old URI is still supported and will be updated if found in a Questionnaire. As a side-effect, this means that a re-export back to FHIR will have the updated initialExpression URI.
- Support for attachments, both in FHIR (type="attachment") and in our internal format (dataType="attachment").
- FHIR answerExpressions that return arrays of strings now work for setting a list (though the type needs to be "choice", not "string", which is something that will be fixed later).
- Updated fhirpath.js for improved handling of choice types.
- Removed direct refereces to angular in FHIR lib files.
- Support for named FHIR expressions. Any supported FHIR expression can now have a name, which acts like a variable for other expressions.
- Fixed a bug where hidden items were triggering validation to fail.
- Fixed a bug that item.repeats is not converted correctly in some cases.
- Fixed a bug that minValue extention is not imported correctly when the value is 0
- Breaking change to FHIR support. The launchContext URI has changed to http://hl7.org/fhir/uv/sdc/StructureDefinition/sdc-questionnaire-launchContext
- Updated jQuery to 3.6.0.
- FHIR calculatedExpressions on editable fields now stop calculating if the user edits them.
- A FHIR Observation-based prepoluation issue: the Observations were not being filtered by status.
- A problem in FHIR expression processing which caused issues if more than one form was added to the page.
- Sorting was corrected for FHIR Observation-based prepoluation. It now takes the latest by "date", not "_lastUpdated".
- Processing of FHIR expressions for fields with multi-select lists, and for fields with radio buttons.
- Replaced local js-class.js with npm js-class package.
- Changed requiring a json package using .json extension.
- Added missing polyfills for IE 11.
- Fixed error handling logic for FHIR expressions.
- Support for x-fhir-query variables, and with embedded FHIRPath in the URLs as described at http://build.fhir.org/ig/HL7/sdc/expressions.html#x-fhir-query-enhancements. The variable extension is documented at http://hl7.org/fhir/R4/extension-variable.html
- Breaking change to FHIR support. Changed the extract behavior to use the Observation Extract Extension http://build.fhir.org/ig/HL7/sdc/StructureDefinition-sdc-questionnaire-observationExtract.html.
- Fixed a bug that nummeric value of 0 was not exported in QuestionnaireResponse
- Support for the FHIR questionnaire choice orientation extension.
- Breaking change to FHIR support. LForms.Util.setFHIRContext now takes an instance of 'client-js', a.k.a. npm package fhirclient, version 2. (See http://docs.smarthealthit.org/client-js).
- Multiple code support for observationLinkPeriod prepopulation.
- Fixed a bug in STU3 Questionnaire import that 'options' is not handled correctly
- Added two functions: LForms.Util.isValid, which checks if the form fields are valid and LForms.Util.getErrors to get a list of errors preventing the form from being valid.
- Added a function, LForms.Util.getAnswersResourceStatus, which checks the status of the loading of answer lists. (This only applies to forms defined as a FHIR Questionnaire.)
- Support for using a FHIR Questionnaire as a form definition in addFormToPage.
- Fixed the extensions URI for answer scores
- Support for the FHIR answerExpression extension (with FHIRPath expressions only).
- Changed the default template options to hide the form controls and header.
- Remove duplicate entry in form level fields.
- Display a marker
*
on labels for required items. - Add
aria-required
on required inputs.
- a bug in FHIR Observation-based extraction that kept it from working for nested items.
- a bug in detection of STU3 Questionnaires
- Treat skip logic condition source as not existing when it is disabled.
- Fix a bug with skip logic notEqual operator.
- Update angularjs to 1.8.0
- Added a support for providing ValueSets via a FHIR resource package at the initialization.
- Updated the URI for the FHIR calculatedExpression extension. (If you are not using FHIR, this change will not affect you.) The lforms-updater package can be used to update FHIR Questionnaires generated for previous versions of LForms.
- Fixed a bug that answers for questions under a question that has no answers were not exported.
- Replaced "Number.parseFloat" with "parseFloat" for IE11
- Fixed contained valueset reference for R4 (from using url to using #vs-id), but continue to support url-based reference only for the purpose of backward-compatibility with previous LForms versions.
- Updated the fhirpath dependency to 2.1.3
- Updated the ucum-lhc dependency to 4.1.3
- Textarea placeholder binding causes exception in IE11
- Separated the skip logic 'disabled' status from item's 'hidden' status.
- Correctly handled the import/export of the questionnaire-hidden extension.
- Fixed a bug that reloading existing LForms form definition object with instances of repeating items might be very slow.
- Since 19.0.0, lforms only supports units for types INT, REAL, and QTY. This fixes a place in which units should have been ignored but were not and caused exceptions to be raised.
- 'linkId' is now required on each item. 'questionCode' is no longer required. The original 'questionCode', 'questionCodeSystem' are kept but might be refactored into 'codeList' in the future versions.
- the name 'sourceItemCode' in dataControl.source becomes 'sourceLinkId' and its value becomes the source item's linkId value
- the value of 'source' in skipLogic.conditions becomes the source item's linkId value.
- Remove _idPath from item object.
- 'linkId' is used in 'skipLogic', 'dataControl' and 'calculationMethod' to identify source items across the form. The source items no longer have to be ancestors or siblings of the target item.
- Fixed missing extensions when outputting lforms format.
- The version tag on generated FHIR resources is now set on the "code" property instead of the "display" property, as some FHIR servers drop tags that do not contain a code.
- Removed a FHIR extension for indicating that a question can have more than one answer. We now rely on FHIR Questionnaire.item.repeats, plus the item type, to determine whether an item repeats or the item's answer repeats in our rendering of the form.
- The URI for the FHIR "observationLinkPeriod" extension has been updated to the current URI, http://hl7.org/fhir/uv/sdc/StructureDefinition/sdc-questionnaire-observationLinkPeriod. FHIR Questionnaires coded with the old URI will need to be updated to continue to support Observation-based prepoluation or extraction. We are releasing a separate package, lforms-updater which can be used to automate updating LForms form definitions and FHIR Questionnaires to the current version.
- Changed answer's 'codeSystem' to be 'system'. Legacy form data with 'codeSystem' are converted into 'system' when a form a loaded.
- LForms form definitions now contain an lformsVersion attribute indicating the LForms version from which they were generated.
- Generated/exported FHIR resources now contain a tag (meta.tag) that starts with 'lformsVersion: ' followed by the LForms version used to export them.
- Added support for a custom extension in FHIR Questionnaire to contain the dataControl data in LHC-Forms.
- Fixed a bug that valueBoolean in Questionnaire was not converted to LForms BL value.
- Bumped up angularjs version to 1.7.x. This could potentially break applications still running prior angularjs versions, hence bumped up the major version.
- Fixed a bug in click event in CNE/CWE control. Changed ng-click event to ng-change event on radio/checkbox inputs when ngModel is used.
- Fix date time parsing test.
- Added support for 'notEqual' in skip logic, to support '!=' in the 'enableWhen' of FHIR Questionnaire.
- Updated the fhirpath dependency to 1.0.1 (which was a breaking fhirpath change, but should not affect LForms). This adds some FHIR model information to the evalution of FHIRPath expressions, paritcularly knowledge of choice-types, so that expressions like "item.answer.value" can work.
- Implemented calculated value support for additional FHIR types, particularly Coding, so that list fields can be set via a FHIRPath expression.
- Export calculatedExpression, variable and other FHIR extensions in lforms format.
- Exporting to FHIR no longer include the minOccurs extension if the value is 1 and "required" is true.
- defaultAnswer was not handled correctly for DT and DTM.
- Added support for item.answer.item when importing from/exporting to FHIR.
- Added a vertical scrollbar for long text of coding instructions and copyright notice in popover windows.
- Added "exists" support to skip logic
- The trigger.code and triger.value.code were "hidden" features, but the issue of code system wasn't taken into consideration and therefore was broken. This has been reimplemented so that when the source question is of type CNE or CWE, the trigger.value will be a hash with any or all of these three fields: code, system, and text, and the trigger matching will be based on these fields. Please see the updated lforms definition for more details.
- Fixed a bug that autocompleter options are not set for items in templateOptions.
- Default values are no longer set when loading QuestionnaireResponse, DiagnosticReport and saved form data.
- Data type QTY is now documented as a supported data type, and is now validated like a REAL. (Previously, there was no validation for type QTY).
- Removed the "type" field from the form definition (though it should not hurt to include it).
- The codeSystem field is no longer defaulted to LOINC. The LOINC default was causing problems for FHIR Questionnaires which did not have a code system specified.
- Data types INT and REAL are now only allowed to have one unit defined in field "units", for alignment with FHIR. For more than one unit, use type QTY (quantity). For backward compatibility with existing form definitions, INT or REAL fields with more than one unit will be changed to QTY, and a warning will be output.
- The data type is no longer changed to "ST" if a question has a calculationMethod.
- The FHIRPath expressions are now cached after being parsed, which greatly speeds up the processing.
- Corrected FHIR export and import of integer, decimal, and quantity types, and the unit extensions used.
- Corrected the default for handling multiple skip logic conditions to be "ANY" instead of "ALL" (i.e. now "ANY" of the conditions being true will make the field visible). The "ANY" default was what should have been the case per the documentation in form_definition.md, and also matches the equivalent default in FHIR.
- Fixed the setting of the FHIR context for evaluating FHIR variables defined on Questionnaire.
- Units column is no longer shown if there is no units values in the form data.
- Display of item with TITLE data type is fixed without setting header flag.
- Support for the FHIR "rendering-style" (CSS) extension on Questionnaire.title, item.text, and item.prefix. (Support on answer list text is still TBD).
- Updated dependencies to get patches for a vulnerability.
- Fixed a bug that item values that have extra user data are not found in the answer list so that they are not displayed.
- Increased the maximum supported nesting level of form sections.
- Changed form title to use title field, if present, otherwise use name field.
- Fixed missing form level fields related to FHIR Questionnaire. All form level fields are preserved.
- The sequence numbers in front of answers won't be displayed if one of the answers has a numeric value, to avoid confusion.
- Added support for 'prefix' in FHIR Questionnaire and in LForms.
- Fixed a bug that on CWE items, user typed answers that are not in the answer list are not displayed in the "OTHER" fields, when answer list is displayed as radio buttons or checkboxes.
- Fixed a bug that code system of an answer is not imported for QuestionnaireResponse and DiagnosticReport.
- User typed, not-on-list value for CWE item is now stored as a string.
- Fixed a bug in conversion of restrictions to corresponding FHIR extensions.
- Support for prefetched lists (FHIR item control type = 'dropdown') whose source comes from external FHIR ValueSets.
- Fixed a bug which was overwriting linkid with codepath in Questionnaire's item.enableWhen.question.
- Fixed a bug that multiple repeating items are added when the "add" button is clicked, if the form with user data that contains multiple repeating items is loaded.
- Fixed bug in LForms.Util.dateToDTMString()
- Support for FHIR Questionnaire items of itemControl type 'autocomplete'.
- Support for the terminology-server extension that specifies the FHIR server from which ValueSet expansions should be done. (Currently, this assumes the terminology server does not require a login.)
- Modified a test Questionnaire, test/data/R4/ussg-fhp.json, to contain examples of this new support.
- An issue that prevented observationLinkPeriod from working on fields that were not top-level.
- Fixed a bug in parsing ISO date and time string.
- Fixed a bug that help instructions are not exported correctly in R4 Questionnaire.
- Removed unnecessary default code system value
- Removed generated identifiers from the exported FHIR QuestionnaireResponse resources. The generated identifiers as they are now are not unique and do not serve specific purposes. The identifiers from previously imported QuestionnaireResponse resources will be preserved. This is not considered a breaking change because FHIR spec governs the protocol here and the identifier field is optional.
- Added support for multiple code system in answers.
- Fixed missing form level properties in conversion of FHIR questionnaire to lforms.
- Fixed missing item code list in conversion of FHIR questionnaire to lforms.
- Fixed a bug in FHIR/SDC Questionnaire version detection.
- DTM support and datetime picker
- This contains a breaking change that only affects forms imported from FHIR Questionnaires. The loading of external FHIR resources no longer happens when an LFormsData object is constructed. Instead, after constructing LFormsData, one must call (on the instance) loadFHIRResources(), which will return a promise that resolves when the resources are loaded. Similarly, if using LForms.Util.addFormToPage(), that will also return a promise that resolves when external FHIR resources had been loaded. (See the documentation.)
- Fixed extension URLs for SDC Questionnaire
- Each value of the multiple selected values in CNE/CWE typed item should be a separate Observation resource when LForms data is converted to corresponding FHIR resources.
- Fixed a bug that user selected units in saved data were not loaded correctly into the LForms.
- Observation-based prepoluation of list fields now works.
- Used a correct extension for coding instructions in FHIR Questionnaire
- Added support for coding instructions format in FHIR Questionnaire
- Fix an error when creating LFormsData object with empty items.
- Empty Observation records were being saved during data extraction to an STU3 FHIR server (for fields without values).
- Corrected the setting of derivedFrom in extracted obsevations in R4.
- The %questionnaire variable is now available for FHIRPath expressions.
- Fixed URL in R4 for ordinalValue (score)
- Support for data extraction via observationLinkPeriod. If you pass in an "extract" option (set to true) to LForms.Util.getFormFHIRData when "resourceType" is set to QuestionnaireResponse, it will return an array of the QuestionnaireResponse resource and any extracted Observation resources.
- Added a check to make sure linked observations do not have focus set to true.
- Added support for FHIR Questionnaire form level fields.
- Patched date parsing errors encountered in form builder environment.
- Changed to allow 'label' in answers to be null.
- Corrected the FHIR itemControl codes. We still accept the incorrect codes (as well as the correct ones) for import, but the export is now correct.
- Changed view's screen size breakpoints.
- Changed import function to work around 'linkId' in FHIR QuestionnaireResponse resource.
- Added validation for signed values of INT and REAL data types.
- Fixed bug in processing regexp value of 'pattern' restriction.
- Problems with mapping from the LForms structure to QuestionnaireResponse when running FHIRPath expressions. Added some tests.
- Enabled generation of source maps for the FHIR supported files.
- Improved error handling and reporting for LForms.util.getFHIRServerReleaseID.
- Corrected a problem with detecting which version of FHIR was being used by a FHIR server.
- Excluded unnecessary files from the npm package.
- The build process has been changed to use npm packages, in preparation for registering this package on npm. (At this point, this package should be ready for being registered, which we will do soon.) It is not expected that this is a breaking change.
- Support for the questionnaire-observationLinkPeriod extenstion for pre-population. (Extraction is not yet supported.)
- This is a fix for calculated expressions in the Safari browser. (Chrome, Edge, and Firefox were working).
- Updated the jquery-ui package to 1.12.1 from 1.11.4, which is a breaking change for that package. Since jQuery is a global variable, this is potentially a breaking change for users of the lforms package. The lforms APIs themselves are unchanged.
- Added code and system attributes to unit, to align with FHIR specs.
- Fix typo in url for FHIR unit option.
- Fixed unit conversions to store the unit lists in unitOption extensions and change the data type to quantity. Used initial.valueQuantity.unit to store the lforms default value. If no default is found, the first unit in the list is set to default.
- Refactored the code to reduce some duplication in STU3 and R4.
- The BMI "calculationMethod" can now handle "[in_i]" as a unit.
- Standard Questionnaire exports for R4 now contain '4.0' (instead of '3.5') as the FHIR version.
- Standard QuestionnaireResponse exports now include meta.profile.
- Exceptions raised for problems with detecting the version of a FHIR resource are now Error objects instead of strings.
- Added an option to specify the subject for an exported FHIR resource.
- Removed some outdated documentation from form_definitions.md.
- Reorganized some code (but not in a way the affects public APIs).
- The "themes" css file is now in a separate file from the lforms.min.css file in the distribution, to avoid making that larger than necessary. It has also been removed from bower.json, so that themes.css will no longer be automatically pulled in with things like wiredep. (This is possibly a breaking change for someone, and is the reason for the major-version increase.)
- The autocomplete-lhc package is now being pull in via npm.
- Now handles FHIR QuestionnaireResponse items that do not have answers.
- Corrected version number in bower.json.
- Support for the FHIR extension "variable" has been added, but as with the "questionnaire-initialExpression" and "questionnaire-calculatedExpression" support is currently limited to FHIRPath-based expresions.
- Fixed errors in parsing argonaut questionnaire extensions with support for item.option.extension-score.
- FHIR Questionnaire contained ValueSet support.
- Added support for the questionnaire-hidden extension http://hl7.org/fhir/StructureDefinition/questionnaire-hidden A good test example is: https://argonautproject.github.io/questionnaire/Questionnaire-questionnaire-example-asq3.html
- FHIR value quantity import/export
- Misc fixes.
- FHIRPath intialization has been corrected, so that the context passed in is now the item on which the expression is attached, and %resource is set to the QustionnaireResponse object.
- Added support for enableWhen and initial(x) in R4.
- Support the FHIR extension "questionnaire-initialExpression".
- A new function LForms.Util.guessFHIRVersion(fhirResource) which looks at the structure of the resource to guess the version of FHIR being used.
- Made a previously internal function, LForms.Util.detectFHIRVersion(fhirResource), public. This function looks at the meta.profile field to determine the FHIR version of the resource.
- Made a previously internal function, LForms.Util.validateFHIRVersion(version), public. This function checks to see if the given version is supported by LForms and if the needed auxiliarly lformsFHIR.min.js file has been loaded.
- In the pre-built files placed on https://clinicaltables.nlm.nih.gov/lforms-versions/, the FHIR auxiliary files were missing from 13.4.0 and possibly earlier.
- Added support for the FHIR questionnaire-launchContext extension in R4.
- Added support for answerValueSet and answerOption in R4.
- Separated test suites and fixtures for R4 and STU3 versions.
- Removed hard coding of loinc code system in answerOption/option valueCoding object.
- LForms.Util.addFormToPage can now accept a form defintion object as its first argument rather than just a variable name that holds that object.
- There were several problems with the FHIR APIs in LForms.Util. Tests were testing lower-level methods rather than the public APIs, which is how that escaped notice.
- The start of support for FHIR R4, in the form of copy of STU3 (so no real R4 support yet, except for questionnaire-calculatedExpression support which we added in 12.12.0).
- An issue with the "grunt test" task introduced in 13.0.0. (The build was not run prior to the tests.)
- Reorganized the FHIR functions to facilitate support for multiple versions of FHIR. (This should not be a breaking change if you are not using FHIR).
- Fixed data type for items with units.
- Added support for TX data type and "text" item type in Questionnaire.
- Updated FHIRPath to 0.8.0.
- Fixed a bug that answers of repeating items in QuestionnaireResponse are not handled correctly.
- Support for the FHIR Questionnaire resource extension questionnaire-calculatedExpression. This requires the fhirpath.js library, which is now packaged with LForms, but as a separate file, app/scripts/fhirpath/fhirpath.min.js.
- Added a 'linkId' field in items.
- The BL (boolean) data type now works correctly, and is displayed as a checkbox.
- The background color for textarea based fields.
- The protractor tests stopped running in Firefox, and a fix is not yet available, so the tests were revised to run in Chrome.
- Upgraded autocomplete-lhc package to 16.0.0.
- Fixed problem with validity of FHIR output by stripping nulls from the resource.
- Treated data type TX same as ST.
- Used TEXTAREA for items with ST data type instead of INPUT.
- Accessibility issue with the announcing of validation errors by a screen reader.
- Accessibility issue with the announcing of date picker buttons by a screen reader.
- Several accessibility issues were fixed, including the reading of inline help and questions and answers for radio buttons and checkboxes.
- Added an option to export LForms data in a standard FHIR QuestionnaireResponse resource without any extensions.
- Changed related functions definitions in LForms.Util
- Modified the TOTALSCORE function to support multiple TOTALSCORE rules on one form.
- Added an option to export LForms data in a standard FHIR Questionnaire resource without any extensions.
- Added an option to export LForms data in a FHIR Bundle with a DiagnosticReport resource and associated Observation resources.
- Added supporting functions for FHIR Bundle.
- Added new functions under LForms.Util for exporting/importing to/from FHIR resources.
- Added documentations for LForms.Util functions in form_definition.md.
- Added an FHIR Questionnaire extension for externallyDefined.
- Changed the linkId of FHIR Questionnaire item to be the _codePath of LForms' item, and updated related conversion functions between FHIR data and LForms data.
- Added an FHIR extension to support repeating answers in FHIR Questionnaire.
- Added support for multiple answers for the initial values of an FHIR Questionnaire.
- Fixed z-index of icon in date input field to go behind any calendar widget coming on the top.
- Added conversion of externallyDefined field in LForms to store it in FHIR questionnaire resource.
- Changed our internal development environment shell from tcsh to bash.
- Fixed an accessibility issue with plain-text popups. Popups with HTML (e.g. HTML-encoded help) are still not completely read.
- Fixed a bug in FHIR QuestionnaireResponse convert function to handle cases where items with units could have data types as "ST"
- Added support to convert a FHIR Questionnaire resource to LForms format.
- Moved themeList.js, which is just for demos, out of the test directory and into app/scripts, so that other applications (e.g. our demo site) can make use of it.
- Fixed the calendar next/previous buttons under themes for IE.
- Added cyan and teal color themes.
- Added color theme coffee.
- The autofill for list fields with only a single list item had been accidentally disabled by previous changes.
- Added support back for validations of items in horizontal tables.
- Added support back for displayControl.colCSS of items in formHeaderItems.
- CSS styles in displayControl.css can now be applied to the item.
- The HL7 v2 output has changed. In particular, for questions with repeating answers, each answer is now in a separate OBX record.
- Added a themes capability, with two new themes.
- List fields whose data comes from an external source (via the URL in the "externallyDefined" property) have a revised format for the content of the AngularJS data model. This will only affect you if you are accessing the data model directly. The change is that any extra data properties for a selected item (other than the "text" and "code" properties) are now placed inside value.data, instead of directly on the item value object.
- Added support for disabling CNE/CWE items (autocomplete input fields or radio buttons/checkboxes)
- Added support for displaying coding instructions and copyright info on the section headers of horizontal tables and matrix tables.
- Addressed some accessibility issues.
- Added checking for questions in form header when generating HL7 and FHIR data.
- Used autocomplete-lhc v13.0.0 and changed the way to handle modified display text for answers.
- Added support for non-clickable headers in lists (when the list items are defined in the form).
- Added supports for FHIR SDC Questionnaire and QuestionnaireResponse
- There was a problem with the handling of defaultAnswer for radio buttons and checkboxes.
- Support for default answers for questions via the defaultAnswer field in the form definition.
- Used a different library (element resize detector) for checking the container element's size, which can handle multiple rendered forms on a page.
- Added a viewMode option to the form and to the individual items to control the layout
- Fixed a bug in URL data type parsing.
- Added a resize event listener on the container element to make the form responsive in cases where container's size changes without a change in window size.
- Changed some background color on section headers and buttons
- Made the form responsive to the container's size, not the screen's size
- Default values are now handled for questions whose answers are presented as radio buttons.
- Also eliminated an unnecessary copy of answer data for the case when there is no label value for the answers.
- Corrected missing fonts in the pre-compiled version.
- Fixed display issues with the icon buttons.
- Fixed the styles for forms where a question contains questions of sections
- Redesigned the form template to make it responsive
- Changed OBX4 value calculation method in HL7 messages.
- Updated a test form, and added a test to make sure a problem with the autocompletion stays fixed.
- Changed the default style of TITLE row to be same as section headers.
- Updated the autocomplete-lhc package to version 10, in which URLs for search autcompleters now take a "maxList" parameter (in place of, but with opposite meaning to, the "autocomp" parameter). Forms with URLs for search lists might need to be updated, or more likely the servers handling the URLs will need to be changed to handle the new parameter, which is the reason for the major version increment on this package. The Clinical Table Search Service supports the new autocomplete-lhc version with the addition of newer API URLs (v3 and higher).
- Fixed a bug in getting form data without questions that have empty values.
- Changed a FHIR data processing function's name.
- Added preliminary support for generating FHIR DiagnosticReport data and merging it back into a form.
- Updated the design and docs of the data control function.
- Renamed the CSS class 'empty-question' to 'lf-empty-question' to avoid possible confusion.
- Added support for setting the code systems for the form and for questions.
- Added support for a new data type, NR (numeric range).
- Prevented HTML tags in listColHeaders from rendering, to reduce the risk of XSS attacks.
- Added an option to hide the Units column/field.
- A listColHeaders option for specifying column headers to appear over the lists for search fields (lists specified with "externallyDefined").
- Added an optional codingInstructionsFormat field on item level to specify the format of coding instructions for each individual item.
- Added a missing polyfill.js file that should have been in 7.1.1.
- Uncoded CWE values rendered as HL7 are now placed into OBX5.9.
- Adjusted formatting of HL7 output to allow the message lines to wrap after a repeat.
- The code system of an answer list can now be specified in "answerCodeSystem" on individual items in a form definition.
- User data validations based on dataType and restrictions
- Use a single namespace, LForms, for all LForms functions and objects.
- Another CSS fix for IE. This is a fix for the placeholder text for textareas, and should have been fixed as a part of the 6.1.1 changes, but was missed.
- Updated the autocomplete-lhc dependency (to 9.0.1) to get some fixes.
- Two CSS fixes for IE.
- Added a function to export user data in HL7 segments (in progress).
- Turned on "minification" of the distribution version of the JavaScript.
- Updated Protractor to work with new version of Firefox, and updated some tests to work with the new Protractor.
- A getFormData function to get complete form definition data, including user input data.
- Events are emitted when a repeating item or section is added or removed.
- The existing getFormData function is renamed to getUserData.
- A 'list' template.
- A 'matrix' layout for section items, in addition to 'horizontal' and 'vertical'.
- A attribute 'answerLayout' in the 'displayControl' field for items that have answers.
- A 'displayControl' field in 'templateOptions' at the form level.
- All existing template names are combined into a new 'table' template
- The existing 'layout' field is renamed as 'questionLayout' and moved into the 'displayControl' field.
- Field hints for search autocompleters were changed to read "Search for... " rather than "Select... " because for search autocompleters the user does not see a list until the first couple of characters are typed.
- WidgetUtil.preprocessRIData. This was an internal API, so it should not be a breaking change for anyone but ourselves.