musora-content-services 1.0.40 → 1.0.41
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/CHANGELOG.md +2 -0
- package/docs/config.js.html +1 -1
- package/docs/index.html +1 -1
- package/docs/module-Config.html +1 -1
- package/docs/module-Railcontent-Services.html +1 -1
- package/docs/module-Sanity-Services.html +11 -11
- package/docs/railcontent.js.html +1 -1
- package/docs/sanity.js.html +25 -28
- package/package.json +1 -1
- package/src/services/sanity.js +24 -27
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,8 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
|
|
4
4
|
|
|
5
|
+
### [1.0.41](https://github.com/railroadmedia/musora-content-services/compare/v1.0.40...v1.0.41) (2024-08-20)
|
|
6
|
+
|
|
5
7
|
### [1.0.40](https://github.com/railroadmedia/musora-content-services/compare/v1.0.39...v1.0.40) (2024-08-20)
|
|
6
8
|
|
|
7
9
|
### [1.0.39](https://github.com/railroadmedia/musora-content-services/compare/v1.0.37...v1.0.39) (2024-08-20)
|
package/docs/config.js.html
CHANGED
|
@@ -111,7 +111,7 @@ module.exports = {
|
|
|
111
111
|
<br class="clear">
|
|
112
112
|
|
|
113
113
|
<footer>
|
|
114
|
-
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 4.0.3</a> on Tue Aug 20 2024
|
|
114
|
+
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 4.0.3</a> on Tue Aug 20 2024 19:53:05 GMT+0000 (Coordinated Universal Time) using the <a href="https://github.com/clenemt/docdash">docdash</a> theme.
|
|
115
115
|
</footer>
|
|
116
116
|
|
|
117
117
|
<script>prettyPrint();</script>
|
package/docs/index.html
CHANGED
|
@@ -110,7 +110,7 @@ Run the following to execute the tests</p>
|
|
|
110
110
|
<br class="clear">
|
|
111
111
|
|
|
112
112
|
<footer>
|
|
113
|
-
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 4.0.3</a> on Tue Aug 20 2024
|
|
113
|
+
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 4.0.3</a> on Tue Aug 20 2024 19:53:05 GMT+0000 (Coordinated Universal Time) using the <a href="https://github.com/clenemt/docdash">docdash</a> theme.
|
|
114
114
|
</footer>
|
|
115
115
|
|
|
116
116
|
<script>prettyPrint();</script>
|
package/docs/module-Config.html
CHANGED
|
@@ -656,7 +656,7 @@ initializeService({
|
|
|
656
656
|
<br class="clear">
|
|
657
657
|
|
|
658
658
|
<footer>
|
|
659
|
-
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 4.0.3</a> on Tue Aug 20 2024
|
|
659
|
+
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 4.0.3</a> on Tue Aug 20 2024 19:53:05 GMT+0000 (Coordinated Universal Time) using the <a href="https://github.com/clenemt/docdash">docdash</a> theme.
|
|
660
660
|
</footer>
|
|
661
661
|
|
|
662
662
|
<script>prettyPrint();</script>
|
|
@@ -783,7 +783,7 @@
|
|
|
783
783
|
<br class="clear">
|
|
784
784
|
|
|
785
785
|
<footer>
|
|
786
|
-
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 4.0.3</a> on Tue Aug 20 2024
|
|
786
|
+
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 4.0.3</a> on Tue Aug 20 2024 19:53:05 GMT+0000 (Coordinated Universal Time) using the <a href="https://github.com/clenemt/docdash">docdash</a> theme.
|
|
787
787
|
</footer>
|
|
788
788
|
|
|
789
789
|
<script>prettyPrint();</script>
|
|
@@ -1896,7 +1896,7 @@ fetchAllFilterOptions('myBrand', '', 'Rock', 'John Doe', 'song', 'Love')
|
|
|
1896
1896
|
|
|
1897
1897
|
<dt class="tag-source">Source:</dt>
|
|
1898
1898
|
<dd class="tag-source"><ul class="dummy"><li>
|
|
1899
|
-
<a href="sanity.js.html">sanity.js</a>, <a href="sanity.js.html#
|
|
1899
|
+
<a href="sanity.js.html">sanity.js</a>, <a href="sanity.js.html#line647">line 647</a>
|
|
1900
1900
|
</li></ul></dd>
|
|
1901
1901
|
|
|
1902
1902
|
|
|
@@ -2054,7 +2054,7 @@ fetchAllFilterOptions('myBrand', '', 'Rock', 'John Doe', 'song', 'Love')
|
|
|
2054
2054
|
|
|
2055
2055
|
<dt class="tag-source">Source:</dt>
|
|
2056
2056
|
<dd class="tag-source"><ul class="dummy"><li>
|
|
2057
|
-
<a href="sanity.js.html">sanity.js</a>, <a href="sanity.js.html#
|
|
2057
|
+
<a href="sanity.js.html">sanity.js</a>, <a href="sanity.js.html#line819">line 819</a>
|
|
2058
2058
|
</li></ul></dd>
|
|
2059
2059
|
|
|
2060
2060
|
|
|
@@ -2219,7 +2219,7 @@ fetchAllFilterOptions('myBrand', '', 'Rock', 'John Doe', 'song', 'Love')
|
|
|
2219
2219
|
|
|
2220
2220
|
<dt class="tag-source">Source:</dt>
|
|
2221
2221
|
<dd class="tag-source"><ul class="dummy"><li>
|
|
2222
|
-
<a href="sanity.js.html">sanity.js</a>, <a href="sanity.js.html#
|
|
2222
|
+
<a href="sanity.js.html">sanity.js</a>, <a href="sanity.js.html#line725">line 725</a>
|
|
2223
2223
|
</li></ul></dd>
|
|
2224
2224
|
|
|
2225
2225
|
|
|
@@ -2384,7 +2384,7 @@ fetchAllFilterOptions('myBrand', '', 'Rock', 'John Doe', 'song', 'Love')
|
|
|
2384
2384
|
|
|
2385
2385
|
<dt class="tag-source">Source:</dt>
|
|
2386
2386
|
<dd class="tag-source"><ul class="dummy"><li>
|
|
2387
|
-
<a href="sanity.js.html">sanity.js</a>, <a href="sanity.js.html#
|
|
2387
|
+
<a href="sanity.js.html">sanity.js</a>, <a href="sanity.js.html#line689">line 689</a>
|
|
2388
2388
|
</li></ul></dd>
|
|
2389
2389
|
|
|
2390
2390
|
|
|
@@ -2542,7 +2542,7 @@ fetchAllFilterOptions('myBrand', '', 'Rock', 'John Doe', 'song', 'Love')
|
|
|
2542
2542
|
|
|
2543
2543
|
<dt class="tag-source">Source:</dt>
|
|
2544
2544
|
<dd class="tag-source"><ul class="dummy"><li>
|
|
2545
|
-
<a href="sanity.js.html">sanity.js</a>, <a href="sanity.js.html#
|
|
2545
|
+
<a href="sanity.js.html">sanity.js</a>, <a href="sanity.js.html#line668">line 668</a>
|
|
2546
2546
|
</li></ul></dd>
|
|
2547
2547
|
|
|
2548
2548
|
|
|
@@ -2858,7 +2858,7 @@ fetchAllFilterOptions('myBrand', '', 'Rock', 'John Doe', 'song', 'Love')
|
|
|
2858
2858
|
|
|
2859
2859
|
<dt class="tag-source">Source:</dt>
|
|
2860
2860
|
<dd class="tag-source"><ul class="dummy"><li>
|
|
2861
|
-
<a href="sanity.js.html">sanity.js</a>, <a href="sanity.js.html#
|
|
2861
|
+
<a href="sanity.js.html">sanity.js</a>, <a href="sanity.js.html#line699">line 699</a>
|
|
2862
2862
|
</li></ul></dd>
|
|
2863
2863
|
|
|
2864
2864
|
|
|
@@ -3016,7 +3016,7 @@ fetchAllFilterOptions('myBrand', '', 'Rock', 'John Doe', 'song', 'Love')
|
|
|
3016
3016
|
|
|
3017
3017
|
<dt class="tag-source">Source:</dt>
|
|
3018
3018
|
<dd class="tag-source"><ul class="dummy"><li>
|
|
3019
|
-
<a href="sanity.js.html">sanity.js</a>, <a href="sanity.js.html#
|
|
3019
|
+
<a href="sanity.js.html">sanity.js</a>, <a href="sanity.js.html#line779">line 779</a>
|
|
3020
3020
|
</li></ul></dd>
|
|
3021
3021
|
|
|
3022
3022
|
|
|
@@ -3174,7 +3174,7 @@ fetchAllFilterOptions('myBrand', '', 'Rock', 'John Doe', 'song', 'Love')
|
|
|
3174
3174
|
|
|
3175
3175
|
<dt class="tag-source">Source:</dt>
|
|
3176
3176
|
<dd class="tag-source"><ul class="dummy"><li>
|
|
3177
|
-
<a href="sanity.js.html">sanity.js</a>, <a href="sanity.js.html#
|
|
3177
|
+
<a href="sanity.js.html">sanity.js</a>, <a href="sanity.js.html#line805">line 805</a>
|
|
3178
3178
|
</li></ul></dd>
|
|
3179
3179
|
|
|
3180
3180
|
|
|
@@ -3339,7 +3339,7 @@ fetchAllFilterOptions('myBrand', '', 'Rock', 'John Doe', 'song', 'Love')
|
|
|
3339
3339
|
|
|
3340
3340
|
<dt class="tag-source">Source:</dt>
|
|
3341
3341
|
<dd class="tag-source"><ul class="dummy"><li>
|
|
3342
|
-
<a href="sanity.js.html">sanity.js</a>, <a href="sanity.js.html#
|
|
3342
|
+
<a href="sanity.js.html">sanity.js</a>, <a href="sanity.js.html#line758">line 758</a>
|
|
3343
3343
|
</li></ul></dd>
|
|
3344
3344
|
|
|
3345
3345
|
|
|
@@ -3710,7 +3710,7 @@ fetchAllFilterOptions('myBrand', '', 'Rock', 'John Doe', 'song', 'Love')
|
|
|
3710
3710
|
|
|
3711
3711
|
<dt class="tag-source">Source:</dt>
|
|
3712
3712
|
<dd class="tag-source"><ul class="dummy"><li>
|
|
3713
|
-
<a href="sanity.js.html">sanity.js</a>, <a href="sanity.js.html#
|
|
3713
|
+
<a href="sanity.js.html">sanity.js</a>, <a href="sanity.js.html#line860">line 860</a>
|
|
3714
3714
|
</li></ul></dd>
|
|
3715
3715
|
|
|
3716
3716
|
|
|
@@ -4877,7 +4877,7 @@ It also includes completion status and progress percentage for each workout by f
|
|
|
4877
4877
|
<br class="clear">
|
|
4878
4878
|
|
|
4879
4879
|
<footer>
|
|
4880
|
-
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 4.0.3</a> on Tue Aug 20 2024
|
|
4880
|
+
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 4.0.3</a> on Tue Aug 20 2024 19:53:05 GMT+0000 (Coordinated Universal Time) using the <a href="https://github.com/clenemt/docdash">docdash</a> theme.
|
|
4881
4881
|
</footer>
|
|
4882
4882
|
|
|
4883
4883
|
<script>prettyPrint();</script>
|
package/docs/railcontent.js.html
CHANGED
|
@@ -201,7 +201,7 @@ export async function fetchContentInProgress(type="all", brand) {
|
|
|
201
201
|
<br class="clear">
|
|
202
202
|
|
|
203
203
|
<footer>
|
|
204
|
-
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 4.0.3</a> on Tue Aug 20 2024
|
|
204
|
+
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 4.0.3</a> on Tue Aug 20 2024 19:53:05 GMT+0000 (Coordinated Universal Time) using the <a href="https://github.com/clenemt/docdash">docdash</a> theme.
|
|
205
205
|
</footer>
|
|
206
206
|
|
|
207
207
|
<script>prettyPrint();</script>
|
package/docs/sanity.js.html
CHANGED
|
@@ -659,34 +659,31 @@ export async function fetchAllFilterOptions(
|
|
|
659
659
|
contentType,
|
|
660
660
|
term
|
|
661
661
|
) {
|
|
662
|
-
|
|
663
|
-
|
|
664
|
-
|
|
665
|
-
|
|
666
|
-
|
|
667
|
-
|
|
668
|
-
|
|
669
|
-
|
|
670
|
-
|
|
671
|
-
|
|
672
|
-
|
|
673
|
-
|
|
674
|
-
|
|
675
|
-
|
|
676
|
-
|
|
677
|
-
|
|
678
|
-
|
|
679
|
-
|
|
680
|
-
|
|
681
|
-
|
|
682
|
-
|
|
683
|
-
}
|
|
684
|
-
}
|
|
662
|
+
const query = `
|
|
663
|
+
{
|
|
664
|
+
"meta": {
|
|
665
|
+
"totalResults": count(*[_type == '${contentType}' && brand == "${brand}"${style ? ` && '${style}' in genre[]->name` : ''}${artist ? ` && artist->name == '${artist}'` : ''}${filters}
|
|
666
|
+
${term ? ` && (title match "${term}" || album match "${term}" || artist->name match "${term}" || genre[]->name match "${term}")` : ''}]),
|
|
667
|
+
"filterOptions": {
|
|
668
|
+
"difficulty": [
|
|
669
|
+
{"type": "Introductory", "count": count(*[_type == '${contentType}' && brand == '${brand}'${style ? ` && '${style}' in genre[]->name` : ''}${artist ? ` && artist->name == '${artist}'` : ''} && difficulty_string == "Introductory"${filters}])},
|
|
670
|
+
{"type": "Beginner", "count": count(*[_type == '${contentType}' && brand == '${brand}'${style ? ` && '${style}' in genre[]->name` : ''}${artist ? ` && artist->name == '${artist}'` : ''} && difficulty_string == "Beginner"${filters}])},
|
|
671
|
+
{"type": "Intermediate", "count": count(*[_type == '${contentType}' && brand == '${brand}'${style ? ` && '${style}' in genre[]->name` : ''}${artist ? ` && artist->name == '${artist}'` : ''} && difficulty_string == "Intermediate"${filters}])},
|
|
672
|
+
{"type": "Advanced", "count": count(*[_type == '${contentType}' && brand == '${brand}'${style ? ` && '${style}' in genre[]->name` : ''}${artist ? ` && artist->name == '${artist}'` : ''} && difficulty_string == "Advanced"${filters}])},
|
|
673
|
+
{"type": "Expert", "count": count(*[_type == '${contentType}' && brand == '${brand}'${style ? ` && '${style}' in genre[]->name` : ''}${artist ? ` && artist->name == '${artist}'` : ''} && difficulty_string == "Expert"${filters}])}
|
|
674
|
+
][count > 0],
|
|
675
|
+
"instrumentless": [
|
|
676
|
+
{"type": "Full Song Only", "count": count(*[_type == '${contentType}' && brand == '${brand}'${style ? ` && '${style}' in genre[]->name` : ''}${artist ? ` && artist->name == '${artist}'` : ''} && instrumentless == false${filters}])},
|
|
677
|
+
{"type": "Instrument Removed", "count": count(*[_type == '${contentType}' && brand == '${brand}'${style ? ` && '${style}' in genre[]->name` : ''}${artist ? ` && artist->name == '${artist}'` : ''} && instrumentless == true${filters}])}
|
|
678
|
+
][count > 0],
|
|
679
|
+
"genre": *[_type == 'genre' && '${contentType}' in filter_types] {
|
|
680
|
+
"type": name,
|
|
681
|
+
"count": count(*[_type == '${contentType}' && brand == "${brand}"${style ? ` && '${style}' in genre[]->name` : ''}${artist ? ` && artist->name == '${artist}'` : ''} && references(^._id)])
|
|
682
|
+
}[count > 0]
|
|
685
683
|
}
|
|
686
|
-
|
|
687
|
-
|
|
688
|
-
|
|
689
|
-
return fetchSanity(query, false);
|
|
684
|
+
}
|
|
685
|
+
}`;
|
|
686
|
+
return fetchSanity(query, true);
|
|
690
687
|
}
|
|
691
688
|
|
|
692
689
|
/**
|
|
@@ -989,7 +986,7 @@ function checkSanityConfig(config) {
|
|
|
989
986
|
<br class="clear">
|
|
990
987
|
|
|
991
988
|
<footer>
|
|
992
|
-
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 4.0.3</a> on Tue Aug 20 2024
|
|
989
|
+
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 4.0.3</a> on Tue Aug 20 2024 19:53:05 GMT+0000 (Coordinated Universal Time) using the <a href="https://github.com/clenemt/docdash">docdash</a> theme.
|
|
993
990
|
</footer>
|
|
994
991
|
|
|
995
992
|
<script>prettyPrint();</script>
|
package/package.json
CHANGED
package/src/services/sanity.js
CHANGED
|
@@ -612,34 +612,31 @@ export async function fetchAllFilterOptions(
|
|
|
612
612
|
contentType,
|
|
613
613
|
term
|
|
614
614
|
) {
|
|
615
|
-
|
|
616
|
-
|
|
617
|
-
|
|
618
|
-
|
|
619
|
-
|
|
620
|
-
|
|
621
|
-
|
|
622
|
-
|
|
623
|
-
|
|
624
|
-
|
|
625
|
-
|
|
626
|
-
|
|
627
|
-
|
|
628
|
-
|
|
629
|
-
|
|
630
|
-
|
|
631
|
-
|
|
632
|
-
|
|
633
|
-
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
}
|
|
637
|
-
}
|
|
615
|
+
const query = `
|
|
616
|
+
{
|
|
617
|
+
"meta": {
|
|
618
|
+
"totalResults": count(*[_type == '${contentType}' && brand == "${brand}"${style ? ` && '${style}' in genre[]->name` : ''}${artist ? ` && artist->name == '${artist}'` : ''}${filters}
|
|
619
|
+
${term ? ` && (title match "${term}" || album match "${term}" || artist->name match "${term}" || genre[]->name match "${term}")` : ''}]),
|
|
620
|
+
"filterOptions": {
|
|
621
|
+
"difficulty": [
|
|
622
|
+
{"type": "Introductory", "count": count(*[_type == '${contentType}' && brand == '${brand}'${style ? ` && '${style}' in genre[]->name` : ''}${artist ? ` && artist->name == '${artist}'` : ''} && difficulty_string == "Introductory"${filters}])},
|
|
623
|
+
{"type": "Beginner", "count": count(*[_type == '${contentType}' && brand == '${brand}'${style ? ` && '${style}' in genre[]->name` : ''}${artist ? ` && artist->name == '${artist}'` : ''} && difficulty_string == "Beginner"${filters}])},
|
|
624
|
+
{"type": "Intermediate", "count": count(*[_type == '${contentType}' && brand == '${brand}'${style ? ` && '${style}' in genre[]->name` : ''}${artist ? ` && artist->name == '${artist}'` : ''} && difficulty_string == "Intermediate"${filters}])},
|
|
625
|
+
{"type": "Advanced", "count": count(*[_type == '${contentType}' && brand == '${brand}'${style ? ` && '${style}' in genre[]->name` : ''}${artist ? ` && artist->name == '${artist}'` : ''} && difficulty_string == "Advanced"${filters}])},
|
|
626
|
+
{"type": "Expert", "count": count(*[_type == '${contentType}' && brand == '${brand}'${style ? ` && '${style}' in genre[]->name` : ''}${artist ? ` && artist->name == '${artist}'` : ''} && difficulty_string == "Expert"${filters}])}
|
|
627
|
+
][count > 0],
|
|
628
|
+
"instrumentless": [
|
|
629
|
+
{"type": "Full Song Only", "count": count(*[_type == '${contentType}' && brand == '${brand}'${style ? ` && '${style}' in genre[]->name` : ''}${artist ? ` && artist->name == '${artist}'` : ''} && instrumentless == false${filters}])},
|
|
630
|
+
{"type": "Instrument Removed", "count": count(*[_type == '${contentType}' && brand == '${brand}'${style ? ` && '${style}' in genre[]->name` : ''}${artist ? ` && artist->name == '${artist}'` : ''} && instrumentless == true${filters}])}
|
|
631
|
+
][count > 0],
|
|
632
|
+
"genre": *[_type == 'genre' && '${contentType}' in filter_types] {
|
|
633
|
+
"type": name,
|
|
634
|
+
"count": count(*[_type == '${contentType}' && brand == "${brand}"${style ? ` && '${style}' in genre[]->name` : ''}${artist ? ` && artist->name == '${artist}'` : ''} && references(^._id)])
|
|
635
|
+
}[count > 0]
|
|
638
636
|
}
|
|
639
|
-
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
return fetchSanity(query, false);
|
|
637
|
+
}
|
|
638
|
+
}`;
|
|
639
|
+
return fetchSanity(query, true);
|
|
643
640
|
}
|
|
644
641
|
|
|
645
642
|
/**
|