diff --git a/CHANGES.md b/CHANGES.md index 88fb94a9a..6a8098fe7 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -12,6 +12,16 @@ ### :heart: Community contributions by (Thank you!) +## 1.5.1-alpha + +### :bug: Bugs fixed + +- Fix issue with bitmap image clipboard. +- Fix issue when removing all path points. +- Increase default team invitation token expiration to 48h. +- Fix wrong error message when an expired token is used. + + ## 1.5.0-alpha ### :sparkles: New features diff --git a/backend/src/app/loggers/mattermost.clj b/backend/src/app/loggers/mattermost.clj index 6b2c7dc8c..ec5d8b52e 100644 --- a/backend/src/app/loggers/mattermost.clj +++ b/backend/src/app/loggers/mattermost.clj @@ -39,8 +39,8 @@ :opt-un [::uri])) (defmethod ig/init-key ::reporter - [_ {:keys [receiver] :as cfg}] - (l/info :msg "intializing mattermost error reporter") + [_ {:keys [receiver uri] :as cfg}] + (l/info :msg "intializing mattermost error reporter" :uri uri) (let [output (a/chan (a/sliding-buffer 128) (filter #(= (:level %) "error")))] (receiver :sub output) @@ -63,6 +63,7 @@ (let [uri (:uri cfg) text (str "Unhandled exception (@channel):\n" "- detail: " (cfg/get :public-uri) "/dbg/error-by-id/" id "\n" + "- profile-id: `" (:profile-id cdata) "`\n" "- host: `" host "`\n" "- version: `" version "`\n" (when error diff --git a/backend/src/app/rpc/mutations/teams.clj b/backend/src/app/rpc/mutations/teams.clj index c9adebfae..662d2dc35 100644 --- a/backend/src/app/rpc/mutations/teams.clj +++ b/backend/src/app/rpc/mutations/teams.clj @@ -309,7 +309,7 @@ team (db/get-by-id conn :team team-id) itoken (tokens :generate {:iss :team-invitation - :exp (dt/in-future "6h") + :exp (dt/in-future "48h") :profile-id (:id profile) :role role :team-id team-id diff --git a/frontend/src/app/main/ui/auth/verify_token.cljs b/frontend/src/app/main/ui/auth/verify_token.cljs index bba45581a..3e0bf5323 100644 --- a/frontend/src/app/main/ui/auth/verify_token.cljs +++ b/frontend/src/app/main/ui/auth/verify_token.cljs @@ -72,18 +72,26 @@ (rx/subs (fn [tdata] (handle-token tdata)) - (fn [error] - (case (:code error) - :email-already-exists + (fn [{:keys [type code] :as error}] + (cond + (and (= :validation type) + (= :invalid-token code) + (= :token-expired (:reason error))) + (let [msg (tr "errors.token-expired")] + (ts/schedule 100 #(st/emit! (dm/error msg))) + (st/emit! (rt/nav :auth-login))) + + (= :email-already-exists code) (let [msg (tr "errors.email-already-exists")] (ts/schedule 100 #(st/emit! (dm/error msg))) (st/emit! (rt/nav :auth-login))) - :email-already-validated + (= :email-already-validated code) (let [msg (tr "errors.email-already-validated")] (ts/schedule 100 #(st/emit! (dm/warn msg))) (st/emit! (rt/nav :auth-login))) + :else (let [msg (tr "errors.generic")] (ts/schedule 100 #(st/emit! (dm/error msg))) (st/emit! (rt/nav :auth-login))))))))) diff --git a/frontend/src/app/main/ui/dashboard/team.cljs b/frontend/src/app/main/ui/dashboard/team.cljs index d1126444e..64eed4bee 100644 --- a/frontend/src/app/main/ui/dashboard/team.cljs +++ b/frontend/src/app/main/ui/dashboard/team.cljs @@ -85,7 +85,8 @@ ;; https://tree.taiga.io/project/uxboxproject/issue/1083 ;; {:value "viewer" :label (tr "labels.viewer")}] - initial (mf/use-memo (mf/deps team) (constantly {:team-id (:id team)})) + initial (mf/use-memo (mf/deps team) (constantly {:team-id (:id team) + :role "editor"})) form (fm/use-form :spec ::invite-member-form :initial initial) on-success diff --git a/frontend/src/app/main/ui/onboarding.cljs b/frontend/src/app/main/ui/onboarding.cljs index 963e0cae3..a14f22a9f 100644 --- a/frontend/src/app/main/ui/onboarding.cljs +++ b/frontend/src/app/main/ui/onboarding.cljs @@ -6,6 +6,7 @@ (ns app.main.ui.onboarding (:require + [app.config :as cf] [app.common.spec :as us] [app.main.data.dashboard :as dd] [app.main.data.messages :as dm] @@ -38,9 +39,9 @@ [:div.modal-right [:div.modal-title [:h2 "Welcome to Penpot!"]] - [:span.release "Alpha version 1.0"] + [:span.release "Alpha version " (:main @cf/version)] [:div.modal-content - [:p "We are very happy to introduce you to the very first Alpha 1.0 release."] + [:p "We are very happy to introduce you to the very first Alpha release."] [:p "Penpot is still at development stage and there will be constant updates. We hope you enjoy the first stable version."]] [:div.modal-navigation [:button.btn-secondary {:on-click next} "Continue"]]] diff --git a/frontend/translations/en.po b/frontend/translations/en.po index 422b472e6..e8a386c23 100644 --- a/frontend/translations/en.po +++ b/frontend/translations/en.po @@ -535,6 +535,10 @@ msgstr "The registration is currently disabled." msgid "errors.terms-privacy-agreement-invalid" msgstr "You must accept our terms of service and privacy policy." +#: src/app/main/ui/auth/verify_token.cljs +msgid "errors.token-expired" +msgstr "Token expired" + #: src/app/main/data/media.cljs, src/app/main/ui/workspace/sidebar/options/menus/exports.cljs, src/app/main/ui/handoff/exports.cljs msgid "errors.unexpected-error" msgstr "An unexpected error occurred." @@ -1111,9 +1115,7 @@ msgstr "Verify new email" #: src/app/main/ui/settings/change_email.cljs msgid "modals.change-email.info" -msgstr "" -"We'll send you an email to your current email “%s” to verify your " -"identity." +msgstr "We'll send you an email to your current email “%s” to verify your identity." #: src/app/main/ui/settings/change_email.cljs msgid "modals.change-email.new-email" @@ -1137,9 +1139,7 @@ msgstr "Yes, delete my account" #: src/app/main/ui/settings/delete_account.cljs msgid "modals.delete-account.info" -msgstr "" -"By removing your account you’ll lose all your current projects and " -"archives." +msgstr "By removing your account you’ll lose all your current projects and archives." #: src/app/main/ui/settings/delete_account.cljs msgid "modals.delete-account.title" diff --git a/frontend/translations/es.po b/frontend/translations/es.po index af64dc802..14c8bec4e 100644 --- a/frontend/translations/es.po +++ b/frontend/translations/es.po @@ -556,6 +556,10 @@ msgstr "El registro está actualmente desactivado." msgid "errors.terms-privacy-agreement-invalid" msgstr "Debes aceptar nuestros términos de servicio y política de privacidad." +#: src/app/main/ui/auth/verify_token.cljs +msgid "errors.token-expired" +msgstr "Token expirado" + #: src/app/main/data/media.cljs, src/app/main/ui/workspace/sidebar/options/menus/exports.cljs, src/app/main/ui/handoff/exports.cljs msgid "errors.unexpected-error" msgstr "Ha ocurrido un error inesperado."