Skip to content

Commit aa2a1b6

Browse files
committed
add ability to receive arguments already html'd
1 parent cfad5b7 commit aa2a1b6

1 file changed

Lines changed: 20 additions & 1 deletion

File tree

src/js/LogDumper.js

Lines changed: 20 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -506,7 +506,26 @@ var logDumper = (function($, module) {
506506
},
507507
$node;
508508
try {
509-
if (methods[method]) {
509+
/*
510+
console.log({
511+
method: method,
512+
args: args,
513+
meta: meta
514+
});
515+
*/
516+
if (meta.format == "html") {
517+
if (typeof args == "object") {
518+
$node = $('<div />', {class:"m_"+method});
519+
for (i = 0; i < args.length; i++) {
520+
$node.append(args[i]);
521+
}
522+
} else {
523+
$node = $(args);
524+
if ($node.find("> .m_"+method).length == 0) {
525+
$node = $('<div />', {class:"m_"+method}).html(args); // $node.wrap('<div />').addClass("m_"+method);
526+
}
527+
}
528+
} else if (methods[method]) {
510529
$node = methods[method](method, args, meta, info);
511530
} else {
512531
$node = methods.default(method, args, meta, info);

0 commit comments

Comments
 (0)