Hi Gee,

I suspect asking these types of questions on StackOverflow. The community
is fairly good about responding to the them and folks on this list also
monitor the polymer tag.

On Wed, Nov 12, 2014 at 2:30 PM, Gee Jay Almestas <[email protected]>
wrote:

> im using *core-scaffold* and *core-item* for my menu i also have *my own
> element wrapped by a div id* i want my core-item menu to scroll to that
> div when i click it... what will i do to do it? tried to use jquery but its
> not working... see info below
>
> *here's my header panel*
> <core-scaffold responsiveWidth="600px">
>   <core-header-panel navigation flex mode="scroll">
>     <core-toolbar>Navigation</core-toolbar>
>     <core-menu theme="core-light-theme">
>       <core-item icon="home" label="Home"></core-item>
> <core-item icon="assignment-ind" label="Who am i"></core-item>
>       <core-item icon="work" label="Works"></core-item>
> *<core-item icon="work" label="Skills"><a class="nav"
> href="#skill"></a></core-item*> *<!-- WHEN CLICK WILL GO TO SKILL ID DIV
> -->*
>         <core-item icon="settings-phone" label="Contacts"></core-item>
>         <core-item icon="link" label="v8"></core-item>
>         <core-item icon="link" label="v7"></core-item>
>         <core-item icon="link" label="v6"></core-item>
>     </core-menu>
>   </core-header-panel>
>
> *my element*
>
>
>
> *<div id="skills"> <!-- should scroll on this part -->
> <skills-koh></skills-koh> <!-- my element --></div></core-scaffold>im
> trying to use a js script but its not working*
>
>
> *jQuery(".nav").on("click", function(event){    event.preventDefault();
>    var dest=null;     if(($($(this.hash)).offset().top) >
> ($(document).height()-$(window).height())){          dest=
> $(document).height()-$(window).height();     }else{
> dest=$($(this.hash)).offset().top;     }
> $($(this.hash)).trigger("click");
> $('html,body').animate({scrollTop:dest}, 500, 'swing' );      });*
>
>
> *also added on my index.html<script
> src="//ajax.googleapis.com/ajax/libs/jquery/1.11.0/jquery.min.js
> <http://ajax.googleapis.com/ajax/libs/jquery/1.11.0/jquery.min.js>"></script>*
>
>  Follow Polymer on Google+: plus.google.com/107187849809354688692
> ---
> You received this message because you are subscribed to the Google Groups
> "Polymer" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/polymer-dev/158ccc8e-3707-4624-9ec6-a62267f8ead6%40googlegroups.com
> <https://groups.google.com/d/msgid/polymer-dev/158ccc8e-3707-4624-9ec6-a62267f8ead6%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
> For more options, visit https://groups.google.com/d/optout.
>

Follow Polymer on Google+: plus.google.com/107187849809354688692
--- 
You received this message because you are subscribed to the Google Groups 
"Polymer" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/polymer-dev/CACGqRCCp1SUjMqgUkE%3DDgoMr6ys0XD85h6VohAtdTofjaNCpyw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to