rich-struct 0.4.2__tar.gz → 0.4.3__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.
- {rich_struct-0.4.2 → rich_struct-0.4.3}/PKG-INFO +1 -1
- {rich_struct-0.4.2 → rich_struct-0.4.3}/pyproject.toml +1 -1
- {rich_struct-0.4.2 → rich_struct-0.4.3}/rich_struct/themes.py +3 -3
- {rich_struct-0.4.2 → rich_struct-0.4.3}/tests/test_print.py +2 -2
- {rich_struct-0.4.2 → rich_struct-0.4.3}/.gitignore +0 -0
- {rich_struct-0.4.2 → rich_struct-0.4.3}/LICENSE +0 -0
- {rich_struct-0.4.2 → rich_struct-0.4.3}/README.md +0 -0
- {rich_struct-0.4.2 → rich_struct-0.4.3}/rich_struct/__init__.py +0 -0
- {rich_struct-0.4.2 → rich_struct-0.4.3}/rich_struct/py.typed +0 -0
- {rich_struct-0.4.2 → rich_struct-0.4.3}/rich_struct/tables.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.5
|
|
2
2
|
Name: rich-struct
|
|
3
|
-
Version: 0.4.
|
|
3
|
+
Version: 0.4.3
|
|
4
4
|
Summary: rich.print with 25 themes (Midnight Slate, Tokyo Night, Dracula, Nord, ...) and print_md/html/json/yaml/xml/obj/table/list helpers
|
|
5
5
|
Project-URL: Homepage, https://github.com/wiertmir/rich-struct
|
|
6
6
|
Project-URL: Issues, https://github.com/wiertmir/rich-struct/issues
|
|
@@ -4,7 +4,7 @@ build-backend = "hatchling.build"
|
|
|
4
4
|
|
|
5
5
|
[project]
|
|
6
6
|
name = "rich-struct"
|
|
7
|
-
version = "0.4.
|
|
7
|
+
version = "0.4.3"
|
|
8
8
|
description = "rich.print with 25 themes (Midnight Slate, Tokyo Night, Dracula, Nord, ...) and print_md/html/json/yaml/xml/obj/table/list helpers"
|
|
9
9
|
readme = "README.md"
|
|
10
10
|
requires-python = ">=3.9"
|
|
@@ -151,9 +151,9 @@ _OVERRIDES = {
|
|
|
151
151
|
"json.null": "italic #a78bfa",
|
|
152
152
|
# objects (print_obj)
|
|
153
153
|
"repr.background": "on #0f172a",
|
|
154
|
-
"repr.attrib_name": "#
|
|
155
|
-
"repr.key": "#
|
|
156
|
-
"repr.call": "bold #
|
|
154
|
+
"repr.attrib_name": "#a3c2f2",
|
|
155
|
+
"repr.key": "#a3c2f2",
|
|
156
|
+
"repr.call": "bold #79c0ff",
|
|
157
157
|
"repr.str": "#a3e635",
|
|
158
158
|
"repr.number": "#fbbf24",
|
|
159
159
|
"repr.number_complex": "#fbbf24",
|
|
@@ -126,11 +126,11 @@ def test_objects_get_their_own_colours_and_background_in_midnight_slate(monkeypa
|
|
|
126
126
|
page_bg, object_bg = "48;2;11;19;32", "48;2;15;23;42" # #0b1320, #0f172a
|
|
127
127
|
out = render(rt.print_obj, Point(1, "y"))
|
|
128
128
|
assert object_bg in out and page_bg not in out
|
|
129
|
-
assert "38;2;
|
|
129
|
+
assert "38;2;163;194;242" in out and "1;38;2;121;192;255" in out # property #a3c2f2 (as JSON keys), class bold #79c0ff (as GitHub Dark)
|
|
130
130
|
assert object_bg not in render(rt.print_md, "text") and object_bg not in render(rt.print_obj, 1, background=False)
|
|
131
131
|
assert "48;2;46;52;64" in render(rt.print_obj, 1, theme="Nord") # other themes: the page background
|
|
132
132
|
# dict keys take the property colour here, and stay string-coloured in themes without repr.key
|
|
133
|
-
prop, slate_str, nord_str = "38;2;
|
|
133
|
+
prop, slate_str, nord_str = "38;2;163;194;242", "38;2;163;230;53", "38;2;163;190;140"
|
|
134
134
|
out = render(rt.print_obj, {"key": "value"})
|
|
135
135
|
assert f"{prop};48;2;15;23;42m'key'" in out and f"{slate_str};48;2;15;23;42m'value'" in out
|
|
136
136
|
assert f"{nord_str};48;2;46;52;64m'key'" in render(rt.print_obj, {"key": "value"}, theme="Nord")
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|