@aloudata/aloudata-design 2.13.17 → 2.14.1
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/dist/AldSelect/BaseSelect.d.ts +70 -0
- package/dist/AldSelect/BaseSelect.js +236 -0
- package/dist/AldSelect/SelectTrigger.d.ts +23 -0
- package/dist/AldSelect/SelectTrigger.js +73 -0
- package/dist/AldSelect/Selector/MultipleResponsiveSelectedSection.d.ts +7 -0
- package/dist/AldSelect/Selector/MultipleResponsiveSelectedSection.js +32 -0
- package/dist/AldSelect/Selector/MultipleSelector.d.ts +12 -0
- package/dist/AldSelect/Selector/MultipleSelector.js +148 -0
- package/dist/AldSelect/Selector/index.d.ts +9 -0
- package/dist/AldSelect/Selector/index.js +25 -0
- package/dist/AldSelect/components/PopupContent.d.ts +8 -0
- package/dist/AldSelect/components/PopupContent.js +17 -0
- package/dist/AldSelect/components/SearchBox.d.ts +9 -0
- package/dist/AldSelect/components/SearchBox.js +26 -0
- package/dist/AldSelect/components/Suffix.d.ts +11 -0
- package/dist/AldSelect/components/Suffix.js +36 -0
- package/dist/AldSelect/hooks/useCache.d.ts +6 -0
- package/dist/AldSelect/hooks/useCache.js +50 -0
- package/dist/AldSelect/hooks/useDisplayMenu.d.ts +3 -0
- package/dist/AldSelect/hooks/useDisplayMenu.js +60 -0
- package/dist/AldSelect/hooks/useLayoutEffect.d.ts +5 -0
- package/dist/AldSelect/hooks/useLayoutEffect.js +17 -0
- package/dist/AldSelect/hooks/useOptions.d.ts +11 -0
- package/dist/AldSelect/hooks/useOptions.js +63 -0
- package/dist/AldSelect/index.d.ts +4 -0
- package/dist/AldSelect/index.js +224 -0
- package/dist/AldSelect/interface.d.ts +91 -0
- package/dist/AldSelect/interface.js +1 -0
- package/dist/AldSelect/style/color.less +54 -0
- package/dist/AldSelect/style/index.d.ts +1 -0
- package/dist/AldSelect/style/index.js +1 -0
- package/dist/AldSelect/style/index.less +138 -0
- package/dist/AldSelect/style/size.less +63 -0
- package/dist/AldSelect/utils/commonUtil.d.ts +8 -0
- package/dist/AldSelect/utils/commonUtil.js +22 -0
- package/dist/AldSelect/utils/getWidthStyle.d.ts +2 -0
- package/dist/AldSelect/utils/getWidthStyle.js +18 -0
- package/dist/AldSelect/utils/keyUtil.d.ts +2 -0
- package/dist/AldSelect/utils/keyUtil.js +10 -0
- package/dist/AldSelect/utils/valueUtil.d.ts +22 -0
- package/dist/AldSelect/utils/valueUtil.js +131 -0
- package/dist/Dropdown/index.d.ts +5 -0
- package/dist/Dropdown/index.js +25 -6
- package/dist/Form/index.d.ts +1 -1
- package/dist/Form/index.js +1 -0
- package/dist/Icon/components/ArrowDownRightFill.d.ts +10 -0
- package/dist/Icon/components/ArrowDownRightFill.js +35 -0
- package/dist/Icon/components/CloseCircleRightFill.d.ts +10 -0
- package/dist/Icon/components/CloseCircleRightFill.js +35 -0
- package/dist/Icon/index.d.ts +2 -0
- package/dist/Icon/index.js +3 -1
- package/dist/Icon/svg/arrow-down-right-fill.svg +5 -0
- package/dist/Icon/svg/close-circle-right-fill.svg +5 -0
- package/dist/Input/components/Password/index.js +1 -0
- package/dist/Menu/index.d.ts +4 -0
- package/dist/Menu/index.js +5 -4
- package/dist/ScrollArea/index.d.ts +1 -0
- package/dist/ScrollArea/index.js +9 -1
- package/dist/Table/helper.d.ts +1 -1
- package/dist/_utils/prefixCls.d.ts +4 -0
- package/dist/_utils/prefixCls.js +16 -0
- package/dist/ald.min.css +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.js +2 -1
- package/dist/index.less +1 -0
- package/dist/locale/default.d.ts +1 -1
- package/package.json +1 -1
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
var _excluded = ["title", "titleId", "desc", "descId"];
|
|
2
|
+
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
3
|
+
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
4
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
5
|
+
import * as React from 'react';
|
|
6
|
+
import { forwardRef, memo } from 'react';
|
|
7
|
+
var CloseCircleRightFill = function CloseCircleRightFill(_ref, ref) {
|
|
8
|
+
var title = _ref.title,
|
|
9
|
+
titleId = _ref.titleId,
|
|
10
|
+
desc = _ref.desc,
|
|
11
|
+
descId = _ref.descId,
|
|
12
|
+
props = _objectWithoutProperties(_ref, _excluded);
|
|
13
|
+
return /*#__PURE__*/React.createElement("svg", _extends({
|
|
14
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
15
|
+
width: props.width || props.size || 16,
|
|
16
|
+
height: props.height || props.size || 16,
|
|
17
|
+
fill: "none",
|
|
18
|
+
viewBox: "0 0 16 16",
|
|
19
|
+
ref: ref,
|
|
20
|
+
"aria-labelledby": titleId,
|
|
21
|
+
"aria-describedby": descId
|
|
22
|
+
}, props), desc ? /*#__PURE__*/React.createElement("desc", {
|
|
23
|
+
id: descId
|
|
24
|
+
}, desc) : null, title ? /*#__PURE__*/React.createElement("title", {
|
|
25
|
+
id: titleId
|
|
26
|
+
}, title) : null, /*#__PURE__*/React.createElement("path", {
|
|
27
|
+
fill: props.color || 'currentColor',
|
|
28
|
+
fillRule: "evenodd",
|
|
29
|
+
d: "M5.375 3.875A5.817 5.817 0 0 1 9.5 2.167c1.61 0 3.07.653 4.125 1.708A5.817 5.817 0 0 1 15.333 8c0 1.61-.653 3.07-1.708 4.125A5.817 5.817 0 0 1 9.5 13.833c-1.61 0-3.07-.653-4.125-1.708A5.816 5.816 0 0 1 3.667 8c0-1.61.653-3.07 1.708-4.125Zm6.364 6.364a.5.5 0 0 1-.707 0L9.5 8.707 7.968 10.24a.5.5 0 0 1-.707-.707L8.793 8 7.26 6.468a.5.5 0 0 1 .707-.707L9.5 7.293l1.532-1.532a.5.5 0 1 1 .707.707L10.207 8l1.532 1.532a.5.5 0 0 1 0 .707Z",
|
|
30
|
+
clipRule: "evenodd"
|
|
31
|
+
}));
|
|
32
|
+
};
|
|
33
|
+
var ForwardRef = /*#__PURE__*/forwardRef(CloseCircleRightFill);
|
|
34
|
+
var Memo = /*#__PURE__*/memo(ForwardRef);
|
|
35
|
+
export default Memo;
|
package/dist/Icon/index.d.ts
CHANGED
|
@@ -48,3 +48,5 @@ export { default as TrashLightLine } from './components/TrashLightLine';
|
|
|
48
48
|
export { default as TriangleLightLine } from './components/TriangleLightLine';
|
|
49
49
|
export { default as User } from './components/User';
|
|
50
50
|
export { default as UserGroup } from './components/UserGroup';
|
|
51
|
+
export { default as ArrowDownRightFill } from './components/ArrowDownRightFill';
|
|
52
|
+
export { default as CloseCircleRightFill } from './components/CloseCircleRightFill';
|
package/dist/Icon/index.js
CHANGED
|
@@ -47,4 +47,6 @@ export { default as TimesLightLine } from "./components/TimesLightLine";
|
|
|
47
47
|
export { default as TrashLightLine } from "./components/TrashLightLine";
|
|
48
48
|
export { default as TriangleLightLine } from "./components/TriangleLightLine";
|
|
49
49
|
export { default as User } from "./components/User";
|
|
50
|
-
export { default as UserGroup } from "./components/UserGroup";
|
|
50
|
+
export { default as UserGroup } from "./components/UserGroup";
|
|
51
|
+
export { default as ArrowDownRightFill } from "./components/ArrowDownRightFill";
|
|
52
|
+
export { default as CloseCircleRightFill } from "./components/CloseCircleRightFill";
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 16 16" fill="none">
|
|
2
|
+
<path fill-rule="evenodd" clip-rule="evenodd"
|
|
3
|
+
d="M8.55557 6.38882C8.33087 6.38882 8.12829 6.52418 8.04231 6.73177C7.95632 6.93937 8.00385 7.17832 8.16273 7.33721L10.9405 10.115C11.0447 10.2192 11.186 10.2777 11.3333 10.2777C11.4807 10.2777 11.622 10.2192 11.7262 10.115L14.5039 7.33721C14.6628 7.17832 14.7104 6.93937 14.6244 6.73177C14.5384 6.52418 14.3358 6.38882 14.1111 6.38882L8.55557 6.38882Z"
|
|
4
|
+
fill="black" />
|
|
5
|
+
</svg>
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 16 16" fill="none">
|
|
2
|
+
<path fill-rule="evenodd" clip-rule="evenodd"
|
|
3
|
+
d="M5.37523 3.87517C6.43032 2.82009 7.88934 2.16663 9.50002 2.16663C11.1107 2.16663 12.5697 2.8201 13.6248 3.87517C14.6799 4.93026 15.3334 6.38928 15.3334 7.99996C15.3334 9.61064 14.6799 11.0697 13.6248 12.1247C12.5697 13.1798 11.1107 13.8333 9.50002 13.8333C7.88934 13.8333 6.43032 13.1798 5.37523 12.1247C4.32015 11.0697 3.66669 9.61064 3.66669 7.99996C3.66669 6.38928 4.32016 4.93025 5.37523 3.87517ZM11.7392 10.2391C11.5439 10.4344 11.2274 10.4344 11.0321 10.2391L9.50006 8.70706L7.96795 10.2392C7.77269 10.4344 7.45611 10.4344 7.26085 10.2392C7.06559 10.0439 7.06559 9.72731 7.26085 9.53205L8.79295 7.99995L7.26085 6.46785C7.06559 6.27259 7.06559 5.95601 7.26085 5.76074C7.45612 5.56548 7.7727 5.56548 7.96796 5.76075L9.50006 7.29284L11.0321 5.76082C11.2273 5.56555 11.5439 5.56555 11.7392 5.76082C11.9345 5.95608 11.9345 6.27266 11.7392 6.46792L10.2072 7.99995L11.7392 9.53198C11.9345 9.72724 11.9345 10.0438 11.7392 10.2391Z"
|
|
4
|
+
fill="black" />
|
|
5
|
+
</svg>
|
|
@@ -25,6 +25,7 @@ export default /*#__PURE__*/React.forwardRef(function (props, ref) {
|
|
|
25
25
|
ref: ref,
|
|
26
26
|
spellCheck: false,
|
|
27
27
|
disabled: disabled,
|
|
28
|
+
autoComplete: "off",
|
|
28
29
|
className: classnames('ald-input', 'ald-input-password', "ald-input-".concat(getSizeType(size)), _defineProperty({}, "ald-input-disabled", disabled), className),
|
|
29
30
|
iconRender: function iconRender(visible) {
|
|
30
31
|
return /*#__PURE__*/React.createElement(IconButton, {
|
package/dist/Menu/index.d.ts
CHANGED
|
@@ -6,6 +6,10 @@ export interface MenuProps {
|
|
|
6
6
|
selectedKeys?: string[];
|
|
7
7
|
}
|
|
8
8
|
export default function Menu(props: MenuProps): React.JSX.Element;
|
|
9
|
+
export declare function isHeaderMenuItem(menuItem: MenuItemType): menuItem is MenuHeaderType;
|
|
10
|
+
export declare function isDivideMenuItem(menuItem: MenuItemType): menuItem is MenuDividerType;
|
|
11
|
+
export declare function isSubMenuItem(menuItem: MenuItemType): menuItem is SubMenuType;
|
|
12
|
+
export declare function isLeafMenu(menuItems: MenuItemType[]): boolean;
|
|
9
13
|
export type MenuItemType = ItemType | MenuDividerType | SubMenuType | MenuHeaderType;
|
|
10
14
|
export interface ItemType {
|
|
11
15
|
key: string;
|
package/dist/Menu/index.js
CHANGED
|
@@ -95,20 +95,21 @@ export default function Menu(props) {
|
|
|
95
95
|
anchorRef: ref,
|
|
96
96
|
className: classNames(className, 'ald-menu'),
|
|
97
97
|
position: "auto",
|
|
98
|
+
captureFocus: false,
|
|
98
99
|
viewScroll: "auto",
|
|
99
100
|
overflow: isLeafMenu(items) ? 'auto' : undefined
|
|
100
101
|
}, getMenuItems(items || [])));
|
|
101
102
|
}
|
|
102
|
-
function isHeaderMenuItem(menuItem) {
|
|
103
|
+
export function isHeaderMenuItem(menuItem) {
|
|
103
104
|
return 'type' in menuItem && menuItem.type === 'header';
|
|
104
105
|
}
|
|
105
|
-
function isDivideMenuItem(menuItem) {
|
|
106
|
+
export function isDivideMenuItem(menuItem) {
|
|
106
107
|
return 'type' in menuItem && menuItem.type === 'divider';
|
|
107
108
|
}
|
|
108
|
-
function isSubMenuItem(menuItem) {
|
|
109
|
+
export function isSubMenuItem(menuItem) {
|
|
109
110
|
return 'children' in menuItem;
|
|
110
111
|
}
|
|
111
|
-
function isLeafMenu(menuItems) {
|
|
112
|
+
export function isLeafMenu(menuItems) {
|
|
112
113
|
return !_.some(menuItems, function (item) {
|
|
113
114
|
return isSubMenuItem(item);
|
|
114
115
|
});
|
|
@@ -9,6 +9,7 @@ interface Props extends ScrollAreaProps {
|
|
|
9
9
|
innerClassName?: string;
|
|
10
10
|
scrollBarHidden?: Array<'horizontal' | 'vertical'>;
|
|
11
11
|
contentDeterminesWidth?: boolean;
|
|
12
|
+
innerStyle?: React.CSSProperties;
|
|
12
13
|
}
|
|
13
14
|
declare const _default: React.MemoExoticComponent<React.ForwardRefExoticComponent<Props & React.RefAttributes<HTMLDivElement>>>;
|
|
14
15
|
export default _default;
|
package/dist/ScrollArea/index.js
CHANGED
|
@@ -1,5 +1,11 @@
|
|
|
1
|
-
|
|
1
|
+
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
2
|
+
var _excluded = ["children", "className", "innerClassName", "horizontalScrollBarClassName", "verticalScrollBarClassName", "onViewportScroll", "contentDeterminesWidth", "scrollBarHidden", "asChild", "innerStyle"];
|
|
2
3
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
4
|
+
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
5
|
+
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
6
|
+
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
7
|
+
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
|
|
8
|
+
function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
3
9
|
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
4
10
|
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
5
11
|
import * as ScrollAreaComponent from '@radix-ui/react-scroll-area';
|
|
@@ -15,6 +21,7 @@ var ScrollArea = function ScrollArea(props, ref) {
|
|
|
15
21
|
contentDeterminesWidth = props.contentDeterminesWidth,
|
|
16
22
|
scrollBarHidden = props.scrollBarHidden,
|
|
17
23
|
asChild = props.asChild,
|
|
24
|
+
innerStyle = props.innerStyle,
|
|
18
25
|
rest = _objectWithoutProperties(props, _excluded);
|
|
19
26
|
var isHorizontalScrollBarHidden = scrollBarHidden === null || scrollBarHidden === void 0 ? void 0 : scrollBarHidden.includes('horizontal');
|
|
20
27
|
var isVerticalScrollBarHidden = scrollBarHidden === null || scrollBarHidden === void 0 ? void 0 : scrollBarHidden.includes('vertical');
|
|
@@ -26,6 +33,7 @@ var ScrollArea = function ScrollArea(props, ref) {
|
|
|
26
33
|
className: classNames('ald-scroll-area-inner', {
|
|
27
34
|
'ald-scroll-area-width-auto': !contentDeterminesWidth
|
|
28
35
|
}, innerClassName),
|
|
36
|
+
style: _objectSpread({}, innerStyle),
|
|
29
37
|
onScroll: function onScroll(event) {
|
|
30
38
|
onViewportScroll === null || onViewportScroll === void 0 ? void 0 : onViewportScroll(event);
|
|
31
39
|
},
|
package/dist/Table/helper.d.ts
CHANGED
|
@@ -23,7 +23,7 @@ export declare function getTableColumns<TDataItem extends object>({ columns, con
|
|
|
23
23
|
render?: ((text: any, record: TDataItem, rowIndex: number) => import("react").ReactNode) | undefined;
|
|
24
24
|
ellipsis?: boolean | undefined;
|
|
25
25
|
noPadding?: boolean | undefined;
|
|
26
|
-
align?: "
|
|
26
|
+
align?: "center" | "left" | "right" | undefined;
|
|
27
27
|
fixed?: "left" | "right" | undefined;
|
|
28
28
|
sortOrder?: "ascend" | "descend" | null | undefined;
|
|
29
29
|
};
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import classNames from 'classnames';
|
|
2
|
+
// classNames 函数的参数类型
|
|
3
|
+
|
|
4
|
+
function prefixCls(componentName) {
|
|
5
|
+
var cls = "beta-ald-".concat(componentName);
|
|
6
|
+
return function () {
|
|
7
|
+
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
8
|
+
args[_key] = arguments[_key];
|
|
9
|
+
}
|
|
10
|
+
return classNames(args).split(' ').map(function (name) {
|
|
11
|
+
if (name.startsWith(cls)) return name;
|
|
12
|
+
return "".concat(cls, "-").concat(name);
|
|
13
|
+
}).join(' ');
|
|
14
|
+
};
|
|
15
|
+
}
|
|
16
|
+
export default prefixCls;
|