Skip to content

Commit

Permalink
fix: comment out activeTab functionality tmp
Browse files Browse the repository at this point in the history
  • Loading branch information
roshaans committed Aug 16, 2023
1 parent 0d07cf8 commit d95e3cc
Showing 1 changed file with 9 additions and 8 deletions.
17 changes: 9 additions & 8 deletions frontend/widgets/src/QueryApi.Dashboard.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ const limit = 7;
let totalIndexers = 0;

State.init({
activeTab: Storage.privateGet("queryapi:activeTab") || activeTab,
activeTab: activeTab,
my_indexers: [],
all_indexers: [],
selected_indexer: undefined,
Expand Down Expand Up @@ -274,12 +274,13 @@ const ButtonLink = styled.a`
}}
`;

const previousSelectedTab = Storage.privateGet("queryapi:activeTab");
if (previousSelectedTab && previousSelectedTab !== state.activeTab) {
State.update({
activeTab: previousSelectedTab,
});
}
// TODO fix activeTab
// const previousSelectedTab = Storage.privateGet("queryapi:activeTab");
// if (previousSelectedTab && previousSelectedTab !== state.activeTab) {
// State.update({
// activeTab: previousSelectedTab,
// });
// }

const selectTab = (tabName) => {
Storage.privateSet("queryapi:activeTab", tabName);
Expand Down Expand Up @@ -346,7 +347,7 @@ return (
>
Indexers
</TabsButton>
{props.view === "create-new-indexer" && (
{state.activeTab == "create-new-indexer" && (
<TabsButton
type="button"
onClick={() => selectTab("create-new-indexer")}
Expand Down

0 comments on commit d95e3cc

Please sign in to comment.