\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n {{ category.attributes.title }}\r\n \r\n \r\n\r\n \r\n \r\n \r\n {{ publishedFrom | date: 'shortDate':'':'pl' }}\r\n \r\n {{ title }}\r\n \r\n {{ description }}\r\n \r\n \r\n \r\n
| null = null;\r\n loading: boolean;\r\n getError: boolean;\r\n private destroyed$: Subject = new Subject();\r\n\r\n constructor(\r\n protected route: ActivatedRoute,\r\n protected articleService: ArticlesService,\r\n protected imageZoomService: ImageZoomService,\r\n protected cdr: ChangeDetectorRef,\r\n protected facadeService: FacadeService,\r\n private elementService: ElementService\r\n ) {\r\n this.setSlug();\r\n }\r\n\r\n setLoader(value: boolean) {\r\n this.loading = value;\r\n this.cdr.detectChanges();\r\n }\r\n\r\n protected setSlug() {\r\n const elements: UrlSegment[] = this.route.snapshot.url;\r\n this.slug = this.route.snapshot.url[elements.length - 1].path;\r\n }\r\n\r\n ngOnInit() {\r\n this.loadArticle();\r\n this.elementService.sameComponentNavigation.pipe(takeUntil(this.destroyed$)).subscribe(() => this.loadArticle());\r\n }\r\n\r\n loadArticle() {\r\n this.setLoader(true);\r\n this.article = null;\r\n this.setSlug();\r\n this.articleService\r\n .getOne(this.slug)\r\n .pipe(\r\n first(),\r\n finalize(() => this.setLoader(false))\r\n )\r\n .subscribe(\r\n response => this.onLoadArticleSuccess(response),\r\n () => (this.getError = true)\r\n );\r\n }\r\n\r\n protected onLoadArticleSuccess(response: ResponseObject) {\r\n this.article = response.data;\r\n this.facadeService.subheader.config.title = this.article.attributes.title;\r\n this.facadeService.subheader.config.displayBreadcrumbs.next(true);\r\n this.facadeService.subheader.categories = this.article.attributes.categories;\r\n this.facadeService.subheader.publishedDate = this.article.attributes.createdAt;\r\n this.facadeService.subheader.image = this.article.attributes.file || this.article.attributes.file['croppedImage'];\r\n this.imageZoomService.setListener();\r\n this.facadeService.scrollTo.resetScrollTop();\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.destroyed$.next(true);\r\n this.destroyed$.complete();\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n {{ 'articles.seeAlso' | trans }}\r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n\r\n","export { ArticleComponent } from './article/article.component';\r\nexport { ArticleListComponent } from './article-list/article-list.component';\r\nexport { ArticleListItemComponent } from './article-list-item/article-list-item.component';\r\nexport { ArticleListRandomComponent } from './article-list-random/article-list-random.component';\r\n","import { Injectable } from '@angular/core';\r\nimport { API } from '@app/common/constants/api.directories';\r\nimport { Article } from '@app/client-core/article/models/article.model';\r\nimport { ResponseArray, ResponseObject } from '@share/common/models/http';\r\nimport { Observable } from 'rxjs';\r\nimport { HttpParams } from '@angular/common/http';\r\nimport { ElementService } from '@app/client-core/dynamic-content/service/element.service';\r\nimport { Preview } from '@app/client-core/preview/interfaces/preview.interface';\r\nimport { first } from 'rxjs/operators';\r\nimport { ApiService } from '@app/common/services/api.service';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ArticlesService implements Preview {\r\n constructor(protected element: ElementService, private apiService: ApiService) {}\r\n\r\n getList(\r\n page: number,\r\n count: number,\r\n category?: string | null,\r\n slug?: string | null,\r\n ): Observable> {\r\n let params: HttpParams = new HttpParams().append('page', page.toString()).append('count', count.toString());\r\n if (category) {\r\n params = params.set('category', category);\r\n } else if (slug) {\r\n params = params.append('categorySlug', slug);\r\n } else if (this.element.objectId) {\r\n params = params.set('category', this.element.objectId);\r\n }\r\n return this.apiService.getAll(`${API.ARTICLES.ROOT}`, params);\r\n }\r\n\r\n\r\n getRandomArticles(expect: string, count: number = 3) {\r\n let params: HttpParams = new HttpParams()\r\n .append('limit', count.toString())\r\n .append('except', expect);\r\n return this.apiService.getAll(`${API.ARTICLES.RANDOM}`, params);\r\n }\r\n\r\n getOne(slug: string): Observable> {\r\n return this.apiService.get(`${API.ARTICLES.ROOT}/${slug}`).pipe(first());\r\n }\r\n}\r\n","import { ChangeDetectionStrategy, Component, OnInit } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { CookieService } from '@app/client-core/cookies/service/cookie.service';\r\n\r\n@Component({\r\n selector: 'app-cookie-information-bar',\r\n templateUrl: './cookie-information-bar.component.html',\r\n styleUrls: ['./cookie-information-bar.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class CookieInformationBarComponent extends ComponentHelper implements OnInit {\r\n\r\n public cookieText: string = '';\r\n\r\n constructor(private settings: SettingsService, private cookieService: CookieService) {\r\n super();\r\n }\r\n\r\n get isCookieAccepted(): string {\r\n return this.cookieService.getCookie('cookiesAccepted');\r\n }\r\n\r\n ngOnInit() {\r\n try {\r\n this.cookieText = this.settings.variables.footer.cookieWarningContent;\r\n } catch (ignore) {\r\n throw new Error('Cannot get cookieWarningContent of undefined');\r\n }\r\n }\r\n\r\n accept(): void {\r\n this.cookieService.setCookie('cookiesAccepted', 'true', 365);\r\n }\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { CookieInformationBarComponent } from './components/cookie-information-bar/cookie-information-bar.component';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\n\r\n@NgModule({\r\n declarations: [CookieInformationBarComponent],\r\n imports: [\r\n CommonModule,\r\n ElementsModule,\r\n TranslatorModule\r\n ],\r\n exports: [\r\n CookieInformationBarComponent\r\n ]\r\n\r\n})\r\nexport class CookiesModule {\r\n}\r\n","import { Injectable } from '@angular/core';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class CookieService {\r\n\r\n constructor() {\r\n }\r\n\r\n public getCookie(name: string) {\r\n const ca: Array = document.cookie.split(';');\r\n const caLen: number = ca.length;\r\n const cookieName = `${name}=`;\r\n let c: string;\r\n\r\n for (let i = 0; i < caLen; i += 1) {\r\n c = ca[i].replace(/^\\s+/g, '');\r\n if (c.indexOf(cookieName) === 0) {\r\n return c.substring(cookieName.length, c.length);\r\n }\r\n }\r\n return '';\r\n }\r\n\r\n public setCookie(name: string, value: string, expireDays: number = 0): void {\r\n let cookie = '';\r\n cookie += `${name}=${value};`;\r\n const d: Date = new Date();\r\n if (expireDays !== 0) {\r\n d.setTime(d.getTime() + expireDays * 24 * 60 * 60 * 1000);\r\n\r\n cookie += `expires=${d.toString()}`;\r\n }\r\n document.cookie = cookie;\r\n\r\n }\r\n\r\n}\r\n","import { AfterViewInit, Component, OnDestroy, ViewChild, ViewContainerRef } from '@angular/core';\r\nimport { ActivatedRoute, Router } from '@angular/router';\r\nimport { DynamicContentService } from '@app/client-core/dynamic-content/service/dynamic-content.service';\r\nimport { LazyLoaderService } from '@app/common/services/lazy-loader.service';\r\nimport { switchMap, takeUntil, tap } from 'rxjs/operators';\r\nimport { of, Subject } from 'rxjs';\r\nimport { ROUTES_PATHS } from '@app/common/constants/routes-paths';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { ComponentInterface } from '@app/client-core/dynamic-content/interfaces/components.interface';\r\nimport { Nullable } from '@share/common/types/utilities.types';\r\nimport { BreadcrumbsService } from '@app/template/layout/modules/header/services/breadcrumbs.service';\r\nimport { ElementService } from '@app/client-core/dynamic-content/service/element.service';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { HOME_COMPONENTS } from '@app/client-core/dynamic-content/constants/component-list';\r\n\r\n@Component({\r\n selector: 'app-dynamic-content',\r\n templateUrl: './dynamic-content.component.html',\r\n styleUrls: ['./dynamic-content.component.scss']\r\n})\r\nexport class DynamicContentComponent implements AfterViewInit, OnDestroy {\r\n @ViewChild('componentPlaceholder', { read: ViewContainerRef }) componentPlaceholder: ViewContainerRef;\r\n private currentView: string;\r\n private destroy$: Subject = new Subject();\r\n\r\n constructor(\r\n private dynamic: DynamicContentService,\r\n private router: Router,\r\n private lazyLoaderService: LazyLoaderService,\r\n private facadeService: FacadeService,\r\n private breadcrumbsService: BreadcrumbsService,\r\n private elementsService: ElementService,\r\n private settingsService: SettingsService,\r\n ) {}\r\n\r\n async ngAfterViewInit() {\r\n this.dynamic.runtimeUrlReader$\r\n .pipe(\r\n takeUntil(this.destroy$),\r\n switchMap((rawUrl: string) => {\r\n if (rawUrl.includes('#')) {\r\n return of(null);\r\n } else {\r\n if (rawUrl === '/') {\r\n return of(this.getHomeComponent()).pipe(\r\n tap((component: Nullable) => (this.dynamic.homeComponent = component))\r\n );\r\n }\r\n return this.dynamic.componentLoader(rawUrl);\r\n }\r\n })\r\n )\r\n .subscribe(\r\n (component: Nullable) => {\r\n this.loadView(component);\r\n },\r\n () => this.componentNotFoundNavigation()\r\n );\r\n }\r\n\r\n private getHomeComponent(): ComponentInterface {\r\n const { name } = this.settingsService.variables.theme;\r\n return { ...HOME_COMPONENTS[name], isHome: true };\r\n }\r\n\r\n private loadView(component: Nullable) {\r\n if (component && component.className !== this.currentView) {\r\n this.breadcrumbsService.reset();\r\n this.facadeService.subheader.reset();\r\n this.componentPlaceholder?.clear();\r\n this.lazyLoaderService.load(component.module, this.componentPlaceholder, component.name).then(() => {\r\n this.facadeService.scrollTo.resetScrollTop();\r\n this.dynamic.loaded = true;\r\n this.currentView = component?.className;\r\n });\r\n } else if (component) {\r\n this.navigateToHomeDefaultContext(component);\r\n this.breadcrumbsService.reset();\r\n this.dynamic.loaded = true;\r\n this.elementsService.loaded = true;\r\n }\r\n this.facadeService.scrollTo.resetScrollTop();\r\n }\r\n\r\n private navigateToHomeDefaultContext(component: null | ComponentInterface) {\r\n if (component?.defaultContext && component?.isHome) {\r\n this.router.navigate([component?.defaultContext]);\r\n }\r\n }\r\n\r\n private componentNotFoundNavigation() {\r\n this.router.navigate(['/', ROUTES_PATHS.notFoundPage.root]);\r\n }\r\n\r\n ngOnDestroy() {\r\n this.destroy$.next(true);\r\n this.destroy$.complete();\r\n }\r\n}\r\n","\r\n","import { StaticPageComponent } from '@app/client-core/static-pages/components/static-page/static-page.component';\r\nimport { ArticleListComponent } from '@app/client-core/article/components/article-list/article-list.component';\r\nimport { ThemesEnum } from '@app/common/models/themes.enum';\r\nimport { ComponentsInterface } from '@app/client-core/dynamic-content/interfaces/components.interface';\r\nimport { OverlayComponent } from '@app/template/home/components/overlay/overlay.component';\r\nimport { ArticleComponent } from '@app/client-core/article/components';\r\n\r\nexport const COMPONENTS: ComponentsInterface = {\r\n main: { name: OverlayComponent, module: ThemesEnum.CORE, className: 'OverlayComponent' },\r\n static: { name: StaticPageComponent, module: ThemesEnum.CORE, className: 'StaticPageComponent' },\r\n articlecategory: { name: ArticleListComponent, module: ThemesEnum.ARTICLE, className: 'ArticleListComponent' },\r\n article: { name: ArticleComponent, module: ThemesEnum.ARTICLE, className: 'ArticleComponent' }\r\n};\r\n\r\nexport enum ThemeName {\r\n Basic = 'podstawowy'\r\n}\r\n\r\nexport const HOME_COMPONENTS: ComponentsInterface = {\r\n [ThemeName.Basic]: { name: OverlayComponent, module: ThemesEnum.CORE, className: 'OverlayComponent' }\r\n};\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { DynamicContentComponent } from './component/dynamic-content/dynamic-content.component';\r\nimport { ProgressBarModule } from '@share/modules/progress-bar/progress-bar.module';\r\nimport { StaticPagesModule } from '@app/client-core/static-pages/static-pages.module';\r\nimport { ArticleModule } from '@app/client-core/article/article.module';\r\nimport { HomeModule } from '@app/template/home/home.module';\r\nimport { DynamicUtilsService } from '@app/client-core/dynamic-content/service/dynamic-utils.service';\r\n\r\n@NgModule({\r\n declarations: [DynamicContentComponent],\r\n imports: [\r\n CommonModule,\r\n ProgressBarModule,\r\n StaticPagesModule,\r\n ArticleModule,\r\n HomeModule\r\n ],\r\n providers: [DynamicUtilsService],\r\n exports: [\r\n DynamicContentComponent\r\n ]\r\n})\r\nexport class DynamicContentModule {\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { API } from '@app/common/constants/api.directories';\r\nimport { COMPONENTS } from '@app/client-core/dynamic-content/constants/component-list';\r\nimport { BehaviorSubject, Observable, of, throwError } from 'rxjs';\r\nimport { MetaResponse, ResponseDefault } from '@share/common/models/http.model';\r\nimport { Nullable } from '@share/common/types/utilities.types';\r\nimport { ComponentInterface } from '@app/client-core/dynamic-content/interfaces/components.interface';\r\nimport { distinctUntilChanged, filter, map, startWith, switchMap, tap } from 'rxjs/operators';\r\nimport { ApiService } from '@app/common/services/api.service';\r\nimport { NavigationEnd, Router } from '@angular/router';\r\nimport { DynamicUtilsService } from '@app/client-core/dynamic-content/service/dynamic-utils.service';\r\nimport { ElementService } from '@app/client-core/dynamic-content/service/element.service';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class DynamicContentService {\r\n private _loaded: BehaviorSubject = new BehaviorSubject(true);\r\n loaded$: Observable = this._loaded.asObservable().pipe(distinctUntilChanged());\r\n homeComponent: Nullable;\r\n\r\n constructor(\r\n private apiService: ApiService,\r\n private router: Router,\r\n private dynamicUtilsService: DynamicUtilsService,\r\n private elementService: ElementService\r\n ) {}\r\n\r\n set loaded(value: boolean) {\r\n this._loaded.next(value);\r\n }\r\n\r\n get runtimeUrlReader$(): Observable {\r\n return this.router.events.pipe(\r\n startWith(new NavigationEnd(0, this.router.url, this.router.url)),\r\n filter((e: any): e is NavigationEnd => e instanceof NavigationEnd),\r\n map((event: NavigationEnd) => event.url)\r\n );\r\n }\r\n\r\n componentLoader(rawUrl: string): Observable> {\r\n return of(rawUrl).pipe(\r\n map((rawUrl: string) => this.dynamicUtilsService.parseUrlToBeProcessable(rawUrl)),\r\n switchMap((url: string) => this.getPageMetadata(url)),\r\n tap(response => {\r\n if (response?.meta?.objectId) {\r\n this.elementService.objectId = response?.meta?.objectId\r\n }\r\n }),\r\n map((response: any) => response.meta),\r\n switchMap((metadata: MetaResponse) => this.getComponentByType(metadata?.type))\r\n );\r\n }\r\n\r\n private getComponentByType(type: string | undefined): Observable> {\r\n if (type) {\r\n const component: Nullable = this.getComponent(type);\r\n if (!component) {\r\n return throwError(`Not found component ${type}`);\r\n }\r\n return of(component);\r\n } else {\r\n return throwError(`Component's type is not provided: ${type}`);\r\n }\r\n }\r\n\r\n getPageMetadata(url: string): Observable {\r\n return this.apiService.get(`${API.DYNAMIC_CONTENT.ROOT}${url && url != ' ' ? '/' + url : ''}`);\r\n }\r\n\r\n private getComponent(module: string): Nullable {\r\n try {\r\n return COMPONENTS[module.toLowerCase()];\r\n } catch (e) {\r\n return null;\r\n }\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\n\r\n@Injectable()\r\nexport class DynamicUtilsService {\r\n parseUrlToBeProcessable(url: string): string {\r\n let parsed: string = url.split('/').join(',');\r\n return parsed === ',' ? '' : parsed;\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { BehaviorSubject, Observable } from 'rxjs';\r\nimport { Nullable } from '@share/common/types/utilities.types';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ElementService {\r\n private _objectId: BehaviorSubject> = new BehaviorSubject>(null);\r\n private _sameComponentNavigation: BehaviorSubject = new BehaviorSubject(false);\r\n\r\n public get getObjectId(): Observable> {\r\n return this._objectId.asObservable();\r\n }\r\n\r\n public get objectId(): Nullable {\r\n return this._objectId.getValue();\r\n }\r\n\r\n public set objectId(value: Nullable) {\r\n this._objectId.next(value);\r\n }\r\n\r\n public get sameComponentNavigation(): Observable {\r\n return this._sameComponentNavigation.asObservable();\r\n }\r\n\r\n public set loaded(value: boolean) {\r\n this._sameComponentNavigation.next(value);\r\n }\r\n\r\n}\r\n","import {\r\n ChangeDetectionStrategy,\r\n ChangeDetectorRef,\r\n Component,\r\n ElementRef,\r\n EventEmitter,\r\n Input,\r\n Output,\r\n Renderer2\r\n} from '@angular/core';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { MenuModel } from '@app/client-core/menu/models/menu.model';\r\nimport { MenuService } from '@app/client-core/menu/services/menu.service';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\n\r\n@Component({\r\n selector: 'app-default-menu',\r\n templateUrl: './default-menu.component.html',\r\n styleUrls: ['./default-menu.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class DefaultMenuComponent {\r\n @Input() menu: AbstractData[];\r\n @Input() isMenuWidthChecking: boolean;\r\n @Input() isLoading: boolean;\r\n\r\n @Output() refreshed: EventEmitter = new EventEmitter();\r\n\r\n getError: boolean;\r\n open: { [id: string]: boolean } = {};\r\n\r\n constructor(\r\n private menuService: MenuService,\r\n private facadeService: FacadeService,\r\n private renderer: Renderer2,\r\n private cdr: ChangeDetectorRef,\r\n private _elementRef: ElementRef\r\n ) {}\r\n\r\n onMouseOver(id: string) {\r\n this.open[id] = true;\r\n }\r\n\r\n hideSubmenu() {\r\n for(let key in this.open) {\r\n this.open[key] = false;\r\n }\r\n }\r\n\r\n onComponentRefresh() {\r\n this.refreshed.emit();\r\n }\r\n}\r\n","\r\n Menu główne\r\n \r\n \r\n \r\n \r\n 0\">\r\n \r\n {{ item.attributes.title }}\r\n \r\n\r\n 12 ? '60' : '30'\" [class.show]=\"open[item.id]\" [attr.aria-labelledby]=\"item.attributes.title\">\r\n \r\n \r\n \r\n \r\n {{ child.attributes.highlightedContent }}\r\n\r\n \r\n \r\n {{ child.attributes.title }}\r\n \r\n\r\n\r\n \r\n \r\n {{ child.attributes.title }}\r\n \r\n\r\n \r\n \r\n\r\n \r\n \r\n \r\n {{ child.attributes.title }}\r\n \r\n\r\n \r\n \r\n {{ child.attributes.title }}\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n {{ item.attributes.title }}\r\n \r\n\r\n \r\n {{ item.attributes.title }}\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import {\r\n AfterViewInit,\r\n ChangeDetectionStrategy,\r\n ChangeDetectorRef,\r\n Component,\r\n ElementRef,\r\n Input,\r\n OnDestroy,\r\n ViewChild\r\n} from '@angular/core';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { MenuModel } from '@app/client-core/menu/models/menu.model';\r\nimport { MenuService } from '@app/client-core/menu/services/menu.service';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { filter, takeUntil, tap } from 'rxjs/operators';\r\nimport { fromEvent, Subject } from 'rxjs';\r\n\r\ndeclare var $: any;\r\n\r\n@Component({\r\n selector: 'app-mobile-menu',\r\n templateUrl: 'mobile-menu.component.html',\r\n styleUrls: ['mobile-menu.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class MobileMenuComponent implements OnDestroy, AfterViewInit {\r\n private destroy$: Subject = new Subject();\r\n\r\n @Input() menu: AbstractData[];\r\n\r\n @ViewChild('sidebarMobile') sidebarMobile: ElementRef;\r\n\r\n getError: boolean;\r\n getLoading: boolean;\r\n open: boolean;\r\n shownComplete: boolean;\r\n\r\n constructor(private menuService: MenuService,\r\n private facadeService: FacadeService,\r\n private cdr: ChangeDetectorRef,\r\n private _elementRef: ElementRef) {}\r\n\r\n ngOnInit() {\r\n this.shownComplete = true;\r\n this.listenForServiceChange();\r\n this.handleOutsideClick();\r\n }\r\n\r\n ngOnDestroy() {\r\n this.destroy$.next(true);\r\n this.destroy$.complete();\r\n }\r\n\r\n listenForServiceChange() {\r\n this.menuService.isMobileMenuActive$.pipe(takeUntil(this.destroy$)).subscribe(isActive => {\r\n if (!isActive) {\r\n this.hide();\r\n }\r\n });\r\n }\r\n\r\n hide() {\r\n this.open = false;\r\n $('.navbar-collapse').collapse('hide');\r\n this.cdr.detectChanges();\r\n }\r\n\r\n toggleMenu() {\r\n if (this.shownComplete) {\r\n this.shownComplete = false;\r\n this.open = !this.open;\r\n }\r\n }\r\n\r\n ngAfterViewInit() {\r\n $('.navbar-collapse')\r\n .on('shown.bs.collapse', () => (this.shownComplete = true))\r\n .on('hidden.bs.collapse', () => (this.shownComplete = true))\r\n }\r\n\r\n setLoader(value: boolean) {\r\n this.getLoading = value;\r\n this.cdr.detectChanges();\r\n }\r\n\r\n parseId(id: string): string {\r\n return id.replace(/ /g,'')\r\n }\r\n\r\n handleOutsideClick() {\r\n const clickEvent$ = fromEvent(document, 'click');\r\n clickEvent$\r\n .pipe(\r\n takeUntil(this.destroy$),\r\n filter(e => !this._elementRef.nativeElement.contains(e.target)),\r\n tap(() => this.hide())\r\n )\r\n .subscribe();\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n 0; else defaultMenuItem\">\r\n {{ item.attributes.title }}\r\n \r\n \r\n \r\n \r\n\r\n \r\n\r\n \r\n {{\r\n item.attributes.title\r\n }}\r\n \r\n\r\n \r\n {{\r\n item.attributes.title\r\n }}\r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { HttpClientModule } from '@angular/common/http';\r\nimport { LogoModule } from '@app/template/layout/modules/logo/logo.module';\r\nimport { DefaultMenuComponent } from './components/default-menu/default-menu.component';\r\nimport { RouterModule } from '@angular/router';\r\nimport { PolygonModule } from '@app/template/elements/polygon/polygon.module';\r\nimport { MobileMenuComponent } from '@app/client-core/menu/components/mobile-menu/mobile-menu.component';\r\n\r\n@NgModule({\r\n declarations: [MobileMenuComponent, DefaultMenuComponent],\r\n imports: [CommonModule, HttpClientModule, RouterModule, ElementsModule, TranslatorModule, LogoModule, PolygonModule],\r\n exports: [DefaultMenuComponent, MobileMenuComponent]\r\n})\r\nexport class MenuModule {}\r\n","import { Injectable } from '@angular/core';\r\nimport { BehaviorSubject, Observable, of } from 'rxjs';\r\nimport { MenuModel } from '@app/client-core/menu/models/menu.model';\r\nimport { ResponseArray } from '@share/common/models/http';\r\nimport { API } from '@app/common/constants/api.directories';\r\nimport { ApiService } from '@app/common/services/api.service';\r\nimport { Router } from '@angular/router';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class MenuService {\r\n\r\n isMobileMenuActive$: BehaviorSubject = new BehaviorSubject(false);\r\n\r\n constructor(private apiService: ApiService, private router: Router) {\r\n }\r\n\r\n public getList(type?: string): Observable> {\r\n return this.apiService.getAll(`${API.MENU.ROOT}${type ? `/${type}` : ''}`);\r\n }\r\n\r\n public navigate(type: string, url: string): Promise {\r\n if (type === 'link') {\r\n return new Promise((resolve) => {\r\n window.open(url);\r\n resolve(true);\r\n });\r\n } else {\r\n if (!url || url.includes('null')) {\r\n return this.router.navigate(['/']);\r\n } else {\r\n return this.router.navigateByUrl('/' + url);\r\n }\r\n }\r\n }\r\n\r\n public isActive(url: string): boolean {\r\n return this.router.isActive(url, true);\r\n }\r\n\r\n}\r\n","import { ChangeDetectionStrategy, ChangeDetectorRef, Component, Inject, OnDestroy } from '@angular/core';\r\nimport { SUBHEADER_INJECTION_TOKEN } from '@app/client-core/search/subheader-injection-token';\r\nimport { Observable, Subject } from 'rxjs';\r\nimport { takeUntil } from 'rxjs/operators';\r\n\r\n@Component({\r\n selector: 'app-search-results-subheader',\r\n templateUrl: 'search-results-subheader.component.html',\r\n styleUrls: ['search-results-subheader.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class SearchResultsSubheaderComponent implements OnDestroy {\r\n private destroy$: Subject = new Subject();\r\n\r\n amount: number;\r\n keyword: string;\r\n\r\n constructor(\r\n @Inject(SUBHEADER_INJECTION_TOKEN) data: Observable<{ amount: number; keyword: string }>,\r\n private cdr: ChangeDetectorRef\r\n ) {\r\n data.pipe(takeUntil(this.destroy$)).subscribe(data => {\r\n this.amount = data.amount;\r\n this.keyword = data.keyword;\r\n this.cdr.detectChanges();\r\n });\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.destroy$.next(true);\r\n this.destroy$.complete();\r\n }\r\n}\r\n","\r\n {{ keyword }} - Wyniki wyszukiwania\r\n \r\n Znaleziono\r\n {{ amount || 0 }} wyników\r\n \r\n\r\n","import { ChangeDetectorRef, Component, Injector, OnDestroy, OnInit } from '@angular/core';\r\nimport { ActivatedRoute } from '@angular/router';\r\nimport { SearchService } from '@app/client-core/search/services/search.service';\r\nimport { SearchItem } from '@app/client-core/search/models/search-item.model';\r\nimport { SearchType } from '@app/template/layout/modules/header/interfaces/subheader-config.interface';\r\nimport { BreadcrumbsService } from '@app/template/layout/modules/header/services/breadcrumbs.service';\r\nimport { combineLatest } from 'rxjs/internal/observable/combineLatest';\r\nimport { finalize, first, map, takeUntil, tap } from 'rxjs/operators';\r\nimport { PaginationService } from '@app/template/elements/pagination/services/pagination.service';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { SearchResultsSubheaderComponent } from '@app/client-core/search/components/search-results-subheader/search-results-subheader.component';\r\nimport { Subject } from 'rxjs';\r\nimport { SearchHelperService } from '@app/client-core/search/search-helper.service';\r\nimport { SUBHEADER_INJECTION_TOKEN } from '@app/client-core/search/subheader-injection-token';\r\nimport { ResponseArray } from '@share/common/models/http';\r\n\r\n@Component({\r\n selector: 'app-search-results',\r\n templateUrl: './search-results.component.html',\r\n styleUrls: ['./search-results.component.scss']\r\n})\r\nexport class SearchResultsComponent implements OnInit, OnDestroy {\r\n searchedWord: string;\r\n data: { articles: SearchItem[]; pages: SearchItem[] } = { articles: [], pages: [] };\r\n type: SearchType;\r\n pages: number = 1;\r\n count: number = 20;\r\n getLoading: boolean;\r\n getError: boolean;\r\n destroyed$: Subject = new Subject();\r\n\r\n private searchMetadata: Subject<{ amount: number; keyword: string }> = new Subject<{\r\n amount: number;\r\n keyword: string;\r\n }>();\r\n\r\n constructor(\r\n private activatedRoute: ActivatedRoute,\r\n private searchService: SearchService,\r\n private breadcrumbsService: BreadcrumbsService,\r\n private paginationService: PaginationService,\r\n private facadeService: FacadeService,\r\n private injector: Injector,\r\n private searchHelperService: SearchHelperService,\r\n private cdr: ChangeDetectorRef\r\n ) {\r\n this.setSubheader();\r\n this.setBreadcrumbs();\r\n }\r\n\r\n private setSubheader() {\r\n this.facadeService.subheader.setConfig({\r\n component: SearchResultsSubheaderComponent,\r\n injector: Injector.create({\r\n providers: [\r\n {\r\n provide: SUBHEADER_INJECTION_TOKEN,\r\n useValue: this.searchMetadata\r\n }\r\n ],\r\n parent: this.injector\r\n })\r\n });\r\n this.facadeService.subheader.config.displayBreadcrumbs.next(true);\r\n }\r\n\r\n public ngOnInit() {\r\n this.setPageListener();\r\n window.scrollTo(0, 0);\r\n }\r\n\r\n setLoader(value: boolean) {\r\n this.getLoading = value;\r\n this.cdr.detectChanges();\r\n }\r\n\r\n public searchRequest(page: number) {\r\n this.clearData();\r\n this.setLoader(true);\r\n this.searchService\r\n .getFullList(this.searchedWord, this.type, page, this.count)\r\n .pipe(\r\n first(),\r\n tap(response => (this.searchService.amount = response.data.length)),\r\n finalize(() => this.setLoader(false))\r\n )\r\n .subscribe(response => this.onResponseSuccess(response));\r\n }\r\n\r\n onResponseSuccess(response: ResponseArray) {\r\n this.clearData();\r\n this.searchMetadata.next({ amount: response?.meta?.amount || 0, keyword: this.searchedWord });\r\n response.data?.forEach((item: any) => {\r\n if (item.type === 'Page') {\r\n this.data = { articles: [...this.data.articles], pages: [...this.data.pages, item] };\r\n } else if (item.type === 'CmsArticle') {\r\n this.data = { articles: [...this.data.articles, item], pages: [...this.data.pages] };\r\n }\r\n });\r\n const meta = response.meta;\r\n if (meta && typeof meta.pages === 'number') {\r\n this.pages = meta.pages;\r\n }\r\n }\r\n\r\n identify(index: number) {\r\n return index;\r\n }\r\n\r\n private clearData() {\r\n this.data = {\r\n articles: [],\r\n pages: []\r\n };\r\n }\r\n\r\n navigateTo(url: string, isExternal: boolean) {\r\n if (isExternal) {\r\n window.open(url);\r\n } else {\r\n this.facadeService.router.navigate([url]);\r\n }\r\n }\r\n\r\n private setBreadcrumbs() {\r\n this.breadcrumbsService.forceActive = true;\r\n this.breadcrumbsService.customBreadcrumbs = [{ title: this.facadeService.translator.trans('search.header') }];\r\n }\r\n\r\n private setPageListener() {\r\n combineLatest([this.activatedRoute.params, this.paginationService.currentPage])\r\n .pipe(\r\n map(results => ({ data: results[0].data, page: results[1] })),\r\n takeUntil(this.destroyed$)\r\n )\r\n .subscribe(results => {\r\n this.searchedWord = results.data;\r\n this.searchRequest(results.page);\r\n });\r\n }\r\n\r\n ngOnDestroy() {\r\n this.destroyed$.next(true);\r\n this.destroyed$.complete();\r\n this.breadcrumbsService.forceActive = false;\r\n }\r\n}\r\n","\r\n \r\n \r\n 0\">\r\n Artykuły\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n 0\">\r\n Strony\r\n \r\n {{ item.attributes.content }}\r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { ChangeDetectorRef, Component, ElementRef, Input, OnDestroy, OnInit, ViewChild } from '@angular/core';\r\nimport { SearchService } from '@app/client-core/search/services/search.service';\r\nimport { SearchItem } from '@app/client-core/search/models/search-item.model';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { NavigationExtras } from '@angular/router';\r\nimport { SearchType } from '@app/template/layout/modules/header/interfaces/subheader-config.interface';\r\nimport { fromEvent, Observable, Subject } from 'rxjs';\r\nimport { filter, finalize, first, takeUntil, tap } from 'rxjs/operators';\r\nimport { UtilsService } from '@share/common/services/utils.service';\r\nimport { SelectModel } from '@share/modules/html/common/interfaces/select-model.interface';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { ThemesEnum } from '@app/common/models/themes.enum';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { ResizeListener } from '@app/common/services/resize-listener.service';\r\n\r\n@Component({\r\n selector: 'app-search',\r\n templateUrl: './search.component.html',\r\n styleUrls: ['./search.component.scss']\r\n})\r\nexport class SearchComponent implements OnInit, OnDestroy {\r\n\r\n private _value = '';\r\n private readonly minLength: number = 3;\r\n private destroy$: Subject = new Subject();\r\n\r\n @ViewChild('input') input: ElementRef;\r\n @Input() mobile: boolean;\r\n @Input() placeholder: string = 'search.button';\r\n\r\n data: { articles: SearchItem[]; pages: SearchItem[] } = { articles: [], pages: [] };\r\n availablesTypes: Array> = [];\r\n type: SearchType = SearchType.Default;\r\n searchSelectId: string;\r\n searchId: string;\r\n showResultsBox: boolean;\r\n loading: boolean;\r\n error: boolean;\r\n forceActive: boolean;\r\n isActive$: Observable;\r\n\r\n\r\n constructor(\r\n private searchService: SearchService,\r\n private _elementRef: ElementRef,\r\n private utils: UtilsService,\r\n private settingsService: SettingsService,\r\n private cdr: ChangeDetectorRef,\r\n private facadeService: FacadeService,\r\n ) {\r\n this.availablesTypes = this.searchService.getAvailableSearchTypes();\r\n const newId: string = this.utils.makeId();\r\n this.searchSelectId = `search-type-${newId}`;\r\n this.searchId = `search-input-${newId}`;\r\n }\r\n\r\n markAsActive() {\r\n this.searchService.isActive$.next(true);\r\n setTimeout(() => {\r\n this.forceActive = true;\r\n this.input.nativeElement.focus();\r\n }, 500)\r\n }\r\n\r\n markAsInactive(){\r\n this.searchService.isActive$.next(false);\r\n this.forceActive = false;\r\n this.showResultsBox = false;\r\n }\r\n\r\n onValueChange(value: string) {\r\n if (value.length >= 3) {\r\n this.showResultsBox = true;\r\n this.searchRequest(value);\r\n } else {\r\n this.showResultsBox = false;\r\n }\r\n this.value = value;\r\n }\r\n\r\n ngOnInit() {\r\n this.setSearchType();\r\n this.handleOutsideClick();\r\n this.isActive$ = this.searchService.isActive$;\r\n }\r\n\r\n private setSearchType() {\r\n this.facadeService.subheader.getConfig().subscribe(config => {\r\n this.type = config.searchType || SearchType.Default;\r\n });\r\n }\r\n\r\n handleOutsideClick() {\r\n const clickEvent$ = fromEvent(document, 'click');\r\n clickEvent$\r\n .pipe(\r\n takeUntil(this.destroy$),\r\n filter(e => !this._elementRef.nativeElement.contains(e.target)),\r\n tap(e => {\r\n this.clear();\r\n this.markAsInactive();\r\n })\r\n )\r\n .subscribe();\r\n }\r\n\r\n get value() {\r\n return this._value;\r\n }\r\n\r\n set value(data: string) {\r\n this._value = data;\r\n }\r\n\r\n hasMinLength(value: string) {\r\n const valid = value.length >= this.minLength;\r\n if (!valid) {\r\n this.clearData();\r\n }\r\n return valid;\r\n }\r\n\r\n search() {\r\n if (this.hasMinLength(this.value)) {\r\n this.markAsInactive();\r\n this.facadeService.router.navigate(['search', this._value], this.getNavigationExtras()).then(onfulfilled => {\r\n if (onfulfilled) {\r\n this.clear();\r\n }\r\n });\r\n }\r\n }\r\n\r\n private getNavigationExtras() {\r\n const extra: NavigationExtras = { queryParams: null };\r\n if (this.type !== SearchType.Default) {\r\n extra.queryParams = { type: this.type };\r\n }\r\n return extra;\r\n }\r\n\r\n setLoader(value: boolean) {\r\n this.loading = value;\r\n this.cdr.detectChanges();\r\n }\r\n\r\n searchRequest(value: string) {\r\n this.setLoader(true);\r\n this.clearData();\r\n this.searchService\r\n .getList(value, this.type)\r\n .pipe(\r\n first(),\r\n finalize(() => this.setLoader(false))\r\n )\r\n .subscribe(response => {\r\n this.clearData();\r\n response.data?.forEach((item: any) => {\r\n if (item.type === 'Page') {\r\n this.data = { articles: [...this.data.articles], pages: [...this.data.pages, item] };\r\n } else if (item.type === 'CmsArticle') {\r\n this.data = { articles: [...this.data.articles, item], pages: [...this.data.pages] };\r\n }\r\n });\r\n });\r\n }\r\n\r\n private clear() {\r\n this._value = '';\r\n this.clearData();\r\n this.showResultsBox = false;\r\n }\r\n\r\n private clearData() {\r\n this.data = {\r\n articles: [],\r\n pages: []\r\n }\r\n }\r\n\r\n ngOnDestroy() {\r\n this.destroy$.next(true);\r\n this.destroy$.complete();\r\n }\r\n}\r\n","\r\n \r\n {{'search.searchLabel' | trans}}\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n 0 || data.articles.length > 0\" [error]=\"error\">\r\n \r\n 0\">\r\n {{'search.pages' | trans}}\r\n \r\n {{ item.attributes.title }}\r\n \r\n \r\n\r\n 0\">\r\n {{'search.articles' | trans}}\r\n \r\n {{ item.attributes.title }}\r\n \r\n \r\n \r\n\r\n \r\n {{'search.noData' | trans}}\r\n \r\n \r\n \r\n\r\n","import { Injectable } from '@angular/core';\r\nimport { BehaviorSubject, forkJoin, Observable } from 'rxjs';\r\n\r\n@Injectable()\r\nexport class SearchHelperService {\r\n amount: BehaviorSubject = new BehaviorSubject(0);\r\n keyword: BehaviorSubject = new BehaviorSubject('');\r\n\r\n getData(): Observable<{ amount: number; keyword: string }> {\r\n return forkJoin({ amount: this.amount, keyword: this.keyword });\r\n }\r\n}\r\n","import {NgModule} from '@angular/core';\r\nimport {CommonModule} from '@angular/common';\r\nimport {SearchComponent} from './components/search/search.component';\r\nimport {FormsModule} from '@angular/forms';\r\nimport {ElementsModule} from '@share/modules/elements/elements.module';\r\nimport {SearchResultsComponent} from './components/search-results/search-results.component';\r\nimport {TranslatorModule} from '@share/modules/translator/translator.module';\r\nimport {NgbPaginationModule} from '@ng-bootstrap/ng-bootstrap';\r\nimport {ContainerModule} from '@app/template/layout/modules/container/container.module';\r\nimport {SelectModule} from '@share/modules/html/select/select.module';\r\nimport { PaginationModule } from '@app/template/elements/pagination/pagination.module';\r\nimport { PaginationService } from '@app/template/elements/pagination/services/pagination.service';\r\nimport { RouterModule } from '@angular/router';\r\nimport { SearchResultsSubheaderComponent } from '@app/client-core/search/components/search-results-subheader/search-results-subheader.component';\r\nimport { ArticleModule } from '@app/client-core/article/article.module';\r\nimport { SearchHelperService } from '@app/client-core/search/search-helper.service';\r\n\r\n@NgModule({\r\n declarations: [SearchComponent, SearchResultsComponent, SearchResultsSubheaderComponent],\r\n imports: [\r\n CommonModule,\r\n FormsModule,\r\n ElementsModule,\r\n TranslatorModule,\r\n NgbPaginationModule,\r\n ContainerModule,\r\n SelectModule,\r\n PaginationModule,\r\n RouterModule,\r\n ArticleModule,\r\n ],\r\n exports: [\r\n SearchComponent,\r\n SearchResultsComponent\r\n ],\r\n providers: [\r\n PaginationService,\r\n SearchHelperService\r\n ]\r\n})\r\nexport class SearchModule {}\r\n","import {Injectable} from '@angular/core';\r\nimport {ServiceHelper} from '@share/common/helpers/service.helper';\r\nimport {API} from '@app/common/constants/api.directories';\r\nimport { BehaviorSubject, Observable } from 'rxjs';\r\nimport {SearchType, SearchTypeNames} from '@app/template/layout/modules/header/interfaces/subheader-config.interface';\r\nimport {HttpParams} from '@angular/common/http';\r\nimport {AbstractData} from '@share/common/models/http.model';\r\nimport {SelectModel} from '@share/modules/html/common/interfaces/select-model.interface';\r\nimport {Bundle} from '@app/common/enums/server-bundles.enum';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class SearchService extends ServiceHelper {\r\n\r\n amount: number = 0;\r\n isActive$: BehaviorSubject = new BehaviorSubject(false);\r\n\r\n constructor() {\r\n super('');\r\n }\r\n\r\n public getList(keyword: string, searchType: SearchType): Observable {\r\n let params: HttpParams = new HttpParams().set('contains', keyword);\r\n\r\n if (!!searchType) {\r\n params = params.set('inside', searchType);\r\n }\r\n\r\n return this.getAll(API.SEARCH.ROOT, {http: {params}});\r\n }\r\n\r\n public getFullList(keyword: string, searchType: SearchType, page: number, count: number): Observable {\r\n let params: HttpParams = new HttpParams();\r\n\r\n params = params.set('page', page.toString());\r\n params = params.set('count', count.toString());\r\n params = params.set('contains', keyword);\r\n\r\n if (!!searchType) {\r\n params = params.set('inside', searchType);\r\n }\r\n\r\n return this.getAll(API.SEARCH.FULL, {http: {params}});\r\n }\r\n\r\n public getAvailableSearchTypes(): Array> {\r\n return [\r\n {\r\n id: SearchType.Default,\r\n type: Bundle.Alert,\r\n attributes: {\r\n title: SearchTypeNames.Default\r\n }\r\n },\r\n {\r\n id: SearchType.EServices,\r\n type: Bundle.Alert,\r\n attributes: {\r\n title: SearchTypeNames.EServices\r\n }\r\n }\r\n ];\r\n }\r\n}\r\n","import { InjectionToken } from '@angular/core';\r\n\r\nexport const SUBHEADER_INJECTION_TOKEN = new InjectionToken('SUBHEADER_INJECTION_TOKEN');\r\n","export { StaticPageComponent } from './static-page/static-page.component';\r\nexport { StaticPageDefaultComponent } from './static-page-default/static-page-default.component';\r\nexport { StaticPageContactComponent } from './static-page-contact/static-page-contact.component';\r\nexport { ContactFormComponent } from './static-page-contact/contact-form/contact-form.component';\r\nexport { ContactImagesComponent } from './static-page-contact/contact-images/contact-images.component';\r\nexport { ContactSubheaderComponent } from './static-page-contact/contact-subheader/contact-subheader.component';\r\nexport { SchedulePageComponent } from './schedule-page/schedule-page.component';\r\n","import { ChangeDetectionStrategy, Component, Input } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'app-schedule-page',\r\n templateUrl: 'schedule-page.component.html',\r\n styleUrls: ['schedule-page.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class SchedulePageComponent {\r\n @Input() data: {\r\n content: {\r\n boxPhone: string;\r\n boxSchedule: string;\r\n boxTitle: string;\r\n boxSubtitle: string;\r\n subtitle: string;\r\n schedule: {date: string, cities: string}[];\r\n };\r\n };\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n {{ boxTitle }}\r\n \r\n \r\n {{ boxSubtitle }}\r\n \r\n \r\n \r\n {{ boxPhone }}\r\n \r\n \r\n\r\n\r\n\r\n \r\n {{ title }}\r\n {{ content }}\r\n \r\n\r\n","import { Observable } from 'rxjs';\r\nimport { ResponseArray } from '@share/common/models/http';\r\nimport { API } from '@app/common/constants/api.directories';\r\nimport { ApiService } from '@app/common/services/api.service';\r\nimport { Injectable } from '@angular/core';\r\n\r\n@Injectable({ providedIn: 'root' })\r\nexport class ConsentsService {\r\n constructor(private apiService: ApiService) {}\r\n\r\n getList(name: string = ''): Observable> {\r\n return this.apiService.getAll(`${API.AUTH.CONSENTS}/${name}`);\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'app-contact-dots',\r\n templateUrl: 'contact-dots.component.html',\r\n styleUrls: ['contact-dots.component.scss']\r\n})\r\nexport class ContactDotsComponent {}\r\n","\r\n \r\n\r\n","import { AfterViewInit, ChangeDetectionStrategy, ChangeDetectorRef, Component, Input, OnDestroy, OnInit } from '@angular/core';\r\nimport { FormBuilder, FormGroup } from '@angular/forms';\r\nimport { CaptchaV3Service } from '@app/common/services/captcha-v3.service';\r\nimport { ConsentsService } from '@app/client-core/static-pages/components/static-page-contact/consents.service';\r\nimport { finalize, first } from 'rxjs/operators';\r\nimport { getContactFormGroup } from '@app/client-core/static-pages/components/static-page-contact/contact-form/form/contact-form.group';\r\nimport { getContactFormConfig } from '@app/client-core/static-pages/components/static-page-contact/contact-form/form/contact-form.config';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { ContactService } from '@app/client-core/static-pages/components/static-page-contact/contact.service';\r\n\r\n@Component({\r\n selector: 'app-contact-form',\r\n templateUrl: 'contact-form.component.html',\r\n styleUrls: ['contact-form.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class ContactFormComponent implements OnInit, OnDestroy, AfterViewInit {\r\n formGroup: FormGroup;\r\n formConfig: { [id: string]: any };\r\n consentLoader: boolean;\r\n sendLoader: boolean;\r\n\r\n @Input() title: string;\r\n @Input() subtitle: string;\r\n\r\n constructor(\r\n private formBuilder: FormBuilder,\r\n private captchaService: CaptchaV3Service,\r\n private consentService: ConsentsService,\r\n private cdr: ChangeDetectorRef,\r\n private facadeService: FacadeService,\r\n private contactService: ContactService\r\n ) {\r\n this.initFormGroup();\r\n }\r\n\r\n private initFormGroup() {\r\n this.formGroup = this.formBuilder.group(getContactFormGroup());\r\n this.formConfig = getContactFormConfig(this.facadeService.translator);\r\n }\r\n\r\n ngOnInit() {\r\n this.captchaService.load();\r\n this.getConsents();\r\n }\r\n\r\n getConsents() {\r\n this.consentLoader = true;\r\n this.cdr.detectChanges();\r\n this.consentService\r\n .getList('contact')\r\n .pipe(\r\n first(),\r\n finalize(() => {\r\n this.consentLoader = false;\r\n this.cdr.detectChanges();\r\n })\r\n )\r\n .subscribe(response => {\r\n const [first] = response.data;\r\n this.setConsentConfig(first.id, first.attributes.fulltext);\r\n });\r\n }\r\n\r\n setConsentConfig(id: string, label: string) {\r\n this.formConfig.consent = {\r\n id: id,\r\n label: label,\r\n allowHtmlLabel: true\r\n };\r\n }\r\n\r\n ngAfterViewInit() {\r\n this.captchaService.toggleVisibility();\r\n }\r\n\r\n onSubmit() {\r\n this.sendLoader = true;\r\n this.cdr.detectChanges();\r\n this.captchaService.execute()\r\n .pipe(\r\n first()\r\n )\r\n .subscribe(\r\n token => {\r\n this.formGroup.patchValue({ captcha: token });\r\n this.sendForm();\r\n },\r\n () => {\r\n this.facadeService.toastr.error(this.facadeService.trans('contact.form.captchaError'));\r\n this.sendLoader = false;\r\n this.cdr.detectChanges();\r\n }\r\n );\r\n }\r\n\r\n sendForm() {\r\n this.contactService\r\n .submit(this.formGroup.getRawValue())\r\n .pipe(\r\n first(),\r\n finalize(() => {\r\n this.sendLoader = false;\r\n this.cdr.detectChanges();\r\n })\r\n )\r\n .subscribe(\r\n () => {\r\n this.facadeService.toastr.success(this.facadeService.translator.trans('contact.form.successMessage'));\r\n this.formGroup.reset();\r\n },\r\n );\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.captchaService.toggleVisibility(false);\r\n }\r\n}\r\n","\r\n {{ title }}\r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n\r\n\r\n","import { InputTypeEnum } from '@share/modules/html/input/enums/input-types.enum';\r\nimport { TranslatorService } from '@share/common/services/translator.service';\r\n\r\nexport function getContactFormConfig(translatorService: TranslatorService): { [id: string]: any } {\r\n return {\r\n senderName: {\r\n id: 'senderName',\r\n type: InputTypeEnum.Text,\r\n label: translatorService.trans('contact.form.name')\r\n },\r\n senderEmail: {\r\n id: 'senderEmail',\r\n type: InputTypeEnum.Text,\r\n label: translatorService.trans('contact.form.email')\r\n },\r\n content: {\r\n id: 'content',\r\n type: InputTypeEnum.Text,\r\n label: translatorService.trans('contact.form.message')\r\n }\r\n };\r\n}\r\n","import { Validators } from '@angular/forms';\r\n\r\nexport function getContactFormGroup(): { [id: string]: any } {\r\n return {\r\n senderName: ['', Validators.required],\r\n senderEmail: ['', Validators.required],\r\n content: ['', Validators.required],\r\n dataProcessConsent: [false, Validators.requiredTrue],\r\n captcha: ['', Validators.required]\r\n };\r\n}\r\n","import { Component, Input } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'app-contact-images',\r\n templateUrl: 'contact-images.component.html',\r\n styleUrls: ['contact-images.component.scss']\r\n})\r\nexport class ContactImagesComponent {\r\n @Input() biggerImageUrl: string;\r\n @Input() smallerImageUrl: string;\r\n\r\n @Input() isRight: boolean;\r\n @Input() special: boolean;\r\n @Input() smallUp: boolean;\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n\r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { InstitutionService } from '@app/common/services/institution.service';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { first } from 'rxjs/operators';\r\nimport { Institution } from '@app/common/models/institution.model';\r\n\r\n@Component({\r\n selector: 'app-contact-subheader',\r\n templateUrl: 'contact-subheader.component.html',\r\n styleUrls: ['contact-subheader.component.scss']\r\n})\r\nexport class ContactSubheaderComponent implements OnInit {\r\n\r\n institution: AbstractData;\r\n\r\n constructor(private institutionService: InstitutionService) {}\r\n\r\n ngOnInit() {\r\n this.getInstitutionData();\r\n }\r\n\r\n getInstitutionData() {\r\n this.institutionService\r\n .getCurrent()\r\n .pipe(\r\n first()\r\n )\r\n .subscribe(response => this.institution = response.data)\r\n }\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n Dane kontaktowe\r\n \r\n {{institution.attributes.name}}\r\n {{institution.attributes.address.zipCode}} {{institution.attributes.address.city}} \r\n {{institution.attributes.address.street}} {{institution.attributes.address.houseNumber}}\r\n tel.: {{institution.attributes.contact.phoneNumber}}\r\n {{institution.attributes.contact.email}}\r\n \r\n \r\n\r\n","import { Injectable } from '@angular/core';\r\nimport { Observable } from 'rxjs';\r\nimport { ApiService } from '@app/common/services/api.service';\r\nimport { API } from '@app/common/constants/api.directories';\r\n\r\n@Injectable({providedIn: 'root'})\r\nexport class ContactService {\r\n\r\n constructor(private apiService: ApiService) {\r\n }\r\n\r\n public submit(contact: any): Observable {\r\n return this.apiService.post('contact', contact);\r\n }\r\n}\r\n","import { ChangeDetectionStrategy, Component, Input } from '@angular/core';\r\nimport { ImageCropper } from '@app/template/home/models/image-cropper.model';\r\n\r\n@Component({\r\n selector: 'app-static-page-contact-department',\r\n templateUrl: 'static-page-contact-department.component.html',\r\n styleUrls: ['static-page-contact-department.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class StaticPageContactDepartmentComponent {\r\n\r\n @Input() rightImage: boolean;\r\n @Input() special: boolean;\r\n @Input() specialTwo: boolean;\r\n @Input() smallUp: boolean;\r\n\r\n @Input() data: {\r\n title: string;\r\n bigImage: ImageCropper;\r\n smallImage: ImageCropper;\r\n people: {\r\n personOrPlace: string;\r\n contact: {\r\n type: 'phone' | 'email';\r\n value: string;\r\n extra: string | null;\r\n }[];\r\n }[];\r\n };\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n {{ data.title }}\r\n \r\n \r\n \r\n \r\n \r\n\r\n\r\n\r\n \r\n {{person.description}}\r\n {{person.fullName}} - {{person?.scope}}\r\n \r\n \r\n Numer telefonu\r\n \r\n {{ contact.value }}\r\n wew. {{ contact.extra }}\r\n \r\n\r\n \r\n Email\r\n \r\n {{ contact.value }}\r\n \r\n \r\n \r\n\r\n","import { Component, Input } from '@angular/core';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { ContactSubheaderComponent } from '@app/client-core/static-pages/components/static-page-contact/contact-subheader/contact-subheader.component';\r\n\r\n@Component({\r\n selector: 'app-static-page-contact',\r\n templateUrl: './static-page-contact.component.html',\r\n styleUrls: ['./static-page-contact.component.scss']\r\n})\r\nexport class StaticPageContactComponent {\r\n @Input() data: {\r\n sectionOne: any,\r\n sectionTwo: any,\r\n sectionThree: any,\r\n sectionFour: any\r\n };\r\n\r\n constructor(private facadeService: FacadeService) {\r\n this.facadeService.subheader.setConfig({\r\n component: ContactSubheaderComponent,\r\n hideDots: true\r\n });\r\n this.facadeService.subheader.displayBreadcrumbs = false;\r\n }\r\n}\r\n","\r\n\r\n\r\n \r\n \r\n {{ data.sectionThree.title }}\r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n = 3\">\r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { Component, Input } from '@angular/core';\r\nimport { StaticPageDefaultModel } from '@app/client-core/static-pages/model/static-page-default.model';\r\n\r\n@Component({\r\n selector: 'app-static-page-default',\r\n templateUrl: './static-page-default.component.html',\r\n styleUrls: ['./static-page-default.component.scss']\r\n})\r\nexport class StaticPageDefaultComponent {\r\n @Input() data: StaticPageDefaultModel;\r\n\r\n getFileUrl() {\r\n // TODO: Poprawić typy\r\n if (this.data.file?.hasOwnProperty('url')) {\r\n return this.data.file['croppedImage'] || this.data?.file['url'];\r\n }\r\n return this.getFileAsString();\r\n }\r\n\r\n private getFileAsString(): string | null {\r\n if (typeof this.data?.file === 'string') {\r\n return this.data?.file;\r\n }\r\n return null;\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { Component, Input, OnDestroy, OnInit } from '@angular/core';\r\nimport { SubheaderService } from '@app/template/layout/modules/header/services/subheader.service';\r\nimport { ElementService } from '@app/client-core/dynamic-content/service/element.service';\r\nimport { ActivatedRoute, Router } from '@angular/router';\r\nimport { UrlService } from '@app/common/services/url.service';\r\nimport { finalize, first, takeUntil } from 'rxjs/operators';\r\nimport { AbstractData, ResponseObject } from '@share/common/models/http';\r\nimport { PagesService } from '@app/common/services/pages.service';\r\nimport { PageModel } from '@app/common/models/page.model';\r\nimport { ReplaySubject } from 'rxjs';\r\nimport { HistoryService } from '@share/common/services/history.service';\r\nimport { StaticPage } from '@app/client-core/static-pages/model/static-pages.model';\r\nimport { Nullable } from '@share/common/types/utilities.types';\r\n\r\n@Component({\r\n selector: 'app-static-page',\r\n templateUrl: './static-page.component.html',\r\n styleUrls: ['./static-page.component.scss']\r\n})\r\nexport class StaticPageComponent implements OnInit, OnDestroy {\r\n @Input() page: Nullable>>>;\r\n\r\n private destroyed$: ReplaySubject = new ReplaySubject(1);\r\n getError: boolean;\r\n getLoading: boolean;\r\n\r\n constructor(\r\n protected pagesService: PagesService,\r\n protected subheaderService: SubheaderService,\r\n private elementService: ElementService,\r\n protected route: ActivatedRoute,\r\n private urlService: UrlService,\r\n private historyService: HistoryService,\r\n private router: Router\r\n ) {}\r\n\r\n private setListener() {\r\n this.elementService.sameComponentNavigation.pipe(takeUntil(this.destroyed$)).subscribe(same => {\r\n if (same) {\r\n this.loadPage();\r\n }\r\n });\r\n }\r\n\r\n ngOnInit() {\r\n this.setListener();\r\n if (!this.page) {\r\n this.loadPage();\r\n } else {\r\n this.setSubheader(this.page);\r\n }\r\n }\r\n\r\n protected onLoadPageSuccess(response: ResponseObject>>) {\r\n this.page = response.data;\r\n this.setSubheader(this.page);\r\n }\r\n\r\n private setSubheader(page: AbstractData>>) {\r\n this.subheaderService.setConfig({ title: page.attributes.title, publishedDate: page.attributes.publishedFrom });\r\n if (page.attributes.content?.pageType === 'schedule') {\r\n this.subheaderService.description = page?.attributes?.content?.content?.subtitle;\r\n this.subheaderService.publishedDate = '';\r\n }\r\n this.subheaderService.config.displayBreadcrumbs.next(true);\r\n }\r\n\r\n loadPage() {\r\n this.getLoading = true;\r\n this.pagesService\r\n .getOne(this.router.url.split('/').join(','))\r\n .pipe(\r\n first(),\r\n finalize(() => (this.getLoading = false))\r\n )\r\n .subscribe(\r\n response => this.onLoadPageSuccess(response),\r\n error => {\r\n this.subheaderService.setConfig({\r\n title: error.error.errors[0].status\r\n });\r\n this.subheaderService.description = error.error.errors[0].title;\r\n this.page = null;\r\n }\r\n );\r\n }\r\n\r\n ngOnDestroy() {\r\n this.destroyed$.next(true);\r\n this.destroyed$.complete();\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { RouterModule } from '@angular/router';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { ContainerModule } from '@app/template/layout/modules/container/container.module';\r\nimport { GoogleMapModule } from '@share/modules/google-map/google-map.module';\r\nimport {\r\n ContactFormComponent,\r\n StaticPageComponent,\r\n StaticPageContactComponent,\r\n StaticPageDefaultComponent,\r\n ContactImagesComponent,\r\n ContactSubheaderComponent,\r\n SchedulePageComponent\r\n} from '@app/client-core/static-pages/components';\r\nimport { ArticleModule } from '@app/client-core/article/article.module';\r\nimport { SimpleBoxModule } from '@app/template/elements/simple-box/simple-box.module';\r\nimport { ReactiveFormsModule } from '@angular/forms';\r\nimport { CheckboxModule } from '@share/modules/html/checkbox/checkbox.module';\r\nimport { InputModule } from '@app/template/elements/input/input.module';\r\nimport { TextareaModule } from '@app/template/elements/textarea/textarea.module';\r\nimport { HeaderModule } from '@app/template/layout/modules/header/header.module';\r\nimport { StaticPageContactDepartmentComponent } from '@app/client-core/static-pages/components/static-page-contact/static-page-contact-department/static-page-contact-department.component';\r\nimport { ContactDotsComponent } from '@app/client-core/static-pages/components/static-page-contact/contact-dots/contact-dots.component';\r\nimport { BreadcrumbsModule } from '@app/template/layout/modules/breadcrumbs/breadcrumbs.module';\r\n\r\n@NgModule({\r\n declarations: [\r\n SchedulePageComponent,\r\n StaticPageContactDepartmentComponent,\r\n ContactImagesComponent,\r\n ContactSubheaderComponent,\r\n ContactFormComponent,\r\n StaticPageComponent,\r\n StaticPageDefaultComponent,\r\n StaticPageContactComponent,\r\n ContactDotsComponent\r\n ],\r\n imports: [\r\n CommonModule,\r\n RouterModule,\r\n ElementsModule,\r\n TranslatorModule,\r\n ContainerModule,\r\n GoogleMapModule,\r\n ArticleModule,\r\n SimpleBoxModule,\r\n ReactiveFormsModule,\r\n CheckboxModule,\r\n InputModule,\r\n TextareaModule,\r\n HeaderModule,\r\n BreadcrumbsModule\r\n ],\r\n exports: [StaticPageComponent]\r\n})\r\nexport class StaticPagesModule {}\r\n","import { AppConfigCMS } from '@share/common/interfaces/app-config.interface';\r\n\r\ndeclare const APP_CONFIG: AppConfigCMS;\r\nexport const URL = APP_CONFIG.API_URL;\r\nconst PREFIX = APP_CONFIG.PREFIX;\r\nconst SERVER = `${URL}/${PREFIX}`;\r\n\r\nexport const API = {\r\n AUTH: {\r\n LOGIN: `${SERVER}/login`,\r\n LOGOUT: `${SERVER}/logout`,\r\n CONSENTS: `${SERVER}/consents`,\r\n FORGOT_PASSWORD: `${SERVER}/account/resetPassword/sendEmail`,\r\n VALIDATE_TOKEN: `${SERVER}/account/resetPassword/checkToken`,\r\n CHANGE_PASSWORD: `${SERVER}/account/resetPassword/change`,\r\n ACTIVATE_ACCOUNT: `${SERVER}/account/confirm`\r\n },\r\n COMMON: {\r\n BREADCRUMBS: `${SERVER}/breadcrumbs`\r\n },\r\n ARTICLES: {\r\n ROOT: `${SERVER}/articles`,\r\n RANDOM: `${SERVER}/articles/random`\r\n },\r\n SETTINGS: {\r\n ROOT: `${SERVER}/settings/bootstrap`,\r\n GET_LAYOUT: `${SERVER}/settings/layout`\r\n },\r\n SEARCH: {\r\n ROOT: `${SERVER}/search/autocomplete`,\r\n FULL: `${SERVER}/search/getResult`\r\n },\r\n PROMOTED: {\r\n ROOT: `${SERVER}/promoted`\r\n },\r\n BANNERS: {\r\n ROOT: `${SERVER}/banners`\r\n },\r\n MENU: {\r\n ROOT: `${SERVER}/menu`,\r\n SITEMAP: `${SERVER}/menu/sitemap`\r\n },\r\n DYNAMIC_CONTENT: {\r\n ROOT: `${SERVER}/search/getMetadata`\r\n },\r\n CATEGORY: {\r\n ROOT: `${SERVER}/categories`\r\n },\r\n PROFILE: {\r\n ROOT: `${SERVER}/account`\r\n },\r\n ALERTS: {\r\n ROOT: `${SERVER}/alerts`\r\n },\r\n BUSINESS_MODULES: {\r\n ROOT: `${SERVER}/businessModules`,\r\n },\r\n PAGES: {\r\n ROOT: `${SERVER}/pages`\r\n },\r\n PREVIEW: {\r\n ROOT: `${SERVER}/preview`\r\n },\r\n INSTITUTION: {\r\n ROOT: 'institution'\r\n },\r\n ASSETS: {\r\n DEFAULT_SETTINGS: 'source/default_settings.json'\r\n }\r\n};\r\n","import { APP_INITIALIZER, LOCALE_ID, Provider } from '@angular/core';\r\nimport { HTTP_INTERCEPTORS } from '@angular/common/http';\r\nimport { BootstrapService } from '@app/common/services/bootstrap.service';\r\nimport {\r\n getBackendVersionFactory,\r\n getFrontendVersionFactory,\r\n getLanguageFactory,\r\n getMaintenanceFactory,\r\n getPermissions,\r\n getSettingsFactory,\r\n getTranslationsFactory\r\n} from '@app/common/functions/bootstrap';\r\nimport { LanguageService } from '@share/common/services/language.service';\r\nimport { InstitutionInterceptorService } from '@app/common/interceptors/institution-interceptor.service';\r\nimport { ContentInterceptorService } from '@app/common/interceptors/content-interceptor.service';\r\nimport { ApiInterceptorService } from '@app/common/interceptors/api-interceptor.service';\r\n\r\nexport const BOOTSTRAP_PROVIDERS: Provider[] = [\r\n {\r\n provide: HTTP_INTERCEPTORS,\r\n useClass: ApiInterceptorService,\r\n multi: true\r\n },\r\n {\r\n provide: HTTP_INTERCEPTORS,\r\n useClass: ContentInterceptorService,\r\n multi: true\r\n },\r\n {\r\n provide: HTTP_INTERCEPTORS,\r\n useClass: InstitutionInterceptorService,\r\n multi: true\r\n },\r\n {\r\n provide: LOCALE_ID,\r\n deps: [LanguageService],\r\n useFactory: getLanguageFactory\r\n },\r\n {\r\n provide: APP_INITIALIZER,\r\n useFactory: getTranslationsFactory,\r\n deps: [BootstrapService],\r\n multi: true\r\n },\r\n {\r\n provide: APP_INITIALIZER,\r\n useFactory: getMaintenanceFactory,\r\n deps: [BootstrapService],\r\n multi: true\r\n },\r\n {\r\n provide: APP_INITIALIZER,\r\n useFactory: getSettingsFactory,\r\n deps: [BootstrapService],\r\n multi: true\r\n },\r\n {\r\n provide: APP_INITIALIZER,\r\n useFactory: getBackendVersionFactory,\r\n deps: [BootstrapService],\r\n multi: true\r\n },\r\n {\r\n provide: APP_INITIALIZER,\r\n useFactory: getFrontendVersionFactory,\r\n deps: [BootstrapService],\r\n multi: true\r\n }\r\n];\r\n","import {HAMMER_GESTURE_CONFIG, HammerGestureConfig} from '@angular/platform-browser';\r\nimport {Injectable, Provider} from '@angular/core';\r\nimport * as Hammer from 'hammerjs';\r\n\r\n@Injectable()\r\nexport class MyHammerConfig extends HammerGestureConfig {\r\n buildHammer(element: HTMLElement) {\r\n return new Hammer(element, {\r\n touchAction: 'pan-y pan-x'\r\n });\r\n }\r\n}\r\n\r\nexport const HAMMER_PROVIDER: Provider[] = [\r\n {\r\n provide: HAMMER_GESTURE_CONFIG,\r\n useClass: MyHammerConfig\r\n }\r\n];\r\n","import { NgModuleFactory, Type } from '@angular/core';\r\nimport { ThemesEnum } from '@app/common/models/themes.enum';\r\n\r\nexport const lazyWidgets: { name: string; loadChildren: () => Promise | Type> }[] = [\r\n {\r\n name: ThemesEnum.CORE,\r\n loadChildren: () => import('@app/client-core/static-pages/static-pages.module').then(m => m.StaticPagesModule)\r\n },\r\n {\r\n name: ThemesEnum.ARTICLE,\r\n loadChildren: () => import('@app/client-core/article/article.module').then(m => m.ArticleModule)\r\n },\r\n {\r\n name: ThemesEnum.MENU,\r\n loadChildren: () => import('@app/client-core/menu/menu.module').then(m => m.MenuModule)\r\n }\r\n];\r\n\r\nexport function lazyArrayToObj() {\r\n const result = {};\r\n for (const w of lazyWidgets) {\r\n result[w.name] = w.loadChildren;\r\n }\r\n return result;\r\n}\r\n","import {PortalVariablesEnum} from '@app/common/enums/portal-variables.enum';\r\n\r\nexport const PORTAL_VARIABLES_PRESETS = {\r\n [PortalVariablesEnum.MainColor]: '',\r\n [PortalVariablesEnum.SectionBackgroundColor]: '',\r\n [PortalVariablesEnum.ButtonColor]: '',\r\n [PortalVariablesEnum.AccentColor]: '',\r\n};\r\n","export const ARTICLE_PREVIEW = 'articles';\r\nexport const STATIC_PAGE_PREVIEW = 'static-pages';\r\nexport const ESERVICE_PREVIEW = 'eservices';\r\nexport const ROUTES_PATHS = {\r\n profile: {\r\n root: 'konto',\r\n login: 'logowanie',\r\n register: 'rejestracja',\r\n remindPassword: 'przypomnij-haslo'\r\n },\r\n businessModules: {\r\n root: 'moduly-biznesowe'\r\n },\r\n eServices: {\r\n root: 'katalog-e-uslug'\r\n },\r\n notFoundPage: {\r\n root: '404'\r\n },\r\n unknownErrorPage: {\r\n root: '500'\r\n },\r\n maintenance: {\r\n root: 'przerwa-techniczna'\r\n },\r\n preview: {\r\n articles: 'articles',\r\n staticPages: 'static-pages'\r\n }\r\n};\r\n","import { InjectionToken } from '@angular/core';\r\n\r\nexport const LAZY_WIDGETS = new InjectionToken<{ [key: string]: string }>('LAZY_WIDGETS');\r\n","export enum MobileEnum {\r\n Large = 992,\r\n Medium = 768,\r\n Small = 576\r\n}\r\n\r\n","export enum PortalVariablesEnum {\r\n MainColor = 'mainColor',\r\n AccentColor = 'accentColor',\r\n ButtonColor = 'buttonColor',\r\n SectionBackgroundColor = 'sectionBackgroundColor'\r\n}\r\n","export enum Bundle {\r\n EServices = 'EServices',\r\n User = 'CmsUser',\r\n Article = 'CmsArticle',\r\n Banner = 'CmsBanner',\r\n BusinessModules = 'CmsBusinessModule',\r\n Settings = 'Setting',\r\n Alert = 'CmsAlert',\r\n Promoted = 'CmsPromoted',\r\n Partners = 'CmsPartners',\r\n Sitemap = 'CmsSitemap',\r\n Breadcrumbs = 'Breadcrumbs',\r\n StaticPages = 'StaticPages',\r\n Preview = 'preview'\r\n}\r\n","import {BootstrapService} from '@app/common/services/bootstrap.service';\r\nimport { LanguageService } from '@share/common/services/language.service';\r\n\r\nexport function getLanguageFactory(language: LanguageService): () => string {\r\n return () => language.getLanguage();\r\n}\r\n\r\nexport function getTranslationsFactory(service: BootstrapService): () => Promise {\r\n return () => service.getTranslations();\r\n}\r\n\r\nexport function getMaintenanceFactory(service: BootstrapService): () => Promise {\r\n return () => service.checkMaintenance();\r\n}\r\n\r\nexport function getSettingsFactory(service: BootstrapService): () => Promise {\r\n return () => service.loadSettings();\r\n}\r\n\r\nexport function getBackendVersionFactory(service: BootstrapService): () => Promise {\r\n return () => service.getBackendVersion();\r\n}\r\n\r\nexport function getFrontendVersionFactory(service: BootstrapService): () => Promise {\r\n return () => service.getFrontendVersion();\r\n}\r\n\r\nexport function getPermissions(service: BootstrapService): () => Promise {\r\n return () => service.getPermissions();\r\n}\r\n","import { OnDestroy, Type } from '@angular/core';\r\nimport { ComponentShareHelper } from '@share/common/helpers/component-share.helper';\r\nimport { FacadeShareService } from '@share/common/services/facade-share.service';\r\nimport { ServiceLocator } from '@share/common/services/locater.service';\r\nimport { FacadeService } from '../services/facade.service';\r\n\r\nexport abstract class ComponentHelper extends ComponentShareHelper implements OnDestroy {\r\n\r\n protected service: FacadeService;\r\n\r\n protected constructor() {\r\n super(ServiceLocator.injector.get(FacadeShareService as Type));\r\n this.service = ServiceLocator.injector.get(FacadeService as Type);\r\n }\r\n}\r\n","import { HttpErrorResponse, HttpEvent, HttpHandler, HttpInterceptor, HttpRequest } from '@angular/common/http';\r\nimport { Injectable } from '@angular/core';\r\nimport { Observable, throwError } from 'rxjs';\r\nimport { ToastrServiceCustom } from '@share/common/services/toastr.service';\r\nimport { Router } from '@angular/router';\r\nimport { ROUTES_PATHS } from '@app/common/constants/routes-paths';\r\nimport { TranslatorService } from '@share/common/services/translator.service';\r\nimport { catchError } from 'rxjs/operators';\r\nimport { ErrorResponse } from '@share/common/models/http.model';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ApiInterceptorService implements HttpInterceptor {\r\n constructor(private toastr: ToastrServiceCustom, private translator: TranslatorService, private router: Router) {}\r\n\r\n private get internalErrorMessage(): string {\r\n return this.translator.trans('global.errors.internalError');\r\n }\r\n\r\n intercept(req: HttpRequest, next: HttpHandler): Observable> {\r\n const headersConfig = {};\r\n const request = req.clone({ setHeaders: headersConfig });\r\n return next.handle(request).pipe(catchError(httpErrorResponse => this.handleError(httpErrorResponse)));\r\n }\r\n\r\n private handleError(httpErrorResponse: any) {\r\n let error: { error: { errors: Array } } = { error: { errors: [] } };\r\n if (httpErrorResponse instanceof HttpErrorResponse) {\r\n this.handleErrorStatus(httpErrorResponse);\r\n const message = this.getMessage(httpErrorResponse);\r\n this.toastr.error(message.title);\r\n error = { error: { errors: [message] } };\r\n }\r\n return throwError(httpErrorResponse);\r\n }\r\n\r\n private getMessage(response: HttpErrorResponse): { title: string; id: string } {\r\n let title: string = '';\r\n try {\r\n const [error] = response.error.errors;\r\n title = error.title;\r\n } catch (e) {\r\n title = this.internalErrorMessage;\r\n }\r\n return { title, id: '' };\r\n }\r\n\r\n private handleErrorStatus(httpErrorResponse: HttpErrorResponse) {\r\n switch (httpErrorResponse.status) {\r\n case 403:\r\n this.handleForbidden();\r\n break;\r\n case 412:\r\n case 0:\r\n this.goToNotFoundPage();\r\n this.router.navigate([ROUTES_PATHS.unknownErrorPage.root]);\r\n break;\r\n }\r\n }\r\n\r\n private handleForbidden() {\r\n if (!this.router.isActive('', false)) {\r\n this.router.navigate(['']);\r\n }\r\n }\r\n\r\n private goToNotFoundPage() {\r\n this.router.navigate([ROUTES_PATHS.unknownErrorPage.root]);\r\n }\r\n}\r\n","import { HttpEvent, HttpHandler, HttpInterceptor, HttpRequest } from '@angular/common/http';\r\nimport { Observable } from 'rxjs';\r\nimport { Injectable } from '@angular/core';\r\n\r\n@Injectable()\r\nexport class ContentInterceptorService implements HttpInterceptor {\r\n intercept(req: HttpRequest, next: HttpHandler): Observable> {\r\n const headersConfig = {\r\n 'Content-Type': 'application/vnd.api+json',\r\n 'Accept': 'application/vnd.api+json',\r\n };\r\n const request = req.clone({setHeaders: headersConfig});\r\n return next.handle(request);\r\n }\r\n}\r\n","import { HttpEvent, HttpHandler, HttpInterceptor, HttpRequest } from '@angular/common/http';\r\nimport { Observable } from 'rxjs';\r\nimport { Injectable } from '@angular/core';\r\n\r\n@Injectable()\r\nexport class InstitutionInterceptorService implements HttpInterceptor {\r\n intercept(req: HttpRequest, next: HttpHandler): Observable> {\r\n const headersConfig = {\r\n 'x-site-url': window.location.origin\r\n };\r\n\r\n const request = req.clone({ setHeaders: headersConfig });\r\n return next.handle(request);\r\n }\r\n}\r\n","export enum ThemesEnum {\r\n ALERT = 'mportal_alert',\r\n ARTICLE = 'mportal_article',\r\n CONSENT = 'mportal_consent',\r\n ESERVICE_CATALOG = 'eservicesCatalog',\r\n MENU = 'mportal_menu',\r\n PROMOTED = 'mportal_promoted',\r\n NETIZEN = 'mportal_netizen',\r\n CORE = 'mportal_core',\r\n EOFFICE = 'eoffice'\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { FormErrors } from '@gkw/shared/common/models/form-errors.model';\r\nimport { HttpErrorResponse } from '@angular/common/http';\r\nimport { ResponseError } from '@share/common/models/http.model';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ApiErrorParserService {\r\n static parse(httpErrorResponse: HttpErrorResponse): FormErrors {\r\n const rawErrors: ResponseError = ApiErrorParserService.getRawErrors(httpErrorResponse);\r\n\r\n const parsedErrors: FormErrors = rawErrors.reduce((previous, current) => {\r\n return {\r\n ...previous,\r\n [current.id ?? current.status]: {\r\n text: current.title\r\n }\r\n };\r\n }, {});\r\n\r\n return parsedErrors;\r\n }\r\n\r\n static getRawErrors(httpErrorResponse: HttpErrorResponse): Array<{ id: string; title: string }> {\r\n try {\r\n return httpErrorResponse.error.errors;\r\n } catch (e) {\r\n throw new Error('Invalid error template');\r\n }\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { RequestOptionsModel } from '@share/common/interfaces/request-options.interface';\r\nimport { AppConfigCMS } from '@share/common/interfaces/app-config.interface';\r\n\r\ndeclare var APP_CONFIG: AppConfigCMS;\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ApiPreprocessorService {\r\n\r\n private readonly URL = `${APP_CONFIG.API_URL}/${APP_CONFIG.PREFIX}`;\r\n\r\n prepareUrl(endpoint: string): string {\r\n if (!endpoint.includes(this.URL)) {\r\n return `${this.URL}/${endpoint}`;\r\n }\r\n\r\n return endpoint;\r\n }\r\n\r\n build(bundle: string, data: object | Array, options: RequestOptionsModel = {}): any {\r\n const request: any = this.createBaseRequest(bundle, data, options);\r\n\r\n if (!!options) {\r\n if (options.jsonapi) {\r\n request.jsonapi = options.jsonapi;\r\n }\r\n if (options.meta) {\r\n request.meta = options.meta;\r\n }\r\n }\r\n\r\n return request;\r\n }\r\n\r\n private createBaseRequest(type: string, data: object | Array, options: RequestOptionsModel): any {\r\n return {\r\n data: Array.isArray(data) ? data : {type: type, attributes: data, id: options.id || '0'},\r\n jsonapi: { // TODO: remove\r\n version: '1.0'\r\n },\r\n meta: {}\r\n };\r\n }\r\n\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { HttpClient, HttpParams } from '@angular/common/http';\r\nimport { Observable, throwError } from 'rxjs';\r\nimport { catchError, first } from 'rxjs/operators';\r\nimport { ResponseArray, ResponseObject } from '@share/common/models/http';\r\nimport { RequestOptionsModel } from '@share/common/interfaces/request-options.interface';\r\nimport { ApiErrorParserService } from '@app/common/services/api-error-parser.service';\r\nimport { ApiPreprocessorService } from '@app/common/services/api-preprocessor.service';\r\nimport { ResponseDefault } from '@share/common/models/http.model';\r\nimport { AppConfigPortal } from '@share/common/interfaces/app-config.interface';\r\n\r\ndeclare var APP_CONFIG: AppConfigPortal;\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ApiService {\r\n private _bundle: string = '';\r\n\r\n constructor(private http: HttpClient, private preprocessor: ApiPreprocessorService) {}\r\n\r\n public setBundle(bundle: string) {\r\n this._bundle = bundle;\r\n }\r\n\r\n get(\r\n endpoint: string,\r\n params: HttpParams = new HttpParams(),\r\n options: RequestOptionsModel = {}\r\n ): Observable> {\r\n return this.http\r\n .get>(this.preprocessor.prepareUrl(endpoint), { params })\r\n .pipe(first());\r\n }\r\n\r\n getAll(\r\n endpoint: string,\r\n params: HttpParams = new HttpParams(),\r\n options: RequestOptionsModel = {}\r\n ): Observable> {\r\n return this.http\r\n .get>(this.preprocessor.prepareUrl(endpoint), { params })\r\n .pipe(first());\r\n }\r\n\r\n post(\r\n endpoint: string,\r\n body: Object = {},\r\n params: HttpParams = new HttpParams(),\r\n options: RequestOptionsModel = {}\r\n ): Observable {\r\n const requestData = this.preprocessor.build(options.bundle || this._bundle, body, options);\r\n return this.http\r\n .post(this.preprocessor.prepareUrl(endpoint), JSON.stringify(requestData), { params })\r\n .pipe(\r\n first(),\r\n catchError(e => throwError(ApiErrorParserService.parse(e)))\r\n );\r\n }\r\n\r\n put(\r\n endpoint: string,\r\n body: Object = {},\r\n options: RequestOptionsModel = {},\r\n params: HttpParams = new HttpParams()\r\n ): Observable {\r\n const requestData = this.preprocessor.build(options.bundle || this._bundle, body, options);\r\n\r\n return this.http\r\n .put(this.preprocessor.prepareUrl(endpoint), JSON.stringify(requestData), { params })\r\n .pipe(\r\n first(),\r\n catchError(e => throwError(ApiErrorParserService.parse(e)))\r\n );\r\n }\r\n\r\n patch(\r\n endpoint: string,\r\n body: Object = {},\r\n options: RequestOptionsModel = {},\r\n params: HttpParams = new HttpParams()\r\n ): Observable {\r\n const requestData = this.preprocessor.build(options.bundle || this._bundle, body, options);\r\n\r\n return this.http\r\n .patch(this.preprocessor.prepareUrl(endpoint), JSON.stringify(requestData), { params })\r\n .pipe(\r\n first(),\r\n catchError(e => throwError(ApiErrorParserService.parse(e)))\r\n );\r\n }\r\n\r\n assets(path: string): Observable {\r\n return this.http.get(`${APP_CONFIG.ASSETS_URL}/${path}`).pipe(first());\r\n }\r\n\r\n delete(endpoint: string): Observable {\r\n return this.http.delete(this.preprocessor.prepareUrl(endpoint)).pipe(first());\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { ROUTES_PATHS } from '@app/common/constants/routes-paths';\r\nimport { ResponseDefault } from '@share/common/models/http.model';\r\nimport { AppService } from '@share/common/services/app.service';\r\nimport { VersionService } from '@share/common/services/version.service';\r\nimport { VariablesCollection } from '@share/common/models/variables.model';\r\nimport { PortalLayoutService } from '@app/common/services/portal-layout.service';\r\nimport { Variable } from '@share/common/interfaces/variables.interface';\r\nimport { first } from 'rxjs/operators';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { AbstractData, ResponseObject } from '@share/common/models/http';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class BootstrapService {\r\n constructor(\r\n private appService: AppService,\r\n private versionService: VersionService,\r\n private portalLayoutService: PortalLayoutService,\r\n private facade: FacadeService\r\n ) {}\r\n\r\n getFrontendVersion(): Promise {\r\n return this.versionService.getFrontendVersion().then(\r\n (version: any) => (this.versionService.frontend = version),\r\n () => {}\r\n );\r\n }\r\n\r\n getBackendVersion(): Promise {\r\n return this.versionService.getBackendVersion().then(\r\n (response: ResponseDefault) => (this.versionService.backend = response.data.id),\r\n () => {}\r\n );\r\n }\r\n\r\n getTranslations(): Promise {\r\n return this.facade.translator.load().then(\r\n (response: ResponseObject) => (this.facade.translator.translations = response.data.attributes),\r\n () => this.onErrorOccur()\r\n );\r\n }\r\n\r\n checkMaintenance(): Promise {\r\n this.facade.maintenance.maintenancePage = ROUTES_PATHS.maintenance.root;\r\n this.facade.maintenance.serverErrorPage = ROUTES_PATHS.notFoundPage.root;\r\n return this.facade.maintenance.check().then(\r\n response => this.facade.maintenance.onSuccess(response),\r\n error => this.facade.maintenance.onError(error)\r\n );\r\n }\r\n\r\n loadSettings(): Promise {\r\n return new Promise(resolve => {\r\n this.facade.settings.load().then(\r\n (response: ResponseObject) => {\r\n this.facade.settings.variables = response.data.attributes;\r\n const layoutData = this.portalLayoutService.prepareData({\r\n ...response.data.attributes.layout,\r\n ...response.data.attributes.site\r\n });\r\n this.portalLayoutService.setLayout(layoutData as Array>);\r\n this.facade.seo.setData(this.facade.settings.variables);\r\n resolve();\r\n },\r\n () => {\r\n this.facade.settings\r\n .loadDefaultVariables()\r\n .pipe(first())\r\n .subscribe(val => {\r\n this.facade.settings.variables = val;\r\n resolve();\r\n });\r\n }\r\n );\r\n });\r\n }\r\n\r\n getPermissions(): Promise {\r\n //this.authService.isAuthenticated\r\n if (!!localStorage.getItem('token')) {\r\n return this.facade.crud.load();\r\n } else {\r\n return new Promise((resolve, reject) => resolve());\r\n }\r\n }\r\n\r\n private onErrorOccur() {\r\n this.appService.setFatalError(true);\r\n this.facade.router.navigate([ROUTES_PATHS.unknownErrorPage.root]);\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { Observable, ReplaySubject, Subject } from 'rxjs';\r\nimport { first, switchMap } from 'rxjs/operators';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\n\r\ndeclare const grecaptcha: any;\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class CaptchaV3Service {\r\n public readonly grecaptcha: Subject = new ReplaySubject();\r\n private scriptElement: HTMLScriptElement;\r\n\r\n constructor(private settingsService: SettingsService) {}\r\n\r\n public load(): void {\r\n if (this.scriptElement) {\r\n return;\r\n }\r\n this.scriptElement = document.createElement('script');\r\n this.scriptElement.src = `https://www.google.com/recaptcha/api.js?render=${this.settingsService.variables.integration.googleReCaptchaSiteKey}`;\r\n this.scriptElement.async = true;\r\n this.scriptElement.addEventListener('load', event => {\r\n grecaptcha.ready(() => {\r\n this.grecaptcha.next(grecaptcha);\r\n });\r\n });\r\n this.scriptElement.addEventListener('error', event => {\r\n this.grecaptcha.next(null);\r\n });\r\n document.getElementsByTagName('head')[0].append(this.scriptElement);\r\n\r\n this.toggleVisibility();\r\n }\r\n\r\n execute(action: string = 'homepage'): Observable {\r\n return this.grecaptcha.pipe(first()).pipe(\r\n switchMap(val => {\r\n if (val === null) {\r\n throw new Error('Google captcha script is not loaded');\r\n }\r\n return val.execute(this.settingsService.variables.integration.googleReCaptchaSiteKey, { action });\r\n })\r\n );\r\n }\r\n\r\n toggleVisibility(show: boolean = true) {\r\n const grecaptcha: HTMLElement | null = document.querySelector('.grecaptcha-badge');\r\n if (grecaptcha) {\r\n grecaptcha.style.display = show ? 'block' : 'none';\r\n }\r\n }\r\n}\r\n","import { Injectable, Injector } from '@angular/core';\r\nimport { FacadeShareService } from '@share/common/services/facade-share.service';\r\nimport { SubheaderService } from '@app/template/layout/modules/header/services/subheader.service';\r\nimport { ScrollToService } from '@app/common/services/scroll-to.service';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class FacadeService extends FacadeShareService {\r\n private _subheader: SubheaderService;\r\n private _scrollTo: ScrollToService;\r\n private _settings: SettingsService;\r\n\r\n constructor(private injector: Injector) {\r\n super(injector);\r\n }\r\n\r\n public get subheader(): SubheaderService {\r\n if (!this._subheader) {\r\n this._subheader = this._injector.get(SubheaderService);\r\n }\r\n return this._subheader;\r\n }\r\n\r\n public get scrollTo(): ScrollToService {\r\n if (!this._scrollTo) {\r\n this._scrollTo = this._injector.get(ScrollToService);\r\n }\r\n return this._scrollTo;\r\n }\r\n\r\n public get settings(): SettingsService {\r\n if (!this._settings) {\r\n this._settings = this._injector.get(SettingsService);\r\n }\r\n return this._settings;\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\n\r\ndeclare var google: any;\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class GoogleTranslateService {\r\n public init() {\r\n // tslint:disable-next-line:no-unused-expression\r\n new google.translate.TranslateElement({\r\n pageLanguage: 'pl',\r\n includedLanguages: 'pl,cs,da,de,en,es,fi,fr,hu,it,ja,no,pt,ru,zh-CN',\r\n layout: google.translate.TranslateElement.InlineLayout.SIMPLE\r\n }, 'google_translate_element');\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { NgbModalOptions } from '@ng-bootstrap/ng-bootstrap';\r\nimport { ServiceHelper } from '@share/common/helpers/service.helper';\r\nimport { ImageZoomComponent } from '@app/template/elements/image-zoom/components/image-zoom/image-zoom.component';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ImageZoomService extends ServiceHelper {\r\n private readonly zoomClass: string = '.image-zoom';\r\n private readonly originalFilterName: string = 'original';\r\n\r\n constructor() {\r\n super('');\r\n }\r\n\r\n public setListener() {\r\n // TODO: it cant find correct dom data, in settimeout works\r\n const images = document.querySelectorAll(this.zoomClass);\r\n for (let i = 0; i < images.length; i++) {\r\n images[i].addEventListener('click', event => this.imagePreview(event.target as HTMLImageElement));\r\n }\r\n }\r\n\r\n public imagePreview(image: HTMLImageElement) {\r\n const src: string = image.src;\r\n const originalSrc: string = this.getOriginalPath(src);\r\n // @ts-ignore\r\n const config: NgbModalOptions = {keyboard: true, backdrop: true, size: 'xl'};\r\n this.modal.openCustomModal(ImageZoomComponent, {original: originalSrc, alt: image.alt}, config);\r\n }\r\n\r\n private getOriginalPath(src: string | null): string {\r\n if (!src) {\r\n return '';\r\n }\r\n let path: string = src.slice(0, src.indexOf('filterName'));\r\n path += `filterName=${this.originalFilterName}`;\r\n return path;\r\n }\r\n}\r\n","import {Injectable} from '@angular/core';\r\nimport {ApiService} from '@app/common/services/api.service';\r\nimport {Observable} from 'rxjs';\r\nimport {ResponseObject} from '@share/common/models/http.model';\r\nimport {Institution} from '@app/common/models/institution.model';\r\nimport {API} from '@app/common/constants/api.directories';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class InstitutionService {\r\n\r\n constructor(private apiService: ApiService) {}\r\n\r\n public getCurrent(): Observable> {\r\n return this.apiService.get(API.INSTITUTION.ROOT);\r\n }\r\n}\r\n","import {\r\n Compiler,\r\n ComponentRef,\r\n Inject,\r\n Injectable,\r\n Injector,\r\n NgModuleFactory,\r\n Type,\r\n ViewContainerRef\r\n} from '@angular/core';\r\nimport { LAZY_WIDGETS } from '@app/common/constants/tokens';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class LazyLoaderService {\r\n constructor(\r\n private injector: Injector,\r\n private compiler: Compiler,\r\n @Inject(LAZY_WIDGETS) private lazyWidgets: { [key: string]: () => Promise | Type> }\r\n ) {}\r\n\r\n async load(name: string, container: ViewContainerRef, component?: any): Promise> {\r\n const ngModuleOrNgModuleFactory = await this.lazyWidgets[name]();\r\n\r\n let moduleFactory;\r\n if (ngModuleOrNgModuleFactory instanceof NgModuleFactory) {\r\n moduleFactory = ngModuleOrNgModuleFactory;\r\n } else {\r\n moduleFactory = await this.compiler.compileModuleAsync(ngModuleOrNgModuleFactory);\r\n }\r\n const entryComponent = component || (moduleFactory.moduleType).entry;\r\n const moduleRef = moduleFactory.create(this.injector);\r\n\r\n const compFactory = moduleRef.componentFactoryResolver.resolveComponentFactory(entryComponent);\r\n\r\n return container.createComponent(compFactory);\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { Observable } from 'rxjs';\r\nimport { Preview } from '@app/client-core/preview/interfaces/preview.interface';\r\nimport { ResponseObject } from '@share/common/models/http';\r\nimport { PageModel } from '@app/common/models/page.model';\r\nimport { ApiService } from '@app/common/services/api.service';\r\nimport { API } from '../constants/api.directories';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class PagesService implements Preview {\r\n constructor(private apiService: ApiService) {}\r\n\r\n getOne(slug: string = ''): Observable>> {\r\n return this.apiService.get(`${API.PAGES.ROOT}${slug ? '/' + slug : ''}`);\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { LayoutService } from '@share/common/services/layout.service';\r\nimport { PortalVariablesEnum } from '@app/common/enums/portal-variables.enum';\r\nimport { PORTAL_VARIABLES_PRESETS } from '@app/common/constants/portal-variables-presets';\r\nimport { HttpClient } from '@angular/common/http';\r\nimport { ImageService } from '@share/common/services/image.service';\r\nimport { AbstractData } from '@share/common/models/http.model';\r\nimport { ObjectString } from '@share/common/interfaces/object-types.interface';\r\nimport { Variable } from '@share/common/interfaces/variables.interface';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class PortalLayoutService extends LayoutService {\r\n\r\n constructor(protected httpClient: HttpClient,\r\n protected imageService: ImageService) {\r\n super(httpClient, imageService);\r\n this.layoutPresets = PORTAL_VARIABLES_PRESETS;\r\n }\r\n\r\n public prepareData(variables: ObjectString): Array>> {\r\n const data: Array>> = [];\r\n for (const variable of Object.keys(variables)) {\r\n data.push({\r\n id: '0',\r\n type: '',\r\n attributes: {\r\n name: variable,\r\n value: variables[variable]\r\n }\r\n });\r\n }\r\n return data;\r\n }\r\n\r\n protected variablesQueue(): Array {\r\n return [\r\n PortalVariablesEnum.AccentColor,\r\n PortalVariablesEnum.ButtonColor,\r\n PortalVariablesEnum.MainColor,\r\n PortalVariablesEnum.SectionBackgroundColor,\r\n ];\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { fromEvent, merge, Observable, of } from 'rxjs';\r\nimport { map, switchMap } from 'rxjs/operators';\r\nimport { MobileEnum } from '@app/common/enums/mobile.enum';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ResizeListener {\r\n get isMobile$(): Observable {\r\n return merge(this.onLoad(), this.onResize()).pipe(\r\n switchMap(value => {\r\n if (!value) {\r\n return this.isMobileDevice();\r\n }\r\n return of(value);\r\n })\r\n );\r\n }\r\n\r\n private onResize(): Observable {\r\n return fromEvent(window, 'resize').pipe(map(() => window.innerWidth < MobileEnum.Large));\r\n }\r\n\r\n private onLoad(): Observable {\r\n return of(window.innerWidth < MobileEnum.Large);\r\n }\r\n private isMobileDevice(): Observable {\r\n return of(/iPhone|iPad|iPod|Android/i.test(navigator.userAgent));\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\n\r\ndeclare var $: Function;\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ScrollToService {\r\n\r\n constructor() {}\r\n\r\n animate(id: string, time: number = 500, scrollDifference: number = 70) {\r\n try {\r\n $('html, body').animate({\r\n scrollTop: ($(id).offset().top as number) - scrollDifference,\r\n }, time);\r\n } catch (ignore) {\r\n }\r\n }\r\n\r\n resetScrollTop() {\r\n window.scrollTo(0, 0);\r\n }\r\n}\r\n\r\n","import { Injectable } from '@angular/core';\r\nimport { API } from '@app/common/constants/api.directories';\r\nimport { ApiService } from '@app/common/services/api.service';\r\nimport { Observable } from 'rxjs';\r\nimport { BootstrapModel } from '@app/common/models/bootstrap.model';\r\nimport { ResponseObject } from '@share/common/models/http';\r\nimport { ThemesEnum } from '@app/common/models/themes.enum';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class SettingsService {\r\n variables: T;\r\n\r\n constructor(private apiService: ApiService) {}\r\n\r\n load(): Promise> {\r\n return this.apiService.get(API.SETTINGS.ROOT).toPromise();\r\n }\r\n\r\n loadDefaultVariables(): Observable {\r\n return this.apiService.assets(API.ASSETS.DEFAULT_SETTINGS);\r\n }\r\n\r\n isModuleActive(theme: ThemesEnum): boolean {\r\n return this.variables.theme.modules.includes(theme);\r\n }\r\n}\r\n","import {Injectable} from '@angular/core';\r\nimport {Location} from '@angular/common';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class UrlService {\r\n constructor(private location: Location) {}\r\n\r\n getParsedUrl(): string {\r\n const path: string = this.location.path();\r\n return path.substr(1, path.length).replace(/\\//g, ',');\r\n }\r\n\r\n getLastUrlElement(): string {\r\n const paths: string[] = this.getParsedUrl().split(',');\r\n return paths[paths.length - 1];\r\n }\r\n}\r\n","import { CommonModule } from '@angular/common';\r\nimport { NgModule } from '@angular/core';\r\nimport { AccordionComponent } from './component/accordion/accordion.component';\r\nimport { AccPanelTitleDirective, AccPanelContentDirective, AccPanelDirective } from './directives/accordion-panel.directive';\r\n\r\n@NgModule({\r\n imports: [CommonModule],\r\n exports: [\r\n AccordionComponent,\r\n AccPanelTitleDirective,\r\n AccPanelContentDirective,\r\n AccPanelDirective\r\n ],\r\n declarations: [\r\n AccordionComponent,\r\n AccPanelTitleDirective,\r\n AccPanelContentDirective,\r\n AccPanelDirective\r\n ]\r\n})\r\nexport class AccordionModule {}\r\n","import { AfterContentChecked, Component, ContentChildren, EventEmitter, Input, Output, QueryList, ViewEncapsulation } from '@angular/core';\r\nimport { AccPanelChangeEvent } from '../../interfaces/accordion-panel-change-event.model';\r\nimport { AccPanelDirective } from '../../directives/accordion-panel.directive';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\n\r\n@Component({\r\n selector: 'app-accordion',\r\n templateUrl: './accordion.component.html',\r\n styleUrls: ['./accordion.component.scss']\r\n})\r\nexport class AccordionComponent extends ComponentHelper implements AfterContentChecked {\r\n @ContentChildren(AccPanelDirective) panels: QueryList;\r\n @Input() activeIds: string[] = [];\r\n @Output() readonly panelChange = new EventEmitter();\r\n\r\n constructor() {\r\n super();\r\n }\r\n\r\n private _findPanelById(panelId: string): AccPanelDirective | undefined {\r\n return this.panels.find(p => p.id === panelId);\r\n }\r\n\r\n\r\n private _updateActiveIds() {\r\n this.activeIds = this.panels.filter(panel => panel.isOpen && !panel.disabled).map(panel => panel.id);\r\n }\r\n\r\n private _changeOpenState(panel: AccPanelDirective, nextState: boolean, target: EventTarget) {\r\n if (panel && !panel.disabled && panel.isOpen !== nextState) {\r\n let defaultPrevented = false;\r\n\r\n this.panelChange.emit({\r\n panelId: panel.id,\r\n nextState: nextState,\r\n target,\r\n prevent: () => { defaultPrevented = true; }\r\n });\r\n\r\n if (!defaultPrevented) {\r\n panel.isOpen = nextState;\r\n\r\n this._updateActiveIds();\r\n }\r\n }\r\n }\r\n\r\n toggle(panelId: string, target: EventTarget) {\r\n const panel = this._findPanelById(panelId);\r\n if (panel) {\r\n this._changeOpenState(panel, !panel.isOpen, target);\r\n }\r\n }\r\n\r\n isPanelActive(panelId: string): boolean {\r\n return this.activeIds && this.activeIds.indexOf(panelId) !== -1;\r\n }\r\n\r\n expandAll() {\r\n this.panels.forEach(panel => {\r\n if (this.activeIds.indexOf(panel.id) === -1) {\r\n this.activeIds.push(panel.id);\r\n }\r\n });\r\n }\r\n\r\n ngAfterContentChecked() {\r\n this.panels.forEach(panel => panel.isOpen = !panel.disabled && this.activeIds.indexOf(panel.id) > -1);\r\n }\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { AfterContentChecked, ContentChildren, Directive, Input, QueryList, TemplateRef } from '@angular/core';\r\n\r\n@Directive({selector: 'ng-template[appAccPanelTitle]'})\r\nexport class AccPanelTitleDirective {\r\n constructor(public templateRef: TemplateRef) {}\r\n}\r\n\r\n@Directive({selector: 'ng-template[appAccPanelContent]'})\r\nexport class AccPanelContentDirective {\r\n constructor(public templateRef: TemplateRef) {}\r\n}\r\n\r\n@Directive({selector: '[appAccPanel]'})\r\nexport class AccPanelDirective implements AfterContentChecked {\r\n\r\n @Input() disabled = false;\r\n @Input() id: string;\r\n @Input() title: string;\r\n @Input() type: string;\r\n @Input() isOpen = false;\r\n\r\n @ContentChildren(AccPanelTitleDirective, {descendants: false}) titleTpls: QueryList;\r\n @ContentChildren(AccPanelContentDirective, {descendants: false}) contentTpls: QueryList;\r\n\r\n titleTpl: AccPanelTitleDirective | null;\r\n contentTpl: AccPanelContentDirective | null;\r\n\r\n constructor() { }\r\n\r\n ngAfterContentChecked() {\r\n this.titleTpl = this.titleTpls.first;\r\n this.contentTpl = this.contentTpls.first;\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { MultiCarouselComponent } from './components/multi-carousel/multi-carousel.component';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { PolygonModule } from '@app/template/elements/polygon/polygon.module';\r\n\r\n@NgModule({\r\n declarations: [\r\n MultiCarouselComponent\r\n ],\r\n imports: [\r\n CommonModule,\r\n TranslatorModule,\r\n PolygonModule\r\n ],\r\n exports: [\r\n MultiCarouselComponent\r\n ]\r\n})\r\nexport class CarouselModule {}\r\n","import { AfterViewChecked, Component, ElementRef, Input } from '@angular/core';\r\nimport { MultiCarousel } from '../../models/multi-carousel.model';\r\nimport { MultiCarouselConfig } from '../../models/multi-carousel-config.model';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { AbstractData } from '@share/common/models/http';\r\n\r\ndeclare var $: Function;\r\n\r\n@Component({\r\n selector: 'app-multi-carousel',\r\n templateUrl: './multi-carousel.component.html',\r\n styleUrls: [\r\n './multi-carousel.component.scss'\r\n ]\r\n})\r\nexport class MultiCarouselComponent extends ComponentHelper implements AfterViewChecked {\r\n @Input() data: Array> = [];\r\n\r\n @Input()\r\n set config(config: MultiCarouselConfig) {\r\n this._config = Object.assign(this._config, config);\r\n }\r\n\r\n private _config: MultiCarouselConfig = {\r\n dots: true,\r\n nav: true,\r\n itemsOnScreen: {\r\n 0: {\r\n items: 2\r\n },\r\n 600: {\r\n items: 3\r\n },\r\n 1000: {\r\n items: 4\r\n }\r\n },\r\n autoplayHoverPause: false,\r\n autoplay: false,\r\n autoplayTimeout: 5000,\r\n loop: false\r\n };\r\n\r\n get config() {\r\n return this._config;\r\n }\r\n\r\n private isCarouselInit = false;\r\n\r\n constructor(private elementRef: ElementRef) {\r\n super();\r\n }\r\n\r\n public initCarousel(): void {\r\n const owl = $('.owl-carousel').owlCarousel({\r\n margin: 0,\r\n responsive: this.config.itemsOnScreen,\r\n dots: this.config.dots,\r\n nav: this.config.nav,\r\n dotsContainer: '#owl-carousel-custom-dots',\r\n navContainer: '#owl-carousel-custom-nav',\r\n navText: [\r\n ``,\r\n ``\r\n ],\r\n autoplay: this.config.autoplay,\r\n autoplayTimeout: this.config.autoplayTimeout,\r\n autoplayHoverPause: this.config.autoplayHoverPause,\r\n loop: this.config.loop\r\n });\r\n $('.owl-dots').on('click', 'li', function (e: any) {\r\n // @ts-ignore\r\n owl.trigger('to.owl.carousel', [$(this).index(), 300]);\r\n });\r\n }\r\n\r\n\r\n private setAriaLabels() {\r\n const dots = this.elementRef.nativeElement.querySelectorAll('.owl-dot');\r\n dots.forEach((dot: HTMLButtonElement, index: number) => {\r\n dot.setAttribute('aria-label', this.trans('global.goToPage') + (index + 1));\r\n });\r\n }\r\n\r\n getLink(url: string): string {\r\n return url?.length > 3 && url.substr(0, 3) === 'www' ? `//${url}` : url\r\n }\r\n\r\n ngAfterViewChecked() {\r\n const carousel = $('.owl-carousel');\r\n if (carousel.length > 0 && !this.isCarouselInit) {\r\n setTimeout(() => {\r\n this.initCarousel();\r\n this.setAriaLabels();\r\n });\r\n this.isCarouselInit = true;\r\n }\r\n }\r\n}\r\n","\r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n\r\n\r\n","import {Component, Input} from '@angular/core';\r\n\r\n@Component({\r\n selector: 'shared-heading-section',\r\n templateUrl: './heading-section.component.html',\r\n styleUrls: ['./heading-section.component.scss']\r\n})\r\nexport class HeadingSectionComponent {\r\n @Input() number: number = 0;\r\n @Input() subtitle: string = '';\r\n @Input() title: string;\r\n @Input() innerColor: boolean = false;\r\n @Input() hsClass: string;\r\n\r\n}\r\n","\r\n \r\n {{ title }}\r\n \r\n - {{subtitle}}\r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { HeadingSectionComponent } from './components/heading-section/heading-section.component';\r\nimport {PolygonModule} from '@app/template/elements/polygon/polygon.module';\r\n\r\n@NgModule({\r\n declarations: [\r\n HeadingSectionComponent\r\n ],\r\n exports: [\r\n HeadingSectionComponent\r\n ],\r\n imports: [\r\n CommonModule,\r\n PolygonModule\r\n ]\r\n})\r\nexport class HeadingModule { }\r\n","import { Component, Input } from '@angular/core';\r\nimport { NgbActiveModal } from '@ng-bootstrap/ng-bootstrap';\r\nimport { ImageZoom } from '@app/template/elements/image-zoom/interfaces/image-zoom.interface';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\n\r\n@Component({\r\n selector: 'app-image-zoom',\r\n templateUrl: './image-zoom.component.html'\r\n})\r\nexport class ImageZoomComponent extends ComponentHelper {\r\n @Input() public data: ImageZoom;\r\n public loading: boolean = true;\r\n public placeholder: boolean = false;\r\n\r\n constructor(private activeModal: NgbActiveModal) {\r\n super();\r\n }\r\n\r\n public close() {\r\n this.activeModal.close();\r\n }\r\n\r\n public onLoad() {\r\n this.loading = false;\r\n }\r\n\r\n public onError() {\r\n this.onLoad();\r\n this.placeholder = true;\r\n }\r\n}\r\n","\r\n {{data.alt}}\r\n \r\n {{'x'}}\r\n \r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { ImageZoomComponent } from '@app/template/elements/image-zoom/components/image-zoom/image-zoom.component';\r\nimport { ProgressBarModule } from '@share/modules/progress-bar/progress-bar.module';\r\nimport { CommonModule } from '@angular/common';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n ProgressBarModule\r\n ],\r\n declarations: [\r\n ImageZoomComponent\r\n ],\r\n exports: [\r\n ImageZoomComponent\r\n ],\r\n entryComponents: [\r\n ImageZoomComponent\r\n ]\r\n})\r\nexport class ImageZoomModule {}\r\n","import { Component, Input } from '@angular/core';\r\nimport { ControlValueAccessor, NgControl } from '@angular/forms';\r\n\r\n@Component({\r\n selector: 'app-input',\r\n templateUrl: 'input.component.html',\r\n styleUrls: ['input.component.scss']\r\n})\r\nexport class InputComponent implements ControlValueAccessor {\r\n\r\n @Input() label: string;\r\n @Input() id: string;\r\n\r\n private onChange: (v: string) => void = (v: string) => {};\r\n private onTouch: () => void = () => {};\r\n\r\n value: string;\r\n\r\n constructor(private ngControl: NgControl) {\r\n this.ngControl.valueAccessor = this;\r\n }\r\n\r\n registerOnChange(fn: any): void {\r\n this.onChange = fn;\r\n }\r\n\r\n registerOnTouched(fn: any): void {\r\n this.onTouch = fn;\r\n }\r\n\r\n writeValue(obj: any): void {\r\n this.value = obj;\r\n this.onChange(obj);\r\n }\r\n}\r\n","\r\n \r\n {{ label }}\r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { InputComponent } from '@app/template/elements/input/input.component';\r\nimport { FormsModule } from '@angular/forms';\r\n\r\n@NgModule({\r\n declarations: [InputComponent],\r\n exports: [InputComponent],\r\n imports: [CommonModule, FormsModule]\r\n})\r\nexport class InputModule {}\r\n","import { Component, EventEmitter, Input, Output } from '@angular/core';\r\nimport { PaginationService } from '../../services/pagination.service';\r\n\r\n@Component({\r\n selector: 'shared-pagination',\r\n templateUrl: './pagination.component.html',\r\n styleUrls: ['./pagination.component.scss'],\r\n})\r\nexport class PaginationComponent {\r\n\r\n @Input() public perPage: number = 10;\r\n @Input() public pages: number = 1;\r\n @Input() public position: 'left' | 'right' = 'right';\r\n @Output() readonly changed: EventEmitter = new EventEmitter();\r\n\r\n constructor(private paginationService: PaginationService) {}\r\n\r\n\r\n public get total(): number {\r\n return this.perPage * this.pages;\r\n }\r\n\r\n public set currentPage(value: number) {\r\n this.paginationService.page = value;\r\n this.changed.emit(value);\r\n }\r\n\r\n public get currentPage(): number {\r\n return this.paginationService.page;\r\n }\r\n\r\n\r\n}\r\n"," 1\">\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n {{'...'}}\r\n {{ currentPage }}\r\n \r\n \r\n \r\n\r\n","import {NgModule} from '@angular/core';\r\nimport {CommonModule} from '@angular/common';\r\nimport {PaginationComponent} from './components/pagination/pagination.component';\r\nimport {NgbPaginationModule} from '@ng-bootstrap/ng-bootstrap';\r\nimport {PaginationService} from './services/pagination.service';\r\n\r\n@NgModule({\r\n declarations: [\r\n PaginationComponent\r\n ],\r\n imports: [\r\n CommonModule,\r\n NgbPaginationModule\r\n ],\r\n exports: [\r\n PaginationComponent\r\n ],\r\n providers: [\r\n PaginationService\r\n ]\r\n})\r\nexport class PaginationModule {}\r\n","import { Injectable } from '@angular/core';\r\nimport { BehaviorSubject, Observable, Subscription } from 'rxjs';\r\nimport { ComponentShareHelper } from '@share/common/helpers/component-share.helper';\r\nimport { FacadeShareService } from '@share/common/services/facade-share.service';\r\nimport { ActivatedRoute, Params } from '@angular/router';\r\n\r\n@Injectable()\r\nexport class PaginationService extends ComponentShareHelper {\r\n private firstPage: number = 1;\r\n private _page: BehaviorSubject = new BehaviorSubject(this.firstPage);\r\n\r\n constructor(private facadeShareService: FacadeShareService,\r\n private activatedRoute: ActivatedRoute) {\r\n super(facadeShareService);\r\n this.setParamsListener();\r\n }\r\n\r\n public setParamsListener() {\r\n return this.activatedRoute.queryParams.subscribe((params: Params) => {\r\n if (params.page) {\r\n this.page = parseInt(params.page, 10);\r\n } else {\r\n this._page.next(this.firstPage);\r\n }\r\n });\r\n }\r\n\r\n private changeQueryParams(value: number) {\r\n setTimeout(() => {\r\n this.facadeShareService.router.navigate([], {\r\n relativeTo: this.activatedRoute,\r\n queryParams: {page: value === this.firstPage ? null : value}\r\n });\r\n });\r\n }\r\n\r\n public set page(value: number) {\r\n if (value !== this.page) {\r\n this._page.next(value);\r\n this.changeQueryParams(value);\r\n }\r\n }\r\n\r\n public get page(): number {\r\n return this._page.getValue();\r\n }\r\n\r\n public get currentPage(): Observable {\r\n return this._page.asObservable();\r\n }\r\n}\r\n","import { Component, Input } from '@angular/core';\r\nimport { UtilsService } from '@share/common/services/utils.service';\r\n\r\n@Component({\r\n selector: 'shared-hexagon-content',\r\n templateUrl: './hexagon-content.component.html',\r\n styleUrls: ['./hexagon-content.component.scss']\r\n})\r\nexport class HexagonContentComponent {\r\n @Input() bgColor: string;\r\n @Input() borderColor: string;\r\n @Input() borderWidth: number = 0;\r\n @Input() width: number = 100;\r\n @Input() height: number = 100;\r\n @Input() isInnerShadow: boolean = false;\r\n @Input() innerShadowConfig: { alpha: number, blur: number } = {alpha: 0.3, blur: 2};\r\n @Input() isOuterShadow: boolean = false;\r\n @Input() isHover: boolean = false;\r\n @Input() bgGradient: boolean = false;\r\n @Input() borderGradient: boolean = false;\r\n @Input() edgeRounded: boolean = false;\r\n @Input() bgImage: string = '';\r\n\r\n public innerShadowID: string = '';\r\n\r\n constructor(private utils: UtilsService) {\r\n this.innerShadowID = this.utils.makeId();\r\n }\r\n\r\n public get location() {\r\n return window.location.href;\r\n }\r\n\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport {HexagonContentComponent} from './components/hexagon-content/hexagon-content.component';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule\r\n ],\r\n declarations: [\r\n HexagonContentComponent\r\n ],\r\n exports: [\r\n HexagonContentComponent\r\n ]\r\n})\r\nexport class PolygonModule {\r\n}\r\n","import { Component, Input, ViewEncapsulation } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'app-promoted-item-icon',\r\n styleUrls: ['promoted-item-icon.component.scss'],\r\n templateUrl: 'promoted-item-icon.component.html',\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class PromotedItemIconComponent {\r\n\r\n @Input() icon: string;\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n\r\n","import { Component, ElementRef, EventEmitter, Input, OnDestroy, Output, Renderer2 } from '@angular/core';\r\nimport { Promoted } from '../../models/promoted.model';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { AbstractData } from '@share/common/models/http';\r\n\r\n@Component({\r\n selector: 'app-promoted-list',\r\n templateUrl: './promoted-list.component.html',\r\n styleUrls: [`./promoted-list.component.scss`]\r\n})\r\nexport class PromotedListComponent extends ComponentHelper implements OnDestroy {\r\n @Input() data: Array>;\r\n\r\n @Input() filter: string;\r\n @Input() height: number = 420;\r\n @Input() background?: string = '';\r\n @Input() hasIcon: boolean = false;\r\n @Output() readonly clicked: EventEmitter = new EventEmitter();\r\n private listenClickFunc: Function;\r\n\r\n constructor(private renderer: Renderer2, private _elementRef: ElementRef) {\r\n super();\r\n this.onClickListener();\r\n }\r\n\r\n private onClickListener(): void {\r\n this.listenClickFunc = this.renderer.listen(this._elementRef.nativeElement, 'click', event =>\r\n this.shareService.utils.navigateTo(event)\r\n );\r\n }\r\n\r\n public imagePath(path: string) {\r\n return this.shareService.image.img({ file: path, filter: this.filter });\r\n }\r\n\r\n public navigateTo(event: Event, url: string, id: string) {\r\n event.preventDefault();\r\n event.stopPropagation();\r\n window.open(url);\r\n this.onClick(id);\r\n }\r\n\r\n public onClick(slug: string) {\r\n this.clicked.emit(slug);\r\n }\r\n\r\n public ngOnDestroy() {\r\n this.listenClickFunc();\r\n }\r\n\r\n public get dataExists(): boolean {\r\n return Array.isArray(this.data) && this.data.length > 0;\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n {{ promoted.attributes.title | truncate: 50 }}\r\n \r\n {{'global.findOutMore' | trans}}\r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { PolygonModule } from '../polygon/polygon.module';\r\nimport { PromotedListComponent } from './components/promoted-list/promoted-list.component';\r\nimport { CommonModule } from '@angular/common';\r\nimport { RouterModule } from '@angular/router';\r\nimport { TruncateModule } from '@share/modules/truncate/truncate.module';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { PromotedItemIconComponent } from './components/promoted-item-icon/promoted-item-icon.component';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\n\r\n@NgModule({\r\n declarations: [\r\n PromotedListComponent,\r\n PromotedItemIconComponent\r\n ],\r\n imports: [\r\n CommonModule,\r\n RouterModule,\r\n PolygonModule,\r\n TruncateModule,\r\n ElementsModule,\r\n TranslatorModule\r\n ],\r\n exports: [\r\n PromotedListComponent\r\n ]\r\n})\r\nexport class PromotedModule {\r\n}\r\n","import { ChangeDetectionStrategy, Component, OnInit } from '@angular/core';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { PagesService } from '@app/common/services/pages.service';\r\nimport { first } from 'rxjs/operators';\r\n\r\n@Component({\r\n selector: 'app-simple-box',\r\n styleUrls: ['simple-box.component.scss'],\r\n templateUrl: 'simple-box.component.html',\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class SimpleBoxComponent implements OnInit {\r\n data: {\r\n button: string;\r\n contactBoxIcon: string;\r\n contactPage: string;\r\n content: string;\r\n title: string;\r\n };\r\n\r\n constructor(private facadeService: FacadeService, private pageService: PagesService) {}\r\n\r\n ngOnInit() {\r\n this.data = this.facadeService.settings.variables.contactBox;\r\n }\r\n\r\n onButtonClick() {\r\n this.pageService\r\n .getOne(this.data.contactPage)\r\n .pipe(first())\r\n .subscribe(page => this.facadeService.router.navigate([page.data.id.replace(',', '/')]));\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n\r\n {{ data.title }}\r\n {{ data.content }}\r\n \r\n\r\n \r\n\r\n \r\n\r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { SimpleBoxComponent } from '@app/template/elements/simple-box/components/simple-box.component';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { CommonModule } from '@angular/common';\r\n\r\n@NgModule({\r\n declarations: [SimpleBoxComponent],\r\n imports: [\r\n ElementsModule,\r\n CommonModule\r\n ],\r\n exports: [SimpleBoxComponent]\r\n})\r\nexport class SimpleBoxModule {\r\n\r\n}\r\n","import { Component, Input } from '@angular/core';\r\nimport { ControlValueAccessor, NgControl } from '@angular/forms';\r\n\r\n@Component({\r\n selector: 'app-textarea',\r\n templateUrl: 'textarea.component.html',\r\n styleUrls: ['textarea.component.scss']\r\n})\r\nexport class TextareaComponent implements ControlValueAccessor {\r\n\r\n @Input() label: string;\r\n @Input() id: string;\r\n\r\n private onChange: (v: string) => void = (v: string) => {};\r\n private onTouch: () => void = () => {};\r\n\r\n value: string;\r\n\r\n constructor(private ngControl: NgControl) {\r\n this.ngControl.valueAccessor = this;\r\n }\r\n\r\n registerOnChange(fn: any): void {\r\n this.onChange = fn;\r\n }\r\n\r\n registerOnTouched(fn: any): void {\r\n this.onTouch = fn;\r\n }\r\n\r\n writeValue(obj: any): void {\r\n this.value = obj;\r\n this.onChange(obj);\r\n }\r\n}\r\n","\r\n \r\n {{ label }}\r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { TextareaComponent } from './textarea.component';\r\nimport { CommonModule } from '@angular/common';\r\nimport { FormsModule } from '@angular/forms';\r\n\r\n@NgModule({\r\n imports: [CommonModule, FormsModule],\r\n declarations: [TextareaComponent],\r\n exports: [TextareaComponent]\r\n})\r\nexport class TextareaModule {}\r\n","import { ChangeDetectionStrategy, Component, Input } from '@angular/core';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { MultiCarousel } from '@app/template/elements/carousel/models/multi-carousel.model';\r\nimport { MultiCarouselConfig } from '@app/template/elements/carousel/models/multi-carousel-config.model';\r\nimport { ImageCropper } from '@app/template/home/models/image-cropper.model';\r\n\r\n@Component({\r\n selector: 'app-gallery',\r\n templateUrl: 'gallery.component.html',\r\n styleUrls: ['gallery.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class GalleryComponent {\r\n config: MultiCarouselConfig = {\r\n dots: false,\r\n nav: true,\r\n itemsOnScreen: {\r\n 0: {\r\n items: 2\r\n },\r\n 700: {\r\n items: 2\r\n },\r\n 800: {\r\n items: 2\r\n },\r\n 1140: {\r\n items: 3\r\n },\r\n 1370: {\r\n items: 4\r\n }\r\n },\r\n autoplayHoverPause: false,\r\n autoplay: false,\r\n autoplayTimeout: 5000,\r\n loop: false\r\n };\r\n\r\n @Input() set data(value: { gallery: AbstractData<{ image: ImageCropper; alt: string }>[] }) {\r\n if (value) {\r\n this.parsedData = value.gallery.map(item => ({\r\n id: item.id,\r\n type: item.type,\r\n attributes: {\r\n file: item.attributes.image.url || (item.attributes.image.croppedUrl as string),\r\n description: item.attributes.alt,\r\n url: '',\r\n isOpenInNewWindow: false\r\n }\r\n }));\r\n }\r\n }\r\n parsedData: Array> = [];\r\n}\r\n","\r\n \r\n \r\n \r\n\r\n\r\n\r\n Galeria\r\n \r\n\r\n\r\n\r\n \r\n \r\n \r\n\r\n","import { ChangeDetectionStrategy, Component, Input } from '@angular/core';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { HomeIntroModel } from '@app/template/home/models/home-intro.model';\r\n\r\n@Component({\r\n selector: 'app-main-banner',\r\n templateUrl: 'main-banner.component.html',\r\n styleUrls: ['main-banner.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class MainBannerComponent {\r\n\r\n @Input() data: HomeIntroModel;\r\n\r\n constructor(private facadeService: FacadeService) {\r\n }\r\n\r\n scrollDown() {\r\n this.facadeService.scrollTo.animate('#promoted', 800, 100);\r\n }\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { ChangeDetectionStrategy, ChangeDetectorRef, Component, Input, OnChanges, SimpleChanges } from '@angular/core';\r\nimport { ArticlesService } from '@app/client-core/article/services/articles.service';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { Article } from '@app/client-core/article/models/article.model';\r\nimport { finalize, first, switchMap } from 'rxjs/operators';\r\nimport { Router } from '@angular/router';\r\nimport { PagesService } from '@app/common/services/pages.service';\r\nimport { DynamicContentService } from '@app/client-core/dynamic-content/service/dynamic-content.service';\r\n\r\n@Component({\r\n selector: 'app-news',\r\n styleUrls: ['news.component.scss'],\r\n templateUrl: 'news.component.html',\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class NewsComponent implements OnChanges {\r\n news: AbstractData[];\r\n loading: boolean;\r\n getError: boolean;\r\n\r\n @Input() data: {\r\n title: string;\r\n subtitle: string;\r\n category: string;\r\n };\r\n\r\n constructor(\r\n private articleService: ArticlesService,\r\n private cdr: ChangeDetectorRef,\r\n private pageService: PagesService,\r\n private router: Router,\r\n private dynamicContentService: DynamicContentService\r\n ) {}\r\n\r\n ngOnChanges(changes: SimpleChanges): void {\r\n if (changes.data.currentValue) {\r\n this.getNews();\r\n }\r\n }\r\n\r\n setLoader(value: boolean) {\r\n this.loading = value;\r\n this.cdr.detectChanges();\r\n }\r\n\r\n test() {\r\n this.pageService.getOne();\r\n }\r\n\r\n getNews() {\r\n this.setLoader(true);\r\n this.pageService\r\n .getOne(this.data.category)\r\n .pipe(\r\n first(),\r\n finalize(() => this.setLoader(false))\r\n )\r\n .subscribe(\r\n response => this.getMetadata(response.data.id),\r\n error => (this.getError = true)\r\n );\r\n }\r\n\r\n getMetadata(url: string) {\r\n this.dynamicContentService\r\n .getPageMetadata(url)\r\n .pipe(switchMap(metadata => this.articleService.getList(1, 4, metadata.meta?.objectId)))\r\n .subscribe(news => {\r\n this.news = news.data;\r\n this.cdr.detectChanges();\r\n });\r\n }\r\n\r\n showMoreClicked() {\r\n this.router.navigate(['aktualnosci']);\r\n }\r\n\r\n readMoreClicked(item: AbstractData) {\r\n this.router.navigate(['aktualnosci', item.attributes.slug]);\r\n }\r\n}\r\n","\r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n\r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n\r\n \r\n {{\r\n category.attributes.title\r\n }}\r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n {{ item.attributes.title }}\r\n \r\n \r\n {{ item.attributes.publishedFrom | date: 'shortDate':'':'pl' }}\r\n \r\n \r\n {{ item.attributes.description }}\r\n \r\n \r\n \r\n \r\n\r\n","import {\r\n AfterViewInit,\r\n ChangeDetectionStrategy,\r\n ChangeDetectorRef,\r\n Component,\r\n Input,\r\n OnInit,\r\n ViewChild,\r\n ViewContainerRef\r\n} from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { LazyLoaderService } from '@app/common/services/lazy-loader.service';\r\nimport { ROUTES_PATHS } from '@app/common/constants/routes-paths';\r\nimport { Router } from '@angular/router';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { finalize, first } from 'rxjs/operators';\r\nimport { HomeService } from '@app/template/home/services/home.service';\r\nimport { PagesService } from '@app/common/services/pages.service';\r\nimport { PageModel } from '@app/common/models/page.model';\r\nimport { HomeModel } from '@app/template/home/models/home.model';\r\n\r\n@Component({\r\n selector: 'app-home',\r\n templateUrl: './overlay.component.html',\r\n styleUrls: ['./overlay.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class OverlayComponent extends ComponentHelper implements OnInit, AfterViewInit {\r\n @ViewChild('businessModules', { read: ViewContainerRef }) businessModules: ViewContainerRef;\r\n @Input() data: AbstractData>;\r\n loading: boolean = true;\r\n\r\n constructor(\r\n private settingsService: SettingsService,\r\n private lazyLoaderService: LazyLoaderService,\r\n private pagesService: PagesService,\r\n private router: Router,\r\n private cdr: ChangeDetectorRef,\r\n private homeService: HomeService\r\n ) {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n this.service.scrollTo.resetScrollTop();\r\n }\r\n\r\n private setLoading(value: boolean) {\r\n this.loading = value;\r\n this.cdr.markForCheck();\r\n }\r\n\r\n getMainPage() {\r\n this.setLoading(true);\r\n this.pagesService\r\n .getOne()\r\n .pipe(\r\n first(),\r\n finalize(() => this.setLoading(false))\r\n )\r\n .subscribe(\r\n response => {\r\n this.data = response.data;\r\n },\r\n () => {\r\n this.router.navigate(['/', ROUTES_PATHS.notFoundPage.root]);\r\n }\r\n );\r\n }\r\n\r\n ngAfterViewInit() {\r\n if (!this.data) {\r\n this.getMainPage();\r\n } else {\r\n this.loading = false;\r\n this.homeService.isHomePreview = true;\r\n }\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n\r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { ChangeDetectionStrategy, ChangeDetectorRef, Component, Input, OnInit } from '@angular/core';\r\nimport { PromotedService } from '@app/template/home/services/promoted.service';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { Promoted } from '@app/template/elements/promoted/models/promoted.model';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { finalize, first } from 'rxjs/operators';\r\n\r\n@Component({\r\n selector: 'app-promoted',\r\n templateUrl: './promoted.component.html',\r\n styleUrls: ['./promoted.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class PromotedComponent extends ComponentHelper implements OnInit {\r\n @Input() data: { title: string; subtitle: string };\r\n promoted: Array> = [];\r\n loading: boolean = false;\r\n\r\n constructor(private promotedService: PromotedService, private cdr: ChangeDetectorRef) {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n this.loadPromoted();\r\n }\r\n\r\n loadPromoted() {\r\n this.setLoading(true);\r\n this.promotedService\r\n .getList()\r\n .pipe(\r\n first(),\r\n finalize(() => this.setLoading(false))\r\n )\r\n .subscribe(\r\n response => (this.promoted = this.getResponseData(response)),\r\n () => this.setComponentError()\r\n );\r\n }\r\n\r\n private setLoading(value: boolean) {\r\n this.loading = value;\r\n this.cdr.markForCheck();\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { ChangeDetectionStrategy, Component, Input } from '@angular/core';\r\nimport { HomeReportCrashModel } from '@app/template/home/models/home-report-crash.model';\r\n\r\n@Component({\r\n selector: 'app-report-crash',\r\n templateUrl: 'report-crash.component.html',\r\n styleUrls: ['report-crash.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class ReportCrashComponent {\r\n @Input() data: HomeReportCrashModel;\r\n}\r\n","\r\n \r\n \r\n \r\n {{ data?.title }}\r\n {{ data?.content }}\r\n \r\n \r\n \r\n \r\n \r\n {{ data?.contactOne?.title }}\r\n \r\n \r\n {{ data?.contactOne.phone }}\r\n \r\n \r\n \r\n {{ data?.contactOne.officeHours }}\r\n \r\n \r\n \r\n {{ data?.contactTwo?.title }}\r\n \r\n \r\n \r\n {{ data?.contactTwo?.phone }}\r\n \r\n \r\n \r\n \r\n {{ data?.contactTwo?.officeHours }}\r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { ChangeDetectionStrategy, ChangeDetectorRef, Component, Input, OnChanges, SimpleChanges } from '@angular/core';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { PagesService } from '@app/common/services/pages.service';\r\nimport { finalize, first } from 'rxjs/operators';\r\nimport { Router } from '@angular/router';\r\n\r\n@Component({\r\n selector: 'app-schedule',\r\n templateUrl: 'schedule.component.html',\r\n styleUrls: ['schedule.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class ScheduleComponent implements OnChanges {\r\n @Input() data: {\r\n title: string;\r\n subtitle: string;\r\n pageId: string;\r\n };\r\n\r\n scheduleElements: {\r\n boxTitle: string;\r\n boxSubtitle: string;\r\n boxPhone: string;\r\n schedule: { cities: string; date: string }[];\r\n };\r\n\r\n url: string;\r\n\r\n constructor(private pageService: PagesService, private cdr: ChangeDetectorRef, private router: Router) {}\r\n\r\n ngOnChanges(changes: SimpleChanges): void {\r\n if (changes.data.currentValue.pageId) {\r\n this.pageService\r\n .getOne(changes.data.currentValue.pageId)\r\n .pipe(\r\n first(),\r\n finalize(() => this.cdr.detectChanges())\r\n )\r\n .subscribe(e => {\r\n this.url = e.data.id.replace(',', '/');\r\n this.scheduleElements = e.data.attributes.content.content;\r\n this.scheduleElements.schedule = this.scheduleElements.schedule.filter(\r\n (item: any, index: number) => index < 4\r\n );\r\n });\r\n }\r\n }\r\n\r\n redirectToMore() {\r\n this.router.navigate([this.url]);\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n\r\n\r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n\r\n\r\n \r\n \r\n \r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n {{ title }}\r\n \r\n \r\n {{ text }}\r\n \r\n \r\n \r\n {{ phone }}\r\n \r\n \r\n\r\n\r\n \r\n {{ item.date }}\r\n {{ item.cities }}\r\n \r\n\r\n","export enum SitemapLoaders {\r\n GetAll = 'GetAll'\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { OverlayComponent } from '@app/template/home/components/overlay/overlay.component';\r\nimport { SearchModule } from '@app/client-core/search/search.module';\r\nimport { PromotedComponent } from '@app/template/home/components/promoted/promoted.component';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { CarouselModule } from '@app/template/elements/carousel/carousel.module';\r\nimport { LogoModule } from '@app/template/layout/modules/logo/logo.module';\r\nimport { TruncateModule } from '@share/modules/truncate/truncate.module';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { RouterModule } from '@angular/router';\r\nimport { SelectModule } from '@share/modules/html/select/select.module';\r\nimport { FormsModule } from '@angular/forms';\r\nimport { NgbCarouselModule, NgbPaginationModule } from '@ng-bootstrap/ng-bootstrap';\r\nimport { HeadingModule } from '@app/template/elements/heading/heading.module';\r\nimport { PromotedModule } from '@app/template/elements/promoted/promoted.module';\r\nimport { PolygonModule } from '@app/template/elements/polygon/polygon.module';\r\nimport { AccordionModule } from '@app/template/elements/accordion/accordion.module';\r\nimport { PaginationModule } from '@app/template/elements/pagination/pagination.module';\r\nimport { MainBannerComponent } from '@app/template/home/components/main-banner/main-banner.component';\r\nimport { ReportCrashComponent } from '@app/template/home/components/report-crash/report-crash.component';\r\nimport { ScheduleComponent } from '@app/template/home/components/schedule/schedule.component';\r\nimport { NewsComponent } from '@app/template/home/components/news/news.component';\r\nimport { GalleryComponent } from '@app/template/home/components/gallery/gallery.component';\r\nimport { SimpleBoxModule } from '@app/template/elements/simple-box/simple-box.module';\r\nimport { ArticleModule } from '@app/client-core/article/article.module';\r\n\r\n@NgModule({\r\n declarations: [\r\n GalleryComponent,\r\n NewsComponent,\r\n ScheduleComponent,\r\n ReportCrashComponent,\r\n MainBannerComponent,\r\n OverlayComponent,\r\n PromotedComponent,\r\n ],\r\n imports: [\r\n CommonModule,\r\n SearchModule,\r\n CarouselModule,\r\n ElementsModule,\r\n LogoModule,\r\n RouterModule,\r\n NgbCarouselModule,\r\n NgbPaginationModule,\r\n PromotedModule,\r\n SelectModule,\r\n FormsModule,\r\n TranslatorModule,\r\n PolygonModule,\r\n TruncateModule,\r\n AccordionModule,\r\n PaginationModule,\r\n HeadingModule,\r\n SimpleBoxModule,\r\n ArticleModule\r\n ],\r\n exports: [OverlayComponent]\r\n})\r\nexport class HomeModule {}\r\n","import { Injectable } from '@angular/core';\r\nimport { BehaviorSubject, Observable } from 'rxjs';\r\nimport { distinctUntilChanged } from 'rxjs/operators';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class HomeService {\r\n private _isHomePreview: BehaviorSubject = new BehaviorSubject(false);\r\n isHomePreview$: Observable = this._isHomePreview.asObservable().pipe(distinctUntilChanged());\r\n\r\n set isHomePreview(value: boolean) {\r\n this._isHomePreview.next(value);\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { ServiceHelper } from '@share/common/helpers/service.helper';\r\nimport { Bundle } from '@app/common/enums/server-bundles.enum';\r\nimport { Observable } from 'rxjs';\r\nimport { ResponseArray } from '@share/common/models/http.model';\r\nimport { API } from '@app/common/constants/api.directories';\r\nimport { Promoted } from '@app/template/elements/promoted/models/promoted.model';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class PromotedService extends ServiceHelper {\r\n constructor() {\r\n super(Bundle.Promoted);\r\n }\r\n\r\n public getList(): Observable> {\r\n return this.getAll(API.PROMOTED.ROOT);\r\n }\r\n}\r\n","import {Injectable} from '@angular/core';\r\nimport {ServiceHelper} from '@share/common/helpers/service.helper';\r\nimport {Bundle} from '@app/common/enums/server-bundles.enum';\r\nimport {Observable} from 'rxjs';\r\nimport {MenuModel} from '@app/client-core/menu/models/menu.model';\r\nimport {ResponseArray} from '@share/common/models/http';\r\nimport {API} from '@app/common/constants/api.directories';\r\nimport { ApiService } from '@app/common/services/api.service';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class SitemapService {\r\n\r\n constructor(private apiService: ApiService) {}\r\n\r\n getInstitutionData(): Observable {\r\n return this.apiService.get('institution');\r\n }\r\n\r\n public getList(): Observable> {\r\n return this.apiService.getAll(API.MENU.SITEMAP);\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { BreadcrumbsService } from '@app/template/layout/modules/header/services/breadcrumbs.service';\r\nimport { SubheaderService } from '@app/template/layout/modules/header/services/subheader.service';\r\nimport { Observable, of } from 'rxjs';\r\nimport { DynamicContentService } from '@app/client-core/dynamic-content/service/dynamic-content.service';\r\nimport { filter, takeUntil } from 'rxjs/operators';\r\nimport { NavigationEnd } from '@angular/router';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { SearchService } from '@app/client-core/search/services/search.service';\r\n\r\n@Component({\r\n selector: 'app-default',\r\n templateUrl: './default.component.html',\r\n styleUrls: ['./default.component.scss']\r\n})\r\nexport class DefaultComponent extends ComponentHelper {\r\n isHome: boolean = true;\r\n backdrop$: Observable;\r\n constructor(\r\n private breadcrumbsService: BreadcrumbsService,\r\n private subheaderService: SubheaderService,\r\n private settings: SettingsService,\r\n private dynamicContentService: DynamicContentService,\r\n private searchService: SearchService\r\n ) {\r\n super();\r\n this.setHome();\r\n this.backdrop$ = searchService.isActive$;\r\n }\r\n\r\n get contentLoaded(): Observable {\r\n return this.dynamicContentService.loaded$;\r\n }\r\n\r\n public deactivate() {\r\n this.breadcrumbsService.clear.next(true);\r\n this.subheaderService.reset();\r\n }\r\n\r\n private setHome() {\r\n this.service.router.events\r\n .pipe(\r\n filter((e): e is NavigationEnd => e instanceof NavigationEnd),\r\n takeUntil(this.destroyed$)\r\n )\r\n .subscribe(event => {\r\n this.isHome = event.url === '/';\r\n });\r\n }\r\n\r\n get canShow(): Observable {\r\n if (this.isHome) {\r\n return this.contentLoaded;\r\n }\r\n return of(true);\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { DefaultComponent } from './components/default/default.component';\r\nimport { HeaderModule } from '@app/template/layout/modules/header/header.module';\r\nimport { FooterModule } from '@app/template/layout/modules/footer/footer.module';\r\nimport { CookiesModule } from '@app/client-core/cookies/cookies.module';\r\nimport { DynamicContentModule } from '@app/client-core/dynamic-content/dynamic-content.module';\r\nimport { AppRoutingModule } from '@app/app-routing.module';\r\nimport { HomeModule } from '@app/template/home/home.module';\r\nimport { SiteMapModule } from '@app/template/layout/modules/sitemap/sitemap.module';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { PolygonModule } from '@app/template/elements/polygon/polygon.module';\r\n\r\n@NgModule({\r\n declarations: [DefaultComponent],\r\n imports: [\r\n CommonModule,\r\n HeaderModule,\r\n HomeModule,\r\n FooterModule,\r\n CookiesModule,\r\n DynamicContentModule,\r\n SiteMapModule,\r\n AppRoutingModule,\r\n ElementsModule,\r\n PolygonModule\r\n ]\r\n})\r\nexport class LayoutModule {}\r\n","import { NgModule } from '@angular/core';\r\nimport { BreadcrumbsComponent } from '@app/template/layout/modules/breadcrumbs/components/breadcrumbs/breadcrumbs.component';\r\nimport { CommonModule } from '@angular/common';\r\nimport { RouterModule } from '@angular/router';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\n\r\n@NgModule({\r\n declarations: [\r\n BreadcrumbsComponent\r\n ],\r\n imports: [\r\n CommonModule,\r\n RouterModule,\r\n TranslatorModule\r\n ],\r\n exports: [\r\n BreadcrumbsComponent\r\n ]\r\n})\r\nexport class BreadcrumbsModule {}\r\n","import { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { ChangeDetectorRef, Component, EventEmitter, OnInit, Output } from '@angular/core';\r\nimport { BreadcrumbsService } from '@app/template/layout/modules/header/services/breadcrumbs.service';\r\nimport { BreadcrumbsLoaders } from '@app/template/layout/modules/header/enums/breadcrumbs-loaders.enum';\r\nimport { Breadcrumbs } from '@app/template/layout/modules/header/models/breadcrumbs.model';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { AbstractData } from '@share/common/models/http';\r\n\r\n@Component({\r\n selector: 'app-breadcrumbs',\r\n templateUrl: './breadcrumbs.component.html',\r\n styleUrls: ['./breadcrumbs.component.scss']\r\n})\r\nexport class BreadcrumbsComponent extends ComponentHelper implements OnInit {\r\n public breadcrumbs: Array> = [];\r\n public shortVersion: boolean = false;\r\n public minLengthForShortVersion: number = 3;\r\n\r\n @Output() readonly loaded: EventEmitter = new EventEmitter();\r\n\r\n constructor(private breadcrumbsService: BreadcrumbsService, private cdr: ChangeDetectorRef) {\r\n super();\r\n }\r\n\r\n public get breadcrumbsExists(): boolean {\r\n return Array.isArray(this.breadcrumbs) && this.breadcrumbs.length > 0;\r\n }\r\n\r\n public ngOnInit() {\r\n this.setReloadListener();\r\n this.setClearListener();\r\n }\r\n\r\n private loadBreadcrumbs() {\r\n this.setLoader(BreadcrumbsLoaders.Get, true);\r\n this.subscriptions.add(\r\n this.breadcrumbsService.getList(this.url).subscribe(\r\n response => {\r\n this.breadcrumbs = this.getResponseData(response);\r\n this.shortVersion = this.breadcrumbs.length > this.minLengthForShortVersion;\r\n this.cdr.detectChanges();\r\n this.loaded.emit();\r\n },\r\n () => {}\r\n )\r\n );\r\n }\r\n\r\n private setReloadListener() {\r\n this.breadcrumbsService.reload.pipe(takeUntil(this.destroyed$)).subscribe(reload => {\r\n if (reload && !this.breadcrumbsService.forceActive) {\r\n this.breadcrumbsService.customBreadcrumbs = [];\r\n this.loadBreadcrumbs();\r\n this.cdr.detectChanges();\r\n }\r\n });\r\n }\r\n\r\n private setClearListener() {\r\n this.breadcrumbsService.clear.pipe(takeUntil(this.destroyed$)).subscribe(clear => {\r\n if (clear) {\r\n this.breadcrumbs = [];\r\n this.cdr.detectChanges();\r\n this.breadcrumbsService.clear.next(false);\r\n }\r\n });\r\n }\r\n\r\n public get customBreadcrumbs(): Array<{ title: string; url?: string }> {\r\n return this.breadcrumbsService.customBreadcrumbs;\r\n }\r\n\r\n private get url(): string {\r\n return this.breadcrumbsService.getParsedUrl(this.service.router.url);\r\n }\r\n\r\n public getLink(index: number): Array {\r\n const segments = this.breadcrumbsService.generateLink(this.breadcrumbs, index);\r\n\r\n if (segments.length > 1) {\r\n return [...segments];\r\n }\r\n\r\n return ['/'];\r\n }\r\n\r\n public expandBreadcrumbs(event: Event) {\r\n event.preventDefault();\r\n this.shortVersion = false;\r\n this.cdr.detectChanges();\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n {{breadcrumb.attributes.title}}\r\n {{breadcrumb.attributes.title}}\r\n \r\n \r\n {{breadcrumb.attributes.title}}\r\n \r\n \r\n \r\n \r\n \r\n {{breadcrumbs[0].attributes.title}}\r\n {{breadcrumbs[0].attributes.title}}\r\n \r\n \r\n {{'...'}}\r\n \r\n {{breadcrumbs[breadcrumbs.length - 1].attributes.title}}\r\n \r\n \r\n\r\n\r\n 0\">\r\n \r\n \r\n \r\n \r\n {{customBreadcrumb.title}}\r\n \r\n \r\n {{customBreadcrumb.title}}\r\n \r\n \r\n \r\n \r\n \r\n\r\n","import {Component, Input, OnInit} from '@angular/core';\r\n\r\n@Component({\r\n selector: 'app-container',\r\n templateUrl: './container.component.html',\r\n styles: []\r\n})\r\nexport class ContainerComponent implements OnInit {\r\n\r\n @Input() public top: number = 30;\r\n @Input() public bottom: number = 30;\r\n @Input() public left: number = 0;\r\n @Input() public right: number = 0;\r\n\r\n constructor() { }\r\n\r\n ngOnInit() {\r\n }\r\n\r\n}\r\n","\r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport {ContainerComponent} from '@app/template/layout/modules/container/components/container/container.component';\r\n\r\n@NgModule({\r\n declarations: [\r\n ContainerComponent\r\n ],\r\n imports: [\r\n CommonModule\r\n ],\r\n exports: [\r\n ContainerComponent\r\n ]\r\n})\r\nexport class ContainerModule { }\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\n\r\n@Component({\r\n selector: 'app-fatal-error',\r\n templateUrl: './fatal-error.component.html',\r\n styleUrls: ['./fatal-error.component.scss']\r\n})\r\nexport class FatalErrorComponent extends ComponentHelper implements OnInit {\r\n\r\n constructor() {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n }\r\n\r\n goToHome(): void {\r\n window.location.href = '/';\r\n }\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n {{ '500' }}\r\n {{ 'Błąd serwera' }}\r\n \r\n \r\n \r\n \r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\n\r\n@Component({\r\n selector: 'app-maintenance',\r\n templateUrl: './maintenance.component.html',\r\n styleUrls: ['./maintenance.component.scss']\r\n})\r\nexport class MaintenanceComponent extends ComponentHelper implements OnInit {\r\n\r\n constructor() {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n }\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n {{'global.maintenance' | trans}}\r\n {{'global.maintenanceText' | trans}}.\r\n \r\n \r\n\r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\n\r\n@Component({\r\n selector: 'app-not-found',\r\n templateUrl: './not-found.component.html',\r\n styleUrls: ['./not-found.component.scss']\r\n})\r\nexport class NotFoundComponent extends ComponentHelper implements OnInit {\r\n\r\n constructor() {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n }\r\n\r\n goToHome(): void {\r\n this.service.router.navigate(['']);\r\n }\r\n\r\n}\r\n","\r\n \r\n \r\n {{ '404' }}\r\n {{ 'Nie znaleziono strony' }}\r\n \r\n \r\n \r\n\r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { NotFoundComponent } from './components/not-found/not-found.component';\r\nimport { RouterModule } from '@angular/router';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { MaintenanceComponent } from './components/maintenance/maintenance.component';\r\nimport { FatalErrorComponent } from './components/fatal-error/fatal-error.component';\r\n\r\n@NgModule({\r\n declarations: [NotFoundComponent, MaintenanceComponent, FatalErrorComponent],\r\n imports: [\r\n CommonModule,\r\n RouterModule,\r\n ElementsModule,\r\n TranslatorModule\r\n ],\r\n exports: [\r\n NotFoundComponent,\r\n MaintenanceComponent\r\n ]\r\n})\r\nexport class ErrorPagesModule {\r\n}\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { VersionService } from '@share/common/services/version.service';\r\n\r\n@Component({\r\n selector: 'app-footer',\r\n templateUrl: './footer.component.html',\r\n styleUrls: ['./footer.component.scss']\r\n})\r\nexport class FooterComponent extends ComponentHelper implements OnInit {\r\n public footer: string;\r\n public version: string;\r\n\r\n constructor(private settingsService: SettingsService, private versionService: VersionService) {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n this.footer = this.settingsService.variables.footer.footer;\r\n }\r\n}\r\n","\r\n","import {NgModule} from '@angular/core';\r\nimport {CommonModule} from '@angular/common';\r\nimport {FooterComponent} from './components/footer/footer.component';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\n\r\n@NgModule({\r\n declarations: [FooterComponent],\r\n imports: [\r\n CommonModule,\r\n TranslatorModule,\r\n ElementsModule\r\n ],\r\n exports: [\r\n FooterComponent\r\n ]\r\n})\r\nexport class FooterModule {\r\n}\r\n","import { ChangeDetectionStrategy, Component } from '@angular/core';\r\n\r\ndeclare let $: any;\r\n\r\n@Component({\r\n selector: 'app-a11y-font-size',\r\n styleUrls: ['a11y-font-size.component.scss'],\r\n templateUrl: 'a11y-font-size.component.html',\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class A11yFontSizeComponent {\r\n constructor() {}\r\n\r\n setDefaultFontSize() {\r\n this.changeFontSize('10px');\r\n }\r\n setBiggerFontSize() {\r\n this.changeFontSize('11px');\r\n }\r\n setBigFontSize() {\r\n this.changeFontSize('12px');\r\n }\r\n\r\n private changeFontSize(size: string) {\r\n $('html').css({\r\n 'font-size': size\r\n });\r\n }\r\n}\r\n","\r\n \r\n \r\n domyślna czcionka\r\n A\r\n \r\n \r\n \r\n \r\n większa czcionka\r\n A\r\n \r\n \r\n \r\n \r\n największa czcionka\r\n A\r\n \r\n \r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { GoogleTranslateService } from '@app/common/services/google-translate.service';\r\n\r\n@Component({\r\n selector: 'app-google-translator',\r\n templateUrl: './google-translator.component.html',\r\n styleUrls: [\r\n './google-translator.component.scss'\r\n ]\r\n})\r\nexport class GoogleTranslatorComponent implements OnInit {\r\n\r\n constructor(private googleTranslateService: GoogleTranslateService) {}\r\n\r\n public ngOnInit() {\r\n this.googleTranslateService.init();\r\n }\r\n\r\n}\r\n","\r\n","import { AfterViewInit, Component, ElementRef, Inject, OnInit, ViewChild, ViewContainerRef } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { DOCUMENT } from '@angular/common';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { LazyLoaderService } from '@app/common/services/lazy-loader.service';\r\nimport { ThemesEnum } from '@app/common/models/themes.enum';\r\nimport { ResizeListener } from '@app/common/services/resize-listener.service';\r\nimport { SearchService } from '@app/client-core/search/services/search.service';\r\nimport { fromEvent, Observable } from 'rxjs';\r\nimport { MenuService } from '@app/client-core/menu/services/menu.service';\r\nimport { debounceTime, filter, finalize, first, takeUntil, tap } from 'rxjs/operators';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { MenuModel } from '@app/client-core/menu/models/menu.model';\r\n\r\ndeclare let $: Function;\r\n\r\n@Component({\r\n selector: 'app-header',\r\n templateUrl: './header-container.component.html',\r\n styleUrls: [\r\n './header-container.component.scss',\r\n './header-container-contrast.component.scss',\r\n ]\r\n})\r\nexport class HeaderContainerComponent extends ComponentHelper implements OnInit, AfterViewInit {\r\n isAuthenticated: boolean = false;\r\n search: string;\r\n\r\n @ViewChild('alertBtn', { read: ViewContainerRef }) alertBtn: ViewContainerRef;\r\n @ViewChild('menu', { read: ViewContainerRef }) menu: ViewContainerRef;\r\n\r\n private startDistance = 10;\r\n\r\n isMobileSearchActive$: Observable;\r\n isValidDefaultMenuWidth: boolean;\r\n isMobileMenuMode: boolean;\r\n isDefaultMenuWidthChecking: boolean;\r\n isFetchMenuLoading: boolean;\r\n menuData: AbstractData[];\r\n\r\n constructor(\r\n @Inject(DOCUMENT) private document: Document,\r\n private settings: SettingsService,\r\n private loader: LazyLoaderService,\r\n public resizeListener: ResizeListener,\r\n private searchService: SearchService,\r\n private menuService: MenuService,\r\n private _elementRef: ElementRef\r\n ) {\r\n super();\r\n }\r\n\r\n get isSubpage(): boolean {\r\n return !this.service.router.isActive('', true);\r\n }\r\n\r\n get isAlertModuleEnabled(): boolean {\r\n return this.settings.isModuleActive(ThemesEnum.ALERT);\r\n }\r\n\r\n get isMenuModuleEnabled(): boolean {\r\n return this.settings.isModuleActive(ThemesEnum.MENU);\r\n }\r\n\r\n /** Metoda sprawdzająca, czy zawartość menu dla desktop'ów nie wystaje poza szerokość okna/headera. */\r\n get isValidHeaderContentWidth(): boolean {\r\n const contentElementRef: HTMLElement = this.document.querySelector('#main-app-header .content') as HTMLElement;\r\n const contentElementChildren: HTMLElement[] = Array.from(contentElementRef.children) as HTMLElement[];\r\n const contentElementAvailableWidth: number = contentElementRef.offsetWidth\r\n - (parseInt(getComputedStyle(contentElementRef).paddingLeft))\r\n - (parseInt(getComputedStyle(contentElementRef).paddingRight))\r\n - 30 // ScrollBar with small offset.\r\n ;\r\n\r\n let contentChildrenWidth: number = 0;\r\n\r\n contentElementChildren.forEach(child => {\r\n contentChildrenWidth += child.offsetWidth;\r\n });\r\n\r\n return contentChildrenWidth <= contentElementAvailableWidth\r\n }\r\n\r\n ngOnInit() {\r\n this.fetchMenu();\r\n window.addEventListener('scroll', () => this.scroll(), true);\r\n this.scroll();\r\n this.isMobileSearchActive$ = this.searchService.isActive$;\r\n this.searchService.isActive$.pipe(takeUntil(this.destroyed$)).subscribe(isActive => {\r\n if (isActive) {\r\n this.menuService.isMobileMenuActive$.next(false);\r\n }\r\n });\r\n this.handleOutsideClick();\r\n }\r\n\r\n ngAfterViewInit() {\r\n this.generateAlertButton();\r\n this.generateMenu();\r\n }\r\n\r\n private setMenuModeChangeListener() {\r\n this.resizeListener.isMobile$.pipe(\r\n takeUntil(this.destroyed$),\r\n tap((value) => this.isMobileMenuMode = value),\r\n filter((value) => !value),\r\n tap(() => {\r\n this.isDefaultMenuWidthChecking = true;\r\n this.isValidDefaultMenuWidth = true; // Pokazanie menu, aby JS mógł obliczyć szerokość wewnątrz komponentu.\r\n }),\r\n debounceTime(500),\r\n ).subscribe((value) => {\r\n this.setIsMobileMenuMode();\r\n });\r\n }\r\n\r\n private fetchMenu() {\r\n this.isFetchMenuLoading = true;\r\n\r\n this.menuService\r\n .getList()\r\n .pipe(\r\n first(),\r\n finalize(() => this.isFetchMenuLoading = false)\r\n )\r\n .subscribe(\r\n response => {\r\n this.menuData = response.data;\r\n this.setMenuModeChangeListener();\r\n }\r\n );\r\n }\r\n\r\n private setIsMobileMenuMode(): void {\r\n // setTimeout z racji wymaganego opóźnienia przy obliczaniu dostępnej szerokosci.\r\n setTimeout(() => {\r\n this.isValidDefaultMenuWidth = this.isValidHeaderContentWidth;\r\n });\r\n\r\n this.isDefaultMenuWidthChecking = false;\r\n }\r\n\r\n generateAlertButton() {\r\n if (this.alertBtn && this.isAlertModuleEnabled) {\r\n this.loader.load(ThemesEnum.ALERT, this.alertBtn);\r\n }\r\n }\r\n\r\n generateMenu() {\r\n if (this.menu) {\r\n this.menu?.clear();\r\n if (this.isMenuModuleEnabled || this.isAuthenticated) {\r\n this.loader.load(ThemesEnum.MENU, this.menu);\r\n }\r\n }\r\n }\r\n\r\n handleOutsideClick() {\r\n const clickEvent$ = fromEvent(document, 'click');\r\n clickEvent$\r\n .pipe(\r\n takeUntil(this.destroyed$),\r\n filter(e => !this._elementRef.nativeElement.contains(e.target)),\r\n tap(e => {\r\n this.searchService.isActive$.next(false);\r\n })\r\n )\r\n .subscribe();\r\n }\r\n\r\n\r\n private scroll() {\r\n const scrollTop = $(this.document).scrollTop(),\r\n header = $('header');\r\n if (scrollTop >= this.startDistance) {\r\n header.addClass('sticked');\r\n } else {\r\n header.removeClass('sticked');\r\n }\r\n }\r\n\r\n onComponentRefresh() {\r\n this.fetchMenu();\r\n }\r\n}\r\n","\r\n Dolina baryczy\r\n \r\n \r\n \r\n {{ 'global.search' | trans }}\r\n \r\n \r\n \r\n {{ 'global.settings' | trans }}\r\n \r\n \r\n \r\n {{'global.contrast' | trans}}\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { AfterViewInit, Component, OnInit, Renderer2 } from '@angular/core';\r\n\r\ndeclare let $: Function;\r\n\r\n@Component({\r\n selector: 'app-high-contrast',\r\n templateUrl: './high-contrast.component.html',\r\n styleUrls: ['./high-contrast.component.scss']\r\n})\r\nexport class HighContrastComponent implements OnInit, AfterViewInit {\r\n constructor(private renderer: Renderer2) {}\r\n\r\n ngOnInit(): void {}\r\n\r\n ngAfterViewInit(): void {\r\n const contrast: string = localStorage.getItem('contrast') as string;\r\n if (contrast) {\r\n switch (contrast) {\r\n case 'blackwhite':\r\n this.addBlackWhite();\r\n break;\r\n case 'yellowblack':\r\n this.addYellowBlack();\r\n break;\r\n }\r\n }\r\n }\r\n\r\n removeContrast() {\r\n this.renderer.removeClass(document.body, localStorage.getItem('contrast') as string);\r\n this.renderer.setStyle(document.body, 'color', '');\r\n this.renderer.setStyle(document.body, 'background-color', '');\r\n\r\n localStorage.setItem('contrast', 'normal');\r\n }\r\n\r\n addYellowBlack() {\r\n this.removeContrast();\r\n this.renderer.addClass(document.body, 'yellowblack');\r\n\r\n this.renderer.setStyle(document.body, 'background-color', 'black');\r\n this.renderer.setStyle(document.body, 'color', 'yellow');\r\n\r\n localStorage.setItem('contrast', 'yellowblack');\r\n }\r\n\r\n addBlackWhite() {\r\n this.removeContrast();\r\n this.renderer.addClass(document.body, 'blackwhite');\r\n\r\n this.renderer.setStyle(document.body, 'background-color', 'white');\r\n this.renderer.setStyle(document.body, 'color', 'black');\r\n\r\n localStorage.setItem('contrast', 'blackwhite');\r\n }\r\n}\r\n","\r\n \r\n \r\n brak wysokiego kontrastu\r\n A\r\n \r\n \r\n \r\n \r\n czarno-biały\r\n A\r\n \r\n \r\n \r\n \r\n żółto-czarny\r\n A\r\n \r\n \r\n\r\n","export { SubheaderDescriptionComponent } from './subheader/subheader-description/subheader-description.component';\r\nexport { SubheaderTitleComponent } from './subheader/subheader-title/subheader-title.component';\r\nexport { SubheaderComponent } from './subheader/subheader.component';\r\nexport { GoogleTranslatorComponent } from './google-translator/google-translator.component';\r\nexport { HeaderContainerComponent } from './header-container/header-container.component';\r\nexport { LanguageComponent } from './language/language.component';\r\nexport { A11yFontSizeComponent } from './a11y-font-size/a11y-font-size.component';\r\n","import {ComponentHelper} from '@app/common/helpers/component.helper';\r\nimport {Component, ViewEncapsulation} from '@angular/core';\r\n\r\n@Component({\r\n selector: 'app-language',\r\n templateUrl: './language.component.html',\r\n styleUrls: ['./language.component.scss'],\r\n})\r\nexport class LanguageComponent extends ComponentHelper {\r\n\r\n public language: string = 'pl';\r\n\r\n constructor() {\r\n super();\r\n }\r\n\r\n changeLanguage(): void {\r\n alert('TODO');\r\n }\r\n}\r\n","\r\n","import { Component, Input } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'cms-subheader-description',\r\n templateUrl: 'subheader-description.component.html',\r\n styleUrls: ['subheader-description.component.scss']\r\n})\r\nexport class SubheaderDescriptionComponent {\r\n @Input() text: string;\r\n @Input() isMobile: boolean;\r\n}\r\n","{{text}}\r\n","import { Component, ElementRef, EventEmitter, Input, Output, ViewChild } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'cms-subheader-title',\r\n templateUrl: 'subheader-title.component.html',\r\n styleUrls: ['subheader-title.component.scss']\r\n})\r\nexport class SubheaderTitleComponent {\r\n\r\n isEditable: boolean = false;\r\n\r\n @Input() title: string;\r\n @Input() isMobile: boolean;\r\n @Input() set editable(editable: boolean) {\r\n this.isEditable = editable;\r\n setTimeout(() => this.text.nativeElement.focus());\r\n };\r\n\r\n @ViewChild('text') text: ElementRef;\r\n\r\n @Output() onSubmitEditable: EventEmitter = new EventEmitter();\r\n\r\n onSubmit() {\r\n this.isEditable = false;\r\n this.onSubmitEditable.emit(this.text.nativeElement.innerText);\r\n }\r\n\r\n}\r\n","{{ title }}\r\n","import { AfterViewInit, Component, Injector } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { SubheaderConfig } from '@app/template/layout/modules/header/interfaces/subheader-config.interface';\r\nimport { BreadcrumbsService } from '@app/template/layout/modules/header/services/breadcrumbs.service';\r\nimport { NavigationEnd } from '@angular/router';\r\nimport { filter, takeUntil } from 'rxjs/operators';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { DynamicContentService } from '@app/client-core/dynamic-content/service/dynamic-content.service';\r\nimport { Observable } from 'rxjs';\r\nimport { HomeService } from '@app/template/home/services/home.service';\r\n\r\n@Component({\r\n selector: 'app-subheader',\r\n templateUrl: './subheader.component.html',\r\n styleUrls: ['./subheader.component.scss']\r\n})\r\nexport class SubheaderComponent extends ComponentHelper implements AfterViewInit {\r\n active: boolean = false;\r\n isHome: boolean = false;\r\n\r\n constructor(\r\n private breadcrumbsService: BreadcrumbsService,\r\n private settings: SettingsService,\r\n private dynamicContentService: DynamicContentService,\r\n private homeService: HomeService\r\n ) {\r\n super();\r\n this.setHome();\r\n }\r\n\r\n get contentLoaded(): Observable {\r\n return this.dynamicContentService.loaded$;\r\n }\r\n\r\n get isHomePreview(): Observable {\r\n return this.homeService.isHomePreview$;\r\n }\r\n\r\n private setHome() {\r\n this.service.router.events\r\n .pipe(\r\n filter((e): e is NavigationEnd => e instanceof NavigationEnd),\r\n takeUntil(this.destroyed$)\r\n )\r\n .subscribe(event => {\r\n this.isHome = event.url === '/';\r\n });\r\n }\r\n\r\n get component() {\r\n return this.service.subheader.config.component;\r\n }\r\n\r\n get config(): SubheaderConfig {\r\n return this.service.subheader.config;\r\n }\r\n\r\n get myInjector(): Injector | null | undefined {\r\n return this.service.subheader.config.injector;\r\n }\r\n\r\n get displayBreadcrumbs() {\r\n return this.service.subheader.config.displayBreadcrumbs;\r\n }\r\n\r\n get forceShow() {\r\n return this.service.subheader.config.forceShow;\r\n }\r\n\r\n get categories(): { title: string; slug: string }[] | undefined {\r\n return this.service.subheader.config.categories;\r\n }\r\n\r\n get publishedDate(): string | undefined {\r\n return this.service.subheader.config.publishedDate;\r\n }\r\n\r\n get image(): string | undefined {\r\n return this.service.subheader.config.image;\r\n }\r\n\r\n get hideDots(): boolean {\r\n return this.service.subheader.config.hideDots || false;\r\n }\r\n\r\n ngAfterViewInit(): void {\r\n this.breadcrumbsService.reload.next(true);\r\n }\r\n\r\n isArray(categories: { title: string; slug: string }[] | string | undefined): boolean {\r\n return Array.isArray(categories);\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n {{ category.attributes.title }}\r\n \r\n \r\n {{ publishedDate | date: 'shortDate':'':'pl' }}\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","export enum BreadcrumbsLoaders {\r\n Get = 'Get'\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { WcagModule } from '@share/modules/wcag/wcag.module';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { LogoModule } from '@app/template/layout/modules/logo/logo.module';\r\nimport { SearchModule } from '@app/client-core/search/search.module';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { RouterModule } from '@angular/router';\r\nimport {\r\n A11yFontSizeComponent,\r\n GoogleTranslatorComponent,\r\n HeaderContainerComponent,\r\n LanguageComponent,\r\n SubheaderComponent,\r\n SubheaderDescriptionComponent,\r\n SubheaderTitleComponent\r\n} from './components';\r\nimport { BreadcrumbsModule } from '@app/template/layout/modules/breadcrumbs/breadcrumbs.module';\r\nimport { HttpClientModule } from '@angular/common/http';\r\nimport { MenuModule } from '@app/client-core/menu/menu.module';\r\nimport { InputModule } from '@share/modules/html/input/input.module';\r\nimport { FormsModule } from '@angular/forms';\r\nimport { HighContrastComponent } from './components/high-contrast/high-contrast.component';\r\n\r\n@NgModule({\r\n declarations: [\r\n LanguageComponent,\r\n SubheaderTitleComponent,\r\n SubheaderDescriptionComponent,\r\n GoogleTranslatorComponent,\r\n HeaderContainerComponent,\r\n SubheaderComponent,\r\n A11yFontSizeComponent,\r\n HighContrastComponent\r\n ],\r\n imports: [\r\n CommonModule,\r\n WcagModule,\r\n LogoModule,\r\n ElementsModule,\r\n HttpClientModule,\r\n SearchModule,\r\n ElementsModule,\r\n TranslatorModule,\r\n RouterModule,\r\n BreadcrumbsModule,\r\n MenuModule,\r\n InputModule,\r\n FormsModule\r\n ],\r\n exports: [HeaderContainerComponent, SubheaderComponent, SubheaderTitleComponent, SubheaderDescriptionComponent]\r\n})\r\nexport class HeaderModule {}\r\n","import { ReplaySubject } from 'rxjs';\r\nimport { Injector } from '@angular/core';\r\n\r\nexport interface SubheaderConfig {\r\n title: string;\r\n description: string;\r\n displayHeader: boolean;\r\n displayBreadcrumbs: ReplaySubject;\r\n searchOpen: boolean;\r\n searchType: SearchType;\r\n component: any;\r\n categories?: { slug: string; title: string }[];\r\n hideSearch: boolean;\r\n injector?: Injector | null;\r\n forceShow: boolean;\r\n publishedDate?: string;\r\n image?: string;\r\n hideDots?: boolean\r\n}\r\n\r\nexport enum SearchType {\r\n Default = '',\r\n EServices = 'eservice',\r\n None = ''\r\n}\r\n\r\nexport enum SearchTypeNames {\r\n Default = 'Wszędzie',\r\n EServices = 'Katalog e-usług'\r\n}\r\n","import { ServiceHelper } from '@share/common/helpers/service.helper';\r\nimport { Bundle } from '@app/common/enums/server-bundles.enum';\r\nimport { Injectable } from '@angular/core';\r\nimport { BehaviorSubject, Observable } from 'rxjs';\r\nimport { AbstractData, ResponseArray } from '@share/common/models/http';\r\nimport { Breadcrumbs } from '@app/template/layout/modules/header/models/breadcrumbs.model';\r\nimport { API } from '@app/common/constants/api.directories';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class BreadcrumbsService extends ServiceHelper {\r\n reload: BehaviorSubject = new BehaviorSubject(false);\r\n clear: BehaviorSubject = new BehaviorSubject(false);\r\n customBreadcrumbs: Array<{ title: string; url?: string }> = [];\r\n forceActive = false;\r\n\r\n constructor() {\r\n super(Bundle.Breadcrumbs);\r\n }\r\n\r\n public getList(url: string): Observable> {\r\n return this.getAll(`${API.COMMON.BREADCRUMBS}/,${url}`);\r\n }\r\n\r\n public getParsedUrl(url: string): string {\r\n return url.substr(1, url.length).split('/').join(',');\r\n }\r\n\r\n public generateLink(breadcrumbs: Array>, index: number): Array {\r\n let path: Array = [];\r\n try {\r\n for (let i = 0; i < (index + 1); i++) {\r\n path.push(breadcrumbs[i].attributes.url);\r\n }\r\n } catch (_ignore) {\r\n path = [];\r\n }\r\n return path;\r\n }\r\n\r\n public reset() {\r\n this.reload.next(true);\r\n }\r\n}\r\n","import { Injectable, Injector } from '@angular/core';\r\nimport { BehaviorSubject, Observable, ReplaySubject } from 'rxjs';\r\nimport { SearchType, SubheaderConfig } from '@app/template/layout/modules/header/interfaces/subheader-config.interface';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class SubheaderService {\r\n private _config: BehaviorSubject;\r\n\r\n constructor() {\r\n this._config = new BehaviorSubject(this.default);\r\n }\r\n\r\n private get default(): SubheaderConfig {\r\n return {\r\n title: '',\r\n description: '',\r\n searchType: SearchType.None,\r\n component: null,\r\n displayHeader: true,\r\n displayBreadcrumbs: new ReplaySubject(1),\r\n searchOpen: false,\r\n hideSearch: false,\r\n injector: null,\r\n forceShow: false,\r\n categories: [],\r\n hideDots: false\r\n };\r\n }\r\n\r\n public get config(): SubheaderConfig {\r\n return this._config.getValue();\r\n }\r\n\r\n public getConfig(): Observable> {\r\n return this._config.asObservable();\r\n }\r\n\r\n public setConfig(value: Partial) {\r\n this._config.next({ ...this.default, ...value });\r\n }\r\n\r\n public set title(title: string) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n title\r\n });\r\n }\r\n\r\n public set description(description: string) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n description\r\n });\r\n }\r\n\r\n public set searchType(searchType: SearchType) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n searchType\r\n });\r\n }\r\n\r\n public set searchOpen(searchOpen: boolean) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n searchOpen\r\n });\r\n }\r\n\r\n public set injector(injector: Injector) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n injector\r\n });\r\n }\r\n\r\n public set forceShow(forceShow: boolean) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n forceShow\r\n });\r\n }\r\n\r\n public set displayBreadcrumbs(show: boolean) {\r\n this.config.displayBreadcrumbs.next(show);\r\n }\r\n\r\n set categories(categories: { slug: string; title: string }[]) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n categories\r\n });\r\n }\r\n\r\n set publishedDate(publishedDate: string) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n publishedDate\r\n });\r\n }\r\n\r\n set image(image: string) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n image\r\n });\r\n }\r\n\r\n set hideDots(hideDots: boolean) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n hideDots\r\n });\r\n }\r\n\r\n public reset() {\r\n this.setConfig(this.default);\r\n }\r\n}\r\n","import { Component, Input, OnDestroy, OnInit } from '@angular/core';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { Subject } from 'rxjs';\r\n\r\n@Component({\r\n selector: 'app-logo',\r\n templateUrl: './logo.component.html',\r\n styleUrls: ['./logo.component.scss']\r\n})\r\nexport class LogoComponent implements OnInit, OnDestroy {\r\n private destroy$: Subject = new Subject();\r\n url: string;\r\n\r\n @Input() id: string = 'logo';\r\n @Input() isAlt: boolean;\r\n @Input() preventChange: boolean;\r\n\r\n constructor(private layoutService: SettingsService) {}\r\n\r\n ngOnInit() {\r\n if (this.isAlt) {\r\n this.url = this.layoutService.variables.site.altLogo;\r\n } else {\r\n this.url = this.layoutService.variables.site.logo;\r\n }\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.destroy$.next(true);\r\n this.destroy$.complete();\r\n }\r\n}\r\n","\r\n Strona główna\r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { LogoComponent } from '@app/template/layout/modules/logo/components/logo/logo.component';\r\nimport { RouterModule } from '@angular/router';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n RouterModule,\r\n TranslatorModule\r\n ],\r\n declarations: [\r\n LogoComponent\r\n ],\r\n exports: [\r\n LogoComponent\r\n ]\r\n})\r\nexport class LogoModule {}\r\n","import { Component, ElementRef, Input, OnDestroy, OnInit, Renderer2 } from '@angular/core';\r\nimport { AbstractData } from '@share/common/models/http.model';\r\nimport { MenuModel } from '@app/client-core/menu/models/menu.model';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\n\r\n@Component({\r\n selector: 'app-sitemap-item',\r\n templateUrl: './sitemap-item.component.html',\r\n styleUrls: [\r\n './sitemap-item.component.scss'\r\n ]\r\n})\r\nexport class SitemapItemComponent extends ComponentHelper implements OnInit, OnDestroy {\r\n @Input() item: AbstractData;\r\n public listenClickFunc: Function;\r\n\r\n constructor(private renderer: Renderer2,\r\n private _elementRef: ElementRef) {\r\n super();\r\n }\r\n\r\n public ngOnInit() {\r\n this.onClickListener();\r\n }\r\n\r\n public openInNewTab(event: Event, url: string) {\r\n event.preventDefault();\r\n event.stopPropagation();\r\n window.open(url);\r\n }\r\n\r\n private onClickListener() {\r\n this.listenClickFunc = this.renderer.listen(\r\n this._elementRef.nativeElement, 'click', (event) => this.service.utils.navigateTo(event)\r\n );\r\n }\r\n\r\n public ngOnDestroy() {\r\n this.listenClickFunc();\r\n }\r\n}\r\n","{{item.attributes.title}}\r\n\r\n \r\n {{subitem.attributes.title}}\r\n \r\n {{subitem.attributes.title}}\r\n \r\n \r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { SitemapService } from '@app/template/home/services/sitemap.service';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { MenuModel } from '@app/client-core/menu/models/menu.model';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { SitemapLoaders } from '@app/template/home/enums/sitemap-loaders.enum';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { finalize, first } from 'rxjs/operators';\r\nimport { InstitutionModel } from '@app/template/layout/modules/sitemap/models/institution.model';\r\n\r\n@Component({\r\n selector: 'app-sitemap',\r\n templateUrl: './sitemap.component.html',\r\n styleUrls: ['./sitemap.component.scss']\r\n})\r\nexport class SitemapComponent extends ComponentHelper implements OnInit {\r\n sitemap: Array> = [];\r\n SitemapLoaders = SitemapLoaders;\r\n description: string;\r\n institution: AbstractData;\r\n constructor(private sitemapService: SitemapService, private settingService: SettingsService) {\r\n super();\r\n }\r\n\r\n public ngOnInit() {\r\n this.loadSitemap();\r\n this.getInstitutionData();\r\n }\r\n\r\n getInstitutionData() {\r\n this.sitemapService\r\n .getInstitutionData()\r\n .pipe(first())\r\n .subscribe(response => (this.institution = response.data));\r\n }\r\n\r\n public loadSitemap() {\r\n this.setLoader(SitemapLoaders.GetAll, true);\r\n this.sitemapService\r\n .getList()\r\n .pipe(\r\n first(),\r\n finalize(() => this.setLoader(SitemapLoaders.GetAll, false))\r\n )\r\n .subscribe(\r\n response => (this.sitemap = this.getResponseData(response)),\r\n () => this.setComponentError()\r\n );\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n {{institution?.attributes?.name}}\r\n \r\n \r\n \r\n {{ institution?.attributes?.address?.zipCode }} {{ institution?.attributes?.address?.city }}\r\n ul. {{ institution?.attributes?.address?.street }} {{ institution?.attributes?.address?.houseNumber }}\r\n {{\r\n institution?.attributes?.address?.apartmentNumber\r\n ? '/' + institution?.attributes?.address?.apartmentNumber\r\n : ''\r\n }}\r\n \r\n \r\n \r\n \r\n \r\n {{ institution?.attributes?.contact?.phoneNumber }}\r\n \r\n \r\n \r\n {{ institution?.attributes?.contact?.phoneNumberSecondary }}\r\n \r\n \r\n \r\n {{ institution?.attributes?.contact?.fax }}\r\n \r\n \r\n \r\n {{ institution?.attributes?.contact?.email }}\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n 0\">\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { LogoModule } from '@app/template/layout/modules/logo/logo.module';\r\nimport { RouterModule } from '@angular/router';\r\nimport { SitemapComponent } from '@app/template/layout/modules/sitemap/components/sitemap/sitemap.component';\r\nimport { SitemapItemComponent } from '@app/template/layout/modules/sitemap/components/sitemap/sitemap-item/sitemap-item.component';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\n\r\n@NgModule({\r\n declarations: [\r\n SitemapComponent,\r\n SitemapItemComponent,\r\n ],\r\n imports: [\r\n CommonModule,\r\n ElementsModule,\r\n LogoModule,\r\n RouterModule,\r\n TranslatorModule,\r\n ],\r\n exports: [\r\n SitemapComponent\r\n ]\r\n})\r\nexport class SiteMapModule {\r\n}\r\n\r\n","// This file can be replaced during build by using the `fileReplacements` array.\r\n// `ng build --prod` replaces `environment.ts` with `environment.prod.ts`.\r\n// The list of file replacements can be found in `angular.json`.\r\n\r\nexport const environment = {\r\n production: false\r\n};\r\n\r\n/*\r\n * For easier debugging in development mode, you can import the following file\r\n * to ignore zone related error stack frames such as `zone.run`, `zoneDelegate.invokeTask`.\r\n *\r\n * This import should be commented out in production mode because it will have a negative impact\r\n * on performance if an error is thrown.\r\n */\r\n// import 'zone.js/dist/zone-error'; // Included with Angular CLI.\r\n","import {enableProdMode} from '@angular/core';\r\nimport {platformBrowserDynamic} from '@angular/platform-browser-dynamic';\r\n\r\nimport {AppModule} from './app/app.module';\r\nimport {environment} from './environments/environment';\r\nimport 'hammerjs';\r\n\r\nif (environment.production) {\r\n enableProdMode();\r\n}\r\n\r\nplatformBrowserDynamic().bootstrapModule(AppModule)\r\n .catch(err => console.error(err));\r\n"]}
) {\r\n this.article = response.data;\r\n this.facadeService.subheader.config.title = this.article.attributes.title;\r\n this.facadeService.subheader.config.displayBreadcrumbs.next(true);\r\n this.facadeService.subheader.categories = this.article.attributes.categories;\r\n this.facadeService.subheader.publishedDate = this.article.attributes.createdAt;\r\n this.facadeService.subheader.image = this.article.attributes.file || this.article.attributes.file['croppedImage'];\r\n this.imageZoomService.setListener();\r\n this.facadeService.scrollTo.resetScrollTop();\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.destroyed$.next(true);\r\n this.destroyed$.complete();\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n {{ 'articles.seeAlso' | trans }}\r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n\r\n","export { ArticleComponent } from './article/article.component';\r\nexport { ArticleListComponent } from './article-list/article-list.component';\r\nexport { ArticleListItemComponent } from './article-list-item/article-list-item.component';\r\nexport { ArticleListRandomComponent } from './article-list-random/article-list-random.component';\r\n","import { Injectable } from '@angular/core';\r\nimport { API } from '@app/common/constants/api.directories';\r\nimport { Article } from '@app/client-core/article/models/article.model';\r\nimport { ResponseArray, ResponseObject } from '@share/common/models/http';\r\nimport { Observable } from 'rxjs';\r\nimport { HttpParams } from '@angular/common/http';\r\nimport { ElementService } from '@app/client-core/dynamic-content/service/element.service';\r\nimport { Preview } from '@app/client-core/preview/interfaces/preview.interface';\r\nimport { first } from 'rxjs/operators';\r\nimport { ApiService } from '@app/common/services/api.service';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ArticlesService implements Preview {\r\n constructor(protected element: ElementService, private apiService: ApiService) {}\r\n\r\n getList(\r\n page: number,\r\n count: number,\r\n category?: string | null,\r\n slug?: string | null,\r\n ): Observable> {\r\n let params: HttpParams = new HttpParams().append('page', page.toString()).append('count', count.toString());\r\n if (category) {\r\n params = params.set('category', category);\r\n } else if (slug) {\r\n params = params.append('categorySlug', slug);\r\n } else if (this.element.objectId) {\r\n params = params.set('category', this.element.objectId);\r\n }\r\n return this.apiService.getAll(`${API.ARTICLES.ROOT}`, params);\r\n }\r\n\r\n\r\n getRandomArticles(expect: string, count: number = 3) {\r\n let params: HttpParams = new HttpParams()\r\n .append('limit', count.toString())\r\n .append('except', expect);\r\n return this.apiService.getAll(`${API.ARTICLES.RANDOM}`, params);\r\n }\r\n\r\n getOne(slug: string): Observable> {\r\n return this.apiService.get(`${API.ARTICLES.ROOT}/${slug}`).pipe(first());\r\n }\r\n}\r\n","import { ChangeDetectionStrategy, Component, OnInit } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { CookieService } from '@app/client-core/cookies/service/cookie.service';\r\n\r\n@Component({\r\n selector: 'app-cookie-information-bar',\r\n templateUrl: './cookie-information-bar.component.html',\r\n styleUrls: ['./cookie-information-bar.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class CookieInformationBarComponent extends ComponentHelper implements OnInit {\r\n\r\n public cookieText: string = '';\r\n\r\n constructor(private settings: SettingsService, private cookieService: CookieService) {\r\n super();\r\n }\r\n\r\n get isCookieAccepted(): string {\r\n return this.cookieService.getCookie('cookiesAccepted');\r\n }\r\n\r\n ngOnInit() {\r\n try {\r\n this.cookieText = this.settings.variables.footer.cookieWarningContent;\r\n } catch (ignore) {\r\n throw new Error('Cannot get cookieWarningContent of undefined');\r\n }\r\n }\r\n\r\n accept(): void {\r\n this.cookieService.setCookie('cookiesAccepted', 'true', 365);\r\n }\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { CookieInformationBarComponent } from './components/cookie-information-bar/cookie-information-bar.component';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\n\r\n@NgModule({\r\n declarations: [CookieInformationBarComponent],\r\n imports: [\r\n CommonModule,\r\n ElementsModule,\r\n TranslatorModule\r\n ],\r\n exports: [\r\n CookieInformationBarComponent\r\n ]\r\n\r\n})\r\nexport class CookiesModule {\r\n}\r\n","import { Injectable } from '@angular/core';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class CookieService {\r\n\r\n constructor() {\r\n }\r\n\r\n public getCookie(name: string) {\r\n const ca: Array = document.cookie.split(';');\r\n const caLen: number = ca.length;\r\n const cookieName = `${name}=`;\r\n let c: string;\r\n\r\n for (let i = 0; i < caLen; i += 1) {\r\n c = ca[i].replace(/^\\s+/g, '');\r\n if (c.indexOf(cookieName) === 0) {\r\n return c.substring(cookieName.length, c.length);\r\n }\r\n }\r\n return '';\r\n }\r\n\r\n public setCookie(name: string, value: string, expireDays: number = 0): void {\r\n let cookie = '';\r\n cookie += `${name}=${value};`;\r\n const d: Date = new Date();\r\n if (expireDays !== 0) {\r\n d.setTime(d.getTime() + expireDays * 24 * 60 * 60 * 1000);\r\n\r\n cookie += `expires=${d.toString()}`;\r\n }\r\n document.cookie = cookie;\r\n\r\n }\r\n\r\n}\r\n","import { AfterViewInit, Component, OnDestroy, ViewChild, ViewContainerRef } from '@angular/core';\r\nimport { ActivatedRoute, Router } from '@angular/router';\r\nimport { DynamicContentService } from '@app/client-core/dynamic-content/service/dynamic-content.service';\r\nimport { LazyLoaderService } from '@app/common/services/lazy-loader.service';\r\nimport { switchMap, takeUntil, tap } from 'rxjs/operators';\r\nimport { of, Subject } from 'rxjs';\r\nimport { ROUTES_PATHS } from '@app/common/constants/routes-paths';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { ComponentInterface } from '@app/client-core/dynamic-content/interfaces/components.interface';\r\nimport { Nullable } from '@share/common/types/utilities.types';\r\nimport { BreadcrumbsService } from '@app/template/layout/modules/header/services/breadcrumbs.service';\r\nimport { ElementService } from '@app/client-core/dynamic-content/service/element.service';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { HOME_COMPONENTS } from '@app/client-core/dynamic-content/constants/component-list';\r\n\r\n@Component({\r\n selector: 'app-dynamic-content',\r\n templateUrl: './dynamic-content.component.html',\r\n styleUrls: ['./dynamic-content.component.scss']\r\n})\r\nexport class DynamicContentComponent implements AfterViewInit, OnDestroy {\r\n @ViewChild('componentPlaceholder', { read: ViewContainerRef }) componentPlaceholder: ViewContainerRef;\r\n private currentView: string;\r\n private destroy$: Subject = new Subject();\r\n\r\n constructor(\r\n private dynamic: DynamicContentService,\r\n private router: Router,\r\n private lazyLoaderService: LazyLoaderService,\r\n private facadeService: FacadeService,\r\n private breadcrumbsService: BreadcrumbsService,\r\n private elementsService: ElementService,\r\n private settingsService: SettingsService,\r\n ) {}\r\n\r\n async ngAfterViewInit() {\r\n this.dynamic.runtimeUrlReader$\r\n .pipe(\r\n takeUntil(this.destroy$),\r\n switchMap((rawUrl: string) => {\r\n if (rawUrl.includes('#')) {\r\n return of(null);\r\n } else {\r\n if (rawUrl === '/') {\r\n return of(this.getHomeComponent()).pipe(\r\n tap((component: Nullable) => (this.dynamic.homeComponent = component))\r\n );\r\n }\r\n return this.dynamic.componentLoader(rawUrl);\r\n }\r\n })\r\n )\r\n .subscribe(\r\n (component: Nullable) => {\r\n this.loadView(component);\r\n },\r\n () => this.componentNotFoundNavigation()\r\n );\r\n }\r\n\r\n private getHomeComponent(): ComponentInterface {\r\n const { name } = this.settingsService.variables.theme;\r\n return { ...HOME_COMPONENTS[name], isHome: true };\r\n }\r\n\r\n private loadView(component: Nullable) {\r\n if (component && component.className !== this.currentView) {\r\n this.breadcrumbsService.reset();\r\n this.facadeService.subheader.reset();\r\n this.componentPlaceholder?.clear();\r\n this.lazyLoaderService.load(component.module, this.componentPlaceholder, component.name).then(() => {\r\n this.facadeService.scrollTo.resetScrollTop();\r\n this.dynamic.loaded = true;\r\n this.currentView = component?.className;\r\n });\r\n } else if (component) {\r\n this.navigateToHomeDefaultContext(component);\r\n this.breadcrumbsService.reset();\r\n this.dynamic.loaded = true;\r\n this.elementsService.loaded = true;\r\n }\r\n this.facadeService.scrollTo.resetScrollTop();\r\n }\r\n\r\n private navigateToHomeDefaultContext(component: null | ComponentInterface) {\r\n if (component?.defaultContext && component?.isHome) {\r\n this.router.navigate([component?.defaultContext]);\r\n }\r\n }\r\n\r\n private componentNotFoundNavigation() {\r\n this.router.navigate(['/', ROUTES_PATHS.notFoundPage.root]);\r\n }\r\n\r\n ngOnDestroy() {\r\n this.destroy$.next(true);\r\n this.destroy$.complete();\r\n }\r\n}\r\n","\r\n","import { StaticPageComponent } from '@app/client-core/static-pages/components/static-page/static-page.component';\r\nimport { ArticleListComponent } from '@app/client-core/article/components/article-list/article-list.component';\r\nimport { ThemesEnum } from '@app/common/models/themes.enum';\r\nimport { ComponentsInterface } from '@app/client-core/dynamic-content/interfaces/components.interface';\r\nimport { OverlayComponent } from '@app/template/home/components/overlay/overlay.component';\r\nimport { ArticleComponent } from '@app/client-core/article/components';\r\n\r\nexport const COMPONENTS: ComponentsInterface = {\r\n main: { name: OverlayComponent, module: ThemesEnum.CORE, className: 'OverlayComponent' },\r\n static: { name: StaticPageComponent, module: ThemesEnum.CORE, className: 'StaticPageComponent' },\r\n articlecategory: { name: ArticleListComponent, module: ThemesEnum.ARTICLE, className: 'ArticleListComponent' },\r\n article: { name: ArticleComponent, module: ThemesEnum.ARTICLE, className: 'ArticleComponent' }\r\n};\r\n\r\nexport enum ThemeName {\r\n Basic = 'podstawowy'\r\n}\r\n\r\nexport const HOME_COMPONENTS: ComponentsInterface = {\r\n [ThemeName.Basic]: { name: OverlayComponent, module: ThemesEnum.CORE, className: 'OverlayComponent' }\r\n};\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { DynamicContentComponent } from './component/dynamic-content/dynamic-content.component';\r\nimport { ProgressBarModule } from '@share/modules/progress-bar/progress-bar.module';\r\nimport { StaticPagesModule } from '@app/client-core/static-pages/static-pages.module';\r\nimport { ArticleModule } from '@app/client-core/article/article.module';\r\nimport { HomeModule } from '@app/template/home/home.module';\r\nimport { DynamicUtilsService } from '@app/client-core/dynamic-content/service/dynamic-utils.service';\r\n\r\n@NgModule({\r\n declarations: [DynamicContentComponent],\r\n imports: [\r\n CommonModule,\r\n ProgressBarModule,\r\n StaticPagesModule,\r\n ArticleModule,\r\n HomeModule\r\n ],\r\n providers: [DynamicUtilsService],\r\n exports: [\r\n DynamicContentComponent\r\n ]\r\n})\r\nexport class DynamicContentModule {\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { API } from '@app/common/constants/api.directories';\r\nimport { COMPONENTS } from '@app/client-core/dynamic-content/constants/component-list';\r\nimport { BehaviorSubject, Observable, of, throwError } from 'rxjs';\r\nimport { MetaResponse, ResponseDefault } from '@share/common/models/http.model';\r\nimport { Nullable } from '@share/common/types/utilities.types';\r\nimport { ComponentInterface } from '@app/client-core/dynamic-content/interfaces/components.interface';\r\nimport { distinctUntilChanged, filter, map, startWith, switchMap, tap } from 'rxjs/operators';\r\nimport { ApiService } from '@app/common/services/api.service';\r\nimport { NavigationEnd, Router } from '@angular/router';\r\nimport { DynamicUtilsService } from '@app/client-core/dynamic-content/service/dynamic-utils.service';\r\nimport { ElementService } from '@app/client-core/dynamic-content/service/element.service';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class DynamicContentService {\r\n private _loaded: BehaviorSubject = new BehaviorSubject(true);\r\n loaded$: Observable = this._loaded.asObservable().pipe(distinctUntilChanged());\r\n homeComponent: Nullable;\r\n\r\n constructor(\r\n private apiService: ApiService,\r\n private router: Router,\r\n private dynamicUtilsService: DynamicUtilsService,\r\n private elementService: ElementService\r\n ) {}\r\n\r\n set loaded(value: boolean) {\r\n this._loaded.next(value);\r\n }\r\n\r\n get runtimeUrlReader$(): Observable {\r\n return this.router.events.pipe(\r\n startWith(new NavigationEnd(0, this.router.url, this.router.url)),\r\n filter((e: any): e is NavigationEnd => e instanceof NavigationEnd),\r\n map((event: NavigationEnd) => event.url)\r\n );\r\n }\r\n\r\n componentLoader(rawUrl: string): Observable> {\r\n return of(rawUrl).pipe(\r\n map((rawUrl: string) => this.dynamicUtilsService.parseUrlToBeProcessable(rawUrl)),\r\n switchMap((url: string) => this.getPageMetadata(url)),\r\n tap(response => {\r\n if (response?.meta?.objectId) {\r\n this.elementService.objectId = response?.meta?.objectId\r\n }\r\n }),\r\n map((response: any) => response.meta),\r\n switchMap((metadata: MetaResponse) => this.getComponentByType(metadata?.type))\r\n );\r\n }\r\n\r\n private getComponentByType(type: string | undefined): Observable> {\r\n if (type) {\r\n const component: Nullable = this.getComponent(type);\r\n if (!component) {\r\n return throwError(`Not found component ${type}`);\r\n }\r\n return of(component);\r\n } else {\r\n return throwError(`Component's type is not provided: ${type}`);\r\n }\r\n }\r\n\r\n getPageMetadata(url: string): Observable {\r\n return this.apiService.get(`${API.DYNAMIC_CONTENT.ROOT}${url && url != ' ' ? '/' + url : ''}`);\r\n }\r\n\r\n private getComponent(module: string): Nullable {\r\n try {\r\n return COMPONENTS[module.toLowerCase()];\r\n } catch (e) {\r\n return null;\r\n }\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\n\r\n@Injectable()\r\nexport class DynamicUtilsService {\r\n parseUrlToBeProcessable(url: string): string {\r\n let parsed: string = url.split('/').join(',');\r\n return parsed === ',' ? '' : parsed;\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { BehaviorSubject, Observable } from 'rxjs';\r\nimport { Nullable } from '@share/common/types/utilities.types';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ElementService {\r\n private _objectId: BehaviorSubject> = new BehaviorSubject>(null);\r\n private _sameComponentNavigation: BehaviorSubject = new BehaviorSubject(false);\r\n\r\n public get getObjectId(): Observable> {\r\n return this._objectId.asObservable();\r\n }\r\n\r\n public get objectId(): Nullable {\r\n return this._objectId.getValue();\r\n }\r\n\r\n public set objectId(value: Nullable) {\r\n this._objectId.next(value);\r\n }\r\n\r\n public get sameComponentNavigation(): Observable {\r\n return this._sameComponentNavigation.asObservable();\r\n }\r\n\r\n public set loaded(value: boolean) {\r\n this._sameComponentNavigation.next(value);\r\n }\r\n\r\n}\r\n","import {\r\n ChangeDetectionStrategy,\r\n ChangeDetectorRef,\r\n Component,\r\n ElementRef,\r\n EventEmitter,\r\n Input,\r\n Output,\r\n Renderer2\r\n} from '@angular/core';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { MenuModel } from '@app/client-core/menu/models/menu.model';\r\nimport { MenuService } from '@app/client-core/menu/services/menu.service';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\n\r\n@Component({\r\n selector: 'app-default-menu',\r\n templateUrl: './default-menu.component.html',\r\n styleUrls: ['./default-menu.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class DefaultMenuComponent {\r\n @Input() menu: AbstractData[];\r\n @Input() isMenuWidthChecking: boolean;\r\n @Input() isLoading: boolean;\r\n\r\n @Output() refreshed: EventEmitter = new EventEmitter();\r\n\r\n getError: boolean;\r\n open: { [id: string]: boolean } = {};\r\n\r\n constructor(\r\n private menuService: MenuService,\r\n private facadeService: FacadeService,\r\n private renderer: Renderer2,\r\n private cdr: ChangeDetectorRef,\r\n private _elementRef: ElementRef\r\n ) {}\r\n\r\n onMouseOver(id: string) {\r\n this.open[id] = true;\r\n }\r\n\r\n hideSubmenu() {\r\n for(let key in this.open) {\r\n this.open[key] = false;\r\n }\r\n }\r\n\r\n onComponentRefresh() {\r\n this.refreshed.emit();\r\n }\r\n}\r\n","\r\n Menu główne\r\n \r\n \r\n \r\n \r\n 0\">\r\n \r\n {{ item.attributes.title }}\r\n \r\n\r\n 12 ? '60' : '30'\" [class.show]=\"open[item.id]\" [attr.aria-labelledby]=\"item.attributes.title\">\r\n \r\n \r\n \r\n \r\n {{ child.attributes.highlightedContent }}\r\n\r\n \r\n \r\n {{ child.attributes.title }}\r\n \r\n\r\n\r\n \r\n \r\n {{ child.attributes.title }}\r\n \r\n\r\n \r\n \r\n\r\n \r\n \r\n \r\n {{ child.attributes.title }}\r\n \r\n\r\n \r\n \r\n {{ child.attributes.title }}\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n {{ item.attributes.title }}\r\n \r\n\r\n \r\n {{ item.attributes.title }}\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import {\r\n AfterViewInit,\r\n ChangeDetectionStrategy,\r\n ChangeDetectorRef,\r\n Component,\r\n ElementRef,\r\n Input,\r\n OnDestroy,\r\n ViewChild\r\n} from '@angular/core';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { MenuModel } from '@app/client-core/menu/models/menu.model';\r\nimport { MenuService } from '@app/client-core/menu/services/menu.service';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { filter, takeUntil, tap } from 'rxjs/operators';\r\nimport { fromEvent, Subject } from 'rxjs';\r\n\r\ndeclare var $: any;\r\n\r\n@Component({\r\n selector: 'app-mobile-menu',\r\n templateUrl: 'mobile-menu.component.html',\r\n styleUrls: ['mobile-menu.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class MobileMenuComponent implements OnDestroy, AfterViewInit {\r\n private destroy$: Subject = new Subject();\r\n\r\n @Input() menu: AbstractData[];\r\n\r\n @ViewChild('sidebarMobile') sidebarMobile: ElementRef;\r\n\r\n getError: boolean;\r\n getLoading: boolean;\r\n open: boolean;\r\n shownComplete: boolean;\r\n\r\n constructor(private menuService: MenuService,\r\n private facadeService: FacadeService,\r\n private cdr: ChangeDetectorRef,\r\n private _elementRef: ElementRef) {}\r\n\r\n ngOnInit() {\r\n this.shownComplete = true;\r\n this.listenForServiceChange();\r\n this.handleOutsideClick();\r\n }\r\n\r\n ngOnDestroy() {\r\n this.destroy$.next(true);\r\n this.destroy$.complete();\r\n }\r\n\r\n listenForServiceChange() {\r\n this.menuService.isMobileMenuActive$.pipe(takeUntil(this.destroy$)).subscribe(isActive => {\r\n if (!isActive) {\r\n this.hide();\r\n }\r\n });\r\n }\r\n\r\n hide() {\r\n this.open = false;\r\n $('.navbar-collapse').collapse('hide');\r\n this.cdr.detectChanges();\r\n }\r\n\r\n toggleMenu() {\r\n if (this.shownComplete) {\r\n this.shownComplete = false;\r\n this.open = !this.open;\r\n }\r\n }\r\n\r\n ngAfterViewInit() {\r\n $('.navbar-collapse')\r\n .on('shown.bs.collapse', () => (this.shownComplete = true))\r\n .on('hidden.bs.collapse', () => (this.shownComplete = true))\r\n }\r\n\r\n setLoader(value: boolean) {\r\n this.getLoading = value;\r\n this.cdr.detectChanges();\r\n }\r\n\r\n parseId(id: string): string {\r\n return id.replace(/ /g,'')\r\n }\r\n\r\n handleOutsideClick() {\r\n const clickEvent$ = fromEvent(document, 'click');\r\n clickEvent$\r\n .pipe(\r\n takeUntil(this.destroy$),\r\n filter(e => !this._elementRef.nativeElement.contains(e.target)),\r\n tap(() => this.hide())\r\n )\r\n .subscribe();\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n 0; else defaultMenuItem\">\r\n {{ item.attributes.title }}\r\n \r\n \r\n \r\n \r\n\r\n \r\n\r\n \r\n {{\r\n item.attributes.title\r\n }}\r\n \r\n\r\n \r\n {{\r\n item.attributes.title\r\n }}\r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { HttpClientModule } from '@angular/common/http';\r\nimport { LogoModule } from '@app/template/layout/modules/logo/logo.module';\r\nimport { DefaultMenuComponent } from './components/default-menu/default-menu.component';\r\nimport { RouterModule } from '@angular/router';\r\nimport { PolygonModule } from '@app/template/elements/polygon/polygon.module';\r\nimport { MobileMenuComponent } from '@app/client-core/menu/components/mobile-menu/mobile-menu.component';\r\n\r\n@NgModule({\r\n declarations: [MobileMenuComponent, DefaultMenuComponent],\r\n imports: [CommonModule, HttpClientModule, RouterModule, ElementsModule, TranslatorModule, LogoModule, PolygonModule],\r\n exports: [DefaultMenuComponent, MobileMenuComponent]\r\n})\r\nexport class MenuModule {}\r\n","import { Injectable } from '@angular/core';\r\nimport { BehaviorSubject, Observable, of } from 'rxjs';\r\nimport { MenuModel } from '@app/client-core/menu/models/menu.model';\r\nimport { ResponseArray } from '@share/common/models/http';\r\nimport { API } from '@app/common/constants/api.directories';\r\nimport { ApiService } from '@app/common/services/api.service';\r\nimport { Router } from '@angular/router';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class MenuService {\r\n\r\n isMobileMenuActive$: BehaviorSubject = new BehaviorSubject(false);\r\n\r\n constructor(private apiService: ApiService, private router: Router) {\r\n }\r\n\r\n public getList(type?: string): Observable> {\r\n return this.apiService.getAll(`${API.MENU.ROOT}${type ? `/${type}` : ''}`);\r\n }\r\n\r\n public navigate(type: string, url: string): Promise {\r\n if (type === 'link') {\r\n return new Promise((resolve) => {\r\n window.open(url);\r\n resolve(true);\r\n });\r\n } else {\r\n if (!url || url.includes('null')) {\r\n return this.router.navigate(['/']);\r\n } else {\r\n return this.router.navigateByUrl('/' + url);\r\n }\r\n }\r\n }\r\n\r\n public isActive(url: string): boolean {\r\n return this.router.isActive(url, true);\r\n }\r\n\r\n}\r\n","import { ChangeDetectionStrategy, ChangeDetectorRef, Component, Inject, OnDestroy } from '@angular/core';\r\nimport { SUBHEADER_INJECTION_TOKEN } from '@app/client-core/search/subheader-injection-token';\r\nimport { Observable, Subject } from 'rxjs';\r\nimport { takeUntil } from 'rxjs/operators';\r\n\r\n@Component({\r\n selector: 'app-search-results-subheader',\r\n templateUrl: 'search-results-subheader.component.html',\r\n styleUrls: ['search-results-subheader.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class SearchResultsSubheaderComponent implements OnDestroy {\r\n private destroy$: Subject = new Subject();\r\n\r\n amount: number;\r\n keyword: string;\r\n\r\n constructor(\r\n @Inject(SUBHEADER_INJECTION_TOKEN) data: Observable<{ amount: number; keyword: string }>,\r\n private cdr: ChangeDetectorRef\r\n ) {\r\n data.pipe(takeUntil(this.destroy$)).subscribe(data => {\r\n this.amount = data.amount;\r\n this.keyword = data.keyword;\r\n this.cdr.detectChanges();\r\n });\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.destroy$.next(true);\r\n this.destroy$.complete();\r\n }\r\n}\r\n","\r\n {{ keyword }} - Wyniki wyszukiwania\r\n \r\n Znaleziono\r\n {{ amount || 0 }} wyników\r\n \r\n\r\n","import { ChangeDetectorRef, Component, Injector, OnDestroy, OnInit } from '@angular/core';\r\nimport { ActivatedRoute } from '@angular/router';\r\nimport { SearchService } from '@app/client-core/search/services/search.service';\r\nimport { SearchItem } from '@app/client-core/search/models/search-item.model';\r\nimport { SearchType } from '@app/template/layout/modules/header/interfaces/subheader-config.interface';\r\nimport { BreadcrumbsService } from '@app/template/layout/modules/header/services/breadcrumbs.service';\r\nimport { combineLatest } from 'rxjs/internal/observable/combineLatest';\r\nimport { finalize, first, map, takeUntil, tap } from 'rxjs/operators';\r\nimport { PaginationService } from '@app/template/elements/pagination/services/pagination.service';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { SearchResultsSubheaderComponent } from '@app/client-core/search/components/search-results-subheader/search-results-subheader.component';\r\nimport { Subject } from 'rxjs';\r\nimport { SearchHelperService } from '@app/client-core/search/search-helper.service';\r\nimport { SUBHEADER_INJECTION_TOKEN } from '@app/client-core/search/subheader-injection-token';\r\nimport { ResponseArray } from '@share/common/models/http';\r\n\r\n@Component({\r\n selector: 'app-search-results',\r\n templateUrl: './search-results.component.html',\r\n styleUrls: ['./search-results.component.scss']\r\n})\r\nexport class SearchResultsComponent implements OnInit, OnDestroy {\r\n searchedWord: string;\r\n data: { articles: SearchItem[]; pages: SearchItem[] } = { articles: [], pages: [] };\r\n type: SearchType;\r\n pages: number = 1;\r\n count: number = 20;\r\n getLoading: boolean;\r\n getError: boolean;\r\n destroyed$: Subject = new Subject();\r\n\r\n private searchMetadata: Subject<{ amount: number; keyword: string }> = new Subject<{\r\n amount: number;\r\n keyword: string;\r\n }>();\r\n\r\n constructor(\r\n private activatedRoute: ActivatedRoute,\r\n private searchService: SearchService,\r\n private breadcrumbsService: BreadcrumbsService,\r\n private paginationService: PaginationService,\r\n private facadeService: FacadeService,\r\n private injector: Injector,\r\n private searchHelperService: SearchHelperService,\r\n private cdr: ChangeDetectorRef\r\n ) {\r\n this.setSubheader();\r\n this.setBreadcrumbs();\r\n }\r\n\r\n private setSubheader() {\r\n this.facadeService.subheader.setConfig({\r\n component: SearchResultsSubheaderComponent,\r\n injector: Injector.create({\r\n providers: [\r\n {\r\n provide: SUBHEADER_INJECTION_TOKEN,\r\n useValue: this.searchMetadata\r\n }\r\n ],\r\n parent: this.injector\r\n })\r\n });\r\n this.facadeService.subheader.config.displayBreadcrumbs.next(true);\r\n }\r\n\r\n public ngOnInit() {\r\n this.setPageListener();\r\n window.scrollTo(0, 0);\r\n }\r\n\r\n setLoader(value: boolean) {\r\n this.getLoading = value;\r\n this.cdr.detectChanges();\r\n }\r\n\r\n public searchRequest(page: number) {\r\n this.clearData();\r\n this.setLoader(true);\r\n this.searchService\r\n .getFullList(this.searchedWord, this.type, page, this.count)\r\n .pipe(\r\n first(),\r\n tap(response => (this.searchService.amount = response.data.length)),\r\n finalize(() => this.setLoader(false))\r\n )\r\n .subscribe(response => this.onResponseSuccess(response));\r\n }\r\n\r\n onResponseSuccess(response: ResponseArray) {\r\n this.clearData();\r\n this.searchMetadata.next({ amount: response?.meta?.amount || 0, keyword: this.searchedWord });\r\n response.data?.forEach((item: any) => {\r\n if (item.type === 'Page') {\r\n this.data = { articles: [...this.data.articles], pages: [...this.data.pages, item] };\r\n } else if (item.type === 'CmsArticle') {\r\n this.data = { articles: [...this.data.articles, item], pages: [...this.data.pages] };\r\n }\r\n });\r\n const meta = response.meta;\r\n if (meta && typeof meta.pages === 'number') {\r\n this.pages = meta.pages;\r\n }\r\n }\r\n\r\n identify(index: number) {\r\n return index;\r\n }\r\n\r\n private clearData() {\r\n this.data = {\r\n articles: [],\r\n pages: []\r\n };\r\n }\r\n\r\n navigateTo(url: string, isExternal: boolean) {\r\n if (isExternal) {\r\n window.open(url);\r\n } else {\r\n this.facadeService.router.navigate([url]);\r\n }\r\n }\r\n\r\n private setBreadcrumbs() {\r\n this.breadcrumbsService.forceActive = true;\r\n this.breadcrumbsService.customBreadcrumbs = [{ title: this.facadeService.translator.trans('search.header') }];\r\n }\r\n\r\n private setPageListener() {\r\n combineLatest([this.activatedRoute.params, this.paginationService.currentPage])\r\n .pipe(\r\n map(results => ({ data: results[0].data, page: results[1] })),\r\n takeUntil(this.destroyed$)\r\n )\r\n .subscribe(results => {\r\n this.searchedWord = results.data;\r\n this.searchRequest(results.page);\r\n });\r\n }\r\n\r\n ngOnDestroy() {\r\n this.destroyed$.next(true);\r\n this.destroyed$.complete();\r\n this.breadcrumbsService.forceActive = false;\r\n }\r\n}\r\n","\r\n \r\n \r\n 0\">\r\n Artykuły\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n 0\">\r\n Strony\r\n \r\n {{ item.attributes.content }}\r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { ChangeDetectorRef, Component, ElementRef, Input, OnDestroy, OnInit, ViewChild } from '@angular/core';\r\nimport { SearchService } from '@app/client-core/search/services/search.service';\r\nimport { SearchItem } from '@app/client-core/search/models/search-item.model';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { NavigationExtras } from '@angular/router';\r\nimport { SearchType } from '@app/template/layout/modules/header/interfaces/subheader-config.interface';\r\nimport { fromEvent, Observable, Subject } from 'rxjs';\r\nimport { filter, finalize, first, takeUntil, tap } from 'rxjs/operators';\r\nimport { UtilsService } from '@share/common/services/utils.service';\r\nimport { SelectModel } from '@share/modules/html/common/interfaces/select-model.interface';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { ThemesEnum } from '@app/common/models/themes.enum';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { ResizeListener } from '@app/common/services/resize-listener.service';\r\n\r\n@Component({\r\n selector: 'app-search',\r\n templateUrl: './search.component.html',\r\n styleUrls: ['./search.component.scss']\r\n})\r\nexport class SearchComponent implements OnInit, OnDestroy {\r\n\r\n private _value = '';\r\n private readonly minLength: number = 3;\r\n private destroy$: Subject = new Subject();\r\n\r\n @ViewChild('input') input: ElementRef;\r\n @Input() mobile: boolean;\r\n @Input() placeholder: string = 'search.button';\r\n\r\n data: { articles: SearchItem[]; pages: SearchItem[] } = { articles: [], pages: [] };\r\n availablesTypes: Array> = [];\r\n type: SearchType = SearchType.Default;\r\n searchSelectId: string;\r\n searchId: string;\r\n showResultsBox: boolean;\r\n loading: boolean;\r\n error: boolean;\r\n forceActive: boolean;\r\n isActive$: Observable;\r\n\r\n\r\n constructor(\r\n private searchService: SearchService,\r\n private _elementRef: ElementRef,\r\n private utils: UtilsService,\r\n private settingsService: SettingsService,\r\n private cdr: ChangeDetectorRef,\r\n private facadeService: FacadeService,\r\n ) {\r\n this.availablesTypes = this.searchService.getAvailableSearchTypes();\r\n const newId: string = this.utils.makeId();\r\n this.searchSelectId = `search-type-${newId}`;\r\n this.searchId = `search-input-${newId}`;\r\n }\r\n\r\n markAsActive() {\r\n this.searchService.isActive$.next(true);\r\n setTimeout(() => {\r\n this.forceActive = true;\r\n this.input.nativeElement.focus();\r\n }, 500)\r\n }\r\n\r\n markAsInactive(){\r\n this.searchService.isActive$.next(false);\r\n this.forceActive = false;\r\n this.showResultsBox = false;\r\n }\r\n\r\n onValueChange(value: string) {\r\n if (value.length >= 3) {\r\n this.showResultsBox = true;\r\n this.searchRequest(value);\r\n } else {\r\n this.showResultsBox = false;\r\n }\r\n this.value = value;\r\n }\r\n\r\n ngOnInit() {\r\n this.setSearchType();\r\n this.handleOutsideClick();\r\n this.isActive$ = this.searchService.isActive$;\r\n }\r\n\r\n private setSearchType() {\r\n this.facadeService.subheader.getConfig().subscribe(config => {\r\n this.type = config.searchType || SearchType.Default;\r\n });\r\n }\r\n\r\n handleOutsideClick() {\r\n const clickEvent$ = fromEvent(document, 'click');\r\n clickEvent$\r\n .pipe(\r\n takeUntil(this.destroy$),\r\n filter(e => !this._elementRef.nativeElement.contains(e.target)),\r\n tap(e => {\r\n this.clear();\r\n this.markAsInactive();\r\n })\r\n )\r\n .subscribe();\r\n }\r\n\r\n get value() {\r\n return this._value;\r\n }\r\n\r\n set value(data: string) {\r\n this._value = data;\r\n }\r\n\r\n hasMinLength(value: string) {\r\n const valid = value.length >= this.minLength;\r\n if (!valid) {\r\n this.clearData();\r\n }\r\n return valid;\r\n }\r\n\r\n search() {\r\n if (this.hasMinLength(this.value)) {\r\n this.markAsInactive();\r\n this.facadeService.router.navigate(['search', this._value], this.getNavigationExtras()).then(onfulfilled => {\r\n if (onfulfilled) {\r\n this.clear();\r\n }\r\n });\r\n }\r\n }\r\n\r\n private getNavigationExtras() {\r\n const extra: NavigationExtras = { queryParams: null };\r\n if (this.type !== SearchType.Default) {\r\n extra.queryParams = { type: this.type };\r\n }\r\n return extra;\r\n }\r\n\r\n setLoader(value: boolean) {\r\n this.loading = value;\r\n this.cdr.detectChanges();\r\n }\r\n\r\n searchRequest(value: string) {\r\n this.setLoader(true);\r\n this.clearData();\r\n this.searchService\r\n .getList(value, this.type)\r\n .pipe(\r\n first(),\r\n finalize(() => this.setLoader(false))\r\n )\r\n .subscribe(response => {\r\n this.clearData();\r\n response.data?.forEach((item: any) => {\r\n if (item.type === 'Page') {\r\n this.data = { articles: [...this.data.articles], pages: [...this.data.pages, item] };\r\n } else if (item.type === 'CmsArticle') {\r\n this.data = { articles: [...this.data.articles, item], pages: [...this.data.pages] };\r\n }\r\n });\r\n });\r\n }\r\n\r\n private clear() {\r\n this._value = '';\r\n this.clearData();\r\n this.showResultsBox = false;\r\n }\r\n\r\n private clearData() {\r\n this.data = {\r\n articles: [],\r\n pages: []\r\n }\r\n }\r\n\r\n ngOnDestroy() {\r\n this.destroy$.next(true);\r\n this.destroy$.complete();\r\n }\r\n}\r\n","\r\n \r\n {{'search.searchLabel' | trans}}\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n 0 || data.articles.length > 0\" [error]=\"error\">\r\n \r\n 0\">\r\n {{'search.pages' | trans}}\r\n \r\n {{ item.attributes.title }}\r\n \r\n \r\n\r\n 0\">\r\n {{'search.articles' | trans}}\r\n \r\n {{ item.attributes.title }}\r\n \r\n \r\n \r\n\r\n \r\n {{'search.noData' | trans}}\r\n \r\n \r\n \r\n\r\n","import { Injectable } from '@angular/core';\r\nimport { BehaviorSubject, forkJoin, Observable } from 'rxjs';\r\n\r\n@Injectable()\r\nexport class SearchHelperService {\r\n amount: BehaviorSubject = new BehaviorSubject(0);\r\n keyword: BehaviorSubject = new BehaviorSubject('');\r\n\r\n getData(): Observable<{ amount: number; keyword: string }> {\r\n return forkJoin({ amount: this.amount, keyword: this.keyword });\r\n }\r\n}\r\n","import {NgModule} from '@angular/core';\r\nimport {CommonModule} from '@angular/common';\r\nimport {SearchComponent} from './components/search/search.component';\r\nimport {FormsModule} from '@angular/forms';\r\nimport {ElementsModule} from '@share/modules/elements/elements.module';\r\nimport {SearchResultsComponent} from './components/search-results/search-results.component';\r\nimport {TranslatorModule} from '@share/modules/translator/translator.module';\r\nimport {NgbPaginationModule} from '@ng-bootstrap/ng-bootstrap';\r\nimport {ContainerModule} from '@app/template/layout/modules/container/container.module';\r\nimport {SelectModule} from '@share/modules/html/select/select.module';\r\nimport { PaginationModule } from '@app/template/elements/pagination/pagination.module';\r\nimport { PaginationService } from '@app/template/elements/pagination/services/pagination.service';\r\nimport { RouterModule } from '@angular/router';\r\nimport { SearchResultsSubheaderComponent } from '@app/client-core/search/components/search-results-subheader/search-results-subheader.component';\r\nimport { ArticleModule } from '@app/client-core/article/article.module';\r\nimport { SearchHelperService } from '@app/client-core/search/search-helper.service';\r\n\r\n@NgModule({\r\n declarations: [SearchComponent, SearchResultsComponent, SearchResultsSubheaderComponent],\r\n imports: [\r\n CommonModule,\r\n FormsModule,\r\n ElementsModule,\r\n TranslatorModule,\r\n NgbPaginationModule,\r\n ContainerModule,\r\n SelectModule,\r\n PaginationModule,\r\n RouterModule,\r\n ArticleModule,\r\n ],\r\n exports: [\r\n SearchComponent,\r\n SearchResultsComponent\r\n ],\r\n providers: [\r\n PaginationService,\r\n SearchHelperService\r\n ]\r\n})\r\nexport class SearchModule {}\r\n","import {Injectable} from '@angular/core';\r\nimport {ServiceHelper} from '@share/common/helpers/service.helper';\r\nimport {API} from '@app/common/constants/api.directories';\r\nimport { BehaviorSubject, Observable } from 'rxjs';\r\nimport {SearchType, SearchTypeNames} from '@app/template/layout/modules/header/interfaces/subheader-config.interface';\r\nimport {HttpParams} from '@angular/common/http';\r\nimport {AbstractData} from '@share/common/models/http.model';\r\nimport {SelectModel} from '@share/modules/html/common/interfaces/select-model.interface';\r\nimport {Bundle} from '@app/common/enums/server-bundles.enum';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class SearchService extends ServiceHelper {\r\n\r\n amount: number = 0;\r\n isActive$: BehaviorSubject = new BehaviorSubject(false);\r\n\r\n constructor() {\r\n super('');\r\n }\r\n\r\n public getList(keyword: string, searchType: SearchType): Observable {\r\n let params: HttpParams = new HttpParams().set('contains', keyword);\r\n\r\n if (!!searchType) {\r\n params = params.set('inside', searchType);\r\n }\r\n\r\n return this.getAll(API.SEARCH.ROOT, {http: {params}});\r\n }\r\n\r\n public getFullList(keyword: string, searchType: SearchType, page: number, count: number): Observable {\r\n let params: HttpParams = new HttpParams();\r\n\r\n params = params.set('page', page.toString());\r\n params = params.set('count', count.toString());\r\n params = params.set('contains', keyword);\r\n\r\n if (!!searchType) {\r\n params = params.set('inside', searchType);\r\n }\r\n\r\n return this.getAll(API.SEARCH.FULL, {http: {params}});\r\n }\r\n\r\n public getAvailableSearchTypes(): Array> {\r\n return [\r\n {\r\n id: SearchType.Default,\r\n type: Bundle.Alert,\r\n attributes: {\r\n title: SearchTypeNames.Default\r\n }\r\n },\r\n {\r\n id: SearchType.EServices,\r\n type: Bundle.Alert,\r\n attributes: {\r\n title: SearchTypeNames.EServices\r\n }\r\n }\r\n ];\r\n }\r\n}\r\n","import { InjectionToken } from '@angular/core';\r\n\r\nexport const SUBHEADER_INJECTION_TOKEN = new InjectionToken('SUBHEADER_INJECTION_TOKEN');\r\n","export { StaticPageComponent } from './static-page/static-page.component';\r\nexport { StaticPageDefaultComponent } from './static-page-default/static-page-default.component';\r\nexport { StaticPageContactComponent } from './static-page-contact/static-page-contact.component';\r\nexport { ContactFormComponent } from './static-page-contact/contact-form/contact-form.component';\r\nexport { ContactImagesComponent } from './static-page-contact/contact-images/contact-images.component';\r\nexport { ContactSubheaderComponent } from './static-page-contact/contact-subheader/contact-subheader.component';\r\nexport { SchedulePageComponent } from './schedule-page/schedule-page.component';\r\n","import { ChangeDetectionStrategy, Component, Input } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'app-schedule-page',\r\n templateUrl: 'schedule-page.component.html',\r\n styleUrls: ['schedule-page.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class SchedulePageComponent {\r\n @Input() data: {\r\n content: {\r\n boxPhone: string;\r\n boxSchedule: string;\r\n boxTitle: string;\r\n boxSubtitle: string;\r\n subtitle: string;\r\n schedule: {date: string, cities: string}[];\r\n };\r\n };\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n {{ boxTitle }}\r\n \r\n \r\n {{ boxSubtitle }}\r\n \r\n \r\n \r\n {{ boxPhone }}\r\n \r\n \r\n\r\n\r\n\r\n \r\n {{ title }}\r\n {{ content }}\r\n \r\n\r\n","import { Observable } from 'rxjs';\r\nimport { ResponseArray } from '@share/common/models/http';\r\nimport { API } from '@app/common/constants/api.directories';\r\nimport { ApiService } from '@app/common/services/api.service';\r\nimport { Injectable } from '@angular/core';\r\n\r\n@Injectable({ providedIn: 'root' })\r\nexport class ConsentsService {\r\n constructor(private apiService: ApiService) {}\r\n\r\n getList(name: string = ''): Observable> {\r\n return this.apiService.getAll(`${API.AUTH.CONSENTS}/${name}`);\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'app-contact-dots',\r\n templateUrl: 'contact-dots.component.html',\r\n styleUrls: ['contact-dots.component.scss']\r\n})\r\nexport class ContactDotsComponent {}\r\n","\r\n \r\n\r\n","import { AfterViewInit, ChangeDetectionStrategy, ChangeDetectorRef, Component, Input, OnDestroy, OnInit } from '@angular/core';\r\nimport { FormBuilder, FormGroup } from '@angular/forms';\r\nimport { CaptchaV3Service } from '@app/common/services/captcha-v3.service';\r\nimport { ConsentsService } from '@app/client-core/static-pages/components/static-page-contact/consents.service';\r\nimport { finalize, first } from 'rxjs/operators';\r\nimport { getContactFormGroup } from '@app/client-core/static-pages/components/static-page-contact/contact-form/form/contact-form.group';\r\nimport { getContactFormConfig } from '@app/client-core/static-pages/components/static-page-contact/contact-form/form/contact-form.config';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { ContactService } from '@app/client-core/static-pages/components/static-page-contact/contact.service';\r\n\r\n@Component({\r\n selector: 'app-contact-form',\r\n templateUrl: 'contact-form.component.html',\r\n styleUrls: ['contact-form.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class ContactFormComponent implements OnInit, OnDestroy, AfterViewInit {\r\n formGroup: FormGroup;\r\n formConfig: { [id: string]: any };\r\n consentLoader: boolean;\r\n sendLoader: boolean;\r\n\r\n @Input() title: string;\r\n @Input() subtitle: string;\r\n\r\n constructor(\r\n private formBuilder: FormBuilder,\r\n private captchaService: CaptchaV3Service,\r\n private consentService: ConsentsService,\r\n private cdr: ChangeDetectorRef,\r\n private facadeService: FacadeService,\r\n private contactService: ContactService\r\n ) {\r\n this.initFormGroup();\r\n }\r\n\r\n private initFormGroup() {\r\n this.formGroup = this.formBuilder.group(getContactFormGroup());\r\n this.formConfig = getContactFormConfig(this.facadeService.translator);\r\n }\r\n\r\n ngOnInit() {\r\n this.captchaService.load();\r\n this.getConsents();\r\n }\r\n\r\n getConsents() {\r\n this.consentLoader = true;\r\n this.cdr.detectChanges();\r\n this.consentService\r\n .getList('contact')\r\n .pipe(\r\n first(),\r\n finalize(() => {\r\n this.consentLoader = false;\r\n this.cdr.detectChanges();\r\n })\r\n )\r\n .subscribe(response => {\r\n const [first] = response.data;\r\n this.setConsentConfig(first.id, first.attributes.fulltext);\r\n });\r\n }\r\n\r\n setConsentConfig(id: string, label: string) {\r\n this.formConfig.consent = {\r\n id: id,\r\n label: label,\r\n allowHtmlLabel: true\r\n };\r\n }\r\n\r\n ngAfterViewInit() {\r\n this.captchaService.toggleVisibility();\r\n }\r\n\r\n onSubmit() {\r\n this.sendLoader = true;\r\n this.cdr.detectChanges();\r\n this.captchaService.execute()\r\n .pipe(\r\n first()\r\n )\r\n .subscribe(\r\n token => {\r\n this.formGroup.patchValue({ captcha: token });\r\n this.sendForm();\r\n },\r\n () => {\r\n this.facadeService.toastr.error(this.facadeService.trans('contact.form.captchaError'));\r\n this.sendLoader = false;\r\n this.cdr.detectChanges();\r\n }\r\n );\r\n }\r\n\r\n sendForm() {\r\n this.contactService\r\n .submit(this.formGroup.getRawValue())\r\n .pipe(\r\n first(),\r\n finalize(() => {\r\n this.sendLoader = false;\r\n this.cdr.detectChanges();\r\n })\r\n )\r\n .subscribe(\r\n () => {\r\n this.facadeService.toastr.success(this.facadeService.translator.trans('contact.form.successMessage'));\r\n this.formGroup.reset();\r\n },\r\n );\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.captchaService.toggleVisibility(false);\r\n }\r\n}\r\n","\r\n {{ title }}\r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n\r\n\r\n","import { InputTypeEnum } from '@share/modules/html/input/enums/input-types.enum';\r\nimport { TranslatorService } from '@share/common/services/translator.service';\r\n\r\nexport function getContactFormConfig(translatorService: TranslatorService): { [id: string]: any } {\r\n return {\r\n senderName: {\r\n id: 'senderName',\r\n type: InputTypeEnum.Text,\r\n label: translatorService.trans('contact.form.name')\r\n },\r\n senderEmail: {\r\n id: 'senderEmail',\r\n type: InputTypeEnum.Text,\r\n label: translatorService.trans('contact.form.email')\r\n },\r\n content: {\r\n id: 'content',\r\n type: InputTypeEnum.Text,\r\n label: translatorService.trans('contact.form.message')\r\n }\r\n };\r\n}\r\n","import { Validators } from '@angular/forms';\r\n\r\nexport function getContactFormGroup(): { [id: string]: any } {\r\n return {\r\n senderName: ['', Validators.required],\r\n senderEmail: ['', Validators.required],\r\n content: ['', Validators.required],\r\n dataProcessConsent: [false, Validators.requiredTrue],\r\n captcha: ['', Validators.required]\r\n };\r\n}\r\n","import { Component, Input } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'app-contact-images',\r\n templateUrl: 'contact-images.component.html',\r\n styleUrls: ['contact-images.component.scss']\r\n})\r\nexport class ContactImagesComponent {\r\n @Input() biggerImageUrl: string;\r\n @Input() smallerImageUrl: string;\r\n\r\n @Input() isRight: boolean;\r\n @Input() special: boolean;\r\n @Input() smallUp: boolean;\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n\r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { InstitutionService } from '@app/common/services/institution.service';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { first } from 'rxjs/operators';\r\nimport { Institution } from '@app/common/models/institution.model';\r\n\r\n@Component({\r\n selector: 'app-contact-subheader',\r\n templateUrl: 'contact-subheader.component.html',\r\n styleUrls: ['contact-subheader.component.scss']\r\n})\r\nexport class ContactSubheaderComponent implements OnInit {\r\n\r\n institution: AbstractData;\r\n\r\n constructor(private institutionService: InstitutionService) {}\r\n\r\n ngOnInit() {\r\n this.getInstitutionData();\r\n }\r\n\r\n getInstitutionData() {\r\n this.institutionService\r\n .getCurrent()\r\n .pipe(\r\n first()\r\n )\r\n .subscribe(response => this.institution = response.data)\r\n }\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n Dane kontaktowe\r\n \r\n {{institution.attributes.name}}\r\n {{institution.attributes.address.zipCode}} {{institution.attributes.address.city}} \r\n {{institution.attributes.address.street}} {{institution.attributes.address.houseNumber}}\r\n tel.: {{institution.attributes.contact.phoneNumber}}\r\n {{institution.attributes.contact.email}}\r\n \r\n \r\n\r\n","import { Injectable } from '@angular/core';\r\nimport { Observable } from 'rxjs';\r\nimport { ApiService } from '@app/common/services/api.service';\r\nimport { API } from '@app/common/constants/api.directories';\r\n\r\n@Injectable({providedIn: 'root'})\r\nexport class ContactService {\r\n\r\n constructor(private apiService: ApiService) {\r\n }\r\n\r\n public submit(contact: any): Observable {\r\n return this.apiService.post('contact', contact);\r\n }\r\n}\r\n","import { ChangeDetectionStrategy, Component, Input } from '@angular/core';\r\nimport { ImageCropper } from '@app/template/home/models/image-cropper.model';\r\n\r\n@Component({\r\n selector: 'app-static-page-contact-department',\r\n templateUrl: 'static-page-contact-department.component.html',\r\n styleUrls: ['static-page-contact-department.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class StaticPageContactDepartmentComponent {\r\n\r\n @Input() rightImage: boolean;\r\n @Input() special: boolean;\r\n @Input() specialTwo: boolean;\r\n @Input() smallUp: boolean;\r\n\r\n @Input() data: {\r\n title: string;\r\n bigImage: ImageCropper;\r\n smallImage: ImageCropper;\r\n people: {\r\n personOrPlace: string;\r\n contact: {\r\n type: 'phone' | 'email';\r\n value: string;\r\n extra: string | null;\r\n }[];\r\n }[];\r\n };\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n {{ data.title }}\r\n \r\n \r\n \r\n \r\n \r\n\r\n\r\n\r\n \r\n {{person.description}}\r\n {{person.fullName}} - {{person?.scope}}\r\n \r\n \r\n Numer telefonu\r\n \r\n {{ contact.value }}\r\n wew. {{ contact.extra }}\r\n \r\n\r\n \r\n Email\r\n \r\n {{ contact.value }}\r\n \r\n \r\n \r\n\r\n","import { Component, Input } from '@angular/core';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { ContactSubheaderComponent } from '@app/client-core/static-pages/components/static-page-contact/contact-subheader/contact-subheader.component';\r\n\r\n@Component({\r\n selector: 'app-static-page-contact',\r\n templateUrl: './static-page-contact.component.html',\r\n styleUrls: ['./static-page-contact.component.scss']\r\n})\r\nexport class StaticPageContactComponent {\r\n @Input() data: {\r\n sectionOne: any,\r\n sectionTwo: any,\r\n sectionThree: any,\r\n sectionFour: any\r\n };\r\n\r\n constructor(private facadeService: FacadeService) {\r\n this.facadeService.subheader.setConfig({\r\n component: ContactSubheaderComponent,\r\n hideDots: true\r\n });\r\n this.facadeService.subheader.displayBreadcrumbs = false;\r\n }\r\n}\r\n","\r\n\r\n\r\n \r\n \r\n {{ data.sectionThree.title }}\r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n = 3\">\r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { Component, Input } from '@angular/core';\r\nimport { StaticPageDefaultModel } from '@app/client-core/static-pages/model/static-page-default.model';\r\n\r\n@Component({\r\n selector: 'app-static-page-default',\r\n templateUrl: './static-page-default.component.html',\r\n styleUrls: ['./static-page-default.component.scss']\r\n})\r\nexport class StaticPageDefaultComponent {\r\n @Input() data: StaticPageDefaultModel;\r\n\r\n getFileUrl() {\r\n // TODO: Poprawić typy\r\n if (this.data.file?.hasOwnProperty('url')) {\r\n return this.data.file['croppedImage'] || this.data?.file['url'];\r\n }\r\n return this.getFileAsString();\r\n }\r\n\r\n private getFileAsString(): string | null {\r\n if (typeof this.data?.file === 'string') {\r\n return this.data?.file;\r\n }\r\n return null;\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { Component, Input, OnDestroy, OnInit } from '@angular/core';\r\nimport { SubheaderService } from '@app/template/layout/modules/header/services/subheader.service';\r\nimport { ElementService } from '@app/client-core/dynamic-content/service/element.service';\r\nimport { ActivatedRoute, Router } from '@angular/router';\r\nimport { UrlService } from '@app/common/services/url.service';\r\nimport { finalize, first, takeUntil } from 'rxjs/operators';\r\nimport { AbstractData, ResponseObject } from '@share/common/models/http';\r\nimport { PagesService } from '@app/common/services/pages.service';\r\nimport { PageModel } from '@app/common/models/page.model';\r\nimport { ReplaySubject } from 'rxjs';\r\nimport { HistoryService } from '@share/common/services/history.service';\r\nimport { StaticPage } from '@app/client-core/static-pages/model/static-pages.model';\r\nimport { Nullable } from '@share/common/types/utilities.types';\r\n\r\n@Component({\r\n selector: 'app-static-page',\r\n templateUrl: './static-page.component.html',\r\n styleUrls: ['./static-page.component.scss']\r\n})\r\nexport class StaticPageComponent implements OnInit, OnDestroy {\r\n @Input() page: Nullable>>>;\r\n\r\n private destroyed$: ReplaySubject = new ReplaySubject(1);\r\n getError: boolean;\r\n getLoading: boolean;\r\n\r\n constructor(\r\n protected pagesService: PagesService,\r\n protected subheaderService: SubheaderService,\r\n private elementService: ElementService,\r\n protected route: ActivatedRoute,\r\n private urlService: UrlService,\r\n private historyService: HistoryService,\r\n private router: Router\r\n ) {}\r\n\r\n private setListener() {\r\n this.elementService.sameComponentNavigation.pipe(takeUntil(this.destroyed$)).subscribe(same => {\r\n if (same) {\r\n this.loadPage();\r\n }\r\n });\r\n }\r\n\r\n ngOnInit() {\r\n this.setListener();\r\n if (!this.page) {\r\n this.loadPage();\r\n } else {\r\n this.setSubheader(this.page);\r\n }\r\n }\r\n\r\n protected onLoadPageSuccess(response: ResponseObject>>) {\r\n this.page = response.data;\r\n this.setSubheader(this.page);\r\n }\r\n\r\n private setSubheader(page: AbstractData>>) {\r\n this.subheaderService.setConfig({ title: page.attributes.title, publishedDate: page.attributes.publishedFrom });\r\n if (page.attributes.content?.pageType === 'schedule') {\r\n this.subheaderService.description = page?.attributes?.content?.content?.subtitle;\r\n this.subheaderService.publishedDate = '';\r\n }\r\n this.subheaderService.config.displayBreadcrumbs.next(true);\r\n }\r\n\r\n loadPage() {\r\n this.getLoading = true;\r\n this.pagesService\r\n .getOne(this.router.url.split('/').join(','))\r\n .pipe(\r\n first(),\r\n finalize(() => (this.getLoading = false))\r\n )\r\n .subscribe(\r\n response => this.onLoadPageSuccess(response),\r\n error => {\r\n this.subheaderService.setConfig({\r\n title: error.error.errors[0].status\r\n });\r\n this.subheaderService.description = error.error.errors[0].title;\r\n this.page = null;\r\n }\r\n );\r\n }\r\n\r\n ngOnDestroy() {\r\n this.destroyed$.next(true);\r\n this.destroyed$.complete();\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { RouterModule } from '@angular/router';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { ContainerModule } from '@app/template/layout/modules/container/container.module';\r\nimport { GoogleMapModule } from '@share/modules/google-map/google-map.module';\r\nimport {\r\n ContactFormComponent,\r\n StaticPageComponent,\r\n StaticPageContactComponent,\r\n StaticPageDefaultComponent,\r\n ContactImagesComponent,\r\n ContactSubheaderComponent,\r\n SchedulePageComponent\r\n} from '@app/client-core/static-pages/components';\r\nimport { ArticleModule } from '@app/client-core/article/article.module';\r\nimport { SimpleBoxModule } from '@app/template/elements/simple-box/simple-box.module';\r\nimport { ReactiveFormsModule } from '@angular/forms';\r\nimport { CheckboxModule } from '@share/modules/html/checkbox/checkbox.module';\r\nimport { InputModule } from '@app/template/elements/input/input.module';\r\nimport { TextareaModule } from '@app/template/elements/textarea/textarea.module';\r\nimport { HeaderModule } from '@app/template/layout/modules/header/header.module';\r\nimport { StaticPageContactDepartmentComponent } from '@app/client-core/static-pages/components/static-page-contact/static-page-contact-department/static-page-contact-department.component';\r\nimport { ContactDotsComponent } from '@app/client-core/static-pages/components/static-page-contact/contact-dots/contact-dots.component';\r\nimport { BreadcrumbsModule } from '@app/template/layout/modules/breadcrumbs/breadcrumbs.module';\r\n\r\n@NgModule({\r\n declarations: [\r\n SchedulePageComponent,\r\n StaticPageContactDepartmentComponent,\r\n ContactImagesComponent,\r\n ContactSubheaderComponent,\r\n ContactFormComponent,\r\n StaticPageComponent,\r\n StaticPageDefaultComponent,\r\n StaticPageContactComponent,\r\n ContactDotsComponent\r\n ],\r\n imports: [\r\n CommonModule,\r\n RouterModule,\r\n ElementsModule,\r\n TranslatorModule,\r\n ContainerModule,\r\n GoogleMapModule,\r\n ArticleModule,\r\n SimpleBoxModule,\r\n ReactiveFormsModule,\r\n CheckboxModule,\r\n InputModule,\r\n TextareaModule,\r\n HeaderModule,\r\n BreadcrumbsModule\r\n ],\r\n exports: [StaticPageComponent]\r\n})\r\nexport class StaticPagesModule {}\r\n","import { AppConfigCMS } from '@share/common/interfaces/app-config.interface';\r\n\r\ndeclare const APP_CONFIG: AppConfigCMS;\r\nexport const URL = APP_CONFIG.API_URL;\r\nconst PREFIX = APP_CONFIG.PREFIX;\r\nconst SERVER = `${URL}/${PREFIX}`;\r\n\r\nexport const API = {\r\n AUTH: {\r\n LOGIN: `${SERVER}/login`,\r\n LOGOUT: `${SERVER}/logout`,\r\n CONSENTS: `${SERVER}/consents`,\r\n FORGOT_PASSWORD: `${SERVER}/account/resetPassword/sendEmail`,\r\n VALIDATE_TOKEN: `${SERVER}/account/resetPassword/checkToken`,\r\n CHANGE_PASSWORD: `${SERVER}/account/resetPassword/change`,\r\n ACTIVATE_ACCOUNT: `${SERVER}/account/confirm`\r\n },\r\n COMMON: {\r\n BREADCRUMBS: `${SERVER}/breadcrumbs`\r\n },\r\n ARTICLES: {\r\n ROOT: `${SERVER}/articles`,\r\n RANDOM: `${SERVER}/articles/random`\r\n },\r\n SETTINGS: {\r\n ROOT: `${SERVER}/settings/bootstrap`,\r\n GET_LAYOUT: `${SERVER}/settings/layout`\r\n },\r\n SEARCH: {\r\n ROOT: `${SERVER}/search/autocomplete`,\r\n FULL: `${SERVER}/search/getResult`\r\n },\r\n PROMOTED: {\r\n ROOT: `${SERVER}/promoted`\r\n },\r\n BANNERS: {\r\n ROOT: `${SERVER}/banners`\r\n },\r\n MENU: {\r\n ROOT: `${SERVER}/menu`,\r\n SITEMAP: `${SERVER}/menu/sitemap`\r\n },\r\n DYNAMIC_CONTENT: {\r\n ROOT: `${SERVER}/search/getMetadata`\r\n },\r\n CATEGORY: {\r\n ROOT: `${SERVER}/categories`\r\n },\r\n PROFILE: {\r\n ROOT: `${SERVER}/account`\r\n },\r\n ALERTS: {\r\n ROOT: `${SERVER}/alerts`\r\n },\r\n BUSINESS_MODULES: {\r\n ROOT: `${SERVER}/businessModules`,\r\n },\r\n PAGES: {\r\n ROOT: `${SERVER}/pages`\r\n },\r\n PREVIEW: {\r\n ROOT: `${SERVER}/preview`\r\n },\r\n INSTITUTION: {\r\n ROOT: 'institution'\r\n },\r\n ASSETS: {\r\n DEFAULT_SETTINGS: 'source/default_settings.json'\r\n }\r\n};\r\n","import { APP_INITIALIZER, LOCALE_ID, Provider } from '@angular/core';\r\nimport { HTTP_INTERCEPTORS } from '@angular/common/http';\r\nimport { BootstrapService } from '@app/common/services/bootstrap.service';\r\nimport {\r\n getBackendVersionFactory,\r\n getFrontendVersionFactory,\r\n getLanguageFactory,\r\n getMaintenanceFactory,\r\n getPermissions,\r\n getSettingsFactory,\r\n getTranslationsFactory\r\n} from '@app/common/functions/bootstrap';\r\nimport { LanguageService } from '@share/common/services/language.service';\r\nimport { InstitutionInterceptorService } from '@app/common/interceptors/institution-interceptor.service';\r\nimport { ContentInterceptorService } from '@app/common/interceptors/content-interceptor.service';\r\nimport { ApiInterceptorService } from '@app/common/interceptors/api-interceptor.service';\r\n\r\nexport const BOOTSTRAP_PROVIDERS: Provider[] = [\r\n {\r\n provide: HTTP_INTERCEPTORS,\r\n useClass: ApiInterceptorService,\r\n multi: true\r\n },\r\n {\r\n provide: HTTP_INTERCEPTORS,\r\n useClass: ContentInterceptorService,\r\n multi: true\r\n },\r\n {\r\n provide: HTTP_INTERCEPTORS,\r\n useClass: InstitutionInterceptorService,\r\n multi: true\r\n },\r\n {\r\n provide: LOCALE_ID,\r\n deps: [LanguageService],\r\n useFactory: getLanguageFactory\r\n },\r\n {\r\n provide: APP_INITIALIZER,\r\n useFactory: getTranslationsFactory,\r\n deps: [BootstrapService],\r\n multi: true\r\n },\r\n {\r\n provide: APP_INITIALIZER,\r\n useFactory: getMaintenanceFactory,\r\n deps: [BootstrapService],\r\n multi: true\r\n },\r\n {\r\n provide: APP_INITIALIZER,\r\n useFactory: getSettingsFactory,\r\n deps: [BootstrapService],\r\n multi: true\r\n },\r\n {\r\n provide: APP_INITIALIZER,\r\n useFactory: getBackendVersionFactory,\r\n deps: [BootstrapService],\r\n multi: true\r\n },\r\n {\r\n provide: APP_INITIALIZER,\r\n useFactory: getFrontendVersionFactory,\r\n deps: [BootstrapService],\r\n multi: true\r\n }\r\n];\r\n","import {HAMMER_GESTURE_CONFIG, HammerGestureConfig} from '@angular/platform-browser';\r\nimport {Injectable, Provider} from '@angular/core';\r\nimport * as Hammer from 'hammerjs';\r\n\r\n@Injectable()\r\nexport class MyHammerConfig extends HammerGestureConfig {\r\n buildHammer(element: HTMLElement) {\r\n return new Hammer(element, {\r\n touchAction: 'pan-y pan-x'\r\n });\r\n }\r\n}\r\n\r\nexport const HAMMER_PROVIDER: Provider[] = [\r\n {\r\n provide: HAMMER_GESTURE_CONFIG,\r\n useClass: MyHammerConfig\r\n }\r\n];\r\n","import { NgModuleFactory, Type } from '@angular/core';\r\nimport { ThemesEnum } from '@app/common/models/themes.enum';\r\n\r\nexport const lazyWidgets: { name: string; loadChildren: () => Promise | Type> }[] = [\r\n {\r\n name: ThemesEnum.CORE,\r\n loadChildren: () => import('@app/client-core/static-pages/static-pages.module').then(m => m.StaticPagesModule)\r\n },\r\n {\r\n name: ThemesEnum.ARTICLE,\r\n loadChildren: () => import('@app/client-core/article/article.module').then(m => m.ArticleModule)\r\n },\r\n {\r\n name: ThemesEnum.MENU,\r\n loadChildren: () => import('@app/client-core/menu/menu.module').then(m => m.MenuModule)\r\n }\r\n];\r\n\r\nexport function lazyArrayToObj() {\r\n const result = {};\r\n for (const w of lazyWidgets) {\r\n result[w.name] = w.loadChildren;\r\n }\r\n return result;\r\n}\r\n","import {PortalVariablesEnum} from '@app/common/enums/portal-variables.enum';\r\n\r\nexport const PORTAL_VARIABLES_PRESETS = {\r\n [PortalVariablesEnum.MainColor]: '',\r\n [PortalVariablesEnum.SectionBackgroundColor]: '',\r\n [PortalVariablesEnum.ButtonColor]: '',\r\n [PortalVariablesEnum.AccentColor]: '',\r\n};\r\n","export const ARTICLE_PREVIEW = 'articles';\r\nexport const STATIC_PAGE_PREVIEW = 'static-pages';\r\nexport const ESERVICE_PREVIEW = 'eservices';\r\nexport const ROUTES_PATHS = {\r\n profile: {\r\n root: 'konto',\r\n login: 'logowanie',\r\n register: 'rejestracja',\r\n remindPassword: 'przypomnij-haslo'\r\n },\r\n businessModules: {\r\n root: 'moduly-biznesowe'\r\n },\r\n eServices: {\r\n root: 'katalog-e-uslug'\r\n },\r\n notFoundPage: {\r\n root: '404'\r\n },\r\n unknownErrorPage: {\r\n root: '500'\r\n },\r\n maintenance: {\r\n root: 'przerwa-techniczna'\r\n },\r\n preview: {\r\n articles: 'articles',\r\n staticPages: 'static-pages'\r\n }\r\n};\r\n","import { InjectionToken } from '@angular/core';\r\n\r\nexport const LAZY_WIDGETS = new InjectionToken<{ [key: string]: string }>('LAZY_WIDGETS');\r\n","export enum MobileEnum {\r\n Large = 992,\r\n Medium = 768,\r\n Small = 576\r\n}\r\n\r\n","export enum PortalVariablesEnum {\r\n MainColor = 'mainColor',\r\n AccentColor = 'accentColor',\r\n ButtonColor = 'buttonColor',\r\n SectionBackgroundColor = 'sectionBackgroundColor'\r\n}\r\n","export enum Bundle {\r\n EServices = 'EServices',\r\n User = 'CmsUser',\r\n Article = 'CmsArticle',\r\n Banner = 'CmsBanner',\r\n BusinessModules = 'CmsBusinessModule',\r\n Settings = 'Setting',\r\n Alert = 'CmsAlert',\r\n Promoted = 'CmsPromoted',\r\n Partners = 'CmsPartners',\r\n Sitemap = 'CmsSitemap',\r\n Breadcrumbs = 'Breadcrumbs',\r\n StaticPages = 'StaticPages',\r\n Preview = 'preview'\r\n}\r\n","import {BootstrapService} from '@app/common/services/bootstrap.service';\r\nimport { LanguageService } from '@share/common/services/language.service';\r\n\r\nexport function getLanguageFactory(language: LanguageService): () => string {\r\n return () => language.getLanguage();\r\n}\r\n\r\nexport function getTranslationsFactory(service: BootstrapService): () => Promise {\r\n return () => service.getTranslations();\r\n}\r\n\r\nexport function getMaintenanceFactory(service: BootstrapService): () => Promise {\r\n return () => service.checkMaintenance();\r\n}\r\n\r\nexport function getSettingsFactory(service: BootstrapService): () => Promise {\r\n return () => service.loadSettings();\r\n}\r\n\r\nexport function getBackendVersionFactory(service: BootstrapService): () => Promise {\r\n return () => service.getBackendVersion();\r\n}\r\n\r\nexport function getFrontendVersionFactory(service: BootstrapService): () => Promise {\r\n return () => service.getFrontendVersion();\r\n}\r\n\r\nexport function getPermissions(service: BootstrapService): () => Promise {\r\n return () => service.getPermissions();\r\n}\r\n","import { OnDestroy, Type } from '@angular/core';\r\nimport { ComponentShareHelper } from '@share/common/helpers/component-share.helper';\r\nimport { FacadeShareService } from '@share/common/services/facade-share.service';\r\nimport { ServiceLocator } from '@share/common/services/locater.service';\r\nimport { FacadeService } from '../services/facade.service';\r\n\r\nexport abstract class ComponentHelper extends ComponentShareHelper implements OnDestroy {\r\n\r\n protected service: FacadeService;\r\n\r\n protected constructor() {\r\n super(ServiceLocator.injector.get(FacadeShareService as Type));\r\n this.service = ServiceLocator.injector.get(FacadeService as Type);\r\n }\r\n}\r\n","import { HttpErrorResponse, HttpEvent, HttpHandler, HttpInterceptor, HttpRequest } from '@angular/common/http';\r\nimport { Injectable } from '@angular/core';\r\nimport { Observable, throwError } from 'rxjs';\r\nimport { ToastrServiceCustom } from '@share/common/services/toastr.service';\r\nimport { Router } from '@angular/router';\r\nimport { ROUTES_PATHS } from '@app/common/constants/routes-paths';\r\nimport { TranslatorService } from '@share/common/services/translator.service';\r\nimport { catchError } from 'rxjs/operators';\r\nimport { ErrorResponse } from '@share/common/models/http.model';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ApiInterceptorService implements HttpInterceptor {\r\n constructor(private toastr: ToastrServiceCustom, private translator: TranslatorService, private router: Router) {}\r\n\r\n private get internalErrorMessage(): string {\r\n return this.translator.trans('global.errors.internalError');\r\n }\r\n\r\n intercept(req: HttpRequest, next: HttpHandler): Observable> {\r\n const headersConfig = {};\r\n const request = req.clone({ setHeaders: headersConfig });\r\n return next.handle(request).pipe(catchError(httpErrorResponse => this.handleError(httpErrorResponse)));\r\n }\r\n\r\n private handleError(httpErrorResponse: any) {\r\n let error: { error: { errors: Array } } = { error: { errors: [] } };\r\n if (httpErrorResponse instanceof HttpErrorResponse) {\r\n this.handleErrorStatus(httpErrorResponse);\r\n const message = this.getMessage(httpErrorResponse);\r\n this.toastr.error(message.title);\r\n error = { error: { errors: [message] } };\r\n }\r\n return throwError(httpErrorResponse);\r\n }\r\n\r\n private getMessage(response: HttpErrorResponse): { title: string; id: string } {\r\n let title: string = '';\r\n try {\r\n const [error] = response.error.errors;\r\n title = error.title;\r\n } catch (e) {\r\n title = this.internalErrorMessage;\r\n }\r\n return { title, id: '' };\r\n }\r\n\r\n private handleErrorStatus(httpErrorResponse: HttpErrorResponse) {\r\n switch (httpErrorResponse.status) {\r\n case 403:\r\n this.handleForbidden();\r\n break;\r\n case 412:\r\n case 0:\r\n this.goToNotFoundPage();\r\n this.router.navigate([ROUTES_PATHS.unknownErrorPage.root]);\r\n break;\r\n }\r\n }\r\n\r\n private handleForbidden() {\r\n if (!this.router.isActive('', false)) {\r\n this.router.navigate(['']);\r\n }\r\n }\r\n\r\n private goToNotFoundPage() {\r\n this.router.navigate([ROUTES_PATHS.unknownErrorPage.root]);\r\n }\r\n}\r\n","import { HttpEvent, HttpHandler, HttpInterceptor, HttpRequest } from '@angular/common/http';\r\nimport { Observable } from 'rxjs';\r\nimport { Injectable } from '@angular/core';\r\n\r\n@Injectable()\r\nexport class ContentInterceptorService implements HttpInterceptor {\r\n intercept(req: HttpRequest, next: HttpHandler): Observable> {\r\n const headersConfig = {\r\n 'Content-Type': 'application/vnd.api+json',\r\n 'Accept': 'application/vnd.api+json',\r\n };\r\n const request = req.clone({setHeaders: headersConfig});\r\n return next.handle(request);\r\n }\r\n}\r\n","import { HttpEvent, HttpHandler, HttpInterceptor, HttpRequest } from '@angular/common/http';\r\nimport { Observable } from 'rxjs';\r\nimport { Injectable } from '@angular/core';\r\n\r\n@Injectable()\r\nexport class InstitutionInterceptorService implements HttpInterceptor {\r\n intercept(req: HttpRequest, next: HttpHandler): Observable> {\r\n const headersConfig = {\r\n 'x-site-url': window.location.origin\r\n };\r\n\r\n const request = req.clone({ setHeaders: headersConfig });\r\n return next.handle(request);\r\n }\r\n}\r\n","export enum ThemesEnum {\r\n ALERT = 'mportal_alert',\r\n ARTICLE = 'mportal_article',\r\n CONSENT = 'mportal_consent',\r\n ESERVICE_CATALOG = 'eservicesCatalog',\r\n MENU = 'mportal_menu',\r\n PROMOTED = 'mportal_promoted',\r\n NETIZEN = 'mportal_netizen',\r\n CORE = 'mportal_core',\r\n EOFFICE = 'eoffice'\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { FormErrors } from '@gkw/shared/common/models/form-errors.model';\r\nimport { HttpErrorResponse } from '@angular/common/http';\r\nimport { ResponseError } from '@share/common/models/http.model';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ApiErrorParserService {\r\n static parse(httpErrorResponse: HttpErrorResponse): FormErrors {\r\n const rawErrors: ResponseError = ApiErrorParserService.getRawErrors(httpErrorResponse);\r\n\r\n const parsedErrors: FormErrors = rawErrors.reduce((previous, current) => {\r\n return {\r\n ...previous,\r\n [current.id ?? current.status]: {\r\n text: current.title\r\n }\r\n };\r\n }, {});\r\n\r\n return parsedErrors;\r\n }\r\n\r\n static getRawErrors(httpErrorResponse: HttpErrorResponse): Array<{ id: string; title: string }> {\r\n try {\r\n return httpErrorResponse.error.errors;\r\n } catch (e) {\r\n throw new Error('Invalid error template');\r\n }\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { RequestOptionsModel } from '@share/common/interfaces/request-options.interface';\r\nimport { AppConfigCMS } from '@share/common/interfaces/app-config.interface';\r\n\r\ndeclare var APP_CONFIG: AppConfigCMS;\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ApiPreprocessorService {\r\n\r\n private readonly URL = `${APP_CONFIG.API_URL}/${APP_CONFIG.PREFIX}`;\r\n\r\n prepareUrl(endpoint: string): string {\r\n if (!endpoint.includes(this.URL)) {\r\n return `${this.URL}/${endpoint}`;\r\n }\r\n\r\n return endpoint;\r\n }\r\n\r\n build(bundle: string, data: object | Array, options: RequestOptionsModel = {}): any {\r\n const request: any = this.createBaseRequest(bundle, data, options);\r\n\r\n if (!!options) {\r\n if (options.jsonapi) {\r\n request.jsonapi = options.jsonapi;\r\n }\r\n if (options.meta) {\r\n request.meta = options.meta;\r\n }\r\n }\r\n\r\n return request;\r\n }\r\n\r\n private createBaseRequest(type: string, data: object | Array, options: RequestOptionsModel): any {\r\n return {\r\n data: Array.isArray(data) ? data : {type: type, attributes: data, id: options.id || '0'},\r\n jsonapi: { // TODO: remove\r\n version: '1.0'\r\n },\r\n meta: {}\r\n };\r\n }\r\n\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { HttpClient, HttpParams } from '@angular/common/http';\r\nimport { Observable, throwError } from 'rxjs';\r\nimport { catchError, first } from 'rxjs/operators';\r\nimport { ResponseArray, ResponseObject } from '@share/common/models/http';\r\nimport { RequestOptionsModel } from '@share/common/interfaces/request-options.interface';\r\nimport { ApiErrorParserService } from '@app/common/services/api-error-parser.service';\r\nimport { ApiPreprocessorService } from '@app/common/services/api-preprocessor.service';\r\nimport { ResponseDefault } from '@share/common/models/http.model';\r\nimport { AppConfigPortal } from '@share/common/interfaces/app-config.interface';\r\n\r\ndeclare var APP_CONFIG: AppConfigPortal;\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ApiService {\r\n private _bundle: string = '';\r\n\r\n constructor(private http: HttpClient, private preprocessor: ApiPreprocessorService) {}\r\n\r\n public setBundle(bundle: string) {\r\n this._bundle = bundle;\r\n }\r\n\r\n get(\r\n endpoint: string,\r\n params: HttpParams = new HttpParams(),\r\n options: RequestOptionsModel = {}\r\n ): Observable> {\r\n return this.http\r\n .get>(this.preprocessor.prepareUrl(endpoint), { params })\r\n .pipe(first());\r\n }\r\n\r\n getAll(\r\n endpoint: string,\r\n params: HttpParams = new HttpParams(),\r\n options: RequestOptionsModel = {}\r\n ): Observable> {\r\n return this.http\r\n .get>(this.preprocessor.prepareUrl(endpoint), { params })\r\n .pipe(first());\r\n }\r\n\r\n post(\r\n endpoint: string,\r\n body: Object = {},\r\n params: HttpParams = new HttpParams(),\r\n options: RequestOptionsModel = {}\r\n ): Observable {\r\n const requestData = this.preprocessor.build(options.bundle || this._bundle, body, options);\r\n return this.http\r\n .post(this.preprocessor.prepareUrl(endpoint), JSON.stringify(requestData), { params })\r\n .pipe(\r\n first(),\r\n catchError(e => throwError(ApiErrorParserService.parse(e)))\r\n );\r\n }\r\n\r\n put(\r\n endpoint: string,\r\n body: Object = {},\r\n options: RequestOptionsModel = {},\r\n params: HttpParams = new HttpParams()\r\n ): Observable {\r\n const requestData = this.preprocessor.build(options.bundle || this._bundle, body, options);\r\n\r\n return this.http\r\n .put(this.preprocessor.prepareUrl(endpoint), JSON.stringify(requestData), { params })\r\n .pipe(\r\n first(),\r\n catchError(e => throwError(ApiErrorParserService.parse(e)))\r\n );\r\n }\r\n\r\n patch(\r\n endpoint: string,\r\n body: Object = {},\r\n options: RequestOptionsModel = {},\r\n params: HttpParams = new HttpParams()\r\n ): Observable {\r\n const requestData = this.preprocessor.build(options.bundle || this._bundle, body, options);\r\n\r\n return this.http\r\n .patch(this.preprocessor.prepareUrl(endpoint), JSON.stringify(requestData), { params })\r\n .pipe(\r\n first(),\r\n catchError(e => throwError(ApiErrorParserService.parse(e)))\r\n );\r\n }\r\n\r\n assets(path: string): Observable {\r\n return this.http.get(`${APP_CONFIG.ASSETS_URL}/${path}`).pipe(first());\r\n }\r\n\r\n delete(endpoint: string): Observable {\r\n return this.http.delete(this.preprocessor.prepareUrl(endpoint)).pipe(first());\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { ROUTES_PATHS } from '@app/common/constants/routes-paths';\r\nimport { ResponseDefault } from '@share/common/models/http.model';\r\nimport { AppService } from '@share/common/services/app.service';\r\nimport { VersionService } from '@share/common/services/version.service';\r\nimport { VariablesCollection } from '@share/common/models/variables.model';\r\nimport { PortalLayoutService } from '@app/common/services/portal-layout.service';\r\nimport { Variable } from '@share/common/interfaces/variables.interface';\r\nimport { first } from 'rxjs/operators';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { AbstractData, ResponseObject } from '@share/common/models/http';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class BootstrapService {\r\n constructor(\r\n private appService: AppService,\r\n private versionService: VersionService,\r\n private portalLayoutService: PortalLayoutService,\r\n private facade: FacadeService\r\n ) {}\r\n\r\n getFrontendVersion(): Promise {\r\n return this.versionService.getFrontendVersion().then(\r\n (version: any) => (this.versionService.frontend = version),\r\n () => {}\r\n );\r\n }\r\n\r\n getBackendVersion(): Promise {\r\n return this.versionService.getBackendVersion().then(\r\n (response: ResponseDefault) => (this.versionService.backend = response.data.id),\r\n () => {}\r\n );\r\n }\r\n\r\n getTranslations(): Promise {\r\n return this.facade.translator.load().then(\r\n (response: ResponseObject) => (this.facade.translator.translations = response.data.attributes),\r\n () => this.onErrorOccur()\r\n );\r\n }\r\n\r\n checkMaintenance(): Promise {\r\n this.facade.maintenance.maintenancePage = ROUTES_PATHS.maintenance.root;\r\n this.facade.maintenance.serverErrorPage = ROUTES_PATHS.notFoundPage.root;\r\n return this.facade.maintenance.check().then(\r\n response => this.facade.maintenance.onSuccess(response),\r\n error => this.facade.maintenance.onError(error)\r\n );\r\n }\r\n\r\n loadSettings(): Promise {\r\n return new Promise(resolve => {\r\n this.facade.settings.load().then(\r\n (response: ResponseObject) => {\r\n this.facade.settings.variables = response.data.attributes;\r\n const layoutData = this.portalLayoutService.prepareData({\r\n ...response.data.attributes.layout,\r\n ...response.data.attributes.site\r\n });\r\n this.portalLayoutService.setLayout(layoutData as Array>);\r\n this.facade.seo.setData(this.facade.settings.variables);\r\n resolve();\r\n },\r\n () => {\r\n this.facade.settings\r\n .loadDefaultVariables()\r\n .pipe(first())\r\n .subscribe(val => {\r\n this.facade.settings.variables = val;\r\n resolve();\r\n });\r\n }\r\n );\r\n });\r\n }\r\n\r\n getPermissions(): Promise {\r\n //this.authService.isAuthenticated\r\n if (!!localStorage.getItem('token')) {\r\n return this.facade.crud.load();\r\n } else {\r\n return new Promise((resolve, reject) => resolve());\r\n }\r\n }\r\n\r\n private onErrorOccur() {\r\n this.appService.setFatalError(true);\r\n this.facade.router.navigate([ROUTES_PATHS.unknownErrorPage.root]);\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { Observable, ReplaySubject, Subject } from 'rxjs';\r\nimport { first, switchMap } from 'rxjs/operators';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\n\r\ndeclare const grecaptcha: any;\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class CaptchaV3Service {\r\n public readonly grecaptcha: Subject = new ReplaySubject();\r\n private scriptElement: HTMLScriptElement;\r\n\r\n constructor(private settingsService: SettingsService) {}\r\n\r\n public load(): void {\r\n if (this.scriptElement) {\r\n return;\r\n }\r\n this.scriptElement = document.createElement('script');\r\n this.scriptElement.src = `https://www.google.com/recaptcha/api.js?render=${this.settingsService.variables.integration.googleReCaptchaSiteKey}`;\r\n this.scriptElement.async = true;\r\n this.scriptElement.addEventListener('load', event => {\r\n grecaptcha.ready(() => {\r\n this.grecaptcha.next(grecaptcha);\r\n });\r\n });\r\n this.scriptElement.addEventListener('error', event => {\r\n this.grecaptcha.next(null);\r\n });\r\n document.getElementsByTagName('head')[0].append(this.scriptElement);\r\n\r\n this.toggleVisibility();\r\n }\r\n\r\n execute(action: string = 'homepage'): Observable {\r\n return this.grecaptcha.pipe(first()).pipe(\r\n switchMap(val => {\r\n if (val === null) {\r\n throw new Error('Google captcha script is not loaded');\r\n }\r\n return val.execute(this.settingsService.variables.integration.googleReCaptchaSiteKey, { action });\r\n })\r\n );\r\n }\r\n\r\n toggleVisibility(show: boolean = true) {\r\n const grecaptcha: HTMLElement | null = document.querySelector('.grecaptcha-badge');\r\n if (grecaptcha) {\r\n grecaptcha.style.display = show ? 'block' : 'none';\r\n }\r\n }\r\n}\r\n","import { Injectable, Injector } from '@angular/core';\r\nimport { FacadeShareService } from '@share/common/services/facade-share.service';\r\nimport { SubheaderService } from '@app/template/layout/modules/header/services/subheader.service';\r\nimport { ScrollToService } from '@app/common/services/scroll-to.service';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class FacadeService extends FacadeShareService {\r\n private _subheader: SubheaderService;\r\n private _scrollTo: ScrollToService;\r\n private _settings: SettingsService;\r\n\r\n constructor(private injector: Injector) {\r\n super(injector);\r\n }\r\n\r\n public get subheader(): SubheaderService {\r\n if (!this._subheader) {\r\n this._subheader = this._injector.get(SubheaderService);\r\n }\r\n return this._subheader;\r\n }\r\n\r\n public get scrollTo(): ScrollToService {\r\n if (!this._scrollTo) {\r\n this._scrollTo = this._injector.get(ScrollToService);\r\n }\r\n return this._scrollTo;\r\n }\r\n\r\n public get settings(): SettingsService {\r\n if (!this._settings) {\r\n this._settings = this._injector.get(SettingsService);\r\n }\r\n return this._settings;\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\n\r\ndeclare var google: any;\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class GoogleTranslateService {\r\n public init() {\r\n // tslint:disable-next-line:no-unused-expression\r\n new google.translate.TranslateElement({\r\n pageLanguage: 'pl',\r\n includedLanguages: 'pl,cs,da,de,en,es,fi,fr,hu,it,ja,no,pt,ru,zh-CN',\r\n layout: google.translate.TranslateElement.InlineLayout.SIMPLE\r\n }, 'google_translate_element');\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { NgbModalOptions } from '@ng-bootstrap/ng-bootstrap';\r\nimport { ServiceHelper } from '@share/common/helpers/service.helper';\r\nimport { ImageZoomComponent } from '@app/template/elements/image-zoom/components/image-zoom/image-zoom.component';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ImageZoomService extends ServiceHelper {\r\n private readonly zoomClass: string = '.image-zoom';\r\n private readonly originalFilterName: string = 'original';\r\n\r\n constructor() {\r\n super('');\r\n }\r\n\r\n public setListener() {\r\n // TODO: it cant find correct dom data, in settimeout works\r\n const images = document.querySelectorAll(this.zoomClass);\r\n for (let i = 0; i < images.length; i++) {\r\n images[i].addEventListener('click', event => this.imagePreview(event.target as HTMLImageElement));\r\n }\r\n }\r\n\r\n public imagePreview(image: HTMLImageElement) {\r\n const src: string = image.src;\r\n const originalSrc: string = this.getOriginalPath(src);\r\n // @ts-ignore\r\n const config: NgbModalOptions = {keyboard: true, backdrop: true, size: 'xl'};\r\n this.modal.openCustomModal(ImageZoomComponent, {original: originalSrc, alt: image.alt}, config);\r\n }\r\n\r\n private getOriginalPath(src: string | null): string {\r\n if (!src) {\r\n return '';\r\n }\r\n let path: string = src.slice(0, src.indexOf('filterName'));\r\n path += `filterName=${this.originalFilterName}`;\r\n return path;\r\n }\r\n}\r\n","import {Injectable} from '@angular/core';\r\nimport {ApiService} from '@app/common/services/api.service';\r\nimport {Observable} from 'rxjs';\r\nimport {ResponseObject} from '@share/common/models/http.model';\r\nimport {Institution} from '@app/common/models/institution.model';\r\nimport {API} from '@app/common/constants/api.directories';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class InstitutionService {\r\n\r\n constructor(private apiService: ApiService) {}\r\n\r\n public getCurrent(): Observable> {\r\n return this.apiService.get(API.INSTITUTION.ROOT);\r\n }\r\n}\r\n","import {\r\n Compiler,\r\n ComponentRef,\r\n Inject,\r\n Injectable,\r\n Injector,\r\n NgModuleFactory,\r\n Type,\r\n ViewContainerRef\r\n} from '@angular/core';\r\nimport { LAZY_WIDGETS } from '@app/common/constants/tokens';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class LazyLoaderService {\r\n constructor(\r\n private injector: Injector,\r\n private compiler: Compiler,\r\n @Inject(LAZY_WIDGETS) private lazyWidgets: { [key: string]: () => Promise | Type> }\r\n ) {}\r\n\r\n async load(name: string, container: ViewContainerRef, component?: any): Promise> {\r\n const ngModuleOrNgModuleFactory = await this.lazyWidgets[name]();\r\n\r\n let moduleFactory;\r\n if (ngModuleOrNgModuleFactory instanceof NgModuleFactory) {\r\n moduleFactory = ngModuleOrNgModuleFactory;\r\n } else {\r\n moduleFactory = await this.compiler.compileModuleAsync(ngModuleOrNgModuleFactory);\r\n }\r\n const entryComponent = component || (moduleFactory.moduleType).entry;\r\n const moduleRef = moduleFactory.create(this.injector);\r\n\r\n const compFactory = moduleRef.componentFactoryResolver.resolveComponentFactory(entryComponent);\r\n\r\n return container.createComponent(compFactory);\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { Observable } from 'rxjs';\r\nimport { Preview } from '@app/client-core/preview/interfaces/preview.interface';\r\nimport { ResponseObject } from '@share/common/models/http';\r\nimport { PageModel } from '@app/common/models/page.model';\r\nimport { ApiService } from '@app/common/services/api.service';\r\nimport { API } from '../constants/api.directories';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class PagesService implements Preview {\r\n constructor(private apiService: ApiService) {}\r\n\r\n getOne(slug: string = ''): Observable>> {\r\n return this.apiService.get(`${API.PAGES.ROOT}${slug ? '/' + slug : ''}`);\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { LayoutService } from '@share/common/services/layout.service';\r\nimport { PortalVariablesEnum } from '@app/common/enums/portal-variables.enum';\r\nimport { PORTAL_VARIABLES_PRESETS } from '@app/common/constants/portal-variables-presets';\r\nimport { HttpClient } from '@angular/common/http';\r\nimport { ImageService } from '@share/common/services/image.service';\r\nimport { AbstractData } from '@share/common/models/http.model';\r\nimport { ObjectString } from '@share/common/interfaces/object-types.interface';\r\nimport { Variable } from '@share/common/interfaces/variables.interface';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class PortalLayoutService extends LayoutService {\r\n\r\n constructor(protected httpClient: HttpClient,\r\n protected imageService: ImageService) {\r\n super(httpClient, imageService);\r\n this.layoutPresets = PORTAL_VARIABLES_PRESETS;\r\n }\r\n\r\n public prepareData(variables: ObjectString): Array>> {\r\n const data: Array>> = [];\r\n for (const variable of Object.keys(variables)) {\r\n data.push({\r\n id: '0',\r\n type: '',\r\n attributes: {\r\n name: variable,\r\n value: variables[variable]\r\n }\r\n });\r\n }\r\n return data;\r\n }\r\n\r\n protected variablesQueue(): Array {\r\n return [\r\n PortalVariablesEnum.AccentColor,\r\n PortalVariablesEnum.ButtonColor,\r\n PortalVariablesEnum.MainColor,\r\n PortalVariablesEnum.SectionBackgroundColor,\r\n ];\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { fromEvent, merge, Observable, of } from 'rxjs';\r\nimport { map, switchMap } from 'rxjs/operators';\r\nimport { MobileEnum } from '@app/common/enums/mobile.enum';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ResizeListener {\r\n get isMobile$(): Observable {\r\n return merge(this.onLoad(), this.onResize()).pipe(\r\n switchMap(value => {\r\n if (!value) {\r\n return this.isMobileDevice();\r\n }\r\n return of(value);\r\n })\r\n );\r\n }\r\n\r\n private onResize(): Observable {\r\n return fromEvent(window, 'resize').pipe(map(() => window.innerWidth < MobileEnum.Large));\r\n }\r\n\r\n private onLoad(): Observable {\r\n return of(window.innerWidth < MobileEnum.Large);\r\n }\r\n private isMobileDevice(): Observable {\r\n return of(/iPhone|iPad|iPod|Android/i.test(navigator.userAgent));\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\n\r\ndeclare var $: Function;\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ScrollToService {\r\n\r\n constructor() {}\r\n\r\n animate(id: string, time: number = 500, scrollDifference: number = 70) {\r\n try {\r\n $('html, body').animate({\r\n scrollTop: ($(id).offset().top as number) - scrollDifference,\r\n }, time);\r\n } catch (ignore) {\r\n }\r\n }\r\n\r\n resetScrollTop() {\r\n window.scrollTo(0, 0);\r\n }\r\n}\r\n\r\n","import { Injectable } from '@angular/core';\r\nimport { API } from '@app/common/constants/api.directories';\r\nimport { ApiService } from '@app/common/services/api.service';\r\nimport { Observable } from 'rxjs';\r\nimport { BootstrapModel } from '@app/common/models/bootstrap.model';\r\nimport { ResponseObject } from '@share/common/models/http';\r\nimport { ThemesEnum } from '@app/common/models/themes.enum';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class SettingsService {\r\n variables: T;\r\n\r\n constructor(private apiService: ApiService) {}\r\n\r\n load(): Promise> {\r\n return this.apiService.get(API.SETTINGS.ROOT).toPromise();\r\n }\r\n\r\n loadDefaultVariables(): Observable {\r\n return this.apiService.assets(API.ASSETS.DEFAULT_SETTINGS);\r\n }\r\n\r\n isModuleActive(theme: ThemesEnum): boolean {\r\n return this.variables.theme.modules.includes(theme);\r\n }\r\n}\r\n","import {Injectable} from '@angular/core';\r\nimport {Location} from '@angular/common';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class UrlService {\r\n constructor(private location: Location) {}\r\n\r\n getParsedUrl(): string {\r\n const path: string = this.location.path();\r\n return path.substr(1, path.length).replace(/\\//g, ',');\r\n }\r\n\r\n getLastUrlElement(): string {\r\n const paths: string[] = this.getParsedUrl().split(',');\r\n return paths[paths.length - 1];\r\n }\r\n}\r\n","import { CommonModule } from '@angular/common';\r\nimport { NgModule } from '@angular/core';\r\nimport { AccordionComponent } from './component/accordion/accordion.component';\r\nimport { AccPanelTitleDirective, AccPanelContentDirective, AccPanelDirective } from './directives/accordion-panel.directive';\r\n\r\n@NgModule({\r\n imports: [CommonModule],\r\n exports: [\r\n AccordionComponent,\r\n AccPanelTitleDirective,\r\n AccPanelContentDirective,\r\n AccPanelDirective\r\n ],\r\n declarations: [\r\n AccordionComponent,\r\n AccPanelTitleDirective,\r\n AccPanelContentDirective,\r\n AccPanelDirective\r\n ]\r\n})\r\nexport class AccordionModule {}\r\n","import { AfterContentChecked, Component, ContentChildren, EventEmitter, Input, Output, QueryList, ViewEncapsulation } from '@angular/core';\r\nimport { AccPanelChangeEvent } from '../../interfaces/accordion-panel-change-event.model';\r\nimport { AccPanelDirective } from '../../directives/accordion-panel.directive';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\n\r\n@Component({\r\n selector: 'app-accordion',\r\n templateUrl: './accordion.component.html',\r\n styleUrls: ['./accordion.component.scss']\r\n})\r\nexport class AccordionComponent extends ComponentHelper implements AfterContentChecked {\r\n @ContentChildren(AccPanelDirective) panels: QueryList;\r\n @Input() activeIds: string[] = [];\r\n @Output() readonly panelChange = new EventEmitter();\r\n\r\n constructor() {\r\n super();\r\n }\r\n\r\n private _findPanelById(panelId: string): AccPanelDirective | undefined {\r\n return this.panels.find(p => p.id === panelId);\r\n }\r\n\r\n\r\n private _updateActiveIds() {\r\n this.activeIds = this.panels.filter(panel => panel.isOpen && !panel.disabled).map(panel => panel.id);\r\n }\r\n\r\n private _changeOpenState(panel: AccPanelDirective, nextState: boolean, target: EventTarget) {\r\n if (panel && !panel.disabled && panel.isOpen !== nextState) {\r\n let defaultPrevented = false;\r\n\r\n this.panelChange.emit({\r\n panelId: panel.id,\r\n nextState: nextState,\r\n target,\r\n prevent: () => { defaultPrevented = true; }\r\n });\r\n\r\n if (!defaultPrevented) {\r\n panel.isOpen = nextState;\r\n\r\n this._updateActiveIds();\r\n }\r\n }\r\n }\r\n\r\n toggle(panelId: string, target: EventTarget) {\r\n const panel = this._findPanelById(panelId);\r\n if (panel) {\r\n this._changeOpenState(panel, !panel.isOpen, target);\r\n }\r\n }\r\n\r\n isPanelActive(panelId: string): boolean {\r\n return this.activeIds && this.activeIds.indexOf(panelId) !== -1;\r\n }\r\n\r\n expandAll() {\r\n this.panels.forEach(panel => {\r\n if (this.activeIds.indexOf(panel.id) === -1) {\r\n this.activeIds.push(panel.id);\r\n }\r\n });\r\n }\r\n\r\n ngAfterContentChecked() {\r\n this.panels.forEach(panel => panel.isOpen = !panel.disabled && this.activeIds.indexOf(panel.id) > -1);\r\n }\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { AfterContentChecked, ContentChildren, Directive, Input, QueryList, TemplateRef } from '@angular/core';\r\n\r\n@Directive({selector: 'ng-template[appAccPanelTitle]'})\r\nexport class AccPanelTitleDirective {\r\n constructor(public templateRef: TemplateRef) {}\r\n}\r\n\r\n@Directive({selector: 'ng-template[appAccPanelContent]'})\r\nexport class AccPanelContentDirective {\r\n constructor(public templateRef: TemplateRef) {}\r\n}\r\n\r\n@Directive({selector: '[appAccPanel]'})\r\nexport class AccPanelDirective implements AfterContentChecked {\r\n\r\n @Input() disabled = false;\r\n @Input() id: string;\r\n @Input() title: string;\r\n @Input() type: string;\r\n @Input() isOpen = false;\r\n\r\n @ContentChildren(AccPanelTitleDirective, {descendants: false}) titleTpls: QueryList;\r\n @ContentChildren(AccPanelContentDirective, {descendants: false}) contentTpls: QueryList;\r\n\r\n titleTpl: AccPanelTitleDirective | null;\r\n contentTpl: AccPanelContentDirective | null;\r\n\r\n constructor() { }\r\n\r\n ngAfterContentChecked() {\r\n this.titleTpl = this.titleTpls.first;\r\n this.contentTpl = this.contentTpls.first;\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { MultiCarouselComponent } from './components/multi-carousel/multi-carousel.component';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { PolygonModule } from '@app/template/elements/polygon/polygon.module';\r\n\r\n@NgModule({\r\n declarations: [\r\n MultiCarouselComponent\r\n ],\r\n imports: [\r\n CommonModule,\r\n TranslatorModule,\r\n PolygonModule\r\n ],\r\n exports: [\r\n MultiCarouselComponent\r\n ]\r\n})\r\nexport class CarouselModule {}\r\n","import { AfterViewChecked, Component, ElementRef, Input } from '@angular/core';\r\nimport { MultiCarousel } from '../../models/multi-carousel.model';\r\nimport { MultiCarouselConfig } from '../../models/multi-carousel-config.model';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { AbstractData } from '@share/common/models/http';\r\n\r\ndeclare var $: Function;\r\n\r\n@Component({\r\n selector: 'app-multi-carousel',\r\n templateUrl: './multi-carousel.component.html',\r\n styleUrls: [\r\n './multi-carousel.component.scss'\r\n ]\r\n})\r\nexport class MultiCarouselComponent extends ComponentHelper implements AfterViewChecked {\r\n @Input() data: Array> = [];\r\n\r\n @Input()\r\n set config(config: MultiCarouselConfig) {\r\n this._config = Object.assign(this._config, config);\r\n }\r\n\r\n private _config: MultiCarouselConfig = {\r\n dots: true,\r\n nav: true,\r\n itemsOnScreen: {\r\n 0: {\r\n items: 2\r\n },\r\n 600: {\r\n items: 3\r\n },\r\n 1000: {\r\n items: 4\r\n }\r\n },\r\n autoplayHoverPause: false,\r\n autoplay: false,\r\n autoplayTimeout: 5000,\r\n loop: false\r\n };\r\n\r\n get config() {\r\n return this._config;\r\n }\r\n\r\n private isCarouselInit = false;\r\n\r\n constructor(private elementRef: ElementRef) {\r\n super();\r\n }\r\n\r\n public initCarousel(): void {\r\n const owl = $('.owl-carousel').owlCarousel({\r\n margin: 0,\r\n responsive: this.config.itemsOnScreen,\r\n dots: this.config.dots,\r\n nav: this.config.nav,\r\n dotsContainer: '#owl-carousel-custom-dots',\r\n navContainer: '#owl-carousel-custom-nav',\r\n navText: [\r\n ``,\r\n ``\r\n ],\r\n autoplay: this.config.autoplay,\r\n autoplayTimeout: this.config.autoplayTimeout,\r\n autoplayHoverPause: this.config.autoplayHoverPause,\r\n loop: this.config.loop\r\n });\r\n $('.owl-dots').on('click', 'li', function (e: any) {\r\n // @ts-ignore\r\n owl.trigger('to.owl.carousel', [$(this).index(), 300]);\r\n });\r\n }\r\n\r\n\r\n private setAriaLabels() {\r\n const dots = this.elementRef.nativeElement.querySelectorAll('.owl-dot');\r\n dots.forEach((dot: HTMLButtonElement, index: number) => {\r\n dot.setAttribute('aria-label', this.trans('global.goToPage') + (index + 1));\r\n });\r\n }\r\n\r\n getLink(url: string): string {\r\n return url?.length > 3 && url.substr(0, 3) === 'www' ? `//${url}` : url\r\n }\r\n\r\n ngAfterViewChecked() {\r\n const carousel = $('.owl-carousel');\r\n if (carousel.length > 0 && !this.isCarouselInit) {\r\n setTimeout(() => {\r\n this.initCarousel();\r\n this.setAriaLabels();\r\n });\r\n this.isCarouselInit = true;\r\n }\r\n }\r\n}\r\n","\r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n\r\n\r\n","import {Component, Input} from '@angular/core';\r\n\r\n@Component({\r\n selector: 'shared-heading-section',\r\n templateUrl: './heading-section.component.html',\r\n styleUrls: ['./heading-section.component.scss']\r\n})\r\nexport class HeadingSectionComponent {\r\n @Input() number: number = 0;\r\n @Input() subtitle: string = '';\r\n @Input() title: string;\r\n @Input() innerColor: boolean = false;\r\n @Input() hsClass: string;\r\n\r\n}\r\n","\r\n \r\n {{ title }}\r\n \r\n - {{subtitle}}\r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { HeadingSectionComponent } from './components/heading-section/heading-section.component';\r\nimport {PolygonModule} from '@app/template/elements/polygon/polygon.module';\r\n\r\n@NgModule({\r\n declarations: [\r\n HeadingSectionComponent\r\n ],\r\n exports: [\r\n HeadingSectionComponent\r\n ],\r\n imports: [\r\n CommonModule,\r\n PolygonModule\r\n ]\r\n})\r\nexport class HeadingModule { }\r\n","import { Component, Input } from '@angular/core';\r\nimport { NgbActiveModal } from '@ng-bootstrap/ng-bootstrap';\r\nimport { ImageZoom } from '@app/template/elements/image-zoom/interfaces/image-zoom.interface';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\n\r\n@Component({\r\n selector: 'app-image-zoom',\r\n templateUrl: './image-zoom.component.html'\r\n})\r\nexport class ImageZoomComponent extends ComponentHelper {\r\n @Input() public data: ImageZoom;\r\n public loading: boolean = true;\r\n public placeholder: boolean = false;\r\n\r\n constructor(private activeModal: NgbActiveModal) {\r\n super();\r\n }\r\n\r\n public close() {\r\n this.activeModal.close();\r\n }\r\n\r\n public onLoad() {\r\n this.loading = false;\r\n }\r\n\r\n public onError() {\r\n this.onLoad();\r\n this.placeholder = true;\r\n }\r\n}\r\n","\r\n {{data.alt}}\r\n \r\n {{'x'}}\r\n \r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { ImageZoomComponent } from '@app/template/elements/image-zoom/components/image-zoom/image-zoom.component';\r\nimport { ProgressBarModule } from '@share/modules/progress-bar/progress-bar.module';\r\nimport { CommonModule } from '@angular/common';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n ProgressBarModule\r\n ],\r\n declarations: [\r\n ImageZoomComponent\r\n ],\r\n exports: [\r\n ImageZoomComponent\r\n ],\r\n entryComponents: [\r\n ImageZoomComponent\r\n ]\r\n})\r\nexport class ImageZoomModule {}\r\n","import { Component, Input } from '@angular/core';\r\nimport { ControlValueAccessor, NgControl } from '@angular/forms';\r\n\r\n@Component({\r\n selector: 'app-input',\r\n templateUrl: 'input.component.html',\r\n styleUrls: ['input.component.scss']\r\n})\r\nexport class InputComponent implements ControlValueAccessor {\r\n\r\n @Input() label: string;\r\n @Input() id: string;\r\n\r\n private onChange: (v: string) => void = (v: string) => {};\r\n private onTouch: () => void = () => {};\r\n\r\n value: string;\r\n\r\n constructor(private ngControl: NgControl) {\r\n this.ngControl.valueAccessor = this;\r\n }\r\n\r\n registerOnChange(fn: any): void {\r\n this.onChange = fn;\r\n }\r\n\r\n registerOnTouched(fn: any): void {\r\n this.onTouch = fn;\r\n }\r\n\r\n writeValue(obj: any): void {\r\n this.value = obj;\r\n this.onChange(obj);\r\n }\r\n}\r\n","\r\n \r\n {{ label }}\r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { InputComponent } from '@app/template/elements/input/input.component';\r\nimport { FormsModule } from '@angular/forms';\r\n\r\n@NgModule({\r\n declarations: [InputComponent],\r\n exports: [InputComponent],\r\n imports: [CommonModule, FormsModule]\r\n})\r\nexport class InputModule {}\r\n","import { Component, EventEmitter, Input, Output } from '@angular/core';\r\nimport { PaginationService } from '../../services/pagination.service';\r\n\r\n@Component({\r\n selector: 'shared-pagination',\r\n templateUrl: './pagination.component.html',\r\n styleUrls: ['./pagination.component.scss'],\r\n})\r\nexport class PaginationComponent {\r\n\r\n @Input() public perPage: number = 10;\r\n @Input() public pages: number = 1;\r\n @Input() public position: 'left' | 'right' = 'right';\r\n @Output() readonly changed: EventEmitter = new EventEmitter();\r\n\r\n constructor(private paginationService: PaginationService) {}\r\n\r\n\r\n public get total(): number {\r\n return this.perPage * this.pages;\r\n }\r\n\r\n public set currentPage(value: number) {\r\n this.paginationService.page = value;\r\n this.changed.emit(value);\r\n }\r\n\r\n public get currentPage(): number {\r\n return this.paginationService.page;\r\n }\r\n\r\n\r\n}\r\n"," 1\">\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n {{'...'}}\r\n {{ currentPage }}\r\n \r\n \r\n \r\n\r\n","import {NgModule} from '@angular/core';\r\nimport {CommonModule} from '@angular/common';\r\nimport {PaginationComponent} from './components/pagination/pagination.component';\r\nimport {NgbPaginationModule} from '@ng-bootstrap/ng-bootstrap';\r\nimport {PaginationService} from './services/pagination.service';\r\n\r\n@NgModule({\r\n declarations: [\r\n PaginationComponent\r\n ],\r\n imports: [\r\n CommonModule,\r\n NgbPaginationModule\r\n ],\r\n exports: [\r\n PaginationComponent\r\n ],\r\n providers: [\r\n PaginationService\r\n ]\r\n})\r\nexport class PaginationModule {}\r\n","import { Injectable } from '@angular/core';\r\nimport { BehaviorSubject, Observable, Subscription } from 'rxjs';\r\nimport { ComponentShareHelper } from '@share/common/helpers/component-share.helper';\r\nimport { FacadeShareService } from '@share/common/services/facade-share.service';\r\nimport { ActivatedRoute, Params } from '@angular/router';\r\n\r\n@Injectable()\r\nexport class PaginationService extends ComponentShareHelper {\r\n private firstPage: number = 1;\r\n private _page: BehaviorSubject = new BehaviorSubject(this.firstPage);\r\n\r\n constructor(private facadeShareService: FacadeShareService,\r\n private activatedRoute: ActivatedRoute) {\r\n super(facadeShareService);\r\n this.setParamsListener();\r\n }\r\n\r\n public setParamsListener() {\r\n return this.activatedRoute.queryParams.subscribe((params: Params) => {\r\n if (params.page) {\r\n this.page = parseInt(params.page, 10);\r\n } else {\r\n this._page.next(this.firstPage);\r\n }\r\n });\r\n }\r\n\r\n private changeQueryParams(value: number) {\r\n setTimeout(() => {\r\n this.facadeShareService.router.navigate([], {\r\n relativeTo: this.activatedRoute,\r\n queryParams: {page: value === this.firstPage ? null : value}\r\n });\r\n });\r\n }\r\n\r\n public set page(value: number) {\r\n if (value !== this.page) {\r\n this._page.next(value);\r\n this.changeQueryParams(value);\r\n }\r\n }\r\n\r\n public get page(): number {\r\n return this._page.getValue();\r\n }\r\n\r\n public get currentPage(): Observable {\r\n return this._page.asObservable();\r\n }\r\n}\r\n","import { Component, Input } from '@angular/core';\r\nimport { UtilsService } from '@share/common/services/utils.service';\r\n\r\n@Component({\r\n selector: 'shared-hexagon-content',\r\n templateUrl: './hexagon-content.component.html',\r\n styleUrls: ['./hexagon-content.component.scss']\r\n})\r\nexport class HexagonContentComponent {\r\n @Input() bgColor: string;\r\n @Input() borderColor: string;\r\n @Input() borderWidth: number = 0;\r\n @Input() width: number = 100;\r\n @Input() height: number = 100;\r\n @Input() isInnerShadow: boolean = false;\r\n @Input() innerShadowConfig: { alpha: number, blur: number } = {alpha: 0.3, blur: 2};\r\n @Input() isOuterShadow: boolean = false;\r\n @Input() isHover: boolean = false;\r\n @Input() bgGradient: boolean = false;\r\n @Input() borderGradient: boolean = false;\r\n @Input() edgeRounded: boolean = false;\r\n @Input() bgImage: string = '';\r\n\r\n public innerShadowID: string = '';\r\n\r\n constructor(private utils: UtilsService) {\r\n this.innerShadowID = this.utils.makeId();\r\n }\r\n\r\n public get location() {\r\n return window.location.href;\r\n }\r\n\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport {HexagonContentComponent} from './components/hexagon-content/hexagon-content.component';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule\r\n ],\r\n declarations: [\r\n HexagonContentComponent\r\n ],\r\n exports: [\r\n HexagonContentComponent\r\n ]\r\n})\r\nexport class PolygonModule {\r\n}\r\n","import { Component, Input, ViewEncapsulation } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'app-promoted-item-icon',\r\n styleUrls: ['promoted-item-icon.component.scss'],\r\n templateUrl: 'promoted-item-icon.component.html',\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class PromotedItemIconComponent {\r\n\r\n @Input() icon: string;\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n\r\n","import { Component, ElementRef, EventEmitter, Input, OnDestroy, Output, Renderer2 } from '@angular/core';\r\nimport { Promoted } from '../../models/promoted.model';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { AbstractData } from '@share/common/models/http';\r\n\r\n@Component({\r\n selector: 'app-promoted-list',\r\n templateUrl: './promoted-list.component.html',\r\n styleUrls: [`./promoted-list.component.scss`]\r\n})\r\nexport class PromotedListComponent extends ComponentHelper implements OnDestroy {\r\n @Input() data: Array>;\r\n\r\n @Input() filter: string;\r\n @Input() height: number = 420;\r\n @Input() background?: string = '';\r\n @Input() hasIcon: boolean = false;\r\n @Output() readonly clicked: EventEmitter = new EventEmitter();\r\n private listenClickFunc: Function;\r\n\r\n constructor(private renderer: Renderer2, private _elementRef: ElementRef) {\r\n super();\r\n this.onClickListener();\r\n }\r\n\r\n private onClickListener(): void {\r\n this.listenClickFunc = this.renderer.listen(this._elementRef.nativeElement, 'click', event =>\r\n this.shareService.utils.navigateTo(event)\r\n );\r\n }\r\n\r\n public imagePath(path: string) {\r\n return this.shareService.image.img({ file: path, filter: this.filter });\r\n }\r\n\r\n public navigateTo(event: Event, url: string, id: string) {\r\n event.preventDefault();\r\n event.stopPropagation();\r\n window.open(url);\r\n this.onClick(id);\r\n }\r\n\r\n public onClick(slug: string) {\r\n this.clicked.emit(slug);\r\n }\r\n\r\n public ngOnDestroy() {\r\n this.listenClickFunc();\r\n }\r\n\r\n public get dataExists(): boolean {\r\n return Array.isArray(this.data) && this.data.length > 0;\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n {{ promoted.attributes.title | truncate: 50 }}\r\n \r\n {{'global.findOutMore' | trans}}\r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { PolygonModule } from '../polygon/polygon.module';\r\nimport { PromotedListComponent } from './components/promoted-list/promoted-list.component';\r\nimport { CommonModule } from '@angular/common';\r\nimport { RouterModule } from '@angular/router';\r\nimport { TruncateModule } from '@share/modules/truncate/truncate.module';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { PromotedItemIconComponent } from './components/promoted-item-icon/promoted-item-icon.component';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\n\r\n@NgModule({\r\n declarations: [\r\n PromotedListComponent,\r\n PromotedItemIconComponent\r\n ],\r\n imports: [\r\n CommonModule,\r\n RouterModule,\r\n PolygonModule,\r\n TruncateModule,\r\n ElementsModule,\r\n TranslatorModule\r\n ],\r\n exports: [\r\n PromotedListComponent\r\n ]\r\n})\r\nexport class PromotedModule {\r\n}\r\n","import { ChangeDetectionStrategy, Component, OnInit } from '@angular/core';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { PagesService } from '@app/common/services/pages.service';\r\nimport { first } from 'rxjs/operators';\r\n\r\n@Component({\r\n selector: 'app-simple-box',\r\n styleUrls: ['simple-box.component.scss'],\r\n templateUrl: 'simple-box.component.html',\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class SimpleBoxComponent implements OnInit {\r\n data: {\r\n button: string;\r\n contactBoxIcon: string;\r\n contactPage: string;\r\n content: string;\r\n title: string;\r\n };\r\n\r\n constructor(private facadeService: FacadeService, private pageService: PagesService) {}\r\n\r\n ngOnInit() {\r\n this.data = this.facadeService.settings.variables.contactBox;\r\n }\r\n\r\n onButtonClick() {\r\n this.pageService\r\n .getOne(this.data.contactPage)\r\n .pipe(first())\r\n .subscribe(page => this.facadeService.router.navigate([page.data.id.replace(',', '/')]));\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n\r\n {{ data.title }}\r\n {{ data.content }}\r\n \r\n\r\n \r\n\r\n \r\n\r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { SimpleBoxComponent } from '@app/template/elements/simple-box/components/simple-box.component';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { CommonModule } from '@angular/common';\r\n\r\n@NgModule({\r\n declarations: [SimpleBoxComponent],\r\n imports: [\r\n ElementsModule,\r\n CommonModule\r\n ],\r\n exports: [SimpleBoxComponent]\r\n})\r\nexport class SimpleBoxModule {\r\n\r\n}\r\n","import { Component, Input } from '@angular/core';\r\nimport { ControlValueAccessor, NgControl } from '@angular/forms';\r\n\r\n@Component({\r\n selector: 'app-textarea',\r\n templateUrl: 'textarea.component.html',\r\n styleUrls: ['textarea.component.scss']\r\n})\r\nexport class TextareaComponent implements ControlValueAccessor {\r\n\r\n @Input() label: string;\r\n @Input() id: string;\r\n\r\n private onChange: (v: string) => void = (v: string) => {};\r\n private onTouch: () => void = () => {};\r\n\r\n value: string;\r\n\r\n constructor(private ngControl: NgControl) {\r\n this.ngControl.valueAccessor = this;\r\n }\r\n\r\n registerOnChange(fn: any): void {\r\n this.onChange = fn;\r\n }\r\n\r\n registerOnTouched(fn: any): void {\r\n this.onTouch = fn;\r\n }\r\n\r\n writeValue(obj: any): void {\r\n this.value = obj;\r\n this.onChange(obj);\r\n }\r\n}\r\n","\r\n \r\n {{ label }}\r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { TextareaComponent } from './textarea.component';\r\nimport { CommonModule } from '@angular/common';\r\nimport { FormsModule } from '@angular/forms';\r\n\r\n@NgModule({\r\n imports: [CommonModule, FormsModule],\r\n declarations: [TextareaComponent],\r\n exports: [TextareaComponent]\r\n})\r\nexport class TextareaModule {}\r\n","import { ChangeDetectionStrategy, Component, Input } from '@angular/core';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { MultiCarousel } from '@app/template/elements/carousel/models/multi-carousel.model';\r\nimport { MultiCarouselConfig } from '@app/template/elements/carousel/models/multi-carousel-config.model';\r\nimport { ImageCropper } from '@app/template/home/models/image-cropper.model';\r\n\r\n@Component({\r\n selector: 'app-gallery',\r\n templateUrl: 'gallery.component.html',\r\n styleUrls: ['gallery.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class GalleryComponent {\r\n config: MultiCarouselConfig = {\r\n dots: false,\r\n nav: true,\r\n itemsOnScreen: {\r\n 0: {\r\n items: 2\r\n },\r\n 700: {\r\n items: 2\r\n },\r\n 800: {\r\n items: 2\r\n },\r\n 1140: {\r\n items: 3\r\n },\r\n 1370: {\r\n items: 4\r\n }\r\n },\r\n autoplayHoverPause: false,\r\n autoplay: false,\r\n autoplayTimeout: 5000,\r\n loop: false\r\n };\r\n\r\n @Input() set data(value: { gallery: AbstractData<{ image: ImageCropper; alt: string }>[] }) {\r\n if (value) {\r\n this.parsedData = value.gallery.map(item => ({\r\n id: item.id,\r\n type: item.type,\r\n attributes: {\r\n file: item.attributes.image.url || (item.attributes.image.croppedUrl as string),\r\n description: item.attributes.alt,\r\n url: '',\r\n isOpenInNewWindow: false\r\n }\r\n }));\r\n }\r\n }\r\n parsedData: Array> = [];\r\n}\r\n","\r\n \r\n \r\n \r\n\r\n\r\n\r\n Galeria\r\n \r\n\r\n\r\n\r\n \r\n \r\n \r\n\r\n","import { ChangeDetectionStrategy, Component, Input } from '@angular/core';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { HomeIntroModel } from '@app/template/home/models/home-intro.model';\r\n\r\n@Component({\r\n selector: 'app-main-banner',\r\n templateUrl: 'main-banner.component.html',\r\n styleUrls: ['main-banner.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class MainBannerComponent {\r\n\r\n @Input() data: HomeIntroModel;\r\n\r\n constructor(private facadeService: FacadeService) {\r\n }\r\n\r\n scrollDown() {\r\n this.facadeService.scrollTo.animate('#promoted', 800, 100);\r\n }\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { ChangeDetectionStrategy, ChangeDetectorRef, Component, Input, OnChanges, SimpleChanges } from '@angular/core';\r\nimport { ArticlesService } from '@app/client-core/article/services/articles.service';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { Article } from '@app/client-core/article/models/article.model';\r\nimport { finalize, first, switchMap } from 'rxjs/operators';\r\nimport { Router } from '@angular/router';\r\nimport { PagesService } from '@app/common/services/pages.service';\r\nimport { DynamicContentService } from '@app/client-core/dynamic-content/service/dynamic-content.service';\r\n\r\n@Component({\r\n selector: 'app-news',\r\n styleUrls: ['news.component.scss'],\r\n templateUrl: 'news.component.html',\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class NewsComponent implements OnChanges {\r\n news: AbstractData[];\r\n loading: boolean;\r\n getError: boolean;\r\n\r\n @Input() data: {\r\n title: string;\r\n subtitle: string;\r\n category: string;\r\n };\r\n\r\n constructor(\r\n private articleService: ArticlesService,\r\n private cdr: ChangeDetectorRef,\r\n private pageService: PagesService,\r\n private router: Router,\r\n private dynamicContentService: DynamicContentService\r\n ) {}\r\n\r\n ngOnChanges(changes: SimpleChanges): void {\r\n if (changes.data.currentValue) {\r\n this.getNews();\r\n }\r\n }\r\n\r\n setLoader(value: boolean) {\r\n this.loading = value;\r\n this.cdr.detectChanges();\r\n }\r\n\r\n test() {\r\n this.pageService.getOne();\r\n }\r\n\r\n getNews() {\r\n this.setLoader(true);\r\n this.pageService\r\n .getOne(this.data.category)\r\n .pipe(\r\n first(),\r\n finalize(() => this.setLoader(false))\r\n )\r\n .subscribe(\r\n response => this.getMetadata(response.data.id),\r\n error => (this.getError = true)\r\n );\r\n }\r\n\r\n getMetadata(url: string) {\r\n this.dynamicContentService\r\n .getPageMetadata(url)\r\n .pipe(switchMap(metadata => this.articleService.getList(1, 4, metadata.meta?.objectId)))\r\n .subscribe(news => {\r\n this.news = news.data;\r\n this.cdr.detectChanges();\r\n });\r\n }\r\n\r\n showMoreClicked() {\r\n this.router.navigate(['aktualnosci']);\r\n }\r\n\r\n readMoreClicked(item: AbstractData) {\r\n this.router.navigate(['aktualnosci', item.attributes.slug]);\r\n }\r\n}\r\n","\r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n\r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n\r\n \r\n {{\r\n category.attributes.title\r\n }}\r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n {{ item.attributes.title }}\r\n \r\n \r\n {{ item.attributes.publishedFrom | date: 'shortDate':'':'pl' }}\r\n \r\n \r\n {{ item.attributes.description }}\r\n \r\n \r\n \r\n \r\n\r\n","import {\r\n AfterViewInit,\r\n ChangeDetectionStrategy,\r\n ChangeDetectorRef,\r\n Component,\r\n Input,\r\n OnInit,\r\n ViewChild,\r\n ViewContainerRef\r\n} from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { LazyLoaderService } from '@app/common/services/lazy-loader.service';\r\nimport { ROUTES_PATHS } from '@app/common/constants/routes-paths';\r\nimport { Router } from '@angular/router';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { finalize, first } from 'rxjs/operators';\r\nimport { HomeService } from '@app/template/home/services/home.service';\r\nimport { PagesService } from '@app/common/services/pages.service';\r\nimport { PageModel } from '@app/common/models/page.model';\r\nimport { HomeModel } from '@app/template/home/models/home.model';\r\n\r\n@Component({\r\n selector: 'app-home',\r\n templateUrl: './overlay.component.html',\r\n styleUrls: ['./overlay.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class OverlayComponent extends ComponentHelper implements OnInit, AfterViewInit {\r\n @ViewChild('businessModules', { read: ViewContainerRef }) businessModules: ViewContainerRef;\r\n @Input() data: AbstractData>;\r\n loading: boolean = true;\r\n\r\n constructor(\r\n private settingsService: SettingsService,\r\n private lazyLoaderService: LazyLoaderService,\r\n private pagesService: PagesService,\r\n private router: Router,\r\n private cdr: ChangeDetectorRef,\r\n private homeService: HomeService\r\n ) {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n this.service.scrollTo.resetScrollTop();\r\n }\r\n\r\n private setLoading(value: boolean) {\r\n this.loading = value;\r\n this.cdr.markForCheck();\r\n }\r\n\r\n getMainPage() {\r\n this.setLoading(true);\r\n this.pagesService\r\n .getOne()\r\n .pipe(\r\n first(),\r\n finalize(() => this.setLoading(false))\r\n )\r\n .subscribe(\r\n response => {\r\n this.data = response.data;\r\n },\r\n () => {\r\n this.router.navigate(['/', ROUTES_PATHS.notFoundPage.root]);\r\n }\r\n );\r\n }\r\n\r\n ngAfterViewInit() {\r\n if (!this.data) {\r\n this.getMainPage();\r\n } else {\r\n this.loading = false;\r\n this.homeService.isHomePreview = true;\r\n }\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n\r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { ChangeDetectionStrategy, ChangeDetectorRef, Component, Input, OnInit } from '@angular/core';\r\nimport { PromotedService } from '@app/template/home/services/promoted.service';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { Promoted } from '@app/template/elements/promoted/models/promoted.model';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { finalize, first } from 'rxjs/operators';\r\n\r\n@Component({\r\n selector: 'app-promoted',\r\n templateUrl: './promoted.component.html',\r\n styleUrls: ['./promoted.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class PromotedComponent extends ComponentHelper implements OnInit {\r\n @Input() data: { title: string; subtitle: string };\r\n promoted: Array> = [];\r\n loading: boolean = false;\r\n\r\n constructor(private promotedService: PromotedService, private cdr: ChangeDetectorRef) {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n this.loadPromoted();\r\n }\r\n\r\n loadPromoted() {\r\n this.setLoading(true);\r\n this.promotedService\r\n .getList()\r\n .pipe(\r\n first(),\r\n finalize(() => this.setLoading(false))\r\n )\r\n .subscribe(\r\n response => (this.promoted = this.getResponseData(response)),\r\n () => this.setComponentError()\r\n );\r\n }\r\n\r\n private setLoading(value: boolean) {\r\n this.loading = value;\r\n this.cdr.markForCheck();\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { ChangeDetectionStrategy, Component, Input } from '@angular/core';\r\nimport { HomeReportCrashModel } from '@app/template/home/models/home-report-crash.model';\r\n\r\n@Component({\r\n selector: 'app-report-crash',\r\n templateUrl: 'report-crash.component.html',\r\n styleUrls: ['report-crash.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class ReportCrashComponent {\r\n @Input() data: HomeReportCrashModel;\r\n}\r\n","\r\n \r\n \r\n \r\n {{ data?.title }}\r\n {{ data?.content }}\r\n \r\n \r\n \r\n \r\n \r\n {{ data?.contactOne?.title }}\r\n \r\n \r\n {{ data?.contactOne.phone }}\r\n \r\n \r\n \r\n {{ data?.contactOne.officeHours }}\r\n \r\n \r\n \r\n {{ data?.contactTwo?.title }}\r\n \r\n \r\n \r\n {{ data?.contactTwo?.phone }}\r\n \r\n \r\n \r\n \r\n {{ data?.contactTwo?.officeHours }}\r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { ChangeDetectionStrategy, ChangeDetectorRef, Component, Input, OnChanges, SimpleChanges } from '@angular/core';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { PagesService } from '@app/common/services/pages.service';\r\nimport { finalize, first } from 'rxjs/operators';\r\nimport { Router } from '@angular/router';\r\n\r\n@Component({\r\n selector: 'app-schedule',\r\n templateUrl: 'schedule.component.html',\r\n styleUrls: ['schedule.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class ScheduleComponent implements OnChanges {\r\n @Input() data: {\r\n title: string;\r\n subtitle: string;\r\n pageId: string;\r\n };\r\n\r\n scheduleElements: {\r\n boxTitle: string;\r\n boxSubtitle: string;\r\n boxPhone: string;\r\n schedule: { cities: string; date: string }[];\r\n };\r\n\r\n url: string;\r\n\r\n constructor(private pageService: PagesService, private cdr: ChangeDetectorRef, private router: Router) {}\r\n\r\n ngOnChanges(changes: SimpleChanges): void {\r\n if (changes.data.currentValue.pageId) {\r\n this.pageService\r\n .getOne(changes.data.currentValue.pageId)\r\n .pipe(\r\n first(),\r\n finalize(() => this.cdr.detectChanges())\r\n )\r\n .subscribe(e => {\r\n this.url = e.data.id.replace(',', '/');\r\n this.scheduleElements = e.data.attributes.content.content;\r\n this.scheduleElements.schedule = this.scheduleElements.schedule.filter(\r\n (item: any, index: number) => index < 4\r\n );\r\n });\r\n }\r\n }\r\n\r\n redirectToMore() {\r\n this.router.navigate([this.url]);\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n\r\n\r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n\r\n\r\n \r\n \r\n \r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n {{ title }}\r\n \r\n \r\n {{ text }}\r\n \r\n \r\n \r\n {{ phone }}\r\n \r\n \r\n\r\n\r\n \r\n {{ item.date }}\r\n {{ item.cities }}\r\n \r\n\r\n","export enum SitemapLoaders {\r\n GetAll = 'GetAll'\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { OverlayComponent } from '@app/template/home/components/overlay/overlay.component';\r\nimport { SearchModule } from '@app/client-core/search/search.module';\r\nimport { PromotedComponent } from '@app/template/home/components/promoted/promoted.component';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { CarouselModule } from '@app/template/elements/carousel/carousel.module';\r\nimport { LogoModule } from '@app/template/layout/modules/logo/logo.module';\r\nimport { TruncateModule } from '@share/modules/truncate/truncate.module';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { RouterModule } from '@angular/router';\r\nimport { SelectModule } from '@share/modules/html/select/select.module';\r\nimport { FormsModule } from '@angular/forms';\r\nimport { NgbCarouselModule, NgbPaginationModule } from '@ng-bootstrap/ng-bootstrap';\r\nimport { HeadingModule } from '@app/template/elements/heading/heading.module';\r\nimport { PromotedModule } from '@app/template/elements/promoted/promoted.module';\r\nimport { PolygonModule } from '@app/template/elements/polygon/polygon.module';\r\nimport { AccordionModule } from '@app/template/elements/accordion/accordion.module';\r\nimport { PaginationModule } from '@app/template/elements/pagination/pagination.module';\r\nimport { MainBannerComponent } from '@app/template/home/components/main-banner/main-banner.component';\r\nimport { ReportCrashComponent } from '@app/template/home/components/report-crash/report-crash.component';\r\nimport { ScheduleComponent } from '@app/template/home/components/schedule/schedule.component';\r\nimport { NewsComponent } from '@app/template/home/components/news/news.component';\r\nimport { GalleryComponent } from '@app/template/home/components/gallery/gallery.component';\r\nimport { SimpleBoxModule } from '@app/template/elements/simple-box/simple-box.module';\r\nimport { ArticleModule } from '@app/client-core/article/article.module';\r\n\r\n@NgModule({\r\n declarations: [\r\n GalleryComponent,\r\n NewsComponent,\r\n ScheduleComponent,\r\n ReportCrashComponent,\r\n MainBannerComponent,\r\n OverlayComponent,\r\n PromotedComponent,\r\n ],\r\n imports: [\r\n CommonModule,\r\n SearchModule,\r\n CarouselModule,\r\n ElementsModule,\r\n LogoModule,\r\n RouterModule,\r\n NgbCarouselModule,\r\n NgbPaginationModule,\r\n PromotedModule,\r\n SelectModule,\r\n FormsModule,\r\n TranslatorModule,\r\n PolygonModule,\r\n TruncateModule,\r\n AccordionModule,\r\n PaginationModule,\r\n HeadingModule,\r\n SimpleBoxModule,\r\n ArticleModule\r\n ],\r\n exports: [OverlayComponent]\r\n})\r\nexport class HomeModule {}\r\n","import { Injectable } from '@angular/core';\r\nimport { BehaviorSubject, Observable } from 'rxjs';\r\nimport { distinctUntilChanged } from 'rxjs/operators';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class HomeService {\r\n private _isHomePreview: BehaviorSubject = new BehaviorSubject(false);\r\n isHomePreview$: Observable = this._isHomePreview.asObservable().pipe(distinctUntilChanged());\r\n\r\n set isHomePreview(value: boolean) {\r\n this._isHomePreview.next(value);\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { ServiceHelper } from '@share/common/helpers/service.helper';\r\nimport { Bundle } from '@app/common/enums/server-bundles.enum';\r\nimport { Observable } from 'rxjs';\r\nimport { ResponseArray } from '@share/common/models/http.model';\r\nimport { API } from '@app/common/constants/api.directories';\r\nimport { Promoted } from '@app/template/elements/promoted/models/promoted.model';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class PromotedService extends ServiceHelper {\r\n constructor() {\r\n super(Bundle.Promoted);\r\n }\r\n\r\n public getList(): Observable> {\r\n return this.getAll(API.PROMOTED.ROOT);\r\n }\r\n}\r\n","import {Injectable} from '@angular/core';\r\nimport {ServiceHelper} from '@share/common/helpers/service.helper';\r\nimport {Bundle} from '@app/common/enums/server-bundles.enum';\r\nimport {Observable} from 'rxjs';\r\nimport {MenuModel} from '@app/client-core/menu/models/menu.model';\r\nimport {ResponseArray} from '@share/common/models/http';\r\nimport {API} from '@app/common/constants/api.directories';\r\nimport { ApiService } from '@app/common/services/api.service';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class SitemapService {\r\n\r\n constructor(private apiService: ApiService) {}\r\n\r\n getInstitutionData(): Observable {\r\n return this.apiService.get('institution');\r\n }\r\n\r\n public getList(): Observable> {\r\n return this.apiService.getAll(API.MENU.SITEMAP);\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { BreadcrumbsService } from '@app/template/layout/modules/header/services/breadcrumbs.service';\r\nimport { SubheaderService } from '@app/template/layout/modules/header/services/subheader.service';\r\nimport { Observable, of } from 'rxjs';\r\nimport { DynamicContentService } from '@app/client-core/dynamic-content/service/dynamic-content.service';\r\nimport { filter, takeUntil } from 'rxjs/operators';\r\nimport { NavigationEnd } from '@angular/router';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { SearchService } from '@app/client-core/search/services/search.service';\r\n\r\n@Component({\r\n selector: 'app-default',\r\n templateUrl: './default.component.html',\r\n styleUrls: ['./default.component.scss']\r\n})\r\nexport class DefaultComponent extends ComponentHelper {\r\n isHome: boolean = true;\r\n backdrop$: Observable;\r\n constructor(\r\n private breadcrumbsService: BreadcrumbsService,\r\n private subheaderService: SubheaderService,\r\n private settings: SettingsService,\r\n private dynamicContentService: DynamicContentService,\r\n private searchService: SearchService\r\n ) {\r\n super();\r\n this.setHome();\r\n this.backdrop$ = searchService.isActive$;\r\n }\r\n\r\n get contentLoaded(): Observable {\r\n return this.dynamicContentService.loaded$;\r\n }\r\n\r\n public deactivate() {\r\n this.breadcrumbsService.clear.next(true);\r\n this.subheaderService.reset();\r\n }\r\n\r\n private setHome() {\r\n this.service.router.events\r\n .pipe(\r\n filter((e): e is NavigationEnd => e instanceof NavigationEnd),\r\n takeUntil(this.destroyed$)\r\n )\r\n .subscribe(event => {\r\n this.isHome = event.url === '/';\r\n });\r\n }\r\n\r\n get canShow(): Observable {\r\n if (this.isHome) {\r\n return this.contentLoaded;\r\n }\r\n return of(true);\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { DefaultComponent } from './components/default/default.component';\r\nimport { HeaderModule } from '@app/template/layout/modules/header/header.module';\r\nimport { FooterModule } from '@app/template/layout/modules/footer/footer.module';\r\nimport { CookiesModule } from '@app/client-core/cookies/cookies.module';\r\nimport { DynamicContentModule } from '@app/client-core/dynamic-content/dynamic-content.module';\r\nimport { AppRoutingModule } from '@app/app-routing.module';\r\nimport { HomeModule } from '@app/template/home/home.module';\r\nimport { SiteMapModule } from '@app/template/layout/modules/sitemap/sitemap.module';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { PolygonModule } from '@app/template/elements/polygon/polygon.module';\r\n\r\n@NgModule({\r\n declarations: [DefaultComponent],\r\n imports: [\r\n CommonModule,\r\n HeaderModule,\r\n HomeModule,\r\n FooterModule,\r\n CookiesModule,\r\n DynamicContentModule,\r\n SiteMapModule,\r\n AppRoutingModule,\r\n ElementsModule,\r\n PolygonModule\r\n ]\r\n})\r\nexport class LayoutModule {}\r\n","import { NgModule } from '@angular/core';\r\nimport { BreadcrumbsComponent } from '@app/template/layout/modules/breadcrumbs/components/breadcrumbs/breadcrumbs.component';\r\nimport { CommonModule } from '@angular/common';\r\nimport { RouterModule } from '@angular/router';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\n\r\n@NgModule({\r\n declarations: [\r\n BreadcrumbsComponent\r\n ],\r\n imports: [\r\n CommonModule,\r\n RouterModule,\r\n TranslatorModule\r\n ],\r\n exports: [\r\n BreadcrumbsComponent\r\n ]\r\n})\r\nexport class BreadcrumbsModule {}\r\n","import { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { ChangeDetectorRef, Component, EventEmitter, OnInit, Output } from '@angular/core';\r\nimport { BreadcrumbsService } from '@app/template/layout/modules/header/services/breadcrumbs.service';\r\nimport { BreadcrumbsLoaders } from '@app/template/layout/modules/header/enums/breadcrumbs-loaders.enum';\r\nimport { Breadcrumbs } from '@app/template/layout/modules/header/models/breadcrumbs.model';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { AbstractData } from '@share/common/models/http';\r\n\r\n@Component({\r\n selector: 'app-breadcrumbs',\r\n templateUrl: './breadcrumbs.component.html',\r\n styleUrls: ['./breadcrumbs.component.scss']\r\n})\r\nexport class BreadcrumbsComponent extends ComponentHelper implements OnInit {\r\n public breadcrumbs: Array> = [];\r\n public shortVersion: boolean = false;\r\n public minLengthForShortVersion: number = 3;\r\n\r\n @Output() readonly loaded: EventEmitter = new EventEmitter();\r\n\r\n constructor(private breadcrumbsService: BreadcrumbsService, private cdr: ChangeDetectorRef) {\r\n super();\r\n }\r\n\r\n public get breadcrumbsExists(): boolean {\r\n return Array.isArray(this.breadcrumbs) && this.breadcrumbs.length > 0;\r\n }\r\n\r\n public ngOnInit() {\r\n this.setReloadListener();\r\n this.setClearListener();\r\n }\r\n\r\n private loadBreadcrumbs() {\r\n this.setLoader(BreadcrumbsLoaders.Get, true);\r\n this.subscriptions.add(\r\n this.breadcrumbsService.getList(this.url).subscribe(\r\n response => {\r\n this.breadcrumbs = this.getResponseData(response);\r\n this.shortVersion = this.breadcrumbs.length > this.minLengthForShortVersion;\r\n this.cdr.detectChanges();\r\n this.loaded.emit();\r\n },\r\n () => {}\r\n )\r\n );\r\n }\r\n\r\n private setReloadListener() {\r\n this.breadcrumbsService.reload.pipe(takeUntil(this.destroyed$)).subscribe(reload => {\r\n if (reload && !this.breadcrumbsService.forceActive) {\r\n this.breadcrumbsService.customBreadcrumbs = [];\r\n this.loadBreadcrumbs();\r\n this.cdr.detectChanges();\r\n }\r\n });\r\n }\r\n\r\n private setClearListener() {\r\n this.breadcrumbsService.clear.pipe(takeUntil(this.destroyed$)).subscribe(clear => {\r\n if (clear) {\r\n this.breadcrumbs = [];\r\n this.cdr.detectChanges();\r\n this.breadcrumbsService.clear.next(false);\r\n }\r\n });\r\n }\r\n\r\n public get customBreadcrumbs(): Array<{ title: string; url?: string }> {\r\n return this.breadcrumbsService.customBreadcrumbs;\r\n }\r\n\r\n private get url(): string {\r\n return this.breadcrumbsService.getParsedUrl(this.service.router.url);\r\n }\r\n\r\n public getLink(index: number): Array {\r\n const segments = this.breadcrumbsService.generateLink(this.breadcrumbs, index);\r\n\r\n if (segments.length > 1) {\r\n return [...segments];\r\n }\r\n\r\n return ['/'];\r\n }\r\n\r\n public expandBreadcrumbs(event: Event) {\r\n event.preventDefault();\r\n this.shortVersion = false;\r\n this.cdr.detectChanges();\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n {{breadcrumb.attributes.title}}\r\n {{breadcrumb.attributes.title}}\r\n \r\n \r\n {{breadcrumb.attributes.title}}\r\n \r\n \r\n \r\n \r\n \r\n {{breadcrumbs[0].attributes.title}}\r\n {{breadcrumbs[0].attributes.title}}\r\n \r\n \r\n {{'...'}}\r\n \r\n {{breadcrumbs[breadcrumbs.length - 1].attributes.title}}\r\n \r\n \r\n\r\n\r\n 0\">\r\n \r\n \r\n \r\n \r\n {{customBreadcrumb.title}}\r\n \r\n \r\n {{customBreadcrumb.title}}\r\n \r\n \r\n \r\n \r\n \r\n\r\n","import {Component, Input, OnInit} from '@angular/core';\r\n\r\n@Component({\r\n selector: 'app-container',\r\n templateUrl: './container.component.html',\r\n styles: []\r\n})\r\nexport class ContainerComponent implements OnInit {\r\n\r\n @Input() public top: number = 30;\r\n @Input() public bottom: number = 30;\r\n @Input() public left: number = 0;\r\n @Input() public right: number = 0;\r\n\r\n constructor() { }\r\n\r\n ngOnInit() {\r\n }\r\n\r\n}\r\n","\r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport {ContainerComponent} from '@app/template/layout/modules/container/components/container/container.component';\r\n\r\n@NgModule({\r\n declarations: [\r\n ContainerComponent\r\n ],\r\n imports: [\r\n CommonModule\r\n ],\r\n exports: [\r\n ContainerComponent\r\n ]\r\n})\r\nexport class ContainerModule { }\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\n\r\n@Component({\r\n selector: 'app-fatal-error',\r\n templateUrl: './fatal-error.component.html',\r\n styleUrls: ['./fatal-error.component.scss']\r\n})\r\nexport class FatalErrorComponent extends ComponentHelper implements OnInit {\r\n\r\n constructor() {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n }\r\n\r\n goToHome(): void {\r\n window.location.href = '/';\r\n }\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n {{ '500' }}\r\n {{ 'Błąd serwera' }}\r\n \r\n \r\n \r\n \r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\n\r\n@Component({\r\n selector: 'app-maintenance',\r\n templateUrl: './maintenance.component.html',\r\n styleUrls: ['./maintenance.component.scss']\r\n})\r\nexport class MaintenanceComponent extends ComponentHelper implements OnInit {\r\n\r\n constructor() {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n }\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n {{'global.maintenance' | trans}}\r\n {{'global.maintenanceText' | trans}}.\r\n \r\n \r\n\r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\n\r\n@Component({\r\n selector: 'app-not-found',\r\n templateUrl: './not-found.component.html',\r\n styleUrls: ['./not-found.component.scss']\r\n})\r\nexport class NotFoundComponent extends ComponentHelper implements OnInit {\r\n\r\n constructor() {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n }\r\n\r\n goToHome(): void {\r\n this.service.router.navigate(['']);\r\n }\r\n\r\n}\r\n","\r\n \r\n \r\n {{ '404' }}\r\n {{ 'Nie znaleziono strony' }}\r\n \r\n \r\n \r\n\r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { NotFoundComponent } from './components/not-found/not-found.component';\r\nimport { RouterModule } from '@angular/router';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { MaintenanceComponent } from './components/maintenance/maintenance.component';\r\nimport { FatalErrorComponent } from './components/fatal-error/fatal-error.component';\r\n\r\n@NgModule({\r\n declarations: [NotFoundComponent, MaintenanceComponent, FatalErrorComponent],\r\n imports: [\r\n CommonModule,\r\n RouterModule,\r\n ElementsModule,\r\n TranslatorModule\r\n ],\r\n exports: [\r\n NotFoundComponent,\r\n MaintenanceComponent\r\n ]\r\n})\r\nexport class ErrorPagesModule {\r\n}\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { VersionService } from '@share/common/services/version.service';\r\n\r\n@Component({\r\n selector: 'app-footer',\r\n templateUrl: './footer.component.html',\r\n styleUrls: ['./footer.component.scss']\r\n})\r\nexport class FooterComponent extends ComponentHelper implements OnInit {\r\n public footer: string;\r\n public version: string;\r\n\r\n constructor(private settingsService: SettingsService, private versionService: VersionService) {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n this.footer = this.settingsService.variables.footer.footer;\r\n }\r\n}\r\n","\r\n","import {NgModule} from '@angular/core';\r\nimport {CommonModule} from '@angular/common';\r\nimport {FooterComponent} from './components/footer/footer.component';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\n\r\n@NgModule({\r\n declarations: [FooterComponent],\r\n imports: [\r\n CommonModule,\r\n TranslatorModule,\r\n ElementsModule\r\n ],\r\n exports: [\r\n FooterComponent\r\n ]\r\n})\r\nexport class FooterModule {\r\n}\r\n","import { ChangeDetectionStrategy, Component } from '@angular/core';\r\n\r\ndeclare let $: any;\r\n\r\n@Component({\r\n selector: 'app-a11y-font-size',\r\n styleUrls: ['a11y-font-size.component.scss'],\r\n templateUrl: 'a11y-font-size.component.html',\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class A11yFontSizeComponent {\r\n constructor() {}\r\n\r\n setDefaultFontSize() {\r\n this.changeFontSize('10px');\r\n }\r\n setBiggerFontSize() {\r\n this.changeFontSize('11px');\r\n }\r\n setBigFontSize() {\r\n this.changeFontSize('12px');\r\n }\r\n\r\n private changeFontSize(size: string) {\r\n $('html').css({\r\n 'font-size': size\r\n });\r\n }\r\n}\r\n","\r\n \r\n \r\n domyślna czcionka\r\n A\r\n \r\n \r\n \r\n \r\n większa czcionka\r\n A\r\n \r\n \r\n \r\n \r\n największa czcionka\r\n A\r\n \r\n \r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { GoogleTranslateService } from '@app/common/services/google-translate.service';\r\n\r\n@Component({\r\n selector: 'app-google-translator',\r\n templateUrl: './google-translator.component.html',\r\n styleUrls: [\r\n './google-translator.component.scss'\r\n ]\r\n})\r\nexport class GoogleTranslatorComponent implements OnInit {\r\n\r\n constructor(private googleTranslateService: GoogleTranslateService) {}\r\n\r\n public ngOnInit() {\r\n this.googleTranslateService.init();\r\n }\r\n\r\n}\r\n","\r\n","import { AfterViewInit, Component, ElementRef, Inject, OnInit, ViewChild, ViewContainerRef } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { DOCUMENT } from '@angular/common';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { LazyLoaderService } from '@app/common/services/lazy-loader.service';\r\nimport { ThemesEnum } from '@app/common/models/themes.enum';\r\nimport { ResizeListener } from '@app/common/services/resize-listener.service';\r\nimport { SearchService } from '@app/client-core/search/services/search.service';\r\nimport { fromEvent, Observable } from 'rxjs';\r\nimport { MenuService } from '@app/client-core/menu/services/menu.service';\r\nimport { debounceTime, filter, finalize, first, takeUntil, tap } from 'rxjs/operators';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { MenuModel } from '@app/client-core/menu/models/menu.model';\r\n\r\ndeclare let $: Function;\r\n\r\n@Component({\r\n selector: 'app-header',\r\n templateUrl: './header-container.component.html',\r\n styleUrls: [\r\n './header-container.component.scss',\r\n './header-container-contrast.component.scss',\r\n ]\r\n})\r\nexport class HeaderContainerComponent extends ComponentHelper implements OnInit, AfterViewInit {\r\n isAuthenticated: boolean = false;\r\n search: string;\r\n\r\n @ViewChild('alertBtn', { read: ViewContainerRef }) alertBtn: ViewContainerRef;\r\n @ViewChild('menu', { read: ViewContainerRef }) menu: ViewContainerRef;\r\n\r\n private startDistance = 10;\r\n\r\n isMobileSearchActive$: Observable;\r\n isValidDefaultMenuWidth: boolean;\r\n isMobileMenuMode: boolean;\r\n isDefaultMenuWidthChecking: boolean;\r\n isFetchMenuLoading: boolean;\r\n menuData: AbstractData[];\r\n\r\n constructor(\r\n @Inject(DOCUMENT) private document: Document,\r\n private settings: SettingsService,\r\n private loader: LazyLoaderService,\r\n public resizeListener: ResizeListener,\r\n private searchService: SearchService,\r\n private menuService: MenuService,\r\n private _elementRef: ElementRef\r\n ) {\r\n super();\r\n }\r\n\r\n get isSubpage(): boolean {\r\n return !this.service.router.isActive('', true);\r\n }\r\n\r\n get isAlertModuleEnabled(): boolean {\r\n return this.settings.isModuleActive(ThemesEnum.ALERT);\r\n }\r\n\r\n get isMenuModuleEnabled(): boolean {\r\n return this.settings.isModuleActive(ThemesEnum.MENU);\r\n }\r\n\r\n /** Metoda sprawdzająca, czy zawartość menu dla desktop'ów nie wystaje poza szerokość okna/headera. */\r\n get isValidHeaderContentWidth(): boolean {\r\n const contentElementRef: HTMLElement = this.document.querySelector('#main-app-header .content') as HTMLElement;\r\n const contentElementChildren: HTMLElement[] = Array.from(contentElementRef.children) as HTMLElement[];\r\n const contentElementAvailableWidth: number = contentElementRef.offsetWidth\r\n - (parseInt(getComputedStyle(contentElementRef).paddingLeft))\r\n - (parseInt(getComputedStyle(contentElementRef).paddingRight))\r\n - 30 // ScrollBar with small offset.\r\n ;\r\n\r\n let contentChildrenWidth: number = 0;\r\n\r\n contentElementChildren.forEach(child => {\r\n contentChildrenWidth += child.offsetWidth;\r\n });\r\n\r\n return contentChildrenWidth <= contentElementAvailableWidth\r\n }\r\n\r\n ngOnInit() {\r\n this.fetchMenu();\r\n window.addEventListener('scroll', () => this.scroll(), true);\r\n this.scroll();\r\n this.isMobileSearchActive$ = this.searchService.isActive$;\r\n this.searchService.isActive$.pipe(takeUntil(this.destroyed$)).subscribe(isActive => {\r\n if (isActive) {\r\n this.menuService.isMobileMenuActive$.next(false);\r\n }\r\n });\r\n this.handleOutsideClick();\r\n }\r\n\r\n ngAfterViewInit() {\r\n this.generateAlertButton();\r\n this.generateMenu();\r\n }\r\n\r\n private setMenuModeChangeListener() {\r\n this.resizeListener.isMobile$.pipe(\r\n takeUntil(this.destroyed$),\r\n tap((value) => this.isMobileMenuMode = value),\r\n filter((value) => !value),\r\n tap(() => {\r\n this.isDefaultMenuWidthChecking = true;\r\n this.isValidDefaultMenuWidth = true; // Pokazanie menu, aby JS mógł obliczyć szerokość wewnątrz komponentu.\r\n }),\r\n debounceTime(500),\r\n ).subscribe((value) => {\r\n this.setIsMobileMenuMode();\r\n });\r\n }\r\n\r\n private fetchMenu() {\r\n this.isFetchMenuLoading = true;\r\n\r\n this.menuService\r\n .getList()\r\n .pipe(\r\n first(),\r\n finalize(() => this.isFetchMenuLoading = false)\r\n )\r\n .subscribe(\r\n response => {\r\n this.menuData = response.data;\r\n this.setMenuModeChangeListener();\r\n }\r\n );\r\n }\r\n\r\n private setIsMobileMenuMode(): void {\r\n // setTimeout z racji wymaganego opóźnienia przy obliczaniu dostępnej szerokosci.\r\n setTimeout(() => {\r\n this.isValidDefaultMenuWidth = this.isValidHeaderContentWidth;\r\n });\r\n\r\n this.isDefaultMenuWidthChecking = false;\r\n }\r\n\r\n generateAlertButton() {\r\n if (this.alertBtn && this.isAlertModuleEnabled) {\r\n this.loader.load(ThemesEnum.ALERT, this.alertBtn);\r\n }\r\n }\r\n\r\n generateMenu() {\r\n if (this.menu) {\r\n this.menu?.clear();\r\n if (this.isMenuModuleEnabled || this.isAuthenticated) {\r\n this.loader.load(ThemesEnum.MENU, this.menu);\r\n }\r\n }\r\n }\r\n\r\n handleOutsideClick() {\r\n const clickEvent$ = fromEvent(document, 'click');\r\n clickEvent$\r\n .pipe(\r\n takeUntil(this.destroyed$),\r\n filter(e => !this._elementRef.nativeElement.contains(e.target)),\r\n tap(e => {\r\n this.searchService.isActive$.next(false);\r\n })\r\n )\r\n .subscribe();\r\n }\r\n\r\n\r\n private scroll() {\r\n const scrollTop = $(this.document).scrollTop(),\r\n header = $('header');\r\n if (scrollTop >= this.startDistance) {\r\n header.addClass('sticked');\r\n } else {\r\n header.removeClass('sticked');\r\n }\r\n }\r\n\r\n onComponentRefresh() {\r\n this.fetchMenu();\r\n }\r\n}\r\n","\r\n Dolina baryczy\r\n \r\n \r\n \r\n {{ 'global.search' | trans }}\r\n \r\n \r\n \r\n {{ 'global.settings' | trans }}\r\n \r\n \r\n \r\n {{'global.contrast' | trans}}\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { AfterViewInit, Component, OnInit, Renderer2 } from '@angular/core';\r\n\r\ndeclare let $: Function;\r\n\r\n@Component({\r\n selector: 'app-high-contrast',\r\n templateUrl: './high-contrast.component.html',\r\n styleUrls: ['./high-contrast.component.scss']\r\n})\r\nexport class HighContrastComponent implements OnInit, AfterViewInit {\r\n constructor(private renderer: Renderer2) {}\r\n\r\n ngOnInit(): void {}\r\n\r\n ngAfterViewInit(): void {\r\n const contrast: string = localStorage.getItem('contrast') as string;\r\n if (contrast) {\r\n switch (contrast) {\r\n case 'blackwhite':\r\n this.addBlackWhite();\r\n break;\r\n case 'yellowblack':\r\n this.addYellowBlack();\r\n break;\r\n }\r\n }\r\n }\r\n\r\n removeContrast() {\r\n this.renderer.removeClass(document.body, localStorage.getItem('contrast') as string);\r\n this.renderer.setStyle(document.body, 'color', '');\r\n this.renderer.setStyle(document.body, 'background-color', '');\r\n\r\n localStorage.setItem('contrast', 'normal');\r\n }\r\n\r\n addYellowBlack() {\r\n this.removeContrast();\r\n this.renderer.addClass(document.body, 'yellowblack');\r\n\r\n this.renderer.setStyle(document.body, 'background-color', 'black');\r\n this.renderer.setStyle(document.body, 'color', 'yellow');\r\n\r\n localStorage.setItem('contrast', 'yellowblack');\r\n }\r\n\r\n addBlackWhite() {\r\n this.removeContrast();\r\n this.renderer.addClass(document.body, 'blackwhite');\r\n\r\n this.renderer.setStyle(document.body, 'background-color', 'white');\r\n this.renderer.setStyle(document.body, 'color', 'black');\r\n\r\n localStorage.setItem('contrast', 'blackwhite');\r\n }\r\n}\r\n","\r\n \r\n \r\n brak wysokiego kontrastu\r\n A\r\n \r\n \r\n \r\n \r\n czarno-biały\r\n A\r\n \r\n \r\n \r\n \r\n żółto-czarny\r\n A\r\n \r\n \r\n\r\n","export { SubheaderDescriptionComponent } from './subheader/subheader-description/subheader-description.component';\r\nexport { SubheaderTitleComponent } from './subheader/subheader-title/subheader-title.component';\r\nexport { SubheaderComponent } from './subheader/subheader.component';\r\nexport { GoogleTranslatorComponent } from './google-translator/google-translator.component';\r\nexport { HeaderContainerComponent } from './header-container/header-container.component';\r\nexport { LanguageComponent } from './language/language.component';\r\nexport { A11yFontSizeComponent } from './a11y-font-size/a11y-font-size.component';\r\n","import {ComponentHelper} from '@app/common/helpers/component.helper';\r\nimport {Component, ViewEncapsulation} from '@angular/core';\r\n\r\n@Component({\r\n selector: 'app-language',\r\n templateUrl: './language.component.html',\r\n styleUrls: ['./language.component.scss'],\r\n})\r\nexport class LanguageComponent extends ComponentHelper {\r\n\r\n public language: string = 'pl';\r\n\r\n constructor() {\r\n super();\r\n }\r\n\r\n changeLanguage(): void {\r\n alert('TODO');\r\n }\r\n}\r\n","\r\n","import { Component, Input } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'cms-subheader-description',\r\n templateUrl: 'subheader-description.component.html',\r\n styleUrls: ['subheader-description.component.scss']\r\n})\r\nexport class SubheaderDescriptionComponent {\r\n @Input() text: string;\r\n @Input() isMobile: boolean;\r\n}\r\n","{{text}}\r\n","import { Component, ElementRef, EventEmitter, Input, Output, ViewChild } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'cms-subheader-title',\r\n templateUrl: 'subheader-title.component.html',\r\n styleUrls: ['subheader-title.component.scss']\r\n})\r\nexport class SubheaderTitleComponent {\r\n\r\n isEditable: boolean = false;\r\n\r\n @Input() title: string;\r\n @Input() isMobile: boolean;\r\n @Input() set editable(editable: boolean) {\r\n this.isEditable = editable;\r\n setTimeout(() => this.text.nativeElement.focus());\r\n };\r\n\r\n @ViewChild('text') text: ElementRef;\r\n\r\n @Output() onSubmitEditable: EventEmitter = new EventEmitter();\r\n\r\n onSubmit() {\r\n this.isEditable = false;\r\n this.onSubmitEditable.emit(this.text.nativeElement.innerText);\r\n }\r\n\r\n}\r\n","{{ title }}\r\n","import { AfterViewInit, Component, Injector } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { SubheaderConfig } from '@app/template/layout/modules/header/interfaces/subheader-config.interface';\r\nimport { BreadcrumbsService } from '@app/template/layout/modules/header/services/breadcrumbs.service';\r\nimport { NavigationEnd } from '@angular/router';\r\nimport { filter, takeUntil } from 'rxjs/operators';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { DynamicContentService } from '@app/client-core/dynamic-content/service/dynamic-content.service';\r\nimport { Observable } from 'rxjs';\r\nimport { HomeService } from '@app/template/home/services/home.service';\r\n\r\n@Component({\r\n selector: 'app-subheader',\r\n templateUrl: './subheader.component.html',\r\n styleUrls: ['./subheader.component.scss']\r\n})\r\nexport class SubheaderComponent extends ComponentHelper implements AfterViewInit {\r\n active: boolean = false;\r\n isHome: boolean = false;\r\n\r\n constructor(\r\n private breadcrumbsService: BreadcrumbsService,\r\n private settings: SettingsService,\r\n private dynamicContentService: DynamicContentService,\r\n private homeService: HomeService\r\n ) {\r\n super();\r\n this.setHome();\r\n }\r\n\r\n get contentLoaded(): Observable {\r\n return this.dynamicContentService.loaded$;\r\n }\r\n\r\n get isHomePreview(): Observable {\r\n return this.homeService.isHomePreview$;\r\n }\r\n\r\n private setHome() {\r\n this.service.router.events\r\n .pipe(\r\n filter((e): e is NavigationEnd => e instanceof NavigationEnd),\r\n takeUntil(this.destroyed$)\r\n )\r\n .subscribe(event => {\r\n this.isHome = event.url === '/';\r\n });\r\n }\r\n\r\n get component() {\r\n return this.service.subheader.config.component;\r\n }\r\n\r\n get config(): SubheaderConfig {\r\n return this.service.subheader.config;\r\n }\r\n\r\n get myInjector(): Injector | null | undefined {\r\n return this.service.subheader.config.injector;\r\n }\r\n\r\n get displayBreadcrumbs() {\r\n return this.service.subheader.config.displayBreadcrumbs;\r\n }\r\n\r\n get forceShow() {\r\n return this.service.subheader.config.forceShow;\r\n }\r\n\r\n get categories(): { title: string; slug: string }[] | undefined {\r\n return this.service.subheader.config.categories;\r\n }\r\n\r\n get publishedDate(): string | undefined {\r\n return this.service.subheader.config.publishedDate;\r\n }\r\n\r\n get image(): string | undefined {\r\n return this.service.subheader.config.image;\r\n }\r\n\r\n get hideDots(): boolean {\r\n return this.service.subheader.config.hideDots || false;\r\n }\r\n\r\n ngAfterViewInit(): void {\r\n this.breadcrumbsService.reload.next(true);\r\n }\r\n\r\n isArray(categories: { title: string; slug: string }[] | string | undefined): boolean {\r\n return Array.isArray(categories);\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n {{ category.attributes.title }}\r\n \r\n \r\n {{ publishedDate | date: 'shortDate':'':'pl' }}\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","export enum BreadcrumbsLoaders {\r\n Get = 'Get'\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { WcagModule } from '@share/modules/wcag/wcag.module';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { LogoModule } from '@app/template/layout/modules/logo/logo.module';\r\nimport { SearchModule } from '@app/client-core/search/search.module';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { RouterModule } from '@angular/router';\r\nimport {\r\n A11yFontSizeComponent,\r\n GoogleTranslatorComponent,\r\n HeaderContainerComponent,\r\n LanguageComponent,\r\n SubheaderComponent,\r\n SubheaderDescriptionComponent,\r\n SubheaderTitleComponent\r\n} from './components';\r\nimport { BreadcrumbsModule } from '@app/template/layout/modules/breadcrumbs/breadcrumbs.module';\r\nimport { HttpClientModule } from '@angular/common/http';\r\nimport { MenuModule } from '@app/client-core/menu/menu.module';\r\nimport { InputModule } from '@share/modules/html/input/input.module';\r\nimport { FormsModule } from '@angular/forms';\r\nimport { HighContrastComponent } from './components/high-contrast/high-contrast.component';\r\n\r\n@NgModule({\r\n declarations: [\r\n LanguageComponent,\r\n SubheaderTitleComponent,\r\n SubheaderDescriptionComponent,\r\n GoogleTranslatorComponent,\r\n HeaderContainerComponent,\r\n SubheaderComponent,\r\n A11yFontSizeComponent,\r\n HighContrastComponent\r\n ],\r\n imports: [\r\n CommonModule,\r\n WcagModule,\r\n LogoModule,\r\n ElementsModule,\r\n HttpClientModule,\r\n SearchModule,\r\n ElementsModule,\r\n TranslatorModule,\r\n RouterModule,\r\n BreadcrumbsModule,\r\n MenuModule,\r\n InputModule,\r\n FormsModule\r\n ],\r\n exports: [HeaderContainerComponent, SubheaderComponent, SubheaderTitleComponent, SubheaderDescriptionComponent]\r\n})\r\nexport class HeaderModule {}\r\n","import { ReplaySubject } from 'rxjs';\r\nimport { Injector } from '@angular/core';\r\n\r\nexport interface SubheaderConfig {\r\n title: string;\r\n description: string;\r\n displayHeader: boolean;\r\n displayBreadcrumbs: ReplaySubject;\r\n searchOpen: boolean;\r\n searchType: SearchType;\r\n component: any;\r\n categories?: { slug: string; title: string }[];\r\n hideSearch: boolean;\r\n injector?: Injector | null;\r\n forceShow: boolean;\r\n publishedDate?: string;\r\n image?: string;\r\n hideDots?: boolean\r\n}\r\n\r\nexport enum SearchType {\r\n Default = '',\r\n EServices = 'eservice',\r\n None = ''\r\n}\r\n\r\nexport enum SearchTypeNames {\r\n Default = 'Wszędzie',\r\n EServices = 'Katalog e-usług'\r\n}\r\n","import { ServiceHelper } from '@share/common/helpers/service.helper';\r\nimport { Bundle } from '@app/common/enums/server-bundles.enum';\r\nimport { Injectable } from '@angular/core';\r\nimport { BehaviorSubject, Observable } from 'rxjs';\r\nimport { AbstractData, ResponseArray } from '@share/common/models/http';\r\nimport { Breadcrumbs } from '@app/template/layout/modules/header/models/breadcrumbs.model';\r\nimport { API } from '@app/common/constants/api.directories';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class BreadcrumbsService extends ServiceHelper {\r\n reload: BehaviorSubject = new BehaviorSubject(false);\r\n clear: BehaviorSubject = new BehaviorSubject(false);\r\n customBreadcrumbs: Array<{ title: string; url?: string }> = [];\r\n forceActive = false;\r\n\r\n constructor() {\r\n super(Bundle.Breadcrumbs);\r\n }\r\n\r\n public getList(url: string): Observable> {\r\n return this.getAll(`${API.COMMON.BREADCRUMBS}/,${url}`);\r\n }\r\n\r\n public getParsedUrl(url: string): string {\r\n return url.substr(1, url.length).split('/').join(',');\r\n }\r\n\r\n public generateLink(breadcrumbs: Array>, index: number): Array {\r\n let path: Array = [];\r\n try {\r\n for (let i = 0; i < (index + 1); i++) {\r\n path.push(breadcrumbs[i].attributes.url);\r\n }\r\n } catch (_ignore) {\r\n path = [];\r\n }\r\n return path;\r\n }\r\n\r\n public reset() {\r\n this.reload.next(true);\r\n }\r\n}\r\n","import { Injectable, Injector } from '@angular/core';\r\nimport { BehaviorSubject, Observable, ReplaySubject } from 'rxjs';\r\nimport { SearchType, SubheaderConfig } from '@app/template/layout/modules/header/interfaces/subheader-config.interface';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class SubheaderService {\r\n private _config: BehaviorSubject;\r\n\r\n constructor() {\r\n this._config = new BehaviorSubject(this.default);\r\n }\r\n\r\n private get default(): SubheaderConfig {\r\n return {\r\n title: '',\r\n description: '',\r\n searchType: SearchType.None,\r\n component: null,\r\n displayHeader: true,\r\n displayBreadcrumbs: new ReplaySubject(1),\r\n searchOpen: false,\r\n hideSearch: false,\r\n injector: null,\r\n forceShow: false,\r\n categories: [],\r\n hideDots: false\r\n };\r\n }\r\n\r\n public get config(): SubheaderConfig {\r\n return this._config.getValue();\r\n }\r\n\r\n public getConfig(): Observable> {\r\n return this._config.asObservable();\r\n }\r\n\r\n public setConfig(value: Partial) {\r\n this._config.next({ ...this.default, ...value });\r\n }\r\n\r\n public set title(title: string) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n title\r\n });\r\n }\r\n\r\n public set description(description: string) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n description\r\n });\r\n }\r\n\r\n public set searchType(searchType: SearchType) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n searchType\r\n });\r\n }\r\n\r\n public set searchOpen(searchOpen: boolean) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n searchOpen\r\n });\r\n }\r\n\r\n public set injector(injector: Injector) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n injector\r\n });\r\n }\r\n\r\n public set forceShow(forceShow: boolean) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n forceShow\r\n });\r\n }\r\n\r\n public set displayBreadcrumbs(show: boolean) {\r\n this.config.displayBreadcrumbs.next(show);\r\n }\r\n\r\n set categories(categories: { slug: string; title: string }[]) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n categories\r\n });\r\n }\r\n\r\n set publishedDate(publishedDate: string) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n publishedDate\r\n });\r\n }\r\n\r\n set image(image: string) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n image\r\n });\r\n }\r\n\r\n set hideDots(hideDots: boolean) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n hideDots\r\n });\r\n }\r\n\r\n public reset() {\r\n this.setConfig(this.default);\r\n }\r\n}\r\n","import { Component, Input, OnDestroy, OnInit } from '@angular/core';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { Subject } from 'rxjs';\r\n\r\n@Component({\r\n selector: 'app-logo',\r\n templateUrl: './logo.component.html',\r\n styleUrls: ['./logo.component.scss']\r\n})\r\nexport class LogoComponent implements OnInit, OnDestroy {\r\n private destroy$: Subject = new Subject();\r\n url: string;\r\n\r\n @Input() id: string = 'logo';\r\n @Input() isAlt: boolean;\r\n @Input() preventChange: boolean;\r\n\r\n constructor(private layoutService: SettingsService) {}\r\n\r\n ngOnInit() {\r\n if (this.isAlt) {\r\n this.url = this.layoutService.variables.site.altLogo;\r\n } else {\r\n this.url = this.layoutService.variables.site.logo;\r\n }\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.destroy$.next(true);\r\n this.destroy$.complete();\r\n }\r\n}\r\n","\r\n Strona główna\r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { LogoComponent } from '@app/template/layout/modules/logo/components/logo/logo.component';\r\nimport { RouterModule } from '@angular/router';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n RouterModule,\r\n TranslatorModule\r\n ],\r\n declarations: [\r\n LogoComponent\r\n ],\r\n exports: [\r\n LogoComponent\r\n ]\r\n})\r\nexport class LogoModule {}\r\n","import { Component, ElementRef, Input, OnDestroy, OnInit, Renderer2 } from '@angular/core';\r\nimport { AbstractData } from '@share/common/models/http.model';\r\nimport { MenuModel } from '@app/client-core/menu/models/menu.model';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\n\r\n@Component({\r\n selector: 'app-sitemap-item',\r\n templateUrl: './sitemap-item.component.html',\r\n styleUrls: [\r\n './sitemap-item.component.scss'\r\n ]\r\n})\r\nexport class SitemapItemComponent extends ComponentHelper implements OnInit, OnDestroy {\r\n @Input() item: AbstractData;\r\n public listenClickFunc: Function;\r\n\r\n constructor(private renderer: Renderer2,\r\n private _elementRef: ElementRef) {\r\n super();\r\n }\r\n\r\n public ngOnInit() {\r\n this.onClickListener();\r\n }\r\n\r\n public openInNewTab(event: Event, url: string) {\r\n event.preventDefault();\r\n event.stopPropagation();\r\n window.open(url);\r\n }\r\n\r\n private onClickListener() {\r\n this.listenClickFunc = this.renderer.listen(\r\n this._elementRef.nativeElement, 'click', (event) => this.service.utils.navigateTo(event)\r\n );\r\n }\r\n\r\n public ngOnDestroy() {\r\n this.listenClickFunc();\r\n }\r\n}\r\n","{{item.attributes.title}}\r\n\r\n \r\n {{subitem.attributes.title}}\r\n \r\n {{subitem.attributes.title}}\r\n \r\n \r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { SitemapService } from '@app/template/home/services/sitemap.service';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { MenuModel } from '@app/client-core/menu/models/menu.model';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { SitemapLoaders } from '@app/template/home/enums/sitemap-loaders.enum';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { finalize, first } from 'rxjs/operators';\r\nimport { InstitutionModel } from '@app/template/layout/modules/sitemap/models/institution.model';\r\n\r\n@Component({\r\n selector: 'app-sitemap',\r\n templateUrl: './sitemap.component.html',\r\n styleUrls: ['./sitemap.component.scss']\r\n})\r\nexport class SitemapComponent extends ComponentHelper implements OnInit {\r\n sitemap: Array> = [];\r\n SitemapLoaders = SitemapLoaders;\r\n description: string;\r\n institution: AbstractData;\r\n constructor(private sitemapService: SitemapService, private settingService: SettingsService) {\r\n super();\r\n }\r\n\r\n public ngOnInit() {\r\n this.loadSitemap();\r\n this.getInstitutionData();\r\n }\r\n\r\n getInstitutionData() {\r\n this.sitemapService\r\n .getInstitutionData()\r\n .pipe(first())\r\n .subscribe(response => (this.institution = response.data));\r\n }\r\n\r\n public loadSitemap() {\r\n this.setLoader(SitemapLoaders.GetAll, true);\r\n this.sitemapService\r\n .getList()\r\n .pipe(\r\n first(),\r\n finalize(() => this.setLoader(SitemapLoaders.GetAll, false))\r\n )\r\n .subscribe(\r\n response => (this.sitemap = this.getResponseData(response)),\r\n () => this.setComponentError()\r\n );\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n {{institution?.attributes?.name}}\r\n \r\n \r\n \r\n {{ institution?.attributes?.address?.zipCode }} {{ institution?.attributes?.address?.city }}\r\n ul. {{ institution?.attributes?.address?.street }} {{ institution?.attributes?.address?.houseNumber }}\r\n {{\r\n institution?.attributes?.address?.apartmentNumber\r\n ? '/' + institution?.attributes?.address?.apartmentNumber\r\n : ''\r\n }}\r\n \r\n \r\n \r\n \r\n \r\n {{ institution?.attributes?.contact?.phoneNumber }}\r\n \r\n \r\n \r\n {{ institution?.attributes?.contact?.phoneNumberSecondary }}\r\n \r\n \r\n \r\n {{ institution?.attributes?.contact?.fax }}\r\n \r\n \r\n \r\n {{ institution?.attributes?.contact?.email }}\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n 0\">\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { LogoModule } from '@app/template/layout/modules/logo/logo.module';\r\nimport { RouterModule } from '@angular/router';\r\nimport { SitemapComponent } from '@app/template/layout/modules/sitemap/components/sitemap/sitemap.component';\r\nimport { SitemapItemComponent } from '@app/template/layout/modules/sitemap/components/sitemap/sitemap-item/sitemap-item.component';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\n\r\n@NgModule({\r\n declarations: [\r\n SitemapComponent,\r\n SitemapItemComponent,\r\n ],\r\n imports: [\r\n CommonModule,\r\n ElementsModule,\r\n LogoModule,\r\n RouterModule,\r\n TranslatorModule,\r\n ],\r\n exports: [\r\n SitemapComponent\r\n ]\r\n})\r\nexport class SiteMapModule {\r\n}\r\n\r\n","// This file can be replaced during build by using the `fileReplacements` array.\r\n// `ng build --prod` replaces `environment.ts` with `environment.prod.ts`.\r\n// The list of file replacements can be found in `angular.json`.\r\n\r\nexport const environment = {\r\n production: false\r\n};\r\n\r\n/*\r\n * For easier debugging in development mode, you can import the following file\r\n * to ignore zone related error stack frames such as `zone.run`, `zoneDelegate.invokeTask`.\r\n *\r\n * This import should be commented out in production mode because it will have a negative impact\r\n * on performance if an error is thrown.\r\n */\r\n// import 'zone.js/dist/zone-error'; // Included with Angular CLI.\r\n","import {enableProdMode} from '@angular/core';\r\nimport {platformBrowserDynamic} from '@angular/platform-browser-dynamic';\r\n\r\nimport {AppModule} from './app/app.module';\r\nimport {environment} from './environments/environment';\r\nimport 'hammerjs';\r\n\r\nif (environment.production) {\r\n enableProdMode();\r\n}\r\n\r\nplatformBrowserDynamic().bootstrapModule(AppModule)\r\n .catch(err => console.error(err));\r\n"]}
(`${API.ARTICLES.ROOT}`, params);\r\n }\r\n\r\n\r\n getRandomArticles(expect: string, count: number = 3) {\r\n let params: HttpParams = new HttpParams()\r\n .append('limit', count.toString())\r\n .append('except', expect);\r\n return this.apiService.getAll(`${API.ARTICLES.RANDOM}`, params);\r\n }\r\n\r\n getOne(slug: string): Observable> {\r\n return this.apiService.get(`${API.ARTICLES.ROOT}/${slug}`).pipe(first());\r\n }\r\n}\r\n","import { ChangeDetectionStrategy, Component, OnInit } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { CookieService } from '@app/client-core/cookies/service/cookie.service';\r\n\r\n@Component({\r\n selector: 'app-cookie-information-bar',\r\n templateUrl: './cookie-information-bar.component.html',\r\n styleUrls: ['./cookie-information-bar.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class CookieInformationBarComponent extends ComponentHelper implements OnInit {\r\n\r\n public cookieText: string = '';\r\n\r\n constructor(private settings: SettingsService, private cookieService: CookieService) {\r\n super();\r\n }\r\n\r\n get isCookieAccepted(): string {\r\n return this.cookieService.getCookie('cookiesAccepted');\r\n }\r\n\r\n ngOnInit() {\r\n try {\r\n this.cookieText = this.settings.variables.footer.cookieWarningContent;\r\n } catch (ignore) {\r\n throw new Error('Cannot get cookieWarningContent of undefined');\r\n }\r\n }\r\n\r\n accept(): void {\r\n this.cookieService.setCookie('cookiesAccepted', 'true', 365);\r\n }\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { CookieInformationBarComponent } from './components/cookie-information-bar/cookie-information-bar.component';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\n\r\n@NgModule({\r\n declarations: [CookieInformationBarComponent],\r\n imports: [\r\n CommonModule,\r\n ElementsModule,\r\n TranslatorModule\r\n ],\r\n exports: [\r\n CookieInformationBarComponent\r\n ]\r\n\r\n})\r\nexport class CookiesModule {\r\n}\r\n","import { Injectable } from '@angular/core';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class CookieService {\r\n\r\n constructor() {\r\n }\r\n\r\n public getCookie(name: string) {\r\n const ca: Array = document.cookie.split(';');\r\n const caLen: number = ca.length;\r\n const cookieName = `${name}=`;\r\n let c: string;\r\n\r\n for (let i = 0; i < caLen; i += 1) {\r\n c = ca[i].replace(/^\\s+/g, '');\r\n if (c.indexOf(cookieName) === 0) {\r\n return c.substring(cookieName.length, c.length);\r\n }\r\n }\r\n return '';\r\n }\r\n\r\n public setCookie(name: string, value: string, expireDays: number = 0): void {\r\n let cookie = '';\r\n cookie += `${name}=${value};`;\r\n const d: Date = new Date();\r\n if (expireDays !== 0) {\r\n d.setTime(d.getTime() + expireDays * 24 * 60 * 60 * 1000);\r\n\r\n cookie += `expires=${d.toString()}`;\r\n }\r\n document.cookie = cookie;\r\n\r\n }\r\n\r\n}\r\n","import { AfterViewInit, Component, OnDestroy, ViewChild, ViewContainerRef } from '@angular/core';\r\nimport { ActivatedRoute, Router } from '@angular/router';\r\nimport { DynamicContentService } from '@app/client-core/dynamic-content/service/dynamic-content.service';\r\nimport { LazyLoaderService } from '@app/common/services/lazy-loader.service';\r\nimport { switchMap, takeUntil, tap } from 'rxjs/operators';\r\nimport { of, Subject } from 'rxjs';\r\nimport { ROUTES_PATHS } from '@app/common/constants/routes-paths';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { ComponentInterface } from '@app/client-core/dynamic-content/interfaces/components.interface';\r\nimport { Nullable } from '@share/common/types/utilities.types';\r\nimport { BreadcrumbsService } from '@app/template/layout/modules/header/services/breadcrumbs.service';\r\nimport { ElementService } from '@app/client-core/dynamic-content/service/element.service';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { HOME_COMPONENTS } from '@app/client-core/dynamic-content/constants/component-list';\r\n\r\n@Component({\r\n selector: 'app-dynamic-content',\r\n templateUrl: './dynamic-content.component.html',\r\n styleUrls: ['./dynamic-content.component.scss']\r\n})\r\nexport class DynamicContentComponent implements AfterViewInit, OnDestroy {\r\n @ViewChild('componentPlaceholder', { read: ViewContainerRef }) componentPlaceholder: ViewContainerRef;\r\n private currentView: string;\r\n private destroy$: Subject = new Subject();\r\n\r\n constructor(\r\n private dynamic: DynamicContentService,\r\n private router: Router,\r\n private lazyLoaderService: LazyLoaderService,\r\n private facadeService: FacadeService,\r\n private breadcrumbsService: BreadcrumbsService,\r\n private elementsService: ElementService,\r\n private settingsService: SettingsService,\r\n ) {}\r\n\r\n async ngAfterViewInit() {\r\n this.dynamic.runtimeUrlReader$\r\n .pipe(\r\n takeUntil(this.destroy$),\r\n switchMap((rawUrl: string) => {\r\n if (rawUrl.includes('#')) {\r\n return of(null);\r\n } else {\r\n if (rawUrl === '/') {\r\n return of(this.getHomeComponent()).pipe(\r\n tap((component: Nullable) => (this.dynamic.homeComponent = component))\r\n );\r\n }\r\n return this.dynamic.componentLoader(rawUrl);\r\n }\r\n })\r\n )\r\n .subscribe(\r\n (component: Nullable) => {\r\n this.loadView(component);\r\n },\r\n () => this.componentNotFoundNavigation()\r\n );\r\n }\r\n\r\n private getHomeComponent(): ComponentInterface {\r\n const { name } = this.settingsService.variables.theme;\r\n return { ...HOME_COMPONENTS[name], isHome: true };\r\n }\r\n\r\n private loadView(component: Nullable) {\r\n if (component && component.className !== this.currentView) {\r\n this.breadcrumbsService.reset();\r\n this.facadeService.subheader.reset();\r\n this.componentPlaceholder?.clear();\r\n this.lazyLoaderService.load(component.module, this.componentPlaceholder, component.name).then(() => {\r\n this.facadeService.scrollTo.resetScrollTop();\r\n this.dynamic.loaded = true;\r\n this.currentView = component?.className;\r\n });\r\n } else if (component) {\r\n this.navigateToHomeDefaultContext(component);\r\n this.breadcrumbsService.reset();\r\n this.dynamic.loaded = true;\r\n this.elementsService.loaded = true;\r\n }\r\n this.facadeService.scrollTo.resetScrollTop();\r\n }\r\n\r\n private navigateToHomeDefaultContext(component: null | ComponentInterface) {\r\n if (component?.defaultContext && component?.isHome) {\r\n this.router.navigate([component?.defaultContext]);\r\n }\r\n }\r\n\r\n private componentNotFoundNavigation() {\r\n this.router.navigate(['/', ROUTES_PATHS.notFoundPage.root]);\r\n }\r\n\r\n ngOnDestroy() {\r\n this.destroy$.next(true);\r\n this.destroy$.complete();\r\n }\r\n}\r\n","\r\n","import { StaticPageComponent } from '@app/client-core/static-pages/components/static-page/static-page.component';\r\nimport { ArticleListComponent } from '@app/client-core/article/components/article-list/article-list.component';\r\nimport { ThemesEnum } from '@app/common/models/themes.enum';\r\nimport { ComponentsInterface } from '@app/client-core/dynamic-content/interfaces/components.interface';\r\nimport { OverlayComponent } from '@app/template/home/components/overlay/overlay.component';\r\nimport { ArticleComponent } from '@app/client-core/article/components';\r\n\r\nexport const COMPONENTS: ComponentsInterface = {\r\n main: { name: OverlayComponent, module: ThemesEnum.CORE, className: 'OverlayComponent' },\r\n static: { name: StaticPageComponent, module: ThemesEnum.CORE, className: 'StaticPageComponent' },\r\n articlecategory: { name: ArticleListComponent, module: ThemesEnum.ARTICLE, className: 'ArticleListComponent' },\r\n article: { name: ArticleComponent, module: ThemesEnum.ARTICLE, className: 'ArticleComponent' }\r\n};\r\n\r\nexport enum ThemeName {\r\n Basic = 'podstawowy'\r\n}\r\n\r\nexport const HOME_COMPONENTS: ComponentsInterface = {\r\n [ThemeName.Basic]: { name: OverlayComponent, module: ThemesEnum.CORE, className: 'OverlayComponent' }\r\n};\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { DynamicContentComponent } from './component/dynamic-content/dynamic-content.component';\r\nimport { ProgressBarModule } from '@share/modules/progress-bar/progress-bar.module';\r\nimport { StaticPagesModule } from '@app/client-core/static-pages/static-pages.module';\r\nimport { ArticleModule } from '@app/client-core/article/article.module';\r\nimport { HomeModule } from '@app/template/home/home.module';\r\nimport { DynamicUtilsService } from '@app/client-core/dynamic-content/service/dynamic-utils.service';\r\n\r\n@NgModule({\r\n declarations: [DynamicContentComponent],\r\n imports: [\r\n CommonModule,\r\n ProgressBarModule,\r\n StaticPagesModule,\r\n ArticleModule,\r\n HomeModule\r\n ],\r\n providers: [DynamicUtilsService],\r\n exports: [\r\n DynamicContentComponent\r\n ]\r\n})\r\nexport class DynamicContentModule {\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { API } from '@app/common/constants/api.directories';\r\nimport { COMPONENTS } from '@app/client-core/dynamic-content/constants/component-list';\r\nimport { BehaviorSubject, Observable, of, throwError } from 'rxjs';\r\nimport { MetaResponse, ResponseDefault } from '@share/common/models/http.model';\r\nimport { Nullable } from '@share/common/types/utilities.types';\r\nimport { ComponentInterface } from '@app/client-core/dynamic-content/interfaces/components.interface';\r\nimport { distinctUntilChanged, filter, map, startWith, switchMap, tap } from 'rxjs/operators';\r\nimport { ApiService } from '@app/common/services/api.service';\r\nimport { NavigationEnd, Router } from '@angular/router';\r\nimport { DynamicUtilsService } from '@app/client-core/dynamic-content/service/dynamic-utils.service';\r\nimport { ElementService } from '@app/client-core/dynamic-content/service/element.service';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class DynamicContentService {\r\n private _loaded: BehaviorSubject = new BehaviorSubject(true);\r\n loaded$: Observable = this._loaded.asObservable().pipe(distinctUntilChanged());\r\n homeComponent: Nullable;\r\n\r\n constructor(\r\n private apiService: ApiService,\r\n private router: Router,\r\n private dynamicUtilsService: DynamicUtilsService,\r\n private elementService: ElementService\r\n ) {}\r\n\r\n set loaded(value: boolean) {\r\n this._loaded.next(value);\r\n }\r\n\r\n get runtimeUrlReader$(): Observable {\r\n return this.router.events.pipe(\r\n startWith(new NavigationEnd(0, this.router.url, this.router.url)),\r\n filter((e: any): e is NavigationEnd => e instanceof NavigationEnd),\r\n map((event: NavigationEnd) => event.url)\r\n );\r\n }\r\n\r\n componentLoader(rawUrl: string): Observable> {\r\n return of(rawUrl).pipe(\r\n map((rawUrl: string) => this.dynamicUtilsService.parseUrlToBeProcessable(rawUrl)),\r\n switchMap((url: string) => this.getPageMetadata(url)),\r\n tap(response => {\r\n if (response?.meta?.objectId) {\r\n this.elementService.objectId = response?.meta?.objectId\r\n }\r\n }),\r\n map((response: any) => response.meta),\r\n switchMap((metadata: MetaResponse) => this.getComponentByType(metadata?.type))\r\n );\r\n }\r\n\r\n private getComponentByType(type: string | undefined): Observable> {\r\n if (type) {\r\n const component: Nullable = this.getComponent(type);\r\n if (!component) {\r\n return throwError(`Not found component ${type}`);\r\n }\r\n return of(component);\r\n } else {\r\n return throwError(`Component's type is not provided: ${type}`);\r\n }\r\n }\r\n\r\n getPageMetadata(url: string): Observable {\r\n return this.apiService.get(`${API.DYNAMIC_CONTENT.ROOT}${url && url != ' ' ? '/' + url : ''}`);\r\n }\r\n\r\n private getComponent(module: string): Nullable {\r\n try {\r\n return COMPONENTS[module.toLowerCase()];\r\n } catch (e) {\r\n return null;\r\n }\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\n\r\n@Injectable()\r\nexport class DynamicUtilsService {\r\n parseUrlToBeProcessable(url: string): string {\r\n let parsed: string = url.split('/').join(',');\r\n return parsed === ',' ? '' : parsed;\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { BehaviorSubject, Observable } from 'rxjs';\r\nimport { Nullable } from '@share/common/types/utilities.types';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ElementService {\r\n private _objectId: BehaviorSubject> = new BehaviorSubject>(null);\r\n private _sameComponentNavigation: BehaviorSubject = new BehaviorSubject(false);\r\n\r\n public get getObjectId(): Observable> {\r\n return this._objectId.asObservable();\r\n }\r\n\r\n public get objectId(): Nullable {\r\n return this._objectId.getValue();\r\n }\r\n\r\n public set objectId(value: Nullable) {\r\n this._objectId.next(value);\r\n }\r\n\r\n public get sameComponentNavigation(): Observable {\r\n return this._sameComponentNavigation.asObservable();\r\n }\r\n\r\n public set loaded(value: boolean) {\r\n this._sameComponentNavigation.next(value);\r\n }\r\n\r\n}\r\n","import {\r\n ChangeDetectionStrategy,\r\n ChangeDetectorRef,\r\n Component,\r\n ElementRef,\r\n EventEmitter,\r\n Input,\r\n Output,\r\n Renderer2\r\n} from '@angular/core';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { MenuModel } from '@app/client-core/menu/models/menu.model';\r\nimport { MenuService } from '@app/client-core/menu/services/menu.service';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\n\r\n@Component({\r\n selector: 'app-default-menu',\r\n templateUrl: './default-menu.component.html',\r\n styleUrls: ['./default-menu.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class DefaultMenuComponent {\r\n @Input() menu: AbstractData[];\r\n @Input() isMenuWidthChecking: boolean;\r\n @Input() isLoading: boolean;\r\n\r\n @Output() refreshed: EventEmitter = new EventEmitter();\r\n\r\n getError: boolean;\r\n open: { [id: string]: boolean } = {};\r\n\r\n constructor(\r\n private menuService: MenuService,\r\n private facadeService: FacadeService,\r\n private renderer: Renderer2,\r\n private cdr: ChangeDetectorRef,\r\n private _elementRef: ElementRef\r\n ) {}\r\n\r\n onMouseOver(id: string) {\r\n this.open[id] = true;\r\n }\r\n\r\n hideSubmenu() {\r\n for(let key in this.open) {\r\n this.open[key] = false;\r\n }\r\n }\r\n\r\n onComponentRefresh() {\r\n this.refreshed.emit();\r\n }\r\n}\r\n","\r\n Menu główne\r\n \r\n \r\n \r\n \r\n 0\">\r\n \r\n {{ item.attributes.title }}\r\n \r\n\r\n 12 ? '60' : '30'\" [class.show]=\"open[item.id]\" [attr.aria-labelledby]=\"item.attributes.title\">\r\n \r\n \r\n \r\n \r\n {{ child.attributes.highlightedContent }}\r\n\r\n \r\n \r\n {{ child.attributes.title }}\r\n \r\n\r\n\r\n \r\n \r\n {{ child.attributes.title }}\r\n \r\n\r\n \r\n \r\n\r\n \r\n \r\n \r\n {{ child.attributes.title }}\r\n \r\n\r\n \r\n \r\n {{ child.attributes.title }}\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n {{ item.attributes.title }}\r\n \r\n\r\n \r\n {{ item.attributes.title }}\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import {\r\n AfterViewInit,\r\n ChangeDetectionStrategy,\r\n ChangeDetectorRef,\r\n Component,\r\n ElementRef,\r\n Input,\r\n OnDestroy,\r\n ViewChild\r\n} from '@angular/core';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { MenuModel } from '@app/client-core/menu/models/menu.model';\r\nimport { MenuService } from '@app/client-core/menu/services/menu.service';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { filter, takeUntil, tap } from 'rxjs/operators';\r\nimport { fromEvent, Subject } from 'rxjs';\r\n\r\ndeclare var $: any;\r\n\r\n@Component({\r\n selector: 'app-mobile-menu',\r\n templateUrl: 'mobile-menu.component.html',\r\n styleUrls: ['mobile-menu.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class MobileMenuComponent implements OnDestroy, AfterViewInit {\r\n private destroy$: Subject = new Subject();\r\n\r\n @Input() menu: AbstractData[];\r\n\r\n @ViewChild('sidebarMobile') sidebarMobile: ElementRef;\r\n\r\n getError: boolean;\r\n getLoading: boolean;\r\n open: boolean;\r\n shownComplete: boolean;\r\n\r\n constructor(private menuService: MenuService,\r\n private facadeService: FacadeService,\r\n private cdr: ChangeDetectorRef,\r\n private _elementRef: ElementRef) {}\r\n\r\n ngOnInit() {\r\n this.shownComplete = true;\r\n this.listenForServiceChange();\r\n this.handleOutsideClick();\r\n }\r\n\r\n ngOnDestroy() {\r\n this.destroy$.next(true);\r\n this.destroy$.complete();\r\n }\r\n\r\n listenForServiceChange() {\r\n this.menuService.isMobileMenuActive$.pipe(takeUntil(this.destroy$)).subscribe(isActive => {\r\n if (!isActive) {\r\n this.hide();\r\n }\r\n });\r\n }\r\n\r\n hide() {\r\n this.open = false;\r\n $('.navbar-collapse').collapse('hide');\r\n this.cdr.detectChanges();\r\n }\r\n\r\n toggleMenu() {\r\n if (this.shownComplete) {\r\n this.shownComplete = false;\r\n this.open = !this.open;\r\n }\r\n }\r\n\r\n ngAfterViewInit() {\r\n $('.navbar-collapse')\r\n .on('shown.bs.collapse', () => (this.shownComplete = true))\r\n .on('hidden.bs.collapse', () => (this.shownComplete = true))\r\n }\r\n\r\n setLoader(value: boolean) {\r\n this.getLoading = value;\r\n this.cdr.detectChanges();\r\n }\r\n\r\n parseId(id: string): string {\r\n return id.replace(/ /g,'')\r\n }\r\n\r\n handleOutsideClick() {\r\n const clickEvent$ = fromEvent(document, 'click');\r\n clickEvent$\r\n .pipe(\r\n takeUntil(this.destroy$),\r\n filter(e => !this._elementRef.nativeElement.contains(e.target)),\r\n tap(() => this.hide())\r\n )\r\n .subscribe();\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n 0; else defaultMenuItem\">\r\n {{ item.attributes.title }}\r\n \r\n \r\n \r\n \r\n\r\n \r\n\r\n \r\n {{\r\n item.attributes.title\r\n }}\r\n \r\n\r\n \r\n {{\r\n item.attributes.title\r\n }}\r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { HttpClientModule } from '@angular/common/http';\r\nimport { LogoModule } from '@app/template/layout/modules/logo/logo.module';\r\nimport { DefaultMenuComponent } from './components/default-menu/default-menu.component';\r\nimport { RouterModule } from '@angular/router';\r\nimport { PolygonModule } from '@app/template/elements/polygon/polygon.module';\r\nimport { MobileMenuComponent } from '@app/client-core/menu/components/mobile-menu/mobile-menu.component';\r\n\r\n@NgModule({\r\n declarations: [MobileMenuComponent, DefaultMenuComponent],\r\n imports: [CommonModule, HttpClientModule, RouterModule, ElementsModule, TranslatorModule, LogoModule, PolygonModule],\r\n exports: [DefaultMenuComponent, MobileMenuComponent]\r\n})\r\nexport class MenuModule {}\r\n","import { Injectable } from '@angular/core';\r\nimport { BehaviorSubject, Observable, of } from 'rxjs';\r\nimport { MenuModel } from '@app/client-core/menu/models/menu.model';\r\nimport { ResponseArray } from '@share/common/models/http';\r\nimport { API } from '@app/common/constants/api.directories';\r\nimport { ApiService } from '@app/common/services/api.service';\r\nimport { Router } from '@angular/router';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class MenuService {\r\n\r\n isMobileMenuActive$: BehaviorSubject = new BehaviorSubject(false);\r\n\r\n constructor(private apiService: ApiService, private router: Router) {\r\n }\r\n\r\n public getList(type?: string): Observable> {\r\n return this.apiService.getAll(`${API.MENU.ROOT}${type ? `/${type}` : ''}`);\r\n }\r\n\r\n public navigate(type: string, url: string): Promise {\r\n if (type === 'link') {\r\n return new Promise((resolve) => {\r\n window.open(url);\r\n resolve(true);\r\n });\r\n } else {\r\n if (!url || url.includes('null')) {\r\n return this.router.navigate(['/']);\r\n } else {\r\n return this.router.navigateByUrl('/' + url);\r\n }\r\n }\r\n }\r\n\r\n public isActive(url: string): boolean {\r\n return this.router.isActive(url, true);\r\n }\r\n\r\n}\r\n","import { ChangeDetectionStrategy, ChangeDetectorRef, Component, Inject, OnDestroy } from '@angular/core';\r\nimport { SUBHEADER_INJECTION_TOKEN } from '@app/client-core/search/subheader-injection-token';\r\nimport { Observable, Subject } from 'rxjs';\r\nimport { takeUntil } from 'rxjs/operators';\r\n\r\n@Component({\r\n selector: 'app-search-results-subheader',\r\n templateUrl: 'search-results-subheader.component.html',\r\n styleUrls: ['search-results-subheader.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class SearchResultsSubheaderComponent implements OnDestroy {\r\n private destroy$: Subject = new Subject();\r\n\r\n amount: number;\r\n keyword: string;\r\n\r\n constructor(\r\n @Inject(SUBHEADER_INJECTION_TOKEN) data: Observable<{ amount: number; keyword: string }>,\r\n private cdr: ChangeDetectorRef\r\n ) {\r\n data.pipe(takeUntil(this.destroy$)).subscribe(data => {\r\n this.amount = data.amount;\r\n this.keyword = data.keyword;\r\n this.cdr.detectChanges();\r\n });\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.destroy$.next(true);\r\n this.destroy$.complete();\r\n }\r\n}\r\n","\r\n {{ keyword }} - Wyniki wyszukiwania\r\n \r\n Znaleziono\r\n {{ amount || 0 }} wyników\r\n \r\n\r\n","import { ChangeDetectorRef, Component, Injector, OnDestroy, OnInit } from '@angular/core';\r\nimport { ActivatedRoute } from '@angular/router';\r\nimport { SearchService } from '@app/client-core/search/services/search.service';\r\nimport { SearchItem } from '@app/client-core/search/models/search-item.model';\r\nimport { SearchType } from '@app/template/layout/modules/header/interfaces/subheader-config.interface';\r\nimport { BreadcrumbsService } from '@app/template/layout/modules/header/services/breadcrumbs.service';\r\nimport { combineLatest } from 'rxjs/internal/observable/combineLatest';\r\nimport { finalize, first, map, takeUntil, tap } from 'rxjs/operators';\r\nimport { PaginationService } from '@app/template/elements/pagination/services/pagination.service';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { SearchResultsSubheaderComponent } from '@app/client-core/search/components/search-results-subheader/search-results-subheader.component';\r\nimport { Subject } from 'rxjs';\r\nimport { SearchHelperService } from '@app/client-core/search/search-helper.service';\r\nimport { SUBHEADER_INJECTION_TOKEN } from '@app/client-core/search/subheader-injection-token';\r\nimport { ResponseArray } from '@share/common/models/http';\r\n\r\n@Component({\r\n selector: 'app-search-results',\r\n templateUrl: './search-results.component.html',\r\n styleUrls: ['./search-results.component.scss']\r\n})\r\nexport class SearchResultsComponent implements OnInit, OnDestroy {\r\n searchedWord: string;\r\n data: { articles: SearchItem[]; pages: SearchItem[] } = { articles: [], pages: [] };\r\n type: SearchType;\r\n pages: number = 1;\r\n count: number = 20;\r\n getLoading: boolean;\r\n getError: boolean;\r\n destroyed$: Subject = new Subject();\r\n\r\n private searchMetadata: Subject<{ amount: number; keyword: string }> = new Subject<{\r\n amount: number;\r\n keyword: string;\r\n }>();\r\n\r\n constructor(\r\n private activatedRoute: ActivatedRoute,\r\n private searchService: SearchService,\r\n private breadcrumbsService: BreadcrumbsService,\r\n private paginationService: PaginationService,\r\n private facadeService: FacadeService,\r\n private injector: Injector,\r\n private searchHelperService: SearchHelperService,\r\n private cdr: ChangeDetectorRef\r\n ) {\r\n this.setSubheader();\r\n this.setBreadcrumbs();\r\n }\r\n\r\n private setSubheader() {\r\n this.facadeService.subheader.setConfig({\r\n component: SearchResultsSubheaderComponent,\r\n injector: Injector.create({\r\n providers: [\r\n {\r\n provide: SUBHEADER_INJECTION_TOKEN,\r\n useValue: this.searchMetadata\r\n }\r\n ],\r\n parent: this.injector\r\n })\r\n });\r\n this.facadeService.subheader.config.displayBreadcrumbs.next(true);\r\n }\r\n\r\n public ngOnInit() {\r\n this.setPageListener();\r\n window.scrollTo(0, 0);\r\n }\r\n\r\n setLoader(value: boolean) {\r\n this.getLoading = value;\r\n this.cdr.detectChanges();\r\n }\r\n\r\n public searchRequest(page: number) {\r\n this.clearData();\r\n this.setLoader(true);\r\n this.searchService\r\n .getFullList(this.searchedWord, this.type, page, this.count)\r\n .pipe(\r\n first(),\r\n tap(response => (this.searchService.amount = response.data.length)),\r\n finalize(() => this.setLoader(false))\r\n )\r\n .subscribe(response => this.onResponseSuccess(response));\r\n }\r\n\r\n onResponseSuccess(response: ResponseArray) {\r\n this.clearData();\r\n this.searchMetadata.next({ amount: response?.meta?.amount || 0, keyword: this.searchedWord });\r\n response.data?.forEach((item: any) => {\r\n if (item.type === 'Page') {\r\n this.data = { articles: [...this.data.articles], pages: [...this.data.pages, item] };\r\n } else if (item.type === 'CmsArticle') {\r\n this.data = { articles: [...this.data.articles, item], pages: [...this.data.pages] };\r\n }\r\n });\r\n const meta = response.meta;\r\n if (meta && typeof meta.pages === 'number') {\r\n this.pages = meta.pages;\r\n }\r\n }\r\n\r\n identify(index: number) {\r\n return index;\r\n }\r\n\r\n private clearData() {\r\n this.data = {\r\n articles: [],\r\n pages: []\r\n };\r\n }\r\n\r\n navigateTo(url: string, isExternal: boolean) {\r\n if (isExternal) {\r\n window.open(url);\r\n } else {\r\n this.facadeService.router.navigate([url]);\r\n }\r\n }\r\n\r\n private setBreadcrumbs() {\r\n this.breadcrumbsService.forceActive = true;\r\n this.breadcrumbsService.customBreadcrumbs = [{ title: this.facadeService.translator.trans('search.header') }];\r\n }\r\n\r\n private setPageListener() {\r\n combineLatest([this.activatedRoute.params, this.paginationService.currentPage])\r\n .pipe(\r\n map(results => ({ data: results[0].data, page: results[1] })),\r\n takeUntil(this.destroyed$)\r\n )\r\n .subscribe(results => {\r\n this.searchedWord = results.data;\r\n this.searchRequest(results.page);\r\n });\r\n }\r\n\r\n ngOnDestroy() {\r\n this.destroyed$.next(true);\r\n this.destroyed$.complete();\r\n this.breadcrumbsService.forceActive = false;\r\n }\r\n}\r\n","\r\n \r\n \r\n 0\">\r\n Artykuły\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n 0\">\r\n Strony\r\n \r\n {{ item.attributes.content }}\r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { ChangeDetectorRef, Component, ElementRef, Input, OnDestroy, OnInit, ViewChild } from '@angular/core';\r\nimport { SearchService } from '@app/client-core/search/services/search.service';\r\nimport { SearchItem } from '@app/client-core/search/models/search-item.model';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { NavigationExtras } from '@angular/router';\r\nimport { SearchType } from '@app/template/layout/modules/header/interfaces/subheader-config.interface';\r\nimport { fromEvent, Observable, Subject } from 'rxjs';\r\nimport { filter, finalize, first, takeUntil, tap } from 'rxjs/operators';\r\nimport { UtilsService } from '@share/common/services/utils.service';\r\nimport { SelectModel } from '@share/modules/html/common/interfaces/select-model.interface';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { ThemesEnum } from '@app/common/models/themes.enum';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { ResizeListener } from '@app/common/services/resize-listener.service';\r\n\r\n@Component({\r\n selector: 'app-search',\r\n templateUrl: './search.component.html',\r\n styleUrls: ['./search.component.scss']\r\n})\r\nexport class SearchComponent implements OnInit, OnDestroy {\r\n\r\n private _value = '';\r\n private readonly minLength: number = 3;\r\n private destroy$: Subject = new Subject();\r\n\r\n @ViewChild('input') input: ElementRef;\r\n @Input() mobile: boolean;\r\n @Input() placeholder: string = 'search.button';\r\n\r\n data: { articles: SearchItem[]; pages: SearchItem[] } = { articles: [], pages: [] };\r\n availablesTypes: Array> = [];\r\n type: SearchType = SearchType.Default;\r\n searchSelectId: string;\r\n searchId: string;\r\n showResultsBox: boolean;\r\n loading: boolean;\r\n error: boolean;\r\n forceActive: boolean;\r\n isActive$: Observable;\r\n\r\n\r\n constructor(\r\n private searchService: SearchService,\r\n private _elementRef: ElementRef,\r\n private utils: UtilsService,\r\n private settingsService: SettingsService,\r\n private cdr: ChangeDetectorRef,\r\n private facadeService: FacadeService,\r\n ) {\r\n this.availablesTypes = this.searchService.getAvailableSearchTypes();\r\n const newId: string = this.utils.makeId();\r\n this.searchSelectId = `search-type-${newId}`;\r\n this.searchId = `search-input-${newId}`;\r\n }\r\n\r\n markAsActive() {\r\n this.searchService.isActive$.next(true);\r\n setTimeout(() => {\r\n this.forceActive = true;\r\n this.input.nativeElement.focus();\r\n }, 500)\r\n }\r\n\r\n markAsInactive(){\r\n this.searchService.isActive$.next(false);\r\n this.forceActive = false;\r\n this.showResultsBox = false;\r\n }\r\n\r\n onValueChange(value: string) {\r\n if (value.length >= 3) {\r\n this.showResultsBox = true;\r\n this.searchRequest(value);\r\n } else {\r\n this.showResultsBox = false;\r\n }\r\n this.value = value;\r\n }\r\n\r\n ngOnInit() {\r\n this.setSearchType();\r\n this.handleOutsideClick();\r\n this.isActive$ = this.searchService.isActive$;\r\n }\r\n\r\n private setSearchType() {\r\n this.facadeService.subheader.getConfig().subscribe(config => {\r\n this.type = config.searchType || SearchType.Default;\r\n });\r\n }\r\n\r\n handleOutsideClick() {\r\n const clickEvent$ = fromEvent(document, 'click');\r\n clickEvent$\r\n .pipe(\r\n takeUntil(this.destroy$),\r\n filter(e => !this._elementRef.nativeElement.contains(e.target)),\r\n tap(e => {\r\n this.clear();\r\n this.markAsInactive();\r\n })\r\n )\r\n .subscribe();\r\n }\r\n\r\n get value() {\r\n return this._value;\r\n }\r\n\r\n set value(data: string) {\r\n this._value = data;\r\n }\r\n\r\n hasMinLength(value: string) {\r\n const valid = value.length >= this.minLength;\r\n if (!valid) {\r\n this.clearData();\r\n }\r\n return valid;\r\n }\r\n\r\n search() {\r\n if (this.hasMinLength(this.value)) {\r\n this.markAsInactive();\r\n this.facadeService.router.navigate(['search', this._value], this.getNavigationExtras()).then(onfulfilled => {\r\n if (onfulfilled) {\r\n this.clear();\r\n }\r\n });\r\n }\r\n }\r\n\r\n private getNavigationExtras() {\r\n const extra: NavigationExtras = { queryParams: null };\r\n if (this.type !== SearchType.Default) {\r\n extra.queryParams = { type: this.type };\r\n }\r\n return extra;\r\n }\r\n\r\n setLoader(value: boolean) {\r\n this.loading = value;\r\n this.cdr.detectChanges();\r\n }\r\n\r\n searchRequest(value: string) {\r\n this.setLoader(true);\r\n this.clearData();\r\n this.searchService\r\n .getList(value, this.type)\r\n .pipe(\r\n first(),\r\n finalize(() => this.setLoader(false))\r\n )\r\n .subscribe(response => {\r\n this.clearData();\r\n response.data?.forEach((item: any) => {\r\n if (item.type === 'Page') {\r\n this.data = { articles: [...this.data.articles], pages: [...this.data.pages, item] };\r\n } else if (item.type === 'CmsArticle') {\r\n this.data = { articles: [...this.data.articles, item], pages: [...this.data.pages] };\r\n }\r\n });\r\n });\r\n }\r\n\r\n private clear() {\r\n this._value = '';\r\n this.clearData();\r\n this.showResultsBox = false;\r\n }\r\n\r\n private clearData() {\r\n this.data = {\r\n articles: [],\r\n pages: []\r\n }\r\n }\r\n\r\n ngOnDestroy() {\r\n this.destroy$.next(true);\r\n this.destroy$.complete();\r\n }\r\n}\r\n","\r\n \r\n {{'search.searchLabel' | trans}}\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n 0 || data.articles.length > 0\" [error]=\"error\">\r\n \r\n 0\">\r\n {{'search.pages' | trans}}\r\n \r\n {{ item.attributes.title }}\r\n \r\n \r\n\r\n 0\">\r\n {{'search.articles' | trans}}\r\n \r\n {{ item.attributes.title }}\r\n \r\n \r\n \r\n\r\n \r\n {{'search.noData' | trans}}\r\n \r\n \r\n \r\n\r\n","import { Injectable } from '@angular/core';\r\nimport { BehaviorSubject, forkJoin, Observable } from 'rxjs';\r\n\r\n@Injectable()\r\nexport class SearchHelperService {\r\n amount: BehaviorSubject = new BehaviorSubject(0);\r\n keyword: BehaviorSubject = new BehaviorSubject('');\r\n\r\n getData(): Observable<{ amount: number; keyword: string }> {\r\n return forkJoin({ amount: this.amount, keyword: this.keyword });\r\n }\r\n}\r\n","import {NgModule} from '@angular/core';\r\nimport {CommonModule} from '@angular/common';\r\nimport {SearchComponent} from './components/search/search.component';\r\nimport {FormsModule} from '@angular/forms';\r\nimport {ElementsModule} from '@share/modules/elements/elements.module';\r\nimport {SearchResultsComponent} from './components/search-results/search-results.component';\r\nimport {TranslatorModule} from '@share/modules/translator/translator.module';\r\nimport {NgbPaginationModule} from '@ng-bootstrap/ng-bootstrap';\r\nimport {ContainerModule} from '@app/template/layout/modules/container/container.module';\r\nimport {SelectModule} from '@share/modules/html/select/select.module';\r\nimport { PaginationModule } from '@app/template/elements/pagination/pagination.module';\r\nimport { PaginationService } from '@app/template/elements/pagination/services/pagination.service';\r\nimport { RouterModule } from '@angular/router';\r\nimport { SearchResultsSubheaderComponent } from '@app/client-core/search/components/search-results-subheader/search-results-subheader.component';\r\nimport { ArticleModule } from '@app/client-core/article/article.module';\r\nimport { SearchHelperService } from '@app/client-core/search/search-helper.service';\r\n\r\n@NgModule({\r\n declarations: [SearchComponent, SearchResultsComponent, SearchResultsSubheaderComponent],\r\n imports: [\r\n CommonModule,\r\n FormsModule,\r\n ElementsModule,\r\n TranslatorModule,\r\n NgbPaginationModule,\r\n ContainerModule,\r\n SelectModule,\r\n PaginationModule,\r\n RouterModule,\r\n ArticleModule,\r\n ],\r\n exports: [\r\n SearchComponent,\r\n SearchResultsComponent\r\n ],\r\n providers: [\r\n PaginationService,\r\n SearchHelperService\r\n ]\r\n})\r\nexport class SearchModule {}\r\n","import {Injectable} from '@angular/core';\r\nimport {ServiceHelper} from '@share/common/helpers/service.helper';\r\nimport {API} from '@app/common/constants/api.directories';\r\nimport { BehaviorSubject, Observable } from 'rxjs';\r\nimport {SearchType, SearchTypeNames} from '@app/template/layout/modules/header/interfaces/subheader-config.interface';\r\nimport {HttpParams} from '@angular/common/http';\r\nimport {AbstractData} from '@share/common/models/http.model';\r\nimport {SelectModel} from '@share/modules/html/common/interfaces/select-model.interface';\r\nimport {Bundle} from '@app/common/enums/server-bundles.enum';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class SearchService extends ServiceHelper {\r\n\r\n amount: number = 0;\r\n isActive$: BehaviorSubject = new BehaviorSubject(false);\r\n\r\n constructor() {\r\n super('');\r\n }\r\n\r\n public getList(keyword: string, searchType: SearchType): Observable {\r\n let params: HttpParams = new HttpParams().set('contains', keyword);\r\n\r\n if (!!searchType) {\r\n params = params.set('inside', searchType);\r\n }\r\n\r\n return this.getAll(API.SEARCH.ROOT, {http: {params}});\r\n }\r\n\r\n public getFullList(keyword: string, searchType: SearchType, page: number, count: number): Observable {\r\n let params: HttpParams = new HttpParams();\r\n\r\n params = params.set('page', page.toString());\r\n params = params.set('count', count.toString());\r\n params = params.set('contains', keyword);\r\n\r\n if (!!searchType) {\r\n params = params.set('inside', searchType);\r\n }\r\n\r\n return this.getAll(API.SEARCH.FULL, {http: {params}});\r\n }\r\n\r\n public getAvailableSearchTypes(): Array> {\r\n return [\r\n {\r\n id: SearchType.Default,\r\n type: Bundle.Alert,\r\n attributes: {\r\n title: SearchTypeNames.Default\r\n }\r\n },\r\n {\r\n id: SearchType.EServices,\r\n type: Bundle.Alert,\r\n attributes: {\r\n title: SearchTypeNames.EServices\r\n }\r\n }\r\n ];\r\n }\r\n}\r\n","import { InjectionToken } from '@angular/core';\r\n\r\nexport const SUBHEADER_INJECTION_TOKEN = new InjectionToken('SUBHEADER_INJECTION_TOKEN');\r\n","export { StaticPageComponent } from './static-page/static-page.component';\r\nexport { StaticPageDefaultComponent } from './static-page-default/static-page-default.component';\r\nexport { StaticPageContactComponent } from './static-page-contact/static-page-contact.component';\r\nexport { ContactFormComponent } from './static-page-contact/contact-form/contact-form.component';\r\nexport { ContactImagesComponent } from './static-page-contact/contact-images/contact-images.component';\r\nexport { ContactSubheaderComponent } from './static-page-contact/contact-subheader/contact-subheader.component';\r\nexport { SchedulePageComponent } from './schedule-page/schedule-page.component';\r\n","import { ChangeDetectionStrategy, Component, Input } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'app-schedule-page',\r\n templateUrl: 'schedule-page.component.html',\r\n styleUrls: ['schedule-page.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class SchedulePageComponent {\r\n @Input() data: {\r\n content: {\r\n boxPhone: string;\r\n boxSchedule: string;\r\n boxTitle: string;\r\n boxSubtitle: string;\r\n subtitle: string;\r\n schedule: {date: string, cities: string}[];\r\n };\r\n };\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n {{ boxTitle }}\r\n \r\n \r\n {{ boxSubtitle }}\r\n \r\n \r\n \r\n {{ boxPhone }}\r\n \r\n \r\n\r\n\r\n\r\n \r\n {{ title }}\r\n {{ content }}\r\n \r\n\r\n","import { Observable } from 'rxjs';\r\nimport { ResponseArray } from '@share/common/models/http';\r\nimport { API } from '@app/common/constants/api.directories';\r\nimport { ApiService } from '@app/common/services/api.service';\r\nimport { Injectable } from '@angular/core';\r\n\r\n@Injectable({ providedIn: 'root' })\r\nexport class ConsentsService {\r\n constructor(private apiService: ApiService) {}\r\n\r\n getList(name: string = ''): Observable> {\r\n return this.apiService.getAll(`${API.AUTH.CONSENTS}/${name}`);\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'app-contact-dots',\r\n templateUrl: 'contact-dots.component.html',\r\n styleUrls: ['contact-dots.component.scss']\r\n})\r\nexport class ContactDotsComponent {}\r\n","\r\n \r\n\r\n","import { AfterViewInit, ChangeDetectionStrategy, ChangeDetectorRef, Component, Input, OnDestroy, OnInit } from '@angular/core';\r\nimport { FormBuilder, FormGroup } from '@angular/forms';\r\nimport { CaptchaV3Service } from '@app/common/services/captcha-v3.service';\r\nimport { ConsentsService } from '@app/client-core/static-pages/components/static-page-contact/consents.service';\r\nimport { finalize, first } from 'rxjs/operators';\r\nimport { getContactFormGroup } from '@app/client-core/static-pages/components/static-page-contact/contact-form/form/contact-form.group';\r\nimport { getContactFormConfig } from '@app/client-core/static-pages/components/static-page-contact/contact-form/form/contact-form.config';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { ContactService } from '@app/client-core/static-pages/components/static-page-contact/contact.service';\r\n\r\n@Component({\r\n selector: 'app-contact-form',\r\n templateUrl: 'contact-form.component.html',\r\n styleUrls: ['contact-form.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class ContactFormComponent implements OnInit, OnDestroy, AfterViewInit {\r\n formGroup: FormGroup;\r\n formConfig: { [id: string]: any };\r\n consentLoader: boolean;\r\n sendLoader: boolean;\r\n\r\n @Input() title: string;\r\n @Input() subtitle: string;\r\n\r\n constructor(\r\n private formBuilder: FormBuilder,\r\n private captchaService: CaptchaV3Service,\r\n private consentService: ConsentsService,\r\n private cdr: ChangeDetectorRef,\r\n private facadeService: FacadeService,\r\n private contactService: ContactService\r\n ) {\r\n this.initFormGroup();\r\n }\r\n\r\n private initFormGroup() {\r\n this.formGroup = this.formBuilder.group(getContactFormGroup());\r\n this.formConfig = getContactFormConfig(this.facadeService.translator);\r\n }\r\n\r\n ngOnInit() {\r\n this.captchaService.load();\r\n this.getConsents();\r\n }\r\n\r\n getConsents() {\r\n this.consentLoader = true;\r\n this.cdr.detectChanges();\r\n this.consentService\r\n .getList('contact')\r\n .pipe(\r\n first(),\r\n finalize(() => {\r\n this.consentLoader = false;\r\n this.cdr.detectChanges();\r\n })\r\n )\r\n .subscribe(response => {\r\n const [first] = response.data;\r\n this.setConsentConfig(first.id, first.attributes.fulltext);\r\n });\r\n }\r\n\r\n setConsentConfig(id: string, label: string) {\r\n this.formConfig.consent = {\r\n id: id,\r\n label: label,\r\n allowHtmlLabel: true\r\n };\r\n }\r\n\r\n ngAfterViewInit() {\r\n this.captchaService.toggleVisibility();\r\n }\r\n\r\n onSubmit() {\r\n this.sendLoader = true;\r\n this.cdr.detectChanges();\r\n this.captchaService.execute()\r\n .pipe(\r\n first()\r\n )\r\n .subscribe(\r\n token => {\r\n this.formGroup.patchValue({ captcha: token });\r\n this.sendForm();\r\n },\r\n () => {\r\n this.facadeService.toastr.error(this.facadeService.trans('contact.form.captchaError'));\r\n this.sendLoader = false;\r\n this.cdr.detectChanges();\r\n }\r\n );\r\n }\r\n\r\n sendForm() {\r\n this.contactService\r\n .submit(this.formGroup.getRawValue())\r\n .pipe(\r\n first(),\r\n finalize(() => {\r\n this.sendLoader = false;\r\n this.cdr.detectChanges();\r\n })\r\n )\r\n .subscribe(\r\n () => {\r\n this.facadeService.toastr.success(this.facadeService.translator.trans('contact.form.successMessage'));\r\n this.formGroup.reset();\r\n },\r\n );\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.captchaService.toggleVisibility(false);\r\n }\r\n}\r\n","\r\n {{ title }}\r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n\r\n\r\n","import { InputTypeEnum } from '@share/modules/html/input/enums/input-types.enum';\r\nimport { TranslatorService } from '@share/common/services/translator.service';\r\n\r\nexport function getContactFormConfig(translatorService: TranslatorService): { [id: string]: any } {\r\n return {\r\n senderName: {\r\n id: 'senderName',\r\n type: InputTypeEnum.Text,\r\n label: translatorService.trans('contact.form.name')\r\n },\r\n senderEmail: {\r\n id: 'senderEmail',\r\n type: InputTypeEnum.Text,\r\n label: translatorService.trans('contact.form.email')\r\n },\r\n content: {\r\n id: 'content',\r\n type: InputTypeEnum.Text,\r\n label: translatorService.trans('contact.form.message')\r\n }\r\n };\r\n}\r\n","import { Validators } from '@angular/forms';\r\n\r\nexport function getContactFormGroup(): { [id: string]: any } {\r\n return {\r\n senderName: ['', Validators.required],\r\n senderEmail: ['', Validators.required],\r\n content: ['', Validators.required],\r\n dataProcessConsent: [false, Validators.requiredTrue],\r\n captcha: ['', Validators.required]\r\n };\r\n}\r\n","import { Component, Input } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'app-contact-images',\r\n templateUrl: 'contact-images.component.html',\r\n styleUrls: ['contact-images.component.scss']\r\n})\r\nexport class ContactImagesComponent {\r\n @Input() biggerImageUrl: string;\r\n @Input() smallerImageUrl: string;\r\n\r\n @Input() isRight: boolean;\r\n @Input() special: boolean;\r\n @Input() smallUp: boolean;\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n\r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { InstitutionService } from '@app/common/services/institution.service';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { first } from 'rxjs/operators';\r\nimport { Institution } from '@app/common/models/institution.model';\r\n\r\n@Component({\r\n selector: 'app-contact-subheader',\r\n templateUrl: 'contact-subheader.component.html',\r\n styleUrls: ['contact-subheader.component.scss']\r\n})\r\nexport class ContactSubheaderComponent implements OnInit {\r\n\r\n institution: AbstractData;\r\n\r\n constructor(private institutionService: InstitutionService) {}\r\n\r\n ngOnInit() {\r\n this.getInstitutionData();\r\n }\r\n\r\n getInstitutionData() {\r\n this.institutionService\r\n .getCurrent()\r\n .pipe(\r\n first()\r\n )\r\n .subscribe(response => this.institution = response.data)\r\n }\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n Dane kontaktowe\r\n \r\n {{institution.attributes.name}}\r\n {{institution.attributes.address.zipCode}} {{institution.attributes.address.city}} \r\n {{institution.attributes.address.street}} {{institution.attributes.address.houseNumber}}\r\n tel.: {{institution.attributes.contact.phoneNumber}}\r\n {{institution.attributes.contact.email}}\r\n \r\n \r\n\r\n","import { Injectable } from '@angular/core';\r\nimport { Observable } from 'rxjs';\r\nimport { ApiService } from '@app/common/services/api.service';\r\nimport { API } from '@app/common/constants/api.directories';\r\n\r\n@Injectable({providedIn: 'root'})\r\nexport class ContactService {\r\n\r\n constructor(private apiService: ApiService) {\r\n }\r\n\r\n public submit(contact: any): Observable {\r\n return this.apiService.post('contact', contact);\r\n }\r\n}\r\n","import { ChangeDetectionStrategy, Component, Input } from '@angular/core';\r\nimport { ImageCropper } from '@app/template/home/models/image-cropper.model';\r\n\r\n@Component({\r\n selector: 'app-static-page-contact-department',\r\n templateUrl: 'static-page-contact-department.component.html',\r\n styleUrls: ['static-page-contact-department.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class StaticPageContactDepartmentComponent {\r\n\r\n @Input() rightImage: boolean;\r\n @Input() special: boolean;\r\n @Input() specialTwo: boolean;\r\n @Input() smallUp: boolean;\r\n\r\n @Input() data: {\r\n title: string;\r\n bigImage: ImageCropper;\r\n smallImage: ImageCropper;\r\n people: {\r\n personOrPlace: string;\r\n contact: {\r\n type: 'phone' | 'email';\r\n value: string;\r\n extra: string | null;\r\n }[];\r\n }[];\r\n };\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n {{ data.title }}\r\n \r\n \r\n \r\n \r\n \r\n\r\n\r\n\r\n \r\n {{person.description}}\r\n {{person.fullName}} - {{person?.scope}}\r\n \r\n \r\n Numer telefonu\r\n \r\n {{ contact.value }}\r\n wew. {{ contact.extra }}\r\n \r\n\r\n \r\n Email\r\n \r\n {{ contact.value }}\r\n \r\n \r\n \r\n\r\n","import { Component, Input } from '@angular/core';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { ContactSubheaderComponent } from '@app/client-core/static-pages/components/static-page-contact/contact-subheader/contact-subheader.component';\r\n\r\n@Component({\r\n selector: 'app-static-page-contact',\r\n templateUrl: './static-page-contact.component.html',\r\n styleUrls: ['./static-page-contact.component.scss']\r\n})\r\nexport class StaticPageContactComponent {\r\n @Input() data: {\r\n sectionOne: any,\r\n sectionTwo: any,\r\n sectionThree: any,\r\n sectionFour: any\r\n };\r\n\r\n constructor(private facadeService: FacadeService) {\r\n this.facadeService.subheader.setConfig({\r\n component: ContactSubheaderComponent,\r\n hideDots: true\r\n });\r\n this.facadeService.subheader.displayBreadcrumbs = false;\r\n }\r\n}\r\n","\r\n\r\n\r\n \r\n \r\n {{ data.sectionThree.title }}\r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n = 3\">\r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { Component, Input } from '@angular/core';\r\nimport { StaticPageDefaultModel } from '@app/client-core/static-pages/model/static-page-default.model';\r\n\r\n@Component({\r\n selector: 'app-static-page-default',\r\n templateUrl: './static-page-default.component.html',\r\n styleUrls: ['./static-page-default.component.scss']\r\n})\r\nexport class StaticPageDefaultComponent {\r\n @Input() data: StaticPageDefaultModel;\r\n\r\n getFileUrl() {\r\n // TODO: Poprawić typy\r\n if (this.data.file?.hasOwnProperty('url')) {\r\n return this.data.file['croppedImage'] || this.data?.file['url'];\r\n }\r\n return this.getFileAsString();\r\n }\r\n\r\n private getFileAsString(): string | null {\r\n if (typeof this.data?.file === 'string') {\r\n return this.data?.file;\r\n }\r\n return null;\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { Component, Input, OnDestroy, OnInit } from '@angular/core';\r\nimport { SubheaderService } from '@app/template/layout/modules/header/services/subheader.service';\r\nimport { ElementService } from '@app/client-core/dynamic-content/service/element.service';\r\nimport { ActivatedRoute, Router } from '@angular/router';\r\nimport { UrlService } from '@app/common/services/url.service';\r\nimport { finalize, first, takeUntil } from 'rxjs/operators';\r\nimport { AbstractData, ResponseObject } from '@share/common/models/http';\r\nimport { PagesService } from '@app/common/services/pages.service';\r\nimport { PageModel } from '@app/common/models/page.model';\r\nimport { ReplaySubject } from 'rxjs';\r\nimport { HistoryService } from '@share/common/services/history.service';\r\nimport { StaticPage } from '@app/client-core/static-pages/model/static-pages.model';\r\nimport { Nullable } from '@share/common/types/utilities.types';\r\n\r\n@Component({\r\n selector: 'app-static-page',\r\n templateUrl: './static-page.component.html',\r\n styleUrls: ['./static-page.component.scss']\r\n})\r\nexport class StaticPageComponent implements OnInit, OnDestroy {\r\n @Input() page: Nullable>>>;\r\n\r\n private destroyed$: ReplaySubject = new ReplaySubject(1);\r\n getError: boolean;\r\n getLoading: boolean;\r\n\r\n constructor(\r\n protected pagesService: PagesService,\r\n protected subheaderService: SubheaderService,\r\n private elementService: ElementService,\r\n protected route: ActivatedRoute,\r\n private urlService: UrlService,\r\n private historyService: HistoryService,\r\n private router: Router\r\n ) {}\r\n\r\n private setListener() {\r\n this.elementService.sameComponentNavigation.pipe(takeUntil(this.destroyed$)).subscribe(same => {\r\n if (same) {\r\n this.loadPage();\r\n }\r\n });\r\n }\r\n\r\n ngOnInit() {\r\n this.setListener();\r\n if (!this.page) {\r\n this.loadPage();\r\n } else {\r\n this.setSubheader(this.page);\r\n }\r\n }\r\n\r\n protected onLoadPageSuccess(response: ResponseObject>>) {\r\n this.page = response.data;\r\n this.setSubheader(this.page);\r\n }\r\n\r\n private setSubheader(page: AbstractData>>) {\r\n this.subheaderService.setConfig({ title: page.attributes.title, publishedDate: page.attributes.publishedFrom });\r\n if (page.attributes.content?.pageType === 'schedule') {\r\n this.subheaderService.description = page?.attributes?.content?.content?.subtitle;\r\n this.subheaderService.publishedDate = '';\r\n }\r\n this.subheaderService.config.displayBreadcrumbs.next(true);\r\n }\r\n\r\n loadPage() {\r\n this.getLoading = true;\r\n this.pagesService\r\n .getOne(this.router.url.split('/').join(','))\r\n .pipe(\r\n first(),\r\n finalize(() => (this.getLoading = false))\r\n )\r\n .subscribe(\r\n response => this.onLoadPageSuccess(response),\r\n error => {\r\n this.subheaderService.setConfig({\r\n title: error.error.errors[0].status\r\n });\r\n this.subheaderService.description = error.error.errors[0].title;\r\n this.page = null;\r\n }\r\n );\r\n }\r\n\r\n ngOnDestroy() {\r\n this.destroyed$.next(true);\r\n this.destroyed$.complete();\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { RouterModule } from '@angular/router';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { ContainerModule } from '@app/template/layout/modules/container/container.module';\r\nimport { GoogleMapModule } from '@share/modules/google-map/google-map.module';\r\nimport {\r\n ContactFormComponent,\r\n StaticPageComponent,\r\n StaticPageContactComponent,\r\n StaticPageDefaultComponent,\r\n ContactImagesComponent,\r\n ContactSubheaderComponent,\r\n SchedulePageComponent\r\n} from '@app/client-core/static-pages/components';\r\nimport { ArticleModule } from '@app/client-core/article/article.module';\r\nimport { SimpleBoxModule } from '@app/template/elements/simple-box/simple-box.module';\r\nimport { ReactiveFormsModule } from '@angular/forms';\r\nimport { CheckboxModule } from '@share/modules/html/checkbox/checkbox.module';\r\nimport { InputModule } from '@app/template/elements/input/input.module';\r\nimport { TextareaModule } from '@app/template/elements/textarea/textarea.module';\r\nimport { HeaderModule } from '@app/template/layout/modules/header/header.module';\r\nimport { StaticPageContactDepartmentComponent } from '@app/client-core/static-pages/components/static-page-contact/static-page-contact-department/static-page-contact-department.component';\r\nimport { ContactDotsComponent } from '@app/client-core/static-pages/components/static-page-contact/contact-dots/contact-dots.component';\r\nimport { BreadcrumbsModule } from '@app/template/layout/modules/breadcrumbs/breadcrumbs.module';\r\n\r\n@NgModule({\r\n declarations: [\r\n SchedulePageComponent,\r\n StaticPageContactDepartmentComponent,\r\n ContactImagesComponent,\r\n ContactSubheaderComponent,\r\n ContactFormComponent,\r\n StaticPageComponent,\r\n StaticPageDefaultComponent,\r\n StaticPageContactComponent,\r\n ContactDotsComponent\r\n ],\r\n imports: [\r\n CommonModule,\r\n RouterModule,\r\n ElementsModule,\r\n TranslatorModule,\r\n ContainerModule,\r\n GoogleMapModule,\r\n ArticleModule,\r\n SimpleBoxModule,\r\n ReactiveFormsModule,\r\n CheckboxModule,\r\n InputModule,\r\n TextareaModule,\r\n HeaderModule,\r\n BreadcrumbsModule\r\n ],\r\n exports: [StaticPageComponent]\r\n})\r\nexport class StaticPagesModule {}\r\n","import { AppConfigCMS } from '@share/common/interfaces/app-config.interface';\r\n\r\ndeclare const APP_CONFIG: AppConfigCMS;\r\nexport const URL = APP_CONFIG.API_URL;\r\nconst PREFIX = APP_CONFIG.PREFIX;\r\nconst SERVER = `${URL}/${PREFIX}`;\r\n\r\nexport const API = {\r\n AUTH: {\r\n LOGIN: `${SERVER}/login`,\r\n LOGOUT: `${SERVER}/logout`,\r\n CONSENTS: `${SERVER}/consents`,\r\n FORGOT_PASSWORD: `${SERVER}/account/resetPassword/sendEmail`,\r\n VALIDATE_TOKEN: `${SERVER}/account/resetPassword/checkToken`,\r\n CHANGE_PASSWORD: `${SERVER}/account/resetPassword/change`,\r\n ACTIVATE_ACCOUNT: `${SERVER}/account/confirm`\r\n },\r\n COMMON: {\r\n BREADCRUMBS: `${SERVER}/breadcrumbs`\r\n },\r\n ARTICLES: {\r\n ROOT: `${SERVER}/articles`,\r\n RANDOM: `${SERVER}/articles/random`\r\n },\r\n SETTINGS: {\r\n ROOT: `${SERVER}/settings/bootstrap`,\r\n GET_LAYOUT: `${SERVER}/settings/layout`\r\n },\r\n SEARCH: {\r\n ROOT: `${SERVER}/search/autocomplete`,\r\n FULL: `${SERVER}/search/getResult`\r\n },\r\n PROMOTED: {\r\n ROOT: `${SERVER}/promoted`\r\n },\r\n BANNERS: {\r\n ROOT: `${SERVER}/banners`\r\n },\r\n MENU: {\r\n ROOT: `${SERVER}/menu`,\r\n SITEMAP: `${SERVER}/menu/sitemap`\r\n },\r\n DYNAMIC_CONTENT: {\r\n ROOT: `${SERVER}/search/getMetadata`\r\n },\r\n CATEGORY: {\r\n ROOT: `${SERVER}/categories`\r\n },\r\n PROFILE: {\r\n ROOT: `${SERVER}/account`\r\n },\r\n ALERTS: {\r\n ROOT: `${SERVER}/alerts`\r\n },\r\n BUSINESS_MODULES: {\r\n ROOT: `${SERVER}/businessModules`,\r\n },\r\n PAGES: {\r\n ROOT: `${SERVER}/pages`\r\n },\r\n PREVIEW: {\r\n ROOT: `${SERVER}/preview`\r\n },\r\n INSTITUTION: {\r\n ROOT: 'institution'\r\n },\r\n ASSETS: {\r\n DEFAULT_SETTINGS: 'source/default_settings.json'\r\n }\r\n};\r\n","import { APP_INITIALIZER, LOCALE_ID, Provider } from '@angular/core';\r\nimport { HTTP_INTERCEPTORS } from '@angular/common/http';\r\nimport { BootstrapService } from '@app/common/services/bootstrap.service';\r\nimport {\r\n getBackendVersionFactory,\r\n getFrontendVersionFactory,\r\n getLanguageFactory,\r\n getMaintenanceFactory,\r\n getPermissions,\r\n getSettingsFactory,\r\n getTranslationsFactory\r\n} from '@app/common/functions/bootstrap';\r\nimport { LanguageService } from '@share/common/services/language.service';\r\nimport { InstitutionInterceptorService } from '@app/common/interceptors/institution-interceptor.service';\r\nimport { ContentInterceptorService } from '@app/common/interceptors/content-interceptor.service';\r\nimport { ApiInterceptorService } from '@app/common/interceptors/api-interceptor.service';\r\n\r\nexport const BOOTSTRAP_PROVIDERS: Provider[] = [\r\n {\r\n provide: HTTP_INTERCEPTORS,\r\n useClass: ApiInterceptorService,\r\n multi: true\r\n },\r\n {\r\n provide: HTTP_INTERCEPTORS,\r\n useClass: ContentInterceptorService,\r\n multi: true\r\n },\r\n {\r\n provide: HTTP_INTERCEPTORS,\r\n useClass: InstitutionInterceptorService,\r\n multi: true\r\n },\r\n {\r\n provide: LOCALE_ID,\r\n deps: [LanguageService],\r\n useFactory: getLanguageFactory\r\n },\r\n {\r\n provide: APP_INITIALIZER,\r\n useFactory: getTranslationsFactory,\r\n deps: [BootstrapService],\r\n multi: true\r\n },\r\n {\r\n provide: APP_INITIALIZER,\r\n useFactory: getMaintenanceFactory,\r\n deps: [BootstrapService],\r\n multi: true\r\n },\r\n {\r\n provide: APP_INITIALIZER,\r\n useFactory: getSettingsFactory,\r\n deps: [BootstrapService],\r\n multi: true\r\n },\r\n {\r\n provide: APP_INITIALIZER,\r\n useFactory: getBackendVersionFactory,\r\n deps: [BootstrapService],\r\n multi: true\r\n },\r\n {\r\n provide: APP_INITIALIZER,\r\n useFactory: getFrontendVersionFactory,\r\n deps: [BootstrapService],\r\n multi: true\r\n }\r\n];\r\n","import {HAMMER_GESTURE_CONFIG, HammerGestureConfig} from '@angular/platform-browser';\r\nimport {Injectable, Provider} from '@angular/core';\r\nimport * as Hammer from 'hammerjs';\r\n\r\n@Injectable()\r\nexport class MyHammerConfig extends HammerGestureConfig {\r\n buildHammer(element: HTMLElement) {\r\n return new Hammer(element, {\r\n touchAction: 'pan-y pan-x'\r\n });\r\n }\r\n}\r\n\r\nexport const HAMMER_PROVIDER: Provider[] = [\r\n {\r\n provide: HAMMER_GESTURE_CONFIG,\r\n useClass: MyHammerConfig\r\n }\r\n];\r\n","import { NgModuleFactory, Type } from '@angular/core';\r\nimport { ThemesEnum } from '@app/common/models/themes.enum';\r\n\r\nexport const lazyWidgets: { name: string; loadChildren: () => Promise | Type> }[] = [\r\n {\r\n name: ThemesEnum.CORE,\r\n loadChildren: () => import('@app/client-core/static-pages/static-pages.module').then(m => m.StaticPagesModule)\r\n },\r\n {\r\n name: ThemesEnum.ARTICLE,\r\n loadChildren: () => import('@app/client-core/article/article.module').then(m => m.ArticleModule)\r\n },\r\n {\r\n name: ThemesEnum.MENU,\r\n loadChildren: () => import('@app/client-core/menu/menu.module').then(m => m.MenuModule)\r\n }\r\n];\r\n\r\nexport function lazyArrayToObj() {\r\n const result = {};\r\n for (const w of lazyWidgets) {\r\n result[w.name] = w.loadChildren;\r\n }\r\n return result;\r\n}\r\n","import {PortalVariablesEnum} from '@app/common/enums/portal-variables.enum';\r\n\r\nexport const PORTAL_VARIABLES_PRESETS = {\r\n [PortalVariablesEnum.MainColor]: '',\r\n [PortalVariablesEnum.SectionBackgroundColor]: '',\r\n [PortalVariablesEnum.ButtonColor]: '',\r\n [PortalVariablesEnum.AccentColor]: '',\r\n};\r\n","export const ARTICLE_PREVIEW = 'articles';\r\nexport const STATIC_PAGE_PREVIEW = 'static-pages';\r\nexport const ESERVICE_PREVIEW = 'eservices';\r\nexport const ROUTES_PATHS = {\r\n profile: {\r\n root: 'konto',\r\n login: 'logowanie',\r\n register: 'rejestracja',\r\n remindPassword: 'przypomnij-haslo'\r\n },\r\n businessModules: {\r\n root: 'moduly-biznesowe'\r\n },\r\n eServices: {\r\n root: 'katalog-e-uslug'\r\n },\r\n notFoundPage: {\r\n root: '404'\r\n },\r\n unknownErrorPage: {\r\n root: '500'\r\n },\r\n maintenance: {\r\n root: 'przerwa-techniczna'\r\n },\r\n preview: {\r\n articles: 'articles',\r\n staticPages: 'static-pages'\r\n }\r\n};\r\n","import { InjectionToken } from '@angular/core';\r\n\r\nexport const LAZY_WIDGETS = new InjectionToken<{ [key: string]: string }>('LAZY_WIDGETS');\r\n","export enum MobileEnum {\r\n Large = 992,\r\n Medium = 768,\r\n Small = 576\r\n}\r\n\r\n","export enum PortalVariablesEnum {\r\n MainColor = 'mainColor',\r\n AccentColor = 'accentColor',\r\n ButtonColor = 'buttonColor',\r\n SectionBackgroundColor = 'sectionBackgroundColor'\r\n}\r\n","export enum Bundle {\r\n EServices = 'EServices',\r\n User = 'CmsUser',\r\n Article = 'CmsArticle',\r\n Banner = 'CmsBanner',\r\n BusinessModules = 'CmsBusinessModule',\r\n Settings = 'Setting',\r\n Alert = 'CmsAlert',\r\n Promoted = 'CmsPromoted',\r\n Partners = 'CmsPartners',\r\n Sitemap = 'CmsSitemap',\r\n Breadcrumbs = 'Breadcrumbs',\r\n StaticPages = 'StaticPages',\r\n Preview = 'preview'\r\n}\r\n","import {BootstrapService} from '@app/common/services/bootstrap.service';\r\nimport { LanguageService } from '@share/common/services/language.service';\r\n\r\nexport function getLanguageFactory(language: LanguageService): () => string {\r\n return () => language.getLanguage();\r\n}\r\n\r\nexport function getTranslationsFactory(service: BootstrapService): () => Promise {\r\n return () => service.getTranslations();\r\n}\r\n\r\nexport function getMaintenanceFactory(service: BootstrapService): () => Promise {\r\n return () => service.checkMaintenance();\r\n}\r\n\r\nexport function getSettingsFactory(service: BootstrapService): () => Promise {\r\n return () => service.loadSettings();\r\n}\r\n\r\nexport function getBackendVersionFactory(service: BootstrapService): () => Promise {\r\n return () => service.getBackendVersion();\r\n}\r\n\r\nexport function getFrontendVersionFactory(service: BootstrapService): () => Promise {\r\n return () => service.getFrontendVersion();\r\n}\r\n\r\nexport function getPermissions(service: BootstrapService): () => Promise {\r\n return () => service.getPermissions();\r\n}\r\n","import { OnDestroy, Type } from '@angular/core';\r\nimport { ComponentShareHelper } from '@share/common/helpers/component-share.helper';\r\nimport { FacadeShareService } from '@share/common/services/facade-share.service';\r\nimport { ServiceLocator } from '@share/common/services/locater.service';\r\nimport { FacadeService } from '../services/facade.service';\r\n\r\nexport abstract class ComponentHelper extends ComponentShareHelper implements OnDestroy {\r\n\r\n protected service: FacadeService;\r\n\r\n protected constructor() {\r\n super(ServiceLocator.injector.get(FacadeShareService as Type));\r\n this.service = ServiceLocator.injector.get(FacadeService as Type);\r\n }\r\n}\r\n","import { HttpErrorResponse, HttpEvent, HttpHandler, HttpInterceptor, HttpRequest } from '@angular/common/http';\r\nimport { Injectable } from '@angular/core';\r\nimport { Observable, throwError } from 'rxjs';\r\nimport { ToastrServiceCustom } from '@share/common/services/toastr.service';\r\nimport { Router } from '@angular/router';\r\nimport { ROUTES_PATHS } from '@app/common/constants/routes-paths';\r\nimport { TranslatorService } from '@share/common/services/translator.service';\r\nimport { catchError } from 'rxjs/operators';\r\nimport { ErrorResponse } from '@share/common/models/http.model';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ApiInterceptorService implements HttpInterceptor {\r\n constructor(private toastr: ToastrServiceCustom, private translator: TranslatorService, private router: Router) {}\r\n\r\n private get internalErrorMessage(): string {\r\n return this.translator.trans('global.errors.internalError');\r\n }\r\n\r\n intercept(req: HttpRequest, next: HttpHandler): Observable> {\r\n const headersConfig = {};\r\n const request = req.clone({ setHeaders: headersConfig });\r\n return next.handle(request).pipe(catchError(httpErrorResponse => this.handleError(httpErrorResponse)));\r\n }\r\n\r\n private handleError(httpErrorResponse: any) {\r\n let error: { error: { errors: Array } } = { error: { errors: [] } };\r\n if (httpErrorResponse instanceof HttpErrorResponse) {\r\n this.handleErrorStatus(httpErrorResponse);\r\n const message = this.getMessage(httpErrorResponse);\r\n this.toastr.error(message.title);\r\n error = { error: { errors: [message] } };\r\n }\r\n return throwError(httpErrorResponse);\r\n }\r\n\r\n private getMessage(response: HttpErrorResponse): { title: string; id: string } {\r\n let title: string = '';\r\n try {\r\n const [error] = response.error.errors;\r\n title = error.title;\r\n } catch (e) {\r\n title = this.internalErrorMessage;\r\n }\r\n return { title, id: '' };\r\n }\r\n\r\n private handleErrorStatus(httpErrorResponse: HttpErrorResponse) {\r\n switch (httpErrorResponse.status) {\r\n case 403:\r\n this.handleForbidden();\r\n break;\r\n case 412:\r\n case 0:\r\n this.goToNotFoundPage();\r\n this.router.navigate([ROUTES_PATHS.unknownErrorPage.root]);\r\n break;\r\n }\r\n }\r\n\r\n private handleForbidden() {\r\n if (!this.router.isActive('', false)) {\r\n this.router.navigate(['']);\r\n }\r\n }\r\n\r\n private goToNotFoundPage() {\r\n this.router.navigate([ROUTES_PATHS.unknownErrorPage.root]);\r\n }\r\n}\r\n","import { HttpEvent, HttpHandler, HttpInterceptor, HttpRequest } from '@angular/common/http';\r\nimport { Observable } from 'rxjs';\r\nimport { Injectable } from '@angular/core';\r\n\r\n@Injectable()\r\nexport class ContentInterceptorService implements HttpInterceptor {\r\n intercept(req: HttpRequest, next: HttpHandler): Observable> {\r\n const headersConfig = {\r\n 'Content-Type': 'application/vnd.api+json',\r\n 'Accept': 'application/vnd.api+json',\r\n };\r\n const request = req.clone({setHeaders: headersConfig});\r\n return next.handle(request);\r\n }\r\n}\r\n","import { HttpEvent, HttpHandler, HttpInterceptor, HttpRequest } from '@angular/common/http';\r\nimport { Observable } from 'rxjs';\r\nimport { Injectable } from '@angular/core';\r\n\r\n@Injectable()\r\nexport class InstitutionInterceptorService implements HttpInterceptor {\r\n intercept(req: HttpRequest, next: HttpHandler): Observable> {\r\n const headersConfig = {\r\n 'x-site-url': window.location.origin\r\n };\r\n\r\n const request = req.clone({ setHeaders: headersConfig });\r\n return next.handle(request);\r\n }\r\n}\r\n","export enum ThemesEnum {\r\n ALERT = 'mportal_alert',\r\n ARTICLE = 'mportal_article',\r\n CONSENT = 'mportal_consent',\r\n ESERVICE_CATALOG = 'eservicesCatalog',\r\n MENU = 'mportal_menu',\r\n PROMOTED = 'mportal_promoted',\r\n NETIZEN = 'mportal_netizen',\r\n CORE = 'mportal_core',\r\n EOFFICE = 'eoffice'\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { FormErrors } from '@gkw/shared/common/models/form-errors.model';\r\nimport { HttpErrorResponse } from '@angular/common/http';\r\nimport { ResponseError } from '@share/common/models/http.model';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ApiErrorParserService {\r\n static parse(httpErrorResponse: HttpErrorResponse): FormErrors {\r\n const rawErrors: ResponseError = ApiErrorParserService.getRawErrors(httpErrorResponse);\r\n\r\n const parsedErrors: FormErrors = rawErrors.reduce((previous, current) => {\r\n return {\r\n ...previous,\r\n [current.id ?? current.status]: {\r\n text: current.title\r\n }\r\n };\r\n }, {});\r\n\r\n return parsedErrors;\r\n }\r\n\r\n static getRawErrors(httpErrorResponse: HttpErrorResponse): Array<{ id: string; title: string }> {\r\n try {\r\n return httpErrorResponse.error.errors;\r\n } catch (e) {\r\n throw new Error('Invalid error template');\r\n }\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { RequestOptionsModel } from '@share/common/interfaces/request-options.interface';\r\nimport { AppConfigCMS } from '@share/common/interfaces/app-config.interface';\r\n\r\ndeclare var APP_CONFIG: AppConfigCMS;\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ApiPreprocessorService {\r\n\r\n private readonly URL = `${APP_CONFIG.API_URL}/${APP_CONFIG.PREFIX}`;\r\n\r\n prepareUrl(endpoint: string): string {\r\n if (!endpoint.includes(this.URL)) {\r\n return `${this.URL}/${endpoint}`;\r\n }\r\n\r\n return endpoint;\r\n }\r\n\r\n build(bundle: string, data: object | Array, options: RequestOptionsModel = {}): any {\r\n const request: any = this.createBaseRequest(bundle, data, options);\r\n\r\n if (!!options) {\r\n if (options.jsonapi) {\r\n request.jsonapi = options.jsonapi;\r\n }\r\n if (options.meta) {\r\n request.meta = options.meta;\r\n }\r\n }\r\n\r\n return request;\r\n }\r\n\r\n private createBaseRequest(type: string, data: object | Array, options: RequestOptionsModel): any {\r\n return {\r\n data: Array.isArray(data) ? data : {type: type, attributes: data, id: options.id || '0'},\r\n jsonapi: { // TODO: remove\r\n version: '1.0'\r\n },\r\n meta: {}\r\n };\r\n }\r\n\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { HttpClient, HttpParams } from '@angular/common/http';\r\nimport { Observable, throwError } from 'rxjs';\r\nimport { catchError, first } from 'rxjs/operators';\r\nimport { ResponseArray, ResponseObject } from '@share/common/models/http';\r\nimport { RequestOptionsModel } from '@share/common/interfaces/request-options.interface';\r\nimport { ApiErrorParserService } from '@app/common/services/api-error-parser.service';\r\nimport { ApiPreprocessorService } from '@app/common/services/api-preprocessor.service';\r\nimport { ResponseDefault } from '@share/common/models/http.model';\r\nimport { AppConfigPortal } from '@share/common/interfaces/app-config.interface';\r\n\r\ndeclare var APP_CONFIG: AppConfigPortal;\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ApiService {\r\n private _bundle: string = '';\r\n\r\n constructor(private http: HttpClient, private preprocessor: ApiPreprocessorService) {}\r\n\r\n public setBundle(bundle: string) {\r\n this._bundle = bundle;\r\n }\r\n\r\n get(\r\n endpoint: string,\r\n params: HttpParams = new HttpParams(),\r\n options: RequestOptionsModel = {}\r\n ): Observable> {\r\n return this.http\r\n .get>(this.preprocessor.prepareUrl(endpoint), { params })\r\n .pipe(first());\r\n }\r\n\r\n getAll(\r\n endpoint: string,\r\n params: HttpParams = new HttpParams(),\r\n options: RequestOptionsModel = {}\r\n ): Observable> {\r\n return this.http\r\n .get>(this.preprocessor.prepareUrl(endpoint), { params })\r\n .pipe(first());\r\n }\r\n\r\n post(\r\n endpoint: string,\r\n body: Object = {},\r\n params: HttpParams = new HttpParams(),\r\n options: RequestOptionsModel = {}\r\n ): Observable {\r\n const requestData = this.preprocessor.build(options.bundle || this._bundle, body, options);\r\n return this.http\r\n .post(this.preprocessor.prepareUrl(endpoint), JSON.stringify(requestData), { params })\r\n .pipe(\r\n first(),\r\n catchError(e => throwError(ApiErrorParserService.parse(e)))\r\n );\r\n }\r\n\r\n put(\r\n endpoint: string,\r\n body: Object = {},\r\n options: RequestOptionsModel = {},\r\n params: HttpParams = new HttpParams()\r\n ): Observable {\r\n const requestData = this.preprocessor.build(options.bundle || this._bundle, body, options);\r\n\r\n return this.http\r\n .put(this.preprocessor.prepareUrl(endpoint), JSON.stringify(requestData), { params })\r\n .pipe(\r\n first(),\r\n catchError(e => throwError(ApiErrorParserService.parse(e)))\r\n );\r\n }\r\n\r\n patch(\r\n endpoint: string,\r\n body: Object = {},\r\n options: RequestOptionsModel = {},\r\n params: HttpParams = new HttpParams()\r\n ): Observable {\r\n const requestData = this.preprocessor.build(options.bundle || this._bundle, body, options);\r\n\r\n return this.http\r\n .patch(this.preprocessor.prepareUrl(endpoint), JSON.stringify(requestData), { params })\r\n .pipe(\r\n first(),\r\n catchError(e => throwError(ApiErrorParserService.parse(e)))\r\n );\r\n }\r\n\r\n assets(path: string): Observable {\r\n return this.http.get(`${APP_CONFIG.ASSETS_URL}/${path}`).pipe(first());\r\n }\r\n\r\n delete(endpoint: string): Observable {\r\n return this.http.delete(this.preprocessor.prepareUrl(endpoint)).pipe(first());\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { ROUTES_PATHS } from '@app/common/constants/routes-paths';\r\nimport { ResponseDefault } from '@share/common/models/http.model';\r\nimport { AppService } from '@share/common/services/app.service';\r\nimport { VersionService } from '@share/common/services/version.service';\r\nimport { VariablesCollection } from '@share/common/models/variables.model';\r\nimport { PortalLayoutService } from '@app/common/services/portal-layout.service';\r\nimport { Variable } from '@share/common/interfaces/variables.interface';\r\nimport { first } from 'rxjs/operators';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { AbstractData, ResponseObject } from '@share/common/models/http';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class BootstrapService {\r\n constructor(\r\n private appService: AppService,\r\n private versionService: VersionService,\r\n private portalLayoutService: PortalLayoutService,\r\n private facade: FacadeService\r\n ) {}\r\n\r\n getFrontendVersion(): Promise {\r\n return this.versionService.getFrontendVersion().then(\r\n (version: any) => (this.versionService.frontend = version),\r\n () => {}\r\n );\r\n }\r\n\r\n getBackendVersion(): Promise {\r\n return this.versionService.getBackendVersion().then(\r\n (response: ResponseDefault) => (this.versionService.backend = response.data.id),\r\n () => {}\r\n );\r\n }\r\n\r\n getTranslations(): Promise {\r\n return this.facade.translator.load().then(\r\n (response: ResponseObject) => (this.facade.translator.translations = response.data.attributes),\r\n () => this.onErrorOccur()\r\n );\r\n }\r\n\r\n checkMaintenance(): Promise {\r\n this.facade.maintenance.maintenancePage = ROUTES_PATHS.maintenance.root;\r\n this.facade.maintenance.serverErrorPage = ROUTES_PATHS.notFoundPage.root;\r\n return this.facade.maintenance.check().then(\r\n response => this.facade.maintenance.onSuccess(response),\r\n error => this.facade.maintenance.onError(error)\r\n );\r\n }\r\n\r\n loadSettings(): Promise {\r\n return new Promise(resolve => {\r\n this.facade.settings.load().then(\r\n (response: ResponseObject) => {\r\n this.facade.settings.variables = response.data.attributes;\r\n const layoutData = this.portalLayoutService.prepareData({\r\n ...response.data.attributes.layout,\r\n ...response.data.attributes.site\r\n });\r\n this.portalLayoutService.setLayout(layoutData as Array>);\r\n this.facade.seo.setData(this.facade.settings.variables);\r\n resolve();\r\n },\r\n () => {\r\n this.facade.settings\r\n .loadDefaultVariables()\r\n .pipe(first())\r\n .subscribe(val => {\r\n this.facade.settings.variables = val;\r\n resolve();\r\n });\r\n }\r\n );\r\n });\r\n }\r\n\r\n getPermissions(): Promise {\r\n //this.authService.isAuthenticated\r\n if (!!localStorage.getItem('token')) {\r\n return this.facade.crud.load();\r\n } else {\r\n return new Promise((resolve, reject) => resolve());\r\n }\r\n }\r\n\r\n private onErrorOccur() {\r\n this.appService.setFatalError(true);\r\n this.facade.router.navigate([ROUTES_PATHS.unknownErrorPage.root]);\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { Observable, ReplaySubject, Subject } from 'rxjs';\r\nimport { first, switchMap } from 'rxjs/operators';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\n\r\ndeclare const grecaptcha: any;\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class CaptchaV3Service {\r\n public readonly grecaptcha: Subject = new ReplaySubject();\r\n private scriptElement: HTMLScriptElement;\r\n\r\n constructor(private settingsService: SettingsService) {}\r\n\r\n public load(): void {\r\n if (this.scriptElement) {\r\n return;\r\n }\r\n this.scriptElement = document.createElement('script');\r\n this.scriptElement.src = `https://www.google.com/recaptcha/api.js?render=${this.settingsService.variables.integration.googleReCaptchaSiteKey}`;\r\n this.scriptElement.async = true;\r\n this.scriptElement.addEventListener('load', event => {\r\n grecaptcha.ready(() => {\r\n this.grecaptcha.next(grecaptcha);\r\n });\r\n });\r\n this.scriptElement.addEventListener('error', event => {\r\n this.grecaptcha.next(null);\r\n });\r\n document.getElementsByTagName('head')[0].append(this.scriptElement);\r\n\r\n this.toggleVisibility();\r\n }\r\n\r\n execute(action: string = 'homepage'): Observable {\r\n return this.grecaptcha.pipe(first()).pipe(\r\n switchMap(val => {\r\n if (val === null) {\r\n throw new Error('Google captcha script is not loaded');\r\n }\r\n return val.execute(this.settingsService.variables.integration.googleReCaptchaSiteKey, { action });\r\n })\r\n );\r\n }\r\n\r\n toggleVisibility(show: boolean = true) {\r\n const grecaptcha: HTMLElement | null = document.querySelector('.grecaptcha-badge');\r\n if (grecaptcha) {\r\n grecaptcha.style.display = show ? 'block' : 'none';\r\n }\r\n }\r\n}\r\n","import { Injectable, Injector } from '@angular/core';\r\nimport { FacadeShareService } from '@share/common/services/facade-share.service';\r\nimport { SubheaderService } from '@app/template/layout/modules/header/services/subheader.service';\r\nimport { ScrollToService } from '@app/common/services/scroll-to.service';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class FacadeService extends FacadeShareService {\r\n private _subheader: SubheaderService;\r\n private _scrollTo: ScrollToService;\r\n private _settings: SettingsService;\r\n\r\n constructor(private injector: Injector) {\r\n super(injector);\r\n }\r\n\r\n public get subheader(): SubheaderService {\r\n if (!this._subheader) {\r\n this._subheader = this._injector.get(SubheaderService);\r\n }\r\n return this._subheader;\r\n }\r\n\r\n public get scrollTo(): ScrollToService {\r\n if (!this._scrollTo) {\r\n this._scrollTo = this._injector.get(ScrollToService);\r\n }\r\n return this._scrollTo;\r\n }\r\n\r\n public get settings(): SettingsService {\r\n if (!this._settings) {\r\n this._settings = this._injector.get(SettingsService);\r\n }\r\n return this._settings;\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\n\r\ndeclare var google: any;\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class GoogleTranslateService {\r\n public init() {\r\n // tslint:disable-next-line:no-unused-expression\r\n new google.translate.TranslateElement({\r\n pageLanguage: 'pl',\r\n includedLanguages: 'pl,cs,da,de,en,es,fi,fr,hu,it,ja,no,pt,ru,zh-CN',\r\n layout: google.translate.TranslateElement.InlineLayout.SIMPLE\r\n }, 'google_translate_element');\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { NgbModalOptions } from '@ng-bootstrap/ng-bootstrap';\r\nimport { ServiceHelper } from '@share/common/helpers/service.helper';\r\nimport { ImageZoomComponent } from '@app/template/elements/image-zoom/components/image-zoom/image-zoom.component';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ImageZoomService extends ServiceHelper {\r\n private readonly zoomClass: string = '.image-zoom';\r\n private readonly originalFilterName: string = 'original';\r\n\r\n constructor() {\r\n super('');\r\n }\r\n\r\n public setListener() {\r\n // TODO: it cant find correct dom data, in settimeout works\r\n const images = document.querySelectorAll(this.zoomClass);\r\n for (let i = 0; i < images.length; i++) {\r\n images[i].addEventListener('click', event => this.imagePreview(event.target as HTMLImageElement));\r\n }\r\n }\r\n\r\n public imagePreview(image: HTMLImageElement) {\r\n const src: string = image.src;\r\n const originalSrc: string = this.getOriginalPath(src);\r\n // @ts-ignore\r\n const config: NgbModalOptions = {keyboard: true, backdrop: true, size: 'xl'};\r\n this.modal.openCustomModal(ImageZoomComponent, {original: originalSrc, alt: image.alt}, config);\r\n }\r\n\r\n private getOriginalPath(src: string | null): string {\r\n if (!src) {\r\n return '';\r\n }\r\n let path: string = src.slice(0, src.indexOf('filterName'));\r\n path += `filterName=${this.originalFilterName}`;\r\n return path;\r\n }\r\n}\r\n","import {Injectable} from '@angular/core';\r\nimport {ApiService} from '@app/common/services/api.service';\r\nimport {Observable} from 'rxjs';\r\nimport {ResponseObject} from '@share/common/models/http.model';\r\nimport {Institution} from '@app/common/models/institution.model';\r\nimport {API} from '@app/common/constants/api.directories';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class InstitutionService {\r\n\r\n constructor(private apiService: ApiService) {}\r\n\r\n public getCurrent(): Observable> {\r\n return this.apiService.get(API.INSTITUTION.ROOT);\r\n }\r\n}\r\n","import {\r\n Compiler,\r\n ComponentRef,\r\n Inject,\r\n Injectable,\r\n Injector,\r\n NgModuleFactory,\r\n Type,\r\n ViewContainerRef\r\n} from '@angular/core';\r\nimport { LAZY_WIDGETS } from '@app/common/constants/tokens';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class LazyLoaderService {\r\n constructor(\r\n private injector: Injector,\r\n private compiler: Compiler,\r\n @Inject(LAZY_WIDGETS) private lazyWidgets: { [key: string]: () => Promise | Type> }\r\n ) {}\r\n\r\n async load(name: string, container: ViewContainerRef, component?: any): Promise> {\r\n const ngModuleOrNgModuleFactory = await this.lazyWidgets[name]();\r\n\r\n let moduleFactory;\r\n if (ngModuleOrNgModuleFactory instanceof NgModuleFactory) {\r\n moduleFactory = ngModuleOrNgModuleFactory;\r\n } else {\r\n moduleFactory = await this.compiler.compileModuleAsync(ngModuleOrNgModuleFactory);\r\n }\r\n const entryComponent = component || (moduleFactory.moduleType).entry;\r\n const moduleRef = moduleFactory.create(this.injector);\r\n\r\n const compFactory = moduleRef.componentFactoryResolver.resolveComponentFactory(entryComponent);\r\n\r\n return container.createComponent(compFactory);\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { Observable } from 'rxjs';\r\nimport { Preview } from '@app/client-core/preview/interfaces/preview.interface';\r\nimport { ResponseObject } from '@share/common/models/http';\r\nimport { PageModel } from '@app/common/models/page.model';\r\nimport { ApiService } from '@app/common/services/api.service';\r\nimport { API } from '../constants/api.directories';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class PagesService implements Preview {\r\n constructor(private apiService: ApiService) {}\r\n\r\n getOne(slug: string = ''): Observable>> {\r\n return this.apiService.get(`${API.PAGES.ROOT}${slug ? '/' + slug : ''}`);\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { LayoutService } from '@share/common/services/layout.service';\r\nimport { PortalVariablesEnum } from '@app/common/enums/portal-variables.enum';\r\nimport { PORTAL_VARIABLES_PRESETS } from '@app/common/constants/portal-variables-presets';\r\nimport { HttpClient } from '@angular/common/http';\r\nimport { ImageService } from '@share/common/services/image.service';\r\nimport { AbstractData } from '@share/common/models/http.model';\r\nimport { ObjectString } from '@share/common/interfaces/object-types.interface';\r\nimport { Variable } from '@share/common/interfaces/variables.interface';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class PortalLayoutService extends LayoutService {\r\n\r\n constructor(protected httpClient: HttpClient,\r\n protected imageService: ImageService) {\r\n super(httpClient, imageService);\r\n this.layoutPresets = PORTAL_VARIABLES_PRESETS;\r\n }\r\n\r\n public prepareData(variables: ObjectString): Array>> {\r\n const data: Array>> = [];\r\n for (const variable of Object.keys(variables)) {\r\n data.push({\r\n id: '0',\r\n type: '',\r\n attributes: {\r\n name: variable,\r\n value: variables[variable]\r\n }\r\n });\r\n }\r\n return data;\r\n }\r\n\r\n protected variablesQueue(): Array {\r\n return [\r\n PortalVariablesEnum.AccentColor,\r\n PortalVariablesEnum.ButtonColor,\r\n PortalVariablesEnum.MainColor,\r\n PortalVariablesEnum.SectionBackgroundColor,\r\n ];\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { fromEvent, merge, Observable, of } from 'rxjs';\r\nimport { map, switchMap } from 'rxjs/operators';\r\nimport { MobileEnum } from '@app/common/enums/mobile.enum';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ResizeListener {\r\n get isMobile$(): Observable {\r\n return merge(this.onLoad(), this.onResize()).pipe(\r\n switchMap(value => {\r\n if (!value) {\r\n return this.isMobileDevice();\r\n }\r\n return of(value);\r\n })\r\n );\r\n }\r\n\r\n private onResize(): Observable {\r\n return fromEvent(window, 'resize').pipe(map(() => window.innerWidth < MobileEnum.Large));\r\n }\r\n\r\n private onLoad(): Observable {\r\n return of(window.innerWidth < MobileEnum.Large);\r\n }\r\n private isMobileDevice(): Observable {\r\n return of(/iPhone|iPad|iPod|Android/i.test(navigator.userAgent));\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\n\r\ndeclare var $: Function;\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ScrollToService {\r\n\r\n constructor() {}\r\n\r\n animate(id: string, time: number = 500, scrollDifference: number = 70) {\r\n try {\r\n $('html, body').animate({\r\n scrollTop: ($(id).offset().top as number) - scrollDifference,\r\n }, time);\r\n } catch (ignore) {\r\n }\r\n }\r\n\r\n resetScrollTop() {\r\n window.scrollTo(0, 0);\r\n }\r\n}\r\n\r\n","import { Injectable } from '@angular/core';\r\nimport { API } from '@app/common/constants/api.directories';\r\nimport { ApiService } from '@app/common/services/api.service';\r\nimport { Observable } from 'rxjs';\r\nimport { BootstrapModel } from '@app/common/models/bootstrap.model';\r\nimport { ResponseObject } from '@share/common/models/http';\r\nimport { ThemesEnum } from '@app/common/models/themes.enum';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class SettingsService {\r\n variables: T;\r\n\r\n constructor(private apiService: ApiService) {}\r\n\r\n load(): Promise> {\r\n return this.apiService.get(API.SETTINGS.ROOT).toPromise();\r\n }\r\n\r\n loadDefaultVariables(): Observable {\r\n return this.apiService.assets(API.ASSETS.DEFAULT_SETTINGS);\r\n }\r\n\r\n isModuleActive(theme: ThemesEnum): boolean {\r\n return this.variables.theme.modules.includes(theme);\r\n }\r\n}\r\n","import {Injectable} from '@angular/core';\r\nimport {Location} from '@angular/common';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class UrlService {\r\n constructor(private location: Location) {}\r\n\r\n getParsedUrl(): string {\r\n const path: string = this.location.path();\r\n return path.substr(1, path.length).replace(/\\//g, ',');\r\n }\r\n\r\n getLastUrlElement(): string {\r\n const paths: string[] = this.getParsedUrl().split(',');\r\n return paths[paths.length - 1];\r\n }\r\n}\r\n","import { CommonModule } from '@angular/common';\r\nimport { NgModule } from '@angular/core';\r\nimport { AccordionComponent } from './component/accordion/accordion.component';\r\nimport { AccPanelTitleDirective, AccPanelContentDirective, AccPanelDirective } from './directives/accordion-panel.directive';\r\n\r\n@NgModule({\r\n imports: [CommonModule],\r\n exports: [\r\n AccordionComponent,\r\n AccPanelTitleDirective,\r\n AccPanelContentDirective,\r\n AccPanelDirective\r\n ],\r\n declarations: [\r\n AccordionComponent,\r\n AccPanelTitleDirective,\r\n AccPanelContentDirective,\r\n AccPanelDirective\r\n ]\r\n})\r\nexport class AccordionModule {}\r\n","import { AfterContentChecked, Component, ContentChildren, EventEmitter, Input, Output, QueryList, ViewEncapsulation } from '@angular/core';\r\nimport { AccPanelChangeEvent } from '../../interfaces/accordion-panel-change-event.model';\r\nimport { AccPanelDirective } from '../../directives/accordion-panel.directive';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\n\r\n@Component({\r\n selector: 'app-accordion',\r\n templateUrl: './accordion.component.html',\r\n styleUrls: ['./accordion.component.scss']\r\n})\r\nexport class AccordionComponent extends ComponentHelper implements AfterContentChecked {\r\n @ContentChildren(AccPanelDirective) panels: QueryList;\r\n @Input() activeIds: string[] = [];\r\n @Output() readonly panelChange = new EventEmitter();\r\n\r\n constructor() {\r\n super();\r\n }\r\n\r\n private _findPanelById(panelId: string): AccPanelDirective | undefined {\r\n return this.panels.find(p => p.id === panelId);\r\n }\r\n\r\n\r\n private _updateActiveIds() {\r\n this.activeIds = this.panels.filter(panel => panel.isOpen && !panel.disabled).map(panel => panel.id);\r\n }\r\n\r\n private _changeOpenState(panel: AccPanelDirective, nextState: boolean, target: EventTarget) {\r\n if (panel && !panel.disabled && panel.isOpen !== nextState) {\r\n let defaultPrevented = false;\r\n\r\n this.panelChange.emit({\r\n panelId: panel.id,\r\n nextState: nextState,\r\n target,\r\n prevent: () => { defaultPrevented = true; }\r\n });\r\n\r\n if (!defaultPrevented) {\r\n panel.isOpen = nextState;\r\n\r\n this._updateActiveIds();\r\n }\r\n }\r\n }\r\n\r\n toggle(panelId: string, target: EventTarget) {\r\n const panel = this._findPanelById(panelId);\r\n if (panel) {\r\n this._changeOpenState(panel, !panel.isOpen, target);\r\n }\r\n }\r\n\r\n isPanelActive(panelId: string): boolean {\r\n return this.activeIds && this.activeIds.indexOf(panelId) !== -1;\r\n }\r\n\r\n expandAll() {\r\n this.panels.forEach(panel => {\r\n if (this.activeIds.indexOf(panel.id) === -1) {\r\n this.activeIds.push(panel.id);\r\n }\r\n });\r\n }\r\n\r\n ngAfterContentChecked() {\r\n this.panels.forEach(panel => panel.isOpen = !panel.disabled && this.activeIds.indexOf(panel.id) > -1);\r\n }\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { AfterContentChecked, ContentChildren, Directive, Input, QueryList, TemplateRef } from '@angular/core';\r\n\r\n@Directive({selector: 'ng-template[appAccPanelTitle]'})\r\nexport class AccPanelTitleDirective {\r\n constructor(public templateRef: TemplateRef) {}\r\n}\r\n\r\n@Directive({selector: 'ng-template[appAccPanelContent]'})\r\nexport class AccPanelContentDirective {\r\n constructor(public templateRef: TemplateRef) {}\r\n}\r\n\r\n@Directive({selector: '[appAccPanel]'})\r\nexport class AccPanelDirective implements AfterContentChecked {\r\n\r\n @Input() disabled = false;\r\n @Input() id: string;\r\n @Input() title: string;\r\n @Input() type: string;\r\n @Input() isOpen = false;\r\n\r\n @ContentChildren(AccPanelTitleDirective, {descendants: false}) titleTpls: QueryList;\r\n @ContentChildren(AccPanelContentDirective, {descendants: false}) contentTpls: QueryList;\r\n\r\n titleTpl: AccPanelTitleDirective | null;\r\n contentTpl: AccPanelContentDirective | null;\r\n\r\n constructor() { }\r\n\r\n ngAfterContentChecked() {\r\n this.titleTpl = this.titleTpls.first;\r\n this.contentTpl = this.contentTpls.first;\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { MultiCarouselComponent } from './components/multi-carousel/multi-carousel.component';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { PolygonModule } from '@app/template/elements/polygon/polygon.module';\r\n\r\n@NgModule({\r\n declarations: [\r\n MultiCarouselComponent\r\n ],\r\n imports: [\r\n CommonModule,\r\n TranslatorModule,\r\n PolygonModule\r\n ],\r\n exports: [\r\n MultiCarouselComponent\r\n ]\r\n})\r\nexport class CarouselModule {}\r\n","import { AfterViewChecked, Component, ElementRef, Input } from '@angular/core';\r\nimport { MultiCarousel } from '../../models/multi-carousel.model';\r\nimport { MultiCarouselConfig } from '../../models/multi-carousel-config.model';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { AbstractData } from '@share/common/models/http';\r\n\r\ndeclare var $: Function;\r\n\r\n@Component({\r\n selector: 'app-multi-carousel',\r\n templateUrl: './multi-carousel.component.html',\r\n styleUrls: [\r\n './multi-carousel.component.scss'\r\n ]\r\n})\r\nexport class MultiCarouselComponent extends ComponentHelper implements AfterViewChecked {\r\n @Input() data: Array> = [];\r\n\r\n @Input()\r\n set config(config: MultiCarouselConfig) {\r\n this._config = Object.assign(this._config, config);\r\n }\r\n\r\n private _config: MultiCarouselConfig = {\r\n dots: true,\r\n nav: true,\r\n itemsOnScreen: {\r\n 0: {\r\n items: 2\r\n },\r\n 600: {\r\n items: 3\r\n },\r\n 1000: {\r\n items: 4\r\n }\r\n },\r\n autoplayHoverPause: false,\r\n autoplay: false,\r\n autoplayTimeout: 5000,\r\n loop: false\r\n };\r\n\r\n get config() {\r\n return this._config;\r\n }\r\n\r\n private isCarouselInit = false;\r\n\r\n constructor(private elementRef: ElementRef) {\r\n super();\r\n }\r\n\r\n public initCarousel(): void {\r\n const owl = $('.owl-carousel').owlCarousel({\r\n margin: 0,\r\n responsive: this.config.itemsOnScreen,\r\n dots: this.config.dots,\r\n nav: this.config.nav,\r\n dotsContainer: '#owl-carousel-custom-dots',\r\n navContainer: '#owl-carousel-custom-nav',\r\n navText: [\r\n ``,\r\n ``\r\n ],\r\n autoplay: this.config.autoplay,\r\n autoplayTimeout: this.config.autoplayTimeout,\r\n autoplayHoverPause: this.config.autoplayHoverPause,\r\n loop: this.config.loop\r\n });\r\n $('.owl-dots').on('click', 'li', function (e: any) {\r\n // @ts-ignore\r\n owl.trigger('to.owl.carousel', [$(this).index(), 300]);\r\n });\r\n }\r\n\r\n\r\n private setAriaLabels() {\r\n const dots = this.elementRef.nativeElement.querySelectorAll('.owl-dot');\r\n dots.forEach((dot: HTMLButtonElement, index: number) => {\r\n dot.setAttribute('aria-label', this.trans('global.goToPage') + (index + 1));\r\n });\r\n }\r\n\r\n getLink(url: string): string {\r\n return url?.length > 3 && url.substr(0, 3) === 'www' ? `//${url}` : url\r\n }\r\n\r\n ngAfterViewChecked() {\r\n const carousel = $('.owl-carousel');\r\n if (carousel.length > 0 && !this.isCarouselInit) {\r\n setTimeout(() => {\r\n this.initCarousel();\r\n this.setAriaLabels();\r\n });\r\n this.isCarouselInit = true;\r\n }\r\n }\r\n}\r\n","\r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n\r\n\r\n","import {Component, Input} from '@angular/core';\r\n\r\n@Component({\r\n selector: 'shared-heading-section',\r\n templateUrl: './heading-section.component.html',\r\n styleUrls: ['./heading-section.component.scss']\r\n})\r\nexport class HeadingSectionComponent {\r\n @Input() number: number = 0;\r\n @Input() subtitle: string = '';\r\n @Input() title: string;\r\n @Input() innerColor: boolean = false;\r\n @Input() hsClass: string;\r\n\r\n}\r\n","\r\n \r\n {{ title }}\r\n \r\n - {{subtitle}}\r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { HeadingSectionComponent } from './components/heading-section/heading-section.component';\r\nimport {PolygonModule} from '@app/template/elements/polygon/polygon.module';\r\n\r\n@NgModule({\r\n declarations: [\r\n HeadingSectionComponent\r\n ],\r\n exports: [\r\n HeadingSectionComponent\r\n ],\r\n imports: [\r\n CommonModule,\r\n PolygonModule\r\n ]\r\n})\r\nexport class HeadingModule { }\r\n","import { Component, Input } from '@angular/core';\r\nimport { NgbActiveModal } from '@ng-bootstrap/ng-bootstrap';\r\nimport { ImageZoom } from '@app/template/elements/image-zoom/interfaces/image-zoom.interface';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\n\r\n@Component({\r\n selector: 'app-image-zoom',\r\n templateUrl: './image-zoom.component.html'\r\n})\r\nexport class ImageZoomComponent extends ComponentHelper {\r\n @Input() public data: ImageZoom;\r\n public loading: boolean = true;\r\n public placeholder: boolean = false;\r\n\r\n constructor(private activeModal: NgbActiveModal) {\r\n super();\r\n }\r\n\r\n public close() {\r\n this.activeModal.close();\r\n }\r\n\r\n public onLoad() {\r\n this.loading = false;\r\n }\r\n\r\n public onError() {\r\n this.onLoad();\r\n this.placeholder = true;\r\n }\r\n}\r\n","\r\n {{data.alt}}\r\n \r\n {{'x'}}\r\n \r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { ImageZoomComponent } from '@app/template/elements/image-zoom/components/image-zoom/image-zoom.component';\r\nimport { ProgressBarModule } from '@share/modules/progress-bar/progress-bar.module';\r\nimport { CommonModule } from '@angular/common';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n ProgressBarModule\r\n ],\r\n declarations: [\r\n ImageZoomComponent\r\n ],\r\n exports: [\r\n ImageZoomComponent\r\n ],\r\n entryComponents: [\r\n ImageZoomComponent\r\n ]\r\n})\r\nexport class ImageZoomModule {}\r\n","import { Component, Input } from '@angular/core';\r\nimport { ControlValueAccessor, NgControl } from '@angular/forms';\r\n\r\n@Component({\r\n selector: 'app-input',\r\n templateUrl: 'input.component.html',\r\n styleUrls: ['input.component.scss']\r\n})\r\nexport class InputComponent implements ControlValueAccessor {\r\n\r\n @Input() label: string;\r\n @Input() id: string;\r\n\r\n private onChange: (v: string) => void = (v: string) => {};\r\n private onTouch: () => void = () => {};\r\n\r\n value: string;\r\n\r\n constructor(private ngControl: NgControl) {\r\n this.ngControl.valueAccessor = this;\r\n }\r\n\r\n registerOnChange(fn: any): void {\r\n this.onChange = fn;\r\n }\r\n\r\n registerOnTouched(fn: any): void {\r\n this.onTouch = fn;\r\n }\r\n\r\n writeValue(obj: any): void {\r\n this.value = obj;\r\n this.onChange(obj);\r\n }\r\n}\r\n","\r\n \r\n {{ label }}\r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { InputComponent } from '@app/template/elements/input/input.component';\r\nimport { FormsModule } from '@angular/forms';\r\n\r\n@NgModule({\r\n declarations: [InputComponent],\r\n exports: [InputComponent],\r\n imports: [CommonModule, FormsModule]\r\n})\r\nexport class InputModule {}\r\n","import { Component, EventEmitter, Input, Output } from '@angular/core';\r\nimport { PaginationService } from '../../services/pagination.service';\r\n\r\n@Component({\r\n selector: 'shared-pagination',\r\n templateUrl: './pagination.component.html',\r\n styleUrls: ['./pagination.component.scss'],\r\n})\r\nexport class PaginationComponent {\r\n\r\n @Input() public perPage: number = 10;\r\n @Input() public pages: number = 1;\r\n @Input() public position: 'left' | 'right' = 'right';\r\n @Output() readonly changed: EventEmitter = new EventEmitter();\r\n\r\n constructor(private paginationService: PaginationService) {}\r\n\r\n\r\n public get total(): number {\r\n return this.perPage * this.pages;\r\n }\r\n\r\n public set currentPage(value: number) {\r\n this.paginationService.page = value;\r\n this.changed.emit(value);\r\n }\r\n\r\n public get currentPage(): number {\r\n return this.paginationService.page;\r\n }\r\n\r\n\r\n}\r\n"," 1\">\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n {{'...'}}\r\n {{ currentPage }}\r\n \r\n \r\n \r\n\r\n","import {NgModule} from '@angular/core';\r\nimport {CommonModule} from '@angular/common';\r\nimport {PaginationComponent} from './components/pagination/pagination.component';\r\nimport {NgbPaginationModule} from '@ng-bootstrap/ng-bootstrap';\r\nimport {PaginationService} from './services/pagination.service';\r\n\r\n@NgModule({\r\n declarations: [\r\n PaginationComponent\r\n ],\r\n imports: [\r\n CommonModule,\r\n NgbPaginationModule\r\n ],\r\n exports: [\r\n PaginationComponent\r\n ],\r\n providers: [\r\n PaginationService\r\n ]\r\n})\r\nexport class PaginationModule {}\r\n","import { Injectable } from '@angular/core';\r\nimport { BehaviorSubject, Observable, Subscription } from 'rxjs';\r\nimport { ComponentShareHelper } from '@share/common/helpers/component-share.helper';\r\nimport { FacadeShareService } from '@share/common/services/facade-share.service';\r\nimport { ActivatedRoute, Params } from '@angular/router';\r\n\r\n@Injectable()\r\nexport class PaginationService extends ComponentShareHelper {\r\n private firstPage: number = 1;\r\n private _page: BehaviorSubject = new BehaviorSubject(this.firstPage);\r\n\r\n constructor(private facadeShareService: FacadeShareService,\r\n private activatedRoute: ActivatedRoute) {\r\n super(facadeShareService);\r\n this.setParamsListener();\r\n }\r\n\r\n public setParamsListener() {\r\n return this.activatedRoute.queryParams.subscribe((params: Params) => {\r\n if (params.page) {\r\n this.page = parseInt(params.page, 10);\r\n } else {\r\n this._page.next(this.firstPage);\r\n }\r\n });\r\n }\r\n\r\n private changeQueryParams(value: number) {\r\n setTimeout(() => {\r\n this.facadeShareService.router.navigate([], {\r\n relativeTo: this.activatedRoute,\r\n queryParams: {page: value === this.firstPage ? null : value}\r\n });\r\n });\r\n }\r\n\r\n public set page(value: number) {\r\n if (value !== this.page) {\r\n this._page.next(value);\r\n this.changeQueryParams(value);\r\n }\r\n }\r\n\r\n public get page(): number {\r\n return this._page.getValue();\r\n }\r\n\r\n public get currentPage(): Observable {\r\n return this._page.asObservable();\r\n }\r\n}\r\n","import { Component, Input } from '@angular/core';\r\nimport { UtilsService } from '@share/common/services/utils.service';\r\n\r\n@Component({\r\n selector: 'shared-hexagon-content',\r\n templateUrl: './hexagon-content.component.html',\r\n styleUrls: ['./hexagon-content.component.scss']\r\n})\r\nexport class HexagonContentComponent {\r\n @Input() bgColor: string;\r\n @Input() borderColor: string;\r\n @Input() borderWidth: number = 0;\r\n @Input() width: number = 100;\r\n @Input() height: number = 100;\r\n @Input() isInnerShadow: boolean = false;\r\n @Input() innerShadowConfig: { alpha: number, blur: number } = {alpha: 0.3, blur: 2};\r\n @Input() isOuterShadow: boolean = false;\r\n @Input() isHover: boolean = false;\r\n @Input() bgGradient: boolean = false;\r\n @Input() borderGradient: boolean = false;\r\n @Input() edgeRounded: boolean = false;\r\n @Input() bgImage: string = '';\r\n\r\n public innerShadowID: string = '';\r\n\r\n constructor(private utils: UtilsService) {\r\n this.innerShadowID = this.utils.makeId();\r\n }\r\n\r\n public get location() {\r\n return window.location.href;\r\n }\r\n\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport {HexagonContentComponent} from './components/hexagon-content/hexagon-content.component';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule\r\n ],\r\n declarations: [\r\n HexagonContentComponent\r\n ],\r\n exports: [\r\n HexagonContentComponent\r\n ]\r\n})\r\nexport class PolygonModule {\r\n}\r\n","import { Component, Input, ViewEncapsulation } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'app-promoted-item-icon',\r\n styleUrls: ['promoted-item-icon.component.scss'],\r\n templateUrl: 'promoted-item-icon.component.html',\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class PromotedItemIconComponent {\r\n\r\n @Input() icon: string;\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n\r\n","import { Component, ElementRef, EventEmitter, Input, OnDestroy, Output, Renderer2 } from '@angular/core';\r\nimport { Promoted } from '../../models/promoted.model';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { AbstractData } from '@share/common/models/http';\r\n\r\n@Component({\r\n selector: 'app-promoted-list',\r\n templateUrl: './promoted-list.component.html',\r\n styleUrls: [`./promoted-list.component.scss`]\r\n})\r\nexport class PromotedListComponent extends ComponentHelper implements OnDestroy {\r\n @Input() data: Array>;\r\n\r\n @Input() filter: string;\r\n @Input() height: number = 420;\r\n @Input() background?: string = '';\r\n @Input() hasIcon: boolean = false;\r\n @Output() readonly clicked: EventEmitter = new EventEmitter();\r\n private listenClickFunc: Function;\r\n\r\n constructor(private renderer: Renderer2, private _elementRef: ElementRef) {\r\n super();\r\n this.onClickListener();\r\n }\r\n\r\n private onClickListener(): void {\r\n this.listenClickFunc = this.renderer.listen(this._elementRef.nativeElement, 'click', event =>\r\n this.shareService.utils.navigateTo(event)\r\n );\r\n }\r\n\r\n public imagePath(path: string) {\r\n return this.shareService.image.img({ file: path, filter: this.filter });\r\n }\r\n\r\n public navigateTo(event: Event, url: string, id: string) {\r\n event.preventDefault();\r\n event.stopPropagation();\r\n window.open(url);\r\n this.onClick(id);\r\n }\r\n\r\n public onClick(slug: string) {\r\n this.clicked.emit(slug);\r\n }\r\n\r\n public ngOnDestroy() {\r\n this.listenClickFunc();\r\n }\r\n\r\n public get dataExists(): boolean {\r\n return Array.isArray(this.data) && this.data.length > 0;\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n {{ promoted.attributes.title | truncate: 50 }}\r\n \r\n {{'global.findOutMore' | trans}}\r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { PolygonModule } from '../polygon/polygon.module';\r\nimport { PromotedListComponent } from './components/promoted-list/promoted-list.component';\r\nimport { CommonModule } from '@angular/common';\r\nimport { RouterModule } from '@angular/router';\r\nimport { TruncateModule } from '@share/modules/truncate/truncate.module';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { PromotedItemIconComponent } from './components/promoted-item-icon/promoted-item-icon.component';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\n\r\n@NgModule({\r\n declarations: [\r\n PromotedListComponent,\r\n PromotedItemIconComponent\r\n ],\r\n imports: [\r\n CommonModule,\r\n RouterModule,\r\n PolygonModule,\r\n TruncateModule,\r\n ElementsModule,\r\n TranslatorModule\r\n ],\r\n exports: [\r\n PromotedListComponent\r\n ]\r\n})\r\nexport class PromotedModule {\r\n}\r\n","import { ChangeDetectionStrategy, Component, OnInit } from '@angular/core';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { PagesService } from '@app/common/services/pages.service';\r\nimport { first } from 'rxjs/operators';\r\n\r\n@Component({\r\n selector: 'app-simple-box',\r\n styleUrls: ['simple-box.component.scss'],\r\n templateUrl: 'simple-box.component.html',\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class SimpleBoxComponent implements OnInit {\r\n data: {\r\n button: string;\r\n contactBoxIcon: string;\r\n contactPage: string;\r\n content: string;\r\n title: string;\r\n };\r\n\r\n constructor(private facadeService: FacadeService, private pageService: PagesService) {}\r\n\r\n ngOnInit() {\r\n this.data = this.facadeService.settings.variables.contactBox;\r\n }\r\n\r\n onButtonClick() {\r\n this.pageService\r\n .getOne(this.data.contactPage)\r\n .pipe(first())\r\n .subscribe(page => this.facadeService.router.navigate([page.data.id.replace(',', '/')]));\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n\r\n {{ data.title }}\r\n {{ data.content }}\r\n \r\n\r\n \r\n\r\n \r\n\r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { SimpleBoxComponent } from '@app/template/elements/simple-box/components/simple-box.component';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { CommonModule } from '@angular/common';\r\n\r\n@NgModule({\r\n declarations: [SimpleBoxComponent],\r\n imports: [\r\n ElementsModule,\r\n CommonModule\r\n ],\r\n exports: [SimpleBoxComponent]\r\n})\r\nexport class SimpleBoxModule {\r\n\r\n}\r\n","import { Component, Input } from '@angular/core';\r\nimport { ControlValueAccessor, NgControl } from '@angular/forms';\r\n\r\n@Component({\r\n selector: 'app-textarea',\r\n templateUrl: 'textarea.component.html',\r\n styleUrls: ['textarea.component.scss']\r\n})\r\nexport class TextareaComponent implements ControlValueAccessor {\r\n\r\n @Input() label: string;\r\n @Input() id: string;\r\n\r\n private onChange: (v: string) => void = (v: string) => {};\r\n private onTouch: () => void = () => {};\r\n\r\n value: string;\r\n\r\n constructor(private ngControl: NgControl) {\r\n this.ngControl.valueAccessor = this;\r\n }\r\n\r\n registerOnChange(fn: any): void {\r\n this.onChange = fn;\r\n }\r\n\r\n registerOnTouched(fn: any): void {\r\n this.onTouch = fn;\r\n }\r\n\r\n writeValue(obj: any): void {\r\n this.value = obj;\r\n this.onChange(obj);\r\n }\r\n}\r\n","\r\n \r\n {{ label }}\r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { TextareaComponent } from './textarea.component';\r\nimport { CommonModule } from '@angular/common';\r\nimport { FormsModule } from '@angular/forms';\r\n\r\n@NgModule({\r\n imports: [CommonModule, FormsModule],\r\n declarations: [TextareaComponent],\r\n exports: [TextareaComponent]\r\n})\r\nexport class TextareaModule {}\r\n","import { ChangeDetectionStrategy, Component, Input } from '@angular/core';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { MultiCarousel } from '@app/template/elements/carousel/models/multi-carousel.model';\r\nimport { MultiCarouselConfig } from '@app/template/elements/carousel/models/multi-carousel-config.model';\r\nimport { ImageCropper } from '@app/template/home/models/image-cropper.model';\r\n\r\n@Component({\r\n selector: 'app-gallery',\r\n templateUrl: 'gallery.component.html',\r\n styleUrls: ['gallery.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class GalleryComponent {\r\n config: MultiCarouselConfig = {\r\n dots: false,\r\n nav: true,\r\n itemsOnScreen: {\r\n 0: {\r\n items: 2\r\n },\r\n 700: {\r\n items: 2\r\n },\r\n 800: {\r\n items: 2\r\n },\r\n 1140: {\r\n items: 3\r\n },\r\n 1370: {\r\n items: 4\r\n }\r\n },\r\n autoplayHoverPause: false,\r\n autoplay: false,\r\n autoplayTimeout: 5000,\r\n loop: false\r\n };\r\n\r\n @Input() set data(value: { gallery: AbstractData<{ image: ImageCropper; alt: string }>[] }) {\r\n if (value) {\r\n this.parsedData = value.gallery.map(item => ({\r\n id: item.id,\r\n type: item.type,\r\n attributes: {\r\n file: item.attributes.image.url || (item.attributes.image.croppedUrl as string),\r\n description: item.attributes.alt,\r\n url: '',\r\n isOpenInNewWindow: false\r\n }\r\n }));\r\n }\r\n }\r\n parsedData: Array> = [];\r\n}\r\n","\r\n \r\n \r\n \r\n\r\n\r\n\r\n Galeria\r\n \r\n\r\n\r\n\r\n \r\n \r\n \r\n\r\n","import { ChangeDetectionStrategy, Component, Input } from '@angular/core';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { HomeIntroModel } from '@app/template/home/models/home-intro.model';\r\n\r\n@Component({\r\n selector: 'app-main-banner',\r\n templateUrl: 'main-banner.component.html',\r\n styleUrls: ['main-banner.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class MainBannerComponent {\r\n\r\n @Input() data: HomeIntroModel;\r\n\r\n constructor(private facadeService: FacadeService) {\r\n }\r\n\r\n scrollDown() {\r\n this.facadeService.scrollTo.animate('#promoted', 800, 100);\r\n }\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { ChangeDetectionStrategy, ChangeDetectorRef, Component, Input, OnChanges, SimpleChanges } from '@angular/core';\r\nimport { ArticlesService } from '@app/client-core/article/services/articles.service';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { Article } from '@app/client-core/article/models/article.model';\r\nimport { finalize, first, switchMap } from 'rxjs/operators';\r\nimport { Router } from '@angular/router';\r\nimport { PagesService } from '@app/common/services/pages.service';\r\nimport { DynamicContentService } from '@app/client-core/dynamic-content/service/dynamic-content.service';\r\n\r\n@Component({\r\n selector: 'app-news',\r\n styleUrls: ['news.component.scss'],\r\n templateUrl: 'news.component.html',\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class NewsComponent implements OnChanges {\r\n news: AbstractData[];\r\n loading: boolean;\r\n getError: boolean;\r\n\r\n @Input() data: {\r\n title: string;\r\n subtitle: string;\r\n category: string;\r\n };\r\n\r\n constructor(\r\n private articleService: ArticlesService,\r\n private cdr: ChangeDetectorRef,\r\n private pageService: PagesService,\r\n private router: Router,\r\n private dynamicContentService: DynamicContentService\r\n ) {}\r\n\r\n ngOnChanges(changes: SimpleChanges): void {\r\n if (changes.data.currentValue) {\r\n this.getNews();\r\n }\r\n }\r\n\r\n setLoader(value: boolean) {\r\n this.loading = value;\r\n this.cdr.detectChanges();\r\n }\r\n\r\n test() {\r\n this.pageService.getOne();\r\n }\r\n\r\n getNews() {\r\n this.setLoader(true);\r\n this.pageService\r\n .getOne(this.data.category)\r\n .pipe(\r\n first(),\r\n finalize(() => this.setLoader(false))\r\n )\r\n .subscribe(\r\n response => this.getMetadata(response.data.id),\r\n error => (this.getError = true)\r\n );\r\n }\r\n\r\n getMetadata(url: string) {\r\n this.dynamicContentService\r\n .getPageMetadata(url)\r\n .pipe(switchMap(metadata => this.articleService.getList(1, 4, metadata.meta?.objectId)))\r\n .subscribe(news => {\r\n this.news = news.data;\r\n this.cdr.detectChanges();\r\n });\r\n }\r\n\r\n showMoreClicked() {\r\n this.router.navigate(['aktualnosci']);\r\n }\r\n\r\n readMoreClicked(item: AbstractData) {\r\n this.router.navigate(['aktualnosci', item.attributes.slug]);\r\n }\r\n}\r\n","\r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n\r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n\r\n \r\n {{\r\n category.attributes.title\r\n }}\r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n {{ item.attributes.title }}\r\n \r\n \r\n {{ item.attributes.publishedFrom | date: 'shortDate':'':'pl' }}\r\n \r\n \r\n {{ item.attributes.description }}\r\n \r\n \r\n \r\n \r\n\r\n","import {\r\n AfterViewInit,\r\n ChangeDetectionStrategy,\r\n ChangeDetectorRef,\r\n Component,\r\n Input,\r\n OnInit,\r\n ViewChild,\r\n ViewContainerRef\r\n} from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { LazyLoaderService } from '@app/common/services/lazy-loader.service';\r\nimport { ROUTES_PATHS } from '@app/common/constants/routes-paths';\r\nimport { Router } from '@angular/router';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { finalize, first } from 'rxjs/operators';\r\nimport { HomeService } from '@app/template/home/services/home.service';\r\nimport { PagesService } from '@app/common/services/pages.service';\r\nimport { PageModel } from '@app/common/models/page.model';\r\nimport { HomeModel } from '@app/template/home/models/home.model';\r\n\r\n@Component({\r\n selector: 'app-home',\r\n templateUrl: './overlay.component.html',\r\n styleUrls: ['./overlay.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class OverlayComponent extends ComponentHelper implements OnInit, AfterViewInit {\r\n @ViewChild('businessModules', { read: ViewContainerRef }) businessModules: ViewContainerRef;\r\n @Input() data: AbstractData>;\r\n loading: boolean = true;\r\n\r\n constructor(\r\n private settingsService: SettingsService,\r\n private lazyLoaderService: LazyLoaderService,\r\n private pagesService: PagesService,\r\n private router: Router,\r\n private cdr: ChangeDetectorRef,\r\n private homeService: HomeService\r\n ) {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n this.service.scrollTo.resetScrollTop();\r\n }\r\n\r\n private setLoading(value: boolean) {\r\n this.loading = value;\r\n this.cdr.markForCheck();\r\n }\r\n\r\n getMainPage() {\r\n this.setLoading(true);\r\n this.pagesService\r\n .getOne()\r\n .pipe(\r\n first(),\r\n finalize(() => this.setLoading(false))\r\n )\r\n .subscribe(\r\n response => {\r\n this.data = response.data;\r\n },\r\n () => {\r\n this.router.navigate(['/', ROUTES_PATHS.notFoundPage.root]);\r\n }\r\n );\r\n }\r\n\r\n ngAfterViewInit() {\r\n if (!this.data) {\r\n this.getMainPage();\r\n } else {\r\n this.loading = false;\r\n this.homeService.isHomePreview = true;\r\n }\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n\r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { ChangeDetectionStrategy, ChangeDetectorRef, Component, Input, OnInit } from '@angular/core';\r\nimport { PromotedService } from '@app/template/home/services/promoted.service';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { Promoted } from '@app/template/elements/promoted/models/promoted.model';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { finalize, first } from 'rxjs/operators';\r\n\r\n@Component({\r\n selector: 'app-promoted',\r\n templateUrl: './promoted.component.html',\r\n styleUrls: ['./promoted.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class PromotedComponent extends ComponentHelper implements OnInit {\r\n @Input() data: { title: string; subtitle: string };\r\n promoted: Array> = [];\r\n loading: boolean = false;\r\n\r\n constructor(private promotedService: PromotedService, private cdr: ChangeDetectorRef) {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n this.loadPromoted();\r\n }\r\n\r\n loadPromoted() {\r\n this.setLoading(true);\r\n this.promotedService\r\n .getList()\r\n .pipe(\r\n first(),\r\n finalize(() => this.setLoading(false))\r\n )\r\n .subscribe(\r\n response => (this.promoted = this.getResponseData(response)),\r\n () => this.setComponentError()\r\n );\r\n }\r\n\r\n private setLoading(value: boolean) {\r\n this.loading = value;\r\n this.cdr.markForCheck();\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { ChangeDetectionStrategy, Component, Input } from '@angular/core';\r\nimport { HomeReportCrashModel } from '@app/template/home/models/home-report-crash.model';\r\n\r\n@Component({\r\n selector: 'app-report-crash',\r\n templateUrl: 'report-crash.component.html',\r\n styleUrls: ['report-crash.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class ReportCrashComponent {\r\n @Input() data: HomeReportCrashModel;\r\n}\r\n","\r\n \r\n \r\n \r\n {{ data?.title }}\r\n {{ data?.content }}\r\n \r\n \r\n \r\n \r\n \r\n {{ data?.contactOne?.title }}\r\n \r\n \r\n {{ data?.contactOne.phone }}\r\n \r\n \r\n \r\n {{ data?.contactOne.officeHours }}\r\n \r\n \r\n \r\n {{ data?.contactTwo?.title }}\r\n \r\n \r\n \r\n {{ data?.contactTwo?.phone }}\r\n \r\n \r\n \r\n \r\n {{ data?.contactTwo?.officeHours }}\r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { ChangeDetectionStrategy, ChangeDetectorRef, Component, Input, OnChanges, SimpleChanges } from '@angular/core';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { PagesService } from '@app/common/services/pages.service';\r\nimport { finalize, first } from 'rxjs/operators';\r\nimport { Router } from '@angular/router';\r\n\r\n@Component({\r\n selector: 'app-schedule',\r\n templateUrl: 'schedule.component.html',\r\n styleUrls: ['schedule.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class ScheduleComponent implements OnChanges {\r\n @Input() data: {\r\n title: string;\r\n subtitle: string;\r\n pageId: string;\r\n };\r\n\r\n scheduleElements: {\r\n boxTitle: string;\r\n boxSubtitle: string;\r\n boxPhone: string;\r\n schedule: { cities: string; date: string }[];\r\n };\r\n\r\n url: string;\r\n\r\n constructor(private pageService: PagesService, private cdr: ChangeDetectorRef, private router: Router) {}\r\n\r\n ngOnChanges(changes: SimpleChanges): void {\r\n if (changes.data.currentValue.pageId) {\r\n this.pageService\r\n .getOne(changes.data.currentValue.pageId)\r\n .pipe(\r\n first(),\r\n finalize(() => this.cdr.detectChanges())\r\n )\r\n .subscribe(e => {\r\n this.url = e.data.id.replace(',', '/');\r\n this.scheduleElements = e.data.attributes.content.content;\r\n this.scheduleElements.schedule = this.scheduleElements.schedule.filter(\r\n (item: any, index: number) => index < 4\r\n );\r\n });\r\n }\r\n }\r\n\r\n redirectToMore() {\r\n this.router.navigate([this.url]);\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n\r\n\r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n\r\n\r\n \r\n \r\n \r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n {{ title }}\r\n \r\n \r\n {{ text }}\r\n \r\n \r\n \r\n {{ phone }}\r\n \r\n \r\n\r\n\r\n \r\n {{ item.date }}\r\n {{ item.cities }}\r\n \r\n\r\n","export enum SitemapLoaders {\r\n GetAll = 'GetAll'\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { OverlayComponent } from '@app/template/home/components/overlay/overlay.component';\r\nimport { SearchModule } from '@app/client-core/search/search.module';\r\nimport { PromotedComponent } from '@app/template/home/components/promoted/promoted.component';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { CarouselModule } from '@app/template/elements/carousel/carousel.module';\r\nimport { LogoModule } from '@app/template/layout/modules/logo/logo.module';\r\nimport { TruncateModule } from '@share/modules/truncate/truncate.module';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { RouterModule } from '@angular/router';\r\nimport { SelectModule } from '@share/modules/html/select/select.module';\r\nimport { FormsModule } from '@angular/forms';\r\nimport { NgbCarouselModule, NgbPaginationModule } from '@ng-bootstrap/ng-bootstrap';\r\nimport { HeadingModule } from '@app/template/elements/heading/heading.module';\r\nimport { PromotedModule } from '@app/template/elements/promoted/promoted.module';\r\nimport { PolygonModule } from '@app/template/elements/polygon/polygon.module';\r\nimport { AccordionModule } from '@app/template/elements/accordion/accordion.module';\r\nimport { PaginationModule } from '@app/template/elements/pagination/pagination.module';\r\nimport { MainBannerComponent } from '@app/template/home/components/main-banner/main-banner.component';\r\nimport { ReportCrashComponent } from '@app/template/home/components/report-crash/report-crash.component';\r\nimport { ScheduleComponent } from '@app/template/home/components/schedule/schedule.component';\r\nimport { NewsComponent } from '@app/template/home/components/news/news.component';\r\nimport { GalleryComponent } from '@app/template/home/components/gallery/gallery.component';\r\nimport { SimpleBoxModule } from '@app/template/elements/simple-box/simple-box.module';\r\nimport { ArticleModule } from '@app/client-core/article/article.module';\r\n\r\n@NgModule({\r\n declarations: [\r\n GalleryComponent,\r\n NewsComponent,\r\n ScheduleComponent,\r\n ReportCrashComponent,\r\n MainBannerComponent,\r\n OverlayComponent,\r\n PromotedComponent,\r\n ],\r\n imports: [\r\n CommonModule,\r\n SearchModule,\r\n CarouselModule,\r\n ElementsModule,\r\n LogoModule,\r\n RouterModule,\r\n NgbCarouselModule,\r\n NgbPaginationModule,\r\n PromotedModule,\r\n SelectModule,\r\n FormsModule,\r\n TranslatorModule,\r\n PolygonModule,\r\n TruncateModule,\r\n AccordionModule,\r\n PaginationModule,\r\n HeadingModule,\r\n SimpleBoxModule,\r\n ArticleModule\r\n ],\r\n exports: [OverlayComponent]\r\n})\r\nexport class HomeModule {}\r\n","import { Injectable } from '@angular/core';\r\nimport { BehaviorSubject, Observable } from 'rxjs';\r\nimport { distinctUntilChanged } from 'rxjs/operators';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class HomeService {\r\n private _isHomePreview: BehaviorSubject = new BehaviorSubject(false);\r\n isHomePreview$: Observable = this._isHomePreview.asObservable().pipe(distinctUntilChanged());\r\n\r\n set isHomePreview(value: boolean) {\r\n this._isHomePreview.next(value);\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { ServiceHelper } from '@share/common/helpers/service.helper';\r\nimport { Bundle } from '@app/common/enums/server-bundles.enum';\r\nimport { Observable } from 'rxjs';\r\nimport { ResponseArray } from '@share/common/models/http.model';\r\nimport { API } from '@app/common/constants/api.directories';\r\nimport { Promoted } from '@app/template/elements/promoted/models/promoted.model';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class PromotedService extends ServiceHelper {\r\n constructor() {\r\n super(Bundle.Promoted);\r\n }\r\n\r\n public getList(): Observable> {\r\n return this.getAll(API.PROMOTED.ROOT);\r\n }\r\n}\r\n","import {Injectable} from '@angular/core';\r\nimport {ServiceHelper} from '@share/common/helpers/service.helper';\r\nimport {Bundle} from '@app/common/enums/server-bundles.enum';\r\nimport {Observable} from 'rxjs';\r\nimport {MenuModel} from '@app/client-core/menu/models/menu.model';\r\nimport {ResponseArray} from '@share/common/models/http';\r\nimport {API} from '@app/common/constants/api.directories';\r\nimport { ApiService } from '@app/common/services/api.service';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class SitemapService {\r\n\r\n constructor(private apiService: ApiService) {}\r\n\r\n getInstitutionData(): Observable {\r\n return this.apiService.get('institution');\r\n }\r\n\r\n public getList(): Observable> {\r\n return this.apiService.getAll(API.MENU.SITEMAP);\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { BreadcrumbsService } from '@app/template/layout/modules/header/services/breadcrumbs.service';\r\nimport { SubheaderService } from '@app/template/layout/modules/header/services/subheader.service';\r\nimport { Observable, of } from 'rxjs';\r\nimport { DynamicContentService } from '@app/client-core/dynamic-content/service/dynamic-content.service';\r\nimport { filter, takeUntil } from 'rxjs/operators';\r\nimport { NavigationEnd } from '@angular/router';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { SearchService } from '@app/client-core/search/services/search.service';\r\n\r\n@Component({\r\n selector: 'app-default',\r\n templateUrl: './default.component.html',\r\n styleUrls: ['./default.component.scss']\r\n})\r\nexport class DefaultComponent extends ComponentHelper {\r\n isHome: boolean = true;\r\n backdrop$: Observable;\r\n constructor(\r\n private breadcrumbsService: BreadcrumbsService,\r\n private subheaderService: SubheaderService,\r\n private settings: SettingsService,\r\n private dynamicContentService: DynamicContentService,\r\n private searchService: SearchService\r\n ) {\r\n super();\r\n this.setHome();\r\n this.backdrop$ = searchService.isActive$;\r\n }\r\n\r\n get contentLoaded(): Observable {\r\n return this.dynamicContentService.loaded$;\r\n }\r\n\r\n public deactivate() {\r\n this.breadcrumbsService.clear.next(true);\r\n this.subheaderService.reset();\r\n }\r\n\r\n private setHome() {\r\n this.service.router.events\r\n .pipe(\r\n filter((e): e is NavigationEnd => e instanceof NavigationEnd),\r\n takeUntil(this.destroyed$)\r\n )\r\n .subscribe(event => {\r\n this.isHome = event.url === '/';\r\n });\r\n }\r\n\r\n get canShow(): Observable {\r\n if (this.isHome) {\r\n return this.contentLoaded;\r\n }\r\n return of(true);\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { DefaultComponent } from './components/default/default.component';\r\nimport { HeaderModule } from '@app/template/layout/modules/header/header.module';\r\nimport { FooterModule } from '@app/template/layout/modules/footer/footer.module';\r\nimport { CookiesModule } from '@app/client-core/cookies/cookies.module';\r\nimport { DynamicContentModule } from '@app/client-core/dynamic-content/dynamic-content.module';\r\nimport { AppRoutingModule } from '@app/app-routing.module';\r\nimport { HomeModule } from '@app/template/home/home.module';\r\nimport { SiteMapModule } from '@app/template/layout/modules/sitemap/sitemap.module';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { PolygonModule } from '@app/template/elements/polygon/polygon.module';\r\n\r\n@NgModule({\r\n declarations: [DefaultComponent],\r\n imports: [\r\n CommonModule,\r\n HeaderModule,\r\n HomeModule,\r\n FooterModule,\r\n CookiesModule,\r\n DynamicContentModule,\r\n SiteMapModule,\r\n AppRoutingModule,\r\n ElementsModule,\r\n PolygonModule\r\n ]\r\n})\r\nexport class LayoutModule {}\r\n","import { NgModule } from '@angular/core';\r\nimport { BreadcrumbsComponent } from '@app/template/layout/modules/breadcrumbs/components/breadcrumbs/breadcrumbs.component';\r\nimport { CommonModule } from '@angular/common';\r\nimport { RouterModule } from '@angular/router';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\n\r\n@NgModule({\r\n declarations: [\r\n BreadcrumbsComponent\r\n ],\r\n imports: [\r\n CommonModule,\r\n RouterModule,\r\n TranslatorModule\r\n ],\r\n exports: [\r\n BreadcrumbsComponent\r\n ]\r\n})\r\nexport class BreadcrumbsModule {}\r\n","import { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { ChangeDetectorRef, Component, EventEmitter, OnInit, Output } from '@angular/core';\r\nimport { BreadcrumbsService } from '@app/template/layout/modules/header/services/breadcrumbs.service';\r\nimport { BreadcrumbsLoaders } from '@app/template/layout/modules/header/enums/breadcrumbs-loaders.enum';\r\nimport { Breadcrumbs } from '@app/template/layout/modules/header/models/breadcrumbs.model';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { AbstractData } from '@share/common/models/http';\r\n\r\n@Component({\r\n selector: 'app-breadcrumbs',\r\n templateUrl: './breadcrumbs.component.html',\r\n styleUrls: ['./breadcrumbs.component.scss']\r\n})\r\nexport class BreadcrumbsComponent extends ComponentHelper implements OnInit {\r\n public breadcrumbs: Array> = [];\r\n public shortVersion: boolean = false;\r\n public minLengthForShortVersion: number = 3;\r\n\r\n @Output() readonly loaded: EventEmitter = new EventEmitter();\r\n\r\n constructor(private breadcrumbsService: BreadcrumbsService, private cdr: ChangeDetectorRef) {\r\n super();\r\n }\r\n\r\n public get breadcrumbsExists(): boolean {\r\n return Array.isArray(this.breadcrumbs) && this.breadcrumbs.length > 0;\r\n }\r\n\r\n public ngOnInit() {\r\n this.setReloadListener();\r\n this.setClearListener();\r\n }\r\n\r\n private loadBreadcrumbs() {\r\n this.setLoader(BreadcrumbsLoaders.Get, true);\r\n this.subscriptions.add(\r\n this.breadcrumbsService.getList(this.url).subscribe(\r\n response => {\r\n this.breadcrumbs = this.getResponseData(response);\r\n this.shortVersion = this.breadcrumbs.length > this.minLengthForShortVersion;\r\n this.cdr.detectChanges();\r\n this.loaded.emit();\r\n },\r\n () => {}\r\n )\r\n );\r\n }\r\n\r\n private setReloadListener() {\r\n this.breadcrumbsService.reload.pipe(takeUntil(this.destroyed$)).subscribe(reload => {\r\n if (reload && !this.breadcrumbsService.forceActive) {\r\n this.breadcrumbsService.customBreadcrumbs = [];\r\n this.loadBreadcrumbs();\r\n this.cdr.detectChanges();\r\n }\r\n });\r\n }\r\n\r\n private setClearListener() {\r\n this.breadcrumbsService.clear.pipe(takeUntil(this.destroyed$)).subscribe(clear => {\r\n if (clear) {\r\n this.breadcrumbs = [];\r\n this.cdr.detectChanges();\r\n this.breadcrumbsService.clear.next(false);\r\n }\r\n });\r\n }\r\n\r\n public get customBreadcrumbs(): Array<{ title: string; url?: string }> {\r\n return this.breadcrumbsService.customBreadcrumbs;\r\n }\r\n\r\n private get url(): string {\r\n return this.breadcrumbsService.getParsedUrl(this.service.router.url);\r\n }\r\n\r\n public getLink(index: number): Array {\r\n const segments = this.breadcrumbsService.generateLink(this.breadcrumbs, index);\r\n\r\n if (segments.length > 1) {\r\n return [...segments];\r\n }\r\n\r\n return ['/'];\r\n }\r\n\r\n public expandBreadcrumbs(event: Event) {\r\n event.preventDefault();\r\n this.shortVersion = false;\r\n this.cdr.detectChanges();\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n {{breadcrumb.attributes.title}}\r\n {{breadcrumb.attributes.title}}\r\n \r\n \r\n {{breadcrumb.attributes.title}}\r\n \r\n \r\n \r\n \r\n \r\n {{breadcrumbs[0].attributes.title}}\r\n {{breadcrumbs[0].attributes.title}}\r\n \r\n \r\n {{'...'}}\r\n \r\n {{breadcrumbs[breadcrumbs.length - 1].attributes.title}}\r\n \r\n \r\n\r\n\r\n 0\">\r\n \r\n \r\n \r\n \r\n {{customBreadcrumb.title}}\r\n \r\n \r\n {{customBreadcrumb.title}}\r\n \r\n \r\n \r\n \r\n \r\n\r\n","import {Component, Input, OnInit} from '@angular/core';\r\n\r\n@Component({\r\n selector: 'app-container',\r\n templateUrl: './container.component.html',\r\n styles: []\r\n})\r\nexport class ContainerComponent implements OnInit {\r\n\r\n @Input() public top: number = 30;\r\n @Input() public bottom: number = 30;\r\n @Input() public left: number = 0;\r\n @Input() public right: number = 0;\r\n\r\n constructor() { }\r\n\r\n ngOnInit() {\r\n }\r\n\r\n}\r\n","\r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport {ContainerComponent} from '@app/template/layout/modules/container/components/container/container.component';\r\n\r\n@NgModule({\r\n declarations: [\r\n ContainerComponent\r\n ],\r\n imports: [\r\n CommonModule\r\n ],\r\n exports: [\r\n ContainerComponent\r\n ]\r\n})\r\nexport class ContainerModule { }\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\n\r\n@Component({\r\n selector: 'app-fatal-error',\r\n templateUrl: './fatal-error.component.html',\r\n styleUrls: ['./fatal-error.component.scss']\r\n})\r\nexport class FatalErrorComponent extends ComponentHelper implements OnInit {\r\n\r\n constructor() {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n }\r\n\r\n goToHome(): void {\r\n window.location.href = '/';\r\n }\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n {{ '500' }}\r\n {{ 'Błąd serwera' }}\r\n \r\n \r\n \r\n \r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\n\r\n@Component({\r\n selector: 'app-maintenance',\r\n templateUrl: './maintenance.component.html',\r\n styleUrls: ['./maintenance.component.scss']\r\n})\r\nexport class MaintenanceComponent extends ComponentHelper implements OnInit {\r\n\r\n constructor() {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n }\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n {{'global.maintenance' | trans}}\r\n {{'global.maintenanceText' | trans}}.\r\n \r\n \r\n\r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\n\r\n@Component({\r\n selector: 'app-not-found',\r\n templateUrl: './not-found.component.html',\r\n styleUrls: ['./not-found.component.scss']\r\n})\r\nexport class NotFoundComponent extends ComponentHelper implements OnInit {\r\n\r\n constructor() {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n }\r\n\r\n goToHome(): void {\r\n this.service.router.navigate(['']);\r\n }\r\n\r\n}\r\n","\r\n \r\n \r\n {{ '404' }}\r\n {{ 'Nie znaleziono strony' }}\r\n \r\n \r\n \r\n\r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { NotFoundComponent } from './components/not-found/not-found.component';\r\nimport { RouterModule } from '@angular/router';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { MaintenanceComponent } from './components/maintenance/maintenance.component';\r\nimport { FatalErrorComponent } from './components/fatal-error/fatal-error.component';\r\n\r\n@NgModule({\r\n declarations: [NotFoundComponent, MaintenanceComponent, FatalErrorComponent],\r\n imports: [\r\n CommonModule,\r\n RouterModule,\r\n ElementsModule,\r\n TranslatorModule\r\n ],\r\n exports: [\r\n NotFoundComponent,\r\n MaintenanceComponent\r\n ]\r\n})\r\nexport class ErrorPagesModule {\r\n}\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { VersionService } from '@share/common/services/version.service';\r\n\r\n@Component({\r\n selector: 'app-footer',\r\n templateUrl: './footer.component.html',\r\n styleUrls: ['./footer.component.scss']\r\n})\r\nexport class FooterComponent extends ComponentHelper implements OnInit {\r\n public footer: string;\r\n public version: string;\r\n\r\n constructor(private settingsService: SettingsService, private versionService: VersionService) {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n this.footer = this.settingsService.variables.footer.footer;\r\n }\r\n}\r\n","\r\n","import {NgModule} from '@angular/core';\r\nimport {CommonModule} from '@angular/common';\r\nimport {FooterComponent} from './components/footer/footer.component';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\n\r\n@NgModule({\r\n declarations: [FooterComponent],\r\n imports: [\r\n CommonModule,\r\n TranslatorModule,\r\n ElementsModule\r\n ],\r\n exports: [\r\n FooterComponent\r\n ]\r\n})\r\nexport class FooterModule {\r\n}\r\n","import { ChangeDetectionStrategy, Component } from '@angular/core';\r\n\r\ndeclare let $: any;\r\n\r\n@Component({\r\n selector: 'app-a11y-font-size',\r\n styleUrls: ['a11y-font-size.component.scss'],\r\n templateUrl: 'a11y-font-size.component.html',\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class A11yFontSizeComponent {\r\n constructor() {}\r\n\r\n setDefaultFontSize() {\r\n this.changeFontSize('10px');\r\n }\r\n setBiggerFontSize() {\r\n this.changeFontSize('11px');\r\n }\r\n setBigFontSize() {\r\n this.changeFontSize('12px');\r\n }\r\n\r\n private changeFontSize(size: string) {\r\n $('html').css({\r\n 'font-size': size\r\n });\r\n }\r\n}\r\n","\r\n \r\n \r\n domyślna czcionka\r\n A\r\n \r\n \r\n \r\n \r\n większa czcionka\r\n A\r\n \r\n \r\n \r\n \r\n największa czcionka\r\n A\r\n \r\n \r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { GoogleTranslateService } from '@app/common/services/google-translate.service';\r\n\r\n@Component({\r\n selector: 'app-google-translator',\r\n templateUrl: './google-translator.component.html',\r\n styleUrls: [\r\n './google-translator.component.scss'\r\n ]\r\n})\r\nexport class GoogleTranslatorComponent implements OnInit {\r\n\r\n constructor(private googleTranslateService: GoogleTranslateService) {}\r\n\r\n public ngOnInit() {\r\n this.googleTranslateService.init();\r\n }\r\n\r\n}\r\n","\r\n","import { AfterViewInit, Component, ElementRef, Inject, OnInit, ViewChild, ViewContainerRef } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { DOCUMENT } from '@angular/common';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { LazyLoaderService } from '@app/common/services/lazy-loader.service';\r\nimport { ThemesEnum } from '@app/common/models/themes.enum';\r\nimport { ResizeListener } from '@app/common/services/resize-listener.service';\r\nimport { SearchService } from '@app/client-core/search/services/search.service';\r\nimport { fromEvent, Observable } from 'rxjs';\r\nimport { MenuService } from '@app/client-core/menu/services/menu.service';\r\nimport { debounceTime, filter, finalize, first, takeUntil, tap } from 'rxjs/operators';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { MenuModel } from '@app/client-core/menu/models/menu.model';\r\n\r\ndeclare let $: Function;\r\n\r\n@Component({\r\n selector: 'app-header',\r\n templateUrl: './header-container.component.html',\r\n styleUrls: [\r\n './header-container.component.scss',\r\n './header-container-contrast.component.scss',\r\n ]\r\n})\r\nexport class HeaderContainerComponent extends ComponentHelper implements OnInit, AfterViewInit {\r\n isAuthenticated: boolean = false;\r\n search: string;\r\n\r\n @ViewChild('alertBtn', { read: ViewContainerRef }) alertBtn: ViewContainerRef;\r\n @ViewChild('menu', { read: ViewContainerRef }) menu: ViewContainerRef;\r\n\r\n private startDistance = 10;\r\n\r\n isMobileSearchActive$: Observable;\r\n isValidDefaultMenuWidth: boolean;\r\n isMobileMenuMode: boolean;\r\n isDefaultMenuWidthChecking: boolean;\r\n isFetchMenuLoading: boolean;\r\n menuData: AbstractData[];\r\n\r\n constructor(\r\n @Inject(DOCUMENT) private document: Document,\r\n private settings: SettingsService,\r\n private loader: LazyLoaderService,\r\n public resizeListener: ResizeListener,\r\n private searchService: SearchService,\r\n private menuService: MenuService,\r\n private _elementRef: ElementRef\r\n ) {\r\n super();\r\n }\r\n\r\n get isSubpage(): boolean {\r\n return !this.service.router.isActive('', true);\r\n }\r\n\r\n get isAlertModuleEnabled(): boolean {\r\n return this.settings.isModuleActive(ThemesEnum.ALERT);\r\n }\r\n\r\n get isMenuModuleEnabled(): boolean {\r\n return this.settings.isModuleActive(ThemesEnum.MENU);\r\n }\r\n\r\n /** Metoda sprawdzająca, czy zawartość menu dla desktop'ów nie wystaje poza szerokość okna/headera. */\r\n get isValidHeaderContentWidth(): boolean {\r\n const contentElementRef: HTMLElement = this.document.querySelector('#main-app-header .content') as HTMLElement;\r\n const contentElementChildren: HTMLElement[] = Array.from(contentElementRef.children) as HTMLElement[];\r\n const contentElementAvailableWidth: number = contentElementRef.offsetWidth\r\n - (parseInt(getComputedStyle(contentElementRef).paddingLeft))\r\n - (parseInt(getComputedStyle(contentElementRef).paddingRight))\r\n - 30 // ScrollBar with small offset.\r\n ;\r\n\r\n let contentChildrenWidth: number = 0;\r\n\r\n contentElementChildren.forEach(child => {\r\n contentChildrenWidth += child.offsetWidth;\r\n });\r\n\r\n return contentChildrenWidth <= contentElementAvailableWidth\r\n }\r\n\r\n ngOnInit() {\r\n this.fetchMenu();\r\n window.addEventListener('scroll', () => this.scroll(), true);\r\n this.scroll();\r\n this.isMobileSearchActive$ = this.searchService.isActive$;\r\n this.searchService.isActive$.pipe(takeUntil(this.destroyed$)).subscribe(isActive => {\r\n if (isActive) {\r\n this.menuService.isMobileMenuActive$.next(false);\r\n }\r\n });\r\n this.handleOutsideClick();\r\n }\r\n\r\n ngAfterViewInit() {\r\n this.generateAlertButton();\r\n this.generateMenu();\r\n }\r\n\r\n private setMenuModeChangeListener() {\r\n this.resizeListener.isMobile$.pipe(\r\n takeUntil(this.destroyed$),\r\n tap((value) => this.isMobileMenuMode = value),\r\n filter((value) => !value),\r\n tap(() => {\r\n this.isDefaultMenuWidthChecking = true;\r\n this.isValidDefaultMenuWidth = true; // Pokazanie menu, aby JS mógł obliczyć szerokość wewnątrz komponentu.\r\n }),\r\n debounceTime(500),\r\n ).subscribe((value) => {\r\n this.setIsMobileMenuMode();\r\n });\r\n }\r\n\r\n private fetchMenu() {\r\n this.isFetchMenuLoading = true;\r\n\r\n this.menuService\r\n .getList()\r\n .pipe(\r\n first(),\r\n finalize(() => this.isFetchMenuLoading = false)\r\n )\r\n .subscribe(\r\n response => {\r\n this.menuData = response.data;\r\n this.setMenuModeChangeListener();\r\n }\r\n );\r\n }\r\n\r\n private setIsMobileMenuMode(): void {\r\n // setTimeout z racji wymaganego opóźnienia przy obliczaniu dostępnej szerokosci.\r\n setTimeout(() => {\r\n this.isValidDefaultMenuWidth = this.isValidHeaderContentWidth;\r\n });\r\n\r\n this.isDefaultMenuWidthChecking = false;\r\n }\r\n\r\n generateAlertButton() {\r\n if (this.alertBtn && this.isAlertModuleEnabled) {\r\n this.loader.load(ThemesEnum.ALERT, this.alertBtn);\r\n }\r\n }\r\n\r\n generateMenu() {\r\n if (this.menu) {\r\n this.menu?.clear();\r\n if (this.isMenuModuleEnabled || this.isAuthenticated) {\r\n this.loader.load(ThemesEnum.MENU, this.menu);\r\n }\r\n }\r\n }\r\n\r\n handleOutsideClick() {\r\n const clickEvent$ = fromEvent(document, 'click');\r\n clickEvent$\r\n .pipe(\r\n takeUntil(this.destroyed$),\r\n filter(e => !this._elementRef.nativeElement.contains(e.target)),\r\n tap(e => {\r\n this.searchService.isActive$.next(false);\r\n })\r\n )\r\n .subscribe();\r\n }\r\n\r\n\r\n private scroll() {\r\n const scrollTop = $(this.document).scrollTop(),\r\n header = $('header');\r\n if (scrollTop >= this.startDistance) {\r\n header.addClass('sticked');\r\n } else {\r\n header.removeClass('sticked');\r\n }\r\n }\r\n\r\n onComponentRefresh() {\r\n this.fetchMenu();\r\n }\r\n}\r\n","\r\n Dolina baryczy\r\n \r\n \r\n \r\n {{ 'global.search' | trans }}\r\n \r\n \r\n \r\n {{ 'global.settings' | trans }}\r\n \r\n \r\n \r\n {{'global.contrast' | trans}}\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { AfterViewInit, Component, OnInit, Renderer2 } from '@angular/core';\r\n\r\ndeclare let $: Function;\r\n\r\n@Component({\r\n selector: 'app-high-contrast',\r\n templateUrl: './high-contrast.component.html',\r\n styleUrls: ['./high-contrast.component.scss']\r\n})\r\nexport class HighContrastComponent implements OnInit, AfterViewInit {\r\n constructor(private renderer: Renderer2) {}\r\n\r\n ngOnInit(): void {}\r\n\r\n ngAfterViewInit(): void {\r\n const contrast: string = localStorage.getItem('contrast') as string;\r\n if (contrast) {\r\n switch (contrast) {\r\n case 'blackwhite':\r\n this.addBlackWhite();\r\n break;\r\n case 'yellowblack':\r\n this.addYellowBlack();\r\n break;\r\n }\r\n }\r\n }\r\n\r\n removeContrast() {\r\n this.renderer.removeClass(document.body, localStorage.getItem('contrast') as string);\r\n this.renderer.setStyle(document.body, 'color', '');\r\n this.renderer.setStyle(document.body, 'background-color', '');\r\n\r\n localStorage.setItem('contrast', 'normal');\r\n }\r\n\r\n addYellowBlack() {\r\n this.removeContrast();\r\n this.renderer.addClass(document.body, 'yellowblack');\r\n\r\n this.renderer.setStyle(document.body, 'background-color', 'black');\r\n this.renderer.setStyle(document.body, 'color', 'yellow');\r\n\r\n localStorage.setItem('contrast', 'yellowblack');\r\n }\r\n\r\n addBlackWhite() {\r\n this.removeContrast();\r\n this.renderer.addClass(document.body, 'blackwhite');\r\n\r\n this.renderer.setStyle(document.body, 'background-color', 'white');\r\n this.renderer.setStyle(document.body, 'color', 'black');\r\n\r\n localStorage.setItem('contrast', 'blackwhite');\r\n }\r\n}\r\n","\r\n \r\n \r\n brak wysokiego kontrastu\r\n A\r\n \r\n \r\n \r\n \r\n czarno-biały\r\n A\r\n \r\n \r\n \r\n \r\n żółto-czarny\r\n A\r\n \r\n \r\n\r\n","export { SubheaderDescriptionComponent } from './subheader/subheader-description/subheader-description.component';\r\nexport { SubheaderTitleComponent } from './subheader/subheader-title/subheader-title.component';\r\nexport { SubheaderComponent } from './subheader/subheader.component';\r\nexport { GoogleTranslatorComponent } from './google-translator/google-translator.component';\r\nexport { HeaderContainerComponent } from './header-container/header-container.component';\r\nexport { LanguageComponent } from './language/language.component';\r\nexport { A11yFontSizeComponent } from './a11y-font-size/a11y-font-size.component';\r\n","import {ComponentHelper} from '@app/common/helpers/component.helper';\r\nimport {Component, ViewEncapsulation} from '@angular/core';\r\n\r\n@Component({\r\n selector: 'app-language',\r\n templateUrl: './language.component.html',\r\n styleUrls: ['./language.component.scss'],\r\n})\r\nexport class LanguageComponent extends ComponentHelper {\r\n\r\n public language: string = 'pl';\r\n\r\n constructor() {\r\n super();\r\n }\r\n\r\n changeLanguage(): void {\r\n alert('TODO');\r\n }\r\n}\r\n","\r\n","import { Component, Input } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'cms-subheader-description',\r\n templateUrl: 'subheader-description.component.html',\r\n styleUrls: ['subheader-description.component.scss']\r\n})\r\nexport class SubheaderDescriptionComponent {\r\n @Input() text: string;\r\n @Input() isMobile: boolean;\r\n}\r\n","{{text}}\r\n","import { Component, ElementRef, EventEmitter, Input, Output, ViewChild } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'cms-subheader-title',\r\n templateUrl: 'subheader-title.component.html',\r\n styleUrls: ['subheader-title.component.scss']\r\n})\r\nexport class SubheaderTitleComponent {\r\n\r\n isEditable: boolean = false;\r\n\r\n @Input() title: string;\r\n @Input() isMobile: boolean;\r\n @Input() set editable(editable: boolean) {\r\n this.isEditable = editable;\r\n setTimeout(() => this.text.nativeElement.focus());\r\n };\r\n\r\n @ViewChild('text') text: ElementRef;\r\n\r\n @Output() onSubmitEditable: EventEmitter = new EventEmitter();\r\n\r\n onSubmit() {\r\n this.isEditable = false;\r\n this.onSubmitEditable.emit(this.text.nativeElement.innerText);\r\n }\r\n\r\n}\r\n","{{ title }}\r\n","import { AfterViewInit, Component, Injector } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { SubheaderConfig } from '@app/template/layout/modules/header/interfaces/subheader-config.interface';\r\nimport { BreadcrumbsService } from '@app/template/layout/modules/header/services/breadcrumbs.service';\r\nimport { NavigationEnd } from '@angular/router';\r\nimport { filter, takeUntil } from 'rxjs/operators';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { DynamicContentService } from '@app/client-core/dynamic-content/service/dynamic-content.service';\r\nimport { Observable } from 'rxjs';\r\nimport { HomeService } from '@app/template/home/services/home.service';\r\n\r\n@Component({\r\n selector: 'app-subheader',\r\n templateUrl: './subheader.component.html',\r\n styleUrls: ['./subheader.component.scss']\r\n})\r\nexport class SubheaderComponent extends ComponentHelper implements AfterViewInit {\r\n active: boolean = false;\r\n isHome: boolean = false;\r\n\r\n constructor(\r\n private breadcrumbsService: BreadcrumbsService,\r\n private settings: SettingsService,\r\n private dynamicContentService: DynamicContentService,\r\n private homeService: HomeService\r\n ) {\r\n super();\r\n this.setHome();\r\n }\r\n\r\n get contentLoaded(): Observable {\r\n return this.dynamicContentService.loaded$;\r\n }\r\n\r\n get isHomePreview(): Observable {\r\n return this.homeService.isHomePreview$;\r\n }\r\n\r\n private setHome() {\r\n this.service.router.events\r\n .pipe(\r\n filter((e): e is NavigationEnd => e instanceof NavigationEnd),\r\n takeUntil(this.destroyed$)\r\n )\r\n .subscribe(event => {\r\n this.isHome = event.url === '/';\r\n });\r\n }\r\n\r\n get component() {\r\n return this.service.subheader.config.component;\r\n }\r\n\r\n get config(): SubheaderConfig {\r\n return this.service.subheader.config;\r\n }\r\n\r\n get myInjector(): Injector | null | undefined {\r\n return this.service.subheader.config.injector;\r\n }\r\n\r\n get displayBreadcrumbs() {\r\n return this.service.subheader.config.displayBreadcrumbs;\r\n }\r\n\r\n get forceShow() {\r\n return this.service.subheader.config.forceShow;\r\n }\r\n\r\n get categories(): { title: string; slug: string }[] | undefined {\r\n return this.service.subheader.config.categories;\r\n }\r\n\r\n get publishedDate(): string | undefined {\r\n return this.service.subheader.config.publishedDate;\r\n }\r\n\r\n get image(): string | undefined {\r\n return this.service.subheader.config.image;\r\n }\r\n\r\n get hideDots(): boolean {\r\n return this.service.subheader.config.hideDots || false;\r\n }\r\n\r\n ngAfterViewInit(): void {\r\n this.breadcrumbsService.reload.next(true);\r\n }\r\n\r\n isArray(categories: { title: string; slug: string }[] | string | undefined): boolean {\r\n return Array.isArray(categories);\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n {{ category.attributes.title }}\r\n \r\n \r\n {{ publishedDate | date: 'shortDate':'':'pl' }}\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","export enum BreadcrumbsLoaders {\r\n Get = 'Get'\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { WcagModule } from '@share/modules/wcag/wcag.module';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { LogoModule } from '@app/template/layout/modules/logo/logo.module';\r\nimport { SearchModule } from '@app/client-core/search/search.module';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { RouterModule } from '@angular/router';\r\nimport {\r\n A11yFontSizeComponent,\r\n GoogleTranslatorComponent,\r\n HeaderContainerComponent,\r\n LanguageComponent,\r\n SubheaderComponent,\r\n SubheaderDescriptionComponent,\r\n SubheaderTitleComponent\r\n} from './components';\r\nimport { BreadcrumbsModule } from '@app/template/layout/modules/breadcrumbs/breadcrumbs.module';\r\nimport { HttpClientModule } from '@angular/common/http';\r\nimport { MenuModule } from '@app/client-core/menu/menu.module';\r\nimport { InputModule } from '@share/modules/html/input/input.module';\r\nimport { FormsModule } from '@angular/forms';\r\nimport { HighContrastComponent } from './components/high-contrast/high-contrast.component';\r\n\r\n@NgModule({\r\n declarations: [\r\n LanguageComponent,\r\n SubheaderTitleComponent,\r\n SubheaderDescriptionComponent,\r\n GoogleTranslatorComponent,\r\n HeaderContainerComponent,\r\n SubheaderComponent,\r\n A11yFontSizeComponent,\r\n HighContrastComponent\r\n ],\r\n imports: [\r\n CommonModule,\r\n WcagModule,\r\n LogoModule,\r\n ElementsModule,\r\n HttpClientModule,\r\n SearchModule,\r\n ElementsModule,\r\n TranslatorModule,\r\n RouterModule,\r\n BreadcrumbsModule,\r\n MenuModule,\r\n InputModule,\r\n FormsModule\r\n ],\r\n exports: [HeaderContainerComponent, SubheaderComponent, SubheaderTitleComponent, SubheaderDescriptionComponent]\r\n})\r\nexport class HeaderModule {}\r\n","import { ReplaySubject } from 'rxjs';\r\nimport { Injector } from '@angular/core';\r\n\r\nexport interface SubheaderConfig {\r\n title: string;\r\n description: string;\r\n displayHeader: boolean;\r\n displayBreadcrumbs: ReplaySubject;\r\n searchOpen: boolean;\r\n searchType: SearchType;\r\n component: any;\r\n categories?: { slug: string; title: string }[];\r\n hideSearch: boolean;\r\n injector?: Injector | null;\r\n forceShow: boolean;\r\n publishedDate?: string;\r\n image?: string;\r\n hideDots?: boolean\r\n}\r\n\r\nexport enum SearchType {\r\n Default = '',\r\n EServices = 'eservice',\r\n None = ''\r\n}\r\n\r\nexport enum SearchTypeNames {\r\n Default = 'Wszędzie',\r\n EServices = 'Katalog e-usług'\r\n}\r\n","import { ServiceHelper } from '@share/common/helpers/service.helper';\r\nimport { Bundle } from '@app/common/enums/server-bundles.enum';\r\nimport { Injectable } from '@angular/core';\r\nimport { BehaviorSubject, Observable } from 'rxjs';\r\nimport { AbstractData, ResponseArray } from '@share/common/models/http';\r\nimport { Breadcrumbs } from '@app/template/layout/modules/header/models/breadcrumbs.model';\r\nimport { API } from '@app/common/constants/api.directories';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class BreadcrumbsService extends ServiceHelper {\r\n reload: BehaviorSubject = new BehaviorSubject(false);\r\n clear: BehaviorSubject = new BehaviorSubject(false);\r\n customBreadcrumbs: Array<{ title: string; url?: string }> = [];\r\n forceActive = false;\r\n\r\n constructor() {\r\n super(Bundle.Breadcrumbs);\r\n }\r\n\r\n public getList(url: string): Observable> {\r\n return this.getAll(`${API.COMMON.BREADCRUMBS}/,${url}`);\r\n }\r\n\r\n public getParsedUrl(url: string): string {\r\n return url.substr(1, url.length).split('/').join(',');\r\n }\r\n\r\n public generateLink(breadcrumbs: Array>, index: number): Array {\r\n let path: Array = [];\r\n try {\r\n for (let i = 0; i < (index + 1); i++) {\r\n path.push(breadcrumbs[i].attributes.url);\r\n }\r\n } catch (_ignore) {\r\n path = [];\r\n }\r\n return path;\r\n }\r\n\r\n public reset() {\r\n this.reload.next(true);\r\n }\r\n}\r\n","import { Injectable, Injector } from '@angular/core';\r\nimport { BehaviorSubject, Observable, ReplaySubject } from 'rxjs';\r\nimport { SearchType, SubheaderConfig } from '@app/template/layout/modules/header/interfaces/subheader-config.interface';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class SubheaderService {\r\n private _config: BehaviorSubject;\r\n\r\n constructor() {\r\n this._config = new BehaviorSubject(this.default);\r\n }\r\n\r\n private get default(): SubheaderConfig {\r\n return {\r\n title: '',\r\n description: '',\r\n searchType: SearchType.None,\r\n component: null,\r\n displayHeader: true,\r\n displayBreadcrumbs: new ReplaySubject(1),\r\n searchOpen: false,\r\n hideSearch: false,\r\n injector: null,\r\n forceShow: false,\r\n categories: [],\r\n hideDots: false\r\n };\r\n }\r\n\r\n public get config(): SubheaderConfig {\r\n return this._config.getValue();\r\n }\r\n\r\n public getConfig(): Observable> {\r\n return this._config.asObservable();\r\n }\r\n\r\n public setConfig(value: Partial) {\r\n this._config.next({ ...this.default, ...value });\r\n }\r\n\r\n public set title(title: string) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n title\r\n });\r\n }\r\n\r\n public set description(description: string) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n description\r\n });\r\n }\r\n\r\n public set searchType(searchType: SearchType) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n searchType\r\n });\r\n }\r\n\r\n public set searchOpen(searchOpen: boolean) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n searchOpen\r\n });\r\n }\r\n\r\n public set injector(injector: Injector) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n injector\r\n });\r\n }\r\n\r\n public set forceShow(forceShow: boolean) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n forceShow\r\n });\r\n }\r\n\r\n public set displayBreadcrumbs(show: boolean) {\r\n this.config.displayBreadcrumbs.next(show);\r\n }\r\n\r\n set categories(categories: { slug: string; title: string }[]) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n categories\r\n });\r\n }\r\n\r\n set publishedDate(publishedDate: string) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n publishedDate\r\n });\r\n }\r\n\r\n set image(image: string) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n image\r\n });\r\n }\r\n\r\n set hideDots(hideDots: boolean) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n hideDots\r\n });\r\n }\r\n\r\n public reset() {\r\n this.setConfig(this.default);\r\n }\r\n}\r\n","import { Component, Input, OnDestroy, OnInit } from '@angular/core';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { Subject } from 'rxjs';\r\n\r\n@Component({\r\n selector: 'app-logo',\r\n templateUrl: './logo.component.html',\r\n styleUrls: ['./logo.component.scss']\r\n})\r\nexport class LogoComponent implements OnInit, OnDestroy {\r\n private destroy$: Subject = new Subject();\r\n url: string;\r\n\r\n @Input() id: string = 'logo';\r\n @Input() isAlt: boolean;\r\n @Input() preventChange: boolean;\r\n\r\n constructor(private layoutService: SettingsService) {}\r\n\r\n ngOnInit() {\r\n if (this.isAlt) {\r\n this.url = this.layoutService.variables.site.altLogo;\r\n } else {\r\n this.url = this.layoutService.variables.site.logo;\r\n }\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.destroy$.next(true);\r\n this.destroy$.complete();\r\n }\r\n}\r\n","\r\n Strona główna\r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { LogoComponent } from '@app/template/layout/modules/logo/components/logo/logo.component';\r\nimport { RouterModule } from '@angular/router';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n RouterModule,\r\n TranslatorModule\r\n ],\r\n declarations: [\r\n LogoComponent\r\n ],\r\n exports: [\r\n LogoComponent\r\n ]\r\n})\r\nexport class LogoModule {}\r\n","import { Component, ElementRef, Input, OnDestroy, OnInit, Renderer2 } from '@angular/core';\r\nimport { AbstractData } from '@share/common/models/http.model';\r\nimport { MenuModel } from '@app/client-core/menu/models/menu.model';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\n\r\n@Component({\r\n selector: 'app-sitemap-item',\r\n templateUrl: './sitemap-item.component.html',\r\n styleUrls: [\r\n './sitemap-item.component.scss'\r\n ]\r\n})\r\nexport class SitemapItemComponent extends ComponentHelper implements OnInit, OnDestroy {\r\n @Input() item: AbstractData;\r\n public listenClickFunc: Function;\r\n\r\n constructor(private renderer: Renderer2,\r\n private _elementRef: ElementRef) {\r\n super();\r\n }\r\n\r\n public ngOnInit() {\r\n this.onClickListener();\r\n }\r\n\r\n public openInNewTab(event: Event, url: string) {\r\n event.preventDefault();\r\n event.stopPropagation();\r\n window.open(url);\r\n }\r\n\r\n private onClickListener() {\r\n this.listenClickFunc = this.renderer.listen(\r\n this._elementRef.nativeElement, 'click', (event) => this.service.utils.navigateTo(event)\r\n );\r\n }\r\n\r\n public ngOnDestroy() {\r\n this.listenClickFunc();\r\n }\r\n}\r\n","{{item.attributes.title}}\r\n\r\n \r\n {{subitem.attributes.title}}\r\n \r\n {{subitem.attributes.title}}\r\n \r\n \r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { SitemapService } from '@app/template/home/services/sitemap.service';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { MenuModel } from '@app/client-core/menu/models/menu.model';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { SitemapLoaders } from '@app/template/home/enums/sitemap-loaders.enum';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { finalize, first } from 'rxjs/operators';\r\nimport { InstitutionModel } from '@app/template/layout/modules/sitemap/models/institution.model';\r\n\r\n@Component({\r\n selector: 'app-sitemap',\r\n templateUrl: './sitemap.component.html',\r\n styleUrls: ['./sitemap.component.scss']\r\n})\r\nexport class SitemapComponent extends ComponentHelper implements OnInit {\r\n sitemap: Array> = [];\r\n SitemapLoaders = SitemapLoaders;\r\n description: string;\r\n institution: AbstractData;\r\n constructor(private sitemapService: SitemapService, private settingService: SettingsService) {\r\n super();\r\n }\r\n\r\n public ngOnInit() {\r\n this.loadSitemap();\r\n this.getInstitutionData();\r\n }\r\n\r\n getInstitutionData() {\r\n this.sitemapService\r\n .getInstitutionData()\r\n .pipe(first())\r\n .subscribe(response => (this.institution = response.data));\r\n }\r\n\r\n public loadSitemap() {\r\n this.setLoader(SitemapLoaders.GetAll, true);\r\n this.sitemapService\r\n .getList()\r\n .pipe(\r\n first(),\r\n finalize(() => this.setLoader(SitemapLoaders.GetAll, false))\r\n )\r\n .subscribe(\r\n response => (this.sitemap = this.getResponseData(response)),\r\n () => this.setComponentError()\r\n );\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n {{institution?.attributes?.name}}\r\n \r\n \r\n \r\n {{ institution?.attributes?.address?.zipCode }} {{ institution?.attributes?.address?.city }}\r\n ul. {{ institution?.attributes?.address?.street }} {{ institution?.attributes?.address?.houseNumber }}\r\n {{\r\n institution?.attributes?.address?.apartmentNumber\r\n ? '/' + institution?.attributes?.address?.apartmentNumber\r\n : ''\r\n }}\r\n \r\n \r\n \r\n \r\n \r\n {{ institution?.attributes?.contact?.phoneNumber }}\r\n \r\n \r\n \r\n {{ institution?.attributes?.contact?.phoneNumberSecondary }}\r\n \r\n \r\n \r\n {{ institution?.attributes?.contact?.fax }}\r\n \r\n \r\n \r\n {{ institution?.attributes?.contact?.email }}\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n 0\">\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { LogoModule } from '@app/template/layout/modules/logo/logo.module';\r\nimport { RouterModule } from '@angular/router';\r\nimport { SitemapComponent } from '@app/template/layout/modules/sitemap/components/sitemap/sitemap.component';\r\nimport { SitemapItemComponent } from '@app/template/layout/modules/sitemap/components/sitemap/sitemap-item/sitemap-item.component';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\n\r\n@NgModule({\r\n declarations: [\r\n SitemapComponent,\r\n SitemapItemComponent,\r\n ],\r\n imports: [\r\n CommonModule,\r\n ElementsModule,\r\n LogoModule,\r\n RouterModule,\r\n TranslatorModule,\r\n ],\r\n exports: [\r\n SitemapComponent\r\n ]\r\n})\r\nexport class SiteMapModule {\r\n}\r\n\r\n","// This file can be replaced during build by using the `fileReplacements` array.\r\n// `ng build --prod` replaces `environment.ts` with `environment.prod.ts`.\r\n// The list of file replacements can be found in `angular.json`.\r\n\r\nexport const environment = {\r\n production: false\r\n};\r\n\r\n/*\r\n * For easier debugging in development mode, you can import the following file\r\n * to ignore zone related error stack frames such as `zone.run`, `zoneDelegate.invokeTask`.\r\n *\r\n * This import should be commented out in production mode because it will have a negative impact\r\n * on performance if an error is thrown.\r\n */\r\n// import 'zone.js/dist/zone-error'; // Included with Angular CLI.\r\n","import {enableProdMode} from '@angular/core';\r\nimport {platformBrowserDynamic} from '@angular/platform-browser-dynamic';\r\n\r\nimport {AppModule} from './app/app.module';\r\nimport {environment} from './environments/environment';\r\nimport 'hammerjs';\r\n\r\nif (environment.production) {\r\n enableProdMode();\r\n}\r\n\r\nplatformBrowserDynamic().bootstrapModule(AppModule)\r\n .catch(err => console.error(err));\r\n"]}
(`${API.ARTICLES.RANDOM}`, params);\r\n }\r\n\r\n getOne(slug: string): Observable> {\r\n return this.apiService.get(`${API.ARTICLES.ROOT}/${slug}`).pipe(first());\r\n }\r\n}\r\n","import { ChangeDetectionStrategy, Component, OnInit } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { CookieService } from '@app/client-core/cookies/service/cookie.service';\r\n\r\n@Component({\r\n selector: 'app-cookie-information-bar',\r\n templateUrl: './cookie-information-bar.component.html',\r\n styleUrls: ['./cookie-information-bar.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class CookieInformationBarComponent extends ComponentHelper implements OnInit {\r\n\r\n public cookieText: string = '';\r\n\r\n constructor(private settings: SettingsService, private cookieService: CookieService) {\r\n super();\r\n }\r\n\r\n get isCookieAccepted(): string {\r\n return this.cookieService.getCookie('cookiesAccepted');\r\n }\r\n\r\n ngOnInit() {\r\n try {\r\n this.cookieText = this.settings.variables.footer.cookieWarningContent;\r\n } catch (ignore) {\r\n throw new Error('Cannot get cookieWarningContent of undefined');\r\n }\r\n }\r\n\r\n accept(): void {\r\n this.cookieService.setCookie('cookiesAccepted', 'true', 365);\r\n }\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { CookieInformationBarComponent } from './components/cookie-information-bar/cookie-information-bar.component';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\n\r\n@NgModule({\r\n declarations: [CookieInformationBarComponent],\r\n imports: [\r\n CommonModule,\r\n ElementsModule,\r\n TranslatorModule\r\n ],\r\n exports: [\r\n CookieInformationBarComponent\r\n ]\r\n\r\n})\r\nexport class CookiesModule {\r\n}\r\n","import { Injectable } from '@angular/core';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class CookieService {\r\n\r\n constructor() {\r\n }\r\n\r\n public getCookie(name: string) {\r\n const ca: Array = document.cookie.split(';');\r\n const caLen: number = ca.length;\r\n const cookieName = `${name}=`;\r\n let c: string;\r\n\r\n for (let i = 0; i < caLen; i += 1) {\r\n c = ca[i].replace(/^\\s+/g, '');\r\n if (c.indexOf(cookieName) === 0) {\r\n return c.substring(cookieName.length, c.length);\r\n }\r\n }\r\n return '';\r\n }\r\n\r\n public setCookie(name: string, value: string, expireDays: number = 0): void {\r\n let cookie = '';\r\n cookie += `${name}=${value};`;\r\n const d: Date = new Date();\r\n if (expireDays !== 0) {\r\n d.setTime(d.getTime() + expireDays * 24 * 60 * 60 * 1000);\r\n\r\n cookie += `expires=${d.toString()}`;\r\n }\r\n document.cookie = cookie;\r\n\r\n }\r\n\r\n}\r\n","import { AfterViewInit, Component, OnDestroy, ViewChild, ViewContainerRef } from '@angular/core';\r\nimport { ActivatedRoute, Router } from '@angular/router';\r\nimport { DynamicContentService } from '@app/client-core/dynamic-content/service/dynamic-content.service';\r\nimport { LazyLoaderService } from '@app/common/services/lazy-loader.service';\r\nimport { switchMap, takeUntil, tap } from 'rxjs/operators';\r\nimport { of, Subject } from 'rxjs';\r\nimport { ROUTES_PATHS } from '@app/common/constants/routes-paths';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { ComponentInterface } from '@app/client-core/dynamic-content/interfaces/components.interface';\r\nimport { Nullable } from '@share/common/types/utilities.types';\r\nimport { BreadcrumbsService } from '@app/template/layout/modules/header/services/breadcrumbs.service';\r\nimport { ElementService } from '@app/client-core/dynamic-content/service/element.service';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { HOME_COMPONENTS } from '@app/client-core/dynamic-content/constants/component-list';\r\n\r\n@Component({\r\n selector: 'app-dynamic-content',\r\n templateUrl: './dynamic-content.component.html',\r\n styleUrls: ['./dynamic-content.component.scss']\r\n})\r\nexport class DynamicContentComponent implements AfterViewInit, OnDestroy {\r\n @ViewChild('componentPlaceholder', { read: ViewContainerRef }) componentPlaceholder: ViewContainerRef;\r\n private currentView: string;\r\n private destroy$: Subject = new Subject();\r\n\r\n constructor(\r\n private dynamic: DynamicContentService,\r\n private router: Router,\r\n private lazyLoaderService: LazyLoaderService,\r\n private facadeService: FacadeService,\r\n private breadcrumbsService: BreadcrumbsService,\r\n private elementsService: ElementService,\r\n private settingsService: SettingsService,\r\n ) {}\r\n\r\n async ngAfterViewInit() {\r\n this.dynamic.runtimeUrlReader$\r\n .pipe(\r\n takeUntil(this.destroy$),\r\n switchMap((rawUrl: string) => {\r\n if (rawUrl.includes('#')) {\r\n return of(null);\r\n } else {\r\n if (rawUrl === '/') {\r\n return of(this.getHomeComponent()).pipe(\r\n tap((component: Nullable) => (this.dynamic.homeComponent = component))\r\n );\r\n }\r\n return this.dynamic.componentLoader(rawUrl);\r\n }\r\n })\r\n )\r\n .subscribe(\r\n (component: Nullable) => {\r\n this.loadView(component);\r\n },\r\n () => this.componentNotFoundNavigation()\r\n );\r\n }\r\n\r\n private getHomeComponent(): ComponentInterface {\r\n const { name } = this.settingsService.variables.theme;\r\n return { ...HOME_COMPONENTS[name], isHome: true };\r\n }\r\n\r\n private loadView(component: Nullable) {\r\n if (component && component.className !== this.currentView) {\r\n this.breadcrumbsService.reset();\r\n this.facadeService.subheader.reset();\r\n this.componentPlaceholder?.clear();\r\n this.lazyLoaderService.load(component.module, this.componentPlaceholder, component.name).then(() => {\r\n this.facadeService.scrollTo.resetScrollTop();\r\n this.dynamic.loaded = true;\r\n this.currentView = component?.className;\r\n });\r\n } else if (component) {\r\n this.navigateToHomeDefaultContext(component);\r\n this.breadcrumbsService.reset();\r\n this.dynamic.loaded = true;\r\n this.elementsService.loaded = true;\r\n }\r\n this.facadeService.scrollTo.resetScrollTop();\r\n }\r\n\r\n private navigateToHomeDefaultContext(component: null | ComponentInterface) {\r\n if (component?.defaultContext && component?.isHome) {\r\n this.router.navigate([component?.defaultContext]);\r\n }\r\n }\r\n\r\n private componentNotFoundNavigation() {\r\n this.router.navigate(['/', ROUTES_PATHS.notFoundPage.root]);\r\n }\r\n\r\n ngOnDestroy() {\r\n this.destroy$.next(true);\r\n this.destroy$.complete();\r\n }\r\n}\r\n","\r\n","import { StaticPageComponent } from '@app/client-core/static-pages/components/static-page/static-page.component';\r\nimport { ArticleListComponent } from '@app/client-core/article/components/article-list/article-list.component';\r\nimport { ThemesEnum } from '@app/common/models/themes.enum';\r\nimport { ComponentsInterface } from '@app/client-core/dynamic-content/interfaces/components.interface';\r\nimport { OverlayComponent } from '@app/template/home/components/overlay/overlay.component';\r\nimport { ArticleComponent } from '@app/client-core/article/components';\r\n\r\nexport const COMPONENTS: ComponentsInterface = {\r\n main: { name: OverlayComponent, module: ThemesEnum.CORE, className: 'OverlayComponent' },\r\n static: { name: StaticPageComponent, module: ThemesEnum.CORE, className: 'StaticPageComponent' },\r\n articlecategory: { name: ArticleListComponent, module: ThemesEnum.ARTICLE, className: 'ArticleListComponent' },\r\n article: { name: ArticleComponent, module: ThemesEnum.ARTICLE, className: 'ArticleComponent' }\r\n};\r\n\r\nexport enum ThemeName {\r\n Basic = 'podstawowy'\r\n}\r\n\r\nexport const HOME_COMPONENTS: ComponentsInterface = {\r\n [ThemeName.Basic]: { name: OverlayComponent, module: ThemesEnum.CORE, className: 'OverlayComponent' }\r\n};\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { DynamicContentComponent } from './component/dynamic-content/dynamic-content.component';\r\nimport { ProgressBarModule } from '@share/modules/progress-bar/progress-bar.module';\r\nimport { StaticPagesModule } from '@app/client-core/static-pages/static-pages.module';\r\nimport { ArticleModule } from '@app/client-core/article/article.module';\r\nimport { HomeModule } from '@app/template/home/home.module';\r\nimport { DynamicUtilsService } from '@app/client-core/dynamic-content/service/dynamic-utils.service';\r\n\r\n@NgModule({\r\n declarations: [DynamicContentComponent],\r\n imports: [\r\n CommonModule,\r\n ProgressBarModule,\r\n StaticPagesModule,\r\n ArticleModule,\r\n HomeModule\r\n ],\r\n providers: [DynamicUtilsService],\r\n exports: [\r\n DynamicContentComponent\r\n ]\r\n})\r\nexport class DynamicContentModule {\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { API } from '@app/common/constants/api.directories';\r\nimport { COMPONENTS } from '@app/client-core/dynamic-content/constants/component-list';\r\nimport { BehaviorSubject, Observable, of, throwError } from 'rxjs';\r\nimport { MetaResponse, ResponseDefault } from '@share/common/models/http.model';\r\nimport { Nullable } from '@share/common/types/utilities.types';\r\nimport { ComponentInterface } from '@app/client-core/dynamic-content/interfaces/components.interface';\r\nimport { distinctUntilChanged, filter, map, startWith, switchMap, tap } from 'rxjs/operators';\r\nimport { ApiService } from '@app/common/services/api.service';\r\nimport { NavigationEnd, Router } from '@angular/router';\r\nimport { DynamicUtilsService } from '@app/client-core/dynamic-content/service/dynamic-utils.service';\r\nimport { ElementService } from '@app/client-core/dynamic-content/service/element.service';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class DynamicContentService {\r\n private _loaded: BehaviorSubject = new BehaviorSubject(true);\r\n loaded$: Observable = this._loaded.asObservable().pipe(distinctUntilChanged());\r\n homeComponent: Nullable;\r\n\r\n constructor(\r\n private apiService: ApiService,\r\n private router: Router,\r\n private dynamicUtilsService: DynamicUtilsService,\r\n private elementService: ElementService\r\n ) {}\r\n\r\n set loaded(value: boolean) {\r\n this._loaded.next(value);\r\n }\r\n\r\n get runtimeUrlReader$(): Observable {\r\n return this.router.events.pipe(\r\n startWith(new NavigationEnd(0, this.router.url, this.router.url)),\r\n filter((e: any): e is NavigationEnd => e instanceof NavigationEnd),\r\n map((event: NavigationEnd) => event.url)\r\n );\r\n }\r\n\r\n componentLoader(rawUrl: string): Observable> {\r\n return of(rawUrl).pipe(\r\n map((rawUrl: string) => this.dynamicUtilsService.parseUrlToBeProcessable(rawUrl)),\r\n switchMap((url: string) => this.getPageMetadata(url)),\r\n tap(response => {\r\n if (response?.meta?.objectId) {\r\n this.elementService.objectId = response?.meta?.objectId\r\n }\r\n }),\r\n map((response: any) => response.meta),\r\n switchMap((metadata: MetaResponse) => this.getComponentByType(metadata?.type))\r\n );\r\n }\r\n\r\n private getComponentByType(type: string | undefined): Observable> {\r\n if (type) {\r\n const component: Nullable = this.getComponent(type);\r\n if (!component) {\r\n return throwError(`Not found component ${type}`);\r\n }\r\n return of(component);\r\n } else {\r\n return throwError(`Component's type is not provided: ${type}`);\r\n }\r\n }\r\n\r\n getPageMetadata(url: string): Observable {\r\n return this.apiService.get(`${API.DYNAMIC_CONTENT.ROOT}${url && url != ' ' ? '/' + url : ''}`);\r\n }\r\n\r\n private getComponent(module: string): Nullable {\r\n try {\r\n return COMPONENTS[module.toLowerCase()];\r\n } catch (e) {\r\n return null;\r\n }\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\n\r\n@Injectable()\r\nexport class DynamicUtilsService {\r\n parseUrlToBeProcessable(url: string): string {\r\n let parsed: string = url.split('/').join(',');\r\n return parsed === ',' ? '' : parsed;\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { BehaviorSubject, Observable } from 'rxjs';\r\nimport { Nullable } from '@share/common/types/utilities.types';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ElementService {\r\n private _objectId: BehaviorSubject> = new BehaviorSubject>(null);\r\n private _sameComponentNavigation: BehaviorSubject = new BehaviorSubject(false);\r\n\r\n public get getObjectId(): Observable> {\r\n return this._objectId.asObservable();\r\n }\r\n\r\n public get objectId(): Nullable {\r\n return this._objectId.getValue();\r\n }\r\n\r\n public set objectId(value: Nullable) {\r\n this._objectId.next(value);\r\n }\r\n\r\n public get sameComponentNavigation(): Observable {\r\n return this._sameComponentNavigation.asObservable();\r\n }\r\n\r\n public set loaded(value: boolean) {\r\n this._sameComponentNavigation.next(value);\r\n }\r\n\r\n}\r\n","import {\r\n ChangeDetectionStrategy,\r\n ChangeDetectorRef,\r\n Component,\r\n ElementRef,\r\n EventEmitter,\r\n Input,\r\n Output,\r\n Renderer2\r\n} from '@angular/core';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { MenuModel } from '@app/client-core/menu/models/menu.model';\r\nimport { MenuService } from '@app/client-core/menu/services/menu.service';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\n\r\n@Component({\r\n selector: 'app-default-menu',\r\n templateUrl: './default-menu.component.html',\r\n styleUrls: ['./default-menu.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class DefaultMenuComponent {\r\n @Input() menu: AbstractData[];\r\n @Input() isMenuWidthChecking: boolean;\r\n @Input() isLoading: boolean;\r\n\r\n @Output() refreshed: EventEmitter = new EventEmitter();\r\n\r\n getError: boolean;\r\n open: { [id: string]: boolean } = {};\r\n\r\n constructor(\r\n private menuService: MenuService,\r\n private facadeService: FacadeService,\r\n private renderer: Renderer2,\r\n private cdr: ChangeDetectorRef,\r\n private _elementRef: ElementRef\r\n ) {}\r\n\r\n onMouseOver(id: string) {\r\n this.open[id] = true;\r\n }\r\n\r\n hideSubmenu() {\r\n for(let key in this.open) {\r\n this.open[key] = false;\r\n }\r\n }\r\n\r\n onComponentRefresh() {\r\n this.refreshed.emit();\r\n }\r\n}\r\n","\r\n Menu główne\r\n \r\n \r\n \r\n \r\n 0\">\r\n \r\n {{ item.attributes.title }}\r\n \r\n\r\n 12 ? '60' : '30'\" [class.show]=\"open[item.id]\" [attr.aria-labelledby]=\"item.attributes.title\">\r\n \r\n \r\n \r\n \r\n {{ child.attributes.highlightedContent }}\r\n\r\n \r\n \r\n {{ child.attributes.title }}\r\n \r\n\r\n\r\n \r\n \r\n {{ child.attributes.title }}\r\n \r\n\r\n \r\n \r\n\r\n \r\n \r\n \r\n {{ child.attributes.title }}\r\n \r\n\r\n \r\n \r\n {{ child.attributes.title }}\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n {{ item.attributes.title }}\r\n \r\n\r\n \r\n {{ item.attributes.title }}\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import {\r\n AfterViewInit,\r\n ChangeDetectionStrategy,\r\n ChangeDetectorRef,\r\n Component,\r\n ElementRef,\r\n Input,\r\n OnDestroy,\r\n ViewChild\r\n} from '@angular/core';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { MenuModel } from '@app/client-core/menu/models/menu.model';\r\nimport { MenuService } from '@app/client-core/menu/services/menu.service';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { filter, takeUntil, tap } from 'rxjs/operators';\r\nimport { fromEvent, Subject } from 'rxjs';\r\n\r\ndeclare var $: any;\r\n\r\n@Component({\r\n selector: 'app-mobile-menu',\r\n templateUrl: 'mobile-menu.component.html',\r\n styleUrls: ['mobile-menu.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class MobileMenuComponent implements OnDestroy, AfterViewInit {\r\n private destroy$: Subject = new Subject();\r\n\r\n @Input() menu: AbstractData[];\r\n\r\n @ViewChild('sidebarMobile') sidebarMobile: ElementRef;\r\n\r\n getError: boolean;\r\n getLoading: boolean;\r\n open: boolean;\r\n shownComplete: boolean;\r\n\r\n constructor(private menuService: MenuService,\r\n private facadeService: FacadeService,\r\n private cdr: ChangeDetectorRef,\r\n private _elementRef: ElementRef) {}\r\n\r\n ngOnInit() {\r\n this.shownComplete = true;\r\n this.listenForServiceChange();\r\n this.handleOutsideClick();\r\n }\r\n\r\n ngOnDestroy() {\r\n this.destroy$.next(true);\r\n this.destroy$.complete();\r\n }\r\n\r\n listenForServiceChange() {\r\n this.menuService.isMobileMenuActive$.pipe(takeUntil(this.destroy$)).subscribe(isActive => {\r\n if (!isActive) {\r\n this.hide();\r\n }\r\n });\r\n }\r\n\r\n hide() {\r\n this.open = false;\r\n $('.navbar-collapse').collapse('hide');\r\n this.cdr.detectChanges();\r\n }\r\n\r\n toggleMenu() {\r\n if (this.shownComplete) {\r\n this.shownComplete = false;\r\n this.open = !this.open;\r\n }\r\n }\r\n\r\n ngAfterViewInit() {\r\n $('.navbar-collapse')\r\n .on('shown.bs.collapse', () => (this.shownComplete = true))\r\n .on('hidden.bs.collapse', () => (this.shownComplete = true))\r\n }\r\n\r\n setLoader(value: boolean) {\r\n this.getLoading = value;\r\n this.cdr.detectChanges();\r\n }\r\n\r\n parseId(id: string): string {\r\n return id.replace(/ /g,'')\r\n }\r\n\r\n handleOutsideClick() {\r\n const clickEvent$ = fromEvent(document, 'click');\r\n clickEvent$\r\n .pipe(\r\n takeUntil(this.destroy$),\r\n filter(e => !this._elementRef.nativeElement.contains(e.target)),\r\n tap(() => this.hide())\r\n )\r\n .subscribe();\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n 0; else defaultMenuItem\">\r\n {{ item.attributes.title }}\r\n \r\n \r\n \r\n \r\n\r\n \r\n\r\n \r\n {{\r\n item.attributes.title\r\n }}\r\n \r\n\r\n \r\n {{\r\n item.attributes.title\r\n }}\r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { HttpClientModule } from '@angular/common/http';\r\nimport { LogoModule } from '@app/template/layout/modules/logo/logo.module';\r\nimport { DefaultMenuComponent } from './components/default-menu/default-menu.component';\r\nimport { RouterModule } from '@angular/router';\r\nimport { PolygonModule } from '@app/template/elements/polygon/polygon.module';\r\nimport { MobileMenuComponent } from '@app/client-core/menu/components/mobile-menu/mobile-menu.component';\r\n\r\n@NgModule({\r\n declarations: [MobileMenuComponent, DefaultMenuComponent],\r\n imports: [CommonModule, HttpClientModule, RouterModule, ElementsModule, TranslatorModule, LogoModule, PolygonModule],\r\n exports: [DefaultMenuComponent, MobileMenuComponent]\r\n})\r\nexport class MenuModule {}\r\n","import { Injectable } from '@angular/core';\r\nimport { BehaviorSubject, Observable, of } from 'rxjs';\r\nimport { MenuModel } from '@app/client-core/menu/models/menu.model';\r\nimport { ResponseArray } from '@share/common/models/http';\r\nimport { API } from '@app/common/constants/api.directories';\r\nimport { ApiService } from '@app/common/services/api.service';\r\nimport { Router } from '@angular/router';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class MenuService {\r\n\r\n isMobileMenuActive$: BehaviorSubject = new BehaviorSubject(false);\r\n\r\n constructor(private apiService: ApiService, private router: Router) {\r\n }\r\n\r\n public getList(type?: string): Observable> {\r\n return this.apiService.getAll(`${API.MENU.ROOT}${type ? `/${type}` : ''}`);\r\n }\r\n\r\n public navigate(type: string, url: string): Promise {\r\n if (type === 'link') {\r\n return new Promise((resolve) => {\r\n window.open(url);\r\n resolve(true);\r\n });\r\n } else {\r\n if (!url || url.includes('null')) {\r\n return this.router.navigate(['/']);\r\n } else {\r\n return this.router.navigateByUrl('/' + url);\r\n }\r\n }\r\n }\r\n\r\n public isActive(url: string): boolean {\r\n return this.router.isActive(url, true);\r\n }\r\n\r\n}\r\n","import { ChangeDetectionStrategy, ChangeDetectorRef, Component, Inject, OnDestroy } from '@angular/core';\r\nimport { SUBHEADER_INJECTION_TOKEN } from '@app/client-core/search/subheader-injection-token';\r\nimport { Observable, Subject } from 'rxjs';\r\nimport { takeUntil } from 'rxjs/operators';\r\n\r\n@Component({\r\n selector: 'app-search-results-subheader',\r\n templateUrl: 'search-results-subheader.component.html',\r\n styleUrls: ['search-results-subheader.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class SearchResultsSubheaderComponent implements OnDestroy {\r\n private destroy$: Subject = new Subject();\r\n\r\n amount: number;\r\n keyword: string;\r\n\r\n constructor(\r\n @Inject(SUBHEADER_INJECTION_TOKEN) data: Observable<{ amount: number; keyword: string }>,\r\n private cdr: ChangeDetectorRef\r\n ) {\r\n data.pipe(takeUntil(this.destroy$)).subscribe(data => {\r\n this.amount = data.amount;\r\n this.keyword = data.keyword;\r\n this.cdr.detectChanges();\r\n });\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.destroy$.next(true);\r\n this.destroy$.complete();\r\n }\r\n}\r\n","\r\n {{ keyword }} - Wyniki wyszukiwania\r\n \r\n Znaleziono\r\n {{ amount || 0 }} wyników\r\n \r\n\r\n","import { ChangeDetectorRef, Component, Injector, OnDestroy, OnInit } from '@angular/core';\r\nimport { ActivatedRoute } from '@angular/router';\r\nimport { SearchService } from '@app/client-core/search/services/search.service';\r\nimport { SearchItem } from '@app/client-core/search/models/search-item.model';\r\nimport { SearchType } from '@app/template/layout/modules/header/interfaces/subheader-config.interface';\r\nimport { BreadcrumbsService } from '@app/template/layout/modules/header/services/breadcrumbs.service';\r\nimport { combineLatest } from 'rxjs/internal/observable/combineLatest';\r\nimport { finalize, first, map, takeUntil, tap } from 'rxjs/operators';\r\nimport { PaginationService } from '@app/template/elements/pagination/services/pagination.service';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { SearchResultsSubheaderComponent } from '@app/client-core/search/components/search-results-subheader/search-results-subheader.component';\r\nimport { Subject } from 'rxjs';\r\nimport { SearchHelperService } from '@app/client-core/search/search-helper.service';\r\nimport { SUBHEADER_INJECTION_TOKEN } from '@app/client-core/search/subheader-injection-token';\r\nimport { ResponseArray } from '@share/common/models/http';\r\n\r\n@Component({\r\n selector: 'app-search-results',\r\n templateUrl: './search-results.component.html',\r\n styleUrls: ['./search-results.component.scss']\r\n})\r\nexport class SearchResultsComponent implements OnInit, OnDestroy {\r\n searchedWord: string;\r\n data: { articles: SearchItem[]; pages: SearchItem[] } = { articles: [], pages: [] };\r\n type: SearchType;\r\n pages: number = 1;\r\n count: number = 20;\r\n getLoading: boolean;\r\n getError: boolean;\r\n destroyed$: Subject = new Subject();\r\n\r\n private searchMetadata: Subject<{ amount: number; keyword: string }> = new Subject<{\r\n amount: number;\r\n keyword: string;\r\n }>();\r\n\r\n constructor(\r\n private activatedRoute: ActivatedRoute,\r\n private searchService: SearchService,\r\n private breadcrumbsService: BreadcrumbsService,\r\n private paginationService: PaginationService,\r\n private facadeService: FacadeService,\r\n private injector: Injector,\r\n private searchHelperService: SearchHelperService,\r\n private cdr: ChangeDetectorRef\r\n ) {\r\n this.setSubheader();\r\n this.setBreadcrumbs();\r\n }\r\n\r\n private setSubheader() {\r\n this.facadeService.subheader.setConfig({\r\n component: SearchResultsSubheaderComponent,\r\n injector: Injector.create({\r\n providers: [\r\n {\r\n provide: SUBHEADER_INJECTION_TOKEN,\r\n useValue: this.searchMetadata\r\n }\r\n ],\r\n parent: this.injector\r\n })\r\n });\r\n this.facadeService.subheader.config.displayBreadcrumbs.next(true);\r\n }\r\n\r\n public ngOnInit() {\r\n this.setPageListener();\r\n window.scrollTo(0, 0);\r\n }\r\n\r\n setLoader(value: boolean) {\r\n this.getLoading = value;\r\n this.cdr.detectChanges();\r\n }\r\n\r\n public searchRequest(page: number) {\r\n this.clearData();\r\n this.setLoader(true);\r\n this.searchService\r\n .getFullList(this.searchedWord, this.type, page, this.count)\r\n .pipe(\r\n first(),\r\n tap(response => (this.searchService.amount = response.data.length)),\r\n finalize(() => this.setLoader(false))\r\n )\r\n .subscribe(response => this.onResponseSuccess(response));\r\n }\r\n\r\n onResponseSuccess(response: ResponseArray) {\r\n this.clearData();\r\n this.searchMetadata.next({ amount: response?.meta?.amount || 0, keyword: this.searchedWord });\r\n response.data?.forEach((item: any) => {\r\n if (item.type === 'Page') {\r\n this.data = { articles: [...this.data.articles], pages: [...this.data.pages, item] };\r\n } else if (item.type === 'CmsArticle') {\r\n this.data = { articles: [...this.data.articles, item], pages: [...this.data.pages] };\r\n }\r\n });\r\n const meta = response.meta;\r\n if (meta && typeof meta.pages === 'number') {\r\n this.pages = meta.pages;\r\n }\r\n }\r\n\r\n identify(index: number) {\r\n return index;\r\n }\r\n\r\n private clearData() {\r\n this.data = {\r\n articles: [],\r\n pages: []\r\n };\r\n }\r\n\r\n navigateTo(url: string, isExternal: boolean) {\r\n if (isExternal) {\r\n window.open(url);\r\n } else {\r\n this.facadeService.router.navigate([url]);\r\n }\r\n }\r\n\r\n private setBreadcrumbs() {\r\n this.breadcrumbsService.forceActive = true;\r\n this.breadcrumbsService.customBreadcrumbs = [{ title: this.facadeService.translator.trans('search.header') }];\r\n }\r\n\r\n private setPageListener() {\r\n combineLatest([this.activatedRoute.params, this.paginationService.currentPage])\r\n .pipe(\r\n map(results => ({ data: results[0].data, page: results[1] })),\r\n takeUntil(this.destroyed$)\r\n )\r\n .subscribe(results => {\r\n this.searchedWord = results.data;\r\n this.searchRequest(results.page);\r\n });\r\n }\r\n\r\n ngOnDestroy() {\r\n this.destroyed$.next(true);\r\n this.destroyed$.complete();\r\n this.breadcrumbsService.forceActive = false;\r\n }\r\n}\r\n","\r\n \r\n \r\n 0\">\r\n Artykuły\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n 0\">\r\n Strony\r\n \r\n {{ item.attributes.content }}\r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { ChangeDetectorRef, Component, ElementRef, Input, OnDestroy, OnInit, ViewChild } from '@angular/core';\r\nimport { SearchService } from '@app/client-core/search/services/search.service';\r\nimport { SearchItem } from '@app/client-core/search/models/search-item.model';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { NavigationExtras } from '@angular/router';\r\nimport { SearchType } from '@app/template/layout/modules/header/interfaces/subheader-config.interface';\r\nimport { fromEvent, Observable, Subject } from 'rxjs';\r\nimport { filter, finalize, first, takeUntil, tap } from 'rxjs/operators';\r\nimport { UtilsService } from '@share/common/services/utils.service';\r\nimport { SelectModel } from '@share/modules/html/common/interfaces/select-model.interface';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { ThemesEnum } from '@app/common/models/themes.enum';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { ResizeListener } from '@app/common/services/resize-listener.service';\r\n\r\n@Component({\r\n selector: 'app-search',\r\n templateUrl: './search.component.html',\r\n styleUrls: ['./search.component.scss']\r\n})\r\nexport class SearchComponent implements OnInit, OnDestroy {\r\n\r\n private _value = '';\r\n private readonly minLength: number = 3;\r\n private destroy$: Subject = new Subject();\r\n\r\n @ViewChild('input') input: ElementRef;\r\n @Input() mobile: boolean;\r\n @Input() placeholder: string = 'search.button';\r\n\r\n data: { articles: SearchItem[]; pages: SearchItem[] } = { articles: [], pages: [] };\r\n availablesTypes: Array> = [];\r\n type: SearchType = SearchType.Default;\r\n searchSelectId: string;\r\n searchId: string;\r\n showResultsBox: boolean;\r\n loading: boolean;\r\n error: boolean;\r\n forceActive: boolean;\r\n isActive$: Observable;\r\n\r\n\r\n constructor(\r\n private searchService: SearchService,\r\n private _elementRef: ElementRef,\r\n private utils: UtilsService,\r\n private settingsService: SettingsService,\r\n private cdr: ChangeDetectorRef,\r\n private facadeService: FacadeService,\r\n ) {\r\n this.availablesTypes = this.searchService.getAvailableSearchTypes();\r\n const newId: string = this.utils.makeId();\r\n this.searchSelectId = `search-type-${newId}`;\r\n this.searchId = `search-input-${newId}`;\r\n }\r\n\r\n markAsActive() {\r\n this.searchService.isActive$.next(true);\r\n setTimeout(() => {\r\n this.forceActive = true;\r\n this.input.nativeElement.focus();\r\n }, 500)\r\n }\r\n\r\n markAsInactive(){\r\n this.searchService.isActive$.next(false);\r\n this.forceActive = false;\r\n this.showResultsBox = false;\r\n }\r\n\r\n onValueChange(value: string) {\r\n if (value.length >= 3) {\r\n this.showResultsBox = true;\r\n this.searchRequest(value);\r\n } else {\r\n this.showResultsBox = false;\r\n }\r\n this.value = value;\r\n }\r\n\r\n ngOnInit() {\r\n this.setSearchType();\r\n this.handleOutsideClick();\r\n this.isActive$ = this.searchService.isActive$;\r\n }\r\n\r\n private setSearchType() {\r\n this.facadeService.subheader.getConfig().subscribe(config => {\r\n this.type = config.searchType || SearchType.Default;\r\n });\r\n }\r\n\r\n handleOutsideClick() {\r\n const clickEvent$ = fromEvent(document, 'click');\r\n clickEvent$\r\n .pipe(\r\n takeUntil(this.destroy$),\r\n filter(e => !this._elementRef.nativeElement.contains(e.target)),\r\n tap(e => {\r\n this.clear();\r\n this.markAsInactive();\r\n })\r\n )\r\n .subscribe();\r\n }\r\n\r\n get value() {\r\n return this._value;\r\n }\r\n\r\n set value(data: string) {\r\n this._value = data;\r\n }\r\n\r\n hasMinLength(value: string) {\r\n const valid = value.length >= this.minLength;\r\n if (!valid) {\r\n this.clearData();\r\n }\r\n return valid;\r\n }\r\n\r\n search() {\r\n if (this.hasMinLength(this.value)) {\r\n this.markAsInactive();\r\n this.facadeService.router.navigate(['search', this._value], this.getNavigationExtras()).then(onfulfilled => {\r\n if (onfulfilled) {\r\n this.clear();\r\n }\r\n });\r\n }\r\n }\r\n\r\n private getNavigationExtras() {\r\n const extra: NavigationExtras = { queryParams: null };\r\n if (this.type !== SearchType.Default) {\r\n extra.queryParams = { type: this.type };\r\n }\r\n return extra;\r\n }\r\n\r\n setLoader(value: boolean) {\r\n this.loading = value;\r\n this.cdr.detectChanges();\r\n }\r\n\r\n searchRequest(value: string) {\r\n this.setLoader(true);\r\n this.clearData();\r\n this.searchService\r\n .getList(value, this.type)\r\n .pipe(\r\n first(),\r\n finalize(() => this.setLoader(false))\r\n )\r\n .subscribe(response => {\r\n this.clearData();\r\n response.data?.forEach((item: any) => {\r\n if (item.type === 'Page') {\r\n this.data = { articles: [...this.data.articles], pages: [...this.data.pages, item] };\r\n } else if (item.type === 'CmsArticle') {\r\n this.data = { articles: [...this.data.articles, item], pages: [...this.data.pages] };\r\n }\r\n });\r\n });\r\n }\r\n\r\n private clear() {\r\n this._value = '';\r\n this.clearData();\r\n this.showResultsBox = false;\r\n }\r\n\r\n private clearData() {\r\n this.data = {\r\n articles: [],\r\n pages: []\r\n }\r\n }\r\n\r\n ngOnDestroy() {\r\n this.destroy$.next(true);\r\n this.destroy$.complete();\r\n }\r\n}\r\n","\r\n \r\n {{'search.searchLabel' | trans}}\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n 0 || data.articles.length > 0\" [error]=\"error\">\r\n \r\n 0\">\r\n {{'search.pages' | trans}}\r\n \r\n {{ item.attributes.title }}\r\n \r\n \r\n\r\n 0\">\r\n {{'search.articles' | trans}}\r\n \r\n {{ item.attributes.title }}\r\n \r\n \r\n \r\n\r\n \r\n {{'search.noData' | trans}}\r\n \r\n \r\n \r\n\r\n","import { Injectable } from '@angular/core';\r\nimport { BehaviorSubject, forkJoin, Observable } from 'rxjs';\r\n\r\n@Injectable()\r\nexport class SearchHelperService {\r\n amount: BehaviorSubject = new BehaviorSubject(0);\r\n keyword: BehaviorSubject = new BehaviorSubject('');\r\n\r\n getData(): Observable<{ amount: number; keyword: string }> {\r\n return forkJoin({ amount: this.amount, keyword: this.keyword });\r\n }\r\n}\r\n","import {NgModule} from '@angular/core';\r\nimport {CommonModule} from '@angular/common';\r\nimport {SearchComponent} from './components/search/search.component';\r\nimport {FormsModule} from '@angular/forms';\r\nimport {ElementsModule} from '@share/modules/elements/elements.module';\r\nimport {SearchResultsComponent} from './components/search-results/search-results.component';\r\nimport {TranslatorModule} from '@share/modules/translator/translator.module';\r\nimport {NgbPaginationModule} from '@ng-bootstrap/ng-bootstrap';\r\nimport {ContainerModule} from '@app/template/layout/modules/container/container.module';\r\nimport {SelectModule} from '@share/modules/html/select/select.module';\r\nimport { PaginationModule } from '@app/template/elements/pagination/pagination.module';\r\nimport { PaginationService } from '@app/template/elements/pagination/services/pagination.service';\r\nimport { RouterModule } from '@angular/router';\r\nimport { SearchResultsSubheaderComponent } from '@app/client-core/search/components/search-results-subheader/search-results-subheader.component';\r\nimport { ArticleModule } from '@app/client-core/article/article.module';\r\nimport { SearchHelperService } from '@app/client-core/search/search-helper.service';\r\n\r\n@NgModule({\r\n declarations: [SearchComponent, SearchResultsComponent, SearchResultsSubheaderComponent],\r\n imports: [\r\n CommonModule,\r\n FormsModule,\r\n ElementsModule,\r\n TranslatorModule,\r\n NgbPaginationModule,\r\n ContainerModule,\r\n SelectModule,\r\n PaginationModule,\r\n RouterModule,\r\n ArticleModule,\r\n ],\r\n exports: [\r\n SearchComponent,\r\n SearchResultsComponent\r\n ],\r\n providers: [\r\n PaginationService,\r\n SearchHelperService\r\n ]\r\n})\r\nexport class SearchModule {}\r\n","import {Injectable} from '@angular/core';\r\nimport {ServiceHelper} from '@share/common/helpers/service.helper';\r\nimport {API} from '@app/common/constants/api.directories';\r\nimport { BehaviorSubject, Observable } from 'rxjs';\r\nimport {SearchType, SearchTypeNames} from '@app/template/layout/modules/header/interfaces/subheader-config.interface';\r\nimport {HttpParams} from '@angular/common/http';\r\nimport {AbstractData} from '@share/common/models/http.model';\r\nimport {SelectModel} from '@share/modules/html/common/interfaces/select-model.interface';\r\nimport {Bundle} from '@app/common/enums/server-bundles.enum';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class SearchService extends ServiceHelper {\r\n\r\n amount: number = 0;\r\n isActive$: BehaviorSubject = new BehaviorSubject(false);\r\n\r\n constructor() {\r\n super('');\r\n }\r\n\r\n public getList(keyword: string, searchType: SearchType): Observable {\r\n let params: HttpParams = new HttpParams().set('contains', keyword);\r\n\r\n if (!!searchType) {\r\n params = params.set('inside', searchType);\r\n }\r\n\r\n return this.getAll(API.SEARCH.ROOT, {http: {params}});\r\n }\r\n\r\n public getFullList(keyword: string, searchType: SearchType, page: number, count: number): Observable {\r\n let params: HttpParams = new HttpParams();\r\n\r\n params = params.set('page', page.toString());\r\n params = params.set('count', count.toString());\r\n params = params.set('contains', keyword);\r\n\r\n if (!!searchType) {\r\n params = params.set('inside', searchType);\r\n }\r\n\r\n return this.getAll(API.SEARCH.FULL, {http: {params}});\r\n }\r\n\r\n public getAvailableSearchTypes(): Array> {\r\n return [\r\n {\r\n id: SearchType.Default,\r\n type: Bundle.Alert,\r\n attributes: {\r\n title: SearchTypeNames.Default\r\n }\r\n },\r\n {\r\n id: SearchType.EServices,\r\n type: Bundle.Alert,\r\n attributes: {\r\n title: SearchTypeNames.EServices\r\n }\r\n }\r\n ];\r\n }\r\n}\r\n","import { InjectionToken } from '@angular/core';\r\n\r\nexport const SUBHEADER_INJECTION_TOKEN = new InjectionToken('SUBHEADER_INJECTION_TOKEN');\r\n","export { StaticPageComponent } from './static-page/static-page.component';\r\nexport { StaticPageDefaultComponent } from './static-page-default/static-page-default.component';\r\nexport { StaticPageContactComponent } from './static-page-contact/static-page-contact.component';\r\nexport { ContactFormComponent } from './static-page-contact/contact-form/contact-form.component';\r\nexport { ContactImagesComponent } from './static-page-contact/contact-images/contact-images.component';\r\nexport { ContactSubheaderComponent } from './static-page-contact/contact-subheader/contact-subheader.component';\r\nexport { SchedulePageComponent } from './schedule-page/schedule-page.component';\r\n","import { ChangeDetectionStrategy, Component, Input } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'app-schedule-page',\r\n templateUrl: 'schedule-page.component.html',\r\n styleUrls: ['schedule-page.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class SchedulePageComponent {\r\n @Input() data: {\r\n content: {\r\n boxPhone: string;\r\n boxSchedule: string;\r\n boxTitle: string;\r\n boxSubtitle: string;\r\n subtitle: string;\r\n schedule: {date: string, cities: string}[];\r\n };\r\n };\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n {{ boxTitle }}\r\n \r\n \r\n {{ boxSubtitle }}\r\n \r\n \r\n \r\n {{ boxPhone }}\r\n \r\n \r\n\r\n\r\n\r\n \r\n {{ title }}\r\n {{ content }}\r\n \r\n\r\n","import { Observable } from 'rxjs';\r\nimport { ResponseArray } from '@share/common/models/http';\r\nimport { API } from '@app/common/constants/api.directories';\r\nimport { ApiService } from '@app/common/services/api.service';\r\nimport { Injectable } from '@angular/core';\r\n\r\n@Injectable({ providedIn: 'root' })\r\nexport class ConsentsService {\r\n constructor(private apiService: ApiService) {}\r\n\r\n getList(name: string = ''): Observable> {\r\n return this.apiService.getAll(`${API.AUTH.CONSENTS}/${name}`);\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'app-contact-dots',\r\n templateUrl: 'contact-dots.component.html',\r\n styleUrls: ['contact-dots.component.scss']\r\n})\r\nexport class ContactDotsComponent {}\r\n","\r\n \r\n\r\n","import { AfterViewInit, ChangeDetectionStrategy, ChangeDetectorRef, Component, Input, OnDestroy, OnInit } from '@angular/core';\r\nimport { FormBuilder, FormGroup } from '@angular/forms';\r\nimport { CaptchaV3Service } from '@app/common/services/captcha-v3.service';\r\nimport { ConsentsService } from '@app/client-core/static-pages/components/static-page-contact/consents.service';\r\nimport { finalize, first } from 'rxjs/operators';\r\nimport { getContactFormGroup } from '@app/client-core/static-pages/components/static-page-contact/contact-form/form/contact-form.group';\r\nimport { getContactFormConfig } from '@app/client-core/static-pages/components/static-page-contact/contact-form/form/contact-form.config';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { ContactService } from '@app/client-core/static-pages/components/static-page-contact/contact.service';\r\n\r\n@Component({\r\n selector: 'app-contact-form',\r\n templateUrl: 'contact-form.component.html',\r\n styleUrls: ['contact-form.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class ContactFormComponent implements OnInit, OnDestroy, AfterViewInit {\r\n formGroup: FormGroup;\r\n formConfig: { [id: string]: any };\r\n consentLoader: boolean;\r\n sendLoader: boolean;\r\n\r\n @Input() title: string;\r\n @Input() subtitle: string;\r\n\r\n constructor(\r\n private formBuilder: FormBuilder,\r\n private captchaService: CaptchaV3Service,\r\n private consentService: ConsentsService,\r\n private cdr: ChangeDetectorRef,\r\n private facadeService: FacadeService,\r\n private contactService: ContactService\r\n ) {\r\n this.initFormGroup();\r\n }\r\n\r\n private initFormGroup() {\r\n this.formGroup = this.formBuilder.group(getContactFormGroup());\r\n this.formConfig = getContactFormConfig(this.facadeService.translator);\r\n }\r\n\r\n ngOnInit() {\r\n this.captchaService.load();\r\n this.getConsents();\r\n }\r\n\r\n getConsents() {\r\n this.consentLoader = true;\r\n this.cdr.detectChanges();\r\n this.consentService\r\n .getList('contact')\r\n .pipe(\r\n first(),\r\n finalize(() => {\r\n this.consentLoader = false;\r\n this.cdr.detectChanges();\r\n })\r\n )\r\n .subscribe(response => {\r\n const [first] = response.data;\r\n this.setConsentConfig(first.id, first.attributes.fulltext);\r\n });\r\n }\r\n\r\n setConsentConfig(id: string, label: string) {\r\n this.formConfig.consent = {\r\n id: id,\r\n label: label,\r\n allowHtmlLabel: true\r\n };\r\n }\r\n\r\n ngAfterViewInit() {\r\n this.captchaService.toggleVisibility();\r\n }\r\n\r\n onSubmit() {\r\n this.sendLoader = true;\r\n this.cdr.detectChanges();\r\n this.captchaService.execute()\r\n .pipe(\r\n first()\r\n )\r\n .subscribe(\r\n token => {\r\n this.formGroup.patchValue({ captcha: token });\r\n this.sendForm();\r\n },\r\n () => {\r\n this.facadeService.toastr.error(this.facadeService.trans('contact.form.captchaError'));\r\n this.sendLoader = false;\r\n this.cdr.detectChanges();\r\n }\r\n );\r\n }\r\n\r\n sendForm() {\r\n this.contactService\r\n .submit(this.formGroup.getRawValue())\r\n .pipe(\r\n first(),\r\n finalize(() => {\r\n this.sendLoader = false;\r\n this.cdr.detectChanges();\r\n })\r\n )\r\n .subscribe(\r\n () => {\r\n this.facadeService.toastr.success(this.facadeService.translator.trans('contact.form.successMessage'));\r\n this.formGroup.reset();\r\n },\r\n );\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.captchaService.toggleVisibility(false);\r\n }\r\n}\r\n","\r\n {{ title }}\r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n\r\n\r\n","import { InputTypeEnum } from '@share/modules/html/input/enums/input-types.enum';\r\nimport { TranslatorService } from '@share/common/services/translator.service';\r\n\r\nexport function getContactFormConfig(translatorService: TranslatorService): { [id: string]: any } {\r\n return {\r\n senderName: {\r\n id: 'senderName',\r\n type: InputTypeEnum.Text,\r\n label: translatorService.trans('contact.form.name')\r\n },\r\n senderEmail: {\r\n id: 'senderEmail',\r\n type: InputTypeEnum.Text,\r\n label: translatorService.trans('contact.form.email')\r\n },\r\n content: {\r\n id: 'content',\r\n type: InputTypeEnum.Text,\r\n label: translatorService.trans('contact.form.message')\r\n }\r\n };\r\n}\r\n","import { Validators } from '@angular/forms';\r\n\r\nexport function getContactFormGroup(): { [id: string]: any } {\r\n return {\r\n senderName: ['', Validators.required],\r\n senderEmail: ['', Validators.required],\r\n content: ['', Validators.required],\r\n dataProcessConsent: [false, Validators.requiredTrue],\r\n captcha: ['', Validators.required]\r\n };\r\n}\r\n","import { Component, Input } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'app-contact-images',\r\n templateUrl: 'contact-images.component.html',\r\n styleUrls: ['contact-images.component.scss']\r\n})\r\nexport class ContactImagesComponent {\r\n @Input() biggerImageUrl: string;\r\n @Input() smallerImageUrl: string;\r\n\r\n @Input() isRight: boolean;\r\n @Input() special: boolean;\r\n @Input() smallUp: boolean;\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n\r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { InstitutionService } from '@app/common/services/institution.service';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { first } from 'rxjs/operators';\r\nimport { Institution } from '@app/common/models/institution.model';\r\n\r\n@Component({\r\n selector: 'app-contact-subheader',\r\n templateUrl: 'contact-subheader.component.html',\r\n styleUrls: ['contact-subheader.component.scss']\r\n})\r\nexport class ContactSubheaderComponent implements OnInit {\r\n\r\n institution: AbstractData;\r\n\r\n constructor(private institutionService: InstitutionService) {}\r\n\r\n ngOnInit() {\r\n this.getInstitutionData();\r\n }\r\n\r\n getInstitutionData() {\r\n this.institutionService\r\n .getCurrent()\r\n .pipe(\r\n first()\r\n )\r\n .subscribe(response => this.institution = response.data)\r\n }\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n Dane kontaktowe\r\n \r\n {{institution.attributes.name}}\r\n {{institution.attributes.address.zipCode}} {{institution.attributes.address.city}} \r\n {{institution.attributes.address.street}} {{institution.attributes.address.houseNumber}}\r\n tel.: {{institution.attributes.contact.phoneNumber}}\r\n {{institution.attributes.contact.email}}\r\n \r\n \r\n\r\n","import { Injectable } from '@angular/core';\r\nimport { Observable } from 'rxjs';\r\nimport { ApiService } from '@app/common/services/api.service';\r\nimport { API } from '@app/common/constants/api.directories';\r\n\r\n@Injectable({providedIn: 'root'})\r\nexport class ContactService {\r\n\r\n constructor(private apiService: ApiService) {\r\n }\r\n\r\n public submit(contact: any): Observable {\r\n return this.apiService.post('contact', contact);\r\n }\r\n}\r\n","import { ChangeDetectionStrategy, Component, Input } from '@angular/core';\r\nimport { ImageCropper } from '@app/template/home/models/image-cropper.model';\r\n\r\n@Component({\r\n selector: 'app-static-page-contact-department',\r\n templateUrl: 'static-page-contact-department.component.html',\r\n styleUrls: ['static-page-contact-department.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class StaticPageContactDepartmentComponent {\r\n\r\n @Input() rightImage: boolean;\r\n @Input() special: boolean;\r\n @Input() specialTwo: boolean;\r\n @Input() smallUp: boolean;\r\n\r\n @Input() data: {\r\n title: string;\r\n bigImage: ImageCropper;\r\n smallImage: ImageCropper;\r\n people: {\r\n personOrPlace: string;\r\n contact: {\r\n type: 'phone' | 'email';\r\n value: string;\r\n extra: string | null;\r\n }[];\r\n }[];\r\n };\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n {{ data.title }}\r\n \r\n \r\n \r\n \r\n \r\n\r\n\r\n\r\n \r\n {{person.description}}\r\n {{person.fullName}} - {{person?.scope}}\r\n \r\n \r\n Numer telefonu\r\n \r\n {{ contact.value }}\r\n wew. {{ contact.extra }}\r\n \r\n\r\n \r\n Email\r\n \r\n {{ contact.value }}\r\n \r\n \r\n \r\n\r\n","import { Component, Input } from '@angular/core';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { ContactSubheaderComponent } from '@app/client-core/static-pages/components/static-page-contact/contact-subheader/contact-subheader.component';\r\n\r\n@Component({\r\n selector: 'app-static-page-contact',\r\n templateUrl: './static-page-contact.component.html',\r\n styleUrls: ['./static-page-contact.component.scss']\r\n})\r\nexport class StaticPageContactComponent {\r\n @Input() data: {\r\n sectionOne: any,\r\n sectionTwo: any,\r\n sectionThree: any,\r\n sectionFour: any\r\n };\r\n\r\n constructor(private facadeService: FacadeService) {\r\n this.facadeService.subheader.setConfig({\r\n component: ContactSubheaderComponent,\r\n hideDots: true\r\n });\r\n this.facadeService.subheader.displayBreadcrumbs = false;\r\n }\r\n}\r\n","\r\n\r\n\r\n \r\n \r\n {{ data.sectionThree.title }}\r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n = 3\">\r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { Component, Input } from '@angular/core';\r\nimport { StaticPageDefaultModel } from '@app/client-core/static-pages/model/static-page-default.model';\r\n\r\n@Component({\r\n selector: 'app-static-page-default',\r\n templateUrl: './static-page-default.component.html',\r\n styleUrls: ['./static-page-default.component.scss']\r\n})\r\nexport class StaticPageDefaultComponent {\r\n @Input() data: StaticPageDefaultModel;\r\n\r\n getFileUrl() {\r\n // TODO: Poprawić typy\r\n if (this.data.file?.hasOwnProperty('url')) {\r\n return this.data.file['croppedImage'] || this.data?.file['url'];\r\n }\r\n return this.getFileAsString();\r\n }\r\n\r\n private getFileAsString(): string | null {\r\n if (typeof this.data?.file === 'string') {\r\n return this.data?.file;\r\n }\r\n return null;\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { Component, Input, OnDestroy, OnInit } from '@angular/core';\r\nimport { SubheaderService } from '@app/template/layout/modules/header/services/subheader.service';\r\nimport { ElementService } from '@app/client-core/dynamic-content/service/element.service';\r\nimport { ActivatedRoute, Router } from '@angular/router';\r\nimport { UrlService } from '@app/common/services/url.service';\r\nimport { finalize, first, takeUntil } from 'rxjs/operators';\r\nimport { AbstractData, ResponseObject } from '@share/common/models/http';\r\nimport { PagesService } from '@app/common/services/pages.service';\r\nimport { PageModel } from '@app/common/models/page.model';\r\nimport { ReplaySubject } from 'rxjs';\r\nimport { HistoryService } from '@share/common/services/history.service';\r\nimport { StaticPage } from '@app/client-core/static-pages/model/static-pages.model';\r\nimport { Nullable } from '@share/common/types/utilities.types';\r\n\r\n@Component({\r\n selector: 'app-static-page',\r\n templateUrl: './static-page.component.html',\r\n styleUrls: ['./static-page.component.scss']\r\n})\r\nexport class StaticPageComponent implements OnInit, OnDestroy {\r\n @Input() page: Nullable>>>;\r\n\r\n private destroyed$: ReplaySubject = new ReplaySubject(1);\r\n getError: boolean;\r\n getLoading: boolean;\r\n\r\n constructor(\r\n protected pagesService: PagesService,\r\n protected subheaderService: SubheaderService,\r\n private elementService: ElementService,\r\n protected route: ActivatedRoute,\r\n private urlService: UrlService,\r\n private historyService: HistoryService,\r\n private router: Router\r\n ) {}\r\n\r\n private setListener() {\r\n this.elementService.sameComponentNavigation.pipe(takeUntil(this.destroyed$)).subscribe(same => {\r\n if (same) {\r\n this.loadPage();\r\n }\r\n });\r\n }\r\n\r\n ngOnInit() {\r\n this.setListener();\r\n if (!this.page) {\r\n this.loadPage();\r\n } else {\r\n this.setSubheader(this.page);\r\n }\r\n }\r\n\r\n protected onLoadPageSuccess(response: ResponseObject>>) {\r\n this.page = response.data;\r\n this.setSubheader(this.page);\r\n }\r\n\r\n private setSubheader(page: AbstractData>>) {\r\n this.subheaderService.setConfig({ title: page.attributes.title, publishedDate: page.attributes.publishedFrom });\r\n if (page.attributes.content?.pageType === 'schedule') {\r\n this.subheaderService.description = page?.attributes?.content?.content?.subtitle;\r\n this.subheaderService.publishedDate = '';\r\n }\r\n this.subheaderService.config.displayBreadcrumbs.next(true);\r\n }\r\n\r\n loadPage() {\r\n this.getLoading = true;\r\n this.pagesService\r\n .getOne(this.router.url.split('/').join(','))\r\n .pipe(\r\n first(),\r\n finalize(() => (this.getLoading = false))\r\n )\r\n .subscribe(\r\n response => this.onLoadPageSuccess(response),\r\n error => {\r\n this.subheaderService.setConfig({\r\n title: error.error.errors[0].status\r\n });\r\n this.subheaderService.description = error.error.errors[0].title;\r\n this.page = null;\r\n }\r\n );\r\n }\r\n\r\n ngOnDestroy() {\r\n this.destroyed$.next(true);\r\n this.destroyed$.complete();\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { RouterModule } from '@angular/router';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { ContainerModule } from '@app/template/layout/modules/container/container.module';\r\nimport { GoogleMapModule } from '@share/modules/google-map/google-map.module';\r\nimport {\r\n ContactFormComponent,\r\n StaticPageComponent,\r\n StaticPageContactComponent,\r\n StaticPageDefaultComponent,\r\n ContactImagesComponent,\r\n ContactSubheaderComponent,\r\n SchedulePageComponent\r\n} from '@app/client-core/static-pages/components';\r\nimport { ArticleModule } from '@app/client-core/article/article.module';\r\nimport { SimpleBoxModule } from '@app/template/elements/simple-box/simple-box.module';\r\nimport { ReactiveFormsModule } from '@angular/forms';\r\nimport { CheckboxModule } from '@share/modules/html/checkbox/checkbox.module';\r\nimport { InputModule } from '@app/template/elements/input/input.module';\r\nimport { TextareaModule } from '@app/template/elements/textarea/textarea.module';\r\nimport { HeaderModule } from '@app/template/layout/modules/header/header.module';\r\nimport { StaticPageContactDepartmentComponent } from '@app/client-core/static-pages/components/static-page-contact/static-page-contact-department/static-page-contact-department.component';\r\nimport { ContactDotsComponent } from '@app/client-core/static-pages/components/static-page-contact/contact-dots/contact-dots.component';\r\nimport { BreadcrumbsModule } from '@app/template/layout/modules/breadcrumbs/breadcrumbs.module';\r\n\r\n@NgModule({\r\n declarations: [\r\n SchedulePageComponent,\r\n StaticPageContactDepartmentComponent,\r\n ContactImagesComponent,\r\n ContactSubheaderComponent,\r\n ContactFormComponent,\r\n StaticPageComponent,\r\n StaticPageDefaultComponent,\r\n StaticPageContactComponent,\r\n ContactDotsComponent\r\n ],\r\n imports: [\r\n CommonModule,\r\n RouterModule,\r\n ElementsModule,\r\n TranslatorModule,\r\n ContainerModule,\r\n GoogleMapModule,\r\n ArticleModule,\r\n SimpleBoxModule,\r\n ReactiveFormsModule,\r\n CheckboxModule,\r\n InputModule,\r\n TextareaModule,\r\n HeaderModule,\r\n BreadcrumbsModule\r\n ],\r\n exports: [StaticPageComponent]\r\n})\r\nexport class StaticPagesModule {}\r\n","import { AppConfigCMS } from '@share/common/interfaces/app-config.interface';\r\n\r\ndeclare const APP_CONFIG: AppConfigCMS;\r\nexport const URL = APP_CONFIG.API_URL;\r\nconst PREFIX = APP_CONFIG.PREFIX;\r\nconst SERVER = `${URL}/${PREFIX}`;\r\n\r\nexport const API = {\r\n AUTH: {\r\n LOGIN: `${SERVER}/login`,\r\n LOGOUT: `${SERVER}/logout`,\r\n CONSENTS: `${SERVER}/consents`,\r\n FORGOT_PASSWORD: `${SERVER}/account/resetPassword/sendEmail`,\r\n VALIDATE_TOKEN: `${SERVER}/account/resetPassword/checkToken`,\r\n CHANGE_PASSWORD: `${SERVER}/account/resetPassword/change`,\r\n ACTIVATE_ACCOUNT: `${SERVER}/account/confirm`\r\n },\r\n COMMON: {\r\n BREADCRUMBS: `${SERVER}/breadcrumbs`\r\n },\r\n ARTICLES: {\r\n ROOT: `${SERVER}/articles`,\r\n RANDOM: `${SERVER}/articles/random`\r\n },\r\n SETTINGS: {\r\n ROOT: `${SERVER}/settings/bootstrap`,\r\n GET_LAYOUT: `${SERVER}/settings/layout`\r\n },\r\n SEARCH: {\r\n ROOT: `${SERVER}/search/autocomplete`,\r\n FULL: `${SERVER}/search/getResult`\r\n },\r\n PROMOTED: {\r\n ROOT: `${SERVER}/promoted`\r\n },\r\n BANNERS: {\r\n ROOT: `${SERVER}/banners`\r\n },\r\n MENU: {\r\n ROOT: `${SERVER}/menu`,\r\n SITEMAP: `${SERVER}/menu/sitemap`\r\n },\r\n DYNAMIC_CONTENT: {\r\n ROOT: `${SERVER}/search/getMetadata`\r\n },\r\n CATEGORY: {\r\n ROOT: `${SERVER}/categories`\r\n },\r\n PROFILE: {\r\n ROOT: `${SERVER}/account`\r\n },\r\n ALERTS: {\r\n ROOT: `${SERVER}/alerts`\r\n },\r\n BUSINESS_MODULES: {\r\n ROOT: `${SERVER}/businessModules`,\r\n },\r\n PAGES: {\r\n ROOT: `${SERVER}/pages`\r\n },\r\n PREVIEW: {\r\n ROOT: `${SERVER}/preview`\r\n },\r\n INSTITUTION: {\r\n ROOT: 'institution'\r\n },\r\n ASSETS: {\r\n DEFAULT_SETTINGS: 'source/default_settings.json'\r\n }\r\n};\r\n","import { APP_INITIALIZER, LOCALE_ID, Provider } from '@angular/core';\r\nimport { HTTP_INTERCEPTORS } from '@angular/common/http';\r\nimport { BootstrapService } from '@app/common/services/bootstrap.service';\r\nimport {\r\n getBackendVersionFactory,\r\n getFrontendVersionFactory,\r\n getLanguageFactory,\r\n getMaintenanceFactory,\r\n getPermissions,\r\n getSettingsFactory,\r\n getTranslationsFactory\r\n} from '@app/common/functions/bootstrap';\r\nimport { LanguageService } from '@share/common/services/language.service';\r\nimport { InstitutionInterceptorService } from '@app/common/interceptors/institution-interceptor.service';\r\nimport { ContentInterceptorService } from '@app/common/interceptors/content-interceptor.service';\r\nimport { ApiInterceptorService } from '@app/common/interceptors/api-interceptor.service';\r\n\r\nexport const BOOTSTRAP_PROVIDERS: Provider[] = [\r\n {\r\n provide: HTTP_INTERCEPTORS,\r\n useClass: ApiInterceptorService,\r\n multi: true\r\n },\r\n {\r\n provide: HTTP_INTERCEPTORS,\r\n useClass: ContentInterceptorService,\r\n multi: true\r\n },\r\n {\r\n provide: HTTP_INTERCEPTORS,\r\n useClass: InstitutionInterceptorService,\r\n multi: true\r\n },\r\n {\r\n provide: LOCALE_ID,\r\n deps: [LanguageService],\r\n useFactory: getLanguageFactory\r\n },\r\n {\r\n provide: APP_INITIALIZER,\r\n useFactory: getTranslationsFactory,\r\n deps: [BootstrapService],\r\n multi: true\r\n },\r\n {\r\n provide: APP_INITIALIZER,\r\n useFactory: getMaintenanceFactory,\r\n deps: [BootstrapService],\r\n multi: true\r\n },\r\n {\r\n provide: APP_INITIALIZER,\r\n useFactory: getSettingsFactory,\r\n deps: [BootstrapService],\r\n multi: true\r\n },\r\n {\r\n provide: APP_INITIALIZER,\r\n useFactory: getBackendVersionFactory,\r\n deps: [BootstrapService],\r\n multi: true\r\n },\r\n {\r\n provide: APP_INITIALIZER,\r\n useFactory: getFrontendVersionFactory,\r\n deps: [BootstrapService],\r\n multi: true\r\n }\r\n];\r\n","import {HAMMER_GESTURE_CONFIG, HammerGestureConfig} from '@angular/platform-browser';\r\nimport {Injectable, Provider} from '@angular/core';\r\nimport * as Hammer from 'hammerjs';\r\n\r\n@Injectable()\r\nexport class MyHammerConfig extends HammerGestureConfig {\r\n buildHammer(element: HTMLElement) {\r\n return new Hammer(element, {\r\n touchAction: 'pan-y pan-x'\r\n });\r\n }\r\n}\r\n\r\nexport const HAMMER_PROVIDER: Provider[] = [\r\n {\r\n provide: HAMMER_GESTURE_CONFIG,\r\n useClass: MyHammerConfig\r\n }\r\n];\r\n","import { NgModuleFactory, Type } from '@angular/core';\r\nimport { ThemesEnum } from '@app/common/models/themes.enum';\r\n\r\nexport const lazyWidgets: { name: string; loadChildren: () => Promise | Type> }[] = [\r\n {\r\n name: ThemesEnum.CORE,\r\n loadChildren: () => import('@app/client-core/static-pages/static-pages.module').then(m => m.StaticPagesModule)\r\n },\r\n {\r\n name: ThemesEnum.ARTICLE,\r\n loadChildren: () => import('@app/client-core/article/article.module').then(m => m.ArticleModule)\r\n },\r\n {\r\n name: ThemesEnum.MENU,\r\n loadChildren: () => import('@app/client-core/menu/menu.module').then(m => m.MenuModule)\r\n }\r\n];\r\n\r\nexport function lazyArrayToObj() {\r\n const result = {};\r\n for (const w of lazyWidgets) {\r\n result[w.name] = w.loadChildren;\r\n }\r\n return result;\r\n}\r\n","import {PortalVariablesEnum} from '@app/common/enums/portal-variables.enum';\r\n\r\nexport const PORTAL_VARIABLES_PRESETS = {\r\n [PortalVariablesEnum.MainColor]: '',\r\n [PortalVariablesEnum.SectionBackgroundColor]: '',\r\n [PortalVariablesEnum.ButtonColor]: '',\r\n [PortalVariablesEnum.AccentColor]: '',\r\n};\r\n","export const ARTICLE_PREVIEW = 'articles';\r\nexport const STATIC_PAGE_PREVIEW = 'static-pages';\r\nexport const ESERVICE_PREVIEW = 'eservices';\r\nexport const ROUTES_PATHS = {\r\n profile: {\r\n root: 'konto',\r\n login: 'logowanie',\r\n register: 'rejestracja',\r\n remindPassword: 'przypomnij-haslo'\r\n },\r\n businessModules: {\r\n root: 'moduly-biznesowe'\r\n },\r\n eServices: {\r\n root: 'katalog-e-uslug'\r\n },\r\n notFoundPage: {\r\n root: '404'\r\n },\r\n unknownErrorPage: {\r\n root: '500'\r\n },\r\n maintenance: {\r\n root: 'przerwa-techniczna'\r\n },\r\n preview: {\r\n articles: 'articles',\r\n staticPages: 'static-pages'\r\n }\r\n};\r\n","import { InjectionToken } from '@angular/core';\r\n\r\nexport const LAZY_WIDGETS = new InjectionToken<{ [key: string]: string }>('LAZY_WIDGETS');\r\n","export enum MobileEnum {\r\n Large = 992,\r\n Medium = 768,\r\n Small = 576\r\n}\r\n\r\n","export enum PortalVariablesEnum {\r\n MainColor = 'mainColor',\r\n AccentColor = 'accentColor',\r\n ButtonColor = 'buttonColor',\r\n SectionBackgroundColor = 'sectionBackgroundColor'\r\n}\r\n","export enum Bundle {\r\n EServices = 'EServices',\r\n User = 'CmsUser',\r\n Article = 'CmsArticle',\r\n Banner = 'CmsBanner',\r\n BusinessModules = 'CmsBusinessModule',\r\n Settings = 'Setting',\r\n Alert = 'CmsAlert',\r\n Promoted = 'CmsPromoted',\r\n Partners = 'CmsPartners',\r\n Sitemap = 'CmsSitemap',\r\n Breadcrumbs = 'Breadcrumbs',\r\n StaticPages = 'StaticPages',\r\n Preview = 'preview'\r\n}\r\n","import {BootstrapService} from '@app/common/services/bootstrap.service';\r\nimport { LanguageService } from '@share/common/services/language.service';\r\n\r\nexport function getLanguageFactory(language: LanguageService): () => string {\r\n return () => language.getLanguage();\r\n}\r\n\r\nexport function getTranslationsFactory(service: BootstrapService): () => Promise {\r\n return () => service.getTranslations();\r\n}\r\n\r\nexport function getMaintenanceFactory(service: BootstrapService): () => Promise {\r\n return () => service.checkMaintenance();\r\n}\r\n\r\nexport function getSettingsFactory(service: BootstrapService): () => Promise {\r\n return () => service.loadSettings();\r\n}\r\n\r\nexport function getBackendVersionFactory(service: BootstrapService): () => Promise {\r\n return () => service.getBackendVersion();\r\n}\r\n\r\nexport function getFrontendVersionFactory(service: BootstrapService): () => Promise {\r\n return () => service.getFrontendVersion();\r\n}\r\n\r\nexport function getPermissions(service: BootstrapService): () => Promise {\r\n return () => service.getPermissions();\r\n}\r\n","import { OnDestroy, Type } from '@angular/core';\r\nimport { ComponentShareHelper } from '@share/common/helpers/component-share.helper';\r\nimport { FacadeShareService } from '@share/common/services/facade-share.service';\r\nimport { ServiceLocator } from '@share/common/services/locater.service';\r\nimport { FacadeService } from '../services/facade.service';\r\n\r\nexport abstract class ComponentHelper extends ComponentShareHelper implements OnDestroy {\r\n\r\n protected service: FacadeService;\r\n\r\n protected constructor() {\r\n super(ServiceLocator.injector.get(FacadeShareService as Type));\r\n this.service = ServiceLocator.injector.get(FacadeService as Type);\r\n }\r\n}\r\n","import { HttpErrorResponse, HttpEvent, HttpHandler, HttpInterceptor, HttpRequest } from '@angular/common/http';\r\nimport { Injectable } from '@angular/core';\r\nimport { Observable, throwError } from 'rxjs';\r\nimport { ToastrServiceCustom } from '@share/common/services/toastr.service';\r\nimport { Router } from '@angular/router';\r\nimport { ROUTES_PATHS } from '@app/common/constants/routes-paths';\r\nimport { TranslatorService } from '@share/common/services/translator.service';\r\nimport { catchError } from 'rxjs/operators';\r\nimport { ErrorResponse } from '@share/common/models/http.model';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ApiInterceptorService implements HttpInterceptor {\r\n constructor(private toastr: ToastrServiceCustom, private translator: TranslatorService, private router: Router) {}\r\n\r\n private get internalErrorMessage(): string {\r\n return this.translator.trans('global.errors.internalError');\r\n }\r\n\r\n intercept(req: HttpRequest, next: HttpHandler): Observable> {\r\n const headersConfig = {};\r\n const request = req.clone({ setHeaders: headersConfig });\r\n return next.handle(request).pipe(catchError(httpErrorResponse => this.handleError(httpErrorResponse)));\r\n }\r\n\r\n private handleError(httpErrorResponse: any) {\r\n let error: { error: { errors: Array } } = { error: { errors: [] } };\r\n if (httpErrorResponse instanceof HttpErrorResponse) {\r\n this.handleErrorStatus(httpErrorResponse);\r\n const message = this.getMessage(httpErrorResponse);\r\n this.toastr.error(message.title);\r\n error = { error: { errors: [message] } };\r\n }\r\n return throwError(httpErrorResponse);\r\n }\r\n\r\n private getMessage(response: HttpErrorResponse): { title: string; id: string } {\r\n let title: string = '';\r\n try {\r\n const [error] = response.error.errors;\r\n title = error.title;\r\n } catch (e) {\r\n title = this.internalErrorMessage;\r\n }\r\n return { title, id: '' };\r\n }\r\n\r\n private handleErrorStatus(httpErrorResponse: HttpErrorResponse) {\r\n switch (httpErrorResponse.status) {\r\n case 403:\r\n this.handleForbidden();\r\n break;\r\n case 412:\r\n case 0:\r\n this.goToNotFoundPage();\r\n this.router.navigate([ROUTES_PATHS.unknownErrorPage.root]);\r\n break;\r\n }\r\n }\r\n\r\n private handleForbidden() {\r\n if (!this.router.isActive('', false)) {\r\n this.router.navigate(['']);\r\n }\r\n }\r\n\r\n private goToNotFoundPage() {\r\n this.router.navigate([ROUTES_PATHS.unknownErrorPage.root]);\r\n }\r\n}\r\n","import { HttpEvent, HttpHandler, HttpInterceptor, HttpRequest } from '@angular/common/http';\r\nimport { Observable } from 'rxjs';\r\nimport { Injectable } from '@angular/core';\r\n\r\n@Injectable()\r\nexport class ContentInterceptorService implements HttpInterceptor {\r\n intercept(req: HttpRequest, next: HttpHandler): Observable> {\r\n const headersConfig = {\r\n 'Content-Type': 'application/vnd.api+json',\r\n 'Accept': 'application/vnd.api+json',\r\n };\r\n const request = req.clone({setHeaders: headersConfig});\r\n return next.handle(request);\r\n }\r\n}\r\n","import { HttpEvent, HttpHandler, HttpInterceptor, HttpRequest } from '@angular/common/http';\r\nimport { Observable } from 'rxjs';\r\nimport { Injectable } from '@angular/core';\r\n\r\n@Injectable()\r\nexport class InstitutionInterceptorService implements HttpInterceptor {\r\n intercept(req: HttpRequest, next: HttpHandler): Observable> {\r\n const headersConfig = {\r\n 'x-site-url': window.location.origin\r\n };\r\n\r\n const request = req.clone({ setHeaders: headersConfig });\r\n return next.handle(request);\r\n }\r\n}\r\n","export enum ThemesEnum {\r\n ALERT = 'mportal_alert',\r\n ARTICLE = 'mportal_article',\r\n CONSENT = 'mportal_consent',\r\n ESERVICE_CATALOG = 'eservicesCatalog',\r\n MENU = 'mportal_menu',\r\n PROMOTED = 'mportal_promoted',\r\n NETIZEN = 'mportal_netizen',\r\n CORE = 'mportal_core',\r\n EOFFICE = 'eoffice'\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { FormErrors } from '@gkw/shared/common/models/form-errors.model';\r\nimport { HttpErrorResponse } from '@angular/common/http';\r\nimport { ResponseError } from '@share/common/models/http.model';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ApiErrorParserService {\r\n static parse(httpErrorResponse: HttpErrorResponse): FormErrors {\r\n const rawErrors: ResponseError = ApiErrorParserService.getRawErrors(httpErrorResponse);\r\n\r\n const parsedErrors: FormErrors = rawErrors.reduce((previous, current) => {\r\n return {\r\n ...previous,\r\n [current.id ?? current.status]: {\r\n text: current.title\r\n }\r\n };\r\n }, {});\r\n\r\n return parsedErrors;\r\n }\r\n\r\n static getRawErrors(httpErrorResponse: HttpErrorResponse): Array<{ id: string; title: string }> {\r\n try {\r\n return httpErrorResponse.error.errors;\r\n } catch (e) {\r\n throw new Error('Invalid error template');\r\n }\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { RequestOptionsModel } from '@share/common/interfaces/request-options.interface';\r\nimport { AppConfigCMS } from '@share/common/interfaces/app-config.interface';\r\n\r\ndeclare var APP_CONFIG: AppConfigCMS;\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ApiPreprocessorService {\r\n\r\n private readonly URL = `${APP_CONFIG.API_URL}/${APP_CONFIG.PREFIX}`;\r\n\r\n prepareUrl(endpoint: string): string {\r\n if (!endpoint.includes(this.URL)) {\r\n return `${this.URL}/${endpoint}`;\r\n }\r\n\r\n return endpoint;\r\n }\r\n\r\n build(bundle: string, data: object | Array, options: RequestOptionsModel = {}): any {\r\n const request: any = this.createBaseRequest(bundle, data, options);\r\n\r\n if (!!options) {\r\n if (options.jsonapi) {\r\n request.jsonapi = options.jsonapi;\r\n }\r\n if (options.meta) {\r\n request.meta = options.meta;\r\n }\r\n }\r\n\r\n return request;\r\n }\r\n\r\n private createBaseRequest(type: string, data: object | Array, options: RequestOptionsModel): any {\r\n return {\r\n data: Array.isArray(data) ? data : {type: type, attributes: data, id: options.id || '0'},\r\n jsonapi: { // TODO: remove\r\n version: '1.0'\r\n },\r\n meta: {}\r\n };\r\n }\r\n\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { HttpClient, HttpParams } from '@angular/common/http';\r\nimport { Observable, throwError } from 'rxjs';\r\nimport { catchError, first } from 'rxjs/operators';\r\nimport { ResponseArray, ResponseObject } from '@share/common/models/http';\r\nimport { RequestOptionsModel } from '@share/common/interfaces/request-options.interface';\r\nimport { ApiErrorParserService } from '@app/common/services/api-error-parser.service';\r\nimport { ApiPreprocessorService } from '@app/common/services/api-preprocessor.service';\r\nimport { ResponseDefault } from '@share/common/models/http.model';\r\nimport { AppConfigPortal } from '@share/common/interfaces/app-config.interface';\r\n\r\ndeclare var APP_CONFIG: AppConfigPortal;\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ApiService {\r\n private _bundle: string = '';\r\n\r\n constructor(private http: HttpClient, private preprocessor: ApiPreprocessorService) {}\r\n\r\n public setBundle(bundle: string) {\r\n this._bundle = bundle;\r\n }\r\n\r\n get(\r\n endpoint: string,\r\n params: HttpParams = new HttpParams(),\r\n options: RequestOptionsModel = {}\r\n ): Observable> {\r\n return this.http\r\n .get>(this.preprocessor.prepareUrl(endpoint), { params })\r\n .pipe(first());\r\n }\r\n\r\n getAll(\r\n endpoint: string,\r\n params: HttpParams = new HttpParams(),\r\n options: RequestOptionsModel = {}\r\n ): Observable> {\r\n return this.http\r\n .get>(this.preprocessor.prepareUrl(endpoint), { params })\r\n .pipe(first());\r\n }\r\n\r\n post(\r\n endpoint: string,\r\n body: Object = {},\r\n params: HttpParams = new HttpParams(),\r\n options: RequestOptionsModel = {}\r\n ): Observable {\r\n const requestData = this.preprocessor.build(options.bundle || this._bundle, body, options);\r\n return this.http\r\n .post(this.preprocessor.prepareUrl(endpoint), JSON.stringify(requestData), { params })\r\n .pipe(\r\n first(),\r\n catchError(e => throwError(ApiErrorParserService.parse(e)))\r\n );\r\n }\r\n\r\n put(\r\n endpoint: string,\r\n body: Object = {},\r\n options: RequestOptionsModel = {},\r\n params: HttpParams = new HttpParams()\r\n ): Observable {\r\n const requestData = this.preprocessor.build(options.bundle || this._bundle, body, options);\r\n\r\n return this.http\r\n .put(this.preprocessor.prepareUrl(endpoint), JSON.stringify(requestData), { params })\r\n .pipe(\r\n first(),\r\n catchError(e => throwError(ApiErrorParserService.parse(e)))\r\n );\r\n }\r\n\r\n patch(\r\n endpoint: string,\r\n body: Object = {},\r\n options: RequestOptionsModel = {},\r\n params: HttpParams = new HttpParams()\r\n ): Observable {\r\n const requestData = this.preprocessor.build(options.bundle || this._bundle, body, options);\r\n\r\n return this.http\r\n .patch(this.preprocessor.prepareUrl(endpoint), JSON.stringify(requestData), { params })\r\n .pipe(\r\n first(),\r\n catchError(e => throwError(ApiErrorParserService.parse(e)))\r\n );\r\n }\r\n\r\n assets(path: string): Observable {\r\n return this.http.get(`${APP_CONFIG.ASSETS_URL}/${path}`).pipe(first());\r\n }\r\n\r\n delete(endpoint: string): Observable {\r\n return this.http.delete(this.preprocessor.prepareUrl(endpoint)).pipe(first());\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { ROUTES_PATHS } from '@app/common/constants/routes-paths';\r\nimport { ResponseDefault } from '@share/common/models/http.model';\r\nimport { AppService } from '@share/common/services/app.service';\r\nimport { VersionService } from '@share/common/services/version.service';\r\nimport { VariablesCollection } from '@share/common/models/variables.model';\r\nimport { PortalLayoutService } from '@app/common/services/portal-layout.service';\r\nimport { Variable } from '@share/common/interfaces/variables.interface';\r\nimport { first } from 'rxjs/operators';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { AbstractData, ResponseObject } from '@share/common/models/http';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class BootstrapService {\r\n constructor(\r\n private appService: AppService,\r\n private versionService: VersionService,\r\n private portalLayoutService: PortalLayoutService,\r\n private facade: FacadeService\r\n ) {}\r\n\r\n getFrontendVersion(): Promise {\r\n return this.versionService.getFrontendVersion().then(\r\n (version: any) => (this.versionService.frontend = version),\r\n () => {}\r\n );\r\n }\r\n\r\n getBackendVersion(): Promise {\r\n return this.versionService.getBackendVersion().then(\r\n (response: ResponseDefault) => (this.versionService.backend = response.data.id),\r\n () => {}\r\n );\r\n }\r\n\r\n getTranslations(): Promise {\r\n return this.facade.translator.load().then(\r\n (response: ResponseObject) => (this.facade.translator.translations = response.data.attributes),\r\n () => this.onErrorOccur()\r\n );\r\n }\r\n\r\n checkMaintenance(): Promise {\r\n this.facade.maintenance.maintenancePage = ROUTES_PATHS.maintenance.root;\r\n this.facade.maintenance.serverErrorPage = ROUTES_PATHS.notFoundPage.root;\r\n return this.facade.maintenance.check().then(\r\n response => this.facade.maintenance.onSuccess(response),\r\n error => this.facade.maintenance.onError(error)\r\n );\r\n }\r\n\r\n loadSettings(): Promise {\r\n return new Promise(resolve => {\r\n this.facade.settings.load().then(\r\n (response: ResponseObject) => {\r\n this.facade.settings.variables = response.data.attributes;\r\n const layoutData = this.portalLayoutService.prepareData({\r\n ...response.data.attributes.layout,\r\n ...response.data.attributes.site\r\n });\r\n this.portalLayoutService.setLayout(layoutData as Array>);\r\n this.facade.seo.setData(this.facade.settings.variables);\r\n resolve();\r\n },\r\n () => {\r\n this.facade.settings\r\n .loadDefaultVariables()\r\n .pipe(first())\r\n .subscribe(val => {\r\n this.facade.settings.variables = val;\r\n resolve();\r\n });\r\n }\r\n );\r\n });\r\n }\r\n\r\n getPermissions(): Promise {\r\n //this.authService.isAuthenticated\r\n if (!!localStorage.getItem('token')) {\r\n return this.facade.crud.load();\r\n } else {\r\n return new Promise((resolve, reject) => resolve());\r\n }\r\n }\r\n\r\n private onErrorOccur() {\r\n this.appService.setFatalError(true);\r\n this.facade.router.navigate([ROUTES_PATHS.unknownErrorPage.root]);\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { Observable, ReplaySubject, Subject } from 'rxjs';\r\nimport { first, switchMap } from 'rxjs/operators';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\n\r\ndeclare const grecaptcha: any;\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class CaptchaV3Service {\r\n public readonly grecaptcha: Subject = new ReplaySubject();\r\n private scriptElement: HTMLScriptElement;\r\n\r\n constructor(private settingsService: SettingsService) {}\r\n\r\n public load(): void {\r\n if (this.scriptElement) {\r\n return;\r\n }\r\n this.scriptElement = document.createElement('script');\r\n this.scriptElement.src = `https://www.google.com/recaptcha/api.js?render=${this.settingsService.variables.integration.googleReCaptchaSiteKey}`;\r\n this.scriptElement.async = true;\r\n this.scriptElement.addEventListener('load', event => {\r\n grecaptcha.ready(() => {\r\n this.grecaptcha.next(grecaptcha);\r\n });\r\n });\r\n this.scriptElement.addEventListener('error', event => {\r\n this.grecaptcha.next(null);\r\n });\r\n document.getElementsByTagName('head')[0].append(this.scriptElement);\r\n\r\n this.toggleVisibility();\r\n }\r\n\r\n execute(action: string = 'homepage'): Observable {\r\n return this.grecaptcha.pipe(first()).pipe(\r\n switchMap(val => {\r\n if (val === null) {\r\n throw new Error('Google captcha script is not loaded');\r\n }\r\n return val.execute(this.settingsService.variables.integration.googleReCaptchaSiteKey, { action });\r\n })\r\n );\r\n }\r\n\r\n toggleVisibility(show: boolean = true) {\r\n const grecaptcha: HTMLElement | null = document.querySelector('.grecaptcha-badge');\r\n if (grecaptcha) {\r\n grecaptcha.style.display = show ? 'block' : 'none';\r\n }\r\n }\r\n}\r\n","import { Injectable, Injector } from '@angular/core';\r\nimport { FacadeShareService } from '@share/common/services/facade-share.service';\r\nimport { SubheaderService } from '@app/template/layout/modules/header/services/subheader.service';\r\nimport { ScrollToService } from '@app/common/services/scroll-to.service';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class FacadeService extends FacadeShareService {\r\n private _subheader: SubheaderService;\r\n private _scrollTo: ScrollToService;\r\n private _settings: SettingsService;\r\n\r\n constructor(private injector: Injector) {\r\n super(injector);\r\n }\r\n\r\n public get subheader(): SubheaderService {\r\n if (!this._subheader) {\r\n this._subheader = this._injector.get(SubheaderService);\r\n }\r\n return this._subheader;\r\n }\r\n\r\n public get scrollTo(): ScrollToService {\r\n if (!this._scrollTo) {\r\n this._scrollTo = this._injector.get(ScrollToService);\r\n }\r\n return this._scrollTo;\r\n }\r\n\r\n public get settings(): SettingsService {\r\n if (!this._settings) {\r\n this._settings = this._injector.get(SettingsService);\r\n }\r\n return this._settings;\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\n\r\ndeclare var google: any;\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class GoogleTranslateService {\r\n public init() {\r\n // tslint:disable-next-line:no-unused-expression\r\n new google.translate.TranslateElement({\r\n pageLanguage: 'pl',\r\n includedLanguages: 'pl,cs,da,de,en,es,fi,fr,hu,it,ja,no,pt,ru,zh-CN',\r\n layout: google.translate.TranslateElement.InlineLayout.SIMPLE\r\n }, 'google_translate_element');\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { NgbModalOptions } from '@ng-bootstrap/ng-bootstrap';\r\nimport { ServiceHelper } from '@share/common/helpers/service.helper';\r\nimport { ImageZoomComponent } from '@app/template/elements/image-zoom/components/image-zoom/image-zoom.component';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ImageZoomService extends ServiceHelper {\r\n private readonly zoomClass: string = '.image-zoom';\r\n private readonly originalFilterName: string = 'original';\r\n\r\n constructor() {\r\n super('');\r\n }\r\n\r\n public setListener() {\r\n // TODO: it cant find correct dom data, in settimeout works\r\n const images = document.querySelectorAll(this.zoomClass);\r\n for (let i = 0; i < images.length; i++) {\r\n images[i].addEventListener('click', event => this.imagePreview(event.target as HTMLImageElement));\r\n }\r\n }\r\n\r\n public imagePreview(image: HTMLImageElement) {\r\n const src: string = image.src;\r\n const originalSrc: string = this.getOriginalPath(src);\r\n // @ts-ignore\r\n const config: NgbModalOptions = {keyboard: true, backdrop: true, size: 'xl'};\r\n this.modal.openCustomModal(ImageZoomComponent, {original: originalSrc, alt: image.alt}, config);\r\n }\r\n\r\n private getOriginalPath(src: string | null): string {\r\n if (!src) {\r\n return '';\r\n }\r\n let path: string = src.slice(0, src.indexOf('filterName'));\r\n path += `filterName=${this.originalFilterName}`;\r\n return path;\r\n }\r\n}\r\n","import {Injectable} from '@angular/core';\r\nimport {ApiService} from '@app/common/services/api.service';\r\nimport {Observable} from 'rxjs';\r\nimport {ResponseObject} from '@share/common/models/http.model';\r\nimport {Institution} from '@app/common/models/institution.model';\r\nimport {API} from '@app/common/constants/api.directories';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class InstitutionService {\r\n\r\n constructor(private apiService: ApiService) {}\r\n\r\n public getCurrent(): Observable> {\r\n return this.apiService.get(API.INSTITUTION.ROOT);\r\n }\r\n}\r\n","import {\r\n Compiler,\r\n ComponentRef,\r\n Inject,\r\n Injectable,\r\n Injector,\r\n NgModuleFactory,\r\n Type,\r\n ViewContainerRef\r\n} from '@angular/core';\r\nimport { LAZY_WIDGETS } from '@app/common/constants/tokens';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class LazyLoaderService {\r\n constructor(\r\n private injector: Injector,\r\n private compiler: Compiler,\r\n @Inject(LAZY_WIDGETS) private lazyWidgets: { [key: string]: () => Promise | Type> }\r\n ) {}\r\n\r\n async load(name: string, container: ViewContainerRef, component?: any): Promise> {\r\n const ngModuleOrNgModuleFactory = await this.lazyWidgets[name]();\r\n\r\n let moduleFactory;\r\n if (ngModuleOrNgModuleFactory instanceof NgModuleFactory) {\r\n moduleFactory = ngModuleOrNgModuleFactory;\r\n } else {\r\n moduleFactory = await this.compiler.compileModuleAsync(ngModuleOrNgModuleFactory);\r\n }\r\n const entryComponent = component || (moduleFactory.moduleType).entry;\r\n const moduleRef = moduleFactory.create(this.injector);\r\n\r\n const compFactory = moduleRef.componentFactoryResolver.resolveComponentFactory(entryComponent);\r\n\r\n return container.createComponent(compFactory);\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { Observable } from 'rxjs';\r\nimport { Preview } from '@app/client-core/preview/interfaces/preview.interface';\r\nimport { ResponseObject } from '@share/common/models/http';\r\nimport { PageModel } from '@app/common/models/page.model';\r\nimport { ApiService } from '@app/common/services/api.service';\r\nimport { API } from '../constants/api.directories';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class PagesService implements Preview {\r\n constructor(private apiService: ApiService) {}\r\n\r\n getOne(slug: string = ''): Observable>> {\r\n return this.apiService.get(`${API.PAGES.ROOT}${slug ? '/' + slug : ''}`);\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { LayoutService } from '@share/common/services/layout.service';\r\nimport { PortalVariablesEnum } from '@app/common/enums/portal-variables.enum';\r\nimport { PORTAL_VARIABLES_PRESETS } from '@app/common/constants/portal-variables-presets';\r\nimport { HttpClient } from '@angular/common/http';\r\nimport { ImageService } from '@share/common/services/image.service';\r\nimport { AbstractData } from '@share/common/models/http.model';\r\nimport { ObjectString } from '@share/common/interfaces/object-types.interface';\r\nimport { Variable } from '@share/common/interfaces/variables.interface';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class PortalLayoutService extends LayoutService {\r\n\r\n constructor(protected httpClient: HttpClient,\r\n protected imageService: ImageService) {\r\n super(httpClient, imageService);\r\n this.layoutPresets = PORTAL_VARIABLES_PRESETS;\r\n }\r\n\r\n public prepareData(variables: ObjectString): Array>> {\r\n const data: Array>> = [];\r\n for (const variable of Object.keys(variables)) {\r\n data.push({\r\n id: '0',\r\n type: '',\r\n attributes: {\r\n name: variable,\r\n value: variables[variable]\r\n }\r\n });\r\n }\r\n return data;\r\n }\r\n\r\n protected variablesQueue(): Array {\r\n return [\r\n PortalVariablesEnum.AccentColor,\r\n PortalVariablesEnum.ButtonColor,\r\n PortalVariablesEnum.MainColor,\r\n PortalVariablesEnum.SectionBackgroundColor,\r\n ];\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { fromEvent, merge, Observable, of } from 'rxjs';\r\nimport { map, switchMap } from 'rxjs/operators';\r\nimport { MobileEnum } from '@app/common/enums/mobile.enum';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ResizeListener {\r\n get isMobile$(): Observable {\r\n return merge(this.onLoad(), this.onResize()).pipe(\r\n switchMap(value => {\r\n if (!value) {\r\n return this.isMobileDevice();\r\n }\r\n return of(value);\r\n })\r\n );\r\n }\r\n\r\n private onResize(): Observable {\r\n return fromEvent(window, 'resize').pipe(map(() => window.innerWidth < MobileEnum.Large));\r\n }\r\n\r\n private onLoad(): Observable {\r\n return of(window.innerWidth < MobileEnum.Large);\r\n }\r\n private isMobileDevice(): Observable {\r\n return of(/iPhone|iPad|iPod|Android/i.test(navigator.userAgent));\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\n\r\ndeclare var $: Function;\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ScrollToService {\r\n\r\n constructor() {}\r\n\r\n animate(id: string, time: number = 500, scrollDifference: number = 70) {\r\n try {\r\n $('html, body').animate({\r\n scrollTop: ($(id).offset().top as number) - scrollDifference,\r\n }, time);\r\n } catch (ignore) {\r\n }\r\n }\r\n\r\n resetScrollTop() {\r\n window.scrollTo(0, 0);\r\n }\r\n}\r\n\r\n","import { Injectable } from '@angular/core';\r\nimport { API } from '@app/common/constants/api.directories';\r\nimport { ApiService } from '@app/common/services/api.service';\r\nimport { Observable } from 'rxjs';\r\nimport { BootstrapModel } from '@app/common/models/bootstrap.model';\r\nimport { ResponseObject } from '@share/common/models/http';\r\nimport { ThemesEnum } from '@app/common/models/themes.enum';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class SettingsService {\r\n variables: T;\r\n\r\n constructor(private apiService: ApiService) {}\r\n\r\n load(): Promise> {\r\n return this.apiService.get(API.SETTINGS.ROOT).toPromise();\r\n }\r\n\r\n loadDefaultVariables(): Observable {\r\n return this.apiService.assets(API.ASSETS.DEFAULT_SETTINGS);\r\n }\r\n\r\n isModuleActive(theme: ThemesEnum): boolean {\r\n return this.variables.theme.modules.includes(theme);\r\n }\r\n}\r\n","import {Injectable} from '@angular/core';\r\nimport {Location} from '@angular/common';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class UrlService {\r\n constructor(private location: Location) {}\r\n\r\n getParsedUrl(): string {\r\n const path: string = this.location.path();\r\n return path.substr(1, path.length).replace(/\\//g, ',');\r\n }\r\n\r\n getLastUrlElement(): string {\r\n const paths: string[] = this.getParsedUrl().split(',');\r\n return paths[paths.length - 1];\r\n }\r\n}\r\n","import { CommonModule } from '@angular/common';\r\nimport { NgModule } from '@angular/core';\r\nimport { AccordionComponent } from './component/accordion/accordion.component';\r\nimport { AccPanelTitleDirective, AccPanelContentDirective, AccPanelDirective } from './directives/accordion-panel.directive';\r\n\r\n@NgModule({\r\n imports: [CommonModule],\r\n exports: [\r\n AccordionComponent,\r\n AccPanelTitleDirective,\r\n AccPanelContentDirective,\r\n AccPanelDirective\r\n ],\r\n declarations: [\r\n AccordionComponent,\r\n AccPanelTitleDirective,\r\n AccPanelContentDirective,\r\n AccPanelDirective\r\n ]\r\n})\r\nexport class AccordionModule {}\r\n","import { AfterContentChecked, Component, ContentChildren, EventEmitter, Input, Output, QueryList, ViewEncapsulation } from '@angular/core';\r\nimport { AccPanelChangeEvent } from '../../interfaces/accordion-panel-change-event.model';\r\nimport { AccPanelDirective } from '../../directives/accordion-panel.directive';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\n\r\n@Component({\r\n selector: 'app-accordion',\r\n templateUrl: './accordion.component.html',\r\n styleUrls: ['./accordion.component.scss']\r\n})\r\nexport class AccordionComponent extends ComponentHelper implements AfterContentChecked {\r\n @ContentChildren(AccPanelDirective) panels: QueryList;\r\n @Input() activeIds: string[] = [];\r\n @Output() readonly panelChange = new EventEmitter();\r\n\r\n constructor() {\r\n super();\r\n }\r\n\r\n private _findPanelById(panelId: string): AccPanelDirective | undefined {\r\n return this.panels.find(p => p.id === panelId);\r\n }\r\n\r\n\r\n private _updateActiveIds() {\r\n this.activeIds = this.panels.filter(panel => panel.isOpen && !panel.disabled).map(panel => panel.id);\r\n }\r\n\r\n private _changeOpenState(panel: AccPanelDirective, nextState: boolean, target: EventTarget) {\r\n if (panel && !panel.disabled && panel.isOpen !== nextState) {\r\n let defaultPrevented = false;\r\n\r\n this.panelChange.emit({\r\n panelId: panel.id,\r\n nextState: nextState,\r\n target,\r\n prevent: () => { defaultPrevented = true; }\r\n });\r\n\r\n if (!defaultPrevented) {\r\n panel.isOpen = nextState;\r\n\r\n this._updateActiveIds();\r\n }\r\n }\r\n }\r\n\r\n toggle(panelId: string, target: EventTarget) {\r\n const panel = this._findPanelById(panelId);\r\n if (panel) {\r\n this._changeOpenState(panel, !panel.isOpen, target);\r\n }\r\n }\r\n\r\n isPanelActive(panelId: string): boolean {\r\n return this.activeIds && this.activeIds.indexOf(panelId) !== -1;\r\n }\r\n\r\n expandAll() {\r\n this.panels.forEach(panel => {\r\n if (this.activeIds.indexOf(panel.id) === -1) {\r\n this.activeIds.push(panel.id);\r\n }\r\n });\r\n }\r\n\r\n ngAfterContentChecked() {\r\n this.panels.forEach(panel => panel.isOpen = !panel.disabled && this.activeIds.indexOf(panel.id) > -1);\r\n }\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { AfterContentChecked, ContentChildren, Directive, Input, QueryList, TemplateRef } from '@angular/core';\r\n\r\n@Directive({selector: 'ng-template[appAccPanelTitle]'})\r\nexport class AccPanelTitleDirective {\r\n constructor(public templateRef: TemplateRef) {}\r\n}\r\n\r\n@Directive({selector: 'ng-template[appAccPanelContent]'})\r\nexport class AccPanelContentDirective {\r\n constructor(public templateRef: TemplateRef) {}\r\n}\r\n\r\n@Directive({selector: '[appAccPanel]'})\r\nexport class AccPanelDirective implements AfterContentChecked {\r\n\r\n @Input() disabled = false;\r\n @Input() id: string;\r\n @Input() title: string;\r\n @Input() type: string;\r\n @Input() isOpen = false;\r\n\r\n @ContentChildren(AccPanelTitleDirective, {descendants: false}) titleTpls: QueryList;\r\n @ContentChildren(AccPanelContentDirective, {descendants: false}) contentTpls: QueryList;\r\n\r\n titleTpl: AccPanelTitleDirective | null;\r\n contentTpl: AccPanelContentDirective | null;\r\n\r\n constructor() { }\r\n\r\n ngAfterContentChecked() {\r\n this.titleTpl = this.titleTpls.first;\r\n this.contentTpl = this.contentTpls.first;\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { MultiCarouselComponent } from './components/multi-carousel/multi-carousel.component';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { PolygonModule } from '@app/template/elements/polygon/polygon.module';\r\n\r\n@NgModule({\r\n declarations: [\r\n MultiCarouselComponent\r\n ],\r\n imports: [\r\n CommonModule,\r\n TranslatorModule,\r\n PolygonModule\r\n ],\r\n exports: [\r\n MultiCarouselComponent\r\n ]\r\n})\r\nexport class CarouselModule {}\r\n","import { AfterViewChecked, Component, ElementRef, Input } from '@angular/core';\r\nimport { MultiCarousel } from '../../models/multi-carousel.model';\r\nimport { MultiCarouselConfig } from '../../models/multi-carousel-config.model';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { AbstractData } from '@share/common/models/http';\r\n\r\ndeclare var $: Function;\r\n\r\n@Component({\r\n selector: 'app-multi-carousel',\r\n templateUrl: './multi-carousel.component.html',\r\n styleUrls: [\r\n './multi-carousel.component.scss'\r\n ]\r\n})\r\nexport class MultiCarouselComponent extends ComponentHelper implements AfterViewChecked {\r\n @Input() data: Array> = [];\r\n\r\n @Input()\r\n set config(config: MultiCarouselConfig) {\r\n this._config = Object.assign(this._config, config);\r\n }\r\n\r\n private _config: MultiCarouselConfig = {\r\n dots: true,\r\n nav: true,\r\n itemsOnScreen: {\r\n 0: {\r\n items: 2\r\n },\r\n 600: {\r\n items: 3\r\n },\r\n 1000: {\r\n items: 4\r\n }\r\n },\r\n autoplayHoverPause: false,\r\n autoplay: false,\r\n autoplayTimeout: 5000,\r\n loop: false\r\n };\r\n\r\n get config() {\r\n return this._config;\r\n }\r\n\r\n private isCarouselInit = false;\r\n\r\n constructor(private elementRef: ElementRef) {\r\n super();\r\n }\r\n\r\n public initCarousel(): void {\r\n const owl = $('.owl-carousel').owlCarousel({\r\n margin: 0,\r\n responsive: this.config.itemsOnScreen,\r\n dots: this.config.dots,\r\n nav: this.config.nav,\r\n dotsContainer: '#owl-carousel-custom-dots',\r\n navContainer: '#owl-carousel-custom-nav',\r\n navText: [\r\n ``,\r\n ``\r\n ],\r\n autoplay: this.config.autoplay,\r\n autoplayTimeout: this.config.autoplayTimeout,\r\n autoplayHoverPause: this.config.autoplayHoverPause,\r\n loop: this.config.loop\r\n });\r\n $('.owl-dots').on('click', 'li', function (e: any) {\r\n // @ts-ignore\r\n owl.trigger('to.owl.carousel', [$(this).index(), 300]);\r\n });\r\n }\r\n\r\n\r\n private setAriaLabels() {\r\n const dots = this.elementRef.nativeElement.querySelectorAll('.owl-dot');\r\n dots.forEach((dot: HTMLButtonElement, index: number) => {\r\n dot.setAttribute('aria-label', this.trans('global.goToPage') + (index + 1));\r\n });\r\n }\r\n\r\n getLink(url: string): string {\r\n return url?.length > 3 && url.substr(0, 3) === 'www' ? `//${url}` : url\r\n }\r\n\r\n ngAfterViewChecked() {\r\n const carousel = $('.owl-carousel');\r\n if (carousel.length > 0 && !this.isCarouselInit) {\r\n setTimeout(() => {\r\n this.initCarousel();\r\n this.setAriaLabels();\r\n });\r\n this.isCarouselInit = true;\r\n }\r\n }\r\n}\r\n","\r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n\r\n\r\n","import {Component, Input} from '@angular/core';\r\n\r\n@Component({\r\n selector: 'shared-heading-section',\r\n templateUrl: './heading-section.component.html',\r\n styleUrls: ['./heading-section.component.scss']\r\n})\r\nexport class HeadingSectionComponent {\r\n @Input() number: number = 0;\r\n @Input() subtitle: string = '';\r\n @Input() title: string;\r\n @Input() innerColor: boolean = false;\r\n @Input() hsClass: string;\r\n\r\n}\r\n","\r\n \r\n {{ title }}\r\n \r\n - {{subtitle}}\r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { HeadingSectionComponent } from './components/heading-section/heading-section.component';\r\nimport {PolygonModule} from '@app/template/elements/polygon/polygon.module';\r\n\r\n@NgModule({\r\n declarations: [\r\n HeadingSectionComponent\r\n ],\r\n exports: [\r\n HeadingSectionComponent\r\n ],\r\n imports: [\r\n CommonModule,\r\n PolygonModule\r\n ]\r\n})\r\nexport class HeadingModule { }\r\n","import { Component, Input } from '@angular/core';\r\nimport { NgbActiveModal } from '@ng-bootstrap/ng-bootstrap';\r\nimport { ImageZoom } from '@app/template/elements/image-zoom/interfaces/image-zoom.interface';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\n\r\n@Component({\r\n selector: 'app-image-zoom',\r\n templateUrl: './image-zoom.component.html'\r\n})\r\nexport class ImageZoomComponent extends ComponentHelper {\r\n @Input() public data: ImageZoom;\r\n public loading: boolean = true;\r\n public placeholder: boolean = false;\r\n\r\n constructor(private activeModal: NgbActiveModal) {\r\n super();\r\n }\r\n\r\n public close() {\r\n this.activeModal.close();\r\n }\r\n\r\n public onLoad() {\r\n this.loading = false;\r\n }\r\n\r\n public onError() {\r\n this.onLoad();\r\n this.placeholder = true;\r\n }\r\n}\r\n","\r\n {{data.alt}}\r\n \r\n {{'x'}}\r\n \r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { ImageZoomComponent } from '@app/template/elements/image-zoom/components/image-zoom/image-zoom.component';\r\nimport { ProgressBarModule } from '@share/modules/progress-bar/progress-bar.module';\r\nimport { CommonModule } from '@angular/common';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n ProgressBarModule\r\n ],\r\n declarations: [\r\n ImageZoomComponent\r\n ],\r\n exports: [\r\n ImageZoomComponent\r\n ],\r\n entryComponents: [\r\n ImageZoomComponent\r\n ]\r\n})\r\nexport class ImageZoomModule {}\r\n","import { Component, Input } from '@angular/core';\r\nimport { ControlValueAccessor, NgControl } from '@angular/forms';\r\n\r\n@Component({\r\n selector: 'app-input',\r\n templateUrl: 'input.component.html',\r\n styleUrls: ['input.component.scss']\r\n})\r\nexport class InputComponent implements ControlValueAccessor {\r\n\r\n @Input() label: string;\r\n @Input() id: string;\r\n\r\n private onChange: (v: string) => void = (v: string) => {};\r\n private onTouch: () => void = () => {};\r\n\r\n value: string;\r\n\r\n constructor(private ngControl: NgControl) {\r\n this.ngControl.valueAccessor = this;\r\n }\r\n\r\n registerOnChange(fn: any): void {\r\n this.onChange = fn;\r\n }\r\n\r\n registerOnTouched(fn: any): void {\r\n this.onTouch = fn;\r\n }\r\n\r\n writeValue(obj: any): void {\r\n this.value = obj;\r\n this.onChange(obj);\r\n }\r\n}\r\n","\r\n \r\n {{ label }}\r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { InputComponent } from '@app/template/elements/input/input.component';\r\nimport { FormsModule } from '@angular/forms';\r\n\r\n@NgModule({\r\n declarations: [InputComponent],\r\n exports: [InputComponent],\r\n imports: [CommonModule, FormsModule]\r\n})\r\nexport class InputModule {}\r\n","import { Component, EventEmitter, Input, Output } from '@angular/core';\r\nimport { PaginationService } from '../../services/pagination.service';\r\n\r\n@Component({\r\n selector: 'shared-pagination',\r\n templateUrl: './pagination.component.html',\r\n styleUrls: ['./pagination.component.scss'],\r\n})\r\nexport class PaginationComponent {\r\n\r\n @Input() public perPage: number = 10;\r\n @Input() public pages: number = 1;\r\n @Input() public position: 'left' | 'right' = 'right';\r\n @Output() readonly changed: EventEmitter = new EventEmitter();\r\n\r\n constructor(private paginationService: PaginationService) {}\r\n\r\n\r\n public get total(): number {\r\n return this.perPage * this.pages;\r\n }\r\n\r\n public set currentPage(value: number) {\r\n this.paginationService.page = value;\r\n this.changed.emit(value);\r\n }\r\n\r\n public get currentPage(): number {\r\n return this.paginationService.page;\r\n }\r\n\r\n\r\n}\r\n"," 1\">\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n {{'...'}}\r\n {{ currentPage }}\r\n \r\n \r\n \r\n\r\n","import {NgModule} from '@angular/core';\r\nimport {CommonModule} from '@angular/common';\r\nimport {PaginationComponent} from './components/pagination/pagination.component';\r\nimport {NgbPaginationModule} from '@ng-bootstrap/ng-bootstrap';\r\nimport {PaginationService} from './services/pagination.service';\r\n\r\n@NgModule({\r\n declarations: [\r\n PaginationComponent\r\n ],\r\n imports: [\r\n CommonModule,\r\n NgbPaginationModule\r\n ],\r\n exports: [\r\n PaginationComponent\r\n ],\r\n providers: [\r\n PaginationService\r\n ]\r\n})\r\nexport class PaginationModule {}\r\n","import { Injectable } from '@angular/core';\r\nimport { BehaviorSubject, Observable, Subscription } from 'rxjs';\r\nimport { ComponentShareHelper } from '@share/common/helpers/component-share.helper';\r\nimport { FacadeShareService } from '@share/common/services/facade-share.service';\r\nimport { ActivatedRoute, Params } from '@angular/router';\r\n\r\n@Injectable()\r\nexport class PaginationService extends ComponentShareHelper {\r\n private firstPage: number = 1;\r\n private _page: BehaviorSubject = new BehaviorSubject(this.firstPage);\r\n\r\n constructor(private facadeShareService: FacadeShareService,\r\n private activatedRoute: ActivatedRoute) {\r\n super(facadeShareService);\r\n this.setParamsListener();\r\n }\r\n\r\n public setParamsListener() {\r\n return this.activatedRoute.queryParams.subscribe((params: Params) => {\r\n if (params.page) {\r\n this.page = parseInt(params.page, 10);\r\n } else {\r\n this._page.next(this.firstPage);\r\n }\r\n });\r\n }\r\n\r\n private changeQueryParams(value: number) {\r\n setTimeout(() => {\r\n this.facadeShareService.router.navigate([], {\r\n relativeTo: this.activatedRoute,\r\n queryParams: {page: value === this.firstPage ? null : value}\r\n });\r\n });\r\n }\r\n\r\n public set page(value: number) {\r\n if (value !== this.page) {\r\n this._page.next(value);\r\n this.changeQueryParams(value);\r\n }\r\n }\r\n\r\n public get page(): number {\r\n return this._page.getValue();\r\n }\r\n\r\n public get currentPage(): Observable {\r\n return this._page.asObservable();\r\n }\r\n}\r\n","import { Component, Input } from '@angular/core';\r\nimport { UtilsService } from '@share/common/services/utils.service';\r\n\r\n@Component({\r\n selector: 'shared-hexagon-content',\r\n templateUrl: './hexagon-content.component.html',\r\n styleUrls: ['./hexagon-content.component.scss']\r\n})\r\nexport class HexagonContentComponent {\r\n @Input() bgColor: string;\r\n @Input() borderColor: string;\r\n @Input() borderWidth: number = 0;\r\n @Input() width: number = 100;\r\n @Input() height: number = 100;\r\n @Input() isInnerShadow: boolean = false;\r\n @Input() innerShadowConfig: { alpha: number, blur: number } = {alpha: 0.3, blur: 2};\r\n @Input() isOuterShadow: boolean = false;\r\n @Input() isHover: boolean = false;\r\n @Input() bgGradient: boolean = false;\r\n @Input() borderGradient: boolean = false;\r\n @Input() edgeRounded: boolean = false;\r\n @Input() bgImage: string = '';\r\n\r\n public innerShadowID: string = '';\r\n\r\n constructor(private utils: UtilsService) {\r\n this.innerShadowID = this.utils.makeId();\r\n }\r\n\r\n public get location() {\r\n return window.location.href;\r\n }\r\n\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport {HexagonContentComponent} from './components/hexagon-content/hexagon-content.component';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule\r\n ],\r\n declarations: [\r\n HexagonContentComponent\r\n ],\r\n exports: [\r\n HexagonContentComponent\r\n ]\r\n})\r\nexport class PolygonModule {\r\n}\r\n","import { Component, Input, ViewEncapsulation } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'app-promoted-item-icon',\r\n styleUrls: ['promoted-item-icon.component.scss'],\r\n templateUrl: 'promoted-item-icon.component.html',\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class PromotedItemIconComponent {\r\n\r\n @Input() icon: string;\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n\r\n","import { Component, ElementRef, EventEmitter, Input, OnDestroy, Output, Renderer2 } from '@angular/core';\r\nimport { Promoted } from '../../models/promoted.model';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { AbstractData } from '@share/common/models/http';\r\n\r\n@Component({\r\n selector: 'app-promoted-list',\r\n templateUrl: './promoted-list.component.html',\r\n styleUrls: [`./promoted-list.component.scss`]\r\n})\r\nexport class PromotedListComponent extends ComponentHelper implements OnDestroy {\r\n @Input() data: Array>;\r\n\r\n @Input() filter: string;\r\n @Input() height: number = 420;\r\n @Input() background?: string = '';\r\n @Input() hasIcon: boolean = false;\r\n @Output() readonly clicked: EventEmitter = new EventEmitter();\r\n private listenClickFunc: Function;\r\n\r\n constructor(private renderer: Renderer2, private _elementRef: ElementRef) {\r\n super();\r\n this.onClickListener();\r\n }\r\n\r\n private onClickListener(): void {\r\n this.listenClickFunc = this.renderer.listen(this._elementRef.nativeElement, 'click', event =>\r\n this.shareService.utils.navigateTo(event)\r\n );\r\n }\r\n\r\n public imagePath(path: string) {\r\n return this.shareService.image.img({ file: path, filter: this.filter });\r\n }\r\n\r\n public navigateTo(event: Event, url: string, id: string) {\r\n event.preventDefault();\r\n event.stopPropagation();\r\n window.open(url);\r\n this.onClick(id);\r\n }\r\n\r\n public onClick(slug: string) {\r\n this.clicked.emit(slug);\r\n }\r\n\r\n public ngOnDestroy() {\r\n this.listenClickFunc();\r\n }\r\n\r\n public get dataExists(): boolean {\r\n return Array.isArray(this.data) && this.data.length > 0;\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n {{ promoted.attributes.title | truncate: 50 }}\r\n \r\n {{'global.findOutMore' | trans}}\r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { PolygonModule } from '../polygon/polygon.module';\r\nimport { PromotedListComponent } from './components/promoted-list/promoted-list.component';\r\nimport { CommonModule } from '@angular/common';\r\nimport { RouterModule } from '@angular/router';\r\nimport { TruncateModule } from '@share/modules/truncate/truncate.module';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { PromotedItemIconComponent } from './components/promoted-item-icon/promoted-item-icon.component';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\n\r\n@NgModule({\r\n declarations: [\r\n PromotedListComponent,\r\n PromotedItemIconComponent\r\n ],\r\n imports: [\r\n CommonModule,\r\n RouterModule,\r\n PolygonModule,\r\n TruncateModule,\r\n ElementsModule,\r\n TranslatorModule\r\n ],\r\n exports: [\r\n PromotedListComponent\r\n ]\r\n})\r\nexport class PromotedModule {\r\n}\r\n","import { ChangeDetectionStrategy, Component, OnInit } from '@angular/core';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { PagesService } from '@app/common/services/pages.service';\r\nimport { first } from 'rxjs/operators';\r\n\r\n@Component({\r\n selector: 'app-simple-box',\r\n styleUrls: ['simple-box.component.scss'],\r\n templateUrl: 'simple-box.component.html',\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class SimpleBoxComponent implements OnInit {\r\n data: {\r\n button: string;\r\n contactBoxIcon: string;\r\n contactPage: string;\r\n content: string;\r\n title: string;\r\n };\r\n\r\n constructor(private facadeService: FacadeService, private pageService: PagesService) {}\r\n\r\n ngOnInit() {\r\n this.data = this.facadeService.settings.variables.contactBox;\r\n }\r\n\r\n onButtonClick() {\r\n this.pageService\r\n .getOne(this.data.contactPage)\r\n .pipe(first())\r\n .subscribe(page => this.facadeService.router.navigate([page.data.id.replace(',', '/')]));\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n\r\n {{ data.title }}\r\n {{ data.content }}\r\n \r\n\r\n \r\n\r\n \r\n\r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { SimpleBoxComponent } from '@app/template/elements/simple-box/components/simple-box.component';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { CommonModule } from '@angular/common';\r\n\r\n@NgModule({\r\n declarations: [SimpleBoxComponent],\r\n imports: [\r\n ElementsModule,\r\n CommonModule\r\n ],\r\n exports: [SimpleBoxComponent]\r\n})\r\nexport class SimpleBoxModule {\r\n\r\n}\r\n","import { Component, Input } from '@angular/core';\r\nimport { ControlValueAccessor, NgControl } from '@angular/forms';\r\n\r\n@Component({\r\n selector: 'app-textarea',\r\n templateUrl: 'textarea.component.html',\r\n styleUrls: ['textarea.component.scss']\r\n})\r\nexport class TextareaComponent implements ControlValueAccessor {\r\n\r\n @Input() label: string;\r\n @Input() id: string;\r\n\r\n private onChange: (v: string) => void = (v: string) => {};\r\n private onTouch: () => void = () => {};\r\n\r\n value: string;\r\n\r\n constructor(private ngControl: NgControl) {\r\n this.ngControl.valueAccessor = this;\r\n }\r\n\r\n registerOnChange(fn: any): void {\r\n this.onChange = fn;\r\n }\r\n\r\n registerOnTouched(fn: any): void {\r\n this.onTouch = fn;\r\n }\r\n\r\n writeValue(obj: any): void {\r\n this.value = obj;\r\n this.onChange(obj);\r\n }\r\n}\r\n","\r\n \r\n {{ label }}\r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { TextareaComponent } from './textarea.component';\r\nimport { CommonModule } from '@angular/common';\r\nimport { FormsModule } from '@angular/forms';\r\n\r\n@NgModule({\r\n imports: [CommonModule, FormsModule],\r\n declarations: [TextareaComponent],\r\n exports: [TextareaComponent]\r\n})\r\nexport class TextareaModule {}\r\n","import { ChangeDetectionStrategy, Component, Input } from '@angular/core';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { MultiCarousel } from '@app/template/elements/carousel/models/multi-carousel.model';\r\nimport { MultiCarouselConfig } from '@app/template/elements/carousel/models/multi-carousel-config.model';\r\nimport { ImageCropper } from '@app/template/home/models/image-cropper.model';\r\n\r\n@Component({\r\n selector: 'app-gallery',\r\n templateUrl: 'gallery.component.html',\r\n styleUrls: ['gallery.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class GalleryComponent {\r\n config: MultiCarouselConfig = {\r\n dots: false,\r\n nav: true,\r\n itemsOnScreen: {\r\n 0: {\r\n items: 2\r\n },\r\n 700: {\r\n items: 2\r\n },\r\n 800: {\r\n items: 2\r\n },\r\n 1140: {\r\n items: 3\r\n },\r\n 1370: {\r\n items: 4\r\n }\r\n },\r\n autoplayHoverPause: false,\r\n autoplay: false,\r\n autoplayTimeout: 5000,\r\n loop: false\r\n };\r\n\r\n @Input() set data(value: { gallery: AbstractData<{ image: ImageCropper; alt: string }>[] }) {\r\n if (value) {\r\n this.parsedData = value.gallery.map(item => ({\r\n id: item.id,\r\n type: item.type,\r\n attributes: {\r\n file: item.attributes.image.url || (item.attributes.image.croppedUrl as string),\r\n description: item.attributes.alt,\r\n url: '',\r\n isOpenInNewWindow: false\r\n }\r\n }));\r\n }\r\n }\r\n parsedData: Array> = [];\r\n}\r\n","\r\n \r\n \r\n \r\n\r\n\r\n\r\n Galeria\r\n \r\n\r\n\r\n\r\n \r\n \r\n \r\n\r\n","import { ChangeDetectionStrategy, Component, Input } from '@angular/core';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { HomeIntroModel } from '@app/template/home/models/home-intro.model';\r\n\r\n@Component({\r\n selector: 'app-main-banner',\r\n templateUrl: 'main-banner.component.html',\r\n styleUrls: ['main-banner.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class MainBannerComponent {\r\n\r\n @Input() data: HomeIntroModel;\r\n\r\n constructor(private facadeService: FacadeService) {\r\n }\r\n\r\n scrollDown() {\r\n this.facadeService.scrollTo.animate('#promoted', 800, 100);\r\n }\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { ChangeDetectionStrategy, ChangeDetectorRef, Component, Input, OnChanges, SimpleChanges } from '@angular/core';\r\nimport { ArticlesService } from '@app/client-core/article/services/articles.service';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { Article } from '@app/client-core/article/models/article.model';\r\nimport { finalize, first, switchMap } from 'rxjs/operators';\r\nimport { Router } from '@angular/router';\r\nimport { PagesService } from '@app/common/services/pages.service';\r\nimport { DynamicContentService } from '@app/client-core/dynamic-content/service/dynamic-content.service';\r\n\r\n@Component({\r\n selector: 'app-news',\r\n styleUrls: ['news.component.scss'],\r\n templateUrl: 'news.component.html',\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class NewsComponent implements OnChanges {\r\n news: AbstractData[];\r\n loading: boolean;\r\n getError: boolean;\r\n\r\n @Input() data: {\r\n title: string;\r\n subtitle: string;\r\n category: string;\r\n };\r\n\r\n constructor(\r\n private articleService: ArticlesService,\r\n private cdr: ChangeDetectorRef,\r\n private pageService: PagesService,\r\n private router: Router,\r\n private dynamicContentService: DynamicContentService\r\n ) {}\r\n\r\n ngOnChanges(changes: SimpleChanges): void {\r\n if (changes.data.currentValue) {\r\n this.getNews();\r\n }\r\n }\r\n\r\n setLoader(value: boolean) {\r\n this.loading = value;\r\n this.cdr.detectChanges();\r\n }\r\n\r\n test() {\r\n this.pageService.getOne();\r\n }\r\n\r\n getNews() {\r\n this.setLoader(true);\r\n this.pageService\r\n .getOne(this.data.category)\r\n .pipe(\r\n first(),\r\n finalize(() => this.setLoader(false))\r\n )\r\n .subscribe(\r\n response => this.getMetadata(response.data.id),\r\n error => (this.getError = true)\r\n );\r\n }\r\n\r\n getMetadata(url: string) {\r\n this.dynamicContentService\r\n .getPageMetadata(url)\r\n .pipe(switchMap(metadata => this.articleService.getList(1, 4, metadata.meta?.objectId)))\r\n .subscribe(news => {\r\n this.news = news.data;\r\n this.cdr.detectChanges();\r\n });\r\n }\r\n\r\n showMoreClicked() {\r\n this.router.navigate(['aktualnosci']);\r\n }\r\n\r\n readMoreClicked(item: AbstractData) {\r\n this.router.navigate(['aktualnosci', item.attributes.slug]);\r\n }\r\n}\r\n","\r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n\r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n\r\n \r\n {{\r\n category.attributes.title\r\n }}\r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n {{ item.attributes.title }}\r\n \r\n \r\n {{ item.attributes.publishedFrom | date: 'shortDate':'':'pl' }}\r\n \r\n \r\n {{ item.attributes.description }}\r\n \r\n \r\n \r\n \r\n\r\n","import {\r\n AfterViewInit,\r\n ChangeDetectionStrategy,\r\n ChangeDetectorRef,\r\n Component,\r\n Input,\r\n OnInit,\r\n ViewChild,\r\n ViewContainerRef\r\n} from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { LazyLoaderService } from '@app/common/services/lazy-loader.service';\r\nimport { ROUTES_PATHS } from '@app/common/constants/routes-paths';\r\nimport { Router } from '@angular/router';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { finalize, first } from 'rxjs/operators';\r\nimport { HomeService } from '@app/template/home/services/home.service';\r\nimport { PagesService } from '@app/common/services/pages.service';\r\nimport { PageModel } from '@app/common/models/page.model';\r\nimport { HomeModel } from '@app/template/home/models/home.model';\r\n\r\n@Component({\r\n selector: 'app-home',\r\n templateUrl: './overlay.component.html',\r\n styleUrls: ['./overlay.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class OverlayComponent extends ComponentHelper implements OnInit, AfterViewInit {\r\n @ViewChild('businessModules', { read: ViewContainerRef }) businessModules: ViewContainerRef;\r\n @Input() data: AbstractData>;\r\n loading: boolean = true;\r\n\r\n constructor(\r\n private settingsService: SettingsService,\r\n private lazyLoaderService: LazyLoaderService,\r\n private pagesService: PagesService,\r\n private router: Router,\r\n private cdr: ChangeDetectorRef,\r\n private homeService: HomeService\r\n ) {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n this.service.scrollTo.resetScrollTop();\r\n }\r\n\r\n private setLoading(value: boolean) {\r\n this.loading = value;\r\n this.cdr.markForCheck();\r\n }\r\n\r\n getMainPage() {\r\n this.setLoading(true);\r\n this.pagesService\r\n .getOne()\r\n .pipe(\r\n first(),\r\n finalize(() => this.setLoading(false))\r\n )\r\n .subscribe(\r\n response => {\r\n this.data = response.data;\r\n },\r\n () => {\r\n this.router.navigate(['/', ROUTES_PATHS.notFoundPage.root]);\r\n }\r\n );\r\n }\r\n\r\n ngAfterViewInit() {\r\n if (!this.data) {\r\n this.getMainPage();\r\n } else {\r\n this.loading = false;\r\n this.homeService.isHomePreview = true;\r\n }\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n\r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { ChangeDetectionStrategy, ChangeDetectorRef, Component, Input, OnInit } from '@angular/core';\r\nimport { PromotedService } from '@app/template/home/services/promoted.service';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { Promoted } from '@app/template/elements/promoted/models/promoted.model';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { finalize, first } from 'rxjs/operators';\r\n\r\n@Component({\r\n selector: 'app-promoted',\r\n templateUrl: './promoted.component.html',\r\n styleUrls: ['./promoted.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class PromotedComponent extends ComponentHelper implements OnInit {\r\n @Input() data: { title: string; subtitle: string };\r\n promoted: Array> = [];\r\n loading: boolean = false;\r\n\r\n constructor(private promotedService: PromotedService, private cdr: ChangeDetectorRef) {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n this.loadPromoted();\r\n }\r\n\r\n loadPromoted() {\r\n this.setLoading(true);\r\n this.promotedService\r\n .getList()\r\n .pipe(\r\n first(),\r\n finalize(() => this.setLoading(false))\r\n )\r\n .subscribe(\r\n response => (this.promoted = this.getResponseData(response)),\r\n () => this.setComponentError()\r\n );\r\n }\r\n\r\n private setLoading(value: boolean) {\r\n this.loading = value;\r\n this.cdr.markForCheck();\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { ChangeDetectionStrategy, Component, Input } from '@angular/core';\r\nimport { HomeReportCrashModel } from '@app/template/home/models/home-report-crash.model';\r\n\r\n@Component({\r\n selector: 'app-report-crash',\r\n templateUrl: 'report-crash.component.html',\r\n styleUrls: ['report-crash.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class ReportCrashComponent {\r\n @Input() data: HomeReportCrashModel;\r\n}\r\n","\r\n \r\n \r\n \r\n {{ data?.title }}\r\n {{ data?.content }}\r\n \r\n \r\n \r\n \r\n \r\n {{ data?.contactOne?.title }}\r\n \r\n \r\n {{ data?.contactOne.phone }}\r\n \r\n \r\n \r\n {{ data?.contactOne.officeHours }}\r\n \r\n \r\n \r\n {{ data?.contactTwo?.title }}\r\n \r\n \r\n \r\n {{ data?.contactTwo?.phone }}\r\n \r\n \r\n \r\n \r\n {{ data?.contactTwo?.officeHours }}\r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { ChangeDetectionStrategy, ChangeDetectorRef, Component, Input, OnChanges, SimpleChanges } from '@angular/core';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { PagesService } from '@app/common/services/pages.service';\r\nimport { finalize, first } from 'rxjs/operators';\r\nimport { Router } from '@angular/router';\r\n\r\n@Component({\r\n selector: 'app-schedule',\r\n templateUrl: 'schedule.component.html',\r\n styleUrls: ['schedule.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class ScheduleComponent implements OnChanges {\r\n @Input() data: {\r\n title: string;\r\n subtitle: string;\r\n pageId: string;\r\n };\r\n\r\n scheduleElements: {\r\n boxTitle: string;\r\n boxSubtitle: string;\r\n boxPhone: string;\r\n schedule: { cities: string; date: string }[];\r\n };\r\n\r\n url: string;\r\n\r\n constructor(private pageService: PagesService, private cdr: ChangeDetectorRef, private router: Router) {}\r\n\r\n ngOnChanges(changes: SimpleChanges): void {\r\n if (changes.data.currentValue.pageId) {\r\n this.pageService\r\n .getOne(changes.data.currentValue.pageId)\r\n .pipe(\r\n first(),\r\n finalize(() => this.cdr.detectChanges())\r\n )\r\n .subscribe(e => {\r\n this.url = e.data.id.replace(',', '/');\r\n this.scheduleElements = e.data.attributes.content.content;\r\n this.scheduleElements.schedule = this.scheduleElements.schedule.filter(\r\n (item: any, index: number) => index < 4\r\n );\r\n });\r\n }\r\n }\r\n\r\n redirectToMore() {\r\n this.router.navigate([this.url]);\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n\r\n\r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n\r\n\r\n \r\n \r\n \r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n {{ title }}\r\n \r\n \r\n {{ text }}\r\n \r\n \r\n \r\n {{ phone }}\r\n \r\n \r\n\r\n\r\n \r\n {{ item.date }}\r\n {{ item.cities }}\r\n \r\n\r\n","export enum SitemapLoaders {\r\n GetAll = 'GetAll'\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { OverlayComponent } from '@app/template/home/components/overlay/overlay.component';\r\nimport { SearchModule } from '@app/client-core/search/search.module';\r\nimport { PromotedComponent } from '@app/template/home/components/promoted/promoted.component';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { CarouselModule } from '@app/template/elements/carousel/carousel.module';\r\nimport { LogoModule } from '@app/template/layout/modules/logo/logo.module';\r\nimport { TruncateModule } from '@share/modules/truncate/truncate.module';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { RouterModule } from '@angular/router';\r\nimport { SelectModule } from '@share/modules/html/select/select.module';\r\nimport { FormsModule } from '@angular/forms';\r\nimport { NgbCarouselModule, NgbPaginationModule } from '@ng-bootstrap/ng-bootstrap';\r\nimport { HeadingModule } from '@app/template/elements/heading/heading.module';\r\nimport { PromotedModule } from '@app/template/elements/promoted/promoted.module';\r\nimport { PolygonModule } from '@app/template/elements/polygon/polygon.module';\r\nimport { AccordionModule } from '@app/template/elements/accordion/accordion.module';\r\nimport { PaginationModule } from '@app/template/elements/pagination/pagination.module';\r\nimport { MainBannerComponent } from '@app/template/home/components/main-banner/main-banner.component';\r\nimport { ReportCrashComponent } from '@app/template/home/components/report-crash/report-crash.component';\r\nimport { ScheduleComponent } from '@app/template/home/components/schedule/schedule.component';\r\nimport { NewsComponent } from '@app/template/home/components/news/news.component';\r\nimport { GalleryComponent } from '@app/template/home/components/gallery/gallery.component';\r\nimport { SimpleBoxModule } from '@app/template/elements/simple-box/simple-box.module';\r\nimport { ArticleModule } from '@app/client-core/article/article.module';\r\n\r\n@NgModule({\r\n declarations: [\r\n GalleryComponent,\r\n NewsComponent,\r\n ScheduleComponent,\r\n ReportCrashComponent,\r\n MainBannerComponent,\r\n OverlayComponent,\r\n PromotedComponent,\r\n ],\r\n imports: [\r\n CommonModule,\r\n SearchModule,\r\n CarouselModule,\r\n ElementsModule,\r\n LogoModule,\r\n RouterModule,\r\n NgbCarouselModule,\r\n NgbPaginationModule,\r\n PromotedModule,\r\n SelectModule,\r\n FormsModule,\r\n TranslatorModule,\r\n PolygonModule,\r\n TruncateModule,\r\n AccordionModule,\r\n PaginationModule,\r\n HeadingModule,\r\n SimpleBoxModule,\r\n ArticleModule\r\n ],\r\n exports: [OverlayComponent]\r\n})\r\nexport class HomeModule {}\r\n","import { Injectable } from '@angular/core';\r\nimport { BehaviorSubject, Observable } from 'rxjs';\r\nimport { distinctUntilChanged } from 'rxjs/operators';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class HomeService {\r\n private _isHomePreview: BehaviorSubject = new BehaviorSubject(false);\r\n isHomePreview$: Observable = this._isHomePreview.asObservable().pipe(distinctUntilChanged());\r\n\r\n set isHomePreview(value: boolean) {\r\n this._isHomePreview.next(value);\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { ServiceHelper } from '@share/common/helpers/service.helper';\r\nimport { Bundle } from '@app/common/enums/server-bundles.enum';\r\nimport { Observable } from 'rxjs';\r\nimport { ResponseArray } from '@share/common/models/http.model';\r\nimport { API } from '@app/common/constants/api.directories';\r\nimport { Promoted } from '@app/template/elements/promoted/models/promoted.model';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class PromotedService extends ServiceHelper {\r\n constructor() {\r\n super(Bundle.Promoted);\r\n }\r\n\r\n public getList(): Observable> {\r\n return this.getAll(API.PROMOTED.ROOT);\r\n }\r\n}\r\n","import {Injectable} from '@angular/core';\r\nimport {ServiceHelper} from '@share/common/helpers/service.helper';\r\nimport {Bundle} from '@app/common/enums/server-bundles.enum';\r\nimport {Observable} from 'rxjs';\r\nimport {MenuModel} from '@app/client-core/menu/models/menu.model';\r\nimport {ResponseArray} from '@share/common/models/http';\r\nimport {API} from '@app/common/constants/api.directories';\r\nimport { ApiService } from '@app/common/services/api.service';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class SitemapService {\r\n\r\n constructor(private apiService: ApiService) {}\r\n\r\n getInstitutionData(): Observable {\r\n return this.apiService.get('institution');\r\n }\r\n\r\n public getList(): Observable> {\r\n return this.apiService.getAll(API.MENU.SITEMAP);\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { BreadcrumbsService } from '@app/template/layout/modules/header/services/breadcrumbs.service';\r\nimport { SubheaderService } from '@app/template/layout/modules/header/services/subheader.service';\r\nimport { Observable, of } from 'rxjs';\r\nimport { DynamicContentService } from '@app/client-core/dynamic-content/service/dynamic-content.service';\r\nimport { filter, takeUntil } from 'rxjs/operators';\r\nimport { NavigationEnd } from '@angular/router';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { SearchService } from '@app/client-core/search/services/search.service';\r\n\r\n@Component({\r\n selector: 'app-default',\r\n templateUrl: './default.component.html',\r\n styleUrls: ['./default.component.scss']\r\n})\r\nexport class DefaultComponent extends ComponentHelper {\r\n isHome: boolean = true;\r\n backdrop$: Observable;\r\n constructor(\r\n private breadcrumbsService: BreadcrumbsService,\r\n private subheaderService: SubheaderService,\r\n private settings: SettingsService,\r\n private dynamicContentService: DynamicContentService,\r\n private searchService: SearchService\r\n ) {\r\n super();\r\n this.setHome();\r\n this.backdrop$ = searchService.isActive$;\r\n }\r\n\r\n get contentLoaded(): Observable {\r\n return this.dynamicContentService.loaded$;\r\n }\r\n\r\n public deactivate() {\r\n this.breadcrumbsService.clear.next(true);\r\n this.subheaderService.reset();\r\n }\r\n\r\n private setHome() {\r\n this.service.router.events\r\n .pipe(\r\n filter((e): e is NavigationEnd => e instanceof NavigationEnd),\r\n takeUntil(this.destroyed$)\r\n )\r\n .subscribe(event => {\r\n this.isHome = event.url === '/';\r\n });\r\n }\r\n\r\n get canShow(): Observable {\r\n if (this.isHome) {\r\n return this.contentLoaded;\r\n }\r\n return of(true);\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { DefaultComponent } from './components/default/default.component';\r\nimport { HeaderModule } from '@app/template/layout/modules/header/header.module';\r\nimport { FooterModule } from '@app/template/layout/modules/footer/footer.module';\r\nimport { CookiesModule } from '@app/client-core/cookies/cookies.module';\r\nimport { DynamicContentModule } from '@app/client-core/dynamic-content/dynamic-content.module';\r\nimport { AppRoutingModule } from '@app/app-routing.module';\r\nimport { HomeModule } from '@app/template/home/home.module';\r\nimport { SiteMapModule } from '@app/template/layout/modules/sitemap/sitemap.module';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { PolygonModule } from '@app/template/elements/polygon/polygon.module';\r\n\r\n@NgModule({\r\n declarations: [DefaultComponent],\r\n imports: [\r\n CommonModule,\r\n HeaderModule,\r\n HomeModule,\r\n FooterModule,\r\n CookiesModule,\r\n DynamicContentModule,\r\n SiteMapModule,\r\n AppRoutingModule,\r\n ElementsModule,\r\n PolygonModule\r\n ]\r\n})\r\nexport class LayoutModule {}\r\n","import { NgModule } from '@angular/core';\r\nimport { BreadcrumbsComponent } from '@app/template/layout/modules/breadcrumbs/components/breadcrumbs/breadcrumbs.component';\r\nimport { CommonModule } from '@angular/common';\r\nimport { RouterModule } from '@angular/router';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\n\r\n@NgModule({\r\n declarations: [\r\n BreadcrumbsComponent\r\n ],\r\n imports: [\r\n CommonModule,\r\n RouterModule,\r\n TranslatorModule\r\n ],\r\n exports: [\r\n BreadcrumbsComponent\r\n ]\r\n})\r\nexport class BreadcrumbsModule {}\r\n","import { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { ChangeDetectorRef, Component, EventEmitter, OnInit, Output } from '@angular/core';\r\nimport { BreadcrumbsService } from '@app/template/layout/modules/header/services/breadcrumbs.service';\r\nimport { BreadcrumbsLoaders } from '@app/template/layout/modules/header/enums/breadcrumbs-loaders.enum';\r\nimport { Breadcrumbs } from '@app/template/layout/modules/header/models/breadcrumbs.model';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { AbstractData } from '@share/common/models/http';\r\n\r\n@Component({\r\n selector: 'app-breadcrumbs',\r\n templateUrl: './breadcrumbs.component.html',\r\n styleUrls: ['./breadcrumbs.component.scss']\r\n})\r\nexport class BreadcrumbsComponent extends ComponentHelper implements OnInit {\r\n public breadcrumbs: Array> = [];\r\n public shortVersion: boolean = false;\r\n public minLengthForShortVersion: number = 3;\r\n\r\n @Output() readonly loaded: EventEmitter = new EventEmitter();\r\n\r\n constructor(private breadcrumbsService: BreadcrumbsService, private cdr: ChangeDetectorRef) {\r\n super();\r\n }\r\n\r\n public get breadcrumbsExists(): boolean {\r\n return Array.isArray(this.breadcrumbs) && this.breadcrumbs.length > 0;\r\n }\r\n\r\n public ngOnInit() {\r\n this.setReloadListener();\r\n this.setClearListener();\r\n }\r\n\r\n private loadBreadcrumbs() {\r\n this.setLoader(BreadcrumbsLoaders.Get, true);\r\n this.subscriptions.add(\r\n this.breadcrumbsService.getList(this.url).subscribe(\r\n response => {\r\n this.breadcrumbs = this.getResponseData(response);\r\n this.shortVersion = this.breadcrumbs.length > this.minLengthForShortVersion;\r\n this.cdr.detectChanges();\r\n this.loaded.emit();\r\n },\r\n () => {}\r\n )\r\n );\r\n }\r\n\r\n private setReloadListener() {\r\n this.breadcrumbsService.reload.pipe(takeUntil(this.destroyed$)).subscribe(reload => {\r\n if (reload && !this.breadcrumbsService.forceActive) {\r\n this.breadcrumbsService.customBreadcrumbs = [];\r\n this.loadBreadcrumbs();\r\n this.cdr.detectChanges();\r\n }\r\n });\r\n }\r\n\r\n private setClearListener() {\r\n this.breadcrumbsService.clear.pipe(takeUntil(this.destroyed$)).subscribe(clear => {\r\n if (clear) {\r\n this.breadcrumbs = [];\r\n this.cdr.detectChanges();\r\n this.breadcrumbsService.clear.next(false);\r\n }\r\n });\r\n }\r\n\r\n public get customBreadcrumbs(): Array<{ title: string; url?: string }> {\r\n return this.breadcrumbsService.customBreadcrumbs;\r\n }\r\n\r\n private get url(): string {\r\n return this.breadcrumbsService.getParsedUrl(this.service.router.url);\r\n }\r\n\r\n public getLink(index: number): Array {\r\n const segments = this.breadcrumbsService.generateLink(this.breadcrumbs, index);\r\n\r\n if (segments.length > 1) {\r\n return [...segments];\r\n }\r\n\r\n return ['/'];\r\n }\r\n\r\n public expandBreadcrumbs(event: Event) {\r\n event.preventDefault();\r\n this.shortVersion = false;\r\n this.cdr.detectChanges();\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n {{breadcrumb.attributes.title}}\r\n {{breadcrumb.attributes.title}}\r\n \r\n \r\n {{breadcrumb.attributes.title}}\r\n \r\n \r\n \r\n \r\n \r\n {{breadcrumbs[0].attributes.title}}\r\n {{breadcrumbs[0].attributes.title}}\r\n \r\n \r\n {{'...'}}\r\n \r\n {{breadcrumbs[breadcrumbs.length - 1].attributes.title}}\r\n \r\n \r\n\r\n\r\n 0\">\r\n \r\n \r\n \r\n \r\n {{customBreadcrumb.title}}\r\n \r\n \r\n {{customBreadcrumb.title}}\r\n \r\n \r\n \r\n \r\n \r\n\r\n","import {Component, Input, OnInit} from '@angular/core';\r\n\r\n@Component({\r\n selector: 'app-container',\r\n templateUrl: './container.component.html',\r\n styles: []\r\n})\r\nexport class ContainerComponent implements OnInit {\r\n\r\n @Input() public top: number = 30;\r\n @Input() public bottom: number = 30;\r\n @Input() public left: number = 0;\r\n @Input() public right: number = 0;\r\n\r\n constructor() { }\r\n\r\n ngOnInit() {\r\n }\r\n\r\n}\r\n","\r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport {ContainerComponent} from '@app/template/layout/modules/container/components/container/container.component';\r\n\r\n@NgModule({\r\n declarations: [\r\n ContainerComponent\r\n ],\r\n imports: [\r\n CommonModule\r\n ],\r\n exports: [\r\n ContainerComponent\r\n ]\r\n})\r\nexport class ContainerModule { }\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\n\r\n@Component({\r\n selector: 'app-fatal-error',\r\n templateUrl: './fatal-error.component.html',\r\n styleUrls: ['./fatal-error.component.scss']\r\n})\r\nexport class FatalErrorComponent extends ComponentHelper implements OnInit {\r\n\r\n constructor() {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n }\r\n\r\n goToHome(): void {\r\n window.location.href = '/';\r\n }\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n {{ '500' }}\r\n {{ 'Błąd serwera' }}\r\n \r\n \r\n \r\n \r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\n\r\n@Component({\r\n selector: 'app-maintenance',\r\n templateUrl: './maintenance.component.html',\r\n styleUrls: ['./maintenance.component.scss']\r\n})\r\nexport class MaintenanceComponent extends ComponentHelper implements OnInit {\r\n\r\n constructor() {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n }\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n {{'global.maintenance' | trans}}\r\n {{'global.maintenanceText' | trans}}.\r\n \r\n \r\n\r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\n\r\n@Component({\r\n selector: 'app-not-found',\r\n templateUrl: './not-found.component.html',\r\n styleUrls: ['./not-found.component.scss']\r\n})\r\nexport class NotFoundComponent extends ComponentHelper implements OnInit {\r\n\r\n constructor() {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n }\r\n\r\n goToHome(): void {\r\n this.service.router.navigate(['']);\r\n }\r\n\r\n}\r\n","\r\n \r\n \r\n {{ '404' }}\r\n {{ 'Nie znaleziono strony' }}\r\n \r\n \r\n \r\n\r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { NotFoundComponent } from './components/not-found/not-found.component';\r\nimport { RouterModule } from '@angular/router';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { MaintenanceComponent } from './components/maintenance/maintenance.component';\r\nimport { FatalErrorComponent } from './components/fatal-error/fatal-error.component';\r\n\r\n@NgModule({\r\n declarations: [NotFoundComponent, MaintenanceComponent, FatalErrorComponent],\r\n imports: [\r\n CommonModule,\r\n RouterModule,\r\n ElementsModule,\r\n TranslatorModule\r\n ],\r\n exports: [\r\n NotFoundComponent,\r\n MaintenanceComponent\r\n ]\r\n})\r\nexport class ErrorPagesModule {\r\n}\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { VersionService } from '@share/common/services/version.service';\r\n\r\n@Component({\r\n selector: 'app-footer',\r\n templateUrl: './footer.component.html',\r\n styleUrls: ['./footer.component.scss']\r\n})\r\nexport class FooterComponent extends ComponentHelper implements OnInit {\r\n public footer: string;\r\n public version: string;\r\n\r\n constructor(private settingsService: SettingsService, private versionService: VersionService) {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n this.footer = this.settingsService.variables.footer.footer;\r\n }\r\n}\r\n","\r\n","import {NgModule} from '@angular/core';\r\nimport {CommonModule} from '@angular/common';\r\nimport {FooterComponent} from './components/footer/footer.component';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\n\r\n@NgModule({\r\n declarations: [FooterComponent],\r\n imports: [\r\n CommonModule,\r\n TranslatorModule,\r\n ElementsModule\r\n ],\r\n exports: [\r\n FooterComponent\r\n ]\r\n})\r\nexport class FooterModule {\r\n}\r\n","import { ChangeDetectionStrategy, Component } from '@angular/core';\r\n\r\ndeclare let $: any;\r\n\r\n@Component({\r\n selector: 'app-a11y-font-size',\r\n styleUrls: ['a11y-font-size.component.scss'],\r\n templateUrl: 'a11y-font-size.component.html',\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class A11yFontSizeComponent {\r\n constructor() {}\r\n\r\n setDefaultFontSize() {\r\n this.changeFontSize('10px');\r\n }\r\n setBiggerFontSize() {\r\n this.changeFontSize('11px');\r\n }\r\n setBigFontSize() {\r\n this.changeFontSize('12px');\r\n }\r\n\r\n private changeFontSize(size: string) {\r\n $('html').css({\r\n 'font-size': size\r\n });\r\n }\r\n}\r\n","\r\n \r\n \r\n domyślna czcionka\r\n A\r\n \r\n \r\n \r\n \r\n większa czcionka\r\n A\r\n \r\n \r\n \r\n \r\n największa czcionka\r\n A\r\n \r\n \r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { GoogleTranslateService } from '@app/common/services/google-translate.service';\r\n\r\n@Component({\r\n selector: 'app-google-translator',\r\n templateUrl: './google-translator.component.html',\r\n styleUrls: [\r\n './google-translator.component.scss'\r\n ]\r\n})\r\nexport class GoogleTranslatorComponent implements OnInit {\r\n\r\n constructor(private googleTranslateService: GoogleTranslateService) {}\r\n\r\n public ngOnInit() {\r\n this.googleTranslateService.init();\r\n }\r\n\r\n}\r\n","\r\n","import { AfterViewInit, Component, ElementRef, Inject, OnInit, ViewChild, ViewContainerRef } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { DOCUMENT } from '@angular/common';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { LazyLoaderService } from '@app/common/services/lazy-loader.service';\r\nimport { ThemesEnum } from '@app/common/models/themes.enum';\r\nimport { ResizeListener } from '@app/common/services/resize-listener.service';\r\nimport { SearchService } from '@app/client-core/search/services/search.service';\r\nimport { fromEvent, Observable } from 'rxjs';\r\nimport { MenuService } from '@app/client-core/menu/services/menu.service';\r\nimport { debounceTime, filter, finalize, first, takeUntil, tap } from 'rxjs/operators';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { MenuModel } from '@app/client-core/menu/models/menu.model';\r\n\r\ndeclare let $: Function;\r\n\r\n@Component({\r\n selector: 'app-header',\r\n templateUrl: './header-container.component.html',\r\n styleUrls: [\r\n './header-container.component.scss',\r\n './header-container-contrast.component.scss',\r\n ]\r\n})\r\nexport class HeaderContainerComponent extends ComponentHelper implements OnInit, AfterViewInit {\r\n isAuthenticated: boolean = false;\r\n search: string;\r\n\r\n @ViewChild('alertBtn', { read: ViewContainerRef }) alertBtn: ViewContainerRef;\r\n @ViewChild('menu', { read: ViewContainerRef }) menu: ViewContainerRef;\r\n\r\n private startDistance = 10;\r\n\r\n isMobileSearchActive$: Observable;\r\n isValidDefaultMenuWidth: boolean;\r\n isMobileMenuMode: boolean;\r\n isDefaultMenuWidthChecking: boolean;\r\n isFetchMenuLoading: boolean;\r\n menuData: AbstractData[];\r\n\r\n constructor(\r\n @Inject(DOCUMENT) private document: Document,\r\n private settings: SettingsService,\r\n private loader: LazyLoaderService,\r\n public resizeListener: ResizeListener,\r\n private searchService: SearchService,\r\n private menuService: MenuService,\r\n private _elementRef: ElementRef\r\n ) {\r\n super();\r\n }\r\n\r\n get isSubpage(): boolean {\r\n return !this.service.router.isActive('', true);\r\n }\r\n\r\n get isAlertModuleEnabled(): boolean {\r\n return this.settings.isModuleActive(ThemesEnum.ALERT);\r\n }\r\n\r\n get isMenuModuleEnabled(): boolean {\r\n return this.settings.isModuleActive(ThemesEnum.MENU);\r\n }\r\n\r\n /** Metoda sprawdzająca, czy zawartość menu dla desktop'ów nie wystaje poza szerokość okna/headera. */\r\n get isValidHeaderContentWidth(): boolean {\r\n const contentElementRef: HTMLElement = this.document.querySelector('#main-app-header .content') as HTMLElement;\r\n const contentElementChildren: HTMLElement[] = Array.from(contentElementRef.children) as HTMLElement[];\r\n const contentElementAvailableWidth: number = contentElementRef.offsetWidth\r\n - (parseInt(getComputedStyle(contentElementRef).paddingLeft))\r\n - (parseInt(getComputedStyle(contentElementRef).paddingRight))\r\n - 30 // ScrollBar with small offset.\r\n ;\r\n\r\n let contentChildrenWidth: number = 0;\r\n\r\n contentElementChildren.forEach(child => {\r\n contentChildrenWidth += child.offsetWidth;\r\n });\r\n\r\n return contentChildrenWidth <= contentElementAvailableWidth\r\n }\r\n\r\n ngOnInit() {\r\n this.fetchMenu();\r\n window.addEventListener('scroll', () => this.scroll(), true);\r\n this.scroll();\r\n this.isMobileSearchActive$ = this.searchService.isActive$;\r\n this.searchService.isActive$.pipe(takeUntil(this.destroyed$)).subscribe(isActive => {\r\n if (isActive) {\r\n this.menuService.isMobileMenuActive$.next(false);\r\n }\r\n });\r\n this.handleOutsideClick();\r\n }\r\n\r\n ngAfterViewInit() {\r\n this.generateAlertButton();\r\n this.generateMenu();\r\n }\r\n\r\n private setMenuModeChangeListener() {\r\n this.resizeListener.isMobile$.pipe(\r\n takeUntil(this.destroyed$),\r\n tap((value) => this.isMobileMenuMode = value),\r\n filter((value) => !value),\r\n tap(() => {\r\n this.isDefaultMenuWidthChecking = true;\r\n this.isValidDefaultMenuWidth = true; // Pokazanie menu, aby JS mógł obliczyć szerokość wewnątrz komponentu.\r\n }),\r\n debounceTime(500),\r\n ).subscribe((value) => {\r\n this.setIsMobileMenuMode();\r\n });\r\n }\r\n\r\n private fetchMenu() {\r\n this.isFetchMenuLoading = true;\r\n\r\n this.menuService\r\n .getList()\r\n .pipe(\r\n first(),\r\n finalize(() => this.isFetchMenuLoading = false)\r\n )\r\n .subscribe(\r\n response => {\r\n this.menuData = response.data;\r\n this.setMenuModeChangeListener();\r\n }\r\n );\r\n }\r\n\r\n private setIsMobileMenuMode(): void {\r\n // setTimeout z racji wymaganego opóźnienia przy obliczaniu dostępnej szerokosci.\r\n setTimeout(() => {\r\n this.isValidDefaultMenuWidth = this.isValidHeaderContentWidth;\r\n });\r\n\r\n this.isDefaultMenuWidthChecking = false;\r\n }\r\n\r\n generateAlertButton() {\r\n if (this.alertBtn && this.isAlertModuleEnabled) {\r\n this.loader.load(ThemesEnum.ALERT, this.alertBtn);\r\n }\r\n }\r\n\r\n generateMenu() {\r\n if (this.menu) {\r\n this.menu?.clear();\r\n if (this.isMenuModuleEnabled || this.isAuthenticated) {\r\n this.loader.load(ThemesEnum.MENU, this.menu);\r\n }\r\n }\r\n }\r\n\r\n handleOutsideClick() {\r\n const clickEvent$ = fromEvent(document, 'click');\r\n clickEvent$\r\n .pipe(\r\n takeUntil(this.destroyed$),\r\n filter(e => !this._elementRef.nativeElement.contains(e.target)),\r\n tap(e => {\r\n this.searchService.isActive$.next(false);\r\n })\r\n )\r\n .subscribe();\r\n }\r\n\r\n\r\n private scroll() {\r\n const scrollTop = $(this.document).scrollTop(),\r\n header = $('header');\r\n if (scrollTop >= this.startDistance) {\r\n header.addClass('sticked');\r\n } else {\r\n header.removeClass('sticked');\r\n }\r\n }\r\n\r\n onComponentRefresh() {\r\n this.fetchMenu();\r\n }\r\n}\r\n","\r\n Dolina baryczy\r\n \r\n \r\n \r\n {{ 'global.search' | trans }}\r\n \r\n \r\n \r\n {{ 'global.settings' | trans }}\r\n \r\n \r\n \r\n {{'global.contrast' | trans}}\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { AfterViewInit, Component, OnInit, Renderer2 } from '@angular/core';\r\n\r\ndeclare let $: Function;\r\n\r\n@Component({\r\n selector: 'app-high-contrast',\r\n templateUrl: './high-contrast.component.html',\r\n styleUrls: ['./high-contrast.component.scss']\r\n})\r\nexport class HighContrastComponent implements OnInit, AfterViewInit {\r\n constructor(private renderer: Renderer2) {}\r\n\r\n ngOnInit(): void {}\r\n\r\n ngAfterViewInit(): void {\r\n const contrast: string = localStorage.getItem('contrast') as string;\r\n if (contrast) {\r\n switch (contrast) {\r\n case 'blackwhite':\r\n this.addBlackWhite();\r\n break;\r\n case 'yellowblack':\r\n this.addYellowBlack();\r\n break;\r\n }\r\n }\r\n }\r\n\r\n removeContrast() {\r\n this.renderer.removeClass(document.body, localStorage.getItem('contrast') as string);\r\n this.renderer.setStyle(document.body, 'color', '');\r\n this.renderer.setStyle(document.body, 'background-color', '');\r\n\r\n localStorage.setItem('contrast', 'normal');\r\n }\r\n\r\n addYellowBlack() {\r\n this.removeContrast();\r\n this.renderer.addClass(document.body, 'yellowblack');\r\n\r\n this.renderer.setStyle(document.body, 'background-color', 'black');\r\n this.renderer.setStyle(document.body, 'color', 'yellow');\r\n\r\n localStorage.setItem('contrast', 'yellowblack');\r\n }\r\n\r\n addBlackWhite() {\r\n this.removeContrast();\r\n this.renderer.addClass(document.body, 'blackwhite');\r\n\r\n this.renderer.setStyle(document.body, 'background-color', 'white');\r\n this.renderer.setStyle(document.body, 'color', 'black');\r\n\r\n localStorage.setItem('contrast', 'blackwhite');\r\n }\r\n}\r\n","\r\n \r\n \r\n brak wysokiego kontrastu\r\n A\r\n \r\n \r\n \r\n \r\n czarno-biały\r\n A\r\n \r\n \r\n \r\n \r\n żółto-czarny\r\n A\r\n \r\n \r\n\r\n","export { SubheaderDescriptionComponent } from './subheader/subheader-description/subheader-description.component';\r\nexport { SubheaderTitleComponent } from './subheader/subheader-title/subheader-title.component';\r\nexport { SubheaderComponent } from './subheader/subheader.component';\r\nexport { GoogleTranslatorComponent } from './google-translator/google-translator.component';\r\nexport { HeaderContainerComponent } from './header-container/header-container.component';\r\nexport { LanguageComponent } from './language/language.component';\r\nexport { A11yFontSizeComponent } from './a11y-font-size/a11y-font-size.component';\r\n","import {ComponentHelper} from '@app/common/helpers/component.helper';\r\nimport {Component, ViewEncapsulation} from '@angular/core';\r\n\r\n@Component({\r\n selector: 'app-language',\r\n templateUrl: './language.component.html',\r\n styleUrls: ['./language.component.scss'],\r\n})\r\nexport class LanguageComponent extends ComponentHelper {\r\n\r\n public language: string = 'pl';\r\n\r\n constructor() {\r\n super();\r\n }\r\n\r\n changeLanguage(): void {\r\n alert('TODO');\r\n }\r\n}\r\n","\r\n","import { Component, Input } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'cms-subheader-description',\r\n templateUrl: 'subheader-description.component.html',\r\n styleUrls: ['subheader-description.component.scss']\r\n})\r\nexport class SubheaderDescriptionComponent {\r\n @Input() text: string;\r\n @Input() isMobile: boolean;\r\n}\r\n","{{text}}\r\n","import { Component, ElementRef, EventEmitter, Input, Output, ViewChild } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'cms-subheader-title',\r\n templateUrl: 'subheader-title.component.html',\r\n styleUrls: ['subheader-title.component.scss']\r\n})\r\nexport class SubheaderTitleComponent {\r\n\r\n isEditable: boolean = false;\r\n\r\n @Input() title: string;\r\n @Input() isMobile: boolean;\r\n @Input() set editable(editable: boolean) {\r\n this.isEditable = editable;\r\n setTimeout(() => this.text.nativeElement.focus());\r\n };\r\n\r\n @ViewChild('text') text: ElementRef;\r\n\r\n @Output() onSubmitEditable: EventEmitter = new EventEmitter();\r\n\r\n onSubmit() {\r\n this.isEditable = false;\r\n this.onSubmitEditable.emit(this.text.nativeElement.innerText);\r\n }\r\n\r\n}\r\n","{{ title }}\r\n","import { AfterViewInit, Component, Injector } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { SubheaderConfig } from '@app/template/layout/modules/header/interfaces/subheader-config.interface';\r\nimport { BreadcrumbsService } from '@app/template/layout/modules/header/services/breadcrumbs.service';\r\nimport { NavigationEnd } from '@angular/router';\r\nimport { filter, takeUntil } from 'rxjs/operators';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { DynamicContentService } from '@app/client-core/dynamic-content/service/dynamic-content.service';\r\nimport { Observable } from 'rxjs';\r\nimport { HomeService } from '@app/template/home/services/home.service';\r\n\r\n@Component({\r\n selector: 'app-subheader',\r\n templateUrl: './subheader.component.html',\r\n styleUrls: ['./subheader.component.scss']\r\n})\r\nexport class SubheaderComponent extends ComponentHelper implements AfterViewInit {\r\n active: boolean = false;\r\n isHome: boolean = false;\r\n\r\n constructor(\r\n private breadcrumbsService: BreadcrumbsService,\r\n private settings: SettingsService,\r\n private dynamicContentService: DynamicContentService,\r\n private homeService: HomeService\r\n ) {\r\n super();\r\n this.setHome();\r\n }\r\n\r\n get contentLoaded(): Observable {\r\n return this.dynamicContentService.loaded$;\r\n }\r\n\r\n get isHomePreview(): Observable {\r\n return this.homeService.isHomePreview$;\r\n }\r\n\r\n private setHome() {\r\n this.service.router.events\r\n .pipe(\r\n filter((e): e is NavigationEnd => e instanceof NavigationEnd),\r\n takeUntil(this.destroyed$)\r\n )\r\n .subscribe(event => {\r\n this.isHome = event.url === '/';\r\n });\r\n }\r\n\r\n get component() {\r\n return this.service.subheader.config.component;\r\n }\r\n\r\n get config(): SubheaderConfig {\r\n return this.service.subheader.config;\r\n }\r\n\r\n get myInjector(): Injector | null | undefined {\r\n return this.service.subheader.config.injector;\r\n }\r\n\r\n get displayBreadcrumbs() {\r\n return this.service.subheader.config.displayBreadcrumbs;\r\n }\r\n\r\n get forceShow() {\r\n return this.service.subheader.config.forceShow;\r\n }\r\n\r\n get categories(): { title: string; slug: string }[] | undefined {\r\n return this.service.subheader.config.categories;\r\n }\r\n\r\n get publishedDate(): string | undefined {\r\n return this.service.subheader.config.publishedDate;\r\n }\r\n\r\n get image(): string | undefined {\r\n return this.service.subheader.config.image;\r\n }\r\n\r\n get hideDots(): boolean {\r\n return this.service.subheader.config.hideDots || false;\r\n }\r\n\r\n ngAfterViewInit(): void {\r\n this.breadcrumbsService.reload.next(true);\r\n }\r\n\r\n isArray(categories: { title: string; slug: string }[] | string | undefined): boolean {\r\n return Array.isArray(categories);\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n {{ category.attributes.title }}\r\n \r\n \r\n {{ publishedDate | date: 'shortDate':'':'pl' }}\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","export enum BreadcrumbsLoaders {\r\n Get = 'Get'\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { WcagModule } from '@share/modules/wcag/wcag.module';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { LogoModule } from '@app/template/layout/modules/logo/logo.module';\r\nimport { SearchModule } from '@app/client-core/search/search.module';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { RouterModule } from '@angular/router';\r\nimport {\r\n A11yFontSizeComponent,\r\n GoogleTranslatorComponent,\r\n HeaderContainerComponent,\r\n LanguageComponent,\r\n SubheaderComponent,\r\n SubheaderDescriptionComponent,\r\n SubheaderTitleComponent\r\n} from './components';\r\nimport { BreadcrumbsModule } from '@app/template/layout/modules/breadcrumbs/breadcrumbs.module';\r\nimport { HttpClientModule } from '@angular/common/http';\r\nimport { MenuModule } from '@app/client-core/menu/menu.module';\r\nimport { InputModule } from '@share/modules/html/input/input.module';\r\nimport { FormsModule } from '@angular/forms';\r\nimport { HighContrastComponent } from './components/high-contrast/high-contrast.component';\r\n\r\n@NgModule({\r\n declarations: [\r\n LanguageComponent,\r\n SubheaderTitleComponent,\r\n SubheaderDescriptionComponent,\r\n GoogleTranslatorComponent,\r\n HeaderContainerComponent,\r\n SubheaderComponent,\r\n A11yFontSizeComponent,\r\n HighContrastComponent\r\n ],\r\n imports: [\r\n CommonModule,\r\n WcagModule,\r\n LogoModule,\r\n ElementsModule,\r\n HttpClientModule,\r\n SearchModule,\r\n ElementsModule,\r\n TranslatorModule,\r\n RouterModule,\r\n BreadcrumbsModule,\r\n MenuModule,\r\n InputModule,\r\n FormsModule\r\n ],\r\n exports: [HeaderContainerComponent, SubheaderComponent, SubheaderTitleComponent, SubheaderDescriptionComponent]\r\n})\r\nexport class HeaderModule {}\r\n","import { ReplaySubject } from 'rxjs';\r\nimport { Injector } from '@angular/core';\r\n\r\nexport interface SubheaderConfig {\r\n title: string;\r\n description: string;\r\n displayHeader: boolean;\r\n displayBreadcrumbs: ReplaySubject;\r\n searchOpen: boolean;\r\n searchType: SearchType;\r\n component: any;\r\n categories?: { slug: string; title: string }[];\r\n hideSearch: boolean;\r\n injector?: Injector | null;\r\n forceShow: boolean;\r\n publishedDate?: string;\r\n image?: string;\r\n hideDots?: boolean\r\n}\r\n\r\nexport enum SearchType {\r\n Default = '',\r\n EServices = 'eservice',\r\n None = ''\r\n}\r\n\r\nexport enum SearchTypeNames {\r\n Default = 'Wszędzie',\r\n EServices = 'Katalog e-usług'\r\n}\r\n","import { ServiceHelper } from '@share/common/helpers/service.helper';\r\nimport { Bundle } from '@app/common/enums/server-bundles.enum';\r\nimport { Injectable } from '@angular/core';\r\nimport { BehaviorSubject, Observable } from 'rxjs';\r\nimport { AbstractData, ResponseArray } from '@share/common/models/http';\r\nimport { Breadcrumbs } from '@app/template/layout/modules/header/models/breadcrumbs.model';\r\nimport { API } from '@app/common/constants/api.directories';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class BreadcrumbsService extends ServiceHelper {\r\n reload: BehaviorSubject = new BehaviorSubject(false);\r\n clear: BehaviorSubject = new BehaviorSubject(false);\r\n customBreadcrumbs: Array<{ title: string; url?: string }> = [];\r\n forceActive = false;\r\n\r\n constructor() {\r\n super(Bundle.Breadcrumbs);\r\n }\r\n\r\n public getList(url: string): Observable> {\r\n return this.getAll(`${API.COMMON.BREADCRUMBS}/,${url}`);\r\n }\r\n\r\n public getParsedUrl(url: string): string {\r\n return url.substr(1, url.length).split('/').join(',');\r\n }\r\n\r\n public generateLink(breadcrumbs: Array>, index: number): Array {\r\n let path: Array = [];\r\n try {\r\n for (let i = 0; i < (index + 1); i++) {\r\n path.push(breadcrumbs[i].attributes.url);\r\n }\r\n } catch (_ignore) {\r\n path = [];\r\n }\r\n return path;\r\n }\r\n\r\n public reset() {\r\n this.reload.next(true);\r\n }\r\n}\r\n","import { Injectable, Injector } from '@angular/core';\r\nimport { BehaviorSubject, Observable, ReplaySubject } from 'rxjs';\r\nimport { SearchType, SubheaderConfig } from '@app/template/layout/modules/header/interfaces/subheader-config.interface';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class SubheaderService {\r\n private _config: BehaviorSubject;\r\n\r\n constructor() {\r\n this._config = new BehaviorSubject(this.default);\r\n }\r\n\r\n private get default(): SubheaderConfig {\r\n return {\r\n title: '',\r\n description: '',\r\n searchType: SearchType.None,\r\n component: null,\r\n displayHeader: true,\r\n displayBreadcrumbs: new ReplaySubject(1),\r\n searchOpen: false,\r\n hideSearch: false,\r\n injector: null,\r\n forceShow: false,\r\n categories: [],\r\n hideDots: false\r\n };\r\n }\r\n\r\n public get config(): SubheaderConfig {\r\n return this._config.getValue();\r\n }\r\n\r\n public getConfig(): Observable> {\r\n return this._config.asObservable();\r\n }\r\n\r\n public setConfig(value: Partial) {\r\n this._config.next({ ...this.default, ...value });\r\n }\r\n\r\n public set title(title: string) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n title\r\n });\r\n }\r\n\r\n public set description(description: string) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n description\r\n });\r\n }\r\n\r\n public set searchType(searchType: SearchType) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n searchType\r\n });\r\n }\r\n\r\n public set searchOpen(searchOpen: boolean) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n searchOpen\r\n });\r\n }\r\n\r\n public set injector(injector: Injector) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n injector\r\n });\r\n }\r\n\r\n public set forceShow(forceShow: boolean) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n forceShow\r\n });\r\n }\r\n\r\n public set displayBreadcrumbs(show: boolean) {\r\n this.config.displayBreadcrumbs.next(show);\r\n }\r\n\r\n set categories(categories: { slug: string; title: string }[]) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n categories\r\n });\r\n }\r\n\r\n set publishedDate(publishedDate: string) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n publishedDate\r\n });\r\n }\r\n\r\n set image(image: string) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n image\r\n });\r\n }\r\n\r\n set hideDots(hideDots: boolean) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n hideDots\r\n });\r\n }\r\n\r\n public reset() {\r\n this.setConfig(this.default);\r\n }\r\n}\r\n","import { Component, Input, OnDestroy, OnInit } from '@angular/core';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { Subject } from 'rxjs';\r\n\r\n@Component({\r\n selector: 'app-logo',\r\n templateUrl: './logo.component.html',\r\n styleUrls: ['./logo.component.scss']\r\n})\r\nexport class LogoComponent implements OnInit, OnDestroy {\r\n private destroy$: Subject = new Subject();\r\n url: string;\r\n\r\n @Input() id: string = 'logo';\r\n @Input() isAlt: boolean;\r\n @Input() preventChange: boolean;\r\n\r\n constructor(private layoutService: SettingsService) {}\r\n\r\n ngOnInit() {\r\n if (this.isAlt) {\r\n this.url = this.layoutService.variables.site.altLogo;\r\n } else {\r\n this.url = this.layoutService.variables.site.logo;\r\n }\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.destroy$.next(true);\r\n this.destroy$.complete();\r\n }\r\n}\r\n","\r\n Strona główna\r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { LogoComponent } from '@app/template/layout/modules/logo/components/logo/logo.component';\r\nimport { RouterModule } from '@angular/router';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n RouterModule,\r\n TranslatorModule\r\n ],\r\n declarations: [\r\n LogoComponent\r\n ],\r\n exports: [\r\n LogoComponent\r\n ]\r\n})\r\nexport class LogoModule {}\r\n","import { Component, ElementRef, Input, OnDestroy, OnInit, Renderer2 } from '@angular/core';\r\nimport { AbstractData } from '@share/common/models/http.model';\r\nimport { MenuModel } from '@app/client-core/menu/models/menu.model';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\n\r\n@Component({\r\n selector: 'app-sitemap-item',\r\n templateUrl: './sitemap-item.component.html',\r\n styleUrls: [\r\n './sitemap-item.component.scss'\r\n ]\r\n})\r\nexport class SitemapItemComponent extends ComponentHelper implements OnInit, OnDestroy {\r\n @Input() item: AbstractData;\r\n public listenClickFunc: Function;\r\n\r\n constructor(private renderer: Renderer2,\r\n private _elementRef: ElementRef) {\r\n super();\r\n }\r\n\r\n public ngOnInit() {\r\n this.onClickListener();\r\n }\r\n\r\n public openInNewTab(event: Event, url: string) {\r\n event.preventDefault();\r\n event.stopPropagation();\r\n window.open(url);\r\n }\r\n\r\n private onClickListener() {\r\n this.listenClickFunc = this.renderer.listen(\r\n this._elementRef.nativeElement, 'click', (event) => this.service.utils.navigateTo(event)\r\n );\r\n }\r\n\r\n public ngOnDestroy() {\r\n this.listenClickFunc();\r\n }\r\n}\r\n","{{item.attributes.title}}\r\n\r\n \r\n {{subitem.attributes.title}}\r\n \r\n {{subitem.attributes.title}}\r\n \r\n \r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { SitemapService } from '@app/template/home/services/sitemap.service';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { MenuModel } from '@app/client-core/menu/models/menu.model';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { SitemapLoaders } from '@app/template/home/enums/sitemap-loaders.enum';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { finalize, first } from 'rxjs/operators';\r\nimport { InstitutionModel } from '@app/template/layout/modules/sitemap/models/institution.model';\r\n\r\n@Component({\r\n selector: 'app-sitemap',\r\n templateUrl: './sitemap.component.html',\r\n styleUrls: ['./sitemap.component.scss']\r\n})\r\nexport class SitemapComponent extends ComponentHelper implements OnInit {\r\n sitemap: Array> = [];\r\n SitemapLoaders = SitemapLoaders;\r\n description: string;\r\n institution: AbstractData;\r\n constructor(private sitemapService: SitemapService, private settingService: SettingsService) {\r\n super();\r\n }\r\n\r\n public ngOnInit() {\r\n this.loadSitemap();\r\n this.getInstitutionData();\r\n }\r\n\r\n getInstitutionData() {\r\n this.sitemapService\r\n .getInstitutionData()\r\n .pipe(first())\r\n .subscribe(response => (this.institution = response.data));\r\n }\r\n\r\n public loadSitemap() {\r\n this.setLoader(SitemapLoaders.GetAll, true);\r\n this.sitemapService\r\n .getList()\r\n .pipe(\r\n first(),\r\n finalize(() => this.setLoader(SitemapLoaders.GetAll, false))\r\n )\r\n .subscribe(\r\n response => (this.sitemap = this.getResponseData(response)),\r\n () => this.setComponentError()\r\n );\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n {{institution?.attributes?.name}}\r\n \r\n \r\n \r\n {{ institution?.attributes?.address?.zipCode }} {{ institution?.attributes?.address?.city }}\r\n ul. {{ institution?.attributes?.address?.street }} {{ institution?.attributes?.address?.houseNumber }}\r\n {{\r\n institution?.attributes?.address?.apartmentNumber\r\n ? '/' + institution?.attributes?.address?.apartmentNumber\r\n : ''\r\n }}\r\n \r\n \r\n \r\n \r\n \r\n {{ institution?.attributes?.contact?.phoneNumber }}\r\n \r\n \r\n \r\n {{ institution?.attributes?.contact?.phoneNumberSecondary }}\r\n \r\n \r\n \r\n {{ institution?.attributes?.contact?.fax }}\r\n \r\n \r\n \r\n {{ institution?.attributes?.contact?.email }}\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n 0\">\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { LogoModule } from '@app/template/layout/modules/logo/logo.module';\r\nimport { RouterModule } from '@angular/router';\r\nimport { SitemapComponent } from '@app/template/layout/modules/sitemap/components/sitemap/sitemap.component';\r\nimport { SitemapItemComponent } from '@app/template/layout/modules/sitemap/components/sitemap/sitemap-item/sitemap-item.component';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\n\r\n@NgModule({\r\n declarations: [\r\n SitemapComponent,\r\n SitemapItemComponent,\r\n ],\r\n imports: [\r\n CommonModule,\r\n ElementsModule,\r\n LogoModule,\r\n RouterModule,\r\n TranslatorModule,\r\n ],\r\n exports: [\r\n SitemapComponent\r\n ]\r\n})\r\nexport class SiteMapModule {\r\n}\r\n\r\n","// This file can be replaced during build by using the `fileReplacements` array.\r\n// `ng build --prod` replaces `environment.ts` with `environment.prod.ts`.\r\n// The list of file replacements can be found in `angular.json`.\r\n\r\nexport const environment = {\r\n production: false\r\n};\r\n\r\n/*\r\n * For easier debugging in development mode, you can import the following file\r\n * to ignore zone related error stack frames such as `zone.run`, `zoneDelegate.invokeTask`.\r\n *\r\n * This import should be commented out in production mode because it will have a negative impact\r\n * on performance if an error is thrown.\r\n */\r\n// import 'zone.js/dist/zone-error'; // Included with Angular CLI.\r\n","import {enableProdMode} from '@angular/core';\r\nimport {platformBrowserDynamic} from '@angular/platform-browser-dynamic';\r\n\r\nimport {AppModule} from './app/app.module';\r\nimport {environment} from './environments/environment';\r\nimport 'hammerjs';\r\n\r\nif (environment.production) {\r\n enableProdMode();\r\n}\r\n\r\nplatformBrowserDynamic().bootstrapModule(AppModule)\r\n .catch(err => console.error(err));\r\n"]}
(`${API.ARTICLES.ROOT}/${slug}`).pipe(first());\r\n }\r\n}\r\n","import { ChangeDetectionStrategy, Component, OnInit } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { CookieService } from '@app/client-core/cookies/service/cookie.service';\r\n\r\n@Component({\r\n selector: 'app-cookie-information-bar',\r\n templateUrl: './cookie-information-bar.component.html',\r\n styleUrls: ['./cookie-information-bar.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class CookieInformationBarComponent extends ComponentHelper implements OnInit {\r\n\r\n public cookieText: string = '';\r\n\r\n constructor(private settings: SettingsService, private cookieService: CookieService) {\r\n super();\r\n }\r\n\r\n get isCookieAccepted(): string {\r\n return this.cookieService.getCookie('cookiesAccepted');\r\n }\r\n\r\n ngOnInit() {\r\n try {\r\n this.cookieText = this.settings.variables.footer.cookieWarningContent;\r\n } catch (ignore) {\r\n throw new Error('Cannot get cookieWarningContent of undefined');\r\n }\r\n }\r\n\r\n accept(): void {\r\n this.cookieService.setCookie('cookiesAccepted', 'true', 365);\r\n }\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { CookieInformationBarComponent } from './components/cookie-information-bar/cookie-information-bar.component';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\n\r\n@NgModule({\r\n declarations: [CookieInformationBarComponent],\r\n imports: [\r\n CommonModule,\r\n ElementsModule,\r\n TranslatorModule\r\n ],\r\n exports: [\r\n CookieInformationBarComponent\r\n ]\r\n\r\n})\r\nexport class CookiesModule {\r\n}\r\n","import { Injectable } from '@angular/core';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class CookieService {\r\n\r\n constructor() {\r\n }\r\n\r\n public getCookie(name: string) {\r\n const ca: Array = document.cookie.split(';');\r\n const caLen: number = ca.length;\r\n const cookieName = `${name}=`;\r\n let c: string;\r\n\r\n for (let i = 0; i < caLen; i += 1) {\r\n c = ca[i].replace(/^\\s+/g, '');\r\n if (c.indexOf(cookieName) === 0) {\r\n return c.substring(cookieName.length, c.length);\r\n }\r\n }\r\n return '';\r\n }\r\n\r\n public setCookie(name: string, value: string, expireDays: number = 0): void {\r\n let cookie = '';\r\n cookie += `${name}=${value};`;\r\n const d: Date = new Date();\r\n if (expireDays !== 0) {\r\n d.setTime(d.getTime() + expireDays * 24 * 60 * 60 * 1000);\r\n\r\n cookie += `expires=${d.toString()}`;\r\n }\r\n document.cookie = cookie;\r\n\r\n }\r\n\r\n}\r\n","import { AfterViewInit, Component, OnDestroy, ViewChild, ViewContainerRef } from '@angular/core';\r\nimport { ActivatedRoute, Router } from '@angular/router';\r\nimport { DynamicContentService } from '@app/client-core/dynamic-content/service/dynamic-content.service';\r\nimport { LazyLoaderService } from '@app/common/services/lazy-loader.service';\r\nimport { switchMap, takeUntil, tap } from 'rxjs/operators';\r\nimport { of, Subject } from 'rxjs';\r\nimport { ROUTES_PATHS } from '@app/common/constants/routes-paths';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { ComponentInterface } from '@app/client-core/dynamic-content/interfaces/components.interface';\r\nimport { Nullable } from '@share/common/types/utilities.types';\r\nimport { BreadcrumbsService } from '@app/template/layout/modules/header/services/breadcrumbs.service';\r\nimport { ElementService } from '@app/client-core/dynamic-content/service/element.service';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { HOME_COMPONENTS } from '@app/client-core/dynamic-content/constants/component-list';\r\n\r\n@Component({\r\n selector: 'app-dynamic-content',\r\n templateUrl: './dynamic-content.component.html',\r\n styleUrls: ['./dynamic-content.component.scss']\r\n})\r\nexport class DynamicContentComponent implements AfterViewInit, OnDestroy {\r\n @ViewChild('componentPlaceholder', { read: ViewContainerRef }) componentPlaceholder: ViewContainerRef;\r\n private currentView: string;\r\n private destroy$: Subject = new Subject();\r\n\r\n constructor(\r\n private dynamic: DynamicContentService,\r\n private router: Router,\r\n private lazyLoaderService: LazyLoaderService,\r\n private facadeService: FacadeService,\r\n private breadcrumbsService: BreadcrumbsService,\r\n private elementsService: ElementService,\r\n private settingsService: SettingsService,\r\n ) {}\r\n\r\n async ngAfterViewInit() {\r\n this.dynamic.runtimeUrlReader$\r\n .pipe(\r\n takeUntil(this.destroy$),\r\n switchMap((rawUrl: string) => {\r\n if (rawUrl.includes('#')) {\r\n return of(null);\r\n } else {\r\n if (rawUrl === '/') {\r\n return of(this.getHomeComponent()).pipe(\r\n tap((component: Nullable) => (this.dynamic.homeComponent = component))\r\n );\r\n }\r\n return this.dynamic.componentLoader(rawUrl);\r\n }\r\n })\r\n )\r\n .subscribe(\r\n (component: Nullable) => {\r\n this.loadView(component);\r\n },\r\n () => this.componentNotFoundNavigation()\r\n );\r\n }\r\n\r\n private getHomeComponent(): ComponentInterface {\r\n const { name } = this.settingsService.variables.theme;\r\n return { ...HOME_COMPONENTS[name], isHome: true };\r\n }\r\n\r\n private loadView(component: Nullable) {\r\n if (component && component.className !== this.currentView) {\r\n this.breadcrumbsService.reset();\r\n this.facadeService.subheader.reset();\r\n this.componentPlaceholder?.clear();\r\n this.lazyLoaderService.load(component.module, this.componentPlaceholder, component.name).then(() => {\r\n this.facadeService.scrollTo.resetScrollTop();\r\n this.dynamic.loaded = true;\r\n this.currentView = component?.className;\r\n });\r\n } else if (component) {\r\n this.navigateToHomeDefaultContext(component);\r\n this.breadcrumbsService.reset();\r\n this.dynamic.loaded = true;\r\n this.elementsService.loaded = true;\r\n }\r\n this.facadeService.scrollTo.resetScrollTop();\r\n }\r\n\r\n private navigateToHomeDefaultContext(component: null | ComponentInterface) {\r\n if (component?.defaultContext && component?.isHome) {\r\n this.router.navigate([component?.defaultContext]);\r\n }\r\n }\r\n\r\n private componentNotFoundNavigation() {\r\n this.router.navigate(['/', ROUTES_PATHS.notFoundPage.root]);\r\n }\r\n\r\n ngOnDestroy() {\r\n this.destroy$.next(true);\r\n this.destroy$.complete();\r\n }\r\n}\r\n","\r\n","import { StaticPageComponent } from '@app/client-core/static-pages/components/static-page/static-page.component';\r\nimport { ArticleListComponent } from '@app/client-core/article/components/article-list/article-list.component';\r\nimport { ThemesEnum } from '@app/common/models/themes.enum';\r\nimport { ComponentsInterface } from '@app/client-core/dynamic-content/interfaces/components.interface';\r\nimport { OverlayComponent } from '@app/template/home/components/overlay/overlay.component';\r\nimport { ArticleComponent } from '@app/client-core/article/components';\r\n\r\nexport const COMPONENTS: ComponentsInterface = {\r\n main: { name: OverlayComponent, module: ThemesEnum.CORE, className: 'OverlayComponent' },\r\n static: { name: StaticPageComponent, module: ThemesEnum.CORE, className: 'StaticPageComponent' },\r\n articlecategory: { name: ArticleListComponent, module: ThemesEnum.ARTICLE, className: 'ArticleListComponent' },\r\n article: { name: ArticleComponent, module: ThemesEnum.ARTICLE, className: 'ArticleComponent' }\r\n};\r\n\r\nexport enum ThemeName {\r\n Basic = 'podstawowy'\r\n}\r\n\r\nexport const HOME_COMPONENTS: ComponentsInterface = {\r\n [ThemeName.Basic]: { name: OverlayComponent, module: ThemesEnum.CORE, className: 'OverlayComponent' }\r\n};\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { DynamicContentComponent } from './component/dynamic-content/dynamic-content.component';\r\nimport { ProgressBarModule } from '@share/modules/progress-bar/progress-bar.module';\r\nimport { StaticPagesModule } from '@app/client-core/static-pages/static-pages.module';\r\nimport { ArticleModule } from '@app/client-core/article/article.module';\r\nimport { HomeModule } from '@app/template/home/home.module';\r\nimport { DynamicUtilsService } from '@app/client-core/dynamic-content/service/dynamic-utils.service';\r\n\r\n@NgModule({\r\n declarations: [DynamicContentComponent],\r\n imports: [\r\n CommonModule,\r\n ProgressBarModule,\r\n StaticPagesModule,\r\n ArticleModule,\r\n HomeModule\r\n ],\r\n providers: [DynamicUtilsService],\r\n exports: [\r\n DynamicContentComponent\r\n ]\r\n})\r\nexport class DynamicContentModule {\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { API } from '@app/common/constants/api.directories';\r\nimport { COMPONENTS } from '@app/client-core/dynamic-content/constants/component-list';\r\nimport { BehaviorSubject, Observable, of, throwError } from 'rxjs';\r\nimport { MetaResponse, ResponseDefault } from '@share/common/models/http.model';\r\nimport { Nullable } from '@share/common/types/utilities.types';\r\nimport { ComponentInterface } from '@app/client-core/dynamic-content/interfaces/components.interface';\r\nimport { distinctUntilChanged, filter, map, startWith, switchMap, tap } from 'rxjs/operators';\r\nimport { ApiService } from '@app/common/services/api.service';\r\nimport { NavigationEnd, Router } from '@angular/router';\r\nimport { DynamicUtilsService } from '@app/client-core/dynamic-content/service/dynamic-utils.service';\r\nimport { ElementService } from '@app/client-core/dynamic-content/service/element.service';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class DynamicContentService {\r\n private _loaded: BehaviorSubject = new BehaviorSubject(true);\r\n loaded$: Observable = this._loaded.asObservable().pipe(distinctUntilChanged());\r\n homeComponent: Nullable;\r\n\r\n constructor(\r\n private apiService: ApiService,\r\n private router: Router,\r\n private dynamicUtilsService: DynamicUtilsService,\r\n private elementService: ElementService\r\n ) {}\r\n\r\n set loaded(value: boolean) {\r\n this._loaded.next(value);\r\n }\r\n\r\n get runtimeUrlReader$(): Observable {\r\n return this.router.events.pipe(\r\n startWith(new NavigationEnd(0, this.router.url, this.router.url)),\r\n filter((e: any): e is NavigationEnd => e instanceof NavigationEnd),\r\n map((event: NavigationEnd) => event.url)\r\n );\r\n }\r\n\r\n componentLoader(rawUrl: string): Observable> {\r\n return of(rawUrl).pipe(\r\n map((rawUrl: string) => this.dynamicUtilsService.parseUrlToBeProcessable(rawUrl)),\r\n switchMap((url: string) => this.getPageMetadata(url)),\r\n tap(response => {\r\n if (response?.meta?.objectId) {\r\n this.elementService.objectId = response?.meta?.objectId\r\n }\r\n }),\r\n map((response: any) => response.meta),\r\n switchMap((metadata: MetaResponse) => this.getComponentByType(metadata?.type))\r\n );\r\n }\r\n\r\n private getComponentByType(type: string | undefined): Observable> {\r\n if (type) {\r\n const component: Nullable = this.getComponent(type);\r\n if (!component) {\r\n return throwError(`Not found component ${type}`);\r\n }\r\n return of(component);\r\n } else {\r\n return throwError(`Component's type is not provided: ${type}`);\r\n }\r\n }\r\n\r\n getPageMetadata(url: string): Observable {\r\n return this.apiService.get(`${API.DYNAMIC_CONTENT.ROOT}${url && url != ' ' ? '/' + url : ''}`);\r\n }\r\n\r\n private getComponent(module: string): Nullable {\r\n try {\r\n return COMPONENTS[module.toLowerCase()];\r\n } catch (e) {\r\n return null;\r\n }\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\n\r\n@Injectable()\r\nexport class DynamicUtilsService {\r\n parseUrlToBeProcessable(url: string): string {\r\n let parsed: string = url.split('/').join(',');\r\n return parsed === ',' ? '' : parsed;\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { BehaviorSubject, Observable } from 'rxjs';\r\nimport { Nullable } from '@share/common/types/utilities.types';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ElementService {\r\n private _objectId: BehaviorSubject> = new BehaviorSubject>(null);\r\n private _sameComponentNavigation: BehaviorSubject = new BehaviorSubject(false);\r\n\r\n public get getObjectId(): Observable> {\r\n return this._objectId.asObservable();\r\n }\r\n\r\n public get objectId(): Nullable {\r\n return this._objectId.getValue();\r\n }\r\n\r\n public set objectId(value: Nullable) {\r\n this._objectId.next(value);\r\n }\r\n\r\n public get sameComponentNavigation(): Observable {\r\n return this._sameComponentNavigation.asObservable();\r\n }\r\n\r\n public set loaded(value: boolean) {\r\n this._sameComponentNavigation.next(value);\r\n }\r\n\r\n}\r\n","import {\r\n ChangeDetectionStrategy,\r\n ChangeDetectorRef,\r\n Component,\r\n ElementRef,\r\n EventEmitter,\r\n Input,\r\n Output,\r\n Renderer2\r\n} from '@angular/core';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { MenuModel } from '@app/client-core/menu/models/menu.model';\r\nimport { MenuService } from '@app/client-core/menu/services/menu.service';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\n\r\n@Component({\r\n selector: 'app-default-menu',\r\n templateUrl: './default-menu.component.html',\r\n styleUrls: ['./default-menu.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class DefaultMenuComponent {\r\n @Input() menu: AbstractData[];\r\n @Input() isMenuWidthChecking: boolean;\r\n @Input() isLoading: boolean;\r\n\r\n @Output() refreshed: EventEmitter = new EventEmitter();\r\n\r\n getError: boolean;\r\n open: { [id: string]: boolean } = {};\r\n\r\n constructor(\r\n private menuService: MenuService,\r\n private facadeService: FacadeService,\r\n private renderer: Renderer2,\r\n private cdr: ChangeDetectorRef,\r\n private _elementRef: ElementRef\r\n ) {}\r\n\r\n onMouseOver(id: string) {\r\n this.open[id] = true;\r\n }\r\n\r\n hideSubmenu() {\r\n for(let key in this.open) {\r\n this.open[key] = false;\r\n }\r\n }\r\n\r\n onComponentRefresh() {\r\n this.refreshed.emit();\r\n }\r\n}\r\n","\r\n Menu główne\r\n \r\n \r\n \r\n \r\n 0\">\r\n \r\n {{ item.attributes.title }}\r\n \r\n\r\n 12 ? '60' : '30'\" [class.show]=\"open[item.id]\" [attr.aria-labelledby]=\"item.attributes.title\">\r\n \r\n \r\n \r\n \r\n {{ child.attributes.highlightedContent }}\r\n\r\n \r\n \r\n {{ child.attributes.title }}\r\n \r\n\r\n\r\n \r\n \r\n {{ child.attributes.title }}\r\n \r\n\r\n \r\n \r\n\r\n \r\n \r\n \r\n {{ child.attributes.title }}\r\n \r\n\r\n \r\n \r\n {{ child.attributes.title }}\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n {{ item.attributes.title }}\r\n \r\n\r\n \r\n {{ item.attributes.title }}\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import {\r\n AfterViewInit,\r\n ChangeDetectionStrategy,\r\n ChangeDetectorRef,\r\n Component,\r\n ElementRef,\r\n Input,\r\n OnDestroy,\r\n ViewChild\r\n} from '@angular/core';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { MenuModel } from '@app/client-core/menu/models/menu.model';\r\nimport { MenuService } from '@app/client-core/menu/services/menu.service';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { filter, takeUntil, tap } from 'rxjs/operators';\r\nimport { fromEvent, Subject } from 'rxjs';\r\n\r\ndeclare var $: any;\r\n\r\n@Component({\r\n selector: 'app-mobile-menu',\r\n templateUrl: 'mobile-menu.component.html',\r\n styleUrls: ['mobile-menu.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class MobileMenuComponent implements OnDestroy, AfterViewInit {\r\n private destroy$: Subject = new Subject();\r\n\r\n @Input() menu: AbstractData[];\r\n\r\n @ViewChild('sidebarMobile') sidebarMobile: ElementRef;\r\n\r\n getError: boolean;\r\n getLoading: boolean;\r\n open: boolean;\r\n shownComplete: boolean;\r\n\r\n constructor(private menuService: MenuService,\r\n private facadeService: FacadeService,\r\n private cdr: ChangeDetectorRef,\r\n private _elementRef: ElementRef) {}\r\n\r\n ngOnInit() {\r\n this.shownComplete = true;\r\n this.listenForServiceChange();\r\n this.handleOutsideClick();\r\n }\r\n\r\n ngOnDestroy() {\r\n this.destroy$.next(true);\r\n this.destroy$.complete();\r\n }\r\n\r\n listenForServiceChange() {\r\n this.menuService.isMobileMenuActive$.pipe(takeUntil(this.destroy$)).subscribe(isActive => {\r\n if (!isActive) {\r\n this.hide();\r\n }\r\n });\r\n }\r\n\r\n hide() {\r\n this.open = false;\r\n $('.navbar-collapse').collapse('hide');\r\n this.cdr.detectChanges();\r\n }\r\n\r\n toggleMenu() {\r\n if (this.shownComplete) {\r\n this.shownComplete = false;\r\n this.open = !this.open;\r\n }\r\n }\r\n\r\n ngAfterViewInit() {\r\n $('.navbar-collapse')\r\n .on('shown.bs.collapse', () => (this.shownComplete = true))\r\n .on('hidden.bs.collapse', () => (this.shownComplete = true))\r\n }\r\n\r\n setLoader(value: boolean) {\r\n this.getLoading = value;\r\n this.cdr.detectChanges();\r\n }\r\n\r\n parseId(id: string): string {\r\n return id.replace(/ /g,'')\r\n }\r\n\r\n handleOutsideClick() {\r\n const clickEvent$ = fromEvent(document, 'click');\r\n clickEvent$\r\n .pipe(\r\n takeUntil(this.destroy$),\r\n filter(e => !this._elementRef.nativeElement.contains(e.target)),\r\n tap(() => this.hide())\r\n )\r\n .subscribe();\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n 0; else defaultMenuItem\">\r\n {{ item.attributes.title }}\r\n \r\n \r\n \r\n \r\n\r\n \r\n\r\n \r\n {{\r\n item.attributes.title\r\n }}\r\n \r\n\r\n \r\n {{\r\n item.attributes.title\r\n }}\r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { HttpClientModule } from '@angular/common/http';\r\nimport { LogoModule } from '@app/template/layout/modules/logo/logo.module';\r\nimport { DefaultMenuComponent } from './components/default-menu/default-menu.component';\r\nimport { RouterModule } from '@angular/router';\r\nimport { PolygonModule } from '@app/template/elements/polygon/polygon.module';\r\nimport { MobileMenuComponent } from '@app/client-core/menu/components/mobile-menu/mobile-menu.component';\r\n\r\n@NgModule({\r\n declarations: [MobileMenuComponent, DefaultMenuComponent],\r\n imports: [CommonModule, HttpClientModule, RouterModule, ElementsModule, TranslatorModule, LogoModule, PolygonModule],\r\n exports: [DefaultMenuComponent, MobileMenuComponent]\r\n})\r\nexport class MenuModule {}\r\n","import { Injectable } from '@angular/core';\r\nimport { BehaviorSubject, Observable, of } from 'rxjs';\r\nimport { MenuModel } from '@app/client-core/menu/models/menu.model';\r\nimport { ResponseArray } from '@share/common/models/http';\r\nimport { API } from '@app/common/constants/api.directories';\r\nimport { ApiService } from '@app/common/services/api.service';\r\nimport { Router } from '@angular/router';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class MenuService {\r\n\r\n isMobileMenuActive$: BehaviorSubject = new BehaviorSubject(false);\r\n\r\n constructor(private apiService: ApiService, private router: Router) {\r\n }\r\n\r\n public getList(type?: string): Observable> {\r\n return this.apiService.getAll(`${API.MENU.ROOT}${type ? `/${type}` : ''}`);\r\n }\r\n\r\n public navigate(type: string, url: string): Promise {\r\n if (type === 'link') {\r\n return new Promise((resolve) => {\r\n window.open(url);\r\n resolve(true);\r\n });\r\n } else {\r\n if (!url || url.includes('null')) {\r\n return this.router.navigate(['/']);\r\n } else {\r\n return this.router.navigateByUrl('/' + url);\r\n }\r\n }\r\n }\r\n\r\n public isActive(url: string): boolean {\r\n return this.router.isActive(url, true);\r\n }\r\n\r\n}\r\n","import { ChangeDetectionStrategy, ChangeDetectorRef, Component, Inject, OnDestroy } from '@angular/core';\r\nimport { SUBHEADER_INJECTION_TOKEN } from '@app/client-core/search/subheader-injection-token';\r\nimport { Observable, Subject } from 'rxjs';\r\nimport { takeUntil } from 'rxjs/operators';\r\n\r\n@Component({\r\n selector: 'app-search-results-subheader',\r\n templateUrl: 'search-results-subheader.component.html',\r\n styleUrls: ['search-results-subheader.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class SearchResultsSubheaderComponent implements OnDestroy {\r\n private destroy$: Subject = new Subject();\r\n\r\n amount: number;\r\n keyword: string;\r\n\r\n constructor(\r\n @Inject(SUBHEADER_INJECTION_TOKEN) data: Observable<{ amount: number; keyword: string }>,\r\n private cdr: ChangeDetectorRef\r\n ) {\r\n data.pipe(takeUntil(this.destroy$)).subscribe(data => {\r\n this.amount = data.amount;\r\n this.keyword = data.keyword;\r\n this.cdr.detectChanges();\r\n });\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.destroy$.next(true);\r\n this.destroy$.complete();\r\n }\r\n}\r\n","\r\n {{ keyword }} - Wyniki wyszukiwania\r\n \r\n Znaleziono\r\n {{ amount || 0 }} wyników\r\n \r\n\r\n","import { ChangeDetectorRef, Component, Injector, OnDestroy, OnInit } from '@angular/core';\r\nimport { ActivatedRoute } from '@angular/router';\r\nimport { SearchService } from '@app/client-core/search/services/search.service';\r\nimport { SearchItem } from '@app/client-core/search/models/search-item.model';\r\nimport { SearchType } from '@app/template/layout/modules/header/interfaces/subheader-config.interface';\r\nimport { BreadcrumbsService } from '@app/template/layout/modules/header/services/breadcrumbs.service';\r\nimport { combineLatest } from 'rxjs/internal/observable/combineLatest';\r\nimport { finalize, first, map, takeUntil, tap } from 'rxjs/operators';\r\nimport { PaginationService } from '@app/template/elements/pagination/services/pagination.service';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { SearchResultsSubheaderComponent } from '@app/client-core/search/components/search-results-subheader/search-results-subheader.component';\r\nimport { Subject } from 'rxjs';\r\nimport { SearchHelperService } from '@app/client-core/search/search-helper.service';\r\nimport { SUBHEADER_INJECTION_TOKEN } from '@app/client-core/search/subheader-injection-token';\r\nimport { ResponseArray } from '@share/common/models/http';\r\n\r\n@Component({\r\n selector: 'app-search-results',\r\n templateUrl: './search-results.component.html',\r\n styleUrls: ['./search-results.component.scss']\r\n})\r\nexport class SearchResultsComponent implements OnInit, OnDestroy {\r\n searchedWord: string;\r\n data: { articles: SearchItem[]; pages: SearchItem[] } = { articles: [], pages: [] };\r\n type: SearchType;\r\n pages: number = 1;\r\n count: number = 20;\r\n getLoading: boolean;\r\n getError: boolean;\r\n destroyed$: Subject = new Subject();\r\n\r\n private searchMetadata: Subject<{ amount: number; keyword: string }> = new Subject<{\r\n amount: number;\r\n keyword: string;\r\n }>();\r\n\r\n constructor(\r\n private activatedRoute: ActivatedRoute,\r\n private searchService: SearchService,\r\n private breadcrumbsService: BreadcrumbsService,\r\n private paginationService: PaginationService,\r\n private facadeService: FacadeService,\r\n private injector: Injector,\r\n private searchHelperService: SearchHelperService,\r\n private cdr: ChangeDetectorRef\r\n ) {\r\n this.setSubheader();\r\n this.setBreadcrumbs();\r\n }\r\n\r\n private setSubheader() {\r\n this.facadeService.subheader.setConfig({\r\n component: SearchResultsSubheaderComponent,\r\n injector: Injector.create({\r\n providers: [\r\n {\r\n provide: SUBHEADER_INJECTION_TOKEN,\r\n useValue: this.searchMetadata\r\n }\r\n ],\r\n parent: this.injector\r\n })\r\n });\r\n this.facadeService.subheader.config.displayBreadcrumbs.next(true);\r\n }\r\n\r\n public ngOnInit() {\r\n this.setPageListener();\r\n window.scrollTo(0, 0);\r\n }\r\n\r\n setLoader(value: boolean) {\r\n this.getLoading = value;\r\n this.cdr.detectChanges();\r\n }\r\n\r\n public searchRequest(page: number) {\r\n this.clearData();\r\n this.setLoader(true);\r\n this.searchService\r\n .getFullList(this.searchedWord, this.type, page, this.count)\r\n .pipe(\r\n first(),\r\n tap(response => (this.searchService.amount = response.data.length)),\r\n finalize(() => this.setLoader(false))\r\n )\r\n .subscribe(response => this.onResponseSuccess(response));\r\n }\r\n\r\n onResponseSuccess(response: ResponseArray) {\r\n this.clearData();\r\n this.searchMetadata.next({ amount: response?.meta?.amount || 0, keyword: this.searchedWord });\r\n response.data?.forEach((item: any) => {\r\n if (item.type === 'Page') {\r\n this.data = { articles: [...this.data.articles], pages: [...this.data.pages, item] };\r\n } else if (item.type === 'CmsArticle') {\r\n this.data = { articles: [...this.data.articles, item], pages: [...this.data.pages] };\r\n }\r\n });\r\n const meta = response.meta;\r\n if (meta && typeof meta.pages === 'number') {\r\n this.pages = meta.pages;\r\n }\r\n }\r\n\r\n identify(index: number) {\r\n return index;\r\n }\r\n\r\n private clearData() {\r\n this.data = {\r\n articles: [],\r\n pages: []\r\n };\r\n }\r\n\r\n navigateTo(url: string, isExternal: boolean) {\r\n if (isExternal) {\r\n window.open(url);\r\n } else {\r\n this.facadeService.router.navigate([url]);\r\n }\r\n }\r\n\r\n private setBreadcrumbs() {\r\n this.breadcrumbsService.forceActive = true;\r\n this.breadcrumbsService.customBreadcrumbs = [{ title: this.facadeService.translator.trans('search.header') }];\r\n }\r\n\r\n private setPageListener() {\r\n combineLatest([this.activatedRoute.params, this.paginationService.currentPage])\r\n .pipe(\r\n map(results => ({ data: results[0].data, page: results[1] })),\r\n takeUntil(this.destroyed$)\r\n )\r\n .subscribe(results => {\r\n this.searchedWord = results.data;\r\n this.searchRequest(results.page);\r\n });\r\n }\r\n\r\n ngOnDestroy() {\r\n this.destroyed$.next(true);\r\n this.destroyed$.complete();\r\n this.breadcrumbsService.forceActive = false;\r\n }\r\n}\r\n","\r\n \r\n \r\n 0\">\r\n Artykuły\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n 0\">\r\n Strony\r\n \r\n {{ item.attributes.content }}\r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { ChangeDetectorRef, Component, ElementRef, Input, OnDestroy, OnInit, ViewChild } from '@angular/core';\r\nimport { SearchService } from '@app/client-core/search/services/search.service';\r\nimport { SearchItem } from '@app/client-core/search/models/search-item.model';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { NavigationExtras } from '@angular/router';\r\nimport { SearchType } from '@app/template/layout/modules/header/interfaces/subheader-config.interface';\r\nimport { fromEvent, Observable, Subject } from 'rxjs';\r\nimport { filter, finalize, first, takeUntil, tap } from 'rxjs/operators';\r\nimport { UtilsService } from '@share/common/services/utils.service';\r\nimport { SelectModel } from '@share/modules/html/common/interfaces/select-model.interface';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { ThemesEnum } from '@app/common/models/themes.enum';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { ResizeListener } from '@app/common/services/resize-listener.service';\r\n\r\n@Component({\r\n selector: 'app-search',\r\n templateUrl: './search.component.html',\r\n styleUrls: ['./search.component.scss']\r\n})\r\nexport class SearchComponent implements OnInit, OnDestroy {\r\n\r\n private _value = '';\r\n private readonly minLength: number = 3;\r\n private destroy$: Subject = new Subject();\r\n\r\n @ViewChild('input') input: ElementRef;\r\n @Input() mobile: boolean;\r\n @Input() placeholder: string = 'search.button';\r\n\r\n data: { articles: SearchItem[]; pages: SearchItem[] } = { articles: [], pages: [] };\r\n availablesTypes: Array> = [];\r\n type: SearchType = SearchType.Default;\r\n searchSelectId: string;\r\n searchId: string;\r\n showResultsBox: boolean;\r\n loading: boolean;\r\n error: boolean;\r\n forceActive: boolean;\r\n isActive$: Observable;\r\n\r\n\r\n constructor(\r\n private searchService: SearchService,\r\n private _elementRef: ElementRef,\r\n private utils: UtilsService,\r\n private settingsService: SettingsService,\r\n private cdr: ChangeDetectorRef,\r\n private facadeService: FacadeService,\r\n ) {\r\n this.availablesTypes = this.searchService.getAvailableSearchTypes();\r\n const newId: string = this.utils.makeId();\r\n this.searchSelectId = `search-type-${newId}`;\r\n this.searchId = `search-input-${newId}`;\r\n }\r\n\r\n markAsActive() {\r\n this.searchService.isActive$.next(true);\r\n setTimeout(() => {\r\n this.forceActive = true;\r\n this.input.nativeElement.focus();\r\n }, 500)\r\n }\r\n\r\n markAsInactive(){\r\n this.searchService.isActive$.next(false);\r\n this.forceActive = false;\r\n this.showResultsBox = false;\r\n }\r\n\r\n onValueChange(value: string) {\r\n if (value.length >= 3) {\r\n this.showResultsBox = true;\r\n this.searchRequest(value);\r\n } else {\r\n this.showResultsBox = false;\r\n }\r\n this.value = value;\r\n }\r\n\r\n ngOnInit() {\r\n this.setSearchType();\r\n this.handleOutsideClick();\r\n this.isActive$ = this.searchService.isActive$;\r\n }\r\n\r\n private setSearchType() {\r\n this.facadeService.subheader.getConfig().subscribe(config => {\r\n this.type = config.searchType || SearchType.Default;\r\n });\r\n }\r\n\r\n handleOutsideClick() {\r\n const clickEvent$ = fromEvent(document, 'click');\r\n clickEvent$\r\n .pipe(\r\n takeUntil(this.destroy$),\r\n filter(e => !this._elementRef.nativeElement.contains(e.target)),\r\n tap(e => {\r\n this.clear();\r\n this.markAsInactive();\r\n })\r\n )\r\n .subscribe();\r\n }\r\n\r\n get value() {\r\n return this._value;\r\n }\r\n\r\n set value(data: string) {\r\n this._value = data;\r\n }\r\n\r\n hasMinLength(value: string) {\r\n const valid = value.length >= this.minLength;\r\n if (!valid) {\r\n this.clearData();\r\n }\r\n return valid;\r\n }\r\n\r\n search() {\r\n if (this.hasMinLength(this.value)) {\r\n this.markAsInactive();\r\n this.facadeService.router.navigate(['search', this._value], this.getNavigationExtras()).then(onfulfilled => {\r\n if (onfulfilled) {\r\n this.clear();\r\n }\r\n });\r\n }\r\n }\r\n\r\n private getNavigationExtras() {\r\n const extra: NavigationExtras = { queryParams: null };\r\n if (this.type !== SearchType.Default) {\r\n extra.queryParams = { type: this.type };\r\n }\r\n return extra;\r\n }\r\n\r\n setLoader(value: boolean) {\r\n this.loading = value;\r\n this.cdr.detectChanges();\r\n }\r\n\r\n searchRequest(value: string) {\r\n this.setLoader(true);\r\n this.clearData();\r\n this.searchService\r\n .getList(value, this.type)\r\n .pipe(\r\n first(),\r\n finalize(() => this.setLoader(false))\r\n )\r\n .subscribe(response => {\r\n this.clearData();\r\n response.data?.forEach((item: any) => {\r\n if (item.type === 'Page') {\r\n this.data = { articles: [...this.data.articles], pages: [...this.data.pages, item] };\r\n } else if (item.type === 'CmsArticle') {\r\n this.data = { articles: [...this.data.articles, item], pages: [...this.data.pages] };\r\n }\r\n });\r\n });\r\n }\r\n\r\n private clear() {\r\n this._value = '';\r\n this.clearData();\r\n this.showResultsBox = false;\r\n }\r\n\r\n private clearData() {\r\n this.data = {\r\n articles: [],\r\n pages: []\r\n }\r\n }\r\n\r\n ngOnDestroy() {\r\n this.destroy$.next(true);\r\n this.destroy$.complete();\r\n }\r\n}\r\n","\r\n \r\n {{'search.searchLabel' | trans}}\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n 0 || data.articles.length > 0\" [error]=\"error\">\r\n \r\n 0\">\r\n {{'search.pages' | trans}}\r\n \r\n {{ item.attributes.title }}\r\n \r\n \r\n\r\n 0\">\r\n {{'search.articles' | trans}}\r\n \r\n {{ item.attributes.title }}\r\n \r\n \r\n \r\n\r\n \r\n {{'search.noData' | trans}}\r\n \r\n \r\n \r\n\r\n","import { Injectable } from '@angular/core';\r\nimport { BehaviorSubject, forkJoin, Observable } from 'rxjs';\r\n\r\n@Injectable()\r\nexport class SearchHelperService {\r\n amount: BehaviorSubject = new BehaviorSubject(0);\r\n keyword: BehaviorSubject = new BehaviorSubject('');\r\n\r\n getData(): Observable<{ amount: number; keyword: string }> {\r\n return forkJoin({ amount: this.amount, keyword: this.keyword });\r\n }\r\n}\r\n","import {NgModule} from '@angular/core';\r\nimport {CommonModule} from '@angular/common';\r\nimport {SearchComponent} from './components/search/search.component';\r\nimport {FormsModule} from '@angular/forms';\r\nimport {ElementsModule} from '@share/modules/elements/elements.module';\r\nimport {SearchResultsComponent} from './components/search-results/search-results.component';\r\nimport {TranslatorModule} from '@share/modules/translator/translator.module';\r\nimport {NgbPaginationModule} from '@ng-bootstrap/ng-bootstrap';\r\nimport {ContainerModule} from '@app/template/layout/modules/container/container.module';\r\nimport {SelectModule} from '@share/modules/html/select/select.module';\r\nimport { PaginationModule } from '@app/template/elements/pagination/pagination.module';\r\nimport { PaginationService } from '@app/template/elements/pagination/services/pagination.service';\r\nimport { RouterModule } from '@angular/router';\r\nimport { SearchResultsSubheaderComponent } from '@app/client-core/search/components/search-results-subheader/search-results-subheader.component';\r\nimport { ArticleModule } from '@app/client-core/article/article.module';\r\nimport { SearchHelperService } from '@app/client-core/search/search-helper.service';\r\n\r\n@NgModule({\r\n declarations: [SearchComponent, SearchResultsComponent, SearchResultsSubheaderComponent],\r\n imports: [\r\n CommonModule,\r\n FormsModule,\r\n ElementsModule,\r\n TranslatorModule,\r\n NgbPaginationModule,\r\n ContainerModule,\r\n SelectModule,\r\n PaginationModule,\r\n RouterModule,\r\n ArticleModule,\r\n ],\r\n exports: [\r\n SearchComponent,\r\n SearchResultsComponent\r\n ],\r\n providers: [\r\n PaginationService,\r\n SearchHelperService\r\n ]\r\n})\r\nexport class SearchModule {}\r\n","import {Injectable} from '@angular/core';\r\nimport {ServiceHelper} from '@share/common/helpers/service.helper';\r\nimport {API} from '@app/common/constants/api.directories';\r\nimport { BehaviorSubject, Observable } from 'rxjs';\r\nimport {SearchType, SearchTypeNames} from '@app/template/layout/modules/header/interfaces/subheader-config.interface';\r\nimport {HttpParams} from '@angular/common/http';\r\nimport {AbstractData} from '@share/common/models/http.model';\r\nimport {SelectModel} from '@share/modules/html/common/interfaces/select-model.interface';\r\nimport {Bundle} from '@app/common/enums/server-bundles.enum';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class SearchService extends ServiceHelper {\r\n\r\n amount: number = 0;\r\n isActive$: BehaviorSubject = new BehaviorSubject(false);\r\n\r\n constructor() {\r\n super('');\r\n }\r\n\r\n public getList(keyword: string, searchType: SearchType): Observable {\r\n let params: HttpParams = new HttpParams().set('contains', keyword);\r\n\r\n if (!!searchType) {\r\n params = params.set('inside', searchType);\r\n }\r\n\r\n return this.getAll(API.SEARCH.ROOT, {http: {params}});\r\n }\r\n\r\n public getFullList(keyword: string, searchType: SearchType, page: number, count: number): Observable {\r\n let params: HttpParams = new HttpParams();\r\n\r\n params = params.set('page', page.toString());\r\n params = params.set('count', count.toString());\r\n params = params.set('contains', keyword);\r\n\r\n if (!!searchType) {\r\n params = params.set('inside', searchType);\r\n }\r\n\r\n return this.getAll(API.SEARCH.FULL, {http: {params}});\r\n }\r\n\r\n public getAvailableSearchTypes(): Array> {\r\n return [\r\n {\r\n id: SearchType.Default,\r\n type: Bundle.Alert,\r\n attributes: {\r\n title: SearchTypeNames.Default\r\n }\r\n },\r\n {\r\n id: SearchType.EServices,\r\n type: Bundle.Alert,\r\n attributes: {\r\n title: SearchTypeNames.EServices\r\n }\r\n }\r\n ];\r\n }\r\n}\r\n","import { InjectionToken } from '@angular/core';\r\n\r\nexport const SUBHEADER_INJECTION_TOKEN = new InjectionToken('SUBHEADER_INJECTION_TOKEN');\r\n","export { StaticPageComponent } from './static-page/static-page.component';\r\nexport { StaticPageDefaultComponent } from './static-page-default/static-page-default.component';\r\nexport { StaticPageContactComponent } from './static-page-contact/static-page-contact.component';\r\nexport { ContactFormComponent } from './static-page-contact/contact-form/contact-form.component';\r\nexport { ContactImagesComponent } from './static-page-contact/contact-images/contact-images.component';\r\nexport { ContactSubheaderComponent } from './static-page-contact/contact-subheader/contact-subheader.component';\r\nexport { SchedulePageComponent } from './schedule-page/schedule-page.component';\r\n","import { ChangeDetectionStrategy, Component, Input } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'app-schedule-page',\r\n templateUrl: 'schedule-page.component.html',\r\n styleUrls: ['schedule-page.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class SchedulePageComponent {\r\n @Input() data: {\r\n content: {\r\n boxPhone: string;\r\n boxSchedule: string;\r\n boxTitle: string;\r\n boxSubtitle: string;\r\n subtitle: string;\r\n schedule: {date: string, cities: string}[];\r\n };\r\n };\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n {{ boxTitle }}\r\n \r\n \r\n {{ boxSubtitle }}\r\n \r\n \r\n \r\n {{ boxPhone }}\r\n \r\n \r\n\r\n\r\n\r\n \r\n {{ title }}\r\n {{ content }}\r\n \r\n\r\n","import { Observable } from 'rxjs';\r\nimport { ResponseArray } from '@share/common/models/http';\r\nimport { API } from '@app/common/constants/api.directories';\r\nimport { ApiService } from '@app/common/services/api.service';\r\nimport { Injectable } from '@angular/core';\r\n\r\n@Injectable({ providedIn: 'root' })\r\nexport class ConsentsService {\r\n constructor(private apiService: ApiService) {}\r\n\r\n getList(name: string = ''): Observable> {\r\n return this.apiService.getAll(`${API.AUTH.CONSENTS}/${name}`);\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'app-contact-dots',\r\n templateUrl: 'contact-dots.component.html',\r\n styleUrls: ['contact-dots.component.scss']\r\n})\r\nexport class ContactDotsComponent {}\r\n","\r\n \r\n\r\n","import { AfterViewInit, ChangeDetectionStrategy, ChangeDetectorRef, Component, Input, OnDestroy, OnInit } from '@angular/core';\r\nimport { FormBuilder, FormGroup } from '@angular/forms';\r\nimport { CaptchaV3Service } from '@app/common/services/captcha-v3.service';\r\nimport { ConsentsService } from '@app/client-core/static-pages/components/static-page-contact/consents.service';\r\nimport { finalize, first } from 'rxjs/operators';\r\nimport { getContactFormGroup } from '@app/client-core/static-pages/components/static-page-contact/contact-form/form/contact-form.group';\r\nimport { getContactFormConfig } from '@app/client-core/static-pages/components/static-page-contact/contact-form/form/contact-form.config';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { ContactService } from '@app/client-core/static-pages/components/static-page-contact/contact.service';\r\n\r\n@Component({\r\n selector: 'app-contact-form',\r\n templateUrl: 'contact-form.component.html',\r\n styleUrls: ['contact-form.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class ContactFormComponent implements OnInit, OnDestroy, AfterViewInit {\r\n formGroup: FormGroup;\r\n formConfig: { [id: string]: any };\r\n consentLoader: boolean;\r\n sendLoader: boolean;\r\n\r\n @Input() title: string;\r\n @Input() subtitle: string;\r\n\r\n constructor(\r\n private formBuilder: FormBuilder,\r\n private captchaService: CaptchaV3Service,\r\n private consentService: ConsentsService,\r\n private cdr: ChangeDetectorRef,\r\n private facadeService: FacadeService,\r\n private contactService: ContactService\r\n ) {\r\n this.initFormGroup();\r\n }\r\n\r\n private initFormGroup() {\r\n this.formGroup = this.formBuilder.group(getContactFormGroup());\r\n this.formConfig = getContactFormConfig(this.facadeService.translator);\r\n }\r\n\r\n ngOnInit() {\r\n this.captchaService.load();\r\n this.getConsents();\r\n }\r\n\r\n getConsents() {\r\n this.consentLoader = true;\r\n this.cdr.detectChanges();\r\n this.consentService\r\n .getList('contact')\r\n .pipe(\r\n first(),\r\n finalize(() => {\r\n this.consentLoader = false;\r\n this.cdr.detectChanges();\r\n })\r\n )\r\n .subscribe(response => {\r\n const [first] = response.data;\r\n this.setConsentConfig(first.id, first.attributes.fulltext);\r\n });\r\n }\r\n\r\n setConsentConfig(id: string, label: string) {\r\n this.formConfig.consent = {\r\n id: id,\r\n label: label,\r\n allowHtmlLabel: true\r\n };\r\n }\r\n\r\n ngAfterViewInit() {\r\n this.captchaService.toggleVisibility();\r\n }\r\n\r\n onSubmit() {\r\n this.sendLoader = true;\r\n this.cdr.detectChanges();\r\n this.captchaService.execute()\r\n .pipe(\r\n first()\r\n )\r\n .subscribe(\r\n token => {\r\n this.formGroup.patchValue({ captcha: token });\r\n this.sendForm();\r\n },\r\n () => {\r\n this.facadeService.toastr.error(this.facadeService.trans('contact.form.captchaError'));\r\n this.sendLoader = false;\r\n this.cdr.detectChanges();\r\n }\r\n );\r\n }\r\n\r\n sendForm() {\r\n this.contactService\r\n .submit(this.formGroup.getRawValue())\r\n .pipe(\r\n first(),\r\n finalize(() => {\r\n this.sendLoader = false;\r\n this.cdr.detectChanges();\r\n })\r\n )\r\n .subscribe(\r\n () => {\r\n this.facadeService.toastr.success(this.facadeService.translator.trans('contact.form.successMessage'));\r\n this.formGroup.reset();\r\n },\r\n );\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.captchaService.toggleVisibility(false);\r\n }\r\n}\r\n","\r\n {{ title }}\r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n\r\n\r\n","import { InputTypeEnum } from '@share/modules/html/input/enums/input-types.enum';\r\nimport { TranslatorService } from '@share/common/services/translator.service';\r\n\r\nexport function getContactFormConfig(translatorService: TranslatorService): { [id: string]: any } {\r\n return {\r\n senderName: {\r\n id: 'senderName',\r\n type: InputTypeEnum.Text,\r\n label: translatorService.trans('contact.form.name')\r\n },\r\n senderEmail: {\r\n id: 'senderEmail',\r\n type: InputTypeEnum.Text,\r\n label: translatorService.trans('contact.form.email')\r\n },\r\n content: {\r\n id: 'content',\r\n type: InputTypeEnum.Text,\r\n label: translatorService.trans('contact.form.message')\r\n }\r\n };\r\n}\r\n","import { Validators } from '@angular/forms';\r\n\r\nexport function getContactFormGroup(): { [id: string]: any } {\r\n return {\r\n senderName: ['', Validators.required],\r\n senderEmail: ['', Validators.required],\r\n content: ['', Validators.required],\r\n dataProcessConsent: [false, Validators.requiredTrue],\r\n captcha: ['', Validators.required]\r\n };\r\n}\r\n","import { Component, Input } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'app-contact-images',\r\n templateUrl: 'contact-images.component.html',\r\n styleUrls: ['contact-images.component.scss']\r\n})\r\nexport class ContactImagesComponent {\r\n @Input() biggerImageUrl: string;\r\n @Input() smallerImageUrl: string;\r\n\r\n @Input() isRight: boolean;\r\n @Input() special: boolean;\r\n @Input() smallUp: boolean;\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n\r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { InstitutionService } from '@app/common/services/institution.service';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { first } from 'rxjs/operators';\r\nimport { Institution } from '@app/common/models/institution.model';\r\n\r\n@Component({\r\n selector: 'app-contact-subheader',\r\n templateUrl: 'contact-subheader.component.html',\r\n styleUrls: ['contact-subheader.component.scss']\r\n})\r\nexport class ContactSubheaderComponent implements OnInit {\r\n\r\n institution: AbstractData;\r\n\r\n constructor(private institutionService: InstitutionService) {}\r\n\r\n ngOnInit() {\r\n this.getInstitutionData();\r\n }\r\n\r\n getInstitutionData() {\r\n this.institutionService\r\n .getCurrent()\r\n .pipe(\r\n first()\r\n )\r\n .subscribe(response => this.institution = response.data)\r\n }\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n Dane kontaktowe\r\n \r\n {{institution.attributes.name}}\r\n {{institution.attributes.address.zipCode}} {{institution.attributes.address.city}} \r\n {{institution.attributes.address.street}} {{institution.attributes.address.houseNumber}}\r\n tel.: {{institution.attributes.contact.phoneNumber}}\r\n {{institution.attributes.contact.email}}\r\n \r\n \r\n\r\n","import { Injectable } from '@angular/core';\r\nimport { Observable } from 'rxjs';\r\nimport { ApiService } from '@app/common/services/api.service';\r\nimport { API } from '@app/common/constants/api.directories';\r\n\r\n@Injectable({providedIn: 'root'})\r\nexport class ContactService {\r\n\r\n constructor(private apiService: ApiService) {\r\n }\r\n\r\n public submit(contact: any): Observable {\r\n return this.apiService.post('contact', contact);\r\n }\r\n}\r\n","import { ChangeDetectionStrategy, Component, Input } from '@angular/core';\r\nimport { ImageCropper } from '@app/template/home/models/image-cropper.model';\r\n\r\n@Component({\r\n selector: 'app-static-page-contact-department',\r\n templateUrl: 'static-page-contact-department.component.html',\r\n styleUrls: ['static-page-contact-department.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class StaticPageContactDepartmentComponent {\r\n\r\n @Input() rightImage: boolean;\r\n @Input() special: boolean;\r\n @Input() specialTwo: boolean;\r\n @Input() smallUp: boolean;\r\n\r\n @Input() data: {\r\n title: string;\r\n bigImage: ImageCropper;\r\n smallImage: ImageCropper;\r\n people: {\r\n personOrPlace: string;\r\n contact: {\r\n type: 'phone' | 'email';\r\n value: string;\r\n extra: string | null;\r\n }[];\r\n }[];\r\n };\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n {{ data.title }}\r\n \r\n \r\n \r\n \r\n \r\n\r\n\r\n\r\n \r\n {{person.description}}\r\n {{person.fullName}} - {{person?.scope}}\r\n \r\n \r\n Numer telefonu\r\n \r\n {{ contact.value }}\r\n wew. {{ contact.extra }}\r\n \r\n\r\n \r\n Email\r\n \r\n {{ contact.value }}\r\n \r\n \r\n \r\n\r\n","import { Component, Input } from '@angular/core';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { ContactSubheaderComponent } from '@app/client-core/static-pages/components/static-page-contact/contact-subheader/contact-subheader.component';\r\n\r\n@Component({\r\n selector: 'app-static-page-contact',\r\n templateUrl: './static-page-contact.component.html',\r\n styleUrls: ['./static-page-contact.component.scss']\r\n})\r\nexport class StaticPageContactComponent {\r\n @Input() data: {\r\n sectionOne: any,\r\n sectionTwo: any,\r\n sectionThree: any,\r\n sectionFour: any\r\n };\r\n\r\n constructor(private facadeService: FacadeService) {\r\n this.facadeService.subheader.setConfig({\r\n component: ContactSubheaderComponent,\r\n hideDots: true\r\n });\r\n this.facadeService.subheader.displayBreadcrumbs = false;\r\n }\r\n}\r\n","\r\n\r\n\r\n \r\n \r\n {{ data.sectionThree.title }}\r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n = 3\">\r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { Component, Input } from '@angular/core';\r\nimport { StaticPageDefaultModel } from '@app/client-core/static-pages/model/static-page-default.model';\r\n\r\n@Component({\r\n selector: 'app-static-page-default',\r\n templateUrl: './static-page-default.component.html',\r\n styleUrls: ['./static-page-default.component.scss']\r\n})\r\nexport class StaticPageDefaultComponent {\r\n @Input() data: StaticPageDefaultModel;\r\n\r\n getFileUrl() {\r\n // TODO: Poprawić typy\r\n if (this.data.file?.hasOwnProperty('url')) {\r\n return this.data.file['croppedImage'] || this.data?.file['url'];\r\n }\r\n return this.getFileAsString();\r\n }\r\n\r\n private getFileAsString(): string | null {\r\n if (typeof this.data?.file === 'string') {\r\n return this.data?.file;\r\n }\r\n return null;\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { Component, Input, OnDestroy, OnInit } from '@angular/core';\r\nimport { SubheaderService } from '@app/template/layout/modules/header/services/subheader.service';\r\nimport { ElementService } from '@app/client-core/dynamic-content/service/element.service';\r\nimport { ActivatedRoute, Router } from '@angular/router';\r\nimport { UrlService } from '@app/common/services/url.service';\r\nimport { finalize, first, takeUntil } from 'rxjs/operators';\r\nimport { AbstractData, ResponseObject } from '@share/common/models/http';\r\nimport { PagesService } from '@app/common/services/pages.service';\r\nimport { PageModel } from '@app/common/models/page.model';\r\nimport { ReplaySubject } from 'rxjs';\r\nimport { HistoryService } from '@share/common/services/history.service';\r\nimport { StaticPage } from '@app/client-core/static-pages/model/static-pages.model';\r\nimport { Nullable } from '@share/common/types/utilities.types';\r\n\r\n@Component({\r\n selector: 'app-static-page',\r\n templateUrl: './static-page.component.html',\r\n styleUrls: ['./static-page.component.scss']\r\n})\r\nexport class StaticPageComponent implements OnInit, OnDestroy {\r\n @Input() page: Nullable>>>;\r\n\r\n private destroyed$: ReplaySubject = new ReplaySubject(1);\r\n getError: boolean;\r\n getLoading: boolean;\r\n\r\n constructor(\r\n protected pagesService: PagesService,\r\n protected subheaderService: SubheaderService,\r\n private elementService: ElementService,\r\n protected route: ActivatedRoute,\r\n private urlService: UrlService,\r\n private historyService: HistoryService,\r\n private router: Router\r\n ) {}\r\n\r\n private setListener() {\r\n this.elementService.sameComponentNavigation.pipe(takeUntil(this.destroyed$)).subscribe(same => {\r\n if (same) {\r\n this.loadPage();\r\n }\r\n });\r\n }\r\n\r\n ngOnInit() {\r\n this.setListener();\r\n if (!this.page) {\r\n this.loadPage();\r\n } else {\r\n this.setSubheader(this.page);\r\n }\r\n }\r\n\r\n protected onLoadPageSuccess(response: ResponseObject>>) {\r\n this.page = response.data;\r\n this.setSubheader(this.page);\r\n }\r\n\r\n private setSubheader(page: AbstractData>>) {\r\n this.subheaderService.setConfig({ title: page.attributes.title, publishedDate: page.attributes.publishedFrom });\r\n if (page.attributes.content?.pageType === 'schedule') {\r\n this.subheaderService.description = page?.attributes?.content?.content?.subtitle;\r\n this.subheaderService.publishedDate = '';\r\n }\r\n this.subheaderService.config.displayBreadcrumbs.next(true);\r\n }\r\n\r\n loadPage() {\r\n this.getLoading = true;\r\n this.pagesService\r\n .getOne(this.router.url.split('/').join(','))\r\n .pipe(\r\n first(),\r\n finalize(() => (this.getLoading = false))\r\n )\r\n .subscribe(\r\n response => this.onLoadPageSuccess(response),\r\n error => {\r\n this.subheaderService.setConfig({\r\n title: error.error.errors[0].status\r\n });\r\n this.subheaderService.description = error.error.errors[0].title;\r\n this.page = null;\r\n }\r\n );\r\n }\r\n\r\n ngOnDestroy() {\r\n this.destroyed$.next(true);\r\n this.destroyed$.complete();\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { RouterModule } from '@angular/router';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { ContainerModule } from '@app/template/layout/modules/container/container.module';\r\nimport { GoogleMapModule } from '@share/modules/google-map/google-map.module';\r\nimport {\r\n ContactFormComponent,\r\n StaticPageComponent,\r\n StaticPageContactComponent,\r\n StaticPageDefaultComponent,\r\n ContactImagesComponent,\r\n ContactSubheaderComponent,\r\n SchedulePageComponent\r\n} from '@app/client-core/static-pages/components';\r\nimport { ArticleModule } from '@app/client-core/article/article.module';\r\nimport { SimpleBoxModule } from '@app/template/elements/simple-box/simple-box.module';\r\nimport { ReactiveFormsModule } from '@angular/forms';\r\nimport { CheckboxModule } from '@share/modules/html/checkbox/checkbox.module';\r\nimport { InputModule } from '@app/template/elements/input/input.module';\r\nimport { TextareaModule } from '@app/template/elements/textarea/textarea.module';\r\nimport { HeaderModule } from '@app/template/layout/modules/header/header.module';\r\nimport { StaticPageContactDepartmentComponent } from '@app/client-core/static-pages/components/static-page-contact/static-page-contact-department/static-page-contact-department.component';\r\nimport { ContactDotsComponent } from '@app/client-core/static-pages/components/static-page-contact/contact-dots/contact-dots.component';\r\nimport { BreadcrumbsModule } from '@app/template/layout/modules/breadcrumbs/breadcrumbs.module';\r\n\r\n@NgModule({\r\n declarations: [\r\n SchedulePageComponent,\r\n StaticPageContactDepartmentComponent,\r\n ContactImagesComponent,\r\n ContactSubheaderComponent,\r\n ContactFormComponent,\r\n StaticPageComponent,\r\n StaticPageDefaultComponent,\r\n StaticPageContactComponent,\r\n ContactDotsComponent\r\n ],\r\n imports: [\r\n CommonModule,\r\n RouterModule,\r\n ElementsModule,\r\n TranslatorModule,\r\n ContainerModule,\r\n GoogleMapModule,\r\n ArticleModule,\r\n SimpleBoxModule,\r\n ReactiveFormsModule,\r\n CheckboxModule,\r\n InputModule,\r\n TextareaModule,\r\n HeaderModule,\r\n BreadcrumbsModule\r\n ],\r\n exports: [StaticPageComponent]\r\n})\r\nexport class StaticPagesModule {}\r\n","import { AppConfigCMS } from '@share/common/interfaces/app-config.interface';\r\n\r\ndeclare const APP_CONFIG: AppConfigCMS;\r\nexport const URL = APP_CONFIG.API_URL;\r\nconst PREFIX = APP_CONFIG.PREFIX;\r\nconst SERVER = `${URL}/${PREFIX}`;\r\n\r\nexport const API = {\r\n AUTH: {\r\n LOGIN: `${SERVER}/login`,\r\n LOGOUT: `${SERVER}/logout`,\r\n CONSENTS: `${SERVER}/consents`,\r\n FORGOT_PASSWORD: `${SERVER}/account/resetPassword/sendEmail`,\r\n VALIDATE_TOKEN: `${SERVER}/account/resetPassword/checkToken`,\r\n CHANGE_PASSWORD: `${SERVER}/account/resetPassword/change`,\r\n ACTIVATE_ACCOUNT: `${SERVER}/account/confirm`\r\n },\r\n COMMON: {\r\n BREADCRUMBS: `${SERVER}/breadcrumbs`\r\n },\r\n ARTICLES: {\r\n ROOT: `${SERVER}/articles`,\r\n RANDOM: `${SERVER}/articles/random`\r\n },\r\n SETTINGS: {\r\n ROOT: `${SERVER}/settings/bootstrap`,\r\n GET_LAYOUT: `${SERVER}/settings/layout`\r\n },\r\n SEARCH: {\r\n ROOT: `${SERVER}/search/autocomplete`,\r\n FULL: `${SERVER}/search/getResult`\r\n },\r\n PROMOTED: {\r\n ROOT: `${SERVER}/promoted`\r\n },\r\n BANNERS: {\r\n ROOT: `${SERVER}/banners`\r\n },\r\n MENU: {\r\n ROOT: `${SERVER}/menu`,\r\n SITEMAP: `${SERVER}/menu/sitemap`\r\n },\r\n DYNAMIC_CONTENT: {\r\n ROOT: `${SERVER}/search/getMetadata`\r\n },\r\n CATEGORY: {\r\n ROOT: `${SERVER}/categories`\r\n },\r\n PROFILE: {\r\n ROOT: `${SERVER}/account`\r\n },\r\n ALERTS: {\r\n ROOT: `${SERVER}/alerts`\r\n },\r\n BUSINESS_MODULES: {\r\n ROOT: `${SERVER}/businessModules`,\r\n },\r\n PAGES: {\r\n ROOT: `${SERVER}/pages`\r\n },\r\n PREVIEW: {\r\n ROOT: `${SERVER}/preview`\r\n },\r\n INSTITUTION: {\r\n ROOT: 'institution'\r\n },\r\n ASSETS: {\r\n DEFAULT_SETTINGS: 'source/default_settings.json'\r\n }\r\n};\r\n","import { APP_INITIALIZER, LOCALE_ID, Provider } from '@angular/core';\r\nimport { HTTP_INTERCEPTORS } from '@angular/common/http';\r\nimport { BootstrapService } from '@app/common/services/bootstrap.service';\r\nimport {\r\n getBackendVersionFactory,\r\n getFrontendVersionFactory,\r\n getLanguageFactory,\r\n getMaintenanceFactory,\r\n getPermissions,\r\n getSettingsFactory,\r\n getTranslationsFactory\r\n} from '@app/common/functions/bootstrap';\r\nimport { LanguageService } from '@share/common/services/language.service';\r\nimport { InstitutionInterceptorService } from '@app/common/interceptors/institution-interceptor.service';\r\nimport { ContentInterceptorService } from '@app/common/interceptors/content-interceptor.service';\r\nimport { ApiInterceptorService } from '@app/common/interceptors/api-interceptor.service';\r\n\r\nexport const BOOTSTRAP_PROVIDERS: Provider[] = [\r\n {\r\n provide: HTTP_INTERCEPTORS,\r\n useClass: ApiInterceptorService,\r\n multi: true\r\n },\r\n {\r\n provide: HTTP_INTERCEPTORS,\r\n useClass: ContentInterceptorService,\r\n multi: true\r\n },\r\n {\r\n provide: HTTP_INTERCEPTORS,\r\n useClass: InstitutionInterceptorService,\r\n multi: true\r\n },\r\n {\r\n provide: LOCALE_ID,\r\n deps: [LanguageService],\r\n useFactory: getLanguageFactory\r\n },\r\n {\r\n provide: APP_INITIALIZER,\r\n useFactory: getTranslationsFactory,\r\n deps: [BootstrapService],\r\n multi: true\r\n },\r\n {\r\n provide: APP_INITIALIZER,\r\n useFactory: getMaintenanceFactory,\r\n deps: [BootstrapService],\r\n multi: true\r\n },\r\n {\r\n provide: APP_INITIALIZER,\r\n useFactory: getSettingsFactory,\r\n deps: [BootstrapService],\r\n multi: true\r\n },\r\n {\r\n provide: APP_INITIALIZER,\r\n useFactory: getBackendVersionFactory,\r\n deps: [BootstrapService],\r\n multi: true\r\n },\r\n {\r\n provide: APP_INITIALIZER,\r\n useFactory: getFrontendVersionFactory,\r\n deps: [BootstrapService],\r\n multi: true\r\n }\r\n];\r\n","import {HAMMER_GESTURE_CONFIG, HammerGestureConfig} from '@angular/platform-browser';\r\nimport {Injectable, Provider} from '@angular/core';\r\nimport * as Hammer from 'hammerjs';\r\n\r\n@Injectable()\r\nexport class MyHammerConfig extends HammerGestureConfig {\r\n buildHammer(element: HTMLElement) {\r\n return new Hammer(element, {\r\n touchAction: 'pan-y pan-x'\r\n });\r\n }\r\n}\r\n\r\nexport const HAMMER_PROVIDER: Provider[] = [\r\n {\r\n provide: HAMMER_GESTURE_CONFIG,\r\n useClass: MyHammerConfig\r\n }\r\n];\r\n","import { NgModuleFactory, Type } from '@angular/core';\r\nimport { ThemesEnum } from '@app/common/models/themes.enum';\r\n\r\nexport const lazyWidgets: { name: string; loadChildren: () => Promise | Type> }[] = [\r\n {\r\n name: ThemesEnum.CORE,\r\n loadChildren: () => import('@app/client-core/static-pages/static-pages.module').then(m => m.StaticPagesModule)\r\n },\r\n {\r\n name: ThemesEnum.ARTICLE,\r\n loadChildren: () => import('@app/client-core/article/article.module').then(m => m.ArticleModule)\r\n },\r\n {\r\n name: ThemesEnum.MENU,\r\n loadChildren: () => import('@app/client-core/menu/menu.module').then(m => m.MenuModule)\r\n }\r\n];\r\n\r\nexport function lazyArrayToObj() {\r\n const result = {};\r\n for (const w of lazyWidgets) {\r\n result[w.name] = w.loadChildren;\r\n }\r\n return result;\r\n}\r\n","import {PortalVariablesEnum} from '@app/common/enums/portal-variables.enum';\r\n\r\nexport const PORTAL_VARIABLES_PRESETS = {\r\n [PortalVariablesEnum.MainColor]: '',\r\n [PortalVariablesEnum.SectionBackgroundColor]: '',\r\n [PortalVariablesEnum.ButtonColor]: '',\r\n [PortalVariablesEnum.AccentColor]: '',\r\n};\r\n","export const ARTICLE_PREVIEW = 'articles';\r\nexport const STATIC_PAGE_PREVIEW = 'static-pages';\r\nexport const ESERVICE_PREVIEW = 'eservices';\r\nexport const ROUTES_PATHS = {\r\n profile: {\r\n root: 'konto',\r\n login: 'logowanie',\r\n register: 'rejestracja',\r\n remindPassword: 'przypomnij-haslo'\r\n },\r\n businessModules: {\r\n root: 'moduly-biznesowe'\r\n },\r\n eServices: {\r\n root: 'katalog-e-uslug'\r\n },\r\n notFoundPage: {\r\n root: '404'\r\n },\r\n unknownErrorPage: {\r\n root: '500'\r\n },\r\n maintenance: {\r\n root: 'przerwa-techniczna'\r\n },\r\n preview: {\r\n articles: 'articles',\r\n staticPages: 'static-pages'\r\n }\r\n};\r\n","import { InjectionToken } from '@angular/core';\r\n\r\nexport const LAZY_WIDGETS = new InjectionToken<{ [key: string]: string }>('LAZY_WIDGETS');\r\n","export enum MobileEnum {\r\n Large = 992,\r\n Medium = 768,\r\n Small = 576\r\n}\r\n\r\n","export enum PortalVariablesEnum {\r\n MainColor = 'mainColor',\r\n AccentColor = 'accentColor',\r\n ButtonColor = 'buttonColor',\r\n SectionBackgroundColor = 'sectionBackgroundColor'\r\n}\r\n","export enum Bundle {\r\n EServices = 'EServices',\r\n User = 'CmsUser',\r\n Article = 'CmsArticle',\r\n Banner = 'CmsBanner',\r\n BusinessModules = 'CmsBusinessModule',\r\n Settings = 'Setting',\r\n Alert = 'CmsAlert',\r\n Promoted = 'CmsPromoted',\r\n Partners = 'CmsPartners',\r\n Sitemap = 'CmsSitemap',\r\n Breadcrumbs = 'Breadcrumbs',\r\n StaticPages = 'StaticPages',\r\n Preview = 'preview'\r\n}\r\n","import {BootstrapService} from '@app/common/services/bootstrap.service';\r\nimport { LanguageService } from '@share/common/services/language.service';\r\n\r\nexport function getLanguageFactory(language: LanguageService): () => string {\r\n return () => language.getLanguage();\r\n}\r\n\r\nexport function getTranslationsFactory(service: BootstrapService): () => Promise {\r\n return () => service.getTranslations();\r\n}\r\n\r\nexport function getMaintenanceFactory(service: BootstrapService): () => Promise {\r\n return () => service.checkMaintenance();\r\n}\r\n\r\nexport function getSettingsFactory(service: BootstrapService): () => Promise {\r\n return () => service.loadSettings();\r\n}\r\n\r\nexport function getBackendVersionFactory(service: BootstrapService): () => Promise {\r\n return () => service.getBackendVersion();\r\n}\r\n\r\nexport function getFrontendVersionFactory(service: BootstrapService): () => Promise {\r\n return () => service.getFrontendVersion();\r\n}\r\n\r\nexport function getPermissions(service: BootstrapService): () => Promise {\r\n return () => service.getPermissions();\r\n}\r\n","import { OnDestroy, Type } from '@angular/core';\r\nimport { ComponentShareHelper } from '@share/common/helpers/component-share.helper';\r\nimport { FacadeShareService } from '@share/common/services/facade-share.service';\r\nimport { ServiceLocator } from '@share/common/services/locater.service';\r\nimport { FacadeService } from '../services/facade.service';\r\n\r\nexport abstract class ComponentHelper extends ComponentShareHelper implements OnDestroy {\r\n\r\n protected service: FacadeService;\r\n\r\n protected constructor() {\r\n super(ServiceLocator.injector.get(FacadeShareService as Type));\r\n this.service = ServiceLocator.injector.get(FacadeService as Type);\r\n }\r\n}\r\n","import { HttpErrorResponse, HttpEvent, HttpHandler, HttpInterceptor, HttpRequest } from '@angular/common/http';\r\nimport { Injectable } from '@angular/core';\r\nimport { Observable, throwError } from 'rxjs';\r\nimport { ToastrServiceCustom } from '@share/common/services/toastr.service';\r\nimport { Router } from '@angular/router';\r\nimport { ROUTES_PATHS } from '@app/common/constants/routes-paths';\r\nimport { TranslatorService } from '@share/common/services/translator.service';\r\nimport { catchError } from 'rxjs/operators';\r\nimport { ErrorResponse } from '@share/common/models/http.model';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ApiInterceptorService implements HttpInterceptor {\r\n constructor(private toastr: ToastrServiceCustom, private translator: TranslatorService, private router: Router) {}\r\n\r\n private get internalErrorMessage(): string {\r\n return this.translator.trans('global.errors.internalError');\r\n }\r\n\r\n intercept(req: HttpRequest, next: HttpHandler): Observable> {\r\n const headersConfig = {};\r\n const request = req.clone({ setHeaders: headersConfig });\r\n return next.handle(request).pipe(catchError(httpErrorResponse => this.handleError(httpErrorResponse)));\r\n }\r\n\r\n private handleError(httpErrorResponse: any) {\r\n let error: { error: { errors: Array } } = { error: { errors: [] } };\r\n if (httpErrorResponse instanceof HttpErrorResponse) {\r\n this.handleErrorStatus(httpErrorResponse);\r\n const message = this.getMessage(httpErrorResponse);\r\n this.toastr.error(message.title);\r\n error = { error: { errors: [message] } };\r\n }\r\n return throwError(httpErrorResponse);\r\n }\r\n\r\n private getMessage(response: HttpErrorResponse): { title: string; id: string } {\r\n let title: string = '';\r\n try {\r\n const [error] = response.error.errors;\r\n title = error.title;\r\n } catch (e) {\r\n title = this.internalErrorMessage;\r\n }\r\n return { title, id: '' };\r\n }\r\n\r\n private handleErrorStatus(httpErrorResponse: HttpErrorResponse) {\r\n switch (httpErrorResponse.status) {\r\n case 403:\r\n this.handleForbidden();\r\n break;\r\n case 412:\r\n case 0:\r\n this.goToNotFoundPage();\r\n this.router.navigate([ROUTES_PATHS.unknownErrorPage.root]);\r\n break;\r\n }\r\n }\r\n\r\n private handleForbidden() {\r\n if (!this.router.isActive('', false)) {\r\n this.router.navigate(['']);\r\n }\r\n }\r\n\r\n private goToNotFoundPage() {\r\n this.router.navigate([ROUTES_PATHS.unknownErrorPage.root]);\r\n }\r\n}\r\n","import { HttpEvent, HttpHandler, HttpInterceptor, HttpRequest } from '@angular/common/http';\r\nimport { Observable } from 'rxjs';\r\nimport { Injectable } from '@angular/core';\r\n\r\n@Injectable()\r\nexport class ContentInterceptorService implements HttpInterceptor {\r\n intercept(req: HttpRequest, next: HttpHandler): Observable> {\r\n const headersConfig = {\r\n 'Content-Type': 'application/vnd.api+json',\r\n 'Accept': 'application/vnd.api+json',\r\n };\r\n const request = req.clone({setHeaders: headersConfig});\r\n return next.handle(request);\r\n }\r\n}\r\n","import { HttpEvent, HttpHandler, HttpInterceptor, HttpRequest } from '@angular/common/http';\r\nimport { Observable } from 'rxjs';\r\nimport { Injectable } from '@angular/core';\r\n\r\n@Injectable()\r\nexport class InstitutionInterceptorService implements HttpInterceptor {\r\n intercept(req: HttpRequest, next: HttpHandler): Observable> {\r\n const headersConfig = {\r\n 'x-site-url': window.location.origin\r\n };\r\n\r\n const request = req.clone({ setHeaders: headersConfig });\r\n return next.handle(request);\r\n }\r\n}\r\n","export enum ThemesEnum {\r\n ALERT = 'mportal_alert',\r\n ARTICLE = 'mportal_article',\r\n CONSENT = 'mportal_consent',\r\n ESERVICE_CATALOG = 'eservicesCatalog',\r\n MENU = 'mportal_menu',\r\n PROMOTED = 'mportal_promoted',\r\n NETIZEN = 'mportal_netizen',\r\n CORE = 'mportal_core',\r\n EOFFICE = 'eoffice'\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { FormErrors } from '@gkw/shared/common/models/form-errors.model';\r\nimport { HttpErrorResponse } from '@angular/common/http';\r\nimport { ResponseError } from '@share/common/models/http.model';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ApiErrorParserService {\r\n static parse(httpErrorResponse: HttpErrorResponse): FormErrors {\r\n const rawErrors: ResponseError = ApiErrorParserService.getRawErrors(httpErrorResponse);\r\n\r\n const parsedErrors: FormErrors = rawErrors.reduce((previous, current) => {\r\n return {\r\n ...previous,\r\n [current.id ?? current.status]: {\r\n text: current.title\r\n }\r\n };\r\n }, {});\r\n\r\n return parsedErrors;\r\n }\r\n\r\n static getRawErrors(httpErrorResponse: HttpErrorResponse): Array<{ id: string; title: string }> {\r\n try {\r\n return httpErrorResponse.error.errors;\r\n } catch (e) {\r\n throw new Error('Invalid error template');\r\n }\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { RequestOptionsModel } from '@share/common/interfaces/request-options.interface';\r\nimport { AppConfigCMS } from '@share/common/interfaces/app-config.interface';\r\n\r\ndeclare var APP_CONFIG: AppConfigCMS;\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ApiPreprocessorService {\r\n\r\n private readonly URL = `${APP_CONFIG.API_URL}/${APP_CONFIG.PREFIX}`;\r\n\r\n prepareUrl(endpoint: string): string {\r\n if (!endpoint.includes(this.URL)) {\r\n return `${this.URL}/${endpoint}`;\r\n }\r\n\r\n return endpoint;\r\n }\r\n\r\n build(bundle: string, data: object | Array, options: RequestOptionsModel = {}): any {\r\n const request: any = this.createBaseRequest(bundle, data, options);\r\n\r\n if (!!options) {\r\n if (options.jsonapi) {\r\n request.jsonapi = options.jsonapi;\r\n }\r\n if (options.meta) {\r\n request.meta = options.meta;\r\n }\r\n }\r\n\r\n return request;\r\n }\r\n\r\n private createBaseRequest(type: string, data: object | Array, options: RequestOptionsModel): any {\r\n return {\r\n data: Array.isArray(data) ? data : {type: type, attributes: data, id: options.id || '0'},\r\n jsonapi: { // TODO: remove\r\n version: '1.0'\r\n },\r\n meta: {}\r\n };\r\n }\r\n\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { HttpClient, HttpParams } from '@angular/common/http';\r\nimport { Observable, throwError } from 'rxjs';\r\nimport { catchError, first } from 'rxjs/operators';\r\nimport { ResponseArray, ResponseObject } from '@share/common/models/http';\r\nimport { RequestOptionsModel } from '@share/common/interfaces/request-options.interface';\r\nimport { ApiErrorParserService } from '@app/common/services/api-error-parser.service';\r\nimport { ApiPreprocessorService } from '@app/common/services/api-preprocessor.service';\r\nimport { ResponseDefault } from '@share/common/models/http.model';\r\nimport { AppConfigPortal } from '@share/common/interfaces/app-config.interface';\r\n\r\ndeclare var APP_CONFIG: AppConfigPortal;\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ApiService {\r\n private _bundle: string = '';\r\n\r\n constructor(private http: HttpClient, private preprocessor: ApiPreprocessorService) {}\r\n\r\n public setBundle(bundle: string) {\r\n this._bundle = bundle;\r\n }\r\n\r\n get(\r\n endpoint: string,\r\n params: HttpParams = new HttpParams(),\r\n options: RequestOptionsModel = {}\r\n ): Observable> {\r\n return this.http\r\n .get>(this.preprocessor.prepareUrl(endpoint), { params })\r\n .pipe(first());\r\n }\r\n\r\n getAll(\r\n endpoint: string,\r\n params: HttpParams = new HttpParams(),\r\n options: RequestOptionsModel = {}\r\n ): Observable> {\r\n return this.http\r\n .get>(this.preprocessor.prepareUrl(endpoint), { params })\r\n .pipe(first());\r\n }\r\n\r\n post(\r\n endpoint: string,\r\n body: Object = {},\r\n params: HttpParams = new HttpParams(),\r\n options: RequestOptionsModel = {}\r\n ): Observable {\r\n const requestData = this.preprocessor.build(options.bundle || this._bundle, body, options);\r\n return this.http\r\n .post(this.preprocessor.prepareUrl(endpoint), JSON.stringify(requestData), { params })\r\n .pipe(\r\n first(),\r\n catchError(e => throwError(ApiErrorParserService.parse(e)))\r\n );\r\n }\r\n\r\n put(\r\n endpoint: string,\r\n body: Object = {},\r\n options: RequestOptionsModel = {},\r\n params: HttpParams = new HttpParams()\r\n ): Observable {\r\n const requestData = this.preprocessor.build(options.bundle || this._bundle, body, options);\r\n\r\n return this.http\r\n .put(this.preprocessor.prepareUrl(endpoint), JSON.stringify(requestData), { params })\r\n .pipe(\r\n first(),\r\n catchError(e => throwError(ApiErrorParserService.parse(e)))\r\n );\r\n }\r\n\r\n patch(\r\n endpoint: string,\r\n body: Object = {},\r\n options: RequestOptionsModel = {},\r\n params: HttpParams = new HttpParams()\r\n ): Observable {\r\n const requestData = this.preprocessor.build(options.bundle || this._bundle, body, options);\r\n\r\n return this.http\r\n .patch(this.preprocessor.prepareUrl(endpoint), JSON.stringify(requestData), { params })\r\n .pipe(\r\n first(),\r\n catchError(e => throwError(ApiErrorParserService.parse(e)))\r\n );\r\n }\r\n\r\n assets(path: string): Observable {\r\n return this.http.get(`${APP_CONFIG.ASSETS_URL}/${path}`).pipe(first());\r\n }\r\n\r\n delete(endpoint: string): Observable {\r\n return this.http.delete(this.preprocessor.prepareUrl(endpoint)).pipe(first());\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { ROUTES_PATHS } from '@app/common/constants/routes-paths';\r\nimport { ResponseDefault } from '@share/common/models/http.model';\r\nimport { AppService } from '@share/common/services/app.service';\r\nimport { VersionService } from '@share/common/services/version.service';\r\nimport { VariablesCollection } from '@share/common/models/variables.model';\r\nimport { PortalLayoutService } from '@app/common/services/portal-layout.service';\r\nimport { Variable } from '@share/common/interfaces/variables.interface';\r\nimport { first } from 'rxjs/operators';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { AbstractData, ResponseObject } from '@share/common/models/http';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class BootstrapService {\r\n constructor(\r\n private appService: AppService,\r\n private versionService: VersionService,\r\n private portalLayoutService: PortalLayoutService,\r\n private facade: FacadeService\r\n ) {}\r\n\r\n getFrontendVersion(): Promise {\r\n return this.versionService.getFrontendVersion().then(\r\n (version: any) => (this.versionService.frontend = version),\r\n () => {}\r\n );\r\n }\r\n\r\n getBackendVersion(): Promise {\r\n return this.versionService.getBackendVersion().then(\r\n (response: ResponseDefault) => (this.versionService.backend = response.data.id),\r\n () => {}\r\n );\r\n }\r\n\r\n getTranslations(): Promise {\r\n return this.facade.translator.load().then(\r\n (response: ResponseObject) => (this.facade.translator.translations = response.data.attributes),\r\n () => this.onErrorOccur()\r\n );\r\n }\r\n\r\n checkMaintenance(): Promise {\r\n this.facade.maintenance.maintenancePage = ROUTES_PATHS.maintenance.root;\r\n this.facade.maintenance.serverErrorPage = ROUTES_PATHS.notFoundPage.root;\r\n return this.facade.maintenance.check().then(\r\n response => this.facade.maintenance.onSuccess(response),\r\n error => this.facade.maintenance.onError(error)\r\n );\r\n }\r\n\r\n loadSettings(): Promise {\r\n return new Promise(resolve => {\r\n this.facade.settings.load().then(\r\n (response: ResponseObject) => {\r\n this.facade.settings.variables = response.data.attributes;\r\n const layoutData = this.portalLayoutService.prepareData({\r\n ...response.data.attributes.layout,\r\n ...response.data.attributes.site\r\n });\r\n this.portalLayoutService.setLayout(layoutData as Array>);\r\n this.facade.seo.setData(this.facade.settings.variables);\r\n resolve();\r\n },\r\n () => {\r\n this.facade.settings\r\n .loadDefaultVariables()\r\n .pipe(first())\r\n .subscribe(val => {\r\n this.facade.settings.variables = val;\r\n resolve();\r\n });\r\n }\r\n );\r\n });\r\n }\r\n\r\n getPermissions(): Promise {\r\n //this.authService.isAuthenticated\r\n if (!!localStorage.getItem('token')) {\r\n return this.facade.crud.load();\r\n } else {\r\n return new Promise((resolve, reject) => resolve());\r\n }\r\n }\r\n\r\n private onErrorOccur() {\r\n this.appService.setFatalError(true);\r\n this.facade.router.navigate([ROUTES_PATHS.unknownErrorPage.root]);\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { Observable, ReplaySubject, Subject } from 'rxjs';\r\nimport { first, switchMap } from 'rxjs/operators';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\n\r\ndeclare const grecaptcha: any;\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class CaptchaV3Service {\r\n public readonly grecaptcha: Subject = new ReplaySubject();\r\n private scriptElement: HTMLScriptElement;\r\n\r\n constructor(private settingsService: SettingsService) {}\r\n\r\n public load(): void {\r\n if (this.scriptElement) {\r\n return;\r\n }\r\n this.scriptElement = document.createElement('script');\r\n this.scriptElement.src = `https://www.google.com/recaptcha/api.js?render=${this.settingsService.variables.integration.googleReCaptchaSiteKey}`;\r\n this.scriptElement.async = true;\r\n this.scriptElement.addEventListener('load', event => {\r\n grecaptcha.ready(() => {\r\n this.grecaptcha.next(grecaptcha);\r\n });\r\n });\r\n this.scriptElement.addEventListener('error', event => {\r\n this.grecaptcha.next(null);\r\n });\r\n document.getElementsByTagName('head')[0].append(this.scriptElement);\r\n\r\n this.toggleVisibility();\r\n }\r\n\r\n execute(action: string = 'homepage'): Observable {\r\n return this.grecaptcha.pipe(first()).pipe(\r\n switchMap(val => {\r\n if (val === null) {\r\n throw new Error('Google captcha script is not loaded');\r\n }\r\n return val.execute(this.settingsService.variables.integration.googleReCaptchaSiteKey, { action });\r\n })\r\n );\r\n }\r\n\r\n toggleVisibility(show: boolean = true) {\r\n const grecaptcha: HTMLElement | null = document.querySelector('.grecaptcha-badge');\r\n if (grecaptcha) {\r\n grecaptcha.style.display = show ? 'block' : 'none';\r\n }\r\n }\r\n}\r\n","import { Injectable, Injector } from '@angular/core';\r\nimport { FacadeShareService } from '@share/common/services/facade-share.service';\r\nimport { SubheaderService } from '@app/template/layout/modules/header/services/subheader.service';\r\nimport { ScrollToService } from '@app/common/services/scroll-to.service';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class FacadeService extends FacadeShareService {\r\n private _subheader: SubheaderService;\r\n private _scrollTo: ScrollToService;\r\n private _settings: SettingsService;\r\n\r\n constructor(private injector: Injector) {\r\n super(injector);\r\n }\r\n\r\n public get subheader(): SubheaderService {\r\n if (!this._subheader) {\r\n this._subheader = this._injector.get(SubheaderService);\r\n }\r\n return this._subheader;\r\n }\r\n\r\n public get scrollTo(): ScrollToService {\r\n if (!this._scrollTo) {\r\n this._scrollTo = this._injector.get(ScrollToService);\r\n }\r\n return this._scrollTo;\r\n }\r\n\r\n public get settings(): SettingsService {\r\n if (!this._settings) {\r\n this._settings = this._injector.get(SettingsService);\r\n }\r\n return this._settings;\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\n\r\ndeclare var google: any;\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class GoogleTranslateService {\r\n public init() {\r\n // tslint:disable-next-line:no-unused-expression\r\n new google.translate.TranslateElement({\r\n pageLanguage: 'pl',\r\n includedLanguages: 'pl,cs,da,de,en,es,fi,fr,hu,it,ja,no,pt,ru,zh-CN',\r\n layout: google.translate.TranslateElement.InlineLayout.SIMPLE\r\n }, 'google_translate_element');\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { NgbModalOptions } from '@ng-bootstrap/ng-bootstrap';\r\nimport { ServiceHelper } from '@share/common/helpers/service.helper';\r\nimport { ImageZoomComponent } from '@app/template/elements/image-zoom/components/image-zoom/image-zoom.component';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ImageZoomService extends ServiceHelper {\r\n private readonly zoomClass: string = '.image-zoom';\r\n private readonly originalFilterName: string = 'original';\r\n\r\n constructor() {\r\n super('');\r\n }\r\n\r\n public setListener() {\r\n // TODO: it cant find correct dom data, in settimeout works\r\n const images = document.querySelectorAll(this.zoomClass);\r\n for (let i = 0; i < images.length; i++) {\r\n images[i].addEventListener('click', event => this.imagePreview(event.target as HTMLImageElement));\r\n }\r\n }\r\n\r\n public imagePreview(image: HTMLImageElement) {\r\n const src: string = image.src;\r\n const originalSrc: string = this.getOriginalPath(src);\r\n // @ts-ignore\r\n const config: NgbModalOptions = {keyboard: true, backdrop: true, size: 'xl'};\r\n this.modal.openCustomModal(ImageZoomComponent, {original: originalSrc, alt: image.alt}, config);\r\n }\r\n\r\n private getOriginalPath(src: string | null): string {\r\n if (!src) {\r\n return '';\r\n }\r\n let path: string = src.slice(0, src.indexOf('filterName'));\r\n path += `filterName=${this.originalFilterName}`;\r\n return path;\r\n }\r\n}\r\n","import {Injectable} from '@angular/core';\r\nimport {ApiService} from '@app/common/services/api.service';\r\nimport {Observable} from 'rxjs';\r\nimport {ResponseObject} from '@share/common/models/http.model';\r\nimport {Institution} from '@app/common/models/institution.model';\r\nimport {API} from '@app/common/constants/api.directories';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class InstitutionService {\r\n\r\n constructor(private apiService: ApiService) {}\r\n\r\n public getCurrent(): Observable> {\r\n return this.apiService.get(API.INSTITUTION.ROOT);\r\n }\r\n}\r\n","import {\r\n Compiler,\r\n ComponentRef,\r\n Inject,\r\n Injectable,\r\n Injector,\r\n NgModuleFactory,\r\n Type,\r\n ViewContainerRef\r\n} from '@angular/core';\r\nimport { LAZY_WIDGETS } from '@app/common/constants/tokens';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class LazyLoaderService {\r\n constructor(\r\n private injector: Injector,\r\n private compiler: Compiler,\r\n @Inject(LAZY_WIDGETS) private lazyWidgets: { [key: string]: () => Promise | Type> }\r\n ) {}\r\n\r\n async load(name: string, container: ViewContainerRef, component?: any): Promise> {\r\n const ngModuleOrNgModuleFactory = await this.lazyWidgets[name]();\r\n\r\n let moduleFactory;\r\n if (ngModuleOrNgModuleFactory instanceof NgModuleFactory) {\r\n moduleFactory = ngModuleOrNgModuleFactory;\r\n } else {\r\n moduleFactory = await this.compiler.compileModuleAsync(ngModuleOrNgModuleFactory);\r\n }\r\n const entryComponent = component || (moduleFactory.moduleType).entry;\r\n const moduleRef = moduleFactory.create(this.injector);\r\n\r\n const compFactory = moduleRef.componentFactoryResolver.resolveComponentFactory(entryComponent);\r\n\r\n return container.createComponent(compFactory);\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { Observable } from 'rxjs';\r\nimport { Preview } from '@app/client-core/preview/interfaces/preview.interface';\r\nimport { ResponseObject } from '@share/common/models/http';\r\nimport { PageModel } from '@app/common/models/page.model';\r\nimport { ApiService } from '@app/common/services/api.service';\r\nimport { API } from '../constants/api.directories';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class PagesService implements Preview {\r\n constructor(private apiService: ApiService) {}\r\n\r\n getOne(slug: string = ''): Observable>> {\r\n return this.apiService.get(`${API.PAGES.ROOT}${slug ? '/' + slug : ''}`);\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { LayoutService } from '@share/common/services/layout.service';\r\nimport { PortalVariablesEnum } from '@app/common/enums/portal-variables.enum';\r\nimport { PORTAL_VARIABLES_PRESETS } from '@app/common/constants/portal-variables-presets';\r\nimport { HttpClient } from '@angular/common/http';\r\nimport { ImageService } from '@share/common/services/image.service';\r\nimport { AbstractData } from '@share/common/models/http.model';\r\nimport { ObjectString } from '@share/common/interfaces/object-types.interface';\r\nimport { Variable } from '@share/common/interfaces/variables.interface';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class PortalLayoutService extends LayoutService {\r\n\r\n constructor(protected httpClient: HttpClient,\r\n protected imageService: ImageService) {\r\n super(httpClient, imageService);\r\n this.layoutPresets = PORTAL_VARIABLES_PRESETS;\r\n }\r\n\r\n public prepareData(variables: ObjectString): Array>> {\r\n const data: Array>> = [];\r\n for (const variable of Object.keys(variables)) {\r\n data.push({\r\n id: '0',\r\n type: '',\r\n attributes: {\r\n name: variable,\r\n value: variables[variable]\r\n }\r\n });\r\n }\r\n return data;\r\n }\r\n\r\n protected variablesQueue(): Array {\r\n return [\r\n PortalVariablesEnum.AccentColor,\r\n PortalVariablesEnum.ButtonColor,\r\n PortalVariablesEnum.MainColor,\r\n PortalVariablesEnum.SectionBackgroundColor,\r\n ];\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { fromEvent, merge, Observable, of } from 'rxjs';\r\nimport { map, switchMap } from 'rxjs/operators';\r\nimport { MobileEnum } from '@app/common/enums/mobile.enum';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ResizeListener {\r\n get isMobile$(): Observable {\r\n return merge(this.onLoad(), this.onResize()).pipe(\r\n switchMap(value => {\r\n if (!value) {\r\n return this.isMobileDevice();\r\n }\r\n return of(value);\r\n })\r\n );\r\n }\r\n\r\n private onResize(): Observable {\r\n return fromEvent(window, 'resize').pipe(map(() => window.innerWidth < MobileEnum.Large));\r\n }\r\n\r\n private onLoad(): Observable {\r\n return of(window.innerWidth < MobileEnum.Large);\r\n }\r\n private isMobileDevice(): Observable {\r\n return of(/iPhone|iPad|iPod|Android/i.test(navigator.userAgent));\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\n\r\ndeclare var $: Function;\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class ScrollToService {\r\n\r\n constructor() {}\r\n\r\n animate(id: string, time: number = 500, scrollDifference: number = 70) {\r\n try {\r\n $('html, body').animate({\r\n scrollTop: ($(id).offset().top as number) - scrollDifference,\r\n }, time);\r\n } catch (ignore) {\r\n }\r\n }\r\n\r\n resetScrollTop() {\r\n window.scrollTo(0, 0);\r\n }\r\n}\r\n\r\n","import { Injectable } from '@angular/core';\r\nimport { API } from '@app/common/constants/api.directories';\r\nimport { ApiService } from '@app/common/services/api.service';\r\nimport { Observable } from 'rxjs';\r\nimport { BootstrapModel } from '@app/common/models/bootstrap.model';\r\nimport { ResponseObject } from '@share/common/models/http';\r\nimport { ThemesEnum } from '@app/common/models/themes.enum';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class SettingsService {\r\n variables: T;\r\n\r\n constructor(private apiService: ApiService) {}\r\n\r\n load(): Promise> {\r\n return this.apiService.get(API.SETTINGS.ROOT).toPromise();\r\n }\r\n\r\n loadDefaultVariables(): Observable {\r\n return this.apiService.assets(API.ASSETS.DEFAULT_SETTINGS);\r\n }\r\n\r\n isModuleActive(theme: ThemesEnum): boolean {\r\n return this.variables.theme.modules.includes(theme);\r\n }\r\n}\r\n","import {Injectable} from '@angular/core';\r\nimport {Location} from '@angular/common';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class UrlService {\r\n constructor(private location: Location) {}\r\n\r\n getParsedUrl(): string {\r\n const path: string = this.location.path();\r\n return path.substr(1, path.length).replace(/\\//g, ',');\r\n }\r\n\r\n getLastUrlElement(): string {\r\n const paths: string[] = this.getParsedUrl().split(',');\r\n return paths[paths.length - 1];\r\n }\r\n}\r\n","import { CommonModule } from '@angular/common';\r\nimport { NgModule } from '@angular/core';\r\nimport { AccordionComponent } from './component/accordion/accordion.component';\r\nimport { AccPanelTitleDirective, AccPanelContentDirective, AccPanelDirective } from './directives/accordion-panel.directive';\r\n\r\n@NgModule({\r\n imports: [CommonModule],\r\n exports: [\r\n AccordionComponent,\r\n AccPanelTitleDirective,\r\n AccPanelContentDirective,\r\n AccPanelDirective\r\n ],\r\n declarations: [\r\n AccordionComponent,\r\n AccPanelTitleDirective,\r\n AccPanelContentDirective,\r\n AccPanelDirective\r\n ]\r\n})\r\nexport class AccordionModule {}\r\n","import { AfterContentChecked, Component, ContentChildren, EventEmitter, Input, Output, QueryList, ViewEncapsulation } from '@angular/core';\r\nimport { AccPanelChangeEvent } from '../../interfaces/accordion-panel-change-event.model';\r\nimport { AccPanelDirective } from '../../directives/accordion-panel.directive';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\n\r\n@Component({\r\n selector: 'app-accordion',\r\n templateUrl: './accordion.component.html',\r\n styleUrls: ['./accordion.component.scss']\r\n})\r\nexport class AccordionComponent extends ComponentHelper implements AfterContentChecked {\r\n @ContentChildren(AccPanelDirective) panels: QueryList;\r\n @Input() activeIds: string[] = [];\r\n @Output() readonly panelChange = new EventEmitter();\r\n\r\n constructor() {\r\n super();\r\n }\r\n\r\n private _findPanelById(panelId: string): AccPanelDirective | undefined {\r\n return this.panels.find(p => p.id === panelId);\r\n }\r\n\r\n\r\n private _updateActiveIds() {\r\n this.activeIds = this.panels.filter(panel => panel.isOpen && !panel.disabled).map(panel => panel.id);\r\n }\r\n\r\n private _changeOpenState(panel: AccPanelDirective, nextState: boolean, target: EventTarget) {\r\n if (panel && !panel.disabled && panel.isOpen !== nextState) {\r\n let defaultPrevented = false;\r\n\r\n this.panelChange.emit({\r\n panelId: panel.id,\r\n nextState: nextState,\r\n target,\r\n prevent: () => { defaultPrevented = true; }\r\n });\r\n\r\n if (!defaultPrevented) {\r\n panel.isOpen = nextState;\r\n\r\n this._updateActiveIds();\r\n }\r\n }\r\n }\r\n\r\n toggle(panelId: string, target: EventTarget) {\r\n const panel = this._findPanelById(panelId);\r\n if (panel) {\r\n this._changeOpenState(panel, !panel.isOpen, target);\r\n }\r\n }\r\n\r\n isPanelActive(panelId: string): boolean {\r\n return this.activeIds && this.activeIds.indexOf(panelId) !== -1;\r\n }\r\n\r\n expandAll() {\r\n this.panels.forEach(panel => {\r\n if (this.activeIds.indexOf(panel.id) === -1) {\r\n this.activeIds.push(panel.id);\r\n }\r\n });\r\n }\r\n\r\n ngAfterContentChecked() {\r\n this.panels.forEach(panel => panel.isOpen = !panel.disabled && this.activeIds.indexOf(panel.id) > -1);\r\n }\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { AfterContentChecked, ContentChildren, Directive, Input, QueryList, TemplateRef } from '@angular/core';\r\n\r\n@Directive({selector: 'ng-template[appAccPanelTitle]'})\r\nexport class AccPanelTitleDirective {\r\n constructor(public templateRef: TemplateRef) {}\r\n}\r\n\r\n@Directive({selector: 'ng-template[appAccPanelContent]'})\r\nexport class AccPanelContentDirective {\r\n constructor(public templateRef: TemplateRef) {}\r\n}\r\n\r\n@Directive({selector: '[appAccPanel]'})\r\nexport class AccPanelDirective implements AfterContentChecked {\r\n\r\n @Input() disabled = false;\r\n @Input() id: string;\r\n @Input() title: string;\r\n @Input() type: string;\r\n @Input() isOpen = false;\r\n\r\n @ContentChildren(AccPanelTitleDirective, {descendants: false}) titleTpls: QueryList;\r\n @ContentChildren(AccPanelContentDirective, {descendants: false}) contentTpls: QueryList;\r\n\r\n titleTpl: AccPanelTitleDirective | null;\r\n contentTpl: AccPanelContentDirective | null;\r\n\r\n constructor() { }\r\n\r\n ngAfterContentChecked() {\r\n this.titleTpl = this.titleTpls.first;\r\n this.contentTpl = this.contentTpls.first;\r\n }\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { MultiCarouselComponent } from './components/multi-carousel/multi-carousel.component';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { PolygonModule } from '@app/template/elements/polygon/polygon.module';\r\n\r\n@NgModule({\r\n declarations: [\r\n MultiCarouselComponent\r\n ],\r\n imports: [\r\n CommonModule,\r\n TranslatorModule,\r\n PolygonModule\r\n ],\r\n exports: [\r\n MultiCarouselComponent\r\n ]\r\n})\r\nexport class CarouselModule {}\r\n","import { AfterViewChecked, Component, ElementRef, Input } from '@angular/core';\r\nimport { MultiCarousel } from '../../models/multi-carousel.model';\r\nimport { MultiCarouselConfig } from '../../models/multi-carousel-config.model';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { AbstractData } from '@share/common/models/http';\r\n\r\ndeclare var $: Function;\r\n\r\n@Component({\r\n selector: 'app-multi-carousel',\r\n templateUrl: './multi-carousel.component.html',\r\n styleUrls: [\r\n './multi-carousel.component.scss'\r\n ]\r\n})\r\nexport class MultiCarouselComponent extends ComponentHelper implements AfterViewChecked {\r\n @Input() data: Array> = [];\r\n\r\n @Input()\r\n set config(config: MultiCarouselConfig) {\r\n this._config = Object.assign(this._config, config);\r\n }\r\n\r\n private _config: MultiCarouselConfig = {\r\n dots: true,\r\n nav: true,\r\n itemsOnScreen: {\r\n 0: {\r\n items: 2\r\n },\r\n 600: {\r\n items: 3\r\n },\r\n 1000: {\r\n items: 4\r\n }\r\n },\r\n autoplayHoverPause: false,\r\n autoplay: false,\r\n autoplayTimeout: 5000,\r\n loop: false\r\n };\r\n\r\n get config() {\r\n return this._config;\r\n }\r\n\r\n private isCarouselInit = false;\r\n\r\n constructor(private elementRef: ElementRef) {\r\n super();\r\n }\r\n\r\n public initCarousel(): void {\r\n const owl = $('.owl-carousel').owlCarousel({\r\n margin: 0,\r\n responsive: this.config.itemsOnScreen,\r\n dots: this.config.dots,\r\n nav: this.config.nav,\r\n dotsContainer: '#owl-carousel-custom-dots',\r\n navContainer: '#owl-carousel-custom-nav',\r\n navText: [\r\n ``,\r\n ``\r\n ],\r\n autoplay: this.config.autoplay,\r\n autoplayTimeout: this.config.autoplayTimeout,\r\n autoplayHoverPause: this.config.autoplayHoverPause,\r\n loop: this.config.loop\r\n });\r\n $('.owl-dots').on('click', 'li', function (e: any) {\r\n // @ts-ignore\r\n owl.trigger('to.owl.carousel', [$(this).index(), 300]);\r\n });\r\n }\r\n\r\n\r\n private setAriaLabels() {\r\n const dots = this.elementRef.nativeElement.querySelectorAll('.owl-dot');\r\n dots.forEach((dot: HTMLButtonElement, index: number) => {\r\n dot.setAttribute('aria-label', this.trans('global.goToPage') + (index + 1));\r\n });\r\n }\r\n\r\n getLink(url: string): string {\r\n return url?.length > 3 && url.substr(0, 3) === 'www' ? `//${url}` : url\r\n }\r\n\r\n ngAfterViewChecked() {\r\n const carousel = $('.owl-carousel');\r\n if (carousel.length > 0 && !this.isCarouselInit) {\r\n setTimeout(() => {\r\n this.initCarousel();\r\n this.setAriaLabels();\r\n });\r\n this.isCarouselInit = true;\r\n }\r\n }\r\n}\r\n","\r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n\r\n\r\n","import {Component, Input} from '@angular/core';\r\n\r\n@Component({\r\n selector: 'shared-heading-section',\r\n templateUrl: './heading-section.component.html',\r\n styleUrls: ['./heading-section.component.scss']\r\n})\r\nexport class HeadingSectionComponent {\r\n @Input() number: number = 0;\r\n @Input() subtitle: string = '';\r\n @Input() title: string;\r\n @Input() innerColor: boolean = false;\r\n @Input() hsClass: string;\r\n\r\n}\r\n","\r\n \r\n {{ title }}\r\n \r\n - {{subtitle}}\r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { HeadingSectionComponent } from './components/heading-section/heading-section.component';\r\nimport {PolygonModule} from '@app/template/elements/polygon/polygon.module';\r\n\r\n@NgModule({\r\n declarations: [\r\n HeadingSectionComponent\r\n ],\r\n exports: [\r\n HeadingSectionComponent\r\n ],\r\n imports: [\r\n CommonModule,\r\n PolygonModule\r\n ]\r\n})\r\nexport class HeadingModule { }\r\n","import { Component, Input } from '@angular/core';\r\nimport { NgbActiveModal } from '@ng-bootstrap/ng-bootstrap';\r\nimport { ImageZoom } from '@app/template/elements/image-zoom/interfaces/image-zoom.interface';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\n\r\n@Component({\r\n selector: 'app-image-zoom',\r\n templateUrl: './image-zoom.component.html'\r\n})\r\nexport class ImageZoomComponent extends ComponentHelper {\r\n @Input() public data: ImageZoom;\r\n public loading: boolean = true;\r\n public placeholder: boolean = false;\r\n\r\n constructor(private activeModal: NgbActiveModal) {\r\n super();\r\n }\r\n\r\n public close() {\r\n this.activeModal.close();\r\n }\r\n\r\n public onLoad() {\r\n this.loading = false;\r\n }\r\n\r\n public onError() {\r\n this.onLoad();\r\n this.placeholder = true;\r\n }\r\n}\r\n","\r\n {{data.alt}}\r\n \r\n {{'x'}}\r\n \r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { ImageZoomComponent } from '@app/template/elements/image-zoom/components/image-zoom/image-zoom.component';\r\nimport { ProgressBarModule } from '@share/modules/progress-bar/progress-bar.module';\r\nimport { CommonModule } from '@angular/common';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n ProgressBarModule\r\n ],\r\n declarations: [\r\n ImageZoomComponent\r\n ],\r\n exports: [\r\n ImageZoomComponent\r\n ],\r\n entryComponents: [\r\n ImageZoomComponent\r\n ]\r\n})\r\nexport class ImageZoomModule {}\r\n","import { Component, Input } from '@angular/core';\r\nimport { ControlValueAccessor, NgControl } from '@angular/forms';\r\n\r\n@Component({\r\n selector: 'app-input',\r\n templateUrl: 'input.component.html',\r\n styleUrls: ['input.component.scss']\r\n})\r\nexport class InputComponent implements ControlValueAccessor {\r\n\r\n @Input() label: string;\r\n @Input() id: string;\r\n\r\n private onChange: (v: string) => void = (v: string) => {};\r\n private onTouch: () => void = () => {};\r\n\r\n value: string;\r\n\r\n constructor(private ngControl: NgControl) {\r\n this.ngControl.valueAccessor = this;\r\n }\r\n\r\n registerOnChange(fn: any): void {\r\n this.onChange = fn;\r\n }\r\n\r\n registerOnTouched(fn: any): void {\r\n this.onTouch = fn;\r\n }\r\n\r\n writeValue(obj: any): void {\r\n this.value = obj;\r\n this.onChange(obj);\r\n }\r\n}\r\n","\r\n \r\n {{ label }}\r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { InputComponent } from '@app/template/elements/input/input.component';\r\nimport { FormsModule } from '@angular/forms';\r\n\r\n@NgModule({\r\n declarations: [InputComponent],\r\n exports: [InputComponent],\r\n imports: [CommonModule, FormsModule]\r\n})\r\nexport class InputModule {}\r\n","import { Component, EventEmitter, Input, Output } from '@angular/core';\r\nimport { PaginationService } from '../../services/pagination.service';\r\n\r\n@Component({\r\n selector: 'shared-pagination',\r\n templateUrl: './pagination.component.html',\r\n styleUrls: ['./pagination.component.scss'],\r\n})\r\nexport class PaginationComponent {\r\n\r\n @Input() public perPage: number = 10;\r\n @Input() public pages: number = 1;\r\n @Input() public position: 'left' | 'right' = 'right';\r\n @Output() readonly changed: EventEmitter = new EventEmitter();\r\n\r\n constructor(private paginationService: PaginationService) {}\r\n\r\n\r\n public get total(): number {\r\n return this.perPage * this.pages;\r\n }\r\n\r\n public set currentPage(value: number) {\r\n this.paginationService.page = value;\r\n this.changed.emit(value);\r\n }\r\n\r\n public get currentPage(): number {\r\n return this.paginationService.page;\r\n }\r\n\r\n\r\n}\r\n"," 1\">\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n {{'...'}}\r\n {{ currentPage }}\r\n \r\n \r\n \r\n\r\n","import {NgModule} from '@angular/core';\r\nimport {CommonModule} from '@angular/common';\r\nimport {PaginationComponent} from './components/pagination/pagination.component';\r\nimport {NgbPaginationModule} from '@ng-bootstrap/ng-bootstrap';\r\nimport {PaginationService} from './services/pagination.service';\r\n\r\n@NgModule({\r\n declarations: [\r\n PaginationComponent\r\n ],\r\n imports: [\r\n CommonModule,\r\n NgbPaginationModule\r\n ],\r\n exports: [\r\n PaginationComponent\r\n ],\r\n providers: [\r\n PaginationService\r\n ]\r\n})\r\nexport class PaginationModule {}\r\n","import { Injectable } from '@angular/core';\r\nimport { BehaviorSubject, Observable, Subscription } from 'rxjs';\r\nimport { ComponentShareHelper } from '@share/common/helpers/component-share.helper';\r\nimport { FacadeShareService } from '@share/common/services/facade-share.service';\r\nimport { ActivatedRoute, Params } from '@angular/router';\r\n\r\n@Injectable()\r\nexport class PaginationService extends ComponentShareHelper {\r\n private firstPage: number = 1;\r\n private _page: BehaviorSubject = new BehaviorSubject(this.firstPage);\r\n\r\n constructor(private facadeShareService: FacadeShareService,\r\n private activatedRoute: ActivatedRoute) {\r\n super(facadeShareService);\r\n this.setParamsListener();\r\n }\r\n\r\n public setParamsListener() {\r\n return this.activatedRoute.queryParams.subscribe((params: Params) => {\r\n if (params.page) {\r\n this.page = parseInt(params.page, 10);\r\n } else {\r\n this._page.next(this.firstPage);\r\n }\r\n });\r\n }\r\n\r\n private changeQueryParams(value: number) {\r\n setTimeout(() => {\r\n this.facadeShareService.router.navigate([], {\r\n relativeTo: this.activatedRoute,\r\n queryParams: {page: value === this.firstPage ? null : value}\r\n });\r\n });\r\n }\r\n\r\n public set page(value: number) {\r\n if (value !== this.page) {\r\n this._page.next(value);\r\n this.changeQueryParams(value);\r\n }\r\n }\r\n\r\n public get page(): number {\r\n return this._page.getValue();\r\n }\r\n\r\n public get currentPage(): Observable {\r\n return this._page.asObservable();\r\n }\r\n}\r\n","import { Component, Input } from '@angular/core';\r\nimport { UtilsService } from '@share/common/services/utils.service';\r\n\r\n@Component({\r\n selector: 'shared-hexagon-content',\r\n templateUrl: './hexagon-content.component.html',\r\n styleUrls: ['./hexagon-content.component.scss']\r\n})\r\nexport class HexagonContentComponent {\r\n @Input() bgColor: string;\r\n @Input() borderColor: string;\r\n @Input() borderWidth: number = 0;\r\n @Input() width: number = 100;\r\n @Input() height: number = 100;\r\n @Input() isInnerShadow: boolean = false;\r\n @Input() innerShadowConfig: { alpha: number, blur: number } = {alpha: 0.3, blur: 2};\r\n @Input() isOuterShadow: boolean = false;\r\n @Input() isHover: boolean = false;\r\n @Input() bgGradient: boolean = false;\r\n @Input() borderGradient: boolean = false;\r\n @Input() edgeRounded: boolean = false;\r\n @Input() bgImage: string = '';\r\n\r\n public innerShadowID: string = '';\r\n\r\n constructor(private utils: UtilsService) {\r\n this.innerShadowID = this.utils.makeId();\r\n }\r\n\r\n public get location() {\r\n return window.location.href;\r\n }\r\n\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport {HexagonContentComponent} from './components/hexagon-content/hexagon-content.component';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule\r\n ],\r\n declarations: [\r\n HexagonContentComponent\r\n ],\r\n exports: [\r\n HexagonContentComponent\r\n ]\r\n})\r\nexport class PolygonModule {\r\n}\r\n","import { Component, Input, ViewEncapsulation } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'app-promoted-item-icon',\r\n styleUrls: ['promoted-item-icon.component.scss'],\r\n templateUrl: 'promoted-item-icon.component.html',\r\n encapsulation: ViewEncapsulation.None\r\n})\r\nexport class PromotedItemIconComponent {\r\n\r\n @Input() icon: string;\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n\r\n","import { Component, ElementRef, EventEmitter, Input, OnDestroy, Output, Renderer2 } from '@angular/core';\r\nimport { Promoted } from '../../models/promoted.model';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { AbstractData } from '@share/common/models/http';\r\n\r\n@Component({\r\n selector: 'app-promoted-list',\r\n templateUrl: './promoted-list.component.html',\r\n styleUrls: [`./promoted-list.component.scss`]\r\n})\r\nexport class PromotedListComponent extends ComponentHelper implements OnDestroy {\r\n @Input() data: Array>;\r\n\r\n @Input() filter: string;\r\n @Input() height: number = 420;\r\n @Input() background?: string = '';\r\n @Input() hasIcon: boolean = false;\r\n @Output() readonly clicked: EventEmitter = new EventEmitter();\r\n private listenClickFunc: Function;\r\n\r\n constructor(private renderer: Renderer2, private _elementRef: ElementRef) {\r\n super();\r\n this.onClickListener();\r\n }\r\n\r\n private onClickListener(): void {\r\n this.listenClickFunc = this.renderer.listen(this._elementRef.nativeElement, 'click', event =>\r\n this.shareService.utils.navigateTo(event)\r\n );\r\n }\r\n\r\n public imagePath(path: string) {\r\n return this.shareService.image.img({ file: path, filter: this.filter });\r\n }\r\n\r\n public navigateTo(event: Event, url: string, id: string) {\r\n event.preventDefault();\r\n event.stopPropagation();\r\n window.open(url);\r\n this.onClick(id);\r\n }\r\n\r\n public onClick(slug: string) {\r\n this.clicked.emit(slug);\r\n }\r\n\r\n public ngOnDestroy() {\r\n this.listenClickFunc();\r\n }\r\n\r\n public get dataExists(): boolean {\r\n return Array.isArray(this.data) && this.data.length > 0;\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n {{ promoted.attributes.title | truncate: 50 }}\r\n \r\n {{'global.findOutMore' | trans}}\r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { PolygonModule } from '../polygon/polygon.module';\r\nimport { PromotedListComponent } from './components/promoted-list/promoted-list.component';\r\nimport { CommonModule } from '@angular/common';\r\nimport { RouterModule } from '@angular/router';\r\nimport { TruncateModule } from '@share/modules/truncate/truncate.module';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { PromotedItemIconComponent } from './components/promoted-item-icon/promoted-item-icon.component';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\n\r\n@NgModule({\r\n declarations: [\r\n PromotedListComponent,\r\n PromotedItemIconComponent\r\n ],\r\n imports: [\r\n CommonModule,\r\n RouterModule,\r\n PolygonModule,\r\n TruncateModule,\r\n ElementsModule,\r\n TranslatorModule\r\n ],\r\n exports: [\r\n PromotedListComponent\r\n ]\r\n})\r\nexport class PromotedModule {\r\n}\r\n","import { ChangeDetectionStrategy, Component, OnInit } from '@angular/core';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { PagesService } from '@app/common/services/pages.service';\r\nimport { first } from 'rxjs/operators';\r\n\r\n@Component({\r\n selector: 'app-simple-box',\r\n styleUrls: ['simple-box.component.scss'],\r\n templateUrl: 'simple-box.component.html',\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class SimpleBoxComponent implements OnInit {\r\n data: {\r\n button: string;\r\n contactBoxIcon: string;\r\n contactPage: string;\r\n content: string;\r\n title: string;\r\n };\r\n\r\n constructor(private facadeService: FacadeService, private pageService: PagesService) {}\r\n\r\n ngOnInit() {\r\n this.data = this.facadeService.settings.variables.contactBox;\r\n }\r\n\r\n onButtonClick() {\r\n this.pageService\r\n .getOne(this.data.contactPage)\r\n .pipe(first())\r\n .subscribe(page => this.facadeService.router.navigate([page.data.id.replace(',', '/')]));\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n\r\n {{ data.title }}\r\n {{ data.content }}\r\n \r\n\r\n \r\n\r\n \r\n\r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { SimpleBoxComponent } from '@app/template/elements/simple-box/components/simple-box.component';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { CommonModule } from '@angular/common';\r\n\r\n@NgModule({\r\n declarations: [SimpleBoxComponent],\r\n imports: [\r\n ElementsModule,\r\n CommonModule\r\n ],\r\n exports: [SimpleBoxComponent]\r\n})\r\nexport class SimpleBoxModule {\r\n\r\n}\r\n","import { Component, Input } from '@angular/core';\r\nimport { ControlValueAccessor, NgControl } from '@angular/forms';\r\n\r\n@Component({\r\n selector: 'app-textarea',\r\n templateUrl: 'textarea.component.html',\r\n styleUrls: ['textarea.component.scss']\r\n})\r\nexport class TextareaComponent implements ControlValueAccessor {\r\n\r\n @Input() label: string;\r\n @Input() id: string;\r\n\r\n private onChange: (v: string) => void = (v: string) => {};\r\n private onTouch: () => void = () => {};\r\n\r\n value: string;\r\n\r\n constructor(private ngControl: NgControl) {\r\n this.ngControl.valueAccessor = this;\r\n }\r\n\r\n registerOnChange(fn: any): void {\r\n this.onChange = fn;\r\n }\r\n\r\n registerOnTouched(fn: any): void {\r\n this.onTouch = fn;\r\n }\r\n\r\n writeValue(obj: any): void {\r\n this.value = obj;\r\n this.onChange(obj);\r\n }\r\n}\r\n","\r\n \r\n {{ label }}\r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { TextareaComponent } from './textarea.component';\r\nimport { CommonModule } from '@angular/common';\r\nimport { FormsModule } from '@angular/forms';\r\n\r\n@NgModule({\r\n imports: [CommonModule, FormsModule],\r\n declarations: [TextareaComponent],\r\n exports: [TextareaComponent]\r\n})\r\nexport class TextareaModule {}\r\n","import { ChangeDetectionStrategy, Component, Input } from '@angular/core';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { MultiCarousel } from '@app/template/elements/carousel/models/multi-carousel.model';\r\nimport { MultiCarouselConfig } from '@app/template/elements/carousel/models/multi-carousel-config.model';\r\nimport { ImageCropper } from '@app/template/home/models/image-cropper.model';\r\n\r\n@Component({\r\n selector: 'app-gallery',\r\n templateUrl: 'gallery.component.html',\r\n styleUrls: ['gallery.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class GalleryComponent {\r\n config: MultiCarouselConfig = {\r\n dots: false,\r\n nav: true,\r\n itemsOnScreen: {\r\n 0: {\r\n items: 2\r\n },\r\n 700: {\r\n items: 2\r\n },\r\n 800: {\r\n items: 2\r\n },\r\n 1140: {\r\n items: 3\r\n },\r\n 1370: {\r\n items: 4\r\n }\r\n },\r\n autoplayHoverPause: false,\r\n autoplay: false,\r\n autoplayTimeout: 5000,\r\n loop: false\r\n };\r\n\r\n @Input() set data(value: { gallery: AbstractData<{ image: ImageCropper; alt: string }>[] }) {\r\n if (value) {\r\n this.parsedData = value.gallery.map(item => ({\r\n id: item.id,\r\n type: item.type,\r\n attributes: {\r\n file: item.attributes.image.url || (item.attributes.image.croppedUrl as string),\r\n description: item.attributes.alt,\r\n url: '',\r\n isOpenInNewWindow: false\r\n }\r\n }));\r\n }\r\n }\r\n parsedData: Array> = [];\r\n}\r\n","\r\n \r\n \r\n \r\n\r\n\r\n\r\n Galeria\r\n \r\n\r\n\r\n\r\n \r\n \r\n \r\n\r\n","import { ChangeDetectionStrategy, Component, Input } from '@angular/core';\r\nimport { FacadeService } from '@app/common/services/facade.service';\r\nimport { HomeIntroModel } from '@app/template/home/models/home-intro.model';\r\n\r\n@Component({\r\n selector: 'app-main-banner',\r\n templateUrl: 'main-banner.component.html',\r\n styleUrls: ['main-banner.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class MainBannerComponent {\r\n\r\n @Input() data: HomeIntroModel;\r\n\r\n constructor(private facadeService: FacadeService) {\r\n }\r\n\r\n scrollDown() {\r\n this.facadeService.scrollTo.animate('#promoted', 800, 100);\r\n }\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { ChangeDetectionStrategy, ChangeDetectorRef, Component, Input, OnChanges, SimpleChanges } from '@angular/core';\r\nimport { ArticlesService } from '@app/client-core/article/services/articles.service';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { Article } from '@app/client-core/article/models/article.model';\r\nimport { finalize, first, switchMap } from 'rxjs/operators';\r\nimport { Router } from '@angular/router';\r\nimport { PagesService } from '@app/common/services/pages.service';\r\nimport { DynamicContentService } from '@app/client-core/dynamic-content/service/dynamic-content.service';\r\n\r\n@Component({\r\n selector: 'app-news',\r\n styleUrls: ['news.component.scss'],\r\n templateUrl: 'news.component.html',\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class NewsComponent implements OnChanges {\r\n news: AbstractData[];\r\n loading: boolean;\r\n getError: boolean;\r\n\r\n @Input() data: {\r\n title: string;\r\n subtitle: string;\r\n category: string;\r\n };\r\n\r\n constructor(\r\n private articleService: ArticlesService,\r\n private cdr: ChangeDetectorRef,\r\n private pageService: PagesService,\r\n private router: Router,\r\n private dynamicContentService: DynamicContentService\r\n ) {}\r\n\r\n ngOnChanges(changes: SimpleChanges): void {\r\n if (changes.data.currentValue) {\r\n this.getNews();\r\n }\r\n }\r\n\r\n setLoader(value: boolean) {\r\n this.loading = value;\r\n this.cdr.detectChanges();\r\n }\r\n\r\n test() {\r\n this.pageService.getOne();\r\n }\r\n\r\n getNews() {\r\n this.setLoader(true);\r\n this.pageService\r\n .getOne(this.data.category)\r\n .pipe(\r\n first(),\r\n finalize(() => this.setLoader(false))\r\n )\r\n .subscribe(\r\n response => this.getMetadata(response.data.id),\r\n error => (this.getError = true)\r\n );\r\n }\r\n\r\n getMetadata(url: string) {\r\n this.dynamicContentService\r\n .getPageMetadata(url)\r\n .pipe(switchMap(metadata => this.articleService.getList(1, 4, metadata.meta?.objectId)))\r\n .subscribe(news => {\r\n this.news = news.data;\r\n this.cdr.detectChanges();\r\n });\r\n }\r\n\r\n showMoreClicked() {\r\n this.router.navigate(['aktualnosci']);\r\n }\r\n\r\n readMoreClicked(item: AbstractData) {\r\n this.router.navigate(['aktualnosci', item.attributes.slug]);\r\n }\r\n}\r\n","\r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n\r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n\r\n \r\n {{\r\n category.attributes.title\r\n }}\r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n {{ item.attributes.title }}\r\n \r\n \r\n {{ item.attributes.publishedFrom | date: 'shortDate':'':'pl' }}\r\n \r\n \r\n {{ item.attributes.description }}\r\n \r\n \r\n \r\n \r\n\r\n","import {\r\n AfterViewInit,\r\n ChangeDetectionStrategy,\r\n ChangeDetectorRef,\r\n Component,\r\n Input,\r\n OnInit,\r\n ViewChild,\r\n ViewContainerRef\r\n} from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { LazyLoaderService } from '@app/common/services/lazy-loader.service';\r\nimport { ROUTES_PATHS } from '@app/common/constants/routes-paths';\r\nimport { Router } from '@angular/router';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { finalize, first } from 'rxjs/operators';\r\nimport { HomeService } from '@app/template/home/services/home.service';\r\nimport { PagesService } from '@app/common/services/pages.service';\r\nimport { PageModel } from '@app/common/models/page.model';\r\nimport { HomeModel } from '@app/template/home/models/home.model';\r\n\r\n@Component({\r\n selector: 'app-home',\r\n templateUrl: './overlay.component.html',\r\n styleUrls: ['./overlay.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class OverlayComponent extends ComponentHelper implements OnInit, AfterViewInit {\r\n @ViewChild('businessModules', { read: ViewContainerRef }) businessModules: ViewContainerRef;\r\n @Input() data: AbstractData>;\r\n loading: boolean = true;\r\n\r\n constructor(\r\n private settingsService: SettingsService,\r\n private lazyLoaderService: LazyLoaderService,\r\n private pagesService: PagesService,\r\n private router: Router,\r\n private cdr: ChangeDetectorRef,\r\n private homeService: HomeService\r\n ) {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n this.service.scrollTo.resetScrollTop();\r\n }\r\n\r\n private setLoading(value: boolean) {\r\n this.loading = value;\r\n this.cdr.markForCheck();\r\n }\r\n\r\n getMainPage() {\r\n this.setLoading(true);\r\n this.pagesService\r\n .getOne()\r\n .pipe(\r\n first(),\r\n finalize(() => this.setLoading(false))\r\n )\r\n .subscribe(\r\n response => {\r\n this.data = response.data;\r\n },\r\n () => {\r\n this.router.navigate(['/', ROUTES_PATHS.notFoundPage.root]);\r\n }\r\n );\r\n }\r\n\r\n ngAfterViewInit() {\r\n if (!this.data) {\r\n this.getMainPage();\r\n } else {\r\n this.loading = false;\r\n this.homeService.isHomePreview = true;\r\n }\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n\r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { ChangeDetectionStrategy, ChangeDetectorRef, Component, Input, OnInit } from '@angular/core';\r\nimport { PromotedService } from '@app/template/home/services/promoted.service';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { Promoted } from '@app/template/elements/promoted/models/promoted.model';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { finalize, first } from 'rxjs/operators';\r\n\r\n@Component({\r\n selector: 'app-promoted',\r\n templateUrl: './promoted.component.html',\r\n styleUrls: ['./promoted.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class PromotedComponent extends ComponentHelper implements OnInit {\r\n @Input() data: { title: string; subtitle: string };\r\n promoted: Array> = [];\r\n loading: boolean = false;\r\n\r\n constructor(private promotedService: PromotedService, private cdr: ChangeDetectorRef) {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n this.loadPromoted();\r\n }\r\n\r\n loadPromoted() {\r\n this.setLoading(true);\r\n this.promotedService\r\n .getList()\r\n .pipe(\r\n first(),\r\n finalize(() => this.setLoading(false))\r\n )\r\n .subscribe(\r\n response => (this.promoted = this.getResponseData(response)),\r\n () => this.setComponentError()\r\n );\r\n }\r\n\r\n private setLoading(value: boolean) {\r\n this.loading = value;\r\n this.cdr.markForCheck();\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { ChangeDetectionStrategy, Component, Input } from '@angular/core';\r\nimport { HomeReportCrashModel } from '@app/template/home/models/home-report-crash.model';\r\n\r\n@Component({\r\n selector: 'app-report-crash',\r\n templateUrl: 'report-crash.component.html',\r\n styleUrls: ['report-crash.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class ReportCrashComponent {\r\n @Input() data: HomeReportCrashModel;\r\n}\r\n","\r\n \r\n \r\n \r\n {{ data?.title }}\r\n {{ data?.content }}\r\n \r\n \r\n \r\n \r\n \r\n {{ data?.contactOne?.title }}\r\n \r\n \r\n {{ data?.contactOne.phone }}\r\n \r\n \r\n \r\n {{ data?.contactOne.officeHours }}\r\n \r\n \r\n \r\n {{ data?.contactTwo?.title }}\r\n \r\n \r\n \r\n {{ data?.contactTwo?.phone }}\r\n \r\n \r\n \r\n \r\n {{ data?.contactTwo?.officeHours }}\r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { ChangeDetectionStrategy, ChangeDetectorRef, Component, Input, OnChanges, SimpleChanges } from '@angular/core';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { PagesService } from '@app/common/services/pages.service';\r\nimport { finalize, first } from 'rxjs/operators';\r\nimport { Router } from '@angular/router';\r\n\r\n@Component({\r\n selector: 'app-schedule',\r\n templateUrl: 'schedule.component.html',\r\n styleUrls: ['schedule.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class ScheduleComponent implements OnChanges {\r\n @Input() data: {\r\n title: string;\r\n subtitle: string;\r\n pageId: string;\r\n };\r\n\r\n scheduleElements: {\r\n boxTitle: string;\r\n boxSubtitle: string;\r\n boxPhone: string;\r\n schedule: { cities: string; date: string }[];\r\n };\r\n\r\n url: string;\r\n\r\n constructor(private pageService: PagesService, private cdr: ChangeDetectorRef, private router: Router) {}\r\n\r\n ngOnChanges(changes: SimpleChanges): void {\r\n if (changes.data.currentValue.pageId) {\r\n this.pageService\r\n .getOne(changes.data.currentValue.pageId)\r\n .pipe(\r\n first(),\r\n finalize(() => this.cdr.detectChanges())\r\n )\r\n .subscribe(e => {\r\n this.url = e.data.id.replace(',', '/');\r\n this.scheduleElements = e.data.attributes.content.content;\r\n this.scheduleElements.schedule = this.scheduleElements.schedule.filter(\r\n (item: any, index: number) => index < 4\r\n );\r\n });\r\n }\r\n }\r\n\r\n redirectToMore() {\r\n this.router.navigate([this.url]);\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n\r\n\r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n\r\n\r\n \r\n \r\n \r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n {{ title }}\r\n \r\n \r\n {{ text }}\r\n \r\n \r\n \r\n {{ phone }}\r\n \r\n \r\n\r\n\r\n \r\n {{ item.date }}\r\n {{ item.cities }}\r\n \r\n\r\n","export enum SitemapLoaders {\r\n GetAll = 'GetAll'\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { OverlayComponent } from '@app/template/home/components/overlay/overlay.component';\r\nimport { SearchModule } from '@app/client-core/search/search.module';\r\nimport { PromotedComponent } from '@app/template/home/components/promoted/promoted.component';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { CarouselModule } from '@app/template/elements/carousel/carousel.module';\r\nimport { LogoModule } from '@app/template/layout/modules/logo/logo.module';\r\nimport { TruncateModule } from '@share/modules/truncate/truncate.module';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { RouterModule } from '@angular/router';\r\nimport { SelectModule } from '@share/modules/html/select/select.module';\r\nimport { FormsModule } from '@angular/forms';\r\nimport { NgbCarouselModule, NgbPaginationModule } from '@ng-bootstrap/ng-bootstrap';\r\nimport { HeadingModule } from '@app/template/elements/heading/heading.module';\r\nimport { PromotedModule } from '@app/template/elements/promoted/promoted.module';\r\nimport { PolygonModule } from '@app/template/elements/polygon/polygon.module';\r\nimport { AccordionModule } from '@app/template/elements/accordion/accordion.module';\r\nimport { PaginationModule } from '@app/template/elements/pagination/pagination.module';\r\nimport { MainBannerComponent } from '@app/template/home/components/main-banner/main-banner.component';\r\nimport { ReportCrashComponent } from '@app/template/home/components/report-crash/report-crash.component';\r\nimport { ScheduleComponent } from '@app/template/home/components/schedule/schedule.component';\r\nimport { NewsComponent } from '@app/template/home/components/news/news.component';\r\nimport { GalleryComponent } from '@app/template/home/components/gallery/gallery.component';\r\nimport { SimpleBoxModule } from '@app/template/elements/simple-box/simple-box.module';\r\nimport { ArticleModule } from '@app/client-core/article/article.module';\r\n\r\n@NgModule({\r\n declarations: [\r\n GalleryComponent,\r\n NewsComponent,\r\n ScheduleComponent,\r\n ReportCrashComponent,\r\n MainBannerComponent,\r\n OverlayComponent,\r\n PromotedComponent,\r\n ],\r\n imports: [\r\n CommonModule,\r\n SearchModule,\r\n CarouselModule,\r\n ElementsModule,\r\n LogoModule,\r\n RouterModule,\r\n NgbCarouselModule,\r\n NgbPaginationModule,\r\n PromotedModule,\r\n SelectModule,\r\n FormsModule,\r\n TranslatorModule,\r\n PolygonModule,\r\n TruncateModule,\r\n AccordionModule,\r\n PaginationModule,\r\n HeadingModule,\r\n SimpleBoxModule,\r\n ArticleModule\r\n ],\r\n exports: [OverlayComponent]\r\n})\r\nexport class HomeModule {}\r\n","import { Injectable } from '@angular/core';\r\nimport { BehaviorSubject, Observable } from 'rxjs';\r\nimport { distinctUntilChanged } from 'rxjs/operators';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class HomeService {\r\n private _isHomePreview: BehaviorSubject = new BehaviorSubject(false);\r\n isHomePreview$: Observable = this._isHomePreview.asObservable().pipe(distinctUntilChanged());\r\n\r\n set isHomePreview(value: boolean) {\r\n this._isHomePreview.next(value);\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { ServiceHelper } from '@share/common/helpers/service.helper';\r\nimport { Bundle } from '@app/common/enums/server-bundles.enum';\r\nimport { Observable } from 'rxjs';\r\nimport { ResponseArray } from '@share/common/models/http.model';\r\nimport { API } from '@app/common/constants/api.directories';\r\nimport { Promoted } from '@app/template/elements/promoted/models/promoted.model';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class PromotedService extends ServiceHelper {\r\n constructor() {\r\n super(Bundle.Promoted);\r\n }\r\n\r\n public getList(): Observable> {\r\n return this.getAll(API.PROMOTED.ROOT);\r\n }\r\n}\r\n","import {Injectable} from '@angular/core';\r\nimport {ServiceHelper} from '@share/common/helpers/service.helper';\r\nimport {Bundle} from '@app/common/enums/server-bundles.enum';\r\nimport {Observable} from 'rxjs';\r\nimport {MenuModel} from '@app/client-core/menu/models/menu.model';\r\nimport {ResponseArray} from '@share/common/models/http';\r\nimport {API} from '@app/common/constants/api.directories';\r\nimport { ApiService } from '@app/common/services/api.service';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class SitemapService {\r\n\r\n constructor(private apiService: ApiService) {}\r\n\r\n getInstitutionData(): Observable {\r\n return this.apiService.get('institution');\r\n }\r\n\r\n public getList(): Observable> {\r\n return this.apiService.getAll(API.MENU.SITEMAP);\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { BreadcrumbsService } from '@app/template/layout/modules/header/services/breadcrumbs.service';\r\nimport { SubheaderService } from '@app/template/layout/modules/header/services/subheader.service';\r\nimport { Observable, of } from 'rxjs';\r\nimport { DynamicContentService } from '@app/client-core/dynamic-content/service/dynamic-content.service';\r\nimport { filter, takeUntil } from 'rxjs/operators';\r\nimport { NavigationEnd } from '@angular/router';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { SearchService } from '@app/client-core/search/services/search.service';\r\n\r\n@Component({\r\n selector: 'app-default',\r\n templateUrl: './default.component.html',\r\n styleUrls: ['./default.component.scss']\r\n})\r\nexport class DefaultComponent extends ComponentHelper {\r\n isHome: boolean = true;\r\n backdrop$: Observable;\r\n constructor(\r\n private breadcrumbsService: BreadcrumbsService,\r\n private subheaderService: SubheaderService,\r\n private settings: SettingsService,\r\n private dynamicContentService: DynamicContentService,\r\n private searchService: SearchService\r\n ) {\r\n super();\r\n this.setHome();\r\n this.backdrop$ = searchService.isActive$;\r\n }\r\n\r\n get contentLoaded(): Observable {\r\n return this.dynamicContentService.loaded$;\r\n }\r\n\r\n public deactivate() {\r\n this.breadcrumbsService.clear.next(true);\r\n this.subheaderService.reset();\r\n }\r\n\r\n private setHome() {\r\n this.service.router.events\r\n .pipe(\r\n filter((e): e is NavigationEnd => e instanceof NavigationEnd),\r\n takeUntil(this.destroyed$)\r\n )\r\n .subscribe(event => {\r\n this.isHome = event.url === '/';\r\n });\r\n }\r\n\r\n get canShow(): Observable {\r\n if (this.isHome) {\r\n return this.contentLoaded;\r\n }\r\n return of(true);\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { DefaultComponent } from './components/default/default.component';\r\nimport { HeaderModule } from '@app/template/layout/modules/header/header.module';\r\nimport { FooterModule } from '@app/template/layout/modules/footer/footer.module';\r\nimport { CookiesModule } from '@app/client-core/cookies/cookies.module';\r\nimport { DynamicContentModule } from '@app/client-core/dynamic-content/dynamic-content.module';\r\nimport { AppRoutingModule } from '@app/app-routing.module';\r\nimport { HomeModule } from '@app/template/home/home.module';\r\nimport { SiteMapModule } from '@app/template/layout/modules/sitemap/sitemap.module';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { PolygonModule } from '@app/template/elements/polygon/polygon.module';\r\n\r\n@NgModule({\r\n declarations: [DefaultComponent],\r\n imports: [\r\n CommonModule,\r\n HeaderModule,\r\n HomeModule,\r\n FooterModule,\r\n CookiesModule,\r\n DynamicContentModule,\r\n SiteMapModule,\r\n AppRoutingModule,\r\n ElementsModule,\r\n PolygonModule\r\n ]\r\n})\r\nexport class LayoutModule {}\r\n","import { NgModule } from '@angular/core';\r\nimport { BreadcrumbsComponent } from '@app/template/layout/modules/breadcrumbs/components/breadcrumbs/breadcrumbs.component';\r\nimport { CommonModule } from '@angular/common';\r\nimport { RouterModule } from '@angular/router';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\n\r\n@NgModule({\r\n declarations: [\r\n BreadcrumbsComponent\r\n ],\r\n imports: [\r\n CommonModule,\r\n RouterModule,\r\n TranslatorModule\r\n ],\r\n exports: [\r\n BreadcrumbsComponent\r\n ]\r\n})\r\nexport class BreadcrumbsModule {}\r\n","import { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { ChangeDetectorRef, Component, EventEmitter, OnInit, Output } from '@angular/core';\r\nimport { BreadcrumbsService } from '@app/template/layout/modules/header/services/breadcrumbs.service';\r\nimport { BreadcrumbsLoaders } from '@app/template/layout/modules/header/enums/breadcrumbs-loaders.enum';\r\nimport { Breadcrumbs } from '@app/template/layout/modules/header/models/breadcrumbs.model';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { AbstractData } from '@share/common/models/http';\r\n\r\n@Component({\r\n selector: 'app-breadcrumbs',\r\n templateUrl: './breadcrumbs.component.html',\r\n styleUrls: ['./breadcrumbs.component.scss']\r\n})\r\nexport class BreadcrumbsComponent extends ComponentHelper implements OnInit {\r\n public breadcrumbs: Array> = [];\r\n public shortVersion: boolean = false;\r\n public minLengthForShortVersion: number = 3;\r\n\r\n @Output() readonly loaded: EventEmitter = new EventEmitter();\r\n\r\n constructor(private breadcrumbsService: BreadcrumbsService, private cdr: ChangeDetectorRef) {\r\n super();\r\n }\r\n\r\n public get breadcrumbsExists(): boolean {\r\n return Array.isArray(this.breadcrumbs) && this.breadcrumbs.length > 0;\r\n }\r\n\r\n public ngOnInit() {\r\n this.setReloadListener();\r\n this.setClearListener();\r\n }\r\n\r\n private loadBreadcrumbs() {\r\n this.setLoader(BreadcrumbsLoaders.Get, true);\r\n this.subscriptions.add(\r\n this.breadcrumbsService.getList(this.url).subscribe(\r\n response => {\r\n this.breadcrumbs = this.getResponseData(response);\r\n this.shortVersion = this.breadcrumbs.length > this.minLengthForShortVersion;\r\n this.cdr.detectChanges();\r\n this.loaded.emit();\r\n },\r\n () => {}\r\n )\r\n );\r\n }\r\n\r\n private setReloadListener() {\r\n this.breadcrumbsService.reload.pipe(takeUntil(this.destroyed$)).subscribe(reload => {\r\n if (reload && !this.breadcrumbsService.forceActive) {\r\n this.breadcrumbsService.customBreadcrumbs = [];\r\n this.loadBreadcrumbs();\r\n this.cdr.detectChanges();\r\n }\r\n });\r\n }\r\n\r\n private setClearListener() {\r\n this.breadcrumbsService.clear.pipe(takeUntil(this.destroyed$)).subscribe(clear => {\r\n if (clear) {\r\n this.breadcrumbs = [];\r\n this.cdr.detectChanges();\r\n this.breadcrumbsService.clear.next(false);\r\n }\r\n });\r\n }\r\n\r\n public get customBreadcrumbs(): Array<{ title: string; url?: string }> {\r\n return this.breadcrumbsService.customBreadcrumbs;\r\n }\r\n\r\n private get url(): string {\r\n return this.breadcrumbsService.getParsedUrl(this.service.router.url);\r\n }\r\n\r\n public getLink(index: number): Array {\r\n const segments = this.breadcrumbsService.generateLink(this.breadcrumbs, index);\r\n\r\n if (segments.length > 1) {\r\n return [...segments];\r\n }\r\n\r\n return ['/'];\r\n }\r\n\r\n public expandBreadcrumbs(event: Event) {\r\n event.preventDefault();\r\n this.shortVersion = false;\r\n this.cdr.detectChanges();\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n {{breadcrumb.attributes.title}}\r\n {{breadcrumb.attributes.title}}\r\n \r\n \r\n {{breadcrumb.attributes.title}}\r\n \r\n \r\n \r\n \r\n \r\n {{breadcrumbs[0].attributes.title}}\r\n {{breadcrumbs[0].attributes.title}}\r\n \r\n \r\n {{'...'}}\r\n \r\n {{breadcrumbs[breadcrumbs.length - 1].attributes.title}}\r\n \r\n \r\n\r\n\r\n 0\">\r\n \r\n \r\n \r\n \r\n {{customBreadcrumb.title}}\r\n \r\n \r\n {{customBreadcrumb.title}}\r\n \r\n \r\n \r\n \r\n \r\n\r\n","import {Component, Input, OnInit} from '@angular/core';\r\n\r\n@Component({\r\n selector: 'app-container',\r\n templateUrl: './container.component.html',\r\n styles: []\r\n})\r\nexport class ContainerComponent implements OnInit {\r\n\r\n @Input() public top: number = 30;\r\n @Input() public bottom: number = 30;\r\n @Input() public left: number = 0;\r\n @Input() public right: number = 0;\r\n\r\n constructor() { }\r\n\r\n ngOnInit() {\r\n }\r\n\r\n}\r\n","\r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport {ContainerComponent} from '@app/template/layout/modules/container/components/container/container.component';\r\n\r\n@NgModule({\r\n declarations: [\r\n ContainerComponent\r\n ],\r\n imports: [\r\n CommonModule\r\n ],\r\n exports: [\r\n ContainerComponent\r\n ]\r\n})\r\nexport class ContainerModule { }\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\n\r\n@Component({\r\n selector: 'app-fatal-error',\r\n templateUrl: './fatal-error.component.html',\r\n styleUrls: ['./fatal-error.component.scss']\r\n})\r\nexport class FatalErrorComponent extends ComponentHelper implements OnInit {\r\n\r\n constructor() {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n }\r\n\r\n goToHome(): void {\r\n window.location.href = '/';\r\n }\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n {{ '500' }}\r\n {{ 'Błąd serwera' }}\r\n \r\n \r\n \r\n \r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\n\r\n@Component({\r\n selector: 'app-maintenance',\r\n templateUrl: './maintenance.component.html',\r\n styleUrls: ['./maintenance.component.scss']\r\n})\r\nexport class MaintenanceComponent extends ComponentHelper implements OnInit {\r\n\r\n constructor() {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n }\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n {{'global.maintenance' | trans}}\r\n {{'global.maintenanceText' | trans}}.\r\n \r\n \r\n\r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\n\r\n@Component({\r\n selector: 'app-not-found',\r\n templateUrl: './not-found.component.html',\r\n styleUrls: ['./not-found.component.scss']\r\n})\r\nexport class NotFoundComponent extends ComponentHelper implements OnInit {\r\n\r\n constructor() {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n }\r\n\r\n goToHome(): void {\r\n this.service.router.navigate(['']);\r\n }\r\n\r\n}\r\n","\r\n \r\n \r\n {{ '404' }}\r\n {{ 'Nie znaleziono strony' }}\r\n \r\n \r\n \r\n\r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { NotFoundComponent } from './components/not-found/not-found.component';\r\nimport { RouterModule } from '@angular/router';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { MaintenanceComponent } from './components/maintenance/maintenance.component';\r\nimport { FatalErrorComponent } from './components/fatal-error/fatal-error.component';\r\n\r\n@NgModule({\r\n declarations: [NotFoundComponent, MaintenanceComponent, FatalErrorComponent],\r\n imports: [\r\n CommonModule,\r\n RouterModule,\r\n ElementsModule,\r\n TranslatorModule\r\n ],\r\n exports: [\r\n NotFoundComponent,\r\n MaintenanceComponent\r\n ]\r\n})\r\nexport class ErrorPagesModule {\r\n}\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { VersionService } from '@share/common/services/version.service';\r\n\r\n@Component({\r\n selector: 'app-footer',\r\n templateUrl: './footer.component.html',\r\n styleUrls: ['./footer.component.scss']\r\n})\r\nexport class FooterComponent extends ComponentHelper implements OnInit {\r\n public footer: string;\r\n public version: string;\r\n\r\n constructor(private settingsService: SettingsService, private versionService: VersionService) {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n this.footer = this.settingsService.variables.footer.footer;\r\n }\r\n}\r\n","\r\n","import {NgModule} from '@angular/core';\r\nimport {CommonModule} from '@angular/common';\r\nimport {FooterComponent} from './components/footer/footer.component';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\n\r\n@NgModule({\r\n declarations: [FooterComponent],\r\n imports: [\r\n CommonModule,\r\n TranslatorModule,\r\n ElementsModule\r\n ],\r\n exports: [\r\n FooterComponent\r\n ]\r\n})\r\nexport class FooterModule {\r\n}\r\n","import { ChangeDetectionStrategy, Component } from '@angular/core';\r\n\r\ndeclare let $: any;\r\n\r\n@Component({\r\n selector: 'app-a11y-font-size',\r\n styleUrls: ['a11y-font-size.component.scss'],\r\n templateUrl: 'a11y-font-size.component.html',\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class A11yFontSizeComponent {\r\n constructor() {}\r\n\r\n setDefaultFontSize() {\r\n this.changeFontSize('10px');\r\n }\r\n setBiggerFontSize() {\r\n this.changeFontSize('11px');\r\n }\r\n setBigFontSize() {\r\n this.changeFontSize('12px');\r\n }\r\n\r\n private changeFontSize(size: string) {\r\n $('html').css({\r\n 'font-size': size\r\n });\r\n }\r\n}\r\n","\r\n \r\n \r\n domyślna czcionka\r\n A\r\n \r\n \r\n \r\n \r\n większa czcionka\r\n A\r\n \r\n \r\n \r\n \r\n największa czcionka\r\n A\r\n \r\n \r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { GoogleTranslateService } from '@app/common/services/google-translate.service';\r\n\r\n@Component({\r\n selector: 'app-google-translator',\r\n templateUrl: './google-translator.component.html',\r\n styleUrls: [\r\n './google-translator.component.scss'\r\n ]\r\n})\r\nexport class GoogleTranslatorComponent implements OnInit {\r\n\r\n constructor(private googleTranslateService: GoogleTranslateService) {}\r\n\r\n public ngOnInit() {\r\n this.googleTranslateService.init();\r\n }\r\n\r\n}\r\n","\r\n","import { AfterViewInit, Component, ElementRef, Inject, OnInit, ViewChild, ViewContainerRef } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { DOCUMENT } from '@angular/common';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { LazyLoaderService } from '@app/common/services/lazy-loader.service';\r\nimport { ThemesEnum } from '@app/common/models/themes.enum';\r\nimport { ResizeListener } from '@app/common/services/resize-listener.service';\r\nimport { SearchService } from '@app/client-core/search/services/search.service';\r\nimport { fromEvent, Observable } from 'rxjs';\r\nimport { MenuService } from '@app/client-core/menu/services/menu.service';\r\nimport { debounceTime, filter, finalize, first, takeUntil, tap } from 'rxjs/operators';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { MenuModel } from '@app/client-core/menu/models/menu.model';\r\n\r\ndeclare let $: Function;\r\n\r\n@Component({\r\n selector: 'app-header',\r\n templateUrl: './header-container.component.html',\r\n styleUrls: [\r\n './header-container.component.scss',\r\n './header-container-contrast.component.scss',\r\n ]\r\n})\r\nexport class HeaderContainerComponent extends ComponentHelper implements OnInit, AfterViewInit {\r\n isAuthenticated: boolean = false;\r\n search: string;\r\n\r\n @ViewChild('alertBtn', { read: ViewContainerRef }) alertBtn: ViewContainerRef;\r\n @ViewChild('menu', { read: ViewContainerRef }) menu: ViewContainerRef;\r\n\r\n private startDistance = 10;\r\n\r\n isMobileSearchActive$: Observable;\r\n isValidDefaultMenuWidth: boolean;\r\n isMobileMenuMode: boolean;\r\n isDefaultMenuWidthChecking: boolean;\r\n isFetchMenuLoading: boolean;\r\n menuData: AbstractData[];\r\n\r\n constructor(\r\n @Inject(DOCUMENT) private document: Document,\r\n private settings: SettingsService,\r\n private loader: LazyLoaderService,\r\n public resizeListener: ResizeListener,\r\n private searchService: SearchService,\r\n private menuService: MenuService,\r\n private _elementRef: ElementRef\r\n ) {\r\n super();\r\n }\r\n\r\n get isSubpage(): boolean {\r\n return !this.service.router.isActive('', true);\r\n }\r\n\r\n get isAlertModuleEnabled(): boolean {\r\n return this.settings.isModuleActive(ThemesEnum.ALERT);\r\n }\r\n\r\n get isMenuModuleEnabled(): boolean {\r\n return this.settings.isModuleActive(ThemesEnum.MENU);\r\n }\r\n\r\n /** Metoda sprawdzająca, czy zawartość menu dla desktop'ów nie wystaje poza szerokość okna/headera. */\r\n get isValidHeaderContentWidth(): boolean {\r\n const contentElementRef: HTMLElement = this.document.querySelector('#main-app-header .content') as HTMLElement;\r\n const contentElementChildren: HTMLElement[] = Array.from(contentElementRef.children) as HTMLElement[];\r\n const contentElementAvailableWidth: number = contentElementRef.offsetWidth\r\n - (parseInt(getComputedStyle(contentElementRef).paddingLeft))\r\n - (parseInt(getComputedStyle(contentElementRef).paddingRight))\r\n - 30 // ScrollBar with small offset.\r\n ;\r\n\r\n let contentChildrenWidth: number = 0;\r\n\r\n contentElementChildren.forEach(child => {\r\n contentChildrenWidth += child.offsetWidth;\r\n });\r\n\r\n return contentChildrenWidth <= contentElementAvailableWidth\r\n }\r\n\r\n ngOnInit() {\r\n this.fetchMenu();\r\n window.addEventListener('scroll', () => this.scroll(), true);\r\n this.scroll();\r\n this.isMobileSearchActive$ = this.searchService.isActive$;\r\n this.searchService.isActive$.pipe(takeUntil(this.destroyed$)).subscribe(isActive => {\r\n if (isActive) {\r\n this.menuService.isMobileMenuActive$.next(false);\r\n }\r\n });\r\n this.handleOutsideClick();\r\n }\r\n\r\n ngAfterViewInit() {\r\n this.generateAlertButton();\r\n this.generateMenu();\r\n }\r\n\r\n private setMenuModeChangeListener() {\r\n this.resizeListener.isMobile$.pipe(\r\n takeUntil(this.destroyed$),\r\n tap((value) => this.isMobileMenuMode = value),\r\n filter((value) => !value),\r\n tap(() => {\r\n this.isDefaultMenuWidthChecking = true;\r\n this.isValidDefaultMenuWidth = true; // Pokazanie menu, aby JS mógł obliczyć szerokość wewnątrz komponentu.\r\n }),\r\n debounceTime(500),\r\n ).subscribe((value) => {\r\n this.setIsMobileMenuMode();\r\n });\r\n }\r\n\r\n private fetchMenu() {\r\n this.isFetchMenuLoading = true;\r\n\r\n this.menuService\r\n .getList()\r\n .pipe(\r\n first(),\r\n finalize(() => this.isFetchMenuLoading = false)\r\n )\r\n .subscribe(\r\n response => {\r\n this.menuData = response.data;\r\n this.setMenuModeChangeListener();\r\n }\r\n );\r\n }\r\n\r\n private setIsMobileMenuMode(): void {\r\n // setTimeout z racji wymaganego opóźnienia przy obliczaniu dostępnej szerokosci.\r\n setTimeout(() => {\r\n this.isValidDefaultMenuWidth = this.isValidHeaderContentWidth;\r\n });\r\n\r\n this.isDefaultMenuWidthChecking = false;\r\n }\r\n\r\n generateAlertButton() {\r\n if (this.alertBtn && this.isAlertModuleEnabled) {\r\n this.loader.load(ThemesEnum.ALERT, this.alertBtn);\r\n }\r\n }\r\n\r\n generateMenu() {\r\n if (this.menu) {\r\n this.menu?.clear();\r\n if (this.isMenuModuleEnabled || this.isAuthenticated) {\r\n this.loader.load(ThemesEnum.MENU, this.menu);\r\n }\r\n }\r\n }\r\n\r\n handleOutsideClick() {\r\n const clickEvent$ = fromEvent(document, 'click');\r\n clickEvent$\r\n .pipe(\r\n takeUntil(this.destroyed$),\r\n filter(e => !this._elementRef.nativeElement.contains(e.target)),\r\n tap(e => {\r\n this.searchService.isActive$.next(false);\r\n })\r\n )\r\n .subscribe();\r\n }\r\n\r\n\r\n private scroll() {\r\n const scrollTop = $(this.document).scrollTop(),\r\n header = $('header');\r\n if (scrollTop >= this.startDistance) {\r\n header.addClass('sticked');\r\n } else {\r\n header.removeClass('sticked');\r\n }\r\n }\r\n\r\n onComponentRefresh() {\r\n this.fetchMenu();\r\n }\r\n}\r\n","\r\n Dolina baryczy\r\n \r\n \r\n \r\n {{ 'global.search' | trans }}\r\n \r\n \r\n \r\n {{ 'global.settings' | trans }}\r\n \r\n \r\n \r\n {{'global.contrast' | trans}}\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { AfterViewInit, Component, OnInit, Renderer2 } from '@angular/core';\r\n\r\ndeclare let $: Function;\r\n\r\n@Component({\r\n selector: 'app-high-contrast',\r\n templateUrl: './high-contrast.component.html',\r\n styleUrls: ['./high-contrast.component.scss']\r\n})\r\nexport class HighContrastComponent implements OnInit, AfterViewInit {\r\n constructor(private renderer: Renderer2) {}\r\n\r\n ngOnInit(): void {}\r\n\r\n ngAfterViewInit(): void {\r\n const contrast: string = localStorage.getItem('contrast') as string;\r\n if (contrast) {\r\n switch (contrast) {\r\n case 'blackwhite':\r\n this.addBlackWhite();\r\n break;\r\n case 'yellowblack':\r\n this.addYellowBlack();\r\n break;\r\n }\r\n }\r\n }\r\n\r\n removeContrast() {\r\n this.renderer.removeClass(document.body, localStorage.getItem('contrast') as string);\r\n this.renderer.setStyle(document.body, 'color', '');\r\n this.renderer.setStyle(document.body, 'background-color', '');\r\n\r\n localStorage.setItem('contrast', 'normal');\r\n }\r\n\r\n addYellowBlack() {\r\n this.removeContrast();\r\n this.renderer.addClass(document.body, 'yellowblack');\r\n\r\n this.renderer.setStyle(document.body, 'background-color', 'black');\r\n this.renderer.setStyle(document.body, 'color', 'yellow');\r\n\r\n localStorage.setItem('contrast', 'yellowblack');\r\n }\r\n\r\n addBlackWhite() {\r\n this.removeContrast();\r\n this.renderer.addClass(document.body, 'blackwhite');\r\n\r\n this.renderer.setStyle(document.body, 'background-color', 'white');\r\n this.renderer.setStyle(document.body, 'color', 'black');\r\n\r\n localStorage.setItem('contrast', 'blackwhite');\r\n }\r\n}\r\n","\r\n \r\n \r\n brak wysokiego kontrastu\r\n A\r\n \r\n \r\n \r\n \r\n czarno-biały\r\n A\r\n \r\n \r\n \r\n \r\n żółto-czarny\r\n A\r\n \r\n \r\n\r\n","export { SubheaderDescriptionComponent } from './subheader/subheader-description/subheader-description.component';\r\nexport { SubheaderTitleComponent } from './subheader/subheader-title/subheader-title.component';\r\nexport { SubheaderComponent } from './subheader/subheader.component';\r\nexport { GoogleTranslatorComponent } from './google-translator/google-translator.component';\r\nexport { HeaderContainerComponent } from './header-container/header-container.component';\r\nexport { LanguageComponent } from './language/language.component';\r\nexport { A11yFontSizeComponent } from './a11y-font-size/a11y-font-size.component';\r\n","import {ComponentHelper} from '@app/common/helpers/component.helper';\r\nimport {Component, ViewEncapsulation} from '@angular/core';\r\n\r\n@Component({\r\n selector: 'app-language',\r\n templateUrl: './language.component.html',\r\n styleUrls: ['./language.component.scss'],\r\n})\r\nexport class LanguageComponent extends ComponentHelper {\r\n\r\n public language: string = 'pl';\r\n\r\n constructor() {\r\n super();\r\n }\r\n\r\n changeLanguage(): void {\r\n alert('TODO');\r\n }\r\n}\r\n","\r\n","import { Component, Input } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'cms-subheader-description',\r\n templateUrl: 'subheader-description.component.html',\r\n styleUrls: ['subheader-description.component.scss']\r\n})\r\nexport class SubheaderDescriptionComponent {\r\n @Input() text: string;\r\n @Input() isMobile: boolean;\r\n}\r\n","{{text}}\r\n","import { Component, ElementRef, EventEmitter, Input, Output, ViewChild } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'cms-subheader-title',\r\n templateUrl: 'subheader-title.component.html',\r\n styleUrls: ['subheader-title.component.scss']\r\n})\r\nexport class SubheaderTitleComponent {\r\n\r\n isEditable: boolean = false;\r\n\r\n @Input() title: string;\r\n @Input() isMobile: boolean;\r\n @Input() set editable(editable: boolean) {\r\n this.isEditable = editable;\r\n setTimeout(() => this.text.nativeElement.focus());\r\n };\r\n\r\n @ViewChild('text') text: ElementRef;\r\n\r\n @Output() onSubmitEditable: EventEmitter = new EventEmitter();\r\n\r\n onSubmit() {\r\n this.isEditable = false;\r\n this.onSubmitEditable.emit(this.text.nativeElement.innerText);\r\n }\r\n\r\n}\r\n","{{ title }}\r\n","import { AfterViewInit, Component, Injector } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { SubheaderConfig } from '@app/template/layout/modules/header/interfaces/subheader-config.interface';\r\nimport { BreadcrumbsService } from '@app/template/layout/modules/header/services/breadcrumbs.service';\r\nimport { NavigationEnd } from '@angular/router';\r\nimport { filter, takeUntil } from 'rxjs/operators';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { DynamicContentService } from '@app/client-core/dynamic-content/service/dynamic-content.service';\r\nimport { Observable } from 'rxjs';\r\nimport { HomeService } from '@app/template/home/services/home.service';\r\n\r\n@Component({\r\n selector: 'app-subheader',\r\n templateUrl: './subheader.component.html',\r\n styleUrls: ['./subheader.component.scss']\r\n})\r\nexport class SubheaderComponent extends ComponentHelper implements AfterViewInit {\r\n active: boolean = false;\r\n isHome: boolean = false;\r\n\r\n constructor(\r\n private breadcrumbsService: BreadcrumbsService,\r\n private settings: SettingsService,\r\n private dynamicContentService: DynamicContentService,\r\n private homeService: HomeService\r\n ) {\r\n super();\r\n this.setHome();\r\n }\r\n\r\n get contentLoaded(): Observable {\r\n return this.dynamicContentService.loaded$;\r\n }\r\n\r\n get isHomePreview(): Observable {\r\n return this.homeService.isHomePreview$;\r\n }\r\n\r\n private setHome() {\r\n this.service.router.events\r\n .pipe(\r\n filter((e): e is NavigationEnd => e instanceof NavigationEnd),\r\n takeUntil(this.destroyed$)\r\n )\r\n .subscribe(event => {\r\n this.isHome = event.url === '/';\r\n });\r\n }\r\n\r\n get component() {\r\n return this.service.subheader.config.component;\r\n }\r\n\r\n get config(): SubheaderConfig {\r\n return this.service.subheader.config;\r\n }\r\n\r\n get myInjector(): Injector | null | undefined {\r\n return this.service.subheader.config.injector;\r\n }\r\n\r\n get displayBreadcrumbs() {\r\n return this.service.subheader.config.displayBreadcrumbs;\r\n }\r\n\r\n get forceShow() {\r\n return this.service.subheader.config.forceShow;\r\n }\r\n\r\n get categories(): { title: string; slug: string }[] | undefined {\r\n return this.service.subheader.config.categories;\r\n }\r\n\r\n get publishedDate(): string | undefined {\r\n return this.service.subheader.config.publishedDate;\r\n }\r\n\r\n get image(): string | undefined {\r\n return this.service.subheader.config.image;\r\n }\r\n\r\n get hideDots(): boolean {\r\n return this.service.subheader.config.hideDots || false;\r\n }\r\n\r\n ngAfterViewInit(): void {\r\n this.breadcrumbsService.reload.next(true);\r\n }\r\n\r\n isArray(categories: { title: string; slug: string }[] | string | undefined): boolean {\r\n return Array.isArray(categories);\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n {{ category.attributes.title }}\r\n \r\n \r\n {{ publishedDate | date: 'shortDate':'':'pl' }}\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","export enum BreadcrumbsLoaders {\r\n Get = 'Get'\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { WcagModule } from '@share/modules/wcag/wcag.module';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { LogoModule } from '@app/template/layout/modules/logo/logo.module';\r\nimport { SearchModule } from '@app/client-core/search/search.module';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { RouterModule } from '@angular/router';\r\nimport {\r\n A11yFontSizeComponent,\r\n GoogleTranslatorComponent,\r\n HeaderContainerComponent,\r\n LanguageComponent,\r\n SubheaderComponent,\r\n SubheaderDescriptionComponent,\r\n SubheaderTitleComponent\r\n} from './components';\r\nimport { BreadcrumbsModule } from '@app/template/layout/modules/breadcrumbs/breadcrumbs.module';\r\nimport { HttpClientModule } from '@angular/common/http';\r\nimport { MenuModule } from '@app/client-core/menu/menu.module';\r\nimport { InputModule } from '@share/modules/html/input/input.module';\r\nimport { FormsModule } from '@angular/forms';\r\nimport { HighContrastComponent } from './components/high-contrast/high-contrast.component';\r\n\r\n@NgModule({\r\n declarations: [\r\n LanguageComponent,\r\n SubheaderTitleComponent,\r\n SubheaderDescriptionComponent,\r\n GoogleTranslatorComponent,\r\n HeaderContainerComponent,\r\n SubheaderComponent,\r\n A11yFontSizeComponent,\r\n HighContrastComponent\r\n ],\r\n imports: [\r\n CommonModule,\r\n WcagModule,\r\n LogoModule,\r\n ElementsModule,\r\n HttpClientModule,\r\n SearchModule,\r\n ElementsModule,\r\n TranslatorModule,\r\n RouterModule,\r\n BreadcrumbsModule,\r\n MenuModule,\r\n InputModule,\r\n FormsModule\r\n ],\r\n exports: [HeaderContainerComponent, SubheaderComponent, SubheaderTitleComponent, SubheaderDescriptionComponent]\r\n})\r\nexport class HeaderModule {}\r\n","import { ReplaySubject } from 'rxjs';\r\nimport { Injector } from '@angular/core';\r\n\r\nexport interface SubheaderConfig {\r\n title: string;\r\n description: string;\r\n displayHeader: boolean;\r\n displayBreadcrumbs: ReplaySubject;\r\n searchOpen: boolean;\r\n searchType: SearchType;\r\n component: any;\r\n categories?: { slug: string; title: string }[];\r\n hideSearch: boolean;\r\n injector?: Injector | null;\r\n forceShow: boolean;\r\n publishedDate?: string;\r\n image?: string;\r\n hideDots?: boolean\r\n}\r\n\r\nexport enum SearchType {\r\n Default = '',\r\n EServices = 'eservice',\r\n None = ''\r\n}\r\n\r\nexport enum SearchTypeNames {\r\n Default = 'Wszędzie',\r\n EServices = 'Katalog e-usług'\r\n}\r\n","import { ServiceHelper } from '@share/common/helpers/service.helper';\r\nimport { Bundle } from '@app/common/enums/server-bundles.enum';\r\nimport { Injectable } from '@angular/core';\r\nimport { BehaviorSubject, Observable } from 'rxjs';\r\nimport { AbstractData, ResponseArray } from '@share/common/models/http';\r\nimport { Breadcrumbs } from '@app/template/layout/modules/header/models/breadcrumbs.model';\r\nimport { API } from '@app/common/constants/api.directories';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class BreadcrumbsService extends ServiceHelper {\r\n reload: BehaviorSubject = new BehaviorSubject(false);\r\n clear: BehaviorSubject = new BehaviorSubject(false);\r\n customBreadcrumbs: Array<{ title: string; url?: string }> = [];\r\n forceActive = false;\r\n\r\n constructor() {\r\n super(Bundle.Breadcrumbs);\r\n }\r\n\r\n public getList(url: string): Observable> {\r\n return this.getAll(`${API.COMMON.BREADCRUMBS}/,${url}`);\r\n }\r\n\r\n public getParsedUrl(url: string): string {\r\n return url.substr(1, url.length).split('/').join(',');\r\n }\r\n\r\n public generateLink(breadcrumbs: Array>, index: number): Array {\r\n let path: Array = [];\r\n try {\r\n for (let i = 0; i < (index + 1); i++) {\r\n path.push(breadcrumbs[i].attributes.url);\r\n }\r\n } catch (_ignore) {\r\n path = [];\r\n }\r\n return path;\r\n }\r\n\r\n public reset() {\r\n this.reload.next(true);\r\n }\r\n}\r\n","import { Injectable, Injector } from '@angular/core';\r\nimport { BehaviorSubject, Observable, ReplaySubject } from 'rxjs';\r\nimport { SearchType, SubheaderConfig } from '@app/template/layout/modules/header/interfaces/subheader-config.interface';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class SubheaderService {\r\n private _config: BehaviorSubject;\r\n\r\n constructor() {\r\n this._config = new BehaviorSubject(this.default);\r\n }\r\n\r\n private get default(): SubheaderConfig {\r\n return {\r\n title: '',\r\n description: '',\r\n searchType: SearchType.None,\r\n component: null,\r\n displayHeader: true,\r\n displayBreadcrumbs: new ReplaySubject(1),\r\n searchOpen: false,\r\n hideSearch: false,\r\n injector: null,\r\n forceShow: false,\r\n categories: [],\r\n hideDots: false\r\n };\r\n }\r\n\r\n public get config(): SubheaderConfig {\r\n return this._config.getValue();\r\n }\r\n\r\n public getConfig(): Observable> {\r\n return this._config.asObservable();\r\n }\r\n\r\n public setConfig(value: Partial) {\r\n this._config.next({ ...this.default, ...value });\r\n }\r\n\r\n public set title(title: string) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n title\r\n });\r\n }\r\n\r\n public set description(description: string) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n description\r\n });\r\n }\r\n\r\n public set searchType(searchType: SearchType) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n searchType\r\n });\r\n }\r\n\r\n public set searchOpen(searchOpen: boolean) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n searchOpen\r\n });\r\n }\r\n\r\n public set injector(injector: Injector) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n injector\r\n });\r\n }\r\n\r\n public set forceShow(forceShow: boolean) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n forceShow\r\n });\r\n }\r\n\r\n public set displayBreadcrumbs(show: boolean) {\r\n this.config.displayBreadcrumbs.next(show);\r\n }\r\n\r\n set categories(categories: { slug: string; title: string }[]) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n categories\r\n });\r\n }\r\n\r\n set publishedDate(publishedDate: string) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n publishedDate\r\n });\r\n }\r\n\r\n set image(image: string) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n image\r\n });\r\n }\r\n\r\n set hideDots(hideDots: boolean) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n hideDots\r\n });\r\n }\r\n\r\n public reset() {\r\n this.setConfig(this.default);\r\n }\r\n}\r\n","import { Component, Input, OnDestroy, OnInit } from '@angular/core';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { Subject } from 'rxjs';\r\n\r\n@Component({\r\n selector: 'app-logo',\r\n templateUrl: './logo.component.html',\r\n styleUrls: ['./logo.component.scss']\r\n})\r\nexport class LogoComponent implements OnInit, OnDestroy {\r\n private destroy$: Subject = new Subject();\r\n url: string;\r\n\r\n @Input() id: string = 'logo';\r\n @Input() isAlt: boolean;\r\n @Input() preventChange: boolean;\r\n\r\n constructor(private layoutService: SettingsService) {}\r\n\r\n ngOnInit() {\r\n if (this.isAlt) {\r\n this.url = this.layoutService.variables.site.altLogo;\r\n } else {\r\n this.url = this.layoutService.variables.site.logo;\r\n }\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.destroy$.next(true);\r\n this.destroy$.complete();\r\n }\r\n}\r\n","\r\n Strona główna\r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { LogoComponent } from '@app/template/layout/modules/logo/components/logo/logo.component';\r\nimport { RouterModule } from '@angular/router';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n RouterModule,\r\n TranslatorModule\r\n ],\r\n declarations: [\r\n LogoComponent\r\n ],\r\n exports: [\r\n LogoComponent\r\n ]\r\n})\r\nexport class LogoModule {}\r\n","import { Component, ElementRef, Input, OnDestroy, OnInit, Renderer2 } from '@angular/core';\r\nimport { AbstractData } from '@share/common/models/http.model';\r\nimport { MenuModel } from '@app/client-core/menu/models/menu.model';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\n\r\n@Component({\r\n selector: 'app-sitemap-item',\r\n templateUrl: './sitemap-item.component.html',\r\n styleUrls: [\r\n './sitemap-item.component.scss'\r\n ]\r\n})\r\nexport class SitemapItemComponent extends ComponentHelper implements OnInit, OnDestroy {\r\n @Input() item: AbstractData;\r\n public listenClickFunc: Function;\r\n\r\n constructor(private renderer: Renderer2,\r\n private _elementRef: ElementRef) {\r\n super();\r\n }\r\n\r\n public ngOnInit() {\r\n this.onClickListener();\r\n }\r\n\r\n public openInNewTab(event: Event, url: string) {\r\n event.preventDefault();\r\n event.stopPropagation();\r\n window.open(url);\r\n }\r\n\r\n private onClickListener() {\r\n this.listenClickFunc = this.renderer.listen(\r\n this._elementRef.nativeElement, 'click', (event) => this.service.utils.navigateTo(event)\r\n );\r\n }\r\n\r\n public ngOnDestroy() {\r\n this.listenClickFunc();\r\n }\r\n}\r\n","{{item.attributes.title}}\r\n\r\n \r\n {{subitem.attributes.title}}\r\n \r\n {{subitem.attributes.title}}\r\n \r\n \r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { SitemapService } from '@app/template/home/services/sitemap.service';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { MenuModel } from '@app/client-core/menu/models/menu.model';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { SitemapLoaders } from '@app/template/home/enums/sitemap-loaders.enum';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { finalize, first } from 'rxjs/operators';\r\nimport { InstitutionModel } from '@app/template/layout/modules/sitemap/models/institution.model';\r\n\r\n@Component({\r\n selector: 'app-sitemap',\r\n templateUrl: './sitemap.component.html',\r\n styleUrls: ['./sitemap.component.scss']\r\n})\r\nexport class SitemapComponent extends ComponentHelper implements OnInit {\r\n sitemap: Array> = [];\r\n SitemapLoaders = SitemapLoaders;\r\n description: string;\r\n institution: AbstractData;\r\n constructor(private sitemapService: SitemapService, private settingService: SettingsService) {\r\n super();\r\n }\r\n\r\n public ngOnInit() {\r\n this.loadSitemap();\r\n this.getInstitutionData();\r\n }\r\n\r\n getInstitutionData() {\r\n this.sitemapService\r\n .getInstitutionData()\r\n .pipe(first())\r\n .subscribe(response => (this.institution = response.data));\r\n }\r\n\r\n public loadSitemap() {\r\n this.setLoader(SitemapLoaders.GetAll, true);\r\n this.sitemapService\r\n .getList()\r\n .pipe(\r\n first(),\r\n finalize(() => this.setLoader(SitemapLoaders.GetAll, false))\r\n )\r\n .subscribe(\r\n response => (this.sitemap = this.getResponseData(response)),\r\n () => this.setComponentError()\r\n );\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n {{institution?.attributes?.name}}\r\n \r\n \r\n \r\n {{ institution?.attributes?.address?.zipCode }} {{ institution?.attributes?.address?.city }}\r\n ul. {{ institution?.attributes?.address?.street }} {{ institution?.attributes?.address?.houseNumber }}\r\n {{\r\n institution?.attributes?.address?.apartmentNumber\r\n ? '/' + institution?.attributes?.address?.apartmentNumber\r\n : ''\r\n }}\r\n \r\n \r\n \r\n \r\n \r\n {{ institution?.attributes?.contact?.phoneNumber }}\r\n \r\n \r\n \r\n {{ institution?.attributes?.contact?.phoneNumberSecondary }}\r\n \r\n \r\n \r\n {{ institution?.attributes?.contact?.fax }}\r\n \r\n \r\n \r\n {{ institution?.attributes?.contact?.email }}\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n 0\">\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { LogoModule } from '@app/template/layout/modules/logo/logo.module';\r\nimport { RouterModule } from '@angular/router';\r\nimport { SitemapComponent } from '@app/template/layout/modules/sitemap/components/sitemap/sitemap.component';\r\nimport { SitemapItemComponent } from '@app/template/layout/modules/sitemap/components/sitemap/sitemap-item/sitemap-item.component';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\n\r\n@NgModule({\r\n declarations: [\r\n SitemapComponent,\r\n SitemapItemComponent,\r\n ],\r\n imports: [\r\n CommonModule,\r\n ElementsModule,\r\n LogoModule,\r\n RouterModule,\r\n TranslatorModule,\r\n ],\r\n exports: [\r\n SitemapComponent\r\n ]\r\n})\r\nexport class SiteMapModule {\r\n}\r\n\r\n","// This file can be replaced during build by using the `fileReplacements` array.\r\n// `ng build --prod` replaces `environment.ts` with `environment.prod.ts`.\r\n// The list of file replacements can be found in `angular.json`.\r\n\r\nexport const environment = {\r\n production: false\r\n};\r\n\r\n/*\r\n * For easier debugging in development mode, you can import the following file\r\n * to ignore zone related error stack frames such as `zone.run`, `zoneDelegate.invokeTask`.\r\n *\r\n * This import should be commented out in production mode because it will have a negative impact\r\n * on performance if an error is thrown.\r\n */\r\n// import 'zone.js/dist/zone-error'; // Included with Angular CLI.\r\n","import {enableProdMode} from '@angular/core';\r\nimport {platformBrowserDynamic} from '@angular/platform-browser-dynamic';\r\n\r\nimport {AppModule} from './app/app.module';\r\nimport {environment} from './environments/environment';\r\nimport 'hammerjs';\r\n\r\nif (environment.production) {\r\n enableProdMode();\r\n}\r\n\r\nplatformBrowserDynamic().bootstrapModule(AppModule)\r\n .catch(err => console.error(err));\r\n"]}
[];\r\n loading: boolean;\r\n getError: boolean;\r\n\r\n @Input() data: {\r\n title: string;\r\n subtitle: string;\r\n category: string;\r\n };\r\n\r\n constructor(\r\n private articleService: ArticlesService,\r\n private cdr: ChangeDetectorRef,\r\n private pageService: PagesService,\r\n private router: Router,\r\n private dynamicContentService: DynamicContentService\r\n ) {}\r\n\r\n ngOnChanges(changes: SimpleChanges): void {\r\n if (changes.data.currentValue) {\r\n this.getNews();\r\n }\r\n }\r\n\r\n setLoader(value: boolean) {\r\n this.loading = value;\r\n this.cdr.detectChanges();\r\n }\r\n\r\n test() {\r\n this.pageService.getOne();\r\n }\r\n\r\n getNews() {\r\n this.setLoader(true);\r\n this.pageService\r\n .getOne(this.data.category)\r\n .pipe(\r\n first(),\r\n finalize(() => this.setLoader(false))\r\n )\r\n .subscribe(\r\n response => this.getMetadata(response.data.id),\r\n error => (this.getError = true)\r\n );\r\n }\r\n\r\n getMetadata(url: string) {\r\n this.dynamicContentService\r\n .getPageMetadata(url)\r\n .pipe(switchMap(metadata => this.articleService.getList(1, 4, metadata.meta?.objectId)))\r\n .subscribe(news => {\r\n this.news = news.data;\r\n this.cdr.detectChanges();\r\n });\r\n }\r\n\r\n showMoreClicked() {\r\n this.router.navigate(['aktualnosci']);\r\n }\r\n\r\n readMoreClicked(item: AbstractData) {\r\n this.router.navigate(['aktualnosci', item.attributes.slug]);\r\n }\r\n}\r\n","\r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n\r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n\r\n \r\n {{\r\n category.attributes.title\r\n }}\r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n {{ item.attributes.title }}\r\n \r\n \r\n {{ item.attributes.publishedFrom | date: 'shortDate':'':'pl' }}\r\n \r\n \r\n {{ item.attributes.description }}\r\n \r\n \r\n \r\n \r\n\r\n","import {\r\n AfterViewInit,\r\n ChangeDetectionStrategy,\r\n ChangeDetectorRef,\r\n Component,\r\n Input,\r\n OnInit,\r\n ViewChild,\r\n ViewContainerRef\r\n} from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { LazyLoaderService } from '@app/common/services/lazy-loader.service';\r\nimport { ROUTES_PATHS } from '@app/common/constants/routes-paths';\r\nimport { Router } from '@angular/router';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { finalize, first } from 'rxjs/operators';\r\nimport { HomeService } from '@app/template/home/services/home.service';\r\nimport { PagesService } from '@app/common/services/pages.service';\r\nimport { PageModel } from '@app/common/models/page.model';\r\nimport { HomeModel } from '@app/template/home/models/home.model';\r\n\r\n@Component({\r\n selector: 'app-home',\r\n templateUrl: './overlay.component.html',\r\n styleUrls: ['./overlay.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class OverlayComponent extends ComponentHelper implements OnInit, AfterViewInit {\r\n @ViewChild('businessModules', { read: ViewContainerRef }) businessModules: ViewContainerRef;\r\n @Input() data: AbstractData>;\r\n loading: boolean = true;\r\n\r\n constructor(\r\n private settingsService: SettingsService,\r\n private lazyLoaderService: LazyLoaderService,\r\n private pagesService: PagesService,\r\n private router: Router,\r\n private cdr: ChangeDetectorRef,\r\n private homeService: HomeService\r\n ) {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n this.service.scrollTo.resetScrollTop();\r\n }\r\n\r\n private setLoading(value: boolean) {\r\n this.loading = value;\r\n this.cdr.markForCheck();\r\n }\r\n\r\n getMainPage() {\r\n this.setLoading(true);\r\n this.pagesService\r\n .getOne()\r\n .pipe(\r\n first(),\r\n finalize(() => this.setLoading(false))\r\n )\r\n .subscribe(\r\n response => {\r\n this.data = response.data;\r\n },\r\n () => {\r\n this.router.navigate(['/', ROUTES_PATHS.notFoundPage.root]);\r\n }\r\n );\r\n }\r\n\r\n ngAfterViewInit() {\r\n if (!this.data) {\r\n this.getMainPage();\r\n } else {\r\n this.loading = false;\r\n this.homeService.isHomePreview = true;\r\n }\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n\r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { ChangeDetectionStrategy, ChangeDetectorRef, Component, Input, OnInit } from '@angular/core';\r\nimport { PromotedService } from '@app/template/home/services/promoted.service';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { Promoted } from '@app/template/elements/promoted/models/promoted.model';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { finalize, first } from 'rxjs/operators';\r\n\r\n@Component({\r\n selector: 'app-promoted',\r\n templateUrl: './promoted.component.html',\r\n styleUrls: ['./promoted.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class PromotedComponent extends ComponentHelper implements OnInit {\r\n @Input() data: { title: string; subtitle: string };\r\n promoted: Array> = [];\r\n loading: boolean = false;\r\n\r\n constructor(private promotedService: PromotedService, private cdr: ChangeDetectorRef) {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n this.loadPromoted();\r\n }\r\n\r\n loadPromoted() {\r\n this.setLoading(true);\r\n this.promotedService\r\n .getList()\r\n .pipe(\r\n first(),\r\n finalize(() => this.setLoading(false))\r\n )\r\n .subscribe(\r\n response => (this.promoted = this.getResponseData(response)),\r\n () => this.setComponentError()\r\n );\r\n }\r\n\r\n private setLoading(value: boolean) {\r\n this.loading = value;\r\n this.cdr.markForCheck();\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { ChangeDetectionStrategy, Component, Input } from '@angular/core';\r\nimport { HomeReportCrashModel } from '@app/template/home/models/home-report-crash.model';\r\n\r\n@Component({\r\n selector: 'app-report-crash',\r\n templateUrl: 'report-crash.component.html',\r\n styleUrls: ['report-crash.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class ReportCrashComponent {\r\n @Input() data: HomeReportCrashModel;\r\n}\r\n","\r\n \r\n \r\n \r\n {{ data?.title }}\r\n {{ data?.content }}\r\n \r\n \r\n \r\n \r\n \r\n {{ data?.contactOne?.title }}\r\n \r\n \r\n {{ data?.contactOne.phone }}\r\n \r\n \r\n \r\n {{ data?.contactOne.officeHours }}\r\n \r\n \r\n \r\n {{ data?.contactTwo?.title }}\r\n \r\n \r\n \r\n {{ data?.contactTwo?.phone }}\r\n \r\n \r\n \r\n \r\n {{ data?.contactTwo?.officeHours }}\r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { ChangeDetectionStrategy, ChangeDetectorRef, Component, Input, OnChanges, SimpleChanges } from '@angular/core';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { PagesService } from '@app/common/services/pages.service';\r\nimport { finalize, first } from 'rxjs/operators';\r\nimport { Router } from '@angular/router';\r\n\r\n@Component({\r\n selector: 'app-schedule',\r\n templateUrl: 'schedule.component.html',\r\n styleUrls: ['schedule.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class ScheduleComponent implements OnChanges {\r\n @Input() data: {\r\n title: string;\r\n subtitle: string;\r\n pageId: string;\r\n };\r\n\r\n scheduleElements: {\r\n boxTitle: string;\r\n boxSubtitle: string;\r\n boxPhone: string;\r\n schedule: { cities: string; date: string }[];\r\n };\r\n\r\n url: string;\r\n\r\n constructor(private pageService: PagesService, private cdr: ChangeDetectorRef, private router: Router) {}\r\n\r\n ngOnChanges(changes: SimpleChanges): void {\r\n if (changes.data.currentValue.pageId) {\r\n this.pageService\r\n .getOne(changes.data.currentValue.pageId)\r\n .pipe(\r\n first(),\r\n finalize(() => this.cdr.detectChanges())\r\n )\r\n .subscribe(e => {\r\n this.url = e.data.id.replace(',', '/');\r\n this.scheduleElements = e.data.attributes.content.content;\r\n this.scheduleElements.schedule = this.scheduleElements.schedule.filter(\r\n (item: any, index: number) => index < 4\r\n );\r\n });\r\n }\r\n }\r\n\r\n redirectToMore() {\r\n this.router.navigate([this.url]);\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n\r\n\r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n\r\n\r\n \r\n \r\n \r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n {{ title }}\r\n \r\n \r\n {{ text }}\r\n \r\n \r\n \r\n {{ phone }}\r\n \r\n \r\n\r\n\r\n \r\n {{ item.date }}\r\n {{ item.cities }}\r\n \r\n\r\n","export enum SitemapLoaders {\r\n GetAll = 'GetAll'\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { OverlayComponent } from '@app/template/home/components/overlay/overlay.component';\r\nimport { SearchModule } from '@app/client-core/search/search.module';\r\nimport { PromotedComponent } from '@app/template/home/components/promoted/promoted.component';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { CarouselModule } from '@app/template/elements/carousel/carousel.module';\r\nimport { LogoModule } from '@app/template/layout/modules/logo/logo.module';\r\nimport { TruncateModule } from '@share/modules/truncate/truncate.module';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { RouterModule } from '@angular/router';\r\nimport { SelectModule } from '@share/modules/html/select/select.module';\r\nimport { FormsModule } from '@angular/forms';\r\nimport { NgbCarouselModule, NgbPaginationModule } from '@ng-bootstrap/ng-bootstrap';\r\nimport { HeadingModule } from '@app/template/elements/heading/heading.module';\r\nimport { PromotedModule } from '@app/template/elements/promoted/promoted.module';\r\nimport { PolygonModule } from '@app/template/elements/polygon/polygon.module';\r\nimport { AccordionModule } from '@app/template/elements/accordion/accordion.module';\r\nimport { PaginationModule } from '@app/template/elements/pagination/pagination.module';\r\nimport { MainBannerComponent } from '@app/template/home/components/main-banner/main-banner.component';\r\nimport { ReportCrashComponent } from '@app/template/home/components/report-crash/report-crash.component';\r\nimport { ScheduleComponent } from '@app/template/home/components/schedule/schedule.component';\r\nimport { NewsComponent } from '@app/template/home/components/news/news.component';\r\nimport { GalleryComponent } from '@app/template/home/components/gallery/gallery.component';\r\nimport { SimpleBoxModule } from '@app/template/elements/simple-box/simple-box.module';\r\nimport { ArticleModule } from '@app/client-core/article/article.module';\r\n\r\n@NgModule({\r\n declarations: [\r\n GalleryComponent,\r\n NewsComponent,\r\n ScheduleComponent,\r\n ReportCrashComponent,\r\n MainBannerComponent,\r\n OverlayComponent,\r\n PromotedComponent,\r\n ],\r\n imports: [\r\n CommonModule,\r\n SearchModule,\r\n CarouselModule,\r\n ElementsModule,\r\n LogoModule,\r\n RouterModule,\r\n NgbCarouselModule,\r\n NgbPaginationModule,\r\n PromotedModule,\r\n SelectModule,\r\n FormsModule,\r\n TranslatorModule,\r\n PolygonModule,\r\n TruncateModule,\r\n AccordionModule,\r\n PaginationModule,\r\n HeadingModule,\r\n SimpleBoxModule,\r\n ArticleModule\r\n ],\r\n exports: [OverlayComponent]\r\n})\r\nexport class HomeModule {}\r\n","import { Injectable } from '@angular/core';\r\nimport { BehaviorSubject, Observable } from 'rxjs';\r\nimport { distinctUntilChanged } from 'rxjs/operators';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class HomeService {\r\n private _isHomePreview: BehaviorSubject = new BehaviorSubject(false);\r\n isHomePreview$: Observable = this._isHomePreview.asObservable().pipe(distinctUntilChanged());\r\n\r\n set isHomePreview(value: boolean) {\r\n this._isHomePreview.next(value);\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { ServiceHelper } from '@share/common/helpers/service.helper';\r\nimport { Bundle } from '@app/common/enums/server-bundles.enum';\r\nimport { Observable } from 'rxjs';\r\nimport { ResponseArray } from '@share/common/models/http.model';\r\nimport { API } from '@app/common/constants/api.directories';\r\nimport { Promoted } from '@app/template/elements/promoted/models/promoted.model';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class PromotedService extends ServiceHelper {\r\n constructor() {\r\n super(Bundle.Promoted);\r\n }\r\n\r\n public getList(): Observable> {\r\n return this.getAll(API.PROMOTED.ROOT);\r\n }\r\n}\r\n","import {Injectable} from '@angular/core';\r\nimport {ServiceHelper} from '@share/common/helpers/service.helper';\r\nimport {Bundle} from '@app/common/enums/server-bundles.enum';\r\nimport {Observable} from 'rxjs';\r\nimport {MenuModel} from '@app/client-core/menu/models/menu.model';\r\nimport {ResponseArray} from '@share/common/models/http';\r\nimport {API} from '@app/common/constants/api.directories';\r\nimport { ApiService } from '@app/common/services/api.service';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class SitemapService {\r\n\r\n constructor(private apiService: ApiService) {}\r\n\r\n getInstitutionData(): Observable {\r\n return this.apiService.get('institution');\r\n }\r\n\r\n public getList(): Observable> {\r\n return this.apiService.getAll(API.MENU.SITEMAP);\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { BreadcrumbsService } from '@app/template/layout/modules/header/services/breadcrumbs.service';\r\nimport { SubheaderService } from '@app/template/layout/modules/header/services/subheader.service';\r\nimport { Observable, of } from 'rxjs';\r\nimport { DynamicContentService } from '@app/client-core/dynamic-content/service/dynamic-content.service';\r\nimport { filter, takeUntil } from 'rxjs/operators';\r\nimport { NavigationEnd } from '@angular/router';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { SearchService } from '@app/client-core/search/services/search.service';\r\n\r\n@Component({\r\n selector: 'app-default',\r\n templateUrl: './default.component.html',\r\n styleUrls: ['./default.component.scss']\r\n})\r\nexport class DefaultComponent extends ComponentHelper {\r\n isHome: boolean = true;\r\n backdrop$: Observable;\r\n constructor(\r\n private breadcrumbsService: BreadcrumbsService,\r\n private subheaderService: SubheaderService,\r\n private settings: SettingsService,\r\n private dynamicContentService: DynamicContentService,\r\n private searchService: SearchService\r\n ) {\r\n super();\r\n this.setHome();\r\n this.backdrop$ = searchService.isActive$;\r\n }\r\n\r\n get contentLoaded(): Observable {\r\n return this.dynamicContentService.loaded$;\r\n }\r\n\r\n public deactivate() {\r\n this.breadcrumbsService.clear.next(true);\r\n this.subheaderService.reset();\r\n }\r\n\r\n private setHome() {\r\n this.service.router.events\r\n .pipe(\r\n filter((e): e is NavigationEnd => e instanceof NavigationEnd),\r\n takeUntil(this.destroyed$)\r\n )\r\n .subscribe(event => {\r\n this.isHome = event.url === '/';\r\n });\r\n }\r\n\r\n get canShow(): Observable {\r\n if (this.isHome) {\r\n return this.contentLoaded;\r\n }\r\n return of(true);\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { DefaultComponent } from './components/default/default.component';\r\nimport { HeaderModule } from '@app/template/layout/modules/header/header.module';\r\nimport { FooterModule } from '@app/template/layout/modules/footer/footer.module';\r\nimport { CookiesModule } from '@app/client-core/cookies/cookies.module';\r\nimport { DynamicContentModule } from '@app/client-core/dynamic-content/dynamic-content.module';\r\nimport { AppRoutingModule } from '@app/app-routing.module';\r\nimport { HomeModule } from '@app/template/home/home.module';\r\nimport { SiteMapModule } from '@app/template/layout/modules/sitemap/sitemap.module';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { PolygonModule } from '@app/template/elements/polygon/polygon.module';\r\n\r\n@NgModule({\r\n declarations: [DefaultComponent],\r\n imports: [\r\n CommonModule,\r\n HeaderModule,\r\n HomeModule,\r\n FooterModule,\r\n CookiesModule,\r\n DynamicContentModule,\r\n SiteMapModule,\r\n AppRoutingModule,\r\n ElementsModule,\r\n PolygonModule\r\n ]\r\n})\r\nexport class LayoutModule {}\r\n","import { NgModule } from '@angular/core';\r\nimport { BreadcrumbsComponent } from '@app/template/layout/modules/breadcrumbs/components/breadcrumbs/breadcrumbs.component';\r\nimport { CommonModule } from '@angular/common';\r\nimport { RouterModule } from '@angular/router';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\n\r\n@NgModule({\r\n declarations: [\r\n BreadcrumbsComponent\r\n ],\r\n imports: [\r\n CommonModule,\r\n RouterModule,\r\n TranslatorModule\r\n ],\r\n exports: [\r\n BreadcrumbsComponent\r\n ]\r\n})\r\nexport class BreadcrumbsModule {}\r\n","import { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { ChangeDetectorRef, Component, EventEmitter, OnInit, Output } from '@angular/core';\r\nimport { BreadcrumbsService } from '@app/template/layout/modules/header/services/breadcrumbs.service';\r\nimport { BreadcrumbsLoaders } from '@app/template/layout/modules/header/enums/breadcrumbs-loaders.enum';\r\nimport { Breadcrumbs } from '@app/template/layout/modules/header/models/breadcrumbs.model';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { AbstractData } from '@share/common/models/http';\r\n\r\n@Component({\r\n selector: 'app-breadcrumbs',\r\n templateUrl: './breadcrumbs.component.html',\r\n styleUrls: ['./breadcrumbs.component.scss']\r\n})\r\nexport class BreadcrumbsComponent extends ComponentHelper implements OnInit {\r\n public breadcrumbs: Array> = [];\r\n public shortVersion: boolean = false;\r\n public minLengthForShortVersion: number = 3;\r\n\r\n @Output() readonly loaded: EventEmitter = new EventEmitter();\r\n\r\n constructor(private breadcrumbsService: BreadcrumbsService, private cdr: ChangeDetectorRef) {\r\n super();\r\n }\r\n\r\n public get breadcrumbsExists(): boolean {\r\n return Array.isArray(this.breadcrumbs) && this.breadcrumbs.length > 0;\r\n }\r\n\r\n public ngOnInit() {\r\n this.setReloadListener();\r\n this.setClearListener();\r\n }\r\n\r\n private loadBreadcrumbs() {\r\n this.setLoader(BreadcrumbsLoaders.Get, true);\r\n this.subscriptions.add(\r\n this.breadcrumbsService.getList(this.url).subscribe(\r\n response => {\r\n this.breadcrumbs = this.getResponseData(response);\r\n this.shortVersion = this.breadcrumbs.length > this.minLengthForShortVersion;\r\n this.cdr.detectChanges();\r\n this.loaded.emit();\r\n },\r\n () => {}\r\n )\r\n );\r\n }\r\n\r\n private setReloadListener() {\r\n this.breadcrumbsService.reload.pipe(takeUntil(this.destroyed$)).subscribe(reload => {\r\n if (reload && !this.breadcrumbsService.forceActive) {\r\n this.breadcrumbsService.customBreadcrumbs = [];\r\n this.loadBreadcrumbs();\r\n this.cdr.detectChanges();\r\n }\r\n });\r\n }\r\n\r\n private setClearListener() {\r\n this.breadcrumbsService.clear.pipe(takeUntil(this.destroyed$)).subscribe(clear => {\r\n if (clear) {\r\n this.breadcrumbs = [];\r\n this.cdr.detectChanges();\r\n this.breadcrumbsService.clear.next(false);\r\n }\r\n });\r\n }\r\n\r\n public get customBreadcrumbs(): Array<{ title: string; url?: string }> {\r\n return this.breadcrumbsService.customBreadcrumbs;\r\n }\r\n\r\n private get url(): string {\r\n return this.breadcrumbsService.getParsedUrl(this.service.router.url);\r\n }\r\n\r\n public getLink(index: number): Array {\r\n const segments = this.breadcrumbsService.generateLink(this.breadcrumbs, index);\r\n\r\n if (segments.length > 1) {\r\n return [...segments];\r\n }\r\n\r\n return ['/'];\r\n }\r\n\r\n public expandBreadcrumbs(event: Event) {\r\n event.preventDefault();\r\n this.shortVersion = false;\r\n this.cdr.detectChanges();\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n {{breadcrumb.attributes.title}}\r\n {{breadcrumb.attributes.title}}\r\n \r\n \r\n {{breadcrumb.attributes.title}}\r\n \r\n \r\n \r\n \r\n \r\n {{breadcrumbs[0].attributes.title}}\r\n {{breadcrumbs[0].attributes.title}}\r\n \r\n \r\n {{'...'}}\r\n \r\n {{breadcrumbs[breadcrumbs.length - 1].attributes.title}}\r\n \r\n \r\n\r\n\r\n 0\">\r\n \r\n \r\n \r\n \r\n {{customBreadcrumb.title}}\r\n \r\n \r\n {{customBreadcrumb.title}}\r\n \r\n \r\n \r\n \r\n \r\n\r\n","import {Component, Input, OnInit} from '@angular/core';\r\n\r\n@Component({\r\n selector: 'app-container',\r\n templateUrl: './container.component.html',\r\n styles: []\r\n})\r\nexport class ContainerComponent implements OnInit {\r\n\r\n @Input() public top: number = 30;\r\n @Input() public bottom: number = 30;\r\n @Input() public left: number = 0;\r\n @Input() public right: number = 0;\r\n\r\n constructor() { }\r\n\r\n ngOnInit() {\r\n }\r\n\r\n}\r\n","\r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport {ContainerComponent} from '@app/template/layout/modules/container/components/container/container.component';\r\n\r\n@NgModule({\r\n declarations: [\r\n ContainerComponent\r\n ],\r\n imports: [\r\n CommonModule\r\n ],\r\n exports: [\r\n ContainerComponent\r\n ]\r\n})\r\nexport class ContainerModule { }\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\n\r\n@Component({\r\n selector: 'app-fatal-error',\r\n templateUrl: './fatal-error.component.html',\r\n styleUrls: ['./fatal-error.component.scss']\r\n})\r\nexport class FatalErrorComponent extends ComponentHelper implements OnInit {\r\n\r\n constructor() {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n }\r\n\r\n goToHome(): void {\r\n window.location.href = '/';\r\n }\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n {{ '500' }}\r\n {{ 'Błąd serwera' }}\r\n \r\n \r\n \r\n \r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\n\r\n@Component({\r\n selector: 'app-maintenance',\r\n templateUrl: './maintenance.component.html',\r\n styleUrls: ['./maintenance.component.scss']\r\n})\r\nexport class MaintenanceComponent extends ComponentHelper implements OnInit {\r\n\r\n constructor() {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n }\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n {{'global.maintenance' | trans}}\r\n {{'global.maintenanceText' | trans}}.\r\n \r\n \r\n\r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\n\r\n@Component({\r\n selector: 'app-not-found',\r\n templateUrl: './not-found.component.html',\r\n styleUrls: ['./not-found.component.scss']\r\n})\r\nexport class NotFoundComponent extends ComponentHelper implements OnInit {\r\n\r\n constructor() {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n }\r\n\r\n goToHome(): void {\r\n this.service.router.navigate(['']);\r\n }\r\n\r\n}\r\n","\r\n \r\n \r\n {{ '404' }}\r\n {{ 'Nie znaleziono strony' }}\r\n \r\n \r\n \r\n\r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { NotFoundComponent } from './components/not-found/not-found.component';\r\nimport { RouterModule } from '@angular/router';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { MaintenanceComponent } from './components/maintenance/maintenance.component';\r\nimport { FatalErrorComponent } from './components/fatal-error/fatal-error.component';\r\n\r\n@NgModule({\r\n declarations: [NotFoundComponent, MaintenanceComponent, FatalErrorComponent],\r\n imports: [\r\n CommonModule,\r\n RouterModule,\r\n ElementsModule,\r\n TranslatorModule\r\n ],\r\n exports: [\r\n NotFoundComponent,\r\n MaintenanceComponent\r\n ]\r\n})\r\nexport class ErrorPagesModule {\r\n}\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { VersionService } from '@share/common/services/version.service';\r\n\r\n@Component({\r\n selector: 'app-footer',\r\n templateUrl: './footer.component.html',\r\n styleUrls: ['./footer.component.scss']\r\n})\r\nexport class FooterComponent extends ComponentHelper implements OnInit {\r\n public footer: string;\r\n public version: string;\r\n\r\n constructor(private settingsService: SettingsService, private versionService: VersionService) {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n this.footer = this.settingsService.variables.footer.footer;\r\n }\r\n}\r\n","\r\n","import {NgModule} from '@angular/core';\r\nimport {CommonModule} from '@angular/common';\r\nimport {FooterComponent} from './components/footer/footer.component';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\n\r\n@NgModule({\r\n declarations: [FooterComponent],\r\n imports: [\r\n CommonModule,\r\n TranslatorModule,\r\n ElementsModule\r\n ],\r\n exports: [\r\n FooterComponent\r\n ]\r\n})\r\nexport class FooterModule {\r\n}\r\n","import { ChangeDetectionStrategy, Component } from '@angular/core';\r\n\r\ndeclare let $: any;\r\n\r\n@Component({\r\n selector: 'app-a11y-font-size',\r\n styleUrls: ['a11y-font-size.component.scss'],\r\n templateUrl: 'a11y-font-size.component.html',\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class A11yFontSizeComponent {\r\n constructor() {}\r\n\r\n setDefaultFontSize() {\r\n this.changeFontSize('10px');\r\n }\r\n setBiggerFontSize() {\r\n this.changeFontSize('11px');\r\n }\r\n setBigFontSize() {\r\n this.changeFontSize('12px');\r\n }\r\n\r\n private changeFontSize(size: string) {\r\n $('html').css({\r\n 'font-size': size\r\n });\r\n }\r\n}\r\n","\r\n \r\n \r\n domyślna czcionka\r\n A\r\n \r\n \r\n \r\n \r\n większa czcionka\r\n A\r\n \r\n \r\n \r\n \r\n największa czcionka\r\n A\r\n \r\n \r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { GoogleTranslateService } from '@app/common/services/google-translate.service';\r\n\r\n@Component({\r\n selector: 'app-google-translator',\r\n templateUrl: './google-translator.component.html',\r\n styleUrls: [\r\n './google-translator.component.scss'\r\n ]\r\n})\r\nexport class GoogleTranslatorComponent implements OnInit {\r\n\r\n constructor(private googleTranslateService: GoogleTranslateService) {}\r\n\r\n public ngOnInit() {\r\n this.googleTranslateService.init();\r\n }\r\n\r\n}\r\n","\r\n","import { AfterViewInit, Component, ElementRef, Inject, OnInit, ViewChild, ViewContainerRef } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { DOCUMENT } from '@angular/common';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { LazyLoaderService } from '@app/common/services/lazy-loader.service';\r\nimport { ThemesEnum } from '@app/common/models/themes.enum';\r\nimport { ResizeListener } from '@app/common/services/resize-listener.service';\r\nimport { SearchService } from '@app/client-core/search/services/search.service';\r\nimport { fromEvent, Observable } from 'rxjs';\r\nimport { MenuService } from '@app/client-core/menu/services/menu.service';\r\nimport { debounceTime, filter, finalize, first, takeUntil, tap } from 'rxjs/operators';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { MenuModel } from '@app/client-core/menu/models/menu.model';\r\n\r\ndeclare let $: Function;\r\n\r\n@Component({\r\n selector: 'app-header',\r\n templateUrl: './header-container.component.html',\r\n styleUrls: [\r\n './header-container.component.scss',\r\n './header-container-contrast.component.scss',\r\n ]\r\n})\r\nexport class HeaderContainerComponent extends ComponentHelper implements OnInit, AfterViewInit {\r\n isAuthenticated: boolean = false;\r\n search: string;\r\n\r\n @ViewChild('alertBtn', { read: ViewContainerRef }) alertBtn: ViewContainerRef;\r\n @ViewChild('menu', { read: ViewContainerRef }) menu: ViewContainerRef;\r\n\r\n private startDistance = 10;\r\n\r\n isMobileSearchActive$: Observable;\r\n isValidDefaultMenuWidth: boolean;\r\n isMobileMenuMode: boolean;\r\n isDefaultMenuWidthChecking: boolean;\r\n isFetchMenuLoading: boolean;\r\n menuData: AbstractData[];\r\n\r\n constructor(\r\n @Inject(DOCUMENT) private document: Document,\r\n private settings: SettingsService,\r\n private loader: LazyLoaderService,\r\n public resizeListener: ResizeListener,\r\n private searchService: SearchService,\r\n private menuService: MenuService,\r\n private _elementRef: ElementRef\r\n ) {\r\n super();\r\n }\r\n\r\n get isSubpage(): boolean {\r\n return !this.service.router.isActive('', true);\r\n }\r\n\r\n get isAlertModuleEnabled(): boolean {\r\n return this.settings.isModuleActive(ThemesEnum.ALERT);\r\n }\r\n\r\n get isMenuModuleEnabled(): boolean {\r\n return this.settings.isModuleActive(ThemesEnum.MENU);\r\n }\r\n\r\n /** Metoda sprawdzająca, czy zawartość menu dla desktop'ów nie wystaje poza szerokość okna/headera. */\r\n get isValidHeaderContentWidth(): boolean {\r\n const contentElementRef: HTMLElement = this.document.querySelector('#main-app-header .content') as HTMLElement;\r\n const contentElementChildren: HTMLElement[] = Array.from(contentElementRef.children) as HTMLElement[];\r\n const contentElementAvailableWidth: number = contentElementRef.offsetWidth\r\n - (parseInt(getComputedStyle(contentElementRef).paddingLeft))\r\n - (parseInt(getComputedStyle(contentElementRef).paddingRight))\r\n - 30 // ScrollBar with small offset.\r\n ;\r\n\r\n let contentChildrenWidth: number = 0;\r\n\r\n contentElementChildren.forEach(child => {\r\n contentChildrenWidth += child.offsetWidth;\r\n });\r\n\r\n return contentChildrenWidth <= contentElementAvailableWidth\r\n }\r\n\r\n ngOnInit() {\r\n this.fetchMenu();\r\n window.addEventListener('scroll', () => this.scroll(), true);\r\n this.scroll();\r\n this.isMobileSearchActive$ = this.searchService.isActive$;\r\n this.searchService.isActive$.pipe(takeUntil(this.destroyed$)).subscribe(isActive => {\r\n if (isActive) {\r\n this.menuService.isMobileMenuActive$.next(false);\r\n }\r\n });\r\n this.handleOutsideClick();\r\n }\r\n\r\n ngAfterViewInit() {\r\n this.generateAlertButton();\r\n this.generateMenu();\r\n }\r\n\r\n private setMenuModeChangeListener() {\r\n this.resizeListener.isMobile$.pipe(\r\n takeUntil(this.destroyed$),\r\n tap((value) => this.isMobileMenuMode = value),\r\n filter((value) => !value),\r\n tap(() => {\r\n this.isDefaultMenuWidthChecking = true;\r\n this.isValidDefaultMenuWidth = true; // Pokazanie menu, aby JS mógł obliczyć szerokość wewnątrz komponentu.\r\n }),\r\n debounceTime(500),\r\n ).subscribe((value) => {\r\n this.setIsMobileMenuMode();\r\n });\r\n }\r\n\r\n private fetchMenu() {\r\n this.isFetchMenuLoading = true;\r\n\r\n this.menuService\r\n .getList()\r\n .pipe(\r\n first(),\r\n finalize(() => this.isFetchMenuLoading = false)\r\n )\r\n .subscribe(\r\n response => {\r\n this.menuData = response.data;\r\n this.setMenuModeChangeListener();\r\n }\r\n );\r\n }\r\n\r\n private setIsMobileMenuMode(): void {\r\n // setTimeout z racji wymaganego opóźnienia przy obliczaniu dostępnej szerokosci.\r\n setTimeout(() => {\r\n this.isValidDefaultMenuWidth = this.isValidHeaderContentWidth;\r\n });\r\n\r\n this.isDefaultMenuWidthChecking = false;\r\n }\r\n\r\n generateAlertButton() {\r\n if (this.alertBtn && this.isAlertModuleEnabled) {\r\n this.loader.load(ThemesEnum.ALERT, this.alertBtn);\r\n }\r\n }\r\n\r\n generateMenu() {\r\n if (this.menu) {\r\n this.menu?.clear();\r\n if (this.isMenuModuleEnabled || this.isAuthenticated) {\r\n this.loader.load(ThemesEnum.MENU, this.menu);\r\n }\r\n }\r\n }\r\n\r\n handleOutsideClick() {\r\n const clickEvent$ = fromEvent(document, 'click');\r\n clickEvent$\r\n .pipe(\r\n takeUntil(this.destroyed$),\r\n filter(e => !this._elementRef.nativeElement.contains(e.target)),\r\n tap(e => {\r\n this.searchService.isActive$.next(false);\r\n })\r\n )\r\n .subscribe();\r\n }\r\n\r\n\r\n private scroll() {\r\n const scrollTop = $(this.document).scrollTop(),\r\n header = $('header');\r\n if (scrollTop >= this.startDistance) {\r\n header.addClass('sticked');\r\n } else {\r\n header.removeClass('sticked');\r\n }\r\n }\r\n\r\n onComponentRefresh() {\r\n this.fetchMenu();\r\n }\r\n}\r\n","\r\n Dolina baryczy\r\n \r\n \r\n \r\n {{ 'global.search' | trans }}\r\n \r\n \r\n \r\n {{ 'global.settings' | trans }}\r\n \r\n \r\n \r\n {{'global.contrast' | trans}}\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { AfterViewInit, Component, OnInit, Renderer2 } from '@angular/core';\r\n\r\ndeclare let $: Function;\r\n\r\n@Component({\r\n selector: 'app-high-contrast',\r\n templateUrl: './high-contrast.component.html',\r\n styleUrls: ['./high-contrast.component.scss']\r\n})\r\nexport class HighContrastComponent implements OnInit, AfterViewInit {\r\n constructor(private renderer: Renderer2) {}\r\n\r\n ngOnInit(): void {}\r\n\r\n ngAfterViewInit(): void {\r\n const contrast: string = localStorage.getItem('contrast') as string;\r\n if (contrast) {\r\n switch (contrast) {\r\n case 'blackwhite':\r\n this.addBlackWhite();\r\n break;\r\n case 'yellowblack':\r\n this.addYellowBlack();\r\n break;\r\n }\r\n }\r\n }\r\n\r\n removeContrast() {\r\n this.renderer.removeClass(document.body, localStorage.getItem('contrast') as string);\r\n this.renderer.setStyle(document.body, 'color', '');\r\n this.renderer.setStyle(document.body, 'background-color', '');\r\n\r\n localStorage.setItem('contrast', 'normal');\r\n }\r\n\r\n addYellowBlack() {\r\n this.removeContrast();\r\n this.renderer.addClass(document.body, 'yellowblack');\r\n\r\n this.renderer.setStyle(document.body, 'background-color', 'black');\r\n this.renderer.setStyle(document.body, 'color', 'yellow');\r\n\r\n localStorage.setItem('contrast', 'yellowblack');\r\n }\r\n\r\n addBlackWhite() {\r\n this.removeContrast();\r\n this.renderer.addClass(document.body, 'blackwhite');\r\n\r\n this.renderer.setStyle(document.body, 'background-color', 'white');\r\n this.renderer.setStyle(document.body, 'color', 'black');\r\n\r\n localStorage.setItem('contrast', 'blackwhite');\r\n }\r\n}\r\n","\r\n \r\n \r\n brak wysokiego kontrastu\r\n A\r\n \r\n \r\n \r\n \r\n czarno-biały\r\n A\r\n \r\n \r\n \r\n \r\n żółto-czarny\r\n A\r\n \r\n \r\n\r\n","export { SubheaderDescriptionComponent } from './subheader/subheader-description/subheader-description.component';\r\nexport { SubheaderTitleComponent } from './subheader/subheader-title/subheader-title.component';\r\nexport { SubheaderComponent } from './subheader/subheader.component';\r\nexport { GoogleTranslatorComponent } from './google-translator/google-translator.component';\r\nexport { HeaderContainerComponent } from './header-container/header-container.component';\r\nexport { LanguageComponent } from './language/language.component';\r\nexport { A11yFontSizeComponent } from './a11y-font-size/a11y-font-size.component';\r\n","import {ComponentHelper} from '@app/common/helpers/component.helper';\r\nimport {Component, ViewEncapsulation} from '@angular/core';\r\n\r\n@Component({\r\n selector: 'app-language',\r\n templateUrl: './language.component.html',\r\n styleUrls: ['./language.component.scss'],\r\n})\r\nexport class LanguageComponent extends ComponentHelper {\r\n\r\n public language: string = 'pl';\r\n\r\n constructor() {\r\n super();\r\n }\r\n\r\n changeLanguage(): void {\r\n alert('TODO');\r\n }\r\n}\r\n","\r\n","import { Component, Input } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'cms-subheader-description',\r\n templateUrl: 'subheader-description.component.html',\r\n styleUrls: ['subheader-description.component.scss']\r\n})\r\nexport class SubheaderDescriptionComponent {\r\n @Input() text: string;\r\n @Input() isMobile: boolean;\r\n}\r\n","{{text}}\r\n","import { Component, ElementRef, EventEmitter, Input, Output, ViewChild } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'cms-subheader-title',\r\n templateUrl: 'subheader-title.component.html',\r\n styleUrls: ['subheader-title.component.scss']\r\n})\r\nexport class SubheaderTitleComponent {\r\n\r\n isEditable: boolean = false;\r\n\r\n @Input() title: string;\r\n @Input() isMobile: boolean;\r\n @Input() set editable(editable: boolean) {\r\n this.isEditable = editable;\r\n setTimeout(() => this.text.nativeElement.focus());\r\n };\r\n\r\n @ViewChild('text') text: ElementRef;\r\n\r\n @Output() onSubmitEditable: EventEmitter = new EventEmitter();\r\n\r\n onSubmit() {\r\n this.isEditable = false;\r\n this.onSubmitEditable.emit(this.text.nativeElement.innerText);\r\n }\r\n\r\n}\r\n","{{ title }}\r\n","import { AfterViewInit, Component, Injector } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { SubheaderConfig } from '@app/template/layout/modules/header/interfaces/subheader-config.interface';\r\nimport { BreadcrumbsService } from '@app/template/layout/modules/header/services/breadcrumbs.service';\r\nimport { NavigationEnd } from '@angular/router';\r\nimport { filter, takeUntil } from 'rxjs/operators';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { DynamicContentService } from '@app/client-core/dynamic-content/service/dynamic-content.service';\r\nimport { Observable } from 'rxjs';\r\nimport { HomeService } from '@app/template/home/services/home.service';\r\n\r\n@Component({\r\n selector: 'app-subheader',\r\n templateUrl: './subheader.component.html',\r\n styleUrls: ['./subheader.component.scss']\r\n})\r\nexport class SubheaderComponent extends ComponentHelper implements AfterViewInit {\r\n active: boolean = false;\r\n isHome: boolean = false;\r\n\r\n constructor(\r\n private breadcrumbsService: BreadcrumbsService,\r\n private settings: SettingsService,\r\n private dynamicContentService: DynamicContentService,\r\n private homeService: HomeService\r\n ) {\r\n super();\r\n this.setHome();\r\n }\r\n\r\n get contentLoaded(): Observable {\r\n return this.dynamicContentService.loaded$;\r\n }\r\n\r\n get isHomePreview(): Observable {\r\n return this.homeService.isHomePreview$;\r\n }\r\n\r\n private setHome() {\r\n this.service.router.events\r\n .pipe(\r\n filter((e): e is NavigationEnd => e instanceof NavigationEnd),\r\n takeUntil(this.destroyed$)\r\n )\r\n .subscribe(event => {\r\n this.isHome = event.url === '/';\r\n });\r\n }\r\n\r\n get component() {\r\n return this.service.subheader.config.component;\r\n }\r\n\r\n get config(): SubheaderConfig {\r\n return this.service.subheader.config;\r\n }\r\n\r\n get myInjector(): Injector | null | undefined {\r\n return this.service.subheader.config.injector;\r\n }\r\n\r\n get displayBreadcrumbs() {\r\n return this.service.subheader.config.displayBreadcrumbs;\r\n }\r\n\r\n get forceShow() {\r\n return this.service.subheader.config.forceShow;\r\n }\r\n\r\n get categories(): { title: string; slug: string }[] | undefined {\r\n return this.service.subheader.config.categories;\r\n }\r\n\r\n get publishedDate(): string | undefined {\r\n return this.service.subheader.config.publishedDate;\r\n }\r\n\r\n get image(): string | undefined {\r\n return this.service.subheader.config.image;\r\n }\r\n\r\n get hideDots(): boolean {\r\n return this.service.subheader.config.hideDots || false;\r\n }\r\n\r\n ngAfterViewInit(): void {\r\n this.breadcrumbsService.reload.next(true);\r\n }\r\n\r\n isArray(categories: { title: string; slug: string }[] | string | undefined): boolean {\r\n return Array.isArray(categories);\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n {{ category.attributes.title }}\r\n \r\n \r\n {{ publishedDate | date: 'shortDate':'':'pl' }}\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","export enum BreadcrumbsLoaders {\r\n Get = 'Get'\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { WcagModule } from '@share/modules/wcag/wcag.module';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { LogoModule } from '@app/template/layout/modules/logo/logo.module';\r\nimport { SearchModule } from '@app/client-core/search/search.module';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { RouterModule } from '@angular/router';\r\nimport {\r\n A11yFontSizeComponent,\r\n GoogleTranslatorComponent,\r\n HeaderContainerComponent,\r\n LanguageComponent,\r\n SubheaderComponent,\r\n SubheaderDescriptionComponent,\r\n SubheaderTitleComponent\r\n} from './components';\r\nimport { BreadcrumbsModule } from '@app/template/layout/modules/breadcrumbs/breadcrumbs.module';\r\nimport { HttpClientModule } from '@angular/common/http';\r\nimport { MenuModule } from '@app/client-core/menu/menu.module';\r\nimport { InputModule } from '@share/modules/html/input/input.module';\r\nimport { FormsModule } from '@angular/forms';\r\nimport { HighContrastComponent } from './components/high-contrast/high-contrast.component';\r\n\r\n@NgModule({\r\n declarations: [\r\n LanguageComponent,\r\n SubheaderTitleComponent,\r\n SubheaderDescriptionComponent,\r\n GoogleTranslatorComponent,\r\n HeaderContainerComponent,\r\n SubheaderComponent,\r\n A11yFontSizeComponent,\r\n HighContrastComponent\r\n ],\r\n imports: [\r\n CommonModule,\r\n WcagModule,\r\n LogoModule,\r\n ElementsModule,\r\n HttpClientModule,\r\n SearchModule,\r\n ElementsModule,\r\n TranslatorModule,\r\n RouterModule,\r\n BreadcrumbsModule,\r\n MenuModule,\r\n InputModule,\r\n FormsModule\r\n ],\r\n exports: [HeaderContainerComponent, SubheaderComponent, SubheaderTitleComponent, SubheaderDescriptionComponent]\r\n})\r\nexport class HeaderModule {}\r\n","import { ReplaySubject } from 'rxjs';\r\nimport { Injector } from '@angular/core';\r\n\r\nexport interface SubheaderConfig {\r\n title: string;\r\n description: string;\r\n displayHeader: boolean;\r\n displayBreadcrumbs: ReplaySubject;\r\n searchOpen: boolean;\r\n searchType: SearchType;\r\n component: any;\r\n categories?: { slug: string; title: string }[];\r\n hideSearch: boolean;\r\n injector?: Injector | null;\r\n forceShow: boolean;\r\n publishedDate?: string;\r\n image?: string;\r\n hideDots?: boolean\r\n}\r\n\r\nexport enum SearchType {\r\n Default = '',\r\n EServices = 'eservice',\r\n None = ''\r\n}\r\n\r\nexport enum SearchTypeNames {\r\n Default = 'Wszędzie',\r\n EServices = 'Katalog e-usług'\r\n}\r\n","import { ServiceHelper } from '@share/common/helpers/service.helper';\r\nimport { Bundle } from '@app/common/enums/server-bundles.enum';\r\nimport { Injectable } from '@angular/core';\r\nimport { BehaviorSubject, Observable } from 'rxjs';\r\nimport { AbstractData, ResponseArray } from '@share/common/models/http';\r\nimport { Breadcrumbs } from '@app/template/layout/modules/header/models/breadcrumbs.model';\r\nimport { API } from '@app/common/constants/api.directories';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class BreadcrumbsService extends ServiceHelper {\r\n reload: BehaviorSubject = new BehaviorSubject(false);\r\n clear: BehaviorSubject = new BehaviorSubject(false);\r\n customBreadcrumbs: Array<{ title: string; url?: string }> = [];\r\n forceActive = false;\r\n\r\n constructor() {\r\n super(Bundle.Breadcrumbs);\r\n }\r\n\r\n public getList(url: string): Observable> {\r\n return this.getAll(`${API.COMMON.BREADCRUMBS}/,${url}`);\r\n }\r\n\r\n public getParsedUrl(url: string): string {\r\n return url.substr(1, url.length).split('/').join(',');\r\n }\r\n\r\n public generateLink(breadcrumbs: Array>, index: number): Array {\r\n let path: Array = [];\r\n try {\r\n for (let i = 0; i < (index + 1); i++) {\r\n path.push(breadcrumbs[i].attributes.url);\r\n }\r\n } catch (_ignore) {\r\n path = [];\r\n }\r\n return path;\r\n }\r\n\r\n public reset() {\r\n this.reload.next(true);\r\n }\r\n}\r\n","import { Injectable, Injector } from '@angular/core';\r\nimport { BehaviorSubject, Observable, ReplaySubject } from 'rxjs';\r\nimport { SearchType, SubheaderConfig } from '@app/template/layout/modules/header/interfaces/subheader-config.interface';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class SubheaderService {\r\n private _config: BehaviorSubject;\r\n\r\n constructor() {\r\n this._config = new BehaviorSubject(this.default);\r\n }\r\n\r\n private get default(): SubheaderConfig {\r\n return {\r\n title: '',\r\n description: '',\r\n searchType: SearchType.None,\r\n component: null,\r\n displayHeader: true,\r\n displayBreadcrumbs: new ReplaySubject(1),\r\n searchOpen: false,\r\n hideSearch: false,\r\n injector: null,\r\n forceShow: false,\r\n categories: [],\r\n hideDots: false\r\n };\r\n }\r\n\r\n public get config(): SubheaderConfig {\r\n return this._config.getValue();\r\n }\r\n\r\n public getConfig(): Observable> {\r\n return this._config.asObservable();\r\n }\r\n\r\n public setConfig(value: Partial) {\r\n this._config.next({ ...this.default, ...value });\r\n }\r\n\r\n public set title(title: string) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n title\r\n });\r\n }\r\n\r\n public set description(description: string) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n description\r\n });\r\n }\r\n\r\n public set searchType(searchType: SearchType) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n searchType\r\n });\r\n }\r\n\r\n public set searchOpen(searchOpen: boolean) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n searchOpen\r\n });\r\n }\r\n\r\n public set injector(injector: Injector) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n injector\r\n });\r\n }\r\n\r\n public set forceShow(forceShow: boolean) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n forceShow\r\n });\r\n }\r\n\r\n public set displayBreadcrumbs(show: boolean) {\r\n this.config.displayBreadcrumbs.next(show);\r\n }\r\n\r\n set categories(categories: { slug: string; title: string }[]) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n categories\r\n });\r\n }\r\n\r\n set publishedDate(publishedDate: string) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n publishedDate\r\n });\r\n }\r\n\r\n set image(image: string) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n image\r\n });\r\n }\r\n\r\n set hideDots(hideDots: boolean) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n hideDots\r\n });\r\n }\r\n\r\n public reset() {\r\n this.setConfig(this.default);\r\n }\r\n}\r\n","import { Component, Input, OnDestroy, OnInit } from '@angular/core';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { Subject } from 'rxjs';\r\n\r\n@Component({\r\n selector: 'app-logo',\r\n templateUrl: './logo.component.html',\r\n styleUrls: ['./logo.component.scss']\r\n})\r\nexport class LogoComponent implements OnInit, OnDestroy {\r\n private destroy$: Subject = new Subject();\r\n url: string;\r\n\r\n @Input() id: string = 'logo';\r\n @Input() isAlt: boolean;\r\n @Input() preventChange: boolean;\r\n\r\n constructor(private layoutService: SettingsService) {}\r\n\r\n ngOnInit() {\r\n if (this.isAlt) {\r\n this.url = this.layoutService.variables.site.altLogo;\r\n } else {\r\n this.url = this.layoutService.variables.site.logo;\r\n }\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.destroy$.next(true);\r\n this.destroy$.complete();\r\n }\r\n}\r\n","\r\n Strona główna\r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { LogoComponent } from '@app/template/layout/modules/logo/components/logo/logo.component';\r\nimport { RouterModule } from '@angular/router';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n RouterModule,\r\n TranslatorModule\r\n ],\r\n declarations: [\r\n LogoComponent\r\n ],\r\n exports: [\r\n LogoComponent\r\n ]\r\n})\r\nexport class LogoModule {}\r\n","import { Component, ElementRef, Input, OnDestroy, OnInit, Renderer2 } from '@angular/core';\r\nimport { AbstractData } from '@share/common/models/http.model';\r\nimport { MenuModel } from '@app/client-core/menu/models/menu.model';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\n\r\n@Component({\r\n selector: 'app-sitemap-item',\r\n templateUrl: './sitemap-item.component.html',\r\n styleUrls: [\r\n './sitemap-item.component.scss'\r\n ]\r\n})\r\nexport class SitemapItemComponent extends ComponentHelper implements OnInit, OnDestroy {\r\n @Input() item: AbstractData;\r\n public listenClickFunc: Function;\r\n\r\n constructor(private renderer: Renderer2,\r\n private _elementRef: ElementRef) {\r\n super();\r\n }\r\n\r\n public ngOnInit() {\r\n this.onClickListener();\r\n }\r\n\r\n public openInNewTab(event: Event, url: string) {\r\n event.preventDefault();\r\n event.stopPropagation();\r\n window.open(url);\r\n }\r\n\r\n private onClickListener() {\r\n this.listenClickFunc = this.renderer.listen(\r\n this._elementRef.nativeElement, 'click', (event) => this.service.utils.navigateTo(event)\r\n );\r\n }\r\n\r\n public ngOnDestroy() {\r\n this.listenClickFunc();\r\n }\r\n}\r\n","{{item.attributes.title}}\r\n\r\n \r\n {{subitem.attributes.title}}\r\n \r\n {{subitem.attributes.title}}\r\n \r\n \r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { SitemapService } from '@app/template/home/services/sitemap.service';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { MenuModel } from '@app/client-core/menu/models/menu.model';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { SitemapLoaders } from '@app/template/home/enums/sitemap-loaders.enum';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { finalize, first } from 'rxjs/operators';\r\nimport { InstitutionModel } from '@app/template/layout/modules/sitemap/models/institution.model';\r\n\r\n@Component({\r\n selector: 'app-sitemap',\r\n templateUrl: './sitemap.component.html',\r\n styleUrls: ['./sitemap.component.scss']\r\n})\r\nexport class SitemapComponent extends ComponentHelper implements OnInit {\r\n sitemap: Array> = [];\r\n SitemapLoaders = SitemapLoaders;\r\n description: string;\r\n institution: AbstractData;\r\n constructor(private sitemapService: SitemapService, private settingService: SettingsService) {\r\n super();\r\n }\r\n\r\n public ngOnInit() {\r\n this.loadSitemap();\r\n this.getInstitutionData();\r\n }\r\n\r\n getInstitutionData() {\r\n this.sitemapService\r\n .getInstitutionData()\r\n .pipe(first())\r\n .subscribe(response => (this.institution = response.data));\r\n }\r\n\r\n public loadSitemap() {\r\n this.setLoader(SitemapLoaders.GetAll, true);\r\n this.sitemapService\r\n .getList()\r\n .pipe(\r\n first(),\r\n finalize(() => this.setLoader(SitemapLoaders.GetAll, false))\r\n )\r\n .subscribe(\r\n response => (this.sitemap = this.getResponseData(response)),\r\n () => this.setComponentError()\r\n );\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n {{institution?.attributes?.name}}\r\n \r\n \r\n \r\n {{ institution?.attributes?.address?.zipCode }} {{ institution?.attributes?.address?.city }}\r\n ul. {{ institution?.attributes?.address?.street }} {{ institution?.attributes?.address?.houseNumber }}\r\n {{\r\n institution?.attributes?.address?.apartmentNumber\r\n ? '/' + institution?.attributes?.address?.apartmentNumber\r\n : ''\r\n }}\r\n \r\n \r\n \r\n \r\n \r\n {{ institution?.attributes?.contact?.phoneNumber }}\r\n \r\n \r\n \r\n {{ institution?.attributes?.contact?.phoneNumberSecondary }}\r\n \r\n \r\n \r\n {{ institution?.attributes?.contact?.fax }}\r\n \r\n \r\n \r\n {{ institution?.attributes?.contact?.email }}\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n 0\">\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { LogoModule } from '@app/template/layout/modules/logo/logo.module';\r\nimport { RouterModule } from '@angular/router';\r\nimport { SitemapComponent } from '@app/template/layout/modules/sitemap/components/sitemap/sitemap.component';\r\nimport { SitemapItemComponent } from '@app/template/layout/modules/sitemap/components/sitemap/sitemap-item/sitemap-item.component';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\n\r\n@NgModule({\r\n declarations: [\r\n SitemapComponent,\r\n SitemapItemComponent,\r\n ],\r\n imports: [\r\n CommonModule,\r\n ElementsModule,\r\n LogoModule,\r\n RouterModule,\r\n TranslatorModule,\r\n ],\r\n exports: [\r\n SitemapComponent\r\n ]\r\n})\r\nexport class SiteMapModule {\r\n}\r\n\r\n","// This file can be replaced during build by using the `fileReplacements` array.\r\n// `ng build --prod` replaces `environment.ts` with `environment.prod.ts`.\r\n// The list of file replacements can be found in `angular.json`.\r\n\r\nexport const environment = {\r\n production: false\r\n};\r\n\r\n/*\r\n * For easier debugging in development mode, you can import the following file\r\n * to ignore zone related error stack frames such as `zone.run`, `zoneDelegate.invokeTask`.\r\n *\r\n * This import should be commented out in production mode because it will have a negative impact\r\n * on performance if an error is thrown.\r\n */\r\n// import 'zone.js/dist/zone-error'; // Included with Angular CLI.\r\n","import {enableProdMode} from '@angular/core';\r\nimport {platformBrowserDynamic} from '@angular/platform-browser-dynamic';\r\n\r\nimport {AppModule} from './app/app.module';\r\nimport {environment} from './environments/environment';\r\nimport 'hammerjs';\r\n\r\nif (environment.production) {\r\n enableProdMode();\r\n}\r\n\r\nplatformBrowserDynamic().bootstrapModule(AppModule)\r\n .catch(err => console.error(err));\r\n"]}
) {\r\n this.router.navigate(['aktualnosci', item.attributes.slug]);\r\n }\r\n}\r\n","\r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n\r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n\r\n \r\n {{\r\n category.attributes.title\r\n }}\r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n {{ item.attributes.title }}\r\n \r\n \r\n {{ item.attributes.publishedFrom | date: 'shortDate':'':'pl' }}\r\n \r\n \r\n {{ item.attributes.description }}\r\n \r\n \r\n \r\n \r\n\r\n","import {\r\n AfterViewInit,\r\n ChangeDetectionStrategy,\r\n ChangeDetectorRef,\r\n Component,\r\n Input,\r\n OnInit,\r\n ViewChild,\r\n ViewContainerRef\r\n} from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { LazyLoaderService } from '@app/common/services/lazy-loader.service';\r\nimport { ROUTES_PATHS } from '@app/common/constants/routes-paths';\r\nimport { Router } from '@angular/router';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { finalize, first } from 'rxjs/operators';\r\nimport { HomeService } from '@app/template/home/services/home.service';\r\nimport { PagesService } from '@app/common/services/pages.service';\r\nimport { PageModel } from '@app/common/models/page.model';\r\nimport { HomeModel } from '@app/template/home/models/home.model';\r\n\r\n@Component({\r\n selector: 'app-home',\r\n templateUrl: './overlay.component.html',\r\n styleUrls: ['./overlay.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class OverlayComponent extends ComponentHelper implements OnInit, AfterViewInit {\r\n @ViewChild('businessModules', { read: ViewContainerRef }) businessModules: ViewContainerRef;\r\n @Input() data: AbstractData>;\r\n loading: boolean = true;\r\n\r\n constructor(\r\n private settingsService: SettingsService,\r\n private lazyLoaderService: LazyLoaderService,\r\n private pagesService: PagesService,\r\n private router: Router,\r\n private cdr: ChangeDetectorRef,\r\n private homeService: HomeService\r\n ) {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n this.service.scrollTo.resetScrollTop();\r\n }\r\n\r\n private setLoading(value: boolean) {\r\n this.loading = value;\r\n this.cdr.markForCheck();\r\n }\r\n\r\n getMainPage() {\r\n this.setLoading(true);\r\n this.pagesService\r\n .getOne()\r\n .pipe(\r\n first(),\r\n finalize(() => this.setLoading(false))\r\n )\r\n .subscribe(\r\n response => {\r\n this.data = response.data;\r\n },\r\n () => {\r\n this.router.navigate(['/', ROUTES_PATHS.notFoundPage.root]);\r\n }\r\n );\r\n }\r\n\r\n ngAfterViewInit() {\r\n if (!this.data) {\r\n this.getMainPage();\r\n } else {\r\n this.loading = false;\r\n this.homeService.isHomePreview = true;\r\n }\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n\r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { ChangeDetectionStrategy, ChangeDetectorRef, Component, Input, OnInit } from '@angular/core';\r\nimport { PromotedService } from '@app/template/home/services/promoted.service';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { Promoted } from '@app/template/elements/promoted/models/promoted.model';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { finalize, first } from 'rxjs/operators';\r\n\r\n@Component({\r\n selector: 'app-promoted',\r\n templateUrl: './promoted.component.html',\r\n styleUrls: ['./promoted.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class PromotedComponent extends ComponentHelper implements OnInit {\r\n @Input() data: { title: string; subtitle: string };\r\n promoted: Array> = [];\r\n loading: boolean = false;\r\n\r\n constructor(private promotedService: PromotedService, private cdr: ChangeDetectorRef) {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n this.loadPromoted();\r\n }\r\n\r\n loadPromoted() {\r\n this.setLoading(true);\r\n this.promotedService\r\n .getList()\r\n .pipe(\r\n first(),\r\n finalize(() => this.setLoading(false))\r\n )\r\n .subscribe(\r\n response => (this.promoted = this.getResponseData(response)),\r\n () => this.setComponentError()\r\n );\r\n }\r\n\r\n private setLoading(value: boolean) {\r\n this.loading = value;\r\n this.cdr.markForCheck();\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { ChangeDetectionStrategy, Component, Input } from '@angular/core';\r\nimport { HomeReportCrashModel } from '@app/template/home/models/home-report-crash.model';\r\n\r\n@Component({\r\n selector: 'app-report-crash',\r\n templateUrl: 'report-crash.component.html',\r\n styleUrls: ['report-crash.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class ReportCrashComponent {\r\n @Input() data: HomeReportCrashModel;\r\n}\r\n","\r\n \r\n \r\n \r\n {{ data?.title }}\r\n {{ data?.content }}\r\n \r\n \r\n \r\n \r\n \r\n {{ data?.contactOne?.title }}\r\n \r\n \r\n {{ data?.contactOne.phone }}\r\n \r\n \r\n \r\n {{ data?.contactOne.officeHours }}\r\n \r\n \r\n \r\n {{ data?.contactTwo?.title }}\r\n \r\n \r\n \r\n {{ data?.contactTwo?.phone }}\r\n \r\n \r\n \r\n \r\n {{ data?.contactTwo?.officeHours }}\r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { ChangeDetectionStrategy, ChangeDetectorRef, Component, Input, OnChanges, SimpleChanges } from '@angular/core';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { PagesService } from '@app/common/services/pages.service';\r\nimport { finalize, first } from 'rxjs/operators';\r\nimport { Router } from '@angular/router';\r\n\r\n@Component({\r\n selector: 'app-schedule',\r\n templateUrl: 'schedule.component.html',\r\n styleUrls: ['schedule.component.scss'],\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class ScheduleComponent implements OnChanges {\r\n @Input() data: {\r\n title: string;\r\n subtitle: string;\r\n pageId: string;\r\n };\r\n\r\n scheduleElements: {\r\n boxTitle: string;\r\n boxSubtitle: string;\r\n boxPhone: string;\r\n schedule: { cities: string; date: string }[];\r\n };\r\n\r\n url: string;\r\n\r\n constructor(private pageService: PagesService, private cdr: ChangeDetectorRef, private router: Router) {}\r\n\r\n ngOnChanges(changes: SimpleChanges): void {\r\n if (changes.data.currentValue.pageId) {\r\n this.pageService\r\n .getOne(changes.data.currentValue.pageId)\r\n .pipe(\r\n first(),\r\n finalize(() => this.cdr.detectChanges())\r\n )\r\n .subscribe(e => {\r\n this.url = e.data.id.replace(',', '/');\r\n this.scheduleElements = e.data.attributes.content.content;\r\n this.scheduleElements.schedule = this.scheduleElements.schedule.filter(\r\n (item: any, index: number) => index < 4\r\n );\r\n });\r\n }\r\n }\r\n\r\n redirectToMore() {\r\n this.router.navigate([this.url]);\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n\r\n\r\n \r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n \r\n \r\n\r\n\r\n \r\n \r\n \r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n {{ title }}\r\n \r\n \r\n {{ text }}\r\n \r\n \r\n \r\n {{ phone }}\r\n \r\n \r\n\r\n\r\n \r\n {{ item.date }}\r\n {{ item.cities }}\r\n \r\n\r\n","export enum SitemapLoaders {\r\n GetAll = 'GetAll'\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { OverlayComponent } from '@app/template/home/components/overlay/overlay.component';\r\nimport { SearchModule } from '@app/client-core/search/search.module';\r\nimport { PromotedComponent } from '@app/template/home/components/promoted/promoted.component';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { CarouselModule } from '@app/template/elements/carousel/carousel.module';\r\nimport { LogoModule } from '@app/template/layout/modules/logo/logo.module';\r\nimport { TruncateModule } from '@share/modules/truncate/truncate.module';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { RouterModule } from '@angular/router';\r\nimport { SelectModule } from '@share/modules/html/select/select.module';\r\nimport { FormsModule } from '@angular/forms';\r\nimport { NgbCarouselModule, NgbPaginationModule } from '@ng-bootstrap/ng-bootstrap';\r\nimport { HeadingModule } from '@app/template/elements/heading/heading.module';\r\nimport { PromotedModule } from '@app/template/elements/promoted/promoted.module';\r\nimport { PolygonModule } from '@app/template/elements/polygon/polygon.module';\r\nimport { AccordionModule } from '@app/template/elements/accordion/accordion.module';\r\nimport { PaginationModule } from '@app/template/elements/pagination/pagination.module';\r\nimport { MainBannerComponent } from '@app/template/home/components/main-banner/main-banner.component';\r\nimport { ReportCrashComponent } from '@app/template/home/components/report-crash/report-crash.component';\r\nimport { ScheduleComponent } from '@app/template/home/components/schedule/schedule.component';\r\nimport { NewsComponent } from '@app/template/home/components/news/news.component';\r\nimport { GalleryComponent } from '@app/template/home/components/gallery/gallery.component';\r\nimport { SimpleBoxModule } from '@app/template/elements/simple-box/simple-box.module';\r\nimport { ArticleModule } from '@app/client-core/article/article.module';\r\n\r\n@NgModule({\r\n declarations: [\r\n GalleryComponent,\r\n NewsComponent,\r\n ScheduleComponent,\r\n ReportCrashComponent,\r\n MainBannerComponent,\r\n OverlayComponent,\r\n PromotedComponent,\r\n ],\r\n imports: [\r\n CommonModule,\r\n SearchModule,\r\n CarouselModule,\r\n ElementsModule,\r\n LogoModule,\r\n RouterModule,\r\n NgbCarouselModule,\r\n NgbPaginationModule,\r\n PromotedModule,\r\n SelectModule,\r\n FormsModule,\r\n TranslatorModule,\r\n PolygonModule,\r\n TruncateModule,\r\n AccordionModule,\r\n PaginationModule,\r\n HeadingModule,\r\n SimpleBoxModule,\r\n ArticleModule\r\n ],\r\n exports: [OverlayComponent]\r\n})\r\nexport class HomeModule {}\r\n","import { Injectable } from '@angular/core';\r\nimport { BehaviorSubject, Observable } from 'rxjs';\r\nimport { distinctUntilChanged } from 'rxjs/operators';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class HomeService {\r\n private _isHomePreview: BehaviorSubject = new BehaviorSubject(false);\r\n isHomePreview$: Observable = this._isHomePreview.asObservable().pipe(distinctUntilChanged());\r\n\r\n set isHomePreview(value: boolean) {\r\n this._isHomePreview.next(value);\r\n }\r\n}\r\n","import { Injectable } from '@angular/core';\r\nimport { ServiceHelper } from '@share/common/helpers/service.helper';\r\nimport { Bundle } from '@app/common/enums/server-bundles.enum';\r\nimport { Observable } from 'rxjs';\r\nimport { ResponseArray } from '@share/common/models/http.model';\r\nimport { API } from '@app/common/constants/api.directories';\r\nimport { Promoted } from '@app/template/elements/promoted/models/promoted.model';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class PromotedService extends ServiceHelper {\r\n constructor() {\r\n super(Bundle.Promoted);\r\n }\r\n\r\n public getList(): Observable> {\r\n return this.getAll(API.PROMOTED.ROOT);\r\n }\r\n}\r\n","import {Injectable} from '@angular/core';\r\nimport {ServiceHelper} from '@share/common/helpers/service.helper';\r\nimport {Bundle} from '@app/common/enums/server-bundles.enum';\r\nimport {Observable} from 'rxjs';\r\nimport {MenuModel} from '@app/client-core/menu/models/menu.model';\r\nimport {ResponseArray} from '@share/common/models/http';\r\nimport {API} from '@app/common/constants/api.directories';\r\nimport { ApiService } from '@app/common/services/api.service';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class SitemapService {\r\n\r\n constructor(private apiService: ApiService) {}\r\n\r\n getInstitutionData(): Observable {\r\n return this.apiService.get('institution');\r\n }\r\n\r\n public getList(): Observable> {\r\n return this.apiService.getAll(API.MENU.SITEMAP);\r\n }\r\n}\r\n","import { Component } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { BreadcrumbsService } from '@app/template/layout/modules/header/services/breadcrumbs.service';\r\nimport { SubheaderService } from '@app/template/layout/modules/header/services/subheader.service';\r\nimport { Observable, of } from 'rxjs';\r\nimport { DynamicContentService } from '@app/client-core/dynamic-content/service/dynamic-content.service';\r\nimport { filter, takeUntil } from 'rxjs/operators';\r\nimport { NavigationEnd } from '@angular/router';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { SearchService } from '@app/client-core/search/services/search.service';\r\n\r\n@Component({\r\n selector: 'app-default',\r\n templateUrl: './default.component.html',\r\n styleUrls: ['./default.component.scss']\r\n})\r\nexport class DefaultComponent extends ComponentHelper {\r\n isHome: boolean = true;\r\n backdrop$: Observable;\r\n constructor(\r\n private breadcrumbsService: BreadcrumbsService,\r\n private subheaderService: SubheaderService,\r\n private settings: SettingsService,\r\n private dynamicContentService: DynamicContentService,\r\n private searchService: SearchService\r\n ) {\r\n super();\r\n this.setHome();\r\n this.backdrop$ = searchService.isActive$;\r\n }\r\n\r\n get contentLoaded(): Observable {\r\n return this.dynamicContentService.loaded$;\r\n }\r\n\r\n public deactivate() {\r\n this.breadcrumbsService.clear.next(true);\r\n this.subheaderService.reset();\r\n }\r\n\r\n private setHome() {\r\n this.service.router.events\r\n .pipe(\r\n filter((e): e is NavigationEnd => e instanceof NavigationEnd),\r\n takeUntil(this.destroyed$)\r\n )\r\n .subscribe(event => {\r\n this.isHome = event.url === '/';\r\n });\r\n }\r\n\r\n get canShow(): Observable {\r\n if (this.isHome) {\r\n return this.contentLoaded;\r\n }\r\n return of(true);\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { DefaultComponent } from './components/default/default.component';\r\nimport { HeaderModule } from '@app/template/layout/modules/header/header.module';\r\nimport { FooterModule } from '@app/template/layout/modules/footer/footer.module';\r\nimport { CookiesModule } from '@app/client-core/cookies/cookies.module';\r\nimport { DynamicContentModule } from '@app/client-core/dynamic-content/dynamic-content.module';\r\nimport { AppRoutingModule } from '@app/app-routing.module';\r\nimport { HomeModule } from '@app/template/home/home.module';\r\nimport { SiteMapModule } from '@app/template/layout/modules/sitemap/sitemap.module';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { PolygonModule } from '@app/template/elements/polygon/polygon.module';\r\n\r\n@NgModule({\r\n declarations: [DefaultComponent],\r\n imports: [\r\n CommonModule,\r\n HeaderModule,\r\n HomeModule,\r\n FooterModule,\r\n CookiesModule,\r\n DynamicContentModule,\r\n SiteMapModule,\r\n AppRoutingModule,\r\n ElementsModule,\r\n PolygonModule\r\n ]\r\n})\r\nexport class LayoutModule {}\r\n","import { NgModule } from '@angular/core';\r\nimport { BreadcrumbsComponent } from '@app/template/layout/modules/breadcrumbs/components/breadcrumbs/breadcrumbs.component';\r\nimport { CommonModule } from '@angular/common';\r\nimport { RouterModule } from '@angular/router';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\n\r\n@NgModule({\r\n declarations: [\r\n BreadcrumbsComponent\r\n ],\r\n imports: [\r\n CommonModule,\r\n RouterModule,\r\n TranslatorModule\r\n ],\r\n exports: [\r\n BreadcrumbsComponent\r\n ]\r\n})\r\nexport class BreadcrumbsModule {}\r\n","import { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { ChangeDetectorRef, Component, EventEmitter, OnInit, Output } from '@angular/core';\r\nimport { BreadcrumbsService } from '@app/template/layout/modules/header/services/breadcrumbs.service';\r\nimport { BreadcrumbsLoaders } from '@app/template/layout/modules/header/enums/breadcrumbs-loaders.enum';\r\nimport { Breadcrumbs } from '@app/template/layout/modules/header/models/breadcrumbs.model';\r\nimport { takeUntil } from 'rxjs/operators';\r\nimport { AbstractData } from '@share/common/models/http';\r\n\r\n@Component({\r\n selector: 'app-breadcrumbs',\r\n templateUrl: './breadcrumbs.component.html',\r\n styleUrls: ['./breadcrumbs.component.scss']\r\n})\r\nexport class BreadcrumbsComponent extends ComponentHelper implements OnInit {\r\n public breadcrumbs: Array> = [];\r\n public shortVersion: boolean = false;\r\n public minLengthForShortVersion: number = 3;\r\n\r\n @Output() readonly loaded: EventEmitter = new EventEmitter();\r\n\r\n constructor(private breadcrumbsService: BreadcrumbsService, private cdr: ChangeDetectorRef) {\r\n super();\r\n }\r\n\r\n public get breadcrumbsExists(): boolean {\r\n return Array.isArray(this.breadcrumbs) && this.breadcrumbs.length > 0;\r\n }\r\n\r\n public ngOnInit() {\r\n this.setReloadListener();\r\n this.setClearListener();\r\n }\r\n\r\n private loadBreadcrumbs() {\r\n this.setLoader(BreadcrumbsLoaders.Get, true);\r\n this.subscriptions.add(\r\n this.breadcrumbsService.getList(this.url).subscribe(\r\n response => {\r\n this.breadcrumbs = this.getResponseData(response);\r\n this.shortVersion = this.breadcrumbs.length > this.minLengthForShortVersion;\r\n this.cdr.detectChanges();\r\n this.loaded.emit();\r\n },\r\n () => {}\r\n )\r\n );\r\n }\r\n\r\n private setReloadListener() {\r\n this.breadcrumbsService.reload.pipe(takeUntil(this.destroyed$)).subscribe(reload => {\r\n if (reload && !this.breadcrumbsService.forceActive) {\r\n this.breadcrumbsService.customBreadcrumbs = [];\r\n this.loadBreadcrumbs();\r\n this.cdr.detectChanges();\r\n }\r\n });\r\n }\r\n\r\n private setClearListener() {\r\n this.breadcrumbsService.clear.pipe(takeUntil(this.destroyed$)).subscribe(clear => {\r\n if (clear) {\r\n this.breadcrumbs = [];\r\n this.cdr.detectChanges();\r\n this.breadcrumbsService.clear.next(false);\r\n }\r\n });\r\n }\r\n\r\n public get customBreadcrumbs(): Array<{ title: string; url?: string }> {\r\n return this.breadcrumbsService.customBreadcrumbs;\r\n }\r\n\r\n private get url(): string {\r\n return this.breadcrumbsService.getParsedUrl(this.service.router.url);\r\n }\r\n\r\n public getLink(index: number): Array {\r\n const segments = this.breadcrumbsService.generateLink(this.breadcrumbs, index);\r\n\r\n if (segments.length > 1) {\r\n return [...segments];\r\n }\r\n\r\n return ['/'];\r\n }\r\n\r\n public expandBreadcrumbs(event: Event) {\r\n event.preventDefault();\r\n this.shortVersion = false;\r\n this.cdr.detectChanges();\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n {{breadcrumb.attributes.title}}\r\n {{breadcrumb.attributes.title}}\r\n \r\n \r\n {{breadcrumb.attributes.title}}\r\n \r\n \r\n \r\n \r\n \r\n {{breadcrumbs[0].attributes.title}}\r\n {{breadcrumbs[0].attributes.title}}\r\n \r\n \r\n {{'...'}}\r\n \r\n {{breadcrumbs[breadcrumbs.length - 1].attributes.title}}\r\n \r\n \r\n\r\n\r\n 0\">\r\n \r\n \r\n \r\n \r\n {{customBreadcrumb.title}}\r\n \r\n \r\n {{customBreadcrumb.title}}\r\n \r\n \r\n \r\n \r\n \r\n\r\n","import {Component, Input, OnInit} from '@angular/core';\r\n\r\n@Component({\r\n selector: 'app-container',\r\n templateUrl: './container.component.html',\r\n styles: []\r\n})\r\nexport class ContainerComponent implements OnInit {\r\n\r\n @Input() public top: number = 30;\r\n @Input() public bottom: number = 30;\r\n @Input() public left: number = 0;\r\n @Input() public right: number = 0;\r\n\r\n constructor() { }\r\n\r\n ngOnInit() {\r\n }\r\n\r\n}\r\n","\r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport {ContainerComponent} from '@app/template/layout/modules/container/components/container/container.component';\r\n\r\n@NgModule({\r\n declarations: [\r\n ContainerComponent\r\n ],\r\n imports: [\r\n CommonModule\r\n ],\r\n exports: [\r\n ContainerComponent\r\n ]\r\n})\r\nexport class ContainerModule { }\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\n\r\n@Component({\r\n selector: 'app-fatal-error',\r\n templateUrl: './fatal-error.component.html',\r\n styleUrls: ['./fatal-error.component.scss']\r\n})\r\nexport class FatalErrorComponent extends ComponentHelper implements OnInit {\r\n\r\n constructor() {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n }\r\n\r\n goToHome(): void {\r\n window.location.href = '/';\r\n }\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n {{ '500' }}\r\n {{ 'Błąd serwera' }}\r\n \r\n \r\n \r\n \r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\n\r\n@Component({\r\n selector: 'app-maintenance',\r\n templateUrl: './maintenance.component.html',\r\n styleUrls: ['./maintenance.component.scss']\r\n})\r\nexport class MaintenanceComponent extends ComponentHelper implements OnInit {\r\n\r\n constructor() {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n }\r\n\r\n}\r\n","\r\n \r\n \r\n \r\n {{'global.maintenance' | trans}}\r\n {{'global.maintenanceText' | trans}}.\r\n \r\n \r\n\r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\n\r\n@Component({\r\n selector: 'app-not-found',\r\n templateUrl: './not-found.component.html',\r\n styleUrls: ['./not-found.component.scss']\r\n})\r\nexport class NotFoundComponent extends ComponentHelper implements OnInit {\r\n\r\n constructor() {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n }\r\n\r\n goToHome(): void {\r\n this.service.router.navigate(['']);\r\n }\r\n\r\n}\r\n","\r\n \r\n \r\n {{ '404' }}\r\n {{ 'Nie znaleziono strony' }}\r\n \r\n \r\n \r\n\r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { NotFoundComponent } from './components/not-found/not-found.component';\r\nimport { RouterModule } from '@angular/router';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { MaintenanceComponent } from './components/maintenance/maintenance.component';\r\nimport { FatalErrorComponent } from './components/fatal-error/fatal-error.component';\r\n\r\n@NgModule({\r\n declarations: [NotFoundComponent, MaintenanceComponent, FatalErrorComponent],\r\n imports: [\r\n CommonModule,\r\n RouterModule,\r\n ElementsModule,\r\n TranslatorModule\r\n ],\r\n exports: [\r\n NotFoundComponent,\r\n MaintenanceComponent\r\n ]\r\n})\r\nexport class ErrorPagesModule {\r\n}\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { VersionService } from '@share/common/services/version.service';\r\n\r\n@Component({\r\n selector: 'app-footer',\r\n templateUrl: './footer.component.html',\r\n styleUrls: ['./footer.component.scss']\r\n})\r\nexport class FooterComponent extends ComponentHelper implements OnInit {\r\n public footer: string;\r\n public version: string;\r\n\r\n constructor(private settingsService: SettingsService, private versionService: VersionService) {\r\n super();\r\n }\r\n\r\n ngOnInit() {\r\n this.footer = this.settingsService.variables.footer.footer;\r\n }\r\n}\r\n","\r\n","import {NgModule} from '@angular/core';\r\nimport {CommonModule} from '@angular/common';\r\nimport {FooterComponent} from './components/footer/footer.component';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\n\r\n@NgModule({\r\n declarations: [FooterComponent],\r\n imports: [\r\n CommonModule,\r\n TranslatorModule,\r\n ElementsModule\r\n ],\r\n exports: [\r\n FooterComponent\r\n ]\r\n})\r\nexport class FooterModule {\r\n}\r\n","import { ChangeDetectionStrategy, Component } from '@angular/core';\r\n\r\ndeclare let $: any;\r\n\r\n@Component({\r\n selector: 'app-a11y-font-size',\r\n styleUrls: ['a11y-font-size.component.scss'],\r\n templateUrl: 'a11y-font-size.component.html',\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class A11yFontSizeComponent {\r\n constructor() {}\r\n\r\n setDefaultFontSize() {\r\n this.changeFontSize('10px');\r\n }\r\n setBiggerFontSize() {\r\n this.changeFontSize('11px');\r\n }\r\n setBigFontSize() {\r\n this.changeFontSize('12px');\r\n }\r\n\r\n private changeFontSize(size: string) {\r\n $('html').css({\r\n 'font-size': size\r\n });\r\n }\r\n}\r\n","\r\n \r\n \r\n domyślna czcionka\r\n A\r\n \r\n \r\n \r\n \r\n większa czcionka\r\n A\r\n \r\n \r\n \r\n \r\n największa czcionka\r\n A\r\n \r\n \r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { GoogleTranslateService } from '@app/common/services/google-translate.service';\r\n\r\n@Component({\r\n selector: 'app-google-translator',\r\n templateUrl: './google-translator.component.html',\r\n styleUrls: [\r\n './google-translator.component.scss'\r\n ]\r\n})\r\nexport class GoogleTranslatorComponent implements OnInit {\r\n\r\n constructor(private googleTranslateService: GoogleTranslateService) {}\r\n\r\n public ngOnInit() {\r\n this.googleTranslateService.init();\r\n }\r\n\r\n}\r\n","\r\n","import { AfterViewInit, Component, ElementRef, Inject, OnInit, ViewChild, ViewContainerRef } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { DOCUMENT } from '@angular/common';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { LazyLoaderService } from '@app/common/services/lazy-loader.service';\r\nimport { ThemesEnum } from '@app/common/models/themes.enum';\r\nimport { ResizeListener } from '@app/common/services/resize-listener.service';\r\nimport { SearchService } from '@app/client-core/search/services/search.service';\r\nimport { fromEvent, Observable } from 'rxjs';\r\nimport { MenuService } from '@app/client-core/menu/services/menu.service';\r\nimport { debounceTime, filter, finalize, first, takeUntil, tap } from 'rxjs/operators';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { MenuModel } from '@app/client-core/menu/models/menu.model';\r\n\r\ndeclare let $: Function;\r\n\r\n@Component({\r\n selector: 'app-header',\r\n templateUrl: './header-container.component.html',\r\n styleUrls: [\r\n './header-container.component.scss',\r\n './header-container-contrast.component.scss',\r\n ]\r\n})\r\nexport class HeaderContainerComponent extends ComponentHelper implements OnInit, AfterViewInit {\r\n isAuthenticated: boolean = false;\r\n search: string;\r\n\r\n @ViewChild('alertBtn', { read: ViewContainerRef }) alertBtn: ViewContainerRef;\r\n @ViewChild('menu', { read: ViewContainerRef }) menu: ViewContainerRef;\r\n\r\n private startDistance = 10;\r\n\r\n isMobileSearchActive$: Observable;\r\n isValidDefaultMenuWidth: boolean;\r\n isMobileMenuMode: boolean;\r\n isDefaultMenuWidthChecking: boolean;\r\n isFetchMenuLoading: boolean;\r\n menuData: AbstractData[];\r\n\r\n constructor(\r\n @Inject(DOCUMENT) private document: Document,\r\n private settings: SettingsService,\r\n private loader: LazyLoaderService,\r\n public resizeListener: ResizeListener,\r\n private searchService: SearchService,\r\n private menuService: MenuService,\r\n private _elementRef: ElementRef\r\n ) {\r\n super();\r\n }\r\n\r\n get isSubpage(): boolean {\r\n return !this.service.router.isActive('', true);\r\n }\r\n\r\n get isAlertModuleEnabled(): boolean {\r\n return this.settings.isModuleActive(ThemesEnum.ALERT);\r\n }\r\n\r\n get isMenuModuleEnabled(): boolean {\r\n return this.settings.isModuleActive(ThemesEnum.MENU);\r\n }\r\n\r\n /** Metoda sprawdzająca, czy zawartość menu dla desktop'ów nie wystaje poza szerokość okna/headera. */\r\n get isValidHeaderContentWidth(): boolean {\r\n const contentElementRef: HTMLElement = this.document.querySelector('#main-app-header .content') as HTMLElement;\r\n const contentElementChildren: HTMLElement[] = Array.from(contentElementRef.children) as HTMLElement[];\r\n const contentElementAvailableWidth: number = contentElementRef.offsetWidth\r\n - (parseInt(getComputedStyle(contentElementRef).paddingLeft))\r\n - (parseInt(getComputedStyle(contentElementRef).paddingRight))\r\n - 30 // ScrollBar with small offset.\r\n ;\r\n\r\n let contentChildrenWidth: number = 0;\r\n\r\n contentElementChildren.forEach(child => {\r\n contentChildrenWidth += child.offsetWidth;\r\n });\r\n\r\n return contentChildrenWidth <= contentElementAvailableWidth\r\n }\r\n\r\n ngOnInit() {\r\n this.fetchMenu();\r\n window.addEventListener('scroll', () => this.scroll(), true);\r\n this.scroll();\r\n this.isMobileSearchActive$ = this.searchService.isActive$;\r\n this.searchService.isActive$.pipe(takeUntil(this.destroyed$)).subscribe(isActive => {\r\n if (isActive) {\r\n this.menuService.isMobileMenuActive$.next(false);\r\n }\r\n });\r\n this.handleOutsideClick();\r\n }\r\n\r\n ngAfterViewInit() {\r\n this.generateAlertButton();\r\n this.generateMenu();\r\n }\r\n\r\n private setMenuModeChangeListener() {\r\n this.resizeListener.isMobile$.pipe(\r\n takeUntil(this.destroyed$),\r\n tap((value) => this.isMobileMenuMode = value),\r\n filter((value) => !value),\r\n tap(() => {\r\n this.isDefaultMenuWidthChecking = true;\r\n this.isValidDefaultMenuWidth = true; // Pokazanie menu, aby JS mógł obliczyć szerokość wewnątrz komponentu.\r\n }),\r\n debounceTime(500),\r\n ).subscribe((value) => {\r\n this.setIsMobileMenuMode();\r\n });\r\n }\r\n\r\n private fetchMenu() {\r\n this.isFetchMenuLoading = true;\r\n\r\n this.menuService\r\n .getList()\r\n .pipe(\r\n first(),\r\n finalize(() => this.isFetchMenuLoading = false)\r\n )\r\n .subscribe(\r\n response => {\r\n this.menuData = response.data;\r\n this.setMenuModeChangeListener();\r\n }\r\n );\r\n }\r\n\r\n private setIsMobileMenuMode(): void {\r\n // setTimeout z racji wymaganego opóźnienia przy obliczaniu dostępnej szerokosci.\r\n setTimeout(() => {\r\n this.isValidDefaultMenuWidth = this.isValidHeaderContentWidth;\r\n });\r\n\r\n this.isDefaultMenuWidthChecking = false;\r\n }\r\n\r\n generateAlertButton() {\r\n if (this.alertBtn && this.isAlertModuleEnabled) {\r\n this.loader.load(ThemesEnum.ALERT, this.alertBtn);\r\n }\r\n }\r\n\r\n generateMenu() {\r\n if (this.menu) {\r\n this.menu?.clear();\r\n if (this.isMenuModuleEnabled || this.isAuthenticated) {\r\n this.loader.load(ThemesEnum.MENU, this.menu);\r\n }\r\n }\r\n }\r\n\r\n handleOutsideClick() {\r\n const clickEvent$ = fromEvent(document, 'click');\r\n clickEvent$\r\n .pipe(\r\n takeUntil(this.destroyed$),\r\n filter(e => !this._elementRef.nativeElement.contains(e.target)),\r\n tap(e => {\r\n this.searchService.isActive$.next(false);\r\n })\r\n )\r\n .subscribe();\r\n }\r\n\r\n\r\n private scroll() {\r\n const scrollTop = $(this.document).scrollTop(),\r\n header = $('header');\r\n if (scrollTop >= this.startDistance) {\r\n header.addClass('sticked');\r\n } else {\r\n header.removeClass('sticked');\r\n }\r\n }\r\n\r\n onComponentRefresh() {\r\n this.fetchMenu();\r\n }\r\n}\r\n","\r\n Dolina baryczy\r\n \r\n \r\n \r\n {{ 'global.search' | trans }}\r\n \r\n \r\n \r\n {{ 'global.settings' | trans }}\r\n \r\n \r\n \r\n {{'global.contrast' | trans}}\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { AfterViewInit, Component, OnInit, Renderer2 } from '@angular/core';\r\n\r\ndeclare let $: Function;\r\n\r\n@Component({\r\n selector: 'app-high-contrast',\r\n templateUrl: './high-contrast.component.html',\r\n styleUrls: ['./high-contrast.component.scss']\r\n})\r\nexport class HighContrastComponent implements OnInit, AfterViewInit {\r\n constructor(private renderer: Renderer2) {}\r\n\r\n ngOnInit(): void {}\r\n\r\n ngAfterViewInit(): void {\r\n const contrast: string = localStorage.getItem('contrast') as string;\r\n if (contrast) {\r\n switch (contrast) {\r\n case 'blackwhite':\r\n this.addBlackWhite();\r\n break;\r\n case 'yellowblack':\r\n this.addYellowBlack();\r\n break;\r\n }\r\n }\r\n }\r\n\r\n removeContrast() {\r\n this.renderer.removeClass(document.body, localStorage.getItem('contrast') as string);\r\n this.renderer.setStyle(document.body, 'color', '');\r\n this.renderer.setStyle(document.body, 'background-color', '');\r\n\r\n localStorage.setItem('contrast', 'normal');\r\n }\r\n\r\n addYellowBlack() {\r\n this.removeContrast();\r\n this.renderer.addClass(document.body, 'yellowblack');\r\n\r\n this.renderer.setStyle(document.body, 'background-color', 'black');\r\n this.renderer.setStyle(document.body, 'color', 'yellow');\r\n\r\n localStorage.setItem('contrast', 'yellowblack');\r\n }\r\n\r\n addBlackWhite() {\r\n this.removeContrast();\r\n this.renderer.addClass(document.body, 'blackwhite');\r\n\r\n this.renderer.setStyle(document.body, 'background-color', 'white');\r\n this.renderer.setStyle(document.body, 'color', 'black');\r\n\r\n localStorage.setItem('contrast', 'blackwhite');\r\n }\r\n}\r\n","\r\n \r\n \r\n brak wysokiego kontrastu\r\n A\r\n \r\n \r\n \r\n \r\n czarno-biały\r\n A\r\n \r\n \r\n \r\n \r\n żółto-czarny\r\n A\r\n \r\n \r\n\r\n","export { SubheaderDescriptionComponent } from './subheader/subheader-description/subheader-description.component';\r\nexport { SubheaderTitleComponent } from './subheader/subheader-title/subheader-title.component';\r\nexport { SubheaderComponent } from './subheader/subheader.component';\r\nexport { GoogleTranslatorComponent } from './google-translator/google-translator.component';\r\nexport { HeaderContainerComponent } from './header-container/header-container.component';\r\nexport { LanguageComponent } from './language/language.component';\r\nexport { A11yFontSizeComponent } from './a11y-font-size/a11y-font-size.component';\r\n","import {ComponentHelper} from '@app/common/helpers/component.helper';\r\nimport {Component, ViewEncapsulation} from '@angular/core';\r\n\r\n@Component({\r\n selector: 'app-language',\r\n templateUrl: './language.component.html',\r\n styleUrls: ['./language.component.scss'],\r\n})\r\nexport class LanguageComponent extends ComponentHelper {\r\n\r\n public language: string = 'pl';\r\n\r\n constructor() {\r\n super();\r\n }\r\n\r\n changeLanguage(): void {\r\n alert('TODO');\r\n }\r\n}\r\n","\r\n","import { Component, Input } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'cms-subheader-description',\r\n templateUrl: 'subheader-description.component.html',\r\n styleUrls: ['subheader-description.component.scss']\r\n})\r\nexport class SubheaderDescriptionComponent {\r\n @Input() text: string;\r\n @Input() isMobile: boolean;\r\n}\r\n","{{text}}\r\n","import { Component, ElementRef, EventEmitter, Input, Output, ViewChild } from '@angular/core';\r\n\r\n@Component({\r\n selector: 'cms-subheader-title',\r\n templateUrl: 'subheader-title.component.html',\r\n styleUrls: ['subheader-title.component.scss']\r\n})\r\nexport class SubheaderTitleComponent {\r\n\r\n isEditable: boolean = false;\r\n\r\n @Input() title: string;\r\n @Input() isMobile: boolean;\r\n @Input() set editable(editable: boolean) {\r\n this.isEditable = editable;\r\n setTimeout(() => this.text.nativeElement.focus());\r\n };\r\n\r\n @ViewChild('text') text: ElementRef;\r\n\r\n @Output() onSubmitEditable: EventEmitter = new EventEmitter();\r\n\r\n onSubmit() {\r\n this.isEditable = false;\r\n this.onSubmitEditable.emit(this.text.nativeElement.innerText);\r\n }\r\n\r\n}\r\n","{{ title }}\r\n","import { AfterViewInit, Component, Injector } from '@angular/core';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { SubheaderConfig } from '@app/template/layout/modules/header/interfaces/subheader-config.interface';\r\nimport { BreadcrumbsService } from '@app/template/layout/modules/header/services/breadcrumbs.service';\r\nimport { NavigationEnd } from '@angular/router';\r\nimport { filter, takeUntil } from 'rxjs/operators';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { DynamicContentService } from '@app/client-core/dynamic-content/service/dynamic-content.service';\r\nimport { Observable } from 'rxjs';\r\nimport { HomeService } from '@app/template/home/services/home.service';\r\n\r\n@Component({\r\n selector: 'app-subheader',\r\n templateUrl: './subheader.component.html',\r\n styleUrls: ['./subheader.component.scss']\r\n})\r\nexport class SubheaderComponent extends ComponentHelper implements AfterViewInit {\r\n active: boolean = false;\r\n isHome: boolean = false;\r\n\r\n constructor(\r\n private breadcrumbsService: BreadcrumbsService,\r\n private settings: SettingsService,\r\n private dynamicContentService: DynamicContentService,\r\n private homeService: HomeService\r\n ) {\r\n super();\r\n this.setHome();\r\n }\r\n\r\n get contentLoaded(): Observable {\r\n return this.dynamicContentService.loaded$;\r\n }\r\n\r\n get isHomePreview(): Observable {\r\n return this.homeService.isHomePreview$;\r\n }\r\n\r\n private setHome() {\r\n this.service.router.events\r\n .pipe(\r\n filter((e): e is NavigationEnd => e instanceof NavigationEnd),\r\n takeUntil(this.destroyed$)\r\n )\r\n .subscribe(event => {\r\n this.isHome = event.url === '/';\r\n });\r\n }\r\n\r\n get component() {\r\n return this.service.subheader.config.component;\r\n }\r\n\r\n get config(): SubheaderConfig {\r\n return this.service.subheader.config;\r\n }\r\n\r\n get myInjector(): Injector | null | undefined {\r\n return this.service.subheader.config.injector;\r\n }\r\n\r\n get displayBreadcrumbs() {\r\n return this.service.subheader.config.displayBreadcrumbs;\r\n }\r\n\r\n get forceShow() {\r\n return this.service.subheader.config.forceShow;\r\n }\r\n\r\n get categories(): { title: string; slug: string }[] | undefined {\r\n return this.service.subheader.config.categories;\r\n }\r\n\r\n get publishedDate(): string | undefined {\r\n return this.service.subheader.config.publishedDate;\r\n }\r\n\r\n get image(): string | undefined {\r\n return this.service.subheader.config.image;\r\n }\r\n\r\n get hideDots(): boolean {\r\n return this.service.subheader.config.hideDots || false;\r\n }\r\n\r\n ngAfterViewInit(): void {\r\n this.breadcrumbsService.reload.next(true);\r\n }\r\n\r\n isArray(categories: { title: string; slug: string }[] | string | undefined): boolean {\r\n return Array.isArray(categories);\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n {{ category.attributes.title }}\r\n \r\n \r\n {{ publishedDate | date: 'shortDate':'':'pl' }}\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","export enum BreadcrumbsLoaders {\r\n Get = 'Get'\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { WcagModule } from '@share/modules/wcag/wcag.module';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { LogoModule } from '@app/template/layout/modules/logo/logo.module';\r\nimport { SearchModule } from '@app/client-core/search/search.module';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\nimport { RouterModule } from '@angular/router';\r\nimport {\r\n A11yFontSizeComponent,\r\n GoogleTranslatorComponent,\r\n HeaderContainerComponent,\r\n LanguageComponent,\r\n SubheaderComponent,\r\n SubheaderDescriptionComponent,\r\n SubheaderTitleComponent\r\n} from './components';\r\nimport { BreadcrumbsModule } from '@app/template/layout/modules/breadcrumbs/breadcrumbs.module';\r\nimport { HttpClientModule } from '@angular/common/http';\r\nimport { MenuModule } from '@app/client-core/menu/menu.module';\r\nimport { InputModule } from '@share/modules/html/input/input.module';\r\nimport { FormsModule } from '@angular/forms';\r\nimport { HighContrastComponent } from './components/high-contrast/high-contrast.component';\r\n\r\n@NgModule({\r\n declarations: [\r\n LanguageComponent,\r\n SubheaderTitleComponent,\r\n SubheaderDescriptionComponent,\r\n GoogleTranslatorComponent,\r\n HeaderContainerComponent,\r\n SubheaderComponent,\r\n A11yFontSizeComponent,\r\n HighContrastComponent\r\n ],\r\n imports: [\r\n CommonModule,\r\n WcagModule,\r\n LogoModule,\r\n ElementsModule,\r\n HttpClientModule,\r\n SearchModule,\r\n ElementsModule,\r\n TranslatorModule,\r\n RouterModule,\r\n BreadcrumbsModule,\r\n MenuModule,\r\n InputModule,\r\n FormsModule\r\n ],\r\n exports: [HeaderContainerComponent, SubheaderComponent, SubheaderTitleComponent, SubheaderDescriptionComponent]\r\n})\r\nexport class HeaderModule {}\r\n","import { ReplaySubject } from 'rxjs';\r\nimport { Injector } from '@angular/core';\r\n\r\nexport interface SubheaderConfig {\r\n title: string;\r\n description: string;\r\n displayHeader: boolean;\r\n displayBreadcrumbs: ReplaySubject;\r\n searchOpen: boolean;\r\n searchType: SearchType;\r\n component: any;\r\n categories?: { slug: string; title: string }[];\r\n hideSearch: boolean;\r\n injector?: Injector | null;\r\n forceShow: boolean;\r\n publishedDate?: string;\r\n image?: string;\r\n hideDots?: boolean\r\n}\r\n\r\nexport enum SearchType {\r\n Default = '',\r\n EServices = 'eservice',\r\n None = ''\r\n}\r\n\r\nexport enum SearchTypeNames {\r\n Default = 'Wszędzie',\r\n EServices = 'Katalog e-usług'\r\n}\r\n","import { ServiceHelper } from '@share/common/helpers/service.helper';\r\nimport { Bundle } from '@app/common/enums/server-bundles.enum';\r\nimport { Injectable } from '@angular/core';\r\nimport { BehaviorSubject, Observable } from 'rxjs';\r\nimport { AbstractData, ResponseArray } from '@share/common/models/http';\r\nimport { Breadcrumbs } from '@app/template/layout/modules/header/models/breadcrumbs.model';\r\nimport { API } from '@app/common/constants/api.directories';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class BreadcrumbsService extends ServiceHelper {\r\n reload: BehaviorSubject = new BehaviorSubject(false);\r\n clear: BehaviorSubject = new BehaviorSubject(false);\r\n customBreadcrumbs: Array<{ title: string; url?: string }> = [];\r\n forceActive = false;\r\n\r\n constructor() {\r\n super(Bundle.Breadcrumbs);\r\n }\r\n\r\n public getList(url: string): Observable> {\r\n return this.getAll(`${API.COMMON.BREADCRUMBS}/,${url}`);\r\n }\r\n\r\n public getParsedUrl(url: string): string {\r\n return url.substr(1, url.length).split('/').join(',');\r\n }\r\n\r\n public generateLink(breadcrumbs: Array>, index: number): Array {\r\n let path: Array = [];\r\n try {\r\n for (let i = 0; i < (index + 1); i++) {\r\n path.push(breadcrumbs[i].attributes.url);\r\n }\r\n } catch (_ignore) {\r\n path = [];\r\n }\r\n return path;\r\n }\r\n\r\n public reset() {\r\n this.reload.next(true);\r\n }\r\n}\r\n","import { Injectable, Injector } from '@angular/core';\r\nimport { BehaviorSubject, Observable, ReplaySubject } from 'rxjs';\r\nimport { SearchType, SubheaderConfig } from '@app/template/layout/modules/header/interfaces/subheader-config.interface';\r\n\r\n@Injectable({\r\n providedIn: 'root'\r\n})\r\nexport class SubheaderService {\r\n private _config: BehaviorSubject;\r\n\r\n constructor() {\r\n this._config = new BehaviorSubject(this.default);\r\n }\r\n\r\n private get default(): SubheaderConfig {\r\n return {\r\n title: '',\r\n description: '',\r\n searchType: SearchType.None,\r\n component: null,\r\n displayHeader: true,\r\n displayBreadcrumbs: new ReplaySubject(1),\r\n searchOpen: false,\r\n hideSearch: false,\r\n injector: null,\r\n forceShow: false,\r\n categories: [],\r\n hideDots: false\r\n };\r\n }\r\n\r\n public get config(): SubheaderConfig {\r\n return this._config.getValue();\r\n }\r\n\r\n public getConfig(): Observable> {\r\n return this._config.asObservable();\r\n }\r\n\r\n public setConfig(value: Partial) {\r\n this._config.next({ ...this.default, ...value });\r\n }\r\n\r\n public set title(title: string) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n title\r\n });\r\n }\r\n\r\n public set description(description: string) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n description\r\n });\r\n }\r\n\r\n public set searchType(searchType: SearchType) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n searchType\r\n });\r\n }\r\n\r\n public set searchOpen(searchOpen: boolean) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n searchOpen\r\n });\r\n }\r\n\r\n public set injector(injector: Injector) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n injector\r\n });\r\n }\r\n\r\n public set forceShow(forceShow: boolean) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n forceShow\r\n });\r\n }\r\n\r\n public set displayBreadcrumbs(show: boolean) {\r\n this.config.displayBreadcrumbs.next(show);\r\n }\r\n\r\n set categories(categories: { slug: string; title: string }[]) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n categories\r\n });\r\n }\r\n\r\n set publishedDate(publishedDate: string) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n publishedDate\r\n });\r\n }\r\n\r\n set image(image: string) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n image\r\n });\r\n }\r\n\r\n set hideDots(hideDots: boolean) {\r\n this._config.next({\r\n ...this._config.getValue(),\r\n hideDots\r\n });\r\n }\r\n\r\n public reset() {\r\n this.setConfig(this.default);\r\n }\r\n}\r\n","import { Component, Input, OnDestroy, OnInit } from '@angular/core';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { Subject } from 'rxjs';\r\n\r\n@Component({\r\n selector: 'app-logo',\r\n templateUrl: './logo.component.html',\r\n styleUrls: ['./logo.component.scss']\r\n})\r\nexport class LogoComponent implements OnInit, OnDestroy {\r\n private destroy$: Subject = new Subject();\r\n url: string;\r\n\r\n @Input() id: string = 'logo';\r\n @Input() isAlt: boolean;\r\n @Input() preventChange: boolean;\r\n\r\n constructor(private layoutService: SettingsService) {}\r\n\r\n ngOnInit() {\r\n if (this.isAlt) {\r\n this.url = this.layoutService.variables.site.altLogo;\r\n } else {\r\n this.url = this.layoutService.variables.site.logo;\r\n }\r\n }\r\n\r\n ngOnDestroy(): void {\r\n this.destroy$.next(true);\r\n this.destroy$.complete();\r\n }\r\n}\r\n","\r\n Strona główna\r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { LogoComponent } from '@app/template/layout/modules/logo/components/logo/logo.component';\r\nimport { RouterModule } from '@angular/router';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\n\r\n@NgModule({\r\n imports: [\r\n CommonModule,\r\n RouterModule,\r\n TranslatorModule\r\n ],\r\n declarations: [\r\n LogoComponent\r\n ],\r\n exports: [\r\n LogoComponent\r\n ]\r\n})\r\nexport class LogoModule {}\r\n","import { Component, ElementRef, Input, OnDestroy, OnInit, Renderer2 } from '@angular/core';\r\nimport { AbstractData } from '@share/common/models/http.model';\r\nimport { MenuModel } from '@app/client-core/menu/models/menu.model';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\n\r\n@Component({\r\n selector: 'app-sitemap-item',\r\n templateUrl: './sitemap-item.component.html',\r\n styleUrls: [\r\n './sitemap-item.component.scss'\r\n ]\r\n})\r\nexport class SitemapItemComponent extends ComponentHelper implements OnInit, OnDestroy {\r\n @Input() item: AbstractData;\r\n public listenClickFunc: Function;\r\n\r\n constructor(private renderer: Renderer2,\r\n private _elementRef: ElementRef) {\r\n super();\r\n }\r\n\r\n public ngOnInit() {\r\n this.onClickListener();\r\n }\r\n\r\n public openInNewTab(event: Event, url: string) {\r\n event.preventDefault();\r\n event.stopPropagation();\r\n window.open(url);\r\n }\r\n\r\n private onClickListener() {\r\n this.listenClickFunc = this.renderer.listen(\r\n this._elementRef.nativeElement, 'click', (event) => this.service.utils.navigateTo(event)\r\n );\r\n }\r\n\r\n public ngOnDestroy() {\r\n this.listenClickFunc();\r\n }\r\n}\r\n","{{item.attributes.title}}\r\n\r\n \r\n {{subitem.attributes.title}}\r\n \r\n {{subitem.attributes.title}}\r\n \r\n \r\n\r\n","import { Component, OnInit } from '@angular/core';\r\nimport { SitemapService } from '@app/template/home/services/sitemap.service';\r\nimport { ComponentHelper } from '@app/common/helpers/component.helper';\r\nimport { MenuModel } from '@app/client-core/menu/models/menu.model';\r\nimport { AbstractData } from '@share/common/models/http';\r\nimport { SitemapLoaders } from '@app/template/home/enums/sitemap-loaders.enum';\r\nimport { SettingsService } from '@app/common/services/settings.service';\r\nimport { finalize, first } from 'rxjs/operators';\r\nimport { InstitutionModel } from '@app/template/layout/modules/sitemap/models/institution.model';\r\n\r\n@Component({\r\n selector: 'app-sitemap',\r\n templateUrl: './sitemap.component.html',\r\n styleUrls: ['./sitemap.component.scss']\r\n})\r\nexport class SitemapComponent extends ComponentHelper implements OnInit {\r\n sitemap: Array> = [];\r\n SitemapLoaders = SitemapLoaders;\r\n description: string;\r\n institution: AbstractData;\r\n constructor(private sitemapService: SitemapService, private settingService: SettingsService) {\r\n super();\r\n }\r\n\r\n public ngOnInit() {\r\n this.loadSitemap();\r\n this.getInstitutionData();\r\n }\r\n\r\n getInstitutionData() {\r\n this.sitemapService\r\n .getInstitutionData()\r\n .pipe(first())\r\n .subscribe(response => (this.institution = response.data));\r\n }\r\n\r\n public loadSitemap() {\r\n this.setLoader(SitemapLoaders.GetAll, true);\r\n this.sitemapService\r\n .getList()\r\n .pipe(\r\n first(),\r\n finalize(() => this.setLoader(SitemapLoaders.GetAll, false))\r\n )\r\n .subscribe(\r\n response => (this.sitemap = this.getResponseData(response)),\r\n () => this.setComponentError()\r\n );\r\n }\r\n}\r\n","\r\n \r\n \r\n \r\n\r\n\r\n \r\n \r\n \r\n \r\n \r\n {{institution?.attributes?.name}}\r\n \r\n \r\n \r\n {{ institution?.attributes?.address?.zipCode }} {{ institution?.attributes?.address?.city }}\r\n ul. {{ institution?.attributes?.address?.street }} {{ institution?.attributes?.address?.houseNumber }}\r\n {{\r\n institution?.attributes?.address?.apartmentNumber\r\n ? '/' + institution?.attributes?.address?.apartmentNumber\r\n : ''\r\n }}\r\n \r\n \r\n \r\n \r\n \r\n {{ institution?.attributes?.contact?.phoneNumber }}\r\n \r\n \r\n \r\n {{ institution?.attributes?.contact?.phoneNumberSecondary }}\r\n \r\n \r\n \r\n {{ institution?.attributes?.contact?.fax }}\r\n \r\n \r\n \r\n {{ institution?.attributes?.contact?.email }}\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n 0\">\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n","import { NgModule } from '@angular/core';\r\nimport { CommonModule } from '@angular/common';\r\nimport { ElementsModule } from '@share/modules/elements/elements.module';\r\nimport { LogoModule } from '@app/template/layout/modules/logo/logo.module';\r\nimport { RouterModule } from '@angular/router';\r\nimport { SitemapComponent } from '@app/template/layout/modules/sitemap/components/sitemap/sitemap.component';\r\nimport { SitemapItemComponent } from '@app/template/layout/modules/sitemap/components/sitemap/sitemap-item/sitemap-item.component';\r\nimport { TranslatorModule } from '@share/modules/translator/translator.module';\r\n\r\n@NgModule({\r\n declarations: [\r\n SitemapComponent,\r\n SitemapItemComponent,\r\n ],\r\n imports: [\r\n CommonModule,\r\n ElementsModule,\r\n LogoModule,\r\n RouterModule,\r\n TranslatorModule,\r\n ],\r\n exports: [\r\n SitemapComponent\r\n ]\r\n})\r\nexport class SiteMapModule {\r\n}\r\n\r\n","// This file can be replaced during build by using the `fileReplacements` array.\r\n// `ng build --prod` replaces `environment.ts` with `environment.prod.ts`.\r\n// The list of file replacements can be found in `angular.json`.\r\n\r\nexport const environment = {\r\n production: false\r\n};\r\n\r\n/*\r\n * For easier debugging in development mode, you can import the following file\r\n * to ignore zone related error stack frames such as `zone.run`, `zoneDelegate.invokeTask`.\r\n *\r\n * This import should be commented out in production mode because it will have a negative impact\r\n * on performance if an error is thrown.\r\n */\r\n// import 'zone.js/dist/zone-error'; // Included with Angular CLI.\r\n","import {enableProdMode} from '@angular/core';\r\nimport {platformBrowserDynamic} from '@angular/platform-browser-dynamic';\r\n\r\nimport {AppModule} from './app/app.module';\r\nimport {environment} from './environments/environment';\r\nimport 'hammerjs';\r\n\r\nif (environment.production) {\r\n enableProdMode();\r\n}\r\n\r\nplatformBrowserDynamic().bootstrapModule(AppModule)\r\n .catch(err => console.error(err));\r\n"]}
\r\n \r\n \r\n \r\n \r\n\r\n \r\n\r\n \r\n {{\r\n category.attributes.title\r\n }}\r\n \r\n\r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n \r\n\r\n {{ item.attributes.title }}\r\n \r\n \r\n {{ item.attributes.publishedFrom | date: 'shortDate':'':'pl' }}\r\n \r\n \r\n {{ item.attributes.description }}\r\n \r\n \r\n \r\n