You are previewing jQuery UI 1.8 The User Interface Library for jQuery.
O'Reilly logo
jQuery UI 1.8 The User Interface Library for jQuery

Book Description

Build highly interactive web applications with ready-to-use widgets from the jQuery User Interface library

  • Packed with examples and clear explanations of how to easily design elegant and powerful front-end interfaces for your web applications

  • A section covering the widget factory including an in-depth example on how to build a custom jQuery UI widget

  • Updated code with significant changes and fixes to the previous edition

  • In Detail

    jQuery UI, the official suite of plugins for the jQuery JavaScript library, gives you a solid platform on which to build rich and engaging interfaces with maximum compatibility, stability, and a minimum of time and effort.

    jQuery UI has a series of ready-made user interface widgets and a comprehensive set of core interaction helpers to reduce the amount of code that you need to write to take a project from conception to completion.

    jQuery UI 1.8: The User Interface Library for jQuery has been specially revised for version 1.8 of jQuery UI. It is written to maximize your experience with the library by breaking down each component and walking you through examples that progressively build upon your knowledge, taking you from beginner to advanced usage in a series of easy-to-follow steps.

    Throughout the book, you'll learn how each component can be initialized in a basic default implementation and then customize and configure each component to tailor it to your application. You'll look at the configuration options and the methods exposed by each component's API to see how these can be used to bring out the best of the library. Each chapter will also show you the custom events fired by the component covered and how these events can be intercepted and acted upon.

    Table of Contents

    1. jQuery UI 1.8 The User Interface Library for jQuery
      1. jQuery UI 1.8
      2. Credits
      3. About the Author
      4. About the Reviewers
      5. www.PacktPub.com
        1. Support files, eBooks, discount offers and more
          1. Why Subscribe?
          2. Free Access for Packt account holders
      6. Preface
        1. What this book covers
        2. What you need for this book
        3. Who this book is for
        4. Conventions
        5. Reader feedback
        6. Customer support
          1. Downloading the example code
          2. Errata
          3. Piracy
          4. Questions
      7. 1. Introducing jQuery UI
        1. Downloading the library
        2. Setting up a development environment
        3. The structure of the library
        4. ThemeRoller
        5. Component categories
        6. Browser support
        7. Book examples
        8. Library licensing
        9. API introduction
          1. Events and callbacks
          2. Callback arguments
        10. Summary
      8. 2. The CSS Framework and Other Utilities
        1. The files that make up the framework
          1. jquery.ui.all.css
          2. jquery.ui.base.css
          3. jquery.ui.core.css
            1. The individual component framework files
          4. jquery.ui.theme.css
        2. Linking to the required framework files
        3. Using the framework classes
        4. Containers
        5. Interactions
        6. Icons
        7. Interaction cues
        8. Switching themes quickly and easily
        9. Overriding the theme
        10. The position utility
          1. Using the position utility
        11. Collision avoidance
        12. Positioning with a function
        13. The widget factory
        14. Creating the widget
        15. The _create function
        16. The common API methods
        17. Adding custom methods
        18. The widget style sheet
        19. Using the widget
        20. Summary
      9. 3. Using the Tabs Widget
        1. A basic tab implementation
        2. Tab CSS framework classes
        3. Applying a custom theme to the tabs
        4. Configurable options
          1. Selecting a tab
          2. Disabling a tab
          3. Transition effects
          4. Collapsible tabs
        5. Tab events
          1. Binding to events
        6. Using tab methods
          1. Enabling and disabling tabs
          2. Adding and removing tabs
          3. Simulating clicks
          4. Creating a tab carousel
          5. Getting and setting options
        7. AJAX tabs
        8. Changing the URL of a remote tab's content
        9. Reloading a remote tab
        10. Displaying data obtained via JSONP
        11. Summary
      10. 4. The Accordion Widget
        1. Accordion's structure
        2. Styling the accordion
        3. Configuring an accordion
          1. Changing the trigger event
          2. Changing the default active header
          3. Filling the height of its container
          4. Accordion animation
        4. Accordion events
          1. Using the change event
          2. The changestart event
        5. Accordion navigation
        6. Accordion methods
          1. Header activation
          2. Resizing an accordion panel
        7. Accordion interoperability
        8. Summary
      11. 5. The Dialog
        1. Creating a basic dialog
        2. Dialog options
          1. Showing the dialog
          2. The title of the dialog
          3. Modality
          4. Adding buttons
          5. Enabling dialog animations
          6. Configuring the dialog's dimensions
          7. Stacking
        3. Dialog's event model
        4. Controlling a dialog programmatically
          1. Toggling the dialog
        5. Getting data from the dialog
        6. Dialog interoperability
        7. Creating a dynamic image-based dialog
        8. Summary
      12. 6. The Slider Widget
        1. Implementing a slider
        2. Custom styling
        3. Configurable options
          1. Creating a vertical slider
          2. Minimum and maximum values
          3. Slider steps
          4. Slider animation
          5. Setting the slider's value
          6. Using multiple handles
          7. The range element
        4. Using slider's event API
        5. Slider methods
        6. Practical uses
        7. A color slider
        8. Summary
      13. 7. The Datepicker Widget
        1. The default datepicker
        2. Configurable options of the datepicker
          1. Basic options
          2. Minimum and maximum dates
          3. Changing the elements in the datepicker UI
          4. Adding a trigger button
          5. Configuring alternative animations
          6. Multiple months
          7. Changing the date format
          8. Updating an additional input element
          9. Localization
          10. Callback properties
        3. Utility methods
        4. Date picking methods
          1. Selecting a date programmatically
          2. Showing the datepicker in a dialog box
        5. An AJAX datepicker
        6. Summary
      14. 8. The Progressbar Widget
        1. The default progressbar implementation
        2. Progressbar's configuration options
          1. Setting progressbar's value
        3. Progressbar's event API
        4. Progressbar methods
        5. User initiated progress
        6. Rich uploads with progressbar
        7. Summary
      15. 9. The Button and Autocomplete Widgets
        1. The button widget
          1. Standard implementations
          2. Theming
          3. Configurable options
          4. Button icons
          5. Input icons
          6. Button events
          7. Buttonsets
            1. Checkbox buttonsets
            2. Radio buttonsets
          8. Button methods
        2. The autocomplete widget
          1. Working with local data sources
            1. Using an array of objects as the data source
          2. Configurable autocomplete options
            1. Configuring minimum length
            2. Appending the suggestion list to an alternative element
          3. Autocomplete events
          4. Autocomplete methods
          5. Working with remote data sources
            1. Using a string as the value of the source option
            2. Using a function as the value of the source option
          6. Displaying HTML in the list of suggestions
        3. Summary
      16. 10. Drag and Drop
        1. The deal with drag and droppables
        2. Draggables
          1. A basic drag implementation
        3. Configuring draggable options
          1. Using the configuration options
          2. Resetting dragged elements
          3. Drag handles
          4. Helper elements
          5. Constraining the drag
          6. Snapping
        4. Draggable event callbacks
        5. Draggable's methods
        6. Droppables
        7. Configuring droppables
          1. Configuring accepted draggables
          2. Tolerance
        8. Droppable event callbacks
          1. Scope
          2. Greedy
        9. Droppable methods
        10. A drag and drop game
        11. Summary
      17. 11. The Resizable Component
        1. A basic resizable
        2. Resizable options
          1. Configuring resize handles
          2. Adding additional handle images
          3. Defining size limits
          4. Resizing ghosts
          5. Containing the resize
          6. Handling aspect ratio
          7. Resizable animations
          8. Simultaneous resizing
          9. Preventing unwanted resizes
        3. Resizable callbacks
        4. Resizable methods
        5. Resizable tabs
        6. Summary
      18. 12. The Selectables Component
        1. Basic implementation
        2. Selectee classnames
        3. Configurable options of the selectable component
          1. Filtering selectables
          2. Canceling the selection
        4. Selectable callbacks
          1. Working with vast amounts of selectables
        5. Selectable methods
          1. Refreshing selectables
        6. A selectable image viewer
          1. Styling the image selector
          2. Adding the behaving
        7. Summary
      19. 13. The Sortables Component
        1. The default implementation
        2. Configuring sortable options
          1. Placeholders
          2. Sortable helpers
          3. Sortable items
          4. Connected lists
        3. Reacting to sortable events
        4. Connected callbacks
        5. Sortable methods
          1. Serializing
        6. Widget compatibility
          1. Adding draggables
        7. Summary
      20. 14. UI Effects
        1. The core effects file
          1. Using color animations
          2. Using class transitions
          3. Advanced easing
        2. Highlighting specified elements
          1. Additional effect arguments
        3. Bouncing
        4. Shaking an element
          1. Transferring an element's outline
        5. Element scaling
        6. Element explosion
        7. The puff effect
        8. The pulsate effect
        9. Dropping elements onto the page
        10. Sliding elements open or closed
          1. Using easing
        11. The window-blind effect
        12. Clipping elements
        13. Folding elements
        14. Summary