diff --git a/src/wp2hugo/internal/hugogenerator/hugo_custom_css.go b/src/wp2hugo/internal/hugogenerator/hugo_custom_css.go deleted file mode 100644 index c872628..0000000 --- a/src/wp2hugo/internal/hugogenerator/hugo_custom_css.go +++ /dev/null @@ -1,40 +0,0 @@ -package hugogenerator - -import "path/filepath" - -const _customCSS = ` -.gallery { - display: flex; - flex-wrap: wrap; -} -.gallery figure, -.gallery figure img { - text-align: center; -} -.gallery figure img { - margin: 1rem auto; -} -.gallery-cols-1 figure { - width: 100%; -} -.gallery-cols-2 figure { - width: 50%; -} -.gallery-cols-3 figure { - width: 33.3333333333%; -} -.gallery-cols-4 figure { - width: 25%; -} -.gallery-cols-5 figure { - width: 25%; -} -.gallery-cols-6 figure { - width: 16.666666666%; -} -` - -func setupCSS(siteDir string) error { - err := appendFile(filepath.Join(siteDir, _outputCssFile), _customCSS) - return err -} diff --git a/src/wp2hugo/internal/hugogenerator/hugo_custom_font.go b/src/wp2hugo/internal/hugogenerator/hugo_custom_font.go index 3fbbcbd..cc89ca9 100644 --- a/src/wp2hugo/internal/hugogenerator/hugo_custom_font.go +++ b/src/wp2hugo/internal/hugogenerator/hugo_custom_font.go @@ -24,6 +24,36 @@ body { word-break: break-word; background: var(--theme); } + +.gallery { + display: flex; + flex-wrap: wrap; +} +.gallery figure, +.gallery figure img { + text-align: center; +} +.gallery figure img { + margin: 1rem auto; +} +.gallery-cols-1 figure { + width: 100%; +} +.gallery-cols-2 figure { + width: 50%; +} +.gallery-cols-3 figure { + width: 33.3333333333%; +} +.gallery-cols-4 figure { + width: 25%; +} +.gallery-cols-5 figure { + width: 25%; +} +.gallery-cols-6 figure { + width: 16.666666666%; +} ` const _outputCssFile = "themes/PaperMod/assets/css/extended/blank.css" diff --git a/src/wp2hugo/internal/hugogenerator/hugo_gen_setup.go b/src/wp2hugo/internal/hugogenerator/hugo_gen_setup.go index 4942060..2527c3a 100644 --- a/src/wp2hugo/internal/hugogenerator/hugo_gen_setup.go +++ b/src/wp2hugo/internal/hugogenerator/hugo_gen_setup.go @@ -104,9 +104,6 @@ func (g Generator) Generate() error { if err = setupFont(*siteDir, g.fontName); err != nil { return err } - if err = setupCSS(*siteDir); err != nil { - return err - } if err = WriteCustomShortCodes(*siteDir); err != nil { return err }