From caedcc59136b8439a4c2f3141f93a9c024369526 Mon Sep 17 00:00:00 2001 From: Mark Nelissen Date: Wed, 20 Jun 2018 19:44:21 +0200 Subject: [PATCH 1/2] switch CSS properties of DraggableProviderDraggableProps from null to undefined, to match type definitions in react 16.4 --- types/react-beautiful-dnd/index.d.ts | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/types/react-beautiful-dnd/index.d.ts b/types/react-beautiful-dnd/index.d.ts index 8d25e79407..feffaf1f29 100644 --- a/types/react-beautiful-dnd/index.d.ts +++ b/types/react-beautiful-dnd/index.d.ts @@ -1,10 +1,11 @@ -// Type definitions for react-beautiful-dnd 6.0 +// Type definitions for react-beautiful-dnd 7.1 // Project: https://github.com/atlassian/react-beautiful-dnd // Definitions by: varHarrie // Bradley Ayers // Austin Turner +// Mark Nelissen // Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped -// TypeScript Version: 2.6 +// TypeScript Version: 2.9 import * as React from 'react'; @@ -84,8 +85,8 @@ export class Droppable extends React.Component {} */ export interface NotDraggingStyle { - transform: null | string; - transition: null | 'none'; + transform?: string; + transition?: 'none'; } export interface DraggingStyle { @@ -97,14 +98,14 @@ export interface DraggingStyle { top: number; left: number; margin: 0; - transform: null | string; + transform?: string; transition: 'none'; zIndex: ZIndex; } export interface DraggableProvidedDraggableProps { // inline style - style: null | DraggingStyle | NotDraggingStyle; + style?: DraggingStyle | NotDraggingStyle; // used for shared global styles 'data-react-beautiful-dnd-draggable': string; } From 32d32a03024cc1949e5cc517ea69f3aef0b80c35 Mon Sep 17 00:00:00 2001 From: Mark Nelissen Date: Wed, 20 Jun 2018 19:51:07 +0200 Subject: [PATCH 2/2] align TypeScript version on the one from react --- types/react-beautiful-dnd/index.d.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/types/react-beautiful-dnd/index.d.ts b/types/react-beautiful-dnd/index.d.ts index feffaf1f29..3cb5e026f8 100644 --- a/types/react-beautiful-dnd/index.d.ts +++ b/types/react-beautiful-dnd/index.d.ts @@ -5,7 +5,7 @@ // Austin Turner // Mark Nelissen // Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped -// TypeScript Version: 2.9 +// TypeScript Version: 2.6 import * as React from 'react';