From 495069b812ca198d6be0d277b943f123cade1c74 Mon Sep 17 00:00:00 2001 From: Yingchun Date: Wed, 22 Oct 2025 11:43:45 +0800 Subject: [PATCH 1/3] feat: add pictorial for oppo card --- packages/hap-compiler/src/style/mediaquery.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/hap-compiler/src/style/mediaquery.js b/packages/hap-compiler/src/style/mediaquery.js index b6c21f3..9a53ed8 100644 --- a/packages/hap-compiler/src/style/mediaquery.js +++ b/packages/hap-compiler/src/style/mediaquery.js @@ -114,7 +114,7 @@ const featureValidator = { }, scene(value) { const reg = - /^(assistantscreen|launcher|globalsearch|calendar|lockscreen|suggestion|voiceassistant|sms|servicecenter|cardesktop)$/ + /^(assistantscreen|launcher|globalsearch|calendar|lockscreen|suggestion|voiceassistant|sms|servicecenter|cardesktop|pictorial)$/ if (reg.test(value)) { return { value } } @@ -125,7 +125,7 @@ const featureValidator = { feature + '` 的值 `' + value + - '` 不正确, 必须为 `assistantscreen | launcher | globalsearch | calendar | lockscreen | suggestion | voiceassistant | sms | servicecenter | cardesktop`' + '` 不正确, 必须为 `assistantscreen | launcher | globalsearch | calendar | lockscreen | suggestion | voiceassistant | sms | servicecenter | cardesktop | pictorial`' ) } } From b9b6a6a6fe404dadae8eb2ad4ee6c09cce1988e8 Mon Sep 17 00:00:00 2001 From: Yingchun Date: Thu, 6 Nov 2025 20:29:53 +0800 Subject: [PATCH 2/3] feat: add segmented type for progress --- packages/hap-compiler/src/template/validator.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/hap-compiler/src/template/validator.js b/packages/hap-compiler/src/template/validator.js index a7b2704..6100bda 100644 --- a/packages/hap-compiler/src/template/validator.js +++ b/packages/hap-compiler/src/template/validator.js @@ -550,7 +550,7 @@ const tagNatives = { def: 0 }, type: { - enum: ['horizontal', 'circular', 'round'] + enum: ['horizontal', 'circular', 'round', 'segmented'] } } }, From 88c92d4565366828b718c93482294df6c2a9138f Mon Sep 17 00:00:00 2001 From: Yingchun Date: Fri, 14 Nov 2025 18:30:02 +0800 Subject: [PATCH 3/3] fix: remove unused code --- packages/hap-compiler/src/style/validator.js | 26 ++++++++++---------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/packages/hap-compiler/src/style/validator.js b/packages/hap-compiler/src/style/validator.js index 6ac08f7..1fe92dc 100755 --- a/packages/hap-compiler/src/style/validator.js +++ b/packages/hap-compiler/src/style/validator.js @@ -400,19 +400,19 @@ const validateTime = function (v) { } } // 灵感组件颜色值 -const themeColors = [ - 'uxCardColorBackground', - 'uxCardColorAccent', - 'uxCardColorTheme', - 'uxCardColorContainer', - 'uxCardColorPrimary', - 'uxCardColorQuaternary', - 'uxCardColorSecondary', - 'uxCardColorSecondaryVariant', - 'uxCardColorTertiary', - 'uxCardColorHue', - 'uxCardColorHueSecondary' -] +// const themeColors = [ +// 'uxCardColorBackground', +// 'uxCardColorAccent', +// 'uxCardColorTheme', +// 'uxCardColorContainer', +// 'uxCardColorPrimary', +// 'uxCardColorQuaternary', +// 'uxCardColorSecondary', +// 'uxCardColorSecondaryVariant', +// 'uxCardColorTertiary', +// 'uxCardColorHue', +// 'uxCardColorHueSecondary' +// ] const validator = { /** * 整数校验