From 1b3921e1d8e0c17c44d739ff3497e3301c66be1f Mon Sep 17 00:00:00 2001 From: Markku Rontu Date: Fri, 31 May 2019 15:34:36 +0300 Subject: [PATCH 01/31] refactor: move jumbotron up --- src/clj/rems/css/styles.clj | 1 + src/cljs/rems/auth/auth.cljs | 15 +++++++++------ src/cljs/rems/auth/ldap.cljs | 2 +- src/cljs/rems/auth/shibboleth.cljs | 2 +- 4 files changed, 12 insertions(+), 8 deletions(-) diff --git a/src/clj/rems/css/styles.clj b/src/clj/rems/css/styles.clj index bce10174d7..2a278638b4 100644 --- a/src/clj/rems/css/styles.clj +++ b/src/clj/rems/css/styles.clj @@ -473,6 +473,7 @@ [:.login-btn {:max-height (u/px 70) :margin-bottom (u/px 20)} [:&:hover {:filter "brightness(80%)"}]] + [:.login-component {:max-width (u/px 420)}] (generate-rems-table-styles) [:.btn.disabled {:opacity 0.25}] [:.catalogue-item-link {:color "#fff" diff --git a/src/cljs/rems/auth/auth.cljs b/src/cljs/rems/auth/auth.cljs index f589ba1f8b..e106af13d0 100644 --- a/src/cljs/rems/auth/auth.cljs +++ b/src/cljs/rems/auth/auth.cljs @@ -6,12 +6,15 @@ (defn login-component [] (let [config @(rf/subscribe [:rems.config/config]) - alternative-endpoint (:alternative-login-url config)] - (case (:authentication config) - :shibboleth (shibboleth/login-component alternative-endpoint) - :fake-shibboleth (shibboleth/login-component alternative-endpoint) - :ldap (ldap/login-component) - nil))) + alternative-endpoint (:alternative-login-url config) + login-component (case (:authentication config) + :shibboleth (shibboleth/login-component alternative-endpoint) + :fake-shibboleth (shibboleth/login-component alternative-endpoint) + :ldap (ldap/login-component) + nil)] + (when login-component + [:div.jumbotron.login-component + login-component]))) (defn guide [] [:div diff --git a/src/cljs/rems/auth/ldap.cljs b/src/cljs/rems/auth/ldap.cljs index 3608850ad8..bfb3e357a4 100644 --- a/src/cljs/rems/auth/ldap.cljs +++ b/src/cljs/rems/auth/ldap.cljs @@ -3,7 +3,7 @@ [rems.text :refer [text]])) (defn login-component [] - [:div.jumbotron + [:div [document-title (text :t.ldap/title)] [:form {:action "/ldap/login" :method "post"} diff --git a/src/cljs/rems/auth/shibboleth.cljs b/src/cljs/rems/auth/shibboleth.cljs index d7eea41a35..90a8cf1380 100644 --- a/src/cljs/rems/auth/shibboleth.cljs +++ b/src/cljs/rems/auth/shibboleth.cljs @@ -5,7 +5,7 @@ [rems.text :refer [text]])) (defn login-component [alternative-endpoint] - [:div.jumbotron + [:div [document-title (text :t.login/title)] [:p (text :t.login/text)] [:div.col-md6 From 43ba4e259a5fff5a9e1c9c4aa677fbbe523f6d50 Mon Sep 17 00:00:00 2001 From: Markku Rontu Date: Fri, 31 May 2019 15:34:49 +0300 Subject: [PATCH 02/31] feat: introductory text in login --- resources/translations/en.edn | 2 ++ resources/translations/fi.edn | 2 ++ src/clj/rems/css/styles.clj | 1 - src/cljs/rems/spa.cljs | 8 +++++++- 4 files changed, 11 insertions(+), 2 deletions(-) diff --git a/resources/translations/en.edn b/resources/translations/en.edn index 9d4c482348..8509b5086d 100644 --- a/resources/translations/en.edn +++ b/resources/translations/en.edn @@ -262,6 +262,8 @@ :link {:download-file "Download file" :opens-in-new-window "Opens in new window"} :login {:alternative "Other sign in options" + :intro [:div [:h1 "Welcome to REMS"] [:p "This is a demo environment for testing the REMS software."] + [:p "Please, login first to access REMS."]] :text "Login by using your Haka credentials" :title "Login"} :missing "Missing translation %1" diff --git a/resources/translations/fi.edn b/resources/translations/fi.edn index 72f3456a33..0e13cd9112 100644 --- a/resources/translations/fi.edn +++ b/resources/translations/fi.edn @@ -262,6 +262,8 @@ :link {:download-file "Lataa tiedosto" :opens-in-new-window "Aukeaa uuteen ikkunaan"} :login {:alternative "Muut kirjautumisvaihtoehdot" + :intro [:div [:h1 "Tervetuloa REMSiin"] [:p "Tämä on demo-ympäristö, joka on tarkoitettu REMS-ohjelmiston kokeilemiseen."] + [:p "Ole hyvä ja kirjaudu sisään ensin."]] :text "Kirjaudu sisään Haka-tunnuksillasi" :title "Kirjaudu sisään"} :missing "Käännös puuttuu %1" diff --git a/src/clj/rems/css/styles.clj b/src/clj/rems/css/styles.clj index 2a278638b4..0a9dd11a41 100644 --- a/src/clj/rems/css/styles.clj +++ b/src/clj/rems/css/styles.clj @@ -463,7 +463,6 @@ [:.jumbotron {:background-color "#fff" :text-align "center" - :max-width (u/px 420) :margin "30px auto" :color "#000" :border-style "solid" diff --git a/src/cljs/rems/spa.cljs b/src/cljs/rems/spa.cljs index 21127686e0..61bc849489 100644 --- a/src/cljs/rems/spa.cljs +++ b/src/cljs/rems/spa.cljs @@ -191,7 +191,13 @@ (do (rf/dispatch [:rems.catalogue/enter-page]) [catalogue-page]) - [auth/login-component])) + [:div + [:div.row.justify-content-center + [:div.col-md-6 + (text :t.login/intro)]] + [:div.row.justify-content-center + [:div.col-md-6 + [auth/login-component]]]])) (defn unauthorized-page [] [:div From 84071a74c01179e4091e4a8182bade16a193e4e4 Mon Sep 17 00:00:00 2001 From: Markku Rontu Date: Fri, 31 May 2019 18:30:35 +0300 Subject: [PATCH 03/31] feat: catalogue page intro texts --- example-theme/extra-translations/fi.edn | 3 ++- resources/translations/en.edn | 2 ++ resources/translations/fi.edn | 2 ++ src/cljs/rems/catalogue.cljs | 2 ++ 4 files changed, 8 insertions(+), 1 deletion(-) diff --git a/example-theme/extra-translations/fi.edn b/example-theme/extra-translations/fi.edn index cd331eae90..9c04130b50 100644 --- a/example-theme/extra-translations/fi.edn +++ b/example-theme/extra-translations/fi.edn @@ -7,5 +7,6 @@ :header "%1 kielivaraa korissa"} :catalogue {:catalogue "Kielivarat" :header "Kielivarat" + :intro "Tällä sivulla on listattuna kaikki kielivarat joita voit tästä järjestelmästä hakea." :apply-resources "Hae uusia kielivaroja"} - :navigation {:catalogue "Kielivarat"}}} \ No newline at end of file + :navigation {:catalogue "Kielivarat"}}} diff --git a/resources/translations/en.edn b/resources/translations/en.edn index 8509b5086d..539bab2e3f 100644 --- a/resources/translations/en.edn +++ b/resources/translations/en.edn @@ -144,8 +144,10 @@ :remove "Remove"} :catalogue {:catalogue "Catalogue" :header "Resource" + :intro "The catalogue contains all the resources that you can apply for in this system." :more-info "More info" :continue-existing-application "Continue existing application" + :continue-existing-application-intro "You have existing unfinished applications that you can continue from here." :apply-resources "Apply for resources"} :collapse {:show-less "Show less" :show-more "Show more"} diff --git a/resources/translations/fi.edn b/resources/translations/fi.edn index 0e13cd9112..deb5111d36 100644 --- a/resources/translations/fi.edn +++ b/resources/translations/fi.edn @@ -144,8 +144,10 @@ :remove "Poista"} :catalogue {:catalogue "Aineistoluettelo" :header "Aineistoluettelo" + :intro "Aineistoluettelossa on listattuna kaikki resurssit joita voit tästä järjestelmästä hakea." :more-info "Lisätietoja" :continue-existing-application "Jatka hakemusta" + :continue-existing-application-intro "Sinulla on keskeneräisiä hakemuksia, joita voit jatkaa tästä." :apply-resources "Hae uusia resursseja"} :collapse {:show-less "Näytä vähemmän" :show-more "Näytä lisää"} diff --git a/src/cljs/rems/catalogue.cljs b/src/cljs/rems/catalogue.cljs index 6827ae24d2..dc63fd90e9 100644 --- a/src/cljs/rems/catalogue.cljs +++ b/src/cljs/rems/catalogue.cljs @@ -100,6 +100,7 @@ (when (seq @(rf/subscribe [applications])) [:div [:h2 (text :t.catalogue/continue-existing-application)] + (text :t.catalogue/continue-existing-application-intro) [application-list/component {:id applications :applications applications @@ -126,6 +127,7 @@ loading-drafts? @(rf/subscribe [::loading-drafts?])] [:div [document-title (text :t.catalogue/catalogue)] + (text :t.catalogue/intro) (if (or loading-catalogue? loading-drafts?) [spinner/big] [:div From c36382137c8b0602dbf423a005d8bf469f6b1259 Mon Sep 17 00:00:00 2001 From: Markku Rontu Date: Fri, 31 May 2019 18:30:44 +0300 Subject: [PATCH 04/31] style: more margin to the top of h2 --- src/clj/rems/css/styles.clj | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/clj/rems/css/styles.clj b/src/clj/rems/css/styles.clj index 0a9dd11a41..9c4c71ae65 100644 --- a/src/clj/rems/css/styles.clj +++ b/src/clj/rems/css/styles.clj @@ -634,7 +634,7 @@ (-> (util/get-theme-attribute :color1) (c/saturate -50) (c/lighten 33)))}] - [:h2 {:margin [[(u/rem 1) 0]]}] + [:h2 {:margin [[(u/rem 3) 0 (u/rem 1) 0]]}] ;; application list [:.rems-table From 6e3715eec1c304334d3b839fccf2760f6a8eaf42 Mon Sep 17 00:00:00 2001 From: Markku Rontu Date: Tue, 4 Jun 2019 13:32:33 +0300 Subject: [PATCH 05/31] style: login jumbo to match content size with margin --- src/clj/rems/css/styles.clj | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/clj/rems/css/styles.clj b/src/clj/rems/css/styles.clj index 9c4c71ae65..01ff56ea92 100644 --- a/src/clj/rems/css/styles.clj +++ b/src/clj/rems/css/styles.clj @@ -463,8 +463,8 @@ [:.jumbotron {:background-color "#fff" :text-align "center" - :margin "30px auto" :color "#000" + :margin-top (u/rem 2) :border-style "solid" :border-width (u/px 1) :box-shadow (util/get-theme-attribute :collapse-shadow :table-shadow)} From 18debab3949cee3454e8e386aa21e1afa64cac58 Mon Sep 17 00:00:00 2001 From: Markku Rontu Date: Tue, 4 Jun 2019 16:29:30 +0300 Subject: [PATCH 06/31] style: catalogue intro --- resources/translations/en.edn | 2 +- resources/translations/fi.edn | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/resources/translations/en.edn b/resources/translations/en.edn index 539bab2e3f..8d40d9a05e 100644 --- a/resources/translations/en.edn +++ b/resources/translations/en.edn @@ -144,7 +144,7 @@ :remove "Remove"} :catalogue {:catalogue "Catalogue" :header "Resource" - :intro "The catalogue contains all the resources that you can apply for in this system." + :intro [:p "The catalogue contains all the resources that you can apply for in this system."] :more-info "More info" :continue-existing-application "Continue existing application" :continue-existing-application-intro "You have existing unfinished applications that you can continue from here." diff --git a/resources/translations/fi.edn b/resources/translations/fi.edn index deb5111d36..3b633f9e50 100644 --- a/resources/translations/fi.edn +++ b/resources/translations/fi.edn @@ -144,7 +144,7 @@ :remove "Poista"} :catalogue {:catalogue "Aineistoluettelo" :header "Aineistoluettelo" - :intro "Aineistoluettelossa on listattuna kaikki resurssit joita voit tästä järjestelmästä hakea." + :intro [:p "Aineistoluettelossa on listattuna kaikki resurssit joita voit tästä järjestelmästä hakea."] :more-info "Lisätietoja" :continue-existing-application "Jatka hakemusta" :continue-existing-application-intro "Sinulla on keskeneräisiä hakemuksia, joita voit jatkaa tästä." From 2b9be010c163f9b6011cfb51099233feda648867 Mon Sep 17 00:00:00 2001 From: Markku Rontu Date: Tue, 4 Jun 2019 16:29:51 +0300 Subject: [PATCH 07/31] style: margin for h1 --- src/clj/rems/css/styles.clj | 1 + 1 file changed, 1 insertion(+) diff --git a/src/clj/rems/css/styles.clj b/src/clj/rems/css/styles.clj index 01ff56ea92..5bb73de1bf 100644 --- a/src/clj/rems/css/styles.clj +++ b/src/clj/rems/css/styles.clj @@ -281,6 +281,7 @@ [:h1 :h2 {:font-weight 400}] [:h1 :h2 :h3 {:letter-spacing (u/rem 0.17)}] [:h4 :h5 :h6 {:letter-spacing (u/rem 0.12)}] + [:h1 {:margin-bottom (u/rem 2)}] [:#app {:min-height (u/percent 100) :flex 1 :display :flex}] From 0d7533cf5fa1519d47407fded8a75efb4efefa6e Mon Sep 17 00:00:00 2001 From: Markku Rontu Date: Tue, 4 Jun 2019 16:31:13 +0300 Subject: [PATCH 08/31] feat: application intro --- resources/translations/en.edn | 1 + resources/translations/fi.edn | 1 + src/clj/rems/css/styles.clj | 1 + src/cljs/rems/application.cljs | 1 + 4 files changed, 4 insertions(+) diff --git a/resources/translations/en.edn b/resources/translations/en.edn index 8d40d9a05e..09823927e3 100644 --- a/resources/translations/en.edn +++ b/resources/translations/en.edn @@ -124,6 +124,7 @@ :returned "Changes requested" :submitted "Applied" :unknown "Unknown"} + :intro [:div.intro [:p "By filling and sending in this application, all the applicants may be granted the applied resources. All the applicable licenses must also be accepted before or after applying."]] :my-applications "My Applications" :state "State" :states {:approved "Approved" diff --git a/resources/translations/fi.edn b/resources/translations/fi.edn index 3b633f9e50..2b1049ae54 100644 --- a/resources/translations/fi.edn +++ b/resources/translations/fi.edn @@ -124,6 +124,7 @@ :returned "Palautettu muokattavaksi" :submitted "Haettu" :unknown "Tuntematon"} + :intro [:div.intro [:p "Täyttämällä ja lähettämällä tämän hakemuksen, kaikki hakijat voivat saada oikeuden haettuihin resursseihin. Kaikkien on sen lisäksi hyväksyttävä kaikki käyttöehdot viimeistään hakemuksen käsittelyn jälkeen saadakseen käyttöoikeudet."]] :my-applications "Omat hakemukset" :state "Tila" :states {:approved "Hyväksytty" diff --git a/src/clj/rems/css/styles.clj b/src/clj/rems/css/styles.clj index 5bb73de1bf..b880ed89b5 100644 --- a/src/clj/rems/css/styles.clj +++ b/src/clj/rems/css/styles.clj @@ -578,6 +578,7 @@ [:.new-form-field-option {:text-align "center"}] [:.full {:width "100%"}] + [:.intro {:margin-bottom (u/rem 2)}] [:.rectangle {:width (u/px 50) :height (u/px 50)}] [:.color-1 {:background-color (util/get-theme-attribute :color1)}] diff --git a/src/cljs/rems/application.cljs b/src/cljs/rems/application.cljs index 3080b1b9a8..1a7b10376c 100644 --- a/src/cljs/rems/application.cljs +++ b/src/cljs/rems/application.cljs @@ -581,6 +581,7 @@ [:div [:div {:class "float-right"} [pdf-button (:application/id application)]] [document-title (text :t.applications/application)] + (text :t.applications/intro) (into [:div] messages) [application-header application] [:div.mt-3 [applicants-info application]] From 9cc689264c08840b7c18f0a8e5e830a7ab68222e Mon Sep 17 00:00:00 2001 From: Markku Rontu Date: Thu, 6 Jun 2019 18:48:18 +0300 Subject: [PATCH 09/31] style: center login page content --- src/cljs/rems/spa.cljs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/cljs/rems/spa.cljs b/src/cljs/rems/spa.cljs index 61bc849489..0f0c368909 100644 --- a/src/cljs/rems/spa.cljs +++ b/src/cljs/rems/spa.cljs @@ -193,10 +193,10 @@ [catalogue-page]) [:div [:div.row.justify-content-center - [:div.col-md-6 + [:div.col-md-6.row.justify-content-center (text :t.login/intro)]] [:div.row.justify-content-center - [:div.col-md-6 + [:div.col-md-6.row.justify-content-center [auth/login-component]]]])) (defn unauthorized-page [] From 2eaaf0fd2f6b53bc53c4d2f1a1b4ae74ca92c39d Mon Sep 17 00:00:00 2001 From: Markku Rontu Date: Thu, 6 Jun 2019 19:26:35 +0300 Subject: [PATCH 10/31] refactor: application-state component - rename - move state to its own row from header - add colon to latest activity --- resources/translations/en.edn | 2 +- resources/translations/fi.edn | 2 +- src/cljs/rems/application.cljs | 12 ++++++------ 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/resources/translations/en.edn b/resources/translations/en.edn index 09823927e3..4f61b82593 100644 --- a/resources/translations/en.edn +++ b/resources/translations/en.edn @@ -134,7 +134,7 @@ :returned "Returned" :submitted "Applied" :unknown "Unknown"} - :latest-activity "Latest activity %1" + :latest-activity "Latest activity: %1" :view "View"} :autocomplete {:no-results "No results" :placeholder "Choose or type"} diff --git a/resources/translations/fi.edn b/resources/translations/fi.edn index 2b1049ae54..b1d0d605e1 100644 --- a/resources/translations/fi.edn +++ b/resources/translations/fi.edn @@ -134,7 +134,7 @@ :returned "Palautettu" :submitted "Haettu" :unknown "Tuntematon"} - :latest-activity "Viimeisin toimenpide %1" + :latest-activity "Viimeisin toimenpide: %1" :view "Näytä"} :autocomplete {:no-results "Ei tuloksia" :placeholder "Valitse tai kirjoita"} diff --git a/src/cljs/rems/application.cljs b/src/cljs/rems/application.cljs index 1a7b10376c..5a1d12cd43 100644 --- a/src/cljs/rems/application.cljs +++ b/src/cljs/rems/application.cljs @@ -389,7 +389,7 @@ {:phase :approve :text :t.phases/approve} {:phase :result :text :t.phases/approved}])) -(defn- application-header [application] +(defn- application-state [application] (let [state (:application/state application) last-activity (:application/last-activity application) event-groups (->> (:application/events application) @@ -402,13 +402,13 @@ (map #(map format-event %)))] [collapsible/component {:id "header" - :title [:span#application-state - (str - (text :t.applications/state) - (str ": " (localize-state state)))] + :title (text :t.applications/state) :always (into [:div [:div.mb-3 {:class (str "state-" (name state))} (phases (get-application-phases state))] + [:h3#application-state + (str (text :t.applications/state) ": ") + (localize-state state)] [:h3 (text-format :t.applications/latest-activity (localize-time last-activity))]] (when-let [g (first event-groups)] (into [[:h3 (text :t.form/events)]] @@ -583,7 +583,7 @@ [document-title (text :t.applications/application)] (text :t.applications/intro) (into [:div] messages) - [application-header application] + [application-state application] [:div.mt-3 [applicants-info application]] [:div.mt-3 [applied-resources application userid]] [:div.my-3 [application-fields application edit-application]] From d646a2d9971782d1e4c71f56a3a926ad8d3e8457 Mon Sep 17 00:00:00 2001 From: Markku Rontu Date: Thu, 6 Jun 2019 19:30:19 +0300 Subject: [PATCH 11/31] refactor: use info-fields for application state This is more consitent with the other sections. --- src/cljs/rems/application.cljs | 12 ++++++++---- test/clj/rems/test_browser.clj | 2 +- 2 files changed, 9 insertions(+), 5 deletions(-) diff --git a/src/cljs/rems/application.cljs b/src/cljs/rems/application.cljs index 5a1d12cd43..17c777d089 100644 --- a/src/cljs/rems/application.cljs +++ b/src/cljs/rems/application.cljs @@ -406,10 +406,14 @@ :always (into [:div [:div.mb-3 {:class (str "state-" (name state))} (phases (get-application-phases state))] - [:h3#application-state - (str (text :t.applications/state) ": ") - (localize-state state)] - [:h3 (text-format :t.applications/latest-activity (localize-time last-activity))]] + [info-field + (text :t.applications/state) + [:span#application-state (localize-state state)] + {:inline? true}] + [info-field + (text :t.applications/latest-activity) + (localize-time last-activity) + {:inline? true}]] (when-let [g (first event-groups)] (into [[:h3 (text :t.form/events)]] (render-event-groups [g])))) diff --git a/test/clj/rems/test_browser.clj b/test/clj/rems/test_browser.clj index 83a265f227..99b43dd9fd 100644 --- a/test/clj/rems/test_browser.clj +++ b/test/clj/rems/test_browser.clj @@ -222,7 +222,7 @@ (check-box "disease_prevention") (send-application) - (is (= "State: Applied" (get-element-text *driver* :application-state))) + (is (= "Applied" (get-element-text *driver* :application-state))) (accept-licenses) From 6fb1ccedf6c7f6eec936930f3b0cfb5c325494b3 Mon Sep 17 00:00:00 2001 From: Markku Rontu Date: Thu, 6 Jun 2019 21:38:33 +0300 Subject: [PATCH 12/31] feat: simplify extra translations - remove LBR texts - use more sensible example of replacement --- example-theme/extra-translations/en.edn | 2 +- example-theme/extra-translations/fi.edn | 13 +------------ test/clj/rems/test_locales.clj | 2 +- 3 files changed, 3 insertions(+), 14 deletions(-) diff --git a/example-theme/extra-translations/en.edn b/example-theme/extra-translations/en.edn index 5b4c9eb9b8..ec7c24640d 100644 --- a/example-theme/extra-translations/en.edn +++ b/example-theme/extra-translations/en.edn @@ -1,3 +1,3 @@ {:t {:administration {:catalogue-items "Catalogue"} - :create-license {:license-text "Licence text"}}} + :create-license {:license-text "Text"}}} diff --git a/example-theme/extra-translations/fi.edn b/example-theme/extra-translations/fi.edn index 9c04130b50..12d7172cd2 100644 --- a/example-theme/extra-translations/fi.edn +++ b/example-theme/extra-translations/fi.edn @@ -1,12 +1 @@ -{:t - {:actions {:resource "Kielivara"} - :administration {:catalogue-item "Kielivara" - :catalogue-items "Kielivarat" - :create-catalogue-item "Uusi kielivara"} - :cart {:apply-for-bundle "Hae näitä kielivaroja (%1 kpl) yhdessä " - :header "%1 kielivaraa korissa"} - :catalogue {:catalogue "Kielivarat" - :header "Kielivarat" - :intro "Tällä sivulla on listattuna kaikki kielivarat joita voit tästä järjestelmästä hakea." - :apply-resources "Hae uusia kielivaroja"} - :navigation {:catalogue "Kielivarat"}}} +{:t {}} diff --git a/test/clj/rems/test_locales.clj b/test/clj/rems/test_locales.clj index 599bdf03a8..e031e491d5 100644 --- a/test/clj/rems/test_locales.clj +++ b/test/clj/rems/test_locales.clj @@ -94,7 +94,7 @@ :translations-directory "translations/" :theme-path "./example-theme/theme.edn"})] (is (= "Catalogue" (getx-in translations [:en :t :administration :catalogue-items]))) - (is (= "Licence text" (getx-in translations [:en :t :create-license :license-text]))))) + (is (= "Text" (getx-in translations [:en :t :create-license :license-text]))))) (testing "extra translations don't override keys that are not defined in extras" (let [translations (locales/load-translations {:languages [:en] :translations-directory "translations/" From d2ab59e024199bc7c50a6ceeffc949a69162b05d Mon Sep 17 00:00:00 2001 From: Markku Rontu Date: Thu, 6 Jun 2019 21:39:25 +0300 Subject: [PATCH 13/31] feat: improved login style and text --- resources/translations/en.edn | 4 ++-- resources/translations/fi.edn | 4 ++-- src/cljs/rems/auth/shibboleth.cljs | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/resources/translations/en.edn b/resources/translations/en.edn index 4f61b82593..215d6c5646 100644 --- a/resources/translations/en.edn +++ b/resources/translations/en.edn @@ -265,8 +265,8 @@ :link {:download-file "Download file" :opens-in-new-window "Opens in new window"} :login {:alternative "Other sign in options" - :intro [:div [:h1 "Welcome to REMS"] [:p "This is a demo environment for testing the REMS software."] - [:p "Please, login first to access REMS."]] + :intro [:div [:h1 "Welcome to REMS"] [:p "This is a demo environment for testing the REMS software. The demo environment has a couple of fictional datasets to which you can apply for access. More information available on the " [:a {:href "#/extra-pages/about"} "About"] " page."] + [:p "Please, login to access REMS."]] :text "Login by using your Haka credentials" :title "Login"} :missing "Missing translation %1" diff --git a/resources/translations/fi.edn b/resources/translations/fi.edn index b1d0d605e1..3fd0ebeccb 100644 --- a/resources/translations/fi.edn +++ b/resources/translations/fi.edn @@ -265,8 +265,8 @@ :link {:download-file "Lataa tiedosto" :opens-in-new-window "Aukeaa uuteen ikkunaan"} :login {:alternative "Muut kirjautumisvaihtoehdot" - :intro [:div [:h1 "Tervetuloa REMSiin"] [:p "Tämä on demo-ympäristö, joka on tarkoitettu REMS-ohjelmiston kokeilemiseen."] - [:p "Ole hyvä ja kirjaudu sisään ensin."]] + :intro [:div [:h1 "Tervetuloa REMSiin"] [:p "Tämä on demo-ympäristö, joka on tarkoitettu REMS-ohjelmiston kokeilemiseen. Demo-ympäristöön on luotu valmiiksi joitain kuvitteellisia tietoaineistoja, joihin voit hakea käyttöoikeutta. Lisätietoja " [:a {:href "#/extra-pages/about"} "Info-sivulla"] "."] + [:p "Ole hyvä ja kirjaudu sisään."]] :text "Kirjaudu sisään Haka-tunnuksillasi" :title "Kirjaudu sisään"} :missing "Käännös puuttuu %1" diff --git a/src/cljs/rems/auth/shibboleth.cljs b/src/cljs/rems/auth/shibboleth.cljs index 90a8cf1380..e6ac20c4a5 100644 --- a/src/cljs/rems/auth/shibboleth.cljs +++ b/src/cljs/rems/auth/shibboleth.cljs @@ -8,7 +8,7 @@ [:div [document-title (text :t.login/title)] [:p (text :t.login/text)] - [:div.col-md6 + [:div [atoms/link-to nil (nav/url-dest "/Shibboleth.sso/Login") [atoms/image {:class "login-btn" :alt "Haka"} "/img/haka-logo.jpg"]]] From 0563f37423bd6060fb3b57dc4e3bd145455599af Mon Sep 17 00:00:00 2001 From: Markku Rontu Date: Thu, 6 Jun 2019 21:40:25 +0300 Subject: [PATCH 14/31] feat: cart intro Also include empty text --- resources/translations/en.edn | 2 ++ resources/translations/fi.edn | 2 ++ src/cljs/rems/cart.cljs | 27 +++++++++++++++------------ 3 files changed, 19 insertions(+), 12 deletions(-) diff --git a/resources/translations/en.edn b/resources/translations/en.edn index 215d6c5646..bd715e3609 100644 --- a/resources/translations/en.edn +++ b/resources/translations/en.edn @@ -141,7 +141,9 @@ :cart {:add "Add to cart" :apply "Apply" :apply-for-bundle "Apply for these %1 resources as a bundle " + :empty [:div.intro [:p "Select resources to apply for."]] :header "%1 resources in cart" + :intro [:div.intro [:p "Here are all the resources that you have picked. If the resources can be applied with the same application, they will be automatically grouped into a bundle."]] :remove "Remove"} :catalogue {:catalogue "Catalogue" :header "Resource" diff --git a/resources/translations/fi.edn b/resources/translations/fi.edn index 3fd0ebeccb..eebe9c863e 100644 --- a/resources/translations/fi.edn +++ b/resources/translations/fi.edn @@ -141,7 +141,9 @@ :cart {:add "Lisää koriin" :apply "Hae" :apply-for-bundle "Hae näitä aineistoja (%1 kpl) yhdessä " + :empty [:div.intro [:p "Valitse resursseja haettavaksi."]] :header "%1 aineistoa korissa" + :intro [:div.intro [:p "Tässä ovat kaikki resurssit jotka olet valinnut. Resurssit jotka voi hakea samalla hakemuksella ryhmitellään automaattisesti yhteen."]] :remove "Poista"} :catalogue {:catalogue "Aineistoluettelo" :header "Aineistoluettelo" diff --git a/src/cljs/rems/cart.cljs b/src/cljs/rems/cart.cljs index 53fe43285a..53980aa2c6 100644 --- a/src/cljs/rems/cart.cljs +++ b/src/cljs/rems/cart.cljs @@ -69,18 +69,21 @@ (defn cart-list "List of shopping cart items" [items language] - (when (seq items) - [:div.outer-cart.mb-3 - [:div.inner-cart - [:div.cart-title - [:i.fa.fa-shopping-cart] - [:span (text-format :t.cart/header (count items))]] - [:table.rems-table.cart - (into [:tbody] - (let [key-fn #(select-vals % [:wfid :formid])] - (apply concat - (for [group (vals (into (sorted-map) (group-by key-fn items)))] - (group-view (sort-by get-localized-title group) language)))))]]])) + (if (seq items) + [:div + (text :t.cart/intro) + [:div.outer-cart.mb-3 + [:div.inner-cart + [:div.cart-title + [:i.fa.fa-shopping-cart] + [:span (text-format :t.cart/header (count items))]] + [:table.rems-table.cart + (into [:tbody] + (let [key-fn #(select-vals % [:wfid :formid])] + (apply concat + (for [group (vals (into (sorted-map) (group-by key-fn items)))] + (group-view (sort-by get-catalogue-item-title group) language)))))]]]] + (text :t.cart/empty))) (defn cart-list-container [] (let [language @(rf/subscribe [:language]) From e2c2401f51e3522f1f1d1985b783d08c07bbcfab Mon Sep 17 00:00:00 2001 From: Markku Rontu Date: Thu, 6 Jun 2019 21:40:50 +0300 Subject: [PATCH 15/31] style: improved existing application intro --- resources/translations/en.edn | 2 +- resources/translations/fi.edn | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/resources/translations/en.edn b/resources/translations/en.edn index bd715e3609..836691e0a0 100644 --- a/resources/translations/en.edn +++ b/resources/translations/en.edn @@ -150,7 +150,7 @@ :intro [:p "The catalogue contains all the resources that you can apply for in this system."] :more-info "More info" :continue-existing-application "Continue existing application" - :continue-existing-application-intro "You have existing unfinished applications that you can continue from here." + :continue-existing-application-intro [:div.intro [:p "You have existing unfinished applications that you can continue from here."]] :apply-resources "Apply for resources"} :collapse {:show-less "Show less" :show-more "Show more"} diff --git a/resources/translations/fi.edn b/resources/translations/fi.edn index eebe9c863e..dcb7a32e5c 100644 --- a/resources/translations/fi.edn +++ b/resources/translations/fi.edn @@ -150,7 +150,7 @@ :intro [:p "Aineistoluettelossa on listattuna kaikki resurssit joita voit tästä järjestelmästä hakea."] :more-info "Lisätietoja" :continue-existing-application "Jatka hakemusta" - :continue-existing-application-intro "Sinulla on keskeneräisiä hakemuksia, joita voit jatkaa tästä." + :continue-existing-application-intro [:div.intro [:p "Sinulla on keskeneräisiä hakemuksia, joita voit jatkaa tästä."]] :apply-resources "Hae uusia resursseja"} :collapse {:show-less "Näytä vähemmän" :show-more "Näytä lisää"} From 9b1f018fabcc3374907a2185fa53d02a12b532dd Mon Sep 17 00:00:00 2001 From: Markku Rontu Date: Wed, 12 Jun 2019 16:23:54 +0300 Subject: [PATCH 16/31] tune: slightly improved texts --- resources/translations/en.edn | 4 ++-- resources/translations/fi.edn | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/resources/translations/en.edn b/resources/translations/en.edn index 836691e0a0..c241e25d69 100644 --- a/resources/translations/en.edn +++ b/resources/translations/en.edn @@ -124,7 +124,7 @@ :returned "Changes requested" :submitted "Applied" :unknown "Unknown"} - :intro [:div.intro [:p "By filling and sending in this application, all the applicants may be granted the applied resources. All the applicable licenses must also be accepted before or after applying."]] + :intro [:div.intro [:p "By filling and sending in this application, the applicants may be granted the applied resources. All the applicable terms of use must also be accepted before or after applying by all the applicants."]] :my-applications "My Applications" :state "State" :states {:approved "Approved" @@ -143,7 +143,7 @@ :apply-for-bundle "Apply for these %1 resources as a bundle " :empty [:div.intro [:p "Select resources to apply for."]] :header "%1 resources in cart" - :intro [:div.intro [:p "Here are all the resources that you have picked. If the resources can be applied with the same application, they will be automatically grouped into a bundle."]] + :intro [:div.intro [:p "Here are the resources that you have selected. If the resources can be applied to with the same application, they will be automatically grouped into a bundle."]] :remove "Remove"} :catalogue {:catalogue "Catalogue" :header "Resource" diff --git a/resources/translations/fi.edn b/resources/translations/fi.edn index dcb7a32e5c..3be7e2c825 100644 --- a/resources/translations/fi.edn +++ b/resources/translations/fi.edn @@ -124,7 +124,7 @@ :returned "Palautettu muokattavaksi" :submitted "Haettu" :unknown "Tuntematon"} - :intro [:div.intro [:p "Täyttämällä ja lähettämällä tämän hakemuksen, kaikki hakijat voivat saada oikeuden haettuihin resursseihin. Kaikkien on sen lisäksi hyväksyttävä kaikki käyttöehdot viimeistään hakemuksen käsittelyn jälkeen saadakseen käyttöoikeudet."]] + :intro [:div.intro [:p "Täyttämällä ja lähettämällä tämän hakemuksen, kaikki hakijat voivat saada oikeuden haettuihin resursseihin. Kaikkien hakijoiden on sen lisäksi hyväksyttävä kaikki käyttöehdot viimeistään hakemuksen käsittelyn jälkeen saadakseen käyttöoikeudet."]] :my-applications "Omat hakemukset" :state "Tila" :states {:approved "Hyväksytty" From daf0ba3f1ec3912718bceab0171374873db50320 Mon Sep 17 00:00:00 2001 From: Markku Rontu Date: Wed, 12 Jun 2019 16:33:30 +0300 Subject: [PATCH 17/31] fix: wrong fn --- src/cljs/rems/cart.cljs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/cljs/rems/cart.cljs b/src/cljs/rems/cart.cljs index 53980aa2c6..b6504dcd17 100644 --- a/src/cljs/rems/cart.cljs +++ b/src/cljs/rems/cart.cljs @@ -82,7 +82,7 @@ (let [key-fn #(select-vals % [:wfid :formid])] (apply concat (for [group (vals (into (sorted-map) (group-by key-fn items)))] - (group-view (sort-by get-catalogue-item-title group) language)))))]]]] + (group-view (sort-by get-localized-title group) language)))))]]]] (text :t.cart/empty))) (defn cart-list-container [] From 089c5332ab0cfa602192e9694cb4a6ec404be9ec Mon Sep 17 00:00:00 2001 From: Markku Rontu Date: Wed, 12 Jun 2019 16:40:25 +0300 Subject: [PATCH 18/31] feat: show external id on application page - application-state block also shows description - heading shows only the id --- src/cljs/rems/application.cljs | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/src/cljs/rems/application.cljs b/src/cljs/rems/application.cljs index 17c777d089..39bb0bbaad 100644 --- a/src/cljs/rems/application.cljs +++ b/src/cljs/rems/application.cljs @@ -406,6 +406,14 @@ :always (into [:div [:div.mb-3 {:class (str "state-" (name state))} (phases (get-application-phases state))] + [info-field + (text :t.applications/application) + [:span#application-id (:application/external-id application)] + {:inline? true}] + [info-field + (text :t.actions/description) + (:application/description application) + {:inline? true}] [info-field (text :t.applications/state) [:span#application-state (localize-state state)] @@ -584,7 +592,7 @@ :contents [format-validation-errors application errors]}])])] [:div [:div {:class "float-right"} [pdf-button (:application/id application)]] - [document-title (text :t.applications/application)] + [document-title [:span (text :t.applications/application) " " (:application/external-id application)]] (text :t.applications/intro) (into [:div] messages) [application-state application] From d5145902f0aacdc0ec506293a362f6016c391777 Mon Sep 17 00:00:00 2001 From: Markku Rontu Date: Wed, 12 Jun 2019 16:52:42 +0300 Subject: [PATCH 19/31] feat: administration intro Also removes redundant buttons. --- resources/translations/en.edn | 1 + resources/translations/fi.edn | 1 + src/cljs/rems/administration/administration.cljs | 10 +--------- 3 files changed, 3 insertions(+), 9 deletions(-) diff --git a/resources/translations/en.edn b/resources/translations/en.edn index c241e25d69..49e088c1b7 100644 --- a/resources/translations/en.edn +++ b/resources/translations/en.edn @@ -75,6 +75,7 @@ :workflow-in-use "Workflow is in use by:"} :form "Form" :forms "Forms" + :intro [:div.intro [:p "From here you can manage the REMS datasets. See the menu above."]] :license "License" :license-field "License \"%1\"" :licenses "Licenses" diff --git a/resources/translations/fi.edn b/resources/translations/fi.edn index 3be7e2c825..3a38b5ee7b 100644 --- a/resources/translations/fi.edn +++ b/resources/translations/fi.edn @@ -75,6 +75,7 @@ :workflow-in-use "Työvuo on käytössä täällä:"} :form "Lomake" :forms "Lomakkeet" + :intro [:div.intro [:p "Täällä voit hallinnoida REMSin aineistoja. Valitse alue valikoista yläpuolelta."]] :license "Lisenssi" :license-field "License \"%1\"" :licenses "Lisenssit" diff --git a/src/cljs/rems/administration/administration.cljs b/src/cljs/rems/administration/administration.cljs index 08931fbda1..ab81445fa1 100644 --- a/src/cljs/rems/administration/administration.cljs +++ b/src/cljs/rems/administration/administration.cljs @@ -93,15 +93,7 @@ [document-title (text :t.navigation/administration)] (if @loading? [spinner/big] - [:div.spaced-sections - {:style {:display :flex - :flex-direction :column - :max-width "15rem"}} - [to-catalogue-items [:btn :btn-primary]] - [to-resources [:btn :btn-primary]] - [to-forms [:btn :btn-primary]] - [to-workflows [:btn :btn-primary]] - [to-licenses [:btn :btn-primary]]])]))) + (text :t.administration/intro))]))) (defn guide [] From fb99ad5100387465faf40d92580340f17f8477ba Mon Sep 17 00:00:00 2001 From: Markku Rontu Date: Wed, 12 Jun 2019 17:04:03 +0300 Subject: [PATCH 20/31] fix: document title --- src/cljs/rems/application.cljs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/cljs/rems/application.cljs b/src/cljs/rems/application.cljs index 39bb0bbaad..109675b7c0 100644 --- a/src/cljs/rems/application.cljs +++ b/src/cljs/rems/application.cljs @@ -592,7 +592,7 @@ :contents [format-validation-errors application errors]}])])] [:div [:div {:class "float-right"} [pdf-button (:application/id application)]] - [document-title [:span (text :t.applications/application) " " (:application/external-id application)]] + [document-title (str (text :t.applications/application) " " (:application/external-id application))] (text :t.applications/intro) (into [:div] messages) [application-state application] From eb27e2fda35aa9bfd3100e3acc59f18ff763a16c Mon Sep 17 00:00:00 2001 From: Markku Rontu Date: Wed, 12 Jun 2019 17:07:22 +0300 Subject: [PATCH 21/31] feat: change document title to shorten --- resources/translations/en.edn | 2 +- resources/translations/fi.edn | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/resources/translations/en.edn b/resources/translations/en.edn index 49e088c1b7..f0ce6ac3ac 100644 --- a/resources/translations/en.edn +++ b/resources/translations/en.edn @@ -256,7 +256,7 @@ :invalid-value "Invalid value." :required "Field \"%1\" is required." :toolong "Answer to field \"%1\" is too long."}} - :header {:title "Welcome to REMS"} + :header {:title "REMS"} :item-lists {:move-down "Move down" :move-up "Move up" :remove "Remove"} diff --git a/resources/translations/fi.edn b/resources/translations/fi.edn index 3a38b5ee7b..4462164497 100644 --- a/resources/translations/fi.edn +++ b/resources/translations/fi.edn @@ -256,7 +256,7 @@ :invalid-value "Arvo ei kelpaa." :required "Kenttä \"%1\" on pakollinen." :toolong "Kentän \"%1\" vastaus on liian pitkä."}} - :header {:title "Tervetuloa REMSiin"} + :header {:title "REMS"} :item-lists {:move-down "Siirrä alaspäin" :move-up "Siirrä ylöspäin" :remove "Poista"} From cd8635478b98e5f50975f68b74dfadead17c07f9 Mon Sep 17 00:00:00 2001 From: Markku Rontu Date: Wed, 12 Jun 2019 17:09:30 +0300 Subject: [PATCH 22/31] fix: browser test --- test/clj/rems/test_browser.clj | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/clj/rems/test_browser.clj b/test/clj/rems/test_browser.clj index 99b43dd9fd..e24646d778 100644 --- a/test/clj/rems/test_browser.clj +++ b/test/clj/rems/test_browser.clj @@ -112,7 +112,7 @@ {:fn/text resource-name} {:xpath "./ancestor::tr"} {:css "button.apply-for-catalogue-items"}]) - (wait-visible *driver* {:tag :h1, :fn/text "Application"}) + (wait-visible *driver* {:tag :h1, :fn/has-text "Application"}) (wait-page-loaded) (screenshot *driver* (io/file reporting-dir "application-page.png"))) From 7886361abeb89aae3b75a1d3f999018d0a3a67d7 Mon Sep 17 00:00:00 2001 From: Markku Rontu Date: Fri, 14 Jun 2019 14:46:25 +0300 Subject: [PATCH 23/31] fix: use configured value for id --- src/cljs/rems/application.cljs | 22 +++++++++++++++------- 1 file changed, 15 insertions(+), 7 deletions(-) diff --git a/src/cljs/rems/application.cljs b/src/cljs/rems/application.cljs index 109675b7c0..7f4f471495 100644 --- a/src/cljs/rems/application.cljs +++ b/src/cljs/rems/application.cljs @@ -389,7 +389,14 @@ {:phase :approve :text :t.phases/approve} {:phase :result :text :t.phases/approved}])) -(defn- application-state [application] +(defn- application-id-value [config application] + (let [id-column (get config :application-id-column :id)] + (case id-column + :external-id (:application/external-id application) + :id (:application/id application) + (:application/id application)))) + +(defn- application-state [application config] (let [state (:application/state application) last-activity (:application/last-activity application) event-groups (->> (:application/events application) @@ -408,7 +415,7 @@ (phases (get-application-phases state))] [info-field (text :t.applications/application) - [:span#application-id (:application/external-id application)] + [:span#application-id (application-id-value config application)] {:inline? true}] [info-field (text :t.actions/description) @@ -583,7 +590,7 @@ [:div#resource-action-forms [change-resources-form application can-bundle-all? can-comment? (partial reload! application-id)]]]}])) -(defn- render-application [application edit-application userid] +(defn- render-application [application edit-application config userid] (let [messages (remove nil? [(disabled-items-warning application) ; NB: eval this here so we get nil or a warning (when-let [errors (:validation-errors edit-application)] @@ -592,10 +599,10 @@ :contents [format-validation-errors application errors]}])])] [:div [:div {:class "float-right"} [pdf-button (:application/id application)]] - [document-title (str (text :t.applications/application) " " (:application/external-id application))] + [document-title (str (text :t.applications/application) " " (application-id-value config application))] (text :t.applications/intro) (into [:div] messages) - [application-state application] + [application-state application config] [:div.mt-3 [applicants-info application]] [:div.mt-3 [applied-resources application userid]] [:div.my-3 [application-fields application edit-application]] @@ -605,7 +612,8 @@ ;;;; Entrypoint (defn application-page [] - (let [application @(rf/subscribe [::application]) + (let [config @(rf/subscribe [:rems.config/config]) + application @(rf/subscribe [::application]) edit-application @(rf/subscribe [::edit-application]) userid (get-in @(rf/subscribe [:identity]) [:user :eppn]) loading? (not application)] @@ -613,7 +621,7 @@ [:div [document-title (text :t.applications/application)] [spinner/big]] - [render-application application edit-application userid]))) + [render-application application edit-application config userid]))) ;;;; Guide From 7694ce88c4356d5b338dfe163db0701ad84c0ee1 Mon Sep 17 00:00:00 2001 From: Markku Rontu Date: Fri, 14 Jun 2019 14:49:05 +0300 Subject: [PATCH 24/31] tune: shorter text --- resources/translations/en.edn | 2 +- resources/translations/fi.edn | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/resources/translations/en.edn b/resources/translations/en.edn index 250614c3a6..1232b22414 100644 --- a/resources/translations/en.edn +++ b/resources/translations/en.edn @@ -125,7 +125,7 @@ :returned "Changes requested" :submitted "Applied" :unknown "Unknown"} - :intro [:div.intro [:p "By filling and sending in this application, the applicants may be granted the applied resources. All the applicable terms of use must also be accepted before or after applying by all the applicants."]] + :intro [:div.intro [:p "By filling and sending in this application, the applicants may be granted the applied resources. All the applicable terms of use must also be accepted by each applicant."]] :my-applications "My Applications" :state "State" :states {:approved "Approved" diff --git a/resources/translations/fi.edn b/resources/translations/fi.edn index 28962864af..2a32111e7e 100644 --- a/resources/translations/fi.edn +++ b/resources/translations/fi.edn @@ -125,7 +125,7 @@ :returned "Palautettu muokattavaksi" :submitted "Haettu" :unknown "Tuntematon"} - :intro [:div.intro [:p "Täyttämällä ja lähettämällä tämän hakemuksen, kaikki hakijat voivat saada oikeuden haettuihin resursseihin. Kaikkien hakijoiden on sen lisäksi hyväksyttävä kaikki käyttöehdot viimeistään hakemuksen käsittelyn jälkeen saadakseen käyttöoikeudet."]] + :intro [:div.intro [:p "Täyttämällä ja lähettämällä tämän hakemuksen, kaikki hakijat voivat saada oikeuden haettuihin resursseihin. Kaikkien hakijoiden on sen lisäksi hyväksyttävä kaikki käyttöehdot viimeistään hakemuksen käsittelyn jälkeen."]] :my-applications "Omat hakemukset" :state "Tila" :states {:approved "Hyväksytty" From 3fff9ef419957ec135333969fb1176658af884db Mon Sep 17 00:00:00 2001 From: Markku Rontu Date: Fri, 14 Jun 2019 14:49:55 +0300 Subject: [PATCH 25/31] tune: Finnish text --- resources/translations/fi.edn | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/resources/translations/fi.edn b/resources/translations/fi.edn index 2a32111e7e..1f4887187a 100644 --- a/resources/translations/fi.edn +++ b/resources/translations/fi.edn @@ -125,7 +125,7 @@ :returned "Palautettu muokattavaksi" :submitted "Haettu" :unknown "Tuntematon"} - :intro [:div.intro [:p "Täyttämällä ja lähettämällä tämän hakemuksen, kaikki hakijat voivat saada oikeuden haettuihin resursseihin. Kaikkien hakijoiden on sen lisäksi hyväksyttävä kaikki käyttöehdot viimeistään hakemuksen käsittelyn jälkeen."]] + :intro [:div.intro [:p "Täyttämällä ja lähettämällä tämän hakemuksen kaikki hakijat voivat saada oikeuden haettuihin resursseihin. Kunkin hakijan on lisäksi hyväksyttävä käyttöehdot viimeistään hakemuksen käsittelyn jälkeen."]] :my-applications "Omat hakemukset" :state "Tila" :states {:approved "Hyväksytty" From 0fd04e3fd665bc8e6e3efc1c3fa81d2172b75bcf Mon Sep 17 00:00:00 2001 From: Markku Rontu Date: Fri, 14 Jun 2019 14:51:27 +0300 Subject: [PATCH 26/31] tune: improved shorter English --- resources/translations/en.edn | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/resources/translations/en.edn b/resources/translations/en.edn index 1232b22414..a330b11187 100644 --- a/resources/translations/en.edn +++ b/resources/translations/en.edn @@ -144,7 +144,7 @@ :apply-for-bundle "Apply for %1 resources as a bundle " :empty [:div.intro [:p "Select resources to apply."]] :header "%1 resources in the cart" - :intro [:div.intro [:p "Here are the resources that you have selected. If the resources can be applied to with the same application, they will be automatically grouped into a bundle."]] + :intro [:div.intro [:p "Here are the selected resources. If several resources can be applied to with the same application, they will be automatically grouped into a bundle."]] :remove "Remove"} :catalogue {:catalogue "Catalogue" :header "Resource" From 3e8356b923a23ff9e541a566c552e771074c0f13 Mon Sep 17 00:00:00 2001 From: Markku Rontu Date: Fri, 14 Jun 2019 14:52:02 +0300 Subject: [PATCH 27/31] tune: shorten by removing extra term existing --- resources/translations/en.edn | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/resources/translations/en.edn b/resources/translations/en.edn index a330b11187..aa4c1648e8 100644 --- a/resources/translations/en.edn +++ b/resources/translations/en.edn @@ -150,8 +150,8 @@ :header "Resource" :intro [:p "The catalogue contains all the resources that you can apply for in this system."] :more-info "More info" - :continue-existing-application "Continue existing application" - :continue-existing-application-intro [:div.intro [:p "You have existing unfinished applications that you can continue from here."]] + :continue-existing-application "Continue application" + :continue-existing-application-intro [:div.intro [:p "You have unfinished applications that you can continue from here."]] :apply-resources "Apply for resources"} :collapse {:show-less "Show less" :show-more "Show more"} From 6fb842c151da64a3d2a728ccd20cd971d6b0b655 Mon Sep 17 00:00:00 2001 From: Markku Rontu Date: Fri, 14 Jun 2019 14:55:20 +0300 Subject: [PATCH 28/31] tune: shorter better text --- resources/translations/fi.edn | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/resources/translations/fi.edn b/resources/translations/fi.edn index 1f4887187a..038321d819 100644 --- a/resources/translations/fi.edn +++ b/resources/translations/fi.edn @@ -144,7 +144,7 @@ :apply-for-bundle "Hae %1 aineistoa yhdessä " :empty [:div.intro [:p "Valitse resursseja haettavaksi."]] :header "%1 aineistoa korissa" - :intro [:div.intro [:p "Tässä ovat kaikki resurssit jotka olet valinnut. Resurssit jotka voi hakea samalla hakemuksella ryhmitellään automaattisesti yhteen."]] + :intro [:div.intro [:p "Tässä ovat valitsemasi resurssit. Samalla hakemuksella haettavat resurssit ryhmitellään automaattisesti yhteen."]] :remove "Poista"} :catalogue {:catalogue "Aineistoluettelo" :header "Aineistoluettelo" From dc89383a61fefe35ddb4aec1466c2bb47c281ace Mon Sep 17 00:00:00 2001 From: Markku Rontu Date: Fri, 14 Jun 2019 14:56:02 +0300 Subject: [PATCH 29/31] tune: text --- resources/translations/en.edn | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/resources/translations/en.edn b/resources/translations/en.edn index aa4c1648e8..0098da0eaf 100644 --- a/resources/translations/en.edn +++ b/resources/translations/en.edn @@ -268,7 +268,7 @@ :link {:download-file "Download file" :opens-in-new-window "Opens in a new window"} :login {:alternative "Other login options" -:intro [:div [:h1 "Welcome to REMS"] [:p "This is a demo environment for testing the REMS software. The demo environment has a couple of fictional datasets to which you can apply for access. More information available on the " [:a {:href "#/extra-pages/about"} "About"] " page."] +:intro [:div [:h1 "Welcome to REMS"] [:p "This is a demo environment for testing the REMS software. The demo environment has a couple of fictional datasets to which you can apply for access. More information is available on " [:a {:href "#/extra-pages/about"} "About"] " page."] [:p "Please, login to access REMS."]] :text "Login with Haka credentials" :title "Login"} From 55d7cbbaf7b68af3a57a271e495a0d371c3ebcaa Mon Sep 17 00:00:00 2001 From: Markku Rontu Date: Fri, 14 Jun 2019 14:57:37 +0300 Subject: [PATCH 30/31] fix: remove colon and % --- resources/translations/en.edn | 2 +- resources/translations/fi.edn | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/resources/translations/en.edn b/resources/translations/en.edn index 0098da0eaf..b6a0b4c2d3 100644 --- a/resources/translations/en.edn +++ b/resources/translations/en.edn @@ -135,7 +135,7 @@ :returned "Returned" :submitted "Applied" :unknown "Unknown"} - :latest-activity "Latest activity: %1" + :latest-activity "Latest activity" :view "View"} :autocomplete {:no-results "No results" :placeholder "Choose or type"} diff --git a/resources/translations/fi.edn b/resources/translations/fi.edn index 038321d819..4cedbc4520 100644 --- a/resources/translations/fi.edn +++ b/resources/translations/fi.edn @@ -135,7 +135,7 @@ :returned "Palautettu" :submitted "Haettu" :unknown "Tuntematon"} - :latest-activity "Viimeisin toimenpide: %1" + :latest-activity "Viimeisin toimenpide" :view "Näytä"} :autocomplete {:no-results "Ei tuloksia" :placeholder "Valitse tai kirjoita"} From 408f5464d4881fd7e72c306eab2886f9bd638296 Mon Sep 17 00:00:00 2001 From: Markku Rontu Date: Fri, 14 Jun 2019 15:00:53 +0300 Subject: [PATCH 31/31] tune: use colon --- resources/translations/en.edn | 4 ++-- resources/translations/fi.edn | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/resources/translations/en.edn b/resources/translations/en.edn index b6a0b4c2d3..d42fb3a1a0 100644 --- a/resources/translations/en.edn +++ b/resources/translations/en.edn @@ -142,7 +142,7 @@ :cart {:add "Add to cart" :apply "Apply" :apply-for-bundle "Apply for %1 resources as a bundle " - :empty [:div.intro [:p "Select resources to apply."]] + :empty [:div.intro [:p "Select resources to apply:"]] :header "%1 resources in the cart" :intro [:div.intro [:p "Here are the selected resources. If several resources can be applied to with the same application, they will be automatically grouped into a bundle."]] :remove "Remove"} @@ -151,7 +151,7 @@ :intro [:p "The catalogue contains all the resources that you can apply for in this system."] :more-info "More info" :continue-existing-application "Continue application" - :continue-existing-application-intro [:div.intro [:p "You have unfinished applications that you can continue from here."]] + :continue-existing-application-intro [:div.intro [:p "You have unfinished applications that you can continue from here:"]] :apply-resources "Apply for resources"} :collapse {:show-less "Show less" :show-more "Show more"} diff --git a/resources/translations/fi.edn b/resources/translations/fi.edn index 4cedbc4520..32a23f5647 100644 --- a/resources/translations/fi.edn +++ b/resources/translations/fi.edn @@ -142,7 +142,7 @@ :cart {:add "Lisää koriin" :apply "Hae" :apply-for-bundle "Hae %1 aineistoa yhdessä " - :empty [:div.intro [:p "Valitse resursseja haettavaksi."]] + :empty [:div.intro [:p "Valitse resursseja haettavaksi:"]] :header "%1 aineistoa korissa" :intro [:div.intro [:p "Tässä ovat valitsemasi resurssit. Samalla hakemuksella haettavat resurssit ryhmitellään automaattisesti yhteen."]] :remove "Poista"} @@ -151,7 +151,7 @@ :intro [:p "Aineistoluettelossa on listattuna kaikki resurssit joita voit tästä järjestelmästä hakea."] :more-info "Lisätietoja" :continue-existing-application "Jatka hakemusta" - :continue-existing-application-intro [:div.intro [:p "Sinulla on keskeneräisiä hakemuksia, joita voit jatkaa tästä."]] + :continue-existing-application-intro [:div.intro [:p "Sinulla on keskeneräisiä hakemuksia, joita voit jatkaa tästä:"]] :apply-resources "Hae uusia resursseja"} :collapse {:show-less "Näytä vähemmän" :show-more "Näytä lisää"}