Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
X
xblock-drag-and-drop-v2
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
OpenEdx
xblock-drag-and-drop-v2
Commits
3fc71a8f
Commit
3fc71a8f
authored
Feb 23, 2016
by
Jonathan Piacenti
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
More compatible handling of zone alignment selection in studio.
parent
63d6bf01
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
19 deletions
+3
-19
drag_and_drop_v2/public/js/drag_and_drop_edit.js
+3
-19
No files found.
drag_and_drop_v2/public/js/drag_and_drop_edit.js
View file @
3fc71a8f
...
@@ -177,7 +177,8 @@ function DragAndDropEditBlock(runtime, element, params) {
...
@@ -177,7 +177,8 @@ function DragAndDropEditBlock(runtime, element, params) {
_fn
.
build
.
form
.
zone
.
add
();
_fn
.
build
.
form
.
zone
.
add
();
})
})
.
on
(
'click'
,
'.remove-zone'
,
_fn
.
build
.
form
.
zone
.
remove
)
.
on
(
'click'
,
'.remove-zone'
,
_fn
.
build
.
form
.
zone
.
remove
)
.
on
(
'input'
,
'.zone-row input, .zone-row select'
,
_fn
.
build
.
form
.
zone
.
changedInputHandler
)
.
on
(
'input'
,
'.zone-row input'
,
_fn
.
build
.
form
.
zone
.
changedInputHandler
)
.
on
(
'change'
,
'.align-select'
,
_fn
.
build
.
form
.
zone
.
changedInputHandler
)
.
on
(
'click'
,
'.target-image-form button'
,
function
(
e
)
{
.
on
(
'click'
,
'.target-image-form button'
,
function
(
e
)
{
e
.
preventDefault
();
e
.
preventDefault
();
...
@@ -329,24 +330,6 @@ function DragAndDropEditBlock(runtime, element, params) {
...
@@ -329,24 +330,6 @@ function DragAndDropEditBlock(runtime, element, params) {
});
});
},
},
getZoneNames
:
function
()
{
var
zoneNames
=
[];
var
$form
=
_fn
.
build
.
$el
.
zones
.
form
.
find
(
'.title'
);
$form
.
each
(
function
(
i
,
el
)
{
var
val
=
$
(
el
).
val
();
if
(
val
.
length
>
0
)
{
zoneNames
.
push
(
val
);
}
});
return
zoneNames
;
},
getZoneAlignNames
:
function
()
{
var
alignNames
=
[
""
,
"left"
,
"center"
,
"right"
];
return
alignNames
;
},
changedInputHandler
:
function
(
ev
)
{
changedInputHandler
:
function
(
ev
)
{
// Called when any of the inputs have changed.
// Called when any of the inputs have changed.
var
$changedInput
=
$
(
ev
.
currentTarget
);
var
$changedInput
=
$
(
ev
.
currentTarget
);
...
@@ -496,6 +479,7 @@ function DragAndDropEditBlock(runtime, element, params) {
...
@@ -496,6 +479,7 @@ function DragAndDropEditBlock(runtime, element, params) {
correct
:
$el
.
find
(
'.success-feedback'
).
val
(),
correct
:
$el
.
find
(
'.success-feedback'
).
val
(),
incorrect
:
$el
.
find
(
'.error-feedback'
).
val
()
incorrect
:
$el
.
find
(
'.error-feedback'
).
val
()
},
},
imageURL
:
imageURL
,
imageURL
:
imageURL
,
imageDescription
:
imageDescription
,
imageDescription
:
imageDescription
,
};
};
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment