@yuntijs/ui 1.0.0-beta.81 → 1.0.0-beta.83
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/es/ChatInputArea/desktop/ChatInputArea.d.ts +1 -1
- package/es/Form/collapse-list/index.d.ts +1 -1
- package/es/Mentions/index.d.ts +4 -0
- package/es/Mentions/index.js +20 -9
- package/es/Mentions/plugins/mention-node/component.js +1 -1
- package/es/Mentions/plugins/mention-node/node.d.ts +1 -2
- package/es/Mentions/plugins/mention-node/node.js +5 -2
- package/es/Mentions/plugins/mention-node/utils.js +6 -1
- package/es/Mentions/plugins/mention-picker/hooks.js +17 -10
- package/es/Mentions/plugins/mention-picker/index.d.ts +3 -0
- package/es/Mentions/plugins/mention-picker/index.js +57 -8
- package/es/Mentions/plugins/mention-picker/menu-item.d.ts +3 -3
- package/es/Mentions/plugins/mention-picker/menu-item.js +2 -2
- package/es/Mentions/plugins/mention-picker/menu.d.ts +5 -4
- package/es/Mentions/plugins/mention-picker/menu.js +2 -1
- package/es/Mentions/plugins/mention-picker/style.js +3 -3
- package/es/Mentions/plugins/mention-picker/utils.d.ts +16 -9
- package/es/Mentions/plugins/mention-picker/utils.js +29 -8
- package/es/Mentions/plugins/on-blur-or-focus-block.js +1 -1
- package/es/Mentions/types.d.ts +5 -10
- package/es/MonacoEditor/base/index.d.ts +6 -2
- package/es/MonacoEditor/base/index.js +4 -2
- package/es/MonacoEditor/base/style.d.ts +1 -0
- package/es/MonacoEditor/base/style.js +23 -6
- package/es/MonacoEditor/index.d.ts +3 -0
- package/es/Page/Page.d.ts +1 -1
- package/es/Radio/index.js +1 -2
- package/es/Table/index.d.ts +1 -1
- package/es/Typography/index.d.ts +1 -1
- package/es/styles/colors/generateColorPalette.d.ts +1 -1
- package/package.json +6 -6
- package/umd/index.min.js +1 -1
- package/umd/index.min.js.map +1 -1
- package/es/MonacoEditor/style.d.ts +0 -10
- package/es/MonacoEditor/style.js +0 -25
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import _taggedTemplateLiteral from "@babel/runtime/helpers/esm/taggedTemplateLiteral";
|
|
2
|
-
var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7;
|
|
2
|
+
var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7, _templateObject8, _templateObject9, _templateObject10;
|
|
3
3
|
import { createStyles, keyframes } from 'antd-style';
|
|
4
|
-
|
|
5
4
|
/**
|
|
6
5
|
* styles from https://github.com/alibaba/lowcode-plugins/blob/main/packages/base-monaco-editor/src/index.scss
|
|
7
6
|
*/
|
|
@@ -14,12 +13,30 @@ export var useStyles = createStyles(function (_ref, _ref2) {
|
|
|
14
13
|
_ref2$isFullScreen = _ref2.isFullScreen,
|
|
15
14
|
isFullScreen = _ref2$isFullScreen === void 0 ? false : _ref2$isFullScreen,
|
|
16
15
|
_ref2$diff = _ref2.diff,
|
|
17
|
-
diff = _ref2$diff === void 0 ? false : _ref2$diff
|
|
16
|
+
diff = _ref2$diff === void 0 ? false : _ref2$diff,
|
|
17
|
+
_ref2$variant = _ref2.variant,
|
|
18
|
+
variant = _ref2$variant === void 0 ? 'outlined' : _ref2$variant;
|
|
18
19
|
var dots = keyframes(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n 0% { content: '.'; }\n 20% { content: '..'; }\n 40% { content: '...'; }\n 60% { content: '....'; }\n 80% { content: '.....'; }\n "])));
|
|
20
|
+
var getBgColor = function getBgColor() {
|
|
21
|
+
switch (variant) {
|
|
22
|
+
case 'outlined':
|
|
23
|
+
{
|
|
24
|
+
return token.colorBgBase;
|
|
25
|
+
}
|
|
26
|
+
case 'filled':
|
|
27
|
+
{
|
|
28
|
+
return token.colorFillTertiary;
|
|
29
|
+
}
|
|
30
|
+
default:
|
|
31
|
+
{
|
|
32
|
+
return 'transparent';
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
};
|
|
19
36
|
return {
|
|
20
|
-
base: css(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n position: relative;\n\n box-sizing: content-box;\n min-height: 100px;\n\n border: 1px solid
|
|
21
|
-
fullScreenBtn: css(
|
|
22
|
-
loading: css(
|
|
37
|
+
base: css(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n position: relative;\n\n box-sizing: content-box;\n min-height: 100px;\n\n background-color: ", ";\n border: 1px solid ", ";\n border-radius: ", "px;\n &:hover {\n border-color: ", ";\n ", "\n }\n\n &.ve-focused {\n ", "\n ", "\n }\n\n &.ve-outline {\n border: 1px solid var(--color-field-border, rgba(31, 56, 88, 0.05)) !important;\n }\n\n & > .react-monaco-editor-container {\n width: 100%;\n height: 100%;\n min-height: 100px;\n background: transparent;\n\n ", "\n\n .monaco-editor,\n .monaco-editor-background,\n .monaco-editor .inputarea.ime-input,\n .monaco-editor .margin {\n background-color: transparent;\n }\n\n & > .monaco-editor {\n border-radius: ", "px;\n .overflow-guard,\n .margin {\n border-top-left-radius: ", "px;\n border-bottom-left-radius: ", "px;\n }\n .monaco-scrollable-element {\n border-top-right-radius: ", "px;\n border-bottom-right-radius: ", "px;\n }\n }\n .monaco-diff-editor {\n border-radius: ", "px;\n & > .original > .monaco-editor {\n border-top-left-radius: ", "px;\n border-bottom-left-radius: ", "px;\n .overflow-guard,\n .margin {\n border-top-left-radius: ", "px;\n border-bottom-left-radius: ", "px;\n }\n }\n .diffViewport {\n border-top-right-radius: ", "px;\n border-bottom-right-radius: ", "px;\n }\n }\n }\n\n .syntaxTips {\n position: absolute;\n bottom: 0;\n left: 0;\n\n box-sizing: border-box;\n width: 100%;\n max-height: 0;\n margin: 0;\n padding: 10px 30px;\n\n color: red;\n\n background: rgba(255, 234, 234, 0.8);\n\n transition: 0.2s ease max-height;\n }\n\n .syntaxTips:hover {\n overflow: auto;\n max-height: 50%;\n }\n\n .syntaxTips .infoIcon {\n position: absolute;\n top: 2px;\n right: 5px;\n transform: rotateY(180deg);\n\n width: 20px;\n height: 16px;\n }\n "])), getBgColor(), variant === 'outlined' ? token.colorBorder : 'transparent', token.borderRadius, variant === 'outlined' ? token.colorPrimaryHover : 'transparent', variant === 'filled' && css(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral(["\n background-color: ", ";\n "])), token.colorFillSecondary), variant === 'filled' && css(_templateObject4 || (_templateObject4 = _taggedTemplateLiteral(["\n background-color: ", ";\n "])), token.colorBgBase), variant !== 'borderless' && css(_templateObject5 || (_templateObject5 = _taggedTemplateLiteral(["\n border-color: ", ";\n "])), token.colorPrimaryActive), isFullScreen && css(_templateObject6 || (_templateObject6 = _taggedTemplateLiteral(["\n position: fixed;\n z-index: 9998;\n inset: 0;\n\n width: auto !important;\n height: auto !important;\n "]))), token.borderRadius, token.borderRadius, token.borderRadius, token.borderRadius, token.borderRadius, token.borderRadius, token.borderRadius, token.borderRadius, token.borderRadius, token.borderRadius, token.borderRadius - 1, token.borderRadius - 1),
|
|
38
|
+
fullScreenBtn: css(_templateObject7 || (_templateObject7 = _taggedTemplateLiteral(["\n &.", "-btn {\n position: absolute;\n top: 20px;\n color: ", ";\n transition: none;\n ", "\n }\n "])), prefixCls, token.colorTextSecondary, isFullScreen ? css(_templateObject8 || (_templateObject8 = _taggedTemplateLiteral(["\n z-index: 9999;\n right: ", "px;\n "])), diff ? 64 : 138) : css(_templateObject9 || (_templateObject9 = _taggedTemplateLiteral(["\n right: ", "px;\n "])), minimapEnabled || diff ? 64 : 20)),
|
|
39
|
+
loading: css(_templateObject10 || (_templateObject10 = _taggedTemplateLiteral(["\n position: absolute;\n inset: 0;\n\n display: flex;\n align-items: center;\n justify-content: center;\n\n font-size: ", "px;\n color: ", ";\n\n background-color: transparent;\n\n &::after {\n content: '';\n width: 16px;\n /* display: inline; */\n animation: ", " steps(3) 1s infinite;\n }\n "])), token.fontSizeSM, token.colorTextTertiary, dots)
|
|
23
40
|
};
|
|
24
41
|
}, {
|
|
25
42
|
hashPriority: 'low'
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { Variant } from 'antd/es/config-provider';
|
|
1
2
|
import React from 'react';
|
|
2
3
|
import type { IDiffMonacoEditorProps, IGeneralManacoEditorProps, ISingleMonacoEditorProps } from './base/helper';
|
|
3
4
|
export { type EditorMeta, Controller as MonacoController } from './base/controller';
|
|
@@ -16,6 +17,8 @@ export interface BaseMonacoEditorProps extends IGeneralManacoEditorProps {
|
|
|
16
17
|
version?: string;
|
|
17
18
|
/** An event emitted when the content of the current model has changed. */
|
|
18
19
|
onChange?: (input: string, event: any) => void;
|
|
20
|
+
/** Variants of Editor, Defaults to outlined. */
|
|
21
|
+
variant?: Variant;
|
|
19
22
|
}
|
|
20
23
|
export declare const BaseMonacoEditor: React.FC<BaseMonacoEditorProps & {
|
|
21
24
|
/** Only for BaseMonacoEditor. */
|
package/es/Page/Page.d.ts
CHANGED
package/es/Radio/index.js
CHANGED
|
@@ -4,7 +4,6 @@ var _excluded = ["className"];
|
|
|
4
4
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
5
5
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
6
6
|
import { Radio as AntdRadio } from 'antd';
|
|
7
|
-
import AntdGroup from 'antd/es/radio/group';
|
|
8
7
|
import React from 'react';
|
|
9
8
|
import { useStyles } from "./style";
|
|
10
9
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
@@ -18,7 +17,7 @@ var Group = function Group(props) {
|
|
|
18
17
|
var _useStyles = useStyles(otherProps),
|
|
19
18
|
styles = _useStyles.styles,
|
|
20
19
|
cx = _useStyles.cx;
|
|
21
|
-
return /*#__PURE__*/_jsx(
|
|
20
|
+
return /*#__PURE__*/_jsx(AntdRadio.Group, _objectSpread(_objectSpread({}, otherProps), {}, {
|
|
22
21
|
className: cx(styles.custom, className)
|
|
23
22
|
}));
|
|
24
23
|
};
|
package/es/Table/index.d.ts
CHANGED
package/es/Typography/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Typography as AntdTypography } from 'antd';
|
|
2
|
+
import type { TooltipPropsWithTitle } from 'antd/es/tooltip';
|
|
2
3
|
import type { TextProps } from 'antd/es/typography/Text';
|
|
3
|
-
import type { TooltipPropsWithTitle } from 'antd/lib/tooltip';
|
|
4
4
|
import React from 'react';
|
|
5
5
|
export declare const Typography: TypographyProps;
|
|
6
6
|
interface TimeProps extends TextProps {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@yuntijs/ui",
|
|
3
|
-
"version": "1.0.0-beta.
|
|
3
|
+
"version": "1.0.0-beta.83",
|
|
4
4
|
"description": "☁️ Yunti UI - an open-source UI component library for building Cloud Native web apps",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"yuntijs",
|
|
@@ -83,17 +83,17 @@
|
|
|
83
83
|
"@alilc/lowcode-plugin-base-monaco-editor": "^1.1.2",
|
|
84
84
|
"@ant-design/icons": "^5",
|
|
85
85
|
"@babel/runtime": "^7",
|
|
86
|
-
"@lexical/react": "^0.
|
|
87
|
-
"@lexical/selection": "^0.
|
|
88
|
-
"@lexical/text": "^0.
|
|
89
|
-
"@lexical/utils": "^0.
|
|
86
|
+
"@lexical/react": "^0.23.1",
|
|
87
|
+
"@lexical/selection": "^0.23.1",
|
|
88
|
+
"@lexical/text": "^0.23.1",
|
|
89
|
+
"@lexical/utils": "^0.23.1",
|
|
90
90
|
"@lobehub/tts": "^1.25.1",
|
|
91
91
|
"@lobehub/ui": "^1.164.2",
|
|
92
92
|
"@melloware/react-logviewer": "^5.2.0",
|
|
93
93
|
"@monaco-editor/loader": "^1.4.0",
|
|
94
94
|
"@shikijs/transformers": "^1.10.3",
|
|
95
95
|
"leva": "^0",
|
|
96
|
-
"lexical": "^0.
|
|
96
|
+
"lexical": "^0.23.1",
|
|
97
97
|
"lodash-es": "^4",
|
|
98
98
|
"lucide-react": "latest",
|
|
99
99
|
"query-string": "^8",
|