UI/Custom empty state messages for transit and transform (#13090)
* customizes empty state messages for transit and transform * adds changelog * clarifies key name
This commit is contained in:
parent
12faa5227b
commit
7f67aa28bf
|
@ -0,0 +1,3 @@
|
|||
```release-note:improvement
|
||||
ui: customizes empty state messages for transit and transform
|
||||
```
|
|
@ -87,6 +87,7 @@ const SECRET_BACKENDS = {
|
|||
displayName: 'Transformation',
|
||||
navigateTree: false,
|
||||
listItemPartial: 'secret-list/transform-list-item',
|
||||
firstStep: 'create a transformation and a role',
|
||||
tabs: [
|
||||
{
|
||||
name: 'transformations',
|
||||
|
@ -136,6 +137,7 @@ const SECRET_BACKENDS = {
|
|||
navigateTree: false,
|
||||
editComponent: 'transit-edit',
|
||||
listItemPartial: 'secret-list/item',
|
||||
firstStep: 'create an encryption key',
|
||||
},
|
||||
};
|
||||
|
||||
|
|
|
@ -4,8 +4,8 @@ import { fragment } from 'ember-data-model-fragments/attributes';
|
|||
import fieldToAttrs, { expandAttributeMeta } from 'vault/utils/field-to-attrs';
|
||||
import { validator, buildValidations } from 'ember-cp-validations';
|
||||
|
||||
//identity will be managed separately and the inclusion
|
||||
//of the system backend is an implementation detail
|
||||
// identity will be managed separately and the inclusion
|
||||
// of the system backend is an implementation detail
|
||||
const LIST_EXCLUDED_BACKENDS = ['system', 'identity'];
|
||||
|
||||
const Validations = buildValidations({
|
||||
|
|
|
@ -68,7 +68,7 @@ export default Route.extend({
|
|||
if (noConnectionCapabilities) {
|
||||
return 'You cannot yet generate credentials. Ask your administrator if you think you should have access.';
|
||||
} else {
|
||||
return 'You can connect and external database to Vault. We recommend that you create a user for Vault rather than using the database root user.';
|
||||
return 'You can connect an external database to Vault. We recommend that you create a user for Vault rather than using the database root user.';
|
||||
}
|
||||
};
|
||||
controller.set('showEmptyState', showEmptyState);
|
||||
|
|
|
@ -113,6 +113,16 @@
|
|||
{{/if}}
|
||||
{{else}}
|
||||
{{#if (eq baseKey.id '')}}
|
||||
{{#if (and options.firstStep (not tab))}}
|
||||
<EmptyState
|
||||
@title="Get started with {{capitalize backendType}}"
|
||||
@message="To use {{backendType}}, you'll need to {{options.firstStep}}."
|
||||
>
|
||||
<SecretLink @mode="create" @secret="" @queryParams={{query-params initialKey=(or filter baseKey.id) itemType=tab}} @class="link">
|
||||
{{options.create}}
|
||||
</SecretLink>
|
||||
</EmptyState>
|
||||
{{else}}
|
||||
<EmptyState
|
||||
@title="No {{pluralize options.item}} in this backend"
|
||||
@message="Secrets in this backend will be listed here. Add a secret to get started."
|
||||
|
@ -121,6 +131,7 @@
|
|||
{{options.create}}
|
||||
</SecretLink>
|
||||
</EmptyState>
|
||||
{{/if}}
|
||||
{{else}}
|
||||
{{#if filterIsFolder}}
|
||||
<EmptyState
|
||||
|
|
Loading…
Reference in New Issue