mirror of
https://github.com/lensapp/lens.git
synced 2025-05-20 05:10:56 +00:00
Remove all references to slack (#7233)
* Remove all references to slack Signed-off-by: Sebastian Malton <sebastian@malton.name> * Fix readme Signed-off-by: Sebastian Malton <sebastian@malton.name> * Cleanup migration Signed-off-by: Sebastian Malton <sebastian@malton.name> * Remove existing slack link from weblink store Signed-off-by: Sebastian Malton <sebastian@malton.name> * Fix type error and wording on ErrorBoundary Signed-off-by: Sebastian Malton <sebastian@malton.name> * Don't export forumsUrl to extension API - Also just remove slack URL Signed-off-by: Sebastian Malton <sebastian@malton.name> * Update snapshots again Signed-off-by: Sebastian Malton <sebastian@malton.name> * Update snapshots again v3 Signed-off-by: Sebastian Malton <sebastian@malton.name> * Revert remove slackUrl Signed-off-by: Sebastian Malton <sebastian@malton.name> * Fix filtering Signed-off-by: Sebastian Malton <sebastian@malton.name> * Fix readme Signed-off-by: Sebastian Malton <sebastian@malton.name> * More of a fix Signed-off-by: Sebastian Malton <sebastian@malton.name> * Try again Signed-off-by: Sebastian Malton <sebastian@malton.name> * Slightly better for now Signed-off-by: Sebastian Malton <sebastian@malton.name> --------- Signed-off-by: Sebastian Malton <sebastian@malton.name>
This commit is contained in:
1 parent
5ad582d88e
commit
3067e82e02
29 files changed
+165
-160
No files matched your search
@@ -10,8 +10,8 @@ export const lensWebsiteLinkName = "Lens Website";
|
||||
export const lensDocumentationWeblinkId = "lens-documentation-link";
|
||||
export const lensDocumentationWeblinkName = "Lens Documentation";
|
||||
|
||||
export const lensSlackWeblinkId = "lens-slack-link";
|
||||
export const lensSlackWeblinkName = "Lens Community Slack";
|
||||
export const lensForumsWeblinkId = "lens-forums-link";
|
||||
export const lensForumsWeblinkName = "Lens Forums";
|
||||
|
||||
export const lensTwitterWeblinkId = "lens-twitter-link";
|
||||
export const lensTwitterWeblinkName = "Lens on Twitter";
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
* Licensed under MIT License. See LICENSE in root directory for more information.
|
||||
*/
|
||||
|
||||
import { docsUrl, slackUrl } from "../../../common/vars";
|
||||
import { docsUrl, forumsUrl } from "../../../common/vars";
|
||||
import type { WeblinkData } from "../../../common/weblinks-store/weblink-store";
|
||||
import { getInjectable } from "@ogre-tools/injectable";
|
||||
import { weblinkStoreMigrationInjectionToken } from "../../../common/weblinks-store/migration-token";
|
||||
@@ -20,7 +20,7 @@ const v514WeblinkStoreMigrationInjectable = getInjectable({
|
||||
weblinks.push(
|
||||
{ id: "https://k8slens.dev", name: links.lensWebsiteLinkName, url: "https://k8slens.dev" },
|
||||
{ id: docsUrl, name: links.lensDocumentationWeblinkName, url: docsUrl },
|
||||
{ id: slackUrl, name: links.lensSlackWeblinkName, url: slackUrl },
|
||||
{ id: forumsUrl, name: links.lensForumsWeblinkName, url: forumsUrl },
|
||||
{ id: "https://twitter.com/k8slens", name: links.lensTwitterWeblinkName, url: "https://twitter.com/k8slens" },
|
||||
{ id: "https://medium.com/k8slens", name: links.lensBlogWeblinkName, url: "https://medium.com/k8slens" },
|
||||
{ id: "https://kubernetes.io/docs/home/", name: links.kubernetesDocumentationWeblinkName, url: "https://kubernetes.io/docs/home/" },
|
||||
|
||||
@@ -16,40 +16,40 @@ const v545Beta1WeblinkStoreMigrationInjectable = getInjectable({
|
||||
const weblinksRaw = store.get("weblinks");
|
||||
const weblinks = (Array.isArray(weblinksRaw) ? weblinksRaw : []) as WeblinkData[];
|
||||
|
||||
const lensWebsiteLink = weblinks.find(weblink => weblink.name === links.lensWebsiteLinkName);
|
||||
const lensWebsite = weblinks.find(weblink => weblink.name === links.lensWebsiteLinkName);
|
||||
|
||||
if (lensWebsiteLink) {
|
||||
lensWebsiteLink.id = links.lensWebsiteWeblinkId;
|
||||
if (lensWebsite) {
|
||||
lensWebsite.id = links.lensWebsiteWeblinkId;
|
||||
}
|
||||
|
||||
const lensDocumentationWeblinkLink = weblinks.find(weblink => weblink.name === links.lensDocumentationWeblinkName);
|
||||
const lensDocumentationWeblink = weblinks.find(weblink => weblink.name === links.lensDocumentationWeblinkName);
|
||||
|
||||
if (lensDocumentationWeblinkLink) {
|
||||
lensDocumentationWeblinkLink.id = links.lensDocumentationWeblinkId;
|
||||
if (lensDocumentationWeblink) {
|
||||
lensDocumentationWeblink.id = links.lensDocumentationWeblinkId;
|
||||
}
|
||||
|
||||
const lensSlackWeblinkLink = weblinks.find(weblink => weblink.name === links.lensSlackWeblinkName);
|
||||
const lensForumsWeblink = weblinks.find(weblink => weblink.name === links.lensForumsWeblinkName);
|
||||
|
||||
if (lensSlackWeblinkLink) {
|
||||
lensSlackWeblinkLink.id = links.lensSlackWeblinkId;
|
||||
if (lensForumsWeblink) {
|
||||
lensForumsWeblink.id = links.lensForumsWeblinkId;
|
||||
}
|
||||
|
||||
const lensTwitterWeblinkLink = weblinks.find(weblink => weblink.name === links.lensTwitterWeblinkName);
|
||||
const lensTwitterWeblink = weblinks.find(weblink => weblink.name === links.lensTwitterWeblinkName);
|
||||
|
||||
if (lensTwitterWeblinkLink) {
|
||||
lensTwitterWeblinkLink.id = links.lensTwitterWeblinkId;
|
||||
if (lensTwitterWeblink) {
|
||||
lensTwitterWeblink.id = links.lensTwitterWeblinkId;
|
||||
}
|
||||
|
||||
const lensBlogWeblinkLink = weblinks.find(weblink => weblink.name === links.lensBlogWeblinkName);
|
||||
const lensBlogWeblink = weblinks.find(weblink => weblink.name === links.lensBlogWeblinkName);
|
||||
|
||||
if (lensBlogWeblinkLink) {
|
||||
lensBlogWeblinkLink.id = links.lensBlogWeblinkId;
|
||||
if (lensBlogWeblink) {
|
||||
lensBlogWeblink.id = links.lensBlogWeblinkId;
|
||||
}
|
||||
|
||||
const kubernetesDocumentationWeblinkLink = weblinks.find(weblink => weblink.name === links.kubernetesDocumentationWeblinkName);
|
||||
const kubernetesDocumentationWeblink = weblinks.find(weblink => weblink.name === links.kubernetesDocumentationWeblinkName);
|
||||
|
||||
if (kubernetesDocumentationWeblinkLink) {
|
||||
kubernetesDocumentationWeblinkLink.id = links.kubernetesDocumentationWeblinkId;
|
||||
if (kubernetesDocumentationWeblink) {
|
||||
kubernetesDocumentationWeblink.id = links.kubernetesDocumentationWeblinkId;
|
||||
}
|
||||
|
||||
store.set("weblinks", weblinks);
|
||||
|
||||
@@ -3,11 +3,11 @@
|
||||
* Licensed under MIT License. See LICENSE in root directory for more information.
|
||||
*/
|
||||
|
||||
import { docsUrl, slackUrl } from "../../../common/vars";
|
||||
import { docsUrl, forumsUrl } from "../../../common/vars";
|
||||
import type { WeblinkData } from "../../../common/weblinks-store/weblink-store";
|
||||
import { getInjectable } from "@ogre-tools/injectable";
|
||||
import { weblinkStoreMigrationInjectionToken } from "../../../common/weblinks-store/migration-token";
|
||||
import { lensDocumentationWeblinkId, lensSlackWeblinkId } from "../links";
|
||||
import { lensDocumentationWeblinkId, lensForumsWeblinkId } from "../links";
|
||||
import { applicationInformationToken } from "@k8slens/application";
|
||||
|
||||
const currentVersionWeblinkStoreMigrationInjectable = getInjectable({
|
||||
@@ -20,10 +20,10 @@ const currentVersionWeblinkStoreMigrationInjectable = getInjectable({
|
||||
run(store) {
|
||||
const weblinksRaw = store.get("weblinks");
|
||||
const weblinks = (Array.isArray(weblinksRaw) ? weblinksRaw : []) as WeblinkData[];
|
||||
const slackWeblink = weblinks.find(weblink => weblink.id === lensSlackWeblinkId);
|
||||
const forumsWeblink = weblinks.find(weblink => weblink.id === lensForumsWeblinkId);
|
||||
|
||||
if (slackWeblink) {
|
||||
slackWeblink.url = slackUrl;
|
||||
if (forumsWeblink) {
|
||||
forumsWeblink.url = forumsUrl;
|
||||
}
|
||||
|
||||
const docsWeblink = weblinks.find(weblink => weblink.id === lensDocumentationWeblinkId);
|
||||
@@ -32,7 +32,9 @@ const currentVersionWeblinkStoreMigrationInjectable = getInjectable({
|
||||
docsWeblink.url = docsUrl;
|
||||
}
|
||||
|
||||
store.set("weblinks", weblinks);
|
||||
const removedSlackLink = weblinks.filter(weblink => weblink.id !== "lens-slack-link");
|
||||
|
||||
store.set("weblinks", removedSlackLink);
|
||||
},
|
||||
};
|
||||
},
|
||||
|
||||
Reference in new issue
Block a user