Helium
Helium copied to clipboard
Duplicate clear button
Executing a cell results (inline) will render two clear buttons ("x") of which only the lower one is functional. See screenshot:

This problem is caused by the single if statement in line 505:

I'm not sure if this behavior is intended. Afaik, if "image/png" is present, "text/plain" doesn't contain anything.
A possible fix could be sorting and replacing if with elif:
def _write_mime_data_to_view(
self, mime_data: dict, region: sublime.Region, view: sublime.View
) -> None:
if "image/png" in mime_data:
pass
elif "text/plain" in mime_data:
pass
elif "text/html" in mime_data:
pas