Add optional Markdown support to the Review dialog.
Review Request #6483 — Created Oct. 21, 2014 and submitted
This adds checkboxes below the text fields in the Review dialog for
toggling Markdown support. It also loads the correct values from the
API, depending on the user's defaultUseRichText setting in UserSession.If the default is to use Markdown, the review and comments will be
requested with text normalized to Markdown, and all TextEditorViews will
be set to save as Markdown by default.If the default is to use plain text, the review and comments will be
requested without any text normalization, allowing the default values to
come in. All TextEditorViews will therefore reflect the stored value.Toggling the new "Enable Markdown" checkbox for any field will mark that
field as dirty, so that it will be saved when saving or publishing the
review. That will then be saved along with the appropriate Rich Text
setting.
Tested loading the body and comment fields with both Markdown and plain text
flags set, and with different defaultUseRichText values set.Tested saving with both Markdown and plain text.
Viewed the payloads to make sure we were loading what was expected.
Unit tests pass.