Skip to content
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

Eng/notion messaging post update permissions #4221

Merged
merged 2 commits into from
Mar 8, 2024

Conversation

fontanierh
Copy link
Contributor

Description

fixes https://github.com/dust-tt/tasks/issues/161

Screenshot 2024-03-08 at 13 40 09

Risk

Deploy Plan

@fontanierh fontanierh force-pushed the eng/notion-massaging-post-update-permissions branch from ebcbd77 to 6435a64 Compare March 8, 2024 12:41
@fontanierh fontanierh requested a review from philipperolet March 8, 2024 12:41
@fontanierh fontanierh changed the title Eng/notion massaging post update permissions Eng/notion messaging post update permissions Mar 8, 2024
Copy link
Contributor

@philipperolet philipperolet left a comment

Choose a reason for hiding this comment

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

👍 2 coms tbd otherwise LGTM 🙏

<DataSourceDetailsModal
dataSource={dataSource}
visible={showDataSourceDetailsModal}
onClose={() => {
setShowDataSourceDetailsModal(false);
}}
onClick={() => {
void handleUpdatePermissions();
void handleUpdatePermissions().then(() => {
Copy link
Contributor

Choose a reason for hiding this comment

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

nit: I think we had something saying from now on we need to catch?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

In client-side code too ? I'm not sure what I would be doing with it (console.error is not actionable for the user)

Copy link
Contributor

Choose a reason for hiding this comment

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

yeah true

@@ -725,6 +727,7 @@ interface ConnectorUiConfig {
addDataButtonLabel: string | null;
displaySettingsButton: boolean;
guideLink: string | null;
onPostPermissionsUpdate?: () => ReactNode;
Copy link
Contributor

Choose a reason for hiding this comment

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

here, you're passing content
but convention is usually onSomething = handler on event something, somethingCallback => happens after something is done
I would do postPermissionsUpdateMessage?: ReactNode here
More generic but needs a bit refactoring thinking would be permissionsUpdateCallback?: () => void (but not sure it can work

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Agreed, changing.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Changed to just return a string as well.

@fontanierh fontanierh requested a review from philipperolet March 8, 2024 13:31
Copy link
Contributor

@philipperolet philipperolet left a comment

Choose a reason for hiding this comment

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

👍

@fontanierh fontanierh merged commit e7b1d26 into main Mar 8, 2024
5 checks passed
@fontanierh fontanierh deleted the eng/notion-massaging-post-update-permissions branch March 8, 2024 13:49
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.

2 participants