@k-l-lambda/lilylet 0.1.49 → 0.1.50

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 (71) hide show
  1. package/lib/abc/abc.d.ts +102 -0
  2. package/lib/abc/abc.js +25 -0
  3. package/lib/abc/grammar.jison.js +1203 -0
  4. package/lib/abc/parser.d.ts +3 -0
  5. package/lib/abc/parser.js +6 -0
  6. package/lib/abcDecoder.d.ts +1 -0
  7. package/lib/abcDecoder.js +1 -0
  8. package/lib/grammar.jison.js +1 -1303
  9. package/lib/index.d.ts +1 -8
  10. package/lib/index.js +1 -10
  11. package/lib/lilylet/abcDecoder.d.ts +25 -0
  12. package/lib/lilylet/abcDecoder.js +1007 -0
  13. package/lib/lilylet/grammar.jison.js +1308 -0
  14. package/lib/lilylet/index.d.ts +10 -0
  15. package/lib/lilylet/index.js +10 -0
  16. package/lib/lilylet/lilypondDecoder.d.ts +29 -0
  17. package/lib/lilylet/lilypondDecoder.js +1053 -0
  18. package/lib/lilylet/lilypondEncoder.d.ts +34 -0
  19. package/lib/lilylet/lilypondEncoder.js +759 -0
  20. package/lib/lilylet/meiEncoder.d.ts +8 -0
  21. package/lib/lilylet/meiEncoder.js +1808 -0
  22. package/lib/lilylet/musicXmlDecoder.d.ts +20 -0
  23. package/lib/lilylet/musicXmlDecoder.js +1195 -0
  24. package/lib/lilylet/musicXmlEncoder.d.ts +15 -0
  25. package/lib/lilylet/musicXmlEncoder.js +701 -0
  26. package/lib/lilylet/musicXmlTypes.d.ts +199 -0
  27. package/lib/lilylet/musicXmlTypes.js +7 -0
  28. package/lib/lilylet/musicXmlUtils.d.ts +92 -0
  29. package/lib/lilylet/musicXmlUtils.js +469 -0
  30. package/lib/lilylet/parser.d.ts +3 -0
  31. package/lib/lilylet/parser.js +151 -0
  32. package/lib/lilylet/serializer.d.ts +11 -0
  33. package/lib/lilylet/serializer.js +653 -0
  34. package/lib/lilylet/types.d.ts +245 -0
  35. package/lib/lilylet/types.js +99 -0
  36. package/lib/lilypondDecoder.d.ts +1 -29
  37. package/lib/lilypondDecoder.js +1 -1006
  38. package/lib/lilypondEncoder.d.ts +1 -34
  39. package/lib/lilypondEncoder.js +1 -759
  40. package/lib/meiEncoder.d.ts +1 -8
  41. package/lib/meiEncoder.js +1 -1545
  42. package/lib/musicXmlDecoder.d.ts +1 -20
  43. package/lib/musicXmlDecoder.js +1 -1151
  44. package/lib/musicXmlEncoder.d.ts +1 -15
  45. package/lib/musicXmlEncoder.js +1 -666
  46. package/lib/musicXmlTypes.d.ts +1 -199
  47. package/lib/musicXmlTypes.js +1 -7
  48. package/lib/musicXmlUtils.d.ts +1 -81
  49. package/lib/musicXmlUtils.js +1 -435
  50. package/lib/parser.d.ts +1 -3
  51. package/lib/parser.js +1 -151
  52. package/lib/serializer.d.ts +1 -11
  53. package/lib/serializer.js +1 -650
  54. package/lib/types.d.ts +1 -244
  55. package/lib/types.js +1 -99
  56. package/package.json +2 -1
  57. package/source/abc/abc.jison +692 -0
  58. package/source/abc/abc.ts +176 -0
  59. package/source/abc/grammar.jison.js +1203 -0
  60. package/source/abc/parser.ts +12 -0
  61. package/source/lilylet/abcDecoder.ts +1121 -0
  62. package/source/lilylet/grammar.jison.js +170 -165
  63. package/source/lilylet/index.ts +4 -3
  64. package/source/lilylet/lilylet.jison +2 -0
  65. package/source/lilylet/lilypondDecoder.ts +91 -41
  66. package/source/lilylet/meiEncoder.ts +280 -0
  67. package/source/lilylet/musicXmlDecoder.ts +74 -27
  68. package/source/lilylet/musicXmlEncoder.ts +201 -146
  69. package/source/lilylet/musicXmlUtils.ts +46 -4
  70. package/source/lilylet/serializer.ts +3 -0
  71. package/source/lilylet/types.ts +1 -0
package/lib/index.d.ts CHANGED
@@ -1,8 +1 @@
1
- export * from "./types";
2
- export * from "./parser";
3
- export * from "./serializer";
4
- import * as meiEncoder from "./meiEncoder";
5
- import * as musicXmlDecoder from "./musicXmlDecoder";
6
- import * as lilypondEncoder from "./lilypondEncoder";
7
- import * as musicXmlEncoder from "./musicXmlEncoder";
8
- export { meiEncoder, musicXmlDecoder, lilypondEncoder, musicXmlEncoder, };
1
+ export * from "./lilylet/index.js";
package/lib/index.js CHANGED
@@ -1,10 +1 @@
1
- export * from "./types.js";
2
- export * from "./parser.js";
3
- export * from "./serializer.js";
4
- import * as meiEncoder from "./meiEncoder.js";
5
- import * as musicXmlDecoder from "./musicXmlDecoder.js";
6
- import * as lilypondEncoder from "./lilypondEncoder.js";
7
- import * as musicXmlEncoder from "./musicXmlEncoder.js";
8
- export { meiEncoder, musicXmlDecoder, lilypondEncoder, musicXmlEncoder, };
9
- // Note: lilypondDecoder is optional and requires @k-l-lambda/lotus
10
- // Import it directly from '@k-l-lambda/lilylet/lib/lilypondDecoder.js' if needed
1
+ export * from "./lilylet/index.js";
@@ -0,0 +1,25 @@
1
+ /**
2
+ * ABC Notation Decoder for Lilylet
3
+ *
4
+ * Converts ABC notation files to Lilylet's internal LilyletDoc format.
5
+ */
6
+ import { LilyletDoc } from "./types";
7
+ /**
8
+ * Decode ABC notation string to LilyletDoc.
9
+ * If the ABC contains multiple tunes, only the first is decoded.
10
+ */
11
+ export declare const decode: (abcString: string) => LilyletDoc;
12
+ /**
13
+ * Decode ABC notation string to multiple LilyletDocs (one per tune).
14
+ */
15
+ export declare const decodeAll: (abcString: string) => LilyletDoc[];
16
+ /**
17
+ * Decode an ABC file to LilyletDoc
18
+ */
19
+ export declare const decodeFile: (filePath: string) => Promise<LilyletDoc>;
20
+ declare const _default: {
21
+ decode: (abcString: string) => LilyletDoc;
22
+ decodeAll: (abcString: string) => LilyletDoc[];
23
+ decodeFile: (filePath: string) => Promise<LilyletDoc>;
24
+ };
25
+ export default _default;