Biblioteca de JavaScript de Toast/popup/modal/diálogo-JSFrame. js
| Autor: | riversun |
|---|---|
| Views Total: | 367 |
| Sitio oficial: | Ir a la web |
| Actualizado: | January 8, 2019 |
| Licencia: | MIT |
Vista prévia
Descripción
JSFrame. js es una biblioteca de JavaScript multifuncional que se utiliza para crear ventanas flotantes, popups modales e incluso notificaciones tostadas con estilos personalizados.
Más características
- Fácil de estilo usando su propio CSS.
- Ajustable y arrastrable.
- Soporta contenido HTML y iFrame.
¿Cómo funciona?
Instale & descargar.
# NPM $ npm install jsframe.js --save
Importe el ' jsframe. js ' en el documento.
<script src="/path/to/jsframe.js"></script>
Cree una nueva instancia de jsframe.
const myWindow = new JSFrame();
Cree una ventana emergente con los siguientes parámetros:
const myPopup = myWindow.create({
// unique name
name: 'my-window-name',
// window title
title: 'Window0',
// position
left: 20,
top: 20,
// width/height
width: 320,
height: 220,
// min width/height
minWidth: 160,
minHeight: 100,
// enable draggable
movable: true,
// enable resizable
resizable: true,
// custom styles
style: {
backgroundColor: 'rgba(220,220,220,0.8)',
overflow: 'auto',
},
// HTML content to present
html: 'Contents',
// or iframe content
url: 'content01.html',
// callback
urlLoaded: (frame) = {}
});





