Skip to content

sharing 6/7: Sharing Tab UI#8064

Draft
keithharvey wants to merge 1 commit into
sharing/03-tech-keystonefrom
sharing/04-sharing-tab-ui
Draft

sharing 6/7: Sharing Tab UI#8064
keithharvey wants to merge 1 commit into
sharing/03-tech-keystonefrom
sharing/04-sharing-tab-ui

Conversation

@keithharvey

@keithharvey keithharvey commented Jun 22, 2026

Copy link
Copy Markdown
Collaborator

📚 Stacked split of #5704 — review bottom-up

Warning

Review and approve here, but don't merge this PR — the whole feature lands in one GitHub-UI merge of the root PR #5704 (byte-identical to the assembled tip) once the type-migration stack (#8235) is in. Merge instructions live on #5704.

Each PR is file-partitioned: every file appears in exactly one PR in its final sharing_tab form, so each PR's diff is byte-identical to that branch. Regenerated deterministically by just bar::sharing-split.

Summary (LLM-generated, claude-opus-4-6)

Wire the PolicyResult / TeamTransfer layer into every sharing-related UI surface.

  • Introduce team_transfer_unsynced.lua as the unsynced TeamTransfer facade (.Resources, .Units, .Units.ShareUnits) and unit_transfer_unsynced.lua which sends unit shares via LuaRulesMsg instead of Spring.ShareResources.
  • Extract gui_advplayerslist helpers into gui_advplayerlist/policy.lua (pack/unpack PolicyResult per PolicyType into player-data rows, RepackPolicy on SharePolicyChanged), resource.lua (HandleResourceTransfer using DecideCommunicationCase), api_extensions.lua (hover-change + hover-invalid-units listener API), and gui_advplayerslist_modules.lua (column-module definitions moved out of the main widget to dodge the Lua local cap; accessed via ModuleRefs).
  • In gui_advplayerslist.lua: share buttons render enabled/disabled overlays from unitPolicy.canShare and amountSendable; tooltips delegate to TeamTransfer.Units.TooltipText / ResourceTransfer.TooltipText; resource slider amounts come from policyResult.amountSendable; add SelectionChanged and SharePolicyChanged callins; hover tracking fires ApiExtensions.HandleHoverChange so invalid units are communicated to the selection-highlight widget.
  • In gui_selectedunits_gl4.lua + shaders: pipe a g_invalid varying from v_parameters.y through geom/vert/frag; units flagged invalid for the hovered receiver render with a red highlight; subscribe to AddHoverInvalidUnitsListener from the player-list API.
  • In gui_top_bar.lua: gate share-slider visibility on GetCachedPolicyResult(...).canShare; read ShareStats for sent/received; re-evaluate policy each tick so tech-unlocks show immediately. In gui_chat.lua: switch chat-message param protocol to positional :key:value pairs with explicit resourceType; use SendTransferChatMessageProtocolHighlights for coloring; skip UnitTaken logging when isTakeInProgress. In gui_teamstats.lua: overlay ShareStats.Read onto engine history for sent/received. Register SharePolicyChanged callin in barwidgets.lua.
  • Expand interface.json sharing tooltips into structured base/tech objects with disabled, allInvalid, buildDelay, stunDelay, invalid (pluralised) variants; add techBlocking and unitSharingMode i18n sections; add tech2TeamLost/tech3TeamLost tip keys. Add cmd_take.lua widget forwarding /take to synced gadget.

@github-actions

github-actions Bot commented Jun 22, 2026

Copy link
Copy Markdown
Contributor

Integration Test Results

18 tests  ±0   9 ✅ ±0   20s ⏱️ -1s
 1 suites ±0   8 💤 ±0 
 1 files   ±0   1 ❌ ±0 

For more details on these failures, see this check.

Results for commit 6c0061d. ± Comparison against base commit 20fd02b.

♻️ This comment has been updated with latest results.

