tag */ class SvgSpriteIconProvider extends AbstractSvgIconProvider { /** * @throws \InvalidArgumentException */ protected function generateMarkup(Icon $icon, array $options): string { if (empty($options['sprite'])) { throw new \InvalidArgumentException('[' . $icon->getIdentifier() . '] The option "sprite" is required and must not be empty', 1603439142); } $source = $options['sprite']; return $this->generateSpriteUseMarkup($source); } /** * @throws \InvalidArgumentException */ protected function generateInlineMarkup(array $options): string { if (!empty($options['source'])) { $source = $options['source']; return $this->getInlineSvg($source); } if (empty($options['sprite'])) { throw new \InvalidArgumentException('The option "sprite" is required and must not be empty if not source SVG file is provided', 1603439146); } $source = $options['sprite']; return $this->generateSpriteUseMarkup($source); } private function generateSpriteUseMarkup(string $sprite): string { return ''; } }