Commit 20f5e4f
authored
fix(import): group project-import warnings by reason (#1910)
* fix(import): group project-import warnings by reason
A File Geodatabase-backed ArcGIS Pro project made the import dialog list
257 separate lines, each reading "The layer's data format is not
supported". Every one of them had the same root cause, but nothing in
the dialog said so.
Warnings are now grouped by the message the user actually sees, largest
group first, so that project reads as one line ("245 layers: ...") with
the layer names behind a toggle. Grouping on the rendered message rather
than on the internal reason keeps two layer types that interpolate
different text apart, and merges anything that would otherwise render
two identical lines. The QGIS import dialog shares the component and
gets the same treatment.
FileGDB sources also get their own reason instead of a generic
"format", so the dialog names the format and points at Add Data ->
File Geodatabase (GDB), which the desktop build supports.
Ref #1904 (item 2)
* Address Claude review feedback
- Cover the `extension(workspace) === "gdb"` branch of the geodatabase
check with its own test, for both the vector and raster resolvers. The
earlier raster test only exercised the workspaceFactory branch.
- Recognize a `.gdb` workspace path in `resolveDataSource` too, so the
two resolvers agree on what a geodatabase is. A vector connection that
names no workspaceFactory previously fell through to a bare "format".
* Address CodeRabbit review feedback
- Fix the Vietnamese `arcgisImportReason.format` string, which read "Bản
đồ nhỏ" ("Minimap"). Pre-existing, but it is one of the messages this
dialog groups, so every non-geodatabase unsupported layer in a
Vietnamese session showed unrelated text.
- Say in the docs that the geodatabase reason covers rasters as well as
feature layers. The suggested wording (add "those layers" via Add Data
→ File Geodatabase) would have overpromised: that source filters to
feature classes carrying geometry and does not read geodatabase raster
datasets, so the sentence now names the limit instead of widening.
* Address review feedback: separate the geodatabase raster reason
- Report a raster stored in a .gdb under its own reason. It previously
shared the feature-class message, which sends the user to Add Data ->
File Geodatabase (GDB) -- a source that lists only feature classes
carrying geometry (GdbSource.tsx filters on geometry_type) and cannot
open a raster dataset. The raster message points at exporting to
GeoTIFF instead. Translated in all 19 catalogs. This also settles the
same concern raised against the Vietnamese file-geodatabase string:
that message now only ever reaches feature layers, in every locale.
- Pin the ordering of the geodatabase check against the missing-dataset
guard with a test. A .gdb workspace with no dataset name reports the
geodatabase rather than "missing-source", matching what the vector
resolver already did for the same connection: naming the geodatabase
is the actionable half, and the absent dataset name would not change
what the user has to do.
- Link the Show/Hide layer names toggle to the list it reveals with
aria-controls, alongside the aria-expanded it already set.
* Keep the aria-controls target in the DOM when collapsed
The names list was only rendered while expanded, so the toggle's
aria-controls pointed at a missing id in the collapsed state. It is now
always rendered and hidden with `hidden`, which keeps it out of the
accessibility tree while leaving the reference resolvable.
* Drop the unused sample field from the warning groups
Only the test read it; the dialog consumes message and layerNames. The
group type no longer needs a type parameter either.1 parent 722206a commit 20f5e4f
26 files changed
Lines changed: 497 additions & 27 deletions
File tree
- apps/geolibre-desktop/src
- components/layout/toolbar
- i18n/locales
- lib
- docs/user-guide
- tests
Lines changed: 78 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
Lines changed: 28 additions & 21 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
9 | 9 | | |
10 | 10 | | |
11 | 11 | | |
12 | | - | |
| 12 | + | |
13 | 13 | | |
14 | 14 | | |
15 | 15 | | |
16 | 16 | | |
17 | 17 | | |
| 18 | + | |
| 19 | + | |
18 | 20 | | |
| 21 | + | |
19 | 22 | | |
20 | 23 | | |
21 | 24 | | |
| |||
35 | 38 | | |
36 | 39 | | |
37 | 40 | | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
38 | 57 | | |
39 | 58 | | |
40 | 59 | | |
| |||
94 | 113 | | |
95 | 114 | | |
96 | 115 | | |
97 | | - | |
98 | | - | |
99 | | - | |
100 | | - | |
101 | | - | |
102 | | - | |
103 | | - | |
104 | | - | |
105 | | - | |
106 | | - | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
107 | 120 | | |
108 | 121 | | |
109 | 122 | | |
| |||
144 | 157 | | |
145 | 158 | | |
146 | 159 | | |
147 | | - | |
148 | | - | |
149 | | - | |
150 | | - | |
151 | | - | |
152 | | - | |
153 | | - | |
154 | | - | |
155 | | - | |
156 | | - | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
157 | 164 | | |
158 | 165 | | |
159 | 166 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2806 | 2806 | | |
2807 | 2807 | | |
2808 | 2808 | | |
| 2809 | + | |
| 2810 | + | |
| 2811 | + | |
| 2812 | + | |
| 2813 | + | |
| 2814 | + | |
| 2815 | + | |
| 2816 | + | |
2809 | 2817 | | |
2810 | 2818 | | |
2811 | 2819 | | |
2812 | 2820 | | |
| 2821 | + | |
| 2822 | + | |
2813 | 2823 | | |
2814 | 2824 | | |
2815 | 2825 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2623 | 2623 | | |
2624 | 2624 | | |
2625 | 2625 | | |
| 2626 | + | |
| 2627 | + | |
| 2628 | + | |
| 2629 | + | |
2626 | 2630 | | |
2627 | 2631 | | |
2628 | 2632 | | |
2629 | 2633 | | |
| 2634 | + | |
| 2635 | + | |
2630 | 2636 | | |
2631 | 2637 | | |
2632 | 2638 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2633 | 2633 | | |
2634 | 2634 | | |
2635 | 2635 | | |
| 2636 | + | |
| 2637 | + | |
| 2638 | + | |
| 2639 | + | |
2636 | 2640 | | |
2637 | 2641 | | |
2638 | 2642 | | |
2639 | 2643 | | |
| 2644 | + | |
| 2645 | + | |
2640 | 2646 | | |
2641 | 2647 | | |
2642 | 2648 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2623 | 2623 | | |
2624 | 2624 | | |
2625 | 2625 | | |
| 2626 | + | |
| 2627 | + | |
| 2628 | + | |
| 2629 | + | |
2626 | 2630 | | |
2627 | 2631 | | |
2628 | 2632 | | |
2629 | 2633 | | |
| 2634 | + | |
| 2635 | + | |
2630 | 2636 | | |
2631 | 2637 | | |
2632 | 2638 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2623 | 2623 | | |
2624 | 2624 | | |
2625 | 2625 | | |
| 2626 | + | |
| 2627 | + | |
| 2628 | + | |
| 2629 | + | |
2626 | 2630 | | |
2627 | 2631 | | |
2628 | 2632 | | |
2629 | 2633 | | |
| 2634 | + | |
| 2635 | + | |
2630 | 2636 | | |
2631 | 2637 | | |
2632 | 2638 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2623 | 2623 | | |
2624 | 2624 | | |
2625 | 2625 | | |
| 2626 | + | |
| 2627 | + | |
| 2628 | + | |
| 2629 | + | |
2626 | 2630 | | |
2627 | 2631 | | |
2628 | 2632 | | |
2629 | 2633 | | |
| 2634 | + | |
| 2635 | + | |
2630 | 2636 | | |
2631 | 2637 | | |
2632 | 2638 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2623 | 2623 | | |
2624 | 2624 | | |
2625 | 2625 | | |
| 2626 | + | |
| 2627 | + | |
| 2628 | + | |
| 2629 | + | |
2626 | 2630 | | |
2627 | 2631 | | |
2628 | 2632 | | |
2629 | 2633 | | |
| 2634 | + | |
| 2635 | + | |
2630 | 2636 | | |
2631 | 2637 | | |
2632 | 2638 | | |
| |||
0 commit comments