plotly / plotly/plotly.js

Legend text overlapping Labels of Y axis when legends set tot left of Chart

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

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

bug P3
Ngôn ngữ chính
JavaScript
Star
18.3k
Fork
2k
Merge trung bình
2 ngày 12 giờ
Pull request đã merge (30 ngày)
28

Mô tả

When legends are left aligned to the chart and Y axis labels have long string. The legend and labels text seems to overlap each other
image
The reason behind seems the way marginPushers are calculated and the labels are rendered. Labels are rendered considering the anchor point for the text as "start" or "end" based on the side where the labels are displayed. In case of labels being displayed on left the text-anchor is set to "right" while the rest of the whole calculations for the charts does not consider this and all the other layers are rendered without considering the extra space that will be required for the labels to render themselves taking space from right to left (read here. When labels are on right we should consider them as margin pushers and calculate them for transformation/axis translations of all layers of the Charts such as zeroline/grid/plots etc,

Please share your point of view or any workarounds, if can be used.

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

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.

Hướng nghiên cứu

Bắt đầu bằng cách theo dõi cách marginPushers được tính toán và cách các nhãn trục Y cùng các chú giải căn trái được render, tập trung vào hành vi text-anchor của SVG được mô tả trong issue. Tái hiện biểu đồ với các nhãn trục Y dài ở phía trái và một chú giải căn trái; được xem là hoàn thành khi chú giải, các nhãn, zeroline, lưới, các plot và các phép dịch của trục không còn chồng lấp lên nhau.

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

Đánh giá

Công nghệ
javascript
Lĩnh vực
data-visualization
Loại issue
Lỗi
Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức độ hoạt động
Đình trệ
Độ rõ ràng
Khá rõ ràng
Mức phù hợp với người mới
35/100

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.