Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 9 additions & 10 deletions crates/typst-library/src/math/matrix.rs
Original file line number Diff line number Diff line change
Expand Up @@ -216,11 +216,11 @@ pub struct MatElem {
pub rows: Vec<Vec<Content>>,
}

/// A case distinction.
/// 場合分け。
///
/// Content across different branches can be aligned with the `&` symbol.
/// `&`記号を用いると異なる分岐に属するコンテンツを整列できます。
///
/// # Example
/// #
/// ```example
/// $ f(x, y) := cases(
/// 1 "if" (x dot y)/2 <= 0,
Expand All @@ -231,11 +231,10 @@ pub struct MatElem {
/// ```
#[elem(Mathy)]
pub struct CasesElem {
/// The delimiter to use.
/// 使用する区切り文字。
///
/// Can be a single character specifying the left delimiter, in which case
/// the right delimiter is inferred. Otherwise, can be an array containing a
/// left and a right delimiter.
/// 一文字の場合は、右区切り文字を推論可能な左区切り文字を指定できます。
/// それ以外の場合は、左右の区切り文字を有する配列が指定可能です。
Copy link

Copilot AI Jul 25, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[nitpick] 「有する」は硬い表現です。「含む」または「を持つ」の方が自然な日本語になります。

Suggested change
/// それ以外の場合は、左右の区切り文字を有する配列が指定可能です
/// それ以外の場合は、左右の区切り文字を含む配列が指定可能です

Copilot uses AI. Check for mistakes.
///
/// ```example
/// #set math.cases(delim: "[")
Expand All @@ -244,7 +243,7 @@ pub struct CasesElem {
#[default(DelimiterPair::BRACE)]
pub delim: DelimiterPair,

/// Whether the direction of cases should be reversed.
/// 場合分けの向きを反転させるかどうか。
///
/// ```example
/// #set math.cases(reverse: true)
Expand All @@ -253,7 +252,7 @@ pub struct CasesElem {
#[default(false)]
pub reverse: bool,

/// The gap between branches.
/// 分岐間の間隔。
///
/// ```example
/// #set math.cases(gap: 1em)
Expand All @@ -263,7 +262,7 @@ pub struct CasesElem {
#[default(DEFAULT_ROW_GAP.into())]
pub gap: Rel<Length>,

/// The branches of the case distinction.
/// 場合分けで分岐させる子要素。
#[variadic]
pub children: Vec<Content>,
}
Expand Down
2 changes: 1 addition & 1 deletion website/translation-status.json
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@
"/docs/reference/math/attach/": "untranslated",
"/docs/reference/math/binom/": "untranslated",
"/docs/reference/math/cancel/": "untranslated",
"/docs/reference/math/cases/": "untranslated",
"/docs/reference/math/cases/": "translated",
"/docs/reference/math/class/": "untranslated",
"/docs/reference/math/equation/": "translated",
"/docs/reference/math/frac/": "translated",
Expand Down