Commit 81b8a486 authored by huoshizhe's avatar huoshizhe

feat: 音效、表单、屏幕适配完成

parent 6b9f8308
...@@ -69,7 +69,8 @@ const runSpawn = async function (){ ...@@ -69,7 +69,8 @@ const runSpawn = async function (){
let zippath = path.resolve(__dirname,"../dist", pkg.name); let zippath = path.resolve(__dirname,"../dist", pkg.name);
//压缩包的存放目录 //压缩包的存放目录
let date = new Date(); let date = new Date();
let zipname = pkg.name+"_"+date.Format("yyyyMMdd hh-mm-ss"); // let zipname = pkg.name+"_"+date.Format("yyyyMMdd hh-mm-ss");
let zipname = 'form';
let zipdir = path.resolve(__dirname,"../publish/"+zipname+".zip"); let zipdir = path.resolve(__dirname,"../publish/"+zipname+".zip");
clean(zipdir); //删除原有的包 clean(zipdir); //删除原有的包
......
<div class="model-content"> <div class="model-content">
<div class="border" style=" width: 520px;">
<span style="height: 30px; font-size: 18px;">已选字母:</span>
<div *ngFor="let letter of item.letterList; let i = index">
<div style="float: left; width: 60px;">
<span style="font-size: 50px;align-content: center;">{{letter}}</span>
<br>
<button style="color: red;" nz-button nzType="dashed" class="add-btn" (click)="removeLetter(i)">
X
</button>
</div>
</div>
<div style="float: none;clear: both;">&nbsp;</div>
</div>
<div class="border" style=" width: 520px;">
<span style="height: 30px; font-size: 18px;">可选字母:</span>
<br>
<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('E')" style="font-size: 50px; width: 50px;">E&nbsp;</a>
<a (click)="addLetter('R')" style="font-size: 50px; width: 50px;">R&nbsp;</a>
<a (click)="addLetter('T')" style="font-size: 50px; width: 50px;">T&nbsp;</a>
<a (click)="addLetter('Y')" style="font-size: 50px; width: 50px;">Y&nbsp;</a>
<a (click)="addLetter('U')" style="font-size: 50px; width: 50px;">U&nbsp;</a>
<a (click)="addLetter('I')" style="font-size: 50px; width: 50px;">I&nbsp;</a>
<a (click)="addLetter('O')" style="font-size: 50px; width: 50px;">O&nbsp;</a>
<a (click)="addLetter('P')" style="font-size: 50px; width: 50px;">P&nbsp;</a>
<br>
<a (click)="addLetter('A')" style="font-size: 50px; margin-left: 20px;">A&nbsp;</a>
<a (click)="addLetter('S')" style="font-size: 50px;">S&nbsp;</a>
<a (click)="addLetter('D')" style="font-size: 50px;">D&nbsp;</a>
<a (click)="addLetter('F')" style="font-size: 50px;">F&nbsp;</a>
<a (click)="addLetter('G')" style="font-size: 50px;">G&nbsp;</a>
<a (click)="addLetter('H')" style="font-size: 50px;">H&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>
<br>
<a (click)="addLetter('Z')" style="font-size: 50px; margin-left: 40px;">Z&nbsp;</a>
<a (click)="addLetter('X')" style="font-size: 50px;">X&nbsp;</a>
<a (click)="addLetter('C')" style="font-size: 50px;">C&nbsp;</a>
<a (click)="addLetter('V')" style="font-size: 50px;">V&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('M')" style="font-size: 50px;">M&nbsp;</a>
</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>
<br> <br>
......
...@@ -18,25 +18,10 @@ export class FormComponent implements OnInit, OnChanges, OnDestroy { ...@@ -18,25 +18,10 @@ export class FormComponent implements OnInit, OnChanges, OnDestroy {
} }
createShell() {
this.item.wordList.push({
word: '',
audio: '',
backWord: '',
backWordAudio: '',
});
this.save();
}
removeShell(idx) {
this.item.wordList.splice(idx, 1);
this.save();
}
ngOnInit() { ngOnInit() {
this.item = { this.item = {
wordList: [] letterList: []
}; };
// 获取存储的数据 // 获取存储的数据
...@@ -54,6 +39,14 @@ export class FormComponent implements OnInit, OnChanges, OnDestroy { ...@@ -54,6 +39,14 @@ export class FormComponent implements OnInit, OnChanges, OnDestroy {
}, this.saveKey); }, this.saveKey);
} }
addLetter(letter) {
this.item.letterList.push(letter);
}
removeLetter(idx) {
this.item.letterList.splice(idx, 1);
}
ngOnChanges() { ngOnChanges() {
} }
...@@ -84,16 +77,6 @@ export class FormComponent implements OnInit, OnChanges, OnDestroy { ...@@ -84,16 +77,6 @@ export class FormComponent implements OnInit, OnChanges, OnDestroy {
this.save(); this.save();
} }
onWordAudioUploadSuccess(e, idx) {
this.item.wordList[idx].audio = e.url;
this.save();
}
onBackWordAudioUploadSuccess(e, idx) {
this.item.wordList[idx].backWordAudio = e.url;
this.save();
}
/** /**
* 储存数据 * 储存数据
*/ */
......
{
"ver": "1.1.2",
"uuid": "e3a6dfce-a78b-45e1-aaba-502ad7d9eebc",
"isBundle": false,
"bundleName": "",
"priority": 1,
"compressionType": {},
"optimizeHotUpdate": {},
"inlineSpriteFrames": {},
"isRemoteBundle": {},
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "749ad49e-6dd6-4340-9582-e0d4ff3d9790",
"downloadMode": 0,
"duration": 0.536,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "697b6d98-8c8c-4377-b281-e552027bae2c",
"downloadMode": 0,
"duration": 0.512,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "4a6c1ace-6cb6-4605-96f1-bb973cbc70b1",
"downloadMode": 0,
"duration": 0.752,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "4c49cedc-16ef-42e0-be45-22a068eb4f7b",
"downloadMode": 0,
"duration": 0.632,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "321daa19-9e08-4fdb-8383-104ac3da0e7c",
"downloadMode": 0,
"duration": 0.632,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "a9f7e82b-85bc-4cd0-ad8b-18c11364e4dc",
"downloadMode": 0,
"duration": 0.752,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "c5e20e4a-b61a-4193-bfc1-0b9ddbb9c26c",
"downloadMode": 0,
"duration": 0.656,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "f6797b4f-af97-49ee-a91f-a673386e2eba",
"downloadMode": 0,
"duration": 0.536,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "d1fdb3cc-09db-49c1-b5ad-e7c5424225dc",
"downloadMode": 0,
"duration": 0.584,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "3dd88676-2229-45f5-b8d2-432264bccf43",
"downloadMode": 0,
"duration": 0.584,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "ea09147a-afb9-4f38-9290-b326ac1c8a6e",
"downloadMode": 0,
"duration": 0.512,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "7617def7-988f-4434-bc12-28a930671819",
"downloadMode": 0,
"duration": 0.704,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "33fb57e7-03d1-4c48-9777-bad307b35f8b",
"downloadMode": 0,
"duration": 0.632,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "c5794023-d6ee-4a59-acfc-500ce33d8604",
"downloadMode": 0,
"duration": 0.704,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "9ab449db-7ce6-4939-a991-f06c61e063a7",
"downloadMode": 0,
"duration": 0.68,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "e81f2129-fd31-4a59-a9c1-119f7afcdd2c",
"downloadMode": 0,
"duration": 0.536,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "a954ea39-ea23-4ad5-8a51-11fa99a77f14",
"downloadMode": 0,
"duration": 0.704,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "9de57423-97d9-435e-b85c-3ba6cd627bfd",
"downloadMode": 0,
"duration": 0.824,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "21e7bf6f-0702-4e8e-84e9-ffb24b8768c8",
"downloadMode": 0,
"duration": 0.776,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "2a47e8f9-45c3-4712-a4f0-2237e4cdc54c",
"downloadMode": 0,
"duration": 0.752,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "4ceab02f-5ba4-4396-9bbd-311120d8c47c",
"downloadMode": 0,
"duration": 0.704,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "70a36255-9d1e-4190-bbd0-b1aa92462cb8",
"downloadMode": 0,
"duration": 0.752,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "54147b60-f71b-433b-8307-5465f952c0cc",
"downloadMode": 0,
"duration": 0.704,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "9c5e7269-dc13-4b6c-b4fd-0d77d3b026c3",
"downloadMode": 0,
"duration": 0.776,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "11598a70-89c2-4392-ac2c-0d421fe14098",
"downloadMode": 0,
"duration": 0.656,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "e27a893b-3ab0-4284-9b97-72478c4d5cc4",
"downloadMode": 0,
"duration": 0.632,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "0b1b213c-91e5-4791-a7ed-1e4820b78a5a",
"downloadMode": 0,
"duration": 1.358367,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "1.1.2",
"uuid": "9535d2bf-bb9b-427e-a0c7-da09cc341786",
"isBundle": false,
"bundleName": "",
"priority": 1,
"compressionType": {},
"optimizeHotUpdate": {},
"inlineSpriteFrames": {},
"isRemoteBundle": {},
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "644233b2-8efb-4aaa-addb-94ec50a46aa3",
"downloadMode": 0,
"duration": 1.008,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "77d897ac-6118-4f78-b560-fb441965d2d4",
"downloadMode": 0,
"duration": 0.972,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "37a34770-608b-435d-a3f2-e07a8b754356",
"downloadMode": 0,
"duration": 1.188,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "767dca12-ab58-4146-939a-f711c28e53ff",
"downloadMode": 0,
"duration": 1.26,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "a689da9b-5bfe-4a14-b508-f8302f1ea066",
"downloadMode": 0,
"duration": 1.296,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "919702ed-d7e6-4382-844a-2a496fc62ba7",
"downloadMode": 0,
"duration": 1.404,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "8e320a13-3259-416a-9c85-1eaf67d34c88",
"downloadMode": 0,
"duration": 1.332,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "c323f318-8aa3-4479-9719-14d8785448d2",
"downloadMode": 0,
"duration": 0.972,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "a098be6f-6eab-4598-bab5-36e41b1ad813",
"downloadMode": 0,
"duration": 1.152,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "47b06ec0-ba1a-46dc-8b2c-a9d52516adef",
"downloadMode": 0,
"duration": 1.044,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "aee01f46-5879-471e-abce-9f9f03d2a3b8",
"downloadMode": 0,
"duration": 1.548,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "4454b9f4-2eee-45c1-a7f3-703c3014ea4a",
"downloadMode": 0,
"duration": 1.332,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "99579f70-7fbb-4b5a-aa38-ba40c57cac76",
"downloadMode": 0,
"duration": 1.404,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "2b85b24c-3027-44b7-b8d5-3d27ae6ad7d1",
"downloadMode": 0,
"duration": 1.368,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "d38e87a0-23c6-45f3-8a0c-7309d509f608",
"downloadMode": 0,
"duration": 1.584,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "3e2043b6-7434-4be3-a8cb-735a81b091c6",
"downloadMode": 0,
"duration": 1.44,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "a8e79b72-9039-426c-8ffe-71e1c48a7f71",
"downloadMode": 0,
"duration": 1.764,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "8280a669-6c1f-4818-8ecf-29e84f6f20de",
"downloadMode": 0,
"duration": 1.368,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "7789aecb-372a-4a22-9b63-d53cc7f5eab8",
"downloadMode": 0,
"duration": 1.476,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "daaec7f0-5c74-4f15-b443-9dda6114f187",
"downloadMode": 0,
"duration": 1.332,
"subMetas": {}
}
\ No newline at end of file
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
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