diff --git a/hosting/scripts/build-target-paths.sh b/hosting/scripts/build-target-paths.sh index 6d5a8429f8..ee314c1ce4 100644 --- a/hosting/scripts/build-target-paths.sh +++ b/hosting/scripts/build-target-paths.sh @@ -11,6 +11,10 @@ if [[ "${TARGETBUILD}" = "aas" ]]; then apt-get install -y openssh-server sed -i "s/#Port 22/Port 2222/" /etc/ssh/sshd_config /etc/init.d/ssh restart -fi + sed -i "s#DATA_DIR#/home#g" /opt/clouseau/clouseau.ini + sed -i "s#DATA_DIR#/home#g" /opt/couchdb/etc/local.ini +else + sed -i "s#DATA_DIR#/data#g" /opt/clouseau/clouseau.ini + sed -i "s#DATA_DIR#/data#g" /opt/couchdb/etc/local.ini -sed -i 's#DATA_DIR#$DATA_DIR#' /opt/clouseau/clouseau.ini /opt/couchdb/etc/local.ini +fi \ No newline at end of file diff --git a/hosting/single/couch/local.ini b/hosting/single/couch/local.ini index 266c0d4b60..35f0383dfc 100644 --- a/hosting/single/couch/local.ini +++ b/hosting/single/couch/local.ini @@ -1,5 +1,5 @@ ; CouchDB Configuration Settings [couchdb] -database_dir = DATA_DIR/couch/dbs -view_index_dir = DATA_DIR/couch/views +database_dir = DATA_DIR/couchdb/dbs +view_index_dir = DATA_DIR/couchdb/views diff --git a/hosting/single/healthcheck.sh b/hosting/single/healthcheck.sh index b92cd153a3..592b3e94fa 100644 --- a/hosting/single/healthcheck.sh +++ b/hosting/single/healthcheck.sh @@ -3,6 +3,11 @@ healthy=true if [ -f "/data/.env" ]; then export $(cat /data/.env | xargs) +elif [ -f "/home/.env" ]; then + export $(cat /home/.env | xargs) +else + echo "No .env file found" + healthy=false fi if [[ $(curl -Lfk -s -w "%{http_code}\n" http://localhost/ -o /dev/null) -ne 200 ]]; then diff --git a/lerna.json b/lerna.json index c1e2022b3c..9fedf86f90 100644 --- a/lerna.json +++ b/lerna.json @@ -1,5 +1,5 @@ { - "version": "1.2.40", + "version": "1.2.41-alpha.0", "npmClient": "yarn", "packages": [ "packages/*" diff --git a/packages/backend-core/package.json b/packages/backend-core/package.json index 3eb7ca78af..27246f1828 100644 --- a/packages/backend-core/package.json +++ b/packages/backend-core/package.json @@ -1,6 +1,6 @@ { "name": "@budibase/backend-core", - "version": "1.2.40", + "version": "1.2.41-alpha.0", "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.2.40", + "@budibase/types": "1.2.41-alpha.0", "@techpass/passport-openidconnect": "0.3.2", "aws-sdk": "2.1030.0", "bcrypt": "5.0.1", diff --git a/packages/bbui/package.json b/packages/bbui/package.json index 16eb2cb509..79234a65f8 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.2.40", + "version": "1.2.41-alpha.0", "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.2.40", + "@budibase/string-templates": "1.2.41-alpha.0", "@spectrum-css/actionbutton": "^1.0.1", "@spectrum-css/actiongroup": "^1.0.1", "@spectrum-css/avatar": "^3.0.2", diff --git a/packages/bbui/src/Icon/Icon.svelte b/packages/bbui/src/Icon/Icon.svelte index 9c99178fdb..f2cae14f0b 100644 --- a/packages/bbui/src/Icon/Icon.svelte +++ b/packages/bbui/src/Icon/Icon.svelte @@ -83,4 +83,9 @@ transform: translateX(-50%); text-align: center; } + + .spectrum-Icon--sizeXS { + width: 10px; + height: 10px; + } diff --git a/packages/bbui/src/Menu/Item.svelte b/packages/bbui/src/Menu/Item.svelte index a5609683a8..dfe61c1736 100644 --- a/packages/bbui/src/Menu/Item.svelte +++ b/packages/bbui/src/Menu/Item.svelte @@ -1,5 +1,6 @@ -{#if showMenu} - -
- -
- - Delete - - - Move up - - - Move down - - - Duplicate - - storeComponentForCopy(true)}> - Cut - - storeComponentForCopy(false)}> - Copy - - pasteComponent("above")} - disabled={noPaste} - > - Paste above - - pasteComponent("below")} - disabled={noPaste} - > - Paste below - - pasteComponent("inside")} - disabled={noPaste || noChildrenAllowed} - > - Paste inside - -
- -{/if} + +
+ +
+ keyboardEvent("Delete")} + > + Delete + + keyboardEvent("ArrowUp", true)} + > + Move up + + keyboardEvent("ArrowDown", true)} + > + Move down + + keyboardEvent("d", true)} + > + Duplicate + + keyboardEvent("x", true)} + > + Cut + + keyboardEvent("c", true)} + > + Copy + + keyboardEvent("v", true)} + disabled={noPaste} + > + Paste + +
diff --git a/packages/builder/src/pages/builder/app/[application]/design/[screenId]/theme/_components/ButtonRoundnessSelect.svelte b/packages/builder/src/pages/builder/app/[application]/design/[screenId]/theme/_components/ButtonRoundnessSelect.svelte new file mode 100644 index 0000000000..21b04f694f --- /dev/null +++ b/packages/builder/src/pages/builder/app/[application]/design/[screenId]/theme/_components/ButtonRoundnessSelect.svelte @@ -0,0 +1,38 @@ + + +
+ +
+ +
+
+ + diff --git a/packages/builder/src/pages/builder/app/[application]/design/[screenId]/theme/_components/ThemeSettingsPanel.svelte b/packages/builder/src/pages/builder/app/[application]/design/[screenId]/theme/_components/ThemeSettingsPanel.svelte index 4bad3b7bc4..1c86a51f67 100644 --- a/packages/builder/src/pages/builder/app/[application]/design/[screenId]/theme/_components/ThemeSettingsPanel.svelte +++ b/packages/builder/src/pages/builder/app/[application]/design/[screenId]/theme/_components/ThemeSettingsPanel.svelte @@ -1,35 +1,11 @@ diff --git a/packages/client/src/stores/builder.js b/packages/client/src/stores/builder.js index be748f0d81..32eb956d52 100644 --- a/packages/client/src/stores/builder.js +++ b/packages/client/src/stores/builder.js @@ -40,8 +40,8 @@ const createBuilderStore = () => { updateProp: (prop, value) => { dispatchEvent("update-prop", { prop, value }) }, - deleteComponent: id => { - dispatchEvent("delete-component", { id }) + keyDown: (key, ctrlKey) => { + dispatchEvent("key-down", { key, ctrlKey }) }, duplicateComponent: id => { dispatchEvent("duplicate-component", { id }) diff --git a/packages/client/src/stores/theme.js b/packages/client/src/stores/theme.js index 995dafbedc..8877556f0c 100644 --- a/packages/client/src/stores/theme.js +++ b/packages/client/src/stores/theme.js @@ -1,6 +1,7 @@ import { derived } from "svelte/store" import { appStore } from "./app" import { builderStore } from "./builder" +import { Constants } from "@budibase/frontend-core" // This is the good old acorn bug where having the word "g l o b a l" makes it // think that this is not ES6 compatible and starts throwing errors when using @@ -28,6 +29,13 @@ const createThemeStore = () => { // Ensure theme is set theme = theme || defaultTheme + // Get base theme + let base = + Constants.Themes.find(x => `spectrum--${x.class}` === theme)?.base || "" + if (base) { + base = `spectrum--${base}` + } + // Delete and nullish keys from the custom theme if (customTheme) { Object.entries(customTheme).forEach(([key, value]) => { @@ -51,6 +59,7 @@ const createThemeStore = () => { return { theme, + baseTheme: base, customTheme, customThemeCss, } diff --git a/packages/frontend-core/package.json b/packages/frontend-core/package.json index f1c0009f18..f0173e9fb8 100644 --- a/packages/frontend-core/package.json +++ b/packages/frontend-core/package.json @@ -1,12 +1,12 @@ { "name": "@budibase/frontend-core", - "version": "1.2.40", + "version": "1.2.41-alpha.0", "description": "Budibase frontend core libraries used in builder and client", "author": "Budibase", "license": "MPL-2.0", "svelte": "src/index.js", "dependencies": { - "@budibase/bbui": "1.2.40", + "@budibase/bbui": "1.2.41-alpha.0", "lodash": "^4.17.21", "svelte": "^3.46.2" } diff --git a/packages/frontend-core/src/themes/midnight.css b/packages/frontend-core/src/themes/midnight.css index 528d847702..f2b4650ebf 100644 --- a/packages/frontend-core/src/themes/midnight.css +++ b/packages/frontend-core/src/themes/midnight.css @@ -12,5 +12,7 @@ --spectrum-global-color-gray-700: hsl(var(--hue), var(--sat), 70%); --spectrum-global-color-gray-800: hsl(var(--hue), var(--sat), 80%); --spectrum-global-color-gray-900: hsl(var(--hue), var(--sat), 95%); + + --modal-background: var(--spectrum-global-color-gray-50); } diff --git a/packages/frontend-core/src/themes/nord.css b/packages/frontend-core/src/themes/nord.css index ebcf7efaf9..c5a9b13640 100644 --- a/packages/frontend-core/src/themes/nord.css +++ b/packages/frontend-core/src/themes/nord.css @@ -43,4 +43,7 @@ --spectrum-alias-highlight-hover: rgba(169, 177, 193, 0.1); --spectrum-alias-highlight-active: rgba(169, 177, 193, 0.1); + --spectrum-alias-background-color-hover-overlay: rgba(169, 177, 193, 0.1); + + --modal-background: var(--spectrum-global-color-gray-50); } diff --git a/packages/server/package.json b/packages/server/package.json index 960001b328..754aa0c264 100644 --- a/packages/server/package.json +++ b/packages/server/package.json @@ -1,7 +1,7 @@ { "name": "@budibase/server", "email": "hi@budibase.com", - "version": "1.2.40", + "version": "1.2.41-alpha.0", "description": "Budibase Web Server", "main": "src/index.ts", "repository": { @@ -77,11 +77,11 @@ "license": "GPL-3.0", "dependencies": { "@apidevtools/swagger-parser": "10.0.3", - "@budibase/backend-core": "1.2.40", - "@budibase/client": "1.2.40", - "@budibase/pro": "1.2.40", - "@budibase/string-templates": "1.2.40", - "@budibase/types": "^1.2.40", + "@budibase/backend-core": "1.2.41-alpha.0", + "@budibase/client": "1.2.41-alpha.0", + "@budibase/pro": "1.2.41-alpha.0", + "@budibase/string-templates": "1.2.41-alpha.0", + "@budibase/types": "1.2.41-alpha.0", "@bull-board/api": "3.7.0", "@bull-board/koa": "3.9.4", "@elastic/elasticsearch": "7.10.0", diff --git a/packages/server/yarn.lock b/packages/server/yarn.lock index e39b0b97c4..f6a0c6ca5c 100644 --- a/packages/server/yarn.lock +++ b/packages/server/yarn.lock @@ -1094,18 +1094,19 @@ resolved "https://registry.yarnpkg.com/@bcoe/v8-coverage/-/v8-coverage-0.2.3.tgz#75a2e8b51cb758a7553d6804a5932d7aace75c39" integrity sha512-0hYQ8SB4Db5zvZB4axdMHGwEaQjkZzFjQiN9LVYvIFB2nSUHW9tYpxWriPrWDASIxiaXax83REcLxuSdnGPZtw== -"@budibase/backend-core@1.2.40": - version "1.2.40" - resolved "https://registry.yarnpkg.com/@budibase/backend-core/-/backend-core-1.2.40.tgz#692062478f310eaee780adbc55e266fc3b6649b6" - integrity sha512-HUw6IQgKkP345vnQcTok6X+inqYe0WpUL7uFJnm3XERvsAWX4FYWbgDoGJGS0+jZjdPjvARkt4+uZuTAEUFLiQ== +"@budibase/backend-core@1.2.41-alpha.0": + version "1.2.41-alpha.0" + resolved "https://registry.yarnpkg.com/@budibase/backend-core/-/backend-core-1.2.41-alpha.0.tgz#ee3bc032ae89e347b9fb220303a9d040df6f5823" + integrity sha512-x6wJpBBFj6a1pGu2OR1vBPHiA4LvdQpVxr6f1lZa2+nAhuXVtEhrdnvBVzK2hJ52dOTTTGaw2A5tTkbf7861CA== dependencies: - "@budibase/types" "^1.2.40" + "@budibase/types" "1.2.41-alpha.0" "@techpass/passport-openidconnect" "0.3.2" aws-sdk "2.1030.0" bcrypt "5.0.1" dotenv "16.0.1" emitter-listener "1.1.2" ioredis "4.28.0" + joi "17.6.0" jsonwebtoken "8.5.1" koa-passport "4.1.4" lodash "4.17.21" @@ -1177,13 +1178,13 @@ svelte-flatpickr "^3.2.3" svelte-portal "^1.0.0" -"@budibase/pro@1.2.40": - version "1.2.40" - resolved "https://registry.yarnpkg.com/@budibase/pro/-/pro-1.2.40.tgz#007cad4d8341698104498ae7d1578a7e26760dd7" - integrity sha512-lGB0/O8l63FtpP1dOzxowFUjgj7SrRSVsODygPB7oScfUBtbqHyZKC4EafrVpJT4A8hbdh1ijQZ8PLJE/YdRkQ== +"@budibase/pro@1.2.41-alpha.0": + version "1.2.41-alpha.0" + resolved "https://registry.yarnpkg.com/@budibase/pro/-/pro-1.2.41-alpha.0.tgz#4f27dbeee24ddc58e2a4e75cd90b53543f742722" + integrity sha512-LiKuO7/9GGzf3xfMmNTZQl2r4jmGgqnUf7fA5ub/MRyWYM7ZjPWEKW1V9OAk3vXwv9a+4V6FUxJQ1sDUZ3DT/Q== dependencies: - "@budibase/backend-core" "1.2.40" - "@budibase/types" "1.2.40" + "@budibase/backend-core" "1.2.41-alpha.0" + "@budibase/types" "1.2.41-alpha.0" "@koa/router" "8.0.8" joi "17.6.0" node-fetch "^2.6.1" @@ -1206,10 +1207,10 @@ svelte-apexcharts "^1.0.2" svelte-flatpickr "^3.1.0" -"@budibase/types@1.2.40", "@budibase/types@^1.2.40": - version "1.2.40" - resolved "https://registry.yarnpkg.com/@budibase/types/-/types-1.2.40.tgz#c1456728b61966cab7fe3689bd044bf415faa138" - integrity sha512-eNZFG0C/GBog87y6StKBjdF/aDJJtUHbAM8NWLUNNqTAiMxO2s3XhDN1dE6t74NBCRFzJo2sAD+34pJHhKFanQ== +"@budibase/types@1.2.41-alpha.0": + version "1.2.41-alpha.0" + resolved "https://registry.yarnpkg.com/@budibase/types/-/types-1.2.41-alpha.0.tgz#01071ce6ecef6799b04b1defce2b38e81b615f9f" + integrity sha512-2jkeToXsujYUXb6P2DFTFUOFv56GgImJ4webP8xr5cPGL0/xmhWGMd/lLxLt96RtMQp43UmVWZm1BA7TZw4fJg== "@bull-board/api@3.7.0": version "3.7.0" diff --git a/packages/string-templates/package.json b/packages/string-templates/package.json index db1aed0956..586e4d5d39 100644 --- a/packages/string-templates/package.json +++ b/packages/string-templates/package.json @@ -1,6 +1,6 @@ { "name": "@budibase/string-templates", - "version": "1.2.40", + "version": "1.2.41-alpha.0", "description": "Handlebars wrapper for Budibase templating.", "main": "src/index.cjs", "module": "dist/bundle.mjs", diff --git a/packages/types/package.json b/packages/types/package.json index 1463a75782..ed22b489c1 100644 --- a/packages/types/package.json +++ b/packages/types/package.json @@ -1,6 +1,6 @@ { "name": "@budibase/types", - "version": "1.2.40", + "version": "1.2.41-alpha.0", "description": "Budibase types", "main": "dist/index.js", "types": "dist/index.d.ts", diff --git a/packages/worker/package.json b/packages/worker/package.json index e2d2a5633b..ddff762a98 100644 --- a/packages/worker/package.json +++ b/packages/worker/package.json @@ -1,7 +1,7 @@ { "name": "@budibase/worker", "email": "hi@budibase.com", - "version": "1.2.40", + "version": "1.2.41-alpha.0", "description": "Budibase background service", "main": "src/index.ts", "repository": { @@ -35,10 +35,10 @@ "author": "Budibase", "license": "GPL-3.0", "dependencies": { - "@budibase/backend-core": "1.2.40", - "@budibase/pro": "1.2.40", - "@budibase/string-templates": "1.2.40", - "@budibase/types": "1.2.40", + "@budibase/backend-core": "1.2.41-alpha.0", + "@budibase/pro": "1.2.41-alpha.0", + "@budibase/string-templates": "1.2.41-alpha.0", + "@budibase/types": "1.2.41-alpha.0", "@koa/router": "8.0.8", "@sentry/node": "6.17.7", "@techpass/passport-openidconnect": "0.3.2", diff --git a/packages/worker/yarn.lock b/packages/worker/yarn.lock index 9806952df8..b475340214 100644 --- a/packages/worker/yarn.lock +++ b/packages/worker/yarn.lock @@ -291,18 +291,19 @@ resolved "https://registry.yarnpkg.com/@bcoe/v8-coverage/-/v8-coverage-0.2.3.tgz#75a2e8b51cb758a7553d6804a5932d7aace75c39" integrity sha512-0hYQ8SB4Db5zvZB4axdMHGwEaQjkZzFjQiN9LVYvIFB2nSUHW9tYpxWriPrWDASIxiaXax83REcLxuSdnGPZtw== -"@budibase/backend-core@1.2.40": - version "1.2.40" - resolved "https://registry.yarnpkg.com/@budibase/backend-core/-/backend-core-1.2.40.tgz#692062478f310eaee780adbc55e266fc3b6649b6" - integrity sha512-HUw6IQgKkP345vnQcTok6X+inqYe0WpUL7uFJnm3XERvsAWX4FYWbgDoGJGS0+jZjdPjvARkt4+uZuTAEUFLiQ== +"@budibase/backend-core@1.2.41-alpha.0": + version "1.2.41-alpha.0" + resolved "https://registry.yarnpkg.com/@budibase/backend-core/-/backend-core-1.2.41-alpha.0.tgz#ee3bc032ae89e347b9fb220303a9d040df6f5823" + integrity sha512-x6wJpBBFj6a1pGu2OR1vBPHiA4LvdQpVxr6f1lZa2+nAhuXVtEhrdnvBVzK2hJ52dOTTTGaw2A5tTkbf7861CA== dependencies: - "@budibase/types" "^1.2.40" + "@budibase/types" "1.2.41-alpha.0" "@techpass/passport-openidconnect" "0.3.2" aws-sdk "2.1030.0" bcrypt "5.0.1" dotenv "16.0.1" emitter-listener "1.1.2" ioredis "4.28.0" + joi "17.6.0" jsonwebtoken "8.5.1" koa-passport "4.1.4" lodash "4.17.21" @@ -324,21 +325,21 @@ uuid "8.3.2" zlib "1.0.5" -"@budibase/pro@1.2.40": - version "1.2.40" - resolved "https://registry.yarnpkg.com/@budibase/pro/-/pro-1.2.40.tgz#007cad4d8341698104498ae7d1578a7e26760dd7" - integrity sha512-lGB0/O8l63FtpP1dOzxowFUjgj7SrRSVsODygPB7oScfUBtbqHyZKC4EafrVpJT4A8hbdh1ijQZ8PLJE/YdRkQ== +"@budibase/pro@1.2.41-alpha.0": + version "1.2.41-alpha.0" + resolved "https://registry.yarnpkg.com/@budibase/pro/-/pro-1.2.41-alpha.0.tgz#4f27dbeee24ddc58e2a4e75cd90b53543f742722" + integrity sha512-LiKuO7/9GGzf3xfMmNTZQl2r4jmGgqnUf7fA5ub/MRyWYM7ZjPWEKW1V9OAk3vXwv9a+4V6FUxJQ1sDUZ3DT/Q== dependencies: - "@budibase/backend-core" "1.2.40" - "@budibase/types" "1.2.40" + "@budibase/backend-core" "1.2.41-alpha.0" + "@budibase/types" "1.2.41-alpha.0" "@koa/router" "8.0.8" joi "17.6.0" node-fetch "^2.6.1" -"@budibase/types@1.2.40", "@budibase/types@^1.2.40": - version "1.2.40" - resolved "https://registry.yarnpkg.com/@budibase/types/-/types-1.2.40.tgz#c1456728b61966cab7fe3689bd044bf415faa138" - integrity sha512-eNZFG0C/GBog87y6StKBjdF/aDJJtUHbAM8NWLUNNqTAiMxO2s3XhDN1dE6t74NBCRFzJo2sAD+34pJHhKFanQ== +"@budibase/types@1.2.41-alpha.0": + version "1.2.41-alpha.0" + resolved "https://registry.yarnpkg.com/@budibase/types/-/types-1.2.41-alpha.0.tgz#01071ce6ecef6799b04b1defce2b38e81b615f9f" + integrity sha512-2jkeToXsujYUXb6P2DFTFUOFv56GgImJ4webP8xr5cPGL0/xmhWGMd/lLxLt96RtMQp43UmVWZm1BA7TZw4fJg== "@cspotcode/source-map-consumer@0.8.0": version "0.8.0"