eworm / big-kahuna Goto Github PK
View Code? Open in Web Editor NEWA flexible Wordpress style menu addon for Statamic
Home Page: https://statamic.com/marketplace/addons/big-kahuna
A flexible Wordpress style menu addon for Statamic
Home Page: https://statamic.com/marketplace/addons/big-kahuna
I think if a child menu element is the currently active page, the parent menu element should also have an active state. This way the parent nav item can show an active state for a child item that's hidden in a dropdown.
As title suggests... should be an option.
I'm using the Spock addon to manage content, and none of BigKahuna's changes will be staged. After reading Statamic's addon docs, it looks like the issue could be due to one of these:
$this->storage->putJSON
does not fire one of the events Spock is listening for https://docs.statamic.com/addons/helpers#storage-put-jsonCould be related to this issue: statamic/spock#35
thanks!
External links should have target="_blank"
or make it an option.
Currently, if a menu used in a template is deleted, the whole site crashes.
Is there already a way to check to see if a menu exists?
Another option could be to protect a created menu so it isn't accidentally deleted through the CMS.
I noticed we're listing this as a field type and using that structure. I don't know if it makes sense to make BK selectable from the field types menu, when creating a field set.
Was this intentional or should we remove that aspect of it?
I get this error in my logs, which I assume is referring to this line:
https://github.com/Eworm/big-kahuna/blob/master/BigKahuna/BigKahunaController.php#L296
I can't get any search results or pages listing in the search box. I took a look under the hood and this is the url that is getting used:
http://club-local:8888/cp/addons/big-kahuna/allpages?locale=
With the locale being included it returns nothing. How can I set a default locale or search with locale?
If the filter list has quite a lot of items in it, it creates a large space at the bottom of the page. It also creates a weird page jump when clicking on checkboxes to add items to a menu.
Steps to reproduce:
This app is great. I would have bought it today if it had a couple more features...
This app needs the ability to customize the wrapper UL elements with custom classes (and submenu UL elements)
At the very least, you should be able to build your own menu templates simply using variables output by this plugin (rather than being required to use the native (and rather restrictive) {{ nav }} tag.
Needs the ability to add carets or icons for dropdown elements. (Or just put them in a custom template or partial) (You COULD add them as CSS elements, I know, but sometimes you're working with other people's code, so you want to work smarter not harder, and build around what they gave you)
Needs the ability to customize the global LI and submenu UL and LI classes (classes for all menu elements, rather than customizing every menu item individually) (Or just add them to a custom template or partial) OR at least bulk edit the classes on the individual elements.
Needs the ability to have the same menu structure with different wrapper (UL and LI) classes. Some responsive menus require the same menu classed differently in the mobile view.
With just a few tweaks, this could easily be a core-worthy component for Statamic... but it's not QUITE there yet. Good work getting it this far.
Hi - I have had Big Kahuna installed previously, deleted it, now reinstalled (after the page delete bug fix) - but I get an error when going to the menu page.
ErrorException in BigKahunaController.php line 37:
Undefined index: locale
in BigKahunaController.php line 37
at HandleExceptions->handleError('8', 'Undefined index: locale', '/Users/paulburgess/Websites/motive-v2/site/addons/BigKahuna/BigKahunaController.php', '37', array('request' => object(Request), 'menus_storage' =>... etc.
Screenshot: http://dlrg.co/fe151e572066
My menus don't render on our staging sites, only on our local setups. I assumed this was because we hadn't entered license keys yet, but we have them in there now and no HTML is rendered. I've confirmed the addon is "installed" and license key is valid for the domain. Any suggestions?
Sort of like a lot of WP plugins do. The free version would be limited to 1 menu, but have all other features to. Any thoughts on how to achieve this? The ideal situation would be to keep everything in 1 repo.
We could also add the trial option, which means making this repo public. Since I don't know enough about the technical aspects of the trial option I'm a bit scared of doing that. Would this allow someone to just remove some code and use the addon for free?
Should we add a settings page to set defaults for all of the class names and such? Then allow them to be overridden on a per-menu basis?
Does it support Statamic 3? Please advise.
Hello Eworm !
The last version seems to not set the default active class.
There is no error, but there is no class added when the current URL is one of the item menu.
For example :
First <li> element should have the is--active, but don't.
From code :
{{ big_kahuna
menu="menu-principal"
class="main-nav text-sm flex lg:flex-row lg:flex-grow"
item_class="burger-item flex leading-none mt-4 font-medium lg:flex-row lg:mt-0 lg:mr-8"
}}
Environment :
So users can target a specific link using css.
If I have a page added to a BK menu, and I change the "slug" of it, which changes the URL, the BK menu has the old URL saved in the JSON file, which is now incorrect.
FIX: If a page is not a custom link, the tag should retrieve the latest slug from the ID of the page, using the Entry class or something.
Saw a bunch of these errors on my live site log files.
ErrorException: Undefined variable: isactive
in /var/www/html/blabla/site/addons/BigKahuna/BigKahunaTags.php:79
This block of code seems problematic.
if ($content) {
$isactive = '';
...
}
$html .= '<li class="' . $itemClass . $isParent . $isactive . $myClassname . '">'; // line 79
The $isactive
variable doesn't get set somehow. what's the possibility of $content
being empty/undefined?
This does not break my site though. At least not that i know of. Maybe this error happens on some deeply buried pages somewhere. Not sure. Statamic's log file is not very informative in this case.
I'm running Statamic 2.11.7 and BigKahuna 1.4.5
Hello,
The plugin has a problem with new version since it saved json data in storage with a key url that will contain the absolute URL website.
When switching between differents env it broke statamic :(
I need actually absolute url for SEO and static cache plugin and other stuff, could you please update big-kahuna to save only relative url ?
Hi, here's an example.
Many thanks!
As a site grows with a lot of Posts/Entries, the filter menu becomes a little tough to work through, even with the search bar. Let's chat about how we can make the filter system a little more robust.
It doesn't now, so I can't remove all items now.
This came about when a client tried creating a Custom URL to link to a hash ID on one of the site's pages, but I can reproducing it with any url, such as https://github.com
. The BK tag will not render if a Custom URL is the first child of a Pages URL.
Given: I have a menu with at least one Pages URL
When: I create a menu item with a Custom URL as a child of an existing Pages URL
Then: I expect to be able to reorder it to any index
BUT: If the item is the first child of the Pages URL, the site throws this error:
FatalThrowableError in BigKahunaTags.php line 105: Call to a member function absoluteUrl() on null
I don't see any localization/translation option when creating menus. Switching locales also doesn't have any effect on the frontend. It only show the default language.
Is it supported? Any plans for this? Pls forgive me in advanced if i missed it.
Thx.
The addon currently includes a composer.json
file without defining any dependencies. The presence of this file makes it necessary to run php please update:addons
in order to install the addon. This should only be necessary if any dependencies must be installed. Thus, removing the composer file simplifies the installation for users. :)
P.S. Thanks for creating this addon, it rocks! ๐
Cheers
But not link the title, otherwise it's too close to the drag element, which would probably result in people clicking on it when they want to drag & drop.
Let's not forget about people with disabilities!
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.