summaryrefslogtreecommitdiff
path: root/library/src/basics
diff options
context:
space:
mode:
authorLaurenz <laurmaedje@gmail.com>2022-12-17 16:24:29 +0100
committerLaurenz <laurmaedje@gmail.com>2022-12-17 16:24:29 +0100
commit35b16e545b4fce299edbc00c9a9754179fa51634 (patch)
treeeb1081e55187e59ff6482abc1ac2f1932606ef59 /library/src/basics
parentb6202b646a0d5ecced301d9bac8bfcaf977d7ee4 (diff)
Document parameters in comment
Diffstat (limited to 'library/src/basics')
-rw-r--r--library/src/basics/heading.rs9
-rw-r--r--library/src/basics/list.rs12
-rw-r--r--library/src/basics/table.rs17
3 files changed, 35 insertions, 3 deletions
diff --git a/library/src/basics/heading.rs b/library/src/basics/heading.rs
index 60415697..2781034e 100644
--- a/library/src/basics/heading.rs
+++ b/library/src/basics/heading.rs
@@ -7,7 +7,14 @@ use crate::text::{SpaceNode, TextNode, TextSize};
/// A section heading.
///
-/// Tags: basics.
+/// # Parameters
+/// - body: Content (positional, required)
+/// The heading's contents.
+/// - level: NonZeroUsize (named)
+/// The logical nesting depth of the heading, starting from one.
+///
+/// # Tags
+/// - basics
#[func]
#[capable(Prepare, Show, Finalize)]
#[derive(Debug, Hash)]
diff --git a/library/src/basics/list.rs b/library/src/basics/list.rs
index 4c016128..c9215a50 100644
--- a/library/src/basics/list.rs
+++ b/library/src/basics/list.rs
@@ -5,7 +5,17 @@ use crate::text::{SpaceNode, TextNode};
/// An unordered (bulleted) or ordered (numbered) list.
///
-/// Tags: basics.
+/// # Parameters
+/// - items: Content (positional, variadic)
+/// The contents of the list items.
+/// - start: NonZeroUsize (named)
+/// Which number to start the enumeration with.
+/// - tight: bool (named)
+/// Makes the list more compact, if enabled. This looks better if the items
+/// fit into a single line each.
+///
+/// # Tags
+/// - basics
#[func]
#[capable(Layout)]
#[derive(Debug, Hash)]
diff --git a/library/src/basics/table.rs b/library/src/basics/table.rs
index 10a9143f..d7e2e08f 100644
--- a/library/src/basics/table.rs
+++ b/library/src/basics/table.rs
@@ -3,7 +3,22 @@ use crate::prelude::*;
/// A table of items.
///
-/// Tags: basics.
+/// # Parameters
+/// - cells: Content (positional, variadic)
+/// The contents of the table cells.
+/// - rows: TrackSizings (named)
+/// Defines the row sizes.
+/// - columns: TrackSizings (named)
+/// Defines the column sizes.
+/// - gutter: TrackSizings (named)
+/// Defines the gaps between rows & columns.
+/// - column-gutter: TrackSizings (named)
+/// Defines the gaps between columns. Takes precedence over `gutter`.
+/// - row-gutter: TrackSizings (named)
+/// Defines the gaps between rows. Takes precedence over `gutter`.
+///
+/// # Tags
+/// - basics
#[func]
#[capable(Layout)]
#[derive(Debug, Hash)]