Comments (9)
Any idea if it's due to doconce format html
, doconce slides_html
or both? To create a minimal example, do you have any idea if we can neglect any of those options?
from doconce.
Good question. There are two commands:
doconce format html slide1.do.txt --html_output=slide1.deck --pygments_html_style=autumn \
--keep_pygments_html_bg SLIDE_TYPE=reveal SLIDE_THEME=swiss \
--skip_inline_comments
doconce slides_html slide1.deck deck --html_slide_theme=swiss
Running 1) with Pre-break DocOnce and 2) with latest DocOnce works fine.
Running 1) with latest DocOnce and 2) with Pre-break DocOnce leads to the problem.
So it seems that doconce slides_html
is the cause.
from doconce.
I created two virtual environments to test the two commands on combinations of the "old" and latest code versions. By "old" I mean commit 53504e235f41
, which is the one before 0f04d50
.
Below I log an example to reproduce at least some of the issues. I removed all options with styling.
Apparently the first command doconce format html
leads to bad slides in latest. The second command works in latest, meaning that the slides are ok when the second command in latest is applied to the output of the first command in the old version.
The html
output in the old versions has indeed several stray <p>
elements. The new version renders the code with more css and html code. I guess the second command slides_html
relies on some of the features in old html formatting.
I notice that
- The first page with the author, date and title are rendered in a different order and style;
- Text above a code cell/table/figure is placed below it;
- Text in back ticks are separated from their surrounding text;
- The spacing/styling can be different.
### slides.do.txt
TITLE: Minimal slide demo
AUTHOR: Some Author
DATE: today
!split
===== Slide =====
Text above `pycod -t` code with a `for` loop
!bc pycod -t
total = 0
for n in range(10):
total += n
!ec
Text below `pycod -t` code with a `for` loop
Text above a table `table`:
|----c-----------c------|
| time | count |
|----c-----------c------|
| 60 | 10000 |
|-----------------------|
Text below a table `table`
Text above a figure `figure`:
FIGURE: [../img/PythonDict, width=400 frac=0.8] Data structure concept of a dictionary in python. label{PythonDict}
Text below a figure `figure`
Commands:
doconce format html slides.do.txt
doconce slides_html slides deck
from doconce.
Thanks for #132! This fixes the problems I had with deck.js slides as far as I can tell.
However, there is one issue: the command line flag --html_slide_theme
is ignored. It is supposed to result in the following line in the html:
<link rel="stylesheet" media="screen" href="deck.js-latest/themes/style/swiss.css">
Instead, we get the default:
<link rel="stylesheet" media="screen" href="deck.js-latest/themes/style/web-2.0.css">
Also, why is the deck.js
folder now called deck.js-latest
?
A second problem is that now reveal slide output is broken...
from doconce.
I fixed the theme option and added some css to shows tables with borders.
There is another issue in the slides (also in the old code): <h1>
tags are displayed very big in the middle of the slide, and if one has more than one in the input html file (from DocOnce chapters, but also from the TOC or TITLE) they clutter the slide. Maybe the --sections_down
option would fix it.
Also, why is the deck.js folder now called deck.js-latest?
Because that is how the latest package from http://imakewebthings.com/deck.js/ is called. deck.js
A second problem is that now reveal slide output is broken...
It does not surprise me, unfortunately
from doconce.
and added some css to shows tables with borders.
Ha, this is very nice! However, these borders do also appear around 'tables' created by !bslidecell
blocks, and these were not there before and should not really be there. Quick demo: https://github.com/lexnederbragt/doconce_demo/blob/master/slide1/slide1.do.txt (last slide, html version in the repo is -not-yet- EDIT now also updated).
About the <h1>
tags, these are title slides, I use them sometimes so it kind of is a feature. And one should only have one per slide (which I guess is poorly documented).
One new issue: earlier, slide transitions were commented out by DocOnce (I guess), see https://github.com/lexnederbragt/doconce_demo/blob/b8b90e565e559506172fa4c694e51f7987fa59f8/slide1/slide1.deck.html#L88. Now, horizontal-slide.css
is added as he default. I'd prefer going back to no transitions... (or, if you have nothing else to do, default --> no transition, but can be changed by a new flag, for example --html_slide_transition=horizontal-slide
).
Thanks for fixing the reveal slides.
from doconce.
Thanks for #140! Table borders now no longer appear in deck slides. But, they are still present in reveal slides...
from doconce.
I also implemented --html_slide_transition
in reveal.js slides and fixed no transition theme as default. The existing code could be made more dynamic as I tried to do for deck.js, but it should work. The existing code creates stray HTML elements (e.g. unclosed <p>
)
from doconce.
After some more testing, I think all is fixed now. Closing the issue. Thanks!
from doconce.
Related Issues (20)
- Speaker notes in deck slides HOT 2
- TITLE/AUTHOR/DATE cause empty markdown cell at top of ipynb output HOT 1
- `print(type(x))` gives no output in html HOT 1
- New feature: abort on error with --execute HOT 7
- Create an answer book in ipynb HOT 5
- New feature: enable execution in a different folder HOT 7
- Figures with caption inside admonitions do not work HOT 1
- Empty markdown cells in ipynb
- Remove `Figure 1` label in html slides when no caption given HOT 4
- Github Actions on the doconce repo time out
- Create notebook cell id based on cell content
- Python 1 HOT 1
- TOC title in html and ipynb have different margins HOT 2
- Miras
- code execution for html should be skipped when py-out present
- Formatting of py-out block in html HOT 1
- Localization of doconce HOT 2
- DocOnce and Beamer document with animation HOT 1
- Compatiliblity with regex 2022.10.31 HOT 1
- Pointing to solutions for installation problems HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from doconce.