Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
O
OP72
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
template admin
OP72
Commits
1f46e160
Commit
1f46e160
authored
Jan 04, 2023
by
limingzhe
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix: debug
parent
a043bfbb
Changes
8
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
676 additions
and
144 deletions
+676
-144
OP72.meta
assets/OP72.meta
+15
-1
OP72.fire
assets/OP72/scene/OP72.fire
+223
-130
OP72.js
assets/OP72/scene/OP72.js
+348
-7
white.png
assets/OP72/texture/test/white.png
+0
-0
white.png.meta
assets/OP72/texture/test/white.png.meta
+36
-0
custom-hot-zone.component.ts
...c/app/common/custom-hot-zone/custom-hot-zone.component.ts
+10
-5
form.component.html
form/src/app/form/form.component.html
+32
-0
form.component.ts
form/src/app/form/form.component.ts
+12
-1
No files found.
assets/OP72.meta
View file @
1f46e160
{"ver":"1.1.2","uuid":"3394706f-015e-4b30-b3da-f1e260ff228d","isBundle":false,"bundleName":"","priority":1,"compressionType":{},"optimizeHotUpdate":{},"inlineSpriteFrames":{},"isRemoteBundle":{"ios":false,"android":false},"subMetas":{}}
{
\ No newline at end of file
"ver": "1.1.2",
"uuid": "3394706f-015e-4b30-b3da-f1e260ff228d",
"isBundle": false,
"bundleName": "",
"priority": 1,
"compressionType": {},
"optimizeHotUpdate": {},
"inlineSpriteFrames": {},
"isRemoteBundle": {
"ios": false,
"android": false
},
"subMetas": {}
}
\ No newline at end of file
assets/OP72/scene/OP72.fire
View file @
1f46e160
This diff is collapsed.
Click to expand it.
assets/OP72/scene/OP72.js
View file @
1f46e160
This diff is collapsed.
Click to expand it.
assets/OP72/texture/test/white.png
0 → 100644
View file @
1f46e160
1.8 KB
assets/OP72/texture/test/white.png.meta
0 → 100644
View file @
1f46e160
{
"ver": "2.3.5",
"uuid": "b703a63f-39e4-406c-abc4-511099f05da4",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 10,
"height": 10,
"platformSettings": {},
"subMetas": {
"white": {
"ver": "1.0.4",
"uuid": "3a26d24e-955a-4414-8603-c77f3d08a31a",
"rawTextureUuid": "b703a63f-39e4-406c-abc4-511099f05da4",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 10,
"height": 10,
"rawWidth": 10,
"rawHeight": 10,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
form/src/app/common/custom-hot-zone/custom-hot-zone.component.ts
View file @
1f46e160
...
@@ -198,7 +198,7 @@ export class CustomHotZoneComponent implements OnInit, OnDestroy, OnChanges {
...
@@ -198,7 +198,7 @@ export class CustomHotZoneComponent implements OnInit, OnDestroy, OnChanges {
onItemImgUploadSuccess
(
e
,
item
)
{
onItemImgUploadSuccess
(
e
,
item
)
{
item
.
pic_url
=
e
.
url
;
item
.
pic_url
=
e
.
url
;
this
.
loadHotZonePic
(
item
.
pic
,
e
.
url
);
this
.
loadHotZonePic
(
item
,
item
.
pic
,
e
.
url
);
this
.
refresh
();
this
.
refresh
();
}
}
...
@@ -418,7 +418,7 @@ export class CustomHotZoneComponent implements OnInit, OnDestroy, OnChanges {
...
@@ -418,7 +418,7 @@ export class CustomHotZoneComponent implements OnInit, OnDestroy, OnChanges {
console
.
log
(
'
picUrl:
'
,
picUrl
);
console
.
log
(
'
picUrl:
'
,
picUrl
);
if
(
picUrl
)
{
if
(
picUrl
)
{
this
.
loadHotZonePic
(
pic
,
picUrl
,
saveData
.
imgScale
);
this
.
loadHotZonePic
(
item
,
pic
,
picUrl
,
saveData
.
imgScale
);
}
}
}
}
...
@@ -1384,7 +1384,7 @@ export class CustomHotZoneComponent implements OnInit, OnDestroy, OnChanges {
...
@@ -1384,7 +1384,7 @@ export class CustomHotZoneComponent implements OnInit, OnDestroy, OnChanges {
if
(
data
.
type
==
'
pic
'
)
{
if
(
data
.
type
==
'
pic
'
)
{
let
picUrl
=
data
.
pic_url
;
let
picUrl
=
data
.
pic_url
;
if
(
picUrl
)
{
if
(
picUrl
)
{
this
.
loadHotZonePic
(
item
.
pic
,
picUrl
);
this
.
loadHotZonePic
(
item
,
item
.
pic
,
picUrl
);
}
}
}
}
...
@@ -1818,7 +1818,7 @@ export class CustomHotZoneComponent implements OnInit, OnDestroy, OnChanges {
...
@@ -1818,7 +1818,7 @@ export class CustomHotZoneComponent implements OnInit, OnDestroy, OnChanges {
console
.
log
(
"
item:
"
,
item
);
console
.
log
(
"
item:
"
,
item
);
}
}
private
loadHotZonePic
(
pic
:
HotZoneImg
,
url
,
scale
=
null
)
{
private
loadHotZonePic
(
item
,
pic
:
HotZoneImg
,
url
,
scale
=
null
)
{
let
baseLen
;
let
baseLen
;
if
(
this
.
hotZoneImgSize
)
{
if
(
this
.
hotZoneImgSize
)
{
...
@@ -1834,7 +1834,12 @@ export class CustomHotZoneComponent implements OnInit, OnDestroy, OnChanges {
...
@@ -1834,7 +1834,12 @@ export class CustomHotZoneComponent implements OnInit, OnDestroy, OnChanges {
}
}
}
}
pic
.
setScaleXY
(
scale
);
const
w
=
item
.
width
*
item
.
scaleX
;
const
h
=
item
.
height
*
item
.
scaleY
;
pic
.
setScaleXY
(
getMinScale
(
pic
,
w
,
h
));
// pic.setScaleXY(scale);
});
});
}
}
...
...
form/src/app/form/form.component.html
View file @
1f46e160
...
@@ -282,6 +282,38 @@
...
@@ -282,6 +282,38 @@
</div>
</div>
</div>
</div>
<div
style=
"margin-top: 30px;"
></div>
<h2>
涂色组设置:
</h2>
<div
style=
"padding: 10px; border: 2px solid #ccc; border-radius: 10px; width: 350px;"
>
<div
*
ngFor=
"let hzItem of item.hotZoneItemArr; let i = index"
>
<div
*
ngIf=
"hzItem.gIdx == '5'"
style=
"margin: 10px; display: flex; align-items: center;"
>
<div
style=
"width: 300px; height: 70px; border: 1px solid #ccc; border-radius: 10px; padding: 5px; "
>
<h3>
item-{{i+1}}
</h3>
<span>
服务端标记区域:
</span>
<a
nz-dropdown
[
nzDropdownMenu
]="
menu4
"
>
{{hzItem.drawItem ? 'draw-item-' + hzItem.drawItem : 'select drawItem'}}
<i
nz-icon
nzType=
"down"
></i>
</a>
<nz-dropdown-menu
#
menu4=
"nzDropdownMenu"
>
<ul
nz-menu
nzSelectable
>
<div
*
ngFor=
"let temp of item.hotZoneItemArr2; let j = index"
(
click
)="
saveDrawItem
(
hzItem
,
j
+
1
)"
>
<li
*
ngIf=
"temp.gIdx == '9' "
nz-menu-item
>
draw-item-{{j+1}}
</li>
</div>
</ul>
</nz-dropdown-menu>
</div>
</div>
</div>
</div>
<div
*
ngIf=
" item.typeArr && item.typeArr.length > 1"
style=
"margin-top: 30px;"
>
<div
*
ngIf=
" item.typeArr && item.typeArr.length > 1"
style=
"margin-top: 30px;"
>
...
...
form/src/app/form/form.component.ts
View file @
1f46e160
...
@@ -181,6 +181,13 @@ export class FormComponent implements OnInit, OnChanges, OnDestroy, AfterViewIni
...
@@ -181,6 +181,13 @@ export class FormComponent implements OnInit, OnChanges, OnDestroy, AfterViewIni
]
]
}
}
},
},
{
name
:
'
涂色区域
'
,
rect
:
true
,
isCopy
:
true
// multRect : true
},
]
]
audioTypeArr
=
[
audioTypeArr
=
[
...
@@ -271,6 +278,7 @@ export class FormComponent implements OnInit, OnChanges, OnDestroy, AfterViewIni
...
@@ -271,6 +278,7 @@ export class FormComponent implements OnInit, OnChanges, OnDestroy, AfterViewIni
'
1
'
:
{
gIdx
:
'
1
'
,
name
:
'
手写
'
},
'
1
'
:
{
gIdx
:
'
1
'
,
name
:
'
手写
'
},
'
2
'
:
{
gIdx
:
'
2
'
,
name
:
'
画圈
'
},
'
2
'
:
{
gIdx
:
'
2
'
,
name
:
'
画圈
'
},
'
4
'
:
{
gIdx
:
'
4
'
,
name
:
'
符号
'
},
'
4
'
:
{
gIdx
:
'
4
'
,
name
:
'
符号
'
},
'
5
'
:
{
gIdx
:
'
5
'
,
name
:
'
涂色
'
},
'
6
'
:
{
gIdx
:
'
6
'
,
name
:
'
书写
'
},
'
6
'
:
{
gIdx
:
'
6
'
,
name
:
'
书写
'
},
}
}
...
@@ -336,7 +344,10 @@ export class FormComponent implements OnInit, OnChanges, OnDestroy, AfterViewIni
...
@@ -336,7 +344,10 @@ export class FormComponent implements OnInit, OnChanges, OnDestroy, AfterViewIni
this
.
save
();
this
.
save
();
}
}
saveDrawItem
(
hzItem
,
itemId
)
{
hzItem
.
drawItem
=
itemId
;
this
.
save
();
}
addWrongAnswer
()
{
addWrongAnswer
()
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment