@opentiny/vue-docs 3.24.6 → 3.25.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (104) hide show
  1. package/demos/apis/button.js +15 -0
  2. package/demos/apis/calendar-view.js +3 -2
  3. package/demos/apis/chart-demo.js +1 -1
  4. package/demos/apis/chart-docs.js +1 -1
  5. package/demos/apis/chart-events.js +1 -1
  6. package/demos/apis/chart-question.js +1 -1
  7. package/demos/apis/chart.js +1 -1
  8. package/demos/apis/form.js +3 -0
  9. package/demos/apis/grid.js +76 -16
  10. package/demos/mobile-first/app/button/type.vue +1 -1
  11. package/demos/mobile-first/app/button/webdoc/button.js +2 -2
  12. package/demos/pc/app/action-menu/basic-usage-composition-api.vue +1 -1
  13. package/demos/pc/app/action-menu/basic-usage.vue +1 -1
  14. package/demos/pc/app/action-menu/card-mode-composition-api.vue +1 -1
  15. package/demos/pc/app/action-menu/card-mode.vue +1 -1
  16. package/demos/pc/app/action-menu/disabled-composition-api.vue +2 -2
  17. package/demos/pc/app/action-menu/disabled.vue +2 -2
  18. package/demos/pc/app/action-menu/events-composition-api.vue +1 -1
  19. package/demos/pc/app/action-menu/events.vue +1 -1
  20. package/demos/pc/app/action-menu/icon-composition-api.vue +2 -2
  21. package/demos/pc/app/action-menu/icon.vue +2 -2
  22. package/demos/pc/app/action-menu/max-show-num-composition-api.vue +1 -1
  23. package/demos/pc/app/action-menu/max-show-num.vue +1 -1
  24. package/demos/pc/app/action-menu/more-text-composition-api.vue +1 -1
  25. package/demos/pc/app/action-menu/more-text.vue +1 -1
  26. package/demos/pc/app/action-menu/popper-class-composition-api.vue +1 -1
  27. package/demos/pc/app/action-menu/popper-class.vue +1 -1
  28. package/demos/pc/app/action-menu/slot-item-composition-api.vue +1 -1
  29. package/demos/pc/app/action-menu/slot-item.vue +1 -1
  30. package/demos/pc/app/action-menu/spacing-composition-api.vue +1 -1
  31. package/demos/pc/app/action-menu/spacing.vue +1 -1
  32. package/demos/pc/app/action-menu/text-field-composition-api.vue +1 -1
  33. package/demos/pc/app/action-menu/text-field.spec.ts +1 -1
  34. package/demos/pc/app/action-menu/text-field.vue +1 -1
  35. package/demos/pc/app/button/icon-composition-api.vue +3 -1
  36. package/demos/pc/app/button/icon.vue +3 -1
  37. package/demos/pc/app/button/webdoc/button.js +3 -2
  38. package/demos/pc/app/calendar-view/calendar-mode-composition-api.vue +7 -1
  39. package/demos/pc/app/calendar-view/calendar-mode.spec.ts +3 -0
  40. package/demos/pc/app/calendar-view/calendar-mode.vue +7 -1
  41. package/demos/pc/app/carousel/webdoc/carousel.js +0 -18
  42. package/demos/pc/app/date-panel/custom-week.spec.ts +2 -2
  43. package/demos/pc/app/grid/base/basic-usage-composition-api.vue +1 -17
  44. package/demos/pc/app/grid/custom/column-fixed.spec.js +2 -1
  45. package/demos/pc/app/grid/custom/page-size.spec.js +1 -1
  46. package/demos/pc/app/grid/data-source/request-service.spec.js +1 -1
  47. package/demos/pc/app/grid/data-source/static-data.spec.js +1 -1
  48. package/demos/pc/app/grid/edit/scrollbar-not-blur-composition-api.vue +119 -0
  49. package/demos/pc/app/grid/edit/scrollbar-not-blur.spec.ts +28 -0
  50. package/demos/pc/app/grid/edit/scrollbar-not-blur.vue +129 -0
  51. package/demos/pc/app/grid/editor/custom-edit.spec.js +7 -2
  52. package/demos/pc/app/grid/empty/empty-data-iscenter.spec.js +1 -1
  53. package/demos/pc/app/grid/event/toolbar-button-click-event.spec.js +1 -1
  54. package/demos/pc/app/grid/expand/expand-trigger-slot-composition-api.vue +85 -0
  55. package/demos/pc/app/grid/expand/expand-trigger-slot.spec.ts +11 -0
  56. package/demos/pc/app/grid/expand/expand-trigger-slot.vue +95 -0
  57. package/demos/pc/app/grid/expand/set-row-expansion.spec.js +4 -0
  58. package/demos/pc/app/grid/filter/default-filter-composition-api.vue +6 -0
  59. package/demos/pc/app/grid/filter/default-filter.vue +6 -0
  60. package/demos/pc/app/grid/filter/default-relation.spec.js +1 -1
  61. package/demos/pc/app/grid/filter/server-filter.spec.js +1 -1
  62. package/demos/pc/app/grid/fixed/right-fixed-composition-api.vue +4 -4
  63. package/demos/pc/app/grid/fixed/right-fixed.vue +4 -4
  64. package/demos/pc/app/grid/footer/footer-summation-empty.spec.js +0 -1
  65. package/demos/pc/app/grid/large-data/full-data-loading.spec.js +10 -3
  66. package/demos/pc/app/grid/large-data/virtual-rolling.spec.js +9 -2
  67. package/demos/pc/app/grid/mouse-keyboard/keyboard-navigation.spec.js +4 -1
  68. package/demos/pc/app/grid/renderer/inner-renderer-date-composition-api.vue +4 -3
  69. package/demos/pc/app/grid/renderer/inner-renderer-date.spec.js +2 -2
  70. package/demos/pc/app/grid/renderer/inner-renderer-date.vue +3 -3
  71. package/demos/pc/app/grid/renderer/inner-renderer.spec.js +4 -0
  72. package/demos/pc/app/grid/size/max-min-grid-height.spec.js +2 -2
  73. package/demos/pc/app/grid/sort/combinations-sort.spec.js +2 -2
  74. package/demos/pc/app/grid/webdoc/grid-edit.js +12 -0
  75. package/demos/pc/app/grid/webdoc/grid-empty.js +1 -1
  76. package/demos/pc/app/grid/webdoc/grid-expand.js +11 -0
  77. package/demos/pc/app/icon/iconGroups.js +1 -0
  78. package/demos/pc/app/popeditor/conditions.spec.ts +1 -1
  79. package/demos/pc/app/select/nest-grid-remote.spec.ts +3 -3
  80. package/demos/pc/app/select/nest-grid.spec.ts +1 -1
  81. package/demos/pc/app/select/nest-radio-grid-much-data.spec.ts +5 -7
  82. package/demos/pc/webdoc/changelog-en.md +270 -197
  83. package/demos/pc/webdoc/changelog.md +82 -256
  84. package/package.json +19 -23
  85. package/playground/App.vue +2 -2
  86. package/src/App.vue +1 -18
  87. package/src/components/float-settings.vue +0 -13
  88. package/src/composable/utils.ts +2 -162
  89. package/src/i18n/index.js +1 -2
  90. package/src/main.js +1 -10
  91. package/src/router.js +0 -12
  92. package/src/tools/appData.js +2 -11
  93. package/src/views/components-doc/common.vue +0 -6
  94. package/src/components/MessageCard.vue +0 -117
  95. package/src/components/tiny-robot-chat.vue +0 -128
  96. package/src/composable/DifyModelProvider.ts +0 -65
  97. package/src/composable/useTinyRobot.ts +0 -167
  98. package/src/views/comprehensive/Demo.vue +0 -212
  99. package/src/views/comprehensive/index.vue +0 -380
  100. package/src/views/comprehensive/products.json +0 -98
  101. package/src/views/comprehensive/types/index.ts +0 -37
  102. package/src/views/remoter/index.vue +0 -63
  103. package/src/views/remoter/sound.vue +0 -349
  104. /package/demos/pc/app/grid/expand/{expand-config.spec.js → expand-config.spec.ts} +0 -0
