Browse Source

Update docs to Farama sphinx theme (#254)

Manuel Goulão 2 years ago
parent
commit
270fccfd66
4 changed files with 15 additions and 95 deletions
  1. 0 53
      docs/_static/css/custom.css
  2. 0 35
      docs/_static/css/env_pages.css
  3. 11 3
      docs/conf.py
  4. 4 4
      docs/requirements.txt

+ 0 - 53
docs/_static/css/custom.css

@@ -1,53 +0,0 @@
-h1 {
-    font-size: 2.25rem;
-}
-
-h2 {
-    font-size: 1.75rem;
-}
-
-h3 {
-    font-size: 1.45rem;
-}
-
-.cookie_alert {
-    position: fixed;
-    display: flex;
-    width: 100%;
-    min-height: 70px;
-    background-color: var(--color-background-secondary);
-    color: var(--color-foreground-primary);
-    border-top: 1px solid var(--color-background-border);
-    bottom: 0;
-    left: 0;
-    z-index: 99999;
-}
-
-.cookie_container {
-    display: flex;
-    align-items: center;
-    width: 700px;
-    max-width: calc(100% - 28px);
-    margin: auto;
-}
-
-.cookie_alert p {
-    flex: 1;
-}
-
-.cookie_alert button {
-    background-color: transparent;
-    border: none;
-    width: 26px;
-    height: 26px;
-    padding: 0;
-    cursor: pointer;
-}
-
-.cookie_alert button svg .cls-1 {
-     stroke: var(--color-foreground-primary);
-}
-
-.cookie_alert button svg {
-    width: 100%;
-}

+ 0 - 35
docs/_static/css/env_pages.css

@@ -1,35 +0,0 @@
-.env-grid {
-    display: flex;
-    flex-wrap: wrap;
-    justify-content: center;
-    width: 100%;
-    box-sizing: border-box;
-}
-.env-grid__cell {
-    display: flex;
-    flex-direction: column;
-    width: 180px;
-    height: 180px;
-    padding: 10px;
-}
-.cell__image-container {
-    display: flex;
-    height: 148px;
-    justify-content: center;
-}
-.cell__image-container img {
-    max-height: 100%;
-}
-.cell__title {
-    display: flex;
-    justify-content: center;
-    text-align: center;
-    align-items: flex-end;
-    height: 32px;
-    line-height: 16px;
-}
-.more-btn {
-    width: 240px;
-    margin: 12px auto;
-    display: block;
-}

+ 11 - 3
docs/conf.py

@@ -20,6 +20,7 @@
 
 import os
 import sys
+from typing import Any, Dict
 
 project = "MiniGrid"
 copyright = "2022"
@@ -77,10 +78,17 @@ html_favicon = "_static/img/minigrid-white.png"
 html_theme_options = {
     "light_logo": "img/minigrid.png",
     "dark_logo": "img/minigrid-white.png",
+    "gtag": "",
 }
+html_context: Dict[str, Any] = {}
+html_context["conf_py_path"] = "/docs/"
+html_context["display_github"] = True
+html_context["github_user"] = "Farama-Foundation"
+html_context["github_repo"] = "Gymnasium"
+html_context["github_version"] = "master"
+html_context["slug"] = "gymnasium"
+
 html_static_path = ["_static"]
-html_css_files = [
-    "css/custom.css",
-]
+html_css_files = []
 
 notfound_urls_prefix = None

+ 4 - 4
docs/requirements.txt

@@ -1,7 +1,7 @@
-sphinx==4.2.0
+sphinx==5.2.3
+sphinx-notfound-page
 myst-parser
-furo==2022.6.21
+git+https://github.com/Farama-Foundation/Celshast#egg=furo
 moviepy
 pygame
-pygments==2.11.2
-sphinx-notfound-page
+pygments==2.11.2