formbuilder-lhcforms 9.6.7 → 9.6.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1898,7 +1898,7 @@ ms
1898
1898
  MIT
1899
1899
  The MIT License (MIT)
1900
1900
 
1901
- Copyright (c) 2016 Zeit, Inc.
1901
+ Copyright (c) 2020 Vercel, Inc.
1902
1902
 
1903
1903
  Permission is hereby granted, free of charge, to any person obtaining a copy
1904
1904
  of this software and associated documentation files (the "Software"), to deal
@@ -4,6 +4,24 @@
4
4
  "pattern": "^[ \\r\\n\\t\\S]+$",
5
5
  "type": "string"
6
6
  },
7
+ "Element": {
8
+ "type": "object",
9
+ "description": "Base definition for all elements in a resource.",
10
+ "properties": {
11
+ "id": {
12
+ "description": "Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces.",
13
+ "$ref": "#/definitions/string"
14
+ },
15
+ "extension": {
16
+ "description": "May be used to represent additional information that is not part of the basic definition of the element. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
17
+ "items": {
18
+ "$ref": "#/definitions/Extension"
19
+ },
20
+ "type": "array"
21
+ }
22
+ },
23
+ "additionalProperties": false
24
+ },
7
25
  "Extension": {
8
26
  "description": "Optional Extension Element - found in all resources.",
9
27
  "properties": {
@@ -15,6 +15,7 @@
15
15
  { "field": "answerValueSet", "col": 12 },
16
16
  { "field": "answerOption", "title": "Answer choices", "col": 12 },
17
17
  { "field": "__$itemControl", "col": 12 },
18
+ { "field": "__$itemControlGroup", "col": 12 },
18
19
  { "field": "__$units", "col": 12 }
19
20
  ]
20
21
  },
@@ -102,7 +102,6 @@
102
102
  {"field": "operator", "col": 7, "nolabel": true},
103
103
  {"field": "value", "col": 4, "nolabel": true}
104
104
  ]
105
-
106
105
  }
107
106
  },
108
107
  "maxLength": {
@@ -253,7 +252,7 @@
253
252
  "id": "string-with-css",
254
253
  "labelPosition": "left",
255
254
  "labelClasses": "col-2 ps-0 pe-1",
256
- "controlClasses": "col-3 p-0"
255
+ "controlClasses": "col p-0"
257
256
  }
258
257
  },
259
258
  "_prefix": {
@@ -1046,6 +1045,79 @@
1046
1045
  "controlClasses": "col-auto btn-group btn-group-sm p-0"
1047
1046
  }
1048
1047
  },
