react-konva-grid
Advanced tools
Comparing version 2.0.5 to 2.0.6
{ | ||
"name": "react-konva-grid", | ||
"description": "Canvas grid to render large set of tabular data with virtualization.", | ||
"version": "2.0.5", | ||
"version": "2.0.6", | ||
"main": "dist/index.js", | ||
@@ -15,3 +15,4 @@ "license": "MIT", | ||
"postpublish": "storybook-to-ghpages", | ||
"prettier": "prettier src/**/*.tsx --write" | ||
"prettier": "prettier src/**/*.tsx --write", | ||
"test": "jest" | ||
}, | ||
@@ -27,2 +28,3 @@ "author": "Vinay M <rmdort@gmail.com>", | ||
"dependencies": { | ||
"@types/jest": "^25.2.3", | ||
"konva": "^6.0.0", | ||
@@ -60,2 +62,3 @@ "react-konva": "^16.13.0-3" | ||
"husky": "^4.2.5", | ||
"jest": "^26.0.1", | ||
"lint-staged": "^10.2.4", | ||
@@ -62,0 +65,0 @@ "prettier": "^2.0.5", |
@@ -17,2 +17,3 @@ ## Declarative Canvas Grid with React Konva | ||
- :fire: Freeze rows and columns | ||
- :white_square_button: Merge rows and columns | ||
- :hand: Resizable headers | ||
@@ -40,3 +41,3 @@ - :hammer_and_wrench: Fully typed API written in TypeScript | ||
Konva grid will work with any browser that supports [react](https://github.com/facebook/react/), [konva](https://konvajs.org/) and canvas element. | ||
Konva grid will work in any browser that supports [react](https://github.com/facebook/react/), [konva](https://konvajs.org/) and canvas element. | ||
@@ -105,2 +106,3 @@ ## Usage | ||
| selections | false | Array | Array of selected cell areas | []| | ||
| mergedCells | false | Array | Array of merged cell areas | []| | ||
| frozenRows | false | number | No of frozen rows | 0 | | ||
@@ -138,2 +140,2 @@ | frozenColumns | false | number | No of frozen columns | 0 | | ||
yarn storybook | ||
```` | ||
```` |
@@ -137,8 +137,9 @@ // Utilities extracted from https://github.com/bvaughn/react-window | ||
export const getBoundedCells = (area: IArea) => { | ||
export const getBoundedCells = (area: IArea | null | undefined) => { | ||
const cells = new Set(); | ||
if (!area) return cells; | ||
const { top, bottom, left, right } = area; | ||
const cells = new Set(); | ||
for (let i = top; i <= bottom; i++) { | ||
for (let j = left; j <= right; j++) { | ||
cells.add(JSON.stringify([i, j])); | ||
cells.add(cellIndentifier(i, j)); | ||
} | ||
@@ -418,1 +419,7 @@ } | ||
}; | ||
/* Create a stringified cell identifier */ | ||
export const cellIndentifier = ( | ||
rowIndex: number, | ||
columnIndex: number | ||
): string => [rowIndex, columnIndex].toString(); |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
8046415
16
2193
138
5
19
+ Added@types/jest@^25.2.3
+ Added@jest/types@25.5.0(transitive)
+ Added@types/istanbul-lib-coverage@2.0.6(transitive)
+ Added@types/istanbul-lib-report@3.0.3(transitive)
+ Added@types/istanbul-reports@1.1.2(transitive)
+ Added@types/jest@25.2.3(transitive)
+ Added@types/yargs@15.0.19(transitive)
+ Added@types/yargs-parser@21.0.3(transitive)
+ Addedansi-regex@5.0.1(transitive)
+ Addedansi-styles@4.3.0(transitive)
+ Addedchalk@3.0.0(transitive)
+ Addedcolor-convert@2.0.1(transitive)
+ Addedcolor-name@1.1.4(transitive)
+ Addeddiff-sequences@25.2.6(transitive)
+ Addedhas-flag@4.0.0(transitive)
+ Addedjest-diff@25.5.0(transitive)
+ Addedjest-get-type@25.2.6(transitive)
+ Addedpretty-format@25.5.0(transitive)
+ Addedsupports-color@7.2.0(transitive)