Modal windows

29-11-2018
```typescript let form = new S.Form() form.addCell("Name", true, new S.TextInput()) var modal = S.buildModalWindow(T("@@Example"), form, "withPadding") modal.addButton({ text: T("@@Cancelar"), className: "transparent", onclick: () => modal.close() }) modal.addButton({ text: T("@@Aceptar"), className: "highlighted", onclick: () => modal.close() }) modal.show(); ``` ![](/open/scl/uploads/62jXleVRJ8mvm1100CZm.png) ```typescript let body = S.create("div", null, null, "This one has a spin button") var modal = S.buildModalWindow(T("@@Example"), body, "withPadding") modal.addButton({ text: T("@@Cancelar"), className: "transparent", onclick: () => modal.close() }) modal.addSpinButton(T("@@Aceptar"), b => { b.startSpinner() }) modal.show(); ``` ![](/open/scl/uploads/3ABGD3sK0qd4fbafxjCK.png) A message box: ```typescript S.showMsgBox("Example", "This is a message", "withPadding") ``` ![](/open/scl/uploads/sFJA4VBUVDKRzF7BomIb.png) A confirm dialog: ```typescript S.confirm("Confirm action", "Proceed?", modal => modal.close()) ``` ![](/open/scl/uploads/8UW2c8BGPD0D4S2Cjq9K.png)