Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: fix some gui issues #880

Merged
merged 7 commits into from
Jun 11, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion src/App.vue
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@
<v-app dark :style="cssVars">
<the-sidebar></the-sidebar>
<the-topbar></the-topbar>

<v-main id="content" :style="mainStyle">
<overlay-scrollbars class="main-content-scrollbar">
<v-container id="page-container" fluid class="container px-3 px-sm-6 py-sm-6 mx-auto">
Expand Down
2 changes: 1 addition & 1 deletion src/assets/styles/page.scss
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
html {
overflow: auto;
overflow: hidden;
}

body {
Expand Down
7 changes: 4 additions & 3 deletions src/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import vuetify from '@/plugins/vuetify'
import i18n from '@/plugins/i18n'
import store from '@/store'
import router from '@/plugins/router'

import { WebSocketPlugin } from '@/plugins/webSocketClient'
import { registerSW } from 'virtual:pwa-register'

// noinspection JSUnusedGlobalSymbols
Expand All @@ -33,7 +33,6 @@ Vue.component('VueLoadImage', VueLoadImage)
//vue-toast-notifications
import VueToast from 'vue-toast-notification'
import 'vue-toast-notification/dist/theme-sugar.css'
import { WebSocketPlugin } from '@/plugins/webSocketClient'

Vue.use(VueToast, {
duration: 3000,
Expand All @@ -43,11 +42,13 @@ Vue.use(VueToast, {
import { OverlayScrollbarsPlugin } from 'overlayscrollbars-vue'
import 'overlayscrollbars/css/OverlayScrollbars.css'

const isSafari = navigator.userAgent.includes('Safari') && navigator.userAgent.search('Chrome') === -1
const isTouch = 'ontouchstart' in window || (navigator.maxTouchPoints > 0 && navigator.maxTouchPoints !== 256)
Vue.use(OverlayScrollbarsPlugin, {
className: 'os-theme-light',
scrollbars: {
visibility: 'auto',
autoHide: 'move',
autoHide: isSafari && isTouch ? 'scroll' : 'move',
},
})

Expand Down
4 changes: 2 additions & 2 deletions src/pages/Machine.vue
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,10 @@
<system-panel></system-panel>
<update-panel></update-panel>
<v-row>
<v-col v-if="klipperState === 'ready'" class="col-md-6 pb-0 pb-md-3">
<v-col v-if="klipperState === 'ready'" class="col-12 col-sm-6 pb-0 pb-md-3">
<endstop-panel></endstop-panel>
</v-col>
<v-col :class="klipperState !== 'ready' ? 'col-md-12' : 'col-md-6 pl-0 pl-md-3'">
<v-col :class="klipperState !== 'ready' ? 'col-12' : 'col-12 col-sm-6 pt-0 pt-sm-3'">
<logfiles-panel></logfiles-panel>
</v-col>
</v-row>
Expand Down