Patch #40137


Jstoolbar help files should import images from the asset pipeline

Added by Marius BĂLTEANU 3 months ago. Updated about 2 months ago.

Text formatting
Target version:
Start date:
Due date:
% Done:


Estimated time:


jstoolbar help files are pure html static files that are importing the images using html image elements, for example:

<img src="../../images/jstoolbar/bt_img.png" style="border: 1px solid #bbb;" alt="Image" />

We need to update these files in order to use the images generated by the asset pipeline. I see 2 options:
1. move all these images as CSS background images
2. refactor all help files in order to use a template that is rendered on server side. If we do this, it will make also easier to modify that files because you don't need to make the same change in all help files.


Related issues

Related to Redmine - Feature #39111: Enable Asset Pipeline Integration using PropshaftResolvedMarius BĂLTEANU

Actions #1

Updated by Marius BĂLTEANU 3 months ago

  • Related to Feature #39111: Enable Asset Pipeline Integration using Propshaft added
Actions #2

Updated by Marius BĂLTEANU about 2 months ago

I've started working on this and I'm attaching an intermediary version of the patch series:

  • Introduces HelpController and a new route help/wiki_syntax/(:detailed) to serve help files
  • Moves all wiki syntax help files to app/views/help and CSS files to app/assets/stylesheets
  • Reorganize all the help files per text formatter (markdown, common_mark and textile)
0003-Remove-languages-from-wiki-syntax-help-files-that-ar (inspired from common_mark implementation)
  • Remove languages from wiki syntax help files that are identical with en language.
  • Fall back to the english help page if there is none for the current language.
  • Changes JS toolbar help button to use the new route
  • Just add the erb extension to all files.
  • Move inline style for img border to css file to cleanup a little bit the view files.
  • Includes the css file from the asset pipeline.
Still need to finish:
  • Update link that points to detailed version.
  • Include images using image_tag.
  • Add tests for new route and HelpController.

I hope I will finish this until the end of this month.

Actions #4

Updated by Marius BĂLTEANU about 2 months ago

I've committed all the patches, still need to add tests.

Actions #5

Updated by Marius BĂLTEANU about 2 months ago

  • Category set to Text formatting
  • Status changed from New to Closed
  • Assignee set to Marius BĂLTEANU
  • Resolution set to Fixed

I think I've finished all the minimum changes in order to restore the old functionality.

Actions #6

Updated by Marius BĂLTEANU about 2 months ago

  • Tracker changed from Defect to Patch
  • Resolution deleted (Fixed)

Also available in: Atom PDF