bn-lightweight-charts 0.2.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- bn_lightweight_charts/__init__.py +7 -0
- bn_lightweight_charts/abstract.py +1001 -0
- bn_lightweight_charts/chart.py +241 -0
- bn_lightweight_charts/drawings.py +278 -0
- bn_lightweight_charts/js/bundle.dev.js +2472 -0
- bn_lightweight_charts/js/bundle.js +1 -0
- bn_lightweight_charts/js/index.html +25 -0
- bn_lightweight_charts/js/index_bn.html +144 -0
- bn_lightweight_charts/js/lightweight-charts.js +15475 -0
- bn_lightweight_charts/js/lightweight-charts.standalone.development.js +15475 -0
- bn_lightweight_charts/js/styles.css +257 -0
- bn_lightweight_charts/polygon.py +470 -0
- bn_lightweight_charts/table.py +138 -0
- bn_lightweight_charts/toolbox.py +45 -0
- bn_lightweight_charts/topbar.py +128 -0
- bn_lightweight_charts/util.py +227 -0
- bn_lightweight_charts/widgets.py +357 -0
- bn_lightweight_charts-0.2.0.dist-info/METADATA +317 -0
- bn_lightweight_charts-0.2.0.dist-info/RECORD +21 -0
- bn_lightweight_charts-0.2.0.dist-info/WHEEL +4 -0
- bn_lightweight_charts-0.2.0.dist-info/licenses/LICENSE +22 -0
|
@@ -0,0 +1,257 @@
|
|
|
1
|
+
:root {
|
|
2
|
+
/*--bg-color:#0c0d0f;*/
|
|
3
|
+
--bg-color:rgb(18,24,38);
|
|
4
|
+
--hover-bg-color: #3c434c;
|
|
5
|
+
--click-bg-color: #50565E;
|
|
6
|
+
--active-bg-color: rgba(0, 122, 255, 0.7);
|
|
7
|
+
--muted-bg-color: rgba(0, 122, 255, 0.3);
|
|
8
|
+
--border-color: #3C434C;
|
|
9
|
+
--color: #d8d9db;
|
|
10
|
+
--active-color: #ececed;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
body {
|
|
14
|
+
/*background-color: rgb(0,0,0);*/
|
|
15
|
+
background-color: rgb(18,24,38);
|
|
16
|
+
color: rgba(19, 23, 34, 1);
|
|
17
|
+
overflow: hidden;
|
|
18
|
+
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu,
|
|
19
|
+
Cantarell, "Helvetica Neue", sans-serif;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
.handler {
|
|
23
|
+
display: flex;
|
|
24
|
+
flex-direction: column;
|
|
25
|
+
position: relative;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
.resize-handle {
|
|
29
|
+
position: absolute;
|
|
30
|
+
left: 0;
|
|
31
|
+
width: 100%;
|
|
32
|
+
height: 2px;
|
|
33
|
+
z-index: 10;
|
|
34
|
+
background: grey;
|
|
35
|
+
cursor: ns-resize;
|
|
36
|
+
bottom: 8px;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
.toolbox {
|
|
40
|
+
position: absolute;
|
|
41
|
+
z-index: 2000;
|
|
42
|
+
display: flex;
|
|
43
|
+
align-items: center;
|
|
44
|
+
top: 25%;
|
|
45
|
+
border: 2px solid var(--border-color);
|
|
46
|
+
border-left: none;
|
|
47
|
+
border-top-right-radius: 4px;
|
|
48
|
+
border-bottom-right-radius: 4px;
|
|
49
|
+
background-color: rgba(25, 27, 30, 0.5);
|
|
50
|
+
flex-direction: column;
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
.toolbox-button {
|
|
54
|
+
margin: 3px;
|
|
55
|
+
border-radius: 4px;
|
|
56
|
+
display: flex;
|
|
57
|
+
background-color: transparent;
|
|
58
|
+
}
|
|
59
|
+
.toolbox-button:hover {
|
|
60
|
+
background-color: rgba(80, 86, 94, 0.7);
|
|
61
|
+
}
|
|
62
|
+
.toolbox-button:active {
|
|
63
|
+
background-color: rgba(90, 106, 104, 0.7);
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
.active-toolbox-button {
|
|
67
|
+
background-color: var(--active-bg-color) !important;
|
|
68
|
+
}
|
|
69
|
+
.active-toolbox-button g {
|
|
70
|
+
fill: var(--active-color);
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
.context-menu {
|
|
74
|
+
position: absolute;
|
|
75
|
+
z-index: 1000;
|
|
76
|
+
background: rgb(50, 50, 50);
|
|
77
|
+
color: var(--active-color);
|
|
78
|
+
display: none;
|
|
79
|
+
border-radius: 5px;
|
|
80
|
+
padding: 3px 3px;
|
|
81
|
+
font-size: 13px;
|
|
82
|
+
cursor: default;
|
|
83
|
+
}
|
|
84
|
+
.context-menu-item {
|
|
85
|
+
display: flex;
|
|
86
|
+
align-items: center;
|
|
87
|
+
justify-content: space-between;
|
|
88
|
+
padding: 2px 10px;
|
|
89
|
+
margin: 1px 0px;
|
|
90
|
+
border-radius: 3px;
|
|
91
|
+
}
|
|
92
|
+
.context-menu-item:hover {
|
|
93
|
+
background-color: var(--muted-bg-color);
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
.color-picker {
|
|
97
|
+
max-width: 170px;
|
|
98
|
+
background-color: var(--bg-color);
|
|
99
|
+
position: absolute;
|
|
100
|
+
z-index: 10000;
|
|
101
|
+
display: none;
|
|
102
|
+
flex-direction: column;
|
|
103
|
+
align-items: center;
|
|
104
|
+
border: 2px solid var(--border-color);
|
|
105
|
+
border-radius: 8px;
|
|
106
|
+
cursor: default;
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
|
|
110
|
+
/* topbar-related */
|
|
111
|
+
.topbar {
|
|
112
|
+
background-color: var(--bg-color);
|
|
113
|
+
border-bottom: 2px solid var(--border-color);
|
|
114
|
+
display: flex;
|
|
115
|
+
align-items: center;
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
.topbar-container {
|
|
119
|
+
display: flex;
|
|
120
|
+
align-items: center;
|
|
121
|
+
flex-grow: 1;
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
.topbar-button {
|
|
125
|
+
border: none;
|
|
126
|
+
padding: 2px 5px;
|
|
127
|
+
margin: 4px 10px;
|
|
128
|
+
font-size: 13px;
|
|
129
|
+
border-radius: 4px;
|
|
130
|
+
color: var(--color);
|
|
131
|
+
background-color: transparent;
|
|
132
|
+
}
|
|
133
|
+
.topbar-button:hover {
|
|
134
|
+
background-color: var(--hover-bg-color)
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
.topbar-button:active {
|
|
138
|
+
background-color: var(--click-bg-color);
|
|
139
|
+
color: var(--active-color);
|
|
140
|
+
font-weight: 500;
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
.switcher-button:active {
|
|
144
|
+
background-color: var(--click-bg-color);
|
|
145
|
+
color: var(--color);
|
|
146
|
+
font-weight: normal;
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
.active-switcher-button {
|
|
150
|
+
background-color: var(--active-bg-color) !important;
|
|
151
|
+
color: var(--active-color) !important;
|
|
152
|
+
font-weight: 500;
|
|
153
|
+
}
|
|
154
|
+
|
|
155
|
+
.topbar-textbox {
|
|
156
|
+
margin: 0px 18px;
|
|
157
|
+
font-size: 16px;
|
|
158
|
+
color: var(--color);
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
.topbar-textbox-input {
|
|
162
|
+
background-color: var(--bg-color);
|
|
163
|
+
color: var(--color);
|
|
164
|
+
border: 1px solid var(--color);
|
|
165
|
+
}
|
|
166
|
+
|
|
167
|
+
.topbar-menu {
|
|
168
|
+
position: absolute;
|
|
169
|
+
display: none;
|
|
170
|
+
z-index: 10000;
|
|
171
|
+
background-color: var(--bg-color);
|
|
172
|
+
border-radius: 2px;
|
|
173
|
+
border: 2px solid var(--border-color);
|
|
174
|
+
border-top: none;
|
|
175
|
+
align-items: flex-start;
|
|
176
|
+
max-height: 80%;
|
|
177
|
+
overflow-y: auto;
|
|
178
|
+
}
|
|
179
|
+
|
|
180
|
+
.topbar-separator {
|
|
181
|
+
width: 1px;
|
|
182
|
+
height: 20px;
|
|
183
|
+
background-color: var(--border-color);
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
.searchbox {
|
|
187
|
+
position: absolute;
|
|
188
|
+
top: 0;
|
|
189
|
+
bottom: 200px;
|
|
190
|
+
left: 0;
|
|
191
|
+
right: 0;
|
|
192
|
+
margin: auto;
|
|
193
|
+
width: 150px;
|
|
194
|
+
height: 30px;
|
|
195
|
+
padding: 5px;
|
|
196
|
+
z-index: 1000;
|
|
197
|
+
align-items: center;
|
|
198
|
+
background-color: rgba(30 ,30, 30, 0.9);
|
|
199
|
+
border: 2px solid var(--border-color);
|
|
200
|
+
border-radius: 5px;
|
|
201
|
+
display: flex;
|
|
202
|
+
|
|
203
|
+
}
|
|
204
|
+
.searchbox input {
|
|
205
|
+
text-align: center;
|
|
206
|
+
width: 100px;
|
|
207
|
+
margin-left: 10px;
|
|
208
|
+
background-color: var(--muted-bg-color);
|
|
209
|
+
color: var(--active-color);
|
|
210
|
+
font-size: 20px;
|
|
211
|
+
border: none;
|
|
212
|
+
outline: none;
|
|
213
|
+
border-radius: 2px;
|
|
214
|
+
}
|
|
215
|
+
|
|
216
|
+
.spinner {
|
|
217
|
+
width: 30px;
|
|
218
|
+
height: 30px;
|
|
219
|
+
border: 4px solid rgba(255, 255, 255, 0.6);
|
|
220
|
+
border-top: 4px solid var(--active-bg-color);
|
|
221
|
+
border-radius: 50%;
|
|
222
|
+
position: absolute;
|
|
223
|
+
top: 50%;
|
|
224
|
+
left: 50%;
|
|
225
|
+
z-index: 1000;
|
|
226
|
+
transform: translate(-50%, -50%);
|
|
227
|
+
display: none;
|
|
228
|
+
}
|
|
229
|
+
|
|
230
|
+
.legend {
|
|
231
|
+
position: absolute;
|
|
232
|
+
z-index: 3000;
|
|
233
|
+
pointer-events: none;
|
|
234
|
+
top: 10px;
|
|
235
|
+
left: 10px;
|
|
236
|
+
display: none;
|
|
237
|
+
flex-direction: column;
|
|
238
|
+
}
|
|
239
|
+
.series-container {
|
|
240
|
+
display: flex;
|
|
241
|
+
flex-direction: column;
|
|
242
|
+
pointer-events: auto;
|
|
243
|
+
overflow-y: auto;
|
|
244
|
+
max-height: 80vh;
|
|
245
|
+
}
|
|
246
|
+
.series-container::-webkit-scrollbar {
|
|
247
|
+
width: 0px;
|
|
248
|
+
}
|
|
249
|
+
.legend-toggle-switch {
|
|
250
|
+
border-radius: 4px;
|
|
251
|
+
margin-left: 10px;
|
|
252
|
+
pointer-events: auto;
|
|
253
|
+
}
|
|
254
|
+
.legend-toggle-switch:hover {
|
|
255
|
+
cursor: pointer;
|
|
256
|
+
background-color: rgba(50, 50, 50, 0.5);
|
|
257
|
+
}
|