Merge branch 'master' into feature/abarrett/lms-notes-app

This commit is contained in:
Arthur Barrett
2013-03-19 13:43:45 -04:00
308 changed files with 8484 additions and 4538 deletions

View File

@@ -5,8 +5,5 @@
"/static/js/vendor/jquery-ui.min.js",
"/static/js/vendor/jquery.leanModal.min.js",
"/static/js/vendor/flot/jquery.flot.js"
],
"static_files": [
"js/application.js"
]
}

View File

@@ -4,9 +4,6 @@ describe 'Calculator', ->
@calculator = new Calculator
describe 'bind', ->
beforeEach ->
Calculator.bind()
it 'bind the calculator button', ->
expect($('.calc')).toHandleWith 'click', @calculator.toggle
@@ -31,12 +28,19 @@ describe 'Calculator', ->
$('form#calculator').submit()
describe 'toggle', ->
it 'toggle the calculator and focus the input', ->
spyOn $.fn, 'focus'
@calculator.toggle(jQuery.Event("click"))
it 'focuses the input when toggled', ->
expect($('li.calc-main')).toHaveClass('open')
expect($('#calculator_wrapper #calculator_input').focus).toHaveBeenCalled()
# Since the focus is called asynchronously, we need to
# wait until focus() is called.
didFocus = false
runs ->
spyOn($.fn, 'focus').andCallFake (elementName) -> didFocus = true
@calculator.toggle(jQuery.Event("click"))
waitsFor (-> didFocus), "focus() should have been called on the input", 1000
runs ->
expect($('#calculator_wrapper #calculator_input').focus).toHaveBeenCalled()
it 'toggle the close button on the calculator button', ->
@calculator.toggle(jQuery.Event("click"))

View File

@@ -22,18 +22,23 @@ describe 'Tab', ->
it 'bind the tabs', ->
expect($.fn.tabs).toHaveBeenCalledWith show: @tab.onShow
# As of jQuery 1.9, the onShow callback is deprecated
# http://jqueryui.com/upgrade-guide/1.9/#deprecated-show-event-renamed-to-activate
# The code below tests that onShow does what is expected,
# but note that onShow will NOT be called when the user
# clicks on the tab if we're using jQuery version >= 1.9
describe 'onShow', ->
beforeEach ->
@tab = new Tab 1, @items
$('[href="#tab-1-0"]').click()
@tab.onShow($('#tab-1-0'), {'index': 1})
it 'replace content in the container', ->
$('[href="#tab-1-1"]').click()
@tab.onShow($('#tab-1-1'), {'index': 1})
expect($('#tab-1-0').html()).toEqual ''
expect($('#tab-1-1').html()).toEqual 'Video 2'
expect($('#tab-1-2').html()).toEqual ''
it 'trigger contentChanged event on the element', ->
spyOnEvent @tab.el, 'contentChanged'
$('[href="#tab-1-1"]').click()
@tab.onShow($('#tab-1-1'), {'index': 1})
expect('contentChanged').toHaveBeenTriggeredOn @tab.el

View File

@@ -32,11 +32,9 @@ describe 'Navigation', ->
heightStyle: 'content'
it 'binds the accordionchange event', ->
Navigation.bind()
expect($('#accordion')).toHandleWith 'accordionchange', @navigation.log
it 'bind the navigation toggle', ->
Navigation.bind()
expect($('#open_close_accordion a')).toHandleWith 'click', @navigation.toggle
describe 'when the #accordion does not exists', ->
@@ -45,7 +43,6 @@ describe 'Navigation', ->
it 'does not activate the accordion', ->
spyOn $.fn, 'accordion'
Navigation.bind()
expect($('#accordion').accordion).wasNotCalled()
describe 'toggle', ->

Binary file not shown.

After

Width:  |  Height:  |  Size: 518 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 34 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 498 B

View File

@@ -2442,4 +2442,39 @@ body.discussion {
color:#000;
font-style: italic;
background-color:#fff;
}
}
.discussion-pin {
font-size: 12px;
float:right;
padding-right: 5px;
font-style: italic;
}
.notpinned .icon
{
display: inline-block;
width: 10px;
height: 14px;
padding-right: 3px;
background: transparent url('../images/unpinned.png') no-repeat 0 0;
}
.pinned .icon
{
display: inline-block;
width: 10px;
height: 14px;
padding-right: 3px;
background: transparent url('../images/pinned.png') no-repeat 0 0;
}
.pinned span {
color: #B82066;
font-style: italic;
}
.notpinned span {
color: #888;
font-style: italic;
}

View File

@@ -119,6 +119,10 @@ div.course-wrapper {
}
}
section.xmodule_WrapperModule ol.vert-mod > li {
border-bottom: none;
}
section.tutorials {
h2 {
margin-bottom: lh();
@@ -219,7 +223,7 @@ div.course-wrapper {
.xmodule_VideoModule {
margin-bottom: 30px;
}
textarea.short-form-response {
@@ -237,7 +241,7 @@ section.self-assessment {
margin-top: 5px;
margin-bottom: 5px;
}
div {
margin-top: 5px;
margin-bottom: 5px;
@@ -261,4 +265,4 @@ section.foldit {
padding-right: 5px;
}
}
}

View File

@@ -205,7 +205,10 @@
position: relative;
width: 100%;
p {
section {
color: $base-font-color;
font: normal 1em/1.6em $serif;
margin: 0px;
height: 100%;
overflow: hidden;
text-overflow: ellipsis;