diff --git a/lerna.json b/lerna.json index cae3496514..c7bf7966c6 100644 --- a/lerna.json +++ b/lerna.json @@ -1,5 +1,5 @@ { - "version": "1.1.29-alpha.1", + "version": "1.1.31", "npmClient": "yarn", "packages": [ "packages/*" @@ -15,4 +15,4 @@ ] } } -} +} \ No newline at end of file diff --git a/package.json b/package.json index 0c7d3989a2..4c24e0025b 100644 --- a/package.json +++ b/package.json @@ -26,7 +26,7 @@ "build": "lerna run build", "build:dev": "lerna run prebuild && tsc --build --watch --preserveWatchOutput", "release": "lerna publish ${RELEASE_VERSION_TYPE:-patch} --yes --force-publish && yarn release:pro", - "release:develop": "lerna publish prerelease --yes --force-publish --dist-tag develop && yarn release:pro:develop", + "release:develop": "lerna publish prerelease --yes --force-publish --dist-tag develop --exact && yarn release:pro:develop", "release:pro": "bash scripts/pro/release.sh", "release:pro:develop": "bash scripts/pro/release.sh develop", "restore": "yarn run clean && yarn run bootstrap && yarn run build", @@ -85,4 +85,4 @@ "install:pro": "bash scripts/pro/install.sh", "dep:clean": "yarn clean && yarn bootstrap" } -} +} \ No newline at end of file diff --git a/packages/backend-core/package.json b/packages/backend-core/package.json index a2f005d646..80ded6d8a0 100644 --- a/packages/backend-core/package.json +++ b/packages/backend-core/package.json @@ -1,6 +1,6 @@ { "name": "@budibase/backend-core", - "version": "1.1.29-alpha.1", + "version": "1.1.31", "description": "Budibase backend core libraries used in server and worker", "main": "dist/src/index.js", "types": "dist/src/index.d.ts", @@ -20,7 +20,7 @@ "test:watch": "jest --watchAll" }, "dependencies": { - "@budibase/types": "^1.1.29-alpha.1", + "@budibase/types": "^1.1.31", "@techpass/passport-openidconnect": "0.3.2", "aws-sdk": "2.1030.0", "bcrypt": "5.0.1", @@ -80,4 +80,4 @@ "typescript": "4.7.3" }, "gitHead": "d1836a898cab3f8ab80ee6d8f42be1a9eed7dcdc" -} +} \ No newline at end of file diff --git a/packages/backend-core/src/logging.ts b/packages/backend-core/src/logging.ts index 8eda15ac79..3fc79a5fe7 100644 --- a/packages/backend-core/src/logging.ts +++ b/packages/backend-core/src/logging.ts @@ -15,11 +15,22 @@ export function logAlert(message: string, e?: any) { console.error(`bb-alert: ${message} ${errorJson}`) } +export function logAlertWithInfo( + message: string, + db: string, + id: string, + error: any +) { + message = `${message} - db: ${db} - doc: ${id} - error: ` + logAlert(message, error) +} + export function logWarn(message: string) { console.warn(`bb-warn: ${message}`) } export default { logAlert, + logAlertWithInfo, logWarn, } diff --git a/packages/bbui/package.json b/packages/bbui/package.json index 527d823617..d8ad85bdc8 100644 --- a/packages/bbui/package.json +++ b/packages/bbui/package.json @@ -1,7 +1,7 @@ { "name": "@budibase/bbui", "description": "A UI solution used in the different Budibase projects.", - "version": "1.1.29-alpha.1", + "version": "1.1.31", "license": "MPL-2.0", "svelte": "src/index.js", "module": "dist/bbui.es.js", @@ -38,7 +38,7 @@ ], "dependencies": { "@adobe/spectrum-css-workflow-icons": "^1.2.1", - "@budibase/string-templates": "^1.1.29-alpha.1", + "@budibase/string-templates": "^1.1.31", "@spectrum-css/actionbutton": "^1.0.1", "@spectrum-css/actiongroup": "^1.0.1", "@spectrum-css/avatar": "^3.0.2", @@ -86,4 +86,4 @@ "svelte-portal": "^1.0.0" }, "gitHead": "d1836a898cab3f8ab80ee6d8f42be1a9eed7dcdc" -} +} \ No newline at end of file diff --git a/packages/bbui/src/ActionButton/ActionButton.svelte b/packages/bbui/src/ActionButton/ActionButton.svelte index 53ba6c7e51..cfc810807e 100644 --- a/packages/bbui/src/ActionButton/ActionButton.svelte +++ b/packages/bbui/src/ActionButton/ActionButton.svelte @@ -84,6 +84,7 @@ } :global([dir="ltr"] .spectrum-ActionButton .spectrum-Icon) { margin-left: 0; + transition: color ease-out 130ms; } .is-selected:not(.spectrum-ActionButton--emphasized) { background: var(--spectrum-global-color-gray-300); @@ -92,4 +93,10 @@ padding: 0; min-width: 0; } + .spectrum-ActionButton--quiet { + padding: 0 8px; + } + .is-selected:not(.emphasized) .spectrum-Icon { + color: var(--spectrum-global-color-gray-900); + } diff --git a/packages/bbui/src/Form/Core/Picker.svelte b/packages/bbui/src/Form/Core/Picker.svelte index fc9f801be2..cdaf00aded 100644 --- a/packages/bbui/src/Form/Core/Picker.svelte +++ b/packages/bbui/src/Form/Core/Picker.svelte @@ -87,10 +87,15 @@ on:mousedown={onClick} > {#if fieldIcon} - + {/if} + {#if fieldColour} + + + + {/if} {/if} - {#if fieldColour} - - - - {/if} onSelectOption(getOptionValue(option, idx))} > {#if getOptionIcon(option, idx)} - + {/if} + {#if getOptionColour(option, idx)} + + + + {/if} {getOptionLabel(option, idx)} @@ -180,11 +185,6 @@ > - {#if getOptionColour(option, idx)} - - - - {/if} {/each} {/if} @@ -209,6 +209,9 @@ width: 100%; box-shadow: none; } + .spectrum-Picker-label.auto-width { + margin-right: var(--spacing-xs); + } .spectrum-Picker-label:not(.auto-width) { overflow: hidden; text-overflow: ellipsis; @@ -221,16 +224,16 @@ .spectrum-Picker-label.auto-width.is-placeholder { padding-right: 2px; } + .auto-width .spectrum-Menu-item { + padding-right: var(--spacing-xl); + } /* Icon and colour alignment */ .spectrum-Menu-checkmark { align-self: center; margin-top: 0; } - .option-colour { - padding-left: 8px; - } - .option-icon { + .option-extra { padding-right: 8px; } diff --git a/packages/bbui/src/StatusLight/StatusLight.svelte b/packages/bbui/src/StatusLight/StatusLight.svelte index a0c72443a6..5b7257891f 100644 --- a/packages/bbui/src/StatusLight/StatusLight.svelte +++ b/packages/bbui/src/StatusLight/StatusLight.svelte @@ -18,11 +18,16 @@ export let disabled = false export let active = false export let color = null + export let square = false + export let hoverable = false
diff --git a/packages/bbui/src/Table/AttachmentRenderer.svelte b/packages/bbui/src/Table/AttachmentRenderer.svelte index 97ce1394cc..4dff22aef8 100644 --- a/packages/bbui/src/Table/AttachmentRenderer.svelte +++ b/packages/bbui/src/Table/AttachmentRenderer.svelte @@ -1,5 +1,4 @@ -{#if !hideIcon} -
- -
+{#if !hideIcon && updateAvailable} + + Update available + {/if} {title || ""}
- {#if showExpandIcon} + {#if expandable} {/if} + {#if showCloseButton} + + {/if}
diff --git a/packages/builder/src/components/portal/overview/automation/HistoryDetailsPanel.svelte b/packages/builder/src/components/portal/overview/automation/HistoryDetailsPanel.svelte index e32669067e..370688e798 100644 --- a/packages/builder/src/components/portal/overview/automation/HistoryDetailsPanel.svelte +++ b/packages/builder/src/components/portal/overview/automation/HistoryDetailsPanel.svelte @@ -1,5 +1,5 @@
@@ -15,24 +14,17 @@ options={$sortedScreens} getOptionLabel={x => x.routing.route} getOptionValue={x => x._id} - getOptionIcon={x => (x.routing.homeScreen ? "Home" : "WebPage")} getOptionColour={x => RoleUtils.getRoleColour(x.routing.roleId)} value={$store.selectedScreenId} on:change={e => store.actions.screens.select(e.detail)} + quiet + autoWidth />
{#if $store.clientFeatures.devicePreview} {/if} -
@@ -59,6 +51,7 @@ justify-content: space-between; align-items: flex-start; gap: var(--spacing-l); + margin: 0 2px; } .header-left, .header-right { @@ -69,7 +62,8 @@ gap: var(--spacing-l); } .header-left :global(.spectrum-Picker) { - width: 250px; + font-weight: 600; + color: var(--spectrum-global-color-gray-900); } .content { flex: 1 1 auto; diff --git a/packages/builder/src/pages/builder/app/[application]/design/[screenId]/_components/AppPreview.svelte b/packages/builder/src/pages/builder/app/[application]/design/[screenId]/_components/AppPreview.svelte index abb956c9d3..304d41ad19 100644 --- a/packages/builder/src/pages/builder/app/[application]/design/[screenId]/_components/AppPreview.svelte +++ b/packages/builder/src/pages/builder/app/[application]/design/[screenId]/_components/AppPreview.svelte @@ -3,6 +3,7 @@ import { onMount, onDestroy } from "svelte" import { store, + selectedComponent, selectedScreen, selectedLayout, currentAsset, @@ -14,6 +15,7 @@ Layout, Heading, Body, + Icon, notifications, } from "@budibase/bbui" import ErrorSVG from "@budibase/frontend-core/assets/error.svg?raw" @@ -96,6 +98,11 @@ $: json = JSON.stringify(previewData) $: refreshContent(json) + // Determine if the add component menu is active + $: isAddingComponent = $isActive( + `./components/${$selectedComponent?._id}/new` + ) + // Update the iframe with the builder info to render the correct preview const refreshContent = message => { if (iframe) { @@ -219,6 +226,16 @@ idToDelete = null } + const toggleAddComponent = () => { + if (isAddingComponent) { + $goto(`../${$selectedScreen._id}/components/${$selectedComponent?._id}`) + } else { + $goto( + `../${$selectedScreen._id}/components/${$selectedComponent?._id}/new` + ) + } + } + onMount(() => { window.addEventListener("message", receiveMessage) if (!$store.clientFeatures.messagePassing) { @@ -282,6 +299,13 @@ class:tablet={$store.previewDevice === "tablet"} class:mobile={$store.previewDevice === "mobile"} /> +
+ Component +
diff --git a/packages/builder/src/pages/builder/app/[application]/design/[screenId]/_components/DevicePreviewSelect.svelte b/packages/builder/src/pages/builder/app/[application]/design/[screenId]/_components/DevicePreviewSelect.svelte index 9f9447daee..870f801336 100644 --- a/packages/builder/src/pages/builder/app/[application]/design/[screenId]/_components/DevicePreviewSelect.svelte +++ b/packages/builder/src/pages/builder/app/[application]/design/[screenId]/_components/DevicePreviewSelect.svelte @@ -3,18 +3,21 @@ import { store } from "builderStore" - + store.actions.preview.setDevice("desktop")} /> store.actions.preview.setDevice("tablet")} /> store.actions.preview.setDevice("mobile")} diff --git a/packages/builder/src/pages/builder/app/[application]/design/[screenId]/components/[componentId]/_components/navigation/ComponentListPanel.svelte b/packages/builder/src/pages/builder/app/[application]/design/[screenId]/components/[componentId]/_components/navigation/ComponentListPanel.svelte index 1bb4e3d9cd..ab776dea5d 100644 --- a/packages/builder/src/pages/builder/app/[application]/design/[screenId]/components/[componentId]/_components/navigation/ComponentListPanel.svelte +++ b/packages/builder/src/pages/builder/app/[application]/design/[screenId]/components/[componentId]/_components/navigation/ComponentListPanel.svelte @@ -9,7 +9,7 @@ import { setContext } from "svelte" import DNDPositionIndicator from "./DNDPositionIndicator.svelte" import { DropPosition } from "./dndStore" - import { notifications } from "@budibase/bbui" + import { notifications, Button } from "@budibase/bbui" let scrollRef @@ -24,7 +24,7 @@ let newOffsets = {} // Calculate left offset - const offsetX = bounds.left + bounds.width + scrollLeft - 58 + const offsetX = bounds.left + bounds.width + scrollLeft - 36 if (offsetX > sidebarWidth) { newOffsets.left = offsetX - sidebarWidth } else { @@ -71,13 +71,10 @@ }) - $goto("../new")} - showExpandIcon - borderRight -> + +
+ +