Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
public
/
sequelize
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
不要怂,就是干,撸起袖子干!
Commit 94983785
authored
May 06, 2019
by
Pedro Augusto de Paula Barbosa
Committed by
Simon Schick
May 06, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
docs(data-types): separate nav menu (#10898)
1 parent
6091ca98
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
48 additions
and
0 deletions
.esdoc.json
docs/css/style.css
docs/plugins/group-data-types.js
.esdoc.json
View file @
9498378
...
@@ -60,6 +60,9 @@
...
@@ -60,6 +60,9 @@
]
]
}
}
}
}
},
{
"name"
:
"./docs/plugins/group-data-types"
}
}
]
]
}
}
docs/css/style.css
View file @
9498378
...
@@ -38,3 +38,9 @@ a[href^="file/lib/"] {
...
@@ -38,3 +38,9 @@ a[href^="file/lib/"] {
box-shadow
:
none
!important
;
box-shadow
:
none
!important
;
max-width
:
300px
;
max-width
:
300px
;
}
}
.navigation
{
margin-top
:
40px
!important
;
padding-top
:
0
;
height
:
calc
(
100%
-
40px
);
}
\ No newline at end of file
docs/plugins/group-data-types.js
0 → 100644
View file @
9498378
'use strict'
;
const
path
=
require
(
'path'
);
const
cheerio
=
require
(
'cheerio'
);
function
groupDataTypes
(
$
)
{
let
firstLi
;
$
(
'nav a'
).
each
(
function
()
{
/* eslint-disable no-invalid-this */
if
(
$
(
this
).
attr
(
'href'
).
startsWith
(
'class/lib/data-types.js~'
))
{
const
li
=
$
(
this
).
closest
(
'li'
);
if
(
!
firstLi
)
{
firstLi
=
li
;
firstLi
.
prepend
(
'<a data-ice="dirPath" class="nav-dir-path" href="variable/index.html#static-variable-DataTypes">datatypes</a>'
);
firstLi
.
appendTo
(
firstLi
.
parent
());
}
else
{
firstLi
.
after
(
li
);
}
}
});
}
class
GroupDataTypesPlugin
{
onHandleContent
(
ev
)
{
if
(
path
.
extname
(
ev
.
data
.
fileName
)
!==
'.html'
)
return
;
const
$
=
cheerio
.
load
(
ev
.
data
.
content
);
groupDataTypes
(
$
);
$
(
'nav li[data-ice=doc]:first-child'
).
css
(
'margin-top'
,
'15px'
);
ev
.
data
.
content
=
$
.
html
();
}
}
module
.
exports
=
new
GroupDataTypesPlugin
();
\ No newline at end of file
Write
Preview
Markdown
is supported
Attach a file
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to post a comment