mempool/frontend/src/app/shared/shared.module.ts

425 lines
18 KiB
TypeScript
Raw Normal View History

import { NgModule } from '@angular/core';
import { CommonModule } from '@angular/common';
2022-11-28 16:00:50 +09:00
import { NgbCollapseModule, NgbTypeaheadModule } from '@ng-bootstrap/ng-bootstrap';
import { FontAwesomeModule, FaIconLibrary } from '@fortawesome/angular-fontawesome';
import { faFilter, faAngleDown, faAngleUp, faAngleRight, faAngleLeft, faBolt, faChartArea, faCogs, faCubes, faHammer, faDatabase, faExchangeAlt, faInfoCircle,
2023-06-05 13:28:00 -04:00
faLink, faList, faSearch, faCaretUp, faCaretDown, faTachometerAlt, faThList, faTint, faTv, faClock, faAngleDoubleDown, faSortUp, faAngleDoubleUp, faChevronDown,
faFileAlt, faRedoAlt, faArrowAltCircleRight, faExternalLinkAlt, faBook, faListUl, faDownload, faQrcode, faArrowRightArrowLeft, faArrowsRotate, faCircleLeft, faFastForward, faWallet, faUserClock, faWrench, faUserFriends, faQuestionCircle, faHistory, faSignOutAlt, faKey, faSuitcase, faIdCardAlt, faNetworkWired, faUserCheck, faCircleCheck, faUserCircle, faCheck, faRocket, faScaleBalanced, faHourglassStart, faHourglassHalf, faHourglassEnd, faWandMagicSparkles } from '@fortawesome/free-solid-svg-icons';
import { InfiniteScrollModule } from 'ngx-infinite-scroll';
import { MenuComponent } from '../components/menu/menu.component';
import { PreviewTitleComponent } from '../components/master-page-preview/preview-title.component';
import { VbytesPipe } from './pipes/bytes-pipe/vbytes.pipe';
import { ShortenStringPipe } from './pipes/shorten-string-pipe/shorten-string.pipe';
import { CeilPipe } from './pipes/math-ceil/math-ceil.pipe';
import { Hex2asciiPipe } from './pipes/hex2ascii/hex2ascii.pipe';
import { Decimal2HexPipe } from './pipes/decimal2hex/decimal2hex.pipe';
import { FeeRoundingPipe } from './pipes/fee-rounding/fee-rounding.pipe';
import { AsmStylerPipe } from './pipes/asm-styler/asm-styler.pipe';
import { AbsolutePipe } from './pipes/absolute/absolute.pipe';
import { RelativeUrlPipe } from './pipes/relative-url/relative-url.pipe';
import { ScriptpubkeyTypePipe } from './pipes/scriptpubkey-type-pipe/scriptpubkey-type.pipe';
import { BytesPipe } from './pipes/bytes-pipe/bytes.pipe';
import { WuBytesPipe } from './pipes/bytes-pipe/wubytes.pipe';
import { FiatCurrencyPipe } from './pipes/fiat-currency.pipe';
import { HttpErrorPipe } from './pipes/http-error-pipe/http-error.pipe';
import { BlockchainComponent } from '../components/blockchain/blockchain.component';
2023-03-05 18:54:04 -06:00
import { TimeComponent } from '../components/time/time.component';
import { ClipboardComponent } from '../components/clipboard/clipboard.component';
2020-07-13 21:46:25 +07:00
import { QrcodeComponent } from '../components/qrcode/qrcode.component';
2020-07-14 21:26:02 +07:00
import { FiatComponent } from '../fiat/fiat.component';
2022-11-28 16:00:50 +09:00
import { NgbNavModule, NgbTooltipModule, NgbPaginationModule, NgbDropdownModule } from '@ng-bootstrap/ng-bootstrap';
import { TxFeaturesComponent } from '../components/tx-features/tx-features.component';
import { TxFeeRatingComponent } from '../components/tx-fee-rating/tx-fee-rating.component';
import { ReactiveFormsModule } from '@angular/forms';
import { LanguageSelectorComponent } from '../components/language-selector/language-selector.component';
2023-01-03 11:56:54 -06:00
import { FiatSelectorComponent } from '../components/fiat-selector/fiat-selector.component';
import { RateUnitSelectorComponent } from '../components/rate-unit-selector/rate-unit-selector.component';
2023-01-02 13:08:25 -06:00
import { ThemeSelectorComponent } from '../components/theme-selector/theme-selector.component';
import { BrowserOnlyDirective } from './directives/browser-only.directive';
import { ServerOnlyDirective } from './directives/server-only.directive';
import { ColoredPriceDirective } from './directives/colored-price.directive';
import { NoSanitizePipe } from './pipes/no-sanitize.pipe';
import { MempoolBlocksComponent } from '../components/mempool-blocks/mempool-blocks.component';
import { BlockchainBlocksComponent } from '../components/blockchain-blocks/blockchain-blocks.component';
import { AmountComponent } from '../components/amount/amount.component';
import { RouterModule } from '@angular/router';
import { CapAddressPipe } from './pipes/cap-address-pipe/cap-address-pipe';
import { StartComponent } from '../components/start/start.component';
import { TransactionsListComponent } from '../components/transactions-list/transactions-list.component';
import { BlockOverviewGraphComponent } from '../components/block-overview-graph/block-overview-graph.component';
import { BlockOverviewTooltipComponent } from '../components/block-overview-tooltip/block-overview-tooltip.component';
2023-12-13 10:59:28 +00:00
import { BlockFiltersComponent } from '../components/block-filters/block-filters.component';
2024-02-16 02:30:51 +00:00
import { AddressGroupComponent } from '../components/address-group/address-group.component';
2024-04-08 04:27:49 +00:00
import { TrackerComponent } from '../components/tracker/tracker.component';
2024-04-13 08:05:31 +00:00
import { TrackerBarComponent } from '../components/tracker/tracker-bar.component';
import { SearchFormComponent } from '../components/search-form/search-form.component';
import { AddressLabelsComponent } from '../components/address-labels/address-labels.component';
import { FooterComponent } from '../components/footer/footer.component';
import { AssetComponent } from '../components/asset/asset.component';
import { AssetsComponent } from '../components/assets/assets.component';
import { AssetsNavComponent } from '../components/assets/assets-nav/assets-nav.component';
import { StatusViewComponent } from '../components/status-view/status-view.component';
2024-03-03 20:31:02 +00:00
import { ServerHealthComponent } from '../components/server-health/server-health.component';
import { ServerStatusComponent } from '../components/server-health/server-status.component';
import { FeesBoxComponent } from '../components/fees-box/fees-box.component';
import { DifficultyComponent } from '../components/difficulty/difficulty.component';
import { DifficultyTooltipComponent } from '../components/difficulty/difficulty-tooltip.component';
import { DifficultyMiningComponent } from '../components/difficulty-mining/difficulty-mining.component';
import { RbfTimelineComponent } from '../components/rbf-timeline/rbf-timeline.component';
import { RbfTimelineTooltipComponent } from '../components/rbf-timeline/rbf-timeline-tooltip.component';
import { PushTransactionComponent } from '../components/push-transaction/push-transaction.component';
import { AssetsFeaturedComponent } from '../components/assets/assets-featured/assets-featured.component';
import { AssetGroupComponent } from '../components/assets/asset-group/asset-group.component';
import { AssetCirculationComponent } from '../components/asset-circulation/asset-circulation.component';
import { AmountShortenerPipe } from '../shared/pipes/amount-shortener.pipe';
import { DifficultyAdjustmentsTable } from '../components/difficulty-adjustments-table/difficulty-adjustments-table.components';
import { BlocksList } from '../components/blocks-list/blocks-list.component';
2022-12-14 16:51:53 -06:00
import { RbfList } from '../components/rbf-list/rbf-list.component';
import { RewardStatsComponent } from '../components/reward-stats/reward-stats.component';
import { DataCyDirective } from '../data-cy.directive';
import { LoadingIndicatorComponent } from '../components/loading-indicator/loading-indicator.component';
import { IndexingProgressComponent } from '../components/indexing-progress/indexing-progress.component';
import { SvgImagesComponent } from '../components/svg-images/svg-images.component';
import { ChangeComponent } from '../components/change/change.component';
2022-05-01 03:01:27 +04:00
import { SatsComponent } from './components/sats/sats.component';
2023-12-07 08:26:32 +00:00
import { BtcComponent } from './components/btc/btc.component';
2023-06-15 15:16:49 -04:00
import { FeeRateComponent } from './components/fee-rate/fee-rate.component';
2023-01-05 11:00:08 -06:00
import { TruncateComponent } from './components/truncate/truncate.component';
2022-05-24 18:40:59 +04:00
import { SearchResultsComponent } from '../components/search-form/search-results/search-results.component';
2022-07-01 18:06:48 +02:00
import { TimestampComponent } from './components/timestamp/timestamp.component';
import { ConfirmationsComponent } from './components/confirmations/confirmations.component';
import { ToggleComponent } from './components/toggle/toggle.component';
import { GeolocationComponent } from '../shared/components/geolocation/geolocation.component';
2023-04-03 16:25:10 +09:00
import { TestnetAlertComponent } from './components/testnet-alert/testnet-alert.component';
import { GlobalFooterComponent } from './components/global-footer/global-footer.component';
2023-08-26 09:52:55 +02:00
import { AcceleratePreviewComponent } from '../components/accelerate-preview/accelerate-preview.component';
2023-08-29 21:20:36 +09:00
import { AccelerateFeeGraphComponent } from '../components/accelerate-preview/accelerate-fee-graph.component';
2023-08-26 09:52:55 +02:00
import { MempoolErrorComponent } from './components/mempool-error/mempool-error.component';
2023-12-07 08:26:32 +00:00
import { AccelerationsListComponent } from '../components/acceleration/accelerations-list/accelerations-list.component';
import { PendingStatsComponent } from '../components/acceleration/pending-stats/pending-stats.component';
import { AccelerationStatsComponent } from '../components/acceleration/acceleration-stats/acceleration-stats.component';
import { AccelerateCheckout } from '../components/accelerate-checkout/accelerate-checkout.component';
import { BlockViewComponent } from '../components/block-view/block-view.component';
2023-09-28 15:48:37 +01:00
import { EightBlocksComponent } from '../components/eight-blocks/eight-blocks.component';
import { MempoolBlockViewComponent } from '../components/mempool-block-view/mempool-block-view.component';
2023-04-15 05:26:18 +09:00
import { MempoolBlockOverviewComponent } from '../components/mempool-block-overview/mempool-block-overview.component';
import { ClockchainComponent } from '../components/clockchain/clockchain.component';
2023-04-15 05:26:18 +09:00
import { ClockFaceComponent } from '../components/clock-face/clock-face.component';
2023-04-19 03:34:13 +09:00
import { ClockComponent } from '../components/clock/clock.component';
2023-06-17 21:04:23 +02:00
import { CalculatorComponent } from '../components/calculator/calculator.component';
2023-06-18 00:16:47 +02:00
import { BitcoinsatoshisPipe } from '../shared/pipes/bitcoinsatoshis.pipe';
import { HttpErrorComponent } from '../shared/components/http-error/http-error.component';
2023-04-15 05:26:18 +09:00
import { OnlyVsizeDirective, OnlyWeightDirective } from './components/weight-directives/weight-directives';
@NgModule({
declarations: [
ClipboardComponent,
2023-03-05 18:54:04 -06:00
TimeComponent,
QrcodeComponent,
FiatComponent,
TxFeaturesComponent,
TxFeeRatingComponent,
LanguageSelectorComponent,
2023-01-03 11:56:54 -06:00
FiatSelectorComponent,
2023-01-02 13:08:25 -06:00
ThemeSelectorComponent,
RateUnitSelectorComponent,
ScriptpubkeyTypePipe,
RelativeUrlPipe,
NoSanitizePipe,
Hex2asciiPipe,
AsmStylerPipe,
AbsolutePipe,
BytesPipe,
VbytesPipe,
WuBytesPipe,
CeilPipe,
ShortenStringPipe,
CapAddressPipe,
Decimal2HexPipe,
FeeRoundingPipe,
FiatCurrencyPipe,
HttpErrorPipe,
ColoredPriceDirective,
BrowserOnlyDirective,
ServerOnlyDirective,
BlockchainComponent,
BlockViewComponent,
2023-09-28 15:48:37 +01:00
EightBlocksComponent,
MempoolBlockViewComponent,
MempoolBlocksComponent,
BlockchainBlocksComponent,
AmountComponent,
MenuComponent,
PreviewTitleComponent,
StartComponent,
BlockOverviewGraphComponent,
BlockOverviewTooltipComponent,
2023-12-13 10:59:28 +00:00
BlockFiltersComponent,
TransactionsListComponent,
2024-02-16 02:30:51 +00:00
AddressGroupComponent,
2024-04-08 04:27:49 +00:00
TrackerComponent,
2024-04-13 08:05:31 +00:00
TrackerBarComponent,
SearchFormComponent,
AddressLabelsComponent,
FooterComponent,
AssetComponent,
AssetsComponent,
StatusViewComponent,
2024-03-03 20:31:02 +00:00
ServerHealthComponent,
ServerStatusComponent,
FeesBoxComponent,
DifficultyComponent,
DifficultyMiningComponent,
DifficultyTooltipComponent,
RbfTimelineComponent,
RbfTimelineTooltipComponent,
PushTransactionComponent,
AssetsNavComponent,
AssetsFeaturedComponent,
AssetGroupComponent,
AssetCirculationComponent,
AmountShortenerPipe,
DifficultyAdjustmentsTable,
BlocksList,
2022-12-14 16:51:53 -06:00
RbfList,
DataCyDirective,
RewardStatsComponent,
LoadingIndicatorComponent,
IndexingProgressComponent,
SvgImagesComponent,
ChangeComponent,
2022-05-01 03:01:27 +04:00
SatsComponent,
2023-12-07 08:26:32 +00:00
BtcComponent,
2023-06-15 15:16:49 -04:00
FeeRateComponent,
2023-01-05 11:00:08 -06:00
TruncateComponent,
2022-05-24 18:40:59 +04:00
SearchResultsComponent,
2022-07-01 18:06:48 +02:00
TimestampComponent,
ConfirmationsComponent,
ToggleComponent,
GeolocationComponent,
2023-04-03 16:25:10 +09:00
TestnetAlertComponent,
GlobalFooterComponent,
2023-08-26 09:52:55 +02:00
AcceleratePreviewComponent,
2023-08-29 21:20:36 +09:00
AccelerateFeeGraphComponent,
2023-06-17 21:04:23 +02:00
CalculatorComponent,
2023-06-18 18:04:32 +02:00
BitcoinsatoshisPipe,
BlockViewComponent,
2023-09-28 15:48:37 +01:00
EightBlocksComponent,
MempoolBlockViewComponent,
2023-04-15 05:26:18 +09:00
MempoolBlockOverviewComponent,
ClockchainComponent,
2023-04-19 03:34:13 +09:00
ClockComponent,
2023-04-15 05:26:18 +09:00
ClockFaceComponent,
OnlyVsizeDirective,
2023-08-26 09:52:55 +02:00
OnlyWeightDirective,
MempoolErrorComponent,
2023-07-20 16:26:42 +09:00
AccelerationsListComponent,
AccelerationStatsComponent,
AccelerateCheckout,
2023-12-07 08:26:32 +00:00
PendingStatsComponent,
HttpErrorComponent,
],
imports: [
CommonModule,
RouterModule,
ReactiveFormsModule,
NgbNavModule,
NgbTooltipModule,
NgbPaginationModule,
NgbTypeaheadModule,
NgbDropdownModule,
NgbCollapseModule,
InfiniteScrollModule,
FontAwesomeModule,
],
providers: [
2023-09-28 15:48:37 +01:00
BytesPipe,
VbytesPipe,
WuBytesPipe,
RelativeUrlPipe,
NoSanitizePipe,
ShortenStringPipe,
CapAddressPipe,
AmountShortenerPipe,
],
exports: [
MenuComponent,
RouterModule,
ReactiveFormsModule,
NgbNavModule,
NgbTooltipModule,
NgbPaginationModule,
NgbTypeaheadModule,
NgbDropdownModule,
NgbCollapseModule,
InfiniteScrollModule,
FontAwesomeModule,
2023-03-05 18:54:04 -06:00
TimeComponent,
ClipboardComponent,
QrcodeComponent,
FiatComponent,
TxFeaturesComponent,
TxFeeRatingComponent,
LanguageSelectorComponent,
2023-01-03 11:56:54 -06:00
FiatSelectorComponent,
RateUnitSelectorComponent,
2023-01-02 13:08:25 -06:00
ThemeSelectorComponent,
ScriptpubkeyTypePipe,
RelativeUrlPipe,
Hex2asciiPipe,
AsmStylerPipe,
AbsolutePipe,
BytesPipe,
VbytesPipe,
WuBytesPipe,
FiatCurrencyPipe,
HttpErrorPipe,
CeilPipe,
ShortenStringPipe,
CapAddressPipe,
Decimal2HexPipe,
FeeRoundingPipe,
ColoredPriceDirective,
BrowserOnlyDirective,
ServerOnlyDirective,
NoSanitizePipe,
BlockchainComponent,
MempoolBlocksComponent,
BlockchainBlocksComponent,
AmountComponent,
StartComponent,
BlockOverviewGraphComponent,
BlockOverviewTooltipComponent,
2023-12-13 10:59:28 +00:00
BlockFiltersComponent,
TransactionsListComponent,
2024-02-16 02:30:51 +00:00
AddressGroupComponent,
2024-04-08 04:27:49 +00:00
TrackerComponent,
2024-04-13 08:05:31 +00:00
TrackerBarComponent,
SearchFormComponent,
AddressLabelsComponent,
FooterComponent,
AssetComponent,
AssetsComponent,
StatusViewComponent,
2024-03-03 20:31:02 +00:00
ServerHealthComponent,
ServerStatusComponent,
FeesBoxComponent,
DifficultyComponent,
DifficultyMiningComponent,
DifficultyTooltipComponent,
RbfTimelineComponent,
RbfTimelineTooltipComponent,
PushTransactionComponent,
AssetsNavComponent,
AssetsFeaturedComponent,
AssetGroupComponent,
AssetCirculationComponent,
AmountShortenerPipe,
DifficultyAdjustmentsTable,
BlocksList,
DataCyDirective,
RewardStatsComponent,
LoadingIndicatorComponent,
IndexingProgressComponent,
SvgImagesComponent,
ChangeComponent,
2022-05-24 18:40:59 +04:00
SatsComponent,
2023-12-07 08:26:32 +00:00
BtcComponent,
2023-06-15 15:16:49 -04:00
FeeRateComponent,
2023-01-05 11:00:08 -06:00
TruncateComponent,
2022-05-24 18:40:59 +04:00
SearchResultsComponent,
2022-07-01 18:06:48 +02:00
TimestampComponent,
ConfirmationsComponent,
ToggleComponent,
GeolocationComponent,
TestnetAlertComponent,
PreviewTitleComponent,
GlobalFooterComponent,
2023-08-26 09:52:55 +02:00
AcceleratePreviewComponent,
2023-08-29 21:20:36 +09:00
AccelerateFeeGraphComponent,
2023-08-26 09:52:55 +02:00
MempoolErrorComponent,
2023-07-20 16:26:42 +09:00
AccelerationsListComponent,
AccelerationStatsComponent,
AccelerateCheckout,
2023-12-07 08:26:32 +00:00
PendingStatsComponent,
HttpErrorComponent,
2023-04-15 05:26:18 +09:00
MempoolBlockOverviewComponent,
ClockchainComponent,
2023-04-19 03:34:13 +09:00
ClockComponent,
2023-04-15 05:26:18 +09:00
ClockFaceComponent,
OnlyVsizeDirective,
OnlyWeightDirective,
]
})
export class SharedModule {
constructor(library: FaIconLibrary) {
library.addIcons(faInfoCircle);
library.addIcons(faChartArea);
library.addIcons(faTv);
2023-06-05 13:28:00 -04:00
library.addIcons(faClock);
library.addIcons(faTachometerAlt);
library.addIcons(faCubes);
library.addIcons(faHammer);
library.addIcons(faCogs);
library.addIcons(faThList);
library.addIcons(faList);
library.addIcons(faTachometerAlt);
library.addIcons(faDatabase);
library.addIcons(faSearch);
library.addIcons(faLink);
library.addIcons(faBolt);
library.addIcons(faTint);
library.addIcons(faFilter);
library.addIcons(faAngleDown);
library.addIcons(faAngleUp);
library.addIcons(faExchangeAlt);
library.addIcons(faAngleDoubleUp);
library.addIcons(faAngleDoubleDown);
library.addIcons(faChevronDown);
library.addIcons(faFileAlt);
library.addIcons(faRedoAlt);
library.addIcons(faArrowAltCircleRight);
library.addIcons(faArrowsRotate);
library.addIcons(faCircleLeft);
library.addIcons(faExternalLinkAlt);
library.addIcons(faSortUp);
library.addIcons(faCaretUp);
library.addIcons(faCaretDown);
library.addIcons(faAngleRight);
library.addIcons(faAngleLeft);
library.addIcons(faBook);
library.addIcons(faListUl);
library.addIcons(faDownload);
2022-05-24 18:40:59 +04:00
library.addIcons(faQrcode);
2022-08-11 17:19:12 +00:00
library.addIcons(faArrowRightArrowLeft);
2022-09-30 13:57:34 +04:00
library.addIcons(faExchangeAlt);
library.addIcons(faList);
library.addIcons(faFastForward);
library.addIcons(faWallet);
library.addIcons(faUserClock);
library.addIcons(faWrench);
library.addIcons(faUserFriends);
library.addIcons(faQuestionCircle);
library.addIcons(faHistory);
library.addIcons(faSignOutAlt);
library.addIcons(faKey);
library.addIcons(faSuitcase);
library.addIcons(faIdCardAlt);
library.addIcons(faNetworkWired);
library.addIcons(faUserCheck);
library.addIcons(faCircleCheck);
library.addIcons(faUserCircle);
2023-11-21 16:42:21 +09:00
library.addIcons(faCheck);
2023-12-09 22:33:02 +07:00
library.addIcons(faRocket);
2024-01-23 09:57:26 +01:00
library.addIcons(faScaleBalanced);
2024-04-13 09:05:50 +00:00
library.addIcons(faHourglassStart);
library.addIcons(faHourglassHalf);
library.addIcons(faHourglassEnd);
library.addIcons(faWandMagicSparkles);
}
}