Skip to content

Commit

Permalink
Embed: fix copy button
Browse files Browse the repository at this point in the history
  • Loading branch information
mbarrenechea committed Oct 9, 2024
1 parent 3bee3e9 commit f447092
Show file tree
Hide file tree
Showing 11 changed files with 111 additions and 10 deletions.
2 changes: 1 addition & 1 deletion client/src/components/map/controls/embed/content.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ const EmbedContent = () => {
size="sm"
onClick={() => {
navigator.clipboard.writeText(
`<iframe src={"${URL}/embed?${searchParams.toString()}"} width="800px" height="600px" />`,
`<iframe src="${URL}/embed?${searchParams.toString()}" width="800px" height="600px" />`,
);
setCopiedIframe(true);
setTimeout(() => setCopiedIframe(false), 3000);
Expand Down
22 changes: 22 additions & 0 deletions client/src/types/generated/strapi.schemas.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3318,6 +3318,7 @@ export type SdgProjectsDataItemAttributesPillarDataAttributesProjectEditSuggesti
publishedAt?: string;
review_decision_details?: string;
review_status?: SdgProjectsDataItemAttributesPillarDataAttributesProjectEditSuggestionsDataItemAttributesReviewStatus;
reviewed_by?: string;
sdgs?: SdgProjectsDataItemAttributesPillarDataAttributesProjectEditSuggestionsDataItemAttributesSdgs;
source_country?: string;
status?: string;
Expand Down Expand Up @@ -3917,6 +3918,7 @@ export type SdgProjectsDataItemAttributesCountriesDataItemAttributesDatasetValue
publishedAt?: string;
review_decision_details?: string;
review_status?: SdgProjectsDataItemAttributesCountriesDataItemAttributesDatasetValuesDataItemAttributesDatasetDataAttributesLayersDataItemAttributesDatasetEditSuggestionDataAttributesReviewStatus;
reviewed_by?: string;
unit?: string;
updatedAt?: string;
updatedBy?: SdgProjectsDataItemAttributesCountriesDataItemAttributesDatasetValuesDataItemAttributesDatasetDataAttributesLayersDataItemAttributesDatasetEditSuggestionDataAttributesUpdatedBy;
Expand Down Expand Up @@ -5140,6 +5142,7 @@ export interface ProjectEditSuggestion {
publishedAt?: string;
review_decision_details?: string;
review_status: ProjectEditSuggestionReviewStatus;
reviewed_by?: string;
sdgs?: ProjectEditSuggestionSdgs;
source_country?: string;
status?: string;
Expand Down Expand Up @@ -5414,6 +5417,7 @@ export type ProjectEditSuggestionPillarDataAttributesProjectsDataItemAttributesS
publishedAt?: string;
review_decision_details?: string;
review_status?: ProjectEditSuggestionPillarDataAttributesProjectsDataItemAttributesSdgsDataItemAttributesProjectEditSuggestionsDataItemAttributesReviewStatus;
reviewed_by?: string;
sdgs?: ProjectEditSuggestionPillarDataAttributesProjectsDataItemAttributesSdgsDataItemAttributesProjectEditSuggestionsDataItemAttributesSdgs;
source_country?: string;
status?: string;
Expand Down Expand Up @@ -6163,6 +6167,7 @@ export type ProjectEditSuggestionCountriesDataItemAttributesDatasetValuesDataIte
publishedAt?: string;
review_decision_details?: string;
review_status?: ProjectEditSuggestionCountriesDataItemAttributesDatasetValuesDataItemAttributesDatasetDataAttributesLayersDataItemAttributesDatasetEditSuggestionDataAttributesReviewStatus;
reviewed_by?: string;
unit?: string;
updatedAt?: string;
updatedBy?: ProjectEditSuggestionCountriesDataItemAttributesDatasetValuesDataItemAttributesDatasetDataAttributesLayersDataItemAttributesDatasetEditSuggestionDataAttributesUpdatedBy;
Expand Down Expand Up @@ -6619,6 +6624,7 @@ export type ProjectEditSuggestionRequestData = {
project?: ProjectEditSuggestionRequestDataProject;
review_decision_details?: string;
review_status: ProjectEditSuggestionRequestDataReviewStatus;
reviewed_by?: string;
sdgs?: ProjectEditSuggestionRequestDataSdgsItem[];
source_country?: string;
status?: string;
Expand Down Expand Up @@ -6821,6 +6827,7 @@ export type ProjectPillarDataAttributesProjectsDataItemAttributesSdgsDataItemAtt
publishedAt?: string;
review_decision_details?: string;
review_status?: ProjectPillarDataAttributesProjectsDataItemAttributesSdgsDataItemAttributesProjectEditSuggestionsDataItemAttributesReviewStatus;
reviewed_by?: string;
sdgs?: ProjectPillarDataAttributesProjectsDataItemAttributesSdgsDataItemAttributesProjectEditSuggestionsDataItemAttributesSdgs;
source_country?: string;
status?: string;
Expand Down Expand Up @@ -7458,6 +7465,7 @@ export type ProjectCountriesDataItemAttributesDatasetValuesDataItemAttributesDat
publishedAt?: string;
review_decision_details?: string;
review_status?: ProjectCountriesDataItemAttributesDatasetValuesDataItemAttributesDatasetDataAttributesLayersDataItemAttributesDatasetEditSuggestionDataAttributesReviewStatus;
reviewed_by?: string;
unit?: string;
updatedAt?: string;
updatedBy?: ProjectCountriesDataItemAttributesDatasetValuesDataItemAttributesDatasetDataAttributesLayersDataItemAttributesDatasetEditSuggestionDataAttributesUpdatedBy;
Expand Down Expand Up @@ -8327,6 +8335,7 @@ export type PillarProjectsDataItemAttributesPillarDataAttributesProjectEditSugge
publishedAt?: string;
review_decision_details?: string;
review_status?: PillarProjectsDataItemAttributesPillarDataAttributesProjectEditSuggestionsDataItemAttributesReviewStatus;
reviewed_by?: string;
sdgs?: PillarProjectsDataItemAttributesPillarDataAttributesProjectEditSuggestionsDataItemAttributesSdgs;
source_country?: string;
status?: string;
Expand Down Expand Up @@ -8955,6 +8964,7 @@ export type PillarProjectsDataItemAttributesCountriesDataItemAttributesDatasetVa
publishedAt?: string;
review_decision_details?: string;
review_status?: PillarProjectsDataItemAttributesCountriesDataItemAttributesDatasetValuesDataItemAttributesDatasetDataAttributesLayersDataItemAttributesDatasetEditSuggestionDataAttributesReviewStatus;
reviewed_by?: string;
unit?: string;
updatedAt?: string;
updatedBy?: PillarProjectsDataItemAttributesCountriesDataItemAttributesDatasetValuesDataItemAttributesDatasetDataAttributesLayersDataItemAttributesDatasetEditSuggestionDataAttributesUpdatedBy;
Expand Down Expand Up @@ -11135,6 +11145,7 @@ export type LayerDatasetDataAttributesLayersDataItemAttributesDatasetEditSuggest
publishedAt?: string;
review_decision_details?: string;
review_status?: LayerDatasetDataAttributesLayersDataItemAttributesDatasetEditSuggestionDataAttributesReviewStatus;
reviewed_by?: string;
unit?: string;
updatedAt?: string;
updatedBy?: LayerDatasetDataAttributesLayersDataItemAttributesDatasetEditSuggestionDataAttributesUpdatedBy;
Expand Down Expand Up @@ -12393,6 +12404,7 @@ export type DatasetValueDatasetDataAttributesLayersDataItemAttributesDatasetEdit
publishedAt?: string;
review_decision_details?: string;
review_status?: DatasetValueDatasetDataAttributesLayersDataItemAttributesDatasetEditSuggestionDataAttributesReviewStatus;
reviewed_by?: string;
unit?: string;
updatedAt?: string;
updatedBy?: DatasetValueDatasetDataAttributesLayersDataItemAttributesDatasetEditSuggestionDataAttributesUpdatedBy;
Expand Down Expand Up @@ -13235,6 +13247,7 @@ export interface DatasetEditSuggestion {
publishedAt?: string;
review_decision_details?: string;
review_status: DatasetEditSuggestionReviewStatus;
reviewed_by?: string;
unit?: string;
updatedAt?: string;
updatedBy?: DatasetEditSuggestionUpdatedBy;
Expand Down Expand Up @@ -13337,6 +13350,7 @@ export type DatasetEditSuggestionCategoryDataAttributesDatasetEditSuggestionsDat
publishedAt?: string;
review_decision_details?: string;
review_status?: DatasetEditSuggestionCategoryDataAttributesDatasetEditSuggestionsDataItemAttributesReviewStatus;
reviewed_by?: string;
unit?: string;
updatedAt?: string;
updatedBy?: DatasetEditSuggestionCategoryDataAttributesDatasetEditSuggestionsDataItemAttributesUpdatedBy;
Expand Down Expand Up @@ -14245,6 +14259,7 @@ export type DatasetEditSuggestionRequestData = {
name?: string;
review_decision_details?: string;
review_status: DatasetEditSuggestionRequestDataReviewStatus;
reviewed_by?: string;
unit?: string;
value_type?: DatasetEditSuggestionRequestDataValueType;
};
Expand Down Expand Up @@ -14687,6 +14702,7 @@ export type DatasetLayersDataItemAttributesDatasetDataAttributesDatasetEditSugge
publishedAt?: string;
review_decision_details?: string;
review_status?: DatasetLayersDataItemAttributesDatasetDataAttributesDatasetEditSuggestionsDataItemAttributesReviewStatus;
reviewed_by?: string;
unit?: string;
updatedAt?: string;
updatedBy?: DatasetLayersDataItemAttributesDatasetDataAttributesDatasetEditSuggestionsDataItemAttributesUpdatedBy;
Expand Down Expand Up @@ -15579,6 +15595,7 @@ export type CountryDatasetValuesDataItemAttributesDatasetDataAttributesLayersDat
publishedAt?: string;
review_decision_details?: string;
review_status?: CountryDatasetValuesDataItemAttributesDatasetDataAttributesLayersDataItemAttributesDatasetEditSuggestionDataAttributesReviewStatus;
reviewed_by?: string;
unit?: string;
updatedAt?: string;
updatedBy?: CountryDatasetValuesDataItemAttributesDatasetDataAttributesLayersDataItemAttributesDatasetEditSuggestionDataAttributesUpdatedBy;
Expand Down Expand Up @@ -16599,6 +16616,7 @@ export type CollaboratorEditSuggestionCollaboratorDataAttributesCollaboratorEdit
publishedAt?: string;
review_decision_details?: string;
review_status?: CollaboratorEditSuggestionCollaboratorDataAttributesCollaboratorEditSuggestionsDataItemAttributesReviewStatus;
reviewed_by?: string;
type?: CollaboratorEditSuggestionCollaboratorDataAttributesCollaboratorEditSuggestionsDataItemAttributesType;
updatedAt?: string;
updatedBy?: CollaboratorEditSuggestionCollaboratorDataAttributesCollaboratorEditSuggestionsDataItemAttributesUpdatedBy;
Expand Down Expand Up @@ -16942,6 +16960,7 @@ export interface CollaboratorEditSuggestion {
publishedAt?: string;
review_decision_details?: string;
review_status: CollaboratorEditSuggestionReviewStatus;
reviewed_by?: string;
type?: CollaboratorEditSuggestionType;
updatedAt?: string;
updatedBy?: CollaboratorEditSuggestionUpdatedBy;
Expand Down Expand Up @@ -17312,6 +17331,7 @@ export type CollaboratorEditSuggestionRequestData = {
name?: string;
review_decision_details?: string;
review_status: CollaboratorEditSuggestionRequestDataReviewStatus;
reviewed_by?: string;
type?: CollaboratorEditSuggestionRequestDataType;
};

Expand Down Expand Up @@ -17494,6 +17514,7 @@ export type CollaboratorCollaboratorEditSuggestionsDataItemAttributes = {
publishedAt?: string;
review_decision_details?: string;
review_status?: CollaboratorCollaboratorEditSuggestionsDataItemAttributesReviewStatus;
reviewed_by?: string;
type?: CollaboratorCollaboratorEditSuggestionsDataItemAttributesType;
updatedAt?: string;
updatedBy?: CollaboratorCollaboratorEditSuggestionsDataItemAttributesUpdatedBy;
Expand Down Expand Up @@ -18427,6 +18448,7 @@ export type CategoryDatasetEditSuggestionsDataItemAttributes = {
publishedAt?: string;
review_decision_details?: string;
review_status?: CategoryDatasetEditSuggestionsDataItemAttributesReviewStatus;
reviewed_by?: string;
unit?: string;
updatedAt?: string;
updatedBy?: CategoryDatasetEditSuggestionsDataItemAttributesUpdatedBy;
Expand Down
27 changes: 18 additions & 9 deletions cms/config/sync/admin-role.strapi-super-admin.json
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,8 @@
"author",
"collaborator",
"image",
"review_decision_details"
"review_decision_details",
"reviewed_by"
]
},
"conditions": []
Expand Down Expand Up @@ -101,7 +102,8 @@
"author",
"collaborator",
"image",
"review_decision_details"
"review_decision_details",
"reviewed_by"
]
},
"conditions": []
Expand All @@ -119,7 +121,8 @@
"author",
"collaborator",
"image",
"review_decision_details"
"review_decision_details",
"reviewed_by"
]
},
"conditions": []
Expand Down Expand Up @@ -262,7 +265,8 @@
"layers",
"dataset",
"colors",
"review_decision_details"
"review_decision_details",
"reviewed_by"
]
},
"conditions": []
Expand Down Expand Up @@ -298,7 +302,8 @@
"layers",
"dataset",
"colors",
"review_decision_details"
"review_decision_details",
"reviewed_by"
]
},
"conditions": []
Expand All @@ -320,7 +325,8 @@
"layers",
"dataset",
"colors",
"review_decision_details"
"review_decision_details",
"reviewed_by"
]
},
"conditions": []
Expand Down Expand Up @@ -853,7 +859,8 @@
"pillar",
"sdgs",
"project",
"review_decision_details"
"review_decision_details",
"reviewed_by"
]
},
"conditions": []
Expand Down Expand Up @@ -894,7 +901,8 @@
"pillar",
"sdgs",
"project",
"review_decision_details"
"review_decision_details",
"reviewed_by"
]
},
"conditions": []
Expand All @@ -921,7 +929,8 @@
"pillar",
"sdgs",
"project",
"review_decision_details"
"review_decision_details",
"reviewed_by"
]
},
"conditions": []
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,20 @@
"sortable": true
}
},
"reviewed_by": {
"edit": {
"label": "reviewed_by",
"description": "",
"placeholder": "",
"visible": true,
"editable": true
},
"list": {
"label": "reviewed_by",
"searchable": true,
"sortable": true
}
},
"createdAt": {
"edit": {
"label": "createdAt",
Expand Down Expand Up @@ -240,6 +254,12 @@
"name": "review_decision_details",
"size": 6
}
],
[
{
"name": "reviewed_by",
"size": 6
}
]
]
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -192,6 +192,20 @@
"sortable": true
}
},
"reviewed_by": {
"edit": {
"label": "reviewed_by",
"description": "",
"placeholder": "",
"visible": true,
"editable": true
},
"list": {
"label": "reviewed_by",
"searchable": true,
"sortable": true
}
},
"createdAt": {
"edit": {
"label": "createdAt",
Expand Down Expand Up @@ -326,6 +340,12 @@
"name": "review_decision_details",
"size": 6
}
],
[
{
"name": "reviewed_by",
"size": 6
}
]
]
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -265,6 +265,20 @@
"sortable": true
}
},
"reviewed_by": {
"edit": {
"label": "reviewed_by",
"description": "",
"placeholder": "",
"visible": true,
"editable": true
},
"list": {
"label": "reviewed_by",
"searchable": true,
"sortable": true
}
},
"createdAt": {
"edit": {
"label": "createdAt",
Expand Down Expand Up @@ -419,6 +433,12 @@
"name": "review_decision_details",
"size": 6
}
],
[
{
"name": "reviewed_by",
"size": 6
}
]
]
}
Expand Down
6 changes: 6 additions & 0 deletions cms/config/sync/user-role.authenticated.json
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,12 @@
{
"action": "api::project-edit-suggestion.project-edit-suggestion.update"
},
{
"action": "api::project-status.project-status.find"
},
{
"action": "api::project-status.project-status.findOne"
},
{
"action": "api::project.project.find"
},
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{}
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{}
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{}
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{}

0 comments on commit f447092

Please sign in to comment.