You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

344 lines
11 KiB

1 year ago
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
  1. $( document ).ready(function() {
  2. $('.pcoded-navbar .pcoded-hasmenu').attr('subitem-icon', 'style1');
  3. $( "#pcoded" ).pcodedmenu({
  4. themelayout: 'horizontal',
  5. horizontalMenuplacement: 'top',
  6. horizontalBrandItem: true,
  7. horizontalLeftNavItem: true,
  8. horizontalRightItem: true,
  9. horizontalSearchItem: true,
  10. horizontalBrandItemAlign: 'left',
  11. horizontalLeftNavItemAlign: 'left',
  12. horizontalRightItemAlign: 'right',
  13. horizontalsearchItemAlign: 'right',
  14. horizontalMobileMenu: true,
  15. MenuTrigger: 'hover',
  16. SubMenuTrigger: 'hover',
  17. activeMenuClass: 'active',
  18. ThemeBackgroundPattern: 'pattern6',
  19. HeaderBackground: 'theme6',
  20. LHeaderBackground :'theme1',
  21. NavbarBackground: 'themelight1',
  22. ActiveItemBackground: 'theme4',
  23. SubItemBackground: 'theme2',
  24. menutype: 'st6', // Value should be st1,st2,st3
  25. freamtype: "theme1",
  26. ActiveItemStyle: 'style1',
  27. ItemBorder: true,
  28. ItemBorderStyle: 'none',
  29. SubItemBorder: true,
  30. DropDownIconStyle: 'style1',
  31. FixedNavbarPosition: true,
  32. FixedHeaderPosition: true,
  33. horizontalNavIsCentered: false,
  34. horizontalstickynavigation: false,
  35. horizontalNavigationMenuIcon: true,
  36. });
  37. function freamtype() {
  38. $('.theme-color > a.fream-type').on("click", function () {
  39. var value = $(this).attr("fream-type");
  40. $('.pcoded').attr('fream-type', value);
  41. $('.pcoded-header').attr("header-theme", "themelight"+value);
  42. $('.pcoded-navbar').attr("navbar-theme", "theme" + value);
  43. $('.navbar-logo').attr("logo-theme", "theme" + value);
  44. });
  45. };
  46. freamtype();
  47. /* Left header logo Change function Start */
  48. function handleogortheme() {
  49. $('.theme-color > a.logo-theme').on("click", function () {
  50. var logotheme = $(this).attr("logo-theme");
  51. $('.navbar-logo').attr("logo-theme", logotheme);
  52. });
  53. };
  54. handleogortheme();
  55. /* Vertical Header Position change function Start*/
  56. function handleheaderposition() {
  57. $('#header-position').change(function() {
  58. if( $(this).is(":checked")) {
  59. $('.pcoded-header').attr("pcoded-header-position", 'fixed' );
  60. $('.pcoded-navbar').attr("pcoded-header-position", 'fixed' );
  61. $('.pcoded-main-container').css('margin-top', $(".pcoded-header").outerHeight());
  62. }else {
  63. $('.pcoded-header').attr("pcoded-header-position", 'relative' );
  64. $('.pcoded-navbar').attr("pcoded-header-position", 'relative' );
  65. $('.pcoded-main-container').css('margin-top', '0px');
  66. }
  67. });
  68. };
  69. handleheaderposition ();
  70. /* Vertical Header Position change function Close*/
  71. function handleheadertheme() {
  72. $('.theme-color > a.header-theme').on("click", function() {
  73. var headertheme = $(this).attr("header-theme");
  74. $('.pcoded-header').attr("header-theme", headertheme);
  75. $('.navbar-logo').attr("logo-theme", headertheme);
  76. });
  77. };
  78. handleheadertheme();
  79. /* Navbar Theme Change function Start */
  80. function handlenavbartheme() {
  81. $('.theme-color > a.navbar-theme').on("click", function() {
  82. var navbartheme = $(this).attr("navbar-theme");
  83. $('.pcoded-navbar').attr("navbar-theme", navbartheme);
  84. $('.navbar-logo').attr("navbar-theme", navbartheme);
  85. });
  86. };
  87. handlenavbartheme();
  88. /* Navbar Theme Change function Close */
  89. /* Navbar Theme Change function Start */
  90. function handleActiveItemTheme() {
  91. $('.theme-color > a.active-item-theme').on("click", function() {
  92. var AtciveItemTheme = $(this).attr("active-item-theme");
  93. $('.pcoded-navbar').attr("active-item-theme", AtciveItemTheme);
  94. });
  95. };
  96. handleActiveItemTheme();
  97. /* Navbar Theme Change function Close */
  98. /* Theme background pattren Change function Start */
  99. function handlethemebgpattern() {
  100. $('.theme-color > a.themebg-pattern').on("click", function() {
  101. var themebgpattern = $(this).attr("themebg-pattern");
  102. $('body').attr("themebg-pattern", themebgpattern);
  103. });
  104. };
  105. handlethemebgpattern();
  106. /* Theme background pattren Change function Close */
  107. /* Theme Layout Change function start*/
  108. function handlethemehorizontallayout() {
  109. $('#theme-layout').val('wide').on('change', function (get_value) {
  110. get_value = $(this).val();
  111. $('.pcoded').attr('horizontal-layout', get_value);
  112. });
  113. };
  114. handlethemehorizontallayout ();
  115. /* Theme Layout Change function Close*/
  116. /*Menu Placement change function start*/
  117. function handleMenuPlacement() {
  118. $('#navbar-placement').val('top').on('change', function (get_value) {
  119. get_value = $(this).val();
  120. $('.pcoded').attr('horizontal-placement', get_value);
  121. });
  122. };
  123. handleMenuPlacement ();
  124. /*Menu Placement change function Close*/
  125. /*Item border change function Start*/
  126. function handleIItemBorder() {
  127. $('#item-border').change(function() {
  128. if( $(this).is(":checked")) {
  129. $('.pcoded-navbar .pcoded-item').attr('item-border', 'false');
  130. }else {
  131. $('.pcoded-navbar .pcoded-item').attr('item-border', 'true');
  132. }
  133. });
  134. };
  135. handleIItemBorder ();
  136. /*Item border change function Close*/
  137. /*SubItem border change function Start*/
  138. function handleSubIItemBorder() {
  139. $('#subitem-border').change(function() {
  140. if( $(this).is(":checked")) {
  141. $('.pcoded-navbar .pcoded-item').attr('subitem-border', 'false');
  142. }else {
  143. $('.pcoded-navbar .pcoded-item').attr('subitem-border', 'true');
  144. }
  145. });
  146. };
  147. handleSubIItemBorder ();
  148. /*SubItem border change function Close*/
  149. /*Item border Style change function Start*/
  150. function handlBoderStyle() {
  151. $('#vertical-border-style').val('solid').on('change', function (get_value) {
  152. get_value = $(this).val();
  153. $('.pcoded-navbar .pcoded-item').attr('item-border-style', get_value);
  154. });
  155. };
  156. handlBoderStyle ();
  157. /*Item border Style change function Close*/
  158. // demo 12 st
  159. /* Vertical Dropdown Icon change function Start*/
  160. function handleVerticalDropDownIconStyle() {
  161. $('#vertical-dropdown-icon').val('style1').on('change', function (get_value) {
  162. get_value = $(this).val();
  163. $('.pcoded-navbar .pcoded-hasmenu').attr('dropdown-icon', get_value);
  164. });
  165. };
  166. handleVerticalDropDownIconStyle ();
  167. /* Vertical Dropdown Icon change function Close*/
  168. /* Vertical SubItem Icon change function Start*/
  169. function handleVerticalSubMenuItemIconStyle() {
  170. $('#vertical-subitem-icon').val('style5').on('change', function (get_value) {
  171. get_value = $(this).val();
  172. $('.pcoded-navbar .pcoded-hasmenu').attr('subitem-icon', get_value);
  173. });
  174. };
  175. handleVerticalSubMenuItemIconStyle ();
  176. /* Vertical SubItem Icon change function Close*/
  177. // demo 12 ed
  178. /* Horizontal Navbar Position change function Start*/
  179. function handleNavigationPosition() {
  180. $('#sidebar-position').change(function() {
  181. if( $(this).is(":checked")) {
  182. $('.pcoded-navbar').attr("pcoded-navbar-position", 'fixed' );
  183. }else {
  184. $('.pcoded-navbar').attr("pcoded-navbar-position", 'relative' );
  185. }
  186. });
  187. };
  188. handleNavigationPosition ();
  189. /* Horizontal Navbar Position change function Close*/
  190. /* Hide Show Menu Icon */
  191. function handleNavigationMenuIcon() {
  192. $('#menu-icons').change(function() {
  193. if( $(this).is(":checked")) {
  194. $('.pcoded .pcoded-navbar .pcoded-item > li > a .pcoded-micon:not(".pcoded-search-item .pcoded-micon")').hide();
  195. }else {
  196. $('.pcoded .pcoded-navbar .pcoded-item > li > a .pcoded-micon:not(".pcoded-search-item .pcoded-micon")').show();
  197. }
  198. });
  199. };
  200. handleNavigationMenuIcon ();
  201. /* Hide Show Brand logo */
  202. function handlepcodedBrandVisibility() {
  203. $('#brand-visibility').change(function() {
  204. if( $(this).is(":checked")) {
  205. $('.pcoded .pcoded-navbar .pcoded-brand').hide();
  206. }else {
  207. $('.pcoded .pcoded-navbar .pcoded-brand').show();
  208. }
  209. });
  210. };
  211. handlepcodedBrandVisibility ();
  212. function handlePcodedLeftItemVisibility() {
  213. $('#leftitem-visibility').change(function() {
  214. if( $(this).is(":checked")) {
  215. $('.pcoded .pcoded-navbar .pcoded-item.pcoded-left-item').hide();
  216. }else {
  217. $('.pcoded .pcoded-navbar .pcoded-item.pcoded-left-item').show();
  218. }
  219. });
  220. };
  221. handlePcodedLeftItemVisibility ();
  222. function handlePcodedRightItemVisibility() {
  223. $('#rightitem-visibility').change(function() {
  224. if( $(this).is(":checked")) {
  225. $('.pcoded .pcoded-navbar .pcoded-item.pcoded-right-item').hide();
  226. }else {
  227. $('.pcoded .pcoded-navbar .pcoded-item.pcoded-right-item').show();
  228. }
  229. });
  230. };
  231. handlePcodedRightItemVisibility ();
  232. function handlePcodedSearchItemVisibility() {
  233. $('#searchitem-visibility').change(function() {
  234. if( $(this).is(":checked")) {
  235. $('.pcoded .pcoded-navbar .pcoded-item.pcoded-search-item').hide();
  236. }else {
  237. $('.pcoded .pcoded-navbar .pcoded-item.pcoded-search-item').show();
  238. }
  239. });
  240. };
  241. handlePcodedSearchItemVisibility ();
  242. function handleBrandItemAlign() {
  243. $('#branditem-align').val('left').on('change', function (get_value) {
  244. get_value = $(this).val();
  245. if (get_value === "left"){
  246. $('.pcoded-navbar .pcoded-brand').removeClass('pcoded-right-align');
  247. $('.pcoded-navbar .pcoded-brand').addClass('pcoded-left-align');
  248. }else{
  249. $('.pcoded-navbar .pcoded-brand').addClass('pcoded-right-align');
  250. $('.pcoded-navbar .pcoded-brand').removeClass('pcoded-left-align');
  251. }
  252. });
  253. };
  254. handleBrandItemAlign ();
  255. function handleLeftItemAlign() {
  256. $('#leftitem-align').val('left').on('change', function (get_value) {
  257. get_value = $(this).val();
  258. if (get_value === "left"){
  259. $('.pcoded-navbar .pcoded-left-item').removeClass('pcoded-right-align');
  260. $('.pcoded-navbar .pcoded-left-item').addClass('pcoded-left-align');
  261. }else{
  262. $('.pcoded-navbar .pcoded-left-item').addClass('pcoded-right-align');
  263. $('.pcoded-navbar .pcoded-left-item').removeClass('pcoded-left-align');
  264. }
  265. });
  266. };
  267. handleLeftItemAlign ();
  268. function handleRightItemAlign() {
  269. $('#rightitem-align').val('left').on('change', function (get_value) {
  270. get_value = $(this).val();
  271. if (get_value === "left"){
  272. $('.pcoded-navbar .pcoded-right-item').removeClass('pcoded-right-align');
  273. $('.pcoded-navbar .pcoded-right-item').addClass('pcoded-left-align');
  274. }else{
  275. $('.pcoded-navbar .pcoded-right-item').addClass('pcoded-right-align');
  276. $('.pcoded-navbar .pcoded-right-item').removeClass('pcoded-left-align');
  277. }
  278. });
  279. };
  280. handleRightItemAlign ();
  281. function handleSearchItemAlign() {
  282. $('#searchitem-align').val('left').on('change', function (get_value) {
  283. get_value = $(this).val();
  284. if (get_value === "left"){
  285. $('.pcoded-navbar .pcoded-search-item').removeClass('pcoded-right-align');
  286. $('.pcoded-navbar .pcoded-search-item').addClass('pcoded-left-align');
  287. }else{
  288. $('.pcoded-navbar .pcoded-search-item').addClass('pcoded-right-align');
  289. $('.pcoded-navbar .pcoded-search-item').removeClass('pcoded-left-align');
  290. }
  291. });
  292. };
  293. handleSearchItemAlign ();
  294. });
  295. function handlemenutype(get_value) {
  296. $('.pcoded').attr('nav-type', get_value);
  297. };
  298. handlemenutype("st2");