Path: csiph.com!.POSTED.204-73-239-109.cust.centrio.cz!not-for-mail From: Cezary Tomczyk Newsgroups: comp.lang.javascript Subject: Re: Looking for JS library that can do hierarchical menus Date: Thu, 15 Jun 2017 07:47:44 +0200 Organization: csiph.com Internet News Service Message-ID: References: <5f50f2f4-0e30-4e62-8ce1-6cb843d96432@googlegroups.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Injection-Date: Thu, 15 Jun 2017 05:47:44 +0000 (UTC) Injection-Info: csiph.com; posting-host="204-73-239-109.cust.centrio.cz:109.239.73.204"; logging-data="34844"; mail-complaints-to="admin@kev009.com" User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0) Gecko/20100101 Thunderbird/52.1.1 In-Reply-To: Content-Language: en-GB Xref: csiph.com comp.lang.javascript:33526 On 15/06/2017 01:31, Maik Koenig wrote: > Am 14.06.2017 um 17:34 schrieb Haddock: > >> Let's say I have a main menu bar with 3 menus: >> >> Line 1: Menu1 >Menu2< Menu3 >> >> Line 2: Menu2.1 Menu2.2 Menu2.3 Menu2.4 >> >> >> In the little sketch above the user klicked on Menu2 which causes in >> a line below the menu items of Menu2 to be displayed which are >> Menu2.1 Menu2.2 Menu2.3 Menu2.4. >> >> Does anyone know of a JS library that has already that kind of menus >> implemented? > > You dont need JS for that. CSS is your friend. > > Example: https://codepen.io/philhoyt/pen/ujHzd With a note that it doesn't work when keyboard navigation used - a submenu is not accessible. -- Cezary Tomczyk http://www.ctomczyk.pl/ https://www.aslint.org/ - Accessibility validation tool