diff --git a/user/config/site.yaml b/user/config/site.yaml
index c45818d..8e0ce02 100644
--- a/user/config/site.yaml
+++ b/user/config/site.yaml
@@ -1,7 +1,35 @@
-title: Grav
-author:
- name: Joe Bloggs
- email: 'joe@test.com'
-metadata:
- description: 'Grav is an easy to use, yet powerful, open source flat-file CMS'
+title: La Bonne Adresse # Name of the site
+author:
+ name: Bachir Soussi Chiadmi # Default author name
+ # email: 'john@email.com' # Default author email
+
+taxonomies: [tag] # Arbitrary list of taxonomy types
+#[édition,édition jeunesse,art,identité visuelle,signalétique,évènement
+
+metadata:
+ description: 'Créations Graphiques' # Site description
+
+summary:
+ enabled: true # enable or disable summary of page
+ format: short # long = summary delimiter will be ignored; short = use the first occurrence of delimiter or size
+ size: 300 # Maximum length of summary (characters)
+ delimiter: === # The summary delimiter
+
+# redirects:
+# /redirect-test: / # Redirect test goes to home page
+# /old/(.*): /new/$1 # Would redirect /old/my-page to /new/my-page
+#
+# routes:
+# /something/else: '/blog/sample-3' # Alias for /blog/sample-3
+# /new/(.*): '/blog/$1' # Regex any /new/my-page URL to /blog/my-page Route
+#
+# blog:
+# route: '/blog' # Custom value added (accessible via system.blog.route)
+
+#menu: # Sample Menu Example
+# - text: Source
+# icon: github
+# url: https://github.com/getgrav/grav
+# - icon: twitter
+# url: http://twitter.com/getgrav
diff --git a/user/config/system.yaml b/user/config/system.yaml
index 21dd89b..974bc50 100644
--- a/user/config/system.yaml
+++ b/user/config/system.yaml
@@ -1,17 +1,17 @@
absolute_urls: false
home:
- alias: '/home'
+ alias: '/projets'
pages:
- theme: antimatter
+ theme: labonneadresse
markdown_extra: false
process:
markdown: true
twig: false
cache:
- enabled: true
+ enabled: false
check:
method: file
driver: auto
diff --git a/user/pages/01.home/default.md b/user/pages/01.home/default.md
deleted file mode 100644
index 64ea8ae..0000000
--- a/user/pages/01.home/default.md
+++ /dev/null
@@ -1,39 +0,0 @@
----
-title: Home
----
-
-# Grav is Running!
-## You have installed **Grav** successfully
-
-Congratulations! You have installed the **Base Grav Package** that provides a **simple page** and the default **antimatter** theme to get you started.
-
->>>>> If you want a more **full-featured** base install, you should check out [**Skeleton** packages available in the downloads](http://getgrav.org/downloads).
-
-### Find out all about Grav
-
-* Learn about **Grav** by checking out our dedicated [Learn Grav](http://learn.getgrav.org) site.
-* Download **plugins**, **themes**, as well as other Grav **skeleton** packages from the [Grav Downloads](http://getgrav.org/downloads) page.
-* Check out our [Grav Development Blog](http://getgrav.org/blog) to find out the latest goings on in the Grav-verse.
-
-### Edit this Page
-
-To edit this page, simply navigate to the folder you installed **Grav** into, and then browse to the `user/pages/01.home` folder and open the `default.md` file in your [editor of choice](http://learn.getgrav.org/basics/requirements). You will see the content of this page in [Markdown format](http://learn.getgrav.org/content/markdown).
-
-### Create a New Page
-
-Creating a new page is a simple affair in **Grav**. Simply follow these simple steps:
-
-1. Navigate to your pages folder: `user/pages/` and create a new folder. In this example, we will use [explicit default ordering](http://learn.getgrav.org/content/content-pages) and call the folder `02.mypage`.
-2. Launch your text editor and paste in the following sample code:
-
- ---
- title: My New Page
- ---
- # My New Page!
-
- This is the body of **my new page** and I can easily use _Markdown_ syntax here.
-
-3. Save this file in the `user/pages/02.mypage/` folder as `default.md`. This will tell **Grav** to render the page using the **default** template.
-4. That is it! Reload your browser to see your new page in the menu.
-
->>> NOTE: The page will automatically show up in the Menu after the "Home" menu item. If you wish to change the name that shows up in the Menu, simple add: `menu: My Page` between the dashes in the page content. This is called the YAML front matter, and it is where you configure page-specific options.
diff --git a/user/pages/01.projets/home.md b/user/pages/01.projets/home.md
new file mode 100644
index 0000000..fc4da23
--- /dev/null
+++ b/user/pages/01.projets/home.md
@@ -0,0 +1,7 @@
+---
+title: Home
+menu : home
+content:
+ items:
+ @self.descendants
+---
diff --git a/user/pages/01.projets/projet1/projet.md b/user/pages/01.projets/projet1/projet.md
new file mode 100644
index 0000000..71007bb
--- /dev/null
+++ b/user/pages/01.projets/projet1/projet.md
@@ -0,0 +1,9 @@
+---
+title: Projet1
+visible: true
+taxonomy:
+ category: projets
+ tag: [édition, art, évènement]
+---
+
+hello :)
diff --git a/user/pages/01.projets/projet2/projet.md b/user/pages/01.projets/projet2/projet.md
new file mode 100644
index 0000000..172887a
--- /dev/null
+++ b/user/pages/01.projets/projet2/projet.md
@@ -0,0 +1,11 @@
+---
+title: Projet2
+visible: true
+taxonomy:
+ category: projets
+ tag: [édition jeunesse, art, évènement]
+---
+
+hello :)
+
+Haec Scipionis oratio, quod senatus in urbe habebatur Pompeiusque aberat, ex ipsius ore Pompei mitti videbatur. Dixerat aliquis leniorem sententiam, ut primo M. Marcellus, ingressus in eam orationem, non oportere ante de ea re ad senatum referri, quam dilectus tota Italia habiti et exercitus conscripti essent, quo praesidio tuto et libere senatus, quae vellet, decernere auderet; ut M. Calidius, qui censebat, ut Pompeius in suas provincias proficisceretur, ne qua esset armorum causa: timere Caesarem ereptis ab eo duabus legionibus, ne ad ejus periculum reservare et retinere eas ad urbem Pompeius videretur; ut M. Rufus, qui sententiam Calidii paucis fere
diff --git a/user/pages/01.projets/projet3/projet.md b/user/pages/01.projets/projet3/projet.md
new file mode 100644
index 0000000..aedd757
--- /dev/null
+++ b/user/pages/01.projets/projet3/projet.md
@@ -0,0 +1,5 @@
+---
+title: Projet3
+---
+
+hello :)
diff --git a/user/pages/01.projets/projet4/projet.md b/user/pages/01.projets/projet4/projet.md
new file mode 100644
index 0000000..1fd8232
--- /dev/null
+++ b/user/pages/01.projets/projet4/projet.md
@@ -0,0 +1,7 @@
+---
+title: Projet4
+---
+
+hello :)
+
+Haec Scipionis oratio, quod senatus in urbe habebatur Pompeiusque aberat, ex ipsius ore Pompei mitti videbatur. Dixerat aliquis leniorem sententiam, ut primo M. Marcellus, ingressus in eam orationem, non oportere ante de ea re ad senatum referri, quam dilectus tota Italia habiti et exercitus conscripti essent, quo praesidio tuto et
diff --git a/user/pages/01.projets/projet5/projet.md b/user/pages/01.projets/projet5/projet.md
new file mode 100644
index 0000000..6d99a82
--- /dev/null
+++ b/user/pages/01.projets/projet5/projet.md
@@ -0,0 +1,9 @@
+---
+title: Projet5
+---
+
+hello :)
+
+Haec Scipionis oratio, quod senatus in urbe habebatur Pompeiusque aberat, ex ipsius ore Pompei mitti videbatur. Dixerat aliquis leniorem sententiam, ut primo M. Marcellus, ingressus in eam orationem, non oportere ante de ea re ad senatum referri, quam dilectus tota Italia habiti et exercitus conscripti essent, quo praesidio tuto et libere senatus, quae vellet, decernere auderet; ut M. Calidius, qui censebat, ut Pompeius in suas provincias proficisceretur, ne qua esset armorum causa: timere Caesarem ereptis ab eo duabus legionibus, ne ad ejus periculum reservare et retinere eas ad urbem Pompeius videretur; ut M. Rufus, qui sententiam Calidii paucis fere
+Haec Scipionis oratio, quod senatus in urbe habebatur Pompeiusque aberat, ex ipsius ore Pompei mitti videbatur. Dixerat aliquis leniorem sententiam, ut primo M. Marcellus, ingressus in eam orationem, non oportere ante de ea re ad senatum referri, quam dilectus tota Italia habiti et exercitus conscripti essent, quo praesidio tuto et libere senatus, quae vellet, decernere auderet; ut M. Calidius, qui censebat, ut Pompeius in suas provincias proficisceretur, ne qua esset armorum causa: timere Caesarem ereptis ab eo duabus legionibus, ne ad ejus periculum reservare et retinere eas ad urbem Pompeius videretur; ut M. Rufus, qui sententiam Calidii paucis fere
+Haec Scipionis oratio, quod senatus in urbe habebatur Pompeiusque aberat, ex ipsius ore Pompei mitti videbatur. Dixerat aliquis leniorem sententiam, ut primo M. Marcellus, ingressus in eam orationem, non oportere ante de ea re ad senatum referri, quam dilectus tota Italia habiti et exercitus conscripti essent, quo praesidio tuto et libere senatus, quae vellet, decernere auderet; ut M. Calidius, qui censebat, ut Pompeius in suas provincias proficisceretur, ne qua esset armorum causa: timere Caesarem ereptis ab eo duabus legionibus, ne ad ejus periculum reservare et retinere eas ad urbem Pompeius videretur; ut M. Rufus, qui sententiam Calidii paucis fere
diff --git a/user/pages/02.statics/default.md b/user/pages/02.statics/default.md
new file mode 100644
index 0000000..ffc81da
--- /dev/null
+++ b/user/pages/02.statics/default.md
@@ -0,0 +1,6 @@
+---
+title: à propos
+menu: à propos
+---
+
+Hello :)
diff --git a/user/plugins/taxonomylist/CHANGELOG.md b/user/plugins/taxonomylist/CHANGELOG.md
new file mode 100644
index 0000000..dcea211
--- /dev/null
+++ b/user/plugins/taxonomylist/CHANGELOG.md
@@ -0,0 +1,41 @@
+# v1.2.6
+## 10/07/2015
+
+2. [](#improved)
+ * Added `active` class on active taxonomies
+
+# v1.2.5
+## 07/19/2015
+
+2. [](#improved)
+ * Set the taxonomy type from the taxonomy being passed in
+
+# v1.2.4
+## 02/19/2015
+
+2. [](#improved)
+ * Implemented new `param_sep` variable from Grav 0.9.18
+
+# v1.2.3
+## 02/05/2015
+
+2. [](#improved)
+ * Added support for HHVM
+
+# v1.2.2
+## 01/09/2015
+
+2. [](#improved)
+ * NOTE: BREAKING CHANGE: Moved templates into `partials/` subfolder for consistency.
+
+# v1.2.1
+## 01/07/2015
+
+1. [](#bugfix)
+ * Support for numeric taxonomy values
+
+# v1.2.0
+## 11/30/2014
+
+1. [](#new)
+ * ChangeLog started...
diff --git a/user/plugins/taxonomylist/LICENSE b/user/plugins/taxonomylist/LICENSE
new file mode 100644
index 0000000..484793a
--- /dev/null
+++ b/user/plugins/taxonomylist/LICENSE
@@ -0,0 +1,21 @@
+The MIT License (MIT)
+
+Copyright (c) 2014 Grav
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all
+copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
+SOFTWARE.
diff --git a/user/plugins/taxonomylist/README.md b/user/plugins/taxonomylist/README.md
new file mode 100644
index 0000000..01887a4
--- /dev/null
+++ b/user/plugins/taxonomylist/README.md
@@ -0,0 +1,44 @@
+# Grav Taxonomy List Plugin
+
+`Taxonomylist` is a [Grav](http://github.com/getgrav/grav) plugin that generates a list of linked tags collected throughout the site.
+
+
+
+# Installation
+
+Installing the Taxonomy List plugin can be done in one of two ways. Our GPM (Grav Package Manager) installation method enables you to quickly and easily install the plugin with a simple terminal command, while the manual method enables you to do so via a zip file.
+
+## GPM Installation (Preferred)
+
+The simplest way to install this plugin is via the [Grav Package Manager (GPM)](http://learn.getgrav.org/advanced/grav-gpm) through your system's Terminal (also called the command line). From the root of your Grav install type:
+
+ bin/gpm install taxonomylist
+
+This will install the Taxonomy List plugin into your `/user/plugins` directory within Grav. Its files can be found under `/your/site/grav/user/plugins/taxonomylist`.
+
+## Manual Installation
+
+To install this plugin, just download the zip version of this repository and unzip it under `/your/site/grav/user/plugins`. Then, rename the folder to `taxonomylist`. You can find these files either on [GitHub](https://github.com/getgrav/grav-plugin-taxonomylist) or via [GetGrav.org](http://getgrav.org/downloads/plugins#extras).
+
+You should now have all the plugin files under
+
+ /your/site/grav/user/plugins/taxonomylist
+
+>> NOTE: This plugin is a modular component for Grav which requires [Grav](http://github.com/getgrav/grav), the [Error](https://github.com/getgrav/grav-plugin-error) and [Problems](https://github.com/getgrav/grav-plugin-problems) plugins, and a theme to be installed in order to operate.
+
+# Usage
+
+To use `taxonomylist` you need to set your pages header with a taxonomy category and tag:
+
+```
+taxonomy:
+ category: blog
+ tag: [tag1, tag2]
+```
+
+> NOTE: If you want to see this plugin in action, have a look at our [Blog Site Skeleton](http://github.com/grav/grav-skeleton-blog-site/archive/master.zip)
+
+# Config Defaults
+```
+route: '/blog'
+```
diff --git a/user/plugins/taxonomylist/assets/readme_1.png b/user/plugins/taxonomylist/assets/readme_1.png
new file mode 100644
index 0000000..eef3d84
Binary files /dev/null and b/user/plugins/taxonomylist/assets/readme_1.png differ
diff --git a/user/plugins/taxonomylist/blueprints.yaml b/user/plugins/taxonomylist/blueprints.yaml
new file mode 100644
index 0000000..c941e5b
--- /dev/null
+++ b/user/plugins/taxonomylist/blueprints.yaml
@@ -0,0 +1,34 @@
+name: Taxonomy List
+version: 1.2.6
+description: "With the **TaxonomyList plugin** you can easily create list of **taxonomy** items such as **tags**, **categories**, etc."
+icon: tag
+author:
+ name: Team Grav
+ email: devs@getgrav.org
+ url: http://getgrav.org
+homepage: https://github.com/getgrav/grav-plugin-taxonomylist
+demo: http://demo.getgrav.org/blog-skeleton
+keywords: taxonomylist, plugin, taxonomy, list, tags, categories
+bugs: https://github.com/getgrav/grav-plugin-taxonomylist/issues
+license: MIT
+
+form:
+ validation: strict
+ fields:
+ enabled:
+ type: toggle
+ label: Plugin status
+ highlight: 1
+ default: 0
+ options:
+ 1: Enabled
+ 0: Disabled
+ validate:
+ type: bool
+
+ route:
+ type: text
+ label: Route to blog
+ placeholder: /blog
+ validate:
+ pattern: "/([a-z\-_]+/?)+"
diff --git a/user/plugins/taxonomylist/classes/taxonomylist.php b/user/plugins/taxonomylist/classes/taxonomylist.php
new file mode 100644
index 0000000..55f5c1d
--- /dev/null
+++ b/user/plugins/taxonomylist/classes/taxonomylist.php
@@ -0,0 +1,54 @@
+taxonomylist) {
+ $this->build();
+ }
+ return $this->taxonomylist;
+ }
+
+ /**
+ * @internal
+ */
+ protected function build()
+ {
+ $taxonomylist = self::getGrav()['taxonomy']->taxonomy();
+ $cache = self::getGrav()['cache'];
+ $hash = hash('md5', serialize($taxonomylist));
+
+ if ($taxonomy = $cache->fetch($hash)) {
+ $this->taxonomylist = $taxonomy;
+ } else {
+ $newlist = [];
+ foreach ($taxonomylist as $x => $y) {
+ $partial = [];
+ foreach ($taxonomylist[$x] as $key => $value) {
+ $taxonomylist[$x][strval($key)] = count($value);
+ $partial[strval($key)] = count($value);
+ }
+ arsort($partial);
+ $newlist[$x] = $partial;
+ }
+ $cache->save($hash, $newlist);
+ $this->taxonomylist = $newlist;
+ }
+ }
+}
diff --git a/user/plugins/taxonomylist/hebe.json b/user/plugins/taxonomylist/hebe.json
new file mode 100644
index 0000000..83b7e70
--- /dev/null
+++ b/user/plugins/taxonomylist/hebe.json
@@ -0,0 +1,15 @@
+{
+ "project":"grav-plugin-taxonomylist",
+ "platforms":{
+ "grav":{
+ "nodes":{
+ "plugin":[
+ {
+ "source":"/",
+ "destination":"/user/plugins/taxonomylist"
+ }
+ ]
+ }
+ }
+ }
+}
diff --git a/user/plugins/taxonomylist/taxonomylist.php b/user/plugins/taxonomylist/taxonomylist.php
new file mode 100644
index 0000000..8891cd4
--- /dev/null
+++ b/user/plugins/taxonomylist/taxonomylist.php
@@ -0,0 +1,58 @@
+ ['onPluginsInitialized', 0]
+ ];
+ }
+
+ /**
+ * Initialize configuration
+ */
+ public function onPluginsInitialized()
+ {
+ if ($this->isAdmin()) {
+ $this->active = false;
+ return;
+ }
+
+ $this->enable([
+ 'onTwigTemplatePaths' => ['onTwigTemplatePaths', 0],
+ 'onTwigSiteVariables' => ['onTwigSiteVariables', 0]
+ ]);
+ }
+
+ /**
+ * Add current directory to twig lookup paths.
+ */
+ public function onTwigTemplatePaths()
+ {
+ $this->grav['twig']->twig_paths[] = __DIR__ . '/templates';
+ }
+
+ /**
+ * Set needed variables to display the taxonomy list.
+ */
+ public function onTwigSiteVariables()
+ {
+ require_once __DIR__ . '/classes/taxonomylist.php';
+
+ $twig = $this->grav['twig'];
+ $twig->twig_vars['taxonomylist'] = new Taxonomylist();
+ $twig->twig_vars['list_url'] = $this->config->get(
+ 'site.blog.route',
+ $this->config->get('plugins.taxonomylist.route')
+ );
+ }
+}
diff --git a/user/plugins/taxonomylist/taxonomylist.yaml b/user/plugins/taxonomylist/taxonomylist.yaml
new file mode 100644
index 0000000..39f856d
--- /dev/null
+++ b/user/plugins/taxonomylist/taxonomylist.yaml
@@ -0,0 +1,2 @@
+enabled: true
+route: '/blog'
diff --git a/user/plugins/taxonomylist/templates/partials/taxonomylist.html.twig b/user/plugins/taxonomylist/templates/partials/taxonomylist.html.twig
new file mode 100644
index 0000000..6a00e44
--- /dev/null
+++ b/user/plugins/taxonomylist/templates/partials/taxonomylist.html.twig
@@ -0,0 +1,10 @@
+{% set taxlist = taxonomylist.get() %}
+
+{% if taxlist %}
+
+ {% for tax,value in taxlist[taxonomy] %}
+ {% set active = uri.param(taxonomy) == tax ? 'active' : '' %}
+ {{ tax }}
+ {% endfor %}
+
+{% endif %}
diff --git a/user/themes/labonneadresse/.gitignore b/user/themes/labonneadresse/.gitignore
new file mode 100644
index 0000000..6d0f314
--- /dev/null
+++ b/user/themes/labonneadresse/.gitignore
@@ -0,0 +1,2 @@
+css
+node_modules
diff --git a/user/themes/labonneadresse/CHANGELOG.md b/user/themes/labonneadresse/CHANGELOG.md
new file mode 100644
index 0000000..03ee7a0
--- /dev/null
+++ b/user/themes/labonneadresse/CHANGELOG.md
@@ -0,0 +1,5 @@
+# v1.0.0
+## 6/22/2015
+
+1. [](#new)
+ * ChangeLog Started
diff --git a/user/themes/labonneadresse/LICENSE.md b/user/themes/labonneadresse/LICENSE.md
new file mode 100644
index 0000000..242132d
--- /dev/null
+++ b/user/themes/labonneadresse/LICENSE.md
@@ -0,0 +1,21 @@
+The MIT License (MIT)
+
+Copyright (c)
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
diff --git a/user/themes/labonneadresse/README.md b/user/themes/labonneadresse/README.md
new file mode 100644
index 0000000..3cc2f57
--- /dev/null
+++ b/user/themes/labonneadresse/README.md
@@ -0,0 +1,105 @@
+# Foundation
+
+
+
+Foundation is a [Grav](http://getgrav.org) theme using Zurb's Foundation front-end framework.
+
+# Installation
+
+Installing the Foundation theme can be done in one of two ways. The GPM (Grav Package Manager) installation method enables you to quickly and easily install the theme with a simple terminal command, while the manual method enables you to do so via a zip file.
+
+## GPM Installation (Preferred)
+
+The simplest way to install this theme is via the [Grav Package Manager (GPM)](http://learn.getgrav.org/advanced/grav-gpm) through your system's Terminal (also called the command line). From the root of your Grav install type:
+
+ bin/gpm install foundation
+
+This will install the Foundation theme into your `/user/themes` directory within Grav. Its files can be found under `/your/site/grav/user/themes/foundation`.
+
+## Manual Installation
+
+To install this theme, just download the zip version of this repository and unzip it under `/your/site/grav/user/themes`. Then, rename the folder to `foundation`. You can find these files either on [GitHub](https://github.com/brettdewoody/grav-theme-foundation) or via [GetGrav.org](http://getgrav.org/downloads/themes).
+
+You should now have all the theme files under
+
+ /your/site/grav/user/themes/foundation
+
+>> NOTE: This theme is a modular component for Grav which requires the [AdvancedPageCache](https://github.com/getgrav/grav-plugin-advanced-pagecache) and [PreCache](https://github.com/getgrav/grav-plugin-precache) plugins.
+
+To install the required plugins, from the root of your Grav install type:
+
+ bin/gpm install advanced-pagecache
+ bin/gpm install precache
+
+# Updating
+
+As development for the Foundation theme continues, new versions may become available that add additional features and functionality, improve compatibility with newer Grav releases, and generally provide a better user experience. Updating Antimatter is easy, and can be done through Grav's GPM system, as well as manually.
+
+## GPM Update (Preferred)
+
+The simplest way to update this theme is via the [Grav Package Manager (GPM)](http://learn.getgrav.org/advanced/grav-gpm). You can do this with this by navigating to the root directory of your Grav install using your system's Terminal (also called command line) and typing the following:
+
+ bin/gpm update foundation
+
+This command will check your Grav install to see if your Foundation theme is due for an update. If a newer release is found, you will be asked whether or not you wish to update. To continue, type `y` and hit enter. The theme will automatically update and clear Grav's cache.
+
+## Manual Update
+
+Manually updating Foundation is pretty simple. Here is what you will need to do to get this done:
+
+* Delete the `your/site/user/themes/foundation` directory.
+* Download the new version of the Foundation theme from either [GitHub](https://github.com/getgrav/grav-plugin-foundation) or [GetGrav.org](http://getgrav.org/downloads/themes#extras).
+* Unzip the zip file in `your/site/user/themes` and rename the resulting folder to `foundation`.
+* Clear the Grav cache. The simplest way to do this is by going to the root Grav directory in terminal and typing `bin/grav clear-cache`.
+
+> Note: Any changes you have made to any of the files listed under this directory will also be removed and replaced by the new set. Any files located elsewhere (for example a YAML settings file placed in `user/config/themes`) will remain intact.
+
+## Features
+
+* Lightweight and minimal for optimal performance
+* Fully responsive with off-page mobile navigation
+* SCSS based CSS source files for easy customization
+* Built-in support for on-page navigation
+* Multiple page template types
+* Fontawesome icon support
+
+### Supported Page Templates
+
+* Default view template
+* Blog view template
+* Error view template
+* Blog item vew template
+* Modular view templates:
+ * Features Modular view template
+ * Showcase Modular view template
+ * Text Modular view template
+* SnipCart view template
+
+# Setup
+
+If you want to set Foundation as the default theme, you can do so by following these steps:
+
+* Navigate to `/your/site/grav/user/config`.
+* Open the **system.yaml** file.
+* Change the `theme:` setting to `theme: foundation`.
+* Save your changes.
+* Clear the Grav cache. The simplest way to do this is by going to the root Grav directory in Terminal and typing `bin/grav clear-cache`.
+
+Once this is done, you should be able to see the new theme on the frontend. Keep in mind any customizations made to the previous theme will not be reflected as all of the theme and templating information is now being pulled from the **foundation** folder.
+
+# Development Process
+
+The Foundation theme includes a Gulp script to compile the SCSS into CSS. You'll need to install [NPM](https://www.npmjs.com/package/npm), [Bower](http://bower.io/) and [Gulp](http://gulpjs.com/) for this. If you have [NPM](https://www.npmjs.com/package/npm) installed this is pretty simple. From the Foundation theme directory (`/user/themes/foundation`), type the following:
+
+ npm install --global gulp
+ npm install --save-dev gulp
+ npm install
+ bower install
+
+This will install all the required packages.
+
+When in development you can run:
+
+ gulp watch
+
+to watch your SCSS files for changes and compile the CSS.
diff --git a/user/themes/labonneadresse/blueprints.yaml b/user/themes/labonneadresse/blueprints.yaml
new file mode 100644
index 0000000..57c1430
--- /dev/null
+++ b/user/themes/labonneadresse/blueprints.yaml
@@ -0,0 +1,14 @@
+name: La Bonne Adresse
+version: 1.0.5
+description: "A high-performance, responsive Grav theme using the Zurb Foundation front-end framework."
+icon: rocket
+screenshot: screenshot.jpg
+author:
+ name: Bachir Soussi Chiadmi
+ # email: brettdewoody@gmail.com
+ url: http://bachirsoussichiadmi.net
+# homepage: https://github.com/brettdewoody/grav-theme-foundation
+# demo: https://github.com/brettdewoody/grav-theme-foundation/demo
+keywords: "foundation, theme, modern, fast, responsive, html5, css3"
+# bugs: https://github.com/brettdewoody/grav-theme-foundation/issues
+license: MIT
diff --git a/user/themes/labonneadresse/bower.json b/user/themes/labonneadresse/bower.json
new file mode 100644
index 0000000..dbe5bd3
--- /dev/null
+++ b/user/themes/labonneadresse/bower.json
@@ -0,0 +1,24 @@
+{
+ "name": "grav-theme-labonneadresse",
+ "description": "A theme for Grav using the Zurb Foundation front-end framework.",
+ "main": "gulpfile.js",
+ "authors": [
+ "Bachir Soussi Chiadmi"
+ ],
+ "license": "MIT",
+ "moduleType": [],
+ "homepage": "",
+ "ignore": [
+ "**/.*",
+ "node_modules",
+ "bower_components",
+ "test",
+ "tests"
+ ],
+ "dependencies": {
+ "foundation": "~5.5.3"
+ },
+ "devDependencies": {
+ "masonry": "~3.3.2"
+ }
+}
diff --git a/user/themes/labonneadresse/bower_components/doc-ready/.bower.json b/user/themes/labonneadresse/bower_components/doc-ready/.bower.json
new file mode 100644
index 0000000..d4d75ec
--- /dev/null
+++ b/user/themes/labonneadresse/bower_components/doc-ready/.bower.json
@@ -0,0 +1,44 @@
+{
+ "name": "doc-ready",
+ "version": "1.0.4",
+ "description": "Let's get this party started... on document ready",
+ "main": "doc-ready.js",
+ "dependencies": {
+ "eventie": "^1"
+ },
+ "homepage": "https://github.com/desandro/doc-ready",
+ "authors": [
+ "David DeSandro"
+ ],
+ "moduleType": [
+ "amd",
+ "globals",
+ "node"
+ ],
+ "keywords": [
+ "DOM",
+ "document",
+ "ready"
+ ],
+ "license": "MIT",
+ "ignore": [
+ "**/.*",
+ "node_modules",
+ "bower_components",
+ "test",
+ "tests",
+ "examples",
+ "package.json",
+ "component.json",
+ "index.html"
+ ],
+ "_release": "1.0.4",
+ "_resolution": {
+ "type": "version",
+ "tag": "v1.0.4",
+ "commit": "cec8e49744a1e18b14a711eea77e201bb70de544"
+ },
+ "_source": "git://github.com/desandro/doc-ready.git",
+ "_target": "~1.0.4",
+ "_originalSource": "doc-ready"
+}
\ No newline at end of file
diff --git a/user/themes/labonneadresse/bower_components/doc-ready/README.md b/user/themes/labonneadresse/bower_components/doc-ready/README.md
new file mode 100644
index 0000000..6f382f5
--- /dev/null
+++ b/user/themes/labonneadresse/bower_components/doc-ready/README.md
@@ -0,0 +1,23 @@
+# docReady
+
+Cross browser document ready helper. Supported by IE8+ and good browsers.
+
+```js
+docReady( function() {
+ console.log("DOM is ready. Let's party");
+});
+```
+
+Props to [dperini/ContentLoaded](https://github.com/dperini/ContentLoaded) for original code
+
+## Install
+
+Install with [Bower](http://bower.io) `bower install doc-ready`
+
+Install with npm `npm install doc-ready`
+
+Install with [Component](http://github.com/component/component) `component install desandro/doc-ready`
+
+## MIT License
+
+docReady is released under the [MIT license](http://desandro.mit-license.org).
diff --git a/user/themes/labonneadresse/bower_components/doc-ready/bower.json b/user/themes/labonneadresse/bower_components/doc-ready/bower.json
new file mode 100644
index 0000000..726600b
--- /dev/null
+++ b/user/themes/labonneadresse/bower_components/doc-ready/bower.json
@@ -0,0 +1,35 @@
+{
+ "name": "doc-ready",
+ "version": "1.0.4",
+ "description": "Let's get this party started... on document ready",
+ "main": "doc-ready.js",
+ "dependencies": {
+ "eventie": "^1"
+ },
+ "homepage": "https://github.com/desandro/doc-ready",
+ "authors": [
+ "David DeSandro"
+ ],
+ "moduleType": [
+ "amd",
+ "globals",
+ "node"
+ ],
+ "keywords": [
+ "DOM",
+ "document",
+ "ready"
+ ],
+ "license": "MIT",
+ "ignore": [
+ "**/.*",
+ "node_modules",
+ "bower_components",
+ "test",
+ "tests",
+ "examples",
+ "package.json",
+ "component.json",
+ "index.html"
+ ]
+}
diff --git a/user/themes/labonneadresse/bower_components/doc-ready/doc-ready.js b/user/themes/labonneadresse/bower_components/doc-ready/doc-ready.js
new file mode 100644
index 0000000..bc5e40e
--- /dev/null
+++ b/user/themes/labonneadresse/bower_components/doc-ready/doc-ready.js
@@ -0,0 +1,80 @@
+/*!
+ * docReady v1.0.4
+ * Cross browser DOMContentLoaded event emitter
+ * MIT license
+ */
+
+/*jshint browser: true, strict: true, undef: true, unused: true*/
+/*global define: false, require: false, module: false */
+
+( function( window ) {
+
+'use strict';
+
+var document = window.document;
+// collection of functions to be triggered on ready
+var queue = [];
+
+function docReady( fn ) {
+ // throw out non-functions
+ if ( typeof fn !== 'function' ) {
+ return;
+ }
+
+ if ( docReady.isReady ) {
+ // ready now, hit it
+ fn();
+ } else {
+ // queue function when ready
+ queue.push( fn );
+ }
+}
+
+docReady.isReady = false;
+
+// triggered on various doc ready events
+function onReady( event ) {
+ // bail if already triggered or IE8 document is not ready just yet
+ var isIE8NotReady = event.type === 'readystatechange' && document.readyState !== 'complete';
+ if ( docReady.isReady || isIE8NotReady ) {
+ return;
+ }
+
+ trigger();
+}
+
+function trigger() {
+ docReady.isReady = true;
+ // process queue
+ for ( var i=0, len = queue.length; i < len; i++ ) {
+ var fn = queue[i];
+ fn();
+ }
+}
+
+function defineDocReady( eventie ) {
+ // trigger ready if page is ready
+ if ( document.readyState === 'complete' ) {
+ trigger();
+ } else {
+ // listen for events
+ eventie.bind( document, 'DOMContentLoaded', onReady );
+ eventie.bind( document, 'readystatechange', onReady );
+ eventie.bind( window, 'load', onReady );
+ }
+
+ return docReady;
+}
+
+// transport
+if ( typeof define === 'function' && define.amd ) {
+ // AMD
+ define( [ 'eventie/eventie' ], defineDocReady );
+} else if ( typeof exports === 'object' ) {
+ module.exports = defineDocReady( require('eventie') );
+} else {
+ // browser global
+ window.docReady = defineDocReady( window.eventie );
+}
+
+})( window );
diff --git a/user/themes/labonneadresse/bower_components/eventEmitter/.bower.json b/user/themes/labonneadresse/bower_components/eventEmitter/.bower.json
new file mode 100644
index 0000000..46dc12a
--- /dev/null
+++ b/user/themes/labonneadresse/bower_components/eventEmitter/.bower.json
@@ -0,0 +1,34 @@
+{
+ "name": "eventEmitter",
+ "description": "Event based JavaScript for the browser",
+ "version": "4.3.0",
+ "main": [
+ "./EventEmitter.js"
+ ],
+ "author": {
+ "name": "Oliver Caldwell",
+ "web": "http://oli.me.uk/"
+ },
+ "license": "Unlicense",
+ "keywords": [
+ "events",
+ "structure"
+ ],
+ "ignore": [
+ "docs",
+ "tests",
+ "tools",
+ ".gitignore",
+ "package.json"
+ ],
+ "homepage": "https://github.com/Olical/EventEmitter",
+ "_release": "4.3.0",
+ "_resolution": {
+ "type": "version",
+ "tag": "v4.3.0",
+ "commit": "34545d1b761fca48d7e4d9c71efc868a8d101419"
+ },
+ "_source": "git://github.com/Olical/EventEmitter.git",
+ "_target": ">=4.2 <5",
+ "_originalSource": "eventEmitter"
+}
\ No newline at end of file
diff --git a/user/themes/labonneadresse/bower_components/eventEmitter/EventEmitter.js b/user/themes/labonneadresse/bower_components/eventEmitter/EventEmitter.js
new file mode 100644
index 0000000..5211bae
--- /dev/null
+++ b/user/themes/labonneadresse/bower_components/eventEmitter/EventEmitter.js
@@ -0,0 +1,474 @@
+/*!
+ * EventEmitter v4.2.11 - git.io/ee
+ * Unlicense - http://unlicense.org/
+ * Oliver Caldwell - http://oli.me.uk/
+ * @preserve
+ */
+
+;(function () {
+ 'use strict';
+
+ /**
+ * Class for managing events.
+ * Can be extended to provide event functionality in other classes.
+ *
+ * @class EventEmitter Manages event registering and emitting.
+ */
+ function EventEmitter() {}
+
+ // Shortcuts to improve speed and size
+ var proto = EventEmitter.prototype;
+ var exports = this;
+ var originalGlobalValue = exports.EventEmitter;
+
+ /**
+ * Finds the index of the listener for the event in its storage array.
+ *
+ * @param {Function[]} listeners Array of listeners to search through.
+ * @param {Function} listener Method to look for.
+ * @return {Number} Index of the specified listener, -1 if not found
+ * @api private
+ */
+ function indexOfListener(listeners, listener) {
+ var i = listeners.length;
+ while (i--) {
+ if (listeners[i].listener === listener) {
+ return i;
+ }
+ }
+
+ return -1;
+ }
+
+ /**
+ * Alias a method while keeping the context correct, to allow for overwriting of target method.
+ *
+ * @param {String} name The name of the target method.
+ * @return {Function} The aliased method
+ * @api private
+ */
+ function alias(name) {
+ return function aliasClosure() {
+ return this[name].apply(this, arguments);
+ };
+ }
+
+ /**
+ * Returns the listener array for the specified event.
+ * Will initialise the event object and listener arrays if required.
+ * Will return an object if you use a regex search. The object contains keys for each matched event. So /ba[rz]/ might return an object containing bar and baz. But only if you have either defined them with defineEvent or added some listeners to them.
+ * Each property in the object response is an array of listener functions.
+ *
+ * @param {String|RegExp} evt Name of the event to return the listeners from.
+ * @return {Function[]|Object} All listener functions for the event.
+ */
+ proto.getListeners = function getListeners(evt) {
+ var events = this._getEvents();
+ var response;
+ var key;
+
+ // Return a concatenated array of all matching events if
+ // the selector is a regular expression.
+ if (evt instanceof RegExp) {
+ response = {};
+ for (key in events) {
+ if (events.hasOwnProperty(key) && evt.test(key)) {
+ response[key] = events[key];
+ }
+ }
+ }
+ else {
+ response = events[evt] || (events[evt] = []);
+ }
+
+ return response;
+ };
+
+ /**
+ * Takes a list of listener objects and flattens it into a list of listener functions.
+ *
+ * @param {Object[]} listeners Raw listener objects.
+ * @return {Function[]} Just the listener functions.
+ */
+ proto.flattenListeners = function flattenListeners(listeners) {
+ var flatListeners = [];
+ var i;
+
+ for (i = 0; i < listeners.length; i += 1) {
+ flatListeners.push(listeners[i].listener);
+ }
+
+ return flatListeners;
+ };
+
+ /**
+ * Fetches the requested listeners via getListeners but will always return the results inside an object. This is mainly for internal use but others may find it useful.
+ *
+ * @param {String|RegExp} evt Name of the event to return the listeners from.
+ * @return {Object} All listener functions for an event in an object.
+ */
+ proto.getListenersAsObject = function getListenersAsObject(evt) {
+ var listeners = this.getListeners(evt);
+ var response;
+
+ if (listeners instanceof Array) {
+ response = {};
+ response[evt] = listeners;
+ }
+
+ return response || listeners;
+ };
+
+ /**
+ * Adds a listener function to the specified event.
+ * The listener will not be added if it is a duplicate.
+ * If the listener returns true then it will be removed after it is called.
+ * If you pass a regular expression as the event name then the listener will be added to all events that match it.
+ *
+ * @param {String|RegExp} evt Name of the event to attach the listener to.
+ * @param {Function} listener Method to be called when the event is emitted. If the function returns true then it will be removed after calling.
+ * @return {Object} Current instance of EventEmitter for chaining.
+ */
+ proto.addListener = function addListener(evt, listener) {
+ var listeners = this.getListenersAsObject(evt);
+ var listenerIsWrapped = typeof listener === 'object';
+ var key;
+
+ for (key in listeners) {
+ if (listeners.hasOwnProperty(key) && indexOfListener(listeners[key], listener) === -1) {
+ listeners[key].push(listenerIsWrapped ? listener : {
+ listener: listener,
+ once: false
+ });
+ }
+ }
+
+ return this;
+ };
+
+ /**
+ * Alias of addListener
+ */
+ proto.on = alias('addListener');
+
+ /**
+ * Semi-alias of addListener. It will add a listener that will be
+ * automatically removed after its first execution.
+ *
+ * @param {String|RegExp} evt Name of the event to attach the listener to.
+ * @param {Function} listener Method to be called when the event is emitted. If the function returns true then it will be removed after calling.
+ * @return {Object} Current instance of EventEmitter for chaining.
+ */
+ proto.addOnceListener = function addOnceListener(evt, listener) {
+ return this.addListener(evt, {
+ listener: listener,
+ once: true
+ });
+ };
+
+ /**
+ * Alias of addOnceListener.
+ */
+ proto.once = alias('addOnceListener');
+
+ /**
+ * Defines an event name. This is required if you want to use a regex to add a listener to multiple events at once. If you don't do this then how do you expect it to know what event to add to? Should it just add to every possible match for a regex? No. That is scary and bad.
+ * You need to tell it what event names should be matched by a regex.
+ *
+ * @param {String} evt Name of the event to create.
+ * @return {Object} Current instance of EventEmitter for chaining.
+ */
+ proto.defineEvent = function defineEvent(evt) {
+ this.getListeners(evt);
+ return this;
+ };
+
+ /**
+ * Uses defineEvent to define multiple events.
+ *
+ * @param {String[]} evts An array of event names to define.
+ * @return {Object} Current instance of EventEmitter for chaining.
+ */
+ proto.defineEvents = function defineEvents(evts) {
+ for (var i = 0; i < evts.length; i += 1) {
+ this.defineEvent(evts[i]);
+ }
+ return this;
+ };
+
+ /**
+ * Removes a listener function from the specified event.
+ * When passed a regular expression as the event name, it will remove the listener from all events that match it.
+ *
+ * @param {String|RegExp} evt Name of the event to remove the listener from.
+ * @param {Function} listener Method to remove from the event.
+ * @return {Object} Current instance of EventEmitter for chaining.
+ */
+ proto.removeListener = function removeListener(evt, listener) {
+ var listeners = this.getListenersAsObject(evt);
+ var index;
+ var key;
+
+ for (key in listeners) {
+ if (listeners.hasOwnProperty(key)) {
+ index = indexOfListener(listeners[key], listener);
+
+ if (index !== -1) {
+ listeners[key].splice(index, 1);
+ }
+ }
+ }
+
+ return this;
+ };
+
+ /**
+ * Alias of removeListener
+ */
+ proto.off = alias('removeListener');
+
+ /**
+ * Adds listeners in bulk using the manipulateListeners method.
+ * If you pass an object as the second argument you can add to multiple events at once. The object should contain key value pairs of events and listeners or listener arrays. You can also pass it an event name and an array of listeners to be added.
+ * You can also pass it a regular expression to add the array of listeners to all events that match it.
+ * Yeah, this function does quite a bit. That's probably a bad thing.
+ *
+ * @param {String|Object|RegExp} evt An event name if you will pass an array of listeners next. An object if you wish to add to multiple events at once.
+ * @param {Function[]} [listeners] An optional array of listener functions to add.
+ * @return {Object} Current instance of EventEmitter for chaining.
+ */
+ proto.addListeners = function addListeners(evt, listeners) {
+ // Pass through to manipulateListeners
+ return this.manipulateListeners(false, evt, listeners);
+ };
+
+ /**
+ * Removes listeners in bulk using the manipulateListeners method.
+ * If you pass an object as the second argument you can remove from multiple events at once. The object should contain key value pairs of events and listeners or listener arrays.
+ * You can also pass it an event name and an array of listeners to be removed.
+ * You can also pass it a regular expression to remove the listeners from all events that match it.
+ *
+ * @param {String|Object|RegExp} evt An event name if you will pass an array of listeners next. An object if you wish to remove from multiple events at once.
+ * @param {Function[]} [listeners] An optional array of listener functions to remove.
+ * @return {Object} Current instance of EventEmitter for chaining.
+ */
+ proto.removeListeners = function removeListeners(evt, listeners) {
+ // Pass through to manipulateListeners
+ return this.manipulateListeners(true, evt, listeners);
+ };
+
+ /**
+ * Edits listeners in bulk. The addListeners and removeListeners methods both use this to do their job. You should really use those instead, this is a little lower level.
+ * The first argument will determine if the listeners are removed (true) or added (false).
+ * If you pass an object as the second argument you can add/remove from multiple events at once. The object should contain key value pairs of events and listeners or listener arrays.
+ * You can also pass it an event name and an array of listeners to be added/removed.
+ * You can also pass it a regular expression to manipulate the listeners of all events that match it.
+ *
+ * @param {Boolean} remove True if you want to remove listeners, false if you want to add.
+ * @param {String|Object|RegExp} evt An event name if you will pass an array of listeners next. An object if you wish to add/remove from multiple events at once.
+ * @param {Function[]} [listeners] An optional array of listener functions to add/remove.
+ * @return {Object} Current instance of EventEmitter for chaining.
+ */
+ proto.manipulateListeners = function manipulateListeners(remove, evt, listeners) {
+ var i;
+ var value;
+ var single = remove ? this.removeListener : this.addListener;
+ var multiple = remove ? this.removeListeners : this.addListeners;
+
+ // If evt is an object then pass each of its properties to this method
+ if (typeof evt === 'object' && !(evt instanceof RegExp)) {
+ for (i in evt) {
+ if (evt.hasOwnProperty(i) && (value = evt[i])) {
+ // Pass the single listener straight through to the singular method
+ if (typeof value === 'function') {
+ single.call(this, i, value);
+ }
+ else {
+ // Otherwise pass back to the multiple function
+ multiple.call(this, i, value);
+ }
+ }
+ }
+ }
+ else {
+ // So evt must be a string
+ // And listeners must be an array of listeners
+ // Loop over it and pass each one to the multiple method
+ i = listeners.length;
+ while (i--) {
+ single.call(this, evt, listeners[i]);
+ }
+ }
+
+ return this;
+ };
+
+ /**
+ * Removes all listeners from a specified event.
+ * If you do not specify an event then all listeners will be removed.
+ * That means every event will be emptied.
+ * You can also pass a regex to remove all events that match it.
+ *
+ * @param {String|RegExp} [evt] Optional name of the event to remove all listeners for. Will remove from every event if not passed.
+ * @return {Object} Current instance of EventEmitter for chaining.
+ */
+ proto.removeEvent = function removeEvent(evt) {
+ var type = typeof evt;
+ var events = this._getEvents();
+ var key;
+
+ // Remove different things depending on the state of evt
+ if (type === 'string') {
+ // Remove all listeners for the specified event
+ delete events[evt];
+ }
+ else if (evt instanceof RegExp) {
+ // Remove all events matching the regex.
+ for (key in events) {
+ if (events.hasOwnProperty(key) && evt.test(key)) {
+ delete events[key];
+ }
+ }
+ }
+ else {
+ // Remove all listeners in all events
+ delete this._events;
+ }
+
+ return this;
+ };
+
+ /**
+ * Alias of removeEvent.
+ *
+ * Added to mirror the node API.
+ */
+ proto.removeAllListeners = alias('removeEvent');
+
+ /**
+ * Emits an event of your choice.
+ * When emitted, every listener attached to that event will be executed.
+ * If you pass the optional argument array then those arguments will be passed to every listener upon execution.
+ * Because it uses `apply`, your array of arguments will be passed as if you wrote them out separately.
+ * So they will not arrive within the array on the other side, they will be separate.
+ * You can also pass a regular expression to emit to all events that match it.
+ *
+ * @param {String|RegExp} evt Name of the event to emit and execute listeners for.
+ * @param {Array} [args] Optional array of arguments to be passed to each listener.
+ * @return {Object} Current instance of EventEmitter for chaining.
+ */
+ proto.emitEvent = function emitEvent(evt, args) {
+ var listenersMap = this.getListenersAsObject(evt);
+ var listeners;
+ var listener;
+ var i;
+ var key;
+ var response;
+
+ for (key in listenersMap) {
+ if (listenersMap.hasOwnProperty(key)) {
+ listeners = listenersMap[key].slice(0);
+ i = listeners.length;
+
+ while (i--) {
+ // If the listener returns true then it shall be removed from the event
+ // The function is executed either with a basic call or an apply if there is an args array
+ listener = listeners[i];
+
+ if (listener.once === true) {
+ this.removeListener(evt, listener.listener);
+ }
+
+ response = listener.listener.apply(this, args || []);
+
+ if (response === this._getOnceReturnValue()) {
+ this.removeListener(evt, listener.listener);
+ }
+ }
+ }
+ }
+
+ return this;
+ };
+
+ /**
+ * Alias of emitEvent
+ */
+ proto.trigger = alias('emitEvent');
+
+ /**
+ * Subtly different from emitEvent in that it will pass its arguments on to the listeners, as opposed to taking a single array of arguments to pass on.
+ * As with emitEvent, you can pass a regex in place of the event name to emit to all events that match it.
+ *
+ * @param {String|RegExp} evt Name of the event to emit and execute listeners for.
+ * @param {...*} Optional additional arguments to be passed to each listener.
+ * @return {Object} Current instance of EventEmitter for chaining.
+ */
+ proto.emit = function emit(evt) {
+ var args = Array.prototype.slice.call(arguments, 1);
+ return this.emitEvent(evt, args);
+ };
+
+ /**
+ * Sets the current value to check against when executing listeners. If a
+ * listeners return value matches the one set here then it will be removed
+ * after execution. This value defaults to true.
+ *
+ * @param {*} value The new value to check for when executing listeners.
+ * @return {Object} Current instance of EventEmitter for chaining.
+ */
+ proto.setOnceReturnValue = function setOnceReturnValue(value) {
+ this._onceReturnValue = value;
+ return this;
+ };
+
+ /**
+ * Fetches the current value to check against when executing listeners. If
+ * the listeners return value matches this one then it should be removed
+ * automatically. It will return true by default.
+ *
+ * @return {*|Boolean} The current value to check for or the default, true.
+ * @api private
+ */
+ proto._getOnceReturnValue = function _getOnceReturnValue() {
+ if (this.hasOwnProperty('_onceReturnValue')) {
+ return this._onceReturnValue;
+ }
+ else {
+ return true;
+ }
+ };
+
+ /**
+ * Fetches the events object and creates one if required.
+ *
+ * @return {Object} The events storage object.
+ * @api private
+ */
+ proto._getEvents = function _getEvents() {
+ return this._events || (this._events = {});
+ };
+
+ /**
+ * Reverts the global {@link EventEmitter} to its previous value and returns a reference to this version.
+ *
+ * @return {Function} Non conflicting EventEmitter class.
+ */
+ EventEmitter.noConflict = function noConflict() {
+ exports.EventEmitter = originalGlobalValue;
+ return EventEmitter;
+ };
+
+ // Expose the class either via AMD, CommonJS or the global object
+ if (typeof define === 'function' && define.amd) {
+ define(function () {
+ return EventEmitter;
+ });
+ }
+ else if (typeof module === 'object' && module.exports){
+ module.exports = EventEmitter;
+ }
+ else {
+ exports.EventEmitter = EventEmitter;
+ }
+}.call(this));
diff --git a/user/themes/labonneadresse/bower_components/eventEmitter/EventEmitter.min.js b/user/themes/labonneadresse/bower_components/eventEmitter/EventEmitter.min.js
new file mode 100644
index 0000000..f85b5e3
--- /dev/null
+++ b/user/themes/labonneadresse/bower_components/eventEmitter/EventEmitter.min.js
@@ -0,0 +1,7 @@
+/*!
+ * EventEmitter v4.2.11 - git.io/ee
+ * Unlicense - http://unlicense.org/
+ * Oliver Caldwell - http://oli.me.uk/
+ * @preserve
+ */
+(function(){"use strict";function t(){}function i(t,n){for(var e=t.length;e--;)if(t[e].listener===n)return e;return-1}function n(e){return function(){return this[e].apply(this,arguments)}}var e=t.prototype,r=this,s=r.EventEmitter;e.getListeners=function(n){var r,e,t=this._getEvents();if(n instanceof RegExp){r={};for(e in t)t.hasOwnProperty(e)&&n.test(e)&&(r[e]=t[e])}else r=t[n]||(t[n]=[]);return r},e.flattenListeners=function(t){var e,n=[];for(e=0;eThis is free and unencumbered software released into the public domain.
+>
+>Anyone is free to copy, modify, publish, use, compile, sell, or distribute this software, either in source code form or as a compiled binary, for any purpose, commercial or non-commercial, and by any means.
+
+I gave people the chance to object in issue #84, which also explains my reasoning.
+
+[guide]: https://github.com/Wolfy87/EventEmitter/blob/master/docs/guide.md
+[api]: https://github.com/Olical/EventEmitter/blob/master/docs/api.md
+[simple]: http://jsfiddle.net/Wolfy87/qXQu9/
+[regexp dom caster]: http://jsfiddle.net/Wolfy87/JqRvS/
+[npm]: https://npmjs.org/
+[bower]: http://bower.io/
+[component]: http://github.com/component/component
+[mocha]: http://visionmedia.github.io/mocha/
+[chai]: http://chaijs.com/
+[issues]: https://github.com/Olical/EventEmitter/issues
+[example]: https://github.com/Olical/EventEmitter/pull/46
+[nathggns]: https://github.com/nathggns
+[http-server]: https://www.npmjs.org/package/http-server
+[node.js]: http://nodejs.org/
+[gitter]: https://gitter.im/Olical/EventEmitter?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge
+[unlicense]: http://unlicense.org/
diff --git a/user/themes/labonneadresse/bower_components/eventEmitter/UNLICENSE b/user/themes/labonneadresse/bower_components/eventEmitter/UNLICENSE
new file mode 100644
index 0000000..68a49da
--- /dev/null
+++ b/user/themes/labonneadresse/bower_components/eventEmitter/UNLICENSE
@@ -0,0 +1,24 @@
+This is free and unencumbered software released into the public domain.
+
+Anyone is free to copy, modify, publish, use, compile, sell, or
+distribute this software, either in source code form or as a compiled
+binary, for any purpose, commercial or non-commercial, and by any
+means.
+
+In jurisdictions that recognize copyright laws, the author or authors
+of this software dedicate any and all copyright interest in the
+software to the public domain. We make this dedication for the benefit
+of the public at large and to the detriment of our heirs and
+successors. We intend this dedication to be an overt act of
+relinquishment in perpetuity of all present and future rights to this
+software under copyright law.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
+IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR
+OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
+ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+OTHER DEALINGS IN THE SOFTWARE.
+
+For more information, please refer to
diff --git a/user/themes/labonneadresse/bower_components/eventEmitter/bower.json b/user/themes/labonneadresse/bower_components/eventEmitter/bower.json
new file mode 100644
index 0000000..39b9803
--- /dev/null
+++ b/user/themes/labonneadresse/bower_components/eventEmitter/bower.json
@@ -0,0 +1,24 @@
+{
+ "name": "eventEmitter",
+ "description": "Event based JavaScript for the browser",
+ "version": "4.3.0",
+ "main": [
+ "./EventEmitter.js"
+ ],
+ "author": {
+ "name": "Oliver Caldwell",
+ "web": "http://oli.me.uk/"
+ },
+ "license": "Unlicense",
+ "keywords": [
+ "events",
+ "structure"
+ ],
+ "ignore": [
+ "docs",
+ "tests",
+ "tools",
+ ".gitignore",
+ "package.json"
+ ]
+}
diff --git a/user/themes/labonneadresse/bower_components/eventEmitter/component.json b/user/themes/labonneadresse/bower_components/eventEmitter/component.json
new file mode 100644
index 0000000..34e0670
--- /dev/null
+++ b/user/themes/labonneadresse/bower_components/eventEmitter/component.json
@@ -0,0 +1,9 @@
+{
+ "name": "eventEmitter",
+ "repo": "Olical/EventEmitter",
+ "description": "Event based JavaScript for the browser.",
+ "version": "4.3.0",
+ "scripts": ["EventEmitter.js"],
+ "main": "EventEmitter.js",
+ "license": "Unlicense"
+}
diff --git a/user/themes/labonneadresse/bower_components/eventie/.bower.json b/user/themes/labonneadresse/bower_components/eventie/.bower.json
new file mode 100644
index 0000000..6b5b662
--- /dev/null
+++ b/user/themes/labonneadresse/bower_components/eventie/.bower.json
@@ -0,0 +1,35 @@
+{
+ "name": "eventie",
+ "version": "1.0.6",
+ "main": "eventie.js",
+ "description": "event binding helper",
+ "ignore": [
+ "component.json",
+ "test.html",
+ "**/.*",
+ "node_modules",
+ "bower_components"
+ ],
+ "homepage": "https://github.com/desandro/eventie",
+ "authors": [
+ "David DeSandro"
+ ],
+ "moduleType": [
+ "amd",
+ "globals",
+ "node"
+ ],
+ "keywords": [
+ "event"
+ ],
+ "license": "MIT",
+ "_release": "1.0.6",
+ "_resolution": {
+ "type": "version",
+ "tag": "v1.0.6",
+ "commit": "14d2ca3df97da64c820829a8310f9198fbafbcfa"
+ },
+ "_source": "git://github.com/desandro/eventie.git",
+ "_target": "~1.0.3",
+ "_originalSource": "eventie"
+}
\ No newline at end of file
diff --git a/user/themes/labonneadresse/bower_components/eventie/README.md b/user/themes/labonneadresse/bower_components/eventie/README.md
new file mode 100644
index 0000000..4d40713
--- /dev/null
+++ b/user/themes/labonneadresse/bower_components/eventie/README.md
@@ -0,0 +1,33 @@
+# eventie - event binding helper
+
+Makes dealing with events in IE8 bearable. Supported by IE8+ and good browsers.
+
+``` js
+var elem = document.querySelector('#my-elem');
+function onElemClick( event ) {
+ console.log( event.type + ' just happened on #' + event.target.id );
+ // -> click just happened on #my-elem
+}
+
+eventie.bind( elem, 'click', onElemClick );
+
+eventie.unbind( elem, 'click', onElemClick );
+```
+
+## Install
+
+Download [eventie.js](eventie.js)
+
+Install with [Bower :bird:](http://bower.io) `bower install eventie`
+
+Install with npm :truck: `npm install eventie`
+
+Install with [Component :nut_and_bolt:](https://github.com/component/component) `component install desandro/eventie`
+
+## IE 8
+
+eventie add support for `event.target` and [`.handleEvent` method](https://developer.mozilla.org/en-US/docs/DOM/EventListener#handleEvent\(\)) for Internet Explorer 8.
+
+## MIT license
+
+eventie is released under the [MIT license](http://desandro.mit-license.org).
diff --git a/user/themes/labonneadresse/bower_components/eventie/bower.json b/user/themes/labonneadresse/bower_components/eventie/bower.json
new file mode 100644
index 0000000..96092a6
--- /dev/null
+++ b/user/themes/labonneadresse/bower_components/eventie/bower.json
@@ -0,0 +1,26 @@
+{
+ "name": "eventie",
+ "version": "1.0.6",
+ "main": "eventie.js",
+ "description": "event binding helper",
+ "ignore": [
+ "component.json",
+ "test.html",
+ "**/.*",
+ "node_modules",
+ "bower_components"
+ ],
+ "homepage": "https://github.com/desandro/eventie",
+ "authors": [
+ "David DeSandro"
+ ],
+ "moduleType": [
+ "amd",
+ "globals",
+ "node"
+ ],
+ "keywords": [
+ "event"
+ ],
+ "license": "MIT"
+}
diff --git a/user/themes/labonneadresse/bower_components/eventie/eventie.js b/user/themes/labonneadresse/bower_components/eventie/eventie.js
new file mode 100644
index 0000000..2bf9929
--- /dev/null
+++ b/user/themes/labonneadresse/bower_components/eventie/eventie.js
@@ -0,0 +1,82 @@
+/*!
+ * eventie v1.0.6
+ * event binding helper
+ * eventie.bind( elem, 'click', myFn )
+ * eventie.unbind( elem, 'click', myFn )
+ * MIT license
+ */
+
+/*jshint browser: true, undef: true, unused: true */
+/*global define: false, module: false */
+
+( function( window ) {
+
+'use strict';
+
+var docElem = document.documentElement;
+
+var bind = function() {};
+
+function getIEEvent( obj ) {
+ var event = window.event;
+ // add event.target
+ event.target = event.target || event.srcElement || obj;
+ return event;
+}
+
+if ( docElem.addEventListener ) {
+ bind = function( obj, type, fn ) {
+ obj.addEventListener( type, fn, false );
+ };
+} else if ( docElem.attachEvent ) {
+ bind = function( obj, type, fn ) {
+ obj[ type + fn ] = fn.handleEvent ?
+ function() {
+ var event = getIEEvent( obj );
+ fn.handleEvent.call( fn, event );
+ } :
+ function() {
+ var event = getIEEvent( obj );
+ fn.call( obj, event );
+ };
+ obj.attachEvent( "on" + type, obj[ type + fn ] );
+ };
+}
+
+var unbind = function() {};
+
+if ( docElem.removeEventListener ) {
+ unbind = function( obj, type, fn ) {
+ obj.removeEventListener( type, fn, false );
+ };
+} else if ( docElem.detachEvent ) {
+ unbind = function( obj, type, fn ) {
+ obj.detachEvent( "on" + type, obj[ type + fn ] );
+ try {
+ delete obj[ type + fn ];
+ } catch ( err ) {
+ // can't delete window object properties
+ obj[ type + fn ] = undefined;
+ }
+ };
+}
+
+var eventie = {
+ bind: bind,
+ unbind: unbind
+};
+
+// ----- module definition ----- //
+
+if ( typeof define === 'function' && define.amd ) {
+ // AMD
+ define( eventie );
+} else if ( typeof exports === 'object' ) {
+ // CommonJS
+ module.exports = eventie;
+} else {
+ // browser global
+ window.eventie = eventie;
+}
+
+})( window );
diff --git a/user/themes/labonneadresse/bower_components/eventie/package.json b/user/themes/labonneadresse/bower_components/eventie/package.json
new file mode 100644
index 0000000..5ce5740
--- /dev/null
+++ b/user/themes/labonneadresse/bower_components/eventie/package.json
@@ -0,0 +1,23 @@
+{
+ "name": "eventie",
+ "version": "1.0.6",
+ "description": "Event binding helper",
+ "main": "eventie.js",
+ "scripts": {
+ "test": "echo \"Error: no test specified\" && exit 1"
+ },
+ "repository": {
+ "type": "git",
+ "url": "git://github.com/desandro/eventie.git"
+ },
+ "license": "MIT",
+ "bugs": {
+ "url": "https://github.com/desandro/eventie/issues"
+ },
+ "homepage": "https://github.com/desandro/eventie",
+ "keywords": [
+ "DOM",
+ "event"
+ ],
+ "author": "David DeSandro"
+}
diff --git a/user/themes/labonneadresse/bower_components/fastclick/.bower.json b/user/themes/labonneadresse/bower_components/fastclick/.bower.json
new file mode 100644
index 0000000..db37d8c
--- /dev/null
+++ b/user/themes/labonneadresse/bower_components/fastclick/.bower.json
@@ -0,0 +1,23 @@
+{
+ "name": "fastclick",
+ "main": "lib/fastclick.js",
+ "ignore": [
+ "**/.*",
+ "component.json",
+ "package.json",
+ "Makefile",
+ "tests",
+ "examples"
+ ],
+ "homepage": "https://github.com/ftlabs/fastclick",
+ "version": "1.0.6",
+ "_release": "1.0.6",
+ "_resolution": {
+ "type": "version",
+ "tag": "v1.0.6",
+ "commit": "2ac7258407619398005ca720596f0d36ce66a6c8"
+ },
+ "_source": "git://github.com/ftlabs/fastclick.git",
+ "_target": ">=0.6.11",
+ "_originalSource": "fastclick"
+}
\ No newline at end of file
diff --git a/user/themes/labonneadresse/bower_components/fastclick/LICENSE b/user/themes/labonneadresse/bower_components/fastclick/LICENSE
new file mode 100644
index 0000000..459a20d
--- /dev/null
+++ b/user/themes/labonneadresse/bower_components/fastclick/LICENSE
@@ -0,0 +1,22 @@
+Copyright (c) 2014 The Financial Times Ltd.
+
+Permission is hereby granted, free of charge, to any person
+obtaining a copy of this software and associated documentation
+files (the "Software"), to deal in the Software without
+restriction, including without limitation the rights to use,
+copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the
+Software is furnished to do so, subject to the following
+conditions:
+
+The above copyright notice and this permission notice shall be
+included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
+OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
+HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
+FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+OTHER DEALINGS IN THE SOFTWARE.
diff --git a/user/themes/labonneadresse/bower_components/fastclick/README.md b/user/themes/labonneadresse/bower_components/fastclick/README.md
new file mode 100644
index 0000000..074895d
--- /dev/null
+++ b/user/themes/labonneadresse/bower_components/fastclick/README.md
@@ -0,0 +1,140 @@
+# FastClick #
+
+FastClick is a simple, easy-to-use library for eliminating the 300ms delay between a physical tap and the firing of a `click` event on mobile browsers. The aim is to make your application feel less laggy and more responsive while avoiding any interference with your current logic.
+
+FastClick is developed by [FT Labs](http://labs.ft.com/), part of the Financial Times.
+
+[Explication en français](http://maxime.sh/2013/02/supprimer-le-lag-des-clics-sur-mobile-avec-fastclick/).
+
+[日本語で説明](https://developer.mozilla.org/ja/docs/Mozilla/Firefox_OS/Apps/Tips_and_techniques#Make_events_immediate)。
+
+## Why does the delay exist? ##
+
+According to [Google](https://developers.google.com/mobile/articles/fast_buttons):
+
+> ...mobile browsers will wait approximately 300ms from the time that you tap the button to fire the click event. The reason for this is that the browser is waiting to see if you are actually performing a double tap.
+
+## Compatibility ##
+
+The library has been deployed as part of the [FT Web App](http://app.ft.com/) and is tried and tested on the following mobile browsers:
+
+* Mobile Safari on iOS 3 and upwards
+* Chrome on iOS 5 and upwards
+* Chrome on Android (ICS)
+* Opera Mobile 11.5 and upwards
+* Android Browser since Android 2
+* PlayBook OS 1 and upwards
+
+## When it isn't needed ##
+
+FastClick doesn't attach any listeners on desktop browsers.
+
+Chrome 32+ on Android with `width=device-width` in the [viewport meta tag](https://developer.mozilla.org/en-US/docs/Mobile/Viewport_meta_tag) doesn't have a 300ms delay, therefore listeners aren't attached.
+
+```html
+
+```
+
+Same goes for Chrome on Android (all versions) with `user-scalable=no` in the viewport meta tag. But be aware that `user-scalable=no` also disables pinch zooming, which may be an accessibility concern.
+
+For IE11+, you can use `touch-action: manipulation;` to disable double-tap-to-zoom on certain elements (like links and buttons). For IE10 use `-ms-touch-action: manipulation`.
+
+## Usage ##
+
+Include fastclick.js in your JavaScript bundle or add it to your HTML page like this:
+
+```html
+
+```
+
+The script must be loaded prior to instantiating FastClick on any element of the page.
+
+To instantiate FastClick on the `body`, which is the recommended method of use:
+
+```js
+if ('addEventListener' in document) {
+ document.addEventListener('DOMContentLoaded', function() {
+ FastClick.attach(document.body);
+ }, false);
+}
+```
+
+Or, if you're using jQuery:
+
+```js
+$(function() {
+ FastClick.attach(document.body);
+});
+```
+
+If you're using Browserify or another CommonJS-style module system, the `FastClick.attach` function will be returned when you call `require('fastclick')`. As a result, the easiest way to use FastClick with these loaders is as follows:
+
+```js
+var attachFastClick = require('fastclick');
+attachFastClick(document.body);
+```
+
+### Minified ###
+
+Run `make` to build a minified version of FastClick using the Closure Compiler REST API. The minified file is saved to `build/fastclick.min.js` or you can [download a pre-minified version](http://build.origami.ft.com/bundles/js?modules=fastclick).
+
+Note: the pre-minified version is built using [our build service](http://origami.ft.com/docs/developer-guide/build-service/) which exposes the `FastClick` object through `Origami.fastclick` and will have the Browserify/CommonJS API (see above).
+
+```js
+var attachFastClick = Origami.fastclick;
+attachFastClick(document.body);
+```
+
+### AMD ###
+
+FastClick has AMD (Asynchronous Module Definition) support. This allows it to be lazy-loaded with an AMD loader, such as [RequireJS](http://requirejs.org/). Note that when using the AMD style require, the full `FastClick` object will be returned, _not_ `FastClick.attach`
+
+```js
+var FastClick = require('fastclick');
+FastClick.attach(document.body, options);
+```
+
+### Package managers ###
+
+You can install FastClick using [Component](https://github.com/component/component), [npm](https://npmjs.org/package/fastclick) or [Bower](http://bower.io/).
+
+For Ruby, there's a third-party gem called [fastclick-rails](http://rubygems.org/gems/fastclick-rails). For .NET there's a [NuGet package](http://nuget.org/packages/FastClick).
+
+## Advanced ##
+
+### Ignore certain elements with `needsclick` ###
+
+Sometimes you need FastClick to ignore certain elements. You can do this easily by adding the `needsclick` class.
+```html
+Ignored by FastClick
+```
+
+#### Use case 1: non-synthetic click required ####
+
+Internally, FastClick uses `document.createEvent` to fire a synthetic `click` event as soon as `touchend` is fired by the browser. It then suppresses the additional `click` event created by the browser after that. In some cases, the non-synthetic `click` event created by the browser is required, as described in the [triggering focus example](http://ftlabs.github.com/fastclick/examples/focus.html).
+
+This is where the `needsclick` class comes in. Add the class to any element that requires a non-synthetic click.
+
+#### Use case 2: Twitter Bootstrap 2.2.2 dropdowns ####
+
+Another example of when to use the `needsclick` class is with dropdowns in Twitter Bootstrap 2.2.2. Bootstrap add its own `touchstart` listener for dropdowns, so you want to tell FastClick to ignore those. If you don't, touch devices will automatically close the dropdown as soon as it is clicked, because both FastClick and Bootstrap execute the synthetic click, one opens the dropdown, the second closes it immediately after.
+
+```html
+Dropdown
+```
+
+## Examples ##
+
+FastClick is designed to cope with many different browser oddities. Here are some examples to illustrate this:
+
+* [basic use](http://ftlabs.github.com/fastclick/examples/layer.html) showing the increase in perceived responsiveness
+* [triggering focus](http://ftlabs.github.com/fastclick/examples/focus.html) on an input element from a `click` handler
+* [input element](http://ftlabs.github.com/fastclick/examples/input.html) which never receives clicks but gets fast focus
+
+## Tests ##
+
+There are no automated tests. The files in `tests/` are manual reduced test cases. We've had a think about how best to test these cases, but they tend to be very browser/device specific and sometimes subjective which means it's not so trivial to test.
+
+## Credits and collaboration ##
+
+FastClick is maintained by [Rowan Beentje](http://twitter.com/rowanbeentje), [Matthew Caruana Galizia](http://twitter.com/mcaruanagalizia) and [Matthew Andrews](http://twitter.com/andrewsmatt) at [FT Labs](http://labs.ft.com). All open source code released by FT Labs is licenced under the MIT licence. We welcome comments, feedback and suggestions. Please feel free to raise an issue or pull request.
diff --git a/user/themes/labonneadresse/bower_components/fastclick/bower.json b/user/themes/labonneadresse/bower_components/fastclick/bower.json
new file mode 100644
index 0000000..18e1abd
--- /dev/null
+++ b/user/themes/labonneadresse/bower_components/fastclick/bower.json
@@ -0,0 +1,12 @@
+{
+ "name": "fastclick",
+ "main": "lib/fastclick.js",
+ "ignore": [
+ "**/.*",
+ "component.json",
+ "package.json",
+ "Makefile",
+ "tests",
+ "examples"
+ ]
+}
diff --git a/user/themes/labonneadresse/bower_components/fastclick/lib/fastclick.js b/user/themes/labonneadresse/bower_components/fastclick/lib/fastclick.js
new file mode 100644
index 0000000..3af4f9d
--- /dev/null
+++ b/user/themes/labonneadresse/bower_components/fastclick/lib/fastclick.js
@@ -0,0 +1,841 @@
+;(function () {
+ 'use strict';
+
+ /**
+ * @preserve FastClick: polyfill to remove click delays on browsers with touch UIs.
+ *
+ * @codingstandard ftlabs-jsv2
+ * @copyright The Financial Times Limited [All Rights Reserved]
+ * @license MIT License (see LICENSE.txt)
+ */
+
+ /*jslint browser:true, node:true*/
+ /*global define, Event, Node*/
+
+
+ /**
+ * Instantiate fast-clicking listeners on the specified layer.
+ *
+ * @constructor
+ * @param {Element} layer The layer to listen on
+ * @param {Object} [options={}] The options to override the defaults
+ */
+ function FastClick(layer, options) {
+ var oldOnClick;
+
+ options = options || {};
+
+ /**
+ * Whether a click is currently being tracked.
+ *
+ * @type boolean
+ */
+ this.trackingClick = false;
+
+
+ /**
+ * Timestamp for when click tracking started.
+ *
+ * @type number
+ */
+ this.trackingClickStart = 0;
+
+
+ /**
+ * The element being tracked for a click.
+ *
+ * @type EventTarget
+ */
+ this.targetElement = null;
+
+
+ /**
+ * X-coordinate of touch start event.
+ *
+ * @type number
+ */
+ this.touchStartX = 0;
+
+
+ /**
+ * Y-coordinate of touch start event.
+ *
+ * @type number
+ */
+ this.touchStartY = 0;
+
+
+ /**
+ * ID of the last touch, retrieved from Touch.identifier.
+ *
+ * @type number
+ */
+ this.lastTouchIdentifier = 0;
+
+
+ /**
+ * Touchmove boundary, beyond which a click will be cancelled.
+ *
+ * @type number
+ */
+ this.touchBoundary = options.touchBoundary || 10;
+
+
+ /**
+ * The FastClick layer.
+ *
+ * @type Element
+ */
+ this.layer = layer;
+
+ /**
+ * The minimum time between tap(touchstart and touchend) events
+ *
+ * @type number
+ */
+ this.tapDelay = options.tapDelay || 200;
+
+ /**
+ * The maximum time for a tap
+ *
+ * @type number
+ */
+ this.tapTimeout = options.tapTimeout || 700;
+
+ if (FastClick.notNeeded(layer)) {
+ return;
+ }
+
+ // Some old versions of Android don't have Function.prototype.bind
+ function bind(method, context) {
+ return function() { return method.apply(context, arguments); };
+ }
+
+
+ var methods = ['onMouse', 'onClick', 'onTouchStart', 'onTouchMove', 'onTouchEnd', 'onTouchCancel'];
+ var context = this;
+ for (var i = 0, l = methods.length; i < l; i++) {
+ context[methods[i]] = bind(context[methods[i]], context);
+ }
+
+ // Set up event handlers as required
+ if (deviceIsAndroid) {
+ layer.addEventListener('mouseover', this.onMouse, true);
+ layer.addEventListener('mousedown', this.onMouse, true);
+ layer.addEventListener('mouseup', this.onMouse, true);
+ }
+
+ layer.addEventListener('click', this.onClick, true);
+ layer.addEventListener('touchstart', this.onTouchStart, false);
+ layer.addEventListener('touchmove', this.onTouchMove, false);
+ layer.addEventListener('touchend', this.onTouchEnd, false);
+ layer.addEventListener('touchcancel', this.onTouchCancel, false);
+
+ // Hack is required for browsers that don't support Event#stopImmediatePropagation (e.g. Android 2)
+ // which is how FastClick normally stops click events bubbling to callbacks registered on the FastClick
+ // layer when they are cancelled.
+ if (!Event.prototype.stopImmediatePropagation) {
+ layer.removeEventListener = function(type, callback, capture) {
+ var rmv = Node.prototype.removeEventListener;
+ if (type === 'click') {
+ rmv.call(layer, type, callback.hijacked || callback, capture);
+ } else {
+ rmv.call(layer, type, callback, capture);
+ }
+ };
+
+ layer.addEventListener = function(type, callback, capture) {
+ var adv = Node.prototype.addEventListener;
+ if (type === 'click') {
+ adv.call(layer, type, callback.hijacked || (callback.hijacked = function(event) {
+ if (!event.propagationStopped) {
+ callback(event);
+ }
+ }), capture);
+ } else {
+ adv.call(layer, type, callback, capture);
+ }
+ };
+ }
+
+ // If a handler is already declared in the element's onclick attribute, it will be fired before
+ // FastClick's onClick handler. Fix this by pulling out the user-defined handler function and
+ // adding it as listener.
+ if (typeof layer.onclick === 'function') {
+
+ // Android browser on at least 3.2 requires a new reference to the function in layer.onclick
+ // - the old one won't work if passed to addEventListener directly.
+ oldOnClick = layer.onclick;
+ layer.addEventListener('click', function(event) {
+ oldOnClick(event);
+ }, false);
+ layer.onclick = null;
+ }
+ }
+
+ /**
+ * Windows Phone 8.1 fakes user agent string to look like Android and iPhone.
+ *
+ * @type boolean
+ */
+ var deviceIsWindowsPhone = navigator.userAgent.indexOf("Windows Phone") >= 0;
+
+ /**
+ * Android requires exceptions.
+ *
+ * @type boolean
+ */
+ var deviceIsAndroid = navigator.userAgent.indexOf('Android') > 0 && !deviceIsWindowsPhone;
+
+
+ /**
+ * iOS requires exceptions.
+ *
+ * @type boolean
+ */
+ var deviceIsIOS = /iP(ad|hone|od)/.test(navigator.userAgent) && !deviceIsWindowsPhone;
+
+
+ /**
+ * iOS 4 requires an exception for select elements.
+ *
+ * @type boolean
+ */
+ var deviceIsIOS4 = deviceIsIOS && (/OS 4_\d(_\d)?/).test(navigator.userAgent);
+
+
+ /**
+ * iOS 6.0-7.* requires the target element to be manually derived
+ *
+ * @type boolean
+ */
+ var deviceIsIOSWithBadTarget = deviceIsIOS && (/OS [6-7]_\d/).test(navigator.userAgent);
+
+ /**
+ * BlackBerry requires exceptions.
+ *
+ * @type boolean
+ */
+ var deviceIsBlackBerry10 = navigator.userAgent.indexOf('BB10') > 0;
+
+ /**
+ * Determine whether a given element requires a native click.
+ *
+ * @param {EventTarget|Element} target Target DOM element
+ * @returns {boolean} Returns true if the element needs a native click
+ */
+ FastClick.prototype.needsClick = function(target) {
+ switch (target.nodeName.toLowerCase()) {
+
+ // Don't send a synthetic click to disabled inputs (issue #62)
+ case 'button':
+ case 'select':
+ case 'textarea':
+ if (target.disabled) {
+ return true;
+ }
+
+ break;
+ case 'input':
+
+ // File inputs need real clicks on iOS 6 due to a browser bug (issue #68)
+ if ((deviceIsIOS && target.type === 'file') || target.disabled) {
+ return true;
+ }
+
+ break;
+ case 'label':
+ case 'iframe': // iOS8 homescreen apps can prevent events bubbling into frames
+ case 'video':
+ return true;
+ }
+
+ return (/\bneedsclick\b/).test(target.className);
+ };
+
+
+ /**
+ * Determine whether a given element requires a call to focus to simulate click into element.
+ *
+ * @param {EventTarget|Element} target Target DOM element
+ * @returns {boolean} Returns true if the element requires a call to focus to simulate native click.
+ */
+ FastClick.prototype.needsFocus = function(target) {
+ switch (target.nodeName.toLowerCase()) {
+ case 'textarea':
+ return true;
+ case 'select':
+ return !deviceIsAndroid;
+ case 'input':
+ switch (target.type) {
+ case 'button':
+ case 'checkbox':
+ case 'file':
+ case 'image':
+ case 'radio':
+ case 'submit':
+ return false;
+ }
+
+ // No point in attempting to focus disabled inputs
+ return !target.disabled && !target.readOnly;
+ default:
+ return (/\bneedsfocus\b/).test(target.className);
+ }
+ };
+
+
+ /**
+ * Send a click event to the specified element.
+ *
+ * @param {EventTarget|Element} targetElement
+ * @param {Event} event
+ */
+ FastClick.prototype.sendClick = function(targetElement, event) {
+ var clickEvent, touch;
+
+ // On some Android devices activeElement needs to be blurred otherwise the synthetic click will have no effect (#24)
+ if (document.activeElement && document.activeElement !== targetElement) {
+ document.activeElement.blur();
+ }
+
+ touch = event.changedTouches[0];
+
+ // Synthesise a click event, with an extra attribute so it can be tracked
+ clickEvent = document.createEvent('MouseEvents');
+ clickEvent.initMouseEvent(this.determineEventType(targetElement), true, true, window, 1, touch.screenX, touch.screenY, touch.clientX, touch.clientY, false, false, false, false, 0, null);
+ clickEvent.forwardedTouchEvent = true;
+ targetElement.dispatchEvent(clickEvent);
+ };
+
+ FastClick.prototype.determineEventType = function(targetElement) {
+
+ //Issue #159: Android Chrome Select Box does not open with a synthetic click event
+ if (deviceIsAndroid && targetElement.tagName.toLowerCase() === 'select') {
+ return 'mousedown';
+ }
+
+ return 'click';
+ };
+
+
+ /**
+ * @param {EventTarget|Element} targetElement
+ */
+ FastClick.prototype.focus = function(targetElement) {
+ var length;
+
+ // Issue #160: on iOS 7, some input elements (e.g. date datetime month) throw a vague TypeError on setSelectionRange. These elements don't have an integer value for the selectionStart and selectionEnd properties, but unfortunately that can't be used for detection because accessing the properties also throws a TypeError. Just check the type instead. Filed as Apple bug #15122724.
+ if (deviceIsIOS && targetElement.setSelectionRange && targetElement.type.indexOf('date') !== 0 && targetElement.type !== 'time' && targetElement.type !== 'month') {
+ length = targetElement.value.length;
+ targetElement.setSelectionRange(length, length);
+ } else {
+ targetElement.focus();
+ }
+ };
+
+
+ /**
+ * Check whether the given target element is a child of a scrollable layer and if so, set a flag on it.
+ *
+ * @param {EventTarget|Element} targetElement
+ */
+ FastClick.prototype.updateScrollParent = function(targetElement) {
+ var scrollParent, parentElement;
+
+ scrollParent = targetElement.fastClickScrollParent;
+
+ // Attempt to discover whether the target element is contained within a scrollable layer. Re-check if the
+ // target element was moved to another parent.
+ if (!scrollParent || !scrollParent.contains(targetElement)) {
+ parentElement = targetElement;
+ do {
+ if (parentElement.scrollHeight > parentElement.offsetHeight) {
+ scrollParent = parentElement;
+ targetElement.fastClickScrollParent = parentElement;
+ break;
+ }
+
+ parentElement = parentElement.parentElement;
+ } while (parentElement);
+ }
+
+ // Always update the scroll top tracker if possible.
+ if (scrollParent) {
+ scrollParent.fastClickLastScrollTop = scrollParent.scrollTop;
+ }
+ };
+
+
+ /**
+ * @param {EventTarget} targetElement
+ * @returns {Element|EventTarget}
+ */
+ FastClick.prototype.getTargetElementFromEventTarget = function(eventTarget) {
+
+ // On some older browsers (notably Safari on iOS 4.1 - see issue #56) the event target may be a text node.
+ if (eventTarget.nodeType === Node.TEXT_NODE) {
+ return eventTarget.parentNode;
+ }
+
+ return eventTarget;
+ };
+
+
+ /**
+ * On touch start, record the position and scroll offset.
+ *
+ * @param {Event} event
+ * @returns {boolean}
+ */
+ FastClick.prototype.onTouchStart = function(event) {
+ var targetElement, touch, selection;
+
+ // Ignore multiple touches, otherwise pinch-to-zoom is prevented if both fingers are on the FastClick element (issue #111).
+ if (event.targetTouches.length > 1) {
+ return true;
+ }
+
+ targetElement = this.getTargetElementFromEventTarget(event.target);
+ touch = event.targetTouches[0];
+
+ if (deviceIsIOS) {
+
+ // Only trusted events will deselect text on iOS (issue #49)
+ selection = window.getSelection();
+ if (selection.rangeCount && !selection.isCollapsed) {
+ return true;
+ }
+
+ if (!deviceIsIOS4) {
+
+ // Weird things happen on iOS when an alert or confirm dialog is opened from a click event callback (issue #23):
+ // when the user next taps anywhere else on the page, new touchstart and touchend events are dispatched
+ // with the same identifier as the touch event that previously triggered the click that triggered the alert.
+ // Sadly, there is an issue on iOS 4 that causes some normal touch events to have the same identifier as an
+ // immediately preceeding touch event (issue #52), so this fix is unavailable on that platform.
+ // Issue 120: touch.identifier is 0 when Chrome dev tools 'Emulate touch events' is set with an iOS device UA string,
+ // which causes all touch events to be ignored. As this block only applies to iOS, and iOS identifiers are always long,
+ // random integers, it's safe to to continue if the identifier is 0 here.
+ if (touch.identifier && touch.identifier === this.lastTouchIdentifier) {
+ event.preventDefault();
+ return false;
+ }
+
+ this.lastTouchIdentifier = touch.identifier;
+
+ // If the target element is a child of a scrollable layer (using -webkit-overflow-scrolling: touch) and:
+ // 1) the user does a fling scroll on the scrollable layer
+ // 2) the user stops the fling scroll with another tap
+ // then the event.target of the last 'touchend' event will be the element that was under the user's finger
+ // when the fling scroll was started, causing FastClick to send a click event to that layer - unless a check
+ // is made to ensure that a parent layer was not scrolled before sending a synthetic click (issue #42).
+ this.updateScrollParent(targetElement);
+ }
+ }
+
+ this.trackingClick = true;
+ this.trackingClickStart = event.timeStamp;
+ this.targetElement = targetElement;
+
+ this.touchStartX = touch.pageX;
+ this.touchStartY = touch.pageY;
+
+ // Prevent phantom clicks on fast double-tap (issue #36)
+ if ((event.timeStamp - this.lastClickTime) < this.tapDelay) {
+ event.preventDefault();
+ }
+
+ return true;
+ };
+
+
+ /**
+ * Based on a touchmove event object, check whether the touch has moved past a boundary since it started.
+ *
+ * @param {Event} event
+ * @returns {boolean}
+ */
+ FastClick.prototype.touchHasMoved = function(event) {
+ var touch = event.changedTouches[0], boundary = this.touchBoundary;
+
+ if (Math.abs(touch.pageX - this.touchStartX) > boundary || Math.abs(touch.pageY - this.touchStartY) > boundary) {
+ return true;
+ }
+
+ return false;
+ };
+
+
+ /**
+ * Update the last position.
+ *
+ * @param {Event} event
+ * @returns {boolean}
+ */
+ FastClick.prototype.onTouchMove = function(event) {
+ if (!this.trackingClick) {
+ return true;
+ }
+
+ // If the touch has moved, cancel the click tracking
+ if (this.targetElement !== this.getTargetElementFromEventTarget(event.target) || this.touchHasMoved(event)) {
+ this.trackingClick = false;
+ this.targetElement = null;
+ }
+
+ return true;
+ };
+
+
+ /**
+ * Attempt to find the labelled control for the given label element.
+ *
+ * @param {EventTarget|HTMLLabelElement} labelElement
+ * @returns {Element|null}
+ */
+ FastClick.prototype.findControl = function(labelElement) {
+
+ // Fast path for newer browsers supporting the HTML5 control attribute
+ if (labelElement.control !== undefined) {
+ return labelElement.control;
+ }
+
+ // All browsers under test that support touch events also support the HTML5 htmlFor attribute
+ if (labelElement.htmlFor) {
+ return document.getElementById(labelElement.htmlFor);
+ }
+
+ // If no for attribute exists, attempt to retrieve the first labellable descendant element
+ // the list of which is defined here: http://www.w3.org/TR/html5/forms.html#category-label
+ return labelElement.querySelector('button, input:not([type=hidden]), keygen, meter, output, progress, select, textarea');
+ };
+
+
+ /**
+ * On touch end, determine whether to send a click event at once.
+ *
+ * @param {Event} event
+ * @returns {boolean}
+ */
+ FastClick.prototype.onTouchEnd = function(event) {
+ var forElement, trackingClickStart, targetTagName, scrollParent, touch, targetElement = this.targetElement;
+
+ if (!this.trackingClick) {
+ return true;
+ }
+
+ // Prevent phantom clicks on fast double-tap (issue #36)
+ if ((event.timeStamp - this.lastClickTime) < this.tapDelay) {
+ this.cancelNextClick = true;
+ return true;
+ }
+
+ if ((event.timeStamp - this.trackingClickStart) > this.tapTimeout) {
+ return true;
+ }
+
+ // Reset to prevent wrong click cancel on input (issue #156).
+ this.cancelNextClick = false;
+
+ this.lastClickTime = event.timeStamp;
+
+ trackingClickStart = this.trackingClickStart;
+ this.trackingClick = false;
+ this.trackingClickStart = 0;
+
+ // On some iOS devices, the targetElement supplied with the event is invalid if the layer
+ // is performing a transition or scroll, and has to be re-detected manually. Note that
+ // for this to function correctly, it must be called *after* the event target is checked!
+ // See issue #57; also filed as rdar://13048589 .
+ if (deviceIsIOSWithBadTarget) {
+ touch = event.changedTouches[0];
+
+ // In certain cases arguments of elementFromPoint can be negative, so prevent setting targetElement to null
+ targetElement = document.elementFromPoint(touch.pageX - window.pageXOffset, touch.pageY - window.pageYOffset) || targetElement;
+ targetElement.fastClickScrollParent = this.targetElement.fastClickScrollParent;
+ }
+
+ targetTagName = targetElement.tagName.toLowerCase();
+ if (targetTagName === 'label') {
+ forElement = this.findControl(targetElement);
+ if (forElement) {
+ this.focus(targetElement);
+ if (deviceIsAndroid) {
+ return false;
+ }
+
+ targetElement = forElement;
+ }
+ } else if (this.needsFocus(targetElement)) {
+
+ // Case 1: If the touch started a while ago (best guess is 100ms based on tests for issue #36) then focus will be triggered anyway. Return early and unset the target element reference so that the subsequent click will be allowed through.
+ // Case 2: Without this exception for input elements tapped when the document is contained in an iframe, then any inputted text won't be visible even though the value attribute is updated as the user types (issue #37).
+ if ((event.timeStamp - trackingClickStart) > 100 || (deviceIsIOS && window.top !== window && targetTagName === 'input')) {
+ this.targetElement = null;
+ return false;
+ }
+
+ this.focus(targetElement);
+ this.sendClick(targetElement, event);
+
+ // Select elements need the event to go through on iOS 4, otherwise the selector menu won't open.
+ // Also this breaks opening selects when VoiceOver is active on iOS6, iOS7 (and possibly others)
+ if (!deviceIsIOS || targetTagName !== 'select') {
+ this.targetElement = null;
+ event.preventDefault();
+ }
+
+ return false;
+ }
+
+ if (deviceIsIOS && !deviceIsIOS4) {
+
+ // Don't send a synthetic click event if the target element is contained within a parent layer that was scrolled
+ // and this tap is being used to stop the scrolling (usually initiated by a fling - issue #42).
+ scrollParent = targetElement.fastClickScrollParent;
+ if (scrollParent && scrollParent.fastClickLastScrollTop !== scrollParent.scrollTop) {
+ return true;
+ }
+ }
+
+ // Prevent the actual click from going though - unless the target node is marked as requiring
+ // real clicks or if it is in the whitelist in which case only non-programmatic clicks are permitted.
+ if (!this.needsClick(targetElement)) {
+ event.preventDefault();
+ this.sendClick(targetElement, event);
+ }
+
+ return false;
+ };
+
+
+ /**
+ * On touch cancel, stop tracking the click.
+ *
+ * @returns {void}
+ */
+ FastClick.prototype.onTouchCancel = function() {
+ this.trackingClick = false;
+ this.targetElement = null;
+ };
+
+
+ /**
+ * Determine mouse events which should be permitted.
+ *
+ * @param {Event} event
+ * @returns {boolean}
+ */
+ FastClick.prototype.onMouse = function(event) {
+
+ // If a target element was never set (because a touch event was never fired) allow the event
+ if (!this.targetElement) {
+ return true;
+ }
+
+ if (event.forwardedTouchEvent) {
+ return true;
+ }
+
+ // Programmatically generated events targeting a specific element should be permitted
+ if (!event.cancelable) {
+ return true;
+ }
+
+ // Derive and check the target element to see whether the mouse event needs to be permitted;
+ // unless explicitly enabled, prevent non-touch click events from triggering actions,
+ // to prevent ghost/doubleclicks.
+ if (!this.needsClick(this.targetElement) || this.cancelNextClick) {
+
+ // Prevent any user-added listeners declared on FastClick element from being fired.
+ if (event.stopImmediatePropagation) {
+ event.stopImmediatePropagation();
+ } else {
+
+ // Part of the hack for browsers that don't support Event#stopImmediatePropagation (e.g. Android 2)
+ event.propagationStopped = true;
+ }
+
+ // Cancel the event
+ event.stopPropagation();
+ event.preventDefault();
+
+ return false;
+ }
+
+ // If the mouse event is permitted, return true for the action to go through.
+ return true;
+ };
+
+
+ /**
+ * On actual clicks, determine whether this is a touch-generated click, a click action occurring
+ * naturally after a delay after a touch (which needs to be cancelled to avoid duplication), or
+ * an actual click which should be permitted.
+ *
+ * @param {Event} event
+ * @returns {boolean}
+ */
+ FastClick.prototype.onClick = function(event) {
+ var permitted;
+
+ // It's possible for another FastClick-like library delivered with third-party code to fire a click event before FastClick does (issue #44). In that case, set the click-tracking flag back to false and return early. This will cause onTouchEnd to return early.
+ if (this.trackingClick) {
+ this.targetElement = null;
+ this.trackingClick = false;
+ return true;
+ }
+
+ // Very odd behaviour on iOS (issue #18): if a submit element is present inside a form and the user hits enter in the iOS simulator or clicks the Go button on the pop-up OS keyboard the a kind of 'fake' click event will be triggered with the submit-type input element as the target.
+ if (event.target.type === 'submit' && event.detail === 0) {
+ return true;
+ }
+
+ permitted = this.onMouse(event);
+
+ // Only unset targetElement if the click is not permitted. This will ensure that the check for !targetElement in onMouse fails and the browser's click doesn't go through.
+ if (!permitted) {
+ this.targetElement = null;
+ }
+
+ // If clicks are permitted, return true for the action to go through.
+ return permitted;
+ };
+
+
+ /**
+ * Remove all FastClick's event listeners.
+ *
+ * @returns {void}
+ */
+ FastClick.prototype.destroy = function() {
+ var layer = this.layer;
+
+ if (deviceIsAndroid) {
+ layer.removeEventListener('mouseover', this.onMouse, true);
+ layer.removeEventListener('mousedown', this.onMouse, true);
+ layer.removeEventListener('mouseup', this.onMouse, true);
+ }
+
+ layer.removeEventListener('click', this.onClick, true);
+ layer.removeEventListener('touchstart', this.onTouchStart, false);
+ layer.removeEventListener('touchmove', this.onTouchMove, false);
+ layer.removeEventListener('touchend', this.onTouchEnd, false);
+ layer.removeEventListener('touchcancel', this.onTouchCancel, false);
+ };
+
+
+ /**
+ * Check whether FastClick is needed.
+ *
+ * @param {Element} layer The layer to listen on
+ */
+ FastClick.notNeeded = function(layer) {
+ var metaViewport;
+ var chromeVersion;
+ var blackberryVersion;
+ var firefoxVersion;
+
+ // Devices that don't support touch don't need FastClick
+ if (typeof window.ontouchstart === 'undefined') {
+ return true;
+ }
+
+ // Chrome version - zero for other browsers
+ chromeVersion = +(/Chrome\/([0-9]+)/.exec(navigator.userAgent) || [,0])[1];
+
+ if (chromeVersion) {
+
+ if (deviceIsAndroid) {
+ metaViewport = document.querySelector('meta[name=viewport]');
+
+ if (metaViewport) {
+ // Chrome on Android with user-scalable="no" doesn't need FastClick (issue #89)
+ if (metaViewport.content.indexOf('user-scalable=no') !== -1) {
+ return true;
+ }
+ // Chrome 32 and above with width=device-width or less don't need FastClick
+ if (chromeVersion > 31 && document.documentElement.scrollWidth <= window.outerWidth) {
+ return true;
+ }
+ }
+
+ // Chrome desktop doesn't need FastClick (issue #15)
+ } else {
+ return true;
+ }
+ }
+
+ if (deviceIsBlackBerry10) {
+ blackberryVersion = navigator.userAgent.match(/Version\/([0-9]*)\.([0-9]*)/);
+
+ // BlackBerry 10.3+ does not require Fastclick library.
+ // https://github.com/ftlabs/fastclick/issues/251
+ if (blackberryVersion[1] >= 10 && blackberryVersion[2] >= 3) {
+ metaViewport = document.querySelector('meta[name=viewport]');
+
+ if (metaViewport) {
+ // user-scalable=no eliminates click delay.
+ if (metaViewport.content.indexOf('user-scalable=no') !== -1) {
+ return true;
+ }
+ // width=device-width (or less than device-width) eliminates click delay.
+ if (document.documentElement.scrollWidth <= window.outerWidth) {
+ return true;
+ }
+ }
+ }
+ }
+
+ // IE10 with -ms-touch-action: none or manipulation, which disables double-tap-to-zoom (issue #97)
+ if (layer.style.msTouchAction === 'none' || layer.style.touchAction === 'manipulation') {
+ return true;
+ }
+
+ // Firefox version - zero for other browsers
+ firefoxVersion = +(/Firefox\/([0-9]+)/.exec(navigator.userAgent) || [,0])[1];
+
+ if (firefoxVersion >= 27) {
+ // Firefox 27+ does not have tap delay if the content is not zoomable - https://bugzilla.mozilla.org/show_bug.cgi?id=922896
+
+ metaViewport = document.querySelector('meta[name=viewport]');
+ if (metaViewport && (metaViewport.content.indexOf('user-scalable=no') !== -1 || document.documentElement.scrollWidth <= window.outerWidth)) {
+ return true;
+ }
+ }
+
+ // IE11: prefixed -ms-touch-action is no longer supported and it's recomended to use non-prefixed version
+ // http://msdn.microsoft.com/en-us/library/windows/apps/Hh767313.aspx
+ if (layer.style.touchAction === 'none' || layer.style.touchAction === 'manipulation') {
+ return true;
+ }
+
+ return false;
+ };
+
+
+ /**
+ * Factory method for creating a FastClick object
+ *
+ * @param {Element} layer The layer to listen on
+ * @param {Object} [options={}] The options to override the defaults
+ */
+ FastClick.attach = function(layer, options) {
+ return new FastClick(layer, options);
+ };
+
+
+ if (typeof define === 'function' && typeof define.amd === 'object' && define.amd) {
+
+ // AMD. Register as an anonymous module.
+ define(function() {
+ return FastClick;
+ });
+ } else if (typeof module !== 'undefined' && module.exports) {
+ module.exports = FastClick.attach;
+ module.exports.FastClick = FastClick;
+ } else {
+ window.FastClick = FastClick;
+ }
+}());
diff --git a/user/themes/labonneadresse/bower_components/fizzy-ui-utils/.bower.json b/user/themes/labonneadresse/bower_components/fizzy-ui-utils/.bower.json
new file mode 100644
index 0000000..1f625f1
--- /dev/null
+++ b/user/themes/labonneadresse/bower_components/fizzy-ui-utils/.bower.json
@@ -0,0 +1,41 @@
+{
+ "name": "fizzy-ui-utils",
+ "version": "1.0.1",
+ "authors": [
+ "David DeSandro"
+ ],
+ "description": "UI utilities",
+ "main": "utils.js",
+ "dependencies": {
+ "doc-ready": "~1.0.4",
+ "matches-selector": "~1.0.2"
+ },
+ "moduleType": [
+ "amd",
+ "globals",
+ "node"
+ ],
+ "keywords": [
+ "utility",
+ "ui"
+ ],
+ "license": "MIT",
+ "ignore": [
+ "**/.*",
+ "node_modules",
+ "bower_components",
+ "test",
+ "tests",
+ "package.json"
+ ],
+ "homepage": "https://github.com/metafizzy/fizzy-ui-utils",
+ "_release": "1.0.1",
+ "_resolution": {
+ "type": "version",
+ "tag": "v1.0.1",
+ "commit": "823b543b583f4831d25aadf94c26fc6018e62172"
+ },
+ "_source": "git://github.com/metafizzy/fizzy-ui-utils.git",
+ "_target": "~1.0.1",
+ "_originalSource": "fizzy-ui-utils"
+}
\ No newline at end of file
diff --git a/user/themes/labonneadresse/bower_components/fizzy-ui-utils/README.md b/user/themes/labonneadresse/bower_components/fizzy-ui-utils/README.md
new file mode 100644
index 0000000..e880394
--- /dev/null
+++ b/user/themes/labonneadresse/bower_components/fizzy-ui-utils/README.md
@@ -0,0 +1,73 @@
+# Fizzy UI utils
+
+UI utility & helper functions
+
+Used in [Flickity](http://flickity.metafizzy.co), [Isotope](http://isotope.metafizzy.co), [Masonry](http://masonry.desandro.com), [Draggabilly](http://draggabilly.desandro.com)
+
+## Install
+
+Bower: `bower install fizzy-ui-utils --save`
+
+npm: `npm install fizzy-ui-utils --save`
+
+## API
+
+``` js
+// fizzyUIUtils is the browser global
+var utils = fizzyUIUtils;
+
+// ---- ---- //
+
+utils.extend( a, b )
+// extend object
+
+utils.modulo( num, div )
+// num [modulo] div
+
+utils.isArray( obj )
+// check if object is Array
+
+utils.makeArray( obj )
+// make array from object
+
+utils.indexOf( ary, obj )
+// get index of object in array
+
+utils.removeFrom( ary, obj )
+// remove object from array
+
+utils.isElement( obj )
+// check if object is an element
+
+utils.setText( elem, text )
+// set text of an element
+
+utils.getParent( elem, selector )
+// get parent element of an element, given a selector string
+
+utils.getQueryElement( elem )
+// if elem is a string, use it as a selector and return element
+
+Class.prototype.handleEvent = utils.handleEvent;
+// enable Class.onclick when element.addEventListener( 'click', this, false )
+
+utils.filterFindElements( elems, selector )
+// iterate through elems, filter and find all elements that match selector
+
+utils.debounceMethod( Class, methodName, threhold )
+// debounce a class method
+
+utils.toDashed( str )
+// 'camelCaseString' -> 'camel-case-string'
+
+utils.htmlInit( Class, namespace )
+// on document ready, initialize Class on every element
+// that matches js-namespace
+// pass in JSON options from element's data-options-namespace attribute
+```
+
+---
+
+MIT license. Have at it.
+
+By [Metafizzy](http://metafizzy.co)
diff --git a/user/themes/labonneadresse/bower_components/fizzy-ui-utils/bower.json b/user/themes/labonneadresse/bower_components/fizzy-ui-utils/bower.json
new file mode 100644
index 0000000..b7caf63
--- /dev/null
+++ b/user/themes/labonneadresse/bower_components/fizzy-ui-utils/bower.json
@@ -0,0 +1,31 @@
+{
+ "name": "fizzy-ui-utils",
+ "version": "1.0.1",
+ "authors": [
+ "David DeSandro"
+ ],
+ "description": "UI utilities",
+ "main": "utils.js",
+ "dependencies": {
+ "doc-ready": "~1.0.4",
+ "matches-selector": "~1.0.2"
+ },
+ "moduleType": [
+ "amd",
+ "globals",
+ "node"
+ ],
+ "keywords": [
+ "utility",
+ "ui"
+ ],
+ "license": "MIT",
+ "ignore": [
+ "**/.*",
+ "node_modules",
+ "bower_components",
+ "test",
+ "tests",
+ "package.json"
+ ]
+}
diff --git a/user/themes/labonneadresse/bower_components/fizzy-ui-utils/utils.js b/user/themes/labonneadresse/bower_components/fizzy-ui-utils/utils.js
new file mode 100644
index 0000000..ebac882
--- /dev/null
+++ b/user/themes/labonneadresse/bower_components/fizzy-ui-utils/utils.js
@@ -0,0 +1,270 @@
+/**
+ * Fizzy UI utils v1.0.1
+ * MIT license
+ */
+
+/*jshint browser: true, undef: true, unused: true, strict: true */
+
+( function( window, factory ) {
+ /*global define: false, module: false, require: false */
+ 'use strict';
+ // universal module definition
+
+ if ( typeof define == 'function' && define.amd ) {
+ // AMD
+ define( [
+ 'doc-ready/doc-ready',
+ 'matches-selector/matches-selector'
+ ], function( docReady, matchesSelector ) {
+ return factory( window, docReady, matchesSelector );
+ });
+ } else if ( typeof exports == 'object' ) {
+ // CommonJS
+ module.exports = factory(
+ window,
+ require('doc-ready'),
+ require('desandro-matches-selector')
+ );
+ } else {
+ // browser global
+ window.fizzyUIUtils = factory(
+ window,
+ window.docReady,
+ window.matchesSelector
+ );
+ }
+
+}( window, function factory( window, docReady, matchesSelector ) {
+
+'use strict';
+
+var utils = {};
+
+// ----- extend ----- //
+
+// extends objects
+utils.extend = function( a, b ) {
+ for ( var prop in b ) {
+ a[ prop ] = b[ prop ];
+ }
+ return a;
+};
+
+// ----- modulo ----- //
+
+utils.modulo = function( num, div ) {
+ return ( ( num % div ) + div ) % div;
+};
+
+// ----- isArray ----- //
+
+var objToString = Object.prototype.toString;
+utils.isArray = function( obj ) {
+ return objToString.call( obj ) == '[object Array]';
+};
+
+// ----- makeArray ----- //
+
+// turn element or nodeList into an array
+utils.makeArray = function( obj ) {
+ var ary = [];
+ if ( utils.isArray( obj ) ) {
+ // use object if already an array
+ ary = obj;
+ } else if ( obj && typeof obj.length == 'number' ) {
+ // convert nodeList to array
+ for ( var i=0, len = obj.length; i < len; i++ ) {
+ ary.push( obj[i] );
+ }
+ } else {
+ // array of single index
+ ary.push( obj );
+ }
+ return ary;
+};
+
+// ----- indexOf ----- //
+
+// index of helper cause IE8
+utils.indexOf = Array.prototype.indexOf ? function( ary, obj ) {
+ return ary.indexOf( obj );
+ } : function( ary, obj ) {
+ for ( var i=0, len = ary.length; i < len; i++ ) {
+ if ( ary[i] === obj ) {
+ return i;
+ }
+ }
+ return -1;
+ };
+
+// ----- removeFrom ----- //
+
+utils.removeFrom = function( ary, obj ) {
+ var index = utils.indexOf( ary, obj );
+ if ( index != -1 ) {
+ ary.splice( index, 1 );
+ }
+};
+
+// ----- isElement ----- //
+
+// http://stackoverflow.com/a/384380/182183
+utils.isElement = ( typeof HTMLElement == 'function' || typeof HTMLElement == 'object' ) ?
+ function isElementDOM2( obj ) {
+ return obj instanceof HTMLElement;
+ } :
+ function isElementQuirky( obj ) {
+ return obj && typeof obj == 'object' &&
+ obj.nodeType == 1 && typeof obj.nodeName == 'string';
+ };
+
+// ----- setText ----- //
+
+utils.setText = ( function() {
+ var setTextProperty;
+ function setText( elem, text ) {
+ // only check setTextProperty once
+ setTextProperty = setTextProperty || ( document.documentElement.textContent !== undefined ? 'textContent' : 'innerText' );
+ elem[ setTextProperty ] = text;
+ }
+ return setText;
+})();
+
+// ----- getParent ----- //
+
+utils.getParent = function( elem, selector ) {
+ while ( elem != document.body ) {
+ elem = elem.parentNode;
+ if ( matchesSelector( elem, selector ) ) {
+ return elem;
+ }
+ }
+};
+
+// ----- getQueryElement ----- //
+
+// use element as selector string
+utils.getQueryElement = function( elem ) {
+ if ( typeof elem == 'string' ) {
+ return document.querySelector( elem );
+ }
+ return elem;
+};
+
+// ----- handleEvent ----- //
+
+// enable .ontype to trigger from .addEventListener( elem, 'type' )
+utils.handleEvent = function( event ) {
+ var method = 'on' + event.type;
+ if ( this[ method ] ) {
+ this[ method ]( event );
+ }
+};
+
+// ----- filterFindElements ----- //
+
+utils.filterFindElements = function( elems, selector ) {
+ // make array of elems
+ elems = utils.makeArray( elems );
+ var ffElems = [];
+
+ for ( var i=0, len = elems.length; i < len; i++ ) {
+ var elem = elems[i];
+ // check that elem is an actual element
+ if ( !utils.isElement( elem ) ) {
+ continue;
+ }
+ // filter & find items if we have a selector
+ if ( selector ) {
+ // filter siblings
+ if ( matchesSelector( elem, selector ) ) {
+ ffElems.push( elem );
+ }
+ // find children
+ var childElems = elem.querySelectorAll( selector );
+ // concat childElems to filterFound array
+ for ( var j=0, jLen = childElems.length; j < jLen; j++ ) {
+ ffElems.push( childElems[j] );
+ }
+ } else {
+ ffElems.push( elem );
+ }
+ }
+
+ return ffElems;
+};
+
+// ----- debounceMethod ----- //
+
+utils.debounceMethod = function( _class, methodName, threshold ) {
+ // original method
+ var method = _class.prototype[ methodName ];
+ var timeoutName = methodName + 'Timeout';
+
+ _class.prototype[ methodName ] = function() {
+ var timeout = this[ timeoutName ];
+ if ( timeout ) {
+ clearTimeout( timeout );
+ }
+ var args = arguments;
+
+ var _this = this;
+ this[ timeoutName ] = setTimeout( function() {
+ method.apply( _this, args );
+ delete _this[ timeoutName ];
+ }, threshold || 100 );
+ };
+};
+
+// ----- htmlInit ----- //
+
+// http://jamesroberts.name/blog/2010/02/22/string-functions-for-javascript-trim-to-camel-case-to-dashed-and-to-underscore/
+utils.toDashed = function( str ) {
+ return str.replace( /(.)([A-Z])/g, function( match, $1, $2 ) {
+ return $1 + '-' + $2;
+ }).toLowerCase();
+};
+
+var console = window.console;
+/**
+ * allow user to initialize classes via .js-namespace class
+ * htmlInit( Widget, 'widgetName' )
+ * options are parsed from data-namespace-option attribute
+ */
+utils.htmlInit = function( WidgetClass, namespace ) {
+ docReady( function() {
+ var dashedNamespace = utils.toDashed( namespace );
+ var elems = document.querySelectorAll( '.js-' + dashedNamespace );
+ var dataAttr = 'data-' + dashedNamespace + '-options';
+
+ for ( var i=0, len = elems.length; i < len; i++ ) {
+ var elem = elems[i];
+ var attr = elem.getAttribute( dataAttr );
+ var options;
+ try {
+ options = attr && JSON.parse( attr );
+ } catch ( error ) {
+ // log error, do not initialize
+ if ( console ) {
+ console.error( 'Error parsing ' + dataAttr + ' on ' +
+ elem.nodeName.toLowerCase() + ( elem.id ? '#' + elem.id : '' ) + ': ' +
+ error );
+ }
+ continue;
+ }
+ // initialize
+ var instance = new WidgetClass( elem, options );
+ // make available via $().data('layoutname')
+ var jQuery = window.jQuery;
+ if ( jQuery ) {
+ jQuery.data( elem, namespace, instance );
+ }
+ }
+ });
+};
+
+// ----- ----- //
+
+return utils;
+
+}));
diff --git a/user/themes/labonneadresse/bower_components/foundation/.bower.json b/user/themes/labonneadresse/bower_components/foundation/.bower.json
new file mode 100644
index 0000000..f15210d
--- /dev/null
+++ b/user/themes/labonneadresse/bower_components/foundation/.bower.json
@@ -0,0 +1,32 @@
+{
+ "name": "foundation",
+ "main": [
+ "scss/foundation.scss",
+ "js/foundation.js"
+ ],
+ "ignore": [],
+ "dependencies": {
+ "jquery": ">= 2.1.0",
+ "modernizr": "2.8.3",
+ "fastclick": ">=0.6.11",
+ "jquery.cookie": "~1.4.0",
+ "jquery-placeholder": "~2.0.7"
+ },
+ "devDependencies": {
+ "jquery.autocomplete": "devbridge/jQuery-Autocomplete#1.2.9",
+ "lodash": "~2.4.1"
+ },
+ "private": true,
+ "homepage": "https://github.com/zurb/bower-foundation",
+ "version": "5.5.3",
+ "_release": "5.5.3",
+ "_resolution": {
+ "type": "version",
+ "tag": "5.5.3",
+ "commit": "b879716aa268e1f88fe43de98db2db4487af00ca"
+ },
+ "_source": "git://github.com/zurb/bower-foundation.git",
+ "_target": "~5.5.3",
+ "_originalSource": "foundation",
+ "_direct": true
+}
\ No newline at end of file
diff --git a/user/themes/labonneadresse/bower_components/foundation/LICENSE b/user/themes/labonneadresse/bower_components/foundation/LICENSE
new file mode 100644
index 0000000..1e12290
--- /dev/null
+++ b/user/themes/labonneadresse/bower_components/foundation/LICENSE
@@ -0,0 +1,22 @@
+Copyright (c) 2013-2015 ZURB, inc.
+
+MIT License
+
+Permission is hereby granted, free of charge, to any person obtaining
+a copy of this software and associated documentation files (the
+"Software"), to deal in the Software without restriction, including
+without limitation the rights to use, copy, modify, merge, publish,
+distribute, sublicense, and/or sell copies of the Software, and to
+permit persons to whom the Software is furnished to do so, subject to
+the following conditions:
+
+The above copyright notice and this permission notice shall be
+included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
diff --git a/user/themes/labonneadresse/bower_components/foundation/README.md b/user/themes/labonneadresse/bower_components/foundation/README.md
new file mode 100644
index 0000000..d5ef5fc
--- /dev/null
+++ b/user/themes/labonneadresse/bower_components/foundation/README.md
@@ -0,0 +1,46 @@
+# [Foundation](http://foundation.zurb.com)
+
+[](https://travis-ci.org/zurb/foundation)
+
+
+Foundation is the most advanced responsive front-end framework in the world. You can quickly prototype and build sites or apps that work on any kind of device with Foundation, which includes layout constructs (like a fully responsive grid), elements and best practices.
+
+To get started, check out
+
+
+## Quickstart
+
+To get going with Foundation you can:
+
+ * [Download the latest release](http://foundation.zurb.com/develop/download.html)
+ * [Install with Bower](http://bower.io): `bower install foundation`
+ * [Install with npm](http://npmjs.com): `npm install foundation-sites`
+
+## Documentation
+
+Foundation uses [Assemble.io](http://assemble.io) and [Grunt](http://gruntjs.com/) to generate its [documentation pages](http://foundation.zurb.com/docs). Documentation can also be run from your local computer:
+
+### View documentation locally
+
+You'll want to clone the Foundation repo first and install all the dependencies. You can do this using the following commands:
+
+```
+git clone git@github.com:zurb/foundation.git
+cd foundation
+npm install -g grunt-cli bower
+npm install
+bower install
+bundle install
+```
+
+Then just run `grunt build` and the documentation will be compiled:
+
+```
+foundation/
+├── dist/
+│ └── ...
+├────── docs/
+│ └── ...
+```
+
+Copyright (c) 2015 ZURB, inc.
diff --git a/user/themes/labonneadresse/bower_components/foundation/bower.json b/user/themes/labonneadresse/bower_components/foundation/bower.json
new file mode 100644
index 0000000..8586aa6
--- /dev/null
+++ b/user/themes/labonneadresse/bower_components/foundation/bower.json
@@ -0,0 +1,21 @@
+{
+ "name": "foundation",
+ "main": [
+ "scss/foundation.scss",
+ "js/foundation.js"
+ ],
+ "ignore": [
+ ],
+ "dependencies": {
+ "jquery": ">= 2.1.0",
+ "modernizr": "2.8.3",
+ "fastclick": ">=0.6.11",
+ "jquery.cookie": "~1.4.0",
+ "jquery-placeholder": "~2.0.7"
+ },
+ "devDependencies": {
+ "jquery.autocomplete": "devbridge/jQuery-Autocomplete#1.2.9",
+ "lodash": "~2.4.1"
+ },
+ "private": true
+}
diff --git a/user/themes/labonneadresse/bower_components/foundation/js/foundation.js b/user/themes/labonneadresse/bower_components/foundation/js/foundation.js
new file mode 100644
index 0000000..13a76a2
--- /dev/null
+++ b/user/themes/labonneadresse/bower_components/foundation/js/foundation.js
@@ -0,0 +1,6581 @@
+/*
+ * Foundation Responsive Library
+ * http://foundation.zurb.com
+ * Copyright 2015, ZURB
+ * Free to use under the MIT license.
+ * http://www.opensource.org/licenses/mit-license.php
+*/
+
+(function ($, window, document, undefined) {
+ 'use strict';
+
+ var header_helpers = function (class_array) {
+ var head = $('head');
+ head.prepend($.map(class_array, function (class_name) {
+ if (head.has('.' + class_name).length === 0) {
+ return '';
+ }
+ }));
+ };
+
+ header_helpers([
+ 'foundation-mq-small',
+ 'foundation-mq-small-only',
+ 'foundation-mq-medium',
+ 'foundation-mq-medium-only',
+ 'foundation-mq-large',
+ 'foundation-mq-large-only',
+ 'foundation-mq-xlarge',
+ 'foundation-mq-xlarge-only',
+ 'foundation-mq-xxlarge',
+ 'foundation-data-attribute-namespace']);
+
+ // Enable FastClick if present
+
+ $(function () {
+ if (typeof FastClick !== 'undefined') {
+ // Don't attach to body if undefined
+ if (typeof document.body !== 'undefined') {
+ FastClick.attach(document.body);
+ }
+ }
+ });
+
+ // private Fast Selector wrapper,
+ // returns jQuery object. Only use where
+ // getElementById is not available.
+ var S = function (selector, context) {
+ if (typeof selector === 'string') {
+ if (context) {
+ var cont;
+ if (context.jquery) {
+ cont = context[0];
+ if (!cont) {
+ return context;
+ }
+ } else {
+ cont = context;
+ }
+ return $(cont.querySelectorAll(selector));
+ }
+
+ return $(document.querySelectorAll(selector));
+ }
+
+ return $(selector, context);
+ };
+
+ // Namespace functions.
+
+ var attr_name = function (init) {
+ var arr = [];
+ if (!init) {
+ arr.push('data');
+ }
+ if (this.namespace.length > 0) {
+ arr.push(this.namespace);
+ }
+ arr.push(this.name);
+
+ return arr.join('-');
+ };
+
+ var add_namespace = function (str) {
+ var parts = str.split('-'),
+ i = parts.length,
+ arr = [];
+
+ while (i--) {
+ if (i !== 0) {
+ arr.push(parts[i]);
+ } else {
+ if (this.namespace.length > 0) {
+ arr.push(this.namespace, parts[i]);
+ } else {
+ arr.push(parts[i]);
+ }
+ }
+ }
+
+ return arr.reverse().join('-');
+ };
+
+ // Event binding and data-options updating.
+
+ var bindings = function (method, options) {
+ var self = this,
+ bind = function(){
+ var $this = S(this),
+ should_bind_events = !$this.data(self.attr_name(true) + '-init');
+ $this.data(self.attr_name(true) + '-init', $.extend({}, self.settings, (options || method), self.data_options($this)));
+
+ if (should_bind_events) {
+ self.events(this);
+ }
+ };
+
+ if (S(this.scope).is('[' + this.attr_name() +']')) {
+ bind.call(this.scope);
+ } else {
+ S('[' + this.attr_name() +']', this.scope).each(bind);
+ }
+ // # Patch to fix #5043 to move this *after* the if/else clause in order for Backbone and similar frameworks to have improved control over event binding and data-options updating.
+ if (typeof method === 'string') {
+ return this[method].call(this, options);
+ }
+
+ };
+
+ var single_image_loaded = function (image, callback) {
+ function loaded () {
+ callback(image[0]);
+ }
+
+ function bindLoad () {
+ this.one('load', loaded);
+
+ if (/MSIE (\d+\.\d+);/.test(navigator.userAgent)) {
+ var src = this.attr( 'src' ),
+ param = src.match( /\?/ ) ? '&' : '?';
+
+ param += 'random=' + (new Date()).getTime();
+ this.attr('src', src + param);
+ }
+ }
+
+ if (!image.attr('src')) {
+ loaded();
+ return;
+ }
+
+ if (image[0].complete || image[0].readyState === 4) {
+ loaded();
+ } else {
+ bindLoad.call(image);
+ }
+ };
+
+ /*! matchMedia() polyfill - Test a CSS media type/query in JS. Authors & copyright (c) 2012: Scott Jehl, Paul Irish, Nicholas Zakas, David Knight. Dual MIT/BSD license */
+
+ window.matchMedia || (window.matchMedia = function() {
+ "use strict";
+
+ // For browsers that support matchMedium api such as IE 9 and webkit
+ var styleMedia = (window.styleMedia || window.media);
+
+ // For those that don't support matchMedium
+ if (!styleMedia) {
+ var style = document.createElement('style'),
+ script = document.getElementsByTagName('script')[0],
+ info = null;
+
+ style.type = 'text/css';
+ style.id = 'matchmediajs-test';
+
+ script.parentNode.insertBefore(style, script);
+
+ // 'style.currentStyle' is used by IE <= 8 and 'window.getComputedStyle' for all other browsers
+ info = ('getComputedStyle' in window) && window.getComputedStyle(style, null) || style.currentStyle;
+
+ styleMedia = {
+ matchMedium: function(media) {
+ var text = '@media ' + media + '{ #matchmediajs-test { width: 1px; } }';
+
+ // 'style.styleSheet' is used by IE <= 8 and 'style.textContent' for all other browsers
+ if (style.styleSheet) {
+ style.styleSheet.cssText = text;
+ } else {
+ style.textContent = text;
+ }
+
+ // Test if media query is true or false
+ return info.width === '1px';
+ }
+ };
+ }
+
+ return function(media) {
+ return {
+ matches: styleMedia.matchMedium(media || 'all'),
+ media: media || 'all'
+ };
+ };
+ }());
+
+ /*
+ * jquery.requestAnimationFrame
+ * https://github.com/gnarf37/jquery-requestAnimationFrame
+ * Requires jQuery 1.8+
+ *
+ * Copyright (c) 2012 Corey Frang
+ * Licensed under the MIT license.
+ */
+
+ (function(jQuery) {
+
+
+ // requestAnimationFrame polyfill adapted from Erik Möller
+ // fixes from Paul Irish and Tino Zijdel
+ // http://paulirish.com/2011/requestanimationframe-for-smart-animating/
+ // http://my.opera.com/emoller/blog/2011/12/20/requestanimationframe-for-smart-er-animating
+
+ var animating,
+ lastTime = 0,
+ vendors = ['webkit', 'moz'],
+ requestAnimationFrame = window.requestAnimationFrame,
+ cancelAnimationFrame = window.cancelAnimationFrame,
+ jqueryFxAvailable = 'undefined' !== typeof jQuery.fx;
+
+ for (; lastTime < vendors.length && !requestAnimationFrame; lastTime++) {
+ requestAnimationFrame = window[ vendors[lastTime] + 'RequestAnimationFrame' ];
+ cancelAnimationFrame = cancelAnimationFrame ||
+ window[ vendors[lastTime] + 'CancelAnimationFrame' ] ||
+ window[ vendors[lastTime] + 'CancelRequestAnimationFrame' ];
+ }
+
+ function raf() {
+ if (animating) {
+ requestAnimationFrame(raf);
+
+ if (jqueryFxAvailable) {
+ jQuery.fx.tick();
+ }
+ }
+ }
+
+ if (requestAnimationFrame) {
+ // use rAF
+ window.requestAnimationFrame = requestAnimationFrame;
+ window.cancelAnimationFrame = cancelAnimationFrame;
+
+ if (jqueryFxAvailable) {
+ jQuery.fx.timer = function (timer) {
+ if (timer() && jQuery.timers.push(timer) && !animating) {
+ animating = true;
+ raf();
+ }
+ };
+
+ jQuery.fx.stop = function () {
+ animating = false;
+ };
+ }
+ } else {
+ // polyfill
+ window.requestAnimationFrame = function (callback) {
+ var currTime = new Date().getTime(),
+ timeToCall = Math.max(0, 16 - (currTime - lastTime)),
+ id = window.setTimeout(function () {
+ callback(currTime + timeToCall);
+ }, timeToCall);
+ lastTime = currTime + timeToCall;
+ return id;
+ };
+
+ window.cancelAnimationFrame = function (id) {
+ clearTimeout(id);
+ };
+
+ }
+
+ }( $ ));
+
+ function removeQuotes (string) {
+ if (typeof string === 'string' || string instanceof String) {
+ string = string.replace(/^['\\/"]+|(;\s?})+|['\\/"]+$/g, '');
+ }
+
+ return string;
+ }
+
+ function MediaQuery(selector) {
+ this.selector = selector;
+ this.query = '';
+ }
+
+ MediaQuery.prototype.toString = function () {
+ return this.query || (this.query = S(this.selector).css('font-family').replace(/^[\/\\'"]+|(;\s?})+|[\/\\'"]+$/g, ''));
+ };
+
+ window.Foundation = {
+ name : 'Foundation',
+
+ version : '5.5.3',
+
+ media_queries : {
+ 'small' : new MediaQuery('.foundation-mq-small'),
+ 'small-only' : new MediaQuery('.foundation-mq-small-only'),
+ 'medium' : new MediaQuery('.foundation-mq-medium'),
+ 'medium-only' : new MediaQuery('.foundation-mq-medium-only'),
+ 'large' : new MediaQuery('.foundation-mq-large'),
+ 'large-only' : new MediaQuery('.foundation-mq-large-only'),
+ 'xlarge' : new MediaQuery('.foundation-mq-xlarge'),
+ 'xlarge-only' : new MediaQuery('.foundation-mq-xlarge-only'),
+ 'xxlarge' : new MediaQuery('.foundation-mq-xxlarge')
+ },
+
+ stylesheet : $('').appendTo('head')[0].sheet,
+
+ global : {
+ namespace : undefined
+ },
+
+ init : function (scope, libraries, method, options, response) {
+ var args = [scope, method, options, response],
+ responses = [];
+
+ // check RTL
+ this.rtl = /rtl/i.test(S('html').attr('dir'));
+
+ // set foundation global scope
+ this.scope = scope || this.scope;
+
+ this.set_namespace();
+
+ if (libraries && typeof libraries === 'string' && !/reflow/i.test(libraries)) {
+ if (this.libs.hasOwnProperty(libraries)) {
+ responses.push(this.init_lib(libraries, args));
+ }
+ } else {
+ for (var lib in this.libs) {
+ responses.push(this.init_lib(lib, libraries));
+ }
+ }
+
+ S(window).load(function () {
+ S(window)
+ .trigger('resize.fndtn.clearing')
+ .trigger('resize.fndtn.dropdown')
+ .trigger('resize.fndtn.equalizer')
+ .trigger('resize.fndtn.interchange')
+ .trigger('resize.fndtn.joyride')
+ .trigger('resize.fndtn.magellan')
+ .trigger('resize.fndtn.topbar')
+ .trigger('resize.fndtn.slider');
+ });
+
+ return scope;
+ },
+
+ init_lib : function (lib, args) {
+ if (this.libs.hasOwnProperty(lib)) {
+ this.patch(this.libs[lib]);
+
+ if (args && args.hasOwnProperty(lib)) {
+ if (typeof this.libs[lib].settings !== 'undefined') {
+ $.extend(true, this.libs[lib].settings, args[lib]);
+ } else if (typeof this.libs[lib].defaults !== 'undefined') {
+ $.extend(true, this.libs[lib].defaults, args[lib]);
+ }
+ return this.libs[lib].init.apply(this.libs[lib], [this.scope, args[lib]]);
+ }
+
+ args = args instanceof Array ? args : new Array(args);
+ return this.libs[lib].init.apply(this.libs[lib], args);
+ }
+
+ return function () {};
+ },
+
+ patch : function (lib) {
+ lib.scope = this.scope;
+ lib.namespace = this.global.namespace;
+ lib.rtl = this.rtl;
+ lib['data_options'] = this.utils.data_options;
+ lib['attr_name'] = attr_name;
+ lib['add_namespace'] = add_namespace;
+ lib['bindings'] = bindings;
+ lib['S'] = this.utils.S;
+ },
+
+ inherit : function (scope, methods) {
+ var methods_arr = methods.split(' '),
+ i = methods_arr.length;
+
+ while (i--) {
+ if (this.utils.hasOwnProperty(methods_arr[i])) {
+ scope[methods_arr[i]] = this.utils[methods_arr[i]];
+ }
+ }
+ },
+
+ set_namespace : function () {
+
+ // Description:
+ // Don't bother reading the namespace out of the meta tag
+ // if the namespace has been set globally in javascript
+ //
+ // Example:
+ // Foundation.global.namespace = 'my-namespace';
+ // or make it an empty string:
+ // Foundation.global.namespace = '';
+ //
+ //
+
+ // If the namespace has not been set (is undefined), try to read it out of the meta element.
+ // Otherwise use the globally defined namespace, even if it's empty ('')
+ var namespace = ( this.global.namespace === undefined ) ? $('.foundation-data-attribute-namespace').css('font-family') : this.global.namespace;
+
+ // Finally, if the namsepace is either undefined or false, set it to an empty string.
+ // Otherwise use the namespace value.
+ this.global.namespace = ( namespace === undefined || /false/i.test(namespace) ) ? '' : namespace;
+ },
+
+ libs : {},
+
+ // methods that can be inherited in libraries
+ utils : {
+
+ // Description:
+ // Fast Selector wrapper returns jQuery object. Only use where getElementById
+ // is not available.
+ //
+ // Arguments:
+ // Selector (String): CSS selector describing the element(s) to be
+ // returned as a jQuery object.
+ //
+ // Scope (String): CSS selector describing the area to be searched. Default
+ // is document.
+ //
+ // Returns:
+ // Element (jQuery Object): jQuery object containing elements matching the
+ // selector within the scope.
+ S : S,
+
+ // Description:
+ // Executes a function a max of once every n milliseconds
+ //
+ // Arguments:
+ // Func (Function): Function to be throttled.
+ //
+ // Delay (Integer): Function execution threshold in milliseconds.
+ //
+ // Returns:
+ // Lazy_function (Function): Function with throttling applied.
+ throttle : function (func, delay) {
+ var timer = null;
+
+ return function () {
+ var context = this, args = arguments;
+
+ if (timer == null) {
+ timer = setTimeout(function () {
+ func.apply(context, args);
+ timer = null;
+ }, delay);
+ }
+ };
+ },
+
+ // Description:
+ // Executes a function when it stops being invoked for n seconds
+ // Modified version of _.debounce() http://underscorejs.org
+ //
+ // Arguments:
+ // Func (Function): Function to be debounced.
+ //
+ // Delay (Integer): Function execution threshold in milliseconds.
+ //
+ // Immediate (Bool): Whether the function should be called at the beginning
+ // of the delay instead of the end. Default is false.
+ //
+ // Returns:
+ // Lazy_function (Function): Function with debouncing applied.
+ debounce : function (func, delay, immediate) {
+ var timeout, result;
+ return function () {
+ var context = this, args = arguments;
+ var later = function () {
+ timeout = null;
+ if (!immediate) {
+ result = func.apply(context, args);
+ }
+ };
+ var callNow = immediate && !timeout;
+ clearTimeout(timeout);
+ timeout = setTimeout(later, delay);
+ if (callNow) {
+ result = func.apply(context, args);
+ }
+ return result;
+ };
+ },
+
+ // Description:
+ // Parses data-options attribute
+ //
+ // Arguments:
+ // El (jQuery Object): Element to be parsed.
+ //
+ // Returns:
+ // Options (Javascript Object): Contents of the element's data-options
+ // attribute.
+ data_options : function (el, data_attr_name) {
+ data_attr_name = data_attr_name || 'options';
+ var opts = {}, ii, p, opts_arr,
+ data_options = function (el) {
+ var namespace = Foundation.global.namespace;
+
+ if (namespace.length > 0) {
+ return el.data(namespace + '-' + data_attr_name);
+ }
+
+ return el.data(data_attr_name);
+ };
+
+ var cached_options = data_options(el);
+
+ if (typeof cached_options === 'object') {
+ return cached_options;
+ }
+
+ opts_arr = (cached_options || ':').split(';');
+ ii = opts_arr.length;
+
+ function isNumber (o) {
+ return !isNaN (o - 0) && o !== null && o !== '' && o !== false && o !== true;
+ }
+
+ function trim (str) {
+ if (typeof str === 'string') {
+ return $.trim(str);
+ }
+ return str;
+ }
+
+ while (ii--) {
+ p = opts_arr[ii].split(':');
+ p = [p[0], p.slice(1).join(':')];
+
+ if (/true/i.test(p[1])) {
+ p[1] = true;
+ }
+ if (/false/i.test(p[1])) {
+ p[1] = false;
+ }
+ if (isNumber(p[1])) {
+ if (p[1].indexOf('.') === -1) {
+ p[1] = parseInt(p[1], 10);
+ } else {
+ p[1] = parseFloat(p[1]);
+ }
+ }
+
+ if (p.length === 2 && p[0].length > 0) {
+ opts[trim(p[0])] = trim(p[1]);
+ }
+ }
+
+ return opts;
+ },
+
+ // Description:
+ // Adds JS-recognizable media queries
+ //
+ // Arguments:
+ // Media (String): Key string for the media query to be stored as in
+ // Foundation.media_queries
+ //
+ // Class (String): Class name for the generated tag
+ register_media : function (media, media_class) {
+ if (Foundation.media_queries[media] === undefined) {
+ $('head').append('');
+ Foundation.media_queries[media] = removeQuotes($('.' + media_class).css('font-family'));
+ }
+ },
+
+ // Description:
+ // Add custom CSS within a JS-defined media query
+ //
+ // Arguments:
+ // Rule (String): CSS rule to be appended to the document.
+ //
+ // Media (String): Optional media query string for the CSS rule to be
+ // nested under.
+ add_custom_rule : function (rule, media) {
+ if (media === undefined && Foundation.stylesheet) {
+ Foundation.stylesheet.insertRule(rule, Foundation.stylesheet.cssRules.length);
+ } else {
+ var query = Foundation.media_queries[media];
+
+ if (query !== undefined) {
+ Foundation.stylesheet.insertRule('@media ' +
+ Foundation.media_queries[media] + '{ ' + rule + ' }', Foundation.stylesheet.cssRules.length);
+ }
+ }
+ },
+
+ // Description:
+ // Performs a callback function when an image is fully loaded
+ //
+ // Arguments:
+ // Image (jQuery Object): Image(s) to check if loaded.
+ //
+ // Callback (Function): Function to execute when image is fully loaded.
+ image_loaded : function (images, callback) {
+ var self = this,
+ unloaded = images.length;
+
+ function pictures_has_height(images) {
+ var pictures_number = images.length;
+
+ for (var i = pictures_number - 1; i >= 0; i--) {
+ if(images.attr('height') === undefined) {
+ return false;
+ };
+ };
+
+ return true;
+ }
+
+ if (unloaded === 0 || pictures_has_height(images)) {
+ callback(images);
+ }
+
+ images.each(function () {
+ single_image_loaded(self.S(this), function () {
+ unloaded -= 1;
+ if (unloaded === 0) {
+ callback(images);
+ }
+ });
+ });
+ },
+
+ // Description:
+ // Returns a random, alphanumeric string
+ //
+ // Arguments:
+ // Length (Integer): Length of string to be generated. Defaults to random
+ // integer.
+ //
+ // Returns:
+ // Rand (String): Pseudo-random, alphanumeric string.
+ random_str : function () {
+ if (!this.fidx) {
+ this.fidx = 0;
+ }
+ this.prefix = this.prefix || [(this.name || 'F'), (+new Date).toString(36)].join('-');
+
+ return this.prefix + (this.fidx++).toString(36);
+ },
+
+ // Description:
+ // Helper for window.matchMedia
+ //
+ // Arguments:
+ // mq (String): Media query
+ //
+ // Returns:
+ // (Boolean): Whether the media query passes or not
+ match : function (mq) {
+ return window.matchMedia(mq).matches;
+ },
+
+ // Description:
+ // Helpers for checking Foundation default media queries with JS
+ //
+ // Returns:
+ // (Boolean): Whether the media query passes or not
+
+ is_small_up : function () {
+ return this.match(Foundation.media_queries.small);
+ },
+
+ is_medium_up : function () {
+ return this.match(Foundation.media_queries.medium);
+ },
+
+ is_large_up : function () {
+ return this.match(Foundation.media_queries.large);
+ },
+
+ is_xlarge_up : function () {
+ return this.match(Foundation.media_queries.xlarge);
+ },
+
+ is_xxlarge_up : function () {
+ return this.match(Foundation.media_queries.xxlarge);
+ },
+
+ is_small_only : function () {
+ return !this.is_medium_up() && !this.is_large_up() && !this.is_xlarge_up() && !this.is_xxlarge_up();
+ },
+
+ is_medium_only : function () {
+ return this.is_medium_up() && !this.is_large_up() && !this.is_xlarge_up() && !this.is_xxlarge_up();
+ },
+
+ is_large_only : function () {
+ return this.is_medium_up() && this.is_large_up() && !this.is_xlarge_up() && !this.is_xxlarge_up();
+ },
+
+ is_xlarge_only : function () {
+ return this.is_medium_up() && this.is_large_up() && this.is_xlarge_up() && !this.is_xxlarge_up();
+ },
+
+ is_xxlarge_only : function () {
+ return this.is_medium_up() && this.is_large_up() && this.is_xlarge_up() && this.is_xxlarge_up();
+ }
+ }
+ };
+
+ $.fn.foundation = function () {
+ var args = Array.prototype.slice.call(arguments, 0);
+
+ return this.each(function () {
+ Foundation.init.apply(Foundation, [this].concat(args));
+ return this;
+ });
+ };
+
+}(jQuery, window, window.document));
+
+;(function ($, window, document, undefined) {
+ 'use strict';
+
+ Foundation.libs.abide = {
+ name : 'abide',
+
+ version : '5.5.3',
+
+ settings : {
+ live_validate : true, // validate the form as you go
+ validate_on_blur : true, // validate whenever you focus/blur on an input field
+ // validate_on: 'tab', // tab (when user tabs between fields), change (input changes), manual (call custom events)
+
+ focus_on_invalid : true, // automatically bring the focus to an invalid input field
+ error_labels : true, // labels with a for="inputId" will receive an `error` class
+ error_class : 'error', // labels with a for="inputId" will receive an `error` class
+ // the amount of time Abide will take before it validates the form (in ms).
+ // smaller time will result in faster validation
+ timeout : 1000,
+ patterns : {
+ alpha : /^[a-zA-Z]+$/,
+ alpha_numeric : /^[a-zA-Z0-9]+$/,
+ integer : /^[-+]?\d+$/,
+ number : /^[-+]?\d*(?:[\.\,]\d+)?$/,
+
+ // amex, visa, diners
+ card : /^(?:4[0-9]{12}(?:[0-9]{3})?|5[1-5][0-9]{14}|6(?:011|5[0-9][0-9])[0-9]{12}|3[47][0-9]{13}|3(?:0[0-5]|[68][0-9])[0-9]{11}|(?:2131|1800|35\d{3})\d{11})$/,
+ cvv : /^([0-9]){3,4}$/,
+
+ // http://www.whatwg.org/specs/web-apps/current-work/multipage/states-of-the-type-attribute.html#valid-e-mail-address
+ email : /^[a-zA-Z0-9.!#$%&'*+\/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+$/,
+
+ // http://blogs.lse.ac.uk/lti/2008/04/23/a-regular-expression-to-match-any-url/
+ url: /^(https?|ftp|file|ssh):\/\/([-;:&=\+\$,\w]+@{1})?([-A-Za-z0-9\.]+)+:?(\d+)?((\/[-\+~%\/\.\w]+)?\??([-\+=&;%@\.\w]+)?#?([\w]+)?)?/,
+ // abc.de
+ domain : /^([a-zA-Z0-9]([a-zA-Z0-9\-]{0,61}[a-zA-Z0-9])?\.)+[a-zA-Z]{2,8}$/,
+
+ datetime : /^([0-2][0-9]{3})\-([0-1][0-9])\-([0-3][0-9])T([0-5][0-9])\:([0-5][0-9])\:([0-5][0-9])(Z|([\-\+]([0-1][0-9])\:00))$/,
+ // YYYY-MM-DD
+ date : /(?:19|20)[0-9]{2}-(?:(?:0[1-9]|1[0-2])-(?:0[1-9]|1[0-9]|2[0-9])|(?:(?!02)(?:0[1-9]|1[0-2])-(?:30))|(?:(?:0[13578]|1[02])-31))$/,
+ // HH:MM:SS
+ time : /^(0[0-9]|1[0-9]|2[0-3])(:[0-5][0-9]){2}$/,
+ dateISO : /^\d{4}[\/\-]\d{1,2}[\/\-]\d{1,2}$/,
+ // MM/DD/YYYY
+ month_day_year : /^(0[1-9]|1[012])[- \/.](0[1-9]|[12][0-9]|3[01])[- \/.]\d{4}$/,
+ // DD/MM/YYYY
+ day_month_year : /^(0[1-9]|[12][0-9]|3[01])[- \/.](0[1-9]|1[012])[- \/.]\d{4}$/,
+
+ // #FFF or #FFFFFF
+ color : /^#?([a-fA-F0-9]{6}|[a-fA-F0-9]{3})$/
+ },
+ validators : {
+ equalTo : function (el, required, parent) {
+ var from = document.getElementById(el.getAttribute(this.add_namespace('data-equalto'))).value,
+ to = el.value,
+ valid = (from === to);
+
+ return valid;
+ }
+ }
+ },
+
+ timer : null,
+
+ init : function (scope, method, options) {
+ this.bindings(method, options);
+ },
+
+ events : function (scope) {
+ var self = this,
+ form = self.S(scope).attr('novalidate', 'novalidate'),
+ settings = form.data(this.attr_name(true) + '-init') || {};
+
+ this.invalid_attr = this.add_namespace('data-invalid');
+
+ function validate(originalSelf, e) {
+ clearTimeout(self.timer);
+ self.timer = setTimeout(function () {
+ self.validate([originalSelf], e);
+ }.bind(originalSelf), settings.timeout);
+ }
+
+ form
+ .off('.abide')
+ .on('submit.fndtn.abide', function (e) {
+ var is_ajax = /ajax/i.test(self.S(this).attr(self.attr_name()));
+ return self.validate(self.S(this).find('input, textarea, select').not(":hidden, [data-abide-ignore]").get(), e, is_ajax);
+ })
+ .on('validate.fndtn.abide', function (e) {
+ if (settings.validate_on === 'manual') {
+ self.validate([e.target], e);
+ }
+ })
+ .on('reset', function (e) {
+ return self.reset($(this), e);
+ })
+ .find('input, textarea, select').not(":hidden, [data-abide-ignore]")
+ .off('.abide')
+ .on('blur.fndtn.abide change.fndtn.abide', function (e) {
+ var id = this.getAttribute('id'),
+ eqTo = form.find('[data-equalto="'+ id +'"]');
+ // old settings fallback
+ // will be deprecated with F6 release
+ if (settings.validate_on_blur && settings.validate_on_blur === true) {
+ validate(this, e);
+ }
+ // checks if there is an equalTo equivalent related by id
+ if(typeof eqTo.get(0) !== "undefined" && eqTo.val().length){
+ validate(eqTo.get(0),e);
+ }
+ // new settings combining validate options into one setting
+ if (settings.validate_on === 'change') {
+ validate(this, e);
+ }
+ })
+ .on('keydown.fndtn.abide', function (e) {
+ var id = this.getAttribute('id'),
+ eqTo = form.find('[data-equalto="'+ id +'"]');
+ // old settings fallback
+ // will be deprecated with F6 release
+ if (settings.live_validate && settings.live_validate === true && e.which != 9) {
+ validate(this, e);
+ }
+ // checks if there is an equalTo equivalent related by id
+ if(typeof eqTo.get(0) !== "undefined" && eqTo.val().length){
+ validate(eqTo.get(0),e);
+ }
+ // new settings combining validate options into one setting
+ if (settings.validate_on === 'tab' && e.which === 9) {
+ validate(this, e);
+ }
+ else if (settings.validate_on === 'change') {
+ validate(this, e);
+ }
+ })
+ .on('focus', function (e) {
+ if (navigator.userAgent.match(/iPad|iPhone|Android|BlackBerry|Windows Phone|webOS/i)) {
+ $('html, body').animate({
+ scrollTop: $(e.target).offset().top
+ }, 100);
+ }
+ });
+ },
+
+ reset : function (form, e) {
+ var self = this;
+ form.removeAttr(self.invalid_attr);
+
+ $('[' + self.invalid_attr + ']', form).removeAttr(self.invalid_attr);
+ $('.' + self.settings.error_class, form).not('small').removeClass(self.settings.error_class);
+ $(':input', form).not(':button, :submit, :reset, :hidden, [data-abide-ignore]').val('').removeAttr(self.invalid_attr);
+ },
+
+ validate : function (els, e, is_ajax) {
+ var validations = this.parse_patterns(els),
+ validation_count = validations.length,
+ form = this.S(els[0]).closest('form'),
+ submit_event = /submit/.test(e.type);
+
+ // Has to count up to make sure the focus gets applied to the top error
+ for (var i = 0; i < validation_count; i++) {
+ if (!validations[i] && (submit_event || is_ajax)) {
+ if (this.settings.focus_on_invalid) {
+ els[i].focus();
+ }
+ form.trigger('invalid.fndtn.abide');
+ this.S(els[i]).closest('form').attr(this.invalid_attr, '');
+ return false;
+ }
+ }
+
+ if (submit_event || is_ajax) {
+ form.trigger('valid.fndtn.abide');
+ }
+
+ form.removeAttr(this.invalid_attr);
+
+ if (is_ajax) {
+ return false;
+ }
+
+ return true;
+ },
+
+ parse_patterns : function (els) {
+ var i = els.length,
+ el_patterns = [];
+
+ while (i--) {
+ el_patterns.push(this.pattern(els[i]));
+ }
+
+ return this.check_validation_and_apply_styles(el_patterns);
+ },
+
+ pattern : function (el) {
+ var type = el.getAttribute('type'),
+ required = typeof el.getAttribute('required') === 'string';
+
+ var pattern = el.getAttribute('pattern') || '';
+
+ if (this.settings.patterns.hasOwnProperty(pattern) && pattern.length > 0) {
+ return [el, this.settings.patterns[pattern], required];
+ } else if (pattern.length > 0) {
+ return [el, new RegExp(pattern), required];
+ }
+
+ if (this.settings.patterns.hasOwnProperty(type)) {
+ return [el, this.settings.patterns[type], required];
+ }
+
+ pattern = /.*/;
+
+ return [el, pattern, required];
+ },
+
+ // TODO: Break this up into smaller methods, getting hard to read.
+ check_validation_and_apply_styles : function (el_patterns) {
+ var i = el_patterns.length,
+ validations = [];
+ if (i == 0) {
+ return validations;
+ }
+ var form = this.S(el_patterns[0][0]).closest('[data-' + this.attr_name(true) + ']'),
+ settings = form.data(this.attr_name(true) + '-init') || {};
+ while (i--) {
+ var el = el_patterns[i][0],
+ required = el_patterns[i][2],
+ value = el.value.trim(),
+ direct_parent = this.S(el).parent(),
+ validator = el.getAttribute(this.add_namespace('data-abide-validator')),
+ is_radio = el.type === 'radio',
+ is_checkbox = el.type === 'checkbox',
+ label = this.S('label[for="' + el.getAttribute('id') + '"]'),
+ valid_length = (required) ? (el.value.length > 0) : true,
+ el_validations = [];
+
+ var parent, valid;
+
+ // support old way to do equalTo validations
+ if (el.getAttribute(this.add_namespace('data-equalto'))) { validator = 'equalTo' }
+
+ if (!direct_parent.is('label')) {
+ parent = direct_parent;
+ } else {
+ parent = direct_parent.parent();
+ }
+
+ if (is_radio && required) {
+ el_validations.push(this.valid_radio(el, required));
+ } else if (is_checkbox && required) {
+ el_validations.push(this.valid_checkbox(el, required));
+
+ } else if (validator) {
+ // Validate using each of the specified (space-delimited) validators.
+ var validators = validator.split(' ');
+ var last_valid = true, all_valid = true;
+ for (var iv = 0; iv < validators.length; iv++) {
+ valid = this.settings.validators[validators[iv]].apply(this, [el, required, parent])
+ el_validations.push(valid);
+ all_valid = valid && last_valid;
+ last_valid = valid;
+ }
+ if (all_valid) {
+ this.S(el).removeAttr(this.invalid_attr);
+ parent.removeClass('error');
+ if (label.length > 0 && this.settings.error_labels) {
+ label.removeClass(this.settings.error_class).removeAttr('role');
+ }
+ $(el).triggerHandler('valid');
+ } else {
+ this.S(el).attr(this.invalid_attr, '');
+ parent.addClass('error');
+ if (label.length > 0 && this.settings.error_labels) {
+ label.addClass(this.settings.error_class).attr('role', 'alert');
+ }
+ $(el).triggerHandler('invalid');
+ }
+ } else {
+
+ if (el_patterns[i][1].test(value) && valid_length ||
+ !required && el.value.length < 1 || $(el).attr('disabled')) {
+ el_validations.push(true);
+ } else {
+ el_validations.push(false);
+ }
+
+ el_validations = [el_validations.every(function (valid) {return valid;})];
+ if (el_validations[0]) {
+ this.S(el).removeAttr(this.invalid_attr);
+ el.setAttribute('aria-invalid', 'false');
+ el.removeAttribute('aria-describedby');
+ parent.removeClass(this.settings.error_class);
+ if (label.length > 0 && this.settings.error_labels) {
+ label.removeClass(this.settings.error_class).removeAttr('role');
+ }
+ $(el).triggerHandler('valid');
+ } else {
+ this.S(el).attr(this.invalid_attr, '');
+ el.setAttribute('aria-invalid', 'true');
+
+ // Try to find the error associated with the input
+ var errorElem = parent.find('small.' + this.settings.error_class, 'span.' + this.settings.error_class);
+ var errorID = errorElem.length > 0 ? errorElem[0].id : '';
+ if (errorID.length > 0) {
+ el.setAttribute('aria-describedby', errorID);
+ }
+
+ // el.setAttribute('aria-describedby', $(el).find('.error')[0].id);
+ parent.addClass(this.settings.error_class);
+ if (label.length > 0 && this.settings.error_labels) {
+ label.addClass(this.settings.error_class).attr('role', 'alert');
+ }
+ $(el).triggerHandler('invalid');
+ }
+ }
+ validations = validations.concat(el_validations);
+ }
+
+ return validations;
+ },
+
+ valid_checkbox : function (el, required) {
+ var el = this.S(el),
+ valid = (el.is(':checked') || !required || el.get(0).getAttribute('disabled'));
+
+ if (valid) {
+ el.removeAttr(this.invalid_attr).parent().removeClass(this.settings.error_class);
+ $(el).triggerHandler('valid');
+ } else {
+ el.attr(this.invalid_attr, '').parent().addClass(this.settings.error_class);
+ $(el).triggerHandler('invalid');
+ }
+
+ return valid;
+ },
+
+ valid_radio : function (el, required) {
+ var name = el.getAttribute('name'),
+ group = this.S(el).closest('[data-' + this.attr_name(true) + ']').find("[name='" + name + "']"),
+ count = group.length,
+ valid = false,
+ disabled = false;
+
+ // Has to count up to make sure the focus gets applied to the top error
+ for (var i=0; i < count; i++) {
+ if( group[i].getAttribute('disabled') ){
+ disabled=true;
+ valid=true;
+ } else {
+ if (group[i].checked){
+ valid = true;
+ } else {
+ if( disabled ){
+ valid = false;
+ }
+ }
+ }
+ }
+
+ // Has to count up to make sure the focus gets applied to the top error
+ for (var i = 0; i < count; i++) {
+ if (valid) {
+ this.S(group[i]).removeAttr(this.invalid_attr).parent().removeClass(this.settings.error_class);
+ $(group[i]).triggerHandler('valid');
+ } else {
+ this.S(group[i]).attr(this.invalid_attr, '').parent().addClass(this.settings.error_class);
+ $(group[i]).triggerHandler('invalid');
+ }
+ }
+
+ return valid;
+ },
+
+ valid_equal : function (el, required, parent) {
+ var from = document.getElementById(el.getAttribute(this.add_namespace('data-equalto'))).value,
+ to = el.value,
+ valid = (from === to);
+
+ if (valid) {
+ this.S(el).removeAttr(this.invalid_attr);
+ parent.removeClass(this.settings.error_class);
+ if (label.length > 0 && settings.error_labels) {
+ label.removeClass(this.settings.error_class);
+ }
+ } else {
+ this.S(el).attr(this.invalid_attr, '');
+ parent.addClass(this.settings.error_class);
+ if (label.length > 0 && settings.error_labels) {
+ label.addClass(this.settings.error_class);
+ }
+ }
+
+ return valid;
+ },
+
+ valid_oneof : function (el, required, parent, doNotValidateOthers) {
+ var el = this.S(el),
+ others = this.S('[' + this.add_namespace('data-oneof') + ']'),
+ valid = others.filter(':checked').length > 0;
+
+ if (valid) {
+ el.removeAttr(this.invalid_attr).parent().removeClass(this.settings.error_class);
+ } else {
+ el.attr(this.invalid_attr, '').parent().addClass(this.settings.error_class);
+ }
+
+ if (!doNotValidateOthers) {
+ var _this = this;
+ others.each(function () {
+ _this.valid_oneof.call(_this, this, null, null, true);
+ });
+ }
+
+ return valid;
+ },
+
+ reflow : function(scope, options) {
+ var self = this,
+ form = self.S('[' + this.attr_name() + ']').attr('novalidate', 'novalidate');
+ self.S(form).each(function (idx, el) {
+ self.events(el);
+ });
+ }
+ };
+}(jQuery, window, window.document));
+
+;(function ($, window, document, undefined) {
+ 'use strict';
+
+ Foundation.libs.accordion = {
+ name : 'accordion',
+
+ version : '5.5.3',
+
+ settings : {
+ content_class : 'content',
+ active_class : 'active',
+ multi_expand : false,
+ toggleable : true,
+ callback : function () {}
+ },
+
+ init : function (scope, method, options) {
+ this.bindings(method, options);
+ },
+
+ events : function (instance) {
+ var self = this;
+ var S = this.S;
+ self.create(this.S(instance));
+
+ S(this.scope)
+ .off('.fndtn.accordion')
+ .on('click.fndtn.accordion', '[' + this.attr_name() + '] > dd > a, [' + this.attr_name() + '] > li > a', function (e) {
+ var accordion = S(this).closest('[' + self.attr_name() + ']'),
+ groupSelector = self.attr_name() + '=' + accordion.attr(self.attr_name()),
+ settings = accordion.data(self.attr_name(true) + '-init') || self.settings,
+ target = S('#' + this.href.split('#')[1]),
+ aunts = $('> dd, > li', accordion),
+ siblings = aunts.children('.' + settings.content_class),
+ active_content = siblings.filter('.' + settings.active_class);
+
+ e.preventDefault();
+
+ if (accordion.attr(self.attr_name())) {
+ siblings = siblings.add('[' + groupSelector + '] dd > ' + '.' + settings.content_class + ', [' + groupSelector + '] li > ' + '.' + settings.content_class);
+ aunts = aunts.add('[' + groupSelector + '] dd, [' + groupSelector + '] li');
+ }
+
+ if (settings.toggleable && target.is(active_content)) {
+ target.parent('dd, li').toggleClass(settings.active_class, false);
+ target.toggleClass(settings.active_class, false);
+ S(this).attr('aria-expanded', function(i, attr){
+ return attr === 'true' ? 'false' : 'true';
+ });
+ settings.callback(target);
+ target.triggerHandler('toggled', [accordion]);
+ accordion.triggerHandler('toggled', [target]);
+ return;
+ }
+
+ if (!settings.multi_expand) {
+ siblings.removeClass(settings.active_class);
+ aunts.removeClass(settings.active_class);
+ aunts.children('a').attr('aria-expanded','false');
+ }
+
+ target.addClass(settings.active_class).parent().addClass(settings.active_class);
+ settings.callback(target);
+ target.triggerHandler('toggled', [accordion]);
+ accordion.triggerHandler('toggled', [target]);
+ S(this).attr('aria-expanded','true');
+ });
+ },
+
+ create: function($instance) {
+ var self = this,
+ accordion = $instance,
+ aunts = $('> .accordion-navigation', accordion),
+ settings = accordion.data(self.attr_name(true) + '-init') || self.settings;
+
+ aunts.children('a').attr('aria-expanded','false');
+ aunts.has('.' + settings.content_class + '.' + settings.active_class).addClass(settings.active_class).children('a').attr('aria-expanded','true');
+
+ if (settings.multi_expand) {
+ $instance.attr('aria-multiselectable','true');
+ }
+ },
+
+ toggle : function(options) {
+ var options = typeof options !== 'undefined' ? options : {};
+ var selector = typeof options.selector !== 'undefined' ? options.selector : '';
+ var toggle_state = typeof options.toggle_state !== 'undefined' ? options.toggle_state : '';
+ var $accordion = typeof options.$accordion !== 'undefined' ? options.$accordion : this.S(this.scope).closest('[' + this.attr_name() + ']');
+
+ var $items = $accordion.find('> dd' + selector + ', > li' + selector);
+ if ( $items.length < 1 ) {
+ if ( window.console ) {
+ console.error('Selection not found.', selector);
+ }
+ return false;
+ }
+
+ var S = this.S;
+ var active_class = this.settings.active_class;
+ $items.each(function() {
+ var $item = S(this);
+ var is_active = $item.hasClass(active_class);
+ if ( ( is_active && toggle_state === 'close' ) || ( !is_active && toggle_state === 'open' ) || toggle_state === '' ) {
+ $item.find('> a').trigger('click.fndtn.accordion');
+ }
+ });
+ },
+
+ open : function(options) {
+ var options = typeof options !== 'undefined' ? options : {};
+ options.toggle_state = 'open';
+ this.toggle(options);
+ },
+
+ close : function(options) {
+ var options = typeof options !== 'undefined' ? options : {};
+ options.toggle_state = 'close';
+ this.toggle(options);
+ },
+
+ off : function () {},
+
+ reflow : function () {}
+ };
+}(jQuery, window, window.document));
+
+;(function ($, window, document, undefined) {
+ 'use strict';
+
+ Foundation.libs.alert = {
+ name : 'alert',
+
+ version : '5.5.3',
+
+ settings : {
+ callback : function () {}
+ },
+
+ init : function (scope, method, options) {
+ this.bindings(method, options);
+ },
+
+ events : function () {
+ var self = this,
+ S = this.S;
+
+ $(this.scope).off('.alert').on('click.fndtn.alert', '[' + this.attr_name() + '] .close', function (e) {
+ var alertBox = S(this).closest('[' + self.attr_name() + ']'),
+ settings = alertBox.data(self.attr_name(true) + '-init') || self.settings;
+
+ e.preventDefault();
+ if (Modernizr.csstransitions) {
+ alertBox.addClass('alert-close');
+ alertBox.on('transitionend webkitTransitionEnd oTransitionEnd', function (e) {
+ S(this).trigger('close.fndtn.alert').remove();
+ settings.callback();
+ });
+ } else {
+ alertBox.fadeOut(300, function () {
+ S(this).trigger('close.fndtn.alert').remove();
+ settings.callback();
+ });
+ }
+ });
+ },
+
+ reflow : function () {}
+ };
+}(jQuery, window, window.document));
+
+;(function ($, window, document, undefined) {
+ 'use strict';
+
+ Foundation.libs.clearing = {
+ name : 'clearing',
+
+ version : '5.5.3',
+
+ settings : {
+ templates : {
+ viewing : '×' +
+ '
' +
+ '' +
+ '
' +
+ '' +
+ ''
+ },
+
+ // comma delimited list of selectors that, on click, will close clearing,
+ // add 'div.clearing-blackout, div.visible-img' to close on background click
+ close_selectors : '.clearing-close, div.clearing-blackout',
+
+ // Default to the entire li element.
+ open_selectors : '',
+
+ // Image will be skipped in carousel.
+ skip_selector : '',
+
+ touch_label : '',
+
+ // event initializer and locks
+ init : false,
+ locked : false
+ },
+
+ init : function (scope, method, options) {
+ var self = this;
+ Foundation.inherit(this, 'throttle image_loaded');
+
+ this.bindings(method, options);
+
+ if (self.S(this.scope).is('[' + this.attr_name() + ']')) {
+ this.assemble(self.S('li', this.scope));
+ } else {
+ self.S('[' + this.attr_name() + ']', this.scope).each(function () {
+ self.assemble(self.S('li', this));
+ });
+ }
+ },
+
+ events : function (scope) {
+ var self = this,
+ S = self.S,
+ $scroll_container = $('.scroll-container');
+
+ if ($scroll_container.length > 0) {
+ this.scope = $scroll_container;
+ }
+
+ S(this.scope)
+ .off('.clearing')
+ .on('click.fndtn.clearing', 'ul[' + this.attr_name() + '] li ' + this.settings.open_selectors,
+ function (e, current, target) {
+ var current = current || S(this),
+ target = target || current,
+ next = current.next('li'),
+ settings = current.closest('[' + self.attr_name() + ']').data(self.attr_name(true) + '-init'),
+ image = S(e.target);
+
+ e.preventDefault();
+
+ if (!settings) {
+ self.init();
+ settings = current.closest('[' + self.attr_name() + ']').data(self.attr_name(true) + '-init');
+ }
+
+ // if clearing is open and the current image is
+ // clicked, go to the next image in sequence
+ if (target.hasClass('visible') &&
+ current[0] === target[0] &&
+ next.length > 0 && self.is_open(current)) {
+ target = next;
+ image = S('img', target);
+ }
+
+ // set current and target to the clicked li if not otherwise defined.
+ self.open(image, current, target);
+ self.update_paddles(target);
+ })
+
+ .on('click.fndtn.clearing', '.clearing-main-next',
+ function (e) { self.nav(e, 'next') })
+ .on('click.fndtn.clearing', '.clearing-main-prev',
+ function (e) { self.nav(e, 'prev') })
+ .on('click.fndtn.clearing', this.settings.close_selectors,
+ function (e) { Foundation.libs.clearing.close(e, this) });
+
+ $(document).on('keydown.fndtn.clearing',
+ function (e) { self.keydown(e) });
+
+ S(window).off('.clearing').on('resize.fndtn.clearing',
+ function () { self.resize() });
+
+ this.swipe_events(scope);
+ },
+
+ swipe_events : function (scope) {
+ var self = this,
+ S = self.S;
+
+ S(this.scope)
+ .on('touchstart.fndtn.clearing', '.visible-img', function (e) {
+ if (!e.touches) { e = e.originalEvent; }
+ var data = {
+ start_page_x : e.touches[0].pageX,
+ start_page_y : e.touches[0].pageY,
+ start_time : (new Date()).getTime(),
+ delta_x : 0,
+ is_scrolling : undefined
+ };
+
+ S(this).data('swipe-transition', data);
+ e.stopPropagation();
+ })
+ .on('touchmove.fndtn.clearing', '.visible-img', function (e) {
+ if (!e.touches) {
+ e = e.originalEvent;
+ }
+ // Ignore pinch/zoom events
+ if (e.touches.length > 1 || e.scale && e.scale !== 1) {
+ return;
+ }
+
+ var data = S(this).data('swipe-transition');
+
+ if (typeof data === 'undefined') {
+ data = {};
+ }
+
+ data.delta_x = e.touches[0].pageX - data.start_page_x;
+
+ if (Foundation.rtl) {
+ data.delta_x = -data.delta_x;
+ }
+
+ if (typeof data.is_scrolling === 'undefined') {
+ data.is_scrolling = !!( data.is_scrolling || Math.abs(data.delta_x) < Math.abs(e.touches[0].pageY - data.start_page_y) );
+ }
+
+ if (!data.is_scrolling && !data.active) {
+ e.preventDefault();
+ var direction = (data.delta_x < 0) ? 'next' : 'prev';
+ data.active = true;
+ self.nav(e, direction);
+ }
+ })
+ .on('touchend.fndtn.clearing', '.visible-img', function (e) {
+ S(this).data('swipe-transition', {});
+ e.stopPropagation();
+ });
+ },
+
+ assemble : function ($li) {
+ var $el = $li.parent();
+
+ if ($el.parent().hasClass('carousel')) {
+ return;
+ }
+
+ $el.after('');
+
+ var grid = $el.detach(),
+ grid_outerHTML = '';
+
+ if (grid[0] == null) {
+ return;
+ } else {
+ grid_outerHTML = grid[0].outerHTML;
+ }
+
+ var holder = this.S('#foundationClearingHolder'),
+ settings = $el.data(this.attr_name(true) + '-init'),
+ data = {
+ grid : '