tycho-components 0.19.17 → 0.21.1
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.
- package/dist/{AppConsent → common/AppConsent}/AppConsent.d.ts +1 -1
- package/dist/{AppDropzone → common/AppDropzone}/AppDropzoneBody.js +3 -3
- package/dist/{AppForm → common/AppForm}/AppFormInfo.js +1 -1
- package/dist/{AppKeyboard → common/AppKeyboard}/AppKeyboard.js +2 -2
- package/dist/{AppPicture → common/AppPicture}/AppPicture.js +1 -1
- package/dist/{AppToast → common/AppToast}/AppToast.js +2 -2
- package/dist/common/index.d.ts +34 -0
- package/dist/common/index.js +27 -0
- package/dist/configs/Localization.d.ts +20 -961
- package/dist/configs/Localization.js +42 -47
- package/dist/configs/index.d.ts +27 -0
- package/dist/configs/index.js +16 -0
- package/dist/configs/mock/MockStructs.d.ts +1 -1
- package/dist/configs/store/actions.d.ts +1 -1
- package/dist/configs/store/store.js +1 -1
- package/dist/configs/store/types.d.ts +1 -1
- package/dist/configs/types/Document.d.ts +1 -1
- package/dist/configs/types/Sentence.d.ts +1 -1
- package/dist/cytoscape-context-menus.d.ts +1 -1
- package/dist/cytoscape-context-menus.js +1 -1
- package/dist/{Comments → features/Comments}/CommentAdd.d.ts +1 -1
- package/dist/{Comments → features/Comments}/CommentAdd.js +3 -3
- package/dist/{Comments → features/Comments}/CommentInfo.js +3 -3
- package/dist/{Comments/types → features/Comments}/CommentService.d.ts +1 -1
- package/dist/{Comments → features/Comments}/Comments.js +5 -5
- package/dist/{Comments → features/Comments}/HeaderNotifications/HeaderNotifications.js +2 -2
- package/dist/{Parameters → features/Parameters}/Parameters.js +1 -1
- package/dist/{Participants → features/Participants}/ParticipantCreate/ParticipantCreate.js +4 -4
- package/dist/{Participants → features/Participants}/ParticipantRemove/ParticipantRemove.js +4 -4
- package/dist/{Participants/types → features/Participants}/ParticipantService.d.ts +2 -2
- package/dist/{Participants → features/Participants}/Participants.js +3 -3
- package/dist/{Participants → features/Participants}/types/Participant.d.ts +1 -1
- package/dist/features/SentenceSplit/SentenceSplit.d.ts +28 -0
- package/dist/features/SentenceSplit/SentenceSplit.js +180 -0
- package/dist/features/SentenceSplit/SentenceSplitAudio/SentenceSplitAudioStep.d.ts +9 -0
- package/dist/features/SentenceSplit/SentenceSplitAudio/SentenceSplitAudioStep.js +38 -0
- package/dist/features/SentenceSplit/SentenceSplitAudio/index.d.ts +2 -0
- package/dist/features/SentenceSplit/SentenceSplitAudio/index.js +2 -0
- package/dist/features/SentenceSplit/SentenceSplitAudio/style.scss +29 -0
- package/dist/features/SentenceSplit/SentenceSplitChoose/SentenceSplitChoose.d.ts +10 -0
- package/dist/features/SentenceSplit/SentenceSplitChoose/SentenceSplitChoose.js +23 -0
- package/dist/features/SentenceSplit/SentenceSplitChoose/index.d.ts +2 -0
- package/dist/features/SentenceSplit/SentenceSplitChoose/index.js +2 -0
- package/dist/features/SentenceSplit/SentenceSplitChoose/style.scss +25 -0
- package/dist/features/SentenceSplit/SentenceSplitCommentUtils.d.ts +21 -0
- package/dist/features/SentenceSplit/SentenceSplitCommentUtils.js +77 -0
- package/dist/features/SentenceSplit/SentenceSplitComments/SentenceSplitCommentBlock.d.ts +7 -0
- package/dist/features/SentenceSplit/SentenceSplitComments/SentenceSplitCommentBlock.js +6 -0
- package/dist/features/SentenceSplit/SentenceSplitComments/SentenceSplitComments.d.ts +8 -0
- package/dist/features/SentenceSplit/SentenceSplitComments/SentenceSplitComments.js +37 -0
- package/dist/features/SentenceSplit/SentenceSplitComments/SentenceSplitCommentsStep.d.ts +11 -0
- package/dist/features/SentenceSplit/SentenceSplitComments/SentenceSplitCommentsStep.js +72 -0
- package/dist/features/SentenceSplit/SentenceSplitComments/SentenceSplitCommentsWords.d.ts +9 -0
- package/dist/features/SentenceSplit/SentenceSplitComments/SentenceSplitCommentsWords.js +15 -0
- package/dist/features/SentenceSplit/SentenceSplitComments/index.d.ts +2 -0
- package/dist/features/SentenceSplit/SentenceSplitComments/index.js +2 -0
- package/dist/features/SentenceSplit/SentenceSplitComments/style.scss +126 -0
- package/dist/features/SentenceSplit/SentenceSplitPreview/SentenceSplitPreview.d.ts +10 -0
- package/dist/features/SentenceSplit/SentenceSplitPreview/SentenceSplitPreview.js +10 -0
- package/dist/features/SentenceSplit/SentenceSplitPreview/SentenceSplitPreviewStep.d.ts +11 -0
- package/dist/features/SentenceSplit/SentenceSplitPreview/SentenceSplitPreviewStep.js +24 -0
- package/dist/features/SentenceSplit/SentenceSplitPreview/index.d.ts +2 -0
- package/dist/features/SentenceSplit/SentenceSplitPreview/index.js +2 -0
- package/dist/features/SentenceSplit/SentenceSplitPreview/style.scss +24 -0
- package/dist/features/SentenceSplit/SentenceSplitService.d.ts +13 -0
- package/dist/features/SentenceSplit/SentenceSplitService.js +13 -0
- package/dist/features/SentenceSplit/SentenceSplitTranslations/SentenceSplitTranslations.d.ts +12 -0
- package/dist/features/SentenceSplit/SentenceSplitTranslations/SentenceSplitTranslations.js +15 -0
- package/dist/features/SentenceSplit/SentenceSplitTranslations/SentenceSplitTranslationsStep.d.ts +10 -0
- package/dist/features/SentenceSplit/SentenceSplitTranslations/SentenceSplitTranslationsStep.js +8 -0
- package/dist/features/SentenceSplit/SentenceSplitTranslations/index.d.ts +2 -0
- package/dist/features/SentenceSplit/SentenceSplitTranslations/index.js +2 -0
- package/dist/features/SentenceSplit/SentenceSplitTranslations/style.scss +23 -0
- package/dist/features/SentenceSplit/SentenceSplitUtils.d.ts +6 -0
- package/dist/features/SentenceSplit/SentenceSplitUtils.js +17 -0
- package/dist/features/SentenceSplit/index.d.ts +2 -0
- package/dist/features/SentenceSplit/index.js +2 -0
- package/dist/features/SentenceSplit/localization/SentenceSplitTexts.d.ts +107 -0
- package/dist/features/SentenceSplit/localization/SentenceSplitTexts.js +107 -0
- package/dist/features/SentenceSplit/style.scss +173 -0
- package/dist/features/SentenceSplit/types/Language.d.ts +6 -0
- package/dist/features/SentenceSplit/types/SentenceSplitRequest.d.ts +20 -0
- package/dist/features/SentenceSplit/types/SentenceSplitRequest.js +16 -0
- package/dist/{SentenceView → features/SentenceView}/SentenceEditionTiers.d.ts +1 -1
- package/dist/{SentenceView → features/SentenceView}/SentenceEditionTiers.js +2 -2
- package/dist/{SentenceView → features/SentenceView}/SentenceMorphemeTags.d.ts +1 -1
- package/dist/{SentenceView → features/SentenceView}/SentenceMorphemeTags.js +1 -1
- package/dist/{SentenceView → features/SentenceView}/SentenceMorphemeTiers.d.ts +2 -2
- package/dist/{SentenceView → features/SentenceView}/SentenceMorphemeTiers.js +1 -1
- package/dist/{SentenceView → features/SentenceView}/SentenceTags.d.ts +1 -1
- package/dist/{SentenceView → features/SentenceView}/SentenceTags.js +1 -1
- package/dist/{SentenceView → features/SentenceView}/SentenceValues.d.ts +1 -1
- package/dist/{SentenceView → features/SentenceView}/SentenceValues.js +1 -1
- package/dist/{SentenceView → features/SentenceView}/SentenceView.d.ts +2 -2
- package/dist/{SentenceView → features/SentenceView}/SentenceView.js +1 -1
- package/dist/{SentenceView → features/SentenceView}/SentenceWordTiers.d.ts +2 -2
- package/dist/{SentenceView → features/SentenceView}/SentenceWordTiers.js +1 -1
- package/dist/{TreeView → features/TreeView}/TreeView.d.ts +1 -1
- package/dist/{TreeView → features/TreeView}/TreeView.js +3 -3
- package/dist/{TreeView → features/TreeView}/TreeViewSearch/TreeViewSearch.d.ts +1 -1
- package/dist/{TreeView → features/TreeView}/TreeViewSearch/TreeViewSearch.js +1 -1
- package/dist/{TreeView → features/TreeView}/cytoscape/CytoscapeTreeConverter.d.ts +1 -1
- package/dist/features/TreeView/cytoscape/NodeCalculation.js +1 -0
- package/dist/{TreeView → features/TreeView}/cytoscape/SyntreesCytoscape.d.ts +1 -1
- package/dist/features/index.d.ts +24 -0
- package/dist/features/index.js +17 -0
- package/dist/functions/FormUtils.d.ts +1 -1
- package/dist/functions/index.d.ts +10 -0
- package/dist/functions/index.js +9 -0
- package/dist/index.d.ts +5 -103
- package/dist/index.js +5 -77
- package/dist/{Base → shell/Base}/ErrorFound.js +1 -1
- package/dist/{Base → shell/Base}/Logout.js +2 -2
- package/dist/{Base → shell/Base}/Unauthorized.js +2 -2
- package/dist/{Header → shell/Header}/HeaderApps/HeaderApps.d.ts +3 -3
- package/dist/{Header → shell/Header}/HeaderApps/HeaderApps.js +24 -24
- package/dist/{Header → shell/Header}/HeaderButtons/HeaderButtons.js +5 -5
- package/dist/{Header → shell/Header}/HeaderCorpora/HeaderCorpora.js +3 -3
- package/dist/{Header → shell/Header}/HeaderCorpora/HeaderCorpus.js +2 -2
- package/dist/{Header → shell/Header}/HeaderUser/HeaderUser.js +1 -1
- package/dist/{Header → shell/Header}/HelpButton/HelpModal.js +3 -3
- package/dist/{Header → shell/Header}/types/App.js +1 -1
- package/dist/{Header → shell/Header}/types/CorpusService.d.ts +1 -1
- package/dist/{Header → shell/Header}/types/CorpusService.js +2 -2
- package/dist/shell/index.d.ts +16 -0
- package/dist/shell/index.js +13 -0
- package/package.json +33 -3
- /package/dist/{AppAnalytics → common/AppAnalytics}/AppAnalytics.d.ts +0 -0
- /package/dist/{AppAnalytics → common/AppAnalytics}/AppAnalytics.js +0 -0
- /package/dist/{AppAnalytics → common/AppAnalytics}/index.d.ts +0 -0
- /package/dist/{AppAnalytics → common/AppAnalytics}/index.js +0 -0
- /package/dist/{AppCard → common/AppCard}/AppCard.d.ts +0 -0
- /package/dist/{AppCard → common/AppCard}/AppCard.js +0 -0
- /package/dist/{AppCard → common/AppCard}/index.d.ts +0 -0
- /package/dist/{AppCard → common/AppCard}/index.js +0 -0
- /package/dist/{AppCard → common/AppCard}/style.scss +0 -0
- /package/dist/{AppClipboard → common/AppClipboard}/AppClipboard.d.ts +0 -0
- /package/dist/{AppClipboard → common/AppClipboard}/AppClipboard.js +0 -0
- /package/dist/{AppClipboard → common/AppClipboard}/index.d.ts +0 -0
- /package/dist/{AppClipboard → common/AppClipboard}/index.js +0 -0
- /package/dist/{AppColorpicker → common/AppColorpicker}/AppColorpicker.d.ts +0 -0
- /package/dist/{AppColorpicker → common/AppColorpicker}/AppColorpicker.js +0 -0
- /package/dist/{AppColorpicker → common/AppColorpicker}/index.d.ts +0 -0
- /package/dist/{AppColorpicker → common/AppColorpicker}/index.js +0 -0
- /package/dist/{AppColorpicker → common/AppColorpicker}/style.scss +0 -0
- /package/dist/{AppConsent → common/AppConsent}/AppConsent.js +0 -0
- /package/dist/{AppConsent → common/AppConsent}/index.d.ts +0 -0
- /package/dist/{AppConsent → common/AppConsent}/index.js +0 -0
- /package/dist/{AppCopyText → common/AppCopyText}/AppCopyText.d.ts +0 -0
- /package/dist/{AppCopyText → common/AppCopyText}/AppCopyText.js +0 -0
- /package/dist/{AppCopyText → common/AppCopyText}/index.d.ts +0 -0
- /package/dist/{AppCopyText → common/AppCopyText}/index.js +0 -0
- /package/dist/{AppCopyText → common/AppCopyText}/styles.scss +0 -0
- /package/dist/{AppDropzone → common/AppDropzone}/AppDropzone.d.ts +0 -0
- /package/dist/{AppDropzone → common/AppDropzone}/AppDropzone.js +0 -0
- /package/dist/{AppDropzone → common/AppDropzone}/AppDropzoneBody.d.ts +0 -0
- /package/dist/{AppDropzone → common/AppDropzone}/UploadService.d.ts +0 -0
- /package/dist/{AppDropzone → common/AppDropzone}/UploadService.js +0 -0
- /package/dist/{AppDropzone → common/AppDropzone}/UploadedFile.d.ts +0 -0
- /package/dist/{AppDropzone → common/AppDropzone}/UploadedFile.js +0 -0
- /package/dist/{AppDropzone → common/AppDropzone}/index.d.ts +0 -0
- /package/dist/{AppDropzone → common/AppDropzone}/index.js +0 -0
- /package/dist/{AppDropzone → common/AppDropzone}/style.scss +0 -0
- /package/dist/{AppDropzoneLocal → common/AppDropzoneLocal}/AppDropzoneBodyLocal.d.ts +0 -0
- /package/dist/{AppDropzoneLocal → common/AppDropzoneLocal}/AppDropzoneBodyLocal.js +0 -0
- /package/dist/{AppDropzoneLocal → common/AppDropzoneLocal}/AppDropzoneLocal.d.ts +0 -0
- /package/dist/{AppDropzoneLocal → common/AppDropzoneLocal}/AppDropzoneLocal.js +0 -0
- /package/dist/{AppDropzoneLocal → common/AppDropzoneLocal}/UploadedFileLocal.d.ts +0 -0
- /package/dist/{AppDropzoneLocal → common/AppDropzoneLocal}/UploadedFileLocal.js +0 -0
- /package/dist/{AppDropzoneLocal → common/AppDropzoneLocal}/index.d.ts +0 -0
- /package/dist/{AppDropzoneLocal → common/AppDropzoneLocal}/index.js +0 -0
- /package/dist/{AppDropzoneLocal → common/AppDropzoneLocal}/style.scss +0 -0
- /package/dist/{AppEditable → common/AppEditable}/AppEditable.d.ts +0 -0
- /package/dist/{AppEditable → common/AppEditable}/AppEditable.js +0 -0
- /package/dist/{AppEditable → common/AppEditable}/AppEditableField.d.ts +0 -0
- /package/dist/{AppEditable → common/AppEditable}/AppEditableField.js +0 -0
- /package/dist/{AppEditable → common/AppEditable}/FormField.d.ts +0 -0
- /package/dist/{AppEditable → common/AppEditable}/FormField.js +0 -0
- /package/dist/{AppEditable → common/AppEditable}/FormFieldOption.d.ts +0 -0
- /package/dist/{AppEditable → common/AppEditable}/FormFieldOption.js +0 -0
- /package/dist/{AppEditable → common/AppEditable}/index.d.ts +0 -0
- /package/dist/{AppEditable → common/AppEditable}/index.js +0 -0
- /package/dist/{AppEditable → common/AppEditable}/style.scss +0 -0
- /package/dist/{AppForm → common/AppForm}/AppForm.d.ts +0 -0
- /package/dist/{AppForm → common/AppForm}/AppForm.js +0 -0
- /package/dist/{AppForm → common/AppForm}/AppFormField.d.ts +0 -0
- /package/dist/{AppForm → common/AppForm}/AppFormField.js +0 -0
- /package/dist/{AppForm → common/AppForm}/AppFormInfo.d.ts +0 -0
- /package/dist/{AppForm → common/AppForm}/index.d.ts +0 -0
- /package/dist/{AppForm → common/AppForm}/index.js +0 -0
- /package/dist/{AppForm → common/AppForm}/style.scss +0 -0
- /package/dist/{AppKeyboard → common/AppKeyboard}/AppKeyboard.d.ts +0 -0
- /package/dist/{AppKeyboard → common/AppKeyboard}/index.d.ts +0 -0
- /package/dist/{AppKeyboard → common/AppKeyboard}/index.js +0 -0
- /package/dist/{AppLoading → common/AppLoading}/AppLoading.d.ts +0 -0
- /package/dist/{AppLoading → common/AppLoading}/AppLoading.js +0 -0
- /package/dist/{AppLoading → common/AppLoading}/index.d.ts +0 -0
- /package/dist/{AppLoading → common/AppLoading}/index.js +0 -0
- /package/dist/{AppLoading → common/AppLoading}/style.scss +0 -0
- /package/dist/{AppModal → common/AppModal}/AppModal.d.ts +0 -0
- /package/dist/{AppModal → common/AppModal}/AppModal.js +0 -0
- /package/dist/{AppModal → common/AppModal}/AppModalConfirm.d.ts +0 -0
- /package/dist/{AppModal → common/AppModal}/AppModalConfirm.js +0 -0
- /package/dist/{AppModal → common/AppModal}/AppModalRemove.d.ts +0 -0
- /package/dist/{AppModal → common/AppModal}/AppModalRemove.js +0 -0
- /package/dist/{AppModal → common/AppModal}/AppModalUtils.d.ts +0 -0
- /package/dist/{AppModal → common/AppModal}/AppModalUtils.js +0 -0
- /package/dist/{AppModal → common/AppModal}/index.d.ts +0 -0
- /package/dist/{AppModal → common/AppModal}/index.js +0 -0
- /package/dist/{AppModal → common/AppModal}/style.scss +0 -0
- /package/dist/{AppPagination → common/AppPagination}/AppPagination.d.ts +0 -0
- /package/dist/{AppPagination → common/AppPagination}/AppPagination.js +0 -0
- /package/dist/{AppPagination → common/AppPagination}/index.d.ts +0 -0
- /package/dist/{AppPagination → common/AppPagination}/index.js +0 -0
- /package/dist/{AppPagination → common/AppPagination}/styles.scss +0 -0
- /package/dist/{AppPicture → common/AppPicture}/AppPicture.d.ts +0 -0
- /package/dist/{AppPicture → common/AppPicture}/index.d.ts +0 -0
- /package/dist/{AppPicture → common/AppPicture}/index.js +0 -0
- /package/dist/{AppPicture → common/AppPicture}/style.scss +0 -0
- /package/dist/{AppPlaceholder → common/AppPlaceholder}/AppPlaceholder.d.ts +0 -0
- /package/dist/{AppPlaceholder → common/AppPlaceholder}/AppPlaceholder.js +0 -0
- /package/dist/{AppPlaceholder → common/AppPlaceholder}/index.d.ts +0 -0
- /package/dist/{AppPlaceholder → common/AppPlaceholder}/index.js +0 -0
- /package/dist/{AppPlaceholder → common/AppPlaceholder}/style.scss +0 -0
- /package/dist/{AppReplaceAll → common/AppReplaceAll}/AppReplaceAll.d.ts +0 -0
- /package/dist/{AppReplaceAll → common/AppReplaceAll}/AppReplaceAll.js +0 -0
- /package/dist/{AppReplaceAll → common/AppReplaceAll}/index.d.ts +0 -0
- /package/dist/{AppReplaceAll → common/AppReplaceAll}/index.js +0 -0
- /package/dist/{AppReplaceAll → common/AppReplaceAll}/style.scss +0 -0
- /package/dist/{AppTable → common/AppTable}/AppTable.d.ts +0 -0
- /package/dist/{AppTable → common/AppTable}/AppTable.js +0 -0
- /package/dist/{AppTable → common/AppTable}/AppTableList.d.ts +0 -0
- /package/dist/{AppTable → common/AppTable}/AppTableList.js +0 -0
- /package/dist/{AppTable → common/AppTable}/AppTableTheme.d.ts +0 -0
- /package/dist/{AppTable → common/AppTable}/AppTableTheme.js +0 -0
- /package/dist/{AppTable → common/AppTable}/AppTableUtils.d.ts +0 -0
- /package/dist/{AppTable → common/AppTable}/AppTableUtils.js +0 -0
- /package/dist/{AppTable → common/AppTable}/index.d.ts +0 -0
- /package/dist/{AppTable → common/AppTable}/index.js +0 -0
- /package/dist/{AppTable → common/AppTable}/styles.scss +0 -0
- /package/dist/{AppTable → common/AppTable}/types/AppPage.d.ts +0 -0
- /package/dist/{AppTable → common/AppTable}/types/AppPage.js +0 -0
- /package/dist/{AppTable → common/AppTable}/types/AppPageable.d.ts +0 -0
- /package/dist/{AppTable → common/AppTable}/types/AppPageable.js +0 -0
- /package/dist/{AppToast → common/AppToast}/AppToast.d.ts +0 -0
- /package/dist/{AppToast → common/AppToast}/ToastMessage.d.ts +0 -0
- /package/dist/{AppToast → common/AppToast}/ToastMessage.js +0 -0
- /package/dist/{AppToast → common/AppToast}/index.d.ts +0 -0
- /package/dist/{AppToast → common/AppToast}/index.js +0 -0
- /package/dist/{AppToast → common/AppToast}/style.scss +0 -0
- /package/dist/{Comments → features/Comments}/CommentInfo.d.ts +0 -0
- /package/dist/{Comments/types → features/Comments}/CommentService.js +0 -0
- /package/dist/{Comments → features/Comments}/Comments.d.ts +0 -0
- /package/dist/{Comments → features/Comments}/HeaderNotifications/HeaderNotifications.d.ts +0 -0
- /package/dist/{Comments → features/Comments}/HeaderNotifications/index.d.ts +0 -0
- /package/dist/{Comments → features/Comments}/HeaderNotifications/index.js +0 -0
- /package/dist/{Comments → features/Comments}/HeaderNotifications/style.scss +0 -0
- /package/dist/{Comments → features/Comments}/index.d.ts +0 -0
- /package/dist/{Comments → features/Comments}/index.js +0 -0
- /package/dist/{Comments → features/Comments}/style.scss +0 -0
- /package/dist/{Comments → features/Comments}/types/Comment.d.ts +0 -0
- /package/dist/{Comments → features/Comments}/types/Comment.js +0 -0
- /package/dist/{CytoscapeMenu → features/CytoscapeMenu}/CytoscapeMenuCanvas.d.ts +0 -0
- /package/dist/{CytoscapeMenu → features/CytoscapeMenu}/CytoscapeMenuCanvas.js +0 -0
- /package/dist/{CytoscapeMenu → features/CytoscapeMenu}/constants.d.ts +0 -0
- /package/dist/{CytoscapeMenu → features/CytoscapeMenu}/constants.js +0 -0
- /package/dist/{CytoscapeMenu → features/CytoscapeMenu}/context-menu.d.ts +0 -0
- /package/dist/{CytoscapeMenu → features/CytoscapeMenu}/context-menu.js +0 -0
- /package/dist/{CytoscapeMenu → features/CytoscapeMenu}/cytoscape-context-menus.d.ts +0 -0
- /package/dist/{CytoscapeMenu → features/CytoscapeMenu}/cytoscape-context-menus.js +0 -0
- /package/dist/{CytoscapeMenu → features/CytoscapeMenu}/index.d.ts +0 -0
- /package/dist/{CytoscapeMenu → features/CytoscapeMenu}/index.js +0 -0
- /package/dist/{CytoscapeMenu → features/CytoscapeMenu}/style.scss +0 -0
- /package/dist/{CytoscapeMenu → features/CytoscapeMenu}/utils.d.ts +0 -0
- /package/dist/{CytoscapeMenu → features/CytoscapeMenu}/utils.js +0 -0
- /package/dist/{Parameters → features/Parameters}/Parameters.d.ts +0 -0
- /package/dist/{Parameters → features/Parameters}/index.d.ts +0 -0
- /package/dist/{Parameters → features/Parameters}/index.js +0 -0
- /package/dist/{Parameters → features/Parameters}/style.scss +0 -0
- /package/dist/{Participants → features/Participants}/ParticipantCreate/ParticipantCreate.d.ts +0 -0
- /package/dist/{Participants → features/Participants}/ParticipantCreate/index.d.ts +0 -0
- /package/dist/{Participants → features/Participants}/ParticipantCreate/index.js +0 -0
- /package/dist/{Participants → features/Participants}/ParticipantRemove/ParticipantRemove.d.ts +0 -0
- /package/dist/{Participants → features/Participants}/ParticipantRemove/index.d.ts +0 -0
- /package/dist/{Participants → features/Participants}/ParticipantRemove/index.js +0 -0
- /package/dist/{Participants → features/Participants}/ParticipantRemove/style.scss +0 -0
- /package/dist/{Participants/types → features/Participants}/ParticipantService.js +0 -0
- /package/dist/{Participants → features/Participants}/Participants.d.ts +0 -0
- /package/dist/{Participants → features/Participants}/index.d.ts +0 -0
- /package/dist/{Participants → features/Participants}/index.js +0 -0
- /package/dist/{Participants → features/Participants}/style.scss +0 -0
- /package/dist/{Participants → features/Participants}/types/Participant.js +0 -0
- /package/dist/{TreeView/cytoscape/NodeBounds.js → features/SentenceSplit/types/Language.js} +0 -0
- /package/dist/{SentenceView → features/SentenceView}/index.d.ts +0 -0
- /package/dist/{SentenceView → features/SentenceView}/index.js +0 -0
- /package/dist/{SentenceView → features/SentenceView}/style.scss +0 -0
- /package/dist/{TreeView → features/TreeView}/TreeViewSearch/TreeViewSearchField.d.ts +0 -0
- /package/dist/{TreeView → features/TreeView}/TreeViewSearch/TreeViewSearchField.js +0 -0
- /package/dist/{TreeView → features/TreeView}/TreeViewSearch/style.scss +0 -0
- /package/dist/{TreeView → features/TreeView}/cytoscape/Configuration.d.ts +0 -0
- /package/dist/{TreeView → features/TreeView}/cytoscape/Configuration.js +0 -0
- /package/dist/{TreeView → features/TreeView}/cytoscape/CytoscapePositionCalculator.d.ts +0 -0
- /package/dist/{TreeView → features/TreeView}/cytoscape/CytoscapePositionCalculator.js +0 -0
- /package/dist/{TreeView → features/TreeView}/cytoscape/CytoscapeStylesheet.d.ts +0 -0
- /package/dist/{TreeView → features/TreeView}/cytoscape/CytoscapeStylesheet.js +0 -0
- /package/dist/{TreeView → features/TreeView}/cytoscape/CytoscapeTreeConverter.js +0 -0
- /package/dist/{TreeView → features/TreeView}/cytoscape/NodeBounds.d.ts +0 -0
- /package/dist/{TreeView/cytoscape/NodeCalculation.js → features/TreeView/cytoscape/NodeBounds.js} +0 -0
- /package/dist/{TreeView → features/TreeView}/cytoscape/NodeCalculation.d.ts +0 -0
- /package/dist/{TreeView → features/TreeView}/cytoscape/NormalizedPosition.d.ts +0 -0
- /package/dist/{TreeView → features/TreeView}/cytoscape/NormalizedPosition.js +0 -0
- /package/dist/{TreeView → features/TreeView}/cytoscape/SyntreesCytoscape.js +0 -0
- /package/dist/{TreeView → features/TreeView}/cytoscape/TreeLayout.d.ts +0 -0
- /package/dist/{TreeView → features/TreeView}/cytoscape/TreeLayout.js +0 -0
- /package/dist/{TreeView → features/TreeView}/index.d.ts +0 -0
- /package/dist/{TreeView → features/TreeView}/index.js +0 -0
- /package/dist/{TreeView → features/TreeView}/style.scss +0 -0
- /package/dist/{Base → shell/Base}/ErrorBoundary.d.ts +0 -0
- /package/dist/{Base → shell/Base}/ErrorBoundary.js +0 -0
- /package/dist/{Base → shell/Base}/ErrorFound.d.ts +0 -0
- /package/dist/{Base → shell/Base}/Login.d.ts +0 -0
- /package/dist/{Base → shell/Base}/Login.js +0 -0
- /package/dist/{Base → shell/Base}/Logout.d.ts +0 -0
- /package/dist/{Base → shell/Base}/NotFound.d.ts +0 -0
- /package/dist/{Base → shell/Base}/NotFound.js +0 -0
- /package/dist/{Base → shell/Base}/Unauthorized.d.ts +0 -0
- /package/dist/{Base → shell/Base}/logo.png +0 -0
- /package/dist/{Base → shell/Base}/style.scss +0 -0
- /package/dist/{Header → shell/Header}/Header.d.ts +0 -0
- /package/dist/{Header → shell/Header}/Header.js +0 -0
- /package/dist/{Header → shell/Header}/HeaderApps/index.d.ts +0 -0
- /package/dist/{Header → shell/Header}/HeaderApps/index.js +0 -0
- /package/dist/{Header → shell/Header}/HeaderApps/logo.png +0 -0
- /package/dist/{Header → shell/Header}/HeaderApps/style.scss +0 -0
- /package/dist/{Header → shell/Header}/HeaderApps/youtube.png +0 -0
- /package/dist/{Header → shell/Header}/HeaderButtons/HeaderButtons.d.ts +0 -0
- /package/dist/{Header → shell/Header}/HeaderButtons/index.d.ts +0 -0
- /package/dist/{Header → shell/Header}/HeaderButtons/index.js +0 -0
- /package/dist/{Header → shell/Header}/HeaderButtons/styles.scss +0 -0
- /package/dist/{Header → shell/Header}/HeaderCorpora/HeaderCorpora.d.ts +0 -0
- /package/dist/{Header → shell/Header}/HeaderCorpora/HeaderCorpus.d.ts +0 -0
- /package/dist/{Header → shell/Header}/HeaderCorpora/index.d.ts +0 -0
- /package/dist/{Header → shell/Header}/HeaderCorpora/index.js +0 -0
- /package/dist/{Header → shell/Header}/HeaderCorpora/style.scss +0 -0
- /package/dist/{Header → shell/Header}/HeaderUser/HeaderUser.d.ts +0 -0
- /package/dist/{Header → shell/Header}/HeaderUser/index.d.ts +0 -0
- /package/dist/{Header → shell/Header}/HeaderUser/index.js +0 -0
- /package/dist/{Header → shell/Header}/HeaderUser/style.scss +0 -0
- /package/dist/{Header → shell/Header}/HelpButton/HelpButton.d.ts +0 -0
- /package/dist/{Header → shell/Header}/HelpButton/HelpButton.js +0 -0
- /package/dist/{Header → shell/Header}/HelpButton/HelpModal.d.ts +0 -0
- /package/dist/{Header → shell/Header}/HelpButton/index.d.ts +0 -0
- /package/dist/{Header → shell/Header}/HelpButton/index.js +0 -0
- /package/dist/{Header → shell/Header}/HelpButton/style.scss +0 -0
- /package/dist/{Header → shell/Header}/index.d.ts +0 -0
- /package/dist/{Header → shell/Header}/index.js +0 -0
- /package/dist/{Header → shell/Header}/styles.scss +0 -0
- /package/dist/{Header → shell/Header}/types/App.d.ts +0 -0
- /package/dist/{LanguageSelector → shell/LanguageSelector}/LanguageSelector.d.ts +0 -0
- /package/dist/{LanguageSelector → shell/LanguageSelector}/LanguageSelector.js +0 -0
- /package/dist/{LanguageSelector → shell/LanguageSelector}/index.d.ts +0 -0
- /package/dist/{LanguageSelector → shell/LanguageSelector}/index.js +0 -0
- /package/dist/{LanguageSelector → shell/LanguageSelector}/styles.scss +0 -0
- /package/dist/{VirtualKeyboard → shell/VirtualKeyboard}/KeyboardCustomLayout.d.ts +0 -0
- /package/dist/{VirtualKeyboard → shell/VirtualKeyboard}/KeyboardCustomLayout.js +0 -0
- /package/dist/{VirtualKeyboard → shell/VirtualKeyboard}/VirtualKeyboard.d.ts +0 -0
- /package/dist/{VirtualKeyboard → shell/VirtualKeyboard}/VirtualKeyboard.js +0 -0
- /package/dist/{VirtualKeyboard → shell/VirtualKeyboard}/index.d.ts +0 -0
- /package/dist/{VirtualKeyboard → shell/VirtualKeyboard}/index.js +0 -0
- /package/dist/{VirtualKeyboard → shell/VirtualKeyboard}/style.scss +0 -0
|
@@ -2,67 +2,62 @@ import i18n from 'i18next';
|
|
|
2
2
|
import languageDetector from 'i18next-browser-languagedetector';
|
|
3
3
|
import { initReactI18next } from 'react-i18next';
|
|
4
4
|
import { BaseTexts } from './localization/BaseTexts';
|
|
5
|
-
import { CommentsTexts } from './localization/CommentsTexts';
|
|
6
5
|
import { CommonTexts } from './localization/CommonTexts';
|
|
7
6
|
import { ConsentTexts } from './localization/ConsentTexts';
|
|
8
7
|
import { HeaderAppTexts } from './localization/HeaderAppTexts';
|
|
9
8
|
import { HeaderTexts } from './localization/HeaderTexts';
|
|
10
9
|
import { HelpTexts } from './localization/HelpTexts';
|
|
10
|
+
import { UploadTexts } from './localization/UploadTexts';
|
|
11
|
+
import { CommentsTexts } from './localization/CommentsTexts';
|
|
11
12
|
import { ParticipantsTexts } from './localization/ParticipantsTexts';
|
|
12
13
|
import { SentenceTexts } from './localization/SentenceTexts';
|
|
13
14
|
import { TreeTexts } from './localization/TreeTexts';
|
|
14
|
-
import { UploadTexts } from './localization/UploadTexts';
|
|
15
15
|
import { ParametersTexts } from './localization/ParametersTexts';
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
upload: UploadTexts['pt-BR'],
|
|
41
|
-
help: HelpTexts['pt-BR'],
|
|
42
|
-
consent: ConsentTexts['pt-BR'],
|
|
43
|
-
parameters: ParametersTexts['pt-BR'],
|
|
44
|
-
},
|
|
45
|
-
it: {
|
|
46
|
-
base: BaseTexts.it,
|
|
47
|
-
comments: CommentsTexts.it,
|
|
48
|
-
common: CommonTexts.it,
|
|
49
|
-
header: HeaderTexts.it,
|
|
50
|
-
'header-app': HeaderAppTexts.it,
|
|
51
|
-
participants: ParticipantsTexts.it,
|
|
52
|
-
sentence: SentenceTexts.it,
|
|
53
|
-
tree: TreeTexts.it,
|
|
54
|
-
upload: UploadTexts.it,
|
|
55
|
-
help: HelpTexts.it,
|
|
56
|
-
consent: ConsentTexts.it,
|
|
57
|
-
parameters: ParametersTexts.it,
|
|
58
|
-
},
|
|
16
|
+
import { SentenceSplitTexts } from '../features/SentenceSplit/localization/SentenceSplitTexts';
|
|
17
|
+
function buildResources(namespaces) {
|
|
18
|
+
return {
|
|
19
|
+
en: Object.fromEntries(Object.entries(namespaces).map(([key, texts]) => [key, texts.en])),
|
|
20
|
+
'pt-BR': Object.fromEntries(Object.entries(namespaces).map(([key, texts]) => [key, texts['pt-BR']])),
|
|
21
|
+
it: Object.fromEntries(Object.entries(namespaces).map(([key, texts]) => [key, texts.it])),
|
|
22
|
+
};
|
|
23
|
+
}
|
|
24
|
+
const CORE_NAMESPACES = {
|
|
25
|
+
base: BaseTexts,
|
|
26
|
+
common: CommonTexts,
|
|
27
|
+
header: HeaderTexts,
|
|
28
|
+
'header-app': HeaderAppTexts,
|
|
29
|
+
upload: UploadTexts,
|
|
30
|
+
help: HelpTexts,
|
|
31
|
+
consent: ConsentTexts,
|
|
32
|
+
};
|
|
33
|
+
const FEATURE_NAMESPACES = {
|
|
34
|
+
comments: CommentsTexts,
|
|
35
|
+
participants: ParticipantsTexts,
|
|
36
|
+
tree: TreeTexts,
|
|
37
|
+
sentence: SentenceTexts,
|
|
38
|
+
parameters: ParametersTexts,
|
|
39
|
+
sentenceSplit: SentenceSplitTexts,
|
|
59
40
|
};
|
|
60
|
-
export
|
|
41
|
+
export const commonResources = buildResources(CORE_NAMESPACES);
|
|
42
|
+
export const featureResources = buildResources(FEATURE_NAMESPACES);
|
|
43
|
+
export function mergeResources(core = commonResources, features = featureResources) {
|
|
44
|
+
const locales = ['en', 'pt-BR', 'it'];
|
|
45
|
+
return Object.fromEntries(locales.map((locale) => [
|
|
46
|
+
locale,
|
|
47
|
+
{
|
|
48
|
+
...core[locale],
|
|
49
|
+
...features[locale],
|
|
50
|
+
},
|
|
51
|
+
]));
|
|
52
|
+
}
|
|
53
|
+
export function commonLocalization(includeFeatures = true) {
|
|
61
54
|
i18n
|
|
62
55
|
.use(initReactI18next)
|
|
63
56
|
.use(languageDetector)
|
|
64
57
|
.init({
|
|
65
|
-
resources:
|
|
58
|
+
resources: includeFeatures
|
|
59
|
+
? mergeResources()
|
|
60
|
+
: commonResources,
|
|
66
61
|
fallbackLng: 'en',
|
|
67
62
|
defaultNS: 'common',
|
|
68
63
|
interpolation: {
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
export { CommonProvider } from './CommonContext';
|
|
2
|
+
export { default as CommonContext } from './CommonContext';
|
|
3
|
+
export { default as CookieStorage } from './CookieStorage';
|
|
4
|
+
export { commonResources, featureResources, mergeResources, commonLocalization, } from './Localization';
|
|
5
|
+
export { default as LexiconListService } from './services/LexiconListService';
|
|
6
|
+
export { default as ParserListService } from './services/ParserListService';
|
|
7
|
+
export type { Corpus, CorpusRequest, Github } from './types/Corpus';
|
|
8
|
+
export { CorpusStatusNames } from './types/CorpusStatus';
|
|
9
|
+
export type { CorpusStatus } from './types/CorpusStatus';
|
|
10
|
+
export { DocumentStatusNames } from './types/Document';
|
|
11
|
+
export type { DocumentStatus, default as Document } from './types/Document';
|
|
12
|
+
export { CorpusImageTypeNames } from './types/CorpusImage';
|
|
13
|
+
export type { CorpusImage, CorpusImageType } from './types/CorpusImage';
|
|
14
|
+
export { EditionTiers } from './types/EditionTiers';
|
|
15
|
+
export type { Parameter, ParameterType } from './types/Parameter';
|
|
16
|
+
export { SentenceStatusNames } from './types/SentenceStatus';
|
|
17
|
+
export type { SentenceStatus } from './types/SentenceStatus';
|
|
18
|
+
export type { Mark, Break, Format as SentenceFormat, SentenceTier, Translation, } from './types/Sentence';
|
|
19
|
+
export type { default as Sentence } from './types/Sentence';
|
|
20
|
+
export type { Chunk, Edition, Format, Morpheme, Split, Struct, Token, ConlluToken, } from './types/Struct';
|
|
21
|
+
export type { CytoscapeTree, Tree } from './types/Tree';
|
|
22
|
+
export { UserStatusNames } from './types/User';
|
|
23
|
+
export type { User, UserStatus } from './types/User';
|
|
24
|
+
export { useCorpusUtils } from './useCorpusUtils';
|
|
25
|
+
export { useLoggedUtils } from './useLoggedUtils';
|
|
26
|
+
export { useMessageUtils } from './useMessageUtils';
|
|
27
|
+
export { useTourUtils } from './useTourUtils';
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
export { CommonProvider } from './CommonContext';
|
|
2
|
+
export { default as CommonContext } from './CommonContext';
|
|
3
|
+
export { default as CookieStorage } from './CookieStorage';
|
|
4
|
+
export { commonResources, featureResources, mergeResources, commonLocalization, } from './Localization';
|
|
5
|
+
export { default as LexiconListService } from './services/LexiconListService';
|
|
6
|
+
export { default as ParserListService } from './services/ParserListService';
|
|
7
|
+
export { CorpusStatusNames } from './types/CorpusStatus';
|
|
8
|
+
export { DocumentStatusNames } from './types/Document';
|
|
9
|
+
export { CorpusImageTypeNames } from './types/CorpusImage';
|
|
10
|
+
export { EditionTiers } from './types/EditionTiers';
|
|
11
|
+
export { SentenceStatusNames } from './types/SentenceStatus';
|
|
12
|
+
export { UserStatusNames } from './types/User';
|
|
13
|
+
export { useCorpusUtils } from './useCorpusUtils';
|
|
14
|
+
export { useLoggedUtils } from './useLoggedUtils';
|
|
15
|
+
export { useMessageUtils } from './useMessageUtils';
|
|
16
|
+
export { useTourUtils } from './useTourUtils';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import Participant from '../../Participants/types/Participant';
|
|
1
|
+
import Participant from '../../features/Participants/types/Participant';
|
|
2
2
|
import { PlatformTools } from '../../functions/ToolsUtils';
|
|
3
3
|
export type DocumentStatus = 'EDITING' | 'EDITED' | 'SYNTACTIC' | 'COMPLETED';
|
|
4
4
|
export declare const DocumentStatusNames: {
|
|
@@ -2,7 +2,7 @@ import { Token } from "./Struct";
|
|
|
2
2
|
import { Edition } from "./Struct";
|
|
3
3
|
import { Struct } from "./Struct";
|
|
4
4
|
import { SentenceStatus } from "./SentenceStatus";
|
|
5
|
-
import { UploadedFile } from "../../AppDropzone/UploadedFile";
|
|
5
|
+
import { UploadedFile } from "../../common/AppDropzone/UploadedFile";
|
|
6
6
|
export type Mark = {
|
|
7
7
|
id: string;
|
|
8
8
|
tokens: Token[];
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
* Cytoscape context menus extension.
|
|
3
3
|
* Use: import contextMenus from 'tycho-components/cytoscape-context-menus'
|
|
4
4
|
*/
|
|
5
|
-
export { contextMenus as default } from './CytoscapeMenu/cytoscape-context-menus';
|
|
5
|
+
export { contextMenus as default } from './features/CytoscapeMenu/cytoscape-context-menus';
|
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
* Cytoscape context menus extension.
|
|
3
3
|
* Use: import contextMenus from 'tycho-components/cytoscape-context-menus'
|
|
4
4
|
*/
|
|
5
|
-
export { contextMenus as default } from './CytoscapeMenu/cytoscape-context-menus';
|
|
5
|
+
export { contextMenus as default } from './features/CytoscapeMenu/cytoscape-context-menus';
|
|
@@ -4,11 +4,11 @@ import { useForm } from 'react-hook-form';
|
|
|
4
4
|
import { useTranslation } from 'react-i18next';
|
|
5
5
|
import { Button, SelectField, TextField } from 'tycho-storybook';
|
|
6
6
|
import * as yup from 'yup';
|
|
7
|
-
import { useMessageUtils } from '
|
|
8
|
-
import FormUtils from '
|
|
7
|
+
import { useMessageUtils } from '../../configs/useMessageUtils';
|
|
8
|
+
import FormUtils from '../../functions/FormUtils';
|
|
9
9
|
import './style.scss';
|
|
10
10
|
import { EMPTY_COMMENT_REQUEST, } from './types/Comment';
|
|
11
|
-
import CommentService from './
|
|
11
|
+
import CommentService from './CommentService';
|
|
12
12
|
export default function CommentAdd({ uid, mode, users, references, keywords, comment, reply, onClose, onChange, }) {
|
|
13
13
|
const { t } = useTranslation('comments');
|
|
14
14
|
const { isLoading, dispatchLoading } = useMessageUtils();
|
|
@@ -2,10 +2,10 @@ import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-run
|
|
|
2
2
|
import { useContext } from 'react';
|
|
3
3
|
import { useTranslation } from 'react-i18next';
|
|
4
4
|
import { Avatar, IconButton } from 'tycho-storybook';
|
|
5
|
-
import CommonContext from '
|
|
6
|
-
import DateUtils from '
|
|
5
|
+
import CommonContext from '../../configs/CommonContext';
|
|
6
|
+
import DateUtils from '../../functions/DateUtils';
|
|
7
7
|
import './style.scss';
|
|
8
|
-
import CommentService from './
|
|
8
|
+
import CommentService from './CommentService';
|
|
9
9
|
export default function CommentInfo({ comment, onRemove, onUpdate, onEdit, onReply, }) {
|
|
10
10
|
const { t } = useTranslation('comments');
|
|
11
11
|
const { state } = useContext(CommonContext);
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { User } from '../../configs/types/User';
|
|
2
|
-
import { Comment, CommentRequest } from './Comment';
|
|
2
|
+
import { Comment, CommentRequest } from './types/Comment';
|
|
3
3
|
declare function findNotifications(uid: string, mode: string): Promise<import("axios").AxiosResponse<Comment[], any, {}>>;
|
|
4
4
|
declare function findReadNotifications(uid: string, mode: string): Promise<import("axios").AxiosResponse<Comment[], any, {}>>;
|
|
5
5
|
declare function markRead(id: string): Promise<import("axios").AxiosResponse<Comment, any, {}>>;
|
|
@@ -3,14 +3,14 @@ import { Drawer } from '@mui/material';
|
|
|
3
3
|
import { useEffect, useMemo, useState } from 'react';
|
|
4
4
|
import { useTranslation } from 'react-i18next';
|
|
5
5
|
import { Button, IconButton } from 'tycho-storybook';
|
|
6
|
-
import AppLoading from '
|
|
7
|
-
import AppPlaceholder from '
|
|
8
|
-
import SecurityUtils from '
|
|
9
|
-
import UsabilityUtils from '
|
|
6
|
+
import AppLoading from '../../common/AppLoading';
|
|
7
|
+
import AppPlaceholder from '../../common/AppPlaceholder';
|
|
8
|
+
import SecurityUtils from '../../functions/SecurityUtils';
|
|
9
|
+
import UsabilityUtils from '../../functions/UsabilityUtils';
|
|
10
10
|
import CommentAdd from './CommentAdd';
|
|
11
11
|
import CommentInfo from './CommentInfo';
|
|
12
12
|
import './style.scss';
|
|
13
|
-
import CommentService from './
|
|
13
|
+
import CommentService from './CommentService';
|
|
14
14
|
export default function Comments({ uid, keywords, references, mode, onClose, onChange, }) {
|
|
15
15
|
const { t } = useTranslation('comments');
|
|
16
16
|
const [openAddComment, setOpenAddComment] = useState(false);
|
|
@@ -3,8 +3,8 @@ import { useEffect, useState } from 'react';
|
|
|
3
3
|
import { Trans, useTranslation } from 'react-i18next';
|
|
4
4
|
import { useNavigate } from 'react-router-dom';
|
|
5
5
|
import { Avatar, IconButton } from 'tycho-storybook';
|
|
6
|
-
import DateUtils from '
|
|
7
|
-
import CommentService from '../
|
|
6
|
+
import DateUtils from '../../../functions/DateUtils';
|
|
7
|
+
import CommentService from '../CommentService';
|
|
8
8
|
import './style.scss';
|
|
9
9
|
export default function HeaderNotifications({ uid, mode, mobile }) {
|
|
10
10
|
const navigate = useNavigate();
|
|
@@ -4,7 +4,7 @@ import Switch from '@mui/material/Switch';
|
|
|
4
4
|
import Tooltip from '@mui/material/Tooltip';
|
|
5
5
|
import React, { useState } from 'react';
|
|
6
6
|
import { useTranslation } from 'react-i18next';
|
|
7
|
-
import { useLoggedUtils } from '
|
|
7
|
+
import { useLoggedUtils } from '../../configs/useLoggedUtils';
|
|
8
8
|
import { Icon } from 'tycho-storybook';
|
|
9
9
|
import './style.scss';
|
|
10
10
|
export default function Parameters({ parameters, onChange }) {
|
|
@@ -5,10 +5,10 @@ import { useForm } from 'react-hook-form';
|
|
|
5
5
|
import { useTranslation } from 'react-i18next';
|
|
6
6
|
import { TextField } from 'tycho-storybook';
|
|
7
7
|
import * as yup from 'yup';
|
|
8
|
-
import AppModal from '
|
|
9
|
-
import CommonContext from '
|
|
10
|
-
import ParticipantService from '../
|
|
11
|
-
import { useMessageUtils } from '
|
|
8
|
+
import AppModal from '../../../common/AppModal';
|
|
9
|
+
import CommonContext from '../../../configs/CommonContext';
|
|
10
|
+
import ParticipantService from '../ParticipantService';
|
|
11
|
+
import { useMessageUtils } from '../../../configs/useMessageUtils';
|
|
12
12
|
export default function ParticipantCreate({ document, onClose, onCreate, }) {
|
|
13
13
|
const { t } = useTranslation('participants');
|
|
14
14
|
const { state } = useContext(CommonContext);
|
|
@@ -3,10 +3,10 @@ import { Box, Modal } from '@mui/material';
|
|
|
3
3
|
import { useContext } from 'react';
|
|
4
4
|
import { useTranslation } from 'react-i18next';
|
|
5
5
|
import { Button, Icon, SelectField } from 'tycho-storybook';
|
|
6
|
-
import { modalRemoveStyle } from '
|
|
7
|
-
import CommonContext from '
|
|
8
|
-
import { useMessageUtils } from '
|
|
9
|
-
import ParticipantService from '../
|
|
6
|
+
import { modalRemoveStyle } from '../../../common/AppModal/AppModalRemove';
|
|
7
|
+
import CommonContext from '../../../configs/CommonContext';
|
|
8
|
+
import { useMessageUtils } from '../../../configs/useMessageUtils';
|
|
9
|
+
import ParticipantService from '../ParticipantService';
|
|
10
10
|
import { useForm } from 'react-hook-form';
|
|
11
11
|
import './style.scss';
|
|
12
12
|
export default function ParticipantRemove({ participant, participants, document, onClose, onChange, }) {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { AppEditableField } from '../../AppEditable/AppEditableField';
|
|
2
|
-
import Participant, { ParticipantCreateRequest } from './Participant';
|
|
1
|
+
import { AppEditableField } from '../../common/AppEditable/AppEditableField';
|
|
2
|
+
import Participant, { ParticipantCreateRequest } from './types/Participant';
|
|
3
3
|
declare function add(uid: string, request: ParticipantCreateRequest): Promise<import("axios").AxiosResponse<Participant, any, {}>>;
|
|
4
4
|
declare function update(field: AppEditableField): Promise<import("axios").AxiosResponse<any, any, {}>>;
|
|
5
5
|
declare function remove(document: string, code: string, transfer?: string): Promise<import("axios").AxiosResponse<any, any, {}>>;
|
|
@@ -3,13 +3,13 @@ import { MenuItem, Select } from '@mui/material';
|
|
|
3
3
|
import { useEffect, useState } from 'react';
|
|
4
4
|
import { useTranslation } from 'react-i18next';
|
|
5
5
|
import { Button } from 'tycho-storybook';
|
|
6
|
-
import AppEditable from '
|
|
7
|
-
import { useMessageUtils } from '
|
|
6
|
+
import AppEditable from '../../common/AppEditable';
|
|
7
|
+
import { useMessageUtils } from '../../configs/useMessageUtils';
|
|
8
8
|
import ParticipantCreate from './ParticipantCreate';
|
|
9
9
|
import ParticipantRemove from './ParticipantRemove';
|
|
10
10
|
import './style.scss';
|
|
11
11
|
import { CHAT_FIELDS, PARTICIPANT_FIELDS, } from './types/Participant';
|
|
12
|
-
import ParticipantService from './
|
|
12
|
+
import ParticipantService from './ParticipantService';
|
|
13
13
|
export default function Participants({ document, participants, onChange, useChat, }) {
|
|
14
14
|
const { t } = useTranslation('participants');
|
|
15
15
|
const { dispatchMessage } = useMessageUtils();
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { Parameter } from '../../configs/types/Parameter';
|
|
2
|
+
import { Struct } from '../../configs/types/Struct';
|
|
3
|
+
import { type ButtonDSModes, type ButtonDSSizes, type TooltipPlacements } from 'tycho-storybook';
|
|
4
|
+
import SentenceSplitLanguage from './types/Language';
|
|
5
|
+
import './style.scss';
|
|
6
|
+
export type SentenceSplitTranslationsInput = {
|
|
7
|
+
values: Record<string, string>;
|
|
8
|
+
};
|
|
9
|
+
export type SentenceSplitIconButtonProps = {
|
|
10
|
+
mode?: ButtonDSModes;
|
|
11
|
+
size?: ButtonDSSizes;
|
|
12
|
+
iconSize?: ButtonDSSizes;
|
|
13
|
+
tooltipPlacement?: TooltipPlacements;
|
|
14
|
+
};
|
|
15
|
+
type Props = {
|
|
16
|
+
struct: Struct;
|
|
17
|
+
documentUid: string;
|
|
18
|
+
wordTiers: Parameter[];
|
|
19
|
+
languages: SentenceSplitLanguage[];
|
|
20
|
+
translations: SentenceSplitTranslationsInput;
|
|
21
|
+
sound: string;
|
|
22
|
+
/** When set, pre-selects the split after the word with this token position (`tok.p`). */
|
|
23
|
+
selected?: number;
|
|
24
|
+
onSuccess?: () => void;
|
|
25
|
+
iconButtonProps?: SentenceSplitIconButtonProps;
|
|
26
|
+
};
|
|
27
|
+
export default function SentenceSplit({ struct, documentUid, wordTiers, languages, translations, sound, selected, onSuccess, iconButtonProps, }: Props): import("react/jsx-runtime").JSX.Element;
|
|
28
|
+
export {};
|
|
@@ -0,0 +1,180 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
2
|
+
import { useEffect, useMemo, useRef, useState } from 'react';
|
|
3
|
+
import { useTranslation } from 'react-i18next';
|
|
4
|
+
import AppModal from '../../common/AppModal/AppModal';
|
|
5
|
+
import SentenceUtils from '../../functions/SentenceUtils';
|
|
6
|
+
import { useCorpusUtils } from '../../configs/useCorpusUtils';
|
|
7
|
+
import { useMessageUtils } from '../../configs/useMessageUtils';
|
|
8
|
+
import { Badge, Button, IconButton, } from 'tycho-storybook';
|
|
9
|
+
import SentenceSplitAudioStep from './SentenceSplitAudio';
|
|
10
|
+
import SentenceSplitChoose from './SentenceSplitChoose';
|
|
11
|
+
import SentenceSplitCommentsStep from './SentenceSplitComments';
|
|
12
|
+
import SentenceSplitPreviewStep from './SentenceSplitPreview';
|
|
13
|
+
import SentenceSplitTranslationsStep from './SentenceSplitTranslations';
|
|
14
|
+
import SentenceSplitService from './SentenceSplitService';
|
|
15
|
+
import SentenceSplitUtils from './SentenceSplitUtils';
|
|
16
|
+
import { emptySentenceSplitRequest, } from './types/SentenceSplitRequest';
|
|
17
|
+
import './style.scss';
|
|
18
|
+
const STEP_CHOOSE = 0;
|
|
19
|
+
const STEP_PREVIEW = 1;
|
|
20
|
+
const STEP_TRANSLATIONS = 2;
|
|
21
|
+
const STEP_AUDIO = 3;
|
|
22
|
+
const STEP_COMMENTS = 4;
|
|
23
|
+
const DEFAULT_ICON_BUTTON_PROPS = {
|
|
24
|
+
mode: 'ghost',
|
|
25
|
+
size: 'medium',
|
|
26
|
+
iconSize: 'medium',
|
|
27
|
+
tooltipPlacement: 'bottom',
|
|
28
|
+
};
|
|
29
|
+
/** Split is after this token's word; must not be the last visible word. */
|
|
30
|
+
function resolveInitialSplitToken(selected, wordTokens) {
|
|
31
|
+
if (selected === undefined)
|
|
32
|
+
return 0;
|
|
33
|
+
const idx = wordTokens.findIndex((tok) => tok.p === selected);
|
|
34
|
+
if (idx === -1 || idx === wordTokens.length - 1)
|
|
35
|
+
return 0;
|
|
36
|
+
return selected;
|
|
37
|
+
}
|
|
38
|
+
export default function SentenceSplit({ struct, documentUid, wordTiers, languages, translations, sound, selected, onSuccess, iconButtonProps, }) {
|
|
39
|
+
const { t } = useTranslation('sentenceSplit');
|
|
40
|
+
const { getCorpus } = useCorpusUtils();
|
|
41
|
+
const { dispatchError, isLoading, dispatchLoading } = useMessageUtils();
|
|
42
|
+
const [open, setOpen] = useState(false);
|
|
43
|
+
const [step, setStep] = useState(STEP_CHOOSE);
|
|
44
|
+
const [request, setRequest] = useState(emptySentenceSplitRequest);
|
|
45
|
+
const [hasComments, setHasComments] = useState(null);
|
|
46
|
+
const stepsContentRef = useRef(null);
|
|
47
|
+
const stepItemRefs = useRef({});
|
|
48
|
+
const load = () => {
|
|
49
|
+
if (open) {
|
|
50
|
+
setStep(STEP_CHOOSE);
|
|
51
|
+
const baseValues = { ...(translations?.values || {}) };
|
|
52
|
+
const sorted = SentenceUtils.sort(struct);
|
|
53
|
+
const tokens = sorted.filter((tok) => SentenceUtils.isVisible(tok) && !SentenceSplitUtils.skipToken(tok));
|
|
54
|
+
setRequest({
|
|
55
|
+
uid: struct.uid,
|
|
56
|
+
token: resolveInitialSplitToken(selected, tokens),
|
|
57
|
+
translationsFirst: baseValues,
|
|
58
|
+
translationsSecond: { ...baseValues },
|
|
59
|
+
});
|
|
60
|
+
}
|
|
61
|
+
};
|
|
62
|
+
const wordTokens = useMemo(() => {
|
|
63
|
+
const sorted = SentenceUtils.sort(struct);
|
|
64
|
+
return sorted.filter((tok) => SentenceUtils.isVisible(tok) && !SentenceSplitUtils.skipToken(tok));
|
|
65
|
+
}, [struct]);
|
|
66
|
+
const canProceedFromChoose = request.token && wordTokens.length >= 2;
|
|
67
|
+
const hasTranslations = useMemo(() => {
|
|
68
|
+
if (!languages?.length)
|
|
69
|
+
return false;
|
|
70
|
+
const values = translations?.values ?? {};
|
|
71
|
+
return Object.values(values).some((v) => String(v ?? '').trim().length > 0);
|
|
72
|
+
}, [languages, translations]);
|
|
73
|
+
const hasAudio = Boolean(sound?.trim());
|
|
74
|
+
const visibleStepIds = useMemo(() => {
|
|
75
|
+
const ids = [STEP_CHOOSE, STEP_PREVIEW];
|
|
76
|
+
if (hasTranslations)
|
|
77
|
+
ids.push(STEP_TRANSLATIONS);
|
|
78
|
+
if (hasAudio)
|
|
79
|
+
ids.push(STEP_AUDIO);
|
|
80
|
+
if (hasComments === true)
|
|
81
|
+
ids.push(STEP_COMMENTS);
|
|
82
|
+
return ids;
|
|
83
|
+
}, [hasTranslations, hasAudio, hasComments]);
|
|
84
|
+
const stepIndex = visibleStepIds.indexOf(step);
|
|
85
|
+
const isLastStep = stepIndex >= 0 && stepIndex === visibleStepIds.length - 1;
|
|
86
|
+
const canGoBack = stepIndex > 0;
|
|
87
|
+
const handleBack = () => {
|
|
88
|
+
if (canGoBack)
|
|
89
|
+
setStep(visibleStepIds[stepIndex - 1]);
|
|
90
|
+
};
|
|
91
|
+
const handleNext = () => {
|
|
92
|
+
if (stepIndex >= 0 && stepIndex < visibleStepIds.length - 1) {
|
|
93
|
+
setStep(visibleStepIds[stepIndex + 1]);
|
|
94
|
+
}
|
|
95
|
+
};
|
|
96
|
+
const handleFinishSplit = () => {
|
|
97
|
+
if (isLoading())
|
|
98
|
+
return;
|
|
99
|
+
dispatchLoading(true);
|
|
100
|
+
SentenceSplitService.split(struct.uid, request)
|
|
101
|
+
.then(() => onSuccess?.())
|
|
102
|
+
.catch((err) => {
|
|
103
|
+
dispatchLoading(false);
|
|
104
|
+
dispatchError({ err, t });
|
|
105
|
+
});
|
|
106
|
+
};
|
|
107
|
+
const commentsCheckPending = hasComments === null;
|
|
108
|
+
const disablePrimary = (step === STEP_CHOOSE && !canProceedFromChoose) ||
|
|
109
|
+
(step === STEP_PREVIEW && request.token === null) ||
|
|
110
|
+
(step === STEP_COMMENTS && isLoading()) ||
|
|
111
|
+
commentsCheckPending;
|
|
112
|
+
const canOpenSplit = wordTokens.length >= 2;
|
|
113
|
+
const steps = useMemo(() => {
|
|
114
|
+
const definitions = [
|
|
115
|
+
{ id: STEP_CHOOSE, label: t('split.words.title') },
|
|
116
|
+
{ id: STEP_PREVIEW, label: t('split.preview.title') },
|
|
117
|
+
{ id: STEP_TRANSLATIONS, label: t('split.translations.title') },
|
|
118
|
+
{ id: STEP_AUDIO, label: t('split.audio.title') },
|
|
119
|
+
{ id: STEP_COMMENTS, label: t('split.comments.title') },
|
|
120
|
+
];
|
|
121
|
+
return definitions
|
|
122
|
+
.filter((item) => visibleStepIds.includes(item.id))
|
|
123
|
+
.map((item, index) => ({ ...item, displayNumber: index + 1 }));
|
|
124
|
+
}, [visibleStepIds, t]);
|
|
125
|
+
useEffect(() => {
|
|
126
|
+
load();
|
|
127
|
+
}, [open, translations, struct.uid, selected]);
|
|
128
|
+
useEffect(() => {
|
|
129
|
+
if (!open) {
|
|
130
|
+
setHasComments(null);
|
|
131
|
+
return;
|
|
132
|
+
}
|
|
133
|
+
let cancelled = false;
|
|
134
|
+
SentenceSplitService.findComments(getCorpus().uid, {
|
|
135
|
+
sentence: struct.uid,
|
|
136
|
+
document: documentUid,
|
|
137
|
+
page: struct.page,
|
|
138
|
+
})
|
|
139
|
+
.then((r) => {
|
|
140
|
+
if (!cancelled)
|
|
141
|
+
setHasComments(r.data.length > 0);
|
|
142
|
+
})
|
|
143
|
+
.catch((err) => {
|
|
144
|
+
if (!cancelled) {
|
|
145
|
+
setHasComments(false);
|
|
146
|
+
dispatchError({ err, t });
|
|
147
|
+
}
|
|
148
|
+
});
|
|
149
|
+
return () => {
|
|
150
|
+
cancelled = true;
|
|
151
|
+
};
|
|
152
|
+
}, [open, struct.uid, documentUid, struct.page, getCorpus, dispatchError, t]);
|
|
153
|
+
useEffect(() => {
|
|
154
|
+
if (!open || visibleStepIds.includes(step))
|
|
155
|
+
return;
|
|
156
|
+
setStep(visibleStepIds[0] ?? STEP_CHOOSE);
|
|
157
|
+
}, [open, visibleStepIds, step]);
|
|
158
|
+
useEffect(() => {
|
|
159
|
+
if (!open)
|
|
160
|
+
return;
|
|
161
|
+
const activeStepItem = stepItemRefs.current[step];
|
|
162
|
+
if (activeStepItem) {
|
|
163
|
+
activeStepItem.scrollIntoView({
|
|
164
|
+
behavior: 'smooth',
|
|
165
|
+
block: 'nearest',
|
|
166
|
+
inline: 'center',
|
|
167
|
+
});
|
|
168
|
+
}
|
|
169
|
+
stepsContentRef.current?.scrollTo({
|
|
170
|
+
top: 0,
|
|
171
|
+
behavior: 'smooth',
|
|
172
|
+
});
|
|
173
|
+
}, [step, open]);
|
|
174
|
+
const mergedIconProps = { ...DEFAULT_ICON_BUTTON_PROPS, ...iconButtonProps };
|
|
175
|
+
return (_jsxs(_Fragment, { children: [_jsx(IconButton, { name: "link_off", onClick: () => setOpen(true), title: canOpenSplit
|
|
176
|
+
? t('button.label.split')
|
|
177
|
+
: t('split.button.disabledTooFewWords'), disabled: !canOpenSplit, ...mergedIconProps }), open && (_jsxs(AppModal, { title: t('modal.split.sentence.title'), className: "sentence-split-modal", close: () => setOpen(false), hideFooter: true, disableEscapeClose: true, disableBackdropClose: true, children: [_jsx("div", { className: "steps-navigation", children: steps.map((stepItem) => (_jsxs("div", { className: `step-item ${step === stepItem.id ? 'active' : ''}`, onClick: () => setStep(stepItem.id), ref: (element) => {
|
|
178
|
+
stepItemRefs.current[stepItem.id] = element;
|
|
179
|
+
}, children: [_jsx(Badge, { text: stepItem.displayNumber.toString(), size: "medium", color: step === stepItem.id ? 'blue' : 'none' }), _jsx("div", { className: "step-label", children: stepItem.label })] }, stepItem.id))) }), _jsxs("div", { className: "steps-content", ref: stepsContentRef, children: [_jsxs("div", { className: "sentence-split-body", children: [step === STEP_CHOOSE && (_jsx(SentenceSplitChoose, { struct: struct, request: request, onChange: setRequest })), step === STEP_PREVIEW && request.token !== null && (_jsx(SentenceSplitPreviewStep, { struct: struct, request: request, wordTiers: wordTiers })), step === STEP_TRANSLATIONS && (_jsx(SentenceSplitTranslationsStep, { languages: languages, request: request, onChange: setRequest })), step === STEP_AUDIO && (_jsx(SentenceSplitAudioStep, { sound: sound, request: request, onChange: setRequest })), step === STEP_COMMENTS && request.token !== null && (_jsx(SentenceSplitCommentsStep, { struct: struct, documentUid: documentUid, request: request, onChange: setRequest }))] }), _jsxs("div", { className: "steps-footer", children: [canGoBack && (_jsx(Button, { text: t('split.button.back'), onClick: handleBack, size: "medium", mode: "ghost" })), _jsx(Button, { text: isLastStep ? t('split.button.finish') : t('split.button.next'), onClick: isLastStep ? handleFinishSplit : handleNext, size: "medium", disabled: disablePrimary })] })] })] }))] }));
|
|
180
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { SentenceSplitRequest } from '../types/SentenceSplitRequest';
|
|
2
|
+
import './style.scss';
|
|
3
|
+
type Props = {
|
|
4
|
+
sound: string;
|
|
5
|
+
request: SentenceSplitRequest;
|
|
6
|
+
onChange: (request: SentenceSplitRequest) => void;
|
|
7
|
+
};
|
|
8
|
+
export default function SentenceSplitAudioStep({ sound, request, onChange, }: Props): import("react/jsx-runtime").JSX.Element;
|
|
9
|
+
export {};
|