File tree 1 file changed +10
-6
lines changed
1 file changed +10
-6
lines changed Original file line number Diff line number Diff line change 117
117
<v-btn v-if =" history.flat().length > 0" color =" blue" class =" mr-3" @click =" downloadPGN($el)" >
118
118
Download PGN
119
119
</v-btn >
120
- <v-dialog v-else v-model =" uploadDialog" :persistent = " true " width =" 1024" >
120
+ <v-dialog v-else v-model =" uploadDialog" width =" 1024" >
121
121
<template #activator =" { props } " >
122
122
<v-btn color =" lime" class =" mr-3" v-bind =" props" >
123
123
Upload PGN
124
124
</v-btn >
125
125
</template >
126
- <v-card >
126
+ <v-card height = " 576 " >
127
127
<v-card-title >
128
128
<span class =" text-h5" >Upload PGN</span >
129
129
</v-card-title >
130
130
<v-card-text >
131
131
<v-container >
132
132
<!-- big ol text box -->
133
- <v-textarea v-model =" pgn" label =" PGN" />
133
+ <v-textarea v-model =" pgn" rows = " 12 " label =" PGN" />
134
134
<!-- tiny file upload box -->
135
- <v-file-input v-model =" pgnFile" label =" PGN File" />
135
+ <v-file-input v-model =" pgnFile" label =" PGN File" prepend-icon = " mdi-upload " />
136
136
</v-container >
137
137
</v-card-text >
138
138
<v-card-actions >
139
139
<v-spacer />
140
+ <v-btn text =" Cancel" @click =" uploadDialog = false" />
140
141
<v-btn color =" blue-darken-1" variant =" text" @click =" uploadPGN" >
141
142
Save
142
143
</v-btn >
143
144
</v-card-actions >
144
145
</v-card >
145
146
</v-dialog >
146
- <v-btn v-if =" useSupabaseUser() && saveToProfileStatus === 'pending'" color =" blue" @click.prevent =" saveToProfile" >
147
+ <v-btn v-if =" useSupabaseUser() && saveToProfileStatus === 'pending'" color =" blue" :disabled =" history.flat().length == 0"
148
+ @click.prevent =" saveToProfile" >
147
149
Save to Profile
148
150
</v-btn >
149
151
<v-btn v-else-if =" saveToProfileStatus === 'sending'" color =" grey" :disabled =" true" >
@@ -350,11 +352,13 @@ export default defineComponent({
350
352
}
351
353
},
352
354
353
- handleReset() {
355
+ handleReset(isActive : Ref < boolean > ) {
354
356
this .boardAPI ?.resetBoard ()
355
357
this .status = ' Pending'
356
358
this .saveToProfileStatus = ' pending'
357
359
this .history = [[]]
360
+ this .whiteOnBottom = true
361
+ isActive .value = false
358
362
},
359
363
360
364
/**
You can’t perform that action at this time.
0 commit comments