@@ -63,6 +63,21 @@ export default {
63
63
  pcDemo: 'dynamic-disabled',
64
64
  mfDemo: ''
65
65
  },
66
+ {
67
+ name: 'custom-style',
68
+ type: 'object',
69
+ defaultValue: '',
70
+ desc: {
71
+ 'zh-CN': '设置 custom-style 属性按钮样式',
72
+ 'en-US': 'Set the custom-style attribute to customize the button style'
73
+ },
74
+ meta: {
75
+ stable: '3.25.0'
76
+ },
77
+ mode: ['pc', 'mobile-first'],
78
+ pcDemo: 'icon',
79
+ mfDemo: 'type'
80
+ },
66
81
  {
67
82
  name: 'ghost',
68
83
  type: 'boolean',
@@ -195,9 +195,10 @@ export default {
195
195
  'en-US': 'Should the upper left button be displayed, Default Display'
196
196
  },
197
197
  meta: {
198
- stable: '3.22.0'
198
+ stable: '3.25.0'
199
199
  },
200
- mode: ['mobile-first'],
200
+ mode: ['pc', 'mobile-first'],
201
+ pcDemo: 'calendar-mode',
201
202
  mfDemo: 'calendar-mode'
202
203
  }
203
204
  ],
@@ -53,7 +53,7 @@ export default {
53
53
  {
54
54
  name: 'extend',
55
55
  typeAnchorName: 'chart#IChartProps',
56
- type: 'objcet',
56
+ type: 'object',
57
57
  defaultValue: '',
58
58
  desc: {
59
59
  'zh-CN': 'echarts 的配置项',
@@ -53,7 +53,7 @@ export default {
53
53
  {
54
54
  name: 'extend',
55
55
  typeAnchorName: 'chart#IChartProps',
56
- type: 'objcet',
56
+ type: 'object',
57
57
  defaultValue: '',
58
58
  desc: {
59
59
  'zh-CN': 'echarts 的配置项',
@@ -53,7 +53,7 @@ export default {
53
53
  {
54
54
  name: 'extend',
55
55
  typeAnchorName: 'chart#IChartProps',
56
- type: 'objcet',
56
+ type: 'object',
57
57
  defaultValue: '',
58
58
  desc: {
59
59
  'zh-CN': 'echarts 的配置项',
@@ -53,7 +53,7 @@ export default {
53
53
  {
54
54
  name: 'extend',
55
55
  typeAnchorName: 'chart#IChartProps',
56
- type: 'objcet',
56
+ type: 'object',
57
57
  defaultValue: '',
58
58
  desc: {
59
59
  'zh-CN': 'echarts 的配置项',
@@ -53,7 +53,7 @@ export default {
53
53
  {
54
54
  name: 'extend',
55
55
  typeAnchorName: 'chart#IChartProps',
56
- type: 'objcet',
56
+ type: 'object',
57
57
  defaultValue: '',
58
58
  desc: {
59
59
  'zh-CN': 'echarts 的配置项',
@@ -153,6 +153,9 @@ export default {
153
153
  name: 'overflow-title',
154
154
  type: 'boolean',
155
155
  defaultValue: 'false',
156
+ meta: {
157
+ stable: '3.15.0'
158
+ },
156
159
  desc: {
157
160
  'zh-CN': '标签超长是否显示提示',
158
161
  'en-US': 'Does the label display a prompt if it is too long'
@@ -57,8 +57,8 @@ export default {
57
57
  },
58
58
  {
59
59
  name: 'cell-class-name',
60
- typeAnchorName: 'IClassNameArgs',
61
- type: 'string | (args: IClassNameArgs) => string',
60
+ typeAnchorName: 'ICellClassNameArgs',
61
+ type: 'string | (args: ICellClassNameArgs) => string',
62
62
  defaultValue: '',
63
63
  desc: {
64
64
  'zh-CN': '给单元格附加 className,也可以是函数',
@@ -2008,10 +2008,10 @@ export default {
2008
2008
  },
2009
2009
  {
2010
2010
  name: 'handleFetch',
2011
- type: '() => Promise',
2011
+ type: '(code: "reload") => Promise<null>',
2012
2012
  defaultValue: '',
2013
2013
  desc: {
2014
- 'zh-CN': '触发表格的 fetch-data ',
2014
+ 'zh-CN': '触发表格的 fetch-data,当 code="reload" 时会将分支重置为 1,且清除筛选、排序等条件',
2015
2015
  'en-US': 'Trigger the fetch-data of the table'
2016
2016
  },
2017
2017
  mode: ['pc', 'mobile-first'],
@@ -2949,8 +2949,14 @@ export default {
2949
2949
  name: 'default',
2950
2950
  defaultValue: '',
2951
2951
  desc: {
2952
- 'zh-CN':
2953
- '自定义显示内容模板,作用插槽参数说明:slots.default({ $table, column, row },h),$table:表格组件对象,column:当前列配置,row:当前行数据,h:vue的渲染函数',
2952
+ 'zh-CN': `自定义显示内容模板,作用域插槽参数说明:<br/>
2953
+ slots.default({ $table, column, row, level, data, rowIndex, $rowIndex, columnIndex, $columnIndex, seq }, h),<br/>
2954
+ $table:表格组件对象,column:当前列配置,row:当前行数据,<br/>
2955
+ level:当前行在树表中的层级,data:表格数据,<br/>
2956
+ rowIndex:所有行中(包含虚拟滚动等隐藏列)下标,$rowIndex:已渲染行中的下标,<br/>
2957
+ columnIndex:所有列中(包含虚拟滚动等隐藏列)下标,$columnIndex:已渲染列中的下标,<br/>
2958
+ seq:单元格所在行的序号,$seq:已弃用,<br/>
2959
+ h:vue的渲染函数`,
2954
2960
  'en-US': 'Customized display content template'
2955
2961
  },
2956
2962
  mode: ['pc', 'mobile-first'],
@@ -2960,13 +2966,25 @@ export default {
2960
2966
  name: 'edit',
2961
2967
  defaultValue: '',
2962
2968
  desc: {
2963
- 'zh-CN':
2964
- '自定义可编辑组件模板,作用插槽参数说明:slots.edit({ $table, column, row },h),$table:表格组件对象,column:当前列配置,row:当前行数据,h:vue的渲染函数',
2969
+ 'zh-CN': '自定义可编辑组件模板,作用域插槽参数同 <code>default</code> 插槽',
2965
2970
  'en-US': 'Customized Editable Component Template'
2966
2971
  },
2967
2972
  mode: ['pc', 'mobile-first'],
2968
2973
  pcDemo: 'grid-slot#slot-editor-slot'
2969
2974
  },
2975
+ {
2976
+ name: 'expand-trigger',
2977
+ defaultValue: '',
2978
+ meta: {
2979
+ stable: '3.25.0'
2980
+ },
2981
+ desc: {
2982
+ 'zh-CN': '自定义展开行图标,作用域插槽参数同 <code>default</code> 插槽',
2983
+ 'en-US': 'Customized expand row icon'
2984
+ },
2985
+ mode: ['pc', 'mobile-first'],
2986
+ pcDemo: 'grid-expand#expand-trigger-slot'
2987
+ },
2970
2988
  {
2971
2989
  name: 'filter',
2972
2990
  defaultValue: '',
@@ -2982,8 +3000,11 @@ export default {
2982
3000
  name: 'header',
2983
3001
  defaultValue: '',
2984
3002
  desc: {
2985
- 'zh-CN':
2986
- '自定义表头内容的模板,作用插槽参数说明:slots.header({ $table, column, columnIndex,$rowIndex},h),$table:表格组件对象,column:当前列配置,columnIndex:当前列索引,$rowIndex:当前行索引,h:vue的渲染函数',
3003
+ 'zh-CN': `自定义表头内容的模板,作用插槽参数说明:<br/>
3004
+ slots.header({ $table, column, columnIndex,$columnIndex,} ,h),<br/>
3005
+ $table:表格组件对象,column:当前列配置,<br/>
3006
+ columnIndex:所有列中(包含虚拟滚动等隐藏列)下标,$columnIndex:已渲染列中的下标,<br/>
3007
+ h:vue的渲染函数`,
2987
3008
  'en-US': 'Template of custom table header content'
2988
3009
  },
2989
3010
  mode: ['pc', 'mobile-first'],
@@ -3194,18 +3215,24 @@ interface IRow {
3194
3215
  depTypes: ['IValidRules'],
3195
3216
  code: `
3196
3217
  interface IColumnConfig {
3197
- type: 'index' | 'radio' | 'checkbox'
3218
+ // 功能列的类型, 'index'行索引,'radio' 单选行, 'selection' 多选行
3219
+ type: 'index' | 'radio' | 'selection'
3220
+ // 列id
3198
3221
  id: string
3199
- prop: string
3222
+ // 校验规则
3200
3223
  rules: IValidRules
3224
+ // 是否必填
3201
3225
  required: boolean
3202
3226
  property: string
3203
3227
  title: string
3204
- label: string
3228
+ // 列宽度
3205
3229
  width: string | number
3230
+ // 自动分配宽度时的最小宽度
3206
3231
  minWidth: string | number
3232
+ // 是否可以调整列宽
3207
3233
  resizable: boolean
3208
- fixed: boolean
3234
+ // 是否左、右冻结
3235
+ fixed: 'left' | 'right'
3209
3236
  align: 'left' | 'center' | 'right'
3210
3237
  headerAlign: 'left' | 'center' | 'right'
3211
3238
  footerAlign: 'left' | 'center' | 'right'
@@ -3475,6 +3502,8 @@ interface ITreeConfig {
3475
3502
  expandRowKeys?: string[]
3476
3503
  // 对于同一级的多个子节点,是否只能同时展开一个子节点
3477
3504
  accordion?: boolean
3505
+ // 3.25.0版本新新增,当trigger为 'default' 时,点击按钮事件是否冒泡,默认为false
3506
+ bubbling?: boolean
3478
3507
  }
3479
3508
  `
3480
3509
  },
@@ -3563,9 +3592,11 @@ interface IEditConfig {
3563
3592
  showStatus?: boolean
3564
3593
  // 自定义编辑规则,返回true可以编辑返回false则禁止编辑
3565
3594
  activeMethod?: ({row: IRow, column: IColumnConfig})=> boolean
3566
- // (3.19新增)当mode为'row'时,行编辑激活状态下默认会忽略activeMethod,配置为true使其生效
3595
+ // (3.19.0新增)当mode为'row'时,行编辑激活状态下默认会忽略activeMethod,配置为true使其生效
3567
3596
  activeStrictly?: boolean
3568
- }
3597
+ //(3.25.0新增)自定义编辑态的退出逻辑。当返回true时,不会退出编辑态。
3598
+ blurOutside?: ({ cell, event, $table }: { cell: HTMLElement, event: Event, $table: Component }) => boolean
3599
+ }
3569
3600
  `
3570
3601
  },
3571
3602
  {
@@ -4133,6 +4164,8 @@ interface IFilterConfig {
4133
4164
  // 设置枚举数据的实际值属性字段, 默认'value'
4134
4165
  value: string
4135
4166
  }[] | () => Promise
4167
+ // 3.25.0新增,设置过滤面板根节点属性
4168
+ attrs: { [props: string]: string }
4136
4169
  }
4137
4170
  `
4138
4171
  },
@@ -4153,6 +4186,33 @@ interface IFilterConfig {
4153
4186
  sortable?: Sortable
4154
4187
  }
4155
4188
  `
4189
+ },
4190
+ {
4191
+ name: 'ICellClassNameArgs',
4192
+ type: 'type',
4193
+ depTypes: ['IColumnConfig', 'IRow'],
4194
+ code: `
4195
+ interface ICellClassNameArgs {
4196
+ // 当前行在树表中的层级
4197
+ level: number
4198
+ // 当前行数据
4199
+ row: IRow
4200
+ // 表格数据
4201
+ data: IRow[]
4202
+ // 所有行中(包含虚拟滚动等隐藏列)下标
4203
+ rowIndex: number
4204
+ // 已渲染行中的下标
4205
+ $rowIndex: number
4206
+ // 表格列配置
4207
+ column: IColumnConfig
4208
+ // 所有列中(包含虚拟滚动等隐藏列)下标
4209
+ columnIndex: number
4210
+ // 已渲染列中的下标
4211
+ $columnIndex: number
4212
+ // 单元格所在行的序号
4213
+ seq: number
4214
+ $seq: string // 已弃用
4215
+ }`
4156
4216
  }
4157
4217
  ]
4158
4218
  }
@@ -4,7 +4,7 @@
4
4
  <tiny-button type="primary"> 主要按钮 </tiny-button>
5
5
  <tiny-button type="success"> 成功按钮 </tiny-button>
6
6
  <tiny-button type="info"> 信息按钮 </tiny-button>
7
- <tiny-button type="warning"> 警告按钮 </tiny-button>
7
+ <tiny-button type="warning" :custom-style="{ maxWidth: 'none' }"> 警告按钮 警告按钮警告按钮警告按钮</tiny-button>
8
8
  <tiny-button type="danger"> 危险按钮 </tiny-button>
9
9
  <tiny-button type="text"> 文本按钮 </tiny-button>
10
10
  </div>
@@ -72,9 +72,9 @@ export default {
72
72
  },
73
73
  desc: {
74
74
  'zh-CN':
75
- '<p>通过 <code>type</code> 属性可以设置不同的主题样式,主要包括 primary、success、info、warning、danger、text。<p>',
75
+ '<p>通过 <code>type</code> 属性可以设置不同的主题样式,主要包括 primary、success、info、warning、danger、text。设置 <code>custom-style</code> 属性按钮样式<p>',
76
76
  'en-US':
77
- '<p>You can use the <code>type</code> attribute to set different theme styles, including primary, success, info, warning, danger, and text.</p>'
77
+ '<p>You can use the <code>type</code> attribute to set different theme styles, including primary, success, info, warning, danger, and text. The <code>custom-style</code> property sets the button style.</p>'
78
78
  },
79
79
  codeFiles: ['type.vue']
80
80
  },
@@ -8,7 +8,7 @@ import { TinyActionMenu } from '@opentiny/vue'
8
8
 
9
9
  const options = ref([
10
10
  {
11
- label: '远程登陆'
11
+ label: '远程登录'
12
12
  },
13
13
  {
14
14
  label: '开机'
@@ -13,7 +13,7 @@ export default {
13
13
  return {
14
14
  options: [
15
15
  {
16
- label: '远程登陆'
16
+ label: '远程登录'
17
17
  },
18
18
  {
19
19
  label: '开机'
@@ -9,7 +9,7 @@ import { iconWebPlus, iconSuccessful, iconCloseSquare } from '@opentiny/vue-icon
9
9
 
10
10
  const options = ref([
11
11
  {
12
- label: '远程登陆',
12
+ label: '远程登录',
13
13
  icon: iconWebPlus()
14
14
  },
15
15
  {
@@ -14,7 +14,7 @@ export default {
14
14
  return {
15
15
  options: [
16
16
  {
17
- label: '远程登陆',
17
+ label: '远程登录',
18
18
  icon: iconWebPlus()
19
19
  },
20
20
  {
@@ -15,7 +15,7 @@ import { iconWebPlus, iconSuccessful, iconCloseSquare } from '@opentiny/vue-icon
15
15
 
16
16
  const options = ref([
17
17
  {
18
- label: '远程登陆'
18
+ label: '远程登录'
19
19
  },
20
20
  {
21
21
  label: '开机',
@@ -38,7 +38,7 @@ const options = ref([
38
38
 
39
39
  const options1 = ref([
40
40
  {
41
- label: '远程登陆',
41
+ label: '远程登录',
42
42
  icon: iconWebPlus()
43
43
  },
44
44
  {
@@ -20,7 +20,7 @@ export default {
20
20
  return {
21
21
  options: [
22
22
  {
23
- label: '远程登陆'
23
+ label: '远程登录'
24
24
  },
25
25
  {
26
26
  label: '开机',
@@ -43,7 +43,7 @@ export default {
43
43
  ],
44
44
  options1: [
45
45
  {
46
- label: '远程登陆',
46
+ label: '远程登录',
47
47
  icon: iconWebPlus()
48
48
  },
49
49
  {
@@ -15,7 +15,7 @@ import { TinyActionMenu, TinyNotify } from '@opentiny/vue'
15
15
 
16
16
  const options = ref([
17
17
  {
18
- label: '远程登陆'
18
+ label: '远程登录'
19
19
  },
20
20
  {
21
21
  label: '开机'
@@ -20,7 +20,7 @@ export default {
20
20
  return {
21
21
  options: [
22
22
  {
23
- label: '远程登陆'
23
+ label: '远程登录'
24
24
  },
25
25
  {
26
26
  label: '开机'
@@ -23,7 +23,7 @@ import { iconWebPlus, iconSuccessful, iconShutdown, iconEllipsis } from '@openti
23
23
 
24
24
  const options = ref([
25
25
  {
26
- label: '远程登陆',
26
+ label: '远程登录',
27
27
  icon: iconWebPlus()
28
28
  },
29
29
  {
@@ -45,7 +45,7 @@ const options = ref([
45
45
 
46
46
  const options1 = ref([
47
47
  {
48
- label: '远程登陆'
48
+ label: '远程登录'
49
49
  },
50
50
  {
51
51
  label: '开机'
@@ -27,7 +27,7 @@ export default {
27
27
  return {
28
28
  options: [
29
29
  {
30
- label: '远程登陆',
30
+ label: '远程登录',
31
31
  icon: iconWebPlus()
32
32
  },
33
33
  {
@@ -48,7 +48,7 @@ export default {
48
48
  ],
49
49
  options1: [
50
50
  {
51
- label: '远程登陆'
51
+ label: '远程登录'
52
52
  },
53
53
  {
54
54
  label: '开机'
@@ -8,7 +8,7 @@ import { TinyActionMenu } from '@opentiny/vue'
8
8
 
9
9
  const options = ref([
10
10
  {
11
- label: '远程登陆'
11
+ label: '远程登录'
12
12
  },
13
13
  {
14
14
  label: '开机'
@@ -13,7 +13,7 @@ export default {
13
13
  return {
14
14
  options: [
15
15
  {
16
- label: '远程登陆'
16
+ label: '远程登录'
17
17
  },
18
18
  {
19
19
  label: '开机'
@@ -8,7 +8,7 @@ import { TinyActionMenu } from '@opentiny/vue'
8
8
 
9
9
  const options = ref([
10
10
  {
11
- label: '远程登陆'
11
+ label: '远程登录'
12
12
  },
13
13
  {
14
14
  label: '开机'
@@ -13,7 +13,7 @@ export default {
13
13
  return {
14
14
  options: [
15
15
  {
16
- label: '远程登陆'
16
+ label: '远程登录'
17
17
  },
18
18
  {
19
19
  label: '开机'
@@ -8,7 +8,7 @@ import { TinyActionMenu } from '@opentiny/vue'
8
8
 
9
9
  const options = ref([
10
10
  {
11
- label: '远程登陆'
11
+ label: '远程登录'
12
12
  },
13
13
  {
14
14
  label: '开机'
@@ -13,7 +13,7 @@ export default {
13
13
  return {
14
14
  options: [
15
15
  {
16
- label: '远程登陆'
16
+ label: '远程登录'
17
17
  },
18
18
  {
19
19
  label: '开机'
@@ -14,7 +14,7 @@ import { iconSmile } from '@opentiny/vue-icon'
14
14
 
15
15
  const options = ref([
16
16
  {
17
- name: '远程登陆'
17
+ name: '远程登录'
18
18
  },
19
19
  {
20
20
  name: '开机'
@@ -20,7 +20,7 @@ export default {
20
20
  return {
21
21
  options: [
22
22
  {
23
- name: '远程登陆'
23
+ name: '远程登录'
24
24
  },
25
25
  {
26
26
  name: '开机'
@@ -12,7 +12,7 @@ import { TinyActionMenu } from '@opentiny/vue'
12
12
 
13
13
  const options = ref([
14
14
  {
15
- label: '远程登陆'
15
+ label: '远程登录'
16
16
  },
17
17
  {
18
18
  label: '开机'
@@ -17,7 +17,7 @@ export default {
17
17
  return {
18
18
  options: [
19
19
  {
20
- label: '远程登陆'
20
+ label: '远程登录'
21
21
  },
22
22
  {
23
23
  label: '开机'
@@ -8,7 +8,7 @@ import { TinyActionMenu } from '@opentiny/vue'
8
8
 
9
9
  const options = ref([
10
10
  {
11
- name: '远程登陆'
11
+ name: '远程登录'
12
12
  },
13
13
  {
14
14
  name: '开机'
@@ -8,6 +8,6 @@ test('映射字段', async ({ page }) => {
8
8
  const actionMenu = wrap.locator('.tiny-action-menu')
9
9
  const visibleItem = actionMenu.locator('.tiny-action-menu__item')
10
10
 
11
- await expect(visibleItem.first()).toHaveText('远程登陆')
11
+ await expect(visibleItem.first()).toHaveText('远程登录')
12
12
  await expect(visibleItem.nth(1)).toHaveText('开机')
13
13
  })
@@ -13,7 +13,7 @@ export default {
13
13
  return {
14
14
  options: [
15
15
  {
16
- name: '远程登陆'
16
+ name: '远程登录'
17
17
  },
18
18
  {
19
19
  name: '开机'
@@ -3,7 +3,9 @@
3
3
  <tiny-layout>
4
4
  <tiny-row>
5
5
  <tiny-button type="primary" :icon="TinyIconEdit"> 图标按钮 </tiny-button>
6
- <tiny-button :icon="TinyIconSearch"> 图标按钮 </tiny-button>
6
+ <tiny-button :icon="TinyIconSearch" :custom-style="{ maxWidth: 'none' }">
7
+ 图标按钮图标按钮图标按钮图标按钮
8
+ </tiny-button>
7
9
  <tiny-button type="success" :icon="TinyIconYes"> 图标按钮 </tiny-button>
8
10
  <tiny-button type="info" :icon="TinyIconMail"> 图标按钮 </tiny-button>
9
11
  <tiny-button type="warning" :icon="TinyIconStarO"> 图标按钮 </tiny-button>
@@ -3,7 +3,9 @@
3
3
  <tiny-layout>
4
4
  <tiny-row>
5
5
  <tiny-button type="primary" :icon="IconEdit"> 图标按钮 </tiny-button>
6
- <tiny-button :icon="IconSearch"> 图标按钮 </tiny-button>
6
+ <tiny-button :icon="IconSearch" :custom-style="{ maxWidth: 'none' }">
7
+ 图标按钮图标按钮图标按钮图标按钮
8
+ </tiny-button>
7
9
  <tiny-button type="success" :icon="IconYes"> 图标按钮 </tiny-button>
8
10
  <tiny-button type="info" :icon="IconMail"> 图标按钮 </tiny-button>
9
11
  <tiny-button type="warning" :icon="IconStarO"> 图标按钮 </tiny-button>
@@ -47,8 +47,9 @@ export default {
47
47
  'en-US': 'Icon Button'
48
48
  },
49
49
  desc: {
50
- 'zh-CN': '通过 <code>icon</code> 属性,设置按钮展示图标。',
51
- 'en-US': 'Display icons and receive an icon component through the <code>icon</code> settings button'
50
+ 'zh-CN': '通过 <code>icon</code> 属性,设置按钮展示图标。<code>custom-style</code>属性设置按钮样式。',
51
+ 'en-US':
52
+ 'Display icons and receive an icon component through the <code>icon</code> settings button. The <code>custom-style</code> property sets the button style.'
52
53
  },
53
54
  codeFiles: ['icon.vue']
54
55
  },
@@ -1,5 +1,11 @@
1
1
  <template>
2
- <tiny-calendar-view :events="eventslist" :year="2023" :month="6" :modes="['month', 'timeline', 'schedule']">
2
+ <tiny-calendar-view
3
+ :events="eventslist"
4
+ :year="2023"
5
+ :month="6"
6
+ :modes="['month', 'timeline', 'schedule']"
7
+ :show-back-today="false"
8
+ >
3
9
  </tiny-calendar-view>
4
10
  </template>
5
11
 
@@ -9,6 +9,9 @@ test('显示模式', async ({ page }) => {
9
9
  const dmonthDom = page.locator('.tiny-calendar-view-month__main')
10
10
  const timelineDom = page.locator('.tiny-calendar-view-week__timeline')
11
11
  const scheduleDom = page.locator('.tiny-calendar-view-week__schedule')
12
+
13
+ const calendarHeader = page.locator('.tiny-calendar-view__header')
14
+ await expect(calendarHeader.locator('div').first()).not.toHaveClass('.tiny-button .tiny-button--default')
12
15
  // 验证按钮是否选中,验证时间组件页面是否正确
13
16
  await expect(monthBtn.locator('.tiny-svg')).toHaveClass(/fill-brand/)
14
17
  await expect(dmonthDom).toBeVisible()
@@ -1,5 +1,11 @@
1
1
  <template>
2
- <tiny-calendar-view :events="eventslist" :year="2023" :month="6" :modes="['month', 'timeline', 'schedule']">
2
+ <tiny-calendar-view
3
+ :events="eventslist"
4
+ :year="2023"
5
+ :month="6"
6
+ :modes="['month', 'timeline', 'schedule']"
7
+ :show-back-today="false"
8
+ >
3
9
  </tiny-calendar-view>
4
10
  </template>
5
11