diff --git a/docs/guides/app.md b/docs/guides/app.md index 29bac93b5..629cf06db 100644 --- a/docs/guides/app.md +++ b/docs/guides/app.md @@ -27,6 +27,10 @@ app.bindaddr(192.168.1.2) !!! note The `run()` method is blocking. To run a Crow app asynchronously `run_async()` should be used instead. + +!!! warning + + When using `run_async()`, make sure to use a variable to save the function's output (such as `#!cpp auto _a = app.run_async()`). Otherwise the app will run synchronously.

diff --git a/docs/guides/routes.md b/docs/guides/routes.md index 0f86e20fd..54241a76f 100644 --- a/docs/guides/routes.md +++ b/docs/guides/routes.md @@ -25,7 +25,8 @@ You can change the HTTP methods the route uses from just the default `GET` by us !!! note - Crow handles `HEAD` and `OPTIONS` methods automatically. So adding those to your handler has no effect. + Crow handles `OPTIONS` method automatically. The `HEAD` method is handled automatically unless defined in a route. + Adding `OPTIONS` to a route's methods has no effect. Crow defines the following methods: ``` diff --git a/docs/stylesheets/colors.css b/docs/stylesheets/colors.css index fd3a5ad07..102d93b1b 100644 --- a/docs/stylesheets/colors.css +++ b/docs/stylesheets/colors.css @@ -13,6 +13,7 @@ --home-border-color: #00000080; --home-shadow-color: #00000040; --home-image-border: linear-gradient(90deg, rgba(0,0,0,0) 0%, rgb(0, 0, 0) 50%, rgba(0,0,0,0) 100%); + --md-default-tag-bg-color: var(--md-default-bg-color); } @@ -28,25 +29,22 @@ --md-default-fg-color--lightest: rgba(255, 255, 255, 0.07); --md-typeset-a-color: var(--md-accent-fg-color) !important; --md-default-bg-color: #1a2124; - --md-code-bg-color: #2f2f2f !important; + --md-code-bg-color: #101010 !important; --md-code-hl-comment-color: var(--md-code-fg-color) !important; --md-code-hl-generic-color: var(--md-code-fg-color) !important; --md-code-hl-variable-color: var(--md-code-fg-color) !important; --md-code-hl-operator-color: var(--md-code-fg-color) !important; - --md-code-fg-color: #adadad !important; + --md-code-fg-color: #cfcfcf !important; --md-code-hl-punctuation-color: #adadad !important; --home-border-color: #ffffff20; --home-shadow-color: #00000040; --home-image-border: linear-gradient(90deg, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.3) 50%, rgba(255, 255, 255, 0) 100%); --md-admonition-bg-color: #272a2b; --md-code-hl-color: rgba(255, 255, 0, 0.18); + --md-default-tag-bg-color: var(--md-default-fg-color); } -.md-typeset code { - padding: 0.2rem; -} - .md-typeset .md-button { color: var(--md-default-fg-color--light); border-radius: 0.5rem; diff --git a/docs/stylesheets/extra.css b/docs/stylesheets/extra.css index 24f4925db..5f8c7549d 100644 --- a/docs/stylesheets/extra.css +++ b/docs/stylesheets/extra.css @@ -1,16 +1,21 @@ .md-header__source { - margin-left: 0px; - width: autho; - min-width: 9.6rem; + margin-left: 0px; + width: autho; + min-width: 9.6rem; } + +.md-typeset code { + border-radius: .25rem !important; +} + .code { - border-radius: 5px; + border-radius: .25rem !important; } .tag { background-color: var(--md-primary-fg-color); - color: var(--md-default-bg-color); + color: var(--md-default-tag-bg-color); border-radius: 50px; padding-left: 0.15em; padding-right: 0.35em; @@ -20,12 +25,12 @@ .tag a { - color: var(--md-default-bg-color); + color: var(--md-default-tag-bg-color); } .tag a:hover { - color: var(--md-default-bg-color); + color: var(--md-default-tag-bg-color); } .md-typeset :is(.emojione, .twemoji, .gemoji)