-
Notifications
You must be signed in to change notification settings - Fork 40
Custom-Legend-Schema development Closes #2363 #3144
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: develop
Are you sure you want to change the base?
Custom-Legend-Schema development Closes #2363 #3144
Conversation
1b99479 to
f1c0e3f
Compare
jolevesq
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@jolevesq reviewed 5 of 7 files at r1, 3 of 3 files at r2, all commit messages.
Reviewable status: all files reviewed, 6 unresolved discussions (waiting on @HansAlainNyaba)
packages/geoview-custom-legend/src/custom-legend-style.ts line 9 at r2 (raw file):
* @returns {SxClasses} An object containing the style classes */ export const getSxClassesMain = (): SxClasses => ({
Same comment as above
packages/geoview-custom-legend/src/custom-legend.tsx line 28 at r2 (raw file):
const { cgpv } = window as TypeWindow; const { ui, reactUtilities } = cgpv; const { useState } = reactUtilities.react;
Why are you using useState?
packages/geoview-custom-legend/src/custom-legend.tsx line 33 at r2 (raw file):
const theme = ui.useTheme(); const sxClasses = getSxClasses(theme); const legendSxMain = getSxClassesMain();
Regroup all scClasses in one
packages/geoview-custom-legend/tsconfig.json line 10 at r2 (raw file):
}, "include": ["src"], "references": [{ "path": "../geoview-core" }]
Bring bac spaces
packages/geoview-custom-legend/schema.json line 29 at r2 (raw file):
}, "definitions": { "legendItem": {
Looks like we miss some properties fromt he RAMP custom legend config
packages/geoview-custom-legend/src/index.tsx line 65 at r2 (raw file):
return { id: `custom-legend`, tooltip: 'CustomLegend.title',
we need to provide aria-label, if not the same you can add tooltip
dd075b4 to
6e7dd82
Compare
HansAlainNyaba
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewable status: 5 of 9 files reviewed, 6 unresolved discussions (waiting on @jolevesq)
packages/geoview-custom-legend/schema.json line 29 at r2 (raw file):
Previously, jolevesq (Johann Levesque) wrote…
Looks like we miss some properties fromt he RAMP custom legend config
Done.
packages/geoview-custom-legend/src/custom-legend.tsx line 28 at r2 (raw file):
Previously, jolevesq (Johann Levesque) wrote…
Why are you using useState?
Done.
jolevesq
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@jolevesq reviewed 2 of 4 files at r3, all commit messages.
Reviewable status: 7 of 9 files reviewed, 6 unresolved discussions (waiting on @HansAlainNyaba)
packages/geoview-custom-legend/schema.json line 108 at r3 (raw file):
"description": "ID of the layer this legend item is associated with (if any)" }, "filter": {
What is this?
60ac68d to
75d2417
Compare
|
Previously, HansAlainNyaba (Hans A ) wrote…
I added most of them we now have ENTRY, ENTRY GROUP, INFO SECTION, UNBOUND LAYER and VISIBILITY SET in the schema |
75d2417 to
f6e5c29
Compare
f6e5c29 to
849401e
Compare
HansAlainNyaba
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@HansAlainNyaba made 4 comments.
Reviewable status: 3 of 9 files reviewed, 6 unresolved discussions (waiting on @jolevesq).
packages/geoview-custom-legend/schema.json line 108 at r3 (raw file):
Previously, jolevesq (Johann Levesque) wrote…
What is this?
I removed the filter property
packages/geoview-custom-legend/src/custom-legend.tsx line 33 at r2 (raw file):
Previously, jolevesq (Johann Levesque) wrote…
Regroup all scClasses in one
Done.
packages/geoview-custom-legend/src/custom-legend-style.ts line 9 at r2 (raw file):
Previously, jolevesq (Johann Levesque) wrote…
Same comment as above
Done.
packages/geoview-custom-legend/src/index.tsx line 65 at r2 (raw file):
Previously, jolevesq (Johann Levesque) wrote…
we need to provide aria-label, if not the same you can add tooltip
Done.
|
Previously, jolevesq (Johann Levesque) wrote…
?? I dont understand this |
jolevesq
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@jolevesq reviewed 2 files and all commit messages, made 6 comments, and resolved 3 discussions.
Reviewable status: 5 of 9 files reviewed, 7 unresolved discussions (waiting on @HansAlainNyaba).
packages/geoview-custom-legend/tsconfig.json line 10 at r2 (raw file):
Previously, HansAlainNyaba (Hans A ) wrote…
?? I dont understand this
[ { not [{
packages/geoview-custom-legend/src/index.tsx line 65 at r2 (raw file):
Previously, HansAlainNyaba (Hans A ) wrote…
Done.
When the same, not needed to set toltip
packages/geoview-custom-legend/schema.json line 7 at r5 (raw file):
"type": "object", "properties": { "id": {
This is not needed
packages/geoview-custom-legend/schema.json line 11 at r5 (raw file):
"description": "Unique identifier for the legend component" }, "enabled": {
Will not be needed, if package there, it is enable
packages/geoview-custom-legend/schema.json line 112 at r5 (raw file):
} }, "display": {
Not a good object, not needed + all children elements
packages/geoview-custom-legend/schema.json line 176 at r5 (raw file):
"description": "Schema version" }, "entry": {
This is suppose to be child of legendItemLIst... what you already ahev in legend item list is a sub type of one of this... Look at how RAMP is done
|
Previously, jolevesq (Johann Levesque) wrote…
OOK I removed "display" item |
|
Previously, jolevesq (Johann Levesque) wrote…
` |
|
Previously, jolevesq (Johann Levesque) wrote…
Done. |
HansAlainNyaba
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@HansAlainNyaba made 6 comments.
Reviewable status: 3 of 9 files reviewed, 7 unresolved discussions (waiting on @jolevesq).
packages/geoview-custom-legend/schema.json line 7 at r5 (raw file):
Previously, jolevesq (Johann Levesque) wrote…
This is not needed
Done.
packages/geoview-custom-legend/schema.json line 11 at r5 (raw file):
Previously, jolevesq (Johann Levesque) wrote…
Will not be needed, if package there, it is enable
Done.
packages/geoview-custom-legend/schema.json line 112 at r5 (raw file):
Previously, HansAlainNyaba (Hans A ) wrote…
OOK I removed "display" item
Done
packages/geoview-custom-legend/schema.json line 176 at r5 (raw file):
Previously, HansAlainNyaba (Hans A ) wrote…
`
We have entry in ramp
packages/geoview-custom-legend/tsconfig.json line 10 at r2 (raw file):
Previously, jolevesq (Johann Levesque) wrote…
[ { not [{
Done.
packages/geoview-custom-legend/src/index.tsx line 65 at r2 (raw file):
Previously, HansAlainNyaba (Hans A ) wrote…
Done.
What need to be the same? tooltip == "aria-label" I dont understand
jolevesq
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@jolevesq reviewed 3 files and all commit messages, made 4 comments, and resolved 6 discussions.
Reviewable status: 6 of 9 files reviewed, 4 unresolved discussions (waiting on @HansAlainNyaba).
packages/geoview-custom-legend/schema.json line 176 at r5 (raw file):
Previously, HansAlainNyaba (Hans A ) wrote…
We have entry in ramp
Yes but need to be a child on legendList. In your PR it is totally disconnected from the array of element
packages/geoview-custom-legend/src/custom-legend.tsx line 20 at r6 (raw file):
} interface FilterConfig {
What is this for?
packages/geoview-custom-legend/src/custom-legend.tsx line 35 at r6 (raw file):
visible?: boolean; layerId?: string; filter?: FilterConfig;
This is not use...
packages/geoview-custom-legend/src/custom-legend-style.ts line 10 at r6 (raw file):
*/ export const getSxClasses = <T extends Record<string, unknown>>(theme: T): SxClasses => { const typedTheme = theme as unknown as {
Theme is in the core... you are not able to reuse?
6a45729 to
e22eee4
Compare
HansAlainNyaba
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@HansAlainNyaba made 4 comments.
Reviewable status: 4 of 9 files reviewed, 4 unresolved discussions (waiting on @jolevesq).
packages/geoview-custom-legend/schema.json line 176 at r5 (raw file):
Previously, jolevesq (Johann Levesque) wrote…
Yes but need to be a child on legendList. In your PR it is totally disconnected from the array of element
Done.
packages/geoview-custom-legend/src/custom-legend.tsx line 20 at r6 (raw file):
Previously, jolevesq (Johann Levesque) wrote…
What is this for?
copilot garbage.. will remove it
packages/geoview-custom-legend/src/custom-legend.tsx line 35 at r6 (raw file):
Previously, jolevesq (Johann Levesque) wrote…
This is not use...
Done.
packages/geoview-custom-legend/src/custom-legend-style.ts line 10 at r6 (raw file):
Previously, jolevesq (Johann Levesque) wrote…
Theme is in the core... you are not able to reuse?
another complication from copilot will do different
e22eee4 to
4eca7ba
Compare
HansAlainNyaba
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@HansAlainNyaba made 1 comment.
Reviewable status: 4 of 9 files reviewed, 4 unresolved discussions (waiting on @jolevesq).
packages/geoview-custom-legend/schema.json line 176 at r5 (raw file):
Previously, HansAlainNyaba (Hans A ) wrote…
Done.
the entry is now under legendlist
Description
Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context. List any dependencies that are required for this change.
Fixes # (issue)
Type of change
How Has This Been Tested?
Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce.
Add the URL for your deploy!
https://hansalainnyaba.github.io/geoview/demos-navigator.html?config=./configs/navigator/demos/17-package-custom-legend.json
Checklist:
I have made corresponding changes to the documentationI have added tests that prove my fix is effective or that my feature worksNew and existing unit tests pass locally with my changesThis change is