upgrade material doc; add multi version (#166)

* Fix: update css for material upgrade
* Feat: update ci.yml
This commit is contained in:
ethfoo 2023-07-05 10:14:32 +08:00 committed by GitHub
parent 4c43d36f21
commit ddc0bae852
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 36 additions and 22 deletions

View File

@ -8,11 +8,24 @@ jobs:
deploy: deploy:
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- uses: actions/checkout@v2 - uses: actions/checkout@v3
- uses: actions/setup-python@v2 - uses: actions/setup-python@v4
with: with:
python-version: 3.x python-version: 3.x
- run: pip install mkdocs-material==7.2.5 - run: echo "cache_id=$(date --utc '+%V')" >> $GITHUB_ENV
- uses: actions/cache@v3
with:
key: mkdocs-material-${{ env.cache_id }}
path: .cache
restore-keys: |
mkdocs-material-
- run: pip install mkdocs-material==9.1.18
- run: pip install mike
- run: mkdocs --version - run: mkdocs --version
- run: pip show mkdocs-material - run: pip show mkdocs-material
- run: mkdocs gh-deploy --force - run: git config --global user.name "${GITHUB_ACTOR}"
- run: git config --get user.name
- run: git config --global user.email "${GITHUB_ACTOR}@users.noreply.github.com"
- run: git pull origin gh-pages -r
- run: mike set-default main
- run: mike deploy --push --update-aliases main latest

View File

@ -29,9 +29,9 @@
margin-top: 50px; margin-top: 50px;
} }
.md-tabs { /* .md-tabs {
box-shadow: 0 0 0.2rem rgb(0 0 0 / 10%), 0 0.2rem 0.4rem rgb(0 0 0 / 20%); box-shadow: 0 0 0.2rem rgb(0 0 0 / 10%), 0 0.2rem 0.4rem rgb(0 0 0 / 20%);
} } */
.md-nav__item--nested>.md-nav__link, .md-nav__item a { .md-nav__item--nested>.md-nav__link, .md-nav__item a {
color: var(--nav-item-color); color: var(--nav-item-color);
@ -53,9 +53,13 @@
border-right: 1px solid #ebedf1; border-right: 1px solid #ebedf1;
} }
.md-nav__item--section>.md-nav__link[for] {
color: #000;
}
.md-nav__item--nested > .md-nav__link{ .md-nav__item--nested > .md-nav__link{
font-size: 0.8rem; font-size: 0.8rem;
font-weight: 500; font-weight: 600;
} }
.md-sidebar--primary .md-nav__item .md-nav__link--active { .md-sidebar--primary .md-nav__item .md-nav__link--active {
@ -78,12 +82,6 @@
padding-left: 3rem; padding-left: 3rem;
} }
/* @media screen and (min-width: 76.25em) {
.md-sidebar--primary:not([hidden])~.md-content>.md-content__inner{
margin-left: 1.6rem;
}
} */
.md-tabs__link { .md-tabs__link {
font-weight: 450; font-weight: 450;
font-size: 0.77rem; font-size: 0.77rem;

View File

@ -32,6 +32,7 @@ theme:
- navigation.tracking - navigation.tracking
- navigation.tabs.sticky - navigation.tabs.sticky
- navigation.top - navigation.top
- content.code.copy
# palette: # palette:
# - scheme: default # - scheme: default
@ -88,6 +89,9 @@ markdown_extensions:
copyright: Copyright © 2022 Loggie.io copyright: Copyright © 2022 Loggie.io
extra: extra:
version:
provider: mike
social: social:
- icon: fontawesome/brands/github - icon: fontawesome/brands/github
link: https://github.com/loggie-io link: https://github.com/loggie-io

View File

@ -19,15 +19,14 @@
display: none; display: none;
} }
@media screen and (min-width: 60em) { .md-sidebar--primary {
.md-sidebar--secondary { display: none !important;
display: none;
}
} }
@media screen and (min-width: 76.25em) { .md-sidebar--secondary {
.md-sidebar--primary { display: none !important;
display: none; }
} .md-content__inner {
margin-right: 0 !important;
} }
@keyframes continuousgradient { @keyframes continuousgradient {
@ -247,7 +246,7 @@ body {
} }
.features-container ul{ .features-container ul{
display: flex; display: flex !important;
flex-wrap: wrap; flex-wrap: wrap;
margin: 0 auto; margin: 0 auto;
} }