Skip to content

Commit 402f86c

Browse files
author
Susan Vanderplas
committed
Update docs/html
1 parent 0077920 commit 402f86c

File tree

4 files changed

+105
-24
lines changed

4 files changed

+105
-24
lines changed

_freeze/index/execute-results/html.json

Lines changed: 3 additions & 5 deletions
Large diffs are not rendered by default.

_quarto.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ project:
55
preview:
66
port: 3430
77
browser: true
8-
98
post-render:
109
- ./validate.sh
1110

@@ -154,6 +153,7 @@ collapse-callout:
154153
filters:
155154
- custom-callout
156155
- collapse-callout
156+
- filters-fix.lua
157157

158158
format:
159159
html:

filters-fix.lua

Lines changed: 89 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,89 @@
1+
function Div (el)
2+
-- Check for a specific class or other criteria
3+
if el.attributes["class"] == "panel-tabset" then
4+
-- Add the role attribute
5+
el.attributes["role"] = "button"
6+
end
7+
return el
8+
end
9+
10+
function Div (el)
11+
-- Check for a specific class or other criteria
12+
if el.attributes["class"] == "column-margin" then
13+
-- Add the role attribute
14+
el.attributes["role"] = "dialog"
15+
end
16+
return el
17+
end
18+
19+
function Div (el)
20+
-- Check for a specific class or other criteria
21+
if el.attributes["class"] == "example" then
22+
-- Add the role attribute
23+
el.attributes["role"] = "dialog"
24+
end
25+
return el
26+
end
27+
28+
function Div (el)
29+
-- Check for a specific class or other criteria
30+
if el.attributes["class"] == "setup" then
31+
-- Add the role attribute
32+
el.attributes["role"] = "dialog"
33+
end
34+
return el
35+
end
36+
37+
function Div (el)
38+
-- Check for a specific class or other criteria
39+
if el.attributes["class"] == "callout-caution" then
40+
-- Add the role attribute
41+
el.attributes["role"] = "dialog"
42+
end
43+
return el
44+
end
45+
46+
function Div (el)
47+
-- Check for a specific class or other criteria
48+
if el.attributes["class"] == "demo" then
49+
-- Add the role attribute
50+
el.attributes["role"] = "dialog"
51+
end
52+
return el
53+
end
54+
55+
function Div (el)
56+
-- Check for a specific class or other criteria
57+
if el.attributes["class"] == "example" then
58+
-- Add the role attribute
59+
el.attributes["role"] = "dialog"
60+
end
61+
return el
62+
end
63+
64+
function Div (el)
65+
-- Check for a specific class or other criteria
66+
if el.attributes["class"] == "learnmore" then
67+
-- Add the role attribute
68+
el.attributes["role"] = "dialog"
69+
end
70+
return el
71+
end
72+
73+
function Div (el)
74+
-- Check for a specific class or other criteria
75+
if el.attributes["class"] == "advanced" then
76+
-- Add the role attribute
77+
el.attributes["role"] = "dialog"
78+
end
79+
return el
80+
end
81+
82+
function A (el)
83+
-- Check for a specific class or other criteria
84+
if el.attributes["append-hash"] then
85+
-- Add the role attribute
86+
el.attributes["append-hash"] = nil
87+
end
88+
return el
89+
end

index.qmd

Lines changed: 12 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -36,12 +36,12 @@ I've made an effort to use some specific formatting and enable certain features
3636

3737
The book contains a number of features which should help you navigate, use, improve, and respond to the textbook.
3838

39-
::: column-margin
39+
::: {.column-margin role="dialog"}
4040
![Textbook features, menus, and interactive options (click to enlarge)](images/how-to-use/Textbook-features.png){.lightbox fig-alt="There are a number of interactive features available in this textbook. There is a search bar on the left sidebar, along with links to each chapter. On the right, there is a menu specific to the sections in each chapter - this helps you navigate within the chapter. There is also a link to \"Edit this page\" that allows you to submit a correction to the textbook via Github. If you log in via GitHub, you can also leave comments, start discussions, or ask questions using the github discussion integration at the bottom of the page. At the bottom, there is a link to the next chapter, but there are also reaction emoji that allow you to express yourself after you read the chapter."}
4141
:::
4242

