1
0
mirror of https://github.com/laurent22/joplin.git synced 2024-12-24 10:27:10 +02:00

Desktop: Resolves #9261: Mention in sync wizard that Dropbox and OneDrive are slow on first sync

This commit is contained in:
Laurent Cozic 2023-12-24 11:06:28 +00:00
parent b4928eb7e5
commit cec5f1f3ba

View File

@ -79,7 +79,7 @@ const SyncTargetBox = styled.div<{ faded: boolean }>`
background-color: ${props => props.theme.backgroundColor}; background-color: ${props => props.theme.backgroundColor};
border: 1px solid ${props => props.theme.dividerColor}; border: 1px solid ${props => props.theme.dividerColor};
border-radius: 8px; border-radius: 8px;
padding: 0.8em 2.2em 2em 2.2em; padding: 2em 2.2em 2em 2.2em;
margin-right: 1em; margin-right: 1em;
max-width: 400px; max-width: 400px;
opacity: ${props => props.faded ? 0.5 : 1}; opacity: ${props => props.faded ? 0.5 : 1};
@ -127,6 +127,14 @@ const FormLabel = styled.label`
margin: 1em 0 0.6em 0; margin: 1em 0 0.6em 0;
`; `;
const SlowSyncWarning = styled.div`
margin-top: 1em;
opacity: 0.8;
font-family: ${props => props.theme.fontFamily};
color: ${props => props.theme.color};
font-size: 14px;
`;
const syncTargetNames: string[] = [ const syncTargetNames: string[] = [
'joplinCloud', 'joplinCloud',
'dropbox', 'dropbox',
@ -283,12 +291,18 @@ export default function(props: Props) {
const descriptionComp = <SyncTargetDescription height={height} ref={info.name === 'joplinCloud' ? joplinCloudDescriptionRef : null}>{info.description}</SyncTargetDescription>; const descriptionComp = <SyncTargetDescription height={height} ref={info.name === 'joplinCloud' ? joplinCloudDescriptionRef : null}>{info.description}</SyncTargetDescription>;
const featuresComp = showJoplinCloudForm && info.name === 'joplinCloud' ? null : renderFeatures(info.name); const featuresComp = showJoplinCloudForm && info.name === 'joplinCloud' ? null : renderFeatures(info.name);
const renderSlowSyncWarning = () => {
if (info.name === 'joplinCloud') return null;
return <SlowSyncWarning>{`⚠️ ${_('%s is not optimised for synchronising many small files so your initial synchronisation will be slow.', info.label)}`}</SlowSyncWarning>;
};
return ( return (
<SyncTargetBox id={key} key={key} faded={showJoplinCloudForm && info.name !== 'joplinCloud'}> <SyncTargetBox id={key} key={key} faded={showJoplinCloudForm && info.name !== 'joplinCloud'}>
<SyncTargetTitle>{logo}{info.label}</SyncTargetTitle> <SyncTargetTitle>{logo}{info.label}</SyncTargetTitle>
{descriptionComp} {descriptionComp}
{featuresComp} {featuresComp}
{renderSelectArea(info)} {renderSelectArea(info)}
{renderSlowSyncWarning()}
</SyncTargetBox> </SyncTargetBox>
); );
} }