Version bump

This commit is contained in:
Laurenz 2023-05-20 21:56:19 +02:00
parent 1321862cd5
commit f692a5efc6
8 changed files with 61 additions and 61 deletions

12
Cargo.lock generated
View File

@ -2173,7 +2173,7 @@ checksum = "6af6ae20167a9ece4bcb41af5b80f8a1f1df981f6391189ce00fd257af04126a"
[[package]] [[package]]
name = "typst" name = "typst"
version = "0.3.0" version = "0.4.0"
dependencies = [ dependencies = [
"bitflags 2.3.1", "bitflags 2.3.1",
"bytemuck", "bytemuck",
@ -2213,7 +2213,7 @@ dependencies = [
[[package]] [[package]]
name = "typst-cli" name = "typst-cli"
version = "0.3.0" version = "0.4.0"
dependencies = [ dependencies = [
"atty", "atty",
"chrono", "chrono",
@ -2243,7 +2243,7 @@ dependencies = [
[[package]] [[package]]
name = "typst-docs" name = "typst-docs"
version = "0.3.0" version = "0.4.0"
dependencies = [ dependencies = [
"comemo", "comemo",
"heck", "heck",
@ -2262,7 +2262,7 @@ dependencies = [
[[package]] [[package]]
name = "typst-library" name = "typst-library"
version = "0.3.0" version = "0.4.0"
dependencies = [ dependencies = [
"az", "az",
"chinese-number", "chinese-number",
@ -2295,7 +2295,7 @@ dependencies = [
[[package]] [[package]]
name = "typst-macros" name = "typst-macros"
version = "0.3.0" version = "0.4.0"
dependencies = [ dependencies = [
"heck", "heck",
"proc-macro2", "proc-macro2",
@ -2305,7 +2305,7 @@ dependencies = [
[[package]] [[package]]
name = "typst-tests" name = "typst-tests"
version = "0.3.0" version = "0.4.0"
dependencies = [ dependencies = [
"clap 4.2.7", "clap 4.2.7",
"comemo", "comemo",

View File

@ -1,23 +1,9 @@
[package]
name = "typst"
version = "0.3.0"
rust-version = "1.65"
authors = ["The Typst Project Developers"]
edition = "2021"
description = "A new markup-based typesetting system that is powerful and easy to learn."
homepage = "https://typst.app"
repository = "https://github.com/typst/typst"
readme = "README.md"
license = "Apache-2.0"
categories = ["compilers", "science"]
keywords = ["markup", "typesetting"]
[workspace] [workspace]
members = ["cli", "docs", "library", "macros", "tests"] members = ["cli", "docs", "library", "macros", "tests"]
default-members = ["cli"] default-members = ["cli"]
[workspace.package] [workspace.package]
version = "0.3.0" version = "0.4.0"
rust-version = "1.65" rust-version = "1.65"
authors = ["The Typst Project Developers"] authors = ["The Typst Project Developers"]
edition = "2021" edition = "2021"
@ -25,8 +11,19 @@ homepage = "https://typst.app"
repository = "https://github.com/typst/typst" repository = "https://github.com/typst/typst"
readme = "README.md" readme = "README.md"
license = "Apache-2.0" license = "Apache-2.0"
[package]
name = "typst"
description = "A new markup-based typesetting system that is powerful and easy to learn."
categories = ["compilers", "science"] categories = ["compilers", "science"]
keywords = ["typst"] keywords = ["markup", "typesetting"]
version.workspace = true
rust-version.workspace = true
authors.workspace = true
edition.workspace = true
homepage.workspace = true
repository.workspace = true
license.workspace = true
[lib] [lib]
doctest = false doctest = false

View File

@ -1,15 +1,15 @@
[package] [package]
name = "typst-cli" name = "typst-cli"
description = "The command line interface for Typst."
categories = ["compilers", "command-line-utilities"]
keywords = ["typst", "cli"]
version.workspace = true version.workspace = true
rust-version.workspace = true rust-version.workspace = true
authors.workspace = true authors.workspace = true
edition.workspace = true edition.workspace = true
description = "The command line interface for Typst."
homepage.workspace = true homepage.workspace = true
repository.workspace = true repository.workspace = true
license.workspace = true license.workspace = true
categories = ["compilers", "command-line-utilities"]
keywords = ["typst", "cli"]
[[bin]] [[bin]]
name = "typst" name = "typst"

View File

@ -5,7 +5,7 @@ description: |
--- ---
# Changelog # Changelog
## Unreleased ## Version 0.4.0 (May 20, 2023) { #v0.4.0 }
- Footnotes - Footnotes
- Implemented support for footnotes - Implemented support for footnotes
- The [`footnote`]($func/footnote) function inserts a footnote - The [`footnote`]($func/footnote) function inserts a footnote
@ -14,11 +14,11 @@ description: |
- The `{"chicago-notes"}` [citation style]($func/cite.style) is now available - The `{"chicago-notes"}` [citation style]($func/cite.style) is now available
- Documentation - Documentation
- Added [guide for LaTeX users]($guides/guide-for-latex-users) - Added a [Guide for LaTeX users]($guides/guide-for-latex-users)
- Now shows default values for optional arguments - Now shows default values for optional arguments
- Added richer outlines in "On this Page" - Added richer outlines in "On this Page"
- Added initial support for search keywords: "Table of Contents" will now find - Added initial support for search keywords: "Table of Contents" will now find
the [outline]($func/outline) function, suggestions for more keywords are the [outline]($func/outline) function. Suggestions for more keywords are
welcome! welcome!
- Fixed issue with search result ranking - Fixed issue with search result ranking
- Fixed many more small issues - Fixed many more small issues
@ -40,13 +40,17 @@ description: |
- Scripting - Scripting
- Added function scopes: A function can now hold related definitions in its - Added function scopes: A function can now hold related definitions in its
own scope, similar to a module. The new [`assert.eq`]($func/assert.eq), for own scope, similar to a module. The new [`assert.eq`]($func/assert.eq)
instance, is part of the [`assert`]($func/assert) scopes. function, for instance, is part of the [`assert`]($func/assert) function's
scope. Note that function scopes are currently only available for built-in
functions.
- Added [`assert.eq`]($func/assert.eq) and [`assert.ne`]($func/assert.ne) - Added [`assert.eq`]($func/assert.eq) and [`assert.ne`]($func/assert.ne)
functions for simpler equality and inequality assertions with more helpful functions for simpler equality and inequality assertions with more helpful
error messages error messages
- The `at` method on [strings]($type/string.at), [arrays]($type/array.at), - Exposed [list]($func/list.item), [enum]($func/enum.item), and
[dictionaries]($type/dict.at), and [content]($type/content.at) now supports [term list]($func/terms.item) items in their respective functions' scope
- The `at` methods on [strings]($type/string.at), [arrays]($type/array.at),
[dictionaries]($type/dict.at), and [content]($type/content.at) now support
specifying a default value specifying a default value
- Added support for passing a function to [`replace`]($type/string.replace) - Added support for passing a function to [`replace`]($type/string.replace)
that is called with each match. that is called with each match.
@ -66,36 +70,35 @@ description: |
- Fixed [alignment]($func/raw.align) of text inside raw blocks (centering a - Fixed [alignment]($func/raw.align) of text inside raw blocks (centering a
raw block, e.g. through a figure, will now keep the text itself raw block, e.g. through a figure, will now keep the text itself
left-aligned) left-aligned)
- Added support for passing a per-column array instead of a function to - Added support for passing a array instead of a function to configure table
configure table cell [alignment]($func/table.align) and cell [alignment]($func/table.align) and [fill]($func/table.fill) per column
[fill]($func/table.fill)
- Fixed automatic figure [`kind`]($func/figure.kind) detection - Fixed automatic figure [`kind`]($func/figure.kind) detection
- Made alignment of [enum numbers]($func/enum.number-align) configurable, - Made alignment of [enum numbers]($func/enum.number-align) configurable,
defaulting to `end` defaulting to `end`
- Fixed show-set rules for blocks in figures - Figures can now be made breakable with a show-set rule for blocks in figure
- Initial fix for smart quotes for RTL languages - Initial fix for smart quotes in RTL languages
- Export - Export
- Fixed ligatures in PDF export: They are now copyable and searchable - Fixed ligatures in PDF export: They are now copyable and searchable
- Exported PDFs now embeds ICC profiles for images that have them - Exported PDFs now embed ICC profiles for images that have them
- Fixed export of strokes with zero thickness - Fixed export of strokes with zero thickness
- Web app - Web app
- Projects can now contain folders - Projects can now contain folders
- Added upload by drag and drop into the file panel - Added upload by drag-and-drop into the file panel
- Files from the file panel can now be dragged into the editor to insert them - Files from the file panel can now be dragged into the editor to insert them
in a Typst file into a Typst file
- You can now copy-paste images and other files from your computer directly - You can now copy-paste images and other files from your computer directly
into the editor into the editor
- Added button to resend confirmation email - Added a button to resend confirmation email
- Added option to invert preview colors in dark mode - Added an option to invert preview colors in dark mode
- Added tips to the loading screen and the Help menu. Feel free to submit - Added tips to the loading screen and the Help menu. Feel free to propose
more! more!
- Added syntax highlighting for YAML files - Added syntax highlighting for YAML files
- Allow middle mouse button click on many buttons to navigate in a new tab - Allowed middle mouse button click on many buttons to navigate into a new tab
- Allow more project names - Allowed more project names
- Fix overridden Vim mode keybindings - Fixed overridden Vim mode keybindings
- Many bugfixes regarding file upload and more - Fixed many bugs regarding file upload and more
- Miscellaneous Improvements - Miscellaneous Improvements
- Improved performance of counters, state, and queries - Improved performance of counters, state, and queries
@ -105,6 +108,8 @@ description: |
- For users of the `typst` crate: The `Document` is now `Sync` again and - For users of the `typst` crate: The `Document` is now `Sync` again and
the `World` doesn't have to be `'static` anymore the `World` doesn't have to be `'static` anymore
<contributors from="v0.3.0" to="v0.4.0" />
## Version 0.3.0 (April 26, 2023) { #v0.3.0 } ## Version 0.3.0 (April 26, 2023) { #v0.3.0 }
- **Breaking changes:** - **Breaking changes:**
- Renamed a few symbols: What was previous `dot.op` is now just `dot` and the - Renamed a few symbols: What was previous `dot.op` is now just `dot` and the

View File

@ -832,6 +832,12 @@ kind. In contrast to normal functions, they can further be used in
[set rules]($styling/#set-rules), [show rules]($styling/#show-rules), and [set rules]($styling/#set-rules), [show rules]($styling/#show-rules), and
[selectors]($type/selector). [selectors]($type/selector).
### Function scopes { #function-scopes }
Functions can hold related definitions in their own scope, similar to a
[module]($scripting/#modules). Examples of this are
[`assert.eq`]($func/assert.eq) or [`list.item`]($func/list.item). However, this
feature is currently only available for built-in functions.
### Defining functions { #definitions } ### Defining functions { #definitions }
You can define your own function with a You can define your own function with a
[let binding]($scripting/#bindings) that has a parameter list after [let binding]($scripting/#bindings) that has a parameter list after

View File

@ -1,14 +1,15 @@
[package] [package]
name = "typst-library" name = "typst-library"
description = "The standard library for Typst."
categories = ["compilers", "science"]
keywords = ["typst"]
version.workspace = true version.workspace = true
rust-version.workspace = true rust-version.workspace = true
authors.workspace = true authors.workspace = true
edition.workspace = true edition.workspace = true
description = "The standard library for Typst."
homepage.workspace = true homepage.workspace = true
repository.workspace = true repository.workspace = true
license.workspace = true license.workspace = true
keywords.workspace = true
[lib] [lib]
test = false test = false

View File

@ -95,21 +95,13 @@ pub struct FigureElem {
/// automatic detection. This can be useful if /// automatic detection. This can be useful if
/// - you wish to create a custom figure type that is not an /// - you wish to create a custom figure type that is not an
/// [image]($func/image), a [table]($func/table) or [code]($func/raw), /// [image]($func/image), a [table]($func/table) or [code]($func/raw),
/// - you want to force the figure to use a counter regardless of its /// - you want to force the figure to use a specific counter regardless of
/// content. /// its content.
/// ///
/// You can set the kind to be an element function or a string. If you set /// You can set the kind to be an element function or a string. If you set
/// it to an element function that is not supported by the figure, you will /// it to an element function that is not supported by the figure, you will
/// need to manually specify the figure's supplement. /// need to manually specify the figure's supplement.
/// ///
/// The figure's automatic detection is based on a priority list to select
/// the element that is likely to be the most important one. If the figure's
/// body contains multiple valid elements, the one with the highest priority
/// is selected. The priority list is as follows:
/// - [image]($func/image) is the most important,
/// - [code]($func/raw) is the second most important,
/// - [table]($func/table) is the least important one.
///
/// ```example /// ```example
/// #figure( /// #figure(
/// circle(radius: 10pt), /// circle(radius: 10pt),

View File

@ -1,14 +1,13 @@
[package] [package]
name = "typst-macros" name = "typst-macros"
description = "Proc-macros for Typst."
version.workspace = true version.workspace = true
rust-version.workspace = true rust-version.workspace = true
authors.workspace = true authors.workspace = true
edition.workspace = true edition.workspace = true
description = "Proc-macros for Typst."
homepage.workspace = true homepage.workspace = true
repository.workspace = true repository.workspace = true
license.workspace = true license.workspace = true
keywords.workspace = true
[lib] [lib]
proc-macro = true proc-macro = true