4343

44-
::: setup
44+
::: {.setup role="dialog"}
4545
#### Setup {.unnumbered}
4646

4747
These sections contain instructions for installing and configuring things. They may be collapsed by default, but that doesn't make them any less important -- it's just useful to condense them after you've completed the setup so that you can focus on more important things.
@@ -53,7 +53,7 @@ These sections contain instructions for installing and configuring things. They
5353

5454
Some instructions depend on your operating system. Where it's shorter, I will use tabs to provide you with OS specific instructions. Here are the icons I will use:
5555

56-
::: panel-tabset
56+
::: {.panel-tabset role="button"}
5757

5858
#### {{< fa brands windows >}} Windows
5959

@@ -71,25 +71,25 @@ Linux specific instructions. I will usually try to make this generic, but if it'
7171

7272

7373

74-
::: callout-caution
74+
::: {.callout-caution role="dialog"}
7575
#### Warnings {-}
7676

7777
These sections contain things you may want to look out for: common errors, mistakes, and unfortunate situations that may arise when programming.
7878
:::
7979

80-
::: demo
80+
::: {.demo role="dialog"}
8181
#### Demos {-}
8282

8383
These sections contain basic demonstrations of how functions or concepts work. They are slightly less interactive than examples.
8484
:::
8585

86-
::: example
86+
::: {.example role="dialog"}
8787
#### Examples {-}
8888

8989
Examples are intended to be interactive - you should attempt them before looking at the code solutions. Often, examples will have tabs which provide the problem, a sketch (sometimes), and then solutions in R and python.
9090

9191

92-
::: panel-tabset
92+
:::: {.panel-tabset role="button"}
9393
##### Problem {-}
9494

9595
The problem will be in the first tab for you to start with
@@ -102,21 +102,15 @@ A solution will be provided in R, potentially with an explanation.
102102

103103
A solution will be provided in Python as well, with an explanation of that code.
104104

105+
::::
105106
:::
106107

107108
In some cases, the problem will be more open-ended and may not adhere to this format, but most example sections in this book will have solutions provided.
108109
I **highly** recommend that you attempt to solve the problem yourself before you look at the solutions - this is the best way to learn.
109110
Passively reading code does not result in information retention.
110111

111-
:::
112-
113-
<!-- ::: callout-important -->
114-
<!-- #### Essential Reading {.unnumbered} -->
115-
116-
<!-- These sections may direct you to additional reading material that is essential for understanding the topic. For instance, I will sometimes link to other online textbooks rather than try to rehash the content myself when someone else has done it better. -->
117-
<!-- ::: -->
118112

119-
::: learnmore
113+
::: {.learnmore role="dialog"}
120114
#### Learn More {-}
121115
These sections will direct you to additional resources that may be helpful to consult as you learn about a topic.
122116
You do not have to use these sections unless you are 1) bored, or 2) hopelessly lost.
@@ -129,7 +123,7 @@ They're provided to help but are not expected reading (Unlike the essential read
129123
<!-- These generic sections contain information I may want to call attention to, but that isn't necessarily urgent or a common error trap. -->
130124
<!-- ::: -->
131125

132-
::: advanced
126+
::: {.advanced role="dialog"}
133127
#### Advanced {-}
134128
These sections are intended to apply to more advanced courses.
135129
If you are taking an introductory course, feel free to skip that content for now.
@@ -150,7 +144,7 @@ This additional information may be information that is helpful but not essential
150144

151145
</details>
152146

153-
::: {.callout-note collapse="true"}
147+
::: {.callout-note collapse="true" role="dialog"}
154148
#### Another type of expandable note {-}
155149

156150
Answers or punchlines may be hidden in this type of expandable section as well.
@@ -178,7 +172,7 @@ I don't have official editors, but thank you to those who make use of the giscus
178172

179173

180174

181-
::: {.callout-note collapse=true}
175+
::: {.callout-note collapse=true role="dialog"}
182176
## Tools
183177

184178
This book was built with the following parameters/settings/library versions:

0 commit comments

Comments
 (0)