@dwidge/json-forms-expo 0.0.2 → 0.0.3

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 (408) hide show
  1. package/dist/cjs/{FileAttachment → Attachment}/AttachmentEdit.js +3 -2
  2. package/dist/cjs/Attachment/AttachmentEdit.js.map +1 -0
  3. package/dist/cjs/Attachment/AttachmentListEdit.js +21 -0
  4. package/dist/cjs/Attachment/AttachmentListEdit.js.map +1 -0
  5. package/dist/cjs/{FileAttachment → Attachment}/AttachmentListView.js +2 -2
  6. package/dist/cjs/Attachment/AttachmentListView.js.map +1 -0
  7. package/dist/cjs/Attachment/AttachmentScreen.js.map +1 -0
  8. package/dist/cjs/{FileAttachment → Attachment}/AttachmentView.js +3 -2
  9. package/dist/cjs/Attachment/AttachmentView.js.map +1 -0
  10. package/dist/cjs/{FileAttachment → Attachment}/index.js +7 -7
  11. package/dist/cjs/Attachment/index.js.map +1 -0
  12. package/dist/cjs/{FileAttachment → Attachment}/useFileAttachmentUrl.js +3 -2
  13. package/dist/cjs/Attachment/useFileAttachmentUrl.js.map +1 -0
  14. package/dist/cjs/{FileAttachment → Attachment}/useFileUrl.js +2 -1
  15. package/dist/cjs/Attachment/useFileUrl.js.map +1 -0
  16. package/dist/cjs/Form/FormEdit.js +22 -3
  17. package/dist/cjs/Form/FormEdit.js.map +1 -1
  18. package/dist/cjs/Form/FormEditScreen.js +4 -17
  19. package/dist/cjs/Form/FormEditScreen.js.map +1 -1
  20. package/dist/cjs/Form/FormListEdit.js +9 -4
  21. package/dist/cjs/Form/FormListEdit.js.map +1 -1
  22. package/dist/cjs/Form/FormListScreen.js +9 -6
  23. package/dist/cjs/Form/FormListScreen.js.map +1 -1
  24. package/dist/cjs/Form/FormListView.js +5 -2
  25. package/dist/cjs/Form/FormListView.js.map +1 -1
  26. package/dist/cjs/Form/FormView.js +5 -1
  27. package/dist/cjs/Form/FormView.js.map +1 -1
  28. package/dist/cjs/Form/index.js +6 -9
  29. package/dist/cjs/Form/index.js.map +1 -1
  30. package/dist/cjs/{Form/EditFormAttachmentScreen.js → Schema/EditSchemaScreen.js} +4 -4
  31. package/dist/cjs/Schema/EditSchemaScreen.js.map +1 -0
  32. package/dist/cjs/Schema/SchemaEdit.js +12 -0
  33. package/dist/cjs/Schema/SchemaEdit.js.map +1 -0
  34. package/dist/cjs/Schema/SchemaEditScreen.js +30 -0
  35. package/dist/cjs/Schema/SchemaEditScreen.js.map +1 -0
  36. package/dist/cjs/Schema/SchemaListEdit.js +22 -0
  37. package/dist/cjs/Schema/SchemaListEdit.js.map +1 -0
  38. package/dist/cjs/Schema/SchemaListScreen.js +28 -0
  39. package/dist/cjs/Schema/SchemaListScreen.js.map +1 -0
  40. package/dist/cjs/Schema/SchemaListView.js +18 -0
  41. package/dist/cjs/Schema/SchemaListView.js.map +1 -0
  42. package/dist/cjs/Schema/SchemaSelectScreen.js +21 -0
  43. package/dist/cjs/Schema/SchemaSelectScreen.js.map +1 -0
  44. package/dist/cjs/Schema/SchemaSelectView.js +16 -0
  45. package/dist/cjs/Schema/SchemaSelectView.js.map +1 -0
  46. package/dist/cjs/Schema/SchemaView.js +12 -0
  47. package/dist/cjs/Schema/SchemaView.js.map +1 -0
  48. package/dist/cjs/{FormAttachment → Schema}/index.js +9 -6
  49. package/dist/cjs/Schema/index.js.map +1 -0
  50. package/dist/cjs/hooks/{FileAttachmentApi.js → AttachmentApi.js} +4 -4
  51. package/dist/cjs/hooks/AttachmentApi.js.map +1 -0
  52. package/dist/cjs/hooks/FileApi.js +1 -1
  53. package/dist/cjs/hooks/FileApi.js.map +1 -1
  54. package/dist/cjs/hooks/FormApi.js +3 -4
  55. package/dist/cjs/hooks/FormApi.js.map +1 -1
  56. package/dist/cjs/hooks/FormsContext.js +4 -4
  57. package/dist/cjs/hooks/FormsContext.js.map +1 -1
  58. package/dist/cjs/hooks/{FormAttachmentApi.js → SchemaApi.js} +6 -5
  59. package/dist/cjs/hooks/SchemaApi.js.map +1 -0
  60. package/dist/cjs/hooks/createApi.js +11 -12
  61. package/dist/cjs/hooks/createApi.js.map +1 -1
  62. package/dist/cjs/hooks/index.js +11 -10
  63. package/dist/cjs/hooks/index.js.map +1 -1
  64. package/dist/cjs/hooks/useCreateBlankAttachment.js +2 -2
  65. package/dist/cjs/hooks/useCreateBlankAttachment.js.map +1 -1
  66. package/dist/cjs/hooks/useCreateBlankForm.js +5 -3
  67. package/dist/cjs/hooks/useCreateBlankForm.js.map +1 -1
  68. package/dist/cjs/hooks/useCreateBlankSchema.js +12 -0
  69. package/dist/cjs/hooks/useCreateBlankSchema.js.map +1 -0
  70. package/dist/cjs/hooks/useIdFilter.js +6 -0
  71. package/dist/cjs/hooks/useIdFilter.js.map +1 -0
  72. package/dist/cjs/index.js +5 -5
  73. package/dist/cjs/index.js.map +1 -1
  74. package/dist/cjs/types/{FileAttachment.js → File1.js} +1 -1
  75. package/dist/cjs/types/File1.js.map +1 -0
  76. package/dist/cjs/types/{FormAttachment.js → Schema1.js} +1 -1
  77. package/dist/cjs/types/Schema1.js.map +1 -0
  78. package/dist/cjs/types/index.js +4 -4
  79. package/dist/cjs/types/index.js.map +1 -1
  80. package/dist/esm/{FileAttachment → Attachment}/AttachmentEdit.js +3 -2
  81. package/dist/esm/Attachment/AttachmentEdit.js.map +1 -0
  82. package/dist/esm/Attachment/AttachmentListEdit.js +14 -0
  83. package/dist/esm/Attachment/AttachmentListEdit.js.map +1 -0
  84. package/dist/esm/{FileAttachment → Attachment}/AttachmentListView.js +2 -2
  85. package/dist/esm/Attachment/AttachmentListView.js.map +1 -0
  86. package/dist/esm/Attachment/AttachmentScreen.js.map +1 -0
  87. package/dist/esm/{FileAttachment → Attachment}/AttachmentView.js +3 -2
  88. package/dist/esm/Attachment/AttachmentView.js.map +1 -0
  89. package/dist/esm/Attachment/index.js +8 -0
  90. package/dist/esm/Attachment/index.js.map +1 -0
  91. package/dist/esm/{FileAttachment → Attachment}/useFileAttachmentUrl.js +3 -2
  92. package/dist/esm/Attachment/useFileAttachmentUrl.js.map +1 -0
  93. package/dist/esm/{FileAttachment → Attachment}/useFileUrl.js +2 -1
  94. package/dist/esm/Attachment/useFileUrl.js.map +1 -0
  95. package/dist/esm/Form/FormEdit.js +22 -3
  96. package/dist/esm/Form/FormEdit.js.map +1 -1
  97. package/dist/esm/Form/FormEditScreen.js +5 -18
  98. package/dist/esm/Form/FormEditScreen.js.map +1 -1
  99. package/dist/esm/Form/FormListEdit.js +10 -5
  100. package/dist/esm/Form/FormListEdit.js.map +1 -1
  101. package/dist/esm/Form/FormListScreen.js +10 -7
  102. package/dist/esm/Form/FormListScreen.js.map +1 -1
  103. package/dist/esm/Form/FormListView.js +5 -2
  104. package/dist/esm/Form/FormListView.js.map +1 -1
  105. package/dist/esm/Form/FormView.js +7 -3
  106. package/dist/esm/Form/FormView.js.map +1 -1
  107. package/dist/esm/Form/index.js +6 -9
  108. package/dist/esm/Form/index.js.map +1 -1
  109. package/dist/esm/{Form/EditFormAttachmentScreen.js → Schema/EditSchemaScreen.js} +2 -2
  110. package/dist/esm/Schema/EditSchemaScreen.js.map +1 -0
  111. package/dist/esm/Schema/SchemaEdit.js +8 -0
  112. package/dist/esm/Schema/SchemaEdit.js.map +1 -0
  113. package/dist/esm/Schema/SchemaEditScreen.js +26 -0
  114. package/dist/esm/Schema/SchemaEditScreen.js.map +1 -0
  115. package/dist/esm/Schema/SchemaListEdit.js +15 -0
  116. package/dist/esm/Schema/SchemaListEdit.js.map +1 -0
  117. package/dist/esm/Schema/SchemaListScreen.js +24 -0
  118. package/dist/esm/Schema/SchemaListScreen.js.map +1 -0
  119. package/dist/esm/Schema/SchemaListView.js +11 -0
  120. package/dist/esm/Schema/SchemaListView.js.map +1 -0
  121. package/dist/esm/Schema/SchemaSelectScreen.js +17 -0
  122. package/dist/esm/Schema/SchemaSelectScreen.js.map +1 -0
  123. package/dist/esm/Schema/SchemaSelectView.js +12 -0
  124. package/dist/esm/Schema/SchemaSelectView.js.map +1 -0
  125. package/dist/esm/Schema/SchemaView.js +8 -0
  126. package/dist/esm/Schema/SchemaView.js.map +1 -0
  127. package/dist/esm/Schema/index.js +10 -0
  128. package/dist/esm/Schema/index.js.map +1 -0
  129. package/dist/esm/hooks/{FileAttachmentApi.js → AttachmentApi.js} +3 -3
  130. package/dist/esm/hooks/AttachmentApi.js.map +1 -0
  131. package/dist/esm/hooks/FileApi.js +1 -1
  132. package/dist/esm/hooks/FileApi.js.map +1 -1
  133. package/dist/esm/hooks/FormApi.js +3 -4
  134. package/dist/esm/hooks/FormApi.js.map +1 -1
  135. package/dist/esm/hooks/FormsContext.js +4 -4
  136. package/dist/esm/hooks/FormsContext.js.map +1 -1
  137. package/dist/esm/hooks/SchemaApi.js +10 -0
  138. package/dist/esm/hooks/SchemaApi.js.map +1 -0
  139. package/dist/esm/hooks/createApi.js +11 -12
  140. package/dist/esm/hooks/createApi.js.map +1 -1
  141. package/dist/esm/hooks/index.js +11 -10
  142. package/dist/esm/hooks/index.js.map +1 -1
  143. package/dist/esm/hooks/useCreateBlankAttachment.js +2 -2
  144. package/dist/esm/hooks/useCreateBlankAttachment.js.map +1 -1
  145. package/dist/esm/hooks/useCreateBlankForm.js +5 -3
  146. package/dist/esm/hooks/useCreateBlankForm.js.map +1 -1
  147. package/dist/esm/hooks/useCreateBlankSchema.js +8 -0
  148. package/dist/esm/hooks/useCreateBlankSchema.js.map +1 -0
  149. package/dist/esm/hooks/useIdFilter.js +2 -0
  150. package/dist/esm/hooks/useIdFilter.js.map +1 -0
  151. package/dist/esm/index.js +5 -5
  152. package/dist/esm/index.js.map +1 -1
  153. package/dist/esm/types/File1.js +2 -0
  154. package/dist/esm/types/File1.js.map +1 -0
  155. package/dist/esm/types/Schema1.js +2 -0
  156. package/dist/esm/types/Schema1.js.map +1 -0
  157. package/dist/esm/types/index.js +4 -4
  158. package/dist/esm/types/index.js.map +1 -1
  159. package/dist/tsconfig.cjs.tsbuildinfo +1 -1
  160. package/dist/tsconfig.tsbuildinfo +1 -1
  161. package/dist/types/Attachment/AttachmentEdit.d.ts +6 -0
  162. package/dist/types/Attachment/AttachmentEdit.d.ts.map +1 -0
  163. package/dist/types/{FileAttachment → Attachment}/AttachmentListEdit.d.ts +3 -3
  164. package/dist/types/Attachment/AttachmentListEdit.d.ts.map +1 -0
  165. package/dist/types/{FileAttachment → Attachment}/AttachmentListView.d.ts +2 -2
  166. package/dist/types/Attachment/AttachmentListView.d.ts.map +1 -0
  167. package/dist/types/{FileAttachment → Attachment}/AttachmentScreen.d.ts +1 -1
  168. package/dist/types/Attachment/AttachmentScreen.d.ts.map +1 -0
  169. package/dist/types/Attachment/AttachmentView.d.ts +6 -0
  170. package/dist/types/Attachment/AttachmentView.d.ts.map +1 -0
  171. package/dist/types/Attachment/index.d.ts +8 -0
  172. package/dist/types/Attachment/index.d.ts.map +1 -0
  173. package/dist/types/Attachment/useFileAttachmentUrl.d.ts.map +1 -0
  174. package/dist/types/Attachment/useFileUrl.d.ts.map +1 -0
  175. package/dist/types/Form/FormEdit.d.ts +6 -2
  176. package/dist/types/Form/FormEdit.d.ts.map +1 -1
  177. package/dist/types/Form/FormEditScreen.d.ts +3 -2
  178. package/dist/types/Form/FormEditScreen.d.ts.map +1 -1
  179. package/dist/types/Form/FormListEdit.d.ts +7 -2
  180. package/dist/types/Form/FormListEdit.d.ts.map +1 -1
  181. package/dist/types/Form/FormListScreen.d.ts +4 -5
  182. package/dist/types/Form/FormListScreen.d.ts.map +1 -1
  183. package/dist/types/Form/FormListView.d.ts +3 -3
  184. package/dist/types/Form/FormListView.d.ts.map +1 -1
  185. package/dist/types/Form/FormView.d.ts +4 -3
  186. package/dist/types/Form/FormView.d.ts.map +1 -1
  187. package/dist/types/Form/index.d.ts +6 -9
  188. package/dist/types/Form/index.d.ts.map +1 -1
  189. package/dist/types/{Form/EditFormAttachmentScreen.d.ts → Schema/EditSchemaScreen.d.ts} +2 -2
  190. package/dist/types/Schema/EditSchemaScreen.d.ts.map +1 -0
  191. package/dist/types/Schema/SchemaEdit.d.ts +4 -0
  192. package/dist/types/Schema/SchemaEdit.d.ts.map +1 -0
  193. package/dist/types/Schema/SchemaEditScreen.d.ts +4 -0
  194. package/dist/types/Schema/SchemaEditScreen.d.ts.map +1 -0
  195. package/dist/types/Schema/SchemaListEdit.d.ts +6 -0
  196. package/dist/types/Schema/SchemaListEdit.d.ts.map +1 -0
  197. package/dist/types/Schema/SchemaListScreen.d.ts +8 -0
  198. package/dist/types/Schema/SchemaListScreen.d.ts.map +1 -0
  199. package/dist/types/Schema/SchemaListView.d.ts +5 -0
  200. package/dist/types/Schema/SchemaListView.d.ts.map +1 -0
  201. package/dist/types/Schema/SchemaSelectScreen.d.ts +6 -0
  202. package/dist/types/Schema/SchemaSelectScreen.d.ts.map +1 -0
  203. package/dist/types/Schema/SchemaSelectView.d.ts +8 -0
  204. package/dist/types/Schema/SchemaSelectView.d.ts.map +1 -0
  205. package/dist/types/Schema/SchemaView.d.ts +5 -0
  206. package/dist/types/Schema/SchemaView.d.ts.map +1 -0
  207. package/dist/types/Schema/index.d.ts +10 -0
  208. package/dist/types/Schema/index.d.ts.map +1 -0
  209. package/dist/types/hooks/AttachmentApi.d.ts +23 -0
  210. package/dist/types/hooks/AttachmentApi.d.ts.map +1 -0
  211. package/dist/types/hooks/FileApi.d.ts +7 -19
  212. package/dist/types/hooks/FileApi.d.ts.map +1 -1
  213. package/dist/types/hooks/FormApi.d.ts +7 -19
  214. package/dist/types/hooks/FormApi.d.ts.map +1 -1
  215. package/dist/types/hooks/FormsContext.d.ts +7 -7
  216. package/dist/types/hooks/SchemaApi.d.ts +23 -0
  217. package/dist/types/hooks/SchemaApi.d.ts.map +1 -0
  218. package/dist/types/hooks/createApi.d.ts +8 -20
  219. package/dist/types/hooks/createApi.d.ts.map +1 -1
  220. package/dist/types/hooks/index.d.ts +11 -10
  221. package/dist/types/hooks/index.d.ts.map +1 -1
  222. package/dist/types/hooks/useCreateBlankAttachment.d.ts +3 -3
  223. package/dist/types/hooks/useCreateBlankAttachment.d.ts.map +1 -1
  224. package/dist/types/hooks/useCreateBlankForm.d.ts +10 -3
  225. package/dist/types/hooks/useCreateBlankForm.d.ts.map +1 -1
  226. package/dist/types/hooks/useCreateBlankSchema.d.ts +6 -0
  227. package/dist/types/hooks/useCreateBlankSchema.d.ts.map +1 -0
  228. package/dist/types/hooks/useIdFilter.d.ts +4 -0
  229. package/dist/types/hooks/useIdFilter.d.ts.map +1 -0
  230. package/dist/types/hooks/useParams.d.ts +1 -1
  231. package/dist/types/hooks/useParams.d.ts.map +1 -1
  232. package/dist/types/index.d.ts +5 -5
  233. package/dist/types/index.d.ts.map +1 -1
  234. package/dist/types/types/{FileAttachment.d.ts → File1.d.ts} +3 -3
  235. package/dist/types/types/File1.d.ts.map +1 -0
  236. package/dist/types/types/Form1.d.ts +2 -3
  237. package/dist/types/types/Form1.d.ts.map +1 -1
  238. package/dist/types/types/Schema1.d.ts +14 -0
  239. package/dist/types/types/Schema1.d.ts.map +1 -0
  240. package/dist/types/types/index.d.ts +4 -4
  241. package/dist/types/types/index.d.ts.map +1 -1
  242. package/package.json +14 -14
  243. package/src/{FileAttachment → Attachment}/AttachmentEdit.tsx +4 -3
  244. package/src/{FileAttachment → Attachment}/AttachmentListEdit.tsx +3 -3
  245. package/src/{FileAttachment → Attachment}/AttachmentListView.tsx +2 -2
  246. package/src/{FileAttachment → Attachment}/AttachmentView.tsx +4 -3
  247. package/src/Attachment/index.ts +7 -0
  248. package/src/{FileAttachment → Attachment}/useFileAttachmentUrl.ts +4 -3
  249. package/src/{FileAttachment → Attachment}/useFileUrl.ts +2 -1
  250. package/src/Form/FormEdit.tsx +60 -7
  251. package/src/Form/FormEditScreen.tsx +10 -42
  252. package/src/Form/FormListEdit.tsx +22 -14
  253. package/src/Form/FormListScreen.tsx +24 -19
  254. package/src/Form/FormListView.tsx +13 -6
  255. package/src/Form/FormView.tsx +26 -11
  256. package/src/Form/index.ts +6 -9
  257. package/src/{Form/EditFormAttachmentScreen.tsx → Schema/EditSchemaScreen.tsx} +4 -4
  258. package/src/Schema/SchemaEdit.tsx +15 -0
  259. package/src/Schema/SchemaEditScreen.tsx +57 -0
  260. package/src/{FormAttachment/FormAttachmentListView.tsx → Schema/SchemaListEdit.tsx} +13 -11
  261. package/src/Schema/SchemaListScreen.tsx +54 -0
  262. package/src/Schema/SchemaListView.tsx +23 -0
  263. package/src/{Form/FormSelectScreen.tsx → Schema/SchemaSelectScreen.tsx} +12 -17
  264. package/src/{Form/FormSelectView.tsx → Schema/SchemaSelectView.tsx} +8 -8
  265. package/src/Schema/SchemaView.tsx +11 -0
  266. package/src/Schema/index.ts +9 -0
  267. package/src/hooks/{FileAttachmentApi.ts → AttachmentApi.ts} +3 -3
  268. package/src/hooks/FileApi.ts +1 -1
  269. package/src/hooks/FormApi.ts +3 -4
  270. package/src/hooks/FormsContext.ts +4 -4
  271. package/src/hooks/SchemaApi.ts +11 -0
  272. package/src/hooks/createApi.ts +22 -19
  273. package/src/hooks/index.ts +11 -10
  274. package/src/hooks/useCreateBlankAttachment.ts +2 -2
  275. package/src/hooks/useCreateBlankForm.ts +11 -3
  276. package/src/hooks/useCreateBlankSchema.ts +12 -0
  277. package/src/hooks/useIdFilter.ts +2 -0
  278. package/src/hooks/useParams.ts +1 -1
  279. package/src/index.ts +5 -5
  280. package/src/types/{FileAttachment.ts → File1.ts} +2 -2
  281. package/src/types/Form1.ts +2 -3
  282. package/src/types/Schema1.ts +17 -0
  283. package/src/types/index.ts +4 -4
  284. package/dist/cjs/FileAttachment/AttachmentEdit.js.map +0 -1
  285. package/dist/cjs/FileAttachment/AttachmentListEdit.js +0 -21
  286. package/dist/cjs/FileAttachment/AttachmentListEdit.js.map +0 -1
  287. package/dist/cjs/FileAttachment/AttachmentListView.js.map +0 -1
  288. package/dist/cjs/FileAttachment/AttachmentScreen.js.map +0 -1
  289. package/dist/cjs/FileAttachment/AttachmentView.js.map +0 -1
  290. package/dist/cjs/FileAttachment/index.js.map +0 -1
  291. package/dist/cjs/FileAttachment/useFileAttachmentUrl.js.map +0 -1
  292. package/dist/cjs/FileAttachment/useFileUrl.js.map +0 -1
  293. package/dist/cjs/Form/EditFormAttachmentScreen.js.map +0 -1
  294. package/dist/cjs/Form/FormSelectScreen.js +0 -21
  295. package/dist/cjs/Form/FormSelectScreen.js.map +0 -1
  296. package/dist/cjs/Form/FormSelectView.js +0 -16
  297. package/dist/cjs/Form/FormSelectView.js.map +0 -1
  298. package/dist/cjs/FormAttachment/FormAttachmentEdit.js +0 -30
  299. package/dist/cjs/FormAttachment/FormAttachmentEdit.js.map +0 -1
  300. package/dist/cjs/FormAttachment/FormAttachmentEditScreen.js +0 -15
  301. package/dist/cjs/FormAttachment/FormAttachmentEditScreen.js.map +0 -1
  302. package/dist/cjs/FormAttachment/FormAttachmentListEdit.js +0 -27
  303. package/dist/cjs/FormAttachment/FormAttachmentListEdit.js.map +0 -1
  304. package/dist/cjs/FormAttachment/FormAttachmentListScreen.js +0 -31
  305. package/dist/cjs/FormAttachment/FormAttachmentListScreen.js.map +0 -1
  306. package/dist/cjs/FormAttachment/FormAttachmentListView.js +0 -21
  307. package/dist/cjs/FormAttachment/FormAttachmentListView.js.map +0 -1
  308. package/dist/cjs/FormAttachment/FormAttachmentView.js +0 -15
  309. package/dist/cjs/FormAttachment/FormAttachmentView.js.map +0 -1
  310. package/dist/cjs/FormAttachment/index.js.map +0 -1
  311. package/dist/cjs/hooks/FileAttachmentApi.js.map +0 -1
  312. package/dist/cjs/hooks/FormAttachmentApi.js.map +0 -1
  313. package/dist/cjs/hooks/useCreateBlankFormAttachment.js +0 -14
  314. package/dist/cjs/hooks/useCreateBlankFormAttachment.js.map +0 -1
  315. package/dist/cjs/types/FileAttachment.js.map +0 -1
  316. package/dist/cjs/types/FormAttachment.js.map +0 -1
  317. package/dist/esm/FileAttachment/AttachmentEdit.js.map +0 -1
  318. package/dist/esm/FileAttachment/AttachmentListEdit.js +0 -14
  319. package/dist/esm/FileAttachment/AttachmentListEdit.js.map +0 -1
  320. package/dist/esm/FileAttachment/AttachmentListView.js.map +0 -1
  321. package/dist/esm/FileAttachment/AttachmentScreen.js.map +0 -1
  322. package/dist/esm/FileAttachment/AttachmentView.js.map +0 -1
  323. package/dist/esm/FileAttachment/index.js +0 -8
  324. package/dist/esm/FileAttachment/index.js.map +0 -1
  325. package/dist/esm/FileAttachment/useFileAttachmentUrl.js.map +0 -1
  326. package/dist/esm/FileAttachment/useFileUrl.js.map +0 -1
  327. package/dist/esm/Form/EditFormAttachmentScreen.js.map +0 -1
  328. package/dist/esm/Form/FormSelectScreen.js +0 -17
  329. package/dist/esm/Form/FormSelectScreen.js.map +0 -1
  330. package/dist/esm/Form/FormSelectView.js +0 -12
  331. package/dist/esm/Form/FormSelectView.js.map +0 -1
  332. package/dist/esm/FormAttachment/FormAttachmentEdit.js +0 -26
  333. package/dist/esm/FormAttachment/FormAttachmentEdit.js.map +0 -1
  334. package/dist/esm/FormAttachment/FormAttachmentEditScreen.js +0 -11
  335. package/dist/esm/FormAttachment/FormAttachmentEditScreen.js.map +0 -1
  336. package/dist/esm/FormAttachment/FormAttachmentListEdit.js +0 -20
  337. package/dist/esm/FormAttachment/FormAttachmentListEdit.js.map +0 -1
  338. package/dist/esm/FormAttachment/FormAttachmentListScreen.js +0 -27
  339. package/dist/esm/FormAttachment/FormAttachmentListScreen.js.map +0 -1
  340. package/dist/esm/FormAttachment/FormAttachmentListView.js +0 -14
  341. package/dist/esm/FormAttachment/FormAttachmentListView.js.map +0 -1
  342. package/dist/esm/FormAttachment/FormAttachmentView.js +0 -11
  343. package/dist/esm/FormAttachment/FormAttachmentView.js.map +0 -1
  344. package/dist/esm/FormAttachment/index.js +0 -7
  345. package/dist/esm/FormAttachment/index.js.map +0 -1
  346. package/dist/esm/hooks/FileAttachmentApi.js.map +0 -1
  347. package/dist/esm/hooks/FormAttachmentApi.js +0 -9
  348. package/dist/esm/hooks/FormAttachmentApi.js.map +0 -1
  349. package/dist/esm/hooks/useCreateBlankFormAttachment.js +0 -10
  350. package/dist/esm/hooks/useCreateBlankFormAttachment.js.map +0 -1
  351. package/dist/esm/types/FileAttachment.js +0 -2
  352. package/dist/esm/types/FileAttachment.js.map +0 -1
  353. package/dist/esm/types/FormAttachment.js +0 -2
  354. package/dist/esm/types/FormAttachment.js.map +0 -1
  355. package/dist/types/FileAttachment/AttachmentEdit.d.ts +0 -6
  356. package/dist/types/FileAttachment/AttachmentEdit.d.ts.map +0 -1
  357. package/dist/types/FileAttachment/AttachmentListEdit.d.ts.map +0 -1
  358. package/dist/types/FileAttachment/AttachmentListView.d.ts.map +0 -1
  359. package/dist/types/FileAttachment/AttachmentScreen.d.ts.map +0 -1
  360. package/dist/types/FileAttachment/AttachmentView.d.ts +0 -6
  361. package/dist/types/FileAttachment/AttachmentView.d.ts.map +0 -1
  362. package/dist/types/FileAttachment/index.d.ts +0 -8
  363. package/dist/types/FileAttachment/index.d.ts.map +0 -1
  364. package/dist/types/FileAttachment/useFileAttachmentUrl.d.ts.map +0 -1
  365. package/dist/types/FileAttachment/useFileUrl.d.ts.map +0 -1
  366. package/dist/types/Form/EditFormAttachmentScreen.d.ts.map +0 -1
  367. package/dist/types/Form/FormSelectScreen.d.ts +0 -6
  368. package/dist/types/Form/FormSelectScreen.d.ts.map +0 -1
  369. package/dist/types/Form/FormSelectView.d.ts +0 -8
  370. package/dist/types/Form/FormSelectView.d.ts.map +0 -1
  371. package/dist/types/FormAttachment/FormAttachmentEdit.d.ts +0 -9
  372. package/dist/types/FormAttachment/FormAttachmentEdit.d.ts.map +0 -1
  373. package/dist/types/FormAttachment/FormAttachmentEditScreen.d.ts +0 -5
  374. package/dist/types/FormAttachment/FormAttachmentEditScreen.d.ts.map +0 -1
  375. package/dist/types/FormAttachment/FormAttachmentListEdit.d.ts +0 -11
  376. package/dist/types/FormAttachment/FormAttachmentListEdit.d.ts.map +0 -1
  377. package/dist/types/FormAttachment/FormAttachmentListScreen.d.ts +0 -7
  378. package/dist/types/FormAttachment/FormAttachmentListScreen.d.ts.map +0 -1
  379. package/dist/types/FormAttachment/FormAttachmentListView.d.ts +0 -5
  380. package/dist/types/FormAttachment/FormAttachmentListView.d.ts.map +0 -1
  381. package/dist/types/FormAttachment/FormAttachmentView.d.ts +0 -6
  382. package/dist/types/FormAttachment/FormAttachmentView.d.ts.map +0 -1
  383. package/dist/types/FormAttachment/index.d.ts +0 -7
  384. package/dist/types/FormAttachment/index.d.ts.map +0 -1
  385. package/dist/types/hooks/FileAttachmentApi.d.ts +0 -35
  386. package/dist/types/hooks/FileAttachmentApi.d.ts.map +0 -1
  387. package/dist/types/hooks/FormAttachmentApi.d.ts +0 -35
  388. package/dist/types/hooks/FormAttachmentApi.d.ts.map +0 -1
  389. package/dist/types/hooks/useCreateBlankFormAttachment.d.ts +0 -13
  390. package/dist/types/hooks/useCreateBlankFormAttachment.d.ts.map +0 -1
  391. package/dist/types/types/FileAttachment.d.ts.map +0 -1
  392. package/dist/types/types/FormAttachment.d.ts +0 -13
  393. package/dist/types/types/FormAttachment.d.ts.map +0 -1
  394. package/src/FileAttachment/index.ts +0 -7
  395. package/src/FormAttachment/FormAttachmentEdit.tsx +0 -72
  396. package/src/FormAttachment/FormAttachmentEditScreen.tsx +0 -21
  397. package/src/FormAttachment/FormAttachmentListEdit.tsx +0 -40
  398. package/src/FormAttachment/FormAttachmentListScreen.tsx +0 -62
  399. package/src/FormAttachment/FormAttachmentView.tsx +0 -25
  400. package/src/FormAttachment/index.ts +0 -6
  401. package/src/hooks/FormAttachmentApi.ts +0 -10
  402. package/src/hooks/useCreateBlankFormAttachment.ts +0 -20
  403. package/src/types/FormAttachment.ts +0 -19
  404. /package/dist/cjs/{FileAttachment → Attachment}/AttachmentScreen.js +0 -0
  405. /package/dist/esm/{FileAttachment → Attachment}/AttachmentScreen.js +0 -0
  406. /package/dist/types/{FileAttachment → Attachment}/useFileAttachmentUrl.d.ts +0 -0
  407. /package/dist/types/{FileAttachment → Attachment}/useFileUrl.d.ts +0 -0
  408. /package/src/{FileAttachment → Attachment}/AttachmentScreen.tsx +0 -0
