diff --git a/marketplace-ui/package.json b/marketplace-ui/package.json index 46c1adf46..fd47c7b2e 100644 --- a/marketplace-ui/package.json +++ b/marketplace-ui/package.json @@ -32,7 +32,6 @@ "markdown-it-github-alerts": "^0.3.0", "marked": "^12.0.0", "ngx-cookie-service": "^18.0.0", - "ngx-markdown": "^18.0.0", "ngx-matomo-client": "^6.3.1", "ngxtension": "^3.5.5", "rxjs": "~7.8.0", diff --git a/marketplace-ui/src/app/app.config.ts b/marketplace-ui/src/app/app.config.ts index 262cf8a03..29d1fdefa 100644 --- a/marketplace-ui/src/app/app.config.ts +++ b/marketplace-ui/src/app/app.config.ts @@ -3,8 +3,6 @@ import { ApplicationConfig, importProvidersFrom, provideZoneChangeDetection } fr import { InMemoryScrollingFeature, InMemoryScrollingOptions, provideRouter, withInMemoryScrolling } from '@angular/router'; import { TranslateLoader, TranslateModule } from '@ngx-translate/core'; import { routes } from './app.routes'; -import { MARKED_OPTIONS, MarkdownModule } from 'ngx-markdown'; -import { markedOptionsFactory } from './core/configs/markdown.config'; import { httpLoaderFactory } from './core/configs/translate.config'; import { apiInterceptor } from './core/interceptors/api.interceptor'; import { provideMatomo, withRouter } from 'ngx-matomo-client'; @@ -38,14 +36,6 @@ export const appConfig: ApplicationConfig = { deps: [HttpClient] } }) - ), - importProvidersFrom( - MarkdownModule.forRoot({ - markedOptions: { - provide: MARKED_OPTIONS, - useFactory: markedOptionsFactory - } - }) ) ] }; diff --git a/marketplace-ui/src/app/core/configs/markdown.config.ts b/marketplace-ui/src/app/core/configs/markdown.config.ts deleted file mode 100644 index bf18cb185..000000000 --- a/marketplace-ui/src/app/core/configs/markdown.config.ts +++ /dev/null @@ -1,16 +0,0 @@ -import { MarkedOptions, MarkedRenderer } from 'ngx-markdown'; - -export function markedOptionsFactory(): MarkedOptions { - const renderer = new MarkedRenderer(); - - renderer.blockquote = (text: string) => { - return '

' + text + '

'; - }; - - return { - renderer: renderer, - gfm: true, - breaks: false, - pedantic: false - }; -} diff --git a/marketplace-ui/src/app/modules/product/product-detail/product-detail.component.spec.ts b/marketplace-ui/src/app/modules/product/product-detail/product-detail.component.spec.ts index 61f15b86f..945e469d4 100644 --- a/marketplace-ui/src/app/modules/product/product-detail/product-detail.component.spec.ts +++ b/marketplace-ui/src/app/modules/product/product-detail/product-detail.component.spec.ts @@ -13,7 +13,6 @@ import { By, DomSanitizer, Title } from '@angular/platform-browser'; import { ActivatedRoute } from '@angular/router'; import { TranslateModule } from '@ngx-translate/core'; import { Viewport } from 'karma-viewport/dist/adapter/viewport'; -import { MarkdownModule } from 'ngx-markdown'; import { of } from 'rxjs'; import { TypeOption } from '../../../shared/enums/type-option.enum'; import { @@ -92,7 +91,6 @@ describe('ProductDetailComponent', () => { imports: [ ProductDetailComponent, TranslateModule.forRoot(), - MarkdownModule.forRoot(), MatomoTestingModule.forRoot() ], providers: [ diff --git a/marketplace-ui/src/app/modules/product/product-detail/product-detail.component.ts b/marketplace-ui/src/app/modules/product/product-detail/product-detail.component.ts index 50a4493c0..05f4f56b2 100644 --- a/marketplace-ui/src/app/modules/product/product-detail/product-detail.component.ts +++ b/marketplace-ui/src/app/modules/product/product-detail/product-detail.component.ts @@ -14,7 +14,6 @@ import { import { ActivatedRoute, Router } from '@angular/router'; import { NgbNavModule } from '@ng-bootstrap/ng-bootstrap'; import { TranslateModule } from '@ngx-translate/core'; -import { MarkdownModule, MarkdownService } from 'ngx-markdown'; import { forkJoin, map, Observable } from 'rxjs'; import { AuthService } from '../../../auth/auth.service'; import { LanguageService } from '../../../core/services/language/language.service'; @@ -76,7 +75,6 @@ const DEFAULT_ACTIVE_TAB = 'description'; CommonModule, ProductStarRatingNumberComponent, TranslateModule, - MarkdownModule, ProductDetailInformationTabComponent, ProductDetailMavenContentComponent, NgbNavModule, @@ -90,7 +88,7 @@ const DEFAULT_ACTIVE_TAB = 'description'; EmptyProductDetailPipe, LoadingSpinnerComponent ], - providers: [ProductService, MarkdownService], + providers: [ProductService], templateUrl: './product-detail.component.html', styleUrl: './product-detail.component.scss' }) diff --git a/marketplace-ui/src/app/modules/product/product-detail/product-installation-count-action/product-installation-count-action.component.spec.ts b/marketplace-ui/src/app/modules/product/product-detail/product-installation-count-action/product-installation-count-action.component.spec.ts index 8dfcb422f..5579313a3 100644 --- a/marketplace-ui/src/app/modules/product/product-detail/product-installation-count-action/product-installation-count-action.component.spec.ts +++ b/marketplace-ui/src/app/modules/product/product-detail/product-installation-count-action/product-installation-count-action.component.spec.ts @@ -1,7 +1,6 @@ import { ComponentFixture, TestBed } from '@angular/core/testing'; import { ProductInstallationCountActionComponent } from './product-installation-count-action.component'; -import {MarkdownModule} from "ngx-markdown"; import {TranslateModule} from "@ngx-translate/core"; describe('ProductInstallationCountActionComponent', () => { @@ -12,8 +11,7 @@ describe('ProductInstallationCountActionComponent', () => { await TestBed.configureTestingModule({ imports: [ ProductInstallationCountActionComponent, - TranslateModule.forRoot(), - MarkdownModule.forRoot() + TranslateModule.forRoot() ] }) .compileComponents();