From cd0276e5988ed1fdb9f64d48b7a402cb73671496 Mon Sep 17 00:00:00 2001 From: dec0dOS Date: Sat, 18 Jun 2022 14:44:59 +0300 Subject: [PATCH 001/126] chore: fix release command --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index ef69551..77996f2 100644 --- a/package.json +++ b/package.json @@ -13,7 +13,7 @@ "dev": "concurrently \"cd frontend && cross-env FAST_REFRESH=true yarn start\" \"cd backend && cross-env NODE_ENV=development ZU_DEFAULT_USERNAME=admin ZU_DEFAULT_PASSWORD=zero-ui nodemon ./bin/www --ignore data/db.json\"", "build": "cd frontend && cross-env INLINE_RUNTIME_CHUNK=false GENERATE_SOURCEMAP=false yarn build", "prod": "cd backend && cross-env NODE_ENV=production ZU_SECURE_HEADERS=false yarn start", - "release": "standard-version && git push --follow-tags origin main", + "release": "standard-version && git push --follow-tags origin main && git add CHANGELOG.md", "commit": "yarn git-cz" }, "devDependencies": { From 2396e973dc4e40f247cb5fef75d0403ccf0a285a Mon Sep 17 00:00:00 2001 From: dec0dOS Date: Sat, 18 Jun 2022 14:55:33 +0300 Subject: [PATCH 002/126] feat: support http basic auth --- .../HomeLoggedOut/HomeLoggedOut.jsx | 22 ++++++++++--------- frontend/src/utils/API.js | 1 + 2 files changed, 13 insertions(+), 10 deletions(-) diff --git a/frontend/src/components/HomeLoggedOut/HomeLoggedOut.jsx b/frontend/src/components/HomeLoggedOut/HomeLoggedOut.jsx index e551f0c..0de5572 100644 --- a/frontend/src/components/HomeLoggedOut/HomeLoggedOut.jsx +++ b/frontend/src/components/HomeLoggedOut/HomeLoggedOut.jsx @@ -13,16 +13,18 @@ function HomeLoggedOut() { useEffect(() => { async function fetchData() { - axios.get("/auth/login").then(function (response) { - if (!response.data.enabled) { - setLoggedIn(true); - setDisableAuth(true); - setToken(""); - history.go(0); - } else { - setDisableAuth(false); - } - }); + axios + .get("/auth/login", { withCredentials: true }) + .then(function (response) { + if (!response.data.enabled) { + setLoggedIn(true); + setDisableAuth(true); + setToken(""); + history.go(0); + } else { + setDisableAuth(false); + } + }); } fetchData(); }, [history, setDisableAuth, setLoggedIn, setToken]); diff --git a/frontend/src/utils/API.js b/frontend/src/utils/API.js index 4656032..847d940 100644 --- a/frontend/src/utils/API.js +++ b/frontend/src/utils/API.js @@ -5,6 +5,7 @@ const baseURL = "/api/"; export default axios.create({ baseURL: baseURL, responseType: "json", + withCredentials: "true", headers: localStorage.getItem("disableAuth") === "true" ? {} From 153563dc88f373dd4099f5f1447aa1a210699fd4 Mon Sep 17 00:00:00 2001 From: dec0dOS Date: Sat, 18 Jun 2022 14:57:08 +0300 Subject: [PATCH 003/126] chore(release): 1.4.0 --- CHANGELOG.md | 6 ++++++ package.json | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index e9f0e54..9848be5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,12 @@ All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines. +## [1.4.0](https://github.com/dec0dOS/zero-ui/compare/v1.3.2...v1.4.0) (2022-06-18) + +### Features + +- support http basic auth ([2396e97](https://github.com/dec0dOS/zero-ui/commit/2396e973dc4e40f247cb5fef75d0403ccf0a285a)) + ### [1.3.2](https://github.com/dec0dOS/zero-ui/compare/v1.3.1...v1.3.2) (2022-06-18) ### Bug Fixes diff --git a/package.json b/package.json index 77996f2..0d9a719 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "zero-ui", - "version": "1.3.2", + "version": "1.4.0", "workspaces": [ "backend", "frontend" From 13976c3c46c2d67f6cc6b5203a62b302cebf1a00 Mon Sep 17 00:00:00 2001 From: dec0dOS Date: Sat, 18 Jun 2022 16:13:06 +0300 Subject: [PATCH 004/126] docs: misc changes --- README.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index b54de4d..f7a1858 100755 --- a/README.md +++ b/README.md @@ -10,9 +10,9 @@ Explore the screenshots » - Report Bug + Bug Report · - Request Feature + Feature Request · Ask a Question