![]() Fixes: CNVS-28841 test plan: - as a user with the new ui - click the "account" link from the left nav - from the sub-nav click "files" - if you do not have any items uploaded - do so in order to click an item and see the action buttons groupset... a few tweaks have been made to bring it inline with products design example: http://screencast.com/t/QA6E3u5u - next click into a course and from the course sub-nav click "files" - the tweaks from above should be viewable on this page as well example: http://screencast.com/t/85IoRnYwlpiE note: - a comment has been left on the jira regarding the odd course sub-nav placement for files within a course *** wil need to be addressed on a new ticket/commit Change-Id: I49cae6c4057e44076ce9cae0489f02c065927f85 Reviewed-on: https://gerrit.instructure.com/77893 Tested-by: Jenkins Reviewed-by: Chris Hart <chart@instructure.com> Product-Review: Chris Hart <chart@instructure.com> QA-Review: Myller de Araujo <myller@instructure.com> |
||
---|---|---|
.. | ||
account_course_user_search | ||
assignments | ||
authentication_providers | ||
context_modules | ||
course_link_validator | ||
course_settings | ||
course_wizard | ||
dashboard_card | ||
discussion_topics | ||
due_dates | ||
editor | ||
epub_exports | ||
external_apps | ||
files | ||
gradebook | ||
gradebook2 | ||
grading | ||
groups | ||
navigation_header | ||
outcomes | ||
shared | ||
styleguide | ||
theme_editor | ||
README.md |
README.md
This directory is temporary until we rework the front-end build This is where we are headed.
Stuff you can do in Canvas JSX files
BUT WAIT!
Your file needs to:
- Have a file name with the
.jsx
extension.
JSX
function foo(paths) {
return <svg>{paths}</svg>;
}
Arrow Functions
var arr = ['hydrogen', 'helium', 'lithium'];
// es5
var a = arr.map(function(s){ return s.length });
// es6
var b = arr.map( s => s.length );
// with curlies requires normal return
var b = arr.map( (s) => {
return s.length
});
// lexical `this`
var obj = {
multiplier: 3,
multiplyStuff (stuff) {
return stuff.map((x) =>
// no bind!
return this.multiplier * x;
)
}
};
Classes
class EventEmitter {
constructor() {
// called when created
}
emit() {
// ...
}
on() {
// ...
}
once() {
// ...
}
removeListener() {
// ...
}
removeAllListeners() {
// ...
}
}
Extending and calling super
.
class Domain extends EventEmitter {
constructor() {
super();
this.members = [];
}
}
Creating instances
var domain = new Domain();
Destructuring
// es5
var map = _.map;
var each = _.each;
// es6
var {map, each} = _;
Concise Object Methods
// es5
var obj = {
foo: function() {}
bar: function() {}
};
// es6
var obj = {
foo() {}
bar() {}
};
Object Short Notation
// es5
function() {
// ...
return {foo: foo, bar: bar, x: 10};
}
// es6
function() {
// ...
return {foo, bar, x: 10};
}
Rest Parameters
// es5
function multiply(multiplier) {
var numbers = Array.prototype.slice.call(arguments, 0);
return number.map(function(n) { return multiplier * n; });
}
// es6
function multiply(multiplier, ...numbers) {
return numbers.map( n => multiplier * n);
}
String Templates
Multiline strings:
// es5
console.log("string text line 1" +
"string text line 2");
// es6
console.log(`string text line 1
string text line 2`);
Interpolated strings
var a = 5;
var b = 10;
// es5
console.log("Fifteen is " + (a + b) + " and not " + (2 * a + b) + ".");
// es6
console.log(`Fifteen is ${a + b} and not ${2 * a + b}.`);