vibe-editor 0.0.2 → 0.0.3

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.
Files changed (2) hide show
  1. package/package.json +3 -2
  2. package/src/styles/vibe.css +785 -0
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "vibe-editor",
3
- "version": "0.0.2",
3
+ "version": "0.0.3",
4
4
  "main": "src/scripts/js/VIBE.js",
5
5
  "keywords": [],
6
6
  "author": "Matthias Nowakowski",
@@ -14,7 +14,8 @@
14
14
  "files": [
15
15
  "src/images/*/*",
16
16
  "src/scripts/js/*",
17
- "src/fonts/*"
17
+ "src/fonts/*",
18
+ "src/styles/*.css"
18
19
  ],
19
20
  "dependencies": {
20
21
  "@babel/plugin-transform-classes": "^7.16.7",
@@ -0,0 +1,785 @@
1
+ @import '~bootstrap/dist/css/bootstrap.min.css';
2
+
3
+ @font-face {
4
+ font-family: "Bravura";
5
+ src: url('../fonts/bravura/svg/Bravura.svg#7377dd80c36b825ad2214a14c2421925') format('svg');
6
+ font-weight: normal;
7
+ font-style: normal;
8
+ }
9
+
10
+ @font-face {
11
+ font-family: "BravuraText";
12
+ src: url('../fonts/bravura/svg/BravuraText.svg#f678e10c1f5609a8428c245cc86aa255') format('svg');
13
+ font-weight: normal;
14
+ font-style: normal;}
15
+
16
+ .dropdown button{
17
+ height: 100%;
18
+ }
19
+
20
+ .vibe-container{
21
+ position: absolute;
22
+ width: 100%;
23
+ height: 100%;
24
+ background: white;
25
+ /* overflow: scroll; */
26
+ }
27
+
28
+ body.waiting * {
29
+ cursor: wait !important;
30
+ }
31
+ /*
32
+ .textmode * {
33
+ cursor: text;
34
+ } */
35
+
36
+
37
+ #scoreRects > :is(.notehead, .clef, .meterSig, .keySig, .rest, .harm, .manipulator, .slur, .tie, .tupletNum, .tupletBracket):hover{
38
+ cursor: pointer;
39
+ }
40
+
41
+ #scoreRects .notehead:hover{
42
+ cursor: ns-resize !important;
43
+ }
44
+
45
+ .clickmode{
46
+ cursor: crosshair
47
+ }
48
+
49
+ #vrvSVG{
50
+ top: 0px;
51
+ width: 100%;
52
+ height: auto;
53
+ position: absolute;
54
+ display: flex;
55
+ flex-direction: column;
56
+ }
57
+
58
+ /* .layer:not(.activeLayer) *{
59
+ fill: rgba(0, 0 , 0, 0.2)
60
+ } */
61
+
62
+ /* .layer:not(.activeLayer) :is(.rest, .mRest) > use{
63
+ fill: rgba(0, 0 , 0, 0.0)
64
+ } */
65
+
66
+ .page{
67
+ translate: 0 10%;
68
+ }
69
+
70
+ #vrvSVG .systemLine{
71
+ stroke: black;
72
+ stroke-dasharray: 10rem;
73
+ stroke-width: 1rem;
74
+ }
75
+
76
+ #interactionOverlay{
77
+ position: absolute;
78
+ top: 0px;
79
+ width: 100%;
80
+ z-index: 100;
81
+ }
82
+
83
+ /* This one is for Debugging.
84
+ Change fill-opacity and stroke-opacity to display boundsing boxes*/
85
+ .debug #scoreRects *, #scoreRects .moving{
86
+ stroke-width: 1px;
87
+ stroke: black;
88
+ fill: gray;
89
+ fill-opacity: 0.1;
90
+ stroke-opacity: 1;
91
+ }
92
+
93
+ /* .debug > div#svgContainer > svg#interactionOverlay{
94
+ stroke-width: 2px;
95
+ stroke: red;
96
+ stroke-opacity: 1;
97
+ stroke-dasharray: 10px;
98
+ } */
99
+
100
+ /* .debug #vrvSVG{
101
+ stroke-width: 2px;
102
+ stroke: blue;
103
+ stroke-opacity: 1;
104
+ stroke-dasharray: 2px;
105
+ } */
106
+
107
+ /* .debug .page{
108
+ stroke-width: 2px;
109
+ stroke: green;
110
+ stroke-opacity: 1;
111
+ stroke-dasharray: 5px;
112
+ } */
113
+
114
+ #scoreRects *{
115
+ stroke-width: 1px;
116
+ stroke: black;
117
+ fill: gray;
118
+ fill-opacity: 0;
119
+ stroke-opacity: 0;
120
+ }
121
+
122
+
123
+ text{
124
+ cursor: text;
125
+ }
126
+
127
+
128
+ /*
129
+ #svgContainer, .annotLinkedText, .annotLinkedText *{
130
+ white-space: pre;
131
+ }
132
+ */
133
+
134
+ #svgContainer{
135
+ position: relative;
136
+ height: 100%;
137
+ overflow: scroll;
138
+ }
139
+
140
+ .staff.lastEntered > .staffLine:first-of-type, .staff.lastEntered > .staffLine:last-of-type, .staff.lastEntered ~ .barLine{
141
+ filter: drop-shadow(5px 16px 15px black)
142
+ }
143
+
144
+ /* .note, .note *, .rest, .rest *, .staff, .measure, .manipulator, .slur, .tie *{
145
+ cursor: pointer !important;
146
+ } */
147
+
148
+ /*
149
+ * TOOLBAR
150
+ */
151
+
152
+ .verticalLine{
153
+ border-left: 1px solid black;
154
+ height: auto;
155
+ position: absolute;
156
+ }
157
+
158
+ #insertMode.empty{
159
+ background-image: url(../images/GUI/edit-solid.svg);
160
+ background-position-x: 10%;
161
+ }
162
+
163
+
164
+ #insertMode{
165
+ background-color: white;
166
+ color: black;
167
+ }
168
+
169
+ .smufl{
170
+ font-family: "BravuraText";
171
+ /* font-size: xx-large; */
172
+ font-size: 160%;
173
+ }
174
+
175
+ .harm *{
176
+ font-family: "BravuraText";
177
+ }
178
+
179
+ #playBtn{
180
+ background-image: url(../images/GUI/play-solid.svg);
181
+ background-size: 80%;
182
+ }
183
+
184
+ #pauseBtn{
185
+ background-image: url(../images/GUI/pause-solid.svg);
186
+ background-size: 80%;
187
+ }
188
+
189
+ #rewindBtn{
190
+ background-image: url(../images/GUI/backward-fast-solid.svg);
191
+ background-size: 80%;
192
+ }
193
+
194
+ #zoomInBtn{
195
+ background-image: url(../images/GUI/zoomin.svg);
196
+ background-size: 80%;
197
+ }
198
+
199
+ #zoomOutBtn{
200
+ background-image: url(../images/GUI/zoomout.svg);
201
+ background-size: 80%;
202
+ }
203
+
204
+ #tupletBtn{
205
+ background-image: url(../images/GUI/triplet.svg);
206
+ background-size: 80%;
207
+ color: rgba(0, 0, 0, 0.0)
208
+ }
209
+
210
+ .btn{
211
+ background-repeat: no-repeat;
212
+ background-position-x: center;
213
+ background-position-y: center;
214
+ outline: none;
215
+ font-family: Bravura;
216
+ font-size: larger;
217
+ }
218
+
219
+ .articulationGroup .btn{
220
+ font-size: larger;
221
+ }
222
+
223
+ .btn-group-md{
224
+ display: flex;
225
+ }
226
+
227
+ /* .btn:hover, .btn.selected {
228
+ filter: invert();
229
+ color: black;
230
+ background-color: white;
231
+ } */
232
+
233
+ .btn:hover{
234
+ background-color: lightgray;
235
+ color: #ffffff;
236
+
237
+ }
238
+
239
+ .btn.selected {
240
+ background-color: black;
241
+ color: #ffffff;
242
+
243
+ }
244
+
245
+ #btnToolbar{
246
+ top: 0px;
247
+ transition: 0.5s;
248
+ /*height: 5%;*/
249
+ }
250
+
251
+ #customToolbar :first-child{
252
+ margin-left: 0.25em;
253
+ }
254
+
255
+ #customToolbar{
256
+ box-shadow: 0px 1px 3px lightgray;
257
+ }
258
+
259
+ #btnToolbar{
260
+ box-shadow: inset 0px -3px 3px lightgray;
261
+ }
262
+
263
+ .dropdown-item.selected{
264
+ background-color: antiquewhite;
265
+ font-weight: bold;
266
+ }
267
+
268
+ .accordion-item, .accordion-header{
269
+ border-bottom-style: solid;
270
+ border-bottom-color: black;
271
+ border-bottom-width: 1.5px;
272
+ }
273
+
274
+ .accordion-button{
275
+ padding: 1.5rem 1.25rem !important;
276
+ }
277
+
278
+ #midiDeviceSelect{
279
+ width: 100%;
280
+ }
281
+
282
+ #toggleSidebar{
283
+ border-bottom-left-radius: 0;
284
+ border-top-left-radius: 0;
285
+ }
286
+
287
+ #toggleSidebar.closedSidebar{
288
+ background-image: url(../images/GUI/bars-solid.svg);
289
+ background-size: 80%;
290
+ }
291
+
292
+ #toggleSidebar.openSidebar{
293
+ background-image: url(../images/GUI/bars-solid.svg);
294
+ background-size: 80%;
295
+ }
296
+
297
+ #insertDropdownKM .hide{
298
+ display: none;
299
+ }
300
+
301
+ #insertToggleDiv{
302
+ display: none;
303
+ }
304
+
305
+ #fileSelectGroup{
306
+ align-self: flex-end;
307
+ margin-left: auto;
308
+ display:flex;
309
+ }
310
+
311
+ /* #midiSelectGroup{
312
+ align-self:baseline;
313
+ margin-left: auto;
314
+ display:flex
315
+ } */
316
+
317
+ #handlerGroup{
318
+ display: none
319
+ }
320
+
321
+ #importXML, #importAudioFile{
322
+ display: none;
323
+ }
324
+
325
+ #sidebarContainer{
326
+ position: absolute;
327
+ left: 0;
328
+ top: 0;
329
+ height: 100%;
330
+ border-color: black;
331
+ border-style: solid;
332
+ border-width: 1px;
333
+ background-color: white;
334
+ transition: 0.5s;
335
+ border-top-left-radius: 5px;
336
+ border-bottom-left-radius: 5px;
337
+ overflow: visible;
338
+ display: flex;
339
+ flex-direction: column;
340
+ }
341
+
342
+ #sidebarContainer a{
343
+ display: block;
344
+ padding-left: 10px;
345
+ }
346
+
347
+ /* #sidebarContainer *{
348
+ font-size: 10pt;
349
+ } */
350
+
351
+ #sidebarContainer.closedSidebar{
352
+ visibility: hidden;
353
+ width: 0
354
+ }
355
+
356
+ #sidebarContainer.openSidebar{
357
+ visibility: visible;
358
+ width: 10%;
359
+ }
360
+
361
+ #sidebarContainer.openSidebar ~ div {
362
+ margin-left: 10%;
363
+ width: 90%;
364
+ flex-wrap: wrap;
365
+ display: flex;
366
+ transition: 0.5s;
367
+ }
368
+
369
+ #sidebarContainer.closedSidebar ~ div{
370
+ margin-left: 0;
371
+ width: 100%;
372
+ transition: 0.5s;
373
+ }
374
+
375
+ #sidebarList{
376
+ position: relative;
377
+ overflow: scroll;
378
+ width: 100%;
379
+ resize: vertical;
380
+ }
381
+
382
+ .dropKey, .dropClef, .dropTime, .dropTempo{
383
+ fill: orange;
384
+ color: orange;
385
+ }
386
+
387
+ #timeDiv{
388
+ cursor:pointer !important;
389
+ }
390
+
391
+ #annotList{
392
+ width: 100%;
393
+ position: relative;
394
+ background-color: white;
395
+ border-top-color: black;
396
+ border-left-color: white;
397
+ border-right-color: white;
398
+ border-bottom-color: white;
399
+ border-style: double;
400
+ overflow: scroll;
401
+ order: 2;
402
+ resize: vertical;
403
+ }
404
+
405
+ #annotList > a{
406
+ white-space: pre-line;
407
+ overflow: unset;
408
+ }
409
+
410
+
411
+ .list-group{
412
+ display: block;
413
+ }
414
+
415
+ #btnToolbar{
416
+ display: flex;
417
+ }
418
+
419
+ .btn-toolbar:not(:empty){
420
+ border-top-color: rgba(0, 0, 0, 0);
421
+ border-right-color: rgba(0, 0, 0, 0);
422
+ border-left-color: rgba(0, 0, 0, 0);
423
+ border-bottom-color: black;
424
+ border-bottom-style: solid;
425
+ border-bottom-width: 3px;
426
+ }
427
+
428
+ .tabBtn{
429
+ border-bottom-color: rgba(0, 0, 0, 0.0);
430
+ border-bottom-left-radius: 0% !important;
431
+ border-bottom-right-radius: 0% !important;
432
+ margin-bottom: -3px;
433
+ }
434
+ [role="group"]{
435
+ margin-top: 3px;
436
+ margin-bottom: 3px;
437
+ }
438
+
439
+ #customToolbar [role="group"]{
440
+ margin-top: 1%;
441
+ margin-bottom: 1%;
442
+ }
443
+
444
+ [role="group"] button:first-of-type{
445
+ border-bottom-left-radius: .2rem;
446
+ border-top-left-radius: .2rem;
447
+ }
448
+
449
+ [role="group"] button:last-of-type{
450
+ border-bottom-right-radius: .2rem;
451
+ border-top-right-radius: .2rem;
452
+ }
453
+
454
+ .btn-group-md>.btn, .btn-sm{
455
+ border-radius: 0%;
456
+ }
457
+
458
+
459
+ /*
460
+ * ANNOTATIONS
461
+ */
462
+
463
+ /*
464
+ #annotationCanvas.back *{
465
+ opacity: 0.5;
466
+ }*/
467
+
468
+ /* #annotationCanvas.front *{
469
+ opacity: 1;
470
+ } */
471
+
472
+
473
+
474
+ .annotLinkedText .annotFO{
475
+ /*background-color: rgba(255, 255, 153, 0.8);*/
476
+ background-color: rgba(0, 0, 0, 0.1);
477
+ border-radius: 0px 10px 10px 10px;
478
+ border-color: black;
479
+ border-style: solid;
480
+ border-width: 3px;
481
+ }
482
+
483
+
484
+ .annotStaticText .annotFO div{
485
+ background-color: white;
486
+ border: 1px solid black;
487
+ }
488
+
489
+ .annotDiv{
490
+ height: 100%;
491
+ width: 100%;
492
+ }
493
+
494
+ .annotLine{
495
+ stroke-width: 2px;
496
+ stroke: lightskyblue;
497
+ stroke-dasharray: 2px;
498
+ }
499
+
500
+
501
+ .lineDragRect{
502
+ stroke-width: 1px;
503
+ stroke: black;
504
+ fill: wheat;
505
+ height: 10px;
506
+ width: 10px;
507
+ transform: translate(-5, -5);
508
+ }
509
+
510
+ .highlightAnnotation, .highlightChord{
511
+ /*fill-opacity: 0.1;
512
+ outline-style: dotted;
513
+ outline-width: 0.5px;
514
+ outline-color: black; */
515
+ filter: drop-shadow( 0px 0px 3em teal)
516
+ }
517
+
518
+ #playCursor{
519
+ stroke-width: 10px;
520
+ stroke: orangered;
521
+ }
522
+
523
+ .layer[n="1"] .highlighted{
524
+
525
+ filter: drop-shadow(30px 10px 4px rgb(255, 71, 255));
526
+ }
527
+
528
+ #phantomNote.l1{
529
+ fill: rgb(255, 71, 255)
530
+ }
531
+
532
+
533
+ .layer[n="2"] .highlighted{
534
+ filter: drop-shadow(30px 10px 4px green);
535
+ }
536
+
537
+ #phantomNote.l2{
538
+ fill: green;
539
+ }
540
+
541
+ .layer[n="3"] .highlighted{
542
+ filter: drop-shadow(30px 10px 4px blue);
543
+ }
544
+
545
+ #phantomNote.l3{
546
+ fill: blue;
547
+ }
548
+
549
+ .layer[n="4"] .highlighted{
550
+ filter: drop-shadow(30px 10px 4px orange);
551
+ }
552
+
553
+ #phantomNote.l4{
554
+ fill: orange;
555
+ }
556
+
557
+ .customAnnotShape{
558
+ fill: orange;
559
+ fill-opacity: 0.2;
560
+ outline-style: dotted;
561
+ outline-width: 0.5px;
562
+ outline-color: black;
563
+ }
564
+
565
+ .customAnnotShape.selected{
566
+ outline-style: dashed;
567
+ outline-color:cornflowerblue;
568
+ outline-width: 1;
569
+ }
570
+
571
+
572
+ .annotLinkedText.selected > .annotFO, .annotStaticText.selected > .annotFO{
573
+ border-color:cornflowerblue;
574
+ border-width: 1;
575
+ border-style: dashed;
576
+ }
577
+
578
+
579
+ [contentEditable=false]:empty:not(:focus):before{
580
+ content:attr(data-text);
581
+ color: lightgray;
582
+ }
583
+
584
+ g.currentlyPlaying *{
585
+ fill:red !important;
586
+ fill-opacity: 1;
587
+ }
588
+
589
+ #followerRect{
590
+ fill: red;
591
+ fill-opacity: 0.3;
592
+ outline-style: none;
593
+ }
594
+
595
+ .marked, .marked *{
596
+ /* fill: red !important; */
597
+ filter: invert() drop-shadow(0 0 1rem crimson);
598
+ }
599
+
600
+ .lastAdded{
601
+ fill:darkcyan
602
+ }
603
+
604
+ .playing{
605
+ fill: red
606
+ }
607
+
608
+ /* LABELS */
609
+
610
+ .labelDiv{
611
+ border: 2px solid black;
612
+ border-radius: 10px;
613
+ height: fit-content;
614
+ width: fit-content;
615
+ min-width: 50px;
616
+ background-color: beige;
617
+ font-size: 40px;
618
+ font-family: 'Times New Roman', Times, serif;
619
+ }
620
+
621
+ .labekFO{
622
+ height: 100%;
623
+ width: 100%;
624
+ }
625
+
626
+ /* KEYMODE */
627
+
628
+ #keyModeSelectRect{
629
+ stroke: black;
630
+ stroke-opacity: 1;
631
+ stroke-width: 2px;
632
+ fill: lightskyblue;
633
+ fill-opacity: 0.4;
634
+ }
635
+
636
+ /* #manipulatorCanvas > #cursor{
637
+ display: none
638
+ } */
639
+
640
+ /* CLICK MODE */
641
+
642
+
643
+ /* #phantomNote{
644
+ transform: skew(-20deg);
645
+ } */
646
+
647
+
648
+ .phantomLine, .phantomMarker{
649
+ stroke-width: 2px;
650
+ stroke:black;
651
+ opacity: 0.5;
652
+ }
653
+
654
+
655
+ /*StatusBar*/
656
+
657
+ #statusBar{
658
+ position: absolute;
659
+ height: 5%;
660
+ width: 100%;
661
+ bottom: 0;
662
+ background-color: lightskyblue;
663
+ border-style: outset;
664
+ z-index: 100;
665
+ }
666
+
667
+
668
+ /*Score Manipulator*/
669
+
670
+ #manipulatorCanvas{
671
+ z-index: 101;
672
+ }
673
+
674
+ .signElement{
675
+ stroke: black;
676
+ stroke-width: 10%;
677
+ }
678
+
679
+ #measureAdder, #measureRemover{
680
+ height: 10%;
681
+ width: 10%;
682
+ }
683
+
684
+ #manipulationButton{
685
+ stroke:black;
686
+ stroke-width: 5%;
687
+ fill: antiquewhite;
688
+ }
689
+
690
+ .manipulator:hover *:not(.selected) , .manipulator.selected{
691
+ filter: invert();
692
+ cursor: pointer;
693
+ }
694
+
695
+ .voiceBtn.inactive > rect{
696
+ fill: lightgray;
697
+ }
698
+
699
+ .voiceBtn.inactive > text{
700
+ fill: gray;
701
+ }
702
+
703
+
704
+ .voiceBtn > rect{
705
+ stroke-width: 5%;
706
+ stroke: black;
707
+ width: 100%;
708
+ height: 100%;
709
+ fill: antiquewhite
710
+ }
711
+
712
+ .voiceBtn > text{
713
+ font-size: 100%;
714
+ width: 100%;
715
+ height: 100%;
716
+ fill: black;
717
+ }
718
+
719
+ .tooltip.show{
720
+ display:contents;
721
+ background: skyblue;
722
+ color: #643045;
723
+ font-weight: bold;
724
+ padding: 5px 10px;
725
+ font-size: 13px;
726
+ border-radius: 4px;
727
+ border-color: maroon;
728
+ display: block;
729
+ opacity: 1;
730
+ position: absolute;
731
+ }
732
+
733
+ /* .tooltip{
734
+ inset: !important;
735
+ } */
736
+
737
+ .tooltip.hide{
738
+ display: none
739
+ }
740
+
741
+ .overfillMark{
742
+ color:rgba(0, 0, 0, 0.5);
743
+ font-size: 12em;
744
+ font-weight: bolder;
745
+ z-index: 100;
746
+
747
+ }
748
+
749
+ /*Disable interaction*/
750
+
751
+ #ff_warning{
752
+ background: rgba(0, 0, 0, 0.25);
753
+ width: 100%;
754
+ margin: auto;
755
+ height: 100%;
756
+ text-align: center;
757
+ font-size: xx-large;
758
+ color:crimson;
759
+ text-shadow: -1px 0 black, 0 1px black, 1px 0 black, 0 -1px black;
760
+ }
761
+
762
+ .hideUI{
763
+ display: none !important;
764
+ }
765
+
766
+ #pauseNote{
767
+ display: none;
768
+ }
769
+
770
+ #interactionOverlay, #vrvSVG > svg{
771
+ transform-origin: top left
772
+ }
773
+
774
+ .indexBase{
775
+ font-size: 0.7em;
776
+ }
777
+
778
+ foreignObject > [contenteditable]{
779
+ font-family: Consolas, Menlo, Monaco, Lucida Console, Liberation Mono, DejaVu Sans Mono, Bitstream Vera Sans Mono, Courier New, monospace, serif;
780
+
781
+ }
782
+
783
+ button{
784
+ box-shadow: none !important;
785
+ }