Commit 2e74352b authored by RAHUL RATHORE's avatar RAHUL RATHORE
Browse files

fix: highlight js loading issue

parent a8d0e11f
Loading
Loading
Loading
Loading
+2 −10
Original line number Diff line number Diff line
@@ -3,7 +3,7 @@ import { CommonModule } from '@angular/common';
import { ThemeModule } from '../../@theme';
import { JsonModalComponent } from './json-modal.component';
import { TranslateModule } from '@ngx-translate/core';
import { HighlightModule, HIGHLIGHT_OPTIONS } from 'ngx-highlightjs';
import { HighlightModule } from 'ngx-highlightjs';

const COMPONENTS = [JsonModalComponent];

@@ -15,14 +15,6 @@ const COMPONENTS = [JsonModalComponent];
		HighlightModule,
	],
	declarations: COMPONENTS,
	exports: COMPONENTS,
	providers: [
		{
			provide: HIGHLIGHT_OPTIONS,
			useValue: {
				fullLibraryLoader: () => import('highlight.js'),
			}
		}
	],
	exports: COMPONENTS
})
export class JsonModalModule {}
+8 −0
Original line number Diff line number Diff line
@@ -31,6 +31,7 @@ import { ServerConnectionService } from '@modules/client.common.angular2/service
import { ServerSettingsService } from './@core/services/server-settings.service';
import { NbEvaIconsModule } from '@nebular/eva-icons';
import { HttpLoaderFactory } from './@shared/translate/translate.module';
import { HighlightModule, HIGHLIGHT_OPTIONS } from 'ngx-highlightjs';

// It's more 'standard' way to use Font-Awesome module and special package,
// but for some reason ngx-admin works without it. So we leave next line commented for now.
@@ -66,6 +67,7 @@ import { HttpLoaderFactory } from './@shared/translate/translate.module';
			 */
			echarts: () => import('echarts')
		}),
		HighlightModule
	],
	declarations: [AppComponent],
	bootstrap: [AppComponent],
@@ -102,6 +104,12 @@ import { HttpLoaderFactory } from './@shared/translate/translate.module';
		SimpleTimer,
		AppModuleGuard,
		MaintenanceModuleGuard,
		{
			provide: HIGHLIGHT_OPTIONS,
			useValue: {
			  	fullLibraryLoader: () => import('highlight.js')
			}
		}
	],
})
export class AppModule {
+0 −1
Original line number Diff line number Diff line
@@ -34,7 +34,6 @@
		>
			<svg viewBox="0 0 24 24" width="24px">
				<path
					_ngcontent-c20=""
					d="M14.6,16.6L19.2,12L14.6,7.4L16,6L22,12L16,18L14.6,16.6M9.4,16.6L4.8,12L9.4,7.4L8,6L2,12L8,18L9.4,16.6Z"
					fill="#fff"
				></path>
+4 −4
Original line number Diff line number Diff line
@@ -10,7 +10,7 @@
		>
			<i class="ion-md-add button-icon mr-1"></i>

			<small _ngcontent-c55="">{{
			<small>{{
				'CUSTOMERS_VIEW.CREATE' | translate
			}}</small>
		</button>
@@ -24,7 +24,7 @@
		>
			<i class="ion-md-trash button-icon mr-1"></i>

			<small _ngcontent-c55="">{{
			<small>{{
				'CUSTOMERS_VIEW.DELETE' | translate
			}}</small>
		</button>
@@ -49,11 +49,11 @@
		>
			<i class="ion-md-close-circle button-icon mr-1"></i>

			<small _ngcontent-c55="" *ngIf="isUserBanned">{{
			<small *ngIf="isUserBanned">{{
				'CUSTOMERS_VIEW.UNBAN' | translate
			}}</small>

			<small _ngcontent-c55="" *ngIf="!isUserBanned">{{
			<small *ngIf="!isUserBanned">{{
				'CUSTOMERS_VIEW.BAN' | translate
			}}</small>
		</button>
+1 −1
Original line number Diff line number Diff line
@@ -16,7 +16,7 @@
					(click)="deleteSelectedDevices()"
				>
					<i class="ion-md-trash button-icon mr-1"></i>
					<small _ngcontent-c55="">{{
					<small>{{
						'CUSTOMERS_VIEW.DEVICE.DELETE' | translate
					}}</small>
				</button>
Loading