2.0.12 • Published 6 years ago
the-frame v2.0.12
the-frame
iFrame of the-components
Installation
$ npm install the-frame --save
Usage
'use strict'
import React from 'react'
import { TheFrame, TheFrameStyle } from 'the-frame'
import { TheSpinStyle } from 'the-spin'
class ExampleComponent extends React.PureComponent {
render () {
return (
<div>
<TheSpinStyle/>
<TheFrameStyle/>
<TheFrame src='./example-html.html'
style={{with: '200px', height: '200px', overflow: 'auto'}}
/>
<hr/>
<TheFrame src='./example-html.html'
style={{with: '200px', height: '200px', overflow: 'auto'}}
spinning
/>
<hr/>
<h3>Embed</h3>
<TheFrame src='./example-html.html'
embed
style={{with: '200px', height: '200px', overflow: 'auto'}}
/>
</div>
)
}
}
export default ExampleComponent
Components
TheFrame
iFrame of the-components
Props
Name | Type | Description | Default |
---|---|---|---|
alt | string | Alt text | 'Page Not Found' |
embed | bool | Enbed source content as dynamic html | false |
onLoad | func | Handler for Load | null |
spinning | bool | Spinning or not | false |
src | string | Source URL | null |
TheFrameStyle
Style for TheFrame
Props
Name | Type | Description | Default |
---|---|---|---|
options | object | Style options | {} |
License
This software is released under the MIT License.