Skip to content

Commit c3542b2

Browse files
committed
Change "disabled" rendering and fix initial sort order
Signed-off-by: Thomas Mäder <[email protected]>
1 parent 8b1beb5 commit c3542b2

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

packages/vsx-registry/src/browser/vsx-extension.tsx

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -557,15 +557,17 @@ export class VSXExtensionComponent<Props extends VSXExtensionComponent.Props = V
557557
<div className='theia-vsx-extension-content'>
558558
<div className='title'>
559559
<div className='noWrapInfo'>
560-
<span className='name'>{displayName}</span> <span className='version'>{VSXExtension.formatVersion(version)}</span>
560+
<span className='name'>{displayName}</span>&nbsp;
561+
<span className='version'>{VSXExtension.formatVersion(version)}&nbsp;
562+
</span>{disabled && <span className='disabled'>({nls.localizeByDefault('disabled')})</span>}
561563
</div>
562564
<div className='stat'>
563565
{!!downloadCount && <span className='download-count'><i className={codicon('cloud-download')} />{downloadCompactFormatter.format(downloadCount)}</span>}
564566
{!!averageRating && <span className='average-rating'><i className={codicon('star-full')} />{averageRatingFormatter(averageRating)}</span>}
565567
</div>
566568
</div>
567569
<div className='noWrapInfo theia-vsx-extension-description'>{description}</div>
568-
{disabled && <div className='disabled'>{nls.localizeByDefault('disabled')}</div>}
570+
569571
<div className='theia-vsx-extension-action-bar'>
570572
<div className='theia-vsx-extension-publisher-container'>
571573
{verified === true ? (

packages/vsx-registry/src/browser/vsx-extensions-model.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -400,6 +400,7 @@ export class VSXExtensionsModel {
400400
if (!extension) { continue; }
401401
refreshing.push(this.refresh(id, extension.version));
402402
}
403+
await Promise.all(refreshing);
403404
const installed = new Set([...prevInstalled, ...currInstalled]);
404405
const installedSorted = Array.from(installed).sort((a, b) => this.compareExtensions(a, b));
405406
this._installed = new Set(installedSorted.values());
@@ -426,7 +427,6 @@ export class VSXExtensionsModel {
426427
this.builtins.delete(PluginIdentifiers.componentsToUnversionedId(plugin.metadata.model));
427428
}
428429
}
429-
await Promise.all(refreshing);
430430
});
431431
}
432432

0 commit comments

Comments
 (0)