src/Metabox/Resources/Transformers/MetaboxTransformer.php
public function includeFields(MetaboxInterface $metabox)
    {
        return $this->collection(
            $metabox->repository()->all(),
            function (FieldTypeInterface $field) {
                $field = $field->setResourceTransformerFactory(new Factory());
                $transformer = $field->getResourceTransformerFactory()->make($field->getResourceTransformer());

                /** @var FieldTransformer $transformer */
                return $transformer->transform($field);
            }
        );
    }
public function includeFields(MetaboxInterface $metabox)
    {
        return $this->collection(
            $metabox->repository()->all(),
            function (FieldTypeInterface $field) {
                $field = $field->setResourceTransformerFactory(new Factory());
                $transformer = $field->getResourceTransformerFactory()->make($field->getResourceTransformer());

                /** @var FieldTransformer $transformer */
                return $transformer->transform($field);
            }
        );
    }
public function includeFields ( MetaboxInterface $ metabox ) { return $ this -> collection ( $ metabox -> repository ( ) -> all ( ) , function ( FieldTypeInterface $ field ) { $ field = $ field -> setResourceTransformerFactory ( new Factory ( ) ) ; $ transformer = $ field -> getResourceTransformerFactory ( ) -> make ( $ field -> getResourceTransformer ( ) ) ; /** @var FieldTransformer $transformer */ return $ transformer -> transform ( $ field ) ; } ) ; }
Return the metabox fields.

@param MetaboxInterface $metabox

@return \League\Fractal\Resource\Collection
Return the metabox fields .