Skip to content

Commit

Permalink
Merge pull request #28 from CompositionalIT/27-convert-react-props-to…
Browse files Browse the repository at this point in the history
…-ag-grid-props

#27 ensure custom props are of type IAgGridProp
  • Loading branch information
isaacabraham authored Feb 16, 2024
2 parents f50cff9 + 694a2de commit 5c0e615
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 11 deletions.
20 changes: 10 additions & 10 deletions src/AgGrid.fs
Original file line number Diff line number Diff line change
Expand Up @@ -156,8 +156,8 @@ type AgGrid() =
Export = fun () -> ev?api?exportDataAsCsv(obj()) |}
|> callback
agGridProp<'row>("onGridReady", onGridReady)
static member inline enableRangeHandle = prop.custom("enableRangeHandle", true)
static member inline enableRangeSelection = prop.custom("enableRangeSelection", true)
static member inline enableRangeHandle (v: bool) = agGridProp<'row>("enableRangeHandle", v)
static member inline enableRangeSelection (v: bool) = agGridProp<'row>("enableRangeSelection", v)
static member inline getContextMenuItems (callback : int -> int -> MenuItem list) = agGridProp<'row>("getContextMenuItems", fun x ->
let menuItems = callback x?node?rowIndex x?column?colId
[|
Expand All @@ -178,14 +178,14 @@ type AgGrid() =
callback startRow startColumn endRow endColumn)
static member inline popupParent parent = agGridProp<'row>("popupParent", parent)
static member inline processDataFromClipboard (callback : string[][] -> string[][]) = agGridProp<'row>("processDataFromClipboard", fun x -> callback x?data)
static member inline stopEditingWhenCellsLoseFocus = prop.custom("stopEditingWhenCellsLoseFocus", true)
static member inline stopEditingWhenGridLosesFocus = prop.custom("stopEditingWhenGridLosesFocus", true)
static member inline suppressClipboardApi = prop.custom("suppressClipboardApi", true)
static member inline suppressCopyRowsToClipboard = prop.custom("suppressCopyRowsToClipboard", true)
static member inline suppressCopySingleCellRanges = prop.custom("suppressCopySingleCellRanges", true)
static member inline suppressMultiRangeSelection = prop.custom("suppressMultiRangeSelection", true)
static member inline suppressRowHoverHighlight = prop.custom("suppressRowHoverHighlight", true)
static member inline suppressScrollOnNewData = prop.custom("suppressScrollOnNewData", true)
static member inline stopEditingWhenCellsLoseFocus (v: bool) = agGridProp<'row>("stopEditingWhenCellsLoseFocus", v)
static member inline stopEditingWhenGridLosesFocus (v: bool) = agGridProp<'row>("stopEditingWhenGridLosesFocus", v)
static member inline suppressClipboardApi (v: bool) = agGridProp<'row>("suppressClipboardApi", v)
static member inline suppressCopyRowsToClipboard (v: bool) = agGridProp<'row>("suppressCopyRowsToClipboard", v)
static member inline suppressCopySingleCellRanges (v: bool) = agGridProp<'row>("suppressCopySingleCellRanges", v)
static member inline suppressMultiRangeSelection (v: bool) = agGridProp<'row>("suppressMultiRangeSelection", v)
static member inline suppressRowHoverHighlight (v: bool) = agGridProp<'row>("suppressRowHoverHighlight", v)
static member inline suppressScrollOnNewData (v: bool) = agGridProp<'row>("suppressScrollOnNewData", v)

static member inline key (v:string) = agGridProp<'row> (prop.key v)
static member inline key (v:int) = agGridProp<'row> (prop.key v)
Expand Down
2 changes: 1 addition & 1 deletion src/Feliz.AgGrid.fsproj
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<TargetFramework>net6.0</TargetFramework>
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
<Authors>Compositional IT</Authors>
<Version>1.0.0</Version>
<Version>1.0.1</Version>
<PackageProjectUrl>https://github.com/CompositionalIT/feliz-ag-grid</PackageProjectUrl>
<RepositoryUrl>https://github.com/CompositionalIT/feliz-ag-grid</RepositoryUrl>
</PropertyGroup>
Expand Down

0 comments on commit 5c0e615

Please sign in to comment.