mirror of
https://github.com/jupyter/notebook.git
synced 2025-04-24 14:20:54 +08:00
Fix all the tests
This commit is contained in:
parent
2478fac032
commit
b15633a89e
@ -6,6 +6,7 @@ define([
|
||||
'jquery',
|
||||
'base/js/utils',
|
||||
'notebook/js/tour',
|
||||
'components/bootstrap/js/bootstrap.min',
|
||||
], function(IPython, $, utils, tour) {
|
||||
"use strict";
|
||||
|
||||
|
@ -52,7 +52,7 @@ define([
|
||||
this.events = options.events;
|
||||
this.keyboard_manager = options.keyboard_manager;
|
||||
this.save_widget = options.save_widget;
|
||||
this.tooltip = tooltip.Tooltip(this.events);
|
||||
this.tooltip = new tooltip.Tooltip(this.events);
|
||||
// TODO: This code smells (and the other `= this` line a couple lines down)
|
||||
// We need a better way to deal with circular instance references.
|
||||
this.keyboard_manager.notebook = this;
|
||||
|
@ -4,7 +4,8 @@
|
||||
define([
|
||||
"underscore",
|
||||
"backbone",
|
||||
], function (_, Backbone) {
|
||||
"base/js/namespace"
|
||||
], function (_, Backbone, IPython) {
|
||||
|
||||
//--------------------------------------------------------------------
|
||||
// WidgetManager class
|
||||
@ -193,5 +194,8 @@ define([
|
||||
this._models[model_id] = widget_model;
|
||||
};
|
||||
|
||||
// Backwards compatability.
|
||||
IPython.WidgetManager = WidgetManager;
|
||||
|
||||
return {'WidgetManager': WidgetManager};
|
||||
});
|
||||
|
@ -3,8 +3,10 @@
|
||||
|
||||
define(["widgets/js/manager",
|
||||
"underscore",
|
||||
"backbone"],
|
||||
function(widgetmanager, _, Backbone){
|
||||
"backbone",
|
||||
"jquery",
|
||||
"base/js/namespace",
|
||||
], function(widgetmanager, _, Backbone, $, IPython){
|
||||
|
||||
var WidgetModel = Backbone.Model.extend({
|
||||
constructor: function (widget_manager, model_id, comm) {
|
||||
@ -458,9 +460,14 @@ function(widgetmanager, _, Backbone){
|
||||
},
|
||||
});
|
||||
|
||||
return {
|
||||
var widget = {
|
||||
'WidgetModel': WidgetModel,
|
||||
'WidgetView': WidgetView,
|
||||
'DOMWidgetView': DOMWidgetView,
|
||||
};
|
||||
|
||||
// For backwards compatability.
|
||||
$.extend(IPython, widget);
|
||||
|
||||
return widget;
|
||||
});
|
||||
|
@ -3,7 +3,9 @@
|
||||
|
||||
define([
|
||||
"widgets/js/widget",
|
||||
], function(widget){
|
||||
"jquery",
|
||||
"components/bootstrap/js/bootstrap.min",
|
||||
], function(widget, $){
|
||||
|
||||
var CheckboxView = widget.DOMWidgetView.extend({
|
||||
render : function(){
|
||||
|
@ -3,7 +3,9 @@
|
||||
|
||||
define([
|
||||
"widgets/js/widget",
|
||||
], function(widget){
|
||||
"jquery",
|
||||
"components/bootstrap/js/bootstrap.min",
|
||||
], function(widget, $){
|
||||
|
||||
var ButtonView = widget.DOMWidgetView.extend({
|
||||
render : function(){
|
||||
|
@ -3,7 +3,8 @@
|
||||
|
||||
define([
|
||||
"widgets/js/widget",
|
||||
"jqueryui"
|
||||
"jqueryui",
|
||||
"components/bootstrap/js/bootstrap.min",
|
||||
], function(widget, $){
|
||||
|
||||
var ContainerView = widget.DOMWidgetView.extend({
|
||||
|
@ -3,7 +3,8 @@
|
||||
|
||||
define([
|
||||
"widgets/js/widget",
|
||||
], function(widget){
|
||||
"jquery",
|
||||
], function(widget, $){
|
||||
|
||||
var ImageView = widget.DOMWidgetView.extend({
|
||||
render : function(){
|
||||
|
@ -3,7 +3,9 @@
|
||||
|
||||
define([
|
||||
"widgets/js/widget",
|
||||
], function(widget){
|
||||
"jqueryui",
|
||||
"components/bootstrap/js/bootstrap.min",
|
||||
], function(widget, $){
|
||||
|
||||
var IntSliderView = widget.DOMWidgetView.extend({
|
||||
render : function(){
|
||||
|
@ -4,7 +4,9 @@
|
||||
define([
|
||||
"widgets/js/widget",
|
||||
"base/js/utils",
|
||||
], function(widget, utils){
|
||||
"jquery",
|
||||
"components/bootstrap/js/bootstrap.min",
|
||||
], function(widget, utils, $){
|
||||
|
||||
var DropdownView = widget.DOMWidgetView.extend({
|
||||
render : function(){
|
||||
|
@ -4,7 +4,9 @@
|
||||
define([
|
||||
"widgets/js/widget",
|
||||
"base/js/utils",
|
||||
], function(widget, utils){
|
||||
"jquery",
|
||||
"components/bootstrap/js/bootstrap.min",
|
||||
], function(widget, utils, $){
|
||||
|
||||
var AccordionView = widget.DOMWidgetView.extend({
|
||||
render: function(){
|
||||
|
@ -3,7 +3,9 @@
|
||||
|
||||
define([
|
||||
"widgets/js/widget",
|
||||
], function(widget){
|
||||
"jquery",
|
||||
"components/bootstrap/js/bootstrap.min",
|
||||
], function(widget, $){
|
||||
|
||||
var HTMLView = widget.DOMWidgetView.extend({
|
||||
render : function(){
|
||||
|
Loading…
x
Reference in New Issue
Block a user