[break] fix(assets): align property schema with config schema#688
Open
Changdw wants to merge 1 commit into
Open
[break] fix(assets): align property schema with config schema#688Changdw wants to merge 1 commit into
Changdw wants to merge 1 commit into
Conversation
yanOO1497
approved these changes
Jun 26, 2026
star-e
approved these changes
Jun 29, 2026
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.
主要变更
在 #677 上做的一点调整
本 PR 的核心变更是:
assets.queryPropertySchema(importer)返回的属性 schema,改为直接使用配置系统的ICocosConfigurationPropertySchema。顶层返回仍保持
Record<string, ICocosConfigurationPropertySchema>,不额外包{ type: 'object', properties: ... }。调用方拿到的仍是“属性名 -> 属性 schema”的 map,但 value 字段与配置系统保持一致。配套变更
为支持主变更,同步做了这些调整:
AssetPropertySchemaMap改为Record<string, ICocosConfigurationPropertySchema>AssetPropertySchema / AssetPropertySchemaOption / AssetPropertySchemaTypeassets-query-property-schema的 Zod result schema 改为配置系统字段propertySchemaConfig源头从旧 Creator 风格配置改为配置系统 schemaqueryPropertySchema不再从userDataConfig.defaultfallback 转换,只返回显式声明的propertySchemaConfigqueryAssetConfigMap的旧 userData config 行为保持不变字段变化:
labeltitleoptionsenum+enumDescriptionsminminimummaxmaximumitemConfigspropertiesraw