From 2b9c5579d244487f213f529c8117722794ee3974 Mon Sep 17 00:00:00 2001 From: Armaan Bhojwani Date: Fri, 8 Jan 2021 22:57:02 -0500 Subject: [PATCH] Specify fill="none" for transparency in SVG --- svg2img | 18 +++++++++--------- template/circle.svg | 2 +- template/square.svg | 2 +- 3 files changed, 11 insertions(+), 11 deletions(-) diff --git a/svg2img b/svg2img index 9c1eba6..e632960 100755 --- a/svg2img +++ b/svg2img @@ -11,39 +11,39 @@ if [[ (! -d "square/svg" || ! -d "circle/svg") || (${1} == "svg") ]]; then mkdir -pv ${SHAPE}/svg sed -e 's/STROKE/stroke="#00ffbf" /g' \ - -e 's/FILL/ fill="#212121"/g' template/${SHAPE}.svg \ + -e 's/FILL/#212121/g' template/${SHAPE}.svg \ > ${SHAPE}/svg/logo-${SHAPE}-color-dark.svg sed -e 's/STROKE/stroke="#00ffbf" /g' \ - -e 's/FILL/ fill="#fff"/g' template/${SHAPE}.svg \ + -e 's/FILL/#fff/g' template/${SHAPE}.svg \ > ${SHAPE}/svg/logo-${SHAPE}-color-white.svg sed -e 's/STROKE/stroke="#00ffbf" /g' \ - -e 's/FILL//g' template/${SHAPE}.svg \ + -e 's/FILL/none/g' template/${SHAPE}.svg \ > ${SHAPE}/svg/logo-${SHAPE}-color-trans.svg sed -e 's/STROKE/stroke="#212121" /g' \ - -e 's/FILL/ fill="#00ffbf"/g' template/${SHAPE}.svg \ + -e 's/FILL/#00ffbf/g' template/${SHAPE}.svg \ > ${SHAPE}/svg/logo-${SHAPE}-dark-color.svg sed -e 's/STROKE/stroke="#212121" /g' \ - -e 's/FILL/ fill="#fff"/g' template/${SHAPE}.svg \ + -e 's/FILL/#fff/g' template/${SHAPE}.svg \ > ${SHAPE}/svg/logo-${SHAPE}-dark-white.svg sed -e 's/STROKE/stroke="#212121" /g' \ - -e 's/FILL//g' template/${SHAPE}.svg \ + -e 's/FILL/none/g' template/${SHAPE}.svg \ > ${SHAPE}/svg/logo-${SHAPE}-dark-trans.svg sed -e 's/STROKE/stroke="#fff" /g' \ - -e 's/FILL/ fill="#00ffbf"/g' template/${SHAPE}.svg \ + -e 's/FILL/#00ffbf/g' template/${SHAPE}.svg \ > ${SHAPE}/svg/logo-${SHAPE}-white-color.svg sed -e 's/STROKE/stroke="#fff" /g' \ - -e 's/FILL/ fill="#212121"/g' template/${SHAPE}.svg \ + -e 's/FILL/#212121/g' template/${SHAPE}.svg \ > ${SHAPE}/svg/logo-${SHAPE}-white-dark.svg sed -e 's/STROKE/stroke="#fff" /g' \ - -e 's/FILL//g' template/${SHAPE}.svg \ + -e 's/FILL/none/g' template/${SHAPE}.svg \ > ${SHAPE}/svg/logo-${SHAPE}-white-trans.svg done fi diff --git a/template/circle.svg b/template/circle.svg index 7eaab61..5210884 100644 --- a/template/circle.svg +++ b/template/circle.svg @@ -1,6 +1,6 @@ - + diff --git a/template/square.svg b/template/square.svg index 2f254cb..8241d93 100644 --- a/template/square.svg +++ b/template/square.svg @@ -1,6 +1,6 @@ - + -- 2.39.2