@f1studio/form-spec 5.0.0-alpha.149 → 5.0.0-alpha.152

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.
Files changed (255) hide show
  1. package/FormSpec.FS/Integrations/Adapters/CorEMR/CoreMREncoder.d.ts.map +1 -1
  2. package/FormSpec.FS/Integrations/Adapters/CorEMR/CoreMRSourceMap.d.ts +5 -3
  3. package/FormSpec.FS/Integrations/Adapters/CorEMR/CoreMRSourceMap.d.ts.map +1 -1
  4. package/FormSpec.FS/Integrations/CorEMR/ItemTriggerConverter.d.ts +19 -0
  5. package/FormSpec.FS/Integrations/CorEMR/ItemTriggerConverter.d.ts.map +1 -0
  6. package/FormSpec.FS/Integrations/CorEMR/TemplateManifestDecoder.d.ts +39 -2
  7. package/FormSpec.FS/Integrations/CorEMR/TemplateManifestDecoder.d.ts.map +1 -1
  8. package/FormSpec.FS/Interop/Facade/BlueprintFilledForm.d.ts +16 -0
  9. package/FormSpec.FS/Interop/Facade/BlueprintFilledForm.d.ts.map +1 -1
  10. package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/CorEMR/CorEMRElementTypeMap.js +3 -3
  11. package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/CorEMR/CorEMRElementTypeMap.js.map +1 -1
  12. package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/CorEMR/CorEMRFieldTypeMapper.js +2 -2
  13. package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/CorEMR/CorEMRFieldTypeMapper.js.map +1 -1
  14. package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/CorEMR/CorEMRTemplateToFormSpec.js +1 -1
  15. package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/CorEMR/CorEMRTemplateToFormSpec.js.map +1 -1
  16. package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/CorEMR/CoreMREncoder.js +23 -21
  17. package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/CorEMR/CoreMREncoder.js.map +1 -1
  18. package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/CorEMR/CoreMRSourceMap.js +16 -7
  19. package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/CorEMR/CoreMRSourceMap.js.map +1 -1
  20. package/FormSpec.TS/FormSpec.FS/Integrations/CorEMR/ItemTriggerConverter.js +580 -0
  21. package/FormSpec.TS/FormSpec.FS/Integrations/CorEMR/ItemTriggerConverter.js.map +1 -0
  22. package/FormSpec.TS/FormSpec.FS/Integrations/CorEMR/TemplateManifestDecoder.js +199 -8
  23. package/FormSpec.TS/FormSpec.FS/Integrations/CorEMR/TemplateManifestDecoder.js.map +1 -1
  24. package/FormSpec.TS/FormSpec.FS/Interop/Facade/BlueprintFilledForm.js +25 -1
  25. package/FormSpec.TS/FormSpec.FS/Interop/Facade/BlueprintFilledForm.js.map +1 -1
  26. package/FormSpec.TS/Thoth.Json/packages/Thoth.Json/Encode.js.map +1 -1
  27. package/README.md +7 -7
  28. package/package.json +13 -15
  29. package/src/FormSpec.FS/Integrations/Adapters/CorEMR/CorEMRElementTypeMap.ts +3 -3
  30. package/src/FormSpec.FS/Integrations/Adapters/CorEMR/CorEMRFieldTypeMapper.ts +3 -3
  31. package/src/FormSpec.FS/Integrations/Adapters/CorEMR/CorEMRTemplateToFormSpec.ts +1 -1
  32. package/src/FormSpec.FS/Integrations/Adapters/CorEMR/CoreMREncoder.ts +25 -23
  33. package/src/FormSpec.FS/Integrations/Adapters/CorEMR/CoreMRSourceMap.ts +19 -13
  34. package/src/FormSpec.FS/Integrations/CorEMR/ItemTriggerConverter.ts +545 -0
  35. package/src/FormSpec.FS/Integrations/CorEMR/TemplateManifestDecoder.ts +120 -14
  36. package/src/FormSpec.FS/Interop/Facade/BlueprintFilledForm.ts +29 -1
  37. package/FormSpec.TS/FormSpec.FS/BitmaskHelpers.ts.map +0 -1
  38. package/FormSpec.TS/FormSpec.FS/BlueprintValidation.ts.map +0 -1
  39. package/FormSpec.TS/FormSpec.FS/Components/HelloComponent.ts.map +0 -1
  40. package/FormSpec.TS/FormSpec.FS/Designer.ts.map +0 -1
  41. package/FormSpec.TS/FormSpec.FS/FormSpec.ts.map +0 -1
  42. package/FormSpec.TS/FormSpec.FS/FormSpecHelpers.ts.map +0 -1
  43. package/FormSpec.TS/FormSpec.FS/FormSpecValues.ts.map +0 -1
  44. package/FormSpec.TS/FormSpec.FS/Helpers.ts.map +0 -1
  45. package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/CorEMR/CorEMRAdapter.ts.map +0 -1
  46. package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/CorEMR/CorEMRElementTypeMap.ts.map +0 -1
  47. package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/CorEMR/CorEMRFieldTypeMapper.ts.map +0 -1
  48. package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/CorEMR/CorEMRFormSpecValidator.ts.map +0 -1
  49. package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/CorEMR/CorEMRSectioning.ts.map +0 -1
  50. package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/CorEMR/CorEMRSemanticReportBuilder.ts.map +0 -1
  51. package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/CorEMR/CorEMRStepsBuilder.ts.map +0 -1
  52. package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/CorEMR/CorEMRTemplateMapper.ts.map +0 -1
  53. package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/CorEMR/CorEMRTemplateToFormSpec.ts.map +0 -1
  54. package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/CorEMR/CorEMRTriggerConverter.ts.map +0 -1
  55. package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/CorEMR/CoreMREncoder.ts.map +0 -1
  56. package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/CorEMR/CoreMRSourceMap.ts.map +0 -1
  57. package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/CorEMR/FormSpecToCoreMRInsert.ts.map +0 -1
  58. package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/FormSystemAdapter.ts.map +0 -1
  59. package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/ReactHookForm/ReactHookFormAdapter.ts.map +0 -1
  60. package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/ReactHookForm/ReactHookFormTypes.ts.map +0 -1
  61. package/FormSpec.TS/FormSpec.FS/Integrations/CorEMR/CoreMRTypes.ts.map +0 -1
  62. package/FormSpec.TS/FormSpec.FS/Integrations/CorEMR/TemplateDecodeTypes.ts.map +0 -1
  63. package/FormSpec.TS/FormSpec.FS/Integrations/CorEMR/TemplateManifestDecoder.ts.map +0 -1
  64. package/FormSpec.TS/FormSpec.FS/Integrations/OpenFda/OpenFdaTypes.ts.map +0 -1
  65. package/FormSpec.TS/FormSpec.FS/Interfaces.ts.map +0 -1
  66. package/FormSpec.TS/FormSpec.FS/Interop/Facade/BlueprintFilledForm.ts.map +0 -1
  67. package/FormSpec.TS/FormSpec.FS/Interop/Facade/FormAnswersGate.ts.map +0 -1
  68. package/FormSpec.TS/FormSpec.FS/Interop/FormSpec.Api.Helpers.ts.map +0 -1
  69. package/FormSpec.TS/FormSpec.FS/Interop/FormSpec.Api.Option.ts.map +0 -1
  70. package/FormSpec.TS/FormSpec.FS/Interop/FormSpec.Values.Api.Option.ts.map +0 -1
  71. package/FormSpec.TS/FormSpec.FS/Logging/LogTypes.ts.map +0 -1
  72. package/FormSpec.TS/FormSpec.FS/Migrator.ts.map +0 -1
  73. package/FormSpec.TS/FormSpec.FS/PathwayDataExtractor.ts.map +0 -1
  74. package/FormSpec.TS/FormSpec.FS/PathwayExecutor.ts.map +0 -1
  75. package/FormSpec.TS/FormSpec.FS/PathwayValidator.ts.map +0 -1
  76. package/FormSpec.TS/FormSpec.FS/PluginInterface.ts.map +0 -1
  77. package/FormSpec.TS/FormSpec.FS/Prelude.ts.map +0 -1
  78. package/FormSpec.TS/FormSpec.FS/Provenance.ts.map +0 -1
  79. package/FormSpec.TS/FormSpec.FS/Renderers/FormSpecMarkdownRenderer.ts.map +0 -1
  80. package/FormSpec.TS/FormSpec.FS/Renderers/MermaidRenderer.ts.map +0 -1
  81. package/FormSpec.TS/FormSpec.FS/Renderers/PathwayRenderers.ts.map +0 -1
  82. package/FormSpec.TS/PluginRegistration.ts.map +0 -1
  83. package/FormSpec.TS/Thoth.Json/packages/Thoth.Json/Decode.ts.map +0 -1
  84. package/FormSpec.TS/Thoth.Json/packages/Thoth.Json/Encode.ts.map +0 -1
  85. package/FormSpec.TS/Thoth.Json/packages/Thoth.Json/Extra.ts.map +0 -1
  86. package/FormSpec.TS/Thoth.Json/packages/Thoth.Json/Types.ts.map +0 -1
  87. package/FormSpec.TS/fable_modules/Fable.Form.3.0.0/Base.fs +0 -511
  88. package/FormSpec.TS/fable_modules/Fable.Form.3.0.0/Base.fs.ts.map +0 -1
  89. package/FormSpec.TS/fable_modules/Fable.Form.3.0.0/Error.fs +0 -16
  90. package/FormSpec.TS/fable_modules/Fable.Form.3.0.0/Error.fs.ts.map +0 -1
  91. package/FormSpec.TS/fable_modules/Fable.Form.3.0.0/Extensions.fs +0 -50
  92. package/FormSpec.TS/fable_modules/Fable.Form.3.0.0/Extensions.fs.ts.map +0 -1
  93. package/FormSpec.TS/fable_modules/Fable.Form.3.0.0/Fable.Form.fableproj +0 -28
  94. package/FormSpec.TS/fable_modules/Fable.Form.3.0.0/Field.fs +0 -24
  95. package/FormSpec.TS/fable_modules/Fable.Form.3.0.0/Field.fs.ts.map +0 -1
  96. package/FormSpec.TS/fable_modules/Fable.Form.Simple.5.0.1/Fable.Form.Simple.fableproj +0 -31
  97. package/FormSpec.TS/fable_modules/Fable.Form.Simple.5.0.1/Form.fs +0 -178
  98. package/FormSpec.TS/fable_modules/Fable.Form.Simple.5.0.1/Form.fs.ts.map +0 -1
  99. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/CheckboxField.fs +0 -47
  100. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/CheckboxField.fs.ts.map +0 -1
  101. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/ColorField.fs +0 -49
  102. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/ColorField.fs.ts.map +0 -1
  103. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/DateField.fs +0 -52
  104. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/DateField.fs.ts.map +0 -1
  105. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/DateTimeLocalField.fs +0 -54
  106. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/DateTimeLocalField.fs.ts.map +0 -1
  107. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/EmailField.fs +0 -48
  108. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/EmailField.fs.ts.map +0 -1
  109. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/Fable.Form.Simple.Bulma.fableproj +0 -53
  110. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/FileField.fs +0 -132
  111. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/FileField.fs.ts.map +0 -1
  112. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/Form.fs +0 -537
  113. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/Form.fs.ts.map +0 -1
  114. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/FormList.fs +0 -361
  115. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/FormList.fs.ts.map +0 -1
  116. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/Group.fs +0 -52
  117. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/Group.fs.ts.map +0 -1
  118. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/Html.View.fs +0 -246
  119. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/Html.View.fs.ts.map +0 -1
  120. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/InputField.fs +0 -52
  121. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/InputField.fs.ts.map +0 -1
  122. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/NumberField.fs +0 -56
  123. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/NumberField.fs.ts.map +0 -1
  124. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/PasswordField.fs +0 -46
  125. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/PasswordField.fs.ts.map +0 -1
  126. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/RadioField.fs +0 -51
  127. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/RadioField.fs.ts.map +0 -1
  128. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/SearchField.fs +0 -49
  129. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/SearchField.fs.ts.map +0 -1
  130. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/Section.fs +0 -60
  131. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/Section.fs.ts.map +0 -1
  132. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/SelectField.fs +0 -79
  133. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/SelectField.fs.ts.map +0 -1
  134. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/TelField.fs +0 -44
  135. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/TelField.fs.ts.map +0 -1
  136. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/TextField.fs +0 -49
  137. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/TextField.fs.ts.map +0 -1
  138. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/TextareaField.fs +0 -59
  139. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/TextareaField.fs.ts.map +0 -1
  140. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/TimeField.fs +0 -44
  141. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/TimeField.fs.ts.map +0 -1
  142. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/Types.fs +0 -143
  143. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Bulma.5.0.1/Types.fs.ts.map +0 -1
  144. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Fields.Html.1.0.1/CheckboxField.fs +0 -36
  145. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Fields.Html.1.0.1/CheckboxField.fs.ts.map +0 -1
  146. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Fields.Html.1.0.1/ColorField.fs +0 -49
  147. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Fields.Html.1.0.1/ColorField.fs.ts.map +0 -1
  148. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Fields.Html.1.0.1/DateField.fs +0 -67
  149. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Fields.Html.1.0.1/DateField.fs.ts.map +0 -1
  150. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Fields.Html.1.0.1/DateTimeLocalField.fs +0 -70
  151. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Fields.Html.1.0.1/DateTimeLocalField.fs.ts.map +0 -1
  152. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Fields.Html.1.0.1/EmailField.fs +0 -76
  153. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Fields.Html.1.0.1/EmailField.fs.ts.map +0 -1
  154. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Fields.Html.1.0.1/Fable.Form.Simple.Fields.Html.fableproj +0 -45
  155. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Fields.Html.1.0.1/NumberField.fs +0 -105
  156. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Fields.Html.1.0.1/NumberField.fs.ts.map +0 -1
  157. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Fields.Html.1.0.1/PasswordField.fs +0 -66
  158. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Fields.Html.1.0.1/PasswordField.fs.ts.map +0 -1
  159. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Fields.Html.1.0.1/RadioField.fs +0 -72
  160. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Fields.Html.1.0.1/RadioField.fs.ts.map +0 -1
  161. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Fields.Html.1.0.1/RangeField.fs +0 -102
  162. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Fields.Html.1.0.1/RangeField.fs.ts.map +0 -1
  163. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Fields.Html.1.0.1/SearchField.fs +0 -83
  164. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Fields.Html.1.0.1/SearchField.fs.ts.map +0 -1
  165. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Fields.Html.1.0.1/SelectField.fs +0 -83
  166. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Fields.Html.1.0.1/SelectField.fs.ts.map +0 -1
  167. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Fields.Html.1.0.1/TelField.fs +0 -63
  168. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Fields.Html.1.0.1/TelField.fs.ts.map +0 -1
  169. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Fields.Html.1.0.1/TextField.fs +0 -83
  170. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Fields.Html.1.0.1/TextField.fs.ts.map +0 -1
  171. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Fields.Html.1.0.1/TextareaField.fs +0 -92
  172. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Fields.Html.1.0.1/TextareaField.fs.ts.map +0 -1
  173. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Fields.Html.1.0.1/TimeField.fs +0 -108
  174. package/FormSpec.TS/fable_modules/Fable.Form.Simple.Fields.Html.1.0.1/TimeField.fs.ts.map +0 -1
  175. package/FormSpec.TS/fable_modules/Fable.Promise.3.2.0/AsyncIterable.fs +0 -57
  176. package/FormSpec.TS/fable_modules/Fable.Promise.3.2.0/AsyncIterable.fs.ts.map +0 -1
  177. package/FormSpec.TS/fable_modules/Fable.Promise.3.2.0/Fable.Promise.fableproj +0 -20
  178. package/FormSpec.TS/fable_modules/Fable.Promise.3.2.0/Promise.fs +0 -766
  179. package/FormSpec.TS/fable_modules/Fable.Promise.3.2.0/Promise.fs.ts.map +0 -1
  180. package/FormSpec.TS/fable_modules/Fable.Promise.3.2.0/PromiseImpl.fs +0 -31
  181. package/FormSpec.TS/fable_modules/Fable.Promise.3.2.0/PromiseImpl.fs.ts.map +0 -1
  182. package/FormSpec.TS/fable_modules/Fable.React.Types.18.3.0/Fable.React.Extensions.fs +0 -17
  183. package/FormSpec.TS/fable_modules/Fable.React.Types.18.3.0/Fable.React.Hooks.fs +0 -152
  184. package/FormSpec.TS/fable_modules/Fable.React.Types.18.3.0/Fable.React.Hooks.fs.ts.map +0 -1
  185. package/FormSpec.TS/fable_modules/Fable.React.Types.18.3.0/Fable.React.Types.fableproj +0 -28
  186. package/FormSpec.TS/fable_modules/Fable.React.Types.18.3.0/Fable.React.fs +0 -218
  187. package/FormSpec.TS/fable_modules/Fable.React.Types.18.3.0/Fable.React.fs.ts.map +0 -1
  188. package/FormSpec.TS/fable_modules/Fable.ReactDom.Types.18.2.0/Fable.ReactDom.Types.fableproj +0 -27
  189. package/FormSpec.TS/fable_modules/Fable.ReactDom.Types.18.2.0/Fable.ReactDom.fs +0 -82
  190. package/FormSpec.TS/fable_modules/Fable.ReactDom.Types.18.2.0/Fable.ReactDom.fs.ts.map +0 -1
  191. package/FormSpec.TS/fable_modules/Feliz.2.8.0/BorderStyle.fs +0 -59
  192. package/FormSpec.TS/fable_modules/Feliz.2.8.0/Colors.fs +0 -154
  193. package/FormSpec.TS/fable_modules/Feliz.2.8.0/Colors.fs.ts.map +0 -1
  194. package/FormSpec.TS/fable_modules/Feliz.2.8.0/DateParsing.fs +0 -52
  195. package/FormSpec.TS/fable_modules/Feliz.2.8.0/DateParsing.fs.ts.map +0 -1
  196. package/FormSpec.TS/fable_modules/Feliz.2.8.0/Feliz.fableproj +0 -53
  197. package/FormSpec.TS/fable_modules/Feliz.2.8.0/Fonts.fs +0 -240
  198. package/FormSpec.TS/fable_modules/Feliz.2.8.0/GridTypes.fs +0 -24
  199. package/FormSpec.TS/fable_modules/Feliz.2.8.0/Helpers.fs +0 -11
  200. package/FormSpec.TS/fable_modules/Feliz.2.8.0/Helpers.fs.ts.map +0 -1
  201. package/FormSpec.TS/fable_modules/Feliz.2.8.0/Html.fs +0 -826
  202. package/FormSpec.TS/fable_modules/Feliz.2.8.0/Internal.fs +0 -176
  203. package/FormSpec.TS/fable_modules/Feliz.2.8.0/Internal.fs.ts.map +0 -1
  204. package/FormSpec.TS/fable_modules/Feliz.2.8.0/Interop.fs +0 -29
  205. package/FormSpec.TS/fable_modules/Feliz.2.8.0/Interop.fs.ts.map +0 -1
  206. package/FormSpec.TS/fable_modules/Feliz.2.8.0/Key.fs +0 -65
  207. package/FormSpec.TS/fable_modules/Feliz.2.8.0/Key.fs.ts.map +0 -1
  208. package/FormSpec.TS/fable_modules/Feliz.2.8.0/Length.fs +0 -145
  209. package/FormSpec.TS/fable_modules/Feliz.2.8.0/Locale.fs +0 -876
  210. package/FormSpec.TS/fable_modules/Feliz.2.8.0/Properties.fs +0 -4085
  211. package/FormSpec.TS/fable_modules/Feliz.2.8.0/Properties.fs.ts.map +0 -1
  212. package/FormSpec.TS/fable_modules/Feliz.2.8.0/React.fs +0 -494
  213. package/FormSpec.TS/fable_modules/Feliz.2.8.0/ReactDOM.fs +0 -25
  214. package/FormSpec.TS/fable_modules/Feliz.2.8.0/ReactDOM.fs.ts.map +0 -1
  215. package/FormSpec.TS/fable_modules/Feliz.2.8.0/ReactInterop.fs +0 -20
  216. package/FormSpec.TS/fable_modules/Feliz.2.8.0/ReactTypes.fs +0 -42
  217. package/FormSpec.TS/fable_modules/Feliz.2.8.0/ReactTypes.fs.ts.map +0 -1
  218. package/FormSpec.TS/fable_modules/Feliz.2.8.0/StyleTypes.fs +0 -57
  219. package/FormSpec.TS/fable_modules/Feliz.2.8.0/StyleTypes.fs.ts.map +0 -1
  220. package/FormSpec.TS/fable_modules/Feliz.2.8.0/Styles.fs +0 -6378
  221. package/FormSpec.TS/fable_modules/Feliz.2.8.0/Svg.fs +0 -1455
  222. package/FormSpec.TS/fable_modules/Feliz.2.8.0/Svg.fs.ts.map +0 -1
  223. package/FormSpec.TS/fable_modules/Feliz.2.8.0/TextDecorationLine.fs +0 -13
  224. package/FormSpec.TS/fable_modules/Feliz.2.8.0/TextDecorationStyle.fs +0 -33
  225. package/FormSpec.TS/fable_modules/Feliz.2.8.0/Transform.fs +0 -181
  226. package/FormSpec.TS/fable_modules/Feliz.2.8.0/TransformOrigin.fs +0 -17
  227. package/FormSpec.TS/fable_modules/Feliz.2.8.0/TransitionProperty.fs +0 -162
  228. package/FormSpec.TS/fable_modules/Feliz.2.8.0/TransitionTimingFunction.fs +0 -62
  229. package/FormSpec.TS/fable_modules/Feliz.2.8.0/Types.fs +0 -13
  230. package/FormSpec.TS/fable_modules/Feliz.2.8.0/Types.fs.ts.map +0 -1
  231. package/FormSpec.TS/fable_modules/Feliz.Bulma.3.0.0/Bulma.fs +0 -990
  232. package/FormSpec.TS/fable_modules/Feliz.Bulma.3.0.0/ElementBuilders.fs +0 -179
  233. package/FormSpec.TS/fable_modules/Feliz.Bulma.3.0.0/ElementBuilders.fs.ts.map +0 -1
  234. package/FormSpec.TS/fable_modules/Feliz.Bulma.3.0.0/Feliz.Bulma.fableproj +0 -32
  235. package/FormSpec.TS/fable_modules/Feliz.Bulma.3.0.0/Modifiers.fs +0 -1986
  236. package/FormSpec.TS/fable_modules/Feliz.Bulma.3.0.0/Modifiers.fs.ts.map +0 -1
  237. package/FormSpec.TS/fable_modules/Feliz.Bulma.3.0.0/Operators.fs +0 -7
  238. package/FormSpec.TS/fable_modules/Feliz.Bulma.3.0.0/Operators.fs.ts.map +0 -1
  239. package/FormSpec.TS/fable_modules/Feliz.Bulma.3.0.0/PropertyBuilders.fs +0 -8
  240. package/FormSpec.TS/fable_modules/Glutinum.Feliz.ReactSignaturePadWrapper.1.0.2/Exports.fs +0 -14
  241. package/FormSpec.TS/fable_modules/Glutinum.Feliz.ReactSignaturePadWrapper.1.0.2/Glutinum.Feliz.ReactSignaturePadWrapper.fableproj +0 -18
  242. package/FormSpec.TS/fable_modules/Glutinum.Feliz.ReactSignaturePadWrapper.1.0.2/Interop.fs +0 -6
  243. package/FormSpec.TS/fable_modules/Glutinum.Feliz.ReactSignaturePadWrapper.1.0.2/ReactSignaturePadWrapper.fs +0 -32
  244. package/FormSpec.TS/fable_modules/Glutinum.Feliz.ReactSignaturePadWrapper.1.0.2/Types.fs +0 -3
  245. package/FormSpec.TS/fable_modules/Glutinum.Feliz.ReactSignaturePadWrapper.1.0.2/Types.fs.ts.map +0 -1
  246. package/FormSpec.TS/fable_modules/project_cracked.json +0 -1
  247. package/FormSpec.TS/plugins/allergyfinder/src/AllergyFinderField.ts.map +0 -1
  248. package/FormSpec.TS/plugins/allergyfinder/src/AllergyLogic.ts.map +0 -1
  249. package/FormSpec.TS/plugins/allergyfinder/src/OpenFdaClient.ts.map +0 -1
  250. package/FormSpec.TS/plugins/bmi/src/BMIField.ts.map +0 -1
  251. package/FormSpec.TS/plugins/demographics/src/DemographicsField.ts.map +0 -1
  252. package/FormSpec.TS/plugins/likert/src/LikertField.ts.map +0 -1
  253. package/FormSpec.TS/plugins/signature/src/SignatureField.ts.map +0 -1
  254. package/FormSpec.TS/plugins/vitals/src/VitalsField.ts.map +0 -1
  255. package/FormSpec.TS/plugins/vitals/src/VitalsLogic.ts.map +0 -1
@@ -1,361 +0,0 @@
1
- namespace Fable.Form.Simple.Bulma.Fields
2
-
3
- open Fable.Form
4
- open Feliz
5
- open Feliz.Bulma
6
- open Fable.Form.Simple
7
- open Fable.Form.Simple.Bulma
8
- open Fable.Form.Extensions
9
-
10
- module FormList =
11
-
12
- [<NoComparison; NoEquality>]
13
- type Form<'Values, 'Field> =
14
- {
15
- Fields: Base.FilledField<'Field> list
16
- Delete: unit -> 'Values
17
- }
18
-
19
- type Attributes =
20
- {
21
- FieldId: string
22
- Label: string
23
- Add: string option
24
- Delete: string option
25
- }
26
-
27
- [<NoComparison; NoEquality>]
28
- type InnerField<'Values, 'Field> =
29
- {
30
- Forms: Form<'Values, 'Field> list
31
- Add: unit -> 'Values
32
- Attributes: Attributes
33
- }
34
-
35
- [<NoComparison; NoEquality>]
36
- type Config<'Values, 'ElementValues> =
37
- {
38
- Value: 'Values -> 'ElementValues list
39
- Update: 'ElementValues list -> 'Values -> 'Values
40
- Default: 'ElementValues
41
- Attributes: Attributes
42
- }
43
-
44
- type ElementContext =
45
- {
46
- FieldIdPrefix: string
47
- Index: int
48
- }
49
-
50
- [<NoComparison; NoEquality>]
51
- type ElementState<'Values, 'ElementValues> =
52
- {
53
- FieldIdPrefix: string
54
- Index: int
55
- Update: 'ElementValues -> 'Values -> 'Values
56
- Values: 'Values
57
- ElementValues: 'ElementValues
58
- }
59
-
60
- let form<'Values, 'Field, 'ElementValues, 'Output>
61
- (tagger: InnerField<'Values, 'Field> -> 'Field)
62
- (formConfig: Config<'Values, 'ElementValues>)
63
- (buildElement: ElementState<'Values, 'ElementValues> -> Base.FilledForm<'Output, 'Field>)
64
- : Base.Form<'Values, 'Output list, 'Field>
65
- =
66
-
67
- Base.custom (fun values ->
68
- let listOfElementValues = formConfig.Value values
69
-
70
- let elementForIndex index elementValues =
71
- buildElement
72
- {
73
- FieldIdPrefix = formConfig.Attributes.FieldId + "-" + string index
74
- Update =
75
- fun newElementValues values ->
76
- let newList = List.setAt index newElementValues listOfElementValues
77
-
78
- formConfig.Update newList values
79
- Index = index
80
- Values = values
81
- ElementValues = elementValues
82
- }
83
-
84
- let filledElements = List.mapi elementForIndex listOfElementValues
85
-
86
- let toForm (index: int) (form: Base.FilledForm<'Output, 'Field>) =
87
- {
88
- Fields = form.Fields
89
- Delete =
90
- fun () ->
91
- let previousForms = List.take index listOfElementValues
92
-
93
- let nextForms = List.drop (index + 1) listOfElementValues
94
-
95
- formConfig.Update (previousForms @ nextForms) values
96
- }
97
-
98
- let gatherResults
99
- (next: Base.FilledForm<'Output, 'Field>)
100
- (current: Result<'Output list, Error.Error * Error.Error list>)
101
- : Result<'Output list, Error.Error * Error.Error list>
102
- =
103
-
104
- match next.Result with
105
- | Ok output -> Result.map (fun x -> output :: x) current
106
-
107
- | Error(head, errors) ->
108
- match current with
109
- | Ok _ -> Error(head, errors)
110
-
111
- | Error(currentHead, currentErrors) ->
112
- Error(head, errors @ (currentHead :: currentErrors))
113
-
114
- let result = List.foldBack gatherResults filledElements (Ok [])
115
-
116
- let isEmpty =
117
- List.fold
118
- (fun state (element: Base.FilledForm<'Output, 'Field>) ->
119
- element.IsEmpty && state
120
- )
121
- false
122
- filledElements
123
-
124
- {
125
- State =
126
- tagger
127
- {
128
- Forms = List.mapi toForm filledElements
129
- Add =
130
- fun _ ->
131
- formConfig.Update
132
- (listOfElementValues
133
- @ [
134
- formConfig.Default
135
- ])
136
- values
137
- Attributes = formConfig.Attributes
138
- }
139
- Result = result
140
- IsEmpty = isEmpty
141
- }
142
- )
143
-
144
- module View =
145
-
146
- [<NoComparison; NoEquality>]
147
- type FormListConfig =
148
- {
149
- Forms: ReactElement list
150
- Label: string
151
- Add:
152
- {|
153
- Action: unit -> unit
154
- Label: string
155
- |} option
156
- Disabled: bool
157
- }
158
-
159
- [<NoComparison; NoEquality>]
160
- type FormListItemConfig =
161
- {
162
- Fields: ReactElement list
163
- Delete:
164
- {|
165
- Action: unit -> unit
166
- Label: string
167
- |} option
168
- Disabled: bool
169
- }
170
-
171
- let formList
172
- ({
173
- Forms = forms
174
- Label = label
175
- Add = add
176
- Disabled = disabled
177
- }: FormListConfig)
178
- =
179
-
180
- let addButton =
181
- match disabled, add with
182
- | (false, Some add) ->
183
- Bulma.button.a [
184
- prop.onClick (fun _ -> add.Action())
185
-
186
- prop.children [
187
- Bulma.icon [
188
- icon.isSmall
189
-
190
- prop.children [
191
- Html.i [
192
- prop.className "fas fa-plus"
193
- ]
194
- ]
195
- ]
196
-
197
- Html.span add.Label
198
- ]
199
- ]
200
-
201
- | _ -> Html.none
202
-
203
- Bulma.field.div [
204
- Bulma.control.div [
205
- Html.View.fieldLabel label
206
-
207
- yield! forms
208
-
209
- addButton
210
- ]
211
- ]
212
-
213
- let formListItem
214
- ({
215
- Fields = fields
216
- Delete = delete
217
- Disabled = disabled
218
- }: FormListItemConfig)
219
- =
220
-
221
- let removeButton =
222
- match disabled, delete with
223
- | (false, Some delete) ->
224
- Bulma.button.a [
225
- prop.onClick (fun _ -> delete.Action())
226
-
227
- prop.children [
228
- Bulma.icon [
229
- icon.isSmall
230
-
231
- prop.children [
232
- Html.i [
233
- prop.className "fas fa-times"
234
- ]
235
- ]
236
- ]
237
-
238
- if delete.Label <> "" then
239
- Html.span delete.Label
240
- ]
241
- ]
242
-
243
- | _ -> Html.none
244
-
245
- Html.div [
246
- prop.className "form-list"
247
-
248
- prop.children [
249
- yield! fields
250
-
251
- Bulma.field.div [
252
- field.isGrouped
253
- field.isGroupedRight
254
-
255
- prop.children [
256
- Bulma.control.div [
257
- removeButton
258
- ]
259
- ]
260
- ]
261
- ]
262
- ]
263
-
264
- type Field<'Values, 'Field, 'Output, 'Value>(innerField: InnerField<'Values, IField<'Values>>) =
265
-
266
- inherit IGenericField<'Values>()
267
-
268
- interface IField<'Values> with
269
-
270
- member _.MapFieldValues(update: 'Values -> 'NewValues) : IField<'NewValues> =
271
- Field
272
- {
273
- Forms =
274
- List.map
275
- (fun (form: Form<'Values, IField<'Values>>) ->
276
- {
277
- Fields =
278
- List.map
279
- (fun
280
- (filledField: Base.FilledField<IField<'Values>>) ->
281
- {
282
- State =
283
- filledField.State.MapFieldValues
284
- update
285
- Error = filledField.Error
286
- IsDisabled = filledField.IsDisabled
287
- IsReadOnly = filledField.IsReadOnly
288
- }
289
- )
290
- form.Fields
291
- Delete = fun _ -> update (form.Delete())
292
- }
293
- )
294
- innerField.Forms
295
- Add = fun _ -> update (innerField.Add())
296
- Attributes = innerField.Attributes
297
- }
298
-
299
- override _.RenderField
300
- (fieldConfig: Form.View.FieldConfig<'Values, 'Msg>)
301
- (filledField: FilledField<'Values>)
302
- =
303
- View.formList
304
- {
305
- Forms =
306
- innerField.Forms
307
- |> List.map (fun
308
- {
309
- Fields = fields
310
- Delete = delete
311
- } ->
312
- View.formListItem
313
- {
314
- Fields = List.map (Html.View.renderField fieldConfig) fields
315
- Delete =
316
- innerField.Attributes.Delete
317
- |> Option.map (fun deleteLabel ->
318
- {|
319
- Action = delete >> fieldConfig.OnChange
320
- Label = deleteLabel
321
- |}
322
- )
323
- Disabled = filledField.IsDisabled || fieldConfig.Disabled
324
- }
325
- )
326
- Label = innerField.Attributes.Label
327
- Add =
328
- innerField.Attributes.Add
329
- |> Option.map (fun addLabel ->
330
- {|
331
- Action = innerField.Add >> fieldConfig.OnChange
332
- Label = addLabel
333
- |}
334
- )
335
- Disabled = filledField.IsDisabled || fieldConfig.Disabled
336
- }
337
-
338
- type FormList =
339
-
340
- static member create(fieldId: string) : FormList.Attributes =
341
- {
342
- FieldId = fieldId
343
- Label = ""
344
- Add = None
345
- Delete = None
346
- }
347
-
348
- static member withLabel (label: string) (attributes: FormList.Attributes) =
349
- { attributes with
350
- Label = label
351
- }
352
-
353
- static member withAdd (add: string) (attributes: FormList.Attributes) =
354
- { attributes with
355
- Add = Some add
356
- }
357
-
358
- static member withDelete (delete: string) (attributes: FormList.Attributes) =
359
- { attributes with
360
- Delete = Some delete
361
- }
@@ -1 +0,0 @@
1
- {"version":3,"sources":["./FormList.fs","../Feliz.2.8.0/Properties.fs","../Feliz.Bulma.3.0.0/ElementBuilders.fs","../Feliz.2.8.0/Interop.fs","../Feliz.2.8.0/Html.fs","../Feliz.Bulma.3.0.0/Bulma.fs","../Feliz.Bulma.3.0.0/PropertyBuilders.fs","../Feliz.Bulma.3.0.0/Modifiers.fs"],"names":["listOfElementValues","formConfig","values","filledElements","buildElement","index","newElementValues","elementValues","result","matchValue","next","head","errors","current","output","x","isEmpty","element","state","tagger","form","elems","children","add","_arg1","addButton","delete","removeButton","innerField","_","formList","formListItem","fieldConfig","field","_arg3","deleteLabel","filledField","addLabel","\u0060\u0060.ctor\u0060\u0060","update","fieldId","attributes","label"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;WAkEQ;AACQA,\u002BDAAsB,AAAAC,iBAAiBC;AAgBvCC,wEAAiB,oIAbjB,AAAAC,aACI,kCACoB,CAAA,AAAAH,gCAAgC,qBAAaI,QAMrDA,sEADA,AAAAJ,kBAFc,0BAAWI,OAAMC,kBAAiBN,sBAEtBE,WAEzBA,QACOK,iBAGmBP;AA8B3CQ,8GAAS;AAVHC,0GAAA,AAAAC;AAAA,gBAAA,AAAAD;AAGEE,4CACE,AAAAF;AADIG,0DACJ,AAAAH;AAAA,oBAAA,AAAAI;iHAIIF,MAAM,OAAAC,QAAU,KAAtB,AAAAC,sBAAA,AAAAA;;;iHAHYF,MAAMC;;;;AAJrBE,uCAAU,AAAAL;AAAA,uBAAA,8IAAqB,K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B,AAAAhB,wBACU,AAAAmB,OAAQ,AAAAnB,kBAGlC,AAAAS,mCACO,AAAAU,OAAQ,AAAAV,qBACV,AAAAA;;;;;;;;;;;;;;;;;;;;;;WA6C7B,8BACcW,SACF,IACF,WACG;;;;WAIb,8BAAA,AAAAC,oBACYC,OADZ,AAAAD,gBAAA,AAAAA;;;;WAKA,8BAAA,AAAAA,oBAAA,AAAAA,kBACelB,KADf,AAAAkB;;;;WAKA,8BAAA,AAAAA,oBAAA,AAAAA,kBAAA,AAAAA,gBACkBf","file":null,"sourcesContent":null,"sourceRoot":null}
@@ -1,52 +0,0 @@
1
- namespace Fable.Form.Simple.Bulma.Fields
2
-
3
- open Feliz
4
- open Feliz.Bulma
5
- open Fable.Form.Simple
6
- open Fable.Form.Simple.Bulma
7
-
8
- module Group =
9
-
10
- type Field<'Values>(fields: FilledField<'Values> list) =
11
-
12
- inherit IGenericField<'Values>()
13
-
14
- interface IField<'Values> with
15
-
16
- member _.MapFieldValues(update: 'Values -> 'NewValues) : IField<'NewValues> =
17
-
18
- fields
19
- |> List.map (fun filledField ->
20
- {
21
- State = filledField.State.MapFieldValues update
22
- Error = filledField.Error
23
- IsDisabled = filledField.IsDisabled
24
- IsReadOnly = filledField.IsReadOnly
25
- }
26
- : FilledField<'NewValues>
27
- )
28
- |> Field
29
- :> IField<'NewValues>
30
-
31
- override _.RenderField
32
- (fieldConfig: Form.View.FieldConfig<'Values, 'Msg>)
33
- (_filledField: FilledField<'Values>)
34
- =
35
-
36
- let renderedFields =
37
- fields
38
- |> List.map (fun field ->
39
- let f1 = Html.View.ignoreChildError field.Error field
40
-
41
- Html.View.renderField
42
- { fieldConfig with
43
- Disabled = field.IsDisabled || fieldConfig.Disabled
44
- }
45
- f1
46
- )
47
-
48
- Bulma.field.div [
49
- Bulma.columns [
50
- renderedFields |> List.map Bulma.column |> prop.children
51
- ]
52
- ]
@@ -1 +0,0 @@
1
- {"version":3,"sources":["./Group.fs","../Feliz.2.8.0/Properties.fs","../Feliz.Bulma.3.0.0/ElementBuilders.fs","../Feliz.2.8.0/Interop.fs","../Feliz.2.8.0/Html.fs","../Feliz.Bulma.3.0.0/Bulma.fs"],"names":["fields","elems","_","children","i","fieldConfig","field","\u0060\u0060.ctor\u0060\u0060","filledField","update"],"mappings":";;;;;;;;;;;;;;;;;AASwB,sBAAAA;;;YCwaWC;ADnZlBC,mCAAAA;AEDoBC,oDCpB\u002BB,mBCuLZ,iBFpKc,uBGiNH,WL7LrC,WCiYKF,UDhYG;AEpBDE,wDFoBUC;AGxCqB,mBAAA,mBCuLZ;2BCqDW;0BJ4LkC,qCCpZUD;;WFQ5F,6GAGC,qCACI,kBAAA,AAAAE,sBAAA,AAAAA,oBACe,AAAAC,mBAAA,OAAoB,AAAAD,sBADnC,AAAAA,wBAAA,AAAAA,wBAHK,yBAA2B,AAAAC,aAAYA,SAFpD,AAAAJ,aC6YyE,YAAY,qCAA\u002BCD;AExahF,eAAA,mBCuLZ;uBC4bkC;sBJ3MW,qCCpZUE;;;;AFd5FD,mCAAAA;AAYA,eAAA,AAAAK,2BATA,sJACC,kBACY,AAAAC,qCAAiCC,SACjC,AAAAD,mBACK,AAAAA,wBACA,AAAAA,0BANrB,AAAAN","file":null,"sourcesContent":null,"sourceRoot":null}
@@ -1,246 +0,0 @@
1
- namespace Fable.Form.Simple.Bulma.Html
2
-
3
- open Feliz
4
- open Feliz.Bulma
5
- open Fable.Form
6
- open Fable.Form.Simple
7
- open Fable.Form.Simple.Form.View
8
- open Fable.Form.Simple.Bulma
9
-
10
- module View =
11
-
12
- let fieldLabel (label: string) =
13
- Bulma.label [
14
- prop.text label
15
- ]
16
-
17
- let errorMessage (message: string) =
18
- Bulma.help [
19
- color.isDanger
20
- prop.text message
21
- ]
22
-
23
- let errorMessageAsHtml (showError: bool) (error: Error.Error option) =
24
- match error with
25
- | Some(Error.External externalError) -> errorMessage externalError
26
-
27
- | _ ->
28
- if showError then
29
- error
30
- |> Option.map errorToString
31
- |> Option.map errorMessage
32
- |> Option.defaultValue (Bulma.help [])
33
-
34
- else
35
- Bulma.help []
36
-
37
- let wrapInFieldContainer (children: ReactElement list) =
38
- Bulma.field.div [
39
- prop.children children
40
- ]
41
-
42
- let withLabelAndError
43
- (label: string)
44
- (showError: bool)
45
- (error: Error.Error option)
46
- (fieldAsHtml: ReactElement)
47
- : ReactElement
48
- =
49
- [
50
- fieldLabel label
51
- Bulma.control.div [
52
- fieldAsHtml
53
- ]
54
- errorMessageAsHtml showError error
55
- ]
56
- |> wrapInFieldContainer
57
-
58
- let form
59
- ({
60
- OnSubmit = onSubmit
61
- State = state
62
- Action = action
63
- Fields = fields
64
- }: FormConfig<'Output, ReactElement>)
65
- =
66
-
67
- Html.form [
68
- prop.onSubmit (fun ev ->
69
- ev.stopPropagation ()
70
- ev.preventDefault ()
71
-
72
- match onSubmit with
73
- | None -> ()
74
- | Some(OnSubmit onSubmit) -> onSubmit ()
75
- )
76
-
77
- prop.children [
78
- yield! fields
79
-
80
- match state with
81
- | Error error -> errorMessage error
82
-
83
- | Success success ->
84
- Bulma.field.div [
85
- Bulma.control.div [
86
- text.hasTextCentered
87
- color.hasTextSuccess
88
- text.hasTextWeightBold
89
-
90
- prop.text success
91
- ]
92
- ]
93
-
94
- | Loading
95
- | ReadOnly
96
- | Idle -> Html.none
97
-
98
- match action with
99
- | Action.SubmitOnly submitLabel ->
100
- Bulma.field.div [
101
- field.isGrouped
102
- field.isGroupedRight
103
-
104
- prop.children [
105
- Bulma.control.div [
106
- Bulma.button.button [
107
- prop.type'.submit
108
- color.isPrimary
109
- prop.text submitLabel
110
- // If the form is loading animate the submit button with the loading animation
111
- if state = Loading then
112
- button.isLoading
113
- ]
114
- ]
115
-
116
- ]
117
- ]
118
-
119
- | Action.Custom func -> func state
120
- ]
121
- ]
122
-
123
- let rec renderField<'Value, 'Attributes, 'Values when 'Attributes :> Field.IAttributes>
124
- (fieldConfig: Form.View.FieldConfig<'Values, 'Value>)
125
- (field: FilledField<'Values>)
126
- : ReactElement
127
- =
128
-
129
- (***
130
-
131
- It would be cleaner to use a match expression here.
132
-
133
- ```fsharp
134
- match field.State with
135
- | :? IRendererField as rendererField ->
136
- ```
137
-
138
- However, by not using a match expression we make it easier to use TypeScript for creating fields.
139
-
140
- ```typescript
141
- export function renderField(dispatch, fieldConfig, field) {
142
- let f1, copyOfStruct_1, value;
143
- const matchValue = field.State;
144
- if (matchValue instanceof IRendererField) {
145
- const rendererField = matchValue;
146
- const matchValue_1 = IRendererField__get_FieldRendererType(rendererField);
147
- if (matchValue_1.tag === 1) {
148
- // This is generic field
149
- }
150
- else {
151
- // This is standard field
152
- }
153
- }
154
- else {
155
- // This is an invalid field
156
- }
157
- }
158
- ```
159
-
160
- This is because, the match with test the instance of the object, which means that we
161
- need to expose the domain to TypeScript (not easy to do, and outside of what I would
162
- like to maintain).
163
-
164
- However, by using a dynamic cast we by pass that and only work based on the shape of the object.
165
-
166
- ```typescript
167
- export function renderField(dispatch, fieldConfig, field) {
168
- let value, f1, copyOfStruct_1;
169
- try {
170
- const rendererField = field.State;
171
- const matchValue = IRendererField__get_FieldRendererType(rendererField);
172
- if (matchValue.tag === 1) {
173
- // This is generic field
174
- }
175
- else {
176
- // This is standard field
177
- }
178
- }
179
- catch (matchValue_1) {
180
- // This is an invalid field
181
- }
182
- }
183
- ```
184
-
185
- See how, we don't have a test against the instance of the object.
186
-
187
- This means we could create an NPM package, to share the shape of the domain and then use that in TypeScript.
188
- *)
189
-
190
- try
191
- let rendererField = field.State :?> IRendererField
192
-
193
- match rendererField.FieldRendererType with
194
- | FieldRendererType.Standard ->
195
-
196
- let standardField = field.State :?> IStandardField<'Values, 'Value, 'Attributes>
197
-
198
- let attributes = standardField.InnerField.Attributes
199
-
200
- let config =
201
- {
202
- OnChange = standardField.InnerField.Update >> fieldConfig.OnChange
203
- OnBlur =
204
- fieldConfig.OnBlur
205
- |> Option.map (fun onBlurEvent ->
206
- fun () -> onBlurEvent (attributes.GetFieldId())
207
- )
208
- Disabled = field.IsDisabled || fieldConfig.Disabled
209
- IsReadOnly = field.IsReadOnly || fieldConfig.IsReadOnly
210
- Value = standardField.InnerField.Value
211
- Error = field.Error
212
- ShowError = fieldConfig.ShowError(attributes.GetFieldId())
213
- Attributes = attributes
214
- }
215
-
216
- standardField.RenderField config
217
-
218
- | FieldRendererType.Generic ->
219
- let genericField = field.State :?> IGenericField<'Values>
220
-
221
- genericField.RenderField fieldConfig field
222
-
223
- with error ->
224
- Fable.Core.JS.console.error error
225
- #if DEBUG
226
- Html.div [
227
- prop.text
228
- "Field not implemented, please implement the field `IStandardField<'Values>` or `IGenericField<'Values>`"
229
- ]
230
- #else
231
- Html.none
232
- #endif
233
-
234
- let ignoreChildError
235
- (parentError: Error.Error option)
236
- (field: FilledField<'Values>)
237
- : FilledField<'Values>
238
- =
239
-
240
- match parentError with
241
- | Some _ -> field
242
-
243
- | None ->
244
- { field with
245
- Error = None
246
- }
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../Feliz.2.8.0/Interop.fs","../Feliz.2.8.0/Html.fs","../Feliz.Bulma.3.0.0/ElementBuilders.fs","../Feliz.Bulma.3.0.0/Bulma.fs","./Html.View.fs","../Feliz.2.8.0/Properties.fs","../Feliz.Bulma.3.0.0/PropertyBuilders.fs","../Feliz.Bulma.3.0.0/Modifiers.fs"],"names":["label","message","externalError","error","errorMessage","showError","elems","children","wrapInFieldContainer","fieldLabel","fieldAsHtml","errorMessageAsHtml","state","_arg1","onSubmit","ev","matchValue","submitLabel","copyOfStruct","field","genericField","fieldConfig","standardField","attributes","config","onBlurEvent","parentError"],"mappings":";;;;;;;;;;;;;;;;;WASoE,mBC0aV,mBC5Xc,uBCkML,SC7O/C,WC2uD2C,YD1uDzCA;;;;WJJ8C,mBCmhBd,eCpYc,uBCoVN,QC3d3C,UEbgC,aCgrCU,gCFmkBE,YDpuDzCC;;;;4BAKQC;AADhB,QAAA,AAAAC;AAAA,YAAA,SACJA;;AAAoBD,4BADhB,UACJC;;;;;;;;;;;A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