Esempio n. 1
0
 public ValueTask DispatchEvent(ElemRef e, string eventType) =>
 mod.InvokeVoidAsync("Act.DispatchEvent", e.Key, eventType);
Esempio n. 2
0
 public ValueTask Click(ElemRef e) =>
 mod.InvokeVoidAsync("Act.Click", e.Key);
Esempio n. 3
0
 public ValueTask SetValue(ElemRef e, string v) =>
 // Useful for setting component values that are private
 mod.InvokeVoidAsync("Act.SetValue", e.Key, v);
Esempio n. 4
0
 public ValueTask <string> GetContent(ElemRef e, bool htmlFormat) =>
 mod.InvokeAsync <string>("Act.GetContent", e.Key, htmlFormat);
Esempio n. 5
0
 public ValueTask <string> SetContent(ElemRef e, string newContent) =>
 mod.InvokeAsync <string>("Act.SetContent", e.Key, newContent);
Esempio n. 6
0
 /// <summary>
 /// Get the html content of an html element.
 /// </summary>
 public ValueTask <string> HtmlContent(ElemRef e) => GetContent(e, true);
Esempio n. 7
0
 /// <summary>
 /// Get the text content of an html element
 /// </summary>
 public ValueTask <string> TextContent(ElemRef e) => GetContent(e, false);
Esempio n. 8
0
 /// <summary>
 /// Replace the content of an element with new content.
 /// </summary>
 public ValueTask <string> SetContent(ElemRef e, string html) => JS.SetContent(e, html);
Esempio n. 9
0
        // Simulating user actions in the browser is a security issue.
        // Manually firing events does NOT trigger default actions.
        // e.g. Firing a KeyEvent on a text field will not update the UI.
        //public ValueTask SendKeys(ElemRef e, string v) => JS.SendKeys(e, v);

        ValueTask <string> GetContent(ElemRef e, bool asHtml) => JS.GetContent(e, asHtml);
Esempio n. 10
0
 public ValueTask DispatchEvent(ElemRef e, string eType) => JS.DispatchEvent(e, eType);
Esempio n. 11
0
 /// <summary>
 /// Set html element.value = v
 /// </summary>
 public ValueTask SetValue(ElemRef e, string v) => JS.SetValue(e, v);
Esempio n. 12
0
 /// <summary>
 /// Send a click event to an html element.
 /// </summary>
 public ValueTask Click(ElemRef e) => JS.Click(e);