chore: Lint shared directory

This commit is contained in:
Tom Moor
2020-06-22 21:29:21 -07:00
parent 26f6961c82
commit 9be5597f4b
27 changed files with 342 additions and 341 deletions

View File

@ -3,54 +3,54 @@
export function slackAuth(
state: string,
scopes: string[] = [
'identity.email',
'identity.basic',
'identity.avatar',
'identity.team',
"identity.email",
"identity.basic",
"identity.avatar",
"identity.team",
],
redirectUri: string = `${process.env.URL}/auth/slack.callback`
): string {
const baseUrl = 'https://slack.com/oauth/authorize';
const baseUrl = "https://slack.com/oauth/authorize";
const params = {
client_id: process.env.SLACK_KEY,
scope: scopes ? scopes.join(' ') : '',
scope: scopes ? scopes.join(" ") : "",
redirect_uri: redirectUri,
state,
};
const urlParams = Object.keys(params)
.map(key => `${key}=${encodeURIComponent(params[key])}`)
.join('&');
.join("&");
return `${baseUrl}?${urlParams}`;
}
export function githubUrl(): string {
return 'https://www.github.com/outline';
return "https://www.github.com/outline";
}
export function githubIssuesUrl(): string {
return 'https://www.github.com/outline/outline/issues';
return "https://www.github.com/outline/outline/issues";
}
export function slackAppStoreUrl(): string {
return 'https://goabstract.slack.com/apps/A0W3UMKBQ-outline';
return "https://goabstract.slack.com/apps/A0W3UMKBQ-outline";
}
export function blogUrl(): string {
return 'https://medium.com/getoutline';
return "https://medium.com/getoutline";
}
export function twitterUrl(): string {
return 'https://twitter.com/outlinewiki';
return "https://twitter.com/outlinewiki";
}
export function spectrumUrl(): string {
return 'https://spectrum.chat/outline';
return "https://spectrum.chat/outline";
}
export function mailToUrl(): string {
return 'mailto:hello@getoutline.com';
return "mailto:hello@getoutline.com";
}
export function features(): string {
@ -65,7 +65,7 @@ export function changelog(): string {
return `https://www.getoutline.com/changelog`;
}
export function signin(service: string = 'slack'): string {
export function signin(service: string = "slack"): string {
return `${process.env.URL}/auth/${service}`;
}