From 76e508ffe3818a78fb941ecde05fe9c269e8bc22 Mon Sep 17 00:00:00 2001 From: "(quasar) nebula" Date: Wed, 19 Feb 2025 16:24:14 -0400 Subject: data: isOriginalRelease -> isMainRelease, etc Also isRerelease -> isSecondaryRelease Im sure this is completely bug free and will not involve squashing one million additional commits --- .../inheritContributionListFromMainRelease.js | 44 ++++++++++++++++++++++ 1 file changed, 44 insertions(+) create mode 100644 src/data/composite/things/track/inheritContributionListFromMainRelease.js (limited to 'src/data/composite/things/track/inheritContributionListFromMainRelease.js') diff --git a/src/data/composite/things/track/inheritContributionListFromMainRelease.js b/src/data/composite/things/track/inheritContributionListFromMainRelease.js new file mode 100644 index 00000000..89252feb --- /dev/null +++ b/src/data/composite/things/track/inheritContributionListFromMainRelease.js @@ -0,0 +1,44 @@ +// Like inheritFromMainRelease, but tuned for contributions. +// Recontextualizes contributions for this track. + +import {input, templateCompositeFrom} from '#composite'; + +import {exposeDependency, raiseOutputWithoutDependency} + from '#composite/control-flow'; +import {withRecontextualizedContributionList, withRedatedContributionList} + from '#composite/wiki-data'; + +import withDate from './withDate.js'; +import withPropertyFromMainRelease + from './withPropertyFromMainRelease.js'; + +export default templateCompositeFrom({ + annotation: `inheritContributionListFromMainRelease`, + + steps: () => [ + withPropertyFromMainRelease({ + property: input.thisProperty(), + notFoundValue: input.value([]), + }), + + raiseOutputWithoutDependency({ + dependency: '#isSecondaryRelease', + mode: input.value('falsy'), + }), + + withRecontextualizedContributionList({ + list: '#mainReleaseValue', + }), + + withDate(), + + withRedatedContributionList({ + list: '#mainReleaseValue', + date: '#date', + }), + + exposeDependency({ + dependency: '#mainReleaseValue', + }), + ], +}); -- cgit 1.3.0-6-gf8a5