insert method
Implementation
@override
void insert(int index, Object data, Style? style) {
final length = this.length;
assert(index >= 0 && index <= length);
final node = Leaf(data);
if (index < length) {
splitAt(index)!.insertBefore(node);
} else {
insertAfter(node);
}
node.format(style);
}