Skip to content

Commit

Permalink
feature: 样式调整
Browse files Browse the repository at this point in the history
  • Loading branch information
XiaoLin committed Jan 4, 2020
1 parent 76b6b58 commit fa55c5d
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 6 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "vue-fortune-wheel",
"version": "0.2.3",
"version": "0.2.5",
"author": "Xiaolin Zhu",
"license": "MIT",
"bugs": {
Expand Down
7 changes: 4 additions & 3 deletions src/components/fortuneWheel/index.scss
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,11 @@
}

.btn-container {
position: relative;
position: absolute;
cursor: pointer;
width: 40%;
height: 40%;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
}

.fortuneWheel-btn{
Expand Down
4 changes: 2 additions & 2 deletions src/components/fortuneWheel/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@
<slot name="wheel" v-else />
</div>
<div class="fortuneWheel-wrapper">
<div class="btn-container" :style="{ width: btnWidth, height: btnWidth}" @click="onRotateStart">
<div v-if="type === 'canvas'" class="fortuneWheel-btn">{{ btnText }}</div>
<div class="btn-container" @click="onRotateStart">
<div v-if="type === 'canvas'" class="fortuneWheel-btn" :style="{ width: btnWidth, height: btnWidth}">{{ btnText }}</div>
<slot v-else name="button"/>
</div>
</div>
Expand Down

0 comments on commit fa55c5d

Please sign in to comment.