Comments (4)
I know the only one way to implement it: Extend Menu
widget and overwrite isItemActive
method with custom logic.
from yii2-gentelella.
Is the issue resolved?
from yii2-gentelella.
The modified Menu
widget :
if (isset($item['active']) && $item['active'])
return true;
parent::isItemActive($item);
doesn't help, because the custom.js
file also handles the current-page
class and .slideDown()
function. The main menu is active, but the child menu is not opened.
// check active menu
$SIDEBAR_MENU.find('a[href="' + CURRENT_URL + '"]').parent('li').addClass('current-page');
$SIDEBAR_MENU.find('a').filter(function () {
return this.href == CURRENT_URL;
}).parent('li').addClass('current-page').parents('ul').slideDown(function() {
setContentHeight();
}).parent().addClass('active');
Does removing the above script solve the issue?
from yii2-gentelella.
@prabowomurti Your solution looks like not bad. I'll check it. But also you can make a pull request. It would be nice.
from yii2-gentelella.
Related Issues (20)
- Use proper @bower alias.
- Proper way to include animate.css in login page HOT 2
- RTL Support HOT 3
- Create collapsible widget HOT 3
- Demo code in @bower/gentelella/build/js/custom.js HOT 3
- How use the other elements that are not in the \ yiister \ yii2-gentelella \ widgets \ HOT 1
- Could not get this to work HOT 3
- Overlaping modals closing all modals HOT 1
- Bootstrap progressbar missing HOT 6
- Menu auto open HOT 2
- Error on install yii2-gentelella HOT 1
- how to set an custom icon for menu items?
- Sub-menu is not opened when `menu_toggle` is collapsed
- A circular dependency is detected for bundle 'yii\web\YiiAsset'
- Update Fontawesome HOT 1
- не работает js скрипт HOT 1
- no matching package found. HOT 2
- font awesome is outta date
- welp
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from yii2-gentelella.