mirror of
https://github.com/greenart7c3/Amber.git
synced 2026-10-06 03:18:23 +00:00
Show group options above the request cards, even when collapsed
Move each group's options panel to render right under the group header, outside the expanded check, so the remember and scope selectors are always visible without expanding the group or scrolling past its cards. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01REtTRsYA3aUGpmbjENbNVb
This commit is contained in:
+13
-13
@@ -190,6 +190,19 @@ fun BunkerMultiEventHomeScreen(
|
||||
)
|
||||
}
|
||||
}
|
||||
if (groupKey.hasGroupOptions()) {
|
||||
item(key = "group-options:${groupKey.type.name}:${groupKey.payload?.name ?: ""}:${groupKey.kind ?: ""}") {
|
||||
RequestGroupOptions(
|
||||
groupKey = groupKey,
|
||||
rememberType = groupRememberTypes[groupKey] ?: RememberType.NEVER,
|
||||
onRememberTypeChanged = { groupRememberTypes[groupKey] = it },
|
||||
relayAuthScope = groupRelayAuthScopes[groupKey] ?: RelayAuthScope.SPECIFIC,
|
||||
onRelayAuthScopeChanged = { groupRelayAuthScopes[groupKey] = it },
|
||||
decryptTypeScope = groupDecryptScopes[groupKey] ?: defaultDecryptTypeScope(groupKey.type),
|
||||
onDecryptTypeScopeChanged = { groupDecryptScopes[groupKey] = it },
|
||||
)
|
||||
}
|
||||
}
|
||||
if (expanded) {
|
||||
items(groupItems, key = { it.request.id }) { bunkerRequest ->
|
||||
BunkerRequestCard(
|
||||
@@ -202,19 +215,6 @@ fun BunkerMultiEventHomeScreen(
|
||||
},
|
||||
)
|
||||
}
|
||||
if (groupKey.hasGroupOptions()) {
|
||||
item(key = "group-options:${groupKey.type.name}:${groupKey.payload?.name ?: ""}:${groupKey.kind ?: ""}") {
|
||||
RequestGroupOptions(
|
||||
groupKey = groupKey,
|
||||
rememberType = groupRememberTypes[groupKey] ?: RememberType.NEVER,
|
||||
onRememberTypeChanged = { groupRememberTypes[groupKey] = it },
|
||||
relayAuthScope = groupRelayAuthScopes[groupKey] ?: RelayAuthScope.SPECIFIC,
|
||||
onRelayAuthScopeChanged = { groupRelayAuthScopes[groupKey] = it },
|
||||
decryptTypeScope = groupDecryptScopes[groupKey] ?: defaultDecryptTypeScope(groupKey.type),
|
||||
onDecryptTypeScopeChanged = { groupDecryptScopes[groupKey] = it },
|
||||
)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+13
-13
@@ -156,6 +156,19 @@ fun IntentMultiEventHomeScreen(
|
||||
)
|
||||
}
|
||||
}
|
||||
if (groupKey.hasGroupOptions()) {
|
||||
item(key = "group-options:${groupKey.type.name}:${groupKey.payload?.name ?: ""}:${groupKey.kind ?: ""}") {
|
||||
RequestGroupOptions(
|
||||
groupKey = groupKey,
|
||||
rememberType = groupRememberTypes[groupKey] ?: RememberType.NEVER,
|
||||
onRememberTypeChanged = { groupRememberTypes[groupKey] = it },
|
||||
relayAuthScope = groupRelayAuthScopes[groupKey] ?: RelayAuthScope.SPECIFIC,
|
||||
onRelayAuthScopeChanged = { groupRelayAuthScopes[groupKey] = it },
|
||||
decryptTypeScope = groupDecryptScopes[groupKey] ?: defaultDecryptTypeScope(groupKey.type),
|
||||
onDecryptTypeScopeChanged = { groupDecryptScopes[groupKey] = it },
|
||||
)
|
||||
}
|
||||
}
|
||||
if (expanded) {
|
||||
items(groupIntents, key = { it.id }) { intent ->
|
||||
IntentRequestCard(
|
||||
@@ -168,19 +181,6 @@ fun IntentMultiEventHomeScreen(
|
||||
},
|
||||
)
|
||||
}
|
||||
if (groupKey.hasGroupOptions()) {
|
||||
item(key = "group-options:${groupKey.type.name}:${groupKey.payload?.name ?: ""}:${groupKey.kind ?: ""}") {
|
||||
RequestGroupOptions(
|
||||
groupKey = groupKey,
|
||||
rememberType = groupRememberTypes[groupKey] ?: RememberType.NEVER,
|
||||
onRememberTypeChanged = { groupRememberTypes[groupKey] = it },
|
||||
relayAuthScope = groupRelayAuthScopes[groupKey] ?: RelayAuthScope.SPECIFIC,
|
||||
onRelayAuthScopeChanged = { groupRelayAuthScopes[groupKey] = it },
|
||||
decryptTypeScope = groupDecryptScopes[groupKey] ?: defaultDecryptTypeScope(groupKey.type),
|
||||
onDecryptTypeScopeChanged = { groupDecryptScopes[groupKey] = it },
|
||||
)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user