Skip to content

Commit 2c814d6

Browse files
Add basic landing page for any tool (#337)
This is just a starting point with a generic config. Fixes #301 <!-- readthedocs-preview readthedocs-about start --> ---- 📚 Documentation preview 📚: https://readthedocs-about--337.org.readthedocs.build/ <!-- readthedocs-preview readthedocs-about end --> --------- Co-authored-by: Anthony <aj@ohess.org>
1 parent 7a42d75 commit 2c814d6

File tree

3 files changed

+233
-0
lines changed

3 files changed

+233
-0
lines changed
Lines changed: 108 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,108 @@
1+
<div class="ui container">
2+
<div class="ui horizontal divider">Try it out</div>
3+
</div>
4+
5+
<section id="try-it-out">
6+
<div class="ui padded container">
7+
<h2 class="ui huge center aligned header">
8+
Upgrade your documentation with Read the Docs
9+
</h2>
10+
11+
<div class="ui very padded centered grid">
12+
13+
<div class="ten wide computer sixteen wide tablet sixteen wide mobile column">
14+
<div class="ui large left aligned basic vertical segment">
15+
16+
{# Stylized code blocks #}
17+
{% call technical.code_block(title="<code>.readthedocs.yaml</code>", icon="fa-file") %}
18+
{% markdown %}
19+
20+
```yaml
21+
# Read the Docs configuration file for Sphinx projects
22+
# See https://docs.readthedocs.io/en/stable/config-file/v2.html for details
23+
24+
# Required
25+
version: 2
26+
27+
# Set the OS, Python version and other tools you might need
28+
build:
29+
os: ubuntu-24.04
30+
tools:
31+
python: "3.12"
32+
nodejs: "20"
33+
# You can also specify other tool versions:
34+
# rust: "1.70"
35+
# golang: "1.20"
36+
37+
# Support any tool with custom build commands
38+
commands:
39+
# Install dependencies
40+
- cd docs/ && npm install
41+
# Build the site
42+
- cd docs/ && npm run build
43+
# Copy generated files into Read the Docs directory
44+
- mkdir --parents $READTHEDOCS_OUTPUT/html/
45+
- cp --recursive docs/build/* $READTHEDOCS_OUTPUT/html/
46+
47+
```
48+
{% endmarkdown %}
49+
{% endcall %}
50+
</div>
51+
</div>
52+
53+
<div class="middle aligned left aligned six wide computer twelve wide tablet sixteen wide mobile column">
54+
<div class="ui padded basic segment">
55+
<div class="ui relaxed list">
56+
57+
{%- set header_1 = "Create an account" %}
58+
{%- set icon_1 = "fa-square-1" -%}
59+
<span class="ui small teal header item">
60+
<i class="fad {{ icon_1 }} secondary big icon"></i>
61+
<span class="content">
62+
{{ header_1 }}
63+
<span class="sub header">
64+
<a data-analytics="signup-modal"
65+
onclick="jQuery('#signup-modal').modal('show');">
66+
Sign up
67+
</a>
68+
with GitHub or your email.
69+
</span>
70+
</span>
71+
</span>
72+
73+
{%- set header_2 = "Import your project" %}
74+
{%- set icon_2 = "fa-square-2" -%}
75+
<span class="ui small header item">
76+
<i class="fad {{ icon_2 }} secondary big icon"></i>
77+
<span class="content">
78+
{{ header_2 }}
79+
<span class="sub header">Select your existing Git repositories with a 1-click interface.</span>
80+
</span>
81+
</span>
82+
83+
{%- set header_3 = "Add YAML config" %}
84+
{%- set icon_3 = "fa-square-3" -%}
85+
<span class="ui small header item">
86+
<i class="fad {{ icon_3 }} secondary big icon"></i>
87+
<span class="content">
88+
{{ header_3 }}
89+
<span class="sub header">Start with this example, and then adapt it.</span>
90+
</span>
91+
</span>
92+
93+
{%- set header_4 = "Your docs build on every commit" %}
94+
{%- set icon_4 = "fa-square-4" -%}
95+
<span class="ui small header item">
96+
<i class="fad {{ icon_4 }} secondary big icon"></i>
97+
<span class="content">
98+
{{ header_4 }}
99+
<span class="sub header">Like magic.</span>
100+
</span>
101+
</span>
102+
</div>
103+
</div>
104+
</div>
105+
106+
</div>
107+
</div>
108+
</section>

content/pages/custom.html

Lines changed: 124 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,124 @@
1+
{#
2+
The goal of this page is to highlight the flexibility of our platform in supporting any documentation tool,
3+
with full customization of the build commands you can run.
4+
#}
5+
6+
{#
7+
View this page at http://localhost:8080/tools/custom/
8+
#}
9+
10+
<html>
11+
<head>
12+
<title>Host any documentation tool</title>
13+
<meta name="template" content="page" />
14+
<meta name="slug" content="tools/custom" />
15+
<meta name="status" content="hidden" />
16+
<meta name="description" content="Read the Docs supports any documentation tool by allowing full control of the build commands your project runs. Enjoy powerful features such as search-as-you-type, previews from Git, and much more." />
17+
</head>
18+
<body>
19+
20+
{% import "partials/basic.html" as basic %}
21+
{% import "partials/marketing.html" as marketing %}
22+
{% import "partials/technical.html" as technical %}
23+
{% import "partials/homepage.html" as homepage %}
24+
25+
<section>
26+
{% call basic.header_image(
27+
header="Deploy with any tool",
28+
image="/images/homepage.png",
29+
image_alt="Examples of Read the Docs hosted documentation",
30+
vertical_align="middle")
31+
%}
32+
<p>
33+
Read the Docs supports any documentation tool by allowing full control of the build commands your project runs.
34+
Enjoy powerful features such as search-as-you-type, previews from Git, and much more.
35+
</p>
36+
37+
<p class="ui basic padded vertical segment">
38+
<a class="ui large teal stackable button"
39+
data-analytics="signup-modal"
40+
onclick="jQuery('#signup-modal').modal('show');">
41+
<i class="fad fa-play icon"></i>
42+
Create an account
43+
</a>
44+
<a href="https://docs.readthedocs.io/en/stable/build-customization.html#override-the-build-process" class="ui large stackable button">
45+
Learn more
46+
</a>
47+
</p>
48+
{% endcall %}
49+
</section>
50+
51+
<section id="features">
52+
{% call marketing.highlight_list() %}
53+
54+
{% call marketing.highlight_item(
55+
icon="olive fa-people-arrows",
56+
icon_style="--fa-secondary-color: violet; --fa-secondary-opacity: 1;",
57+
header="Collaborate with deploy previews",
58+
color="violet") %}
59+
{% markdown %}
60+
Receive feedback from your team,
61+
and <strong>have confidence in changes</strong> before they go live.
62+
{% endmarkdown %}
63+
{% endcall %}
64+
65+
{% call marketing.highlight_item(
66+
icon="yellow fa-magnifying-glass",
67+
icon_style="--fa-secondary-color: white; --fa-secondary-opacity: 1;",
68+
header="Always find what you need",
69+
color="violet") %}
70+
{% markdown %}
71+
Search across all your projects with our search-as-you-type interface,
72+
and <strong>never lose documentation again</strong>.
73+
{% endmarkdown %}
74+
{% endcall %}
75+
76+
{% call marketing.highlight_item(
77+
icon="fa-cogs",
78+
header="Full customization of build commands",
79+
color="violet") %}
80+
{% markdown %}
81+
Customize the build commands to suit your project's needs.
82+
<strong>Flexibility to support any tool</strong>.
83+
{% endmarkdown %}
84+
{% endcall %}
85+
86+
{% endcall %}
87+
</section>
88+
89+
{# Try it out code block #}
90+
{% include "includes/try-it-out-custom.html" %}
91+
92+
{% block homepage_bottom_callout %}
93+
<section>
94+
<div class="ui very padded container">
95+
<div class="ui grid center aligned">
96+
97+
<div class="row">
98+
<div class="column twelve wide computer sixteen wide tablet">
99+
100+
<div class="ui basic vertical huge segment">
101+
<p>
102+
<b>Get started with any documentation tool today.</b>
103+
</p>
104+
105+
<p>
106+
<a class="ui large teal stackable button"
107+
data-analytics="signup-modal"
108+
onclick="jQuery('#signup-modal').modal('show');">
109+
<i class="fad fa-play icon"></i>
110+
Create an account
111+
</a>
112+
</p>
113+
</div>
114+
115+
</div>
116+
</div>
117+
118+
</div>
119+
</div>
120+
</section>
121+
{% endblock homepage_bottom_callout %}
122+
123+
</body>
124+
</html>

readthedocs_theme/templates/includes/topnav.html

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,7 @@
4646
<a class="item" href="{{ SITEURL }}/tools/sphinx">Sphinx</a>
4747
<a class="item" href="{{ SITEURL }}/tools/mkdocs">Mkdocs</a>
4848
<a class="item" href="{{ SITEURL }}/tools/jupyter-book">Jupyter Book</a>
49+
<a class="item" href="{{ SITEURL }}/tools/custom">Other tools</a>
4950
</div>
5051
</div>
5152
{% endif %}

0 commit comments

Comments
 (0)