Skip to content

Commit e878ad4

Browse files
wxiaoguangGiteaBot
authored andcommitted
Improve frontend guideline (go-gitea#28711)
It has been a consensus for long time during reviewing: "avoiding inline styles as much as possible".
1 parent 7f833d8 commit e878ad4

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

docs/content/contributing/guidelines-frontend.en-us.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,11 +48,12 @@ We recommend [Google HTML/CSS Style Guide](https://google.github.io/styleguide/h
4848
10. Avoid mixing different events in one event listener, prefer to use individual event listeners for every event.
4949
11. Custom event names are recommended to use `ce-` prefix.
5050
12. Gitea's tailwind-style CSS classes use `gt-` prefix (`gt-relative`), while Gitea's own private framework-level CSS classes use `g-` prefix (`g-modal-confirm`).
51+
13. Avoid inline scripts & styles as much as possible, it's recommended to put JS code into JS files and use CSS classes. If inline scripts & styles are unavoidable, explain the reason why it can't be avoided.
5152

5253
### Accessibility / ARIA
5354

5455
In history, Gitea heavily uses Fomantic UI which is not an accessibility-friendly framework.
55-
Gitea uses some patches to make Fomantic UI more accessible (see the `aria.js` and `aria.md`),
56+
Gitea uses some patches to make Fomantic UI more accessible (see `aria.md` and related JS files),
5657
but there are still many problems which need a lot of work and time to fix.
5758

5859
### Framework Usage

0 commit comments

Comments
 (0)