Export Plot from its own Plot/module.zi

plot/Plot now resolves by its file in builds that name --module-path
plot=DIR as well as in projects, like PlotWidget.
This commit is contained in:
waozi committed 2026-10-18 22:33:13 -03:00
1 parent 4e5223e85a
commit 0d8ddc29ed
4 files changed
+6 -4

No files matched your search

+3 -1
View File
@@ -13,7 +13,9 @@ Install the Ziran launcher once with `make install-user` in Ziran, then run
`ziran fetch` and `make build` here. `make run` opens a small demo on the Cairo
backend; `make check` checks the source and runs the nonvisual indicator test.
The checked-in `ziran.lock` pins both Ziran and Kryon to exact commits. Plot
exports `src/module.zi` for other packages. That module re-exports Plot's
exports `src/Plot/module.zi` for other packages, so `plot/Plot` resolves by
its file both in projects and in builds that name `--module-path plot=DIR`.
That module re-exports Plot's
charts and Kryon's public UI surface; app code can use
`using Charts :: #import "Plot";`.
File renamed without changes.
+1 -1
View File
@@ -1,4 +1,4 @@
using Charts :: #import "module";
using Charts :: #import "Plot";
#program_export
Frame :: (session: Session, viewport: Rectangle) -> s32 {
+2 -2
View File
@@ -14,8 +14,8 @@ ref = "master"
[exports]
# Public module is Plot; the lowercase export is retained for older imports.
plot = "src/module.zi"
Plot = "src/module.zi"
plot = "src/Plot/module.zi"
Plot = "src/Plot/module.zi"
# The chart surface alone, for apps that draw their own series.
PlotWidget = "src/PlotWidget/module.zi"