This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module TokenInputHelpers | |
THEME = '' # set to 'facebook' or 'mac' if using themes | |
def token_input(locator, options) | |
raise "Must pass a hash containing 'with'" unless options.is_a?(Hash) && options.has_key?(:with) | |
theme = THEME.present? ? "-#{THEME}" : "" | |
field = _find_fillable_field(locator) # find the field that will ultimately be sent to the server, the one the user intends to fill in |