Skip to content

Header buttons

alessandro contini edited this page Oct 19, 2017 · 3 revisions

Header buttons will only be displayed in the header section at the top of the home page, and they are meant to offer quick links to other parts the project, for instance: project files, downloads, tutorials, FAQs, etc...

header buttons

To edit them or their content please do the following:

  • open the lang.yml file, to be found inside the /_data/ folder, and inside the respective language folders, /en/ /it/ etc...
  • find the dictionary keys for homeheader.html include file and edit the buttons content according to your needs
# dictionary keys for homeheader.html include file
header:
  title: "MicroWebsiteTemplate"
  tagline: "This is the template for opencarecc websites"
  buttons:
    - text: "View on GitHub"
      link: "https://github.com/opencarecc/MicroWebsiteTemplate"
    - text: "Download .zip"
      link: "https://github.com/opencarecc/MicroWebsiteTemplate/zipball/master"
    - text: "Build your own!"
      link: "https://github.com/opencarecc/MicroWebsiteTemplate/wiki"

IMPORTANT:

  • please always keep the original indentation, breaking the indentation may turn into errors and the incorrect displaying, or not displaying at all, of content
  • in the case of multiple levels of indentation please be sure to keep the code structure unchanged, since the builder will loop through the list to generate some of the interface elements

For instance: In the code snippet above the builder will loop over the buttons array to generate the buttons of the banner in the homepage, where the button attributes (text and link) are defined after any of the - symbols. If you want to remove a button just delete the dictionary keys after one of the - indexes of the array and the - symbol itself.