MCPcopy Create free account
hub / github.com/callstack/react-native-paper / CellContent

Function CellContent

src/components/DataTable/DataTableCell.tsx:93–116  ·  view source on GitHub ↗
({
  children,
  textStyle,
  maxFontSizeMultiplier,
  testID,
}: Pick<
  Props,
  'children' | 'textStyle' | 'testID' | 'maxFontSizeMultiplier'
>)

Source from the content-addressed store, hash-verified

91};
92
93const CellContent = ({
94 children,
95 textStyle,
96 maxFontSizeMultiplier,
97 testID,
98}: Pick<
99 Props,
100 'children' | 'textStyle' | 'testID' | 'maxFontSizeMultiplier'
101>) => {
102 if (React.isValidElement(children)) {
103 return children;
104 }
105
106 return (
107 <Text
108 style={textStyle}
109 numberOfLines={1}
110 maxFontSizeMultiplier={maxFontSizeMultiplier}
111 testID={`${testID}-text-container`}
112 >
113 {children}
114 </Text>
115 );
116};
117
118DataTableCell.displayName = 'DataTable.Cell';
119

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…