-
Notifications
You must be signed in to change notification settings - Fork 98
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
11 changed files
with
179 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
<template> | ||
<svg viewBox="0 0 1024 1024"> | ||
<path | ||
d="M153.770667 517.558857l200.387047-197.241905L302.86019 268.190476 48.761905 518.290286l254.439619 243.614476 50.590476-52.833524-200.021333-191.512381zM658.285714 320.316952L709.583238 268.190476l254.098286 250.09981L709.241905 761.904762l-50.590476-52.833524 200.021333-191.512381L658.285714 320.316952z m-112.981333-86.186666L393.99619 785.554286l70.534096 19.358476 151.30819-551.399619-70.534095-19.358476z" | ||
v-bind="$attrs" | ||
></path> | ||
</svg> | ||
</template> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
48 changes: 48 additions & 0 deletions
48
frontend/src/views/ProfilesView/components/MixinAndScriptConfig.vue
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
<script setup lang="ts"> | ||
import { ref } from 'vue' | ||
import { useI18n } from 'vue-i18n' | ||
import { type ProfileType } from '@/stores' | ||
import { MixinConfigDefaults, ScriptConfigDefaults } from '@/constant' | ||
const model = defineModel<{ | ||
mixin: ProfileType['mixinConfig'] | ||
script: ProfileType['scriptConfig'] | ||
}>({ | ||
default: { | ||
mixin: MixinConfigDefaults(), | ||
script: ScriptConfigDefaults() | ||
} | ||
}) | ||
const { t } = useI18n() | ||
const activeTab = ref('mixin') | ||
const tabItems = [ | ||
{ key: 'mixin', tab: 'profile.mixinSettings.name' }, | ||
{ key: 'script', tab: 'profile.scriptSettings.name' } | ||
] | ||
const MixinPriorityOptions = [ | ||
{ label: 'profile.mixinSettings.mixin', value: 'mixin' }, | ||
{ label: 'profile.mixinSettings.gui', value: 'gui' } | ||
] | ||
</script> | ||
|
||
<template> | ||
<Tabs v-model:active-key="activeTab" :items="tabItems"> | ||
<template #mixin> | ||
<div class="form-item"> | ||
{{ t('profile.mixinSettings.priority') }} | ||
<Radio v-model="model.mixin.priority" :options="MixinPriorityOptions" /> | ||
</div> | ||
<CodeViewer v-model="model.mixin.config" lang="yaml" editable /> | ||
</template> | ||
<template #script> | ||
<CodeViewer v-model="model.script.code" lang="javascript" editable /> | ||
</template> | ||
</Tabs> | ||
</template> | ||
|
||
<style lang="less" scoped></style> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters