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

Adjust page width in mobile to device width #157

Closed
wants to merge 1 commit into from
Closed

Adjust page width in mobile to device width #157

wants to merge 1 commit into from

Conversation

ykrods
Copy link

@ykrods ykrods commented Jul 5, 2019

solve #139 and improve #140

I noticed the bug and investigated implementation of Sphinx. Related feature was added in Sphinx v1.7.0 and implemented on sphinx-doc/sphinx#4376 .

I think it's better to describe mix-width property in media queries and the value as unset as this PR.

Reasons

  • min-width and max-width of div.body are defined as theme options of basic theme. Because Alabaster inherit basic theme, end user can change the value like bellow. If static value is defined in alabaster.css, these options will be meaningless.

    # conf.py example
    html_theme_options = {
      'body_min_width': 320,
      'body_max_width': 640,
    }
  • I think this sphinx feature (and basic theme) is assumed to be browsed on only PC browser and there is no need to have fixed value to these property on smartphone.

About other changes

When I tested this changes, I noticed that the sidebar width is not fit to widow size.

  • I think padding value of sidebar should be 30px (same of outer margin). Unfortunately, I couldn't understand why the width is 102.5%, but It looks good also to be 100% at my testing.

@bitprophet bitprophet deleted the branch sphinx-doc:master January 13, 2023 00:42
@bitprophet bitprophet closed this Jan 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants