« get me outta code hell

data: #things/commentary-entry -> #things/content - hsmusic-wiki - HSMusic - static wiki software cataloguing collaborative creation
about summary refs log tree commit diff
path: root/src/data/composite/things/commentary-entry
diff options
context:
space:
mode:
author(quasar) nebula <qznebula@protonmail.com>2025-05-01 12:43:58 -0300
committer(quasar) nebula <qznebula@protonmail.com>2025-05-06 12:29:05 -0300
commitcad44bfd247272ea8c11764d3b65dfd6a1b2b224 (patch)
treec9494dc8febb039951dc70f7ea7837c3839bda3a /src/data/composite/things/commentary-entry
parent4c99ad241cd8d34c0a6a68a4edac15b869ce6ee1 (diff)
data: #things/commentary-entry -> #things/content
Diffstat (limited to 'src/data/composite/things/commentary-entry')
-rw-r--r--src/data/composite/things/commentary-entry/index.js1
-rw-r--r--src/data/composite/things/commentary-entry/withWebArchiveDate.js41
2 files changed, 0 insertions, 42 deletions
diff --git a/src/data/composite/things/commentary-entry/index.js b/src/data/composite/things/commentary-entry/index.js
deleted file mode 100644
index 091bae1a..00000000
--- a/src/data/composite/things/commentary-entry/index.js
+++ /dev/null
@@ -1 +0,0 @@
-export {default as withWebArchiveDate} from './withWebArchiveDate.js';
diff --git a/src/data/composite/things/commentary-entry/withWebArchiveDate.js b/src/data/composite/things/commentary-entry/withWebArchiveDate.js
deleted file mode 100644
index 3aaa4f64..00000000
--- a/src/data/composite/things/commentary-entry/withWebArchiveDate.js
+++ /dev/null
@@ -1,41 +0,0 @@
-import {input, templateCompositeFrom} from '#composite';
-
-import {raiseOutputWithoutDependency} from '#composite/control-flow';
-
-export default templateCompositeFrom({
-  annotation: `withWebArchiveDate`,
-
-  outputs: ['#webArchiveDate'],
-
-  steps: () => [
-    {
-      dependencies: ['annotation'],
-
-      compute: (continuation, {annotation}) =>
-        continuation({
-          ['#dateText']:
-            annotation
-              ?.match(/https?:\/\/web.archive.org\/web\/([0-9]{8,8})[0-9]*\//)
-              ?.[1] ??
-            null,
-        }),
-    },
-
-    raiseOutputWithoutDependency({
-      dependency: '#dateText',
-      output: input.value({['#webArchiveDate']: null}),
-    }),
-
-    {
-      dependencies: ['#dateText'],
-      compute: (continuation, {['#dateText']: dateText}) =>
-        continuation({
-          ['#webArchiveDate']:
-            new Date(
-              dateText.slice(0, 4) + '/' +
-              dateText.slice(4, 6) + '/' +
-              dateText.slice(6, 8)),
-        }),
-    },
-  ],
-});