@lobehub/ui 1.169.0 → 1.169.2

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,6 +1,6 @@
1
1
  import { type DrawerProps as AntdDrawerProps } from 'antd';
2
2
  import { CSSProperties, ReactNode } from 'react';
3
- export interface DrawProps extends Omit<AntdDrawerProps, 'styles' | 'classNames'> {
3
+ export interface DrawerProps extends Omit<AntdDrawerProps, 'styles' | 'classNames'> {
4
4
  classNames?: AntdDrawerProps['classNames'] & {
5
5
  bodyContent?: string;
6
6
  extra?: string;
@@ -16,5 +16,5 @@ export interface DrawProps extends Omit<AntdDrawerProps, 'styles' | 'classNames'
16
16
  title?: CSSProperties;
17
17
  };
18
18
  }
19
- declare const Draw: import("react").NamedExoticComponent<DrawProps>;
20
- export default Draw;
19
+ declare const Drawer: import("react").NamedExoticComponent<DrawerProps>;
20
+ export default Drawer;
@@ -9,7 +9,7 @@ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol"
9
9
  function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
10
10
  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; }
11
11
  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; }
12
- import { Drawer as AntdDraw } from 'antd';
12
+ import { Drawer as AntdDrawer } from 'antd';
13
13
  import { useTheme } from 'antd-style';
14
14
  import { XIcon } from 'lucide-react';
15
15
  import { memo, useMemo } from 'react';
@@ -18,7 +18,7 @@ import ActionIcon from "../ActionIcon";
18
18
  import { jsx as _jsx } from "react/jsx-runtime";
19
19
  import { jsxs as _jsxs } from "react/jsx-runtime";
20
20
  import { Fragment as _Fragment } from "react/jsx-runtime";
21
- var Draw = /*#__PURE__*/memo(function (_ref) {
21
+ var Drawer = /*#__PURE__*/memo(function (_ref) {
22
22
  var onClose = _ref.onClose,
23
23
  _ref$containerMaxWidt = _ref.containerMaxWidth,
24
24
  containerMaxWidth = _ref$containerMaxWidt === void 0 ? 1024 : _ref$containerMaxWidt,
@@ -86,7 +86,7 @@ var Draw = /*#__PURE__*/memo(function (_ref) {
86
86
  size: 'site'
87
87
  })]
88
88
  });
89
- return /*#__PURE__*/_jsx(AntdDraw, _objectSpread(_objectSpread({
89
+ return /*#__PURE__*/_jsx(AntdDrawer, _objectSpread(_objectSpread({
90
90
  classNames: classNames,
91
91
  closable: false,
92
92
  extra: noHeader ? undefined : extraNode,
@@ -163,4 +163,4 @@ var Draw = /*#__PURE__*/memo(function (_ref) {
163
163
  })
164
164
  }));
165
165
  });
166
- export default Draw;
166
+ export default Drawer;
@@ -91,7 +91,7 @@ var mappingKey = function mappingKey(isAppleDevice) {
91
91
  icon: ArrowRightToLineIcon
92
92
  }) : 'Tab'), KeyMapEnum.Up, /*#__PURE__*/_jsx(Icon, {
93
93
  icon: ArrowUpIcon
94
- })), KeyMapEnum.Comma, ','), KeyMapEnum.Period, '.'), _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_ref, KeyMapEnum.Slash, '/'), KeyMapEnum.Semicolon, ';'), KeyMapEnum.Quote, "'"), KeyMapEnum.Backquote, '`'), KeyMapEnum.Backslash, '\\'), KeyMapEnum.BracketLeft, '['), KeyMapEnum.BracketRight, ']'), KeyMapEnum.Minus, '-'), KeyMapEnum.Equal, '=');
94
+ })), KeyMapEnum.Comma, ','), KeyMapEnum.Period, '.'), _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_ref, KeyMapEnum.Slash, '?'), KeyMapEnum.Semicolon, ';'), KeyMapEnum.Quote, "'"), KeyMapEnum.Backquote, '`'), KeyMapEnum.Backslash, '\\'), KeyMapEnum.BracketLeft, '['), KeyMapEnum.BracketRight, ']'), KeyMapEnum.Minus, '-'), KeyMapEnum.Equal, '+');
95
95
  };
96
96
  var Hotkey = /*#__PURE__*/memo(function (_ref2) {
97
97
  var _ref2$variant = _ref2.variant,
@@ -19,6 +19,8 @@ export declare const KeyMapEnum: {
19
19
  readonly Minus: "minus";
20
20
  readonly Mod: "mod";
21
21
  readonly Period: "period";
22
+ readonly Plus: "equal";
23
+ readonly QuestionMark: "slash";
22
24
  readonly Quote: "quote";
23
25
  readonly Right: "right";
24
26
  readonly RightClick: "right-click";
package/es/Hotkey/type.js CHANGED
@@ -29,6 +29,10 @@ export var KeyMapEnum = {
29
29
  // Command on Mac, Ctrl on Win
30
30
  Period: 'period',
31
31
  // .
32
+ Plus: 'equal',
33
+ // +
34
+ QuestionMark: 'slash',
35
+ // ?
32
36
  Quote: 'quote',
33
37
  // '
34
38
  Right: 'right',
@@ -263,7 +263,7 @@ var HotkeyInput = /*#__PURE__*/memo(function (_ref) {
263
263
  style: {
264
264
  pointerEvents: 'none'
265
265
  }
266
- }), allowReset && hotkeyValue && hotkeyValue !== resetValue && !disabled && /*#__PURE__*/_jsx(ActionIcon, {
266
+ }), !isFocused && allowReset && hotkeyValue && hotkeyValue !== resetValue && !disabled && /*#__PURE__*/_jsx(ActionIcon, {
267
267
  active: true,
268
268
  icon: Undo2Icon,
269
269
  onClick: handleReset,
@@ -13,7 +13,7 @@ export { default as DraggablePanelBody, type DraggablePanelBodyProps, } from './
13
13
  export { default as DraggablePanelContainer, type DraggablePanelContainerProps, } from './DraggablePanel/components/DraggablePanelContainer';
14
14
  export { default as DraggablePanelFooter, type DraggablePanelFooterProps, } from './DraggablePanel/components/DraggablePanelFooter';
15
15
  export { default as DraggablePanelHeader, type DraggablePanelHeaderProps, } from './DraggablePanel/components/DraggablePanelHeader';
16
- export { default as Draw, type DrawProps } from './Draw';
16
+ export { default as Drawer, type DrawerProps } from './Drawer';
17
17
  export { default as EditableText, type EditableTextProps } from './EditableText';
18
18
  export { default as EmojiPicker, type EmojiPickerProps } from './EmojiPicker';
19
19
  export { default as EmptyCard, type EmptyCardProps } from './EmptyCard';
package/es/components.js CHANGED
@@ -13,7 +13,7 @@ export { default as DraggablePanelBody } from "./DraggablePanel/components/Dragg
13
13
  export { default as DraggablePanelContainer } from "./DraggablePanel/components/DraggablePanelContainer";
14
14
  export { default as DraggablePanelFooter } from "./DraggablePanel/components/DraggablePanelFooter";
15
15
  export { default as DraggablePanelHeader } from "./DraggablePanel/components/DraggablePanelHeader";
16
- export { default as Draw } from "./Draw";
16
+ export { default as Drawer } from "./Drawer";
17
17
  export { default as EditableText } from "./EditableText";
18
18
  export { default as EmojiPicker } from "./EmojiPicker";
19
19
  export { default as EmptyCard } from "./EmptyCard";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lobehub/ui",
3
- "version": "1.169.0",
3
+ "version": "1.169.2",
4
4
  "description": "Lobe UI is an open-source UI component library for building AIGC web apps",
5
5
  "keywords": [
6
6
  "lobehub",