markdown_convert 1.2.40__py3-none-any.whl → 1.2.42__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.
- markdown_convert/__main__.py +0 -2
- markdown_convert/default.css +62 -15
- markdown_convert/modules/convert.py +1 -1
- markdown_convert/modules/transform.py +3 -3
- {markdown_convert-1.2.40.dist-info → markdown_convert-1.2.42.dist-info}/METADATA +3 -3
- {markdown_convert-1.2.40.dist-info → markdown_convert-1.2.42.dist-info}/RECORD +9 -9
- {markdown_convert-1.2.40.dist-info → markdown_convert-1.2.42.dist-info}/WHEEL +0 -0
- {markdown_convert-1.2.40.dist-info → markdown_convert-1.2.42.dist-info}/entry_points.txt +0 -0
- {markdown_convert-1.2.40.dist-info → markdown_convert-1.2.42.dist-info}/licenses/LICENSE +0 -0
markdown_convert/__main__.py
CHANGED
|
@@ -5,7 +5,6 @@ CLI interface to convert markdown files to pdf.
|
|
|
5
5
|
Author: @julynx
|
|
6
6
|
"""
|
|
7
7
|
|
|
8
|
-
|
|
9
8
|
from sys import exit as sys_exit
|
|
10
9
|
|
|
11
10
|
from argsdict import args
|
|
@@ -78,7 +77,6 @@ def main():
|
|
|
78
77
|
|
|
79
78
|
# pylint: disable=W0718
|
|
80
79
|
except Exception as err:
|
|
81
|
-
|
|
82
80
|
asked_for_help = "--help" in arg or "-h" in arg
|
|
83
81
|
show_usage = isinstance(err, (IndexError, ValueError)) or asked_for_help
|
|
84
82
|
|
markdown_convert/default.css
CHANGED
|
@@ -21,7 +21,8 @@ html {
|
|
|
21
21
|
body {
|
|
22
22
|
margin: 0;
|
|
23
23
|
padding: 0;
|
|
24
|
-
font-family:
|
|
24
|
+
font-family:
|
|
25
|
+
"Segoe UI", "Ubuntu", "DejaVu Sans", "Liberation Sans", "Arial",
|
|
25
26
|
"sans-serif";
|
|
26
27
|
color: #333;
|
|
27
28
|
}
|
|
@@ -104,7 +105,7 @@ ol ol,
|
|
|
104
105
|
ul ul {
|
|
105
106
|
margin-bottom: 0;
|
|
106
107
|
margin-left: 0;
|
|
107
|
-
padding-left:
|
|
108
|
+
padding-left: var(--left-margin);
|
|
108
109
|
}
|
|
109
110
|
|
|
110
111
|
/* Code blocks */
|
|
@@ -113,7 +114,7 @@ pre {
|
|
|
113
114
|
white-space: pre-wrap;
|
|
114
115
|
}
|
|
115
116
|
|
|
116
|
-
pre>code {
|
|
117
|
+
pre > code {
|
|
117
118
|
display: block;
|
|
118
119
|
padding: 1em;
|
|
119
120
|
margin-top: 0;
|
|
@@ -121,7 +122,8 @@ pre>code {
|
|
|
121
122
|
}
|
|
122
123
|
|
|
123
124
|
code {
|
|
124
|
-
font-family:
|
|
125
|
+
font-family:
|
|
126
|
+
"JetBrains Mono", "Consolas", "Ubuntu Mono", "DejaVu Sans Mono",
|
|
125
127
|
"Liberation Mono", "Courier New", monospace;
|
|
126
128
|
font-size: 1rem;
|
|
127
129
|
background-color: #eee;
|
|
@@ -150,27 +152,63 @@ blockquote {
|
|
|
150
152
|
color: #666;
|
|
151
153
|
}
|
|
152
154
|
|
|
153
|
-
blockquote>blockquote {
|
|
155
|
+
blockquote > blockquote {
|
|
154
156
|
padding-left: var(--left-margin-small);
|
|
155
157
|
}
|
|
156
158
|
|
|
159
|
+
/* Images */
|
|
157
160
|
img {
|
|
158
161
|
max-width: 80vw;
|
|
159
162
|
max-height: 80vh;
|
|
160
163
|
width: auto;
|
|
161
164
|
height: auto;
|
|
162
165
|
display: block;
|
|
163
|
-
margin:
|
|
166
|
+
margin: 1em auto;
|
|
167
|
+
}
|
|
168
|
+
|
|
169
|
+
/* Image alt text attributes */
|
|
170
|
+
img[alt*="::tiny::"],
|
|
171
|
+
img[alt*="::smallest::"] {
|
|
172
|
+
width: 10vw;
|
|
173
|
+
}
|
|
174
|
+
|
|
175
|
+
img[alt*="::small::"] {
|
|
176
|
+
width: 30vw;
|
|
177
|
+
}
|
|
178
|
+
|
|
179
|
+
img[alt*="::medium::"],
|
|
180
|
+
img[alt*="::normal::"] {
|
|
181
|
+
width: 60vw;
|
|
182
|
+
}
|
|
183
|
+
|
|
184
|
+
img[alt*="::large::"],
|
|
185
|
+
img[alt*="::big::"] {
|
|
186
|
+
width: 80vw;
|
|
187
|
+
}
|
|
188
|
+
|
|
189
|
+
img[alt*="::full::"],
|
|
190
|
+
img[alt*="::max::"],
|
|
191
|
+
img[alt*="::huge::"],
|
|
192
|
+
img[alt*="::wide::"] {
|
|
193
|
+
width: 100vw;
|
|
194
|
+
max-width: 100vw;
|
|
164
195
|
}
|
|
165
196
|
|
|
166
|
-
|
|
167
|
-
|
|
197
|
+
p:has(> img[alt*="::inline::"]) {
|
|
198
|
+
display: inline-block;
|
|
199
|
+
width: min-content;
|
|
200
|
+
vertical-align: top;
|
|
201
|
+
margin-right: 1em;
|
|
202
|
+
}
|
|
203
|
+
|
|
204
|
+
/* Image footers */
|
|
205
|
+
p > img + em {
|
|
168
206
|
text-align: center;
|
|
169
207
|
font-size: 1rem;
|
|
170
208
|
font-style: italic;
|
|
171
209
|
color: #666;
|
|
172
210
|
display: block;
|
|
173
|
-
margin: 1em auto
|
|
211
|
+
margin: 1em auto;
|
|
174
212
|
}
|
|
175
213
|
|
|
176
214
|
/* Tables */
|
|
@@ -212,14 +250,23 @@ td {
|
|
|
212
250
|
word-break: break-word;
|
|
213
251
|
}
|
|
214
252
|
|
|
253
|
+
/* Horizontal rulers */
|
|
254
|
+
hr {
|
|
255
|
+
height: 1px;
|
|
256
|
+
background-color: #999;
|
|
257
|
+
border: none;
|
|
258
|
+
}
|
|
259
|
+
|
|
215
260
|
/* Page breaks */
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
page-break-after: always;
|
|
261
|
+
hr:has(+ hr) {
|
|
262
|
+
visibility: hidden;
|
|
219
263
|
}
|
|
220
264
|
|
|
221
|
-
|
|
222
|
-
|
|
265
|
+
hr + hr {
|
|
266
|
+
clear: both;
|
|
267
|
+
break-after: always;
|
|
268
|
+
page-break-after: always;
|
|
269
|
+
visibility: hidden;
|
|
223
270
|
}
|
|
224
271
|
|
|
225
272
|
section,
|
|
@@ -239,7 +286,7 @@ h5 {
|
|
|
239
286
|
break-after: avoid;
|
|
240
287
|
}
|
|
241
288
|
|
|
242
|
-
/*
|
|
289
|
+
/* Mathematical expressions */
|
|
243
290
|
math[display="block"] {
|
|
244
291
|
margin-top: 1em;
|
|
245
292
|
margin-bottom: 1em;
|
|
@@ -21,13 +21,13 @@ def create_html_document(html_content, css_content, csp):
|
|
|
21
21
|
<html>
|
|
22
22
|
<head>
|
|
23
23
|
<meta charset="UTF-8">
|
|
24
|
-
<meta http-equiv="Content-Security-Policy" content="{csp or
|
|
24
|
+
<meta http-equiv="Content-Security-Policy" content="{csp or ""}">
|
|
25
25
|
<style>
|
|
26
|
-
{css_content or
|
|
26
|
+
{css_content or ""}
|
|
27
27
|
</style>
|
|
28
28
|
</head>
|
|
29
29
|
<body>
|
|
30
|
-
{html_content or
|
|
30
|
+
{html_content or ""}
|
|
31
31
|
</body>
|
|
32
32
|
</html>"""
|
|
33
33
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: markdown_convert
|
|
3
|
-
Version: 1.2.
|
|
3
|
+
Version: 1.2.42
|
|
4
4
|
Summary: Convert Markdown files to PDF from your command line.
|
|
5
5
|
Project-URL: homepage, https://github.com/Julynx/markdown_convert
|
|
6
6
|
Author-email: Julio Cabria <juliocabria@tutanota.com>
|
|
@@ -9,7 +9,7 @@ License-File: LICENSE
|
|
|
9
9
|
Classifier: License :: OSI Approved :: GNU General Public License v2 (GPLv2)
|
|
10
10
|
Classifier: Operating System :: OS Independent
|
|
11
11
|
Classifier: Programming Language :: Python :: 3
|
|
12
|
-
Requires-Python: <3.15,>=3.
|
|
12
|
+
Requires-Python: <3.15,>=3.11
|
|
13
13
|
Requires-Dist: argsdict==1.0.0
|
|
14
14
|
Requires-Dist: beautifulsoup4>=4.14.3
|
|
15
15
|
Requires-Dist: latex2mathml>=3.78.1
|
|
@@ -31,7 +31,7 @@ _Convert Markdown files to PDF from your command line._
|
|
|
31
31
|
|
|
32
32
|
<br>
|
|
33
33
|
|
|
34
|
-
<img src='https://i.imgur.com/kzoo3hs.png'
|
|
34
|
+
<img src='https://i.imgur.com/kzoo3hs.png'>
|
|
35
35
|
|
|
36
36
|
<br>
|
|
37
37
|
|
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
markdown_convert/__init__.py,sha256=ysW3pXsDGGK4PzZHcIBTpfVW58IkDUwHffDkf_GM6UU,303
|
|
2
|
-
markdown_convert/__main__.py,sha256=
|
|
2
|
+
markdown_convert/__main__.py,sha256=w6sHfJcJQpMOERPqiNoKgoRM38YUwK22eGBmVkpZj1g,2807
|
|
3
3
|
markdown_convert/code.css,sha256=Wt4FqFqJcpT-jwY3GN-o4ZRCCXU8DQj-9lqKdGiuoyw,4935
|
|
4
|
-
markdown_convert/default.css,sha256
|
|
4
|
+
markdown_convert/default.css,sha256=-O54VpOvX_PP7vwT8zTErZLYVSzXV4LQoELRM8yXWS8,4166
|
|
5
5
|
markdown_convert/modules/__init__.py,sha256=PFPgiQhMXgyfjD8BkfLC_X8AR1jz-dCxfif2qmNofJs,65
|
|
6
6
|
markdown_convert/modules/constants.py,sha256=eUeIFRxZerP3E0Rgp_Nsl0Q38IBELwca5UO3fbUcxRA,1280
|
|
7
|
-
markdown_convert/modules/convert.py,sha256=
|
|
7
|
+
markdown_convert/modules/convert.py,sha256=02N_Iz4TLKWR1xseNv8hyCTujCJdYepWZlxjXw9tsj0,8876
|
|
8
8
|
markdown_convert/modules/resources.py,sha256=tnW8JmCrJNBRbzOcaOVG6GX5jPC8Kzj3dA7gX0B935A,2488
|
|
9
|
-
markdown_convert/modules/transform.py,sha256=
|
|
9
|
+
markdown_convert/modules/transform.py,sha256=p7J8LJKBjMA_EtUYIfXqw_Tc1eean7EbM6KW5Tv4AOs,3138
|
|
10
10
|
markdown_convert/modules/utils.py,sha256=NX0WegM8e8MPKNNmweTujAWO8ZghdB8LSGDx20K2E44,655
|
|
11
11
|
markdown_convert/modules/validate.py,sha256=XV_k7cHeifEKDaltF26tCmabs2-Me5msP3enI_eVwfA,1517
|
|
12
|
-
markdown_convert-1.2.
|
|
13
|
-
markdown_convert-1.2.
|
|
14
|
-
markdown_convert-1.2.
|
|
15
|
-
markdown_convert-1.2.
|
|
16
|
-
markdown_convert-1.2.
|
|
12
|
+
markdown_convert-1.2.42.dist-info/METADATA,sha256=FpWY-E6em0W-zeNUd8bmg4bk-qJ7Lk3YkKoqWGg2d0k,3928
|
|
13
|
+
markdown_convert-1.2.42.dist-info/WHEEL,sha256=WLgqFyCfm_KASv4WHyYy0P3pM_m7J5L9k2skdKLirC8,87
|
|
14
|
+
markdown_convert-1.2.42.dist-info/entry_points.txt,sha256=RCmzC7C0sX-SpzIP2Cr34rhg3lMd7BRx-exaZPfK8bU,68
|
|
15
|
+
markdown_convert-1.2.42.dist-info/licenses/LICENSE,sha256=gXf5dRMhNSbfLPYYTY_5hsZ1r7UU1OaKQEAQUhuIBkM,18092
|
|
16
|
+
markdown_convert-1.2.42.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|