Skip to content

Commit

Permalink
Use textarea for ssh key in Machine Credentials
Browse files Browse the repository at this point in the history
Using textarea prevents lost of EOL chars and making input invalid
  • Loading branch information
ZitaNemeckova committed Apr 10, 2017
1 parent 96dc625 commit 2d3a0f1
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,10 @@ ManageIQ.angular.app.component('ansibleCredentialOptions', {
'{{ __(attr.label) }}',
'</label>',
'<div ng-switch="attr.type" class="text">',
// password
// password or ssh input (must be textarea to prevent EOL getting lost)
'<div ng-switch-when="password" class="col-md-8">',
'<input type="password" class="form-control" title="{{ __(attr.help_text) }}" ng-model="vm.model[name]">',
'<input ng-if="!attr.multiline" type="password" class="form-control" title="{{ __(attr.help_text) }}" ng-model="vm.model[name]">',
'<textarea ng-if="attr.multiline" class="form-control" title="{{ __(attr.help_text) }}" ng-model="vm.model[name]"></textarea>',
'</div>',
// select
'<div ng-switch-when="choice" class="col-md-8">',
Expand Down

0 comments on commit 2d3a0f1

Please sign in to comment.