Skip to content

Added LaTeX preview feature to all comment/feedback fields - #1017

Merged
efischer19 merged 1 commit into
openedx:masterfrom
open-craft:bdero/feedback-latex-preview
Jul 6, 2017
Merged

Added LaTeX preview feature to all comment/feedback fields#1017
efischer19 merged 1 commit into
openedx:masterfrom
open-craft:bdero/feedback-latex-preview

Conversation

@bdero

@bdero bdero commented Jun 29, 2017

Copy link
Copy Markdown
Contributor

Development for openfun: ORA2 already offers LaTeX previewing when LaTeX is enabled for submissions, but the peer assessment and self assessment sections also allow for inputting LaTeX, even though there are no preview buttons for these fields.

This change adds a LaTeX preview button to each of these fields that are currently missing it.

Screenshot:

screenshot

Testing setup:

  1. Clone this repository into the /edx/app/src directory, checkout the branch for this PR, and install the xblock like so:
    pip install -e file:///edx/src/edx-ora2/#egg=ora2==localdev
    
  2. Go to the Advanced Settings of a course in Studio and add "ora2" to the Advanced Module List
  3. Add an "Open Response Assessment" problem to a new Unit
  4. Select "Edit" on the new ORA problem to open the settings modal
  5. Change "Allow LaTeX Responses" to True, and click Save to close the settings dialog
  6. Publish the Unit

Testing instructions:

  1. Logged in with two different users (I'll refer to them as User A and User B), navigate to the new ORA2 problem in the LMS
  2. User A: Type some LaTeX markup into the submission field, for example:
    \begin{align}
    u_{n}&=-3+\frac{3n}{2}\\
    &=\frac{3n-6}{2}
    \end{align}
  3. User A: Select "Preview in LaTeX" to verify that it (still) works as expected
  4. User A: Submit the response and then complete the "Learn to Assess Responses" section
  5. User B: Submit a response, and then complete the "Learn to Assess Responses" section - you will be prompted to assess User A's submission in the "Assess Peers" section
  6. User B: Observe that there are "Preview in LaTeX" buttons below each of the fields
  7. User B: Type some LaTeX markup into each of the fields and verify that the "Preview in LaTeX" feature works as expected

@bdero
bdero requested a review from e-kolpakov June 29, 2017 01:36
@openedx-webhooks

Copy link
Copy Markdown

Thanks for the pull request, @bdero! It looks like you're a member of a company that does contract work for edX. If you're doing this work as part of a paid contract with edX, you should talk to edX about who will review this pull request. If this work is not part of a paid contract with edX, then you should ensure that there is an OSPR issue to track this work in JIRA, so that we don't lose track of your pull request.

Create an OSPR issue for this pull request.

@openedx-webhooks

Copy link
Copy Markdown

Thanks for the pull request, @bdero! I've created OSPR-1801 to keep track of it in JIRA. JIRA is a place for product owners to prioritize feature reviews by the engineering development teams.

Feel free to add as much of the following information to the ticket:

  • supporting documentation
  • edx-code email threads
  • timeline information ("this must be merged by XX date", and why that is)
  • partner information ("this is a course on edx.org")
  • any other information that can help Product understand the context for the PR

All technical communication about the code itself will still be done via the GitHub pull request interface. As a reminder, our process documentation is here.

If you like, you can add yourself to the AUTHORS file for this repo, though that isn't required. Please see the CONTRIBUTING file for more information.

@openedx-webhooks openedx-webhooks added needs triage open-source-contribution PR author is not from Axim or 2U labels Jun 29, 2017
@bdero bdero added the waiting on author PR author needs to resolve review requests, answer questions, fix tests, etc. label Jun 29, 2017
@bdero
bdero force-pushed the bdero/feedback-latex-preview branch 2 times, most recently from 56db8b6 to fff4158 Compare June 29, 2017 04:03
@bdero bdero changed the title WIP: Added LaTeX preview feature to all comment/feedback fields Added LaTeX preview feature to all comment/feedback fields Jun 29, 2017
@bdero bdero removed the waiting on author PR author needs to resolve review requests, answer questions, fix tests, etc. label Jun 29, 2017
@bdero
bdero force-pushed the bdero/feedback-latex-preview branch 4 times, most recently from c21ce70 to c979228 Compare June 30, 2017 01:55

@e-kolpakov e-kolpakov left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

  • I tested this: followed testing instructions
  • I read through the code
  • I checked for accessibility issues (to the best of my knowledge)
  • Includes documentation

@bdero
bdero force-pushed the bdero/feedback-latex-preview branch from c979228 to 8fb5af0 Compare June 30, 2017 04:31
@openedx-webhooks openedx-webhooks added product review PR requires product review before merging and removed needs triage labels Jun 30, 2017
@jul

jul commented Jul 6, 2017

Copy link
Copy Markdown

We are testing here too (fun-mooc). Tests are conclusive so far: it works as advertised.

@bdero bdero mentioned this pull request Jul 6, 2017
10 tasks
@sstack22

sstack22 commented Jul 6, 2017

Copy link
Copy Markdown

@bdero - this looks great! Just want to confirm - the preview button only appears when a comment is written in latex? That is my only concern.

@bdero

bdero commented Jul 6, 2017

Copy link
Copy Markdown
Contributor Author

@sstack22 Thanks, and yup, all of the preview buttons/areas will only show up if the latex option is enabled for the xblock.

@sstack22

sstack22 commented Jul 6, 2017

Copy link
Copy Markdown

👍 from product review.

@openedx-webhooks openedx-webhooks added awaiting prioritization and removed product review PR requires product review before merging labels Jul 6, 2017

@efischer19 efischer19 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great to me, thanks for the PR!

@efischer19
efischer19 merged commit 410adc8 into openedx:master Jul 6, 2017
bdero added a commit to open-craft/openedx-platform that referenced this pull request Jul 7, 2017
julAtWork pushed a commit to julAtWork/edx-ora2 that referenced this pull request Jul 17, 2017
Allow LaTeX previewing for multiple prompts

Conflicts:

	openassessment/xblock/static/css/openassessment-ltr.css
	openassessment/xblock/static/css/openassessment-rtl.css
	openassessment/xblock/static/js/openassessment-lms.min.js
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants