react-tether: Provides its own types (#39530)

This commit is contained in:
Alexander T
2019-10-28 20:28:32 -07:00
committed by Jesse Trinity
parent 4728586434
commit 49e9a494fb
5 changed files with 6 additions and 68 deletions
+6
View File
@@ -3240,6 +3240,12 @@
"sourceRepoURL": "https://github.com/tanem/react-svg",
"asOfVersion": "5.0.0"
},
{
"libraryName": "react-tether",
"typingsPackageName": "react-tether",
"sourceRepoURL": "https://github.com/danreeves/react-tether",
"asOfVersion": "1.0.0"
},
{
"libraryName": "react-webcam",
"typingsPackageName": "react-webcam",
-25
View File
@@ -1,25 +0,0 @@
// Type definitions for react-tether 0.5
// Project: https://github.com/danreeves/react-tether
// Definitions by: Ryan Price <https://github.com/ryprice>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
// TypeScript Version: 2.8
export default TetherComponent;
export as namespace ReactTether;
import * as React from 'react';
import * as Tether from 'tether';
declare class TetherComponent extends React.Component<ReactTether.TetherComponentProps> { }
declare namespace ReactTether {
interface TetherComponentProps extends React.Props<TetherComponent>, Tether.ITetherOptions {
renderElementTag?: string;
renderElementTo?: string | { appendChild(element: HTMLElement): void };
id?: string;
className?: string;
style?: React.CSSProperties;
onUpdate?(): void;
onRepositioned?(): void;
}
}
-16
View File
@@ -1,16 +0,0 @@
import TetherComponent from "react-tether";
import * as React from "react";
const ReactTetherAllOptions: JSX.Element =
<TetherComponent
attachment="bottom middle"
id="id123"
className="react-tether"
onUpdate={() => {}}
onRepositioned={() => {}}
renderElementTag="div"
renderElementTo=".container"
/>;
const ReactTetherRequiredOptions: JSX.Element =
<TetherComponent attachment="bottom middle" />;
-25
View File
@@ -1,25 +0,0 @@
{
"compilerOptions": {
"module": "commonjs",
"lib": [
"es6",
"dom"
],
"noImplicitAny": true,
"noImplicitThis": true,
"strictNullChecks": true,
"strictFunctionTypes": true,
"jsx": "react",
"baseUrl": "../",
"typeRoots": [
"../"
],
"types": [],
"noEmit": true,
"forceConsistentCasingInFileNames": true
},
"files": [
"index.d.ts",
"react-tether-tests.tsx"
]
}
-2
View File
@@ -1,2 +0,0 @@
{ "extends": "dtslint/dt.json" }