Skip to content

Commit 513b8ca

Browse files
committed
Now, buttons' text fields are dynamic and coming from props
1 parent 91194fd commit 513b8ca

File tree

1 file changed

+6
-10
lines changed

1 file changed

+6
-10
lines changed

src/components/chmod-checkbox/chmod-checkbox.tsx

Lines changed: 6 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -9,21 +9,17 @@ export class CHModCheckbox {
99
/**
1010
* The first name
1111
*/
12-
@Prop() first: string;
12+
@Prop() first: string = "READ";
1313

1414
/**
1515
* The middle name
1616
*/
17-
@Prop() middle: string;
17+
@Prop() middle: string = "WRITE";
1818

1919
/**
2020
* The last name
2121
*/
22-
@Prop() last: string;
23-
24-
// private getText(): string {
25-
// return format(this.first, this.middle, this.last);
26-
// }
22+
@Prop() last: string = "EXECUTE";
2723

2824
render() {
2925
return (
@@ -35,7 +31,7 @@ export class CHModCheckbox {
3531
<label htmlFor="read">
3632
<span></span>
3733
</label>
38-
<span class="content-text-style">READ</span>
34+
<span class="content-text-style">{this.first}</span>
3935
</div>
4036
</form>
4137
</div>
@@ -46,7 +42,7 @@ export class CHModCheckbox {
4642
<label htmlFor="write">
4743
<span></span>
4844
</label>
49-
<span class="content-text-style">WRITE</span>
45+
<span class="content-text-style">{this.middle}</span>
5046
</div>
5147
</form>
5248
</div>
@@ -57,7 +53,7 @@ export class CHModCheckbox {
5753
<label htmlFor="execute">
5854
<span></span>
5955
</label>
60-
<span class="content-text-style">EXECUTE</span>
56+
<span class="content-text-style">{this.last}</span>
6157
</div>
6258
</form>
6359
</div>

0 commit comments

Comments
 (0)