@medyll/idae-cadenzia 0.81.1 → 0.83.0
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/.prettierignore +4 -4
- package/.prettierrc +15 -15
- package/CHANGELOG.md +24 -0
- package/README.md +38 -38
- package/eslint.config.js +33 -33
- package/package.json +1 -1
- package/scripts/package-pre.js +3 -3
- package/src/app.d.ts +13 -13
- package/src/app.html +12 -12
- package/src/demo.spec.ts +7 -7
- package/src/lib/components/App.svelte +46 -46
- package/src/lib/components/CadencePanel.svelte +24 -24
- package/src/lib/components/ChordTable.svelte +252 -252
- package/src/lib/components/ChordVisualization.svelte +82 -82
- package/src/lib/constants/constants.ts +49 -49
- package/src/lib/functions/functions.svelte.ts +139 -139
- package/src/lib/functions/rules.ts +118 -118
- package/src/lib/index.ts +1 -1
- package/src/lib/types/types.ts +31 -31
- package/src/routes/+page.svelte +7 -7
- package/svelte.config.js +18 -18
- package/tsconfig.json +19 -19
- package/vite.config.ts +10 -10
package/src/lib/types/types.ts
CHANGED
|
@@ -1,31 +1,31 @@
|
|
|
1
|
-
export type Chord = {
|
|
2
|
-
root: string;
|
|
3
|
-
quality: string;
|
|
4
|
-
augDim?: string;
|
|
5
|
-
sus?: string;
|
|
6
|
-
sept?: string;
|
|
7
|
-
modifier?: string;
|
|
8
|
-
duration: string;
|
|
9
|
-
};
|
|
10
|
-
|
|
11
|
-
export type TimeSignature = {
|
|
12
|
-
numerator: number;
|
|
13
|
-
denominator: number;
|
|
14
|
-
};
|
|
15
|
-
|
|
16
|
-
export type ChordEntry = {
|
|
17
|
-
chord: Chord;
|
|
18
|
-
timeSignature?: { numerator: number; denominator: number };
|
|
19
|
-
armor: string;
|
|
20
|
-
mode?: string;
|
|
21
|
-
measureInfo: {
|
|
22
|
-
start: number;
|
|
23
|
-
end: number;
|
|
24
|
-
beatStart: number;
|
|
25
|
-
};
|
|
26
|
-
};
|
|
27
|
-
|
|
28
|
-
export type Cadence = {
|
|
29
|
-
name: string;
|
|
30
|
-
chords: string[];
|
|
31
|
-
};
|
|
1
|
+
export type Chord = {
|
|
2
|
+
root: string;
|
|
3
|
+
quality: string;
|
|
4
|
+
augDim?: string;
|
|
5
|
+
sus?: string;
|
|
6
|
+
sept?: string;
|
|
7
|
+
modifier?: string;
|
|
8
|
+
duration: string;
|
|
9
|
+
};
|
|
10
|
+
|
|
11
|
+
export type TimeSignature = {
|
|
12
|
+
numerator: number;
|
|
13
|
+
denominator: number;
|
|
14
|
+
};
|
|
15
|
+
|
|
16
|
+
export type ChordEntry = {
|
|
17
|
+
chord: Chord;
|
|
18
|
+
timeSignature?: { numerator: number; denominator: number };
|
|
19
|
+
armor: string;
|
|
20
|
+
mode?: string;
|
|
21
|
+
measureInfo: {
|
|
22
|
+
start: number;
|
|
23
|
+
end: number;
|
|
24
|
+
beatStart: number;
|
|
25
|
+
};
|
|
26
|
+
};
|
|
27
|
+
|
|
28
|
+
export type Cadence = {
|
|
29
|
+
name: string;
|
|
30
|
+
chords: string[];
|
|
31
|
+
};
|
package/src/routes/+page.svelte
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
<script lang="ts">
|
|
2
|
-
import App from "../lib/components/App.svelte";
|
|
3
|
-
|
|
4
|
-
</script>
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
<App />
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import App from "../lib/components/App.svelte";
|
|
3
|
+
|
|
4
|
+
</script>
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
<App />
|
package/svelte.config.js
CHANGED
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
import adapter from '@sveltejs/adapter-auto';
|
|
2
|
-
import { vitePreprocess } from '@sveltejs/vite-plugin-svelte';
|
|
3
|
-
|
|
4
|
-
/** @type {import('@sveltejs/kit').Config} */
|
|
5
|
-
const config = {
|
|
6
|
-
// Consult https://svelte.dev/docs/kit/integrations
|
|
7
|
-
// for more information about preprocessors
|
|
8
|
-
preprocess: vitePreprocess(),
|
|
9
|
-
|
|
10
|
-
kit: {
|
|
11
|
-
// adapter-auto only supports some environments, see https://svelte.dev/docs/kit/adapter-auto for a list.
|
|
12
|
-
// If your environment is not supported, or you settled on a specific environment, switch out the adapter.
|
|
13
|
-
// See https://svelte.dev/docs/kit/adapters for more information about adapters.
|
|
14
|
-
adapter: adapter()
|
|
15
|
-
}
|
|
16
|
-
};
|
|
17
|
-
|
|
18
|
-
export default config;
|
|
1
|
+
import adapter from '@sveltejs/adapter-auto';
|
|
2
|
+
import { vitePreprocess } from '@sveltejs/vite-plugin-svelte';
|
|
3
|
+
|
|
4
|
+
/** @type {import('@sveltejs/kit').Config} */
|
|
5
|
+
const config = {
|
|
6
|
+
// Consult https://svelte.dev/docs/kit/integrations
|
|
7
|
+
// for more information about preprocessors
|
|
8
|
+
preprocess: vitePreprocess(),
|
|
9
|
+
|
|
10
|
+
kit: {
|
|
11
|
+
// adapter-auto only supports some environments, see https://svelte.dev/docs/kit/adapter-auto for a list.
|
|
12
|
+
// If your environment is not supported, or you settled on a specific environment, switch out the adapter.
|
|
13
|
+
// See https://svelte.dev/docs/kit/adapters for more information about adapters.
|
|
14
|
+
adapter: adapter()
|
|
15
|
+
}
|
|
16
|
+
};
|
|
17
|
+
|
|
18
|
+
export default config;
|
package/tsconfig.json
CHANGED
|
@@ -1,19 +1,19 @@
|
|
|
1
|
-
{
|
|
2
|
-
"extends": "./.svelte-kit/tsconfig.json",
|
|
3
|
-
"compilerOptions": {
|
|
4
|
-
"allowJs": true,
|
|
5
|
-
"checkJs": true,
|
|
6
|
-
"esModuleInterop": true,
|
|
7
|
-
"forceConsistentCasingInFileNames": true,
|
|
8
|
-
"resolveJsonModule": true,
|
|
9
|
-
"skipLibCheck": true,
|
|
10
|
-
"sourceMap": true,
|
|
11
|
-
"strict": true,
|
|
12
|
-
"moduleResolution": "bundler"
|
|
13
|
-
}
|
|
14
|
-
// Path aliases are handled by https://svelte.dev/docs/kit/configuration#alias
|
|
15
|
-
// except $lib which is handled by https://svelte.dev/docs/kit/configuration#files
|
|
16
|
-
//
|
|
17
|
-
// If you want to overwrite includes/excludes, make sure to copy over the relevant includes/excludes
|
|
18
|
-
// from the referenced tsconfig.json - TypeScript does not merge them in
|
|
19
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"extends": "./.svelte-kit/tsconfig.json",
|
|
3
|
+
"compilerOptions": {
|
|
4
|
+
"allowJs": true,
|
|
5
|
+
"checkJs": true,
|
|
6
|
+
"esModuleInterop": true,
|
|
7
|
+
"forceConsistentCasingInFileNames": true,
|
|
8
|
+
"resolveJsonModule": true,
|
|
9
|
+
"skipLibCheck": true,
|
|
10
|
+
"sourceMap": true,
|
|
11
|
+
"strict": true,
|
|
12
|
+
"moduleResolution": "bundler"
|
|
13
|
+
}
|
|
14
|
+
// Path aliases are handled by https://svelte.dev/docs/kit/configuration#alias
|
|
15
|
+
// except $lib which is handled by https://svelte.dev/docs/kit/configuration#files
|
|
16
|
+
//
|
|
17
|
+
// If you want to overwrite includes/excludes, make sure to copy over the relevant includes/excludes
|
|
18
|
+
// from the referenced tsconfig.json - TypeScript does not merge them in
|
|
19
|
+
}
|
package/vite.config.ts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { defineConfig } from 'vitest/config';
|
|
2
|
-
import { sveltekit } from '@sveltejs/kit/vite';
|
|
3
|
-
|
|
4
|
-
export default defineConfig({
|
|
5
|
-
plugins: [sveltekit()],
|
|
6
|
-
|
|
7
|
-
test: {
|
|
8
|
-
include: ['src/**/*.{test,spec}.{js,ts}']
|
|
9
|
-
}
|
|
10
|
-
});
|
|
1
|
+
import { defineConfig } from 'vitest/config';
|
|
2
|
+
import { sveltekit } from '@sveltejs/kit/vite';
|
|
3
|
+
|
|
4
|
+
export default defineConfig({
|
|
5
|
+
plugins: [sveltekit()],
|
|
6
|
+
|
|
7
|
+
test: {
|
|
8
|
+
include: ['src/**/*.{test,spec}.{js,ts}']
|
|
9
|
+
}
|
|
10
|
+
});
|