Skip to content

Commit

Permalink
Add docs (#13)
Browse files Browse the repository at this point in the history
  • Loading branch information
mgoulao authored Sep 13, 2022
1 parent b48e162 commit 91769fc
Show file tree
Hide file tree
Showing 351 changed files with 13,137 additions and 6 deletions.
42 changes: 42 additions & 0 deletions .github/workflows/build-docs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
name: Build Documentation website
on:
push:
branches: [main]
permissions:
contents: write
jobs:
docs:
name: Generate Website
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3

- uses: actions/setup-python@v4
with:
python-version: '3.9'

- name: Install dependencies
run: pip install -r docs/requirements.txt

- name: Install Gymnasium
run: pip install .

- name: Build
run: sphinx-build -b dirhtml -v docs _build

- name: Move 404
run: mv _build/404/index.html _build/404.html

- name: Update 404 links
run: python ./docs/scripts/move_404.py _build/404.html

- name: Remove .doctrees
run: rm -r _build/.doctrees

- name: Upload to GitHub Pages
uses: JamesIves/github-pages-deploy-action@v4
with:
folder: _build
clean-exclude: |
*.*.*/
4 changes: 2 additions & 2 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ repos:
hooks:
- id: codespell
args:
- --ignore-words-list=nd,reacher,thist,ths, ure, referenc
- --ignore-words-list=nd,reacher,thist,ths, ure, referenc,wile
- repo: https://gitlab.com/PyCQA/flake8
rev: 4.0.1
hooks:
Expand All @@ -30,7 +30,7 @@ repos:
rev: 6.1.1 # pick a git hash / tag to point to
hooks:
- id: pydocstyle
exclude: ^(gymnasium/version.py)|(gymnasium/envs/)|(tests/)
exclude: ^(gymnasium/version.py)|(gymnasium/envs/)|(tests/)|(docs/)
args:
- --source
- --explain
Expand Down
5 changes: 5 additions & 0 deletions docs/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
.DS_Store
__pycache__
.vscode/
build/
_build/
7 changes: 7 additions & 0 deletions docs/404.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
hide-toc: true
---

# 404

## Page Not Found
20 changes: 20 additions & 0 deletions docs/Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# Minimal makefile for Sphinx documentation
#

# You can set these variables from the command line, and also
# from the environment for the first two.
SPHINXOPTS ?=
SPHINXBUILD ?= sphinx-build
SOURCEDIR = .
BUILDDIR = _build

# Put it first so that "make" without argument is like "make help".
help:
@$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)

.PHONY: help Makefile

# Catch-all target: route all unknown targets to Sphinx using the new
# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS).
%: Makefile
@$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
51 changes: 51 additions & 0 deletions docs/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
# Gymnasium-docs

This folder contains the documentation for [Gymnasium](https://github.com/Farama-Foundation/gymnasium).

If you are modifying a non-environment page or an atari environment page, please PR this repo. Otherwise, follow the steps below:

## Instructions for modifying environment pages

### Editing an environment page

If you are editing an Atari environment, directly edit the Markdown file in this repository.

Otherwise, fork Gymnasium and edit the docstring in the environment's Python file. Then, pip install your Gymnasium fork and run `docs/scripts/gen_mds.py` in this repo. This will automatically generate a Markdown documentation file for the environment.

### Adding a new environment

#### Atari env

For Atari envs, add a Markdown file into `pages/environments/atari` then complete the **other steps**.

#### Non-Atari env

Ensure the environment is in Gymnasium (or your fork). Ensure that the environment's Python file has a properly formatted markdown docstring. Pip install Gymnasium (or your fork) then run `docs/scripts/gen_mds.py`. This will automatically generate an md page for the environment. Then complete the [other steps](#other-steps).

#### Other steps

- Add the corresponding gif into the `docs/_static/videos/{ENV_TYPE}` folder, where `ENV_TYPE` is the category of your new environment (e.g. mujoco). Follow snake_case naming convention. Alternatively, run `docs/scripts/gen_gifs.py`.
- Edit `docs/environments/{ENV_TYPE}/index.md`, and add the name of the file corresponding to your new environment to the `toctree`.

## Build the Documentation

Install the required packages and Gymnasium (or your fork):

```
pip install -r requirements.txt
pip install gymnasium
```

To build the documentation once:

```
cd docs
make dirhtml _build
```

To rebuild the documentation automatically every time a change is made:

```
cd docs
sphinx-autobuild -b dirhtml . _build
```
97 changes: 97 additions & 0 deletions docs/_static/css/custom.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,97 @@
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%;
}

