Skip to content

Commit

Permalink
Merge pull request #761 from FDMediagroep/updated-dependencies
Browse files Browse the repository at this point in the history
Updated dependencies
  • Loading branch information
willemliufdmg authored Sep 5, 2024
2 parents c3d88ca + 3e3f9fd commit b97bcf5
Show file tree
Hide file tree
Showing 4 changed files with 25 additions and 21 deletions.
2 changes: 1 addition & 1 deletion next-env.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@
/// <reference types="next/image-types/global" />

// NOTE: This file should not be edited
// see https://nextjs.org/docs/basic-features/typescript for more information.
// see https://nextjs.org/docs/pages/building-your-application/configuring/typescript for more information.
26 changes: 13 additions & 13 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,11 +33,11 @@
"@types/fetch-jsonp": "^1.1.0",
"@types/micro-cors": "^0.1.5",
"@types/node": "^22.5.4",
"@types/react": "^18.3.4",
"@types/react": "^18.3.5",
"@types/react-dom": "^18.3.0",
"@types/xmldom": "^0.1.34",
"@webcomponents/webcomponentsjs": "^2.8.0",
"@xmldom/xmldom": "^0.8.10",
"@xmldom/xmldom": "^0.9.1",
"autoprefixer": "^10.4.20",
"copy-webpack-plugin": "^12.0.2",
"copyfiles": "^2.4.1",
Expand All @@ -62,7 +62,7 @@
"prettier": "^3.3.3",
"react": "^18.3.1",
"react-dom": "^18.3.1",
"sass": "^1.77.8",
"sass": "^1.78.0",
"sass-loader": "^16.0.1",
"ts-loader": "^9.5.1",
"typescript": "^5.5.4",
Expand Down
12 changes: 8 additions & 4 deletions src/utils/articleContent.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ import { TextFrame } from '@fdmg/design-system/components/textframe/TextFrame';
import { LinkBlock } from '@fdmg/design-system/components/article-link-block/LinkBlock';
import { Vimeo } from '@fdmg/design-system/components/vimeo/Vimeo';
import { Youtube } from '@fdmg/design-system/components/youtube/Youtube';
import { XMLSerializer } from '@xmldom/xmldom';
import { XMLSerializer, Node } from '@xmldom/xmldom';
import {
BulletPoint,
Alignment,
Expand All @@ -25,12 +25,14 @@ function innerHTML(node: Element, tagName?: string) {
return '';
}
return new XMLSerializer()
.serializeToString(node.getElementsByTagName(tagName).item(0))
.serializeToString(
node.getElementsByTagName(tagName).item(0) as unknown as Node
)
.replace(`<${tagName}>`, '')
.replace(`</${tagName}>`, '');
} else {
return new XMLSerializer()
.serializeToString(node)
.serializeToString(node as unknown as Node)
.replace(`<${node.nodeName}>`, '')
.replace(`</${node.nodeName}>`, '');
}
Expand Down Expand Up @@ -273,7 +275,9 @@ export function mergeInlineContent(doc: any) {
);
} else {
console.log(
new XMLSerializer().serializeToString(childNode)
new XMLSerializer().serializeToString(
childNode as unknown as Node
)
);
}
}
Expand Down

0 comments on commit b97bcf5

Please sign in to comment.