diff --git a/src/server_manager/messages/en.json b/src/server_manager/messages/en.json index 10779a39..06f38c03 100644 --- a/src/server_manager/messages/en.json +++ b/src/server_manager/messages/en.json @@ -261,10 +261,13 @@ "setup-step-by-step": "Step-by-step set-up guide", "setup-tested": "Tested on VULTR, Linode, and Liquid Web", "setup-title": "Choose a cloud service to set up Outline.", - "share-description-html": "Copy this invitation and send it from a communication tool you trust. {openLink}Need help?{closeLink}", + "share-description": "Copy this invitation and send it from a communication tool you trust. {openLink}Need help?{closeLink}", + "share-invite": "You’re invited to connect to my Outline server. Use it to access the open internet, no matter where you are. Follow the instructions on your invitation link below to download the Outline App and get connected.", "share-invite-copied": "Copied to clipboard", "share-invite-copy": "Copy invitation", - "share-invite-html": "You're invited to Outline! Follow these instructions to use my server to access the open internet on any device, no matter where you are. No personal information will be collected.

1) Download and install the Outline app for your device:

- Android: https://play.google.com/store/apps/details?id=org.outline.android.client
- iOS: https://itunes.apple.com/app/outline-app/id1356177741
- Windows: https://s3.amazonaws.com/outline-releases/client/Outline-Client.exe - once downloaded, double click to launch.
- macOS: https://itunes.apple.com/app/outline-app/id1356178125
- Linux: https://s3.amazonaws.com/outline-releases/client/Outline-Client.AppImage - once downloaded, make it executable, then double click to launch.

2) Copy the following access key.
{openLink}{accessKey}{closeLink}

3) In the Outline app, tap the \"+\" sign on the top bar and paste the access key.

4) Press the \"ADD SERVER\" button to confirm.

