From 980e4deb63ad5b709ee27cba9d3863badcf31dd4 Mon Sep 17 00:00:00 2001 From: Daniel Palacio Date: Wed, 31 Oct 2012 16:51:15 -0500 Subject: [PATCH] Switch to coffeescript, and fix Rakefile Change the library to coffeescript and compile it using rake compile. This will compile all the assets and minimize it for general consumption. --- .rvmrc | 48 ++ .rvmrc.10.31.2012-14:58:51 | 48 ++ Gemfile | 9 + Gemfile.lock | 30 + Rakefile | 36 +- sample/login.html | 19 + sample/register.html | 20 + sample/sample.css | 10 + src/flags.authy.css | 2 +- src/form.authy.coffee | 388 +++++++++++ src/form.authy.css | 2 + src/form.authy.js | 1318 ++++++++++++++++++++++++++---------- src/form.authy.min.css | 2 +- src/form.authy.min.js | 2 +- src/images/icon.png | Bin 789 -> 1070 bytes test.html | 25 - 16 files changed, 1551 insertions(+), 408 deletions(-) create mode 100644 .rvmrc create mode 100644 .rvmrc.10.31.2012-14:58:51 create mode 100644 Gemfile create mode 100644 Gemfile.lock create mode 100644 sample/login.html create mode 100644 sample/register.html create mode 100644 sample/sample.css create mode 100644 src/form.authy.coffee delete mode 100644 test.html diff --git a/.rvmrc b/.rvmrc new file mode 100644 index 0000000..d6f8cca --- /dev/null +++ b/.rvmrc @@ -0,0 +1,48 @@ +#!/usr/bin/env bash + +# This is an RVM Project .rvmrc file, used to automatically load the ruby +# development environment upon cd'ing into the directory + +# First we specify our desired [@], the @gemset name is optional, +# Only full ruby name is supported here, for short names use: +# echo "rvm use 1.9.3" > .rvmrc +environment_id="ruby-1.9.3-p194@authy-forms-helper" + +# Uncomment the following lines if you want to verify rvm version per project +# rvmrc_rvm_version="1.14.10 (master)" # 1.10.1 seams as a safe start +# eval "$(echo ${rvm_version}.${rvmrc_rvm_version} | awk -F. '{print "[[ "$1*65536+$2*256+$3" -ge "$4*65536+$5*256+$6" ]]"}' )" || { +# echo "This .rvmrc file requires at least RVM ${rvmrc_rvm_version}, aborting loading." +# return 1 +# } + +# First we attempt to load the desired environment directly from the environment +# file. This is very fast and efficient compared to running through the entire +# CLI and selector. If you want feedback on which environment was used then +# insert the word 'use' after --create as this triggers verbose mode. +if [[ -d "${rvm_path:-$HOME/.rvm}/environments" + && -s "${rvm_path:-$HOME/.rvm}/environments/$environment_id" ]] +then + \. "${rvm_path:-$HOME/.rvm}/environments/$environment_id" + [[ -s "${rvm_path:-$HOME/.rvm}/hooks/after_use" ]] && + \. "${rvm_path:-$HOME/.rvm}/hooks/after_use" || true +else + # If the environment file has not yet been created, use the RVM CLI to select. + rvm --create "$environment_id" || { + echo "Failed to create RVM environment '${environment_id}'." + return 1 + } +fi + +# If you use bundler, this might be useful to you: +# if [[ -s Gemfile ]] && { +# ! builtin command -v bundle >/dev/null || +# builtin command -v bundle | GREP_OPTIONS= \grep $rvm_path/bin/bundle >/dev/null +# } +# then +# printf "%b" "The rubygem 'bundler' is not installed. Installing it now.\n" +# gem install bundler +# fi +# if [[ -s Gemfile ]] && builtin command -v bundle >/dev/null +# then +# bundle install | GREP_OPTIONS= \grep -vE '^Using|Your bundle is complete' +# fi diff --git a/.rvmrc.10.31.2012-14:58:51 b/.rvmrc.10.31.2012-14:58:51 new file mode 100644 index 0000000..6156928 --- /dev/null +++ b/.rvmrc.10.31.2012-14:58:51 @@ -0,0 +1,48 @@ +#!/usr/bin/env bash + +# This is an RVM Project .rvmrc file, used to automatically load the ruby +# development environment upon cd'ing into the directory + +# First we specify our desired [@], the @gemset name is optional, +# Only full ruby name is supported here, for short names use: +# echo "rvm use 1.9.3" > .rvmrc +environment_id="ruby-1.9.3-p194@c" + +# Uncomment the following lines if you want to verify rvm version per project +# rvmrc_rvm_version="1.14.10 (master)" # 1.10.1 seams as a safe start +# eval "$(echo ${rvm_version}.${rvmrc_rvm_version} | awk -F. '{print "[[ "$1*65536+$2*256+$3" -ge "$4*65536+$5*256+$6" ]]"}' )" || { +# echo "This .rvmrc file requires at least RVM ${rvmrc_rvm_version}, aborting loading." +# return 1 +# } + +# First we attempt to load the desired environment directly from the environment +# file. This is very fast and efficient compared to running through the entire +# CLI and selector. If you want feedback on which environment was used then +# insert the word 'use' after --create as this triggers verbose mode. +if [[ -d "${rvm_path:-$HOME/.rvm}/environments" + && -s "${rvm_path:-$HOME/.rvm}/environments/$environment_id" ]] +then + \. "${rvm_path:-$HOME/.rvm}/environments/$environment_id" + [[ -s "${rvm_path:-$HOME/.rvm}/hooks/after_use" ]] && + \. "${rvm_path:-$HOME/.rvm}/hooks/after_use" || true +else + # If the environment file has not yet been created, use the RVM CLI to select. + rvm --create "$environment_id" || { + echo "Failed to create RVM environment '${environment_id}'." + return 1 + } +fi + +# If you use bundler, this might be useful to you: +# if [[ -s Gemfile ]] && { +# ! builtin command -v bundle >/dev/null || +# builtin command -v bundle | GREP_OPTIONS= \grep $rvm_path/bin/bundle >/dev/null +# } +# then +# printf "%b" "The rubygem 'bundler' is not installed. Installing it now.\n" +# gem install bundler +# fi +# if [[ -s Gemfile ]] && builtin command -v bundle >/dev/null +# then +# bundle install | GREP_OPTIONS= \grep -vE '^Using|Your bundle is complete' +# fi diff --git a/Gemfile b/Gemfile new file mode 100644 index 0000000..8fbf005 --- /dev/null +++ b/Gemfile @@ -0,0 +1,9 @@ +source :rubygems + +gem "yuicompressor" +gem "coffee-script" +gem "sass" +gem "haml" +gem 'yui-compressor' + + diff --git a/Gemfile.lock b/Gemfile.lock new file mode 100644 index 0000000..282418e --- /dev/null +++ b/Gemfile.lock @@ -0,0 +1,30 @@ +GEM + remote: http://rubygems.org/ + specs: + POpen4 (0.1.4) + Platform (>= 0.4.0) + open4 + Platform (0.4.0) + coffee-script (2.2.0) + coffee-script-source + execjs + coffee-script-source (1.4.0) + execjs (1.4.0) + multi_json (~> 1.0) + haml (3.1.7) + multi_json (1.3.6) + open4 (1.3.0) + sass (3.2.1) + yui-compressor (0.9.6) + POpen4 (>= 0.1.4) + yuicompressor (1.2.0) + +PLATFORMS + ruby + +DEPENDENCIES + coffee-script + haml + sass + yui-compressor + yuicompressor diff --git a/Rakefile b/Rakefile index bd70b42..35b67db 100644 --- a/Rakefile +++ b/Rakefile @@ -1,9 +1,19 @@ +namespace :coffee do + desc "Compile" + task :compile do + require 'coffee-script' + puts "Compiling Coffeescript" + + js = CoffeeScript.compile File.read("#{Dir.pwd}/src/form.authy.coffee") + File.open("#{Dir.pwd}/src/form.authy.js", 'w') { |file| file.write(js) } + end +end namespace :css do desc "Build countries flags css" task :countries do File.open("src/flags.authy.css", "w") do |f| - f.puts "// THIS FILE IS AUTOGENERATED. PLEASE DO NOT MODIFIED IT" + f.puts "/* THIS FILE IS AUTOGENERATED. PLEASE DO NOT MODIFIED IT */" Dir["src/images/flags/*.gif"].each do |flag| name = File.basename(flag, ".gif") f.puts ".flag_#{name} { background: url('images/flags/#{name}.gif') no-repeat 0px center; }" @@ -13,20 +23,32 @@ namespace :css do end desc "Compile" - task :compile => ["css:countries"] do - system "cat src/flags.authy.css src/form.authy.css | yuicompressor --type css -o src/form.authy.min.css" + task :compress => ["css:countries"] do + puts "Compressing css" + require "yui/compressor" + css = File.read("#{Dir.pwd}/src/flags.authy.css") + css += "\n" + css += File.read("#{Dir.pwd}/src/form.authy.css") + + compressor = YUI::CssCompressor.new + min_css = compressor.compress(css) + File.open("#{Dir.pwd}/src/form.authy.min.css", 'w') { |file| file.write(min_css) } end end namespace :js do desc "Compile" - task :compile do - system "cat src/form.authy.js | yuicompressor --type js -o src/form.authy.min.js" + task :compress do + puts "Compressing javascript" + js = File.read("#{Dir.pwd}/src/form.authy.js") + compressor = YUI::JavaScriptCompressor.new + min_js = compressor.compress(js) + File.open("#{Dir.pwd}/src/form.authy.min.js", 'w') { |file| file.write(min_js) } end end -task :compile => ["css:compile", "js:compile"] do +task :compile => ["coffee:compile","css:compress", "js:compress"] do end task :package => ["compile"] do @@ -34,4 +56,4 @@ task :package => ["compile"] do system "cd src; zip form.authy.zip form.authy.min.js form.authy.min.css images/**/*; mv form.authy.zip .." end -task :default => :compile \ No newline at end of file +task :default => :compile diff --git a/sample/login.html b/sample/login.html new file mode 100644 index 0000000..d0fa00a --- /dev/null +++ b/sample/login.html @@ -0,0 +1,19 @@ + + + + + + + + + + + + diff --git a/sample/register.html b/sample/register.html new file mode 100644 index 0000000..f8ef068 --- /dev/null +++ b/sample/register.html @@ -0,0 +1,20 @@ + + + + + + + + + + + + diff --git a/sample/sample.css b/sample/sample.css new file mode 100644 index 0000000..9ac6935 --- /dev/null +++ b/sample/sample.css @@ -0,0 +1,10 @@ +.login-form { + margin-top: 10em; + text-align: center; + line-height: 2em; + +} + +.login-form input { + width: 180px; +} diff --git a/src/flags.authy.css b/src/flags.authy.css index 7776eea..115ad3b 100644 --- a/src/flags.authy.css +++ b/src/flags.authy.css @@ -1,4 +1,4 @@ -// THIS FILE IS AUTOGENERATED. PLEASE DO NOT MODIFIED IT +/* THIS FILE IS AUTOGENERATED. PLEASE DO NOT MODIFIED IT */ .flag_af93 { background: url('images/flags/af93.gif') no-repeat 0px center; } .flag_al213 { background: url('images/flags/al213.gif') no-repeat 0px center; } .flag_al355 { background: url('images/flags/al355.gif') no-repeat 0px center; } diff --git a/src/form.authy.coffee b/src/form.authy.coffee new file mode 100644 index 0000000..715a7d6 --- /dev/null +++ b/src/form.authy.coffee @@ -0,0 +1,388 @@ +Authy = {} + +# Fix Internet Explorer by defining getElementsByClassName +unless document.getElementsByClassName? + document.getElementsByClassName = (className, parentElement) -> + children = (parentElement || document.body).getElementsByTagName("*") + elements = [] + child = undefined + i = 0 + length = children.length + + while i < length + child = children[i] + elements.push child unless (" " + child.className + " ").indexOf(" " + className + " ") is -1 + i++ + return elements + + HTMLDivElement::getElementsByClassName = (className) -> + return document.getElementsByClassName className, this + +Authy.UI = -> + + # Attributes + self = this + tooltipTitle = "Authy Help Tooltip" + tooltipMessage = "This is a help tooltip for your users. You can set the message by doing: authyUI.setTooltip(\"title\", \"message\");" + + + countriesList = [ + {"country":"United States of America","code":"1"},{"country":"Canada","code":"1"},{"country":"Russia","code":"7"},{"country":"Kazakhstan","code":"7"}, + {"country":"Egypt","code":"20"},{"country":"South Africa","code":"27"},{"country":"Greece","code":"30"},{"country":"Netherlands","code":"31"}, + {"country":"Belgium","code":"32"},{"country":"France","code":"33"},{"country":"Spain","code":"34"},{"country":"Hungary","code":"36"}, + {"country":"Italy","code":"39"},{"country":"Romania","code":"40"},{"country":"Switzerland","code":"41"},{"country":"Austria","code":"43"}, + {"country":"United Kingdom","code":"44"},{"country":"Guernsey","code":"44"},{"country":"Isle of Man","code":"44"},{"country":"Jersey","code":"44"}, + {"country":"Denmark","code":"45"},{"country":"Sweden","code":"46"},{"country":"Norway","code":"47"},{"country":"Poland","code":"48"}, + {"country":"Germany","code":"49"},{"country":"Peru","code":"51"},{"country":"Mexico","code":"52"},{"country":"Cuba","code":"53"}, + {"country":"Argentina","code":"54"},{"country":"Brazil","code":"55"},{"country":"Chile","code":"56"},{"country":"Colombia","code":"57"}, + {"country":"Venezuela","code":"58"},{"country":"Malaysia","code":"60"},{"country":"Australia","code":"61"},{"country":"Indonesia","code":"62"}, + {"country":"Philippines","code":"63"},{"country":"New Zealand","code":"64"},{"country":"Singapore","code":"65"},{"country":"Thailand","code":"66"}, + {"country":"Japan","code":"81"},{"country":"Korea (South)","code":"82"},{"country":"Vietnam","code":"84"},{"country":"China","code":"86"}, + {"country":"Turkey","code":"90"},{"country":"India","code":"91"},{"country":"Pakistan","code":"92"},{"country":"Afghanistan","code":"93"}, + {"country":"Sri Lanka","code":"94"},{"country":"Myanmar","code":"95"},{"country":"Iran","code":"98"},{"country":"Morocco","code":"212"}, + {"country":"Algeria","code":"213"},{"country":"Tunisia","code":"216"},{"country":"Libya","code":"218"},{"country":"Gambia","code":"220"}, + {"country":"Senegal","code":"221"},{"country":"Mauritania","code":"222"},{"country":"Mali Republic","code":"223"},{"country":"Guinea","code":"224"}, + {"country":"Ivory Coast","code":"225"},{"country":"Burkina Faso","code":"226"},{"country":"Niger","code":"227"},{"country":"Togo","code":"228"}, + {"country":"Benin","code":"229"},{"country":"Mauritius","code":"230"},{"country":"Liberia","code":"231"},{"country":"Sierra Leone","code":"232"}, + {"country":"Ghana","code":"233"},{"country":"Nigeria","code":"234"},{"country":"Chad","code":"235"},{"country":"Central African Republic","code":"236"}, + {"country":"Cameroon","code":"237"},{"country":"Cape Verde Islands","code":"238"},{"country":"Sao Tome and Principe","code":"239"}, + {"country":"Gabon","code":"241"},{"country":"Congo, Democratic Republ","code":"243"},{"country":"Angola","code":"244"}, + {"country":"Guinea-Bissau","code":"245"},{"country":"Seychelles","code":"248"},{"country":"Sudan","code":"249"},{"country":"Rwanda","code":"250"}, + {"country":"Ethiopia","code":"251"},{"country":"Somalia","code":"252"},{"country":"Djibouti","code":"253"},{"country":"Kenya","code":"254"}, + {"country":"Tanzania","code":"255"},{"country":"Uganda","code":"256"},{"country":"Burundi","code":"257"},{"country":"Mozambique","code":"258"}, + {"country":"Zambia","code":"260"},{"country":"Madagascar","code":"261"},{"country":"Reunion","code":"262"},{"country":"Zimbabwe","code":"263"}, + {"country":"Namibia","code":"264"},{"country":"Malawi","code":"265"},{"country":"Lesotho","code":"266"},{"country":"Botswana","code":"267"}, + {"country":"Swaziland","code":"268"},{"country":"Mayotte Island","code":"269"},{"country":"Aruba","code":"297"},{"country":"Faroe Islands","code":"298"}, + {"country":"Greenland","code":"299"},{"country":"Gibraltar","code":"350"},{"country":"Portugal","code":"351"},{"country":"Luxembourg","code":"352"}, + {"country":"Ireland","code":"353"},{"country":"Iceland","code":"354"},{"country":"Albania","code":"355"},{"country":"Malta","code":"356"}, + {"country":"Cyprus","code":"357"},{"country":"Finland","code":"358"},{"country":"Bulgaria","code":"359"},{"country":"Lithuania","code":"370"}, + {"country":"Latvia","code":"371"},{"country":"Estonia","code":"372"},{"country":"Moldova","code":"373"},{"country":"Armenia","code":"374"}, + {"country":"Belarus","code":"375"},{"country":"Andorra","code":"376"},{"country":"Monaco","code":"377"},{"country":"San Marino","code":"378"}, + {"country":"Ukraine","code":"380"},{"country":"Serbia","code":"381"},{"country":"Montenegro","code":"382"},{"country":"Croatia","code":"385"}, + {"country":"Slovenia","code":"386"},{"country":"Bosnia-Herzegovina","code":"387"},{"country":"Macedonia","code":"389"}, + {"country":"Czech Republic","code":"420"},{"country":"Slovakia","code":"421"},{"country":"Liechtenstein","code":"423"}, + {"country":"Falkland Islands","code":"500"},{"country":"Belize","code":"501"},{"country":"Guatemala","code":"502"},{"country":"El Salvador","code":"503"}, + {"country":"Honduras","code":"504"},{"country":"Nicaragua","code":"505"},{"country":"Costa Rica","code":"506"},{"country":"Panama","code":"507"}, + {"country":"Haiti","code":"509"},{"country":"Guadeloupe","code":"590"},{"country":"Bolivia","code":"591"},{"country":"Guyana","code":"592"}, + {"country":"Ecuador","code":"593"},{"country":"French Guiana","code":"594"},{"country":"Paraguay","code":"595"},{"country":"Martinique","code":"596"}, + {"country":"Suriname","code":"597"},{"country":"Uruguay","code":"598"},{"country":"Netherlands Antilles","code":"599"},{"country":"Timor-Leste","code":"670"}, + {"country":"Guam","code":"671"},{"country":"Brunei","code":"673"},{"country":"Nauru","code":"674"},{"country":"Papua New Guinea","code":"675"}, + {"country":"Tonga","code":"676"},{"country":"Solomon Islands","code":"677"},{"country":"Vanuatu","code":"678"},{"country":"Fiji Islands","code":"679"}, + {"country":"Cook Islands","code":"682"},{"country":"Samoa","code":"685"},{"country":"New Caledonia","code":"687"},{"country":"French Polynesia","code":"689"}, + {"country":"Korea (North)","code":"850"},{"country":"HongKong","code":"852"},{"country":"Macau","code":"853"},{"country":"Cambodia","code":"855"}, + {"country":"Laos","code":"856"},{"country":"Bangladesh","code":"880"},{"country":"International","code":"882"},{"country":"Taiwan","code":"886"}, + {"country":"Maldives","code":"960"},{"country":"Lebanon","code":"961"},{"country":"Jordan","code":"962"},{"country":"Syria","code":"963"}, + {"country":"Iraq","code":"964"},{"country":"Kuwait","code":"965"},{"country":"Saudi Arabia","code":"966"},{"country":"Yemen","code":"967"}, + {"country":"Oman","code":"968"},{"country":"Palestine","code":"970"},{"country":"United Arab Emirates","code":"971"},{"country":"Israel","code":"972"}, + {"country":"Bahrain","code":"973"},{"country":"Qatar","code":"974"},{"country":"Bhutan","code":"975"},{"country":"Mongolia","code":"976"}, + {"country":"Nepal","code":"977"},{"country":"Tajikistan","code":"992"},{"country":"Turkmenistan","code":"993"},{"country":"Azerbaijan","code":"994"}, + {"country":"Georgia","code":"995"},{"country":"Kyrgyzstan","code":"996"},{"country":"Uzbekistan","code":"998"},{"country":"Bahamas","code":"1242"}, + {"country":"Barbados","code":"1246"},{"country":"Anguilla","code":"1264"},{"country":"Antigua and Barbuda","code":"1268"}, + {"country":"Virgin Islands, British","code":"1284"},{"country":"Cayman Islands","code":"1345"},{"country":"Bermuda","code":"1441"}, + {"country":"Grenada","code":"1473"},{"country":"Turks and Caicos Islands","code":"1649"},{"country":"Montserrat","code":"1664"}, + {"country":"Saint Lucia","code":"1758"},{"country":"Dominica","code":"1767"},{"country":"St. Vincent and The Gren","code":"1784"}, + {"country":"Puerto Rico","code":"1787"},{"country":"Dominican Republic","code":"1809"},{"country":"Dominican Republic2","code":"1829"}, + {"country":"Dominican Republic3","code":"1849"},{"country":"Trinidad and Tobago","code":"1868"},{"country":"Saint Kitts and Nevis","code":"1869"}, + {"country":"Jamaica","code":"1876"},{"country":"Congo","code":"2420"} + ] + + + + # Private Members + + #validates the cellphone is not null and partially correct + setupCellphoneValidation = -> + cellPhone = document.getElementById("authy-cellphone") + return unless cellPhone + cellPhone.onblur = -> + if cellPhone.value != "" and cellPhone.value.match(/^([0-9][0-9][0-9])\W*([0-9][0-9]{2})\W*([0-9]{3,5})$/) + cellPhone.style.backgroundColor = "white" + else + cellPhone.style.backgroundColor = "#F2DEDE" + return + + + #Validates Authy token is not null + setupAuthyTokenValidation = -> + token = document.getElementById("authy-token") + return unless token + token.onblur = -> + if token.value != "" and token.value.match(/^\d+$/) + token.style.backgroundColor = "white" + else + token.style.backgroundColor = "#F2DEDE" + + return + + #Sets the help toolTip + setupTooltip = -> + authy_help = document.getElementById("authy-help") + return unless authy_help + tooltip = document.createElement("div") + tooltip.setAttribute "id", "authy-tooltip" + pos = absolutePosFor(authy_help) + tooltipTop = pos[0] + tooltipLeft = pos[1] + 10 + tooltip.setAttribute "style", "top:" + tooltipTop + "px;left:" + tooltipLeft + "px;" + tooltip.innerHTML = "

