mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-02-23 01:02:54 +00:00
Fix CSSProperties indexer issue (sort of)
This commit is contained in:
parent
6102332bf0
commit
b4fdbace3d
@ -206,15 +206,16 @@ myComponent.reset();
|
||||
// --------------------------------------------------------------------------
|
||||
|
||||
var children: any[] = ["Hello world", [null], React.DOM.span(null)];
|
||||
var divStyle: React.CSSProperties = { // CSSProperties
|
||||
flex: "1 1 main-size",
|
||||
backgroundImage: "url('hello.png')"
|
||||
};
|
||||
var htmlAttr: React.HTMLAttributes = {
|
||||
key: 36,
|
||||
ref: "htmlComponent",
|
||||
children: children,
|
||||
className: "test-attr",
|
||||
style: { // CSSProperties
|
||||
flex: "1 1 main-size",
|
||||
backgroundImage: "url('hello.png')"
|
||||
},
|
||||
style: divStyle,
|
||||
onClick: (event: React.MouseEvent) => {
|
||||
event.preventDefault();
|
||||
event.stopPropagation();
|
||||
|
||||
4
react/react.d.ts
vendored
4
react/react.d.ts
vendored
@ -403,7 +403,7 @@ declare namespace __React {
|
||||
strokeOpacity?: number;
|
||||
strokeWidth?: number;
|
||||
|
||||
[propertyName: string]: string | number | boolean;
|
||||
[propertyName: string]: any;
|
||||
}
|
||||
|
||||
interface HTMLAttributes extends DOMAttributes {
|
||||
@ -1200,7 +1200,7 @@ declare module "react/addons" {
|
||||
strokeOpacity?: number;
|
||||
strokeWidth?: number;
|
||||
|
||||
[propertyName: string]: string | number | boolean;
|
||||
[propertyName: string]: any;
|
||||
}
|
||||
|
||||
interface HTMLAttributes extends DOMAttributes {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user