Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -18,3 +18,4 @@ node_modules/
*DS_Store*
.vscode/
*.bak
*.mda
8 changes: 8 additions & 0 deletions .jshintrc
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,14 @@
"quotmark" : "double",
"eqeqeq" : true,
"undef" : true,
"maxstatements" : 15,
"maxdepth" : 2,
"maxcomplexity" : 5,
"nonbsp" : true,
"nonem" : true,
"unparam" : true,
"plusplus" : true,
"regexp" : true,
"globals" : {
"mendix" : false,
"mx" : false,
Expand Down
18 changes: 10 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,27 +23,29 @@ For more information on contributing to this repository visit [Contributing to a
### Display
* *Username placeholder* - Standard text to be displayed in username field
* *Password placeholder* - Standard text to be displayed in password field
* *'Login' button caption* - Text to be displayed on login button
* *Progress bar caption* - Text to display in progress bar, displayed while login request executes
* *Username Label* - Username label caption
* *Password Label* - Password label caption
* *Login button caption* - Text to be displayed on login button
* *Empty username/password message* - Feedback message shown when a user didn't provide all credentials
* *'Forgot password' link text* - Text to use in Forgot password link
* *Forgot password link text* - Text to use in the Forgot password link

### Behaviour
* *Show progress bar* - Display a progress bar while signing in
* *Forgot password microflow* - Microflow being triggered in case of 'forgot password' onclick
* *Focus username input field* - Move focus to username field when the form is showed (only use this if it is not done automatically)

* *Login Failure Text* - Warning message to show when login fails twice

### Mobile
* *Auto capitalize* - Enables/disables auto capitalize functionality on username input field for mobile devices
* *Auto correct* - Enables/disables auto correct functionality on username input field for mobile devices
* *Username Keyboard Type* - The keyboard type to display when the user is entering their username

### Password
* *Show/mask password toggle* - Adds a toggle button to show/mask password.*
* *'Show password' button caption* - The caption that is used for the show button for the value of the password
* *'Mask password' button caption* - The caption that is used for the hide button for the value of the password
* *'Show password' button image* - Optional image to be displayed in 'Show password' button
* *'Mask password' button image* - Optional image to be displayed in 'Mask password' button
* *Show password button caption* - The caption that is used for the show button for the value of the password
* *Mask password button caption* - The caption that is used for the hide button for the value of the password
* *Show password button image* - Optional image to be displayed in 'Show password' button
* *Mask password button image* - Optional image to be displayed in 'Mask password' button

### Casehandling
* Convert to lower/uppercase - this option will convert user name input to upper/lower case. Using this functionality only makes practical sense when all usernames defined in your application are either upper or lower cased.
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "LoginForm",
"version": "3.4.0",
"version": "3.5.0",
"description": "A custom login form which can be used as an alternative to the default Mendix login page.",
"license": "",
"author": "",
Expand Down
114 changes: 74 additions & 40 deletions src/LoginForm/LoginForm.xml
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
<widget id="LoginForm.widget.LoginForm" needsEntityContext="false" xmlns="http://www.mendix.com/widget/1.0/">
<widget id="LoginForm.widget.LoginForm" needsEntityContext="false"
xmlns="http://www.mendix.com/widget/1.0/"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.mendix.com/widget/1.0/ ../../xsd/widget.xsd">
<name>LoginForm</name>
<description>Login form</description>
<icon>
Expand All @@ -17,95 +20,126 @@
</icon>
<properties>
<property key="userexample" type="string" defaultValue="Username" required="false">
<caption>Username placeholder</caption>
<caption>Username Placeholder</caption>
<category>Display</category>
<description>Input box sample value</description>
</property>
<property key="passexample" type="string" defaultValue="Password" required="false">
<caption>Password placeholder</caption>
<caption>Password Placeholder</caption>
<category>Display</category>
<description>Input box sample value</description>
</property>
<property key="logintext" type="string" defaultValue="Login">
<caption>'Login' button caption</caption>
<property key="showLabels" type="boolean" defaultValue="false">
<caption>Show Labels</caption>
<category>Display</category>
<description>Show username and password labels</description>
</property>
<property key="usernameLabel" type="string" defaultValue="User name" required="false">
<caption>Username Label</caption>
<category>Display</category>
<description>Caption of login button</description>
<description>Username label caption (Only used if Show Labels is Yes)</description>
</property>
<property key="progresstext" type="string" required="false">
<caption>Progress bar caption</caption>
<property key="passwordLabel" type="string" defaultValue="Password" required="false">
<caption>Password Label</caption>
<category>Display</category>
<description>Text to display in progress bar</description>
<description>Password label caption (Only used if Show Labels is Yes)</description>
</property>
<property key="logintext" type="string" defaultValue="Login">
<caption>Login Button Caption</caption>
<category>Display</category>
<description>Login button caption</description>
</property>
<property key="emptytext" type="string" required="false" defaultValue="No username or password given">
<caption>Empty username or password text</caption>
<caption>Empty Username or Password Text</caption>
<category>Display</category>
<description>Text to display in case of form being submitted without username or password</description>
<description>Displayed when Username or Password is empty</description>
</property>
<property key="forgottext" type="string" required="false" defaultValue="Forgot your password?">
<caption>'Forgot password' link text</caption>
<caption>Forgot Password Link Text</caption>
<category>Display</category>
<description>Text to display in 'forgot password' link</description>
<description>Text in Forgot Password link</description>
</property>
<property key="showprogress" type="boolean" defaultValue="false">
<caption>Show progress bar</caption>
<caption>Show Progress Bar</caption>
<category>Behavior</category>
<description>Display a progress bar while signing in</description>
</property>
<property key="showLoginFailureWarning" type="boolean" defaultValue="false">
<caption>Login Failure Warning</caption>
<category>Behavior</category>
<description>Alert that username will be blocked for 5 minutes if login fails 3 times</description>
</property>
<property key="loginFailureText" type="string" defaultValue="Your account will be blocked for 5 minutes if login with the same username fails thrice!">
<caption>Login Failure Text</caption>
<category>Behavior</category>
<description>Warning message to show when login fails twice</description>
</property>
<property key="forgotmf" type="microflow" required="false">
<caption>Forgot Password Microflow</caption>
<category>Behavior</category>
<description>Triggered on clicking the Forgot Password link</description>
<returnType type="Void"/>
</property>
<property key="dofocus" type="boolean" defaultValue="false">
<caption>Focus Username Input Field</caption>
<category>Behavior</category>
<description>When form is shown, username filed takes focus (If not automatic)</description>
</property>
<property key="showPasswordView" type="boolean" defaultValue="false">
<caption>Show/mask password toggle</caption>
<caption>Show/Mask Password Toggle</caption>
<category>Password</category>
<description>Adds a toggle button to show/mask password.</description>
<description>Toggle button to show/mask password.</description>
</property>
<property key="showButtonCaption" type="string" required="false" defaultValue="Show">
<caption>'Show password' button caption</caption>
<caption>Show Password Button Caption</caption>
<category>Password</category>
<description>The caption that is used for the show button for the value of the password.</description>
<description>Caption for the button that shows the password</description>
</property>
<property key="hideButtonCaption" type="string" required="false" defaultValue="Mask">
<caption>'Mask password' button caption</caption>
<caption>Mask Password Button Caption</caption>
<category>Password</category>
<description>The caption that is used for the hide button for the value of the password.</description>
<description>Caption for the button that masks the password</description>
</property>
<property key="showImage" type="image" required="false">
<caption>'Show password' button image</caption>
<caption>Show Password Button Image</caption>
<category>Password</category>
<description>Optional image to be displayed in 'Show password' button.</description>
<description>Optional image to be displayed on Show Password button.</description>
</property>
<property key="hideImage" type="image" required="false">
<caption>'Mask password' button image</caption>
<caption>Mask Password Button Image</caption>
<category>Password</category>
<description>Optional image to be displayed in 'Mask password' button.</description>
</property>
<property key="forgotmf" type="microflow" required="false">
<caption>Forgot password microflow</caption>
<category>Behavior</category>
<description>Microflow being triggered in case of 'forgot password' onclick</description>
<returnType type="Void"/>
</property>
<property key="dofocus" type="boolean" defaultValue="false">
<caption>Focus username input field</caption>
<category>Behavior</category>
<description>Focus the username field when the form is showed (only use this if it is not done automatically)</description>
<description>Optional image to be displayed on Mask Password button.</description>
</property>
<property key="convertCase" type="enumeration" defaultValue="none">
<caption>Convert to lowercase/uppercase</caption>
<category>Casehandling</category>
<description>Enables/disables automatic conversion of username input field to lowercase/uppercase</description>
<description>Automatic conversion of Username to lowercase/uppercase</description>
<enumerationValues>
<enumerationValue key="none">None</enumerationValue>
<enumerationValue key="toLowerCase">Convert to lowercase</enumerationValue>
<enumerationValue key="toUpperCase">Convert to uppercase</enumerationValue>
</enumerationValues>
</property>
<property key="autoCorrect" type="boolean" defaultValue="false">
<caption>Auto correct</caption>
<caption>Auto-correct</caption>
<category>Mobile</category>
<description>Enables/disables auto correct functionality on username input field for mobile devices</description>
<description>Auto-correct Username</description>
</property>
<property key="autoCapitalize" type="boolean" defaultValue="false">
<caption>Auto capitalize</caption>
<caption>Auto-capitalize</caption>
<category>Mobile</category>
<description>Enables/disables auto capitalize functionality on username input field for mobile devices</description>
<description>Auto-capitalize Username</description>
</property>
<property key="keyboardType" type="enumeration" defaultValue="text">
<caption>Username Keyboard Type</caption>
<category>Mobile</category>
<description>The keyboard type to display when the user is entering their username</description>
<enumerationValues>
<enumerationValue key="text">Text</enumerationValue>
<enumerationValue key="email">Email</enumerationValue>
<enumerationValue key="tel">Telephone Number</enumerationValue>
<enumerationValue key="number">Number</enumerationValue>
</enumerationValues>
</property>
</properties>
</widget>
Loading