Commit 2499dbb9 authored by 董政锦's avatar 董政锦

style: game4 h5端样式修改;

parent cb2dbddf
......@@ -4,6 +4,7 @@ declare module 'crypto-js';
declare module 'crypto-js/sha256';
declare const __APP_DOMAIN__: string;
declare const __DEBUG__: boolean;
interface ImportMetaEnv {
readonly VITE_ASSET_BASE_URL?: string;
......
......@@ -15,12 +15,14 @@
"crypto-js": "^4.2.0",
"msgpack": "^1.0.3",
"socket.io-client": "^4.8.3",
"vconsole": "^3.15.1",
"vue": "^3.5.32",
"vue-router": "^4.6.4"
},
"devDependencies": {
"@tsconfig/node24": "^24.0.4",
"@types/node": "^24.12.2",
"@vitejs/plugin-basic-ssl": "^2.3.0",
"@vitejs/plugin-vue": "^6.0.6",
"@vue/tsconfig": "^0.9.1",
"npm-run-all2": "^8.0.4",
......
......@@ -20,6 +20,9 @@ importers:
socket.io-client:
specifier: ^4.8.3
version: 4.8.3
vconsole:
specifier: ^3.15.1
version: 3.15.1
vue:
specifier: ^3.5.32
version: 3.5.35(typescript@6.0.3)
......@@ -33,6 +36,9 @@ importers:
'@types/node':
specifier: ^24.12.2
version: 24.12.4
'@vitejs/plugin-basic-ssl':
specifier: ^2.3.0
version: 2.3.0(vite@8.0.16(@types/node@24.12.4))
'@vitejs/plugin-vue':
specifier: ^6.0.6
version: 6.0.7(vite@8.0.16(@types/node@24.12.4))(vue@3.5.35(typescript@6.0.3))
......@@ -185,6 +191,10 @@ packages:
peerDependencies:
'@babel/core': ^7.0.0-0
'@babel/runtime@7.29.7':
resolution: {integrity: sha512-Nq8OhGWiZIZGV6hLHoyAKLLcJihP/xFeBMGJoUrxTX2psI8dCifzLhZISFb+VWS3wFMRDmCGw5R+dOySCqPLhw==}
engines: {node: '>=6.9.0'}
'@babel/template@7.29.7':
resolution: {integrity: sha512-puq+Gf35oI24FeN11LkoUQFqv9uwNeWpxXZi/Ji3rRIoKAzKnxRaZ+Gkj0vKS9ZCiTESfng1N9LyOyXvo+m+Gg==}
engines: {node: '>=6.9.0'}
......@@ -348,6 +358,12 @@ packages:
'@types/node@24.12.4':
resolution: {integrity: sha512-GUUEShf+PBCGW2KaXwcIt3Yk+e3pkKwWKb9GSyM9WQVE+ep2jzmHdGsHzu4wgcZy5fN9FBdVzjpBQsYlpfpgLA==}
'@vitejs/plugin-basic-ssl@2.3.0':
resolution: {integrity: sha512-bdyo8rB3NnQbikdMpHaML9Z1OZPBu6fFOBo+OtxsBlvMJtysWskmBcnbIDhUqgC8tcxNv/a+BcV5U+2nQMm1OQ==}
engines: {node: ^18.0.0 || ^20.0.0 || >=22.0.0}
peerDependencies:
vite: ^6.0.0 || ^7.0.0 || ^8.0.0
'@vitejs/plugin-vue@6.0.7':
resolution: {integrity: sha512-km+p+XdSz9Sxm5rqUbqcSfZYaAniKxWBj1KURl+Jr7UaPvvX7BmaWMdP69I5rrFDeQGyxAG7NXdc57vz+snhWg==}
engines: {node: ^20.19.0 || >=22.12.0}
......@@ -474,6 +490,13 @@ packages:
convert-source-map@2.0.0:
resolution: {integrity: sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==}
copy-text-to-clipboard@3.2.2:
resolution: {integrity: sha512-T6SqyLd1iLuqPA90J5N4cTalrtovCySh58iiZDGJ6FGznbclKh4UI+FGacQSgFzwKG77W7XT5gwbVEbd9cIH1A==}
engines: {node: '>=12'}
core-js@3.49.0:
resolution: {integrity: sha512-es1U2+YTtzpwkxVLwAFdSpaIMyQaq0PBgm3YD1W3Qpsn1NAmO3KSgZfu+oGSWVu6NvLHoHCV/aYcsE5wiB7ALg==}
cross-spawn@7.0.6:
resolution: {integrity: sha512-uV2QOWP2nWzsy2aMp8aRibhi9dlzF5Hgh5SHaB9OiTGEyDTiJJyx0uy51QXdyWbtAHNua4XJzUKca3OzKUd3vA==}
engines: {node: '>= 8'}
......@@ -698,6 +721,9 @@ packages:
muggle-string@0.4.1:
resolution: {integrity: sha512-VNTrAak/KhO2i8dqqnqnAHOa3cYBwXEZe9h+D5h/1ZqFSTEFHdM65lR7RoIqq3tBBYavsOXV84NoHXZ0AkPyqQ==}
mutation-observer@1.0.3:
resolution: {integrity: sha512-M/O/4rF2h776hV7qGMZUH3utZLO/jK7p8rnNgGkjKUw8zCGjRQPxB8z6+5l8+VjRUQ3dNYu4vjqXYLr+U8ZVNA==}
nan@2.27.0:
resolution: {integrity: sha512-hC+0LidcL3XE4rp1C4H54KujgXKzbfyTngZTwBByQxsOxCEKZT0MPQ4hOKUH2jU1OYstqdDH4onyHPDzcV0XdQ==}
......@@ -836,6 +862,9 @@ packages:
peerDependencies:
browserslist: '>= 4.21.0'
vconsole@3.15.1:
resolution: {integrity: sha512-KH8XLdrq9T5YHJO/ixrjivHfmF2PC2CdVoK6RWZB4yftMykYIaXY1mxZYAic70vADM54kpMQF+dYmvl5NRNy1g==}
vite-dev-rpc@2.0.0:
resolution: {integrity: sha512-yKwbTwdHKSD2k/aGqyWpPHepo45OQc8lH3/6IfT4ZqeKE26ooKvi4WIEKzqWav8v+9Is8u1k8q54hvOmqASazA==}
peerDependencies:
......@@ -1135,6 +1164,8 @@ snapshots:
transitivePeerDependencies:
- supports-color
'@babel/runtime@7.29.7': {}
'@babel/template@7.29.7':
dependencies:
'@babel/code-frame': 7.29.7
......@@ -1270,6 +1301,10 @@ snapshots:
dependencies:
undici-types: 7.16.0
'@vitejs/plugin-basic-ssl@2.3.0(vite@8.0.16(@types/node@24.12.4))':
dependencies:
vite: 8.0.16(@types/node@24.12.4)
'@vitejs/plugin-vue@6.0.7(vite@8.0.16(@types/node@24.12.4))(vue@3.5.35(typescript@6.0.3))':
dependencies:
'@rolldown/pluginutils': 1.0.1
......@@ -1431,6 +1466,10 @@ snapshots:
convert-source-map@2.0.0: {}
copy-text-to-clipboard@3.2.2: {}
core-js@3.49.0: {}
cross-spawn@7.0.6:
dependencies:
path-key: 3.1.1
......@@ -1586,6 +1625,8 @@ snapshots:
muggle-string@0.4.1: {}
mutation-observer@1.0.3: {}
nan@2.27.0: {}
nanoid@3.3.12: {}
......@@ -1729,6 +1770,13 @@ snapshots:
escalade: 3.2.0
picocolors: 1.1.1
vconsole@3.15.1:
dependencies:
'@babel/runtime': 7.29.7
copy-text-to-clipboard: 3.2.2
core-js: 3.49.0
mutation-observer: 1.0.3
vite-dev-rpc@2.0.0(vite@8.0.16(@types/node@24.12.4)):
dependencies:
birpc: 4.0.0
......
This source diff could not be displayed because it is too large. You can view the blob instead.
This source diff could not be displayed because it is too large. You can view the blob instead.
<svg width="500" height="90" viewBox="0 0 500 90" fill="none" xmlns="http://www.w3.org/2000/svg">
<rect width="500" height="90" rx="16" fill="#E61903"/>
<path d="M65.232 32.856L67.716 29.796C68.316 30.084 68.976 30.432 69.696 30.84C70.416 31.248 71.112 31.656 71.784 32.064C72.456 32.448 73.008 32.796 73.44 33.108L70.848 36.564C70.464 36.228 69.936 35.844 69.264 35.412C68.616 34.956 67.932 34.512 67.212 34.08C66.516 33.624 65.856 33.216 65.232 32.856ZM64.008 42.504L66.456 39.372C67.056 39.66 67.716 39.996 68.436 40.38C69.156 40.74 69.852 41.112 70.524 41.496C71.22 41.856 71.784 42.192 72.216 42.504L69.66 45.96C69.252 45.648 68.712 45.288 68.04 44.88C67.392 44.448 66.708 44.028 65.988 43.62C65.268 43.212 64.608 42.84 64.008 42.504ZM64.368 60.684C64.824 59.7 65.304 58.572 65.808 57.3C66.312 56.004 66.816 54.636 67.32 53.196C67.848 51.756 68.328 50.328 68.76 48.912L72.252 51.072C71.892 52.368 71.484 53.7 71.028 55.068C70.596 56.412 70.152 57.744 69.696 59.064C69.24 60.36 68.772 61.608 68.292 62.808L64.368 60.684ZM87.228 33.684H97.884V37.752H87.228V33.684ZM86.652 40.452H95.544V44.196H86.652V40.452ZM85.14 49.056H97.992V52.908H85.14V49.056ZM87.048 29.472L91.188 30.156C90.78 32.532 90.204 34.824 89.46 37.032C88.716 39.24 87.852 41.088 86.868 42.576C86.604 42.36 86.244 42.12 85.788 41.856C85.332 41.568 84.876 41.304 84.42 41.064C83.964 40.8 83.568 40.596 83.232 40.452C84.216 39.156 85.02 37.524 85.644 35.556C86.268 33.588 86.736 31.56 87.048 29.472ZM89.784 45.924H93.78V58.848C93.78 59.808 93.672 60.576 93.456 61.152C93.24 61.728 92.808 62.184 92.16 62.52C91.512 62.832 90.732 63.024 89.82 63.096C88.932 63.168 87.888 63.204 86.688 63.204C86.64 62.628 86.496 61.968 86.256 61.224C86.04 60.48 85.812 59.82 85.572 59.244C86.316 59.268 87.036 59.292 87.732 59.316C88.428 59.316 88.896 59.316 89.136 59.316C89.4 59.316 89.568 59.28 89.64 59.208C89.736 59.136 89.784 58.992 89.784 58.776V45.924ZM93.852 40.452H94.788L95.544 40.236L98.1 42.072C97.284 43.2 96.324 44.352 95.22 45.528C94.14 46.704 93.084 47.688 92.052 48.48C91.788 48.072 91.428 47.616 90.972 47.112C90.516 46.608 90.12 46.212 89.784 45.924C90.288 45.492 90.804 45 91.332 44.448C91.86 43.896 92.352 43.332 92.808 42.756C93.264 42.156 93.612 41.616 93.852 41.136V40.452ZM72.288 34.62H85.068V38.688H72.288V34.62ZM76.356 42.684H82.44V46.572H76.356V42.684ZM80.856 42.684H84.78C84.78 42.684 84.768 42.792 84.744 43.008C84.744 43.2 84.744 43.44 84.744 43.728C84.744 43.992 84.732 44.196 84.708 44.34C84.636 47.172 84.54 49.584 84.42 51.576C84.324 53.568 84.204 55.224 84.06 56.544C83.94 57.864 83.784 58.896 83.592 59.64C83.424 60.384 83.22 60.924 82.98 61.26C82.644 61.74 82.284 62.076 81.9 62.268C81.54 62.484 81.12 62.64 80.64 62.736C80.232 62.832 79.716 62.88 79.092 62.88C78.492 62.904 77.832 62.904 77.112 62.88C77.064 62.304 76.956 61.644 76.788 60.9C76.62 60.18 76.38 59.544 76.068 58.992C76.596 59.064 77.076 59.112 77.508 59.136C77.964 59.136 78.312 59.136 78.552 59.136C78.768 59.136 78.948 59.1 79.092 59.028C79.26 58.956 79.428 58.812 79.596 58.596C79.788 58.308 79.956 57.66 80.1 56.652C80.268 55.62 80.412 54.048 80.532 51.936C80.676 49.8 80.784 46.968 80.856 43.44V42.684ZM74.952 37.608H78.912C78.864 40.056 78.756 42.48 78.588 44.88C78.444 47.256 78.18 49.56 77.796 51.792C77.412 54 76.824 56.076 76.032 58.02C75.264 59.94 74.232 61.656 72.936 63.168C72.624 62.688 72.192 62.172 71.64 61.62C71.088 61.068 70.56 60.648 70.056 60.36C71.184 59.04 72.072 57.528 72.72 55.824C73.368 54.12 73.836 52.272 74.124 50.28C74.436 48.264 74.64 46.188 74.736 44.052C74.856 41.916 74.928 39.768 74.952 37.608ZM75.312 30.624L79.272 29.112C79.776 29.784 80.28 30.528 80.784 31.344C81.288 32.16 81.684 32.868 81.972 33.468L77.832 35.268C77.592 34.644 77.22 33.888 76.716 33C76.236 32.112 75.768 31.32 75.312 30.624ZM100.548 33.288H111.456V37.068H100.548V33.288ZM110.448 33.288H111.204L111.924 33.108L114.696 34.044C114.216 38.052 113.436 41.748 112.356 45.132C111.3 48.492 109.98 51.492 108.396 54.132C106.812 56.748 104.964 58.968 102.852 60.792C102.636 60.432 102.336 60.036 101.952 59.604C101.592 59.148 101.22 58.716 100.836 58.308C100.452 57.876 100.08 57.528 99.72 57.264C101.112 56.208 102.396 54.876 103.572 53.268C104.772 51.636 105.828 49.8 106.74 47.76C107.676 45.72 108.456 43.56 109.08 41.28C109.704 38.976 110.16 36.624 110.448 34.224V33.288ZM100.404 41.1L103.356 38.58C104.388 39.876 105.468 41.256 106.596 42.72C107.748 44.184 108.876 45.66 109.98 47.148C111.084 48.612 112.104 50.028 113.04 51.396C114 52.74 114.768 53.964 115.344 55.068L112.032 58.128C111.456 57.024 110.724 55.764 109.836 54.348C108.948 52.932 107.964 51.456 106.884 49.92C105.828 48.384 104.736 46.86 103.608 45.348C102.504 43.836 101.436 42.42 100.404 41.1ZM114.372 39.444L132.948 37.284L133.452 41.136L114.876 43.404L114.372 39.444ZM124.2 31.812L127.296 29.544C127.824 30.024 128.388 30.564 128.988 31.164C129.588 31.764 130.164 32.352 130.716 32.928C131.268 33.504 131.712 34.02 132.048 34.476L128.772 37.068C128.484 36.588 128.064 36.048 127.512 35.448C126.984 34.824 126.432 34.2 125.856 33.576C125.28 32.928 124.728 32.34 124.2 31.812ZM117.864 29.652H122.364C122.412 32.772 122.508 35.712 122.652 38.472C122.82 41.232 123.06 43.764 123.372 46.068C123.708 48.348 124.116 50.34 124.596 52.044C125.1 53.748 125.688 55.104 126.36 56.112C127.056 57.096 127.848 57.66 128.736 57.804C129.144 57.852 129.456 57.432 129.672 56.544C129.912 55.632 130.092 54.228 130.212 52.332C130.476 52.644 130.836 52.968 131.292 53.304C131.772 53.64 132.24 53.952 132.696 54.24C133.176 54.528 133.56 54.744 133.848 54.888C133.536 57.168 133.116 58.92 132.588 60.144C132.084 61.368 131.508 62.184 130.86 62.592C130.236 63.024 129.588 63.216 128.916 63.168C127.188 63 125.712 62.364 124.488 61.26C123.264 60.156 122.244 58.644 121.428 56.724C120.612 54.78 119.964 52.476 119.484 49.812C119.004 47.124 118.632 44.088 118.368 40.704C118.128 37.32 117.96 33.636 117.864 29.652ZM128.844 42.324L132.3 44.412C131.58 46.188 130.68 47.94 129.6 49.668C128.52 51.372 127.308 53.004 125.964 54.564C124.644 56.1 123.228 57.504 121.716 58.776C120.204 60.048 118.632 61.116 117 61.98C116.592 61.452 116.076 60.888 115.452 60.288C114.828 59.688 114.216 59.172 113.616 58.74C115.296 58.02 116.904 57.084 118.44 55.932C119.976 54.756 121.404 53.436 122.724 51.972C124.068 50.508 125.256 48.96 126.288 47.328C127.32 45.696 128.172 44.028 128.844 42.324ZM139.752 38.148H150.696V41.964H139.752V38.148ZM139.644 31.236H153.54V49.128H139.644V45.276H149.184V35.088H139.644V31.236ZM138.276 62.448L137.844 58.596L139.536 57.156L149.796 54.204C149.94 54.78 150.144 55.428 150.408 56.148C150.672 56.844 150.9 57.42 151.092 57.876C148.572 58.692 146.52 59.352 144.936 59.856C143.376 60.36 142.152 60.768 141.264 61.08C140.4 61.392 139.752 61.644 139.32 61.836C138.912 62.052 138.564 62.256 138.276 62.448ZM145.8 51.828L149.544 50.028C150.144 50.988 150.768 52.044 151.416 53.196C152.064 54.324 152.664 55.44 153.216 56.544C153.768 57.624 154.2 58.596 154.512 59.46L150.516 61.584C150.228 60.72 149.82 59.736 149.292 58.632C148.788 57.504 148.224 56.352 147.6 55.176C147 53.976 146.4 52.86 145.8 51.828ZM138.276 62.448C138.204 62.04 138.072 61.548 137.88 60.972C137.712 60.42 137.508 59.88 137.268 59.352C137.052 58.824 136.824 58.38 136.584 58.02C136.992 57.828 137.376 57.54 137.736 57.156C138.096 56.772 138.276 56.232 138.276 55.536V31.236H142.704V59.136C142.704 59.136 142.548 59.196 142.236 59.316C141.948 59.436 141.588 59.604 141.156 59.82C140.724 60.036 140.28 60.288 139.824 60.576C139.392 60.864 139.02 61.164 138.708 61.476C138.42 61.788 138.276 62.112 138.276 62.448ZM164.232 31.488H168.48V52.296C168.48 53.256 168.372 54.048 168.156 54.672C167.964 55.272 167.568 55.752 166.968 56.112C166.368 56.448 165.648 56.652 164.808 56.724C163.968 56.796 162.96 56.832 161.784 56.832C161.712 56.256 161.568 55.572 161.352 54.78C161.136 53.988 160.884 53.316 160.596 52.764C161.244 52.788 161.856 52.812 162.432 52.836C163.032 52.836 163.44 52.824 163.656 52.8C163.872 52.776 164.016 52.728 164.088 52.656C164.184 52.584 164.232 52.44 164.232 52.224V31.488ZM155.556 31.488H166.284V35.448H159.876V63.24H155.556V31.488ZM183.672 46.896H205.56V50.856H183.672V46.896ZM197.388 43.404H201.636V58.632C201.636 59.664 201.504 60.48 201.24 61.08C201 61.68 200.508 62.136 199.764 62.448C199.044 62.76 198.156 62.952 197.1 63.024C196.068 63.096 194.844 63.132 193.428 63.132C193.356 62.556 193.188 61.884 192.924 61.116C192.684 60.348 192.42 59.676 192.132 59.1C193.044 59.124 193.944 59.148 194.832 59.172C195.72 59.172 196.32 59.172 196.632 59.172C196.92 59.172 197.112 59.124 197.208 59.028C197.328 58.932 197.388 58.776 197.388 58.56V43.404ZM185.616 52.62L189.144 50.784C189.696 51.384 190.26 52.056 190.836 52.8C191.412 53.52 191.94 54.24 192.42 54.96C192.924 55.68 193.308 56.328 193.572 56.904L189.792 58.992C189.576 58.416 189.24 57.756 188.784 57.012C188.328 56.244 187.824 55.476 187.272 54.708C186.72 53.94 186.168 53.244 185.616 52.62ZM178.344 29.4H182.52V63.204H178.344V29.4ZM172.044 51.504C172.956 50.88 174.048 50.088 175.32 49.128C176.616 48.144 177.924 47.124 179.244 46.068L180.828 49.56C179.748 50.52 178.632 51.504 177.48 52.512C176.352 53.496 175.248 54.42 174.168 55.284L172.044 51.504ZM171.972 36.708L174.96 34.332C175.488 34.884 176.052 35.496 176.652 36.168C177.252 36.816 177.816 37.464 178.344 38.112C178.872 38.76 179.28 39.348 179.568 39.876L176.436 42.504C176.172 41.976 175.788 41.376 175.284 40.704C174.78 40.032 174.24 39.348 173.664 38.652C173.088 37.932 172.524 37.284 171.972 36.708ZM192.384 32.244H202.536L201.78 35.628H190.26L192.384 32.244ZM192.708 29.4L197.172 30.552C196.26 31.728 195.204 32.868 194.004 33.972C192.804 35.076 191.532 36.096 190.188 37.032C188.844 37.944 187.488 38.724 186.12 39.372C185.928 39.108 185.652 38.796 185.292 38.436C184.956 38.076 184.608 37.728 184.248 37.392C183.888 37.032 183.564 36.744 183.276 36.528C184.572 36.024 185.82 35.388 187.02 34.62C188.244 33.852 189.336 33.024 190.296 32.136C191.28 31.224 192.084 30.312 192.708 29.4ZM188.676 38.688L191.844 36.852C192.468 37.356 193.092 37.932 193.716 38.58C194.364 39.228 194.844 39.828 195.156 40.38L191.808 42.324C191.544 41.82 191.112 41.22 190.512 40.524C189.912 39.828 189.3 39.216 188.676 38.688ZM201.06 32.244H201.888L202.644 32.064L205.488 33.504C204.6 35.424 203.472 37.128 202.104 38.616C200.736 40.08 199.188 41.352 197.46 42.432C195.756 43.512 193.896 44.436 191.88 45.204C189.888 45.948 187.824 46.56 185.688 47.04C185.472 46.512 185.16 45.924 184.752 45.276C184.344 44.604 183.948 44.064 183.564 43.656C185.484 43.32 187.344 42.84 189.144 42.216C190.968 41.592 192.66 40.836 194.22 39.948C195.78 39.036 197.148 37.992 198.324 36.816C199.5 35.64 200.412 34.332 201.06 32.892V32.244ZM209.844 31.488H240.408V35.592H209.844V31.488ZM208.656 44.412H241.452V48.552H208.656V44.412ZM229.5 33.864H234.036V63.276H229.5V33.864ZM216.792 33.9H221.256V43.368C221.256 45.096 221.16 46.872 220.968 48.696C220.776 50.496 220.368 52.272 219.744 54.024C219.144 55.776 218.22 57.456 216.972 59.064C215.748 60.648 214.104 62.088 212.04 63.384C211.776 63.048 211.44 62.676 211.032 62.268C210.624 61.86 210.192 61.464 209.736 61.08C209.304 60.696 208.908 60.384 208.548 60.144C210.396 59.04 211.872 57.816 212.976 56.472C214.08 55.104 214.908 53.7 215.46 52.26C216.012 50.796 216.372 49.308 216.54 47.796C216.708 46.284 216.792 44.796 216.792 43.332V33.9ZM261.9 57.948H273.816V61.764H261.9V57.948ZM259.164 48.084H275.976V63.168H271.872V51.9H263.052V63.204H259.164V48.084ZM269.028 36.204L272.448 34.512C273.288 35.544 274.092 36.672 274.86 37.896C275.652 39.096 276.36 40.296 276.984 41.496C277.608 42.696 278.088 43.776 278.424 44.736L274.716 46.716C274.428 45.732 273.984 44.628 273.384 43.404C272.784 42.18 272.1 40.944 271.332 39.696C270.588 38.424 269.82 37.26 269.028 36.204ZM258.552 46.068C258.48 45.804 258.36 45.432 258.192 44.952C258.048 44.448 257.88 43.932 257.688 43.404C257.496 42.852 257.316 42.408 257.148 42.072C257.556 41.952 257.94 41.7 258.3 41.316C258.66 40.932 259.044 40.428 259.452 39.804C259.692 39.492 260.004 38.988 260.388 38.292C260.772 37.596 261.204 36.78 261.684 35.844C262.164 34.884 262.632 33.852 263.088 32.748C263.568 31.644 264 30.54 264.384 29.436L268.884 30.624C268.212 32.232 267.456 33.84 266.616 35.448C265.8 37.032 264.948 38.532 264.06 39.948C263.172 41.364 262.296 42.636 261.432 43.764V43.872C261.432 43.872 261.288 43.944 261 44.088C260.712 44.232 260.376 44.424 259.992 44.664C259.608 44.904 259.272 45.156 258.984 45.42C258.696 45.66 258.552 45.876 258.552 46.068ZM258.552 46.068L258.444 42.684L260.748 41.28L275.22 40.308C275.316 40.908 275.448 41.58 275.616 42.324C275.808 43.044 275.976 43.632 276.12 44.088C273.288 44.328 270.9 44.532 268.956 44.7C267.036 44.868 265.452 45.024 264.204 45.168C262.98 45.288 262.008 45.396 261.288 45.492C260.568 45.588 260.004 45.684 259.596 45.78C259.188 45.876 258.84 45.972 258.552 46.068ZM244.692 49.092C245.052 47.844 245.412 46.44 245.772 44.88C246.156 43.296 246.504 41.628 246.816 39.876C247.128 38.124 247.404 36.384 247.644 34.656C247.908 32.904 248.1 31.224 248.22 29.616L252.288 29.868C252.12 31.572 251.88 33.336 251.568 35.16C251.28 36.984 250.956 38.808 250.596 40.632C250.236 42.456 249.864 44.208 249.48 45.888C249.096 47.544 248.712 49.056 248.328 50.424L244.692 49.092ZM244.332 36.564H254.196V40.524H244.332V36.564ZM253.188 36.564H253.908L254.628 36.492L257.112 36.816C256.872 41.496 256.356 45.54 255.564 48.948C254.772 52.332 253.632 55.188 252.144 57.516C250.68 59.82 248.82 61.704 246.564 63.168C246.3 62.664 245.916 62.064 245.412 61.368C244.932 60.696 244.476 60.156 244.044 59.748C245.964 58.692 247.56 57.132 248.832 55.068C250.128 53.004 251.136 50.484 251.856 47.508C252.576 44.532 253.02 41.136 253.188 37.32V36.564ZM244.692 49.092L246.996 46.032C247.932 46.776 248.916 47.58 249.948 48.444C250.98 49.308 251.988 50.196 252.972 51.108C253.956 51.996 254.856 52.884 255.672 53.772C256.512 54.636 257.196 55.44 257.724 56.184L255.132 59.712C254.628 58.944 253.98 58.104 253.188 57.192C252.396 56.28 251.52 55.344 250.56 54.384C249.6 53.424 248.616 52.5 247.608 51.612C246.6 50.7 245.628 49.86 244.692 49.092ZM288.632 32.604H306.956V36.276H288.632V32.604ZM292.988 39.948H302.744V43.476H292.988V39.948ZM291.764 37.608L295.868 38.544C295.364 40.488 294.692 42.36 293.852 44.16C293.012 45.96 292.076 47.472 291.044 48.696C290.804 48.456 290.48 48.168 290.072 47.832C289.688 47.496 289.28 47.16 288.848 46.824C288.44 46.488 288.08 46.224 287.768 46.032C288.68 45.024 289.472 43.764 290.144 42.252C290.84 40.74 291.38 39.192 291.764 37.608ZM292.844 29.4H296.588V38.22H292.844V29.4ZM299.504 29.4H303.32V38.832H299.504V29.4ZM290.576 45.492H293.816V58.056H290.576V45.492ZM292.52 45.492H299.648V56.22H292.52V52.944H296.372V48.768H292.52V45.492ZM301.736 39.948H305.768C305.768 39.948 305.768 40.068 305.768 40.308C305.768 40.524 305.756 40.776 305.732 41.064C305.732 41.328 305.732 41.556 305.732 41.748C305.636 45.036 305.528 47.844 305.408 50.172C305.288 52.476 305.156 54.384 305.012 55.896C304.892 57.384 304.724 58.56 304.508 59.424C304.316 60.264 304.088 60.876 303.824 61.26C303.44 61.788 303.032 62.172 302.6 62.412C302.192 62.652 301.712 62.82 301.16 62.916C300.656 63.012 300.032 63.06 299.288 63.06C298.568 63.084 297.812 63.084 297.02 63.06C296.996 62.46 296.876 61.8 296.66 61.08C296.444 60.36 296.192 59.736 295.904 59.208C296.576 59.28 297.188 59.328 297.74 59.352C298.316 59.352 298.76 59.352 299.072 59.352C299.336 59.352 299.552 59.316 299.72 59.244C299.912 59.148 300.092 58.98 300.26 58.74C300.452 58.5 300.62 58.008 300.764 57.264C300.908 56.52 301.028 55.464 301.124 54.096C301.244 52.704 301.352 50.916 301.448 48.732C301.544 46.548 301.64 43.896 301.736 40.776V39.948ZM308.648 36.06H321.896V40.056H308.648V36.06ZM309.26 29.508L313.652 30.12C313.1 33.624 312.296 36.9 311.24 39.948C310.184 42.972 308.792 45.48 307.064 47.472C306.848 47.184 306.536 46.848 306.128 46.464C305.744 46.08 305.324 45.696 304.868 45.312C304.436 44.904 304.052 44.592 303.716 44.376C305.276 42.696 306.488 40.548 307.352 37.932C308.24 35.316 308.876 32.508 309.26 29.508ZM315.632 38.508L320.06 38.94C319.532 42.996 318.728 46.584 317.648 49.704C316.592 52.824 315.104 55.512 313.184 57.768C311.288 60.024 308.852 61.908 305.876 63.42C305.756 63.084 305.54 62.664 305.228 62.16C304.94 61.656 304.628 61.152 304.292 60.648C303.956 60.168 303.656 59.784 303.392 59.496C306.056 58.296 308.216 56.736 309.872 54.816C311.552 52.896 312.836 50.58 313.724 47.868C314.636 45.156 315.272 42.036 315.632 38.508ZM310.88 39.948C311.384 42.876 312.116 45.624 313.076 48.192C314.036 50.736 315.284 52.98 316.82 54.924C318.356 56.868 320.264 58.38 322.544 59.46C322.208 59.748 321.848 60.108 321.464 60.54C321.08 60.972 320.72 61.416 320.384 61.872C320.048 62.352 319.772 62.796 319.556 63.204C317.084 61.836 315.032 60.06 313.4 57.876C311.768 55.668 310.448 53.112 309.44 50.208C308.432 47.28 307.604 44.076 306.956 40.596L310.88 39.948ZM326.072 32.568L328.844 29.94C329.468 30.468 330.152 31.056 330.896 31.704C331.64 32.352 332.348 33 333.02 33.648C333.692 34.296 334.232 34.872 334.64 35.376L331.688 38.4C331.304 37.848 330.788 37.236 330.14 36.564C329.516 35.892 328.844 35.208 328.124 34.512C327.404 33.792 326.72 33.144 326.072 32.568ZM329.06 62.88L328.088 58.884L328.988 57.552L336.044 52.188C336.188 52.764 336.392 53.412 336.656 54.132C336.944 54.852 337.196 55.428 337.412 55.86C335.78 57.156 334.448 58.212 333.416 59.028C332.384 59.844 331.58 60.492 331.004 60.972C330.428 61.452 329.996 61.836 329.708 62.124C329.444 62.412 329.228 62.664 329.06 62.88ZM324.38 40.524H331.472V44.664H324.38V40.524ZM329.06 62.88C328.964 62.544 328.784 62.136 328.52 61.656C328.28 61.2 328.016 60.744 327.728 60.288C327.464 59.856 327.212 59.508 326.972 59.244C327.356 58.956 327.752 58.524 328.16 57.948C328.568 57.348 328.772 56.628 328.772 55.788V40.524H332.912V58.74C332.912 58.74 332.72 58.884 332.336 59.172C331.952 59.436 331.496 59.784 330.968 60.216C330.464 60.648 330.02 61.104 329.636 61.584C329.252 62.064 329.06 62.496 329.06 62.88ZM341.336 50.28H352.424V53.052H341.336V50.28ZM336.692 31.884H356.888V34.944H336.692V31.884ZM337.7 36.42H355.808V39.3H337.7V36.42ZM335.612 40.812H358.004V43.908H335.612V40.812ZM341.228 55.104H352.352V57.948H341.228V55.104ZM338.06 45.312H352.352V48.48H342.056V63.24H338.06V45.312ZM351.452 45.312H355.52V59.1C355.52 60.036 355.4 60.78 355.16 61.332C354.944 61.884 354.512 62.304 353.864 62.592C353.216 62.88 352.436 63.06 351.524 63.132C350.612 63.204 349.532 63.228 348.284 63.204C348.212 62.676 348.056 62.052 347.816 61.332C347.6 60.636 347.372 60.036 347.132 59.532C347.852 59.58 348.584 59.604 349.328 59.604C350.072 59.604 350.564 59.604 350.804 59.604C351.236 59.604 351.452 59.412 351.452 59.028V45.312ZM344.576 29.4H348.86V41.856H344.576V29.4ZM381.296 31.02H390.584V34.944H381.296V31.02ZM381.296 39.156H390.584V42.972H381.296V39.156ZM381.26 47.4H390.62V51.252H381.26V47.4ZM388.748 31.02H392.888V58.452C392.888 59.508 392.768 60.336 392.528 60.936C392.288 61.56 391.856 62.052 391.232 62.412C390.608 62.748 389.816 62.964 388.856 63.06C387.92 63.156 386.78 63.192 385.436 63.168C385.364 62.592 385.208 61.896 384.968 61.08C384.728 60.288 384.476 59.616 384.212 59.064C384.98 59.112 385.736 59.136 386.48 59.136C387.248 59.136 387.764 59.136 388.028 59.136C388.292 59.136 388.472 59.088 388.568 58.992C388.688 58.872 388.748 58.68 388.748 58.416V31.02ZM379.496 31.02H383.564V44.268C383.564 45.684 383.516 47.232 383.42 48.912C383.348 50.592 383.18 52.296 382.916 54.024C382.676 55.728 382.328 57.384 381.872 58.992C381.416 60.6 380.792 62.04 380 63.312C379.784 63.048 379.46 62.748 379.028 62.412C378.596 62.1 378.164 61.8 377.732 61.512C377.3 61.224 376.916 61.008 376.58 60.864C377.492 59.304 378.152 57.564 378.56 55.644C378.968 53.724 379.22 51.78 379.316 49.812C379.436 47.82 379.496 45.972 379.496 44.268V31.02ZM360.668 33.648H378.308V37.428H360.668V33.648ZM365.348 39.552H373.952V42.828H365.348V39.552ZM365.348 45.132H373.952V48.444H365.348V45.132ZM360.236 50.856H378.056V54.636H360.236V50.856ZM363.476 29.832H367.364V52.224H363.476V29.832ZM371.864 29.832H375.824V52.224H371.864V29.832ZM364.7 54.888L368.804 56.076C368.132 57.396 367.304 58.704 366.32 60C365.336 61.32 364.364 62.424 363.404 63.312C363.164 63.048 362.828 62.76 362.396 62.448C361.988 62.136 361.556 61.824 361.1 61.512C360.668 61.2 360.284 60.948 359.948 60.756C360.908 60.036 361.808 59.148 362.648 58.092C363.512 57.036 364.196 55.968 364.7 54.888ZM370.064 56.508L373.34 54.708C373.82 55.212 374.312 55.788 374.816 56.436C375.344 57.06 375.836 57.684 376.292 58.308C376.772 58.908 377.156 59.46 377.444 59.964L373.952 61.98C373.712 61.5 373.364 60.936 372.908 60.288C372.476 59.664 372.008 59.016 371.504 58.344C371 57.672 370.52 57.06 370.064 56.508ZM408.98 33.504H428.456V37.428H408.98V33.504ZM407.288 47.364H429.824V51.252H407.288V47.364ZM406.928 40.56H430.148V44.484H406.928V40.56ZM416.36 29.58H420.644V42.612H416.36V29.58ZM421.292 43.836H425.612V58.704C425.612 59.76 425.48 60.576 425.216 61.152C424.952 61.752 424.46 62.22 423.74 62.556C423.02 62.868 422.144 63.06 421.112 63.132C420.104 63.204 418.916 63.24 417.548 63.24C417.476 62.64 417.308 61.944 417.044 61.152C416.804 60.384 416.54 59.724 416.252 59.172C416.828 59.196 417.416 59.22 418.016 59.244C418.616 59.244 419.144 59.244 419.6 59.244C420.056 59.22 420.368 59.208 420.536 59.208C420.824 59.208 421.016 59.172 421.112 59.1C421.232 59.004 421.292 58.836 421.292 58.596V43.836ZM409.304 53.34L412.868 51.468C413.396 52.068 413.936 52.74 414.488 53.484C415.04 54.228 415.544 54.96 416 55.68C416.48 56.376 416.84 57.024 417.08 57.624L413.3 59.712C413.084 59.136 412.76 58.476 412.328 57.732C411.896 56.988 411.416 56.232 410.888 55.464C410.36 54.696 409.832 53.988 409.304 53.34ZM404.516 37.356L408.26 38.94C407.396 40.428 406.388 41.916 405.236 43.404C404.084 44.892 402.872 46.308 401.6 47.652C400.328 48.972 399.08 50.124 397.856 51.108C397.76 50.772 397.592 50.328 397.352 49.776C397.112 49.2 396.848 48.624 396.56 48.048C396.272 47.472 396.032 47.016 395.84 46.68C396.896 45.912 397.952 45.036 399.008 44.052C400.088 43.044 401.108 41.976 402.068 40.848C403.028 39.696 403.844 38.532 404.516 37.356ZM403.616 29.472L407.648 31.128C406.88 32.232 405.98 33.348 404.948 34.476C403.916 35.58 402.824 36.624 401.672 37.608C400.544 38.592 399.416 39.456 398.288 40.2C398.144 39.864 397.94 39.468 397.676 39.012C397.436 38.556 397.184 38.1 396.92 37.644C396.656 37.188 396.416 36.816 396.2 36.528C397.136 35.952 398.072 35.268 399.008 34.476C399.968 33.684 400.856 32.856 401.672 31.992C402.488 31.104 403.136 30.264 403.616 29.472ZM401.132 45.42L405.056 41.424L405.272 41.496V63.204H401.132V45.42Z" fill="white"/>
</svg>
<svg width="447" height="288" viewBox="0 0 447 288" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M0 9.99999C0 4.47715 4.47715 0 10 0H437C442.523 0 447 4.47715 447 10V287.5L224 234.5L0 287.5V9.99999Z" fill="url(#paint0_linear_99_884)"/>
<defs>
<linearGradient id="paint0_linear_99_884" x1="223.5" y1="0" x2="223.5" y2="287.5" gradientUnits="userSpaceOnUse">
<stop stop-color="#FFE897"/>
<stop offset="1" stop-color="white"/>
</linearGradient>
</defs>
</svg>
import SHA256 from 'crypto-js/sha256'
/**
* 是否开启 vconsole 调试面板
* - 开发模式(__DEBUG__=true)下自动开启
* - 生产模式下可通过 URL 参数 ?vc 或 ?debug 手动开启
*
* 关闭方式:将 vite.config.ts 中 __DEBUG__ 改为 false,且访问时不带 ?vc 参数
*/
function shouldEnableVConsole(): boolean {
if (__DEBUG__) return true
const params = new URLSearchParams(location.search)
return params.has('vc') || params.has('debug')
}
/**
* 是否使用模拟微信数据
* - 开发模式下如果 URL 没有真实 token 参数,自动启用模拟数据
* - 生产模式下可通过 URL 参数 ?mock 手动启用
*/
export function shouldMockWechat(): boolean {
const params = new URLSearchParams(location.search)
if (params.get('token')) return false // 有真实 token 就不 mock
if (__DEBUG__) return true
return params.has('mock')
}
/** 模拟的微信用户数据 */
export function getMockWechat() {
const mockToken = 'debug_mock_token_' + Date.now()
return {
token: SHA256(mockToken).toString(),
token_origin: mockToken,
nickname: '测试用户',
avatar: 'https://picsum.photos/200',
}
}
/**
* 初始化 vconsole(动态导入,生产环境未触发时不会打包)
*/
export async function initVConsole() {
if (!shouldEnableVConsole()) return
try {
const { default: VConsole } = await import('vconsole')
const vc = new VConsole()
console.log('[debug] vconsole 已启动')
return vc
} catch (e) {
console.warn('[debug] vconsole 加载失败:', e)
}
}
......@@ -89,5 +89,17 @@ export function $getWechat(): any | null {
avatar: q[2],
};
}
// 调试模式:无真实微信参数时使用模拟数据
if (__DEBUG__) {
const mockToken = 'debug_mock_token_' + Date.now()
return {
token: SHA256(mockToken).toString(),
token_origin: mockToken,
nickname: '测试用户',
avatar: 'https://picsum.photos/200',
}
}
return null;
}
\ No newline at end of file
......@@ -186,7 +186,7 @@ defineExpose({
display: flex;
align-items: center;
justify-content: center;
background-color: rgba(0, 0, 0, 0.2);
background-color: rgba(0, 0, 0, 0.6);
/* pointer-events: none; */
}
......
......@@ -3,7 +3,9 @@ import './assets/main.css'
import { createApp } from 'vue'
import App from './App.vue'
import router from './router'
import { initVConsole } from './commons/debug'
localStorage.setItem('domain', __APP_DOMAIN__)
initVConsole()
createApp(App).use(router).mount('#app')
<script setup lang="ts">
import { onBeforeUnmount, onMounted, ref } from 'vue'
import { computed, onBeforeUnmount, onMounted, ref } from 'vue'
import { cssAssetUrl } from '@/commons/assets.ts'
import MobileStage from '@/components/MobileStage.vue'
import { useGameSocket, joinSharedRoom, sendGameMessage, userJoinStatus } from '@/composables/useGameSocket'
......@@ -14,11 +14,13 @@ const imageUrls = {
bg: cssAssetUrl('game4/h5-game4-bg.svg'),
bg2: cssAssetUrl('game1/bg2.png'),
playBg: cssAssetUrl('game4/h5-game4-bg2.svg'),
logo: cssAssetUrl('game1/logo.png'),
logo: cssAssetUrl('game4/logo.svg'),
time: cssAssetUrl('game4/h5-game4-clock.svg'),
title: cssAssetUrl('game4/h5-game4-title1.svg'),
title2: cssAssetUrl('game4/h5-game4-title2.svg'),
avatarBg: cssAssetUrl('game4/h5-game4-join.svg'),
// avatarBg: cssAssetUrl('game4/h5-game4-join.svg'),
userBg: cssAssetUrl('game4/user-bg.svg'),
startBg: cssAssetUrl('game4/start-bg.svg'),
gift: cssAssetUrl('game4/h5-game4-gift.svg'),
avatar: cssAssetUrl('game1/avatar.png'),
gu: cssAssetUrl('game4/h5-game4-horse.svg'),
......@@ -33,6 +35,13 @@ const imageUrls = {
const wechat = $getWechat()
const currentView = ref<GameView>('loading')
const stageBackground = computed(() => {
if (currentView.value === 'playing') {
return `${imageUrls.playBg} center/cover`
}
return `${imageUrls.bg} center/cover`
})
const countdownInterval = ref(60)
const isDivDescVisible = ref(false)
const tick = ref(0) // 点击次数/摇动次数
......@@ -216,7 +225,7 @@ onBeforeUnmount(() => {
<template>
<MobileStage v-if="token" :showGameRule="showGameRule" ref="mobileStageRef"
:background="`${imageUrls.bg} center/cover`">
:background="stageBackground">
<template #gameRule>
<div class="rule-container">
<div class="rule-txt-container">
......@@ -250,9 +259,10 @@ onBeforeUnmount(() => {
<style scoped>
.rule-container {
.rule-txt-container {
background: #FFF9E4;
width: 62vw;
margin: 0 40px;
border-radius: 5px;
background: #FFF9E4;
padding-top: 20px;
padding-bottom: 10px;
......
<script setup lang="ts">
import { $getWechat } from '@/commons/utils.ts'
import { onMounted, ref } from 'vue';
defineProps<{
imageUrls: Record<string, string>
userJoinStatus: boolean
......@@ -7,6 +10,14 @@ defineProps<{
defineEmits<{
touchGameRule: []
}>()
const nickname = ref('');
const avatar = ref('');
onMounted(() => {
const wechat = $getWechat();
nickname.value = wechat.nickname;
avatar.value = wechat.avatar;
});
</script>
<template>
......@@ -16,8 +27,14 @@ defineEmits<{
<div class="img-title"></div>
<div class="img-title2"></div>
<div class="img-gift"></div>
<div class="img-avatar-bg"></div>
<div class="img-avatar"></div>
<div class="img-user-bg"></div>
<div class="img-avatar" :style="`background: url(${avatar});border-radius:66px;width:132px;height:132px;`"></div>
<div class="txt-nickname">{{ nickname }}</div>
<div class="txt-loading">
<label v-if="userJoinStatus">您已成功加入游戏等待主持人开始</label>
<label v-else>正在加入游戏...</label>
</div>
<div class="img-start-bg"></div>
</div>
</template>
......@@ -99,28 +116,24 @@ defineEmits<{
background: v-bind('imageUrls.gift') center/cover;
}
.img-avatar-bg {
.img-user-bg {
position: absolute;
top: 568px;
left: calc(50% + 12px);
width: 500px;
height: 821px;
background: v-bind('imageUrls.avatarBg') center/cover;
top: 634px;
left: 50%;
width: 447px;
height: 287.5px;
background: v-bind('imageUrls.userBg') center/cover no-repeat;
transform: translateX(-50%);
}
.img-avatar {
position: absolute;
top: 564px;
top: 524px;
left: 50%;
width: 156px;
height: 156px;
background: v-bind('imageUrls.avatar') center/cover;
transform: translateX(-50%);
}
.txt-nickname {
position: absolute;
top: 650px;
top: 668px;
left: 50%;
color: #E00000;
font-size: 25pt;
......@@ -130,7 +143,7 @@ defineEmits<{
.txt-loading {
position: absolute;
top: 710px;
top: 743px;
left: 50%;
width: 288px;
color: #E00000;
......@@ -140,6 +153,16 @@ defineEmits<{
transform: translateX(-50%);
}
.img-start-bg {
position: absolute;
bottom: 291px;
left: 50%;
width: 500px;
height: 90px;
background: v-bind('imageUrls.startBg') center/cover no-repeat;
transform: translateX(-50%);
}
.txt-loading label {
display: inline-block;
transform-origin: center;
......
......@@ -2,7 +2,7 @@
import { onBeforeUnmount, onMounted } from 'vue'
import shakeSound from '@/assets/images/game4/yaoyiyao.mp3'
defineProps<{
const props = defineProps<{
imageUrls: Record<string, string>
countdownInterval: number
isDivDescVisible: boolean
......@@ -83,6 +83,13 @@ const handleDeviceMotion = (ev: DeviceMotionEvent) => {
lastShakeTime = now
playShakeSound()
// 摇晃时打印日志:输出将要通过 websocket 提交的数据
console.log('[摇一摇] 检测到摇晃,即将提交数据:', {
type: 'submit_score',
data: { score: props.tick + 1 },
})
emit('touch')
}
......
......@@ -20,16 +20,16 @@ defineEmits<{
<div class="score-content">
<div>张小明</div>
<div>您的成绩</div>
<div>策马跑道</div>
<div></div>
<div>{{ tick }}</div>
<div>最终排名</div>
<div><label>{{ level }}</label></div>
</div>
</div>
<div class="btn-group">
<!-- <div class="btn-group">
<div class="btn-replay" @click="$emit('replay')"></div>
<div class="btn-back" @click="$emit('back')"></div>
</div>
</div> -->
</div>
</template>
......
import { fileURLToPath, URL } from 'node:url'
import { cpSync, existsSync, rmSync } from 'node:fs'
import { resolve } from 'node:path'
import basicSsl from '@vitejs/plugin-basic-ssl'
import { defineConfig } from 'vite'
import vue from '@vitejs/plugin-vue'
import vueDevTools from 'vite-plugin-vue-devtools'
......@@ -29,10 +29,12 @@ export default defineConfig(({ command }) => ({
base: command === 'build' ? '/cc/h5/' : '/',
define: {
__APP_DOMAIN__: JSON.stringify(command === 'build' ? buildDomain : ''),
__DEBUG__: JSON.stringify(command === 'serve'),
},
plugins: [
vue(),
vueDevTools(),
basicSsl(),
copyImageAssets(),
],
server: {
......
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