Skip to content
This repository has been archived by the owner on Oct 18, 2024. It is now read-only.

Commit

Permalink
refactor(geogebra): Remove hack to fix sizing
Browse files Browse the repository at this point in the history
  • Loading branch information
LarsTheGlidingSquirrel committed Mar 18, 2024
1 parent a4eb45a commit 54331f2
Showing 1 changed file with 1 addition and 17 deletions.
18 changes: 1 addition & 17 deletions src/frontend/plugins/create-renderers.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,23 +18,7 @@ export function createRenderers(): ReturnType<typeof createBasicRenderers> {
type: 'serloInjection',
renderer: SerloInjectionStaticRenderer,
},
...pluginRenderers.map((pluginRenderer) => {
// If geogebra, wrap the renderer inside a aspect-ratio 16/9 block so that the geogebra embed gets scaled correctly. In frontend this is implicitly done by PrivacyWrapper, which we do not have here.
if (pluginRenderer.type === EditorPluginType.Geogebra) {
return {
type: EditorPluginType.Geogebra,
renderer: (props) => {
return (
<div className="relative pb-[56.2%]">
<pluginRenderer.renderer {...props} />
</div>
)
},
}
}
// Else, return renderer without modification
return pluginRenderer
}),
...pluginRenderers,
],
...otherRenderers,
linkRenderer: ({ href, children }) => {
Expand Down

0 comments on commit 54331f2

Please sign in to comment.