Fix <img> HTML element refactoring issue (resolve #476, close #477)

This commit is contained in:
Cotes Chung 2022-01-05 00:53:16 +08:00
parent 7337fa5f20
commit 948356d7d6

View file

@ -56,9 +56,10 @@
{% assign _height = nil %}
{% assign _src = nil %}
{% assign _left = _img_snippet | split: '/>' | first %}
{% assign _right = _img_snippet | replace: _left, '' %}
{% assign _left = _img_snippet | split: '>' | first %}
{% assign _right = _img_snippet | remove: _left %}
{% assign _left = _left | remove: ' /' %}
{% assign _left = _left | replace: ' w=', ' width=' | replace: ' h=', ' height=' %}
{% assign _attrs = _left | split: ' ' %}