forked from LiveCarta/BookConverter
Add ability to get file from import in css
This commit is contained in:
@@ -165,7 +165,7 @@ LIVECARTA_STYLE_ATTRS_SHOULD_BE_TAG = {
|
||||
}
|
||||
|
||||
|
||||
def check_style_to_be_tag(style) -> List[tuple]:
|
||||
def check_style_to_be_tag(style: str) -> List[tuple]:
|
||||
"""
|
||||
Function searches style properties that can be converted to tags.
|
||||
It searches for them and prepare list of properties to be removed from style string
|
||||
@@ -511,6 +511,8 @@ def convert_html_soup_with_css_style(html_soup: BeautifulSoup, css_text: str) ->
|
||||
tags_with_possible_style_attr = html_soup.find_all(
|
||||
could_have_style_in_livecarta_regexp)
|
||||
for i, x in enumerate(tags_with_possible_style_attr):
|
||||
if i == 2:
|
||||
pass
|
||||
x.attrs['livecarta_id'] = i
|
||||
livecarta_tmp_ids.append(i)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user