| Age | Commit message (Collapse) | Author |
|
querystring template tag.
Co-authored-by: Jacob Walls <jacobtylerwalls@gmail.com>
Co-authored-by: Natalia <124304+nessita@users.noreply.github.com>
Backport of 922c4cf972e04b1ce7ecee592231106724dcfd09 from main.
|
|
registration.
Ideally, this will be reverted when an upstream solution is available for
https://github.com/python/cpython/issues/141560.
Thanks Patrick Rauscher for the report and Augusto Pontes for the
first iteration and test.
Backport of 34186e731ca20a2344b1f88fd543a854d6b13a00 from main.
|
|
|
|
warning.
|
|
|
|
Added a warning for accessing PartialTemplate.source when debugging is disabled.
Thanks Sarah Boyce for the idea.
|
|
Language.
Introduced `{% partialdef %}` and `{% partial %}` template tags to
define and render reusable named fragments within a template file.
Partials can also be accessed using the `template_name#partial_name`
syntax via `get_template()`, `render()`, `{% include %}`, and other
template-loading tools.
Adjusted `get_template()` behavior to support partial resolution, with
appropriate error handling for invalid names and edge cases. Introduced
`PartialTemplate` to encapsulate partial rendering behavior.
Includes tests and internal refactors to support partial context
binding, exception reporting, and tag validation.
Co-authored-by: Carlton Gibson <carlton@noumenal.es>
Co-authored-by: Natalia <124304+nessita@users.noreply.github.com>
Co-authored-by: Nick Pope <nick@nickpope.me.uk>
|
|
Refactored `center` template filter to match f-string behaviour,
producing consistent padding for both odd and even fillings.
Thanks Lily Acorn for the report and Natalia Bidart for the review.
Co-authored-by: Lily Acorn <code@lilyf.org>
|
|
Rewrapped long docstrings and block comments to 79 characters + newline
using script from https://github.com/medmunds/autofix-w505.
|
|
Manually reformatted some long docstrings and comments that would be
damaged by the to-be-applied autofixer script, in cases where editorial
judgment seemed necessary for style or wording changes.
|
|
|
|
This initial work adds a pair of settings to configure specific CSP
directives for enforcing or reporting policy violations, a new
`django.middleware.csp.ContentSecurityPolicyMiddleware` to apply the
appropriate headers to responses, and a context processor to support CSP
nonces in templates for safely inlining assets.
Relevant documentation has been added for the 6.0 release notes,
security overview, a new how-to page, and a dedicated reference section.
Thanks to the multiple reviewers for their precise and valuable feedback.
Co-authored-by: Natalia <124304+nessita@users.noreply.github.com>
|
|
variable names.
Regression in 5183f7c287a9a5d61ca1103b55166cda52d9c647.
Thank you to Jon Banafato and Baptiste Mispelon for the report.
|
|
|
|
|
|
template tag.
Co-authored-by: Natalia <124304+nessita@users.noreply.github.com>
|
|
path with an unknown origin.
|
|
Thanks Sarah Boyce for the report.
|
|
|
|
* Refs #35816 -- Improved test coverage of FilterExpression.
* Fixed #35816 -- Made FilterExpression parse scientific numbers.
---------
Co-authored-by: Sarah Boyce <42296566+sarahboyce@users.noreply.github.com>
|
|
https://github.com/psf/black/releases/tag/25.1.0
|
|
|
|
template tag.
Thank you to David Feeley for the report and Natalia Bidart for the review.
|
|
Co-authored-by: Brock <bsmick97@gmail.com>
|
|
|
|
Co-authored-by: Natalia <124304+nessita@users.noreply.github.com>
|
|
super objects are copyable on Python 3.14+:
https://github.com/python/cpython/commit/5ca4e34bc1aab8321911aac6d5b2b9e75ff764d8
and can no longer be used in BaseContext.__copy__().
|
|
in the template.
|
|
with __class_get_item__.
|
|
Thanks Elias Myllymäki for the report.
Co-authored-by: Shai Berger <shai@platonix.com>
|
|
|
|
|
|
that can be flattened.
|
|
Keep consistent behaviour of slice() filter between python 3.12 and prior
versions in the case of a dict passed to the filter (catch the new to python
3.12 KeyError exception).
|
|
Thanks Adam Johnson for reviews.
|
|
|
|
https://github.com/psf/black/releases/tag/24.1.0
|
|
|
|
|
|
By setting a value in the `parser.extra_data` mapping, template tags
pass additional data out of the parsing context.
Any extra data set is exposed on the template via the matching
`.extra_data` attribute.
Library authors should use a key to namespace extra data. The 'django'
namespace is reserved for internal use.
|
|
TemplatesSetting.
Regression in 439242c5943e16dd5a3a68fadac76e5e723eb323.
|
|
|
|
renderer.
|
|
Special characters lose their special meaning inside sets of characters.
"-" lose its special meaning if it's placed as the first or last
character.
Follow up to 7c6b66383da5f9a67142334cd2ed2d769739e8f1.
|
|
|
|
|
|
|
|
|
|
subclasses."
This reverts commit d7f5bfd241666c0a76e90208da1e9ef81aec44db.
Thanks Márton Salomváry for the report.
|
|
return a dict.
|