Commit 736ddd2d authored by LMZ's avatar LMZ

feat: 首次提交

parent cb1367da
No preview for this file type
...@@ -1778,6 +1778,11 @@ ...@@ -1778,6 +1778,11 @@
"through": ">=2.2.7 <3" "through": ">=2.2.7 <3"
} }
}, },
"abbrev": {
"version": "1.1.1",
"resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz",
"integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q=="
},
"accepts": { "accepts": {
"version": "1.3.7", "version": "1.3.7",
"resolved": "https://registry.npmjs.org/accepts/-/accepts-1.3.7.tgz", "resolved": "https://registry.npmjs.org/accepts/-/accepts-1.3.7.tgz",
...@@ -1900,6 +1905,11 @@ ...@@ -1900,6 +1905,11 @@
"integrity": "sha1-l6ERlkmyEa0zaR2fn0hqjsn74KM=", "integrity": "sha1-l6ERlkmyEa0zaR2fn0hqjsn74KM=",
"dev": true "dev": true
}, },
"amdefine": {
"version": "1.0.1",
"resolved": "https://registry.npmjs.org/amdefine/-/amdefine-1.0.1.tgz",
"integrity": "sha1-SlKCrBZHKek2Gbz9OtFR+BfOkfU="
},
"ansi-colors": { "ansi-colors": {
"version": "3.2.4", "version": "3.2.4",
"resolved": "https://registry.npmjs.org/ansi-colors/-/ansi-colors-3.2.4.tgz", "resolved": "https://registry.npmjs.org/ansi-colors/-/ansi-colors-3.2.4.tgz",
...@@ -1924,14 +1934,12 @@ ...@@ -1924,14 +1934,12 @@
"ansi-regex": { "ansi-regex": {
"version": "2.1.1", "version": "2.1.1",
"resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz", "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz",
"integrity": "sha1-w7M6te42DYbg5ijwRorn7yfWVN8=", "integrity": "sha1-w7M6te42DYbg5ijwRorn7yfWVN8="
"dev": true
}, },
"ansi-styles": { "ansi-styles": {
"version": "3.2.1", "version": "3.2.1",
"resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz",
"integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==",
"dev": true,
"requires": { "requires": {
"color-convert": "^1.9.0" "color-convert": "^1.9.0"
} }
...@@ -1969,8 +1977,16 @@ ...@@ -1969,8 +1977,16 @@
"aproba": { "aproba": {
"version": "1.2.0", "version": "1.2.0",
"resolved": "https://registry.npmjs.org/aproba/-/aproba-1.2.0.tgz", "resolved": "https://registry.npmjs.org/aproba/-/aproba-1.2.0.tgz",
"integrity": "sha512-Y9J6ZjXtoYh8RnXVCMOU/ttDmk1aBjunq9vO0ta5x85WDQiQfUF9sIPBITdbiiIVcBo03Hi3jMxigBtsddlXRw==", "integrity": "sha512-Y9J6ZjXtoYh8RnXVCMOU/ttDmk1aBjunq9vO0ta5x85WDQiQfUF9sIPBITdbiiIVcBo03Hi3jMxigBtsddlXRw=="
"dev": true },
"are-we-there-yet": {
"version": "1.1.5",
"resolved": "https://registry.npmjs.org/are-we-there-yet/-/are-we-there-yet-1.1.5.tgz",
"integrity": "sha512-5hYdAkZlcG8tOLujVDTgCT+uPX0VnpAH28gWsLfzpXYm7wP6mp5Q/gYyR7YQ0cKVJcXJnl3j2kpBan13PtQf6w==",
"requires": {
"delegates": "^1.0.0",
"readable-stream": "^2.0.6"
}
}, },
"arg": { "arg": {
"version": "4.1.3", "version": "4.1.3",
...@@ -2015,6 +2031,11 @@ ...@@ -2015,6 +2031,11 @@
"integrity": "sha1-45sJrqne+Gao8gbiiK9jkZuuOcQ=", "integrity": "sha1-45sJrqne+Gao8gbiiK9jkZuuOcQ=",
"dev": true "dev": true
}, },
"array-find-index": {
"version": "1.0.2",
"resolved": "https://registry.npmjs.org/array-find-index/-/array-find-index-1.0.2.tgz",
"integrity": "sha1-3wEKoSh+Fku9pvlyOwqWoexBh6E="
},
"array-flatten": { "array-flatten": {
"version": "2.1.2", "version": "2.1.2",
"resolved": "https://registry.npmjs.org/array-flatten/-/array-flatten-2.1.2.tgz", "resolved": "https://registry.npmjs.org/array-flatten/-/array-flatten-2.1.2.tgz",
...@@ -2064,7 +2085,6 @@ ...@@ -2064,7 +2085,6 @@
"version": "0.2.4", "version": "0.2.4",
"resolved": "https://registry.npmjs.org/asn1/-/asn1-0.2.4.tgz", "resolved": "https://registry.npmjs.org/asn1/-/asn1-0.2.4.tgz",
"integrity": "sha512-jxwzQpLQjSmWXgwaCZE9Nz+glAG01yF1QnWgbhGwHI5A6FRIEY6IVqtHhIepHqI7/kyEyQEagBC5mBEFlIYvdg==", "integrity": "sha512-jxwzQpLQjSmWXgwaCZE9Nz+glAG01yF1QnWgbhGwHI5A6FRIEY6IVqtHhIepHqI7/kyEyQEagBC5mBEFlIYvdg==",
"dev": true,
"requires": { "requires": {
"safer-buffer": "~2.1.0" "safer-buffer": "~2.1.0"
} }
...@@ -2118,8 +2138,7 @@ ...@@ -2118,8 +2138,7 @@
"assert-plus": { "assert-plus": {
"version": "1.0.0", "version": "1.0.0",
"resolved": "https://registry.npmjs.org/assert-plus/-/assert-plus-1.0.0.tgz", "resolved": "https://registry.npmjs.org/assert-plus/-/assert-plus-1.0.0.tgz",
"integrity": "sha1-8S4PPF13sLHN2RRpQuTpbB5N1SU=", "integrity": "sha1-8S4PPF13sLHN2RRpQuTpbB5N1SU="
"dev": true
}, },
"assign-symbols": { "assign-symbols": {
"version": "1.0.0", "version": "1.0.0",
...@@ -2153,6 +2172,11 @@ ...@@ -2153,6 +2172,11 @@
"integrity": "sha512-z/WhQ5FPySLdvREByI2vZiTWwCnF0moMJ1hK9YQwDTHKh6I7/uSckMetoRGb5UBZPC1z0jlw+n/XCgjeH7y1AQ==", "integrity": "sha512-z/WhQ5FPySLdvREByI2vZiTWwCnF0moMJ1hK9YQwDTHKh6I7/uSckMetoRGb5UBZPC1z0jlw+n/XCgjeH7y1AQ==",
"dev": true "dev": true
}, },
"async-foreach": {
"version": "0.1.3",
"resolved": "https://registry.npmjs.org/async-foreach/-/async-foreach-0.1.3.tgz",
"integrity": "sha1-NhIfhFwFeBct5Bmpfb6x0W7DRUI="
},
"async-limiter": { "async-limiter": {
"version": "1.0.1", "version": "1.0.1",
"resolved": "https://registry.npmjs.org/async-limiter/-/async-limiter-1.0.1.tgz", "resolved": "https://registry.npmjs.org/async-limiter/-/async-limiter-1.0.1.tgz",
...@@ -2162,8 +2186,7 @@ ...@@ -2162,8 +2186,7 @@
"asynckit": { "asynckit": {
"version": "0.4.0", "version": "0.4.0",
"resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz", "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz",
"integrity": "sha1-x57Zf380y48robyXkLzDZkdLS3k=", "integrity": "sha1-x57Zf380y48robyXkLzDZkdLS3k="
"dev": true
}, },
"atob": { "atob": {
"version": "2.1.2", "version": "2.1.2",
...@@ -2189,14 +2212,12 @@ ...@@ -2189,14 +2212,12 @@
"aws-sign2": { "aws-sign2": {
"version": "0.7.0", "version": "0.7.0",
"resolved": "https://registry.npmjs.org/aws-sign2/-/aws-sign2-0.7.0.tgz", "resolved": "https://registry.npmjs.org/aws-sign2/-/aws-sign2-0.7.0.tgz",
"integrity": "sha1-tG6JCTSpWR8tL2+G1+ap8bP+dqg=", "integrity": "sha1-tG6JCTSpWR8tL2+G1+ap8bP+dqg="
"dev": true
}, },
"aws4": { "aws4": {
"version": "1.10.0", "version": "1.10.0",
"resolved": "https://registry.npmjs.org/aws4/-/aws4-1.10.0.tgz", "resolved": "https://registry.npmjs.org/aws4/-/aws4-1.10.0.tgz",
"integrity": "sha512-3YDiu347mtVtjpyV3u5kVqQLP242c06zwDOgpeRnybmXlYYsLbtTrUBUm8i8srONt+FWobl5aibnU1030PeeuA==", "integrity": "sha512-3YDiu347mtVtjpyV3u5kVqQLP242c06zwDOgpeRnybmXlYYsLbtTrUBUm8i8srONt+FWobl5aibnU1030PeeuA=="
"dev": true
}, },
"axobject-query": { "axobject-query": {
"version": "2.0.2", "version": "2.0.2",
...@@ -2335,7 +2356,6 @@ ...@@ -2335,7 +2356,6 @@
"version": "1.0.2", "version": "1.0.2",
"resolved": "https://registry.npmjs.org/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.2.tgz", "resolved": "https://registry.npmjs.org/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.2.tgz",
"integrity": "sha1-pDAdOJtqQ/m2f/PKEaP2Y342Dp4=", "integrity": "sha1-pDAdOJtqQ/m2f/PKEaP2Y342Dp4=",
"dev": true,
"requires": { "requires": {
"tweetnacl": "^0.14.3" "tweetnacl": "^0.14.3"
} }
...@@ -2386,6 +2406,14 @@ ...@@ -2386,6 +2406,14 @@
"integrity": "sha512-gaqbzQPqOoamawKg0LGVd7SzLgXS+JH61oWprSLH+P+abTczqJbhTR8CmJ2u9/bUYNmHTGJx/UEmn6doAvvuig==", "integrity": "sha512-gaqbzQPqOoamawKg0LGVd7SzLgXS+JH61oWprSLH+P+abTczqJbhTR8CmJ2u9/bUYNmHTGJx/UEmn6doAvvuig==",
"dev": true "dev": true
}, },
"block-stream": {
"version": "0.0.9",
"resolved": "https://registry.npmjs.org/block-stream/-/block-stream-0.0.9.tgz",
"integrity": "sha1-E+v+d4oDIFz+A3UUgeu0szAMEmo=",
"requires": {
"inherits": "~2.0.0"
}
},
"blocking-proxy": { "blocking-proxy": {
"version": "1.0.1", "version": "1.0.1",
"resolved": "https://registry.npmjs.org/blocking-proxy/-/blocking-proxy-1.0.1.tgz", "resolved": "https://registry.npmjs.org/blocking-proxy/-/blocking-proxy-1.0.1.tgz",
...@@ -2806,8 +2834,23 @@ ...@@ -2806,8 +2834,23 @@
"camelcase": { "camelcase": {
"version": "5.3.1", "version": "5.3.1",
"resolved": "https://registry.npmjs.org/camelcase/-/camelcase-5.3.1.tgz", "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-5.3.1.tgz",
"integrity": "sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg==", "integrity": "sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg=="
"dev": true },
"camelcase-keys": {
"version": "2.1.0",
"resolved": "https://registry.npmjs.org/camelcase-keys/-/camelcase-keys-2.1.0.tgz",
"integrity": "sha1-MIvur/3ygRkFHvodkyITyRuPkuc=",
"requires": {
"camelcase": "^2.0.0",
"map-obj": "^1.0.0"
},
"dependencies": {
"camelcase": {
"version": "2.1.1",
"resolved": "https://registry.npmjs.org/camelcase/-/camelcase-2.1.1.tgz",
"integrity": "sha1-fB0W1nmhu+WcoCys7PsBHiAfWh8="
}
}
}, },
"caniuse-api": { "caniuse-api": {
"version": "3.0.0", "version": "3.0.0",
...@@ -2836,8 +2879,7 @@ ...@@ -2836,8 +2879,7 @@
"caseless": { "caseless": {
"version": "0.12.0", "version": "0.12.0",
"resolved": "https://registry.npmjs.org/caseless/-/caseless-0.12.0.tgz", "resolved": "https://registry.npmjs.org/caseless/-/caseless-0.12.0.tgz",
"integrity": "sha1-G2gcIf+EAzyCZUMJBolCDRhxUdw=", "integrity": "sha1-G2gcIf+EAzyCZUMJBolCDRhxUdw="
"dev": true
}, },
"chalk": { "chalk": {
"version": "2.4.2", "version": "2.4.2",
...@@ -3033,8 +3075,7 @@ ...@@ -3033,8 +3075,7 @@
"code-point-at": { "code-point-at": {
"version": "1.1.0", "version": "1.1.0",
"resolved": "https://registry.npmjs.org/code-point-at/-/code-point-at-1.1.0.tgz", "resolved": "https://registry.npmjs.org/code-point-at/-/code-point-at-1.1.0.tgz",
"integrity": "sha1-DQcLTQQ6W+ozovGkDi7bPZpMz3c=", "integrity": "sha1-DQcLTQQ6W+ozovGkDi7bPZpMz3c="
"dev": true
}, },
"codelyzer": { "codelyzer": {
"version": "5.2.2", "version": "5.2.2",
...@@ -3091,7 +3132,6 @@ ...@@ -3091,7 +3132,6 @@
"version": "1.9.3", "version": "1.9.3",
"resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz", "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz",
"integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==", "integrity": "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==",
"dev": true,
"requires": { "requires": {
"color-name": "1.1.3" "color-name": "1.1.3"
} }
...@@ -3099,8 +3139,7 @@ ...@@ -3099,8 +3139,7 @@
"color-name": { "color-name": {
"version": "1.1.3", "version": "1.1.3",
"resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz",
"integrity": "sha1-p9BVi9icQveV3UIyj3QIMcpTvCU=", "integrity": "sha1-p9BVi9icQveV3UIyj3QIMcpTvCU="
"dev": true
}, },
"color-string": { "color-string": {
"version": "1.5.3", "version": "1.5.3",
...@@ -3122,7 +3161,6 @@ ...@@ -3122,7 +3161,6 @@
"version": "1.0.8", "version": "1.0.8",
"resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz", "resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz",
"integrity": "sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==", "integrity": "sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==",
"dev": true,
"requires": { "requires": {
"delayed-stream": "~1.0.0" "delayed-stream": "~1.0.0"
} }
...@@ -3262,6 +3300,11 @@ ...@@ -3262,6 +3300,11 @@
"integrity": "sha512-ZMkYO/LkF17QvCPqM0gxw8yUzigAOZOSWSHg91FH6orS7vcEj5dVZTidN2fQ14yBSdg97RqhSNwLUXInd52OTA==", "integrity": "sha512-ZMkYO/LkF17QvCPqM0gxw8yUzigAOZOSWSHg91FH6orS7vcEj5dVZTidN2fQ14yBSdg97RqhSNwLUXInd52OTA==",
"dev": true "dev": true
}, },
"console-control-strings": {
"version": "1.1.0",
"resolved": "https://registry.npmjs.org/console-control-strings/-/console-control-strings-1.1.0.tgz",
"integrity": "sha1-PXz0Rk22RG6mRL9LOVB/mFEAjo4="
},
"constants-browserify": { "constants-browserify": {
"version": "1.0.0", "version": "1.0.0",
"resolved": "https://registry.npmjs.org/constants-browserify/-/constants-browserify-1.0.0.tgz", "resolved": "https://registry.npmjs.org/constants-browserify/-/constants-browserify-1.0.0.tgz",
...@@ -3755,6 +3798,14 @@ ...@@ -3755,6 +3798,14 @@
} }
} }
}, },
"currently-unhandled": {
"version": "0.4.1",
"resolved": "https://registry.npmjs.org/currently-unhandled/-/currently-unhandled-0.4.1.tgz",
"integrity": "sha1-mI3zP+qxke95mmE2nddsF635V+o=",
"requires": {
"array-find-index": "^1.0.1"
}
},
"custom-event": { "custom-event": {
"version": "1.0.1", "version": "1.0.1",
"resolved": "https://registry.npmjs.org/custom-event/-/custom-event-1.0.1.tgz", "resolved": "https://registry.npmjs.org/custom-event/-/custom-event-1.0.1.tgz",
...@@ -3777,7 +3828,6 @@ ...@@ -3777,7 +3828,6 @@
"version": "1.14.1", "version": "1.14.1",
"resolved": "https://registry.npmjs.org/dashdash/-/dashdash-1.14.1.tgz", "resolved": "https://registry.npmjs.org/dashdash/-/dashdash-1.14.1.tgz",
"integrity": "sha1-hTz6D3y+L+1d4gMmuN1YEDX24vA=", "integrity": "sha1-hTz6D3y+L+1d4gMmuN1YEDX24vA=",
"dev": true,
"requires": { "requires": {
"assert-plus": "^1.0.0" "assert-plus": "^1.0.0"
} }
...@@ -3827,8 +3877,7 @@ ...@@ -3827,8 +3877,7 @@
"decamelize": { "decamelize": {
"version": "1.2.0", "version": "1.2.0",
"resolved": "https://registry.npmjs.org/decamelize/-/decamelize-1.2.0.tgz", "resolved": "https://registry.npmjs.org/decamelize/-/decamelize-1.2.0.tgz",
"integrity": "sha1-9lNNFRSCabIDUue+4m9QH5oZEpA=", "integrity": "sha1-9lNNFRSCabIDUue+4m9QH5oZEpA="
"dev": true
}, },
"decode-uri-component": { "decode-uri-component": {
"version": "0.2.0", "version": "0.2.0",
...@@ -4006,8 +4055,12 @@ ...@@ -4006,8 +4055,12 @@
"delayed-stream": { "delayed-stream": {
"version": "1.0.0", "version": "1.0.0",
"resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz", "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz",
"integrity": "sha1-3zrhmayt+31ECqrgsp4icrJOxhk=", "integrity": "sha1-3zrhmayt+31ECqrgsp4icrJOxhk="
"dev": true },
"delegates": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/delegates/-/delegates-1.0.0.tgz",
"integrity": "sha1-hMbhWbgZBP3KWaDvRM2HDTElD5o="
}, },
"depd": { "depd": {
"version": "1.1.2", "version": "1.1.2",
...@@ -4211,7 +4264,6 @@ ...@@ -4211,7 +4264,6 @@
"version": "0.1.2", "version": "0.1.2",
"resolved": "https://registry.npmjs.org/ecc-jsbn/-/ecc-jsbn-0.1.2.tgz", "resolved": "https://registry.npmjs.org/ecc-jsbn/-/ecc-jsbn-0.1.2.tgz",
"integrity": "sha1-OoOpBOVDUyh4dMVkt1SThoSamMk=", "integrity": "sha1-OoOpBOVDUyh4dMVkt1SThoSamMk=",
"dev": true,
"requires": { "requires": {
"jsbn": "~0.1.0", "jsbn": "~0.1.0",
"safer-buffer": "^2.1.0" "safer-buffer": "^2.1.0"
...@@ -4458,7 +4510,6 @@ ...@@ -4458,7 +4510,6 @@
"version": "1.3.2", "version": "1.3.2",
"resolved": "https://registry.npmjs.org/error-ex/-/error-ex-1.3.2.tgz", "resolved": "https://registry.npmjs.org/error-ex/-/error-ex-1.3.2.tgz",
"integrity": "sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g==", "integrity": "sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g==",
"dev": true,
"requires": { "requires": {
"is-arrayish": "^0.2.1" "is-arrayish": "^0.2.1"
} }
...@@ -4520,8 +4571,7 @@ ...@@ -4520,8 +4571,7 @@
"escape-string-regexp": { "escape-string-regexp": {
"version": "1.0.5", "version": "1.0.5",
"resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz", "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz",
"integrity": "sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ=", "integrity": "sha1-G2HAViGQqN/2rjuyzwIAyhMLhtQ="
"dev": true
}, },
"escodegen": { "escodegen": {
"version": "1.14.3", "version": "1.14.3",
...@@ -4795,8 +4845,7 @@ ...@@ -4795,8 +4845,7 @@
"extsprintf": { "extsprintf": {
"version": "1.3.0", "version": "1.3.0",
"resolved": "https://registry.npmjs.org/extsprintf/-/extsprintf-1.3.0.tgz", "resolved": "https://registry.npmjs.org/extsprintf/-/extsprintf-1.3.0.tgz",
"integrity": "sha1-lpGEQOMEGnpBT4xS48V06zw+HgU=", "integrity": "sha1-lpGEQOMEGnpBT4xS48V06zw+HgU="
"dev": true
}, },
"fast-deep-equal": { "fast-deep-equal": {
"version": "2.0.1", "version": "2.0.1",
...@@ -4807,8 +4856,7 @@ ...@@ -4807,8 +4856,7 @@
"fast-json-stable-stringify": { "fast-json-stable-stringify": {
"version": "2.0.0", "version": "2.0.0",
"resolved": "https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.0.0.tgz", "resolved": "https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.0.0.tgz",
"integrity": "sha1-1RQsDK7msRifh9OnYREGT4bIu/I=", "integrity": "sha1-1RQsDK7msRifh9OnYREGT4bIu/I="
"dev": true
}, },
"fast-levenshtein": { "fast-levenshtein": {
"version": "2.0.6", "version": "2.0.6",
...@@ -5008,7 +5056,6 @@ ...@@ -5008,7 +5056,6 @@
"version": "3.0.0", "version": "3.0.0",
"resolved": "https://registry.npmjs.org/find-up/-/find-up-3.0.0.tgz", "resolved": "https://registry.npmjs.org/find-up/-/find-up-3.0.0.tgz",
"integrity": "sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg==", "integrity": "sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg==",
"dev": true,
"requires": { "requires": {
"locate-path": "^3.0.0" "locate-path": "^3.0.0"
} }
...@@ -5049,14 +5096,12 @@ ...@@ -5049,14 +5096,12 @@
"forever-agent": { "forever-agent": {
"version": "0.6.1", "version": "0.6.1",
"resolved": "https://registry.npmjs.org/forever-agent/-/forever-agent-0.6.1.tgz", "resolved": "https://registry.npmjs.org/forever-agent/-/forever-agent-0.6.1.tgz",
"integrity": "sha1-+8cfDEGt6zf5bFd60e1C2P2sypE=", "integrity": "sha1-+8cfDEGt6zf5bFd60e1C2P2sypE="
"dev": true
}, },
"form-data": { "form-data": {
"version": "2.3.3", "version": "2.3.3",
"resolved": "https://registry.npmjs.org/form-data/-/form-data-2.3.3.tgz", "resolved": "https://registry.npmjs.org/form-data/-/form-data-2.3.3.tgz",
"integrity": "sha512-1lLKB2Mu3aGP1Q/2eCOx0fNbRMe7XdwktwOruhfqqd0rIJWwN4Dh+E3hrPSlDCXnSR7UtZ1N38rVXm+6+MEhJQ==", "integrity": "sha512-1lLKB2Mu3aGP1Q/2eCOx0fNbRMe7XdwktwOruhfqqd0rIJWwN4Dh+E3hrPSlDCXnSR7UtZ1N38rVXm+6+MEhJQ==",
"dev": true,
"requires": { "requires": {
"asynckit": "^0.4.0", "asynckit": "^0.4.0",
"combined-stream": "^1.0.6", "combined-stream": "^1.0.6",
...@@ -5160,6 +5205,17 @@ ...@@ -5160,6 +5205,17 @@
"dev": true, "dev": true,
"optional": true "optional": true
}, },
"fstream": {
"version": "1.0.12",
"resolved": "https://registry.npmjs.org/fstream/-/fstream-1.0.12.tgz",
"integrity": "sha512-WvJ193OHa0GHPEL+AycEJgxvBEwyfRkN1vhjca23OaPVMCaLCXTd5qAu82AjTcgP1UJmytkOKb63Ypde7raDIg==",
"requires": {
"graceful-fs": "^4.1.2",
"inherits": "~2.0.0",
"mkdirp": ">=0.5 0",
"rimraf": "2"
}
},
"ftp": { "ftp": {
"version": "0.3.10", "version": "0.3.10",
"resolved": "https://registry.npmjs.org/ftp/-/ftp-0.3.10.tgz", "resolved": "https://registry.npmjs.org/ftp/-/ftp-0.3.10.tgz",
...@@ -5198,6 +5254,49 @@ ...@@ -5198,6 +5254,49 @@
"integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==", "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==",
"dev": true "dev": true
}, },
"gauge": {
"version": "2.7.4",
"resolved": "https://registry.npmjs.org/gauge/-/gauge-2.7.4.tgz",
"integrity": "sha1-LANAXHU4w51+s3sxcCLjJfsBi/c=",
"requires": {
"aproba": "^1.0.3",
"console-control-strings": "^1.0.0",
"has-unicode": "^2.0.0",
"object-assign": "^4.1.0",
"signal-exit": "^3.0.0",
"string-width": "^1.0.1",
"strip-ansi": "^3.0.1",
"wide-align": "^1.1.0"
},
"dependencies": {
"is-fullwidth-code-point": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz",
"integrity": "sha1-754xOG8DGn8NZDr4L95QxFfvAMs=",
"requires": {
"number-is-nan": "^1.0.0"
}
},
"string-width": {
"version": "1.0.2",
"resolved": "https://registry.npmjs.org/string-width/-/string-width-1.0.2.tgz",
"integrity": "sha1-EYvfW4zcUaKn5w0hHgfisLmxB9M=",
"requires": {
"code-point-at": "^1.0.0",
"is-fullwidth-code-point": "^1.0.0",
"strip-ansi": "^3.0.0"
}
}
}
},
"gaze": {
"version": "1.1.3",
"resolved": "https://registry.npmjs.org/gaze/-/gaze-1.1.3.tgz",
"integrity": "sha512-BRdNm8hbWzFzWHERTrejLqwHDfS4GibPoq5wjTPIoJHoBtKGPg3xAFfxmM+9ztbXelxcf2hwQcaz1PtmFeue8g==",
"requires": {
"globule": "^1.0.0"
}
},
"genfun": { "genfun": {
"version": "5.0.0", "version": "5.0.0",
"resolved": "https://registry.npmjs.org/genfun/-/genfun-5.0.0.tgz", "resolved": "https://registry.npmjs.org/genfun/-/genfun-5.0.0.tgz",
...@@ -5215,6 +5314,11 @@ ...@@ -5215,6 +5314,11 @@
"resolved": "https://registry.npmjs.org/get-ready/-/get-ready-1.0.0.tgz", "resolved": "https://registry.npmjs.org/get-ready/-/get-ready-1.0.0.tgz",
"integrity": "sha1-+RgX8emt7P6hOlYq38jeiDqzR4I=" "integrity": "sha1-+RgX8emt7P6hOlYq38jeiDqzR4I="
}, },
"get-stdin": {
"version": "4.0.1",
"resolved": "https://registry.npmjs.org/get-stdin/-/get-stdin-4.0.1.tgz",
"integrity": "sha1-uWjGsKBDhDJJAui/Gl3zJXmkUP4="
},
"get-stream": { "get-stream": {
"version": "4.1.0", "version": "4.1.0",
"resolved": "https://registry.npmjs.org/get-stream/-/get-stream-4.1.0.tgz", "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-4.1.0.tgz",
...@@ -5247,7 +5351,6 @@ ...@@ -5247,7 +5351,6 @@
"version": "0.1.7", "version": "0.1.7",
"resolved": "https://registry.npmjs.org/getpass/-/getpass-0.1.7.tgz", "resolved": "https://registry.npmjs.org/getpass/-/getpass-0.1.7.tgz",
"integrity": "sha1-Xv+OPmhNVprkyysSgmBOi6YhSfo=", "integrity": "sha1-Xv+OPmhNVprkyysSgmBOi6YhSfo=",
"dev": true,
"requires": { "requires": {
"assert-plus": "^1.0.0" "assert-plus": "^1.0.0"
} }
...@@ -5314,11 +5417,20 @@ ...@@ -5314,11 +5417,20 @@
} }
} }
}, },
"globule": {
"version": "1.3.2",
"resolved": "https://registry.npmjs.org/globule/-/globule-1.3.2.tgz",
"integrity": "sha512-7IDTQTIu2xzXkT+6mlluidnWo+BypnbSoEVVQCGfzqnl5Ik8d3e1d4wycb8Rj9tWW+Z39uPWsdlquqiqPCd/pA==",
"requires": {
"glob": "~7.1.1",
"lodash": "~4.17.10",
"minimatch": "~3.0.2"
}
},
"graceful-fs": { "graceful-fs": {
"version": "4.2.4", "version": "4.2.4",
"resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.4.tgz", "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.4.tgz",
"integrity": "sha512-WjKPNJF79dtJAVniUlGGWHYGz2jWxT6VhN/4m1NdkbZ2nOsEF+cI1Edgql5zCRhs/VsQYRvrXctxktVXZUkixw==", "integrity": "sha512-WjKPNJF79dtJAVniUlGGWHYGz2jWxT6VhN/4m1NdkbZ2nOsEF+cI1Edgql5zCRhs/VsQYRvrXctxktVXZUkixw=="
"dev": true
}, },
"handle-thing": { "handle-thing": {
"version": "2.0.1", "version": "2.0.1",
...@@ -5329,14 +5441,12 @@ ...@@ -5329,14 +5441,12 @@
"har-schema": { "har-schema": {
"version": "2.0.0", "version": "2.0.0",
"resolved": "https://registry.npmjs.org/har-schema/-/har-schema-2.0.0.tgz", "resolved": "https://registry.npmjs.org/har-schema/-/har-schema-2.0.0.tgz",
"integrity": "sha1-qUwiJOvKwEeCoNkDVSHyRzW37JI=", "integrity": "sha1-qUwiJOvKwEeCoNkDVSHyRzW37JI="
"dev": true
}, },
"har-validator": { "har-validator": {
"version": "5.1.5", "version": "5.1.5",
"resolved": "https://registry.npmjs.org/har-validator/-/har-validator-5.1.5.tgz", "resolved": "https://registry.npmjs.org/har-validator/-/har-validator-5.1.5.tgz",
"integrity": "sha512-nmT2T0lljbxdQZfspsno9hgrG3Uir6Ks5afism62poxqBM6sDnMEuPmzTq8XN0OEwqKLLdh1jQI3qyE66Nzb3w==", "integrity": "sha512-nmT2T0lljbxdQZfspsno9hgrG3Uir6Ks5afism62poxqBM6sDnMEuPmzTq8XN0OEwqKLLdh1jQI3qyE66Nzb3w==",
"dev": true,
"requires": { "requires": {
"ajv": "^6.12.3", "ajv": "^6.12.3",
"har-schema": "^2.0.0" "har-schema": "^2.0.0"
...@@ -5346,7 +5456,6 @@ ...@@ -5346,7 +5456,6 @@
"version": "6.12.3", "version": "6.12.3",
"resolved": "https://registry.npmjs.org/ajv/-/ajv-6.12.3.tgz", "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.12.3.tgz",
"integrity": "sha512-4K0cK3L1hsqk9xIb2z9vs/XU+PGJZ9PNpJRDS9YLzmNdX6jmVPfamLvTJr0aDAusnHyCHO6MjzlkAsgtqp9teA==", "integrity": "sha512-4K0cK3L1hsqk9xIb2z9vs/XU+PGJZ9PNpJRDS9YLzmNdX6jmVPfamLvTJr0aDAusnHyCHO6MjzlkAsgtqp9teA==",
"dev": true,
"requires": { "requires": {
"fast-deep-equal": "^3.1.1", "fast-deep-equal": "^3.1.1",
"fast-json-stable-stringify": "^2.0.0", "fast-json-stable-stringify": "^2.0.0",
...@@ -5357,8 +5466,7 @@ ...@@ -5357,8 +5466,7 @@
"fast-deep-equal": { "fast-deep-equal": {
"version": "3.1.3", "version": "3.1.3",
"resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz", "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz",
"integrity": "sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==", "integrity": "sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q=="
"dev": true
} }
} }
}, },
...@@ -5375,7 +5483,6 @@ ...@@ -5375,7 +5483,6 @@
"version": "2.0.0", "version": "2.0.0",
"resolved": "https://registry.npmjs.org/has-ansi/-/has-ansi-2.0.0.tgz", "resolved": "https://registry.npmjs.org/has-ansi/-/has-ansi-2.0.0.tgz",
"integrity": "sha1-NPUEnOHs3ysGSa8+8k5F7TVBbZE=", "integrity": "sha1-NPUEnOHs3ysGSa8+8k5F7TVBbZE=",
"dev": true,
"requires": { "requires": {
"ansi-regex": "^2.0.0" "ansi-regex": "^2.0.0"
} }
...@@ -5415,6 +5522,11 @@ ...@@ -5415,6 +5522,11 @@
"integrity": "sha512-PLcsoqu++dmEIZB+6totNFKq/7Do+Z0u4oT0zKOJNl3lYK6vGwwu2hjHs+68OEZbTjiUE9bgOABXbP/GvrS0Kg==", "integrity": "sha512-PLcsoqu++dmEIZB+6totNFKq/7Do+Z0u4oT0zKOJNl3lYK6vGwwu2hjHs+68OEZbTjiUE9bgOABXbP/GvrS0Kg==",
"dev": true "dev": true
}, },
"has-unicode": {
"version": "2.0.1",
"resolved": "https://registry.npmjs.org/has-unicode/-/has-unicode-2.0.1.tgz",
"integrity": "sha1-4Ob+aijPUROIVeCG0Wkedx3iqLk="
},
"has-value": { "has-value": {
"version": "1.0.0", "version": "1.0.0",
"resolved": "https://registry.npmjs.org/has-value/-/has-value-1.0.0.tgz", "resolved": "https://registry.npmjs.org/has-value/-/has-value-1.0.0.tgz",
...@@ -5673,7 +5785,6 @@ ...@@ -5673,7 +5785,6 @@
"version": "1.2.0", "version": "1.2.0",
"resolved": "https://registry.npmjs.org/http-signature/-/http-signature-1.2.0.tgz", "resolved": "https://registry.npmjs.org/http-signature/-/http-signature-1.2.0.tgz",
"integrity": "sha1-muzZJRFHcvPZW2WmCruPfBj7rOE=", "integrity": "sha1-muzZJRFHcvPZW2WmCruPfBj7rOE=",
"dev": true,
"requires": { "requires": {
"assert-plus": "^1.0.0", "assert-plus": "^1.0.0",
"jsprim": "^1.2.2", "jsprim": "^1.2.2",
...@@ -5805,6 +5916,11 @@ ...@@ -5805,6 +5916,11 @@
"integrity": "sha1-khi5srkoojixPcT7a21XbyMUU+o=", "integrity": "sha1-khi5srkoojixPcT7a21XbyMUU+o=",
"dev": true "dev": true
}, },
"in-publish": {
"version": "2.0.1",
"resolved": "https://registry.npmjs.org/in-publish/-/in-publish-2.0.1.tgz",
"integrity": "sha512-oDM0kUSNFC31ShNxHKUyfZKy8ZeXZBWMjMdZHKLOk13uvT27VTL/QzRGfRUcevJhpkZAvlhPYuXkF7eNWrtyxQ=="
},
"indent-string": { "indent-string": {
"version": "4.0.0", "version": "4.0.0",
"resolved": "https://registry.npmjs.org/indent-string/-/indent-string-4.0.0.tgz", "resolved": "https://registry.npmjs.org/indent-string/-/indent-string-4.0.0.tgz",
...@@ -6000,8 +6116,7 @@ ...@@ -6000,8 +6116,7 @@
"is-arrayish": { "is-arrayish": {
"version": "0.2.1", "version": "0.2.1",
"resolved": "https://registry.npmjs.org/is-arrayish/-/is-arrayish-0.2.1.tgz", "resolved": "https://registry.npmjs.org/is-arrayish/-/is-arrayish-0.2.1.tgz",
"integrity": "sha1-d8mYQFJ6qOyxqLppe4BkWnqSap0=", "integrity": "sha1-d8mYQFJ6qOyxqLppe4BkWnqSap0="
"dev": true
}, },
"is-binary-path": { "is-binary-path": {
"version": "2.1.0", "version": "2.1.0",
...@@ -6111,11 +6226,15 @@ ...@@ -6111,11 +6226,15 @@
"integrity": "sha1-qIwCU1eR8C7TfHahueqXc8gz+MI=", "integrity": "sha1-qIwCU1eR8C7TfHahueqXc8gz+MI=",
"dev": true "dev": true
}, },
"is-finite": {
"version": "1.1.0",
"resolved": "https://registry.npmjs.org/is-finite/-/is-finite-1.1.0.tgz",
"integrity": "sha512-cdyMtqX/BOqqNBBiKlIVkytNHm49MtMlYyn1zxzvJKWmFMlGzm+ry5BBfYyeY9YmNKbRSo/o7OX9w9ale0wg3w=="
},
"is-fullwidth-code-point": { "is-fullwidth-code-point": {
"version": "2.0.0", "version": "2.0.0",
"resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz", "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz",
"integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8=", "integrity": "sha1-o7MKXE8ZkYMWeqq5O+764937ZU8="
"dev": true
}, },
"is-glob": { "is-glob": {
"version": "4.0.1", "version": "4.0.1",
...@@ -6235,8 +6354,12 @@ ...@@ -6235,8 +6354,12 @@
"is-typedarray": { "is-typedarray": {
"version": "1.0.0", "version": "1.0.0",
"resolved": "https://registry.npmjs.org/is-typedarray/-/is-typedarray-1.0.0.tgz", "resolved": "https://registry.npmjs.org/is-typedarray/-/is-typedarray-1.0.0.tgz",
"integrity": "sha1-5HnICFjfDBsR3dppQPlgEfzaSpo=", "integrity": "sha1-5HnICFjfDBsR3dppQPlgEfzaSpo="
"dev": true },
"is-utf8": {
"version": "0.2.1",
"resolved": "https://registry.npmjs.org/is-utf8/-/is-utf8-0.2.1.tgz",
"integrity": "sha1-Sw2hRCEE0bM2NA6AeX6GXPOffXI="
}, },
"is-windows": { "is-windows": {
"version": "1.0.2", "version": "1.0.2",
...@@ -6270,8 +6393,7 @@ ...@@ -6270,8 +6393,7 @@
"isexe": { "isexe": {
"version": "2.0.0", "version": "2.0.0",
"resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz",
"integrity": "sha1-6PvzdNxVb/iUehDcsFctYz8s+hA=", "integrity": "sha1-6PvzdNxVb/iUehDcsFctYz8s+hA="
"dev": true
}, },
"isobject": { "isobject": {
"version": "3.0.1", "version": "3.0.1",
...@@ -6535,8 +6657,7 @@ ...@@ -6535,8 +6657,7 @@
"jsbn": { "jsbn": {
"version": "0.1.1", "version": "0.1.1",
"resolved": "https://registry.npmjs.org/jsbn/-/jsbn-0.1.1.tgz", "resolved": "https://registry.npmjs.org/jsbn/-/jsbn-0.1.1.tgz",
"integrity": "sha1-peZUwuWi3rXyAdls77yoDA7y9RM=", "integrity": "sha1-peZUwuWi3rXyAdls77yoDA7y9RM="
"dev": true
}, },
"jsesc": { "jsesc": {
"version": "2.5.2", "version": "2.5.2",
...@@ -6553,20 +6674,17 @@ ...@@ -6553,20 +6674,17 @@
"json-schema": { "json-schema": {
"version": "0.2.3", "version": "0.2.3",
"resolved": "https://registry.npmjs.org/json-schema/-/json-schema-0.2.3.tgz", "resolved": "https://registry.npmjs.org/json-schema/-/json-schema-0.2.3.tgz",
"integrity": "sha1-tIDIkuWaLwWVTOcnvT8qTogvnhM=", "integrity": "sha1-tIDIkuWaLwWVTOcnvT8qTogvnhM="
"dev": true
}, },
"json-schema-traverse": { "json-schema-traverse": {
"version": "0.4.1", "version": "0.4.1",
"resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz", "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz",
"integrity": "sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==", "integrity": "sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg=="
"dev": true
}, },
"json-stringify-safe": { "json-stringify-safe": {
"version": "5.0.1", "version": "5.0.1",
"resolved": "https://registry.npmjs.org/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz", "resolved": "https://registry.npmjs.org/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz",
"integrity": "sha1-Epai1Y/UXxmg9s4B1lcB4sc1tus=", "integrity": "sha1-Epai1Y/UXxmg9s4B1lcB4sc1tus="
"dev": true
}, },
"json3": { "json3": {
"version": "3.3.3", "version": "3.3.3",
...@@ -6602,7 +6720,6 @@ ...@@ -6602,7 +6720,6 @@
"version": "1.4.1", "version": "1.4.1",
"resolved": "https://registry.npmjs.org/jsprim/-/jsprim-1.4.1.tgz", "resolved": "https://registry.npmjs.org/jsprim/-/jsprim-1.4.1.tgz",
"integrity": "sha1-MT5mvB5cwG5Di8G3SZwuXFastqI=", "integrity": "sha1-MT5mvB5cwG5Di8G3SZwuXFastqI=",
"dev": true,
"requires": { "requires": {
"assert-plus": "1.0.0", "assert-plus": "1.0.0",
"extsprintf": "1.3.0", "extsprintf": "1.3.0",
...@@ -6799,6 +6916,41 @@ ...@@ -6799,6 +6916,41 @@
"immediate": "~3.0.5" "immediate": "~3.0.5"
} }
}, },
"load-json-file": {
"version": "1.1.0",
"resolved": "https://registry.npmjs.org/load-json-file/-/load-json-file-1.1.0.tgz",
"integrity": "sha1-lWkFcI1YtLq0wiYbBPWfMcmTdMA=",
"requires": {
"graceful-fs": "^4.1.2",
"parse-json": "^2.2.0",
"pify": "^2.0.0",
"pinkie-promise": "^2.0.0",
"strip-bom": "^2.0.0"
},
"dependencies": {
"parse-json": {
"version": "2.2.0",
"resolved": "https://registry.npmjs.org/parse-json/-/parse-json-2.2.0.tgz",
"integrity": "sha1-9ID0BDTvgHQfhGkJn43qGPVaTck=",
"requires": {
"error-ex": "^1.2.0"
}
},
"pify": {
"version": "2.3.0",
"resolved": "https://registry.npmjs.org/pify/-/pify-2.3.0.tgz",
"integrity": "sha1-7RQaasBDqEnqWISY59yosVMw6Qw="
},
"strip-bom": {
"version": "2.0.0",
"resolved": "https://registry.npmjs.org/strip-bom/-/strip-bom-2.0.0.tgz",
"integrity": "sha1-YhmoVhZSBJHzV4i9vxRHqZx+aw4=",
"requires": {
"is-utf8": "^0.2.0"
}
}
}
},
"loader-runner": { "loader-runner": {
"version": "2.4.0", "version": "2.4.0",
"resolved": "https://registry.npmjs.org/loader-runner/-/loader-runner-2.4.0.tgz", "resolved": "https://registry.npmjs.org/loader-runner/-/loader-runner-2.4.0.tgz",
...@@ -6820,7 +6972,6 @@ ...@@ -6820,7 +6972,6 @@
"version": "3.0.0", "version": "3.0.0",
"resolved": "https://registry.npmjs.org/locate-path/-/locate-path-3.0.0.tgz", "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-3.0.0.tgz",
"integrity": "sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A==", "integrity": "sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A==",
"dev": true,
"requires": { "requires": {
"p-locate": "^3.0.0", "p-locate": "^3.0.0",
"path-exists": "^3.0.0" "path-exists": "^3.0.0"
...@@ -6829,8 +6980,7 @@ ...@@ -6829,8 +6980,7 @@
"lodash": { "lodash": {
"version": "4.17.19", "version": "4.17.19",
"resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.19.tgz", "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.19.tgz",
"integrity": "sha512-JNvd8XER9GQX0v2qJgsaN/mzFCNA5BRe/j8JN9d+tWyGLSodKQHKFicdwNYzWwI3wjRnaKPsGj1XkBjx/F96DQ==", "integrity": "sha512-JNvd8XER9GQX0v2qJgsaN/mzFCNA5BRe/j8JN9d+tWyGLSodKQHKFicdwNYzWwI3wjRnaKPsGj1XkBjx/F96DQ=="
"dev": true
}, },
"lodash.clonedeep": { "lodash.clonedeep": {
"version": "4.5.0", "version": "4.5.0",
...@@ -6898,6 +7048,15 @@ ...@@ -6898,6 +7048,15 @@
"js-tokens": "^3.0.0 || ^4.0.0" "js-tokens": "^3.0.0 || ^4.0.0"
} }
}, },
"loud-rejection": {
"version": "1.6.0",
"resolved": "https://registry.npmjs.org/loud-rejection/-/loud-rejection-1.6.0.tgz",
"integrity": "sha1-W0b4AUft7leIcPCG0Eghz5mOVR8=",
"requires": {
"currently-unhandled": "^0.4.1",
"signal-exit": "^3.0.0"
}
},
"lru-cache": { "lru-cache": {
"version": "5.1.1", "version": "5.1.1",
"resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-5.1.1.tgz", "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-5.1.1.tgz",
...@@ -7024,6 +7183,11 @@ ...@@ -7024,6 +7183,11 @@
"integrity": "sha1-wyq9C9ZSXZsFFkW7TyasXcmKDb8=", "integrity": "sha1-wyq9C9ZSXZsFFkW7TyasXcmKDb8=",
"dev": true "dev": true
}, },
"map-obj": {
"version": "1.0.1",
"resolved": "https://registry.npmjs.org/map-obj/-/map-obj-1.0.1.tgz",
"integrity": "sha1-2TPOuSBdgr3PSIb2dCvcK03qFG0="
},
"map-visit": { "map-visit": {
"version": "1.0.0", "version": "1.0.0",
"resolved": "https://registry.npmjs.org/map-visit/-/map-visit-1.0.0.tgz", "resolved": "https://registry.npmjs.org/map-visit/-/map-visit-1.0.0.tgz",
...@@ -7077,6 +7241,23 @@ ...@@ -7077,6 +7241,23 @@
"readable-stream": "^2.0.1" "readable-stream": "^2.0.1"
} }
}, },
"meow": {
"version": "3.7.0",
"resolved": "https://registry.npmjs.org/meow/-/meow-3.7.0.tgz",
"integrity": "sha1-cstmi0JSKCkKu/qFaJJYcwioAfs=",
"requires": {
"camelcase-keys": "^2.0.0",
"decamelize": "^1.1.2",
"loud-rejection": "^1.0.0",
"map-obj": "^1.0.1",
"minimist": "^1.1.3",
"normalize-package-data": "^2.3.4",
"object-assign": "^4.0.1",
"read-pkg-up": "^1.0.1",
"redent": "^1.0.0",
"trim-newlines": "^1.0.0"
}
},
"merge-descriptors": { "merge-descriptors": {
"version": "1.0.1", "version": "1.0.1",
"resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.1.tgz", "resolved": "https://registry.npmjs.org/merge-descriptors/-/merge-descriptors-1.0.1.tgz",
...@@ -7255,14 +7436,12 @@ ...@@ -7255,14 +7436,12 @@
"mime-db": { "mime-db": {
"version": "1.44.0", "version": "1.44.0",
"resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.44.0.tgz", "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.44.0.tgz",
"integrity": "sha512-/NOTfLrsPBVeH7YtFPgsVWveuL+4SjjYxaQ1xtM1KMFj7HdxlBlxeyNLzhyJVx7r4rZGJAZ/6lkKCitSc/Nmpg==", "integrity": "sha512-/NOTfLrsPBVeH7YtFPgsVWveuL+4SjjYxaQ1xtM1KMFj7HdxlBlxeyNLzhyJVx7r4rZGJAZ/6lkKCitSc/Nmpg=="
"dev": true
}, },
"mime-types": { "mime-types": {
"version": "2.1.27", "version": "2.1.27",
"resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.27.tgz", "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.27.tgz",
"integrity": "sha512-JIhqnCasI9yD+SsmkquHBxTSEuZdQX5BuQnS2Vc7puQQQ+8yiP5AY5uWhpdv4YL4VM5c6iliiYWPgJ/nJQLp7w==", "integrity": "sha512-JIhqnCasI9yD+SsmkquHBxTSEuZdQX5BuQnS2Vc7puQQQ+8yiP5AY5uWhpdv4YL4VM5c6iliiYWPgJ/nJQLp7w==",
"dev": true,
"requires": { "requires": {
"mime-db": "1.44.0" "mime-db": "1.44.0"
} }
...@@ -7502,9 +7681,7 @@ ...@@ -7502,9 +7681,7 @@
"nan": { "nan": {
"version": "2.14.1", "version": "2.14.1",
"resolved": "https://registry.npmjs.org/nan/-/nan-2.14.1.tgz", "resolved": "https://registry.npmjs.org/nan/-/nan-2.14.1.tgz",
"integrity": "sha512-isWHgVjnFjh2x2yuJ/tj3JbwoHu3UC2dX5G/88Cm24yB6YopVgxvBObDY7n5xW6ExmFhJpSEQqFPvq9zaXc8Jw==", "integrity": "sha512-isWHgVjnFjh2x2yuJ/tj3JbwoHu3UC2dX5G/88Cm24yB6YopVgxvBObDY7n5xW6ExmFhJpSEQqFPvq9zaXc8Jw=="
"dev": true,
"optional": true
}, },
"nanomatch": { "nanomatch": {
"version": "1.2.13", "version": "1.2.13",
...@@ -7597,6 +7774,42 @@ ...@@ -7597,6 +7774,42 @@
"integrity": "sha512-7ASaDa3pD+lJ3WvXFsxekJQelBKRpne+GOVbLbtHYdd7pFspyeuJHnWfLplGf3SwKGbfs/aYl5V/JCIaHVUKKQ==", "integrity": "sha512-7ASaDa3pD+lJ3WvXFsxekJQelBKRpne+GOVbLbtHYdd7pFspyeuJHnWfLplGf3SwKGbfs/aYl5V/JCIaHVUKKQ==",
"dev": true "dev": true
}, },
"node-gyp": {
"version": "3.8.0",
"resolved": "https://registry.npmjs.org/node-gyp/-/node-gyp-3.8.0.tgz",
"integrity": "sha512-3g8lYefrRRzvGeSowdJKAKyks8oUpLEd/DyPV4eMhVlhJ0aNaZqIrNUIPuEWWTAoPqyFkfGrM67MC69baqn6vA==",
"requires": {
"fstream": "^1.0.0",
"glob": "^7.0.3",
"graceful-fs": "^4.1.2",
"mkdirp": "^0.5.0",
"nopt": "2 || 3",
"npmlog": "0 || 1 || 2 || 3 || 4",
"osenv": "0",
"request": "^2.87.0",
"rimraf": "2",
"semver": "~5.3.0",
"tar": "^2.0.0",
"which": "1"
},
"dependencies": {
"semver": {
"version": "5.3.0",
"resolved": "https://registry.npmjs.org/semver/-/semver-5.3.0.tgz",
"integrity": "sha1-myzl094C0XxgEq0yaqa00M9U+U8="
},
"tar": {
"version": "2.2.2",
"resolved": "https://registry.npmjs.org/tar/-/tar-2.2.2.tgz",
"integrity": "sha512-FCEhQ/4rE1zYv9rYXJw/msRqsnmlje5jHP6huWeBZ704jUTy02c5AZyWujpMR1ax6mVw9NyJMfuK2CMDWVIfgA==",
"requires": {
"block-stream": "*",
"fstream": "^1.0.12",
"inherits": "2"
}
}
}
},
"node-libs-browser": { "node-libs-browser": {
"version": "2.2.1", "version": "2.2.1",
"resolved": "https://registry.npmjs.org/node-libs-browser/-/node-libs-browser-2.2.1.tgz", "resolved": "https://registry.npmjs.org/node-libs-browser/-/node-libs-browser-2.2.1.tgz",
...@@ -7642,11 +7855,89 @@ ...@@ -7642,11 +7855,89 @@
"integrity": "sha512-gsO4vjEdQaTusZAEebUWp2a5d7dF5DYoIpDG7WySnk7BuZDW+GPpHXoXXuYawRBr/9t5q54tirPz79kFIWg4dA==", "integrity": "sha512-gsO4vjEdQaTusZAEebUWp2a5d7dF5DYoIpDG7WySnk7BuZDW+GPpHXoXXuYawRBr/9t5q54tirPz79kFIWg4dA==",
"dev": true "dev": true
}, },
"node-sass": {
"version": "4.14.1",
"resolved": "https://registry.npmjs.org/node-sass/-/node-sass-4.14.1.tgz",
"integrity": "sha512-sjCuOlvGyCJS40R8BscF5vhVlQjNN069NtQ1gSxyK1u9iqvn6tf7O1R4GNowVZfiZUCRt5MmMs1xd+4V/7Yr0g==",
"requires": {
"async-foreach": "^0.1.3",
"chalk": "^1.1.1",
"cross-spawn": "^3.0.0",
"gaze": "^1.0.0",
"get-stdin": "^4.0.1",
"glob": "^7.0.3",
"in-publish": "^2.0.0",
"lodash": "^4.17.15",
"meow": "^3.7.0",
"mkdirp": "^0.5.1",
"nan": "^2.13.2",
"node-gyp": "^3.8.0",
"npmlog": "^4.0.0",
"request": "^2.88.0",
"sass-graph": "2.2.5",
"stdout-stream": "^1.4.0",
"true-case-path": "^1.0.2"
},
"dependencies": {
"ansi-styles": {
"version": "2.2.1",
"resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-2.2.1.tgz",
"integrity": "sha1-tDLdM1i2NM914eRmQ2gkBTPB3b4="
},
"chalk": {
"version": "1.1.3",
"resolved": "https://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz",
"integrity": "sha1-qBFcVeSnAv5NFQq9OHKCKn4J/Jg=",
"requires": {
"ansi-styles": "^2.2.1",
"escape-string-regexp": "^1.0.2",
"has-ansi": "^2.0.0",
"strip-ansi": "^3.0.0",
"supports-color": "^2.0.0"
}
},
"cross-spawn": {
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-3.0.1.tgz",
"integrity": "sha1-ElYDfsufDF9549bvE14wdwGEuYI=",
"requires": {
"lru-cache": "^4.0.1",
"which": "^1.2.9"
}
},
"lru-cache": {
"version": "4.1.5",
"resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-4.1.5.tgz",
"integrity": "sha512-sWZlbEP2OsHNkXrMl5GYk/jKk70MBng6UU4YI/qGDYbgf6YbP4EvmqISbXCoJiRKs+1bSpFHVgQxvJ17F2li5g==",
"requires": {
"pseudomap": "^1.0.2",
"yallist": "^2.1.2"
}
},
"supports-color": {
"version": "2.0.0",
"resolved": "https://registry.npmjs.org/supports-color/-/supports-color-2.0.0.tgz",
"integrity": "sha1-U10EXOa2Nj+kARcIRimZXp3zJMc="
},
"yallist": {
"version": "2.1.2",
"resolved": "https://registry.npmjs.org/yallist/-/yallist-2.1.2.tgz",
"integrity": "sha1-HBH5IY8HYImkfdUS+TxmmaaoHVI="
}
}
},
"nopt": {
"version": "3.0.6",
"resolved": "https://registry.npmjs.org/nopt/-/nopt-3.0.6.tgz",
"integrity": "sha1-xkZdvwirzU2zWTF/eaxopkayj/k=",
"requires": {
"abbrev": "1"
}
},
"normalize-package-data": { "normalize-package-data": {
"version": "2.5.0", "version": "2.5.0",
"resolved": "https://registry.npmjs.org/normalize-package-data/-/normalize-package-data-2.5.0.tgz", "resolved": "https://registry.npmjs.org/normalize-package-data/-/normalize-package-data-2.5.0.tgz",
"integrity": "sha512-/5CMN3T0R4XTj4DcGaexo+roZSdSFW/0AOOTROrjxzCG1wrWXEsGbRKevjlIL+ZDE4sZlJr5ED4YW0yqmkK+eA==", "integrity": "sha512-/5CMN3T0R4XTj4DcGaexo+roZSdSFW/0AOOTROrjxzCG1wrWXEsGbRKevjlIL+ZDE4sZlJr5ED4YW0yqmkK+eA==",
"dev": true,
"requires": { "requires": {
"hosted-git-info": "^2.1.4", "hosted-git-info": "^2.1.4",
"resolve": "^1.10.0", "resolve": "^1.10.0",
...@@ -7657,8 +7948,7 @@ ...@@ -7657,8 +7948,7 @@
"hosted-git-info": { "hosted-git-info": {
"version": "2.8.8", "version": "2.8.8",
"resolved": "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-2.8.8.tgz", "resolved": "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-2.8.8.tgz",
"integrity": "sha512-f/wzC2QaWBs7t9IYqB4T3sR1xviIViXJRJTWBlx2Gf3g0Xi5vI7Yy4koXQ1c9OYDGHN9sBy1DQ2AB8fqZBWhUg==", "integrity": "sha512-f/wzC2QaWBs7t9IYqB4T3sR1xviIViXJRJTWBlx2Gf3g0Xi5vI7Yy4koXQ1c9OYDGHN9sBy1DQ2AB8fqZBWhUg=="
"dev": true
} }
} }
}, },
...@@ -7769,6 +8059,17 @@ ...@@ -7769,6 +8059,17 @@
"path-key": "^2.0.0" "path-key": "^2.0.0"
} }
}, },
"npmlog": {
"version": "4.1.2",
"resolved": "https://registry.npmjs.org/npmlog/-/npmlog-4.1.2.tgz",
"integrity": "sha512-2uUqazuKlTaSI/dC8AzicUck7+IrEaOnN/e0jd3Xtt1KcGpwx30v50mL7oPyr/h9bL3E4aZccVwpwP+5W9Vjkg==",
"requires": {
"are-we-there-yet": "~1.1.2",
"console-control-strings": "~1.1.0",
"gauge": "~2.7.3",
"set-blocking": "~2.0.0"
}
},
"nth-check": { "nth-check": {
"version": "1.0.2", "version": "1.0.2",
"resolved": "https://registry.npmjs.org/nth-check/-/nth-check-1.0.2.tgz", "resolved": "https://registry.npmjs.org/nth-check/-/nth-check-1.0.2.tgz",
...@@ -7787,14 +8088,12 @@ ...@@ -7787,14 +8088,12 @@
"number-is-nan": { "number-is-nan": {
"version": "1.0.1", "version": "1.0.1",
"resolved": "https://registry.npmjs.org/number-is-nan/-/number-is-nan-1.0.1.tgz", "resolved": "https://registry.npmjs.org/number-is-nan/-/number-is-nan-1.0.1.tgz",
"integrity": "sha1-CXtgK1NCKlIsGvuHkDGDNpQaAR0=", "integrity": "sha1-CXtgK1NCKlIsGvuHkDGDNpQaAR0="
"dev": true
}, },
"oauth-sign": { "oauth-sign": {
"version": "0.9.0", "version": "0.9.0",
"resolved": "https://registry.npmjs.org/oauth-sign/-/oauth-sign-0.9.0.tgz", "resolved": "https://registry.npmjs.org/oauth-sign/-/oauth-sign-0.9.0.tgz",
"integrity": "sha512-fexhUFFPTGV8ybAtSIGbV6gOkSv8UtRbDBnAyLQw4QPKkgNlsH2ByPGtMUqdWkos6YCRmAqViwgZrJc/mRDzZQ==", "integrity": "sha512-fexhUFFPTGV8ybAtSIGbV6gOkSv8UtRbDBnAyLQw4QPKkgNlsH2ByPGtMUqdWkos6YCRmAqViwgZrJc/mRDzZQ=="
"dev": true
}, },
"object-assign": { "object-assign": {
"version": "4.1.1", "version": "4.1.1",
...@@ -8057,8 +8356,7 @@ ...@@ -8057,8 +8356,7 @@
"os-homedir": { "os-homedir": {
"version": "1.0.2", "version": "1.0.2",
"resolved": "https://registry.npmjs.org/os-homedir/-/os-homedir-1.0.2.tgz", "resolved": "https://registry.npmjs.org/os-homedir/-/os-homedir-1.0.2.tgz",
"integrity": "sha1-/7xJiDNuDoM94MFox+8VISGqf7M=", "integrity": "sha1-/7xJiDNuDoM94MFox+8VISGqf7M="
"dev": true
}, },
"os-locale": { "os-locale": {
"version": "3.1.0", "version": "3.1.0",
...@@ -8083,14 +8381,12 @@ ...@@ -8083,14 +8381,12 @@
"os-tmpdir": { "os-tmpdir": {
"version": "1.0.2", "version": "1.0.2",
"resolved": "https://registry.npmjs.org/os-tmpdir/-/os-tmpdir-1.0.2.tgz", "resolved": "https://registry.npmjs.org/os-tmpdir/-/os-tmpdir-1.0.2.tgz",
"integrity": "sha1-u+Z0BseaqFxc/sdm/lc0VV36EnQ=", "integrity": "sha1-u+Z0BseaqFxc/sdm/lc0VV36EnQ="
"dev": true
}, },
"osenv": { "osenv": {
"version": "0.1.5", "version": "0.1.5",
"resolved": "https://registry.npmjs.org/osenv/-/osenv-0.1.5.tgz", "resolved": "https://registry.npmjs.org/osenv/-/osenv-0.1.5.tgz",
"integrity": "sha512-0CWcCECdMVc2Rw3U5w9ZjqX6ga6ubk1xDVKxtBQPK7wis/0F2r9T6k4ydGYhecl7YUBxBVxhL5oisPsNxAPe2g==", "integrity": "sha512-0CWcCECdMVc2Rw3U5w9ZjqX6ga6ubk1xDVKxtBQPK7wis/0F2r9T6k4ydGYhecl7YUBxBVxhL5oisPsNxAPe2g==",
"dev": true,
"requires": { "requires": {
"os-homedir": "^1.0.0", "os-homedir": "^1.0.0",
"os-tmpdir": "^1.0.0" "os-tmpdir": "^1.0.0"
...@@ -8126,7 +8422,6 @@ ...@@ -8126,7 +8422,6 @@
"version": "2.3.0", "version": "2.3.0",
"resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz", "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-2.3.0.tgz",
"integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==", "integrity": "sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==",
"dev": true,
"requires": { "requires": {
"p-try": "^2.0.0" "p-try": "^2.0.0"
} }
...@@ -8135,7 +8430,6 @@ ...@@ -8135,7 +8430,6 @@
"version": "3.0.0", "version": "3.0.0",
"resolved": "https://registry.npmjs.org/p-locate/-/p-locate-3.0.0.tgz", "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-3.0.0.tgz",
"integrity": "sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ==", "integrity": "sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ==",
"dev": true,
"requires": { "requires": {
"p-limit": "^2.0.0" "p-limit": "^2.0.0"
} }
...@@ -8161,8 +8455,7 @@ ...@@ -8161,8 +8455,7 @@
"p-try": { "p-try": {
"version": "2.2.0", "version": "2.2.0",
"resolved": "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz", "resolved": "https://registry.npmjs.org/p-try/-/p-try-2.2.0.tgz",
"integrity": "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==", "integrity": "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ=="
"dev": true
}, },
"pac-proxy-agent": { "pac-proxy-agent": {
"version": "3.0.1", "version": "3.0.1",
...@@ -8374,8 +8667,7 @@ ...@@ -8374,8 +8667,7 @@
"path-exists": { "path-exists": {
"version": "3.0.0", "version": "3.0.0",
"resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz", "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz",
"integrity": "sha1-zg6+ql94yxiSXqfYENe1mwEP1RU=", "integrity": "sha1-zg6+ql94yxiSXqfYENe1mwEP1RU="
"dev": true
}, },
"path-is-absolute": { "path-is-absolute": {
"version": "1.0.1", "version": "1.0.1",
...@@ -8397,8 +8689,7 @@ ...@@ -8397,8 +8689,7 @@
"path-parse": { "path-parse": {
"version": "1.0.6", "version": "1.0.6",
"resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.6.tgz", "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.6.tgz",
"integrity": "sha512-GSmOT2EbHrINBf9SR7CDELwlJ8AENk3Qn7OikK4nFYAu3Ote2+JYNVvkpAEQm3/TLNEJFD/xZJjzyxg3KBWOzw==", "integrity": "sha512-GSmOT2EbHrINBf9SR7CDELwlJ8AENk3Qn7OikK4nFYAu3Ote2+JYNVvkpAEQm3/TLNEJFD/xZJjzyxg3KBWOzw=="
"dev": true
}, },
"path-to-regexp": { "path-to-regexp": {
"version": "0.1.7", "version": "0.1.7",
...@@ -8452,8 +8743,7 @@ ...@@ -8452,8 +8743,7 @@
"performance-now": { "performance-now": {
"version": "2.1.0", "version": "2.1.0",
"resolved": "https://registry.npmjs.org/performance-now/-/performance-now-2.1.0.tgz", "resolved": "https://registry.npmjs.org/performance-now/-/performance-now-2.1.0.tgz",
"integrity": "sha1-Ywn04OX6kT7BxpMHrjZLSzd8nns=", "integrity": "sha1-Ywn04OX6kT7BxpMHrjZLSzd8nns="
"dev": true
}, },
"picomatch": { "picomatch": {
"version": "2.2.2", "version": "2.2.2",
...@@ -8470,14 +8760,12 @@ ...@@ -8470,14 +8760,12 @@
"pinkie": { "pinkie": {
"version": "2.0.4", "version": "2.0.4",
"resolved": "https://registry.npmjs.org/pinkie/-/pinkie-2.0.4.tgz", "resolved": "https://registry.npmjs.org/pinkie/-/pinkie-2.0.4.tgz",
"integrity": "sha1-clVrgM+g1IqXToDnckjoDtT3+HA=", "integrity": "sha1-clVrgM+g1IqXToDnckjoDtT3+HA="
"dev": true
}, },
"pinkie-promise": { "pinkie-promise": {
"version": "2.0.1", "version": "2.0.1",
"resolved": "https://registry.npmjs.org/pinkie-promise/-/pinkie-promise-2.0.1.tgz", "resolved": "https://registry.npmjs.org/pinkie-promise/-/pinkie-promise-2.0.1.tgz",
"integrity": "sha1-ITXW36ejWMBprJsXh3YogihFD/o=", "integrity": "sha1-ITXW36ejWMBprJsXh3YogihFD/o=",
"dev": true,
"requires": { "requires": {
"pinkie": "^2.0.0" "pinkie": "^2.0.0"
} }
...@@ -9359,14 +9647,12 @@ ...@@ -9359,14 +9647,12 @@
"pseudomap": { "pseudomap": {
"version": "1.0.2", "version": "1.0.2",
"resolved": "https://registry.npmjs.org/pseudomap/-/pseudomap-1.0.2.tgz", "resolved": "https://registry.npmjs.org/pseudomap/-/pseudomap-1.0.2.tgz",
"integrity": "sha1-8FKijacOYYkX7wqKw0wa5aaChrM=", "integrity": "sha1-8FKijacOYYkX7wqKw0wa5aaChrM="
"dev": true
}, },
"psl": { "psl": {
"version": "1.8.0", "version": "1.8.0",
"resolved": "https://registry.npmjs.org/psl/-/psl-1.8.0.tgz", "resolved": "https://registry.npmjs.org/psl/-/psl-1.8.0.tgz",
"integrity": "sha512-RIdOzyoavK+hA18OGGWDqUTsCLhtA7IcZ/6NCs4fFJaHBDab+pDDmDIByWFRQJq2Cd7r1OoQxBGKOaztq+hjIQ==", "integrity": "sha512-RIdOzyoavK+hA18OGGWDqUTsCLhtA7IcZ/6NCs4fFJaHBDab+pDDmDIByWFRQJq2Cd7r1OoQxBGKOaztq+hjIQ=="
"dev": true
}, },
"public-encrypt": { "public-encrypt": {
"version": "4.0.3", "version": "4.0.3",
...@@ -9425,8 +9711,7 @@ ...@@ -9425,8 +9711,7 @@
"punycode": { "punycode": {
"version": "2.1.1", "version": "2.1.1",
"resolved": "https://registry.npmjs.org/punycode/-/punycode-2.1.1.tgz", "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.1.1.tgz",
"integrity": "sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A==", "integrity": "sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A=="
"dev": true
}, },
"q": { "q": {
"version": "1.5.1", "version": "1.5.1",
...@@ -9591,6 +9876,61 @@ ...@@ -9591,6 +9876,61 @@
"util-promisify": "^2.1.0" "util-promisify": "^2.1.0"
} }
}, },
"read-pkg": {
"version": "1.1.0",
"resolved": "https://registry.npmjs.org/read-pkg/-/read-pkg-1.1.0.tgz",
"integrity": "sha1-9f+qXs0pyzHAR0vKfXVra7KePyg=",
"requires": {
"load-json-file": "^1.0.0",
"normalize-package-data": "^2.3.2",
"path-type": "^1.0.0"
},
"dependencies": {
"path-type": {
"version": "1.1.0",
"resolved": "https://registry.npmjs.org/path-type/-/path-type-1.1.0.tgz",
"integrity": "sha1-WcRPfuSR2nBNpBXaWkBwuk+P5EE=",
"requires": {
"graceful-fs": "^4.1.2",
"pify": "^2.0.0",
"pinkie-promise": "^2.0.0"
}
},
"pify": {
"version": "2.3.0",
"resolved": "https://registry.npmjs.org/pify/-/pify-2.3.0.tgz",
"integrity": "sha1-7RQaasBDqEnqWISY59yosVMw6Qw="
}
}
},
"read-pkg-up": {
"version": "1.0.1",
"resolved": "https://registry.npmjs.org/read-pkg-up/-/read-pkg-up-1.0.1.tgz",
"integrity": "sha1-nWPBMnbAZZGNV/ACpX9AobZD+wI=",
"requires": {
"find-up": "^1.0.0",
"read-pkg": "^1.0.0"
},
"dependencies": {
"find-up": {
"version": "1.1.2",
"resolved": "https://registry.npmjs.org/find-up/-/find-up-1.1.2.tgz",
"integrity": "sha1-ay6YIrGizgpgq2TWEOzK1TyyTQ8=",
"requires": {
"path-exists": "^2.0.0",
"pinkie-promise": "^2.0.0"
}
},
"path-exists": {
"version": "2.1.0",
"resolved": "https://registry.npmjs.org/path-exists/-/path-exists-2.1.0.tgz",
"integrity": "sha1-D+tsZPD8UY2adU3V77YscCJ2H0s=",
"requires": {
"pinkie-promise": "^2.0.0"
}
}
}
},
"readable-stream": { "readable-stream": {
"version": "2.3.7", "version": "2.3.7",
"resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.7.tgz", "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.7.tgz",
...@@ -9626,6 +9966,25 @@ ...@@ -9626,6 +9966,25 @@
"picomatch": "^2.2.1" "picomatch": "^2.2.1"
} }
}, },
"redent": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/redent/-/redent-1.0.0.tgz",
"integrity": "sha1-z5Fqsf1fHxbfsggi3W7H9zDCr94=",
"requires": {
"indent-string": "^2.1.0",
"strip-indent": "^1.0.1"
},
"dependencies": {
"indent-string": {
"version": "2.1.0",
"resolved": "https://registry.npmjs.org/indent-string/-/indent-string-2.1.0.tgz",
"integrity": "sha1-ji1INIdCEhtKghi3oTfppSBJ3IA=",
"requires": {
"repeating": "^2.0.0"
}
}
}
},
"reflect-metadata": { "reflect-metadata": {
"version": "0.1.13", "version": "0.1.13",
"resolved": "https://registry.npmjs.org/reflect-metadata/-/reflect-metadata-0.1.13.tgz", "resolved": "https://registry.npmjs.org/reflect-metadata/-/reflect-metadata-0.1.13.tgz",
...@@ -9758,11 +10117,18 @@ ...@@ -9758,11 +10117,18 @@
"integrity": "sha1-jcrkcOHIirwtYA//Sndihtp15jc=", "integrity": "sha1-jcrkcOHIirwtYA//Sndihtp15jc=",
"dev": true "dev": true
}, },
"repeating": {
"version": "2.0.1",
"resolved": "https://registry.npmjs.org/repeating/-/repeating-2.0.1.tgz",
"integrity": "sha1-UhTFOpJtNVJwdSf7q0FdvAjQbdo=",
"requires": {
"is-finite": "^1.0.0"
}
},
"request": { "request": {
"version": "2.88.2", "version": "2.88.2",
"resolved": "https://registry.npmjs.org/request/-/request-2.88.2.tgz", "resolved": "https://registry.npmjs.org/request/-/request-2.88.2.tgz",
"integrity": "sha512-MsvtOrfG9ZcrOwAW+Qi+F6HbD0CWXEh9ou77uOb7FM2WPhwT7smM833PzanhJLsgXjN89Ir6V2PczXNnMpwKhw==", "integrity": "sha512-MsvtOrfG9ZcrOwAW+Qi+F6HbD0CWXEh9ou77uOb7FM2WPhwT7smM833PzanhJLsgXjN89Ir6V2PczXNnMpwKhw==",
"dev": true,
"requires": { "requires": {
"aws-sign2": "~0.7.0", "aws-sign2": "~0.7.0",
"aws4": "^1.8.0", "aws4": "^1.8.0",
...@@ -9789,16 +10155,14 @@ ...@@ -9789,16 +10155,14 @@
"qs": { "qs": {
"version": "6.5.2", "version": "6.5.2",
"resolved": "https://registry.npmjs.org/qs/-/qs-6.5.2.tgz", "resolved": "https://registry.npmjs.org/qs/-/qs-6.5.2.tgz",
"integrity": "sha512-N5ZAX4/LxJmF+7wN74pUD6qAh9/wnvdQcjq9TZjevvXzSUo7bfmw91saqMjzGS2xq91/odN2dW/WOl7qQHNDGA==", "integrity": "sha512-N5ZAX4/LxJmF+7wN74pUD6qAh9/wnvdQcjq9TZjevvXzSUo7bfmw91saqMjzGS2xq91/odN2dW/WOl7qQHNDGA=="
"dev": true
} }
} }
}, },
"require-directory": { "require-directory": {
"version": "2.1.1", "version": "2.1.1",
"resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz",
"integrity": "sha1-jGStX9MNqxyXbiNE/+f3kqam30I=", "integrity": "sha1-jGStX9MNqxyXbiNE/+f3kqam30I="
"dev": true
}, },
"require-main-filename": { "require-main-filename": {
"version": "1.0.1", "version": "1.0.1",
...@@ -9816,7 +10180,6 @@ ...@@ -9816,7 +10180,6 @@
"version": "1.17.0", "version": "1.17.0",
"resolved": "https://registry.npmjs.org/resolve/-/resolve-1.17.0.tgz", "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.17.0.tgz",
"integrity": "sha512-ic+7JYiV8Vi2yzQGFWOkiZD5Z9z7O2Zhm9XMaTxdJExKasieFCr+yXZ/WmXsckHiKl12ar0y6XiXDx3m4RHn1w==", "integrity": "sha512-ic+7JYiV8Vi2yzQGFWOkiZD5Z9z7O2Zhm9XMaTxdJExKasieFCr+yXZ/WmXsckHiKl12ar0y6XiXDx3m4RHn1w==",
"dev": true,
"requires": { "requires": {
"path-parse": "^1.0.6" "path-parse": "^1.0.6"
} }
...@@ -9962,6 +10325,103 @@ ...@@ -9962,6 +10325,103 @@
"chokidar": ">=2.0.0 <4.0.0" "chokidar": ">=2.0.0 <4.0.0"
} }
}, },
"sass-graph": {
"version": "2.2.5",
"resolved": "https://registry.npmjs.org/sass-graph/-/sass-graph-2.2.5.tgz",
"integrity": "sha512-VFWDAHOe6mRuT4mZRd4eKE+d8Uedrk6Xnh7Sh9b4NGufQLQjOrvf/MQoOdx+0s92L89FeyUUNfU597j/3uNpag==",
"requires": {
"glob": "^7.0.0",
"lodash": "^4.0.0",
"scss-tokenizer": "^0.2.3",
"yargs": "^13.3.2"
},
"dependencies": {
"ansi-regex": {
"version": "4.1.0",
"resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-4.1.0.tgz",
"integrity": "sha512-1apePfXM1UOSqw0o9IiFAovVz9M5S1Dg+4TrDwfMewQ6p/rmMueb7tWZjQ1rx4Loy1ArBggoqGpfqqdI4rondg=="
},
"cliui": {
"version": "5.0.0",
"resolved": "https://registry.npmjs.org/cliui/-/cliui-5.0.0.tgz",
"integrity": "sha512-PYeGSEmmHM6zvoef2w8TPzlrnNpXIjTipYK780YswmIP9vjxmd6Y2a3CB2Ks6/AU8NHjZugXvo8w3oWM2qnwXA==",
"requires": {
"string-width": "^3.1.0",
"strip-ansi": "^5.2.0",
"wrap-ansi": "^5.1.0"
}
},
"emoji-regex": {
"version": "7.0.3",
"resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-7.0.3.tgz",
"integrity": "sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA=="
},
"get-caller-file": {
"version": "2.0.5",
"resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz",
"integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg=="
},
"require-main-filename": {
"version": "2.0.0",
"resolved": "https://registry.npmjs.org/require-main-filename/-/require-main-filename-2.0.0.tgz",
"integrity": "sha512-NKN5kMDylKuldxYLSUfrbo5Tuzh4hd+2E8NPPX02mZtn1VuREQToYe/ZdlJy+J3uCpfaiGF05e7B8W0iXbQHmg=="
},
"string-width": {
"version": "3.1.0",
"resolved": "https://registry.npmjs.org/string-width/-/string-width-3.1.0.tgz",
"integrity": "sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==",
"requires": {
"emoji-regex": "^7.0.1",
"is-fullwidth-code-point": "^2.0.0",
"strip-ansi": "^5.1.0"
}
},
"strip-ansi": {
"version": "5.2.0",
"resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-5.2.0.tgz",
"integrity": "sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==",
"requires": {
"ansi-regex": "^4.1.0"
}
},
"wrap-ansi": {
"version": "5.1.0",
"resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-5.1.0.tgz",
"integrity": "sha512-QC1/iN/2/RPVJ5jYK8BGttj5z83LmSKmvbvrXPNCLZSEb32KKVDJDl/MOt2N01qU2H/FkzEa9PKto1BqDjtd7Q==",
"requires": {
"ansi-styles": "^3.2.0",
"string-width": "^3.0.0",
"strip-ansi": "^5.0.0"
}
},
"yargs": {
"version": "13.3.2",
"resolved": "https://registry.npmjs.org/yargs/-/yargs-13.3.2.tgz",
"integrity": "sha512-AX3Zw5iPruN5ie6xGRIDgqkT+ZhnRlZMLMHAs8tg7nRruy2Nb+i5o9bwghAogtM08q1dpr2LVoS8KSTMYpWXUw==",
"requires": {
"cliui": "^5.0.0",
"find-up": "^3.0.0",
"get-caller-file": "^2.0.1",
"require-directory": "^2.1.1",
"require-main-filename": "^2.0.0",
"set-blocking": "^2.0.0",
"string-width": "^3.0.0",
"which-module": "^2.0.0",
"y18n": "^4.0.0",
"yargs-parser": "^13.1.2"
}
},
"yargs-parser": {
"version": "13.1.2",
"resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-13.1.2.tgz",
"integrity": "sha512-3lbsNRf/j+A4QuSZfDRA7HRSfWrzO0YjqTJd5kjAq37Zep1CEgaYmrH9Q3GwPiB9cHyd1Y1UwggGhJGoxipbzg==",
"requires": {
"camelcase": "^5.0.0",
"decamelize": "^1.2.0"
}
}
}
},
"sass-loader": { "sass-loader": {
"version": "8.0.0", "version": "8.0.0",
"resolved": "https://registry.npmjs.org/sass-loader/-/sass-loader-8.0.0.tgz", "resolved": "https://registry.npmjs.org/sass-loader/-/sass-loader-8.0.0.tgz",
...@@ -10058,6 +10518,25 @@ ...@@ -10058,6 +10518,25 @@
"ajv-keywords": "^3.1.0" "ajv-keywords": "^3.1.0"
} }
}, },
"scss-tokenizer": {
"version": "0.2.3",
"resolved": "https://registry.npmjs.org/scss-tokenizer/-/scss-tokenizer-0.2.3.tgz",
"integrity": "sha1-jrBtualyMzOCTT9VMGQRSYR85dE=",
"requires": {
"js-base64": "^2.1.8",
"source-map": "^0.4.2"
},
"dependencies": {
"source-map": {
"version": "0.4.4",
"resolved": "https://registry.npmjs.org/source-map/-/source-map-0.4.4.tgz",
"integrity": "sha1-66T12pwNyZneaAMti092FzZSA2s=",
"requires": {
"amdefine": ">=0.0.4"
}
}
}
},
"sdk-base": { "sdk-base": {
"version": "2.0.1", "version": "2.0.1",
"resolved": "https://registry.npmjs.org/sdk-base/-/sdk-base-2.0.1.tgz", "resolved": "https://registry.npmjs.org/sdk-base/-/sdk-base-2.0.1.tgz",
...@@ -10224,8 +10703,7 @@ ...@@ -10224,8 +10703,7 @@
"set-blocking": { "set-blocking": {
"version": "2.0.0", "version": "2.0.0",
"resolved": "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz", "resolved": "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz",
"integrity": "sha1-BF+XgtARrppoA93TgrJDkrPYkPc=", "integrity": "sha1-BF+XgtARrppoA93TgrJDkrPYkPc="
"dev": true
}, },
"set-immediate-shim": { "set-immediate-shim": {
"version": "1.0.1", "version": "1.0.1",
...@@ -10293,8 +10771,7 @@ ...@@ -10293,8 +10771,7 @@
"signal-exit": { "signal-exit": {
"version": "3.0.3", "version": "3.0.3",
"resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.3.tgz", "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.3.tgz",
"integrity": "sha512-VUJ49FC8U1OxwZLxIbTTrDvLnf/6TDgxZcK8wxR8zs13xpx7xbG60ndBlhNrFi2EMuFRoeDoJO7wthSLq42EjA==", "integrity": "sha512-VUJ49FC8U1OxwZLxIbTTrDvLnf/6TDgxZcK8wxR8zs13xpx7xbG60ndBlhNrFi2EMuFRoeDoJO7wthSLq42EjA=="
"dev": true
}, },
"simple-swizzle": { "simple-swizzle": {
"version": "0.2.2", "version": "0.2.2",
...@@ -10696,7 +11173,6 @@ ...@@ -10696,7 +11173,6 @@
"version": "3.1.1", "version": "3.1.1",
"resolved": "https://registry.npmjs.org/spdx-correct/-/spdx-correct-3.1.1.tgz", "resolved": "https://registry.npmjs.org/spdx-correct/-/spdx-correct-3.1.1.tgz",
"integrity": "sha512-cOYcUWwhCuHCXi49RhFRCyJEK3iPj1Ziz9DpViV3tbZOwXD49QzIN3MpOLJNxh2qwq2lJJZaKMVw9qNi4jTC0w==", "integrity": "sha512-cOYcUWwhCuHCXi49RhFRCyJEK3iPj1Ziz9DpViV3tbZOwXD49QzIN3MpOLJNxh2qwq2lJJZaKMVw9qNi4jTC0w==",
"dev": true,
"requires": { "requires": {
"spdx-expression-parse": "^3.0.0", "spdx-expression-parse": "^3.0.0",
"spdx-license-ids": "^3.0.0" "spdx-license-ids": "^3.0.0"
...@@ -10705,14 +11181,12 @@ ...@@ -10705,14 +11181,12 @@
"spdx-exceptions": { "spdx-exceptions": {
"version": "2.3.0", "version": "2.3.0",
"resolved": "https://registry.npmjs.org/spdx-exceptions/-/spdx-exceptions-2.3.0.tgz", "resolved": "https://registry.npmjs.org/spdx-exceptions/-/spdx-exceptions-2.3.0.tgz",
"integrity": "sha512-/tTrYOC7PPI1nUAgx34hUpqXuyJG+DTHJTnIULG4rDygi4xu/tfgmq1e1cIRwRzwZgo4NLySi+ricLkZkw4i5A==", "integrity": "sha512-/tTrYOC7PPI1nUAgx34hUpqXuyJG+DTHJTnIULG4rDygi4xu/tfgmq1e1cIRwRzwZgo4NLySi+ricLkZkw4i5A=="
"dev": true
}, },
"spdx-expression-parse": { "spdx-expression-parse": {
"version": "3.0.1", "version": "3.0.1",
"resolved": "https://registry.npmjs.org/spdx-expression-parse/-/spdx-expression-parse-3.0.1.tgz", "resolved": "https://registry.npmjs.org/spdx-expression-parse/-/spdx-expression-parse-3.0.1.tgz",
"integrity": "sha512-cbqHunsQWnJNE6KhVSMsMeH5H/L9EpymbzqTQ3uLwNCLZ1Q481oWaofqH7nO6V07xlXwY6PhQdQ2IedWx/ZK4Q==", "integrity": "sha512-cbqHunsQWnJNE6KhVSMsMeH5H/L9EpymbzqTQ3uLwNCLZ1Q481oWaofqH7nO6V07xlXwY6PhQdQ2IedWx/ZK4Q==",
"dev": true,
"requires": { "requires": {
"spdx-exceptions": "^2.1.0", "spdx-exceptions": "^2.1.0",
"spdx-license-ids": "^3.0.0" "spdx-license-ids": "^3.0.0"
...@@ -10721,8 +11195,7 @@ ...@@ -10721,8 +11195,7 @@
"spdx-license-ids": { "spdx-license-ids": {
"version": "3.0.5", "version": "3.0.5",
"resolved": "https://registry.npmjs.org/spdx-license-ids/-/spdx-license-ids-3.0.5.tgz", "resolved": "https://registry.npmjs.org/spdx-license-ids/-/spdx-license-ids-3.0.5.tgz",
"integrity": "sha512-J+FWzZoynJEXGphVIS+XEh3kFSjZX/1i9gFBaWQcB+/tmpe2qUsSBABpcxqxnAxFdiUFEgAX1bjYGQvIZmoz9Q==", "integrity": "sha512-J+FWzZoynJEXGphVIS+XEh3kFSjZX/1i9gFBaWQcB+/tmpe2qUsSBABpcxqxnAxFdiUFEgAX1bjYGQvIZmoz9Q=="
"dev": true
}, },
"spdy": { "spdy": {
"version": "4.0.2", "version": "4.0.2",
...@@ -10833,7 +11306,6 @@ ...@@ -10833,7 +11306,6 @@
"version": "1.16.1", "version": "1.16.1",
"resolved": "https://registry.npmjs.org/sshpk/-/sshpk-1.16.1.tgz", "resolved": "https://registry.npmjs.org/sshpk/-/sshpk-1.16.1.tgz",
"integrity": "sha512-HXXqVUq7+pcKeLqqZj6mHFUMvXtOJt1uoUx09pFW6011inTMxqI8BA8PM95myrIyyKwdnzjdFjLiE6KBPVtJIg==", "integrity": "sha512-HXXqVUq7+pcKeLqqZj6mHFUMvXtOJt1uoUx09pFW6011inTMxqI8BA8PM95myrIyyKwdnzjdFjLiE6KBPVtJIg==",
"dev": true,
"requires": { "requires": {
"asn1": "~0.2.3", "asn1": "~0.2.3",
"assert-plus": "^1.0.0", "assert-plus": "^1.0.0",
...@@ -10888,6 +11360,14 @@ ...@@ -10888,6 +11360,14 @@
"resolved": "https://registry.npmjs.org/statuses/-/statuses-1.5.0.tgz", "resolved": "https://registry.npmjs.org/statuses/-/statuses-1.5.0.tgz",
"integrity": "sha1-Fhx9rBd2Wf2YEfQ3cfqZOBR4Yow=" "integrity": "sha1-Fhx9rBd2Wf2YEfQ3cfqZOBR4Yow="
}, },
"stdout-stream": {
"version": "1.4.1",
"resolved": "https://registry.npmjs.org/stdout-stream/-/stdout-stream-1.4.1.tgz",
"integrity": "sha512-j4emi03KXqJWcIeF8eIXkjMFN1Cmb8gUlDYGeBALLPo5qdyTfA9bOtl8m33lRoC+vFMkP3gl0WsDr6+gzxbbTA==",
"requires": {
"readable-stream": "^2.0.1"
}
},
"stream-browserify": { "stream-browserify": {
"version": "2.0.2", "version": "2.0.2",
"resolved": "https://registry.npmjs.org/stream-browserify/-/stream-browserify-2.0.2.tgz", "resolved": "https://registry.npmjs.org/stream-browserify/-/stream-browserify-2.0.2.tgz",
...@@ -10981,7 +11461,6 @@ ...@@ -10981,7 +11461,6 @@
"version": "2.1.1", "version": "2.1.1",
"resolved": "https://registry.npmjs.org/string-width/-/string-width-2.1.1.tgz", "resolved": "https://registry.npmjs.org/string-width/-/string-width-2.1.1.tgz",
"integrity": "sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw==", "integrity": "sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw==",
"dev": true,
"requires": { "requires": {
"is-fullwidth-code-point": "^2.0.0", "is-fullwidth-code-point": "^2.0.0",
"strip-ansi": "^4.0.0" "strip-ansi": "^4.0.0"
...@@ -10990,14 +11469,12 @@ ...@@ -10990,14 +11469,12 @@
"ansi-regex": { "ansi-regex": {
"version": "3.0.0", "version": "3.0.0",
"resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.0.tgz", "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.0.tgz",
"integrity": "sha1-7QMXwyIGT3lGbAKWa922Bas32Zg=", "integrity": "sha1-7QMXwyIGT3lGbAKWa922Bas32Zg="
"dev": true
}, },
"strip-ansi": { "strip-ansi": {
"version": "4.0.0", "version": "4.0.0",
"resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz", "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz",
"integrity": "sha1-qEeQIusaw2iocTibY1JixQXuNo8=", "integrity": "sha1-qEeQIusaw2iocTibY1JixQXuNo8=",
"dev": true,
"requires": { "requires": {
"ansi-regex": "^3.0.0" "ansi-regex": "^3.0.0"
} }
...@@ -11036,7 +11513,6 @@ ...@@ -11036,7 +11513,6 @@
"version": "3.0.1", "version": "3.0.1",
"resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz",
"integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=",
"dev": true,
"requires": { "requires": {
"ansi-regex": "^2.0.0" "ansi-regex": "^2.0.0"
} }
...@@ -11053,6 +11529,14 @@ ...@@ -11053,6 +11529,14 @@
"integrity": "sha1-u0P/VZim6wXYm1n80SnJgzE2Br8=", "integrity": "sha1-u0P/VZim6wXYm1n80SnJgzE2Br8=",
"dev": true "dev": true
}, },
"strip-indent": {
"version": "1.0.1",
"resolved": "https://registry.npmjs.org/strip-indent/-/strip-indent-1.0.1.tgz",
"integrity": "sha1-DHlipq3vp7vUrDZkYKY4VSrhoKI=",
"requires": {
"get-stdin": "^4.0.1"
}
},
"style-loader": { "style-loader": {
"version": "1.0.0", "version": "1.0.0",
"resolved": "https://registry.npmjs.org/style-loader/-/style-loader-1.0.0.tgz", "resolved": "https://registry.npmjs.org/style-loader/-/style-loader-1.0.0.tgz",
...@@ -11583,7 +12067,6 @@ ...@@ -11583,7 +12067,6 @@
"version": "2.5.0", "version": "2.5.0",
"resolved": "https://registry.npmjs.org/tough-cookie/-/tough-cookie-2.5.0.tgz", "resolved": "https://registry.npmjs.org/tough-cookie/-/tough-cookie-2.5.0.tgz",
"integrity": "sha512-nlLsUzgm1kfLXSXfRZMc1KLAugd4hqJHDTvc2hDIwS3mZAfMEuMbc03SujMF+GEcpaX/qboeycw6iO8JwVv2+g==", "integrity": "sha512-nlLsUzgm1kfLXSXfRZMc1KLAugd4hqJHDTvc2hDIwS3mZAfMEuMbc03SujMF+GEcpaX/qboeycw6iO8JwVv2+g==",
"dev": true,
"requires": { "requires": {
"psl": "^1.1.28", "psl": "^1.1.28",
"punycode": "^2.1.1" "punycode": "^2.1.1"
...@@ -11595,6 +12078,19 @@ ...@@ -11595,6 +12078,19 @@
"integrity": "sha512-L0Orpi8qGpRG//Nd+H90vFB+3iHnue1zSSGmNOOCh1GLJ7rUKVwV2HvijphGQS2UmhUZewS9VgvxYIdgr+fG1A==", "integrity": "sha512-L0Orpi8qGpRG//Nd+H90vFB+3iHnue1zSSGmNOOCh1GLJ7rUKVwV2HvijphGQS2UmhUZewS9VgvxYIdgr+fG1A==",
"dev": true "dev": true
}, },
"trim-newlines": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/trim-newlines/-/trim-newlines-1.0.0.tgz",
"integrity": "sha1-WIeWa7WCpFA6QetST301ARgVphM="
},
"true-case-path": {
"version": "1.0.3",
"resolved": "https://registry.npmjs.org/true-case-path/-/true-case-path-1.0.3.tgz",
"integrity": "sha512-m6s2OdQe5wgpFMC+pAJ+q9djG82O2jcHPOI6RNg1yy9rCYR+WD6Nbpl32fDpfC56nirdRy+opFa/Vk7HYhqaew==",
"requires": {
"glob": "^7.1.2"
}
},
"ts-node": { "ts-node": {
"version": "8.3.0", "version": "8.3.0",
"resolved": "https://registry.npmjs.org/ts-node/-/ts-node-8.3.0.tgz", "resolved": "https://registry.npmjs.org/ts-node/-/ts-node-8.3.0.tgz",
...@@ -11661,7 +12157,6 @@ ...@@ -11661,7 +12157,6 @@
"version": "0.6.0", "version": "0.6.0",
"resolved": "https://registry.npmjs.org/tunnel-agent/-/tunnel-agent-0.6.0.tgz", "resolved": "https://registry.npmjs.org/tunnel-agent/-/tunnel-agent-0.6.0.tgz",
"integrity": "sha1-J6XeoGs2sEoKmWZ3SykIaPD8QP0=", "integrity": "sha1-J6XeoGs2sEoKmWZ3SykIaPD8QP0=",
"dev": true,
"requires": { "requires": {
"safe-buffer": "^5.0.1" "safe-buffer": "^5.0.1"
} }
...@@ -11669,8 +12164,7 @@ ...@@ -11669,8 +12164,7 @@
"tweetnacl": { "tweetnacl": {
"version": "0.14.5", "version": "0.14.5",
"resolved": "https://registry.npmjs.org/tweetnacl/-/tweetnacl-0.14.5.tgz", "resolved": "https://registry.npmjs.org/tweetnacl/-/tweetnacl-0.14.5.tgz",
"integrity": "sha1-WuaBd/GS1EViadEIr6k/+HQ/T2Q=", "integrity": "sha1-WuaBd/GS1EViadEIr6k/+HQ/T2Q="
"dev": true
}, },
"type-check": { "type-check": {
"version": "0.3.2", "version": "0.3.2",
...@@ -11881,7 +12375,6 @@ ...@@ -11881,7 +12375,6 @@
"version": "4.2.2", "version": "4.2.2",
"resolved": "https://registry.npmjs.org/uri-js/-/uri-js-4.2.2.tgz", "resolved": "https://registry.npmjs.org/uri-js/-/uri-js-4.2.2.tgz",
"integrity": "sha512-KY9Frmirql91X2Qgjry0Wd4Y+YTdrdZheS8TFwvkbLWf/G5KNJDCh6pKL5OZctEW4+0Baa5idK2ZQuELRwPznQ==", "integrity": "sha512-KY9Frmirql91X2Qgjry0Wd4Y+YTdrdZheS8TFwvkbLWf/G5KNJDCh6pKL5OZctEW4+0Baa5idK2ZQuELRwPznQ==",
"dev": true,
"requires": { "requires": {
"punycode": "^2.1.0" "punycode": "^2.1.0"
} }
...@@ -12040,14 +12533,12 @@ ...@@ -12040,14 +12533,12 @@
"uuid": { "uuid": {
"version": "3.4.0", "version": "3.4.0",
"resolved": "https://registry.npmjs.org/uuid/-/uuid-3.4.0.tgz", "resolved": "https://registry.npmjs.org/uuid/-/uuid-3.4.0.tgz",
"integrity": "sha512-HjSDRw6gZE5JMggctHBcjVak08+KEVhSIiDzFnT9S9aegmp85S/bReBVTb4QTFaRNptJ9kuYaNhnbNEOkbKb/A==", "integrity": "sha512-HjSDRw6gZE5JMggctHBcjVak08+KEVhSIiDzFnT9S9aegmp85S/bReBVTb4QTFaRNptJ9kuYaNhnbNEOkbKb/A=="
"dev": true
}, },
"validate-npm-package-license": { "validate-npm-package-license": {
"version": "3.0.4", "version": "3.0.4",
"resolved": "https://registry.npmjs.org/validate-npm-package-license/-/validate-npm-package-license-3.0.4.tgz", "resolved": "https://registry.npmjs.org/validate-npm-package-license/-/validate-npm-package-license-3.0.4.tgz",
"integrity": "sha512-DpKm2Ui/xN7/HQKCtpZxoRWBhZ9Z0kqtygG8XCgNQ8ZlDnxuQmWhj566j8fN4Cu3/JmbhsDo7fcAJq4s9h27Ew==", "integrity": "sha512-DpKm2Ui/xN7/HQKCtpZxoRWBhZ9Z0kqtygG8XCgNQ8ZlDnxuQmWhj566j8fN4Cu3/JmbhsDo7fcAJq4s9h27Ew==",
"dev": true,
"requires": { "requires": {
"spdx-correct": "^3.0.0", "spdx-correct": "^3.0.0",
"spdx-expression-parse": "^3.0.0" "spdx-expression-parse": "^3.0.0"
...@@ -12078,7 +12569,6 @@ ...@@ -12078,7 +12569,6 @@
"version": "1.10.0", "version": "1.10.0",
"resolved": "https://registry.npmjs.org/verror/-/verror-1.10.0.tgz", "resolved": "https://registry.npmjs.org/verror/-/verror-1.10.0.tgz",
"integrity": "sha1-OhBcoXBTr1XW4nDB+CiGguGNpAA=", "integrity": "sha1-OhBcoXBTr1XW4nDB+CiGguGNpAA=",
"dev": true,
"requires": { "requires": {
"assert-plus": "^1.0.0", "assert-plus": "^1.0.0",
"core-util-is": "1.0.2", "core-util-is": "1.0.2",
...@@ -12719,7 +13209,6 @@ ...@@ -12719,7 +13209,6 @@
"version": "1.3.1", "version": "1.3.1",
"resolved": "https://registry.npmjs.org/which/-/which-1.3.1.tgz", "resolved": "https://registry.npmjs.org/which/-/which-1.3.1.tgz",
"integrity": "sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==", "integrity": "sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==",
"dev": true,
"requires": { "requires": {
"isexe": "^2.0.0" "isexe": "^2.0.0"
} }
...@@ -12727,8 +13216,15 @@ ...@@ -12727,8 +13216,15 @@
"which-module": { "which-module": {
"version": "2.0.0", "version": "2.0.0",
"resolved": "https://registry.npmjs.org/which-module/-/which-module-2.0.0.tgz", "resolved": "https://registry.npmjs.org/which-module/-/which-module-2.0.0.tgz",
"integrity": "sha1-2e8H3Od7mQK4o6j6SzHD4/fm6Ho=", "integrity": "sha1-2e8H3Od7mQK4o6j6SzHD4/fm6Ho="
"dev": true },
"wide-align": {
"version": "1.1.3",
"resolved": "https://registry.npmjs.org/wide-align/-/wide-align-1.1.3.tgz",
"integrity": "sha512-QGkOQc8XL6Bt5PwnsExKBPuMKBxnGxWWW3fU55Xt4feHozMUhdUMaBCk290qpm/wG5u/RSKzwdAC4i51YigihA==",
"requires": {
"string-width": "^1.0.2 || 2"
}
}, },
"win-release": { "win-release": {
"version": "1.1.1", "version": "1.1.1",
...@@ -12846,8 +13342,7 @@ ...@@ -12846,8 +13342,7 @@
"y18n": { "y18n": {
"version": "4.0.0", "version": "4.0.0",
"resolved": "https://registry.npmjs.org/y18n/-/y18n-4.0.0.tgz", "resolved": "https://registry.npmjs.org/y18n/-/y18n-4.0.0.tgz",
"integrity": "sha512-r9S/ZyXu/Xu9q1tYlpsLIsa3EeLXXk0VwlxqTcFRfg9EhMW+17kbt9G0NrgCmhGb5vT2hyhJZLfDGx+7+5Uj/w==", "integrity": "sha512-r9S/ZyXu/Xu9q1tYlpsLIsa3EeLXXk0VwlxqTcFRfg9EhMW+17kbt9G0NrgCmhGb5vT2hyhJZLfDGx+7+5Uj/w=="
"dev": true
}, },
"yallist": { "yallist": {
"version": "3.1.1", "version": "3.1.1",
......
...@@ -7,29 +7,20 @@ ...@@ -7,29 +7,20 @@
} }
.radioPaire { .question-box {
float: left; width: 1000px;
margin: 3px; border: 1px solid #ccc;
border-style: dashed; padding: 25px;
border-color: #000;
border-width: 1px;
}
.border {
border-radius: 20px; border-radius: 20px;
border-style: dashed; margin-bottom: 20px;
padding: 20px;
margin: 20px;
/*width: 500px; */
/*//border-radius: 20px;*/
/*//border-width: 2px;*/
/*//border-color: #000000;*/
} }
.border-lite { .group-box {
border: 2px dashed #ddd; width: 1050px;
border-radius: 0.5rem; border: 2px solid #ccc;
padding: 10px; padding: 25px;
margin: 10px; border-radius: 20px;
margin-bottom: 20px;
} }
<div class="model-content"> <div class="model-content">
<div style="padding: 10px;"> <div style="padding: 30px">
<div style="width: 300px;" align='center'> <div style="display: flex; flex-direction: column; margin-bottom: 20px;">
<span>图1: </span> <span nz-text nzType="secondary"> 【最佳图片尺寸】 </span>
<app-upload-image-with-preview <span nz-text nzType="secondary">1、题干图片最佳尺寸:678*396</span>
[picUrl]="item.pic_url" <span nz-text nzType="secondary">2、选项图片最佳尺寸:366*248</span>
(imageUploaded)="onImageUploadSuccess($event, 'pic_url')"> <span nz-text nzType="secondary">重要提示:</span>
</app-upload-image-with-preview> <span nz-text nzType="secondary">内容编辑完成后,一定要进行预览~!!!</span>
<span nz-text nzType="secondary">确保预览没问题后再发布~!!!</span>
</div>
<div *ngFor="let g of item.groupArr; let gi = index" class="group-box">
<div style="display: flex; align-items: center;">
<h1>组-{{gi+1}}</h1>
<button style="margin-left: 50px; margin-bottom: 12px;" nz-button nzType="danger" nzsize="small" (click)="deleteGroup(gi)">删除本组</button>
</div>
<div *ngFor="let q of g.questionArr; let qi = index" class="question-box">
<h1>题-{{qi + 1}}</h1>
<div style="display: flex; align-items: center; ">
<h2> 题干类型: </h2>
<nz-radio-group [(ngModel)]="q.questionType" style="margin-left: 20px; margin-top: -11px" (ngModelChange)="save()">
<label nz-radio nzValue="text">文本</label>
<label nz-radio nzValue="pic">图片</label>
<label nz-radio nzValue="audio">音频</label>
<label nz-radio nzValue="video">视频</label>
</nz-radio-group>
<button style="margin-left: 100px; margin-bottom: 12px;" nz-button nzType="danger" nzsize="small" (click)="deleteQuestion(g, qi)">删除本题</button>
</div>
<div style="width: 700px">
<div *ngIf="q.questionType == 'text'">
<input type="text" nz-input [(ngModel)]="q.text" (blur)="save()">
</div> </div>
<div style="width: 300px; margin-top: 5px;" align='center'> <div *ngIf="q.questionType == 'pic'" style="width: 80%">
<span>图2: </span>
<app-upload-image-with-preview <app-upload-image-with-preview
[picUrl]="item.pic_url_2" [picUrl]="q.pic_url"
(imageUploaded)="onImageUploadSuccess($event, 'pic_url_2')"> (imageUploaded)="onImageUploadSuccess($event, 'pic_url', q)"
</app-upload-image-with-preview> ></app-upload-image-with-preview>
</div>
<div *ngIf="q.questionType != 'video'">
<app-audio-recorder
[audioUrl]="q.audio_url"
(audioUploaded)="onAudioUploadSuccess($event, 'audio_url', q)"
></app-audio-recorder>
</div> </div>
<div style="width: 300px; margin-top: 15px;"> <div *ngIf="q.questionType == 'video'">
<span>文本: </span> <app-upload-video
<input type="text" nz-input [(ngModel)]="item.text" (blur)="save()"> (videoUploaded)="onVideoUploadSuccess($event, q)"
[item]="q"
[videoUrl]="q.video_url"></app-upload-video>
</div>
</div> </div>
<div style="margin-top: 5px"> <nz-divider style=" margin-top: 30px; margin-bottom: 30px;"></nz-divider>
<span>音频: </span>
<div style="display: flex; align-items: center;">
<h2> 答案类型: </h2>
<nz-radio-group [(ngModel)]="q.answerType" style="margin-left: 20px; margin-top: -11px" (ngModelChange)="save()">
<label nz-radio nzValue="text">文本</label>
<label nz-radio nzValue="pic">图片</label>
<label nz-radio nzValue="audio">音频</label>
</nz-radio-group>
</div>
<div *ngFor="let it of q.answerArr; let i = index">
<div style="margin-bottom: 30px; width : 500px; border: 1px solid #ccc; border-radius: 10px; padding: 5px;">
<span> 答案{{i+1}}: </span>
<nz-radio-group style="margin-left: 20px; margin-bottom: 5px;" [(ngModel)]="it.answerRight" (ngModelChange)="save()">
<label nz-radio nzValue="0">错误</label>
<label nz-radio nzValue="1">正确</label>
<button style="margin-left: 240px" nz-button nzType="danger" nzsize="small" (click)="deleteAnswer(q, i)">X</button>
</nz-radio-group>
<input *ngIf="q.answerType == 'text'" type="text" nz-input [(ngModel)]="it.text" (blur)="save()">
<app-upload-image-with-preview
*ngIf="q.answerType == 'pic'"
[picUrl]="it.pic_url"
(imageUploaded)="onImageUploadSuccess($event, 'pic_url', it)"
></app-upload-image-with-preview>
<app-audio-recorder <app-audio-recorder
[audioUrl]="item.audio_url" [audioUrl]="it.audio_url"
(audioUploaded)="onAudioUploadSuccess($event, 'audio_url')" (audioUploaded)="onAudioUploadSuccess($event, 'audio_url', it)"
></app-audio-recorder> ></app-audio-recorder>
</div>
</div>
<div *ngIf="q.answerArr?.length < 4" style="padding: 30px;" >
<button nz-button nzType="dashed" style="width: 150px; height: 50px; margin-top: -30px; margin-left: -30px" (click)="addAnswer(q)">添加答案</button>
</div>
</div>
<div style="padding: 30px;" >
<button nz-button nzType="dashed" style="width: 200px; height: 100px; margin-top: 10px; margin-left: -30px" (click)="addQuestion(g)">添加新题</button>
</div> </div>
</div> </div>
<div style="padding: 30px;" >
<button nz-button nzType="dashed" style="width: 200px; height: 100px; margin-top: 30px; margin-left: -30px" (click)="addGroup()">添加新组</button>
</div>
</div>
</div> </div>
import { Component, EventEmitter, Input, OnDestroy, OnChanges, OnInit, Output, ApplicationRef, ChangeDetectorRef } from '@angular/core'; import {Component, EventEmitter, Input, OnDestroy, OnChanges, OnInit, Output, ApplicationRef, ChangeDetectorRef} from '@angular/core';
import { JsonPipe } from '@angular/common';
@Component({ @Component({
...@@ -10,56 +10,105 @@ import { JsonPipe } from '@angular/common'; ...@@ -10,56 +10,105 @@ import { JsonPipe } from '@angular/common';
export class FormComponent implements OnInit, OnChanges, OnDestroy { export class FormComponent implements OnInit, OnChanges, OnDestroy {
// 储存数据用 // 储存数据用
saveKey = "test_001"; saveKey = "pu_app_xuanze";
// 储存对象 // 储存对象
item; item;
constructor(private appRef: ApplicationRef, private changeDetectorRef: ChangeDetectorRef) {
} constructor(private appRef: ApplicationRef,private changeDetectorRef: ChangeDetectorRef) {
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 = {};
// 获取存储的数据 // 获取存储的数据
(<any>window).courseware.getData((data) => { (<any> window).courseware.getData((data) => {
if (data) { if (data) {
this.item = data; this.item = data;
} }
// this.item = JSON.parse('{"questionType":"text","answerType":"text","answerArr":[{"text":"","pic_url":"","answerRight":"0"},{"text":"","pic_url":"","answerRight":"0"},{"text":"","pic_url":"","answerRight":"0"}],"questionArr":[{"questionType":"text","answerType":"text","answerArr":[{"text":"aaaaa","pic_url":"","answerRight":"0"},{"text":"bb","pic_url":"","answerRight":"1"},{"text":"ccccc","pic_url":"","answerRight":"0","audio_url":"http://staging-teach.cdn.ireadabc.com/b004c86f1a26a367cfa329b11e365f0f.mp3"}],"text":"11112","audio_url":"http://staging-teach.cdn.ireadabc.com/ce693028675b6324506ebfe45974e4c1.mp3"},{"questionType":"pic","answerType":"pic","answerArr":[{"text":"","pic_url":"http://staging-teach.cdn.ireadabc.com/56cf568aebe7ddfa75a0ac3366942241.png","answerRight":"0"},{"text":"","pic_url":"http://staging-teach.cdn.ireadabc.com/9340adda6869dd31a63b9d85a3f9ffe5.png","answerRight":"1","audio_url":"http://staging-teach.cdn.ireadabc.com/6725c1d93e9dbfbfc937ce3611b12631.mp3"}],"text":"22222","pic_url":"http://staging-teach.cdn.ireadabc.com/2d29dffee7d7fefea19ef7c8ea566072.png"},{"questionType":"audio","answerType":"audio","answerArr":[{"text":"","pic_url":"","answerRight":"0","audio_url":"http://staging-teach.cdn.ireadabc.com/519b8f68a4ebd96ee0405d945ca65489.mp3"},{"text":"","pic_url":"","answerRight":"1","audio_url":"http://staging-teach.cdn.ireadabc.com/b363bf8aaddd56ec977ce233f5d46be1.mp3"}],"audio_url":"http://staging-teach.cdn.ireadabc.com/7934cdcec68eabe639020bad5420d7f8.mp3"},{"questionType":"video","answerType":"text","answerArr":[{"text":"444444","pic_url":"","answerRight":"0"},{"text":"3333333","pic_url":"","answerRight":"1","audio_url":"http://staging-teach.cdn.ireadabc.com/f67df2a0dd444837299a3bede235c9d6.mp3"}],"video_url":"http://staging-teach.cdn.ireadabc.com/1ac7eb5446e806b562ec47ad88b092c9.mp4"}],"audio_url":"http://staging-teach.cdn.ireadabc.com/ce693028675b6324506ebfe45974e4c1.mp3"}');
console.log("this.item: ", JSON.stringify(this.item));
this.init(); this.init();
this.changeDetectorRef.markForCheck(); this.changeDetectorRef.markForCheck();
this.changeDetectorRef.detectChanges(); this.changeDetectorRef.detectChanges();
this.refresh(); this.refresh();
}, this.saveKey); }, this.saveKey);
} }
ngOnChanges() { ngOnChanges() {
} }
ngOnDestroy() { ngOnDestroy() {
} }
init() { init() {
if (!this.item.groupArr) {
this.item.groupArr = [];
}
// if (!this.item.questionArr) {
// this.item.questionArr = [];
// }
// if (!this.item.questionType) {
// this.item.questionType = 'text';
// this.item.answerType = 'text';
// this.item.answerArr = [];
// }
}
addGroup() {
this.item.groupArr.push({
questionArr: []
});
this.save();
}
deleteGroup(i) {
this.item.groupArr.splice(i , 1);
this.save();
}
addQuestion(group) {
const ques = {
questionType : 'text',
answerType : 'text',
answerArr : [],
}
group.questionArr.push(ques);
this.save();
}
deleteQuestion(grou, i) {
grou.questionArr.splice(i , 1);
this.save();
}
deleteAnswer(item, i) {
item.answerArr.splice(i, 1);
this.save();
}
addAnswer(q) {
q.answerArr.push({
text: '',
pic_url: '',
answerRight: '0',
});
this.save();
} }
...@@ -67,9 +116,12 @@ export class FormComponent implements OnInit, OnChanges, OnDestroy { ...@@ -67,9 +116,12 @@ export class FormComponent implements OnInit, OnChanges, OnDestroy {
* 储存图片数据 * 储存图片数据
* @param e * @param e
*/ */
onImageUploadSuccess(e, key) { onImageUploadSuccess(e, key, item = null) {
this.item[key] = e.url; if (!item) {
item = this.item;
}
item[key] = e.url;
this.save(); this.save();
} }
...@@ -77,18 +129,18 @@ export class FormComponent implements OnInit, OnChanges, OnDestroy { ...@@ -77,18 +129,18 @@ export class FormComponent implements OnInit, OnChanges, OnDestroy {
* 储存音频数据 * 储存音频数据
* @param e * @param e
*/ */
onAudioUploadSuccess(e, key) { onAudioUploadSuccess(e, key, item=null) {
this.item[key] = e.url;
this.save();
}
onWordAudioUploadSuccess(e, idx) { if (!item) {
this.item.wordList[idx].audio = e.url; item = this.item;
}
item[key] = e.url;
this.save(); this.save();
} }
onBackWordAudioUploadSuccess(e, idx) {
this.item.wordList[idx].backWordAudio = e.url; onVideoUploadSuccess(e, item) {
item.video_url = e.url;
this.save(); this.save();
} }
...@@ -96,10 +148,8 @@ export class FormComponent implements OnInit, OnChanges, OnDestroy { ...@@ -96,10 +148,8 @@ export class FormComponent implements OnInit, OnChanges, OnDestroy {
* 储存数据 * 储存数据
*/ */
save() { save() {
(<any>window).courseware.setData(this.item, null, this.saveKey); (<any> window).courseware.setData(this.item, null, this.saveKey);
this.refresh(); this.refresh();
console.log('this.item = ' + JSON.stringify(this.item));
} }
/** /**
...@@ -112,3 +162,4 @@ export class FormComponent implements OnInit, OnChanges, OnDestroy { ...@@ -112,3 +162,4 @@ export class FormComponent implements OnInit, OnChanges, OnDestroy {
} }
} }
This source diff could not be displayed because it is too large. You can view the blob instead.
{
"ver": "1.1.2",
"uuid": "e976091a-1c92-4be8-bdef-e61b8d23d13d",
"isBundle": true,
"bundleName": "",
"priority": 1,
"compressionType": {},
"optimizeHotUpdate": {},
"inlineSpriteFrames": {},
"isRemoteBundle": {
"ios": true,
"android": true
},
"subMetas": {}
}
\ No newline at end of file
{ {
"ver": "1.1.2", "ver": "1.1.2",
"uuid": "cb9fa4ea-66ca-45af-ad31-e445c7b0ef32", "uuid": "75aa2c1b-1b9f-420f-a059-a50a0857fdf6",
"isBundle": false, "isBundle": false,
"bundleName": "", "bundleName": "",
"priority": 1, "priority": 1,
......
{ {
"ver": "1.1.2", "ver": "1.1.2",
"uuid": "20185448-a1ca-4de2-8b37-7bf6cdfccbae", "uuid": "4bb574ab-d8a9-4a02-8081-cd22c8b5fb23",
"isBundle": false, "isBundle": false,
"bundleName": "", "bundleName": "",
"priority": 1, "priority": 1,
......
{ {
"ver": "2.3.5", "ver": "2.3.5",
"uuid": "9a79969a-0506-48d4-bc98-3c05d109b027", "uuid": "fa4d888d-4425-40c0-83f7-f8c5cd892d0b",
"type": "sprite", "type": "sprite",
"wrapMode": "clamp", "wrapMode": "clamp",
"filterMode": "bilinear", "filterMode": "bilinear",
"premultiplyAlpha": false, "premultiplyAlpha": false,
"genMipmaps": false, "genMipmaps": false,
"packable": true, "packable": true,
"width": 61, "width": 63,
"height": 67, "height": 68,
"platformSettings": {}, "platformSettings": {},
"subMetas": { "subMetas": {
"btn_left": { "btn_laba": {
"ver": "1.0.4", "ver": "1.0.4",
"uuid": "ce19457d-e8f3-4c38-ae3e-d4b99208ddb5", "uuid": "07a58438-24ac-46ef-acad-275a36ecd8ab",
"rawTextureUuid": "9a79969a-0506-48d4-bc98-3c05d109b027", "rawTextureUuid": "fa4d888d-4425-40c0-83f7-f8c5cd892d0b",
"trimType": "auto", "trimType": "auto",
"trimThreshold": 1, "trimThreshold": 1,
"rotated": false, "rotated": false,
...@@ -22,10 +22,10 @@ ...@@ -22,10 +22,10 @@
"offsetY": 0, "offsetY": 0,
"trimX": 0, "trimX": 0,
"trimY": 0, "trimY": 0,
"width": 61, "width": 63,
"height": 67, "height": 68,
"rawWidth": 61, "rawWidth": 63,
"rawHeight": 67, "rawHeight": 68,
"borderTop": 0, "borderTop": 0,
"borderBottom": 0, "borderBottom": 0,
"borderLeft": 0, "borderLeft": 0,
......
{ {
"ver": "2.3.5", "ver": "2.3.5",
"uuid": "efa5fa09-a4dd-4bfc-ab7e-17c19f85408f", "uuid": "71fd5385-83aa-4d73-baeb-460a8379c1cc",
"type": "sprite", "type": "sprite",
"wrapMode": "clamp", "wrapMode": "clamp",
"filterMode": "bilinear", "filterMode": "bilinear",
"premultiplyAlpha": false, "premultiplyAlpha": false,
"genMipmaps": false, "genMipmaps": false,
"packable": true, "packable": true,
"width": 366, "width": 63,
"height": 336, "height": 68,
"platformSettings": {}, "platformSettings": {},
"subMetas": { "subMetas": {
"1orange": { "btn_laba2": {
"ver": "1.0.4", "ver": "1.0.4",
"uuid": "43d1e79d-6de8-4dcb-b8ce-d767df7913aa", "uuid": "736831ca-2860-4e8f-b22e-417696a7093c",
"rawTextureUuid": "efa5fa09-a4dd-4bfc-ab7e-17c19f85408f", "rawTextureUuid": "71fd5385-83aa-4d73-baeb-460a8379c1cc",
"trimType": "auto", "trimType": "auto",
"trimThreshold": 1, "trimThreshold": 1,
"rotated": false, "rotated": false,
"offsetX": 0, "offsetX": 0,
"offsetY": -0.5, "offsetY": 0,
"trimX": 0, "trimX": 0,
"trimY": 1, "trimY": 0,
"width": 366, "width": 63,
"height": 335, "height": 68,
"rawWidth": 366, "rawWidth": 63,
"rawHeight": 336, "rawHeight": 68,
"borderTop": 0, "borderTop": 0,
"borderBottom": 0, "borderBottom": 0,
"borderLeft": 0, "borderLeft": 0,
......
{
"ver": "2.3.5",
"uuid": "cb6a98b5-6958-4520-bec1-ce1056bc01ea",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 63,
"height": 68,
"platformSettings": {},
"subMetas": {
"btn_laba3": {
"ver": "1.0.4",
"uuid": "0b0a7597-1a72-48f5-924e-ad2dbf733d25",
"rawTextureUuid": "cb6a98b5-6958-4520-bec1-ce1056bc01ea",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 63,
"height": 68,
"rawWidth": 63,
"rawHeight": 68,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{
"ver": "2.3.5",
"uuid": "2a467c38-7699-49f8-aad7-2213da46a3ba",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 63,
"height": 68,
"platformSettings": {},
"subMetas": {
"btn_laba4": {
"ver": "1.0.4",
"uuid": "79ca7f43-aacd-43c9-803b-111602421022",
"rawTextureUuid": "2a467c38-7699-49f8-aad7-2213da46a3ba",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 63,
"height": 68,
"rawWidth": 63,
"rawHeight": 68,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{
"__type__": "cc.AnimationClip",
"_name": "laba",
"_objFlags": 0,
"_native": "",
"_duration": 0.35,
"sample": 60,
"speed": 1,
"wrapMode": 2,
"curveData": {
"comps": {
"cc.Sprite": {
"spriteFrame": [
{
"frame": 0,
"value": {
"__uuid__": "07a58438-24ac-46ef-acad-275a36ecd8ab"
}
},
{
"frame": 0.08333333333333333,
"value": {
"__uuid__": "736831ca-2860-4e8f-b22e-417696a7093c"
}
},
{
"frame": 0.16666666666666666,
"value": {
"__uuid__": "0b0a7597-1a72-48f5-924e-ad2dbf733d25"
}
},
{
"frame": 0.25,
"value": {
"__uuid__": "79ca7f43-aacd-43c9-803b-111602421022"
}
},
{
"frame": 0.3333333333333333,
"value": {
"__uuid__": "07a58438-24ac-46ef-acad-275a36ecd8ab"
}
}
]
}
}
},
"events": []
}
\ No newline at end of file
{
"ver": "2.1.0",
"uuid": "e01464cd-bf75-4d4a-8243-a4604d675fec",
"subMetas": {}
}
\ No newline at end of file
{ {
"ver": "1.1.2", "ver": "1.1.2",
"uuid": "0853721c-3f55-4eb2-873d-e3081cfadd4b", "uuid": "af6afa75-6b41-4c9e-9238-bd69b56d3763",
"isBundle": false, "isBundle": false,
"bundleName": "", "bundleName": "",
"priority": 1, "priority": 1,
......
{
"ver": "2.3.5",
"uuid": "899a2db7-60b0-4ca7-a07e-777edaef98ab",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 150,
"height": 121,
"platformSettings": {},
"subMetas": {
"btn_audio0": {
"ver": "1.0.4",
"uuid": "1c70d9eb-1034-4997-a6fb-aea058d39beb",
"rawTextureUuid": "899a2db7-60b0-4ca7-a07e-777edaef98ab",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 150,
"height": 121,
"rawWidth": 150,
"rawHeight": 121,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{
"ver": "2.3.5",
"uuid": "7fe0cda8-17b1-492a-b87c-14a682d1f838",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 150,
"height": 121,
"platformSettings": {},
"subMetas": {
"btn_audio1": {
"ver": "1.0.4",
"uuid": "69eb205c-4901-452f-b4c8-989c1227830e",
"rawTextureUuid": "7fe0cda8-17b1-492a-b87c-14a682d1f838",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 14.5,
"offsetY": 0,
"trimX": 29,
"trimY": 0,
"width": 121,
"height": 121,
"rawWidth": 150,
"rawHeight": 121,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{
"ver": "2.3.5",
"uuid": "cabcdd1a-b71e-4382-9ffd-8a474bcc2129",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 150,
"height": 121,
"platformSettings": {},
"subMetas": {
"btn_audio2": {
"ver": "1.0.4",
"uuid": "7b2bd629-77ac-4fc8-9ee7-569ed0ed3a59",
"rawTextureUuid": "cabcdd1a-b71e-4382-9ffd-8a474bcc2129",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 14.5,
"offsetY": 0,
"trimX": 29,
"trimY": 0,
"width": 121,
"height": 121,
"rawWidth": 150,
"rawHeight": 121,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{
"__type__": "cc.AnimationClip",
"_name": "op_audio",
"_objFlags": 0,
"_native": "",
"_duration": 0.26666666666666666,
"sample": 60,
"speed": 1,
"wrapMode": 2,
"curveData": {
"comps": {
"cc.Sprite": {
"spriteFrame": [
{
"frame": 0,
"value": {
"__uuid__": "1c70d9eb-1034-4997-a6fb-aea058d39beb"
}
},
{
"frame": 0.08333333333333333,
"value": {
"__uuid__": "69eb205c-4901-452f-b4c8-989c1227830e"
}
},
{
"frame": 0.16666666666666666,
"value": {
"__uuid__": "7b2bd629-77ac-4fc8-9ee7-569ed0ed3a59"
}
},
{
"frame": 0.25,
"value": {
"__uuid__": "1c70d9eb-1034-4997-a6fb-aea058d39beb"
}
}
]
}
}
},
"events": []
}
\ No newline at end of file
{
"ver": "2.1.0",
"uuid": "990c93ef-ffbd-4d38-8e32-a403d2f4ff97",
"subMetas": {}
}
\ No newline at end of file
{
"ver": "1.1.2",
"uuid": "10154cf9-b9c1-41f6-a23c-d49e16c1ee57",
"isBundle": false,
"bundleName": "",
"priority": 1,
"compressionType": {},
"optimizeHotUpdate": {},
"inlineSpriteFrames": {},
"isRemoteBundle": {},
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.3.5",
"uuid": "2303c16e-22bf-4edd-ae0d-44869fd75df0",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 105,
"height": 126,
"platformSettings": {},
"subMetas": {
"btn_1": {
"ver": "1.0.4",
"uuid": "0bf14665-ae47-49d9-8b19-1a0f3b38036e",
"rawTextureUuid": "2303c16e-22bf-4edd-ae0d-44869fd75df0",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 105,
"height": 126,
"rawWidth": 105,
"rawHeight": 126,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{
"ver": "2.3.5",
"uuid": "ad2bfb68-de98-4902-b035-3b40f23ebf2a",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 105,
"height": 126,
"platformSettings": {},
"subMetas": {
"btn_2": {
"ver": "1.0.4",
"uuid": "64df225a-c5d8-417e-b93a-06034a128796",
"rawTextureUuid": "ad2bfb68-de98-4902-b035-3b40f23ebf2a",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 105,
"height": 126,
"rawWidth": 105,
"rawHeight": 126,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{
"ver": "2.3.5",
"uuid": "58fe3a70-083e-4c83-892e-7685eba8c82b",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 105,
"height": 126,
"platformSettings": {},
"subMetas": {
"btn_3": {
"ver": "1.0.4",
"uuid": "e8ffef6e-2426-4de5-b185-2bd4ec3556a8",
"rawTextureUuid": "58fe3a70-083e-4c83-892e-7685eba8c82b",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 105,
"height": 126,
"rawWidth": 105,
"rawHeight": 126,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{
"ver": "2.3.5",
"uuid": "f94c6c62-0fb0-4d41-9fad-4b58136853ae",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 105,
"height": 126,
"platformSettings": {},
"subMetas": {
"btn_4": {
"ver": "1.0.4",
"uuid": "cad38fe3-a460-40bf-9b80-d57ee36ce2d6",
"rawTextureUuid": "f94c6c62-0fb0-4d41-9fad-4b58136853ae",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 105,
"height": 126,
"rawWidth": 105,
"rawHeight": 126,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{
"__type__": "cc.AnimationClip",
"_name": "ques_audio",
"_objFlags": 0,
"_native": "",
"_duration": 0.35,
"sample": 60,
"speed": 1,
"wrapMode": 2,
"curveData": {
"comps": {
"cc.Sprite": {
"spriteFrame": [
{
"frame": 0,
"value": {
"__uuid__": "0bf14665-ae47-49d9-8b19-1a0f3b38036e"
}
},
{
"frame": 0.08333333333333333,
"value": {
"__uuid__": "64df225a-c5d8-417e-b93a-06034a128796"
}
},
{
"frame": 0.16666666666666666,
"value": {
"__uuid__": "e8ffef6e-2426-4de5-b185-2bd4ec3556a8"
}
},
{
"frame": 0.25,
"value": {
"__uuid__": "cad38fe3-a460-40bf-9b80-d57ee36ce2d6"
}
},
{
"frame": 0.3333333333333333,
"value": {
"__uuid__": "0bf14665-ae47-49d9-8b19-1a0f3b38036e"
}
}
]
}
}
},
"events": []
}
\ No newline at end of file
{
"ver": "2.1.0",
"uuid": "802d460c-c4c2-4976-bbf0-14feb3750881",
"subMetas": {}
}
\ No newline at end of file
{
"ver": "1.1.2",
"uuid": "a7bae982-984d-487c-b12a-d53623796005",
"isBundle": false,
"bundleName": "",
"priority": 1,
"compressionType": {},
"optimizeHotUpdate": {},
"inlineSpriteFrames": {},
"isRemoteBundle": {},
"subMetas": {}
}
\ No newline at end of file
{
"__type__": "cc.AnimationClip",
"_name": "audio_big",
"_objFlags": 0,
"_native": "",
"_duration": 0.35,
"sample": 60,
"speed": 1,
"wrapMode": 2,
"curveData": {
"comps": {
"cc.Sprite": {
"spriteFrame": [
{
"frame": 0,
"value": {
"__uuid__": "62f365b3-09fd-40b6-8227-f0cc48d2ca4a"
}
},
{
"frame": 0.08333333333333333,
"value": {
"__uuid__": "bec42e56-98de-4cf2-afa0-20d383ba4758"
}
},
{
"frame": 0.16666666666666666,
"value": {
"__uuid__": "2e26f95f-430d-4f06-8124-9da0e739a9e0"
}
},
{
"frame": 0.25,
"value": {
"__uuid__": "47bfa6e9-d33a-4d8a-a261-6189176ee7b8"
}
},
{
"frame": 0.3333333333333333,
"value": {
"__uuid__": "62f365b3-09fd-40b6-8227-f0cc48d2ca4a"
}
}
]
}
}
},
"events": []
}
\ No newline at end of file
{
"ver": "2.1.0",
"uuid": "0dab7b62-6bff-451d-bce3-55f0509129f9",
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.3.5",
"uuid": "0c89dc58-eab0-43d4-92ee-c3affb960f50",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 162,
"height": 167,
"platformSettings": {},
"subMetas": {
"btn_tigan": {
"ver": "1.0.4",
"uuid": "62f365b3-09fd-40b6-8227-f0cc48d2ca4a",
"rawTextureUuid": "0c89dc58-eab0-43d4-92ee-c3affb960f50",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 162,
"height": 167,
"rawWidth": 162,
"rawHeight": 167,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{
"ver": "2.3.5",
"uuid": "5efc281d-c4f4-44fc-b0df-8c28d0047928",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 162,
"height": 167,
"platformSettings": {},
"subMetas": {
"btn_tigan2": {
"ver": "1.0.4",
"uuid": "bec42e56-98de-4cf2-afa0-20d383ba4758",
"rawTextureUuid": "5efc281d-c4f4-44fc-b0df-8c28d0047928",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 162,
"height": 167,
"rawWidth": 162,
"rawHeight": 167,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{
"ver": "2.3.5",
"uuid": "e3034287-f01f-418e-8a3b-eca9e25e065a",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 162,
"height": 167,
"platformSettings": {},
"subMetas": {
"btn_tigan3": {
"ver": "1.0.4",
"uuid": "2e26f95f-430d-4f06-8124-9da0e739a9e0",
"rawTextureUuid": "e3034287-f01f-418e-8a3b-eca9e25e065a",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 162,
"height": 167,
"rawWidth": 162,
"rawHeight": 167,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{
"ver": "2.3.5",
"uuid": "ddc293a8-9092-41af-978e-4f49fc801159",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 162,
"height": 167,
"platformSettings": {},
"subMetas": {
"btn_tigan4": {
"ver": "1.0.4",
"uuid": "47bfa6e9-d33a-4d8a-a261-6189176ee7b8",
"rawTextureUuid": "ddc293a8-9092-41af-978e-4f49fc801159",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 162,
"height": 167,
"rawWidth": 162,
"rawHeight": 167,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{
"ver": "1.1.2",
"uuid": "892ff52a-178d-4a9e-874c-b17a22eae615",
"isBundle": false,
"bundleName": "",
"priority": 1,
"compressionType": {},
"optimizeHotUpdate": {},
"inlineSpriteFrames": {},
"isRemoteBundle": {},
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "0af7f03b-039d-4ab2-b9a0-f4bd44320859",
"downloadMode": 0,
"duration": 1.776327,
"subMetas": {}
}
\ No newline at end of file
{ {
"ver": "2.0.1", "ver": "2.0.1",
"uuid": "f0680ae0-c079-45ef-abd7-9e63d90b982b", "uuid": "edc9bb14-e27c-4fd3-a87d-d4ea7a01f3b8",
"downloadMode": 0, "downloadMode": 0,
"duration": 0.130612, "duration": 0.130612,
"subMetas": {} "subMetas": {}
......
{
"ver": "2.0.1",
"uuid": "b5acb246-88ad-491b-acf4-3ad84f0bc84b",
"downloadMode": 0,
"duration": 4.04898,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "ae679fe2-69b2-45fd-a5f9-1c51f38cf077",
"downloadMode": 0,
"duration": 2.220408,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "4fa481d7-28d6-461c-919b-2d3c6a521dce",
"downloadMode": 0,
"duration": 0.173333,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "a262fe60-ad0a-4177-8075-70541510bdfd",
"downloadMode": 0,
"duration": 2.115917,
"subMetas": {}
}
\ No newline at end of file
{
"ver": "2.0.1",
"uuid": "58f5e868-6053-4ff9-a177-146b47bbf6ba",
"downloadMode": 0,
"duration": 0.264,
"subMetas": {}
}
\ No newline at end of file
{ {
"ver": "1.1.2", "ver": "1.1.2",
"uuid": "c35bb2f6-f24a-4850-ae44-643f2fdc7541", "uuid": "f9ff87df-13c3-4529-838a-93336988cede",
"isBundle": false, "isBundle": false,
"bundleName": "", "bundleName": "",
"priority": 1, "priority": 1,
......
This source diff could not be displayed because it is too large. You can view the blob instead.
{ {
"ver": "1.2.9", "ver": "1.2.9",
"uuid": "57ea7c61-9b8b-498a-b024-c98ee9124beb", "uuid": "5e0a03aa-9b9e-4076-b508-7dbf209bb115",
"asyncLoadAssets": false, "asyncLoadAssets": false,
"autoReleaseAssets": true, "autoReleaseAssets": true,
"subMetas": {} "subMetas": {}
......
{ {
"ver": "1.1.2", "ver": "1.1.2",
"uuid": "b0c008bc-cf92-463b-8360-0984e13c2e4d", "uuid": "0bdf31a9-a3f4-41ec-aa7c-f93ebd2f6505",
"isBundle": false, "isBundle": false,
"bundleName": "", "bundleName": "",
"priority": 1, "priority": 1,
......
// Learn cc.Class:
// - https://docs.cocos.com/creator/manual/en/scripting/class.html
// Learn Attribute:
// - https://docs.cocos.com/creator/manual/en/scripting/reference/attributes.html
// Learn life-cycle callbacks:
// - https://docs.cocos.com/creator/manual/en/scripting/life-cycle-callbacks.html
// import { getSprNode } from "./util";
import { getSprNode, playAudioByUrl, showBtnAnima, getScaleRateBy2Node, localPosTolocalPos, randomSortByArr, loadDragonBones, playAudio, showTrebleFirework, getSprNodeByUrl, setSprNodeMaxLen, delayCall, asyncDelay, RandomInt, exchangeNodePos} from "./util";
cc.Class({
extends: cc.Component,
properties: {
baseWidth: {
default: 1280,
type: cc.Integer
},
baseHeight: {
default: 720,
type: cc.Integer
}
},
onLoad() {
cc.debug.setDisplayStats(false);
this.initSceneData();
this.initSize();
},
initSceneData() {
this._imageResList = [];
this._audioResList = [];
this._animaResList = [];
},
_designSize: null,
_frameSize: null,
_mapScaleMin: null,
_mapScaleMax: null,
_cocosScale: null,
canvas: null,
initSize() {
// 注意cc.winSize只有在适配后(修改fitHeight/fitWidth后)才能获取到正确的值,因此使用cc.getFrameSize()来获取初始的屏幕大小
let screen_size = cc.view.getFrameSize().width / cc.view.getFrameSize().height
let design_size = cc.Canvas.instance.designResolution.width / cc.Canvas.instance.designResolution.height
let f = screen_size >= design_size
cc.Canvas.instance.fitHeight = f
cc.Canvas.instance.fitWidth = !f
const frameSize = cc.view.getFrameSize();
this._frameSize = frameSize;
this._designSize = cc.view.getDesignResolutionSize();
let sx = cc.winSize.width / frameSize.width;
let sy = cc.winSize.height / frameSize.height;
this._cocosScale = Math.min(sx, sy);
sx = frameSize.width / this._designSize.width;
sy = frameSize.height / this._designSize.height;
this._mapScaleMin = Math.min(sx, sy) * this._cocosScale;
this._mapScaleMax = Math.max(sx, sy) * this._cocosScale;
this.canvas = cc.find('Canvas');
// cc.log('cc.Canvas: ', cc.Canvas);
},
start() {
let getData = this.getData.bind(this);
if (window && window.courseware) {
getData = window.courseware.getData;
}
getData((data) => {
console.log('data:', data);
this.data = data || this.getDefaultData();
this.preloadItem()
})
},
_imageResList: null,
_audioResList: null,
_animaResList: null,
preloadItem() {
this.addPreloadImage();
this.addPreloadAudio();
this.addPreloadAnima();
this.preload();
},
getData(func) {
func(this.getDefaultData());
},
getDefaultData() {
const dataJson = '{"groupArr":[{"questionArr":[{"questionType":"pic","answerType":"text","answerArr":[{"text":"11111","pic_url":"","answerRight":"1","audio_url":"http://staging-teach.cdn.ireadabc.com/fbe2f23b9eb191a9330f99800e0d54d5.mp3"},{"text":"22222","pic_url":"","answerRight":"1"},{"text":"33 33333 ","pic_url":"","answerRight":"0","audio_url":"http://staging-teach.cdn.ireadabc.com/cf5077b8cbcaa1dc664df569d4af6043.mp3"},{"text":"444444","pic_url":"","answerRight":"0"}],"pic_url":"http://staging-teach.cdn.ireadabc.com/9d114554c4760ff35f1ff5479504a531.jpg","audio_url":"http://staging-teach.cdn.ireadabc.com/f51e3fedc88aa69a99f6ef579f7de047.mp3"}]},{"questionArr":[{"questionType":"text","answerType":"pic","answerArr":[{"text":"","pic_url":"http://staging-teach.cdn.ireadabc.com/fe229e6b32f385fb8fe5eb9ec5843c66.jpg","answerRight":"0","audio_url":"http://staging-teach.cdn.ireadabc.com/b39dfb2221c22175d3e8ac972923a82b.mp3"},{"text":"","pic_url":"http://staging-teach.cdn.ireadabc.com/9c5fa50efd7a004f24ea7fcbcf81080e.jpg","answerRight":"1","audio_url":"http://staging-teach.cdn.ireadabc.com/4293d4b1deb0389036434a1101a35178.mp3"}],"text":"a a aaaaaa aa a aaaa a a aaaaaaa aaaaa aaa aaaaaa.","audio_url":"http://staging-teach.cdn.ireadabc.com/0ee754beb094936dcbbc64ad6ee5c71c.mp3"},{"questionType":"video","answerType":"audio","answerArr":[{"text":"","pic_url":"","answerRight":"1","audio_url":"http://staging-teach.cdn.ireadabc.com/81c827cd941d1c5e4557569aa8153be7.mp3"},{"text":"","pic_url":"","answerRight":"0","audio_url":"http://staging-teach.cdn.ireadabc.com/3501f776900fe1e1a3b5f6302e156dd6.mp3"}],"video_url":"http://staging-teach.cdn.ireadabc.com/f309f8dd44d59c65e44f375f818871e1.mp4"}]},{"questionArr":[{"questionType":"audio","answerType":"text","answerArr":[{"text":"2222","pic_url":"","answerRight":"1","audio_url":"http://staging-teach.cdn.ireadabc.com/263d9cbaef7fbf251f9e3703130fb763.mp3"},{"text":"33333","pic_url":"","answerRight":"0","audio_url":"http://staging-teach.cdn.ireadabc.com/4edd6cd36d36dd5a16348db81044bda7.mp3"},{"text":"4444","pic_url":"","answerRight":"0"},{"text":"2324 234","pic_url":"","answerRight":"1"}],"audio_url":"http://staging-teach.cdn.ireadabc.com/e02d24c775a3f77c6967869435b11f7c.mp3"},{"questionType":"audio","answerType":"pic","answerArr":[{"text":"","pic_url":"http://staging-teach.cdn.ireadabc.com/9d114554c4760ff35f1ff5479504a531.jpg","answerRight":"1"},{"text":"","pic_url":"http://staging-teach.cdn.ireadabc.com/bf26f92e4f0557ad70ac27006855dae9.jpg","answerRight":"1","audio_url":"http://staging-teach.cdn.ireadabc.com/f51e3fedc88aa69a99f6ef579f7de047.mp3"},{"text":"","pic_url":"http://staging-teach.cdn.ireadabc.com/be8ec5cee7a3074440478b00a4a84f5e.png","answerRight":"0"},{"text":"","pic_url":"http://staging-teach.cdn.ireadabc.com/bd82aae5df96886a246106562015e496.png","answerRight":"0"}],"audio_url":"http://staging-teach.cdn.ireadabc.com/5de85e459a5e5df4823896d38e1066b9.mp3"},{"questionType":"audio","answerType":"audio","answerArr":[{"text":"","pic_url":"","answerRight":"1","audio_url":"http://staging-teach.cdn.ireadabc.com/28a42e3e77e023c8118624bb8351e7b2.mp3"},{"text":"","pic_url":"","answerRight":"1","audio_url":"http://staging-teach.cdn.ireadabc.com/4edd6cd36d36dd5a16348db81044bda7.mp3"},{"text":"","pic_url":"","answerRight":"0","audio_url":"http://staging-teach.cdn.ireadabc.com/263d9cbaef7fbf251f9e3703130fb763.mp3"}],"audio_url":"http://staging-teach.cdn.ireadabc.com/f51e3fedc88aa69a99f6ef579f7de047.mp3"}]}]}';
const data1 = JSON.parse(dataJson);
return data1;
const data = {
bgItem: {
rect: {
height: 380,
width: 675.56,
x: 160.72,
y: 0
},
// url: "http://staging-teach.cdn.ireadabc.com/b31c5881ea5f607c1d3540029a7d29c7.png"
url: "http://staging-teach.cdn.ireadabc.com/756b0a8de4cb84ed70e70d60f87a5901.jpg"
},
hotZoneItemArr: [
{
id: 1595919608244,
imgScale: 1,
index: 0,
itemType: "rect",
mapScale: 0.903125,
rect: {
height: 120.84,
width: 115.99,
x: 378.68,
y: 191.3
},
skeJsonData: {
name: "finish1_ske.json",
url: "http://staging-teach.cdn.ireadabc.com/bd825dcceea298d1146be8067ae3d17f.json"
},
texJsonData: {
name: "finish1_tex.json",
url: "http://staging-teach.cdn.ireadabc.com/246f8991b729fa3e5a7f4802de828efa.json"
},
texPngData: {
name: "finish1_tex.png",
url: "http://staging-teach.cdn.ireadabc.com/5a0c5af3e952acd0ac83a6e5c6f03ff1.png"
}
}
],
picArr: [
{
audio_url: "http://staging-teach.cdn.ireadabc.com/0128a59057e63c4c6b4b96556d077a98.mp3",
pic_url: "http://staging-teach.cdn.ireadabc.com/18f2a029e02d679da8d42746daea228f.png",
text: "1111",
}
]
}
data.picArr = data.picArr.concat(data.picArr);
data.picArr = data.picArr.concat(data.picArr);
data.picArr = data.picArr.concat(data.picArr);
data.picArr = data.picArr.concat(data.picArr);
data.picArr = data.picArr.concat(data.picArr);
return data;
},
preload() {
const preloadArr = this._imageResList.concat(this._audioResList).concat(this._animaResList);
cc.assetManager.loadAny(preloadArr, null, null, (err, data) => {
// console.log(' preload data, ', data);
this.loadEnd();
if (window && window["air"]) {
window["air"].hideAirClassLoading();
}
});
},
addPreloadImage() {
if (this.data.pic_url) {
this._imageResList.push({ url: this.data.pic_url });
}
if (this.data.bgItem) {
this._imageResList.push({ url: this.data.bgItem.url });
}
if (!this.data.hotZoneItemArr) {
return;
}
this.data.hotZoneItemArr.forEach((item) => {
if (item.pic_url) {
this._imageResList.push({ url: item.pic_url });
}
})
},
addPreloadAudio() {
if (this.data.questionArr) {
const arr = this.data.questionArr;
for (let i=0 ;i<arr.length; i++) {
this._audioResList.push({url: arr[i].audio_url || ''});
this._audioResList.push({url: arr[i].video_url || ''});
}
}
},
addPreloadAnima() {
if (!this.data.hotZoneItemArr) {
return;
}
this.data.hotZoneItemArr.forEach((item) => {
if (item.skeJsonData) {
this._animaResList.push({ url: item.skeJsonData.url || '' });
this._animaResList.push({ url: item.texJsonData.url || ''});
this._animaResList.push({ url: item.texPngData.url || ''});
}
})
},
loadEnd() {
this.initData();
this.initView();
// this.initMusic();
},
initMusic() {
cc.assetManager.loadRemote(this.data.bg_audio_url, (err, clip) => {
cc.audioEngine.setMusicVolume(0.3);
const audioID = cc.audioEngine.playMusic(clip, true);
});
},
curGroupIndex: null,
curQuestionIndex: null,
curQuestionData: null,
initData() {
this.curGroupIndex = 0;
this.curQuestionIndex = 0;
this.setCurGroupAndQuestion()
console.log('this.curQuestionData', this.curQuestionData)
this.initAudioEffect();
},
curGroup: null,
setCurGroupAndQuestion() {
this.curGroup = this.data.groupArr[this.curGroupIndex];
if (!this.curGroup) {
this.gameEnd();
} else {
this.curQuestionIndex = 0;
this.setCurQuestionData();
}
},
setCurQuestionData() {
this.curQuestionData = this.curGroup.questionArr[this.curQuestionIndex];
if (!this.curQuestionData) {
this.hideVideo();
this.showBigStar();
}
},
hideVideo() {
this.videoNode.active = false;
this.videoNode.player.pause();
this.videoNode.pauseBtn.active = false;
this.videoNode.playBtn.active = true;
},
rightClip: null,
wrongClip: null,
bigStarClip: null,
btnClip: null,
finishClip: null,
selectClip: null,
starCountClip: null,
initAudioEffect() {
this.rightClip = cc.find('Canvas/res/audio/right').getComponent(cc.AudioSource).clip;
this.wrongClip = cc.find('Canvas/res/audio/wrong').getComponent(cc.AudioSource).clip;
this.bigStarClip = cc.find('Canvas/res/audio/big_star').getComponent(cc.AudioSource).clip;
this.btnClip = cc.find('Canvas/res/audio/btn').getComponent(cc.AudioSource).clip;
this.finishClip = cc.find('Canvas/res/audio/finish').getComponent(cc.AudioSource).clip;
this.selectClip = cc.find('Canvas/res/audio/select').getComponent(cc.AudioSource).clip;
this.starCountClip = cc.find('Canvas/res/audio/star_count').getComponent(cc.AudioSource).clip;
},
initView() {
this.initQuestion();
this.initOption();
this.initBtn();
this.initIcon();
this.initMask();
this.setCurQuestion();
this.setCurOption();
this.initStar();
},
bigStarArr: null,
initStar() {
const gArr = this.data.groupArr;
if (gArr.length <= 1) {
return;
}
this.cleanStar();
this.bigStarArr = [];
let baseX = this.canvas.width / 2 - 80 * this._mapScaleMin;
let baseY = this.canvas.height / 2 - 80 * this._mapScaleMin;
let disH = 80 * this._mapScaleMin;
let disScale = 1;
if (gArr.length > 5) {
disH = (400 / gArr.length) * this._mapScaleMin;
disScale = 5 / gArr.length;
}
for (let i = 0; i < gArr.length; i++) {
const starBg = getSprNode('star_bg');
this.canvas.addChild(starBg, 10);
starBg.x = baseX;
starBg.y = baseY - i * disH;
starBg.scale = disScale;
const starTop = getSprNode('star');
starBg.addChild(starTop);
starTop.active = false;
starBg.star = starTop;
const starBig = getSprNode('icon_bigstar');
starTop.addChild(starBig);
starBig.angle = -90;
starBg.starBig = starBig;
this.bigStarArr.push(starBg);
}
console.log("bigStarArr: ", this.bigStarArr);
},
cleanStar() {
if (this.bigStarArr && this.bigStarArr.length > 0) {
for (let i=0; i<this.bigStarArr.length; i++) {
this.bigStarArr[i].removeFromParent();
}
}
},
showBigStar() {
if (!this.bigStarArr || this.bigStarArr.length <= 0) {
this.checkGameEnd();
return;
}
const bigStarBg = this.bigStarArr[this.curGroupIndex];
const starBig = bigStarBg.starBig;
starBig.scale = 1;
const star = bigStarBg.star;
star.active = true;
star.scaleX = 0.7 / bigStarBg.scale;
star.scaleY = 1 / bigStarBg.scale;
star.angle = 90;
const canvas = cc.find('Canvas');
const startPos = exchangeNodePos(star.parent, canvas, cc.v2(0, -canvas.height / 2));
const middlePos = exchangeNodePos(star.parent, canvas, cc.v2(0, -canvas.height / 4));
star.x = startPos.x;
star.y = startPos.y - starBig.height;
console.log('middlePos = ' + JSON.stringify(middlePos));
const time = 1;
cc.tween(star)
.to(0.3, { y: middlePos.y + 80 }, { easing: 'quadOut' })
.to(0.1, { y: middlePos.y + 40, scaleX: 1.2 / bigStarBg.scale, scaleY: 0.8 / bigStarBg.scale }, { easing: 'quadOut' })
.to(0.1, { y: middlePos.y, scaleX: 1 / bigStarBg.scale, scaleY: 1 / bigStarBg.scale }, { easing: 'quadOut' })
.delay(0.1)
.to(0.8, { angle: -720, scale: 1 })
.start();
cc.tween(star)
.delay(0.6)
.to(0.8, { x: 0 }, { easing: 'quadIn' })
.start();
cc.tween(star)
.delay(0.6)
.to(0.8, { y: 0 }, { easing: 'quadOut' })
.start();
cc.tween(starBig)
.delay(0.6)
.to(0.8, { scale: 0 }, { easing: 'quadOut' })
.call(() => {
this.checkGameEnd();
playAudio(this.starCountClip);
})
.start();
playAudio(this.bigStarClip);
},
checkGameEnd() {
this.curGroupIndex ++;
this.setCurGroupAndQuestion();
if (!this.curQuestionData) {
// this.gameEnd();
return;
}
this.showChangeQuesAnim();
},
checkBtn: null,
initBtn() {
const checkBtn = getSprNode("btn_check");
checkBtn.scale = this._mapScaleMin;
this.canvas.addChild(checkBtn);
checkBtn.x = -500 * this._mapScaleMin;
checkBtn.y = -35 * this._mapScaleMin;
checkBtn.baseX = checkBtn.x;
checkBtn.baseY = checkBtn.y;
checkBtn.opacity = 0;
this.checkBtn = checkBtn;
checkBtn.on(cc.Node.EventType.TOUCH_START, () => {
if (checkBtn.opacity == 0) {
return;
}
showBtnAnima(checkBtn);
this.checkBtnClick();
})
},
refreshCheckBtn() {
this.checkBtn.opacity = 0;
const arr = this.curOptionArr;
for (let i=0; i<arr.length; i++) {
if (arr[i].light.opacity > 254) {
this.checkBtn.opacity = 255;
return;
}
}
},
tryagain: null,
initIcon() {
const icon = getSprNode("try_again");
icon.opacity = 0;
icon.scale = this._mapScaleMin;
this.canvas.addChild(icon);
this.tryagain = icon;
},
showTryAgain() {
const time = 0.3;
cc.tween(this.tryagain)
.to(time, {opacity: 255}, {easing: "cubicOut"})
.delay(0.3)
.to(time, {opacity: 0}, {easing: "cubicIn"})
.start();
},
initQuestion() {
this.initPicQuestion();
this.initTextQuestion();
this.initVideoQuestion();
this.initAudioQuestion();
},
quesPicBg: null,
initPicQuestion() {
const picBg = getSprNode("ques_pic_bg");
this.canvas.addChild(picBg);
picBg.scale = this._mapScaleMin;
picBg.y = 130 * this._mapScaleMin
this.quesPicBg = picBg;
picBg.active = false;
this.addQuesAudio(picBg)
},
quesTextBg: null,
initTextQuestion() {
const picBg = getSprNode("ques_pic_bg");
this.canvas.addChild(picBg);
picBg.scale = this._mapScaleMin;
picBg.y = 130 * this._mapScaleMin
this.quesTextBg = picBg;
const labelNode = new cc.Node();
labelNode.parent = picBg;
const label = labelNode.addComponent(cc.RichText);
const size = 80
label.font = cc.find('Canvas/res/font/Berlin-Sans-FB').getComponent(cc.Label).font;
// label.string = `<outline color=#a83c13 width=2><size=${size}><color=#ffffff>${this.data.title || " " }</color></size></outline>`
// label.string = `<size=${size}><color=#751e00>${this.curGroup.title }</color></size>`
label.lineHeight = size;
label.horizontalAlign = cc.macro.TextAlignment.CENTER
label.maxWidth = 648;
picBg.label = label;
picBg.active = false;
this.addQuesAudio(picBg)
},
quesVideoBg: null,
videoNode: null,
initVideoQuestion() {
const picBg = getSprNode("ques_pic_bg");
this.canvas.addChild(picBg);
picBg.scale = this._mapScaleMin;
picBg.y = 130 * this._mapScaleMin
this.quesVideoBg = picBg;
const videoNode = new cc.Node();
const vPlayer = videoNode.addComponent(cc.VideoPlayer);
picBg.addChild(videoNode);
videoNode.width = 678;
videoNode.height = 396;
this.videoNode = videoNode;
picBg.video = vPlayer;
const btnNode = new cc.Node();
picBg.addChild(btnNode);
btnNode.x = picBg.width / 2 + 50;
const playBtn = getSprNode("video_play");
btnNode.addChild(playBtn);
const pauseBtn = getSprNode("video_pause");
btnNode.addChild(pauseBtn);
pauseBtn.active = false;
videoNode.player = vPlayer;
videoNode.playBtn = playBtn;
videoNode.pauseBtn = pauseBtn;
playBtn.on(cc.Node.EventType.TOUCH_START, () => {
vPlayer.play();
playBtn.active = false;
pauseBtn.active = true;
})
pauseBtn.on(cc.Node.EventType.TOUCH_START, () => {
vPlayer.pause();
pauseBtn.active = false;
playBtn.active = true;
})
videoNode.on('completed', () => {
pauseBtn.active = false;
playBtn.active = true;
})
picBg.active = false;
},
quesAudioBg: null,
initAudioQuestion() {
const audioNode = new cc.Node();
audioNode.active = false;
this.canvas.addChild(audioNode);
audioNode.x = 440 * this._mapScaleMin;
audioNode.y = -60 * this._mapScaleMin;
this.quesAudioBg = audioNode;
const audioAnimNode = cc.instantiate(cc.find("Canvas/res/anim/audio_big"));
audioNode.addChild(audioAnimNode);
const iconTop = getSprNode('audio_big')
audioNode.addChild(iconTop);
iconTop.opacity = 255;
iconTop.addComponent(cc.BlockInputEvents);
iconTop.on(cc.Node.EventType.TOUCH_START, () => {
if (iconTop.opacity == 0) {
return;
}
if (!audioNode.audioClip) {
return;
}
const anim = audioAnimNode.getComponent(cc.Animation);
anim.play('audio_big');
iconTop.opacity = 0;
audioAnimNode.opacity = 255;
if (audioNode.audioClip) {
playAudio(audioNode.audioClip, () => {
iconTop.opacity = 255;
audioAnimNode.opacity = 0;
anim.stop();
});
}
})
},
addQuesAudio(bg) {
const audioNode = new cc.Node();
bg.addChild(audioNode);
audioNode.x = bg.width / 2 + 50;
const audioAnimNode = cc.instantiate(cc.find("Canvas/res/anim/ques_audio"));
audioNode.addChild(audioAnimNode);
const iconTop = getSprNode('ques_audio')
audioNode.addChild(iconTop);
iconTop.opacity = 255;
iconTop.addComponent(cc.BlockInputEvents);
iconTop.on(cc.Node.EventType.TOUCH_START, () => {
if (iconTop.opacity == 0) {
return;
}
const anim = audioAnimNode.getComponent(cc.Animation);
anim.play('ques_audio');
iconTop.opacity = 0;
audioAnimNode.opacity = 255;
if (audioNode.audioClip) {
playAudio(audioNode.audioClip, () => {
iconTop.opacity = 255;
audioAnimNode.opacity = 0;
anim.stop();
});
}
})
bg.audioNode = audioNode;
},
initOption() {
this.initPicOption();
this.initAudioOption();
this.initTextOption();
this.initPicOptionBig();
this.initAudioOptionBig();
this.initTextOptionBig();
},
optionPicBgArr: null,
initPicOption() {
// console.log('this.data: ', this.data);
this.optionPicBgArr = [];
for (let i=0; i<4; i++) {
const pic = this.getOnePicOption();
this.canvas.addChild(pic);
pic.scale = this._mapScaleMin;
pic.y = -235 * this._mapScaleMin;
this.optionPicBgArr.push(pic);
}
},
optionPicBgBigArr: null,
initPicOptionBig() {
this.optionPicBgBigArr = [];
const baseX = -380 * this._mapScaleMin;
const disW = 440 * this._mapScaleMin;
let baseY = 170 * this._mapScaleMin;
const disH = 350 * this._mapScaleMin;
let count = 0;
for (let i=0; i<4; i++) {
if (i==2) {
count = 0;
baseY -= disH;
}
const pic = this.getOnePicOption(true);
this.canvas.addChild(pic);
pic.scale = this._mapScaleMin;
pic.x = baseX + count * disW;
pic.y = baseY;
this.optionPicBgBigArr.push(pic);
count ++;
}
},
getOnePicOption(isBig = false) {
const picBgParent = new cc.Node();
let lightResName = "option_pic_bg_l";
let bgResName = "option_pic_bg";
if (isBig) {
lightResName = "op_pic_bg_big_l";
bgResName = "op_pic_bg_big";
}
const light = getSprNode(lightResName);
picBgParent.addChild(light);
light.opacity = 0;
picBgParent.light = light;
const picBg = getSprNode(bgResName);
picBgParent.addChild(picBg);
picBgParent.picBg = picBg;
picBgParent.width = picBg.width;
picBgParent.height = picBg.height;
const soundNode = new cc.Node();
picBgParent.addChild(soundNode);
picBgParent.soundIcon = soundNode;
const soundIconAnim = cc.instantiate(cc.find("Canvas/res/anim/laba"))
soundNode.addChild(soundIconAnim);
soundIconAnim.opacity = 0;
const soundIconTop = getSprNode('btn_laba')
soundNode.addChild(soundIconTop);
soundIconTop.opacity = 255;
soundNode.x = picBgParent.width / 2 - soundIconTop.width / 2;
soundNode.y = picBgParent.height / 2 //- soundIconTop.height / 2;
soundNode.active = false;
picBgParent.active = false;
picBgParent.on(cc.Node.EventType.TOUCH_START, () => {
if( light.opacity == 0 ) {
light.opacity = 255;
playAudio(this.selectClip);
} else {
light.opacity = 0;
}
this.refreshCheckBtn();
})
soundIconTop.addComponent(cc.BlockInputEvents);
soundIconTop.on(cc.Node.EventType.TOUCH_START, () => {
const anim = soundIconAnim.getComponent(cc.Animation);
anim.play('laba');
soundIconTop.opacity = 0;
soundIconAnim.opacity = 255;
if (soundNode.audioClip) {
playAudio(soundNode.audioClip, () => {
soundIconTop.opacity = 255;
soundIconAnim.opacity = 0;
anim.stop();
});
}
})
return picBgParent;
},
addIconRight(bg) {
const px = bg.width / 2;
const py = -bg.height / 2 ;
const worldPos = bg.convertToWorldSpaceAR(cc.v2(px, py));
const localPos = this.canvas.convertToNodeSpaceAR(worldPos);
const iconRight = getSprNode('icon_right');
iconRight.scale = this._mapScaleMin;
this.canvas.addChild(iconRight, 1);
iconRight.x = localPos.x;
iconRight.y = localPos.y + 50 * this._mapScaleMin;
bg.iconRight = iconRight;
this.showOneFirework(cc.v2(0, -bg.height / 3), bg, cc.find('paperBase').children, 200, 300, 20, 1);
},
optionAudioBgArr: null,
initAudioOption() {
this.optionAudioBgArr = [];
for (let i=0; i<4; i++) {
const audio = this.getOneAudioOption();
this.canvas.addChild(audio);
audio.scale = this._mapScaleMin;
audio.y = -235 * this._mapScaleMin;
this.optionAudioBgArr.push(audio);
}
},
optionAudioBgBigArr: null,
initAudioOptionBig() {
this.optionAudioBgBigArr = [];
const baseX = -380 * this._mapScaleMin;
const disW = 440 * this._mapScaleMin;
let baseY = 170 * this._mapScaleMin;
const disH = 350 * this._mapScaleMin;
let count = 0;
for (let i=0; i<4; i++) {
if (i==2) {
count = 0;
baseY -= disH;
}
const audio = this.getOneAudioOption(true);
this.canvas.addChild(audio);
audio.scale = this._mapScaleMin;
audio.x = baseX + count * disW;
audio.y = baseY;
this.optionAudioBgBigArr.push(audio);
count ++;
}
},
optionTextBgArr: null,
initTextOption() {
this.optionTextBgArr = [];
for (let i=0; i<4; i++) {
const textOption = this.getOneTextOption();
this.canvas.addChild(textOption);
textOption.scale = this._mapScaleMin;
// textOption.y = -235 * this._mapScaleMin;
this.optionTextBgArr.push(textOption);
}
},
optionTextBgBigArr: null,
initTextOptionBig() {
const baseX = -180 * this._mapScaleMin;
const disW = 100 * this._mapScaleMin;
let baseY = 220 * this._mapScaleMin;
const disH = 150 * this._mapScaleMin;
this.optionTextBgBigArr = [];
for (let i=0; i<4; i++) {
const textOption = this.getOneTextOption(true);
this.canvas.addChild(textOption);
textOption.scale = this._mapScaleMin;
textOption.x = baseX;
textOption.y = baseY - i * disH;
this.optionTextBgBigArr.push(textOption);
}
},
getOneAudioOption(isBig=false) {
let lightResName = "option_pic_bg_l";
let bgResName = "option_pic_bg";
if (isBig) {
lightResName = "op_pic_bg_big_l";
bgResName = "op_pic_bg_big";
}
const audioBgNode = new cc.Node();
const light = getSprNode(lightResName);
audioBgNode.addChild(light);
light.opacity = 0;
audioBgNode.light = light;
const picBg = getSprNode(bgResName);
audioBgNode.addChild(picBg);
audioBgNode.picBg = picBg;
audioBgNode.width = picBg.width;
audioBgNode.height = picBg.height;
const animNode = cc.instantiate(cc.find("Canvas/res/anim/op_audio"))
audioBgNode.addChild(animNode);
animNode.anchorX = 0.6;
const animTop = getSprNode('op_audio');
audioBgNode.addChild(animTop);
animTop.anchorX = 0.6;
const anim = animNode.getComponent(cc.Animation);
animNode.opacity = 0;
audioBgNode.anim = anim;
audioBgNode.animNode = animNode;
audioBgNode.animTop = animTop;
audioBgNode.showAnim = () => {
this.playItemAnim(audioBgNode);
cc.audioEngine.stop(audioBgNode.audioId);
}
audioBgNode.stopAnim = () => {
cc.audioEngine.stop(audioBgNode.audioId);
this.stopItemAnim(audioBgNode);
}
audioBgNode.on(cc.Node.EventType.TOUCH_START, () => {
if( light.opacity == 0 ) {
light.opacity = 255;
playAudio(this.selectClip);
audioBgNode.showAnim();
if (audioBgNode.audioClip) {
audioBgNode.audioId = playAudio(audioBgNode.audioClip, () => {
this.stopItemAnim(audioBgNode);
});
}
} else {
light.opacity = 0;
audioBgNode.stopAnim();
}
this.refreshCheckBtn();
});
audioBgNode.active = false;
return audioBgNode;
},
getOneTextOption(isBig=false) {
let lightResName = "option_text_bg_l";
let bgResName = "option_text_bg";
if (isBig) {
lightResName = "op_text_bg_big_l";
bgResName = "op_text_bg_big";
}
const textBgParent = new cc.Node();
textBgParent.active = false;
const light = getSprNode(lightResName);
textBgParent.addChild(light);
light.opacity = 0;
textBgParent.light = light;
const textBg = getSprNode(bgResName);
textBgParent.addChild(textBg);
textBgParent.textBg = textBg;
textBgParent.width = textBg.width;
textBgParent.height = textBg.height;
const labelNode = new cc.Node();
labelNode.parent = textBgParent;
const label = labelNode.addComponent(cc.Label);
label.fontSize = 56;
label.lineHeight = 56;
if (isBig) {
label.fontSize = 64;
label.lineHeight = 64;
}
label.font = cc.find('Canvas/res/font/Berlin-Sans-FB').getComponent(cc.Label).font;
textBgParent.label = label;
const color = new cc.Color();
cc.Color.fromHEX(color, '#023659' );
labelNode.color = color;
const soundNode = new cc.Node();
textBgParent.addChild(soundNode);
textBgParent.soundIcon = soundNode;
const soundIconAnim = cc.instantiate(cc.find("Canvas/res/anim/laba"))
soundNode.addChild(soundIconAnim);
soundIconAnim.opacity = 0;
const soundIconTop = getSprNode('btn_laba')
soundNode.addChild(soundIconTop);
soundIconTop.opacity = 255;
soundNode.x = textBgParent.width / 2 - 15; // - soundIconTop.width / 2;
soundNode.y = textBgParent.height / 2 - 15; //- soundIconTop.height / 2;
soundNode.active = false;
textBgParent.on(cc.Node.EventType.TOUCH_START, () => {
if( light.opacity == 0 ) {
light.opacity = 255;
playAudio(this.selectClip);
} else {
light.opacity = 0;
}
this.refreshCheckBtn();
})
soundIconTop.addComponent(cc.BlockInputEvents);
soundIconTop.on(cc.Node.EventType.TOUCH_START, () => {
const anim = soundIconAnim.getComponent(cc.Animation);
anim.play('laba');
soundIconTop.opacity = 0;
soundIconAnim.opacity = 255;
if (soundNode.audioClip) {
playAudio(soundNode.audioClip, () => {
soundIconTop.opacity = 255;
soundIconAnim.opacity = 0;
anim.stop();
});
}
})
return textBgParent;
},
playItemAnim(item) {
item.anim.play();
item.animNode.opacity = 255;
item.animTop.opacity = 0;
},
stopItemAnim(item) {
item.animNode.opacity = 0;
item.animTop.opacity = 255;
},
setCurQuestion() {
switch(this.curQuestionData.questionType) {
case "pic":
this.setQuestionPic();
break;
case "text":
this.setQuestionText();
break;
case "video":
this.setQuestionVideo();
break;
case "audio":
this.setQuestionAudio();
break;
}
this.refreshCheckBtnPos();
},
refreshCheckBtnPos() {
if (this.curQuestionData.questionType == 'audio') {
this.checkBtn.x = 440 * this._mapScaleMin;
this.checkBtn.y = -240 * this._mapScaleMin;
} else {
this.checkBtn.x = this.checkBtn.baseX;
this.checkBtn.y = this.checkBtn.baseY;
}
},
curQuesBg: null,
setQuestionPic() {
this.curQuesBg = this.quesPicBg;
this.curQuesBg.active = true;
if (this.quesPicBg.pic) {
this.quesPicBg.pic.removeFromParent();
this.quesPicBg.pic = null;
}
if (this.curQuestionData.pic_url) {
getSprNodeByUrl(this.curQuestionData.pic_url, (spr) => {
const sprNode = spr.node;
setSprNodeMaxLen(sprNode, 678, 396);
this.quesPicBg.addChild(sprNode)
this.quesPicBg.pic = sprNode;
})
}
const audioNode = this.quesPicBg.audioNode;
audioNode.active = false;
audioNode.audioClip = null;
if (this.curQuestionData.audio_url) {
cc.assetManager.loadRemote(this.curQuestionData.audio_url, (err, audioClip) => {
audioNode.audioClip = audioClip;
});
audioNode.active = true;
}
},
setQuestionText() {
this.curQuesBg = this.quesTextBg;
this.curQuesBg.active = true;
const label = this.curQuesBg.label;
const size = 80;
label.string = `<size=${size}><color=#fff4b6>${this.curQuestionData.text}</color></size>`
const audioNode = this.curQuesBg.audioNode;
audioNode.active = false;
audioNode.audioClip = null;
if (this.curQuestionData.audio_url) {
cc.assetManager.loadRemote(this.curQuestionData.audio_url, (err, audioClip) => {
audioNode.audioClip = audioClip;
});
audioNode.active = true;
}
},
setQuestionVideo() {
this.curQuesBg = this.quesVideoBg;
this.curQuesBg.active = true;
this.videoNode.active = true;
if (this.curQuestionData.video_url) {
this.curQuesBg.video.remoteURL = this.curQuestionData.video_url;
}
},
setQuestionAudio() {
this.curQuesBg = this.quesAudioBg;
this.curQuesBg.active = true;
this.curQuesBg.audioClip = null;
if (this.curQuestionData.audio_url) {
cc.assetManager.loadRemote(this.curQuestionData.audio_url, (err, audioClip) => {
this.curQuesBg.audioClip = audioClip;
});
}
},
setCurOption() {
const arr = this.curQuestionData.answerArr;
const isBig = this.curQuestionData.questionType == 'audio';
switch(this.curQuestionData.answerType) {
case "pic":
this.setOptionPic(arr, isBig);
break;
case "audio":
this.setOptionAudio(arr, isBig);
break;
case "text":
this.setOptionText(arr, isBig);
break;
}
},
curOptionArr: null,
setOptionPic(arr, isBig=false) {
let opItemArr = this.optionPicBgArr;
if (isBig) {
opItemArr = this.optionPicBgBigArr;
}
this.curOptionArr = [];
const disW = 158 * this._mapScaleMin;
const baseX = -(arr.length - 1) * disW;
for (let i=0; i<arr.length; i++) {
opItemArr[i].active = true;
if (!isBig) {
opItemArr[i].x = baseX + i * disW * 2;
}
const picBg = opItemArr[i].picBg;
picBg.removeAllChildren();
const data = arr[i];
if (data.pic_url) {
getSprNodeByUrl, getSprNodeByUrl(data.pic_url, (spr) => {
let maxW = 280;
let maxH = 190;
if (isBig) {
maxW = 366;
maxH = 248;
}
setSprNodeMaxLen(spr.node, maxW, maxH);
console.log('spr: ', spr);
picBg.addChild(spr.node);
})
}
const soundIcon = opItemArr[i].soundIcon;
soundIcon.active = false;
soundIcon.audioClip = null;
opItemArr[i].audioClip = null;
if (data.audio_url) {
cc.assetManager.loadRemote(data.audio_url, (err, audioClip) => {
soundIcon.audioClip = audioClip;
opItemArr[i].audioClip = audioClip;
});
soundIcon.active = true;
}
opItemArr[i].data = data;
this.curOptionArr.push(opItemArr[i]);
}
},
setOptionAudio(arr, isBig=false) {
let opItemArr = this.optionAudioBgArr;
if (isBig) {
opItemArr = this.optionAudioBgBigArr;
}
this.curOptionArr = [];
const disW = 158 * this._mapScaleMin;
const baseX = -(arr.length - 1) * disW;
for (let i=0; i<arr.length; i++) {
opItemArr[i].active = true;
if(!isBig) {
opItemArr[i].x = baseX + i * disW * 2;
}
const data = arr[i];
opItemArr[i].audioClip = null;
if (data.audio_url) {
cc.assetManager.loadRemote(data.audio_url, (err, audioClip) => {
opItemArr[i].audioClip = audioClip;
});
}
opItemArr[i].data = data;
this.curOptionArr.push(opItemArr[i]);
}
},
setOptionAudioBig(arr) {
this.curOptionArr = [];
for (let i=0; i<arr.length; i++) {
this.optionAudioBgArr[i].active = true;
const data = arr[i];
this.optionAudioBgArr[i].audioClip = null;
if (data.audio_url) {
cc.assetManager.loadRemote(data.audio_url, (err, audioClip) => {
this.optionAudioBgArr[i].audioClip = audioClip;
});
}
this.optionAudioBgArr[i].data = data;
this.curOptionArr.push(this.optionAudioBgArr[i]);
}
},
setOptionText(arr, isBig=false) {
console.log(' in setOptionText, isBig: ', isBig);
let opItemArr = this.optionTextBgArr;
if (isBig) {
opItemArr = this.optionTextBgBigArr
}
this.curOptionArr = [];
const disW = 315 * this._mapScaleMin;
const disH = 120 * this._mapScaleMin;
const baseX = - disW ;
let baseY = -235 * this._mapScaleMin;
if (arr.length > 2) {
baseY = -170 * this._mapScaleMin;
}
let count = 0;
for (let i=0; i<arr.length; i++) {
if (i == 2) {
baseY -= disH;
count = 0;
}
opItemArr[i].active = true;
if (!isBig) {
opItemArr[i].x = baseX + count * disW * 2;
opItemArr[i].y = baseY;
}
opItemArr[i].label.string = arr[i].text;
opItemArr[i].label["_forceUpdateRenderData"](true);
if (opItemArr[i].label.node.width > opItemArr[i].width * 0.9) {
opItemArr[i].label.node.scale = opItemArr[i].width * 0.9 / opItemArr[i].label.node.width;
} else {
opItemArr[i].label.node.scale = 1;
}
const data = arr[i];
const soundIcon = opItemArr[i].soundIcon;
soundIcon.active = false;
soundIcon.audioClip = null;
opItemArr[i].audioClip = null;
if (data.audio_url) {
cc.assetManager.loadRemote(data.audio_url, (err, audioClip) => {
soundIcon.audioClip = audioClip;
opItemArr[i].audioClip = audioClip;
});
soundIcon.active = true;
}
opItemArr[i].data = data;
this.curOptionArr.push(opItemArr[i]);
count++;
}
},
shakeArr: null,
wrongArr: null,
checkBtnClick() {
this.shakeArr = [];
this.wrongArr = [];
this.checkItemWrong();
if (this.wrongArr.length > 0) {
//有选错的
this.itemShake();
this.hideLight();
playAudio(this.wrongClip);
return;
}
const isRightAll = this.checkItemRightCount();
if (!isRightAll) {
// 有漏选的
this.itemShake();
this.hideLight();
playAudio(this.wrongClip);
return;
}
this.showAllRight();
this.showMask();
playAudio(this.rightClip, () => {
this.playAnswerAudio(0);
})
},
playAnswerAudio(index) {
const arr = this.curOptionArr;
if (!arr[index]) {
// delayCall(0.5, () => {
this.changeNextQuestion();
// })
} else {
if ( arr[index].light.opacity > 254 && arr[index].audioClip ) {
playAudio(arr[index].audioClip, () => {
this.playAnswerAudio(index + 1);
})
} else {
this.playAnswerAudio(index + 1);
}
}
},
checkItemWrong() {
const arr = this.curOptionArr;
console.log('arr: ', arr);
for (let i=0; i<arr.length; i++) {
const itemBg = arr[i];
if (itemBg.light.opacity >= 254) {
this.shakeArr.push(itemBg);
console.log('aaa', itemBg.data);;
if (itemBg.data.answerRight == '0') {
this.wrongArr.push(itemBg);
}
}
}
},
checkItemRightCount() {
let rightTotalCount = 0;
const answerArr = this.curQuestionData.answerArr;
for (let i=0; i<answerArr.length; i++) {
if (answerArr[i].answerRight == '1') {
rightTotalCount ++;
}
}
let curRightCount = 0;
const curOptionArr = this.curOptionArr;
for (let i=0; i<curOptionArr.length; i++) {
if (curOptionArr[i].light.opacity > 254) {
curRightCount ++;
}
}
return rightTotalCount == curRightCount;
},
itemShake() {
let rate = 1;
if (this.curQuestionData.answerType == 'text') {
rate = 0.5;
}
const arr = this.shakeArr;
for (let i=0; i<arr.length; i++) {
this.rotateShake(arr[i], rate);
if (arr[i].stopAnim) {
arr[i].stopAnim();
}
}
this.showTryAgain();
},
hideLight() {
const arr = this.curOptionArr;
for (let i=0; i<arr.length; i++) {
arr[i].light.opacity = 0;
}
this.checkBtn.opacity = 0;
},
rotateShake(item, rate = 1) {
const time = 0.9;
cc.tween(item)
.to(time / 6 / 2, {angle: -20 * rate}, {easing: 'sineInOut'})
.to(time / 6, {angle: 12 * rate}, {easing: 'sineInOut'})
.to(time / 6, {angle: -7 * rate}, {easing: 'sineInOut'})
.to(time / 6, {angle: 4 * rate}, {easing: 'sineInOut'})
.to(time / 6, {angle: -2 * rate}, {easing: 'sineInOut'})
.to(time / 6, {angle: 1 * rate}, {easing: 'sineInOut'})
.to(time / 6, {angle: 0 * rate}, {easing: 'sineInOut'})
.start();
},
showAllRight() {
const curOptionArr = this.curOptionArr;
for (let i=0; i<curOptionArr.length; i++) {
if (curOptionArr[i].light.opacity > 254) {
this.addIconRight(curOptionArr[i]);
}
}
},
changeNextQuestion() {
console.log(' in changeNextQuestion')
this.curQuestionIndex ++ ;
this.setCurQuestionData();
if (!this.curQuestionData) {
// this.gameEnd();
return;
}
this.showChangeQuesAnim();
},
showChangeQuesAnim() {
this.hideLight();
this.hideCurOptionAnim(() => {
this.setCurOption();
this.showCurOptionAnim();
this.hideMask();
});
this.hideCurQuestion(() => {
this.setCurQuestion();
this.showCurQuestionAnim();
});
},
maskLayer: null,
initMask() {
const maskLayer = new cc.Node();
maskLayer.width = this.canvas.width;
maskLayer.height = this.canvas.height;
this.canvas.addChild(maskLayer, 20);
maskLayer.addComponent(cc.BlockInputEvents);
this.maskLayer = maskLayer;
this.maskLayer.active = false;
},
showMask() {
this.maskLayer.active = true;
},
hideMask() {
this.maskLayer.active = false;
},
hideCurOptionAnim(cb) {
const arr = this.curOptionArr;
const time = 0.5;
for (let i=0; i<arr.length; i++) {
if (arr[i].iconRight) {
arr[i].iconRight.removeFromParent();
arr[i].iconRight = null;
}
cc.tween(arr[i])
.to(time, {opacity: 0}, {easing: "cubicOut"})
.call(() => {
arr[i].active = false;
})
.start();
}
delayCall(time, () => {
cb();
})
},
showCurOptionAnim(cb=null) {
const arr = this.curOptionArr;
const time = 0.5;
for (let i=0; i<arr.length; i++) {
arr[i].opacity = 0;
cc.tween(arr[i])
.to(time, {opacity: 255}, {easing: "cubicIn"})
.start();
}
if (cb) {
delayCall(time, () => {
cb();
})
}
},
hideCurQuestion(cb) {
const time = 0.5;
cc.tween(this.curQuesBg)
.to(time, {opacity: 0}, {easing: "cubicOut"})
.call(() => {
this.curQuesBg.active = false;
cb();
})
.start();
},
showCurQuestionAnim() {
this.curQuesBg.active = true;
this.curQuesBg.opacity = 0;
const time = 0.5;
cc.tween(this.curQuesBg)
.to(time, {opacity: 255}, {easing: "cubicIn"})
.start();
},
gameEnd() {
console.log('game end !')
this.showRestart();
// this.showOneFirework(cc.v2(0, -this.canvas.height / 2), this.canvas, cc.find('paperBase').children, this.canvas.width / 2.5, this.canvas.height * 2, 100, 1);
playAudio(this.finishClip);
const camera = cc.find('Canvas/Main Camera');
camera.zIndex = 100;
showTrebleFirework(camera, cc.find('RibbonNodeBase').children);
},
showRestart() {
const btn = getSprNode("btn_restart");
btn.scale = this._mapScaleMin;
btn.baseS = btn.scale;
this.canvas.addChild(btn, 21);
btn.on(cc.Node.EventType.TOUCH_START, () => {
btn.removeFromParent();
this.initData();
this.initStar();
this.showChangeQuesAnim();
playAudio(this.btnClip);
})
const time = 1;
btn.scale = 0;
cc.tween(btn)
.delay(1)
.to(time, {scale: btn.baseS}, {easing: "elasticOut"})
.start();
},
async showOneFirework(pos, parentNode, nodeList, w, h, n, timeRate=1) {
for (let i = 0; i < 3; i++) {
this.showFirework(pos, parentNode, nodeList, w, h, n, timeRate);
await asyncDelay(0.1);
}
},
showFirework(pos, parentNode, nodeList, width = 200, height = 500, number = 30, timeRate=1) {
const subTime = 1;
for (let i = 0; i < number; i++) {
const quad = this.createQuads(pos, parentNode, nodeList);
const targetX = RandomInt(width / 2, -width / 2);
const targetY = RandomInt(height);
cc.tween(quad)
.by(0.5 * timeRate, { x: targetX })
.by((2 + subTime * Math.random()) * timeRate, { x: targetX * 2 })
.start();
cc.tween(quad)
.by(0.5 * timeRate, { y: targetY }, { easing: 'quadOut' })
.to((3 + subTime * Math.random()) * timeRate, { y: -parentNode.height * 2 }, { easing: 'quadIn' })
.removeSelf()
.start();
cc.tween(quad)
.delay(1 * timeRate)
.to((0.5 + subTime * Math.random()) * timeRate , { opacity: 0 })
.start();
}
},
createQuads(pos, parentNode, nodeList) {
const quadBase = cc.instantiate(nodeList[RandomInt(nodeList.length)]);
quadBase.x = pos.x;
quadBase.y = pos.y;
quadBase.z = pos.z;
quadBase.angle = RandomInt(180);
quadBase.parent = parentNode;
const quad = quadBase.getChildByName('quad');
quad.x = 0;
quad.y = 0;
quad.angle = RandomInt(180);
const paper = quad.getChildByName('paper');
paper.scaleX = Math.random() * 0.8 + 0.2;
paper.scaleY = Math.random() * 0.8 + 0.2;
quadBase.scaleX = Math.random();
cc.tween(quadBase)
.to((1 - quadBase.scaleX) * 0.3, { scaleX: 1 })
.call(() => {
const time = Math.random() * 0.2;
cc.tween(quadBase)
.to(0.1 + time, { scaleX: -1 })
.to(0.1 + time, { scaleX: 1 })
.union()
.repeatForever()
.start();
})
.start();
return quadBase;
},
restart() {
},
initTitle() {
const offX = 96;
const offY = 11;
const title = getSprNode('title_bg');
title.parent = this.canvas;
title.scale = this._mapScaleMin;
title.zIndex = 10;
title.x = -this.canvas.width / 2 + title.width / 2 * title.scale + offX;
title.y = this.canvas.height / 2 - title.height / 2 * title.scale - offY;
// console.log('this.data: ', this.data);
title.addComponent(cc.Button)
title.on('click', () => {
if (this.data.title_audio_url) {
playAudioByUrl(this.data.title_audio_url);
}
})
const labelNode = new cc.Node();
labelNode.parent = title;
const label = labelNode.addComponent(cc.RichText);
const size = 42
label.font = cc.find('Canvas/res/font/aharoni').getComponent(cc.Label).font;
label.string = `<outline color=#a83c13 width=2><size=${size}><color=#ffffff>${this.data.title || " " }</color></size></outline>`
// label.string = `<size=${size}><color=#751e00>${this.curGroup.title }</color></size>`
label.lineHeight = size;
label.horizontalAlign = cc.macro.TextAlignment.LEFT
labelNode.anchorX = 0;
labelNode.anchorY = 1
labelNode.x = -title.width / 2 + 90;
const maxLen = 305;
if (labelNode.width > maxLen) {
labelNode.scale = maxLen / labelNode.width;
}
labelNode.y = labelNode.height / 2 * labelNode.scale + 15;
},
initBg() {
// if (!this.data.pic_url) {
// return;
// }
// getSprNodeByUrl, setSprNodeMaxLen(this.data.pic_url, (spr) => {
// this.canvas.addChild(spr.node);
// spr.node.scale = this._mapScaleMax;
// });
},
initHotZone() {
this.initHotZoneBg();
},
hotZoneBg: null,
initHotZoneBg() {
this.hotZoneBg = new cc.Node();
this.hotZoneBg.name = 'hotZoneBg';
this.hotZoneBg.parent = cc.find('Canvas');
this.hotZoneBg.zIndex = 4;
if (!this.data.bgItem) {
return;
}
cc.loader.load({url: this.data.bgItem.url}, (err, img) => {
// this.addMask(this.hotZoneBg);
this.hotZoneBg.width = img.width;
this.hotZoneBg.height = img.height;
const sprNode = new cc.Node();
sprNode.name = 'bgItemSpr'
var sf = new cc.SpriteFrame(img);
// const spr = this.hotZoneBg.addComponent(cc.Sprite);
const spr = sprNode.addComponent(cc.Sprite);
spr.spriteFrame = sf
sprNode.width = this.hotZoneBg.width;
sprNode.height = this.hotZoneBg.height;
sprNode.parent = this.hotZoneBg;
window['bg'] =sprNode
const sx = this.canvas.width / this.hotZoneBg.width;
const sy = (this.canvas.height) / this.hotZoneBg.height;
const s = Math.min(sx, sy);
this.hotZoneBg.scale = s;
// this.data.bgItem.isShowDebugLine = true;
this.initHotZoneItem();
});
},
initHotZoneItem() {
this.data.hotZoneItemArr.forEach((item) => {
// console.log('item.gIdx: ', item.gIdx);
switch (item.gIdx) {
case "0":
this.setOneDragPic(item);
break;
case "1":
this.setOneDragAction(item);
break;
case "2":
this.setOneRect(item);
break;
default:
break;
}
});
},
addMask(node) {
const mask = node.addComponent(cc.Mask);
mask.type = cc.Mask.Type.RECT;
},
setOneDragAction(data) {
const rate = (this.hotZoneBg.scale * this.hotZoneBg.width) / this.data.bgItem.rect.width;
const rectNode = new cc.Node();
rectNode.name = 'rect' + data.index;
this.hotZoneBg.addChild(rectNode);
const ctx = rectNode.addComponent(cc.Graphics);
// 红色矩形
ctx.lineWidth = 4;
ctx.strokeColor = cc.Color.BLACK;
ctx.fillColor = cc.Color.WHITE.setA(100);
const scale = rate / this.hotZoneBg.scaleY ;
rectNode.width = data.rect.width * scale;
rectNode.height = data.rect.height * scale;
rectNode.x = -this.hotZoneBg.width / 2 + data.rect.x * scale;
rectNode.y = this.hotZoneBg.height / 2 - data.rect.height * scale - data.rect.y * scale;
const {x, y, width, height} = rectNode;
// rectNode.anchorX = rectNode.anchorY = 0;
if (this.data.bgItem.isShowDebugLine) {
ctx.rect(-rectNode.width / 2, -rectNode.height / 2, rectNode.width, rectNode.height);
}
ctx.stroke();
ctx.fill();
rectNode.x += rectNode.width / 2;
rectNode.y += rectNode.height / 2;
rectNode.baseX = rectNode.x;
rectNode.baseY = rectNode.y;
rectNode.targetOff();
rectNode.on(cc.Node.EventType.TOUCH_START, () => {
if (rectNode.isDragEnd) {
if (rectNode.audioClip) {
cc.audioEngine.stopAllEffects();
cc.audioEngine.playEffect(rectNode.audioClip, false, 0.8);
}
return;
}
this._curShowItem = rectNode;
})
const realRate = this.hotZoneBg.width / this.data.bgItem.rect.width;
rectNode.targetPx = -this.hotZoneBg.width / 2 + ( data.dragDot.x - this.data.bgItem.rect.x ) * realRate;
rectNode.targetPy = this.hotZoneBg.height / 2 - (data.dragDot.y - this.data.bgItem.rect.y) * realRate;
if (data.audio_url) {
cc.assetManager.loadRemote(data.audio_url, (err, audioClip) => {
rectNode.audioClip = audioClip;
});
}
console.log('setOneAction ~~ data: ', data)
const actionData = data['actionData_' + data.gIdx];
if (!actionData) {
return;
}
if (actionData.type == 'text') {
const label = this.setOneActionText(rectNode, actionData);
label.node.scale = scale * data.fontScale;
label.node.targetOff();
// label.overflow = cc.Label.Overflow.NONE;
// label.node.setContentSize(new cc.Size(0, lineHeight));
label["_forceUpdateRenderData"](true);
} else if (actionData.type == 'pic') {
const pic = this.setOneActionPic(rectNode, actionData);
} else if (actionData.type == 'anima') {
const anima = this.setOneActionAnima(rectNode, actionData);
}
},
setOneAction(data) {
const rate = (this.hotZoneBg.scale * this.hotZoneBg.width) / this.data.bgItem.rect.width;
const rectNode = new cc.Node();
rectNode.name = 'rect' + data.index;
this.hotZoneBg.addChild(rectNode);
const ctx = rectNode.addComponent(cc.Graphics);
// 红色矩形
ctx.lineWidth = 4;
ctx.strokeColor = cc.Color.BLACK;
ctx.fillColor = cc.Color.WHITE.setA(100);
const scale = rate / this.hotZoneBg.scaleY ;
rectNode.width = data.rect.width * scale;
rectNode.height = data.rect.height * scale;
rectNode.x = -this.hotZoneBg.width / 2 + data.rect.x * scale;
rectNode.y = this.hotZoneBg.height / 2 - data.rect.height * scale - data.rect.y * scale;
const {x, y, width, height} = rectNode;
rectNode.anchorX = rectNode.anchorY = 0;
if (this.data.bgItem.isShowDebugLine) {
ctx.rect(0, 0, rectNode.width, rectNode.height);
}
ctx.stroke();
ctx.fill();
console.log('setOneAction ~~ data: ', data)
const actionData = data['actionData_' + data.gIdx];
if (!actionData) {
return;
}
if (actionData.type == 'text') {
const label = this.setOneActionText(rectNode, actionData);
label.node.scale = scale * data.fontScale;
// label.overflow = cc.Label.Overflow.NONE;
// label.node.setContentSize(new cc.Size(0, lineHeight));
label["_forceUpdateRenderData"](true);
} else if (actionData.type == 'pic') {
const pic = this.setOneActionPic(rectNode, actionData);
} else if (actionData.type == 'anima') {
const anima = this.setOneActionAnima(rectNode, actionData);
}
},
setOneActionText(rectNode, actionData) {
const labelNode = new cc.Node();
labelNode.parent = rectNode;
const label = labelNode.addComponent(cc.Label);
label.font = cc.find('Canvas/res/font/ahronbd-1').getComponent(cc.Label).font;
label.string = actionData.text;
// label.string = `<size=${size}><color=#751e00>${this.curGroup.title }</color></size>`
// label.lineHeight = size;
// label.horizontalAlign = cc.macro.TextAlignment.LEFT
// labelNode.anchorX = 0;
// labelNode.anchorY = 1
labelNode.color = cc.Color.BLACK;
const opArr = actionData.changeOption
// console.log('opArr', opArr);
const tweenArr = [];
for (let i = 0; i < opArr.length; i++ ) {
const opData = opArr[i];
console.log('opArr[0]', opArr[i])
if (opData[0] == 'fontColor') {
const color = new cc.Color();
cc.Color.fromHEX(color, opData[1] );
labelNode.color = color;
} else if (opData[0] == 'opacity') {
// console.log('opData: ', opData)
labelNode.opacity = Number( opData[1] / 100 * 255 ) + 0.1;
// console.log(labelNode.opacity);
tweenArr.push({item: labelNode , option: `{"${opData[0]}" : ${opData[2] / 100 * 255}}`, optionName: opData[0]},)
} else {
label[opData[0]] = opData[1];
tweenArr.push({item: label, option: `{"${opData[0]}" : ${opData[2]}}`, optionName: opData[0]})
}
}
// if (actionData.audio_url) {
// cc.assetManager.loadRemote(actionData.audio_url, (err, audioClip) => {
// labelNode.audioClip = audioClip;
// });
// }
label.lineHeight = label.fontSize;
// labelNode.y += rectNode.height / 2;
// labelNode.x += rectNode.width / 2;
// rectNode.addComponent(cc.Button);
// rectNode.on('click', () => {
// if (labelNode.audioClip) {
// cc.audioEngine.stopAllEffects();
// cc.audioEngine.playEffect(labelNode.audioClip, false, 0.8);
// }
// if (labelNode.isClicked) {
// // return;
// }
// labelNode.isClicked = true;
// for (let i=0; i<tweenArr.length; i++) {
// const tweenData = tweenArr[i];
// if (tweenData.optionName == 'opacity') {
// console.log('~~~ ', tweenData.item[tweenData.optionName] );
// cc.tween(tweenData.item)
// .to(actionData.changeTime, JSON.parse(tweenData.option) )
// .start();
// }
// }
// });
return label;
},
setOneActionPic(rectNode, actionData) {
console.log('setOneActionPic actionData: ', actionData)
const picNode = new cc.Node();
rectNode.addChild(picNode);
cc.loader.load({url: actionData.pic_url}, (err, img) => {
const spr = picNode.addComponent(cc.Sprite);
spr.spriteFrame = new cc.SpriteFrame(img)
picNode.y += rectNode.height / 2;
picNode.x += rectNode.width / 2;
picNode.scaleX = rectNode.width / picNode.width;
picNode.scaleY = rectNode.height / picNode.height;
const opArr = actionData.changeOption
const tweenArr = [];
for (let i = 0; i < opArr.length; i++ ) {
const opData = opArr[i];
console.log('opData: ~~~ ', opData);
if (opData[0] == 'opacity') {
picNode.opacity = Number( opData[1] / 100 * 255 ) + 0.1;
console.log(picNode.opacity);
tweenArr.push({item: picNode , option: `{"${opData[0]}" : ${opData[2] / 100 * 255}}`, optionName: opData[0]},)
} else {
// picNode[opData[0]] = Number(opData[1]);
// tweenArr.push({item: picNode, option: `{"${opData[0]}" : ${opData[2]}}`, optionName: opData[0]})
}
if (actionData.audio_url) {
cc.assetManager.loadRemote(actionData.audio_url, (err, audioClip) => {
rectNode.audioClip = audioClip;
});
}
rectNode.addComponent(cc.Button);
rectNode.on('click', () => {
if (rectNode.audioClip) {
cc.audioEngine.stopAllEffects();
cc.audioEngine.playEffect(rectNode.audioClip, false, 0.8);
}
if (rectNode.isClicked) {
// return;
}
rectNode.isClicked = true;
for (let i=0; i<tweenArr.length; i++) {
const tweenData = tweenArr[i];
if (tweenData.optionName == 'opacity') {
cc.tween(tweenData.item)
.to(actionData.changeTime, JSON.parse(tweenData.option) )
.start();
}
}
});
}
});
},
setOneActionAnima(rectNode, actionData) {
const animaNode = new cc.Node();
rectNode.addChild(animaNode);
if (actionData.audio_url) {
cc.assetManager.loadRemote(actionData.audio_url, (err, audioClip) => {
rectNode.audioClip = audioClip;
});
}
const data = actionData;
const dragonDisplay = animaNode.addComponent(dragonBones.ArmatureDisplay);
if (!data.texPngData) {
return
}
const image = data.texPngData.url//"http://staging-teach.cdn.ireadabc.com/5a0c5af3e952acd0ac83a6e5c6f03ff1.png";
const ske = data.skeJsonData.url//"http://staging-teach.cdn.ireadabc.com/bd825dcceea298d1146be8067ae3d17f.json";
const atlas = data.texJsonData.url//"http://staging-teach.cdn.ireadabc.com/246f8991b729fa3e5a7f4802de828efa.json";
cc.loader.load(image, (error, texture) => {
cc.loader.load({url: atlas, type: 'txt'}, (error, atlasJson) => {
cc.loader.load({url: ske, type: 'txt'}, (error, dragonBonesJson) => {
const atlas = new dragonBones.DragonBonesAtlasAsset();
atlas.atlasJson = atlasJson;
atlas.texture = texture;
const asset = new dragonBones.DragonBonesAsset();
asset.dragonBonesJson = dragonBonesJson;
dragonDisplay.dragonAtlasAsset = atlas;
dragonDisplay.dragonAsset = asset;
let json = JSON.parse(asset.dragonBonesJson);
let armatures = json["armature"];
let armatureNames = [];
for (let i = 0; i < armatures.length; i++) {
armatureNames.push(armatures[i].name);
}
// console.log('armatureNames: ', armatureNames);
let animationNames = [];
if (armatureNames.length > 0) {
let defaultArmatureName = armatureNames[0];
dragonDisplay.armatureName = defaultArmatureName;
// let animationNames = dragonDisplay.getAnimationNames(defaultArmatureName);
let defaultArmature = armatures[0];
let animations = defaultArmature.animation;
for (let i = 0; i < animations.length; i++) {
animationNames.push(animations[i].name);
}
// rectNode.addComponent(cc.Button);
// rectNode.on('click', () => {
// if (rectNode.isClicked) {
// // return;
// }
// rectNode.isClicked = true;
// console.log('clicked');
// if (rectNode.audioClip) {
// cc.audioEngine.stopAllEffects();
// cc.director.emit('STOP_ALL_AUDIO')
// cc.audioEngine.playEffect(rectNode.audioClip, false, 0.8);
// }
// if (animationNames.length > 0) {
// dragonDisplay.playAnimation(animationNames[0], 1);
// }
// });
}
// animaNode.x = rectNode.x + rectNode.width / 2;
// animaNode.y = rectNode.y + rectNode.height / 2;
// const sx = rectNode.width / animaNode.width;
// const sy = rectNode.height / animaNode.height;
// const scale = Math.min(sx, sy);
// animaNode.scale = scale;
animaNode.y += rectNode.height / 2;
animaNode.x += rectNode.width / 2;
animaNode.scaleX = rectNode.width / animaNode.width;
animaNode.scaleY = rectNode.height / animaNode.height;
const opArr = actionData.changeOption
const tweenArr = [];
for (let i = 0; i < opArr.length; i++ ) {
const opData = opArr[i];
console.log('opData: ~~~ ', opData);
if (opData[0] == 'opacity') {
animaNode.opacity = Number( opData[1] / 100 * 255 ) + 0.1;
console.log(animaNode.opacity);
tweenArr.push({item: animaNode , option: `{"${opData[0]}" : ${opData[2] / 100 * 255}}`, optionName: opData[2] == null ? '' : opData[0]},)
} else {
// animaNode[opData[0]] = Number(opData[1]);
// tweenArr.push({item: animaNode, option: `{"${opData[0]}" : ${opData[2]}}`, optionName: opData[2] == null ? '' : opData[0]})
}
if (actionData.audio_url) {
cc.assetManager.loadRemote(actionData.audio_url, (err, audioClip) => {
rectNode.audioClip = audioClip;
});
}
rectNode.addComponent(cc.Button);
rectNode.on('click', () => {
if (rectNode.audioClip) {
cc.audioEngine.stopAllEffects();
cc.audioEngine.playEffect(rectNode.audioClip, false, 0.8);
}
if (rectNode.isClicked) {
// return;
}
rectNode.isClicked = true;
for (let j=0; j<tweenArr.length; j++) {
const tweenData = tweenArr[j];
console.log('tweenData: ', tweenData);
if (tweenData.optionName) {
cc.tween(tweenData.item)
.to(actionData.changeTime, JSON.parse(tweenData.option))
.start();
}
}
if (animationNames.length > 0) {
dragonDisplay.playAnimation(animationNames[0], 1);
}
});
}
});
});
});
},
setOneAnimaSmall(data) {
const rate = (this.hotZoneBg.scale * this.hotZoneBg.width) / this.data.bgItem.rect.width;
const rectNode = new cc.Node();
rectNode.name = 'rect' + data.index;
this.hotZoneBg.addChild(rectNode);
const ctx = rectNode.addComponent(cc.Graphics);
// 红色矩形
ctx.lineWidth = 4;
ctx.strokeColor = cc.Color.BLACK;
ctx.fillColor = cc.Color.WHITE.setA(100);
const scale = rate / this.hotZoneBg.scaleY;
rectNode.width = data.rect.width * scale;
rectNode.height = data.rect.height * scale;
rectNode.x = -this.hotZoneBg.width / 2 + data.rect.x * scale;
rectNode.y = this.hotZoneBg.height / 2 - data.rect.height * scale - data.rect.y * scale;
rectNode.anchorX = rectNode.anchorY = 0;
if (this.data.bgItem.isShowDebugLine) {
ctx.rect(0, 0, rectNode.width, rectNode.height);
}
ctx.stroke();
ctx.fill();
const animaNode = new cc.Node();
animaNode.name = 'anima_' + data.index;
this.hotZoneBg.addChild(animaNode);
if (data.audio_url) {
cc.assetManager.loadRemote(data.audio_url, (err, audioClip) => {
animaNode.audioClip = audioClip;
});
}
const dragonDisplay = animaNode.addComponent(dragonBones.ArmatureDisplay);
if (!data.texPngData) {
return
}
const image = data.texPngData.url//"http://staging-teach.cdn.ireadabc.com/5a0c5af3e952acd0ac83a6e5c6f03ff1.png";
const ske = data.skeJsonData.url//"http://staging-teach.cdn.ireadabc.com/bd825dcceea298d1146be8067ae3d17f.json";
const atlas = data.texJsonData.url//"http://staging-teach.cdn.ireadabc.com/246f8991b729fa3e5a7f4802de828efa.json";
cc.loader.load(image, (error, texture) => {
cc.loader.load({url: atlas, type: 'txt'}, (error, atlasJson) => {
cc.loader.load({url: ske, type: 'txt'}, (error, dragonBonesJson) => {
const atlas = new dragonBones.DragonBonesAtlasAsset();
atlas.atlasJson = atlasJson;
atlas.texture = texture;
const asset = new dragonBones.DragonBonesAsset();
asset.dragonBonesJson = dragonBonesJson;
dragonDisplay.dragonAtlasAsset = atlas;
dragonDisplay.dragonAsset = asset;
let json = JSON.parse(asset.dragonBonesJson);
let armatures = json["armature"];
// console.log('armatures: ', armatures);
let armatureNames = [];
for (let i = 0; i < armatures.length; i++) {
armatureNames.push(armatures[i].name);
}
// console.log('armatureNames: ', armatureNames);
if (armatureNames.length > 0) {
let defaultArmatureName = armatureNames[0];
dragonDisplay.armatureName = defaultArmatureName;
// let animationNames = dragonDisplay.getAnimationNames(defaultArmatureName);
let defaultArmature = armatures[0];
let animations = defaultArmature.animation;
let animationNames = [];
for (let i = 0; i < animations.length; i++) {
animationNames.push(animations[i].name);
}
rectNode.addComponent(cc.Button);
rectNode.on('click', () => {
if (rectNode.isClicked) {
// return;
}
rectNode.isClicked = true;
console.log('clicked');
if (animaNode.audioClip) {
cc.audioEngine.stopAllEffects();
cc.director.emit('STOP_ALL_AUDIO')
cc.audioEngine.playEffect(animaNode.audioClip, false, 0.8);
}
if (animationNames.length > 0) {
dragonDisplay.playAnimation(animationNames[0], 1);
}
});
}
animaNode.x = rectNode.x + rectNode.width / 2;
animaNode.y = rectNode.y + rectNode.height / 2;
const sx = rectNode.width / animaNode.width;
const sy = rectNode.height / animaNode.height;
const scale = Math.min(sx, sy);
animaNode.scale = scale;
});
});
});
},
setOneDragPic(data) {
const rate = (this.hotZoneBg.scale * this.hotZoneBg.width) / this.data.bgItem.rect.width;
const picNode = new cc.Node();
picNode.name= 'pic' + data.index;
picNode.data = data;
this.hotZoneBg.addChild(picNode);
cc.loader.load({url: data.pic_url}, (err, img) => {
const spr = picNode.addComponent(cc.Sprite);
spr.spriteFrame = new cc.SpriteFrame(img)
const scale = rate / this.hotZoneBg.scaleY;
picNode.width = data.rect.width * scale;
picNode.height = data.rect.height * scale;
picNode.x = -this.hotZoneBg.width / 2 + data.rect.x * scale;
picNode.y = this.hotZoneBg.height / 2 - data.rect.height * scale - data.rect.y * scale;
picNode.x += picNode.width / 2 * picNode.scaleX;
picNode.y += picNode.height / 2 * picNode.scaleX;
// picNode.anchorX = picNode.anchorY = 0;
// if (data.audio_url) {
// this.addPicAudio(picNode);
// }
this.addDragPoint(picNode, data)
});
},
addDragPoint(picNode, data) {
picNode.baseX = picNode.x;
picNode.baseY = picNode.y;
const realRate = this.hotZoneBg.width / this.data.bgItem.rect.width;
picNode.targetPx = -this.hotZoneBg.width / 2 + ( data.dragDot.x - this.data.bgItem.rect.x ) * realRate;
picNode.targetPy = this.hotZoneBg.height / 2 - (data.dragDot.y - this.data.bgItem.rect.y) * realRate;
if (data.audio_url) {
cc.assetManager.loadRemote(data.audio_url, (err, audioClip) => {
picNode.audioClip = audioClip;
});
}
picNode.on(cc.Node.EventType.TOUCH_START, () => {
if (picNode.isDragEnd) {
if (picNode.audioClip) {
cc.audioEngine.stopAllEffects();
cc.audioEngine.playEffect(picNode.audioClip, false, 0.8);
}
return;
}
this._curShowItem = picNode;
// picNode.x = -this.hotZoneBg.width / 2 + ( data.dragDot.x - this.data.bgItem.rect.x ) * realRate;
// picNode.y = this.hotZoneBg.height / 2 - (data.dragDot.y - this.data.bgItem.rect.y) * realRate;
})
},
setOnePic(data) {
const rate = (this.hotZoneBg.scale * this.hotZoneBg.width) / this.data.bgItem.rect.width;
const picNode = new cc.Node();
picNode.name= 'pic' + data.index;
picNode.data = data;
this.hotZoneBg.addChild(picNode);
cc.loader.load({url: data.pic_url}, (err, img) => {
const spr = picNode.addComponent(cc.Sprite);
spr.spriteFrame = new cc.SpriteFrame(img)
const scale = rate / this.hotZoneBg.scaleY;
picNode.width = data.rect.width * scale;
picNode.height = data.rect.height * scale;
picNode.x = -this.hotZoneBg.width / 2 + data.rect.x * scale;
picNode.y = this.hotZoneBg.height / 2 - data.rect.height * scale - data.rect.y * scale;
picNode.anchorX = picNode.anchorY = 0;
if (data.audio_url) {
this.addPicAudio(picNode);
}
});
},
setOneRect(data) {
const rate = (this.hotZoneBg.scale * this.hotZoneBg.width) / this.data.bgItem.rect.width;
const rectNode = new cc.Node();
rectNode.name = 'rect' + data.index;
this.hotZoneBg.addChild(rectNode);
const ctx = rectNode.addComponent(cc.Graphics);
// 红色矩形
ctx.lineWidth = 4;
ctx.strokeColor = cc.Color.BLACK;
ctx.fillColor = cc.Color.WHITE.setA(100);
const scale = rate / this.hotZoneBg.scaleY;
// console.log('scale: ', scale);
// console.log('scale2: ', scale / data.mapScale);
rectNode.width = data.rect.width * scale;
rectNode.height = data.rect.height * scale;
rectNode.x = -this.hotZoneBg.width / 2 + data.rect.x * scale;
rectNode.y = this.hotZoneBg.height / 2 - data.rect.height * scale - data.rect.y * scale;
// rectNode.scale = 1 / data.mapScale;
rectNode.anchorX = rectNode.anchorY = 0;
if (this.data.bgItem.isShowDebugLine) {
ctx.rect(0, 0, rectNode.width, rectNode.height);
}
ctx.stroke();
ctx.fill();
// console.log('```data: ', data)
this.dragEndRectArr.push(rectNode);
if (data.audio_url) {
cc.assetManager.loadRemote(data.audio_url, (err, audioClip) => {
rectNode.audioClip = audioClip;
});
}
// rectNode.addComponent(cc.Button);
// rectNode.on('click', () => {
// if (rectNode.isClicked) {
// // return;
// }
// rectNode.isClicked = true;
// console.log('clicked');
// if (rectNode.audioClip) {
// cc.audioEngine.stopAllEffects();
// cc.audioEngine.playEffect(rectNode.audioClip, false, 0.8);
// }
// });
},
addPicAudio(picNode) {
const data = picNode.data;
cc.assetManager.loadRemote(data.audio_url, (err, audioClip) => {
picNode.audioClip = audioClip;
});
picNode.addComponent(cc.Button);
picNode.on('click', () => {
if (picNode.audioClip) {
cc.audioEngine.stopAllEffects();
cc.audioEngine.playEffect(picNode.audioClip, false, 0.8);
}
});
},
initListener() {
const canvas = cc.find('Canvas');
let downFlag = false;
const touchMove = (e) => {
this.canvasTouchMove(e);
if (canvas.hasEventListener(cc.Node.EventType.MOUSE_MOVE)) {
canvas.off(cc.Node.EventType.MOUSE_MOVE, mouseMove)
}
}
const mouseMove = (e) => {
if (!downFlag) {
return;
}
this.canvasTouchMove(e);
if (canvas.hasEventListener(cc.Node.EventType.TOUCH_MOVE)) {
canvas.off(cc.Node.EventType.TOUCH_MOVE, touchMove)
this.removeHtmlCanvasListener('touchmove');
}
}
const touchEnd = (e) => {
downFlag = false;
this.canvasTouchEnd(e);
if (canvas.hasEventListener(cc.Node.EventType.MOUSE_UP)) {
canvas.off(cc.Node.EventType.MOUSE_UP, mouseUp)
}
if (canvas.hasEventListener(cc.Node.EventType.MOUSE_LEAVE)) {
canvas.off(cc.Node.EventType.MOUSE_LEAVE, mouseUp)
}
this.removeHtmlTouchEnd();
}
const mouseUp = (e) => {
downFlag = false;
this.canvasTouchEnd(e);
if (canvas.hasEventListener(cc.Node.EventType.TOUCH_END)) {
canvas.off(cc.Node.EventType.TOUCH_END, touchEnd)
}
if (canvas.hasEventListener(cc.Node.EventType.TOUCH_CANCEL)) {
canvas.off(cc.Node.EventType.TOUCH_CANCEL, touchEnd)
}
}
canvas.on(cc.Node.EventType.TOUCH_MOVE, touchMove)
canvas.on(cc.Node.EventType.MOUSE_MOVE, mouseMove)
canvas.on(cc.Node.EventType.TOUCH_END, touchEnd)
canvas.on(cc.Node.EventType.TOUCH_CANCEL, touchEnd)
canvas.on(cc.Node.EventType.MOUSE_UP, mouseUp)
},
removeHtmlCanvasListener(type) {
const canvasHtml = document.querySelector('canvas');
canvasHtml.addEventListener(type, (e) => {})
},
removeHtmlTouchEnd() {
const canvasHtml = document.querySelector('canvas');
canvasHtml.removeEventListener('touchend', this.htmlCanvasTouchendFunc, this);
},
canvasTouchMove(e) {
if (!this._curShowItem) {
return;
}
const pos = e.getLocation();
this._curShowItem.x = pos.x - e.currentTarget.width / 2;
this._curShowItem.y = pos.y - e.currentTarget.height / 2;
// console.log('pos: ', pos.x);
},
canvasTouchEnd(e) {
if (!this._curShowItem) {
return;
}
this.checkOnDragEndRect();
this._curShowItem = null;
},
checkOnDragEndRect() {
console.log('emptyGroupArr: ', this.emptyGroupArr);
for (let i = 0; i < this.dragEndRectArr.length; i++) {
const rect = this.dragEndRectArr[i];
const worldPos = this._curShowItem.parent.convertToWorldSpaceAR(cc.v2(this._curShowItem.x, this._curShowItem.y));
const worldRect = rect.getBoundingBoxToWorld();
if (worldRect.contains(worldPos)) {
console.log('rect in ')
this.checkIsDragEndTarget(rect);
// removeItemFromArr(this.emptyGroupArr, letterGroup);
// this.showLetterSuccess(letterGroup);
// this.checkGroupEnd();
return;
}
}
this.itemBack();
},
itemBack() {
cc.audioEngine.playEffect(this.wrongClip, false, 0.8);
cc.tween(this._curShowItem)
.to(0.5, {x: this._curShowItem.baseX, y: this._curShowItem.baseY}, {easing: "elasticOut"})
.start();
},
checkIsDragEndTarget(rect) {
const worldPos = this._curShowItem.parent.convertToWorldSpaceAR(cc.v2(this._curShowItem.targetPx, this._curShowItem.targetPy));
const worldRect = rect.getBoundingBoxToWorld();
if (worldRect.contains(worldPos)) {
this._curShowItem.x = this._curShowItem.targetPx;
this._curShowItem.y = this._curShowItem.targetPy;
this._curShowItem.isDragEnd = true;
cc.audioEngine.playEffect(this.rightClip, false, 0.8);
} else {
this.itemBack();
}
},
});
{ {
"ver": "1.0.8", "ver": "1.0.8",
"uuid": "c41b0e51-55d7-443c-af3a-b22c3dd9b9e5", "uuid": "40eb8e96-d0cf-4860-9228-b8975b9e2db5",
"isPlugin": false, "isPlugin": false,
"loadPluginInWeb": true, "loadPluginInWeb": true,
"loadPluginInNative": true, "loadPluginInNative": true,
......
/**
* Copyright (c) 2014-present, Facebook, Inc.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
!(function (global) {
"use strict";
var Op = Object.prototype;
var hasOwn = Op.hasOwnProperty;
var undefined; // More compressible than void 0.
var $Symbol = typeof Symbol === "function" ? Symbol : {};
var iteratorSymbol = $Symbol.iterator || "@@iterator";
var asyncIteratorSymbol = $Symbol.asyncIterator || "@@asyncIterator";
var toStringTagSymbol = $Symbol.toStringTag || "@@toStringTag";
var inModule = typeof module === "object";
var runtime = global.regeneratorRuntime;
if (runtime) {
if (inModule) {
// If regeneratorRuntime is defined globally and we're in a module,
// make the exports object identical to regeneratorRuntime.
module.exports = runtime;
}
// Don't bother evaluating the rest of this file if the runtime was
// already defined globally.
return;
}
// Define the runtime globally (as expected by generated code) as either
// module.exports (if we're in a module) or a new, empty object.
runtime = global.regeneratorRuntime = inModule ? module.exports : {};
function wrap(innerFn, outerFn, self, tryLocsList) {
// If outerFn provided and outerFn.prototype is a Generator, then outerFn.prototype instanceof Generator.
var protoGenerator = outerFn && outerFn.prototype instanceof Generator ? outerFn : Generator;
var generator = Object.create(protoGenerator.prototype);
var context = new Context(tryLocsList || []);
// The ._invoke method unifies the implementations of the .next,
// .throw, and .return methods.
generator._invoke = makeInvokeMethod(innerFn, self, context);
return generator;
}
runtime.wrap = wrap;
// Try/catch helper to minimize deoptimizations. Returns a completion
// record like context.tryEntries[i].completion. This interface could
// have been (and was previously) designed to take a closure to be
// invoked without arguments, but in all the cases we care about we
// already have an existing method we want to call, so there's no need
// to create a new function object. We can even get away with assuming
// the method takes exactly one argument, since that happens to be true
// in every case, so we don't have to touch the arguments object. The
// only additional allocation required is the completion record, which
// has a stable shape and so hopefully should be cheap to allocate.
function tryCatch(fn, obj, arg) {
try {
return { type: "normal", arg: fn.call(obj, arg) };
} catch (err) {
return { type: "throw", arg: err };
}
}
var GenStateSuspendedStart = "suspendedStart";
var GenStateSuspendedYield = "suspendedYield";
var GenStateExecuting = "executing";
var GenStateCompleted = "completed";
// Returning this object from the innerFn has the same effect as
// breaking out of the dispatch switch statement.
var ContinueSentinel = {};
// Dummy constructor functions that we use as the .constructor and
// .constructor.prototype properties for functions that return Generator
// objects. For full spec compliance, you may wish to configure your
// minifier not to mangle the names of these two functions.
function Generator() { }
function GeneratorFunction() { }
function GeneratorFunctionPrototype() { }
// This is a polyfill for %IteratorPrototype% for environments that
// don't natively support it.
var IteratorPrototype = {};
IteratorPrototype[iteratorSymbol] = function () {
return this;
};
var getProto = Object.getPrototypeOf;
var NativeIteratorPrototype = getProto && getProto(getProto(values([])));
if (NativeIteratorPrototype &&
NativeIteratorPrototype !== Op &&
hasOwn.call(NativeIteratorPrototype, iteratorSymbol)) {
// This environment has a native %IteratorPrototype%; use it instead
// of the polyfill.
IteratorPrototype = NativeIteratorPrototype;
}
var Gp = GeneratorFunctionPrototype.prototype =
Generator.prototype = Object.create(IteratorPrototype);
GeneratorFunction.prototype = Gp.constructor = GeneratorFunctionPrototype;
GeneratorFunctionPrototype.constructor = GeneratorFunction;
GeneratorFunctionPrototype[toStringTagSymbol] =
GeneratorFunction.displayName = "GeneratorFunction";
// Helper for defining the .next, .throw, and .return methods of the
// Iterator interface in terms of a single ._invoke method.
function defineIteratorMethods(prototype) {
["next", "throw", "return"].forEach(function (method) {
prototype[method] = function (arg) {
return this._invoke(method, arg);
};
});
}
runtime.isGeneratorFunction = function (genFun) {
var ctor = typeof genFun === "function" && genFun.constructor;
return ctor
? ctor === GeneratorFunction ||
// For the native GeneratorFunction constructor, the best we can
// do is to check its .name property.
(ctor.displayName || ctor.name) === "GeneratorFunction"
: false;
};
runtime.mark = function (genFun) {
if (Object.setPrototypeOf) {
Object.setPrototypeOf(genFun, GeneratorFunctionPrototype);
} else {
genFun.__proto__ = GeneratorFunctionPrototype;
if (!(toStringTagSymbol in genFun)) {
genFun[toStringTagSymbol] = "GeneratorFunction";
}
}
genFun.prototype = Object.create(Gp);
return genFun;
};
// Within the body of any async function, `await x` is transformed to
// `yield regeneratorRuntime.awrap(x)`, so that the runtime can test
// `hasOwn.call(value, "__await")` to determine if the yielded value is
// meant to be awaited.
runtime.awrap = function (arg) {
return { __await: arg };
};
function AsyncIterator(generator) {
function invoke(method, arg, resolve, reject) {
var record = tryCatch(generator[method], generator, arg);
if (record.type === "throw") {
reject(record.arg);
} else {
var result = record.arg;
var value = result.value;
if (value &&
typeof value === "object" &&
hasOwn.call(value, "__await")) {
return Promise.resolve(value.__await).then(function (value) {
invoke("next", value, resolve, reject);
}, function (err) {
invoke("throw", err, resolve, reject);
});
}
return Promise.resolve(value).then(function (unwrapped) {
// When a yielded Promise is resolved, its final value becomes
// the .value of the Promise<{value,done}> result for the
// current iteration. If the Promise is rejected, however, the
// result for this iteration will be rejected with the same
// reason. Note that rejections of yielded Promises are not
// thrown back into the generator function, as is the case
// when an awaited Promise is rejected. This difference in
// behavior between yield and await is important, because it
// allows the consumer to decide what to do with the yielded
// rejection (swallow it and continue, manually .throw it back
// into the generator, abandon iteration, whatever). With
// await, by contrast, there is no opportunity to examine the
// rejection reason outside the generator function, so the
// only option is to throw it from the await expression, and
// let the generator function handle the exception.
result.value = unwrapped;
resolve(result);
}, reject);
}
}
var previousPromise;
function enqueue(method, arg) {
function callInvokeWithMethodAndArg() {
return new Promise(function (resolve, reject) {
invoke(method, arg, resolve, reject);
});
}
return previousPromise =
// If enqueue has been called before, then we want to wait until
// all previous Promises have been resolved before calling invoke,
// so that results are always delivered in the correct order. If
// enqueue has not been called before, then it is important to
// call invoke immediately, without waiting on a callback to fire,
// so that the async generator function has the opportunity to do
// any necessary setup in a predictable way. This predictability
// is why the Promise constructor synchronously invokes its
// executor callback, and why async functions synchronously
// execute code before the first await. Since we implement simple
// async functions in terms of async generators, it is especially
// important to get this right, even though it requires care.
previousPromise ? previousPromise.then(
callInvokeWithMethodAndArg,
// Avoid propagating failures to Promises returned by later
// invocations of the iterator.
callInvokeWithMethodAndArg
) : callInvokeWithMethodAndArg();
}
// Define the unified helper method that is used to implement .next,
// .throw, and .return (see defineIteratorMethods).
this._invoke = enqueue;
}
defineIteratorMethods(AsyncIterator.prototype);
AsyncIterator.prototype[asyncIteratorSymbol] = function () {
return this;
};
runtime.AsyncIterator = AsyncIterator;
// Note that simple async functions are implemented on top of
// AsyncIterator objects; they just return a Promise for the value of
// the final result produced by the iterator.
runtime.async = function (innerFn, outerFn, self, tryLocsList) {
var iter = new AsyncIterator(
wrap(innerFn, outerFn, self, tryLocsList)
);
return runtime.isGeneratorFunction(outerFn)
? iter // If outerFn is a generator, return the full iterator.
: iter.next().then(function (result) {
return result.done ? result.value : iter.next();
});
};
function makeInvokeMethod(innerFn, self, context) {
var state = GenStateSuspendedStart;
return function invoke(method, arg) {
if (state === GenStateExecuting) {
throw new Error("Generator is already running");
}
if (state === GenStateCompleted) {
if (method === "throw") {
throw arg;
}
// Be forgiving, per 25.3.3.3.3 of the spec:
// https://people.mozilla.org/~jorendorff/es6-draft.html#sec-generatorresume
return doneResult();
}
context.method = method;
context.arg = arg;
while (true) {
var delegate = context.delegate;
if (delegate) {
var delegateResult = maybeInvokeDelegate(delegate, context);
if (delegateResult) {
if (delegateResult === ContinueSentinel) continue;
return delegateResult;
}
}
if (context.method === "next") {
// Setting context._sent for legacy support of Babel's
// function.sent implementation.
context.sent = context._sent = context.arg;
} else if (context.method === "throw") {
if (state === GenStateSuspendedStart) {
state = GenStateCompleted;
throw context.arg;
}
context.dispatchException(context.arg);
} else if (context.method === "return") {
context.abrupt("return", context.arg);
}
state = GenStateExecuting;
var record = tryCatch(innerFn, self, context);
if (record.type === "normal") {
// If an exception is thrown from innerFn, we leave state ===
// GenStateExecuting and loop back for another invocation.
state = context.done
? GenStateCompleted
: GenStateSuspendedYield;
if (record.arg === ContinueSentinel) {
continue;
}
return {
value: record.arg,
done: context.done
};
} else if (record.type === "throw") {
state = GenStateCompleted;
// Dispatch the exception by looping back around to the
// context.dispatchException(context.arg) call above.
context.method = "throw";
context.arg = record.arg;
}
}
};
}
// Call delegate.iterator[context.method](context.arg) and handle the
// result, either by returning a { value, done } result from the
// delegate iterator, or by modifying context.method and context.arg,
// setting context.delegate to null, and returning the ContinueSentinel.
function maybeInvokeDelegate(delegate, context) {
var method = delegate.iterator[context.method];
if (method === undefined) {
// A .throw or .return when the delegate iterator has no .throw
// method always terminates the yield* loop.
context.delegate = null;
if (context.method === "throw") {
if (delegate.iterator.return) {
// If the delegate iterator has a return method, give it a
// chance to clean up.
context.method = "return";
context.arg = undefined;
maybeInvokeDelegate(delegate, context);
if (context.method === "throw") {
// If maybeInvokeDelegate(context) changed context.method from
// "return" to "throw", let that override the TypeError below.
return ContinueSentinel;
}
}
context.method = "throw";
context.arg = new TypeError(
"The iterator does not provide a 'throw' method");
}
return ContinueSentinel;
}
var record = tryCatch(method, delegate.iterator, context.arg);
if (record.type === "throw") {
context.method = "throw";
context.arg = record.arg;
context.delegate = null;
return ContinueSentinel;
}
var info = record.arg;
if (!info) {
context.method = "throw";
context.arg = new TypeError("iterator result is not an object");
context.delegate = null;
return ContinueSentinel;
}
if (info.done) {
// Assign the result of the finished delegate to the temporary
// variable specified by delegate.resultName (see delegateYield).
context[delegate.resultName] = info.value;
// Resume execution at the desired location (see delegateYield).
context.next = delegate.nextLoc;
// If context.method was "throw" but the delegate handled the
// exception, let the outer generator proceed normally. If
// context.method was "next", forget context.arg since it has been
// "consumed" by the delegate iterator. If context.method was
// "return", allow the original .return call to continue in the
// outer generator.
if (context.method !== "return") {
context.method = "next";
context.arg = undefined;
}
} else {
// Re-yield the result returned by the delegate method.
return info;
}
// The delegate iterator is finished, so forget it and continue with
// the outer generator.
context.delegate = null;
return ContinueSentinel;
}
// Define Generator.prototype.{next,throw,return} in terms of the
// unified ._invoke helper method.
defineIteratorMethods(Gp);
Gp[toStringTagSymbol] = "Generator";
// A Generator should always return itself as the iterator object when the
// @@iterator function is called on it. Some browsers' implementations of the
// iterator prototype chain incorrectly implement this, causing the Generator
// object to not be returned from this call. This ensures that doesn't happen.
// See https://github.com/facebook/regenerator/issues/274 for more details.
Gp[iteratorSymbol] = function () {
return this;
};
Gp.toString = function () {
return "[object Generator]";
};
function pushTryEntry(locs) {
var entry = { tryLoc: locs[0] };
if (1 in locs) {
entry.catchLoc = locs[1];
}
if (2 in locs) {
entry.finallyLoc = locs[2];
entry.afterLoc = locs[3];
}
this.tryEntries.push(entry);
}
function resetTryEntry(entry) {
var record = entry.completion || {};
record.type = "normal";
delete record.arg;
entry.completion = record;
}
function Context(tryLocsList) {
// The root entry object (effectively a try statement without a catch
// or a finally block) gives us a place to store values thrown from
// locations where there is no enclosing try statement.
this.tryEntries = [{ tryLoc: "root" }];
tryLocsList.forEach(pushTryEntry, this);
this.reset(true);
}
runtime.keys = function (object) {
var keys = [];
for (var key in object) {
keys.push(key);
}
keys.reverse();
// Rather than returning an object with a next method, we keep
// things simple and return the next function itself.
return function next() {
while (keys.length) {
var key = keys.pop();
if (key in object) {
next.value = key;
next.done = false;
return next;
}
}
// To avoid creating an additional object, we just hang the .value
// and .done properties off the next function object itself. This
// also ensures that the minifier will not anonymize the function.
next.done = true;
return next;
};
};
function values(iterable) {
if (iterable) {
var iteratorMethod = iterable[iteratorSymbol];
if (iteratorMethod) {
return iteratorMethod.call(iterable);
}
if (typeof iterable.next === "function") {
return iterable;
}
if (!isNaN(iterable.length)) {
var i = -1, next = function next() {
while (++i < iterable.length) {
if (hasOwn.call(iterable, i)) {
next.value = iterable[i];
next.done = false;
return next;
}
}
next.value = undefined;
next.done = true;
return next;
};
return next.next = next;
}
}
// Return an iterator with no values.
return { next: doneResult };
}
runtime.values = values;
function doneResult() {
return { value: undefined, done: true };
}
Context.prototype = {
constructor: Context,
reset: function (skipTempReset) {
this.prev = 0;
this.next = 0;
// Resetting context._sent for legacy support of Babel's
// function.sent implementation.
this.sent = this._sent = undefined;
this.done = false;
this.delegate = null;
this.method = "next";
this.arg = undefined;
this.tryEntries.forEach(resetTryEntry);
if (!skipTempReset) {
for (var name in this) {
// Not sure about the optimal order of these conditions:
if (name.charAt(0) === "t" &&
hasOwn.call(this, name) &&
!isNaN(+name.slice(1))) {
this[name] = undefined;
}
}
}
},
stop: function () {
this.done = true;
var rootEntry = this.tryEntries[0];
var rootRecord = rootEntry.completion;
if (rootRecord.type === "throw") {
throw rootRecord.arg;
}
return this.rval;
},
dispatchException: function (exception) {
if (this.done) {
throw exception;
}
var context = this;
function handle(loc, caught) {
record.type = "throw";
record.arg = exception;
context.next = loc;
if (caught) {
// If the dispatched exception was caught by a catch block,
// then let that catch block handle the exception normally.
context.method = "next";
context.arg = undefined;
}
return !!caught;
}
for (var i = this.tryEntries.length - 1; i >= 0; --i) {
var entry = this.tryEntries[i];
var record = entry.completion;
if (entry.tryLoc === "root") {
// Exception thrown outside of any try block that could handle
// it, so set the completion value of the entire function to
// throw the exception.
return handle("end");
}
if (entry.tryLoc <= this.prev) {
var hasCatch = hasOwn.call(entry, "catchLoc");
var hasFinally = hasOwn.call(entry, "finallyLoc");
if (hasCatch && hasFinally) {
if (this.prev < entry.catchLoc) {
return handle(entry.catchLoc, true);
} else if (this.prev < entry.finallyLoc) {
return handle(entry.finallyLoc);
}
} else if (hasCatch) {
if (this.prev < entry.catchLoc) {
return handle(entry.catchLoc, true);
}
} else if (hasFinally) {
if (this.prev < entry.finallyLoc) {
return handle(entry.finallyLoc);
}
} else {
throw new Error("try statement without catch or finally");
}
}
}
},
abrupt: function (type, arg) {
for (var i = this.tryEntries.length - 1; i >= 0; --i) {
var entry = this.tryEntries[i];
if (entry.tryLoc <= this.prev &&
hasOwn.call(entry, "finallyLoc") &&
this.prev < entry.finallyLoc) {
var finallyEntry = entry;
break;
}
}
if (finallyEntry &&
(type === "break" ||
type === "continue") &&
finallyEntry.tryLoc <= arg &&
arg <= finallyEntry.finallyLoc) {
// Ignore the finally entry if control is not jumping to a
// location outside the try/catch block.
finallyEntry = null;
}
var record = finallyEntry ? finallyEntry.completion : {};
record.type = type;
record.arg = arg;
if (finallyEntry) {
this.method = "next";
this.next = finallyEntry.finallyLoc;
return ContinueSentinel;
}
return this.complete(record);
},
complete: function (record, afterLoc) {
if (record.type === "throw") {
throw record.arg;
}
if (record.type === "break" ||
record.type === "continue") {
this.next = record.arg;
} else if (record.type === "return") {
this.rval = this.arg = record.arg;
this.method = "return";
this.next = "end";
} else if (record.type === "normal" && afterLoc) {
this.next = afterLoc;
}
return ContinueSentinel;
},
finish: function (finallyLoc) {
for (var i = this.tryEntries.length - 1; i >= 0; --i) {
var entry = this.tryEntries[i];
if (entry.finallyLoc === finallyLoc) {
this.complete(entry.completion, entry.afterLoc);
resetTryEntry(entry);
return ContinueSentinel;
}
}
},
"catch": function (tryLoc) {
for (var i = this.tryEntries.length - 1; i >= 0; --i) {
var entry = this.tryEntries[i];
if (entry.tryLoc === tryLoc) {
var record = entry.completion;
if (record.type === "throw") {
var thrown = record.arg;
resetTryEntry(entry);
}
return thrown;
}
}
// The context.catch method must only be called with a location
// argument that corresponds to a known catch block.
throw new Error("illegal catch attempt");
},
delegateYield: function (iterable, resultName, nextLoc) {
this.delegate = {
iterator: values(iterable),
resultName: resultName,
nextLoc: nextLoc
};
if (this.method === "next") {
// Deliberately forget the last sent value so that we don't
// accidentally pass it on to the delegate.
this.arg = undefined;
}
return ContinueSentinel;
}
};
})(
// In sloppy mode, unbound `this` refers to the global object, fallback to
// Function constructor if we're in global strict mode. That is sadly a form
// of indirect eval which violates Content Security Policy.
(function () { return this })() || Function("return this")()
);
{ {
"ver": "1.0.8", "ver": "1.0.8",
"uuid": "b54300af-b8e5-4b4e-aa2f-9ac1cef7b598", "uuid": "e2e0dcb5-f556-4545-b84a-3e9fb09c0a68",
"isPlugin": true, "isPlugin": true,
"loadPluginInWeb": true, "loadPluginInWeb": true,
"loadPluginInNative": true, "loadPluginInNative": true,
......
...@@ -70,72 +70,9 @@ export function setSprNodeMaxLen(sprNode, maxW, maxH) { ...@@ -70,72 +70,9 @@ export function setSprNodeMaxLen(sprNode, maxW, maxH) {
sprNode.scale = Math.round(s * 1000) / 1000; sprNode.scale = Math.round(s * 1000) / 1000;
} }
export function localPosTolocalPos(baseNode, targetNode) {
const worldPos = targetNode.parent.convertToWorldSpaceAR(cc.v2(targetNode.x, targetNode.y));
const localPos = baseNode.parent.convertToNodeSpaceAR(cc.v2(worldPos.x, worldPos.y));
return localPos;
}
export function worldPosToLocalPos(worldPos, baseNode) {
const localPos = baseNode.parent.convertToNodeSpaceAR(cc.v2(worldPos.x, worldPos.y));
return localPos;
}
export function getScaleRateBy2Node(baseNode, targetNode, maxFlag = true) {
const worldRect1 = targetNode.getBoundingBoxToWorld();
const worldRect2 = baseNode.getBoundingBoxToWorld();
const sx = worldRect1.width / worldRect2.width;
const sy = worldRect1.height / worldRect2.height;
if (maxFlag) {
return Math.max(sx, sy);
} else {
return Math.min(sx, sy);
}
}
export function getDistance (start, end){
var pos = cc.v2(start.x - end.x, start.y - end.y);
var dis = Math.sqrt(pos.x*pos.x + pos.y*pos.y);
return dis;
}
export function playAudioByUrl(audio_url, cb=null) {
if (audio_url) {
cc.assetManager.loadRemote(audio_url, (err, audioClip) => {
const audioId = cc.audioEngine.play(audioClip, false, 0.8);
if (cb) {
cc.audioEngine.setFinishCallback(audioId, () => {
cb();
});
}
});
}
}
export function btnClickAnima(btn, time=0.15, rate=1.05) {
btn.tmpScale = btn.scale;
btn.on(cc.Node.EventType.TOUCH_START, () => {
cc.tween(btn)
.to(time / 2, {scale: btn.scale * rate})
.start()
})
btn.on(cc.Node.EventType.TOUCH_CANCEL, () => {
cc.tween(btn)
.to(time / 2, {scale: btn.tmpScale})
.start()
})
btn.on(cc.Node.EventType.TOUCH_END, () => {
cc.tween(btn)
.to(time / 2, {scale: btn.tmpScale})
.start()
})
}
export function getSpriteFrimeByUrl(url, cb) { export function getSpriteFrimeByUrl(url, cb) {
cc.loader.load({ url }, (err, img) => { cc.loader.load({url}, (err, img) => {
const spriteFrame = new cc.SpriteFrame(img) const spriteFrame = new cc.SpriteFrame(img)
if (cb) { if (cb) {
cb(spriteFrame); cb(spriteFrame);
...@@ -163,7 +100,7 @@ export function getSprNodeByUrl(url, cb) { ...@@ -163,7 +100,7 @@ export function getSprNodeByUrl(url, cb) {
export function playAudio(audioClip, cb = null) { export function playAudio(audioClip, cb=null) {
if (audioClip) { if (audioClip) {
const audioId = cc.audioEngine.playEffect(audioClip, false, 0.8); const audioId = cc.audioEngine.playEffect(audioClip, false, 0.8);
if (cb) { if (cb) {
...@@ -171,9 +108,23 @@ export function playAudio(audioClip, cb = null) { ...@@ -171,9 +108,23 @@ export function playAudio(audioClip, cb = null) {
cb(); cb();
}); });
} }
return audioId;
}
}
export function playAudioByUrl(audio_url, cb=null) {
if (audio_url) {
cc.assetManager.loadRemote(audio_url, (err, audioClip) => {
playAudio(audioClip, cb);
});
} }
} }
export async function asyncDelay(time) { export async function asyncDelay(time) {
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
try { try {
...@@ -341,14 +292,50 @@ export function showTrebleFirework(baseNode, rabbonList) { ...@@ -341,14 +292,50 @@ export function showTrebleFirework(baseNode, rabbonList) {
showFireworks(right); showFireworks(right);
} }
export function onHomeworkFinish() {
const middleLayer = cc.find('middleLayer'); export function delayCall(time, cb) {
if (middleLayer) { return cc.tween({})
const middleLayerComponent = middleLayer.getComponent('middleLayer'); .delay(time)
if (middleLayerComponent.role == 'student') { .call(() => {
middleLayerComponent.onHomeworkFinish(() => { }); if (cb) {
cb();
} }
} else { })
console.log('onHomeworkFinish'); .start();
}
export function removeFromArr(arr, item) {
const index = arr.indexOf(item);
if (index != -1) {
arr.splice(index, 1);
return true;
}
return false;
}
export function showBtnAnima(btn, cb=null) {
const baseS = btn.scale;
cc.tween(btn)
.to(0.05, {scale: 0.9 * baseS})
.to(0.05, {scale: 1 * baseS})
.call(() => {
if (cb) {
cb();
} }
})
.start();
}
export function jellyShake(node) {
const baseS = node.scale;
const time = 1;
cc.tween(node)
.to(time / 5 / 2, {scaleX: baseS * 0.8, scaleY: baseS * 1.2}, {easing: "sineInOut"})
.to(time / 5, {scaleX: baseS * 1.1, scaleY: baseS * 0.9}, {easing: "sineInOut"})
.to(time / 5, {scaleX: baseS * 0.95, scaleY: baseS * 1.15}, {easing: "sineInOut"})
.to(time / 5, {scaleX: baseS * 1.02, scaleY: baseS * 0.98}, {easing: "sineInOut"})
.to(time / 5, {scaleX: baseS * 1, scaleY: baseS * 1}, {easing: "sineInOut"})
.start();
} }
\ No newline at end of file
{ {
"ver": "1.0.8", "ver": "1.0.8",
"uuid": "ade7af40-d56d-4087-bbc6-2888fef55353", "uuid": "25ccf041-bdf3-4b6a-8683-c24e4c39fed4",
"isPlugin": false, "isPlugin": false,
"loadPluginInWeb": true, "loadPluginInWeb": true,
"loadPluginInNative": true, "loadPluginInNative": true,
......
{
"ver": "1.1.2",
"uuid": "2582562a-54bb-483a-8483-727d57c6c974",
"isBundle": false,
"bundleName": "",
"priority": 1,
"compressionType": {},
"optimizeHotUpdate": {},
"inlineSpriteFrames": {},
"isRemoteBundle": {},
"subMetas": {}
}
\ No newline at end of file
{ {
"ver": "1.1.0", "ver": "1.1.0",
"uuid": "c551970e-b095-45f3-9f1d-25cde8b8deb1", "uuid": "f4ebd988-078f-4f85-b843-133e12c5774e",
"subMetas": {} "subMetas": {}
} }
\ No newline at end of file
{
"ver": "2.3.5",
"uuid": "835caf90-a4a3-49b7-891c-8b9628c6c1a3",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 29,
"height": 29,
"platformSettings": {},
"subMetas": {
"Img_paper": {
"ver": "1.0.4",
"uuid": "b4eaff45-6718-4047-9d8f-5ecea01f08ae",
"rawTextureUuid": "835caf90-a4a3-49b7-891c-8b9628c6c1a3",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 29,
"height": 29,
"rawWidth": 29,
"rawHeight": 29,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{ {
"ver": "2.3.5", "ver": "2.3.5",
"uuid": "e1b4d971-9876-4832-803a-5a321964a78b", "uuid": "d9e1514c-10d5-4e20-acb8-17e57fc3d1e5",
"type": "sprite", "type": "sprite",
"wrapMode": "clamp", "wrapMode": "clamp",
"filterMode": "bilinear", "filterMode": "bilinear",
...@@ -13,8 +13,8 @@ ...@@ -13,8 +13,8 @@
"subMetas": { "subMetas": {
"bg": { "bg": {
"ver": "1.0.4", "ver": "1.0.4",
"uuid": "8288e3d4-4c75-4b27-8f01-f7014417f4dd", "uuid": "8f91b960-a198-4876-9fe1-f956ecbd765b",
"rawTextureUuid": "e1b4d971-9876-4832-803a-5a321964a78b", "rawTextureUuid": "d9e1514c-10d5-4e20-acb8-17e57fc3d1e5",
"trimType": "auto", "trimType": "auto",
"trimThreshold": 1, "trimThreshold": 1,
"rotated": false, "rotated": false,
......
{
"ver": "2.3.5",
"uuid": "08b40084-2634-4cc3-818d-f396a15a951d",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 1280,
"height": 697,
"platformSettings": {},
"subMetas": {
"bg_2": {
"ver": "1.0.4",
"uuid": "b5e75143-dbe8-4edd-b6bb-f60633fe052b",
"rawTextureUuid": "08b40084-2634-4cc3-818d-f396a15a951d",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 1280,
"height": 697,
"rawWidth": 1280,
"rawHeight": 697,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{
"ver": "2.3.5",
"uuid": "5624a60d-df0d-48f5-9a29-2e7924ff02e5",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 36,
"height": 24,
"platformSettings": {},
"subMetas": {
"bg_sahua": {
"ver": "1.0.4",
"uuid": "0290c32f-9b41-4ec2-ab60-4e07ac969a63",
"rawTextureUuid": "5624a60d-df0d-48f5-9a29-2e7924ff02e5",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 36,
"height": 24,
"rawWidth": 36,
"rawHeight": 24,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{
"ver": "2.3.5",
"uuid": "249674f2-ae69-4209-a8f4-901abe8a860b",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 454,
"height": 113,
"platformSettings": {},
"subMetas": {
"bg_tryagain": {
"ver": "1.0.4",
"uuid": "80e29b22-f373-485c-8211-8b57da727698",
"rawTextureUuid": "249674f2-ae69-4209-a8f4-901abe8a860b",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 454,
"height": 113,
"rawWidth": 454,
"rawHeight": 113,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{
"ver": "2.3.5",
"uuid": "dc8809fe-b291-4bcd-a0ed-cebff8dcfeb5",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 201,
"height": 89,
"platformSettings": {},
"subMetas": {
"btn_check": {
"ver": "1.0.4",
"uuid": "650c7ec5-6cd8-4a7e-91db-a0b1343086d6",
"rawTextureUuid": "dc8809fe-b291-4bcd-a0ed-cebff8dcfeb5",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 201,
"height": 89,
"rawWidth": 201,
"rawHeight": 89,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{
"ver": "2.3.5",
"uuid": "7a7f137e-d523-4454-9232-f93a2a475acf",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 384,
"height": 151,
"platformSettings": {},
"subMetas": {
"btn_restart": {
"ver": "1.0.4",
"uuid": "bf3b1fe2-41ed-4842-9db3-29f3d7304593",
"rawTextureUuid": "7a7f137e-d523-4454-9232-f93a2a475acf",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 384,
"height": 151,
"rawWidth": 384,
"rawHeight": 151,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{
"ver": "2.3.5",
"uuid": "6b03a6fc-96d5-49a3-817e-368e7ed68e06",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 278,
"height": 275,
"platformSettings": {},
"subMetas": {
"icon_bigstar": {
"ver": "1.0.4",
"uuid": "13ba294e-e1ed-4529-adb4-fde4d01710d6",
"rawTextureUuid": "6b03a6fc-96d5-49a3-817e-368e7ed68e06",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 278,
"height": 275,
"rawWidth": 278,
"rawHeight": 275,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{
"ver": "2.3.5",
"uuid": "b93b9aee-483b-45e1-89d6-b3d5e482b4ee",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 122,
"height": 95,
"platformSettings": {},
"subMetas": {
"icon_right": {
"ver": "1.0.4",
"uuid": "661ccc57-af7c-4bb8-b740-6b7f29f84b7a",
"rawTextureUuid": "b93b9aee-483b-45e1-89d6-b3d5e482b4ee",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 122,
"height": 95,
"rawWidth": 122,
"rawHeight": 95,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{ {
"ver": "2.3.5", "ver": "2.3.5",
"uuid": "18d07592-51a9-421e-8972-0f67b68d29e1", "uuid": "936aa108-3147-4785-8b89-a84ce7eb5b3c",
"type": "sprite", "type": "sprite",
"wrapMode": "clamp", "wrapMode": "clamp",
"filterMode": "bilinear", "filterMode": "bilinear",
"premultiplyAlpha": false, "premultiplyAlpha": false,
"genMipmaps": false, "genMipmaps": false,
"packable": true, "packable": true,
"width": 144, "width": 407,
"height": 144, "height": 303,
"platformSettings": {}, "platformSettings": {},
"subMetas": { "subMetas": {
"icon": { "op_pic_bg_big": {
"ver": "1.0.4", "ver": "1.0.4",
"uuid": "6fbc30a8-3c49-44ae-8ba4-7f56f385b78a", "uuid": "c7896147-2816-4fcc-a13d-d9a5c5ed48e6",
"rawTextureUuid": "18d07592-51a9-421e-8972-0f67b68d29e1", "rawTextureUuid": "936aa108-3147-4785-8b89-a84ce7eb5b3c",
"trimType": "auto", "trimType": "auto",
"trimThreshold": 1, "trimThreshold": 1,
"rotated": false, "rotated": false,
"offsetX": 0, "offsetX": 0,
"offsetY": -0.5, "offsetY": 0,
"trimX": 3, "trimX": 9,
"trimY": 2, "trimY": 9,
"width": 138, "width": 389,
"height": 141, "height": 285,
"rawWidth": 144, "rawWidth": 407,
"rawHeight": 144, "rawHeight": 303,
"borderTop": 0, "borderTop": 0,
"borderBottom": 0, "borderBottom": 0,
"borderLeft": 0, "borderLeft": 0,
......
{
"ver": "2.3.5",
"uuid": "c3650da3-110a-4680-b9aa-b474f5f6afc6",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 407,
"height": 303,
"platformSettings": {},
"subMetas": {
"op_pic_bg_big_l": {
"ver": "1.0.4",
"uuid": "7ab8b8ad-24a7-49d9-b6e4-0732819ca9d5",
"rawTextureUuid": "c3650da3-110a-4680-b9aa-b474f5f6afc6",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 407,
"height": 303,
"rawWidth": 407,
"rawHeight": 303,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{
"ver": "2.3.5",
"uuid": "1e7f443e-a48b-4e9a-b0b7-9626067e2e73",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 693,
"height": 129,
"platformSettings": {},
"subMetas": {
"op_text_bg_big": {
"ver": "1.0.4",
"uuid": "3a8d36c2-5da6-4db3-a12f-9ecf09eae275",
"rawTextureUuid": "1e7f443e-a48b-4e9a-b0b7-9626067e2e73",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 9,
"trimY": 9,
"width": 675,
"height": 111,
"rawWidth": 693,
"rawHeight": 129,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{
"ver": "2.3.5",
"uuid": "eb5e00c5-a7d1-4229-b7ff-6ef298d1e341",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 693,
"height": 129,
"platformSettings": {},
"subMetas": {
"op_text_bg_big_l": {
"ver": "1.0.4",
"uuid": "60266da8-c9d2-4a4e-b071-3377c5bb7678",
"rawTextureUuid": "eb5e00c5-a7d1-4229-b7ff-6ef298d1e341",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 693,
"height": 129,
"rawWidth": 693,
"rawHeight": 129,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{
"ver": "2.3.5",
"uuid": "4013e8e6-89b6-4009-ae14-82d8c0d4c206",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 307,
"height": 227,
"platformSettings": {},
"subMetas": {
"option_pic_bg": {
"ver": "1.0.4",
"uuid": "880dfb40-3c9e-47b9-8dc8-89f461cf77fd",
"rawTextureUuid": "4013e8e6-89b6-4009-ae14-82d8c0d4c206",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 5,
"trimY": 5,
"width": 297,
"height": 217,
"rawWidth": 307,
"rawHeight": 227,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{
"ver": "2.3.5",
"uuid": "7c559c61-33e5-4aaa-a857-742510f020c3",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 307,
"height": 227,
"platformSettings": {},
"subMetas": {
"option_pic_bg_l": {
"ver": "1.0.4",
"uuid": "4521834b-37c2-41be-89fc-399039615867",
"rawTextureUuid": "7c559c61-33e5-4aaa-a857-742510f020c3",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 307,
"height": 227,
"rawWidth": 307,
"rawHeight": 227,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{
"ver": "2.3.5",
"uuid": "2ab96811-4682-4ee2-b37d-24367dc50c57",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 604,
"height": 108,
"platformSettings": {},
"subMetas": {
"option_text_bg": {
"ver": "1.0.4",
"uuid": "1ae2b508-0ca6-41ab-b0cf-a8057c827641",
"rawTextureUuid": "2ab96811-4682-4ee2-b37d-24367dc50c57",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 5,
"trimY": 5,
"width": 594,
"height": 98,
"rawWidth": 604,
"rawHeight": 108,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{
"ver": "2.3.5",
"uuid": "4be747a4-bfcc-4fe8-9042-2a530b3dfa1d",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 604,
"height": 108,
"platformSettings": {},
"subMetas": {
"option_text_bg_l": {
"ver": "1.0.4",
"uuid": "f347f17e-d969-416c-940c-d0c308f1b04b",
"rawTextureUuid": "4be747a4-bfcc-4fe8-9042-2a530b3dfa1d",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 604,
"height": 108,
"rawWidth": 604,
"rawHeight": 108,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{
"ver": "2.3.5",
"uuid": "ceb1f68c-c977-4d96-9684-c93c92fcb78a",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 702,
"height": 418,
"platformSettings": {},
"subMetas": {
"ques_pic_bg": {
"ver": "1.0.4",
"uuid": "7d246caa-ac10-4456-bec3-e9c951aaa187",
"rawTextureUuid": "ceb1f68c-c977-4d96-9684-c93c92fcb78a",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 702,
"height": 418,
"rawWidth": 702,
"rawHeight": 418,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{
"ver": "2.3.5",
"uuid": "ebf0021f-1714-474e-bc59-31f96370f55c",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 62,
"height": 69,
"platformSettings": {},
"subMetas": {
"star": {
"ver": "1.0.4",
"uuid": "7fe7a583-8be5-4f05-8f51-1ca529a0437e",
"rawTextureUuid": "ebf0021f-1714-474e-bc59-31f96370f55c",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 62,
"height": 69,
"rawWidth": 62,
"rawHeight": 69,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{ {
"ver": "2.3.5", "ver": "2.3.5",
"uuid": "d582359e-924e-4ee9-9964-1fc4bb417e71", "uuid": "4a570528-225e-4eb9-8a5c-ea566d8056f6",
"type": "sprite", "type": "sprite",
"wrapMode": "clamp", "wrapMode": "clamp",
"filterMode": "bilinear", "filterMode": "bilinear",
"premultiplyAlpha": false, "premultiplyAlpha": false,
"genMipmaps": false, "genMipmaps": false,
"packable": true, "packable": true,
"width": 61, "width": 62,
"height": 67, "height": 69,
"platformSettings": {}, "platformSettings": {},
"subMetas": { "subMetas": {
"btn_right": { "star_bg": {
"ver": "1.0.4", "ver": "1.0.4",
"uuid": "e5a2dbaa-a677-4a32-90d7-a1b057d7fb59", "uuid": "292fce96-423a-4bb1-b1cc-6f3a61e85600",
"rawTextureUuid": "d582359e-924e-4ee9-9964-1fc4bb417e71", "rawTextureUuid": "4a570528-225e-4eb9-8a5c-ea566d8056f6",
"trimType": "auto", "trimType": "auto",
"trimThreshold": 1, "trimThreshold": 1,
"rotated": false, "rotated": false,
"offsetX": -0.5, "offsetX": 0,
"offsetY": 0.5, "offsetY": 1.5,
"trimX": 0, "trimX": 0,
"trimY": 0, "trimY": 0,
"width": 60, "width": 62,
"height": 66, "height": 66,
"rawWidth": 61, "rawWidth": 62,
"rawHeight": 67, "rawHeight": 69,
"borderTop": 0, "borderTop": 0,
"borderBottom": 0, "borderBottom": 0,
"borderLeft": 0, "borderLeft": 0,
......
{
"ver": "2.3.5",
"uuid": "85e63127-58d8-450d-958d-31b5051eacd3",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 454,
"height": 113,
"platformSettings": {},
"subMetas": {
"try_again": {
"ver": "1.0.4",
"uuid": "f1e0a458-e66d-4117-a0af-71eb95828ab0",
"rawTextureUuid": "85e63127-58d8-450d-958d-31b5051eacd3",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 454,
"height": 113,
"rawWidth": 454,
"rawHeight": 113,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{
"ver": "2.3.5",
"uuid": "40cbfffa-0736-4622-9f69-3d6b0a8be067",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 105,
"height": 126,
"platformSettings": {},
"subMetas": {
"video_pause": {
"ver": "1.0.4",
"uuid": "711e8b24-ba5d-4ed4-a59e-8e131229934d",
"rawTextureUuid": "40cbfffa-0736-4622-9f69-3d6b0a8be067",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 105,
"height": 126,
"rawWidth": 105,
"rawHeight": 126,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{
"ver": "2.3.5",
"uuid": "f2cdf783-a046-4d26-89c3-a928fcbcd7f3",
"type": "sprite",
"wrapMode": "clamp",
"filterMode": "bilinear",
"premultiplyAlpha": false,
"genMipmaps": false,
"packable": true,
"width": 105,
"height": 126,
"platformSettings": {},
"subMetas": {
"video_play": {
"ver": "1.0.4",
"uuid": "c68e0cd3-7e00-4478-8a33-923a7da0c85d",
"rawTextureUuid": "f2cdf783-a046-4d26-89c3-a928fcbcd7f3",
"trimType": "auto",
"trimThreshold": 1,
"rotated": false,
"offsetX": 0,
"offsetY": 0,
"trimX": 0,
"trimY": 0,
"width": 105,
"height": 126,
"rawWidth": 105,
"rawHeight": 126,
"borderTop": 0,
"borderBottom": 0,
"borderLeft": 0,
"borderRight": 0,
"subMetas": {}
}
}
}
\ No newline at end of file
{
"ver": "1.1.2",
"uuid": "e8bd16b0-3804-45a9-a8ca-f52c02224f55",
"isBundle": false,
"bundleName": "",
"priority": 1,
"compressionType": {},
"optimizeHotUpdate": {},
"inlineSpriteFrames": {},
"isRemoteBundle": {},
"subMetas": {}
}
\ No newline at end of file
[
{
"__type__": "cc.SceneAsset",
"_name": "",
"_objFlags": 0,
"_native": "",
"scene": {
"__id__": 1
}
},
{
"__type__": "cc.Scene",
"_objFlags": 0,
"_parent": null,
"_children": [
{
"__id__": 2
}
],
"_active": false,
"_components": [],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 0,
"height": 0
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0,
"y": 0
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
0,
0,
0,
0,
0,
0,
1,
1,
1,
1
]
},
"_is3DNode": true,
"_groupIndex": 0,
"groupIndex": 0,
"autoReleaseAssets": true,
"_id": "57ea7c61-9b8b-498a-b024-c98ee9124beb"
},
{
"__type__": "cc.Node",
"_name": "Canvas",
"_objFlags": 0,
"_parent": {
"__id__": 1
},
"_children": [
{
"__id__": 3
},
{
"__id__": 5
},
{
"__id__": 7
},
{
"__id__": 14
}
],
"_active": true,
"_components": [
{
"__id__": 24
},
{
"__id__": 25
},
{
"__id__": 26
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 1280,
"height": 720
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
640,
360,
0,
0,
0,
0,
1,
1,
1,
1
]
},
"_eulerAngles": {
"__type__": "cc.Vec3",
"x": 0,
"y": 0,
"z": 0
},
"_skewX": 0,
"_skewY": 0,
"_is3DNode": false,
"_groupIndex": 0,
"groupIndex": 0,
"_id": "a5esZu+45LA5mBpvttspPD"
},
{
"__type__": "cc.Node",
"_name": "Main Camera",
"_objFlags": 0,
"_parent": {
"__id__": 2
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 4
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 1280,
"height": 720
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
0,
0,
362.85545494732423,
0,
0,
0,
1,
1,
1,
1
]
},
"_eulerAngles": {
"__type__": "cc.Vec3",
"x": 0,
"y": 0,
"z": 0
},
"_skewX": 0,
"_skewY": 0,
"_is3DNode": false,
"_groupIndex": 0,
"groupIndex": 0,
"_id": "e1WoFrQ79G7r4ZuQE3HlNb"
},
{
"__type__": "cc.Camera",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 3
},
"_enabled": true,
"_cullingMask": 4294967295,
"_clearFlags": 7,
"_backgroundColor": {
"__type__": "cc.Color",
"r": 0,
"g": 0,
"b": 0,
"a": 255
},
"_depth": -1,
"_zoomRatio": 1,
"_targetTexture": null,
"_fov": 60,
"_orthoSize": 10,
"_nearClip": 1,
"_farClip": 4096,
"_ortho": true,
"_rect": {
"__type__": "cc.Rect",
"x": 0,
"y": 0,
"width": 1,
"height": 1
},
"_renderStages": 1,
"_alignWithScreen": true,
"_id": "81GN3uXINKVLeW4+iKSlim"
},
{
"__type__": "cc.Node",
"_name": "bg",
"_objFlags": 0,
"_parent": {
"__id__": 2
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 6
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 1280,
"height": 720
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
0,
0,
0,
0,
0,
0,
1,
1,
1,
1
]
},
"_eulerAngles": {
"__type__": "cc.Vec3",
"x": 0,
"y": 0,
"z": 0
},
"_skewX": 0,
"_skewY": 0,
"_is3DNode": false,
"_groupIndex": 0,
"groupIndex": 0,
"_id": "32MJMZ2HRGF4BOf533Avyi"
},
{
"__type__": "cc.Sprite",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 5
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_spriteFrame": {
"__uuid__": "8288e3d4-4c75-4b27-8f01-f7014417f4dd"
},
"_type": 0,
"_sizeMode": 1,
"_fillType": 0,
"_fillCenter": {
"__type__": "cc.Vec2",
"x": 0,
"y": 0
},
"_fillStart": 0,
"_fillRange": 0,
"_isTrimmedMode": true,
"_atlas": null,
"_id": "97/S6HDq9MeqgmV1Zwnhbb"
},
{
"__type__": "cc.Node",
"_name": "bottomPart",
"_objFlags": 0,
"_parent": {
"__id__": 2
},
"_children": [
{
"__id__": 8
},
{
"__id__": 11
}
],
"_active": true,
"_components": [],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 0,
"height": 0
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
635.132,
-356.326,
0,
0,
0,
0,
1,
1,
1,
1
]
},
"_eulerAngles": {
"__type__": "cc.Vec3",
"x": 0,
"y": 0,
"z": 0
},
"_skewX": 0,
"_skewY": 0,
"_is3DNode": false,
"_groupIndex": 0,
"groupIndex": 0,
"_id": "8c7k8ep/ZFNpO263+1QHz9"
},
{
"__type__": "cc.Node",
"_name": "btn_left",
"_objFlags": 0,
"_parent": {
"__id__": 7
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 9
},
{
"__id__": 10
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 61,
"height": 67
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
-148.464,
34,
0,
0,
0,
0,
1,
1,
1,
1
]
},
"_eulerAngles": {
"__type__": "cc.Vec3",
"x": 0,
"y": 0,
"z": 0
},
"_skewX": 0,
"_skewY": 0,
"_is3DNode": false,
"_groupIndex": 0,
"groupIndex": 0,
"_id": "5ad2wLQLxIN5Eg7OHecSH6"
},
{
"__type__": "cc.Sprite",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 8
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_spriteFrame": {
"__uuid__": "ce19457d-e8f3-4c38-ae3e-d4b99208ddb5"
},
"_type": 0,
"_sizeMode": 1,
"_fillType": 0,
"_fillCenter": {
"__type__": "cc.Vec2",
"x": 0,
"y": 0
},
"_fillStart": 0,
"_fillRange": 0,
"_isTrimmedMode": true,
"_atlas": null,
"_id": "84mqOgJ3JNqZrYVTEU8CjE"
},
{
"__type__": "cc.Button",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 8
},
"_enabled": true,
"_normalMaterial": null,
"_grayMaterial": null,
"duration": 0.1,
"zoomScale": 1.2,
"clickEvents": [],
"_N$interactable": true,
"_N$enableAutoGrayEffect": false,
"_N$transition": 0,
"transition": 0,
"_N$normalColor": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_N$pressedColor": {
"__type__": "cc.Color",
"r": 211,
"g": 211,
"b": 211,
"a": 255
},
"pressedColor": {
"__type__": "cc.Color",
"r": 211,
"g": 211,
"b": 211,
"a": 255
},
"_N$hoverColor": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"hoverColor": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_N$disabledColor": {
"__type__": "cc.Color",
"r": 124,
"g": 124,
"b": 124,
"a": 255
},
"_N$normalSprite": null,
"_N$pressedSprite": null,
"pressedSprite": null,
"_N$hoverSprite": null,
"hoverSprite": null,
"_N$disabledSprite": null,
"_N$target": null,
"_id": "bcYN/4EKBJhbIAfovo9Ah1"
},
{
"__type__": "cc.Node",
"_name": "btn_right",
"_objFlags": 0,
"_parent": {
"__id__": 7
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 12
},
{
"__id__": 13
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 60,
"height": 66
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
-47.164,
34,
0,
0,
0,
0,
1,
1,
1,
1
]
},
"_eulerAngles": {
"__type__": "cc.Vec3",
"x": 0,
"y": 0,
"z": 0
},
"_skewX": 0,
"_skewY": 0,
"_is3DNode": false,
"_groupIndex": 0,
"groupIndex": 0,
"_id": "46i3stdzpHX6zQHTGnRsNE"
},
{
"__type__": "cc.Sprite",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 11
},
"_enabled": true,
"_materials": [
{
"__uuid__": "eca5d2f2-8ef6-41c2-bbe6-f9c79d09c432"
}
],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_spriteFrame": {
"__uuid__": "e5a2dbaa-a677-4a32-90d7-a1b057d7fb59"
},
"_type": 0,
"_sizeMode": 1,
"_fillType": 0,
"_fillCenter": {
"__type__": "cc.Vec2",
"x": 0,
"y": 0
},
"_fillStart": 0,
"_fillRange": 0,
"_isTrimmedMode": true,
"_atlas": null,
"_id": "42Sh8QS/BHn4WiGyPQPKPt"
},
{
"__type__": "cc.Button",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 11
},
"_enabled": true,
"_normalMaterial": null,
"_grayMaterial": null,
"duration": 0.1,
"zoomScale": 1.2,
"clickEvents": [],
"_N$interactable": true,
"_N$enableAutoGrayEffect": false,
"_N$transition": 0,
"transition": 0,
"_N$normalColor": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_N$pressedColor": {
"__type__": "cc.Color",
"r": 211,
"g": 211,
"b": 211,
"a": 255
},
"pressedColor": {
"__type__": "cc.Color",
"r": 211,
"g": 211,
"b": 211,
"a": 255
},
"_N$hoverColor": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"hoverColor": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_N$disabledColor": {
"__type__": "cc.Color",
"r": 124,
"g": 124,
"b": 124,
"a": 255
},
"_N$normalSprite": null,
"_N$pressedSprite": null,
"pressedSprite": null,
"_N$hoverSprite": null,
"hoverSprite": null,
"_N$disabledSprite": null,
"_N$target": null,
"_id": "1aj32fYY1IxLesa77E70Qu"
},
{
"__type__": "cc.Node",
"_name": "res",
"_objFlags": 0,
"_parent": {
"__id__": 2
},
"_children": [
{
"__id__": 15
},
{
"__id__": 18
},
{
"__id__": 21
}
],
"_active": false,
"_components": [],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 0,
"height": 0
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
0,
0,
0,
0,
0,
0,
1,
1,
1,
1
]
},
"_eulerAngles": {
"__type__": "cc.Vec3",
"x": 0,
"y": 0,
"z": 0
},
"_skewX": 0,
"_skewY": 0,
"_is3DNode": false,
"_groupIndex": 0,
"groupIndex": 0,
"_id": "0aAzbH6R1E+6AmGRrkKa5O"
},
{
"__type__": "cc.Node",
"_name": "font",
"_objFlags": 0,
"_parent": {
"__id__": 14
},
"_children": [
{
"__id__": 16
}
],
"_active": true,
"_components": [],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 0,
"height": 0
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
0,
0,
0,
0,
0,
0,
1,
1,
1,
1
]
},
"_eulerAngles": {
"__type__": "cc.Vec3",
"x": 0,
"y": 0,
"z": 0
},
"_skewX": 0,
"_skewY": 0,
"_is3DNode": false,
"_groupIndex": 0,
"groupIndex": 0,
"_id": "9bLfcYeeNKrr524vzWchiM"
},
{
"__type__": "cc.Node",
"_name": "BRLNSDB",
"_objFlags": 0,
"_parent": {
"__id__": 15
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 17
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 0,
"height": 0
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
0,
0,
0,
0,
0,
0,
1,
1,
1,
1
]
},
"_eulerAngles": {
"__type__": "cc.Vec3",
"x": 0,
"y": 0,
"z": 0
},
"_skewX": 0,
"_skewY": 0,
"_is3DNode": false,
"_groupIndex": 0,
"groupIndex": 0,
"_id": "cfMLGsq0BMhJARv+ySMAxS"
},
{
"__type__": "cc.Label",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 16
},
"_enabled": true,
"_materials": [],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_useOriginalSize": true,
"_string": "",
"_N$string": "",
"_fontSize": 40,
"_lineHeight": 40,
"_enableWrapText": true,
"_N$file": {
"__uuid__": "c551970e-b095-45f3-9f1d-25cde8b8deb1"
},
"_isSystemFontUsed": false,
"_spacingX": 0,
"_batchAsBitmap": false,
"_styleFlags": 0,
"_underlineHeight": 0,
"_N$horizontalAlign": 0,
"_N$verticalAlign": 0,
"_N$fontFamily": "Arial",
"_N$overflow": 0,
"_N$cacheMode": 0,
"_id": "9bNHNPu5lC7rQYyr8ai/sY"
},
{
"__type__": "cc.Node",
"_name": "img",
"_objFlags": 0,
"_parent": {
"__id__": 14
},
"_children": [
{
"__id__": 19
}
],
"_active": true,
"_components": [],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 0,
"height": 0
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
0,
0,
0,
0,
0,
0,
1,
1,
1,
1
]
},
"_eulerAngles": {
"__type__": "cc.Vec3",
"x": 0,
"y": 0,
"z": 0
},
"_skewX": 0,
"_skewY": 0,
"_is3DNode": false,
"_groupIndex": 0,
"groupIndex": 0,
"_id": "53LUHHG2pEr79fyrvazXJs"
},
{
"__type__": "cc.Node",
"_name": "icon",
"_objFlags": 0,
"_parent": {
"__id__": 18
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 20
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 138,
"height": 141
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
0,
0,
0,
0,
0,
0,
1,
1,
1,
1
]
},
"_eulerAngles": {
"__type__": "cc.Vec3",
"x": 0,
"y": 0,
"z": 0
},
"_skewX": 0,
"_skewY": 0,
"_is3DNode": false,
"_groupIndex": 0,
"groupIndex": 0,
"_id": "1blU2OArJIfoC9XfupGxJG"
},
{
"__type__": "cc.Sprite",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 19
},
"_enabled": true,
"_materials": [],
"_srcBlendFactor": 770,
"_dstBlendFactor": 771,
"_spriteFrame": {
"__uuid__": "6fbc30a8-3c49-44ae-8ba4-7f56f385b78a"
},
"_type": 0,
"_sizeMode": 1,
"_fillType": 0,
"_fillCenter": {
"__type__": "cc.Vec2",
"x": 0,
"y": 0
},
"_fillStart": 0,
"_fillRange": 0,
"_isTrimmedMode": true,
"_atlas": null,
"_id": "03GEWUEZJGyKormWgIWCtM"
},
{
"__type__": "cc.Node",
"_name": "audio",
"_objFlags": 0,
"_parent": {
"__id__": 14
},
"_children": [
{
"__id__": 22
}
],
"_active": true,
"_components": [],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 0,
"height": 0
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
0,
0,
0,
0,
0,
0,
1,
1,
1,
1
]
},
"_eulerAngles": {
"__type__": "cc.Vec3",
"x": 0,
"y": 0,
"z": 0
},
"_skewX": 0,
"_skewY": 0,
"_is3DNode": false,
"_groupIndex": 0,
"groupIndex": 0,
"_id": "b823DIVC9L+Ihc3T9Bt7m3"
},
{
"__type__": "cc.Node",
"_name": "btn",
"_objFlags": 0,
"_parent": {
"__id__": 21
},
"_children": [],
"_active": true,
"_components": [
{
"__id__": 23
}
],
"_prefab": null,
"_opacity": 255,
"_color": {
"__type__": "cc.Color",
"r": 255,
"g": 255,
"b": 255,
"a": 255
},
"_contentSize": {
"__type__": "cc.Size",
"width": 0,
"height": 0
},
"_anchorPoint": {
"__type__": "cc.Vec2",
"x": 0.5,
"y": 0.5
},
"_trs": {
"__type__": "TypedArray",
"ctor": "Float64Array",
"array": [
0,
0,
0,
0,
0,
0,
1,
1,
1,
1
]
},
"_eulerAngles": {
"__type__": "cc.Vec3",
"x": 0,
"y": 0,
"z": 0
},
"_skewX": 0,
"_skewY": 0,
"_is3DNode": false,
"_groupIndex": 0,
"groupIndex": 0,
"_id": "3d0p0/uJZJIoRva5Br2iqv"
},
{
"__type__": "cc.AudioSource",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 22
},
"_enabled": true,
"_clip": {
"__uuid__": "f0680ae0-c079-45ef-abd7-9e63d90b982b"
},
"_volume": 1,
"_mute": false,
"_loop": false,
"playOnLoad": false,
"preload": false,
"_id": "0adN50f61DlbmppsPkOnjX"
},
{
"__type__": "cc.Canvas",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 2
},
"_enabled": true,
"_designResolution": {
"__type__": "cc.Size",
"width": 1280,
"height": 720
},
"_fitWidth": false,
"_fitHeight": false,
"_id": "59Cd0ovbdF4byw5sbjJDx7"
},
{
"__type__": "cc.Widget",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 2
},
"_enabled": true,
"alignMode": 1,
"_target": null,
"_alignFlags": 45,
"_left": 0,
"_right": 0,
"_top": 0,
"_bottom": 0,
"_verticalCenter": 0,
"_horizontalCenter": 0,
"_isAbsLeft": true,
"_isAbsRight": true,
"_isAbsTop": true,
"_isAbsBottom": true,
"_isAbsHorizontalCenter": true,
"_isAbsVerticalCenter": true,
"_originalWidth": 0,
"_originalHeight": 0,
"_id": "29zXboiXFBKoIV4PQ2liTe"
},
{
"__type__": "f4edeRi+NdAabqAkVYRwFjK",
"_name": "",
"_objFlags": 0,
"node": {
"__id__": 2
},
"_enabled": true,
"_id": "e687yyoRBIzZAOVRL8Sseh"
}
]
\ No newline at end of file
import { onHomeworkFinish } from "../script/util";
import { defaultData } from "../script/defaultData";
cc.Class({
extends: cc.Component,
properties: {
},
// 生命周期 onLoad
onLoad() {
this.initSceneData();
this.initSize();
},
_imageResList: null,
_audioResList: null,
_animaResList: null,
initSceneData() {
this._imageResList = [];
this._audioResList = [];
this._animaResList = [];
},
_designSize: null, // 设计分辨率
_frameSize: null, // 屏幕分辨率
_mapScaleMin: null, // 场景中常用缩放(取大值)
_mapScaleMax: null, // 场景中常用缩放(取小值)
_cocosScale: null, // cocos 自缩放 (较少用到)
initSize() {
// 注意cc.winSize只有在适配后(修改fitHeight/fitWidth后)才能获取到正确的值,因此使用cc.getFrameSize()来获取初始的屏幕大小
let screen_size = cc.view.getFrameSize().width / cc.view.getFrameSize().height
let design_size = cc.Canvas.instance.designResolution.width / cc.Canvas.instance.designResolution.height
let f = screen_size >= design_size
cc.Canvas.instance.fitHeight = f
cc.Canvas.instance.fitWidth = !f
const frameSize = cc.view.getFrameSize();
this._frameSize = frameSize;
this._designSize = cc.view.getDesignResolutionSize();
let sx = cc.winSize.width / frameSize.width;
let sy = cc.winSize.height / frameSize.height;
this._cocosScale = Math.min(sx, sy);
sx = frameSize.width / this._designSize.width;
sy = frameSize.height / this._designSize.height;
this._mapScaleMin = Math.min(sx, sy) * this._cocosScale;
this._mapScaleMax = Math.max(sx, sy) * this._cocosScale;
},
// 生命周期 start
start() {
let getData = this.getData.bind(this);
if (window && window.courseware) {
getData = window.courseware.getData;
}
getData((data) => {
console.log('data:', data);
this.data = data || this.getDefaultData();
this.data = JSON.parse(JSON.stringify(this.data))
this.preloadItem()
})
},
getData(func) {
if (window && window.courseware) {
window.courseware.getData(func, 'scene');
return;
}
const middleLayer = cc.find('middleLayer');
if (middleLayer) {
const middleLayerComponent = middleLayer.getComponent('middleLayer');
middleLayerComponent.getData(func);
return;
}
func(this.getDefaultData());
},
getDefaultData() {
return defaultData;
},
preloadItem() {
this.addPreloadImage();
this.addPreloadAudio();
this.addPreloadAnima();
this.preload();
},
addPreloadImage() {
this._imageResList.push({ url: this.data.pic_url });
this._imageResList.push({ url: this.data.pic_url_2 });
},
addPreloadAudio() {
this._audioResList.push({ url: this.data.audio_url });
},
addPreloadAnima() {
},
preload() {
const preloadArr = this._imageResList.concat(this._audioResList).concat(this._animaResList);
cc.assetManager.loadAny(preloadArr, null, null, (err, data) => {
this.loadEnd();
if (window && window["air"]) {
window["air"].hideAirClassLoading();
}
cc.debug.setDisplayStats(false);
});
},
loadEnd() {
this.initData();
this.initAudio();
this.initView();
// this.initListener();
},
_cantouch: null,
initData() {
// 所有全局变量 默认都是null
this._cantouch = true;
},
audioBtn: null,
initAudio() {
const audioNode = cc.find('Canvas/res/audio');
const getAudioByResName = (resName) => {
return audioNode.getChildByName(resName).getComponent(cc.AudioSource);
}
this.audioBtn = getAudioByResName('btn');
},
initView() {
this.initBg();
this.initPic();
this.initBtn();
this.initIcon();
},
initBg() {
const bgNode = cc.find('Canvas/bg');
bgNode.scale = this._mapScaleMax;
},
pic1: null,
pic2: null,
initPic() {
const canvas = cc.find('Canvas');
const maxW = canvas.width * 0.7;
this.getSprNodeByUrl(this.data.pic_url, (sprNode) => {
const picNode1 = sprNode;
picNode1.scale = maxW / picNode1.width;
picNode1.baseX = picNode1.x;
canvas.addChild(picNode1);
this.pic1 = picNode1;
const labelNode = new cc.Node();
labelNode.color = cc.Color.YELLOW;
const label = labelNode.addComponent(cc.Label);
label.string = this.data.text;
label.fontSize = 60;
label.lineHeight = 60;
label.font = cc.find('Canvas/res/font/BRLNSDB').getComponent('cc.Label').font;
picNode1.addChild(labelNode);
});
this.getSprNodeByUrl(this.data.pic_url_2, (sprNode) => {
const picNode2 = sprNode;
picNode2.scale = maxW / picNode2.width;
canvas.addChild(picNode2);
picNode2.x = canvas.width;
picNode2.baseX = picNode2.x;
this.pic2 = picNode2;
const labelNode = new cc.Node();
const label = labelNode.addComponent(cc.RichText);
const size = 60
label.font = cc.find('Canvas/res/font/BRLNSDB').getComponent(cc.Label).font;
label.string = `<outline color=#751e00 width=4><size=${size}><color=#ffffff>${this.data.text}</color></size></outline>`
label.lineHeight = size;
picNode2.addChild(labelNode);
});
},
initIcon() {
const iconNode = this.getSprNode('icon');
iconNode.zIndex = 5;
iconNode.anchorX = 1;
iconNode.anchorY = 1;
iconNode.parent = cc.find('Canvas');
iconNode.x = iconNode.parent.width / 2 - 10;
iconNode.y = iconNode.parent.height / 2 - 10;
iconNode.on(cc.Node.EventType.TOUCH_START, () => {
this.playAudioByUrl(this.data.audio_url);
})
},
curPage: null,
initBtn() {
this.curPage = 0;
const bottomPart = cc.find('Canvas/bottomPart');
bottomPart.zIndex = 5; // 提高层级
bottomPart.x = bottomPart.parent.width / 2;
bottomPart.y = -bottomPart.parent.height / 2;
const leftBtnNode = bottomPart.getChildByName('btn_left');
//节点中添加了button组件 则可以添加click事件监听
leftBtnNode.on('click', () => {
if (!this._cantouch) {
return;
}
if (this.curPage == 0) {
return;
}
this.curPage = 0
this.leftMove();
// 游戏结束时需要调用这个方法通知系统作业完成
onHomeworkFinish();
cc.audioEngine.play(this.audioBtn.clip, false, 0.8)
})
const rightBtnNode = bottomPart.getChildByName('btn_right');
//节点中添加了button组件 则可以添加click事件监听
rightBtnNode.on('click', () => {
if (!this._cantouch) {
return;
}
if (this.curPage == 1) {
return;
}
this.curPage = 1
this.rightMove();
cc.audioEngine.play(this.audioBtn.clip, false, 0.5)
})
},
leftMove() {
this._cantouch = false;
const len = this.pic1.parent.width;
cc.tween(this.pic1)
.to(1, { x: this.pic1.baseX }, { easing: 'cubicInOut' })
.start();
cc.tween(this.pic2)
.to(1, { x: this.pic2.baseX }, { easing: 'cubicInOut' })
.call(() => {
this._cantouch = true;
})
.start();
},
rightMove() {
this._cantouch = false;
const len = this.pic1.parent.width;
cc.tween(this.pic1)
.to(1, { x: this.pic1.baseX - len }, { easing: 'cubicInOut' })
.start();
cc.tween(this.pic2)
.to(1, { x: this.pic2.baseX - len }, { easing: 'cubicInOut' })
.call(() => {
this._cantouch = true;
})
.start();
},
// update (dt) {},
// ------------------------------------------------
getSprNode(resName) {
const sf = cc.find('Canvas/res/img/' + resName).getComponent(cc.Sprite).spriteFrame;
const node = new cc.Node();
node.addComponent(cc.Sprite).spriteFrame = sf;
return node;
},
getSpriteFrimeByUrl(url, cb) {
cc.loader.load({ url }, (err, img) => {
const spriteFrame = new cc.SpriteFrame(img)
if (cb) {
cb(spriteFrame);
}
})
},
getSprNodeByUrl(url, cb) {
const node = new cc.Node();
const spr = node.addComponent(cc.Sprite);
this.getSpriteFrimeByUrl(url, (sf) => {
spr.spriteFrame = sf;
if (cb) {
cb(node);
}
})
},
playAudioByUrl(audio_url, cb = null) {
if (audio_url) {
cc.assetManager.loadRemote(audio_url, (err, audioClip) => {
const audioId = cc.audioEngine.play(audioClip, false, 0.8);
if (cb) {
cc.audioEngine.setFinishCallback(audioId, () => {
cb();
});
}
});
}
},
// ------------------------------------------
});
{
"ver": "1.0.8",
"uuid": "f4ede462-f8d7-4069-ba80-915611c058ca",
"isPlugin": false,
"loadPluginInWeb": true,
"loadPluginInNative": true,
"loadPluginInEditor": false,
"subMetas": {}
}
\ No newline at end of file
export const defaultData = {
"pic_url": "http://staging-teach.cdn.ireadabc.com/ed94332a503c31e0908bd4c6923a2665.png",
"pic_url_2": "http://staging-teach.cdn.ireadabc.com/5fb60317ade0195d35ad8034d5370a7f.png",
"text": "This is a test label.",
"audio_url": "http://staging-teach.cdn.ireadabc.com/f47f1d7b5c160fe1c59500d180346240.mp3"
}
\ No newline at end of file
/**
* Copyright (c) 2014-present, Facebook, Inc.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
!(function (global) {
"use strict";
var Op = Object.prototype;
var hasOwn = Op.hasOwnProperty;
var undefined; // More compressible than void 0.
var $Symbol = typeof Symbol === "function" ? Symbol : {};
var iteratorSymbol = $Symbol.iterator || "@@iterator";
var asyncIteratorSymbol = $Symbol.asyncIterator || "@@asyncIterator";
var toStringTagSymbol = $Symbol.toStringTag || "@@toStringTag";
var inModule = typeof module === "object";
var runtime = global.regeneratorRuntime;
if (runtime) {
if (inModule) {
// If regeneratorRuntime is defined globally and we're in a module,
// make the exports object identical to regeneratorRuntime.
module.exports = runtime;
}
// Don't bother evaluating the rest of this file if the runtime was
// already defined globally.
return;
}
// Define the runtime globally (as expected by generated code) as either
// module.exports (if we're in a module) or a new, empty object.
runtime = global.regeneratorRuntime = inModule ? module.exports : {};
function wrap(innerFn, outerFn, self, tryLocsList) {
// If outerFn provided and outerFn.prototype is a Generator, then outerFn.prototype instanceof Generator.
var protoGenerator = outerFn && outerFn.prototype instanceof Generator ? outerFn : Generator;
var generator = Object.create(protoGenerator.prototype);
var context = new Context(tryLocsList || []);
// The ._invoke method unifies the implementations of the .next,
// .throw, and .return methods.
generator._invoke = makeInvokeMethod(innerFn, self, context);
return generator;
}
runtime.wrap = wrap;
// Try/catch helper to minimize deoptimizations. Returns a completion
// record like context.tryEntries[i].completion. This interface could
// have been (and was previously) designed to take a closure to be
// invoked without arguments, but in all the cases we care about we
// already have an existing method we want to call, so there's no need
// to create a new function object. We can even get away with assuming
// the method takes exactly one argument, since that happens to be true
// in every case, so we don't have to touch the arguments object. The
// only additional allocation required is the completion record, which
// has a stable shape and so hopefully should be cheap to allocate.
function tryCatch(fn, obj, arg) {
try {
return { type: "normal", arg: fn.call(obj, arg) };
} catch (err) {
return { type: "throw", arg: err };
}
}
var GenStateSuspendedStart = "suspendedStart";
var GenStateSuspendedYield = "suspendedYield";
var GenStateExecuting = "executing";
var GenStateCompleted = "completed";
// Returning this object from the innerFn has the same effect as
// breaking out of the dispatch switch statement.
var ContinueSentinel = {};
// Dummy constructor functions that we use as the .constructor and
// .constructor.prototype properties for functions that return Generator
// objects. For full spec compliance, you may wish to configure your
// minifier not to mangle the names of these two functions.
function Generator() { }
function GeneratorFunction() { }
function GeneratorFunctionPrototype() { }
// This is a polyfill for %IteratorPrototype% for environments that
// don't natively support it.
var IteratorPrototype = {};
IteratorPrototype[iteratorSymbol] = function () {
return this;
};
var getProto = Object.getPrototypeOf;
var NativeIteratorPrototype = getProto && getProto(getProto(values([])));
if (NativeIteratorPrototype &&
NativeIteratorPrototype !== Op &&
hasOwn.call(NativeIteratorPrototype, iteratorSymbol)) {
// This environment has a native %IteratorPrototype%; use it instead
// of the polyfill.
IteratorPrototype = NativeIteratorPrototype;
}
var Gp = GeneratorFunctionPrototype.prototype =
Generator.prototype = Object.create(IteratorPrototype);
GeneratorFunction.prototype = Gp.constructor = GeneratorFunctionPrototype;
GeneratorFunctionPrototype.constructor = GeneratorFunction;
GeneratorFunctionPrototype[toStringTagSymbol] =
GeneratorFunction.displayName = "GeneratorFunction";
// Helper for defining the .next, .throw, and .return methods of the
// Iterator interface in terms of a single ._invoke method.
function defineIteratorMethods(prototype) {
["next", "throw", "return"].forEach(function (method) {
prototype[method] = function (arg) {
return this._invoke(method, arg);
};
});
}
runtime.isGeneratorFunction = function (genFun) {
var ctor = typeof genFun === "function" && genFun.constructor;
return ctor
? ctor === GeneratorFunction ||
// For the native GeneratorFunction constructor, the best we can
// do is to check its .name property.
(ctor.displayName || ctor.name) === "GeneratorFunction"
: false;
};
runtime.mark = function (genFun) {
if (Object.setPrototypeOf) {
Object.setPrototypeOf(genFun, GeneratorFunctionPrototype);
} else {
genFun.__proto__ = GeneratorFunctionPrototype;
if (!(toStringTagSymbol in genFun)) {
genFun[toStringTagSymbol] = "GeneratorFunction";
}
}
genFun.prototype = Object.create(Gp);
return genFun;
};
// Within the body of any async function, `await x` is transformed to
// `yield regeneratorRuntime.awrap(x)`, so that the runtime can test
// `hasOwn.call(value, "__await")` to determine if the yielded value is
// meant to be awaited.
runtime.awrap = function (arg) {
return { __await: arg };
};
function AsyncIterator(generator) {
function invoke(method, arg, resolve, reject) {
var record = tryCatch(generator[method], generator, arg);
if (record.type === "throw") {
reject(record.arg);
} else {
var result = record.arg;
var value = result.value;
if (value &&
typeof value === "object" &&
hasOwn.call(value, "__await")) {
return Promise.resolve(value.__await).then(function (value) {
invoke("next", value, resolve, reject);
}, function (err) {
invoke("throw", err, resolve, reject);
});
}
return Promise.resolve(value).then(function (unwrapped) {
// When a yielded Promise is resolved, its final value becomes
// the .value of the Promise<{value,done}> result for the
// current iteration. If the Promise is rejected, however, the
// result for this iteration will be rejected with the same
// reason. Note that rejections of yielded Promises are not
// thrown back into the generator function, as is the case
// when an awaited Promise is rejected. This difference in
// behavior between yield and await is important, because it
// allows the consumer to decide what to do with the yielded
// rejection (swallow it and continue, manually .throw it back
// into the generator, abandon iteration, whatever). With
// await, by contrast, there is no opportunity to examine the
// rejection reason outside the generator function, so the
// only option is to throw it from the await expression, and
// let the generator function handle the exception.
result.value = unwrapped;
resolve(result);
}, reject);
}
}
var previousPromise;
function enqueue(method, arg) {
function callInvokeWithMethodAndArg() {
return new Promise(function (resolve, reject) {
invoke(method, arg, resolve, reject);
});
}
return previousPromise =
// If enqueue has been called before, then we want to wait until
// all previous Promises have been resolved before calling invoke,
// so that results are always delivered in the correct order. If
// enqueue has not been called before, then it is important to
// call invoke immediately, without waiting on a callback to fire,
// so that the async generator function has the opportunity to do
// any necessary setup in a predictable way. This predictability
// is why the Promise constructor synchronously invokes its
// executor callback, and why async functions synchronously
// execute code before the first await. Since we implement simple
// async functions in terms of async generators, it is especially
// important to get this right, even though it requires care.
previousPromise ? previousPromise.then(
callInvokeWithMethodAndArg,
// Avoid propagating failures to Promises returned by later
// invocations of the iterator.
callInvokeWithMethodAndArg
) : callInvokeWithMethodAndArg();
}
// Define the unified helper method that is used to implement .next,
// .throw, and .return (see defineIteratorMethods).
this._invoke = enqueue;
}
defineIteratorMethods(AsyncIterator.prototype);
AsyncIterator.prototype[asyncIteratorSymbol] = function () {
return this;
};
runtime.AsyncIterator = AsyncIterator;
// Note that simple async functions are implemented on top of
// AsyncIterator objects; they just return a Promise for the value of
// the final result produced by the iterator.
runtime.async = function (innerFn, outerFn, self, tryLocsList) {
var iter = new AsyncIterator(
wrap(innerFn, outerFn, self, tryLocsList)
);
return runtime.isGeneratorFunction(outerFn)
? iter // If outerFn is a generator, return the full iterator.
: iter.next().then(function (result) {
return result.done ? result.value : iter.next();
});
};
function makeInvokeMethod(innerFn, self, context) {
var state = GenStateSuspendedStart;
return function invoke(method, arg) {
if (state === GenStateExecuting) {
throw new Error("Generator is already running");
}
if (state === GenStateCompleted) {
if (method === "throw") {
throw arg;
}
// Be forgiving, per 25.3.3.3.3 of the spec:
// https://people.mozilla.org/~jorendorff/es6-draft.html#sec-generatorresume
return doneResult();
}
context.method = method;
context.arg = arg;
while (true) {
var delegate = context.delegate;
if (delegate) {
var delegateResult = maybeInvokeDelegate(delegate, context);
if (delegateResult) {
if (delegateResult === ContinueSentinel) continue;
return delegateResult;
}
}
if (context.method === "next") {
// Setting context._sent for legacy support of Babel's
// function.sent implementation.
context.sent = context._sent = context.arg;
} else if (context.method === "throw") {
if (state === GenStateSuspendedStart) {
state = GenStateCompleted;
throw context.arg;
}
context.dispatchException(context.arg);
} else if (context.method === "return") {
context.abrupt("return", context.arg);
}
state = GenStateExecuting;
var record = tryCatch(innerFn, self, context);
if (record.type === "normal") {
// If an exception is thrown from innerFn, we leave state ===
// GenStateExecuting and loop back for another invocation.
state = context.done
? GenStateCompleted
: GenStateSuspendedYield;
if (record.arg === ContinueSentinel) {
continue;
}
return {
value: record.arg,
done: context.done
};
} else if (record.type === "throw") {
state = GenStateCompleted;
// Dispatch the exception by looping back around to the
// context.dispatchException(context.arg) call above.
context.method = "throw";
context.arg = record.arg;
}
}
};
}
// Call delegate.iterator[context.method](context.arg) and handle the
// result, either by returning a { value, done } result from the
// delegate iterator, or by modifying context.method and context.arg,
// setting context.delegate to null, and returning the ContinueSentinel.
function maybeInvokeDelegate(delegate, context) {
var method = delegate.iterator[context.method];
if (method === undefined) {
// A .throw or .return when the delegate iterator has no .throw
// method always terminates the yield* loop.
context.delegate = null;
if (context.method === "throw") {
if (delegate.iterator.return) {
// If the delegate iterator has a return method, give it a
// chance to clean up.
context.method = "return";
context.arg = undefined;
maybeInvokeDelegate(delegate, context);
if (context.method === "throw") {
// If maybeInvokeDelegate(context) changed context.method from
// "return" to "throw", let that override the TypeError below.
return ContinueSentinel;
}
}
context.method = "throw";
context.arg = new TypeError(
"The iterator does not provide a 'throw' method");
}
return ContinueSentinel;
}
var record = tryCatch(method, delegate.iterator, context.arg);
if (record.type === "throw") {
context.method = "throw";
context.arg = record.arg;
context.delegate = null;
return ContinueSentinel;
}
var info = record.arg;
if (!info) {
context.method = "throw";
context.arg = new TypeError("iterator result is not an object");
context.delegate = null;
return ContinueSentinel;
}
if (info.done) {
// Assign the result of the finished delegate to the temporary
// variable specified by delegate.resultName (see delegateYield).
context[delegate.resultName] = info.value;
// Resume execution at the desired location (see delegateYield).
context.next = delegate.nextLoc;
// If context.method was "throw" but the delegate handled the
// exception, let the outer generator proceed normally. If
// context.method was "next", forget context.arg since it has been
// "consumed" by the delegate iterator. If context.method was
// "return", allow the original .return call to continue in the
// outer generator.
if (context.method !== "return") {
context.method = "next";
context.arg = undefined;
}
} else {
// Re-yield the result returned by the delegate method.
return info;
}
// The delegate iterator is finished, so forget it and continue with
// the outer generator.
context.delegate = null;
return ContinueSentinel;
}
// Define Generator.prototype.{next,throw,return} in terms of the
// unified ._invoke helper method.
defineIteratorMethods(Gp);
Gp[toStringTagSymbol] = "Generator";
// A Generator should always return itself as the iterator object when the
// @@iterator function is called on it. Some browsers' implementations of the
// iterator prototype chain incorrectly implement this, causing the Generator
// object to not be returned from this call. This ensures that doesn't happen.
// See https://github.com/facebook/regenerator/issues/274 for more details.
Gp[iteratorSymbol] = function () {
return this;
};
Gp.toString = function () {
return "[object Generator]";
};
function pushTryEntry(locs) {
var entry = { tryLoc: locs[0] };
if (1 in locs) {
entry.catchLoc = locs[1];
}
if (2 in locs) {
entry.finallyLoc = locs[2];
entry.afterLoc = locs[3];
}
this.tryEntries.push(entry);
}
function resetTryEntry(entry) {
var record = entry.completion || {};
record.type = "normal";
delete record.arg;
entry.completion = record;
}
function Context(tryLocsList) {
// The root entry object (effectively a try statement without a catch
// or a finally block) gives us a place to store values thrown from
// locations where there is no enclosing try statement.
this.tryEntries = [{ tryLoc: "root" }];
tryLocsList.forEach(pushTryEntry, this);
this.reset(true);
}
runtime.keys = function (object) {
var keys = [];
for (var key in object) {
keys.push(key);
}
keys.reverse();
// Rather than returning an object with a next method, we keep
// things simple and return the next function itself.
return function next() {
while (keys.length) {
var key = keys.pop();
if (key in object) {
next.value = key;
next.done = false;
return next;
}
}
// To avoid creating an additional object, we just hang the .value
// and .done properties off the next function object itself. This
// also ensures that the minifier will not anonymize the function.
next.done = true;
return next;
};
};
function values(iterable) {
if (iterable) {
var iteratorMethod = iterable[iteratorSymbol];
if (iteratorMethod) {
return iteratorMethod.call(iterable);
}
if (typeof iterable.next === "function") {
return iterable;
}
if (!isNaN(iterable.length)) {
var i = -1, next = function next() {
while (++i < iterable.length) {
if (hasOwn.call(iterable, i)) {
next.value = iterable[i];
next.done = false;
return next;
}
}
next.value = undefined;
next.done = true;
return next;
};
return next.next = next;
}
}
// Return an iterator with no values.
return { next: doneResult };
}
runtime.values = values;
function doneResult() {
return { value: undefined, done: true };
}
Context.prototype = {
constructor: Context,
reset: function (skipTempReset) {
this.prev = 0;
this.next = 0;
// Resetting context._sent for legacy support of Babel's
// function.sent implementation.
this.sent = this._sent = undefined;
this.done = false;
this.delegate = null;
this.method = "next";
this.arg = undefined;
this.tryEntries.forEach(resetTryEntry);
if (!skipTempReset) {
for (var name in this) {
// Not sure about the optimal order of these conditions:
if (name.charAt(0) === "t" &&
hasOwn.call(this, name) &&
!isNaN(+name.slice(1))) {
this[name] = undefined;
}
}
}
},
stop: function () {
this.done = true;
var rootEntry = this.tryEntries[0];
var rootRecord = rootEntry.completion;
if (rootRecord.type === "throw") {
throw rootRecord.arg;
}
return this.rval;
},
dispatchException: function (exception) {
if (this.done) {
throw exception;
}
var context = this;
function handle(loc, caught) {
record.type = "throw";
record.arg = exception;
context.next = loc;
if (caught) {
// If the dispatched exception was caught by a catch block,
// then let that catch block handle the exception normally.
context.method = "next";
context.arg = undefined;
}
return !!caught;
}
for (var i = this.tryEntries.length - 1; i >= 0; --i) {
var entry = this.tryEntries[i];
var record = entry.completion;
if (entry.tryLoc === "root") {
// Exception thrown outside of any try block that could handle
// it, so set the completion value of the entire function to
// throw the exception.
return handle("end");
}
if (entry.tryLoc <= this.prev) {
var hasCatch = hasOwn.call(entry, "catchLoc");
var hasFinally = hasOwn.call(entry, "finallyLoc");
if (hasCatch && hasFinally) {
if (this.prev < entry.catchLoc) {
return handle(entry.catchLoc, true);
} else if (this.prev < entry.finallyLoc) {
return handle(entry.finallyLoc);
}
} else if (hasCatch) {
if (this.prev < entry.catchLoc) {
return handle(entry.catchLoc, true);
}
} else if (hasFinally) {
if (this.prev < entry.finallyLoc) {
return handle(entry.finallyLoc);
}
} else {
throw new Error("try statement without catch or finally");
}
}
}
},
abrupt: function (type, arg) {
for (var i = this.tryEntries.length - 1; i >= 0; --i) {
var entry = this.tryEntries[i];
if (entry.tryLoc <= this.prev &&
hasOwn.call(entry, "finallyLoc") &&
this.prev < entry.finallyLoc) {
var finallyEntry = entry;
break;
}
}
if (finallyEntry &&
(type === "break" ||
type === "continue") &&
finallyEntry.tryLoc <= arg &&
arg <= finallyEntry.finallyLoc) {
// Ignore the finally entry if control is not jumping to a
// location outside the try/catch block.
finallyEntry = null;
}
var record = finallyEntry ? finallyEntry.completion : {};
record.type = type;
record.arg = arg;
if (finallyEntry) {
this.method = "next";
this.next = finallyEntry.finallyLoc;
return ContinueSentinel;
}
return this.complete(record);
},
complete: function (record, afterLoc) {
if (record.type === "throw") {
throw record.arg;
}
if (record.type === "break" ||
record.type === "continue") {
this.next = record.arg;
} else if (record.type === "return") {
this.rval = this.arg = record.arg;
this.method = "return";
this.next = "end";
} else if (record.type === "normal" && afterLoc) {
this.next = afterLoc;
}
return ContinueSentinel;
},
finish: function (finallyLoc) {
for (var i = this.tryEntries.length - 1; i >= 0; --i) {
var entry = this.tryEntries[i];
if (entry.finallyLoc === finallyLoc) {
this.complete(entry.completion, entry.afterLoc);
resetTryEntry(entry);
return ContinueSentinel;
}
}
},
"catch": function (tryLoc) {
for (var i = this.tryEntries.length - 1; i >= 0; --i) {
var entry = this.tryEntries[i];
if (entry.tryLoc === tryLoc) {
var record = entry.completion;
if (record.type === "throw") {
var thrown = record.arg;
resetTryEntry(entry);
}
return thrown;
}
}
// The context.catch method must only be called with a location
// argument that corresponds to a known catch block.
throw new Error("illegal catch attempt");
},
delegateYield: function (iterable, resultName, nextLoc) {
this.delegate = {
iterator: values(iterable),
resultName: resultName,
nextLoc: nextLoc
};
if (this.method === "next") {
// Deliberately forget the last sent value so that we don't
// accidentally pass it on to the delegate.
this.arg = undefined;
}
return ContinueSentinel;
}
};
})(
// In sloppy mode, unbound `this` refers to the global object, fallback to
// Function constructor if we're in global strict mode. That is sadly a form
// of indirect eval which violates Content Security Policy.
(function () { return this })() || Function("return this")()
);
{
"ver": "1.1.2",
"uuid": "8ba21262-178f-4fa5-afc9-2c1dd50ba3ab",
"isBundle": false,
"bundleName": "",
"priority": 1,
"compressionType": {},
"optimizeHotUpdate": {},
"inlineSpriteFrames": {},
"isRemoteBundle": {},
"subMetas": {}
}
\ No newline at end of file
{ {
"title": "play", "title": "play",
"packageName": "org.cocos2d.demo", "packageName": "org.cocos2d.demo",
"startScene": "57ea7c61-9b8b-498a-b024-c98ee9124beb", "startScene": "5e0a03aa-9b9e-4076-b508-7dbf209bb115",
"excludeScenes": [], "excludeScenes": [],
"includeSDKBox": false, "includeSDKBox": false,
"orientation": { "orientation": {
...@@ -28,6 +28,7 @@ ...@@ -28,6 +28,7 @@
}, },
"ios": { "ios": {
"REMOTE_SERVER_ROOT": "", "REMOTE_SERVER_ROOT": "",
"ios_enable_jit": true,
"packageName": "org.cocos2d.demo" "packageName": "org.cocos2d.demo"
}, },
"mac": { "mac": {
...@@ -50,5 +51,6 @@ ...@@ -50,5 +51,6 @@
"scheme": "https", "scheme": "https",
"skipRecord": false "skipRecord": false
}, },
"appBundle": false "appBundle": false,
"agreements": {}
} }
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