why:
* using display=in_rce instead of borderless allows inline/iframed
LTI launches inside an active RCE to work and use postMessages
* this was mistakenly also using in_rce with link-type
LTI launches, which open in a new tab
* which meant that the new tab never replaced the iframe
with the tool entirely, so there was still a canvas wrapper
* continue using display=borderless with links that open
an LTI tool in a new tab
closes INTEROP-8379
refs INTEROP-8205
flag=none
test plan:
* in a docker container:
```
cd packages/canvas-rce
yarn build:watch
```
* you can also restart your webpack container to make sure the changes
are picked up
* install the lti 1.3 test tool or 1.1 test tool with the editor_button
placement
* launch the tool from a page that has the RCE, like a new wiki page
* pass back a content item with no iframe attribute so that it makes
a link
* change to the HTML editor - the <a> tag should have
display=borderless
* save the page, and hover over the link
* it should include display=borderless, not display=in_rce
* click on the link
* it should open in a new tab, and the URL in the address bar
should eventually be for the tool, not canvas
Change-Id: I49a7d99cc21d77540f9ea9023f4d371ad509a104
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/335741
Reviewed-by: Paul Gray <paul.gray@instructure.com>
QA-Review: Paul Gray <paul.gray@instructure.com>
Product-Review: Alexis Nast <alexis.nast@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
closes LF-1099
flag=none
test plan:
-find an RCE, toggle to the html editor
-insert a source tag with width + height attributes
-toggle to normal editor and back to html editor
>confirm the width/height attributes weren't stripped
-save the page
-re-edit your content again
>confirm the width/height weren't stripped by the server
Change-Id: Iffc814b1a12479971ed00bda98b776a5c3a5b6de
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/335334
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Jacob DeWar <jacob.dewar@instructure.com>
QA-Review: Jacob DeWar <jacob.dewar@instructure.com>
Product-Review: Jake Oeding <jake.oeding@instructure.com>
adds the same verifier that was added to the rce
publish script to check if the package is able
to be installed outside of canvas-lms
closes LF-1091
flag=none
test plan:
- use the flags to skip parts of the script that don't need
testing, such as SKIP_NPM_PUBLISH
- run the script, ensure that the 'Verifying NPM install...'
works as expected, installing the package and reporting
if it succeeds or not
Change-Id: I68ac59b6180551d4d5f9d7ba94ab6e65ac78bc9e
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/335113
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Jake Oeding <jake.oeding@instructure.com>
Reviewed-by: Jackson Howe <jackson.howe@instructure.com>
QA-Review: Jackson Howe <jackson.howe@instructure.com>
Product-Review: Sarah Gerard <sarah.gerard@instructure.com>
flag=none
closes LF-1089
Test Plan:
- Have files in course/user with really long names
- Go to an RCE (ex Pages)
- Go to one of the course/user images/media/documents traya
- Change category to "All"
- Expand until files are shown
- Hover over files
* Verify hover shows full file name
Change-Id: I3eab059e7b56e35129e9d9e02ac30baf13f0c8ee
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/335090
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Mysti Lilla <mysti@instructure.com>
Reviewed-by: Jake Oeding <jake.oeding@instructure.com>
QA-Review: Mysti Lilla <mysti@instructure.com>
Product-Review: Jacob DeWar <jacob.dewar@instructure.com>
Also:
- Remove some unnecessary use of @instructure/ui-themeable
- Remove use of TsMigrationAny
- Remove some instui-related module declarations
(no longer needed)
- Remove old upgrade-instructure-ui script
- Upgrade typescript and babel-plugin-typescript-to-proptypes in RCE
Test plan:
- Build passes
flag=none
Change-Id: I734183ed8bdf68422e4eb46285909c30bc31ee33
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/334667
Reviewed-by: Jackson Howe <jackson.howe@instructure.com>
QA-Review: Aaron Shafovaloff <ashafovaloff@instructure.com>
Product-Review: Aaron Shafovaloff <ashafovaloff@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
when choosing a video from All Files in an
RCE, the url has ?type=video?type=video, which
is incorrect
closes LF-66
flag=none
test plan:
- in an RCE, add media by clicking on the media icon,
and then switching the file type from Media to 'All'
in the dropdown
- after adding the media, switch to the html editor and
notice the src should only have ?type=video once
- ensure the rest of the iframe looks the same
- ensure adding media from course media and user media
also still results in the correct src
Change-Id: Ibaebfc4520320ce1904823bd296f9c4ff8fcbb5d
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/333420
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Davis Hyer <dhyer@instructure.com>
QA-Review: Davis Hyer <dhyer@instructure.com>
Product-Review: Davis Hyer <dhyer@instructure.com>
closes LF-804
flag=none
Test Plan:
- Add Video to a New Quiz
- Add captions
- Refresh the New Quiz
- Open Video tray
* Verify captions appear
- Repeat with Audio
Change-Id: I1a3f0df0bfcaec7b3f456d7dcfea78017ab1a549
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/334124
Reviewed-by: Eric Saupe <eric.saupe@instructure.com>
QA-Review: Eric Saupe <eric.saupe@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Product-Review: Jacob DeWar <jacob.dewar@instructure.com>
closes LF-709
flag=none
test plan:
- use the flags to skip parts of the script that don't need
testing, such as SKIP_NPM_PUBLISH
- run the script, ensure that the 'Verifying NPM install...'
works as expected, installing the package and reporting
if it succeeds or not
Change-Id: Ie0fb0e5d82f27426a99044acde64d774b9837d1c
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/334550
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Jackson Howe <jackson.howe@instructure.com>
QA-Review: Jackson Howe <jackson.howe@instructure.com>
Product-Review: Sarah Gerard <sarah.gerard@instructure.com>
flag=none
refs ARC-9407
Test Plan:
- Enable Assignments Enhancements - Student flag
- Create an assignment with media recording submission
- Take assignment as Student
- Click Record Media and record video
- Open Network Tab
- Click Save Media button many times quickly
* Verify in network tab that thousands of requests are NOT sent
Change-Id: I470d3c7e676b4db8584a05abcd415294e25bda0c
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/334296
Reviewed-by: Mysti Lilla <mysti@instructure.com>
Reviewed-by: Eric Saupe <eric.saupe@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
QA-Review: Mysti Lilla <mysti@instructure.com>
Product-Review: Jacob DeWar <jacob.dewar@instructure.com>
Closes FOO-4017
flag=none
Several bug fixes, plus this has the requested changes
from InstUI for the new look and feel for the side and
top navigation bars.
Test plan:
* automated tests pass
Change-Id: I5292256e4e479c70837cc77b10b97dfaba235848
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/333822
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
QA-Review: Charley Kline <ckline@instructure.com>
Product-Review: Charley Kline <ckline@instructure.com>
Reviewed-by: Aaron Shafovaloff <ashafovaloff@instructure.com>
This fixes post-merge build failures.
New TypeScript version picked up on some naughty
assignments in a test file. But since it's a test
file we can ignore it
flag=none
Change-Id: Iacbae1a289f77f7eb14e1b176530f9469e89778f
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/333535
QA-Review: Aaron Shafovaloff <ashafovaloff@instructure.com>
Product-Review: Aaron Shafovaloff <ashafovaloff@instructure.com>
Reviewed-by: James Butters <jbutters@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
closes LF-968
flag = none
Test plan: jenkins passes
Change-Id: I2c64d49a5a82b455ef6b0793d0fee23edc6aa2a1
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/333284
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Jonathan Guardado <jonathan.guardado@instructure.com>
QA-Review: Jonathan Guardado <jonathan.guardado@instructure.com>
Product-Review: Jackson Howe <jackson.howe@instructure.com>
Removes global use of jest-fetch-mock, which inhibits
migration to vitest.
Also:
- TypeScriptify Confetti
- more properly tests confetti with testing-library
- removes needless setTimeout on confetti SR-only flashAlert
Test plan
- Submit assignment as student
- Confetti should still show
flag=none
Change-Id: I70fdc23dbc6d18a37487abeaa7625c441cc64d77
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/333193
Reviewed-by: Spencer Olson <solson@instructure.com>
Reviewed-by: Drake Harper <drake.harper@instructure.com>
QA-Review: Aaron Shafovaloff <ashafovaloff@instructure.com>
Product-Review: Aaron Shafovaloff <ashafovaloff@instructure.com>
Build-Review: James Butters <jbutters@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
fixes LF-954
flag=none
test plan:
- create a classic quiz
- go to the questions tab and create a new
question
- the html element display in the bottom status bar
should be left justified
- switch to the html editor
- the "Switch to raw HTML Editor" button should be left
justified
- ensure that rces in other places still look the same
Change-Id: Ib819fd229df4b9e1bda2b9b4ad8bdfe44c086a9c
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/332801
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Juan Chavez <juan.chavez@instructure.com>
QA-Review: Juan Chavez <juan.chavez@instructure.com>
Product-Review: Sarah Gerard <sarah.gerard@instructure.com>
fixes LF-906
flag=none
Test Plan:
- In an RCE, record a video and save it
- Go to course file
- Verify new file has appropriate extension
- Repeat with uploading media
- Go to submission comments
- Submit an assignment
- Go to speedgrader for submission
- Record media
- Go to user files
- Verify new file has appropriate extension
- Repeat with uploading media
Change-Id: Ie79209fd6bd43eb5eeaae1dbd85c89bc34f7d2a3
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/331893
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Product-Review: Jacob DeWar <jacob.dewar@instructure.com>
Reviewed-by: Juan Chavez <juan.chavez@instructure.com>
QA-Review: Juan Chavez <juan.chavez@instructure.com>
test plan:
- smoke test badges on old and new nav
- smoke test profile tray on old and new nav
flag=instui_nav
Refs FOO-3880
Refs FOO-3887
Refs FOO-3894
Refs FOO-3895
Change-Id: I1d3a669aee09dc67b04e798a23e016d26f398fd4
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/331758
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
QA-Review: Aaron Shafovaloff <ashafovaloff@instructure.com>
Product-Review: Aaron Shafovaloff <ashafovaloff@instructure.com>
Reviewed-by: Gustavo Bernardes <gustavo.bernardes@instructure.com>
fixes LF-887
flag=media_links_use_attachment_id
Test plan
- In a Blueprint parent course, upload
a media file and lock the file for editing
in the children courses
- Link a child course and sync the content
from the parent
- Link the video in the RCE in the child course
- Click on the video in the editor and go to
Video Options
- Verify that an API response to the RCS at
api/files/:fileId was sent
- For best results, test with g/330028 and
g/330353 (which will actually provide the
required API field)
Change-Id: Ib0f734ba45842c6320804c4d46516ab8b1a76304
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/330025
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Luis Oliveira <luis.oliveira@instructure.com>
QA-Review: Luis Oliveira <luis.oliveira@instructure.com>
Product-Review: Mysti Lilla <mysti@instructure.com>
Closes FOO-3955
Refs EVAL-3613
Closes FOO-3820
Refs FOO-3947
flag=none
There's mount/unmount bug in <Tray> that was causing
some heartburn, this fixes that.
This InstUI fix exposed some broken tests which were
checking for a Tray to no longer be open; because a
tray closing is a transition, it's necessary to wait
for it to close in an asynchronous test... checking
for that immediately cannot be expected to work due
to the transition, but was accidentally working in
some cases.
Two entire Selenium specs became very flaky as a
result of this version bump; they were just skipped
for now since they're rather complex and it wasn't
obvious how to fix them. The EVAL ticket was created
so that that issue could be addressed later.
test plan:
* automated tests pass
Change-Id: I81374d0c8e783a7b0285c2cf9506153e2194fceb
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/330333
Reviewed-by: Michael Hulse <michael.hulse@instructure.com>
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
QA-Review: Charley Kline <ckline@instructure.com>
Product-Review: Charley Kline <ckline@instructure.com>
I think this may be due to instui8 being fully typescript,
though I don't understand why it would affect native react
prop type validations. This commit eliminates the new
prop warning console error messages.
The real solution to this is to convert CanvasConentTray
and all the related components to typescript, but that
is way beyond the scope of this ticket.
closes LF-786
flag=none
test plan:
- in a dev environment (so you get react console messages)
- open a page with the rce
- open dev tools
- in the RCE, open the CanvasContentTray
(e.g. Documents -> Course Documents)
> expect the tray to open w/o bad prop error messages in
the devtools console
- repeat for images and media
Change-Id: I3d211eaade0f4a27fde446dfeafc27edcfb4558e
Reviewed-on: https://gerrit.instructure.com/c/canvas-lms/+/328124
Tested-by: Service Cloud Jenkins <svc.cloudjenkins@instructure.com>
Reviewed-by: Jackson Howe <jackson.howe@instructure.com>
QA-Review: Jackson Howe <jackson.howe@instructure.com>
Product-Review: Ed Schiebel <eschiebel@instructure.com>