File tree 2 files changed +6
-3
lines changed
packages/amis-editor-core/src
2 files changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -218,12 +218,14 @@ export default class Breadcrumb extends React.Component<
218
218
const nearby : Array < EditorNodeType > = (
219
219
item . parent as EditorNodeType
220
220
) ?. uniqueChildren ;
221
-
221
+ const region =
222
+ item . region ||
223
+ item . childRegions . find ( ( i : any ) => i . region ) ?. region ;
222
224
return (
223
225
< li key = { index } >
224
226
< span
225
227
data-node-id = { item . id }
226
- data-node-region = { item . region }
228
+ data-node-region = { region }
227
229
onClick = { this . handleClick }
228
230
onMouseEnter = { this . handleMouseEnter }
229
231
>
Original file line number Diff line number Diff line change @@ -260,6 +260,7 @@ export class BasicToolbarPlugin extends BasePlugin {
260
260
const node = store . getNodeById ( id ) ! ;
261
261
const paths = store . getNodePathById ( id ) ;
262
262
const first = paths . pop ( ) ! ;
263
+ region = region || node . childRegions . find ( i => i . region ) ?. region ;
263
264
const host = node . host as EditorNodeType ;
264
265
const regionNode = node . parent as EditorNodeType ;
265
266
@@ -279,7 +280,7 @@ export class BasicToolbarPlugin extends BasePlugin {
279
280
id : 'unselect' ,
280
281
label : '取消多选' ,
281
282
icon : 'cancel-icon' ,
282
- onSelect : ( ) => store . setActiveId ( id )
283
+ onSelect : ( ) => store . setActiveId ( id , region )
283
284
} ) ;
284
285
285
286
menus . push ( {
You can’t perform that action at this time.
0 commit comments