mirror of
https://github.com/ether/etherpad-lite.git
synced 2025-04-22 08:26:16 -04:00
export: txt import include correct OL prefix (#4086)
Includes test coverage Final part of solving https://github.com/ether/etherpad-lite/issues/3447
This commit is contained in:
parent
423be7f081
commit
aff93d24dd
2 changed files with 55 additions and 5 deletions
|
@ -36,8 +36,19 @@ var testImports = {
|
|||
expectedHTML: '<!DOCTYPE HTML><html><body><ul class="bullet"><li>FOO</ul><br></body></html>',
|
||||
expectedText: '\t* FOO\n\n'
|
||||
},
|
||||
"prefixcorrectlinenumber":{
|
||||
input: '<html><body><ol><li>should be 1</li><li>should be 2</li></ol></body></html>',
|
||||
expectedHTML: '<!DOCTYPE HTML><html><body><ol start="1" class="number"><li>should be 1</li><li>should be 2</ol><br></body></html>',
|
||||
expectedText: '\t1. should be 1\n\t2. should be 2\n\n'
|
||||
},
|
||||
"prefixcorrectlinenumbernested":{
|
||||
input: '<html><body><ol><li>should be 1</li><ol><li>foo</li></ol><li>should be 2</li></ol></body></html>',
|
||||
expectedHTML: '<!DOCTYPE HTML><html><body><ol start="1" class="number"><li>should be 1<ol start="2" class="number"><li>foo</ol><li>should be 2</ol><br></body></html>',
|
||||
expectedText: '\t1. should be 1\n\t\t1.1. foo\n\t2. should be 2\n\n'
|
||||
},
|
||||
|
||||
/*
|
||||
"prefixcorrectlinenumber #3450":{
|
||||
"prefixcorrectlinenumber when introduced none list item - currently not supported see #3450":{
|
||||
input: '<html><body><ol><li>should be 1</li>test<li>should be 2</li></ol></body></html>',
|
||||
expectedHTML: '<!DOCTYPE HTML><html><body><ol start="1" class="number"><li>should be 1</li>test<li>should be 2</li></ol><br></body></html>',
|
||||
expectedText: '\t1. should be 1\n\ttest\n\t2. should be 2\n\n'
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue