1
0
mirror of https://github.com/django/django.git synced 2025-10-23 21:59:11 +00:00

Fixed #33842 -- Used :source: role for links to repo files on GitHub.

This commit is contained in:
Ramil Yanbulatov
2022-06-30 15:08:49 +03:00
committed by Carlton Gibson
parent f3a06b06b5
commit c6290bae9d
17 changed files with 28 additions and 27 deletions

View File

@@ -2591,8 +2591,8 @@ templates for a specific app, or a specific model.
Set up your projects admin template directories
-----------------------------------------------
The admin template files are located in the ``contrib/admin/templates/admin``
directory.
The admin template files are located in the
:source:`django/contrib/admin/templates/admin` directory.
In order to override one or more of them, first create an ``admin`` directory
in your project's ``templates`` directory. This can be any of the directories
@@ -2611,7 +2611,7 @@ directory, so make sure you name the directory in all lowercase if you are
going to run your app on a case-sensitive filesystem.
To override an admin template for a specific app, copy and edit the template
from the ``django/contrib/admin/templates/admin`` directory, and save it to one
from the :source:`django/contrib/admin/templates/admin` directory, and save it to one
of the directories you just created.
For example, if we wanted to add a tool to the change list view for all the
@@ -2729,10 +2729,10 @@ override to your project:
{% endblock %}
The list of CSS variables are defined at
:file:`django/contrib/admin/static/admin/css/base.css`.
:source:`django/contrib/admin/static/admin/css/base.css`.
Dark mode variables, respecting the `prefers-color-scheme`_ media query, are
defined at :file:`django/contrib/admin/static/admin/css/dark_mode.css`. This is
defined at :source:`django/contrib/admin/static/admin/css/dark_mode.css`. This is
linked to the document in ``{% block dark-mode-vars %}``.
.. _prefers-color-scheme: https://developer.mozilla.org/en-US/docs/Web/CSS/@media/prefers-color-scheme

View File

@@ -6,7 +6,7 @@ Django aims to follow Python's :ref:`"batteries included" philosophy
<tut-batteries-included>`. It ships with a variety of extra, optional tools
that solve common web development problems.
This code lives in ``django/contrib`` in the Django distribution. This document
This code lives in :source:`django/contrib` in the Django distribution. This document
gives a rundown of the packages in ``contrib``, along with any dependencies
those packages have.

View File

@@ -2045,7 +2045,7 @@ Bash completion
---------------
If you use the Bash shell, consider installing the Django bash completion
script, which lives in ``extras/django_bash_completion`` in the Django source
script, which lives in :source:`extras/django_bash_completion` in the Django source
distribution. It enables tab-completion of ``django-admin`` and
``manage.py`` commands, so you can, for instance...

View File

@@ -101,8 +101,8 @@ This renderer uses a standalone
:class:`~django.template.backends.django.DjangoTemplates`
engine (unconnected to what you might have configured in the
:setting:`TEMPLATES` setting). It loads templates first from the built-in form
templates directory in ``django/forms/templates`` and then from the installed
apps' templates directories using the :class:`app_directories
templates directory in :source:`django/forms/templates` and then from the
installed apps' templates directories using the :class:`app_directories
<django.template.loaders.app_directories.Loader>` loader.
If you want to render templates with customizations from your
@@ -136,8 +136,8 @@ be removed at that time.
This renderer is the same as the :class:`DjangoTemplates` renderer except that
it uses a :class:`~django.template.backends.jinja2.Jinja2` backend. Templates
for the built-in widgets are located in ``django/forms/jinja2`` and installed
apps can provide templates in a ``jinja2`` directory.
for the built-in widgets are located in :source:`django/forms/jinja2` and
installed apps can provide templates in a ``jinja2`` directory.
To use this backend, all the forms and widgets in your project and its
third-party apps must have Jinja2 templates. Unless you provide your own Jinja2