@draftbit/core 50.8.3 → 50.8.4
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/lib/commonjs/components/SectionList/SectionHeader.js +1 -1
- package/lib/commonjs/components/SectionList/SectionList.js +1 -1
- package/lib/typescript/src/components/SectionList/SectionHeader.d.ts +2 -0
- package/lib/typescript/src/components/SectionList/SectionHeader.js +3 -3
- package/lib/typescript/src/components/SectionList/SectionHeader.js.map +1 -1
- package/lib/typescript/src/components/SectionList/SectionList.d.ts +2 -0
- package/lib/typescript/src/components/SectionList/SectionList.js +2 -2
- package/lib/typescript/src/components/SectionList/SectionList.js.map +1 -1
- package/lib/typescript/tsconfig.tsbuildinfo +1 -1
- package/package.json +3 -3
- package/src/components/SectionList/SectionHeader.js +3 -3
- package/src/components/SectionList/SectionHeader.js.map +1 -1
- package/src/components/SectionList/SectionHeader.tsx +5 -3
- package/src/components/SectionList/SectionList.js +2 -2
- package/src/components/SectionList/SectionList.js.map +1 -1
- package/src/components/SectionList/SectionList.tsx +9 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
var _this=this,_jsxFileName="/home/runner/work/react-native-jigsaw/react-native-jigsaw/packages/core/src/components/SectionList/SectionHeader.tsx";import React from"react";import{View,Text}from"react-native";import{withTheme}from"@draftbit/theme";import{jsx as _jsx}from"react/jsx-runtime";var SectionHeader=function SectionHeader(_ref){var style=_ref.style,children=_ref.children;return _jsx(View,{style:[style],children:children});};export var DefaultSectionHeader=withTheme(function(_ref2){var title=_ref2.title,theme=_ref2.theme;return _jsx(Text,{testID:"default-section-header",style:{color:theme.colors.background.base,backgroundColor:theme.colors.branding.primary,fontSize:16,padding:10},children:title});});export default SectionHeader;
|
|
1
|
+
var _this=this,_jsxFileName="/home/runner/work/react-native-jigsaw/react-native-jigsaw/packages/core/src/components/SectionList/SectionHeader.tsx";import React from"react";import{View,Text}from"react-native";import{withTheme}from"@draftbit/theme";import{jsx as _jsx}from"react/jsx-runtime";var SectionHeader=function SectionHeader(_ref){var style=_ref.style,children=_ref.children;return _jsx(View,{style:[style],children:children});};export var DefaultSectionHeader=withTheme(function(_ref2){var title=_ref2.title,theme=_ref2.theme,backgroundColor=_ref2.backgroundColor,textColor=_ref2.textColor;return _jsx(Text,{testID:"default-section-header",style:{color:textColor!=null?textColor:theme.colors.background.base,backgroundColor:backgroundColor!=null?backgroundColor:theme.colors.branding.primary,fontSize:16,padding:10},children:title});});export default SectionHeader;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import _toConsumableArray from"@babel/runtime/helpers/toConsumableArray";import _objectWithoutProperties from"@babel/runtime/helpers/objectWithoutProperties";var _excluded=["sectionKey","stickyHeader","listComponent","data","renderItem","keyExtractor"];var _this=this,_jsxFileName="/home/runner/work/react-native-jigsaw/react-native-jigsaw/packages/core/src/components/SectionList/SectionList.tsx";import React from"react";import{FlashList}from"@shopify/flash-list";import SectionHeader,{DefaultSectionHeader}from"./SectionHeader";import{flattenReactFragments}from"../../utilities";import FlatList from"../FlatList";import{jsx as _jsx}from"react/jsx-runtime";export var DEFAULT_SECTION="Uncategorized";var SectionList=React.forwardRef(function(_ref,ref){var sectionKey=_ref.sectionKey,_ref$stickyHeader=_ref.stickyHeader,stickyHeader=_ref$stickyHeader===void 0?false:_ref$stickyHeader,_ref$listComponent=_ref.listComponent,listComponent=_ref$listComponent===void 0?"FlatList":_ref$listComponent,dataProp=_ref.data,renderItemProp=_ref.renderItem,keyExtractorProp=_ref.keyExtractor,rest=_objectWithoutProperties(_ref,_excluded);var data=React.useMemo(function(){return Array.isArray(dataProp)?dataProp:[];},[dataProp]);var dataWithSections=React.useMemo(function(){var result=[];var sectionDataItems={};for(var _item of data){var _item$sectionKey;var section=((_item$sectionKey=_item[sectionKey])==null?void 0:_item$sectionKey.toString())||DEFAULT_SECTION;if(sectionDataItems[section]){sectionDataItems[section].push(_item);}else{sectionDataItems[section]=[_item];}}for(var _section in sectionDataItems){result.push({type:"SECTION_ITEM",title:_section});var sectionItems=sectionDataItems[_section].map(function(item){return{type:"DATA_ITEM",data:item};});result.push.apply(result,_toConsumableArray(sectionItems));}return result;},[data,sectionKey]);var sectionHeaderIndicies=React.useMemo(function(){return stickyHeader?dataWithSections.filter(function(item){return item.type==="SECTION_ITEM";}).map(function(item){return dataWithSections.indexOf(item);}):undefined;},[dataWithSections,stickyHeader]);var extractSectionHeader=function extractSectionHeader(element){if(!element){return null;}var props=element.props||{};var children=flattenReactFragments(React.Children.toArray(props.children));if(element.type===SectionHeader){return element;}else{for(var child of children){if(child.type===SectionHeader){return child;}}}return null;};var extractRemainingNonSectionHeader=function extractRemainingNonSectionHeader(element){if(!element){return null;}var props=element.props||{};var children=flattenReactFragments(React.Children.toArray(props.children));if(element.type===SectionHeader){return null;}else{var newChildren=[];for(var child of children){if(child.type!==SectionHeader){newChildren.push(child);}}return React.cloneElement(element,Object.assign({},props,{children:newChildren}));}};var renderItem=function renderItem(_ref2){var item=_ref2.item,index=_ref2.index;switch(item.type){case"SECTION_ITEM":{var renderedItem=renderItemProp({index:index,section:item.title});return extractSectionHeader(renderedItem)||_jsx(DefaultSectionHeader,{title:item.title});}case"DATA_ITEM":{var _renderedItem=renderItemProp({item:item.data,index:index,section:item.data[sectionKey]||DEFAULT_SECTION});return extractRemainingNonSectionHeader(_renderedItem);}}};var keyExtractor=function keyExtractor(item,index){switch(item.type){case"SECTION_ITEM":{return`section_${index.toString()}`;}case"DATA_ITEM":{return(keyExtractorProp==null?void 0:keyExtractorProp(item.data,index))||index.toString();}}};switch(listComponent){case"FlatList":return _jsx(FlatList,Object.assign({ref:ref,stickyHeaderIndices:sectionHeaderIndicies},rest,{data:dataWithSections,renderItem:renderItem,keyExtractor:keyExtractor}));case"FlashList":return _jsx(FlashList,Object.assign({ref:ref,stickyHeaderIndices:sectionHeaderIndicies},rest,{data:dataWithSections,renderItem:renderItem,keyExtractor:keyExtractor}));}});export default SectionList;
|
|
1
|
+
import _toConsumableArray from"@babel/runtime/helpers/toConsumableArray";import _objectWithoutProperties from"@babel/runtime/helpers/objectWithoutProperties";var _excluded=["sectionKey","stickyHeader","listComponent","data","renderItem","keyExtractor","sectionHeaderBackgroundColor","sectionHeaderTextColor"];var _this=this,_jsxFileName="/home/runner/work/react-native-jigsaw/react-native-jigsaw/packages/core/src/components/SectionList/SectionList.tsx";import React from"react";import{FlashList}from"@shopify/flash-list";import SectionHeader,{DefaultSectionHeader}from"./SectionHeader";import{flattenReactFragments}from"../../utilities";import FlatList from"../FlatList";import{jsx as _jsx}from"react/jsx-runtime";export var DEFAULT_SECTION="Uncategorized";var SectionList=React.forwardRef(function(_ref,ref){var sectionKey=_ref.sectionKey,_ref$stickyHeader=_ref.stickyHeader,stickyHeader=_ref$stickyHeader===void 0?false:_ref$stickyHeader,_ref$listComponent=_ref.listComponent,listComponent=_ref$listComponent===void 0?"FlatList":_ref$listComponent,dataProp=_ref.data,renderItemProp=_ref.renderItem,keyExtractorProp=_ref.keyExtractor,sectionHeaderBackgroundColor=_ref.sectionHeaderBackgroundColor,sectionHeaderTextColor=_ref.sectionHeaderTextColor,rest=_objectWithoutProperties(_ref,_excluded);var data=React.useMemo(function(){return Array.isArray(dataProp)?dataProp:[];},[dataProp]);var dataWithSections=React.useMemo(function(){var result=[];var sectionDataItems={};for(var _item of data){var _item$sectionKey;var section=((_item$sectionKey=_item[sectionKey])==null?void 0:_item$sectionKey.toString())||DEFAULT_SECTION;if(sectionDataItems[section]){sectionDataItems[section].push(_item);}else{sectionDataItems[section]=[_item];}}for(var _section in sectionDataItems){result.push({type:"SECTION_ITEM",title:_section});var sectionItems=sectionDataItems[_section].map(function(item){return{type:"DATA_ITEM",data:item};});result.push.apply(result,_toConsumableArray(sectionItems));}return result;},[data,sectionKey]);var sectionHeaderIndicies=React.useMemo(function(){return stickyHeader?dataWithSections.filter(function(item){return item.type==="SECTION_ITEM";}).map(function(item){return dataWithSections.indexOf(item);}):undefined;},[dataWithSections,stickyHeader]);var extractSectionHeader=function extractSectionHeader(element){if(!element){return null;}var props=element.props||{};var children=flattenReactFragments(React.Children.toArray(props.children));if(element.type===SectionHeader){return element;}else{for(var child of children){if(child.type===SectionHeader){return child;}}}return null;};var extractRemainingNonSectionHeader=function extractRemainingNonSectionHeader(element){if(!element){return null;}var props=element.props||{};var children=flattenReactFragments(React.Children.toArray(props.children));if(element.type===SectionHeader){return null;}else{var newChildren=[];for(var child of children){if(child.type!==SectionHeader){newChildren.push(child);}}return React.cloneElement(element,Object.assign({},props,{children:newChildren}));}};var renderItem=function renderItem(_ref2){var item=_ref2.item,index=_ref2.index;switch(item.type){case"SECTION_ITEM":{var renderedItem=renderItemProp({index:index,section:item.title});return extractSectionHeader(renderedItem)||_jsx(DefaultSectionHeader,{title:item.title,backgroundColor:sectionHeaderBackgroundColor,textColor:sectionHeaderTextColor});}case"DATA_ITEM":{var _renderedItem=renderItemProp({item:item.data,index:index,section:item.data[sectionKey]||DEFAULT_SECTION});return extractRemainingNonSectionHeader(_renderedItem);}}};var keyExtractor=function keyExtractor(item,index){switch(item.type){case"SECTION_ITEM":{return`section_${index.toString()}`;}case"DATA_ITEM":{return(keyExtractorProp==null?void 0:keyExtractorProp(item.data,index))||index.toString();}}};switch(listComponent){case"FlatList":return _jsx(FlatList,Object.assign({ref:ref,stickyHeaderIndices:sectionHeaderIndicies},rest,{data:dataWithSections,renderItem:renderItem,keyExtractor:keyExtractor}));case"FlashList":return _jsx(FlashList,Object.assign({ref:ref,stickyHeaderIndices:sectionHeaderIndicies},rest,{data:dataWithSections,renderItem:renderItem,keyExtractor:keyExtractor}));}});export default SectionList;
|
|
@@ -8,6 +8,8 @@ declare const SectionHeader: React.FC<React.PropsWithChildren<SectionHeaderProps
|
|
|
8
8
|
interface DefaultSectionHeaderProps {
|
|
9
9
|
title: string;
|
|
10
10
|
theme: ReadTheme;
|
|
11
|
+
backgroundColor?: string;
|
|
12
|
+
textColor?: string;
|
|
11
13
|
}
|
|
12
14
|
export declare const DefaultSectionHeader: React.ForwardRefExoticComponent<Omit<DefaultSectionHeaderProps, "theme"> & React.RefAttributes<any>>;
|
|
13
15
|
export default SectionHeader;
|
|
@@ -2,10 +2,10 @@ import React from "react";
|
|
|
2
2
|
import { View, Text } from "react-native";
|
|
3
3
|
import { withTheme } from "@draftbit/theme";
|
|
4
4
|
const SectionHeader = ({ style, children, }) => React.createElement(View, { style: [style] }, children);
|
|
5
|
-
export const DefaultSectionHeader = withTheme(({ title, theme }) => {
|
|
5
|
+
export const DefaultSectionHeader = withTheme(({ title, theme, backgroundColor, textColor }) => {
|
|
6
6
|
return (React.createElement(Text, { testID: "default-section-header", style: {
|
|
7
|
-
color: theme.colors.background.base,
|
|
8
|
-
backgroundColor: theme.colors.branding.primary,
|
|
7
|
+
color: textColor !== null && textColor !== void 0 ? textColor : theme.colors.background.base,
|
|
8
|
+
backgroundColor: backgroundColor !== null && backgroundColor !== void 0 ? backgroundColor : theme.colors.branding.primary,
|
|
9
9
|
fontSize: 16,
|
|
10
10
|
padding: 10,
|
|
11
11
|
} }, title));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SectionHeader.js","sourceRoot":"","sources":["../../../../../src/components/SectionList/SectionHeader.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,IAAI,EAAwB,IAAI,EAAE,MAAM,cAAc,CAAC;AAChE,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAO5C,MAAM,aAAa,GAA0D,CAAC,EAC5E,KAAK,EACL,QAAQ,GACT,EAAE,EAAE,CAAC,oBAAC,IAAI,IAAC,KAAK,EAAE,CAAC,KAAK,CAAC,IAAG,QAAQ,CAAQ,CAAC;
|
|
1
|
+
{"version":3,"file":"SectionHeader.js","sourceRoot":"","sources":["../../../../../src/components/SectionList/SectionHeader.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAE,IAAI,EAAwB,IAAI,EAAE,MAAM,cAAc,CAAC;AAChE,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAO5C,MAAM,aAAa,GAA0D,CAAC,EAC5E,KAAK,EACL,QAAQ,GACT,EAAE,EAAE,CAAC,oBAAC,IAAI,IAAC,KAAK,EAAE,CAAC,KAAK,CAAC,IAAG,QAAQ,CAAQ,CAAC;AAQ9C,MAAM,CAAC,MAAM,oBAAoB,GAAG,SAAS,CAC3C,CAAC,EAAE,KAAK,EAAE,KAAK,EAAE,eAAe,EAAE,SAAS,EAA6B,EAAE,EAAE;IAC1E,OAAO,CACL,oBAAC,IAAI,IACH,MAAM,EAAC,wBAAwB,EAC/B,KAAK,EAAE;YACL,KAAK,EAAE,SAAS,aAAT,SAAS,cAAT,SAAS,GAAI,KAAK,CAAC,MAAM,CAAC,UAAU,CAAC,IAAI;YAChD,eAAe,EAAE,eAAe,aAAf,eAAe,cAAf,eAAe,GAAI,KAAK,CAAC,MAAM,CAAC,QAAQ,CAAC,OAAO;YACjE,QAAQ,EAAE,EAAE;YACZ,OAAO,EAAE,EAAE;SACZ,IAEA,KAAK,CACD,CACR,CAAC;AACJ,CAAC,CACF,CAAC;AAEF,eAAe,aAAa,CAAC"}
|
|
@@ -13,6 +13,8 @@ interface AdditionalSectionListProps<T> {
|
|
|
13
13
|
}) => JSX.Element;
|
|
14
14
|
keyExtractor?: (item: T, index: number) => string;
|
|
15
15
|
listComponent?: ListComponentType;
|
|
16
|
+
sectionHeaderBackgroundColor?: string;
|
|
17
|
+
sectionHeaderTextColor?: string;
|
|
16
18
|
}
|
|
17
19
|
export declare type FlatListSectionListProps<T> = Omit<FlatListProps<T>, "renderItem"> & AdditionalSectionListProps<T>;
|
|
18
20
|
export declare type FlashListSectionListProps<T> = Omit<FlashListProps<T>, "renderItem"> & AdditionalSectionListProps<T>;
|
|
@@ -4,7 +4,7 @@ import SectionHeader, { DefaultSectionHeader } from "./SectionHeader";
|
|
|
4
4
|
import { flattenReactFragments } from "../../utilities";
|
|
5
5
|
import FlatList from "../FlatList";
|
|
6
6
|
export const DEFAULT_SECTION = "Uncategorized";
|
|
7
|
-
const SectionList = React.forwardRef(({ sectionKey, stickyHeader = false, listComponent = "FlatList", data: dataProp, renderItem: renderItemProp, keyExtractor: keyExtractorProp, ...rest }, ref) => {
|
|
7
|
+
const SectionList = React.forwardRef(({ sectionKey, stickyHeader = false, listComponent = "FlatList", data: dataProp, renderItem: renderItemProp, keyExtractor: keyExtractorProp, sectionHeaderBackgroundColor, sectionHeaderTextColor, ...rest }, ref) => {
|
|
8
8
|
const data = React.useMemo(() => (Array.isArray(dataProp) ? dataProp : []), [dataProp]);
|
|
9
9
|
const dataWithSections = React.useMemo(() => {
|
|
10
10
|
var _a;
|
|
@@ -78,7 +78,7 @@ const SectionList = React.forwardRef(({ sectionKey, stickyHeader = false, listCo
|
|
|
78
78
|
index,
|
|
79
79
|
section: item.title,
|
|
80
80
|
});
|
|
81
|
-
return (extractSectionHeader(renderedItem) || (React.createElement(DefaultSectionHeader, { title: item.title })));
|
|
81
|
+
return (extractSectionHeader(renderedItem) || (React.createElement(DefaultSectionHeader, { title: item.title, backgroundColor: sectionHeaderBackgroundColor, textColor: sectionHeaderTextColor })));
|
|
82
82
|
}
|
|
83
83
|
case "DATA_ITEM": {
|
|
84
84
|
const renderedItem = renderItemProp({
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SectionList.js","sourceRoot":"","sources":["../../../../../src/components/SectionList/SectionList.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAkB,SAAS,EAAE,MAAM,qBAAqB,CAAC;AAGhE,OAAO,aAAa,EAAE,EAAE,oBAAoB,EAAE,MAAM,iBAAiB,CAAC;AACtE,OAAO,EAAE,qBAAqB,EAAE,MAAM,iBAAiB,CAAC;AACxD,OAAO,QAAQ,MAAM,aAAa,CAAC;
|
|
1
|
+
{"version":3,"file":"SectionList.js","sourceRoot":"","sources":["../../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