docling-core 2.43.0__py3-none-any.whl → 2.43.1__py3-none-any.whl
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.
Potentially problematic release.
This version of docling-core might be problematic. Click here for more details.
- docling_core/transforms/serializer/html.py +17 -0
- docling_core/transforms/visualizer/layout_visualizer.py +3 -1
- {docling_core-2.43.0.dist-info → docling_core-2.43.1.dist-info}/METADATA +1 -1
- {docling_core-2.43.0.dist-info → docling_core-2.43.1.dist-info}/RECORD +8 -8
- {docling_core-2.43.0.dist-info → docling_core-2.43.1.dist-info}/WHEEL +0 -0
- {docling_core-2.43.0.dist-info → docling_core-2.43.1.dist-info}/entry_points.txt +0 -0
- {docling_core-2.43.0.dist-info → docling_core-2.43.1.dist-info}/licenses/LICENSE +0 -0
- {docling_core-2.43.0.dist-info → docling_core-2.43.1.dist-info}/top_level.txt +0 -0
|
@@ -713,6 +713,23 @@ class HTMLListSerializer(BaseModel, BaseListSerializer):
|
|
|
713
713
|
**kwargs,
|
|
714
714
|
)
|
|
715
715
|
|
|
716
|
+
# Append nested list to parent list item:
|
|
717
|
+
i = 0
|
|
718
|
+
while i < len(parts):
|
|
719
|
+
prt = parts[i]
|
|
720
|
+
if prt.text.startswith(("<ul>", "<ol>")):
|
|
721
|
+
for j in range(i - 1, -1, -1):
|
|
722
|
+
if parts[j].text.startswith(("<li>", "<li ")) and parts[
|
|
723
|
+
j
|
|
724
|
+
].text.endswith("</li>"):
|
|
725
|
+
before, _, _ = parts[j].text.rpartition("</li>")
|
|
726
|
+
parts[j].text = f"{before}\n{prt.text}\n</li>"
|
|
727
|
+
break
|
|
728
|
+
if j > -1:
|
|
729
|
+
parts.pop(i)
|
|
730
|
+
else:
|
|
731
|
+
i += 1
|
|
732
|
+
|
|
716
733
|
# Add all child parts
|
|
717
734
|
text_res = "\n".join(
|
|
718
735
|
[
|
|
@@ -148,7 +148,9 @@ class LayoutVisualizer(BaseVisualizer):
|
|
|
148
148
|
prev_image = None
|
|
149
149
|
prev_page_nr = None
|
|
150
150
|
for idx, (elem, _) in enumerate(
|
|
151
|
-
doc.iterate_items(
|
|
151
|
+
doc.iterate_items(
|
|
152
|
+
included_content_layers=included_content_layers, traverse_pictures=True
|
|
153
|
+
)
|
|
152
154
|
):
|
|
153
155
|
if not isinstance(elem, DocItem):
|
|
154
156
|
continue
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: docling-core
|
|
3
|
-
Version: 2.43.
|
|
3
|
+
Version: 2.43.1
|
|
4
4
|
Summary: A python library to define and validate data types in Docling.
|
|
5
5
|
Author-email: Cesar Berrospi Ramis <ceb@zurich.ibm.com>, Panos Vagenas <pva@zurich.ibm.com>, Michele Dolfi <dol@zurich.ibm.com>, Christoph Auer <cau@zurich.ibm.com>, Peter Staar <taa@zurich.ibm.com>
|
|
6
6
|
Maintainer-email: Panos Vagenas <pva@zurich.ibm.com>, Michele Dolfi <dol@zurich.ibm.com>, Christoph Auer <cau@zurich.ibm.com>, Peter Staar <taa@zurich.ibm.com>, Cesar Berrospi Ramis <ceb@zurich.ibm.com>
|
|
@@ -30,12 +30,12 @@ docling_core/transforms/serializer/__init__.py,sha256=CECQlMoCDUxkg4RAUdC3itA3I3
|
|
|
30
30
|
docling_core/transforms/serializer/base.py,sha256=TI8Epj7gyxdTet9j-Rs4o5U09gfACfAIVoirlschviM,7266
|
|
31
31
|
docling_core/transforms/serializer/common.py,sha256=0TNEGoA_rJ-qkVYp-X8SMUr3jTrbf6TRzPzwufYh5JM,19114
|
|
32
32
|
docling_core/transforms/serializer/doctags.py,sha256=TD0yAm1qSVy-GsE6svpUAI-Yqjcf2rrTZ3ac9YU3gbE,19858
|
|
33
|
-
docling_core/transforms/serializer/html.py,sha256=
|
|
33
|
+
docling_core/transforms/serializer/html.py,sha256=JswD_tQiQgmOJ29erkn6qEJX0F2N7zaoxJ9TCCSQPLE,39635
|
|
34
34
|
docling_core/transforms/serializer/html_styles.py,sha256=-jBwS4EU7yfKoz0GSoxhwx90OmIKieO6TwPw57IuxcA,4692
|
|
35
35
|
docling_core/transforms/serializer/markdown.py,sha256=VwonuAkuOPmQM7ibDIGvQBHOqhTcTJ_t187fLQQiNPo,23951
|
|
36
36
|
docling_core/transforms/visualizer/__init__.py,sha256=gUfF25yiJ_KO46ZIUNqZQOZGy2PLx6gnnr6AZYxKHXI,35
|
|
37
37
|
docling_core/transforms/visualizer/base.py,sha256=aEF7b3rHq6DVdX8zDYEPoq55BHDYe4Hh_97lBdcW4lY,555
|
|
38
|
-
docling_core/transforms/visualizer/layout_visualizer.py,sha256=
|
|
38
|
+
docling_core/transforms/visualizer/layout_visualizer.py,sha256=k93ORWxA1oTDNkNxyqlzqB2aunxBX3aq4e4ihdJzRkE,8089
|
|
39
39
|
docling_core/transforms/visualizer/reading_order_visualizer.py,sha256=muqmaxOBao39X3Dut0934NAjU3I4v3JN5VzzdjmoGRY,7776
|
|
40
40
|
docling_core/transforms/visualizer/table_visualizer.py,sha256=iJPjk-XQSSCH3oujcjPMz-redAwNNHseZ41lFyd-u3k,8097
|
|
41
41
|
docling_core/types/__init__.py,sha256=MVRSgsk5focwGyAplh_TRR3dEecIXpd98g_u3zZ5HXo,260
|
|
@@ -75,9 +75,9 @@ docling_core/utils/generate_jsonschema.py,sha256=uNX1O5XnjyB5nA66XqZXTt3YbGuR2ty
|
|
|
75
75
|
docling_core/utils/legacy.py,sha256=5lghO48OEcV9V51tRnH3YSKgLtdqhr-Q5C_OcJZ8TOs,24392
|
|
76
76
|
docling_core/utils/validate.py,sha256=aQ11UbFyl8iD_N7yTTZmm_VVeXz8KcCyn3GLXgkfYRM,2049
|
|
77
77
|
docling_core/utils/validators.py,sha256=azcrndLzhNkTWnbFSu9shJ5D3j_znnLrIFA5R8hzmGU,2798
|
|
78
|
-
docling_core-2.43.
|
|
79
|
-
docling_core-2.43.
|
|
80
|
-
docling_core-2.43.
|
|
81
|
-
docling_core-2.43.
|
|
82
|
-
docling_core-2.43.
|
|
83
|
-
docling_core-2.43.
|
|
78
|
+
docling_core-2.43.1.dist-info/licenses/LICENSE,sha256=2M9-6EoQ1sxFztTOkXGAtwUDJvnWaAHdB9BYWVwGkIw,1087
|
|
79
|
+
docling_core-2.43.1.dist-info/METADATA,sha256=uVJIJpT7DuKgWIYmdqxgTf2Av_5dB2Da9ZfcPiHqbPc,6453
|
|
80
|
+
docling_core-2.43.1.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
|
81
|
+
docling_core-2.43.1.dist-info/entry_points.txt,sha256=ER4zROQWkFMHIrY-oqY5E4HeCcCIg8dLkNztYGxdb7c,59
|
|
82
|
+
docling_core-2.43.1.dist-info/top_level.txt,sha256=O-tcXpGiurlud-1ZxMq1b-OmrfAVA4sajcgWU32RtfA,13
|
|
83
|
+
docling_core-2.43.1.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|