mirror of
https://github.com/microsoft/vscode.git
synced 2025-12-24 12:19:20 +00:00
Remove usages of in (#276333)
* Remove usages of in * Update extensions/ipynb/src/serializers.ts Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> --------- Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
This commit is contained in:
@@ -76,8 +76,8 @@ const domEval = (container: Element) => {
|
||||
};
|
||||
|
||||
function getAltText(outputInfo: OutputItem) {
|
||||
const metadata = outputInfo.metadata;
|
||||
if (typeof metadata === 'object' && metadata && 'vscode_altText' in metadata && typeof metadata.vscode_altText === 'string') {
|
||||
const metadata = outputInfo.metadata as Record<string, unknown> | undefined;
|
||||
if (typeof metadata === 'object' && metadata && typeof metadata.vscode_altText === 'string') {
|
||||
return metadata.vscode_altText;
|
||||
}
|
||||
return undefined;
|
||||
@@ -337,9 +337,9 @@ function findScrolledHeight(container: HTMLElement): number | undefined {
|
||||
}
|
||||
|
||||
function scrollingEnabled(output: OutputItem, options: RenderOptions) {
|
||||
const metadata = output.metadata;
|
||||
const metadata = output.metadata as Record<string, unknown> | undefined;
|
||||
return (typeof metadata === 'object' && metadata
|
||||
&& 'scrollable' in metadata && typeof metadata.scrollable === 'boolean') ?
|
||||
&& typeof metadata.scrollable === 'boolean') ?
|
||||
metadata.scrollable : options.outputScrolling;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user