working on documentation
This commit is contained in:
@@ -381,7 +381,7 @@ class Canvas extends React.Component {
|
||||
for (let [key, widget] of Object.entries(this.widgetRefs)) {
|
||||
// since the mouseUp event is not triggered inside the widget once its outside,
|
||||
// we'll need a global mouse up event to re-enable drag
|
||||
widget.current.enableDrag()
|
||||
widget.current?.enableDrag()
|
||||
}
|
||||
}
|
||||
|
||||
@@ -918,6 +918,7 @@ class Canvas extends React.Component {
|
||||
|
||||
this.setState({
|
||||
toolbarAttrs: null,
|
||||
toolbarOpen: false,
|
||||
selectedWidget: null
|
||||
})
|
||||
|
||||
@@ -926,7 +927,7 @@ class Canvas extends React.Component {
|
||||
for (let widgetId of widgetIds) {
|
||||
this.removeWidget(widgetId)
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -93,9 +93,13 @@ export class TkinterBase extends Widget {
|
||||
parentLayout: layout,
|
||||
}
|
||||
|
||||
this.removeAttr("gridManager")
|
||||
this.removeAttr("flexManager")
|
||||
this.removeAttr("positioning")
|
||||
// this.removeAttr("gridManager")
|
||||
// this.removeAttr("flexManager")
|
||||
// this.removeAttr("positioning")
|
||||
|
||||
// remove gridManager, flexManager positioning
|
||||
const {gridManager, flexManager, positioning, ...restAttrs} = this.state.attrs
|
||||
|
||||
if (parentLayout === Layouts.FLEX || parentLayout === Layouts.GRID) {
|
||||
|
||||
updates = {
|
||||
@@ -104,7 +108,7 @@ export class TkinterBase extends Widget {
|
||||
}
|
||||
// Allow optional absolute positioning if the parent layout is flex or grid
|
||||
const updateAttrs = {
|
||||
...this.state.attrs,
|
||||
...restAttrs,
|
||||
positioning: {
|
||||
label: "Absolute positioning",
|
||||
tool: Tools.CHECK_BUTTON,
|
||||
|
||||
Reference in New Issue
Block a user