RemoteContent: fix store access

This commit is contained in:
Liam Fitzgerald 2021-03-10 15:56:22 +10:00
parent 77857a487e
commit ca682f7bcf
No known key found for this signature in database
GPG Key ID: D390E12C61D1CFFB

View File

@ -2,10 +2,11 @@ import React, { Component, Fragment } from 'react';
import { BaseAnchor, BaseImage, Box, Button, Text } from '@tlon/indigo-react';
import { hasProvider } from 'oembed-parser';
import EmbedContainer from 'react-oembed-container';
import { withSettingsState } from '~/logic/state/settings';
import useSettingsState from '~/logic/state/settings';
import { RemoteContentPolicy } from '~/types/local-update';
import { VirtualContextProps, withVirtual } from "~/logic/lib/virtualContext";
import { IS_IOS } from '~/logic/lib/platform';
import withState from '~/logic/lib/withState';
type RemoteContentProps = VirtualContextProps & {
url: string;
@ -268,4 +269,4 @@ return;
}
}
export default withSettingsState(withVirtual(RemoteContent), ['remoteContentPolicy']);
export default withState(withVirtual(RemoteContent), [[useSettingsState, ['remoteContentPolicy']]]);