cssAudio - Activefile-genericCSS - ActiveGeneric - ActiveHTML - ActiveImage - ActiveJS - ActiveSVG - ActiveText - Activefile-genericVideo - ActiveLovehtmlicon-new-collectionicon-personicon-teamlog-outoctocatpop-outspinnerstartv

Pen Settings

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URL's added here will be added as <link>s in order, and before the CSS in the editor. If you link to another Pen, it will include the CSS from that Pen. If the preprocessor matches, it will attempt to combine them before processing.

+ add another resource

You're using npm packages, so we've auto-selected Babel for you here, which we require to process imports and make it all work. If you need to use a different JavaScript preprocessor, remove the packages in the npm tab.

Add External Scripts/Pens

Any URL's added here will be added as <script>s in order, and run before the JavaScript in the editor. You can use the URL of any other Pen and it will include the JavaScript from that Pen.

+ add another resource

Use npm Packages

We can make npm packages available for you to use in your JavaScript. We use webpack to prepare them and make them available to import. We'll also process your JavaScript with Babel.

⚠️ This feature can only be used by logged in users.

Code Indentation

     

Save Automatically?

If active, Pens will autosave every 30 seconds after being saved once.

Auto-Updating Preview

If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.

            
              <p>フォーラム<br>トピック: <a href="https://wp-simplicity.com/suport/topic/%e3%82%b9%e3%83%9e%e3%83%9b%e3%82%b5%e3%82%a4%e3%83%88%e3%80%80%e3%82%a2%e3%82%b3%e3%83%bc%e3%83%87%e3%82%a3%e3%82%aa%e3%83%b3%e3%83%84%e3%83%aa%e3%83%bc%e3%83%a1%e3%83%8b%e3%83%a5%e3%83%bc%e3%81%ae/" target="_blank">スマホサイト アコーディオンツリーメニューの色変更</a>のサンプルです</p>

<div id="navi">
      	<div id="navi-in">
      <div class="menu-%e3%83%a1%e3%82%a4%e3%83%b3%e3%83%a1%e3%83%8b%e3%83%a5%e3%83%bc-container"><ul id="menu-%e3%83%a1%e3%82%a4%e3%83%b3%e3%83%a1%e3%83%8b%e3%83%a5%e3%83%bc" class="menu"><li id="menu-item-14" class="menu-item menu-item-type-custom menu-item-object-custom menu-item-home menu-item-14"><a href="https://wp-simplicity.com/">ホーム</a></li>
<li id="menu-item-51855" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-has-children menu-item-51855"><a href="https://wp-simplicity.com/downloads/downloads2/">ダウンロード</a>
<ul class="sub-menu">
	<li id="menu-item-35130" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-35130"><a href="https://wp-simplicity.com/downloads/downloads2/">Simplicity2</a></li>
	<li id="menu-item-35129" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-35129"><a href="https://wp-simplicity.com/downloads/child-theme2/">Simplicity2子テーマ</a></li>
	<li id="menu-item-1895" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-1895"><a href="https://wp-simplicity.com/downloads/skin/">スキン</a></li>
	<li id="menu-item-44126" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-44126"><a href="https://wp-simplicity.com/downloads/terms-of-use/">Simplicity利用規約</a></li>
</ul>
</li>
<li id="menu-item-45" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-45"><a href="https://wp-simplicity.com/initialization/">初期設定</a></li>
<li id="menu-item-61" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-has-children menu-item-61"><a href="https://wp-simplicity.com/layout/">レイアウト見本</a>
<ul class="sub-menu">
	<li id="menu-item-51835" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-51835"><a href="https://wp-simplicity.com/layout/">レイアウト見本</a></li>
	<li id="menu-item-51834" class="menu-item menu-item-type-custom menu-item-object-custom menu-item-51834"><a href="https://simplicity.sample.mixh.jp/">デモサイト</a></li>
