Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 12 additions & 3 deletions src/renderer/components/modals/ManagedActivateModal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,10 @@ type Failed = Extract<ActivateState, { s: 'no-configuration' | 'unreachable' | '
const STILL_CHECKING_MS = 3000
const PREPARING_MS = 10_000

// The policy section that says what an organization learns from a computer it manages.
const PRIVACY_MANAGED = 'https://mirall.app/privacy#managed'
const LINK = 'font-headline font-bold text-secondary hover:underline focus-ring rounded'

const FAILED_COPY = {
'no-configuration': { title: 'managed.activate.noConfigTitle', body: 'managed.activate.noConfigBody' },
unreachable: { title: 'managed.activate.unreachableTitle', body: 'managed.activate.unreachableBody' },
Expand Down Expand Up @@ -179,6 +183,12 @@ function ReadyBody({ preview, error, connecting, onConnect, onClose }: ReadyBody
return (
<>
<p id="managed-activate-body" className="text-on-surface-variant font-medium">{t('managed.activate.readyBody', { org: org.name })}</p>
<p className="text-sm text-on-surface-variant">
{t('managed.activate.sees', { org: org.name })}{' '}
<a href={PRIVACY_MANAGED} target="_blank" rel="noreferrer" className={LINK}>
{t('managed.activate.privacy')}<span className="sr-only"> {t('managed.activate.opensInBrowser')}</span>
</a>
</p>
{preview.replaces && <Callout tone="warning">{t('managed.activate.replaces', { previous: preview.replaces })}</Callout>}
<Contact org={org} />
{error && (
Expand All @@ -198,14 +208,13 @@ function ReadyBody({ preview, error, connecting, onConnect, onClose }: ReadyBody
function Contact({ org }: { org: ManagedOrganization }) {
const { t } = useTranslation()
if (!org.supportEmail && !org.supportUrl) return null
const link = 'font-headline font-bold text-secondary hover:underline focus-ring rounded'
return (
<p className="text-sm text-on-surface-variant">
{t('managed.activate.questions')}{' '}
{org.supportEmail && <a href={`mailto:${org.supportEmail}`} target="_blank" rel="noreferrer" className={link}>{org.supportEmail}</a>}
{org.supportEmail && <a href={`mailto:${org.supportEmail}`} target="_blank" rel="noreferrer" className={LINK}>{org.supportEmail}</a>}
{org.supportEmail && org.supportUrl && ' · '}
{org.supportUrl && (
<a href={org.supportUrl} target="_blank" rel="noreferrer" className={link}>
<a href={org.supportUrl} target="_blank" rel="noreferrer" className={LINK}>
{t('managed.activate.supportPage')}<span className="sr-only"> {t('managed.activate.opensInBrowser')}</span>
</a>
)}
Expand Down
2 changes: 2 additions & 0 deletions src/renderer/locales/de/common.json
Original file line number Diff line number Diff line change
Expand Up @@ -1704,6 +1704,8 @@
"preparingHint": "Mirall prüft weiter. Du kannst das schließen und den Link später erneut anklicken.",
"readyTitle": "Mirall mit {{org}} verbinden?",
"readyBody": "{{org}} verwaltet Einstellungen auf diesem Computer. Verwaltete Einstellungen lassen sich nicht ändern, solange die Verbindung besteht.",
"sees": "{{org}} sieht den Namen dieses Computers, seine Mirall-Version und sein Betriebssystem, welche ihrer Einstellungen gelten und ob Backups funktionieren. Nie deine Dateien, deine Spaces oder mit wem du teilst.",
"privacy": "Datenschutzerklärung",
"replaces": "Das ersetzt deine Verbindung mit {{previous}}.",
"questions": "Fragen?",
"supportPage": "Support-Seite",
Expand Down
2 changes: 2 additions & 0 deletions src/renderer/locales/en/common.json
Original file line number Diff line number Diff line change
Expand Up @@ -1704,6 +1704,8 @@
"preparingHint": "Mirall keeps checking. You can close this and click the link again later.",
"readyTitle": "Connect Mirall to {{org}}?",
"readyBody": "{{org}} will manage settings on this computer. Settings it manages can’t be changed while connected.",
"sees": "{{org}} will see this computer’s name, its Mirall version and operating system, which of its settings apply, and whether backups work. Never your files, your spaces or who you share with.",
"privacy": "Privacy Policy",
"replaces": "This replaces your connection to {{previous}}.",
"questions": "Questions?",
"supportPage": "Support page",
Expand Down
2 changes: 2 additions & 0 deletions src/renderer/locales/es/common.json
Original file line number Diff line number Diff line change
Expand Up @@ -1704,6 +1704,8 @@
"preparingHint": "Mirall sigue comprobando. Puedes cerrar esto y volver a hacer clic en el enlace más tarde.",
"readyTitle": "¿Conectar Mirall con {{org}}?",
"readyBody": "{{org}} gestionará ajustes en este ordenador. Los ajustes gestionados no se pueden cambiar mientras estés conectado.",
"sees": "{{org}} verá el nombre de este ordenador, su versión de Mirall y su sistema operativo, cuáles de sus ajustes se aplican y si las copias de seguridad funcionan. Nunca tus archivos, tus espacios ni con quién compartes.",
"privacy": "Política de privacidad",
"replaces": "Esto sustituye tu conexión con {{previous}}.",
"questions": "¿Preguntas?",
"supportPage": "Página de soporte",
Expand Down
2 changes: 2 additions & 0 deletions src/renderer/locales/fr/common.json
Original file line number Diff line number Diff line change
Expand Up @@ -1704,6 +1704,8 @@
"preparingHint": "Mirall continue de vérifier. Vous pouvez fermer ceci et cliquer à nouveau sur le lien plus tard.",
"readyTitle": "Connecter Mirall à {{org}} ?",
"readyBody": "{{org}} gérera des réglages sur cet ordinateur. Les réglages gérés ne peuvent pas être modifiés tant que la connexion est active.",
"sees": "{{org}} verra le nom de cet ordinateur, sa version de Mirall et son système d’exploitation, lesquels de ses réglages s’appliquent et si les sauvegardes fonctionnent. Jamais vos fichiers, vos espaces ni les personnes avec qui vous partagez.",
"privacy": "Politique de confidentialité",
"replaces": "Cela remplace votre connexion à {{previous}}.",
"questions": "Des questions ?",
"supportPage": "Page d’assistance",
Expand Down
2 changes: 2 additions & 0 deletions src/renderer/locales/it/common.json
Original file line number Diff line number Diff line change
Expand Up @@ -1704,6 +1704,8 @@
"preparingHint": "Mirall continua a verificare. Puoi chiudere e fare di nuovo clic sul link più tardi.",
"readyTitle": "Collegare Mirall a {{org}}?",
"readyBody": "{{org}} gestirà alcune impostazioni su questo computer. Le impostazioni gestite non si possono modificare finché sei collegato.",
"sees": "{{org}} vedrà il nome di questo computer, la sua versione di Mirall e il sistema operativo, quali delle sue impostazioni si applicano e se i backup funzionano. Mai i tuoi file, i tuoi spazi né con chi condividi.",
"privacy": "Informativa sulla privacy",
"replaces": "Questo sostituisce il collegamento a {{previous}}.",
"questions": "Domande?",
"supportPage": "Pagina di assistenza",
Expand Down
4 changes: 3 additions & 1 deletion test/frontend/scenarios/s186-managed-activate-accept.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,14 @@ export default async function s186({ runDir, bootstrap }) {
fixture.serve({ 'network.relayMode': 'auto', 'audit.enabled': true, 'audit.retentionDays': 90 })
const A = new Instance({ name: 'Alice', bootstrap, slot: 0, total: 1, env: fixture.env })
try {
await r.ok('the link opens the dialog with the organization and its contact, and no settings list', async () => {
await r.ok('the link opens the dialog with the organization, what it will see, its contact, and no settings list', async () => {
await A.launch()
await A.openDeepLink(fixture.link)
await A.waitText('Connect Mirall to Acme Test GmbH?', 20000)
assert(await A.hasText('it@acme.example'), 'the contact line')
assert(!(await A.hasText('Relay')), 'no list of managed settings')
assert(await A.hasText('Never your files, your spaces or who you share with'), 'what the organization will see')
assert(await A.has({ role: 'link', contains: 'Privacy Policy' }), 'the privacy policy link')
await A.shot('s186-ready', runDir)
})

Expand Down
Loading