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

fix(sheet): parseValue handle number #4049

Merged
merged 1 commit into from
Nov 30, 2024
Merged

fix(sheet): parseValue handle number #4049

merged 1 commit into from
Nov 30, 2024

Conversation

Dushusir
Copy link
Member

@Dushusir Dushusir commented Nov 13, 2024

What's updated?

Fix parse cell input

How to test?

  1. Enter =SUM(11, 2 2, 33) in the Cell
  2. Keep =SUM(11, 2 2, 33) (Previously it was correctly coverted to =SUM(11, 45324, 33))

Pull Request Checklist

  • Related tickets or issues have been linked in the PR description (or missing issue).
  • Naming convention is followed (do please check it especially when you created new plugins, commands and resources).
  • Unit tests have been added for the changes (if applicable).
  • Breaking changes have been documented (or no breaking changes introduced in this PR).

Copy link

github-actions bot commented Nov 13, 2024

View Deployment

📑 Examples 📚 Storybook
🔗 Preview link 🔗 Preview link

Copy link

github-actions bot commented Nov 13, 2024

Playwright test results

passed  20 passed

Details

stats  20 tests across 9 suites
duration  4 minutes, 48 seconds
commit  0b0b7a6
info  For more information, see full report

Copy link

codecov bot commented Nov 13, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 33.76%. Comparing base (fe472fb) to head (0b0b7a6).
Report is 2 commits behind head on dev.

Additional details and impacted files
@@           Coverage Diff           @@
##              dev    #4049   +/-   ##
=======================================
  Coverage   33.76%   33.76%           
=======================================
  Files        2486     2486           
  Lines      127614   127615    +1     
  Branches    28584    28585    +1     
=======================================
+ Hits        43092    43093    +1     
  Misses      84522    84522           

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

@Dushusir Dushusir added the qa:untested This PR is ready to be tested label Nov 13, 2024
@Dushusir Dushusir marked this pull request as ready for review November 13, 2024 08:17
@zhaolixin7 zhaolixin7 added the qa:verified This PR has already by verified by a QA and is considered good enough to be merge label Nov 18, 2024
@univer-bot univer-bot bot removed the qa:untested This PR is ready to be tested label Nov 18, 2024
Copy link
Member

@wzhudev wzhudev left a comment

Choose a reason for hiding this comment

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

Should add a unit test for the situation numfmt.isDate() is true.

@Dushusir
Copy link
Member Author

Should add a unit test for the situation numfmt.isDate() is true.

In this test, 2 2 will be parsed as a date type

expect(normalizeStringByLexer('=SUM(11, 2 2, 33)')).toBe('=SUM(11, 2 2, 33)');

Execution details

numfmt.parseValue('2 2') // Get { "v": 45324, "z": "m d"}
numfmt.isDate('m d') // Get true

image

@Dushusir Dushusir requested a review from wzhudev November 19, 2024 12:31
@Dushusir Dushusir force-pushed the dushusir/fix-cell-input branch from 46b7a35 to 0b0b7a6 Compare November 30, 2024 02:54
Copy link
Member

@wzhudev wzhudev left a comment

Choose a reason for hiding this comment

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

LGTM

@Dushusir Dushusir merged commit 59b95fa into dev Nov 30, 2024
9 checks passed
@Dushusir Dushusir deleted the dushusir/fix-cell-input branch November 30, 2024 03:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
qa:verified This PR has already by verified by a QA and is considered good enough to be merge
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants