From 95f16c99bd049b04384ddf9fbf4eb7858f90fec1 Mon Sep 17 00:00:00 2001 From: hankhill19580 <hankhill19580@gmail.com> Date: Fri, 3 Jul 2020 23:18:14 +0000 Subject: [PATCH] Remove Why I2P from the welcome wizard. Make the welcome wizard more informative about the functionality contained within I2P. Tweaks to stylesheets on the welcome wizard. --- .../i2p/router/web/helpers/WizardHandler.java | 6 +- apps/routerconsole/jsp/welcome.jsp | 118 +++++++++++------- .../resources/themes/console/dark/console.css | 19 +-- .../themes/console/light/console.css | 13 +- 4 files changed, 93 insertions(+), 63 deletions(-) diff --git a/apps/routerconsole/java/src/net/i2p/router/web/helpers/WizardHandler.java b/apps/routerconsole/java/src/net/i2p/router/web/helpers/WizardHandler.java index 16a9fcc7d5..3651248999 100644 --- a/apps/routerconsole/java/src/net/i2p/router/web/helpers/WizardHandler.java +++ b/apps/routerconsole/java/src/net/i2p/router/web/helpers/WizardHandler.java @@ -45,9 +45,9 @@ public class WizardHandler extends FormHandler { // Saved in CSSHelper, assume success addFormNoticeNoEscape(_t("Console language saved.")); } - if ("4".equals(page)) { + if ("3".equals(page)) { startNDT(); - } else if ("5".equals(page)) { + } else if ("4".equals(page)) { synchronized (_helper) { if (_helper.isNDTSuccessful()) { addFormNotice(_t("Bandwidth test completed successfully")); @@ -60,7 +60,7 @@ public class WizardHandler extends FormHandler { addFormError(_t("Bandwidth test did not complete")); } } - } else if ("6".equals(page)) { + } else if ("5".equals(page)) { Map<String, String> changes = new HashMap<String, String>(); boolean updated = updateRates(changes); if (updated) { diff --git a/apps/routerconsole/jsp/welcome.jsp b/apps/routerconsole/jsp/welcome.jsp index ac8d8c7e01..acd02896a7 100644 --- a/apps/routerconsole/jsp/welcome.jsp +++ b/apps/routerconsole/jsp/welcome.jsp @@ -4,7 +4,7 @@ // The MLabHelper singleton will prevent multiple simultaneous tests, even across sessions. // page ID - final int LAST_PAGE = 7; + final int LAST_PAGE = 6; String pg = request.getParameter("page"); int ipg; if (pg == null) { @@ -14,14 +14,14 @@ ipg = Integer.parseInt(pg); if (request.getParameter("prev") != null) { // previous button handling - if (ipg == 6) - ipg = 3; + if (ipg == 5) + ipg = 2; else ipg -= 2; } if (ipg <= 0 || ipg > LAST_PAGE) { ipg = 1; - } else if (ipg == 4 && request.getParameter("skipbw") != null) { + } else if (ipg == 3 && request.getParameter("skipbw") != null) { ipg++; // skip bw test } } catch (NumberFormatException nfe) { @@ -64,7 +64,7 @@ <%=intl.title("New Install Wizard")%> <% wizhelper.setContextId(i2pcontextId); - if (ipg == 4) { + if (ipg == 3) { %> <script src="/js/welcomeajax.js?<%=net.i2p.CoreVersion.VERSION%>" type="text/javascript"></script> <script nonce="<%=cspNonce%>" type="text/javascript"> @@ -81,7 +81,7 @@ }, true); </script> <% - } // ipg == 4 + } // ipg == 3 %> </head><body> <div id="wizard" class="overlay"> @@ -108,7 +108,7 @@ <%-- needed for CSS: --%><div id="config_ui"> <%-- needed for lang setting in css.jsi: --%><input type="hidden" name="consoleNonce" value="<%=net.i2p.router.web.CSSHelper.getNonce()%>" > <img class="wizard progress" src="/themes/console/images/wizard/wizardlogo.png"> -<h3 id="wizardheading" class="wizard"><%=uihelper._t("Router Console Language")%></h3> +<h3 id="wizardheading" class="wizard"><%=uihelper._t("Select Language")%></h3> <img class="wizardimg" src="/themes/console/images/wizard/step-0.png"> <div class="clickableProgression"> <span class="currentProgression">⬤</span> @@ -117,37 +117,26 @@ <span class="unvisitedProgression">◯</span> <span class="unvisitedProgression">◯</span> <span class="unvisitedProgression">◯</span> +<span class="unvisitedProgression">◯</span> </div> <div id="wizlangsettings" class="wizard"> <jsp:getProperty name="uihelper" property="langSettings" /> </div> -</div> -<% - - } else if (ipg == 2) { - // I2P Philosophy - // license info? -%> -<img class="wizard progress" src="/themes/console/images/wizard/wizardlogo.png"> -<h3 id="wizardheading" class="wizard"><%=intl._t("Why I2P?")%></h3> -<img class="wizardimg" src="/themes/console/images/wizard/step-1.png"> -<div class="clickableProgression"> -<span class="visitedProgression">◯</span> -<span class="currentProgression">⬤</span> -<span class="unvisitedProgression">◯</span> -<span class="unvisitedProgression">◯</span> -<span class="unvisitedProgression">◯</span> -<span class="unvisitedProgression">◯</span> -</div> <div class="wizardtext"> <p> -<%=intl._t("I2P is a communication tool for people who value privacy and wish to remain anonymous online.")%> -<%=intl._t("I2P is a peer to peer network where you can browse and create hidden services.")%> +<%=intl._t("Please select your preferred language")%> +</p> +<p> +<%=intl._t("This project is supported by Transifex and OTF through the Localization Lab.")%> +<%=intl._t("Thank you to all of the volunteers all over the world who help keep our project")%> +<%=intl._t("accessible. I2P is always looking for support to keep its documentation up to date,")%> +<a href="https://www.transifex.com/projects/p/I2P/" target="_blank"><%=intl._t("please consider supporting our translation efforts.")%></a> </p> </div> +</div> <% - } else if (ipg == 3) { + } else if (ipg == 2) { // Overview of bandwidth test %> <img class="wizard progress" src="/themes/console/images/wizard/wizardlogo.png"> @@ -155,17 +144,18 @@ <img class="wizardimg" src="/themes/console/images/wizard/step-2.png"> <div class="clickableProgression"> <span class="visitedProgression">◯</span> -<span class="visitedProgression">◯</span> <span class="currentProgression">⬤</span> <span class="unvisitedProgression">◯</span> <span class="unvisitedProgression">◯</span> <span class="unvisitedProgression">◯</span> +<span class="unvisitedProgression">◯</span> </div> <div class="wizardtext"> <p> <%=intl._t("I2P will now test your internet connection to identify the optimal speed settings.")%> <%=intl._t("Bandwidth participation improves the anonymity level of all users on the network and maximizes your download speed.")%> <%=intl._t("This is done using the third-party M-Lab service.")%> +<%=intl._t("During this time you will be connected directly to M-Lab's service, with your real IP address.")%> </p><p> <%=intl._t("Please review the M-Lab privacy policies linked below.")%> <%=intl._t("If you do not wish to run the M-Lab bandwidth test, you may skip it by clicking the button below.")%> @@ -176,7 +166,7 @@ </div> <% - } else if (ipg == 4) { + } else if (ipg == 3) { // Bandwidth test in progress (w/ AJAX) %> <img class="wizard progress" src="/themes/console/images/wizard/wizardlogo.png"> @@ -185,10 +175,10 @@ <div class="clickableProgression"> <span class="visitedProgression">◯</span> <span class="visitedProgression">◯</span> -<span class="visitedProgression">◯</span> <span class="currentProgression">⬤</span> <span class="unvisitedProgression">◯</span> <span class="unvisitedProgression">◯</span> +<span class="unvisitedProgression">◯</span> </div> <div id="xhr" class="notifcation"> <!-- for non-script --> @@ -196,9 +186,23 @@ </div> <div id="xhr2" class="notification"> </div> +<div class="wizardtext"> +<p> +<%=intl._t("While the I2P router software is getting ready to go, it's testing your bandwidth, obtaining an initial")%> +<%=intl._t("set of peers from a reseed server, making it's first few exploratory peer connections, and getting.")%> +<%=intl._t("integrated with the rest of the network.")%> +</p> +<p> +<%=intl._t("To learn more about these topics and what functions they perform for I2P, you can visit our")%> +<a href="http://geti2p.net" target="_blank"><%=intl._t("web site")%></a><%=intl._t(", our")%> +<a href="http://wiki.i2p-projekt.i2p" target="_blank"><%=intl._t("wiki")%></a><%=intl._t(", or contact us on our")%> +<a href="http://i2pforum.net" target="_blank"><%=intl._t("forums")%></a> +<%=intl._t("to get help from the community.")%> +</p> +</div> <% - } else if (ipg == 5) { + } else if (ipg == 4) { // Bandwidth test results // and/or manual bw entry? %> @@ -270,26 +274,31 @@ out.print(intl._t("NOTE")); out.print("</b>: "); out.print(intl._t("You have configured I2P to share only {0} KBps.", share)); - out.print("\n"); + out.print("</br>"); out.print(intl._t("I2P requires at least 12KBps to enable sharing. ")); - out.print(intl._t("Please enable sharing (participating in tunnels) by configuring more bandwidth. ")); - out.print(intl._t("It improves your anonymity by creating cover traffic, and helps the network.")); + out.print(intl._t("By donating your bandwidth to participating traffic, you not only help others, you improve ")); + out.print(intl._t("your own anonymity by creating cover traffic.")); + out.print("</br>"); + out.print(intl._t("We recommend sharing 75% or more for I2P, but you can adjust based on your needs.")); } else { out.print(intl._t("You have configured I2P to share {0} KBps.", share)); - out.print("\n"); + out.print("</br>"); - out.print(intl._t("The higher the share bandwidth the more you improve your anonymity and help the network.")); + out.print(intl._t("By donating your bandwidth to participating traffic, you not only help others, you improve ")); + out.print(intl._t("your own anonymity by creating cover traffic.")); + out.print("</br>"); + out.print(intl._t("We recommend sharing 75% or more for I2P, but you can adjust based on your needs.")); } %> </div> <% - } else if (ipg == 6) { + } else if (ipg == 5) { // Browser setup %> <img class="wizard progress" src="/themes/console/images/wizard/wizardlogo.png"> -<h3 id="wizardheading" class="wizard"><%=intl._t("Browser Setup")%></h3> +<h3 id="wizardheading" class="wizard"><%=intl._t("Browser and Application Setup")%></h3> <img class="wizardimg" src="/themes/console/images/wizard/step-5.png"> <div class="clickableProgression"> <span class="visitedProgression">◯</span> @@ -314,7 +323,25 @@ <% } //isWindows() %> -</p></div> +</p> +<p> +<%=intl._t("The I2P router also comes with it's own versions of common, useful internet applications like")%> +<a href="/torrents" target="_blank"><%=intl._t("bittorrent")%></a> +<%=intl._t("and")%> +<a href="/webmail" target="_blank"><%=intl._t("e-mail")%></a> +<%=intl._t("so you can keep doing the things you need to do.")%> +<%=intl._t("These applications work with I2P automatically and require no additional configuration.")%> +</p> +<p> +<%=intl._t("Normally, I2P addresses are long and random. To help make I2P addresses easier to read and remember,")%> +<%=intl._t("the I2P router also includes it's own built-in")%> +<a href="/dns" target="_blank"><%=intl._t("Address Book")%></a> +<%=intl._t("so you can")%> +<%=intl._t("privately assign human-readable names to the sites you like to visit.")%> +<%=intl._t("The Address Book can also be used to subscribe to lists of URL's shared by other I2P users who choose")%> +<%=intl._t("to distribute their own lists of hostnames and addresses.")%> +</p> +</div> <% } else if (ipg == LAST_PAGE) { @@ -333,10 +360,11 @@ </div> <div class="wizardtext"> <p> -<%=intl._t("When you start I2P, it may take a few minutes to bootstrap (integrate) your router into the network and find additional peers, so please be patient.")%> +<%=intl._t("When you start I2P for the first time, it needs need to integrate with the I2P network. It may also")%> +<%=intl._t("indicate that it is temporarily \"Rejecting Tunnels.\" This is a normal part of the process. Please be patient.")%> </p><p> -<%=intl._t("When I2P starts up, and during normal operation, I2P's tunnel build readiness indicator in the side panel may indicate that I2P is \"Rejecting Tunnels\"; this is normal behavior.")%> -<%=intl._t("Once green stars are indicated next to your Local Tunnels, there is a wide variety of things you can do with I2P.")%> +<%=intl._t("Green circles in the sidebar area of the I2P Router Console indicate that you are ready to use I2P")%> +<%=intl._t("for browsing or applications.")%> </p> </div> <% @@ -359,11 +387,11 @@ %> <input type="submit" class="cancel wizardbutton" name="skip" value="<%=intl._t("Skip Setup")%>" > <% - if (ipg == 3) { + if (ipg == 2) { %> <input type="submit" class="cancel wizardbutton" name="skipbw" value="<%=intl._t("Skip Bandwidth Test")%>" > <% - } else if (ipg == 4) { + } else if (ipg == 3) { %> <input type="submit" class="cancel wizardbutton" name="cancelbw" value="<%=intl._t("Cancel Bandwidth Test")%>" > <% diff --git a/installer/resources/themes/console/dark/console.css b/installer/resources/themes/console/dark/console.css index 4a027c37cc..38919d8252 100644 --- a/installer/resources/themes/console/dark/console.css +++ b/installer/resources/themes/console/dark/console.css @@ -1166,7 +1166,7 @@ div.widescroll { /* only scroll content, not entire page eg /peers */ div.messages { padding: 20px 10px 20px 50px; - margin: 10px 0 15px 0; +/* margin: 10px 0 15px 0;*/ border: 1px solid #292929; background: #1F1A24; background: url(images/confirmed.png) no-repeat 12px center, right bottom no-repeat #1F1A24; @@ -1200,7 +1200,7 @@ div.messages li { .wizardnotice { position: absolute; - top: 75%; + bottom: 5%; left: 5%; width: 22%; } @@ -3138,12 +3138,13 @@ td#themeselect { #infodiv { position: absolute; left: 32%; - width: 16%; + width: 34%; top: 50%; box-shadow: inset 0 0 0 1px #fff; filter: drop-shadow(0 0 1px #ccf); background: rgba(0,0,0,0.7); - padding: 2px; + padding: .5%; + text-align: justify; } #bandwidthconfig { @@ -3210,7 +3211,7 @@ div#wizlangsettings.wizard { border: none; position: absolute; left: 15%; - top: 30%; + top: 50%; } #langsettings hr { @@ -3540,10 +3541,10 @@ table#bandwidthconfig td:first-child { } #xhr2.notification { - width: 30%; - position: absolute; - left: 30%; - top: 40%; + width: 20%; + position: absolute; + left: 70%; + top: 30%; font-size: larger; } diff --git a/installer/resources/themes/console/light/console.css b/installer/resources/themes/console/light/console.css index 3696d8534a..e2efdfcc3e 100644 --- a/installer/resources/themes/console/light/console.css +++ b/installer/resources/themes/console/light/console.css @@ -2550,7 +2550,7 @@ td { #infodiv { position: absolute; left: 32%; - width: 16%; + width: 35%; top: 50%; box-shadow: inset 0 0 0 1px #fff; filter: drop-shadow(0 0 1px #ccf); @@ -2615,10 +2615,10 @@ td { } #xhr2.notification { - width: 30%; - position: absolute; - left: 60%; - top: 45%; + width: 20%; + position: absolute; + left: 70%; + top: 30%; font-size: larger; background: #eef; background: linear-gradient(to right, #fafaff, #eef); @@ -4864,7 +4864,7 @@ div#langsettings { div#wizlangsettings.wizard { position: absolute; left: 15%; - top: 30%; + top: 50%; } #themesettings hr, #langsettings hr { @@ -6197,6 +6197,7 @@ table#schedjobs { .infodiv { font-size: larger; + text-align: justify; } #peerdefs td:first-child { -- GitLab