From 0380a3149738f0f23856debea067ad5a1d6bfa4e Mon Sep 17 00:00:00 2001 From: Catherine Liu Date: Wed, 4 Dec 2019 13:18:49 -0700 Subject: [PATCH] [7.3] [Canvas][Docs] Updates function reference (#50393) (#51536) --- .../canvas/canvas-function-reference.asciidoc | 878 ++++++++---------- 1 file changed, 374 insertions(+), 504 deletions(-) diff --git a/docs/canvas/canvas-function-reference.asciidoc b/docs/canvas/canvas-function-reference.asciidoc index 4c58a48b7c0b26..266166ece263e7 100644 --- a/docs/canvas/canvas-function-reference.asciidoc +++ b/docs/canvas/canvas-function-reference.asciidoc @@ -28,7 +28,7 @@ Returns `true` if all of the conditions are met. See also <>. *Expression syntax* [source,js] ---- -all {neq “foo”} {neq “bar”} {neq “fizz”} +all {neq "foo"} {neq "bar"} {neq "fizz"} all condition={gt 10} condition={lt 20} ---- @@ -49,7 +49,7 @@ filters } | render ---- -This sets the color of the metric text to `”red”` if the context passed into `metric` is greater than or equal to 0 and less than 0.8. Otherwise, the color is set to `"green"`. +This sets the color of the metric text to `"red"` if the context passed into `metric` is greater than or equal to 0 and less than 0.8. Otherwise, the color is set to `"green"`. *Accepts:* `null` @@ -76,8 +76,8 @@ Converts between core types, including `string`, `number`, `null`, `boolean`, an *Expression syntax* [source,js] ---- -alterColumn “cost” type=”string” -alterColumn column=”@timestamp” name=”foo” +alterColumn "cost" type="string" +alterColumn column="@timestamp" name="foo" ---- *Code example* @@ -85,7 +85,7 @@ alterColumn column=”@timestamp” name=”foo” ---- filters | demodata -| alterColumn “time” name=”time_in_ms” type=”number” +| alterColumn "time" name="time_in_ms" type="number" | table | render ---- @@ -97,7 +97,7 @@ This renames the `time` column to `time_in_ms` and converts the type of the colu |=== |Argument |Type |Description -|_Unnamed_ *** +|_Unnamed_ *** Alias: `column` |`string` @@ -124,7 +124,7 @@ Returns `true` if at least one of the conditions is met. See also <>. *Expression syntax* [source,js] ---- -any {eq “foo”} {eq “bar”} {eq “fizz”} +any {eq "foo"} {eq "bar"} {eq "fizz"} any condition={lte 10} condition={gt 30} ---- @@ -140,7 +140,7 @@ filters | pie | render ---- -This filters out any rows that don’t contain `“elasticsearch”`, `“kibana”` or `“x-pack”` in the `project` field. +This filters out any rows that don’t contain `"elasticsearch"`, `"kibana"` or `"x-pack"` in the `project` field. *Accepts:* `null` @@ -167,9 +167,9 @@ Creates a `datatable` with a single value. See also <>. *Expression syntax* [source,js] ---- -as -as “foo” -as name=”bar” +as +as "foo" +as name="bar" ---- *Code example* @@ -182,7 +182,7 @@ filters | plot | render ---- -`as` casts any primitive value (`string`, `number`, `date`, `null`) into a `datatable` with a single row and a single column with the given name (or defaults to `"value"` if no name is provided). This is useful when piping a primitive value into a function that only takes `datatable` as an input. +`as` casts any primitive value (`string`, `number`, `date`, `null`) into a `datatable` with a single row and a single column with the given name (or defaults to `"value"` if no name is provided). This is useful when piping a primitive value into a function that only takes `datatable` as an input. In the example above, `ply` expects each `fn` subexpression to return a `datatable` in order to merge the results of each `fn` back into a `datatable`, but using a `math` aggregation in the subexpressions returns a single `math` value, which is then cast into a `datatable` using `as`. @@ -192,7 +192,7 @@ In the example above, `ply` expects each `fn` subexpression to return a `datatab |=== |Argument |Type |Description -|_Unnamed_ +|_Unnamed_ Alias: `name` |`string` @@ -223,7 +223,7 @@ asset id="asset-498f7429-4d56-42a2-a7e4-8bf08d98d114" image dataurl={asset "asset-c661a7cc-11be-45a1-a401-d7592ea7917a"} mode="contain" | render ---- -The image asset stored with the ID `“asset-c661a7cc-11be-45a1-a401-d7592ea7917a”` is passed into the `dataurl` argument of the `image` function to display the stored asset. +The image asset stored with the ID `"asset-c661a7cc-11be-45a1-a401-d7592ea7917a"` is passed into the `dataurl` argument of the `image` function to display the stored asset. *Accepts:* `null` @@ -251,7 +251,7 @@ Configures the axis of a visualization. Only used with <>. [source,js] ---- axisConfig show=false -axisConfig position=”right” min=0 max=10 tickSize=1 +axisConfig position="right" min=0 max=10 tickSize=1 ---- *Code example* @@ -260,9 +260,9 @@ axisConfig position=”right” min=0 max=10 tickSize=1 filters | demodata | pointseries x="size(cost)" y="project" color="project" -| plot defaultStyle={seriesStyle bars=0.75 horizontalBars=true} - legend=false - xaxis={axisConfig position="top" min=0 max=400 tickSize=100} +| plot defaultStyle={seriesStyle bars=0.75 horizontalBars=true} + legend=false + xaxis={axisConfig position="top" min=0 max=400 tickSize=100} yaxis={axisConfig position="right"} | render ---- @@ -276,21 +276,21 @@ This sets the `x-axis` to display on the top of the chart and sets the range of |`max` |`number`, `string`, `null` -|The maximum value displayed in the axis. Must be a `number`, a date in milliseconds since epoch, or an ISO8601 `string` +|The maximum value displayed in the axis. Must be a number, a date in milliseconds since epoch, or an ISO8601 string. |`min` |`number`, `string`, `null` -|The minimum value displayed in the axis. Must be a `number`, a date in milliseconds since epoch, or an ISO8601 `string` +|The minimum value displayed in the axis. Must be a number, a date in milliseconds since epoch, or an ISO8601 string. |`position` |`string` -|The position of the axis labels. For example, `"top"`, `"bottom"`, `"left"`, or `"right"`. +|The position of the axis labels. For example, `"top"`, `"bottom"`, `"left"`, or `"right"`. Default: `"left"` |`show` |`boolean` -|Show the axis labels? +|Show the axis labels? Default: `true` @@ -309,30 +309,30 @@ Default: `true` [[case_fn]] === `case` -Builds a `case` (including a condition/result) to pass to the <> function. +Builds a <>, including a condition and a result, to pass to the <> function. *Expression syntax* [source,js] ---- -case 0 then=”red” -case when=5 then=”yellow” -case if={lte 50} then=”green” +case 0 then="red" +case when=5 then="yellow" +case if={lte 50} then="green" ---- *Code example* [source,text] ---- math "random()" -| progress shape="gauge" label={formatnumber "0%"} - font={font size=24 family="'Open Sans', Helvetica, Arial, sans-serif" align="center" +| progress shape="gauge" label={formatnumber "0%"} + font={font size=24 family="'Open Sans', Helvetica, Arial, sans-serif" align="center" color={ - switch {case if={lte 0.5} then="green"} - {case if={all {gt 0.5} {lte 0.75}} then="orange"} + switch {case if={lte 0.5} then="green"} + {case if={all {gt 0.5} {lte 0.75}} then="orange"} default="red" - }} + }} valueColor={ - switch {case if={lte 0.5} then="green"} - {case if={all {gt 0.5} {lte 0.75}} then="orange"} + switch {case if={lte 0.5} then="green"} + {case if={all {gt 0.5} {lte 0.75}} then="orange"} default="red" } | render @@ -345,7 +345,7 @@ This sets the color of the progress indicator and the color of the label to `"gr |=== |Argument |Type |Description -|_Unnamed_ +|_Unnamed_ Alias: `when` |`any` @@ -378,13 +378,13 @@ Clears the _context_, and returns `null`. [[columns_fn]] === `columns` -Includes or excludes columns from a data table. If you specify both, this will exclude first. +Includes or excludes columns from a `datatable`. When both arguments are specified, the excluded columns will be removed first. *Expression syntax* [source,js] ---- -columns include=”@timestamp, projects, cost” -columns exclude=”username, country, age” +columns include="@timestamp, projects, cost" +columns exclude="username, country, age" ---- *Code example* @@ -404,11 +404,11 @@ This only keeps the `price`, `cost`, `state`, and `project` columns from the `de |=== |Argument |Type |Description -|_Unnamed_ +|_Unnamed_ Alias: `include` |`string` -|A comma-separated list of column names to keep in the `datatable`. +|A comma-separated list of column names to keep in the `datatable`. |`exclude` |`string` @@ -417,20 +417,18 @@ Alias: `include` *Returns:* `datatable` - + [float] [[compare_fn]] === `compare` -Compares the _context_ to specified value to determine `true` or `false`. -Usually used in combination with <> or <>. This only works with primitive types, -such as `number`, `string`, and `boolean`. See also <>, <>, <>, <>, <>, and <>. +Compares the _context_ to specified value to determine `true` or `false`. Usually used in combination with `<>` or <>. This only works with primitive types, such as `number`, `string`, `boolean`, `null`. See also <>, <>, <>, <>, <>, <> *Expression syntax* [source,js] ---- -compare “neq” to=”elasticsearch” -compare op=”lte” to=100 +compare "neq" to="elasticsearch" +compare op="lte" to=100 ---- *Code example* @@ -438,18 +436,18 @@ compare op=”lte” to=100 ---- filters | demodata -| mapColumn project - fn=${getCell project | - switch +| mapColumn project + fn={getCell project | + switch {case if={compare eq to=kibana} then=kibana} {case if={compare eq to=elasticsearch} then=elasticsearch} default="other" } | pointseries size="size(cost)" color="project" -| pie +| pie | render ---- -This maps all `project` values that aren’t `“kibana”` and `“elasticsearch”` to `“other”`. Alternatively, you can use the individual comparator functions instead of compare. See <>, <>, <>, <>, <>, and <>. +This maps all `project` values that aren’t `"kibana"` and `"elasticsearch"` to `"other"`. Alternatively, you can use the individual comparator functions instead of compare. *Accepts:* `string`, `number`, `boolean`, `null` @@ -457,17 +455,17 @@ This maps all `project` values that aren’t `“kibana”` and `“elasticsearc |=== |Argument |Type |Description -|_Unnamed_ +|_Unnamed_ Alias: `op` |`string` -|The operator to use in the comparison: `eq` (equal to), `gt` (greater than), `gte` (greater than or equal to), `lt` (less than), `lte` (less than or equal to), `ne` or `neq` (not equal to). +|The operator to use in the comparison: `"eq"` (equal to), `"gt"` (greater than), `"gte"` (greater than or equal to), `"lt"` (less than), `"lte"` (less than or equal to), `"ne"` or `"neq"` (not equal to). Default: `"eq"` -|`to` +|`to` -Alias: `this`, `b` +Aliases: `b`, `this` |`any` |The value compared to the _context_. |=== @@ -484,29 +482,28 @@ Creates an object used for styling an element's container, including background, *Expression syntax* [source,js] ---- -containerStyle backgroundColor=”red”’ -containerStyle borderRadius=”50px” -containerStyle border=”1px solid black” -containerStyle padding=”5px” -containerStyle opacity=”0.5” -containerStyle overflow=”hidden” -containerStyle backgroundImage={asset id=asset-f40d2292-cf9e-4f2c-8c6f-a504a25e949c} - backgroundRepeat="no-repeat" - backgroundSize="cover" +containerStyle backgroundColor="red"’ +containerStyle borderRadius="50px" +containerStyle border="1px solid black" +containerStyle padding="5px" +containerStyle opacity="0.5" +containerStyle overflow="hidden" +containerStyle backgroundImage={asset id=asset-f40d2292-cf9e-4f2c-8c6f-a504a25e949c} + backgroundRepeat="no-repeat" + backgroundSize="cover" ---- *Code example* [source,text] ---- -shape "star" fill="#E61D35" maintainAspect=true -| render - containerStyle={ - containerStyle backgroundColor="#F8D546" - borderRadius="200px" - border="4px solid #05509F" - padding="0px" - opacity="0.9" - overflow="hidden" +shape "star" fill="#E61D35" maintainAspect=true +| render containerStyle={ + containerStyle backgroundColor="#F8D546" + borderRadius="200px" + border="4px solid #05509F" + padding="0px" + opacity="0.9" + overflow="hidden" } ---- @@ -566,8 +563,7 @@ Default: `"hidden"` [[context_fn]] === `context` -Returns whatever you pass into it. This can be useful when you need to use the -_context_ as an argument to a function as a sub-expression. +Returns whatever you pass into it. This can be useful when you need to use _context_ as argument to a function as a sub-expression. *Expression syntax* [source,js] @@ -580,40 +576,41 @@ context ---- date | formatdate "LLLL" -| markdown "Last updated: " {context} +| markdown "Last updated: " {context} | render ---- Using the `context` function allows us to pass the output, or _context_, of the previous function as a value to an argument in the next function. Here we get the formatted date string from the previous function and pass it as `content` for the markdown element. *Accepts:* `any` -*Returns:* Original _context_ +*Returns:* Depends on your input and arguments + [float] [[csv_fn]] -=== `csv` +=== `csv` Creates a `datatable` from CSV input. *Expression syntax* [source,js] ---- -csv “fruit, stock - kiwi, 10 - Banana, 5” +csv "fruit, stock + kiwi, 10 + Banana, 5" ---- *Code example* [source,text] ---- csv "fruit,stock - kiwi,10 - banana,5" + kiwi,10 + banana,5" | pointseries color=fruit size=stock | pie | render ---- -This is useful for quickly mocking data. +This creates a `datatable` with `fruit` and `stock` columns with two rows. This is useful for quickly mocking data. *Accepts:* `null` @@ -621,7 +618,7 @@ This is useful for quickly mocking data. |=== |Argument |Type |Description -|_Unnamed_ *** +|_Unnamed_ *** Alias: `data` |`string` @@ -631,14 +628,13 @@ Alias: `data` |`string` |The data separation character. -|`newLine` +|`newline` |`string` |The row separation character. |=== *Returns:* `datatable` - [float] [[d_fns]] == D @@ -647,15 +643,15 @@ Alias: `data` [[date_fn]] === `date` -Returns the current time, or a time parsed from a `string`, as milliseconds since epoch. +Returns the current time, or a time parsed from a specified string, as milliseconds since epoch. *Expression syntax* [source,js] ---- date date value=1558735195 -date “2019-05-24T21:59:55+0000” -date “01/31/2019” format=”MM/DD/YYYY” +date "2019-05-24T21:59:55+0000" +date "01/31/2019" format="MM/DD/YYYY" ---- *Code example* @@ -663,11 +659,11 @@ date “01/31/2019” format=”MM/DD/YYYY” ---- date | formatdate "LLL" -| markdown {context} - font={font family="Arial, sans-serif" size=30 align="left" - color="#000000" - weight="normal" - underline=false +| markdown {context} + font={font family="Arial, sans-serif" size=30 align="left" + color="#000000" + weight="normal" + underline=false italic=false} | render ---- @@ -679,17 +675,15 @@ Using `date` without passing any arguments will return the current date and time |=== |Argument |Type |Description -|_Unnamed_ +|_Unnamed_ Alias: `value` |`string` -|A date string to be parsed into milliseconds since epoch. The date string be either a valid JavaScript Date input or a string to parse -using the `format` argument. Must be an ISO8601 string or you must provide the format. +|An optional date string that is parsed into milliseconds since epoch. The date string can be either a valid JavaScript `Date` input or a string to parse using the `format` argument. Must be an ISO8601 string, or you must provide the format. |`format` |`string` -|The MomentJS format for parsing the optional date -`string`. See the https://momentjs.com/docs/#/displaying/[MomentJS documentation]. +|The MomentJS format used to parse the specified date string. For more information, see https://momentjs.com/docs/#/displaying/. |=== *Returns:* `number` @@ -701,35 +695,17 @@ using the `format` argument. Must be an ISO8601 string or you must provide the f A mock data set that includes project CI times with usernames, countries, and run phases. -*Expression syntax* -[source,js] ----- -demodata -demodata “ci” -demodata type=”shirts” ----- - -*Code example* -[source,text] ----- -filters -| demodata -| table -| render ----- -`demodata` is a mock data set that you can use to start playing around in Canvas. - *Accepts:* `filter` [cols="3*^<"] |=== |Argument |Type |Description -|_Unnamed_ +|_Unnamed_ Alias: `type` |`string` -|The name of the demo data set to use. +|The name of the demo data set to use. Default: `"ci"` |=== @@ -741,24 +717,7 @@ Default: `"ci"` [[do_fn]] === `do` -Executes multiple sub-expressions, then returns the original _context_. Use for running functions that produce an action or side effect without changing the original _context_. - -*Expression syntax* -[source,js] ----- -do fn={something cool} ----- - -*Code example* -[source,text] ----- -filters -| demodata -| do fn={something cool} -| table -| render ----- -`do` should be used to invoke a function that produces as a side effect without changing the `context`. +Executes multiple sub-expressions, then returns the original _context_. Use for running functions that produce an action or a side effect without changing the original _context_. *Accepts:* `any` @@ -768,12 +727,12 @@ filters |_Unnamed_ † -Aliases: `expression`, `exp`, `fn`, `function` +Aliases: `exp`, `expression`, `fn`, `function` |`any` -|The sub-expressions to execute. The return values of these sub-expressions are not available in the root pipeline as this function simply returns the _context_. +|The sub-expressions to execute. The return values of these sub-expressions are not available in the root pipeline as this function simply returns the original _context_. |=== -*Returns:* Original _context_ +*Returns:* Depends on your input and arguments [float] @@ -793,7 +752,7 @@ dropdownControl valueColumn=agent filterColumn=agent.keyword filterGroup=group1 [source,text] ---- demodata -| dropdownControl valueColumn=project filterColumn=project +| dropdownControl valueColumn=project filterColumn=project | render ---- This creates a dropdown filter element. It requires a data source and uses the unique values from the given `valueColumn` (i.e. `project`) and applies the filter to the `project` column. Note: `filterColumn` should point to a keyword type field for Elasticsearch data sources. @@ -808,18 +767,17 @@ This creates a dropdown filter element. It requires a data source and uses the u |`string` |The column or field that you want to filter. -|`valueColumn` *** -|`string` -|The column or field to extract the unique values for the drop-down control. - |`filterGroup` |`string` |The group name for the filter. + +|`valueColumn` *** +|`string` +|The column or field from which to extract the unique values for the dropdown control. |=== *Returns:* `render` - [float] [[e_fns]] == E @@ -836,7 +794,7 @@ Returns whether the _context_ is equal to the argument. eq true eq null eq 10 -eq “foo” +eq "foo" ---- *Code example* @@ -844,18 +802,18 @@ eq “foo” ---- filters | demodata -| mapColumn project - fn=${getCell project | - switch +| mapColumn project + fn={getCell project | + switch {case if={eq kibana} then=kibana} {case if={eq elasticsearch} then=elasticsearch} default="other" } | pointseries size="size(cost)" color="project" -| pie +| pie | render ---- -This changes all values in the project column that don’t equal `“kibana”` or `“elasticsearch”` to `“other”`. +This changes all values in the project column that don’t equal `"kibana"` or `"elasticsearch"` to `"other"`. *Accepts:* `boolean`, `number`, `string`, `null` @@ -863,7 +821,7 @@ This changes all values in the project column that don’t equal `“kibana”` |=== |Argument |Type |Description -|_Unnamed_ *** +|_Unnamed_ *** Alias: `value` |`boolean`, `number`, `string`, `null` @@ -877,29 +835,7 @@ Alias: `value` [[escount_fn]] === `escount` -Queries {es} for the number of hits matching the specified query. - -*Expression syntax* -[source,js] ----- -escount index=”logstash-*” -escount "currency:\"EUR\"" index=”kibana_sample_data_ecommerce” -escount query="response:404" index=”kibana_sample_data_logs” ----- - -*Code example* -[source,text] ----- -filters -| escount "Cancelled:true" index="kibana_sample_data_flights" -| math "value" -| progress shape="semicircle" - label={formatnumber 0,0} - font={font size=24 family="'Open Sans', Helvetica, Arial, sans-serif" color="#000000" align=center} - max={filters | escount index="kibana_sample_data_flights"} -| render ----- -The first `escount` expression retrieves the number of flights that were cancelled. The second `escount` expression retrieves the total number of flights. +Query Elasticsearch for the number of hits matching the specified query. *Accepts:* `filter` @@ -907,9 +843,9 @@ The first `escount` expression retrieves the number of flights that were cancell |=== |Argument |Type |Description -|_Unnamed_ +|_Unnamed_ -Alias: `q`, `query` +Aliases: `q`, `query` |`string` |A Lucene query string. @@ -929,36 +865,7 @@ Default: `_all` [[esdocs_fn]] === `esdocs` -Queries {es} for raw documents. Specify the fields you want to retrieve, -especially if you are asking for a lot of rows. - -*Expression syntax* -[source,js] ----- -esdocs index=”logstash-*” -esdocs "currency:\"EUR\"" index=”kibana_sample_data_ecommerce” -esdocs query="response:404" index=”kibana_sample_data_logs” -esdocs index=”kibana_sample_data_flights” count=100 -esdocs index="kibana_sample_data_flights" sort="AvgTicketPrice, asc" ----- - -*Code example* -[source,text] ----- -filters -| esdocs index="kibana_sample_data_ecommerce" - fields="customer_gender, taxful_total_price, order_date" - sort="order_date, asc" - count=10000 -| mapColumn "order_date" - fn={getCell "order_date" | date {context} | rounddate "YYYY-MM-DD"} -| alterColumn "order_date" type="date" -| pointseries x="order_date" y="sum(taxful_total_price)" color="customer_gender" -| plot defaultStyle={seriesStyle lines=3} - palette={palette "#7ECAE3" "#003A4D" gradient=true} -| render ----- -This retrieves the latest 10000 documents data from the `kibana_sample_data_ecommerce` index sorted by `order_date` in ascending order and only requests the `customer_gender`, `taxful_total_price`, and `order_date` fields. +Query Elasticsearch for raw documents. Specify the fields you want to retrieve, especially if you are asking for a lot of rows. *Accepts:* `filter` @@ -966,7 +873,7 @@ This retrieves the latest 10000 documents data from the `kibana_sample_data_ecom |=== |Argument |Type |Description -|_Unnamed_ +|_Unnamed_ Aliases: `q`, `query` |`string` @@ -986,9 +893,13 @@ Default: `1000` |`index` |`string` -|An index or index pattern. For example, `"logstash-*"`. +|An index or index pattern. For example, `"logstash-*"`. + +Default: `_all` -Default: `"_all"` +|`metaFields` +|`string` +|Comma separated list of meta fields. For example, `"_index,_type"`. |`sort` |`string` @@ -1002,22 +913,7 @@ Default: `"_all"` [[essql_fn]] === `essql` -Queries {es} using {es} SQL. - -*Expression syntax* -[source,js] ----- -essql query=”SELECT * FROM \”logstash*\”” -essql “SELECT * FROM \”apm*\”” count=10000 ----- - -*Code example* -[source,text] ----- -filters -| essql query="SELECT Carrier, FlightDelayMin, AvgTicketPrice FROM \"kibana_sample_data_flights\"" ----- -This retrieves the `Carrier`, `FlightDelayMin`, and `AvgTicketPrice` fields from the “kibana_sample_data_flights” index. +Queries Elasticsearch using Elasticsearch SQL. *Accepts:* `filter` @@ -1025,19 +921,21 @@ This retrieves the `Carrier`, `FlightDelayMin`, and `AvgTicketPrice` fields from |=== |Argument |Type |Description -|_Unnamed_ *** +|_Unnamed_ -Alias: `q`, `query` +Aliases: `q`, `query` |`string` -|An {es} SQL query. +|An Elasticsearch SQL query. |`count` |`number` -|The number of documents to retrieve. Smaller numbers perform better. +|The number of documents to retrieve. For better performance, use a smaller data set. Default: `1000` |`timezone` + +Alias: `tz` |`string` |The timezone to use for date operations. Valid ISO8601 formats and UTC offsets both work. @@ -1056,9 +954,9 @@ Creates a filter that matches a given column to an exact value. *Expression syntax* [source,js] ---- -exactly “state” value=”running” -exactly “age” value=50 filterGroup=”group2” -exactly column=“project” value=”beats” +exactly "state" value="running" +exactly "age" value=50 filterGroup="group2" +exactly column="project" value="beats" ---- *Code example* @@ -1071,7 +969,7 @@ filters | plot defaultStyle={seriesStyle bars=1} | render ---- -The `exactly` filter here is added to existing filters retrieved by the `filters` function and further filters down the data to only have `”elasticsearch”` data. The `exactly` filter only applies to this one specific element and will not affect other elements in the workpad. +The `exactly` filter here is added to existing filters retrieved by the `filters` function and further filters down the data to only have `"elasticsearch"` data. The `exactly` filter only applies to this one specific element and will not affect other elements in the workpad. *Accepts:* `filter` @@ -1081,25 +979,23 @@ The `exactly` filter here is added to existing filters retrieved by the `filters |`column` *** -Aliases: `field`, `c` +Aliases: `c`, `field` |`string` |The column or field that you want to filter. +|`filterGroup` +|`string` +|The group name for the filter. + |`value` *** Aliases: `v`, `val` |`string` -|The value to match exactly, including white space and -capitalization. - -|`filterGroup` -|`string` -|The group name for the filter. +|The value to match exactly, including white space and capitalization. |=== *Returns:* `filter` - [float] [[f_fns]] == F @@ -1113,8 +1009,8 @@ Filters rows in a `datatable` based on the return value of a sub-expression. *Expression syntax* [source,js] ---- -filterrows {getCell “project” | eq “kibana”} -filterrows fn={getCell “age” | gt 50} +filterrows {getCell "project" | eq "kibana"} +filterrows fn={getCell "age" | gt 50} ---- *Code example* @@ -1123,11 +1019,11 @@ filterrows fn={getCell “age” | gt 50} filters | demodata | filterrows {getCell "country" | any {eq "IN"} {eq "US"} {eq "CN"}} -| mapColumn "@timestamp" +| mapColumn "@timestamp" fn={getCell "@timestamp" | rounddate "YYYY-MM"} | alterColumn "@timestamp" type="date" | pointseries x="@timestamp" y="mean(cost)" color="country" -| plot defaultStyle={seriesStyle points="2" lines="1"} +| plot defaultStyle={seriesStyle points="2" lines="1"} palette={palette "#01A4A4" "#CC6666" "#D0D102" "#616161" "#00A1CB" "#32742C" "#F18D05" "#113F8C" "#61AE24" "#D70060" gradient=false} | render ---- @@ -1139,13 +1035,11 @@ This uses `filterrows` to only keep data from India (`IN`), the United States (` |=== |Argument |Type |Description -|_Unnamed_ *** +|_Unnamed_ *** -Aliases: `fn`, `exp`, `expression` +Aliases: `exp`, `expression`, `fn`, `function` |`boolean` -|An expression to pass into each row in the `datatable.` -The expression should return a `boolean`. A `true` value preserves the row, -and a `false` value removes it. +|An expression to pass into each row in the `datatable`. The expression should return a `boolean`. A `true` value preserves the row, and a `false` value removes it. |=== *Returns:* `datatable` @@ -1161,8 +1055,8 @@ Aggregates element filters from the workpad for use elsewhere, usually a data so [source,js] ---- filters -filters group=”timefilter1” -filters group=”timefilter2” group=”dropdownfilter1” ungrouped=true +filters group="timefilter1" +filters group="timefilter2" group="dropdownfilter1" ungrouped=true ---- *Code example* @@ -1171,19 +1065,19 @@ filters group=”timefilter2” group=”dropdownfilter1” ungrouped=true filters group=group2 ungrouped=true | demodata | pointseries x="project" y="size(cost)" color="project" -| plot defaultStyle={seriesStyle bars=0.75} legend=false +| plot defaultStyle={seriesStyle bars=0.75} legend=false font={ - font size=14 - family="'Open Sans', Helvetica, Arial, sans-serif" - align="left" - color="#FFFFFF" - weight="lighter" - underline=true + font size=14 + family="'Open Sans', Helvetica, Arial, sans-serif" + align="left" + color="#FFFFFF" + weight="lighter" + underline=true italic=true } | render ---- -`filters` sets the existing filters as context and accepts `group` parameter to create filter groups. +`filters` sets the existing filters as context and accepts a `group` parameter to opt into specific filter groups. Setting `ungrouped` to `true` opts out of using global filters. *Accepts:* `null` @@ -1191,7 +1085,7 @@ filters group=group2 ungrouped=true |=== |Argument |Type |Description -|_Unnamed_ † +|_Unnamed_ † Alias: `group` |`string` @@ -1199,7 +1093,7 @@ Alias: `group` |`ungrouped` -Alias: `nogroup`, `nogroups` +Aliases: `nogroup`, `nogroups` |`boolean` |Exclude filters that belong to a filter group? @@ -1234,14 +1128,14 @@ font lHeight=32 filters | demodata | pointseries x="project" y="size(cost)" color="project" -| plot defaultStyle={seriesStyle bars=0.75} legend=false +| plot defaultStyle={seriesStyle bars=0.75} legend=false font={ - font size=14 - family="'Open Sans', Helvetica, Arial, sans-serif" - align="left" - color="#FFFFFF" - weight="lighter" - underline=true + font size=14 + family="'Open Sans', Helvetica, Arial, sans-serif" + align="left" + color="#FFFFFF" + weight="lighter" + underline=true italic=true } | render @@ -1255,7 +1149,7 @@ filters |`align` |`string` -|The horizontal alignment of text. +|The horizontal text alignment. Default: `left` @@ -1265,40 +1159,41 @@ Default: `left` |`family` |`string` -|An acceptable CSS web font string. +|An acceptable CSS web font string Default: `"'Open Sans', Helvetica, Arial, sans-serif"` |`italic` |`boolean` -|Italicize the text? +|Italicize the text? Default: `false` -|`lHeight` +|`lHeight` Alias: `lineHeight` |`number`, `null` -|The line height in pixels. +|The line height in pixels + +Default: `null` |`size` |`number` -|The font size in pixels. +|The font size in pixels Default: `14` |`underline` |`boolean` -|Underline the text? +|Underline the text? Default: `false` |`weight` |`string` -|The font weight. For example, `"normal"`, `"bold"`, `"bolder"`, `"lighter"`, `"100"`, `"200"`, `"300"`, `"400"`, `"500"`, `"600"`, `"700"`, `"800"`, or `"900"`. - -Default: `"normal"` +|The font weight. For example, `"normal"`, `"bold"`, `"bolder"`, `"lighter"`, `"100"`, `"200"`, `"300"`, `"400"`, `"500"`, `"600"`, `"700"`, `"800"`, or `"900"`. +Default: `normal` |=== *Returns:* `style` @@ -1313,8 +1208,8 @@ Formats an ISO8601 date string or a date in milliseconds since epoch using Momen *Expression syntax* [source,js] ---- -formatdate format=”YYYY-MM-DD” -formatdate “MM/DD/YYYY” +formatdate format="YYYY-MM-DD" +formatdate "MM/DD/YYYY" ---- *Code example* @@ -1327,7 +1222,7 @@ filters | plot defaultStyle={seriesStyle points=5} | render ---- -This transforms the dates in the `time` field into strings that look like `“Jan ‘19”`, `“Feb ‘19”`, etc. using a MomentJS format. +This transforms the dates in the `time` field into strings that look like `"Jan ‘19"`, `"Feb ‘19"`, etc. using a MomentJS format. *Accepts:* `number`, `string` @@ -1335,7 +1230,7 @@ This transforms the dates in the `time` field into strings that look like `“Ja |=== |Argument |Type |Description -|_Unnamed_ *** +|_Unnamed_ *** Alias: `format` |`string` @@ -1349,13 +1244,13 @@ Alias: `format` [[formatnumber_fn]] === `formatnumber` -Formats a `number` into a formatted `string` using NumeralJS. See http://numeraljs.com/#format. +Formats a number into a formatted number string using NumeralJS. For more information, see http://numeraljs.com/#format. *Expression syntax* [source,js] ---- -formatnumber format=”$0,0.00” -fortmatnumber “0.0a” +formatnumber format="$0,0.00" +formatnumber "0.0a" ---- *Code example* @@ -1364,8 +1259,8 @@ fortmatnumber “0.0a” filters | demodata | math "mean(percent_uptime)" -| progress shape="gauge" - label={formatnumber "0%"} +| progress shape="gauge" + label={formatnumber "0%"} font={font size=24 family="'Open Sans', Helvetica, Arial, sans-serif" color="#000000" align="center"} | render ---- @@ -1377,7 +1272,7 @@ The `formatnumber` subexpression receives the same `context` as the `progress` f |=== |Argument |Type |Description -|_Unnamed_ *** +|_Unnamed_ *** Alias: `format` |`string` @@ -1386,7 +1281,6 @@ Alias: `format` *Returns:* `string` - [float] [[g_fns]] == G @@ -1403,13 +1297,13 @@ Fetches a single cell from a `datatable`. |=== |Argument |Type |Description -|_Unnamed_ +|_Unnamed_ -Aliases: `column`, `c` +Aliases: `c`, `column` |`string` |The name of the column to fetch the value from. If not provided, the value is retrieved from the first column. -|`row` +|`row` Alias: `r` |`number` @@ -1418,7 +1312,7 @@ Alias: `r` Default: `0` |=== -*Returns:* Depends on the data in the cell +*Returns:* Depends on your input and arguments [float] @@ -1433,7 +1327,7 @@ Returns whether the _context_ is greater than the argument. |=== |Argument |Type |Description -|_Unnamed_ *** +|_Unnamed_ *** Alias: `value` |`number`, `string` @@ -1455,7 +1349,7 @@ Returns whether the _context_ is greater or equal to the argument. |=== |Argument |Type |Description -|_Unnamed_ *** +|_Unnamed_ *** Alias: `value` |`number`, `string` @@ -1464,7 +1358,6 @@ Alias: `value` *Returns:* `boolean` - [float] [[h_fns]] == H @@ -1481,7 +1374,7 @@ Retrieves the first N rows from the `datatable`. See also <>. |=== |Argument |Type |Description -|_Unnamed_ +|_Unnamed_ Alias: `count` |`number` @@ -1492,7 +1385,6 @@ Default: `1` *Returns:* `datatable` - [float] [[i_fns]] == I @@ -1509,22 +1401,22 @@ Performs conditional logic. |=== |Argument |Type |Description -|_Unnamed_ +|_Unnamed_ *** Alias: `condition` |`boolean` |A `true` or `false` indicating whether a condition is met, usually returned by a sub-expression. When unspecified, the original _context_ is returned. -|`then` -|`any` -|The return value when the condition is `true`. When unspecified and the condition is met, the original _context_ is returned. - |`else` |`any` |The return value when the condition is `false`. When unspecified and the condition is not met, the original _context_ is returned. + +|`then` +|`any` +|The return value when the condition is `true`. When unspecified and the condition is met, the original _context_ is returned. |=== -*Returns:* Depends on your _context_ and arguments +*Returns:* Depends on your input and arguments [float] @@ -1539,37 +1431,31 @@ Displays an image. Provide an image asset as a `base64` data URL, or pass in a s |=== |Argument |Type |Description -|_Unnamed_ +|_Unnamed_ Aliases: `dataurl`, `url` |`string`, `null` |The HTTP(S) URL or `base64` data URL of an image. +Example value for the _Unnamed_ argument, formatted as a `base64` data URL: +[source, url] +------------ +data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiIHN0YW5kYWxvbmU9Im5vIj8+CjxzdmcKICAgeG1sbnM6ZGM9Imh0dHA6Ly9wdXJsLm9yZy9kYy9lbGVtZW50cy8xLjEvIgogICB4bWxuczpjYz0iaHR0cDovL2NyZWF0aXZlY29tbW9ucy5vcmcvbnMjIgogICB4bWxuczpyZGY9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkvMDIvMjItcmRmLXN5bnRheC1ucyMiCiAgIHhtbG5zOnN2Zz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciCiAgIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIKICAgdmlld0JveD0iMCAwIDI3MC42MDAwMSAyNjkuNTQ2NjYiCiAgIGhlaWdodD0iMjY5LjU0NjY2IgogICB3aWR0aD0iMjcwLjYwMDAxIgogICB4bWw6c3BhY2U9InByZXNlcnZlIgogICBpZD0ic3ZnMiIKICAgdmVyc2lvbj0iMS4xIj48bWV0YWRhdGEKICAgICBpZD0ibWV0YWRhdGE4Ij48cmRmOlJERj48Y2M6V29yawogIC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CwyOTguNDEgYyA0MS43NCwtMzIuMDkgOTIuODMsLTQ5LjU5IDE0NC45OCwtNDkuNTkgMTMyLjI1LDAgMjM5LjgxLDEwNy41NTkgMjM5LjgxLDIzOS44MjEgMCwyOS4xNiAtNC44OCw1Ny4xNjggLTE0LjUzLDgzLjQxOCBsIC0zMDQuMDgsNzEuMTYgLTY2LjE4LC0zNDQuODA5IiAvPjxwYXRoCiAgICAgICAgIGlkPSJwYXRoMjYiCiAgICAgICAgIHN0eWxlPSJmaWxsOiMzMTc3YTc7ZmlsbC1vcGFjaXR5OjE7ZmlsbC1ydWxlOm5vbnplcm87c3Ryb2tlOm5vbmUiCiAgICAgICAgIGQ9Im0gMTM4NS42Nyw3MjIuOTMgMzM0Ljc2LC03OC4zMDEgYyAxMzYuMDIsNDQuOTYxIDIzMC41NiwxNzUuMzUxIDIzMC41NiwzMTguNzYyIDAsMTM5LjMzOSAtODYuNTQsMjYzLjg1OSAtMjE2LjM4LDMxMy4wMzkgbCAtNDM3Ljg0LC0zODMuNTkgODguOSwtMTY5LjkxIiAvPjwvZz48L2c+PC9zdmc+ +------------ + |`mode` |`string` -|`"contain"` shows the entire image, scaled to fit. -`"cover"` fills the container with the image, cropping from the sides or bottom as needed. -`"stretch"` resizes the height and width of the image to 100% of the container. - +|`"contain"` shows the entire image, scaled to fit. `"cover"` fills the container with the image, cropping from the sides or bottom as needed. `"stretch"` resizes the height and width of the image to 100% of the container. Default: `"contain"` |=== -Example value for the `dataurl` argument, formatted as a `base64` data URL: -[source, url] -------------- -data:image/svg+xml;`base64`,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiIHN0YW5kYWxvbmU9Im5vIj8+CjxzdmcKICAgeG1sbnM6ZGM9Imh0dHA6Ly9wdXJsLm9yZy9kYy9lbGVtZW50cy8xLjEvIgogICB4bWxuczpjYz0iaHR0cDovL2NyZWF0aXZlY29tbW9ucy5vcmcvbnMjIgogICB4bWxuczpyZGY9Imh0dHA6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ZXJvO3N0cm9rZTpub25lIgogICAgICAgICBkPSJNIDMwOC45OTIsMTM3Ni43IEMgMTczLjAyLDEzMzEuNjQgNzguNDgwNSwxMjAxLjMgNzguNDgwNSwxMDU3LjkzIDc4LjQ4MDUsOTE4LjM0IDE2NC44Miw3OTMuNjggMjk0LjQwNiw3NDQuMzUyIGwgNDI2Ljk4MSwzODUuOTM4IC03OC4zOTUsMTY3LjUxIC0zMzQsNzguOSIgLz48cGF0aAogICAgICAgICBpZD0icGF0aDI0IgogICAgICAgICBzdHlsZT0iZmlsbDojODVjZTI2O2ZpbGwtb3BhY2l0eToxO2ZpbGwtcnVsZTpub256ZXJvO3N0cm9rZTpub25lIgogICAgICAgICBkPSJtIDEzMjMuOCwyOTguNDEgYyA0MS43NCwtMzIuMDkgOTIuODMsLTQ5LjU5IDE0NC45OCwtNDkuNTkgMTMyLjI1LDAgMjM5LjgxLDEwNy41NTkgMjM5LjgxLDIzOS44MjEgMCwyOS4xNiAtNC44OCw1Ny4xNjggLTE0LjUzLDgzLjQxOCBsIC0zMDQuMDgsNzEuMTYgLTY2LjE4LC0zNDQuODA5IiAvPjxwYXRoCiAgICAgICAgIGlkPSJwYXRoMjYiCiAgICAgICAgIHN0eWxlPSJmaWxsOiMzMTc3YTc7ZmlsbC1vcGFjaXR5OjE7ZmlsbC1ydWxlOm5vbnplcm87c3Ryb2tlOm5vbmUiCiAgICAgICAgIGQ9Im0gMTM4NS42Nyw3MjIuOTMgMzM0Ljc2LC03OC4zMDEgYyAxMzYuMDIsNDQuOTYxIDIzMC41NiwxNzUuMzUxIDIzMC41NiwzMTguNzYyIDAsMTM5LjMzOSAtODYuNTQsMjYzLjg1OSAtMjE2LjM4LDMxMy4wMzkgbCAtNDM3Ljg0LC0zODMuNTkgODguOSwtMTY5LjkxIiAvPjwvZz48L2c+PC9zdmc+ -------------- - *Returns:* `image` - [float] [[j_fns]] == J -[float] - [float] [[joinRows_fn]] === `joinRows` @@ -1582,47 +1468,44 @@ Concatenates values from rows in a `datatable` into a single string. |=== |Argument |Type |Description -|_Unnamed_ *** +|_Unnamed_ *** Alias: `column` |`string` -|The column or field from which to extract the values. +|The column or field from which to extract the values. -|distinct +|`distinct` |`boolean` -|Extract only unique values? +|Extract only unique values? Default: `true` -|quote +|`quote` |`string` -|The quote character to wrap around each extracted value. +|The quote character to wrap around each extracted value. Default: `"'"` -|separator +|`separator` -Aliases: `sep`, `delimiter` +Aliases: `delimiter`, `sep` |`string` |The delimiter to insert between each extracted value. -Default: `", "` +Default: `","` |=== *Returns:* `string` - [float] [[l_fns]] == L -[float] [float] [[location_fn]] === `location` -Find your current location using the Geolocation API of the browser. Performance can vary, but is fairly accurate. -See: https://developer.mozilla.org/en-US/docs/Web/API/Navigator/geolocation. +Find your current location using the Geolocation API of the browser. Performance can vary, but is fairly accurate. See https://developer.mozilla.org/en-US/docs/Web/API/Navigator/geolocation. Don’t use <> if you plan to generate PDFs as this function requires user input. *Accepts:* `null` @@ -1641,7 +1524,7 @@ Returns whether the _context_ is less than the argument. |=== |Argument |Type |Description -|_Unnamed_ *** +|_Unnamed_ *** Alias: `value` |`number`, `string` @@ -1663,7 +1546,7 @@ Returns whether the _context_ is less than or equal to the argument. |=== |Argument |Type |Description -|_Unnamed_ *** +|_Unnamed_ *** Alias: `value` |`number`, `string` @@ -1672,7 +1555,6 @@ Alias: `value` *Returns:* `boolean` - [float] [[m_fns]] == M @@ -1681,7 +1563,7 @@ Alias: `value` [[mapColumn_fn]] === `mapColumn` -Adds a column calculated as the result of other columns. Changes are made only when you provide arguments. See also <> and <>. +Adds a column calculated as the result of other columns. Changes are made only when you provide arguments.See also <> and <>. *Accepts:* `datatable` @@ -1689,15 +1571,15 @@ Adds a column calculated as the result of other columns. Changes are made only w |=== |Argument |Type |Description -|_Unnamed_ *** +|_Unnamed_ *** -Alias: `column` +Aliases: `column`, `name` |`string` |The name of the resulting column. |`expression` *** -Alias: `exp`, `fn`, `function` +Aliases: `exp`, `fn`, `function` |`boolean`, `number`, `string`, `null` |A Canvas expression that is passed to each row as a single row `datatable`. |=== @@ -1719,17 +1601,17 @@ Adds an element that renders Markdown text. TIP: Use the <> functio |_Unnamed_ † -Alias: `expression`, `content` +Aliases: `content`, `expression` |`string` -|A string of text that contains Markdown. To concatenate, pass the <> function multiple times. +|A string of text that contains Markdown. To concatenate, pass the `string` function multiple times. Default: `""` |`font` |`style` -|The CSS font properties for the content. For example, `font-family` or `font-weight`. +|The CSS font properties for the content. For example, "font-family" or "font-weight". -Default: `{font}` +Default: `${font}` |=== *Returns:* `render` @@ -1739,7 +1621,7 @@ Default: `{font}` [[math_fn]] === `math` -Interprets a `TinyMath` math expression using a `number` or `datatable` as _context_. The `datatable` columns are available by their column name. If the _context_ is a `number`, it is available as `value`. +Interprets a `TinyMath` math expression using a `number` or `datatable` as _context_. The `datatable` columns are available by their column name. If the _context_ is a number it is available as `value`. *Accepts:* `number`, `datatable` @@ -1747,11 +1629,11 @@ Interprets a `TinyMath` math expression using a `number` or `datatable` as _cont |=== |Argument |Type |Description -|_Unnamed_ *** +|_Unnamed_ Alias: `expression` |`string` -|An evaluated TinyMath expression. See <>. +|An evaluated `TinyMath` expression. See https://www.elastic.co/guide/en/kibana/current/canvas-tinymath-functions.html. |=== *Returns:* `number` @@ -1771,28 +1653,27 @@ Displays a number over a label. |_Unnamed_ -Aliases: `label`, `text`, `description` +Aliases: `description`, `label`, `text` |`string` |The text describing the metric. Default: `""` -|`metricFont` +|`labelFont` |`style` -|The CSS font properties for the metric. For example, `font-family` or `font-weight`. +|The CSS font properties for the label. For example, `font-family` or `font-weight`. -Default: `{font size=48 family="'Open Sans', Helvetica, Arial, sans-serif" color="#000000" align=center lHeight=48}`. +Default: `${font size=14 family="'Open Sans', Helvetica, Arial, sans-serif" color="#000000" align=center}` -|`labelFont` +|`metricFont` |`style` -|The CSS font properties for the label. For example, `font-family` or `font-weight`. +|The CSS font properties for the metric. For example, `font-family` or `font-weight`. -Default: `{font size=14 family="'Open Sans', Helvetica, Arial, sans-serif" color="#000000" align=center}`. +Default: `${font size=48 family="'Open Sans', Helvetica, Arial, sans-serif" color="#000000" align=center lHeight=48}` |=== *Returns:* `render` - [float] [[n_fns]] == N @@ -1809,7 +1690,7 @@ Returns whether the _context_ is not equal to the argument. |=== |Argument |Type |Description -|_Unnamed_ *** +|_Unnamed_ *** Alias: `value` |`boolean`, `number`, `string`, `null` @@ -1818,7 +1699,6 @@ Alias: `value` *Returns:* `boolean` - [float] [[p_fns]] == P @@ -1835,7 +1715,7 @@ Creates a color palette. |=== |Argument |Type |Description -|_Unnamed_ *** † +|_Unnamed_ † Alias: `color` |`string` @@ -1843,7 +1723,7 @@ Alias: `color` |`gradient` |`boolean` -|Make a gradient where supported? +|Make a gradient palette where supported? Default: `false` @@ -1873,17 +1753,17 @@ Configures a pie chart element. |`style` |The CSS font properties for the labels. For example, `font-family` or `font-weight`. -Default: `{font}` +Default: `${font}` |`hole` |`number` -|Draws a hole in the pie, 0-100, as a percentage of the pie radius. +|Draws a hole in the pie, between `0` and `100`, as a percentage of the pie radius. Default: `0` |`labelRadius` |`number` -|The percentage of the container area to use as a radius for the label circle. +|The percentage of the container area to use as a radius for the label circle. Default: `100` @@ -1895,19 +1775,19 @@ Default: `true` |`legend` |`string`, `boolean` -|The legend position. For example, `"nw"`, `"sw"`, `"ne"`, `"se"`. When `false`, the legend is hidden. +|The legend position. For example, `"nw"`, `"sw"`, `"ne"`, `"se"`, or `false`. When `false`, the legend is hidden. Default: `false` |`palette` |`palette` -|A `palette` object for describing the colors to use in this pie chart +|A `palette` object for describing the colors to use in this pie chart. -Default: `{palette}` +Default: `${palette}` |`radius` |`string`, `number` -|The radius of the pie as a percentage (between 0 and 1) of the available space. To automatically set radius, use `"auto"`. +|The radius of the pie as a percentage, between `0` and `1`, of the available space. To automatically set the radius, use `"auto"`. Default: `"auto"` @@ -1917,7 +1797,7 @@ Default: `"auto"` |`tilt` |`number` -|The percentage of tilt, where 1 is fully vertical, and 0 is completely flat. +|The percentage of tilt where `1` is fully vertical, and `0` is completely flat. Default: `1` |=== @@ -1929,7 +1809,7 @@ Default: `1` [[plot_fn]] === `plot` -Configures a plot element. +Configures a chart element. *Accepts:* `pointseries` @@ -1941,13 +1821,13 @@ Configures a plot element. |`seriesStyle` |The default style to use for every series. -Default: `{seriesStyle points=5}` +Default: `${seriesStyle points=5}` |`font` |`style` |The CSS font properties for the labels. For example, `font-family` or `font-weight`. -Default: `{font}` +Default: `${font}` |`legend` |`string`, `boolean` @@ -1957,9 +1837,9 @@ Default: `"ne"` |`palette` |`palette` -|A `palette` object for describing the colors to use in this chart +|A `palette` object for describing the colors to use in this chart. -Default: `{palette}` +Default: `${palette}` |`seriesStyle` † |`seriesStyle` @@ -1993,15 +1873,15 @@ Subdivides a `datatable` by the unique values of the specified columns, and pass |=== |Argument |Type |Description -|`by` *** † +|`by` † |`string` |The column to subdivide the `datatable`. -|`expression` *** † +|`expression` † -Alias: `fn`, `exp`, `function` +Aliases: `exp`, `fn`, `function` |`datatable` -|An expression to pass into each resulting data table. Expressions must return a `datatable`. Use `as` to turn literals into `datatable`s. Multiple expressions must return the same number of rows. If you need to return a different row count, pipe into another instance of <>. If multiple expressions return `datatable`s with the same column names, the last one wins. +|An expression to pass each resulting `datatable` into. Tips: Expressions must return a `datatable`. Use <> to turn literals into `datatable`s. Multiple expressions must return the same number of rows.If you need to return a different row count, pipe into another instance of <>. If multiple expressions returns the columns with the same name, the last one wins. |=== *Returns:* `datatable` @@ -2011,8 +1891,7 @@ Alias: `fn`, `exp`, `function` [[pointseries_fn]] === `pointseries` -Turns a `datatable` into a point series model. Currently we differentiate measure from dimensions by looking for a <>. If you enter a TinyMath -expression in your argument, Canvas treats that argument as a measure. Otherwise, it is a dimension. Dimensions are combined to create unique keys. Measures are then deduplicated by those keys using the specified TinyMath function. +Turn a `datatable` into a point series model. Currently we differentiate measure from dimensions by looking for a `TinyMath` expression. See https://www.elastic.co/guide/en/kibana/current/canvas-tinymath-functions.html. If you enter a `TinyMath` expression in your argument, we treat that argument as a measure, otherwise it is a dimension. Dimensions are combined to create unique keys. Measures are then deduplicated by those keys using the specified `TinyMath` function *Accepts:* `datatable` @@ -2048,7 +1927,7 @@ expression in your argument, Canvas treats that argument as a measure. Otherwise [[progress_fn]] === `progress` -Configures a progress element +Configures a progress element. *Accepts:* `number` @@ -2056,7 +1935,7 @@ Configures a progress element |=== |Argument |Type |Description -| _Unnamed_ +|_Unnamed_ Alias: `shape` |`string` @@ -2080,14 +1959,14 @@ Default: `20` |`style` |The CSS font properties for the label. For example, `font-family` or `font-weight`. -Default: `{font size=24 family="'Open Sans', Helvetica, Arial, sans-serif" color="#000000" align=center}` +Default: `${font size=24 family="'Open Sans', Helvetica, Arial, sans-serif" color="#000000" align=center}` |`label` |`boolean`, `string` -|To show or hide the value, use `true` or `false`. Alternatively, provide a string to display as a label. +|To show or hide the label, use `true` or `false`. Alternatively, provide a string to display as a label. Default: `true` - + |`max` |`number` |The maximum value of the progress element. @@ -2109,7 +1988,6 @@ Default: `20` *Returns:* `render` - [float] [[r_fns]] == R @@ -2128,19 +2006,19 @@ Renders the _context_ as a specific element and sets element level options, such |`as` |`string` -|The element type to render. You might want to use a specialized function instead, such as <> or <>. - -|`css` -|`string` -|Any block of custom CSS to be scoped to the element - -Default: `".canvasRenderEl{\n\n}"` +|The element type to render. You probably want a specialized function instead, such as <> or <>. |`containerStyle` |`containerStyle` |The style for the container, including background, border, and opacity. -Default: `{containerStyle}` +Default: `${containerStyle}` + +|`css` +|`string` +|Any block of custom CSS to be scoped to the element. + +Default: `".canvasRenderEl${}"` |=== *Returns:* `render` @@ -2159,20 +2037,26 @@ Configures a repeating image element. |Argument |Type |Description |`emptyImage` -|`string` +|`string`, `null` |Fills the difference between the _context_ and `max` parameter for the element with this image. Provide an image asset as a `base64` data URL, or pass in a sub-expression. Default: `null` |`image` -|`string` +|`string`, `null` |The image to repeat. Provide an image asset as a `base64` data URL, or pass in a sub-expression. +Example value for the `image` argument, formatted as a `base64` data URL: +[source, url] +------------ +data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22utf-8%22%3F%3E%0A%3Csvg%20viewBox%3D%22-3.948730230331421%20-1.7549896240234375%20245.25946044921875%20241.40370178222656%22%20width%3D%22245.25946044921875%22%20height%3D%22241.40370178222656%22%20style%3D%22enable-background%3Anew%200%200%20686.2%20235.7%3B%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%0A%20%20%3Cdefs%3E%0A%20%20%20%20%3Cstyle%20type%3D%22text%2Fcss%22%3E%0A%09.st0%7Bfill%3A%232D2D2D%3B%7D%0A%3C%2Fstyle%3E%0A%20%20%3C%2Fdefs%3E%0A%20%20%3Cg%20transform%3D%22matrix%281%2C%200%2C%200%2C%201%2C%200%2C%200%29%22%3E%0A%20%20%20%20%3Cg%3E%0A%20%20%20%20%20%20%3Cpath%20class%3D%22st0%22%20d%3D%22M329.4%2C160.3l4.7-0.5l0.3%2C9.6c-12.4%2C1.7-23%2C2.6-31.8%2C2.6c-11.7%2C0-20-3.4-24.9-10.2%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bc-4.9-6.8-7.3-17.4-7.3-31.7c0-28.6%2C11.4-42.9%2C34.1-42.9c11%2C0%2C19.2%2C3.1%2C24.6%2C9.2c5.4%2C6.1%2C8.1%2C15.8%2C8.1%2C28.9l-0.7%2C9.3h-53.8%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bc0%2C9%2C1.6%2C15.7%2C4.9%2C20c3.3%2C4.3%2C8.9%2C6.5%2C17%2C6.5C312.8%2C161.2%2C321.1%2C160.9%2C329.4%2C160.3z%20M325%2C124.9c0-10-1.6-17.1-4.8-21.2%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bc-3.2-4.1-8.4-6.2-15.6-6.2c-7.2%2C0-12.7%2C2.2-16.3%2C6.5c-3.6%2C4.3-5.5%2C11.3-5.6%2C20.9H325z%22%2F%3E%0A%20%20%20%20%20%20%3Cpath%20class%3D%22st0%22%20d%3D%22M354.3%2C171.4V64h12.2v107.4H354.3z%22%2F%3E%0A%20%20%20%20%20%20%3Cpath%20class%3D%22st0%22%20d%3D%22M443.5%2C113.5v41.1c0%2C4.1%2C10.1%2C3.9%2C10.1%2C3.9l-0.6%2C10.8c-8.6%2C0-15.7%2C0.7-20-3.4c-9.8%2C4.3-19.5%2C6.1-29.3%2C6.1%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bc-7.5%2C0-13.2-2.1-17.1-6.4c-3.9-4.2-5.9-10.3-5.9-18.3c0-7.9%2C2-13.8%2C6-17.5c4-3.7%2C10.3-6.1%2C18.9-6.9l25.6-2.4v-7%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bc0-5.5-1.2-9.5-3.6-11.9c-2.4-2.4-5.7-3.6-9.8-3.6l-32.1%2C0V87.2h31.3c9.2%2C0%2C15.9%2C2.1%2C20.1%2C6.4C441.4%2C97.8%2C443.5%2C104.5%2C443.5%2C113.5%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bz%20M393.3%2C146.7c0%2C10%2C4.1%2C15%2C12.4%2C15c7.4%2C0%2C14.7-1.2%2C21.8-3.7l3.7-1.3v-26.9l-24.1%2C2.3c-4.9%2C0.4-8.4%2C1.8-10.6%2C4.2%26%2310%3B%26%239%3B%26%239%3B%26%239%3BC394.4%2C138.7%2C393.3%2C142.2%2C393.3%2C146.7z%22%2F%3E%0A%20%20%20%20%20%20%3Cpath%20class%3D%22st0%22%20d%3D%22M491.2%2C98.2c-11.8%2C0-17.8%2C4.1-17.8%2C12.4c0%2C3.8%2C1.4%2C6.5%2C4.1%2C8.1c2.7%2C1.6%2C8.9%2C3.2%2C18.6%2C4.9%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bc9.7%2C1.7%2C16.5%2C4%2C20.5%2C7.1c4%2C3%2C6%2C8.7%2C6%2C17.1c0%2C8.4-2.7%2C14.5-8.1%2C18.4c-5.4%2C3.9-13.2%2C5.9-23.6%2C5.9c-6.7%2C0-29.2-2.5-29.2-2.5%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bl0.7-10.6c12.9%2C1.2%2C22.3%2C2.2%2C28.6%2C2.2c6.3%2C0%2C11.1-1%2C14.4-3c3.3-2%2C5-5.4%2C5-10.1c0-4.7-1.4-7.9-4.2-9.6c-2.8-1.7-9-3.3-18.6-4.8%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bc-9.6-1.5-16.4-3.7-20.4-6.7c-4-2.9-6-8.4-6-16.3c0-7.9%2C2.8-13.8%2C8.4-17.6c5.6-3.8%2C12.6-5.7%2C20.9-5.7c6.6%2C0%2C29.6%2C1.7%2C29.6%2C1.7%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bv10.7C508.1%2C99%2C498.2%2C98.2%2C491.2%2C98.2z%22%2F%3E%0A%20%20%20%20%20%20%3Cpath%20class%3D%22st0%22%20d%3D%22M581.7%2C99.5h-25.9v39c0%2C9.3%2C0.7%2C15.5%2C2%2C18.4c1.4%2C2.9%2C4.6%2C4.4%2C9.7%2C4.4l14.5-1l0.8%2C10.1%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bc-7.3%2C1.2-12.8%2C1.8-16.6%2C1.8c-8.5%2C0-14.3-2.1-17.6-6.2c-3.3-4.1-4.9-12-4.9-23.6V99.5h-11.6V88.9h11.6V63.9h12.1v24.9h25.9V99.5z%22%2F%3E%0A%20%20%20%20%20%20%3Cpath%20class%3D%22st0%22%20d%3D%22M598.7%2C78.4V64.3h12.2v14.2H598.7z%20M598.7%2C171.4V88.9h12.2v82.5H598.7z%22%2F%3E%0A%20%20%20%20%20%20%3Cpath%20class%3D%22st0%22%20d%3D%22M663.8%2C87.2c3.6%2C0%2C9.7%2C0.7%2C18.3%2C2l3.9%2C0.5l-0.5%2C9.9c-8.7-1-15.1-1.5-19.2-1.5c-9.2%2C0-15.5%2C2.2-18.8%2C6.6%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bc-3.3%2C4.4-5%2C12.6-5%2C24.5c0%2C11.9%2C1.5%2C20.2%2C4.6%2C24.9c3.1%2C4.7%2C9.5%2C7%2C19.3%2C7l19.2-1.5l0.5%2C10.1c-10.1%2C1.5-17.7%2C2.3-22.7%2C2.3%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bc-12.7%2C0-21.5-3.3-26.3-9.8c-4.8-6.5-7.3-17.5-7.3-33c0-15.5%2C2.6-26.4%2C7.8-32.6C643%2C90.4%2C651.7%2C87.2%2C663.8%2C87.2z%22%2F%3E%0A%20%20%20%20%3C%2Fg%3E%0A%20%20%20%20%3Cpath%20class%3D%22st0%22%20d%3D%22M236.6%2C123.5c0-19.8-12.3-37.2-30.8-43.9c0.8-4.2%2C1.2-8.4%2C1.2-12.7C207%2C30%2C177%2C0%2C140.2%2C0%26%2310%3B%26%239%3B%26%239%3BC118.6%2C0%2C98.6%2C10.3%2C86%2C27.7c-6.2-4.8-13.8-7.4-21.7-7.4c-19.6%2C0-35.5%2C15.9-35.5%2C35.5c0%2C4.3%2C0.8%2C8.5%2C2.2%2C12.4%26%2310%3B%26%239%3B%26%239%3BC12.6%2C74.8%2C0%2C92.5%2C0%2C112.2c0%2C19.9%2C12.4%2C37.3%2C30.9%2C44c-0.8%2C4.1-1.2%2C8.4-1.2%2C12.7c0%2C36.8%2C29.9%2C66.7%2C66.7%2C66.7%26%2310%3B%26%239%3B%26%239%3Bc21.6%2C0%2C41.6-10.4%2C54.1-27.8c6.2%2C4.9%2C13.8%2C7.6%2C21.7%2C7.6c19.6%2C0%2C35.5-15.9%2C35.5-35.5c0-4.3-0.8-8.5-2.2-12.4%26%2310%3B%26%239%3B%26%239%3BC223.9%2C160.9%2C236.6%2C143.2%2C236.6%2C123.5z%20M91.6%2C34.8c10.9-15.9%2C28.9-25.4%2C48.1-25.4c32.2%2C0%2C58.4%2C26.2%2C58.4%2C58.4%26%2310%3B%26%239%3B%26%239%3Bc0%2C3.9-0.4%2C7.7-1.1%2C11.5l-52.2%2C45.8L93%2C101.5L82.9%2C79.9L91.6%2C34.8z%20M65.4%2C29c6.2%2C0%2C12.1%2C2%2C17%2C5.7l-7.8%2C40.3l-35.5-8.4%26%2310%3B%26%239%3B%26%239%3Bc-1.1-3.1-1.7-6.3-1.7-9.7C37.4%2C41.6%2C49.9%2C29%2C65.4%2C29z%20M9.1%2C112.3c0-16.7%2C11-31.9%2C26.9-37.2L75%2C84.4l9.1%2C19.5l-49.8%2C45%26%2310%3B%26%239%3B%26%239%3BC19.2%2C143.1%2C9.1%2C128.6%2C9.1%2C112.3z%20M145.2%2C200.9c-10.9%2C16.1-29%2C25.6-48.4%2C25.6c-32.3%2C0-58.6-26.3-58.6-58.5c0-4%2C0.4-7.9%2C1.1-11.7%26%2310%3B%26%239%3B%26%239%3Bl50.9-46l52%2C23.7l11.5%2C22L145.2%2C200.9z%20M171.2%2C206.6c-6.1%2C0-12-2-16.9-5.8l7.7-40.2l35.4%2C8.3c1.1%2C3.1%2C1.7%2C6.3%2C1.7%2C9.7%26%2310%3B%26%239%3B%26%239%3BC199.2%2C194.1%2C186.6%2C206.6%2C171.2%2C206.6z%20M200.5%2C160.5l-39-9.1l-10.4-19.8l51-44.7c15.1%2C5.7%2C25.2%2C20.2%2C25.2%2C36.5%26%2310%3B%26%239%3B%26%239%3BC227.4%2C140.1%2C216.4%2C155.3%2C200.5%2C160.5z%22%2F%3E%0A%20%20%3C%2Fg%3E%0A%3C%2Fsvg%3E +------------ + |`max` |`number` |The maximum number of times the image can repeat. -Default: `100` +Default: `1000` |`size` |`number` @@ -2181,13 +2065,6 @@ Default: `100` Default: `100` |=== - -Example value for the `image` argument, formatted as a `base64` data URL: -[source, url] ------------- -data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22utf-8%22%3F%3E%0A%3Csvg%20viewBox%3D%22-3.948730230331421%20-1.7549896240234375%20245.25946044921875%20241.40370178222656%22%20width%3D%22245.25946044921875%22%20height%3D%22241.40370178222656%22%20style%3D%22enable-background%3Anew%200%200%20686.2%20235.7%3B%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%0A%20%20%3Cdefs%3E%0A%20%20%20%20%3Cstyle%20type%3D%22text%2Fcss%22%3E%0A%09.st0%7Bfill%3A%232D2D2D%3B%7D%0A%3C%2Fstyle%3E%0A%20%20%3C%2Fdefs%3E%0A%20%20%3Cg%20transform%3D%22matrix%281%2C%200%2C%200%2C%201%2C%200%2C%200%29%22%3E%0A%20%20%20%20%3Cg%3E%0A%20%20%20%20%20%20%3Cpath%20class%3D%22st0%22%20d%3D%22M329.4%2C160.3l4.7-0.5l0.3%2C9.6c-12.4%2C1.7-23%2C2.6-31.8%2C2.6c-11.7%2C0-20-3.4-24.9-10.2%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bc-4.9-6.8-7.3-17.4-7.3-31.7c0-28.6%2C11.4-42.9%2C34.1-42.9c11%2C0%2C19.2%2C3.1%2C24.6%2C9.2c5.4%2C6.1%2C8.1%2C15.8%2C8.1%2C28.9l-0.7%2C9.3h-53.8%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bc0%2C9%2C1.6%2C15.7%2C4.9%2C20c3.3%2C4.3%2C8.9%2C6.5%2C17%2C6.5C312.8%2C161.2%2C321.1%2C160.9%2C329.4%2C160.3z%20M325%2C124.9c0-10-1.6-17.1-4.8-21.2%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bc-3.2-4.1-8.4-6.2-15.6-6.2c-7.2%2C0-12.7%2C2.2-16.3%2C6.5c-3.6%2C4.3-5.5%2C11.3-5.6%2C20.9H325z%22%2F%3E%0A%20%20%20%20%20%20%3Cpath%20class%3D%22st0%22%20d%3D%22M354.3%2C171.4V64h12.2v107.4H354.3z%22%2F%3E%0A%20%20%20%20%20%20%3Cpath%20class%3D%22st0%22%20d%3D%22M443.5%2C113.5v41.1c0%2C4.1%2C10.1%2C3.9%2C10.1%2C3.9l-0.6%2C10.8c-8.6%2C0-15.7%2C0.7-20-3.4c-9.8%2C4.3-19.5%2C6.1-29.3%2C6.1%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bc-7.5%2C0-13.2-2.1-17.1-6.4c-3.9-4.2-5.9-10.3-5.9-18.3c0-7.9%2C2-13.8%2C6-17.5c4-3.7%2C10.3-6.1%2C18.9-6.9l25.6-2.4v-7%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bc0-5.5-1.2-9.5-3.6-11.9c-2.4-2.4-5.7-3.6-9.8-3.6l-32.1%2C0V87.2h31.3c9.2%2C0%2C15.9%2C2.1%2C20.1%2C6.4C441.4%2C97.8%2C443.5%2C104.5%2C443.5%2C113.5%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bz%20M393.3%2C146.7c0%2C10%2C4.1%2C15%2C12.4%2C15c7.4%2C0%2C14.7-1.2%2C21.8-3.7l3.7-1.3v-26.9l-24.1%2C2.3c-4.9%2C0.4-8.4%2C1.8-10.6%2C4.2%26%2310%3B%26%239%3B%26%239%3B%26%239%3BC394.4%2C138.7%2C393.3%2C142.2%2C393.3%2C146.7z%22%2F%3E%0A%20%20%20%20%20%20%3Cpath%20class%3D%22st0%22%20d%3D%22M491.2%2C98.2c-11.8%2C0-17.8%2C4.1-17.8%2C12.4c0%2C3.8%2C1.4%2C6.5%2C4.1%2C8.1c2.7%2C1.6%2C8.9%2C3.2%2C18.6%2C4.9%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bc9.7%2C1.7%2C16.5%2C4%2C20.5%2C7.1c4%2C3%2C6%2C8.7%2C6%2C17.1c0%2C8.4-2.7%2C14.5-8.1%2C18.4c-5.4%2C3.9-13.2%2C5.9-23.6%2C5.9c-6.7%2C0-29.2-2.5-29.2-2.5%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bl0.7-10.6c12.9%2C1.2%2C22.3%2C2.2%2C28.6%2C2.2c6.3%2C0%2C11.1-1%2C14.4-3c3.3-2%2C5-5.4%2C5-10.1c0-4.7-1.4-7.9-4.2-9.6c-2.8-1.7-9-3.3-18.6-4.8%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bc-9.6-1.5-16.4-3.7-20.4-6.7c-4-2.9-6-8.4-6-16.3c0-7.9%2C2.8-13.8%2C8.4-17.6c5.6-3.8%2C12.6-5.7%2C20.9-5.7c6.6%2C0%2C29.6%2C1.7%2C29.6%2C1.7%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bv10.7C508.1%2C99%2C498.2%2C98.2%2C491.2%2C98.2z%22%2F%3E%0A%20%20%20%20%20%20%3Cpath%20class%3D%22st0%22%20d%3D%22M581.7%2C99.5h-25.9v39c0%2C9.3%2C0.7%2C15.5%2C2%2C18.4c1.4%2C2.9%2C4.6%2C4.4%2C9.7%2C4.4l14.5-1l0.8%2C10.1%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bc-7.3%2C1.2-12.8%2C1.8-16.6%2C1.8c-8.5%2C0-14.3-2.1-17.6-6.2c-3.3-4.1-4.9-12-4.9-23.6V99.5h-11.6V88.9h11.6V63.9h12.1v24.9h25.9V99.5z%22%2F%3E%0A%20%20%20%20%20%20%3Cpath%20class%3D%22st0%22%20d%3D%22M598.7%2C78.4V64.3h12.2v14.2H598.7z%20M598.7%2C171.4V88.9h12.2v82.5H598.7z%22%2F%3E%0A%20%20%20%20%20%20%3Cpath%20class%3D%22st0%22%20d%3D%22M663.8%2C87.2c3.6%2C0%2C9.7%2C0.7%2C18.3%2C2l3.9%2C0.5l-0.5%2C9.9c-8.7-1-15.1-1.5-19.2-1.5c-9.2%2C0-15.5%2C2.2-18.8%2C6.6%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bc-3.3%2C4.4-5%2C12.6-5%2C24.5c0%2C11.9%2C1.5%2C20.2%2C4.6%2C24.9c3.1%2C4.7%2C9.5%2C7%2C19.3%2C7l19.2-1.5l0.5%2C10.1c-10.1%2C1.5-17.7%2C2.3-22.7%2C2.3%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bc-12.7%2C0-21.5-3.3-26.3-9.8c-4.8-6.5-7.3-17.5-7.3-33c0-15.5%2C2.6-26.4%2C7.8-32.6C643%2C90.4%2C651.7%2C87.2%2C663.8%2C87.2z%22%2F%3E%0A%20%20%20%20%3C%2Fg%3E%0A%20%20%20%20%3Cpath%20class%3D%22st0%22%20d%3D%22M236.6%2C123.5c0-19.8-12.3-37.2-30.8-43.9c0.8-4.2%2C1.2-8.4%2C1.2-12.7C207%2C30%2C177%2C0%2C140.2%2C0%26%2310%3B%26%239%3B%26%239%3BC118.6%2C0%2C98.6%2C10.3%2C86%2C27.7c-6.2-4.8-13.8-7.4-21.7-7.4c-19.6%2C0-35.5%2C15.9-35.5%2C35.5c0%2C4.3%2C0.8%2C8.5%2C2.2%2C12.4%26%2310%3B%26%239%3B%26%239%3BC12.6%2C74.8%2C0%2C92.5%2C0%2C112.2c0%2C19.9%2C12.4%2C37.3%2C30.9%2C44c-0.8%2C4.1-1.2%2C8.4-1.2%2C12.7c0%2C36.8%2C29.9%2C66.7%2C66.7%2C66.7%26%2310%3B%26%239%3B%26%239%3Bc21.6%2C0%2C41.6-10.4%2C54.1-27.8c6.2%2C4.9%2C13.8%2C7.6%2C21.7%2C7.6c19.6%2C0%2C35.5-15.9%2C35.5-35.5c0-4.3-0.8-8.5-2.2-12.4%26%2310%3B%26%239%3B%26%239%3BC223.9%2C160.9%2C236.6%2C143.2%2C236.6%2C123.5z%20M91.6%2C34.8c10.9-15.9%2C28.9-25.4%2C48.1-25.4c32.2%2C0%2C58.4%2C26.2%2C58.4%2C58.4%26%2310%3B%26%239%3B%26%239%3Bc0%2C3.9-0.4%2C7.7-1.1%2C11.5l-52.2%2C45.8L93%2C101.5L82.9%2C79.9L91.6%2C34.8z%20M65.4%2C29c6.2%2C0%2C12.1%2C2%2C17%2C5.7l-7.8%2C40.3l-35.5-8.4%26%2310%3B%26%239%3B%26%239%3Bc-1.1-3.1-1.7-6.3-1.7-9.7C37.4%2C41.6%2C49.9%2C29%2C65.4%2C29z%20M9.1%2C112.3c0-16.7%2C11-31.9%2C26.9-37.2L75%2C84.4l9.1%2C19.5l-49.8%2C45%26%2310%3B%26%239%3B%26%239%3BC19.2%2C143.1%2C9.1%2C128.6%2C9.1%2C112.3z%20M145.2%2C200.9c-10.9%2C16.1-29%2C25.6-48.4%2C25.6c-32.3%2C0-58.6-26.3-58.6-58.5c0-4%2C0.4-7.9%2C1.1-11.7%26%2310%3B%26%239%3B%26%239%3Bl50.9-46l52%2C23.7l11.5%2C22L145.2%2C200.9z%20M171.2%2C206.6c-6.1%2C0-12-2-16.9-5.8l7.7-40.2l35.4%2C8.3c1.1%2C3.1%2C1.7%2C6.3%2C1.7%2C9.7%26%2310%3B%26%239%3B%26%239%3BC199.2%2C194.1%2C186.6%2C206.6%2C171.2%2C206.6z%20M200.5%2C160.5l-39-9.1l-10.4-19.8l51-44.7c15.1%2C5.7%2C25.2%2C20.2%2C25.2%2C36.5%26%2310%3B%26%239%3B%26%239%3BC227.4%2C140.1%2C216.4%2C155.3%2C200.5%2C160.5z%22%2F%3E%0A%20%20%3C%2Fg%3E%0A%3C%2Fsvg%3E ------------- - *Returns:* `render` @@ -2203,27 +2080,23 @@ Uses a regular expression to replace parts of a string. |=== |Argument |Type |Description -|_Unnamed_ *** +|_Unnamed_ -Alias: `pattern`, `regex` +Aliases: `pattern`, `regex` |`string` -|The text or pattern of a JavaScript regular expression. For example, `"[aeiou]"`. -You can use capturing groups here. +|The text or pattern of a JavaScript regular expression. For example, `"[aeiou]"`. You can use capturing groups here. -|`flags` +|`flags` Alias: `modifiers` -|`datatable` -|Specify flags. See the -https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/RegExp[RegExp documentation] -for reference +|`string` +|Specify flags. See https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/RegExp. Default: `"g"` |`replacement` |`string` -|The replacement for the matching parts of `string`. Capturing groups can be accessed -by their index. For example, `$1`. +|The replacement for the matching parts of string. Capturing groups can be accessed by their index. For example, `"$1"`. Default: `""` |=== @@ -2243,28 +2116,29 @@ Configures an image reveal element. |=== |Argument |Type |Description +|`emptyImage` +|`string`, `null` +|An optional background image to reveal over. Provide an image asset as a ``base64`` data URL, or pass in a sub-expression. + +Default: `null` + |`image` -|`string` +|`string`, `null` |The image to reveal. Provide an image asset as a `base64` data URL, or pass in a sub-expression. -|`emptyImage` -|`string` -|An optional background image to reveal over. Provide an image asset as a `base64` data URL, or pass in a sub-expression. +Example value for the `image` argument, formatted as a `base64` data URL: +[source, url] +------------ +data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22utf-8%22%3F%3E%0A%3Csvg%20viewBox%3D%22-3.948730230331421%20-1.7549896240234375%20245.25946044921875%20241.40370178222656%22%20width%3D%22245.25946044921875%22%20height%3D%22241.40370178222656%22%20style%3D%22enable-background%3Anew%200%200%20686.2%20235.7%3B%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%0A%20%20%3Cdefs%3E%0A%20%20%20%20%3Cstyle%20type%3D%22text%2Fcss%22%3E%0A%09.st0%7Bfill%3A%232D2D2D%3B%7D%0A%3C%2Fstyle%3E%0A%20%20%3C%2Fdefs%3E%0A%20%20%3Cg%20transform%3D%22matrix%281%2C%200%2C%200%2C%201%2C%200%2C%200%29%22%3E%0A%20%20%20%20%3Cg%3E%0A%20%20%20%20%20%20%3Cpath%20class%3D%22st0%22%20d%3D%22M329.4%2C160.3l4.7-0.5l0.3%2C9.6c-12.4%2C1.7-23%2C2.6-31.8%2C2.6c-11.7%2C0-20-3.4-24.9-10.2%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bc-4.9-6.8-7.3-17.4-7.3-31.7c0-28.6%2C11.4-42.9%2C34.1-42.9c11%2C0%2C19.2%2C3.1%2C24.6%2C9.2c5.4%2C6.1%2C8.1%2C15.8%2C8.1%2C28.9l-0.7%2C9.3h-53.8%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bc0%2C9%2C1.6%2C15.7%2C4.9%2C20c3.3%2C4.3%2C8.9%2C6.5%2C17%2C6.5C312.8%2C161.2%2C321.1%2C160.9%2C329.4%2C160.3z%20M325%2C124.9c0-10-1.6-17.1-4.8-21.2%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bc-3.2-4.1-8.4-6.2-15.6-6.2c-7.2%2C0-12.7%2C2.2-16.3%2C6.5c-3.6%2C4.3-5.5%2C11.3-5.6%2C20.9H325z%22%2F%3E%0A%20%20%20%20%20%20%3Cpath%20class%3D%22st0%22%20d%3D%22M354.3%2C171.4V64h12.2v107.4H354.3z%22%2F%3E%0A%20%20%20%20%20%20%3Cpath%20class%3D%22st0%22%20d%3D%22M443.5%2C113.5v41.1c0%2C4.1%2C10.1%2C3.9%2C10.1%2C3.9l-0.6%2C10.8c-8.6%2C0-15.7%2C0.7-20-3.4c-9.8%2C4.3-19.5%2C6.1-29.3%2C6.1%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bc-7.5%2C0-13.2-2.1-17.1-6.4c-3.9-4.2-5.9-10.3-5.9-18.3c0-7.9%2C2-13.8%2C6-17.5c4-3.7%2C10.3-6.1%2C18.9-6.9l25.6-2.4v-7%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bc0-5.5-1.2-9.5-3.6-11.9c-2.4-2.4-5.7-3.6-9.8-3.6l-32.1%2C0V87.2h31.3c9.2%2C0%2C15.9%2C2.1%2C20.1%2C6.4C441.4%2C97.8%2C443.5%2C104.5%2C443.5%2C113.5%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bz%20M393.3%2C146.7c0%2C10%2C4.1%2C15%2C12.4%2C15c7.4%2C0%2C14.7-1.2%2C21.8-3.7l3.7-1.3v-26.9l-24.1%2C2.3c-4.9%2C0.4-8.4%2C1.8-10.6%2C4.2%26%2310%3B%26%239%3B%26%239%3B%26%239%3BC394.4%2C138.7%2C393.3%2C142.2%2C393.3%2C146.7z%22%2F%3E%0A%20%20%20%20%20%20%3Cpath%20class%3D%22st0%22%20d%3D%22M491.2%2C98.2c-11.8%2C0-17.8%2C4.1-17.8%2C12.4c0%2C3.8%2C1.4%2C6.5%2C4.1%2C8.1c2.7%2C1.6%2C8.9%2C3.2%2C18.6%2C4.9%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bc9.7%2C1.7%2C16.5%2C4%2C20.5%2C7.1c4%2C3%2C6%2C8.7%2C6%2C17.1c0%2C8.4-2.7%2C14.5-8.1%2C18.4c-5.4%2C3.9-13.2%2C5.9-23.6%2C5.9c-6.7%2C0-29.2-2.5-29.2-2.5%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bl0.7-10.6c12.9%2C1.2%2C22.3%2C2.2%2C28.6%2C2.2c6.3%2C0%2C11.1-1%2C14.4-3c3.3-2%2C5-5.4%2C5-10.1c0-4.7-1.4-7.9-4.2-9.6c-2.8-1.7-9-3.3-18.6-4.8%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bc-9.6-1.5-16.4-3.7-20.4-6.7c-4-2.9-6-8.4-6-16.3c0-7.9%2C2.8-13.8%2C8.4-17.6c5.6-3.8%2C12.6-5.7%2C20.9-5.7c6.6%2C0%2C29.6%2C1.7%2C29.6%2C1.7%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bv10.7C508.1%2C99%2C498.2%2C98.2%2C491.2%2C98.2z%22%2F%3E%0A%20%20%20%20%20%20%3Cpath%20class%3D%22st0%22%20d%3D%22M581.7%2C99.5h-25.9v39c0%2C9.3%2C0.7%2C15.5%2C2%2C18.4c1.4%2C2.9%2C4.6%2C4.4%2C9.7%2C4.4l14.5-1l0.8%2C10.1%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bc-7.3%2C1.2-12.8%2C1.8-16.6%2C1.8c-8.5%2C0-14.3-2.1-17.6-6.2c-3.3-4.1-4.9-12-4.9-23.6V99.5h-11.6V88.9h11.6V63.9h12.1v24.9h25.9V99.5z%22%2F%3E%0A%20%20%20%20%20%20%3Cpath%20class%3D%22st0%22%20d%3D%22M598.7%2C78.4V64.3h12.2v14.2H598.7z%20M598.7%2C171.4V88.9h12.2v82.5H598.7z%22%2F%3E%0A%20%20%20%20%20%20%3Cpath%20class%3D%22st0%22%20d%3D%22M663.8%2C87.2c3.6%2C0%2C9.7%2C0.7%2C18.3%2C2l3.9%2C0.5l-0.5%2C9.9c-8.7-1-15.1-1.5-19.2-1.5c-9.2%2C0-15.5%2C2.2-18.8%2C6.6%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bc-3.3%2C4.4-5%2C12.6-5%2C24.5c0%2C11.9%2C1.5%2C20.2%2C4.6%2C24.9c3.1%2C4.7%2C9.5%2C7%2C19.3%2C7l19.2-1.5l0.5%2C10.1c-10.1%2C1.5-17.7%2C2.3-22.7%2C2.3%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bc-12.7%2C0-21.5-3.3-26.3-9.8c-4.8-6.5-7.3-17.5-7.3-33c0-15.5%2C2.6-26.4%2C7.8-32.6C643%2C90.4%2C651.7%2C87.2%2C663.8%2C87.2z%22%2F%3E%0A%20%20%20%20%3C%2Fg%3E%0A%20%20%20%20%3Cpath%20class%3D%22st0%22%20d%3D%22M236.6%2C123.5c0-19.8-12.3-37.2-30.8-43.9c0.8-4.2%2C1.2-8.4%2C1.2-12.7C207%2C30%2C177%2C0%2C140.2%2C0%26%2310%3B%26%239%3B%26%239%3BC118.6%2C0%2C98.6%2C10.3%2C86%2C27.7c-6.2-4.8-13.8-7.4-21.7-7.4c-19.6%2C0-35.5%2C15.9-35.5%2C35.5c0%2C4.3%2C0.8%2C8.5%2C2.2%2C12.4%26%2310%3B%26%239%3B%26%239%3BC12.6%2C74.8%2C0%2C92.5%2C0%2C112.2c0%2C19.9%2C12.4%2C37.3%2C30.9%2C44c-0.8%2C4.1-1.2%2C8.4-1.2%2C12.7c0%2C36.8%2C29.9%2C66.7%2C66.7%2C66.7%26%2310%3B%26%239%3B%26%239%3Bc21.6%2C0%2C41.6-10.4%2C54.1-27.8c6.2%2C4.9%2C13.8%2C7.6%2C21.7%2C7.6c19.6%2C0%2C35.5-15.9%2C35.5-35.5c0-4.3-0.8-8.5-2.2-12.4%26%2310%3B%26%239%3B%26%239%3BC223.9%2C160.9%2C236.6%2C143.2%2C236.6%2C123.5z%20M91.6%2C34.8c10.9-15.9%2C28.9-25.4%2C48.1-25.4c32.2%2C0%2C58.4%2C26.2%2C58.4%2C58.4%26%2310%3B%26%239%3B%26%239%3Bc0%2C3.9-0.4%2C7.7-1.1%2C11.5l-52.2%2C45.8L93%2C101.5L82.9%2C79.9L91.6%2C34.8z%20M65.4%2C29c6.2%2C0%2C12.1%2C2%2C17%2C5.7l-7.8%2C40.3l-35.5-8.4%26%2310%3B%26%239%3B%26%239%3Bc-1.1-3.1-1.7-6.3-1.7-9.7C37.4%2C41.6%2C49.9%2C29%2C65.4%2C29z%20M9.1%2C112.3c0-16.7%2C11-31.9%2C26.9-37.2L75%2C84.4l9.1%2C19.5l-49.8%2C45%26%2310%3B%26%239%3B%26%239%3BC19.2%2C143.1%2C9.1%2C128.6%2C9.1%2C112.3z%20M145.2%2C200.9c-10.9%2C16.1-29%2C25.6-48.4%2C25.6c-32.3%2C0-58.6-26.3-58.6-58.5c0-4%2C0.4-7.9%2C1.1-11.7%26%2310%3B%26%239%3B%26%239%3Bl50.9-46l52%2C23.7l11.5%2C22L145.2%2C200.9z%20M171.2%2C206.6c-6.1%2C0-12-2-16.9-5.8l7.7-40.2l35.4%2C8.3c1.1%2C3.1%2C1.7%2C6.3%2C1.7%2C9.7%26%2310%3B%26%239%3B%26%239%3BC199.2%2C194.1%2C186.6%2C206.6%2C171.2%2C206.6z%20M200.5%2C160.5l-39-9.1l-10.4-19.8l51-44.7c15.1%2C5.7%2C25.2%2C20.2%2C25.2%2C36.5%26%2310%3B%26%239%3B%26%239%3BC227.4%2C140.1%2C216.4%2C155.3%2C200.5%2C160.5z%22%2F%3E%0A%20%20%3C%2Fg%3E%0A%3C%2Fsvg%3E +------------ |`origin` |`string` -|The position to start the image fill. For example, `"top"`, `"left"`, `"bottom"`, or `"right"` +|The position to start the image fill. For example, `"top"`, `"bottom"`, `"left"`, or right. Default: `"bottom"` |=== - -Example value for the `image` argument, formatted as a `base64` data URL: -[source, url] ------------- -data:image/svg+xml,%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22utf-8%22%3F%3E%0A%3Csvg%20viewBox%3D%22-3.948730230331421%20-1.7549896240234375%20245.25946044921875%20241.40370178222656%22%20width%3D%22245.25946044921875%22%20height%3D%22241.40370178222656%22%20style%3D%22enable-background%3Anew%200%200%20686.2%20235.7%3B%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%0A%20%20%3Cdefs%3E%0A%20%20%20%20%3Cstyle%20type%3D%22text%2Fcss%22%3E%0A%09.st0%7Bfill%3A%232D2D2D%3B%7D%0A%3C%2Fstyle%3E%0A%20%20%3C%2Fdefs%3E%0A%20%20%3Cg%20transform%3D%22matrix%281%2C%200%2C%200%2C%201%2C%200%2C%200%29%22%3E%0A%20%20%20%20%3Cg%3E%0A%20%20%20%20%20%20%3Cpath%20class%3D%22st0%22%20d%3D%22M329.4%2C160.3l4.7-0.5l0.3%2C9.6c-12.4%2C1.7-23%2C2.6-31.8%2C2.6c-11.7%2C0-20-3.4-24.9-10.2%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bc-4.9-6.8-7.3-17.4-7.3-31.7c0-28.6%2C11.4-42.9%2C34.1-42.9c11%2C0%2C19.2%2C3.1%2C24.6%2C9.2c5.4%2C6.1%2C8.1%2C15.8%2C8.1%2C28.9l-0.7%2C9.3h-53.8%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bc0%2C9%2C1.6%2C15.7%2C4.9%2C20c3.3%2C4.3%2C8.9%2C6.5%2C17%2C6.5C312.8%2C161.2%2C321.1%2C160.9%2C329.4%2C160.3z%20M325%2C124.9c0-10-1.6-17.1-4.8-21.2%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bc-3.2-4.1-8.4-6.2-15.6-6.2c-7.2%2C0-12.7%2C2.2-16.3%2C6.5c-3.6%2C4.3-5.5%2C11.3-5.6%2C20.9H325z%22%2F%3E%0A%20%20%20%20%20%20%3Cpath%20class%3D%22st0%22%20d%3D%22M354.3%2C171.4V64h12.2v107.4H354.3z%22%2F%3E%0A%20%20%20%20%20%20%3Cpath%20class%3D%22st0%22%20d%3D%22M443.5%2C113.5v41.1c0%2C4.1%2C10.1%2C3.9%2C10.1%2C3.9l-0.6%2C10.8c-8.6%2C0-15.7%2C0.7-20-3.4c-9.8%2C4.3-19.5%2C6.1-29.3%2C6.1%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bc-7.5%2C0-13.2-2.1-17.1-6.4c-3.9-4.2-5.9-10.3-5.9-18.3c0-7.9%2C2-13.8%2C6-17.5c4-3.7%2C10.3-6.1%2C18.9-6.9l25.6-2.4v-7%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bc0-5.5-1.2-9.5-3.6-11.9c-2.4-2.4-5.7-3.6-9.8-3.6l-32.1%2C0V87.2h31.3c9.2%2C0%2C15.9%2C2.1%2C20.1%2C6.4C441.4%2C97.8%2C443.5%2C104.5%2C443.5%2C113.5%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bz%20M393.3%2C146.7c0%2C10%2C4.1%2C15%2C12.4%2C15c7.4%2C0%2C14.7-1.2%2C21.8-3.7l3.7-1.3v-26.9l-24.1%2C2.3c-4.9%2C0.4-8.4%2C1.8-10.6%2C4.2%26%2310%3B%26%239%3B%26%239%3B%26%239%3BC394.4%2C138.7%2C393.3%2C142.2%2C393.3%2C146.7z%22%2F%3E%0A%20%20%20%20%20%20%3Cpath%20class%3D%22st0%22%20d%3D%22M491.2%2C98.2c-11.8%2C0-17.8%2C4.1-17.8%2C12.4c0%2C3.8%2C1.4%2C6.5%2C4.1%2C8.1c2.7%2C1.6%2C8.9%2C3.2%2C18.6%2C4.9%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bc9.7%2C1.7%2C16.5%2C4%2C20.5%2C7.1c4%2C3%2C6%2C8.7%2C6%2C17.1c0%2C8.4-2.7%2C14.5-8.1%2C18.4c-5.4%2C3.9-13.2%2C5.9-23.6%2C5.9c-6.7%2C0-29.2-2.5-29.2-2.5%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bl0.7-10.6c12.9%2C1.2%2C22.3%2C2.2%2C28.6%2C2.2c6.3%2C0%2C11.1-1%2C14.4-3c3.3-2%2C5-5.4%2C5-10.1c0-4.7-1.4-7.9-4.2-9.6c-2.8-1.7-9-3.3-18.6-4.8%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bc-9.6-1.5-16.4-3.7-20.4-6.7c-4-2.9-6-8.4-6-16.3c0-7.9%2C2.8-13.8%2C8.4-17.6c5.6-3.8%2C12.6-5.7%2C20.9-5.7c6.6%2C0%2C29.6%2C1.7%2C29.6%2C1.7%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bv10.7C508.1%2C99%2C498.2%2C98.2%2C491.2%2C98.2z%22%2F%3E%0A%20%20%20%20%20%20%3Cpath%20class%3D%22st0%22%20d%3D%22M581.7%2C99.5h-25.9v39c0%2C9.3%2C0.7%2C15.5%2C2%2C18.4c1.4%2C2.9%2C4.6%2C4.4%2C9.7%2C4.4l14.5-1l0.8%2C10.1%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bc-7.3%2C1.2-12.8%2C1.8-16.6%2C1.8c-8.5%2C0-14.3-2.1-17.6-6.2c-3.3-4.1-4.9-12-4.9-23.6V99.5h-11.6V88.9h11.6V63.9h12.1v24.9h25.9V99.5z%22%2F%3E%0A%20%20%20%20%20%20%3Cpath%20class%3D%22st0%22%20d%3D%22M598.7%2C78.4V64.3h12.2v14.2H598.7z%20M598.7%2C171.4V88.9h12.2v82.5H598.7z%22%2F%3E%0A%20%20%20%20%20%20%3Cpath%20class%3D%22st0%22%20d%3D%22M663.8%2C87.2c3.6%2C0%2C9.7%2C0.7%2C18.3%2C2l3.9%2C0.5l-0.5%2C9.9c-8.7-1-15.1-1.5-19.2-1.5c-9.2%2C0-15.5%2C2.2-18.8%2C6.6%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bc-3.3%2C4.4-5%2C12.6-5%2C24.5c0%2C11.9%2C1.5%2C20.2%2C4.6%2C24.9c3.1%2C4.7%2C9.5%2C7%2C19.3%2C7l19.2-1.5l0.5%2C10.1c-10.1%2C1.5-17.7%2C2.3-22.7%2C2.3%26%2310%3B%26%239%3B%26%239%3B%26%239%3Bc-12.7%2C0-21.5-3.3-26.3-9.8c-4.8-6.5-7.3-17.5-7.3-33c0-15.5%2C2.6-26.4%2C7.8-32.6C643%2C90.4%2C651.7%2C87.2%2C663.8%2C87.2z%22%2F%3E%0A%20%20%20%20%3C%2Fg%3E%0A%20%20%20%20%3Cpath%20class%3D%22st0%22%20d%3D%22M236.6%2C123.5c0-19.8-12.3-37.2-30.8-43.9c0.8-4.2%2C1.2-8.4%2C1.2-12.7C207%2C30%2C177%2C0%2C140.2%2C0%26%2310%3B%26%239%3B%26%239%3BC118.6%2C0%2C98.6%2C10.3%2C86%2C27.7c-6.2-4.8-13.8-7.4-21.7-7.4c-19.6%2C0-35.5%2C15.9-35.5%2C35.5c0%2C4.3%2C0.8%2C8.5%2C2.2%2C12.4%26%2310%3B%26%239%3B%26%239%3BC12.6%2C74.8%2C0%2C92.5%2C0%2C112.2c0%2C19.9%2C12.4%2C37.3%2C30.9%2C44c-0.8%2C4.1-1.2%2C8.4-1.2%2C12.7c0%2C36.8%2C29.9%2C66.7%2C66.7%2C66.7%26%2310%3B%26%239%3B%26%239%3Bc21.6%2C0%2C41.6-10.4%2C54.1-27.8c6.2%2C4.9%2C13.8%2C7.6%2C21.7%2C7.6c19.6%2C0%2C35.5-15.9%2C35.5-35.5c0-4.3-0.8-8.5-2.2-12.4%26%2310%3B%26%239%3B%26%239%3BC223.9%2C160.9%2C236.6%2C143.2%2C236.6%2C123.5z%20M91.6%2C34.8c10.9-15.9%2C28.9-25.4%2C48.1-25.4c32.2%2C0%2C58.4%2C26.2%2C58.4%2C58.4%26%2310%3B%26%239%3B%26%239%3Bc0%2C3.9-0.4%2C7.7-1.1%2C11.5l-52.2%2C45.8L93%2C101.5L82.9%2C79.9L91.6%2C34.8z%20M65.4%2C29c6.2%2C0%2C12.1%2C2%2C17%2C5.7l-7.8%2C40.3l-35.5-8.4%26%2310%3B%26%239%3B%26%239%3Bc-1.1-3.1-1.7-6.3-1.7-9.7C37.4%2C41.6%2C49.9%2C29%2C65.4%2C29z%20M9.1%2C112.3c0-16.7%2C11-31.9%2C26.9-37.2L75%2C84.4l9.1%2C19.5l-49.8%2C45%26%2310%3B%26%239%3B%26%239%3BC19.2%2C143.1%2C9.1%2C128.6%2C9.1%2C112.3z%20M145.2%2C200.9c-10.9%2C16.1-29%2C25.6-48.4%2C25.6c-32.3%2C0-58.6-26.3-58.6-58.5c0-4%2C0.4-7.9%2C1.1-11.7%26%2310%3B%26%239%3B%26%239%3Bl50.9-46l52%2C23.7l11.5%2C22L145.2%2C200.9z%20M171.2%2C206.6c-6.1%2C0-12-2-16.9-5.8l7.7-40.2l35.4%2C8.3c1.1%2C3.1%2C1.7%2C6.3%2C1.7%2C9.7%26%2310%3B%26%239%3B%26%239%3BC199.2%2C194.1%2C186.6%2C206.6%2C171.2%2C206.6z%20M200.5%2C160.5l-39-9.1l-10.4-19.8l51-44.7c15.1%2C5.7%2C25.2%2C20.2%2C25.2%2C36.5%26%2310%3B%26%239%3B%26%239%3BC227.4%2C140.1%2C216.4%2C155.3%2C200.5%2C160.5z%22%2F%3E%0A%20%20%3C%2Fg%3E%0A%3C%2Fsvg%3E ------------- - *Returns:* `render` @@ -2280,11 +2154,11 @@ Uses a MomentJS formatting string to round milliseconds since epoch, and returns |=== |Argument |Type |Description -|_Unnamed_ +|_Unnamed_ Alias: `format` |`string` -|The MomentJS Format to use for bucketing. For example, `"YYYY-MM"` rounds to months. See https://momentjs.com/docs/#/displaying/. +|The MomentJS format to use for bucketing. For example, `"YYYY-MM"` rounds to months. See https://momentjs.com/docs/#/displaying/. |=== *Returns:* `number` @@ -2316,44 +2190,42 @@ Creates an object used for describing the properties of a series on a chart. Use |=== |Argument |Type |Description -|`label` -|`string` -|The name of the series to style. +|`bars` +|`number` +|The width of bars. |`color` |`string` |The line color. +|`fill` +|`number`, `boolean` +|Should we fill in the points? + +Default: `false` + +|`horizontalBars` +|`boolean` +|Sets the orientation of the bars in the chart to horizontal. + +|`label` +|`string` +|The name of the series to style. + |`lines` |`number` |The width of the line. -|`bars` -|`number` -|The width of bars. - |`points` |`number` |The size of points on line. -|`fill` -|`number`, `boolean` -|Should we fill in the points? - -Default: `false` - |`stack` |`number`, `null` |Specifies if the series should be stacked. The number is the stack ID. Series with the same stack ID are stacked together. - -|`horizontalBars` -|`boolean` -|Sets the orientation of the bars in the chart to horizontal. - -Default: `false` |=== -*Returns:* `seriesStyle` +*Returns:* `seriesStyle` [float] @@ -2368,25 +2240,25 @@ Creates a shape. |=== |Argument |Type |Description -|_Unnamed_ +|_Unnamed_ Alias: `shape` |`string` -|Pick a shape +|Pick a shape. -Default: `"square"` +Default: `square` -|`border` +|`border` -Alias `stroke` -|`number` +Alias: `stroke` +|`string` |An SVG color for the border outlining the shape. -|`borderWidth` +|`borderWidth` Alias: `strokeWidth` |`number` -|The thickness of the border +|The thickness of the border. Default: `0` @@ -2403,7 +2275,7 @@ Default: `"black"` Default: `false` |=== -*Returns:* shape +*Returns:* `shape` [float] @@ -2420,13 +2292,13 @@ Sorts a `datatable` by the specified column. |_Unnamed_ -Alias: `column` +Aliases: `by`, `column` |`string` |The column to sort by. When unspecified, the `datatable` is sorted by the first column. |`reverse` |`boolean` -|Reverse the sorting order? When unspecified, the `datatable` is sorted in ascending order. +|Reverses the sorting order. When unspecified, the `datatable` is sorted in ascending order. Default: `false` |=== @@ -2446,15 +2318,15 @@ Adds a column with the same static value in every row. See also <>. |=== |Argument |Type |Description -|_Unnamed_ *** +|_Unnamed_ Alias: `count` |`number` -|The number of rows to retrieve from the end of the datatable. +|The number of rows to retrieve from the end of the `datatable`. + +Default: `1` |=== *Returns:* `datatable` @@ -2590,29 +2463,29 @@ Creates a time filter for querying a source. |=== |Argument |Type |Description -|`column` +|`column` -Alias: `field`, `c` +Aliases: `c`, `field` |`string` |The column or field that you want to filter. Default: `"@timestamp"` -|`from` - -Alias: `f`, `start` +|`filterGroup` |`string` -|The beginning of the range, in ISO8601 or {es} `datemath` format +|The group name for the filter -|`to` +|`from` -Alias: `t`, `end` +Aliases: `f`, `start` |`string` -|The end of the range, in ISO8601 or {es} `datemath` format +|The beginning of the range, in ISO8601 or Elasticsearch `datemath` format -|`filterGroup` +|`to` + +Aliases: `end`, `t` |`string` -|The group name for the filter +|The end of the range, in ISO8601 or Elasticsearch `datemath` format |=== *Returns:* `filter` @@ -2630,13 +2503,13 @@ Configures a time filter control element. |=== |Argument |Type |Description -|`column` +|`column` -Alias: `field`, `c` +Aliases: `c`, `field` |`string` |The column or field that you want to filter. -Default: `"@timestamp"` +Default: `@timestamp` |`compact` |`boolean` @@ -2649,7 +2522,6 @@ Default: `true` |The group name for the filter. |=== - *Returns:* `render` @@ -2665,37 +2537,37 @@ Uses Timelion to extract one or more time series from many sources. |=== |Argument |Type |Description -|_Unnamed_ +|_Unnamed_ Aliases: `q`, `query` |`string` -|A Timelion query +|A Timelion query Default: `".es(*)"` -|`interval` -|`string` -|The bucket interval for the time series - -Default: `"auto"` - |`from` |`string` -|The {es} `datemath` string for the beginning of the time range. +|The Elasticsearch `datemath` string for the beginning of the time range. Default: `"now-1y"` -|`to` +|`interval` |`string` -|The {es} `datemath` string for the end of the time range. +|The bucket interval for the time series. -Default: `"now"` +Default: `"auto"` |`timezone` |`string` -|The timezone for the time range. See [Moment Timezone](https://momentjs.com/timezone/). +|The timezone for the time range. See https://momentjs.com/timezone/. Default: `"UTC"` + +|`to` +|`string` +|The Elasticsearch `datemath` string for the end of the time range. + +Default: `"now"` |=== *Returns:* `datatable` @@ -2713,16 +2585,15 @@ Explicitly casts the type of the _context_ from one type to the specified type. |=== |Argument |Type |Description -|_Unnamed_ *** +|_Unnamed_ † Alias: `type` |`string` -|A known type +|A known data type in the expression language. |=== *Returns:* Depends on your input and arguments - [float] [[u_fns]] == U @@ -2731,7 +2602,7 @@ Alias: `type` [[urlparam_fn]] === `urlparam` -Retrieves a URL parameter to use in an expression. The <> function always returns a `string`. For example, you can retrieve the value `"20"` from the parameter `myVar` from the URL `https://localhost:5601/app/canvas?myVar=20`. +Retrieves a URL parameter to use in an expression. The <> function always returns a `string`. For example, you can retrieve the value `"20"` from the parameter `myVar` from the URL `https://localhost:5601/app/canvas?myVar=20`. *Accepts:* `null` @@ -2739,9 +2610,9 @@ Retrieves a URL parameter to use in an expression. The <> function |=== |Argument |Type |Description -|_Unnamed_ *** +|_Unnamed_ *** -Aliases: `var`, `variable` +Aliases: `param`, `var`, `variable` |`string` |The URL hash parameter to retrieve. @@ -2753,4 +2624,3 @@ Default: `""` |=== *Returns:* `string` -