creativecommons / creativecommons.org

Legacy legal code translations and general support issues
MIT License
155 stars 204 forks source link

New template for translations #898

Closed georgehari closed 5 years ago

georgehari commented 5 years ago

We just received the Slovenian translations for 4.0. The team produced the 6 HTML files based on the present template. This is the first translation that follows the new template, so we need to know where does the code start and where it ends.

I guess these parts should be removed from the HTML files of translations and they will be added later when the files are pushed live:

1


<div class="site-header-wrapper">
--
  | <header id="masthead" class="site-header sticky-nav-main sticky attached" role="banner">
  | <div class="site-header-main">
  | <div class="site-branding">
  | <a class="cc-site-logo-link" href="https://creativecommons.org/" rel="home">
  | <img class="cc-site-logo" src="https://creativecommons.org/wp-content/themes/cc/images/cc.logo.white.svg" height="72" width="303">
  | </a>
  | </div>
  | <button id="menu-toggle" class="menu-toggle"><i class="cc-icon-menu"></i> <span>Menu</span></button>
  | <div id="site-header-menu" class="site-header-menu">
  | <nav id="mobile-navigation" class="mobile-navigation" role="navigation" aria-label="Mobile Menu">
  | <div class="menu-mobile-menu-container"><ul id="menu-mobile-menu" class="mobile-menu">
  | <li id="menu-item-48798" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-48798"><a href="https://creativecommons.org/share-your-work/">Share your work</a></li>
  | <li id="menu-item-48799" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-48799"><a href="https://creativecommons.org/use-remix/">Use &amp; remix</a></li>
  | <li id="menu-item-48800" class="menu-item menu-item-type-post_type menu-item-object-page page_item page-item-7466 menu-item-48800"><a href="https://creativecommons.org/about/">What we do</a></li>
  | <li id="menu-item-48801" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-48801"><a href="https://creativecommons.org/blog/">Blog</a></li>
  | <li id="menu-item-48802" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-48802"><a href="https://creativecommons.org/about/global-affiliate-network/">Global Affiliate Network</a></li>
  | <li id="menu-item-48803" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-48803"><a href="https://creativecommons.org/use-remix/search-the-commons/">Search the Commons</a></li>
  | </ul></div>
  | </nav>
  | <nav id="site-navigation" class="main-navigation" role="navigation" aria-label="Primary Menu">
  | <div class="menu-primary-menu-container"><ul id="menu-primary-menu" class="primary-menu">
  | <li id="menu-item-48791" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-48791"><a href="https://creativecommons.org/share-your-work/">Share your work</a></li>
  | <li id="menu-item-48792" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-48792"><a href="https://creativecommons.org/use-remix/">Use &amp; remix</a></li>
  | <li id="menu-item-48570" class="menu-item menu-item-type-post_type menu-item-object-page page_item page-item-7466 menu-item-48570"><a href="https://creativecommons.org/about/">What we do</a></li>
  | <li id="menu-item-48793" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-48793"><a href="https://creativecommons.org/blog/">Blog</a></li>
  | </ul></div>
  | </nav>
  | <nav id="secondary-navigation" class="secondary-navigation" role="navigation" aria-label="Secondary Menu">
  | <div class="menu-secondary-menu-container"><ul id="menu-secondary-menu" class="secondary-menu"><li id="menu-item-48804" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-48804"><a href="https://creativecommons.org/about/global-affiliate-network/">Global Affiliate Network</a></li>
  | <li id="menu-item-48805" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-48805"><a href="https://creativecommons.org/use-remix/search-the-commons/">Search the Commons</a></li>
  | <li id="menu-item-48806" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-48806"><a href="https://creativecommons.org/about/contact/">Contact</a></li>
  | </ul></div>
  | </nav>
  | <nav id="social-navigation" class="social-navigation" role="navigation" aria-label="Social Links Menu">
  | <div class="menu-social-links-container"><ul id="menu-social-links" class="social-links-menu">
  | <li id="menu-item-48807" class="menu-item menu-item-type-custom menu-item-object-custom menu-item-48807"><a href="https://www.facebook.com/creativecommons"><span class="screen-reader-text">Facebook</span></a></li>
  | <li id="menu-item-48808" class="menu-item menu-item-type-custom menu-item-object-custom menu-item-48808"><a href="https://twitter.com/creativecommons"><span class="screen-reader-text">Twitter</span></a></li>
  | <li id="menu-item-48809" class="menu-item menu-item-type-custom menu-item-object-custom menu-item-48809"><a href="mailto:info@creativecommons.org"><span class="screen-reader-text">Mail</span></a></li>
  | </ul></div>
  | </nav>
  | </div>
  | </div>
  | </header>
  | <header class="site-header spacer" role="banner">
  | <div class="site-header-main">
  | <div class="site-branding">
  | <a class="cc-site-logo-link" href="https://creativecommons.org/" rel="home">
  | <img class="cc-site-logo" src="https://creativecommons.org/wp-content/themes/cc/images/cc.logo.white.svg" height="72" width="303">
  | </a>
  | </div>
  | <button id="menu-toggle" class="menu-toggle"><i class="cc-icon-menu"></i> <span>Menu</span></button>
  | <div id="site-header-menu" class="site-header-menu">
  | <nav id="mobile-navigation" class="mobile-navigation" role="navigation" aria-label="Mobile Menu">
  | <div class="menu-mobile-menu-container"><ul id="menu-mobile-menu" class="mobile-menu">
  | <li id="menu-item-48798" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-48798"><a href="https://creativecommons.org/share-your-work/">Share your work</a></li>
  | <li id="menu-item-48799" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-48799"><a href="https://creativecommons.org/use-remix/">Use &amp; remix</a></li>
  | <li id="menu-item-48800" class="menu-item menu-item-type-post_type menu-item-object-page page_item page-item-7466 menu-item-48800"><a href="https://creativecommons.org/about/">What we do</a></li>
  | <li id="menu-item-48801" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-48801"><a href="https://creativecommons.org/blog/">Blog</a></li>
  | <li id="menu-item-48802" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-48802"><a href="https://creativecommons.org/about/global-affiliate-network/">Global Affiliate Network</a></li>
  | <li id="menu-item-48803" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-48803"><a href="https://creativecommons.org/use-remix/search-the-commons/">Search the Commons</a></li>
  | </ul></div>
  | </nav>
  | <nav id="site-navigation" class="main-navigation" role="navigation" aria-label="Primary Menu">
  | <div class="menu-primary-menu-container"><ul id="menu-primary-menu" class="primary-menu">
  | <li id="menu-item-48791" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-48791"><a href="https://creativecommons.org/share-your-work/">Share your work</a></li>
  | <li id="menu-item-48792" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-48792"><a href="https://creativecommons.org/use-remix/">Use &amp; remix</a></li>
  | <li id="menu-item-48570" class="menu-item menu-item-type-post_type menu-item-object-page page_item page-item-7466 menu-item-48570"><a href="https://creativecommons.org/about/">What we do</a></li>
  | <li id="menu-item-48793" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-48793"><a href="https://creativecommons.org/blog/">Blog</a></li>
  | </ul></div>
  | </nav>
  | <nav id="secondary-navigation" class="secondary-navigation" role="navigation" aria-label="Secondary Menu">
  | <div class="menu-secondary-menu-container"><ul id="menu-secondary-menu" class="secondary-menu"><li id="menu-item-48804" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-48804"><a href="https://creativecommons.org/about/global-affiliate-network/">Global Affiliate Network</a></li>
  | <li id="menu-item-48805" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-48805"><a href="https://creativecommons.org/use-remix/search-the-commons/">Search the Commons</a></li>
  | <li id="menu-item-48806" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-48806"><a href="https://creativecommons.org/about/contact/">Contact</a></li>
  | </ul></div>
  | </nav>
  | <nav id="social-navigation" class="social-navigation" role="navigation" aria-label="Social Links Menu">
  | <div class="menu-social-links-container"><ul id="menu-social-links" class="social-links-menu">
  | <li id="menu-item-48807" class="menu-item menu-item-type-custom menu-item-object-custom menu-item-48807"><a href="https://www.facebook.com/creativecommons"><span class="screen-reader-text">Facebook</span></a></li>
  | <li id="menu-item-48808" class="menu-item menu-item-type-custom menu-item-object-custom menu-item-48808"><a href="https://twitter.com/creativecommons"><span class="screen-reader-text">Twitter</span></a></li>
  | <li id="menu-item-48809" class="menu-item menu-item-type-custom menu-item-object-custom menu-item-48809"><a href="mailto:info@creativecommons.org"><span class="screen-reader-text">Mail</span></a></li>
  | </ul></div>
  | </nav>
  | </div>
  | </div>
  | </header>
  | </div>
  | <aside id="header-below" class="widget-area">
  | <section id="text-15" class="widget-1 widget-first widget-last widget-odd widget widget_text">
  | <div class="textwidget">
  | <div id="donation-bar-wrapper" class="donation-bar-wrapper">
  | <div id="donation-bar-inner" class="donation-bar-inner">
  | <p class="donate-text">Help us build a vibrant, collaborative global commons</p>
  | <div class="donate-action"><a href="/donate?utm_campaign=2018fund&utm_source=license_header2018" class="button donate arrow">Donate<span class="hide-on-mobile"> Now</span></a></div>
  | </div>
  | </div>
  | </div>
  | </section>
  | </aside>
  |  
  |  
  | <div id="language-selector-block" class="container"> <div class="language-selector-inner">This page is available in the following languages: <img class="language-icon" src="/images/language_icon_x2.png" alt="Languages" /> <select><option value="legalcode.ar">العربية</option><option value="legalcode.de">Deutsch</option><option value="legalcode" selected="selected">English</option><option value="legalcode.es">Español</option><option value="legalcode.eu">euskara</option><option value="legalcode.fi">suomeksi</option><option value="legalcode.fr">français</option><option value="legalcode.hr">hrvatski</option><option value="legalcode.id">bahasa Indonesia</option><option value="legalcode.it">italiano</option><option value="legalcode.ja">日本語</option><option value="legalcode.lt">Lietuvių</option><option value="legalcode.lv">Latviski</option><option value="legalcode.mi">Te Reo Māori</option><option value="legalcode.nl">Nederlands</option><option value="legalcode.no">norsk</option><option value="legalcode.pl">polski</option><option value="legalcode.pt">Português</option><option value="legalcode.ru">русский</option><option value="legalcode.sv">svenska</option><option value="legalcode.tr">Türkçe</option><option value="legalcode.uk">українська</option> </select> </div></div>

