mirror of
https://github.com/block/buzz.git
synced 2026-12-01 05:32:24 +00:00
## Summary - add custom-agent catalog sharing and hide built-ins from discovery - let owners publish later catalog updates from Share or while saving edits — the save always persists locally, and the publish reports `published` or `queued` (flushed automatically once the relay is reachable again) - preserve agent type, model, and runtime across snapshot import/export - simplify agent and team entry points and tighten catalog layout - migrate the legacy global retention queue into the owner's active scope so pending catalog publishes survive the upgrade - keep the agent list and edits usable in recovery mode by degrading to unshared projections when scope resolution or the retention DB fails - track catalog provenance on copied personas, so adding an already-added foreign agent resolves to the existing copy instead of creating a duplicate - scope inbound persona events to the community relay they arrived on - page the catalog read past the relay's 1,000-row query clamp - unify the share dialog's memory-level choice into a single "What's included" selector that drives both DM-send and copy-link delivery (all six combinations preserved), group the delivery rows above the option rows, and label the catalog toggle "Not shared" / "Shared" - keep emoji avatars on catalog entries — they persist as inline percent-encoded SVG, which the catalog projection's http(s)-only URL guard used to drop, so a shared agent showed initials instead of its avatar - drop the "Active in communities" card from Agents settings, superseded by the per-channel runtime controls in the members sidebar ## Screenshots ### Agent actions  ### Team avatar stack  ### Catalog sharing  ### Publish while editing  ### Publish from Share  ### Catalog details  --------- Signed-off-by: kenny lopez <klopez4212@gmail.com> Signed-off-by: Will Pfleger <pfleger.will@gmail.com> Co-authored-by: Will Pfleger <pfleger.will@gmail.com>
71 lines
1.9 KiB
TypeScript
71 lines
1.9 KiB
TypeScript
import { Button } from "@/shared/ui/button";
|
|
|
|
type AgentDefinitionDialogFooterProps = {
|
|
canSubmit: boolean;
|
|
isAvatarUploadPending: boolean;
|
|
isPending: boolean;
|
|
onCancel: () => void;
|
|
publishesCatalogUpdates: boolean;
|
|
submitBlockReason: string | null;
|
|
submitLabel: string;
|
|
};
|
|
|
|
export function AgentDefinitionDialogFooter({
|
|
canSubmit,
|
|
isAvatarUploadPending,
|
|
isPending,
|
|
onCancel,
|
|
publishesCatalogUpdates,
|
|
submitBlockReason,
|
|
submitLabel,
|
|
}: AgentDefinitionDialogFooterProps) {
|
|
return (
|
|
<div className="flex w-full flex-wrap items-center justify-between gap-3">
|
|
<div className="flex min-h-9 min-w-0 flex-wrap items-center gap-3">
|
|
{submitBlockReason ? (
|
|
<p
|
|
className="text-2xs text-muted-foreground"
|
|
data-testid="persona-dialog-submit-reason"
|
|
>
|
|
{submitBlockReason}
|
|
</p>
|
|
) : null}
|
|
{publishesCatalogUpdates ? (
|
|
<p
|
|
className="max-w-sm text-xs text-muted-foreground"
|
|
data-testid="persona-dialog-catalog-publish-notice"
|
|
>
|
|
This agent is in the community catalog. Your changes will be
|
|
published when you save.
|
|
</p>
|
|
) : null}
|
|
</div>
|
|
|
|
<div className="flex items-center gap-2">
|
|
<Button
|
|
disabled={isPending || isAvatarUploadPending}
|
|
onClick={onCancel}
|
|
type="button"
|
|
variant="outline"
|
|
>
|
|
Cancel
|
|
</Button>
|
|
<Button
|
|
data-testid="persona-dialog-submit"
|
|
disabled={!canSubmit}
|
|
form="persona-dialog-form"
|
|
type="submit"
|
|
>
|
|
{isPending
|
|
? "Saving..."
|
|
: isAvatarUploadPending
|
|
? "Uploading..."
|
|
: publishesCatalogUpdates
|
|
? "Save and publish"
|
|
: submitLabel}
|
|
</Button>
|
|
</div>
|
|
</div>
|
|
);
|
|
}
|