From 086ff8d39a6defadacd29592b3ec0584366f6848 Mon Sep 17 00:00:00 2001 From: "Kyle J. McKay" Date: Wed, 26 Oct 2016 05:21:29 -0700 Subject: [PATCH] : improve formatting Add some formatting rules for the element so that it formats approximately the same but does not corrupt the line spacing anymore. One instance that should not have been using at all is just converted to a plain span instead. With these changes superscripts are still superscripts, they just no longer cause the line to grow in height thus avoiding an ugly look on the page where the line with the superscript has extra space around it. Signed-off-by: Kyle J. McKay --- Girocco/Config.pm | 2 +- Girocco/User.pm | 4 ++-- cgi/delproj.cgi | 4 ++-- cgi/editproj.cgi | 8 ++++---- cgi/edituser.cgi | 2 +- cgi/regproj.cgi | 8 ++++---- cgi/reguser.cgi | 2 +- gitweb/gitweb.css | 24 ++++++++++++++++++++++++ gitweb/gitweb_config.perl | 2 +- html/girocco.css | 24 ++++++++++++++++++++++++ 10 files changed, 64 insertions(+), 16 deletions(-) diff --git a/Girocco/Config.pm b/Girocco/Config.pm index 0c7e47c..032b792 100644 --- a/Girocco/Config.pm +++ b/Girocco/Config.pm @@ -568,7 +568,7 @@ our $legalese = <By submitting this form, you are confirming that you will mirror or push only what we can store and show to anyone else who can visit this site without breaking any law, and that you will be nice to all small furry animals. -(more details) +(more details)

EOT diff --git a/Girocco/User.pm b/Girocco/User.pm index 9feba22..a1d9dfe 100644 --- a/Girocco/User.pm +++ b/Girocco/User.pm @@ -327,9 +327,9 @@ sub keys_html_list { $html .= "
". - "download https push user authentication certificate ". + "download https push user authentication certificate ". "". - "(learn more)" + "(learn more)" if $type eq 'ssh-rsa' && $Girocco::Config::httpspushurl && $Girocco::Config::clientcert && $Girocco::Config::clientkey; diff --git a/cgi/delproj.cgi b/cgi/delproj.cgi index 8ddc514..8ba2fab 100755 --- a/cgi/delproj.cgi +++ b/cgi/delproj.cgi @@ -179,8 +179,8 @@ $name ($url) from the site.

EOT if ($Girocco::Config::project_passwords) { print <Admin password: (forgot password?)

+

Admin password: (forgot password?)

EOT } print <Admin password: - (forgot password?) + class="ctxaction">(forgot password?)
New admin password (twice):
(leave empty to keep it the same)

@@ -175,12 +175,12 @@ EOT "@{[url_path($Girocco::Config::webadmurl)]}/reguser.cgi\">registered users may push.

"; if ($Girocco::Config::mob and not grep { $_ eq $Girocco::Config::mob } @{$h{users}}) { print "

(Please consider adding the $Girocco::Config::mob user.\n"; - print "(learn more))\n"; + print "(learn more))\n"; print "

