Skip to content

Commit

Permalink
chore: update
Browse files Browse the repository at this point in the history
  • Loading branch information
yanglbme committed Dec 19, 2024
1 parent eb709a8 commit 953cb73
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 9 deletions.
14 changes: 7 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -76,19 +76,19 @@ Markdown 文档自动即时渲染为微信图文,让你不再为微信文章
示例代码:

```js
const { file, util, okCb, errCb } = CUSTOM_ARG;
const param = new FormData();
param.append(`file`, file);
const { file, util, okCb, errCb } = CUSTOM_ARG
const param = new FormData()
param.append(`file`, file)
util.axios
.post(`http://127.0.0.1:9000/upload`, param, {
headers: { "Content-Type": `multipart/form-data` },
headers: { 'Content-Type': `multipart/form-data` },
})
.then((res) => {
okCb(res.url);
okCb(res.url)
})
.catch((err) => {
errCb(err);
});
errCb(err)
})

// 提供的可用参数:
// CUSTOM_ARG = {
Expand Down
5 changes: 3 additions & 2 deletions src/components/CodemirrorEditor/PostSlider.vue
Original file line number Diff line number Diff line change
Expand Up @@ -90,9 +90,10 @@ function delPost() {
:key="post.title"
href="#"
:class="{
'bg-primary text-primary-foreground': store.currentPostIndex === index,
'bg-primary text-primary-foreground shadow-lg border-2 border-primary': store.currentPostIndex === index,
'dark:bg-primary-dark dark:text-primary-foreground-dark dark:border-primary-dark': store.currentPostIndex === index,
}"
class="hover:bg-primary/90 hover:text-primary-foreground dark:bg-muted dark:hover:bg-muted h-8 w-full inline-flex items-center justify-start gap-2 whitespace-nowrap rounded px-2 text-sm transition-colors dark:text-white dark:hover:text-white"
class="hover:bg-primary/90 hover:text-primary-foreground dark:bg-muted dark:hover:bg-muted dark:hover:border-primary-dark h-8 w-full inline-flex items-center justify-start gap-2 whitespace-nowrap rounded px-2 text-sm transition-colors dark:text-white dark:hover:text-white"
@click="store.currentPostIndex = index"
>
<span class="line-clamp-1">{{ post.title }}</span>
Expand Down

0 comments on commit 953cb73

Please sign in to comment.