Просмотр исходного кода

:octocat: removed the fill attributes from QRMarkupSVG::path() as they can be set by CSS and were unintuitive

smiley 2 лет назад
Родитель
Сommit
98d4447aa4
1 измененных файлов с 1 добавлено и 13 удалено
  1. 1 13
      src/Output/QRMarkupSVG.php

+ 1 - 13
src/Output/QRMarkupSVG.php

@@ -145,19 +145,7 @@ class QRMarkupSVG extends QRMarkup{
 	 * @see https://developer.mozilla.org/en-US/docs/Web/SVG/Element/path
 	 */
 	protected function path(string $path, int $M_TYPE):string{
-		$val = $this->getModuleValue($M_TYPE);
-		// ignore non-existent module values
-		$format = empty($val)
-			? '<path class="%1$s" d="%2$s"/>'
-			: '<path class="%1$s" fill="%3$s" fill-opacity="%4$s" d="%2$s"/>';
-
-		return sprintf(
-			$format,
-			$this->getCssClass($M_TYPE),
-			$path,
-			($val ?? ''), // value may or may not exist
-			$this->options->svgOpacity
-		);
+		return sprintf('<path class="%s" d="%s"/>', $this->getCssClass($M_TYPE), $path);
 	}
 
 	/**