Skip to content

Commit f96b603

Browse files
drew-harrisskeptrunedev
authored andcommitted
fix: sticky checkbox button on dashboard
1 parent d6edf79 commit f96b603

2 files changed

Lines changed: 8 additions & 3 deletions

File tree

frontends/dashboard/src/hooks/usePublicPageSettings.tsx

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -100,6 +100,13 @@ export const { use: usePublicPage, provider: PublicPageProvider } =
100100
if (extraParams.inline == undefined || extraParams.inline == null) {
101101
setExtraParams("inline", true);
102102
}
103+
104+
if (
105+
extraParams.showResultHighlights === null ||
106+
extraParams.showResultHighlights === undefined
107+
) {
108+
setExtraParams("showResultHighlights", true);
109+
}
103110
});
104111

105112
// Selecting another pattern builds the svg field

frontends/dashboard/src/pages/dataset/PublicPageSettings.tsx

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1078,9 +1078,7 @@ const PublicPageControls = () => {
10781078
</div>
10791079
<input
10801080
type="checkbox"
1081-
checked={
1082-
(extraParams.showResultHighlights as boolean) || true
1083-
}
1081+
checked={extraParams.showResultHighlights === true}
10841082
onChange={(e) => {
10851083
setExtraParams(
10861084
"showResultHighlights",

0 commit comments

Comments
 (0)