diff options
author | Lunny Xiao <xiaolunwen@gmail.com> | 2019-11-15 09:27:50 +0800 |
---|---|---|
committer | techknowlogick <techknowlogick@gitea.io> | 2019-11-14 20:27:50 -0500 |
commit | 42ada741e3360b14ede8772aa1a2dd3e83209033 (patch) | |
tree | 1091690dd254f71887ffc2ad00ff2839ebcd33c4 /web_src | |
parent | 06a8504c784fe404bcae92028515add816383729 (diff) | |
download | gitea-42ada741e3360b14ede8772aa1a2dd3e83209033.tar.gz gitea-42ada741e3360b14ede8772aa1a2dd3e83209033.zip |
Pack web_src/js/draw.js to public/js/index.js (#8975)
* pack web_src/js/draw.js to public/js/index.js
* fix eslint
Diffstat (limited to 'web_src')
-rw-r--r-- | web_src/js/draw.js | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/web_src/js/draw.js b/web_src/js/draw.js new file mode 100644 index 0000000000..bb9c7f28c7 --- /dev/null +++ b/web_src/js/draw.js @@ -0,0 +1,15 @@ +/* globals gitGraph */ + +$(() => { + const graphList = []; + + if (!document.getElementById('graph-canvas')) { + return; + } + + $('#graph-raw-list li span.node-relation').each(function () { + graphList.push($(this).text()); + }); + + gitGraph(document.getElementById('graph-canvas'), graphList); +}); |