list = $list; $this->callback = $callback; } /** * 图像大小 * @param int $size * @return $this */ public function size(int $size): self { $this->size = $size; return $this; } /** * @return array */ public function render(): array { $list = []; foreach ($this->list as $vo) { $list[] = [ 'nodeName' => 'a-image', 'src' => $vo, 'width' => $this->size, 'height' => $this->size, ]; } return [ 'nodeName' => 'a-image-preview-group', 'infinite' => true, 'child' => [ 'nodeName' => 'a-space', 'child' => $list ] ]; } }