Fix regex bug and add support for other svg elements

This fixes an issue with the regex that ended up doing `</style>>`. It also adds support for other elements because not all SVGs are made of paths.