@oceanbase/design 1.0.0-alpha.20 → 1.0.0-alpha.21
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.
|
@@ -1,9 +1,8 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import type { DescriptionsItemType } from '..';
|
|
3
3
|
export default function useItems(items?: DescriptionsItemType[], children?: React.ReactNode, bordered?: boolean): {
|
|
4
|
-
children: string | number | boolean |
|
|
4
|
+
children: string | number | boolean | import("@emotion/react/jsx-runtime").JSX.Element | Iterable<React.ReactNode>;
|
|
5
5
|
key?: React.Key;
|
|
6
|
-
className?: string;
|
|
7
6
|
label?: React.ReactNode;
|
|
8
7
|
span?: number | "filled" | {
|
|
9
8
|
xxl?: number;
|
|
@@ -14,8 +13,9 @@ export default function useItems(items?: DescriptionsItemType[], children?: Reac
|
|
|
14
13
|
xs?: number;
|
|
15
14
|
};
|
|
16
15
|
style?: React.CSSProperties;
|
|
17
|
-
|
|
18
|
-
|
|
16
|
+
className?: string;
|
|
17
|
+
classNames?: Partial<Record<"content" | "label", string>>;
|
|
18
|
+
styles?: Partial<Record<"content" | "label", React.CSSProperties>>;
|
|
19
19
|
labelStyle?: React.CSSProperties;
|
|
20
20
|
contentStyle?: React.CSSProperties;
|
|
21
21
|
}[];
|
package/es/style/global.js
CHANGED
|
@@ -15,7 +15,7 @@ import 'antd/dist/reset.css';
|
|
|
15
15
|
import { Fragment as _Fragment } from "react/jsx-runtime";
|
|
16
16
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
17
17
|
var genGlobalStyle = function genGlobalStyle(token, prefixCls, iconPrefixCls) {
|
|
18
|
-
var
|
|
18
|
+
var _ref;
|
|
19
19
|
var antCls = ".".concat(prefixCls);
|
|
20
20
|
var iconCls = ".".concat(iconPrefixCls);
|
|
21
21
|
var buttonComponentCls = "".concat(antCls, "-btn");
|
|
@@ -80,15 +80,26 @@ var genGlobalStyle = function genGlobalStyle(token, prefixCls, iconPrefixCls) {
|
|
|
80
80
|
'input::placeholder': {
|
|
81
81
|
// affact all placeholder excluding select
|
|
82
82
|
fontWeight: token.fontWeightWeak
|
|
83
|
+
},
|
|
84
|
+
// WCAG 2.4.7: native / non-ant focusables still need a visible ring (antd controls use token lineWidthFocus)
|
|
85
|
+
// [[
|
|
86
|
+
// `button:not([class^="${prefixCls}-"]):not([class*=" ${prefixCls}-"]):focus-visible`,
|
|
87
|
+
// `a:not([class^="${prefixCls}-"]):not([class*=" ${prefixCls}-"]):focus-visible`,
|
|
88
|
+
// `textarea:not([class^="${prefixCls}-"]):not([class*=" ${prefixCls}-"]):focus-visible`,
|
|
89
|
+
// `select:not([class^="${prefixCls}-"]):not([class*=" ${prefixCls}-"]):focus-visible`,
|
|
90
|
+
// `input:not([class^="${prefixCls}-"]):not([class*=" ${prefixCls}-"]):focus-visible`,
|
|
91
|
+
// `[role="button"]:not([class^="${prefixCls}-"]):not([class*=" ${prefixCls}-"]):focus-visible`,
|
|
92
|
+
// ].join(', ')]: {
|
|
93
|
+
// outline: `${token.lineWidthFocus ?? 2}px solid ${token.colorPrimary}`,
|
|
94
|
+
// outlineOffset: 2,
|
|
95
|
+
// },
|
|
96
|
+
'*': {
|
|
97
|
+
scrollbarColor: "".concat(token.colorFillSecondary, " transparent")
|
|
98
|
+
},
|
|
99
|
+
'.rc-virtual-list-scrollbar-thumb': {
|
|
100
|
+
background: "".concat(token.colorFillSecondary, " !important")
|
|
83
101
|
}
|
|
84
|
-
}, _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_ref,
|
|
85
|
-
outline: "".concat((_token$lineWidthFocus = token.lineWidthFocus) !== null && _token$lineWidthFocus !== void 0 ? _token$lineWidthFocus : 2, "px solid ").concat(token.colorPrimary),
|
|
86
|
-
outlineOffset: 2
|
|
87
|
-
}), '*', {
|
|
88
|
-
scrollbarColor: "".concat(token.colorFillSecondary, " transparent")
|
|
89
|
-
}), '.rc-virtual-list-scrollbar-thumb', {
|
|
90
|
-
background: "".concat(token.colorFillSecondary, " !important")
|
|
91
|
-
}), "[style*='font-size: 12px']", {
|
|
102
|
+
}, _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_ref, "[style*='font-size: 12px']", {
|
|
92
103
|
fontWeight: token.fontWeightWeak
|
|
93
104
|
}), 'a[href], a[data-aspm-param^="obcloud_openLink="]', _defineProperty({}, "&:not([disabled]):not([class^=\"".concat(prefixCls, "-\"]):hover"), {
|
|
94
105
|
textDecoration: 'underline'
|
|
@@ -112,7 +123,7 @@ var genGlobalStyle = function genGlobalStyle(token, prefixCls, iconPrefixCls) {
|
|
|
112
123
|
color: token.colorIcon
|
|
113
124
|
}))), "".concat(selectComponentCls).concat(selectComponentCls, "-single").concat(selectComponentCls, "-open ").concat(selectComponentCls, "-selection-item"), {
|
|
114
125
|
color: token.colorTextSecondary
|
|
115
|
-
}),
|
|
126
|
+
}), "".concat(pickerComponentCls), _defineProperty({}, "".concat(pickerComponentCls, "-clear ").concat(iconCls), _defineProperty({
|
|
116
127
|
color: token.gray7
|
|
117
128
|
}, '&:hover', {
|
|
118
129
|
color: token.gray8
|
|
@@ -125,7 +136,7 @@ var genGlobalStyle = function genGlobalStyle(token, prefixCls, iconPrefixCls) {
|
|
|
125
136
|
color: token.colorIcon,
|
|
126
137
|
// to avoid icon to be hidden when hover
|
|
127
138
|
position: 'relative'
|
|
128
|
-
})), "".concat(treeComponentCls, " ").concat(treeComponentCls, "-iconEle, ").concat(treeSelectComponentCls, " ").concat(treeSelectComponentCls, "-iconEle"), _defineProperty({}, "".concat(iconCls), {
|
|
139
|
+
})), _defineProperty(_defineProperty(_ref, "".concat(treeComponentCls, " ").concat(treeComponentCls, "-iconEle, ").concat(treeSelectComponentCls, " ").concat(treeSelectComponentCls, "-iconEle"), _defineProperty({}, "".concat(iconCls), {
|
|
129
140
|
color: token.colorIcon
|
|
130
141
|
})), "".concat(uploadComponentCls), _defineProperty({}, "".concat(iconCls), {
|
|
131
142
|
color: token.colorIcon
|
package/es/table/index.d.ts
CHANGED
|
@@ -38,8 +38,8 @@ declare const _default: (<RecordType extends AnyObject = AnyObject>(props: Table
|
|
|
38
38
|
SELECTION_ALL: "SELECT_ALL";
|
|
39
39
|
SELECTION_INVERT: "SELECT_INVERT";
|
|
40
40
|
SELECTION_NONE: "SELECT_NONE";
|
|
41
|
-
Column: <
|
|
42
|
-
ColumnGroup: <
|
|
41
|
+
Column: <RecordType extends import("antd/es/_util/type").AnyObject>(_: import("antd").TableColumnProps<RecordType>) => null;
|
|
42
|
+
ColumnGroup: <RecordType_1 extends import("antd/es/_util/type").AnyObject>(_: import("antd/es/table/ColumnGroup").ColumnGroupProps<RecordType_1>) => null;
|
|
43
43
|
Summary: typeof Summary;
|
|
44
44
|
useStyle: (prefixCls: string, rootCls?: string) => readonly [(node: ReactElement<any, string | React.JSXElementConstructor<any>>) => ReactElement<any, string | React.JSXElementConstructor<any>>, string, string];
|
|
45
45
|
useDefaultPagination: (pagination?: false | import("antd").TablePaginationConfig) => false | import("antd").TablePaginationConfig;
|
|
@@ -1,9 +1,8 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import type { DescriptionsItemType } from '..';
|
|
3
3
|
export default function useItems(items?: DescriptionsItemType[], children?: React.ReactNode, bordered?: boolean): {
|
|
4
|
-
children: string | number | boolean |
|
|
4
|
+
children: string | number | boolean | import("@emotion/react/jsx-runtime").JSX.Element | Iterable<React.ReactNode>;
|
|
5
5
|
key?: React.Key;
|
|
6
|
-
className?: string;
|
|
7
6
|
label?: React.ReactNode;
|
|
8
7
|
span?: number | "filled" | {
|
|
9
8
|
xxl?: number;
|
|
@@ -14,8 +13,9 @@ export default function useItems(items?: DescriptionsItemType[], children?: Reac
|
|
|
14
13
|
xs?: number;
|
|
15
14
|
};
|
|
16
15
|
style?: React.CSSProperties;
|
|
17
|
-
|
|
18
|
-
|
|
16
|
+
className?: string;
|
|
17
|
+
classNames?: Partial<Record<"content" | "label", string>>;
|
|
18
|
+
styles?: Partial<Record<"content" | "label", React.CSSProperties>>;
|
|
19
19
|
labelStyle?: React.CSSProperties;
|
|
20
20
|
contentStyle?: React.CSSProperties;
|
|
21
21
|
}[];
|
package/lib/style/global.js
CHANGED
|
@@ -82,10 +82,17 @@ const genGlobalStyle = (token, prefixCls, iconPrefixCls) => {
|
|
|
82
82
|
fontWeight: token.fontWeightWeak
|
|
83
83
|
},
|
|
84
84
|
// WCAG 2.4.7: native / non-ant focusables still need a visible ring (antd controls use token lineWidthFocus)
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
}
|
|
85
|
+
// [[
|
|
86
|
+
// `button:not([class^="${prefixCls}-"]):not([class*=" ${prefixCls}-"]):focus-visible`,
|
|
87
|
+
// `a:not([class^="${prefixCls}-"]):not([class*=" ${prefixCls}-"]):focus-visible`,
|
|
88
|
+
// `textarea:not([class^="${prefixCls}-"]):not([class*=" ${prefixCls}-"]):focus-visible`,
|
|
89
|
+
// `select:not([class^="${prefixCls}-"]):not([class*=" ${prefixCls}-"]):focus-visible`,
|
|
90
|
+
// `input:not([class^="${prefixCls}-"]):not([class*=" ${prefixCls}-"]):focus-visible`,
|
|
91
|
+
// `[role="button"]:not([class^="${prefixCls}-"]):not([class*=" ${prefixCls}-"]):focus-visible`,
|
|
92
|
+
// ].join(', ')]: {
|
|
93
|
+
// outline: `${token.lineWidthFocus ?? 2}px solid ${token.colorPrimary}`,
|
|
94
|
+
// outlineOffset: 2,
|
|
95
|
+
// },
|
|
89
96
|
'*': {
|
|
90
97
|
scrollbarColor: `${token.colorFillSecondary} transparent`
|
|
91
98
|
},
|
package/lib/table/index.d.ts
CHANGED
|
@@ -38,8 +38,8 @@ declare const _default: (<RecordType extends AnyObject = AnyObject>(props: Table
|
|
|
38
38
|
SELECTION_ALL: "SELECT_ALL";
|
|
39
39
|
SELECTION_INVERT: "SELECT_INVERT";
|
|
40
40
|
SELECTION_NONE: "SELECT_NONE";
|
|
41
|
-
Column: <
|
|
42
|
-
ColumnGroup: <
|
|
41
|
+
Column: <RecordType extends import("antd/es/_util/type").AnyObject>(_: import("antd").TableColumnProps<RecordType>) => null;
|
|
42
|
+
ColumnGroup: <RecordType_1 extends import("antd/es/_util/type").AnyObject>(_: import("antd/es/table/ColumnGroup").ColumnGroupProps<RecordType_1>) => null;
|
|
43
43
|
Summary: typeof Summary;
|
|
44
44
|
useStyle: (prefixCls: string, rootCls?: string) => readonly [(node: ReactElement<any, string | React.JSXElementConstructor<any>>) => ReactElement<any, string | React.JSXElementConstructor<any>>, string, string];
|
|
45
45
|
useDefaultPagination: (pagination?: false | import("antd").TablePaginationConfig) => false | import("antd").TablePaginationConfig;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@oceanbase/design",
|
|
3
|
-
"version": "1.0.0-alpha.
|
|
3
|
+
"version": "1.0.0-alpha.21",
|
|
4
4
|
"description": "The Design System of OceanBase",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"oceanbase",
|
|
@@ -66,5 +66,5 @@
|
|
|
66
66
|
"react": ">=16.9.0",
|
|
67
67
|
"react-dom": ">=16.9.0"
|
|
68
68
|
},
|
|
69
|
-
"gitHead": "
|
|
69
|
+
"gitHead": "f341321d6fc6414c7a852de69862a3c8f5ff7cca"
|
|
70
70
|
}
|