-
+
+ setSearchTerm(e.target.value)}
+ />
+ {
+ if (searchInputRef.current.value === "") {
+ searchInputRef.current.value = "*";
+ setSearchTerm("*");
+ } else {
+ searchInputRef.current.value = "";
+ setSearchTerm("");
+ }
}}
>
- navigate("/")}
- className="inline-block ml-4 cursor-pointer"
- />
- History
+ {searchTerm === "" ? "Show All" : "Clear"}
+
+
+
+ {filteredAndSortedSessions.length === 0 && (
+
+ No past sessions found. To start a new session, either click the "+"
+ button or use the keyboard shortcut: Option + Command + N
- {/* {workspacePaths && workspacePaths.length > 0 && (
-
setFilteringByWorkspace((prev) => !prev)}
- title={`Show only sessions from ${lastPartOfPath(
- workspacePaths[workspacePaths.length - 1]
- )}/`}
- />
- )} */}
-
+ )}
-
-
- setSearchTerm(e.target.value)}
- />
- {
- if (searchInputRef.current.value === "") {
- searchInputRef.current.value = "*";
- setSearchTerm("*");
- } else {
- searchInputRef.current.value = "";
- setSearchTerm("");
- }
- }}
- >
- {searchTerm === "" ? "Show All" : "Clear"}
-
-
-
- {filteredAndSortedSessions.length === 0 && (
-
- No past sessions found. To start a new session, either click the "+"
- button or use the keyboard shortcut: Option + Command + N
-
- )}
-
-
-
- {filteredAndSortedSessions.map((session, index) => {
- const prevDate =
- index > 0
- ? parseDate(filteredAndSortedSessions[index - 1].dateCreated)
- : earlier;
- const date = parseDate(session.dateCreated);
- return (
-
- {index === 0 && date > yesterday && (
-
- Today
-
- )}
- {date < yesterday &&
- date > lastWeek &&
- prevDate > yesterday && (
-
- This Week
-
- )}
- {date < lastWeek &&
- date > lastMonth &&
- prevDate > lastWeek && (
-
- This Month
-
- )}
- {date < lastMonth && prevDate > lastMonth && (
-
- Older
-
+
+
+ {filteredAndSortedSessions.map((session, index) => {
+ const prevDate =
+ index > 0
+ ? parseDate(filteredAndSortedSessions[index - 1].dateCreated)
+ : earlier;
+ const date = parseDate(session.dateCreated);
+ return (
+
+ {index === 0 && date > yesterday && (
+ Today
+ )}
+ {date < yesterday &&
+ date > lastWeek &&
+ prevDate > yesterday && (
+ This Week
)}
+ {date < lastWeek && date > lastMonth && prevDate > lastWeek && (
+ This Month
+ )}
+ {date < lastMonth && prevDate > lastMonth && (
+ Older
+ )}
-
- deleteSessionInUI(session.sessionId)}
- >
-
-
- );
- })}
-
-
-
-
- All session data is saved in ~/.continue/sessions
-
-
+
+ deleteSessionInUI(session.sessionId)}
+ >
+
+
+ );
+ })}
+
+
+
+
+ All session data is saved in ~/.continue/sessions
+
);
}
-
-export default History;
diff --git a/gui/src/pages/gui.tsx b/gui/src/pages/gui/Chat.tsx
similarity index 92%
rename from gui/src/pages/gui.tsx
rename to gui/src/pages/gui/Chat.tsx
index 156c0b3b2..243657462 100644
--- a/gui/src/pages/gui.tsx
+++ b/gui/src/pages/gui/Chat.tsx
@@ -24,43 +24,43 @@ import {
lightGray,
vscBackground,
vscForeground,
-} from "../components";
-import { ChatScrollAnchor } from "../components/ChatScrollAnchor";
-import StepContainer from "../components/gui/StepContainer";
-import TimelineItem from "../components/gui/TimelineItem";
-import ContinueInputBox from "../components/mainInput/ContinueInputBox";
-import { defaultInputModifiers } from "../components/mainInput/inputModifiers";
-import { TutorialCard } from "../components/mainInput/TutorialCard";
+} from "../../components";
+import { ChatScrollAnchor } from "../../components/ChatScrollAnchor";
+import StepContainer from "../../components/gui/StepContainer";
+import TimelineItem from "../../components/gui/TimelineItem";
+import ContinueInputBox from "../../components/mainInput/ContinueInputBox";
+import { defaultInputModifiers } from "../../components/mainInput/inputModifiers";
+import { TutorialCard } from "../../components/mainInput/TutorialCard";
import {
OnboardingCard,
useOnboardingCard,
-} from "../components/OnboardingCard";
-import { IdeMessengerContext } from "../context/IdeMessenger";
-import useChatHandler from "../hooks/useChatHandler";
-import useHistory from "../hooks/useHistory";
-import { useTutorialCard } from "../hooks/useTutorialCard";
-import { useWebviewListener } from "../hooks/useWebviewListener";
-import { defaultModelSelector } from "../redux/selectors/modelSelectors";
+} from "../../components/OnboardingCard";
+import { IdeMessengerContext } from "../../context/IdeMessenger";
+import useChatHandler from "../../hooks/useChatHandler";
+import useHistory from "../../hooks/useHistory";
+import { useTutorialCard } from "../../hooks/useTutorialCard";
+import { useWebviewListener } from "../../hooks/useWebviewListener";
+import { defaultModelSelector } from "../../redux/selectors/modelSelectors";
import {
clearLastResponse,
deleteMessage,
newSession,
setInactive,
-} from "../redux/slices/stateSlice";
+} from "../../redux/slices/stateSlice";
import {
setDialogEntryOn,
setDialogMessage,
setShowDialog,
-} from "../redux/slices/uiStateSlice";
-import { RootState } from "../redux/store";
+} from "../../redux/slices/uiStateSlice";
+import { RootState } from "../../redux/store";
import {
getFontSize,
getMetaKeyLabel,
isJetBrains,
isMetaEquivalentKeyPressed,
-} from "../util";
-import { FREE_TRIAL_LIMIT_REQUESTS } from "../util/freeTrial";
-import { getLocalStorage, setLocalStorage } from "../util/localStorage";
+} from "../../util";
+import { FREE_TRIAL_LIMIT_REQUESTS } from "../../util/freeTrial";
+import { getLocalStorage, setLocalStorage } from "../../util/localStorage";
const TopGuiDiv = styled.div<{
showScrollbar?: boolean;
@@ -144,7 +144,7 @@ function fallbackRender({ error, resetErrorBoundary }: any) {
);
}
-function GUI() {
+export function Chat() {
const posthog = usePostHog();
const dispatch = useDispatch();
const ideMessenger = useContext(IdeMessengerContext);
@@ -528,5 +528,3 @@ function GUI() {
>
);
}
-
-export default GUI;
diff --git a/gui/src/pages/gui/index.tsx b/gui/src/pages/gui/index.tsx
new file mode 100644
index 000000000..53e184027
--- /dev/null
+++ b/gui/src/pages/gui/index.tsx
@@ -0,0 +1,22 @@
+import { Chat } from "./Chat";
+import { History } from "../../components/History";
+import styled from "styled-components";
+import { vscSidebarBorder } from "../../components";
+
+export const Aside = styled.aside`
+ border-right: 1px solid ${vscSidebarBorder};
+`;
+
+export default function GUI() {
+ return (
+
+ );
+}
diff --git a/gui/src/pages/history/HistoryHeader.tsx b/gui/src/pages/history/HistoryHeader.tsx
new file mode 100644
index 000000000..4a8d4688c
--- /dev/null
+++ b/gui/src/pages/history/HistoryHeader.tsx
@@ -0,0 +1,37 @@
+import { useNavigate } from "react-router-dom";
+import { lightGray, vscBackground } from "../../components";
+import { useNavigationListener } from "../../hooks/useNavigationListener";
+import { ArrowLeftIcon } from "@heroicons/react/24/outline";
+
+export const HistoryHeader = () => {
+ useNavigationListener();
+ const navigate = useNavigate();
+
+ return (
+
+
+
navigate("/")}
+ className="inline-block ml-4 cursor-pointer"
+ />
+ History
+
+ {/* {workspacePaths && workspacePaths.length > 0 && (
+
setFilteringByWorkspace((prev) => !prev)}
+ title={`Show only sessions from ${lastPartOfPath(
+ workspacePaths[workspacePaths.length - 1]
+ )}/`}
+ />
+ )} */}
+
+ );
+};
diff --git a/gui/src/pages/history/index.tsx b/gui/src/pages/history/index.tsx
new file mode 100644
index 000000000..6d31c60bc
--- /dev/null
+++ b/gui/src/pages/history/index.tsx
@@ -0,0 +1,12 @@
+import { History } from "../../components/History";
+import { getFontSize } from "../../util";
+import { HistoryHeader } from "./HistoryHeader";
+
+export default function HistoryPage() {
+ return (
+
+
+
+
+ );
+}
diff --git a/gui/tailwind.config.cjs b/gui/tailwind.config.cjs
index a20bdecf7..63e0c2810 100644
--- a/gui/tailwind.config.cjs
+++ b/gui/tailwind.config.cjs
@@ -10,12 +10,15 @@ module.exports = {
theme: {
// Note that these breakpoints are primarily optimized for the input toolbar
screens: {
- xxs: "170px", // Smallest width for Primary Sidebar in VS Code
+ "2xs": "170px", // Smallest width for Primary Sidebar in VS Code
xs: "250px", // Avg default sidebar width in VS Code
sm: "330px",
md: "460px",
lg: "590px",
xl: "720px",
+ "2xl": "860px",
+ "3xl": "1000px",
+ "4xl": "1140px",
},
extend: {
animation: {