Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
655d2fd339 | ||
|
|
0735ed37a9 | ||
|
|
d96070f336 | ||
|
|
d259abb749 | ||
|
|
3e06c5fd66 | ||
|
|
288e5110f4 | ||
|
|
41ca5244cc | ||
|
|
3d4b5451ae | ||
|
|
dc17ff1158 | ||
|
|
de23cb6243 | ||
|
|
94d7f0dc16 | ||
|
|
45c52e3571 | ||
|
|
03640e239b | ||
|
|
4c24fa7284 | ||
|
|
12483ee63b | ||
|
|
bae712540e | ||
|
|
31664b5f38 | ||
|
|
ba5aea2b88 | ||
|
|
a6e38df012 | ||
|
|
bc0018dadc | ||
|
|
1a659d30d2 | ||
|
|
d0bf0bde11 | ||
|
|
d87fe4173d |
No files matched your search
@@ -0,0 +1,145 @@
|
||||
name: Release
|
||||
|
||||
on:
|
||||
workflow_dispatch:
|
||||
inputs:
|
||||
version:
|
||||
type: string
|
||||
description: New version number in X.Y.Z
|
||||
required: true
|
||||
|
||||
jobs:
|
||||
push-version-number:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Clone develop repository
|
||||
uses: actions/checkout@v3
|
||||
with:
|
||||
token: ${{ secrets.PAT }}
|
||||
ref: 'develop'
|
||||
|
||||
- name: get-npm-version
|
||||
id: package-version
|
||||
uses: martinbeentjes/npm-get-version-action@main
|
||||
|
||||
- name: Push version number
|
||||
if: steps.package-version.outputs.current-version != github.event.inputs.version
|
||||
shell: bash
|
||||
run: |
|
||||
npm version --no-git-tag-version ${{ github.event.inputs.version }}
|
||||
|
||||
- name: git add & commit & push
|
||||
if: steps.package-version.outputs.current-version != github.event.inputs.version
|
||||
uses: EndBug/add-and-commit@v9
|
||||
with:
|
||||
add: 'package.json package-lock.json'
|
||||
default_author: github_actions
|
||||
message: 'chore: push version number to v${{ github.event.inputs.version }}'
|
||||
push: true
|
||||
|
||||
update-master-branch:
|
||||
needs: ['push-version-number']
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: everlytic/branch-merge@1.1.5
|
||||
with:
|
||||
github_token: ${{ secrets.PAT }}
|
||||
source_ref: 'develop'
|
||||
target_branch: 'master'
|
||||
commit_message_template: '[Automated] Merged {source_ref} into target {target_branch}'
|
||||
|
||||
release:
|
||||
needs: ['update-master-branch']
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Fetch repo
|
||||
uses: actions/checkout@v3
|
||||
with:
|
||||
ref: 'master'
|
||||
fetch-depth: 0
|
||||
|
||||
- name: Install node
|
||||
uses: actions/setup-node@v3
|
||||
with:
|
||||
node-version: 18
|
||||
|
||||
- name: Install dependencies
|
||||
run: npm ci
|
||||
|
||||
- name: Build
|
||||
run: npm run build
|
||||
|
||||
- name: Move build out of dist
|
||||
shell: bash
|
||||
run: mv ./dist/mainsail.zip ./mainsail.zip
|
||||
|
||||
- name: Get latest tag
|
||||
id: latest_tag
|
||||
shell: bash
|
||||
run: |
|
||||
echo "TAG_NAME=$(git describe --tags $(git rev-list --tags --max-count=1))" >> $GITHUB_OUTPUT
|
||||
|
||||
- name: Generate a changelog
|
||||
uses: orhun/git-cliff-action@v1
|
||||
id: generate-changelog
|
||||
with:
|
||||
config: ./cliff-release.toml
|
||||
args: ${{ steps.latest_tag.outputs.TAG_NAME }}..HEAD
|
||||
|
||||
- name: Create release and upload build
|
||||
uses: softprops/action-gh-release@v1
|
||||
id: create-release
|
||||
with:
|
||||
name: v${{ github.event.inputs.version }}
|
||||
tag_name: v${{ github.event.inputs.version }}
|
||||
token: ${{ secrets.GITHUB_TOKEN }}
|
||||
files: ./mainsail.zip
|
||||
body: ${{ steps.generate-changelog.outputs.content }}
|
||||
|
||||
- name: Copy remote configs to dist
|
||||
shell: bash
|
||||
run: cp ./remote/* ./dist/
|
||||
|
||||
- name: Upload to remote server
|
||||
uses: SamKirkland/FTP-Deploy-Action@4.3.3
|
||||
with:
|
||||
server: ${{ secrets.REMOTEHOST }}
|
||||
username: ${{ secrets.REMOTEUSER }}
|
||||
password: ${{ secrets.REMOTEPASSWORD }}
|
||||
dangerous-clean-slate: true
|
||||
local-dir: ./dist/
|
||||
|
||||
update-changelog:
|
||||
needs: ['release']
|
||||
name: Generate changelog
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v3
|
||||
with:
|
||||
ref: 'develop'
|
||||
token: ${{ secrets.PAT }}
|
||||
fetch-depth: 0
|
||||
|
||||
- name: Get latest tag
|
||||
id: latest_tag
|
||||
shell: bash
|
||||
run: |
|
||||
echo "TAG_NAME=$(git describe --tags $(git rev-list --tags --max-count=1))" >> $GITHUB_OUTPUT
|
||||
|
||||
- name: Generate a changelog
|
||||
uses: orhun/git-cliff-action@v1
|
||||
id: git-cliff
|
||||
with:
|
||||
config: cliff.toml
|
||||
args: v0.0.4..${{ steps.latest_tag.outputs.TAG_NAME }}
|
||||
env:
|
||||
OUTPUT: ${{ github.workspace }}/CHANGELOG.md
|
||||
|
||||
- name: Show CHANGELOG
|
||||
run: |
|
||||
cat CHANGELOG.md
|
||||
- uses: stefanzweifel/git-auto-commit-action@v4
|
||||
with:
|
||||
commit_message: 'docs(changelog): update changelog'
|
||||
file_pattern: CHANGELOG.md
|
||||
@@ -1,42 +0,0 @@
|
||||
name: Update changelog
|
||||
|
||||
on:
|
||||
# Update the changelog after pushing a new tag
|
||||
push:
|
||||
tags:
|
||||
- '*'
|
||||
|
||||
# Update the changelog by invoking this workflow manually
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
changelog:
|
||||
name: Generate changelog
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v3
|
||||
with:
|
||||
fetch-depth: 0
|
||||
- name: Get latest tag
|
||||
run: |
|
||||
echo "::set-output name=TAG_NAME::$(git describe --tags $(git rev-list --tags --max-count=1))"
|
||||
id: latest_tag
|
||||
- name: Generate a changelog
|
||||
uses: orhun/git-cliff-action@v1
|
||||
id: git-cliff
|
||||
with:
|
||||
config: cliff.toml
|
||||
args: v0.0.4..${{ steps.latest_tag.outputs.TAG_NAME }}
|
||||
env:
|
||||
OUTPUT: CHANGELOG.md
|
||||
|
||||
- name: show CHANGELOG
|
||||
run: |
|
||||
cat CHANGELOG.md
|
||||
|
||||
- uses: stefanzweifel/git-auto-commit-action@v4
|
||||
with:
|
||||
commit_message: 'chore(changelog): update changelog'
|
||||
file_pattern: CHANGELOG.md
|
||||
branch: develop
|
||||
@@ -84,6 +84,14 @@ Do you need help or just want to talk? Join our active community on [Discord](ht
|
||||
Did you find a bug or did you thought of a feature?
|
||||
Please create an [Issue](https://github.com/mainsail-crew/mainsail/issues) in GitHub and let us know.
|
||||
|
||||
## Official Sponsors
|
||||
|
||||
<p align='center'>
|
||||
<img src="https://raw.githubusercontent.com/mainsail-crew/docs/master/assets/img/logo-bigtreetech.png" alt='Mainsail logo' width="150">
|
||||
</p>
|
||||
|
||||
**BIGTREETECH** is the official mainboard partner of Mainsail. BIGTREETECH is committed to developing innovative and competitive products to better serve the 3D printing community.
|
||||
|
||||
## Support Mainsail
|
||||
|
||||
Mainsail is primarily developed and maintained by meteyou. To keep the project going he invests his free time, almost
|
||||
|
||||
@@ -0,0 +1,68 @@
|
||||
# configuration file for git-cliff (0.1.0)
|
||||
|
||||
[changelog]
|
||||
# changelog header
|
||||
header = """
|
||||
# What's Changed
|
||||
"""
|
||||
# template for the changelog body
|
||||
# https://tera.netlify.app/docs/#introduction
|
||||
body = """
|
||||
{% for group, commits in commits | group_by(attribute="group") %}\
|
||||
### {{ group | split(pat="$") | last | upper_first }}
|
||||
{% for commit in commits
|
||||
| filter(attribute="scope")
|
||||
| sort(attribute="scope") %}
|
||||
- **{{commit.scope}}**: {{ commit.message | upper_first | trim }} | [{{ commit.id | truncate(length=7, end="") }}]({{ commit.id }})\
|
||||
{%- if commit.breaking %}
|
||||
{% raw %} {% endraw %}- **BREAKING**: {{commit.breaking_description}}
|
||||
{%- endif -%}
|
||||
|
||||
{%- endfor -%}
|
||||
{%- for commit in commits %}
|
||||
{%- if commit.scope -%}
|
||||
{% else -%}
|
||||
{% raw %}\n{% endraw %}\
|
||||
- {{ commit.message | upper_first | trim }} | [{{ commit.id | truncate(length=7, end="") }}]({{ commit.id }})\
|
||||
{%- if commit.breaking %}
|
||||
{% raw %} {% endraw %}- **BREAKING**: {{commit.breaking_description}}
|
||||
{%- endif -%}
|
||||
|
||||
{% endif -%}
|
||||
{% endfor -%}
|
||||
{% raw %}\n{% endraw %}
|
||||
{% endfor %}\n\
|
||||
"""
|
||||
# remove the leading and trailing whitespaces from the template
|
||||
trim = true
|
||||
# changelog footer
|
||||
footer = """
|
||||
"""
|
||||
|
||||
[git]
|
||||
# allow only conventional commits
|
||||
# https://www.conventionalcommits.org
|
||||
conventional_commits = true
|
||||
filter_unconventional = true
|
||||
# regex for parsing and grouping commits
|
||||
commit_parsers = [
|
||||
{ message = "^docs\\(changelog\\):", group = "Changelog", skip = true}, # Old redundant commits
|
||||
{ message = "^chore\\(changelog\\): update changelog", group = "Changelog", skip = true}, # Old redundant commits
|
||||
{ message = "^chore: push version number to", group = "9$Other", skip = true}, # Old redundant commits
|
||||
{ message = "^feat(\\(.*\\))?:", group = "1$Features"},
|
||||
{ message = "^feature(\\(.*\\))?:", group = "1$Features"},
|
||||
{ message = "^fix(\\(.*\\))?:", group = "2$Bug Fixes and Improvements"},
|
||||
{ message = "^docs(\\(.*\\))?:", group = "7$Documentation"},
|
||||
{ message = "^perf(\\(.*\\))?:", group = "3$Performance"},
|
||||
{ message = "^refactor(\\(.*\\))?:", group = "4$Refactor"},
|
||||
{ message = "^style(\\(.*\\))?:", group = "5$Styling"},
|
||||
{ message = "^test(\\(.*\\))?:", group = "9$Other"},
|
||||
{ message = "^locale(\\(.*\\))?:", group = "6$Localization"},
|
||||
{ message = "^chore(\\(.*\\))?:", group = "9$Other"},
|
||||
{ body = ".*security", group = "Security"},
|
||||
]
|
||||
# filter out the commits that are not matched by commit parsers
|
||||
filter_commits = true
|
||||
ignore_tags="v*-(beta|rc)*"
|
||||
# glob pattern for matching git tags
|
||||
tag_pattern = "v[0-9]*"
|
||||
+14
-14
@@ -17,7 +17,7 @@ body = """
|
||||
## [unreleased]
|
||||
{% endif %}\
|
||||
{% for group, commits in commits | group_by(attribute="group") %}\
|
||||
### {{ group | upper_first }}
|
||||
### {{ group | split(pat="$") | last | upper_first }}
|
||||
{% for commit in commits
|
||||
| filter(attribute="scope")
|
||||
| sort(attribute="scope") %}
|
||||
@@ -25,7 +25,6 @@ body = """
|
||||
{%- if commit.breaking %}
|
||||
{% raw %} {% endraw %}- **BREAKING**: {{commit.breaking_description}}
|
||||
{%- endif -%}
|
||||
|
||||
{%- endfor -%}
|
||||
{%- for commit in commits %}
|
||||
{%- if commit.scope -%}
|
||||
@@ -35,7 +34,6 @@ body = """
|
||||
{%- if commit.breaking %}
|
||||
{% raw %} {% endraw %}- **BREAKING**: {{commit.breaking_description}}
|
||||
{%- endif -%}
|
||||
|
||||
{% endif -%}
|
||||
{% endfor -%}
|
||||
{% raw %}\n{% endraw %}
|
||||
@@ -55,16 +53,18 @@ filter_unconventional = false
|
||||
# regex for parsing and grouping commits
|
||||
commit_parsers = [
|
||||
{ message = "^docs\\(changelog\\):", group = "Changelog", skip = true}, # Old redundant commits
|
||||
{ message = "^feat(\\(.*\\))?:", group = "Features"},
|
||||
{ message = "^feature(\\(.*\\))?:", group = "Features"},
|
||||
{ message = "^fix(\\(.*\\))?:", group = "Bug Fixes"},
|
||||
{ message = "^docs(\\(.*\\))?:", group = "Documentation"},
|
||||
{ message = "^perf(\\(.*\\))?:", group = "Performance"},
|
||||
{ message = "^refactor(\\(.*\\))?:", group = "Refactor"},
|
||||
{ message = "^style(\\(.*\\))?:", group = "Styling"},
|
||||
{ message = "^test(\\(.*\\))?:", group = "Testing"},
|
||||
{ message = "^locale(\\(.*\\))?:", group = "Localization"},
|
||||
{ message = "^chore(\\(.*\\))?:", group = "Miscellaneous Tasks", skip = true}, # chore tasks are not relevant for the changelog
|
||||
{ message = "^chore\\(changelog\\): update changelog", group = "Changelog", skip = true}, # Old redundant commits
|
||||
{ message = "^chore: push version number to", group = "9$Other", skip = true}, # Old redundant commits
|
||||
{ message = "^feat(\\(.*\\))?:", group = "1$Features"},
|
||||
{ message = "^feature(\\(.*\\))?:", group = "1$Features"},
|
||||
{ message = "^fix(\\(.*\\))?:", group = "2$Bug Fixes and Improvements"},
|
||||
{ message = "^docs(\\(.*\\))?:", group = "7$Documentation"},
|
||||
{ message = "^perf(\\(.*\\))?:", group = "3$Performance"},
|
||||
{ message = "^refactor(\\(.*\\))?:", group = "4$Refactor"},
|
||||
{ message = "^style(\\(.*\\))?:", group = "5$Styling"},
|
||||
{ message = "^test(\\(.*\\))?:", group = "9$Other"},
|
||||
{ message = "^locale(\\(.*\\))?:", group = "6$Localization"},
|
||||
{ message = "^chore(\\(.*\\))?:", group = "9$Other"},
|
||||
{ body = ".*security", group = "Security"},
|
||||
{ message = "release v2.1.2", group = "Release"}, # workaround for v2.1.2 release
|
||||
]
|
||||
@@ -72,4 +72,4 @@ commit_parsers = [
|
||||
filter_commits = true
|
||||
ignore_tags="v*-(beta|rc)*"
|
||||
# glob pattern for matching git tags
|
||||
tag_pattern = "v[0-9]*"
|
||||
tag_pattern = "v[0-9]*"
|
||||
Generated
+2
-2
@@ -1,12 +1,12 @@
|
||||
{
|
||||
"name": "mainsail",
|
||||
"version": "2.4.0",
|
||||
"version": "2.4.1",
|
||||
"lockfileVersion": 2,
|
||||
"requires": true,
|
||||
"packages": {
|
||||
"": {
|
||||
"name": "mainsail",
|
||||
"version": "2.4.0",
|
||||
"version": "2.4.1",
|
||||
"dependencies": {
|
||||
"@codemirror/commands": "^6.0.1",
|
||||
"@codemirror/lang-css": "^6.0.0",
|
||||
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "mainsail",
|
||||
"version": "2.4.0",
|
||||
"version": "2.4.1",
|
||||
"private": true,
|
||||
"decription": "a klipper web interface",
|
||||
"author": {
|
||||
|
||||
@@ -0,0 +1,8 @@
|
||||
<IfModule mod_rewrite.c>
|
||||
RewriteEngine On
|
||||
RewriteBase /
|
||||
RewriteRule ^index\.html$ - [L]
|
||||
RewriteCond %{REQUEST_FILENAME} !-f
|
||||
RewriteCond %{REQUEST_FILENAME} !-d
|
||||
RewriteRule . /index.html [L]
|
||||
</IfModule>
|
||||
@@ -0,0 +1,7 @@
|
||||
{
|
||||
"defaultLocale": "en",
|
||||
"hostname": null,
|
||||
"port": null,
|
||||
"instancesDB": "browser",
|
||||
"instances": []
|
||||
}
|
||||
@@ -333,3 +333,52 @@ export default class TheEditor extends Mixins(BaseMixin) {
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
::v-deep .ͼ1 .cm-panel.cm-search *:focus:not(.focus-visible) {
|
||||
outline: none;
|
||||
}
|
||||
|
||||
::v-deep .ͼ1 .cm-panel.cm-search input[type='checkbox'] {
|
||||
width: 2.2em;
|
||||
height: 2.2em;
|
||||
color: dodgerblue;
|
||||
vertical-align: middle;
|
||||
-webkit-appearance: none;
|
||||
border: 10px;
|
||||
outline: 0;
|
||||
flex-grow: 0;
|
||||
border-radius: 4px;
|
||||
background: var(--v-toolbar-base);
|
||||
transition: background 300ms;
|
||||
cursor: pointer;
|
||||
margin-right: 0.5em;
|
||||
}
|
||||
|
||||
/* Pseudo element for check styling */
|
||||
|
||||
::v-deep .ͼ1 .cm-panel.cm-search input[type='checkbox']::before {
|
||||
content: '';
|
||||
color: transparent;
|
||||
display: block;
|
||||
width: inherit;
|
||||
height: inherit;
|
||||
border-radius: inherit;
|
||||
border: 2px;
|
||||
background-color: transparent;
|
||||
background-size: contain;
|
||||
box-shadow: inset 0 0 0 1px #ccd3d8;
|
||||
font-size: 16px;
|
||||
}
|
||||
|
||||
/* Checked */
|
||||
|
||||
::v-deep .ͼ1 .cm-panel.cm-search input[type='checkbox']:checked {
|
||||
background-color: var(--color-primary);
|
||||
}
|
||||
|
||||
::v-deep .ͼ1 .cm-panel.cm-search input[type='checkbox']:checked::before {
|
||||
box-shadow: none;
|
||||
background-color: var(--color-primary);
|
||||
background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24'%3E %3Cpath d='M15.88 8.29L10 14.17l-1.88-1.88a.996.996 0 1 0-1.41 1.41l2.59 2.59c.39.39 1.02.39 1.41 0L17.3 9.7a.996.996 0 0 0 0-1.41c-.39-.39-1.03-.39-1.42 0z' fill='%23fffff'/%3E %3C/svg%3E");
|
||||
}
|
||||
</style>
|
||||
@@ -63,7 +63,7 @@
|
||||
class="button-min-width-auto px-3 emergency-button"
|
||||
:loading="loadings.includes('topbarEmergencyStop')"
|
||||
@click="btnEmergencyStop">
|
||||
<v-icon class="mr-md-2">{{ mdiAlertCircleOutline }}</v-icon>
|
||||
<v-icon class="mr-md-2">{{ mdiAlertOctagonOutline }}</v-icon>
|
||||
<span class="d-none d-md-inline">{{ $t('App.TopBar.EmergencyStop') }}</span>
|
||||
</v-btn>
|
||||
<the-notification-menu></the-notification-menu>
|
||||
@@ -84,10 +84,10 @@
|
||||
</v-snackbar>
|
||||
<v-dialog v-model="showEmergencyStopDialog" width="400" :fullscreen="isMobile">
|
||||
<panel
|
||||
:title="$t('EmergencyStopDialog.EmergencyStop')"
|
||||
:title="$t('EmergencyStopDialog.EmergencyStop').toString()"
|
||||
toolbar-color="error"
|
||||
card-class="emergency-stop-dialog"
|
||||
:icon="mdiAlertCircleOutline"
|
||||
:icon="mdiAlertOctagonOutline"
|
||||
:margin-bottom="false">
|
||||
<template #buttons>
|
||||
<v-btn icon tile @click="showEmergencyStopDialog = false">
|
||||
@@ -119,7 +119,7 @@ import PrinterSelector from '@/components/ui/PrinterSelector.vue'
|
||||
import MainsailLogo from '@/components/ui/MainsailLogo.vue'
|
||||
import TheNotificationMenu from '@/components/notifications/TheNotificationMenu.vue'
|
||||
import { topbarHeight } from '@/store/variables'
|
||||
import { mdiAlertCircleOutline, mdiContentSave, mdiFileUpload, mdiClose, mdiCloseThick } from '@mdi/js'
|
||||
import { mdiAlertOctagonOutline, mdiContentSave, mdiFileUpload, mdiClose, mdiCloseThick } from '@mdi/js'
|
||||
|
||||
type uploadSnackbar = {
|
||||
status: boolean
|
||||
@@ -145,7 +145,7 @@ type uploadSnackbar = {
|
||||
},
|
||||
})
|
||||
export default class TheTopbar extends Mixins(BaseMixin) {
|
||||
mdiAlertCircleOutline = mdiAlertCircleOutline
|
||||
mdiAlertOctagonOutline = mdiAlertOctagonOutline
|
||||
mdiContentSave = mdiContentSave
|
||||
mdiFileUpload = mdiFileUpload
|
||||
mdiClose = mdiClose
|
||||
@@ -256,14 +256,14 @@ export default class TheTopbar extends Mixins(BaseMixin) {
|
||||
|
||||
async uploadAndStart() {
|
||||
if (this.$refs.fileUploadAndStart?.files.length) {
|
||||
this.$store.dispatch('socket/addLoading', { name: 'btnUploadAndStart' })
|
||||
await this.$store.dispatch('socket/addLoading', { name: 'btnUploadAndStart' })
|
||||
let successFiles = []
|
||||
for (const file of this.$refs.fileUploadAndStart?.files || []) {
|
||||
const result = await this.doUploadAndStart(file)
|
||||
successFiles.push(result)
|
||||
}
|
||||
|
||||
this.$store.dispatch('socket/removeLoading', { name: 'btnUploadAndStart' })
|
||||
await this.$store.dispatch('socket/removeLoading', { name: 'btnUploadAndStart' })
|
||||
for (const file of successFiles) {
|
||||
const text = this.$t('App.TopBar.UploadOfFileSuccessful', { file: file }).toString()
|
||||
this.$toast.success(text)
|
||||
@@ -329,6 +329,7 @@ export default class TheTopbar extends Mixins(BaseMixin) {
|
||||
</script>
|
||||
|
||||
<style>
|
||||
/*noinspection CssUnusedSymbol*/
|
||||
.topbar .v-toolbar__content {
|
||||
padding-top: 0 !important;
|
||||
padding-bottom: 0 !important;
|
||||
@@ -338,13 +339,17 @@ export default class TheTopbar extends Mixins(BaseMixin) {
|
||||
.button-min-width-auto {
|
||||
min-width: auto !important;
|
||||
}
|
||||
/*noinspection CssUnusedSymbol*/
|
||||
.topbar .v-btn {
|
||||
height: 100% !important;
|
||||
max-height: none;
|
||||
}
|
||||
/*noinspection CssUnusedSymbol*/
|
||||
.topbar .v-btn.v-btn--icon {
|
||||
/*noinspection CssUnresolvedCustomProperty*/
|
||||
width: var(--topbar-icon-btn-width) !important;
|
||||
}
|
||||
/*noinspection CssUnusedSymbol*/
|
||||
@media (min-width: 768px) {
|
||||
header.topbar {
|
||||
z-index: 8 !important;
|
||||
|
||||
@@ -62,7 +62,7 @@
|
||||
<span>+{{ offset }}</span>
|
||||
</v-btn>
|
||||
</v-item-group>
|
||||
<v-item-group class="_btn-group mt-3">
|
||||
<v-item-group class="_btn-group mt-6 mt-sm-3">
|
||||
<v-btn
|
||||
v-for="(offset, index) in offsetsZ"
|
||||
:key="`offsetsDown-${index}`"
|
||||
|
||||
@@ -1,40 +1,26 @@
|
||||
<style scoped>
|
||||
._spin_button_group {
|
||||
width: 24px;
|
||||
margin-top: -6px;
|
||||
margin-left: -6px;
|
||||
margin-bottom: -6px;
|
||||
}
|
||||
|
||||
.v-input--has-state {
|
||||
margin-bottom: -18px !important;
|
||||
}
|
||||
</style>
|
||||
|
||||
<template>
|
||||
<form @submit.prevent="submit">
|
||||
<v-text-field
|
||||
v-model.number="value"
|
||||
v-model="value"
|
||||
:label="label"
|
||||
:suffix="unit"
|
||||
:error="invalidInput()"
|
||||
:error-messages="inputErrors()"
|
||||
:error="invalidInput"
|
||||
:error-messages="inputErrors"
|
||||
:disabled="disabled"
|
||||
:step="step"
|
||||
:min="min"
|
||||
:max="max"
|
||||
:dec="dec"
|
||||
type="number"
|
||||
hide-spin-buttons
|
||||
hide-details="auto"
|
||||
outlined
|
||||
dense
|
||||
class="d-flex align-top"
|
||||
@blur="value = target"
|
||||
@blur="value = target.toString()"
|
||||
@focus="$event.target.select()"
|
||||
@keydown="checkInvalidChars">
|
||||
<template v-if="defaultValue" #append>
|
||||
<v-icon @click="resetToDefault">{{ value !== defaultValue ? mdiRestart : '' }}</v-icon>
|
||||
<v-icon @click="resetToDefault">{{ value !== defaultValue.toString() ? mdiRestart : '' }}</v-icon>
|
||||
</template>
|
||||
<template v-if="hasSpinner" #append-outer>
|
||||
<div class="_spin_button_group">
|
||||
@@ -74,7 +60,7 @@ export default class NumberInput extends Mixins(BaseMixin) {
|
||||
mdiChevronUp = mdiChevronUp
|
||||
mdiChevronDown = mdiChevronDown
|
||||
|
||||
private value: number = 0
|
||||
private value: string = '0'
|
||||
private error: boolean = false
|
||||
private invalidChars: string[] = ['e', 'E', '+']
|
||||
|
||||
@@ -123,40 +109,44 @@ export default class NumberInput extends Mixins(BaseMixin) {
|
||||
declare readonly outputErrorMsg: boolean
|
||||
|
||||
created(): void {
|
||||
this.value = this.target
|
||||
this.value = this.target.toString()
|
||||
}
|
||||
|
||||
@Watch('target')
|
||||
updateTarget(): void {
|
||||
this.value = this.target
|
||||
this.value = this.target.toString()
|
||||
}
|
||||
|
||||
incrementValue(): void {
|
||||
if (this.value + this.step * this.spinnerFactor < this.max! || this.max === null) {
|
||||
this.value = Math.round((this.value + this.step * this.spinnerFactor) * 10 ** this.dec) / 10 ** this.dec
|
||||
} else {
|
||||
this.value = this.max
|
||||
}
|
||||
if (this.inputValue + this.step * this.spinnerFactor < this.max! || this.max === null) {
|
||||
this.value = (
|
||||
Math.round((this.inputValue + this.step * this.spinnerFactor) * 10 ** this.dec) /
|
||||
10 ** this.dec
|
||||
).toString()
|
||||
} else this.value = this.max.toString()
|
||||
|
||||
this.submit()
|
||||
}
|
||||
|
||||
decrementValue(): void {
|
||||
if (this.value - this.step * this.spinnerFactor > this.min) {
|
||||
this.value = Math.round((this.value - this.step * this.spinnerFactor) * 10 ** this.dec) / 10 ** this.dec
|
||||
} else {
|
||||
this.value = this.min
|
||||
}
|
||||
if (this.inputValue - this.step * this.spinnerFactor > this.min) {
|
||||
this.value = (
|
||||
Math.round((this.inputValue - this.step * this.spinnerFactor) * 10 ** this.dec) /
|
||||
10 ** this.dec
|
||||
).toString()
|
||||
} else this.value = this.min.toString()
|
||||
|
||||
this.submit()
|
||||
}
|
||||
|
||||
resetToDefault(): void {
|
||||
this.value = this.defaultValue
|
||||
this.value = this.defaultValue.toString()
|
||||
this.submit()
|
||||
}
|
||||
|
||||
submit(): void {
|
||||
if (this.invalidInput()) return
|
||||
this.$emit('submit', { name: this.param, value: this.value })
|
||||
if (this.invalidInput) return
|
||||
this.$emit('submit', { name: this.param, value: this.inputValue })
|
||||
}
|
||||
|
||||
// input validation //
|
||||
@@ -166,27 +156,44 @@ export default class NumberInput extends Mixins(BaseMixin) {
|
||||
if (this.invalidChars.includes(event.key)) event.preventDefault()
|
||||
}
|
||||
|
||||
invalidInput(): boolean {
|
||||
return this.value.toString() === '' || this.value < this.min || (this.value > this.max! && this.max !== null)
|
||||
// this function only parse this.value, to escape an empty input
|
||||
get inputValue(): number {
|
||||
if (this.value.toString() === '') return 0
|
||||
|
||||
return parseFloat(this.value.replace(',', '.'))
|
||||
}
|
||||
|
||||
inputErrors() {
|
||||
get invalidInput(): boolean {
|
||||
return this.inputErrors.length > 0
|
||||
}
|
||||
|
||||
get inputErrors() {
|
||||
if (!this.outputErrorMsg) return []
|
||||
|
||||
const errors = []
|
||||
if (this.value.toString() === '') {
|
||||
// "Input must not be empty!"
|
||||
errors.push(this.$t('App.NumberInput.NoEmptyAllowedError'))
|
||||
}
|
||||
if (this.max === null && this.value < this.min) {
|
||||
if (this.max === null && this.inputValue < this.min) {
|
||||
// "Must be grater or equal than {min}!"
|
||||
errors.push(this.$t('App.NumberInput.GreaterOrEqualError', { min: this.min }))
|
||||
}
|
||||
if (this.max !== null && (this.value > this.max! || this.value < this.min)) {
|
||||
if (this.max !== null && (this.inputValue > this.max! || this.inputValue < this.min)) {
|
||||
// "Must be between {min} and {max}!"
|
||||
errors.push(this.$t('App.NumberInput.MustBeBetweenError', { min: this.min, max: this.max }))
|
||||
}
|
||||
|
||||
return errors
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
._spin_button_group {
|
||||
width: 24px;
|
||||
margin-top: -6px;
|
||||
margin-left: -6px;
|
||||
margin-bottom: -6px;
|
||||
}
|
||||
|
||||
.v-input--has-state {
|
||||
margin-bottom: -18px !important;
|
||||
}
|
||||
</style>
|
||||
@@ -1,31 +1,22 @@
|
||||
import Component from 'vue-class-component'
|
||||
import BaseMixin from '@/components/mixins/base'
|
||||
import { allDashboardPanels } from '@/store/variables'
|
||||
import { capitalize } from '@/plugins/helpers'
|
||||
import { GuiMacrosStateMacrogroup } from '@/store/gui/macros/types'
|
||||
import {
|
||||
mdiArrowCollapseVertical,
|
||||
mdiCodeTags,
|
||||
mdiConsoleLine,
|
||||
mdiDipSwitch,
|
||||
mdiEngine,
|
||||
mdiGamepad,
|
||||
mdiInformation,
|
||||
mdiPrinter3dNozzle,
|
||||
mdiThermometerLines,
|
||||
mdiWebcam,
|
||||
} from '@mdi/js'
|
||||
|
||||
@Component
|
||||
export default class DashboardMixin extends BaseMixin {
|
||||
get printerKinematics() {
|
||||
return this.$store.getters['printer/getKinematics']
|
||||
}
|
||||
|
||||
get printerExtruderCount() {
|
||||
return this.$store.getters['printer/getExtruders'].length
|
||||
}
|
||||
|
||||
get printerAvailableHeatersCount() {
|
||||
return this.$store.getters['printer/getAvailableHeaters'].length
|
||||
}
|
||||
|
||||
get printerTemperatureSensorsCount() {
|
||||
return this.$store.getters['printer/getTemperatureSensors'].length
|
||||
}
|
||||
|
||||
get macroMode() {
|
||||
return this.$store.state.gui.macros.mode ?? 'simple'
|
||||
}
|
||||
|
||||
get macrogroups() {
|
||||
return this.$store.getters['gui/macros/getAllMacrogroups'] ?? []
|
||||
}
|
||||
@@ -34,89 +25,6 @@ export default class DashboardMixin extends BaseMixin {
|
||||
return this.$store.getters['gui/webcams/getWebcams'] ?? []
|
||||
}
|
||||
|
||||
get missingPanelsMobile() {
|
||||
const panels = [...this.$store.state.gui.dashboard.mobileLayout]
|
||||
|
||||
return this.checkMissingPanels(panels)
|
||||
}
|
||||
|
||||
get missingPanelsTablet() {
|
||||
const panels = [
|
||||
...this.$store.state.gui.dashboard.tabletLayout1,
|
||||
...this.$store.state.gui.dashboard.tabletLayout2,
|
||||
]
|
||||
|
||||
return this.checkMissingPanels(panels)
|
||||
}
|
||||
|
||||
get missingPanelsDesktop() {
|
||||
const panels = [
|
||||
...this.$store.state.gui.dashboard.desktopLayout1,
|
||||
...this.$store.state.gui.dashboard.desktopLayout2,
|
||||
]
|
||||
|
||||
return this.checkMissingPanels(panels)
|
||||
}
|
||||
|
||||
get missingPanelsWidescreen() {
|
||||
const panels = [
|
||||
...this.$store.state.gui.dashboard.widescreenLayout1,
|
||||
...this.$store.state.gui.dashboard.widescreenLayout2,
|
||||
...this.$store.state.gui.dashboard.widescreenLayout3,
|
||||
]
|
||||
|
||||
return this.checkMissingPanels(panels)
|
||||
}
|
||||
|
||||
get allPossiblePanels() {
|
||||
let allPanels = [...allDashboardPanels]
|
||||
|
||||
// remove macros panel and add macrogroups panels if macroMode === expert
|
||||
if (this.macroMode === 'expert') {
|
||||
this.macrogroups.forEach((group: GuiMacrosStateMacrogroup) => {
|
||||
allPanels.push('macrogroup_' + group.id)
|
||||
})
|
||||
|
||||
allPanels = allPanels.filter((name) => name !== 'macros')
|
||||
}
|
||||
|
||||
// remove toolhead panel, if kinematics === none
|
||||
if (this.printerKinematics === 'none') {
|
||||
allPanels = allPanels.filter((name) => name !== 'toolhead-control')
|
||||
}
|
||||
|
||||
// remove extruder panel, if printerExtruderCount < 1
|
||||
if (this.printerExtruderCount < 1) {
|
||||
allPanels = allPanels.filter((name) => name !== 'extruder-control')
|
||||
}
|
||||
|
||||
// remove temperature panel, if heaters & sensors < 1
|
||||
if (this.printerAvailableHeatersCount + this.printerTemperatureSensorsCount < 1) {
|
||||
allPanels = allPanels.filter((name) => name !== 'temperature')
|
||||
}
|
||||
|
||||
// remove webcam panel, if no webcam exists
|
||||
if (this.webcams.length === 0) {
|
||||
allPanels = allPanels.filter((name) => name !== 'webcam')
|
||||
}
|
||||
|
||||
return allPanels
|
||||
}
|
||||
|
||||
checkMissingPanels(panels: any[]) {
|
||||
const missingPanels: any[] = []
|
||||
|
||||
this.allPossiblePanels.forEach((panelname) => {
|
||||
if (!panels.find((panel) => panel.name === panelname))
|
||||
missingPanels.push({
|
||||
name: panelname,
|
||||
visible: true,
|
||||
})
|
||||
})
|
||||
|
||||
return missingPanels
|
||||
}
|
||||
|
||||
getPanelName(name: string) {
|
||||
if (name.startsWith('macrogroup_')) {
|
||||
const groupId = name.split('_')[1] ?? ''
|
||||
@@ -136,4 +44,32 @@ export default class DashboardMixin extends BaseMixin {
|
||||
|
||||
return this.$t(`Panels.${capitalize(name)}Panel.Headline`)
|
||||
}
|
||||
|
||||
convertPanelnameToIcon(name: string): string {
|
||||
if (name.startsWith('macrogroup_')) return mdiCodeTags
|
||||
|
||||
switch (name) {
|
||||
case 'webcam':
|
||||
return mdiWebcam
|
||||
case 'zoffset':
|
||||
return mdiArrowCollapseVertical
|
||||
case 'toolhead-control':
|
||||
return mdiGamepad
|
||||
case 'macros':
|
||||
return mdiCodeTags
|
||||
case 'miscellaneous':
|
||||
return mdiDipSwitch
|
||||
case 'temperature':
|
||||
return mdiThermometerLines
|
||||
case 'miniconsole':
|
||||
return mdiConsoleLine
|
||||
case 'machine-settings':
|
||||
return mdiEngine
|
||||
case 'extruder-control':
|
||||
return mdiPrinter3dNozzle
|
||||
|
||||
default:
|
||||
return mdiInformation
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -461,7 +461,11 @@ export default class ExtruderControlPanel extends Mixins(BaseMixin, ControlMixin
|
||||
}
|
||||
|
||||
get extrudedLength(): number {
|
||||
return Math.round(this.feedamount * this.extrudeFactor * (this.filamentDiameter / this.nozzleDiameter))
|
||||
return Math.round(
|
||||
this.feedamount *
|
||||
this.extrudeFactor *
|
||||
(Math.pow(this.filamentDiameter, 2) / Math.pow(this.nozzleDiameter, 2))
|
||||
)
|
||||
}
|
||||
|
||||
get volumetricFlow(): number {
|
||||
|
||||
@@ -86,7 +86,11 @@
|
||||
<template v-if="networkInterfaces">
|
||||
<div v-for="(interfaceStats, interfaceName) in networkInterfaces" :key="interfaceName">
|
||||
<span class="text-no-wrap">
|
||||
{{ interfaceName }}{{ getIpAddress(interfaceStats.details.ip_addresses) }}:
|
||||
{{ interfaceName }}
|
||||
<template v-if="'details' in interfaceStats">
|
||||
{{ getIpAddress(interfaceStats.details.ip_addresses) }}
|
||||
</template>
|
||||
:
|
||||
</span>
|
||||
<span class="text-no-wrap">
|
||||
{{
|
||||
|
||||
@@ -1,114 +1,7 @@
|
||||
<style lang="scss" scoped>
|
||||
svg {
|
||||
max-height: 350px;
|
||||
min-height: 275px;
|
||||
user-select: none;
|
||||
filter: drop-shadow(0px 10px 10px rgba(0, 0, 0, 0.3));
|
||||
}
|
||||
|
||||
svg a {
|
||||
stroke: hsl(0, 0%, 10%);
|
||||
stroke-width: 0.3px;
|
||||
}
|
||||
|
||||
svg a.step {
|
||||
transition: fill 750ms ease-out;
|
||||
}
|
||||
|
||||
svg a.step:hover {
|
||||
fill: hsl(215, 0%, 50%) !important;
|
||||
transition: fill 100ms ease-in;
|
||||
}
|
||||
|
||||
svg a.step:active {
|
||||
fill: hsl(215, 0%, 70%) !important;
|
||||
}
|
||||
|
||||
svg a.step.inner {
|
||||
fill: #666;
|
||||
}
|
||||
svg a.step.inner-mid {
|
||||
fill: #555;
|
||||
}
|
||||
svg a.step.outer-mid {
|
||||
fill: #444;
|
||||
}
|
||||
svg a.step.outer {
|
||||
fill: #333;
|
||||
}
|
||||
|
||||
svg g#stepsZ,
|
||||
svg g#stepsXY {
|
||||
pointer-events: none;
|
||||
user-select: none;
|
||||
font-family: 'Roboto-Regular', 'Roboto', sans-serif;
|
||||
font-size: 3px;
|
||||
fill: white;
|
||||
}
|
||||
|
||||
svg a#tilt_adjust text {
|
||||
font-family: 'Roboto-Regular', 'Roboto', sans-serif;
|
||||
font-size: 3px;
|
||||
display: none;
|
||||
}
|
||||
|
||||
svg g#home_buttons text {
|
||||
font-family: 'Roboto-Regular', 'Roboto', sans-serif;
|
||||
font-size: 5px;
|
||||
fill: black;
|
||||
}
|
||||
|
||||
svg g.home_button,
|
||||
svg a#home_all_center {
|
||||
fill: var(--color-warning);
|
||||
transition: opacity 250ms;
|
||||
}
|
||||
|
||||
svg a#tilt_adjust,
|
||||
svg a#stepper_off {
|
||||
transition: opacity 250ms;
|
||||
}
|
||||
|
||||
svg a#tilt_adjust.warning,
|
||||
svg a#stepper_off.warning {
|
||||
fill: var(--color-warning);
|
||||
}
|
||||
|
||||
svg a#tilt_adjust.primary,
|
||||
svg a#stepper_off.primary {
|
||||
fill: var(--color-primary);
|
||||
}
|
||||
|
||||
svg g.home_button.homed,
|
||||
svg a#home_all_center.homed {
|
||||
fill: var(--color-primary);
|
||||
}
|
||||
|
||||
svg g.home_button:hover,
|
||||
svg a#home_all_center:hover,
|
||||
svg a#tilt_adjust:hover,
|
||||
svg a#stepper_off:hover {
|
||||
opacity: 0.8;
|
||||
}
|
||||
|
||||
svg a#tilt_adjust text,
|
||||
svg a#tilt_adjust #tilt_icon,
|
||||
svg a#stepper_off #stepper_off_icon,
|
||||
svg g#home_buttons .home-icon {
|
||||
pointer-events: none;
|
||||
user-select: none;
|
||||
}
|
||||
|
||||
svg a#tilt_adjust #tilt_icon,
|
||||
svg a#stepper_off #stepper_off_icon {
|
||||
fill: #000;
|
||||
}
|
||||
</style>
|
||||
|
||||
<template>
|
||||
<div>
|
||||
<v-row>
|
||||
<v-col class="pa-0">
|
||||
<v-col class="pa-0 mt-1">
|
||||
<svg
|
||||
width="100%"
|
||||
height="100%"
|
||||
@@ -120,13 +13,13 @@ svg a#stepper_off #stepper_off_icon {
|
||||
<rect x="0" y="0" width="62" height="62" style="fill: none" />
|
||||
<g id="home_buttons" transform="matrix(0.804902,0,0,1,0.0430241,0)">
|
||||
<!-- HOME X BUTTON -->
|
||||
<a @click="doHomeX">
|
||||
<a :class="xHomeClass" @click="doHomeX">
|
||||
<g
|
||||
id="home_x"
|
||||
transform="matrix(0.707107,-0.707107,0.707107,0.707107,-1.41799,4.05689)">
|
||||
<g
|
||||
id="home_button_x"
|
||||
:class="'home_button' + (homedAxes.includes('x') ? ' homed' : '')"
|
||||
class="home_button"
|
||||
transform="matrix(0.68689,0.68689,-0.68689,0.68689,3.87132,0.962447)">
|
||||
<path :d="pathHomeButtonTop" />
|
||||
</g>
|
||||
@@ -135,20 +28,20 @@ svg a#stepper_off #stepper_off_icon {
|
||||
</g>
|
||||
<g
|
||||
id="Icon"
|
||||
class="home-icon"
|
||||
class="home_icon"
|
||||
transform="matrix(0.147059,0,0,0.147059,2.10662,2.08254)">
|
||||
<path :d="homeIcon" style="fill-rule: nonzero" />
|
||||
</g>
|
||||
</g>
|
||||
</a>
|
||||
<!-- HOME Y BUTTON -->
|
||||
<a @click="doHomeY">
|
||||
<a :class="yHomeClass" @click="doHomeY">
|
||||
<g
|
||||
id="home_y"
|
||||
transform="matrix(0.707107,0.707107,-0.707107,0.707107,57.8807,-1.41799)">
|
||||
<g
|
||||
id="home_button_y"
|
||||
:class="'home_button' + (homedAxes.includes('y') ? ' homed' : '')"
|
||||
class="home_button"
|
||||
transform="matrix(0.68689,0.68689,-0.68689,0.68689,3.87132,0.962447)">
|
||||
<path :d="pathHomeButtonTop" />
|
||||
</g>
|
||||
@@ -157,20 +50,20 @@ svg a#stepper_off #stepper_off_icon {
|
||||
</g>
|
||||
<g
|
||||
id="icon"
|
||||
class="home-icon"
|
||||
class="home_icon"
|
||||
transform="matrix(0.147059,0,0,0.147059,2.10662,2.08254)">
|
||||
<path :d="homeIcon" style="fill-rule: nonzero" />
|
||||
</g>
|
||||
</g>
|
||||
</a>
|
||||
<!-- HOME Z BUTTON -->
|
||||
<a @click="doHomeZ">
|
||||
<a :class="zHomeClass" @click="doHomeZ">
|
||||
<g
|
||||
id="home_z"
|
||||
transform="matrix(-0.707107,0.707107,-0.707107,-0.707107,63.3555,57.8807)">
|
||||
<g
|
||||
id="home_button_z"
|
||||
:class="'home_button ' + (homedAxes.includes('z') ? ' homed' : '')"
|
||||
class="home_button"
|
||||
transform="matrix(0.68689,0.68689,-0.68689,0.68689,3.87132,0.962447)">
|
||||
<path :d="pathHomeButtonBottom" />
|
||||
</g>
|
||||
@@ -179,20 +72,20 @@ svg a#stepper_off #stepper_off_icon {
|
||||
</g>
|
||||
<g
|
||||
id="icon1"
|
||||
class="home-icon"
|
||||
class="home_icon"
|
||||
transform="matrix(0.147059,0,0,0.147059,2.10662,2.08254)">
|
||||
<path :d="homeIcon" style="fill-rule: nonzero" />
|
||||
</g>
|
||||
</g>
|
||||
</a>
|
||||
<!-- HOME XY BUTTON -->
|
||||
<a v-if="enableXYHoming" @click="doHomeXY">
|
||||
<a v-if="enableXYHoming" :class="xyHomeClass" @click="doHomeXY">
|
||||
<g
|
||||
id="home_xy"
|
||||
transform="matrix(-0.707107,-0.707107,0.707107,-0.707107,4.05689,63.3555)">
|
||||
<g
|
||||
id="home_button_xy"
|
||||
:class="'home_button' + (homedAxes.includes('xy') ? ' homed' : '')"
|
||||
class="home_button"
|
||||
transform="matrix(0.68689,0.68689,-0.68689,0.68689,3.87132,0.962447)">
|
||||
<path :d="pathHomeButtonBottom" />
|
||||
</g>
|
||||
@@ -201,35 +94,34 @@ svg a#stepper_off #stepper_off_icon {
|
||||
</g>
|
||||
<g
|
||||
id="icon2"
|
||||
class="home-icon"
|
||||
class="home_icon"
|
||||
transform="matrix(0.147059,0,0,0.147059,2.10662,2.08254)">
|
||||
<path :d="homeIcon" style="fill-rule: nonzero" />
|
||||
</g>
|
||||
</g>
|
||||
</a>
|
||||
<!-- HOME ALL BUTTON -->
|
||||
<a v-if="!enableXYHoming" @click="doHome">
|
||||
<a v-else :class="xyzHomeClass" @click="doHome">
|
||||
<g
|
||||
id="home_all"
|
||||
transform="matrix(-0.707107,-0.707107,0.707107,-0.707107,4.05689,63.3555)">
|
||||
<g
|
||||
id="home_button_all"
|
||||
:class="'home_button' + (homedAxes.includes('xyz') ? ' homed' : '')"
|
||||
class="home_button"
|
||||
transform="matrix(0.68689,0.68689,-0.68689,0.68689,3.87132,0.962447)">
|
||||
<path :d="pathHomeButtonBottom" />
|
||||
</g>
|
||||
<g
|
||||
id="icon3"
|
||||
class="home-icon"
|
||||
class="home_icon"
|
||||
transform="matrix(0.29377,0,0,0.29377,0.346087,1.64241)">
|
||||
<path :d="homeIcon" style="fill-rule: nonzero" />
|
||||
</g>
|
||||
</g>
|
||||
</a>
|
||||
<a v-if="enableXYHoming" @click="doHome">
|
||||
<g
|
||||
id="home_all_center"
|
||||
:class="'home_button' + (homedAxes.includes('xyz') ? ' homed' : '')">
|
||||
<!-- HOME ALL BUTTON IN THE CENTER -->
|
||||
<a v-if="enableXYHoming" :class="xyzHomeClass" @click="doHome">
|
||||
<g id="home_all_center" class="home_button">
|
||||
<circle id="home_button_all_center" cx="31" cy="31" r="5" />
|
||||
</g>
|
||||
<g id="icon4" class="home-icon" transform="scale(0.3) translate(91.25,91.25)">
|
||||
@@ -241,7 +133,10 @@ svg a#stepper_off #stepper_off_icon {
|
||||
<g id="step_buttons" transform="matrix(0.804902,0,0,1,0.0430241,0)">
|
||||
<!-- Z STEPS BUTTONS -->
|
||||
<g id="Z" transform="matrix(1.24239,0,0,1,-0.0534526,0)">
|
||||
<g id="Bottom" transform="matrix(-1,-1.52149e-16,9.85721e-17,-1,114.34,62)">
|
||||
<g
|
||||
id="Bottom"
|
||||
:class="zStepClass"
|
||||
transform="matrix(-1,-1.52149e-16,9.85721e-17,-1,114.34,62)">
|
||||
<a
|
||||
class="step inner"
|
||||
@click="
|
||||
@@ -290,7 +185,7 @@ svg a#stepper_off #stepper_off_icon {
|
||||
</g>
|
||||
</a>
|
||||
</g>
|
||||
<g id="Top">
|
||||
<g id="Top" :class="zStepClass">
|
||||
<a
|
||||
class="step inner"
|
||||
@click="
|
||||
@@ -343,7 +238,7 @@ svg a#stepper_off #stepper_off_icon {
|
||||
</g>
|
||||
</g>
|
||||
<!-- Z STEP BUTTON TEXT -->
|
||||
<g id="stepsZ" transform="matrix(1,0,0,1,40,0)">
|
||||
<g id="stepsZ" :class="zStepClass" transform="matrix(1,0,0,1,40,0)">
|
||||
<g transform="matrix(1,0,0,1,0.483899,4.07983)">
|
||||
<text x="30.7px" y="19.056px" text-anchor="middle">
|
||||
{{ stepsZ.length >= 0 ? stepsZ[0] : '--' }}
|
||||
@@ -367,7 +262,7 @@ svg a#stepper_off #stepper_off_icon {
|
||||
</g>
|
||||
<!-- XY STEP BUTTONS -->
|
||||
<g id="XY">
|
||||
<g id="Right">
|
||||
<g id="Right" :class="xStepClass">
|
||||
<a
|
||||
class="step inner"
|
||||
@click="
|
||||
@@ -417,7 +312,10 @@ svg a#stepper_off #stepper_off_icon {
|
||||
</g>
|
||||
</a>
|
||||
</g>
|
||||
<g id="Left" transform="matrix(-1,-1.22465e-16,1.22465e-16,-1,61.9767,61.9767)">
|
||||
<g
|
||||
id="Left"
|
||||
:class="xStepClass"
|
||||
transform="matrix(-1,-1.22465e-16,1.22465e-16,-1,61.9767,61.9767)">
|
||||
<a
|
||||
class="step inner"
|
||||
@click="
|
||||
@@ -467,7 +365,10 @@ svg a#stepper_off #stepper_off_icon {
|
||||
</g>
|
||||
</a>
|
||||
</g>
|
||||
<g id="Bottom1" transform="matrix(6.12323e-17,1,-1,6.12323e-17,61.9767,-1.77705e-14)">
|
||||
<g
|
||||
id="Bottom1"
|
||||
:class="yStepClass"
|
||||
transform="matrix(6.12323e-17,1,-1,6.12323e-17,61.9767,-1.77705e-14)">
|
||||
<a
|
||||
class="step inner"
|
||||
@click="
|
||||
@@ -517,7 +418,10 @@ svg a#stepper_off #stepper_off_icon {
|
||||
</g>
|
||||
</a>
|
||||
</g>
|
||||
<g id="Top1" transform="matrix(6.12323e-17,-1,1,6.12323e-17,7.10543e-15,61.9767)">
|
||||
<g
|
||||
id="Top1"
|
||||
:class="yStepClass"
|
||||
transform="matrix(6.12323e-17,-1,1,6.12323e-17,7.10543e-15,61.9767)">
|
||||
<a
|
||||
class="step inner"
|
||||
@click="
|
||||
@@ -569,7 +473,7 @@ svg a#stepper_off #stepper_off_icon {
|
||||
</g>
|
||||
</g>
|
||||
<!-- XY STEP BUTTON TEXT -->
|
||||
<g id="stepsXY">
|
||||
<g id="stepsXY" :class="stepTextClass">
|
||||
<g transform="matrix(1,0,0,1,0.483899,4.07983)">
|
||||
<text x="30.5px" y="19.056px" text-anchor="middle">
|
||||
{{ stepsXY.length >= 0 ? stepsXY[0] : '--' }}
|
||||
@@ -617,7 +521,7 @@ svg a#stepper_off #stepper_off_icon {
|
||||
<path :d="zTiltIcon2" />
|
||||
</g>
|
||||
</a>
|
||||
<a v-else id="stepper_off" :class="homedAxes !== '' ? 'primary' : 'warning'" @click="doSend('M84')">
|
||||
<a v-else id="stepper_off" :class="motorsOffClass" @click="doSend('M84')">
|
||||
<circle id="stepper_off_button" cx="70.92" cy="31" r="5" />
|
||||
<g id="stepper_off_icon" transform="scale(0.3) translate(224,91)">
|
||||
<path :d="engineOffIcon" />
|
||||
@@ -710,10 +614,89 @@ export default class CircleControl extends Mixins(BaseMixin, ControlMixin) {
|
||||
return Array.from(new Set([...(steps ?? [])])).sort((a, b) => a - b)
|
||||
}
|
||||
|
||||
get isPrinting() {
|
||||
return ['printing'].includes(this.printer_state)
|
||||
}
|
||||
|
||||
get stepTextClass() {
|
||||
if (!this.homedAxes.includes('xy') || this.isPrinting) return ['disabled']
|
||||
|
||||
return []
|
||||
}
|
||||
|
||||
get xStepClass() {
|
||||
if (!this.homedAxes.includes('x') || this.isPrinting) return ['disabled']
|
||||
|
||||
return []
|
||||
}
|
||||
|
||||
get yStepClass() {
|
||||
if (!this.homedAxes.includes('y') || this.isPrinting) return ['disabled']
|
||||
|
||||
return []
|
||||
}
|
||||
|
||||
get zStepClass() {
|
||||
if (!this.homedAxes.includes('z') || this.isPrinting) return ['disabled']
|
||||
|
||||
return []
|
||||
}
|
||||
|
||||
get xHomeClass() {
|
||||
let classes = []
|
||||
if (this.homedAxes.includes('x')) classes.push('homed')
|
||||
if (this.isPrinting) classes.push('disabled')
|
||||
|
||||
return classes
|
||||
}
|
||||
|
||||
get yHomeClass() {
|
||||
let classes = []
|
||||
if (this.homedAxes.includes('y')) classes.push('homed')
|
||||
if (this.isPrinting) classes.push('disabled')
|
||||
|
||||
return classes
|
||||
}
|
||||
|
||||
get xyHomeClass() {
|
||||
let classes = []
|
||||
if (this.homedAxes.includes('xy')) classes.push('homed')
|
||||
if (this.isPrinting) classes.push('disabled')
|
||||
|
||||
return classes
|
||||
}
|
||||
|
||||
get xyzHomeClass() {
|
||||
let classes = []
|
||||
if (this.homedAxes.includes('xyz')) classes.push('homed')
|
||||
if (this.isPrinting) classes.push('disabled')
|
||||
|
||||
return classes
|
||||
}
|
||||
|
||||
get zHomeClass() {
|
||||
let classes = []
|
||||
if (this.homedAxes.includes('z')) classes.push('homed')
|
||||
if (this.isPrinting) classes.push('disabled')
|
||||
|
||||
return classes
|
||||
}
|
||||
|
||||
get colorSpecialButton() {
|
||||
if (this.existsQGL) return this.colorQuadGantryLevel
|
||||
else if (this.existsZtilt) return this.colorZTilt
|
||||
else return 'warning'
|
||||
let classes = []
|
||||
if (this.isPrinting) classes.push('disabled')
|
||||
if (this.existsQGL) classes.push(this.colorQuadGantryLevel)
|
||||
else if (this.existsZtilt) classes.push(this.colorZTilt)
|
||||
|
||||
return classes
|
||||
}
|
||||
|
||||
get motorsOffClass() {
|
||||
let classes = []
|
||||
classes.push(this.homedAxes !== '' ? 'primary' : 'warning')
|
||||
if (this.isPrinting) classes.push('disabled')
|
||||
|
||||
return classes
|
||||
}
|
||||
|
||||
clickSpecialButton() {
|
||||
@@ -722,3 +705,128 @@ export default class CircleControl extends Mixins(BaseMixin, ControlMixin) {
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
svg {
|
||||
max-height: 350px;
|
||||
min-height: 275px;
|
||||
user-select: none;
|
||||
filter: drop-shadow(0px 10px 10px rgba(0, 0, 0, 0.3));
|
||||
}
|
||||
|
||||
svg a {
|
||||
stroke: hsl(0, 0%, 10%);
|
||||
stroke-width: 0.3px;
|
||||
}
|
||||
|
||||
svg a.step {
|
||||
transition: fill 750ms ease-out;
|
||||
}
|
||||
|
||||
svg a.step:hover {
|
||||
fill: hsl(215, 0%, 50%) !important;
|
||||
transition: fill 100ms ease-in;
|
||||
}
|
||||
|
||||
svg a.step:active {
|
||||
fill: hsl(215, 0%, 70%) !important;
|
||||
}
|
||||
|
||||
svg a.step.inner {
|
||||
fill: #666;
|
||||
}
|
||||
svg a.step.inner-mid {
|
||||
fill: #555;
|
||||
}
|
||||
svg a.step.outer-mid {
|
||||
fill: #444;
|
||||
}
|
||||
svg a.step.outer {
|
||||
fill: #333;
|
||||
}
|
||||
|
||||
svg .disabled a.step {
|
||||
pointer-events: none;
|
||||
}
|
||||
|
||||
svg g#stepsZ,
|
||||
svg g#stepsXY {
|
||||
pointer-events: none;
|
||||
user-select: none;
|
||||
font-family: 'Roboto-Regular', 'Roboto', sans-serif;
|
||||
font-size: 3px;
|
||||
fill: white;
|
||||
}
|
||||
|
||||
svg a#tilt_adjust text {
|
||||
font-family: 'Roboto-Regular', 'Roboto', sans-serif;
|
||||
font-size: 3px;
|
||||
display: none;
|
||||
}
|
||||
|
||||
svg g#home_buttons text {
|
||||
font-family: 'Roboto-Regular', 'Roboto', sans-serif;
|
||||
font-size: 5px;
|
||||
fill: black;
|
||||
}
|
||||
|
||||
svg g.home_button,
|
||||
svg a#home_all_center {
|
||||
fill: var(--color-warning);
|
||||
transition: opacity 250ms;
|
||||
}
|
||||
|
||||
svg a.disabled {
|
||||
pointer-events: none;
|
||||
}
|
||||
|
||||
svg a.disabled .home_button path,
|
||||
svg a.disabled circle {
|
||||
fill: rgb(92, 92, 92);
|
||||
}
|
||||
|
||||
svg g#stepsXY.disabled text,
|
||||
svg g#stepsZ.disabled text {
|
||||
fill: rgba(255, 255, 255, 0.3);
|
||||
}
|
||||
|
||||
svg a#tilt_adjust,
|
||||
svg a#stepper_off {
|
||||
transition: opacity 250ms;
|
||||
}
|
||||
|
||||
svg a#tilt_adjust.warning,
|
||||
svg a#stepper_off.warning {
|
||||
fill: var(--color-warning);
|
||||
}
|
||||
|
||||
svg a#tilt_adjust.primary,
|
||||
svg a#stepper_off.primary {
|
||||
fill: var(--color-primary);
|
||||
}
|
||||
|
||||
svg .homed g.home_button,
|
||||
svg .homed a#home_all_center {
|
||||
fill: var(--color-primary);
|
||||
}
|
||||
|
||||
svg g.home_button:hover,
|
||||
svg a#home_all_center:hover,
|
||||
svg a#tilt_adjust:hover,
|
||||
svg a#stepper_off:hover {
|
||||
opacity: 0.8;
|
||||
}
|
||||
|
||||
svg a#tilt_adjust text,
|
||||
svg a#tilt_adjust #tilt_icon,
|
||||
svg a#stepper_off #stepper_off_icon,
|
||||
svg g#home_buttons .home_icon {
|
||||
pointer-events: none;
|
||||
user-select: none;
|
||||
}
|
||||
|
||||
svg a#tilt_adjust #tilt_icon,
|
||||
svg a#stepper_off #stepper_off_icon {
|
||||
fill: #000;
|
||||
}
|
||||
</style>
|
||||
@@ -0,0 +1,40 @@
|
||||
<template>
|
||||
<v-card flat>
|
||||
<v-card-text>
|
||||
<v-row>
|
||||
<v-col class="col-12 col-md-6">
|
||||
<settings-dashboard-sortable viewport-name="desktop" :column="1" />
|
||||
</v-col>
|
||||
<v-col class="col-12 col-md-6">
|
||||
<settings-dashboard-sortable viewport-name="desktop" :column="2" />
|
||||
</v-col>
|
||||
</v-row>
|
||||
<v-row>
|
||||
<v-col class="text-center">
|
||||
<v-btn color="error" @click="resetLayout">{{ $t('Settings.DashboardTab.ResetLayout') }}</v-btn>
|
||||
</v-col>
|
||||
</v-row>
|
||||
</v-card-text>
|
||||
</v-card>
|
||||
</template>
|
||||
|
||||
<script lang="ts">
|
||||
import Component from 'vue-class-component'
|
||||
import { Mixins } from 'vue-property-decorator'
|
||||
import DashboardMixin from '@/components/mixins/dashboard'
|
||||
import SettingsDashboardSortable from '@/components/settings/Dashboard/Sortable.vue'
|
||||
|
||||
@Component({
|
||||
components: {
|
||||
SettingsDashboardSortable,
|
||||
},
|
||||
})
|
||||
export default class SettingsDashboardTabDesktop extends Mixins(DashboardMixin) {
|
||||
resetLayout() {
|
||||
this.$store.dispatch('gui/resetLayout', 'desktopLayout1')
|
||||
this.$store.dispatch('gui/resetLayout', 'desktopLayout2')
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped></style>
|
||||
@@ -0,0 +1,36 @@
|
||||
<template>
|
||||
<v-card flat>
|
||||
<v-card-text>
|
||||
<v-row>
|
||||
<v-col>
|
||||
<settings-dashboard-sortable viewport-name="mobile" :column="0" />
|
||||
</v-col>
|
||||
</v-row>
|
||||
<v-row>
|
||||
<v-col class="text-center">
|
||||
<v-btn color="error" @click="resetLayout">{{ $t('Settings.DashboardTab.ResetLayout') }}</v-btn>
|
||||
</v-col>
|
||||
</v-row>
|
||||
</v-card-text>
|
||||
</v-card>
|
||||
</template>
|
||||
|
||||
<script lang="ts">
|
||||
import Component from 'vue-class-component'
|
||||
import { Mixins } from 'vue-property-decorator'
|
||||
import DashboardMixin from '@/components/mixins/dashboard'
|
||||
import SettingsDashboardSortable from '@/components/settings/Dashboard/Sortable.vue'
|
||||
|
||||
@Component({
|
||||
components: {
|
||||
SettingsDashboardSortable,
|
||||
},
|
||||
})
|
||||
export default class SettingsDashboardTabMobile extends Mixins(DashboardMixin) {
|
||||
resetLayout() {
|
||||
this.$store.dispatch('gui/resetLayout', 'mobileLayout')
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped></style>
|
||||
@@ -0,0 +1,100 @@
|
||||
<template>
|
||||
<v-card class="mx-auto fill-height" max-width="300" tile>
|
||||
<v-list class="fill-height" dense>
|
||||
<v-list-item v-if="column < 2">
|
||||
<v-row>
|
||||
<v-col class="col-auto pr-0 pl-8">
|
||||
<v-icon>{{ mdiInformation }}</v-icon>
|
||||
</v-col>
|
||||
<v-col class="pr-0 text-truncate">
|
||||
{{ $t('Panels.StatusPanel.Headline') }}
|
||||
</v-col>
|
||||
<v-col class="col-auto pl-0">
|
||||
<v-icon color="grey lighten-1">{{ mdiLock }}</v-icon>
|
||||
</v-col>
|
||||
</v-row>
|
||||
</v-list-item>
|
||||
<draggable
|
||||
v-model="layout"
|
||||
handle=".handle"
|
||||
class="v-list-item-group fill-height"
|
||||
ghost-class="ghost"
|
||||
:group="groupname">
|
||||
<transition-group>
|
||||
<settings-dashboard-sortable-item
|
||||
v-for="element in layout"
|
||||
:key="`item-${element.name}`"
|
||||
:name="element.name"
|
||||
:visible="element.visible"
|
||||
@change-visible="changeVisible" />
|
||||
</transition-group>
|
||||
</draggable>
|
||||
</v-list>
|
||||
</v-card>
|
||||
</template>
|
||||
|
||||
<script lang="ts">
|
||||
import Component from 'vue-class-component'
|
||||
import { Mixins, Prop } from 'vue-property-decorator'
|
||||
import draggable from 'vuedraggable'
|
||||
import { mdiInformation, mdiLock } from '@mdi/js'
|
||||
import DashboardMixin from '@/components/mixins/dashboard'
|
||||
import SettingsDashboardSortableItem from '@/components/settings/Dashboard/SortableItem.vue'
|
||||
|
||||
@Component({
|
||||
components: { SettingsDashboardSortableItem, draggable },
|
||||
})
|
||||
export default class SettingsDashboardSortable extends Mixins(DashboardMixin) {
|
||||
/**
|
||||
* Icons
|
||||
*/
|
||||
mdiInformation = mdiInformation
|
||||
mdiLock = mdiLock
|
||||
|
||||
@Prop({ type: String, required: true }) declare readonly viewportName: string
|
||||
@Prop({ type: Number, required: false, default: 1 }) declare readonly column: number
|
||||
|
||||
get layoutname() {
|
||||
if (this.column) return `${this.viewportName}Layout${this.column}`
|
||||
|
||||
return `${this.viewportName}Layout`
|
||||
}
|
||||
|
||||
get groupname() {
|
||||
return `${this.viewportName}Viewport`
|
||||
}
|
||||
|
||||
get layout() {
|
||||
return this.$store.getters['gui/getPanels'](this.viewportName, this.column)
|
||||
}
|
||||
|
||||
set layout(newVal) {
|
||||
newVal = newVal.filter((element: any) => element !== undefined)
|
||||
|
||||
this.$store.dispatch('gui/saveSetting', { name: `dashboard.${this.layoutname}`, value: newVal })
|
||||
}
|
||||
|
||||
changeVisible(name: string, newVal: boolean) {
|
||||
const index = this.layout.findIndex((element: any) => element.name === name)
|
||||
if (index !== -1) {
|
||||
this.layout[index].visible = newVal
|
||||
this.$store.dispatch('gui/saveSetting', {
|
||||
name: `dashboard.${this.layoutname}`,
|
||||
value: this.layout,
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
/deep/ .ghost {
|
||||
opacity: 0.5;
|
||||
background: #c8ebfb;
|
||||
}
|
||||
|
||||
.v-list-item-group > span {
|
||||
display: block;
|
||||
height: 100%;
|
||||
}
|
||||
</style>
|
||||
@@ -0,0 +1,67 @@
|
||||
<template>
|
||||
<v-list-item>
|
||||
<v-row>
|
||||
<v-col class="col-auto px-0">
|
||||
<v-icon class="handle pr-2">{{ mdiDragVertical }}</v-icon>
|
||||
<v-icon>{{ icon }}</v-icon>
|
||||
</v-col>
|
||||
<v-col class="pr-0 text-truncate">
|
||||
{{ panelname }}
|
||||
</v-col>
|
||||
<v-col class="col-auto pl-2">
|
||||
<v-icon
|
||||
:color="checkboxColor"
|
||||
@click.stop="$emit('change-visible', name, !visible)"
|
||||
v-html="checkboxIcon" />
|
||||
</v-col>
|
||||
</v-row>
|
||||
</v-list-item>
|
||||
</template>
|
||||
|
||||
<script lang="ts">
|
||||
import Component from 'vue-class-component'
|
||||
import { Mixins, Prop } from 'vue-property-decorator'
|
||||
import draggable from 'vuedraggable'
|
||||
import { mdiCheckboxBlankOutline, mdiCheckboxMarked, mdiDragVertical, mdiInformation } from '@mdi/js'
|
||||
import DashboardMixin from '@/components/mixins/dashboard'
|
||||
|
||||
@Component({
|
||||
components: { draggable },
|
||||
})
|
||||
export default class SettingsDashboardSortableItem extends Mixins(DashboardMixin) {
|
||||
/**
|
||||
* Icons
|
||||
*/
|
||||
mdiInformation = mdiInformation
|
||||
mdiDragVertical = mdiDragVertical
|
||||
|
||||
@Prop({ type: String, required: true }) declare readonly name: string
|
||||
@Prop({ type: Boolean, required: true }) declare readonly visible: boolean
|
||||
|
||||
get panelname() {
|
||||
return this.getPanelName(this.name)
|
||||
}
|
||||
|
||||
get icon() {
|
||||
return this.convertPanelnameToIcon(this.name)
|
||||
}
|
||||
|
||||
get checkboxColor() {
|
||||
if (this.visible) return 'primary'
|
||||
|
||||
return 'grey lighten-1'
|
||||
}
|
||||
|
||||
get checkboxIcon() {
|
||||
if (this.visible) return mdiCheckboxMarked
|
||||
|
||||
return mdiCheckboxBlankOutline
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
.handle {
|
||||
cursor: move;
|
||||
}
|
||||
</style>
|
||||
@@ -0,0 +1,39 @@
|
||||
<template>
|
||||
<v-card flat>
|
||||
<v-card-text>
|
||||
<v-row>
|
||||
<v-col class="col-12 col-md-6">
|
||||
<settings-dashboard-sortable viewport-name="tablet" :column="1" />
|
||||
</v-col>
|
||||
<v-col class="col-12 col-md-6">
|
||||
<settings-dashboard-sortable viewport-name="tablet" :column="2" />
|
||||
</v-col>
|
||||
</v-row>
|
||||
<v-row>
|
||||
<v-col class="text-center">
|
||||
<v-btn color="error" @click="resetLayout">{{ $t('Settings.DashboardTab.ResetLayout') }}</v-btn>
|
||||
</v-col>
|
||||
</v-row>
|
||||
</v-card-text>
|
||||
</v-card>
|
||||
</template>
|
||||
|
||||
<script lang="ts">
|
||||
import Component from 'vue-class-component'
|
||||
import { Mixins } from 'vue-property-decorator'
|
||||
import DashboardMixin from '@/components/mixins/dashboard'
|
||||
import SettingsDashboardSortable from '@/components/settings/Dashboard/Sortable.vue'
|
||||
@Component({
|
||||
components: {
|
||||
SettingsDashboardSortable,
|
||||
},
|
||||
})
|
||||
export default class SettingsDashboardTabTablet extends Mixins(DashboardMixin) {
|
||||
resetLayout() {
|
||||
this.$store.dispatch('gui/resetLayout', 'tabletLayout1')
|
||||
this.$store.dispatch('gui/resetLayout', 'tabletLayout2')
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped></style>
|
||||
@@ -0,0 +1,43 @@
|
||||
<template>
|
||||
<v-card flat>
|
||||
<v-card-text>
|
||||
<v-row>
|
||||
<v-col class="col-12 col-md-4">
|
||||
<settings-dashboard-sortable viewport-name="widescreen" :column="1" />
|
||||
</v-col>
|
||||
<v-col class="col-12 col-md-4">
|
||||
<settings-dashboard-sortable viewport-name="widescreen" :column="2" />
|
||||
</v-col>
|
||||
<v-col class="col-12 col-md-4">
|
||||
<settings-dashboard-sortable viewport-name="widescreen" :column="3" />
|
||||
</v-col>
|
||||
</v-row>
|
||||
<v-row>
|
||||
<v-col class="text-center">
|
||||
<v-btn color="error" @click="resetLayout">{{ $t('Settings.DashboardTab.ResetLayout') }}</v-btn>
|
||||
</v-col>
|
||||
</v-row>
|
||||
</v-card-text>
|
||||
</v-card>
|
||||
</template>
|
||||
|
||||
<script lang="ts">
|
||||
import Component from 'vue-class-component'
|
||||
import { Mixins } from 'vue-property-decorator'
|
||||
import DashboardMixin from '@/components/mixins/dashboard'
|
||||
import SettingsDashboardSortable from '@/components/settings/Dashboard/Sortable.vue'
|
||||
@Component({
|
||||
components: {
|
||||
SettingsDashboardSortable,
|
||||
},
|
||||
})
|
||||
export default class SettingsDashboardTabWidescreen extends Mixins(DashboardMixin) {
|
||||
resetLayout() {
|
||||
this.$store.dispatch('gui/resetLayout', 'widescreenLayout1')
|
||||
this.$store.dispatch('gui/resetLayout', 'widescreenLayout2')
|
||||
this.$store.dispatch('gui/resetLayout', 'widescreenLayout3')
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped></style>
|
||||
@@ -1,4 +1,8 @@
|
||||
<style scoped></style>
|
||||
<style scoped>
|
||||
.dashboard-rows-container /deep/ .v-list-item-group {
|
||||
min-height: 80px;
|
||||
}
|
||||
</style>
|
||||
|
||||
<template>
|
||||
<v-card flat>
|
||||
@@ -33,7 +37,7 @@
|
||||
</v-col>
|
||||
</v-row>
|
||||
<v-row>
|
||||
<v-col>
|
||||
<v-col class="dashboard-rows-container">
|
||||
<component :is="currentTab"></component>
|
||||
</v-col>
|
||||
</v-row>
|
||||
@@ -45,16 +49,14 @@
|
||||
import Component from 'vue-class-component'
|
||||
import { Mixins } from 'vue-property-decorator'
|
||||
import BaseMixin from '@/components/mixins/base'
|
||||
import draggable from 'vuedraggable'
|
||||
import SettingsDashboardTabMobile from '@/components/settings/SettingsDashboardTabMobile.vue'
|
||||
import SettingsDashboardTabTablet from '@/components/settings/SettingsDashboardTabTablet.vue'
|
||||
import SettingsDashboardTabDesktop from '@/components/settings/SettingsDashboardTabDesktop.vue'
|
||||
import SettingsDashboardTabWidescreen from '@/components/settings/SettingsDashboardTabWidescreen.vue'
|
||||
import SettingsDashboardTabMobile from '@/components/settings/Dashboard/Mobile.vue'
|
||||
import SettingsDashboardTabTablet from '@/components/settings/Dashboard/Tablet.vue'
|
||||
import SettingsDashboardTabDesktop from '@/components/settings/Dashboard/Desktop.vue'
|
||||
import SettingsDashboardTabWidescreen from '@/components/settings/Dashboard/Widescreen.vue'
|
||||
import { mdiCellphone, mdiMonitorScreenshot, mdiMonitorDashboard, mdiTablet } from '@mdi/js'
|
||||
|
||||
@Component({
|
||||
components: {
|
||||
draggable,
|
||||
SettingsDashboardTabMobile,
|
||||
SettingsDashboardTabTablet,
|
||||
SettingsDashboardTabDesktop,
|
||||
|
||||
@@ -1,192 +0,0 @@
|
||||
<template>
|
||||
<v-card flat>
|
||||
<v-card-text>
|
||||
<v-row>
|
||||
<v-col class="col-12 col-md-6">
|
||||
<v-card class="mx-auto" max-width="300" tile>
|
||||
<v-list dense>
|
||||
<v-list-item>
|
||||
<v-row>
|
||||
<v-col class="col-auto pr-0 pl-8">
|
||||
<v-icon>{{ mdiInformation }}</v-icon>
|
||||
</v-col>
|
||||
<v-col class="pr-0 text-truncate">
|
||||
{{ $t('Panels.StatusPanel.Headline') }}
|
||||
</v-col>
|
||||
<v-col class="col-auto pl-0">
|
||||
<v-icon color="grey lighten-1">{{ mdiLock }}</v-icon>
|
||||
</v-col>
|
||||
</v-row>
|
||||
</v-list-item>
|
||||
<draggable
|
||||
v-model="desktopLayout1"
|
||||
handle=".handle"
|
||||
class="v-list-item-group"
|
||||
ghost-class="ghost"
|
||||
group="desktopViewport">
|
||||
<template v-for="element in desktopLayout1">
|
||||
<v-list-item :key="'item-desktop-' + element.name">
|
||||
<v-row class="d-flex align-center">
|
||||
<v-col class="col-auto px-0">
|
||||
<v-icon class="handle pr-2">{{ mdiDragVertical }}</v-icon>
|
||||
<v-icon v-text="convertPanelnameToIcon(element.name)"></v-icon>
|
||||
</v-col>
|
||||
<v-col class="pr-0 text-truncate">
|
||||
{{ getPanelName(element.name) }}
|
||||
</v-col>
|
||||
<v-col class="col-auto pl-2">
|
||||
<v-icon
|
||||
v-if="!element.visible"
|
||||
color="grey lighten-1"
|
||||
@click.stop="changeState1(element.name, true)">
|
||||
{{ mdiCheckboxBlankOutline }}
|
||||
</v-icon>
|
||||
<v-icon
|
||||
v-else
|
||||
color="primary"
|
||||
@click.stop="changeState1(element.name, false)">
|
||||
{{ mdiCheckboxMarked }}
|
||||
</v-icon>
|
||||
</v-col>
|
||||
</v-row>
|
||||
</v-list-item>
|
||||
</template>
|
||||
</draggable>
|
||||
</v-list>
|
||||
</v-card>
|
||||
</v-col>
|
||||
<v-col class="col-12 col-md-6">
|
||||
<v-card class="mx-auto" max-width="300" tile>
|
||||
<v-list dense>
|
||||
<draggable
|
||||
v-model="desktopLayout2"
|
||||
handle=".handle"
|
||||
class="v-list-item-group"
|
||||
ghost-class="ghost"
|
||||
group="desktopViewport">
|
||||
<template v-for="element in desktopLayout2">
|
||||
<v-list-item :key="'item-desktop-' + element.name">
|
||||
<v-row class="d-flex align-center">
|
||||
<v-col class="col-auto px-0">
|
||||
<v-icon class="handle pr-2">{{ mdiDragVertical }}</v-icon>
|
||||
<v-icon v-text="convertPanelnameToIcon(element.name)"></v-icon>
|
||||
</v-col>
|
||||
<v-col class="pr-0 text-truncate">
|
||||
{{ getPanelName(element.name) }}
|
||||
</v-col>
|
||||
<v-col class="col-auto pl-2">
|
||||
<v-icon
|
||||
v-if="!element.visible"
|
||||
color="grey lighten-1"
|
||||
@click.stop="changeState2(element.name, true)">
|
||||
{{ mdiCheckboxBlankOutline }}
|
||||
</v-icon>
|
||||
<v-icon
|
||||
v-else
|
||||
color="primary"
|
||||
@click.stop="changeState2(element.name, false)">
|
||||
{{ mdiCheckboxMarked }}
|
||||
</v-icon>
|
||||
</v-col>
|
||||
</v-row>
|
||||
</v-list-item>
|
||||
</template>
|
||||
</draggable>
|
||||
</v-list>
|
||||
</v-card>
|
||||
</v-col>
|
||||
</v-row>
|
||||
<v-row>
|
||||
<v-col class="text-center">
|
||||
<v-btn color="error" @click="resetLayout">{{ $t('Settings.DashboardTab.ResetLayout') }}</v-btn>
|
||||
</v-col>
|
||||
</v-row>
|
||||
</v-card-text>
|
||||
</v-card>
|
||||
</template>
|
||||
|
||||
<script lang="ts">
|
||||
import Component from 'vue-class-component'
|
||||
import { Mixins } from 'vue-property-decorator'
|
||||
import draggable from 'vuedraggable'
|
||||
import { convertPanelnameToIcon } from '@/plugins/helpers'
|
||||
import DashboardMixin from '@/components/mixins/dashboard'
|
||||
import { mdiInformation, mdiCheckboxMarked, mdiCheckboxBlankOutline, mdiLock, mdiDragVertical } from '@mdi/js'
|
||||
|
||||
@Component({
|
||||
components: {
|
||||
draggable,
|
||||
},
|
||||
})
|
||||
export default class SettingsDashboardTabDesktop extends Mixins(DashboardMixin) {
|
||||
/**
|
||||
* Icons
|
||||
*/
|
||||
mdiLock = mdiLock
|
||||
mdiInformation = mdiInformation
|
||||
mdiDragVertical = mdiDragVertical
|
||||
mdiCheckboxMarked = mdiCheckboxMarked
|
||||
mdiCheckboxBlankOutline = mdiCheckboxBlankOutline
|
||||
|
||||
convertPanelnameToIcon = convertPanelnameToIcon
|
||||
|
||||
get desktopLayout1() {
|
||||
let panels = this.$store.getters['gui/getPanels']('desktopLayout1')
|
||||
panels = panels.concat(this.missingPanelsDesktop)
|
||||
panels = panels.filter((element: any) => this.allPossiblePanels.includes(element.name))
|
||||
|
||||
return panels
|
||||
}
|
||||
|
||||
set desktopLayout1(newVal) {
|
||||
newVal = newVal.filter((element: any) => element !== undefined)
|
||||
|
||||
this.$store.dispatch('gui/saveSetting', { name: 'dashboard.desktopLayout1', value: newVal })
|
||||
}
|
||||
|
||||
get desktopLayout2() {
|
||||
let panels = this.$store.getters['gui/getPanels']('desktopLayout2')
|
||||
panels = panels.filter((element: any) => this.allPossiblePanels.includes(element.name))
|
||||
|
||||
return panels
|
||||
}
|
||||
|
||||
set desktopLayout2(newVal) {
|
||||
newVal = newVal.filter((element: any) => element !== undefined)
|
||||
|
||||
this.$store.dispatch('gui/saveSetting', { name: 'dashboard.desktopLayout2', value: newVal })
|
||||
}
|
||||
|
||||
changeState1(name: string, newVal: boolean) {
|
||||
const index = this.desktopLayout1.findIndex((element: any) => element.name === name)
|
||||
if (index !== -1) {
|
||||
this.desktopLayout1[index].visible = newVal
|
||||
this.$store.dispatch('gui/saveSetting', { name: 'dashboard.desktopLayout1', value: this.desktopLayout1 })
|
||||
}
|
||||
}
|
||||
|
||||
changeState2(name: string, newVal: boolean) {
|
||||
const index = this.desktopLayout2.findIndex((element: any) => element.name === name)
|
||||
if (index !== -1) {
|
||||
this.desktopLayout2[index].visible = newVal
|
||||
this.$store.dispatch('gui/saveSetting', { name: 'dashboard.desktopLayout2', value: this.desktopLayout2 })
|
||||
}
|
||||
}
|
||||
|
||||
resetLayout() {
|
||||
this.$store.dispatch('gui/resetLayout', 'desktopLayout1')
|
||||
this.$store.dispatch('gui/resetLayout', 'desktopLayout2')
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
.ghost {
|
||||
opacity: 0.5;
|
||||
background: #c8ebfb;
|
||||
}
|
||||
|
||||
.handle {
|
||||
cursor: move;
|
||||
}
|
||||
</style>
|
||||
@@ -1,129 +0,0 @@
|
||||
<template>
|
||||
<v-card flat>
|
||||
<v-card-text>
|
||||
<v-row>
|
||||
<v-col>
|
||||
<v-card class="mx-auto" max-width="300" tile>
|
||||
<v-list dense>
|
||||
<v-list-item>
|
||||
<v-row>
|
||||
<v-col class="col-auto pr-0 pl-8">
|
||||
<v-icon>{{ mdiInformation }}</v-icon>
|
||||
</v-col>
|
||||
<v-col class="pr-0 text-truncate">
|
||||
{{ $t('Panels.StatusPanel.Headline') }}
|
||||
</v-col>
|
||||
<v-col class="col-auto pl-0">
|
||||
<v-icon color="grey lighten-1">{{ mdiLock }}</v-icon>
|
||||
</v-col>
|
||||
</v-row>
|
||||
</v-list-item>
|
||||
<draggable
|
||||
v-model="mobileLayout"
|
||||
handle=".handle"
|
||||
class="v-list-item-group"
|
||||
ghost-class="ghost"
|
||||
group="mobileViewport">
|
||||
<template v-for="element in mobileLayout">
|
||||
<v-list-item :key="'item-mobile-' + element.name">
|
||||
<v-row class="d-flex align-center">
|
||||
<v-col class="col-auto px-0">
|
||||
<v-icon class="handle pr-2">{{ mdiDragVertical }}</v-icon>
|
||||
<v-icon v-text="convertPanelnameToIcon(element.name)"></v-icon>
|
||||
</v-col>
|
||||
<v-col class="pr-0 text-truncate">
|
||||
{{ getPanelName(element.name) }}
|
||||
</v-col>
|
||||
<v-col class="col-auto pl-2">
|
||||
<v-icon
|
||||
v-if="!element.visible"
|
||||
color="grey lighten-1"
|
||||
@click.stop="changeState(element.name, true)">
|
||||
{{ mdiCheckboxBlankOutline }}
|
||||
</v-icon>
|
||||
<v-icon
|
||||
v-else
|
||||
color="primary"
|
||||
@click.stop="changeState(element.name, false)">
|
||||
{{ mdiCheckboxMarked }}
|
||||
</v-icon>
|
||||
</v-col>
|
||||
</v-row>
|
||||
</v-list-item>
|
||||
</template>
|
||||
</draggable>
|
||||
</v-list>
|
||||
</v-card>
|
||||
</v-col>
|
||||
</v-row>
|
||||
<v-row>
|
||||
<v-col class="text-center">
|
||||
<v-btn color="error" @click="resetLayout">{{ $t('Settings.DashboardTab.ResetLayout') }}</v-btn>
|
||||
</v-col>
|
||||
</v-row>
|
||||
</v-card-text>
|
||||
</v-card>
|
||||
</template>
|
||||
|
||||
<script lang="ts">
|
||||
import Component from 'vue-class-component'
|
||||
import { Mixins } from 'vue-property-decorator'
|
||||
import DashboardMixin from '@/components/mixins/dashboard'
|
||||
import draggable from 'vuedraggable'
|
||||
import { convertPanelnameToIcon } from '@/plugins/helpers'
|
||||
import { mdiDragVertical, mdiCheckboxBlankOutline, mdiCheckboxMarked, mdiInformation, mdiLock } from '@mdi/js'
|
||||
@Component({
|
||||
components: {
|
||||
draggable,
|
||||
},
|
||||
})
|
||||
export default class SettingsDashboardTabMobile extends Mixins(DashboardMixin) {
|
||||
/**
|
||||
* Icons
|
||||
*/
|
||||
mdiLock = mdiLock
|
||||
mdiInformation = mdiInformation
|
||||
mdiDragVertical = mdiDragVertical
|
||||
mdiCheckboxMarked = mdiCheckboxMarked
|
||||
mdiCheckboxBlankOutline = mdiCheckboxBlankOutline
|
||||
|
||||
convertPanelnameToIcon = convertPanelnameToIcon
|
||||
|
||||
get mobileLayout() {
|
||||
let panels = this.$store.getters['gui/getPanels']('mobileLayout')
|
||||
panels = panels.concat(this.missingPanelsMobile)
|
||||
panels = panels.filter((element: any) => this.allPossiblePanels.includes(element.name))
|
||||
|
||||
return panels
|
||||
}
|
||||
|
||||
set mobileLayout(newVal) {
|
||||
newVal = newVal.filter((element: any) => element !== undefined)
|
||||
|
||||
this.$store.dispatch('gui/saveSetting', { name: 'dashboard.mobileLayout', value: newVal })
|
||||
}
|
||||
|
||||
changeState(name: string, newVal: boolean) {
|
||||
const index = this.mobileLayout.findIndex((element: any) => element.name === name)
|
||||
if (index !== -1) {
|
||||
this.mobileLayout[index].visible = newVal
|
||||
this.$store.dispatch('gui/saveSetting', { name: 'dashboard.mobileLayout', value: this.mobileLayout })
|
||||
}
|
||||
}
|
||||
|
||||
resetLayout() {
|
||||
this.$store.dispatch('gui/resetLayout', 'mobileLayout')
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
.ghost {
|
||||
opacity: 0.5;
|
||||
background: #c8ebfb;
|
||||
}
|
||||
|
||||
.handle {
|
||||
cursor: move;
|
||||
}
|
||||
</style>
|
||||
@@ -1,191 +0,0 @@
|
||||
<template>
|
||||
<v-card flat>
|
||||
<v-card-text>
|
||||
<v-row>
|
||||
<v-col class="col-12 col-md-6">
|
||||
<v-card class="mx-auto" max-width="300" tile>
|
||||
<v-list dense>
|
||||
<v-list-item>
|
||||
<v-row>
|
||||
<v-col class="col-auto pr-0 pl-8">
|
||||
<v-icon>{{ mdiInformation }}</v-icon>
|
||||
</v-col>
|
||||
<v-col class="pr-0 text-truncate">
|
||||
{{ $t('Panels.StatusPanel.Headline') }}
|
||||
</v-col>
|
||||
<v-col class="col-auto pl-0">
|
||||
<v-icon color="grey lighten-1">{{ mdiLock }}</v-icon>
|
||||
</v-col>
|
||||
</v-row>
|
||||
</v-list-item>
|
||||
<draggable
|
||||
v-model="tabletLayout1"
|
||||
handle=".handle"
|
||||
class="v-list-item-group"
|
||||
ghost-class="ghost"
|
||||
group="tabletViewport">
|
||||
<template v-for="element in tabletLayout1">
|
||||
<v-list-item :key="'item-tablet-' + element.name">
|
||||
<v-row class="d-flex align-center">
|
||||
<v-col class="col-auto px-0">
|
||||
<v-icon class="handle pr-2">{{ mdiDragVertical }}</v-icon>
|
||||
<v-icon v-text="convertPanelnameToIcon(element.name)"></v-icon>
|
||||
</v-col>
|
||||
<v-col class="pr-0 text-truncate">
|
||||
{{ getPanelName(element.name) }}
|
||||
</v-col>
|
||||
<v-col class="col-auto pl-2">
|
||||
<v-icon
|
||||
v-if="!element.visible"
|
||||
color="grey lighten-1"
|
||||
@click.stop="changeState1(element.name, true)">
|
||||
{{ mdiCheckboxBlankOutline }}
|
||||
</v-icon>
|
||||
<v-icon
|
||||
v-else
|
||||
color="primary"
|
||||
@click.stop="changeState1(element.name, false)">
|
||||
{{ mdiCheckboxMarked }}
|
||||
</v-icon>
|
||||
</v-col>
|
||||
</v-row>
|
||||
</v-list-item>
|
||||
</template>
|
||||
</draggable>
|
||||
</v-list>
|
||||
</v-card>
|
||||
</v-col>
|
||||
<v-col class="col-12 col-md-6">
|
||||
<v-card class="mx-auto" max-width="300" tile>
|
||||
<v-list dense>
|
||||
<draggable
|
||||
v-model="tabletLayout2"
|
||||
handle=".handle"
|
||||
class="v-list-item-group"
|
||||
ghost-class="ghost"
|
||||
group="tabletViewport">
|
||||
<template v-for="element in tabletLayout2">
|
||||
<v-list-item :key="'item-tablet-' + element.name">
|
||||
<v-row class="d-flex align-center">
|
||||
<v-col class="col-auto px-0">
|
||||
<v-icon class="handle pr-2">{{ mdiDragVertical }}</v-icon>
|
||||
<v-icon v-text="convertPanelnameToIcon(element.name)"></v-icon>
|
||||
</v-col>
|
||||
<v-col class="pr-0 text-truncate">
|
||||
{{ getPanelName(element.name) }}
|
||||
</v-col>
|
||||
<v-col class="col-auto pl-2">
|
||||
<v-icon
|
||||
v-if="!element.visible"
|
||||
color="grey lighten-1"
|
||||
@click.stop="changeState2(element.name, true)">
|
||||
{{ mdiCheckboxBlankOutline }}
|
||||
</v-icon>
|
||||
<v-icon
|
||||
v-else
|
||||
color="primary"
|
||||
@click.stop="changeState2(element.name, false)">
|
||||
{{ mdiCheckboxMarked }}
|
||||
</v-icon>
|
||||
</v-col>
|
||||
</v-row>
|
||||
</v-list-item>
|
||||
</template>
|
||||
</draggable>
|
||||
</v-list>
|
||||
</v-card>
|
||||
</v-col>
|
||||
</v-row>
|
||||
<v-row>
|
||||
<v-col class="text-center">
|
||||
<v-btn color="error" @click="resetLayout">{{ $t('Settings.DashboardTab.ResetLayout') }}</v-btn>
|
||||
</v-col>
|
||||
</v-row>
|
||||
</v-card-text>
|
||||
</v-card>
|
||||
</template>
|
||||
|
||||
<script lang="ts">
|
||||
import Component from 'vue-class-component'
|
||||
import { Mixins } from 'vue-property-decorator'
|
||||
import DashboardMixin from '@/components/mixins/dashboard'
|
||||
import draggable from 'vuedraggable'
|
||||
import { convertPanelnameToIcon } from '@/plugins/helpers'
|
||||
import { mdiLock, mdiInformation, mdiDragVertical, mdiCheckboxMarked, mdiCheckboxBlankOutline } from '@mdi/js'
|
||||
@Component({
|
||||
components: {
|
||||
draggable,
|
||||
},
|
||||
})
|
||||
export default class SettingsDashboardTabTablet extends Mixins(DashboardMixin) {
|
||||
/**
|
||||
* Icons
|
||||
*/
|
||||
mdiLock = mdiLock
|
||||
mdiInformation = mdiInformation
|
||||
mdiDragVertical = mdiDragVertical
|
||||
mdiCheckboxMarked = mdiCheckboxMarked
|
||||
mdiCheckboxBlankOutline = mdiCheckboxBlankOutline
|
||||
|
||||
convertPanelnameToIcon = convertPanelnameToIcon
|
||||
|
||||
get tabletLayout1() {
|
||||
let panels = this.$store.getters['gui/getPanels']('tabletLayout1')
|
||||
panels = panels.concat(this.missingPanelsTablet)
|
||||
panels = panels.filter((element: any) => this.allPossiblePanels.includes(element.name))
|
||||
|
||||
return panels
|
||||
}
|
||||
|
||||
set tabletLayout1(newVal) {
|
||||
newVal = newVal.filter((element: any) => element !== undefined)
|
||||
|
||||
this.$store.dispatch('gui/saveSetting', { name: 'dashboard.tabletLayout1', value: newVal })
|
||||
}
|
||||
|
||||
get tabletLayout2() {
|
||||
let panels = this.$store.getters['gui/getPanels']('tabletLayout2')
|
||||
panels = panels.filter((element: any) => this.allPossiblePanels.includes(element.name))
|
||||
|
||||
return panels
|
||||
}
|
||||
|
||||
set tabletLayout2(newVal) {
|
||||
newVal = newVal.filter((element: any) => element !== undefined)
|
||||
|
||||
this.$store.dispatch('gui/saveSetting', { name: 'dashboard.tabletLayout2', value: newVal })
|
||||
}
|
||||
|
||||
changeState1(name: string, newVal: boolean) {
|
||||
const index = this.tabletLayout1.findIndex((element: any) => element.name === name)
|
||||
if (index !== -1) {
|
||||
this.tabletLayout1[index].visible = newVal
|
||||
this.$store.dispatch('gui/saveSetting', { name: 'dashboard.tabletLayout1', value: this.tabletLayout1 })
|
||||
}
|
||||
}
|
||||
|
||||
changeState2(name: string, newVal: boolean) {
|
||||
const index = this.tabletLayout2.findIndex((element: any) => element.name === name)
|
||||
if (index !== -1) {
|
||||
this.tabletLayout2[index].visible = newVal
|
||||
this.$store.dispatch('gui/saveSetting', { name: 'dashboard.tabletLayout2', value: this.tabletLayout2 })
|
||||
}
|
||||
}
|
||||
|
||||
resetLayout() {
|
||||
this.$store.dispatch('gui/resetLayout', 'tabletLayout1')
|
||||
this.$store.dispatch('gui/resetLayout', 'tabletLayout2')
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
.ghost {
|
||||
opacity: 0.5;
|
||||
background: #c8ebfb;
|
||||
}
|
||||
|
||||
.handle {
|
||||
cursor: move;
|
||||
}
|
||||
</style>
|
||||
@@ -1,262 +0,0 @@
|
||||
<template>
|
||||
<v-card flat>
|
||||
<v-card-text>
|
||||
<v-row>
|
||||
<v-col class="col-12 col-md-4">
|
||||
<v-card class="mx-auto" max-width="300" tile>
|
||||
<v-list dense>
|
||||
<v-list-item>
|
||||
<v-row>
|
||||
<v-col class="col-auto pr-0 pl-8">
|
||||
<v-icon>{{ mdiInformation }}</v-icon>
|
||||
</v-col>
|
||||
<v-col class="pr-0 text-truncate">
|
||||
{{ $t('Panels.StatusPanel.Headline') }}
|
||||
</v-col>
|
||||
<v-col class="col-auto pl-0">
|
||||
<v-icon color="grey lighten-1">{{ mdiLock }}</v-icon>
|
||||
</v-col>
|
||||
</v-row>
|
||||
</v-list-item>
|
||||
<draggable
|
||||
v-model="widescreenLayout1"
|
||||
handle=".handle"
|
||||
class="v-list-item-group"
|
||||
ghost-class="ghost"
|
||||
group="widescreenViewport">
|
||||
<template v-for="element in widescreenLayout1">
|
||||
<v-list-item :key="'item-widescreen-' + element.name">
|
||||
<v-row>
|
||||
<v-col class="col-auto px-0">
|
||||
<v-icon class="handle pr-2">{{ mdiDragVertical }}</v-icon>
|
||||
<v-icon v-text="convertPanelnameToIcon(element.name)"></v-icon>
|
||||
</v-col>
|
||||
<v-col class="pr-0 text-truncate">
|
||||
{{ getPanelName(element.name) }}
|
||||
</v-col>
|
||||
<v-col class="col-auto pl-2">
|
||||
<v-icon
|
||||
v-if="!element.visible"
|
||||
color="grey lighten-1"
|
||||
@click.stop="changeState1(element.name, true)">
|
||||
{{ mdiCheckboxBlankOutline }}
|
||||
</v-icon>
|
||||
<v-icon
|
||||
v-else
|
||||
color="primary"
|
||||
@click.stop="changeState1(element.name, false)">
|
||||
{{ mdiCheckboxMarked }}
|
||||
</v-icon>
|
||||
</v-col>
|
||||
</v-row>
|
||||
</v-list-item>
|
||||
</template>
|
||||
</draggable>
|
||||
</v-list>
|
||||
</v-card>
|
||||
</v-col>
|
||||
<v-col class="col-12 col-md-4">
|
||||
<v-card class="mx-auto" max-width="300" tile>
|
||||
<v-list dense>
|
||||
<draggable
|
||||
v-model="widescreenLayout2"
|
||||
handle=".handle"
|
||||
class="v-list-item-group"
|
||||
ghost-class="ghost"
|
||||
group="widescreenViewport">
|
||||
<template v-for="element in widescreenLayout2">
|
||||
<v-list-item :key="'item-widescreen-' + element.name">
|
||||
<v-row>
|
||||
<v-col class="col-auto px-0">
|
||||
<v-icon class="handle pr-2">{{ mdiDragVertical }}</v-icon>
|
||||
<v-icon v-text="convertPanelnameToIcon(element.name)"></v-icon>
|
||||
</v-col>
|
||||
<v-col class="pr-0 text-truncate">
|
||||
{{ getPanelName(element.name) }}
|
||||
</v-col>
|
||||
<v-col class="col-auto pl-2">
|
||||
<v-icon
|
||||
v-if="!element.visible"
|
||||
color="grey lighten-1"
|
||||
@click.stop="changeState2(element.name, true)">
|
||||
{{ mdiCheckboxBlankOutline }}
|
||||
</v-icon>
|
||||
<v-icon
|
||||
v-else
|
||||
color="primary"
|
||||
@click.stop="changeState2(element.name, false)">
|
||||
{{ mdiCheckboxMarked }}
|
||||
</v-icon>
|
||||
</v-col>
|
||||
</v-row>
|
||||
</v-list-item>
|
||||
</template>
|
||||
</draggable>
|
||||
</v-list>
|
||||
</v-card>
|
||||
</v-col>
|
||||
<v-col class="col-12 col-md-4">
|
||||
<v-card class="mx-auto" max-width="300" tile>
|
||||
<v-list dense>
|
||||
<draggable
|
||||
v-model="widescreenLayout3"
|
||||
handle=".handle"
|
||||
class="v-list-item-group"
|
||||
ghost-class="ghost"
|
||||
group="widescreenViewport">
|
||||
<template v-for="element in widescreenLayout3">
|
||||
<v-list-item :key="'item-widescreen-' + element.name">
|
||||
<v-row class="d-flex align-center">
|
||||
<v-col class="col-auto px-0">
|
||||
<v-icon class="handle pr-2">{{ mdiDragVertical }}</v-icon>
|
||||
<v-icon v-text="convertPanelnameToIcon(element.name)"></v-icon>
|
||||
</v-col>
|
||||
<v-col class="pr-0 text-truncate">
|
||||
{{ getPanelName(element.name) }}
|
||||
</v-col>
|
||||
<v-col class="col-auto pl-2">
|
||||
<v-icon
|
||||
v-if="!element.visible"
|
||||
color="grey lighten-1"
|
||||
@click.stop="changeState3(element.name, true)">
|
||||
{{ mdiCheckboxBlankOutline }}
|
||||
</v-icon>
|
||||
<v-icon
|
||||
v-else
|
||||
color="primary"
|
||||
@click.stop="changeState3(element.name, false)">
|
||||
{{ mdiCheckboxMarked }}
|
||||
</v-icon>
|
||||
</v-col>
|
||||
</v-row>
|
||||
</v-list-item>
|
||||
</template>
|
||||
</draggable>
|
||||
</v-list>
|
||||
</v-card>
|
||||
</v-col>
|
||||
</v-row>
|
||||
<v-row>
|
||||
<v-col class="text-center">
|
||||
<v-btn color="error" @click="resetLayout">{{ $t('Settings.DashboardTab.ResetLayout') }}</v-btn>
|
||||
</v-col>
|
||||
</v-row>
|
||||
</v-card-text>
|
||||
</v-card>
|
||||
</template>
|
||||
|
||||
<script lang="ts">
|
||||
import Component from 'vue-class-component'
|
||||
import { Mixins } from 'vue-property-decorator'
|
||||
import draggable from 'vuedraggable'
|
||||
import { convertPanelnameToIcon } from '@/plugins/helpers'
|
||||
import DashboardMixin from '@/components/mixins/dashboard'
|
||||
import { mdiDragVertical, mdiCheckboxBlankOutline, mdiCheckboxMarked, mdiInformation, mdiLock } from '@mdi/js'
|
||||
@Component({
|
||||
components: {
|
||||
draggable,
|
||||
},
|
||||
})
|
||||
export default class SettingsDashboardTabWidescreen extends Mixins(DashboardMixin) {
|
||||
/**
|
||||
* Icons
|
||||
*/
|
||||
mdiLock = mdiLock
|
||||
mdiInformation = mdiInformation
|
||||
mdiDragVertical = mdiDragVertical
|
||||
mdiCheckboxMarked = mdiCheckboxMarked
|
||||
mdiCheckboxBlankOutline = mdiCheckboxBlankOutline
|
||||
|
||||
convertPanelnameToIcon = convertPanelnameToIcon
|
||||
|
||||
get widescreenLayout1() {
|
||||
let panels = this.$store.getters['gui/getPanels']('widescreenLayout1')
|
||||
panels = panels.concat(this.missingPanelsWidescreen)
|
||||
panels = panels.filter((element: any) => this.allPossiblePanels.includes(element.name))
|
||||
|
||||
return panels
|
||||
}
|
||||
|
||||
set widescreenLayout1(newVal) {
|
||||
newVal = newVal.filter((element: any) => element !== undefined)
|
||||
|
||||
this.$store.dispatch('gui/saveSetting', { name: 'dashboard.widescreenLayout1', value: newVal })
|
||||
}
|
||||
|
||||
get widescreenLayout2() {
|
||||
let panels = this.$store.getters['gui/getPanels']('widescreenLayout2')
|
||||
panels = panels.filter((element: any) => this.allPossiblePanels.includes(element.name))
|
||||
|
||||
return panels
|
||||
}
|
||||
|
||||
set widescreenLayout2(newVal) {
|
||||
newVal = newVal.filter((element: any) => element !== undefined)
|
||||
|
||||
this.$store.dispatch('gui/saveSetting', { name: 'dashboard.widescreenLayout2', value: newVal })
|
||||
}
|
||||
|
||||
get widescreenLayout3() {
|
||||
let panels = this.$store.getters['gui/getPanels']('widescreenLayout3')
|
||||
panels = panels.filter((element: any) => this.allPossiblePanels.includes(element.name))
|
||||
|
||||
return panels
|
||||
}
|
||||
|
||||
set widescreenLayout3(newVal) {
|
||||
newVal = newVal.filter((element: any) => element !== undefined)
|
||||
|
||||
this.$store.dispatch('gui/saveSetting', { name: 'dashboard.widescreenLayout3', value: newVal })
|
||||
}
|
||||
|
||||
changeState1(name: string, newVal: boolean) {
|
||||
const index = this.widescreenLayout1.findIndex((element: any) => element.name === name)
|
||||
if (index !== -1) {
|
||||
this.widescreenLayout1[index].visible = newVal
|
||||
this.$store.dispatch('gui/saveSetting', {
|
||||
name: 'dashboard.widescreenLayout1',
|
||||
value: this.widescreenLayout1,
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
changeState2(name: string, newVal: boolean) {
|
||||
const index = this.widescreenLayout2.findIndex((element: any) => element.name === name)
|
||||
if (index !== -1) {
|
||||
this.widescreenLayout2[index].visible = newVal
|
||||
this.$store.dispatch('gui/saveSetting', {
|
||||
name: 'dashboard.widescreenLayout2',
|
||||
value: this.widescreenLayout2,
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
changeState3(name: string, newVal: boolean) {
|
||||
const index = this.widescreenLayout3.findIndex((element: any) => element.name === name)
|
||||
if (index !== -1) {
|
||||
this.widescreenLayout3[index].visible = newVal
|
||||
this.$store.dispatch('gui/saveSetting', {
|
||||
name: 'dashboard.widescreenLayout3',
|
||||
value: this.widescreenLayout3,
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
resetLayout() {
|
||||
this.$store.dispatch('gui/resetLayout', 'widescreenLayout1')
|
||||
this.$store.dispatch('gui/resetLayout', 'widescreenLayout2')
|
||||
this.$store.dispatch('gui/resetLayout', 'widescreenLayout3')
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
.ghost {
|
||||
opacity: 0.5;
|
||||
background: #c8ebfb;
|
||||
}
|
||||
|
||||
.handle {
|
||||
cursor: move;
|
||||
}
|
||||
</style>
|
||||
@@ -63,8 +63,6 @@ export default class Mjpegstreamer extends Mixins(BaseMixin) {
|
||||
get url() {
|
||||
const baseUrl = this.camSettings.urlStream
|
||||
let url = new URL(baseUrl, this.printerUrl === undefined ? this.hostUrl.toString() : this.printerUrl)
|
||||
url.port = this.hostPort.toString()
|
||||
|
||||
if (baseUrl.startsWith('http') || baseUrl.startsWith('://')) url = new URL(baseUrl)
|
||||
|
||||
return decodeURIComponent(url.toString())
|
||||
|
||||
@@ -99,8 +99,6 @@ export default class MjpegstreamerAdaptive extends Mixins(BaseMixin) {
|
||||
const baseUrl = this.camSettings.urlSnapshot
|
||||
|
||||
let url = new URL(baseUrl, this.printerUrl === undefined ? this.hostUrl.toString() : this.printerUrl)
|
||||
url.port = this.hostPort.toString()
|
||||
|
||||
if (baseUrl.startsWith('http') || baseUrl.startsWith('://')) url = new URL(baseUrl)
|
||||
|
||||
url.searchParams.append('bypassCache', this.refresh.toString())
|
||||
|
||||
@@ -27,7 +27,7 @@ export default class Uv4lMjpeg extends Mixins(BaseMixin) {
|
||||
private isVisibleDocument = true
|
||||
|
||||
@Prop({ required: true }) declare readonly camSettings: GuiWebcamStateWebcam
|
||||
@Prop({ default: null }) declare readonly printerUrl: string | null
|
||||
@Prop() declare printerUrl: string | undefined
|
||||
|
||||
declare $refs: {
|
||||
webcamUv4lMjpegImage: HTMLImageElement
|
||||
@@ -36,8 +36,6 @@ export default class Uv4lMjpeg extends Mixins(BaseMixin) {
|
||||
get url() {
|
||||
const baseUrl = this.camSettings.urlStream
|
||||
let url = new URL(baseUrl, this.printerUrl === undefined ? this.hostUrl.toString() : this.printerUrl)
|
||||
url.port = this.hostPort.toString()
|
||||
|
||||
if (baseUrl.startsWith('http') || baseUrl.startsWith('://')) url = new URL(baseUrl)
|
||||
|
||||
return decodeURIComponent(url.toString())
|
||||
|
||||
+64
-4
@@ -107,6 +107,17 @@
|
||||
"UpdatingDone": "Opdatering af {software} udført!"
|
||||
}
|
||||
},
|
||||
"BedScrews": {
|
||||
"Abort": "Afbryd",
|
||||
"Accept": "Acceptér",
|
||||
"Adjusted": "Justeret",
|
||||
"Description": "Klik på <b>Justeret</b> hvis skruen blev justeret. Klik på <b>Acceptér</b> for at fortsætte uden justering.",
|
||||
"Headline": "Bed skruer",
|
||||
"ScrewAccepted": "Skrue accepteret",
|
||||
"ScrewIndex": "Skrue Index",
|
||||
"ScrewName": "Skrue Navn",
|
||||
"ScrewOutput": "{current} af {max}"
|
||||
},
|
||||
"ConnectionDialog": {
|
||||
"CannotConnectTo": "Kan ikke forbinde med Moonraker ({host}).",
|
||||
"CheckMoonrakerLog": "Hvis denne besked vises flere gange, kig da i logfilen her:",
|
||||
@@ -179,7 +190,10 @@
|
||||
"Free": "Ledig",
|
||||
"FreeDisk": "Ledig plads",
|
||||
"GCodeFiles": "G-Code Filer",
|
||||
"GcodesRootDirectoryDoesntExists": "Ingen mappe med g-koder fundet. Tjek at opsætning af \"path\" under [virtual_sdcard] sektionen i printer.cfg er korrekt.",
|
||||
"HiddenFiles": "Skjulte filer",
|
||||
"InvalidNameAlreadyExists": "Navnet eksisterer allerede, vælg venligst et andet navn.",
|
||||
"InvalidNameEmpty": "Feltet må ikke være tomt!",
|
||||
"LastEndTime": "Sidste slut tid",
|
||||
"LastFilamentUsed": "Sidste filament forbrug",
|
||||
"LastModified": "Sidst ændret",
|
||||
@@ -252,8 +266,8 @@
|
||||
"Max": "Maks",
|
||||
"Min": "Min",
|
||||
"Name": "Navn",
|
||||
"Size": "Størrelse",
|
||||
"Variance": "Variation"
|
||||
"Range": "Variation",
|
||||
"Size": "Størrelse"
|
||||
},
|
||||
"DeleteBedMeshProfile": "Slet Bed Mesh profil",
|
||||
"DoYouReallyWantToDelete": "Vil du slette \"{name}\"?",
|
||||
@@ -337,6 +351,7 @@
|
||||
"in_progress": "Igangværende",
|
||||
"klippy_disconnect": "Klippy afbrudt",
|
||||
"klippy_shutdown": "Klippy lukket ned",
|
||||
"Others": "Andre",
|
||||
"server_exit": "Server exit"
|
||||
},
|
||||
"TitleExportHistory": "Export History",
|
||||
@@ -362,6 +377,7 @@
|
||||
"AllFiles": "Alle",
|
||||
"Cancel": "Annuller",
|
||||
"ConfigFiles": "Konfigurationsfiler",
|
||||
"ConfigRootDirectoryDoesntExists": "Ingen konfiguration fundet. Tjek venligst opsætningen af \"config_path\" under [file_manager] sektionen af Moonraker konfigurationen.",
|
||||
"Create": "Ny",
|
||||
"CreateDirectory": "Ny mappe",
|
||||
"CreateFile": "Ny Fil",
|
||||
@@ -452,6 +468,12 @@
|
||||
"UpToDate": "up-to-date"
|
||||
}
|
||||
},
|
||||
"ManualProbe": {
|
||||
"Abort": "Afbryd",
|
||||
"Accept": "Acceptér",
|
||||
"Advanced": "Avanceret",
|
||||
"Headline": "Manuel Probing"
|
||||
},
|
||||
"Panels": {
|
||||
"ExtruderControlPanel": {
|
||||
"Allowed": "Tilladt",
|
||||
@@ -488,7 +510,8 @@
|
||||
"FirmwareRestart": "Genstart alt",
|
||||
"KlipperCheck": "Check at Klipper service kører og at en UDS (Unix Domain Socket) er konfigureret.",
|
||||
"MoonrakerCannotConnect": "Moonraker kan ikke forbinde til Klipper!",
|
||||
"Restart": "Genstart"
|
||||
"Restart": "Genstart",
|
||||
"ServiceReports": "{service} rapporter"
|
||||
},
|
||||
"MachineSettingsPanel": {
|
||||
"Headline": "Printer indstillinger",
|
||||
@@ -518,6 +541,12 @@
|
||||
},
|
||||
"MiscellaneousPanel": {
|
||||
"Headline": "Diverse",
|
||||
"Light": {
|
||||
"Blue": "blå",
|
||||
"Green": "grøn",
|
||||
"Red": "rød",
|
||||
"White": "hvid"
|
||||
},
|
||||
"RunoutSensor": {
|
||||
"Detected": "Fundet",
|
||||
"Disabled": "Deaktiveret",
|
||||
@@ -748,6 +777,8 @@
|
||||
"ShowAxes": "Vis akser"
|
||||
},
|
||||
"GeneralTab": {
|
||||
"12hours": "12-timers ({time})",
|
||||
"24hours": "24-timers ({time})",
|
||||
"Backup": "Backup",
|
||||
"BackupDialog": "Vælg de sektioner du ønsker at lave backup af:",
|
||||
"CalcEstimateTime": "Beregn estimeret printtid",
|
||||
@@ -763,6 +794,7 @@
|
||||
"Slicer": "Slicer (M73)"
|
||||
},
|
||||
"CannotReadJson": "Kan ikke læse backup-fil",
|
||||
"DateFormat": "Datoformat",
|
||||
"DbConsoleHistory": "Terminal Historik",
|
||||
"DbHistoryJobs": "Jobhistorik",
|
||||
"DbHistoryTotals": "Totalhistorik",
|
||||
@@ -782,7 +814,8 @@
|
||||
"PrinterName": "Printernavn",
|
||||
"Reset": "Nulstil",
|
||||
"Restore": "Gendan",
|
||||
"RestoreDialog": "Vælg de sektioner du ønsker at gendanne fra backup:"
|
||||
"RestoreDialog": "Vælg de sektioner du ønsker at gendanne fra backup:",
|
||||
"TimeFormat": "Tidsformat"
|
||||
},
|
||||
"InterfaceSettings": "Interfaceindstillinger",
|
||||
"MacrosTab": {
|
||||
@@ -821,6 +854,29 @@
|
||||
"UnknownGroup": "Ukendt gruppe",
|
||||
"Warning": "Advarsel"
|
||||
},
|
||||
"MiscellaneousTab": {
|
||||
"AddGroup": "Tilføj gruppe",
|
||||
"AddPreset": "Tilføj forudindstilling",
|
||||
"Color": "Farve",
|
||||
"CreateGroup": "Tilføj gruppe",
|
||||
"CreatePreset": "Tilføj forudindstilling",
|
||||
"End": "Slut",
|
||||
"EndDescription": "Sidste LED i denne gruppe.",
|
||||
"Groups": "Grupper",
|
||||
"GroupSubTitle": "Start: {start}, Slut: {end}",
|
||||
"LightGroups": "{name} - Grupper",
|
||||
"LightPresets": "{name} - Forudindstillinger",
|
||||
"Miscellaneous": "Diverse",
|
||||
"Name": "Navn",
|
||||
"NoDevicesFound": "Ingen enheder fundet",
|
||||
"NoGroupFound": "Ingen gruppe fundet",
|
||||
"NoPresetFound": "Ingen forudindstilling fundet",
|
||||
"Presets": "Forudindstillinger",
|
||||
"Start": "Første",
|
||||
"StartDescription": "Første LED i denne gruppe.",
|
||||
"UnableToLoadLight": "Kunne ikke indlæse LED",
|
||||
"UnableToLoadPreset": "Kunne ikke indlæse forudindstilling"
|
||||
},
|
||||
"PresetsTab": {
|
||||
"AddPreset": "Tilføj forudindstilling",
|
||||
"Cooldown": "Nedkøling",
|
||||
@@ -848,6 +904,7 @@
|
||||
"UpdatePrinter": "Opdater printer",
|
||||
"UseConfigJson": "InstanceDB = JSON fundet. Brug venligst config.json til at ændre på printerlisten."
|
||||
},
|
||||
"Store": "Gem",
|
||||
"TimelapseTab": {
|
||||
"Autorender": "Autorendering",
|
||||
"AutorenderDescription": "Hvis aktiv, vil Timelapse video automatisk blive renderet efter afsluttet print.",
|
||||
@@ -942,9 +999,11 @@
|
||||
"ShowWebcamInNavigation": "Vis Webcam i navigation",
|
||||
"UiSettings": "UI-indstillinger"
|
||||
},
|
||||
"Update": "Opdater",
|
||||
"WebcamsTab": {
|
||||
"AddWebcam": "Tilføj webcam",
|
||||
"CreateWebcam": "Nyt Webcam",
|
||||
"EditCrowsnestConf": "Redigér crowsnest.conf",
|
||||
"EditWebcam": "Rediger Webcam",
|
||||
"FlipWebcam": "Vend webcam-billedet:",
|
||||
"Horizontally": "horisontalt",
|
||||
@@ -984,6 +1043,7 @@
|
||||
"Delete": "Slet",
|
||||
"DeleteDirectory": "Slet mappe",
|
||||
"DeleteDirectoryQuestion": "Vil du slette mappen \"{name}\" og alt dens indhold?",
|
||||
"DeleteSelectedQuestion": "Er du sikker på du vil slette alle {count} valgte filer?",
|
||||
"Download": "Download",
|
||||
"DuplicateLastframe": "Dupliker sidste frame",
|
||||
"Empty": "Ingen færdige Timelapse filer fundet.",
|
||||
|
||||
+3
-3
@@ -109,8 +109,8 @@
|
||||
},
|
||||
"BedScrews": {
|
||||
"Abort": "abbrechen",
|
||||
"Adjusted": "angepasst",
|
||||
"Accept": "bestätigen",
|
||||
"Adjusted": "angepasst",
|
||||
"Description": "Klick auf <b>ANGEPASST</b> wenn die aktuelle Schraube eingestellt wurde. Klick auf <b>BESTÄTIGEN</b> um fortzufahren ohne Anpassung.",
|
||||
"Headline": "Bettschrauben",
|
||||
"ScrewAccepted": "bestätigte Schrauben",
|
||||
@@ -266,8 +266,8 @@
|
||||
"Max": "Max",
|
||||
"Min": "Min",
|
||||
"Name": "Name",
|
||||
"Size": "Größe",
|
||||
"Variance": "Varianz"
|
||||
"Range": "Spannweite",
|
||||
"Size": "Größe"
|
||||
},
|
||||
"DeleteBedMeshProfile": "Lösche Bed Mesh",
|
||||
"DoYouReallyWantToDelete": "Möchtest du das Profil \"{name}\" wirklich löschen?",
|
||||
|
||||
+3
-3
@@ -109,8 +109,8 @@
|
||||
},
|
||||
"BedScrews": {
|
||||
"Abort": "abort",
|
||||
"Adjusted": "adjusted",
|
||||
"Accept": "accept",
|
||||
"Adjusted": "adjusted",
|
||||
"Description": "Click on <b>ADJUSTED</b> if the current screw was adjusted. Click on <b>ACCEPT</b> to continue without adjustment.",
|
||||
"Headline": "Bed Screws",
|
||||
"ScrewAccepted": "Screws accepted",
|
||||
@@ -266,8 +266,8 @@
|
||||
"Max": "Max",
|
||||
"Min": "Min",
|
||||
"Name": "Name",
|
||||
"Size": "Size",
|
||||
"Variance": "Variance"
|
||||
"Range": "Range",
|
||||
"Size": "Size"
|
||||
},
|
||||
"DeleteBedMeshProfile": "Delete Bed Mesh Profile",
|
||||
"DoYouReallyWantToDelete": "Do you really want to delete the profile \"{name}\"?",
|
||||
|
||||
+1
-1
@@ -109,8 +109,8 @@
|
||||
},
|
||||
"BedScrews": {
|
||||
"Abort": "中止",
|
||||
"Adjusted": "調整済み",
|
||||
"Accept": "確認",
|
||||
"Adjusted": "調整済み",
|
||||
"Description": "現在のスクリューの調整が済んだら<b>調整済み</b>をクリックしてください。<b>確認</b>をクリックすると調整せずに先に進みます。",
|
||||
"Headline": "ベッドスクリュー",
|
||||
"ScrewAccepted": "スクリュー確認済み",
|
||||
|
||||
+59
-4
@@ -107,6 +107,17 @@
|
||||
"UpdatingDone": "Updaten van {software} voltooid!"
|
||||
}
|
||||
},
|
||||
"BedScrews": {
|
||||
"Abort": "annuleer",
|
||||
"Accept": "accepteer",
|
||||
"Adjusted": "aangepast",
|
||||
"Description": "Klik op <b>AANGEPAST</b> indien de huidige schroef aagepast is. Klik op <b>ACCEPTEER</b> om door te gaan zonder aanpassing.",
|
||||
"Headline": "Bed Schroeven",
|
||||
"ScrewAccepted": "Schroeven geaccepteerd",
|
||||
"ScrewIndex": "Schroef Index",
|
||||
"ScrewName": "Schroef Naam",
|
||||
"ScrewOutput": "{current} van {max}"
|
||||
},
|
||||
"ConnectionDialog": {
|
||||
"CannotConnectTo": "Kan niet verbinden met Moonraker ({host}).",
|
||||
"CheckMoonrakerLog": "Als deze melding vaker getoond wordt, kijk in de logs op:",
|
||||
@@ -181,6 +192,8 @@
|
||||
"GCodeFiles": "G-Code Bestanden",
|
||||
"GcodesRootDirectoryDoesntExists": "Geen G-Code directory gevonden. Controleer de optie \"path\" in de [virtual_sdcard] sectie van de Klipper configuratie.",
|
||||
"HiddenFiles": "Verborgen bestanden",
|
||||
"InvalidNameAlreadyExists": "Naam bestaat al, kies een andere naam.",
|
||||
"InvalidNameEmpty": "Naam mag niet leeg zijn!",
|
||||
"LastEndTime": "Laatste eindtijd",
|
||||
"LastFilamentUsed": "Laatst gebruikte filament",
|
||||
"LastModified": "Laatst bewerkt",
|
||||
@@ -253,8 +266,8 @@
|
||||
"Max": "Max",
|
||||
"Min": "Min",
|
||||
"Name": "Naam",
|
||||
"Size": "Grootte",
|
||||
"Variance": "Variatie"
|
||||
"Range": "Bereik",
|
||||
"Size": "Grootte"
|
||||
},
|
||||
"DeleteBedMeshProfile": "Verwijder Bed Mesh Profiel",
|
||||
"DoYouReallyWantToDelete": "Weet je zeker dat je het profiel \"{name}\" wil verwijderen?",
|
||||
@@ -455,6 +468,12 @@
|
||||
"UpToDate": "up-to-date"
|
||||
}
|
||||
},
|
||||
"ManualProbe": {
|
||||
"Abort": "annuleer",
|
||||
"Accept": "accepteer",
|
||||
"Advanced": "Geavanceerd",
|
||||
"Headline": "Handmatige Probe"
|
||||
},
|
||||
"Panels": {
|
||||
"ExtruderControlPanel": {
|
||||
"Allowed": "Toegestaan",
|
||||
@@ -491,7 +510,8 @@
|
||||
"FirmwareRestart": "Firmware Herstart",
|
||||
"KlipperCheck": "Controleer of de Klipper service draait en een UDS (Unix Domain Socket) geconfigureerd is.",
|
||||
"MoonrakerCannotConnect": "Moonraker kan niet met Klipper verbinden!",
|
||||
"Restart": "Herstart"
|
||||
"Restart": "Herstart",
|
||||
"ServiceReports": "{service} rapportages"
|
||||
},
|
||||
"MachineSettingsPanel": {
|
||||
"Headline": "Machine instellingen",
|
||||
@@ -521,6 +541,12 @@
|
||||
},
|
||||
"MiscellaneousPanel": {
|
||||
"Headline": "Overige",
|
||||
"Light": {
|
||||
"Blue": "blauw",
|
||||
"Green": "groen",
|
||||
"Red": "rood",
|
||||
"White": "wit"
|
||||
},
|
||||
"RunoutSensor": {
|
||||
"Detected": "gedetecteerd",
|
||||
"Disabled": "uitgeschakeld",
|
||||
@@ -751,6 +777,8 @@
|
||||
"ShowAxes": "Toon Assen"
|
||||
},
|
||||
"GeneralTab": {
|
||||
"12hours": "12-uurs ({time})",
|
||||
"24hours": "24-uurs ({time})",
|
||||
"Backup": "Backup",
|
||||
"BackupDialog": "Selecteer alle secties waarvan je een backup wilt maken:",
|
||||
"CalcEstimateTime": "Bereken geschatte tijd",
|
||||
@@ -766,6 +794,7 @@
|
||||
"Slicer": "Slicer (M73)"
|
||||
},
|
||||
"CannotReadJson": "Kan het backup bestand niet lezen/verwerken. ",
|
||||
"DateFormat": "Datumformaat",
|
||||
"DbConsoleHistory": "Console Geschiedenis",
|
||||
"DbHistoryJobs": "Geschiedenis Jobs",
|
||||
"DbHistoryTotals": "Geschiedenis Totalen",
|
||||
@@ -785,7 +814,8 @@
|
||||
"PrinterName": "Printer naam",
|
||||
"Reset": "reset",
|
||||
"Restore": "Herstellen",
|
||||
"RestoreDialog": "Kies alle secties die je wil herstellen:"
|
||||
"RestoreDialog": "Kies alle secties die je wil herstellen:",
|
||||
"TimeFormat": "Tijdformaat"
|
||||
},
|
||||
"InterfaceSettings": "Interface Instellingen",
|
||||
"MacrosTab": {
|
||||
@@ -824,6 +854,29 @@
|
||||
"UnknownGroup": "Onbekende Groep",
|
||||
"Warning": "waarschuwing"
|
||||
},
|
||||
"MiscellaneousTab": {
|
||||
"AddGroup": "voeg groep toe",
|
||||
"AddPreset": "voeg preset toe",
|
||||
"Color": "Kleur",
|
||||
"CreateGroup": "Maak groep aan",
|
||||
"CreatePreset": "Maak preset aan",
|
||||
"End": "Einde",
|
||||
"EndDescription": "Laatste LED van deze groep.",
|
||||
"Groups": "Groepen",
|
||||
"GroupSubTitle": "Start: {start}, Einde: {end}",
|
||||
"LightGroups": "{name} - Groepen",
|
||||
"LightPresets": "{name} - Presets",
|
||||
"Miscellaneous": "Overige",
|
||||
"Name": "Naam",
|
||||
"NoDevicesFound": "Geen apparaten gevonden",
|
||||
"NoGroupFound": "Geen groep gevonden",
|
||||
"NoPresetFound": "Geen presets gevonden",
|
||||
"Presets": "Presets",
|
||||
"Start": "Start",
|
||||
"StartDescription": "Eerste LED van deze groep.",
|
||||
"UnableToLoadLight": "Niet gelukt het licht te laden",
|
||||
"UnableToLoadPreset": "Niet gelukt de preset te laden"
|
||||
},
|
||||
"PresetsTab": {
|
||||
"AddPreset": "voeg preset toe",
|
||||
"Cooldown": "Afkoelen",
|
||||
@@ -851,6 +904,7 @@
|
||||
"UpdatePrinter": "Update Printer",
|
||||
"UseConfigJson": "InstanceDB = JSON gedetecteerd. Gebruik de config.json om de printerlijst aan te passen."
|
||||
},
|
||||
"Store": "opslaan",
|
||||
"TimelapseTab": {
|
||||
"Autorender": "Autorender",
|
||||
"AutorenderDescription": "Wanneer ingeschakeld, zal de timelapse video automatisch renderen aan het eind van de print",
|
||||
@@ -945,6 +999,7 @@
|
||||
"ShowWebcamInNavigation": "Toon Webcam in de navigatie",
|
||||
"UiSettings": "UI Instellingen"
|
||||
},
|
||||
"Update": "updaten",
|
||||
"WebcamsTab": {
|
||||
"AddWebcam": "voeg webcam toe",
|
||||
"CreateWebcam": "Nieuwe Webcam",
|
||||
|
||||
+62
-6
@@ -107,6 +107,17 @@
|
||||
"UpdatingDone": "{software} güncellemesi tamamlandı!"
|
||||
}
|
||||
},
|
||||
"BedScrews": {
|
||||
"Abort": "iptal et",
|
||||
"Accept": "kabul et",
|
||||
"Adjusted": "ayarlanmış",
|
||||
"Description": "Mevcut vida ayarlandıysa <b>ADJUSTED</b> seçeneğine tıklayın. Ayarlama yapmadan devam etmek için <b>ACCEPT</b>'i tıklayın.",
|
||||
"Headline": "Tabla Vidaları",
|
||||
"ScrewAccepted": "Vidalar kabul edildi",
|
||||
"ScrewIndex": "Vida Endeksi",
|
||||
"ScrewName": "Vida İsmi",
|
||||
"ScrewOutput": "{current} / {max}"
|
||||
},
|
||||
"ConnectionDialog": {
|
||||
"CannotConnectTo": "Moonraker'a ({host}) bağlanılamıyor.",
|
||||
"CheckMoonrakerLog": "Bu mesaj tekrar tekrar görünüyorsa, lütfen şu adreste bulunan günlük dosyasına bakın:",
|
||||
@@ -144,7 +155,7 @@
|
||||
"UnsavedChanges": "Kaydedilmemiş Değişiklikler",
|
||||
"UnsavedChangesMessage": "{filename} dosyasında yaptığınız değişiklikleri kaydetmek istiyor musunuz??",
|
||||
"UnsavedChangesSubMessage": "Kaydetmezseniz değişiklikleriniz kaybolacak. Bu mesajı editör ayarlarından devre dışı bırakabilirsiniz.",
|
||||
"Uploading": "Karşya Yükleniyor"
|
||||
"Uploading": "Karşıya Yükleniyor"
|
||||
},
|
||||
"EmergencyStopDialog": {
|
||||
"AreYouSure": "Emin Misiniz?",
|
||||
@@ -181,6 +192,8 @@
|
||||
"GCodeFiles": "G-Kod Dosyaları",
|
||||
"GcodesRootDirectoryDoesntExists": "G-Kod dizini bulunamadı. Lütfen Klipper yapılandırmasının [virtual_sdcard] bölümündeki \"path\" seçeneğini işaretleyin.",
|
||||
"HiddenFiles": "Gizli Dosyalar",
|
||||
"InvalidNameAlreadyExists": "İsim zaten var, lütfen başka bir isim seçin.",
|
||||
"InvalidNameEmpty": "Giriş boş olmamalıdır!",
|
||||
"LastEndTime": "Son Bitiş Zamanı",
|
||||
"LastFilamentUsed": "Son Filament Kullanımı",
|
||||
"LastModified": "Son Düzenleme",
|
||||
@@ -253,8 +266,8 @@
|
||||
"Max": "Max",
|
||||
"Min": "Min",
|
||||
"Name": "İsim",
|
||||
"Size": "Boyut",
|
||||
"Variance": "Varyans"
|
||||
"Range": "Menzil",
|
||||
"Size": "Boyut"
|
||||
},
|
||||
"DeleteBedMeshProfile": "Tabla Örgü Profilini Sil",
|
||||
"DoYouReallyWantToDelete": "\"{name}\" profilini gerçekten silmek istiyor musunuz?",
|
||||
@@ -338,6 +351,7 @@
|
||||
"in_progress": "Devam etmekte",
|
||||
"klippy_disconnect": "Klippy bağlantıyı kes",
|
||||
"klippy_shutdown": "Klippy kapat",
|
||||
"Others": "Diğerleri",
|
||||
"server_exit": "Sunucu çıkışı"
|
||||
},
|
||||
"TitleExportHistory": "İhracat Geçmişi",
|
||||
@@ -454,6 +468,12 @@
|
||||
"UpToDate": "güncel"
|
||||
}
|
||||
},
|
||||
"ManualProbe": {
|
||||
"Abort": "iptal et",
|
||||
"Accept": "kabul et",
|
||||
"Advanced": "Gelişmiş",
|
||||
"Headline": "Manuel Prob"
|
||||
},
|
||||
"Panels": {
|
||||
"ExtruderControlPanel": {
|
||||
"Allowed": "İzin Verilmiş",
|
||||
@@ -490,7 +510,8 @@
|
||||
"FirmwareRestart": "Firmware Yeniden Başlatma",
|
||||
"KlipperCheck": "Lütfen Klipper hizmetinin çalışıp çalışmadığını ve bir UDS'nin (Unix Etki Alanı Soketi) yapılandırılıp yapılandırılmadığını kontrol edin.",
|
||||
"MoonrakerCannotConnect": "Moonraker Klipper'a bağlanamıyor!",
|
||||
"Restart": "Yeniden Başlat"
|
||||
"Restart": "Yeniden Başlat",
|
||||
"ServiceReports": "{service} raporları"
|
||||
},
|
||||
"MachineSettingsPanel": {
|
||||
"Headline": "Makine",
|
||||
@@ -520,6 +541,12 @@
|
||||
},
|
||||
"MiscellaneousPanel": {
|
||||
"Headline": "Çeşitli",
|
||||
"Light": {
|
||||
"Blue": "mavi",
|
||||
"Green": "yeşil",
|
||||
"Red": "kırmızı",
|
||||
"White": "beyaz"
|
||||
},
|
||||
"RunoutSensor": {
|
||||
"Detected": "algılandı",
|
||||
"Disabled": "hizmet dışı kalmış",
|
||||
@@ -750,6 +777,8 @@
|
||||
"ShowAxes": "Eksenleri Göster"
|
||||
},
|
||||
"GeneralTab": {
|
||||
"12hours": "12 saat ({time})",
|
||||
"24hours": "24 saat ({time})",
|
||||
"Backup": "Yedek",
|
||||
"BackupDialog": "Lütfen yedek oluşturmak istediğiniz tüm bölümleri seçin:",
|
||||
"CalcEstimateTime": "Tahmini zaman hesaplaması",
|
||||
@@ -765,6 +794,7 @@
|
||||
"Slicer": "Dilimleyici (M73)"
|
||||
},
|
||||
"CannotReadJson": "Yedekleme dosyası okunamıyor/ayrıştırılamıyor.",
|
||||
"DateFormat": "Tarih formatı",
|
||||
"DbConsoleHistory": "Konsol Geçmişi",
|
||||
"DbHistoryJobs": "Geçmiş İşler",
|
||||
"DbHistoryTotals": "Geçmiş Toplamları",
|
||||
@@ -784,7 +814,8 @@
|
||||
"PrinterName": "Yazıcı İsmi",
|
||||
"Reset": "sıfırla",
|
||||
"Restore": "Eski haline getir",
|
||||
"RestoreDialog": "Lütfen geri yüklemek istediğiniz tüm bölümleri seçin:"
|
||||
"RestoreDialog": "Lütfen geri yüklemek istediğiniz tüm bölümleri seçin:",
|
||||
"TimeFormat": "Tarih formatı"
|
||||
},
|
||||
"InterfaceSettings": "Arayüz Ayarları",
|
||||
"MacrosTab": {
|
||||
@@ -823,6 +854,29 @@
|
||||
"UnknownGroup": "Bilinmeyen Grup",
|
||||
"Warning": "uyarı"
|
||||
},
|
||||
"MiscellaneousTab": {
|
||||
"AddGroup": "grup ekle",
|
||||
"AddPreset": "ön ayar ekle",
|
||||
"Color": "Renk",
|
||||
"CreateGroup": "Grup oluştur",
|
||||
"CreatePreset": "Hazır ayar oluştur",
|
||||
"End": "Son",
|
||||
"EndDescription": "Bu grubun son LED'i.",
|
||||
"Groups": "Gruplar",
|
||||
"GroupSubTitle": "Başlangıç: {start}, Bitiş: {end}",
|
||||
"LightGroups": "{name} - Gruplar",
|
||||
"LightPresets": "{name} - Ön Ayarlar",
|
||||
"Miscellaneous": "Çeşitli",
|
||||
"Name": "İsim",
|
||||
"NoDevicesFound": "Hiçbir cihaz bulunamadı",
|
||||
"NoGroupFound": "Grup bulunamadı",
|
||||
"NoPresetFound": "Ön ayar bulunamadı",
|
||||
"Presets": "Ön Ayarlar",
|
||||
"Start": "Başlat",
|
||||
"StartDescription": "Bu grubun ilk LED'i.",
|
||||
"UnableToLoadLight": "Işık yüklenemiyor",
|
||||
"UnableToLoadPreset": "Ön ayar yüklenemiyor"
|
||||
},
|
||||
"PresetsTab": {
|
||||
"AddPreset": "ön ayar ekle",
|
||||
"Cooldown": "Soğutma",
|
||||
@@ -850,6 +904,7 @@
|
||||
"UpdatePrinter": "Yazıcıyı Güncelle",
|
||||
"UseConfigJson": "InstanceDB = JSON algılandı. Yazıcı listesini değiştirmek için lütfen config.json'u kullanın."
|
||||
},
|
||||
"Store": "dükkan",
|
||||
"TimelapseTab": {
|
||||
"Autorender": "Otomatik Oluşturma",
|
||||
"AutorenderDescription": "Etkinleştirilirse, timelapse, baskının sonunda otomatik olarak oluşturulacaktır.",
|
||||
@@ -944,6 +999,7 @@
|
||||
"ShowWebcamInNavigation": "Web kamerasını navigasyonda göster",
|
||||
"UiSettings": "Arayüz-Ayarları"
|
||||
},
|
||||
"Update": "güncelleme",
|
||||
"WebcamsTab": {
|
||||
"AddWebcam": "web kamerası ekle",
|
||||
"CreateWebcam": "Web Kamerası Oluştur",
|
||||
@@ -951,7 +1007,7 @@
|
||||
"EditWebcam": "Web Kamerası Düzenle",
|
||||
"FlipWebcam": "Web kamerasını çevirin:",
|
||||
"Horizontally": "yatay olarak",
|
||||
"IconBed": "Yatak",
|
||||
"IconBed": "Tabla",
|
||||
"IconCam": "Kamera",
|
||||
"IconDoor": "Kapı",
|
||||
"IconFilament": "Filament",
|
||||
|
||||
+70
-14
@@ -13,7 +13,7 @@
|
||||
},
|
||||
"MoonrakerWarnings": {
|
||||
"MoonrakerComponent": "Moonraker: {component}",
|
||||
"MoonrakerFailedComponentDescription": "加载moonraker组件'{component}'时检测到错误。请检查日志文件并解决问题。",
|
||||
"MoonrakerFailedComponentDescription": "加载moonraker组件'{component}'时检测到错误。请检查日志文件并修复此问题。",
|
||||
"MoonrakerWarning": "Moonraker警告",
|
||||
"UnparsedConfigOption": "在[{section}]标签中检测到无法解析的配置'{option}: {value}'。这可能是一个不再可用的选项,也可能是组件加载失败的结果。在将来,这将导致启动错误。",
|
||||
"UnparsedConfigSection": "检测到无法解析的标签[{section}]。这可能是一个不再可用的标签,也可能是组件加载失败的结果。在将来,这将导致启动错误。"
|
||||
@@ -107,10 +107,21 @@
|
||||
"UpdatingDone": "{software}更新完成!"
|
||||
}
|
||||
},
|
||||
"BedScrews": {
|
||||
"Abort": "取消",
|
||||
"Accept": "接受",
|
||||
"Adjusted": "已调整",
|
||||
"Description": "如果当前螺丝已调整,请点击<b>已调整</b>。未调整下继续请点击<b>认可</b>。",
|
||||
"Headline": "热床螺丝",
|
||||
"ScrewAccepted": "已认可的螺丝",
|
||||
"ScrewIndex": "螺丝索引",
|
||||
"ScrewName": "螺丝名称",
|
||||
"ScrewOutput": "当前{current}/总共{max}"
|
||||
},
|
||||
"ConnectionDialog": {
|
||||
"CannotConnectTo": "Moonraker ({host})连接失败。",
|
||||
"CheckMoonrakerLog": "如果此消息重复显示, 请从此处查看日志文件:",
|
||||
"Connecting": "连接到{host}",
|
||||
"CannotConnectTo": "无法连接Moonraker ({host})。",
|
||||
"CheckMoonrakerLog": "如果此消息重复显示,请从此处查看日志文件:",
|
||||
"Connecting": "连接{host}",
|
||||
"Failed": "连接失败",
|
||||
"Initializing": "正在初始化",
|
||||
"TryAgain": "重试"
|
||||
@@ -128,7 +139,7 @@
|
||||
"Cancel": "取消",
|
||||
"DoYouWantToStartFilename": "是否开始打印{filename}?",
|
||||
"Headline": "开始任务",
|
||||
"Print": "开始打印",
|
||||
"Print": "打印",
|
||||
"Timelapse": "延时摄影"
|
||||
}
|
||||
},
|
||||
@@ -191,7 +202,7 @@
|
||||
"LastTotalDuration": "上次打印总耗时",
|
||||
"LayerHeight": "层高",
|
||||
"Name": "名称",
|
||||
"NewDirectory": "新建文件夹",
|
||||
"NewDirectory": "新文件夹",
|
||||
"NozzleDiameter": "喷嘴直径",
|
||||
"ObjectHeight": "物体高度",
|
||||
"Preheat": "预热",
|
||||
@@ -222,7 +233,7 @@
|
||||
"GCodeViewer": {
|
||||
"ClearLoadedFile": "清除",
|
||||
"ColorMode": "颜色模式",
|
||||
"Downloading": "下载中",
|
||||
"Downloading": "正在下载",
|
||||
"ForceLineRendering": "强制线渲染",
|
||||
"HDRendering": "高清渲染(圆形拉伸)",
|
||||
"High": "高",
|
||||
@@ -232,14 +243,14 @@
|
||||
"Max": "最大",
|
||||
"Medium": "中",
|
||||
"ReloadRequired": "需要重新加载",
|
||||
"Rendering": "渲染中",
|
||||
"Rendering": "正在渲染",
|
||||
"RenderQuality": "渲染质量",
|
||||
"ShowObjectSelection": "显示可选对象",
|
||||
"ShowToolhead": "显示打印头",
|
||||
"ShowTravelMoves": "显示移动路径",
|
||||
"SpecularLighting": "镜面光泽",
|
||||
"Title": "G-Code预览",
|
||||
"Tracking": "追踪",
|
||||
"Tracking": "正在追踪",
|
||||
"Transparency": "透明度",
|
||||
"Ultra": "极致",
|
||||
"VoxelMode": "体素模式(ASMBL)"
|
||||
@@ -266,7 +277,7 @@
|
||||
"InvalidNameAlreadyExists": "预设名称已经存在,请换一个名称。",
|
||||
"InvalidNameEmpty": "输入值不能为空!",
|
||||
"InvalidNameReserved": "预设 'default' 已保留,请选择其他预设名称。",
|
||||
"Later": "Later",
|
||||
"Later": "以后",
|
||||
"Mesh": "床网",
|
||||
"Name": "名称",
|
||||
"NoBedMeshHasBeenLoadedYet": "没有加载床网。",
|
||||
@@ -457,6 +468,12 @@
|
||||
"UpToDate": "已经更新到最新"
|
||||
}
|
||||
},
|
||||
"ManualProbe": {
|
||||
"Abort": "取消",
|
||||
"Accept": "接受",
|
||||
"Advanced": "高级",
|
||||
"Headline": "手动Probe"
|
||||
},
|
||||
"Panels": {
|
||||
"ExtruderControlPanel": {
|
||||
"Allowed": "允许",
|
||||
@@ -491,9 +508,10 @@
|
||||
},
|
||||
"KlippyStatePanel": {
|
||||
"FirmwareRestart": "重启Klipper并重置主控",
|
||||
"KlipperCheck": "请检查Klipper服务是否运行并且已经设置UDS(Unix Domain Socket)。",
|
||||
"KlipperCheck": "请检查Klipper服务是否运行。",
|
||||
"MoonrakerCannotConnect": "Moonraker无法连接到Klipper !",
|
||||
"Restart": "重启Klipper"
|
||||
"Restart": "重启Klipper",
|
||||
"ServiceReports": "{service} 报告"
|
||||
},
|
||||
"MachineSettingsPanel": {
|
||||
"Headline": "机器设置",
|
||||
@@ -523,6 +541,12 @@
|
||||
},
|
||||
"MiscellaneousPanel": {
|
||||
"Headline": "其他设置",
|
||||
"Light": {
|
||||
"Blue": "蓝",
|
||||
"Green": "绿",
|
||||
"Red": "红",
|
||||
"White": "白"
|
||||
},
|
||||
"RunoutSensor": {
|
||||
"Detected": "检测到",
|
||||
"Disabled": "已关闭",
|
||||
@@ -753,6 +777,8 @@
|
||||
"ShowAxes": "显示轴"
|
||||
},
|
||||
"GeneralTab": {
|
||||
"12hours": "12-小时 ({time})",
|
||||
"24hours": "24-小时 ({time})",
|
||||
"Backup": "备份",
|
||||
"BackupDialog": "请选择你想要备份的内容:",
|
||||
"CalcEstimateTime": "估算时间计算",
|
||||
@@ -768,6 +794,7 @@
|
||||
"Slicer": "切片软件 (M73)"
|
||||
},
|
||||
"CannotReadJson": "无法读取/解析备份文件。",
|
||||
"DateFormat": "日期格式",
|
||||
"DbConsoleHistory": "控制台历史记录",
|
||||
"DbHistoryJobs": "历史任务",
|
||||
"DbHistoryTotals": "历史统计",
|
||||
@@ -787,7 +814,8 @@
|
||||
"PrinterName": "打印机名称",
|
||||
"Reset": "重启",
|
||||
"Restore": "恢复",
|
||||
"RestoreDialog": "请选择你想要恢复的项:"
|
||||
"RestoreDialog": "请选择你想要恢复的项:",
|
||||
"TimeFormat": "时间格式"
|
||||
},
|
||||
"InterfaceSettings": "Mainsail设置",
|
||||
"MacrosTab": {
|
||||
@@ -826,6 +854,29 @@
|
||||
"UnknownGroup": "未知分组",
|
||||
"Warning": "警告"
|
||||
},
|
||||
"MiscellaneousTab": {
|
||||
"AddGroup": "添加分组",
|
||||
"AddPreset": "添加预设",
|
||||
"Color": "颜色",
|
||||
"CreateGroup": "新建分组",
|
||||
"CreatePreset": "新建预设",
|
||||
"End": "结束",
|
||||
"EndDescription": "分组中最后的LED",
|
||||
"Groups": "分组",
|
||||
"GroupSubTitle": "开始:{start},结束:{end}",
|
||||
"LightGroups": "{name} - 分组",
|
||||
"LightPresets": "{name} - 预设",
|
||||
"Miscellaneous": "杂项",
|
||||
"Name": "名称",
|
||||
"NoDevicesFound": "未找到设备",
|
||||
"NoGroupFound": "未找到分组",
|
||||
"NoPresetFound": "未找到预设",
|
||||
"Presets": "预设",
|
||||
"Start": "开始",
|
||||
"StartDescription": "分组中第一个LED",
|
||||
"UnableToLoadLight": "无法加载灯",
|
||||
"UnableToLoadPreset": "无法加载预设"
|
||||
},
|
||||
"PresetsTab": {
|
||||
"AddPreset": "添加预设",
|
||||
"Cooldown": "冷却",
|
||||
@@ -851,8 +902,9 @@
|
||||
"Port": "Moonraker服务端口",
|
||||
"RemotePrinters": "打印机",
|
||||
"UpdatePrinter": "更新打印机",
|
||||
"UseConfigJson": "InstanceDB = JSON detected. 请使用 config.json 来修改打印机列表。"
|
||||
"UseConfigJson": "检测到InstanceDB = JSON。请使用 config.json 来修改打印机列表。"
|
||||
},
|
||||
"Store": "存储",
|
||||
"TimelapseTab": {
|
||||
"Autorender": "自动渲染",
|
||||
"AutorenderDescription": "如果开启将在打印结束后自动渲染延时摄影的视频",
|
||||
@@ -947,11 +999,14 @@
|
||||
"ShowWebcamInNavigation": "在导航栏中显示摄像头",
|
||||
"UiSettings": "UI设置"
|
||||
},
|
||||
"Update": "更新",
|
||||
"WebcamsTab": {
|
||||
"AddWebcam": "添加摄像头",
|
||||
"CreateWebcam": "添加摄像头",
|
||||
"EditCrowsnestConf": "编辑 crowsnest.conf",
|
||||
"EditWebcam": "编辑摄像头",
|
||||
"FlipWebcam": "翻转摄像头图像:",
|
||||
"Horizontally": "水平",
|
||||
"IconBed": "热床",
|
||||
"IconCam": "摄像头",
|
||||
"IconDoor": "门",
|
||||
@@ -974,6 +1029,7 @@
|
||||
"UrlSnapshot": "快照地址(URL)",
|
||||
"UrlStream": "视频流地址(URL)",
|
||||
"Uv4lMjpeg": "UV4L-MJPEG",
|
||||
"Vertically": "垂直",
|
||||
"Webcams": "摄像头"
|
||||
}
|
||||
},
|
||||
|
||||
+8
-79
@@ -95,7 +95,6 @@ import StatusPanel from '@/components/panels/StatusPanel.vue'
|
||||
import ToolheadControlPanel from '@/components/panels/ToolheadControlPanel.vue'
|
||||
import TemperaturePanel from '@/components/panels/TemperaturePanel.vue'
|
||||
import WebcamPanel from '@/components/panels/WebcamPanel.vue'
|
||||
import kebabCase from 'lodash.kebabcase'
|
||||
|
||||
@Component({
|
||||
components: {
|
||||
@@ -114,106 +113,36 @@ import kebabCase from 'lodash.kebabcase'
|
||||
},
|
||||
})
|
||||
export default class PageDashboard extends Mixins(DashboardMixin) {
|
||||
get allComponents() {
|
||||
let output: string[] = []
|
||||
const components = Object.keys(this.$options.components ?? {})
|
||||
|
||||
components?.forEach((component) => {
|
||||
if (component.endsWith('Panel')) output.push(kebabCase(component))
|
||||
})
|
||||
|
||||
// remove toolhead panel, if kinematics === none
|
||||
if (this.printerKinematics === 'none') {
|
||||
output = output.filter((name) => name !== 'toolhead-control-panel')
|
||||
}
|
||||
|
||||
// remove extruder panel, if printerExtruderCount < 1
|
||||
if (this.printerExtruderCount < 1) {
|
||||
output = output.filter((name) => name !== 'extruder-control-panel')
|
||||
}
|
||||
|
||||
// remove temperature panel, if heaters & sensors < 1
|
||||
if (this.printerAvailableHeatersCount + this.printerTemperatureSensorsCount < 1) {
|
||||
output = output.filter((name) => name !== 'temperature-panel')
|
||||
}
|
||||
|
||||
return output
|
||||
}
|
||||
|
||||
get mobileLayout() {
|
||||
let panels = this.$store.getters['gui/getPanels']('mobileLayout')
|
||||
panels = panels.concat(this.missingPanelsMobile)
|
||||
panels = panels.filter(
|
||||
(element: any) => element.visible && this.allComponents.includes(this.extractPanelName(element.name))
|
||||
)
|
||||
|
||||
return panels
|
||||
return this.$store.getters['gui/getPanels']('mobile', 0, true)
|
||||
}
|
||||
|
||||
get tabletLayout1() {
|
||||
let panels = this.$store.getters['gui/getPanels']('tabletLayout1')
|
||||
panels = panels.concat(this.missingPanelsTablet)
|
||||
panels = panels.filter(
|
||||
(element: any) => element.visible && this.allComponents.includes(this.extractPanelName(element.name))
|
||||
)
|
||||
|
||||
return panels
|
||||
return this.$store.getters['gui/getPanels']('tablet', 1, true)
|
||||
}
|
||||
|
||||
get tabletLayout2() {
|
||||
let panels = this.$store.getters['gui/getPanels']('tabletLayout2')
|
||||
panels = panels.filter(
|
||||
(element: any) => element.visible && this.allComponents.includes(this.extractPanelName(element.name))
|
||||
)
|
||||
|
||||
return panels
|
||||
return this.$store.getters['gui/getPanels']('tablet', 2, true)
|
||||
}
|
||||
|
||||
get desktopLayout1() {
|
||||
let panels = this.$store.getters['gui/getPanels']('desktopLayout1')
|
||||
panels = panels.concat(this.missingPanelsDesktop)
|
||||
panels = panels.filter(
|
||||
(element: any) => element.visible && this.allComponents.includes(this.extractPanelName(element.name))
|
||||
)
|
||||
|
||||
return panels
|
||||
return this.$store.getters['gui/getPanels']('desktop', 1, true)
|
||||
}
|
||||
|
||||
get desktopLayout2() {
|
||||
let panels = this.$store.getters['gui/getPanels']('desktopLayout2')
|
||||
panels = panels.filter(
|
||||
(element: any) => element.visible && this.allComponents.includes(this.extractPanelName(element.name))
|
||||
)
|
||||
|
||||
return panels
|
||||
return this.$store.getters['gui/getPanels']('desktop', 2, true)
|
||||
}
|
||||
|
||||
get widescreenLayout1() {
|
||||
let panels = this.$store.getters['gui/getPanels']('widescreenLayout1')
|
||||
panels = panels.concat(this.missingPanelsWidescreen)
|
||||
panels = panels.filter(
|
||||
(element: any) => element.visible && this.allComponents.includes(this.extractPanelName(element.name))
|
||||
)
|
||||
|
||||
return panels
|
||||
return this.$store.getters['gui/getPanels']('widescreen', 1, true)
|
||||
}
|
||||
|
||||
get widescreenLayout2() {
|
||||
let panels = this.$store.getters['gui/getPanels']('widescreenLayout2')
|
||||
panels = panels.filter(
|
||||
(element: any) => element.visible && this.allComponents.includes(this.extractPanelName(element.name))
|
||||
)
|
||||
|
||||
return panels
|
||||
return this.$store.getters['gui/getPanels']('widescreen', 2, true)
|
||||
}
|
||||
|
||||
get widescreenLayout3() {
|
||||
let panels = this.$store.getters['gui/getPanels']('widescreenLayout3')
|
||||
panels = panels.filter(
|
||||
(element: any) => element.visible && this.allComponents.includes(this.extractPanelName(element.name))
|
||||
)
|
||||
|
||||
return panels
|
||||
return this.$store.getters['gui/getPanels']('widescreen', 3, true)
|
||||
}
|
||||
|
||||
extractPanelName(name: string) {
|
||||
|
||||
+14
-15
@@ -96,7 +96,7 @@
|
||||
<v-col
|
||||
class="col-12 col-sm-auto pt-0 pb-0 pl-lg-6 d-flex justify-center justify-sm-start">
|
||||
<v-switch
|
||||
v-model="scaleVisualMap"
|
||||
v-model="scaleGradient"
|
||||
:label="$t('Heightmap.ScaleGradient')"
|
||||
class="mt-0 ml-5"></v-switch>
|
||||
</v-col>
|
||||
@@ -129,7 +129,7 @@
|
||||
<v-row>
|
||||
<v-col>
|
||||
<v-slider
|
||||
v-model="heightmapScale"
|
||||
v-model="scaleZMax"
|
||||
:label="$t('Heightmap.ScaleZMax')"
|
||||
:min="heightmapRangeLimit[0]"
|
||||
:max="heightmapRangeLimit[1]"
|
||||
@@ -186,7 +186,7 @@
|
||||
</v-row>
|
||||
<v-divider class="my-3"></v-divider>
|
||||
<v-row class="px-3">
|
||||
<v-col>{{ $t('Heightmap.CurrentMesh.Variance') }}</v-col>
|
||||
<v-col>{{ $t('Heightmap.CurrentMesh.Range') }}</v-col>
|
||||
<v-col class="text-right">{{ currentProfile.variance.toFixed(3) }} mm</v-col>
|
||||
</v-row>
|
||||
</v-card-text>
|
||||
@@ -478,7 +478,6 @@ export default class PageHeightmap extends Mixins(BaseMixin, ControlMixin) {
|
||||
(value: string) => !this.existsProfileName(value) || this.$t('Heightmap.InvalidNameAlreadyExists'),
|
||||
]
|
||||
|
||||
private heightmapScale = 0.5
|
||||
private probedOpacity = 1
|
||||
private meshOpacity = 1
|
||||
private flatOpacity = 0.5
|
||||
@@ -564,8 +563,8 @@ export default class PageHeightmap extends Mixins(BaseMixin, ControlMixin) {
|
||||
},
|
||||
zAxis3D: {
|
||||
type: 'value',
|
||||
min: this.heightmapScale * -1,
|
||||
max: this.heightmapScale,
|
||||
min: this.scaleZMax * -1,
|
||||
max: this.scaleZMax,
|
||||
nameTextStyle: {
|
||||
color: this.colorAxisName,
|
||||
},
|
||||
@@ -671,20 +670,20 @@ export default class PageHeightmap extends Mixins(BaseMixin, ControlMixin) {
|
||||
this.$store.dispatch('gui/saveSetting', { name: 'view.heightmap.wireframe', value: newVal })
|
||||
}
|
||||
|
||||
get scale(): boolean {
|
||||
return this.$store.state.gui.view.heightmap.scale ?? true
|
||||
get scaleGradient(): boolean {
|
||||
return this.$store.state.gui.view.heightmap.scaleGradient ?? false
|
||||
}
|
||||
|
||||
set scale(newVal) {
|
||||
this.$store.dispatch('gui/saveSetting', { name: 'view.heightmap.scale', value: newVal })
|
||||
set scaleGradient(newVal) {
|
||||
this.$store.dispatch('gui/saveSetting', { name: 'view.heightmap.scaleGradient', value: newVal })
|
||||
}
|
||||
|
||||
get scaleVisualMap(): boolean {
|
||||
return this.$store.state.gui.view.heightmap.scaleVisualMap ?? false
|
||||
get scaleZMax(): number {
|
||||
return this.$store.state.gui.view.heightmap.scaleZMax ?? 0.5
|
||||
}
|
||||
|
||||
set scaleVisualMap(newVal) {
|
||||
this.$store.dispatch('gui/saveSetting', { name: 'view.heightmap.scaleVisualMap', value: newVal })
|
||||
set scaleZMax(newVal) {
|
||||
this.$store.dispatch('gui/saveSetting', { name: 'view.heightmap.scaleZMax', value: newVal })
|
||||
}
|
||||
|
||||
get rangeX(): number[] {
|
||||
@@ -911,7 +910,7 @@ export default class PageHeightmap extends Mixins(BaseMixin, ControlMixin) {
|
||||
}
|
||||
|
||||
get visualMapRange(): number[] {
|
||||
if (!this.scaleVisualMap) return [-0.1, 0.1]
|
||||
if (!this.scaleGradient) return [-0.1, 0.1]
|
||||
|
||||
return this.heightmapLimit
|
||||
}
|
||||
|
||||
@@ -14,7 +14,6 @@ const mainsailEditor = EditorView.theme(
|
||||
color: '#d4d4d4',
|
||||
backgroundColor: ui.background,
|
||||
},
|
||||
|
||||
'.cm-activeLine.cm-line': {
|
||||
caretColor: '#d4d4d4 !important',
|
||||
},
|
||||
@@ -37,6 +36,76 @@ const mainsailEditor = EditorView.theme(
|
||||
'.cm-selectionMatch': {
|
||||
backgroundColor: '#add6ff26',
|
||||
},
|
||||
|
||||
'.cm-button': {
|
||||
'font-family': 'Roboto,sans-serif',
|
||||
'font-weight': '500',
|
||||
'font-size': '.675rem',
|
||||
'letter-spacing': '0.0892857143em',
|
||||
'vertical-align': 'middle',
|
||||
padding: '0.3em 1em',
|
||||
'border-radius': '4px',
|
||||
'border-width': '0',
|
||||
color: 'var(--color-primary)',
|
||||
'background-color': 'var(--v-secondary-darken2)',
|
||||
'background-image': 'none!important',
|
||||
'text-transform': 'uppercase',
|
||||
'text-indent': '0.0892857143em',
|
||||
'text-aling': 'left',
|
||||
},
|
||||
|
||||
'.cm-textfield:focus': {
|
||||
'border-color': 'var(--color-primary)!important',
|
||||
},
|
||||
|
||||
'.cm-textfield:focus-visible': {
|
||||
'border-color': 'var(--color-primary)!important',
|
||||
},
|
||||
|
||||
'.cm-textfield::placeholder': {
|
||||
'text-transform': 'uppercase',
|
||||
},
|
||||
'.cm-panel.cm-search label': {
|
||||
'font-weight': '500',
|
||||
'font-family': 'Roboto,sans-serif',
|
||||
'letter-spacing': '0.0892857143em',
|
||||
'text-transform': 'uppercase',
|
||||
'font-size': '12px',
|
||||
'white-space': 'pre',
|
||||
color: 'var(--v-primary-base)',
|
||||
},
|
||||
|
||||
'.cm-panel.cm-search [name=close]': {
|
||||
'font-family': 'Roboto,sans-serif',
|
||||
'text-transform': 'uppercase',
|
||||
'font-size': '200%',
|
||||
'white-space': 'pre',
|
||||
color: 'var(--color-primary)',
|
||||
'padding-right': '5px',
|
||||
'padding-top': '5px',
|
||||
},
|
||||
|
||||
'.cm-button:hover': {
|
||||
'background-color': 'var(--v-secondary-lighten1)',
|
||||
'background-image': 'none!important',
|
||||
'transition-duration': '0.5s',
|
||||
'transition-timing-function': 'cubic-bezier(1.2,0,.2,1)',
|
||||
},
|
||||
|
||||
'.cm-textfield': {
|
||||
'font-family': 'Roboto,sans-serif',
|
||||
'vertical-align': 'middle',
|
||||
'font-size': '.675rem',
|
||||
border: '1px solid silver',
|
||||
backgroundColor: ui.background,
|
||||
padding: '.3em .1em',
|
||||
'padding-left': '0.6em',
|
||||
'border-radius': '0.2em',
|
||||
},
|
||||
|
||||
'.cm-panels': {
|
||||
'background-color': 'var(--v-toolbar-base)',
|
||||
},
|
||||
},
|
||||
{ dark: true }
|
||||
)
|
||||
|
||||
@@ -1,17 +1,5 @@
|
||||
import { FileStateFile } from '@/store/files/types'
|
||||
import { PrinterStateMacroParams } from '@/store/printer/types'
|
||||
import {
|
||||
mdiArrowCollapseVertical,
|
||||
mdiCodeTags,
|
||||
mdiConsoleLine,
|
||||
mdiDipSwitch,
|
||||
mdiEngine,
|
||||
mdiGamepad,
|
||||
mdiInformation,
|
||||
mdiPrinter3dNozzle,
|
||||
mdiThermometerLines,
|
||||
mdiWebcam,
|
||||
} from '@mdi/js'
|
||||
import Vue from 'vue'
|
||||
|
||||
export const setDataDeep = (currentState: any, payload: any) => {
|
||||
@@ -64,34 +52,6 @@ export const capitalize = (str: string): string => {
|
||||
return str.charAt(0).toUpperCase() + str.slice(1)
|
||||
}
|
||||
|
||||
export const convertPanelnameToIcon = (name: string): string => {
|
||||
if (name.startsWith('macrogroup_')) return mdiCodeTags
|
||||
|
||||
switch (name) {
|
||||
case 'webcam':
|
||||
return mdiWebcam
|
||||
case 'zoffset':
|
||||
return mdiArrowCollapseVertical
|
||||
case 'toolhead-control':
|
||||
return mdiGamepad
|
||||
case 'macros':
|
||||
return mdiCodeTags
|
||||
case 'miscellaneous':
|
||||
return mdiDipSwitch
|
||||
case 'temperature':
|
||||
return mdiThermometerLines
|
||||
case 'miniconsole':
|
||||
return mdiConsoleLine
|
||||
case 'machine-settings':
|
||||
return mdiEngine
|
||||
case 'extruder-control':
|
||||
return mdiPrinter3dNozzle
|
||||
|
||||
default:
|
||||
return mdiInformation
|
||||
}
|
||||
}
|
||||
|
||||
export const camelize = (str: string): string => {
|
||||
return str
|
||||
.replace(/_/g, ' ')
|
||||
|
||||
@@ -32,7 +32,6 @@ export const actions: ActionTree<RootState, RootState> = {
|
||||
importConfigJson({ commit }, payload: ConfigJson) {
|
||||
type RootStateInstancesDbType = 'moonraker' | 'browser' | 'json'
|
||||
let instancesDB: RootStateInstancesDbType = payload.instancesDB ?? 'moonraker'
|
||||
if (document.location.hostname === 'my.mainsail.xyz') instancesDB = 'browser'
|
||||
if (import.meta.env.VUE_APP_INSTANCES_DB)
|
||||
instancesDB = import.meta.env.VUE_APP_INSTANCES_DB as RootStateInstancesDbType
|
||||
|
||||
|
||||
+103
-20
@@ -1,6 +1,7 @@
|
||||
import { GetterTree } from 'vuex'
|
||||
import { GuiState } from '@/store/gui/types'
|
||||
import { GuiMacrosStateMacrogroup } from '@/store/gui/macros/types'
|
||||
import { allDashboardPanels } from '@/store/variables'
|
||||
|
||||
// eslint-disable-next-line
|
||||
export const getters: GetterTree<GuiState, any> = {
|
||||
@@ -33,31 +34,113 @@ export const getters: GetterTree<GuiState, any> = {
|
||||
return true
|
||||
},
|
||||
|
||||
getPanels: (state, getters, rootState) => (viewport: string) => {
|
||||
// @ts-ignore
|
||||
let panels = state.dashboard[viewport]?.filter((element: any) => element !== null) ?? []
|
||||
getAllPossiblePanels: (state, getters, rootState, rootGetters) => {
|
||||
let allPanels = [...allDashboardPanels]
|
||||
|
||||
if (rootState.gui.macros.mode === 'simple')
|
||||
panels = panels.filter((element: any) => !element.name.startsWith('macrogroup_'))
|
||||
else {
|
||||
panels = panels.filter((element: any) => element.name !== 'macros')
|
||||
// remove macros panel and add macrogroups panels if macroMode === expert
|
||||
if (state.macros?.mode === 'expert') {
|
||||
const macrogroups = getters['macros/getAllMacrogroups']
|
||||
if (macrogroups.length) {
|
||||
panels = panels.filter((element: any) => {
|
||||
if (!element.name.startsWith('macrogroup_')) return true
|
||||
|
||||
const macrogroupId = element.name.slice(11)
|
||||
return (
|
||||
macrogroups.findIndex(
|
||||
(macrogroup: GuiMacrosStateMacrogroup) => macrogroup.id === macrogroupId
|
||||
) !== -1
|
||||
)
|
||||
})
|
||||
}
|
||||
macrogroups.forEach((group: GuiMacrosStateMacrogroup) => {
|
||||
allPanels.push('macrogroup_' + group.id)
|
||||
})
|
||||
|
||||
allPanels = allPanels.filter((name) => name !== 'macros')
|
||||
}
|
||||
|
||||
if (getters['webcams/getWebcams'].length === 0) {
|
||||
panels = panels.filter((element: any) => element.name !== 'webcam')
|
||||
// remove toolhead panel, if kinematics === none
|
||||
const printerKinematics = rootGetters['printer/getKinematics']
|
||||
if (printerKinematics === 'none') {
|
||||
allPanels = allPanels.filter((name) => name !== 'toolhead-control')
|
||||
}
|
||||
|
||||
// remove extruder panel, if printerExtruderCount < 1
|
||||
const printerExtruders = rootGetters['printer/getExtruders']
|
||||
if (printerExtruders.length < 1) {
|
||||
allPanels = allPanels.filter((name) => name !== 'extruder-control')
|
||||
}
|
||||
|
||||
// remove temperature panel, if heaters & sensors < 1
|
||||
const printerAvailableHeaters = rootGetters['printer/getAvailableHeaters']
|
||||
const printerTemperatureSensorKeys = rootGetters['printer/getTemperatureSensorKeys']
|
||||
if (printerAvailableHeaters.length + printerTemperatureSensorKeys.length < 1) {
|
||||
allPanels = allPanels.filter((name) => name !== 'temperature')
|
||||
}
|
||||
|
||||
// remove webcam panel, if no webcam exists
|
||||
const webcams = getters['webcams/getWebcams']
|
||||
if (webcams.length === 0) {
|
||||
allPanels = allPanels.filter((name) => name !== 'webcam')
|
||||
}
|
||||
|
||||
return allPanels
|
||||
},
|
||||
|
||||
getPanels:
|
||||
(state, getters, rootState) =>
|
||||
(viewport: string, column: number, onlyVisible: boolean = false) => {
|
||||
const layoutName = column ? `${viewport}Layout${column}` : `${viewport}Layout`
|
||||
// @ts-ignore
|
||||
let panels = state.dashboard[layoutName]?.filter((element: any) => element !== null) ?? []
|
||||
|
||||
if (column < 2) {
|
||||
const allViewportPanels = getters['getAllPanelsFromViewport'](viewport)
|
||||
const allPossiblePanels = getters['getAllPossiblePanels']
|
||||
const missingPanels: any[] = []
|
||||
|
||||
allPossiblePanels.forEach((panelname: string) => {
|
||||
if (!allViewportPanels.find((panel: any) => panel.name === panelname))
|
||||
missingPanels.push({
|
||||
name: panelname,
|
||||
visible: true,
|
||||
})
|
||||
})
|
||||
panels = panels.concat(missingPanels)
|
||||
}
|
||||
|
||||
if (onlyVisible) {
|
||||
panels = panels.filter((element: any) => element.visible)
|
||||
}
|
||||
|
||||
if (rootState.gui.macros.mode === 'simple')
|
||||
panels = panels.filter((element: any) => !element.name.startsWith('macrogroup_'))
|
||||
else {
|
||||
panels = panels.filter((element: any) => element.name !== 'macros')
|
||||
const macrogroups = getters['macros/getAllMacrogroups']
|
||||
if (macrogroups.length) {
|
||||
panels = panels.filter((element: any) => {
|
||||
if (!element.name.startsWith('macrogroup_')) return true
|
||||
|
||||
const macrogroupId = element.name.slice(11)
|
||||
return (
|
||||
macrogroups.findIndex(
|
||||
(macrogroup: GuiMacrosStateMacrogroup) => macrogroup.id === macrogroupId
|
||||
) !== -1
|
||||
)
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
if (getters['webcams/getWebcams'].length === 0) {
|
||||
panels = panels.filter((element: any) => element.name !== 'webcam')
|
||||
}
|
||||
|
||||
return panels
|
||||
},
|
||||
|
||||
getAllPanelsFromViewport: (state) => (viewport: string) => {
|
||||
let panels: any = []
|
||||
|
||||
if (`${viewport}Layout` in state.dashboard) {
|
||||
// @ts-ignore
|
||||
panels = panels.concat(state.dashboard[`${viewport}Layout`])
|
||||
}
|
||||
|
||||
let nr = 1
|
||||
while (`${viewport}Layout${nr}` in state.dashboard) {
|
||||
// @ts-ignore
|
||||
panels = panels.concat(state.dashboard[`${viewport}Layout${nr}`])
|
||||
nr++
|
||||
}
|
||||
|
||||
return panels
|
||||
|
||||
@@ -194,8 +194,8 @@ export const getDefaultState = (): GuiState => {
|
||||
mesh: false,
|
||||
flat: false,
|
||||
wireframe: true,
|
||||
scale: 0.5,
|
||||
scaleVisualMap: false,
|
||||
scaleGradient: false,
|
||||
scaleZMax: 0.5,
|
||||
},
|
||||
history: {
|
||||
countPerPage: 10,
|
||||
|
||||
@@ -133,8 +133,8 @@ export interface GuiState {
|
||||
mesh: boolean
|
||||
flat: boolean
|
||||
wireframe: boolean
|
||||
scale: number
|
||||
scaleVisualMap: boolean
|
||||
scaleGradient: boolean
|
||||
scaleZMax: number
|
||||
}
|
||||
history: {
|
||||
countPerPage: number
|
||||
|
||||
@@ -100,15 +100,13 @@ export const getters: GetterTree<PrinterState, RootState> = {
|
||||
},
|
||||
|
||||
getPrintMaxLayers: (state) => {
|
||||
if (state.print_stats?.info?.total_layer !== null) {
|
||||
return state.print_stats.info.total_layer
|
||||
} else if (state.current_file?.layer_count) {
|
||||
return state.current_file.layer_count
|
||||
} else if (
|
||||
'current_file' in state &&
|
||||
'first_layer_height' in state.current_file &&
|
||||
'layer_height' in state.current_file &&
|
||||
'object_height' in state.current_file
|
||||
if ((state.print_stats?.info?.total_layer ?? null) !== null) return state.print_stats.info.total_layer
|
||||
if (state.current_file?.layer_count) return state.current_file.layer_count
|
||||
|
||||
if (
|
||||
state.current_file?.first_layer_height !== undefined &&
|
||||
state.current_file?.layer_height !== undefined &&
|
||||
state.current_file?.object_height !== undefined
|
||||
) {
|
||||
const max = Math.ceil(
|
||||
(state.current_file.object_height - state.current_file.first_layer_height) /
|
||||
@@ -122,12 +120,12 @@ export const getters: GetterTree<PrinterState, RootState> = {
|
||||
},
|
||||
|
||||
getPrintCurrentLayer: (state, getters) => {
|
||||
if (state.print_stats?.info?.current_layer !== null) {
|
||||
return state.print_stats.info.current_layer
|
||||
} else if (
|
||||
if ((state.print_stats?.info?.current_layer ?? null) !== null) return state.print_stats.info.current_layer
|
||||
|
||||
if (
|
||||
state.print_stats?.print_duration > 0 &&
|
||||
'first_layer_height' in state.current_file &&
|
||||
'layer_height' in state.current_file
|
||||
state.current_file?.first_layer_height !== undefined &&
|
||||
state.current_file?.layer_height !== undefined
|
||||
) {
|
||||
const gcodePositionZ = state.gcode_move?.gcode_position[2] ?? 0
|
||||
const current_layer = Math.ceil(
|
||||
@@ -156,7 +154,7 @@ export const getters: GetterTree<PrinterState, RootState> = {
|
||||
type,
|
||||
state: { ...value },
|
||||
config: state.configfile?.config[key] ?? {},
|
||||
settings: state.configfile?.settings[key] ?? {},
|
||||
settings: state.configfile?.settings[key.toLowerCase()] ?? {},
|
||||
})
|
||||
}
|
||||
}
|
||||
@@ -280,72 +278,79 @@ export const getters: GetterTree<PrinterState, RootState> = {
|
||||
return caseInsensitiveSort(fans, 'name')
|
||||
},
|
||||
|
||||
getTemperatureSensorKeys: (state) => {
|
||||
return Object.keys(state).filter((name) => name.startsWith('temperature_sensor ') && !name.startsWith('_'))
|
||||
},
|
||||
|
||||
getTemperatureSensors: (state, getters, rootState, rootGetters) => {
|
||||
const sensors: PrinterStateTemperatureSensor[] = []
|
||||
|
||||
for (const [key, value] of Object.entries(state)) {
|
||||
const tempSensors = getters['getTemperatureSensorKeys']
|
||||
tempSensors.forEach((key: string) => {
|
||||
const nameSplit = key.split(' ')
|
||||
const values = { ...state[key] }
|
||||
let icon = mdiThermometer
|
||||
const min_temp = state.configfile?.settings[key]?.min_temp ?? 0
|
||||
const max_temp = state.configfile?.settings[key]?.max_temp ?? 210
|
||||
const split = (max_temp - min_temp) / 3
|
||||
|
||||
if (nameSplit[0] === 'temperature_sensor' && !nameSplit[1].startsWith('_')) {
|
||||
let icon = mdiThermometer
|
||||
const min_temp = state.configfile?.settings[key]?.min_temp ?? 0
|
||||
const max_temp = state.configfile?.settings[key]?.max_temp ?? 210
|
||||
const split = (max_temp - min_temp) / 3
|
||||
if (values.temperature <= min_temp + split) icon = mdiThermometerLow
|
||||
if (values.temperature >= max_temp - split) icon = mdiThermometerHigh
|
||||
|
||||
if (value.temperature <= min_temp + split) icon = mdiThermometerLow
|
||||
if (value.temperature >= max_temp - split) icon = mdiThermometerHigh
|
||||
sensors.push({
|
||||
name: nameSplit[1],
|
||||
temperature: Math.round(values.temperature * 10) / 10,
|
||||
additionalSensors: getters.getAdditionalSensors(nameSplit[1]),
|
||||
icon: icon,
|
||||
min_temp: min_temp,
|
||||
max_temp: max_temp,
|
||||
measured_min_temp: Math.round(values.measured_min_temp * 10) / 10,
|
||||
measured_max_temp: Math.round(values.measured_max_temp * 10) / 10,
|
||||
chartColor: getters['tempHistory/getDatasetColor'](nameSplit[1]),
|
||||
chartSeries: getters['tempHistory/getSerieNames'](nameSplit[1]),
|
||||
})
|
||||
})
|
||||
|
||||
sensors.push({
|
||||
name: nameSplit[1],
|
||||
temperature: Math.round(value.temperature * 10) / 10,
|
||||
additionalSensors: getters.getAdditionalSensors(nameSplit[1]),
|
||||
icon: icon,
|
||||
min_temp: min_temp,
|
||||
max_temp: max_temp,
|
||||
measured_min_temp: Math.round(value.measured_min_temp * 10) / 10,
|
||||
measured_max_temp: Math.round(value.measured_max_temp * 10) / 10,
|
||||
chartColor: getters['tempHistory/getDatasetColor'](nameSplit[1]),
|
||||
chartSeries: getters['tempHistory/getSerieNames'](nameSplit[1]),
|
||||
})
|
||||
} else if (key === 'z_thermal_adjust') {
|
||||
let icon = mdiThermometer
|
||||
const min_temp = state.configfile?.settings[key]?.min_temp ?? 0
|
||||
const max_temp = state.configfile?.settings[key]?.max_temp ?? 210
|
||||
const split = (max_temp - min_temp) / 3
|
||||
if ('z_thermal_adjust' in state) {
|
||||
const key = 'z_thermal_adjust'
|
||||
const values = state[key]
|
||||
let icon = mdiThermometer
|
||||
const min_temp = state.configfile?.settings[key]?.min_temp ?? 0
|
||||
const max_temp = state.configfile?.settings[key]?.max_temp ?? 210
|
||||
const split = (max_temp - min_temp) / 3
|
||||
|
||||
if (value.temperature <= min_temp + split) icon = mdiThermometerLow
|
||||
if (value.temperature >= max_temp - split) icon = mdiThermometerHigh
|
||||
if (values.temperature <= min_temp + split) icon = mdiThermometerLow
|
||||
if (values.temperature >= max_temp - split) icon = mdiThermometerHigh
|
||||
|
||||
const additionalSensorBool = rootGetters['gui/getDatasetAdditionalSensorValue']({
|
||||
name: key,
|
||||
sensor: 'z_adjust',
|
||||
})
|
||||
const additionalSensorBool = rootGetters['gui/getDatasetAdditionalSensorValue']({
|
||||
name: key,
|
||||
sensor: 'z_adjust',
|
||||
})
|
||||
|
||||
const additionalSensor: PrinterStateAdditionalSensor = {
|
||||
bool: additionalSensorBool,
|
||||
name: 'z_adjust',
|
||||
unit: 'μm',
|
||||
value: Math.round(value.current_z_adjust * 1000),
|
||||
}
|
||||
|
||||
if (Math.abs(value.current_z_adjust) >= 0.1) {
|
||||
additionalSensor.value = Math.round(value.current_z_adjust * 1000) / 1000
|
||||
additionalSensor.unit = 'mm'
|
||||
}
|
||||
|
||||
sensors.push({
|
||||
name: key,
|
||||
temperature: Math.round(value.temperature * 10) / 10,
|
||||
additionalSensors: [additionalSensor],
|
||||
icon,
|
||||
min_temp: min_temp,
|
||||
max_temp: max_temp,
|
||||
measured_min_temp: Math.round(value.measured_min_temp * 10) / 10,
|
||||
measured_max_temp: Math.round(value.measured_max_temp * 10) / 10,
|
||||
chartColor: getters['tempHistory/getDatasetColor'](key),
|
||||
chartSeries: getters['tempHistory/getSerieNames'](key),
|
||||
})
|
||||
const additionalSensor: PrinterStateAdditionalSensor = {
|
||||
bool: additionalSensorBool,
|
||||
name: 'z_adjust',
|
||||
unit: 'μm',
|
||||
value: Math.round(values.current_z_adjust * 1000),
|
||||
}
|
||||
|
||||
if (Math.abs(values.current_z_adjust) >= 0.1) {
|
||||
additionalSensor.value = Math.round(values.current_z_adjust * 1000) / 1000
|
||||
additionalSensor.unit = 'mm'
|
||||
}
|
||||
|
||||
sensors.push({
|
||||
name: key,
|
||||
temperature: Math.round(values.temperature * 10) / 10,
|
||||
additionalSensors: [additionalSensor],
|
||||
icon,
|
||||
min_temp: min_temp,
|
||||
max_temp: max_temp,
|
||||
measured_min_temp: Math.round(values.measured_min_temp * 10) / 10,
|
||||
measured_max_temp: Math.round(values.measured_max_temp * 10) / 10,
|
||||
chartColor: getters['tempHistory/getDatasetColor'](key),
|
||||
chartSeries: getters['tempHistory/getSerieNames'](key),
|
||||
})
|
||||
}
|
||||
|
||||
return caseInsensitiveSort(sensors, 'name')
|
||||
|
||||
@@ -153,9 +153,12 @@ export const getters: GetterTree<ServerState, any> = {
|
||||
|
||||
Object.keys(state.network_stats).forEach((interfaceName: string) => {
|
||||
if (interfaceName !== 'lo') {
|
||||
if (state.system_info?.network && interfaceName in state.system_info.network) {
|
||||
if (interfaceName in (state.system_info?.network ?? {}) || interfaceName.startsWith('can')) {
|
||||
interfaces[interfaceName] = { ...state.network_stats[interfaceName] }
|
||||
interfaces[interfaceName].details = { ...state.system_info.network[interfaceName] }
|
||||
|
||||
if (state.system_info?.network && interfaceName in (state.system_info?.network ?? {})) {
|
||||
interfaces[interfaceName].details = { ...state.system_info.network[interfaceName] }
|
||||
}
|
||||
}
|
||||
}
|
||||
})
|
||||
|
||||
Reference in new issue
Block a user