1048
+ "__$itemControlGroup": {
1049
+ // Proxy for item control extension.
1050
+ "description": "Choose the type of control for the 'Group' data type. Some item controls are not supported by the LHC-Forms preview, as indicated by the asterisk (*) symbol.",
1051
+ "title": "Group Item Control",
1052
+ "oneOf": [
1053
+ {
1054
+ 'enum': ["list"],
1055
+ 'display': 'List',
1056
+ 'description': 'Questions within the group should be presented sequentially.',
1057
+ 'support': true
1058
+ },
1059
+ {
1060
+ 'enum': ["table"],
1061
+ 'display': 'Vertical Answer Table',
1062
+ 'description': 'For \'choice\' questions, the table representation should have questions as rows and answers as columns. Ensure option sets are consistent within a group. Sparse tables, where certain options are missing for specific questions, may not be rendered as tables by all tools due to inconsistent data structure.',
1063
+ 'support': true
1064
+ },
1065
+ {
1066
+ 'enum': ["htable"],
1067
+ 'display': 'Horizontal Answer Table',
1068
+ 'description': 'For \'choice\' questions, the table representation should have questions as columns and answers as rows. Ensure option sets are consistent within a group. Sparse tables, where certain options are missing for specific questions, may not be rendered as tables by all tools due to inconsistent data structure.',
1069
+ 'support': false
1070
+ },
1071
+ {
1072
+ 'enum': ["gtable"],
1073
+ 'display': 'Group Table',
1074
+ 'description': 'Questions within the group should be presented as columns in the table, with each group repetition forming a new row. This arrangement is suitable for single-answer questions.',
1075
+ 'support': true
1076
+ },
1077
+ {
1078
+ 'enum': ["grid"],
1079
+ 'display': 'Group Grid',
1080
+ 'description': 'Within a \'grid\' group, child items of type=\'group\' represents rows. Questions nested within these row groups are arranged as columns. The grid layout may be fully populated or sparse. Questions can support various data types and answer choices.',
1081
+ 'support': false
1082
+ },
1083
+ {
1084
+ 'enum': ["header"],
1085
+ 'display': 'Header',
1086
+ 'description': 'The group should always be visible at the top of the form\'s display area.',
1087
+ 'support': false
1088
+ },
1089
+ {
1090
+ 'enum': ["footer"],
1091
+ 'display': 'Footer',
1092
+ 'description': 'The group should always be visible at the bottom of the form\'s display area.',
1093
+ 'support': false
1094
+ },
1095
+ {
1096
+ 'enum': ["page"],
1097
+ 'display': 'Page',
1098
+ 'description': 'A page group designation indicates that the content within it should be treated as a single logical unit for rendering. When rendering, all enabled items within the page should be displayed simulatenously, while subsequent groups remain hidden until the user moves to their page. Header and footer groups are typically displayed on all pages. However, items positioned before a page group are considered as being on a separate page.',
1099
+ 'support': false
1100
+ },
1101
+ {
1102
+ 'enum': ["tab-container"],
1103
+ 'display': 'Tab Container',
1104
+ 'description': 'A group with this designation represents a collection of tabs. All child items must be of type \'group\'. Child groups cannot directly declare item controls. Each child group serves as a tab within the tab container, with its \'item.text\' property used as the tab label.',
1105
+ 'support': false
1106
+ }
1107
+ ],
1108
+ "default": "list",
1109
+ "type": "string",
1110
+ "visibleIf": {
1111
+ "type": ["$EXP$ target.value == 'group'"]
1112
+ },
1113
+ "widget": {
1114
+ "id": "item-control",
1115
+ "labelPosition": "left",
1116
+ "labelClasses": "col-2 ps-0 pe-1",
1117
+ "controlClasses": "col-9 btn-group btn-group-sm p-0",
1118
+ "note": "(1) - not supported by LHC-Forms preview."
1119
+ }
1120
+ },
1049
1121
  "__$terminologyServer": {
1050
1122
  "description": "Enter url for preferred terminology server.",
1051
1123
  "title": "Terminology server",
@@ -1480,15 +1552,94 @@
1480
1552
  "type": ["$EXP$ target.value == 'integer' || target.value == 'decimal' || target.value == 'quantity'"]
1481
1553
  }
1482
1554
  },
