Skip to content

Commit f583783

Browse files
upgrade to new patterns
1 parent 40e980d commit f583783

File tree

5 files changed

+49
-261
lines changed

5 files changed

+49
-261
lines changed

_includes/layouts/side-bar.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -263,7 +263,7 @@
263263

264264
{% if ai_ml == true %}
265265
<li class="--sidebar-item">
266-
<a href="#ai-ml" class="js-splash--navigation-item">Artificial Intelligence and Machine Learning</a>
266+
<a href="/{{langue}}/ai-ml/" class="js-splash--navigation-item">Artificial Intelligence and Machine Learning</a>
267267
</li>
268268
{% endif %}
269269

_includes/posts/documentation_eg.html

+23-28
Original file line numberDiff line numberDiff line change
@@ -98,15 +98,15 @@
9898
{% if show_header %}
9999
<a href="#fundamentals" name="fundamentals" id="fundamentals">Fundamentals</a>
100100
{% endif %}
101-
101+
102102
</header>
103103
<section class="--grid">
104104
<ul class="--grid-list">
105105
{%- for page in languagelist -%}
106106
{% if page.display_as == "file_settings" %}
107107

108108
{% include layouts/grid-item.html %}
109-
109+
110110

111111
{% endif %}
112112
{%- endfor -%}
@@ -115,21 +115,20 @@
115115
</section>
116116
{% endif %}
117117

118-
{% if chart_type %}
119-
<section class="--tutorial-section">
118+
{% if ai_ml %}
119+
<section class="--tutorial-section" id="ai_ml">
120120
<header class="--section-header">
121121
{% if show_header %}
122122

123-
<a href="#basic-charts" name="basic" id="basic-charts">Basic Charts</a>
123+
<a href="#ai_ml">Artificial Intelligence and Machine Learning</a>
124124

125125
{% endif %}
126126

127127
</header>
128128
<section class="--grid">
129129
<ul class="--grid-list">
130130
{%- for page in languagelist -%}
131-
{% if page.display_as == "chart_type" or page.display_as == "basic" %}
132-
131+
{% if page.display_as == "ai_ml" %}
133132

134133
{% include layouts/grid-item.html %}
135134

@@ -141,20 +140,21 @@
141140
</section>
142141
{% endif %}
143142

144-
{% if statistical %}
145-
<section class="--tutorial-section" id="statistical-charts">
143+
{% if chart_type %}
144+
<section class="--tutorial-section">
146145
<header class="--section-header">
147146
{% if show_header %}
148147

149-
<a href="#statistical-charts">Statistical Charts</a>
148+
<a href="#basic-charts" name="basic" id="basic-charts">Basic Charts</a>
150149

151150
{% endif %}
152151

153152
</header>
154153
<section class="--grid">
155154
<ul class="--grid-list">
156155
{%- for page in languagelist -%}
157-
{% if page.display_as == "statistical" %}
156+
{% if page.display_as == "chart_type" or page.display_as == "basic" %}
157+
158158

159159
{% include layouts/grid-item.html %}
160160

@@ -166,28 +166,23 @@
166166
</section>
167167
{% endif %}
168168

169-
{% if ai_ml %}
170-
<section class="--tutorial-section" id="ai-ml">
171-
<header class="--section-header"><a href="#ai-ml" name="ai-ml" id="basic-charts">Artifical Intelligence and Machine Learning Charts</a>
169+
{% if statistical %}
170+
<section class="--tutorial-section" id="statistical-charts">
171+
<header class="--section-header">
172+
{% if show_header %}
173+
174+
<a href="#statistical-charts">Statistical Charts</a>
175+
176+
{% endif %}
177+
172178
</header>
173179
<section class="--grid">
174180
<ul class="--grid-list">
175181
{%- for page in languagelist -%}
176-
{% if page.display_as == "ai_ml" %}
177-
178-
<li style="background-image: url({{site.imgurl}}{{page.thumbnail}});" class="--grid-item">
179-
<a href="{% if page.permalink contains 'http' %}{{page.permalink}}{% else %}/{{page.permalink}}{% endif %}">
180-
182+
{% if page.display_as == "statistical" %}
181183

182-
<!--<a href="{{page.permalink}}">-->
183-
<div class="--item-meta"><span>{{page.name}}</span></div>
184-
<div class="--item-image">
185-
<span>View Tutorial</span>
186-
<img src="{{site.imgurl}}{{page.thumbnail}}" alt="{{page.name}}">
187-
</div>
188-
</a>
184+
{% include layouts/grid-item.html %}
189185

190-
</li>
191186

192187
{% endif %}
193188
{%- endfor -%}
@@ -908,4 +903,4 @@ <h4 class="example-section-title" id="layout-options">
908903

909904
{% if page.language == "matlab" %}
910905
<p><em>MATLAB is a registered trademark of The MathWorks, Inc.</em></p>
911-
{% endif %}
906+
{% endif %}

_includes/posts/mainlang_documentation_eg.html

+24
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,8 @@
4141
{% assign chart_studio = true %}
4242
{% elsif page.display_as == "advanced_opt" %}
4343
{% assign advanced_opt = true %}
44+
{% elsif page.display_as == "ai_ml" %}
45+
{% assign ai_ml = true %}
4446

4547
{% endif %}
4648
{%- endfor -%}
@@ -78,6 +80,28 @@
7880
</section>
7981
{% endif %}
8082

83+
84+
85+
{% if ai_ml %}
86+
<section class="--tutorial-section">
87+
<header class="--section-header"><a href="#ai_ml" name="ai_ml" id="ai_ml">Artificial Intelligence and Machine Learning</a>
88+
<a href="/{{language}}/ai-ml/" class="langindexlink">More AI and ML &raquo;</a>
89+
</header>
90+
<section class="--grid">
91+
<ul class="--grid-list">
92+
{%- for page in languagelist -%}
93+
{% if page.display_as == "ai_ml" and page.order < num_examples %}
94+
95+
96+
{% include layouts/grid-item.html %}
97+
{% endif %}
98+
{%- endfor -%}
99+
</ul>
100+
<a href="/{{language}}/ai-ml/" class="langindexlink-mobile">More AI and ML &raquo;</a>
101+
</section>
102+
</section>
103+
{% endif %}
104+
81105
{% if chart_type %}
82106
<section class="--tutorial-section">
83107
<header class="--section-header"><a href="#basic-charts" id="basic-charts">Basic Charts</a>

_posts/python/2020-02-23-ai-index.html

+1-3
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,19 @@
11
---
22
permalink: python/ai-ml/
33
description: Plotly's Python graphing library makes interactive, publication-quality graphs online. Examples of how to make charts related to artificial intelligence and machine learning.
4-
name: More Artificial Intelligence and Machine Learning Charts
4+
name: AI and ML Charts
55
layout: langindex
66
language: python
77
display_as: ai_ml
88
thumbnail: thumbnail/mixed.jpg
99
page_type: example_index
10-
order: 5
1110
---
1211

1312

1413
<header class="--welcome">
1514
<div class="--welcome-body">
1615
<!--div.--wrap-inner-->
1716
<div class="--title">
18-
<div class="--category-img"><img src="https://plot.ly/gh-pages/documentation/static/images/python-small.png" alt=""></div>
1917
<div class="--body">
2018
<h1>Plotly Python Open Source Graphing Library Artificial Intelligence and Machine Learning Charts</h1>
2119
<p>{{page.description}}</p>

0 commit comments

Comments
 (0)