@schukai/monster 4.3.1 → 4.4.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -2,6 +2,22 @@
2
2
 
3
3
 
4
4
 
5
+ ## [4.4.1] - 2025-05-14
6
+
7
+ ### Bug Fixes
8
+
9
+ - Add placeholder properties for login inputs [#315](https://gitlab.schukai.com/oss/libraries/javascript/monster/issues/315)
10
+
11
+
12
+
13
+ ## [4.4.0] - 2025-05-14
14
+
15
+ ### Add Features
16
+
17
+ - Add placeholders for email and username fields in login form translations [#315](https://gitlab.schukai.com/oss/libraries/javascript/monster/issues/315)
18
+
19
+
20
+
5
21
  ## [4.3.1] - 2025-05-12
6
22
 
7
23
  ### Bug Fixes
package/package.json CHANGED
@@ -1 +1 @@
1
- {"author":"schukai GmbH","dependencies":{"@floating-ui/dom":"^1.7.0","@popperjs/core":"^2.11.8"},"description":"Monster is a simple library for creating fast, robust and lightweight websites.","homepage":"https://monsterjs.org/","keywords":["framework","web","dom","css","sass","mobile-first","app","front-end","templates","schukai","core","shopcloud","alvine","monster","buildmap","stack","observer","observable","uuid","node","nodelist","css-in-js","logger","log","theme"],"license":"AGPL 3.0","main":"source/monster.mjs","module":"source/monster.mjs","name":"@schukai/monster","repository":{"type":"git","url":"https://gitlab.schukai.com/oss/libraries/javascript/monster.git"},"type":"module","version":"4.3.1"}
1
+ {"author":"schukai GmbH","dependencies":{"@floating-ui/dom":"^1.7.0","@popperjs/core":"^2.11.8"},"description":"Monster is a simple library for creating fast, robust and lightweight websites.","homepage":"https://monsterjs.org/","keywords":["framework","web","dom","css","sass","mobile-first","app","front-end","templates","schukai","core","shopcloud","alvine","monster","buildmap","stack","observer","observable","uuid","node","nodelist","css-in-js","logger","log","theme"],"license":"AGPL 3.0","main":"source/monster.mjs","module":"source/monster.mjs","name":"@schukai/monster","repository":{"type":"git","url":"https://gitlab.schukai.com/oss/libraries/javascript/monster.git"},"type":"module","version":"4.4.1"}
@@ -216,6 +216,10 @@ class Login extends CustomElement {
216
216
  * @property {string} accessKeys.username Access key for focusing the username field
217
217
  * @property {string} accessKeys.password Access key for focusing the password field
218
218
  * @property {Object} fetch Definitions for backend requests to support login workflows
219
+ * @property {Object} placeholder Placeholder text for input fields
220
+ * @property {string} placeholder.username Placeholder for the username field
221
+ * @property {string} placeholder.password Placeholder for the password field
222
+ * @property {string} placeholder.email Placeholder for the email field
219
223
  * @property {Object} fetch.login Fetch config for login request
220
224
  * @property {string} fetch.login.url Endpoint to post login credentials to
221
225
  * @property {string} fetch.login.method HTTP method for login (e.g., "POST")
@@ -294,6 +298,12 @@ class Login extends CustomElement {
294
298
  password: "p",
295
299
  },
296
300
 
301
+ placeholder: {
302
+ username: "",
303
+ password: "",
304
+ email: "",
305
+ },
306
+
297
307
  fetch: {
298
308
  login: {
299
309
  url: "",
@@ -464,6 +474,7 @@ function getTranslations() {
464
474
  "Dieses Formular ist nicht konfiguriert.",
465
475
  messagePasswordResetDisabled:
466
476
  "Sie können keinen Code anfordern, da die<br>Zwei-Faktor-Authentifizierung bei Ihrem Konto aktiviert ist.<br>Bitte kontaktieren Sie den Administrator.",
477
+
467
478
  };
468
479
  case "es":
469
480
  return {
@@ -497,6 +508,9 @@ function getTranslations() {
497
508
  messageThisFormIsNotConfigured: "Este formulario no está configurado.",
498
509
  messagePasswordResetDisabled:
499
510
  "Esta función no funciona porque la autenticación de dos factores está activada en su cuenta. Por favor, póngase en contacto con el administrador.",
511
+
512
+
513
+
500
514
  };
501
515
  case "zh":
502
516
  return {
@@ -526,6 +540,9 @@ function getTranslations() {
526
540
  messageThisFormIsNotConfigured: "此表单尚未配置。",
527
541
  messagePasswordResetDisabled:
528
542
  "此功能无法使用,因为您的帐户启用了双因素身份验证。请联系管理员。",
543
+
544
+
545
+
529
546
  };
530
547
 
531
548
  case "hi":
@@ -556,6 +573,8 @@ function getTranslations() {
556
573
  messageThisFormIsNotConfigured: "यह फर कनगर नह ह।",
557
574
  messagePasswordResetDisabled:
558
575
  "यह सवध कम नह करत कक आपक खत म द घटक पमणकरण सकम ह। कपय पशसक स सपर कर।",
576
+
577
+
559
578
  };
560
579
 
561
580
  case "bn":
@@ -586,6 +605,8 @@ function getTranslations() {
586
605
  messageThisFormIsNotConfigured: "এই ফরট কনফগর কর হযন।",
587
606
  messagePasswordResetDisabled:
588
607
  "এই ফশনট করকর নয করণ আপনর অযকউন দট ফকর পমণকরণ সকয কর আছ। দয কর পশসকর সথ যগযগ করন।",
608
+
609
+
589
610
  };
590
611
 
591
612
  case "pt": // Portuguese
@@ -617,6 +638,8 @@ function getTranslations() {
617
638
  messageThisFormIsNotConfigured: "Este formulário não está configurado.",
618
639
  messagePasswordResetDisabled:
619
640
  "Esta função não funciona porque a autenticação de dois fatores<br>está ativada em sua conta. Por favor, entre em contato com o administrador.",
641
+
642
+
620
643
  };
621
644
 
622
645
  case "ru": // Russian
@@ -648,6 +671,8 @@ function getTranslations() {
648
671
  messageThisFormIsNotConfigured: "Эта форма не настроена.",
649
672
  messagePasswordResetDisabled:
650
673
  "Эта функция не работает, потому что двухфакторная аутентификация<br> включена в вашей учетной записи. Пожалуйста, свяжитесь с администратором.",
674
+
675
+
651
676
  };
652
677
 
653
678
  case "ja": // Japanese
@@ -680,6 +705,7 @@ function getTranslations() {
680
705
  messageThisFormIsNotConfigured: "このフォームは設定されていません。",
681
706
  messagePasswordResetDisabled:
682
707
  "この機能は使用できません。アカウントで二要素認証が有効になっているため、管理者に連絡してください。",
708
+
683
709
  };
684
710
 
685
711
  case "pa": // Western Punjabi
@@ -710,6 +736,8 @@ function getTranslations() {
710
736
  messageThisFormIsNotConfigured: "ਇਸ ਫਰਮ ਨ ਸਰਚਤ ਨਹ ਕਤ ਗਆ ਹ।",
711
737
  messagePasswordResetDisabled:
712
738
  "ਇਹ ਫਕਸਨ ਕਮ ਨਹ ਕਰਦ ਕਉਕ ਤਹਡ ਖਤ ਵਚ ਦ ਫਕਟਰ ਪਰਮਣਕਰਣ ਸਰਗਰਮ ਹ। ਕਰਪ ਕਰਕ ਪਰਬਧਕ ਨਲ ਸਪਰਕ ਕਰ।",
739
+
740
+
713
741
  };
714
742
 
715
743
  case "mr": // Marathi
@@ -740,6 +768,8 @@ function getTranslations() {
740
768
  messageThisFormIsNotConfigured: "ह फर सरचत कलल नह.",
741
769
  messagePasswordResetDisabled:
742
770
  "य करच कमगर करत नह करण आपल खतत दन घटक पमणकरण सकय कल आह. कपय ववसपकश सपर सध.",
771
+
772
+
743
773
  };
744
774
 
745
775
  case "fr": // French
@@ -773,6 +803,8 @@ function getTranslations() {
773
803
  messageThisFormIsNotConfigured: "Ce formulaire n'est pas configuré.",
774
804
  messagePasswordResetDisabled:
775
805
  "Cette fonctionnalité ne fonctionne pas car l'authentification à deux facteurs est activée sur<br>votre compte. Veuillez contacter l'administrateur.",
806
+
807
+
776
808
  };
777
809
 
778
810
  case "it": // Italian
@@ -805,6 +837,7 @@ function getTranslations() {
805
837
  messageThisFormIsNotConfigured: "Questo modulo non è configurato.",
806
838
  messagePasswordResetDisabled:
807
839
  "Questa funzione non funziona perché l'autenticazione a due<br>fattori è attiva sul tuo account. Contatta l'amministratore.",
840
+
808
841
  };
809
842
 
810
843
  case "nl": // Dutch
@@ -836,6 +869,7 @@ function getTranslations() {
836
869
  messageThisFormIsNotConfigured: "Dit formulier is niet geconfigureerd.",
837
870
  messagePasswordResetDisabled:
838
871
  "Deze functie werkt niet omdat tweefactorauthenticatie is<br>ingeschakeld op uw account. Neem contact op met de beheerder.",
872
+
839
873
  };
840
874
 
841
875
  case "sv": // Swedish
@@ -867,6 +901,7 @@ function getTranslations() {
867
901
  messageThisFormIsNotConfigured: "Detta formulär är inte konfigurerat.",
868
902
  messagePasswordResetDisabled:
869
903
  "Denna funktion fungerar inte eftersom tvåfaktorsautentisering är aktiverad på ditt konto. Kontakta administratören.",
904
+
870
905
  };
871
906
 
872
907
  case "pl": // Polish
@@ -899,6 +934,7 @@ function getTranslations() {
899
934
  "Ten formularz nie jest skonfigurowany.",
900
935
  messagePasswordResetDisabled:
901
936
  "Ta funkcja nie działa, ponieważ włączona jest autoryzacja dwuetapowa na twoim koncie. Skontaktuj się z administratorem.",
937
+
902
938
  };
903
939
 
904
940
  case "da": // Danish
@@ -929,6 +965,7 @@ function getTranslations() {
929
965
  messageThisFormIsNotConfigured: "Denne formular er ikke konfigureret.",
930
966
  messagePasswordResetDisabled:
931
967
  "Denne funktion fungerer ikke, fordi tofaktorautentificering<br>er aktiveret på din konto. Kontakt administratoren.",
968
+
932
969
  };
933
970
 
934
971
  case "no": // Norwegian
@@ -961,6 +998,7 @@ function getTranslations() {
961
998
  messageThisFormIsNotConfigured: "Dette skjemaet er ikke konfigurert.",
962
999
  messagePasswordResetDisabled:
963
1000
  "Denne funksjonen fungerer ikke fordi<br>tofaktorautentisering er aktivert på kontoen din. Kontakt administratoren.",
1001
+
964
1002
  };
965
1003
 
966
1004
  case "cs": // Czech
@@ -991,6 +1029,7 @@ function getTranslations() {
991
1029
  messageThisFormIsNotConfigured: "Tento formulář není nakonfigurován.",
992
1030
  messagePasswordResetDisabled:
993
1031
  "Tato funkce nefunguje, protože je na vašem<br>účtu aktivováno dvoufaktorové ověřování. Kontaktujte správce.",
1032
+
994
1033
  };
995
1034
 
996
1035
  default:
@@ -1022,6 +1061,7 @@ function getTranslations() {
1022
1061
  messageThisFormIsNotConfigured: "This form is not configured.",
1023
1062
  messagePasswordResetDisabled:
1024
1063
  "This function does not work because two-factor<br>authentication is enabled on your account.<br>Please contact the administrator.",
1064
+
1025
1065
  };
1026
1066
  }
1027
1067
  }
@@ -1609,10 +1649,13 @@ function getTemplate() {
1609
1649
  part="login-field-set">
1610
1650
  <slot name="login-header"></slot>
1611
1651
  <label part="login-label" data-monster-replace="path:labels.username"></label>
1612
- <input part="login-username" type="text" name="username" autofocus autocomplete="off">
1652
+ <input part="login-username"
1653
+ data-monster-attributes="placeholder path:placeholder.username"
1654
+ type="text" name="username" autofocus autocomplete="off">
1613
1655
  <div data-monster-attributes="class path:classes.usernameInvalid"></div>
1614
1656
  <label part="login-password-label" data-monster-replace="path:labels.password"></label>
1615
1657
  <monster-password
1658
+ data-monster-attributes="data-monster-option-placeholder path:placeholder.password"
1616
1659
  exportparts="input-group:input-group-password,
1617
1660
  control:input-group-password-control,
1618
1661
  input:input-group-password-input" part="login-password"
@@ -1655,7 +1698,8 @@ function getTemplate() {
1655
1698
  <label part="forgot-password-label" data-monster-replace="path:labels.mailAddress"></label>
1656
1699
  <input type="email" name="email"
1657
1700
  part="field-set-forgot-password-email"
1658
- data-monster-attributes="accesskey path:accessKeys.username"
1701
+ data-monster-attributes="accesskey path:accessKeys.username,
1702
+ placeholder path:placeholder.email"
1659
1703
  autocomplete="off">
1660
1704
  <div data-monster-attributes="class path:classes.emailInvalid"></div>
1661
1705
  <monster-message-state-button id="requestLinkButton"