element_getInnerElement
Query a single child element within a scoped container using selector and targetSelector. Returns element summary; use to narrow search inside custom components.
Instructions
在一个已定位元素的范围内查询单个子元素(element.$(targetSelector)),返回该子元素摘要(tagName/text/value/size/offset)。用法:selector(+可选 innerSelector)先定位作用域元素,targetSelector 是在该作用域内执行的查询 —— 适合在某容器/自定义组件内部缩小查询范围;若从页面根查询请用 page_getElement。withWxml=true 时额外返回该子元素的完整 outerWxml(可能很大)。结果超过 maxBytes(默认 50000B)返回 {truncated,bytes,maxBytes,note,data} 包装,关掉 withWxml 或调大 maxBytes。selector 支持 [index=N](仅作用于 selector,innerSelector/targetSelector 内不支持下标)。
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| maxBytes | No | ||
| selector | Yes | ||
| withWxml | No | ||
| connection | No | 可选连接覆盖(不传则用默认会话)。可用字段:mode(launch|connect)、cliPath、projectPath、wsEndpoint、timeout、port(【自动化端口】→ cli auto --auto-port,默认 9420;不是 IDE HTTP 服务端口,别把 IDE 服务端口传进来)、account、ticket、trustProject、args、cwd、autoClose、autoLaunch、launchTimeout、connectTimeout。 | |
| innerSelector | No | ||
| targetSelector | Yes |