mirror of
https://github.com/microsoft/vscode.git
synced 2026-04-18 23:59:43 +01:00
Experiment with switching markdown extension to use native privates
Let's try this out with one extension to start
This commit is contained in:
@@ -9,18 +9,18 @@ const codeLineClass = 'code-line';
|
||||
|
||||
|
||||
export class CodeLineElement {
|
||||
private readonly _detailParentElements: readonly HTMLDetailsElement[];
|
||||
readonly #detailParentElements: readonly HTMLDetailsElement[];
|
||||
|
||||
constructor(
|
||||
readonly element: HTMLElement,
|
||||
readonly line: number,
|
||||
readonly codeElement?: HTMLElement,
|
||||
) {
|
||||
this._detailParentElements = Array.from(getParentsWithTagName<HTMLDetailsElement>(element, 'DETAILS'));
|
||||
this.#detailParentElements = Array.from(getParentsWithTagName<HTMLDetailsElement>(element, 'DETAILS'));
|
||||
}
|
||||
|
||||
get isVisible(): boolean {
|
||||
if (this._detailParentElements.some(x => !x.open)) {
|
||||
if (this.#detailParentElements.some(x => !x.open)) {
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user