@@ -530,6 +530,38 @@ public void TestIssue5()
530530 Assert . Contains ( "<w:hyperlink w:tgtFrame=\" _blank\" " , xml ) ;
531531 }
532532
533+ [ Fact ]
534+ public void TestIssue_MiniWordHyperLinkList ( )
535+ {
536+ var path = PathHelper . GetTempFilePath ( ) ;
537+ var templatePath = PathHelper . GetFile ( "TestBasicFill.docx" ) ;
538+ var value = new Dictionary < string , object > ( )
539+ {
540+ [ "Name" ] = new List < MiniWordHyperLink > ( ) {
541+ new MiniWordHyperLink ( ) {
542+ Url = "https://google.com" ,
543+ Text = "測試連結22!!"
544+ } ,
545+ new MiniWordHyperLink ( ) {
546+ Url = "https://google.com" ,
547+ Text = "測試連結11!!"
548+ }
549+ } ,
550+ [ "Company_Name" ] = "MiniSofteware" ,
551+ [ "CreateDate" ] = new DateTime ( 2021 , 01 , 01 ) ,
552+ [ "VIP" ] = true ,
553+ [ "Points" ] = 123 ,
554+ [ "APP" ] = "Demo APP" ,
555+ } ;
556+ MiniWord . SaveAsByTemplate ( path , templatePath , value ) ;
557+ //Console.WriteLine(path);
558+ var xml = Helpers . GetZipFileContent ( path , "word/document.xml" ) ;
559+ Assert . DoesNotContain ( "Jack Demo APP Account Data" , xml ) ;
560+ Assert . Contains ( "MiniSofteware Demo APP Account Data" , xml ) ;
561+ Assert . Contains ( "MiniSofteware Demo APP Account Data" , xml ) ;
562+ Assert . Contains ( "<w:hyperlink w:tgtFrame=\" _blank\" " , xml ) ;
563+ }
564+
533565 /// <summary>
534566 /// [Fuzzy Regex replace similar key · Issue #5 · mini-software/MiniWord](https://github.com/mini-software/MiniWord/issues/5)
535567 /// </summary>
0 commit comments