From 56da5dcbdff449ac1128f9ca62fd575bce36130a Mon Sep 17 00:00:00 2001 From: "Y.D.X." <73375426+YDX-2147483647@users.noreply.github.com> Date: Wed, 25 Oct 2023 22:34:56 +0800 Subject: [PATCH] Improve documentation a bit MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Fix typos. - _phyiscs_ → _physica_ - _ingore_ → _ignore_ - Enable syntax highlighting for raw/code blocks. Note that I didn't touch inline `#hl(…)`, because they look better than typst's builtin. - Replace a Typst's repo URL to doc URL. The repo link is broken due to a refactor, and I guess it's https://github.com/typst/typst/blob/a7fbe5151e3feed933a6f66ed946e8e9ed30795a/crates/typst-library/src/math/op.rs now. --- README.md | 2 +- physica-manual.typ | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index ab531fa..88f028c 100644 --- a/README.md +++ b/README.md @@ -32,7 +32,7 @@ See the [manual](https://github.com/Leedehai/typst-physics/blob/master/physica-m ![demo](https://user-images.githubusercontent.com/18319900/236073825-e91b4601-7e92-490b-a7e4-e9e405a2147b.png) -## Using phyiscs in your Typst document +## Using physica in your Typst document ### With `typst` package management (recommended) diff --git a/physica-manual.typ b/physica-manual.typ index c125729..3d14399 100644 --- a/physica-manual.typ +++ b/physica-manual.typ @@ -54,7 +54,7 @@ With `typst`'s #linkurl("package management", "https://github.com/typst/packages #import "physica.typ": * -``` +```typst #import "@preview/physica:0.8.0": * $ curl (grad f), tensor(T, -mu, +nu), pdv(f,x,y,[1,2]) $ @@ -422,7 +422,7 @@ xmat(2, 2, #g)`) #v(1em) -Typst built-in math operators: #linkurl("source code", "https://github.com/typst/typst/blob/main/library/src/math/op.rs"). +Typst built-in math operators: #linkurl(`math.op`, "https://typst.app/docs/reference/math/op/"). #table( columns: (auto, auto), @@ -877,7 +877,7 @@ Function: `signals(str`, `step:`:..., `style`:...`)`. [`X` \ $ signals("X") $], [], - [ingore: (blankspace) \ separate: `&`], + [ignore: (blankspace) \ separate: `&`], [repeat: `.` (dot)], ) @@ -896,7 +896,7 @@ $ signals("-|=|-", step: #2em), signals("-|#|-"), signals("-<=>-<=") $ $ signals("R1..F0..", step: #.5em)signals("R1.|v|1", step: #.5em, color:#fuchsia) $ *(5)* -``` +```typst "clk:" & signals("|1....|0....|1....|0....|1....|0....|1....|0..", step: #0.5em) \ "bus:" & signals(" #.... X=... ..... ..... X=... ..... ..... X#.", step: #0.5em) ```