Skip to content

Commit

Permalink
lint.
Browse files Browse the repository at this point in the history
  • Loading branch information
junhaoliao committed Sep 3, 2024
1 parent e2b1784 commit b9d6e76
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 3 deletions.
7 changes: 5 additions & 2 deletions new-log-viewer/src/components/Layout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -254,14 +254,17 @@ const Layout = () => {
);

updateWindowUrlHashParams({
logEventNum: firstLogEventNumOnNextPage || logEventNumRef.current < lastFilteredLogEventNum ?
logEventNum: firstLogEventNumOnNextPage ||
logEventNumRef.current < lastFilteredLogEventNum ?
lastFilteredLogEventNum :
numEventsRef.current,
});
}
break;
case ACTION_NAME.LAST_PAGE:
updateWindowUrlHashParams({logEventNum: lastFilteredLogEventNum || numEventsRef.current});
updateWindowUrlHashParams({
logEventNum: lastFilteredLogEventNum || numEventsRef.current,
});
break;
case ACTION_NAME.PAGE_TOP:
goToPositionAndCenter(editor, {lineNumber: 1, column: 1});
Expand Down
3 changes: 2 additions & 1 deletion new-log-viewer/src/contexts/StateContextProvider.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// eslint-disable-next-line no-warning-comments
// TODO: move handlers out from StateContextProvider.
/* eslint-disable max-lines, max-lines-per-function */
/* eslint-disable max-lines, max-lines-per-function, max-statements */
import React, {
createContext,
useCallback,
Expand Down Expand Up @@ -285,6 +285,7 @@ const StateContextProvider = ({children}: StateContextProviderProps) => {
pageNumRef.current = newPageNum;
}, [
firstLogEventNumPerPage,
numEvents,
numFilteredEvents,
logEventNum,
]);
Expand Down
1 change: 1 addition & 0 deletions new-log-viewer/src/services/MainWorker.ts
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ const postResp = <T extends WORKER_RESP_CODE>(
postMessage({code, args});
};

// eslint-disable-next-line max-lines-per-function
onmessage = async (ev: MessageEvent<MainWorkerReqMessage>) => {
const {code, args} = ev.data;
console.log(`[Renderer -> MainWorker] code=${code}: args=${JSON.stringify(args)}`);
Expand Down

0 comments on commit b9d6e76

Please sign in to comment.