Unverified Commit 040af46e authored by Hong Minhee's avatar Hong Minhee
Browse files

Fix type error on `fedify inbox` command

parent 9642125e
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -12,7 +12,8 @@
    ".vscode",
    "fedify-cli-*.tar.xz",
    "fedify-cli-*.tgz",
    "fedify-cli-*.zip"
    "fedify-cli-*.zip",
    "npm"
  ],
  "unstable": [
    "fs",
+6 −0
Original line number Diff line number Diff line
@@ -379,6 +379,12 @@ app.get("/r/:idx{[0-9]+}", (c) => {
  const tab = c.req.query("tab") ?? "request";
  const activity = activities[idx];
  if (activity == null) return c.notFound();
  if (
    tab !== "request" && tab !== "response" && tab !== "raw-activity" &&
    tab !== "compact-activity" && tab !== "expanded-activity" && tab !== "logs"
  ) {
    return c.notFound();
  }
  return c.html(<ActivityEntryPage idx={idx} entry={activity} tabPage={tab} />);
});

+9 −7
Original line number Diff line number Diff line
@@ -169,15 +169,17 @@ const LogList: FC<LogListProps> = ({ logs }: LogListProps) => {
  );
};

interface ActivityEntryViewProps {
  entry: ActivityEntry;
  tabPage:
type ActivityEntryTabPage =
  | "request"
  | "response"
  | "raw-activity"
  | "compact-activity"
  | "expanded-activity"
  | "logs";

interface ActivityEntryViewProps {
  entry: ActivityEntry;
  tabPage: ActivityEntryTabPage;
}

const ActivityEntryView: FC<ActivityEntryViewProps> = async (