1.0.82 • Published 3 years ago
@prostreyd/vue-dialog v1.0.82
Vue dialog modal box (alert, prompt, confirm)
A dialog for alerts, prompts, and confirms that is lightweight and based on promises with Typescript support (only supports vue 2).
Install
$ npm install --save @prostreyd/vue-dialogQuick Start Usage
//in main.ts or main.js
import Vue from 'vue'
import VuejsDialogBox from "@prostreyd/vue-dialog";
import "@prostreyd/vue-dialog/dist/style.css";
Vue.use(VuejsDialogBox);Alert
await this.$dialogBox.title({
  // bottom default values
  title: "This is alert", // String. Title of dialog
  okText: "Ok" // String. Confirm button text
});
//...your codePrompt
const text = await this.$dialogBox.prompt({
  // bottom default values
  title: "Write something", // String. Title of dialog.
  okText: "Yes", // String. Confirm button text.
  cancelText: "No", // String. Cancel button text.
  placeholder: "", // String. Input placeholder text.
  allowConfirmEmptyString: false, // Boolean. Is it possible to click on the confirm button if the text is empty. 
});
//...your codeConfirm
const ok = await this.$dialogBox.confirm({
  // bottom default values
  title: "Are you sure?", // String. Title of dialog.
  okText: "Yes", // String. Confirm button text.
  cancelText: "No", // String. Cancel button text.
});
if (ok) {
  //...your code
}1.0.82
3 years ago
1.0.81
3 years ago
1.0.8
3 years ago
1.0.7
3 years ago
1.0.6
3 years ago
1.0.5
3 years ago
1.0.3
3 years ago
1.0.2
3 years ago
1.0.1
3 years ago
1.0.0
3 years ago
0.2.3
3 years ago
0.2.2
3 years ago
0.2.1
3 years ago
0.2.0
3 years ago
0.1.9
3 years ago
0.1.8
3 years ago
0.1.7
3 years ago
0.1.6
3 years ago
0.1.5
3 years ago
0.1.4
3 years ago
0.1.3
3 years ago
0.1.2
3 years ago
0.1.1
3 years ago
0.1.0
3 years ago