Comparing version 2.0.0 to 2.0.1
@@ -29,8 +29,2 @@ import React from 'react' | ||
) => [ContainerRect, (element: HTMLElement) => void] | ||
export declare const getColumns: ( | ||
width?: number, | ||
minimumWidth?: number, | ||
gutter?: number, | ||
columnCount?: number | undefined | ||
) => [number, number] | ||
export interface SizeObserverProps { | ||
@@ -97,13 +91,2 @@ as: any | ||
export declare const List: React.FC<ListProps> | ||
/** | ||
* Returns all of the ranges within a larger range that contain unloaded rows. | ||
*/ | ||
export declare const scanForUnloadedRanges: ( | ||
isItemLoaded: (index: number, items: any[]) => boolean, | ||
minimumBatchSize: number, | ||
items: any[], | ||
totalItems: number, | ||
startIndex: number, | ||
stopIndex: number | ||
) => number[] | ||
export interface InfiniteLoaderOptions { | ||
@@ -110,0 +93,0 @@ isItemLoaded?: (index: number, items: any[]) => boolean |
'use strict' | ||
exports.__esModule = true | ||
exports.useInfiniteLoader = exports.scanForUnloadedRanges = exports.List = exports.Masonry = exports.FreeMasonry = exports.getColumns = exports.useContainerRect = exports.useWindowScroller = void 0 | ||
exports.useInfiniteLoader = exports.List = exports.Masonry = exports.FreeMasonry = exports.useContainerRect = exports.useWindowScroller = void 0 | ||
@@ -409,3 +409,2 @@ var _propTypes = _interopRequireDefault(require('prop-types')) | ||
exports.getColumns = getColumns | ||
const getContainerStyle = (0, _memoizeOne.default)( | ||
@@ -1030,4 +1029,2 @@ (isScrolling, estimateTotalHeight) => ({ | ||
exports.scanForUnloadedRanges = scanForUnloadedRanges | ||
const defaultIsItemLoaded = (index, items) => items[index] !== void 0 | ||
@@ -1034,0 +1031,0 @@ |
@@ -29,8 +29,2 @@ import React from 'react' | ||
) => [ContainerRect, (element: HTMLElement) => void] | ||
export declare const getColumns: ( | ||
width?: number, | ||
minimumWidth?: number, | ||
gutter?: number, | ||
columnCount?: number | undefined | ||
) => [number, number] | ||
export interface SizeObserverProps { | ||
@@ -97,13 +91,2 @@ as: any | ||
export declare const List: React.FC<ListProps> | ||
/** | ||
* Returns all of the ranges within a larger range that contain unloaded rows. | ||
*/ | ||
export declare const scanForUnloadedRanges: ( | ||
isItemLoaded: (index: number, items: any[]) => boolean, | ||
minimumBatchSize: number, | ||
items: any[], | ||
totalItems: number, | ||
startIndex: number, | ||
stopIndex: number | ||
) => number[] | ||
export interface InfiniteLoaderOptions { | ||
@@ -110,0 +93,0 @@ isItemLoaded?: (index: number, items: any[]) => boolean |
@@ -340,8 +340,4 @@ import _pt from 'prop-types' | ||
} | ||
export const getColumns = ( | ||
width = 0, | ||
minimumWidth = 0, | ||
gutter = 8, | ||
columnCount | ||
) => { | ||
const getColumns = (width = 0, minimumWidth = 0, gutter = 8, columnCount) => { | ||
columnCount = columnCount || Math.floor(width / (minimumWidth + gutter)) || 1 | ||
@@ -353,2 +349,3 @@ const columnWidth = Math.floor( | ||
} | ||
const getContainerStyle = memoizeOne((isScrolling, estimateTotalHeight) => ({ | ||
@@ -885,3 +882,4 @@ position: 'relative', | ||
} | ||
export const scanForUnloadedRanges = ( | ||
const scanForUnloadedRanges = ( | ||
isItemLoaded, | ||
@@ -888,0 +886,0 @@ minimumBatchSize, |
{ | ||
"name": "masonic", | ||
"version": "2.0.0", | ||
"version": "2.0.1", | ||
"homepage": "https://github.com/jaredLunde/masonic#readme", | ||
@@ -5,0 +5,0 @@ "repository": "github:jaredLunde/masonic", |
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
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
0
102626
2837