\n"; } foreach my $user (@{$h{users}}) { my $mlm = ''; - $mlm = " (learn more)" + $mlm = " (learn more)" if $Girocco::Config::mob && $user eq $Girocco::Config::mob; print "
  • $user$mlm
  • \n"; } diff --git a/cgi/edituser.cgi b/cgi/edituser.cgi index 647322b..8b042b6 100755 --- a/cgi/edituser.cgi +++ b/cgi/edituser.cgi @@ -151,7 +151,7 @@ EOT my $httpspara = ''; $httpspara = <Please be sure to include at least one RSA key (starts with the ssh-rsa prefix) in -order to enable HTTPS pushing. (learn more)
    +order to enable HTTPS pushing. (learn more)
    An X.509 (e.g. OpenSSL) format public key can be converted to SSH .pub format with the ConvertPubKey utility thus obviating the need for OpenSSH if all pushing is to be done using HTTPS (see the example in the TIPS section of the ConvertPubKey -h output).

    diff --git a/cgi/regproj.cgi b/cgi/regproj.cgi index 4a1187c..218adb7 100755 --- a/cgi/regproj.cgi +++ b/cgi/regproj.cgi @@ -136,7 +136,7 @@ EOT my @pushurls = (); push(@pushurls, "$Girocco::Config::pushurl/$name.git") if $Girocco::Config::pushurl; push(@pushurls, "$Girocco::Config::httpspushurl/$name.git " . - "(learn more)") + "(learn more)") if $Girocco::Config::httpspushurl; print "

    The push URL(s) for the project: " . join(", ", @pushurls) . "

    " if @pushurls; my @pullurls = (); @@ -154,9 +154,9 @@ EOT } my $pushy = $Girocco::Config::pushurl || $Girocco::Config::httpspushurl; my $pushyhint = ''; - $pushyhint = " # " . - "(learn more)" . - "" if $pushy =~ /^https:/i; + $pushyhint = " # " . + "(learn more)" + if $pushy =~ /^https:/i; print <You can assign users now - don't forget to assign yourself as a user as well if you want to push! diff --git a/cgi/reguser.cgi b/cgi/reguser.cgi index fc230c4..90bd576 100755 --- a/cgi/reguser.cgi +++ b/cgi/reguser.cgi @@ -66,7 +66,7 @@ EOT my $httpspara = ''; $httpspara = <Please be sure to include at least one RSA key (starts with the ssh-rsa prefix) in -order to enable HTTPS pushing. (learn more)
    +order to enable HTTPS pushing. (learn more)
    X.509 (e.g. OpenSSL) format public keys can be converted to SSH .pub format with the ConvertPubKey utility thus obviating the need for OpenSSH if all pushing is to be done using HTTPS (see the example in the TIPS section of the ConvertPubKey -h output).

    diff --git a/gitweb/gitweb.css b/gitweb/gitweb.css index ef543c8..30d8cfa 100644 --- a/gitweb/gitweb.css +++ b/gitweb/gitweb.css @@ -1 +1,25 @@ /* Girocco-specific fragment of gitweb.css, appended at the end. */ + +sup.sup { + position: relative; + font-size: 100%; + vertical-align: baseline; + bottom: +1ex; +} +sup.sup > span:first-child { + position: relative; + font-size: smaller; + top: +1pt; +} + +sub.sub { + position: relative; + font-size: 100%; + vertical-align: baseline; + top: +1pt; +} +sub.sub > span:first-child { + position: relative; + font-size: smaller; + top: +0.5ex; +} diff --git a/gitweb/gitweb_config.perl b/gitweb/gitweb_config.perl index cb20144..0e08ac2 100644 --- a/gitweb/gitweb_config.perl +++ b/gitweb/gitweb_config.perl @@ -76,7 +76,7 @@ our $git_base_bundles_url = url_path($Girocco::Config::bundlesurl); # e.g. "https push instructions" our $https_hint_html = undef; $https_hint_html = substr(<(learn more)
    +(learn more) HINT # owner link hook given owner name (full and NOT obfuscated) diff --git a/html/girocco.css b/html/girocco.css index a9b410f..47df4a8 100644 --- a/html/girocco.css +++ b/html/girocco.css @@ -174,3 +174,27 @@ div.htmlcgi h4 { .hover:hover > span:first-child { visibility: visible; } + +sup.sup { + position: relative; + font-size: 100%; + vertical-align: baseline; + bottom: +1ex; +} +sup.sup > span:first-child { + position: relative; + font-size: smaller; + top: +1pt; +} + +sub.sub { + position: relative; + font-size: 100%; + vertical-align: baseline; + top: +1pt; +} +sub.sub > span:first-child { + position: relative; + font-size: smaller; + top: +0.5ex; +} -- 2.11.4.GIT