-
-
Notifications
You must be signed in to change notification settings - Fork 544
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
XWIKI-22121: Improve the registration experience #3155
Open
Sereza7
wants to merge
26
commits into
xwiki:master
Choose a base branch
from
Sereza7:XWIKI-22121
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
26 commits
Select commit
Hold shift + click to select a range
d0e251c
XWIKI-22121: Improve the registration experience - Part C
Sereza7 157fd99
XWIKI-22121: Improve the registration experience - Part C
Sereza7 641dc53
XWIKI-22121: Improve the registration experience - Part A
Sereza7 f631969
XWIKI-22121: Improve the registration experience - Part B
Sereza7 78fdc81
XWIKI-22121: Improve the registration experience - Part B
Sereza7 cd64ac2
XWIKI-22121: Improve the registration experience - Part B
Sereza7 4c3045c
Merge branch 'xwiki:master' into XWIKI-22121
Sereza7 bee22da
XWIKI-22121: Improve the registration experience - Part B
Sereza7 d3cab05
XWIKI-22121: Improve the registration experience - Part B
Sereza7 af3c804
XWIKI-22121: Improve the registration experience - Part B
Sereza7 39445e5
Merge branch 'xwiki:master' into XWIKI-22121
Sereza7 fa5e492
XWIKI-22121: Improve the registration experience
Sereza7 1bd4025
XWIKI-22121: Improve the registration experience
Sereza7 8b9fb00
XWIKI-22121: Improve the registration experience
Sereza7 d24b61e
XWIKI-22121: Improve the registration experience
Sereza7 d328145
XWIKI-22121: Improve the registration experience
Sereza7 3618247
XWIKI-22121: Improve the registration experience
Sereza7 cf825e4
Merge branch 'xwiki:master' into XWIKI-22121
Sereza7 23b31ed
XWIKI-22121: Improve the registration experience
Sereza7 af46c36
XWIKI-22121: Improve the registration experience
Sereza7 683ccd5
XWIKI-22121: Improve the registration experience
Sereza7 17237cc
XWIKI-22121: Improve the registration experience
Sereza7 699558b
Merge branch 'master' into XWIKI-22121
Sereza7 420b092
XWIKI-22121: Improve the registration experience
Sereza7 2467089
XWIKI-22121: Improve the registration experience
Sereza7 d0bcd33
Merge branch 'xwiki:master' into XWIKI-22121
Sereza7 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -243,7 +243,8 @@ void registerJohnSmith(boolean isModal, boolean closedWiki, boolean withRegistra | |
{ | ||
AbstractRegistrationPage registrationPage = setUp(testUtils, isModal, closedWiki, withRegistrationConfig); | ||
registrationPage.fillInJohnSmithValues(); | ||
assertTrue(validateAndRegister(testUtils, isModal, registrationPage)); | ||
assertTrue(validateAndRegister(testUtils, isModal, registrationPage), String.format("isModal: %s close " | ||
+ "wiki: %s withRegistrationConfig: %s", isModal, closedWiki, withRegistrationConfig)); | ||
tryToLoginAsJohnSmith(testUtils, AbstractRegistrationPage.JOHN_SMITH_PASSWORD, registrationPage); | ||
} | ||
|
||
|
@@ -345,7 +346,6 @@ void registerWikiSyntaxName(boolean isModal, boolean closedWiki, boolean withReg | |
AbstractRegistrationPage.JOHN_SMITH_USERNAME, password, password, "[email protected]"); | ||
assertTrue(validateAndRegister(testUtils, isModal, registrationPage), String.format("isModal: %s close " | ||
+ "wiki: %s withRegistrationConfig: %s", isModal, closedWiki, withRegistrationConfig)); | ||
|
||
// TODO: looks like a pretty strange behavior, there might be a message box title missing somewhere | ||
String messagePrefix = closedWiki ? "" : "Information "; | ||
|
||
|
190 changes: 157 additions & 33 deletions
190
...administration/xwiki-platform-administration-ui/src/main/resources/XWiki/Registration.xml
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -522,9 +522,30 @@ | |
<passwordRuleOneUpperCaseEnabled>0</passwordRuleOneUpperCaseEnabled> | ||
</property> | ||
<property> | ||
<registrationSuccessMessage>#set($message = $services.localization.render('core.register.successful', 'xwiki/2.1', ['USERLINK', $userName])) | ||
<registrationSuccessMessage>#set($discard = $xwiki.ssx.use("XWiki.RegistrationConfig")) | ||
#set($displayName = "$!firstName $!lastName") | ||
#set($noReadableName = ($!firstName == "") || ($!lastName == "")) | ||
#if($noReadableName) | ||
#set($displayName = $userName) | ||
#end | ||
#set($headline = $services.localization.render('core.register.successful.welcome', [$displayName])) | ||
#set($userLink = $xwiki.getUserName("$userSpace$userName")) | ||
{{info}}$message.replace('USERLINK', "{{html clean=false}}$userLink{{/html}}"){{/info}}</registrationSuccessMessage> | ||
#set($successAndLogin = $services.localization.render('core.register.successful.successandlogin')) | ||
[[image:undraw_done_re_oak4.svg||data-xwiki-image-style-alignment="center" height="50vh"]] | ||
|
||
{{html clean="true"}} | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. clean="true" is the default AFAIK |
||
<div class="registration-success-headline"> | ||
<h2>$headline </h2> | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Probably need some escaping |
||
#if(!$noReadableName) | ||
<p class="registration-success-subtitle"> | ||
($userName) | ||
</p> | ||
#end | ||
</div> | ||
<p class="registration-success-hint"> | ||
$successAndLogin | ||
</p> | ||
{{/html}}</registrationSuccessMessage> | ||
</property> | ||
<property> | ||
<requireCaptcha>0</requireCaptcha> | ||
|
@@ -533,4 +554,144 @@ | |
<welcomeMessage>{{translation key="core.register.welcome"/}}</welcomeMessage> | ||
</property> | ||
</object> | ||
<object> | ||
<name>XWiki.RegistrationConfig</name> | ||
<number>0</number> | ||
<className>XWiki.StyleSheetExtension</className> | ||
<guid>6e9139ba-c4ac-4243-9ca7-9e935b0cc730</guid> | ||
<class> | ||
<name>XWiki.StyleSheetExtension</name> | ||
<customClass/> | ||
<customMapping/> | ||
<defaultViewSheet/> | ||
<defaultEditSheet/> | ||
<defaultWeb/> | ||
<nameField/> | ||
<validationScript/> | ||
<cache> | ||
<cache>0</cache> | ||
<defaultValue>long</defaultValue> | ||
<disabled>0</disabled> | ||
<displayType>select</displayType> | ||
<freeText>forbidden</freeText> | ||
<largeStorage>0</largeStorage> | ||
<multiSelect>0</multiSelect> | ||
<name>cache</name> | ||
<number>5</number> | ||
<prettyName>Caching policy</prettyName> | ||
<relationalStorage>0</relationalStorage> | ||
<separator> </separator> | ||
<separators>|, </separators> | ||
<size>1</size> | ||
<unmodifiable>0</unmodifiable> | ||
<values>long|short|default|forbid</values> | ||
<classType>com.xpn.xwiki.objects.classes.StaticListClass</classType> | ||
</cache> | ||
<code> | ||
<contenttype>PureText</contenttype> | ||
<disabled>0</disabled> | ||
<editor>PureText</editor> | ||
<name>code</name> | ||
<number>2</number> | ||
<prettyName>Code</prettyName> | ||
<restricted>0</restricted> | ||
<rows>20</rows> | ||
<size>50</size> | ||
<unmodifiable>0</unmodifiable> | ||
<classType>com.xpn.xwiki.objects.classes.TextAreaClass</classType> | ||
</code> | ||
<contentType> | ||
<cache>0</cache> | ||
<disabled>0</disabled> | ||
<displayType>select</displayType> | ||
<freeText>forbidden</freeText> | ||
<largeStorage>0</largeStorage> | ||
<multiSelect>0</multiSelect> | ||
<name>contentType</name> | ||
<number>6</number> | ||
<prettyName>Content Type</prettyName> | ||
<relationalStorage>0</relationalStorage> | ||
<separator> </separator> | ||
<separators>|, </separators> | ||
<size>1</size> | ||
<unmodifiable>0</unmodifiable> | ||
<values>CSS|LESS</values> | ||
<classType>com.xpn.xwiki.objects.classes.StaticListClass</classType> | ||
</contentType> | ||
<name> | ||
<disabled>0</disabled> | ||
<name>name</name> | ||
<number>1</number> | ||
<prettyName>Name</prettyName> | ||
<size>30</size> | ||
<unmodifiable>0</unmodifiable> | ||
<classType>com.xpn.xwiki.objects.classes.StringClass</classType> | ||
</name> | ||
<parse> | ||
<disabled>0</disabled> | ||
<displayFormType>select</displayFormType> | ||
<displayType>yesno</displayType> | ||
<name>parse</name> | ||
<number>4</number> | ||
<prettyName>Parse content</prettyName> | ||
<unmodifiable>0</unmodifiable> | ||
<classType>com.xpn.xwiki.objects.classes.BooleanClass</classType> | ||
</parse> | ||
<use> | ||
<cache>0</cache> | ||
<disabled>0</disabled> | ||
<displayType>select</displayType> | ||
<freeText>forbidden</freeText> | ||
<largeStorage>0</largeStorage> | ||
<multiSelect>0</multiSelect> | ||
<name>use</name> | ||
<number>3</number> | ||
<prettyName>Use this extension</prettyName> | ||
<relationalStorage>0</relationalStorage> | ||
<separator> </separator> | ||
<separators>|, </separators> | ||
<size>1</size> | ||
<unmodifiable>0</unmodifiable> | ||
<values>currentPage|onDemand|always</values> | ||
<classType>com.xpn.xwiki.objects.classes.StaticListClass</classType> | ||
</use> | ||
</class> | ||
<property> | ||
<cache>long</cache> | ||
</property> | ||
<property> | ||
<code>.registration-success-headline { | ||
display: flex; | ||
align-items: baseline; | ||
justify-content: center; | ||
} | ||
|
||
.registration-success-headline > .registration-success-subtitle { | ||
display: block; | ||
} | ||
|
||
.registration-success-hint { | ||
display: block; | ||
text-align: center; | ||
} | ||
|
||
/* Resize the hero image displayed when the registration is successful so that the buttons are always on screen without | ||
needing to scroll. */ | ||
img.wikigeneratedid { | ||
height: 50vh; | ||
}</code> | ||
</property> | ||
<property> | ||
<contentType></contentType> | ||
</property> | ||
<property> | ||
<name></name> | ||
</property> | ||
<property> | ||
<parse/> | ||
</property> | ||
<property> | ||
<use>onDemand</use> | ||
</property> | ||
</object> | ||
</xwikidoc> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Any reason for not using directly some html to put in the html macro for that one?