@trackunit/filters-filter-bar 0.1.4 → 0.1.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.cjs.js +1 -1
- package/index.esm.js +1 -1
- package/package.json +1 -1
- package/src/lib/components/FilterResults.d.ts +4 -4
package/index.cjs.js
CHANGED
|
@@ -384,7 +384,7 @@ const FilterHeader = ({ filterKey, title, searchEnabled, searchProps, filterHasC
|
|
|
384
384
|
* shows no results if length or array is 0
|
|
385
385
|
* otherwise it calls children as a render prop
|
|
386
386
|
*/
|
|
387
|
-
const FilterResults = ({ results, ignoreUndefined, loading, children }) => {
|
|
387
|
+
const FilterResults = ({ results, ignoreUndefined, loading, children, }) => {
|
|
388
388
|
if (!results) {
|
|
389
389
|
return null;
|
|
390
390
|
}
|
package/index.esm.js
CHANGED
|
@@ -382,7 +382,7 @@ const FilterHeader = ({ filterKey, title, searchEnabled, searchProps, filterHasC
|
|
|
382
382
|
* shows no results if length or array is 0
|
|
383
383
|
* otherwise it calls children as a render prop
|
|
384
384
|
*/
|
|
385
|
-
const FilterResults = ({ results, ignoreUndefined, loading, children }) => {
|
|
385
|
+
const FilterResults = ({ results, ignoreUndefined, loading, children, }) => {
|
|
386
386
|
if (!results) {
|
|
387
387
|
return null;
|
|
388
388
|
}
|
package/package.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
interface Props<
|
|
2
|
-
results:
|
|
1
|
+
interface Props<TResult> {
|
|
2
|
+
results: TResult[] | undefined | null;
|
|
3
3
|
loading?: boolean;
|
|
4
4
|
ignoreUndefined?: boolean;
|
|
5
|
-
children: (results:
|
|
5
|
+
children: (results: TResult[]) => JSX.Element;
|
|
6
6
|
}
|
|
7
7
|
/**
|
|
8
8
|
* Wrapper around results for filters.
|
|
@@ -10,5 +10,5 @@ interface Props<T> {
|
|
|
10
10
|
* shows no results if length or array is 0
|
|
11
11
|
* otherwise it calls children as a render prop
|
|
12
12
|
*/
|
|
13
|
-
export declare const FilterResults: <
|
|
13
|
+
export declare const FilterResults: <TResult extends object | string>({ results, ignoreUndefined, loading, children, }: Props<TResult>) => import("react/jsx-runtime").JSX.Element | null;
|
|
14
14
|
export {};
|