From 410d8700e4555c414b50f19b0d626758e030ce2b Mon Sep 17 00:00:00 2001 From: Pedro Silva Date: Mon, 5 Jun 2023 18:42:44 +0100 Subject: [PATCH 01/17] Add more tests for user settings --- qa-core/src/internal-api/api/apis/SelfAPI.ts | 18 +++++++++++++++--- .../tests/users/userManagement.spec.ts | 16 ++++++++++++++++ 2 files changed, 31 insertions(+), 3 deletions(-) diff --git a/qa-core/src/internal-api/api/apis/SelfAPI.ts b/qa-core/src/internal-api/api/apis/SelfAPI.ts index cd162053a1..022a438249 100644 --- a/qa-core/src/internal-api/api/apis/SelfAPI.ts +++ b/qa-core/src/internal-api/api/apis/SelfAPI.ts @@ -14,10 +14,11 @@ export default class SelfAPI extends BaseAPI { return [response, json] } - async changeSelfPassword(body: Partial): Promise<[Response, User]> { + async changeSelfPassword(): Promise<[Response, User]> { + const body = { + password: "newPassword", + } const [response, json] = await this.post(`/global/self`, body) - expect(json._id).toEqual(body._id) - expect(json._rev).not.toEqual(body._rev) return [response, json] } @@ -26,4 +27,15 @@ export default class SelfAPI extends BaseAPI { expect(json).toHaveProperty("apiKey") return json } + + async changeUserInfo(body: Partial): Promise<[Response, User]> { + const [response, json] = await this.post(`/global/self`, body) + return [response, json] + } + + async generateApiKey(): Promise<[Response, ApiKeyResponse]> { + const [response, json] = await this.post(`/global/self/api_key`) + expect(json).toHaveProperty("apiKey") + return [response, json] + } } diff --git a/qa-core/src/internal-api/tests/users/userManagement.spec.ts b/qa-core/src/internal-api/tests/users/userManagement.spec.ts index 28096c08c9..d1bada05c0 100644 --- a/qa-core/src/internal-api/tests/users/userManagement.spec.ts +++ b/qa-core/src/internal-api/tests/users/userManagement.spec.ts @@ -87,4 +87,20 @@ describe("Internal API - User Management & Permissions", () => { expect(changedUserInfoJson.builder?.global).toBeDefined() expect(changedUserInfoJson.builder?.global).toEqual(true) }) + + it("Set First and Last Name", async () => { + const body: Partial = { + firstName: "newFirstName", + lastName: "newLastName", + } + await config.api.self.changeUserInfo(body) + }) + + it("Generate API key", async () => { + await config.api.self.generateApiKey() + }) + + it("Change Password", async () => { + await config.api.self.changeSelfPassword() + }) }) From 0aa3e19d095b1623972e3c269e0fa332c7d5cdd7 Mon Sep 17 00:00:00 2001 From: Pedro Silva Date: Fri, 9 Jun 2023 12:44:31 +0100 Subject: [PATCH 02/17] Add verifications --- .../src/internal-api/tests/users/userManagement.spec.ts | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/qa-core/src/internal-api/tests/users/userManagement.spec.ts b/qa-core/src/internal-api/tests/users/userManagement.spec.ts index d1bada05c0..42bda21102 100644 --- a/qa-core/src/internal-api/tests/users/userManagement.spec.ts +++ b/qa-core/src/internal-api/tests/users/userManagement.spec.ts @@ -94,6 +94,11 @@ describe("Internal API - User Management & Permissions", () => { lastName: "newLastName", } await config.api.self.changeUserInfo(body) + + const [changedUserInfoResponse, changedUserInfoJson] = + await config.api.self.getSelf() + expect(changedUserInfoJson.firstName).toEqual("newFirstName") + expect(changedUserInfoJson.lastName).toEqual("newLastName") }) it("Generate API key", async () => { @@ -102,5 +107,9 @@ describe("Internal API - User Management & Permissions", () => { it("Change Password", async () => { await config.api.self.changeSelfPassword() + const [changedUserInfoResponse, changedUserInfoJson] = + await config.api.self.getSelf() + + await config.login(changedUserInfoJson.email!, "newPassword") }) }) From 6cb664060e2db8817e79f537d04fdec36ced292a Mon Sep 17 00:00:00 2001 From: Adria Navarro Date: Mon, 3 Jul 2023 10:13:42 +0100 Subject: [PATCH 03/17] Refetch tables on many to many --- .../backend/DataTable/modals/CreateEditColumn.svelte | 6 ++++++ .../DataTable/modals/grid/GridCreateColumnModal.svelte | 8 +++++++- 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/packages/builder/src/components/backend/DataTable/modals/CreateEditColumn.svelte b/packages/builder/src/components/backend/DataTable/modals/CreateEditColumn.svelte index 8a4a6d3012..318b7d9663 100644 --- a/packages/builder/src/components/backend/DataTable/modals/CreateEditColumn.svelte +++ b/packages/builder/src/components/backend/DataTable/modals/CreateEditColumn.svelte @@ -182,6 +182,12 @@ indexes, }) dispatch("updatecolumns") + if ( + saveColumn.type === LINK_TYPE && + saveColumn.relationshipType === RelationshipTypes.MANY_TO_MANY + ) { + dispatch("updatetables") + } if (originalName) { notifications.success("Column updated successfully") } else { diff --git a/packages/builder/src/components/backend/DataTable/modals/grid/GridCreateColumnModal.svelte b/packages/builder/src/components/backend/DataTable/modals/grid/GridCreateColumnModal.svelte index 9e386ae140..d0d3b81d84 100644 --- a/packages/builder/src/components/backend/DataTable/modals/grid/GridCreateColumnModal.svelte +++ b/packages/builder/src/components/backend/DataTable/modals/grid/GridCreateColumnModal.svelte @@ -1,6 +1,7 @@ - + { + tables.fetch() + }} + /> From 2cbead8bc4c794a57d2b09299258ce8716125ed1 Mon Sep 17 00:00:00 2001 From: Adria Navarro Date: Mon, 3 Jul 2023 11:47:42 +0100 Subject: [PATCH 04/17] Fetch relationships --- .../backend/DataTable/modals/CreateEditColumn.svelte | 5 ++++- .../DataTable/modals/grid/GridCreateColumnModal.svelte | 8 +------- 2 files changed, 5 insertions(+), 8 deletions(-) diff --git a/packages/builder/src/components/backend/DataTable/modals/CreateEditColumn.svelte b/packages/builder/src/components/backend/DataTable/modals/CreateEditColumn.svelte index 318b7d9663..665175a435 100644 --- a/packages/builder/src/components/backend/DataTable/modals/CreateEditColumn.svelte +++ b/packages/builder/src/components/backend/DataTable/modals/CreateEditColumn.svelte @@ -186,7 +186,10 @@ saveColumn.type === LINK_TYPE && saveColumn.relationshipType === RelationshipTypes.MANY_TO_MANY ) { - dispatch("updatetables") + // Fetching the new tables + tables.fetch() + // Fetching the new relationships + datasources.fetch() } if (originalName) { notifications.success("Column updated successfully") diff --git a/packages/builder/src/components/backend/DataTable/modals/grid/GridCreateColumnModal.svelte b/packages/builder/src/components/backend/DataTable/modals/grid/GridCreateColumnModal.svelte index d0d3b81d84..9e386ae140 100644 --- a/packages/builder/src/components/backend/DataTable/modals/grid/GridCreateColumnModal.svelte +++ b/packages/builder/src/components/backend/DataTable/modals/grid/GridCreateColumnModal.svelte @@ -1,7 +1,6 @@ - { - tables.fetch() - }} - /> + From 46244b72ac30bb9b0918614c863b90a3fd3c3d5c Mon Sep 17 00:00:00 2001 From: Peter Clement Date: Mon, 3 Jul 2023 11:50:57 +0100 Subject: [PATCH 05/17] Handle errors in grid when no validation structure in response --- packages/frontend-core/src/components/grid/stores/rows.js | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/packages/frontend-core/src/components/grid/stores/rows.js b/packages/frontend-core/src/components/grid/stores/rows.js index 736863378f..0971b4cc18 100644 --- a/packages/frontend-core/src/components/grid/stores/rows.js +++ b/packages/frontend-core/src/components/grid/stores/rows.js @@ -246,6 +246,14 @@ export const deriveStores = context => { } } else { // Some other error - just update the current cell + if (get(focusedCellId)) { + validation.actions.setError( + get(focusedCellId), + error?.message || "Error" + ) + } else { + get(notifications).error(error?.message || "An unknown error occurred") + } validation.actions.setError(get(focusedCellId), error?.message || "Error") } } From 3aad1e8ca3d8d4dbfccebc50af3f380c00291bda Mon Sep 17 00:00:00 2001 From: Conor Webb <126772285+ConorWebb96@users.noreply.github.com> Date: Mon, 3 Jul 2023 12:07:45 +0100 Subject: [PATCH 06/17] Helpers functions bug fixes (#11003) * Helpers functions bug fixes * Corrected multiply example * Removing test for times. --------- Co-authored-by: mike12345567 --- packages/string-templates/manifest.json | 27 +++---------------- packages/string-templates/package.json | 2 +- .../scripts/gen-collection-info.js | 6 ++--- .../string-templates/test/helpers.spec.js | 8 ------ 4 files changed, 8 insertions(+), 35 deletions(-) diff --git a/packages/string-templates/manifest.json b/packages/string-templates/manifest.json index f837f3aa75..087f1fd8ab 100644 --- a/packages/string-templates/manifest.json +++ b/packages/string-templates/manifest.json @@ -75,7 +75,7 @@ ], "numArgs": 2, "example": "{{ multiply 10 5 }} -> 50", - "description": "

Return the product of a times b.

\n" + "description": "

Multiply number a by number b.

\n" }, "plus": { "args": [ @@ -128,15 +128,6 @@ "numArgs": 1, "example": "{{ sum [1, 2, 3] }} -> 6", "description": "

Returns the sum of all numbers in the given array.

\n" - }, - "times": { - "args": [ - "a", - "b" - ], - "numArgs": 2, - "example": "{{ times 10 5 }} -> 50", - "description": "

Multiply number a by number b.

\n" } }, "array": { @@ -497,19 +488,9 @@ "str" ], "numArgs": 1, - "example": "{{ escape 'https://myurl?Hello%20There' }} -> https://myurl?Hello+There", + "example": "{{ decodeURI 'https://myurl?Hello%20There' }} -> https://myurl?=Hello There", "description": "

Decode a Uniform Resource Identifier (URI) component.

\n" }, - "url_encode": { - "args": [], - "numArgs": 0, - "description": "

Alias for encodeURI.

\n" - }, - "url_decode": { - "args": [], - "numArgs": 0, - "description": "

Alias for decodeURI.

\n" - }, "urlResolve": { "args": [ "base", @@ -625,7 +606,7 @@ "length" ], "numArgs": 2, - "example": "{{ellipsis 'foo bar baz' 7}} -> foo bar…", + "example": "{{ellipsis 'foo bar baz', 7}} -> foo bar…", "description": "

Truncates a string to the specified length, and appends it with an elipsis, .

\n" }, "hyphenate": { @@ -1219,4 +1200,4 @@ "description": "

Produce a humanized duration left/until given an amount of time and the type of time measurement.

\n" } } -} +} \ No newline at end of file diff --git a/packages/string-templates/package.json b/packages/string-templates/package.json index b1a276369f..07326d31b7 100644 --- a/packages/string-templates/package.json +++ b/packages/string-templates/package.json @@ -25,7 +25,7 @@ "manifest": "node ./scripts/gen-collection-info.js" }, "dependencies": { - "@budibase/handlebars-helpers": "^0.11.8", + "@budibase/handlebars-helpers": "^0.11.9", "dayjs": "^1.10.4", "handlebars": "^4.7.6", "handlebars-utils": "^1.0.6", diff --git a/packages/string-templates/scripts/gen-collection-info.js b/packages/string-templates/scripts/gen-collection-info.js index bfc0ec79ac..1dbb20e5cf 100644 --- a/packages/string-templates/scripts/gen-collection-info.js +++ b/packages/string-templates/scripts/gen-collection-info.js @@ -9,8 +9,8 @@ const marked = require("marked") * full list of supported helpers can be found here: * https://github.com/budibase/handlebars-helpers */ - -const DIRECTORY = fs.existsSync("node_modules") ? "." : ".." +const { join } = require("path") +const DIRECTORY = join(__dirname, "..", "..", "..") const COLLECTIONS = [ "math", "array", @@ -20,7 +20,7 @@ const COLLECTIONS = [ "comparison", "object", ] -const FILENAME = `${DIRECTORY}/manifest.json` +const FILENAME = join(__dirname, "..", "manifest.json") const outputJSON = {} const ADDED_HELPERS = { date: { diff --git a/packages/string-templates/test/helpers.spec.js b/packages/string-templates/test/helpers.spec.js index 1969410993..a587ca60dd 100644 --- a/packages/string-templates/test/helpers.spec.js +++ b/packages/string-templates/test/helpers.spec.js @@ -48,14 +48,6 @@ describe("test the math helpers", () => { }) expect(parseInt(output)).toBe(2) }) - - it("should be able to times", async () => { - const output = await processString("{{times a b}}", { - a: 5, - b: 5, - }) - expect(parseInt(output)).toBe(25) - }) }) describe("test the array helpers", () => { From 71e44b1eab55982ef06afcab02402b6f16679a67 Mon Sep 17 00:00:00 2001 From: Budibase Staging Release Bot <> Date: Mon, 3 Jul 2023 11:08:02 +0000 Subject: [PATCH 07/17] Bump version to 2.7.37-alpha.5 --- lerna.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lerna.json b/lerna.json index a9cd175fd1..8da39031d3 100644 --- a/lerna.json +++ b/lerna.json @@ -1,5 +1,5 @@ { - "version": "2.7.37-alpha.4", + "version": "2.7.37-alpha.5", "npmClient": "yarn", "packages": [ "packages/*" From c504ceca9de00741bcb767a6caf9bc6a6838060b Mon Sep 17 00:00:00 2001 From: Peter Clement Date: Mon, 3 Jul 2023 13:29:28 +0100 Subject: [PATCH 08/17] solely use notifications store for error message without rowId --- .../frontend-core/src/components/grid/stores/rows.js | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/packages/frontend-core/src/components/grid/stores/rows.js b/packages/frontend-core/src/components/grid/stores/rows.js index 0971b4cc18..59d7c633d6 100644 --- a/packages/frontend-core/src/components/grid/stores/rows.js +++ b/packages/frontend-core/src/components/grid/stores/rows.js @@ -245,16 +245,7 @@ export const deriveStores = context => { focusedCellId.set(`${rowId}-${erroredColumns[0]}`) } } else { - // Some other error - just update the current cell - if (get(focusedCellId)) { - validation.actions.setError( - get(focusedCellId), - error?.message || "Error" - ) - } else { - get(notifications).error(error?.message || "An unknown error occurred") - } - validation.actions.setError(get(focusedCellId), error?.message || "Error") + get(notifications).error(error?.message || "An unknown error occurred") } } From e4c5e67514f5a0ccc5dbefe639a21977c74100f8 Mon Sep 17 00:00:00 2001 From: Michael Drury Date: Mon, 3 Jul 2023 14:10:18 +0100 Subject: [PATCH 09/17] Revert "Add more tests for user settings" --- qa-core/src/internal-api/api/apis/SelfAPI.ts | 18 +++---------- .../tests/users/userManagement.spec.ts | 25 ------------------- 2 files changed, 3 insertions(+), 40 deletions(-) diff --git a/qa-core/src/internal-api/api/apis/SelfAPI.ts b/qa-core/src/internal-api/api/apis/SelfAPI.ts index 022a438249..cd162053a1 100644 --- a/qa-core/src/internal-api/api/apis/SelfAPI.ts +++ b/qa-core/src/internal-api/api/apis/SelfAPI.ts @@ -14,11 +14,10 @@ export default class SelfAPI extends BaseAPI { return [response, json] } - async changeSelfPassword(): Promise<[Response, User]> { - const body = { - password: "newPassword", - } + async changeSelfPassword(body: Partial): Promise<[Response, User]> { const [response, json] = await this.post(`/global/self`, body) + expect(json._id).toEqual(body._id) + expect(json._rev).not.toEqual(body._rev) return [response, json] } @@ -27,15 +26,4 @@ export default class SelfAPI extends BaseAPI { expect(json).toHaveProperty("apiKey") return json } - - async changeUserInfo(body: Partial): Promise<[Response, User]> { - const [response, json] = await this.post(`/global/self`, body) - return [response, json] - } - - async generateApiKey(): Promise<[Response, ApiKeyResponse]> { - const [response, json] = await this.post(`/global/self/api_key`) - expect(json).toHaveProperty("apiKey") - return [response, json] - } } diff --git a/qa-core/src/internal-api/tests/users/userManagement.spec.ts b/qa-core/src/internal-api/tests/users/userManagement.spec.ts index 42bda21102..28096c08c9 100644 --- a/qa-core/src/internal-api/tests/users/userManagement.spec.ts +++ b/qa-core/src/internal-api/tests/users/userManagement.spec.ts @@ -87,29 +87,4 @@ describe("Internal API - User Management & Permissions", () => { expect(changedUserInfoJson.builder?.global).toBeDefined() expect(changedUserInfoJson.builder?.global).toEqual(true) }) - - it("Set First and Last Name", async () => { - const body: Partial = { - firstName: "newFirstName", - lastName: "newLastName", - } - await config.api.self.changeUserInfo(body) - - const [changedUserInfoResponse, changedUserInfoJson] = - await config.api.self.getSelf() - expect(changedUserInfoJson.firstName).toEqual("newFirstName") - expect(changedUserInfoJson.lastName).toEqual("newLastName") - }) - - it("Generate API key", async () => { - await config.api.self.generateApiKey() - }) - - it("Change Password", async () => { - await config.api.self.changeSelfPassword() - const [changedUserInfoResponse, changedUserInfoJson] = - await config.api.self.getSelf() - - await config.login(changedUserInfoJson.email!, "newPassword") - }) }) From 22ae329a2a2f4125c7937bcf05fd13fc95f4f13f Mon Sep 17 00:00:00 2001 From: Dean Date: Mon, 3 Jul 2023 14:48:36 +0100 Subject: [PATCH 10/17] Fix to ensure screens are listed in the navigateTo button action and that any URL configured there is trimmed --- .../common/bindings/DrawerBindableCombobox.svelte | 1 + .../controls/ButtonActionEditor/actions/NavigateTo.svelte | 8 ++++++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/packages/builder/src/components/common/bindings/DrawerBindableCombobox.svelte b/packages/builder/src/components/common/bindings/DrawerBindableCombobox.svelte index 55f7866453..edf65797c2 100644 --- a/packages/builder/src/components/common/bindings/DrawerBindableCombobox.svelte +++ b/packages/builder/src/components/common/bindings/DrawerBindableCombobox.svelte @@ -68,6 +68,7 @@ on:blur={() => dispatch("blur")} {placeholder} {error} + options={allOptions} /> {#if !disabled}
diff --git a/packages/builder/src/components/design/settings/controls/ButtonActionEditor/actions/NavigateTo.svelte b/packages/builder/src/components/design/settings/controls/ButtonActionEditor/actions/NavigateTo.svelte index dca2887fb4..edbdc53083 100644 --- a/packages/builder/src/components/design/settings/controls/ButtonActionEditor/actions/NavigateTo.svelte +++ b/packages/builder/src/components/design/settings/controls/ButtonActionEditor/actions/NavigateTo.svelte @@ -43,7 +43,9 @@ title="Destination" placeholder="/screen" value={parameters.url} - on:change={value => (parameters.url = value.detail)} + on:change={value => { + parameters.url = value.detail ? value.detail.trim() : value.detail + }} {bindings} options={urlOptions} appendBindingsAsOptions={false} @@ -55,7 +57,9 @@ title="Destination" placeholder="/url" value={parameters.url} - on:change={value => (parameters.url = value.detail)} + on:change={value => { + parameters.url = value.detail ? value.detail.trim() : value.detail + }} {bindings} />
From 228d7cc156c6e50019e09a1a5a7614045bbf850e Mon Sep 17 00:00:00 2001 From: Budibase Staging Release Bot <> Date: Mon, 3 Jul 2023 14:26:26 +0000 Subject: [PATCH 11/17] Bump version to 2.7.37-alpha.6 --- lerna.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lerna.json b/lerna.json index 8da39031d3..4939fa778c 100644 --- a/lerna.json +++ b/lerna.json @@ -1,5 +1,5 @@ { - "version": "2.7.37-alpha.5", + "version": "2.7.37-alpha.6", "npmClient": "yarn", "packages": [ "packages/*" From 10be6509d6afb6262d8ac4b21c31cb35d18c6f29 Mon Sep 17 00:00:00 2001 From: Budibase Staging Release Bot <> Date: Mon, 3 Jul 2023 14:30:32 +0000 Subject: [PATCH 12/17] Bump version to 2.7.37-alpha.7 --- lerna.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lerna.json b/lerna.json index 4939fa778c..db1295bdd1 100644 --- a/lerna.json +++ b/lerna.json @@ -1,5 +1,5 @@ { - "version": "2.7.37-alpha.6", + "version": "2.7.37-alpha.7", "npmClient": "yarn", "packages": [ "packages/*" From c9589c1edc958a68698dfdd3ea51c208a7ca00b2 Mon Sep 17 00:00:00 2001 From: melohagan <101575380+melohagan@users.noreply.github.com> Date: Tue, 4 Jul 2023 08:34:59 +0100 Subject: [PATCH 13/17] Apply column order for Grid block (#11099) * Apply column order for Grid block * Refactor * Do not allow column reorder for Grid block * Refactor --- .../components/design/settings/componentSettings.js | 2 ++ .../settings/controls/ColumnEditor/ColumnDrawer.svelte | 5 +++++ .../settings/controls/ColumnEditor/ColumnEditor.svelte | 2 ++ .../controls/ColumnEditor/GridColumnEditor.svelte | 10 ++++++++++ packages/client/manifest.json | 2 +- 5 files changed, 20 insertions(+), 1 deletion(-) create mode 100644 packages/builder/src/components/design/settings/controls/ColumnEditor/GridColumnEditor.svelte diff --git a/packages/builder/src/components/design/settings/componentSettings.js b/packages/builder/src/components/design/settings/componentSettings.js index 31f51bf468..b3b9fb6577 100644 --- a/packages/builder/src/components/design/settings/componentSettings.js +++ b/packages/builder/src/components/design/settings/componentSettings.js @@ -20,6 +20,7 @@ import ValidationEditor from "./controls/ValidationEditor/ValidationEditor.svelt import DrawerBindableInput from "components/common/bindings/DrawerBindableInput.svelte" import ColumnEditor from "./controls/ColumnEditor/ColumnEditor.svelte" import BasicColumnEditor from "./controls/ColumnEditor/BasicColumnEditor.svelte" +import GridColumnEditor from "./controls/ColumnEditor/GridColumnEditor.svelte" import BarButtonList from "./controls/BarButtonList.svelte" import FieldConfiguration from "./controls/FieldConfiguration/FieldConfiguration.svelte" @@ -47,6 +48,7 @@ const componentMap = { fieldConfiguration: FieldConfiguration, columns: ColumnEditor, "columns/basic": BasicColumnEditor, + "columns/grid": GridColumnEditor, "field/sortable": SortableFieldSelect, "field/string": FormFieldSelect, "field/number": FormFieldSelect, diff --git a/packages/builder/src/components/design/settings/controls/ColumnEditor/ColumnDrawer.svelte b/packages/builder/src/components/design/settings/controls/ColumnEditor/ColumnDrawer.svelte index 6e57d20751..f249245b34 100644 --- a/packages/builder/src/components/design/settings/controls/ColumnEditor/ColumnDrawer.svelte +++ b/packages/builder/src/components/design/settings/controls/ColumnEditor/ColumnDrawer.svelte @@ -18,6 +18,7 @@ export let options = [] export let schema = {} export let allowCellEditing = true + export let allowReorder = true const flipDurationMs = 150 let dragDisabled = true @@ -110,6 +111,7 @@ {#each columns as column (column.id)}
diff --git a/packages/builder/src/components/design/settings/controls/ColumnEditor/GridColumnEditor.svelte b/packages/builder/src/components/design/settings/controls/ColumnEditor/GridColumnEditor.svelte new file mode 100644 index 0000000000..291a1b61a8 --- /dev/null +++ b/packages/builder/src/components/design/settings/controls/ColumnEditor/GridColumnEditor.svelte @@ -0,0 +1,10 @@ + + + diff --git a/packages/client/manifest.json b/packages/client/manifest.json index 8e7d2bf21f..59928ae684 100644 --- a/packages/client/manifest.json +++ b/packages/client/manifest.json @@ -5248,7 +5248,7 @@ "required": true }, { - "type": "columns/basic", + "type": "columns/grid", "label": "Columns", "key": "columns", "dependsOn": "table" From bad1abe921f9141deffa5ba9a6c4255ec6f6647a Mon Sep 17 00:00:00 2001 From: Budibase Staging Release Bot <> Date: Tue, 4 Jul 2023 07:35:17 +0000 Subject: [PATCH 14/17] Bump version to 2.7.37-alpha.8 --- lerna.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lerna.json b/lerna.json index db1295bdd1..c63e43a8ef 100644 --- a/lerna.json +++ b/lerna.json @@ -1,5 +1,5 @@ { - "version": "2.7.37-alpha.7", + "version": "2.7.37-alpha.8", "npmClient": "yarn", "packages": [ "packages/*" From e0e0fcabad9b3695927af3e4d0b50203ed4146fa Mon Sep 17 00:00:00 2001 From: Andrew Kingston Date: Tue, 4 Jul 2023 09:41:10 +0100 Subject: [PATCH 15/17] Fix grid block row height not working. Change initialRowHeight setting to fixedRowHeight --- packages/client/manifest.json | 2 +- packages/client/src/components/app/GridBlock.svelte | 4 ++-- .../src/components/grid/controls/SizeButton.svelte | 10 ++++++---- .../src/components/grid/layout/Grid.svelte | 4 ++-- .../src/components/grid/stores/config.js | 4 ++-- .../frontend-core/src/components/grid/stores/ui.js | 12 +++++++----- 6 files changed, 20 insertions(+), 16 deletions(-) diff --git a/packages/client/manifest.json b/packages/client/manifest.json index 59928ae684..649038c20e 100644 --- a/packages/client/manifest.json +++ b/packages/client/manifest.json @@ -5274,7 +5274,7 @@ { "type": "select", "label": "Row height", - "key": "initialRowHeight", + "key": "fixedRowHeight", "placeholder": "Default", "options": [ { diff --git a/packages/client/src/components/app/GridBlock.svelte b/packages/client/src/components/app/GridBlock.svelte index ae0acb50f0..dd67a5657b 100644 --- a/packages/client/src/components/app/GridBlock.svelte +++ b/packages/client/src/components/app/GridBlock.svelte @@ -12,7 +12,7 @@ export let initialFilter = null export let initialSortColumn = null export let initialSortOrder = null - export let initialRowHeight = null + export let fixedRowHeight = null export let columns = null const component = getContext("component") @@ -47,7 +47,7 @@ {initialFilter} {initialSortColumn} {initialSortOrder} - {initialRowHeight} + {fixedRowHeight} {columnWhitelist} {schemaOverrides} showControls={false} diff --git a/packages/frontend-core/src/components/grid/controls/SizeButton.svelte b/packages/frontend-core/src/components/grid/controls/SizeButton.svelte index eb9bf917d9..22e0c6c2e9 100644 --- a/packages/frontend-core/src/components/grid/controls/SizeButton.svelte +++ b/packages/frontend-core/src/components/grid/controls/SizeButton.svelte @@ -8,7 +8,8 @@ SmallRowHeight, } from "../lib/constants" - const { stickyColumn, columns, rowHeight, table } = getContext("grid") + const { stickyColumn, columns, rowHeight, table, fixedRowHeight } = + getContext("grid") // Some constants for column width options const smallColSize = 120 @@ -86,6 +87,7 @@
{#each rowSizeOptions as option} changeRowHeight(option.size)} @@ -118,15 +120,15 @@