Conversation
0d4cfa5 to
e6e3f61
Compare
function as source of truth
- Convert resources to computed from savedResources - Add loadChart() to fetch chart and extract resource IDs from series - Add loadMissingResourcesForChart() to fetch individual resources - Add loadSelectedChart() triggered by Charger button - Switch form from reactive to ref - Move dataset initialization to top level - Fetch charts list at top level instead of onMounted
… debounced preview
Also add translations
5844cc1 to
2291cc3
Compare
|
|
||
| await page.getByLabel('Titre').fill('Test Chart') | ||
| await page.getByLabel('Description').fill('Test Description') | ||
| await page.waitForTimeout(500) |
There was a problem hiding this comment.
Do we need this timeout? Could we have something more precise?
There was a problem hiding this comment.
There is a debounce for the title / description
There was a problem hiding this comment.
I changed it to 300, I don't think we can do it differently
There was a problem hiding this comment.
There is no text appearing after the debounce?
There was a problem hiding this comment.
The chart title is updated but we can't select it for now, it's inside the canvas. Later it'll be replace with a p tag and one for the description too but this is not done yet
| // Check that this function return wanted data | ||
| const response = await getData(config, props.resource.id, page, sortConfig) | ||
| if ('data' in response && response.data && response.data.length > 0) { | ||
| if ('data' in response && response.data && 0 in response.data) { |
There was a problem hiding this comment.
I think it was a type issue, but I will double check
There was a problem hiding this comment.
Yep, the issue from the typecheck is :
Error: src/components/ResourceAccordion/Preview.vue(148,35): error TS2769: No overload matches this call.
Overload 1 of 2, '(o: {}): string[]', gave the following error.
Argument of type 'Record<string, unknown> | undefined' is not assignable to parameter of type '{}'.
Type 'undefined' is not assignable to type '{}'.
Overload 2 of 2, '(o: object): string[]', gave the following error.
Argument of type 'Record<string, unknown> | undefined' is not assignable to parameter of type 'object'.
Type 'undefined' is not assignable to type 'object'.
Now that we are live on demo, we can remove the base URLs
Fixes datagouv/data.gouv.fr#1972