mirror of
https://github.com/quine-global/hyper.git
synced 2026-01-13 04:28:41 -09:00
Fix errors reported after upgrading to typescript 4.2
Removed ResizeObserver polyfill and added explicit type declaration for HyperState
This commit is contained in:
parent
4a91e03a78
commit
e554e1db4f
5 changed files with 12 additions and 23 deletions
|
|
@ -11,7 +11,6 @@ import Color from 'color';
|
|||
import terms from '../terms';
|
||||
import processClipboard from '../utils/paste';
|
||||
import SearchBox from './searchBox';
|
||||
import ResizeObserver from 'resize-observer-polyfill';
|
||||
import {TermProps} from '../hyper';
|
||||
import {ObjectTypedKeys} from '../utils/object';
|
||||
|
||||
|
|
|
|||
7
lib/hyper.d.ts
vendored
7
lib/hyper.d.ts
vendored
|
|
@ -162,8 +162,11 @@ export type hyperPlugin = {
|
|||
reduceUI: IUiReducer;
|
||||
};
|
||||
|
||||
import rootReducer from './reducers/index';
|
||||
export type HyperState = ReturnType<typeof rootReducer>;
|
||||
export type HyperState = {
|
||||
ui: Immutable<uiState>;
|
||||
sessions: Immutable<sessionState>;
|
||||
termGroups: Immutable<ITermState>;
|
||||
};
|
||||
|
||||
import {UIActions} from './constants/ui';
|
||||
import {ConfigActions} from './constants/config';
|
||||
|
|
|
|||
|
|
@ -1,18 +1,11 @@
|
|||
import {combineReducers} from 'redux';
|
||||
import ui, {IUiReducer} from './ui';
|
||||
import sessions, {ISessionReducer} from './sessions';
|
||||
import termGroups, {ITermGroupReducer} from './term-groups';
|
||||
import {HyperActions} from '../hyper';
|
||||
import {combineReducers, Reducer} from 'redux';
|
||||
import ui from './ui';
|
||||
import sessions from './sessions';
|
||||
import termGroups from './term-groups';
|
||||
import {HyperActions, HyperState} from '../hyper';
|
||||
|
||||
export default combineReducers<
|
||||
{
|
||||
ui: ReturnType<IUiReducer>;
|
||||
sessions: ReturnType<ISessionReducer>;
|
||||
termGroups: ReturnType<ITermGroupReducer>;
|
||||
},
|
||||
HyperActions
|
||||
>({
|
||||
export default combineReducers({
|
||||
ui,
|
||||
sessions,
|
||||
termGroups
|
||||
});
|
||||
}) as Reducer<HyperState, HyperActions>;
|
||||
|
|
|
|||
|
|
@ -116,7 +116,6 @@
|
|||
"prettier": "2.2.1",
|
||||
"proxyquire": "2.1.3",
|
||||
"redux-devtools-extension": "2.13.8",
|
||||
"resize-observer-polyfill": "1.5.1",
|
||||
"spectron": "13.0.0",
|
||||
"style-loader": "2.0.0",
|
||||
"terser": "5.6.0",
|
||||
|
|
|
|||
|
|
@ -6480,11 +6480,6 @@ reselect@4.0.0:
|
|||
resolved "https://registry.npmjs.org/reselect/-/reselect-4.0.0.tgz#f2529830e5d3d0e021408b246a206ef4ea4437f7"
|
||||
integrity sha512-qUgANli03jjAyGlnbYVAV5vvnOmJnODyABz51RdBN7M4WaVu8mecZWgyQNkG8Yqe3KRGRt0l4K4B3XVEULC4CA==
|
||||
|
||||
resize-observer-polyfill@1.5.1:
|
||||
version "1.5.1"
|
||||
resolved "https://registry.npmjs.org/resize-observer-polyfill/-/resize-observer-polyfill-1.5.1.tgz#0e9020dd3d21024458d4ebd27e23e40269810464"
|
||||
integrity sha512-LwZrotdHOo12nQuZlHEmtuXdqGoOD0OhaxopaNFxWzInpEgaLWoVuAMbTzixuosCx2nEG58ngzW3vxdWoxIgdg==
|
||||
|
||||
resolve-alpn@^1.0.0:
|
||||
version "1.0.0"
|
||||
resolved "https://registry.npmjs.org/resolve-alpn/-/resolve-alpn-1.0.0.tgz#745ad60b3d6aff4b4a48e01b8c0bdc70959e0e8c"
|
||||
|
|
|
|||
Loading…
Reference in a new issue