Skip to content

Commit

Permalink
[flatpickr] Fix DefinitelyTyped#20701: Deprecate redundant "flatpickr…
Browse files Browse the repository at this point in the history
…" types (DefinitelyTyped#20983)

* Cut: Run "not-needed" script.

* Cut: .github/CODEOWNERS entries.

* Fix: "react-flatpickr" definition file and tests.
  • Loading branch information
begincalendar authored and sheetalkamat committed Oct 25, 2017
1 parent 302690e commit a374bea
Show file tree
Hide file tree
Showing 13 changed files with 16 additions and 262 deletions.
2 changes: 0 additions & 2 deletions .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
Expand Up @@ -931,8 +931,6 @@
/types/first-mate/ @GlenCFL
/types/fixed-data-table/ @pepaar @stephenjelfs
/types/flat/ @chrootsu
/types/flatpickr/v2/ @UnwrittenFun
/types/flatpickr/ @UnwrittenFun @rowellx68 @wagich
/types/flexslider/ @diullei
/types/flickity/ @clmcgrath @wagich
/types/flight/ @jonathanhedren
Expand Down
6 changes: 6 additions & 0 deletions notNeededPackages.json
Original file line number Diff line number Diff line change
Expand Up @@ -216,6 +216,12 @@
"sourceRepoURL": "http://fineuploader.com/",
"asOfVersion": "5.14.0"
},
{
"libraryName": "flatpickr",
"typingsPackageName": "flatpickr",
"sourceRepoURL": "https://github.com/chmln/flatpickr",
"asOfVersion": "3.1.2"
},
{
"libraryName": "gaea-model",
"typingsPackageName": "gaea-model",
Expand Down
14 changes: 0 additions & 14 deletions types/flatpickr/flatpickr-tests.ts

This file was deleted.

105 changes: 0 additions & 105 deletions types/flatpickr/index.d.ts

This file was deleted.

24 changes: 0 additions & 24 deletions types/flatpickr/tsconfig.json

This file was deleted.

1 change: 0 additions & 1 deletion types/flatpickr/tslint.json

This file was deleted.

14 changes: 0 additions & 14 deletions types/flatpickr/v2/flatpickr-tests.ts

This file was deleted.

68 changes: 0 additions & 68 deletions types/flatpickr/v2/index.d.ts

This file was deleted.

29 changes: 0 additions & 29 deletions types/flatpickr/v2/tsconfig.json

This file was deleted.

1 change: 0 additions & 1 deletion types/flatpickr/v2/tslint.json

This file was deleted.

4 changes: 2 additions & 2 deletions types/react-flatpickr/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@
// TypeScript Version: 2.3

import { Component } from 'react';
import { EventCallback, Options } from 'flatpickr';
import { Hook, Options } from 'flatpickr';

export interface DateTimePickerProps {
defaultValue?: string;
options?: Options;
onChange?: EventCallback;
onChange?: Hook;
value?: string;
}

Expand Down
6 changes: 6 additions & 0 deletions types/react-flatpickr/package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"private": true,
"dependencies": {
"flatpickr": "^4.0.6"
}
}
4 changes: 2 additions & 2 deletions types/react-flatpickr/react-flatpickr-tests.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import * as Flatpickr from 'flatpickr';
import { Instance } from 'flatpickr';
import * as React from 'react';
import DatePicker from 'react-flatpickr';

Expand All @@ -12,7 +12,7 @@ const options = {
const optionsElement = <DatePicker options={ options }/>;

const onChange = (
selectedDates: Date[], dateStr: string, instance: Flatpickr,
selectedDates: Date[], dateStr: string, instance: Instance,
elem: HTMLElement
) => null;
const onChangeElement = <DatePicker onChange={ onChange }/>;
Expand Down

0 comments on commit a374bea

Please sign in to comment.