@lobehub/ui 2.7.0 → 2.7.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/es/Markdown/Markdown.js
CHANGED
|
@@ -89,15 +89,10 @@ var Markdown = /*#__PURE__*/memo(function (_ref) {
|
|
|
89
89
|
defaultVariants: {
|
|
90
90
|
animated: false,
|
|
91
91
|
enableLatex: true,
|
|
92
|
-
gfm: true,
|
|
93
92
|
variant: 'default'
|
|
94
93
|
},
|
|
95
94
|
/* eslint-disable sort-keys-fix/sort-keys-fix */
|
|
96
95
|
variants: {
|
|
97
|
-
gfm: {
|
|
98
|
-
true: styles.gfm,
|
|
99
|
-
false: null
|
|
100
|
-
},
|
|
101
96
|
variant: {
|
|
102
97
|
default: null,
|
|
103
98
|
chat: styles.chat
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7, _templateObject8, _templateObject9, _templateObject10, _templateObject11, _templateObject12, _templateObject13, _templateObject14, _templateObject15, _templateObject16;
|
|
1
|
+
var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7, _templateObject8, _templateObject9, _templateObject10, _templateObject11, _templateObject12, _templateObject13, _templateObject14, _templateObject15, _templateObject16, _templateObject17;
|
|
2
2
|
function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
|
|
3
3
|
import { createStyles } from 'antd-style';
|
|
4
4
|
var IGNORE_CLASSNAME = '.ignore-markdown-style';
|
|
@@ -30,8 +30,9 @@ export var useStyles = createStyles(function (_ref, _ref2) {
|
|
|
30
30
|
var svg = css(_templateObject14 || (_templateObject14 = _taggedTemplateLiteral(["\n svg:not(", " svg) {\n line-height: 1;\n }\n "])), IGNORE_CLASSNAME);
|
|
31
31
|
var table = css(_templateObject15 || (_templateObject15 = _taggedTemplateLiteral(["\n table:not(", " table) {\n unicode-bidi: isolate;\n overflow: auto hidden;\n display: block;\n border-spacing: 0;\n border-collapse: collapse;\n\n box-sizing: border-box;\n width: max-content;\n max-width: 100%;\n margin-block: calc(var(--lobe-markdown-margin-multiple) * 0.5em);\n border-radius: calc(var(--lobe-markdown-border-radius) * 1px);\n\n text-align: start;\n text-indent: initial;\n text-wrap: pretty;\n word-break: auto-phrase;\n overflow-wrap: break-word;\n\n background: ", ";\n box-shadow: 0 0 0 1px var(--lobe-markdown-border-color);\n\n code {\n word-break: break-word;\n }\n\n thead {\n background: ", ";\n }\n\n tr {\n box-shadow: 0 1px 0 var(--lobe-markdown-border-color);\n }\n\n th,\n td {\n min-width: 120px;\n padding-block: 0.75em;\n padding-inline: 1em;\n text-align: start;\n }\n }\n "])), IGNORE_CLASSNAME, token.colorFillQuaternary, token.colorFillQuaternary);
|
|
32
32
|
var video = css(_templateObject16 || (_templateObject16 = _taggedTemplateLiteral(["\n > video:not(", " video),\n > p:not(", " p) > video {\n margin-block: calc(var(--lobe-markdown-margin-multiple) * 0.5em);\n border-radius: calc(var(--lobe-markdown-border-radius) * 1px);\n box-shadow: 0 0 0 1px var(--lobe-markdown-border-color);\n }\n\n video:not(", " video) {\n max-width: 100%;\n }\n "])), IGNORE_CLASSNAME, IGNORE_CLASSNAME, IGNORE_CLASSNAME);
|
|
33
|
+
var gfm = css(_templateObject17 || (_templateObject17 = _taggedTemplateLiteral(["\n .markdown-alert {\n margin-block: calc(var(--lobe-markdown-margin-multiple) * 0.5em);\n padding-inline-start: 1em;\n border-inline-start: solid 4px ", ";\n\n > p {\n margin-block-start: 0 !important;\n }\n }\n\n .markdown-alert > :first-child {\n margin-block-start: 0;\n }\n\n .markdown-alert > :last-child {\n margin-block-end: 0;\n }\n\n .markdown-alert-note {\n border-inline-start-color: ", ";\n }\n\n .markdown-alert-tip {\n border-inline-start-color: ", ";\n }\n\n .markdown-alert-important {\n border-inline-start-color: ", ";\n }\n\n .markdown-alert-warning {\n border-inline-start-color: ", ";\n }\n\n .markdown-alert-caution {\n border-inline-start-color: ", ";\n }\n\n .markdown-alert-title {\n display: flex;\n align-items: center;\n margin-block-end: 0.5em !important;\n font-weight: 500;\n }\n\n .markdown-alert-note .markdown-alert-title {\n color: ", ";\n fill: ", ";\n }\n\n .markdown-alert-tip .markdown-alert-title {\n color: ", ";\n fill: ", ";\n }\n\n .markdown-alert-important .markdown-alert-title {\n color: ", ";\n fill: ", ";\n }\n\n .markdown-alert-warning .markdown-alert-title {\n color: ", ";\n fill: ", ";\n }\n\n .markdown-alert-caution .markdown-alert-title {\n color: ", ";\n fill: ", ";\n }\n\n .octicon {\n overflow: visible !important;\n display: inline-block;\n margin-inline-end: 0.5em;\n vertical-align: text-bottom;\n }\n\n .task-list-item {\n &::before {\n display: none !important;\n }\n\n input[type='checkbox'] {\n margin-block: 0 0.25em;\n margin-inline: -1.6em 0.2em;\n vertical-align: middle;\n }\n\n input[type='checkbox']:dir(rtl) {\n margin: 0 -1.6em 0.25em 0.2em;\n }\n }\n\n /* Style the footnotes section. */\n\n .footnotes {\n margin-block-start: calc(var(--lobe-markdown-margin-multiple) * 1em);\n font-size: smaller;\n color: #8b949e;\n\n #footnote-label {\n display: none;\n }\n\n > ol {\n margin: 0 !important;\n }\n }\n\n .sr-only {\n position: absolute;\n\n overflow: hidden;\n\n width: 1px;\n height: 1px;\n padding: 0;\n border: 0;\n\n word-wrap: normal;\n\n clip: rect(0, 0, 0, 0);\n }\n\n sup:has(a[aria-describedby='footnote-label']) {\n margin-inline: 2px;\n vertical-align: super !important;\n\n [data-footnote-ref] {\n display: inline-block;\n\n width: 16px;\n height: 16px;\n border-radius: 4px;\n\n font-family: ", ";\n font-size: 10px;\n color: ", " !important;\n text-align: center;\n\n background: ", ";\n }\n }\n "])), token.colorBorder, token.colorInfo, token.colorSuccess, token.purple, token.colorWarning, token.colorError, token.colorInfo, token.colorInfo, token.colorSuccess, token.colorSuccess, token.purple, token.purple, token.colorWarning, token.colorWarning, token.colorError, token.colorError, token.fontFamilyCode, token.colorTextSecondary, token.colorFillSecondary);
|
|
33
34
|
return {
|
|
34
35
|
root: __root,
|
|
35
|
-
variant: cx(a, blockquote, code, details, header, hr, img, kbd, list, p, pre, strong, svg, table, video)
|
|
36
|
+
variant: cx(a, blockquote, code, details, header, hr, img, kbd, list, p, pre, strong, svg, table, video, gfm)
|
|
36
37
|
};
|
|
37
38
|
});
|
package/es/Markdown/style.d.ts
CHANGED
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
export declare const useStyles: (props?: unknown) => import("antd-style").ReturnStyles<{
|
|
2
2
|
animated: import("antd-style").SerializedStyles;
|
|
3
3
|
chat: import("antd-style").SerializedStyles;
|
|
4
|
-
gfm: import("antd-style").SerializedStyles;
|
|
5
4
|
latex: import("antd-style").SerializedStyles;
|
|
6
5
|
root: import("antd-style").SerializedStyles;
|
|
7
6
|
}>;
|
package/es/Markdown/style.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5
|
|
1
|
+
var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5;
|
|
2
2
|
function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
|
|
3
3
|
import { createStyles, keyframes } from 'antd-style';
|
|
4
4
|
export var useStyles = createStyles(function (_ref) {
|
|
@@ -10,8 +10,7 @@ export var useStyles = createStyles(function (_ref) {
|
|
|
10
10
|
return {
|
|
11
11
|
animated: css(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n .animate-fade-in,\n .katex-html span,\n span.line > span,\n code:not(:has(span.line)),\n > * {\n animation: ", " 1s ease-in-out;\n }\n "])), fadeIn),
|
|
12
12
|
chat: css(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral(["\n --lobe-markdown-border-radius: ", ";\n\n ol,\n ul {\n > li {\n &::marker {\n color: ", " !important;\n }\n\n > li {\n &::marker {\n color: ", " !important;\n }\n }\n }\n }\n\n ul {\n list-style: unset;\n\n > li {\n &::before {\n content: unset;\n display: unset;\n }\n }\n }\n "])), token.borderRadius, cyanColor, token.colorTextSecondary),
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
root: css(_templateObject6 || (_templateObject6 = _taggedTemplateLiteral(["\n position: relative;\n overflow: hidden;\n max-width: 100%;\n "])))
|
|
13
|
+
latex: css(_templateObject4 || (_templateObject4 = _taggedTemplateLiteral(["\n .katex-error {\n color: ", " !important;\n }\n\n .katex-html {\n overflow: auto hidden;\n padding: 3px;\n\n .base {\n margin-block: 0;\n margin-inline: auto;\n }\n\n .tag {\n position: relative !important;\n display: inline-block;\n padding-inline-start: 0.5rem;\n }\n }\n "])), token.colorTextDescription),
|
|
14
|
+
root: css(_templateObject5 || (_templateObject5 = _taggedTemplateLiteral(["\n position: relative;\n overflow: hidden;\n max-width: 100%;\n "])))
|
|
16
15
|
};
|
|
17
16
|
});
|