-
Notifications
You must be signed in to change notification settings - Fork 2
/
index.html
94 lines (93 loc) · 1.95 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Simple Modular Synth</title>
<style>
html,
body {
min-height: 100%;
margin: 0;
padding: 0;
}
#app {
height: 100vh;
width: 100vw;
display: flex;
flex-wrap: nowrap;
}
.module {
width: 100px;
height: 50px;
background-color: #fafafa;
border-radius: 4px;
padding: 10px;
position: absolute;
z-index: 2;
text-align: center;
border: 1px solid #aaa;
}
.module.active,
.module:hover {
border: 1px solid #aaf;
}
.module button {
display: block;
position: absolute;
z-index: 3;
border-radius: 100%;
padding: 0;
width: 16px;
height: 16px;
margin-left: -8px;
border: none;
background-color: #faa;
}
.module button:hover {
background-color: #aaf;
}
.module button.active {
background-color: #f00;
}
.module input {
width: 90%;
margin-top: 12px;
}
svg {
position: absolute;
z-index: 2;
pointer-events: none;
}
path {
fill: none;
stroke: #dfdfdf;
stroke-width: 4px;
pointer-events: all;
cursor: pointer;
}
path:hover {
stroke: #aaf;
}
.graph {
position: relative;
flex: 1;
height: 100vh;
background-size: 30px 30px;
background-image: radial-gradient(circle, #ddd 1px, transparent 1px);
}
.sidebar {
order: 1;
flex: 0 0 10vw;
background-color: #eee;
padding: 0 2rem;
overflow-y: scroll;
position: relative;
z-index: 3;
}
</style>
</head>
<body>
<div id="app"></div>
<script type="module" src="./index.js"></script>
</body>
</html>