0
Fork 0
mirror of https://github.com/logto-io/logto.git synced 2025-01-20 21:32:31 -05:00

chore: remove dirty code (#3398)

This commit is contained in:
Darcy Ye 2023-03-14 20:01:06 +08:00 committed by GitHub
parent b58765c79c
commit f31887344e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -30,7 +30,6 @@ const SignInExperiencePreview = ({ platform, mode, language = 'en', signInExperi
const { customPhrases } = useUiLanguages();
const { userEndpoint } = useContext(AppEndpointsContext);
const previewRef = useRef<HTMLIFrameElement>(null);
const customCssRef = useRef(document.createElement('style'));
const { data: allConnectors } = useSWR<ConnectorResponse[], RequestError>('api/connectors');
const configForUiPage = useMemo(() => {
@ -82,8 +81,6 @@ const SignInExperiencePreview = ({ platform, mode, language = 'en', signInExperi
useEffect(() => {
postPreviewMessage();
document.head.append(customCssRef.current);
const iframe = previewRef.current;
iframe?.addEventListener('load', postPreviewMessage);