) {
event.preventDefault();
@@ -133,11 +154,12 @@ export class AtomicRecsResult {
}
private getContentHTML() {
- return Array.from(this.content!.children)
- .map((child) => child.outerHTML)
- .join('');
+ return parentNodeToString(this.content!);
}
+ private getLinkHTML() {
+ return parentNodeToString(this.linkContent);
+ }
private get isCustomRenderFunctionMode() {
return this.renderingFunction !== undefined;
}
@@ -158,6 +180,10 @@ export class AtomicRecsResult {
class="result-root"
ref={(ref) => (this.resultRootRef = ref)}
>
+ (this.linkContainerRef = ref)}
+ >
);
}
@@ -171,6 +197,7 @@ export class AtomicRecsResult {
.join(' ')}`}
innerHTML={this.getContentHTML()}
>
+
);
}
@@ -186,7 +213,8 @@ export class AtomicRecsResult {
if (this.shouldExecuteRenderFunction()) {
const customRenderOutputAsString = this.renderingFunction!(
this.result,
- this.resultRootRef!
+ this.resultRootRef!,
+ this.linkContainerRef!
);
this.resultRootRef!.className += ` ${this.layout
diff --git a/packages/atomic/src/pages/index.html b/packages/atomic/src/pages/index.html
index 5d54fd9a883..41255b0b1ff 100644
--- a/packages/atomic/src/pages/index.html
+++ b/packages/atomic/src/pages/index.html
@@ -230,7 +230,6 @@
-