item = $item; } public function renderContent(Renderer $renderer, EvaluationContext $context) { echo '
"With" block not implemented yet.
'; } protected function getSerializationContextForChildren(EvaluationContext $context): EvaluationContext { //Set the current item for the children so that they can (partially) resolve //their own bindings for control initialization. $innerContext = $context->createChildContext(); $optionResult = $context->resolve($this->item); if ( $optionResult->isEmpty() ) { return $innerContext; } $resolved = $optionResult->get(); $innerContext->setCurrentItem($resolved); return $innerContext; } protected function getJsUiElementType(): string { return $this->getRevisedJsUiElementType(); } protected function getRevisedJsUiElementType(): string { return 'with'; } public function serializeForRevisedJs(EvaluationContext $context): array { $result = parent::serializeForRevisedJs($context); $result['item'] = self::serializeMinimalBindingForJs($this->item, $context); return $result; } public function getAllReferencedSettings(EvaluationContext $context) { yield from self::getSettingsReferencedByBinding($this->item, $context); } }