@sumaris-net/ngx-components 18.2.31 → 18.2.32

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.
Files changed (37) hide show
  1. package/doc/changelog.md +1031 -1028
  2. package/esm2022/src/app/core/form/entity/entity-editor.class.mjs +1 -1
  3. package/esm2022/src/app/core/install/install-upgrade-card.component.mjs +1 -1
  4. package/esm2022/src/app/core/peer/select-peer.modal.mjs +3 -3
  5. package/esm2022/src/app/core/peer/select-peer.module.mjs +1 -1
  6. package/esm2022/src/app/core/services/config/core.config.mjs +1 -1
  7. package/esm2022/src/app/core/services/model/node-feature.model.mjs +1 -1
  8. package/esm2022/src/app/core/services/model/peer.model.mjs +1 -1
  9. package/esm2022/src/app/core/services/network.service.mjs +1 -1
  10. package/esm2022/src/app/core/services/network.utils.mjs +1 -1
  11. package/esm2022/src/app/core/services/storage/entity-store.class.mjs +1 -1
  12. package/esm2022/src/app/core/table/testing/table.testing.mjs +3 -3
  13. package/esm2022/src/app/shared/forms.mjs +1 -1
  14. package/esm2022/src/app/shared/inputs.mjs +1 -1
  15. package/esm2022/src/app/shared/material/boolean/material.boolean.mjs +3 -3
  16. package/esm2022/src/app/shared/material/boolean/testing/boolean.test.page.mjs +3 -3
  17. package/esm2022/src/app/shared/material/latlong/latlong.utils.mjs +1 -1
  18. package/esm2022/src/app/shared/material/latlong/material.latlong.mjs +5 -3
  19. package/esm2022/src/app/shared/material/latlong/material.latlong.module.mjs +1 -1
  20. package/esm2022/src/app/shared/material/latlong/testing/latlong.test.mjs +3 -3
  21. package/esm2022/src/app/shared/material/material.animations.mjs +1 -1
  22. package/esm2022/src/app/shared/pipes/latlong-format.pipe.mjs +1 -1
  23. package/esm2022/src/app/shared/rx-state/rx-state.decorators.mjs +1 -1
  24. package/esm2022/src/app/shared/validator/validators.mjs +1 -1
  25. package/esm2022/src/environments/environment.class.mjs +1 -1
  26. package/esm2022/src/environments/environment.mjs +1 -1
  27. package/fesm2022/sumaris-net.ngx-components.mjs +14 -12
  28. package/fesm2022/sumaris-net.ngx-components.mjs.map +1 -1
  29. package/package.json +1 -1
  30. package/src/app/shared/inputs.d.ts +1 -1
  31. package/src/assets/i18n/en-US.json +735 -735
  32. package/src/assets/i18n/en.json +734 -734
  33. package/src/assets/i18n/fr.json +734 -734
  34. package/src/assets/manifest.json +17 -17
  35. package/src/theme/_material.scss +213 -213
  36. package/src/theme/_ngx-components.scss +955 -955
  37. package/src/theme/_ngx-components.table.scss +597 -597
