forked from caitp/angular-drop
-
Notifications
You must be signed in to change notification settings - Fork 0
/
angularDrop.js
63 lines (55 loc) · 1.34 KB
/
angularDrop.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
angularDropFiles = {
'angularDropSrc': [
'src/utils.js',
'src/dndDOM.js',
'src/draggable.js',
'src/droppable.js',
'src/provider.js',
'src/public.js'
],
'angularDropTest': [
'test/**/*.spec.js',
],
'karma': [
'bower_components/jquery/dist/jquery.js',
'test/jquery_remove.js',
'bower_components/angular/angular.js',
'bower_components/angular-mocks/angular-mocks.js',
'@angularDropSrc',
'src/publish.js',
'@angularDropTest',
],
'karmaExclude': [
'test/jquery_alias.js',
],
'karmaJquery': [
'bower_components/jquery/dist/jquery.js',
'bower_components/angular/angular.js',
'bower_components/angular-mocks/angular-mocks.js',
'test/jquery_alias.js',
'@angularDropSrc',
'src/publish.js',
'@angularDropTest',
],
'karmaJqueryExclude': [
'test/jquery_remove.js'
]
};
if (exports) {
exports.files = angularDropFiles;
exports.mergeFilesFor = function() {
var files = [];
Array.prototype.slice.call(arguments, 0).forEach(function(filegroup) {
angularDropFiles[filegroup].forEach(function(file) {
// replace @ref
var match = file.match(/^\@(.*)/);
if (match) {
files = files.concat(angularDropFiles[match[1]]);
} else {
files.push(file);
}
});
});
return files;
};
}