chore: enable no load by default (#5968)
* enable no load by default * remove help section brackets * fallback to server with mentions
This commit is contained in:
parent
712339a638
commit
4251b114c3
3 changed files with 19 additions and 25 deletions
|
|
@ -31,7 +31,4 @@ export const filterActivityOnSelectedFilters = (
|
||||||
): TIssueActivityComment[] =>
|
): TIssueActivityComment[] =>
|
||||||
activity.filter((activity) => filter.includes(activity.activity_type as TActivityFilters));
|
activity.filter((activity) => filter.includes(activity.activity_type as TActivityFilters));
|
||||||
|
|
||||||
// boolean to decide if the local db cache is enabled
|
|
||||||
export const ENABLE_LOCAL_DB_CACHE = false;
|
|
||||||
|
|
||||||
export const ENABLE_ISSUE_DEPENDENCIES = false;
|
export const ENABLE_ISSUE_DEPENDENCIES = false;
|
||||||
|
|
|
||||||
|
|
@ -16,7 +16,6 @@ import { usePlatformOS } from "@/hooks/use-platform-os";
|
||||||
// plane web components
|
// plane web components
|
||||||
import { PlaneVersionNumber } from "@/plane-web/components/global";
|
import { PlaneVersionNumber } from "@/plane-web/components/global";
|
||||||
import { WorkspaceEditionBadge } from "@/plane-web/components/workspace";
|
import { WorkspaceEditionBadge } from "@/plane-web/components/workspace";
|
||||||
import { ENABLE_LOCAL_DB_CACHE } from "@/plane-web/constants/issues";
|
|
||||||
|
|
||||||
export interface WorkspaceHelpSectionProps {
|
export interface WorkspaceHelpSectionProps {
|
||||||
setSidebarActive?: React.Dispatch<React.SetStateAction<boolean>>;
|
setSidebarActive?: React.Dispatch<React.SetStateAction<boolean>>;
|
||||||
|
|
@ -111,23 +110,21 @@ export const SidebarHelpSection: React.FC<WorkspaceHelpSectionProps> = observer(
|
||||||
</a>
|
</a>
|
||||||
</CustomMenu.MenuItem>
|
</CustomMenu.MenuItem>
|
||||||
<div className="my-1 border-t border-custom-border-200" />
|
<div className="my-1 border-t border-custom-border-200" />
|
||||||
{ENABLE_LOCAL_DB_CACHE && (
|
<CustomMenu.MenuItem>
|
||||||
<CustomMenu.MenuItem>
|
<div
|
||||||
<div
|
onClick={(e) => {
|
||||||
onClick={(e) => {
|
e.preventDefault();
|
||||||
e.preventDefault();
|
e.stopPropagation();
|
||||||
e.stopPropagation();
|
}}
|
||||||
}}
|
className="flex w-full items-center justify-between text-xs hover:bg-custom-background-80"
|
||||||
className="flex w-full items-center justify-between text-xs hover:bg-custom-background-80"
|
>
|
||||||
>
|
<span className="racking-tight">Local Cache</span>
|
||||||
<span className="racking-tight">Local Cache</span>
|
<ToggleSwitch
|
||||||
<ToggleSwitch
|
value={canUseLocalDB}
|
||||||
value={canUseLocalDB}
|
onChange={() => toggleLocalDB(workspaceSlug?.toString(), projectId?.toString())}
|
||||||
onChange={() => toggleLocalDB(workspaceSlug?.toString(), projectId?.toString())}
|
/>
|
||||||
/>
|
</div>
|
||||||
</div>
|
</CustomMenu.MenuItem>
|
||||||
</CustomMenu.MenuItem>
|
|
||||||
)}
|
|
||||||
<CustomMenu.MenuItem>
|
<CustomMenu.MenuItem>
|
||||||
<button
|
<button
|
||||||
type="button"
|
type="button"
|
||||||
|
|
@ -173,8 +170,9 @@ export const SidebarHelpSection: React.FC<WorkspaceHelpSectionProps> = observer(
|
||||||
<Tooltip tooltipContent={`${isCollapsed ? "Expand" : "Hide"}`} isMobile={isMobile}>
|
<Tooltip tooltipContent={`${isCollapsed ? "Expand" : "Hide"}`} isMobile={isMobile}>
|
||||||
<button
|
<button
|
||||||
type="button"
|
type="button"
|
||||||
className={`grid place-items-center rounded-md p-1 text-custom-text-200 outline-none hover:bg-custom-background-90 hover:text-custom-text-100 ${isCollapsed ? "w-full" : ""
|
className={`grid place-items-center rounded-md p-1 text-custom-text-200 outline-none hover:bg-custom-background-90 hover:text-custom-text-100 ${
|
||||||
}`}
|
isCollapsed ? "w-full" : ""
|
||||||
|
}`}
|
||||||
onClick={() => toggleSidebar()}
|
onClick={() => toggleSidebar()}
|
||||||
>
|
>
|
||||||
<MoveLeft className={`h-4 w-4 duration-300 ${isCollapsed ? "rotate-180" : ""}`} />
|
<MoveLeft className={`h-4 w-4 duration-300 ${isCollapsed ? "rotate-180" : ""}`} />
|
||||||
|
|
|
||||||
|
|
@ -9,7 +9,6 @@ import { TUserPermissions } from "@plane/types/src/enums";
|
||||||
import { API_BASE_URL } from "@/helpers/common.helper";
|
import { API_BASE_URL } from "@/helpers/common.helper";
|
||||||
// local
|
// local
|
||||||
import { persistence } from "@/local-db/storage.sqlite";
|
import { persistence } from "@/local-db/storage.sqlite";
|
||||||
import { ENABLE_LOCAL_DB_CACHE } from "@/plane-web/constants/issues";
|
|
||||||
import { EUserPermissions } from "@/plane-web/constants/user-permissions";
|
import { EUserPermissions } from "@/plane-web/constants/user-permissions";
|
||||||
// services
|
// services
|
||||||
import { AuthService } from "@/services/auth.service";
|
import { AuthService } from "@/services/auth.service";
|
||||||
|
|
@ -278,6 +277,6 @@ export class UserStore implements IUserStore {
|
||||||
}
|
}
|
||||||
|
|
||||||
get localDBEnabled() {
|
get localDBEnabled() {
|
||||||
return ENABLE_LOCAL_DB_CACHE && this.userSettings.canUseLocalDB;
|
return this.userSettings.canUseLocalDB;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue