change(mfm): `$[tada ]` のフォントサイズは1段階しか大きくならないように

This commit is contained in:
kakkokari-gtyih 2024-04-28 14:22:01 +09:00
parent e2ff5f58b2
commit 3a4db9c73c
2 changed files with 13 additions and 2 deletions

View File

@ -121,8 +121,11 @@ export default function (props: MfmProps, { emit }: { emit: SetupContext<MfmEven
case 'tada': {
const speed = validTime(token.props.args.speed) ?? '1s';
const delay = validTime(token.props.args.delay) ?? '0s';
style = 'font-size: 150%;' + (useAnim ? `animation: global-tada ${speed} linear infinite both; animation-delay: ${delay};` : '');
break;
style = (useAnim ? `animation: global-tada ${speed} linear infinite both; animation-delay: ${delay};` : '');
return h('span', {
style: 'display: inline-block; ' + style,
class: 'mfm-tada',
}, genEl(token.children, scale));
}
case 'jelly': {
const speed = validTime(token.props.args.speed) ?? '1s';

View File

@ -540,6 +540,14 @@ html[data-color-mode=dark] ._woodenFrame {
}
}
.mfm-tada {
font-size: 150%;
}
.mfm-tada:has(.mfm-tada) {
font-size: 100%;
}
.mfm-x2 {
--mfm-zoom-size: 200%;
}