Skip to content

feat(core): add Sharing domain project mappings#1044

Merged
kunickiaj merged 1 commit into
mainfrom
05-05-feat_core_add_sharing_domain_project_mappings
May 6, 2026
Merged

feat(core): add Sharing domain project mappings#1044
kunickiaj merged 1 commit into
mainfrom
05-05-feat_core_add_sharing_domain_project_mappings

Conversation

@kunickiaj
Copy link
Copy Markdown
Owner

@kunickiaj kunickiaj commented May 6, 2026

Description

Adds core helpers for local project-to-Sharing-domain settings: list active domains, derive project candidates, and upsert/delete project mappings. Workspace-id-only and unknown/unmapped sessions are surfaced as Local only, and mapping writes validate active scope_id values without granting scope_memberships.

Stack slice: core foundation for codemem-ov4g.6.1.

Type of Change

  • 🚀 Feature (new functionality)
  • 🐛 Bug fix (fixes an issue)
  • 📚 Documentation (docs-only change)
  • 🔧 Maintenance (refactor, chore, CI, etc.)
  • 🧪 Testing (test-only changes)

Testing

  • Relevant checks pass locally (pnpm run tsc, pnpm run lint, pnpm run test)
  • Added/updated tests for changes
  • Manually verified changes work as expected

Validation run:

  • pnpm exec vitest run packages/core/src/project-scope-settings.test.ts
  • pnpm run tsc
  • touched-file Biome check

Checklist

  • Code follows project style (pnpm run lint passes for touched files)
  • Self-review completed
  • Documentation updated (if needed)
  • No new warnings introduced

Copy link
Copy Markdown
Owner Author

kunickiaj commented May 6, 2026

Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 335c14fec4

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread packages/core/src/project-scope-settings.ts Outdated
@kunickiaj kunickiaj force-pushed the 05-05-feat_core_add_sharing_domain_project_mappings branch from 335c14f to e5f66d3 Compare May 6, 2026 05:27
Copy link
Copy Markdown
Owner Author

kunickiaj commented May 6, 2026

Merge activity

  • May 6, 1:52 PM UTC: A user started a stack merge that includes this pull request via Graphite.
  • May 6, 1:52 PM UTC: @kunickiaj merged this pull request with Graphite.

@kunickiaj kunickiaj merged commit e99ee25 into main May 6, 2026
8 checks passed
@kunickiaj kunickiaj deleted the 05-05-feat_core_add_sharing_domain_project_mappings branch May 6, 2026 13:52
kunickiaj added a commit that referenced this pull request May 6, 2026
## Description
Adds viewer-server settings endpoints for Sharing-domain project mappings on top of the core helpers. The API lists domains/projects/mappings, saves mappings with strict field validation, rejects inactive or unknown `scope_id` values, and does not mutate `scope_memberships`.

Stack slice: viewer API for codemem-ov4g.6.1. Depends on #1044.

## Type of Change

- [x] 🚀 Feature (new functionality)
- [ ] 🐛 Bug fix (fixes an issue)
- [ ] 📚 Documentation (docs-only change)
- [ ] 🔧 Maintenance (refactor, chore, CI, etc.)
- [x] 🧪 Testing (test-only changes)

## Testing

- [x] Relevant checks pass locally (`pnpm run tsc`, `pnpm run lint`, `pnpm run test`)
- [x] Added/updated tests for changes
- [ ] Manually verified changes work as expected

Validation run:
- `pnpm exec vitest run packages/viewer-server/src/index.test.ts -t "updates local Sharing domain project mappings without granting membership"`
- `pnpm run tsc`
- touched-file Biome check

## Checklist

- [x] Code follows project style (`pnpm run lint` passes for touched files)
- [x] Self-review completed
- [x] Documentation updated (if needed)
- [x] No new warnings introduced
kunickiaj added a commit that referenced this pull request May 6, 2026
## Description
Adds the Settings UI surface for assigning known projects to Sharing domains. The panel shows Local-only fallback for unmapped/unknown projects, saves explicit project mappings through the viewer API, and avoids presenting coordinator/group membership as data access.

Stack slice: UI for codemem-ov4g.6.1. Depends on #1044 and #1045.

## Type of Change

- [x] 🚀 Feature (new functionality)
- [ ] 🐛 Bug fix (fixes an issue)
- [ ] 📚 Documentation (docs-only change)
- [ ] 🔧 Maintenance (refactor, chore, CI, etc.)
- [x] 🧪 Testing (test-only changes)

## Testing

- [x] Relevant checks pass locally (`pnpm run tsc`, `pnpm run lint`, `pnpm run test`)
- [x] Added/updated tests for changes
- [ ] Manually verified changes work as expected

Validation run:
- `pnpm exec vitest run packages/ui/src/tabs/settings/components/SharingDomainsPanel.test.tsx`
- `pnpm --filter @codemem/ui build`
- `pnpm run tsc`
- touched-file Biome check

## Checklist

- [x] Code follows project style (`pnpm run lint` passes for touched files)
- [x] Self-review completed
- [x] Documentation updated (if needed)
- [x] No new warnings introduced
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