Enabled snippet completion from the first letter (allowing single letter snippet prefixes). Extended the luasnip usage and added a telescope extension to show all enabled snippets for the current buffer.
100 lines
1.9 KiB
Text
100 lines
1.9 KiB
Text
# Quarto extensions to markdown
|
|
|
|
extends markdown
|
|
|
|
# definitions list
|
|
snippet : Definition list
|
|
$1
|
|
: $0
|
|
|
|
snippet `` Codecell with language
|
|
\`\`\`{${1:language}}
|
|
${2:code}
|
|
\`\`\`
|
|
|
|
snippet ``p Codecell with language
|
|
\`\`\`{python}
|
|
${2:code}
|
|
\`\`\`
|
|
|
|
snippet ``r Codecell with language
|
|
\`\`\`{r}
|
|
${2:code}
|
|
\`\`\`
|
|
|
|
snippet pyfig2 Sub-Figures from python codecell
|
|
\`\`\`{python}
|
|
#| label: fig-${1:label}
|
|
#| fig-cap: "${2:caption}"
|
|
#| fig-subcap:
|
|
#| - "${3:subcap1}"
|
|
#| - "${3:subcap2}"
|
|
#| layout-ncol: 2
|
|
|
|
${0:code}
|
|
\`\`\`
|
|
|
|
snippet pyfig Figure from python codecell
|
|
\`\`\`{python}
|
|
#| label: fig-${1:label}
|
|
#| fig-cap: "${2:caption}"
|
|
|
|
${0:code}
|
|
\`\`\`
|
|
|
|
snippet fig General figure
|
|
{#fig-${2:label}}
|
|
|
|
snippet pytab Figure from python codecell
|
|
\`\`\`{python}
|
|
#| label: tbl-${1:label}
|
|
#| tbl-cap: "${2:caption}"
|
|
|
|
${0:code}
|
|
\`\`\`
|
|
|
|
snippet fref Figure crossref
|
|
@fig-${1:label}
|
|
snippet tref Table crossref
|
|
@tbl-${1:label}
|
|
snippet sref Section crossref
|
|
@sec-${1:label}
|
|
snippet eref Equation crossref
|
|
@eq-${1:label}
|
|
|
|
snippet cite Citation
|
|
[@${1:bib-key}]
|
|
|
|
snippet fn Footnote
|
|
[^${1:id}]
|
|
|
|
[^${1}]: ${2:text}
|
|
|
|
snippet shortcode Shortcode
|
|
{{< $0 >}}
|
|
|
|
snippet div Div block
|
|
::: {.${1:class}}
|
|
$0
|
|
:::
|
|
|
|
snippet note Callout note
|
|
::: {.callout-note}
|
|
$0
|
|
:::
|
|
snippet warn Callout warning
|
|
::: {.callout-warning}
|
|
$0
|
|
:::
|
|
snippet import Callout important
|
|
::: {.callout-important}
|
|
$0
|
|
:::
|
|
snippet tip Callout tip
|
|
::: {.callout-tip}
|
|
$0
|
|
:::
|
|
snippet caut Callout caution
|
|
::: {.callout-caution}
|
|
$0
|
|
:::
|