Skip to content

Commit

Permalink
Merge pull request GoogleChromeLabs#385 from GoogleChromeLabs/renovat…
Browse files Browse the repository at this point in the history
…e/typescript-3.x

Update dependency typescript to v3.2.2
  • Loading branch information
surma authored Dec 17, 2018
2 parents 7217fe1 + c9dc807 commit d68d932
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 11 deletions.
6 changes: 3 additions & 3 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@
"tslint-config-semistandard": "7.0.0",
"tslint-react": "3.6.0",
"typed-css-modules": "0.3.7",
"typescript": "3.1.6",
"typescript": "3.2.2",
"url-loader": "1.1.2",
"webpack": "4.27.1",
"webpack-bundle-analyzer": "3.0.3",
Expand Down
4 changes: 2 additions & 2 deletions src/components/App/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,8 @@ export default class App extends Component<Props, State> {
if (process.env.NODE_ENV === 'development') {
this.setState(window.STATE);
const oldCDU = this.componentDidUpdate;
this.componentDidUpdate = (props, state) => {
if (oldCDU) oldCDU.call(this, props, state);
this.componentDidUpdate = (props, state, prev) => {
if (oldCDU) oldCDU.call(this, props, state, prev);
window.STATE = this.state;
};
}
Expand Down
4 changes: 3 additions & 1 deletion src/components/Options/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,9 @@ import Checkbox from '../checkbox';
import Expander from '../expander';
import Select from '../select';

const encoderOptionsComponentMap = {
const encoderOptionsComponentMap: {
[x: string]: (new (...args: any[]) => Component<any, any>) | undefined;
} = {
[identity.type]: undefined,
[optiPNG.type]: OptiPNGEncoderOptions,
[mozJPEG.type]: MozJpegEncoderOptions,
Expand Down
8 changes: 4 additions & 4 deletions src/components/compress/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -576,9 +576,9 @@ export default class Compress extends Component<Props, State> {
mobileView={mobileView}
preprocessorState={side.latestSettings.preprocessorState}
encoderState={side.latestSettings.encoderState}
onEncoderTypeChange={this.onEncoderTypeChange.bind(this, index)}
onEncoderOptionsChange={this.onEncoderOptionsChange.bind(this, index)}
onPreprocessorOptionsChange={this.onPreprocessorOptionsChange.bind(this, index)}
onEncoderTypeChange={this.onEncoderTypeChange.bind(this, index as 0|1)}
onEncoderOptionsChange={this.onEncoderOptionsChange.bind(this, index as 0|1)}
onPreprocessorOptionsChange={this.onPreprocessorOptionsChange.bind(this, index as 0|1)}
/>
));

Expand All @@ -592,7 +592,7 @@ export default class Compress extends Component<Props, State> {
source={source}
loading={loading || side.loading}
copyDirection={copyDirections[index]}
onCopyToOtherClick={this.onCopyToOtherClick.bind(this, index)}
onCopyToOtherClick={this.onCopyToOtherClick.bind(this, index as 0|1)}
buttonPosition={mobileView ? 'stack-right' : buttonPositions[index]}
>
{!mobileView ? null : [
Expand Down

0 comments on commit d68d932

Please sign in to comment.