From 54e85616601231d8a551124648be4f56c3ec800b Mon Sep 17 00:00:00 2001 From: "(quasar) nebula" Date: Sat, 19 Oct 2024 22:20:49 -0300 Subject: content: linkFlashAct: use generateUnsafeMunchy --- src/content/dependencies/linkFlashAct.js | 26 +++++++++++++++++--------- 1 file changed, 17 insertions(+), 9 deletions(-) (limited to 'src') diff --git a/src/content/dependencies/linkFlashAct.js b/src/content/dependencies/linkFlashAct.js index fbb819ed..82c23325 100644 --- a/src/content/dependencies/linkFlashAct.js +++ b/src/content/dependencies/linkFlashAct.js @@ -1,14 +1,22 @@ export default { - contentDependencies: ['linkThing'], - extraDependencies: ['html'], + contentDependencies: ['generateUnsafeMunchy', 'linkThing'], - relations: (relation, flashAct) => - ({link: relation('linkThing', 'localized.flashActGallery', flashAct)}), + relations: (relation, flashAct) => ({ + unsafeMunchy: + relation('generateUnsafeMunchy'), - data: (flashAct) => - ({name: flashAct.name}), + link: + relation('linkThing', 'localized.flashActGallery', flashAct), + }), - generate: (data, relations, {html}) => - relations.link - .slot('content', new html.Tag(null, null, data.name)), + data: (flashAct) => ({ + name: flashAct.name, + }), + + generate: (data, relations) => + relations.link.slots({ + content: + relations.unsafeMunchy + .slot('contentSource', data.name), + }), }; -- cgit 1.3.0-6-gf8a5