Merge pull request #10593 from ruchirguitar/feat/g12-svg-interactivity-menu

SVG Interactivity: add a context menu to event rows
This commit is contained in:
BFlat authored and GitHub committed 2026-12-04 09:31:06 +07:00
commit d215702b56
3 files changed
+199 -19

No files matched your search

+192 -17
View File
@@ -4,6 +4,9 @@
//! objects' events, and a click on one picks it to edit. Remove Selected Entry
//! (`svgInteractivity.removeEvent`) and the panel menu's Clear Events (`svgInteractivity.clearEvents`)
//! remove them; Link JavaScript Files… opens the JavaScript Files dialog (`ui.javascriptFilesDialog`).
//! A right-click on an event row (or Shift+F10 on the focused row) picks that event and opens its
//! menu: Remove Event, Clear Events and Link JavaScript Files…, the same commands as the footer and
//! the panel menu.
//! Everything reads `svgInteractivity.info`.
use std::hash::{DefaultHasher, Hash, Hasher};
@@ -17,7 +20,7 @@ use craft::ui::display::{Shade, Text};
use craft::ui::form::Field;
use craft::ui::layout_components::Stack;
use craft::ui::list::{List, ListRow};
use craft::ui::menu::PanelRow;
use craft::ui::menu::{Menu, MenuItem, PanelRow};
use craft::ui::pickers::Select;
use craft::ui::primitives::SubmitKey;
use craft::ui::runtime::commands::{CommandState, CommandStates};
@@ -35,6 +38,13 @@ pub const ID: &str = "svgInteractivity";
/// The engine command of the panel menu's one row.
const CLEAR_EVENTS: &str = "svgInteractivity.clearEvents";
/// What the footer or a row's menu picked, run once the list is drawn.
#[derive(Clone, Copy)]
enum RowAction {
Clear,
LinkFiles,
}
/// The SVG Interactivity panel's own state, kept while the app runs.
#[derive(Clone, Debug, Default)]
pub(crate) struct SvgInteractivityPanel {
@@ -51,8 +61,8 @@ pub(crate) struct Info {
script_target: Option<egui::IdSalt>,
}
/// What [`info`] was read for: drawing (uid and File Revert count), revision, and selection size and ends.
pub(crate) type SelKey = ((u64, u64), u64, usize, Option<NodeId>, Option<NodeId>);
/// What [`info`] was read for: drawing (uid and File Revert count), revision, and selected objects.
pub(crate) type SelKey = ((u64, u64), u64, Vec<NodeId>);
/// A side label's text without its colon: the label draws the colon itself
/// (`CommonWords::caption`), so the catalog's "Event:" keeps its translation here.
@@ -61,16 +71,11 @@ pub(crate) fn caption(label: &'static str) -> &'static str {
crate::i18n::t(label).trim_end_matches(':')
}
fn sel_key(app: &VectorcraftApp) -> Option<SelKey> {
let st = app.session.active()?;
let sel = &st.selection.objects;
Some(((st.uid, st.reverts), st.revision, sel.len(), sel.first().copied(), sel.last().copied()))
}
/// The memoized [`Info`] when it was read for the current document and selection.
fn cached(app: &VectorcraftApp) -> Option<&Info> {
let key = sel_key(app)?;
app.canvas.svg_info.as_ref().filter(|(k, _)| *k == key).map(|(_, v)| v)
let st = app.session.active()?;
let (((uid, reverts), revision, selection), info) = app.canvas.svg_info.as_ref()?;
(*uid == st.uid && *reverts == st.reverts && *revision == st.revision && selection == &st.selection.objects).then_some(info)
}
/// `svgInteractivity.info`, read again only when the document or the selection changes.
@@ -78,7 +83,8 @@ pub(crate) fn info(app: &mut VectorcraftApp) -> Info {
if let Some(v) = cached(app) {
return v.clone();
}
let Some(key) = sel_key(app) else { return Info::default() };
let Some(st) = app.session.active() else { return Info::default() };
let key = ((st.uid, st.reverts), st.revision, st.selection.objects.clone());
let r = app.session.execute("svgInteractivity.info", &json!({})).unwrap_or_default();
let events = r["events"]
.as_array()
@@ -134,7 +140,10 @@ pub fn show(app: &mut VectorcraftApp, ui: &mut Ui) {
let rows_stamp = stamp.finish();
let mut remove = None;
let mut footer_pick = None;
let has_doc = app.session.active().is_some();
let mut row_action = None;
let document = app.session.active().map(|st| st.uid);
let has_doc = document.is_some();
let can_clear = clearable(&info);
let listed = events.iter().any(|(e, _)| e == event);
Stack::new()
.fill()
@@ -155,9 +164,12 @@ pub fn show(app: &mut VectorcraftApp, ui: &mut Ui) {
}
let selection = if listed { Selection::single(event.to_string()) } else { Default::default() };
let mut list = List::<String>::new(tl!("Events"))
// Keep each row menu with the drawing and artwork it was opened for.
.id(ui.scope_id().with(("svg-events", document, info.script_target)))
.select(SelectMode::Single)
.arrows_select(true)
.deletable(true)
.row_menu()
.rows_stamp(rows_stamp)
.selection(Bind::given(selection))
.sizing(Sizing::Fill);
@@ -180,12 +192,29 @@ pub fn show(app: &mut VectorcraftApp, ui: &mut Ui) {
}
}
CollectionEvent::Activate(key) => pick = Some(key),
// The menu acts on the row it opened on, so that row becomes the picked event.
CollectionEvent::ContextMenu(request) => pick = Some(request.key),
CollectionEvent::Delete(_) => {
remove = pick.as_deref().or(listed.then_some(event)).map(str::to_owned);
}
_ => {}
}
}
// `list.menu` is `None` once its row leaves the list.
if let Some(request) = list.menu {
let key = request.key.clone();
Menu::context(request.key, &list.response).show(ui, |ui, _| {
if MenuItem::new(tl!("Remove Event")).show(ui).ran {
remove = Some(key.clone());
}
if MenuItem::new(tl!("Clear Events")).enabled(can_clear).show(ui).ran {
row_action = Some(RowAction::Clear);
}
if MenuItem::new(tl!("Link JavaScript Files…")).enabled(has_doc).show(ui).ran {
row_action = Some(RowAction::LinkFiles);
}
});
}
});
if let Some(e) = pick {
let state = &mut app.ui.svg_interactivity_panel;
@@ -200,10 +229,17 @@ pub fn show(app: &mut VectorcraftApp, ui: &mut Ui) {
}
match footer_pick {
Some(0) => remove = Some(event.to_string()),
Some(1) => {
Some(1) => row_action = Some(RowAction::LinkFiles),
_ => {}
}
match row_action {
Some(RowAction::Clear) => {
app.run(CLEAR_EVENTS, json!({})).ok();
}
Some(RowAction::LinkFiles) => {
crate::menus::invoke(app, "ui.javascriptFilesDialog", json!({}));
}
_ => {}
None => {}
}
if let Some(event) = remove
&& app.run("svgInteractivity.removeEvent", json!({ "event": event })).is_ok_and(|out| out["changed"].as_u64().unwrap_or(0) > 0)
@@ -221,11 +257,16 @@ pub(crate) fn menu_rows(_app: &VectorcraftApp) -> Vec<PanelRow> {
/// Clear Events is on while the objects have events. The panel reads the events each frame it shows; a
/// panel that is not shown leaves the row off.
pub(crate) fn menu_states(app: &VectorcraftApp, states: &mut CommandStates) {
// (Where the objects' events differ, some of them have events.)
let any = cached(app).is_some_and(|info| info.has && info.events.as_ref().is_none_or(|l| !l.is_empty()));
let any = cached(app).is_some_and(clearable);
states.set(CommandRef::new(CLEAR_EVENTS), CommandState::new().enabled(any));
}
/// Clear Events has something to clear: the objects have events. (Where their events differ, some
/// of them have events.)
fn clearable(info: &Info) -> bool {
info.has && info.events.as_ref().is_none_or(|l| !l.is_empty())
}
/// The panel's own `ui.svgInteractivity.*` commands: it has none, because its menu row is the engine
/// command `svgInteractivity.clearEvents`.
pub(crate) fn run(_app: &mut VectorcraftApp, _id: &str, _params: &Value) -> Option<Result<Value, String>> {
@@ -481,4 +522,138 @@ mod tests {
assert_eq!(panel.value(caption("JavaScript:")).as_deref(), Some(script.as_str()));
assert!(panel.in_view(&last), "the picker scrolls the selected event into view");
}
/// A rectangle with two events, `onclick: 1;` and `onmouseover: 2;`, in the panel.
fn two_events() -> Panel {
let mut app = VectorcraftApp::new(Session::new(), Default::default());
run(&mut app, "file.new", json!({"width": 100, "height": 100}));
run(&mut app, "shape.rectangle", json!({"x": 0, "y": 0, "width": 50, "height": 50}));
run(&mut app, "svgInteractivity.setEvent", json!({"event": "onclick", "script": "1;"}));
run(&mut app, "svgInteractivity.setEvent", json!({"event": "onmouseover", "script": "2;"}));
Panel::new(app, show)
}
fn undo_len(panel: &Panel) -> usize {
panel.app().session.active().unwrap().history.undo.len()
}
#[test]
fn row_menu_picks_its_row_and_removes_that_event_in_one_undo_step() {
let mut panel = two_events();
panel.click("onclick: 1;");
assert_eq!(panel.value(caption("JavaScript:")).as_deref(), Some("1;"));
panel.secondary_click("onmouseover: 2;");
assert_eq!(panel.value(caption("JavaScript:")).as_deref(), Some("2;"), "the right-clicked row is picked");
let undo = undo_len(&panel);
panel.click_menu_item(tl!("Remove Event"));
panel.frame();
assert!(!panel.shows("onmouseover: 2;"), "the right-clicked event is removed");
assert!(panel.shows("onclick: 1;"), "the event picked before the right-click stays");
assert_eq!(undo_len(&panel), undo + 1);
panel.app().run("edit.undo", json!({})).unwrap();
panel.frame();
assert!(panel.shows("onmouseover: 2;"), "one undo brings it back");
}
#[test]
fn row_menu_offers_the_panel_menu_and_footer_commands() {
let mut panel = two_events();
panel.secondary_click("onclick: 1;");
let mut states = CommandStates::default();
menu_states(&panel.app(), &mut states);
let panel_menu_clear = states.remove(&CommandRef::new(CLEAR_EVENTS)).is_some_and(|s| s.is_enabled());
assert_eq!(panel.menu_item_enabled(tl!("Clear Events")), panel_menu_clear, "Clear Events follows the panel menu");
assert!(panel.menu_item_enabled(tl!("Link JavaScript Files…")), "a document is open");
let undo = undo_len(&panel);
panel.click_menu_item(tl!("Clear Events"));
panel.frame();
assert!(!panel.shows("onclick: 1;") && !panel.shows("onmouseover: 2;"));
assert_eq!(undo_len(&panel), undo + 1);
}
#[test]
fn keyboard_row_menu_opens_on_the_focused_row_and_escape_returns_focus() {
let mut panel = two_events();
panel.click("onclick: 1;");
panel.key(egui::Key::ArrowDown, egui::Modifiers::NONE);
panel.key(egui::Key::F10, egui::Modifiers::SHIFT);
panel.frame();
assert!(panel.menu_item_enabled(tl!("Remove Event")));
panel.key(egui::Key::Escape, egui::Modifiers::NONE);
panel.frame();
assert!(!panel.shows_role(tl!("Remove Event"), craft::ui::contract::Role::MENU_ITEM));
assert!(panel.focused("onmouseover: 2;"), "Escape gives focus back to the row");
// Enter runs the menu's first row, Remove Event, announced in that frame like the footer's.
panel.key(egui::Key::F10, egui::Modifiers::SHIFT);
panel.frame();
let enter =
|pressed| egui::Event::Key { key: egui::Key::Enter, physical_key: None, pressed, repeat: false, modifiers: egui::Modifiers::NONE };
panel.frame_with(vec![enter(true)]);
let removed = crate::i18n::fmt(tl!("Removed SVG event {event}"), &[("event", "onmouseover")]);
let announced = panel.announces(&removed);
panel.frame_with(vec![enter(false)]);
panel.frame();
assert!(announced, "the removal is announced like the footer's");
assert!(!panel.shows("onmouseover: 2;"));
assert!(panel.shows("onclick: 1;"));
}
#[test]
fn row_menu_closes_when_artwork_selection_changes_in_the_same_document() {
let mut app = VectorcraftApp::new(Session::new(), Default::default());
run(&mut app, "file.new", json!({"width": 100, "height": 100}));
let ids = [0, 20, 40, 60].map(|x| run(&mut app, "shape.rectangle", json!({"x": x, "y": 0, "width": 10, "height": 10}))["id"].clone());
run(&mut app, "svgInteractivity.setEvent", json!({"ids": ids, "event": "onclick", "script": "1;"}));
let first = json!({"ids": [ids[0], ids[1], ids[3]]});
let second = json!({"ids": [ids[0], ids[2], ids[3]]});
run(&mut app, "select.set", first.clone());
let mut panel = Panel::new(app, show);
let item = tl!("Remove Event");
let role = craft::ui::contract::Role::MENU_ITEM;
panel.secondary_click("onclick: 1;");
assert!(panel.menu_item_enabled(item));
// Only the middle object changes, and both selections display the exact same row.
run(&mut panel.app(), "select.set", second);
panel.frame();
assert!(panel.shows("onclick: 1;"));
assert!(!panel.shows_role(item, role));
run(&mut panel.app(), "select.set", first);
panel.frame();
assert!(!panel.shows_role(item, role), "the old menu stays closed on return");
panel.secondary_click("onclick: 1;");
assert!(panel.menu_item_enabled(item), "the row can open a fresh menu");
}
#[test]
fn row_menu_closes_when_its_row_disappears_or_the_document_changes() {
let mut panel = two_events();
panel.secondary_click("onmouseover: 2;");
assert!(panel.menu_item_enabled(tl!("Remove Event")));
run(&mut panel.app(), "svgInteractivity.removeEvent", json!({"event": "onmouseover"}));
panel.frame();
assert!(!panel.shows_role(tl!("Remove Event"), craft::ui::contract::Role::MENU_ITEM));
// A second document whose object has the same event: switching to it shows a row of the same
// name, which the menu must not carry over to.
{
let mut app = panel.app();
run(&mut app, "file.new", json!({"width": 100, "height": 100}));
run(&mut app, "shape.rectangle", json!({"x": 0, "y": 0, "width": 50, "height": 50}));
run(&mut app, "svgInteractivity.setEvent", json!({"event": "onclick", "script": "1;"}));
app.run("window.nextDocument", json!({})).unwrap();
}
panel.frame();
panel.secondary_click("onclick: 1;");
assert!(panel.menu_item_enabled(tl!("Remove Event")));
panel.app().run("window.nextDocument", json!({})).unwrap();
panel.frame();
assert!(panel.shows("onclick: 1;"), "the other document lists the same event");
assert!(!panel.shows_role(tl!("Remove Event"), craft::ui::contract::Role::MENU_ITEM));
}
}
+4 -1
View File
@@ -1,7 +1,7 @@
# Gaps
> Status-bar snapping quick access (#8687, #8779): the bottom right offers Smart Guides, Snap to Point and Snap to Grid toggles plus the same live Snapping menu as the Control bar. Both use existing commands. Framework fit ranks omit the direct group first, then the dropdown, before the existing readouts or core status content narrow. The native buttons expose their current selected state. Scores and estimates are unchanged.
> **Last reviewed:** 2026-10-10 · **Last updated:** 2026-11-25 · **Change:** minor (G12: History row menus adapted to shared Craft list/menu controls after rebase (#8845); scores and estimates unchanged; previously: G12: Document Info panel menu Selection Only (`ui.docInfo.selectionOnly`) counts the selection, and with no artwork selected it shows (No artwork selected) and artboards the Artboard tool has selected still show; scores and estimates unchanged; previously: G12: OpenType panel feature rows have an item context menu (Turn On / Turn Off, Reset OpenType Features); scores and estimates unchanged; previously: G3 lists shadows from the first light and graphics as done and drops angular cut caps, which Revolve's Cap closes, #8312; scores and estimates unchanged; previously: G12/M14: History row context menus, pending-edit snapshot targeting, keyboard access and document-switch dismissal (#8845); scores and estimates unchanged; previously: G3 lists shadows from the first light and graphics as done and drops angular cut caps, which Revolve's Cap closes, #8312; scores and estimates unchanged; previously: G12: Asset Export tile context menus; scores and estimates unchanged; previously: M14/G12: Appearance panel: right-click item context menus for rows (Duplicate, Delete, Hide/Show, Edit Effect, Clear Appearance, Reduce to Basic Appearance) with selection handling, #8809; previously: G12: Properties panel Quick Actions include contextual text actions (Create Outlines, Retype, Find and Replace…); scores and estimates unchanged; previously: G12: Actions panel item context menus for action sets (New Action…, New Set…, Duplicate Set, Delete Set, Set Options…) and actions (Play, Record, Duplicate, Delete, Action Options…, Batch…) with selection handling; clicking Duplicate on an action duplicates that action; headless tests in `crates/ui-egui/src/panels/actions.rs`; scores and estimates unchanged; previously: Scissors shows the actual proposed cut point while hovering, using its existing snapping and cut target (#8655); scores and estimates unchanged; previously: G12: Brushes panel: item right-click context menu (Brush Options, Duplicate Brush, Delete Brush) with selection handling; scores and estimates unchanged; previously: G12: Links panel row context menu (Relink…, Go To Link, Update Link, Edit Original, Show in Folder, Embed Image / Unembed…) with selection handling; scores and estimates unchanged; previously: Direct Selection: Space during an ordinary path's handle drag repositions its anchor and handles, including a Pen loan (#7237, request 3 only; scores and estimates unchanged); previously: SVG export preserves document units on root width/height for physical units, #864; G11 estimate 8–15 → 6–13 h; G4 and G13 Missing lists drop the shipped Touch Type, Snap to Glyph and Dimension tool, and G13's snapping entry keeps only what is still missing, the partial Snapping panel and the items not yet checked (#8387); G13 keeps one estimate (13–23 h); estimates unchanged; previously: Retype phase 1 (#4934): Type › Retype (`type.retype`) turns outlined text that exactly matches an available font back into point text; scores and estimates unchanged; previously: Production Preflight: output-aware fonts, text overflow, linked files and effective image resolution, clickable findings and automatic rechecking; scores and estimates unchanged; previously: PDF export writes the document language as the catalog's `/Lang`, #3644; Recolor Artwork follow-up (#8031, remaining #4028): native Lab input, picker swatch libraries and Assign-row menus; UI interaction regression coverage; scores and estimates unchanged; previously: Eraser review: hidden Rasterize and Along/Across stroke rows do not block preserving visible gradients; scores and estimates unchanged; previously: Eraser review: ordinary Group/Layer paints and reproducible evaluated gradient placements are preserved; other placements retain existing fitting; scores and estimates unchanged; previously: Eraser: shared fill-only area cutting for fixed and varied tips and the Alt-drag marquee, #6582; scores and estimates unchanged; previously: G4 type: modal Check Spelling dialog (Edit › Spelling › Check Spelling…), #4936; spell check complete; previously: Type: the Middle Eastern & South Asian composers are done as a per-paragraph choice with the Standard composers (#4935); G5: built-in Neon & Glow graphic style library (Cyan Neon, Magenta Laser, Amber Tube, Electric Lime, Pulse Violet, Cobalt Phosphor); estimate unchanged (3–13 h); previously: Tech Circuit brush library, G5; previously: G5: built-in Weather Icons symbol library (Sun, Moon, Cloud, Rain, Thunder, Snow); estimate 5–15 → 4–14 h; previously: 3D: the seams of white-light Extrude & Bevel, Inflate and Rotate, and the face seams of the 3D (Classic) effects, have round joins instead of miters; previously: PDF import: preserve Type 3 font text runs as named groups <g>, or as lLine truncated
> **Last reviewed:** 2026-10-10 · **Last updated:** 2026-12-02 · **Change:** minor (G12: SVG Interactivity event rows have an item menu (Remove Event, Clear Events, Link JavaScript Files…); scores and estimates unchanged; previously: G12: History row menus adapted to shared Craft list/menu controls after rebase (#8845); scores and estimates unchanged; previously: G12: Document Info panel menu Selection Only (`ui.docInfo.selectionOnly`) counts the selection, and with no artwork selected it shows (No artwork selected) and artboards the Artboard tool has selected still show; scores and estimates unchanged; previously: G12: OpenType panel feature rows have an item context menu (Turn On / Turn Off, Reset OpenType Features); scores and estimates unchanged; previously: G3 lists shadows from the first light and graphics as done and drops angular cut caps, which Revolve's Cap closes, #8312; scores and estimates unchanged; previously: G12/M14: History row context menus, pending-edit snapshot targeting, keyboard access and document-switch dismissal (#8845); scores and estimates unchanged; previously: G3 lists shadows from the first light and graphics as done and drops angular cut caps, which Revolve's Cap closes, #8312; scores and estimates unchanged; previously: G12: Asset Export tile context menus; scores and estimates unchanged; previously: M14/G12: Appearance panel: right-click item context menus for rows (Duplicate, Delete, Hide/Show, Edit Effect, Clear Appearance, Reduce to Basic Appearance) with selection handling, #8809; previously: G12: Properties panel Quick Actions include contextual text actions (Create Outlines, Retype, Find and Replace…); scores and estimates unchanged; previously: G12: Actions panel item context menus for action sets (New Action…, New Set…, Duplicate Set, Delete Set, Set Options…) and actions (Play, Record, Duplicate, Delete, Action Options…, Batch…) with selection handling; clicking Duplicate on an action duplicates that action; headless tests in `crates/ui-egui/src/panels/actions.rs`; scores and estimates unchanged; previously: Scissors shows the actual proposed cut point while hovering, using its existing snapping and cut target (#8655); scores and estimates unchanged; previously: G12: Brushes panel: item right-click context menu (Brush Options, Duplicate Brush, Delete Brush) with selection handling; scores and estimates unchanged; previously: G12: Links panel row context menu (Relink…, Go To Link, Update Link, Edit Original, Show in Folder, Embed Image / Unembed…) with selection handling; scores and estimates unchanged; previously: Direct Selection: Space during an ordinary path's handle drag repositions its anchor and handles, including a Pen loan (#7237, request 3 only; scores and estimates unchanged); previously: SVG export preserves document units on root width/height for physical units, #864; G11 estimate 8–15 → 6–13 h; G4 and G13 Missing lists drop the shipped Touch Type, Snap to Glyph and Dimension tool, and G13's snapping entry keeps only what is still missing, the partial Snapping panel and the items not yet checked (#8387); G13 keeps one estimate (13–23 h); estimates unchanged; previously: Retype phase 1 (#4934): Type › Retype (`type.retype`) turns outlined text that exactly matches an available font back into point text; scores and estimates unchanged; previously: Production Preflight: output-aware fonts, text overflow, linked files and effective image resolution, clickable findings and automatic rechecking; scores and estimates unchanged; previously: PDF export writes the document language as the catalog's `/Lang`, #3644; Recolor Artwork follow-up (#8031, remaining #4028): native Lab input, picker swatch libraries and Assign-row menus; UI interaction regression coverage; scores and estimates unchanged; previously: Eraser review: hidden Rasterize and Along/Across stroke rows do not block preserving visible gradients; scores and estimates unchanged; previously: Eraser review: ordinary Group/Layer paints and reproducible evaluated gradient placements are preserved; other placements retain existing fitting; scores and estimates unchanged; previously: Eraser: shared fill-only area cutting for fixed and varied tips and the Alt-drag marquee, #6582; scores and estimates unchanged; previously: G4 type: modal Check Spelling dialog (Edit › Spelling › Check Spelling…), #4936; spell check complete; previously: Type: the Middle Eastern & South Asian composers are done as a per-paragraph choice with the Standard composers (#4935); G5: built-in Neon & Glow graphic style library (Cyan Neon, Magenta Laser, Amber Tube, Electric Lime, Pulse Violet, Cobalt Phosphor); estimate unchanged (3–13 h); previously: Tech Circuit brush library, G5; previously: G5: built-in Weather Icons symbol library (Sun, Moon, Cloud, Rain, Thunder, Snow); estimate 5–15 → 4–14 h; previously: 3D: the seams of white-light Extrude & Bevel, Inflate and Rotate, and the face seLine truncated
> Panel readout copy (#8432, #8826): Info values and paint names, Links information, and named Document Info rows with no separate value follow the guarded immediate-copy policy landed in #9353. A plain first click copies the full value and reports "Copied the value"; accessible activation copies it too. Selectable readouts retain word selection on double-click, Shift/drag selection and keyboard Copy/Cut. Links Location retains #9521's path fitting and full-path tooltip as static text, with the same full-value primary/accessible copy and a native Copy Location button for keyboard use. Scores and estimates are unchanged.
@@ -81,6 +81,7 @@ Artboard Options forwards the active Artboard tool's Scale Artwork with Artboard
| Date | Change | Summary |
|---|---|---|
| 2026-12-02 | minor | G12: SVG Interactivity event rows have an item menu: a right-click (or Shift+F10 on the focused row) picks that event and offers Remove Event (`svgInteractivity.removeEvent` for that row, one undo step), Clear Events (`svgInteractivity.clearEvents`, enabled like the panel menu row) and Link JavaScript Files… (`ui.javascriptFilesDialog`). Headless regressions: `panels::svg_interactivity::tests`. Scores and estimates unchanged. |
| 2026-11-25 | minor | Document Info › Objects: total enclosed area (`pathArea` in pt²) for closed and compound paths (holes subtracted per fill rule; guides and open paths left out) and formatted Path Area in document units, beyond reference panel (#6965). Worked out only when the request covers Objects (`pathArea` null otherwise or with `pathArea: false`); the panel asks for it only while Objects or All Categories is shown. Tests: `info_gives_the_paths_total_area`, `info_works_out_the_path_area_only_for_the_objects_category`, `the_path_area_is_worked_out_only_while_objects_is_shown`, `format_area_formats_and_trims_cleanly`. Scores and estimates unchanged. |
| 2026-11-24 | minor | G12: History row context menus use shared Craft List and Menu controls after rebasing onto the panel migration. App-specific actions retain the chosen snapshot across pending edits and dismiss on document switches; keyboard context requests and focus restoration use the shared runtime. Regression cases retained (#8845); scores and estimates unchanged. |
| 2026-11-21 | minor | G12: Document Info › Selection Only (`ui.docInfo.selectionOnly`) counts objects in the selection through `document.info`; with no artwork selected it shows (No artwork selected) and artboards the Artboard tool has selected still show. Headless regressions: `panels::doc_info::tests::test_doc_info_counts_entire_document`, `test_doc_info_selection_only_toggles_and_filters_counts`, `test_doc_info_selection_only_keeps_selected_artboard`, `test_doc_info_panel_menu_toggles_state`. Scores and estimates unchanged. |
@@ -559,6 +560,8 @@ macOS cursor delivery (#2292) is narrowed to a native host adapter using the exi
## G12 Preferences and panels that don't act yet
- **Done (2026-12-02):** SVG Interactivity event rows have an item context menu. A right-click on an event row, or Shift+F10 on the focused row, picks that event and offers **Remove Event** (`svgInteractivity.removeEvent` for that row, one undo step, announced like the footer's Remove Selected Entry), **Clear Events** (`svgInteractivity.clearEvents`, enabled under the same rule as the panel menu row) and **Link JavaScript Files…** (`ui.javascriptFilesDialog`). The menu closes when its row leaves the list or the document changes. Headless regressions: `panels::svg_interactivity::tests::row_menu_picks_its_row_and_removes_that_event_in_one_undo_step`, `row_menu_offers_the_panel_menu_and_footer_commands`, `keyboard_row_menu_opens_on_the_focused_row_and_escape_returns_focus` and `row_menu_closes_when_its_row_disappears_or_the_document_changes`. Other G12 gaps remain; scores and estimates unchanged.
- Glyphs cells have an item context menu. A character offers **Insert Glyph** at the Type caret or in selected text. A glyph without a mapped character offers **Apply Alternate** for the character selected with the Type tool. The menu uses the same actions as Enter and double-click and disables the item when its text target cannot accept the glyph.
- **Implemented and tested (2026-11-21):** Properties panel Quick Actions follow every selected object. Ungroup (`object.ungroup`) is offered when any selected object is a group, including several groups, a group selected after a path, and a group that holds another group. Isolate Group (`object.isolate`) is offered only when that one group is the whole selection. Unite (`object.pathfinder.unite`) appears only for selections of at least two objects, each a non-guide path or a compound path. It appears alongside Group and Make Clipping Mask. Headless regressions: `panels::properties::tests::two_groups_offer_ungroup_without_isolate_group`, `one_group_offers_ungroup_and_isolate_group` and `several_paths_offer_group_clipping_mask_and_unite`. Other G12 gaps remain; scores and estimates unchanged.
+3 -1
View File
@@ -1,7 +1,7 @@
# UI and interaction parity
> Status-bar snapping quick access (#8687, #8779): the bottom right offers Smart Guides, Snap to Point and Snap to Grid toggles plus the same live Snapping menu as the Control bar. Both use existing commands. Framework fit ranks omit the direct group first, then the dropdown, before the existing readouts or core status content narrow. The native buttons expose their current selected state. Scores and estimates are unchanged.
> **Last reviewed:** 2026-10-10 · **Last updated:** 2026-12-02 · **Change:** minor (RFC-0052 Headless section, all unknown; earlier: Ctrl/Cmd+arrow fine nudge, #5258; scores and estimates unchanged; previously: Smart Guides: in a document with more than 20,000 anchors, the snap targets are gathered topmost first, so the objects in front, the newest, keep their anchors, edges and centre as targets for ruler guides, moves, scaling and drawing (#8531); scores and estimates unchanged; previously: 3D effect options: unchanged values preserve the document and add no Undo; scores and estimates unchanged); previously: minor (G12: History row menus adapted to shared Craft list/menu controls after rebase (#8845); scores and estimates unchanged; previously: G12/M14: History row context menus, pending-edit snapshot targeting, keyboard access and document-switch dismissal (#8845); scores and estimates unchanged; previously: Pencil Edit Selected Paths follows lifted strokes, carves, loops, closes and redraws compound paths; Layers: a targeted item with an appearance of its own keeps its inner ring visible around a smaller appearance dot, so the target circle's four looks differ, #8711; scores and estimates unchanged; previously: G12: Asset Export tile context menus; scores and estimates unchanged; previously: Properties panel per context (G12): contextual text Quick Actions (Create Outlines, Retype, Find and Replace…); scores and estimates unchanged; previously: Layers: a targeted item with an appearance of its own keeps its inner ring visible around a smaller appearance dot, so the target circle's four looks differ, #8711; scores and estimates unchanged; previously: Trim View hides the ruler guides, guide paths and the grid while it is on and greys out Show/Hide Guides and Show/Hide Grid, #8363; scores and estimates unchanged; previously: Scissors shows the actual proposed cut point while hovering, using its existing snapping and cut target (#8655); scores and estimates unchanged; previously: Graphic Styles panel: right-click item context menu for tiles and rows with Options, Duplicate, Delete, Redefine, Break Link; scores and estimates unchanged; previously: Artboard tool: Shift held once a move or Alt-copy drag is under way keeps it to the level, upright or 45° line, #8580; scores and estimates unchanged; previously: Image Trace Ignore Color keeps the canvas View and stays armed on a missed pixel (#8068); Canvas context menu: a right-click on a path offers Simplify… next to Smooth…, opening the Simplify slider, or the Simplify dialog kept for next time, as Object › Path › Simplify… does, #8344; scores and estimates unchanged; previously: a tool drag held near an edge of the canvas scrolls the view, #8551; scores and estimates unchanged; previously: G12: Place: show progress window with Cancel for slow placed files exceeding 0.4 s, part of #5930; scores and estimates unchanged; previously: All Tools drawer: a tool the toolbar holds is dimmed in the readable dim text colour, not the disabled colour that was unreadable against the panel, and a hovered dimmed row takes the panel's darker fill so it stays readable, #8294; scores and estimates unchanged; previously: : selected guide rows stay highlighted after the pointer leaves (#7344); scores and estimates unchanged; previously: Layersselected Dimension extension-line color and weight in Properties (#7078; four focused UI regressions passed); scores and estimates unchanged; previously: Brush Options Key Color: restore canvas input for the existing one-shot pick, then resume the retained draft and previous tool (#8284; six full-app input regressions passed); scores and estimates unchanged; previously: Ellipse: Up/Down changes Anchors while drawing (#7840); scores and estimates unchanged; previously: Windows/Linux menu access keys and localized cues (#6596); previously: Backquote/~ arrow pattern nudges (#7717); scores and estimates unchanged; previously: Window > Toolbars > Compact Tools offers optional denser main Tools spacing (#7234); default layout, scores and estimates unchanged; previously: Direct Selection: Space during an ordinary path's handle drag repositions its anchor and handles, including a Pen loan (#7237, request 3 only; scores and estimates unchanged); previously: Floating panels keep their window level while focus moves between the app's windows, so a press on one panel's bar no longer hands the keyboard to another, #6986; scores and estimates unchanged; previously minor: Lock Guides: a selection marquee (Selection, Direct Selection, Group Selection, Enclosing Lasso) leaves out paths made into guides inside groups and compound paths too, as clicks do (#3074), so a group is no longer selected by a locked guide in it; an enclosing marquee measures a group without its locked or hidden guides, and Direct Selection takes no anchor or segment of a guide that can't be picked; a guide in a group still moves with its group (#8538); scores and estimaLine truncated
> **Last reviewed:** 2026-10-10 · **Last updated:** 2026-12-02 · **Change:** minor (G12: SVG Interactivity event rows have an item menu; scores and estimates unchanged; earlier: RFC-0052 Headless section, all unknown; earlier: Ctrl/Cmd+arrow fine nudge, #5258; scores and estimates unchanged; previously: Smart Guides: in a document with more than 20,000 anchors, the snap targets are gathered topmost first, so the objects in front, the newest, keep their anchors, edges and centre as targets for ruler guides, moves, scaling and drawing (#8531); scores and estimates unchanged; previously: 3D effect options: unchanged values preserve the document and add no Undo; scores and estimates unchanged); previously: minor (G12: History row menus adapted to shared Craft list/menu controls after rebase (#8845); scores and estimates unchanged; previously: G12/M14: History row context menus, pending-edit snapshot targeting, keyboard access and document-switch dismissal (#8845); scores and estimates unchanged; previously: Pencil Edit Selected Paths follows lifted strokes, carves, loops, closes and redraws compound paths; Layers: a targeted item with an appearance of its own keeps its inner ring visible around a smaller appearance dot, so the target circle's four looks differ, #8711; scores and estimates unchanged; previously: G12: Asset Export tile context menus; scores and estimates unchanged; previously: Properties panel per context (G12): contextual text Quick Actions (Create Outlines, Retype, Find and Replace…); scores and estimates unchanged; previously: Layers: a targeted item with an appearance of its own keeps its inner ring visible around a smaller appearance dot, so the target circle's four looks differ, #8711; scores and estimates unchanged; previously: Trim View hides the ruler guides, guide paths and the grid while it is on and greys out Show/Hide Guides and Show/Hide Grid, #8363; scores and estimates unchanged; previously: Scissors shows the actual proposed cut point while hovering, using its existing snapping and cut target (#8655); scores and estimates unchanged; previously: Graphic Styles panel: right-click item context menu for tiles and rows with Options, Duplicate, Delete, Redefine, Break Link; scores and estimates unchanged; previously: Artboard tool: Shift held once a move or Alt-copy drag is under way keeps it to the level, upright or 45° line, #8580; scores and estimates unchanged; previously: Image Trace Ignore Color keeps the canvas View and stays armed on a missed pixel (#8068); Canvas context menu: a right-click on a path offers Simplify… next to Smooth…, opening the Simplify slider, or the Simplify dialog kept for next time, as Object › Path › Simplify… does, #8344; scores and estimates unchanged; previously: a tool drag held near an edge of the canvas scrolls the view, #8551; scores and estimates unchanged; previously: G12: Place: show progress window with Cancel for slow placed files exceeding 0.4 s, part of #5930; scores and estimates unchanged; previously: All Tools drawer: a tool the toolbar holds is dimmed in the readable dim text colour, not the disabled colour that was unreadable against the panel, and a hovered dimmed row takes the panel's darker fill so it stays readable, #8294; scores and estimates unchanged; previously: : selected guide rows stay highlighted after the pointer leaves (#7344); scores and estimates unchanged; previously: Layersselected Dimension extension-line color and weight in Properties (#7078; four focused UI regressions passed); scores and estimates unchanged; previously: Brush Options Key Color: restore canvas input for the existing one-shot pick, then resume the retained draft and previous tool (#8284; six full-app input regressions passed); scores and estimates unchanged; previously: Ellipse: Up/Down changes Anchors while drawing (#7840); scores and estimates unchanged; previously: Windows/Linux menu access keys and localized cues (#6596); previously: Backquote/~ arrow pattern nudges (#7717); scores and estimates unchanged; previously: Window > Toolbars > Compact Tools offers optional denser main Tools spacing (#7234); default layout, scores and estimates unchanged; previously: Direct Selection: Space during an ordinary path's handle drag repositions its anchor and handles, including a Pen loan (#7237, request 3 only; scores and estimates unchanged); previously: Floating panels keep their window level while focus moves between the app's windows, so a press on one panel's bar no longer hands the keyboard to another, #6986; scores and estimates unchanged; previously minor: Lock Guides: a selection marquee (Selection, Direct Selection, Group Selection, Enclosing Lasso) leaves out paths made into guides inside groups and compound paths too, as clicks do (#3074), so a group is no longer selected by a locked guide in it; an enclosing marquee measures a group without its locked or hidden guides, and Direct Selection takes no anchor or segment of a guide Line truncated
> Panel readout copy (#8432, #8826): Info values and paint names, Links information, and named Document Info rows with no separate value follow the guarded immediate-copy policy landed in #9353. A plain first click copies the full value and reports "Copied the value"; accessible activation copies it too. Selectable readouts retain word selection on double-click, Shift/drag selection and keyboard Copy/Cut. Links Location retains #9521's path fitting and full-path tooltip as static text, with the same full-value primary/accessible copy and a native Copy Location button for keyboard use. Scores and estimates are unchanged.
>
@@ -554,6 +554,7 @@ next unit in the order a right-click on a ruler lists them, from Feet back to Po
| Links panel row context menu (G12) | done | Right-clicking a link row presents an item context menu offering Relink…, Go To Link, Update Link, Edit Original, Show in Folder, and Embed Image / Unembed…; right-clicking an unselected row selects it first, preserving selection if already part of a multi-selection. Tests: `panels::tests_links::right_click_context_menu_in_links_panel`. | unknown |
| Appearance panel row context menu (G12) | done | Right-clicking a stroke or fill row offers Duplicate Stroke / Duplicate Fill, Delete Stroke / Delete Fill, and Hide/Show Stroke / Fill; effect rows offer Edit Effect…, Duplicate Effect, Delete Effect, and Hide/Show Effect; root object row offers Clear Appearance and Reduce to Basic Appearance. Right-clicking an unselected row targets it first before opening the context menu. Tests: `panels::tests_appearance::right_clicking_a_stroke_row_selects_it_and_exposes_context_menu`, `panels::tests_appearance::clicking_duplicate_stroke_duplicates_the_stroke_with_one_undo_step`, `panels::tests_appearance::clicking_delete_effect_removes_the_effect_from_appearance`, `panels::tests_appearance::right_clicking_root_object_row_exposes_clear_and_reduce_appearance`. | unknown |
| SVG Interactivity panel: JavaScript for each object's events and the document's linked JavaScript files, written to SVG and read back as text | done | `svgInteractivity.*`, `ui.javascriptFilesDialog` | unknown |
| SVG Interactivity event row item menu (G12) | done | Right-clicking an event row (or Shift+F10 on the focused row) picks that event and offers Remove Event, Clear Events and Link JavaScript Files…, the same commands as the footer and the panel menu; the menu closes when its row leaves the list or the document or artwork selection changes. `panels::svg_interactivity::tests::row_menu_picks_its_row_and_removes_that_event_in_one_undo_step`, `row_menu_offers_the_panel_menu_and_footer_commands`, `keyboard_row_menu_opens_on_the_focused_row_and_escape_returns_focus`, `row_menu_closes_when_its_row_disappears_or_the_document_changes` | unknown |
| Retype panel | partial | Window › Retype lists the fonts whose glyphs exactly match at least one selected outlined shape, ranked by how many shapes each matches, ten and then five more, with samples in three sizes and the user's own text; a click sets the font on selected live type (`retype.find`, `type.retypeFonts`). Installed fonts not loaded yet are compared too, read in the background with Cancel (`retype.cancelSearch`). Opening it from the Type menu, the context menu, and the Properties panel for outlined shapes (the Properties panel Quick Action opens it for text selections only), filtering by font source and favorites, near matches and text in images are missing (#4934) | unknown |
| Comments, Version History panels | missing | cloud features (out of scope) | unknown |
| Blend panel (30.7) | partial | Window › Blend provides Type (Ease In, Ease Out, Ease In Out, Ease Out In), Ramp 0–100% and independent color Shift, alongside the existing blend controls. Easing is disabled without a spine. Original polynomial distributions approximate the publicly documented behavior. On-canvas Appearance and Easing widgets set Shift and Ramp; a blend without a spine shows the Appearance widget alone. [Public source](https://helpx.adobe.com/illustrator/desktop/manage-colors/apply-transparency-and-blending/blend-panel-overview.html) | unknown |
@@ -683,6 +684,7 @@ before release (#6373). [Paint faces and edges](https://helpx.adobe.com/illustra
| Date | Change | Summary |
|---|---|---|
| 2026-12-02 | minor | G12: SVG Interactivity event rows have an item menu (Remove Event, Clear Events, Link JavaScript Files…) using the footer and panel menu commands; `panels::svg_interactivity::tests`. Scores and estimates unchanged. |
| 2026-11-27 | minor | 3D effect options: unchanged approval and equivalent validated `effect.setParams` preserve the effect, document revision and Undo, including defaults. Changed options still save once. Scores and estimates unchanged. |
| 2026-11-26 | minor | #8744: native-canvas sampler-owned release/Zoom regression source, retaining ordinary navigation, dock rejection, accepted sampling, document/selection/paint/history controls and no idle replay. Runtime pending; scores, gaps and hours unchanged. |
| 2026-11-24 | minor | G12: History row context menus use shared Craft List and Menu controls after rebasing onto the panel migration. App-specific actions retain the chosen snapshot across pending edits and dismiss on document switches; keyboard context requests and focus restoration use the shared runtime. Regression cases retained (#8845); scores and estimates unchanged. |