mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
ApiKeys: Fixes close('X') button layout issue (#27625)
* ApiKeys: Fixes add API key layout * ApiKeys: snapshot tests updated
This commit is contained in:
parent
31e2b7e7c8
commit
5a06ed431c
@ -13,14 +13,7 @@ import ApiKeysAddedModal from './ApiKeysAddedModal';
|
|||||||
import config from 'app/core/config';
|
import config from 'app/core/config';
|
||||||
import appEvents from 'app/core/app_events';
|
import appEvents from 'app/core/app_events';
|
||||||
import EmptyListCTA from 'app/core/components/EmptyListCTA/EmptyListCTA';
|
import EmptyListCTA from 'app/core/components/EmptyListCTA/EmptyListCTA';
|
||||||
import {
|
import { DeleteButton, EventsWithValidation, InlineFormLabel, LegacyForms, ValidationEvents, Icon } from '@grafana/ui';
|
||||||
DeleteButton,
|
|
||||||
EventsWithValidation,
|
|
||||||
InlineFormLabel,
|
|
||||||
LegacyForms,
|
|
||||||
ValidationEvents,
|
|
||||||
IconButton,
|
|
||||||
} from '@grafana/ui';
|
|
||||||
const { Input, Switch } = LegacyForms;
|
const { Input, Switch } = LegacyForms;
|
||||||
import { NavModel, dateTimeFormat, rangeUtil } from '@grafana/data';
|
import { NavModel, dateTimeFormat, rangeUtil } from '@grafana/data';
|
||||||
import { FilterInput } from 'app/core/components/FilterInput/FilterInput';
|
import { FilterInput } from 'app/core/components/FilterInput/FilterInput';
|
||||||
@ -182,10 +175,12 @@ export class ApiKeysPage extends PureComponent<Props, any> {
|
|||||||
|
|
||||||
return (
|
return (
|
||||||
<SlideDown in={isAdding}>
|
<SlideDown in={isAdding}>
|
||||||
<div className="cta-form">
|
<div className="gf-form-inline cta-form">
|
||||||
<IconButton name="times" className="cta-form__close btn btn-transparent" onClick={this.onToggleAdding} />
|
<button className="cta-form__close btn btn-transparent" onClick={this.onToggleAdding}>
|
||||||
<h5>Add API Key</h5>
|
<Icon name="times" />
|
||||||
|
</button>
|
||||||
<form className="gf-form-group" onSubmit={this.onAddApiKey}>
|
<form className="gf-form-group" onSubmit={this.onAddApiKey}>
|
||||||
|
<h5>Add API Key</h5>
|
||||||
<div className="gf-form-inline">
|
<div className="gf-form-inline">
|
||||||
<div className="gf-form max-width-21">
|
<div className="gf-form max-width-21">
|
||||||
<span className="gf-form-label">Key name</span>
|
<span className="gf-form-label">Key name</span>
|
||||||
|
@ -47,20 +47,23 @@ exports[`Render should render CTA if there are no API keys 1`] = `
|
|||||||
in={false}
|
in={false}
|
||||||
>
|
>
|
||||||
<div
|
<div
|
||||||
className="cta-form"
|
className="gf-form-inline cta-form"
|
||||||
>
|
>
|
||||||
<IconButton
|
<button
|
||||||
className="cta-form__close btn btn-transparent"
|
className="cta-form__close btn btn-transparent"
|
||||||
name="times"
|
|
||||||
onClick={[Function]}
|
onClick={[Function]}
|
||||||
/>
|
>
|
||||||
<h5>
|
<Icon
|
||||||
Add API Key
|
name="times"
|
||||||
</h5>
|
/>
|
||||||
|
</button>
|
||||||
<form
|
<form
|
||||||
className="gf-form-group"
|
className="gf-form-group"
|
||||||
onSubmit={[Function]}
|
onSubmit={[Function]}
|
||||||
>
|
>
|
||||||
|
<h5>
|
||||||
|
Add API Key
|
||||||
|
</h5>
|
||||||
<div
|
<div
|
||||||
className="gf-form-inline"
|
className="gf-form-inline"
|
||||||
>
|
>
|
||||||
|
Loading…
Reference in New Issue
Block a user