From 751d35c396b521f7e822975d4d7e1118c6825d7c Mon Sep 17 00:00:00 2001 From: "grafana-delivery-bot[bot]" <132647405+grafana-delivery-bot[bot]@users.noreply.github.com> Date: Wed, 26 Jul 2023 08:41:46 -0500 Subject: [PATCH] [v9.5.x] Prometheus: Add present_over_time syntax highlighting (#72367) Prometheus: Add present_over_time syntax highlighting (#72283) add prometheus present_over_time syntax highlighting to color present_over_time keyword for prometheus (cherry picked from commit d96067985b3f4752bef2a2545c926a97c65393b6) Co-authored-by: stratomonitor --- public/app/plugins/datasource/prometheus/promql.ts | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/public/app/plugins/datasource/prometheus/promql.ts b/public/app/plugins/datasource/prometheus/promql.ts index 8b4f032989a..6baa26d4899 100644 --- a/public/app/plugins/datasource/prometheus/promql.ts +++ b/public/app/plugins/datasource/prometheus/promql.ts @@ -521,6 +521,12 @@ export const FUNCTIONS = [ detail: 'last_over_time(range-vector)', documentation: 'The most recent point value in specified interval.', }, + { + insertText: 'present_over_time', + label: 'present_over_time', + detail: 'present_over_time(range-vector)', + documentation: 'The value 1 for any series in the specified interval.', + }, ]; export const PROM_KEYWORDS = FUNCTIONS.map((keyword) => keyword.label);