websocket.axml 884 B

1234567891011121314151617181920
  1. <view class="container">
  2. <view class="subView">
  3. <input class="server_addr" placeholder="wss://YourServer/" onConfirm="onServerAddressComplete" onBlur="onServerAddressComplete"/>
  4. </view>
  5. <view class="subView">
  6. <button class="buttons" name="startButton" onTap="connect_start">开始连接</button>
  7. </view>
  8. <view class="subView" a:if="{{sendMessageAbility}}">
  9. <input class="message_text" placeholder="输入要发送的消息:" onConfirm="onSendMessageReady" onBlur="onSendMessageReady"/>
  10. </view>
  11. <view class="subView" a:if="{{sendMessageAbility}}">
  12. <button class="buttons" name="sendButton" onTap="send_start">发送数据</button>
  13. </view>
  14. <view class="subView" a:if="{{closeLinkAbility}}">
  15. <button class="buttons" name="closeButton" onTap="close_start">关闭</button>
  16. </view>
  17. <view>
  18. <text class="run_log">{{log}}</text>
  19. <view/>
  20. </view>