{"id":167,"date":"2013-04-08T02:10:40","date_gmt":"2013-04-08T00:10:40","guid":{"rendered":"http:\/\/alexis.nomine.fr\/en\/?p=167"},"modified":"2013-04-08T05:59:54","modified_gmt":"2013-04-08T03:59:54","slug":"responsive-css3-jquery-switching-accordion-tabs","status":"publish","type":"post","link":"https:\/\/alexis.nomine.fr\/en\/blog\/2013\/04\/08\/responsive-css3-jquery-switching-accordion-tabs\/","title":{"rendered":"A responsive experiment with CSS3 and jQuery: switching between accordion and tabs display"},"content":{"rendered":"<p>I've been playing lately with responsive design, trying to present data the best way depending on the screen size available. Most of the time, CSS3 media queries will be enough. However, some designs will also require a bit of jQuery. Is it possible to make it responsive as well? That's what I intented in this experiment.<\/p>\n<p>For the purpose of this example, I have a list of 10 well known stars with a small bio. I want to display it as an accordion on smaller screens, and as vertical tabs on the bigger ones.<\/p>\n<p>If you're too impatient to reed the whole article, have a look at the <a class=\"button white\" href=\"http:\/\/dev.nomine.fr\/css3-jquery-experiment\/\" title=\"Demo: A responsive experiment with CSS3 and jQuery\">Demo<\/a><\/p>\n<p><!--more--><\/p>\n<h2>The markup<\/h2>\n<p>Here is what the markup looks like. Pretty simple, with the title of my page, the navigation for the tabs view, and the profiles:<\/p>\n<pre class=\"language-markup\"><code>&lt;h1&gt;Star Profiles&lt;\/h1&gt;\r\n&lt;nav&gt;\r\n &lt;ul&gt;\r\n  &lt;li&gt;&lt;a href=&quot;#bard-tipp&quot;&gt;Bard Tipp&lt;\/a&gt;&lt;\/li&gt;\r\n  &lt;li&gt;&lt;a href=&quot;#neolardo-picadrio&quot;&gt;Neolardo Picadrio&lt;\/a&gt;&lt;\/li&gt;\r\n  [...]\r\n &lt;\/ul&gt;\r\n&lt;\/nav&gt;\r\n&lt;div id=&quot;profiles&quot;&gt;\r\n &lt;article id=&quot;bard-tipp&quot;&gt;\r\n  &lt;h1&gt;Bard Tipp&lt;\/h1&gt;\r\n  &lt;div class=&quot;description&quot;&gt;\r\n   &lt;p&gt;Fusce et justo purus, at vestibulum ligula. Sed nisi ante, volutpat vel sollicitudin vitae, pretium in tortor. Aliquam id massa nulla, in viverra risus. Morbi vestibulum sapien nisl, at consequat purus. Proin purus nunc, bibendum sit amet aliquam a, condimentum quis elit.&lt;\/p&gt;\r\n  &lt;\/div&gt;\r\n &lt;\/article&gt;\r\n &lt;article id=&quot;neolardo-picadrio&quot;&gt;\r\n  &lt;h1&gt;Neolardo Picadrio&lt;\/h1&gt;\r\n  &lt;div class=&quot;description&quot;&gt;\r\n   &lt;p&gt;Fusce et justo purus, at vestibulum ligula. Sed nisi ante, volutpat vel sollicitudin vitae, pretium in tortor. Aliquam id massa nulla, in viverra risus. Morbi vestibulum sapien nisl, at consequat purus. Proin purus nunc, bibendum sit amet aliquam a, condimentum quis elit.&lt;\/p&gt;\r\n  &lt;\/div&gt;\r\n &lt;\/article&gt;\r\n [...]\r\n&lt;\/div&gt;<\/code><\/pre>\n<h2>The style<\/h2>\n<p>I'll design for mobile first, so let's add a bit of styling for the accordion:<\/p>\n<pre class=\"language-css\"><code>body{\r\n\tmargin: 0;\r\n\tpadding: 0;\r\n}\r\n\r\n\/* the accordion handles *\/\r\n#profiles h1{\r\n\tborder-bottom: 1px solid #999;\r\n\tbackground-color: #ddd;\r\n\tmargin: 0;\r\n\tpadding: 0 1em;\r\n\tfont-size: 1em;\r\n\tline-height: 2;\r\n\tfont-weight: normal;\r\n\tcursor: pointer; \/* display a hand cursor, like links *\/\r\n}\r\n#profiles :first-child h1{\r\n\tborder-top: 1px solid #999;\r\n}\r\n\r\n\/* visually indicate when it&#039;s open *\/\r\n#profiles .active h1{\r\n\tbackground-color: #f5f5f5;\r\n\tborder-bottom: 0;\r\n}\r\n\r\n\/* the panels, closed by default *\/\r\n#profiles .description{\r\n\tpadding: 0 1em;\r\n\tdisplay:none;\r\n}\r\n\r\n\/* needed only for the tabs, so we hide it here *\/\r\nnav{\r\n\tdisplay:none;\r\n}<\/code><\/pre>\n<p>For the tabs, we'll put the style in a CSS3 media query block (<i>@media screen and (min-width:760px)<\/i>), applied only when the viewport is wide enough:<\/p>\n<pre class=\"language-css\"><code>\r\n@media screen and (min-width:760px){\r\n\tbody{\r\n\t\tmax-width: 980px;\r\n\t\tmargin: 0 auto;\r\n\t}\r\n\t\r\n\t\/* display the tabs handles on the left side *\/\r\n\tnav{\r\n\t\tdisplay: block;\r\n\t\twidth: 12.5em;\r\n\t\tfloat: left;\r\n\t\tmargin-top: 1em;\r\n\t}\r\n\tnav ul{\r\n\t\tlist-style: none;\r\n\t\tmargin: O;\r\n\t\tpadding: 0;\r\n\t}\r\n\tnav a{\r\n\t\tdisplay: block;\r\n\t\tcolor: inherit;\r\n\t\ttext-decoration: none;\r\n\t}\r\n\tnav li{\r\n\t\tborder-bottom: 1px solid #999;\r\n\t\tborder-left: 1px solid #999;\r\n\t\tbackground-color: #dcdcdc;\r\n\t\tmargin: 0;\r\n\t\tpadding: 0 1em;\r\n\t\tfont-size: 1em;\r\n\t\tline-height: 2;\r\n\t}\r\n\tnav li:first-child{\r\n\t\tborder-top: 1px solid #999;\r\n\t}\r\n\t\/* visually indicate when it&#039;s open *\/\r\n\tnav .active{\r\n\t\tbackground: white;\r\n\t\tmargin-right: -1px;\r\n\t\tfont-weight: bold;\r\n\t}\r\n\t\r\n\t#profiles{\r\n\t\tmargin-left: 12.5em; \/* make room for the handles *\/\r\n\t\tborder: 1px solid #989898;\r\n\t}\r\n\t\r\n\t\/* hide all the profiles except the one that&#039;s active *\/\r\n\t#profiles article{\r\n\t\tdisplay: none;\r\n\t}\r\n\t#profiles .active{\r\n\t\tdisplay: block;\r\n\t}\r\n\t\r\n\t\/* override accordion styling *\/\r\n\t#profiles h1{\r\n\t\tbackground-color: transparent;\r\n\t\tborder: none;\r\n\t\tcursor: auto;\r\n\t}\r\n\t#profiles h1:first-child{\r\n\t\tborder-top: 0;\r\n\t}\r\n\t#profiles .active h1{\r\n\t\tbackground-color: transparent;\r\n\t}\r\n\t#profiles .description{\r\n\t\tdisplay: block;\r\n\t}\r\n}\r\n<\/code><\/pre>\n<h2>The script<\/h2>\n<p>The key to make the jQuery script responsive is to use the event <i>$(window).resize()<\/i> and the property <i>$(window).width()<\/i>:<\/p>\n<pre class=\"language-javascript\"><code>var panels = $(&#039;#profiles article&#039;); \/\/ cache the profiles\r\nvar navlinks = $(&#039;nav li&#039;); \/\/ cache the nav links\r\nvar view = &quot;&quot;; \/\/ store the actual view\r\nvar minWidth = 760; \/\/ breakpoint between views\r\n\r\nfunction accordionHandler() {\r\n\t\/\/ get the target panel\r\n\tvar panel = $(this).parent();\r\n\t\/\/ if not already open, open it. else, close it\r\n\tpanel.toggleClass(&#039;active&#039;).children(&#039;.description&#039;).slideToggle();\r\n\t\/\/ close every other panels\r\n\tpanels.not(panel).removeClass(&#039;active&#039;).children(&#039;.description&#039;).slideUp();\r\n\t\/\/ select corresponding navlink in case view switches to tabs later\r\n\tvar navlink = navlinks.has(&#039;a[href=#&#039;+panel.attr(&#039;id&#039;)+&#039;]&#039;);\r\n\tnavlink.toggleClass(&#039;active&#039;);\r\n\tnavlinks.not(navlink).removeClass(&#039;active&#039;);\r\n}\r\n\r\nfunction tabsHandler(e) {\r\n\t\/\/ prevent the default click event\r\n\te.preventDefault();\r\n\t\/\/ get the target panel\r\n\tpanel = $($(this).attr(&#039;href&#039;));\r\n\t\/\/ open it\r\n\tpanel.addClass(&#039;active&#039;);\r\n\t\/\/ close every other panels\r\n\tpanels.not(panel).removeClass(&#039;active&#039;);\r\n\t\/\/ select corresponding navlink\r\n\tnavlinks.removeClass(&#039;active&#039;);\r\n\t$(this).parent().addClass(&#039;active&#039;);\r\n}\r\n\r\nfunction switchView() {\r\n\t\/\/ if the viewport is wider than minWidth\r\n\tif ($(window).width() &gt; minWidth) {\r\n\t\t\/\/ switch to tabs view if it&#039;s not already the case\r\n\t\tif (view != &quot;tabs&quot;) {\r\n\t\t\tview = &quot;tabs&quot;;\r\n\t\t\t\/\/ remove accordion behavior\r\n\t\t\tpanels.children(&#039;h1&#039;).off(&#039;click&#039;,accordionHandler);\r\n\t\t\tpanels.children(&#039;.description&#039;).show();\r\n\t\t\t\/\/ add tabs behavior\r\n\t\t\tnavlinks.children(&#039;a&#039;).on(&#039;click&#039;,tabsHandler);\r\n\t\t\t\/\/ open the first tab if no tab is open\r\n\t\t\tif (!panels.is(&#039;.active&#039;)){\r\n\t\t\t\tnavlinks.first().addClass(&#039;active&#039;);\r\n\t\t\t\tpanels.first().addClass(&#039;active&#039;);\r\n\t\t\t}\r\n\t\t}\r\n\t\/\/ if the viewport is smaller than minWidth\r\n\t} else {\r\n\t\t\/\/ switch to accordion view if it&#039;s not already the case\r\n\t\tif (view != &quot;accordion&quot;) {\r\n\t\t\tview = &quot;accordion&quot;;\r\n\t\t\t\/\/ remove tabs behavior\r\n\t\t\tnavlinks.children(&#039;a&#039;).off(&#039;click&#039;,tabsHandler);\r\n\t\t\t\/\/ add accordion behavior\r\n\t\t\tpanels.children(&#039;h1&#039;).on(&#039;click&#039;,accordionHandler);\r\n\t\t\t\/\/ hide every panel except if there&#039;s one &quot;active&quot;\r\n\t\t\tpanels.filter(&#039;.active&#039;).children(&#039;.description&#039;).show();\r\n\t\t\tpanels.not(&#039;.active&#039;).children(&#039;.description&#039;).hide();\r\n\t\t}\r\n\t}\r\n}\r\n\r\n\/\/ load the right view at init and when the viewport changes\r\n$(document).ready(switchView);\r\n$(window).resize(switchView);<\/code><\/pre>\n<p>Last thing, we'll need to add this small meta in the document head, so that smartphones know that the page is made for them, and won't try to adapt it:<\/p>\n<pre class=\"language-markup\"><code>&lt;meta name=&quot;viewport&quot; content=&quot;width=device-width, initial-scale=1&quot; \/&gt;<\/code><\/pre>\n<p>If we want to take care of the poor IE8 users, we'll need to add two polyfills: one to understand HTML5, the other to understand CSS3 min\/max-width media queries (available <a href=\"https:\/\/github.com\/scottjehl\/Respond\" title=\"Respond\">here<\/a>:<\/p>\n<pre class=\"language-markup\"><code>&lt;!--[if lt IE 9]&gt;\r\n &lt;script src=&quot;http:\/\/html5shiv.googlecode.com\/svn\/trunk\/html5.js&quot;&gt;&lt;\/script&gt;\r\n &lt;script src=&quot;respond.min.js&quot;&gt;&lt;\/script&gt;\r\n&lt;![endif]--&gt;<\/code><\/pre>\n<p>That's it! We now have a <a class=\"button white\" href=\"http:\/\/dev.nomine.fr\/css3-jquery-experiment\/\" title=\"Demo: A responsive experiment with CSS3 and jQuery\">responsive accordion\/tabs display<\/a>.<br \/>\nWhat do you think? Anything you'd make differently?<\/p>\n<p><!--\n\n<aside>Remark: there are also some \"pure CSS3\" solutions involving :target selector or checkbox elements (see <a href=\"http:\/\/tympanus.net\/codrops\/2012\/02\/21\/accordion-with-css3\/\" target=\"_blank\">this great Codrops article<\/a>) but it makes it more complicated to switch between views so I'll stick to jQuery for this example.<\/aside>\n\n--><\/p>\n","protected":false},"excerpt":{"rendered":"<p>I&#8217;ve been playing lately with responsive design, trying to present data the best way depending on the screen size available. Most of the time, CSS3 media queries will be enough. However, some designs will also require a bit of jQuery. Is it possible to make it responsive as well? That&#8217;s what I intented in this [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":187,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_exactmetrics_skip_tracking":false,"_exactmetrics_sitenote_active":false,"_exactmetrics_sitenote_note":"","_exactmetrics_sitenote_category":0,"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[15],"tags":[16,18,17],"class_list":["post-167","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-experiments","tag-css3","tag-jquery","tag-media-queries"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.4 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>A responsive experiment with CSS3 and jQuery: switching between accordion and tabs display  - Nomine Web Creations<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/alexis.nomine.fr\/en\/blog\/2013\/04\/08\/responsive-css3-jquery-switching-accordion-tabs\/\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Alexis Nomin\u00e9\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"5 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/alexis.nomine.fr\\\/en\\\/blog\\\/2013\\\/04\\\/08\\\/responsive-css3-jquery-switching-accordion-tabs\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/alexis.nomine.fr\\\/en\\\/blog\\\/2013\\\/04\\\/08\\\/responsive-css3-jquery-switching-accordion-tabs\\\/\"},\"author\":{\"name\":\"Alexis Nomin\u00e9\",\"@id\":\"https:\\\/\\\/alexis.nomine.fr\\\/en\\\/#\\\/schema\\\/person\\\/3b5fe5cc50f1203f12855f8dee331109\"},\"headline\":\"A responsive experiment with CSS3 and jQuery: switching between accordion and tabs display\",\"datePublished\":\"2013-04-08T00:10:40+00:00\",\"dateModified\":\"2013-04-08T03:59:54+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/alexis.nomine.fr\\\/en\\\/blog\\\/2013\\\/04\\\/08\\\/responsive-css3-jquery-switching-accordion-tabs\\\/\"},\"wordCount\":292,\"commentCount\":0,\"image\":{\"@id\":\"https:\\\/\\\/alexis.nomine.fr\\\/en\\\/blog\\\/2013\\\/04\\\/08\\\/responsive-css3-jquery-switching-accordion-tabs\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/alexis.nomine.fr\\\/en\\\/files\\\/2013\\\/04\\\/responsive-460.jpg\",\"keywords\":[\"CSS3\",\"jQuery\",\"media queries\"],\"articleSection\":[\"Experiments\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\\\/\\\/alexis.nomine.fr\\\/en\\\/blog\\\/2013\\\/04\\\/08\\\/responsive-css3-jquery-switching-accordion-tabs\\\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/alexis.nomine.fr\\\/en\\\/blog\\\/2013\\\/04\\\/08\\\/responsive-css3-jquery-switching-accordion-tabs\\\/\",\"url\":\"https:\\\/\\\/alexis.nomine.fr\\\/en\\\/blog\\\/2013\\\/04\\\/08\\\/responsive-css3-jquery-switching-accordion-tabs\\\/\",\"name\":\"A responsive experiment with CSS3 and jQuery: switching between accordion and tabs display - Nomine Web Creations\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/alexis.nomine.fr\\\/en\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/alexis.nomine.fr\\\/en\\\/blog\\\/2013\\\/04\\\/08\\\/responsive-css3-jquery-switching-accordion-tabs\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/alexis.nomine.fr\\\/en\\\/blog\\\/2013\\\/04\\\/08\\\/responsive-css3-jquery-switching-accordion-tabs\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/alexis.nomine.fr\\\/en\\\/files\\\/2013\\\/04\\\/responsive-460.jpg\",\"datePublished\":\"2013-04-08T00:10:40+00:00\",\"dateModified\":\"2013-04-08T03:59:54+00:00\",\"author\":{\"@id\":\"https:\\\/\\\/alexis.nomine.fr\\\/en\\\/#\\\/schema\\\/person\\\/3b5fe5cc50f1203f12855f8dee331109\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/alexis.nomine.fr\\\/en\\\/blog\\\/2013\\\/04\\\/08\\\/responsive-css3-jquery-switching-accordion-tabs\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/alexis.nomine.fr\\\/en\\\/blog\\\/2013\\\/04\\\/08\\\/responsive-css3-jquery-switching-accordion-tabs\\\/#primaryimage\",\"url\":\"https:\\\/\\\/alexis.nomine.fr\\\/en\\\/files\\\/2013\\\/04\\\/responsive-460.jpg\",\"contentUrl\":\"https:\\\/\\\/alexis.nomine.fr\\\/en\\\/files\\\/2013\\\/04\\\/responsive-460.jpg\",\"width\":460,\"height\":460},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/alexis.nomine.fr\\\/en\\\/#website\",\"url\":\"https:\\\/\\\/alexis.nomine.fr\\\/en\\\/\",\"name\":\"Nomine Web Creations\",\"description\":\"Websites creation, development, web design\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/alexis.nomine.fr\\\/en\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/alexis.nomine.fr\\\/en\\\/#\\\/schema\\\/person\\\/3b5fe5cc50f1203f12855f8dee331109\",\"name\":\"Alexis Nomin\u00e9\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/1d01656b8ca51f9a4999518e34d1477667b1bdc8abf11eea3430e03a78bcf48e?s=96&d=mm&r=g\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/1d01656b8ca51f9a4999518e34d1477667b1bdc8abf11eea3430e03a78bcf48e?s=96&d=mm&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/1d01656b8ca51f9a4999518e34d1477667b1bdc8abf11eea3430e03a78bcf48e?s=96&d=mm&r=g\",\"caption\":\"Alexis Nomin\u00e9\"},\"url\":\"https:\\\/\\\/alexis.nomine.fr\\\/en\\\/blog\\\/author\\\/alexis\\\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"A responsive experiment with CSS3 and jQuery: switching between accordion and tabs display  - Nomine Web Creations","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/alexis.nomine.fr\/en\/blog\/2013\/04\/08\/responsive-css3-jquery-switching-accordion-tabs\/","twitter_misc":{"Written by":"Alexis Nomin\u00e9","Est. reading time":"5 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/alexis.nomine.fr\/en\/blog\/2013\/04\/08\/responsive-css3-jquery-switching-accordion-tabs\/#article","isPartOf":{"@id":"https:\/\/alexis.nomine.fr\/en\/blog\/2013\/04\/08\/responsive-css3-jquery-switching-accordion-tabs\/"},"author":{"name":"Alexis Nomin\u00e9","@id":"https:\/\/alexis.nomine.fr\/en\/#\/schema\/person\/3b5fe5cc50f1203f12855f8dee331109"},"headline":"A responsive experiment with CSS3 and jQuery: switching between accordion and tabs display","datePublished":"2013-04-08T00:10:40+00:00","dateModified":"2013-04-08T03:59:54+00:00","mainEntityOfPage":{"@id":"https:\/\/alexis.nomine.fr\/en\/blog\/2013\/04\/08\/responsive-css3-jquery-switching-accordion-tabs\/"},"wordCount":292,"commentCount":0,"image":{"@id":"https:\/\/alexis.nomine.fr\/en\/blog\/2013\/04\/08\/responsive-css3-jquery-switching-accordion-tabs\/#primaryimage"},"thumbnailUrl":"https:\/\/alexis.nomine.fr\/en\/files\/2013\/04\/responsive-460.jpg","keywords":["CSS3","jQuery","media queries"],"articleSection":["Experiments"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/alexis.nomine.fr\/en\/blog\/2013\/04\/08\/responsive-css3-jquery-switching-accordion-tabs\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/alexis.nomine.fr\/en\/blog\/2013\/04\/08\/responsive-css3-jquery-switching-accordion-tabs\/","url":"https:\/\/alexis.nomine.fr\/en\/blog\/2013\/04\/08\/responsive-css3-jquery-switching-accordion-tabs\/","name":"A responsive experiment with CSS3 and jQuery: switching between accordion and tabs display - Nomine Web Creations","isPartOf":{"@id":"https:\/\/alexis.nomine.fr\/en\/#website"},"primaryImageOfPage":{"@id":"https:\/\/alexis.nomine.fr\/en\/blog\/2013\/04\/08\/responsive-css3-jquery-switching-accordion-tabs\/#primaryimage"},"image":{"@id":"https:\/\/alexis.nomine.fr\/en\/blog\/2013\/04\/08\/responsive-css3-jquery-switching-accordion-tabs\/#primaryimage"},"thumbnailUrl":"https:\/\/alexis.nomine.fr\/en\/files\/2013\/04\/responsive-460.jpg","datePublished":"2013-04-08T00:10:40+00:00","dateModified":"2013-04-08T03:59:54+00:00","author":{"@id":"https:\/\/alexis.nomine.fr\/en\/#\/schema\/person\/3b5fe5cc50f1203f12855f8dee331109"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/alexis.nomine.fr\/en\/blog\/2013\/04\/08\/responsive-css3-jquery-switching-accordion-tabs\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/alexis.nomine.fr\/en\/blog\/2013\/04\/08\/responsive-css3-jquery-switching-accordion-tabs\/#primaryimage","url":"https:\/\/alexis.nomine.fr\/en\/files\/2013\/04\/responsive-460.jpg","contentUrl":"https:\/\/alexis.nomine.fr\/en\/files\/2013\/04\/responsive-460.jpg","width":460,"height":460},{"@type":"WebSite","@id":"https:\/\/alexis.nomine.fr\/en\/#website","url":"https:\/\/alexis.nomine.fr\/en\/","name":"Nomine Web Creations","description":"Websites creation, development, web design","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/alexis.nomine.fr\/en\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/alexis.nomine.fr\/en\/#\/schema\/person\/3b5fe5cc50f1203f12855f8dee331109","name":"Alexis Nomin\u00e9","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/1d01656b8ca51f9a4999518e34d1477667b1bdc8abf11eea3430e03a78bcf48e?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/1d01656b8ca51f9a4999518e34d1477667b1bdc8abf11eea3430e03a78bcf48e?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/1d01656b8ca51f9a4999518e34d1477667b1bdc8abf11eea3430e03a78bcf48e?s=96&d=mm&r=g","caption":"Alexis Nomin\u00e9"},"url":"https:\/\/alexis.nomine.fr\/en\/blog\/author\/alexis\/"}]}},"jetpack_featured_media_url":"https:\/\/alexis.nomine.fr\/en\/files\/2013\/04\/responsive-460.jpg","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/alexis.nomine.fr\/en\/wp-json\/wp\/v2\/posts\/167","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/alexis.nomine.fr\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/alexis.nomine.fr\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/alexis.nomine.fr\/en\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/alexis.nomine.fr\/en\/wp-json\/wp\/v2\/comments?post=167"}],"version-history":[{"count":0,"href":"https:\/\/alexis.nomine.fr\/en\/wp-json\/wp\/v2\/posts\/167\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/alexis.nomine.fr\/en\/wp-json\/wp\/v2\/media\/187"}],"wp:attachment":[{"href":"https:\/\/alexis.nomine.fr\/en\/wp-json\/wp\/v2\/media?parent=167"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/alexis.nomine.fr\/en\/wp-json\/wp\/v2\/categories?post=167"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/alexis.nomine.fr\/en\/wp-json\/wp\/v2\/tags?post=167"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}