Skip to content

Make outdated banner noisier, cleanup layouts #2634

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

Merged
merged 7 commits into from
Nov 17, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion _getting-started/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ title: Getting Started
partof: getting-started
languages: [fr, ja, ru, uk]
includeTOC: true

newcomer_resources:
- title: Are You Coming From Java?
description: What you should know to get to speed with Scala after your initial setup.
Expand Down
16 changes: 0 additions & 16 deletions _includes/inner-page-main-content.html

This file was deleted.

7 changes: 7 additions & 0 deletions _includes/outdated-notice.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
<div class="inline-sticky-top inline-sticky-top-higher">
<div class="wip-notice">
<h4>Outdated Notice</h4>
<p><a class="new-version-notice" href="{{ include.new-version }}"><i class="fa fa-info"></i><span>&nbsp;&nbsp;
This page has a new version.</span></a></p>
</div>
</div>
7 changes: 4 additions & 3 deletions _includes/sidebar-toc-multipage-overview.html
Original file line number Diff line number Diff line change
Expand Up @@ -50,9 +50,10 @@ <h5 class="contents">Contents</h5>
<li><a href="{{ site.baseurl }}/{{ l }}/{{ rootTutorialURL }}" class="lang">{{ lang.name }}</a></li>
{% endfor %}
</ul>
{% elsif page.language %}
{% assign engPath = page.id | remove_first: "/" | remove_first: page.language | append: '.html' %}
{% assign engPg = site.overviews | where: 'partof', page.partof | first %}
{% elsif page.language and page.orphanTranslation == false %}
<!-- i.e. some pages like '/zh-cn/thanks.html' have no english version -->
{% assign engPath = page.id | remove_first: "/" | remove_first: page.language | append: '.html' %}
{% assign engPg = site.overviews | where: 'partof', page.partof | first %}
<ul id="available-languages" style="display: none;">
<li><a href="{{ site.baseurl }}{{ engPath }}">English</a></li>
{% for l in engPg.languages %}
Expand Down
11 changes: 6 additions & 5 deletions _includes/sidebar-toc-singlepage-overview.html
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,14 @@ <h5 class="contents">Contents</h5>
{% for l in page.languages %}
{% capture intermediate %}{{ page.url }}{% endcapture %}
{% capture rootTutorialURL %}{{ intermediate | remove_first: '/' }}{% endcapture %}
{% assign lang = site.data.languages[l] %}
<li><a href="{{ site.baseurl }}/{{ l }}/{{ rootTutorialURL }}" class="lang">{{ lang.name }}</a></li>
{% assign lang = site.data.languages[l] %}
<li><a href="{{ site.baseurl }}/{{ l }}/{{ rootTutorialURL }}" class="lang">{{ lang.name }}</a></li>
{% endfor %}
</ul>
{% elsif page.language %}
{% assign engPath = page.id | remove_first: "/" | remove_first: page.language | append: '.html' %}
{% assign engPg = site.overviews | where: 'partof', page.partof | first %}
{% elsif page.language and page.orphanTranslation == false %}
<!-- i.e. some pages like '/zh-cn/thanks.html' have no english version -->
{% assign engPath = page.id | remove_first: "/" | remove_first: page.language | append: '.html' %}
{% assign engPg = site.overviews | where: 'partof', page.partof | first %}
<ul id="available-languages" style="display: none;">
<li><a href="{{ site.baseurl }}{{ engPath }}">English</a></li>
{% for l in engPg.languages %}
Expand Down
2 changes: 1 addition & 1 deletion _ja/index.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
layout: documentation
layout: landing-page-deprecated
title: ドキュメント
language: ja
partof: documentation
Expand Down
2 changes: 1 addition & 1 deletion _ja/scala3/contribute-to-docs.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
layout: inner-page-documentation
layout: singlepage-overview
overview-name: "Scala 3 Documentation"
title: Contributing to the Docs
language: ja
Expand Down
4 changes: 1 addition & 3 deletions _ja/scala3/guides.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
layout: inner-page-parent
layout: root-index-layout
title: Scala 3 のガイド
language: ja
scala3: true
Expand Down Expand Up @@ -36,5 +36,3 @@ guides:
</div>
</div>
</section>


4 changes: 2 additions & 2 deletions _ja/scala3/index.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
layout: inner-page-documentation
layout: landing-page
title: Documentation for Scala 3
language: ja
namespace: root
Expand Down Expand Up @@ -41,4 +41,4 @@ sections:
description: "Scala 3 の言語仕様"
icon: "fa fa-book"
link: https://docs.scala-lang.org/scala3/reference
---
---
2 changes: 1 addition & 1 deletion _layouts/inner-page.html → _layouts/basic-index.html
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
layout: inner-page-parent
layout: root-index-layout
---

<section class="full-width">
Expand Down
6 changes: 0 additions & 6 deletions _layouts/blog-detail.html

This file was deleted.

9 changes: 0 additions & 9 deletions _layouts/blog-list.html

This file was deleted.

5 changes: 4 additions & 1 deletion _layouts/cheatsheet.html
Original file line number Diff line number Diff line change
@@ -1,12 +1,15 @@
---
layout: inner-page-parent-dropdown
layout: root-content-layout
---

<section class="full-width">
<div class="wrap">
<div class="content-primary cheatsheet">
<div class="inner-box">
<div class="toc-context">
{% if page.new-version %}
{% include outdated-notice.html new-version=page.new-version %}
{% endif %}
{{content}}
</div>

Expand Down
17 changes: 0 additions & 17 deletions _layouts/contribute.html

This file was deleted.

13 changes: 0 additions & 13 deletions _layouts/events.html

This file was deleted.

Loading