[ofbiz-framework] branch trunk updated (f85040f -> 51d9161)

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

[ofbiz-framework] branch trunk updated (f85040f -> 51d9161)

jleroux@apache.org
This is an automated email from the ASF dual-hosted git repository.

jleroux pushed a change to branch trunk
in repository https://gitbox.apache.org/repos/asf/ofbiz-framework.git.


    from f85040f  Improved: Headerize external script in multi-block html template (OFBIZ-11741)
     new 6c6f1e1  Improved: Rainbow theme: use the United Nations flag ad default flag (OFBIZ-11705)
     new 51d9161  Improved: Rainbow theme: use the United Nations flag ad default flag (OFBIZ-11705)

The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 themes/rainbowstone/template/includes/Avatar.ftl   | 10 ++--
 .../webapp/rainbowstone/flag-icon.min.css          |  2 +-
 .../webapp/rainbowstone/flags/1x1/un.svg           | 68 ++++++++++++++++++++++
 .../webapp/rainbowstone/flags/4x3/un.svg           | 68 ++++++++++++++++++++++
 4 files changed, 143 insertions(+), 5 deletions(-)
 create mode 100644 themes/rainbowstone/webapp/rainbowstone/flags/1x1/un.svg
 create mode 100644 themes/rainbowstone/webapp/rainbowstone/flags/4x3/un.svg

Reply | Threaded
Open this post in threaded view
|

[ofbiz-framework] 01/02: Improved: Rainbow theme: use the United Nations flag ad default flag (OFBIZ-11705)

jleroux@apache.org
This is an automated email from the ASF dual-hosted git repository.

jleroux pushed a commit to branch trunk
in repository https://gitbox.apache.org/repos/asf/ofbiz-framework.git

commit 6c6f1e1135cba6a35ac4c5eb37bcc3db743c3817
Author: Jacques Le Roux <[hidden email]>
AuthorDate: Sun May 31 12:36:44 2020 +0200

    Improved: Rainbow theme: use the United Nations flag ad default flag (OFBIZ-11705)
   
    This follows OFBIZ-9866: where I proposed to use the United Nations flag
    as default flag
   
    Pierre noticed that no flag shows when a meta language (like en) is chosen.
   
    I noticed that some meta language have default values (gb, fr, zh, th). So I did
    not apply Pierre's GH PR#154 to keep those, because that can be increased.
   
    I added the un.svg flag from https://en.wikipedia.org/wiki/United_Nations
    I did not adapt its size. Since it's SVG it should be OK in most cases
    I also added the necessary change at the end of in flag-icon.min.css
   
    Thanks: Pierre Smits for the initial patch
---
 themes/rainbowstone/template/includes/Avatar.ftl          | 10 ++++++----
 themes/rainbowstone/webapp/rainbowstone/flag-icon.min.css |  2 +-
 2 files changed, 7 insertions(+), 5 deletions(-)

diff --git a/themes/rainbowstone/template/includes/Avatar.ftl b/themes/rainbowstone/template/includes/Avatar.ftl
index b32a43d..0100f36 100644
--- a/themes/rainbowstone/template/includes/Avatar.ftl
+++ b/themes/rainbowstone/template/includes/Avatar.ftl
@@ -41,10 +41,12 @@ under the License.
             <a id="user-lang" href="<@ofbizUrl>ListLocales</@ofbizUrl>">
             <#assign userLang = locale.toString()>
             <#assign flagLang = locale.toString()?keep_after_last("_")>
-            <#if "en" == userLang><#assign flagLang = "GB"></#if>
-            <#if "fr" == userLang><#assign flagLang = "FR"></#if>
-            <#if "zh" == userLang><#assign flagLang = "SG"></#if>
-            <#if "th" == userLang><#assign flagLang = "TH"></#if>
+            <#if "en" == userLang || "fr" == userLang || "zh" == userLang || "th" == userLang>
+                <#if "en" == userLang><#assign flagLang = "GB"></#if>
+                <#if "fr" == userLang><#assign flagLang = "FR"></#if>
+                <#if "zh" == userLang><#assign flagLang = "SG"></#if>
+                <#if "th" == userLang><#assign flagLang = "TH"></#if>
+            <#elseif 2 == userLang?length><#assign flagLang = "UN"></#if>
                 <span class="flag-icon flag-icon-<#if userLang?size <= 2>${userLang}<#else>${flagLang?lower_case}</#if>"><#if userLang?size <= 2>${userLang}<#else>${flagLang}</#if></span>
             </a>
         </div>
