From db9c5e5d147159ef2ad4591f41fe21230d836545 Mon Sep 17 00:00:00 2001 From: PgBiel <9021226+PgBiel@users.noreply.github.com> Date: Mon, 13 Jan 2025 14:25:50 -0300 Subject: [PATCH] add mirror and license information --- README.md | 2 ++ docs/book/src/README.md | 4 ++++ docs/book/src/about/installation.md | 2 +- 3 files changed, 7 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 69ce1f8..946edd5 100644 --- a/README.md +++ b/README.md @@ -5,6 +5,8 @@ Framework for custom elements and types in Typst. **Supports Typst 0.11.0 or lat **Read the book:** https://pgbiel.github.io/elembic +**Mirrors:** [GitHub (pgbiel/elembic)](https://github.com/PgBiel/elembic); [Codeberg (pgbiel/elembic)](https://codeberg.org/PgBiel/elembic) + ## About Elembic lets you create **custom elements,** which are **reusable document components,** with support for **typechecked fields, show and set rules** (without using any `state` by default), **revoke and reset rules, reference and outline support,** and more. In addition, Elembic lets you create **custom types,** which also support **typechecked fields** but also **custom casting**, and can be used in element fields or by themselves in arbitrary Typst code. diff --git a/docs/book/src/README.md b/docs/book/src/README.md index 3f67600..0157c6b 100644 --- a/docs/book/src/README.md +++ b/docs/book/src/README.md @@ -25,3 +25,7 @@ Elembic ships with a **considerably flexible type system** through its `types` m Not only does Elembic support **using and combining Typst-native types** (e.g. a field can take `e.types.union(int, stroke)` to support integers or strokes), but it also supports **declaring your own custom, nominal types**. They are represented as dictionaries, but **are strongly-typed,** such that a dictionary with the same fields won't cast to your custom type and vice-versa by default (unless you specify otherwise). For example, a data type representing a `person` won't cast to another type `owner` even if they share the same fields. Custom types optionally support **arbitrary casting from other types.** For example, you may allow automatic casts from integers and floats to your custom type. This is mostly useful when creating "ad-hoc" types for certain elements with fully customized behavior. You can read more in the ["Custom types" chapter](./types/custom-types/.). + +## License + +Elembic is licensed under MIT or Apache-2.0, at your option. diff --git a/docs/book/src/about/installation.md b/docs/book/src/about/installation.md index 1c12ca6..94ca24b 100644 --- a/docs/book/src/about/installation.md +++ b/docs/book/src/about/installation.md @@ -4,7 +4,7 @@ Currently, Elembic must be installed **as a local package** (or by **copying it To install Elembic as a local package in your system, see [https://github.com/typst/packages?tab=readme-ov-file#local-packages](https://github.com/typst/packages?tab=readme-ov-file#local-packages) for instructions. -In particular, it involves downloading Elembic's files from [https://github.com/PgBiel/elembic](https://github.com/PgBiel/elembic) and copying it to `$LOCAL_PACKAGES_DIR/elembic/0.0.1`. +In particular, it involves downloading Elembic's files from either [GitHub (pgbiel/elembic)](https://github.com/PgBiel/elembic) or [Codeberg (pgbiel/elembic)](https://codeberg.org/PgBiel/elembic) and then copying it to `$LOCAL_PACKAGES_DIR/elembic/0.0.1`. If you're using a Linux platform, there is the following one-liner command to install the latest development version (note: does not remove a prior installation):