stable
Clone or download
Part of story #13453: finish drag'n drop images in tracker text areas How to test: - No functional change expected in the image drag and drop for the Tracker artifact view. Check translations, errors and check that when you upload an image and then remove it from the editor, it is filtered out of the file field. - Rebuild planning v2 - When you have a file field and you can update / submit to it, you should be able to paste or drop an image in a Follow-up comment or a text field. - When you submit, the file field references that image. - When you remove the image from the textarea before submitting, the file field does not reference that image anymore (it is filtered before submit) - When there is an error, an error message should be shown below the textarea. - When there is no file field or there is one that you can't write to, there should NOT be a help message below the textarea. - When you try to paste an image anyway, there should be an error message below the textarea. Notes to reviewer: Translation has been really painful for this patch. Please note that: - If I had kept the "gettext_provider" in ckeditor files, we would have imported "po" files with 3 different outcomes: vue-gettext, angular-gettext and node-gettext, which is very painful to configure. - make generate-po does not extract gettext from Vue components in the artifact modal. I tried it, and it drops all strings extracted from angular. - "translate" attribute does not work out of the box with NgVue. - For the two points above, I think it's wiser to spend time reworking the modal in Vue instead of making them work. Translated strings in Vue will have to be updated "by hand" without tools to extract them. Change-Id: I3c92a06dd92fa1b55c9d198ed0c867239db34740
Modified Files
Name | ||||
---|---|---|---|---|
M | plugins/tracker/www/scripts/angular-artifact-modal/po/fr.po | +20 | −1 | Go to diff View file |
M | plugins/tracker/www/scripts/angular-artifact-modal/src/common/RichTextEditor.spec.js | +259 | −7 | Go to diff View file |
M | plugins/tracker/www/scripts/angular-artifact-modal/src/common/RichTextEditor.vue | +132 | −11 | Go to diff View file |
M | plugins/tracker/www/scripts/angular-artifact-modal/src/followups/FollowupEditor.vue | +6 | −0 | Go to diff View file |
M | plugins/tracker/www/scripts/angular-artifact-modal/src/index.spec.js | +1 | −0 | Go to diff View file |
M | plugins/tracker/www/scripts/angular-artifact-modal/src/model/field-values-service.js | +4 | −3 | Go to diff View file |
M | plugins/tracker/www/scripts/angular-artifact-modal/src/model/field-values-service.spec.js | +14 | −8 | Go to diff View file |
A | plugins/tracker/www/scripts/angular-artifact-modal/src/ng-vue-config.js | +29 | −0 | Go to diff View file |
A | plugins/tracker/www/scripts/angular-artifact-modal/src/store/getters.js | +22 | −0 | Go to diff View file |
A | plugins/tracker/www/scripts/angular-artifact-modal/src/store/index.js | +29 | −0 | Go to diff View file |
A | plugins/tracker/www/scripts/angular-artifact-modal/src/store/mutations.js | +22 | −0 | Go to diff View file |
A | plugins/tracker/www/scripts/angular-artifact-modal/src/store/state.js | +22 | −0 | Go to diff View file |
M | plugins/tracker/www/scripts/angular-artifact-modal/src/tuleap-artifact-modal-controller.js | +21 | −2 | Go to diff View file |
M | plugins/tracker/www/scripts/angular-artifact-modal/src/tuleap-artifact-modal-controller.spec.js | +118 | −49 | Go to diff View file |
M | plugins/tracker/www/scripts/angular-artifact-modal/src/tuleap-artifact-modal-fields/disabled-field-detector.js | +7 | −1 | Go to diff View file |
M | plugins/tracker/www/scripts/angular-artifact-modal/src/tuleap-artifact-modal-fields/file-field/file-field-detector.js | +5 | −0 | Go to diff View file |
M | plugins/tracker/www/scripts/angular-artifact-modal/src/tuleap-artifact-modal-fields/file-field/file-field-detector.spec.js | +44 | −1 | Go to diff View file |
A | plugins/tracker/www/scripts/angular-artifact-modal/src/tuleap-artifact-modal-fields/file-field/file-field-validator.js | +72 | −0 | Go to diff View file |
A | plugins/tracker/www/scripts/angular-artifact-modal/src/tuleap-artifact-modal-fields/file-field/file-field-validator.spec.js | +244 | −0 | Go to diff View file |
A | plugins/tracker/www/scripts/angular-artifact-modal/src/tuleap-artifact-modal-fields/file-field/is-uploading-in-ckeditor-state.js | +32 | −0 | Go to diff View file |
M | plugins/tracker/www/scripts/angular-artifact-modal/src/tuleap-artifact-modal-fields/text-field/TextField.vue | +6 | −0 | Go to diff View file |
M | plugins/tracker/www/scripts/angular-artifact-modal/src/tuleap-artifact-modal-service.js | +9 | −2 | Go to diff View file |
M | plugins/tracker/www/scripts/angular-artifact-modal/src/tuleap-artifact-modal.js | +2 | −0 | Go to diff View file |
M | plugins/tracker/www/scripts/angular-artifact-modal/src/tuleap-artifact-modal.tpl.html | +3 | −0 | Go to diff View file |
M | plugins/tracker/www/scripts/angular-artifact-modal/src/validate-service.js | +13 | −13 | Go to diff View file |
M | plugins/tracker/www/scripts/angular-artifact-modal/src/validate-service.spec.js | +34 | −27 | Go to diff View file |
A | plugins/tracker/www/scripts/angular-artifact-modal/src/vuex-store.js | +26 | −0 | Go to diff View file |
M | plugins/tracker/www/scripts/constants/fields-constants.js | +8 | −0 | Go to diff View file |
M | plugins/tracker/www/scripts/package-lock.json | +5 | −0 | Go to diff View file |
M | plugins/tracker/www/scripts/package.json | +1 | −0 | Go to diff View file |
M | plugins/tracker/www/scripts/webpack.config.js | +1 | −0 | Go to diff View file |
M | src/www/scripts/tuleap/ckeditor/file-upload-handler-factory.js | +30 | −15 | Go to diff View file |
M | src/www/scripts/tuleap/ckeditor/file-upload-handler-factory.spec.js | +63 | −20 | Go to diff View file |
M | src/www/scripts/tuleap/ckeditor/get-upload-image-options.js | +18 | −2 | Go to diff View file |
M | src/www/scripts/tuleap/ckeditor/get-upload-image-options.spec.js | +30 | −7 | Go to diff View file |
M | tools/utils/scripts/webpack-aliases.js | +3 | −2 | Go to diff View file |