Skip to content

Commit 9b22898

Browse files
committed
feat: MBlog api doc
1 parent dc2d183 commit 9b22898

File tree

7 files changed

+313
-291
lines changed

7 files changed

+313
-291
lines changed

module/Blog/Core/MBlog.php

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,19 +7,22 @@
77
use Module\Blog\Util\BlogCategoryUtil;
88
use Module\Blog\Util\BlogTagUtil;
99

10+
1011
class MBlog
1112
{
1213
public static function categoryTree()
1314
{
1415
return BlogCategoryUtil::categoryTree();
1516
}
1617

18+
1719
public static function latestBlog($limit)
1820
{
1921
$paginateData = self::paginateBlog(0, 1, $limit);
2022
return $paginateData['records'];
2123
}
2224

25+
2326
public static function paginateBlog($categoryId, $page = 1, $pageSize = 10, $option = [])
2427
{
2528
if ($categoryId > 0) {
@@ -60,11 +63,13 @@ public static function paginateBlog($categoryId, $page = 1, $pageSize = 10, $opt
6063
];
6164
}
6265

66+
6367
public static function getCategory($categoryId)
6468
{
6569
return BlogCategoryUtil::get($categoryId);
6670
}
6771

72+
6873
public static function tags()
6974
{
7075
return BlogTagUtil::all();

public/asset/theme/default/style.css

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

vendor/modstart/modstart/asset/theme/default/style.css

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

vendor/modstart/modstart/resources/asset/src/sui/base/theme.less

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,3 +66,14 @@
6666

6767
--container-width: var(--theme-container-width, 55rem);
6868
}
69+
70+
[data-theme="dark"] {
71+
&:root, page, & {
72+
--color-body-bg: #151728 !important;
73+
--color-content-bg: #1b1e32 !important;
74+
--color-body-line: #1b1e32 !important;
75+
--color-text: #80859f !important;
76+
--color-input-bg: #1b1e32 !important;
77+
--color-muted: #80859f !important;
78+
}
79+
}

vendor/modstart/modstart/resources/asset/src/sui/bricks/component/header/header.less

Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -859,8 +859,8 @@
859859

860860
.ub-header-c {
861861
height: 3rem;
862-
border-bottom: 0.05rem solid #EEE;
863-
background: #FFF;
862+
border-bottom: 0.05rem solid var(--color-body-line);
863+
background: var(--color-content-bg);
864864
overflow: hidden;
865865
position: fixed;
866866
text-align: center;
@@ -899,8 +899,9 @@
899899
padding: 0.2rem 0.5rem 0.2rem 0.75rem;
900900
width: 30%;
901901
max-width: 30em;
902-
border: 1px solid var(--color-primary);
902+
border: 1px solid var(--color-body-line);
903903
position: relative;
904+
background-color: var(--color-body-bg);
904905

905906
.input {
906907
height: 1.5rem;
@@ -914,20 +915,21 @@
914915

915916
.submit {
916917
position: absolute;
917-
right: -1px;
918-
top: -1px;
919-
height: 2rem;
918+
right: 0px;
919+
top: 0px;
920+
height: 1.9rem;
920921
border: none;
921922
outline: none;
922923
font-size: 0.7rem;
923-
color: #FFF;
924+
color: var(--color-text);
924925
cursor: pointer;
925-
background: var(--color-primary);
926+
background: var(--color-body-bg);
926927
border-radius: 0 1rem 1rem 0;
927928
padding: 0 0.6rem 0 0.5rem;
928929

929930
&:hover {
930-
background: var(--color-primary-dark);
931+
background: var(--color-body-bg);
932+
color: var(--color-primary);
931933
}
932934
}
933935
}
@@ -955,7 +957,7 @@
955957

956958
.item-icon {
957959
vertical-align: middle;
958-
color: #333;
960+
color: var(--color-text);
959961
display: inline-block;
960962
padding: 0 0.6rem;
961963
margin-top: -0.2rem;

0 commit comments

Comments
 (0)