@manuscripts/article-editor 1.9.1 → 1.9.2

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 (421) hide show
  1. package/dist/cjs/src/components/Support.js +129 -0
  2. package/dist/cjs/src/components/Support.js.map +1 -0
  3. package/dist/cjs/src/components/inspector/ElementStyleInspector.js +14 -0
  4. package/dist/cjs/src/components/inspector/ElementStyleInspector.js.map +1 -0
  5. package/dist/cjs/src/components/inspector/StatisticsInspector.js +39 -0
  6. package/dist/cjs/src/components/inspector/StatisticsInspector.js.map +1 -0
  7. package/dist/cjs/src/components/library/CitationModel.js +210 -0
  8. package/dist/cjs/src/components/library/CitationModel.js.map +1 -0
  9. package/dist/cjs/src/components/library/CitationProperties.js +67 -0
  10. package/dist/cjs/src/components/library/CitationProperties.js.map +1 -0
  11. package/dist/cjs/src/components/library/ExternalSearch.js +156 -0
  12. package/dist/cjs/src/components/library/ExternalSearch.js.map +1 -0
  13. package/dist/cjs/src/components/library/GlobalLibrary.js +133 -0
  14. package/dist/cjs/src/components/library/GlobalLibrary.js.map +1 -0
  15. package/dist/cjs/src/components/library/LibraryCollectionCategories.js +53 -0
  16. package/dist/cjs/src/components/library/LibraryCollectionCategories.js.map +1 -0
  17. package/dist/cjs/src/components/library/LibraryForm.js +437 -0
  18. package/dist/cjs/src/components/library/LibraryForm.js.map +1 -0
  19. package/dist/cjs/src/components/library/LibraryItems.js +116 -0
  20. package/dist/cjs/src/components/library/LibraryItems.js.map +1 -0
  21. package/dist/cjs/src/components/library/LibraryPageContainer.js +107 -0
  22. package/dist/cjs/src/components/library/LibraryPageContainer.js.map +1 -0
  23. package/dist/cjs/src/components/library/LibrarySidebar.js +172 -0
  24. package/dist/cjs/src/components/library/LibrarySidebar.js.map +1 -0
  25. package/dist/cjs/src/components/library/Messages.js +25 -0
  26. package/dist/cjs/src/components/library/Messages.js.map +1 -0
  27. package/dist/cjs/src/components/library/ProjectLibrary.js +96 -0
  28. package/dist/cjs/src/components/library/ProjectLibrary.js.map +1 -0
  29. package/dist/cjs/src/components/menu/ApplicationMenus.js +79 -0
  30. package/dist/cjs/src/components/menu/ApplicationMenus.js.map +1 -0
  31. package/dist/cjs/src/components/metadata/HeaderFigure.js +147 -0
  32. package/dist/cjs/src/components/metadata/HeaderFigure.js.map +1 -0
  33. package/dist/cjs/src/components/metadata/Metadata.js +103 -0
  34. package/dist/cjs/src/components/metadata/Metadata.js.map +1 -0
  35. package/dist/cjs/src/components/metadata/MetadataContainer.js +203 -0
  36. package/dist/cjs/src/components/metadata/MetadataContainer.js.map +1 -0
  37. package/dist/cjs/src/components/metadata/TitleFieldContainer.js +56 -0
  38. package/dist/cjs/src/components/metadata/TitleFieldContainer.js.map +1 -0
  39. package/dist/cjs/src/components/projects/CategorisedKeywordsInput.js +439 -0
  40. package/dist/cjs/src/components/projects/CategorisedKeywordsInput.js.map +1 -0
  41. package/dist/cjs/src/components/projects/KeywordsInput.js +80 -0
  42. package/dist/cjs/src/components/projects/KeywordsInput.js.map +1 -0
  43. package/dist/cjs/src/components/projects/ListToolbarItemStyles.js +85 -0
  44. package/dist/cjs/src/components/projects/ListToolbarItemStyles.js.map +1 -0
  45. package/dist/cjs/src/components/projects/ManuscriptMenus.js +92 -0
  46. package/dist/cjs/src/components/projects/ManuscriptMenus.js.map +1 -0
  47. package/dist/cjs/src/components/projects/ManuscriptPageContainer.js +11 -6
  48. package/dist/cjs/src/components/projects/ManuscriptPageContainer.js.map +1 -1
  49. package/dist/cjs/src/components/projects/ManuscriptToolbar.js +111 -0
  50. package/dist/cjs/src/components/projects/ManuscriptToolbar.js.map +1 -0
  51. package/dist/cjs/src/components/projects/OrderedListToolbarItem.js +109 -0
  52. package/dist/cjs/src/components/projects/OrderedListToolbarItem.js.map +1 -0
  53. package/dist/cjs/src/components/projects/SortableManuscript.js +102 -0
  54. package/dist/cjs/src/components/projects/SortableManuscript.js.map +1 -0
  55. package/dist/cjs/src/components/projects/lean-workflow/ApplicationMenusLW.js +102 -0
  56. package/dist/cjs/src/components/projects/lean-workflow/ApplicationMenusLW.js.map +1 -0
  57. package/dist/cjs/src/components/projects/lean-workflow/CommentList.js +289 -0
  58. package/dist/cjs/src/components/projects/lean-workflow/CommentList.js.map +1 -0
  59. package/dist/cjs/src/components/projects/lean-workflow/CommentsTab.js +41 -0
  60. package/dist/cjs/src/components/projects/lean-workflow/CommentsTab.js.map +1 -0
  61. package/dist/cjs/src/components/projects/lean-workflow/ContentTab.js +66 -0
  62. package/dist/cjs/src/components/projects/lean-workflow/ContentTab.js.map +1 -0
  63. package/dist/cjs/src/components/projects/lean-workflow/EditorElement.js +252 -0
  64. package/dist/cjs/src/components/projects/lean-workflow/EditorElement.js.map +1 -0
  65. package/dist/cjs/src/components/projects/lean-workflow/ExceptionDialog.js +150 -0
  66. package/dist/cjs/src/components/projects/lean-workflow/ExceptionDialog.js.map +1 -0
  67. package/dist/cjs/src/components/projects/lean-workflow/ManuscriptPageContainerLW.js +187 -0
  68. package/dist/cjs/src/components/projects/lean-workflow/ManuscriptPageContainerLW.js.map +1 -0
  69. package/dist/cjs/src/components/projects/lean-workflow/SaveStatusController.js +53 -0
  70. package/dist/cjs/src/components/projects/lean-workflow/SaveStatusController.js.map +1 -0
  71. package/dist/cjs/src/components/projects/lean-workflow/TrackChangesStyles.js +106 -0
  72. package/dist/cjs/src/components/projects/lean-workflow/TrackChangesStyles.js.map +1 -0
  73. package/dist/cjs/src/components/projects/lean-workflow/icons/DeleteIcon.js +27 -0
  74. package/dist/cjs/src/components/projects/lean-workflow/icons/DeleteIcon.js.map +1 -0
  75. package/dist/cjs/src/components/projects/lean-workflow/icons/GroupIcon.js +29 -0
  76. package/dist/cjs/src/components/projects/lean-workflow/icons/GroupIcon.js.map +1 -0
  77. package/dist/cjs/src/components/projects/lean-workflow/icons/LinkIcon.js +23 -0
  78. package/dist/cjs/src/components/projects/lean-workflow/icons/LinkIcon.js.map +1 -0
  79. package/dist/cjs/src/components/projects/lean-workflow/icons/TemplateIcon.js +23 -0
  80. package/dist/cjs/src/components/projects/lean-workflow/icons/TemplateIcon.js.map +1 -0
  81. package/dist/cjs/src/components/projects/lean-workflow/provider/UserProvider.js +38 -0
  82. package/dist/cjs/src/components/projects/lean-workflow/provider/UserProvider.js.map +1 -0
  83. package/dist/cjs/src/components/requirements/RequirementContainer.js +58 -0
  84. package/dist/cjs/src/components/requirements/RequirementContainer.js.map +1 -0
  85. package/dist/cjs/src/components/requirements/RequirementsData.js +129 -0
  86. package/dist/cjs/src/components/requirements/RequirementsData.js.map +1 -0
  87. package/dist/cjs/src/components/requirements/RequirementsIcons.js +34 -0
  88. package/dist/cjs/src/components/requirements/RequirementsIcons.js.map +1 -0
  89. package/dist/cjs/src/components/requirements/RequirementsInspector.js +150 -0
  90. package/dist/cjs/src/components/requirements/RequirementsInspector.js.map +1 -0
  91. package/dist/cjs/src/components/requirements/RequirementsList.js +84 -0
  92. package/dist/cjs/src/components/requirements/RequirementsList.js.map +1 -0
  93. package/dist/cjs/src/components/requirements/SectionValidations.js +47 -0
  94. package/dist/cjs/src/components/requirements/SectionValidations.js.map +1 -0
  95. package/dist/cjs/src/components/toolbar/ListToolbarItemStyles.js +85 -0
  96. package/dist/cjs/src/components/toolbar/ListToolbarItemStyles.js.map +1 -0
  97. package/dist/cjs/src/components/toolbar/ManuscriptToolbar.js +111 -0
  98. package/dist/cjs/src/components/toolbar/ManuscriptToolbar.js.map +1 -0
  99. package/dist/cjs/src/components/toolbar/OrderdListToolbarItem.js +190 -0
  100. package/dist/cjs/src/components/toolbar/OrderdListToolbarItem.js.map +1 -0
  101. package/dist/cjs/src/components/track-changes/useEditorStore.js +60 -0
  102. package/dist/cjs/src/components/track-changes/useEditorStore.js.map +1 -0
  103. package/dist/cjs/src/config.js +2 -0
  104. package/dist/cjs/src/config.js.map +1 -1
  105. package/dist/cjs/src/hooks/use-requirements-validation.js +87 -0
  106. package/dist/cjs/src/hooks/use-requirements-validation.js.map +1 -0
  107. package/dist/cjs/src/lib/apollo.js +41 -0
  108. package/dist/cjs/src/lib/apollo.js.map +1 -0
  109. package/dist/cjs/src/lib/lean-workflow-gql.js +40 -0
  110. package/dist/cjs/src/lib/lean-workflow-gql.js.map +1 -0
  111. package/dist/cjs/src/lib/replace-attachments-ids.js +49 -0
  112. package/dist/cjs/src/lib/replace-attachments-ids.js.map +1 -0
  113. package/dist/cjs/src/postgres-data/Bibilo.js +33 -0
  114. package/dist/cjs/src/postgres-data/Bibilo.js.map +1 -0
  115. package/dist/cjs/src/quarterback/api/auth.js +7 -0
  116. package/dist/cjs/src/quarterback/api/auth.js.map +1 -0
  117. package/dist/cjs/src/quarterback/api/comment.js +13 -0
  118. package/dist/cjs/src/quarterback/api/comment.js.map +1 -0
  119. package/dist/cjs/src/quarterback/api/methodsV2.js +124 -0
  120. package/dist/cjs/src/quarterback/api/methodsV2.js.map +1 -0
  121. package/dist/cjs/src/quarterback/api/snapshot.js +16 -0
  122. package/dist/cjs/src/quarterback/api/snapshot.js.map +1 -0
  123. package/dist/cjs/src/quarterback/useAuthStore.js +80 -0
  124. package/dist/cjs/src/quarterback/useAuthStore.js.map +1 -0
  125. package/dist/cjs/src/quarterback/useCommentStore.js +178 -0
  126. package/dist/cjs/src/quarterback/useCommentStore.js.map +1 -0
  127. package/dist/cjs/src/quarterback/useDocStore.js +121 -0
  128. package/dist/cjs/src/quarterback/useDocStore.js.map +1 -0
  129. package/dist/cjs/src/quarterback/usePouchStore.js +75 -0
  130. package/dist/cjs/src/quarterback/usePouchStore.js.map +1 -0
  131. package/dist/cjs/src/quarterback/useSnapshotStore.js +140 -0
  132. package/dist/cjs/src/quarterback/useSnapshotStore.js.map +1 -0
  133. package/dist/cjs/src/store/BiblioTools.js +3 -0
  134. package/dist/cjs/src/store/BiblioTools.js.map +1 -0
  135. package/dist/cjs/stories/Citation.stories.js +43 -0
  136. package/dist/cjs/stories/Citation.stories.js.map +1 -0
  137. package/dist/cjs/stories/LibrarySidebar.stories.js +188 -0
  138. package/dist/cjs/stories/LibrarySidebar.stories.js.map +1 -0
  139. package/dist/cjs/stories/Metadata.stories.js +53 -0
  140. package/dist/cjs/stories/Metadata.stories.js.map +1 -0
  141. package/dist/cjs/stories/Notification.stories.js +62 -0
  142. package/dist/cjs/stories/Notification.stories.js.map +1 -0
  143. package/dist/cjs/stories/Page.stories.js +50 -0
  144. package/dist/cjs/stories/Page.stories.js.map +1 -0
  145. package/dist/cjs/stories/Panel.stories.js +62 -0
  146. package/dist/cjs/stories/Panel.stories.js.map +1 -0
  147. package/dist/cjs/stories/Placeholders.stories.js +23 -0
  148. package/dist/cjs/stories/Placeholders.stories.js.map +1 -0
  149. package/dist/cjs/stories/PopperButtons.stories.js +27 -0
  150. package/dist/cjs/stories/PopperButtons.stories.js.map +1 -0
  151. package/dist/cjs/stories/Progress.stories.js +25 -0
  152. package/dist/cjs/stories/Progress.stories.js.map +1 -0
  153. package/dist/cjs/stories/ProgressIndicator.stories.js +33 -0
  154. package/dist/cjs/stories/ProgressIndicator.stories.js.map +1 -0
  155. package/dist/cjs/stories/ReloadDialog.stories.js +21 -0
  156. package/dist/cjs/stories/ReloadDialog.stories.js.map +1 -0
  157. package/dist/cjs/stories/RequirementsInspector.stories.js +159 -0
  158. package/dist/cjs/stories/RequirementsInspector.stories.js.map +1 -0
  159. package/dist/cjs/stories/RequirmentsList.stories.js +36 -0
  160. package/dist/cjs/stories/RequirmentsList.stories.js.map +1 -0
  161. package/dist/cjs/stories/SelectField.stories.js +34 -0
  162. package/dist/cjs/stories/SelectField.stories.js.map +1 -0
  163. package/dist/cjs/stories/Support.stories.js +32 -0
  164. package/dist/cjs/stories/Support.stories.js.map +1 -0
  165. package/dist/cjs/stories/data/doc.js +27 -0
  166. package/dist/cjs/stories/data/doc.js.map +1 -0
  167. package/dist/cjs/stories/data/validationData.js +44 -0
  168. package/dist/cjs/stories/data/validationData.js.map +1 -0
  169. package/dist/es/src/components/Support.js +100 -0
  170. package/dist/es/src/components/Support.js.map +1 -0
  171. package/dist/es/src/components/inspector/ElementStyleInspector.js +13 -0
  172. package/dist/es/src/components/inspector/ElementStyleInspector.js.map +1 -0
  173. package/dist/es/src/components/inspector/StatisticsInspector.js +32 -0
  174. package/dist/es/src/components/inspector/StatisticsInspector.js.map +1 -0
  175. package/dist/es/src/components/library/CitationModel.js +180 -0
  176. package/dist/es/src/components/library/CitationModel.js.map +1 -0
  177. package/dist/es/src/components/library/CitationProperties.js +60 -0
  178. package/dist/es/src/components/library/CitationProperties.js.map +1 -0
  179. package/dist/es/src/components/library/ExternalSearch.js +127 -0
  180. package/dist/es/src/components/library/ExternalSearch.js.map +1 -0
  181. package/dist/es/src/components/library/GlobalLibrary.js +104 -0
  182. package/dist/es/src/components/library/GlobalLibrary.js.map +1 -0
  183. package/dist/es/src/components/library/LibraryCollectionCategories.js +45 -0
  184. package/dist/es/src/components/library/LibraryCollectionCategories.js.map +1 -0
  185. package/dist/es/src/components/library/LibraryForm.js +409 -0
  186. package/dist/es/src/components/library/LibraryForm.js.map +1 -0
  187. package/dist/es/src/components/library/LibraryItems.js +86 -0
  188. package/dist/es/src/components/library/LibraryItems.js.map +1 -0
  189. package/dist/es/src/components/library/LibraryPageContainer.js +80 -0
  190. package/dist/es/src/components/library/LibraryPageContainer.js.map +1 -0
  191. package/dist/es/src/components/library/LibrarySidebar.js +165 -0
  192. package/dist/es/src/components/library/LibrarySidebar.js.map +1 -0
  193. package/dist/es/src/components/library/Messages.js +18 -0
  194. package/dist/es/src/components/library/Messages.js.map +1 -0
  195. package/dist/es/src/components/library/ProjectLibrary.js +67 -0
  196. package/dist/es/src/components/library/ProjectLibrary.js.map +1 -0
  197. package/dist/es/src/components/menu/ApplicationMenus.js +72 -0
  198. package/dist/es/src/components/menu/ApplicationMenus.js.map +1 -0
  199. package/dist/es/src/components/metadata/HeaderFigure.js +117 -0
  200. package/dist/es/src/components/metadata/HeaderFigure.js.map +1 -0
  201. package/dist/es/src/components/metadata/Metadata.js +73 -0
  202. package/dist/es/src/components/metadata/Metadata.js.map +1 -0
  203. package/dist/es/src/components/metadata/MetadataContainer.js +178 -0
  204. package/dist/es/src/components/metadata/MetadataContainer.js.map +1 -0
  205. package/dist/es/src/components/metadata/TitleFieldContainer.js +49 -0
  206. package/dist/es/src/components/metadata/TitleFieldContainer.js.map +1 -0
  207. package/dist/es/src/components/projects/CategorisedKeywordsInput.js +409 -0
  208. package/dist/es/src/components/projects/CategorisedKeywordsInput.js.map +1 -0
  209. package/dist/es/src/components/projects/KeywordsInput.js +73 -0
  210. package/dist/es/src/components/projects/KeywordsInput.js.map +1 -0
  211. package/dist/es/src/components/projects/ListToolbarItemStyles.js +59 -0
  212. package/dist/es/src/components/projects/ListToolbarItemStyles.js.map +1 -0
  213. package/dist/es/src/components/projects/ManuscriptMenus.js +62 -0
  214. package/dist/es/src/components/projects/ManuscriptMenus.js.map +1 -0
  215. package/dist/es/src/components/projects/ManuscriptPageContainer.js +10 -6
  216. package/dist/es/src/components/projects/ManuscriptPageContainer.js.map +1 -1
  217. package/dist/es/src/components/projects/ManuscriptToolbar.js +104 -0
  218. package/dist/es/src/components/projects/ManuscriptToolbar.js.map +1 -0
  219. package/dist/es/src/components/projects/OrderedListToolbarItem.js +101 -0
  220. package/dist/es/src/components/projects/OrderedListToolbarItem.js.map +1 -0
  221. package/dist/es/src/components/projects/SortableManuscript.js +72 -0
  222. package/dist/es/src/components/projects/SortableManuscript.js.map +1 -0
  223. package/dist/es/src/components/projects/lean-workflow/ApplicationMenusLW.js +72 -0
  224. package/dist/es/src/components/projects/lean-workflow/ApplicationMenusLW.js.map +1 -0
  225. package/dist/es/src/components/projects/lean-workflow/CommentList.js +259 -0
  226. package/dist/es/src/components/projects/lean-workflow/CommentList.js.map +1 -0
  227. package/dist/es/src/components/projects/lean-workflow/CommentsTab.js +34 -0
  228. package/dist/es/src/components/projects/lean-workflow/CommentsTab.js.map +1 -0
  229. package/dist/es/src/components/projects/lean-workflow/ContentTab.js +59 -0
  230. package/dist/es/src/components/projects/lean-workflow/ContentTab.js.map +1 -0
  231. package/dist/es/src/components/projects/lean-workflow/EditorElement.js +227 -0
  232. package/dist/es/src/components/projects/lean-workflow/EditorElement.js.map +1 -0
  233. package/dist/es/src/components/projects/lean-workflow/ExceptionDialog.js +120 -0
  234. package/dist/es/src/components/projects/lean-workflow/ExceptionDialog.js.map +1 -0
  235. package/dist/es/src/components/projects/lean-workflow/ManuscriptPageContainerLW.js +159 -0
  236. package/dist/es/src/components/projects/lean-workflow/ManuscriptPageContainerLW.js.map +1 -0
  237. package/dist/es/src/components/projects/lean-workflow/SaveStatusController.js +23 -0
  238. package/dist/es/src/components/projects/lean-workflow/SaveStatusController.js.map +1 -0
  239. package/dist/es/src/components/projects/lean-workflow/TrackChangesStyles.js +99 -0
  240. package/dist/es/src/components/projects/lean-workflow/TrackChangesStyles.js.map +1 -0
  241. package/dist/es/src/components/projects/lean-workflow/icons/DeleteIcon.js +20 -0
  242. package/dist/es/src/components/projects/lean-workflow/icons/DeleteIcon.js.map +1 -0
  243. package/dist/es/src/components/projects/lean-workflow/icons/GroupIcon.js +22 -0
  244. package/dist/es/src/components/projects/lean-workflow/icons/GroupIcon.js.map +1 -0
  245. package/dist/es/src/components/projects/lean-workflow/icons/LinkIcon.js +16 -0
  246. package/dist/es/src/components/projects/lean-workflow/icons/LinkIcon.js.map +1 -0
  247. package/dist/es/src/components/projects/lean-workflow/icons/TemplateIcon.js +16 -0
  248. package/dist/es/src/components/projects/lean-workflow/icons/TemplateIcon.js.map +1 -0
  249. package/dist/es/src/components/projects/lean-workflow/provider/UserProvider.js +11 -0
  250. package/dist/es/src/components/projects/lean-workflow/provider/UserProvider.js.map +1 -0
  251. package/dist/es/src/components/requirements/RequirementContainer.js +51 -0
  252. package/dist/es/src/components/requirements/RequirementContainer.js.map +1 -0
  253. package/dist/es/src/components/requirements/RequirementsData.js +99 -0
  254. package/dist/es/src/components/requirements/RequirementsData.js.map +1 -0
  255. package/dist/es/src/components/requirements/RequirementsIcons.js +24 -0
  256. package/dist/es/src/components/requirements/RequirementsIcons.js.map +1 -0
  257. package/dist/es/src/components/requirements/RequirementsInspector.js +118 -0
  258. package/dist/es/src/components/requirements/RequirementsInspector.js.map +1 -0
  259. package/dist/es/src/components/requirements/RequirementsList.js +54 -0
  260. package/dist/es/src/components/requirements/RequirementsList.js.map +1 -0
  261. package/dist/es/src/components/requirements/SectionValidations.js +40 -0
  262. package/dist/es/src/components/requirements/SectionValidations.js.map +1 -0
  263. package/dist/es/src/components/toolbar/ListToolbarItemStyles.js +59 -0
  264. package/dist/es/src/components/toolbar/ListToolbarItemStyles.js.map +1 -0
  265. package/dist/es/src/components/toolbar/ManuscriptToolbar.js +104 -0
  266. package/dist/es/src/components/toolbar/ManuscriptToolbar.js.map +1 -0
  267. package/dist/es/src/components/toolbar/OrderdListToolbarItem.js +158 -0
  268. package/dist/es/src/components/toolbar/OrderdListToolbarItem.js.map +1 -0
  269. package/dist/es/src/components/track-changes/useEditorStore.js +57 -0
  270. package/dist/es/src/components/track-changes/useEditorStore.js.map +1 -0
  271. package/dist/es/src/config.js +2 -0
  272. package/dist/es/src/config.js.map +1 -1
  273. package/dist/es/src/hooks/use-requirements-validation.js +83 -0
  274. package/dist/es/src/hooks/use-requirements-validation.js.map +1 -0
  275. package/dist/es/src/lib/apollo.js +35 -0
  276. package/dist/es/src/lib/apollo.js.map +1 -0
  277. package/dist/es/src/lib/lean-workflow-gql.js +33 -0
  278. package/dist/es/src/lib/lean-workflow-gql.js.map +1 -0
  279. package/dist/es/src/lib/replace-attachments-ids.js +44 -0
  280. package/dist/es/src/lib/replace-attachments-ids.js.map +1 -0
  281. package/dist/es/src/postgres-data/Bibilo.js +29 -0
  282. package/dist/es/src/postgres-data/Bibilo.js.map +1 -0
  283. package/dist/es/src/quarterback/api/auth.js +3 -0
  284. package/dist/es/src/quarterback/api/auth.js.map +1 -0
  285. package/dist/es/src/quarterback/api/comment.js +6 -0
  286. package/dist/es/src/quarterback/api/comment.js.map +1 -0
  287. package/dist/es/src/quarterback/api/methodsV2.js +111 -0
  288. package/dist/es/src/quarterback/api/methodsV2.js.map +1 -0
  289. package/dist/es/src/quarterback/api/snapshot.js +8 -0
  290. package/dist/es/src/quarterback/api/snapshot.js.map +1 -0
  291. package/dist/es/src/quarterback/useAuthStore.js +51 -0
  292. package/dist/es/src/quarterback/useAuthStore.js.map +1 -0
  293. package/dist/es/src/quarterback/useCommentStore.js +149 -0
  294. package/dist/es/src/quarterback/useCommentStore.js.map +1 -0
  295. package/dist/es/src/quarterback/useDocStore.js +92 -0
  296. package/dist/es/src/quarterback/useDocStore.js.map +1 -0
  297. package/dist/es/src/quarterback/usePouchStore.js +69 -0
  298. package/dist/es/src/quarterback/usePouchStore.js.map +1 -0
  299. package/dist/es/src/quarterback/useSnapshotStore.js +114 -0
  300. package/dist/es/src/quarterback/useSnapshotStore.js.map +1 -0
  301. package/dist/es/src/store/BiblioTools.js +2 -0
  302. package/dist/es/src/store/BiblioTools.js.map +1 -0
  303. package/dist/es/stories/Citation.stories.js +38 -0
  304. package/dist/es/stories/Citation.stories.js.map +1 -0
  305. package/dist/es/stories/LibrarySidebar.stories.js +183 -0
  306. package/dist/es/stories/LibrarySidebar.stories.js.map +1 -0
  307. package/dist/es/stories/Metadata.stories.js +48 -0
  308. package/dist/es/stories/Metadata.stories.js.map +1 -0
  309. package/dist/es/stories/Notification.stories.js +57 -0
  310. package/dist/es/stories/Notification.stories.js.map +1 -0
  311. package/dist/es/stories/Page.stories.js +45 -0
  312. package/dist/es/stories/Page.stories.js.map +1 -0
  313. package/dist/es/stories/Panel.stories.js +57 -0
  314. package/dist/es/stories/Panel.stories.js.map +1 -0
  315. package/dist/es/stories/Placeholders.stories.js +18 -0
  316. package/dist/es/stories/Placeholders.stories.js.map +1 -0
  317. package/dist/es/stories/PopperButtons.stories.js +22 -0
  318. package/dist/es/stories/PopperButtons.stories.js.map +1 -0
  319. package/dist/es/stories/Progress.stories.js +20 -0
  320. package/dist/es/stories/Progress.stories.js.map +1 -0
  321. package/dist/es/stories/ProgressIndicator.stories.js +28 -0
  322. package/dist/es/stories/ProgressIndicator.stories.js.map +1 -0
  323. package/dist/es/stories/ReloadDialog.stories.js +16 -0
  324. package/dist/es/stories/ReloadDialog.stories.js.map +1 -0
  325. package/dist/es/stories/RequirementsInspector.stories.js +154 -0
  326. package/dist/es/stories/RequirementsInspector.stories.js.map +1 -0
  327. package/dist/es/stories/RequirmentsList.stories.js +31 -0
  328. package/dist/es/stories/RequirmentsList.stories.js.map +1 -0
  329. package/dist/es/stories/SelectField.stories.js +29 -0
  330. package/dist/es/stories/SelectField.stories.js.map +1 -0
  331. package/dist/es/stories/Support.stories.js +27 -0
  332. package/dist/es/stories/Support.stories.js.map +1 -0
  333. package/dist/es/stories/data/doc.js +21 -0
  334. package/dist/es/stories/data/doc.js.map +1 -0
  335. package/dist/es/stories/data/validationData.js +41 -0
  336. package/dist/es/stories/data/validationData.js.map +1 -0
  337. package/dist/types/src/components/Support.d.ts +13 -0
  338. package/dist/types/src/components/inspector/ElementStyleInspector.d.ts +13 -0
  339. package/dist/types/src/components/inspector/StatisticsInspector.d.ts +17 -0
  340. package/dist/types/src/components/library/CitationModel.d.ts +18 -0
  341. package/dist/types/src/components/library/CitationProperties.d.ts +17 -0
  342. package/dist/types/src/components/library/ExternalSearch.d.ts +19 -0
  343. package/dist/types/src/components/library/GlobalLibrary.d.ts +20 -0
  344. package/dist/types/src/components/library/LibraryCollectionCategories.d.ts +15 -0
  345. package/dist/types/src/components/library/LibraryForm.d.ts +20 -0
  346. package/dist/types/src/components/library/LibraryItems.d.ts +12 -0
  347. package/dist/types/src/components/library/LibraryPageContainer.d.ts +14 -0
  348. package/dist/types/src/components/library/LibrarySidebar.d.ts +21 -0
  349. package/dist/types/src/components/library/Messages.d.ts +15 -0
  350. package/dist/types/src/components/library/ProjectLibrary.d.ts +23 -0
  351. package/dist/types/src/components/menu/ApplicationMenus.d.ts +19 -0
  352. package/dist/types/src/components/metadata/HeaderFigure.d.ts +13 -0
  353. package/dist/types/src/components/metadata/Metadata.d.ts +60 -0
  354. package/dist/types/src/components/metadata/MetadataContainer.d.ts +21 -0
  355. package/dist/types/src/components/metadata/TitleFieldContainer.d.ts +19 -0
  356. package/dist/types/src/components/projects/CategorisedKeywordsInput.d.ts +6 -0
  357. package/dist/types/src/components/projects/KeywordsInput.d.ts +17 -0
  358. package/dist/types/src/components/projects/ListToolbarItemStyles.d.ts +25 -0
  359. package/dist/types/src/components/projects/ManuscriptMenus.d.ts +18 -0
  360. package/dist/types/src/components/projects/ManuscriptPageContainer.d.ts +1 -0
  361. package/dist/types/src/components/projects/ManuscriptToolbar.d.ts +22 -0
  362. package/dist/types/src/components/projects/OrderedListToolbarItem.d.ts +16 -0
  363. package/dist/types/src/components/projects/SortableManuscript.d.ts +18 -0
  364. package/dist/types/src/components/projects/lean-workflow/ApplicationMenusLW.d.ts +20 -0
  365. package/dist/types/src/components/projects/lean-workflow/CommentList.d.ts +18 -0
  366. package/dist/types/src/components/projects/lean-workflow/CommentsTab.d.ts +7 -0
  367. package/dist/types/src/components/projects/lean-workflow/ContentTab.d.ts +6 -0
  368. package/dist/types/src/components/projects/lean-workflow/EditorElement.d.ts +18 -0
  369. package/dist/types/src/components/projects/lean-workflow/ExceptionDialog.d.ts +4 -0
  370. package/dist/types/src/components/projects/lean-workflow/ManuscriptPageContainerLW.d.ts +18 -0
  371. package/dist/types/src/components/projects/lean-workflow/SaveStatusController.d.ts +17 -0
  372. package/dist/types/src/components/projects/lean-workflow/TrackChangesStyles.d.ts +13 -0
  373. package/dist/types/src/components/projects/lean-workflow/icons/DeleteIcon.d.ts +13 -0
  374. package/dist/types/src/components/projects/lean-workflow/icons/GroupIcon.d.ts +15 -0
  375. package/dist/types/src/components/projects/lean-workflow/icons/LinkIcon.d.ts +13 -0
  376. package/dist/types/src/components/projects/lean-workflow/icons/TemplateIcon.d.ts +13 -0
  377. package/dist/types/src/components/projects/lean-workflow/provider/UserProvider.d.ts +22 -0
  378. package/dist/types/src/components/requirements/RequirementContainer.d.ts +19 -0
  379. package/dist/types/src/components/requirements/RequirementsData.d.ts +21 -0
  380. package/dist/types/src/components/requirements/RequirementsIcons.d.ts +16 -0
  381. package/dist/types/src/components/requirements/RequirementsInspector.d.ts +23 -0
  382. package/dist/types/src/components/requirements/RequirementsList.d.ts +16 -0
  383. package/dist/types/src/components/requirements/SectionValidations.d.ts +21 -0
  384. package/dist/types/src/components/toolbar/ListToolbarItemStyles.d.ts +25 -0
  385. package/dist/types/src/components/toolbar/ManuscriptToolbar.d.ts +22 -0
  386. package/dist/types/src/components/toolbar/OrderdListToolbarItem.d.ts +24 -0
  387. package/dist/types/src/components/track-changes/useEditorStore.d.ts +36 -0
  388. package/dist/types/src/config.d.ts +2 -0
  389. package/dist/types/src/hooks/use-requirements-validation.d.ts +22 -0
  390. package/dist/types/src/lib/apollo.d.ts +13 -0
  391. package/dist/types/src/lib/lean-workflow-gql.d.ts +66 -0
  392. package/dist/types/src/lib/replace-attachments-ids.d.ts +15 -0
  393. package/dist/types/src/postgres-data/Bibilo.d.ts +33 -0
  394. package/dist/types/src/quarterback/api/auth.d.ts +13 -0
  395. package/dist/types/src/quarterback/api/comment.d.ts +16 -0
  396. package/dist/types/src/quarterback/api/methodsV2.d.ts +32 -0
  397. package/dist/types/src/quarterback/api/snapshot.d.ts +17 -0
  398. package/dist/types/src/quarterback/useAuthStore.d.ts +61 -0
  399. package/dist/types/src/quarterback/useCommentStore.d.ts +30 -0
  400. package/dist/types/src/quarterback/useDocStore.d.ts +19 -0
  401. package/dist/types/src/quarterback/usePouchStore.d.ts +30 -0
  402. package/dist/types/src/quarterback/useSnapshotStore.d.ts +29 -0
  403. package/dist/types/src/store/BiblioTools.d.ts +21 -0
  404. package/dist/types/stories/Citation.stories.d.ts +12 -0
  405. package/dist/types/stories/LibrarySidebar.stories.d.ts +12 -0
  406. package/dist/types/stories/Metadata.stories.d.ts +12 -0
  407. package/dist/types/stories/Notification.stories.d.ts +12 -0
  408. package/dist/types/stories/Page.stories.d.ts +12 -0
  409. package/dist/types/stories/Panel.stories.d.ts +12 -0
  410. package/dist/types/stories/Placeholders.stories.d.ts +12 -0
  411. package/dist/types/stories/PopperButtons.stories.d.ts +12 -0
  412. package/dist/types/stories/Progress.stories.d.ts +12 -0
  413. package/dist/types/stories/ProgressIndicator.stories.d.ts +12 -0
  414. package/dist/types/stories/ReloadDialog.stories.d.ts +12 -0
  415. package/dist/types/stories/RequirementsInspector.stories.d.ts +12 -0
  416. package/dist/types/stories/RequirmentsList.stories.d.ts +12 -0
  417. package/dist/types/stories/SelectField.stories.d.ts +12 -0
  418. package/dist/types/stories/Support.stories.d.ts +12 -0
  419. package/dist/types/stories/data/doc.d.ts +14 -0
  420. package/dist/types/stories/data/validationData.d.ts +13 -0
  421. package/package.json +3 -3
