This commit is contained in:
haoouba
2021-02-27 21:00:05 +08:00
parent baec17728e
commit 96085cc371
10 changed files with 288 additions and 240 deletions

View File

@@ -97,6 +97,11 @@ $(function () {
title: '点击复制',
id: 'wmd-copy-button',
svg: '<svg class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg"><path d="M817.521 690.221h-50.921v-356.441c0-40.735-35.644-76.38-76.38-76.38h-356.441v-50.921h356.441c71.289 0 127.3 56.012 127.3 127.3v356.441z" p-id="2048" fill="#9b9b9b"></path><path d="M639.3 817.521h-356.441c-40.735 0-76.38-35.644-76.38-76.38v-356.441c0-40.735 35.644-76.38 76.38-76.38h356.441c40.735 0 76.38 35.644 76.38 76.38v356.441c0 40.735-35.644 76.38-76.38 76.38zM282.859 359.241c-15.277 0-25.461 10.185-25.461 25.46v356.441c0 15.277 10.185 25.461 25.461 25.461h356.441c15.277 0 25.46-10.185 25.46-25.461v-356.441c0-15.277-10.185-25.46-25.46-25.46h-356.441z" p-id="2049" fill="#9b9b9b"></path></svg>'
},
{
title: '插入音乐',
id: 'wmd-mp3-button',
svg: '<svg class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg"><path d="M806.848 262.144v0.064l6.272 5.76a19.2 19.2 0 0 1-26.24 28.032 6044.48 6044.48 0 0 0-72.96-67.2l-3.648-3.328c-21.376-19.392-39.232-35.2-52.224-46.144a282.432 282.432 0 0 0-16.32-13.056c-1.216-0.896-2.048-1.408-1.792-1.344a14.848 14.848 0 0 0 7.296 1.472 18.944 18.944 0 0 0 18.368-18.816v153.6l-19.2-19.2h172.8V896H300.8a95.872 95.872 0 0 1-96-95.872V128.448h364.8a19.2 19.2 0 0 1 0 38.4H224l19.2-19.2v652.48a57.472 57.472 0 0 0 57.6 57.472h499.2l-19.2 19.2V301.12l19.2 19.2H627.2V147.648c0-10.688 8.576-19.456 19.264-19.648a20.672 20.672 0 0 1 9.856 2.24 51.072 51.072 0 0 1 7.872 4.928c6.4 4.736 12.544 9.664 18.56 14.848 18.048 15.36 35.84 31.04 53.376 47.04l3.648 3.328c22.464 20.48 44.864 41.024 67.072 61.76zM243.2 473.408v0.448H896v326.208H128V473.856h76.8v-0.448h38.4z m458.048 72.768c-17.024 0-30.912 4.608-41.6 14.336l-1.472 1.28c-10.496 9.6-16.384 22.592-17.728 39.04h25.984a35.84 35.84 0 0 1 10.496-24.064c5.76-5.312 14.08-8 24.512-8 10.24 0 18.24 2.176 23.616 7.04a26.24 26.24 0 0 1 7.552 19.968 25.472 25.472 0 0 1-8.32 20.16c-5.312 4.608-13.312 7.04-24.064 7.04h-12.352v19.968h12.608c11.456 0 20.224 2.432 26.048 7.296 6.336 4.864 9.472 12.416 9.472 22.592 0 8.768-3.2 15.808-8.96 21.696a38.208 38.208 0 0 1-27.008 9.728 35.136 35.136 0 0 1-24.832-8.768c-7.296-6.336-10.944-15.36-11.456-27.008h-26.752c1.472 19.456 8.32 34.304 20.48 44.48 10.688 9.024 25.024 13.632 42.752 13.632 18.56 0 33.856-5.312 45.504-15.552a51.584 51.584 0 0 0 16.512-39.424 36.8 36.8 0 0 0-8.704-25.28 48.512 48.512 0 0 0-23.36-14.336c18.944-6.336 28.672-19.2 28.672-38.208a43.328 43.328 0 0 0-15.552-35.008c-10.688-8.512-24.576-12.608-42.048-12.608z m-403.2 3.392h-31.424V723.2h26.496V599.168h0.96l53.312 124.032h22.848l53.248-124.032h0.96V723.2h26.496V549.568h-31.36l-60.288 139.072h-0.768l-60.544-139.072z m258.944 0H484.992V723.2h26.56v-67.584h44.992c41.6 0 62.464-17.792 62.464-53.312 0-35.2-20.672-52.736-62.016-52.736z m-2.176 22.592c12.864 0 22.4 2.432 28.48 7.296 6.08 4.416 9.216 12.16 9.216 22.848 0 10.752-3.2 18.56-8.96 23.36-6.144 4.864-15.616 7.296-28.736 7.296h-43.264v-60.8h43.264z" p-id="14012" fill="#9b9b9b"></path></svg>'
}
];
@@ -158,6 +163,9 @@ $(function () {
case 'wmd-copy-button':
str = `{copy text="文本文本"}${$('#text').selectionRange() ? $('#text').selectionRange() : '点击复制'}{/copy}`;
break;
case 'wmd-mp3-button':
str = `\n\n{mp3 src="音乐地址" /}\n\n`;
break;
}
return str;
}