Neoteroi / mkdocs-plugins

Plugins for MkDocs.
MIT License
116 stars 9 forks source link

Cannot seem to get timeline to function #34

Closed sseekamp0 closed 1 year ago

sseekamp0 commented 1 year ago

Hello, I'm trying to get a timeline added to my mkdocs-material site, but can't seem to quite understand how this package installs/works.

  1. I've run pip3 install neoteroi-mkdocs and that installed correctly.
  2. I added the following to my mkdocs.yml that's at the root of my site
    markdown_extensions:
    - neoteroi.timeline

    and

    extra_css:
    - css/neoteroi-mkdocs.css

However, I consistently get WARNING - [12:39:06] "GET /docs/css/neoteroi-mkdocs.css HTTP/1.1" code 404 in my console output.

Questions:

  1. I did notice in the introduction page of the documentation site you indicated that we had to download the CSS? Is that required or serve up timeline? or is it downloaded with the pip install?
  2. Can I copy the CSS output instead of downloading a file?
  3. Do you have an example site of serving up the timeline? Couldn't find your mkdocs example site in this repo.
RobertoPrevato commented 1 year ago

Hi @sseekamp0 Yes, it's necessary to download the CSS file and include it in your site folder. Distributing it with pip wouldn't work because it would get placed into your Python virtual environment, or Python global installation folder (depending on whether you use virtual environments or not). The MkDocs development server does not serve files in your dependencies folder.

Couldn't find your mkdocs example site in this repo.

The documentation site is linked in the README of this repo, there are 8 links at the very top:

image

scydas commented 1 year ago

image I have the same problem. Is the css file described in the documentation the file I marked up? File name is different

RobertoPrevato commented 1 year ago

Hi @scydas Yes, as described here https://www.neoteroi.dev/mkdocs-plugins/intro/#how-to-obtain-css-files

You can download the CSS from the assets of the last successful release (link valid at the time of this writing), or from the published artifacts of the last successful GitHub Workflows run in GitHub.

From the release:

image

From the last action (today here):

image

In the first case, rename the CSS file as desired. In the second case, the file has already name "neoteroi-mkdocs.css", in only need to be unzipped.

scydas commented 1 year ago

@RobertoPrevato Thank you very much for your reply, I have a question. oad only supports swagger V3? not V2

RobertoPrevato commented 1 year ago

@RobertoPrevato Thank you very much for your reply, I have a question. oad only supports swagger V3? not V2

You're welcome 😄. Yes, my libraries to handle OpenAPI Specification only support V3. Because I wouldn't have the time to support also version 2. However, I generally structure my code to support adding support for V2 eventually in the future (or V4, when it will exist).