(block, fallback)
| 334 | } |
| 335 | |
| 336 | function detectChildIndent(block, fallback) { |
| 337 | const lines = block.split(/\r?\n/).reverse(); |
| 338 | for (const line of lines) { |
| 339 | const match = line.match(/^(\s*)["'][^"']+["'],?\s*$/); |
| 340 | if (match) { |
| 341 | return match[1]; |
| 342 | } |
| 343 | } |
| 344 | return fallback; |
| 345 | } |
| 346 | |
| 347 | function findFallbackChildren(block, fallbackGroup) { |
| 348 | const textPattern = new RegExp(`\\btext\\s*:\\s*["']${escapeRegExp(fallbackGroup)}["']`, "g"); |
no outgoing calls
no test coverage detected