-
Notifications
You must be signed in to change notification settings - Fork 3.8k
/
require-config.js
203 lines (199 loc) · 7.91 KB
/
require-config.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
;(function (require, define) {
// We do not wish to bundle common libraries (that may also be used by non-RequireJS code on the page
// into the optimized files. Therefore load these libraries through script tags and explicitly define them.
// Note that when the optimizer executes this code, window will not be defined.
if (window) {
var defineDependency = function (globalVariable, name, noShim) {
if (window[globalVariable]) {
if (noShim) {
define(name, {});
}
else {
define(name, [], function() {return window[globalVariable];});
}
}
else {
console.error("Expected library to be included on page, but not found on window object: " + name);
}
};
defineDependency("jQuery", "jquery");
defineDependency("s", "underscore.string");
// Underscore.string no longer installs itself directly on "_". For compatibility with existing
// code, add it to "_" with its previous name.
if (window._ && window.s) {
window._.str = window.s;
}
defineDependency("gettext", "gettext");
defineDependency("Logger", "logger");
defineDependency("URI", "URI");
defineDependency("Backbone", "backbone");
// utility.js adds two functions to the window object, but does not return anything
defineDependency("isExternal", "utility", true);
}
require.config({
// NOTE: baseUrl has been previously set in lms/templates/main.html
waitSeconds: 60,
paths: {
"annotator_1.2.9": "js/vendor/edxnotes/annotator-full.min",
"date": "js/vendor/date",
"moment": "js/vendor/moment.min",
"moment-with-locales": "xmodule_js/common_static/js/vendor/moment-with-locales.min",
"text": "js/vendor/requirejs/text",
"logger": "js/src/logger",
"backbone": "js/vendor/backbone-min",
"backbone-super": "js/vendor/backbone-super",
"backbone.paginator": "js/vendor/backbone.paginator.min",
"underscore": "js/vendor/underscore-min",
"underscore.string": "js/vendor/underscore.string.min",
"jquery": "js/vendor/jquery.min",
"jquery.cookie": "js/vendor/jquery.cookie",
'jquery.timeago': 'js/vendor/jquery.timeago',
"jquery.url": "js/vendor/url.min",
"jquery.ui": "js/vendor/jquery-ui.min",
"jquery.iframe-transport": "js/vendor/jQuery-File-Upload/js/jquery.iframe-transport",
"jquery.fileupload": "js/vendor/jQuery-File-Upload/js/jquery.fileupload",
"URI": "js/vendor/URI.min",
"string_utils": "js/src/string_utils",
"utility": "js/src/utility",
// Files needed by OVA
"annotator": "js/vendor/ova/annotator-full",
"annotator-harvardx": "js/vendor/ova/annotator-full-firebase-auth",
"video.dev": "js/vendor/ova/video.dev",
"vjs.youtube": "js/vendor/ova/vjs.youtube",
"rangeslider": "js/vendor/ova/rangeslider",
"share-annotator": "js/vendor/ova/share-annotator",
"richText-annotator": "js/vendor/ova/richText-annotator",
"reply-annotator": "js/vendor/ova/reply-annotator",
"grouping-annotator": "js/vendor/ova/grouping-annotator",
"tags-annotator": "js/vendor/ova/tags-annotator",
"diacritic-annotator": "js/vendor/ova/diacritic-annotator",
"flagging-annotator": "js/vendor/ova/flagging-annotator",
"jquery-Watch": "js/vendor/ova/jquery-Watch",
"openseadragon": "js/vendor/ova/openseadragon",
"osda": "js/vendor/ova/OpenSeaDragonAnnotation",
"ova": "js/vendor/ova/ova",
"catch": "js/vendor/ova/catch/js/catch",
"handlebars": "js/vendor/ova/catch/js/handlebars-1.1.2",
"tinymce": "js/vendor/tinymce/js/tinymce/tinymce.full.min",
"jquery.tinymce": "js/vendor/tinymce/js/tinymce/jquery.tinymce.min"
// end of files needed by OVA
},
shim: {
"gettext": {
exports: "gettext"
},
"annotator_1.2.9": {
deps: ["jquery"],
exports: "Annotator"
},
"date": {
exports: "Date"
},
"jquery": {
exports: "$"
},
"jquery.cookie": {
deps: ["jquery"],
exports: "jQuery.fn.cookie"
},
"jquery.timeago": {
deps: ["jquery"],
exports: "jQuery.timeago"
},
"jquery.url": {
deps: ["jquery"],
exports: "jQuery.url"
},
"jquery.fileupload": {
deps: ["jquery.ui", "jquery.iframe-transport"],
exports: "jQuery.fn.fileupload"
},
"jquery.tinymce": {
deps: ["jquery", "tinymce"],
exports: "jQuery.fn.tinymce"
},
"underscore": {
exports: "_"
},
"backbone": {
deps: ["underscore", "jquery"],
exports: "Backbone"
},
"backbone.paginator": {
deps: ["backbone"],
exports: "Backbone.Paginator"
},
"backbone-super": {
deps: ["backbone"]
},
"string_utils": {
deps: ["underscore"],
exports: "interpolate_text"
},
// Needed by OVA
"video.dev": {
exports:"videojs"
},
"vjs.youtube": {
deps: ["video.dev"]
},
"rangeslider": {
deps: ["video.dev"]
},
"annotator": {
exports: "Annotator"
},
"annotator-harvardx":{
deps: ["annotator"]
},
"share-annotator": {
deps: ["annotator"]
},
"richText-annotator": {
deps: ["annotator", "tinymce"]
},
"reply-annotator": {
deps: ["annotator"]
},
"tags-annotator": {
deps: ["annotator"]
},
"diacritic-annotator": {
deps: ["annotator"]
},
"flagging-annotator": {
deps: ["annotator"]
},
"grouping-annotator": {
deps: ["annotator"]
},
"ova": {
exports: "ova",
deps: [
"annotator", "annotator-harvardx", "video.dev", "vjs.youtube", "rangeslider", "share-annotator",
"richText-annotator", "reply-annotator", "tags-annotator", "flagging-annotator",
"grouping-annotator", "diacritic-annotator", "jquery-Watch", "catch", "handlebars", "URI"
]
},
"osda": {
exports: "osda",
deps: [
"annotator", "annotator-harvardx", "video.dev", "vjs.youtube", "rangeslider", "share-annotator",
"richText-annotator", "reply-annotator", "tags-annotator", "flagging-annotator",
"grouping-annotator", "diacritic-annotator", "openseadragon", "jquery-Watch", "catch", "handlebars",
"URI"
]
},
"tinymce": {
exports: "tinymce"
},
// End of needed by OVA
"moment": {
exports: "moment"
},
"moment-with-locales": {
exports: "moment"
}
}
});
}).call(this, require || RequireJS.require, define || RequireJS.define);