Commit graph

14 commits

Author SHA1 Message Date
Emil Stenström
edf3885632 Replace all instances of component_block with component. Remove duplicate tests. 2024-02-21 22:38:06 +01:00
Emil Stenström
48fe8171b4 Reformat lines that became too long. And enforce 119 line length. 2024-02-21 22:38:06 +01:00
Emil Stenström
ef6a082238 Remove component tag in favour of component_block. 2024-02-21 22:38:06 +01:00
Dylan Castillo
560b721523 Change context behavior setting to enum 2024-01-15 21:58:42 +01:00
Dylan Castillo
4da76c178b Add setting to isolate components' context by default 2024-01-15 21:58:42 +01:00
lemontheme
a8dfcce24e Introduce {% fill %} replacing 'fill' func of 'slot' tag
Partial implementation fill-tags plus update tests

Implement {% fill %} tags. Next: update tests.

Bring back support for {%slot%} blocks for bckwrd-compat and implement ambig. resolution policy

Update tests to use fill blocks. Add extra checks that raise errors

Add new tests for fill-slot nesting

Update README. Editing still required

remove unused var ctxt after flake8 complaint

fix flake8 warning about slotless f-string

[pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

Add new slot aliases in fill context. Clean up rendering logic in Component. Update docs.

fix flake8, isort, black errors

Refactor duplicated name validation

Add if_filled tag + elif_filled...else_filled...endif_filled for cond. slots

Fix mistake in do_if_filled() docstring

Upload templates for tests! D'oh

Incorporate PR feedback

Drop Literal type hint; Use isort off-on instead of skip in tests

Treat all fill,slot,if_filled,component names as variables

Reset sampleproject components

Add test for variable filled name

Update examples in docs
2023-03-14 23:40:21 +01:00
pre-commit-ci[bot]
0648ad9a93 [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
2021-09-10 11:12:26 +00:00
Real-Gecko
5fcabaa5ba Renamed get_context to get_context_data 2021-09-10 11:27:55 +02:00
Emil Stenström
5b9188cc9c Refactored Component class
# Conflicts:
#	README.md
#	pyproject.toml
2021-09-10 11:27:28 +02:00
Emil Stenström
57a5aa0f4b
Only render dependencies that are used of a specific page (#52)
Co-authored-by: rbeard0330 <@dul2k3BKW6m>
2021-03-24 22:47:48 +01:00
Emil Stenström
26f39c73f3 This is a difference between Django 3.0 and 3.1. 2021-02-15 21:22:07 +01:00
Emil Stenström
07986c5216
Caching templates to allow for dynamic template generation
Co-authored-by: rbeard0330 <@dul2k3BKW6m>
2021-02-15 21:07:14 +01:00
rbeard0330
2633c3f08f
Pass context into component tags by default, and let components disable with "only" (#20)
Co-authored-by: rbeard0330 <@dul2k3BKW6m>
2021-01-25 12:31:54 +01:00
rbeard0330
93b8a7404a
Rework of context handling (#18)
Co-authored-by: rbeard0330 <@dul2k3BKW6m>
2020-12-28 10:40:35 +01:00