## 10.0.0

---

- Upgrade to 24.1.x of @helsenorge packages

## 9.1.0

---

- Added support for internal linking based on sdf-hyperlink-target extension on all components
- Added DOMPurifier render with target="\_self"
- Added same-site url builder for links that open in the same window

## 9.0.1

---

- Fix handling of initial values for quantity fields.

## 9.0.0

---

- Upgrade to- 23.x.x version of @helsenorge packages
- Upgraded to use React 17.0.2
- Added @helsenorge/framework-utils as devDependency
- Added @helsenorge/date-time as peerDependency
- Added @helsenorge/autosuggest as peerDependency
- Added @helsenorge/file-upload as devDependency
- Added @helsenorge/form as devDependency
- Upgraded enzyme-adapter-react-16 to enzyme-adapter-react-17
- Upgraded designsystem-react to 1.0.0-formlayoutiphone.0
- Replaced ExpanderSection from Toolkit with Expander from designsystem
- Replaced icons from Toolkit with icons from designsystem
- Temporarily removed validation-spec.tsx. The behaviour tested for seems to work, but test won't run.

## 8.0.1

---

- Fixed a bug when duplicating an item for repeat, where the duplicated item sometimes would contain an empty answer block.

## 8.0.0

---

- Upgrade to 22.x.x version of @helsenorge packages
- Upgraded to use Node 16.13.2
- Added @helsenorge/designsystem-react as a peerDependency
- Added enzyme-adapter-react-16 as a devDependency
- Removed TS-Jest in favour of Babel for tests

## 7.10.8

---

- Removed InitialDate prop from DateRangePicker used in date-day-input.tsx

## 7.10.7

---

- Replaced Spinner component with Loader from designsystem-react in ReceiverComponent

## 7.10.6

---

- Fix publish fault

## 7.10.5

---

- Replaced Lightbox component with Modal from designsystem-react
- Replaced Spinner component with Loader from designsystem-react
- Replaced MessageBox component with NotaficationBox from designsystem-react
- Replaced button components from toolkit with Button from designsystem-react
- Upgrade package @helsenorge/core-build to 21.3.1
- Upgrade package @helsenorge/core-utils to 21.3.0
- Upgrade package @helsenorge/toolkit to 21.4.1

  7.10.4

---

- Fix bug where value in receiver component was not cleared when unselecting a leaf node.

  7.10.3

---

- Add support for questionnaire-item-control "receiver-component"

  7.10.2

---

- Fix focus bug in dateTime field when touch events is enabled in browser and date is entered by keyboard.

  7.10.1

---

- Remove "InitialFormData" from store.

  7.10.0

---

- Upgrade components to new version of @helsenorge/toolkit and @helsenorge/core-utils. Requires @helsenorge/toolkit v21.0.0 and
  @helsenorge/core-utils v21.0.0
- Upgrade package immer to 9.0.6
- Upgrade package uuid to 8.3.2
- Move package tabbable from depenencies to devDependencies

  7.9.3

---

- Re-render boolean component when resources prop is changed.

  7.9.2

---

- Add new props to disable submit and save buttons in <Form>-component: submitButtonDisabled, saveButtonDisabled

  7.9.1

---

- Show correct value for readonly year and year + month field with initial value.

  7.9.0

---

- Add new fields for year and year + month.
- Fix issue with dropdown value not being updated when deleting a repeatable item.
- Fix issue with entering date by keyboard when touch events is enabled in browser.

  7.8.1

---

- Remove support for unused Questionnaire extensions.

  7.8.0

---

- Add support for sublabel-extension for all components with label.
- Add support for questionnaire-item-control "highlight" for item type = "display".

  7.7.1

---

- Add id-attribute to markup of all form HTML elements.

  7.7.0

---

- Upgrade components to new version of @helsenorge/toolkit and @helsenorge/core-utils. Requires @helsenorge/toolkit v20.0.0 and
  @helsenorge/core-utils v20.0.0

  7.6.6

---

- Do not set empty "text" property for items in QuestionnaireResponse if the item does not have "text" property.

  7.6.5

---

- Add function to get value of sdf-generatepdf Questionnaire extension.

  7.6.4

---

- Replace MessageBox component with NotificationPanel.
- Change button types in confirm delete repeated item dialog from ActionButton to DisplayButton.

  7.6.3

