File tree Expand file tree Collapse file tree 3 files changed +52
-1
lines changed Expand file tree Collapse file tree 3 files changed +52
-1
lines changed Original file line number Diff line number Diff line change 3
3
"version" : " 0.0.0-semantically-released" ,
4
4
"description" : " Datepickers built with Semantic UI for React and Dayzed" ,
5
5
"main" : " dist/react-semantic-ui-datepickers.js" ,
6
+ "typings" : " ./dist/index.d.ts" ,
6
7
"scripts" : {
7
8
"add-contributor" : " kcd-scripts contributors add" ,
8
9
"build" : " kcd-scripts build --bundle cjs.minify" ,
Original file line number Diff line number Diff line change @@ -11,7 +11,10 @@ module.exports = {
11
11
sourcemap : true ,
12
12
} ) ,
13
13
plugins : [
14
- copy ( { 'src/locales' : 'dist/locales' } ) ,
14
+ copy ( {
15
+ 'src/locales' : 'dist/locales' ,
16
+ 'src/index.d.ts' : 'dist/index.d.ts' ,
17
+ } ) ,
15
18
postcss ( { extract : true , minimize : true } ) ,
16
19
] . concat ( rollupConfig . plugins ) ,
17
20
} ;
Original file line number Diff line number Diff line change
1
+ import * as React from 'react' ;
2
+ import { SemanticICONS , SemanticSIZES } from 'semantic-ui-react' ;
3
+
4
+ interface Locale {
5
+ todayButton : string ;
6
+ nextMonth : string ;
7
+ previousMonth : string ;
8
+ nextYear : string ;
9
+ previousYear : string ;
10
+ weekdays : string [ ] ;
11
+ months : string [ ] ;
12
+ }
13
+
14
+ export interface SemanticDatepickerProps {
15
+ clearable ?: boolean ;
16
+ date ?: Date ;
17
+ disabled ?: boolean ;
18
+ error ?: boolean ;
19
+ firstDayOfWeek ?: number ;
20
+ format ?: string ;
21
+ icon ?: SemanticICONS ;
22
+ iconPosition ?: 'left' ;
23
+ id ?: string ;
24
+ keepOpenOnClear ?: boolean ;
25
+ keepOpenOnSelect ?: boolean ;
26
+ label ?: string ;
27
+ loading ?: boolean ;
28
+ locale ?: Locale ;
29
+ maxDate ?: Date ;
30
+ minDate ?: Date ;
31
+ name ?: string ;
32
+ onDateChange : ( newDate : Date | Date [ ] | null ) => void ;
33
+ placeholder ?: string ;
34
+ placeholder ?: string ;
35
+ selected ?: Date | Date [ ] ;
36
+ showOutsideDays ?: boolean ;
37
+ size ?: SemanticSIZES ;
38
+ transparent ?: boolean ;
39
+ type : 'basic' | 'range' ;
40
+ }
41
+
42
+ declare class SemanticDatepicker extends React . Component <
43
+ SemanticDatepickerProps ,
44
+ any
45
+ > { }
46
+
47
+ export default SemanticDatepicker ;
You can’t perform that action at this time.
0 commit comments