thedesk/src/components/AddColumn/PublicTimeline.vue

36 lines
754 B
Vue
Raw Normal View History

<template>
<div>
<form @submit.prevent="addTL">
<BaseInputText placeholder="e.g:mstdn.jp" v-model="instance"/>
<BaseButton
type="submit"
class="primary fill"
style="--font-size:.8em;"
:disabled="!hasDomain"
>Add Column</BaseButton>
</form>
</div>
</template>
<script lang="ts">
2019-04-25 00:52:40 +09:00
import { ipcRenderer } from "electron"
import { Component, Vue } from "vue-property-decorator"
@Component
2019-04-27 06:33:15 +09:00
export default class PublicTimeline extends Vue {
public instance: string = ""
2019-04-24 17:15:42 +09:00
public get hasDomain() {
2019-04-25 00:52:40 +09:00
return this.instance != ""
}
2019-04-23 23:42:07 +09:00
public addTL() {
ipcRenderer.send("add-timeline", this.instance, 'no-auth')
2019-04-24 17:31:18 +09:00
2019-04-25 00:52:40 +09:00
this.instance = ""
2019-04-24 01:07:20 +09:00
}
}
</script>
<style scoped lang="postcss">
</style>