ladybird/Userland/Libraries/LibWeb/Internals/Inspector.idl
Timothy Flynn 3ec5c1941f LibWeb+LibWebView: Add a button to the Inspector to export its contents
When working on the Inspector's HTML, it's often kind of tricky to debug
when an element is styled / positioned incorrectly. We don't have a way
to inspect the Inspector itself.

This adds a button to the Inspector to export its HTML/CSS/JS contents
to the downloads directory. This allows for more easily testing changes,
especially by opening the exported HTML in another browser's dev tools.

We will ultimately likely remove this button (or make it hidden) by the
time we are production-ready. But it's quite useful for now.
2024-08-20 09:28:25 +02:00

19 lines
753 B
Text

#import <DOM/NamedNodeMap.idl>
[Exposed=Nobody] interface Inspector {
undefined inspectorLoaded();
undefined inspectDOMNode(long nodeID, optional long pseudoElement);
undefined setDOMNodeText(long nodeID, DOMString text);
undefined setDOMNodeTag(long nodeID, DOMString tag);
undefined addDOMNodeAttributes(long nodeID, NamedNodeMap attributes);
undefined replaceDOMNodeAttribute(long nodeID, unsigned long long attributeIndex, NamedNodeMap replacementAttributes);
undefined requestDOMTreeContextMenu(long nodeID, long clientX, long clientY, DOMString type, DOMString? tag, unsigned long long? attributeIndex);
undefined executeConsoleScript(DOMString script);
undefined exportInspectorHTML(DOMString html);
};