import * as _ from 'lodash';
import React from 'react';
import { ExtensionContext } from '@workbench-stack/components';
import { ContributableViewContainer } from '@workbench-stack/extension-api';
import { Subscription } from 'rxjs';
import { map } from 'rxjs/operators';
import { ViewSlot } from './ViewSlot';

function byPriority(a: { priority: number }, b: { priority: number }): number {
    return b.priority - a.priority;
}

export const ExtensionViewSlotComponent = (props) => {
        const { activeEditorId } = props;
        return (
            <ExtensionContext.Consumer>
                {({ controller }) => <ViewSlot controller={controller} />}
            </ExtensionContext.Consumer>
        );
};

