diff --git a/arkui/ace_js_attribute_api/src/main/js/MainAbility/pages/input/router/index.hml b/arkui/ace_js_attribute_api/src/main/js/MainAbility/pages/input/router/index.hml index 680b78b4553df3ea0788dd7bc2181f750cd16dfa..f1a1ad0e5aeafb024a7f13c892c15ca7282990d3 100644 --- a/arkui/ace_js_attribute_api/src/main/js/MainAbility/pages/input/router/index.hml +++ b/arkui/ace_js_attribute_api/src/main/js/MainAbility/pages/input/router/index.hml @@ -35,4 +35,7 @@ set/delete test + + watch test + diff --git a/arkui/ace_js_attribute_api/src/main/js/MainAbility/pages/input/router/index.js b/arkui/ace_js_attribute_api/src/main/js/MainAbility/pages/input/router/index.js index 1336e058a5212be35c70071c596edc7a0e209d45..032361ce9a4ada315d04e7b292cb449b30d0134a 100644 --- a/arkui/ace_js_attribute_api/src/main/js/MainAbility/pages/input/router/index.js +++ b/arkui/ace_js_attribute_api/src/main/js/MainAbility/pages/input/router/index.js @@ -22,6 +22,15 @@ export default { onInit() { this.$watch("watchVal", "onwatch") }, + onConfigurationUpdated(configuration) { + console.info("the configuration is " + JSON.stringify(configuration)); + let fontScale = configuration.fontScale; + let locate = configuration.locate; + let objectLocate = locate.unicodeSetting; + console.info("the fontScale " + fontScale); + console.info("the locate is " + JSON.stringify(locate)); + console.info("the objectLocate is " + JSON.stringify(objectLocate)); + }, functionTest1() { var function1 = this.$element('function1'); var result = function1.setStyle("font-size", "50px") @@ -53,6 +62,15 @@ export default { this.$delete('Version'); // log print:Version = undefined console.info("Version = " + this.Version); + + // add new attr test + console.info("this app is = " + this.$app); + console.info("this def is = " + this.$app.$def); + }, + functionTest7() { + let input = this.$refs.refname + console.info("this refs is = " + this.$refs); + console.info("this refs is = " + input); }, onwatch(newVal, oldVal) { console.log("watch newVal = " + newVal + ",oldVal =" + oldVal)