fix: 修复 office-viewer 的 databar 显示不正确问题 (#9842)

* fix: 修复 office-viewer 的 databar 显示不正确问题

* 修复 ghpages 报错及 git clone 出错

* 补上 base16-dark 主题
This commit is contained in:
吴多益 2024-03-22 14:01:38 +08:00 committed by GitHub
parent ccc50420c4
commit 3ea2bb60e8
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
9 changed files with 12 additions and 13 deletions

Binary file not shown.

View File

@ -26,7 +26,6 @@
/>
<link rel="stylesheet" href="/node_modules/katex/dist/katex.min.css" />
<link rel="stylesheet" href="/node_modules/prismjs/themes/prism.css" />
<link rel="stylesheet" href="/node_modules/office-viewer/dist/office.css" />
<link rel="stylesheet" href="/examples/doc.css" />
<link rel="stylesheet" href="/examples/style.scss" />

View File

@ -1,8 +1,11 @@
@import '../../../node_modules/codemirror/lib/codemirror';
@import '../../../node_modules/codemirror/theme/base16-dark';
@import '../../../node_modules/codemirror/theme/idea';
@import '../../../node_modules/froala-editor/css/froala_style.min';
@import '../../../node_modules/froala-editor/css/froala_editor.pkgd.min';
@import '../../../node_modules/tinymce/skins/ui/oxide/skin';
@import '../../../node_modules/video-react/dist/video-react';
@import '../../../node_modules/cropperjs/dist/cropper';
@import '../../../node_modules/office-viewer/dist/office';
@import './components/react-datetime';

View File

@ -4,10 +4,6 @@ import type CodeMirror from 'codemirror';
import {autobind, changedEffect} from 'amis-core';
import {resizeSensor} from 'amis-core';
import 'codemirror/theme/idea.css';
import 'codemirror/theme/base16-dark.css';
// import 'codemirror/theme/base16-light.css';
export interface CodeMirrorEditorProps {
className?: string;
style?: any;

View File

@ -62,7 +62,7 @@
"moment": "^2.19.4",
"moment-timezone": "^0.5.34",
"mpegts.js": "^1.6.10",
"office-viewer": "^0.3.5",
"office-viewer": "^0.3.7",
"prop-types": "^15.6.1",
"qrcode.react": "^3.1.0",
"react-cropper": "^2.1.8",

View File

@ -1,6 +1,6 @@
{
"name": "office-viewer",
"version": "0.3.5",
"version": "0.3.7",
"description": "office 文档在线预览",
"main": "lib/index.js",
"module": "esm/index.js",
@ -116,4 +116,4 @@
"printBasicPrototype": false
}
}
}
}

View File

@ -3,8 +3,6 @@ import {DisplayData, Sheet} from '../../sheet/Sheet';
import {SheetCanvas} from '../SheetCanvas';
import {PADDING_SIZE} from '../Consts';
import {LinkPosition} from './LinkPosition';
import {CellInfo} from '../../types/CellInfo';
import {autoClip} from './autoClip';
import {CellInfoWithSize} from './CellInfoWithSize';
import type {ExcelRender} from '../ExcelRender';
@ -27,7 +25,11 @@ export function drawCells(
}
const cellInfo = currentSheet.getCellInfo(row, col);
if (cellInfo) {
cellInfoMap.set(`${row},${col}`, {...cellInfo, width, height});
cellInfoMap.set(`${row},${col}`, {
...JSON.parse(JSON.stringify(cellInfo)),
width,
height
});
}
}

View File

@ -4,8 +4,7 @@
import {Attributes} from '../../../openxml/Attributes';
import {CT_Color, CT_Color_Attributes} from '../CT_Color';
import {X14Sparkline, X14Sparkline_Attributes} from './X14Sparkline';
import {X14Sparklines, X14Sparklines_Attributes} from './x14:sparklines';
import {X14Sparklines, X14Sparklines_Attributes} from './x14Sparklines';
export type ST_SparklineAxisMinMax = 'individual' | 'groupMax' | 'group';