Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
tianyazhichiC
algorithm-visualizer
提交
d467815b
A
algorithm-visualizer
项目概览
tianyazhichiC
/
algorithm-visualizer
与 Fork 源项目一致
从无法访问的项目Fork
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
A
algorithm-visualizer
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
提交
d467815b
编写于
6月 04, 2016
作者:
N
nem035
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
added "use strict" to all files that did not have it
上级
b6f42c55
变更
36
展开全部
隐藏空白更改
内联
并排
Showing
36 changed file
with
106 addition
and
41 deletion
+106
-41
js/dom/loading_slider.js
js/dom/loading_slider.js
+1
-0
js/dom/setup/index.js
js/dom/setup/index.js
+4
-2
js/dom/setup/setup_dividers.js
js/dom/setup/setup_dividers.js
+3
-1
js/dom/setup/setup_document.js
js/dom/setup/setup_document.js
+3
-1
js/dom/setup/setup_files_bar.js
js/dom/setup/setup_files_bar.js
+3
-1
js/dom/setup/setup_interval.js
js/dom/setup/setup_interval.js
+3
-1
js/dom/setup/setup_module_container.js
js/dom/setup/setup_module_container.js
+3
-1
js/dom/setup/setup_powered_by.js
js/dom/setup/setup_powered_by.js
+3
-1
js/dom/setup/setup_scratch_paper.js
js/dom/setup/setup_scratch_paper.js
+3
-1
js/dom/setup/setup_side_menu.js
js/dom/setup/setup_side_menu.js
+3
-1
js/dom/setup/setup_top_menu.js
js/dom/setup/setup_top_menu.js
+2
-0
js/dom/setup/setup_window.js
js/dom/setup/setup_window.js
+3
-1
js/module/data/array1d.js
js/module/data/array1d.js
+2
-0
js/module/data/array2d.js
js/module/data/array2d.js
+3
-1
js/module/data/coordinate_system.js
js/module/data/coordinate_system.js
+3
-1
js/module/data/directed_graph.js
js/module/data/directed_graph.js
+3
-1
js/module/data/undirected_graph.js
js/module/data/undirected_graph.js
+3
-1
js/module/data/weighted_directed_graph.js
js/module/data/weighted_directed_graph.js
+3
-1
js/module/data/weighted_undirected_graph.js
js/module/data/weighted_undirected_graph.js
+3
-1
js/module/tracer/array1d.js
js/module/tracer/array1d.js
+3
-1
js/module/tracer/array2d.js
js/module/tracer/array2d.js
+3
-1
js/module/tracer/chart.js
js/module/tracer/chart.js
+3
-1
js/module/tracer/coordinate_system.js
js/module/tracer/coordinate_system.js
+3
-1
js/module/tracer/directed_graph.js
js/module/tracer/directed_graph.js
+3
-1
js/module/tracer/log.js
js/module/tracer/log.js
+3
-1
js/module/tracer/tracer.js
js/module/tracer/tracer.js
+4
-2
js/module/tracer/undirected_graph.js
js/module/tracer/undirected_graph.js
+3
-1
js/module/tracer/weighted_directed_graph.js
js/module/tracer/weighted_directed_graph.js
+3
-1
js/module/tracer/weighted_undirected_graph.js
js/module/tracer/weighted_undirected_graph.js
+3
-1
js/tracer_manager/util/from_json.js
js/tracer_manager/util/from_json.js
+3
-1
js/tracer_manager/util/index.js
js/tracer_manager/util/index.js
+3
-1
js/tracer_manager/util/refine_by_type.js
js/tracer_manager/util/refine_by_type.js
+2
-0
js/tracer_manager/util/to_json.js
js/tracer_manager/util/to_json.js
+3
-1
public/algorithm_visualizer.js
public/algorithm_visualizer.js
+8
-8
public/algorithm_visualizer.js.map
public/algorithm_visualizer.js.map
+1
-1
public/algorithm_visualizer.min.js.map
public/algorithm_visualizer.min.js.map
+1
-1
未找到文件。
js/dom/loading_slider.js
浏览文件 @
d467815b
'
use strict
'
;
const
showLoadingSlider
=
()
=>
{
$
(
'
#loading-slider
'
).
removeClass
(
'
loaded
'
);
...
...
js/dom/setup/index.js
浏览文件 @
d467815b
'
use strict
'
;
const
setupDividers
=
require
(
'
./setup_dividers
'
);
const
setupDocument
=
require
(
'
./setup_document
'
);
const
setupFilesBar
=
require
(
'
./setup_files_bar
'
);
...
...
@@ -10,7 +12,7 @@ const setupTopMenu = require('./setup_top_menu');
const
setupWindow
=
require
(
'
./setup_window
'
);
/**
* Initializes elements once the app loads in the DOM.
* Initializes elements once the app loads in the DOM.
*/
const
setup
=
()
=>
{
...
...
@@ -52,4 +54,4 @@ const setup = () => {
module
.
exports
=
{
setup
};
\ No newline at end of file
};
js/dom/setup/setup_dividers.js
浏览文件 @
d467815b
'
use strict
'
;
const
app
=
require
(
'
../../app
'
);
const
addDividerToDom
=
(
divider
)
=>
{
...
...
@@ -96,4 +98,4 @@ module.exports = () => {
for
(
let
i
=
0
;
i
<
dividers
.
length
;
i
++
)
{
addDividerToDom
(
dividers
[
i
]);
}
}
\ No newline at end of file
}
js/dom/setup/setup_document.js
浏览文件 @
d467815b
'
use strict
'
;
const
app
=
require
(
'
../../app
'
);
module
.
exports
=
()
=>
{
...
...
@@ -11,4 +13,4 @@ module.exports = () => {
$
(
document
).
mouseup
(
function
(
e
)
{
app
.
getTracerManager
().
command
(
'
mouseup
'
,
e
);
});
};
\ No newline at end of file
};
js/dom/setup/setup_files_bar.js
浏览文件 @
d467815b
'
use strict
'
;
const
definitelyBigger
=
(
x
,
y
)
=>
x
>
(
y
+
2
);
module
.
exports
=
()
=>
{
...
...
@@ -54,4 +56,4 @@ module.exports = () => {
$
(
'
.files_bar > .btn-left
'
).
attr
(
'
disabled
'
,
!
lefter
);
$
(
'
.files_bar > .btn-right
'
).
attr
(
'
disabled
'
,
!
righter
);
});
}
\ No newline at end of file
}
js/dom/setup/setup_interval.js
浏览文件 @
d467815b
'
use strict
'
;
const
app
=
require
(
'
../../app
'
);
const
Toast
=
require
(
'
../toast
'
);
...
...
@@ -47,4 +49,4 @@ module.exports = () => {
tracerManager
.
interval
=
seconds
*
1000
;
Toast
.
showInfoToast
(
message
);
});
};
\ No newline at end of file
};
js/dom/setup/setup_module_container.js
浏览文件 @
d467815b
'
use strict
'
;
const
app
=
require
(
'
../../app
'
);
module
.
exports
=
()
=>
{
...
...
@@ -15,4 +17,4 @@ module.exports = () => {
$module_container
.
on
(
'
DOMMouseScroll mousewheel
'
,
'
.module_wrapper
'
,
function
(
e
)
{
app
.
getTracerManager
().
findOwner
(
this
).
mousewheel
(
e
);
});
}
\ No newline at end of file
}
js/dom/setup/setup_powered_by.js
浏览文件 @
d467815b
'
use strict
'
;
module
.
exports
=
()
=>
{
$
(
'
#powered-by
'
).
click
(
function
()
{
$
(
'
#powered-by-list button
'
).
toggleClass
(
'
collapse
'
);
});
};
\ No newline at end of file
};
js/dom/setup/setup_scratch_paper.js
浏览文件 @
d467815b
'
use strict
'
;
const
app
=
require
(
'
../../app
'
);
const
Server
=
require
(
'
../../server
'
);
const
showAlgorithm
=
require
(
'
../show_algorithm
'
);
...
...
@@ -10,4 +12,4 @@ module.exports = () => {
showAlgorithm
(
category
,
algorithm
,
data
);
});
});
};
\ No newline at end of file
};
js/dom/setup/setup_side_menu.js
浏览文件 @
d467815b
'
use strict
'
;
const
app
=
require
(
'
../../app
'
);
let
sidemenu_percent
;
...
...
@@ -22,4 +24,4 @@ module.exports = () => {
app
.
getTracerManager
().
resize
();
});
}
\ No newline at end of file
}
js/dom/setup/setup_top_menu.js
浏览文件 @
d467815b
'
use strict
'
;
const
app
=
require
(
'
../../app
'
);
const
Server
=
require
(
'
../../server
'
);
const
Toast
=
require
(
'
../toast
'
);
...
...
js/dom/setup/setup_window.js
浏览文件 @
d467815b
'
use strict
'
;
const
app
=
require
(
'
../../app
'
);
module
.
exports
=
function
()
{
$
(
window
).
resize
(
function
()
{
app
.
getTracerManager
().
resize
();
});
};
\ No newline at end of file
};
js/module/data/array1d.js
浏览文件 @
d467815b
'
use strict
'
;
const
Array2D
=
require
(
'
./array2d
'
);
const
random
=
(
N
,
min
,
max
)
=>
{
...
...
js/module/data/array2d.js
浏览文件 @
d467815b
'
use strict
'
;
const
random
=
(
N
,
M
,
min
,
max
)
=>
{
if
(
!
N
)
N
=
10
;
if
(
!
M
)
M
=
10
;
...
...
@@ -24,4 +26,4 @@ const randomSorted = (N, M, min, max) => {
module
.
exports
=
{
random
,
randomSorted
};
\ No newline at end of file
};
js/module/data/coordinate_system.js
浏览文件 @
d467815b
'
use strict
'
;
const
random
=
(
N
,
min
,
max
)
=>
{
if
(
!
N
)
N
=
7
;
if
(
!
min
)
min
=
1
;
...
...
@@ -12,4 +14,4 @@ const random = (N, min, max) => {
module
.
exports
=
{
random
};
\ No newline at end of file
};
js/module/data/directed_graph.js
浏览文件 @
d467815b
'
use strict
'
;
const
random
=
(
N
,
ratio
)
=>
{
if
(
!
N
)
N
=
5
;
if
(
!
ratio
)
ratio
=
.
3
;
...
...
@@ -15,4 +17,4 @@ const random = (N, ratio) => {
module
.
exports
=
{
random
};
\ No newline at end of file
};
js/module/data/undirected_graph.js
浏览文件 @
d467815b
'
use strict
'
;
const
random
=
(
N
,
ratio
)
=>
{
if
(
!
N
)
N
=
5
;
if
(
!
ratio
)
ratio
=
.
3
;
...
...
@@ -15,4 +17,4 @@ const random = (N, ratio) => {
module
.
exports
=
{
random
};
\ No newline at end of file
};
js/module/data/weighted_directed_graph.js
浏览文件 @
d467815b
'
use strict
'
;
const
random
=
(
N
,
ratio
,
min
,
max
)
=>
{
if
(
!
N
)
N
=
5
;
if
(
!
ratio
)
ratio
=
.
3
;
...
...
@@ -17,4 +19,4 @@ const random = (N, ratio, min, max) => {
module
.
exports
=
{
random
};
\ No newline at end of file
};
js/module/data/weighted_undirected_graph.js
浏览文件 @
d467815b
'
use strict
'
;
const
random
=
(
N
,
ratio
,
min
,
max
)
=>
{
if
(
!
N
)
N
=
5
;
if
(
!
ratio
)
ratio
=
.
3
;
...
...
@@ -17,4 +19,4 @@ const random = (N, ratio, min, max) => {
module
.
exports
=
{
random
};
\ No newline at end of file
};
js/module/tracer/array1d.js
浏览文件 @
d467815b
'
use strict
'
;
const
Array2DTracer
=
require
(
'
./array2d
'
);
class
Array1DTracer
extends
Array2DTracer
{
...
...
@@ -42,4 +44,4 @@ class Array1DTracer extends Array2DTracer {
}
}
module
.
exports
=
Array1DTracer
;
\ No newline at end of file
module
.
exports
=
Array1DTracer
;
js/module/tracer/array2d.js
浏览文件 @
d467815b
'
use strict
'
;
const
Tracer
=
require
(
'
./tracer
'
);
const
{
...
...
@@ -335,4 +337,4 @@ const initView = (tracer) => {
tracer
.
$container
.
append
(
tracer
.
$table
);
};
module
.
exports
=
Array2DTracer
;
\ No newline at end of file
module
.
exports
=
Array2DTracer
;
js/module/tracer/chart.js
浏览文件 @
d467815b
'
use strict
'
;
const
Tracer
=
require
(
'
./tracer
'
);
class
ChartTracer
extends
Tracer
{
...
...
@@ -135,4 +137,4 @@ const initView = (tracer) => {
});
};
module
.
exports
=
ChartTracer
;
\ No newline at end of file
module
.
exports
=
ChartTracer
;
js/module/tracer/coordinate_system.js
浏览文件 @
d467815b
'
use strict
'
;
const
DirectedGraphTracer
=
require
(
'
./directed_graph
'
);
class
CoordinateSystemTracer
extends
DirectedGraphTracer
{
...
...
@@ -137,4 +139,4 @@ const initView = (tracer) => {
});
};
module
.
exports
=
CoordinateSystemTracer
;
\ No newline at end of file
module
.
exports
=
CoordinateSystemTracer
;
js/module/tracer/directed_graph.js
浏览文件 @
d467815b
'
use strict
'
;
const
Tracer
=
require
(
'
./tracer
'
);
const
{
...
...
@@ -398,4 +400,4 @@ sigma.canvas.edges.arrow = function (edge, source, target, context, settings) {
}
};
module
.
exports
=
DirectedGraphTracer
;
\ No newline at end of file
module
.
exports
=
DirectedGraphTracer
;
js/module/tracer/log.js
浏览文件 @
d467815b
'
use strict
'
;
const
Tracer
=
require
(
'
./tracer
'
);
class
LogTracer
extends
Tracer
{
...
...
@@ -53,4 +55,4 @@ const initView = (tracer) => {
tracer
.
$container
.
append
(
tracer
.
$wrapper
);
};
module
.
exports
=
LogTracer
;
\ No newline at end of file
module
.
exports
=
LogTracer
;
js/module/tracer/tracer.js
浏览文件 @
d467815b
'
use strict
'
;
const
app
=
require
(
'
../../app
'
);
const
{
...
...
@@ -9,7 +11,7 @@ class Tracer {
static
getClassName
()
{
return
'
Tracer
'
;
}
constructor
(
name
)
{
this
.
module
=
this
.
constructor
;
...
...
@@ -105,4 +107,4 @@ class Tracer {
}
}
module
.
exports
=
Tracer
;
\ No newline at end of file
module
.
exports
=
Tracer
;
js/module/tracer/undirected_graph.js
浏览文件 @
d467815b
'
use strict
'
;
const
DirectedGraphTracer
=
require
(
'
./directed_graph
'
);
class
UndirectedGraphTracer
extends
DirectedGraphTracer
{
...
...
@@ -80,4 +82,4 @@ const initView = (tracer) => {
});
};
module
.
exports
=
UndirectedGraphTracer
;
\ No newline at end of file
module
.
exports
=
UndirectedGraphTracer
;
js/module/tracer/weighted_directed_graph.js
浏览文件 @
d467815b
'
use strict
'
;
const
DirectedGraphTracer
=
require
(
'
./directed_graph
'
);
const
{
...
...
@@ -193,4 +195,4 @@ const initView = (tracer) => {
});
};
module
.
exports
=
WeightedDirectedGraphTracer
;
\ No newline at end of file
module
.
exports
=
WeightedDirectedGraphTracer
;
js/module/tracer/weighted_undirected_graph.js
浏览文件 @
d467815b
'
use strict
'
;
const
WeightedDirectedGraphTracer
=
require
(
'
./weighted_directed_graph
'
);
const
UndirectedGraphTracer
=
require
(
'
./undirected_graph
'
);
...
...
@@ -46,4 +48,4 @@ const initView = (tracer) => {
});
};
module
.
exports
=
WeightedUndirectedGraphTracer
;
\ No newline at end of file
module
.
exports
=
WeightedUndirectedGraphTracer
;
js/tracer_manager/util/from_json.js
浏览文件 @
d467815b
'
use strict
'
;
const
{
parse
}
=
JSON
;
...
...
@@ -8,4 +10,4 @@ const fromJSON = (obj) => {
});
};
module
.
exports
=
fromJSON
;
\ No newline at end of file
module
.
exports
=
fromJSON
;
js/tracer_manager/util/index.js
浏览文件 @
d467815b
'
use strict
'
;
const
toJSON
=
require
(
'
./to_json
'
);
const
fromJSON
=
require
(
'
./from_json
'
);
const
refineByType
=
require
(
'
./refine_by_type
'
);
...
...
@@ -6,4 +8,4 @@ module.exports = {
toJSON
,
fromJSON
,
refineByType
};
\ No newline at end of file
};
js/tracer_manager/util/refine_by_type.js
浏览文件 @
d467815b
'
use strict
'
;
const
refineByType
=
(
item
)
=>
{
switch
(
typeof
(
item
))
{
case
'
number
'
:
...
...
js/tracer_manager/util/to_json.js
浏览文件 @
d467815b
'
use strict
'
;
const
{
stringify
}
=
JSON
;
...
...
@@ -8,4 +10,4 @@ const toJSON = (obj) => {
});
};
module
.
exports
=
toJSON
;
\ No newline at end of file
module
.
exports
=
toJSON
;
public/algorithm_visualizer.js
浏览文件 @
d467815b
此差异已折叠。
点击以展开。
public/algorithm_visualizer.js.map
浏览文件 @
d467815b
此差异已折叠。
点击以展开。
public/algorithm_visualizer.min.js.map
浏览文件 @
d467815b
此差异已折叠。
点击以展开。
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录