Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

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

Open
wants to merge 6 commits into
base: develop
Choose a base branch
from

Conversation

kakkokari-gtyih
Copy link
Contributor

@kakkokari-gtyih kakkokari-gtyih commented Apr 28, 2024

What

$[tada ] で文字サイズが大きくなるのを最初の1段階のみに変更
(tadaで文字サイズがデカくなる仕様自体は利用されているケースが多いので互換性のため1段階だけは大きくするようにしてある)

Why

$[tada ] をネストして巨大な文字を作れてしまう問題を修正

Additional info (optional)

Checklist

  • Read the contribution guide
  • Test working in a local environment
  • (If needed) Add story of storybook
  • (If needed) Update CHANGELOG.md
  • (If possible) Add tests

@kakkokari-gtyih kakkokari-gtyih added the ☢️Breaking This change breaks compatibility label Apr 28, 2024
@github-actions github-actions bot added the packages/frontend Client side specific issue/PR label Apr 28, 2024
@kakkokari-gtyih kakkokari-gtyih changed the title change(mfm): $[tada ] のフォントサイズは1段階しか大きくならないように enhance(mfm): $[tada ] のフォントサイズは1段階しか大きくならないように Apr 28, 2024
Copy link

codecov bot commented Apr 28, 2024

Codecov Report

Attention: Patch coverage is 0% with 5 lines in your changes are missing coverage. Please review.

Project coverage is 77.66%. Comparing base (2b8056a) to head (39efd2f).

Files Patch % Lines
...src/components/global/MkMisskeyFlavoredMarkdown.ts 0.00% 5 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff              @@
##           develop   #13757       +/-   ##
============================================
+ Coverage    64.95%   77.66%   +12.70%     
============================================
  Files          989      183      -806     
  Lines       112848    25408    -87440     
  Branches      5770      487     -5283     
============================================
- Hits         73306    19734    -53572     
+ Misses       38100     5667    -32433     
+ Partials      1442        7     -1435     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@kakkokari-gtyih kakkokari-gtyih removed the ☢️Breaking This change breaks compatibility label Apr 28, 2024
@kakkokari-gtyih
Copy link
Contributor Author

ちょっとbreaking change過ぎるので一旦なしで

@kakkokari-gtyih kakkokari-gtyih deleted the enh-mfm-tada branch April 28, 2024 05:37
@kakkokari-gtyih kakkokari-gtyih restored the enh-mfm-tada branch May 15, 2024 10:36
@kakkokari-gtyih
Copy link
Contributor Author

kakkokari-gtyih commented May 15, 2024

breakingではあるものの悪用例が発生したのを確認した(io)ので再オープン
(破壊的変更であるかどうかは私では判断しかねるのでちょっと確認しておいてください🙏)

cc: @u1-liquid

@kakkokari-gtyih kakkokari-gtyih added the ☢️Breaking This change breaks compatibility label May 15, 2024
font-size: 150%;
}

.mfm-tada:has(.mfm-tada) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hasセレクタって重そうな気がしたけどどうだろう

Copy link
Contributor Author

@kakkokari-gtyih kakkokari-gtyih May 18, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

そもそも登場頻度(このクエリに引っかかること)は高くない気がするので大丈夫かも

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ブラウザが「このクエリに引っかかるかどうか」を判定すること自体のコストが高いという話だわね

@tai-cha
Copy link
Contributor

tai-cha commented May 20, 2024

related? #13266

@tai-cha
Copy link
Contributor

tai-cha commented May 20, 2024

tadaのネスト回数によってはx2やx3, x4同様に畳めばいいのでは?(普通にannoyingなので)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
☢️Breaking This change breaks compatibility packages/frontend Client side specific issue/PR
Projects
Development

Successfully merging this pull request may close these issues.

3 participants