Initial commit

This commit is contained in:
2021-03-23 13:54:38 +01:00
commit 82b142ff95
16941 changed files with 2617212 additions and 0 deletions

View File

@@ -0,0 +1,13 @@
<?xml version="1.0" encoding="UTF-8" ?>
<config xmlns="http://thelia.net/schema/dic/config"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://thelia.net/schema/dic/config http://thelia.net/schema/dic/config/thelia-1.0.xsd">
<hooks>
<hook id="mainmenuhook.hook.front">
<tag name="hook.event_listener" event="main.navbar-secondary" templates="render:main-navbar-secondary.html"/>
</hook>
</hooks>
</config>

View File

@@ -0,0 +1,24 @@
<?xml version="1.0" encoding="UTF-8"?>
<module xmlns="http://thelia.net/schema/dic/module"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://thelia.net/schema/dic/module http://thelia.net/schema/dic/module/module-2_2.xsd">
<fullnamespace>MainMenuHook\MainMenuHook</fullnamespace>
<descriptive locale="en_US">
<title>Block Main Menu</title>
</descriptive>
<descriptive locale="fr_FR">
<title>Bloc Menu Principal</title>
</descriptive>
<languages>
<language>en_US</language>
<language>fr_FR</language>
</languages>
<version>2.3.5</version>
<author>
<name>Frédéric FLIPPE</name>
<email>frederic@id-media.fr</email>
</author>
<type>classic</type>
<thelia>2.2.0</thelia>
<stability>alpha</stability>
</module>

View File

@@ -0,0 +1,20 @@
<?php
/*************************************************************************************/
/* This file is part of the Thelia package. */
/* */
/* Copyright (c) OpenStudio */
/* email : dev@thelia.net */
/* web : http://www.thelia.net */
/* */
/* For the full copyright and license information, please view the LICENSE.txt */
/* file that was distributed with this source code. */
/*************************************************************************************/
namespace MainMenuHook;
use Thelia\Module\BaseModule;
class MainMenuHook extends BaseModule
{
}

View File

@@ -0,0 +1,55 @@
# Main Menu Hook
Add a short description here. You can also add a screenshot if needed.
## Installation
### Manually
* Copy the module into ```<thelia_root>/local/modules/``` directory and be sure that the name of the module is MainMenuHook.
* Activate it in your thelia administration panel
### Composer
Add it in your main thelia composer.json file
```
composer require your-vendor/main-menu-hook-module:~1.0
```
## Usage
Explain here how to use your module, how to configure it, etc.
## Hook
If your module use one or more hook, fill this part. Explain which hooks are used.
## Loop
If your module declare one or more loop, describe them here like this :
[loop name]
### Input arguments
|Argument |Description |
|--- |--- |
|**arg1** | describe arg1 with an exemple. |
|**arg2** | describe arg2 with an exemple. |
### Output arguments
|Variable |Description |
|--- |--- |
|$VAR1 | describe $VAR1 variable |
|$VAR2 | describe $VAR2 variable |
### Exemple
Add a complete exemple of your loop
## Other ?
If you have other think to put, feel free to complete your readme as you want.

View File

@@ -0,0 +1,11 @@
{
"name": "your-vendor/main-menu-hook-module",
"license": "LGPL-3.0+",
"type": "thelia-module",
"require": {
"thelia/installer": "~1.1"
},
"extra": {
"installer-name": "MainMenuHook"
}
}

View File

@@ -0,0 +1,42 @@
<ul class="nav navbar-nav navbar-categories">
{* <li><a href="{navigate to="index"}" class="home">{intl l="Home" d="hooknavigation.fo.default"}</a></li> *}
<li><a href="{navigate to="index"}" class="home"></a></li>
{loop type="category" name="category.navigation" parent="0" need_count_child="yes"}
<li class="dropdown">
<a href="{$URL}" class="dropdown-toggle">{$TITLE}</a>
<ul class="dropdown-menu" role="menu">
{loop type="product" name="sub-cat" category=$ID}
<li><a href="{$URL}">{$TITLE}</a></li>
{/loop}
</ul>
</li>
{/loop}
{loop type="folder" name="menu" exclude="1,14"}
{if $CONTENT_COUNT == 1 && $PARENT == 0}
{loop type="content" name="sous.menu" folder=$ID}
<li class="nav-item">
<a class="nav-link" href="{$URL}">
{$TITLE}
</a>
</li>
{/loop}
{elseif $CONTENT_COUNT > 1}
<li class="dropdown">
<a class="nav-link dropdown-toggle" href="#" id="navbarDropdown" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
{$TITLE}
</a>
<ul class="dropdown-menu" aria-labelledby="navbarDropdownMenuLink">
{loop type="content" name="sous.menu" folder=$ID}
<li class="nav-item"><a class="dropdown-item" href="{$URL}">{$TITLE}</a></li>
{/loop}
</ul>
</li>
{/if}
{/loop}
{loop type="content" name="menu" id=24}
<li class="nav-item">
<a class="nav-link" href="{$URL}">{$TITLE}</a>
</li>
{/loop}
<li{if strpos($smarty.server.REQUEST_URI, "contact")} class="active"{/if} id="{$smarty.server.REQUEST_URI}"><a href="{url path="/contact"}">{intl l="Contact"}</a></li>
</ul>