Skip to content

Commit

Permalink
chore: change editor unit name
Browse files Browse the repository at this point in the history
  • Loading branch information
wzhudev committed Jun 18, 2024
1 parent 48a1c9f commit d0b8c91
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
8 changes: 4 additions & 4 deletions packages/core/src/common/const.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,16 +14,16 @@
* limitations under the License.
*/

export const DOCS_NORMAL_EDITOR_UNIT_ID_KEY = '__defaultDocumentNormalEditorSpecialUnitId_20231006__';
export const DOCS_NORMAL_EDITOR_UNIT_ID_KEY = '__INTERNAL_EDITOR__DOCS_NORMAL';

export const DOCS_FORMULA_BAR_EDITOR_UNIT_ID_KEY = '__defaultDocumentFormulaBarEditorSpecialUnitId_20231012__';
export const DOCS_FORMULA_BAR_EDITOR_UNIT_ID_KEY = '__INTERNAL_EDITOR__DOCS_FORMULA_BAR';

export const DEFAULT_EMPTY_DOCUMENT_VALUE = '\r\n';

export function createInternalEditorID(id: string) {
return `__internalEditorId__${id}`;
return `__INTERNAL_EDITOR__${id}`;
}

export function isInternalEditorID(id: string) {
return id.startsWith('__');
return id.startsWith('__INTERNAL_EDITOR__');
}
2 changes: 1 addition & 1 deletion packages/core/src/services/instance/instance.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ export interface IUniverInstanceService {
/** Subscribe to curtain type of units' creation. */
getTypeOfUnitAdded$<T extends UnitModel>(type: UnitType): Observable<T>;

/** @interal */
/** @ignore */
__addUnit(unit: UnitModel): void;

/** Omits value when a UnitModel is disposed. */
Expand Down

0 comments on commit d0b8c91

Please sign in to comment.