@skbkontur/markdown 1.11.1 → 1.11.3
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/package.json
CHANGED
package/src/Markdown/Markdown.js
CHANGED
|
@@ -58,7 +58,7 @@ export var Markdown = function (props) {
|
|
|
58
58
|
useLayoutEffect(function () {
|
|
59
59
|
var _a;
|
|
60
60
|
var textareaNode = (_a = textareaRef.current) === null || _a === void 0 ? void 0 : _a.node;
|
|
61
|
-
setInitialWidth(textareaNode.
|
|
61
|
+
setInitialWidth(textareaNode.clientWidth);
|
|
62
62
|
}, []);
|
|
63
63
|
useEffect(function () {
|
|
64
64
|
var _a;
|
|
@@ -85,7 +85,7 @@ export var getMarkdownReactUiTheme = function (theme, reactUiTheme, panelHorizon
|
|
|
85
85
|
textareaBorderTopColor: 'transparent',
|
|
86
86
|
textareaShadow: 'none',
|
|
87
87
|
})), (fullScreenTextareaPadding &&
|
|
88
|
-
__assign({ textareaBorderColor: 'transparent', textareaBorderColorFocus: 'transparent', textareaBorderTopColor: 'transparent', textareaShadow: 'none' }, extendThemeConfigWithSized({
|
|
88
|
+
__assign({ sidePagePaddingLeft: '0', sidePagePaddingRight: '0', textareaBorderColor: 'transparent', textareaBorderColorFocus: 'transparent', textareaBorderTopColor: 'transparent', textareaShadow: 'none' }, extendThemeConfigWithSized({
|
|
89
89
|
textareaMinHeight: '85vh',
|
|
90
90
|
textareaPaddingX: "".concat(fullScreenTextareaPadding, "px"),
|
|
91
91
|
textareaPaddingY: '0',
|
|
@@ -79,7 +79,7 @@ export var useFullscreenHorizontalPadding = function (fullscreen, textareaWidth)
|
|
|
79
79
|
var observable = document.body;
|
|
80
80
|
var handleChangeWidth_1 = function (width) { return setPadding((width - textareaWidth) / 2); };
|
|
81
81
|
handleChangeWidth_1(observable.clientWidth);
|
|
82
|
-
var observer_1 = new ResizeObserver(function (entries) { return entries.forEach(function (e) { return handleChangeWidth_1(e.
|
|
82
|
+
var observer_1 = new ResizeObserver(function (entries) { return entries.forEach(function (e) { return handleChangeWidth_1(e.target.clientWidth); }); });
|
|
83
83
|
observer_1.observe(observable);
|
|
84
84
|
return function () { return observer_1.disconnect(); };
|
|
85
85
|
}
|
|
@@ -12,7 +12,7 @@ export var Href = styled.a(templateObject_6 || (templateObject_6 = __makeTemplat
|
|
|
12
12
|
export var FileName = styled.span(templateObject_7 || (templateObject_7 = __makeTemplateObject(["\n white-space: pre-wrap;\n"], ["\n white-space: pre-wrap;\n"])));
|
|
13
13
|
export var ImgHref = styled.a(templateObject_8 || (templateObject_8 = __makeTemplateObject(["\n text-decoration: none !important;\n border: none !important;\n"], ["\n text-decoration: none !important;\n border: none !important;\n"])));
|
|
14
14
|
export var TableWrapper = styled.div(templateObject_9 || (templateObject_9 = __makeTemplateObject(["\n width: 100%;\n overflow-x: auto;\n"], ["\n width: 100%;\n overflow-x: auto;\n"])));
|
|
15
|
-
export var Table = styled.table(templateObject_10 || (templateObject_10 = __makeTemplateObject(["\n width:
|
|
15
|
+
export var Table = styled.table(templateObject_10 || (templateObject_10 = __makeTemplateObject(["\n width: 100%;\n min-width: 400px;\n"], ["\n width: 100%;\n min-width: 400px;\n"])));
|
|
16
16
|
export function getListStyle(depth) {
|
|
17
17
|
return depth ? { marginTop: 4 } : { marginBottom: 16 };
|
|
18
18
|
}
|