# Sphinx Book Theme 功能记录

## 文本

### 高亮

```{example} 

NMY[DD]{.bg-warning}

```

## margin

一些右边栏的技巧

### 各种admonition

````{example} 

```{note}
:class: margin

watch this!
```

And this!

````

### 直接创建一个侧边块

````{example}

```{margin}

hello!

```

````

### 侧边批语

````{example} 

Here's my sentence and a sidenote[^1].

[^1]: And here's my sidenote content.

````

这里因为在一个`example`块里面所以显示的不太正常。但在实际应用中会出现在margin里，其实和[直接创建一个侧边块](#直接创建一个侧边块)是一样的。

## admonition

note, important & something

### 自定义标题

````{example} 

```{admonition} 要我说啊：
---
class: important
---


这个功能有点意思
```

````

### 可折叠

````{example} 

```{admonition} 也许对你有帮助：
---
class: seealso dropdown
---
但应该没有
```

````

### 全长度 note

````{example} 

```{important}
:class: full-width
也许这看上去是让人困惑的: 为什么不能 $100\%$ 赢呢？

原因是，不管如何，Alice 和 Bob 不知道对方拿到的是什么。真值表有四种情况，自己只能看见一半的信息，因此不能说 "$i,j=0,0$ 时我们就怎么出." 这种话。只能说" Alice 看见 0 时该出 1, Bob 看见 1 时该出 0"，这样是不能保证赢的。
```

````

### 引言

````{example} 

```{epigraph}
这个页面确实可以

-- 沃兹基硕德
```

````

### 按钮

````{example}
```{button-link} /index.html
      :color: primary

      回到主页
```
````

## 图片

````{example}

```{figure} pics/logo.jpg
---
width: 60%
figclass: margin-caption
alt: My figure text
name: test_test
---
如果figclass不设置则在下方. 而设置为margin就整个图片在右边。要注意yaml块不能和上方```有空行。
```
如{numref}`test_test`所示

注意这种在orphan对象里是没法引用的。

````

## 多张图片

````{example}

```{subfigure} AB|CD
:gap: 6px
:subcaptions: below
:name: mymultifigure

![Image A](./pics/logo.jpg)

![Image B](./pics/logo.jpg)

![Image C](./pics/logo.jpg)

![Image D](./pics/logo.jpg)

块的描述就是分区方式，如 AA|BC就是A独占一行， AB|AC就是A独占一列。A.B|CDE就是AB中间有一个空白。gap是图与图之间的空隙，subcaptions是子图图注的位置，可以选above|below
```

````

## 表格

````{example}

```{list-table} 名字在这！
---
width: 80%
name: test_table
header-rows: 1
stub-columns: 2
---

* - 1
  - 2
  - 3
  - 4
* - 1
  - 2
  - 3
  - 4
* - 1
  - 2
  - 3
  - 4
* - 1
  - 2
  - 3
  - 4

```
如{numref}`test_table`所示
````

## 公式

### 公式引用

````{example}

$$
\alpha = 2 c
$$ (test-eq)

公式{eq}`test-eq`

````

## 代码

````{example}

```{code-block} python
:linenos:
:emphasize-lines: 1,3

import numpy as np
import matplotlib.pyplot as plt
from pyscf import gto, scf, dft

# 定义键长范围和基组
bond_lengths = np.linspace(0.5, 3.0, 20)
basis_sets = ['sto-3g', '6-31g', 'cc-pvdz', 'cc-pvtz']
```

````