Finalizacja migracji

This commit is contained in:
2021-06-29 13:13:42 +02:00
parent 26ae065837
commit 19c2199c5e
71 changed files with 28313 additions and 13994 deletions
+46 -46
View File
@@ -1,46 +1,46 @@
import { defineComponent } from 'vue';
export default defineComponent({
methods: {
calculateExpStyle(exp: string | number, isSupporter = false): string {
const bgColor = exp > -1 ? (exp < 2 ? '#26B0D9' : `hsl(${-exp * 5 + 100}, 85%, 50%)`) : '#666';
const fontColor = exp > 15 || exp == -1 ? 'white' : 'black';
const boxShadow = isSupporter ? `box-shadow: 0 0 10px 2px ${bgColor};` : '';
return `background-color: ${bgColor}; color: ${fontColor}; ${boxShadow}`;
},
statusClasses(occupiedTo: string) {
let className = '';
switch (occupiedTo) {
case 'WOLNA':
className = 'free';
break;
case 'KOŃCZY':
className = 'ending';
break;
case 'NIEZALOGOWANY':
className = 'not-signed';
break;
case 'BEZ LIMITU':
className = 'no-limit';
break;
case 'NIEDOSTĘPNY':
className = 'unavailable';
break;
case 'Z/W':
className = 'brb';
break;
case 'BRAK MIEJSCA':
className = 'no-space';
break;
default:
break;
}
return className;
}
}
})
import { defineComponent } from 'vue';
export default defineComponent({
methods: {
calculateExpStyle(exp: string | number, isSupporter = false): string {
const bgColor = exp > -1 ? (exp < 2 ? '#26B0D9' : `hsl(${-exp * 5 + 100}, 85%, 50%)`) : '#666';
const fontColor = exp > 15 || exp == -1 ? 'white' : 'black';
const boxShadow = isSupporter ? `box-shadow: 0 0 10px 2px ${bgColor};` : '';
return `background-color: ${bgColor}; color: ${fontColor}; ${boxShadow}`;
},
statusClasses(occupiedTo: string) {
let className = '';
switch (occupiedTo) {
case 'WOLNA':
className = 'free';
break;
case 'KOŃCZY':
className = 'ending';
break;
case 'NIEZALOGOWANY':
className = 'not-signed';
break;
case 'BEZ LIMITU':
className = 'no-limit';
break;
case 'NIEDOSTĘPNY':
className = 'unavailable';
break;
case 'Z/W':
className = 'brb';
break;
case 'BRAK MIEJSCA':
className = 'no-space';
break;
default:
break;
}
return className;
}
}
})