mirror of
https://github.com/squidfunk/mkdocs-material.git
synced 2026-08-04 19:45:08 -04:00
Prefixed tabs and instant feature flags with 'navigation.*'
This commit is contained in:
@@ -400,7 +400,10 @@ export function initialize(config: unknown) {
|
||||
})
|
||||
|
||||
/* Enable instant loading, if not on file:// protocol */
|
||||
if (config.features.includes("instant") && location.protocol !== "file:") {
|
||||
if (
|
||||
config.features.includes("navigation.instant") &&
|
||||
location.protocol !== "file:"
|
||||
) {
|
||||
|
||||
/* Fetch sitemap and extract URL whitelist */
|
||||
base$
|
||||
|
||||
@@ -30,8 +30,8 @@ import { SearchIndex, SearchTransformFn } from "integrations"
|
||||
* Feature flags
|
||||
*/
|
||||
export type Feature =
|
||||
| "tabs" /* Tabs navigation */
|
||||
| "instant" /* Instant loading
|
||||
| "navigation.tabs" /* Tabs navigation */
|
||||
| "navigation.instant" /* Instant loading
|
||||
|
||||
/* ------------------------------------------------------------------------- */
|
||||
|
||||
|
||||
@@ -234,7 +234,7 @@
|
||||
|
||||
<!-- Tabs navigation -->
|
||||
{% block tabs %}
|
||||
{% if "tabs" in config.theme.features %}
|
||||
{% if "navigation.tabs" in config.theme.features %}
|
||||
{% include "partials/tabs.html" %}
|
||||
{% endif %}
|
||||
{% endblock %}
|
||||
|
||||
Reference in New Issue
Block a user