-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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
A minimal change to replace data calls with attr as per guidelines #19900
Conversation
This affects the manage topics on a repository. Namely the done button once changes are made. I'm unhappy with the associated template, as there is an anchor element for something that should be a button. Since it must not be mixed, I haven't refactored the code into a Vue component yet. Signed-off-by: André Jaenisch <andre.jaenisch@posteo.de>
In my mind, there might be some options for rewriting the code into Vue:
And still in my mind:
|
About the mixed code, you can have a look at https://github.com/go-gitea/gitea/blob/main/web_src/js/components/DashboardRepoList.js I do not think it's a good practice to use Vue. The development guidelines are always open (actually, most of them were written recently), if you have ideas about how to make the code base more healthy and maintainable, please suggest 🙏 |
Please help to review #19901 |
I feel like this should be another issue (since discussion tab is disabled in this repo), but allow me to reply here for the time being:
https://storybook.js.org/ is becoming industry standard. How do you deal with disabled JavaScript in these cases? I've read elsewhere, that Gitea wants to be able to cater for these cases (and I assume, you don't want to run Server-Side Rendering).
I would suggest this for now, too. With the option to extract LESS files from Fomantic once the rewrite is complete (to drop the dependency entirely).
I agree. It will be a lot of work to detangle. Perhaps some meta-issue could be tracked with a task list listing all files and PRs that reference their refactor. As I mentioned in that chat, the sheer number of open PRs make me nervous that I would duplicate work.
I would suggest going with option 2 until the Fomantic dependency can be dropped. Looking at fomantic/Fomantic-UI#319 (comment) there is a transition planned to TypeScript and SASS (SASS is more popular then LESS, TypeScript has a learning curve). If option 3 is applied, perhaps open an issue to follow-up with a refactoring (or note that in the meta issue). I came across certain elements, that would make a good fit for a component. (I'm okay if you copy these conversations into a new issue and refernce this PR there) |
* giteaofficial/main: Move some repository related code into sub package (go-gitea#19711) A minimal change to replace data calls with attr as per guidelines (go-gitea#19900) Modernize JS build scripts (go-gitea#19824) [skip ci] Updated translations via Crowdin Update MAINTAINERS (go-gitea#19896)
There are discussions (as old as back to 2019) The Gitea UI problem is really a long story ..... |
…o-gitea#19900) This affects the manage topics on a repository. Namely the done button once changes are made. Signed-off-by: André Jaenisch <andre.jaenisch@posteo.de> Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com> Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
Tiny step towards #18345 (comment)
This affects the manage topics on a repository. Namely the done
button once changes are made.
gitea/templates/repo/home.tmpl
Lines 48 to 49 in d9b50e4
I'm unhappy with the associated template, as there is an anchor
element for something that should be a button. Since it must not be
mixed, I haven't refactored the code into a Vue component yet.
How are refactorings organised in this project?
Signed-off-by: André Jaenisch andre.jaenisch@posteo.de