forked from moodle/moodle
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
MDL-54722 navigation: Properly overflow expanded nav trees
- Loading branch information
1 parent
6a74e76
commit fd5466a
Showing
15 changed files
with
84 additions
and
26 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -16,20 +16,32 @@ | |
/** | ||
* Load the settings block tree javscript | ||
* | ||
* @module block_navigation/navblock | ||
* @module block_settings/settingsblock | ||
* @package core | ||
* @copyright 2015 John Okely <[email protected]> | ||
* @license http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later | ||
*/ | ||
define(['jquery', 'core/tree'], function($, Tree) { | ||
return { | ||
init: function(siteAdminNodeId) { | ||
init: function(instanceid, siteAdminNodeId) { | ||
var adminTree = new Tree(".block_settings .block_tree"); | ||
if (siteAdminNodeId) { | ||
var siteAdminNode = adminTree.treeRoot.find('#' + siteAdminNodeId); | ||
var siteAdminLink = siteAdminNode.children('a').first(); | ||
siteAdminLink.replaceWith('<span tabindex="0">' + siteAdminLink.html() + '</span>'); | ||
} | ||
adminTree.finishExpandingGroup = function(item) { | ||
Tree.prototype.finishExpandingGroup.call(this, item); | ||
Y.Global.fire(M.core.globalEvents.BLOCK_CONTENT_UPDATED, { | ||
instanceid: instanceid | ||
}); | ||
}; | ||
adminTree.collapseGroup = function(item) { | ||
Tree.prototype.collapseGroup.call(this, item); | ||
Y.Global.fire(M.core.globalEvents.BLOCK_CONTENT_UPDATED, { | ||
instanceid: instanceid | ||
}); | ||
}; | ||
} | ||
}; | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters