Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found
Select Git revision
  • 354-actualites-partage-article-via-rs-image-d-illus-a-la-place-du-logo-res-in
  • 582-modification-fiche-structure-offre-structure-vs-offre-accompagnant-numerique-ordre-des-blocs
  • 630-bo-admin-fonction-2
  • 673-fiche-structure-mise-en-forme-des-rs
  • 722-envsubst-client-side-conf
  • 723-structures-l-api-ne-prend-pas-en-compte-l-offre-des-mediateurs
  • 728-cartographie-ordre-d-affichage-de-la-liste
  • 734-actualites-menu-en-mobile
  • dev
  • feat/nginx-security
  • master
  • renovate/bluehalo-ngx-leaflet-20.x
  • renovate/chokidar-4.x
  • renovate/chromatic-com-storybook-4.x
  • renovate/devdependencies-(non-major)
  • renovate/leaflet.locatecontrol-0.x
  • renovate/major-ag-grid-monorepo
  • renovate/major-angular-cli-monorepo
  • renovate/major-angular-eslint-monorepo
  • renovate/major-angular-monorepo
  • renovate/major-angularmaterial-monorepo
  • renovate/major-storybook-monorepo
  • renovate/major-typescript-eslint-monorepo
  • renovate/ng-packagr-20.x
  • renovate/ngx-matomo-client-8.x
  • renovate/ngx-toastr-19.x
  • renovate/npm-11.x
  • wip_3.4
  • 1.1.0
  • v0.0.1
  • v0.0.2
  • v0.0.3
  • v1.1.0
  • v1.10.0
  • v1.11.0
  • v1.11.1
  • v1.12.0
  • v1.12.1
  • v1.13.0
  • v1.14.0
  • v1.15.0
  • v1.16.0
  • v1.16.1
  • v1.16.2
  • v1.16.3
  • v1.17.0
  • v1.17.1
  • v1.17.2
  • v1.17.3
  • v1.2.0
  • v1.3.0
  • v1.4.0
  • v1.5.0
  • v1.6.0
  • v1.6.1
  • v1.7.0
  • v1.8.0
  • v1.9.0
  • v1.9.1
  • v2.0.0
  • v2.0.0-beta1
  • v2.0.0-beta1.1
  • v2.0.0-beta2
  • v2.0.0-beta2.1
  • v2.0.0-beta2.2
  • v2.0.0-beta4
  • v2.0.0-beta5
  • v2.0.1
  • v2.0.2
  • v2.1.0
  • v2.1.1
  • v2.1.2
  • v2.2.0
  • v2.3.0
  • v2.3.1
  • v2.3.2
  • v2.3.3
  • v2.4.0
  • v2.4.1
  • v2.4.2
  • v2.5.0
  • v3.0.0
  • v3.0.1
  • v3.0.2
  • v3.1.0
  • v3.1.0-openshift
  • v3.2.0
  • v3.2.1
  • v3.2.2
  • v3.3.0
  • v3.3.1
  • v3.4.0
  • v3.4.1
  • v3.4.2
  • v3.4.3
  • v4.0.0
  • v4.0.1
  • v4.0.2
  • v4.1.0
  • v4.1.1
100 results

Target

Select target project
  • web-et-numerique / Factory / Resin / Client
1 result
Select Git revision
  • 354-actualites-partage-article-via-rs-image-d-illus-a-la-place-du-logo-res-in
  • 582-modification-fiche-structure-offre-structure-vs-offre-accompagnant-numerique-ordre-des-blocs
  • 630-bo-admin-fonction-2
  • 673-fiche-structure-mise-en-forme-des-rs
  • 722-envsubst-client-side-conf
  • 723-structures-l-api-ne-prend-pas-en-compte-l-offre-des-mediateurs
  • 728-cartographie-ordre-d-affichage-de-la-liste
  • 734-actualites-menu-en-mobile
  • dev
  • feat/nginx-security
  • master
  • renovate/bluehalo-ngx-leaflet-20.x
  • renovate/chokidar-4.x
  • renovate/chromatic-com-storybook-4.x
  • renovate/devdependencies-(non-major)
  • renovate/leaflet.locatecontrol-0.x
  • renovate/major-ag-grid-monorepo
  • renovate/major-angular-cli-monorepo
  • renovate/major-angular-eslint-monorepo
  • renovate/major-angular-monorepo
  • renovate/major-angularmaterial-monorepo
  • renovate/major-storybook-monorepo
  • renovate/major-typescript-eslint-monorepo
  • renovate/ng-packagr-20.x
  • renovate/ngx-matomo-client-8.x
  • renovate/ngx-toastr-19.x
  • renovate/npm-11.x
  • wip_3.4
  • 1.1.0
  • v0.0.1
  • v0.0.2
  • v0.0.3
  • v1.1.0
  • v1.10.0
  • v1.11.0
  • v1.11.1
  • v1.12.0
  • v1.12.1
  • v1.13.0
  • v1.14.0
  • v1.15.0
  • v1.16.0
  • v1.16.1
  • v1.16.2
  • v1.16.3
  • v1.17.0
  • v1.17.1
  • v1.17.2
  • v1.17.3
  • v1.2.0
  • v1.3.0
  • v1.4.0
  • v1.5.0
  • v1.6.0
  • v1.6.1
  • v1.7.0
  • v1.8.0
  • v1.9.0
  • v1.9.1
  • v2.0.0
  • v2.0.0-beta1
  • v2.0.0-beta1.1
  • v2.0.0-beta2
  • v2.0.0-beta2.1
  • v2.0.0-beta2.2
  • v2.0.0-beta4
  • v2.0.0-beta5
  • v2.0.1
  • v2.0.2
  • v2.1.0
  • v2.1.1
  • v2.1.2
  • v2.2.0
  • v2.3.0
  • v2.3.1
  • v2.3.2
  • v2.3.3
  • v2.4.0
  • v2.4.1
  • v2.4.2
  • v2.5.0
  • v3.0.0
  • v3.0.1
  • v3.0.2
  • v3.1.0
  • v3.1.0-openshift
  • v3.2.0
  • v3.2.1
  • v3.2.2
  • v3.3.0
  • v3.3.1
  • v3.4.0
  • v3.4.1
  • v3.4.2
  • v3.4.3
  • v4.0.0
  • v4.0.1
  • v4.0.2
  • v4.1.0
  • v4.1.1
100 results
Show changes

Commits on Source 3

151 files
+ 11844
11326
Compare changes
  • Side-by-side
  • Inline

Files

.eslintignore

0 → 100644
+8 −0
Original line number Diff line number Diff line
.angular/
.git/
.idea/
.vscode/
build/
coverage/
dist/
node_modules/
 No newline at end of file

.eslintrc.json

0 → 100644
+37 −0
Original line number Diff line number Diff line
{
  "root": true,
  "ignorePatterns": ["projects/**/*"],
  "overrides": [
    {
      "files": ["*.ts"],
      "parserOptions": {
        "project": ["tsconfig.json"],
        "createDefaultProgram": true
      },
      "extends": ["plugin:@angular-eslint/recommended", "plugin:@angular-eslint/template/process-inline-templates"],
      "rules": {
        "@angular-eslint/directive-selector": [
          "error",
          {
            "type": "attribute",
            "prefix": "app",
            "style": "camelCase"
          }
        ],
        "@angular-eslint/component-selector": [
          "error",
          {
            "type": "element",
            "prefix": "app",
            "style": "kebab-case"
          }
        ]
      }
    },
    {
      "files": ["*.html"],
      "extends": ["plugin:@angular-eslint/template/recommended"],
      "rules": {}
    }
  ]
}
+2 −3
Original line number Diff line number Diff line
@@ -54,6 +54,5 @@ api/db.json
# Documentation generated with compodoc
documentation

CHANGELOG.md

