Filter level: a reference date before 1 AD looks like an input error

Đang mở
#358 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 1 ngày

Chưa có ai nhận issue này.

Đánh giá

Độ khó
3/5
Thời gian dự kiến
1-2 ngày
Mức phù hợp với người mới
78/100
Loại issue
Lỗi
Độ rõ ràng
Đặc tả rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
javascript, react

Hướng nghiên cứu

Start with packages/pivotkit-react/src/filter-level.jsx around dayWhole, aria-invalid, and the quick-anchor-date-hint line, then inspect dateInputValue in packages/pivotkit-react/src/menu-ops.js. Add English and German neutral guidance for an applied date the field cannot display, and cover the field with a browser or render test. Done when that case omits aria-invalid, shows the guidance, and existing behavior for dates from 1 AD remains intact.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

idea

Follow-up from the review of #357 (#351).

An <input type="date"> cannot hold a year before 1 AD. When a view's quick choice counts from a reference date before 1 AD (pivotkit-core accepts it, for example from a loaded view), the Filter level shows the date field empty, marks it aria-invalid and shows "Enter a whole date; the ranges still count from 5 BC." That reads as if the user made a mistake. The date that applies is fine; the field simply cannot show it.

Where: the reference date's field in filter-level.jsx (dayWhole, aria-invalid, the quick-anchor-date-hint line) and dateInputValue in menu-ops.js.

Fix: when the field is empty only because the applied date cannot be shown, leave out aria-invalid and show a neutral line instead ("Counts from 5 BC, a date this field cannot show; enter a date to change it."), in English and German. Add a browser or render test that covers the field (none touches quick-anchor-date yet).

Not affected: dates from 1 AD on, which is all real data I know of. Typing a whole date still replaces such a reference date.

Ngôn ngữ chính
JavaScript
Star
1
Fork
1
Merge trung bình
3 giờ 34 phút
Pull request đã merge (30 ngày)
213

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của eizedev/pivotkit

Tất cả issue của eizedev/pivotkit

Issue tương tự

Thêm issue về JavaScript

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.