Skip to content

Commit 16cb94d

Browse files
committed
Fix make doc command fails in development
Closes #4134
1 parent 8a5ebf3 commit 16cb94d

10 files changed

+961
-0
lines changed

.gitignore

+1
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ esm
77
es6
88
docs/_site/
99
docs/.jekyll-metadata
10+
docs/.jekyll-cache
1011
packages/react-admin/docs
1112
examples/**/static
1213
examples/**/dist

docs/_layouts/default.html

+118
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,118 @@
1+
<!DOCTYPE HTML>
2+
<html lang="en-US">
3+
4+
<head>
5+
<title>React-admin - {{ page.title }}</title>
6+
<meta charset="UTF-8">
7+
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
8+
<meta content="text/html; charset=utf-8" http-equiv="Content-Type">
9+
<meta name="description" content="{{ page.description }}">
10+
<meta name="HandheldFriendly" content="true" />
11+
<meta name="viewport" content="width=device-width, initial-scale=1">
12+
<meta name="apple-mobile-web-app-capable" content="yes">
13+
<meta name="apple-mobile-web-app-status-bar-style" content="black">
14+
<link rel="stylesheet" href="{{ '/css/materialize.min.css' | relative_url }}">
15+
<link rel="stylesheet" href="{{ '/css/style-v3.css' | relative_url }}">
16+
<link rel="stylesheet" href="{{ '/css/syntax.css' | relative_url }}">
17+
<link rel="stylesheet" href="{{ '/css/prism.css' | relative_url }}">
18+
<link rel="stylesheet" href="https://fonts.googleapis.com/icon?family=Material+Icons">
19+
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/docsearch.js@2/dist/cdn/docsearch.min.css" />
20+
<!-- You won't find analytics tags in this page. React-admin protects your privacy! -->
21+
</head>
22+
23+
<body>
24+
25+
<header>
26+
<nav>
27+
<a href="#" data-target="slide-out" class="sidenav-trigger"><i class="material-icons">menu</i></a>
28+
<div class="nav-wrapper" style="background: linear-gradient(145deg,#027be3 11%,#1a237e 75%)">
29+
<div class="left">
30+
<form action="#" onsubmit="return false;">
31+
<div class="input-field" style="position:absolute">
32+
<input type="search" name="q" id="query" size="31" maxlength="255" value=""
33+
style="vertical-align:inherit!important" />
34+
<label class="label-icon" for="test"><i class="material-icons">search</i></label>
35+
<i class="material-icons">close</i>
36+
</div>
37+
<span id="search"></span>
38+
</form>
39+
</div>
40+
<ul id="nav-mobile" class="right hide-on-med-and-down">
41+
<li class="active"><a href="https://marmelab.com/react-admin/Readme.html">Documentation</a></li>
42+
<li><a href="https://marmelab.com/react-admin-demo">Demo</a></li>
43+
<li><a href="https://marmelab.com/en/blog/#react-admin">Blog</a></li>
44+
<li><a href="https://github.com/marmelab/react-admin">GitHub</a></li>
45+
</ul>
46+
</div>
47+
</nav>
48+
<ul id="slide-out" class="sidenav sidenav-fixed">
49+
<li class="logo">
50+
<a href="{{ site.url }}"><img src="{{ site.url }}/assets/logo_white.png" /></a>
51+
</li>
52+
{% include_relative navigation.html %}
53+
</ul>
54+
55+
</header>
56+
57+
<main>
58+
<div class="container">
59+
<div class="row">
60+
<div class="col s12 m8 offset-m1 xl7 offset-xl1 markdown-section DocSearch-content">
61+
{{ content }}
62+
</div>
63+
<div class="col hide-on-small-only m3 xl3 offset-xl1">
64+
<div class="toc-wrapper">
65+
<div style="height: 1px;">
66+
<ul class="section table-of-contents pushpin">
67+
</ul>
68+
</div>
69+
</div>
70+
</div>
71+
</div>
72+
</div>
73+
</main>
74+
75+
<script src="{{ '/js/materialize.min.js' | relative_url }}"></script>
76+
<script src="{{ 'js/prism.js' | relative_url }}"></script>
77+
<script>
78+
function slugify(text) {
79+
return text.toString().toLowerCase()
80+
.replace(/\s+/g, '-') // Replace spaces with -
81+
.replace(/[^\w\-]+/g, '') // Remove all non-word chars
82+
.replace(/\-\-+/g, '-') // Replace multiple - with single -
83+
.replace(/^-+/, '') // Trim - from start of text
84+
.replace(/-+$/, ''); // Trim - from end of text
85+
}
86+
document.addEventListener('DOMContentLoaded', function () {
87+
/* Generate table of contents */
88+
document.querySelectorAll('.markdown-section h2').forEach(element => {
89+
element.classList.add('scrollspy');
90+
var a = document.createElement('a');
91+
a.href = "#" + slugify(element.innerText);
92+
a.innerText = element.innerText;
93+
var li = document.createElement('li');
94+
li.appendChild(a);
95+
document.querySelector('.table-of-contents').appendChild(li)
96+
})
97+
M.Sidenav.init(document.querySelectorAll('.sidenav'));
98+
M.Pushpin.init(document.querySelector('.pushpin'), { offset: 75, top: 75 });
99+
M.ScrollSpy.init(document.querySelectorAll('.scrollspy'));
100+
M.Dropdown.init(document.querySelectorAll('.dropdown-trigger'));
101+
});
102+
</script>
103+
<script type="text/javascript" src="https://cdn.jsdelivr.net/npm/docsearch.js@2/dist/cdn/docsearch.min.js"></script>
104+
<script type="text/javascript">
105+
docsearch({
106+
apiKey: '32f254b1de6a25a96665d1229b6eb8f7',
107+
indexName: 'marmelab-react-admin',
108+
inputSelector: '#query',
109+
debug: false, // Set debug to true if you want to inspect the dropdown
110+
autocompleteOptions: {
111+
appendTo: '#search',
112+
hint: false,
113+
}
114+
});
115+
</script>
116+
</body>
117+
118+
</html>