package-lock.json
# External libs
/projects
Original line number Diff line number Diff line
| :triangular_flag_on_post: Give your MR the same name that the desired squash commit. In doubt, check the conventional commit [doc](https://www.conventionalcommits.org/en/v1.0.0/).|
| --- |

## What does this MR do and why?

_Describe in detail what your merge request does and why._

| :warning: Keep an up to date checklist based on your icescrum tasks during all the draft phase to help any other developer who would take the job after you to finish it. |
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |

| :warning: Keep an up to date checklist based on your icescrum tasks during all the draft phase of the MR to help any other developer who would take the job after you to finish it.|
| --- |

## Screenshots or screen recordings

_These are strongly recommended to assist reviewers and reduce the time to merge your change._


## How to set up and validate locally (or on alpha)

_List all steps to set up and validate the changes on local environment._

## MR acceptance checklist

_To be completed by the chosen reviewer._

<!---
@@ -25,9 +27,10 @@ More reading on checklists can be found in the "Checklist Manifesto": http://atu
"It is common to misconceive how checklists function in complex lines of work. They are not comprehensive how-to guides, whether for building a skyscraper or getting a plane out of trouble. They are quick and simple tools aimed to buttress the skills of expert professionals." - Gawande, Atul. The Checklist Manifesto
--->


### Quality

- [ ] Confirmed
* [ ] Confirmed

1. For the code that this change impacts, I believe that the automated tests validate functionality that is highly important to users.  If the existing automated tests do not cover this functionality, I have added the necessary additional tests or I have added an issue to describe the automation testing gap and linked it to this MR.
1. I have made sure that the sonar quality coverage is up to standards.
@@ -37,26 +40,26 @@ More reading on checklists can be found in the "Checklist Manifesto": http://atu

### Performance, reliability and availability

- [ ] Confirmed
* [ ] Confirmed

1. I am confident that this MR does not harm performance, or I have asked a reviewer to help assess the performance impact.
1. I have considered the scalability risk based on future predicted growth.

### Documentation

- [ ] Confirmed
* [ ] Confirmed

1. I have prepared a squash commit to feed the changelog linked to the current milestone.
1. The MR is named after the desired squash commit to feed the changelog linked to the current milestone.
1. I have added/updated documentation (also updated if the changes feature a deprecation) or I have decided that documentation changes are not needed for this MR.

### Security

- [ ] Confirmed
* [ ] Confirmed

1. I have confirmed that if this MR does not contains any sensitive informations hidden in the changes.

### Deployment

- [ ] Confirmed
* [ ] Confirmed

1. When featured on a self-data project release, i have made sure my app version in the manifest and package.json is incremented and any relative changes to the permissions are clearly written and transmitted to Cozy.
+1 −0
Original line number Diff line number Diff line
@@ -15,6 +15,7 @@ RUN npm install --silent
COPY angular.json .
COPY tsconfig.json .
COPY tsconfig.app.json .
COPY tsconfig.base.json .
COPY ngsw-config.json .
COPY /nginx/nginx.conf .
COPY /src ./src
+198 −158
Original line number Diff line number Diff line
@@ -152,6 +152,46 @@
          }
        }
      }
    },
    "@gouvfr-anct/mediation-numerique": {
      "projectType": "library",
      "root": "projects/gouvfr-anct/mediation-numerique",
      "sourceRoot": "projects/gouvfr-anct/mediation-numerique/src",
      "prefix": "lib",
      "architect": {
        "build": {
          "builder": "@angular-devkit/build-angular:ng-packagr",
          "options": {
            "project": "projects/gouvfr-anct/mediation-numerique/ng-package.json"
          },
          "configurations": {
            "production": {
              "tsConfig": "projects/gouvfr-anct/mediation-numerique/tsconfig.lib.prod.json"
            },
            "development": {
              "tsConfig": "projects/gouvfr-anct/mediation-numerique/tsconfig.lib.json"
            }
          },
          "defaultConfiguration": "production"
        },
        "test": {
          "builder": "@angular-builders/jest:run",
          "options": {
            "configPath": "jest.config.js",
            "tsConfig": "tsconfig.spec.json",
            "scripts": []
          }
        },
        "lint": {
          "builder": "@angular-eslint/builder:lint",
          "options": {
            "lintFilePatterns": [
              "projects/gouvfr-anct/mediation-numerique/src/**/*.ts",
              "projects/gouvfr-anct/mediation-numerique/src/**/*.html"
            ]
          }
        }
      }
    }
  },
  "defaultProject": "pamn"

jest.config.js

0 → 100644
+7 −0
Original line number Diff line number Diff line
module.exports = {
  preset: 'jest-preset-angular',
  setupFilesAfterEnv: ['<rootDir>/jest.setup.ts'],
  moduleNameMapper: {
    '@gouvfr-anct/(.*)': '<rootDir>/dist/@gouvfr-anct/$1',
  },
};

jest.setup.ts

0 → 100644
+1 −0
Original line number Diff line number Diff line
import 'jest-preset-angular/jest-preset';
+10267 −5073

File changed.

Preview size limit exceeded, changes collapsed.