.sidebar-logo-container {
display: flex;
height: 100px;
}

/*=======================
Envinronments grid
========================*/
.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;
}
35 changes: 35 additions & 0 deletions docs/_static/css/env_pages.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
.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;
}
Binary file added docs/_static/diagrams/AE_loop.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/_static/diagrams/AE_loop_dark.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/_static/diagrams/pendulum.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/_static/img/favicon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions docs/_static/img/github_icon.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
80 changes: 80 additions & 0 deletions docs/_static/img/gymnasium_black.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
81 changes: 81 additions & 0 deletions docs/_static/img/gymnasium_white.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/_static/videos/atari/adventure.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/_static/videos/atari/aid.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/_static/videos/atari/aid_deterministic.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/_static/videos/atari/aid_no_frameskip.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/_static/videos/atari/air_raid.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/_static/videos/atari/alien.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/_static/videos/atari/amidar.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/_static/videos/atari/ar.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/_static/videos/atari/ar_deterministic.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/_static/videos/atari/ar_no_frameskip.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/_static/videos/atari/assault.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/_static/videos/atari/asterix.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/_static/videos/atari/asteroids.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/_static/videos/atari/atlantis.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/_static/videos/atari/atlantis2.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/_static/videos/atari/ator_action.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/_static/videos/atari/backgammon.gif
Binary file added docs/_static/videos/atari/bank_heist.gif
Binary file added docs/_static/videos/atari/basic_math.gif
Binary file added docs/_static/videos/atari/battle_zone.gif
Binary file added docs/_static/videos/atari/beam_rider.gif
Binary file added docs/_static/videos/atari/berzerk.gif
Binary file added docs/_static/videos/atari/blackjack.gif
Binary file added docs/_static/videos/atari/bowling.gif
Binary file added docs/_static/videos/atari/boxing.gif
Binary file added docs/_static/videos/atari/breakout.gif
Binary file added docs/_static/videos/atari/carnival.gif
Binary file added docs/_static/videos/atari/casino.gif
Binary file added docs/_static/videos/atari/centipede.gif
Binary file added docs/_static/videos/atari/chopper_command.gif
Binary file added docs/_static/videos/atari/crazy_climber.gif
Binary file added docs/_static/videos/atari/crossbow.gif
Binary file added docs/_static/videos/atari/darkchambers.gif
Binary file added docs/_static/videos/atari/defender.gif
Binary file added docs/_static/videos/atari/demon_attack.gif
Binary file added docs/_static/videos/atari/donkey_kong.gif
Binary file added docs/_static/videos/atari/double_dunk.gif
Binary file added docs/_static/videos/atari/earthworld.gif
Binary file added docs/_static/videos/atari/elevator_action.gif
Binary file added docs/_static/videos/atari/enduro.gif
Binary file added docs/_static/videos/atari/entombed.gif
Binary file added docs/_static/videos/atari/er.gif
Binary file added docs/_static/videos/atari/er_deterministic.gif
Binary file added docs/_static/videos/atari/er_no_frameskip.gif
Binary file added docs/_static/videos/atari/erk.gif
Binary file added docs/_static/videos/atari/erk_deterministic.gif
Binary file added docs/_static/videos/atari/erk_no_frameskip.gif
Binary file added docs/_static/videos/atari/et.gif
Binary file added docs/_static/videos/atari/fishing_derby.gif
Binary file added docs/_static/videos/atari/flag_capture.gif
Binary file added docs/_static/videos/atari/freeway.gif
Binary file added docs/_static/videos/atari/frogger.gif
Binary file added docs/_static/videos/atari/frostbite.gif
Binary file added docs/_static/videos/atari/galaxian.gif
Binary file added docs/_static/videos/atari/gopher.gif
Binary file added docs/_static/videos/atari/gravitar.gif
Binary file added docs/_static/videos/atari/hangman.gif
Binary file added docs/_static/videos/atari/haunted_house.gif
Binary file added docs/_static/videos/atari/heist.gif
Binary file added docs/_static/videos/atari/heist_no_frameskip.gif
Binary file added docs/_static/videos/atari/hero.gif
Binary file added docs/_static/videos/atari/human_cannonball.gif
Binary file added docs/_static/videos/atari/ice_hockey.gif
Binary file added docs/_static/videos/atari/ing.gif
Binary file added docs/_static/videos/atari/ing_derby.gif
Binary file added docs/_static/videos/atari/ing_deterministic.gif
Binary file added docs/_static/videos/atari/ing_no_frameskip.gif
Binary file added docs/_static/videos/atari/ipede.gif
Binary file added docs/_static/videos/atari/ipede_deterministic.gif
Binary file added docs/_static/videos/atari/ipede_no_frameskip.gif
Binary file added docs/_static/videos/atari/itar.gif
Binary file added docs/_static/videos/atari/itar_deterministic.gif
Binary file added docs/_static/videos/atari/itar_no_frameskip.gif
Binary file added docs/_static/videos/atari/ival.gif
Binary file added docs/_static/videos/atari/ival_deterministic.gif
Binary file added docs/_static/videos/atari/ival_no_frameskip.gif
Binary file added docs/_static/videos/atari/jamesbond.gif
Binary file added docs/_static/videos/atari/journey_escape.gif
Binary file added docs/_static/videos/atari/kaboom.gif
Binary file added docs/_static/videos/atari/kangaroo.gif
Binary file added docs/_static/videos/atari/keystone_kapers.gif
Binary file added docs/_static/videos/atari/king_kong.gif
Binary file added docs/_static/videos/atari/klax.gif
Binary file added docs/_static/videos/atari/koolaid.gif
Binary file added docs/_static/videos/atari/kout.gif
Binary file added docs/_static/videos/atari/kout_deterministic.gif
Binary file added docs/_static/videos/atari/kout_no_frameskip.gif
Binary file added docs/_static/videos/atari/krull.gif
Binary file added docs/_static/videos/atari/kung_fu_master.gif
Binary file added docs/_static/videos/atari/laser_gates.gif
Binary file added docs/_static/videos/atari/le_dunk.gif
Binary file added docs/_static/videos/atari/le_zone.gif
Binary file added docs/_static/videos/atari/lost_luggage.gif
Binary file added docs/_static/videos/atari/mario_bros.gif
Binary file added docs/_static/videos/atari/miniature_golf.gif
Binary file added docs/_static/videos/atari/montezuma_revenge.gif
Binary file added docs/_static/videos/atari/mr_do.gif
Binary file added docs/_static/videos/atari/ms_pacman.gif
Binary file added docs/_static/videos/atari/n.gif
Binary file added docs/_static/videos/atari/n_attack.gif
Binary file added docs/_static/videos/atari/n_deterministic.gif
Binary file added docs/_static/videos/atari/n_no_frameskip.gif
Binary file added docs/_static/videos/atari/name_this_game.gif
Binary file added docs/_static/videos/atari/nder.gif
Binary file added docs/_static/videos/atari/nder_deterministic.gif
Binary file added docs/_static/videos/atari/nder_no_frameskip.gif
Binary file added docs/_static/videos/atari/ng.gif
Binary file added docs/_static/videos/atari/ng_deterministic.gif
Binary file added docs/_static/videos/atari/ng_no_frameskip.gif
Binary file added docs/_static/videos/atari/ntis.gif
Binary file added docs/_static/videos/atari/ntis_deterministic.gif
Binary file added docs/_static/videos/atari/ntis_no_frameskip.gif
Binary file added docs/_static/videos/atari/nture.gif
Binary file added docs/_static/videos/atari/nture_no_frameskip.gif
Binary file added docs/_static/videos/atari/othello.gif
Binary file added docs/_static/videos/atari/pacman.gif
Binary file added docs/_static/videos/atari/per_command.gif
Binary file added docs/_static/videos/atari/phoenix.gif
Binary file added docs/_static/videos/atari/pitfall.gif
Binary file added docs/_static/videos/atari/pitfall2.gif
Binary file added docs/_static/videos/atari/pong.gif
Binary file added docs/_static/videos/atari/pooyan.gif
Binary file added docs/_static/videos/atari/private_eye.gif
Binary file added docs/_static/videos/atari/qbert.gif
Binary file added docs/_static/videos/atari/rider.gif
Binary file added docs/_static/videos/atari/rider_deterministic.gif
Binary file added docs/_static/videos/atari/rider_no_frameskip.gif
Binary file added docs/_static/videos/atari/riverraid.gif
Binary file added docs/_static/videos/atari/rix.gif
Binary file added docs/_static/videos/atari/rix_deterministic.gif
Binary file added docs/_static/videos/atari/rix_no_frameskip.gif
Binary file added docs/_static/videos/atari/ro.gif
Binary file added docs/_static/videos/atari/ro_deterministic.gif
Binary file added docs/_static/videos/atari/ro_no_frameskip.gif
Binary file added docs/_static/videos/atari/road_runner.gif
Binary file added docs/_static/videos/atari/robotank.gif
Binary file added docs/_static/videos/atari/roids.gif
Binary file added docs/_static/videos/atari/roids_deterministic.gif
Binary file added docs/_static/videos/atari/roids_no_frameskip.gif
Binary file added docs/_static/videos/atari/seaquest.gif
Binary file added docs/_static/videos/atari/sir_lancelot.gif
Binary file added docs/_static/videos/atari/skiing.gif
Binary file added docs/_static/videos/atari/solaris.gif
Binary file added docs/_static/videos/atari/space_invaders.gif
Binary file added docs/_static/videos/atari/space_war.gif
Binary file added docs/_static/videos/atari/star_gunner.gif
Binary file added docs/_static/videos/atari/superman.gif
Binary file added docs/_static/videos/atari/surround.gif
Binary file added docs/_static/videos/atari/tbite.gif
Binary file added docs/_static/videos/atari/tbite_no_frameskip.gif
Binary file added docs/_static/videos/atari/tennis.gif
Binary file added docs/_static/videos/atari/tetris.gif
Binary file added docs/_static/videos/atari/tic_tac_toe3_d.gif
Binary file added docs/_static/videos/atari/time_pilot.gif
Binary file added docs/_static/videos/atari/trondead.gif
Binary file added docs/_static/videos/atari/turmoil.gif
Binary file added docs/_static/videos/atari/tutankham.gif
Binary file added docs/_static/videos/atari/ult.gif
Binary file added docs/_static/videos/atari/ult_deterministic.gif
Binary file added docs/_static/videos/atari/ult_no_frameskip.gif
Binary file added docs/_static/videos/atari/up_n_down.gif
Binary file added docs/_static/videos/atari/venture.gif
Binary file added docs/_static/videos/atari/video_checkers.gif
Binary file added docs/_static/videos/atari/video_pinball.gif
Binary file added docs/_static/videos/atari/videochess.gif
Binary file added docs/_static/videos/atari/videocube.gif
Binary file added docs/_static/videos/atari/way.gif
Binary file added docs/_static/videos/atari/way_deterministic.gif
Binary file added docs/_static/videos/atari/way_no_frameskip.gif
Binary file added docs/_static/videos/atari/wizard_of_wor.gif
Binary file added docs/_static/videos/atari/word_zapper.gif
Binary file added docs/_static/videos/atari/y_climber.gif
Binary file added docs/_static/videos/atari/yars_revenge.gif
Binary file added docs/_static/videos/atari/zaxxon.gif
Binary file added docs/_static/videos/box2d/bipedal_walker.gif
Binary file added docs/_static/videos/box2d/car_racing.gif
Binary file added docs/_static/videos/box2d/lunar_lander.gif
Binary file added docs/_static/videos/classic_control/acrobot.gif
Binary file added docs/_static/videos/classic_control/cart_pole.gif
Binary file added docs/_static/videos/classic_control/pendulum.gif
Binary file added docs/_static/videos/mujoco/ant.gif
Binary file added docs/_static/videos/mujoco/half_cheetah.gif
Binary file added docs/_static/videos/mujoco/hopper.gif
Binary file added docs/_static/videos/mujoco/humanoid.gif
Binary file added docs/_static/videos/mujoco/humanoid_standup.gif
Binary file added docs/_static/videos/mujoco/inverted_pendulum.gif
Binary file added docs/_static/videos/mujoco/pusher.gif
Binary file added docs/_static/videos/mujoco/reacher.gif
Binary file added docs/_static/videos/mujoco/striker.gif
Binary file added docs/_static/videos/mujoco/swimmer.gif
Binary file added docs/_static/videos/mujoco/thrower.gif
Binary file added docs/_static/videos/mujoco/walker2d.gif
Binary file added docs/_static/videos/toy_text/blackjack.gif
Binary file added docs/_static/videos/toy_text/cliff_walking.gif
Binary file added docs/_static/videos/toy_text/frozen_lake.gif
Binary file added docs/_static/videos/toy_text/taxi.gif
42 changes: 42 additions & 0 deletions docs/_templates/base.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
{% extends "furo/base.html" %}