---

- Add prop attachmentErrorMessage, which will be shown in a red messagebox on all attachment fields if set.

  7.6.2

---

- Translate resources for datepicker component.

  7.6.1

---

- Set "text" property in QuestionnaireResponse for repeated groups.

  7.6.0

---

- Upgrade components to new version of @helsenorge/toolkits. Requires @helsenorge/toolkit v19.1.0
- Date-time component will use language from questionnaire to set month and day names.

  7.5.1

---

- Fix crash when using date component with english locale.
- Set month opened in date component to current month (unless a date is set in date component)
- Remove depenency to moment. moment is included as depenency in @helsenorge/toolkit.

  7.5.0

---

- Upgrade components to new version of @helsenorge/toolkit and @helsenorge/core-utils. Requires @helsenorge/toolkit v19.0.0 and
  @helsenorge/core-utils v19.0.0
- New datepicker component. Will use language from questionnaire to set month and day names.
- Change checked color of checkboxes and radio buttons from purple to teal.
- Form button types changed from ActionButton to DisplayButton

  7.4.1

---

- Run enableWhen logic when Coding value is removed (most common when checkbox is un-checked).

  7.4.0

---

- Upgrade components to new version of @helsenorge/toolkit and @helsenorge/core-utils. Requires @helsenorge/toolkit v18.0.0 and
  @helsenorge/core-utils v5.4.0

  7.3.4

---

- When dispatching new value event for choice and open-choice, also send system in valueCoding if item use answerOption instead of
  answerValueSet.

  7.3.3

---

- Show existing answer in autocomplete field when the component is mounted.
- When evaluating enableWhen for a repeated item, search for condition question in repeated parent before searching the rest of the
  questionnaire.
- Fix agressive defauting added zeroes in time and date-time input fields.

  7.3.2

---

- Add function to get item and markdown text for all items with questionnaire-item-control "sidebar".

  7.3.1

---

- Hide no-suggestions message of autocomplete field when autocomplete field lose focus. Never show no-suggestions for open-choice
  autocomplete.
- Remove default placeholder of autocomplete field.

  7.3.0

---

- Add support for questionnaire-item-control "autocomplete" for choice and open-choice. Support url in answerValueSet for choice and
  open-choice.

  7.2.2

---

- Export function isIE11() from utils.

  7.2.1

---

- Add support for scroll navigator. Can be enabled with extension sdf-questionnaire-navgiator-state.

  7.2.0

---

- Skipped, published as beta version only.

  7.1.2

---

- Added support for questionnaire-item-control "highlight" for item type = "text.

  7.1.1

---

- Support for extension sdf-questionnaire-print-version on questionnaire to determine the url (if any) of the binary file representing the
  paper version of this questionnaire.

  7.1.0

---

- Upgrade components to new version of @helsenorge/toolkit and @helsenorge/core-utils. Requires @helsenorge/toolkit v15.0.1 and
  @helsenorge/core-utils v3.0.0

  7.0.2

---

- Fix for 'false' values in enableWhen: run enableWhen matching when answerDecimal and answerInteger is the number 0, and answerString is
  the empty string.

  7.0.1

---

- Performance improvement: Fix componentShouldUpdate check for when resources prop changes

  7.0.0

---

- Upgrade from FHIR STU3 to FHIR R4.

  6.6.1

---

- Update components if new resource prop is set after first render.

  6.6.0

---

- Upgrade components to new version of @helsenorge/toolkit. Requires @helsenorge/toolkit v14.0.0

  6.5.7

---

- Introduce new prop 'syncQuestionnaireResponse' to give limited assistance in synchronizing a Questionnaire and a QuestionnaireResponse
  object. It supports adding and deleting items, and very limited support for changed items. It does not support any extensions. In
  addition, it will convert old linkIds of the form X^Y into new linkIds of the form X.

  6.5.6

---

- Support for setting custom text on delete attachment button (deleteAttachmentText), instead of hardcoded 'Slett'.

  6.5.5

---

- Use v1.6.22 of @helsenorge/core-utils as peerDependency.

  6.5.4

---

- Fix issue with clearing answers of items multiple dependent enableWhen items.

  6.5.3

---

- Improve processing time when clearing answers of items which will hidden by enableWhen.

  6.5.2

