Skip to main content

max / quasi

Row::acts and Row::tokens, beside Row::primary The run replaced three members and primary got a method because every consumer wanted the same three lines back. Actions and tokens are in that same position: goingson wrote those lines twice in one file the day the members went away.
Author: Max Johnson <me@maxj.phd> · 2026-08-12 17:25 UTC
Signed with PGP, not checked
Commit: 4b4444dccf4e9c66b6986c48048aea342c91c93e
Parent: 9d176f1
2 files changed, +37 insertions, -8 deletions
M Cargo.lock +8 -8
@@ -5159,14 +5159,6 @@
5159 5159 source = "registry+https://github.com/rust-lang/crates.io-index"
5160 5160 checksum = "29666d0abbfad1e3dc4dcf6144730dd3a3ab225bbbdac83319345b1b44ccfc1b"
5161 5161
5162 - [[patch.unused]]
5163 - name = "synckit-client"
5164 - version = "0.8.0"
5165 -
5166 - [[patch.unused]]
5167 - name = "synckit-config"
5168 - version = "0.2.0"
5169 -
5170 5162 [[patch.unused]]
5171 5163 name = "kberg"
5172 5164 version = "0.1.0"
@@ -5178,3 +5170,11 @@
5178 5170 [[patch.unused]]
5179 5171 name = "tagtree"
5180 5172 version = "0.4.0"
5173 +
5174 + [[patch.unused]]
5175 + name = "synckit-client"
5176 + version = "0.8.0"
5177 +
5178 + [[patch.unused]]
5179 + name = "synckit-config"
5180 + version = "0.2.0"
@@ -1552,6 +1552,35 @@
1552 1552 .collect::<Vec<_>>()
1553 1553 .join(" ")
1554 1554 }
1555 +
1556 + /// The controls the row shows.
1557 + ///
1558 + /// The same service [`primary`](Self::primary) does, for the member the run
1559 + /// replaced. `actions` was a `Vec<Act>` before the run, and every consumer
1560 + /// that read it now writes the same three lines: filter the run by role,
1561 + /// match the one node kind that can be there, and collect. goingson wrote
1562 + /// them twice in one file the day the member went away.
1563 + ///
1564 + /// Not what the row *offers*: that is [`menu`](Self::menu), which is held
1565 + /// back until the host asks for it and is not on the line.
1566 + pub fn acts(&self) -> impl Iterator<Item = &Act> {
1567 + self.role(layout::RowPart::Actions)
1568 + .filter_map(|node| match node {
1569 + Node::Act(act) => Some(act),
1570 + _ => None,
1571 + })
1572 + }
1573 +
1574 + /// The tags the row shows.
1575 + ///
1576 + /// [`acts`](Self::acts)' counterpart, for the same reason.
1577 + pub fn tokens(&self) -> impl Iterator<Item = &Tag> {
1578 + self.role(layout::RowPart::Tokens)
1579 + .filter_map(|node| match node {
1580 + Node::Token(tag) => Some(tag),
1581 + _ => None,
1582 + })
1583 + }
1555 1584 }
1556 1585
1557 1586 /// One cell of a table row.