Skip to content

Commit

Permalink
iframe panel
Browse files Browse the repository at this point in the history
closes #9
  • Loading branch information
t2t2 committed Oct 20, 2017
1 parent 89feb88 commit 18a9550
Show file tree
Hide file tree
Showing 3 changed files with 51 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/components/panel-list.vue
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,12 @@
description: 'Manage stream & recording status',
icon: 'movie',
type: 'Stream'
},
{
name: 'Frame',
description: 'Embed any webpage',
icon: 'web_asset',
type: 'Iframe'
}
]
Expand Down
43 changes: 43 additions & 0 deletions src/components/panels/iframe.vue
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
<template>
<panel-wrapper :content-class="['panel-iframe']">
<template slot="name">Frame</template>
<iframe
:src="url"
frameborder="0"
style="width: 100%; height: 100%;"
></iframe>

<div slot="settings">
<label>
URKL
<div class="input-group">
<input
type="text"
v-model="url"
>
</div>
</label>
</div>
</panel-wrapper>
</template>

<script>
import panelMixin from '../mixins/panel'
export default {
mixins: [panelMixin],
computed: {
url: {
get() {
if (this.settings.url) {
return this.settings.url
}
return 'about:blank'
},
set(value) {
this.setSetting('url', value)
}
}
}
}
</script>
2 changes: 2 additions & 0 deletions src/components/panels/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,15 @@
import panelMixin from '../mixins/panel'

import Grid from './grid'
import Iframe from './iframe'
import Invalid from './invalid'
import Scenes from './scenes'
import Sources from './sources'
import Stream from './stream'

const components = {
Grid,
Iframe,
Invalid,
Scenes,
Sources,
Expand Down

0 comments on commit 18a9550

Please sign in to comment.