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

Serve template CSS files per Document #1479

Merged
merged 3 commits into from
Jul 15, 2020
Merged

Serve template CSS files per Document #1479

merged 3 commits into from
Jul 15, 2020

Conversation

philippjfr
Copy link
Member

Previously we added the Template CSS to the global list of CSS to be served. This meant that this CSS would pollute the notebook, cause issues when switching templates since the CSS would persist and cause issues when multiple pages being served used different templates or themes.

This PR replaces the default bokeh DocHandler with a PanelDocHandler which in turn replaces bokeh Resources with PanelResources. This gives us more control over the CSS and JS files being served up.

@philippjfr philippjfr added the type: enhancement Minor feature or improvement to an existing feature label Jul 15, 2020
@codecov
Copy link

codecov bot commented Jul 15, 2020

Codecov Report

Merging #1479 into master will increase coverage by 0.06%.
The diff coverage is 85.71%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1479      +/-   ##
==========================================
+ Coverage   86.01%   86.07%   +0.06%     
==========================================
  Files         139      139              
  Lines       15512    15560      +48     
==========================================
+ Hits        13343    13394      +51     
+ Misses       2169     2166       -3     
Impacted Files Coverage Δ
panel/template/base.py 57.78% <35.71%> (+1.85%) ⬆️
panel/io/resources.py 92.06% <94.11%> (+0.22%) ⬆️
panel/io/server.py 65.42% <100.00%> (+2.98%) ⬆️
panel/tests/test_server.py 100.00% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 42065be...04f95be. Read the comment docs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: enhancement Minor feature or improvement to an existing feature
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant