fix(editor): remove selection when click New Record button (#11073)
fix: BS-2847
This commit is contained in:
@@ -52,8 +52,9 @@ export class MobileTableGroup extends SignalWatcher(
|
|||||||
|
|
||||||
private readonly clickAddRow = () => {
|
private readonly clickAddRow = () => {
|
||||||
this.view.rowAdd('end', this.group?.key);
|
this.view.rowAdd('end', this.group?.key);
|
||||||
requestAnimationFrame(() => {
|
|
||||||
const selectionController = this.viewEle.selectionController;
|
const selectionController = this.viewEle.selectionController;
|
||||||
|
selectionController.selection = undefined;
|
||||||
|
requestAnimationFrame(() => {
|
||||||
const index = this.view.properties$.value.findIndex(
|
const index = this.view.properties$.value.findIndex(
|
||||||
v => v.type$.value === 'title'
|
v => v.type$.value === 'title'
|
||||||
);
|
);
|
||||||
@@ -70,8 +71,9 @@ export class MobileTableGroup extends SignalWatcher(
|
|||||||
|
|
||||||
private readonly clickAddRowInStart = () => {
|
private readonly clickAddRowInStart = () => {
|
||||||
this.view.rowAdd('start', this.group?.key);
|
this.view.rowAdd('start', this.group?.key);
|
||||||
requestAnimationFrame(() => {
|
|
||||||
const selectionController = this.viewEle.selectionController;
|
const selectionController = this.viewEle.selectionController;
|
||||||
|
selectionController.selection = undefined;
|
||||||
|
requestAnimationFrame(() => {
|
||||||
const index = this.view.properties$.value.findIndex(
|
const index = this.view.properties$.value.findIndex(
|
||||||
v => v.type$.value === 'title'
|
v => v.type$.value === 'title'
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -69,8 +69,9 @@ export class TableGroup extends SignalWatcher(
|
|||||||
|
|
||||||
private readonly clickAddRow = () => {
|
private readonly clickAddRow = () => {
|
||||||
this.view.rowAdd('end', this.group?.key);
|
this.view.rowAdd('end', this.group?.key);
|
||||||
requestAnimationFrame(() => {
|
|
||||||
const selectionController = this.viewEle.selectionController;
|
const selectionController = this.viewEle.selectionController;
|
||||||
|
selectionController.selection = undefined;
|
||||||
|
requestAnimationFrame(() => {
|
||||||
const index = this.view.properties$.value.findIndex(
|
const index = this.view.properties$.value.findIndex(
|
||||||
v => v.type$.value === 'title'
|
v => v.type$.value === 'title'
|
||||||
);
|
);
|
||||||
@@ -87,8 +88,9 @@ export class TableGroup extends SignalWatcher(
|
|||||||
|
|
||||||
private readonly clickAddRowInStart = () => {
|
private readonly clickAddRowInStart = () => {
|
||||||
this.view.rowAdd('start', this.group?.key);
|
this.view.rowAdd('start', this.group?.key);
|
||||||
requestAnimationFrame(() => {
|
|
||||||
const selectionController = this.viewEle.selectionController;
|
const selectionController = this.viewEle.selectionController;
|
||||||
|
selectionController.selection = undefined;
|
||||||
|
requestAnimationFrame(() => {
|
||||||
const index = this.view.properties$.value.findIndex(
|
const index = this.view.properties$.value.findIndex(
|
||||||
v => v.type$.value === 'title'
|
v => v.type$.value === 'title'
|
||||||
);
|
);
|
||||||
|
|||||||
Reference in New Issue
Block a user