{%- block regular_scripts -%}
{{ super() }}

<script>
(() => {
if (!localStorage.getItem("shownCookieAlert")) {
const boxElem = document.createElement("div");
boxElem.classList.add("cookie_alert");
const containerElem = document.createElement("div");
containerElem.classList.add("cookie_container");
const textElem = document.createElement("p");
textElem.innerHTML = `This page uses <a href="https://analytics.google.com/">
Google Analytics</a> to collect statistics. You can disable it by blocking
the JavaScript coming from www.google-analytics.com.`;
containerElem.appendChild(textElem);
const closeBtn = document.createElement("button");
closeBtn.innerHTML = `<?xml version="1.0" ?><svg viewBox="0 0 32 32" xmlns="http://www.w3.org/2000/svg"><defs><style>.cls-1{fill:none;stroke:#000;stroke-linecap:round;stroke-linejoin:round;stroke-width:2px;}</style></defs><title/><g id="cross"><line class="cls-1" x1="7" x2="25" y1="7" y2="25"/><line class="cls-1" x1="7" x2="25" y1="25" y2="7"/></g></svg>`
closeBtn.onclick = () => {
localStorage.setItem("shownCookieAlert", "true");
boxElem.style.display = "none";
}
containerElem.appendChild(closeBtn);
boxElem.appendChild(containerElem);
document.body.appendChild(boxElem);
}
})()

</script>

<!-- Google tag (gtag.js) -->
<script async src="https://www.googletagmanager.com/gtag/js?id=G-JGXSLW7N06"></script>
<script>
window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date());

gtag('config', 'G-JGXSLW7N06');
</script>

{%- endblock regular_scripts -%}
Loading

0 comments on commit 91769fc

Please sign in to comment.