Skip to content

Commit

Permalink
Fixed wrongly merged files
Browse files Browse the repository at this point in the history
  • Loading branch information
romanisa committed Oct 20, 2023
1 parent 027540e commit 768124a
Show file tree
Hide file tree
Showing 4 changed files with 0 additions and 27 deletions.
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { getDefaultStyle } from './getDefaultStyle';
import type { DomToModelContext } from 'roosterjs-content-model-types';

const BLOCK_DISPLAY_STYLES = ['block', 'list-item', 'table', 'table-cell', 'flex'];

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -92,30 +92,6 @@ describe('handleEntity', () => {
expect(entityUtils.addDelimiters).toHaveBeenCalledTimes(0);
});

it('Readonly fake entity', () => {
const div = document.createElement('div');
const entityModel: ContentModelEntity = {
blockType: 'Entity',
segmentType: 'Entity',
format: {},
wrapper: div,
entityFormat: {
isFakeEntity: true,
isReadonly: true,
},
};

div.textContent = 'test';

const parent = document.createElement('div');

handleEntityBlock(document, parent, entityModel, context, null);

expect(parent.innerHTML).toBe('<div contenteditable="false">test</div>');
expect(div.outerHTML).toBe('<div contenteditable="false">test</div>');
expect(addDelimiters.default).toHaveBeenCalledTimes(0);
});

it('Simple inline readonly entity', () => {
const span = document.createElement('span');
const entityModel: ContentModelEntity = {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { updateMetadata } from 'roosterjs-content-model-dom';
import type { ContentModelImage, ImageMetadataFormat } from 'roosterjs-content-model-types';
import {
createNumberDefinition,
createObjectDefinition,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ import type {

/**
* @internal
* Options for cloneModel API
*/
export type CachedElementHandler = (
node: HTMLElement,
Expand Down

0 comments on commit 768124a

Please sign in to comment.