ant-design / cssinjs

https://ant-design.github.io/cssinjs
MIT License
235 stars 57 forks source link

fix: fix memo path #146

Closed zombieJ closed 8 months ago

zombieJ commented 8 months ago

对于嵌套主题,token 会存在递进关系:

const tokenPath1 = [token1];
const tokenPath2 = [token1, token2];

这使得路径存在子集关系时,两者会冲突。添加额外的 value 映射对象隔离这种情况。

github-actions[bot] commented 8 months ago

😭 Deploy PR Preview 1914d2123d8d723a9c0ff99fbacbd8e10a8115a7 failed. Build logs

🤖 By surge-preview

codecov-commenter commented 8 months ago

Codecov Report

All modified lines are covered by tests :white_check_mark:

Comparison is base (3e59218) 94.32% compared to head (6d176f5) 94.58%.

:exclamation: Current head 6d176f5 differs from pull request most recent head 1914d21. Consider uploading reports for the commit 1914d21 to get more accurate results

Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #146 +/- ## ========================================== + Coverage 94.32% 94.58% +0.26% ========================================== Files 25 25 Lines 2202 2199 -3 Branches 346 346 ========================================== + Hits 2077 2080 +3 + Misses 125 119 -6 ``` | [Files](https://app.codecov.io/gh/ant-design/cssinjs/pull/146?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=ant-design) | Coverage Δ | | |---|---|---| | [src/hooks/useCacheToken.tsx](https://app.codecov.io/gh/ant-design/cssinjs/pull/146?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=ant-design#diff-c3JjL2hvb2tzL3VzZUNhY2hlVG9rZW4udHN4) | `99.41% <100.00%> (-0.02%)` | :arrow_down: | | [src/util.ts](https://app.codecov.io/gh/ant-design/cssinjs/pull/146?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=ant-design#diff-c3JjL3V0aWwudHM=) | `55.40% <100.00%> (+4.05%)` | :arrow_up: |

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.