mdui 2.1.4 → 2.1.5
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.
- package/README.md +49 -49
- package/components/avatar/index.d.ts +2 -2
- package/components/avatar/index.js +1 -1
- package/components/badge/index.d.ts +1 -1
- package/components/badge/index.js +1 -1
- package/components/bottom-app-bar/index.d.ts +2 -2
- package/components/bottom-app-bar/index.js +2 -2
- package/components/bottom-app-bar/style.js +1 -1
- package/components/button/index.d.ts +1 -1
- package/components/button/index.js +1 -1
- package/components/button/style.js +1 -1
- package/components/button-icon/index.d.ts +1 -1
- package/components/button-icon/index.js +3 -2
- package/components/card/index.d.ts +1 -1
- package/components/card/index.js +1 -1
- package/components/checkbox/index.d.ts +4 -4
- package/components/checkbox/index.js +4 -4
- package/components/chip/index.d.ts +8 -8
- package/components/chip/index.js +8 -8
- package/components/circular-progress/index.d.ts +3 -3
- package/components/circular-progress/index.js +2 -2
- package/components/collapse/collapse-item.d.ts +1 -1
- package/components/dialog/index.d.ts +1 -1
- package/components/dialog/index.js +1 -1
- package/components/divider/index.d.ts +2 -2
- package/components/divider/index.js +2 -2
- package/components/dropdown/index.d.ts +2 -2
- package/components/dropdown/index.js +10 -3
- package/components/fab/index.d.ts +3 -3
- package/components/fab/index.js +3 -3
- package/components/layout/layout-item-base.d.ts +1 -1
- package/components/layout/layout.d.ts +1 -1
- package/components/layout/layout.js +1 -1
- package/components/linear-progress/index.d.ts +4 -4
- package/components/linear-progress/index.js +3 -3
- package/components/list/list-item.d.ts +4 -4
- package/components/list/list-item.js +4 -4
- package/components/menu/menu-item.d.ts +2 -2
- package/components/menu/menu-item.js +4 -3
- package/components/menu/menu.d.ts +2 -2
- package/components/menu/menu.js +2 -3
- package/components/navigation-bar/navigation-bar-item.d.ts +1 -1
- package/components/navigation-bar/navigation-bar-item.js +1 -1
- package/components/navigation-bar/navigation-bar-style.js +1 -1
- package/components/navigation-bar/navigation-bar.d.ts +1 -1
- package/components/navigation-bar/navigation-bar.js +1 -1
- package/components/navigation-drawer/index.d.ts +15 -15
- package/components/navigation-drawer/index.js +15 -16
- package/components/navigation-rail/navigation-rail-item.d.ts +1 -1
- package/components/navigation-rail/navigation-rail-item.js +1 -1
- package/components/navigation-rail/navigation-rail.d.ts +3 -3
- package/components/navigation-rail/navigation-rail.js +3 -4
- package/components/radio/radio-group.d.ts +1 -1
- package/components/radio/radio-group.js +1 -1
- package/components/radio/radio.d.ts +2 -2
- package/components/radio/radio.js +2 -2
- package/components/range-slider/index.d.ts +1 -1
- package/components/range-slider/index.js +1 -1
- package/components/segmented-button/segmented-button-group.d.ts +1 -1
- package/components/segmented-button/segmented-button-group.js +1 -2
- package/components/segmented-button/segmented-button.d.ts +1 -1
- package/components/segmented-button/segmented-button.js +1 -1
- package/components/select/index.d.ts +2 -2
- package/components/select/index.js +2 -2
- package/components/slider/index.d.ts +1 -1
- package/components/slider/index.js +1 -1
- package/components/snackbar/index.d.ts +2 -2
- package/components/snackbar/index.js +2 -3
- package/components/switch/index.d.ts +4 -4
- package/components/switch/index.js +4 -4
- package/components/text-field/index.d.ts +4 -4
- package/components/text-field/index.js +5 -5
- package/components/tooltip/index.d.ts +2 -2
- package/components/tooltip/index.js +3 -2
- package/components/top-app-bar/top-app-bar-style.js +1 -1
- package/components/top-app-bar/top-app-bar.d.ts +1 -1
- package/components/top-app-bar/top-app-bar.js +1 -1
- package/css-data.en.json +128 -128
- package/css-data.zh-cn.json +111 -111
- package/custom-elements.json +183 -183
- package/html-data.en.json +491 -491
- package/html-data.zh-cn.json +28 -28
- package/jsx.en.d.ts +588 -588
- package/jsx.zh-cn.d.ts +28 -28
- package/mdui.esm.js +8 -8
- package/mdui.global.js +8 -8
- package/package.json +5 -4
- package/web-types.en.json +696 -696
- package/web-types.zh-cn.json +179 -179
package/jsx.zh-cn.d.ts
CHANGED
|
@@ -22,7 +22,7 @@ declare global {
|
|
|
22
22
|
*/
|
|
23
23
|
'src'?: string;
|
|
24
24
|
/**
|
|
25
|
-
* 图片如何适应容器框,与原生的 [`object-fit`](https://developer.mozilla.org/
|
|
25
|
+
* 图片如何适应容器框,与原生的 [`object-fit`](https://developer.mozilla.org/zh-CN/docs/Web/CSS/object-fit) 属性相同。可选值包括:
|
|
26
26
|
*
|
|
27
27
|
* * `contain`:保持图片原有尺寸比例,内容会被等比例缩放
|
|
28
28
|
* * `cover`:保持图片原有尺寸比例,但部分内容可能被剪切
|
|
@@ -100,7 +100,7 @@ declare global {
|
|
|
100
100
|
*/
|
|
101
101
|
'scroll-target'?: string | HTMLElement | JQ<HTMLElement>;
|
|
102
102
|
/**
|
|
103
|
-
*
|
|
103
|
+
* 触发滚动行为所需的滚动距离,单位为 `px`
|
|
104
104
|
* @see https://www.mdui.org/zh-cn/docs/2/components/bottom-app-bar#attributes-scroll-threshold
|
|
105
105
|
*/
|
|
106
106
|
'scroll-threshold'?: number;
|
|
@@ -633,7 +633,7 @@ declare global {
|
|
|
633
633
|
*/
|
|
634
634
|
'name'?: string;
|
|
635
635
|
/**
|
|
636
|
-
*
|
|
636
|
+
* 复选框的值,将与表单数据一起提交
|
|
637
637
|
* @see https://www.mdui.org/zh-cn/docs/2/components/checkbox#attributes-value
|
|
638
638
|
*/
|
|
639
639
|
'value'?: string;
|
|
@@ -664,7 +664,7 @@ declare global {
|
|
|
664
664
|
'tabindex'?: number;
|
|
665
665
|
} & HTMLElementProps;
|
|
666
666
|
/**
|
|
667
|
-
*
|
|
667
|
+
* 标签组件
|
|
668
668
|
*
|
|
669
669
|
* ```html
|
|
670
670
|
* <mdui-chip>Chip</mdui-chip>
|
|
@@ -673,7 +673,7 @@ declare global {
|
|
|
673
673
|
*/
|
|
674
674
|
'mdui-chip': {
|
|
675
675
|
/**
|
|
676
|
-
*
|
|
676
|
+
* 标签的形状。可选值包括:
|
|
677
677
|
*
|
|
678
678
|
* * `assist`:用于显示与当前上下文相关的辅助操作,如在点餐页面提供分享、收藏等功能
|
|
679
679
|
* * `filter`:用于对内容进行筛选,如在搜索结果页过滤搜索结果
|
|
@@ -698,7 +698,7 @@ declare global {
|
|
|
698
698
|
*/
|
|
699
699
|
'selected'?: boolean;
|
|
700
700
|
/**
|
|
701
|
-
* 是否可删除。为 `true`
|
|
701
|
+
* 是否可删除。为 `true` 时,标签右侧会显示删除图标
|
|
702
702
|
* @see https://www.mdui.org/zh-cn/docs/2/components/chip#attributes-deletable
|
|
703
703
|
*/
|
|
704
704
|
'deletable'?: boolean;
|
|
@@ -883,7 +883,7 @@ declare global {
|
|
|
883
883
|
'formtarget'?: '_self' | '_blank' | '_parent' | '_top';
|
|
884
884
|
} & HTMLElementProps;
|
|
885
885
|
/**
|
|
886
|
-
*
|
|
886
|
+
* 环形进度条组件
|
|
887
887
|
*
|
|
888
888
|
* ```html
|
|
889
889
|
* <mdui-circular-progress></mdui-circular-progress>
|
|
@@ -892,12 +892,12 @@ declare global {
|
|
|
892
892
|
*/
|
|
893
893
|
'mdui-circular-progress': {
|
|
894
894
|
/**
|
|
895
|
-
*
|
|
895
|
+
* 进度条的最大值。默认为 `1`
|
|
896
896
|
* @see https://www.mdui.org/zh-cn/docs/2/components/circular-progress#attributes-max
|
|
897
897
|
*/
|
|
898
898
|
'max'?: number;
|
|
899
899
|
/**
|
|
900
|
-
*
|
|
900
|
+
* 进度条的当前值。如果未指定该值,则显示为不确定状态
|
|
901
901
|
* @see https://www.mdui.org/zh-cn/docs/2/components/circular-progress#attributes-value
|
|
902
902
|
*/
|
|
903
903
|
'value'?: number;
|
|
@@ -1016,7 +1016,7 @@ declare global {
|
|
|
1016
1016
|
'stacked-actions'?: boolean;
|
|
1017
1017
|
} & HTMLElementProps;
|
|
1018
1018
|
/**
|
|
1019
|
-
*
|
|
1019
|
+
* 分隔线组件
|
|
1020
1020
|
*
|
|
1021
1021
|
* ```html
|
|
1022
1022
|
* <mdui-divider></mdui-divider>
|
|
@@ -1025,7 +1025,7 @@ declare global {
|
|
|
1025
1025
|
*/
|
|
1026
1026
|
'mdui-divider': {
|
|
1027
1027
|
/**
|
|
1028
|
-
*
|
|
1028
|
+
* 是否为垂直分隔线
|
|
1029
1029
|
* @see https://www.mdui.org/zh-cn/docs/2/components/divider#attributes-vertical
|
|
1030
1030
|
*/
|
|
1031
1031
|
'vertical'?: boolean;
|
|
@@ -1397,7 +1397,7 @@ declare global {
|
|
|
1397
1397
|
'full-height'?: boolean;
|
|
1398
1398
|
} & HTMLElementProps;
|
|
1399
1399
|
/**
|
|
1400
|
-
*
|
|
1400
|
+
* 线性进度条组件
|
|
1401
1401
|
*
|
|
1402
1402
|
* ```html
|
|
1403
1403
|
* <mdui-linear-progress></mdui-linear-progress>
|
|
@@ -1406,12 +1406,12 @@ declare global {
|
|
|
1406
1406
|
*/
|
|
1407
1407
|
'mdui-linear-progress': {
|
|
1408
1408
|
/**
|
|
1409
|
-
*
|
|
1409
|
+
* 进度条的最大值。默认为 `1`
|
|
1410
1410
|
* @see https://www.mdui.org/zh-cn/docs/2/components/linear-progress#attributes-max
|
|
1411
1411
|
*/
|
|
1412
1412
|
'max'?: number;
|
|
1413
1413
|
/**
|
|
1414
|
-
*
|
|
1414
|
+
* 进度条的当前值。如果未指定该值,则处于不确定状态
|
|
1415
1415
|
* @see https://www.mdui.org/zh-cn/docs/2/components/linear-progress#attributes-value
|
|
1416
1416
|
*/
|
|
1417
1417
|
'value'?: number;
|
|
@@ -1879,7 +1879,7 @@ declare global {
|
|
|
1879
1879
|
*/
|
|
1880
1880
|
'scroll-target'?: string | HTMLElement | JQ<HTMLElement>;
|
|
1881
1881
|
/**
|
|
1882
|
-
*
|
|
1882
|
+
* 触发滚动行为所需的滚动距离,单位为 `px`
|
|
1883
1883
|
* @see https://www.mdui.org/zh-cn/docs/2/components/navigation-bar#navigation-bar-attributes-scroll-threshold
|
|
1884
1884
|
*/
|
|
1885
1885
|
'scroll-threshold'?: number;
|
|
@@ -1890,7 +1890,7 @@ declare global {
|
|
|
1890
1890
|
'order'?: number;
|
|
1891
1891
|
} & HTMLElementProps;
|
|
1892
1892
|
/**
|
|
1893
|
-
*
|
|
1893
|
+
* 抽屉导航栏组件
|
|
1894
1894
|
*
|
|
1895
1895
|
* ```html
|
|
1896
1896
|
* <mdui-navigation-drawer>content</mdui-navigation-drawer>
|
|
@@ -1899,29 +1899,29 @@ declare global {
|
|
|
1899
1899
|
*/
|
|
1900
1900
|
'mdui-navigation-drawer': {
|
|
1901
1901
|
/**
|
|
1902
|
-
*
|
|
1902
|
+
* 是否打开抽屉导航栏
|
|
1903
1903
|
* @see https://www.mdui.org/zh-cn/docs/2/components/navigation-drawer#attributes-open
|
|
1904
1904
|
*/
|
|
1905
1905
|
'open'?: boolean;
|
|
1906
1906
|
/**
|
|
1907
|
-
*
|
|
1907
|
+
* 抽屉导航栏打开时,是否显示遮罩层
|
|
1908
1908
|
*
|
|
1909
1909
|
* 在窄屏设备上(屏幕宽度小于 [`--mdui-breakpoint-md`](https://www.mdui.org/zh-cn/docs/2/styles/design-tokens#breakpoint)),会始终显示遮罩层,无视该参数
|
|
1910
1910
|
* @see https://www.mdui.org/zh-cn/docs/2/components/navigation-drawer#attributes-modal
|
|
1911
1911
|
*/
|
|
1912
1912
|
'modal'?: boolean;
|
|
1913
1913
|
/**
|
|
1914
|
-
* 在有遮罩层的情况下,按下 ESC
|
|
1914
|
+
* 在有遮罩层的情况下,按下 ESC 键是否关闭抽屉导航栏
|
|
1915
1915
|
* @see https://www.mdui.org/zh-cn/docs/2/components/navigation-drawer#attributes-close-on-esc
|
|
1916
1916
|
*/
|
|
1917
1917
|
'close-on-esc'?: boolean;
|
|
1918
1918
|
/**
|
|
1919
|
-
*
|
|
1919
|
+
* 点击遮罩层时,是否关闭抽屉导航栏
|
|
1920
1920
|
* @see https://www.mdui.org/zh-cn/docs/2/components/navigation-drawer#attributes-close-on-overlay-click
|
|
1921
1921
|
*/
|
|
1922
1922
|
'close-on-overlay-click'?: boolean;
|
|
1923
1923
|
/**
|
|
1924
|
-
*
|
|
1924
|
+
* 抽屉导航栏的位置。可选值包括:
|
|
1925
1925
|
*
|
|
1926
1926
|
* * `left`:左侧
|
|
1927
1927
|
* * `right`:右侧
|
|
@@ -1929,7 +1929,7 @@ declare global {
|
|
|
1929
1929
|
*/
|
|
1930
1930
|
'placement'?: 'left' | 'right';
|
|
1931
1931
|
/**
|
|
1932
|
-
*
|
|
1932
|
+
* 默认情况下,抽屉导航栏相对于 `body` 元素显示。当该属性设置为 `true` 时,抽屉导航栏将相对于其父元素显示。
|
|
1933
1933
|
*
|
|
1934
1934
|
* **Note**:设置该属性时,必须在父元素上手动设置样式 `position: relative; overflow: hidden;`。
|
|
1935
1935
|
* @see https://www.mdui.org/zh-cn/docs/2/components/navigation-drawer#attributes-contained
|
|
@@ -2064,14 +2064,14 @@ declare global {
|
|
|
2064
2064
|
*/
|
|
2065
2065
|
'alignment'?: 'start' | 'center' | 'end';
|
|
2066
2066
|
/**
|
|
2067
|
-
* 默认情况下,导航栏相对于 `body`
|
|
2067
|
+
* 默认情况下,导航栏相对于 `body` 元素显示。当该属性设置为 `true` 时,导航栏将相对于其父元素显示。
|
|
2068
2068
|
*
|
|
2069
2069
|
* **Note**:设置该属性时,必须在父元素上手动设置样式 `position: relative;`。
|
|
2070
2070
|
* @see https://www.mdui.org/zh-cn/docs/2/components/navigation-rail#navigation-rail-attributes-contained
|
|
2071
2071
|
*/
|
|
2072
2072
|
'contained'?: boolean;
|
|
2073
2073
|
/**
|
|
2074
|
-
*
|
|
2074
|
+
* 是否在导航栏和页面内容之间添加分隔线
|
|
2075
2075
|
* @see https://www.mdui.org/zh-cn/docs/2/components/navigation-rail#navigation-rail-attributes-divider
|
|
2076
2076
|
*/
|
|
2077
2077
|
'divider'?: boolean;
|
|
@@ -2111,7 +2111,7 @@ declare global {
|
|
|
2111
2111
|
*/
|
|
2112
2112
|
'name'?: string;
|
|
2113
2113
|
/**
|
|
2114
|
-
*
|
|
2114
|
+
* 单选框组当前选中的值,将与表单数据一起提交
|
|
2115
2115
|
* @see https://www.mdui.org/zh-cn/docs/2/components/radio#radio-group-attributes-value
|
|
2116
2116
|
*/
|
|
2117
2117
|
'value'?: string;
|
|
@@ -2619,7 +2619,7 @@ declare global {
|
|
|
2619
2619
|
*/
|
|
2620
2620
|
'mdui-slider': {
|
|
2621
2621
|
/**
|
|
2622
|
-
*
|
|
2622
|
+
* 滑块的值,将与表单数据一起提交
|
|
2623
2623
|
* @see https://www.mdui.org/zh-cn/docs/2/components/slider#attributes-value
|
|
2624
2624
|
*/
|
|
2625
2625
|
'value'?: number;
|
|
@@ -2790,7 +2790,7 @@ declare global {
|
|
|
2790
2790
|
*/
|
|
2791
2791
|
'name'?: string;
|
|
2792
2792
|
/**
|
|
2793
|
-
*
|
|
2793
|
+
* 开关的值,将与表单数据一起提交
|
|
2794
2794
|
* @see https://www.mdui.org/zh-cn/docs/2/components/switch#attributes-value
|
|
2795
2795
|
*/
|
|
2796
2796
|
'value'?: string;
|
|
@@ -3334,7 +3334,7 @@ declare global {
|
|
|
3334
3334
|
*/
|
|
3335
3335
|
'scroll-target'?: string | HTMLElement | JQ<HTMLElement>;
|
|
3336
3336
|
/**
|
|
3337
|
-
*
|
|
3337
|
+
* 触发滚动行为所需的滚动距离,单位为 `px`
|
|
3338
3338
|
* @see https://www.mdui.org/zh-cn/docs/2/components/top-app-bar#top-app-bar-attributes-scroll-threshold
|
|
3339
3339
|
*/
|
|
3340
3340
|
'scroll-threshold'?: number;
|