AbstractXan / Mizi

A simple markdown to website generator written in C++.
https://abstractxan.xyz/site/mizi__site_generator
MIT License
42 stars 7 forks source link

highlighting text #13

Open theorashid opened 6 months ago

theorashid commented 6 months ago

Hi Priyansh,

Thanks for this project, it was great to see someone distill the 100r.co site into template.

I have a couple of issues specific to my project, but given I only minimally edited the Mizi template, others may find the same issues.

  1. I cannot highlight the text on my website. An example page. This does not seem to be an issue on either your website or my friend's website that I helped set up, but he chose a different font.
  2. For some reason, when I run ./build.sh, I get an error that File '../style.css' not found. Generating...DONE and it creates one in ../style.css (i.e. outside of the repo). Each time I have to delete the file rm ../style.css.

Source code for my site is here: https://github.com/theorashid/theorashid.github.io

Any help on these would be much appreciated. Thank you again for making this project.

Best, Theo

AbstractXan commented 1 month ago

Hey Theo,

  1. The text highlight is not showing because the highlighted colour matches your page background. Changing the following line in the style.css file should solve the issue.

    ::selection {
    background: #FBFBFB; /* Change this color */
    ...
    }
  2. It is Mizi's intended behaviour to check config.conf for the CSS file path relative to the HTML pages in ./site; if no file is found, it generates a CSS file with the file name in config. This file path is used across all the generated HTML pages. It is advisable to change the generated 'styles.css' file outside for any style changes across the generated HTML pages. If the file exists, the error File '../style.css' not found. would not be shown to the user.

I hope this will help resolve the problems. Thank you for raising the issue. It made me realise I should document the config file parameters better for clarity.

Best, Priyansh

theorashid commented 1 month ago

Hey,

  1. worked a charm, thanks
  2. I have the file structure the same as yours is set up. Relative to ./site, the CSS file is in ../style.css. However, I get File '../style.css' not found and style.css is generated at ../../style.css relative to ./site (the issue). If I edit the path in config.conf to style.css, no file is generated but the CSS is not picked up leaving only the raw html.