* Detect WPS (Kingsoft Office / WPS Office) by checking for known markers * in the presentation XML string.
(presentationXml: string)
| 53 | * in the presentation XML string. |
| 54 | */ |
| 55 | function detectWps(presentationXml: string): boolean { |
| 56 | return ( |
| 57 | /\bKingsoft\b/i.test(presentationXml) || |
| 58 | /\bWPS Office\b/i.test(presentationXml) || |
| 59 | /xmlns:[\w.-]*kso[\w.-]*=/i.test(presentationXml) |
| 60 | ) |
| 61 | } |
| 62 | |
| 63 | /** |
| 64 | * Find a rels entry by type substring match. |
no test coverage detected