feat(spec): add fieldGroups MVP to ObjectSchema#1199
Merged
xuyushun441-sys merged 5 commits intomainfrom Apr 21, 2026
Merged
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Adds simplified metadata-layer field grouping: - New ObjectFieldGroupSchema (key/label/icon/description/defaultExpanded/visibleOn) - Optional fieldGroups: ObjectFieldGroup[] on ObjectSchema; array order = display order - Group keys validated unique + snake_case; field→group via existing Field.group - 12 new tests; CHANGELOG updated under [Unreleased] Agent-Logs-Url: https://github.com/objectstack-ai/framework/sessions/9a38bcfa-8efb-46a2-a910-88a4f33364d8 Co-authored-by: xuyushun441-sys <255036401+xuyushun441-sys@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Add simplified field groups protocol for metadata layer MVP
feat(spec): add fieldGroups MVP to ObjectSchema
Apr 20, 2026
…ing guide - Add "Field Groups (MVP)" section to skills/objectstack-schema/SKILL.md with a full worked example, ObjectFieldGroup property table, and migration scope - Link fieldGroups in the "Important optional properties" table and references list - Add "Field Groups" section to content/docs/guides/data-modeling.mdx (with TOC entry) - Regenerate skill references via `pnpm --filter @objectstack/spec gen:skill-refs` so every skill's object.zod.ts copy now includes ObjectFieldGroupSchema (sync also picks up unrelated drift in manifest.zod.ts / dashboard.zod.ts / filter+query → objectstack-query move, per the script's source-of-truth role) Agent-Logs-Url: https://github.com/objectstack-ai/framework/sessions/2dfd93fb-72b4-4e49-bbba-c239c6b5b81c Co-authored-by: xuyushun441-sys <255036401+xuyushun441-sys@users.noreply.github.com>
…unity/Lead
Declare logical `fieldGroups` on each of the four primary CRM objects and
opt every field in via `group: '<key>'`. No business-logic changes — only
form-layout metadata — so validations, workflows, indexes, and state
machines are unaffected.
- Account: basic / financials / contact_info / ownership / branding / system
- Contact: identity / account_info / contact_info / mailing_address /
additional / preferences
- Opportunity: basic / financials / sales_process / classification /
competition / notes / forecast
- Lead: identity / company_info / contact_info / qualification / assignment /
address / additional / preferences / conversion
Verified every field maps to a declared group key (0 orphaned, 0 ungrouped)
and all four objects parse successfully with `ObjectSchema.safeParse`.
Pre-existing typecheck errors in `src/views/lead.view.ts` and
`objectstack.config.ts` (unrelated `'1'|'2'|'3'|'4'` string enum and
sharing-rule types) are untouched by this change.
CHANGELOG entry added under `[Unreleased] → Changed`.
Agent-Logs-Url: https://github.com/objectstack-ai/framework/sessions/c2759af4-65bb-4cff-8b2b-ed605c936273
Co-authored-by: xuyushun441-sys <255036401+xuyushun441-sys@users.noreply.github.com>
Contributor
|
@claude[agent] resolve the merge conflicts in this pull request |
Copilot stopped work on behalf of
xuyushun441-sys due to an error
April 21, 2026 04:04
|
Deployment failed with the following error: View Documentation: https://vercel.com/docs/accounts/team-members-and-roles |
|
Deployment failed with the following error: View Documentation: https://vercel.com/docs/accounts/team-members-and-roles |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
examples/app-crm — showcase
fieldGroupsMVPWires the new
fieldGroupsprotocol (added in this same PR's spec commit) into the CRM reference example so users have a realistic, multi-group starting point when designing forms and detail pages.fieldGroupsshowcaseaccount.object.ts— 6 groups (basic / financials / contact_info / ownership / branding / system)contact.object.ts— 6 groups (identity / account_info / contact_info / mailing_address / additional / preferences)opportunity.object.ts— 7 groups (basic / financials / sales_process / classification / competition / notes / forecast)lead.object.ts— 9 groups (identity / company_info / contact_info / qualification / assignment / address / additional / preferences / conversion)[Unreleased] → ChangedentryObjectSchema.safeParse()on all four objects →parsed=true, 0 ungrouped, 0 orphaned field → group referencessrc/views/lead.view.tsandobjectstack.config.tsare unrelated to this change)Earlier commits in this PR (context)
ObjectFieldGroupSchema+ObjectSchema.fieldGroupsadded topackages/spec/src/data/object.zod.tsobject.test.ts(all green; full spec suite 6827/6827)skills/objectstack-schema/SKILL.mdcontent/docs/guides/data-modeling.mdxgen:skill-refsDesign notes (recap)
packages/spec— schema-only.orderproperty on groups.Field.groupis the sole field → group assignment mechanism; in-group display order =ObjectSchema.fieldstraversal order.Field.group. Explicit per-field in-group ordering deferred.