mirror of
https://github.com/microsoft/playwright.git
synced 2024-12-14 05:37:20 +03:00
fix(dotnet): correctly mark members as deprecated (#9977)
This commit is contained in:
parent
9c1ff08186
commit
bd5ae9e0cb
@ -293,7 +293,6 @@ function renderMember(member, parent, options, out) {
|
||||
return;
|
||||
}
|
||||
|
||||
/** @type string */
|
||||
let type = translateType(member.type, parent, t => generateNameDefault(member, name, t, parent));
|
||||
if (member.kind === 'event') {
|
||||
if (!member.type)
|
||||
@ -301,6 +300,8 @@ function renderMember(member, parent, options, out) {
|
||||
out.push('');
|
||||
if (member.spec)
|
||||
out.push(...XmlDoc.renderXmlDoc(member.spec, maxDocumentationColumnWidth));
|
||||
if (member.deprecated)
|
||||
out.push(`[System.Obsolete]`);
|
||||
out.push(`event EventHandler<${type}> ${name};`);
|
||||
return;
|
||||
}
|
||||
@ -499,6 +500,8 @@ function renderMethod(member, parent, name, options, out) {
|
||||
if (!member.async) {
|
||||
if (member.spec && !options.nodocs)
|
||||
out.push(...XmlDoc.renderXmlDoc(member.spec, maxDocumentationColumnWidth));
|
||||
if (member.deprecated)
|
||||
out.push(`[System.Obsolete]`);
|
||||
out.push(`${type} ${name} { get; }`);
|
||||
return;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user