" + tooltipTitle + "

" + tooltipMessage + "

" + document.body.appendChild tooltip + document.getElementById("authy-help").onclick = -> + document.getElementById("authy-tooltip").style.display = "block" + + document.getElementById("authy-tooltip-close").onclick = -> + document.getElementById("authy-tooltip").style.display = "none" + + return + + # Process the down-arrow key + processKey40 = (listId) -> + caId = "countries-autocomplete-" + listId + countriesArr = document.getElementById(caId).getElementsByTagName("li") + + i = 0 + while i < countriesArr.length + if document.getElementById(caId).getElementsByTagName("li")[i].className == "active" + document.getElementById(caId).getElementsByTagName("li")[i].className = "" + if (i + 1) == countriesArr.length + document.getElementById(caId).getElementsByTagName("li")[0].className = "active" + else + document.getElementById(caId).getElementsByTagName("li")[i + 1].className = "active" + return false + i++ + document.getElementById(caId).getElementsByTagName("li")[0].setAttribute "class", "active" + + return + + + #process the up arrow key + processKey38 = (listId) -> + caId = "countries-autocomplete-" + listId + countriesArr = document.getElementById(caId).getElementsByTagName("li") + i = countriesArr.length - 1 + + while i >= 0 + if document.getElementById(caId).getElementsByTagName("li")[i].className == "active" + document.getElementById(caId).getElementsByTagName("li")[i].className = "" + if i == 0 + document.getElementById(caId).getElementsByTagName("li")[countriesArr.length - 1].className = "active" + else + document.getElementById(caId).getElementsByTagName("li")[i - 1].className = "active" + return false + i-- + document.getElementById(caId).getElementsByTagName("li")[0].setAttribute("class", "active") + return + + + # + # Process the enter key + # + processKey13 = (listId) -> + obj = document.getElementById("countries-autocomplete-" + listId).getElementsByClassName("active")[0] + self.autocomplete obj + return false + + + # + # Setup to handle the keyboard input events + # + setupEvents = (countriesInput, listId) -> + return unless countriesInput + + countriesInput.onfocus = -> + document.getElementById("countries-autocomplete-" + listId).style.display = "block" + + # when it loses focus hide the list + countriesInput.onblur = -> + # defer this call so click events can be processed + setTimeout (-> + document.getElementById("countries-autocomplete-" + listId).style.display = "none" + ), 200 + + countriesInput.onkeyup = (event) -> + document.getElementById("countries-autocomplete-" + listId).style.display = "block" + keyID = window.event.keyCode # IE + switch keyID + when 13 # enter key + processKey13(listId) + return false + when 40 # down key + return false if processKey40(listId) == false + when 38 # up key + return false if processKey38(listId) == false + self.searchItem listId + + countriesInput.onkeypress = (event) -> + if window.event.keyCode == 13 + processKey13(listId) # Enter key + return false + + document.getElementById("countries-autocomplete-" + listId).onclick = (e) -> + if e && e.stopPropagation + e.stopPropagation() + else + e = window.event + e.cancelBubble = true + + document.getElementById("countries-input-" + listId).onclick = (e) -> + if e && e.stopPropagation + e.stopPropagation() + countriesInput.focus() + countriesInput.select() + else + e = window.event + e.cancelBubble = true + + document.onclick = -> + document.getElementById("countries-autocomplete-" + listId).style.display = "none" + return + + + + # + #Return #TODO + # + buildItem = (classActive, country, listId) -> + cc = country.country.substring(0, 2).toLowerCase() + country.code + return "
  • " + " " + " (+" + country.code + ") " + country.country + "
  • " + + + # + # Given an element returns it absolute position + # + absolutePosFor = (element) -> + absTop = 0 + absLeft = 0 + while element + absTop += element.offsetTop + absLeft += element.offsetLeft + element = element.offsetParent + return [absTop, absLeft] + + + # + # Sets up the countriesDropDown + # + setupCountriesDropdown = (countriesSelect, listId) -> + return unless countriesSelect + countries = [] + i = 0 + + while i < countriesSelect.getElementsByTagName("option").length + buf = [] + buf[0] = countriesSelect.getElementsByTagName("option")[i].value + buf[1] = countriesSelect.getElementsByTagName("option")[i].innerHTML + countries.push buf + i++ + + countriesSelect.setAttribute "style", "display:none" + name = countriesSelect.getAttribute("name") + countriesSelect.removeAttribute "name" + countriesAutocomplete = document.createElement("div") + countryCodeValue = document.createElement("input") + countryCodeValue.setAttribute "type", "hidden" + countryCodeValue.setAttribute "id", "country-code-" + listId + countryCodeValue.setAttribute "name", name + classActive = "" + countriesAutocompleteHTML = "
      " + i = 0 + + while i < countriesList.length + classActive = (if (i is 0) then "active" else "") + countriesAutocompleteHTML += buildItem(classActive, countriesList[i], listId) + i++ + + countriesAutocompleteHTML += "
    " + countriesAutocomplete.innerHTML = countriesAutocompleteHTML + document.body.appendChild countriesAutocomplete + countriesInput = document.createElement("input") + countriesInput.setAttribute "id", "countries-input-" + listId + countriesInput.setAttribute "class", "countries-input" + countriesInput.setAttribute "type", "text" + countriesInput.setAttribute "autocomplete", "off" + countriesSelect.parentNode.insertBefore countriesInput, countriesSelect + countriesSelect.parentNode.appendChild countryCodeValue + pos = absolutePosFor(countriesInput) + countriesAutocomplete.setAttribute "id", "countries-autocomplete-" + listId + countriesAutocomplete.setAttribute "class", "countries-autocomplete" + countriesAutocomplete.setAttribute "style", "width: " + (countriesInput.offsetWidth - 5) + "px; top: " + (pos[0] + 27) + "px; left: " + pos[1] + "px;" + setupEvents countriesInput, listId + + # + # If there are multiple countries dropdows, finds each one and sets a countries Dropdown + # + findAndSetupCountries = -> + setupCountriesDropdown document.getElementById("authy-countries"), 0 + countries = document.getElementsByClassName("authy-countries") + i = 0 + + while i < countries.length + setupCountriesDropdown countries[i], i + 1 + i++ + return + + ########### + # Public Members + ########### + + @init = -> + setupAuthyTokenValidation() + setupTooltip() + findAndSetupCountries() + setupCellphoneValidation() + + + @searchItem = (listId) -> + classActive = "active" + countriesInput = document.getElementById("countries-input-" + listId) + str = countriesInput.value + countriesAutocompleteHTML = "
      " + matches = false + str = str.replace(/[-[\]{}()*+?.,\\^$|#\s]/g, "\\$&") # Escape regular expression special characters + reg = new RegExp("^" + str, "i") + i = 0 + + while i < countriesList.length + countryItem = countriesList[i] + countryWords = countryItem.country.toLowerCase().split(/\s+/) + + # Capture words starting with the entered pattern + cw = 0 + + while cw < countryWords.length + if countryWords[cw].length > 2 && countryWords[cw].match(reg) + countriesAutocompleteHTML += buildItem(classActive, countryItem, listId) + classActive = "" + matches = true + break + cw++ + i++ + countriesAutocompleteHTML += "
    " + document.getElementById("countries-autocomplete-" + listId).innerHTML = countriesAutocompleteHTML if matches + + @autocomplete = (obj) -> + listId = obj.getAttribute("data-list-id") + document.getElementById("countries-input-" + listId).value = obj.getAttribute("data-name") + document.getElementById("countries-autocomplete-" + listId).style.display = "none" + document.getElementById("country-code-" + listId).value = obj.getAttribute("rel") + + @setTooltip = (title, msg) -> + tooltip = document.getElementById("authy-tooltip") + return unless tooltip + tooltip.getElementsByClassName("tooltip-title")[0].innerHTML = title + tooltip.getElementsByClassName("tooltip-content")[0].innerHTML = msg + +Authy.UI.instance = -> + unless @ui + @ui = new Authy.UI() + @ui.init() + @ui + +window.onload = -> + Authy.UI.instance() + + + + + diff --git a/src/form.authy.css b/src/form.authy.css index bb9229f..69e5fd8 100644 --- a/src/form.authy.css +++ b/src/form.authy.css @@ -34,6 +34,8 @@ #authy-token { padding: 3px 0 3px 25px; background: url('images/icon.png') no-repeat 2px center; + background-size: 20px 15px; + } #authy-tooltip { diff --git a/src/form.authy.js b/src/form.authy.js index 6ff7be2..f2de86d 100644 --- a/src/form.authy.js +++ b/src/form.authy.js @@ -1,403 +1,975 @@ -var Authy = {}; +(function() { + var Authy; -// Fix Internet Explorer by defining getElementsByClassName -if(document.getElementsByClassName == null) { + Authy = {}; + + if (document.getElementsByClassName == null) { document.getElementsByClassName = function(className, parentElement) { - var children = (parentElement || document.body).getElementsByTagName('*'); - var elements = [], child; - for (var i = 0, length = children.length; i < length; i++) { - child = children[i]; - if ((' '+child.className+' ').indexOf(' '+className+' ') != -1){ - elements.push(child); - } + var child, children, elements, i, length; + children = (parentElement || document.body).getElementsByTagName("*"); + elements = []; + child = void 0; + i = 0; + length = children.length; + while (i < length) { + child = children[i]; + if ((" " + child.className + " ").indexOf(" " + className + " ") !== -1) { + elements.push(child); } - return elements; + i++; + } + return elements; }; - HTMLDivElement.prototype.getElementsByClassName = function(className) { - return document.getElementsByClassName(className, this); - } -}; - -Authy.UI = function() { - // Attributes - var self = this; - var tooltipTitle = "Authy Help"; - var tooltipMessage = 'This token is only needed if you setup Authy to protect your account. Learn more here'; - - var countriesList = [ - {"country":"United States of America","code":"1"},{"country":"Canada","code":"1"},{"country":"Russia","code":"7"},{"country":"Kazakhstan","code":"7"}, - {"country":"Egypt","code":"20"},{"country":"South Africa","code":"27"},{"country":"Greece","code":"30"},{"country":"Netherlands","code":"31"}, - {"country":"Belgium","code":"32"},{"country":"France","code":"33"},{"country":"Spain","code":"34"},{"country":"Hungary","code":"36"}, - {"country":"Italy","code":"39"},{"country":"Romania","code":"40"},{"country":"Switzerland","code":"41"},{"country":"Austria","code":"43"}, - {"country":"United Kingdom","code":"44"},{"country":"Guernsey","code":"44"},{"country":"Isle of Man","code":"44"},{"country":"Jersey","code":"44"}, - {"country":"Denmark","code":"45"},{"country":"Sweden","code":"46"},{"country":"Norway","code":"47"},{"country":"Poland","code":"48"}, - {"country":"Germany","code":"49"},{"country":"Peru","code":"51"},{"country":"Mexico","code":"52"},{"country":"Cuba","code":"53"}, - {"country":"Argentina","code":"54"},{"country":"Brazil","code":"55"},{"country":"Chile","code":"56"},{"country":"Colombia","code":"57"}, - {"country":"Venezuela","code":"58"},{"country":"Malaysia","code":"60"},{"country":"Australia","code":"61"},{"country":"Indonesia","code":"62"}, - {"country":"Philippines","code":"63"},{"country":"New Zealand","code":"64"},{"country":"Singapore","code":"65"},{"country":"Thailand","code":"66"}, - {"country":"Japan","code":"81"},{"country":"Korea (South)","code":"82"},{"country":"Vietnam","code":"84"},{"country":"China","code":"86"}, - {"country":"Turkey","code":"90"},{"country":"India","code":"91"},{"country":"Pakistan","code":"92"},{"country":"Afghanistan","code":"93"}, - {"country":"Sri Lanka","code":"94"},{"country":"Myanmar","code":"95"},{"country":"Iran","code":"98"},{"country":"Morocco","code":"212"}, - {"country":"Algeria","code":"213"},{"country":"Tunisia","code":"216"},{"country":"Libya","code":"218"},{"country":"Gambia","code":"220"}, - {"country":"Senegal","code":"221"},{"country":"Mauritania","code":"222"},{"country":"Mali Republic","code":"223"},{"country":"Guinea","code":"224"}, - {"country":"Ivory Coast","code":"225"},{"country":"Burkina Faso","code":"226"},{"country":"Niger","code":"227"},{"country":"Togo","code":"228"}, - {"country":"Benin","code":"229"},{"country":"Mauritius","code":"230"},{"country":"Liberia","code":"231"},{"country":"Sierra Leone","code":"232"}, - {"country":"Ghana","code":"233"},{"country":"Nigeria","code":"234"},{"country":"Chad","code":"235"},{"country":"Central African Republic","code":"236"}, - {"country":"Cameroon","code":"237"},{"country":"Cape Verde Islands","code":"238"},{"country":"Sao Tome and Principe","code":"239"}, - {"country":"Gabon","code":"241"},{"country":"Congo, Democratic Republ","code":"243"},{"country":"Angola","code":"244"}, - {"country":"Guinea-Bissau","code":"245"},{"country":"Seychelles","code":"248"},{"country":"Sudan","code":"249"},{"country":"Rwanda","code":"250"}, - {"country":"Ethiopia","code":"251"},{"country":"Somalia","code":"252"},{"country":"Djibouti","code":"253"},{"country":"Kenya","code":"254"}, - {"country":"Tanzania","code":"255"},{"country":"Uganda","code":"256"},{"country":"Burundi","code":"257"},{"country":"Mozambique","code":"258"}, - {"country":"Zambia","code":"260"},{"country":"Madagascar","code":"261"},{"country":"Reunion","code":"262"},{"country":"Zimbabwe","code":"263"}, - {"country":"Namibia","code":"264"},{"country":"Malawi","code":"265"},{"country":"Lesotho","code":"266"},{"country":"Botswana","code":"267"}, - {"country":"Swaziland","code":"268"},{"country":"Mayotte Island","code":"269"},{"country":"Aruba","code":"297"},{"country":"Faroe Islands","code":"298"}, - {"country":"Greenland","code":"299"},{"country":"Gibraltar","code":"350"},{"country":"Portugal","code":"351"},{"country":"Luxembourg","code":"352"}, - {"country":"Ireland","code":"353"},{"country":"Iceland","code":"354"},{"country":"Albania","code":"355"},{"country":"Malta","code":"356"}, - {"country":"Cyprus","code":"357"},{"country":"Finland","code":"358"},{"country":"Bulgaria","code":"359"},{"country":"Lithuania","code":"370"}, - {"country":"Latvia","code":"371"},{"country":"Estonia","code":"372"},{"country":"Moldova","code":"373"},{"country":"Armenia","code":"374"}, - {"country":"Belarus","code":"375"},{"country":"Andorra","code":"376"},{"country":"Monaco","code":"377"},{"country":"San Marino","code":"378"}, - {"country":"Ukraine","code":"380"},{"country":"Serbia","code":"381"},{"country":"Montenegro","code":"382"},{"country":"Croatia","code":"385"}, - {"country":"Slovenia","code":"386"},{"country":"Bosnia-Herzegovina","code":"387"},{"country":"Macedonia","code":"389"}, - {"country":"Czech Republic","code":"420"},{"country":"Slovakia","code":"421"},{"country":"Liechtenstein","code":"423"}, - {"country":"Falkland Islands","code":"500"},{"country":"Belize","code":"501"},{"country":"Guatemala","code":"502"},{"country":"El Salvador","code":"503"}, - {"country":"Honduras","code":"504"},{"country":"Nicaragua","code":"505"},{"country":"Costa Rica","code":"506"},{"country":"Panama","code":"507"}, - {"country":"Haiti","code":"509"},{"country":"Guadeloupe","code":"590"},{"country":"Bolivia","code":"591"},{"country":"Guyana","code":"592"}, - {"country":"Ecuador","code":"593"},{"country":"French Guiana","code":"594"},{"country":"Paraguay","code":"595"},{"country":"Martinique","code":"596"}, - {"country":"Suriname","code":"597"},{"country":"Uruguay","code":"598"},{"country":"Netherlands Antilles","code":"599"},{"country":"Timor-Leste","code":"670"}, - {"country":"Guam","code":"671"},{"country":"Brunei","code":"673"},{"country":"Nauru","code":"674"},{"country":"Papua New Guinea","code":"675"}, - {"country":"Tonga","code":"676"},{"country":"Solomon Islands","code":"677"},{"country":"Vanuatu","code":"678"},{"country":"Fiji Islands","code":"679"}, - {"country":"Cook Islands","code":"682"},{"country":"Samoa","code":"685"},{"country":"New Caledonia","code":"687"},{"country":"French Polynesia","code":"689"}, - {"country":"Korea (North)","code":"850"},{"country":"HongKong","code":"852"},{"country":"Macau","code":"853"},{"country":"Cambodia","code":"855"}, - {"country":"Laos","code":"856"},{"country":"Bangladesh","code":"880"},{"country":"International","code":"882"},{"country":"Taiwan","code":"886"}, - {"country":"Maldives","code":"960"},{"country":"Lebanon","code":"961"},{"country":"Jordan","code":"962"},{"country":"Syria","code":"963"}, - {"country":"Iraq","code":"964"},{"country":"Kuwait","code":"965"},{"country":"Saudi Arabia","code":"966"},{"country":"Yemen","code":"967"}, - {"country":"Oman","code":"968"},{"country":"Palestine","code":"970"},{"country":"United Arab Emirates","code":"971"},{"country":"Israel","code":"972"}, - {"country":"Bahrain","code":"973"},{"country":"Qatar","code":"974"},{"country":"Bhutan","code":"975"},{"country":"Mongolia","code":"976"}, - {"country":"Nepal","code":"977"},{"country":"Tajikistan","code":"992"},{"country":"Turkmenistan","code":"993"},{"country":"Azerbaijan","code":"994"}, - {"country":"Georgia","code":"995"},{"country":"Kyrgyzstan","code":"996"},{"country":"Uzbekistan","code":"998"},{"country":"Bahamas","code":"1242"}, - {"country":"Barbados","code":"1246"},{"country":"Anguilla","code":"1264"},{"country":"Antigua and Barbuda","code":"1268"}, - {"country":"Virgin Islands, British","code":"1284"},{"country":"Cayman Islands","code":"1345"},{"country":"Bermuda","code":"1441"}, - {"country":"Grenada","code":"1473"},{"country":"Turks and Caicos Islands","code":"1649"},{"country":"Montserrat","code":"1664"}, - {"country":"Saint Lucia","code":"1758"},{"country":"Dominica","code":"1767"},{"country":"St. Vincent and The Gren","code":"1784"}, - {"country":"Puerto Rico","code":"1787"},{"country":"Dominican Republic","code":"1809"},{"country":"Dominican Republic2","code":"1829"}, - {"country":"Dominican Republic3","code":"1849"},{"country":"Trinidad and Tobago","code":"1868"},{"country":"Saint Kitts and Nevis","code":"1869"}, - {"country":"Jamaica","code":"1876"},{"country":"Congo","code":"2420"} + return document.getElementsByClassName(className, this); + }; + } + + Authy.UI = function() { + var absolutePosFor, buildItem, countriesList, findAndSetupCountries, processKey13, processKey38, processKey40, self, setupAuthyTokenValidation, setupCellphoneValidation, setupCountriesDropdown, setupEvents, setupTooltip, tooltipMessage, tooltipTitle; + self = this; + tooltipTitle = "Authy Help Tooltip"; + tooltipMessage = "This is a help tooltip for your users. You can set the message by doing: authyUI.setTooltip(\"title\", \"message\");"; + countriesList = [ + { + "country": "United States of America", + "code": "1" + }, { + "country": "Canada", + "code": "1" + }, { + "country": "Russia", + "code": "7" + }, { + "country": "Kazakhstan", + "code": "7" + }, { + "country": "Egypt", + "code": "20" + }, { + "country": "South Africa", + "code": "27" + }, { + "country": "Greece", + "code": "30" + }, { + "country": "Netherlands", + "code": "31" + }, { + "country": "Belgium", + "code": "32" + }, { + "country": "France", + "code": "33" + }, { + "country": "Spain", + "code": "34" + }, { + "country": "Hungary", + "code": "36" + }, { + "country": "Italy", + "code": "39" + }, { + "country": "Romania", + "code": "40" + }, { + "country": "Switzerland", + "code": "41" + }, { + "country": "Austria", + "code": "43" + }, { + "country": "United Kingdom", + "code": "44" + }, { + "country": "Guernsey", + "code": "44" + }, { + "country": "Isle of Man", + "code": "44" + }, { + "country": "Jersey", + "code": "44" + }, { + "country": "Denmark", + "code": "45" + }, { + "country": "Sweden", + "code": "46" + }, { + "country": "Norway", + "code": "47" + }, { + "country": "Poland", + "code": "48" + }, { + "country": "Germany", + "code": "49" + }, { + "country": "Peru", + "code": "51" + }, { + "country": "Mexico", + "code": "52" + }, { + "country": "Cuba", + "code": "53" + }, { + "country": "Argentina", + "code": "54" + }, { + "country": "Brazil", + "code": "55" + }, { + "country": "Chile", + "code": "56" + }, { + "country": "Colombia", + "code": "57" + }, { + "country": "Venezuela", + "code": "58" + }, { + "country": "Malaysia", + "code": "60" + }, { + "country": "Australia", + "code": "61" + }, { + "country": "Indonesia", + "code": "62" + }, { + "country": "Philippines", + "code": "63" + }, { + "country": "New Zealand", + "code": "64" + }, { + "country": "Singapore", + "code": "65" + }, { + "country": "Thailand", + "code": "66" + }, { + "country": "Japan", + "code": "81" + }, { + "country": "Korea (South)", + "code": "82" + }, { + "country": "Vietnam", + "code": "84" + }, { + "country": "China", + "code": "86" + }, { + "country": "Turkey", + "code": "90" + }, { + "country": "India", + "code": "91" + }, { + "country": "Pakistan", + "code": "92" + }, { + "country": "Afghanistan", + "code": "93" + }, { + "country": "Sri Lanka", + "code": "94" + }, { + "country": "Myanmar", + "code": "95" + }, { + "country": "Iran", + "code": "98" + }, { + "country": "Morocco", + "code": "212" + }, { + "country": "Algeria", + "code": "213" + }, { + "country": "Tunisia", + "code": "216" + }, { + "country": "Libya", + "code": "218" + }, { + "country": "Gambia", + "code": "220" + }, { + "country": "Senegal", + "code": "221" + }, { + "country": "Mauritania", + "code": "222" + }, { + "country": "Mali Republic", + "code": "223" + }, { + "country": "Guinea", + "code": "224" + }, { + "country": "Ivory Coast", + "code": "225" + }, { + "country": "Burkina Faso", + "code": "226" + }, { + "country": "Niger", + "code": "227" + }, { + "country": "Togo", + "code": "228" + }, { + "country": "Benin", + "code": "229" + }, { + "country": "Mauritius", + "code": "230" + }, { + "country": "Liberia", + "code": "231" + }, { + "country": "Sierra Leone", + "code": "232" + }, { + "country": "Ghana", + "code": "233" + }, { + "country": "Nigeria", + "code": "234" + }, { + "country": "Chad", + "code": "235" + }, { + "country": "Central African Republic", + "code": "236" + }, { + "country": "Cameroon", + "code": "237" + }, { + "country": "Cape Verde Islands", + "code": "238" + }, { + "country": "Sao Tome and Principe", + "code": "239" + }, { + "country": "Gabon", + "code": "241" + }, { + "country": "Congo, Democratic Republ", + "code": "243" + }, { + "country": "Angola", + "code": "244" + }, { + "country": "Guinea-Bissau", + "code": "245" + }, { + "country": "Seychelles", + "code": "248" + }, { + "country": "Sudan", + "code": "249" + }, { + "country": "Rwanda", + "code": "250" + }, { + "country": "Ethiopia", + "code": "251" + }, { + "country": "Somalia", + "code": "252" + }, { + "country": "Djibouti", + "code": "253" + }, { + "country": "Kenya", + "code": "254" + }, { + "country": "Tanzania", + "code": "255" + }, { + "country": "Uganda", + "code": "256" + }, { + "country": "Burundi", + "code": "257" + }, { + "country": "Mozambique", + "code": "258" + }, { + "country": "Zambia", + "code": "260" + }, { + "country": "Madagascar", + "code": "261" + }, { + "country": "Reunion", + "code": "262" + }, { + "country": "Zimbabwe", + "code": "263" + }, { + "country": "Namibia", + "code": "264" + }, { + "country": "Malawi", + "code": "265" + }, { + "country": "Lesotho", + "code": "266" + }, { + "country": "Botswana", + "code": "267" + }, { + "country": "Swaziland", + "code": "268" + }, { + "country": "Mayotte Island", + "code": "269" + }, { + "country": "Aruba", + "code": "297" + }, { + "country": "Faroe Islands", + "code": "298" + }, { + "country": "Greenland", + "code": "299" + }, { + "country": "Gibraltar", + "code": "350" + }, { + "country": "Portugal", + "code": "351" + }, { + "country": "Luxembourg", + "code": "352" + }, { + "country": "Ireland", + "code": "353" + }, { + "country": "Iceland", + "code": "354" + }, { + "country": "Albania", + "code": "355" + }, { + "country": "Malta", + "code": "356" + }, { + "country": "Cyprus", + "code": "357" + }, { + "country": "Finland", + "code": "358" + }, { + "country": "Bulgaria", + "code": "359" + }, { + "country": "Lithuania", + "code": "370" + }, { + "country": "Latvia", + "code": "371" + }, { + "country": "Estonia", + "code": "372" + }, { + "country": "Moldova", + "code": "373" + }, { + "country": "Armenia", + "code": "374" + }, { + "country": "Belarus", + "code": "375" + }, { + "country": "Andorra", + "code": "376" + }, { + "country": "Monaco", + "code": "377" + }, { + "country": "San Marino", + "code": "378" + }, { + "country": "Ukraine", + "code": "380" + }, { + "country": "Serbia", + "code": "381" + }, { + "country": "Montenegro", + "code": "382" + }, { + "country": "Croatia", + "code": "385" + }, { + "country": "Slovenia", + "code": "386" + }, { + "country": "Bosnia-Herzegovina", + "code": "387" + }, { + "country": "Macedonia", + "code": "389" + }, { + "country": "Czech Republic", + "code": "420" + }, { + "country": "Slovakia", + "code": "421" + }, { + "country": "Liechtenstein", + "code": "423" + }, { + "country": "Falkland Islands", + "code": "500" + }, { + "country": "Belize", + "code": "501" + }, { + "country": "Guatemala", + "code": "502" + }, { + "country": "El Salvador", + "code": "503" + }, { + "country": "Honduras", + "code": "504" + }, { + "country": "Nicaragua", + "code": "505" + }, { + "country": "Costa Rica", + "code": "506" + }, { + "country": "Panama", + "code": "507" + }, { + "country": "Haiti", + "code": "509" + }, { + "country": "Guadeloupe", + "code": "590" + }, { + "country": "Bolivia", + "code": "591" + }, { + "country": "Guyana", + "code": "592" + }, { + "country": "Ecuador", + "code": "593" + }, { + "country": "French Guiana", + "code": "594" + }, { + "country": "Paraguay", + "code": "595" + }, { + "country": "Martinique", + "code": "596" + }, { + "country": "Suriname", + "code": "597" + }, { + "country": "Uruguay", + "code": "598" + }, { + "country": "Netherlands Antilles", + "code": "599" + }, { + "country": "Timor-Leste", + "code": "670" + }, { + "country": "Guam", + "code": "671" + }, { + "country": "Brunei", + "code": "673" + }, { + "country": "Nauru", + "code": "674" + }, { + "country": "Papua New Guinea", + "code": "675" + }, { + "country": "Tonga", + "code": "676" + }, { + "country": "Solomon Islands", + "code": "677" + }, { + "country": "Vanuatu", + "code": "678" + }, { + "country": "Fiji Islands", + "code": "679" + }, { + "country": "Cook Islands", + "code": "682" + }, { + "country": "Samoa", + "code": "685" + }, { + "country": "New Caledonia", + "code": "687" + }, { + "country": "French Polynesia", + "code": "689" + }, { + "country": "Korea (North)", + "code": "850" + }, { + "country": "HongKong", + "code": "852" + }, { + "country": "Macau", + "code": "853" + }, { + "country": "Cambodia", + "code": "855" + }, { + "country": "Laos", + "code": "856" + }, { + "country": "Bangladesh", + "code": "880" + }, { + "country": "International", + "code": "882" + }, { + "country": "Taiwan", + "code": "886" + }, { + "country": "Maldives", + "code": "960" + }, { + "country": "Lebanon", + "code": "961" + }, { + "country": "Jordan", + "code": "962" + }, { + "country": "Syria", + "code": "963" + }, { + "country": "Iraq", + "code": "964" + }, { + "country": "Kuwait", + "code": "965" + }, { + "country": "Saudi Arabia", + "code": "966" + }, { + "country": "Yemen", + "code": "967" + }, { + "country": "Oman", + "code": "968" + }, { + "country": "Palestine", + "code": "970" + }, { + "country": "United Arab Emirates", + "code": "971" + }, { + "country": "Israel", + "code": "972" + }, { + "country": "Bahrain", + "code": "973" + }, { + "country": "Qatar", + "code": "974" + }, { + "country": "Bhutan", + "code": "975" + }, { + "country": "Mongolia", + "code": "976" + }, { + "country": "Nepal", + "code": "977" + }, { + "country": "Tajikistan", + "code": "992" + }, { + "country": "Turkmenistan", + "code": "993" + }, { + "country": "Azerbaijan", + "code": "994" + }, { + "country": "Georgia", + "code": "995" + }, { + "country": "Kyrgyzstan", + "code": "996" + }, { + "country": "Uzbekistan", + "code": "998" + }, { + "country": "Bahamas", + "code": "1242" + }, { + "country": "Barbados", + "code": "1246" + }, { + "country": "Anguilla", + "code": "1264" + }, { + "country": "Antigua and Barbuda", + "code": "1268" + }, { + "country": "Virgin Islands, British", + "code": "1284" + }, { + "country": "Cayman Islands", + "code": "1345" + }, { + "country": "Bermuda", + "code": "1441" + }, { + "country": "Grenada", + "code": "1473" + }, { + "country": "Turks and Caicos Islands", + "code": "1649" + }, { + "country": "Montserrat", + "code": "1664" + }, { + "country": "Saint Lucia", + "code": "1758" + }, { + "country": "Dominica", + "code": "1767" + }, { + "country": "St. Vincent and The Gren", + "code": "1784" + }, { + "country": "Puerto Rico", + "code": "1787" + }, { + "country": "Dominican Republic", + "code": "1809" + }, { + "country": "Dominican Republic2", + "code": "1829" + }, { + "country": "Dominican Republic3", + "code": "1849" + }, { + "country": "Trinidad and Tobago", + "code": "1868" + }, { + "country": "Saint Kitts and Nevis", + "code": "1869" + }, { + "country": "Jamaica", + "code": "1876" + }, { + "country": "Congo", + "code": "2420" + } ]; - var countries = []; - - // Private Members - var setupCellphoneValidation = function() { - var cellPhone = document.getElementById("authy-cellphone"); - if(!cellPhone) return; - - cellPhone.onblur = function(){ - if(cellPhone.value != '' && cellPhone.value.match(/^([0-9][0-9][0-9])\W*([0-9][0-9]{2})\W*([0-9]{3,5})$/)){ - cellPhone.style.backgroundColor = "white"; + setupCellphoneValidation = function() { + var cellPhone; + cellPhone = document.getElementById("authy-cellphone"); + if (!cellPhone) { + return; + } + cellPhone.onblur = function() { + if (cellPhone.value !== "" && cellPhone.value.match(/^([0-9][0-9][0-9])\W*([0-9][0-9]{2})\W*([0-9]{3,5})$/)) { + return cellPhone.style.backgroundColor = "white"; + } else { + return cellPhone.style.backgroundColor = "#F2DEDE"; + } + }; + }; + setupAuthyTokenValidation = function() { + var token; + token = document.getElementById("authy-token"); + if (!token) { + return; + } + token.onblur = function() { + if (token.value !== "" && token.value.match(/^\d+$/)) { + return token.style.backgroundColor = "white"; + } else { + return token.style.backgroundColor = "#F2DEDE"; + } + }; + }; + setupTooltip = function() { + var authy_help, pos, tooltip, tooltipLeft, tooltipTop; + authy_help = document.getElementById("authy-help"); + if (!authy_help) { + return; + } + tooltip = document.createElement("div"); + tooltip.setAttribute("id", "authy-tooltip"); + pos = absolutePosFor(authy_help); + tooltipTop = pos[0]; + tooltipLeft = pos[1] + 10; + tooltip.setAttribute("style", "top:" + tooltipTop + "px;left:" + tooltipLeft + "px;"); + tooltip.innerHTML = "

    " + tooltipTitle + "

    " + tooltipMessage + "

    "; + document.body.appendChild(tooltip); + document.getElementById("authy-help").onclick = function() { + return document.getElementById("authy-tooltip").style.display = "block"; + }; + document.getElementById("authy-tooltip-close").onclick = function() { + return document.getElementById("authy-tooltip").style.display = "none"; + }; + }; + processKey40 = function(listId) { + var caId, countriesArr, i; + caId = "countries-autocomplete-" + listId; + countriesArr = document.getElementById(caId).getElementsByTagName("li"); + i = 0; + while (i < countriesArr.length) { + if (document.getElementById(caId).getElementsByTagName("li")[i].className === "active") { + document.getElementById(caId).getElementsByTagName("li")[i].className = ""; + if ((i + 1) === countriesArr.length) { + document.getElementById(caId).getElementsByTagName("li")[0].className = "active"; } else { - cellPhone.style.backgroundColor = "#F2DEDE"; + document.getElementById(caId).getElementsByTagName("li")[i + 1].className = "active"; } + return false; } + i++; + } + document.getElementById(caId).getElementsByTagName("li")[0].setAttribute("class", "active"); }; - - var setupAuthyToken = function() { - var token = document.getElementById("authy-token"); - if(!token) return; - - token.onblur = function() { - if(token.value != '' && token.value.match(/^\d+$/)){ - token.style.backgroundColor = "white"; + processKey38 = function(listId) { + var caId, countriesArr, i; + caId = "countries-autocomplete-" + listId; + countriesArr = document.getElementById(caId).getElementsByTagName("li"); + i = countriesArr.length - 1; + while (i >= 0) { + if (document.getElementById(caId).getElementsByTagName("li")[i].className === "active") { + document.getElementById(caId).getElementsByTagName("li")[i].className = ""; + if (i === 0) { + document.getElementById(caId).getElementsByTagName("li")[countriesArr.length - 1].className = "active"; } else { - token.style.backgroundColor = "#F2DEDE"; + document.getElementById(caId).getElementsByTagName("li")[i - 1].className = "active"; } - }; - }; - - var setupTooltip = function() { - var authy_help = document.getElementById("authy-help"); - if(!authy_help) return; - - var tooltip = document.createElement("div"); - tooltip.setAttribute("id", "authy-tooltip"); - - var pos = absolutePosFor(authy_help); - - var tooltipTop = pos[0]; - var tooltipLeft = pos[1]+10; - - - - tooltip.setAttribute("style", "top:" + tooltipTop + "px;left:" + tooltipLeft + "px;"); - tooltip.innerHTML = '

    '+tooltipTitle+'

    '+tooltipMessage+'

    '; - document.body.appendChild(tooltip); - document.getElementById('authy-help').onclick = function(){ document.getElementById("authy-tooltip").style.display = "block"; }; - document.getElementById('authy-tooltip-close').onclick = function(){ document.getElementById("authy-tooltip").style.display = "none"; }; - }; - - var processKey40 = function(listId) { - var caId = 'countries-autocomplete-'+listId; - var countriesArr = document.getElementById(caId).getElementsByTagName('li'); - for(var i=0; i=0; i--){ - if(document.getElementById(caId).getElementsByTagName('li')[i].className == 'active'){ - document.getElementById(caId).getElementsByTagName('li')[i].className = ''; - if(i == 0){ - document.getElementById(caId).getElementsByTagName('li')[countriesArr.length-1].className = 'active'; - } else { - document.getElementById(caId).getElementsByTagName('li')[i-1].className = 'active'; - } - return false; - } - } - document.getElementById(caId).getElementsByTagName('li')[0].setAttribute('class', 'active'); - } - - var processKey13 = function(listId) { - var obj = document.getElementById('countries-autocomplete-'+listId).getElementsByClassName('active')[0]; - - self.autocomplete(obj); - return false; - } - - var setupEvents = function(countriesInput, listId) { - if(!countriesInput) return; - - countriesInput.onfocus = function() { - document.getElementById('countries-autocomplete-'+listId).style.display = "block"; - } - - // when it loses focus hide the list - countriesInput.onblur = function() { - // defer this call so click events can be processed - setTimeout(function() { - document.getElementById('countries-autocomplete-'+listId).style.display = "none"; - }, 200); - } - - countriesInput.onkeyup = function(event) { - document.getElementById('countries-autocomplete-'+listId).style.display = "block"; - var keyID = window.event.keyCode; // IE - - switch(keyID) { - case 13: - // enter - processKey13(listId); - return false; - break; - case 40: - // down key - if(processKey40(listId) == false) - return false; - break; - case 38: - // up key - if(processKey38(listId) == false) - return false; - break; + processKey13 = function(listId) { + var obj; + obj = document.getElementById("countries-autocomplete-" + listId).getElementsByClassName("active")[0]; + self.autocomplete(obj); + return false; + }; + setupEvents = function(countriesInput, listId) { + if (!countriesInput) { + return; + } + countriesInput.onfocus = function() { + return document.getElementById("countries-autocomplete-" + listId).style.display = "block"; + }; + countriesInput.onblur = function() { + return setTimeout((function() { + return document.getElementById("countries-autocomplete-" + listId).style.display = "none"; + }), 200); + }; + countriesInput.onkeyup = function(event) { + var keyID; + document.getElementById("countries-autocomplete-" + listId).style.display = "block"; + keyID = window.event.keyCode; + switch (keyID) { + case 13: + processKey13(listId); + return false; + case 40: + if (processKey40(listId) === false) { + return false; } - - self.searchItem(listId); - }; - - countriesInput.onkeypress = function(event) { - if(window.event.keyCode == 13) { - processKey13(listId); // Enter key + break; + case 38: + if (processKey38(listId) === false) { return false; - } - }; - - document.getElementById('countries-autocomplete-'+listId).onclick = function(e){ - if(e && e.stopPropagation) { - e.stopPropagation(); - } else { - e = window.event; - e.cancelBubble = true; } } - - document.getElementById('countries-input-'+listId).onclick = function(e){ - if(e && e.stopPropagation) { - e.stopPropagation(); - - countriesInput.focus(); - countriesInput.select(); - } else { - e = window.event; - e.cancelBubble = true; - } + return self.searchItem(listId); + }; + countriesInput.onkeypress = function(event) { + if (window.event.keyCode === 13) { + processKey13(listId); + return false; } - - document.onclick = function() { - document.getElementById('countries-autocomplete-'+listId).style.display = "none"; + }; + document.getElementById("countries-autocomplete-" + listId).onclick = function(e) { + if (e && e.stopPropagation) { + return e.stopPropagation(); + } else { + e = window.event; + return e.cancelBubble = true; } - - - }; - - var buildItem = function(classActive, country, listId) { - var cc = country.country.substring(0,2).toLowerCase()+country.code; - return '
  • '+ - ' '+ - ' (+'+ country.code + ') ' + country.country + '
  • '; - } - - var absolutePosFor = function(element) { - var absTop = 0; - var absLeft = 0; - while(element) { - absTop += element.offsetTop; - absLeft += element.offsetLeft; - - element = element.offsetParent; - } - - return [absTop, absLeft]; - } - - var setupCountriesDropdown = function(countriesSelect, listId) { - if(!countriesSelect) { - return; - } - - var countries = []; - for( var i=0; i < countriesSelect.getElementsByTagName("option").length; i++){ - var buf = []; - buf[0] = countriesSelect.getElementsByTagName("option")[i].value; - buf[1] = countriesSelect.getElementsByTagName("option")[i].innerHTML; - countries.push(buf); - } - - countriesSelect.setAttribute("style", "display:none"); - var name = countriesSelect.getAttribute("name"); - countriesSelect.removeAttribute("name"); - - var countriesAutocomplete = document.createElement("div"); - var countryCodeValue = document.createElement("input"); - countryCodeValue.setAttribute("type", "hidden"); - countryCodeValue.setAttribute("id", "country-code-"+listId); - countryCodeValue.setAttribute("name", name); - - var classActive = ''; - - var countriesAutocompleteHTML = '
      '; - - for( var i=0; i < countriesList.length; i++){ - classActive = (i == 0) ? 'active' : ''; - countriesAutocompleteHTML += buildItem(classActive, countriesList[i], listId); - } - countriesAutocompleteHTML += '
    '; - countriesAutocomplete.innerHTML = countriesAutocompleteHTML; - - document.body.appendChild(countriesAutocomplete); - - var countriesInput = document.createElement("input"); - countriesInput.setAttribute("id", "countries-input-"+listId); - countriesInput.setAttribute("class", "countries-input") - countriesInput.setAttribute("type", "text"); - countriesInput.setAttribute("autocomplete", "off"); - - countriesSelect.parentNode.insertBefore(countriesInput, countriesSelect); - countriesSelect.parentNode.appendChild(countryCodeValue); - - var pos = absolutePosFor(countriesInput); - - countriesAutocomplete.setAttribute("id", "countries-autocomplete-"+listId); - countriesAutocomplete.setAttribute("class", "countries-autocomplete"); - countriesAutocomplete.setAttribute("style", "width: "+(countriesInput.offsetWidth-5)+"px; top: " + (pos[0]+27) + "px; left: " + pos[1] + "px;"); - - setupEvents(countriesInput, listId) - } - - var findAndSetupCountries = function() { - setupCountriesDropdown(document.getElementById("authy-countries"), 0); - var countries = document.getElementsByClassName("authy-countries"); - - for(var i = 0; i < countries.length; i++) { - setupCountriesDropdown(countries[i], i+1); + }; + document.getElementById("countries-input-" + listId).onclick = function(e) { + if (e && e.stopPropagation) { + e.stopPropagation(); + countriesInput.focus(); + return countriesInput.select(); + } else { + e = window.event; + return e.cancelBubble = true; } + }; + return document.onclick = function() { + document.getElementById("countries-autocomplete-" + listId).style.display = "none"; + }; + }; + buildItem = function(classActive, country, listId) { + var cc; + cc = country.country.substring(0, 2).toLowerCase() + country.code; + return "
  • " + " " + " (+" + country.code + ") " + country.country + "
  • "; + }; + absolutePosFor = function(element) { + var absLeft, absTop; + absTop = 0; + absLeft = 0; + while (element) { + absTop += element.offsetTop; + absLeft += element.offsetLeft; + element = element.offsetParent; + } + return [absTop, absLeft]; + }; + setupCountriesDropdown = function(countriesSelect, listId) { + var buf, classActive, countries, countriesAutocomplete, countriesAutocompleteHTML, countriesInput, countryCodeValue, i, name, pos; + if (!countriesSelect) { + return; + } + countries = []; + i = 0; + while (i < countriesSelect.getElementsByTagName("option").length) { + buf = []; + buf[0] = countriesSelect.getElementsByTagName("option")[i].value; + buf[1] = countriesSelect.getElementsByTagName("option")[i].innerHTML; + countries.push(buf); + i++; + } + countriesSelect.setAttribute("style", "display:none"); + name = countriesSelect.getAttribute("name"); + countriesSelect.removeAttribute("name"); + countriesAutocomplete = document.createElement("div"); + countryCodeValue = document.createElement("input"); + countryCodeValue.setAttribute("type", "hidden"); + countryCodeValue.setAttribute("id", "country-code-" + listId); + countryCodeValue.setAttribute("name", name); + classActive = ""; + countriesAutocompleteHTML = "
      "; + i = 0; + while (i < countriesList.length) { + classActive = (i === 0 ? "active" : ""); + countriesAutocompleteHTML += buildItem(classActive, countriesList[i], listId); + i++; + } + countriesAutocompleteHTML += "
    "; + countriesAutocomplete.innerHTML = countriesAutocompleteHTML; + document.body.appendChild(countriesAutocomplete); + countriesInput = document.createElement("input"); + countriesInput.setAttribute("id", "countries-input-" + listId); + countriesInput.setAttribute("class", "countries-input"); + countriesInput.setAttribute("type", "text"); + countriesInput.setAttribute("autocomplete", "off"); + countriesSelect.parentNode.insertBefore(countriesInput, countriesSelect); + countriesSelect.parentNode.appendChild(countryCodeValue); + pos = absolutePosFor(countriesInput); + countriesAutocomplete.setAttribute("id", "countries-autocomplete-" + listId); + countriesAutocomplete.setAttribute("class", "countries-autocomplete"); + countriesAutocomplete.setAttribute("style", "width: " + (countriesInput.offsetWidth - 5) + "px; top: " + (pos[0] + 27) + "px; left: " + pos[1] + "px;"); + return setupEvents(countriesInput, listId); + }; + findAndSetupCountries = function() { + var countries, i; + setupCountriesDropdown(document.getElementById("authy-countries"), 0); + countries = document.getElementsByClassName("authy-countries"); + i = 0; + while (i < countries.length) { + setupCountriesDropdown(countries[i], i + 1); + i++; + } }; - - - - // Public Members this.init = function() { - setupAuthyToken(); - setupTooltip(); - findAndSetupCountries(); - setupCellphoneValidation(); - } - + setupAuthyTokenValidation(); + setupTooltip(); + findAndSetupCountries(); + return setupCellphoneValidation(); + }; this.searchItem = function(listId) { - var classActive = 'active'; - var countriesInput = document.getElementById('countries-input-'+listId); - var str = countriesInput.value; - var countriesAutocompleteHTML = '
      '; - var ok = false; - - str = str.replace(/[-[\]{}()*+?.,\\^$|#\s]/g, "\\$&"); // Escape regular expression special characters - - var reg = new RegExp("^"+str, "i"); - for( var i=0; i < countriesList.length; i++){ - var countryItem = countriesList[i]; - var countryWords = countryItem.country.toLowerCase().split(/\s+/); - // Capture words starting with the entered pattern - for(var cw = 0; cw < countryWords.length; cw++) { - if(countryWords[cw].length > 2 && countryWords[cw].match(reg)) { - countriesAutocompleteHTML += buildItem(classActive, countryItem, listId); - classActive = ''; - ok = true; - break; - } - } - } - countriesAutocompleteHTML += '
    '; - if(ok) { - document.getElementById('countries-autocomplete-'+listId).innerHTML = countriesAutocompleteHTML; + var classActive, countriesAutocompleteHTML, countriesInput, countryItem, countryWords, cw, i, matches, reg, str; + classActive = "active"; + countriesInput = document.getElementById("countries-input-" + listId); + str = countriesInput.value; + countriesAutocompleteHTML = "
      "; + matches = false; + str = str.replace(/[-[\]{}()*+?.,\\^$|#\s]/g, "\\$&"); + reg = new RegExp("^" + str, "i"); + i = 0; + while (i < countriesList.length) { + countryItem = countriesList[i]; + countryWords = countryItem.country.toLowerCase().split(/\s+/); + cw = 0; + while (cw < countryWords.length) { + if (countryWords[cw].length > 2 && countryWords[cw].match(reg)) { + countriesAutocompleteHTML += buildItem(classActive, countryItem, listId); + classActive = ""; + matches = true; + break; + } + cw++; } - } - + i++; + } + countriesAutocompleteHTML += "
    "; + if (matches) { + return document.getElementById("countries-autocomplete-" + listId).innerHTML = countriesAutocompleteHTML; + } + }; this.autocomplete = function(obj) { - var listId = obj.getAttribute("data-list-id"); - document.getElementById('countries-input-'+listId).value = obj.getAttribute("data-name"); - document.getElementById('countries-autocomplete-'+listId).style.display = "none"; - - document.getElementById('country-code-'+listId).value = obj.getAttribute('rel'); - } - - this.setTooltip = function(title, msg) { - var tooltip = document.getElementById("authy-tooltip"); - if(!tooltip) return; - - tooltip.getElementsByClassName("tooltip-title")[0].innerHTML = title; - tooltip.getElementsByClassName("tooltip-content")[0].innerHTML = msg; - } -}; + var listId; + listId = obj.getAttribute("data-list-id"); + document.getElementById("countries-input-" + listId).value = obj.getAttribute("data-name"); + document.getElementById("countries-autocomplete-" + listId).style.display = "none"; + return document.getElementById("country-code-" + listId).value = obj.getAttribute("rel"); + }; + return this.setTooltip = function(title, msg) { + var tooltip; + tooltip = document.getElementById("authy-tooltip"); + if (!tooltip) { + return; + } + tooltip.getElementsByClassName("tooltip-title")[0].innerHTML = title; + return tooltip.getElementsByClassName("tooltip-content")[0].innerHTML = msg; + }; + }; -Authy.UI.instance = function() { - if(!this.ui){ - this.ui = new Authy.UI(); - this.ui.init(); + Authy.UI.instance = function() { + if (!this.ui) { + this.ui = new Authy.UI(); + this.ui.init(); } - return this.ui; -} + }; + + window.onload = function() { + return Authy.UI.instance(); + }; -window.onload = function() { - Authy.UI.instance(); -} +}).call(this); diff --git a/src/form.authy.min.css b/src/form.authy.min.css index 085a63e..0ab3dac 100644 --- a/src/form.authy.min.css +++ b/src/form.authy.min.css @@ -1 +1 @@ -// THIS FILE IS AUTOGENERATED. PLEASE DO NOT MODIFIED IT .flag_af93{background:url('images/flags/af93.gif') no-repeat 0 center}.flag_al213{background:url('images/flags/al213.gif') no-repeat 0 center}.flag_al355{background:url('images/flags/al355.gif') no-repeat 0 center}.flag_al358{background:url('images/flags/al358.gif') no-repeat 0 center}.flag_am1684{background:url('images/flags/am1684.gif') no-repeat 0 center}.flag_an1264{background:url('images/flags/an1264.gif') no-repeat 0 center}.flag_an1268{background:url('images/flags/an1268.gif') no-repeat 0 center}.flag_an244{background:url('images/flags/an244.gif') no-repeat 0 center}.flag_an376{background:url('images/flags/an376.gif') no-repeat 0 center}.flag_ar297{background:url('images/flags/ar297.gif') no-repeat 0 center}.flag_ar374{background:url('images/flags/ar374.gif') no-repeat 0 center}.flag_ar54{background:url('images/flags/ar54.gif') no-repeat 0 center}.flag_au43{background:url('images/flags/au43.gif') no-repeat 0 center}.flag_au61{background:url('images/flags/au61.gif') no-repeat 0 center}.flag_az994{background:url('images/flags/az994.gif') no-repeat 0 center}.flag_ba1242{background:url('images/flags/ba1242.gif') no-repeat 0 center}.flag_ba1246{background:url('images/flags/ba1246.gif') no-repeat 0 center}.flag_ba880{background:url('images/flags/ba880.gif') no-repeat 0 center}.flag_ba973{background:url('images/flags/ba973.gif') no-repeat 0 center}.flag_be1441{background:url('images/flags/be1441.gif') no-repeat 0 center}.flag_be229{background:url('images/flags/be229.gif') no-repeat 0 center}.flag_be32{background:url('images/flags/be32.gif') no-repeat 0 center}.flag_be375{background:url('images/flags/be375.gif') no-repeat 0 center}.flag_be501{background:url('images/flags/be501.gif') no-repeat 0 center}.flag_bh975{background:url('images/flags/bh975.gif') no-repeat 0 center}.flag_bo267{background:url('images/flags/bo267.gif') no-repeat 0 center}.flag_bo387{background:url('images/flags/bo387.gif') no-repeat 0 center}.flag_bo591{background:url('images/flags/bo591.gif') no-repeat 0 center}.flag_br246{background:url('images/flags/br246.gif') no-repeat 0 center}.flag_br55{background:url('images/flags/br55.gif') no-repeat 0 center}.flag_br673{background:url('images/flags/br673.gif') no-repeat 0 center}.flag_bu226{background:url('images/flags/bu226.gif') no-repeat 0 center}.flag_bu257{background:url('images/flags/bu257.gif') no-repeat 0 center}.flag_bu359{background:url('images/flags/bu359.gif') no-repeat 0 center}.flag_ca1{background:url('images/flags/ca1.gif') no-repeat 0 center}.flag_ca1345{background:url('images/flags/ca1345.gif') no-repeat 0 center}.flag_ca237{background:url('images/flags/ca237.gif') no-repeat 0 center}.flag_ca238{background:url('images/flags/ca238.gif') no-repeat 0 center}.flag_ca855{background:url('images/flags/ca855.gif') no-repeat 0 center}.flag_ce236{background:url('images/flags/ce236.gif') no-repeat 0 center}.flag_ch235{background:url('images/flags/ch235.gif') no-repeat 0 center}.flag_ch56{background:url('images/flags/ch56.gif') no-repeat 0 center}.flag_ch61{background:url('images/flags/ch61.gif') no-repeat 0 center}.flag_ch86{background:url('images/flags/ch86.gif') no-repeat 0 center}.flag_co225{background:url('images/flags/co225.gif') no-repeat 0 center}.flag_co242{background:url('images/flags/co242.gif') no-repeat 0 center}.flag_co243{background:url('images/flags/co243.gif') no-repeat 0 center}.flag_co269{background:url('images/flags/co269.gif') no-repeat 0 center}.flag_co506{background:url('images/flags/co506.gif') no-repeat 0 center}.flag_co57{background:url('images/flags/co57.gif') no-repeat 0 center}.flag_co61{background:url('images/flags/co61.gif') no-repeat 0 center}.flag_co682{background:url('images/flags/co682.gif') no-repeat 0 center}.flag_cr385{background:url('images/flags/cr385.gif') no-repeat 0 center}.flag_cu53{background:url('images/flags/cu53.gif') no-repeat 0 center}.flag_cy357{background:url('images/flags/cy357.gif') no-repeat 0 center}.flag_cz420{background:url('images/flags/cz420.gif') no-repeat 0 center}.flag_de45{background:url('images/flags/de45.gif') no-repeat 0 center}.flag_dj253{background:url('images/flags/dj253.gif') no-repeat 0 center}.flag_do1767{background:url('images/flags/do1767.gif') no-repeat 0 center}.flag_do1849{background:url('images/flags/do1849.gif') no-repeat 0 center}.flag_ec593{background:url('images/flags/ec593.gif') no-repeat 0 center}.flag_eg20{background:url('images/flags/eg20.gif') no-repeat 0 center}.flag_el503{background:url('images/flags/el503.gif') no-repeat 0 center}.flag_england{background:url('images/flags/england.gif') no-repeat 0 center}.flag_eq240{background:url('images/flags/eq240.gif') no-repeat 0 center}.flag_er291{background:url('images/flags/er291.gif') no-repeat 0 center}.flag_es372{background:url('images/flags/es372.gif') no-repeat 0 center}.flag_et251{background:url('images/flags/et251.gif') no-repeat 0 center}.flag_fa298{background:url('images/flags/fa298.gif') no-repeat 0 center}.flag_fa500{background:url('images/flags/fa500.gif') no-repeat 0 center}.flag_fam{background:url('images/flags/fam.gif') no-repeat 0 center}.flag_fi358{background:url('images/flags/fi358.gif') no-repeat 0 center}.flag_fi679{background:url('images/flags/fi679.gif') no-repeat 0 center}.flag_fr33{background:url('images/flags/fr33.gif') no-repeat 0 center}.flag_fr594{background:url('images/flags/fr594.gif') no-repeat 0 center}.flag_fr689{background:url('images/flags/fr689.gif') no-repeat 0 center}.flag_ga220{background:url('images/flags/ga220.gif') no-repeat 0 center}.flag_ga241{background:url('images/flags/ga241.gif') no-repeat 0 center}.flag_ge49{background:url('images/flags/ge49.gif') no-repeat 0 center}.flag_ge995{background:url('images/flags/ge995.gif') no-repeat 0 center}.flag_gh233{background:url('images/flags/gh233.gif') no-repeat 0 center}.flag_gi350{background:url('images/flags/gi350.gif') no-repeat 0 center}.flag_gr1473{background:url('images/flags/gr1473.gif') no-repeat 0 center}.flag_gr299{background:url('images/flags/gr299.gif') no-repeat 0 center}.flag_gr30{background:url('images/flags/gr30.gif') no-repeat 0 center}.flag_gu1671{background:url('images/flags/gu1671.gif') no-repeat 0 center}.flag_gu224{background:url('images/flags/gu224.gif') no-repeat 0 center}.flag_gu245{background:url('images/flags/gu245.gif') no-repeat 0 center}.flag_gu502{background:url('images/flags/gu502.gif') no-repeat 0 center}.flag_gu590{background:url('images/flags/gu590.gif') no-repeat 0 center}.flag_gu592{background:url('images/flags/gu592.gif') no-repeat 0 center}.flag_ha509{background:url('images/flags/ha509.gif') no-repeat 0 center}.flag_ho39{background:url('images/flags/ho39.gif') no-repeat 0 center}.flag_ho504{background:url('images/flags/ho504.gif') no-repeat 0 center}.flag_ho852{background:url('images/flags/ho852.gif') no-repeat 0 center}.flag_hu36{background:url('images/flags/hu36.gif') no-repeat 0 center}.flag_ic354{background:url('images/flags/ic354.gif') no-repeat 0 center}.flag_in62{background:url('images/flags/in62.gif') no-repeat 0 center}.flag_in91{background:url('images/flags/in91.gif') no-repeat 0 center}.flag_ir353{background:url('images/flags/ir353.gif') no-repeat 0 center}.flag_ir964{background:url('images/flags/ir964.gif') no-repeat 0 center}.flag_ir98{background:url('images/flags/ir98.gif') no-repeat 0 center}.flag_is972{background:url('images/flags/is972.gif') no-repeat 0 center}.flag_it39{background:url('images/flags/it39.gif') no-repeat 0 center}.flag_ja1876{background:url('images/flags/ja1876.gif') no-repeat 0 center}.flag_ja81{background:url('images/flags/ja81.gif') no-repeat 0 center}.flag_jo962{background:url('images/flags/jo962.gif') no-repeat 0 center}.flag_ka7{background:url('images/flags/ka7.gif') no-repeat 0 center}.flag_ke254{background:url('images/flags/ke254.gif') no-repeat 0 center}.flag_ki686{background:url('images/flags/ki686.gif') no-repeat 0 center}.flag_ko82{background:url('images/flags/ko82.gif') no-repeat 0 center}.flag_ko850{background:url('images/flags/ko850.gif') no-repeat 0 center}.flag_ku965{background:url('images/flags/ku965.gif') no-repeat 0 center}.flag_ky996{background:url('images/flags/ky996.gif') no-repeat 0 center}.flag_la371{background:url('images/flags/la371.gif') no-repeat 0 center}.flag_la856{background:url('images/flags/la856.gif') no-repeat 0 center}.flag_le266{background:url('images/flags/le266.gif') no-repeat 0 center}.flag_le961{background:url('images/flags/le961.gif') no-repeat 0 center}.flag_li218{background:url('images/flags/li218.gif') no-repeat 0 center}.flag_li231{background:url('images/flags/li231.gif') no-repeat 0 center}.flag_li370{background:url('images/flags/li370.gif') no-repeat 0 center}.flag_li423{background:url('images/flags/li423.gif') no-repeat 0 center}.flag_lu352{background:url('images/flags/lu352.gif') no-repeat 0 center}.flag_ma222{background:url('images/flags/ma222.gif') no-repeat 0 center}.flag_ma223{background:url('images/flags/ma223.gif') no-repeat 0 center}.flag_ma230{background:url('images/flags/ma230.gif') no-repeat 0 center}.flag_ma261{background:url('images/flags/ma261.gif') no-repeat 0 center}.flag_ma262{background:url('images/flags/ma262.gif') no-repeat 0 center}.flag_ma265{background:url('images/flags/ma265.gif') no-repeat 0 center}.flag_ma356{background:url('images/flags/ma356.gif') no-repeat 0 center}.flag_ma389{background:url('images/flags/ma389.gif') no-repeat 0 center}.flag_ma596{background:url('images/flags/ma596.gif') no-repeat 0 center}.flag_ma60{background:url('images/flags/ma60.gif') no-repeat 0 center}.flag_ma692{background:url('images/flags/ma692.gif') no-repeat 0 center}.flag_ma853{background:url('images/flags/ma853.gif') no-repeat 0 center}.flag_ma960{background:url('images/flags/ma960.gif') no-repeat 0 center}.flag_me52{background:url('images/flags/me52.gif') no-repeat 0 center}.flag_mi691{background:url('images/flags/mi691.gif') no-repeat 0 center}.flag_mo1664{background:url('images/flags/mo1664.gif') no-repeat 0 center}.flag_mo212{background:url('images/flags/mo212.gif') no-repeat 0 center}.flag_mo258{background:url('images/flags/mo258.gif') no-repeat 0 center}.flag_mo373{background:url('images/flags/mo373.gif') no-repeat 0 center}.flag_mo377{background:url('images/flags/mo377.gif') no-repeat 0 center}.flag_mo382{background:url('images/flags/mo382.gif') no-repeat 0 center}.flag_mo976{background:url('images/flags/mo976.gif') no-repeat 0 center}.flag_my95{background:url('images/flags/my95.gif') no-repeat 0 center}.flag_na264{background:url('images/flags/na264.gif') no-repeat 0 center}.flag_na674{background:url('images/flags/na674.gif') no-repeat 0 center}.flag_ne31{background:url('images/flags/ne31.gif') no-repeat 0 center}.flag_ne599{background:url('images/flags/ne599.gif') no-repeat 0 center}.flag_ne64{background:url('images/flags/ne64.gif') no-repeat 0 center}.flag_ne687{background:url('images/flags/ne687.gif') no-repeat 0 center}.flag_ne977{background:url('images/flags/ne977.gif') no-repeat 0 center}.flag_ni227{background:url('images/flags/ni227.gif') no-repeat 0 center}.flag_ni234{background:url('images/flags/ni234.gif') no-repeat 0 center}.flag_ni505{background:url('images/flags/ni505.gif') no-repeat 0 center}.flag_ni683{background:url('images/flags/ni683.gif') no-repeat 0 center}.flag_no1670{background:url('images/flags/no1670.gif') no-repeat 0 center}.flag_no47{background:url('images/flags/no47.gif') no-repeat 0 center}.flag_no672{background:url('images/flags/no672.gif') no-repeat 0 center}.flag_om968{background:url('images/flags/om968.gif') no-repeat 0 center}.flag_pa507{background:url('images/flags/pa507.gif') no-repeat 0 center}.flag_pa595{background:url('images/flags/pa595.gif') no-repeat 0 center}.flag_pa675{background:url('images/flags/pa675.gif') no-repeat 0 center}.flag_pa680{background:url('images/flags/pa680.gif') no-repeat 0 center}.flag_pa92{background:url('images/flags/pa92.gif') no-repeat 0 center}.flag_pa970{background:url('images/flags/pa970.gif') no-repeat 0 center}.flag_pe51{background:url('images/flags/pe51.gif') no-repeat 0 center}.flag_ph63{background:url('images/flags/ph63.gif') no-repeat 0 center}.flag_pi64{background:url('images/flags/pi64.gif') no-repeat 0 center}.flag_po351{background:url('images/flags/po351.gif') no-repeat 0 center}.flag_po48{background:url('images/flags/po48.gif') no-repeat 0 center}.flag_pu1939{background:url('images/flags/pu1939.gif') no-repeat 0 center}.flag_qa974{background:url('images/flags/qa974.gif') no-repeat 0 center}.flag_re262{background:url('images/flags/re262.gif') no-repeat 0 center}.flag_ro40{background:url('images/flags/ro40.gif') no-repeat 0 center}.flag_ru7{background:url('images/flags/ru7.gif') no-repeat 0 center}.flag_rw250{background:url('images/flags/rw250.gif') no-repeat 0 center}.flag_sa1758{background:url('images/flags/sa1758.gif') no-repeat 0 center}.flag_sa1784{background:url('images/flags/sa1784.gif') no-repeat 0 center}.flag_sa1869{background:url('images/flags/sa1869.gif') no-repeat 0 center}.flag_sa239{background:url('images/flags/sa239.gif') no-repeat 0 center}.flag_sa290{background:url('images/flags/sa290.gif') no-repeat 0 center}.flag_sa378{background:url('images/flags/sa378.gif') no-repeat 0 center}.flag_sa508{background:url('images/flags/sa508.gif') no-repeat 0 center}.flag_sa685{background:url('images/flags/sa685.gif') no-repeat 0 center}.flag_sa966{background:url('images/flags/sa966.gif') no-repeat 0 center}.flag_se221{background:url('images/flags/se221.gif') no-repeat 0 center}.flag_se248{background:url('images/flags/se248.gif') no-repeat 0 center}.flag_se381{background:url('images/flags/se381.gif') no-repeat 0 center}.flag_si232{background:url('images/flags/si232.gif') no-repeat 0 center}.flag_si65{background:url('images/flags/si65.gif') no-repeat 0 center}.flag_sl386{background:url('images/flags/sl386.gif') no-repeat 0 center}.flag_sl421{background:url('images/flags/sl421.gif') no-repeat 0 center}.flag_so252{background:url('images/flags/so252.gif') no-repeat 0 center}.flag_so27{background:url('images/flags/so27.gif') no-repeat 0 center}.flag_so677{background:url('images/flags/so677.gif') no-repeat 0 center}.flag_sp34{background:url('images/flags/sp34.gif') no-repeat 0 center}.flag_sr94{background:url('images/flags/sr94.gif') no-repeat 0 center}.flag_su249{background:url('images/flags/su249.gif') no-repeat 0 center}.flag_su597{background:url('images/flags/su597.gif') no-repeat 0 center}.flag_sv47{background:url('images/flags/sv47.gif') no-repeat 0 center}.flag_sw268{background:url('images/flags/sw268.gif') no-repeat 0 center}.flag_sw41{background:url('images/flags/sw41.gif') no-repeat 0 center}.flag_sw46{background:url('images/flags/sw46.gif') no-repeat 0 center}.flag_sy963{background:url('images/flags/sy963.gif') no-repeat 0 center}.flag_ta255{background:url('images/flags/ta255.gif') no-repeat 0 center}.flag_ta886{background:url('images/flags/ta886.gif') no-repeat 0 center}.flag_ta992{background:url('images/flags/ta992.gif') no-repeat 0 center}.flag_th66{background:url('images/flags/th66.gif') no-repeat 0 center}.flag_ti670{background:url('images/flags/ti670.gif') no-repeat 0 center}.flag_to228{background:url('images/flags/to228.gif') no-repeat 0 center}.flag_to676{background:url('images/flags/to676.gif') no-repeat 0 center}.flag_to690{background:url('images/flags/to690.gif') no-repeat 0 center}.flag_tr1868{background:url('images/flags/tr1868.gif') no-repeat 0 center}.flag_tu1649{background:url('images/flags/tu1649.gif') no-repeat 0 center}.flag_tu216{background:url('images/flags/tu216.gif') no-repeat 0 center}.flag_tu688{background:url('images/flags/tu688.gif') no-repeat 0 center}.flag_tu90{background:url('images/flags/tu90.gif') no-repeat 0 center}.flag_tu993{background:url('images/flags/tu993.gif') no-repeat 0 center}.flag_ug256{background:url('images/flags/ug256.gif') no-repeat 0 center}.flag_uk380{background:url('images/flags/uk380.gif') no-repeat 0 center}.flag_un1{background:url('images/flags/un1.gif') no-repeat 0 center}.flag_un44{background:url('images/flags/un44.gif') no-repeat 0 center}.flag_un971{background:url('images/flags/un971.gif') no-repeat 0 center}.flag_ur598{background:url('images/flags/ur598.gif') no-repeat 0 center}.flag_uz998{background:url('images/flags/uz998.gif') no-repeat 0 center}.flag_va678{background:url('images/flags/va678.gif') no-repeat 0 center}.flag_ve58{background:url('images/flags/ve58.gif') no-repeat 0 center}.flag_vi1284{background:url('images/flags/vi1284.gif') no-repeat 0 center}.flag_vi1340{background:url('images/flags/vi1340.gif') no-repeat 0 center}.flag_vi84{background:url('images/flags/vi84.gif') no-repeat 0 center}.flag_wa681{background:url('images/flags/wa681.gif') no-repeat 0 center}.flag_wales{background:url('images/flags/wales.gif') no-repeat 0 center}.flag_we212{background:url('images/flags/we212.gif') no-repeat 0 center}.flag_ye967{background:url('images/flags/ye967.gif') no-repeat 0 center}.flag_za260{background:url('images/flags/za260.gif') no-repeat 0 center}.flag_zi263{background:url('images/flags/zi263.gif') no-repeat 0 center}.aflag{width:16px;height:12px;display:inline-block}.countries-autocomplete{background-color:#fff;border:2px solid #ccc}.countries-autocomplete ul{margin:0;padding:0}.countries-autocomplete li{list-style-type:none;border-bottom:1px solid #ccc;padding:5px 10px;font-size:12px;font-family:arial}.countries-autocomplete li:hover,.countries-autocomplete li.active{cursor:pointer;background-color:#ccc}#authy-tooltip-close{position:absolute;top:5px;right:5px;cursor:pointer;width:11px;height:11px;background:url('images/close.gif') no-repeat 0 0}#authy-token{padding:3px 0 3px 22px;border:1px solid #ccc;background:url('images/icon.png') no-repeat 2px center;color:#333}#authy-tooltip{position:absolute;z-index:999999;border:1px solid #ccc;-moz-border-radius:6px;-webkit-border-radius:6px;border-radius:6px;padding:10px;background-color:#fff;display:none;width:330px}#authy-tooltip p{color:#444}.countries-autocomplete{position:absolute;width:200px;display:none;max-height:200px;overflow:auto;z-index:99999999}.countries-input,#authy-cellphone{border:1px solid #ccc;color:#333}#authy-help{color:#35c2f1}#authy-help:hover{text-decoration:none} \ No newline at end of file +.flag_af93{background:url('images/flags/af93.gif') no-repeat 0 center}.flag_al213{background:url('images/flags/al213.gif') no-repeat 0 center}.flag_al355{background:url('images/flags/al355.gif') no-repeat 0 center}.flag_al358{background:url('images/flags/al358.gif') no-repeat 0 center}.flag_am1684{background:url('images/flags/am1684.gif') no-repeat 0 center}.flag_an1264{background:url('images/flags/an1264.gif') no-repeat 0 center}.flag_an1268{background:url('images/flags/an1268.gif') no-repeat 0 center}.flag_an244{background:url('images/flags/an244.gif') no-repeat 0 center}.flag_an376{background:url('images/flags/an376.gif') no-repeat 0 center}.flag_ar297{background:url('images/flags/ar297.gif') no-repeat 0 center}.flag_ar374{background:url('images/flags/ar374.gif') no-repeat 0 center}.flag_ar54{background:url('images/flags/ar54.gif') no-repeat 0 center}.flag_au43{background:url('images/flags/au43.gif') no-repeat 0 center}.flag_au61{background:url('images/flags/au61.gif') no-repeat 0 center}.flag_az994{background:url('images/flags/az994.gif') no-repeat 0 center}.flag_ba1242{background:url('images/flags/ba1242.gif') no-repeat 0 center}.flag_ba1246{background:url('images/flags/ba1246.gif') no-repeat 0 center}.flag_ba880{background:url('images/flags/ba880.gif') no-repeat 0 center}.flag_ba973{background:url('images/flags/ba973.gif') no-repeat 0 center}.flag_be1441{background:url('images/flags/be1441.gif') no-repeat 0 center}.flag_be229{background:url('images/flags/be229.gif') no-repeat 0 center}.flag_be32{background:url('images/flags/be32.gif') no-repeat 0 center}.flag_be375{background:url('images/flags/be375.gif') no-repeat 0 center}.flag_be501{background:url('images/flags/be501.gif') no-repeat 0 center}.flag_bh975{background:url('images/flags/bh975.gif') no-repeat 0 center}.flag_bo267{background:url('images/flags/bo267.gif') no-repeat 0 center}.flag_bo387{background:url('images/flags/bo387.gif') no-repeat 0 center}.flag_bo591{background:url('images/flags/bo591.gif') no-repeat 0 center}.flag_br246{background:url('images/flags/br246.gif') no-repeat 0 center}.flag_br55{background:url('images/flags/br55.gif') no-repeat 0 center}.flag_br673{background:url('images/flags/br673.gif') no-repeat 0 center}.flag_bu226{background:url('images/flags/bu226.gif') no-repeat 0 center}.flag_bu257{background:url('images/flags/bu257.gif') no-repeat 0 center}.flag_bu359{background:url('images/flags/bu359.gif') no-repeat 0 center}.flag_ca1{background:url('images/flags/ca1.gif') no-repeat 0 center}.flag_ca1345{background:url('images/flags/ca1345.gif') no-repeat 0 center}.flag_ca237{background:url('images/flags/ca237.gif') no-repeat 0 center}.flag_ca238{background:url('images/flags/ca238.gif') no-repeat 0 center}.flag_ca855{background:url('images/flags/ca855.gif') no-repeat 0 center}.flag_ce236{background:url('images/flags/ce236.gif') no-repeat 0 center}.flag_ch235{background:url('images/flags/ch235.gif') no-repeat 0 center}.flag_ch56{background:url('images/flags/ch56.gif') no-repeat 0 center}.flag_ch61{background:url('images/flags/ch61.gif') no-repeat 0 center}.flag_ch86{background:url('images/flags/ch86.gif') no-repeat 0 center}.flag_co225{background:url('images/flags/co225.gif') no-repeat 0 center}.flag_co242{background:url('images/flags/co242.gif') no-repeat 0 center}.flag_co243{background:url('images/flags/co243.gif') no-repeat 0 center}.flag_co269{background:url('images/flags/co269.gif') no-repeat 0 center}.flag_co506{background:url('images/flags/co506.gif') no-repeat 0 center}.flag_co57{background:url('images/flags/co57.gif') no-repeat 0 center}.flag_co61{background:url('images/flags/co61.gif') no-repeat 0 center}.flag_co682{background:url('images/flags/co682.gif') no-repeat 0 center}.flag_cr385{background:url('images/flags/cr385.gif') no-repeat 0 center}.flag_cu53{background:url('images/flags/cu53.gif') no-repeat 0 center}.flag_cy357{background:url('images/flags/cy357.gif') no-repeat 0 center}.flag_cz420{background:url('images/flags/cz420.gif') no-repeat 0 center}.flag_de45{background:url('images/flags/de45.gif') no-repeat 0 center}.flag_dj253{background:url('images/flags/dj253.gif') no-repeat 0 center}.flag_do1767{background:url('images/flags/do1767.gif') no-repeat 0 center}.flag_do1849{background:url('images/flags/do1849.gif') no-repeat 0 center}.flag_ec593{background:url('images/flags/ec593.gif') no-repeat 0 center}.flag_eg20{background:url('images/flags/eg20.gif') no-repeat 0 center}.flag_el503{background:url('images/flags/el503.gif') no-repeat 0 center}.flag_england{background:url('images/flags/england.gif') no-repeat 0 center}.flag_eq240{background:url('images/flags/eq240.gif') no-repeat 0 center}.flag_er291{background:url('images/flags/er291.gif') no-repeat 0 center}.flag_es372{background:url('images/flags/es372.gif') no-repeat 0 center}.flag_et251{background:url('images/flags/et251.gif') no-repeat 0 center}.flag_fa298{background:url('images/flags/fa298.gif') no-repeat 0 center}.flag_fa500{background:url('images/flags/fa500.gif') no-repeat 0 center}.flag_fam{background:url('images/flags/fam.gif') no-repeat 0 center}.flag_fi358{background:url('images/flags/fi358.gif') no-repeat 0 center}.flag_fi679{background:url('images/flags/fi679.gif') no-repeat 0 center}.flag_fr33{background:url('images/flags/fr33.gif') no-repeat 0 center}.flag_fr594{background:url('images/flags/fr594.gif') no-repeat 0 center}.flag_fr689{background:url('images/flags/fr689.gif') no-repeat 0 center}.flag_ga220{background:url('images/flags/ga220.gif') no-repeat 0 center}.flag_ga241{background:url('images/flags/ga241.gif') no-repeat 0 center}.flag_ge49{background:url('images/flags/ge49.gif') no-repeat 0 center}.flag_ge995{background:url('images/flags/ge995.gif') no-repeat 0 center}.flag_gh233{background:url('images/flags/gh233.gif') no-repeat 0 center}.flag_gi350{background:url('images/flags/gi350.gif') no-repeat 0 center}.flag_gr1473{background:url('images/flags/gr1473.gif') no-repeat 0 center}.flag_gr299{background:url('images/flags/gr299.gif') no-repeat 0 center}.flag_gr30{background:url('images/flags/gr30.gif') no-repeat 0 center}.flag_gu1671{background:url('images/flags/gu1671.gif') no-repeat 0 center}.flag_gu224{background:url('images/flags/gu224.gif') no-repeat 0 center}.flag_gu245{background:url('images/flags/gu245.gif') no-repeat 0 center}.flag_gu502{background:url('images/flags/gu502.gif') no-repeat 0 center}.flag_gu590{background:url('images/flags/gu590.gif') no-repeat 0 center}.flag_gu592{background:url('images/flags/gu592.gif') no-repeat 0 center}.flag_ha509{background:url('images/flags/ha509.gif') no-repeat 0 center}.flag_ho39{background:url('images/flags/ho39.gif') no-repeat 0 center}.flag_ho504{background:url('images/flags/ho504.gif') no-repeat 0 center}.flag_ho852{background:url('images/flags/ho852.gif') no-repeat 0 center}.flag_hu36{background:url('images/flags/hu36.gif') no-repeat 0 center}.flag_ic354{background:url('images/flags/ic354.gif') no-repeat 0 center}.flag_in62{background:url('images/flags/in62.gif') no-repeat 0 center}.flag_in91{background:url('images/flags/in91.gif') no-repeat 0 center}.flag_ir353{background:url('images/flags/ir353.gif') no-repeat 0 center}.flag_ir964{background:url('images/flags/ir964.gif') no-repeat 0 center}.flag_ir98{background:url('images/flags/ir98.gif') no-repeat 0 center}.flag_is972{background:url('images/flags/is972.gif') no-repeat 0 center}.flag_it39{background:url('images/flags/it39.gif') no-repeat 0 center}.flag_ja1876{background:url('images/flags/ja1876.gif') no-repeat 0 center}.flag_ja81{background:url('images/flags/ja81.gif') no-repeat 0 center}.flag_jo962{background:url('images/flags/jo962.gif') no-repeat 0 center}.flag_ka7{background:url('images/flags/ka7.gif') no-repeat 0 center}.flag_ke254{background:url('images/flags/ke254.gif') no-repeat 0 center}.flag_ki686{background:url('images/flags/ki686.gif') no-repeat 0 center}.flag_ko82{background:url('images/flags/ko82.gif') no-repeat 0 center}.flag_ko850{background:url('images/flags/ko850.gif') no-repeat 0 center}.flag_ku965{background:url('images/flags/ku965.gif') no-repeat 0 center}.flag_ky996{background:url('images/flags/ky996.gif') no-repeat 0 center}.flag_la371{background:url('images/flags/la371.gif') no-repeat 0 center}.flag_la856{background:url('images/flags/la856.gif') no-repeat 0 center}.flag_le266{background:url('images/flags/le266.gif') no-repeat 0 center}.flag_le961{background:url('images/flags/le961.gif') no-repeat 0 center}.flag_li218{background:url('images/flags/li218.gif') no-repeat 0 center}.flag_li231{background:url('images/flags/li231.gif') no-repeat 0 center}.flag_li370{background:url('images/flags/li370.gif') no-repeat 0 center}.flag_li423{background:url('images/flags/li423.gif') no-repeat 0 center}.flag_lu352{background:url('images/flags/lu352.gif') no-repeat 0 center}.flag_ma222{background:url('images/flags/ma222.gif') no-repeat 0 center}.flag_ma223{background:url('images/flags/ma223.gif') no-repeat 0 center}.flag_ma230{background:url('images/flags/ma230.gif') no-repeat 0 center}.flag_ma261{background:url('images/flags/ma261.gif') no-repeat 0 center}.flag_ma262{background:url('images/flags/ma262.gif') no-repeat 0 center}.flag_ma265{background:url('images/flags/ma265.gif') no-repeat 0 center}.flag_ma356{background:url('images/flags/ma356.gif') no-repeat 0 center}.flag_ma389{background:url('images/flags/ma389.gif') no-repeat 0 center}.flag_ma596{background:url('images/flags/ma596.gif') no-repeat 0 center}.flag_ma60{background:url('images/flags/ma60.gif') no-repeat 0 center}.flag_ma692{background:url('images/flags/ma692.gif') no-repeat 0 center}.flag_ma853{background:url('images/flags/ma853.gif') no-repeat 0 center}.flag_ma960{background:url('images/flags/ma960.gif') no-repeat 0 center}.flag_me52{background:url('images/flags/me52.gif') no-repeat 0 center}.flag_mi691{background:url('images/flags/mi691.gif') no-repeat 0 center}.flag_mo1664{background:url('images/flags/mo1664.gif') no-repeat 0 center}.flag_mo212{background:url('images/flags/mo212.gif') no-repeat 0 center}.flag_mo258{background:url('images/flags/mo258.gif') no-repeat 0 center}.flag_mo373{background:url('images/flags/mo373.gif') no-repeat 0 center}.flag_mo377{background:url('images/flags/mo377.gif') no-repeat 0 center}.flag_mo382{background:url('images/flags/mo382.gif') no-repeat 0 center}.flag_mo976{background:url('images/flags/mo976.gif') no-repeat 0 center}.flag_my95{background:url('images/flags/my95.gif') no-repeat 0 center}.flag_na264{background:url('images/flags/na264.gif') no-repeat 0 center}.flag_na674{background:url('images/flags/na674.gif') no-repeat 0 center}.flag_ne31{background:url('images/flags/ne31.gif') no-repeat 0 center}.flag_ne599{background:url('images/flags/ne599.gif') no-repeat 0 center}.flag_ne64{background:url('images/flags/ne64.gif') no-repeat 0 center}.flag_ne687{background:url('images/flags/ne687.gif') no-repeat 0 center}.flag_ne977{background:url('images/flags/ne977.gif') no-repeat 0 center}.flag_ni227{background:url('images/flags/ni227.gif') no-repeat 0 center}.flag_ni234{background:url('images/flags/ni234.gif') no-repeat 0 center}.flag_ni505{background:url('images/flags/ni505.gif') no-repeat 0 center}.flag_ni683{background:url('images/flags/ni683.gif') no-repeat 0 center}.flag_no1670{background:url('images/flags/no1670.gif') no-repeat 0 center}.flag_no47{background:url('images/flags/no47.gif') no-repeat 0 center}.flag_no672{background:url('images/flags/no672.gif') no-repeat 0 center}.flag_om968{background:url('images/flags/om968.gif') no-repeat 0 center}.flag_pa507{background:url('images/flags/pa507.gif') no-repeat 0 center}.flag_pa595{background:url('images/flags/pa595.gif') no-repeat 0 center}.flag_pa675{background:url('images/flags/pa675.gif') no-repeat 0 center}.flag_pa680{background:url('images/flags/pa680.gif') no-repeat 0 center}.flag_pa92{background:url('images/flags/pa92.gif') no-repeat 0 center}.flag_pa970{background:url('images/flags/pa970.gif') no-repeat 0 center}.flag_pe51{background:url('images/flags/pe51.gif') no-repeat 0 center}.flag_ph63{background:url('images/flags/ph63.gif') no-repeat 0 center}.flag_pi64{background:url('images/flags/pi64.gif') no-repeat 0 center}.flag_po351{background:url('images/flags/po351.gif') no-repeat 0 center}.flag_po48{background:url('images/flags/po48.gif') no-repeat 0 center}.flag_pu1939{background:url('images/flags/pu1939.gif') no-repeat 0 center}.flag_qa974{background:url('images/flags/qa974.gif') no-repeat 0 center}.flag_re262{background:url('images/flags/re262.gif') no-repeat 0 center}.flag_ro40{background:url('images/flags/ro40.gif') no-repeat 0 center}.flag_ru7{background:url('images/flags/ru7.gif') no-repeat 0 center}.flag_rw250{background:url('images/flags/rw250.gif') no-repeat 0 center}.flag_sa1758{background:url('images/flags/sa1758.gif') no-repeat 0 center}.flag_sa1784{background:url('images/flags/sa1784.gif') no-repeat 0 center}.flag_sa1869{background:url('images/flags/sa1869.gif') no-repeat 0 center}.flag_sa239{background:url('images/flags/sa239.gif') no-repeat 0 center}.flag_sa290{background:url('images/flags/sa290.gif') no-repeat 0 center}.flag_sa378{background:url('images/flags/sa378.gif') no-repeat 0 center}.flag_sa508{background:url('images/flags/sa508.gif') no-repeat 0 center}.flag_sa685{background:url('images/flags/sa685.gif') no-repeat 0 center}.flag_sa966{background:url('images/flags/sa966.gif') no-repeat 0 center}.flag_se221{background:url('images/flags/se221.gif') no-repeat 0 center}.flag_se248{background:url('images/flags/se248.gif') no-repeat 0 center}.flag_se381{background:url('images/flags/se381.gif') no-repeat 0 center}.flag_si232{background:url('images/flags/si232.gif') no-repeat 0 center}.flag_si65{background:url('images/flags/si65.gif') no-repeat 0 center}.flag_sl386{background:url('images/flags/sl386.gif') no-repeat 0 center}.flag_sl421{background:url('images/flags/sl421.gif') no-repeat 0 center}.flag_so252{background:url('images/flags/so252.gif') no-repeat 0 center}.flag_so27{background:url('images/flags/so27.gif') no-repeat 0 center}.flag_so677{background:url('images/flags/so677.gif') no-repeat 0 center}.flag_sp34{background:url('images/flags/sp34.gif') no-repeat 0 center}.flag_sr94{background:url('images/flags/sr94.gif') no-repeat 0 center}.flag_su249{background:url('images/flags/su249.gif') no-repeat 0 center}.flag_su597{background:url('images/flags/su597.gif') no-repeat 0 center}.flag_sv47{background:url('images/flags/sv47.gif') no-repeat 0 center}.flag_sw268{background:url('images/flags/sw268.gif') no-repeat 0 center}.flag_sw41{background:url('images/flags/sw41.gif') no-repeat 0 center}.flag_sw46{background:url('images/flags/sw46.gif') no-repeat 0 center}.flag_sy963{background:url('images/flags/sy963.gif') no-repeat 0 center}.flag_ta255{background:url('images/flags/ta255.gif') no-repeat 0 center}.flag_ta886{background:url('images/flags/ta886.gif') no-repeat 0 center}.flag_ta992{background:url('images/flags/ta992.gif') no-repeat 0 center}.flag_th66{background:url('images/flags/th66.gif') no-repeat 0 center}.flag_ti670{background:url('images/flags/ti670.gif') no-repeat 0 center}.flag_to228{background:url('images/flags/to228.gif') no-repeat 0 center}.flag_to676{background:url('images/flags/to676.gif') no-repeat 0 center}.flag_to690{background:url('images/flags/to690.gif') no-repeat 0 center}.flag_tr1868{background:url('images/flags/tr1868.gif') no-repeat 0 center}.flag_tu1649{background:url('images/flags/tu1649.gif') no-repeat 0 center}.flag_tu216{background:url('images/flags/tu216.gif') no-repeat 0 center}.flag_tu688{background:url('images/flags/tu688.gif') no-repeat 0 center}.flag_tu90{background:url('images/flags/tu90.gif') no-repeat 0 center}.flag_tu993{background:url('images/flags/tu993.gif') no-repeat 0 center}.flag_ug256{background:url('images/flags/ug256.gif') no-repeat 0 center}.flag_uk380{background:url('images/flags/uk380.gif') no-repeat 0 center}.flag_un1{background:url('images/flags/un1.gif') no-repeat 0 center}.flag_un44{background:url('images/flags/un44.gif') no-repeat 0 center}.flag_un971{background:url('images/flags/un971.gif') no-repeat 0 center}.flag_ur598{background:url('images/flags/ur598.gif') no-repeat 0 center}.flag_uz998{background:url('images/flags/uz998.gif') no-repeat 0 center}.flag_va678{background:url('images/flags/va678.gif') no-repeat 0 center}.flag_ve58{background:url('images/flags/ve58.gif') no-repeat 0 center}.flag_vi1284{background:url('images/flags/vi1284.gif') no-repeat 0 center}.flag_vi1340{background:url('images/flags/vi1340.gif') no-repeat 0 center}.flag_vi84{background:url('images/flags/vi84.gif') no-repeat 0 center}.flag_wa681{background:url('images/flags/wa681.gif') no-repeat 0 center}.flag_wales{background:url('images/flags/wales.gif') no-repeat 0 center}.flag_we212{background:url('images/flags/we212.gif') no-repeat 0 center}.flag_ye967{background:url('images/flags/ye967.gif') no-repeat 0 center}.flag_za260{background:url('images/flags/za260.gif') no-repeat 0 center}.flag_zi263{background:url('images/flags/zi263.gif') no-repeat 0 center}.aflag{width:16px;height:12px;display:inline-block}.countries-autocomplete{background-color:#fff;border:1px solid #ccc}.countries-autocomplete ul{margin:0;padding:0}.countries-autocomplete li{list-style-type:none;padding:5px 10px;font-size:12px;font-family:arial}.countries-autocomplete li:hover,.countries-autocomplete li.active{cursor:pointer;background-color:#eee}#authy-tooltip-close{position:absolute;top:5px;right:5px;cursor:pointer;width:11px;height:11px;background:url('images/close.gif') no-repeat 0 0}#authy-token{padding:3px 0 3px 25px;background:url('images/icon.png') no-repeat 2px center;background-size:20px 15px}#authy-tooltip{position:absolute;z-index:999999;border:1px solid #ccc;-moz-border-radius:6px;-webkit-border-radius:6px;border-radius:6px;padding:10px;background-color:#fff;display:none;width:330px}#authy-tooltip p{color:#444}.countries-autocomplete{position:absolute;width:200px;display:none;max-height:200px;overflow:auto;z-index:99999999}#authy-help{color:#35c2f1}#authy-help:hover{text-decoration:none} \ No newline at end of file diff --git a/src/form.authy.min.js b/src/form.authy.min.js index d26295d..6fea3e4 100644 --- a/src/form.authy.min.js +++ b/src/form.authy.min.js @@ -1 +1 @@ -var Authy={};if(document.getElementsByClassName==null){document.getElementsByClassName=function(d,a){var c=(a||document.body).getElementsByTagName("*");var f=[],g;for(var b=0,e=c.length;b

    '+b+'

    '+e+"

    ";document.body.appendChild(s);document.getElementById("authy-help").onclick=function(){document.getElementById("authy-tooltip").style.display="block"};document.getElementById("authy-tooltip-close").onclick=function(){document.getElementById("authy-tooltip").style.display="none"}};var h=function(q){var t="countries-autocomplete-"+q;var s=document.getElementById(t).getElementsByTagName("li");for(var r=0;r=0;r--){if(document.getElementById(t).getElementsByTagName("li")[r].className=="active"){document.getElementById(t).getElementsByTagName("li")[r].className="";if(r==0){document.getElementById(t).getElementsByTagName("li")[s.length-1].className="active"}else{document.getElementById(t).getElementsByTagName("li")[r-1].className="active"}return false}}document.getElementById(t).getElementsByTagName("li")[0].setAttribute("class","active")};var f=function(q){var r=document.getElementById("countries-autocomplete-"+q).getElementsByClassName("active")[0];n.autocomplete(r);return false};var k=function(q,r){if(!q){return}q.onfocus=function(){document.getElementById("countries-autocomplete-"+r).style.display="block"};q.onblur=function(){setTimeout(function(){document.getElementById("countries-autocomplete-"+r).style.display="none"},200)};q.onkeyup=function(s){document.getElementById("countries-autocomplete-"+r).style.display="block";var t=window.event.keyCode;switch(t){case 13:f(r);return false;break;case 40:if(h(r)==false){return false}break;case 38:if(g(r)==false){return false}break}n.searchItem(r)};q.onkeypress=function(s){if(window.event.keyCode==13){f(r);return false}};document.getElementById("countries-autocomplete-"+r).onclick=function(s){if(s&&s.stopPropagation){s.stopPropagation()}else{s=window.event;s.cancelBubble=true}};document.getElementById("countries-input-"+r).onclick=function(s){if(s&&s.stopPropagation){s.stopPropagation();q.focus();q.select()}else{s=window.event;s.cancelBubble=true}};document.onclick=function(){document.getElementById("countries-autocomplete-"+r).style.display="none"}};var a=function(q,s,r){var t=s.country.substring(0,2).toLowerCase()+s.code;return'
  • (+'+s.code+") "+s.country+"
  • "};var l=function(r){var s=0;var q=0;while(r){s+=r.offsetTop;q+=r.offsetLeft;r=r.offsetParent}return[s,q]};var j=function(x,u){if(!x){return}var B=[];for(var t=0;t";y.innerHTML=v;document.body.appendChild(y);var q=document.createElement("input");q.setAttribute("id","countries-input-"+u);q.setAttribute("class","countries-input");q.setAttribute("type","text");q.setAttribute("autocomplete","off");x.parentNode.insertBefore(q,x);x.parentNode.appendChild(A);var z=l(q);y.setAttribute("id","countries-autocomplete-"+u);y.setAttribute("class","countries-autocomplete");y.setAttribute("style","width: "+(q.offsetWidth-5)+"px; top: "+(z[0]+27)+"px; left: "+z[1]+"px;");k(q,u)};var p=function(){j(document.getElementById("authy-countries"),0);var q=document.getElementsByClassName("authy-countries");for(var r=0;r2&&A[t].match(r)){w+=a(x,s,v);x="";z=true;break}}}w+="";if(z){document.getElementById("countries-autocomplete-"+v).innerHTML=w}};this.autocomplete=function(r){var q=r.getAttribute("data-list-id");document.getElementById("countries-input-"+q).value=r.getAttribute("data-name");document.getElementById("countries-autocomplete-"+q).style.display="none";document.getElementById("country-code-"+q).value=r.getAttribute("rel")};this.setTooltip=function(s,r){var q=document.getElementById("authy-tooltip");if(!q){return}q.getElementsByClassName("tooltip-title")[0].innerHTML=s;q.getElementsByClassName("tooltip-content")[0].innerHTML=r}};Authy.UI.instance=function(){if(!this.ui){this.ui=new Authy.UI();this.ui.init()}return this.ui};window.onload=function(){Authy.UI.instance()}; \ No newline at end of file +(function(){var Authy;Authy={};if(document.getElementsByClassName==null){document.getElementsByClassName=function(className,parentElement){var child,children,elements,i,length;children=(parentElement||document.body).getElementsByTagName("*");elements=[];child=void 0;i=0;length=children.length;while(i

    '+tooltipTitle+'

    '+tooltipMessage+"

    ";document.body.appendChild(tooltip);document.getElementById("authy-help").onclick=function(){return document.getElementById("authy-tooltip").style.display="block"};document.getElementById("authy-tooltip-close").onclick=function(){return document.getElementById("authy-tooltip").style.display="none"}};processKey40=function(listId){var caId,countriesArr,i;caId="countries-autocomplete-"+listId;countriesArr=document.getElementById(caId).getElementsByTagName("li");i=0;while(i=0){if(document.getElementById(caId).getElementsByTagName("li")[i].className==="active"){document.getElementById(caId).getElementsByTagName("li")[i].className="";if(i===0){document.getElementById(caId).getElementsByTagName("li")[countriesArr.length-1].className="active"}else{document.getElementById(caId).getElementsByTagName("li")[i-1].className="active"}return false}i--}document.getElementById(caId).getElementsByTagName("li")[0].setAttribute("class","active")};processKey13=function(listId){var obj;obj=document.getElementById("countries-autocomplete-"+listId).getElementsByClassName("active")[0];self.autocomplete(obj);return false};setupEvents=function(countriesInput,listId){if(!countriesInput){return}countriesInput.onfocus=function(){return document.getElementById("countries-autocomplete-"+listId).style.display="block"};countriesInput.onblur=function(){return setTimeout((function(){return document.getElementById("countries-autocomplete-"+listId).style.display="none"}),200)};countriesInput.onkeyup=function(event){var keyID;document.getElementById("countries-autocomplete-"+listId).style.display="block";keyID=window.event.keyCode;switch(keyID){case 13:processKey13(listId);return false;case 40:if(processKey40(listId)===false){return false}break;case 38:if(processKey38(listId)===false){return false}}return self.searchItem(listId)};countriesInput.onkeypress=function(event){if(window.event.keyCode===13){processKey13(listId);return false}};document.getElementById("countries-autocomplete-"+listId).onclick=function(e){if(e&&e.stopPropagation){return e.stopPropagation()}else{e=window.event;return e.cancelBubble=true}};document.getElementById("countries-input-"+listId).onclick=function(e){if(e&&e.stopPropagation){e.stopPropagation();countriesInput.focus();return countriesInput.select()}else{e=window.event;return e.cancelBubble=true}};return document.onclick=function(){document.getElementById("countries-autocomplete-"+listId).style.display="none"}};buildItem=function(classActive,country,listId){var cc;cc=country.country.substring(0,2).toLowerCase()+country.code;return'
  • (+'+country.code+") "+country.country+"
  • "};absolutePosFor=function(element){var absLeft,absTop;absTop=0;absLeft=0;while(element){absTop+=element.offsetTop;absLeft+=element.offsetLeft;element=element.offsetParent}return[absTop,absLeft]};setupCountriesDropdown=function(countriesSelect,listId){var buf,classActive,countries,countriesAutocomplete,countriesAutocompleteHTML,countriesInput,countryCodeValue,i,name,pos;if(!countriesSelect){return}countries=[];i=0;while(i";i=0;while(i";countriesAutocomplete.innerHTML=countriesAutocompleteHTML;document.body.appendChild(countriesAutocomplete);countriesInput=document.createElement("input");countriesInput.setAttribute("id","countries-input-"+listId);countriesInput.setAttribute("class","countries-input");countriesInput.setAttribute("type","text");countriesInput.setAttribute("autocomplete","off");countriesSelect.parentNode.insertBefore(countriesInput,countriesSelect);countriesSelect.parentNode.appendChild(countryCodeValue);pos=absolutePosFor(countriesInput);countriesAutocomplete.setAttribute("id","countries-autocomplete-"+listId);countriesAutocomplete.setAttribute("class","countries-autocomplete");countriesAutocomplete.setAttribute("style","width: "+(countriesInput.offsetWidth-5)+"px; top: "+(pos[0]+27)+"px; left: "+pos[1]+"px;");return setupEvents(countriesInput,listId)};findAndSetupCountries=function(){var countries,i;setupCountriesDropdown(document.getElementById("authy-countries"),0);countries=document.getElementsByClassName("authy-countries");i=0;while(i";matches=false;str=str.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&");reg=new RegExp("^"+str,"i");i=0;while(i2&&countryWords[cw].match(reg)){countriesAutocompleteHTML+=buildItem(classActive,countryItem,listId);classActive="";matches=true;break}cw++}i++}countriesAutocompleteHTML+="";if(matches){return document.getElementById("countries-autocomplete-"+listId).innerHTML=countriesAutocompleteHTML}};this.autocomplete=function(obj){var listId;listId=obj.getAttribute("data-list-id");document.getElementById("countries-input-"+listId).value=obj.getAttribute("data-name");document.getElementById("countries-autocomplete-"+listId).style.display="none";return document.getElementById("country-code-"+listId).value=obj.getAttribute("rel")};return this.setTooltip=function(title,msg){var tooltip;tooltip=document.getElementById("authy-tooltip");if(!tooltip){return}tooltip.getElementsByClassName("tooltip-title")[0].innerHTML=title;return tooltip.getElementsByClassName("tooltip-content")[0].innerHTML=msg}};Authy.UI.instance=function(){if(!this.ui){this.ui=new Authy.UI();this.ui.init()}return this.ui};window.onload=function(){return Authy.UI.instance()}}).call(this); \ No newline at end of file diff --git a/src/images/icon.png b/src/images/icon.png index 939ebaecc5b0e9b76a08b70b51b3ab9a2e88e55a..1f3d4b7052843e570fcb4f8af2d91b97eabe7ef0 100644 GIT binary patch delta 1047 zcmV+y1nB#f2CfJ;iBL{Q4GJ0x0000DNk~Le0000b0000T2nGNE0a~z?RR91032;bR za{vGf6951U69E94oEVWICw~LGNklt!#+9P z_aN18WK{k^>HiEM22kQZOaO?(0Ro5-tC=vfKs4AqAYg$R?)dmNBb0prX678Id0?{v z0tjp-P^&yp(F3TF{~aG*VuBeZ3^joTsOUF{21+u*EC<`o#K`~>gMVr$ggYH%6_WE| zev^k;4OR%lK*iz6d}Is|Kv?~a4p`vsfdZI2q3*g1^oR;Pu%ME2L41(!p}tfGDxL!m zcOwW8Af65~09hU& z0Ap2bgFp-erF48p2OT4@0Ah?EfCXrnfesend*~S9H(&vJN;1 ztV`D9ut60p0e{F4nNn}ny!}oD_+^DEkq&y-Cn##zoh*-FJ%GI}zfJ{qp2ki~z%X{s zWwWgiOF0Xe?tUqqnCa*U&6@_WwordSpcNSrrx63&hwI;g(Jt%A(TQHgR2<^x63Gf3 zot2aQ2{l^{((k}93~Zs}VupCtoP14j`pwtp>`|!2SAT#}tr)?P9zl+pfh6<*=nF%l zYJO}0>dRIjmdBwEl-PFyaRIEd!2%?KSOAG{fZU=WDx{zeSx%sY!UaHaYJl!Q^nwQs zV09dFWA6^0kOPIvO=wjjgD3Q0YBfo8+y&%l1r@vKbwAt}K!a8A1r5|Q*Fl9J6&weO zGDV={9)E%yg{@ZV02)?FY`l@_xb;Zw8bQkS>Nemo@*oyRp|&>(g%;3J$kjdrF2|8jj$tzoUcumM z0m55}SZXO{N*ss7j6XoVtjNtUQ1w`W!wga#2Ush&)&lWvkRw5DL1>KF;V1{c!|E(- z^%cJIgdE2a0vMr-v+l#=IGni?=r~ZXV*wEk1ZA#;&;}jp6*3mbkzHgE3jkvLn}^Sm RLreew002ovPDHLkV1i;|tZx7S delta 764 zcmV?>-f%pRuI|@C%eF0gX1;*GfrzZfU5`fqrh#jE9AjKPjc!J}j zOCP`*%uFKwoH_$y3NSD;A9^RNYKLqn6VxyRMkc0!~2yz)Ce>2mg|9}7S!UP2@Ou+P)Yd0DGeEJMg$jtN^s3y+g z;l%_0-+wstDKbv?@73!N4b04+frf)!%6L%Cbm_kzKcm35YpF9Btenfh!pD06#Q*d0 zli{7_9{v}rHzEg9BGAwc7>2U3J!AOwOPh(2kud}uHhjDc`pafr2GW8+e=$c8X5r^k z(CBGeAQ9@1Y~cI@^7;Xcf&zAY%NJc{wKRu_{`w^a6w74#`~3$Sh%fAH_lp&%2x!m; zXlxb$!^Q!~PsCxU0LW0Tw#F0i@Z;f0g2(c|pTF)P8wQOa5W5g$=>Px!LEHq8_d&i< zYpLb~ia!8~M>5Gs-~adIe<=f#fPe_xzz@ey%YY&Xlsq`|vvt2uoC=fb2O6pmGgKxi zI)Ryo`xB>}%p<7$1CU|xWCQcc@An`0m^j$Mrf`-NZ07FkMD}6=(9roHLxB-z2sBI| z<{MzJ6u=FWl=#5}v~dl{3t(>pV;ks7kj4${p+Sk*3s%m$F5K$jjubEzZHr3Zj= z0slXKT<~kxUjE-ZQui?Y|MUqg$?E39z~T0000 - - - - -
    - Authy tocken: -
    - Authy help: help -
    - Authy countries: - -
    - New Authy countries: - -
    - - Authy cellphone: -
    -
    - - - - -