2

<div class="site-footer-wrapper">
  | <footer id="colophon" class="site-footer sticky-nav-main" role="contentinfo">
  | <div class="cc-footer">
  | <div class="column cc-footer-main">
  | <div class="cc-footer-logo">
  | <a href="https://creativecommons.org/" class="custom-logo-link" rel="home" itemprop="url"><img src="https://creativecommons.org/wp-content/uploads/2016/06/cc.logo_.white_.png" class="custom-logo" alt="cc.logo.white" itemprop="logo" srcset="https://creativecommons.org/wp-content/uploads/2016/06/cc.logo_.white_.png 980w, https://creativecommons.org/wp-content/uploads/2016/06/cc.logo_.white_-300x73.png 300w, https://creativecommons.org/wp-content/uploads/2016/06/cc.logo_.white_-768x188.png 768w, https://creativecommons.org/wp-content/uploads/2016/06/cc.logo_.white_-140x34.png 140w, https://creativecommons.org/wp-content/uploads/2016/06/cc.logo_.white_-50x12.png 50w, https://creativecommons.org/wp-content/uploads/2016/06/cc.logo_.white_-270x66.png 270w, https://creativecommons.org/wp-content/uploads/2016/06/cc.logo_.white_-245x60.png 245w" sizes="(max-width: 709px) 85vw, (max-width: 909px) 67vw, (max-width: 1362px) 62vw, 840px" height="240" width="980"></a>
  | </div>
  | <div class="cc-footer-links">
  | <div class="menu-footer-links-container">
  | <ul id="menu-footer-links" class="menu">
  | <li id="menu-item-48794" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-48794"><a href="https://creativecommons.org/about/contact/">Contact</a></li>
  | <li id="menu-item-48795" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-48795"><a href="https://creativecommons.org/privacy/">Privacy</a></li>
  | <li id="menu-item-48796" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-48796"><a href="https://creativecommons.org/policies/">Policies</a></li>
  | <li id="menu-item-48797" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-48797"><a href="https://creativecommons.org/terms/">Terms</a></li>
  | </ul>
  | </div>
  | </div>
  | </div>
  | <div class="column cc-footer-contact">
  | <h6><a href="https://creativecommons.org/about/contact">We'd love to hear from you!</a></h6>
  | <address>
  | Creative Commons<br>
  | PO Box 1866, Mountain View, CA 94042
  | </address>
  | <ul>
  | <li><a href="mailto:info@creativecommons.org" class="mail">info@creativecommons.org</a></li>
  | <li><a href="https://creativecommons.org/faq">Frequently Asked Questions</a></li>
  | </ul>
  | </div>
  | <div class="column cc-footer-license">
  | <div class="license-icons">
  | <a rel="license" href="https://creativecommons.org/licenses/by/4.0/" title="Creative Commons Attribution 4.0 International license">
  | <i class="cc-icon-cc"></i>
  | <i class="cc-icon-cc-by"></i>
  | </a>
  | </div>
  | <aside>
  | <div xmlns:cc="https://creativecommons.org/ns#" about="https://creativecommons.org">
  | <p>Except where otherwise <a class="subfoot" href="https://creativecommons.org/policies#license">noted</a>, content on this site is licensed under a <a class="subfoot" href="https://creativecommons.org/licenses/by/4.0/" rel="license">Creative Commons Attribution 4.0 International license</a>. <a class="subfoot" href="https://creativecommons.org/website-icons" target="blank">Icons</a> by The Noun Project.</p>
  | </div>
  | </aside>
  | </div>
  | </div>
  | </footer>
  | </div>
  | <script type='text/javascript'>
  | /* <![CDATA[ */
  | var screenReaderText = {"expand":"expand child menu","collapse":"collapse child menu"};
  | /* ]]> */
  | </script>
  | <script type='text/javascript' src='https://creativecommons.org/wp-content/themes/twentysixteen/js/functions.js'></script>
  | </body>
  | </html>
 

@sarahpearson @peterspdx

georgehari commented 5 years ago

FYI, the Korean translations will follow the new template as well.

@sarahpearson

TimidRobot commented 5 years ago

@georgehari Which file are you using as the template?

My understanding is that the English Files were being used as a template:

To assist with their use, I added additional comments in HTML comments within 4.0 and cc0 English licenses by TimidRobot · Pull Request #981.

georgehari commented 5 years ago

I used the template above, from my first message in this thread, we didn't have a template to use for staging. So I had to do what I could. The aim is to make the staged files look like they were live.

georgehari commented 5 years ago

I guess we can use those English files.

I created a test language (pb language code), created a new branch and staged a test by-nc-sa file. It should be visible at the next Magical Pony update at https://cc4-pb-legalcode.legal.creativecommons.org/licenses/by-nc-sa/4.0/legalcode.pb.

Pushed https://github.com/creativecommons/creativecommons.org/commit/1de392f90d08b248444b8243103ace798e3eb192

georgehari commented 5 years ago

The staged file now looks good, so we can use the English license pages as templates for the future staged translations.

https://cc4-pb-legalcode.legal.creativecommons.org/licenses/by-nc-sa/4.0/legalcode.pb