pydoc HTML output is not responsive and has no viewport meta in released versions
Chưa có ai nhận issue này.
- Ngôn ngữ chính
- Python
- Star
- 77.2k
- Fork
- 35.9k
- Chỉ số merge pull request
- Chỉ số pull request đang chờ
Mô tả
python -m pydoc -w generates standalone HTML pages for modules. The output is not usable on mobile:
- The generated page has no tag in any released version (3.11-3.13). A viewport tag was added to the main branch only recently (Lib/pydoc.py), so it is not in any release yet.
- Lib/pydoc_data/_pydoc.css contains no layout media queries at all; the only @media block is
prefers-color-scheme: dark. The navigation sidebar and content are laid out with fixed widths, which overflows on narrow screens.
Related: #127276 ("Missing styles for pages created by a 'python -m pydoc -w' call", open) and #153906 (closed). This issue is specifically about the mobile/responsive behavior.
Expected: backport/keep a viewport meta tag in the generated HTML and add a max-width media query that stacks the sidebar above the content on narrow screens.
Hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- 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.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Hướng nghiên cứu
Bắt đầu với Lib/pydoc.py và Lib/pydoc_data/_pydoc.css, sau đó chạy python -m pydoc -w trên một module để kiểm tra trang được tạo. Hoàn tất có nghĩa là đầu ra được phát hành bao gồm thẻ meta viewport và trên các màn hình hẹp, phần điều hướng xếp phía trên nội dung mà không bị tràn.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Đánh giá
- Công nghệ
- css, python
- Lĩnh vực
- documentation, frontend
- Loại issue
- Lỗi
- Độ khó
- 2/5
- Thời gian dự kiến
- 1-3 giờ
- Mức độ hoạt động
- Ít trao đổi
- Độ rõ ràng
- Đặc tả rõ ràng
- Mức phù hợp với người mới
- 78/100