Skip to content

Commit 8d9224a

Browse files
committed
fix(heuristic-table): ignoring overrideContentWidth option
1 parent 3a75cbe commit 8d9224a

File tree

3 files changed

+4
-1
lines changed

3 files changed

+4
-1
lines changed

packages/heuristic-table-plugin/src/HTMLTable.tsx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,11 +36,12 @@ function Container({
3636
const HTMLTable = memo(function HTMLTable({
3737
layout,
3838
TDefaultRenderer,
39+
settings,
3940
config,
4041
...props
4142
}: HTMLTableProps) {
4243
const tableWidth = layout.totalWidth;
43-
const containerWidth = props.sharedProps.contentWidth;
44+
const containerWidth = settings.contentWidth;
4445
return (
4546
<TDefaultRenderer
4647
{...props}

packages/heuristic-table-plugin/src/shared-types.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -167,6 +167,7 @@ export interface HeuristicTablePluginConfig {
167167
export interface HTMLTableProps extends CustomTagRendererProps<TBlock> {
168168
layout: TableLayout;
169169
config: HeuristicTablePluginConfig;
170+
settings: Settings;
170171
}
171172

172173
/**

packages/heuristic-table-plugin/src/useHtmlTableProps.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,7 @@ export default function useHtmlTableProps(
5353
const layout = useTableLayout({ tnode, settings });
5454
return {
5555
layout,
56+
settings,
5657
config: table || {},
5758
sharedProps,
5859
tnode,

0 commit comments

Comments
 (0)