# j-iFrameViewer

> This component show a layer (over the content) with a iframe.

Framework: jcomponent20
Product: jComponent 20 (jcomponent@20)
Language: en
Content-SHA256: 15a4655235b27c69c4d83e1d1afa3c91d776ea9b68087951638028c4f0ead584
Snapshot: c0700e321579725c5cf4f5ace1ad7d2866d1b4f93c24a63c0b41b6b7998e976c
Sources: components@910ed1a86f6e72b4f031d3ad0dc7844f9fc5cb8e
Review: not-recorded

This component show a layer (over the content) with a iframe.

- singleton

__Options__:

- `name {String}` a label name to header
- `url {String}` URL address for iframe
- `ready {Function(iframe)}` optional, `onready` handler
- `close {Function}` optional, `onclose` handler
- `esc {Boolean}` can close the component with pressing of `ESC` key (defualt: `false`)
- `width {String}` a width of iframe (default: `100%`)
- `margin {Number}` a vertical (top/bottom) margin (default: `0`)
- __NEW__: `html {String}` a custom HTML content for the iframe

Use it with `<ui-component name="iframeviewer">`. When the component is not loaded yet, jComponent downloads it on first use from the address in `DEF.fallback` (the Componentator CDN by default). Author: Peter Širka. Source: the Componentator components repository, MIT license.

```html example.html
<ui-component name="iframeviewer"></ui-component>

<script>
	SETTER(true, 'iframeviewer/open', { url: 'https://www.totaljs.com', name: 'Total.js', esc: true });
</script>
```