@keithharvey keithharvey force-pushed the sharing/04-sharing-tab-ui branch from 7911463 to 41cb9cf Compare June 22, 2026 08:26
@keithharvey keithharvey force-pushed the sharing/03-tech-keystone branch from 0ac6d63 to 495ddd8 Compare June 22, 2026 18:03
@keithharvey keithharvey force-pushed the sharing/04-sharing-tab-ui branch from 41cb9cf to b05ed42 Compare June 22, 2026 18:03
@keithharvey keithharvey force-pushed the sharing/03-tech-keystone branch from 495ddd8 to e44eafa Compare June 22, 2026 19:05
@keithharvey keithharvey force-pushed the sharing/04-sharing-tab-ui branch from b05ed42 to 04252b9 Compare June 22, 2026 19:06
@keithharvey keithharvey force-pushed the sharing/03-tech-keystone branch from e44eafa to 470079c Compare June 24, 2026 07:58
@keithharvey keithharvey force-pushed the sharing/04-sharing-tab-ui branch 2 times, most recently from daa0b5b to 6b37fb4 Compare June 25, 2026 21:37
@keithharvey keithharvey force-pushed the sharing/03-tech-keystone branch from 470079c to 5da130f Compare June 25, 2026 21:37
@keithharvey keithharvey changed the title sharing 4/4: Sharing Tab UI sharing 4/5: Sharing Tab UI Jun 25, 2026
@keithharvey keithharvey force-pushed the sharing/04-sharing-tab-ui branch from 6b37fb4 to b58d6eb Compare June 25, 2026 22:26
@keithharvey keithharvey force-pushed the sharing/03-tech-keystone branch from 5da130f to 7fd7297 Compare June 25, 2026 22:26
@keithharvey keithharvey changed the title sharing 4/5: Sharing Tab UI sharing 5/6: Sharing Tab UI Jun 28, 2026
@keithharvey keithharvey force-pushed the sharing/04-sharing-tab-ui branch from b58d6eb to f22459c Compare June 28, 2026 06:51
@keithharvey keithharvey force-pushed the sharing/03-tech-keystone branch 2 times, most recently from 33bc2cb to ea791fa Compare June 28, 2026 07:24
@keithharvey keithharvey force-pushed the sharing/04-sharing-tab-ui branch 2 times, most recently from 9e8fe32 to aca03b5 Compare June 28, 2026 07:28
@keithharvey keithharvey force-pushed the sharing/03-tech-keystone branch from ea791fa to 73d078b Compare June 28, 2026 07:28
@keithharvey keithharvey changed the title sharing 5/6: Sharing Tab UI sharing 6/7: Sharing Tab UI Jun 28, 2026
@keithharvey keithharvey force-pushed the sharing/03-tech-keystone branch from 73d078b to b77838c Compare June 28, 2026 09:02
@keithharvey keithharvey force-pushed the sharing/04-sharing-tab-ui branch from aca03b5 to 5ec9c9b Compare June 28, 2026 09:02
@keithharvey keithharvey force-pushed the sharing/04-sharing-tab-ui branch from 304451c to 6d18f69 Compare June 30, 2026 08:17
@keithharvey keithharvey force-pushed the sharing/03-tech-keystone branch from 118a62c to 273b843 Compare July 1, 2026 20:32
@keithharvey keithharvey force-pushed the sharing/04-sharing-tab-ui branch from 6d18f69 to e00fa42 Compare July 1, 2026 20:32
@keithharvey keithharvey force-pushed the sharing/03-tech-keystone branch from 273b843 to 4f4337e Compare July 1, 2026 20:47
@keithharvey keithharvey force-pushed the sharing/04-sharing-tab-ui branch from e00fa42 to fd9faac Compare July 1, 2026 20:47
@keithharvey keithharvey force-pushed the sharing/03-tech-keystone branch from 4f4337e to b4e176d Compare July 4, 2026 06:38
@keithharvey keithharvey force-pushed the sharing/04-sharing-tab-ui branch from fd9faac to cb1120e Compare July 4, 2026 06:38
@keithharvey keithharvey force-pushed the sharing/03-tech-keystone branch from b4e176d to 6e48d13 Compare July 10, 2026 05:45
@keithharvey keithharvey force-pushed the sharing/04-sharing-tab-ui branch from cb1120e to 895d56e Compare July 10, 2026 05:45
@keithharvey keithharvey force-pushed the sharing/03-tech-keystone branch from 6e48d13 to a3e0e2e Compare July 10, 2026 09:40
@keithharvey keithharvey force-pushed the sharing/04-sharing-tab-ui branch from 895d56e to ce6c3d7 Compare July 10, 2026 09:41
@keithharvey keithharvey force-pushed the sharing/03-tech-keystone branch from a3e0e2e to 2297960 Compare July 10, 2026 10:19
@keithharvey keithharvey force-pushed the sharing/04-sharing-tab-ui branch from ce6c3d7 to 116f6a2 Compare July 10, 2026 10:19
@keithharvey keithharvey force-pushed the sharing/03-tech-keystone branch from 2297960 to dca19db Compare July 10, 2026 10:44
@keithharvey keithharvey force-pushed the sharing/04-sharing-tab-ui branch from 116f6a2 to 4e1afac Compare July 10, 2026 10:44
@keithharvey keithharvey force-pushed the sharing/03-tech-keystone branch from dca19db to cd71922 Compare July 15, 2026 07:34
@keithharvey keithharvey force-pushed the sharing/04-sharing-tab-ui branch from 4e1afac to cfbbc6a Compare July 15, 2026 07:34
@keithharvey keithharvey force-pushed the sharing/03-tech-keystone branch from cd71922 to 6834032 Compare July 15, 2026 20:06
@keithharvey keithharvey force-pushed the sharing/04-sharing-tab-ui branch from cfbbc6a to 5ddf04e Compare July 15, 2026 20:06
@keithharvey keithharvey force-pushed the sharing/03-tech-keystone branch from 6834032 to 21ffb7d Compare July 15, 2026 20:27
@keithharvey keithharvey force-pushed the sharing/04-sharing-tab-ui branch from 5ddf04e to 9b37bc7 Compare July 15, 2026 20:27
@keithharvey keithharvey force-pushed the sharing/03-tech-keystone branch from 21ffb7d to 90c8ce7 Compare July 15, 2026 20:37
@keithharvey keithharvey force-pushed the sharing/04-sharing-tab-ui branch from 9b37bc7 to 67948fc Compare July 15, 2026 20:37
@keithharvey keithharvey force-pushed the sharing/03-tech-keystone branch from 90c8ce7 to e68faff Compare July 15, 2026 22:17
@keithharvey keithharvey force-pushed the sharing/04-sharing-tab-ui branch from 67948fc to f170fa5 Compare July 15, 2026 22:17
@keithharvey keithharvey force-pushed the sharing/03-tech-keystone branch from e68faff to 192e574 Compare July 16, 2026 03:11
@keithharvey keithharvey force-pushed the sharing/04-sharing-tab-ui branch from f170fa5 to 2b37362 Compare July 16, 2026 03:11
@keithharvey keithharvey force-pushed the sharing/03-tech-keystone branch from 192e574 to 20fd02b Compare July 16, 2026 05:08
@keithharvey keithharvey force-pushed the sharing/04-sharing-tab-ui branch from 2b37362 to 6c0061d Compare July 16, 2026 05:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant