diff --git a/README.md b/README.md index 7bbba954..36c19564 100644 --- a/README.md +++ b/README.md @@ -185,7 +185,7 @@ This banner can be used to notify users of privacy policy changes. This banner d This banner can be used to notify users of privacy policy changes. It does not collect consent preferences, however, it will save a consent timestamp for whenever the user acknowledges the policy change, and closes the modal. This banner is similar to `PrivacyPolicyNotice`, however instead of using a button to close the modal - an X icon is used in the top right-hand corner of the modal. -![ViewState = PrivacyPolicyNoticeWithCloseButton](FIXME) +![ViewState = PrivacyPolicyNoticeWithCloseButton](https://github.com/transcend-io/consent-manager-ui/assets/10264973/54010d7f-905a-4014-8268-5915590b177b) #### Button Mapping diff --git a/src/components/CloseButton.tsx b/src/components/CloseButton.tsx index e9f9565e..184486d8 100644 --- a/src/components/CloseButton.tsx +++ b/src/components/CloseButton.tsx @@ -1,6 +1,6 @@ import { h, JSX } from 'preact'; import { useIntl } from 'react-intl'; -import { messages } from 'src/messages'; +import { messages } from '../messages'; /** * Close button, useful for closing modal diff --git a/src/playground/airgapStub.ts b/src/playground/airgapStub.ts index d87d1021..ac0c547d 100644 --- a/src/playground/airgapStub.ts +++ b/src/playground/airgapStub.ts @@ -16,12 +16,24 @@ const getPurposeTypes: AirgapAPI['getPurposeTypes'] = () => { return JSON.parse(purposeTypes ?? {}); }; +const AIRGAP_STATUS = { + protection: false, + csp: false, + monitoring: false, + telemetry: false, +}; + export const airgapStub: AirgapAPI = { // eslint-disable-next-line @typescript-eslint/ban-ts-comment // @ts-ignore ready: (callback) => callback(airgapStub), /** Queue of callbacks to dispatch once airgap is ready */ readyQueue: [], + toggle: () => { + AIRGAP_STATUS.protection = !AIRGAP_STATUS.protection; + return true; + }, + status: AIRGAP_STATUS, /** Enqueue cross-domain data sync across all airgap bundle domains */ sync: () => Promise.resolve(), /** Resolve airgap request overrides for a URL */