mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 15:48:12 +00:00
LibWeb: Expose barebones CSSStyleDeclaration to JavaScript
You can now access an element's inline style via Element.style. The interface is not very capable yet though. :^)
This commit is contained in:
parent
0759f54bd3
commit
33e3f0c71f
9 changed files with 43 additions and 2 deletions
|
@ -37,4 +37,11 @@ CSSStyleDeclaration::~CSSStyleDeclaration()
|
|||
{
|
||||
}
|
||||
|
||||
String CSSStyleDeclaration::item(size_t index) const
|
||||
{
|
||||
if (index >= m_properties.size())
|
||||
return {};
|
||||
return CSS::string_from_property_id(m_properties[index].property_id);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue