Commit 43083d30 authored by Lukas Burgey's avatar Lukas Burgey

Make state tooltips and descriptions consistent

parent a7db97a4
......@@ -39,51 +39,62 @@ export class StateComponent implements OnInit {
(state: DeploymentState) => {
switch (state.state) {
case 'not_deployed':
this.stateDescription = `The credentials are not deployed for the service ${ this.service.name }.`;
this.stateDescription = `Your credentials are not deployed for ${ this.service.name }.`;
this.buttonActive = false;
break;
case 'deployment_pending':
this.stateDescription = `Waiting for the deployment of the credentials to the site ${ this.service.site.name }.`;
this.stateDescription = `Waiting for the deployment of your credentials to ${ this.service.site.name }.`;
this.buttonActive = false;
break;
case 'removal_pending':
this.stateDescription = `Waiting for the removal of the credentials from the site ${ this.service.site.name }.`;
this.stateDescription = `Waiting for the removal of your credentials from ${ this.service.site.name }.`;
this.buttonActive = false;
break;
case 'deployed':
this.stateDescription = `The credentials are deployed for the service ${ this.service.name }. Click to see details.`;
this.buttonActive = true;
this.buttonColor = 'primary';
this.buttonText = 'View credentials';
this.buttonTooltip = this.buttonText;
this.buttonText = 'View Credentials';
this.buttonTooltip = 'View detailed information about the deployed credentials';
this.stateDescription = `
The credentials are deployed for this service ${ this.service.name }.
Click "${ this.buttonText }" see details on your deployed ssh keys and credentials.
`;
break;
case 'questionnaire':
this.stateDescription = `Site ${ this.service.site.name } needs more data to deploy the keys. Please click to submit the data.`;
this.buttonActive = true;
this.buttonColor = 'warn';
this.buttonText = 'Submit Data';
this.buttonTooltip = this.buttonText;
this.buttonTooltip = 'Submit missing data';
this.stateDescription = `
More data is needed to deploy your credentials.
Please click "${ this.buttonText }" to submit the missing data.
`;
break;
case 'failed':
this.stateDescription = `Site ${ this.service.site.name } failed to deploy the credentials.
The deployment will be retried. Click for details.`;
this.buttonActive = true;
this.buttonColor = 'warn';
this.buttonText = 'Submit Data';
this.buttonText = 'Show Error';
this.buttonTooltip = this.buttonText;
this.stateDescription = `
The deployment of your credentials failed, but will be tried again.
Please click "${ this.buttonText }" for more details concerning this error.
`;
break;
case 'rejected':
this.stateDescription = `Site ${ this.service.site.name } rejected the deployment of the credentials. Click for details.`;
this.buttonActive = true;
this.buttonColor = 'warn';
this.buttonText = 'Submit Data';
this.buttonText = 'Show message';
this.buttonTooltip = this.buttonText;
this.stateDescription = `
The deployment of your credentials was rejected.
Please click "${ this.buttonText }" to show more details.
`;
break;
default:
this.stateDescription = 'Access to this service was never requested.';
this.stateDescription = '';
this.buttonActive = false;
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment