| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167 |
- // Jest Snapshot v1, https://goo.gl/fbAQLP
- exports[`Render should render API keys table if there are any keys 1`] = `
- <Page
- navModel={
- Object {
- "main": Object {
- "text": "Configuration",
- },
- "node": Object {
- "text": "Api Keys",
- },
- }
- }
- >
- <PageContents
- isLoading={true}
- />
- </Page>
- `;
- exports[`Render should render CTA if there are no API keys 1`] = `
- <Page
- navModel={
- Object {
- "main": Object {
- "text": "Configuration",
- },
- "node": Object {
- "text": "Api Keys",
- },
- }
- }
- >
- <PageContents
- isLoading={false}
- >
- <EmptyListCTA
- buttonIcon="gicon gicon-apikeys"
- buttonLink="#"
- buttonTitle=" New API Key"
- onClick={[Function]}
- proTip="Remember you can provide view-only API access to other applications."
- title="You haven't added any API Keys yet."
- />
- <Component
- in={false}
- >
- <div
- className="cta-form"
- >
- <button
- className="cta-form__close btn btn-transparent"
- onClick={[Function]}
- >
- <i
- className="fa fa-close"
- />
- </button>
- <h5>
- Add API Key
- </h5>
- <form
- className="gf-form-group"
- onSubmit={[Function]}
- >
- <div
- className="gf-form-inline"
- >
- <div
- className="gf-form max-width-21"
- >
- <span
- className="gf-form-label"
- >
- Key name
- </span>
- <Input
- className="gf-form-input"
- onChange={[Function]}
- placeholder="Name"
- type="text"
- value=""
- />
- </div>
- <div
- className="gf-form"
- >
- <span
- className="gf-form-label"
- >
- Role
- </span>
- <span
- className="gf-form-select-wrapper"
- >
- <select
- className="gf-form-input gf-size-auto"
- onChange={[Function]}
- value="Viewer"
- >
- <option
- key="Viewer"
- label="Viewer"
- value="Viewer"
- >
- Viewer
- </option>
- <option
- key="Editor"
- label="Editor"
- value="Editor"
- >
- Editor
- </option>
- <option
- key="Admin"
- label="Admin"
- value="Admin"
- >
- Admin
- </option>
- </select>
- </span>
- </div>
- <div
- className="gf-form max-width-21"
- >
- <Component
- tooltip="The api key life duration. For example 1d if your key is going to last for one day. All the supported units are: s,m,h,d,w,M,y"
- >
- Time to live
- </Component>
- <Input
- className="gf-form-input"
- onChange={[Function]}
- placeholder="1d"
- type="text"
- validationEvents={
- Object {
- "onBlur": Array [
- Object {
- "errorMessage": "Not a valid duration",
- "rule": [Function],
- },
- ],
- }
- }
- value=""
- />
- </div>
- <div
- className="gf-form"
- >
- <button
- className="btn gf-form-btn btn-primary"
- >
- Add
- </button>
- </div>
- </div>
- </form>
- </div>
- </Component>
- </PageContents>
- </Page>
- `;
|