luxe 0.1.4: remembered models, wheel-driven lists, and a steadier phone app

- luxe starts on the model you last chose in this project, then the last one anywhere. Signing in
  opens the model picker instead of choosing for you.
- Every list in a modal takes the mouse wheel and a draggable scrollbar.
- The phone app shows reasoning in full, stays put while you read back through a long session, and
  shows a question's answer on its card.
- On Windows, luxe update replaces the running luxe, and a signed-in install no longer sees setup
  again.
- The file tree no longer shows "engine busy" in a large project, loop output is easier to follow,
  and the name is written lowercase.

The CHANGELOG has the full list.
This commit is contained in:
Evan Whittaker
2026-10-20 13:51:34 -05:00
parent 6184aa21fb
commit a0666d6c81
591 changed files with 4926 additions and 2942 deletions

View File

@@ -8,7 +8,7 @@ pub(super) fn hex(color: Color) -> Option<String> {
Color::Rgb(red, green, blue) => (red, green, blue),
Color::Indexed(index) => indexed_rgb(index),
Color::Reset => return None,
// The sixteen named colors belong to the terminal's palette. Luxe's own themes are pure
// The sixteen named colors belong to the terminal's palette. luxe's own themes are pure
// RGB, so this is only reached by a user theme; xterm's defaults are the least surprising
// stand-in available.
named => indexed_rgb(named_index(named)?),

View File

@@ -123,7 +123,7 @@ fn block_element(block: &Block, x: f64, y: f64, fill: &str) -> String {
/// Which cell edges a box-drawing glyph reaches, and whether its corner is rounded.
///
/// `(up, right, down, left)`. Only the light set: it is what Luxe draws with, and a heavy or double
/// `(up, right, down, left)`. Only the light set: it is what luxe draws with, and a heavy or double
/// rule would need its own stroke width rather than a flag here.
type Arms = (bool, bool, bool, bool);

View File

@@ -1,6 +1,6 @@
//! fixture_svg — a production render, exported as vector.
//!
//! The site needs pictures of Luxe, and a screenshot is the worst way to get one: it is a raster at
//! The site needs pictures of luxe, and a screenshot is the worst way to get one: it is a raster at
//! somebody's DPI, its text cannot be selected or searched, it weighs ten times what it should, and
//! it puts a terminal and a font in the pipeline where neither belongs. The render is already a
//! grid of glyphs and colors, so it can be drawn directly.

View File

@@ -76,7 +76,7 @@ fn cell_fraction_glyphs_are_drawn_not_typeset() {
for glyph in ['\u{e0b8}', '\u{e0ba}', '\u{e0bc}', '\u{e0be}'] {
assert!(is_drawn(glyph), "U+{:04X} should be geometry", glyph as u32);
}
// Letters and the geometric shapes Luxe uses as marks stay text: any font has them, and
// Letters and the geometric shapes luxe uses as marks stay text: any font has them, and
// they carry meaning that should remain selectable.
for glyph in ['a', '\u{276f}', '\u{25cf}', '\u{25c6}'] {
assert!(!is_drawn(glyph), "U+{:04X} should be typeset", glyph as u32);

View File

@@ -1,7 +1,7 @@
//! shiki_theme — luxe's palette as a syntax theme for the website's code blocks.
//!
//! The docs describe a terminal program; highlighting their code in somebody else's palette is a
//! small lie about what Luxe looks like. This writes a TextMate theme from the same JSON the TUI
//! small lie about what luxe looks like. This writes a TextMate theme from the same JSON the TUI
//! loads, so the code on the page is colored by the product's own tokens.
//!
//! It is also the palette's hardest test. A theme with six accents can hide a weak one behind a
@@ -32,7 +32,7 @@ fn theme_json(name: &str, theme: &HashMap<String, ColorValue>) -> String {
let hex = |token: &str| -> String {
match theme.get(token) {
Some(ColorValue::Rgb(red, green, blue)) => format!("#{red:02x}{green:02x}{blue:02x}"),
// Every token this maps is RGB in Luxe's own themes; anything else would be a theme
// Every token this maps is RGB in luxe's own themes; anything else would be a theme
// this generator was not written for, and inventing a color would hide that.
_ => panic!("{name}.{token} is not an RGB color"),
}

View File

@@ -96,7 +96,7 @@ fn stylesheet(dark: &HashMap<String, ColorValue>) -> String {
out.push_str(":root {\n color-scheme: dark;\n");
out.push_str(&block(dark, true));
// The canvas a baked-in capture sits on. A recording is the terminal's own background in every
// cell Luxe paints, so a plate in any other color turns the painted cells into rectangles; with
// cell luxe paints, so a plate in any other color turns the painted cells into rectangles; with
// one theme on the page these are the page's own colors, named for what they are for.
let _ = writeln!(
out,
@@ -178,7 +178,7 @@ mod tests {
/// Every exported token reaches the stylesheet. A token that resolves to an ANSI index or the
/// terminal default has no hex to give, which is fine in a terminal and useless on a page — so
/// Luxe's own theme must not contain one.
/// luxe's own theme must not contain one.
#[test]
fn every_exported_token_has_a_color() {
let dark = luxe();

View File

@@ -25,7 +25,7 @@ fn main() -> Result<()> {
}
let mut app = seeded_app(&theme, scenario).map_err(anyhow::Error::msg)?;
// `LUXE_FIXTURE_DESKTOP=<name>` paints the frame in an Omarchy theme from this machine, turned
// into Luxe's the way a session following the desktop does, so a theme no built-in matches can
// into luxe's the way a session following the desktop does, so a theme no built-in matches can
// be judged without applying it
if let Ok(name) = env::var("LUXE_FIXTURE_DESKTOP") {
app.theme_styles = desktop_styles(&name)?;
@@ -42,7 +42,7 @@ fn main() -> Result<()> {
}
let scenario_name = scenario.name();
execute!(io::stdout(), SetTitle(format!("Luxe fixture: {scenario_name}")))?;
execute!(io::stdout(), SetTitle(format!("luxe fixture: {scenario_name}")))?;
let mut terminal = terminal::init()?;
let result = run(&mut terminal, &mut app);
terminal::restore()?;
@@ -400,7 +400,7 @@ fn desktop_styles(name: &str) -> Result<luxe_tui::theme::styles::ThemeStyles> {
let desktop = luxe_core::omarchy::DesktopTheme { name: name.to_owned(), dir };
let registry = luxe_core::theme::ThemeRegistry::new().with_desktop(Some(&desktop));
let Some(resolved) = registry.resolve(luxe_core::omarchy::DESKTOP_THEME) else {
bail!("{name} has no colors Luxe can read")
bail!("{name} has no colors luxe can read")
};
Ok(luxe_tui::theme::styles::ThemeStyles::from_resolved(&resolved, name))
}

View File

@@ -84,8 +84,8 @@ fn tile(rows: &[&str], (plate_color, ink): (String, String)) -> String {
format!(
"<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 {side} {side}\" \
width=\"{side}\" height=\"{side}\" role=\"img\" aria-label=\"Luxe\">\n \
<title>Luxe</title>\n \
width=\"{side}\" height=\"{side}\" role=\"img\" aria-label=\"luxe\">\n \
<title>luxe</title>\n \
<path fill=\"{plate_color}\" d=\"{plate}\"/>\n \
<g transform=\"translate({offset_x:.2} {TILE_PAD}) scale({scale:.4})\">\n \
<path fill=\"{ink}\" d=\"{letter}\"/>\n \
@@ -111,9 +111,9 @@ fn svg(rows: &[&str], letters: std::ops::Range<usize>) -> String {
out.push_str(&format!(
"<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"{left} 0 {width} {height}\" \
width=\"{width}\" height=\"{height}\" data-cell=\"{CELL_W} {CELL_H}\" \
role=\"img\" aria-label=\"Luxe\">\n"
role=\"img\" aria-label=\"luxe\">\n"
));
out.push_str(" <title>Luxe</title>\n");
out.push_str(" <title>luxe</title>\n");
for (index, path) in paths.iter().enumerate() {
let step = index + letters.start + 1;
out.push_str(&format!(
@@ -293,7 +293,7 @@ mod tests {
assert!(svg.trim_end().ends_with("</svg>"));
assert_eq!(svg.matches("<path").count(), 4, "one path per letter");
assert!(svg.contains("--luxe-wordmark-1"), "letters are themable from CSS");
assert!(svg.contains("aria-label=\"Luxe\""));
assert!(svg.contains("aria-label=\"luxe\""));
assert!(svg.contains("data-cell=\"10 22\""), "the grid the highlight is drawn in");
}