Skip to content

Commit

Permalink
fix(core): rename textInput
Browse files Browse the repository at this point in the history
  • Loading branch information
wumail authored and boyongjiong committed Nov 1, 2023
1 parent 8a8a0f9 commit 1681484
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion packages/core/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -504,7 +504,7 @@
edgeTextDraggable: true,
edgeType: 'bezier',
style: {
textInput: {
inputText: {
background: 'black',
}
},
Expand Down
2 changes: 1 addition & 1 deletion packages/core/src/constant/DefaultTheme.ts
Original file line number Diff line number Diff line change
Expand Up @@ -282,7 +282,7 @@ export type Theme = {
* 节点旋转控制点样式
*/
rotateControl?: CommonTheme,
textInput?: CommonTheme,
inputText?: CommonTheme,
};

export const defaultTheme: Theme = {
Expand Down
4 changes: 2 additions & 2 deletions packages/core/src/tool/TextEditTool.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ export default class TextEdit extends Component<IProps, IState> {
static getDerivedStateFromProps(props) {
const { graphModel } = props;
const { transformModel, theme } = graphModel;
const { textInput } = theme;
const { inputText } = theme;
let { textEditElement } = graphModel;
let autoStyle;
if (textEditElement) {
Expand Down Expand Up @@ -107,7 +107,7 @@ export default class TextEdit extends Component<IProps, IState> {
left,
top,
...autoStyle,
...textInput,
...inputText,
},
};
}
Expand Down

0 comments on commit 1681484

Please sign in to comment.