Wiki source code of Application Guidelines

Last modified by Vincent Massol on 2024/02/26 17:56

Show last authors
1 {{warning}}
2
3 Also read more details about:
4
5 * [[Application Development Best Practices>>dev:Community.DevelopmentPractices||anchor="HApplicationDevelopment"]]
6 * [[Application Design>>contrib:Main.WebHome||anchor="HApplicationDesign"]]
7 * [[Code Style>>dev:Community.CodeStyle]], especially the [[XHTML/CSS>>dev:Community.XhtmlCssCodeStyle]] rules
8 * [[Special CSS Classes>>xwiki:Documentation.DevGuide.FrontendResources.SpecialCSSClasses.WebHome]]
9 {{/warning}}
10
11 == Access ==
12
13 1. Your application must be accessible through the "Applications" panel(((
14 Create a page containing a [[UI extension>>xwiki:Documentation.DevGuide.ExtensionPoint.AddApplicationUIX]] object (##XWiki.UIExtensionClass##).
15 )))
16 1. All technical pages must be ##hidden##
17 1. Make sure your application has a proper Translation page, read more about [[internationalising applications>>xwiki:Documentation.DevGuide.Tutorials.InternationalizingApplications.WebHome]].
18 1. Make sure your application pages are not orphans, use ##mvn xar:format## and ##mvn xar:verify## in order to assure these cases(((
19 (!) Standardise the parent, some applications are children of AppWithinMinutes.WebHome
20 )))
21
22 == Functionality ==
23
24 1. Your application should have at least CRUD (create, read, update, delete) operations(((
25 No matter what type of entities your application is managing, it is needed to have a way to create, view, edit and delete those types of entities for a basic functionality.
26 (!) Standardise the creation of artifacts (pop-up | create action)
27 (!) Standardise the display of artifacts (livetable | custom display)
28 )))
29 1. Consistent way of interacting with your application(((
30 If your application is handling multiple types of entities, you must have a symmetric and consistent way of interacting with them.
31 )))
32
33 == Styling ==
34
35 1. Check out the [[current skin>>xwiki:Documentation.AdminGuide.Skins]] supported by XWiki and make sure your application is following that particular style
36 1. Use [[ColorTheme variables>>extensions:Extension.Color Theme Application||anchor="HUsingColorThemesvariables"]] in order for your application to adjust to the theme color changes
37 1. All forms must be [[vertical aligned>>xwiki:Documentation.DevGuide.FrontendResources.VerticalForms.WebHome]]
38 1. Naming conventions(((
39 (!) Standardise application's homepage title
40 (!) Standardise usage of spaces for compound names (like Task Manager, File Manager, etc.)
41 (!) Standardise 'Applications' panel name entry
42 )))
43
44 == CSS ==
45
46 1. Careful using generic XWiki standard classes(((
47 This is particularly important if you are using [[SSX objects>>xwiki:Documentation.DevGuide.Tutorials.SkinExtensionsTutorial.WebHome]] with the "//Always on this wiki//" visibility option, because the rules will affect the whole wiki instance.
48 For example, using something like the following code is bad since it will affect all document titles:
49
50 {{code}}
51 #document-title {
52 color: red;
53 }
54 {{/code}}
55
56 A solution is to use "//on demand//" SSX or to prefix your style with a CSS class specific to your application. Also make sure your classes don't overlap with [[other CSS classes>>xwiki:Documentation.DevGuide.FrontendResources.SpecialCSSClasses.WebHome]] used by XWiki.
57 )))
58 1. Don't use ##inline## and ##!important## declarations(((
59 Always there is an alternative to rewrite the declarations, usually by adjusting the selector's [[specificity>>https://developer.mozilla.org/en-US/docs/Web/CSS/Specificity]]. Using ##inline## and ##!important## declarations will backfire on the long term when others will want to maintain and integrate your application.
60 )))

Get Connected