diff --git a/.DS_Store b/.DS_Store index 0dfd56565a..363dbb1c4c 100644 Binary files a/.DS_Store and b/.DS_Store differ diff --git a/packages/builder/assets/budibase-emblem-white.svg b/packages/builder/assets/budibase-emblem-white.svg deleted file mode 100644 index 728e859260..0000000000 --- a/packages/builder/assets/budibase-emblem-white.svg +++ /dev/null @@ -1,29 +0,0 @@ - - - - - - - - - - - - - - - - diff --git a/packages/builder/assets/budibase-logo-only.png b/packages/builder/assets/budibase-logo-only.png deleted file mode 100644 index 652444e5bd..0000000000 Binary files a/packages/builder/assets/budibase-logo-only.png and /dev/null differ diff --git a/packages/builder/assets/budibase-logo-white.png b/packages/builder/assets/budibase-logo-white.png deleted file mode 100644 index da8440c09e..0000000000 Binary files a/packages/builder/assets/budibase-logo-white.png and /dev/null differ diff --git a/packages/builder/assets/budibase-logo.png b/packages/builder/assets/budibase-logo.png deleted file mode 100644 index 1d6fc3d1cc..0000000000 Binary files a/packages/builder/assets/budibase-logo.png and /dev/null differ diff --git a/packages/builder/src/builderStore/api.js b/packages/builder/src/builderStore/api.js index 04dcce6cb9..3fcd35ce28 100644 --- a/packages/builder/src/builderStore/api.js +++ b/packages/builder/src/builderStore/api.js @@ -3,6 +3,7 @@ const apiCall = method => async (url, body) => { method: method, headers: { "Content-Type": "application/json", + "x-user-agent": "Budibase Builder", }, body: body && JSON.stringify(body), }) @@ -14,11 +15,11 @@ const apiCall = method => async (url, body) => { return response } -const post = apiCall("POST") -const get = apiCall("GET") -const patch = apiCall("PATCH") -const del = apiCall("DELETE") -const put = apiCall("PUT") +export const post = apiCall("POST") +export const get = apiCall("GET") +export const patch = apiCall("PATCH") +export const del = apiCall("DELETE") +export const put = apiCall("PUT") export default { post, diff --git a/packages/builder/src/builderStore/loadComponentLibraries.js b/packages/builder/src/builderStore/loadComponentLibraries.js index ada00134f4..9d534f86fe 100644 --- a/packages/builder/src/builderStore/loadComponentLibraries.js +++ b/packages/builder/src/builderStore/loadComponentLibraries.js @@ -1,3 +1,5 @@ +import { get } from "builderStore/api" + /** * Fetches the definitions for component library components. This includes * their props and other metadata from components.json. @@ -6,7 +8,7 @@ export const fetchComponentLibDefinitions = async appId => { const LIB_DEFINITION_URL = `/${appId}/components/definitions` try { - const libDefinitionResponse = await fetch(LIB_DEFINITION_URL) + const libDefinitionResponse = await get(LIB_DEFINITION_URL) return await libDefinitionResponse.json() } catch (err) { console.error(`Error fetching component definitions for ${appId}`, err) diff --git a/packages/builder/src/components/common/Select.svelte b/packages/builder/src/components/common/Select.svelte index e89b8006a5..4bdd2a941e 100644 --- a/packages/builder/src/components/common/Select.svelte +++ b/packages/builder/src/components/common/Select.svelte @@ -22,7 +22,6 @@ font-size: 14px; position: relative; border: var(--grey-dark) 1px solid; - max-width: 256px; } .adjusted { diff --git a/packages/builder/src/components/start/CreateAppModal.svelte b/packages/builder/src/components/start/CreateAppModal.svelte index d2232f7604..f012860194 100644 --- a/packages/builder/src/components/start/CreateAppModal.svelte +++ b/packages/builder/src/components/start/CreateAppModal.svelte @@ -5,6 +5,7 @@ import { AppsIcon, InfoIcon, CloseIcon } from "components/common/Icons/" import { getContext } from "svelte" import { fade } from "svelte/transition" + import { post } from "builderStore/api" const { open, close } = getContext("simple-modal") @@ -33,15 +34,7 @@ const data = { name, description } loading = true try { - const response = await fetch("/api/applications", { - method: "POST", // *GET, POST, PUT, DELETE, etc. - credentials: "same-origin", // include, *same-origin, omit - headers: { - "Content-Type": "application/json", - // 'Content-Type': 'application/x-www-form-urlencoded', - }, - body: JSON.stringify(data), // body data type must match "Content-Type" header - }) + const response = await post("/api/applications", data) const res = await response.json() diff --git a/packages/builder/src/components/userInterface/AppPreview/iframeTemplate.js b/packages/builder/src/components/userInterface/AppPreview/iframeTemplate.js index d3a94b6cf5..462becb32f 100644 --- a/packages/builder/src/components/userInterface/AppPreview/iframeTemplate.js +++ b/packages/builder/src/components/userInterface/AppPreview/iframeTemplate.js @@ -17,6 +17,7 @@ export default ({ body, html { height: 100%!important; + font-family: Roboto !important; } .lay-__screenslot__text { width: 100%; diff --git a/packages/builder/src/components/userInterface/EventsEditor/EventEditorModal.svelte b/packages/builder/src/components/userInterface/EventsEditor/EventEditorModal.svelte index 684d400399..35faac366f 100644 --- a/packages/builder/src/components/userInterface/EventsEditor/EventEditorModal.svelte +++ b/packages/builder/src/components/userInterface/EventsEditor/EventEditorModal.svelte @@ -1,5 +1,6 @@ - -

- {eventData.name ? `${eventData.name} Event` : 'Create a New Component Event'} -

- - Click here to learn more about component events - +
+
+
+

+ {eventData.name ? `${eventData.name} Event` : 'Create a New Component Event'} +

+
+
+
+

Event Type

+ +
+
-
-
-
-
Event Type
- {@html getIcon('info', 20)} -
- +
+

Event Action(s)

+ { + createNewEventHandler(draftEventHandler) + draftEventHandler = { parameters: [] } + }} + handler={draftEventHandler} /> +
+ {#if eventData} + {#each eventData.handlers as handler, index} + deleteEventHandler(index)} + {handler} /> + {/each} + {/if} + +
+ - -
-
Event Action(s)
- {@html getIcon('info', 20)} -
- { - createNewEventHandler(draftEventHandler) - draftEventHandler = { parameters: [] } - }} - handler={draftEventHandler} /> - {#if eventData} - {#each eventData.handlers as handler, index} - deleteEventHandler(index)} - {handler} /> - {/each} - {/if} - -
- - - Save - +
+
- +
diff --git a/packages/builder/src/components/userInterface/EventsEditor/EventsEditor.svelte b/packages/builder/src/components/userInterface/EventsEditor/EventsEditor.svelte index d897ad9c2f..cbc46a3094 100644 --- a/packages/builder/src/components/userInterface/EventsEditor/EventsEditor.svelte +++ b/packages/builder/src/components/userInterface/EventsEditor/EventsEditor.svelte @@ -1,4 +1,5 @@ @@ -71,11 +84,6 @@ {/each}
- diff --git a/packages/builder/src/components/userInterface/EventsEditor/StateBindingCascader.svelte b/packages/builder/src/components/userInterface/EventsEditor/StateBindingCascader.svelte index 1edf5d45a0..69ab73e16c 100644 --- a/packages/builder/src/components/userInterface/EventsEditor/StateBindingCascader.svelte +++ b/packages/builder/src/components/userInterface/EventsEditor/StateBindingCascader.svelte @@ -1,8 +1,8 @@
- {parameter.name} -
- {#if parameter.name === 'workflow'} - - {:else} - - - {/if} -
+ {#if parameter.name === 'workflow'} + {parameter.name} + {/if} + {#if parameter.name === 'workflow'} + + {:else} + + {/if}
diff --git a/packages/builder/src/components/userInterface/ModelSelect.svelte b/packages/builder/src/components/userInterface/ModelSelect.svelte index ae5014e31f..44fa2e51e0 100644 --- a/packages/builder/src/components/userInterface/ModelSelect.svelte +++ b/packages/builder/src/components/userInterface/ModelSelect.svelte @@ -7,7 +7,7 @@
+ {/each} diff --git a/packages/builder/src/favicon.ico b/packages/builder/src/favicon.ico index 68b7d616ff..c216bfc024 100644 Binary files a/packages/builder/src/favicon.ico and b/packages/builder/src/favicon.ico differ diff --git a/packages/builder/src/favicon.png b/packages/builder/src/favicon.png index 4b51107210..60ab37ad84 100644 Binary files a/packages/builder/src/favicon.png and b/packages/builder/src/favicon.png differ diff --git a/packages/builder/src/pages/[application]/_reset.svelte b/packages/builder/src/pages/[application]/_reset.svelte index d973ba7517..2eec749c8f 100644 --- a/packages/builder/src/pages/[application]/_reset.svelte +++ b/packages/builder/src/pages/[application]/_reset.svelte @@ -1,6 +1,7 @@ - + - + + \ No newline at end of file diff --git a/packages/standard-components/components.json b/packages/standard-components/components.json index 574cbd5446..a562650b85 100644 --- a/packages/standard-components/components.json +++ b/packages/standard-components/components.json @@ -59,6 +59,7 @@ "props": { "logo": "asset", "loginRedirect": "string", + "name": "string", "usernameLabel": { "type": "string", "default": "Username" diff --git a/packages/standard-components/src/Button.svelte b/packages/standard-components/src/Button.svelte index eac2150274..66df8f9338 100644 --- a/packages/standard-components/src/Button.svelte +++ b/packages/standard-components/src/Button.svelte @@ -17,7 +17,7 @@