https://bugzilla.wikimedia.org/show_bug.cgi?id=29028

Krinkle <[email protected]> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |[email protected]

--- Comment #8 from Krinkle <[email protected]> 2011-05-21 21:18:39 UTC ---
The some-rights thing (ie. part if you can block, part if you can delete etc.)
can probably be achieved by making the gadget more object oriented / modular
and splitting it up in multiple modules that can be plugged-in.

ResourceLoader take care of dependancies and make it into a single request
without duplicating code.

For example in ResourceLoader2 the following is likely possible:

Gadgets:

* Awesome-core
** hidden: true
** scripts: awesome.core.js (MediaWik:Gadget-awesome.core.js)

* Awesome-delete
** scripts: awesome.delete.js (MediaWiki:Gadget-awesome.delete.js)
** dependencies: awesome-core
** rights: delete

* Awesome-block
** scripts: awesome.block.js (MediaWiki:Gadget-awesome.block.js)
** dependencies: awesome-core
** rights: block


Preferences:
[_] Enable Awesomeness on the Delete-page
[_] Enable Awesomeness on the Rights-page 


-core will only be loaded once, and if one of the modules is enabled.


However "load if one of the following rights" is not possible yet (or planned
to), I'm not sure we should though, it makes it hard to make any assumptions
about the gadget later on. I think in most cases the above is what you actually
want and not "one of the following rights".

-- 
Configure bugmail: https://bugzilla.wikimedia.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.

_______________________________________________
Wikibugs-l mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l

Reply via email to