+17 −1
Original line number Diff line number Diff line
@@ -22,13 +22,14 @@
    "@angular/common": "~13.1.1",
    "@angular/compiler": "~13.1.1",
    "@angular/core": "~13.1.1",
    "@angular/flex-layout": "^10.0.0-beta.32",
    "@angular/flex-layout": "^13.0.0-beta.38",
    "@angular/forms": "~13.1.1",
    "@angular/platform-browser": "~13.1.1",
    "@angular/platform-browser-dynamic": "~13.1.1",
    "@angular/router": "~13.1.1",
    "@angular/service-worker": "~13.1.1",
    "@asymmetrik/ngx-leaflet": "^8.1.0",
    "@gouvfr-anct/mediation-numerique": "^0.0.17",
    "@ngx-translate/core": "^13.0.0",
    "ag-grid-angular": "^26.2.0",
    "ag-grid-community": "^26.2.1",
@@ -43,29 +44,44 @@
    "zone.js": "~0.11.4"
  },
  "devDependencies": {
    "@angular-builders/jest": "^13.0.3",
    "@angular-devkit/build-angular": "^13.2.1",
    "@angular-eslint/builder": "^13.2.1",
    "@angular-eslint/eslint-plugin": "^13.2.1",
    "@angular-eslint/eslint-plugin-template": "^13.2.1",
    "@angular-eslint/schematics": "^13.2.1",
    "@angular-eslint/template-parser": "^13.2.1",
    "@angular/cli": "^13.1.2",
    "@angular/compiler-cli": "~13.1.1",
    "@angular/localize": "^13.1.1",
    "@compodoc/compodoc": "^1.1.16",
    "@types/jasmine": "~4.0.0",
    "@types/jasminewd2": "~2.0.3",
    "@types/jest": "^27.5.0",
    "@types/leaflet": "^1.5.17",
    "@types/leaflet.locatecontrol": "^0.60.7",
    "@types/node": "^16.0.0",
    "@typescript-eslint/eslint-plugin": "^5.24.0",
    "@typescript-eslint/parser": "^5.24.0",
    "codelyzer": "^6.0.0",
    "eslint": "^8.15.0",
    "eslint-plugin-jest": "^26.2.2",
    "http-server": "^14.1.0",
    "jasmine-core": "~4.1.0",
    "jasmine-spec-reporter": "~5.0.0",
    "jest": "^27.5.1",
    "jest-preset-angular": "^11.1.2",
    "karma": "^6.3.9",
    "karma-browserify": "^7.0.0",
    "karma-chrome-launcher": "~3.1.0",
    "karma-coverage-istanbul-reporter": "~3.0.2",
    "karma-jasmine": "~4.0.0",
    "karma-jasmine-html-reporter": "^1.5.0",
    "ng-packagr": "^13.0.0",
    "prettier": "^2.1.2",
    "protractor": "~7.0.0",
    "standard-version": "^9.3.2",
    "ts-jest": "^27.1.4",
    "ts-node": "~8.3.0",
    "tslint": "~6.1.0",
    "typescript": "~4.5.4"
Original line number Diff line number Diff line
@@ -8,7 +8,6 @@ import { OrientationFormComponent } from './form/orientation-form/orientation-fo
import { AdminGuard } from './guards/admin.guard';
import { AuthGuard } from './guards/auth.guard';
import { LoginGuard } from './guards/login.guard';
import { DeactivateGuard } from './guards/deactivate.guard';
import { LegalNoticeComponent } from './legal-notice/legal-notice.component';
import { LoginComponent } from './login/login.component';
import { NewsletterSubscriptionComponent } from './newsletter-subscription/newsletter-subscription.component';
@@ -18,10 +17,9 @@ import { ResetEmailComponent } from './reset-email/reset-email.component';
import { ResetPasswordComponent } from './reset-password/reset-password.component';
import { StructureResolver } from './resolvers/structure.resolver';
import { PasswordFormComponent } from './shared/components';
import { StructureJoinComponent } from './structure/structure-join/structure-join.component';
import { StructureDetailsComponent } from './structure-list/components/structure-details/structure-details.component';
import { StructureListComponent } from './structure-list/structure-list.component';
import { StructureDetailsWrapperComponent } from './structure/components/structure-details-wrapper/structure-details-wrapper.component';
import { StructureExcludeComponent } from './structure/structure-exclude/structure-exclude.component';
import { StructureJoinComponent } from './structure/structure-join/structure-join.component';

const footerOutletRoute: Route = {
  path: '',
@@ -33,7 +31,7 @@ const routes: Routes = [
  {
    path: 'print',
    outlet: 'print',
    children: [{ path: 'structure', component: StructureDetailsComponent }, footerOutletRoute],
    children: [{ path: 'structure', component: StructureDetailsWrapperComponent }, footerOutletRoute],
  },
  {
    path: 'print',
@@ -60,7 +58,7 @@ const routes: Routes = [
      {
        path: '',
        outlet: 'left-pane',
        component: StructureDetailsComponent,
        component: StructureDetailsWrapperComponent,
      },
    ],
  },
@@ -74,16 +72,6 @@ const routes: Routes = [
      footerOutletRoute,
    ],
  },
  {
    path: 'structures',
    children: [
      {
        path: '',
        component: StructureListComponent,
      },
      footerOutletRoute,
    ],
  },
  {
    path: 'legal-notice',
    children: [
@@ -152,7 +140,7 @@ const routes: Routes = [
        path: '',
        outlet: 'left-pane',
        data: { fullScreen: true },
        component: StructureDetailsComponent,
        component: StructureDetailsWrapperComponent,
      },
    ],
  },
Original line number Diff line number Diff line
@@ -4,7 +4,6 @@ import { ProfileService } from './profile/services/profile.service';
import { AuthService } from './services/auth.service';
import { RouterListenerService } from './services/routerListener.service';
import { UpdateService } from './services/update.service';
import { PrintService } from './shared/service/print.service';

@Component({
  selector: 'app-root',
@@ -16,7 +15,6 @@ export class AppComponent implements OnInit {
  public loading = true;

  constructor(
    public printService: PrintService,
    private authService: AuthService,
    private profilService: ProfileService,
    private routerListener: RouterListenerService,
Original line number Diff line number Diff line
import { LOCALE_ID, NgModule } from '@angular/core';
import { HttpClientModule, HTTP_INTERCEPTORS } from '@angular/common/http';
import { LOCALE_ID, NgModule } from '@angular/core';
import { BrowserModule } from '@angular/platform-browser';
import { BrowserAnimationsModule } from '@angular/platform-browser/animations';
import { ServiceWorkerModule } from '@angular/service-worker';
import { GeometryPolygonConfiguration, MapModule, StructureModule } from '@gouvfr-anct/mediation-numerique';
import { ToastrModule } from 'ngx-toastr';

import metropole from '../assets/geojson/metropole.json';
import { environment } from '../environments/environment';
import { AppRoutingModule } from './app-routing.module';

import { AppComponent } from './app.component';
import { CartoComponent } from './carto/carto.component';
import { CustomBreakPointsProvider } from './config/custom-breakpoint';
import { CustomHttpInterceptor } from './config/http-interceptor';
import { InitialPosition } from './config/map/initial-position';
import { MarkerType } from './config/map/marker-type';
import { ZoomLevel } from './config/map/zoomLevel.enum';
import { ContactComponent } from './contact/contact.component';
import { FooterComponent } from './footer/footer.component';
import { FormViewModule } from './form/form-view/form-view.module';
import { OrientationComponent } from './form/orientation-form/component/orientation-modal/orientation-modal.component';
import { StructureDetailPrintComponent } from './form/orientation-form/component/structure-detail-print/structure-detail-print.component';
import { StructureListPrintComponent } from './form/orientation-form/component/structure-list-print/structure-list-print.component';
import { StructurePrintHeaderComponent } from './form/orientation-form/component/structure-print-header/structure-print-header.component';
import { OrientationFormComponent } from './form/orientation-form/orientation-form.component';
import { AdminGuard } from './guards/admin.guard';
import { AuthGuard } from './guards/auth.guard';
import { DeactivateGuard } from './guards/deactivate.guard';
import { LoginGuard } from './guards/login.guard';
import { RoleGuard } from './guards/role.guard';
import { HeaderComponent } from './header/header.component';
import { SharedModule } from './shared/shared.module';
import { MapModule } from './map/map.module';
import { StructureListComponent } from './structure-list/structure-list.component';
import { CardComponent } from './structure-list/components/card/card.component';
import { StructureListSearchComponent } from './structure-list/components/structure-list-search/structure-list-search.component';
import { StructureDetailsComponent } from './structure-list/components/structure-details/structure-details.component';
import { ModalFilterComponent } from './structure-list/components/modal-filter/modal-filter.component';
import { LegalNoticeComponent } from './legal-notice/legal-notice.component';
import { LoginComponent } from './login/login.component';
import { NewsletterSubscriptionComponent } from './newsletter-subscription/newsletter-subscription.component';
import { PageComponent } from './page/page.component';
import { ContactComponent } from './contact/contact.component';
import { AuthGuard } from './guards/auth.guard';
import { LoginGuard } from './guards/login.guard';
import { CustomHttpInterceptor } from './config/http-interceptor';
import { ResetEmailComponent } from './reset-email/reset-email.component';
import { ResetPasswordComponent } from './reset-password/reset-password.component';
import { AdminGuard } from './guards/admin.guard';
import { DeactivateGuard } from './guards/deactivate.guard';
import { StructureResolver } from './resolvers/structure.resolver';
import { TempUserResolver } from './resolvers/temp-user.resolver';
import { StructureJoinComponent } from './structure/structure-join/structure-join.component';
import { GeojsonService } from './services/geojson.service';
import { RouterListenerService } from './services/routerListener.service';
import { NewsletterSubscriptionComponent } from './newsletter-subscription/newsletter-subscription.component';
import { OrientationFormComponent } from './form/orientation-form/orientation-form.component';
import { StructureDetailPrintComponent } from './form/orientation-form/component/structure-detail-print/structure-detail-print.component';
import { StructureListPrintComponent } from './form/orientation-form/component/structure-list-print/structure-list-print.component';
import { StructurePrintHeaderComponent } from './form/orientation-form/component/structure-print-header/structure-print-header.component';
import { OrientationComponent } from './form/orientation-form/component/orientation-modal/orientation-modal.component';
import { ServiceWorkerModule } from '@angular/service-worker';
import { environment } from '../environments/environment';
import { StructureResolver } from './resolvers/structure.resolver';
import { RoleGuard } from './guards/role.guard';
import { StructureService } from './services/structure.service';
import { UpdateService } from './services/update.service';
import { DataShareConsentComponent } from './shared/components/data-share-consent/data-share-consent.component';
import { FormViewModule } from './form/form-view/form-view.module';
import { LoginComponent } from './login/login.component';
import { SharedModule } from './shared/shared.module';
import { SearchService } from './structure-list/services/search.service';
import { StructureDetailsActionsComponent } from './structure/components/structure-details-actions/structure-details-actions.component';
import { StructureDetailsModalsComponent } from './structure/components/structure-details-modals/structure-details-modals.component';
import { StructureDetailsWrapperComponent } from './structure/components/structure-details-wrapper/structure-details-wrapper.component';
import { TclAccessComponent } from './structure/components/tcl-access/tcl-access.component';
import { StructureExcludeComponent } from './structure/structure-exclude/structure-exclude.component';
import { StructureJoinComponent } from './structure/structure-join/structure-join.component';

@NgModule({
  declarations: [
@@ -53,11 +57,6 @@ import { StructureExcludeComponent } from './structure/structure-exclude/structu
    HeaderComponent,
    FooterComponent,
    CartoComponent,
    StructureListComponent,
    CardComponent,
    StructureListSearchComponent,
    ModalFilterComponent,
    StructureDetailsComponent,
    LegalNoticeComponent,
    PageComponent,
    ContactComponent,
@@ -72,16 +71,27 @@ import { StructureExcludeComponent } from './structure/structure-exclude/structu
    DataShareConsentComponent,
    OrientationComponent,
    LoginComponent,
    TclAccessComponent,
    StructureDetailsModalsComponent,
    StructureDetailsActionsComponent,
    StructureExcludeComponent,
    StructureDetailsWrapperComponent,
  ],
  imports: [
    BrowserModule,
    HttpClientModule,
    AppRoutingModule,
    SharedModule,
    MapModule,
    MapModule.forRoot(
      metropole as GeometryPolygonConfiguration,
      ZoomLevel,
      InitialPosition,
      MarkerType,
      GeojsonService
    ),
    BrowserAnimationsModule,
    ToastrModule.forRoot(),
    StructureModule.forRoot(SearchService, StructureService),
    FormViewModule,
    ServiceWorkerModule.register('ngsw-worker.js', {
      enabled: environment.production,
Original line number Diff line number Diff line
@@ -4,6 +4,7 @@
  </div>
  <div class="panes-container" fxLayout="row">
    <app-structure-list
      #ref
      (searchEvent)="getStructures($event)"
      [structureList]="structures"
      [location]="currentLocation"
@@ -12,9 +13,29 @@
      [selectedStructure]="currentStructure"
      (updatedStructure)="updateStructures($event)"
      class="left-pane"
      [ngClass]="{ mapPhone: isMapPhone == true }"
      [ngClass]="{ mapPhone: isMapPhone === true }"
      fxLayout="column"
    ></app-structure-list>
    >
      <div slot="structure-list-actions">
        <app-button
          tabindex="0"
          (action)="addStructure()"
          [text]="'Ajouter une structure'"
          [style]="buttonTypeEnum.Secondary"
          [extraClass]="'small-text'"
        ></app-button>
      </div>
      <div slot="structure-list-elements">
        <app-card
          *ngFor="let structure of ref.structureList"
          [structure]="structure"
          [isClaimed]="((structureClaims | async) ?? [])[structure._id]"
          (showDetails)="ref.showDetails($event)"
          (hover)="ref.handleCardHover($event)"
          class="structure-card"
        ></app-card>
      </div>
    </app-structure-list>
    <div class="btnSwitch">
      <app-button
        [style]="buttonTypeEnum.ButtonPhone"
@@ -31,7 +52,7 @@
      [isMapPhone]="isMapPhone"
      [searchedValue]="searchedValue"
      class="right-pane"
      [ngClass]="{ mapPhone: isMapPhone == true }"
      [ngClass]="{ mapPhone: isMapPhone === true }"
    ></app-map>
  </div>
</div>
Original line number Diff line number Diff line
import { Component, OnInit } from '@angular/core';
import { Meta } from '@angular/platform-browser';
import { ActivatedRoute } from '@angular/router';
import { ActivatedRoute, Router } from '@angular/router';
import { Filter, GeoJson, Structure } from '@gouvfr-anct/mediation-numerique';
import { ButtonType } from '@gouvfr-anct/mediation-numerique/shared';
import * as _ from 'lodash';
import { GeoJson } from '../map/models/geojson.model';
import { Structure } from '../models/structure.model';
import { Observable } from 'rxjs';
import { AuthService } from '../services/auth.service';
import { GeojsonService } from '../services/geojson.service';
import { StructureService } from '../services/structure.service';
import { ButtonType } from '../shared/components/button/buttonType.enum';
import { Filter } from '../structure-list/models/filter.model';
import { CustomRegExp } from '../utils/CustomRegExp';

@Component({
@@ -28,11 +28,15 @@ export class CartoComponent implements OnInit {
  public isMapPhone = false;
  public searchedValue = null;
  public buttonTypeEnum = ButtonType;


  constructor(
    private structureService: StructureService,
    private geoJsonService: GeojsonService,
    private activatedRoute: ActivatedRoute,
    private meta: Meta
    private meta: Meta,
    private router: Router,
    private authService: AuthService
  ) {}

  ngOnInit(): void {
@@ -114,11 +118,12 @@ export class CartoComponent implements OnInit {
        }
        return structure;
      })
    ).then((structureList) => {
    ).then(async (structureList: Structure[]) => {
      if (sortByDistance) {
        structureList = _.sortBy(structureList, ['distance']);
      }
      this.structures = structureList;
      // await this.setClaimIndicators(this.profilService.isAdmin());
    });
  }

@@ -207,4 +212,16 @@ export class CartoComponent implements OnInit {
  public switchMapList(): void {
    this.isMapPhone = !this.isMapPhone;
  }

  public addStructure(): void {
    if (!this.authService.isLoggedIn()) {
      this.router.navigateByUrl('/login');
    } else {
      this.router.navigateByUrl('/form/structure');
    }
  }

  public isClaimed(structure): Observable<boolean> {
    return this.structureService.isClaimed(structure._id, null);
  }
}
Original line number Diff line number Diff line
import { Component, EventEmitter, Input, OnChanges, Output, SimpleChanges } from '@angular/core';
import { FormGroup } from '@angular/forms';
import { Router } from '@angular/router';
import { ButtonType } from '@gouvfr-anct/mediation-numerique/shared';
import { User } from '../../models/user.model';
import { ProfileService } from '../../profile/services/profile.service';
import { AuthService } from '../../services/auth.service';
import { NewsletterService } from '../../services/newsletter.service';
import { ButtonType } from '../../shared/components/button/buttonType.enum';
import { Utils } from '../../utils/utils';
import { accountFormStep } from '../form-view/account-form/accountFormStep.enum';
import { formType } from '../form-view/formType.enum';
Original line number Diff line number Diff line
import { Component, OnInit } from '@angular/core';
import { FormControl, FormGroup, Validators } from '@angular/forms';
import { ActivatedRoute, NavigationEnd, Router } from '@angular/router';
import { PersonalOffer, Structure } from '@gouvfr-anct/mediation-numerique';
import { forkJoin, of } from 'rxjs';
import { catchError, map } from 'rxjs/operators';
import { PersonalOffer } from '../../models/personalOffer.model';
import { Structure } from '../../models/structure.model';
import { StructureWithOwners } from '../../models/structureWithOwners.model';
import { User } from '../../models/user.model';
import { ProfileService } from '../../profile/services/profile.service';
Original line number Diff line number Diff line
import { Component, EventEmitter, Input, Output } from '@angular/core';
import { Router } from '@angular/router';
import { ButtonType } from '../../../../shared/components/button/buttonType.enum';
import { ButtonType } from '@gouvfr-anct/mediation-numerique/shared';
import { accountFormStep } from '../../account-form/accountFormStep.enum';
import { formType } from '../../formType.enum';
import { personalOfferFormStep } from '../../personal-offer-form/personalOfferFormStep.enum';
Original line number Diff line number Diff line
import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';
import { FormGroup } from '@angular/forms';
import { Structure } from '../../../../models/structure.model';
import { ButtonType } from '../../../../shared/components/button/buttonType.enum';
import { Category } from '../../../../structure-list/models/category.model';
import { Module } from '../../../../structure-list/models/module.model';
import { Category, Module } from '@gouvfr-anct/mediation-numerique';
import { ButtonType } from '@gouvfr-anct/mediation-numerique/shared';
import { SearchService } from '../../../../structure-list/services/search.service';

@Component({
Original line number Diff line number Diff line
import { Component, ElementRef, EventEmitter, Input, Output, ViewChild } from '@angular/core';
import { FormGroup } from '@angular/forms';
import { ButtonType } from '@gouvfr-anct/mediation-numerique/shared';
import { Employer } from '../../../../models/employer.model';
import { ProfileService } from '../../../../profile/services/profile.service';
import { ButtonType } from '../../../../shared/components/button/buttonType.enum';

@Component({
  selector: 'app-profile-employer-selection',
Original line number Diff line number Diff line
import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';
import { FormGroup } from '@angular/forms';
import { ButtonType } from '@gouvfr-anct/mediation-numerique/shared';
import { Job } from '../../../../models/job.model';
import { ProfileService } from '../../../../profile/services/profile.service';
import { ButtonType } from '../../../../shared/components/button/buttonType.enum';

@Component({
  selector: 'app-profile-job-selection',
Original line number Diff line number Diff line
import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';
import { FormGroup } from '@angular/forms';
import { Structure } from '../../../../models/structure.model';
import { Filter, Structure } from '@gouvfr-anct/mediation-numerique';
import { ButtonType } from '@gouvfr-anct/mediation-numerique/shared';
import { ProfileService } from '../../../../profile/services/profile.service';
import { StructureService } from '../../../../services/structure.service';
import { ButtonType } from '../../../../shared/components/button/buttonType.enum';
import { Filter } from '../../../../structure-list/models/filter.model';

@Component({
  selector: 'app-profile-structure-choice',
Original line number Diff line number Diff line
import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';
import { FormGroup } from '@angular/forms';
import { ButtonType } from '../../../../shared/components/button/buttonType.enum';
import { Category } from '../../../../structure-list/models/category.model';
import { Category } from '@gouvfr-anct/mediation-numerique';
import { ButtonType } from '@gouvfr-anct/mediation-numerique/shared';

@Component({
  selector: 'app-structure-digital-helping-accompaniment',
Original line number Diff line number Diff line
import { Component, EventEmitter, Input, OnInit, Output } from '@angular/core';
import { AbstractControl, FormGroup } from '@angular/forms';
import { Module } from '../../../../structure-list/models/module.model';
import { Module } from '@gouvfr-anct/mediation-numerique';

@Component({
  selector: 'app-structure-equipments',
Original line number Diff line number Diff line
import { Component, EventEmitter, Input, OnChanges, OnInit, Output, SimpleChanges } from '@angular/core';
import { AbstractControl, FormArray, FormControl, FormGroup } from '@angular/forms';
import { ActivatedRoute } from '@angular/router';
import { Address } from '../../../models/address.model';
import { Structure } from '../../../models/structure.model';
import { Address, Category, Module, Structure } from '@gouvfr-anct/mediation-numerique';
import { User } from '../../../models/user.model';
import { ProfileService } from '../../../profile/services/profile.service';
import { CategoryEnum } from '../../../shared/enum/category.enum';
import { Category } from '../../../structure-list/models/category.model';
import { Module } from '../../../structure-list/models/module.model';
import { SearchService } from '../../../structure-list/services/search.service';
import { formType } from '../formType.enum';
import { structureFormStep } from './structureFormStep.enum';