@budibase/bbui 2.6.19-alpha.0 → 2.6.19

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.6.19-alpha.0",
4
+ "version": "2.6.19",
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.6.19-alpha.0",
42
- "@budibase/string-templates": "2.6.19-alpha.0",
41
+ "@budibase/shared-core": "^2.6.19",
42
+ "@budibase/string-templates": "^2.6.19",
43
43
  "@spectrum-css/accordion": "3.0.24",
44
44
  "@spectrum-css/actionbutton": "1.0.1",
45
45
  "@spectrum-css/actiongroup": "1.0.1",
@@ -90,5 +90,5 @@
90
90
  "resolutions": {
91
91
  "loader-utils": "1.4.1"
92
92
  },
93
- "gitHead": "82e867c0f5b41fe3af88333effeb88f29b8b4d23"
93
+ "gitHead": "ef8ac7e2e16f83f8d7475d310302cd22aa57fdd2"
94
94
  }
@@ -2,7 +2,6 @@
2
2
  import "@spectrum-css/button/dist/index-vars.css"
3
3
  import Tooltip from "../Tooltip/Tooltip.svelte"
4
4
 
5
- export let type
6
5
  export let disabled = false
7
6
  export let size = "M"
8
7
  export let cta = false
@@ -22,7 +21,6 @@
22
21
 
23
22
  <button
24
23
  {id}
25
- {type}
26
24
  class:spectrum-Button--cta={cta}
27
25
  class:spectrum-Button--primary={primary}
28
26
  class:spectrum-Button--secondary={secondary}
@@ -75,7 +73,6 @@
75
73
  button {
76
74
  position: relative;
77
75
  }
78
-
79
76
  .spectrum-Button-label {
80
77
  white-space: nowrap;
81
78
  overflow: hidden;
@@ -1,7 +1,7 @@
1
1
  <script>
2
2
  import Icon from "../Icon/Icon.svelte"
3
3
  import { getContext, onMount } from "svelte"
4
- import ErrorMessage from "./ErrorMessage.svelte"
4
+ import { slide } from "svelte/transition"
5
5
 
6
6
  export let disabled = false
7
7
  export let error = null
@@ -55,7 +55,9 @@
55
55
  {/if}
56
56
  </div>
57
57
  {#if error}
58
- <ErrorMessage {error} />
58
+ <div transition:slide|local={{ duration: 130 }} class="error-message">
59
+ {error}
60
+ </div>
59
61
  {/if}
60
62
  </div>
61
63
 
@@ -108,6 +110,13 @@
108
110
  .field {
109
111
  flex: 1 1 auto;
110
112
  }
113
+ .error-message {
114
+ background: var(--spectrum-global-color-red-400);
115
+ color: white;
116
+ font-size: 14px;
117
+ padding: 6px 16px;
118
+ font-weight: 500;
119
+ }
111
120
  .error-icon {
112
121
  flex: 0 0 auto;
113
122
  }
@@ -4,4 +4,3 @@ export { default as FancySelect } from "./FancySelect.svelte"
4
4
  export { default as FancyButton } from "./FancyButton.svelte"
5
5
  export { default as FancyForm } from "./FancyForm.svelte"
6
6
  export { default as FancyButtonRadio } from "./FancyButtonRadio.svelte"
7
- export { default as ErrorMessage } from "./ErrorMessage.svelte"
@@ -18,14 +18,10 @@
18
18
  export let ignoreTimezones = false
19
19
  export let time24hr = false
20
20
  export let range = false
21
- export let flatpickr
22
- export let useKeyboardShortcuts = true
23
-
24
21
  const dispatch = createEventDispatcher()
25
22
  const flatpickrId = `${uuid()}-wrapper`
26
-
27
23
  let open = false
28
- let flatpickrOptions
24
+ let flatpickr, flatpickrOptions
29
25
 
30
26
  // Another classic flatpickr issue. Errors were randomly being thrown due to
31
27
  // flatpickr internal code. Making sure that "destroy" is a valid function
@@ -63,8 +59,6 @@
63
59
  dispatch("change", timestamp.toISOString())
64
60
  }
65
61
  },
66
- onOpen: () => dispatch("open"),
67
- onClose: () => dispatch("close"),
68
62
  }
69
63
 
70
64
  $: redrawOptions = {
@@ -119,16 +113,12 @@
119
113
 
120
114
  const onOpen = () => {
121
115
  open = true
122
- if (useKeyboardShortcuts) {
123
- document.addEventListener("keyup", clearDateOnBackspace)
124
- }
116
+ document.addEventListener("keyup", clearDateOnBackspace)
125
117
  }
126
118
 
127
119
  const onClose = () => {
128
120
  open = false
129
- if (useKeyboardShortcuts) {
130
- document.removeEventListener("keyup", clearDateOnBackspace)
131
- }
121
+ document.removeEventListener("keyup", clearDateOnBackspace)
132
122
 
133
123
  // Manually blur all input fields since flatpickr creates a second
134
124
  // duplicate input field.
@@ -1,19 +0,0 @@
1
- <script>
2
- import { slide } from "svelte/transition"
3
-
4
- export let error = null
5
- </script>
6
-
7
- <div transition:slide|local={{ duration: 130 }} class="error-message">
8
- {error}
9
- </div>
10
-
11
- <style>
12
- .error-message {
13
- background: var(--spectrum-global-color-red-400);
14
- color: white;
15
- font-size: 14px;
16
- padding: 6px 16px;
17
- font-weight: 500;
18
- }
19
- </style>