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

frontend: Add create namespace ui #1727

Merged
merged 1 commit into from
Jul 16, 2024
Merged

frontend: Add create namespace ui #1727

merged 1 commit into from
Jul 16, 2024

Conversation

vyncent-t
Copy link
Contributor

@vyncent-t vyncent-t commented Feb 19, 2024

Add Create Namespace Feature to UI

fixes #1705
fixes #2055

Description

This PR introduces a new feature to the UI that allows users to create namespaces directly from the namespaces list view. A 'Create' button (represented by a + sign) has been added next to the title of the namespaces list view. Upon clicking this button, users are presented with a dialog box where they can input the name for the new namespace. Submitting this by clicking the 'Create' button will create the new namespace.

Changes

  • Added a 'Create' button (+ sign) next to the title of the namespaces list view.
  • Implemented a dialog box that prompts the user to enter the name of the new namespace.
  • Added functionality to create a new namespace upon clicking the 'Create' button in the dialog box.

Verification

  • Tested the 'Create' button to ensure it triggers the dialog box as expected.
  • Verified the dialog box accepts input and allows for the creation of a new namespace.
  • Confirmed that the new namespace appears in the namespaces list view upon creation.

Screenshots

image
image

@vyncent-t vyncent-t force-pushed the namespace-creation-ui branch from 4840332 to 9304a84 Compare February 19, 2024 21:15
@vyncent-t
Copy link
Contributor Author

  • push to fix build failures and translations

@vyncent-t vyncent-t added enhancement New feature or request frontend Issues related to the frontend labels Feb 19, 2024
@vyncent-t vyncent-t self-assigned this Feb 19, 2024
@vyncent-t vyncent-t marked this pull request as ready for review February 19, 2024 21:16
Copy link
Contributor

@knrt10 knrt10 left a comment

Choose a reason for hiding this comment

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

Some suggestions for translations

@vyncent-t vyncent-t marked this pull request as draft February 20, 2024 15:33
@vyncent-t vyncent-t requested a review from illume February 20, 2024 15:58
@vyncent-t vyncent-t force-pushed the namespace-creation-ui branch 2 times, most recently from 4103f4e to c199d1c Compare February 21, 2024 16:32
@vyncent-t vyncent-t marked this pull request as ready for review February 21, 2024 16:52
Copy link
Collaborator

@joaquimrocha joaquimrocha left a comment

Choose a reason for hiding this comment

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

Thanks Vincent.
Can you move the dialog/button into its own module? So it's more isolated and also in case we want to show it in a different view.

For consistency with the rest of the UX, I think the create button should trigger a cancellable action (like the Editor's apply / Delete / Scale / etc.).

Copy link
Collaborator

@joaquimrocha joaquimrocha left a comment

Choose a reason for hiding this comment

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

Req changes.

@vyncent-t vyncent-t force-pushed the namespace-creation-ui branch 2 times, most recently from d626eb9 to 564b556 Compare February 27, 2024 18:01
@vyncent-t
Copy link
Contributor Author

  • last push removes notes

@vyncent-t
Copy link
Contributor Author

vyncent-t commented Feb 27, 2024

last push

  • moved create namespace button and dialog to module
  • make create namespace process able to quit

@vyncent-t vyncent-t force-pushed the namespace-creation-ui branch from 564b556 to 763ae21 Compare February 28, 2024 18:41
@vyncent-t
Copy link
Contributor Author

  • last push is still needing some fixes, when creating a namespace item it is almost instant at this current implementation.

maybe artificially adding a timer would allow it to be slow enough to react to a quit action?

frontend/src/i18n/locales/de/translation.json Outdated Show resolved Hide resolved
@vyncent-t vyncent-t marked this pull request as draft March 1, 2024 13:48
@vyncent-t vyncent-t force-pushed the namespace-creation-ui branch 2 times, most recently from 486fc30 to 3e9fd01 Compare March 1, 2024 16:35
Copy link
Collaborator

@joaquimrocha joaquimrocha left a comment

Choose a reason for hiding this comment

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

Almost there. Left a few comments after trying it out.
Seems also like some storybook snapshots that are unrelated did get updated. So I am not sure if it's a legitimate side-effect or if we're now breaking the snapshot generation with this addon.

@joaquimrocha joaquimrocha self-requested a review July 3, 2024 12:55
Copy link
Collaborator

@joaquimrocha joaquimrocha left a comment

Choose a reason for hiding this comment

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

Approved by mistake. I meant it needs changes.

@vyncent-t vyncent-t force-pushed the namespace-creation-ui branch 3 times, most recently from 4e31e2e to b733add Compare July 8, 2024 15:22
@vyncent-t vyncent-t marked this pull request as ready for review July 8, 2024 16:10
@vyncent-t vyncent-t requested review from joaquimrocha and illume July 8, 2024 16:10
@vyncent-t
Copy link
Contributor Author

Still can't seem to source that build error?

@vyncent-t vyncent-t force-pushed the namespace-creation-ui branch 4 times, most recently from 37d4fcc to 8fddbd4 Compare July 10, 2024 17:45
@vyncent-t
Copy link
Contributor Author

rebased to current main and updated the "@types/lodash": "^4.17.4", to avoid compatibility error, its now "@types/lodash": "4.17.4",

@vyncent-t vyncent-t force-pushed the namespace-creation-ui branch 2 times, most recently from 47fac1a to 5ff103e Compare July 10, 2024 20:25
Copy link
Collaborator

@joaquimrocha joaquimrocha left a comment

Choose a reason for hiding this comment

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

Almost there. Found a few things in the code.

@vyncent-t vyncent-t force-pushed the namespace-creation-ui branch 2 times, most recently from 857ab27 to b866e3c Compare July 12, 2024 15:26
@vyncent-t vyncent-t force-pushed the namespace-creation-ui branch 2 times, most recently from 0059fff to 37970b7 Compare July 12, 2024 20:53
@vyncent-t vyncent-t requested a review from joaquimrocha July 12, 2024 22:22
Copy link
Collaborator

@joaquimrocha joaquimrocha left a comment

Choose a reason for hiding this comment

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

Just one last change needed.

Signed-off-by: Vincent T <vtaylor@microsoft.com>
@vyncent-t vyncent-t force-pushed the namespace-creation-ui branch from 37970b7 to 688ae64 Compare July 15, 2024 13:35
@joaquimrocha joaquimrocha merged commit 79211b7 into main Jul 16, 2024
18 checks passed
@joaquimrocha joaquimrocha deleted the namespace-creation-ui branch July 16, 2024 17:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request frontend Issues related to the frontend
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Provide option to create namespace Add special UI for creating a Namespace
5 participants