Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
xsf0105 committed Mar 28, 2024
1 parent 04f379c commit c100907
Show file tree
Hide file tree
Showing 5 changed files with 125 additions and 174 deletions.
48 changes: 24 additions & 24 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@
"push2GithubWebsite": "node ./scripts/push2GithubWebsite"
},
"dependencies": {
"quark-doc-header": "^2.0.27",
"quark-doc-home": "^2.0.27",
"quark-doc-header": "^2.0.31",
"quark-doc-home": "^2.0.32",
"quarkd": "^1.0.2",
"sass": "~1.32.0",
"vue-i18n": "^9.1.10",
Expand Down
227 changes: 96 additions & 131 deletions src/assets/styles/theme.scss → src/assets/styles/theme.css
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@

/* light mode theme */
:root {
--font-family-base: "Inter var", "Inter", ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Helvetica, Arial, "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";
--font-family-mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
Expand Down Expand Up @@ -34,31 +35,17 @@
font-family: var(--font-family-base);
}

.nav-item .nav-active {
color: var(--brand-color);
}

.action .why-quark {
background-color: var(--main-bg);
color: #000;
&:hover {
background-color: #f6f6f6;
}
}

.nav-item a {
color: var(--text-font-color-light);
font-family: var(--font-family-base);
}
.nav-item a:hover {
color: var(--brand-color);
}
.social-links a,
.translate-lang a {
.social-links a {
color: rgba(60, 60, 67, .7);
}
.social-links a:hover svg,
.translate-lang a:hover svg{
.social-links a:hover svg {
color: rgba(60, 60, 67, .92);
transition: color .25s;
}
Expand Down Expand Up @@ -108,18 +95,20 @@
}

.doc-content-document ul li,
.doc-content-document ol li,{
.doc-content-document ol li {
color: var(--text-font-color);
}


/* dark mode theme */
html.dark {
--link-font-color-dark: rgba(255, 255, 255, 0.87);
--main-bg: #23272f;
--text-font-color: rgba(255, 255, 255, 0.87);
--header-bg-light: #fff;

--text-font-color-light: rgba(255, 255, 255, 0.5);
/* --text-font-color-light: rgba(255, 255, 255, 0.87); */

--text-code-font-color: #c9def1;
--brand-color: #646cff;
Expand All @@ -136,122 +125,98 @@ html.dark {
--scroll-down-dark-color: var(--link-font-color-dark);
--arrow-dark-mode-icon: url('https://raw.githubusercontent.com/hellof2e/static/main/arrow-dark-mode.png');
--footer-bg: conic-gradient(from 90deg at -10% 100%, #2b303b 0deg, #2b303b 90deg, #16181d 1turn);
--logo-dark-mode: url('https://raw.githubusercontent.com/hellof2e/static/main/quarkd-logo-light-mode.png');

font-family: var(--font-family-base);
color: var(--link-font-color-dark);
background-color: var(--main-bg);
}

html.dark pre {
color: #1e1e20;
}

html.dark .paragraph {
color: var(--nav-link-color);
}

html.dark .nav-item .nav-active {
color: var(--brand-color);
}

html.dark .flyout-menu .menu-wrap {
background: var(--main-bg);
box-shadow: 0 1px 2px rgba(0, 0, 0, .04), 0 1px 2px rgba(0, 0, 0, .06);
border: 1px solid rgba(84, 84, 84, .48);
}

html.dark .flyout-menu .menu-group-title {
color: rgba(235, 235, 235, .38);
}

html.dark .flyout-menu .menu-link {
color: rgba(255, 255, 255, .87);
}
html.dark .flyout-menu .menu-link:hover {
color: #646cff;
}


html.dark .nav-item a:hover,
html.dark .nav-item button:hover {
color: rgba(255 255 255 / 1);
}
html.dark .nav-item .nav-active {
color: #fff;
}

html.dark .social-links a:hover svg{
color: #fff;
}

html.dark .doc-nav a {
color: #fff;
}
html.dark .doc-nav a:hover {
color: var(--brand-color);
}

html.dark .translations:before, .appearance:before, .social-links:before {
background-color: rgba(60, 60, 67, 0.92);
}


html.dark .doc-content-document p > code {
color: var(--text-code-font-color);
}
html.dark .doc-content-document strong {
color: var(--text-font-color);
}
html.dark .doc-content-document blockquote p {
color: #bcc0ff;
}
html.dark .doc-content-document a {
color: #9499ff;
text-decoration: underline;
}
html.dark .doc-content-document a:hover {
color: #bcc0ff;
}

pre {
color: #1e1e20;
}

.flyout-menu .menu-wrap {
background: var(--main-bg);
box-shadow: 0 1px 2px rgba(0, 0, 0, .04), 0 1px 2px rgba(0, 0, 0, .06);
border: 1px solid rgba(84, 84, 84, .48);
}

.flyout-menu .menu-group-title {
color: rgba(235, 235, 235, .38);
}

.flyout-menu .menu-link {
color: rgba(255, 255, 255, .87);
&:hover {
color: #646cff;
}
}


.nav-item a:hover,
.nav-item button:hover {
color: rgba(255 255 255 / 1);
}
.nav-item .nav-active {
color: #fff;
}

.social-links a:hover svg{
color: #fff;
}
.translate-lang:hover {
color: #fff;
}

.doc-nav a {
color: #fff;
}
.doc-nav a:hover {
color: var(--brand-color);
}

.translations:before, .appearance:before, .social-links:before {
background-color: rgba(60, 60, 67, 0.92);
}


.doc-content-document p > code {
color: var(--text-code-font-color);
}
.doc-content-document strong {
color: var(--text-font-color);
}
.doc-content-document blockquote p {
color: #bcc0ff;
}
.doc-content-document a {
color: #9499ff;
text-decoration: underline;
}
.doc-content-document a:hover {
color: #bcc0ff;
}

.doc-content-document table {
border: 1px solid #333;
}
.doc-content-document table th,
.doc-content-document table td {
border-left: 1px solid #333;
color: #fff;
}
.doc-content-document table td {
border-top: 1px solid #333;
}

.doc-content-document ul li,
.doc-content-document ol li
.doc-content-document strong {
color: var(--text-font-color);
}

.action .why-quark {
background-color: #313136;
color: #fff;
&:hover {
background-color: #2c2c30;
}
}
}





// @media screen and (min-width: 860px) {
// .doc-nav {
// display: none;
// }
// .doc-content {
// margin-left: 0!important;
// }
// }

// @media screen and (max-width: 880px) {
// .doc-nav {
// display: block;
// }
// .doc-content {
// margin-left: 260px;
// }
// }
html.dark .doc-content-document table {
border: 1px solid #333;
}
html.dark .doc-content-document table th,
html.dark .doc-content-document table td {
border-left: 1px solid #333;
color: #fff;
}
html.dark .doc-content-document table td {
border-top: 1px solid #333;
}

html.dark .doc-content-document ul li,
html.dark .doc-content-document ol li
html.dark .doc-content-document strong {
color: var(--text-font-color);
}
4 changes: 2 additions & 2 deletions src/docs_vue/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,10 @@ import "@/assets/styles/reset.scss";
import "@/assets/styles/md-style.scss";

// 主题 light or dark
import "@/assets/styles/theme.scss";
import "@/assets/styles/theme.css";

if (isMobile) {
location.replace("https://quark-design.hellobike.com/demo/demo.html#/");
location.replace("https://quark-design.hellobike.com/demo/demo.html#/");
}

const app = createApp(App);
Expand Down
Loading

0 comments on commit c100907

Please sign in to comment.