-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
1 parent
d7fc07f
commit d678210
Showing
11 changed files
with
193 additions
and
85 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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,69 @@ | ||
<template> | ||
<el-input | ||
:model-value="JSON.stringify(values)" | ||
:disabled="true" | ||
> | ||
<template #append> | ||
<el-button :icon="Eye" @click="this.isOpen = true" /> | ||
</template> | ||
</el-input> | ||
|
||
<el-drawer | ||
v-if="isOpen" | ||
v-model="isOpen" | ||
:title="root" | ||
destroy-on-close | ||
size="" | ||
:append-to-body="true" | ||
> | ||
<template #header> | ||
<code>{{ root }}</code> | ||
</template> | ||
<el-form label-position="top"> | ||
<task-editor | ||
ref="editor" | ||
section="conditions" | ||
:model-value="taskYaml" | ||
@update:model-value="onInput" | ||
/> | ||
</el-form> | ||
|
||
<template #footer> | ||
<el-button :icon="ContentSave" @click="isOpen = false" type="primary"> | ||
{{ $t('save') }} | ||
</el-button> | ||
</template> | ||
</el-drawer> | ||
</template> | ||
|
||
<script setup> | ||
import Eye from "vue-material-design-icons/Eye.vue"; | ||
import ContentSave from "vue-material-design-icons/ContentSave.vue"; | ||
</script> | ||
|
||
<script> | ||
import Task from "./Task" | ||
import YamlUtils from "../../../utils/yamlUtils"; | ||
import TaskEditor from "../TaskEditor.vue" | ||
export default { | ||
mixins: [Task], | ||
components: {TaskEditor}, | ||
data() { | ||
return { | ||
isOpen: false, | ||
}; | ||
}, | ||
computed: { | ||
taskYaml() { | ||
return YamlUtils.stringify(this.modelValue); | ||
} | ||
}, | ||
methods: { | ||
onInput(value) { | ||
this.$emit("update:modelValue", YamlUtils.parse(value)); | ||
}, | ||
}, | ||
}; | ||
</script> | ||
|
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
Oops, something went wrong.