From Ajax Patterns
These patterns are under Construction. They are in Preparation for Tools Europe 2008 conference. Michael Mahemoff will be covering these patterns in a keynote presentation for the general conference and in more detail at a keynote presentation at the Web 2.0 patterns workshop.
Principles for OpenSocial Application Development
Patterns for OpenSocial Application Development
Gadget UI Structure
- Multiple Tabs Use multiple tabs to offer multiple features in a single space.
- Accordion Use an accordion structure to offer multiple features in a single space.
- Popup Window Launch new pages in a popup window, so that the container retains sovereign posture.
- Canvas View Offer a canvas view to deliver more complex and demanding functionality.
- Auto-Refresh Keep container content up-to-date by auto-refreshing gadget data.
- Bundle Offer pre-prepared bundles of content
Gadget UI Elements
- Read-Write Element Optimise screen real estate by morphing display elements into editors for the same underlying data.
- Collapsible Element Optimise screen real estate by allowing users to collapse (and expand) certain elements.
- Inter-Gadget Drag-And-Drop Allow drag and drap of content between gadgets.
- OAuth Call Use delegated trust protocols, OAuth in particular, to access privileged services.
- Inter-Frame Call Use inter-frame calls to access privileged services.
- UI Customisation Offer preferences related to UI appearance, such as colour schemes, gadget height, and title.
- URL-Embedded Preferences Improve flexibility by allowing preferences to be embedded in the gadget URL.
- Autonomous Persistence Use JSON and hidden preferences to keep your gadget independent of persistence-based web services.
Packaging and Distribution
- Relative Path Reference For ease of distribution, dynamically calculate the URL of your gadget and then download scripts, stylesheets, images, and services from the same server, on demand.
- Embedded Image Employ the data: URI protocol to keep your gadget self-contained.
- First Move Allow a gadget user to initiate an interaction with another individual who may not yet be using (or signed up) with the gadget.
- Legacy URL-type Gadget For legacy web apps and older widget or portlet technology, begin gadget migration by wrapping it inside a simple URL-type gadget.
- Social Fixture Develop against a fixed social tree which you can replicate each run.
- Gadget Factory Instead of maintaining a static XML file, output your gadget from a script to stay DRY ("Don't Repeat Yourself") and improve flexibility.
Beyond scope - OpenSocial platform implementation patterns
These are patterns present in OpenSocial platforms such as Shindig and the portals - iGoogle, MySpace, Hi5, etc. They are out of scope from this project, as the project's sole audience at this time is developers of OpenSocial applications.
- Gadget Server
- OpenSocial API
- Sandboxing (distinct iframe domains, Caja)
- Set Title Feature
- Message Feature
- ... etc. ...
- Gadget Catalogue
- Gadget Feedback
- Gadget Sharing