---

- Do not set system in Coding object in processNewValueAction(...) if system is undefined or null.

  6.5.1

---

- Fix styling of static buttonbar.

  6.5.0

---

- Upgrade components to new version of @helsenorge/toolkit. Requires @helsenorge/toolkit v13.0.0

  6.4.3

---

- Render add and delete buttons of repeatable fields on separate lines for all field types.
- Remove title attribute of anchor tags rendered from markdown when title is null.

  6.4.2

---

- Fix bug for revalidate of textarea. Requires @helsenorge/toolkit v12.0.12

  6.4.1

---

- Remove extension sdf-save-to-document-archive.
- Support for extension sdf-endpoint on questionnaire to determine the recipient url (if any) of questionnaire.

  6.4.0

---

- Revalidate components when they are updated via props. Requires @helsenorge/toolkit v12.0.8

  6.3.0

---

- Support for error message when required string or text field is empty. Added resource formRequiredErrorMessage ("Du må fylle ut dette
  feltet")

  6.2.4

---

- Support for extension SaveToDocumentArchive on questionnaire to determine where QuestionnaireResponse is saved.

  6.2.3

---

- Add class 'page_skjemautfyller\_\_helpComponent--open' to help component content when content is expanded.

  6.2.2

---

- Repeat-buttons would be rendered on all repeated response items. Now only renders on last response item.

  6.2.1

---

- Fix bug where it was possible to type '000' in hours and minutes fields of time input.

  6.2.0

---

- Support for external rendering of markdown using the new onRenderMarkdown property.

  6.1.3

---

- Fix bug when collapsing enableWhen. Bedore it would not always clear the entered data, this should now be fixed.

  6.1.2

---

- Enable immer for ES5 to support IE11.
- Replace Number.isNaN(...) and Number.isFinite(...) with window.isNaN(...) and window.isFinite(...) to support IE11.

  6.1.1

---

- Add target attribute to list of valid DOMPurify attributes, so lnks can be opened in new tabs.

  6.1.0

---

- Use ExpandableSection component instead of ExpandableBlock component for itemControl-extension inline.
- Add css class 'page_skjemautfyller\_\_component_readonlytext' to markup of readonly string and text fields.

  6.0.0

---

- This version requires @helsenorge/toolkit v12.0.0 or higher as well as @helsenorge/core-utils v1.4.2 or higher.

  5.3.0

---

- Change button placement & button types: save button is now a secondary Actionbutton, instead of a Functionbutton. Save button is now
  between Submit and Cancel buttons.

  5.2.12

---

- Support for http://helsenorge.no/fhir/StructureDefinition/sdf-presentationbuttons

  5.2.11

---

- Support for http://ehelse.no/fhir/StructureDefinition/sdf-maxvalue and http://ehelse.no/fhir/StructureDefinition/sdf-minvalue

  5.2.10

---

- Don't render the Save or Cancel buttons if their callbacks are not defined.

  5.2.9

---

- Rendering optimalizations.

  5.2.8

---

- regex validation support for text fields.

  5.2.7

---

- enableWhen now supports checkboxes where several answers may be given. It triggers when any of the given answers matches the enableWhen
  answer. Previously it would only trigger when the answer exactly matched the enableWhen answer.

  5.2.6

---

- Bug fix for date-fields. Previously it was not possible to clear a date-fields value.

  5.2.5

---

- Added support for questionnaire-item-control type "grid".

  5.2.4

---

- Bug fix for scoring. Don't propagate NaN and Infinite results.

  5.2.3

---

- Support for extension maxDecimalPlaces on quantity types. Now also supports maxDecimalPlaces where the value is 0, in which case the input
  field acts as an integer field.

  5.2.2

---

- Changed the onChange public API to include an IQuestionnaireInspector, that supports querying a questionnaire for QuestionnaireItems and
  QuestionnaireResponses using linkIds.

  5.2.1

---

- Added support for enableWhen with quantity answers.

  5.2.0

---

- Upgrade @helsenorge/core-build and @helsenorge/toolkit

  5.0.1

---

- Added new property onChange, that gets triggered whenever a user answers a question. The onChange callback is passed an instance of
  IActionRequester, that facilitate programmatic changes to the questionnaire.

  5.0.0

---

- Support for scoring with total score (TS), section score (SS) question score (QS) and fhirpath scoring.
- Upgraded @helsenorge/core-build to v10.0.2.
- redux-thunk as middleware is now required.

  4.0.3

---

- Fixes bug where empty answers where not pruned from the reponse tree.

  4.0.2

---

- Added support for hidden items.

  4.0.0

---

- Removed ^ from QuestionnaireResponse for repeating items.

  3.5.2

---

- Update the redux state after typing in a text input (250ms debounce) without leaving (blur) the text input.

  3.5.1

---

- Update the redux state after typing in a text area (250ms debounce) without leaving (blur) the text area.

  3.5.0

---

- Added @helsenorge/toolkit version ^9.0.0 as peerDependency

  3.4.1

---

- Fixed bug when multple enableWhen items are dependent. Now all answers are cleared.

  3.4.0

---

- Use @helsenorge/toolkit version 8.4.2
- Use @helsenorge/core-build 8.1.0
- New rules for eslint og tslint

  3.2.1

---

- Added support for itemControl-extension inline. Using expandable block for child items
- when item type text has itemControl code == inline.

  3.2.0

---

- Use @helsenorge/toolkit version 8

  3.1.0

---

- Added validation of text and string input. If the new prop validateScriptInjection = true then
- html tags in input fields will give a validation error. Added resource validationNotAllowed (er ikke tillatt)

  3.0.3

---

- Fixed bug when a boolean with more than one children is repeated
- When using hasAnswer = false in enableWhen, then the item should be visible if there are no answer.

  3.0.2

---

- All components now properly renders their children. In previous versions, some component types did not render their childre.

  3.0.1

---

- Empty answer objects used to remain in the QuestionnaireResponse structure when an answer was removed. This should no longer be the case.
  An empty answer should now result in the answer property being removed entirely.

  3.0.0

---

- Use new versions of redux (7.1.0), react-redux (4.0.4) and redux-thunk (2.3)
- Added peerDependencies
- Use @helsenorge/toolkit v7.0.0 (added as peerDependency)

  2.6.7

---

- Use @helsenorge/toolkit v6.2.5 that fixes an event-notify issue with datepicker.

  2.6.6

---

- Support for questionnaire-item-control 'table', 'htable', 'gtable' and 'atable'.

  Group-items with itemControl-extension, having one of the codes 'table', 'htable', 'gtable' or 'atable', will be rendered with a
  corresponding class name. E.g. 'page_skjemautfyller\_\_itemControl_gtable'

  2.6.5

---

- Adding onKeyPress validity check on Quantity input so only numbers and decimal go through 2.6.4

---

- When closing items via enableWhen, make sure only the hidden fields are cleaned up, and not unrelated fields.

  2.6.3

---

- Changed the version of moment to "2.22.2" because that version is used by MinHelse

  2.6.1

---

- Use @helsenorge/toolkit v6.2.1

  2.6.0

---

- Introduce a new property 'validationSummaryPlacement' to control the placement of the form validation summary. Possible values are:

      ValidationSummaryPlacement.Top
      ValidationSummaryPlacement.Bottom

  If nothing is specified, it defaults to ValidationSummaryPlacement.Top.

  2.5.1

---

- enableWhen-components that were generated by a repeat used to be expanded as default. This behaviour have now been fixed, so that these
  components are properly expanded according to their criteria.

  2.5.0

---

- Item type of attachment with repeat set to true, will render to a component that can handle upload of multiple files. The component will
  for that reason render without the repeat and delete buttons.

  2.4.0

---

- Added public API to control what file types and file sizes are valid for attachments.

  2.3.0

---

- Added support for helpitems.

  Help for an item can be defined using another item that is a direct descendant of the item in question. This helpitem must be of type
  "text" and implement the itemControl-extension with a code value of "help". Eg.

  { linkId: "1", text: "This is a question", type: "group", item: [ { extension: [ { url:
  "http://hl7.org/fhir/StructureDefinition/questionnaire-itemControl", valueCodeableConcept: { coding: [ { system:
  "http://hl7.org/fhir/ValueSet/questionnaire-item-control", code: "help" } ] } } ], linkId: "1.0.1", text: "This is the help text for the
  item with linkId 1", type: "text" } ] }

  2.2.2

---

- Added component specific css classes for all components.
