Activity Search Phase 1#1875
Open
joswig wants to merge 18 commits into
Open
Conversation
237d865 to
2a5f418
Compare
Contributor
|
This feels very useful, so much potential here |
9e5e9c4 to
1849440
Compare
b91a810 to
34a44a1
Compare
- Server-side pagination (offset + aggregate count) with first/prev/next/last controls - Expanded filters: plan name/owner, created_by, last-modified date range, scheduling-goal origin - Argument name dropdown driven by the selected model's activity type parameter schemas; narrows further when an activity type is selected - Server-side sort: AG Grid column state translated to nested Hasura order_by - All filter state encoded in URL query params (bookmarkable / shareable searches), initialized on load with deferred model-id resolution while subscription primes - Result table: tag chips, JSON arguments column, formatted timestamps via getShortISOForDate, plus toggleable Created At / Plan ID / Activity ID columns - Column picker (ActivityTableMenu) with show/hide all + reset; column state persisted via localStorage. Forward columnVisible / columnsReset events through SingleActionDataGrid so the picker can react - Search button always enabled; auto-search-on-load still gated on a non-empty filter
Adds persistColumnStateKey + transformColumnState props on DataGrid (forwarded through BulkAction/SingleActionDataGrid). WorkspaceFileBrowser drops its duplicated save/clear logic and rides its name-column processing through transformColumnState.
Replace maxOptionChars*8 width estimate with canvas measureText, reading the font off a hidden DOM ref so it tracks CSS. Pass items through RowVirtualizerFixed as a slot prop (fixes stale content when array changes in place). Add loading prop. TimelineItemList + mock updated for new virtualizer API.
Mission Model uses SearchableDropdown. Collapse pending-model state into a single selectedModelId (selectedModel derived). Inline subscription-error banner. Per-dropdown loading. Start Offset min/max filters. Argument Value defaults tooltip. Search always enabled, above Clear, sticky footer. 500ms-delayed spinner overlay over results; no-op local sort comparators avoid the flash before server-sorted data lands. SearchResults adopts the new persistColumnStateKey for column-state persistence.
UI / UX - Multi-select Activity Type filter (`_in` clause); arg-name dropdown handles multi - New filters: Last Modified By, Created After/Before, Plan Tag, Scheduling Goal - New columns: Model, Model ID, Absolute Start Time, Scheduling Goal - Column order regrouped: action → identity → plan/model → tagging → timing → audit → provenance - Open-in-plan: Svelte component cell, full-cell click, pinned-left icon column - Right-click context menu: "Copy N Activit(ies)" and "Open in plan" (single-select) - Click-drag column resize (no shift-key required) - Open-in-plan exempt from column picker and the "hide all" sweep Behavior fixes - Cross-plan paste respects the right-click paste-at-time even when the source activities' absolute times fall outside the target plan window - Arg value matching: JSON.parse + singleton-array sugar so typing `5` finds `XYZ: 5` and `XYZ: [1, 2, 5]`; numeric/bool branch covers all four shapes - Drop the `directive_id: id` gql alias — fixes Hasura sort error on Activity ID - DataGrid: querySelectorAll so the selected-row class stays in sync between center and pinned-left containers (fixes the two-tone selected row bug) Types / internals - ActivityDirectiveSearchResult now extends ActivityDirectiveDB instead of redefining shared fields; corrects applied_preset shape along the way - SEARCH_ACTIVITIES extends plan with mission_model, adds source_scheduling_goal, anchor_id, anchored_to_start, metadata for the clipboard mapping - Use ColumnPinnedType / SortDirection imports for the two literal ColDef fields
f5da1be to
363d1b5
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
New
/searchpage for finding activity directives across all plans, plus shared-component improvements that came out of building it.Search page
Filters (all bookmarkable via URL query params):
Mission Model
Activity Type (multi-select; narrowed by selected model)
Activity Name
Argument Name (typeahead from the selected model's parameter schemas; narrows further with a selected Type)
Argument Value (tooltip notes mission-model defaults are not applied. Also – typing
5matchesXYZ: 5andXYZ: [1, 2, 5]; arrays/structs accepted as JSON)Tag
Preset (model-filtered)
Created By
Last Modified By
Created After / Created Before
Last Modified Before / After
Start Offset min/max
Plan Name
Plan Owner
Plan Tag
Scheduling Goal
Scheduler-created only
Results:
Server-side pagination, 50/page, with aggregate count
Server-side sort translated from AG Grid column state
Sticky-footer Search/Clear
500ms-delayed spinner overlay during search
Inline banner for subscription errors
Per-dropdown loading state
Columns (default-visible unless noted):
Selection & cross-plan copy:
Shared changes
DataGrid:
persistColumnStateKey+transformColumnStateprops centralize column-state localStorage save/clearBulkActionDataGridandSingleActionDataGridtransformColumnStateSearchableDropdown:
measureTextwith font read off a hidden DOM ref (replaces themaxOptionChars * 8heuristic that overshot for proportional fonts)RowVirtualizerFixedas a slot prop so menus refresh while openloadingproptype="button"so Enter inside a sibling input no longer toggles the menuRowVirtualizerFixed:
itemsprop replacescount; slot exposesitemBug fixes & polish
querySelectorAllso pinned-left and center containers stay in sync (fixes two-tone selected row with pinned columns — affects every table with pinned columns, not just search)Test plan
TODO
Future Work
Future directions for this work could involve:
/searchpage