@@ -1,955 +1,955 @@
1
-
2
- body,
3
- html {
4
- padding: 0;
5
- margin: 0;
6
- }
7
-
8
- *::selection {
9
- background: var(--ion-color-shade, rgba(0, 0, 0, 0.3));
10
- }
11
-
12
- // Text style
13
- // --------------------------------------------------
14
- .text-italic {
15
- font-style: italic;
16
- }
17
- .ion-text-wrap {
18
- white-space: normal;
19
- word-wrap: break-word;
20
- }
21
-
22
- // Page Container Structure
23
- // --------------------------------------------------
24
-
25
- .ion-page-invisible {
26
- opacity: 0;
27
- }
28
-
29
- ion-toolbar ion-title,
30
- app-toolbar ion-title {
31
- small {
32
- font-weight: normal;
33
- br {
34
- display: none;
35
- visibility: hidden;
36
- }
37
- }
38
- // Add a separator, after the <small> part
39
- small:first-of-type:after {
40
- content: " - ";
41
- }
42
- }
43
-
44
- @media screen and (max-width: $screen-sm-max) {
45
- ion-toolbar ion-title,
46
- app-toolbar ion-title {
47
- small {
48
- @include font-size(10pt);
49
- }
50
- small br {
51
- display: unset;
52
- visibility: unset;
53
- }
54
- // Add a separator, after the <small> part
55
- small:first-of-type:after {
56
- content: "";
57
- }
58
- }
59
- }
60
-
61
- // Ionic Safe Margins
62
- // --------------------------------------------------
63
- html.plt-ios.plt-hybrid,
64
- html.plt-ios.plt-pwa {
65
- --ion-statusbar-padding: 20px;
66
- }
67
-
68
- html {
69
- --ion-safe-area-top: var(--ion-statusbar-padding);
70
- }
71
-
72
- // TODO: remove once Safari 11.2 dies
73
- @supports (padding-top: constant(safe-area-inset-top)) {
74
- html {
75
- --ion-safe-area-top: constant(safe-area-inset-top);
76
- --ion-safe-area-bottom: constant(safe-area-inset-bottom);
77
- --ion-safe-area-left: constant(safe-area-inset-left);
78
- --ion-safe-area-right: constant(safe-area-inset-right);
79
- }
80
- }
81
-
82
- @supports (padding-top: env(safe-area-inset-top)) {
83
- html {
84
- --ion-safe-area-top: env(safe-area-inset-top);
85
- --ion-safe-area-bottom: env(safe-area-inset-bottom);
86
- --ion-safe-area-left: env(safe-area-inset-left);
87
- --ion-safe-area-right: env(safe-area-inset-right);
88
- }
89
- }
90
-
91
- // --------------------------------------------------
92
- // Back button in app toolbar
93
- // --------------------------------------------------
94
-
95
- .ion-page.can-go-back {
96
- app-toolbar {
97
-
98
- ion-menu-toggle {
99
- display: none !important;
100
- }
101
-
102
- // Back button
103
- ion-back-button,
104
- ion-button.back-button {
105
- display: inline-block !important;
106
- }
107
- }
108
- }
109
-
110
- // --------------------------------------------------
111
- // Main Menu
112
- // --------------------------------------------------
113
- .split-pane-md.split-pane-visible > .split-pane-side {
114
- max-width: #{$app-menu-width} !important;
115
- }
116
-
117
- ion-menu.menu-side-left {
118
- .menu-inner {
119
- .scroll {
120
- overflow-y: auto !important;
121
-
122
- .scroll-inner {
123
- min-height: auto !important;
124
- }
125
- }
126
- }
127
- }
128
-
129
-
130
- mat-form-field {
131
- .mat-paginator-page-size-select {
132
- @include font-size-important(14px);
133
- }
134
- }
135
-
136
-
137
- // --- mat-date-short-field
138
- mat-calendar.mat-date-short-panel {
139
- // Hide some buttons (e.g. to change the period)
140
- // and the month view
141
- .mat-calendar-period-button,
142
- mat-year-view {
143
- visibility: hidden;
144
- display: none;
145
- }
146
- }
147
-
148
- @media screen and (min-width: $screen-sm) {
149
- form.form-container {
150
- ion-grid {
151
- ion-col[size-sm="auto"] > mat-date-time-field {
152
- // When inside a form + grid : fix <ion-col size-sm="auto"> alignment in some screen resolution
153
- max-width: 200px;
154
- }
155
- }
156
- }
157
- }
158
- // --------------------------------------------------
159
- // mat-checkbox
160
- // --------------------------------------------------
161
-
162
- mat-checkbox {
163
- .mat-checkbox-checkmark {
164
- .mat-checkbox-checkmark-path {
165
- // TODO: change to accent-contrast
166
- stroke: white !important;
167
- }
168
- }
169
- }
170
-
171
- // --------------------------------------------------
172
- // mat-autocomplete and mat-select panel
173
- // --------------------------------------------------
174
-
175
- // When simple text option, add a padding
176
- mat-option {
177
-
178
- .mdc-list-item__primary-text {
179
- display: inline-block;
180
- flex-grow: 1;
181
- }
182
- .mat-option-text:not(:has(ion-row)),
183
- .mat-option-text:has(ion-searchbar),
184
- .mdc-list-item__primary-text:has(ion-searchbar) {
185
- padding: 0 !important;
186
- }
187
- ion-row,
188
- .mat-option-text:has(ion-row),
189
- .mdc-list-item__primary-text:has(ion-row) {
190
- padding: 0;
191
- }
192
- mat-autocomplete-footer {
193
- .mat-option-text,
194
- .mdc-list-item__primary-text {
195
- padding: 0 !important;
196
- }
197
- }
198
- }
199
-
200
- mat-option:not(:last-of-type) {
201
- border-bottom: 1px solid #{$app-select-option-border-color};
202
- }
203
-
204
-
205
- .cdk-overlay-pane:has(.mat-mdc-select-panel) {
206
- --min-width: 200px;
207
- --max-width: calc(min(100%, 100vw - 64px));
208
- min-width: var(--min-width) !important;
209
- max-width: var(--max-width) !important;
210
-
211
- // FIXME : This is a workaround find at : https://github.com/angular/components/issues/26000#issuecomment-1563107933
212
- &:has(.mat-select-panel-fit-content) {
213
- --min-width: fit-content !important;
214
- }
215
-
216
- .mat-mdc-select-panel {
217
- --mat-switch-visible-track-transition: transform 75ms 50ms cubic-bezier(0, 0, 0.2, 1);
218
- transition: --mat-switch-visible-track-transition;
219
- transform: scaleY(1) !important;
220
-
221
- &.hidden {
222
- transform: scaleY(0) !important;
223
- }
224
-
225
- .mat-mdc-option {
226
- // When option text wrap, do not increase the option height
227
- ion-col.ion-text-wrap {
228
- max-height: var(--mat-option-max-height, #{$mat-option-max-height});
229
- }
230
- }
231
- }
232
-
233
- }
234
-
235
-
236
- .cdk-overlay-pane:has(.mat-mdc-autocomplete-panel) {
237
- --min-width: 200px;
238
- --max-width: calc(min(100%, 100vw - 64px));
239
- min-width: var(--min-width) !important;
240
- max-width: var(--max-width) !important;
241
-
242
- // FIXME : This is a workaround find at : https://github.com/angular/components/issues/26000#issuecomment-1563107933
243
- &:has(.mat-select-panel-fit-content) {
244
- --min-width: fit-content !important;
245
- }
246
- }
247
-
248
-
249
- .mat-mdc-autocomplete-panel-medium-size .mat-mdc-autocomplete-panel,
250
- .mat-mdc-autocomplete-panel-medium-size.mat-mdc-autocomplete-panel,
251
- .min-width-medium .mat-mdc-autocomplete-panel,
252
- .min-width-medium.mat-mdc-autocomplete-panel,
253
- .min-width-medium.mat-mdc-select-panel {
254
- --min-width: 300px;
255
- }
256
- .mat-mdc-autocomplete-panel-large-size .mat-mdc-autocomplete-panel,
257
- .mat-mdc-autocomplete-panel.mat-mdc-autocomplete-panel-large-size,
258
- .min-width-large .mat-mdc-autocomplete-panel,
259
- .min-width-large.mat-mdc-autocomplete-panel,
260
- .min-width-large.mat-mdc-select-panel{
261
- --min-width: 400px;
262
- }
263
- .mat-mdc-autocomplete-panel-xlarge-size .mat-mdc-autocomplete-panel,
264
- .mat-mdc-autocomplete-panel-xlarge-size.mat-mdc-autocomplete-panel,
265
- .mat-mdc-autocomplete-panel-xlarge-size.mat-mdc-select-panel {
266
- --min-width: 450px;
267
- }
268
- .mat-select-panel.min-width-80vw,
269
- .mat-mdc-select-panel.min-width-80vw,
270
- .min-width-80vw .mat-mdc-autocomplete-panel,
271
- .min-width-80vw.mat-mdc-autocomplete-panel {
272
- --min-width: 80vw;
273
- }
274
-
275
- .mat-mdc-autocomplete-panel-center .mat-mdc-autocomplete-panel,
276
- .mat-mdc-autocomplete-panel-center.mat-mdc-autocomplete-panel {
277
- margin-left: calc(var(--min-width, 200px) / -2 + 50%) !important;
278
- }
279
-
280
- .mat-mdc-autocomplete-panel-full-size .mat-mdc-autocomplete-panel,
281
- .mat-mdc-autocomplete-panel-full-size.mat-mdc-autocomplete-panel,
282
- .full-size .mat-mdc-autocomplete-panel,
283
- .full-size.mat-mdc-autocomplete-panel,
284
- .cdk-overlay-pane:has(.mat-mdc-select-panel.full-size) {
285
- --min-width: calc(100vw - 64px);
286
- --max-width: calc(100vw - 64px);
287
- position: fixed;
288
- left: 32px !important;
289
- }
290
-
291
- .mat-mdc-select-panel,
292
- .mat-mdc-autocomplete-panel {
293
- /* when multiple selection enable */
294
- mat-pseudo-checkbox {
295
- margin-left: 8px;
296
- }
297
-
298
- padding: 0 !important;
299
- }
300
-
301
- ion-list,
302
- .mat-mdc-menu-panel {
303
- &.ion-list-popover {
304
- padding: 0 !important;
305
- }
306
- }
307
-
308
- // --------------------------------------------------
309
- // mat-autocomplete-field
310
- // --------------------------------------------------
311
-
312
- // Define useful variable
313
- html.plt-ios {
314
- --ion-searchbar-height: 60px;
315
- //--ion-toolbar-height: 58px;
316
- }
317
- html {
318
- //--ion-searchbar-height: 58px;
319
- }
320
-
321
- ion-list,
322
- .mat-mdc-menu-panel,
323
- .mat-mdc-select-panel,
324
- .mat-mdc-autocomplete-panel {
325
-
326
- /* Avoid bad display, when opening panel for the first time */
327
- &.ng-trigger-transformPanel {
328
- ion-searchbar.mat-select-header,
329
- ion-searchbar.mat-autocomplete-header {
330
- visibility: visible;
331
- display: flex;
332
- opacity: 1;
333
- transition: opacity 0.3s ease-in-out;
334
- }
335
- }
336
-
337
- .mat-mdc-optgroup.mat-select-searchbar,
338
- .mat-mdc-option.mat-autocomplete-searchbar
339
- {
340
- padding: 0 !important;
341
- height: var(--ion-searchbar-height, 58px) !important;
342
- background-color: var(--ion-color-secondary100) !important;
343
- pointer-events: inherit !important;
344
-
345
- .mat-mdc-optgroup-label {
346
- background-color: var(--ion-color-secondary100) !important;
347
- padding: 0;
348
- display: block;
349
- }
350
-
351
- /* hide pseudo checkbox, in the searchbar*/
352
- mat-pseudo-checkbox {
353
- visibility: hidden;
354
- display: none;
355
- }
356
-
357
- &.mat-select-searchbar-sticky {
358
- z-index: 1001;
359
- /* Set header as sticky*/
360
- position: -webkit-sticky;
361
- position: sticky;
362
- top: 0;
363
- }
364
-
365
- .searchbar-input {
366
- --background: var(--app-form-field-background-color, var(--ion-background-color));
367
- }
368
- }
369
-
370
- ion-row.ion-list-header,
371
- ion-row.mat-select-header,
372
- ion-row.mat-menu-header,
373
- ion-row.mat-autocomplete-header {
374
- &.multiple {
375
- /* Offset due to mat-pseudo-checkbox */
376
- padding-left: 32px;
377
- }
378
- &.column {
379
- /* Set header as sticky*/
380
- position: -webkit-sticky;
381
- position: sticky;
382
- top: 0;
383
- z-index: 1001;
384
- background-color: var(--ion-color-secondary);
385
- border-bottom: 1px solid #{$app-select-option-border-color};
386
- color: var(--ion-color-secondary-contrast);
387
- line-height: 20px;
388
- @include font-size(12px);
389
- font-weight: 500;
390
- height: 20px;
391
- ion-col {
392
- white-space: nowrap;
393
- text-overflow: ellipsis;
394
- }
395
- &.mat-select-searchbar-sticky {
396
- /* offset because of the searchbar height */
397
- top: var(--ion-searchbar-height, 58px);
398
- }
399
- }
400
-
401
- }
402
-
403
- ion-row.ion-list-footer,
404
- ion-row.mat-select-footer,
405
- ion-row.mat-menu-footer,
406
- ion-row.mat-autocomplete-footer,
407
- mat-option.mat-autocomplete-footer {
408
- /* Set footer as sticky*/
409
- position: -webkit-sticky;
410
- position: sticky;
411
- bottom: 0;
412
- z-index: 1001;
413
- border-top: 1px solid #{$app-select-option-border-color};
414
- background-color: var(--ion-toolbar-background, #{$ion-toolbar-background});
415
- color: var(--ion-color-medium) !important; // not working on mobile form because the mat-option is disabled
416
- @include font-size(12px);
417
- font-weight: 500;
418
- height: 20px;
419
- min-height: 20px;
420
- line-height: 20px;
421
- opacity: 1 !important;
422
-
423
- ion-col {
424
- white-space: nowrap;
425
- text-overflow: ellipsis;
426
- }
427
- }
428
-
429
- ion-row {
430
- --ion-grid-column-padding: 0;
431
-
432
- ion-col {
433
- --padding-start: 8px;
434
- padding: 0 !important;
435
- padding-left: var(--padding-start) !important;
436
- text-overflow: ellipsis;
437
- overflow: hidden;
438
- white-space: nowrap;
439
- }
440
- }
441
-
442
- .odd {
443
- background: var(--ion-light-color-shade, $light);
444
- }
445
-
446
- .mat-mdc-option[no-padding],
447
- mat-option[no-padding] {
448
- padding: 0 !important;
449
- }
450
- }
451
-
452
- // --------------------------------------------------
453
- // Table > Filter expansion panel
454
- // --------------------------------------------------
455
-
456
- mat-expansion-panel {
457
-
458
- &.filter-panel {
459
-
460
- background: var(--ion-color-secondary50);
461
- color: var(--ion-color-secondary50-contrast);
462
- margin-bottom: 5px;
463
-
464
- .form-container {
465
- mat-form-field {
466
- width: 100%;
467
-
468
- .datetime-md {
469
- padding: 0 !important;
470
- }
471
- }
472
- }
473
-
474
- mat-action-row {
475
- ion-label {
476
- line-height: 36px;
477
- }
478
- }
479
- }
480
-
481
- &.filter-panel-floating {
482
- z-index: 999;
483
- position: absolute;
484
- top: 0;
485
- left: 0;
486
- right: 0;
487
- }
488
-
489
- &.filter-panel-pinned {
490
- overflow-y: scroll;
491
- }
492
-
493
- .mat-expansion-panel-header,
494
- mat-expansion-panel-header {
495
- padding: var(--expansion-panel-header-padding, var(--expansion-panel-padding));
496
- }
497
- .mat-expansion-panel-body {
498
- padding: var(--expansion-panel-padding, var(--ion-padding));
499
- }
500
- }
501
-
502
- // --------------------------------------------------
503
- // Form buttons bar
504
- // --------------------------------------------------
505
- app-form-buttons-bar {
506
- --form-buttons-bar-buttons-width: 400px;
507
- --form-buttons-bar-content-max-width: calc(100% - var(--form-buttons-bar-buttons-width) - 40px /*right menu toggle button*/);
508
- .app-form-buttons-bar-content {
509
- max-width: var(--form-buttons-bar-content-max-width);
510
- }
511
- }
512
-
513
- // --------------------------------------------------
514
- // Ion-select
515
- // --------------------------------------------------
516
-
517
- ion-popover.select-popover {
518
- .popover-content {
519
- min-width: calc(min(80%, 200px));
520
- }
521
- }
522
-
523
- @media screen and (min-width: $screen-sm) {
524
- ion-popover.select-popover {
525
- .popover-content {
526
- min-width: 300px;
527
- }
528
-
529
- ion-radio .radio-icon {
530
- border: 0 !important;
531
- }
532
- }
533
- }
534
-
535
-
536
- // --------------------------------------------------
537
- // Ionic list
538
- // --------------------------------------------------
539
- ion-list {
540
- ion-item.ion-item-selected {
541
- --ion-color-base: var(--ion-color-secondary100);
542
- --ion-color-contrast: var(--ion-color-secondary100-contrast);
543
-
544
- &:before {
545
- background: var(--ion-color-base) !important;
546
- color: var(--ion-color-contrast) !important;
547
- }
548
- }
549
- }
550
-
551
- // ------------------------
552
- // Other material component
553
-
554
- .flex-spacer,
555
- .toolbar-spacer {
556
- flex: 1 1 auto;
557
- }
558
-
559
- ion-toolbar {
560
- --min-height: var(--ion-toolbar-height, 56px);
561
- }
562
- ion-toolbar[translucent] {
563
- --background: transparent !important;
564
- }
565
-
566
- // --- mat-stepper component
567
- mat-horizontal-stepper {
568
- .mat-horizontal-stepper-header-container {
569
- padding: 0;
570
- }
571
-
572
- .mat-horizontal-content-container {
573
- padding: 0;
574
- }
575
- }
576
-
577
-
578
- // Extra small device: Phones (<767px)
579
- @media screen and (max-width: $screen-xs-max) {
580
- mat-horizontal-stepper {
581
- .mat-horizontal-stepper-header-container {
582
- .mat-horizontal-stepper-header {
583
- padding-left: 5px;
584
- }
585
-
586
- .mat-stepper-horizontal-line {
587
- display: none;
588
- }
589
- }
590
-
591
- .mat-horizontal-content-container {
592
- padding: 0;
593
- }
594
- }
595
- }
596
-
597
- mat-button-toggle.mat-button-toggle-checked,
598
- mat-button-toggle.mat-button-toggle-checked.mat-button-toggle-disabled {
599
- background-color: var(--ion-color-light);
600
- color: white;
601
- }
602
-
603
- // --------------------------------------------------
604
- // Material menu
605
- // --------------------------------------------------
606
-
607
-
608
- .mat-mdc-menu-panel {
609
-
610
- // Max width = 400px
611
- &.mat-menu-size-400 {
612
- min-width: unset;
613
- width: 400px;
614
- max-width: calc(90vw);
615
- }
616
- // Max width = 75vw
617
- &.mat-menu-size-75vw {
618
- min-width: unset;
619
- width: calc(75vw);
620
- max-width: calc(90vw);
621
- }
622
-
623
- // No padding
624
- &.ion-no-padding {
625
- .mat-mdc-menu-content {
626
- padding: 0 !important;
627
- }
628
- }
629
-
630
- // Small menu item (e.g. for actions on a table row)
631
- &.mat-mdc-menu-item-small-height .mat-mdc-menu-item,
632
- .mat-mdc-menu-item.mat-mdc-menu-item-small-height
633
- {
634
- padding: 0 8px;
635
- height: 35px;
636
- line-height: 35px;
637
- }
638
- // Reduce the font size, on label just inside a mat-menu (e.g. see trips.page.html)
639
- .mat-mdc-menu-content > ion-label {
640
- @include font-size(12px);
641
- }
642
-
643
- .mat-mdc-menu-content ion-item > ion-icon[slot="start"] {
644
- margin-right: 16px;
645
- vertical-align: middle;
646
- }
647
-
648
- // Menu title (e.g. see extraction map)
649
- .mat-mdc-menu-item.mat-mdc-menu-title {
650
- padding: 0 8px;
651
- height: 27px;
652
- line-height: 27px;
653
- @include font-size(12px);
654
- pointer-events: none;
655
- color: var(--ion-color-medium, rgba(0, 0, 0, 0.38));
656
- }
657
- }
658
-
659
- // --------------------------------------------------
660
- // Alert
661
- // --------------------------------------------------
662
-
663
- ion-alert button.alert-button {
664
- cursor: pointer;
665
- }
666
-
667
-
668
- // --------------------------------------------------
669
- // Overlay
670
- // --------------------------------------------------
671
-
672
- .cdk-overlay-dark-backdrop {
673
- background: rgba(var(--ion-backdrop-color-rgb, 0,0,0), var(--ion-backdrop-opacity, 0.32));
674
- }
675
-
676
- // --------------------------------------------------
677
- // Date and time picker
678
- // --------------------------------------------------
679
- // Date picker
680
- .mat-datepicker-content {
681
- --mat-datepicker-calendar-container-background-color: var(--ion-background-color, #fff) !important;
682
- --mat-datepicker-calendar-container-text-color: var(--ion-text-color, #000000) !important;
683
- --mat-datepicker-calendar-date-text-color: var(--ion-text-color);
684
- --mat-datepicker-calendar-body-label-text-color: var(--ion-color-step-500);
685
- --mat-datepicker-calendar-header-text-color: var(--ion-color-step-500);
686
- }
687
- mat-calendar {
688
- .mat-calendar-header {
689
- background-color: var(--ion-color-secondary) !important;
690
- color: var(--ion-color-secondary-contrast) !important;
691
-
692
- button {
693
- color: var(--ion-color-secondary-contrast) !important;
694
- }
695
- }
696
-
697
- .mat-calendar-body-selected {
698
- background-color: var(--ion-color-accent) !important;
699
- color: var(--ion-color-accent-contrast) !important;
700
- font-weight: bold;
701
- }
702
-
703
- .mat-calendar-arrow {
704
- border-top-color: var(--ion-color-secondary-contrast) !important;
705
- }
706
- }
707
-
708
- @media (orientation: landscape) {
709
- .mat-datepicker-content-touch {
710
- height: fit-content !important;
711
- min-height: 310px;
712
-
713
- .mat-calendar-controls {
714
- margin-top: 0;
715
- }
716
- .mat-datepicker-content-container {
717
- &.mat-datepicker-content-container-with-actions {
718
- height: unset !important;
719
- }
720
- .mat-datepicker-actions {
721
- background-color: var(--mat-datepicker-calendar-container-background-color);
722
- margin-top: -12px;
723
- }
724
- }
725
- }
726
- }
727
-
728
- // Time picker
729
- .timepicker {
730
- .timepicker-header {
731
- // Change header color to 'secondary'
732
- --mat-toolbar-container-background-color: var(--ion-color-secondary) !important;
733
- }
734
- }
735
-
736
- // --------------------------------------------------
737
- // Mat chip field
738
- // --------------------------------------------------
739
-
740
- .mat-mdc-form-field-type-mat-chip-grid {
741
- .mat-mdc-form-field-infix {
742
- --mdc-chip-container-height: 24px !important;
743
- }
744
- }
745
-
746
-
747
- // --------------------------------------------------
748
- // Pages
749
- // --------------------------------------------------
750
- ion-item {
751
- ion-label.error {
752
- line-height: 16px;
753
- line-break: normal;
754
- overflow: visible;
755
- white-space: normal;
756
- }
757
- }
758
-
759
- // --------------------------------------------------
760
- // Modal
761
- // --------------------------------------------------
762
-
763
- ion-modal.stack-modal {
764
- --box-shadow: 0 28px 48px rgba(0, 0, 0, 0.4);
765
- --backdrop-opacity: var(--ion-backdrop-opacity, 0.32);
766
- }
767
-
768
- ion-modal.modal-large{
769
- --min-height: calc(100% - 50px) !important;
770
- --min-width: calc(100% - 100px) !important;
771
- }
772
- ion-modal.modal-fullscreen {
773
- --min-height: calc(100%) !important;
774
- --min-width: calc(100%) !important;
775
- }
776
-
777
-
778
- // --------------------------------------------------
779
- // Popover
780
- // --------------------------------------------------
781
-
782
- .popover-large {
783
- --min-width: calc(min(500px, 80%));
784
- }
785
-
786
- .popover-notifications {
787
- --popover-top: 0;
788
- --max-height: calc(90vh - 40px /* header + footer height */ - var(--popover-top, 0px) - var(--offset-y, 0px));
789
-
790
- ion-item {
791
- --ion-item-background-color-hover: var(--ion-color-light);
792
- &.unread {
793
- --ion-item-background: rgba(var(--ion-color-secondary100-rgb), 0.2);
794
- --ion-item-background-color-hover: rgba(var(--ion-color-secondary100-rgb), 0.3);
795
- }
796
- }
797
- }
798
-
799
- // --------------------------------------------------
800
- // Large button with icon floating on right
801
- // --------------------------------------------------
802
- .flex-margin ion-icon,
803
- .flex-margin span {
804
- margin-left: auto;
805
- }
806
-
807
- // --------------------------------------------------
808
- // Icon tooltip, and title
809
- // --------------------------------------------------
810
- // Fix Button icon name overrides button's own title on mouse over
811
- /*ion-icon[name='chatbox'] {
812
- pointer-events: none !important;
813
- }*/
814
- .mat-cell {
815
- /* smaller size, for the comment icon */
816
- mat-icon.comment {
817
- @include font-size(16pt);
818
- height: 100%;
819
- vertical-align: center;
820
- color: var(--ion-color-tertiary, grey);
821
-
822
- &.disabled {
823
- color: var(--ion-color-medium, grey);
824
- }
825
- }
826
- }
827
-
828
- // --------------------------------------------------
829
- // Icon inside text
830
- // --------------------------------------------------
831
- mat-icon,
832
- ion-icon {
833
- &.text-size {
834
- font-size: 1em;
835
- width: 1em;
836
- height: 1em;
837
- }
838
- }
839
- ion-button[expand="block"],
840
- ion-button[expand="full"],
841
- .mat-button,
842
- .mat-raised-button {
843
- mat-icon,
844
- ion-icon {
845
- &[slot] {
846
- pointer-events: none;
847
- width: 24px;
848
- height: 24px;
849
- }
850
- &[slot='start'],
851
- &[slot='end'] {
852
- margin-left: unset;
853
- margin-right: unset;
854
- margin-top: 0;
855
- margin-bottom: 0;
856
- }
857
- &t[slot='start'] {
858
- margin-inline-start: -0.3em;
859
- margin-inline-end: 0.3em;
860
- }
861
- &[slot='end'] {
862
- margin-inline-start: 0.3em;
863
- margin-inline-end: -0.3em;
864
- }
865
- &.ion-float-start[slot='start'] {
866
- position: absolute;
867
- left: 0;
868
- }
869
- &.ion-float-end[slot='end'] {
870
- position: absolute;
871
- right: 0;
872
- }
873
- }
874
- }
875
-
876
- // --------------------------------------------------
877
- // Icon multiple
878
- // --------------------------------------------------
879
- ion-icon.icon-secondary,
880
- mat-icon.icon-secondary,
881
- .mat-mdc-icon-button .mat-icon.icon-secondary {
882
- position: absolute;
883
- left: 0;
884
- }
885
-
886
- // --------------------------------------------------
887
- // Toast
888
- // --------------------------------------------------
889
- ion-toast {
890
- --background: var(--ion-color-dark);
891
- --color: var(--ion-color-dark-contrast);
892
- --button-color: var(--ion-color-secondary);
893
-
894
- &.secondary {
895
- --background: var(--ion-color-secondary);
896
- --color: var(--ion-color-secondary-contrast);
897
- --button-color: var(--ion-color-tertiary);
898
- }
899
- &.accent {
900
- --background: var(--ion-color-accent);
901
- --color: var(--ion-color-accent-contrast);
902
- --button-color: var(--ion-color-primary);
903
- }
904
- &.danger {
905
- --background: var(--ion-color-danger);
906
- --color: var(--ion-color-danger-contrast);
907
- --button-color: var(--ion-color-primary);
908
- }
909
-
910
- /* -- workaround because toast animation failed */
911
- --toast-max-height: 75px;
912
-
913
- &.toast-stack-offset-1 {
914
- --toast-stack-offset: 1;
915
- }
916
- &.toast-stack-offset-2 {
917
- --toast-stack-offset: 2;
918
- }
919
- &.toast-stack-offset-3 {
920
- --toast-stack-offset: 3;
921
- }
922
- &.toast-stack-offset-4 {
923
- --toast-stack-offset: 4;
924
- }
925
-
926
- &.toast-stacked-top {
927
- --toast-top: calc(var(--toast-stack-offset, 0) * var(--toast-max-height, 0));
928
- transform: translateY(var(--toast-top));
929
- }
930
- &.toast-stacked-bottom {
931
- --toast-bottom: calc(-1 * var(--toast-stack-offset, 0) * var(--toast-max-height, 0)) !important;
932
- transform: translateY(var(--toast-bottom));
933
- }
934
- }
935
-
936
- // --------------------------------------------------
937
- // Refresher
938
- // --------------------------------------------------
939
- ion-refresher.refresher-native {
940
- z-index: 1000;
941
- }
942
-
943
- // --------------------------------------------------
944
- // Named filter
945
- // --------------------------------------------------
946
-
947
- ion-toolbar app-named-filter-selector,
948
- mat-toolbar app-named-filter-selector {
949
-
950
- // Hide subscript wrapper (will hide hint)
951
- .mat-mdc-form-field-subscript-wrapper {
952
- display: none;
953
- visibility: hidden;
954
- }
955
- }
1
+
2
+ body,
3
+ html {
4
+ padding: 0;
5
+ margin: 0;
6
+ }
7
+
8
+ *::selection {
9
+ background: var(--ion-color-shade, rgba(0, 0, 0, 0.3));
10
+ }
11
+
12
+ // Text style
13
+ // --------------------------------------------------
14
+ .text-italic {
15
+ font-style: italic;
16
+ }
17
+ .ion-text-wrap {
18
+ white-space: normal;
19
+ word-wrap: break-word;
20
+ }
21
+
22
+ // Page Container Structure
23
+ // --------------------------------------------------
24
+
25
+ .ion-page-invisible {
26
+ opacity: 0;
27
+ }
28
+
29
+ ion-toolbar ion-title,
30
+ app-toolbar ion-title {
31
+ small {
32
+ font-weight: normal;
33
+ br {
34
+ display: none;
35
+ visibility: hidden;
36
+ }
37
+ }
38
+ // Add a separator, after the <small> part
39
+ small:first-of-type:after {
40
+ content: " - ";
41
+ }
42
+ }
43
+
44
+ @media screen and (max-width: $screen-sm-max) {
45
+ ion-toolbar ion-title,
46
+ app-toolbar ion-title {
47
+ small {
48
+ @include font-size(10pt);
49
+ }
50
+ small br {
51
+ display: unset;
52
+ visibility: unset;
53
+ }
54
+ // Add a separator, after the <small> part
55
+ small:first-of-type:after {
56
+ content: "";
57
+ }
58
+ }
59
+ }
60
+
61
+ // Ionic Safe Margins
62
+ // --------------------------------------------------
63
+ html.plt-ios.plt-hybrid,
64
+ html.plt-ios.plt-pwa {
65
+ --ion-statusbar-padding: 20px;
66
+ }
67
+
68
+ html {
69
+ --ion-safe-area-top: var(--ion-statusbar-padding);
70
+ }
71
+
72
+ // TODO: remove once Safari 11.2 dies
73
+ @supports (padding-top: constant(safe-area-inset-top)) {
74
+ html {
75
+ --ion-safe-area-top: constant(safe-area-inset-top);
76
+ --ion-safe-area-bottom: constant(safe-area-inset-bottom);
77
+ --ion-safe-area-left: constant(safe-area-inset-left);
78
+ --ion-safe-area-right: constant(safe-area-inset-right);
79
+ }
80
+ }
81
+
82
+ @supports (padding-top: env(safe-area-inset-top)) {
83
+ html {
84
+ --ion-safe-area-top: env(safe-area-inset-top);
85
+ --ion-safe-area-bottom: env(safe-area-inset-bottom);
86
+ --ion-safe-area-left: env(safe-area-inset-left);
87
+ --ion-safe-area-right: env(safe-area-inset-right);
88
+ }
89
+ }
90
+
91
+ // --------------------------------------------------
92
+ // Back button in app toolbar
93
+ // --------------------------------------------------
94
+
95
+ .ion-page.can-go-back {
96
+ app-toolbar {
97
+
98
+ ion-menu-toggle {
99
+ display: none !important;
100
+ }
101
+
102
+ // Back button
103
+ ion-back-button,
104
+ ion-button.back-button {
105
+ display: inline-block !important;
106
+ }
107
+ }
108
+ }
109
+
110
+ // --------------------------------------------------
111
+ // Main Menu
112
+ // --------------------------------------------------
113
+ .split-pane-md.split-pane-visible > .split-pane-side {
114
+ max-width: #{$app-menu-width} !important;
115
+ }
116
+
117
+ ion-menu.menu-side-left {
118
+ .menu-inner {
119
+ .scroll {
120
+ overflow-y: auto !important;
121
+
122
+ .scroll-inner {
123
+ min-height: auto !important;
124
+ }
125
+ }
126
+ }
127
+ }
128
+
129
+
130
+ mat-form-field {
131
+ .mat-paginator-page-size-select {
132
+ @include font-size-important(14px);
133
+ }
134
+ }
135
+
136
+
137
+ // --- mat-date-short-field
138
+ mat-calendar.mat-date-short-panel {
139
+ // Hide some buttons (e.g. to change the period)
140
+ // and the month view
141
+ .mat-calendar-period-button,
142
+ mat-year-view {
143
+ visibility: hidden;
144
+ display: none;
145
+ }
146
+ }
147
+
148
+ @media screen and (min-width: $screen-sm) {
149
+ form.form-container {
150
+ ion-grid {
151
+ ion-col[size-sm="auto"] > mat-date-time-field {
152
+ // When inside a form + grid : fix <ion-col size-sm="auto"> alignment in some screen resolution
153
+ max-width: 200px;
154
+ }
155
+ }
156
+ }
157
+ }
158
+ // --------------------------------------------------
159
+ // mat-checkbox
160
+ // --------------------------------------------------
161
+
162
+ mat-checkbox {
163
+ .mat-checkbox-checkmark {
164
+ .mat-checkbox-checkmark-path {
165
+ // TODO: change to accent-contrast
166
+ stroke: white !important;
167
+ }
168
+ }
169
+ }
170
+
171
+ // --------------------------------------------------
172
+ // mat-autocomplete and mat-select panel
173
+ // --------------------------------------------------
174
+
175
+ // When simple text option, add a padding
176
+ mat-option {
177
+
178
+ .mdc-list-item__primary-text {
179
+ display: inline-block;
180
+ flex-grow: 1;
181
+ }
182
+ .mat-option-text:not(:has(ion-row)),
183
+ .mat-option-text:has(ion-searchbar),
184
+ .mdc-list-item__primary-text:has(ion-searchbar) {
185
+ padding: 0 !important;
186
+ }
187
+ ion-row,
188
+ .mat-option-text:has(ion-row),
189
+ .mdc-list-item__primary-text:has(ion-row) {
190
+ padding: 0;
191
+ }
192
+ mat-autocomplete-footer {
193
+ .mat-option-text,
194
+ .mdc-list-item__primary-text {
195
+ padding: 0 !important;
196
+ }
197
+ }
198
+ }
199
+
200
+ mat-option:not(:last-of-type) {
201
+ border-bottom: 1px solid #{$app-select-option-border-color};
202
+ }
203
+
204
+
205
+ .cdk-overlay-pane:has(.mat-mdc-select-panel) {
206
+ --min-width: 200px;
207
+ --max-width: calc(min(100%, 100vw - 64px));
208
+ min-width: var(--min-width) !important;
209
+ max-width: var(--max-width) !important;
210
+
211
+ // FIXME : This is a workaround find at : https://github.com/angular/components/issues/26000#issuecomment-1563107933
212
+ &:has(.mat-select-panel-fit-content) {
213
+ --min-width: fit-content !important;
214
+ }
215
+
216
+ .mat-mdc-select-panel {
217
+ --mat-switch-visible-track-transition: transform 75ms 50ms cubic-bezier(0, 0, 0.2, 1);
218
+ transition: --mat-switch-visible-track-transition;
219
+ transform: scaleY(1) !important;
220
+
221
+ &.hidden {
222
+ transform: scaleY(0) !important;
223
+ }
224
+
225
+ .mat-mdc-option {
226
+ // When option text wrap, do not increase the option height
227
+ ion-col.ion-text-wrap {
228
+ max-height: var(--mat-option-max-height, #{$mat-option-max-height});
229
+ }
230
+ }
231
+ }
232
+
233
+ }
234
+
235
+
236
+ .cdk-overlay-pane:has(.mat-mdc-autocomplete-panel) {
237
+ --min-width: 200px;
238
+ --max-width: calc(min(100%, 100vw - 64px));
239
+ min-width: var(--min-width) !important;
240
+ max-width: var(--max-width) !important;
241
+
242
+ // FIXME : This is a workaround find at : https://github.com/angular/components/issues/26000#issuecomment-1563107933
243
+ &:has(.mat-select-panel-fit-content) {
244
+ --min-width: fit-content !important;
245
+ }
246
+ }
247
+
248
+
249
+ .mat-mdc-autocomplete-panel-medium-size .mat-mdc-autocomplete-panel,
250
+ .mat-mdc-autocomplete-panel-medium-size.mat-mdc-autocomplete-panel,
251
+ .min-width-medium .mat-mdc-autocomplete-panel,
252
+ .min-width-medium.mat-mdc-autocomplete-panel,
253
+ .min-width-medium.mat-mdc-select-panel {
254
+ --min-width: 300px;
255
+ }
256
+ .mat-mdc-autocomplete-panel-large-size .mat-mdc-autocomplete-panel,
257
+ .mat-mdc-autocomplete-panel.mat-mdc-autocomplete-panel-large-size,
258
+ .min-width-large .mat-mdc-autocomplete-panel,
259
+ .min-width-large.mat-mdc-autocomplete-panel,
260
+ .min-width-large.mat-mdc-select-panel{
261
+ --min-width: 400px;
262
+ }
263
+ .mat-mdc-autocomplete-panel-xlarge-size .mat-mdc-autocomplete-panel,
264
+ .mat-mdc-autocomplete-panel-xlarge-size.mat-mdc-autocomplete-panel,
265
+ .mat-mdc-autocomplete-panel-xlarge-size.mat-mdc-select-panel {
266
+ --min-width: 450px;
267
+ }
268
+ .mat-select-panel.min-width-80vw,
269
+ .mat-mdc-select-panel.min-width-80vw,
270
+ .min-width-80vw .mat-mdc-autocomplete-panel,
271
+ .min-width-80vw.mat-mdc-autocomplete-panel {
272
+ --min-width: 80vw;
273
+ }
274
+
275
+ .mat-mdc-autocomplete-panel-center .mat-mdc-autocomplete-panel,
276
+ .mat-mdc-autocomplete-panel-center.mat-mdc-autocomplete-panel {
277
+ margin-left: calc(var(--min-width, 200px) / -2 + 50%) !important;
278
+ }
279
+
280
+ .mat-mdc-autocomplete-panel-full-size .mat-mdc-autocomplete-panel,
281
+ .mat-mdc-autocomplete-panel-full-size.mat-mdc-autocomplete-panel,
282
+ .full-size .mat-mdc-autocomplete-panel,
283
+ .full-size.mat-mdc-autocomplete-panel,
284
+ .cdk-overlay-pane:has(.mat-mdc-select-panel.full-size) {
285
+ --min-width: calc(100vw - 64px);
286
+ --max-width: calc(100vw - 64px);
287
+ position: fixed;
288
+ left: 32px !important;
289
+ }
290
+
291
+ .mat-mdc-select-panel,
292
+ .mat-mdc-autocomplete-panel {
293
+ /* when multiple selection enable */
294
+ mat-pseudo-checkbox {
295
+ margin-left: 8px;
296
+ }
297
+
298
+ padding: 0 !important;
299
+ }
300
+
301
+ ion-list,
302
+ .mat-mdc-menu-panel {
303
+ &.ion-list-popover {
304
+ padding: 0 !important;
305
+ }
306
+ }
307
+
308
+ // --------------------------------------------------
309
+ // mat-autocomplete-field
310
+ // --------------------------------------------------
311
+
312
+ // Define useful variable
313
+ html.plt-ios {
314
+ --ion-searchbar-height: 60px;
315
+ //--ion-toolbar-height: 58px;
316
+ }
317
+ html {
318
+ //--ion-searchbar-height: 58px;
319
+ }
320
+
321
+ ion-list,
322
+ .mat-mdc-menu-panel,
323
+ .mat-mdc-select-panel,
324
+ .mat-mdc-autocomplete-panel {
325
+
326
+ /* Avoid bad display, when opening panel for the first time */
327
+ &.ng-trigger-transformPanel {
328
+ ion-searchbar.mat-select-header,
329
+ ion-searchbar.mat-autocomplete-header {
330
+ visibility: visible;
331
+ display: flex;
332
+ opacity: 1;
333
+ transition: opacity 0.3s ease-in-out;
334
+ }
335
+ }
336
+
337
+ .mat-mdc-optgroup.mat-select-searchbar,
338
+ .mat-mdc-option.mat-autocomplete-searchbar
339
+ {
340
+ padding: 0 !important;
341
+ height: var(--ion-searchbar-height, 58px) !important;
342
+ background-color: var(--ion-color-secondary100) !important;
343
+ pointer-events: inherit !important;
344
+
345
+ .mat-mdc-optgroup-label {
346
+ background-color: var(--ion-color-secondary100) !important;
347
+ padding: 0;
348
+ display: block;
349
+ }
350
+
351
+ /* hide pseudo checkbox, in the searchbar*/
352
+ mat-pseudo-checkbox {
353
+ visibility: hidden;
354
+ display: none;
355
+ }
356
+
357
+ &.mat-select-searchbar-sticky {
358
+ z-index: 1001;
359
+ /* Set header as sticky*/
360
+ position: -webkit-sticky;
361
+ position: sticky;
362
+ top: 0;
363
+ }
364
+
365
+ .searchbar-input {
366
+ --background: var(--app-form-field-background-color, var(--ion-background-color));
367
+ }
368
+ }
369
+
370
+ ion-row.ion-list-header,
371
+ ion-row.mat-select-header,
372
+ ion-row.mat-menu-header,
373
+ ion-row.mat-autocomplete-header {
374
+ &.multiple {
375
+ /* Offset due to mat-pseudo-checkbox */
376
+ padding-left: 32px;
377
+ }
378
+ &.column {
379
+ /* Set header as sticky*/
380
+ position: -webkit-sticky;
381
+ position: sticky;
382
+ top: 0;
383
+ z-index: 1001;
384
+ background-color: var(--ion-color-secondary);
385
+ border-bottom: 1px solid #{$app-select-option-border-color};
386
+ color: var(--ion-color-secondary-contrast);
387
+ line-height: 20px;
388
+ @include font-size(12px);
389
+ font-weight: 500;
390
+ height: 20px;
391
+ ion-col {
392
+ white-space: nowrap;
393
+ text-overflow: ellipsis;
394
+ }
395
+ &.mat-select-searchbar-sticky {
396
+ /* offset because of the searchbar height */
397
+ top: var(--ion-searchbar-height, 58px);
398
+ }
399
+ }
400
+
401
+ }
402
+
403
+ ion-row.ion-list-footer,
404
+ ion-row.mat-select-footer,
405
+ ion-row.mat-menu-footer,
406
+ ion-row.mat-autocomplete-footer,
407
+ mat-option.mat-autocomplete-footer {
408
+ /* Set footer as sticky*/
409
+ position: -webkit-sticky;
410
+ position: sticky;
411
+ bottom: 0;
412
+ z-index: 1001;
413
+ border-top: 1px solid #{$app-select-option-border-color};
414
+ background-color: var(--ion-toolbar-background, #{$ion-toolbar-background});
415
+ color: var(--ion-color-medium) !important; // not working on mobile form because the mat-option is disabled
416
+ @include font-size(12px);
417
+ font-weight: 500;
418
+ height: 20px;
419
+ min-height: 20px;
420
+ line-height: 20px;
421
+ opacity: 1 !important;
422
+
423
+ ion-col {
424
+ white-space: nowrap;
425
+ text-overflow: ellipsis;
426
+ }
427
+ }
428
+
429
+ ion-row {
430
+ --ion-grid-column-padding: 0;
431
+
432
+ ion-col {
433
+ --padding-start: 8px;
434
+ padding: 0 !important;
435
+ padding-left: var(--padding-start) !important;
436
+ text-overflow: ellipsis;
437
+ overflow: hidden;
438
+ white-space: nowrap;
439
+ }
440
+ }
441
+
442
+ .odd {
443
+ background: var(--ion-light-color-shade, $light);
444
+ }
445
+
446
+ .mat-mdc-option[no-padding],
447
+ mat-option[no-padding] {
448
+ padding: 0 !important;
449
+ }
450
+ }
451
+
452
+ // --------------------------------------------------
453
+ // Table > Filter expansion panel
454
+ // --------------------------------------------------
455
+
456
+ mat-expansion-panel {
457
+
458
+ &.filter-panel {
459
+
460
+ background: var(--ion-color-secondary50);
461
+ color: var(--ion-color-secondary50-contrast);
462
+ margin-bottom: 5px;
463
+
464
+ .form-container {
465
+ mat-form-field {
466
+ width: 100%;
467
+
468
+ .datetime-md {
469
+ padding: 0 !important;
470
+ }
471
+ }
472
+ }
473
+
474
+ mat-action-row {
475
+ ion-label {
476
+ line-height: 36px;
477
+ }
478
+ }
479
+ }
480
+
481
+ &.filter-panel-floating {
482
+ z-index: 999;
483
+ position: absolute;
484
+ top: 0;
485
+ left: 0;
486
+ right: 0;
487
+ }
488
+
489
+ &.filter-panel-pinned {
490
+ overflow-y: scroll;
491
+ }
492
+
493
+ .mat-expansion-panel-header,
494
+ mat-expansion-panel-header {
495
+ padding: var(--expansion-panel-header-padding, var(--expansion-panel-padding));
496
+ }
497
+ .mat-expansion-panel-body {
498
+ padding: var(--expansion-panel-padding, var(--ion-padding));
499
+ }
500
+ }
501
+
502
+ // --------------------------------------------------
503
+ // Form buttons bar
504
+ // --------------------------------------------------
505
+ app-form-buttons-bar {
506
+ --form-buttons-bar-buttons-width: 400px;
507
+ --form-buttons-bar-content-max-width: calc(100% - var(--form-buttons-bar-buttons-width) - 40px /*right menu toggle button*/);
508
+ .app-form-buttons-bar-content {
509
+ max-width: var(--form-buttons-bar-content-max-width);
510
+ }
511
+ }
512
+
513
+ // --------------------------------------------------
514
+ // Ion-select
515
+ // --------------------------------------------------
516
+
517
+ ion-popover.select-popover {
518
+ .popover-content {
519
+ min-width: calc(min(80%, 200px));
520
+ }
521
+ }
522
+
523
+ @media screen and (min-width: $screen-sm) {
524
+ ion-popover.select-popover {
525
+ .popover-content {
526
+ min-width: 300px;
527
+ }
528
+
529
+ ion-radio .radio-icon {
530
+ border: 0 !important;
531
+ }
532
+ }
533
+ }
534
+
535
+
536
+ // --------------------------------------------------
537
+ // Ionic list
538
+ // --------------------------------------------------
539
+ ion-list {
540
+ ion-item.ion-item-selected {
541
+ --ion-color-base: var(--ion-color-secondary100);
542
+ --ion-color-contrast: var(--ion-color-secondary100-contrast);
543
+
544
+ &:before {
545
+ background: var(--ion-color-base) !important;
546
+ color: var(--ion-color-contrast) !important;
547
+ }
548
+ }
549
+ }
550
+
551
+ // ------------------------
552
+ // Other material component
553
+
554
+ .flex-spacer,
555
+ .toolbar-spacer {
556
+ flex: 1 1 auto;
557
+ }
558
+
559
+ ion-toolbar {
560
+ --min-height: var(--ion-toolbar-height, 56px);
561
+ }
562
+ ion-toolbar[translucent] {
563
+ --background: transparent !important;
564
+ }
565
+
566
+ // --- mat-stepper component
567
+ mat-horizontal-stepper {
568
+ .mat-horizontal-stepper-header-container {
569
+ padding: 0;
570
+ }
571
+
572
+ .mat-horizontal-content-container {
573
+ padding: 0;
574
+ }
575
+ }
576
+
577
+
578
+ // Extra small device: Phones (<767px)
579
+ @media screen and (max-width: $screen-xs-max) {
580
+ mat-horizontal-stepper {
581
+ .mat-horizontal-stepper-header-container {
582
+ .mat-horizontal-stepper-header {
583
+ padding-left: 5px;
584
+ }
585
+
586
+ .mat-stepper-horizontal-line {
587
+ display: none;
588
+ }
589
+ }
590
+
591
+ .mat-horizontal-content-container {
592
+ padding: 0;
593
+ }
594
+ }
595
+ }
596
+
597
+ mat-button-toggle.mat-button-toggle-checked,
598
+ mat-button-toggle.mat-button-toggle-checked.mat-button-toggle-disabled {
599
+ background-color: var(--ion-color-light);
600
+ color: white;
601
+ }
602
+
603
+ // --------------------------------------------------
604
+ // Material menu
605
+ // --------------------------------------------------
606
+
607
+
608
+ .mat-mdc-menu-panel {
609
+
610
+ // Max width = 400px
611
+ &.mat-menu-size-400 {
612
+ min-width: unset;
613
+ width: 400px;
614
+ max-width: calc(90vw);
615
+ }
616
+ // Max width = 75vw
617
+ &.mat-menu-size-75vw {
618
+ min-width: unset;
619
+ width: calc(75vw);
620
+ max-width: calc(90vw);
621
+ }
622
+
623
+ // No padding
624
+ &.ion-no-padding {
625
+ .mat-mdc-menu-content {
626
+ padding: 0 !important;
627
+ }
628
+ }
629
+
630
+ // Small menu item (e.g. for actions on a table row)
631
+ &.mat-mdc-menu-item-small-height .mat-mdc-menu-item,
632
+ .mat-mdc-menu-item.mat-mdc-menu-item-small-height
633
+ {
634
+ padding: 0 8px;
635
+ height: 35px;
636
+ line-height: 35px;
637
+ }
638
+ // Reduce the font size, on label just inside a mat-menu (e.g. see trips.page.html)
639
+ .mat-mdc-menu-content > ion-label {
640
+ @include font-size(12px);
641
+ }
642
+
643
+ .mat-mdc-menu-content ion-item > ion-icon[slot="start"] {
644
+ margin-right: 16px;
645
+ vertical-align: middle;
646
+ }
647
+
648
+ // Menu title (e.g. see extraction map)
649
+ .mat-mdc-menu-item.mat-mdc-menu-title {
650
+ padding: 0 8px;
651
+ height: 27px;
652
+ line-height: 27px;
653
+ @include font-size(12px);
654
+ pointer-events: none;
655
+ color: var(--ion-color-medium, rgba(0, 0, 0, 0.38));
656
+ }
657
+ }
658
+
659
+ // --------------------------------------------------
660
+ // Alert
661
+ // --------------------------------------------------
662
+
663
+ ion-alert button.alert-button {
664
+ cursor: pointer;
665
+ }
666
+
667
+
668
+ // --------------------------------------------------
669
+ // Overlay
670
+ // --------------------------------------------------
671
+
672
+ .cdk-overlay-dark-backdrop {
673
+ background: rgba(var(--ion-backdrop-color-rgb, 0,0,0), var(--ion-backdrop-opacity, 0.32));
674
+ }
675
+
676
+ // --------------------------------------------------
677
+ // Date and time picker
678
+ // --------------------------------------------------
679
+ // Date picker
680
+ .mat-datepicker-content {
681
+ --mat-datepicker-calendar-container-background-color: var(--ion-background-color, #fff) !important;
682
+ --mat-datepicker-calendar-container-text-color: var(--ion-text-color, #000000) !important;
683
+ --mat-datepicker-calendar-date-text-color: var(--ion-text-color);
684
+ --mat-datepicker-calendar-body-label-text-color: var(--ion-color-step-500);
685
+ --mat-datepicker-calendar-header-text-color: var(--ion-color-step-500);
686
+ }
687
+ mat-calendar {
688
+ .mat-calendar-header {
689
+ background-color: var(--ion-color-secondary) !important;
690
+ color: var(--ion-color-secondary-contrast) !important;
691
+
692
+ button {
693
+ color: var(--ion-color-secondary-contrast) !important;
694
+ }
695
+ }
696
+
697
+ .mat-calendar-body-selected {
698
+ background-color: var(--ion-color-accent) !important;
699
+ color: var(--ion-color-accent-contrast) !important;
700
+ font-weight: bold;
701
+ }
702
+
703
+ .mat-calendar-arrow {
704
+ border-top-color: var(--ion-color-secondary-contrast) !important;
705
+ }
706
+ }
707
+
708
+ @media (orientation: landscape) {
709
+ .mat-datepicker-content-touch {
710
+ height: fit-content !important;
711
+ min-height: 310px;
712
+
713
+ .mat-calendar-controls {
714
+ margin-top: 0;
715
+ }
716
+ .mat-datepicker-content-container {
717
+ &.mat-datepicker-content-container-with-actions {
718
+ height: unset !important;
719
+ }
720
+ .mat-datepicker-actions {
721
+ background-color: var(--mat-datepicker-calendar-container-background-color);
722
+ margin-top: -12px;
723
+ }
724
+ }
725
+ }
726
+ }
727
+
728
+ // Time picker
729
+ .timepicker {
730
+ .timepicker-header {
731
+ // Change header color to 'secondary'
732
+ --mat-toolbar-container-background-color: var(--ion-color-secondary) !important;
733
+ }
734
+ }
735
+
736
+ // --------------------------------------------------
737
+ // Mat chip field
738
+ // --------------------------------------------------
739
+
740
+ .mat-mdc-form-field-type-mat-chip-grid {
741
+ .mat-mdc-form-field-infix {
742
+ --mdc-chip-container-height: 24px !important;
743
+ }
744
+ }
745
+
746
+
747
+ // --------------------------------------------------
748
+ // Pages
749
+ // --------------------------------------------------
750
+ ion-item {
751
+ ion-label.error {
752
+ line-height: 16px;
753
+ line-break: normal;
754
+ overflow: visible;
755
+ white-space: normal;
756
+ }
757
+ }
758
+
759
+ // --------------------------------------------------
760
+ // Modal
761
+ // --------------------------------------------------
762
+
763
+ ion-modal.stack-modal {
764
+ --box-shadow: 0 28px 48px rgba(0, 0, 0, 0.4);
765
+ --backdrop-opacity: var(--ion-backdrop-opacity, 0.32);
766
+ }
767
+
768
+ ion-modal.modal-large{
769
+ --min-height: calc(100% - 50px) !important;
770
+ --min-width: calc(100% - 100px) !important;
771
+ }
772
+ ion-modal.modal-fullscreen {
773
+ --min-height: calc(100%) !important;
774
+ --min-width: calc(100%) !important;
775
+ }
776
+
777
+
778
+ // --------------------------------------------------
779
+ // Popover
780
+ // --------------------------------------------------
781
+
782
+ .popover-large {
783
+ --min-width: calc(min(500px, 80%));
784
+ }
785
+
786
+ .popover-notifications {
787
+ --popover-top: 0;
788
+ --max-height: calc(90vh - 40px /* header + footer height */ - var(--popover-top, 0px) - var(--offset-y, 0px));
789
+
790
+ ion-item {
791
+ --ion-item-background-color-hover: var(--ion-color-light);
792
+ &.unread {
793
+ --ion-item-background: rgba(var(--ion-color-secondary100-rgb), 0.2);
794
+ --ion-item-background-color-hover: rgba(var(--ion-color-secondary100-rgb), 0.3);
795
+ }
796
+ }
797
+ }
798
+
799
+ // --------------------------------------------------
800
+ // Large button with icon floating on right
801
+ // --------------------------------------------------
802
+ .flex-margin ion-icon,
803
+ .flex-margin span {
804
+ margin-left: auto;
805
+ }
806
+
807
+ // --------------------------------------------------
808
+ // Icon tooltip, and title
809
+ // --------------------------------------------------
810
+ // Fix Button icon name overrides button's own title on mouse over
811
+ /*ion-icon[name='chatbox'] {
812
+ pointer-events: none !important;
813
+ }*/
814
+ .mat-cell {
815
+ /* smaller size, for the comment icon */
816
+ mat-icon.comment {
817
+ @include font-size(16pt);
818
+ height: 100%;
819
+ vertical-align: center;
820
+ color: var(--ion-color-tertiary, grey);
821
+
822
+ &.disabled {
823
+ color: var(--ion-color-medium, grey);
824
+ }
825
+ }
826
+ }
827
+
828
+ // --------------------------------------------------
829
+ // Icon inside text
830
+ // --------------------------------------------------
831
+ mat-icon,
832
+ ion-icon {
833
+ &.text-size {
834
+ font-size: 1em;
835
+ width: 1em;
836
+ height: 1em;
837
+ }
838
+ }
839
+ ion-button[expand="block"],
840
+ ion-button[expand="full"],
841
+ .mat-button,
842
+ .mat-raised-button {
843
+ mat-icon,
844
+ ion-icon {
845
+ &[slot] {
846
+ pointer-events: none;
847
+ width: 24px;
848
+ height: 24px;
849
+ }
850
+ &[slot='start'],
851
+ &[slot='end'] {
852
+ margin-left: unset;
853
+ margin-right: unset;
854
+ margin-top: 0;
855
+ margin-bottom: 0;
856
+ }
857
+ &t[slot='start'] {
858
+ margin-inline-start: -0.3em;
859
+ margin-inline-end: 0.3em;
860
+ }
861
+ &[slot='end'] {
862
+ margin-inline-start: 0.3em;
863
+ margin-inline-end: -0.3em;
864
+ }
865
+ &.ion-float-start[slot='start'] {
866
+ position: absolute;
867
+ left: 0;
868
+ }
869
+ &.ion-float-end[slot='end'] {
870
+ position: absolute;
871
+ right: 0;
872
+ }
873
+ }
874
+ }
875
+
876
+ // --------------------------------------------------
877
+ // Icon multiple
878
+ // --------------------------------------------------
879
+ ion-icon.icon-secondary,
880
+ mat-icon.icon-secondary,
881
+ .mat-mdc-icon-button .mat-icon.icon-secondary {
882
+ position: absolute;
883
+ left: 0;
884
+ }
885
+
886
+ // --------------------------------------------------
887
+ // Toast
888
+ // --------------------------------------------------
889
+ ion-toast {
890
+ --background: var(--ion-color-dark);
891
+ --color: var(--ion-color-dark-contrast);
892
+ --button-color: var(--ion-color-secondary);
893
+
894
+ &.secondary {
895
+ --background: var(--ion-color-secondary);
896
+ --color: var(--ion-color-secondary-contrast);
897
+ --button-color: var(--ion-color-tertiary);
898
+ }
899
+ &.accent {
900
+ --background: var(--ion-color-accent);
901
+ --color: var(--ion-color-accent-contrast);
902
+ --button-color: var(--ion-color-primary);
903
+ }
904
+ &.danger {
905
+ --background: var(--ion-color-danger);
906
+ --color: var(--ion-color-danger-contrast);
907
+ --button-color: var(--ion-color-primary);
908
+ }
909
+
910
+ /* -- workaround because toast animation failed */
911
+ --toast-max-height: 75px;
912
+
913
+ &.toast-stack-offset-1 {
914
+ --toast-stack-offset: 1;
915
+ }
916
+ &.toast-stack-offset-2 {
917
+ --toast-stack-offset: 2;
918
+ }
919
+ &.toast-stack-offset-3 {
920
+ --toast-stack-offset: 3;
921
+ }
922
+ &.toast-stack-offset-4 {
923
+ --toast-stack-offset: 4;
924
+ }
925
+
926
+ &.toast-stacked-top {
927
+ --toast-top: calc(var(--toast-stack-offset, 0) * var(--toast-max-height, 0));
928
+ transform: translateY(var(--toast-top));
929
+ }
930
+ &.toast-stacked-bottom {
931
+ --toast-bottom: calc(-1 * var(--toast-stack-offset, 0) * var(--toast-max-height, 0)) !important;
932
+ transform: translateY(var(--toast-bottom));
933
+ }
934
+ }
935
+
936
+ // --------------------------------------------------
937
+ // Refresher
938
+ // --------------------------------------------------
939
+ ion-refresher.refresher-native {
940
+ z-index: 1000;
941
+ }
942
+
943
+ // --------------------------------------------------
944
+ // Named filter
945
+ // --------------------------------------------------
946
+
947
+ ion-toolbar app-named-filter-selector,
948
+ mat-toolbar app-named-filter-selector {
949
+
950
+ // Hide subscript wrapper (will hide hint)
951
+ .mat-mdc-form-field-subscript-wrapper {
952
+ display: none;
953
+ visibility: hidden;
954
+ }
955
+ }