Skip to content

Conversation

@valera-rozuvan
Copy link
Contributor

Add ability to display LTI module in a new window. Iframe will be still supported. The flag which determines what functionality is used can be set from the Edit dialog in Studio per individual LTI.

Python tests, acceptance tests, and Jasmine tests were updated.

Reviewers:
@frrrances
@Lyla-Fischer
@singingwolfboy

@ghost ghost assigned singingwolfboy Oct 1, 2013
@valera-rozuvan
Copy link
Contributor Author

@polesye I tried going with the Underscore templates, but I was not successful. It will take a lot of time for me to implement such a solution. In the end I went with jQuery and modifying our element on the fly.

Maybe this is not optimal, but it does reduce the number of fixtures to 1.

^_^

Copy link
Contributor

Choose a reason for hiding this comment

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

I'm worried this wording is confusing to students and the plain link style is easy to miss in a vertical, so I think we need a bit more here. I would change it to:

    <p><span class="description">[LTI Display Name] (External resource)</span>
    <a href="#" class='link_lti_new_window'><i class="icon-external-link"></i> ${_('View resource in a new window')}</a>
    </p>

where [LTI Display Name] is the text that the Studio user puts into the display name input.

In addition, it needs some styling to make it a bigger element in the vertical with a clear button, similar to discussions:

screen shot 2013-10-02 at 3 59 15 pm

Copy link
Contributor

Choose a reason for hiding this comment

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

@valera-rozuvan please add this styling

@ghost ghost assigned auraz Oct 4, 2013
Copy link
Contributor

Choose a reason for hiding this comment

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

This is checked in template, do not check it twice.

@ghost ghost assigned nedbat Oct 4, 2013
@auraz
Copy link
Contributor

auraz commented Oct 4, 2013

@valera-rozuvan Please add styling pointed by Frances

Copy link
Contributor

Choose a reason for hiding this comment

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

Shouldn't "External resource" be translated?

@valera-rozuvan
Copy link
Contributor Author

@singingwolfboy I have addressed your template translation comments.

@valera-rozuvan
Copy link
Contributor Author

@auraz I have removed check for empty and default URL in JavaScript (lti module, not Jasmine test).

@valera-rozuvan
Copy link
Contributor Author

@frrrances I am having trouble identifying the styles I need in order to make the link stand out more. My HTML code is:

<section class="xmodule_display xmodule_LTIModule" data-type="LTI">
    <div id="i4x-private-01-lti-4757d22a9c974afc8c39e777753f247e" class="lti" data-open_in_a_new_page="true">
        <p>
            <span class="description">
                Book 1 (External resource)
            </span>
            <a href="#" class="link_lti_new_window">
                <i class="icon-external-link"></i>
                View resource in a new window
            </a>
        </p>
    </div>
</section>

Can you please suggest?

@valera-rozuvan
Copy link
Contributor Author

@auraz I have actually added back the check for URL. If it is empty or default - then we must make sure that JS part does not try to make a form submit. I know that the check is in the template. But that check only adds or removes iframe or link.

@frrrances
Copy link
Contributor

@valera-rozuvan I made pushed some changes to the sass and adjusted the html a little for the LTI in an external window. Let me know if that helps or if you need me to make adjustments. thanks!

@valera-rozuvan
Copy link
Contributor Author

@frrrances I like your changes. I have just tweaked them a bit to make the link and the text on the same level, and more in the center.

@Lyla-Fischer @singingwolfboy @frrrances Am I good to merge?

@frrrances
Copy link
Contributor

looks good to me! 👍

auraz and others added 12 commits October 14, 2013 13:58
Add ability to display LTI module in a new
window. Iframe will be still supported.

Fix python test
Update acceptance tests
Fix in acceptance tests, they are stable now
Fix Acceptance tests.
Adding Jasmine tests for LTI.
Fixing Jasmine tests. Adding the rest of Jasmine tests.
Removed JS check for empty url and default url. In template added
i18n support for several strings.
Made it so that the link and the text are on the same level, and in the
center of the block.
valera-rozuvan added a commit that referenced this pull request Oct 15, 2013
New feature for lti module. Open in new window.
@valera-rozuvan valera-rozuvan merged commit 5592511 into master Oct 15, 2013
@valera-rozuvan valera-rozuvan deleted the alex/lti_new_window branch October 15, 2013 12:07
jenkins-ks pushed a commit to nttks/edx-platform that referenced this pull request Sep 16, 2016
jenkins-ks pushed a commit to nttks/edx-platform that referenced this pull request Sep 16, 2016
…anslations-for-multilingual-support

Fix translation for cert name in dashboard openedx#1185
jenkins-ks pushed a commit to nttks/edx-platform that referenced this pull request Sep 27, 2016
jenkins-ks pushed a commit to nttks/edx-platform that referenced this pull request Sep 27, 2016
…ail-templates-for-multilingual-support

Fix email templates for multilingual support openedx#1185
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants