« get me outta code hell

hsmusic-wiki - HSMusic - static wiki software cataloguing collaborative creation
about summary refs log tree commit diff
path: root/src/content
diff options
context:
space:
mode:
Diffstat (limited to 'src/content')
-rw-r--r--src/content/dependencies/generateAlbumInfoPage.js5
-rw-r--r--src/content/dependencies/generateArtistGroupContributionsInfo.js7
-rw-r--r--src/content/dependencies/generateTrackInfoPage.js10
-rw-r--r--src/content/dependencies/index.js10
-rw-r--r--src/content/dependencies/listAlbumsByDuration.js8
-rw-r--r--src/content/dependencies/listAlbumsByTracks.js7
-rw-r--r--src/content/dependencies/listArtistsByCommentaryEntries.js6
-rw-r--r--src/content/dependencies/listArtistsByContributions.js7
-rw-r--r--src/content/dependencies/listArtistsByDuration.js8
-rw-r--r--src/content/dependencies/listArtistsByName.js6
-rw-r--r--src/content/dependencies/listGroupsByAlbums.js6
-rw-r--r--src/content/dependencies/listGroupsByDuration.js8
-rw-r--r--src/content/dependencies/listGroupsByLatestAlbum.js8
-rw-r--r--src/content/dependencies/listGroupsByTracks.js7
-rw-r--r--src/content/dependencies/listTagsByUses.js7
-rw-r--r--src/content/dependencies/listTracksByDate.js6
-rw-r--r--src/content/dependencies/listTracksByDurationInAlbum.js8
-rw-r--r--src/content/dependencies/listTracksByTimesReferenced.js7
-rw-r--r--src/content/dependencies/transformContent.js6
-rw-r--r--src/content/util/groupTracksByGroup.js2
20 files changed, 30 insertions, 109 deletions
diff --git a/src/content/dependencies/generateAlbumInfoPage.js b/src/content/dependencies/generateAlbumInfoPage.js
index 992f817..ce17ab2 100644
--- a/src/content/dependencies/generateAlbumInfoPage.js
+++ b/src/content/dependencies/generateAlbumInfoPage.js
@@ -1,6 +1,7 @@
-import getChronologyRelations from '../util/getChronologyRelations.js';
-import {sortAlbumsTracksChronologically} from '#wiki-data';
 import {empty} from '#sugar';
+import {sortAlbumsTracksChronologically} from '#wiki-data';
+
+import getChronologyRelations from '../util/getChronologyRelations.js';
 
 export default {
   contentDependencies: [
diff --git a/src/content/dependencies/generateArtistGroupContributionsInfo.js b/src/content/dependencies/generateArtistGroupContributionsInfo.js
index bc3992e..1aa5dce 100644
--- a/src/content/dependencies/generateArtistGroupContributionsInfo.js
+++ b/src/content/dependencies/generateArtistGroupContributionsInfo.js
@@ -1,9 +1,4 @@
-import {
-  empty,
-  filterProperties,
-  stitchArrays,
-  unique,
-} from '#sugar';
+import {empty, filterProperties, stitchArrays, unique} from '#sugar';
 
 export default {
   contentDependencies: ['linkGroup'],
diff --git a/src/content/dependencies/generateTrackInfoPage.js b/src/content/dependencies/generateTrackInfoPage.js
index 70106e3..334c542 100644
--- a/src/content/dependencies/generateTrackInfoPage.js
+++ b/src/content/dependencies/generateTrackInfoPage.js
@@ -1,11 +1,7 @@
-import getChronologyRelations from '../util/getChronologyRelations.js';
-
-import {
-  sortAlbumsTracksChronologically,
-  sortFlashesChronologically,
-} from '#wiki-data';
-
 import {empty} from '#sugar';
+import {sortAlbumsTracksChronologically, sortFlashesChronologically} from '#wiki-data';
+
+import getChronologyRelations from '../util/getChronologyRelations.js';
 
 export default {
   contentDependencies: [
diff --git a/src/content/dependencies/index.js b/src/content/dependencies/index.js
index 6040829..3bc3484 100644
--- a/src/content/dependencies/index.js
+++ b/src/content/dependencies/index.js
@@ -1,13 +1,13 @@
-import chokidar from 'chokidar';
-import {ESLint} from 'eslint';
-
 import EventEmitter from 'node:events';
 import {readdir} from 'node:fs/promises';
 import * as path from 'node:path';
 import {fileURLToPath} from 'node:url';
 
-import contentFunction, {ContentFunctionSpecError} from '../../content-function.js';
-import {color, logWarn} from '../../util/cli.js';
+import chokidar from 'chokidar';
+import {ESLint} from 'eslint';
+
+import {color, logWarn} from '#cli';
+import contentFunction, {ContentFunctionSpecError} from '#content-function';
 import {annotateFunction} from '#sugar';
 
 function cachebust(filePath) {
diff --git a/src/content/dependencies/listAlbumsByDuration.js b/src/content/dependencies/listAlbumsByDuration.js
index 73e7814..1f95f5e 100644
--- a/src/content/dependencies/listAlbumsByDuration.js
+++ b/src/content/dependencies/listAlbumsByDuration.js
@@ -1,11 +1,5 @@
 import {stitchArrays} from '#sugar';
-
-import {
-  filterByCount,
-  getTotalDuration,
-  sortAlphabetically,
-  sortByCount,
-} from '#wiki-data';
+import {filterByCount, getTotalDuration, sortAlphabetically, sortByCount} from '#wiki-data';
 
 export default {
   contentDependencies: ['generateListingPage', 'linkAlbum'],
diff --git a/src/content/dependencies/listAlbumsByTracks.js b/src/content/dependencies/listAlbumsByTracks.js
index 1b925d2..abf3c3f 100644
--- a/src/content/dependencies/listAlbumsByTracks.js
+++ b/src/content/dependencies/listAlbumsByTracks.js
@@ -1,10 +1,5 @@
 import {stitchArrays} from '#sugar';
-
-import {
-  filterByCount,
-  sortAlphabetically,
-  sortByCount,
-} from '#wiki-data';
+import {filterByCount, sortAlphabetically, sortByCount} from '#wiki-data';
 
 export default {
   contentDependencies: ['generateListingPage', 'linkAlbum'],
diff --git a/src/content/dependencies/listArtistsByCommentaryEntries.js b/src/content/dependencies/listArtistsByCommentaryEntries.js
index a041e0b..4db9885 100644
--- a/src/content/dependencies/listArtistsByCommentaryEntries.js
+++ b/src/content/dependencies/listArtistsByCommentaryEntries.js
@@ -1,9 +1,5 @@
 import {stitchArrays} from '#sugar';
-import {
-  filterByCount,
-  sortAlphabetically,
-  sortByCount,
-} from '#wiki-data';
+import {filterByCount, sortAlphabetically, sortByCount} from '#wiki-data';
 
 export default {
   contentDependencies: ['generateListingPage', 'linkArtist'],
diff --git a/src/content/dependencies/listArtistsByContributions.js b/src/content/dependencies/listArtistsByContributions.js
index ee876d5..86c8cfa 100644
--- a/src/content/dependencies/listArtistsByContributions.js
+++ b/src/content/dependencies/listArtistsByContributions.js
@@ -1,10 +1,5 @@
 import {stitchArrays, unique} from '#sugar';
-
-import {
-  filterByCount,
-  sortAlphabetically,
-  sortByCount,
-} from '#wiki-data';
+import {filterByCount, sortAlphabetically, sortByCount} from '#wiki-data';
 
 export default {
   contentDependencies: ['generateListingPage', 'linkArtist'],
diff --git a/src/content/dependencies/listArtistsByDuration.js b/src/content/dependencies/listArtistsByDuration.js
index 5aeb841..d6a1897 100644
--- a/src/content/dependencies/listArtistsByDuration.js
+++ b/src/content/dependencies/listArtistsByDuration.js
@@ -1,11 +1,5 @@
 import {stitchArrays} from '#sugar';
-
-import {
-  filterByCount,
-  getTotalDuration,
-  sortAlphabetically,
-  sortByCount,
-} from '#wiki-data';
+import {filterByCount, getTotalDuration, sortAlphabetically, sortByCount} from '#wiki-data';
 
 export default {
   contentDependencies: ['generateListingPage', 'linkArtist'],
diff --git a/src/content/dependencies/listArtistsByName.js b/src/content/dependencies/listArtistsByName.js
index 2c85bb4..6c0ad83 100644
--- a/src/content/dependencies/listArtistsByName.js
+++ b/src/content/dependencies/listArtistsByName.js
@@ -1,9 +1,5 @@
 import {stitchArrays} from '#sugar';
-
-import {
-  getArtistNumContributions,
-  sortAlphabetically,
-} from '#wiki-data';
+import {getArtistNumContributions, sortAlphabetically} from '#wiki-data';
 
 export default {
   contentDependencies: ['generateListingPage', 'linkArtist'],
diff --git a/src/content/dependencies/listGroupsByAlbums.js b/src/content/dependencies/listGroupsByAlbums.js
index 83fe5ce..063b826 100644
--- a/src/content/dependencies/listGroupsByAlbums.js
+++ b/src/content/dependencies/listGroupsByAlbums.js
@@ -1,9 +1,5 @@
 import {stitchArrays} from '#sugar';
-import {
-  filterByCount,
-  sortAlphabetically,
-  sortByCount,
-} from '#wiki-data';
+import {filterByCount, sortAlphabetically, sortByCount} from '#wiki-data';
 
 export default {
   contentDependencies: ['generateListingPage', 'linkGroup'],
diff --git a/src/content/dependencies/listGroupsByDuration.js b/src/content/dependencies/listGroupsByDuration.js
index dce4846..e2a023e 100644
--- a/src/content/dependencies/listGroupsByDuration.js
+++ b/src/content/dependencies/listGroupsByDuration.js
@@ -1,11 +1,5 @@
 import {stitchArrays} from '#sugar';
-
-import {
-  filterByCount,
-  getTotalDuration,
-  sortAlphabetically,
-  sortByCount,
-} from '#wiki-data';
+import {filterByCount, getTotalDuration, sortAlphabetically, sortByCount} from '#wiki-data';
 
 export default {
   contentDependencies: ['generateListingPage', 'linkGroup'],
diff --git a/src/content/dependencies/listGroupsByLatestAlbum.js b/src/content/dependencies/listGroupsByLatestAlbum.js
index 84012cf..fa22366 100644
--- a/src/content/dependencies/listGroupsByLatestAlbum.js
+++ b/src/content/dependencies/listGroupsByLatestAlbum.js
@@ -1,11 +1,5 @@
 import {stitchArrays} from '#sugar';
-
-import {
-  compareDates,
-  filterMultipleArrays,
-  sortChronologically,
-  sortMultipleArrays,
-} from '#wiki-data';
+import {compareDates, filterMultipleArrays, sortChronologically, sortMultipleArrays} from '#wiki-data';
 
 export default {
   contentDependencies: [
diff --git a/src/content/dependencies/listGroupsByTracks.js b/src/content/dependencies/listGroupsByTracks.js
index e105b99..b3c55ca 100644
--- a/src/content/dependencies/listGroupsByTracks.js
+++ b/src/content/dependencies/listGroupsByTracks.js
@@ -1,10 +1,5 @@
 import {accumulateSum, stitchArrays} from '#sugar';
-
-import {
-  filterByCount,
-  sortAlphabetically,
-  sortByCount,
-} from '#wiki-data';
+import {filterByCount, sortAlphabetically, sortByCount} from '#wiki-data';
 
 export default {
   contentDependencies: ['generateListingPage', 'linkGroup'],
diff --git a/src/content/dependencies/listTagsByUses.js b/src/content/dependencies/listTagsByUses.js
index dae3404..98a50b8 100644
--- a/src/content/dependencies/listTagsByUses.js
+++ b/src/content/dependencies/listTagsByUses.js
@@ -1,10 +1,5 @@
 import {stitchArrays} from '#sugar';
-
-import {
-  filterByCount,
-  sortAlphabetically,
-  sortByCount,
-} from '#wiki-data';
+import {filterByCount, sortAlphabetically, sortByCount} from '#wiki-data';
 
 export default {
   contentDependencies: ['generateListingPage', 'linkArtTag'],
diff --git a/src/content/dependencies/listTracksByDate.js b/src/content/dependencies/listTracksByDate.js
index 9464682..d6546e6 100644
--- a/src/content/dependencies/listTracksByDate.js
+++ b/src/content/dependencies/listTracksByDate.js
@@ -1,9 +1,5 @@
 import {stitchArrays} from '#sugar';
-
-import {
-  chunkByProperties,
-  sortAlbumsTracksChronologically,
-} from '#wiki-data';
+import {chunkByProperties, sortAlbumsTracksChronologically} from '#wiki-data';
 
 export default {
   contentDependencies: ['generateListingPage', 'linkAlbum', 'linkTrack'],
diff --git a/src/content/dependencies/listTracksByDurationInAlbum.js b/src/content/dependencies/listTracksByDurationInAlbum.js
index db30ed0..4e83e92 100644
--- a/src/content/dependencies/listTracksByDurationInAlbum.js
+++ b/src/content/dependencies/listTracksByDurationInAlbum.js
@@ -1,11 +1,5 @@
 import {stitchArrays} from '#sugar';
-
-import {
-  filterByCount,
-  filterMultipleArrays,
-  sortByCount,
-  sortChronologically,
-} from '#wiki-data';
+import {filterByCount, filterMultipleArrays, sortByCount, sortChronologically} from '#wiki-data';
 
 export default {
   contentDependencies: ['generateListingPage', 'linkAlbum', 'linkTrack'],
diff --git a/src/content/dependencies/listTracksByTimesReferenced.js b/src/content/dependencies/listTracksByTimesReferenced.js
index 3cb5a35..15a3461 100644
--- a/src/content/dependencies/listTracksByTimesReferenced.js
+++ b/src/content/dependencies/listTracksByTimesReferenced.js
@@ -1,10 +1,5 @@
 import {stitchArrays} from '#sugar';
-
-import {
-  filterByCount,
-  sortAlbumsTracksChronologically,
-  sortByCount,
-} from '#wiki-data';
+import {filterByCount, sortAlbumsTracksChronologically, sortByCount} from '#wiki-data';
 
 export default {
   contentDependencies: ['generateListingPage', 'linkTrack'],
diff --git a/src/content/dependencies/transformContent.js b/src/content/dependencies/transformContent.js
index 3d93284..9a5ac45 100644
--- a/src/content/dependencies/transformContent.js
+++ b/src/content/dependencies/transformContent.js
@@ -1,7 +1,7 @@
-import {marked} from 'marked';
+import {bindFind} from '#find';
+import {parseInput} from '#replacer';
 
-import {bindFind} from '../../util/find.js';
-import {parseInput} from '../../util/replacer.js';
+import {marked} from 'marked';
 
 export const replacerSpec = {
   album: {
diff --git a/src/content/util/groupTracksByGroup.js b/src/content/util/groupTracksByGroup.js
index 559967b..4e18900 100644
--- a/src/content/util/groupTracksByGroup.js
+++ b/src/content/util/groupTracksByGroup.js
@@ -1,4 +1,4 @@
-import {empty} from '../../util/sugar.js';
+import {empty} from '#sugar';
 
 export default function groupTracksByGroup(tracks, groups) {
   const lists = new Map(groups.map(group => [group, []]));