djhtmx 1.1.0__tar.gz → 1.1.1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {djhtmx-1.1.0 → djhtmx-1.1.1}/CHANGELOG.md +4 -0
- {djhtmx-1.1.0 → djhtmx-1.1.1}/PKG-INFO +36 -3
- {djhtmx-1.1.0 → djhtmx-1.1.1}/README.md +35 -2
- {djhtmx-1.1.0 → djhtmx-1.1.1}/src/djhtmx/__init__.py +1 -1
- {djhtmx-1.1.0 → djhtmx-1.1.1}/src/djhtmx/utils.py +1 -4
- {djhtmx-1.1.0 → djhtmx-1.1.1}/.gitignore +0 -0
- {djhtmx-1.1.0 → djhtmx-1.1.1}/LICENSE +0 -0
- {djhtmx-1.1.0 → djhtmx-1.1.1}/MANIFEST.in +0 -0
- {djhtmx-1.1.0 → djhtmx-1.1.1}/pyproject.toml +0 -0
- {djhtmx-1.1.0 → djhtmx-1.1.1}/src/djhtmx/apps.py +0 -0
- {djhtmx-1.1.0 → djhtmx-1.1.1}/src/djhtmx/command_queue.py +0 -0
- {djhtmx-1.1.0 → djhtmx-1.1.1}/src/djhtmx/commands.py +0 -0
- {djhtmx-1.1.0 → djhtmx-1.1.1}/src/djhtmx/component.py +0 -0
- {djhtmx-1.1.0 → djhtmx-1.1.1}/src/djhtmx/consumer.py +0 -0
- {djhtmx-1.1.0 → djhtmx-1.1.1}/src/djhtmx/context.py +0 -0
- {djhtmx-1.1.0 → djhtmx-1.1.1}/src/djhtmx/exceptions.py +0 -0
- {djhtmx-1.1.0 → djhtmx-1.1.1}/src/djhtmx/global_events.py +0 -0
- {djhtmx-1.1.0 → djhtmx-1.1.1}/src/djhtmx/introspection.py +0 -0
- {djhtmx-1.1.0 → djhtmx-1.1.1}/src/djhtmx/json.py +0 -0
- {djhtmx-1.1.0 → djhtmx-1.1.1}/src/djhtmx/management/commands/htmx.py +0 -0
- {djhtmx-1.1.0 → djhtmx-1.1.1}/src/djhtmx/middleware.py +0 -0
- {djhtmx-1.1.0 → djhtmx-1.1.1}/src/djhtmx/query.py +0 -0
- {djhtmx-1.1.0 → djhtmx-1.1.1}/src/djhtmx/repo.py +0 -0
- {djhtmx-1.1.0 → djhtmx-1.1.1}/src/djhtmx/settings.py +0 -0
- {djhtmx-1.1.0 → djhtmx-1.1.1}/src/djhtmx/static/htmx/2.0.4/ext/ws.js +0 -0
- {djhtmx-1.1.0 → djhtmx-1.1.1}/src/djhtmx/static/htmx/2.0.4/htmx.amd.js +0 -0
- {djhtmx-1.1.0 → djhtmx-1.1.1}/src/djhtmx/static/htmx/2.0.4/htmx.cjs.js +0 -0
- {djhtmx-1.1.0 → djhtmx-1.1.1}/src/djhtmx/static/htmx/2.0.4/htmx.esm.d.ts +0 -0
- {djhtmx-1.1.0 → djhtmx-1.1.1}/src/djhtmx/static/htmx/2.0.4/htmx.esm.js +0 -0
- {djhtmx-1.1.0 → djhtmx-1.1.1}/src/djhtmx/static/htmx/2.0.4/htmx.js +0 -0
- {djhtmx-1.1.0 → djhtmx-1.1.1}/src/djhtmx/static/htmx/2.0.4/htmx.min.js +0 -0
- {djhtmx-1.1.0 → djhtmx-1.1.1}/src/djhtmx/static/htmx/django.js +0 -0
- {djhtmx-1.1.0 → djhtmx-1.1.1}/src/djhtmx/templates/htmx/headers.html +0 -0
- {djhtmx-1.1.0 → djhtmx-1.1.1}/src/djhtmx/templates/htmx/lazy.html +0 -0
- {djhtmx-1.1.0 → djhtmx-1.1.1}/src/djhtmx/templatetags/__init__.py +0 -0
- {djhtmx-1.1.0 → djhtmx-1.1.1}/src/djhtmx/templatetags/htmx.py +0 -0
- {djhtmx-1.1.0 → djhtmx-1.1.1}/src/djhtmx/testing.py +0 -0
- {djhtmx-1.1.0 → djhtmx-1.1.1}/src/djhtmx/tracing.py +0 -0
- {djhtmx-1.1.0 → djhtmx-1.1.1}/src/djhtmx/urls.py +0 -0
|
@@ -7,6 +7,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
7
7
|
|
|
8
8
|
## [Unreleased]
|
|
9
9
|
|
|
10
|
+
## [1.1.1] - 2025-08-23
|
|
11
|
+
|
|
12
|
+
- Remove `get_model_subscriptions` `Action` annotation as string literals, as this does not reflect model relationships
|
|
13
|
+
|
|
10
14
|
## [1.1.0] - 2025-08-15
|
|
11
15
|
|
|
12
16
|
### Changed
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: djhtmx
|
|
3
|
-
Version: 1.1.
|
|
3
|
+
Version: 1.1.1
|
|
4
4
|
Summary: Interactive UI Components for Django using HTMX
|
|
5
5
|
Project-URL: Homepage, https://github.com/edelvalle/djhtmx
|
|
6
6
|
Project-URL: Documentation, https://github.com/edelvalle/djhtmx#readme
|
|
@@ -54,8 +54,19 @@ Interactive UI Components for Django using [htmx](https://htmx.org)
|
|
|
54
54
|
|
|
55
55
|
## Install
|
|
56
56
|
|
|
57
|
-
|
|
58
|
-
|
|
57
|
+
```bash
|
|
58
|
+
uv add djhtmx
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
or
|
|
62
|
+
|
|
63
|
+
```bash
|
|
64
|
+
pip install djhtmx
|
|
65
|
+
```
|
|
66
|
+
|
|
67
|
+
# Configuration
|
|
68
|
+
|
|
69
|
+
Add `djhtmx` to your `INSTALLED_APPS`.
|
|
59
70
|
|
|
60
71
|
```python
|
|
61
72
|
INSTALLED_APPS = [
|
|
@@ -63,11 +74,33 @@ INSTALLED_APPS = [
|
|
|
63
74
|
"djhtmx",
|
|
64
75
|
...
|
|
65
76
|
]
|
|
77
|
+
```
|
|
66
78
|
|
|
79
|
+
Install the Middleware as the last one of the list
|
|
80
|
+
|
|
81
|
+
```python
|
|
67
82
|
MIDDLEWARE = [
|
|
68
83
|
...,
|
|
69
84
|
"djhtmx.middleware",
|
|
70
85
|
]
|
|
86
|
+
```
|
|
87
|
+
|
|
88
|
+
Add `djhtmx.context.component_repo` to the list of context processors:
|
|
89
|
+
|
|
90
|
+
```python
|
|
91
|
+
TEMPLATES = [
|
|
92
|
+
{
|
|
93
|
+
"BACKEND": "django.template.backends.django.DjangoTemplates",
|
|
94
|
+
"DIRS": [],
|
|
95
|
+
"APP_DIRS": True,
|
|
96
|
+
"OPTIONS": {
|
|
97
|
+
"context_processors": [
|
|
98
|
+
...,
|
|
99
|
+
"djhtmx.context.component_repo",
|
|
100
|
+
],
|
|
101
|
+
},
|
|
102
|
+
},
|
|
103
|
+
]
|
|
71
104
|
|
|
72
105
|
```
|
|
73
106
|
|
|
@@ -7,8 +7,19 @@ Interactive UI Components for Django using [htmx](https://htmx.org)
|
|
|
7
7
|
|
|
8
8
|
## Install
|
|
9
9
|
|
|
10
|
-
|
|
11
|
-
|
|
10
|
+
```bash
|
|
11
|
+
uv add djhtmx
|
|
12
|
+
```
|
|
13
|
+
|
|
14
|
+
or
|
|
15
|
+
|
|
16
|
+
```bash
|
|
17
|
+
pip install djhtmx
|
|
18
|
+
```
|
|
19
|
+
|
|
20
|
+
# Configuration
|
|
21
|
+
|
|
22
|
+
Add `djhtmx` to your `INSTALLED_APPS`.
|
|
12
23
|
|
|
13
24
|
```python
|
|
14
25
|
INSTALLED_APPS = [
|
|
@@ -16,11 +27,33 @@ INSTALLED_APPS = [
|
|
|
16
27
|
"djhtmx",
|
|
17
28
|
...
|
|
18
29
|
]
|
|
30
|
+
```
|
|
19
31
|
|
|
32
|
+
Install the Middleware as the last one of the list
|
|
33
|
+
|
|
34
|
+
```python
|
|
20
35
|
MIDDLEWARE = [
|
|
21
36
|
...,
|
|
22
37
|
"djhtmx.middleware",
|
|
23
38
|
]
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
Add `djhtmx.context.component_repo` to the list of context processors:
|
|
42
|
+
|
|
43
|
+
```python
|
|
44
|
+
TEMPLATES = [
|
|
45
|
+
{
|
|
46
|
+
"BACKEND": "django.template.backends.django.DjangoTemplates",
|
|
47
|
+
"DIRS": [],
|
|
48
|
+
"APP_DIRS": True,
|
|
49
|
+
"OPTIONS": {
|
|
50
|
+
"context_processors": [
|
|
51
|
+
...,
|
|
52
|
+
"djhtmx.context.component_repo",
|
|
53
|
+
],
|
|
54
|
+
},
|
|
55
|
+
},
|
|
56
|
+
]
|
|
24
57
|
|
|
25
58
|
```
|
|
26
59
|
|
|
@@ -63,12 +63,9 @@ def get_instance_subscriptions(
|
|
|
63
63
|
return {f"{prefix}.{action}" for action in actions}
|
|
64
64
|
|
|
65
65
|
|
|
66
|
-
Action = t.Literal["created", "updated", "deleted"]
|
|
67
|
-
|
|
68
|
-
|
|
69
66
|
def get_model_subscriptions(
|
|
70
67
|
obj: type[models.Model] | models.Model,
|
|
71
|
-
actions: t.Sequence[
|
|
68
|
+
actions: t.Sequence[str | None] = (),
|
|
72
69
|
) -> set[str]:
|
|
73
70
|
"""Get the subscriptions to actions of the model.
|
|
74
71
|
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|