</ul>
</li>
<li id="menu-item-266" class="menu-item menu-item-type-taxonomy menu-item-object-category menu-item-266"><a href="https://wp-simplicity.com/category/news/">NEWS</a></li>
<li id="menu-item-267" class="menu-item menu-item-type-taxonomy menu-item-object-category menu-item-267"><a href="https://wp-simplicity.com/category/settings/">設定いろいろ</a></li>
<li id="menu-item-268" class="menu-item menu-item-type-taxonomy menu-item-object-category menu-item-268"><a href="https://wp-simplicity.com/category/settings/customizer/">カスタマイザー設定</a></li>
<li id="menu-item-141" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-has-children menu-item-141"><a href="https://wp-simplicity.com/reference/">参考情報</a>
<ul class="sub-menu">
	<li id="menu-item-35028" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-35028"><a href="https://wp-simplicity.com/reference/">参考・技術情報</a></li>
	<li id="menu-item-1154" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-1154"><a href="https://wp-simplicity.com/reference/adoption-sites/">導入サイト</a></li>
</ul>
</li>
<li id="menu-item-9272" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-has-children menu-item-9272"><a href="https://wp-simplicity.com/forums/">サポート</a>
<ul class="sub-menu">
	<li id="menu-item-37199" class="menu-item menu-item-type-custom menu-item-object-custom menu-item-37199"><a href="https://wp-simplicity.com/suport/topic/first-time/">フォーラム利用の前に</a></li>
	<li id="menu-item-9280" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-9280"><a href="https://wp-simplicity.com/forums/">フォーラム</a></li>
	<li id="menu-item-9273" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-9273"><a href="https://wp-simplicity.com/forums/create-topic/">トピックの作成</a></li>
	<li id="menu-item-44548" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-44548"><a href="https://wp-simplicity.com/forums/recent-response/">最近の書き込み一覧</a></li>
	<li id="menu-item-25226" class="menu-item menu-item-type-custom menu-item-object-custom menu-item-25226"><a href="https://wp-simplicity.com/important-point/">テーマ利用前の注意点</a></li>
	<li id="menu-item-18106" class="menu-item menu-item-type-custom menu-item-object-custom menu-item-18106"><a href="https://wp-simplicity.com/trouble-guideline/">動作不良時のガイドライン</a></li>
	<li id="menu-item-23521" class="menu-item menu-item-type-custom menu-item-object-custom menu-item-23521"><a href="https://wp-simplicity.com/simplicity-known-bugs/">既知の不具合</a></li>
	<li id="menu-item-17785" class="menu-item menu-item-type-post_type menu-item-object-page menu-item-17785"><a href="https://wp-simplicity.com/forums/unsupported/">サポート対象外のもの</a></li>
</ul>
</li>
</ul></div>    </div><!-- /#navi-in -->
  </div>
            
          
!
            
              //これは何かしら入っていたのでいれてあるだけで不要
.slicknav_menu {
  display: block;
}

//ここから -----------------------

//フォントサイズ
.slicknav_nav .menu-item {
	font-size: 16px;
}

//背景色
.slicknav_menu {
	background-color: #f00;
}

//リンク色
.slicknav_nav a {
	color: #00f;
}

//リンクhover
.slicknav_nav a:hover {
	background-color: #111;
	color: #fff;
	border-radius: 0 0 5px 10%;
}
//サブメニューがある親のhover
//ただし、ここは特殊なhtmlの構造をしているので
//リンクテキストと実際のリンクが混じったような感じになる
.slicknav_nav .slicknav_row:hover {
	background-color: #fff;
	color: #111;
	border-radius: 0 0 5px 10%;
}

//最後のアイテムの色変更
.slicknav_nav > li:last-of-type {
	background-color: #fff;
}
.slicknav_nav > li:last-of-type a {
	color: #0f0;
}
            
          
!
            
              (function($){
  $('#navi .menu > ul, #navi ul.menu').slicknav({
    label: 'MENU',
    allowParentLinks: true,
		closedSymbol: '<i class="fa fa-plus-square" aria-hidden="true"></i>',
		openedSymbol: '<i class="fa fa-minus-square" aria-hidden="true"></i>'
  });
})(jQuery);
            
          
!
999px
🕑 One or more of the npm packages you are using needs to be built. You're the first person to ever need it! We're building it right now and your preview will start updating again when it's ready.
Loading ..................

Console