src/lib/inbox/inbox.component.ts
Main Component of the Inbox Library, gives an example layout and functionality for an inbox workspace.
Important: The usePagination and useProgressiveLoader inputs are mutually exclusive.
If both are enabled, neither feature will be active and warnings will be logged.
<talenra-inbox
class="talenra-inbox"
[dataItems]="dataItems"
[loading]="false"
[attributes]="attributes"
[customShortcuts]="customShortcuts"
[detailViewTabs]="detailViewTabs"
[presets]="presets"
[activePresetName]="activePresetName"
usePagination
[paginatorState]="paginatorState"
(paginatorStateChange)="onPaginatorStateChange($event)"
(presetAction)="onPresetAction($event)"
(presetsChange)="newPresets($event)"
(clickedDataItemEmitter)="onClickedDataItem($event)"
(dataItemsInteractions)="onDataItemsInteractions($event)"
(virtualScrollerPosition)="onVirtualScrollerPosition($event)"
></talenra-inbox><talenra-inbox
class="talenra-inbox"
[dataItems]="dataItems"
[loading]="false"
[attributes]="attributes"
useProgressiveLoader
[progressiveLoaderState]="progressiveLoaderState"
(progressiveLoaderStateChange)="onProgressiveLoaderStateChange($event)"
(clickedDataItemEmitter)="onClickedDataItem($event)"
(dataItemsInteractions)="onDataItemsInteractions($event)"
></talenra-inbox>
| selector | talenra-inbox |
| imports |
InboxSkeletonLoadingComponent
SkeletonLoadingDataItemsListComponent
NgTemplateOutlet
CopyContentDirective
AsyncPipe
DetailViewInformationComponent
InboxNoteBoxComponent
PaginatorComponent
DataItemsListComponent
InboxLayoutComponent
FilterToolbarComponent
InboxToolbarComponent
InboxConfigurationPanelComponent
ProgressiveLoaderComponent
TalenraInboxTranslatePipe
|
| styleUrls | ./inbox.component.scss |
| templateUrl | ./inbox.component.html |
| loading |
Type : boolean
|
Default value : false
|
|
Boolean to show if skeleton loading is to be shown. Important information:
|
| noteBoxItems |
Type : INoteBoxItem[]
|
|
The NoteBoxItems input is used to show a custom note box items in style of the default note box. It is changeable in runtime by the consuming app to show different content in the note box. Important information:
UsageExample :ConfigurationExample : |
| pairingAttributes |
Type : IPairingAttributes[]
|
Default value : []
|
|
The pairing attributes which combine two attributes to one attribute. The pairingAttributes input is used to combine two attributes to one attribute. Important information:
UsageExample :ConfigurationExample : |
| presets |
Type : IPreset[]
|
Default value : []
|
|
The presets input is necessary to create and show different presets in the inbox. The user has the possibility to choose between the presets. If the consuming application used the app without the presets input, the inbox won't be able to save or manipulate new presets and existing presets. Important information:
UsageExample :Active preset nameExample :ConfigurationExample : |
| refreshing |
Type : boolean
|
Default value : false
|
|
The Important information
|
| selectDataItem |
Type : IDataItemId
|
|
The input is used to select a data item in the inbox. The input is an object of Important information:
UsageExample :ConfigurationExample : |
| usePagination |
Type : boolean
|
Default value : false
|
|
If true, the pagination feature is enabled. UsageExample : |
| detailViewTabs |
Type : IInboxTabBarItem[]
|
Default value : []
|
|
The detailViewTabs input is used to add tabs to the detail-view. Important information:
|
| inboxConfigurationPanelTabs |
Type : IInboxTabBarItem[]
|
Default value : []
|
|
The inboxConfigurationPanelTabs input is used to add tabs to the inboxConfigurationPanel. Important information:
|
| lockedDataItems |
Type : IDataItemId[]
|
Default value : []
|
|
The input is used to lock specific data items in the inbox. The input is an array of Error Information (Infotip): When Important information:
UsageExample :Basic locked items (static lock icon)Example :Locked items with error info (clickable lock icon with infotip)Example : |
| possibleOptions |
Type : IQueryBuilderValueOptions[]
|
|
The values that can be selected in connection to each rule identifier. |
| progressiveLoaderState |
Type : ProgressiveLoaderState
|
Default value : { currentIteration: 1, iterationSize: 25, iterationEnd: 100, totalItems: 1000, }
|
|
The state configuration for the progressive loader. Only used when useProgressiveLoader is true and usePagination is false. UsageExample : |
| dataItemsInteractions |
Type : EventEmitter<IInteractedDataItems>
|
|
The event which is emitted when a dataItems is interacted with by the further-actions and the proceed button. The Messages correlate with the buttons in the toolbar and the list view. Process: The process button was clicked (arrow-right icon). More: The further actions button was clicked (three-dots icon). The More message is intended to allow the consuming app to customize the further actions menu and specify which item opened the menu. Important information:
|
| filterSortSearchEmitter |
Type : EventEmitter
|
|
The event which is emitted when the filter, sort or the search input changes The consuming application receives information about which filter, sort or search input is used. Important information:
|
| paginatorStateChange |
Type : EventEmitter
|
|
The event which is emitted when the page changes in the pagination.
The consuming application receives information about which page is selected.
The consuming application can load the data for the selected page by using the |
| refreshingChange |
Type : EventEmitter
|
|
The value that the refresh button is clicked. It will emit the value |
| selectedAllAttributesEmitter |
Type : EventEmitter
|
|
The event which is emitted when the all selected attributes changes The consuming application receives information about which attributes have been selected. |
| selectedDetailAttributesEmitter |
Type : EventEmitter
|
|
The event which is emitted when the selected detail attributes changes The consuming application receives information about which detail attributes (the ones below the line in the attribute-settings). The attributes are emitted as an array of strings with the correct order as chosen by the user. The strings are the identifiers of the attributes. |
| selectedMainAttributesEmitter |
Type : EventEmitter
|
|
The event which is emitted when the selected main attributes change The consuming application receives information about which main attributes (the ones above the line in the attribute-settings). The attributes are emitted as an array of strings with the correct order as chosen by the user. The strings are the identifiers of the attributes. |
| progressiveLoaderStateChange |
Type : ProgressiveLoaderState
|
|
The event which is emitted when the progressive loader state changes.
The consuming application receives information about the current loader state.
The consuming application can load more data by using the |
| clickedDataItemFunction | ||||||||
clickedDataItemFunction(dataItem: any)
|
||||||||
|
Handler for the clicked data item.
Parameters :
Returns :
void
|
| handleChangesOnPreset | ||||||||
handleChangesOnPreset(btn: string)
|
||||||||
|
Handles the changes in the preset.
Parameters :
Returns :
void
|
| iconBtnFunction | ||||||||
iconBtnFunction(btn: string)
|
||||||||
|
Main function to handle interactions with clicked icon buttons.
Parameters :
Returns :
void
|
| initializeComponent |
initializeComponent()
|
|
Functions to initialize the component.
Returns :
void
|
| initializeComponentForViewUsage |
initializeComponentForViewUsage()
|
|
Initializes the component for the view usage.
Returns :
void
|
| numberMainAttributesChosenByUserHandler | ||||||||
numberMainAttributesChosenByUserHandler($event: number)
|
||||||||
|
Sets the number of main attributes chosen by the user.-
Parameters :
Returns :
void
|
| numberMarkedDataItemsChange | ||||||
numberMarkedDataItemsChange($event: number)
|
||||||
|
Handler for the change of number of marked data items.
Parameters :
Returns :
void
|
| onDataItemsInteractions | ||||||||
onDataItemsInteractions(event: IInteractedDataItems)
|
||||||||
|
Depending on the clicked data item button the corresponding event actions will be shown.
Parameters :
Returns :
void
|
| onIconFilterChange | ||||||||
onIconFilterChange(icons: IIconInput[])
|
||||||||
|
Handler for changes in the icon filter state.
Parameters :
Returns :
void
|
| onInboxConfigurationPanelButtonAction | ||||||||||||
onInboxConfigurationPanelButtonAction(action: TConfigurationPanelBottomBarActions, fromPresetChange?: boolean)
|
||||||||||||
|
Actions performed on button action. Should emit filterSearchSort event.
Parameters :
Returns :
void
|
| onPaginatorStateChange | ||||||||
onPaginatorStateChange(paginatorState: PaginatorState)
|
||||||||
|
Handler for the paginator state change.
Parameters :
Returns :
void
|
| onSelectedFilters | ||||||||
onSelectedFilters(filterAttributes: IQueryBuilderQuery)
|
||||||||
|
The action that is to be performed in for the items.
Parameters :
Returns :
void
|
| onSelectedSorts | ||||||
onSelectedSorts(sorts: ISortAttributesInput[])
|
||||||
|
Handles the selected sorts.
Parameters :
Returns :
void
|
| recognizeChangesInInbox |
recognizeChangesInInbox()
|
|
Subscribes to the changes in the inbox. Values are provided by the changed values service.
Returns :
void
|
| resetPresetEmitterHandler |
resetPresetEmitterHandler()
|
|
Handler if the inbox is to be reset.
Returns :
void
|
| selectedAllAttributesHandler | ||||||||
selectedAllAttributesHandler(selectedAllAttributes: IAttributeItem[])
|
||||||||
|
Handler for the selected all attributes.
Parameters :
Returns :
void
|
| selectedDetailAttributesEmitterHandler | ||||||||
selectedDetailAttributesEmitterHandler(selectedDetailAttributes: IAttributeItem[])
|
||||||||
|
Handler for the selected detail attributes.
Parameters :
Returns :
void
|
| selectedMainAttributesEmitterHandler | ||||||||
selectedMainAttributesEmitterHandler(selectedMainAttributes: IAttributeItem[])
|
||||||||
|
Handler for the selected main attributes.
Parameters :
Returns :
void
|
| setInboxStateChangedState |
setInboxStateChangedState()
|
|
Auxiliary method to set the state that the inbox state changed.
Returns :
void
|
| changedValuesService |
Type : unknown
|
Default value : inject(ChangedPresetValuesService)
|
|
Injected changed values service. |
| csvService |
Type : unknown
|
Default value : inject(CsvService)
|
|
Injected csv service. |
| Public dataItemsClass |
Type : DataItemsClass
|
Default value : new DataItemsClass()
|
|
Class to interact with data items. |
| dataItemsService |
Type : unknown
|
Default value : inject(DataItemsService)
|
|
Injected inbox data items service. |
| filterState |
Type : unknown
|
Default value : inject(FilterStateService)
|
|
Injected filter state. |
| filterToolbarService |
Type : unknown
|
Default value : inject(FilterToolbarService)
|
|
Injected filter toolbar service. |
| inboxDetailViewService |
Type : unknown
|
Default value : inject(InboxDetailViewService)
|
|
Injected inbox detail view service. |
| inboxHelperService |
Type : unknown
|
Default value : inject(InboxHelperService)
|
|
Injected inbox helper service. |
| inboxState |
Type : unknown
|
Default value : inject(InboxState)
|
|
Injected inbox state. |
| inboxToolbarService |
Type : unknown
|
Default value : inject(InboxToolbarService)
|
|
Injected inbox toolbar service. |
| keyboardService |
Type : unknown
|
Default value : inject(KeyboardService)
|
|
Injected keyboard service. |
| Public mainCheckboxState |
Type : unknown
|
Default value : CheckboxState.Outline
|
|
Number of marked data items in data items list. |
| mainFacadeSetterService |
Type : unknown
|
Default value : inject(MainFacadeSetterService)
|
|
Injected set inbox configuration service. |
| Public numberMarkedDataItems |
Type : number
|
Default value : 0
|
|
Number of marked data items in data items list. |
| updatePresetsService |
Type : unknown
|
Default value : inject(UpdatePresetsService)
|
|
Injected update preset service. |