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.
python -m pydoc -wgenerates standalone HTML pages for modules. The output is not usable on mobile: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.