Commit a6346bad authored by huoshizhe's avatar huoshizhe

feat: 选择的字母按照《小星星》换行

parent b48f6f91
...@@ -12,8 +12,8 @@ ...@@ -12,8 +12,8 @@
</div> </div>
<div style="float: none;clear: both;">&nbsp;</div> <div style="float: none;clear: both;">&nbsp;</div>
</div> </div>
<div class="border" style=" width: 520px;"> <!-- <div class="border" style=" width: 520px;">
<span style="height: 30px; font-size: 18px;">可选字母:</span> <span style="height: 30px; font-size: 18px;">可选字母(点击下方字母选择):</span>
<br> <br>
<a (click)="addLetter('Q')" style="font-size: 50px; width: 50px;">Q&nbsp;</a> <a (click)="addLetter('Q')" style="font-size: 50px; width: 50px;">Q&nbsp;</a>
<a (click)="addLetter('W')" style="font-size: 50px; width: 50px;">W&nbsp;</a> <a (click)="addLetter('W')" style="font-size: 50px; width: 50px;">W&nbsp;</a>
...@@ -43,7 +43,43 @@ ...@@ -43,7 +43,43 @@
<a (click)="addLetter('B')" style="font-size: 50px;">B&nbsp;</a> <a (click)="addLetter('B')" style="font-size: 50px;">B&nbsp;</a>
<a (click)="addLetter('N')" style="font-size: 50px;">N&nbsp;</a> <a (click)="addLetter('N')" style="font-size: 50px;">N&nbsp;</a>
<a (click)="addLetter('M')" style="font-size: 50px;">M&nbsp;</a> <a (click)="addLetter('M')" style="font-size: 50px;">M&nbsp;</a>
<br>
</div> -->
<div class="border" style="width: 350px;">
<span style="height: 30px; font-size: 18px;">可选字母(点击下方字母选择):</span>
<br>
<a (click)="addLetter('A')" style="font-size: 50px;">A&nbsp;</a>
<a (click)="addLetter('B')" style="font-size: 50px;">B&nbsp;</a>
<a (click)="addLetter('C')" style="font-size: 50px;">C&nbsp;</a>
<a (click)="addLetter('D')" style="font-size: 50px;">D&nbsp;</a>
<a (click)="addLetter('E')" style="font-size: 50px;">E&nbsp;</a>
<a (click)="addLetter('F')" style="font-size: 50px;">F&nbsp;</a>
<a (click)="addLetter('G')" style="font-size: 50px;">G&nbsp;</a>
<br>
<a (click)="addLetter('H')" style="font-size: 50px;">H&nbsp;</a>
<a (click)="addLetter('I')" style="font-size: 50px;">I&nbsp;</a>
<a (click)="addLetter('J')" style="font-size: 50px;">J&nbsp;</a>
<a (click)="addLetter('K')" style="font-size: 50px;">K&nbsp;</a>
<a (click)="addLetter('L')" style="font-size: 50px;">L&nbsp;</a>
<a (click)="addLetter('M')" style="font-size: 50px;">M&nbsp;</a>
<a (click)="addLetter('N')" style="font-size: 50px;">N&nbsp;</a>
<br>
<a (click)="addLetter('O')" style="font-size: 50px;">O&nbsp;</a>
<a (click)="addLetter('P')" style="font-size: 50px;">P&nbsp;</a>
<a (click)="addLetter('Q')" style="font-size: 50px;">Q&nbsp;</a>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<a (click)="addLetter('R')" style="font-size: 50px;">R&nbsp;</a>
<a (click)="addLetter('S')" style="font-size: 50px;">S&nbsp;</a>
<a (click)="addLetter('T')" style="font-size: 50px;">T&nbsp;</a>
<br>
<a (click)="addLetter('U')" style="font-size: 50px;">U&nbsp;</a>
<a (click)="addLetter('V')" style="font-size: 50px;">V&nbsp;</a>
<a (click)="addLetter('W')" style="font-size: 50px;">W&nbsp;</a>
&nbsp;&nbsp;
<a (click)="addLetter('X')" style="font-size: 50px;">X&nbsp;</a>
<a (click)="addLetter('Y')" style="font-size: 50px;">Y&nbsp;</a>
<a (click)="addLetter('Z')" style="font-size: 50px;">Z&nbsp;</a>
<br>
</div> </div>
<!-- <div class="border" style=" width: 520px; height: 120px;"> <!-- <div class="border" style=" width: 520px; height: 120px;">
<span style="height: 30px; font-size: 18px;">单词音频:</span> <span style="height: 30px; font-size: 18px;">单词音频:</span>
......
...@@ -41,10 +41,12 @@ export class FormComponent implements OnInit, OnChanges, OnDestroy { ...@@ -41,10 +41,12 @@ export class FormComponent implements OnInit, OnChanges, OnDestroy {
addLetter(letter) { addLetter(letter) {
this.item.letterList.push(letter); this.item.letterList.push(letter);
this.save();
} }
removeLetter(idx) { removeLetter(idx) {
this.item.letterList.splice(idx, 1); this.item.letterList.splice(idx, 1);
this.save();
} }
ngOnChanges() { ngOnChanges() {
......
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