Skip to content

Commit

Permalink
fix(vue-renderless): [date-picker,dept,dialog-box,dialog-select,direc…
Browse files Browse the repository at this point in the history
…tives,divider,drawer,drop-roles,drop-times,dropdown] fix site: Optimize site documentation typesetting
  • Loading branch information
dufu1991 committed Dec 27, 2024
1 parent e85129a commit d1afe7f
Show file tree
Hide file tree
Showing 87 changed files with 344 additions and 344 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<tiny-date-picker v-model="value" :default-value="defaultDate"></tiny-date-picker>
</div>
<br />
<p>日期时间(范围),选择日期之后默认显示的时间(范围):</p>
<p>日期时间 (范围),选择日期之后默认显示的时间 (范围):</p>
<div class="demo-date-picker-wrap">
<tiny-date-picker v-model="dateTimeValue" type="datetime" :default-time="defaultTime"></tiny-date-picker>
<tiny-date-picker
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ test('[DatePicker] 测试选择器打开时默认时间设置', async ({ page })
await expect(page.getByRole('button', { name: '2000 年' })).toBeVisible()
await expect(page.getByRole('button', { name: '11 月' })).toBeVisible()

// default-time: 日期时间(范围),选择日期之后默认显示的时间(范围)
// default-time: 日期时间 (范围),选择日期之后默认显示的时间 (范围)
const dateInputDefaultTime = page.getByRole('textbox').nth(2)
await dateInputDefaultTime.fill('2023-05-20 09:00:00')
await dateInputDefaultTime.press('Enter')
Expand Down
2 changes: 1 addition & 1 deletion examples/sites/demos/pc/app/date-picker/default-value.vue
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<tiny-date-picker v-model="value" :default-value="defaultDate"></tiny-date-picker>
</div>
<br />
<p>日期时间(范围),选择日期之后默认显示的时间(范围):</p>
<p>日期时间 (范围),选择日期之后默认显示的时间 (范围):</p>
<div class="demo-date-picker-wrap">
<tiny-date-picker v-model="dateTimeValue" type="datetime" :default-time="defaultTime"></tiny-date-picker>
<tiny-date-picker
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -136,11 +136,11 @@ const pickerOptionsMonthRange = {
const pickerOptionsStartFrom = {
shortcuts: [
{
text: '某日起始', // text可以自定义
text: '某日起始', // text 可以自定义
type: 'startFrom'
},
{
text: '某日为止', // text可以自定义
text: '某日为止', // text 可以自定义
type: 'endAt'
},
{
Expand Down
4 changes: 2 additions & 2 deletions examples/sites/demos/pc/app/date-picker/shortcuts.vue
Original file line number Diff line number Diff line change
Expand Up @@ -137,11 +137,11 @@ export default {
pickerOptionsStartFrom: {
shortcuts: [
{
text: '某日起始', // text可以自定义
text: '某日起始', // text 可以自定义
type: 'startFrom'
},
{
text: '某日为止', // text可以自定义
text: '某日为止', // text 可以自定义
type: 'endAt'
},
{
Expand Down
4 changes: 2 additions & 2 deletions examples/sites/demos/pc/app/date-picker/webdoc/date-picker.js
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ export default {
},
desc: {
'zh-CN':
'\n <p>通过设置 <code>show-week-number</code> 属性为 <code>true</code> 显示周次序号,通过<code>format-weeks</code>属性设置周次显示格式,<code>format-weeks</code>函数有两个参数:</p>\n <ul>\n <li>customWeeks:自定义周次的序号</li>\n <li>weekFirstDays:获取每周次中的首个日期</li>\n </ul>\n <p>通过 <code>picker-options</code> 的 <code> firstDayOfWeek </code> 属性来设置每周的第一天是星期几,默认值是7,也就是星期天。</p>\n ',
'\n <p>通过设置 <code>show-week-number</code> 属性为 <code>true</code> 显示周次序号,通过<code>format-weeks</code>属性设置周次显示格式,<code>format-weeks</code>函数有两个参数:</p>\n <ul>\n <li>customWeeks:自定义周次的序号</li>\n <li>weekFirstDays:获取每周次中的首个日期</li>\n </ul>\n <p>通过 <code>picker-options</code> 的 <code> firstDayOfWeek </code> 属性来设置每周的第一天是星期几,默认值是 7,也就是星期天。</p>\n ',
'en-US':
'\n <p>Display the original weekly sequence number through the <code> show-week-number </code> attribute, and pass in two parameters through the <code> format-weeks </code> attribute.</p>\n <p>The parameters are set as follows: </p>\n <ul><li>customWeeks: set the sequence number of the custom week</li><li>weekFirstDays: get the first date of each week</li></ul>\n <p>Set the day of the week on the first day of the week through the <code> firstDayOfWeek </code> property of <code> picker-options </code>. The default value is 7, which is Sunday.</p>\n '
},
Expand Down Expand Up @@ -212,7 +212,7 @@ export default {
},
desc: {
'zh-CN':
'<p>范围选择时,默认情况下,在开始日期面板中单击上一月或上一年箭头图标时,结束日期面板中日期也联动切换到上一月或上一年。在结束日期面板中切换下一月或下一年时,开始日期面板也随之联动。但若配置 <code>unlink-panels</code> 属性为 true ,面板之间就不再联动,切换年月时只对当前面板生效。</p>\n',
'<p>范围选择时,默认情况下,在开始日期面板中单击上一月或上一年箭头图标时,结束日期面板中日期也联动切换到上一月或上一年。在结束日期面板中切换下一月或下一年时,开始日期面板也随之联动。但若配置 <code>unlink-panels</code> 属性为 true,面板之间就不再联动,切换年月时只对当前面板生效。</p>\n',
'en-US':
'<p><code>default-value</code> property specifies the date that is selected by default when the date picker panel opens. </p>\n'
},
Expand Down
42 changes: 21 additions & 21 deletions examples/sites/demos/pc/app/dept/custom-service-composition-api.vue
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
import { ref } from 'vue'
import { TinyDept } from '@opentiny/vue'
// mock数据
// mock 数据
const DEPT_LIST = [
{
upperCode: '000001',
Expand All @@ -22,14 +22,14 @@ const DEPT_LIST = [
coa_Combination: null,
hrCode: '022471',
dept_Code: null,
hrName: 'SZ技术',
hrName: 'SZ 技术',
coaCode: null
},
{
coa_Combination: null,
hrCode: '030055',
dept_Code: null,
hrName: 'SZ海洋网络',
hrName: 'SZ 海洋网络',
coaCode: null
},
{
Expand All @@ -43,7 +43,7 @@ const DEPT_LIST = [
coa_Combination: null,
hrCode: '022279',
dept_Code: null,
hrName: '贝托SZ',
hrName: '贝托 SZ',
coaCode: null
},
{
Expand All @@ -62,7 +62,7 @@ const DEPT_LIST = [
coa_Combination: null,
hrCode: '041963',
dept_Code: null,
hrName: 'BPIT&QM HRBP管理部',
hrName: 'BPIT&QM HRBP 管理部',
coaCode: '0021.000.0001.041963'
}
]
Expand All @@ -86,21 +86,21 @@ const DEPT_LIST = [
coa_Combination: null,
hrCode: '023338',
dept_Code: null,
hrName: '测试数据室XX',
hrName: '测试数据室 XX',
coaCode: '0021.000.0001.023338'
},
{
coa_Combination: null,
hrCode: '027425',
dept_Code: null,
hrName: '中国XX测试数据部',
hrName: '中国 XX 测试数据部',
coaCode: '0021.000.0002.027425'
},
{
coa_Combination: null,
hrCode: '023093',
dept_Code: null,
hrName: '测试数据XX管理部',
hrName: '测试数据 XX 管理部',
coaCode: '0021.000.0001.023093'
}
]
Expand All @@ -112,7 +112,7 @@ const DEPT_LIST = [
coa_Combination: null,
hrCode: '038370',
dept_Code: null,
hrName: '业务应用与XX测试数据部',
hrName: '业务应用与 XX 测试数据部',
coaCode: '0021.000.0001.038370'
},
{
Expand All @@ -126,21 +126,21 @@ const DEPT_LIST = [
coa_Combination: null,
hrCode: '023114',
dept_Code: null,
hrName: '测试数据XX人力资源部',
hrName: '测试数据 XX 人力资源部',
coaCode: '0021.000.0001.023114'
},
{
coa_Combination: null,
hrCode: '034899',
dept_Code: null,
hrName: '测试数据XX财经管理部',
hrName: '测试数据 XX 财经管理部',
coaCode: '0021.000.0001.034899'
},
{
coa_Combination: null,
hrCode: '023221',
dept_Code: null,
hrName: '测试数据XX质量与运营部',
hrName: '测试数据 XX 质量与运营部',
coaCode: '0021.000.0001.023221'
}
]
Expand All @@ -152,7 +152,7 @@ const DEPT_LIST = [
coa_Combination: null,
hrCode: '023489',
dept_Code: null,
hrName: '中央XX测试数据部',
hrName: '中央 XX 测试数据部',
coaCode: '0021.000.0001.023489'
}
]
Expand All @@ -164,7 +164,7 @@ const DEPT_LIST = [
coa_Combination: null,
hrCode: '023286',
dept_Code: null,
hrName: 'XX应用交付部',
hrName: 'XX 应用交付部',
coaCode: '0021.000.0001.023286'
}
]
Expand All @@ -176,7 +176,7 @@ const DEPT_LIST = [
coa_Combination: null,
hrCode: '022471',
dept_Code: null,
hrName: 'XX应用实施部',
hrName: 'XX 应用实施部',
coaCode: '0021.000.0001.022471'
}
]
Expand Down Expand Up @@ -204,19 +204,19 @@ function getfetchDeptByValue(searchValue) {
{
coaCode: '0021.000.0001.023475',
hrCode: '023475',
hrName: '测试数据室XX质量与运营部',
hrName: '测试数据室 XX 质量与运营部',
coaStatus: '1-有效-VALID'
},
{
coaCode: '0021.000.0001.023114',
hrCode: '023114',
hrName: '测试数据XX人力资源部',
hrName: '测试数据 XX 人力资源部',
coaStatus: '1-有效-VALID'
},
{
coaCode: '0021.000.0001.023093',
hrCode: '023093',
hrName: '测试数据XX管理部',
hrName: '测试数据 XX 管理部',
coaStatus: '1-有效-VALID'
}
])
Expand All @@ -243,19 +243,19 @@ function getfetchDept(code) {
{
coaCode: '0021.000.0001.023475',
hrCode: '023475',
hrName: '测试数据室XX质量与运营部',
hrName: '测试数据室 XX 质量与运营部',
coaStatus: '1-有效-VALID'
},
{
coaCode: '0021.000.0001.023114',
hrCode: '023114',
hrName: '测试数据XX人力资源部',
hrName: '测试数据 XX 人力资源部',
coaStatus: '1-有效-VALID'
},
{
coaCode: '0021.000.0001.023093',
hrCode: '023093',
hrName: '测试数据XX管理部',
hrName: '测试数据 XX 管理部',
coaStatus: '1-有效-VALID'
}
])
Expand Down
8 changes: 4 additions & 4 deletions examples/sites/demos/pc/app/dept/custom-service.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,24 +12,24 @@ test('自定义服务数据', async ({ page }) => {
.filter({ hasText: /^SZSZSZ$/ })
.getByRole('textbox')
.click()
await page.getByRole('listitem').filter({ hasText: 'SZ技术' }).click()
await page.getByRole('listitem').filter({ hasText: 'SZ 技术' }).click()
await page
.locator('div')
.filter({ hasText: /^XXXXXX$/ })
.getByRole('textbox')
.click()
await page.getByRole('listitem').filter({ hasText: '测试数据室XX' }).click()
await page.getByRole('listitem').filter({ hasText: '测试数据室 XX' }).click()
await page
.locator('div')
.filter({ hasText: /^XXXXXX$/ })
.getByRole('textbox')
.click()
await page.getByRole('listitem').filter({ hasText: '测试数据室XX' }).click()
await page.getByRole('listitem').filter({ hasText: '测试数据室 XX' }).click()
await page.waitForTimeout(500)
await page.getByRole('button', { name: '确定' }).click()
// await page.waitForTimeout(500)
const inputBox = page.locator('.tiny-dept .tiny-input input').first()
await expect(inputBox).toHaveValue(
'SZ技术/测试数据室XX/中央XX测试数据部/XX应用交付部/XX应用实施部/测试数据室XX/中央XX测试数据部/XX应用交付部/XX应用实施部'
'SZ 技术/测试数据室 XX/中央 XX 测试数据部/XX 应用交付部/XX 应用实施部/测试数据室 XX/中央 XX 测试数据部/XX 应用交付部/XX 应用实施部'
)
})
Loading

0 comments on commit d1afe7f

Please sign in to comment.