mirror of
https://github.com/Spythere/pojazdownik.git
synced 2026-05-03 11:45:34 +00:00
Poprawki w importach
This commit is contained in:
+1
-37
@@ -1,46 +1,10 @@
|
||||
import { createApp, Directive } from 'vue';
|
||||
import { createApp } from 'vue';
|
||||
import { createPinia } from 'pinia';
|
||||
import App from './App.vue';
|
||||
|
||||
import {
|
||||
Store,
|
||||
isLocomotive,
|
||||
locoDataList,
|
||||
carDataList,
|
||||
totalLength,
|
||||
totalMass,
|
||||
maxAllowedSpeed,
|
||||
maxStockSpeed,
|
||||
isTrainPassenger,
|
||||
warnings,
|
||||
} from './store';
|
||||
|
||||
const clickOutsideDirective: Directive = {
|
||||
beforeMount(el, binding) {
|
||||
el.clickOutsideEvent = (event: Event) => {
|
||||
if (!(el == event.target || el.contains(event.target))) {
|
||||
binding.value();
|
||||
}
|
||||
};
|
||||
|
||||
document.addEventListener('click', el.clickOutsideEvent);
|
||||
},
|
||||
};
|
||||
|
||||
const pinia = createPinia();
|
||||
|
||||
createApp(App)
|
||||
.use(pinia)
|
||||
// .provide('Store', Store)
|
||||
// .provide('isLocomotive', isLocomotive)
|
||||
// .provide('locoDataList', locoDataList)
|
||||
// .provide('carDataList', carDataList)
|
||||
// .provide('totalMass', totalMass)
|
||||
// .provide('totalLength', totalLength)
|
||||
// .provide('maxStockSpeed', maxStockSpeed)
|
||||
// .provide('maxAllowedSpeed', maxAllowedSpeed)
|
||||
// .provide('isTrainPassenger', isTrainPassenger)
|
||||
// .provide('warnings', warnings)
|
||||
// .directive('click-outside', clickOutsideDirective)
|
||||
.mount('#app');
|
||||
|
||||
|
||||
Reference in New Issue
Block a user