mirror of
https://github.com/grafana/grafana.git
synced 2025-07-31 16:42:36 +08:00

* fixes so we match the transformer based on name properly. * changed the signature on the FieldMatcher. * introduced a names option so you can filter in name specificly. * changed so the matcher UI uses the new options format. * moved the exported functions together. * changing editors a bit. * made the filter by name work with both regex and name filtering. * fixed failing tests and make sure we always parse regex the same way. * removed unused code. * simplified to make the existing field overrides still working. * fixed issue reported by hugo. * added tests for the name matcher. * added tests for filter by name. * added more tests. * generated new version of the packages docs. * fixed spelling error. * regenerated the docs.
50 lines
2.0 KiB
Markdown
50 lines
2.0 KiB
Markdown
+++
|
|
# -----------------------------------------------------------------------
|
|
# Do not edit this file. It is automatically generated by API Documenter.
|
|
# -----------------------------------------------------------------------
|
|
title = "DateTimeOptionsWithFormat"
|
|
keywords = ["grafana","documentation","sdk","@grafana/data"]
|
|
type = "docs"
|
|
+++
|
|
|
|
## DateTimeOptionsWithFormat interface
|
|
|
|
The type describing the options that can be passed to the [dateTimeFormat](./data/datetimeformat.md) helper function to control how the date and time value passed to the function is formatted.
|
|
|
|
<b>Signature</b>
|
|
|
|
```typescript
|
|
export interface DateTimeOptionsWithFormat extends DateTimeOptions
|
|
```
|
|
<b>Import</b>
|
|
|
|
```typescript
|
|
import { DateTimeOptionsWithFormat } from '@grafana/data';
|
|
```
|
|
<b>Properties</b>
|
|
|
|
| Property | Type | Description |
|
|
| --- | --- | --- |
|
|
| [defaultWithMS](#defaultwithms-property) | <code>boolean</code> | Set this value to <code>true</code> if you want to include milliseconds when formatting date and time values in the default [DEFAULT\_DATE\_TIME\_FORMAT](./data/default_date_time_format.md) format. |
|
|
| [format](#format-property) | <code>string</code> | Specify a [momentjs](https://momentjs.com/docs/#/displaying/format) format to use a custom formatting pattern of the date and time value. If no format is set, then [DEFAULT\_DATE\_TIME\_FORMAT](./data/default_date_time_format.md) is used. |
|
|
|
|
### defaultWithMS property
|
|
|
|
Set this value to `true` if you want to include milliseconds when formatting date and time values in the default [DEFAULT\_DATE\_TIME\_FORMAT](./data/default_date_time_format.md) format.
|
|
|
|
<b>Signature</b>
|
|
|
|
```typescript
|
|
defaultWithMS?: boolean;
|
|
```
|
|
|
|
### format property
|
|
|
|
Specify a [momentjs](https://momentjs.com/docs/#/displaying/format) format to use a custom formatting pattern of the date and time value. If no format is set, then [DEFAULT\_DATE\_TIME\_FORMAT](./data/default_date_time_format.md) is used.
|
|
|
|
<b>Signature</b>
|
|
|
|
```typescript
|
|
format?: string;
|
|
```
|