<3 coffeescript
This commit is contained in:
parent
b9cdfbbd3a
commit
a0a30a64ed
@ -138,8 +138,7 @@ $ = (selector, root=d.body) ->
|
|||||||
$$ = (selector, root=d.body) ->
|
$$ = (selector, root=d.body) ->
|
||||||
result = root.querySelectorAll selector
|
result = root.querySelectorAll selector
|
||||||
node for node in result
|
node for node in result
|
||||||
mv = (args...) ->
|
mv = (args..., parent) ->
|
||||||
parent = args.pop()
|
|
||||||
(parent.appendChild child) for child in args
|
(parent.appendChild child) for child in args
|
||||||
getConfig = (name) ->
|
getConfig = (name) ->
|
||||||
GM_getValue name, config[name][0]
|
GM_getValue name, config[name][0]
|
||||||
|
|||||||
@ -182,12 +182,11 @@
|
|||||||
return _results;
|
return _results;
|
||||||
};
|
};
|
||||||
mv = function() {
|
mv = function() {
|
||||||
var args, child, parent, _i, _len, _results;
|
var args, child, parent, _i, _j, _len, _results;
|
||||||
args = 1 <= arguments.length ? __slice.call(arguments, 0) : [];
|
args = 2 <= arguments.length ? __slice.call(arguments, 0, _i = arguments.length - 1) : (_i = 0, []), parent = arguments[_i++];
|
||||||
parent = args.pop();
|
|
||||||
_results = [];
|
_results = [];
|
||||||
for (_i = 0, _len = args.length; _i < _len; _i++) {
|
for (_j = 0, _len = args.length; _j < _len; _j++) {
|
||||||
child = args[_i];
|
child = args[_j];
|
||||||
_results.push(parent.appendChild(child));
|
_results.push(parent.appendChild(child));
|
||||||
}
|
}
|
||||||
return _results;
|
return _results;
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user