@opendaw/studio-core 0.0.22 → 0.0.23
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.
package/dist/Colors.d.ts.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"Colors.d.ts","sourceRoot":"","sources":["../src/Colors.ts"],"names":[],"mappings":"
|
1
|
+
{"version":3,"file":"Colors.d.ts","sourceRoot":"","sources":["../src/Colors.ts"],"names":[],"mappings":"AAWA,eAAO,MAAM,MAAM;;;;;;;;;;;;;CAalB,CAAA"}
|
package/dist/Colors.js
CHANGED
@@ -1,15 +1,23 @@
|
|
1
|
-
|
1
|
+
import { InaccessibleProperty } from "@opendaw/lib-std";
|
2
|
+
const getPropertyValue = (() => {
|
3
|
+
if (typeof document === "undefined") {
|
4
|
+
// This will compile in React but fails at runtime when no document is available
|
5
|
+
return (_property) => InaccessibleProperty;
|
6
|
+
}
|
7
|
+
const computedStyle = getComputedStyle(document.documentElement);
|
8
|
+
return (property) => computedStyle.getPropertyValue(property);
|
9
|
+
})();
|
2
10
|
export const Colors = {
|
3
|
-
blue:
|
4
|
-
green:
|
5
|
-
yellow:
|
6
|
-
cream:
|
7
|
-
orange:
|
8
|
-
red:
|
9
|
-
purple:
|
10
|
-
bright:
|
11
|
-
gray:
|
12
|
-
dark:
|
13
|
-
shadow:
|
14
|
-
black:
|
11
|
+
blue: getPropertyValue("--color-blue"),
|
12
|
+
green: getPropertyValue("--color-green"),
|
13
|
+
yellow: getPropertyValue("--color-yellow"),
|
14
|
+
cream: getPropertyValue("--color-cream"),
|
15
|
+
orange: getPropertyValue("--color-orange"),
|
16
|
+
red: getPropertyValue("--color-red"),
|
17
|
+
purple: getPropertyValue("--color-purple"),
|
18
|
+
bright: getPropertyValue("--color-bright"),
|
19
|
+
gray: getPropertyValue("--color-gray"),
|
20
|
+
dark: getPropertyValue("--color-dark"),
|
21
|
+
shadow: getPropertyValue("--color-shadow"),
|
22
|
+
black: getPropertyValue("--color-black")
|
15
23
|
};
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"CaptureMidi.d.ts","sourceRoot":"","sources":["../../src/capture/CaptureMidi.ts"],"names":[],"mappings":"AAAA,OAAO,EAQH,MAAM,EAEN,UAAU,EAEb,MAAM,kBAAkB,CAAA;AAGzB,OAAO,EAAC,YAAY,EAAE,cAAc,EAAC,MAAM,uBAAuB,CAAA;AAClE,OAAO,EAAC,OAAO,EAAC,MAAM,WAAW,CAAA;AAEjC,OAAO,EAAC,gBAAgB,EAAC,MAAM,oBAAoB,CAAA;AACnD,OAAO,EAAC,cAAc,EAAC,MAAM,kBAAkB,CAAA;AAI/C,qBAAa,WAAY,SAAQ,OAAO,CAAC,cAAc,CAAC;;gBAQxC,OAAO,EAAE,cAAc,EAAE,YAAY,EAAE,YAAY,EAAE,cAAc,EAAE,cAAc;
|
1
|
+
{"version":3,"file":"CaptureMidi.d.ts","sourceRoot":"","sources":["../../src/capture/CaptureMidi.ts"],"names":[],"mappings":"AAAA,OAAO,EAQH,MAAM,EAEN,UAAU,EAEb,MAAM,kBAAkB,CAAA;AAGzB,OAAO,EAAC,YAAY,EAAE,cAAc,EAAC,MAAM,uBAAuB,CAAA;AAClE,OAAO,EAAC,OAAO,EAAC,MAAM,WAAW,CAAA;AAEjC,OAAO,EAAC,gBAAgB,EAAC,MAAM,oBAAoB,CAAA;AACnD,OAAO,EAAC,cAAc,EAAC,MAAM,kBAAkB,CAAA;AAI/C,qBAAa,WAAY,SAAQ,OAAO,CAAC,cAAc,CAAC;;gBAQxC,OAAO,EAAE,cAAc,EAAE,YAAY,EAAE,YAAY,EAAE,cAAc,EAAE,cAAc;IAqC/F,IAAI,KAAK,IAAI,MAAM,CAKlB;IAED,IAAI,WAAW,IAAI,MAAM,CAAC,MAAM,CAAC,CAIhC;IAEK,gBAAgB,CAAC,EAAE,EAAE,gBAAgB,GAAG,OAAO,CAAC,IAAI,CAAC;IAgB3D,cAAc,CAAC,EAAC,OAAO,EAAC,EAAE,gBAAgB,GAAG,UAAU;CA8C1D"}
|
@@ -33,18 +33,17 @@ export class CaptureMidi extends Capture {
|
|
33
33
|
console.debug(MidiData.debug(event.data));
|
34
34
|
const data = asDefined(event.data);
|
35
35
|
const engine = manager.project.engine;
|
36
|
-
|
37
|
-
if (MidiData.isNoteOff(data) || (isNoteOn && MidiData.readVelocity(data) === 0)) {
|
38
|
-
engine.noteOff(this.uuid, MidiData.readPitch(data));
|
39
|
-
}
|
40
|
-
else if (isNoteOn) {
|
36
|
+
if (MidiData.isNoteOn(data)) {
|
41
37
|
engine.noteOn(this.uuid, MidiData.readPitch(data), MidiData.readVelocity(data));
|
42
38
|
}
|
39
|
+
else if (MidiData.isNoteOff(data)) {
|
40
|
+
engine.noteOff(this.uuid, MidiData.readPitch(data));
|
41
|
+
}
|
43
42
|
}));
|
44
43
|
}
|
45
44
|
get label() {
|
46
45
|
return MidiDevices.get().mapOr(midiAccess => this.deviceId.getValue().match({
|
47
|
-
none: () => this.armed.getValue() ? "Listening to all MIDI devices" : "
|
46
|
+
none: () => this.armed.getValue() ? "Listening to all MIDI devices" : "Arm to listen to MIDI device...",
|
48
47
|
some: value => `Listening to ${midiAccess.inputs.get(value)?.name}`
|
49
48
|
}), "MIDI not available");
|
50
49
|
}
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@opendaw/studio-core",
|
3
|
-
"version": "0.0.
|
3
|
+
"version": "0.0.23",
|
4
4
|
"license": "LGPL-3.0-or-later",
|
5
5
|
"publishConfig": {
|
6
6
|
"access": "public"
|
@@ -44,5 +44,5 @@
|
|
44
44
|
"@opendaw/studio-forge-boxes": "^0.0.22",
|
45
45
|
"@opendaw/typescript-config": "^0.0.19"
|
46
46
|
},
|
47
|
-
"gitHead": "
|
47
|
+
"gitHead": "e4e9f38dbeaa68def8657392668989df903006b6"
|
48
48
|
}
|