tag:OSS图片标签加入title属性。

This commit is contained in:
徐涛 2021-05-05 11:49:58 +08:00
parent 2a6fa60587
commit da4956d06d

View File

@ -11,6 +11,7 @@ hexo.extend.tag.register('oss_image', function(args) {
attrs.push(`src="${imageSrc}"`);
let altMessage = args.shift() || '';
attrs.push(`title="${altMessage}"`);
attrs.push(`alt="${altMessage}"`);
let width = args.shift() || 0;