18 lines
472 B
Python
18 lines
472 B
Python
import json
|
|
from urllib import request
|
|
|
|
|
|
def get_icons():
|
|
url = "https://cdn.jsdelivr.net/npm/remixicon@4.5.0/fonts/remixicon.glyph.json"
|
|
data = json.loads(request.urlopen(url).read())
|
|
|
|
return [i.removesuffix("-line") for i in data.keys() if i.endswith("-line")]
|
|
|
|
|
|
def pdf_outline_to_str(outline):
|
|
return " ".join(
|
|
(
|
|
dest.title if not isinstance(dest, list) else pdf_outline_to_str(dest)
|
|
for dest in outline
|
|
)
|
|
)
|