Skip to content

Commit 763f853

Browse files
committed
comments #2
1 parent fbcd8cd commit 763f853

File tree

5 files changed

+26
-33
lines changed

5 files changed

+26
-33
lines changed
Lines changed: 4 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -1,31 +1,4 @@
1-
.co-create-secret-form {
2-
.btn-file {
3-
position: relative;
4-
overflow: hidden;
5-
}
6-
7-
.btn-file input[type=file] {
8-
position: absolute;
9-
top: 0;
10-
right: 0;
11-
min-width: 100%;
12-
min-height: 100%;
13-
font-size: 100px;
14-
text-align: right;
15-
filter: alpha(opacity=0);
16-
opacity: 0;
17-
outline: none;
18-
background: white;
19-
cursor: inherit;
20-
display: block;
21-
}
22-
23-
.form-textarea {
24-
min-height: 300px;
25-
width: 100%;
26-
}
27-
28-
.help-block {
29-
margin-bottom: 10px;
30-
}
31-
}
1+
.co-create-secret-form__textarea {
2+
min-height: 300px;
3+
width: 100%;
4+
}

frontend/public/components/secrets/create-secret.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -293,7 +293,7 @@ class SSHAuthSubform extends React.Component<SSHAuthSubformProps, SSHAuthSubform
293293
<div>
294294
<FileInput onChange={this.onFileChange} />
295295
<p className="help-block">Upload your private SSH key file.</p>
296-
<textarea className="form-control form-textarea"
296+
<textarea className="form-control co-create-secret-form__textarea"
297297
id="ssh-privatekey"
298298
name="privateKey"
299299
onChange={this.changeData}
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
.co-btn-file {
2+
position: relative;
3+
overflow: hidden;
4+
input[type=file] {
5+
position: absolute;
6+
top: 0;
7+
right: 0;
8+
min-width: 100%;
9+
min-height: 100%;
10+
font-size: 100px;
11+
text-align: right;
12+
filter: alpha(opacity=0);
13+
opacity: 0;
14+
outline: none;
15+
background: white;
16+
cursor: inherit;
17+
display: block;
18+
}
19+
}

frontend/public/components/utils/file-input.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ export class FileInput extends React.Component<fileInputProps, fileInputState> {
2929
readOnly
3030
disabled />
3131
<span className="input-group-btn">
32-
<span className="btn btn-default btn-file">
32+
<span className="btn btn-default co-btn-file">
3333
Browse&hellip;
3434
<input type="file" onChange={this.onFileChange} className="form-control"/>
3535
</span>

frontend/public/style.scss

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@
3333

3434
// React Components
3535
@import "components/utils/copy-to-clipboard";
36+
@import "components/utils/file-input";
3637
@import "components/utils/label";
3738
@import "components/utils/number-spinner";
3839
@import "components/utils/status-box";

0 commit comments

Comments
 (0)