Get title name.
(el: etree.Element)
| 89 | |
| 90 | @deprecated('Use `render_inner_html` and `striptags` instead.') |
| 91 | def get_name(el: etree.Element) -> str: |
| 92 | """Get title name.""" |
| 93 | |
| 94 | text = [] |
| 95 | for c in el.itertext(): |
| 96 | if isinstance(c, AtomicString): |
| 97 | text.append(html.unescape(c)) |
| 98 | else: |
| 99 | text.append(c) |
| 100 | return ''.join(text).strip() |
| 101 | |
| 102 | |
| 103 | @deprecated('Use `run_postprocessors`, `render_inner_html` and/or `striptags` instead.') |