@onemrvapublic/design-system 0.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.dockerignore +4 -0
- package/.editorconfig +16 -0
- package/.github/workflows/npm-publish.yml +34 -0
- package/README.md +27 -0
- package/angular.json +214 -0
- package/build.sh +108 -0
- package/cypress.config.ts +40 -0
- package/index.html +10 -0
- package/npm-publish.sh +11 -0
- package/package.json +89 -0
- package/projects/onemrva/design-system/README.md +24 -0
- package/projects/onemrva/design-system/_index.scss +29 -0
- package/projects/onemrva/design-system/_utils.scss +25 -0
- package/projects/onemrva/design-system/layout/assets/logo_de.svg +3 -0
- package/projects/onemrva/design-system/layout/assets/logo_en.svg +3 -0
- package/projects/onemrva/design-system/layout/assets/logo_fr.svg +3 -0
- package/projects/onemrva/design-system/layout/assets/logo_nl.svg +3 -0
- package/projects/onemrva/design-system/layout/assets/logo_onem_rva.svg +32 -0
- package/projects/onemrva/design-system/layout/index.ts +7 -0
- package/projects/onemrva/design-system/layout/ng-package.json +6 -0
- package/projects/onemrva/design-system/layout/src/components/index.ts +31 -0
- package/projects/onemrva/design-system/layout/src/components/layout/_layout-mixin.component.scss +159 -0
- package/projects/onemrva/design-system/layout/src/components/layout/layout.component.html +194 -0
- package/projects/onemrva/design-system/layout/src/components/layout/layout.component.scss +137 -0
- package/projects/onemrva/design-system/layout/src/components/layout/layout.component.spec.ts +24 -0
- package/projects/onemrva/design-system/layout/src/components/layout/layout.component.ts +187 -0
- package/projects/onemrva/design-system/layout/src/components/layout-content/layout-content.component.spec.ts +24 -0
- package/projects/onemrva/design-system/layout/src/components/layout-content/layout-content.component.ts +23 -0
- package/projects/onemrva/design-system/layout/src/components/layout-footer/layout-footer.component.ts +11 -0
- package/projects/onemrva/design-system/layout/src/components/layout-login-menu/layout-login-menu.component.spec.ts +25 -0
- package/projects/onemrva/design-system/layout/src/components/layout-login-menu/layout-login-menu.component.ts +17 -0
- package/projects/onemrva/design-system/layout/src/components/layout-route/layout-route.component.html +57 -0
- package/projects/onemrva/design-system/layout/src/components/layout-route/layout-route.component.spec.ts +24 -0
- package/projects/onemrva/design-system/layout/src/components/layout-route/layout-route.component.ts +56 -0
- package/projects/onemrva/design-system/layout/src/components/layout-sidenav/layout-sidenav.component.html +104 -0
- package/projects/onemrva/design-system/layout/src/components/layout-sidenav/layout-sidenav.component.ts +88 -0
- package/projects/onemrva/design-system/layout/src/components/layout-sidenav-title/layout-sidenav-title.component.ts +9 -0
- package/projects/onemrva/design-system/layout/src/components/layout-subroute/layout-subroute.component.html +44 -0
- package/projects/onemrva/design-system/layout/src/components/layout-subroute/layout-subroute.component.spec.ts +24 -0
- package/projects/onemrva/design-system/layout/src/components/layout-subroute/layout-subroute.component.ts +35 -0
- package/projects/onemrva/design-system/layout/src/components/layout-title/layout-title.component.spec.ts +25 -0
- package/projects/onemrva/design-system/layout/src/components/layout-title/layout-title.component.ts +17 -0
- package/projects/onemrva/design-system/layout/src/decorators/coerce-boolean-input.decorator.ts +19 -0
- package/projects/onemrva/design-system/layout/src/decorators/observable-content.decorator.ts +13 -0
- package/projects/onemrva/design-system/layout/src/directives/drawer-host.directive.ts +10 -0
- package/projects/onemrva/design-system/layout/src/enums/environment.enum.ts +6 -0
- package/projects/onemrva/design-system/layout/src/layout.component.spec.ts +24 -0
- package/projects/onemrva/design-system/layout/src/layout.module.ts +103 -0
- package/projects/onemrva/design-system/layout/src/models/onem-language.model.ts +4 -0
- package/projects/onemrva/design-system/layout/src/models/onemrva-profile.model.ts +57 -0
- package/projects/onemrva/design-system/layout/src/services/drawer.service.ts +28 -0
- package/projects/onemrva/design-system/layout/src/striphtml.pipe.ts +11 -0
- package/projects/onemrva/design-system/layout/src/test.ts +25 -0
- package/projects/onemrva/design-system/mat-avatar/index.ts +2 -0
- package/projects/onemrva/design-system/mat-avatar/ng-package.json +6 -0
- package/projects/onemrva/design-system/mat-avatar/src/onemrva-mat-avatar.component.html +17 -0
- package/projects/onemrva/design-system/mat-avatar/src/onemrva-mat-avatar.component.scss +130 -0
- package/projects/onemrva/design-system/mat-avatar/src/onemrva-mat-avatar.component.ts +421 -0
- package/projects/onemrva/design-system/mat-avatar/src/onemrva-mat-avatar.module.ts +17 -0
- package/projects/onemrva/design-system/mat-badge/index.ts +6 -0
- package/projects/onemrva/design-system/mat-badge/ng-package.json +6 -0
- package/projects/onemrva/design-system/mat-badge/src/onemrva-mat-badge.component.scss +152 -0
- package/projects/onemrva/design-system/mat-badge/src/onemrva-mat-badge.component.ts +291 -0
- package/projects/onemrva/design-system/mat-badge/src/onemrva-mat-badge.module.ts +8 -0
- package/projects/onemrva/design-system/mat-breadcrumb/index.ts +7 -0
- package/projects/onemrva/design-system/mat-breadcrumb/ng-package.json +6 -0
- package/projects/onemrva/design-system/mat-breadcrumb/src/onemrva-mat-breadcrumb.component.html +37 -0
- package/projects/onemrva/design-system/mat-breadcrumb/src/onemrva-mat-breadcrumb.component.scss +70 -0
- package/projects/onemrva/design-system/mat-breadcrumb/src/onemrva-mat-breadcrumb.component.ts +16 -0
- package/projects/onemrva/design-system/mat-breadcrumb/src/onemrva-mat-breadcrumb.model.ts +4 -0
- package/projects/onemrva/design-system/mat-breadcrumb/src/onemrva-mat-breadcrumb.module.ts +12 -0
- package/projects/onemrva/design-system/mat-breadcrumb/src/onemrva-mat-breadcrumb.service.ts +65 -0
- package/projects/onemrva/design-system/mat-clipboard/index.ts +6 -0
- package/projects/onemrva/design-system/mat-clipboard/ng-package.json +6 -0
- package/projects/onemrva/design-system/mat-clipboard/src/_onemrva-mat-spinner.component.scss +62 -0
- package/projects/onemrva/design-system/mat-clipboard/src/onemrva-mat-clipboard.component.ts +16 -0
- package/projects/onemrva/design-system/mat-clipboard/src/onemrva-mat-clipboard.module.ts +14 -0
- package/projects/onemrva/design-system/mat-datepicker-header/index.ts +5 -0
- package/projects/onemrva/design-system/mat-datepicker-header/ng-package.json +6 -0
- package/projects/onemrva/design-system/mat-datepicker-header/src/_onemrva-mat-datepicker-header.component.scss +11 -0
- package/projects/onemrva/design-system/mat-datepicker-header/src/onemrva-mat-datepicker-header.component.html +53 -0
- package/projects/onemrva/design-system/mat-datepicker-header/src/onemrva-mat-datepicker-header.component.ts +285 -0
- package/projects/onemrva/design-system/mat-file-upload/index.ts +11 -0
- package/projects/onemrva/design-system/mat-file-upload/ng-package.json +6 -0
- package/projects/onemrva/design-system/mat-file-upload/src/components/index.ts +10 -0
- package/projects/onemrva/design-system/mat-file-upload/src/components/onemrva-mat-file-panel/onemrva-file-panel.component.html +59 -0
- package/projects/onemrva/design-system/mat-file-upload/src/components/onemrva-mat-file-panel/onemrva-file-panel.component.scss +24 -0
- package/projects/onemrva/design-system/mat-file-upload/src/components/onemrva-mat-file-panel/onemrva-file-panel.component.ts +79 -0
- package/projects/onemrva/design-system/mat-file-upload/src/components/onemrva-mat-file-upload/onemrva-mat-file-upload.component.html +53 -0
- package/projects/onemrva/design-system/mat-file-upload/src/components/onemrva-mat-file-upload/onemrva-mat-file-upload.component.scss +248 -0
- package/projects/onemrva/design-system/mat-file-upload/src/components/onemrva-mat-file-upload/onemrva-mat-file-upload.component.ts +185 -0
- package/projects/onemrva/design-system/mat-file-upload/src/directives/dnd.directive.ts +43 -0
- package/projects/onemrva/design-system/mat-file-upload/src/models/action-config.model.ts +10 -0
- package/projects/onemrva/design-system/mat-file-upload/src/models/progress-file.model.ts +94 -0
- package/projects/onemrva/design-system/mat-file-upload/src/onemrva-mat-file-upload-itf.store.ts +79 -0
- package/projects/onemrva/design-system/mat-file-upload/src/onemrva-mat-file-upload.module.ts +28 -0
- package/projects/onemrva/design-system/mat-file-upload/src/onemrva-mat-file-upload.service.ts +68 -0
- package/projects/onemrva/design-system/mat-file-upload/src/onemrva-mat-file-upload.store.ts +473 -0
- package/projects/onemrva/design-system/mat-input-bank-account/index.ts +5 -0
- package/projects/onemrva/design-system/mat-input-bank-account/ng-package.json +6 -0
- package/projects/onemrva/design-system/mat-input-bank-account/src/onemrva-mat-input-bank-account.component.html +32 -0
- package/projects/onemrva/design-system/mat-input-bank-account/src/onemrva-mat-input-bank-account.component.scss +9 -0
- package/projects/onemrva/design-system/mat-input-bank-account/src/onemrva-mat-input-bank-account.component.ts +125 -0
- package/projects/onemrva/design-system/mat-input-country/index.ts +6 -0
- package/projects/onemrva/design-system/mat-input-country/ng-package.json +6 -0
- package/projects/onemrva/design-system/mat-input-country/src/countries.ts +3182 -0
- package/projects/onemrva/design-system/mat-input-country/src/onemrva-mat-input-country.component.html +29 -0
- package/projects/onemrva/design-system/mat-input-country/src/onemrva-mat-input-country.component.scss +29 -0
- package/projects/onemrva/design-system/mat-input-country/src/onemrva-mat-input-country.component.ts +144 -0
- package/projects/onemrva/design-system/mat-input-enterprise-number/index.ts +5 -0
- package/projects/onemrva/design-system/mat-input-enterprise-number/ng-package.json +6 -0
- package/projects/onemrva/design-system/mat-input-enterprise-number/src/onemrva-mat-input-enterprise-number.component.html +39 -0
- package/projects/onemrva/design-system/mat-input-enterprise-number/src/onemrva-mat-input-enterprise-number.component.scss +25 -0
- package/projects/onemrva/design-system/mat-input-enterprise-number/src/onemrva-mat-input-enterprise-number.component.ts +190 -0
- package/projects/onemrva/design-system/mat-input-phone/index.ts +6 -0
- package/projects/onemrva/design-system/mat-input-phone/ng-package.json +6 -0
- package/projects/onemrva/design-system/mat-input-phone/src/onemrva-mat-input-phone.component.html +43 -0
- package/projects/onemrva/design-system/mat-input-phone/src/onemrva-mat-input-phone.component.scss +29 -0
- package/projects/onemrva/design-system/mat-input-phone/src/onemrva-mat-input-phone.component.ts +261 -0
- package/projects/onemrva/design-system/mat-input-phone/src/phone-number.directive.ts +47 -0
- package/projects/onemrva/design-system/mat-message-box/index.ts +2 -0
- package/projects/onemrva/design-system/mat-message-box/ng-package.json +6 -0
- package/projects/onemrva/design-system/mat-message-box/src/onemrva-mat-message-box.component.scss +60 -0
- package/projects/onemrva/design-system/mat-message-box/src/onemrva-mat-message-box.component.ts +134 -0
- package/projects/onemrva/design-system/mat-message-box/src/onemrva-mat-message-box.module.ts +12 -0
- package/projects/onemrva/design-system/mat-multi-select/index.ts +2 -0
- package/projects/onemrva/design-system/mat-multi-select/ng-package.json +6 -0
- package/projects/onemrva/design-system/mat-multi-select/src/_onemrva-mat-multi-select.component.scss +66 -0
- package/projects/onemrva/design-system/mat-multi-select/src/onemrva-mat-multi-select.component.html +24 -0
- package/projects/onemrva/design-system/mat-multi-select/src/onemrva-mat-multi-select.component.ts +152 -0
- package/projects/onemrva/design-system/mat-multi-select/src/onemrva-mat-multi-select.module.ts +31 -0
- package/projects/onemrva/design-system/mat-notification/index.ts +1 -0
- package/projects/onemrva/design-system/mat-notification/ng-package.json +6 -0
- package/projects/onemrva/design-system/mat-notification/src/_onemrva-mat-notification.component.scss +71 -0
- package/projects/onemrva/design-system/mat-notification/src/onemrva-mat-notification.component.html +10 -0
- package/projects/onemrva/design-system/mat-notification/src/onemrva-mat-notification.component.ts +158 -0
- package/projects/onemrva/design-system/mat-paginator/index.ts +6 -0
- package/projects/onemrva/design-system/mat-paginator/ng-package.json +7 -0
- package/projects/onemrva/design-system/mat-paginator/package.json +7 -0
- package/projects/onemrva/design-system/mat-paginator/src/_onemrva-mat-paginator.component.scss +122 -0
- package/projects/onemrva/design-system/mat-paginator/src/onemrva-mat-paginator.component.html +104 -0
- package/projects/onemrva/design-system/mat-paginator/src/onemrva-mat-paginator.component.spec.ts +184 -0
- package/projects/onemrva/design-system/mat-paginator/src/onemrva-mat-paginator.component.ts +214 -0
- package/projects/onemrva/design-system/mat-paginator/src/onemrva-mat-paginator.module.ts +15 -0
- package/projects/onemrva/design-system/mat-panel/index.ts +6 -0
- package/projects/onemrva/design-system/mat-panel/ng-package.json +6 -0
- package/projects/onemrva/design-system/mat-panel/src/onemrva-mat-panel-content.component.ts +12 -0
- package/projects/onemrva/design-system/mat-panel/src/onemrva-mat-panel-content.html +5 -0
- package/projects/onemrva/design-system/mat-panel/src/onemrva-mat-panel-icon.component.ts +12 -0
- package/projects/onemrva/design-system/mat-panel/src/onemrva-mat-panel-icon.html +5 -0
- package/projects/onemrva/design-system/mat-panel/src/onemrva-mat-panel-title-action.component.ts +12 -0
- package/projects/onemrva/design-system/mat-panel/src/onemrva-mat-panel-title-action.html +5 -0
- package/projects/onemrva/design-system/mat-panel/src/onemrva-mat-panel-title.component.ts +20 -0
- package/projects/onemrva/design-system/mat-panel/src/onemrva-mat-panel-title.html +8 -0
- package/projects/onemrva/design-system/mat-panel/src/onemrva-mat-panel.component.html +10 -0
- package/projects/onemrva/design-system/mat-panel/src/onemrva-mat-panel.component.scss +100 -0
- package/projects/onemrva/design-system/mat-panel/src/onemrva-mat-panel.component.ts +122 -0
- package/projects/onemrva/design-system/mat-panel/src/onemrva-mat-panel.module.ts +26 -0
- package/projects/onemrva/design-system/mat-pop-over/index.ts +4 -0
- package/projects/onemrva/design-system/mat-pop-over/ng-package.json +6 -0
- package/projects/onemrva/design-system/mat-pop-over/src/onemrva-mat-pop-over-content.component.ts +13 -0
- package/projects/onemrva/design-system/mat-pop-over/src/onemrva-mat-pop-over-trigger.component.ts +13 -0
- package/projects/onemrva/design-system/mat-pop-over/src/onemrva-mat-pop-over.component.html +29 -0
- package/projects/onemrva/design-system/mat-pop-over/src/onemrva-mat-pop-over.component.scss +141 -0
- package/projects/onemrva/design-system/mat-pop-over/src/onemrva-mat-pop-over.component.ts +47 -0
- package/projects/onemrva/design-system/mat-pop-over/src/onemrva-mat-pop-over.module.ts +19 -0
- package/projects/onemrva/design-system/mat-progress-bar/index.ts +1 -0
- package/projects/onemrva/design-system/mat-progress-bar/ng-package.json +6 -0
- package/projects/onemrva/design-system/mat-progress-bar/src/_onemrva-mat-progress-bar-mixin.component.scss +37 -0
- package/projects/onemrva/design-system/mat-progress-bar/src/onemrva-mat-progress-bar.component.html +13 -0
- package/projects/onemrva/design-system/mat-progress-bar/src/onemrva-mat-progress-bar.component.ts +27 -0
- package/projects/onemrva/design-system/mat-select-search/index.ts +3 -0
- package/projects/onemrva/design-system/mat-select-search/ng-package.json +6 -0
- package/projects/onemrva/design-system/mat-select-search/src/default-options.ts +42 -0
- package/projects/onemrva/design-system/mat-select-search/src/mat-select-no-entries-found.directive.ts +15 -0
- package/projects/onemrva/design-system/mat-select-search/src/mat-select-search-clear.directive.ts +13 -0
- package/projects/onemrva/design-system/mat-select-search/src/mat-select-search.component.html +67 -0
- package/projects/onemrva/design-system/mat-select-search/src/mat-select-search.component.scss +126 -0
- package/projects/onemrva/design-system/mat-select-search/src/mat-select-search.component.spec.ts +790 -0
- package/projects/onemrva/design-system/mat-select-search/src/mat-select-search.component.ts +612 -0
- package/projects/onemrva/design-system/mat-select-search/src/mat-select-search.module.ts +53 -0
- package/projects/onemrva/design-system/mat-side-menu/index.ts +6 -0
- package/projects/onemrva/design-system/mat-side-menu/ng-package.json +6 -0
- package/projects/onemrva/design-system/mat-side-menu/src/onemrva-mat-side-menu.component.html +36 -0
- package/projects/onemrva/design-system/mat-side-menu/src/onemrva-mat-side-menu.component.scss +50 -0
- package/projects/onemrva/design-system/mat-side-menu/src/onemrva-mat-side-menu.component.spec.ts +66 -0
- package/projects/onemrva/design-system/mat-side-menu/src/onemrva-mat-side-menu.component.ts +46 -0
- package/projects/onemrva/design-system/mat-side-menu/src/onemrva-mat-side-menu.module.ts +14 -0
- package/projects/onemrva/design-system/mat-skeleton/index.ts +3 -0
- package/projects/onemrva/design-system/mat-skeleton/ng-package.json +6 -0
- package/projects/onemrva/design-system/mat-skeleton/src/onemrva-mat-skeleton-enums.ts +32 -0
- package/projects/onemrva/design-system/mat-skeleton/src/onemrva-mat-skeleton.component.html +17 -0
- package/projects/onemrva/design-system/mat-skeleton/src/onemrva-mat-skeleton.component.scss +216 -0
- package/projects/onemrva/design-system/mat-skeleton/src/onemrva-mat-skeleton.component.ts +173 -0
- package/projects/onemrva/design-system/mat-skeleton/src/onemrva-mat-skeleton.module.ts +16 -0
- package/projects/onemrva/design-system/mat-spinner/index.ts +6 -0
- package/projects/onemrva/design-system/mat-spinner/ng-package.json +6 -0
- package/projects/onemrva/design-system/mat-spinner/src/_onemrva-mat-spinner.component.scss +62 -0
- package/projects/onemrva/design-system/mat-spinner/src/onemrva-mat-spinner.component.ts +11 -0
- package/projects/onemrva/design-system/mat-spinner/src/onemrva-mat-spinner.module.ts +8 -0
- package/projects/onemrva/design-system/mat-stepper/index.ts +6 -0
- package/projects/onemrva/design-system/mat-stepper/ng-package.json +6 -0
- package/projects/onemrva/design-system/mat-stepper/src/_stepper-variables.scss +29 -0
- package/projects/onemrva/design-system/mat-stepper/src/onemrva-mat-stepper.component.spec.ts +23 -0
- package/projects/onemrva/design-system/mat-stepper/src/onemrva-mat-stepper.component.ts +60 -0
- package/projects/onemrva/design-system/mat-stepper/src/onemrva-mat-stepper.html +53 -0
- package/projects/onemrva/design-system/mat-stepper/src/onemrva-mat-stepper.module.ts +30 -0
- package/projects/onemrva/design-system/mat-stepper/src/onemrva-mat-stepper.scss +106 -0
- package/projects/onemrva/design-system/mat-stepper/src/onemrva-stepper-animations.ts +40 -0
- package/projects/onemrva/design-system/mat-table-of-content/index.ts +8 -0
- package/projects/onemrva/design-system/mat-table-of-content/ng-package.json +6 -0
- package/projects/onemrva/design-system/mat-table-of-content/src/_onemrva-mat-table-of-content.component.scss +79 -0
- package/projects/onemrva/design-system/mat-table-of-content/src/onemrva-mat-table-of-content.component.html +23 -0
- package/projects/onemrva/design-system/mat-table-of-content/src/onemrva-mat-table-of-content.component.ts +128 -0
- package/projects/onemrva/design-system/mat-table-of-content/src/onemrva-mat-table-of-content.directive.ts +67 -0
- package/projects/onemrva/design-system/mat-table-of-content/src/onemrva-mat-table-of-content.service.ts +51 -0
- package/projects/onemrva/design-system/mat-table-of-content/src/onemrva-mat-toc-anchor.model.ts +24 -0
- package/projects/onemrva/design-system/mat-task-list/index.ts +5 -0
- package/projects/onemrva/design-system/mat-task-list/ng-package.json +6 -0
- package/projects/onemrva/design-system/mat-task-list/src/onemrva-mat-task-content.component.ts +12 -0
- package/projects/onemrva/design-system/mat-task-list/src/onemrva-mat-task-content.html +5 -0
- package/projects/onemrva/design-system/mat-task-list/src/onemrva-mat-task-list.component.html +1 -0
- package/projects/onemrva/design-system/mat-task-list/src/onemrva-mat-task-list.component.scss +150 -0
- package/projects/onemrva/design-system/mat-task-list/src/onemrva-mat-task-list.component.ts +50 -0
- package/projects/onemrva/design-system/mat-task-list/src/onemrva-mat-task-list.module.ts +31 -0
- package/projects/onemrva/design-system/mat-task-list/src/onemrva-mat-task-title.component.ts +18 -0
- package/projects/onemrva/design-system/mat-task-list/src/onemrva-mat-task-title.html +5 -0
- package/projects/onemrva/design-system/mat-task-list/src/onemrva-mat-task.component.html +17 -0
- package/projects/onemrva/design-system/mat-task-list/src/onemrva-mat-task.component.scss +0 -0
- package/projects/onemrva/design-system/mat-task-list/src/onemrva-mat-task.component.ts +117 -0
- package/projects/onemrva/design-system/mat-timepicker/index.ts +6 -0
- package/projects/onemrva/design-system/mat-timepicker/ng-package.json +6 -0
- package/projects/onemrva/design-system/mat-timepicker/src/clock/clock.component.html +42 -0
- package/projects/onemrva/design-system/mat-timepicker/src/clock/clock.component.scss +129 -0
- package/projects/onemrva/design-system/mat-timepicker/src/clock/clock.component.spec.ts +25 -0
- package/projects/onemrva/design-system/mat-timepicker/src/clock/clock.component.ts +273 -0
- package/projects/onemrva/design-system/mat-timepicker/src/interfaces-and-types.ts +16 -0
- package/projects/onemrva/design-system/mat-timepicker/src/onemrva-mat-timepicker.component.html +0 -0
- package/projects/onemrva/design-system/mat-timepicker/src/onemrva-mat-timepicker.component.ts +289 -0
- package/projects/onemrva/design-system/mat-timepicker/src/onemrva-mat-timepicker.module.ts +40 -0
- package/projects/onemrva/design-system/mat-timepicker/src/timepicker-dialog/timepicker-dialog.component.html +53 -0
- package/projects/onemrva/design-system/mat-timepicker/src/timepicker-dialog/timepicker-dialog.component.scss +69 -0
- package/projects/onemrva/design-system/mat-timepicker/src/timepicker-dialog/timepicker-dialog.component.spec.ts +25 -0
- package/projects/onemrva/design-system/mat-timepicker/src/timepicker-dialog/timepicker-dialog.component.ts +169 -0
- package/projects/onemrva/design-system/mat-timepicker/src/timepicker-toggle/timepicker-toggle.component.html +15 -0
- package/projects/onemrva/design-system/mat-timepicker/src/timepicker-toggle/timepicker-toggle.component.scss +32 -0
- package/projects/onemrva/design-system/mat-timepicker/src/timepicker-toggle/timepicker-toggle.component.ts +135 -0
- package/projects/onemrva/design-system/mat-timepicker/src/timepicker.directive.ts +594 -0
- package/projects/onemrva/design-system/mat-timepicker/src/util.ts +97 -0
- package/projects/onemrva/design-system/mat-toast/index.ts +6 -0
- package/projects/onemrva/design-system/mat-toast/ng-package.json +6 -0
- package/projects/onemrva/design-system/mat-toast/src/onemrva-mat-toast.component.scss +54 -0
- package/projects/onemrva/design-system/mat-toast/src/onemrva-mat-toast.component.ts +36 -0
- package/projects/onemrva/design-system/mat-toast/src/onemrva-mat-toast.module.ts +11 -0
- package/projects/onemrva/design-system/mat-tooltip/index.ts +4 -0
- package/projects/onemrva/design-system/mat-tooltip/ng-package.json +6 -0
- package/projects/onemrva/design-system/mat-tooltip/src/onemrva-mat-tooltip.component.scss +9 -0
- package/projects/onemrva/design-system/mat-tooltip/src/onemrva-mat-tooltip.component.ts +21 -0
- package/projects/onemrva/design-system/mat-tooltip/src/onemrva-mat-tooltip.directive.ts +119 -0
- package/projects/onemrva/design-system/mat-tooltip/src/onemrva-mat-tooltip.module.ts +11 -0
- package/projects/onemrva/design-system/ng-package.json +20 -0
- package/projects/onemrva/design-system/package.json +27 -0
- package/projects/onemrva/design-system/page-not-found/assets/404/Arri/303/250re-plan.svg +22 -0
- package/projects/onemrva/design-system/page-not-found/assets/404/Halo.svg +10 -0
- package/projects/onemrva/design-system/page-not-found/assets/404/Ombre.svg +3 -0
- package/projects/onemrva/design-system/page-not-found/assets/404/Page.svg +21 -0
- package/projects/onemrva/design-system/page-not-found/assets/404/Page2.svg +19 -0
- package/projects/onemrva/design-system/page-not-found/assets/404/Soucoupe.svg +70 -0
- package/projects/onemrva/design-system/page-not-found/assets/404/Yeux.svg +6 -0
- package/projects/onemrva/design-system/page-not-found/assets/404/shape.svg +3 -0
- package/projects/onemrva/design-system/page-not-found/index.ts +5 -0
- package/projects/onemrva/design-system/page-not-found/ng-package.json +9 -0
- package/projects/onemrva/design-system/page-not-found/src/page-not-found-action.component.ts +9 -0
- package/projects/onemrva/design-system/page-not-found/src/page-not-found-extra.component.ts +9 -0
- package/projects/onemrva/design-system/page-not-found/src/page-not-found-invader.component.scss +16 -0
- package/projects/onemrva/design-system/page-not-found/src/page-not-found-invader.component.ts +84 -0
- package/projects/onemrva/design-system/page-not-found/src/page-not-found-mixin.component.scss +12 -0
- package/projects/onemrva/design-system/page-not-found/src/page-not-found.component.html +31 -0
- package/projects/onemrva/design-system/page-not-found/src/page-not-found.component.scss +206 -0
- package/projects/onemrva/design-system/page-not-found/src/page-not-found.component.ts +59 -0
- package/projects/onemrva/design-system/page-not-found/src/page-not-found.module.ts +24 -0
- package/projects/onemrva/design-system/src/public-api.ts +5 -0
- package/projects/onemrva/design-system/tsconfig.lib.json +12 -0
- package/projects/onemrva/design-system/tsconfig.lib.prod.json +10 -0
- package/projects/onemrva/design-system/utils/index.ts +2 -0
- package/projects/onemrva/design-system/utils/ng-package.json +6 -0
- package/projects/onemrva/design-system/utils/src/enum.utils.ts +6 -0
- package/projects/onemrva/design-system/utils/src/enums/color.enum.ts +14 -0
- package/projects/onemrva/design-system/utils/src/enums/index.ts +2 -0
- package/projects/onemrva/design-system/utils/src/enums/size.enum.ts +11 -0
- package/projects/schematics/README.md +40 -0
- package/projects/schematics/package.json +25 -0
- package/projects/schematics/src/cmp-demo/schema.json +15 -0
- package/projects/schematics/src/collection.json +17 -0
- package/projects/schematics/src/component/files/root/ng-package.json +6 -0
- package/projects/schematics/src/component/files/src/onemrva-mat-__name__.component.html +4 -0
- package/projects/schematics/src/component/schema.json +11 -0
- package/projects/schematics/src/demo/files/demo/demo-__name__.component.html +2 -0
- package/projects/schematics/src/demo/files/demo/readme.md +26 -0
- package/projects/schematics/src/demo/schema.json +15 -0
- package/projects/schematics/tsconfig.json +24 -0
- package/projects/test/.nycrc +5 -0
- package/projects/test/cypress/coverage.webpack.ts +20 -0
- package/projects/test/cypress/cucumber-json/basictest.cucumber.json +402 -0
- package/projects/test/cypress/fixtures/example.json +5 -0
- package/projects/test/cypress/integration/basictest.feature +53 -0
- package/projects/test/cypress/integration/common/basicTestSteps.ts +54 -0
- package/projects/test/cypress/plugins/index.ts +13 -0
- package/projects/test/cypress/support/commands.ts +44 -0
- package/projects/test/cypress/support/e2e.ts +20 -0
- package/projects/test/cypress/tsconfig.json +10 -0
- package/projects/test/cypress/videos/basictest.feature.mp4 +0 -0
- package/projects/test/karma.conf.js +44 -0
- package/projects/test/src/app/app-routing.module.ts +14 -0
- package/projects/test/src/app/app.component.html +14 -0
- package/projects/test/src/app/app.component.scss +0 -0
- package/projects/test/src/app/app.component.spec.ts +35 -0
- package/projects/test/src/app/app.component.ts +51 -0
- package/projects/test/src/app/app.module.ts +103 -0
- package/projects/test/src/app/demos/avatar/demo-avatar.component.html +77 -0
- package/projects/test/src/app/demos/avatar/demo-avatar.component.scss +4 -0
- package/projects/test/src/app/demos/avatar/demo-avatar.component.ts +13 -0
- package/projects/test/src/app/demos/badge/demo-badge.component.html +389 -0
- package/projects/test/src/app/demos/badge/demo-badge.component.scss +4 -0
- package/projects/test/src/app/demos/badge/demo-badge.component.ts +22 -0
- package/projects/test/src/app/demos/badge/readme.md +30 -0
- package/projects/test/src/app/demos/breadcrumb/demo-breadcrumb.component.html +20 -0
- package/projects/test/src/app/demos/breadcrumb/demo-breadcrumb.component.ts +7 -0
- package/projects/test/src/app/demos/breadcrumb/demo-breadcrumb.module.ts +89 -0
- package/projects/test/src/app/demos/breadcrumb/readme.md +29 -0
- package/projects/test/src/app/demos/datepicker/demo-datepicker.component.html +10 -0
- package/projects/test/src/app/demos/datepicker/demo-datepicker.component.scss +5 -0
- package/projects/test/src/app/demos/datepicker/demo-datepicker.component.ts +12 -0
- package/projects/test/src/app/demos/datepicker/demo-datepicker.module.ts +43 -0
- package/projects/test/src/app/demos/datepicker/readme.md +36 -0
- package/projects/test/src/app/demos/file-upload/demo-file-upload.component.html +30 -0
- package/projects/test/src/app/demos/file-upload/demo-file-upload.component.ts +132 -0
- package/projects/test/src/app/demos/file-upload/demo-file-upload.service.ts +60 -0
- package/projects/test/src/app/demos/file-upload/readme.md +26 -0
- package/projects/test/src/app/demos/input-bank-account/demo-input-bank-account.component.ts +19 -0
- package/projects/test/src/app/demos/input-bank-account/demo-input-bank-account.module.ts +20 -0
- package/projects/test/src/app/demos/input-country/demo-input-country.component.html +9 -0
- package/projects/test/src/app/demos/input-country/demo-input-country.component.ts +14 -0
- package/projects/test/src/app/demos/input-country/demo-input-country.module.ts +26 -0
- package/projects/test/src/app/demos/input-enterprise-number/demo-input-enterprise-number.component.ts +13 -0
- package/projects/test/src/app/demos/input-enterprise-number/demo-input-enterprise-number.module.ts +20 -0
- package/projects/test/src/app/demos/input-phone/demo-input-phone.component.html +16 -0
- package/projects/test/src/app/demos/input-phone/demo-input-phone.component.ts +16 -0
- package/projects/test/src/app/demos/input-phone/demo-input-phone.module.ts +21 -0
- package/projects/test/src/app/demos/message-box/demo-message-box.component.html +32 -0
- package/projects/test/src/app/demos/message-box/demo-message-box.component.ts +12 -0
- package/projects/test/src/app/demos/message-box/readme.md +26 -0
- package/projects/test/src/app/demos/multiselect/demo-multiselect.component.html +53 -0
- package/projects/test/src/app/demos/multiselect/demo-multiselect.component.scss +23 -0
- package/projects/test/src/app/demos/multiselect/demo-multiselect.component.ts +53 -0
- package/projects/test/src/app/demos/multiselect/demo-multiselect.module.ts +38 -0
- package/projects/test/src/app/demos/multiselect/readme.md +34 -0
- package/projects/test/src/app/demos/not-found/demo-not-found.component.html +21 -0
- package/projects/test/src/app/demos/not-found/demo-not-found.component.scss +6 -0
- package/projects/test/src/app/demos/not-found/demo-not-found.component.ts +50 -0
- package/projects/test/src/app/demos/not-found/readme.md +44 -0
- package/projects/test/src/app/demos/notification/demo-notification.component.html +5 -0
- package/projects/test/src/app/demos/notification/demo-notification.component.ts +10 -0
- package/projects/test/src/app/demos/paginator/demo-paginator.component.html +35 -0
- package/projects/test/src/app/demos/paginator/demo-paginator.component.ts +25 -0
- package/projects/test/src/app/demos/paginator/readme.md +89 -0
- package/projects/test/src/app/demos/panel/demo-panel.component.html +53 -0
- package/projects/test/src/app/demos/panel/demo-panel.component.scss +3 -0
- package/projects/test/src/app/demos/panel/demo-panel.component.ts +20 -0
- package/projects/test/src/app/demos/panel/readme.md +26 -0
- package/projects/test/src/app/demos/pop-over/demo-pop-over.component.html +130 -0
- package/projects/test/src/app/demos/pop-over/demo-pop-over.component.scss +9 -0
- package/projects/test/src/app/demos/pop-over/demo-pop-over.component.ts +13 -0
- package/projects/test/src/app/demos/pop-over/readme.md +26 -0
- package/projects/test/src/app/demos/progress-bar/demo-progress-bar.component.html +19 -0
- package/projects/test/src/app/demos/progress-bar/demo-progress-bar.component.ts +35 -0
- package/projects/test/src/app/demos/side-menu/demo-side-menu.component.html +5 -0
- package/projects/test/src/app/demos/side-menu/demo-side-menu.component.ts +34 -0
- package/projects/test/src/app/demos/side-menu/readme.md +30 -0
- package/projects/test/src/app/demos/skeleton/demo-skeleton.component.html +119 -0
- package/projects/test/src/app/demos/skeleton/demo-skeleton.component.scss +0 -0
- package/projects/test/src/app/demos/skeleton/demo-skeleton.component.ts +35 -0
- package/projects/test/src/app/demos/spinner/demo-spinner.component.html +1 -0
- package/projects/test/src/app/demos/spinner/demo-spinner.component.ts +10 -0
- package/projects/test/src/app/demos/spinner/readme.md +24 -0
- package/projects/test/src/app/demos/summary-stepper/demo-summary-stepper.component.html +108 -0
- package/projects/test/src/app/demos/summary-stepper/demo-summary-stepper.component.scss +3 -0
- package/projects/test/src/app/demos/summary-stepper/demo-summary-stepper.component.ts +55 -0
- package/projects/test/src/app/demos/summary-stepper/readme.md +26 -0
- package/projects/test/src/app/demos/table/demo-table-datasource.ts +140 -0
- package/projects/test/src/app/demos/table/demo-table.component.html +41 -0
- package/projects/test/src/app/demos/table/demo-table.component.scss +17 -0
- package/projects/test/src/app/demos/table/demo-table.component.ts +51 -0
- package/projects/test/src/app/demos/table/demo-table.module.ts +45 -0
- package/projects/test/src/app/demos/table/readme.md +27 -0
- package/projects/test/src/app/demos/task-list/demo-task-list.component.html +37 -0
- package/projects/test/src/app/demos/task-list/demo-task-list.component.scss +3 -0
- package/projects/test/src/app/demos/task-list/demo-task-list.component.ts +14 -0
- package/projects/test/src/app/demos/task-list/demo-task-list.module.ts +29 -0
- package/projects/test/src/app/demos/task-list/readme.md +26 -0
- package/projects/test/src/app/demos/timepicker/demo-timepicker.component.html +9 -0
- package/projects/test/src/app/demos/timepicker/demo-timepicker.component.ts +31 -0
- package/projects/test/src/app/demos/timepicker/readme.md +26 -0
- package/projects/test/src/app/demos/toast/demo-toast.component.html +8 -0
- package/projects/test/src/app/demos/toast/demo-toast.component.scss +3 -0
- package/projects/test/src/app/demos/toast/demo-toast.component.ts +61 -0
- package/projects/test/src/app/demos/toast/readme.md +30 -0
- package/projects/test/src/app/demos/toc/demo-toc.component.html +288 -0
- package/projects/test/src/app/demos/toc/demo-toc.component.ts +26 -0
- package/projects/test/src/app/demos/tooltip/demo-tooltip.component.html +73 -0
- package/projects/test/src/app/demos/tooltip/demo-tooltip.component.scss +11 -0
- package/projects/test/src/app/demos/tooltip/demo-tooltip.component.ts +14 -0
- package/projects/test/src/app/home.component.ts +54 -0
- package/projects/test/src/app/material.module.ts +39 -0
- package/projects/test/src/app/onemrva-translate-http-loader.ts +35 -0
- package/projects/test/src/app/routes.ts +198 -0
- package/projects/test/src/assets/.gitkeep +0 -0
- package/projects/test/src/assets/i18n/de.json +80 -0
- package/projects/test/src/assets/i18n/en.json +80 -0
- package/projects/test/src/assets/i18n/fr.json +80 -0
- package/projects/test/src/assets/i18n/nl.json +79 -0
- package/projects/test/src/environments/environment.e2e.ts +3 -0
- package/projects/test/src/environments/environment.prod.ts +3 -0
- package/projects/test/src/environments/environment.ts +16 -0
- package/projects/test/src/favicon.ico +0 -0
- package/projects/test/src/index.html +15 -0
- package/projects/test/src/main.ts +12 -0
- package/projects/test/src/polyfills.ts +53 -0
- package/projects/test/src/styles.scss +22 -0
- package/projects/test/src/test.ts +26 -0
- package/projects/test/tsconfig.app.json +15 -0
- package/projects/test/tsconfig.spec.json +18 -0
- package/rva.crt +36 -0
- package/tsconfig.json +44 -0
|
@@ -0,0 +1,128 @@
|
|
|
1
|
+
import {
|
|
2
|
+
Component,
|
|
3
|
+
HostBinding,
|
|
4
|
+
HostListener,
|
|
5
|
+
Input,
|
|
6
|
+
OnDestroy,
|
|
7
|
+
OnInit,
|
|
8
|
+
} from '@angular/core';
|
|
9
|
+
import { MatListModule } from '@angular/material/list';
|
|
10
|
+
import { TranslateModule, TranslateService } from '@ngx-translate/core';
|
|
11
|
+
import { OnemrvaMatTableOfContentService } from './onemrva-mat-table-of-content.service';
|
|
12
|
+
import { Observable, map, tap } from 'rxjs';
|
|
13
|
+
import {
|
|
14
|
+
OnemrvaMatTocAnchor,
|
|
15
|
+
OnemrvaMatTocAnchorLevel,
|
|
16
|
+
OnemrvaMatTocAnchorStatus,
|
|
17
|
+
} from './onemrva-mat-toc-anchor.model';
|
|
18
|
+
import { CommonModule } from '@angular/common';
|
|
19
|
+
import { MatIconModule } from '@angular/material/icon';
|
|
20
|
+
|
|
21
|
+
@Component({
|
|
22
|
+
selector: 'onemrva-mat-table-of-content',
|
|
23
|
+
templateUrl: 'onemrva-mat-table-of-content.component.html',
|
|
24
|
+
standalone: true,
|
|
25
|
+
imports: [MatListModule, TranslateModule, CommonModule, MatIconModule],
|
|
26
|
+
})
|
|
27
|
+
export class OnemrvaMatTableOfContentComponent implements OnInit, OnDestroy {
|
|
28
|
+
@Input()
|
|
29
|
+
titleKey!: string;
|
|
30
|
+
|
|
31
|
+
@Input()
|
|
32
|
+
tocName!: string;
|
|
33
|
+
|
|
34
|
+
@HostBinding('attr.data-cy')
|
|
35
|
+
@Input()
|
|
36
|
+
dataCy: string = 'onemrva-mat-toc';
|
|
37
|
+
|
|
38
|
+
// @HostBinding('attr.aria-label')
|
|
39
|
+
// @Input()
|
|
40
|
+
// get ariaLabel() {
|
|
41
|
+
// if (!this.titleKey) return null;
|
|
42
|
+
// return this.translate.instant(this.titleKey);
|
|
43
|
+
// }
|
|
44
|
+
|
|
45
|
+
@Input()
|
|
46
|
+
tableOfContentName!: string;
|
|
47
|
+
|
|
48
|
+
@Input()
|
|
49
|
+
scrollShift: number = 0;
|
|
50
|
+
|
|
51
|
+
toc$!: Observable<OnemrvaMatTocAnchor[]>;
|
|
52
|
+
|
|
53
|
+
activePath: string = '';
|
|
54
|
+
timerId: any;
|
|
55
|
+
|
|
56
|
+
@HostListener('window:scroll', ['$event']) onScrollEvent($event: any) {
|
|
57
|
+
this.throttledUpdateActivePath($event);
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
@HostListener('window:resize', ['$event']) onResizeEvent($event: any) {
|
|
61
|
+
this.throttledUpdateActivePath($event);
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
level = OnemrvaMatTocAnchorLevel;
|
|
65
|
+
status = OnemrvaMatTocAnchorStatus;
|
|
66
|
+
|
|
67
|
+
constructor(private tocService: OnemrvaMatTableOfContentService) {}
|
|
68
|
+
|
|
69
|
+
ngOnInit(): void {
|
|
70
|
+
this.toc$ = this.tocService.toc$.pipe(
|
|
71
|
+
map((tocMap) => tocMap[this.tocName].filter((entry) => !entry.hidden)),
|
|
72
|
+
tap((toc) => {
|
|
73
|
+
if (!toc) this.titleKey = 'tocName.notFound';
|
|
74
|
+
else this.activePath = toc[0].path;
|
|
75
|
+
})
|
|
76
|
+
);
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
ngOnDestroy(): void {
|
|
80
|
+
this.tocService.resetToc();
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
goTo(anchor: OnemrvaMatTocAnchor) {
|
|
84
|
+
let e = document.querySelector("[href='" + anchor.path + "']")!;
|
|
85
|
+
let y = e.getBoundingClientRect().y;
|
|
86
|
+
|
|
87
|
+
window.scroll({
|
|
88
|
+
top: window.scrollY + y - this.scrollShift,
|
|
89
|
+
behavior: 'smooth',
|
|
90
|
+
});
|
|
91
|
+
|
|
92
|
+
// this.activePath = anchor.path;
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
throttledUpdateActivePath($event: any) {
|
|
96
|
+
if (this.timerId) return;
|
|
97
|
+
|
|
98
|
+
this.timerId = setTimeout(() => {
|
|
99
|
+
this.updateActivePath($event);
|
|
100
|
+
this.timerId = undefined;
|
|
101
|
+
}, 200);
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
updateActivePath(e: any) {
|
|
105
|
+
const scrollPosition = window.scrollY;
|
|
106
|
+
|
|
107
|
+
let prevElement: { href: string; top: number } = { href: '', top: 0 };
|
|
108
|
+
|
|
109
|
+
const anchors = document.querySelectorAll('.onemrva-mat-toc-anchor');
|
|
110
|
+
for (let i = 0; i < anchors.length; i++) {
|
|
111
|
+
let anchor = anchors[i];
|
|
112
|
+
let top = anchor.getBoundingClientRect().top - this.scrollShift;
|
|
113
|
+
let href: string = anchor.getAttribute('href')!;
|
|
114
|
+
|
|
115
|
+
if (top >= 0) {
|
|
116
|
+
if (prevElement.top < 0) {
|
|
117
|
+
this.activePath =
|
|
118
|
+
(top + prevElement.top) / 2 > 0 ? prevElement.href : href;
|
|
119
|
+
} else {
|
|
120
|
+
this.activePath = anchor.getAttribute('href')!;
|
|
121
|
+
}
|
|
122
|
+
return;
|
|
123
|
+
} else {
|
|
124
|
+
prevElement = { top, href };
|
|
125
|
+
}
|
|
126
|
+
}
|
|
127
|
+
}
|
|
128
|
+
}
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
import {
|
|
2
|
+
OnInit,
|
|
3
|
+
Directive,
|
|
4
|
+
Input,
|
|
5
|
+
HostBinding,
|
|
6
|
+
AfterViewInit,
|
|
7
|
+
ChangeDetectorRef,
|
|
8
|
+
} from '@angular/core';
|
|
9
|
+
import { OnemrvaMatTableOfContentService } from './onemrva-mat-table-of-content.service';
|
|
10
|
+
import { OnemrvaMatTocAnchor } from './onemrva-mat-toc-anchor.model';
|
|
11
|
+
import { TranslateService } from '@ngx-translate/core';
|
|
12
|
+
|
|
13
|
+
/**
|
|
14
|
+
* For accessibility purpose, aria-label and will be displayed
|
|
15
|
+
*/
|
|
16
|
+
|
|
17
|
+
@Directive({
|
|
18
|
+
selector: '[onemrvaMatToc]',
|
|
19
|
+
standalone: true,
|
|
20
|
+
})
|
|
21
|
+
export class OnemrvaMatTableOfContentDirective
|
|
22
|
+
implements OnInit, AfterViewInit
|
|
23
|
+
{
|
|
24
|
+
@Input()
|
|
25
|
+
onemrvaMatToc!: OnemrvaMatTocAnchor;
|
|
26
|
+
|
|
27
|
+
@HostBinding('attr.role')
|
|
28
|
+
role: string = 'link';
|
|
29
|
+
|
|
30
|
+
@HostBinding('attr.class')
|
|
31
|
+
clazz: string = 'onemrva-mat-toc-anchor';
|
|
32
|
+
|
|
33
|
+
@HostBinding('attr.aria-label')
|
|
34
|
+
get ariaLabel() {
|
|
35
|
+
return this.translateService.instant(this.onemrvaMatToc?.titleKey);
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
@Input()
|
|
39
|
+
hiddenInToc = false;
|
|
40
|
+
|
|
41
|
+
@HostBinding('attr.href')
|
|
42
|
+
get href() {
|
|
43
|
+
if (
|
|
44
|
+
this.onemrvaMatToc &&
|
|
45
|
+
this.onemrvaMatToc.path &&
|
|
46
|
+
this.onemrvaMatToc.path[0] !== '#'
|
|
47
|
+
)
|
|
48
|
+
return '#' + this.onemrvaMatToc?.path;
|
|
49
|
+
return this.onemrvaMatToc?.path;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
constructor(
|
|
53
|
+
private tocService: OnemrvaMatTableOfContentService,
|
|
54
|
+
private cd: ChangeDetectorRef,
|
|
55
|
+
private translateService: TranslateService
|
|
56
|
+
) {}
|
|
57
|
+
|
|
58
|
+
ngOnInit(): void {
|
|
59
|
+
this.tocService.addAnchor({ ...this.onemrvaMatToc, directive: this });
|
|
60
|
+
|
|
61
|
+
// console.log(' HWK this.hidden', this.hidden);
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
ngAfterViewInit(): void {
|
|
65
|
+
this.cd.detectChanges();
|
|
66
|
+
}
|
|
67
|
+
}
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import { Injectable } from '@angular/core';
|
|
2
|
+
import { BehaviorSubject, Observable } from 'rxjs';
|
|
3
|
+
import {
|
|
4
|
+
OnemrvaMatTocAnchor,
|
|
5
|
+
OnemrvaMatToc,
|
|
6
|
+
OnemrvaMatTocAnchorLevel,
|
|
7
|
+
} from './onemrva-mat-toc-anchor.model';
|
|
8
|
+
|
|
9
|
+
@Injectable()
|
|
10
|
+
export class OnemrvaMatTableOfContentService {
|
|
11
|
+
private _toc: OnemrvaMatToc = {};
|
|
12
|
+
private _toc$: BehaviorSubject<OnemrvaMatToc> = new BehaviorSubject({});
|
|
13
|
+
toc$: Observable<OnemrvaMatToc> = this._toc$.asObservable();
|
|
14
|
+
|
|
15
|
+
addAnchor(anchor: OnemrvaMatTocAnchor) {
|
|
16
|
+
if (!anchor.level) {
|
|
17
|
+
anchor.level = OnemrvaMatTocAnchorLevel.SECTION;
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
if (!this._toc[anchor.tocName])
|
|
21
|
+
this._toc = { ...this._toc, [anchor.tocName]: [anchor] };
|
|
22
|
+
else if (
|
|
23
|
+
this._toc[anchor.tocName].findIndex((a) => anchor.path === a.path) < 0
|
|
24
|
+
) {
|
|
25
|
+
let idx = -1;
|
|
26
|
+
if (anchor.order) {
|
|
27
|
+
idx = this._toc[anchor.tocName].findIndex(
|
|
28
|
+
(a) => a.order && anchor.order! < a.order
|
|
29
|
+
);
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
const newToc = [...this._toc[anchor.tocName]];
|
|
33
|
+
if (idx >= 0) {
|
|
34
|
+
newToc.splice(idx, 0, anchor);
|
|
35
|
+
} else {
|
|
36
|
+
newToc.push(anchor);
|
|
37
|
+
}
|
|
38
|
+
this._toc = {
|
|
39
|
+
...this._toc,
|
|
40
|
+
[anchor.tocName]: newToc,
|
|
41
|
+
};
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
this._toc$.next(this._toc);
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
resetToc() {
|
|
48
|
+
this._toc = {};
|
|
49
|
+
this._toc$.next(this._toc);
|
|
50
|
+
}
|
|
51
|
+
}
|
package/projects/onemrva/design-system/mat-table-of-content/src/onemrva-mat-toc-anchor.model.ts
ADDED
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
export enum OnemrvaMatTocAnchorStatus {
|
|
2
|
+
CHECKMARK,
|
|
3
|
+
WARNING,
|
|
4
|
+
}
|
|
5
|
+
|
|
6
|
+
export enum OnemrvaMatTocAnchorLevel {
|
|
7
|
+
SECTION,
|
|
8
|
+
SUBSECTION,
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
export interface OnemrvaMatTocAnchor {
|
|
12
|
+
tocName: string;
|
|
13
|
+
titleKey: string;
|
|
14
|
+
path: string;
|
|
15
|
+
order?: number; // You can manually set the order of your links
|
|
16
|
+
status?: OnemrvaMatTocAnchorStatus; // checkmarck add a checkmark icon at the end of the line. Warning adds an exclamation mark
|
|
17
|
+
level?: OnemrvaMatTocAnchorLevel; // Section level by default
|
|
18
|
+
hidden?: boolean;
|
|
19
|
+
directive?: any;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
export interface OnemrvaMatToc {
|
|
23
|
+
[tocName: string]: OnemrvaMatTocAnchor[];
|
|
24
|
+
}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export * from './src/onemrva-mat-task-list.module';
|
|
2
|
+
export * from './src/onemrva-mat-task-list.component';
|
|
3
|
+
export * from './src/onemrva-mat-task-title.component';
|
|
4
|
+
export * from './src/onemrva-mat-task-content.component';
|
|
5
|
+
export * from './src/onemrva-mat-task.component';
|
package/projects/onemrva/design-system/mat-task-list/src/onemrva-mat-task-content.component.ts
ADDED
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import {Component, Input, TemplateRef, ViewChild} from "@angular/core";
|
|
2
|
+
|
|
3
|
+
@Component({
|
|
4
|
+
selector: 'onemrva-mat-task-content',
|
|
5
|
+
templateUrl: './onemrva-mat-task-content.html',
|
|
6
|
+
})
|
|
7
|
+
export class OnemrvaMatTaskContentComponent {
|
|
8
|
+
@Input() customNgClass: any;
|
|
9
|
+
|
|
10
|
+
@ViewChild(TemplateRef) template?: TemplateRef<any>;
|
|
11
|
+
|
|
12
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
<ng-content></ng-content>
|
|
@@ -0,0 +1,150 @@
|
|
|
1
|
+
@use '../../utils' as utils;
|
|
2
|
+
|
|
3
|
+
@mixin taskList($theme) {
|
|
4
|
+
|
|
5
|
+
$panel-border-radius: 16px;
|
|
6
|
+
$panel-margin: 16px;
|
|
7
|
+
$panel-border-color: utils.palette($theme, 'primary', 50);
|
|
8
|
+
$panel-padding: 24px;
|
|
9
|
+
|
|
10
|
+
// Get the primary color palette from the color-config.
|
|
11
|
+
$primary: utils.palette($theme, 'primary');
|
|
12
|
+
onemrva-mat-task {
|
|
13
|
+
border-radius: $panel-border-radius;
|
|
14
|
+
border: 1px solid $panel-border-color;
|
|
15
|
+
padding: $panel-padding;
|
|
16
|
+
display: block;
|
|
17
|
+
position: relative;
|
|
18
|
+
margin-bottom: $panel-margin;
|
|
19
|
+
|
|
20
|
+
.onemrva-mat-task-content,
|
|
21
|
+
.onemrva-mat-task-title {
|
|
22
|
+
margin-left: 80px;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
.onemrva-mat-task-content {
|
|
26
|
+
margin-top: 16px;
|
|
27
|
+
|
|
28
|
+
p:last-child {
|
|
29
|
+
margin: 0;
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
.onemrva-mat-task-title {
|
|
34
|
+
font-family: 'Poppins', sans-serif;
|
|
35
|
+
font-style: normal;
|
|
36
|
+
font-weight: 700;
|
|
37
|
+
font-size: 20px;
|
|
38
|
+
line-height: 35px;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
.onemrva-mat-task-icon {
|
|
42
|
+
float: left;
|
|
43
|
+
position: absolute;
|
|
44
|
+
top: 50%;
|
|
45
|
+
-ms-transform: translateY(-50%);
|
|
46
|
+
transform: translateY(-50%);
|
|
47
|
+
width: 50px;
|
|
48
|
+
text-align: center;
|
|
49
|
+
|
|
50
|
+
.mat-checkbox .mat-checkbox-ripple {
|
|
51
|
+
left: calc(50% - 10px);
|
|
52
|
+
top: calc(50% - 10px);
|
|
53
|
+
height: 20px;
|
|
54
|
+
width: 20px;
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
span.bubble {
|
|
58
|
+
display: block;
|
|
59
|
+
text-align: center;
|
|
60
|
+
color: utils.palette($theme, 'primary', '500-contrast');
|
|
61
|
+
font-size: 24px;
|
|
62
|
+
width: 40px;
|
|
63
|
+
height: 40px;
|
|
64
|
+
line-height: 40px;
|
|
65
|
+
border: 2px solid utils.palette($theme, 'primary', '500-contrast');
|
|
66
|
+
background: $primary;
|
|
67
|
+
border-radius: 50%;
|
|
68
|
+
outline: 1px solid $primary;
|
|
69
|
+
|
|
70
|
+
mat-icon {
|
|
71
|
+
font-size: 24px;
|
|
72
|
+
margin-top: 8px;
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
&.mat-primary {
|
|
78
|
+
@include taskStyle($theme, 'primary');
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
&.mat-accent {
|
|
82
|
+
@include taskStyle($theme, 'accent');
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
&.mat-warn {
|
|
86
|
+
@include taskStyle($theme, 'warn');
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
&.mat-grayscale {
|
|
90
|
+
@include taskStyle($theme, 'grayscale');
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
&.mat-info {
|
|
94
|
+
@include taskStyle($theme, 'info');
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
&.mat-success {
|
|
98
|
+
@include taskStyle($theme, 'success');
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
&.mat-error {
|
|
102
|
+
@include taskStyle($theme, 'error');
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
|
|
106
|
+
&.mat-disabled {
|
|
107
|
+
.onemrva-mat-task-icon {
|
|
108
|
+
mat-icon {
|
|
109
|
+
color: utils.palette($theme, 'grayscale', '400-contrast');
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
span {
|
|
113
|
+
mat-icon {
|
|
114
|
+
color: utils.palette($theme, 'grayscale', '500-contrast');
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
color: utils.palette($theme, 'grayscale', '500-contrast');
|
|
118
|
+
background: utils.palette($theme, 'grayscale', 400);
|
|
119
|
+
outline: 1px solid utils.palette($theme, 'grayscale', 400);
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
.onemrva-mat-task-title, .onemrva-mat-task-content {
|
|
123
|
+
color: utils.palette($theme, 'grayscale', 400);
|
|
124
|
+
}
|
|
125
|
+
}
|
|
126
|
+
}
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
@mixin taskStyle($theme, $color, $weight: 500) {
|
|
130
|
+
border: none;
|
|
131
|
+
background: utils.palette($theme, $color, 50);
|
|
132
|
+
|
|
133
|
+
.onemrva-mat-task-title {
|
|
134
|
+
color: utils.palette($theme, $color, $weight);
|
|
135
|
+
}
|
|
136
|
+
.onemrva-mat-task-icon {
|
|
137
|
+
mat-icon {
|
|
138
|
+
color: utils.palette($theme, $color, $weight);
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
span {
|
|
142
|
+
mat-icon {
|
|
143
|
+
color: utils.palette($theme, $color, '500-contrast');
|
|
144
|
+
}
|
|
145
|
+
color: utils.palette($theme, $color, '500-contrast');
|
|
146
|
+
background: utils.palette($theme, $color, $weight);
|
|
147
|
+
outline: 1px solid utils.palette($theme, $color, $weight);
|
|
148
|
+
}
|
|
149
|
+
}
|
|
150
|
+
}
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import {
|
|
2
|
+
AfterContentInit,
|
|
3
|
+
AfterViewInit,
|
|
4
|
+
ChangeDetectionStrategy,
|
|
5
|
+
ChangeDetectorRef,
|
|
6
|
+
Component,
|
|
7
|
+
ContentChild,
|
|
8
|
+
ContentChildren,
|
|
9
|
+
HostBinding,
|
|
10
|
+
Input,
|
|
11
|
+
QueryList,
|
|
12
|
+
} from '@angular/core';
|
|
13
|
+
import { OnemrvaMatColor } from '@onemrvapublic/design-system/utils';
|
|
14
|
+
import { OnemrvaMatTaskComponent } from './onemrva-mat-task.component';
|
|
15
|
+
|
|
16
|
+
let NEXT_ID = 0;
|
|
17
|
+
|
|
18
|
+
@Component({
|
|
19
|
+
selector: 'onemrva-mat-task-list',
|
|
20
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
21
|
+
templateUrl: './onemrva-mat-task-list.component.html',
|
|
22
|
+
})
|
|
23
|
+
export class OnemrvaMatTaskListComponent
|
|
24
|
+
implements AfterViewInit, AfterContentInit
|
|
25
|
+
{
|
|
26
|
+
@HostBinding('attr.id')
|
|
27
|
+
@Input()
|
|
28
|
+
public id = `onemrva-mat-task-list-${NEXT_ID++}`;
|
|
29
|
+
|
|
30
|
+
@HostBinding('attr.data-cy')
|
|
31
|
+
@Input()
|
|
32
|
+
data_cy: string = 'onemrva-mat-task-list';
|
|
33
|
+
|
|
34
|
+
@ContentChildren(OnemrvaMatTaskComponent, {
|
|
35
|
+
descendants: true,
|
|
36
|
+
})
|
|
37
|
+
_tasks?: QueryList<OnemrvaMatTaskComponent>;
|
|
38
|
+
|
|
39
|
+
constructor(private cd: ChangeDetectorRef) {}
|
|
40
|
+
|
|
41
|
+
ngAfterViewInit() {
|
|
42
|
+
this.cd.detectChanges();
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
ngAfterContentInit(): void {
|
|
46
|
+
// this.tasks?.forEach((task) => {
|
|
47
|
+
// // task.
|
|
48
|
+
// });
|
|
49
|
+
}
|
|
50
|
+
}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { NgModule } from '@angular/core';
|
|
2
|
+
import { OnemrvaMatTaskListComponent } from './onemrva-mat-task-list.component';
|
|
3
|
+
import { OnemrvaMatTaskTitleComponent } from './onemrva-mat-task-title.component';
|
|
4
|
+
import { OnemrvaMatTaskContentComponent } from './onemrva-mat-task-content.component';
|
|
5
|
+
import { CommonModule } from '@angular/common';
|
|
6
|
+
import { OnemrvaMatTaskComponent } from './onemrva-mat-task.component';
|
|
7
|
+
import {MatIconModule} from "@angular/material/icon";
|
|
8
|
+
import {MatCheckboxModule} from "@angular/material/checkbox";
|
|
9
|
+
import {ReactiveFormsModule} from "@angular/forms";
|
|
10
|
+
|
|
11
|
+
@NgModule({
|
|
12
|
+
declarations: [
|
|
13
|
+
OnemrvaMatTaskListComponent,
|
|
14
|
+
OnemrvaMatTaskTitleComponent,
|
|
15
|
+
OnemrvaMatTaskContentComponent,
|
|
16
|
+
OnemrvaMatTaskComponent,
|
|
17
|
+
],
|
|
18
|
+
imports: [
|
|
19
|
+
CommonModule,
|
|
20
|
+
MatIconModule,
|
|
21
|
+
MatCheckboxModule,
|
|
22
|
+
ReactiveFormsModule
|
|
23
|
+
],
|
|
24
|
+
exports: [
|
|
25
|
+
OnemrvaMatTaskListComponent,
|
|
26
|
+
OnemrvaMatTaskTitleComponent,
|
|
27
|
+
OnemrvaMatTaskContentComponent,
|
|
28
|
+
OnemrvaMatTaskComponent,
|
|
29
|
+
],
|
|
30
|
+
})
|
|
31
|
+
export class OnemrvaMatTaskListModule {}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import {AfterViewInit, ChangeDetectorRef, Component, ContentChild, Input, TemplateRef, ViewChild} from "@angular/core";
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
@Component({
|
|
5
|
+
selector: 'onemrva-mat-task-title',
|
|
6
|
+
templateUrl: './onemrva-mat-task-title.html',
|
|
7
|
+
})
|
|
8
|
+
export class OnemrvaMatTaskTitleComponent implements AfterViewInit{
|
|
9
|
+
@Input() customNgClass: any;
|
|
10
|
+
|
|
11
|
+
@ViewChild(TemplateRef) template?: TemplateRef<any>;
|
|
12
|
+
|
|
13
|
+
constructor(private cd: ChangeDetectorRef) {}
|
|
14
|
+
|
|
15
|
+
ngAfterViewInit() {
|
|
16
|
+
this.cd.detectChanges();
|
|
17
|
+
}
|
|
18
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
<div class="onemrva-mat-task-icon">
|
|
2
|
+
<ng-container *ngIf="icon !== undefined">
|
|
3
|
+
<span class="bubble"><mat-icon >{{ icon }}</mat-icon></span>
|
|
4
|
+
</ng-container>
|
|
5
|
+
<ng-container *ngIf="form !== undefined">
|
|
6
|
+
<mat-checkbox [disabled]="true" [formControl]="form" [aria-label]="arialLabel"></mat-checkbox>
|
|
7
|
+
</ng-container>
|
|
8
|
+
<ng-container *ngIf="bubble !== undefined">
|
|
9
|
+
<span class="bubble">{{ bubble }}</span>
|
|
10
|
+
</ng-container>
|
|
11
|
+
</div>
|
|
12
|
+
<ng-container *ngIf="title?.template as tpl">
|
|
13
|
+
<ng-container *ngTemplateOutlet="tpl"></ng-container>
|
|
14
|
+
</ng-container>
|
|
15
|
+
<ng-container *ngIf="content?.template as tpl">
|
|
16
|
+
<ng-container *ngTemplateOutlet="tpl"></ng-container>
|
|
17
|
+
</ng-container>
|
|
File without changes
|