Add replacer(-two_columns,-font_to_span, preproc_headings)

This commit is contained in:
Kiryl
2022-09-05 17:23:03 +03:00
parent 3fcff462d3
commit 9e31d3152c
2 changed files with 106 additions and 121 deletions

View File

@@ -11,12 +11,63 @@
{
"name": "title",
"value": "footer"
},
{
"name": "id",
"value": "^Table of Contents\\d+"
}
]
}
}
]
},
{
"preset_name": "replacer",
"rules": [
{
"tags": ["^font$"],
"condition": null,
"tag_to_replace": "span"
},
{
"tags": ["^h[6-9]$"],
"condition": null,
"tag_to_replace": "p"
},
{
"tags": ["^div$"],
"condition": {
"parent_tags": null,
"child_tags": null,
"attrs": [
{
"name": "style",
"value": "column-count: 2"
}
]
},
"tag_to_replace": "p"
}
]
},
{
"preset_name": "attr_replacer",
"rules": [
{
"attr": {
"name": "style",
"value": "column-count: 2"
},
"condition": {
"tags": ["^p$"]
},
"attr_to_replace": {
"name": null,
"value": "columns2"
}
}
]
},
{
"preset_name": "unwrapper",
"rules": [
@@ -33,16 +84,7 @@
{
"name": "lang",
"value": "^ru-RU$"
}
]
}
},
{
"tags": ["^font$"],
"condition": {
"parent_tags": null,
"child_tags": null,
"attrs": [
},
{
"name": "face",
"value": "^Times New Roman[\\w, ]+$"
@@ -53,7 +95,7 @@
{
"tags": ["^p$"],
"condition": {
"parent_tags": "li",
"parent_tags": ":is(li)",
"child_tags": null,
"attrs": null
}
@@ -74,8 +116,8 @@
{
"tags": ["^u$"],
"condition": {
"parent_tags": "a",
"child_tags": "a",
"parent_tags": ":is(a)",
"child_tags": ":is(a)",
"attrs": null
}
},
@@ -89,4 +131,4 @@
}
]
}
]
]