Skip to content

TagSpaces is an offline, open source, document manager with tagging support

chore: reactivating Kanban perspective

Ilian Sapundshiev41e09b5e9de0
diff --git a/app/components/FolderContainer.tsx b/app/components/FolderContainer.tsx
index 6fa344ca1..f79515d32 100644
--- a/app/components/FolderContainer.tsx
+++ b/app/components/FolderContainer.tsx
@@ -448,21 +448,26 @@ function FolderContainer(props: Props) {
const perspectiveToggleButtons = [];
AvailablePerspectives.forEach(perspective => {
- if (perspective.beta === false) {
- perspectiveToggleButtons.push(
- <ToggleButton
- value={perspective.id}
- aria-label={perspective.id}
- key={perspective.id}
- data-tid={perspective.key}
- onClick={() => switchPerspective(perspective.id)}
+ // if (perspective.beta === false) {
+ perspectiveToggleButtons.push(
+ <ToggleButton
+ value={perspective.id}
+ aria-label={perspective.id}
+ key={perspective.id}
+ data-tid={perspective.key}
+ onClick={() => switchPerspective(perspective.id)}
+ >
+ <Tooltip
+ title={
+ perspective.title +
+ (perspective.beta && ' ' + i18n.t('core:betaStatus').toUpperCase())
+ }
>
- <Tooltip title={perspective.title}>
- <div style={{ display: 'flex' }}>{perspective.icon}</div>
- </Tooltip>
- </ToggleButton>
- );
- }
+ <div style={{ display: 'flex' }}>{perspective.icon}</div>
+ </Tooltip>
+ </ToggleButton>
+ );
+ // }
});
return (
diff --git a/app/components/PerspectiveSelector.tsx b/app/components/PerspectiveSelector.tsx
index ab9127a60..b017a1401 100644
--- a/app/components/PerspectiveSelector.tsx
+++ b/app/components/PerspectiveSelector.tsx
@@ -28,6 +28,7 @@ import i18n from '../services/i18n';
import { Pro } from '-/pro';
import { connect } from 'react-redux';
import { getCurrentLanguage } from '-/reducers/settings';
+import { BetaLabel, ProLabel } from '-/components/HelperComponents';
function PerspectiveSelector(props) {
const { defaultValue, onChange, testId, label } = props;
@@ -49,13 +50,10 @@ function PerspectiveSelector(props) {
);
AvailablePerspectives.forEach(perspective => {
- let includePerspective = perspective.beta === false;
+ let includePerspective = true;
if (!Pro && perspective.pro === true) {
includePerspective = false;
}
- if (Pro && perspective.beta === false) {
- includePerspective = true;
- }
if (includePerspective) {
perspectiveSelectorMenuItems.push(
<MenuItem key={perspective.key} value={perspective.id}>
@@ -63,7 +61,10 @@ function PerspectiveSelector(props) {
<ListItemIcon style={{ paddingLeft: 3, paddingTop: 3 }}>
{perspective.icon}
</ListItemIcon>
- <ListItemText>{perspective.title}</ListItemText>
+ <ListItemText>
+ {perspective.title}&nbsp;
+ {perspective.beta && <BetaLabel />}
+ </ListItemText>
</div>
</MenuItem>
);
diff --git a/app/components/menus/DirectoryMenu.tsx b/app/components/menus/DirectoryMenu.tsx
index ce7da6681..ad15f9511 100644
--- a/app/components/menus/DirectoryMenu.tsx
+++ b/app/components/menus/DirectoryMenu.tsx
@@ -213,14 +213,6 @@ function DirectoryMenu(props: Props) {
true
);
}
- // } else if (perspectiveId === PerspectiveIDs.WIKI) {
- // const openPersDocs = window.confirm(i18n.t('perspectiveInPro'));
- // if (openPersDocs) {
- // props.openURLExternally(
- // Links.documentationLinks.kanbanPerspective,
- // true
- // );
- // }
}
}
diff --git a/app/perspectives/index.tsx b/app/perspectives/index.tsx
index bff5bdf69..6c13d5764 100644
--- a/app/perspectives/index.tsx
+++ b/app/perspectives/index.tsx
@@ -52,15 +52,6 @@ export const ListPerspectiveMeta = {
title: 'List Perspective'
};
-// export const WikiPerspectiveMeta = {
-// id: PerspectiveIDs.WIKI,
-// key: 'openWikiPerspective',
-// pro: true,
-// beta: true,
-// icon: <WikiPerspectiveIcon />,
-// title: 'Wiki Perspective'
-// };
-
export const MapiquePerspectiveMeta = {
id: PerspectiveIDs.MAPIQUE,
key: 'openMapiquePerspective',
@@ -74,7 +65,7 @@ export const KanbanPerspectiveMeta = {
id: PerspectiveIDs.KANBAN,
key: 'openKanbanPerspective',
pro: true,
- beta: false,
+ beta: true,
icon: <KanbanPerspectiveIcon />,
title: 'Kanban Perspective'
};