@@ -0,0 +1,120 @@
1
+ /*!
2
+ * The contents of this file are subject to the Common Public Attribution License Version 1.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License at https://mpapp-public.gitlab.io/manuscripts-frontend/LICENSE. The License is based on the Mozilla Public License Version 1.1 but Sections 14 and 15 have been added to cover use of software over a computer network and provide for limited attribution for the Original Developer. In addition, Exhibit A has been modified to be consistent with Exhibit B.
3
+ *
4
+ * Software distributed under the License is distributed on an “AS IS” basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limitations under the License.
5
+ *
6
+ * The Original Code is manuscripts-frontend.
7
+ *
8
+ * The Original Developer is the Initial Developer. The Initial Developer of the Original Code is Atypon Systems LLC.
9
+ *
10
+ * All portions of the code written by Atypon Systems LLC are Copyright (c) 2019 Atypon Systems LLC. All Rights Reserved.
11
+ */
12
+ import { AlertMessage, AlertMessageType, Category, Dialog, errorsDecoder, TertiaryButton, } from '@manuscripts/style-guide';
13
+ import React, { useCallback, useContext, useMemo, useState } from 'react';
14
+ import styled from 'styled-components';
15
+ import { useSetTaskOnHold } from '../../../lib/lean-workflow-gql';
16
+ import { Loading, LoadingOverlay } from '../../Loading';
17
+ import { UserContext } from './provider/UserProvider';
18
+ // TODO:: move this to style-guide
19
+ export const ExceptionDialog = ({ errorCode }) => {
20
+ const setTaskOnHold = useSetTaskOnHold();
21
+ const [toggleDialog, setToggleDialog] = useState(true);
22
+ const [loading, setLoading] = useState(false);
23
+ const [alert, setAlert] = useState(undefined);
24
+ const { lwUser, submissionId } = useContext(UserContext);
25
+ const { title, description } = errorsDecoder(errorCode);
26
+ const onCloseClick = useCallback(() => {
27
+ setToggleDialog(false);
28
+ }, []);
29
+ const onAssignClick = useCallback(async () => {
30
+ setLoading(true);
31
+ return await setTaskOnHold({ submissionId, errorCode })
32
+ .then(({ data }) => {
33
+ if (data?.setTaskOnHold) {
34
+ setAlert(AlertMessageType.success);
35
+ }
36
+ else {
37
+ setAlert(AlertMessageType.error);
38
+ }
39
+ setLoading(false);
40
+ })
41
+ .catch(() => {
42
+ setAlert(AlertMessageType.error);
43
+ setLoading(false);
44
+ });
45
+ }, [setTaskOnHold, submissionId, errorCode]);
46
+ const dialogMessages = useMemo(() => lwUser.role.id === 'pe'
47
+ ? {
48
+ header: title,
49
+ message: description,
50
+ secondaryMessage: 'Take care of the reported issue to unblock the process.',
51
+ actions: {
52
+ primary: {
53
+ action: onAssignClick,
54
+ title: 'Assign to me',
55
+ },
56
+ secondary: {
57
+ action: onCloseClick,
58
+ title: 'Cancel',
59
+ },
60
+ },
61
+ }
62
+ : {
63
+ header: title,
64
+ message: description,
65
+ secondaryMessage: 'If the problem persists, please assign the task to the Production Editor to take care of the issue.',
66
+ actions: {
67
+ primary: {
68
+ action: onAssignClick,
69
+ title: 'Assign',
70
+ },
71
+ secondary: {
72
+ action: onCloseClick,
73
+ title: 'Close',
74
+ },
75
+ },
76
+ }, [lwUser.role.id, onAssignClick, onCloseClick, title, description]);
77
+ return (React.createElement(React.Fragment, null, (loading && (React.createElement(LoadingOverlay, null,
78
+ React.createElement(Loading, null, "Assigning task to the Production Editor\u2026")))) ||
79
+ (alert && (React.createElement(AlertWrapper, null,
80
+ React.createElement(AlertMessage, { type: alert }, (alert === AlertMessageType.success &&
81
+ 'The task was successfully assigned to the Production Editor') ||
82
+ 'Un able to assign task to the Production Editor')))) || (React.createElement(Dialog, { isOpen: toggleDialog, category: Category.error, header: dialogMessages.header, message: dialogMessages.message, actions: dialogMessages.actions },
83
+ React.createElement(SecondaryMessage, null,
84
+ dialogMessages.secondaryMessage,
85
+ lwUser.role.id === 'pe' && (React.createElement(TextButton, null, "Contact support")))))));
86
+ };
87
+ const SecondaryMessage = styled.div `
88
+ word-wrap: break-word;
89
+ margin: ${(props) => props.theme.grid.unit * 2}px 0;
90
+ font: ${(props) => props.theme.font.weight.normal}
91
+ ${(props) => props.theme.font.size.medium} / 1
92
+ ${(props) => props.theme.font.family.sans};
93
+ color: ${(props) => props.theme.colors.text.secondary};
94
+ line-height: 1.5;
95
+ `;
96
+ // TODO:: move this to style-guide as we use it for dashboard
97
+ const TextButton = styled(TertiaryButton) `
98
+ &:not([disabled]):hover,
99
+ &:not([disabled]):focus {
100
+ border-color: transparent;
101
+ background: transparent;
102
+ color: ${(props) => props.theme.colors.brand.dark};
103
+ }
104
+ padding: 0;
105
+ width: 100%;
106
+ justify-content: start;
107
+ font-size: ${(props) => props.theme.font.size.medium};
108
+ text-decoration: underline;
109
+ `;
110
+ const AlertWrapper = styled.div `
111
+ position: fixed;
112
+ z-index: 10;
113
+ margin: 0 ${(props) => props.theme.grid.unit * 20}px
114
+ ${(props) => props.theme.grid.unit * 11}px
115
+ ${(props) => props.theme.grid.unit * 20}px;
116
+ bottom: 0;
117
+ right: 0;
118
+ left: 0;
119
+ `;
120
+ //# sourceMappingURL=ExceptionDialog.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ExceptionDialog.js","sourceRoot":"","sources":["../../../../../../src/components/projects/lean-workflow/ExceptionDialog.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AACH,OAAO,EACL,YAAY,EACZ,gBAAgB,EAChB,Q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,CAAC,KAAK,CAAC,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC,IAAI;;;;;eAKtC,CAAC,KAAK,EAAE,EAAE,CAAC,KAAK,CAAC,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,MAAM;;CAErD,CAAA;AAED,MAAM,YAAY,GAAG,MAAM,CAAC,GAAG,CAAA;;;cAGjB,CAAC,KAAK,EAAE,EAAE,CAAC,KAAK,CAAC,KAAK,CAAC,IAAI,CAAC,IAAI,GAAG,EAAE;MAC7C,CAAC,KAAK,EAAE,EAAE,CAAC,KAAK,CAAC,KAAK,CAAC,IAAI,CAAC,IAAI,GAAG,EAAE;MACrC,CAAC,KAAK,EAAE,EAAE,CAAC,KAAK,CAAC,KAAK,CAAC,IAAI,CAAC,IAAI,GAAG,EAAE;;;;CAI1C,CAAA"}
@@ -0,0 +1,159 @@
1
+ /*!
2
+ * The contents of this file are subject to the Common Public Attribution License Version 1.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License at https://mpapp-public.gitlab.io/manuscripts-frontend/LICENSE. The License is based on the Mozilla Public License Version 1.1 but Sections 14 and 15 have been added to cover use of software over a computer network and provide for limited attribution for the Original Developer. In addition, Exhibit A has been modified to be consistent with Exhibit B.
3
+ *
4
+ * Software distributed under the License is distributed on an “AS IS” basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limitations under the License.
5
+ *
6
+ * The Original Code is manuscripts-frontend.
7
+ *
8
+ * The Original Developer is the Initial Developer. The Initial Developer of the Original Code is Atypon Systems LLC.
9
+ *
10
+ * All portions of the code written by Atypon Systems LLC are Copyright (c) 2019 Atypon Systems LLC. All Rights Reserved.
11
+ */
12
+ import '@manuscripts/body-editor/styles/Editor.css';
13
+ import '@manuscripts/body-editor/styles/AdvancedEditor.css';
14
+ import '@manuscripts/body-editor/styles/popper.css';
15
+ import '@reach/tabs/styles.css';
16
+ import { ManuscriptToolbar, RequirementsProvider, } from '@manuscripts/body-editor';
17
+ import { CapabilitiesProvider, useCalcPermission, usePermissions, } from '@manuscripts/style-guide';
18
+ import { TrackChangesStatus } from '@manuscripts/track-changes-plugin';
19
+ import { debounce } from 'lodash';
20
+ import React, { useEffect, useLayoutEffect, useMemo } from 'react';
21
+ import styled from 'styled-components';
22
+ import config from '../../../config';
23
+ import { useCreateEditor } from '../../../hooks/use-create-editor';
24
+ import useTrackedModelManagement from '../../../hooks/use-tracked-model-management';
25
+ import { useCommentStore } from '../../../quarterback/useCommentStore';
26
+ import { useDocStore } from '../../../quarterback/useDocStore';
27
+ import { useStore } from '../../../store';
28
+ import MetadataContainer from '../../metadata/MetadataContainer';
29
+ import { Main } from '../../Page';
30
+ import { useEditorStore } from '../../track-changes/useEditorStore';
31
+ import { EditorBody, EditorContainer, EditorContainerInner, EditorHeader, } from '../EditorContainer';
32
+ import Inspector from '../Inspector';
33
+ import ManuscriptSidebar from '../ManuscriptSidebar';
34
+ import { ApplicationMenuContainer, ApplicationMenusLW as ApplicationMenus, } from './ApplicationMenusLW';
35
+ import EditorElement from './EditorElement';
36
+ import { UserProvider } from './provider/UserProvider';
37
+ import { TrackChangesStyles } from './TrackChangesStyles';
38
+ const ManuscriptPageContainer = () => {
39
+ const [{ project, user, submission, person, permittedActions }, dispatch] = useStore((state) => {
40
+ return {
41
+ manuscriptID: state.manuscriptID,
42
+ project: state.project,
43
+ user: state.user,
44
+ submission: state.submission,
45
+ permittedActions: state.permittedActions,
46
+ person: state.person,
47
+ };
48
+ });
49
+ useEffect(() => {
50
+ if (submission?.id && person) {
51
+ dispatch({
52
+ submission: submission,
53
+ submissionId: submission.id,
54
+ lwUser: person,
55
+ });
56
+ }
57
+ }, [submission, person, dispatch]);
58
+ // lwRole must not be used to calculate permissions in the contenxt of manuscripts app.
59
+ // lwRole is only for the dashboard
60
+ const can = useCalcPermission({
61
+ profile: user,
62
+ project: project,
63
+ permittedActions,
64
+ });
65
+ return (React.createElement(CapabilitiesProvider, { can: can },
66
+ React.createElement(ManuscriptPageView, null)));
67
+ };
68
+ const ManuscriptPageView = () => {
69
+ const [manuscript] = useStore((store) => store.manuscript);
70
+ const [project] = useStore((store) => store.project);
71
+ const [user] = useStore((store) => store.user);
72
+ const [lwUser] = useStore((store) => store.lwUser);
73
+ const [modelMap] = useStore((store) => store.modelMap);
74
+ const [submissionID] = useStore((store) => store.submissionID || '');
75
+ const [manuscriptID, storeDispatch, getState] = useStore((store) => store.manuscriptID);
76
+ const [doc] = useStore((store) => store.doc);
77
+ const [saveModel] = useStore((store) => store.saveModel);
78
+ const [deleteModel] = useStore((store) => store.deleteModel);
79
+ const [collaboratorsById] = useStore((store) => store.collaboratorsById || new Map());
80
+ const can = usePermissions();
81
+ const editor = useCreateEditor();
82
+ const { state, dispatch, view } = editor;
83
+ const { saveTrackModel, trackModelMap, deleteTrackModel, getTrackModel } = useTrackedModelManagement(doc, view, state, dispatch, saveModel, deleteModel, modelMap, () => getState().submission.attachments);
84
+ useEffect(() => {
85
+ storeDispatch({
86
+ saveTrackModel,
87
+ trackModelMap,
88
+ deleteTrackModel,
89
+ getTrackModel,
90
+ });
91
+ }, [
92
+ saveTrackModel,
93
+ trackModelMap,
94
+ deleteTrackModel,
95
+ storeDispatch,
96
+ getTrackModel,
97
+ ]);
98
+ const { setUsers } = useCommentStore();
99
+ const { updateDocument } = useDocStore();
100
+ const { init: initEditor, setEditorState, trackState } = useEditorStore();
101
+ useLayoutEffect(() => setUsers(collaboratorsById), [collaboratorsById, setUsers]);
102
+ useLayoutEffect(() => view && initEditor(view), [view, initEditor]);
103
+ const hasPendingSuggestions = useMemo(() => {
104
+ const { changeSet } = trackState || {};
105
+ return changeSet && changeSet.pending.length > 0;
106
+ }, [trackState]);
107
+ useEffect(() => {
108
+ storeDispatch({ hasPendingSuggestions });
109
+ }, [storeDispatch, hasPendingSuggestions]);
110
+ const saveDocument = debounce((state) => {
111
+ storeDispatch({ doc: state.doc });
112
+ updateDocument(manuscriptID, state.doc.toJSON());
113
+ }, 500);
114
+ useEffect(() => {
115
+ const { trackState } = setEditorState(state);
116
+ if (trackState && trackState.status !== TrackChangesStatus.viewSnapshots) {
117
+ saveDocument(state);
118
+ }
119
+ // eslint-disable-next-line react-hooks/exhaustive-deps
120
+ }, [state]);
121
+ return (React.createElement(RequirementsProvider, { modelMap: modelMap },
122
+ React.createElement(UserProvider, { lwUser: lwUser, manuscriptUser: user, submissionId: submissionID },
123
+ React.createElement(ManuscriptSidebar, { project: project, manuscript: manuscript, view: view, state: state, user: user }),
124
+ React.createElement(PageWrapper, null,
125
+ React.createElement(Main, null,
126
+ React.createElement(EditorContainer, null,
127
+ React.createElement(EditorContainerInner, null,
128
+ React.createElement(EditorHeader, null,
129
+ React.createElement(ApplicationMenuContainer, null,
130
+ React.createElement(ApplicationMenus, { editor: editor, contentEditable: can.editArticle })),
131
+ can.seeEditorToolbar && (React.createElement(ManuscriptToolbar, { state: state, can: can, dispatch: dispatch, footnotesEnabled: config.features.footnotes, view: view }))),
132
+ React.createElement(EditorBody, null,
133
+ React.createElement(MetadataContainer, { handleTitleStateChange: () => '' /*FIX THIS*/, allowInvitingAuthors: false, showAuthorEditButton: true, disableEditButton: !can.editMetadata }),
134
+ React.createElement(TrackChangesStyles, null,
135
+ React.createElement(EditorElement, { editor: editor })))))),
136
+ React.createElement(Inspector, { editor: editor })))));
137
+ };
138
+ const PageWrapper = styled.div `
139
+ position: relative;
140
+ display: flex;
141
+ flex: 2;
142
+ overflow: hidden;
143
+
144
+ .edit_authors_button {
145
+ display: initial;
146
+ color: ${(props) => props.theme.colors.button.secondary.color.default};
147
+ background: ${(props) => props.theme.colors.button.secondary.background.default};
148
+ border-color: ${(props) => props.theme.colors.button.secondary.border.default};
149
+
150
+ &:not([disabled]):hover,
151
+ &:not([disabled]):focus {
152
+ color: ${(props) => props.theme.colors.button.secondary.color.hover};
153
+ background: ${(props) => props.theme.colors.button.secondary.background.hover};
154
+ border-color: ${(props) => props.theme.colors.button.secondary.border.hover};
155
+ }
156
+ }
157
+ `;
158
+ export default ManuscriptPageContainer;
159
+ //# sourceMappingURL=ManuscriptPageContainerLW.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ManuscriptPageContainerLW.js","sourceRoot":"","sources":["../../../../../../src/components/projects/lean-workflow/ManuscriptPageContainerLW.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,4CAA4C,CAAA;AACnD,OAAO,oDAAoD,CAAA;AAC3D,OAAO,4CAA4C,CAAA;AACnD,OAAO,wBAAwB,CAAA;AAE/B,OAAO,EACL,iBAAiB,EACjB,oBAAoB,GACrB,MAAM,0BAA0B,CAAA;AACjC,OAAO,EACL,oBAAoB,EACpB,iBAAiB,EACjB,cAAc,GACf,MAAM,0BAA0B,CAAA;AACjC,OAAO,EAAE,kBAAkB,EAAE,MAAM,mCAAmC,CAAA;AAEtE,OAAO,EAAE,QAAQ,EAAE,MAAM,QAAQ,CAAA;AACjC,OAAO,KAAK,EAAE,EAAE,SAAS,EAAE,eAAe,EAAE,OAAO,EAAE,MAAM,OAAO,CAAA;AAClE,OAAO,MAAM,MAAM,mBAAmB,CAAA;AAEtC,OAAO,MAAM,MAAM,iBAAiB,CAAA;AACpC,OAAO,EAAE,eAAe,EAAE,MAAM,kCAAkC,CAAA;AAClE,OAAO,yBAAyB,MAAM,6CAA6C,CAAA;AAEnF,OAAO,EAAE,eAAe,EAAE,MAAM,sCAAsC,CAAA;AACtE,OAAO,EAAE,WAAW,EAAE,MAAM,kCAAkC,CAAA;AAC9D,OAAO,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAA;AACzC,OAAO,iBAAiB,MAAM,kCAAkC,CAAA;AAChE,OAAO,EAAE,IAAI,EAAE,MAAM,YAAY,CAAA;AACjC,OAAO,EAAE,cAAc,EAAE,MAAM,oCAAoC,CAAA;AACnE,OAAO,EACL,UAAU,EACV,eAAe,EACf,oBAAoB,EACpB,YAAY,GACb,MAAM,oBAAoB,CAAA;AAC3B,OAAO,SAAS,MAAM,cAAc,CA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K,CAAC,KAAK;oBACrD,CAAC,KAAK,EAAE,EAAE,CACtB,KAAK,CAAC,KAAK,CAAC,MAAM,CAAC,MAAM,CAAC,SAAS,CAAC,UAAU,CAAC,KAAK;sBACtC,CAAC,KAAK,EAAE,EAAE,CACxB,KAAK,CAAC,KAAK,CAAC,MAAM,CAAC,MAAM,CAAC,SAAS,CAAC,MAAM,CAAC,KAAK;;;CAGvD,CAAA;AAED,eAAe,uBAAuB,CAAA"}
@@ -0,0 +1,23 @@
1
+ /*!
2
+ * The contents of this file are subject to the Common Public Attribution License Version 1.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License at https://mpapp-public.gitlab.io/manuscripts-frontend/LICENSE. The License is based on the Mozilla Public License Version 1.1 but Sections 14 and 15 have been added to cover use of software over a computer network and provide for limited attribution for the Original Developer. In addition, Exhibit A has been modified to be consistent with Exhibit B.
3
+ *
4
+ * Software distributed under the License is distributed on an “AS IS” basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limitations under the License.
5
+ *
6
+ * The Original Code is manuscripts-frontend.
7
+ *
8
+ * The Original Developer is the Initial Developer. The Initial Developer of the Original Code is Atypon Systems LLC.
9
+ *
10
+ * All portions of the code written by Atypon Systems LLC are Copyright (c) 2019 Atypon Systems LLC. All Rights Reserved.
11
+ */
12
+ import { SaveStatus } from '@manuscripts/style-guide';
13
+ import React from 'react';
14
+ import useOnlineState, { OnlineState } from '../../../hooks/use-online-state';
15
+ export const SaveStatusController = ({ isSaving }) => {
16
+ // const syncState = useSyncState() // couchdb heritage
17
+ const [onlineState] = useOnlineState();
18
+ const isOffline = onlineState !== OnlineState.Online;
19
+ // const isPushing = selectors.isPushing(containerID, syncState) // couchdb heritage
20
+ const status = isOffline ? 'offline' : isSaving ? 'saving' : 'saved';
21
+ return React.createElement(SaveStatus, { status: status });
22
+ };
23
+ //# sourceMappingURL=SaveStatusController.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"SaveStatusController.js","sourceRoot":"","sources":["../../../../../../src/components/projects/lean-workflow/SaveStatusController.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,EAAE,UAAU,EAAE,MAAM,0BAA0B,CAAA;AACrD,OAAO,KAAK,MAAM,OAAO,CAAA;AAEzB,OAAO,cAAc,EAAE,EAAE,WAAW,EAAE,MAAM,iCAAiC,CAAA;AAM7E,MAAM,CAAC,MAAM,oBAAoB,GAAoB,CAAC,EAAE,QAAQ,EAAE,EAAE,EAAE;IACpE,uDAAuD;IACvD,MAAM,CAAC,WAAW,CAAC,GAAG,cAAc,EAAE,CAAA;IAEtC,MAAM,SAAS,GAAG,WAAW,KAAK,WAAW,CAAC,MAAM,CAAA;IACpD,oFAAoF;IAEpF,MAAM,MAAM,GAAG,SAAS,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,OAAO,CAAA;IAEpE,OAAO,oBAAC,UAAU,IAAC,MAAM,EAAE,MAAM,GAAI,CAAA;AACvC,CAAC,CAAA"}
@@ -0,0 +1,99 @@
1
+ /*!
2
+ * The contents of this file are subject to the Common Public Attribution License Version 1.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License at https://mpapp-public.gitlab.io/manuscripts-frontend/LICENSE. The License is based on the Mozilla Public License Version 1.1 but Sections 14 and 15 have been added to cover use of software over a computer network and provide for limited attribution for the Original Developer. In addition, Exhibit A has been modified to be consistent with Exhibit B.
3
+ *
4
+ * Software distributed under the License is distributed on an “AS IS” basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limitations under the License.
5
+ *
6
+ * The Original Code is manuscripts-frontend.
7
+ *
8
+ * The Original Developer is the Initial Developer. The Initial Developer of the Original Code is Atypon Systems LLC.
9
+ *
10
+ * All portions of the code written by Atypon Systems LLC are Copyright (c) 2019 Atypon Systems LLC. All Rights Reserved.
11
+ */
12
+ import { usePermissions } from '@manuscripts/style-guide';
13
+ import React from 'react';
14
+ import styled from 'styled-components';
15
+ import config from '../../../config';
16
+ import { useStore } from '../../../store';
17
+ import { useEditorStore } from '../../track-changes/useEditorStore';
18
+ const TrackChangesOn = styled.div `
19
+
20
+ .track-changes--control {
21
+ display: none;
22
+ position: absolute;
23
+ }
24
+
25
+ .track-changes--control > button {
26
+ display: flex;
27
+ flex-direction: column;
28
+ justify-content: center;
29
+ align-items: center;
30
+ background: ${(props) => props.theme.colors.button.secondary.background.default};
31
+ border: 1px solid
32
+ ${(props) => props.theme.colors.button.secondary.border.default};
33
+ color: ${(props) => props.theme.colors.button.secondary.color.default};
34
+ width: 2em;
35
+ height: 2em;
36
+ border-radius: 50%;
37
+ cursor: pointer;
38
+ }
39
+
40
+ .track-changes--control > button:hover {
41
+ background: ${(props) => props.theme.colors.button.default.background.hover} !important;
42
+ }
43
+
44
+ .track-changes--control > button > svg {
45
+ display: inline-flex;
46
+ width: 1.2em;
47
+ height: 1.2em;
48
+ }
49
+ }
50
+ `;
51
+ const TrackChangesReadOnly = styled(TrackChangesOn) `
52
+ .track-changes--control {
53
+ display: none !important;
54
+ }
55
+ `;
56
+ const TrackChangesRejectOnly = styled(TrackChangesOn) `
57
+ [data-action='accept'] {
58
+ display: none !important;
59
+ }
60
+ `;
61
+ const TrackChangesOff = styled.div `
62
+ .track-changes--control {
63
+ display: none !important;
64
+ }
65
+ `;
66
+ const Actions = styled.div `
67
+ .pending:hover .track-changes--control:is(${(props) => props.selector}),
68
+ .track-changes--control:is(${(props) => props.selector}):hover {
69
+ display: inline-flex;
70
+ }
71
+ `;
72
+ const trackChangesCssSelector = (ids) => {
73
+ return ids.map((id) => `[data-changeid="${id}"]`).join(',\n');
74
+ };
75
+ export const TrackChangesStyles = ({ children }) => {
76
+ const { trackState } = useEditorStore();
77
+ const can = usePermissions();
78
+ const [user] = useStore((store) => store.user);
79
+ const { changeSet } = trackState || {};
80
+ const suggestedChangesSelector = trackChangesCssSelector(changeSet?.pending ? changeSet?.pending.map((change) => change.id) : []);
81
+ const mySuggestedChangesSelector = trackChangesCssSelector(changeSet?.pending
82
+ ? changeSet?.pending
83
+ .filter((change) => change.dataTracked.authorID == user?._id)
84
+ .map((change) => change.id)
85
+ : []);
86
+ if (!config.quarterback.enabled) {
87
+ return React.createElement(TrackChangesOff, null, children);
88
+ }
89
+ if (can.handleSuggestion) {
90
+ return (React.createElement(TrackChangesOn, null,
91
+ React.createElement(Actions, { selector: suggestedChangesSelector }, children)));
92
+ }
93
+ if (can.rejectOwnSuggestion) {
94
+ return (React.createElement(TrackChangesRejectOnly, null,
95
+ React.createElement(Actions, { selector: mySuggestedChangesSelector }, children)));
96
+ }
97
+ return React.createElement(TrackChangesReadOnly, null, children);
98
+ };
99
+ //# sourceMappingURL=TrackChangesStyles.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"TrackChangesStyles.js","sourceRoot":"","sources":["../../../../../../src/components/projects/lean-workflow/TrackChangesStyles.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAA;AACzD,OAAO,KAAK,MAAM,OAAO,CAAA;AACzB,OAAO,MAAM,MAAM,mBAAmB,CAAA;AAEtC,OAAO,MAAM,MAAM,iBAAiB,CAAA;AACpC,OAAO,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAA;AACzC,OAAO,EAAE,cAAc,EAAE,MAAM,oCAAoC,CAAA;AAEnE,MAAM,cAAc,GAAG,MAAM,CAAC,GAAG,CAAA;;;;;;;;;;;;kBAYf,CAAC,KAAK,EAAE,EAAE,CACtB,KAAK,CAAC,KAAK,CAAC,MAAM,CAAC,MAAM,CAAC,SAAS,CAAC,UAAU,CAAC,OAAO;;QAEpD,CAAC,KAAK,EAAE,EAAE,CAAC,KAAK,CAAC,KAAK,CAAC,MAAM,CAAC,MAAM,CAAC,SAAS,CAAC,MAAM,CAAC,OAAO;aACxD,CAAC,KAAK,EAAE,EA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AAC,SAAS,EAAE,OAAO,CAAC,GAAG,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,MAAM,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,EAAE,CACxE,CAAA;IAED,MAAM,0BAA0B,GAAG,uBAAuB,CACxD,SAAS,EAAE,OAAO;QAChB,CAAC,CAAC,SAAS,EAAE,OAAO;aACf,MAAM,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,MAAM,CAAC,WAAW,CAAC,QAAQ,IAAI,IAAI,EAAE,GAAG,CAAC;aAC5D,GAAG,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,MAAM,CAAC,EAAE,CAAC;QAC/B,CAAC,CAAC,EAAE,CACP,CAAA;IAED,IAAI,CAAC,MAAM,CAAC,WAAW,CAAC,OAAO,EAAE;QAC/B,OAAO,oBAAC,eAAe,QAAE,QAAQ,CAAmB,CAAA;KACrD;IAED,IAAI,GAAG,CAAC,gBAAgB,EAAE;QACxB,OAAO,CACL,oBAAC,cAAc;YACb,oBAAC,OAAO,IAAC,QAAQ,EAAE,wBAAwB,IAAG,QAAQ,CAAW,CAClD,CAClB,CAAA;KACF;IAED,IAAI,GAAG,CAAC,mBAAmB,EAAE;QAC3B,OAAO,CACL,oBAAC,sBAAsB;YACrB,oBAAC,OAAO,IAAC,QAAQ,EAAE,0BAA0B,IAAG,QAAQ,CAAW,CAC5C,CAC1B,CAAA;KACF;IAED,OAAO,oBAAC,oBAAoB,QAAE,QAAQ,CAAwB,CAAA;AAChE,CAAC,CAAA"}
@@ -0,0 +1,20 @@
1
+ /*!
2
+ * The contents of this file are subject to the Common Public Attribution License Version 1.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License at https://mpapp-public.gitlab.io/manuscripts-frontend/LICENSE. The License is based on the Mozilla Public License Version 1.1 but Sections 14 and 15 have been added to cover use of software over a computer network and provide for limited attribution for the Original Developer. In addition, Exhibit A has been modified to be consistent with Exhibit B.
3
+ *
4
+ * Software distributed under the License is distributed on an “AS IS” basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limitations under the License.
5
+ *
6
+ * The Original Code is manuscripts-frontend.
7
+ *
8
+ * The Original Developer is the Initial Developer. The Initial Developer of the Original Code is Atypon Systems LLC.
9
+ *
10
+ * All portions of the code written by Atypon Systems LLC are Copyright (c) 2022 Atypon Systems LLC. All Rights Reserved.
11
+ */
12
+ import React from 'react';
13
+ export const DeleteIcon = () => (React.createElement("svg", { width: "13", height: "16", viewBox: "0 0 13 16", fill: "none", xmlns: "http://www.w3.org/2000/svg" },
14
+ React.createElement("path", { className: "icon_element", fillRule: "evenodd", clipRule: "evenodd", d: "M2.00001 2.99995C2 3.0013 2 3.00265 2 3.00399V13.004C2 13.5563 2.44772 14.004 3 14.004H10C10.5523 14.004 11 13.5563 11 13.004V3.00399C11 3.00265 11 3.0013 11 2.99995C11.5978 3.34576 12 3.99211 12 4.73239V13.004C12 14.1086 11.1046 15.004 10 15.004H3C1.89543 15.004 1 14.1086 1 13.004V4.73239C1 3.99211 1.4022 3.34576 2.00001 2.99995Z", fill: "#F35143" }),
15
+ React.createElement("path", { className: "icon_element", fillRule: "evenodd", clipRule: "evenodd", d: "M4.5 0C3.67157 0 3 0.671573 3 1.5V3.5C3 4.32843 3.67157 5 4.5 5H8.5C9.32843 5 10 4.32843 10 3.5V1.5C10 0.671573 9.32843 0 8.5 0H4.5ZM9 1.5C9 1.22386 8.77614 1 8.5 1H4.5C4.22386 1 4 1.22386 4 1.5C4 1.77614 4.22386 2 4.5 2H8.5C8.77614 2 9 1.77614 9 1.5Z", fill: "#F35143" }),
16
+ React.createElement("rect", { className: "icon_element", y: "2", width: "13", height: "3", rx: "1.5", fill: "#F35143" }),
17
+ React.createElement("path", { className: "icon_element", fillRule: "evenodd", clipRule: "evenodd", d: "M8 7.5C8 7.22386 8.22386 7 8.5 7C8.77614 7 9 7.22386 9 7.5V11.5C9 11.7761 8.77614 12 8.5 12C8.22386 12 8 11.7761 8 11.5V7.5Z", fill: "#F35143" }),
18
+ React.createElement("path", { className: "icon_element", fillRule: "evenodd", clipRule: "evenodd", d: "M4 7.5C4 7.22386 4.22386 7 4.5 7C4.77614 7 5 7.22386 5 7.5V11.5C5 11.7761 4.77614 12 4.5 12C4.22386 12 4 11.7761 4 11.5V7.5Z", fill: "#F35143" }),
19
+ React.createElement("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M11.5 3C11.7761 3 12 3.22386 12 3.5C12 3.77614 11.7761 4 11.5 4L1.5 4C1.22386 4 1 3.77614 1 3.5C1 3.22386 1.22386 3 1.5 3L11.5 3Z", fill: "white" })));
20
+ //# sourceMappingURL=DeleteIcon.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"DeleteIcon.js","sourceRoot":"","sources":["../../../../../../../src/components/projects/lean-workflow/icons/DeleteIcon.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AACH,OAAO,KAAK,MAAM,OAAO,CAAA;AAEzB,MAAM,CAAC,MAAM,UAAU,GAAa,GAAG,EAAE,CAAC,CACxC,6BACE,KAAK,EAAC,IAAI,EACV,MAAM,EAAC,IAAI,EACX,OAAO,EAAC,WAAW,EACnB,IAAI,EAAC,MAAM,EACX,KAAK,EAAC,4BAA4B;IAElC,8BACE,SAAS,EAAC,cAAc,EACxB,QAAQ,EAAC,SAAS,EAClB,QAAQ,EAAC,SAAS,EAClB,CAAC,EAAC,8UAA8U,EAChV,IAAI,EAAC,SAAS,GACd;IACF,8BACE,SAAS,EAAC,cAAc,EACxB,QAAQ,EAAC,SAAS,EAClB,QAAQ,EAAC,SAAS,EAClB,CAAC,EAAC,6PAA6P,EAC/P,IAAI,EAAC,SAAS,GACd;IACF,8BACE,SAAS,EAAC,cAAc,EACxB,CAAC,EAAC,GAAG,EACL,KAAK,EAAC,IAAI,EACV,MAAM,EAAC,GAAG,EACV,EAAE,EAAC,KAAK,EACR,IAAI,EAAC,SAAS,GACd;IACF,8BACE,SAAS,EAAC,cAAc,EACxB,QAAQ,EAAC,SAAS,EAClB,QAAQ,EAAC,SAAS,EAClB,CAAC,EAAC,8HAA8H,EAChI,IAAI,EAAC,SAAS,GACd;IACF,8BACE,SAAS,EAAC,cAAc,EACxB,QAAQ,EAAC,SAAS,EAClB,QAAQ,EAAC,SAAS,EAClB,CAAC,EAAC,8HAA8H,EAChI,IAAI,EAAC,SAAS,GACd;IACF,8BACE,QAAQ,EAAC,SAAS,EAClB,QAAQ,EAAC,SAAS,EAClB,CAAC,EAAC,mIAAmI,EACrI,IAAI,EAAC,OAAO,GACZ,CACE,CACP,CAAA"}
@@ -0,0 +1,22 @@
1
+ /*!
2
+ * The contents of this file are subject to the Common Public Attribution License Version 1.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License at https://mpapp-public.gitlab.io/manuscripts-frontend/LICENSE. The License is based on the Mozilla Public License Version 1.1 but Sections 14 and 15 have been added to cover use of software over a computer network and provide for limited attribution for the Original Developer. In addition, Exhibit A has been modified to be consistent with Exhibit B.
3
+ *
4
+ * Software distributed under the License is distributed on an “AS IS” basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limitations under the License.
5
+ *
6
+ * The Original Code is manuscripts-frontend.
7
+ *
8
+ * The Original Developer is the Initial Developer. The Initial Developer of the Original Code is Atypon Systems LLC.
9
+ *
10
+ * All portions of the code written by Atypon Systems LLC are Copyright (c) 2022 Atypon Systems LLC. All Rights Reserved.
11
+ */
12
+ import React from 'react';
13
+ import styled from 'styled-components';
14
+ export const GroupIcon = ({ numberOfCitations, }) => (React.createElement(BadgeIcon, { width: "12", height: "12", viewBox: "0 0 12 12", fill: "none", xmlns: "http://www.w3.org/2000/svg" },
15
+ React.createElement("rect", { width: "12", height: "12", rx: "6", fill: (numberOfCitations > 0 && '#BCE7F6') || '#FE8F1F' }),
16
+ React.createElement("text", { x: "6", y: "8", fill: "#FFF", fontSize: "9px", textAnchor: "middle", fontWeight: "400" }, numberOfCitations)));
17
+ const BadgeIcon = styled.svg `
18
+ top: -4px;
19
+ right: 16px;
20
+ position: absolute;
21
+ `;
22
+ //# sourceMappingURL=GroupIcon.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GroupIcon.js","sourceRoot":"","sources":["../../../../../../../src/components/projects/lean-workflow/icons/GroupIcon.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AACH,OAAO,KAAK,MAAM,OAAO,CAAA;AACzB,OAAO,MAAM,MAAM,mBAAmB,CAAA;AAEtC,MAAM,CAAC,MAAM,SAAS,GAA4C,CAAC,EACjE,iBAAiB,GAClB,EAAE,EAAE,CAAC,CACJ,oBAAC,SAAS,IACR,KAAK,EAAC,IAAI,EACV,MAAM,EAAC,IAAI,EACX,OAAO,EAAC,WAAW,EACnB,IAAI,EAAC,MAAM,EACX,KAAK,EAAC,4BAA4B;IAElC,8BACE,KAAK,EAAC,IAAI,EACV,MAAM,EAAC,IAAI,EACX,EAAE,EAAC,GAAG,EACN,IAAI,EAAE,CAAC,iBAAiB,GAAG,CAAC,IAAI,SAAS,CAAC,IAAI,SAAS,GACvD;IACF,8BACE,CAAC,EAAC,GAAG,EACL,CAAC,EAAC,GAAG,EACL,IAAI,EAAC,MAAM,EACX,QAAQ,EAAC,KAAK,EACd,UAAU,EAAC,QAAQ,EACnB,UAAU,EAAC,KAAK,IAEf,iBAAiB,CACb,CACG,CACb,CAAA;AAED,MAAM,SAAS,GAAG,MAAM,CAAC,GAAG,CAAA;;;;CAI3B,CAAA"}
@@ -0,0 +1,16 @@
1
+ /*!
2
+ * The contents of this file are subject to the Common Public Attribution License Version 1.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License at https://mpapp-public.gitlab.io/manuscripts-frontend/LICENSE. The License is based on the Mozilla Public License Version 1.1 but Sections 14 and 15 have been added to cover use of software over a computer network and provide for limited attribution for the Original Developer. In addition, Exhibit A has been modified to be consistent with Exhibit B.
3
+ *
4
+ * Software distributed under the License is distributed on an “AS IS” basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limitations under the License.
5
+ *
6
+ * The Original Code is manuscripts-frontend.
7
+ *
8
+ * The Original Developer is the Initial Developer. The Initial Developer of the Original Code is Atypon Systems LLC.
9
+ *
10
+ * All portions of the code written by Atypon Systems LLC are Copyright (c) 2022 Atypon Systems LLC. All Rights Reserved.
11
+ */
12
+ import React from 'react';
13
+ export const LinkIcon = () => (React.createElement("svg", { width: "16", height: "16", viewBox: "0 0 16 16", fill: "none", xmlns: "http://www.w3.org/2000/svg" },
14
+ React.createElement("path", { d: "M6.63317 12.1949L4.74782 14.0803C3.9662 14.8619 2.70042 14.8619 1.91945 14.0804C1.13832 13.2993 1.13832 12.0334 1.91929 11.2524L5.69063 7.48109C6.4716 6.70009 7.73751 6.70009 8.51848 7.48109C8.77882 7.74143 9.20095 7.74143 9.46129 7.48109C9.72163 7.22075 9.72163 6.79862 9.46129 6.53828C8.1596 5.23659 6.04951 5.23659 4.74782 6.53828L0.97651 10.3096C-0.325178 11.6113 -0.325178 13.7214 0.97651 15.0231C2.27804 16.3254 4.38829 16.3254 5.69067 15.0231L7.57601 13.1377C7.83635 12.8774 7.83635 12.4552 7.57601 12.1949C7.31567 11.9346 6.89351 11.9346 6.63317 12.1949Z", fill: "#6E6E6E" }),
15
+ React.createElement("path", { d: "M15.0235 0.976266C13.7218 -0.325422 11.6111 -0.325422 10.3094 0.976266L8.04737 3.23827C7.78702 3.49861 7.78702 3.92073 8.04737 4.18108C8.30771 4.44142 8.72984 4.44142 8.99018 4.18108L11.2522 1.91908C12.0331 1.13808 13.2997 1.13808 14.0807 1.91908C14.8617 2.70005 14.8617 3.96595 14.0807 4.74692L9.93271 8.89495C9.15171 9.67595 7.88584 9.67595 7.10487 8.89495C6.84452 8.63461 6.4224 8.63461 6.16205 8.89495C5.90171 9.1553 5.90171 9.57742 6.16205 9.83777C7.46374 11.1395 9.57384 11.1395 10.8755 9.83777L15.0235 5.68977C16.3252 4.38808 16.3252 2.27795 15.0235 0.976266Z", fill: "#6E6E6E" })));
16
+ //# sourceMappingURL=LinkIcon.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"LinkIcon.js","sourceRoot":"","sources":["../../../../../../../src/components/projects/lean-workflow/icons/LinkIcon.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AACH,OAAO,KAAK,MAAM,OAAO,CAAA;AAEzB,MAAM,CAAC,MAAM,QAAQ,GAAa,GAAG,EAAE,CAAC,CACtC,6BACE,KAAK,EAAC,IAAI,EACV,MAAM,EAAC,IAAI,EACX,OAAO,EAAC,WAAW,EACnB,IAAI,EAAC,MAAM,EACX,KAAK,EAAC,4BAA4B;IAElC,8BACE,CAAC,EAAC,ojBAAojB,EACtjB,IAAI,EAAC,SAAS,GACd;IACF,8BACE,CAAC,EAAC,wjBAAwjB,EAC1jB,IAAI,EAAC,SAAS,GACd,CACE,CACP,CAAA"}
@@ -0,0 +1,16 @@
1
+ /*!
2
+ * The contents of this file are subject to the Common Public Attribution License Version 1.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License at https://mpapp-public.gitlab.io/manuscripts-frontend/LICENSE. The License is based on the Mozilla Public License Version 1.1 but Sections 14 and 15 have been added to cover use of software over a computer network and provide for limited attribution for the Original Developer. In addition, Exhibit A has been modified to be consistent with Exhibit B.
3
+ *
4
+ * Software distributed under the License is distributed on an “AS IS” basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limitations under the License.
5
+ *
6
+ * The Original Code is manuscripts-frontend.
7
+ *
8
+ * The Original Developer is the Initial Developer. The Initial Developer of the Original Code is Atypon Systems LLC.
9
+ *
10
+ * All portions of the code written by Atypon Systems LLC are Copyright (c) 2022 Atypon Systems LLC. All Rights Reserved.
11
+ */
12
+ import React from 'react';
13
+ export const TemplateIcon = () => (React.createElement("svg", { width: "16", height: "18", viewBox: "0 0 16 18", fill: "none", xmlns: "http://www.w3.org/2000/svg" },
14
+ React.createElement("rect", { x: "1.25", y: "1.25", width: "13.5", height: "15.5", rx: "1.75", fill: "white", stroke: "#6E6E6E", strokeWidth: "1.5" }),
15
+ React.createElement("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M9 6.5C9 6.08579 8.66421 5.75 8.25 5.75H7.25V4.75C7.25 4.33579 6.91421 4 6.5 4C6.08579 4 5.75 4.33579 5.75 4.75V5.75H4.75C4.33579 5.75 4 6.08579 4 6.5C4 6.91421 4.33579 7.25 4.75 7.25H5.75V8.25C5.75 8.66421 6.08579 9 6.5 9C6.91421 9 7.25 8.66421 7.25 8.25V7.25H8.25C8.66421 7.25 9 6.91421 9 6.5Z", fill: "#6E6E6E" })));
16
+ //# sourceMappingURL=TemplateIcon.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"TemplateIcon.js","sourceRoot":"","sources":["../../../../../../../src/components/projects/lean-workflow/icons/TemplateIcon.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AACH,OAAO,KAAK,MAAM,OAAO,CAAA;AAEzB,MAAM,CAAC,MAAM,YAAY,GAAa,GAAG,EAAE,CAAC,CAC1C,6BACE,KAAK,EAAC,IAAI,EACV,MAAM,EAAC,IAAI,EACX,OAAO,EAAC,WAAW,EACnB,IAAI,EAAC,MAAM,EACX,KAAK,EAAC,4BAA4B;IAElC,8BACE,CAAC,EAAC,MAAM,EACR,CAAC,EAAC,MAAM,EACR,KAAK,EAAC,MAAM,EACZ,MAAM,EAAC,MAAM,EACb,EAAE,EAAC,MAAM,EACT,IAAI,EAAC,OAAO,EACZ,MAAM,EAAC,SAAS,EAChB,WAAW,EAAC,KAAK,GACjB;IACF,8BACE,QAAQ,EAAC,SAAS,EAClB,QAAQ,EAAC,SAAS,EAClB,CAAC,EAAC,ySAAyS,EAC3S,IAAI,EAAC,SAAS,GACd,CACE,CACP,CAAA"}
@@ -0,0 +1,11 @@
1
+ import React, { createContext } from 'react';
2
+ // @ts-ignore
3
+ export const UserContext = createContext({});
4
+ export const UserProvider = ({ lwUser, manuscriptUser, submissionId, children, }) => {
5
+ return (React.createElement(UserContext.Provider, { value: {
6
+ lwUser,
7
+ manuscriptUser,
8
+ submissionId,
9
+ } }, children));
10
+ };
11
+ //# sourceMappingURL=UserProvider.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"UserProvider.js","sourceRoot":"","sources":["../../../../../../../src/components/projects/lean-workflow/provider/UserProvider.tsx"],"names":[],"mappings":"AAYA,OAAO,KAAK,EAAE,EAAE,aAAa,EAAE,MAAM,OAAO,CAAA;AAU5C,aAAa;AACb,MAAM,CAAC,MAAM,WAAW,GAAG,aAAa,CAAgB,EAAE,CAAC,CAAA;AAE3D,MAAM,CAAC,MAAM,YAAY,GAA4B,CAAC,EACpD,MAAM,EACN,cAAc,EACd,YAAY,EACZ,QAAQ,GACT,EAAE,EAAE;IACH,OAAO,CACL,oBAAC,WAAW,CAAC,QAAQ,IACnB,KAAK,EAAE;YACL,MAAM;YACN,cAAc;YACd,YAAY;SACb,IAEA,QAAQ,CACY,CACxB,CAAA;AACH,CAAC,CAAA"}
@@ -0,0 +1,51 @@
1
+ /*!
2
+ * The contents of this file are subject to the Common Public Attribution License Version 1.0 (the “License”); you may not use this file except in compliance with the License. You may obtain a copy of the License at https://mpapp-public.gitlab.io/manuscripts-frontend/LICENSE. The License is based on the Mozilla Public License Version 1.1 but Sections 14 and 15 have been added to cover use of software over a computer network and provide for limited attribution for the Original Developer. In addition, Exhibit A has been modified to be consistent with Exhibit B.
3
+ *
4
+ * Software distributed under the License is distributed on an “AS IS” basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License for the specific language governing rights and limitations under the License.
5
+ *
6
+ * The Original Code is manuscripts-frontend.
7
+ *
8
+ * The Original Developer is the Initial Developer. The Initial Developer of the Original Code is Atypon Systems LLC.
9
+ *
10
+ * All portions of the code written by Atypon Systems LLC are Copyright (c) 2019 Atypon Systems LLC. All Rights Reserved.
11
+ */
12
+ import React from 'react';
13
+ import styled from 'styled-components';
14
+ import { useDropdown } from '../../hooks/use-dropdown';
15
+ import { ArrowDownIcon, ArrowUpIcon, ValidationDangerIcon, ValidationPassedIcon, } from './RequirementsIcons';
16
+ export const RequirementContainer = ({ title, result, children, }) => {
17
+ const failedResults = result.filter((node) => !node.passed && !node.ignored);
18
+ const { toggleOpen, isOpen } = useDropdown(failedResults.length !== 0);
19
+ return (React.createElement(Container, null,
20
+ React.createElement(Data, { onClick: toggleOpen },
21
+ React.createElement(Icon, null, failedResults.length === 0 ? (React.createElement(ValidationPassedIcon, null)) : (React.createElement(ValidationDangerIcon, null))),
22
+ React.createElement(Title, null, title),
23
+ React.createElement(ExpanderButton, null, isOpen ? React.createElement(ArrowUpIcon, null) : React.createElement(ArrowDownIcon, null))),
24
+ isOpen && React.createElement(React.Fragment, null, children)));
25
+ };
26
+ const ExpanderButton = styled.div `
27
+ cursor: pointer;
28
+ `;
29
+ const Container = styled.div `
30
+ padding: 0 0 16px 0;
31
+ border-bottom: 1px solid #f2f2f2;
32
+ margin: 24px 28px 0;
33
+ `;
34
+ const Title = styled.div `
35
+ font-family: Lato;
36
+ font-style: normal;
37
+ font-weight: bold;
38
+ font-size: 16px;
39
+ line-height: 24px;
40
+ flex: 0.96;
41
+ cursor: pointer;
42
+ `;
43
+ const Icon = styled.div `
44
+ display: inline-flex;
45
+ padding: 3px 11px 0 0;
46
+ `;
47
+ const Data = styled.div `
48
+ display: flex;
49
+ padding: 20px 0 0 21px;
50
+ `;
51
+ //# sourceMappingURL=RequirementContainer.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"RequirementContainer.js","sourceRoot":"","sources":["../../../../../src/components/requirements/RequirementContainer.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAGH,OAAO,KAAK,MAAM,OAAO,CAAA;AACzB,OAAO,MAAM,MAAM,mBAAmB,CAAA;AAEtC,OAAO,EAAE,WAAW,EAAE,MAAM,0BAA0B,CAAA;AACtD,OAAO,EACL,aAAa,EACb,WAAW,EACX,oBAAoB,EACpB,oB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