diff --git a/themes/rainbowstone/webapp/rainbowstone/flag-icon.min.css b/themes/rainbowstone/webapp/rainbowstone/flag-icon.min.css
index dd768f4..5a8d636 100644
--- a/themes/rainbowstone/webapp/rainbowstone/flag-icon.min.css
+++ b/themes/rainbowstone/webapp/rainbowstone/flag-icon.min.css
@@ -17,4 +17,4 @@
  * under the License.
  */
 
-.flag-icon,.flag-icon-background{background-repeat:no-repeat;background-size:contain;background-position:50%}.flag-icon{position:relative;display:inline-block;width:1.33333333em;line-height:1em}.flag-icon:before{content:"\00a0"}.flag-icon.flag-icon-squared{width:1em}.flag-icon-ad{background-image:url(/rainbowstone/flags//4x3/ad.svg)}.flag-icon-ad.flag-icon-squared{background-image:url(/rainbowstone/flags//1x1/ad.svg)}.flag-icon-ae{background-image:url(/rainbowstone/flags//4x3/ae.svg)}.fl [...]
\ No newline at end of file
+.flag-icon,.flag-icon-background{background-repeat:no-repeat;background-size:contain;background-position:50%}.flag-icon{position:relative;display:inline-block;width:1.33333333em;line-height:1em}.flag-icon:before{content:"\00a0"}.flag-icon.flag-icon-squared{width:1em}.flag-icon-ad{background-image:url(/rainbowstone/flags//4x3/ad.svg)}.flag-icon-ad.flag-icon-squared{background-image:url(/rainbowstone/flags//1x1/ad.svg)}.flag-icon-ae{background-image:url(/rainbowstone/flags//4x3/ae.svg)}.fl [...]
\ No newline at end of file

Reply | Threaded
Open this post in threaded view
|

[ofbiz-framework] 02/02: Improved: Rainbow theme: use the United Nations flag ad default flag (OFBIZ-11705)

jleroux@apache.org
In reply to this post by jleroux@apache.org
This is an automated email from the ASF dual-hosted git repository.

jleroux pushed a commit to branch trunk
in repository https://gitbox.apache.org/repos/asf/ofbiz-framework.git

commit 51d91619ea582920e003849c5542f0d52b5c2b44
Author: Jacques Le Roux <[hidden email]>
AuthorDate: Sun May 31 12:39:20 2020 +0200

    Improved: Rainbow theme: use the United Nations flag ad default flag (OFBIZ-11705)
   
    Oops, I missed to add the un flag files
---
 .../webapp/rainbowstone/flags/1x1/un.svg           | 68 ++++++++++++++++++++++
 .../webapp/rainbowstone/flags/4x3/un.svg           | 68 ++++++++++++++++++++++
 2 files changed, 136 insertions(+)

diff --git a/themes/rainbowstone/webapp/rainbowstone/flags/1x1/un.svg b/themes/rainbowstone/webapp/rainbowstone/flags/1x1/un.svg
new file mode 100644
index 0000000..d5b503f
--- /dev/null
+++ b/themes/rainbowstone/webapp/rainbowstone/flags/1x1/un.svg
@@ -0,0 +1,68 @@
+<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" height="800" width="1200"><head xmlns=""><style id="dark-reader-style">@media screen {
+
+/* Leading rule */
+html {
+  -webkit-filter: invert(100%) hue-rotate(180deg) !important;
+  filter: invert(100%) hue-rotate(180deg) !important;
+}
+
+/* Reverse rule */
+img,
+video,
+:not(object):not(body)&gt;embed,
+object,
+svg image,
+[style*="background:url"],
+[style*="background-image:url"],
+[style*="background: url"],
+[style*="background-image: url"],
+[background],
+twitterwidget {
+  -webkit-filter: invert(100%) hue-rotate(180deg) !important;
+  filter: invert(100%) hue-rotate(180deg) !important;
+}
+[style*="background:url"] *,
+[style*="background-image:url"] *,
+[style*="background: url"] *,
+[style*="background-image: url"] *,
+input,
+[background] *,
+img[src^="https://s0.wp.com/latex.php"],
+twitterwidget .NaturalImage-image {
+  -webkit-filter: none !important;
+  filter: none !important;
+}
+.compatibility-with-darkreader-below-4-3-3 {
+  background: white !important;
+}
+
+/* Text contrast */
+html {
+  text-shadow: 0 0 0 !important;
+}
+
+/* Full screen */
+:-webkit-full-screen, :-webkit-full-screen * {
+  -webkit-filter: none !important;
+  filter: none !important;
+}
+:-moz-full-screen, :-moz-full-screen * {
+  -webkit-filter: none !important;
+  filter: none !important;
+}
+:fullscreen, :fullscreen * {
+  -webkit-filter: none !important;
+  filter: none !important;
+}
+
+/* Page background */
+html {
+  background: rgb(0,0,0) !important;
+}
+
+/* Custom rules */
+.compatibility-with-darkreader-below-4-3-3 {
+    background: white !important;
+}
+
+}</style></head><path fill="#418fde" fill-rule="evenodd" d="M0 0h1200v800H0z"/><g transform="translate(-.02 2.173)"><g transform="translate(-1.081)"><path d="M663.853 587.03c-2.694 3.079-6.18 5.956-9.466 8.608-21.233-21.943-46.16-46.262-69.854-46.262-14.69 0-25.27 11.182-37.613 19.072-17.13 10.949-40.626 17.115-60.761 9.08-10.83-4.113-21.323-10.17-29.165-20.01 15.848 10.93 39.58 12.4 57.472 4.977 19.776-8.205 39.904-19.099 62.44-19.099 33.223 0 64.797 22.473 86.947 43.635zm-245.542-69.01 [...]
\ No newline at end of file
diff --git a/themes/rainbowstone/webapp/rainbowstone/flags/4x3/un.svg b/themes/rainbowstone/webapp/rainbowstone/flags/4x3/un.svg
new file mode 100644
index 0000000..d5b503f
--- /dev/null
+++ b/themes/rainbowstone/webapp/rainbowstone/flags/4x3/un.svg
@@ -0,0 +1,68 @@
+<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" height="800" width="1200"><head xmlns=""><style id="dark-reader-style">@media screen {
+
+/* Leading rule */
+html {
+  -webkit-filter: invert(100%) hue-rotate(180deg) !important;
+  filter: invert(100%) hue-rotate(180deg) !important;
+}
+
+/* Reverse rule */
+img,
+video,
+:not(object):not(body)&gt;embed,
+object,
+svg image,
+[style*="background:url"],
+[style*="background-image:url"],
+[style*="background: url"],
+[style*="background-image: url"],
+[background],
+twitterwidget {
+  -webkit-filter: invert(100%) hue-rotate(180deg) !important;
+  filter: invert(100%) hue-rotate(180deg) !important;
+}
+[style*="background:url"] *,
+[style*="background-image:url"] *,
+[style*="background: url"] *,
+[style*="background-image: url"] *,
+input,
+[background] *,
+img[src^="https://s0.wp.com/latex.php"],
+twitterwidget .NaturalImage-image {
+  -webkit-filter: none !important;
+  filter: none !important;
+}
+.compatibility-with-darkreader-below-4-3-3 {
+  background: white !important;
+}
+
+/* Text contrast */
+html {
+  text-shadow: 0 0 0 !important;
+}
+
+/* Full screen */
+:-webkit-full-screen, :-webkit-full-screen * {
+  -webkit-filter: none !important;
+  filter: none !important;
+}
+:-moz-full-screen, :-moz-full-screen * {
+  -webkit-filter: none !important;
+  filter: none !important;
+}
+:fullscreen, :fullscreen * {
+  -webkit-filter: none !important;
+  filter: none !important;
+}
+
+/* Page background */
+html {
+  background: rgb(0,0,0) !important;
+}
+
+/* Custom rules */
+.compatibility-with-darkreader-below-4-3-3 {
+    background: white !important;
+}
+
+}</style></head><path fill="#418fde" fill-rule="evenodd" d="M0 0h1200v800H0z"/><g transform="translate(-.02 2.173)"><g transform="translate(-1.081)"><path d="M663.853 587.03c-2.694 3.079-6.18 5.956-9.466 8.608-21.233-21.943-46.16-46.262-69.854-46.262-14.69 0-25.27 11.182-37.613 19.072-17.13 10.949-40.626 17.115-60.761 9.08-10.83-4.113-21.323-10.17-29.165-20.01 15.848 10.93 39.58 12.4 57.472 4.977 19.776-8.205 39.904-19.099 62.44-19.099 33.223 0 64.797 22.473 86.947 43.635zm-245.542-69.01 [...]
\ No newline at end of file