@budibase/bbui 2.8.1 → 2.8.2-alpha.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@budibase/bbui",
3
3
  "description": "A UI solution used in the different Budibase projects.",
4
- "version": "2.8.1",
4
+ "version": "2.8.2-alpha.0",
5
5
  "license": "MPL-2.0",
6
6
  "svelte": "src/index.js",
7
7
  "module": "dist/bbui.es.js",
@@ -38,8 +38,8 @@
38
38
  ],
39
39
  "dependencies": {
40
40
  "@adobe/spectrum-css-workflow-icons": "1.2.1",
41
- "@budibase/shared-core": "2.8.1",
42
- "@budibase/string-templates": "2.8.1",
41
+ "@budibase/shared-core": "2.8.2-alpha.0",
42
+ "@budibase/string-templates": "2.8.2-alpha.0",
43
43
  "@spectrum-css/accordion": "3.0.24",
44
44
  "@spectrum-css/actionbutton": "1.0.1",
45
45
  "@spectrum-css/actiongroup": "1.0.1",
@@ -104,5 +104,5 @@
104
104
  }
105
105
  }
106
106
  },
107
- "gitHead": "84eb8be81f1c22165254f5ea0bd0022a59956f22"
107
+ "gitHead": "7d575c7f3e9c5b8ec383e0a14041ba55c70fe5ac"
108
108
  }
@@ -1,3 +1,7 @@
1
+ <script context="module">
2
+ export const keepOpen = Symbol("keepOpen")
3
+ </script>
4
+
1
5
  <script>
2
6
  import "@spectrum-css/dialog/dist/index-vars.css"
3
7
  import { getContext } from "svelte"
@@ -30,7 +34,7 @@
30
34
 
31
35
  async function secondary(e) {
32
36
  loading = true
33
- if (!secondaryAction || (await secondaryAction(e)) !== false) {
37
+ if (!secondaryAction || (await secondaryAction(e)) !== keepOpen) {
34
38
  hide()
35
39
  }
36
40
  loading = false
@@ -38,7 +42,7 @@
38
42
 
39
43
  async function confirm() {
40
44
  loading = true
41
- if (!onConfirm || (await onConfirm()) !== false) {
45
+ if (!onConfirm || (await onConfirm()) !== keepOpen) {
42
46
  hide()
43
47
  }
44
48
  loading = false
@@ -46,7 +50,7 @@
46
50
 
47
51
  async function close() {
48
52
  loading = true
49
- if (!onCancel || (await onCancel()) !== false) {
53
+ if (!onCancel || (await onCancel()) !== keepOpen) {
50
54
  cancel()
51
55
  }
52
56
  loading = false
package/src/index.js CHANGED
@@ -42,7 +42,7 @@ export { default as MenuSection } from "./Menu/Section.svelte"
42
42
  export { default as MenuSeparator } from "./Menu/Separator.svelte"
43
43
  export { default as MenuItem } from "./Menu/Item.svelte"
44
44
  export { default as Modal } from "./Modal/Modal.svelte"
45
- export { default as ModalContent } from "./Modal/ModalContent.svelte"
45
+ export { default as ModalContent, keepOpen } from "./Modal/ModalContent.svelte"
46
46
  export { default as NotificationDisplay } from "./Notification/NotificationDisplay.svelte"
47
47
  export { default as Notification } from "./Notification/Notification.svelte"
48
48
  export { default as SideNavigation } from "./SideNavigation/Navigation.svelte"