5) A card will be added to your app. Tap \"Connect\" to get connected with the new service you added.", + "share-invite-copy-access-key": "Copy your access key:", + "share-invite-instructions": "Follow our invitation instructions on GitHub:", + "share-invite-trouble": "Having trouble accessing the invitation link?", "share-title": "Share access", "survey-data-limits-title": "Help us understand how to improve data limits", "survey-decline": "Decline", diff --git a/src/server_manager/messages/master_messages.json b/src/server_manager/messages/master_messages.json index d48048d8..8c6da347 100644 --- a/src/server_manager/messages/master_messages.json +++ b/src/server_manager/messages/master_messages.json @@ -1227,7 +1227,7 @@ "message": "Choose a cloud service to set up Outline.", "description": "This string appears in the server setup view as a header. Prompts the user to create deploy Outline servers on the cloud provider of their choice. 'Set up' means install and run the Outline server software." }, - "share_description_html": { + "share_description": { "message": "Copy this invitation and send it from a communication tool you trust. $START_OF_LINK$Need help?$END_OF_LINK$", "description": "This string appears as a sub-header of a dialog that provides instructions on how to share access to a server.", "placeholders": { @@ -1239,23 +1239,9 @@ } } }, - "share_invite_html": { - "message": "You're invited to Outline! Follow these instructions to use my server to access the open internet on any device, no matter where you are. No personal information will be collected.$LINE_BREAK$$LINE_BREAK$1) Download and install the Outline app for your device:$LINE_BREAK$$LINE_BREAK$ - Android: https://play.google.com/store/apps/details?id=org.outline.android.client$LINE_BREAK$ - iOS: https://itunes.apple.com/app/outline-app/id1356177741$LINE_BREAK$ - Windows: https://s3.amazonaws.com/outline-releases/client/Outline-Client.exe - once downloaded, double click to launch.$LINE_BREAK$ - macOS: https://itunes.apple.com/app/outline-app/id1356178125$LINE_BREAK$ - Linux: https://s3.amazonaws.com/outline-releases/client/Outline-Client.AppImage - once downloaded, make it executable, then double click to launch.$LINE_BREAK$$LINE_BREAK$2) Copy the following access key.$LINE_BREAK$ $START_OF_LINK$$ACCESS_KEY$$END_OF_LINK$$LINE_BREAK$$LINE_BREAK$3) In the Outline app, tap the \"+\" sign on the top bar and paste the access key.$LINE_BREAK$$LINE_BREAK$4) Press the \"ADD SERVER\" button to confirm.$LINE_BREAK$$LINE_BREAK$5) A card will be added to your app. Tap \"Connect\" to get connected with the new service you added.", - "description": "This string appears as an email invitation instructing new Outline users how to set up and connect to Outline.", - "placeholders": { - "ACCESS_KEY": { - "content": "{accessKey}" - }, - "END_OF_LINK": { - "content": "{closeLink}" - }, - "LINE_BREAK": { - "content": "
" - }, - "START_OF_LINK": { - "content": "{openLink}" - } - } + "share_invite": { + "message": "You\u2019re invited to connect to my Outline server. Use it to access the open internet, no matter where you are. Follow the instructions on your invitation link below to download the Outline App and get connected.", + "description": "This string appears as a paragraph within a dialog that provides an invitation to share access to a server. Belongs to the instructions for the user with whom access is being shared." }, "share_invite_copied": { "message": "Copied to clipboard", @@ -1265,6 +1251,18 @@ "message": "Copy invitation", "description": "This string appears as a button within a dialog that provides an invitation to share access to a server. Clicking it copies the invitation instructions text to the clipboard." }, + "share_invite_copy_access_key": { + "message": "Copy your access key:", + "description": "This string appears as a paragraph within a dialog that provides an invitation to share access to a server. Belongs to the instructions for the user with whom access is being shared." + }, + "share_invite_instructions": { + "message": "Follow our invitation instructions on GitHub:", + "description": "This string appears as a list item within a dialog that provides an invitation to share access to a server. Belongs to the instructions for the user with whom access is being shared." + }, + "share_invite_trouble": { + "message": "Having trouble accessing the invitation link?", + "description": "This string appears as a paragraph within a dialog that provides an invitation to share access to a server. Belongs to the instructions for the user with whom access is being shared." + }, "share_title": { "message": "Share access", "description": "This string appears as the header of a dialog that provides an invitation to share access to a server." diff --git a/src/server_manager/web_app/app.ts b/src/server_manager/web_app/app.ts index b7a37847..ea742559 100644 --- a/src/server_manager/web_app/app.ts +++ b/src/server_manager/web_app/app.ts @@ -302,7 +302,7 @@ export class App { appRoot.addEventListener('OpenShareDialogRequested', (event: CustomEvent) => { const accessKey = event.detail.accessKey; - this.appRoot.openShareDialog(accessKey); + this.appRoot.openShareDialog(accessKey, this.getS3InviteUrl(accessKey)); }); appRoot.addEventListener('OpenGetConnectedDialogRequested', (event: CustomEvent) => { diff --git a/src/server_manager/web_app/ui_components/app-root.ts b/src/server_manager/web_app/ui_components/app-root.ts index 97a39c52..670f833e 100644 --- a/src/server_manager/web_app/ui_components/app-root.ts +++ b/src/server_manager/web_app/ui_components/app-root.ts @@ -993,8 +993,8 @@ export class AppRoot extends polymerElementWithLocalize { (this.$.feedbackDialog as OutlineFeedbackDialog).open(prepopulatedMessage, true); } - openShareDialog(accessKey: string) { - (this.$.shareDialog as OutlineShareDialog).open(accessKey); + openShareDialog(accessKey: string, s3Url: string) { + (this.$.shareDialog as OutlineShareDialog).open(accessKey, s3Url); } openPerKeyDataLimitDialog( diff --git a/src/server_manager/web_app/ui_components/outline-share-dialog.ts b/src/server_manager/web_app/ui_components/outline-share-dialog.ts index 7a1bb5d9..881cad18 100644 --- a/src/server_manager/web_app/ui_components/outline-share-dialog.ts +++ b/src/server_manager/web_app/ui_components/outline-share-dialog.ts @@ -21,7 +21,7 @@ import {html} from '@polymer/polymer/lib/utils/html-tag'; import * as clipboard from 'clipboard-polyfill'; export interface OutlineShareDialog extends Element { - open(accessKey: string): void; + open(accessKey: string, s3url: string): void; } // TODO(alalama): add a language selector. This should be a separate instance of @@ -108,15 +108,29 @@ Polymer({

[[localize('share-title')]]

-
+
+

[[localize('share-invite')]]

+ +

{{s3Url}}

+

-----

+

[[localize('share-invite-trouble')]]

+
    +
  1. + [[localize('share-invite-copy-access-key')]] + {{accessKey}} +
  2. +
  3. + [[localize('share-invite-instructions')]] + https://github.com/Jigsaw-Code/outline-client/blob/master/docs/invitation_instructions.md +
  4. +
+
[[localize('share-invite-copy')]]