private function mapPlaceholders(PersistenceBlock $block, BlockDefinitionInterface $blockDefinition, ?array $locales = null): Generator
    {
        if (!$blockDefinition instanceof ContainerDefinitionInterface) {
            return;
        }

        foreach ($blockDefinition->getPlaceholders() as $placeholderIdentifier) {
            yield $placeholderIdentifier => Placeholder::fromArray(
                [
                    'identifier' => $placeholderIdentifier,
                    'blocks' => new LazyCollection(
                        function () use ($block, $placeholderIdentifier, $locales): array {
                            return array_map(
                                function (PersistenceBlock $childBlock) use ($locales): Block {
                                    return $this->mapBlock($childBlock, $locales, false);
                                },
                                $this->blockHandler->loadChildBlocks($block, $placeholderIdentifier)
                            );
                        }
                    ),
                ]
            );
        }
    }