lint
This commit is contained in:
		
							parent
							
								
									bf05061cc7
								
							
						
					
					
						commit
						b63d22e7db
					
				@ -77,7 +77,7 @@ export const testDiffStateVectorOfUpdateIsEmpty = tc => {
 | 
				
			|||||||
  /**
 | 
					  /**
 | 
				
			||||||
   * @type {null | Uint8Array}
 | 
					   * @type {null | Uint8Array}
 | 
				
			||||||
   */
 | 
					   */
 | 
				
			||||||
  let sv = /* any */ (null)
 | 
					  let sv = /** @type {any} */ (null)
 | 
				
			||||||
  ydoc.getText().insert(0, 'a')
 | 
					  ydoc.getText().insert(0, 'a')
 | 
				
			||||||
  ydoc.on('update', update => {
 | 
					  ydoc.on('update', update => {
 | 
				
			||||||
    sv = Y.encodeStateVectorFromUpdate(update)
 | 
					    sv = Y.encodeStateVectorFromUpdate(update)
 | 
				
			||||||
 | 
				
			|||||||
@ -273,7 +273,7 @@ export const testUndoInEmbed = tc => {
 | 
				
			|||||||
 */
 | 
					 */
 | 
				
			||||||
export const testUndoDeleteFilter = tc => {
 | 
					export const testUndoDeleteFilter = tc => {
 | 
				
			||||||
  /**
 | 
					  /**
 | 
				
			||||||
   * @type {Array<Y.Map<any>>}
 | 
					   * @type {Y.Array<any>}
 | 
				
			||||||
   */
 | 
					   */
 | 
				
			||||||
  const array0 = /** @type {any} */ (init(tc, { users: 3 }).array0)
 | 
					  const array0 = /** @type {any} */ (init(tc, { users: 3 }).array0)
 | 
				
			||||||
  const undoManager = new Y.UndoManager(array0, { deleteFilter: item => !(item instanceof Y.Item) || (item.content instanceof Y.ContentType && item.content.type._map.size === 0) })
 | 
					  const undoManager = new Y.UndoManager(array0, { deleteFilter: item => !(item instanceof Y.Item) || (item.content instanceof Y.ContentType && item.content.type._map.size === 0) })
 | 
				
			||||||
 | 
				
			|||||||
@ -563,7 +563,7 @@ const arrayTransactions = [
 | 
				
			|||||||
      return
 | 
					      return
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
    const pos = prng.int32(gen, 0, yarray.length - 1)
 | 
					    const pos = prng.int32(gen, 0, yarray.length - 1)
 | 
				
			||||||
    const len = 1 // prng.int32(gen, 1, math.min(3, yarray.length - pos)) @todo!
 | 
					    const len = prng.int32(gen, 1, math.min(1, yarray.length - pos))
 | 
				
			||||||
    const _newPosAdj = prng.int32(gen, 0, yarray.length - len)
 | 
					    const _newPosAdj = prng.int32(gen, 0, yarray.length - len)
 | 
				
			||||||
    // make sure that we don't insert in-between the moved range
 | 
					    // make sure that we don't insert in-between the moved range
 | 
				
			||||||
    const newPos = _newPosAdj + (_newPosAdj > yarray.length - len ? len : 0)
 | 
					    const newPos = _newPosAdj + (_newPosAdj > yarray.length - len ? len : 0)
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user