mirror of
https://github.com/gosticks/react-table.git
synced 2026-08-11 20:40:17 +00:00
Merge branch 'master' of https://github.com/react-tools/react-table
This commit is contained in:
@@ -1,5 +1,13 @@
|
||||
{
|
||||
"dist/index.js": {
|
||||
"bundled": 113198,
|
||||
"minified": 52513,
|
||||
"gzipped": 13835
|
||||
},
|
||||
"dist/index.es.js": {
|
||||
"bundled": 112261,
|
||||
"minified": 51677,
|
||||
"gzipped": 13669,
|
||||
"bundled": 126701,
|
||||
"minified": 59700,
|
||||
"gzipped": 15373
|
||||
|
||||
@@ -72,7 +72,7 @@ The following options are supported on any `Column` object passed to the `column
|
||||
- Defaults to `false`
|
||||
- If set to `true`, the underlying sorting direction will be inverted, but the UI will not.
|
||||
- This may be useful in situations where positive and negative connotation is inverted, eg. a Golfing score where a lower score is considered more positive than a higher one.
|
||||
- `sortType: String | Function(rowA: <Row>, rowB: <Row>, columnID: String, desc: Bool)`
|
||||
- `sortType: String | Function(rowA: <Row>, rowB: <Row>, columnId: String, desc: Bool)`
|
||||
- Used to compare 2 rows of data and order them correctly.
|
||||
- If a **function** is passed, it must be **memoized**
|
||||
- String options: `basic`, `datetime`, `alphanumeric`. Defaults to `alphanumeric`.
|
||||
@@ -106,7 +106,7 @@ The following properties are available on every `Column` object returned by the
|
||||
- This function is used to resolve any props needed for this column's UI that is responsible for toggling the sort direction when the user clicks it.
|
||||
- You can use the `getSortByToggleProps` hook to extend its functionality.
|
||||
- Custom props may be passed. **NOTE: Custom props may override built-in sortBy props, so be careful!**
|
||||
- `clearSorting: Function() => void`
|
||||
- `clearSortBy: Function() => void`
|
||||
- This function can be used to programmatically clear the sorting for this column.
|
||||
- `isSorted: Boolean`
|
||||
- Denotes whether this column is currently being sorted
|
||||
|
||||
@@ -63,7 +63,7 @@ const EditableCell = ({
|
||||
updateMyData(index, id, value)
|
||||
}
|
||||
|
||||
// If the initialValue is changed externall, sync it up with our state
|
||||
// If the initialValue is changed external, sync it up with our state
|
||||
React.useEffect(() => {
|
||||
setValue(initialValue)
|
||||
}, [initialValue])
|
||||
|
||||
+2
-2
@@ -1,10 +1,10 @@
|
||||
[
|
||||
{
|
||||
"timestamp": 1578686270736,
|
||||
"timestamp": 1581710431975,
|
||||
"files": [
|
||||
{
|
||||
"filename": "index.js",
|
||||
"size": 23119,
|
||||
"size": 25790,
|
||||
"delta": -3
|
||||
}
|
||||
]
|
||||
|
||||
+3
-3
@@ -1,11 +1,11 @@
|
||||
[
|
||||
{
|
||||
"timestamp": 1578686279477,
|
||||
"timestamp": 1581710438411,
|
||||
"files": [
|
||||
{
|
||||
"filename": "index.es.js",
|
||||
"size": 22915,
|
||||
"delta": -2
|
||||
"size": 25587,
|
||||
"delta": -4
|
||||
}
|
||||
]
|
||||
}
|
||||
|
||||
@@ -128,7 +128,6 @@ function useInstance(instance) {
|
||||
state: { groupBy },
|
||||
dispatch,
|
||||
autoResetGroupBy = true,
|
||||
manaulGroupBy,
|
||||
disableGroupBy,
|
||||
defaultCanGroupBy,
|
||||
getHooks,
|
||||
@@ -320,7 +319,7 @@ function useInstance(instance) {
|
||||
if (getAutoResetGroupBy()) {
|
||||
dispatch({ type: actions.resetGroupBy })
|
||||
}
|
||||
}, [dispatch, manaulGroupBy ? null : data])
|
||||
}, [dispatch, manualGroupBy ? null : data])
|
||||
|
||||
Object.assign(instance, {
|
||||
preGroupedRows: rows,
|
||||
|
||||
Reference in New Issue
Block a user