docs/assets/logo_white.png

5.19 KB
Loading

docs/css/materialize.min.css

+13
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docs/css/prism.css

+139
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,139 @@
1+
/* http://prismjs.com/download.html?themes=prism&languages=markup+css+clike+javascript+jsx */
2+
/**
3+
* prism.js default theme for JavaScript, CSS and HTML
4+
* Based on dabblet (http://dabblet.com)
5+
* @author Lea Verou
6+
*/
7+
8+
code[class*="language-"],
9+
pre[class*="language-"] {
10+
color: black;
11+
background: none;
12+
text-shadow: 0 1px white;
13+
font-family: Consolas, Monaco, 'Andale Mono', 'Ubuntu Mono', monospace;
14+
text-align: left;
15+
white-space: pre;
16+
word-spacing: normal;
17+
word-break: normal;
18+
word-wrap: normal;
19+
line-height: 1.5;
20+
21+
-moz-tab-size: 4;
22+
-o-tab-size: 4;
23+
tab-size: 4;
24+
25+
-webkit-hyphens: none;
26+
-moz-hyphens: none;
27+
-ms-hyphens: none;
28+
hyphens: none;
29+
}
30+
31+
pre[class*="language-"]::-moz-selection, pre[class*="language-"] ::-moz-selection,
32+
code[class*="language-"]::-moz-selection, code[class*="language-"] ::-moz-selection {
33+
text-shadow: none;
34+
background: #b3d4fc;
35+
}
36+
37+
pre[class*="language-"]::selection, pre[class*="language-"] ::selection,
38+
code[class*="language-"]::selection, code[class*="language-"] ::selection {
39+
text-shadow: none;
40+
background: #b3d4fc;
41+
}
42+
43+
@media print {
44+
code[class*="language-"],
45+
pre[class*="language-"] {
46+
text-shadow: none;
47+
}
48+
}
49+
50+
/* Code blocks */
51+
pre[class*="language-"] {
52+
padding: 1em;
53+
margin: .5em 0 1.275em 0;
54+
overflow: auto;
55+
}
56+
57+
:not(pre) > code[class*="language-"],
58+
pre[class*="language-"] {
59+
background: #f5f2f0;
60+
}
61+
62+
/* Inline code */
63+
:not(pre) > code[class*="language-"] {
64+
padding: .1em;
65+
border-radius: .3em;
66+
white-space: normal;
67+
}
68+
69+
.token.comment,
70+
.token.prolog,
71+
.token.doctype,
72+
.token.cdata {
73+
color: slategray;
74+
}
75+
76+
.token.punctuation {
77+
color: #999;
78+
}
79+
80+
.namespace {
81+
opacity: .7;
82+
}
83+
84+
.token.property,
85+
.token.tag,
86+
.token.boolean,
87+
.token.number,
88+
.token.constant,
89+
.token.symbol,
90+
.token.deleted {
91+
color: #905;
92+
}
93+
94+
.token.selector,
95+
.token.attr-name,
96+
.token.string,
97+
.token.char,
98+
.token.builtin,
99+
.token.inserted {
100+
color: #690;
101+
}
102+
103+
.token.operator,
104+
.token.entity,
105+
.token.url,
106+
.language-css .token.string,
107+
.style .token.string {
108+
color: #a67f59;
109+
background: hsla(0, 0%, 100%, .5);
110+
}
111+
112+
.token.atrule,
113+
.token.attr-value,
114+
.token.keyword {
115+
color: #07a;
116+
}
117+
118+
.token.function {
119+
color: #DD4A68;
120+
}
121+
122+
.token.regex,
123+
.token.important,
124+
.token.variable {
125+
color: #e90;
126+
}
127+
128+
.token.important,
129+
.token.bold {
130+
font-weight: bold;
131+
}
132+
.token.italic {
133+
font-style: italic;
134+
}
135+
136+
.token.entity {
137+
cursor: help;
138+
}
139+

0 commit comments

Comments
 (0)