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

Wrong week number which start on #578

Closed
2 tasks done
huyjs9 opened this issue Jan 12, 2022 · 0 comments
Closed
2 tasks done

Wrong week number which start on #578

huyjs9 opened this issue Jan 12, 2022 · 0 comments
Labels
bug Something isn't working

Comments

@huyjs9
Copy link

huyjs9 commented Jan 12, 2022

Before you start - checklist

  • I followed instructions in documentation written for my React-Calendar version
  • I have checked if this bug is not already reported

Description

Week starts on Saturday on 01/01/2022 but it's week 52 of 2021

      <Calendar
        onChange={onChange}
        locale="en-US"
        calendarType="Arabic"
        showWeekNumbers
        showFixedNumberOfWeeks
        value={date}
      />

Steps to reproduce

  1. Go to https://codesandbox.io/s/react-wrong-week-number-xv16g?file=/src/index.js.
  2. Move to January 2022
  3. Check issue of the wrong week

Expected behavior

week number will return week 1 for the start date of 01/01/2022

Actual behavior

week number returned week 52 of 2021 for week 1 of 2022

Environment

  • Browser (if applicable):
  • React-Calendar version:
  • React version:
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant