Apply CSS and get properties
Hey, I just stumbled upon this library and while it looks super neat, the examples are a bit sparse. So this might be a bit of a stretch, but I'm basically looking to do the following:
(1) Parse some HTML, (2) parse some CSS, (3) apply the CSS rules to the HTML tree, and (4) obtain style properties for each element.
Is this possible with lexbor at this point?
Hi @marcpabst
(3) apply the CSS rules to the HTML tree, and (4) obtain style properties for each element.
On development stage. In a week, the parser of CSS properties will be ready and apply them to the nodes of the HTML tree.
Nice! I will keep an eye on this package! Thanks!
@marcpabst
Delays for at least a week. A lot of things to do at the main job.
Hey, no worries - your real job is more important. Would be cool though if you'd let me know when there is any progress :).
i'll try to help with css properties once css parser is in git
Yeah, that'd be much appreciated!
@lexborisov still no news on this ?
Seems so. @vtorri
I am looking for a good HTML/CSS parser combo and so far Lexbor is the furthest next to Netsurf's codebase. Hopefuly it's gonna get this feature soon =)
@IngwiePhoenix
There should be a big commit soon. Sorry, very busy with main job.
@lexborisov Hello, I hope you are well. Is there progress with CSS work ?
@marcpabst @vtorri @IngwiePhoenix
The first version of the styles has finally appeared. Better late than never!
Please, see examples.
Now I am expanding the available properties for parsing. At the moment, parsing recognizes only two properties: width and height. All other properties are treated as customs. They also apply to elements. Plus I will add more examples.
@lexborisov great news !
Thats awesome! :D Going to take a look at it right away.
Took a look and I love what I see. This is pretty awesome, gonna play with this later. But this is pretty much what I needed. Great work, thanks so much!
@IngwiePhoenix
Thanks for the feedback. This is just the beginning :)
@lexborisov do you want me to help about css properties ?
@vtorri
You can not ask, but immediately help! :) In fact, I will now add the main (needed for further development) properties. And I will describe the steps for adding new properties.
@vtorri
Please, see wiki instructions for add new property for parsing.
Later I will write a list of properties that can be dealt with.
@marcpabst
Done.