(index = 0, length = Number.MAX_VALUE)
| 232 | } |
| 233 | |
| 234 | lines(index = 0, length = Number.MAX_VALUE): (Block | BlockEmbed)[] { |
| 235 | const getLines = ( |
| 236 | blot: ParentBlot, |
| 237 | blotIndex: number, |
| 238 | blotLength: number, |
| 239 | ) => { |
| 240 | let lines: (Block | BlockEmbed)[] = []; |
| 241 | let lengthLeft = blotLength; |
| 242 | blot.children.forEachAt( |
| 243 | blotIndex, |
| 244 | blotLength, |
| 245 | (child, childIndex, childLength) => { |
| 246 | if (isLine(child)) { |
| 247 | lines.push(child); |
| 248 | } else if (child instanceof ContainerBlot) { |
| 249 | lines = lines.concat(getLines(child, childIndex, lengthLeft)); |
| 250 | } |
| 251 | lengthLeft -= childLength; |
| 252 | }, |
| 253 | ); |
| 254 | return lines; |
| 255 | }; |
| 256 | return getLines(this, index, length); |
| 257 | } |
| 258 | |
| 259 | optimize(context?: { [key: string]: any }): void; |
| 260 | optimize( |
no outgoing calls
no test coverage detected