From 4fc425b286efba913adc2da1c22f7ed1cb25587f Mon Sep 17 00:00:00 2001 From: SleeplessOne1917 <28871516+SleeplessOne1917@users.noreply.github.com> Date: Sat, 13 Apr 2024 20:59:02 -0400 Subject: [PATCH] Make modal use markdown --- .../components/common/adult-consent-modal.tsx | 18 ++++++++++++++---- src/shared/components/home/site-form.tsx | 1 + 2 files changed, 15 insertions(+), 4 deletions(-) diff --git a/src/shared/components/common/adult-consent-modal.tsx b/src/shared/components/common/adult-consent-modal.tsx index e9d8f1ac..4519b502 100644 --- a/src/shared/components/common/adult-consent-modal.tsx +++ b/src/shared/components/common/adult-consent-modal.tsx @@ -3,6 +3,7 @@ import { modalMixin } from "../mixins/modal-mixin"; import { adultConsentLocalStorageKey } from "../../config"; import { setIsoData } from "@utils/app"; import { IsoDataOptionalSite } from "../../interfaces"; +import { mdToHtml } from "../../markdown"; interface AdultConsentModalProps { contentWarning: string; @@ -29,11 +30,20 @@ class AdultConsentModalInner extends Component { data-bs-backdrop="static" ref={this.modalDivRef} > -
+
-
- {contentWarning} -
+
+

Content Warning

+
+
+ this.forceUpdate(), + )} + />