- admittedly this should probably be tracked via a link but ... not really sure how to do that and the last time I did it, I had massive issues with updating on other machines.
25 lines
No EOL
1.5 KiB
Text
25 lines
No EOL
1.5 KiB
Text
[0;1;40;37m[?33hAnsiLove.[35mrender[0m([32m"cl!-al02.ans"[37m, [1;33mfunction [37m([0mcanvas[1m, [0msauce[1m) {
|
||
document.[35mgetElementById[37m([0;32m"ansi-container"[1;37m).[35mappendChild[37m([0mcanvas[1m);
|
||
[33mconsole[37m.log(sauce);
|
||
}, {[0;32m"bits"[1;37m: [0;32m"9"[1;37m});
|
||
|
||
[0m// And for producing extremely long files,
|
||
// spanning multiple canvas elements by splitting every nth row...
|
||
|
||
[0;1;40;37m[?33hAnsiLove.[35msplitRender[0m([32m"long_ansi.ans"[37m, [1;33mfunction [37m([0mcanvases[1m, [0msauce[1m) {
|
||
canvases.[35mforEach[37m([1;33mfunction [37m([0mcanvas[1m) {
|
||
canvas.[35mstyle[37m.[35mverticalAlign [37m= [0;32m"bottom"; [37m// For perfect, gap-less viewing
|
||
[1mdocument.[35mgetElementById[37m([0;32m"ansi-container"[1;37m).[35mappendChild[37m([0mcanvas[1m);
|
||
});
|
||
[33mconsole[37m.log(sauce);
|
||
}, [31m27[37m, {[0;32m"bits"[1;37m: [0;32m"8"[1;37m});
|
||
|
||
[0m// And for [5mansimations[25m...
|
||
|
||
[1;33mvar [1;37mcontroller = [0;1;40;37m[?33hAnsiLove.[35manimate[0m([32m"ansimation.ans"[37m, [1;33mfunction [37m([0mcanvas[1m, [0msauce[1m) {
|
||
document.[35mgetElementById[37m([0;32m"ansi-container"[1;37m).[35mappendChild[37m([0mcanvas[1m);
|
||
[33mconsole[37m.log(sauce);
|
||
controller.play([31m2800[37m, [33mfunction [1;37m() {
|
||
[33mconsole[37m.log([0;32m"Finished Playing"[1;37m);
|
||
});
|
||
}, {[0;32m"bits"[1;37m: [0;32m"9"[1;37m}); |