Merge branch 'next' into doc-demand
This commit is contained in:
@@ -14,30 +14,21 @@
|
||||
"vue-router": "^4.0.12",
|
||||
"vue-i18n": "^9.2.0-beta.34",
|
||||
"@vueuse/core": "^8.3.0",
|
||||
"pinia": "^2.0.9",
|
||||
"pinia": "^2.0.14",
|
||||
"pinia-plugin-persist": "^1.0.0"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@babel/core": "^7.15.8",
|
||||
"@babel/preset-env": "^7.15.8",
|
||||
"@babel/preset-typescript": "^7.15.0",
|
||||
"@rollup/plugin-babel": "^5.3.0",
|
||||
"@types/markdown-it": "^12.2.3",
|
||||
"@types/markdown-it-container": "^2.0.4",
|
||||
"@types/node": "^16.11.9",
|
||||
"@types/prettier": "^2.4.4",
|
||||
"@vitejs/plugin-vue": "^2.3.1",
|
||||
"@vue/compiler-sfc": "^3.2.33",
|
||||
"@vue/server-renderer": "^3.2.33",
|
||||
"escape-html": "^1.0.3",
|
||||
"less": "^4.1.2",
|
||||
"markdown-it-container": "^3.0.0",
|
||||
"prismjs": "^1.25.0",
|
||||
"prismjs": "^1.28.0",
|
||||
"rimraf": "^3.0.2",
|
||||
"rollup": "^2.70.1",
|
||||
"typescript": "^4.6.3",
|
||||
"vite": "2.9.8",
|
||||
"vite-plugin-md": "^0.12.4",
|
||||
"vite-plugin-md": "^0.13.4",
|
||||
"unplugin-auto-import": "^0.7.1",
|
||||
"unplugin-vue-components": "^0.19.3",
|
||||
"unplugin-layui-vue-resolver": "0.0.10"
|
||||
|
||||
@@ -1,20 +1,16 @@
|
||||
code {
|
||||
margin: 0;
|
||||
border-radius: 3px;
|
||||
padding: 0.25rem 0.5rem;
|
||||
font-size: 0.85em;
|
||||
color: var(--c-text-light);
|
||||
border-radius: 3px;
|
||||
background-color: rgba(27, 31, 35, 0.05);
|
||||
font-family: Menlo, Monaco, Consolas, "Courier New", monospace;
|
||||
font-size: 0.85em;
|
||||
}
|
||||
|
||||
code .token.deleted {
|
||||
color: #ec5975;
|
||||
}
|
||||
|
||||
code .token.inserted {
|
||||
color: var(--c-brand);
|
||||
}
|
||||
|
||||
div[class*='language-'] {
|
||||
position: relative;
|
||||
margin: 1rem -1.5rem;
|
||||
@@ -77,58 +73,11 @@ li > div[class*='language-'] {
|
||||
|
||||
[class*='language-'] code {
|
||||
padding: 0;
|
||||
line-height: 24px;
|
||||
font-size: 14px;
|
||||
color: #000;
|
||||
color: #303133;
|
||||
background-color: #fafafa;
|
||||
}
|
||||
|
||||
/* Line highlighting */
|
||||
.highlight-lines {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
bottom: 0;
|
||||
left: 0;
|
||||
padding: 1.25rem 0;
|
||||
width: 100%;
|
||||
line-height: 24px;
|
||||
letter-spacing: 0.5px;
|
||||
line-height: 23px;
|
||||
font-size: 14px;
|
||||
user-select: none;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.highlight-lines .highlighted {
|
||||
background-color: rgba(0, 0, 0, 0.66);
|
||||
}
|
||||
|
||||
/* Line numbers mode */
|
||||
div[class*='language-'].line-numbers-mode {
|
||||
padding-left: 3.5rem;
|
||||
}
|
||||
|
||||
.line-numbers-wrapper {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
bottom: 0;
|
||||
left: 0;
|
||||
z-index: 3;
|
||||
border-right: 1px solid rgba(0, 0, 0, 0.5);
|
||||
padding: 1.25rem 0;
|
||||
width: 3.5rem;
|
||||
text-align: center;
|
||||
line-height: 24px;
|
||||
font-size: 14px;
|
||||
color: #888;
|
||||
}
|
||||
|
||||
/* Language marker */
|
||||
[class*='language-']:before {
|
||||
position: absolute;
|
||||
top: 0.6em;
|
||||
right: 1em;
|
||||
z-index: 2;
|
||||
font-size: 0.8rem;
|
||||
color: #888;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -163,14 +112,14 @@ div[class*='language-'].line-numbers-mode {
|
||||
.token.boolean,
|
||||
.token.number,
|
||||
.token.function {
|
||||
color: #f08d49;
|
||||
color: #f5871f;
|
||||
}
|
||||
|
||||
.token.property,
|
||||
.token.class-name,
|
||||
.token.constant,
|
||||
.token.symbol {
|
||||
color: #f8c555;
|
||||
color: #f5871f;
|
||||
}
|
||||
|
||||
.token.selector,
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
<i
|
||||
class="layui-icon layui-icon-play btn"
|
||||
@click="onPlayground"
|
||||
title="在 Playground 中打开"
|
||||
title="运行代码"
|
||||
/>
|
||||
<i
|
||||
class="layui-icon layui-icon-file btn"
|
||||
@@ -137,12 +137,8 @@ function handleScroll() {
|
||||
margin: 1rem 0;
|
||||
border: 1px solid whitesmoke;
|
||||
border-radius: 3px;
|
||||
background: var(--c-bg);
|
||||
transition: all 0.2s;
|
||||
}
|
||||
.lay-code:hover {
|
||||
box-shadow: var(--shadow-2);
|
||||
}
|
||||
.lay-code .source {
|
||||
padding: 24px;
|
||||
padding-bottom: 15px;
|
||||
@@ -150,7 +146,6 @@ function handleScroll() {
|
||||
.lay-code .meta {
|
||||
padding: 0 10px;
|
||||
height: 0;
|
||||
background-color: var(--c-page-background);
|
||||
overflow: hidden;
|
||||
transition: height 0.2s;
|
||||
}
|
||||
@@ -160,10 +155,8 @@ function handleScroll() {
|
||||
margin-bottom: 0px;
|
||||
border: 1px solid whitesmoke;
|
||||
box-sizing: border-box;
|
||||
background: var(--c-bg);
|
||||
font-size: 14px;
|
||||
line-height: 22px;
|
||||
color: var(--c-text-light-1);
|
||||
word-break: break-word;
|
||||
}
|
||||
.lay-code .source .description p {
|
||||
@@ -179,9 +172,7 @@ function handleScroll() {
|
||||
background-color: rgba(27, 31, 35, 0.05);
|
||||
font-size: 12px;
|
||||
line-height: 18px;
|
||||
color: var(--c-text-light);
|
||||
}
|
||||
|
||||
.lay-code .control {
|
||||
height: 44px;
|
||||
box-sizing: border-box;
|
||||
@@ -189,9 +180,8 @@ function handleScroll() {
|
||||
border-top: 1px solid whitesmoke;
|
||||
border-bottom-left-radius: 4px;
|
||||
border-bottom-right-radius: 4px;
|
||||
background: var(--c-bg);
|
||||
background-color: white;
|
||||
text-align: center;
|
||||
color: var(--c-text);
|
||||
cursor: pointer;
|
||||
width: 100%;
|
||||
user-select: none;
|
||||
@@ -201,10 +191,6 @@ function handleScroll() {
|
||||
z-index: 11;
|
||||
bottom: 0;
|
||||
}
|
||||
.lay-code .control:hover {
|
||||
background-color: var(--c-page-background);
|
||||
color: var(--c-brand);
|
||||
}
|
||||
.lay-code .control > i {
|
||||
display: inline-block;
|
||||
font-size: 16px;
|
||||
|
||||
@@ -22,12 +22,10 @@ onMounted(() => {
|
||||
outline: none;
|
||||
box-shadow: none;
|
||||
}
|
||||
|
||||
.DocSearch-Button .DocSearch-Search-Icon,
|
||||
.DocSearch-Button-Placeholder {
|
||||
color: whitesmoke;
|
||||
}
|
||||
|
||||
:root {
|
||||
--docsearch-logo-color: var(--global-primary-color);
|
||||
--docsearch-primary-color: var(--global-primary-color);
|
||||
@@ -43,11 +41,9 @@ onMounted(() => {
|
||||
.DocSearch-Button-Container {
|
||||
padding-left: 2px;
|
||||
}
|
||||
|
||||
.DocSearch-Button-Placeholder {
|
||||
padding-left: 8px;
|
||||
}
|
||||
|
||||
.DocSearch-Button,
|
||||
.DocSearch-Button:hover,
|
||||
.DocSearch-Button:active,
|
||||
@@ -55,18 +51,15 @@ onMounted(() => {
|
||||
border: 1px solid rgb(224, 224, 230);
|
||||
box-shadow: none;
|
||||
}
|
||||
|
||||
.DocSearch-Button-Key {
|
||||
border: 1px solid rgba(60, 60, 60, 0.29);
|
||||
background: transparent;
|
||||
box-shadow: none;
|
||||
}
|
||||
|
||||
.DocSearch-Button .DocSearch-Search-Icon,
|
||||
.DocSearch-Button-Placeholder {
|
||||
color: rgba(0, 0, 0, 0.6);
|
||||
}
|
||||
|
||||
.DocSearch-Button-Keys {
|
||||
display: none;
|
||||
}
|
||||
|
||||
@@ -20,9 +20,9 @@
|
||||
font-size: 14px;
|
||||
width: 50px;
|
||||
max-width: 180px;
|
||||
height: 50px; /*统一每一行的默认高度*/
|
||||
border-top: 1px solid whitesmoke; /*内部边框样式*/
|
||||
padding: 0 10px; /*内边距*/
|
||||
height: 50px;
|
||||
border-top: 1px solid whitesmoke;
|
||||
padding: 0 10px;
|
||||
padding-left: 28px;
|
||||
}
|
||||
.lay-table-box table th {
|
||||
|
||||
@@ -148,12 +148,12 @@ export default {
|
||||
::: demo 使用 `radius` 属性,创建圆角按钮
|
||||
|
||||
<template>
|
||||
<lay-button type="primary" radius>原始按钮</lay-button>
|
||||
<lay-button type="default" radius>默认按钮</lay-button>
|
||||
<lay-button type="normal" radius>百搭按钮</lay-button>
|
||||
<lay-button type="warm" radius>暖色按钮</lay-button>
|
||||
<lay-button type="danger" radius>警告按钮</lay-button>
|
||||
<lay-button disabled radius>禁用按钮</lay-button>
|
||||
<lay-button type="primary" radius="true">原始按钮</lay-button>
|
||||
<lay-button type="default" radius="true">默认按钮</lay-button>
|
||||
<lay-button type="normal" radius="true">百搭按钮</lay-button>
|
||||
<lay-button type="warm" radius="true">暖色按钮</lay-button>
|
||||
<lay-button type="danger" radius="true">警告按钮</lay-button>
|
||||
<lay-button disabled radius="true">禁用按钮</lay-button>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
|
||||
@@ -201,9 +201,10 @@ export default {
|
||||
|
||||
::: table
|
||||
|
||||
| 属性 | 描述 | 可选值 |
|
||||
| ----- | ---- | ------ |
|
||||
| title | 标题 | -- |
|
||||
| 属性 | 描述 | 类型 | 可选值 | 可选值 |
|
||||
| ----- | ---- | ------ | ----- | ----- |
|
||||
| title | 标题 | `string` | -- | -- |
|
||||
| shadow | 阴影 | `string` | `always` | `always` `hover` `never` |
|
||||
|
||||
:::
|
||||
|
||||
|
||||
@@ -13,7 +13,6 @@
|
||||
::: demo 使用 `lay-input` 标签, 创建输入框
|
||||
|
||||
<template>
|
||||
{{ data1 }}
|
||||
<lay-input v-model="data1"></lay-input>
|
||||
</template>
|
||||
|
||||
|
||||
@@ -483,13 +483,13 @@ export default {
|
||||
|
||||
:::
|
||||
|
||||
::: title 层级缩进
|
||||
::: title 扩展图标
|
||||
:::
|
||||
|
||||
::: demo
|
||||
|
||||
<template>
|
||||
<lay-menu v-model:selectedKey="selectedKey" v-model:openKeys="openKeys7" :child-spacing="childSpacing" v-model:tree="isTree">
|
||||
<lay-menu v-model:selectedKey="selectedKey" v-model:openKeys="openKeys7" v-model:tree="isTree">
|
||||
<lay-menu-item id="1">
|
||||
<router-link to="">
|
||||
<lay-icon type="layui-icon-home"></lay-icon>
|
||||
@@ -503,6 +503,9 @@ export default {
|
||||
目录
|
||||
</router-link>
|
||||
</template>
|
||||
<template v-slot:expandIcon={isExpand}>
|
||||
{{isExpand}}
|
||||
</template>
|
||||
<lay-menu-item id="8">
|
||||
<router-link to="">
|
||||
<lay-icon type="layui-icon-home"></lay-icon>
|
||||
@@ -526,15 +529,13 @@ export default {
|
||||
setup() {
|
||||
|
||||
const isTree = ref(true)
|
||||
const selectedKey = ref("5")
|
||||
const openKeys7 = ref(["7"])
|
||||
const childSpacing = ref(true);
|
||||
const selectedKey = ref("5")
|
||||
|
||||
return {
|
||||
isTree,
|
||||
openKeys7,
|
||||
selectedKey,
|
||||
childSpacing
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -590,6 +591,7 @@ export default {
|
||||
| 插槽 | 描述 | 备注 |
|
||||
| ----- | -------- | ---- |
|
||||
| title | 菜单标题 | -- |
|
||||
| expandIcon | 扩展图标 | -- |
|
||||
|
||||
:::
|
||||
|
||||
|
||||
@@ -274,8 +274,8 @@ export default {
|
||||
]
|
||||
|
||||
const dataSource5 = [
|
||||
{id:"1", username:"root", password:"root", age:"18"},
|
||||
{id:"2", username:"woow", password:"woow", age:"20"}
|
||||
{id:"1", username:"root", age:"18"},
|
||||
{id:"2", username:"woow", age:"20"}
|
||||
]
|
||||
|
||||
const rowClick5 = function(data) {
|
||||
|
||||
@@ -11,6 +11,18 @@
|
||||
<template>
|
||||
<lay-timeline>
|
||||
<lay-timeline-item title="1.0.x">
|
||||
<ul>
|
||||
<a name="1-0-8"></a>
|
||||
<li>
|
||||
<h3>1.0.8 <span class="layui-badge-rim">2022-05-11</span></h3>
|
||||
<ul>
|
||||
<li>[重构] table 组件 columns 渲染。</li>
|
||||
<li>[新增] sub-menu 组件 expandIcon 插槽。</li>
|
||||
<li>[修复] table 组件 datasource 缺失属性 column 错位。</li>
|
||||
<li>[修复] fullscreen 组件按 F11 进入全屏, 退出全屏不生效。</li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
<ul>
|
||||
<a name="1-0-7"></a>
|
||||
<li>
|
||||
|
||||
@@ -43,7 +43,7 @@
|
||||
<lay-card>
|
||||
<lay-row>
|
||||
<lay-col md="2">
|
||||
<lay-avatar src="https://portrait.gitee.com/uploads/avatars/user/702/2106738_wanglin300_1639442830.png!avatar200"></lay-avatar>
|
||||
<lay-avatar src="https://portrait.gitee.com/uploads/avatars/user/702/2106738_wanglin300_1639442830.png"></lay-avatar>
|
||||
</lay-col>
|
||||
<lay-col md="3">
|
||||
halo
|
||||
@@ -103,7 +103,7 @@
|
||||
<lay-card>
|
||||
<lay-row>
|
||||
<lay-col md="2">
|
||||
<lay-avatar src="https://portrait.gitee.com/uploads/avatars/user/2596/7789823_finalsummer_1613993823.png!avatar200"></lay-avatar>
|
||||
<lay-avatar src="https://portrait.gitee.com/uploads/avatars/user/2596/7789823_finalsummer_1613993823.png"></lay-avatar>
|
||||
</lay-col>
|
||||
<lay-col md="3">
|
||||
finalsummer
|
||||
|
||||
@@ -131,7 +131,6 @@ export default {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return `
|
||||
<lay-code>
|
||||
${description ? `<template #description>${descTemplate}</template>` : ""}
|
||||
|
||||
@@ -31,14 +31,13 @@ export const usePlayGround = async (
|
||||
code = decodeCode.replace(
|
||||
scriptRe,
|
||||
`<script lang="ts" setup>$1
|
||||
</script>`
|
||||
</script>`
|
||||
);
|
||||
} else {
|
||||
code = `${decodeCode}
|
||||
<script lang="ts" setup>
|
||||
<script lang="ts" setup>
|
||||
|
||||
</script>
|
||||
`;
|
||||
</script>`;
|
||||
}
|
||||
|
||||
// 去除 export default,保留其中的内容
|
||||
|
||||
Reference in New Issue
Block a user