Skip to content

Conversation

@barshathakuri
Copy link
Contributor

@barshathakuri barshathakuri commented Sep 4, 2025

Changes

  • Remove old data fetching
  • Add Data from API

This PR doesn't introduce any

  • temporary files, auto-generated files or secret keys
  • build works
  • eslint issues
  • typescript issues
  • codegen errors
  • console.log meant for debugging
  • typos
  • unwanted comments
  • conflict markers

This PR includes

  • Translation

"footprint": "Ověření",
"change-detection": "Porovnání",
"project-card-progress-text": "{{progress, number}}% dokončeno",
"project-card-last-update": "{{date, datetime}}",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we might need this, because this also happens during the build time. Need to take this from env or something in github pages.

"change-detection": "Porovnání",
"project-card-progress-text": "{{progress, number}}% dokončeno",
"project-card-last-update": "{{date, datetime}}",
"project-card-contributors-text": "{{contributors}}",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This too

href = {
...href,
pathname: href.pathname?.replace('[locale]', locale),
pathname: href?.pathname?.replace('[locale]', locale),
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this necessary?

Comment on lines 142 to 144
.map((project) => (isDefined(project.exportHotTaskingManagerGeometries) ? {
...project,
coordinates: [project.coordinates[1], project.coordinates[0]] as LatLngTuple,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

need to add this further

Comment on lines 121 to 124
pagination: {
limit: PAGE_SIZE,
offset: 0,
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

add a note to remove this later

Comment on lines 778 to 780
// icon={
// projectTypeOptionsMap[project.projectType]?.icon
// }
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why is this commented out? Bring it back please. This can be worked on right now, I think.

</Tag>
)}
{project.number_of_users && (
{/* {project.number_of_users && (
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

uncomment and hardcode in the transformation earlier

import { gql } from 'graphql-request';
import { ProjectStatus, ProjectType } from 'utils/common';

export interface ProjectProperties {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Need to bring this from server/backend

export type ProjectType = 'FIND' | 'VALIDATE' | 'VALIDATE_IMAGE' | 'COMPARE' | 'COMPLETENESS';

export type ProjectType = 1 | 2 | 3 | 4 | 10;
// export type ProjectType = 1 | 2 | 3 | 4 | 10;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

remove this

.map(async (feature) => {
let geometry = null;

// 🔑 Fetch geometry from exportHotTaskingManagerGeometries URL
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh oh, i see chatgpt 😋

@@ -0,0 +1,4 @@
{
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there a reason we separated these out?

import Link from 'components/Link';

import styles from './styles.module.css';
import { ProjectProperties } from 'pages/queries';
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why fetching this type from queries and not directly from the generated schema?

projectTypeOptionsMap[project.project_type].icon
)}
icon={
projectTypeOptionsMap[project.projectType]?.icon
Copy link
Contributor

@subinasr subinasr Sep 10, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we need this mapping function?

.gitmodules Outdated
@@ -1,3 +1,6 @@
[submodule "server"]
path = server
url = git@github.com:mapswipe/python-mapswipe-workers.git
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We don't need the other one anymore.

export interface Props {
className?: string;
type: '1' | '2' | '3' | '10';
type: 'FIND' | 'VALIDATE' | 'VALIDATE_IMAGE' | 'COMPARE' | 'COMPLETENESS';
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please add icon for completeness as well.

),
},
]), [t]);
const projectTypeOptions: ProjectTypeOption[] = useMemo(() => ([
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We probably need other projectType options too. All of them.

icons={(
<ProjectTypeIcon
type="2"
type="VALIDATE"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Don't we need to add other project options here?

Comment on lines 252 to 268
10: {
key: 'COMPLETENESS',
label: t('validate-image'),
icon: (
<ProjectTypeIcon type="10" size="small" />
<ProjectTypeIcon type="VALIDATE_IMAGE" size="small" />
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Other project types are needed here too?

@barshathakuri barshathakuri force-pushed the feature/update-api branch 5 times, most recently from ffd7e45 to c59a742 Compare September 18, 2025 06:20
@barshathakuri barshathakuri force-pushed the feature/update-api branch 3 times, most recently from 9641647 to c642ac8 Compare September 19, 2025 09:19
@frozenhelium frozenhelium changed the base branch from main to project/private-api September 19, 2025 09:48
@barshathakuri barshathakuri force-pushed the feature/update-api branch 6 times, most recently from 76d0c00 to c642ac8 Compare September 19, 2025 13:27
@AdityaKhatri AdityaKhatri force-pushed the feature/update-api branch 2 times, most recently from 3cad8c7 to 953ca7d Compare September 25, 2025 10:34
@AdityaKhatri AdityaKhatri force-pushed the feature/update-api branch 4 times, most recently from 6823ec1 to 8eba61c Compare September 25, 2025 11:29
@AdityaKhatri AdityaKhatri force-pushed the feature/update-api branch 6 times, most recently from ede0d78 to 5e6a07d Compare October 9, 2025 09:35
@AdityaKhatri AdityaKhatri merged commit 4ff8350 into project/private-api Oct 9, 2025
1 check passed
@AdityaKhatri AdityaKhatri deleted the feature/update-api branch October 9, 2025 10:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants