1
0
mirror of https://github.com/MisskeyIO/misskey synced 2024-12-24 11:38:20 +09:00
MisskeyIO/src/web/app/desktop/scripts/input-dialog.js

13 lines
331 B
JavaScript
Raw Normal View History

2017-03-18 20:05:11 +09:00
import * as riot from 'riot';
2017-02-18 17:43:31 +09:00
2017-03-18 20:05:11 +09:00
export default (title, placeholder, defaultValue, onOk, onCancel) => {
2017-02-18 17:43:31 +09:00
const dialog = document.body.appendChild(document.createElement('mk-input-dialog'));
return riot.mount(dialog, {
title: title,
placeholder: placeholder,
'default': defaultValue,
onOk: onOk,
onCancel: onCancel
});
};