你好我試圖像將焦點設置在輸入框 - 角JS
輸入框代碼上點擊按鈕ng_focus:
<input type="text" placeholder="" class="promocode" ng-focus="focus" ng-model="text" value="" />
按鈕代碼:
<span ng-click="text = 'sheetesh'; focus=true"> Sheetesh </span>
<p>focus: {{focus}}</p>
及其返回真實cli CK在跨度上,但重點不工作。
重點:真正
屏幕截圖: its showing like that
'NG-focus'不設置焦點。這就像'ng-click'。聚焦事件發生時,將執行'ng-focus'的值。 –