A11y: Fix fastpass issues for share modal (#40386)

This commit is contained in:
Hugo Häggmark
2021-10-14 07:13:15 +02:00
committed by GitHub
parent b0414f66dc
commit a981ea22fb
5 changed files with 27 additions and 7 deletions

View File

@@ -1,6 +1,6 @@
import React, { FormEvent, PureComponent } from 'react';
import { RadioButtonGroup, Switch, Field, TextArea, ClipboardButton, Modal } from '@grafana/ui';
import { SelectableValue, AppEvents } from '@grafana/data';
import { ClipboardButton, Field, Modal, RadioButtonGroup, Switch, TextArea } from '@grafana/ui';
import { AppEvents, SelectableValue } from '@grafana/data';
import { DashboardModel, PanelModel } from 'app/features/dashboard/state';
import { appEvents } from 'app/core/core';
import { buildIframeHtml } from './utils';
@@ -91,10 +91,15 @@ export class ShareEmbed extends PureComponent<Props, State> {
</Field>
<Field
label="Embed HTML"
description="The HTML code below can be pasted and included in another web page. Unless anonymous access is enabled,
description="The HTML code below can be pasted and included in another web page. Unless anonymous access is enabled,
the user viewing that page need to be signed into Grafana for the graph to load."
>
<TextArea rows={5} value={iframeHtml} onChange={this.onIframeHtmlChange}></TextArea>
<TextArea
id="share-panel-embed-embed-html-textarea"
rows={5}
value={iframeHtml}
onChange={this.onIframeHtmlChange}
/>
</Field>
<Modal.ButtonRow>
<ClipboardButton variant="primary" getText={this.getIframeHtml} onClipboardCopy={this.onIframeHtmlCopy}>