-
Notifications
You must be signed in to change notification settings - Fork 0
Extension Guidelines
fauxfiction edited this page Aug 6, 2011
·
1 revision
This page exists to outline a set of criteria that extensions should conform to in order to minimise incompatibility between Google+ extensions (except where direct UI clashes occur).
This is in being drafted
Extensions may assume the following:
- All elements displayed in the G+ stream (whether native or injected) have:
- the standard update element classes (
.tf,.Ekand.Omat present) and - a unique ID with the form
#update-[extension_id]-[post_id].
- the standard update element classes (
Extensions should conform to the following expectations to ensure compatibility:
- All elements injected into the DOM should be identifiable via class selectors and/or IDs containing a recognisable extension specific prefix.
- All elements injected into the DOM which are not intended to modify or supplement existing elements (ie. stand-alone injection blocks) should be contained within a parent element with the same characteristic classes as its siblings.
- It'd be nice for extensions to be able to traverse the DOM in a certain way which would be transparent to injected elements. Would this be doable via inverse jQuery (or better, native) selector matching (expect extensions to put a known selector in all injected container elements)? Matt
- Should injected stream elements have IDs with the form
#updateinj-[ext_id]-[unique_id](or something similar) so selector partial matching of"update-"and"updateinj"return the native posts and the injected posts respectively? Partial matching"update"would return all stream items. Matt