(candidate: HintRect)
| 234 | tries.push({ ...box, x: rect.x + rect.width + 1 }); |
| 235 | } |
| 236 | const moved = (candidate: HintRect): number => |
| 237 | Math.abs(candidate.x - box.x) + Math.abs(candidate.y - box.y); |
| 238 | const free = tries.filter((candidate) => inside(candidate) && covers(candidate) === 0); |
| 239 | if (free.length === 0) { |
| 240 | return null; |