WebEngine
WebEngine copied to clipboard
Dynamic pages: add class to body for each dynamic path part
For example, on URL /shop/computers/apple/macbook-pro
There can be multiple dynamic path parts: page/shop/@shop-area/@brand/@item.html
Currently, the body gets the following classes:
dir--pagedir--page--shopdir--page--shop--_shop-areadir--page--shop--_shop-area--_branddir--page--shop--_shop-area--_brand--_itemuri--page--shop--_shop-area--_brand--_item
It would also be good to see the following classes, or something similar, so the individual dynamic pages can be referenced in CSS where appropriate:
_shop-area--computers_brand--apple_item--macbook-pro
Can be implemented here: https://github.com/PhpGt/WebEngine/blob/64daaae7a9f6dec9f9935006c2ae930d76e0097a/src/Middleware/RequestHandler.php#L202-L213