资源优化
This commit is contained in:
@@ -14,12 +14,17 @@ const props = defineProps({
|
||||
type: Array,
|
||||
default: () => [],
|
||||
},
|
||||
onChange: {
|
||||
type: Function,
|
||||
default: (index) => {},
|
||||
},
|
||||
});
|
||||
|
||||
const currentIndex = ref(0);
|
||||
|
||||
const handleChange = (e) => {
|
||||
currentIndex.value = e.detail.current;
|
||||
props.onChange(e.detail.current);
|
||||
};
|
||||
</script>
|
||||
|
||||
@@ -81,10 +86,10 @@ const handleChange = (e) => {
|
||||
width: 8px;
|
||||
height: 8px;
|
||||
border-radius: 50%;
|
||||
background-color: rgba(255, 255, 255, 0.5);
|
||||
background-color: #ccc;
|
||||
}
|
||||
|
||||
.dot.active {
|
||||
background-color: #fff;
|
||||
background-color: #000;
|
||||
}
|
||||
</style>
|
||||
|
||||
@@ -77,7 +77,10 @@ const onCreateRoom = async () => {
|
||||
<view class="create-room">
|
||||
<image src="../static/battle-bg.png" mode="widthFix" />
|
||||
<view>
|
||||
<image src="../static/avatar.png" mode="widthFix" />
|
||||
<image
|
||||
src="https://api.shelingxingqiu.com/attachment/2025-07-12/db9x4i9g536xerkv9i.png"
|
||||
mode="widthFix"
|
||||
/>
|
||||
<image src="../static/versus.png" mode="widthFix" />
|
||||
<view>
|
||||
<image src="../static/question-mark.png" mode="widthFix" />
|
||||
|
||||
@@ -34,7 +34,7 @@ const toPractiseTwo = () => {
|
||||
/>
|
||||
<view class="practise-btn" @click="toPractiseOne">
|
||||
<image
|
||||
src="../static/practise1.png"
|
||||
src="https://api.shelingxingqiu.com/attachment/2025-07-12/db9x668e2vdtqh0otq.png"
|
||||
class="practise1"
|
||||
mode="widthFix"
|
||||
/>
|
||||
@@ -46,7 +46,7 @@ const toPractiseTwo = () => {
|
||||
/>
|
||||
<view class="practise-btn" @click="toPractiseTwo">
|
||||
<image
|
||||
src="../static/practise2.png"
|
||||
src="https://api.shelingxingqiu.com/attachment/2025-07-12/db9x668eehkvyicc08.png"
|
||||
class="practise2"
|
||||
mode="widthFix"
|
||||
/>
|
||||
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 5.2 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 50 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 50 KiB |
Reference in New Issue
Block a user