36 lines
1.9 KiB
Markdown
36 lines
1.9 KiB
Markdown
# Market Scrollable Plugin Columns Design
|
|
|
|
**Goal:** Keep the plugin-generated columns visible without letting them cover Xingtu's native middle columns.
|
|
|
|
**Problem:** The current implementation injects plugin columns into the right sticky section. That expands the sticky width and causes native middle columns such as `预期播放量` and `互动率` to be visually covered.
|
|
|
|
**Approved Direction:** Keep plugin columns always visible, but move them out of the right sticky area. The plugin columns should live in the horizontally scrollable middle area so they scroll together with the native table columns.
|
|
|
|
## Design
|
|
|
|
### Layout
|
|
|
|
- Preserve the native left sticky author section.
|
|
- Preserve the native right sticky section for Xingtu's own right-side columns, especially `21-60s报价` and `操作`.
|
|
- Insert plugin columns as a separate non-sticky section immediately before the right sticky section.
|
|
- Let the plugin section participate in the same horizontal flow as the middle columns so users reach it through horizontal scrolling.
|
|
|
|
### DOM Sync Responsibilities
|
|
|
|
- `syncDivGridRoot()` remains responsible for locating the author section, middle columns, and right sticky section.
|
|
- Plugin header cells and plugin body columns should no longer be inserted into `actionHeader.parentElement` / `actionColumn.parentElement`.
|
|
- A dedicated plugin section should be created or reused under the header row and body row.
|
|
- Row alignment logic should still read plugin cells row-by-row for rendering, visibility, and ordering.
|
|
|
|
### Behavior
|
|
|
|
- Export, filtering, sorting, and row hydration should keep working unchanged.
|
|
- Only column placement changes.
|
|
- Existing synthetic table mode is unaffected.
|
|
|
|
### Testing
|
|
|
|
- Add regression coverage proving the right sticky section width stays at the native width.
|
|
- Add regression coverage proving plugin columns render in a separate non-sticky section.
|
|
- Keep existing export and hydration behavior green.
|