@@ -1,40 +0,0 @@
1
- // Copyright DWJ 2024.
2
- // Distributed under the Boost Software License, Version 1.0.
3
- // https://www.boost.org/LICENSE_1_0.txt
4
-
5
- import { StyledView, UnstyledList, viewStyles } from "@dwidge/components-rnw";
6
- import { useNavAction2 } from "@dwidge/hooks-expo";
7
- import { useMemoState } from "@dwidge/hooks-react";
8
- import assert from "assert";
9
- import { useParams } from "../hooks";
10
- import { FormAttachmentApi } from "../hooks/FormAttachmentApi";
11
- import { useNavRoutes } from "../hooks/FormsContext";
12
- import { FormAttachmentView } from "./FormAttachmentView";
13
-
14
- export const FormAttachmentListEdit = ({
15
- ids = useParams(),
16
- elements = FormAttachmentApi.useGetList({
17
- id: undefined,
18
- data: undefined,
19
- ...ids,
20
- }),
21
- selection: [selection, setSelection] = useMemoState<string[]>([]),
22
- onPress = useNavAction2(
23
- useNavRoutes().FORM_ATTACHMENT_EDIT_SCREEN,
24
- async (id: string) => ({
25
- FormAttachmentId: id,
26
- }),
27
- ),
28
- }) => (
29
- <StyledView column>
30
- <UnstyledList
31
- items={elements}
32
- keyExtractor={(item) => (assert(item.id), item.id)}
33
- selection={[selection, setSelection]}
34
- render={(item) => <FormAttachmentView id={item.id} />}
35
- selectStyle={viewStyles.select}
36
- style={viewStyles.unselect}
37
- onPress={onPress}
38
- />
39
- </StyledView>
40
- );
@@ -1,62 +0,0 @@
1
- // Copyright DWJ 2024.
2
- // Distributed under the Boost Software License, Version 1.0.
3
- // https://www.boost.org/LICENSE_1_0.txt
4
-
5
- import { StyledHeader } from "@dwidge/components-expo";
6
- import {
7
- CenterView,
8
- ScreenView,
9
- ScrollView,
10
- StyledFontAwesome,
11
- } from "@dwidge/components-rnw";
12
- import { useNavAction2 } from "@dwidge/hooks-expo";
13
- import { useMemoState } from "@dwidge/hooks-react";
14
- import { TouchableOpacity } from "react-native";
15
- import { FormAttachmentApi } from "../hooks/FormAttachmentApi";
16
- import { useNavRoutes } from "../hooks/FormsContext";
17
- import { FormAttachmentListEdit } from "./FormAttachmentListEdit";
18
-
19
- export const FormAttachmentListScreen = ({
20
- onCreateAttachment = useNavAction2(
21
- useNavRoutes().FORM_SELECT_SCREEN,
22
- async () => ({}),
23
- ),
24
- onEditAttachment = useNavAction2(
25
- useNavRoutes().FORM_ATTACHMENT_EDIT_SCREEN,
26
- async (key: string) => ({
27
- FormAttachmentId: key,
28
- }),
29
- ),
30
- onDeleteAttachmentList = FormAttachmentApi.useDeleteList(),
31
- selection = useMemoState<string[]>([]),
32
- }) => (
33
- <ScreenView>
34
- <StyledHeader
35
- title="Manage Forms"
36
- actions={[
37
- {
38
- icon: "remove-circle",
39
- onPress:
40
- onDeleteAttachmentList && selection[0].length
41
- ? () => onDeleteAttachmentList(selection[0].map((id) => ({ id })))
42
- : undefined,
43
- },
44
- {
45
- icon: "add-circle",
46
- onPress: onCreateAttachment,
47
- },
48
- ]}
49
- />
50
- <ScrollView gap>
51
- <FormAttachmentListEdit
52
- selection={selection}
53
- onPress={onEditAttachment}
54
- />
55
- <TouchableOpacity style={{ flex: 1 }} onPress={onCreateAttachment}>
56
- <CenterView row gap>
57
- <StyledFontAwesome name="plus" size={30} />
58
- </CenterView>
59
- </TouchableOpacity>
60
- </ScrollView>
61
- </ScreenView>
62
- );
@@ -1,25 +0,0 @@
1
- // Copyright DWJ 2024.
2
- // Distributed under the Boost Software License, Version 1.0.
3
- // https://www.boost.org/LICENSE_1_0.txt
4
-
5
- import { StyledDate } from "@dwidge/components-expo";
6
- import { StyledLoader, StyledText, StyledView } from "@dwidge/components-rnw";
7
- import { FormApi } from "../hooks/FormApi";
8
- import { FormAttachmentApi } from "../hooks/FormAttachmentApi";
9
- import { useParams } from "../hooks/useParams";
10
-
11
- export const FormAttachmentView = ({
12
- id = useParams().FormAttachmentId,
13
- attachment: [attachment, setAttachment] = FormAttachmentApi.useItem(id),
14
- form = FormApi.useGetItem(attachment?.FormId),
15
- }) =>
16
- attachment && form ? (
17
- <StyledView space outline gap pad flex>
18
- <StyledText>{form.name || "untitled"}</StyledText>
19
- {attachment.createdAt && (
20
- <StyledDate>{attachment.createdAt * 1000}</StyledDate>
21
- )}
22
- </StyledView>
23
- ) : (
24
- <StyledLoader />
25
- );
@@ -1,6 +0,0 @@
1
- export * from "./FormAttachmentEdit";
2
- export * from "./FormAttachmentEditScreen";
3
- export * from "./FormAttachmentListEdit";
4
- export * from "./FormAttachmentListScreen";
5
- export * from "./FormAttachmentListView";
6
- export * from "./FormAttachmentView";
@@ -1,10 +0,0 @@
1
- import { FormAttachment1 } from "../types/FormAttachment.js";
2
- import { createApi } from "./createApi.js";
3
-
4
- export const FormAttachmentApi = createApi<FormAttachment1>({
5
- id: undefined,
6
- createdAt: undefined,
7
- createdBy: undefined,
8
- FormId: undefined,
9
- data: undefined,
10
- });
@@ -1,20 +0,0 @@
1
- // Copyright DWJ 2024.
2
- // Distributed under the Boost Software License, Version 1.0.
3
- // https://www.boost.org/LICENSE_1_0.txt
4
-
5
- import { Form1Key } from "../types/Form1";
6
- import { FormApi } from "./FormApi";
7
- import { FormAttachmentApi } from "./FormAttachmentApi";
8
- import { useParams } from "./useParams";
9
-
10
- export const useCreateBlankFormAttachment = ({
11
- createFormList = FormApi.useCreateList(),
12
- createAttachmentList = FormAttachmentApi.useCreateList(),
13
- AttachmentIds = useParams(),
14
- } = {}) =>
15
- createFormList && createAttachmentList
16
- ? async (forms: Form1Key[]) =>
17
- createAttachmentList(
18
- forms.map((form) => ({ ...AttachmentIds, FormId: form.id })),
19
- ).then(([r]) => ({ FormAttachmentId: r?.id }))
20
- : async () => undefined;
@@ -1,19 +0,0 @@
1
- export type FormAttachment1 = {
2
- id: string;
3
- created: boolean;
4
- createdAt: number;
5
- createdBy: number | null;
6
- FormId: string | null;
7
- data: string | null;
8
- };
9
-
10
- export type FormAttachment1Get = Partial<FormAttachment1>;
11
-
12
- export type FormAttachment1Set = Omit<
13
- FormAttachment1Get,
14
- "createdAt" | "createdBy"
15
- >;
16
-
17
- export type FormAttachment1Key = Pick<FormAttachment1Get, "id">;
18
-
19
- export type FormAttachment1Filter = FormAttachment1Get;