Charlie Tran 843a6c5bbb
feat(frontend): update datahub-web client UI code (#1806)
* Releases updated version of datahub-web client UI code

* Fix typo in yarn lock

* Change yarn lock to match yarn registry directories

* Previous commit missed some paths

* Even more changes to yarnlock missing in previous commit

* Include codegen file for typings

* Add files to get parity for datahub-web and current OS datahub-midtier

* Add in typo fix from previous commit - change to proper license

* Implement proper OS fix for person entity picture url

* Workarounds for open source DH issues

* Fixes institutional memory api and removes unopensourced tabs for datasets

* Fixes search dataset deprecation and user search issue as a result of changes

* Remove internal only options in the avatar menu
2020-08-26 15:44:50 -07:00

30 lines
1.5 KiB
TypeScript

import Component from '@glimmer/component';
import { PersonEntity } from '@datahub/data-models/entity/person/person-entity';
interface IAvatarGenericWrapperArgs {
// Optional parameters to influence what renders in the generic wrapper
options: {
// Component to accept the yielded params of the avatar main container, for example avatar-name
component: string;
// Whether or not we pass the whole of the yielded avatars to a single component that accepts
// a list or if we want to use the above stated component for each avatar in the yielded list
// from avatar main container
avatarsAsList?: boolean;
// Whether or not we should build the avatars in the avatar main container. Most often this
// will likely be false
shouldBuildAvatar?: boolean;
};
// The entity we are passing to avatar main container to be transformed. Called "value" as this
// is often the generic param used to pass values into generic components in our application
value: PersonEntity | Array<PersonEntity>;
}
/**
* The generic wrapper component can be used to wrap both the avatar main container and a avatar
* presentational component together, useful for when the component is being loaded to a config
* and the template doesn't have room to allow for the full blown container usage that requires
* yielding to block components and passing different params around, etc.
* Note that if the generic wrapper is used, the value is expected to be a person entity
*/
export default class AvatarGenericWrapper extends Component<IAvatarGenericWrapperArgs> {}