dom_tools library
DOM Tools Library
Classes
- AnyUriPolicy
- Allows anu Uri policy.
- CanvasImageViewer
- An image viewer that can render points, rectangles, clip and grid over.
- Color
- Represents a color.
- CSSAnimationConfig
- CSSAnimationConfigElements
- CSS animation configuration for a List<Element>.
- CSSAnimationConfigGroup
- CSS animation configuration for a group of CSSAnimationConfig.
- CSSThemeSet
- A Theme set, with multiples themes.
- CSSValueBase
- DataAssets
-
A collections of assets (DataURL, Blob, MediaSource) that can be accessed
by an
ObjectURL, avoiding usage and encoding to data URL (base64). - DataStorage
- Represents a persistent storage in the browser.
-
DOMTreeReferenceMap<
V> -
A
TreeReferenceMapfor DOM Nodes. - FilterResult
- Filter result.
- HSLColor
- A color represented using alpha, hue, saturation, and lightness.
- HSVColor
- A color represented using alpha, hue, saturation, and value.
- ImagePerspectiveFilter
- A filter that applies a perspective to an image.
- ImagePerspectiveFilterCache
- A cache for perspective filers.
- ImageScaledCache
- A cache for scaled images.
-
Label<
T extends num> - State
- A state stored in DataStorage.
- StorageValue
- Represents a value stored in State.
- StyleColor
- Specifies a CSS color.
- TextStyle
- Specifies a CSS text style.
- TrackElementInViewport
- Tracks a DOM Element to identify when its visible in viewport.
- TrackElementResize
- Tracks a DOM Element to identify when its size changes.
- TrackElementValue
- Tracks a DOM Element to identify when a value changes.
-
ViewerElement<
T> - Represents an element in the CanvasImageViewer.
Enums
- DataStorageType
- Type of DataStorage.
- EditionType
- The type of edition for CanvasImageViewer.
- FontStyle
- Specifies a CSS font style.
- FontWeight
- Specifies a CSS font weight.
- Quality
- Quality of an image.
- StateOperation
- State operation.
- TouchDeviceDetection
- Status type of touch device detection.
Extensions
Constants
-
codeTheme0
→ const Map<
String, TextStyle> -
codeTheme1
→ const Map<
String, TextStyle> -
codeTheme2
→ const Map<
String, TextStyle> - cssMaxZIndex → const int
Properties
- codeTheme → CSSThemeSet
-
final
- deviceHeight → int?
-
no setter
- deviceWidth → int?
-
no setter
- isExtraLargeDevice → bool
-
no setter
- isExtraSmallDevice → bool
-
no setter
- isLargeDevice → bool
-
no setter
- isLargeDeviceOrHigher → bool
-
no setter
- isLargeDeviceOrLower → bool
-
no setter
- isMediumDevice → bool
-
no setter
- isMediumDeviceOrLHigher → bool
-
no setter
- isMediumDeviceOrLower → bool
-
no setter
- isSmallDevice → bool
-
no setter
- isSmallDeviceOrHigher → bool
-
no setter
- isSmallDeviceOrLower → bool
-
no setter
-
onDetectTouchDevice
→ EventStream<
TouchDeviceDetection> -
Will fire a TouchDeviceDetection when detection finishes.
final
Functions
-
addCSSCode(
String cssCode) → Future< bool> -
Adds a CSS code (
cssCode) into DOM. -
addCssSource(
String cssSource, {int? insertIndex}) → Future< bool> -
Add a CSS path using a
linkelement intoheadDOM node. -
addElementsClasses(
Iterable< Element> elements, Iterable<String> classes) → bool -
Add to
elementsa set ofclasses. Will remove classes starting with '!'. -
addJavaScriptCode(
String scriptCode) → Future< bool> -
Adds a JavaScript code (
scriptCode) into DOM. -
addJavaScriptSource(
String scriptSource, {bool addToBody = false, bool async = false}) → Future< bool> -
Adds a JavaScript path (
scriptSource] into DOM. -
addJSFunction(
String name, List< String> parameters, String body) → Future<bool> - Adds a JavaScript function into DOM.
-
animateCSSSequence(
Iterable< CSSAnimationConfig> animationsConfig, {Duration? initialDelay, int? repeat, bool? repeatInfinity}) → Future<void> ? -
Sames
animateCSSbut runsanimationsConfigin sequence; -
appendElementInnerHTML(
Element element, String html, {NodeValidator? validator}) → void -
Appends to the inner HTML of
elementwith parsed result ofhtml. -
applyCSS(
CssStyleDeclaration css, Element element, [List< Element> ? extraElements]) → bool -
Applies
csstoelementandextraElementslist if present. -
applyPerspective(
CanvasImageSource image, List< Point< perspective) → FilterResult?num> > -
Apply
perspectivefilter toimage. -
asCssStyleDeclaration(
dynamic css) → CssStyleDeclaration -
Parses dynamic
cssas CssStyleDeclaration. -
blockHorizontalScrollTraverse(
Element element) → void -
Blocks a scroll event in the horizontal direction that traverses the
element. -
blockHorizontalScrollTraverseEvent(
Element element, WheelEvent wheelEvent) → bool -
Blocks a
wheelEventin the horizontal direction that traverses theelement. -
blockScrollTraverse(
Element element) → void -
Blocks a scroll event in the vertical and horizontal directions that traverses the
element. -
blockVerticalScrollTraverse(
Element element) → void -
Blocks a scroll event in the vertical direction that traverses the
element. -
blockVerticalScrollTraverseEvent(
Element element, WheelEvent wheelEvent) → bool -
Blocks a
wheelEventin the vertical direction that traverses theelement. -
buildMetaContent(
Map< String, String?> map) → String -
Builds a
metacontent frommap. -
callJSFunction(
String method, [List? args]) → dynamic -
Calls JavaScript a function
methodwithargs. -
callJSObjectMethod(
Object o, String method, [List? args]) → dynamic -
Calls JavaScript a
methodin objectowithargs. -
canvasToImageElement(
CanvasElement canvas, [String? mimeType, num? quality]) → ImageElement -
Converts
canvasto ImageElement -
clearSelections(
) → void - Clears selected text in vieport.
-
copyElementToClipboard(
Element element) → bool -
Copies
elementtext to Clipboard. -
copyPoints(
List< Point< points) → List<num> >Point< num> > -
Makes a copy of
points. -
createDiv(
[bool inline = false, String? html, NodeValidator? validator]) → DivElement -
Creates a
div.inlineIftruesetsdisplay: inline-block.htmlThe HTML to parse as content. -
createDivInline(
[String? html]) → DivElement -
Creates a
divwithdisplay: inline-block. -
createDivInlineBlock(
) → DivElement -
Creates a
divwithdisplay: inline-block. -
createHTML(
[String? html, NodeValidator? validator]) → Element - Creates a HTML Element. Returns 1st node form parsed HTML.
-
createImageElementFromBase64(
String? base64, [String? mimeType]) → ImageElement? -
Creates an image from a Base-64 with
mimeType. -
createImageElementFromFile(
File file) → Future< ImageElement> -
Creates an image from a
file. -
createLabel(
[String? html, NodeValidator? validator]) → LabelElement -
Creates a
labelelement. -
createScaledImage(
CanvasImageSource image, int width, int height, double scale) → CanvasImageSource -
Creates a new image from
image, ofwidthandheight, to ascale. -
createSpan(
[String? html, NodeValidator? validator]) → SpanElement -
Creates a
spanelement. -
createStandardNodeValidator(
{bool svg = true, bool allowSvgForeignObject = false}) → NodeValidatorBuilder -
cropImage(
CanvasImageSource image, int x, int y, int width, int height) → CanvasElement? -
Crops the
imageusing coordinatesx,y,widthandheight, returning new image (CanvasElement). -
cropImageByRectangle(
CanvasImageSource image, Rectangle< num> ? crop) → CanvasElement? -
Crops an image using a Rectangle (
crop), delegating to method cropImage, -
dataURLToBlob(
DataURLBase64 dataURL) → Blob -
Converts a
dataURLto a Blob. -
defineCSS(
CssStyleDeclaration? currentCSS, CssStyleDeclaration? appendCSS, [dynamic defaultCSS]) → CssStyleDeclaration -
Defines a new CssStyleDeclaration merging
currentCSSandappendCSS. -
detectTouchDevice(
) → TouchDeviceDetection? - Starts touch device detection. Returns the current status.
-
disableDoubleClicks(
) → void - Disables browser double clicks/tap.
-
disableScrolling(
) → void - Disables scrolling in browser.
-
disableZooming(
) → void - Disables browser zooming.
-
downloadBlob(
Blob blob, String fileName) → void -
Downloads
blobof typemimeType, saving a file withfileName. -
downloadBytes(
List< int> bytes, MimeType mimeType, String fileName) → void -
Downloads
bytesof typemimeType, saving a file withfileName. -
downloadContent(
List< String> content, MimeType mimeType, String fileName) → void -
Downloads
contentof typemimeType, saving a file withfileName. -
downloadDataURL(
DataURLBase64 dataURL, String fileName) → void -
Downloads
dataURL, saving a file withfileName. -
elementMatchesAttribute(
Element element, String attributeName, dynamic attributeValue) → bool -
Returns
trueifelementmatchesattributeNameandattributeValue. -
elementMatchesAttributes(
Element element, Map< String, dynamic> attributes) → bool -
Returns
trueifelementmatchesattributes. -
elementOnLoad(
ImageElement img) → Future< bool> -
Returns a Future<bool> for when
imgloads. -
enableScrolling(
) → void - Enables scrolling in browser.
-
evalJS(
String scriptCode) → dynamic -
Call
eval()with the content ofscriptCodeand returns the result. -
getAllCssRuleBySelector(
Pattern targetSelector, CssStyleSheet? sheet) → List< CssRule> -
Returns a List<CssRule> for
targetSelector. -
getAllCssStyleSheet(
) → List< CssStyleSheet> - Returns all current CssStyleSheet.
-
getAllMediaCssRule(
String mediaCondition) → List< CssMediaRule> -
Returns a list of @media CssRule with
mediaCondition. -
getAllOutOfViewportMediaCssRule(
int viewportWidth, dynamic viewportHeight) → List< CssMediaRule> -
Returns all CssMediaRule not applied for
viewportWidthandviewportHeight. -
getAllOutOfViewportMediaCssRuleAsClassRule(
int viewportWidth, dynamic viewportHeight, String targetClass) → List< String> -
Transforms all CssMediaRule to
targetClassrule not applied forviewportWidthandviewportHeight. -
getAllViewportMediaCssRule(
int viewportWidth, dynamic viewportHeight) → List< CssMediaRule> -
Returns all CssMediaRule applied for
viewportWidthviewportHeight. -
getAllViewportMediaCssRuleAsClassRule(
int viewportWidth, dynamic viewportHeight, String targetClass) → List< String> -
Transforms all CssMediaRule to
targetClassrule applied forviewportWidthandviewportHeight. -
getAnchorElementByHREF(
String href) → AnchorElement? -
Selects an AnchorElement in DOM with
href. -
getComputedStyle(
{Element? parent, Element? element, String? classes, String? style, }) → CssStyleDeclaration - Returns a CssStyleDeclaration from an element.
-
getElementAllCssProperties(
Element element) → List< String> -
Returns a list of CSS properties associated with
element -
getElementAllCssRule(
Element element) → List< CssRule> -
Returns a list of CssRule associated with
element. -
getElementAttribute(
Element element, Object? key) → String? -
Returns
elementattribute withkey. -
getElementAttributeRegExp(
Element element, RegExp key) → String? -
Returns
elementattribute with RegExpkey. -
getElementAttributeStr(
Element element, String key) → String? -
Returns
elementattribute with Stringkey. -
getElementByHREF(
String tag, String href) → Element? -
Selects an Element in DOM with
tagandhref. -
getElementBySRC(
String tag, String src) → Element? -
Selects an Element in DOM with
tagandsrc. -
getElementByValues<
V> (String tag, ElementValueGetter getter, List< V> values, [ElementValueGetter? getter2, List<V> ? values2]) → Element? -
selects in DOM an Element with
tagand one ofvaluesprovided bygetter. -
getElementDocumentPosition(
Element element) → Pair< num> - Returns the X and Y position of Element int the Document.
-
getElementHeight(
Element element, [int? def]) → int? -
Returns
elementheight. Tries to use 'offsetHeight' or 'style.height' values. -
getElementHREF(
Element element) → String? -
Returns
hrefvalue for different Element types. -
getElementPreComputedStyle(
Element element) → CssStyleDeclaration -
Returns a CssStyleDeclaration of the pre-computed CSS properties of
element. -
getElementSRC(
Element element) → String? -
Returns
srcvalue for different Element types. -
getElementsWithAttributes(
String tag, Map< String, dynamic> matchAttributes) → List<Element> -
Selects elements from DOM with
tagand matches attribute. -
getElementTagName(
Node node) → String? -
Returns the
nodetag name. Returns null ifnodeis not an Element. -
getElementValue(
Element element, [String? def]) → String? -
Gets the
elementvalue depending of identified type. -
getElementWidth(
Element element, [int? def]) → int? -
Returns
elementwidth. Tries to use 'offsetWidth' or 'style.width' values. -
getElementZIndex(
Element? element, [String? def]) → String? -
Returns the
elementz-indexorelement.parentz-indexrecursively. -
getFileMimeType(
File file, [String accept = '']) → MimeType? -
Returns the
fileMimeType. -
getImageDimension(
CanvasImageSource image) → Rectangle< int> ? -
Gets the width and height from
image(CanvasImageSource). -
getLinkElementByHREF(
String href, [String? rel]) → LinkElement? -
Selects an LinkElement in DOM with
href. -
getMetaTagsContentWithName(
String name) → List< String?> -
Returns a list of
metacontet withname. -
getMetaTagsWithName(
String name) → List< Element> -
Returns a list of
metaElement withname. -
getParentElement(
Element element, {bool validator(Element parent)?, int maxLevels = 1000}) → Element? -
Returns the parent of
elementapplyingvalidatorandmaxLevels. -
getScriptElementBySRC(
String src) → ScriptElement? -
Selects an ScriptElement in DOM with
src. -
getURLData(
String url, {String? user, String? password, bool withCredentials = true}) → Future< Uint8List> -
Makes a HTTP request and returns
urlcontent as Uint8List. -
getVisibleNode(
Element? element) → Element? - Get the first visible element in the hierarchy.
-
htmlToText(
String html, [NodeValidator? validator]) → String? -
Transform
htmlto plain text. -
isCssEmpty(
CssStyleDeclaration css) → bool -
Returns
trueif CssStyleDeclaration is empty. -
isCssNotEmpty(
CssStyleDeclaration css) → bool -
Returns
trueif CssStyleDeclaration is not empty. -
isElementWithHREF(
Element element) → bool -
Returns
trueifelementtype can havehrefattribute. -
isElementWithSRC(
Element element) → bool -
Returns
trueifelementtype can havesrcattribute. -
isInDOM(
dynamic element) → bool -
Returns
trueifelementis in DOM tree. -
isInlineElement(
DivElement element, {bool checkBootstrapClasses = true}) → bool -
Returns
trueifelementdisplayproperty is inline. -
isInViewport(
Element element, {bool fully = false}) → bool -
Returns
trueifelementis visible in viewport. -
isMobileAppStatusBarTranslucent(
) → bool -
Returns
trueifmetatag of nameapple-mobile-web-app-status-bar-styleistranslucent. -
isNodeInDOM(
Node node) → bool -
Returns
trueifnodeis in DOM tree. -
isOrientationInLandscapeMode(
) → bool -
Returns
trueif device orientation is in Landscape mode. -
isOrientationInPortraitMode(
) → bool -
Returns
trueif device orientation is in Portrait mode. -
isSafariIOS(
) → bool -
jsArrayToList(
JsArray? a) → List? -
Converts a JsArray
ato a List. Also converts values using jsToDart. -
jsObjectKeys(
JsObject o) → List< String> -
Returns the keys of JsObject
o. -
jsObjectToMap(
JsObject? o) → Map? -
Converts a JsObject
oto a Map. Also converts keys and values using jsToDart. -
jsToDart(
Object? o) → Object? -
Converts
oto Dart primitives or collections. -
lerpDouble(
num a, num b, double t) → double? -
loadCSS(
String cssClassPrefix, Map< String, CSSValueBase> ? css) → void -
Loads
cssdynamically. -
mapJSFunction(
String jsFunctionName, MappedFunction f) → void - Maps a JavaScript function to a Dart function.
-
markdownToDiv(
String markdown, {bool normalize = true, Iterable< BlockSyntax> ? blockSyntaxes, Iterable<InlineSyntax> ? inlineSyntaxes, ExtensionSet? extensionSet, Resolver? linkResolver, Resolver? imageLinkResolver, bool inlineOnly = false}) → DivElement -
Converts a
markdowndocument into a HTML in a div node. -
markdownToHtml(
String markdown, {bool normalize = true, Iterable< BlockSyntax> ? blockSyntaxes, Iterable<InlineSyntax> ? inlineSyntaxes, ExtensionSet? extensionSet, Resolver? linkResolver, Resolver? imageLinkResolver, bool inlineOnly = false}) → String -
Converts a
markdowndocument into a HTML string. -
measureText(
String text, {required String fontFamily, required Object fontSize, bool bold = false}) → Dimension? -
nodeTreeContains(
Node rootNode, Node target) → bool -
Returns
trueifrootNodecontainstarget. -
nodeTreeContainsAny(
Node rootNode, Iterable< Node> list) → bool -
Returns
trueifrootNodecontains any Node inlist. -
normalizeIndent(
String text) → String - Normalizes a indent, removing the common/global indent of the code.
-
numsToPoints(
List< num> perspective) → List<Point< num> > - Converts a List<num>, as pairs, to a List<Point>.
-
onOrientationchange(
EventListener listener) → bool -
Attaches
listenertoorientationchangeevent. -
parseCSSLength(
String cssValue, {String? unit, int? def, bool allowPXWithoutSuffix = false}) → num? -
Parses a CSS length, using optional
unit. -
parseCssRuleSelectors(
CssRule cssRule) → List< String> -
Parses the selectors of
cssRule. -
parseCssRuleTextProperties(
String? cssRuleText) → String - Returns a list of properties of the CssRule text.
-
parseCssRuleTextSelectors(
String? cssRuleText) → List< String> - Returns a list of selectors of the CssRule text.
-
parseMetaContent(
String content) → Map< String, String?> -
Parses a
metacontent to Map<String,String>. -
prefetchHref(
String href, {int? insertIndex, bool? preLoad}) → Future< bool> -
Prefetch a HREF using a
linkelement intoheadDOM node. -
readFileDataAsArrayBuffer(
File file) → Future< Uint8List?> -
Reads
fileas Uint8List. -
readFileDataAsBase64(
File file) → Future< String?> -
Reads
fileas Base64 String. -
readFileDataAsDataURLBase64(
File file, [String accept = '']) → Future< String?> -
Reads
fileas DATA URL Base64 String. -
readFileDataAsText(
File file) → Future< String?> -
Reads
fileas text. -
readFileInputElementAsArrayBuffer(
FileUploadInputElement? input, [bool removeExifFromImage = false]) → Future< Uint8List?> -
Reads selected file of
inputas Uint8List. -
readFileInputElementAsBase64(
FileUploadInputElement? input, [bool removeExifFromImage = false]) → Future< String?> -
Reads selected file of
inputas Base64. -
readFileInputElementAsDataURLBase64(
FileUploadInputElement? input, [bool removeExifFromImage = false]) → Future< String?> -
Reads selected file of
inputas DATA URL Base64. -
readFileInputElementAsString(
FileUploadInputElement? input, [bool removeExifFromImage = false]) → Future< String?> -
Reads selected file of
inputas String. -
redirectOnTouchEndToMouseEvent(
Element element) → void -
Redirects
element.onTouchEndtoelement.onMouseUpas MouseEvent. -
redirectOnTouchMoveToMouseEvent(
Element element) → void -
Redirects
element.onTouchMovetoelement.onMouseMoveas MouseEvent. -
redirectOnTouchStartToMouseEvent(
Element element) → void -
Redirects
element.onTouchStarttoelement.onMouseDownas MouseEvent. -
reloadAssets(
Map< String, String> assetsURLAndTag, {Duration? timeout}) → Future<bool> - Reloads an asset (img, audi or video), forcing reload of asset URL.
-
reloadIframe(
IFrameElement iFrame, [bool? forceGet]) → Future< bool> - Reloads an IFrame document.
-
removeElementBackgroundBlur(
Element element, [int? blurSize]) → void -
Removes
elementbackground blur effect, set by setElementBackgroundBlur. -
removeElementScrollColors(
Element element) → List< String> ? -
Removes
elementscroll colors CSS properties set by setElementScrollColors. -
removeExifFromImageFile(
File file) → Future< String?> -
Removes Exif from JPEG
file. -
replaceElement(
Node n1, Node n2) → bool -
Replaces
n1withn2inn1parent. -
resetZoom(
) → void - Resets viewport zoom.
-
rotateCanvasImageSource(
CanvasImageSource image, int width, int height, [dynamic angleDegree = 90]) → CanvasElement -
Rotates
image(a CanvasImageSource) withangleDegree. -
rotateImageElement(
ImageElement image, [dynamic angleDegree = 90]) → CanvasElement -
Rotates
imagewithangleDegree. -
scalePoints(
List< Point< points, double scale) → List<num> >Point< num> > -
Scales
pointstoscale. -
scalePointsXY(
List< Point< points, double scaleX, double scaleY) → List<num> >Point< num> > -
Scales
pointstoscaleXandscaleY. -
scrollTo(
num? x, num? y, {bool smooth = true, int? delayMs, Object? scrollable}) → void -
Scrolls viewport to
x,y. -
scrollToBottom(
{bool smooth = true, int? delayMs, Object? scrollable}) → void - Scrolls viewport to the bottom.
-
scrollToElement(
Element element, {bool centered = true, bool vertical = true, bool horizontal = true, bool smooth = true, int? translateX, int? translateY, Object? scrollable}) → void -
Scrolls the viewport to the
element. -
scrollToLeft(
{bool smooth = true, int? delayMs, Object? scrollable}) → void - Scrolls viewport to the left border.
-
scrollToRight(
{bool smooth = true, int? delayMs, Object? scrollable}) → void - Scrolls viewport to the right border.
-
scrollToTop(
{bool smooth = true, int y = 0, bool fixSafariIOS = false, int? delayMs, Object? scrollable}) → void - Scrolls viewport to the top.
-
scrollToTopDelayed(
int delayMs) → void - Use scrollToTop instead.
-
selectCssRuleWithSelector(
Pattern targetSelector) → List< CssRule> -
Returns a list of CssRule with
targetSelectorpatterns. -
setDivCentered(
DivElement div, {bool centerVertically = true, bool centerHorizontally = true, bool checkBootstrapClasses = true}) → void -
Sets
divas centered content, usingdisplayproperty astableand sub div elementsdisplayproperty astable-cell. -
setElementBackgroundBlur(
Element element, [int? blurSize]) → void -
Sets
elementbackground as a blur effect of sizeblurSize. Uses CSS propertybackdrop-filter. -
setElementHREF(
Element element, String href) → bool -
Sets
elementhrefdepending of the identified type. -
setElementInnerHTML(
Element element, String html, {NodeValidator? validator}) → void -
Sets the inner HTML of
elementwith parsed result ofhtml. -
setElementScrollColors(
Element element, int scrollWidth, String scrollButtonColor, [String? scrollBgColor]) → String? -
Sets
elementscroll colors, using standard CSS propertyscrollbar-colorand webkit pseudo element::-webkit-scrollbar-thumband::-webkit-scrollbar-track -
setElementSRC(
Element element, String src) → bool -
Sets the
elementsrcdepending of the identified type. -
setElementValue(
Element? element, String value) → bool -
Sets the
elementvaluedepending of the identified type. -
setMetaViewportScale(
{String? minimumScale, String? maximumScale}) → bool -
Sets the
metaviewport withminimumScaleandmaximumScale. -
setTreeElementsBackgroundBlur(
Element element, String className) → void -
setTreeElementsDivCentered(
Element element, String className, {bool centerVertically = true, bool centerHorizontally = true}) → void -
Set all
elementsub div withclassNameto centered content. -
setZoom(
String zoom) → void -
Sets the viewport
zoom. -
showDialogElement(
Element content, {double? transparency, String? padding}) → DivElement - Shows an Element dialog.
-
showDialogHTML(
String? html, {double? transparency, String? padding, NodeValidator? validator}) → DivElement? -
Shows a
htmldialog. -
showDialogImage(
String src) → void -
Shows an image (
src) dialog. -
showDialogText(
String? text, {double? transparency, String? padding}) → DivElement? - Shows a text dialog.
-
toCanvasElement(
CanvasImageSource imageSource, int width, int height) → CanvasElement -
Converts
imageSourceto CanvasElement. -
toDataURLBase64(
String? mediaType, String base64) → String - Builds a DATA URL string.
-
toHTML(
Element element) → String -
Converts
elementto HTML. -
touchEventToMouseEvent(
TouchEvent event) → MouseEvent? -
Converts a TouchEvent
eventto a MouseEvent. -
translatePoints(
List< Point< points, num x, num y) → List<num> >Point< num> > -
Translate
pintsinxandy.
Typedefs
- AnimationCallback = void Function()
-
ElementValueGetter<
T> = T? Function(Element element) - Returns a value from an Element.
- FunctionTest = bool Function()
- ImageFilter = CanvasImageSource Function(CanvasImageSource? image, int width, int height)
-
Applies a filter to
image, ofwidthandheight. - MappedFunction = dynamic Function(dynamic o)
- MatchesValue = bool Function(String value)
- OnElementEvent = void Function(Element element)
-
OnElementTrackValueEvent<
T> = bool Function(Element element, T? value) - StateEventListener = void Function(StateOperation op, State state, String key, dynamic value)
- StateKeyListener = void Function(dynamic value)
-
ValueCopier<
T> = T? Function(T? value)