1555
+ /** Proxy for help text. Help text is represented by a child item.
1556
+ In form builder, to avoid child item to represent like a child question, the help text child item
1557
+ is converted to a proxy field __$helpText. Its _ element is this:
1558
+ item: [{
1559
+ text: 'Plain help text'
1560
+ type: 'display',
1561
+ extension: [{
1562
+ url: 'http://hl7.org/fhir/StructureDefinition/questionnaire-itemControl',
1563
+ valueCodeableConcept: {
1564
+ text: 'Help-Button',
1565
+ coding: [{
1566
+ code: 'help',
1567
+ system: 'http://hl7.org/fhir/questionnaire-item-control'
1568
+ }]
1569
+ }
1570
+ }],
1571
+ // The following _text element is used to specify rendering style and rendering xhtml
1572
+ _text: {
1573
+ extension: [{
1574
+ url: 'http://hl7.org/fhir/StructuredDefinition/rendering-style',
1575
+ valueString: 'css string'
1576
+ },
1577
+ {
1578
+ url: 'http://hl7.org/fhir/StructuredDefinition/rendering-xhtml',
1579
+ valueString: 'xhtml string'
1580
+ }
1581
+ }
1582
+ }]
1583
+ // While input for plain text help is represented by the following __$helpText (string type), the
1584
+ // _text (Element type) of help text item is represented by ___$helpText below
1585
+ */
1483
1586
  "__$helpText": {
1484
1587
  "description": "Text is displayed in a dialog box or similar control if invoked by pushing a button or some other UI-appropriate action to request 'help' for a question, group or the questionnaire as a whole (depending what the text is nested within)",
1485
1588
  "title": "Help text",
1486
- "type": "string",
1589
+ "type": "object",
1590
+ "properties": {
1591
+ "linkId": {
1592
+ "description": "Help text for question.",
1593
+ "title": "Help text",
1594
+ "pattern": "^[^\\s]+( [^\\s]+)*$",
1595
+ "type": "string",
1596
+ "widget": {
1597
+ "id": "hidden"
1598
+ }
1599
+ },
1600
+ "type": {
1601
+ "enum": ['display'],
1602
+ "type": "string",
1603
+ "widget": {
1604
+ "id": "hidden"
1605
+ }
1606
+ },
1607
+ "text": {
1608
+ "description": "Help text for question.",
1609
+ "title": "Help text",
1610
+ "pattern": "^[ \\r\\n\\t\\S]+$",
1611
+ "type": "string",
1612
+ "widget": {
1613
+ "id": "string-with-css",
1614
+ "labelPosition": "left",
1615
+ "labelClasses": "col-sm-2 p-0 pe-1",
1616
+ "controlClasses": "col p-0",
1617
+ }
1618
+ },
1619
+ "_text": {
1620
+ "$ref": "#/definitions/Element",
1621
+ "widget": {
1622
+ "id": "hidden"
1623
+ }
1624
+ },
1625
+ "extension": {
1626
+ "description": "May be used to represent additional information that is not part of the basic definition of the element. To make the use of extensions safe and manageable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension.",
1627
+ "title": "Extensions for text",
1628
+ "items": {
1629
+ "$ref": "#/definitions/Extension"
1630
+ },
1631
+ "type": "array",
1632
+ "widget": {
1633
+ "id": "hidden"
1634
+ }
1635
+ },
1636
+ },
1637
+ "additionalProperties": true,
1487
1638
  "widget": {
1488
1639
  "id": "help-text",
1489
1640
  "labelPosition": "left",
1490
1641
  "labelClasses": "col-sm-2 p-0 pe-1",
1491
- "controlClasses": "col-sm form-control form-control-sm p-1"
1642
+ "controlClasses": "col p-0"
1492
1643
  }
1493
1644
  },
1494
1645
  "__$end": {
@@ -1590,7 +1741,7 @@
1590
1741
  ],
1591
1742
  "showFields": [
1592
1743
  {
1593
- "field": "__$units",
1744
+ "field": "__$helpText",
1594
1745
  "col": 12
1595
1746
  }
1596
1747
  ]
@@ -1639,6 +1790,17 @@
1639
1790
  }
1640
1791
  ]
1641
1792
  },
1793
+ {
1794
+ "fields": [
1795
+ "__$itemControlGroup"
1796
+ ],
1797
+ "showFields": [
1798
+ {
1799
+ "field": "__$itemControlGroup",
1800
+ "col": 12
1801
+ }
1802
+ ]
1803
+ },
1642
1804
  {
1643
1805
  "fields": [
1644
1806
  "__$terminologyServer"
@@ -1 +1 @@
1
- {"version": "9.6.7"}
1
+ {"version": "9.6.9"}
@@ -19,6 +19,6 @@
19
19
  <body class="bg-secondary">
20
20
  <lfb-root></lfb-root>
21
21
  <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.6.0/jquery.min.js"></script>
22
- <script src="runtime.eda6f60d5b6890c8.js" type="module"></script><script src="polyfills.ef59bbccd462f5ac.js" type="module"></script><script src="scripts.5c83cbb4dbb11a83.js" defer></script><script src="main.4eb07da4b7d3ba86.js" type="module"></script></body>
22
+ <script src="runtime.eda6f60d5b6890c8.js" type="module"></script><script src="polyfills.ef59bbccd462f5ac.js" type="module"></script><script src="scripts.5c83cbb4dbb11a83.js" defer></script><script src="main.52488ee249d56b57.js" type="module"></script></body>
23
23
  </html>
24
24