processing / p5.js-web-editor

The p5.js Editor is a website for creating p5.js sketches, with a focus on making coding accessible and inclusive for artists, designers, educators, beginners, and anyone else! You can create, share, or remix p5.js sketches without needing to download or configure anything.
https://editor.p5js.org
GNU Lesser General Public License v2.1
1.37k stars 1.32k forks source link

Feat/share modal, Allowing user to edit collection URLs slug #3047

Closed letscodedanish closed 6 months ago

letscodedanish commented 7 months ago

Fixes #3009

Changes:By adding the "Edit Slug" option and implementing the logic to handle slug editing in the ShareModal.jsx file, users now have the ability to edit the slug associated with the shared project. The logic ensures that the URL is updated accordingly, addressing the feature request of allowing users to edit slugs.

Suggest me the changes that are needed.

I have verified that this pull request:

raclim commented 6 months ago

Thanks for your work on this!

Although this PR seems like it carried over quite a bit of changes from another PR, I think this is a good start so far! It seems like that the changes are updating the URL slugs for sketches in the ShareModal.jsx file, but I do think that the original issue referenced specifically changing URL slugs for Collections, which I think appears in the CollectionShareButton.jsx file.

I think it could be interesting to potentially have slugs changed in both of these places, but before that happens I feel like this particular feature might need some more discussion for how this would be implemented and handling different scenarios (like how do we handle multiple collections trying to have the same URL slug? where specifically in the editor do we want these URL changes to happen?).

Due to the number of PRs we have at the moment I'm going to close this one for now. I'm sorry we can't get this in at the moment, but please feel free to revisit this once there's been more discussion or help flesh out what this feature would look further, thanks!