diff --git a/src/alerts/actions.ts b/src/alerts/actions.ts index e50238e68..ce483d1be 100644 --- a/src/alerts/actions.ts +++ b/src/alerts/actions.ts @@ -22,7 +22,8 @@ export const alertsShowAlert = createAction( type: 'alerts.action.showAlert', domain, specific, - props, + // HACK: using varargs to allow props to be optional, but it is only one arg + props: props.at(0), }), ); diff --git a/src/alerts/sagas.ts b/src/alerts/sagas.ts index f12a29c97..421b8c113 100644 --- a/src/alerts/sagas.ts +++ b/src/alerts/sagas.ts @@ -35,7 +35,9 @@ function* handleShowAlert(action: ReturnType): Generator try { const alertAction = yield* take(chan); // the dismiss actions will have called this already, but other actions don't - toaster.dismiss(key); + if (alertAction !== 'dismiss') { + toaster.dismiss(key); + } yield* put(alertsDidShowAlert(action.domain, action.specific, alertAction)); } finally { diff --git a/src/firmware/alerts/NoDfuHub.tsx b/src/firmware/alerts/NoDfuHub.tsx index 2ede5557a..5986f746e 100644 --- a/src/firmware/alerts/NoDfuHub.tsx +++ b/src/firmware/alerts/NoDfuHub.tsx @@ -26,7 +26,7 @@ const NoDfuHub: React.VoidFunctionComponent = () => { href={pybricksUsbDfuTroubleshootingUrl} target="_blank" > - {i18n.translate('noDfuHub.suggestion2')} + {i18n.translate('noDfuHub.troubleshootButton')} diff --git a/src/index.tsx b/src/index.tsx index 92ee13a11..0aa560fd9 100644 --- a/src/index.tsx +++ b/src/index.tsx @@ -47,9 +47,11 @@ const store = configureStore({ // copy of defaults 'meta.arg', 'meta.baseQueryMeta', - // HACK: technically serializable, can be removed after - // https://github.com/microsoft/vscode/pull/151993 + // monoco view state has class-based object but is technically serializable 'viewState.viewState.firstPosition', + // contain ArrayBuffer or DataView + 'data', + 'firmwareZip', ], }, })