8000 Dark mode: invert some images by hugovk · Pull Request #2409 · python/peps · GitHub
[go: up one dir, main page]

Skip to content

Dark mode: invert some images #2409

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Mar 11, 2022
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Use native :class: option
  • Loading branch information
AA-Turner committed Mar 11, 2022
commit 87a35b1fea57d561b845ae20ee7020fc9525252b
2 changes: 1 addition & 1 deletion pep-0001.txt
Original file line number Diff line number Diff line change
Expand Up @@ -438,8 +438,8 @@ an API can replace version 1.

The possible paths of the status of PEPs are as follows:

.. rst-class:: invert-in-dark-mode
.. image:: pep-0001-process_flow.png
:class: invert-in-dark-mode
:alt: PEP process flow diagram

While not shown in the diagram, "Accepted" PEPs may technically move to
Expand Down
2 changes: 1 addition & 1 deletion pep-0458.txt
Original file line number Diff line number Diff line change
Expand Up @@ -488,8 +488,8 @@ also indicates the types of keys used to sign each role, and which roles are
trusted to sign for files available on PyPI. The next two sections cover the
details of signing repository files and the types of keys used for each role.

.. rst-class:: invert-in-dark-mode
.. image:: pep-0458-1.png
:class: invert-in-dark-mode

Figure 1: An overview of the role metadata available on PyPI.

Expand Down
2 changes: 1 addition & 1 deletion pep-0480.txt
Original file line number Diff line number Diff line change
Expand Up @@ -206,8 +206,8 @@ projects are signed by an online key. That is, an attacker is able to corrupt
packages in the minimum security model, but not in the maximum model, without
also compromising a developer's key.

.. rst-class:: invert-in-dark-mode
.. image:: pep-0480-1.png
:class: invert-in-dark-mode

Figure 1: An overview of the metadata layout in the maximum security model.
The maximum security model supports continuous delivery and survivable key
Expand Down
4 changes: 2 additions & 2 deletions pep-0495.txt
Original file line number Diff line number Diff line change
Expand Up @@ -384,10 +384,10 @@ smaller after any transition that creates a fold. The values returned
by ``tzname()`` and ``dst()`` may or may not depend on the value of
the ``fold`` attribute depending on the kind of the transition.

.. rst-class:: invert-in-dark-mode
.. image:: pep-0495-fold-2.png
:align: center
:width: 60%
:class: invert-in-dark-mode

The sketch above illustrates the relationship between the UTC and
local time around a fall-back transition. The zig-zag line is a graph
Expand All @@ -410,10 +410,10 @@ local time that falls in a gap, the rules in effect before the
transition should be used if ``fold=0``. Otherwise, the rules in
effect after the transition should be used.

.. rst-class:: invert-in-dark-mode
.. image:: pep-0495-gap.png
:align: center
:width: 60%
:class: invert-in-dark-mode

The sketch above illustrates the relationship between the UTC and
local time around a spring-forward transition. At the transition, the
Expand Down
2 changes: 1 addition & 1 deletion pep-0525.txt
Original file line number Diff line number Diff line change
Expand Up @@ -386,10 +386,10 @@ reference implementation introduces three new objects:
methods). Essentially, they control how asynchronous generators are
iterated:

.. rst-class:: invert-in-dark-mode
.. image:: pep-0525-1.png
:align: center
:width: 80%
:class: invert-in-dark-mode


PyAsyncGenASend and PyAsyncGenAThrow
Expand Down
2 changes: 1 addition & 1 deletion pep-0532.txt
Original file line number Diff line number Diff line change
Expand Up @@ -680,8 +680,8 @@ The following diagram illustrates the core concepts behind the circuit
breaking protocol (although it glosses over the technical detail of looking
up the special methods via the type rather than the instance):

.. rst-class:: invert-in-dark-mode
.. image:: pep-0532/circuit-breaking-protocol.svg
:class: invert-in-dark-mode
:alt: diagram of circuit breaking protocol applied to ternary expression

We will work through the following expression::
Expand Down
4 changes: 2 additions & 2 deletions pep-0550.rst
Original file line number Diff line number Diff line change
Expand Up @@ -1565,10 +1565,10 @@ coroutine.
Appendix: HAMT Performance Analysis
===================================

.. rst-class:: invert-in-dark-mode
.. figure:: pep-0550-hamt_vs_dict-v2.png
:align: center
:width: 100%
:class: invert-in-dark-mode

Figure 1. Benchmark code can be found here: [9]_.

Expand All @@ -1579,10 +1579,10 @@ The above chart demonstrates that:

* ``dict.copy()`` becomes very slow around 100 items.

.. rst-class:: invert-in-dark-mode
.. figure:: pep-0550-lookup_hamt.png
:align: center
:width: 100%
:class: invert-in-dark-mode

Figure 2. Benchmark code can be found here: [10]_.

Expand Down
4 changes: 2 additions & 2 deletions pep-0603.rst
Original file line number Diff line number Diff line change
Expand Up @@ -295,10 +295,10 @@ fairly detailed description of the algorithm as well.
Performance
-----------

.. rst-class:: invert-in-dark-mode
.. figure:: pep-0603-hamt_vs_dict.png
:align: center
:width: 100%
:class: invert-in-dark-mode

Figure 1. Benchmark code can be found here: [3]_.

Expand All @@ -310,10 +310,10 @@ The above chart demonstrates that:
* ``dict.copy()`` becomes less efficient when using around
100-200 items.

.. rst-class:: invert-in-dark-mode
.. figure:: pep-0603-lookup_hamt.png
:align: center
:width: 100%
:class: invert-in-dark-mode

Figure 2. Benchmark code can be found here: [4]_.

Expand Down
2 changes: 1 addition & 1 deletion pep-3147.txt
Original file line number Diff line number Diff line change
Expand Up @@ -316,9 +316,9 @@ Flow chart

Here is a flow chart describing how modules are loaded:

.. rst-class:: invert-in-dark-mode
.. image:: pep-3147-1.png
:scale: 75
:class: invert-in-dark-mode


Alternative Python implementations
Expand Down
2 changes: 1 addition & 1 deletion pep_sphinx_extensions/pep_theme/static/dark.css
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,6 @@
--colour-warning: #900;
}

.invert-in-dark-mode {
img.invert-in-dark-mode {
filter: invert(1);
}
0