closes CNVS-19413
folks have been requesting RTL support. This uses
tinymce's core plugin to provide it. Unfortunately that adds
another two buttons to the toolbar. :(
wraps the directionality plugin in an AMD wrapper, and adds it
to our default configuration
Also prevents canvas from stripping out the "dir" element
when HTML scrubbing
TEST PLAN:
- go to any RCE
- see the two new buttons for RTL and LTR
- use them to change back and forth, make sure it doesn't break
- ensure that our custom plugins don't interact badly with it. (I've
done a cursory code read and some clicking around, but that would
be my biggest concern)
Change-Id: I0884b65a99ec0e1db8c6abd82711a35799a062dd
Reviewed-on: https://gerrit.instructure.com/50672
QA-Review: August Thornton <august@instructure.com>
Tested-by: Jenkins
Reviewed-by: Rob Orton <rob@instructure.com>
Product-Review: Ethan Vizitei <evizitei@instructure.com>
fixes CNVS-18648
This was suspected to be a tinymce problem,
but tiny wasn't stripping lang at all (which
is why the reporter was confused that it was
in the white list).
This adds rspec (and therefore specs)
and the sanitize dependency
to the canvas_sanitize gem, adds a spec
that proves the sanitization problem was in here,
and then changes the default config to allow the
lang element to show up on html elements.
TEST PLAN:
- Open an RCE in Canvas
- Use the HTML editor and paste in <p lang="es"> Hola. Como estas?</p>p>
- Save
- Edit and verify that the lang attribute hasn't been stripped
Change-Id: Iff9129a8cbff4b4efd004e619ef92c7395dda568
Reviewed-on: https://gerrit.instructure.com/50255
Reviewed-by: Jeremy Stanley <jeremy@instructure.com>
Product-Review: Jeremy Stanley <jeremy@instructure.com>
Reviewed-by: Dan Minkevitch <dan@instructure.com>
Tested-by: Jenkins
QA-Review: Jahnavi Yetukuri <jyetukuri@instructure.com>
test plan:
- add add a video in an iframe in the rich content editor
- it should be able to become full screen
fixes PLAT-647
Change-Id: I05ad81fdebc32353af9746605e9847947e614582
Reviewed-on: https://gerrit.instructure.com/41728
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Nathan Mills <nathanm@instructure.com>
QA-Review: Clare Strong <clare@instructure.com>
Product-Review: Brad Humphrey <brad@instructure.com>
fixes CNVS-13697
When you create html markup in canvas, you should be able to add
accessible attributes and roles to elements. This commit allows you to
do that.
Test Plan
As a user that can edit a wiki page
When you edit a wiki page
And you toggle to edit the html
Then you add an aria attribute like aria-label
And you toggle back to the yswyg editor
And you toggle back into the html view
Then aria elements should still be on the html elements
And they should still be there when you save the page and inspect the
elements via developer tools.
Change-Id: Id443170fb3eabcbfcec58fd29b6fcfe1ea71279a
Reviewed-on: https://gerrit.instructure.com/36627
Reviewed-by: Jeremy Stanley <jeremy@instructure.com>
Tested-by: Jenkins <jenkins@instructure.com>
QA-Review: Clare Strong <clare@instructure.com>
Product-Review: Hilary Scharton <hilary@instructure.com>
test plan:
* try to add audio and video tags in html content
* should not remove the tags when saving
closes #CNVS-9660
Change-Id: I46e363d2150f16a07ec8cf096be8b7652c437254
Reviewed-on: https://gerrit.instructure.com/36594
Tested-by: Jenkins <jenkins@instructure.com>
Product-Review: Jeremy Stanley <jeremy@instructure.com>
Reviewed-by: Jeremy Stanley <jeremy@instructure.com>
QA-Review: Caleb Guanzon <cguanzon@instructure.com>
test plan:
* try to save html content with a title attibute on an
html element other than a or img:
e.g. "<p title='a title'>text</p>"
* the attribute should not be removed
closes #CNVS-8357
Change-Id: Ib6bf534a75aa30fff8efc6345189114ff3718e1c
Reviewed-on: https://gerrit.instructure.com/36590
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Jeremy Stanley <jeremy@instructure.com>
Product-Review: Jeremy Stanley <jeremy@instructure.com>
QA-Review: Caleb Guanzon <cguanzon@instructure.com>
test plan:
* add html content including one or more h1 tags
(e.g. "<h1>Header</h1>")
* confirm that it retains the tags rather than
stripping them out
fixes #CNVS-12321
Change-Id: I74dd56aced493255b2f8a5834d2a5a841de6d910
Reviewed-on: https://gerrit.instructure.com/33139
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Ryan Florence <ryanf@instructure.com>
QA-Review: Nathan Rogowski <nathan@instructure.com>
Product-Review: Ryan Florence <ryanf@instructure.com>
in commit 8ae4ba8e, the regex was modified to accept negative
values (e.g., -1.0em), making the \w-\w clause redundant and
causing extremely slow matching in certain pathological cases.
test plan:
- import the Angel package attached to the ticket
- it should complete in a reasonable time (a few minutes,
probably) and definitely should not max out your CPU
for three hours while making no visible progress
fixes CNVS-10820
Change-Id: I582386c25d4d99f362ce2411b0c387bc958a71c5
Reviewed-on: https://gerrit.instructure.com/30074
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Bracken Mosbacker <bracken@instructure.com>
Product-Review: Bracken Mosbacker <bracken@instructure.com>
QA-Review: Nathan Rogowski <nathan@instructure.com>
fixes CNVS-11072
test plan: in a canvas repository without a .git directory (like a deploy) call
a bundle command (like script/console). it should not give you warnings about
missing .git directories
Change-Id: I2daa1371d97c94f7c3db81d3fd2bad387fcabaf8
Reviewed-on: https://gerrit.instructure.com/29947
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Stephan Hagemann <stephan@pivotallabs.com>
Product-Review: Stephan Hagemann <stephan@pivotallabs.com>
QA-Review: Stephan Hagemann <stephan@pivotallabs.com>