(children: any[])
| 933 | } |
| 934 | |
| 935 | function mergeAdjacentTextLikeChildren(children: any[]): any[] { |
| 936 | const merged: any[] = []; |
| 937 | for (const child of children) { |
| 938 | if (isEmptyTextLikeChild(child)) continue; |
| 939 | |
| 940 | const previous = merged[merged.length - 1]; |
| 941 | if (previous?.type === "JSXText" && child.type === "JSXText") { |
| 942 | setTextLikeValue(previous, `${getTextLikeValue(previous) ?? ""}${getTextLikeValue(child) ?? ""}`); |
| 943 | continue; |
| 944 | } |
| 945 | |
| 946 | merged.push(child); |
| 947 | } |
| 948 | return merged; |
| 949 | } |
| 950 | |
| 951 | function trimTextLikeEdges(value: string): { core: string; hasLeadingWhitespace: boolean; hasTrailingWhitespace: boolean } { |
| 952 | return { |
no test coverage detected