@webquark/core 1.1.0-dev.5 → 1.1.0-dev.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +20 -3
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/q-navbar.cjs.entry.js +222 -4
- package/dist/cjs/webquark.cjs.js +1 -1
- package/dist/collection/components/layout/navbar/navbar.css +119 -0
- package/dist/collection/components/layout/navbar/navbar.js +280 -4
- package/dist/collection/components/layout/navbar/test/navbar.cmp.test.js +317 -1
- package/dist/components/q-navbar.js +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/esm/q-navbar.entry.js +222 -4
- package/dist/esm/webquark.js +1 -1
- package/dist/playground/build/p-0aecd9b1.entry.js +1 -0
- package/dist/playground/build/webquark.esm.js +1 -1
- package/dist/playground/playground/specs/q-navbar.sandbox.json +8 -0
- package/dist/types/components/layout/navbar/navbar.d.ts +27 -1
- package/dist/types/components/layout/navbar/navbar.types.d.ts +2 -0
- package/dist/types/components.d.ts +24 -2
- package/dist/types/index.d.ts +1 -1
- package/dist/webquark/p-0aecd9b1.entry.js +1 -0
- package/dist/webquark/webquark.esm.js +1 -1
- package/package.json +1 -1
- package/scripts/wq-switch/README.md +39 -11
- package/scripts/wq-switch/dist/index.js +31 -18
- package/scripts/wq-switch/dist/setup.js +31 -15
- package/dist/playground/build/p-fdd85ce4.entry.js +0 -1
- package/dist/webquark/p-fdd85ce4.entry.js +0 -1
|
@@ -4,6 +4,26 @@
|
|
|
4
4
|
var import_node_fs = require("node:fs");
|
|
5
5
|
var import_node_path = require("node:path");
|
|
6
6
|
var names = ["@webquark/core", "@webquark/angular", "@webquark/react"];
|
|
7
|
+
var configName = ".webquark.json";
|
|
8
|
+
function readWebQuarkConfig(root) {
|
|
9
|
+
const file = import_node_path.join(root, configName);
|
|
10
|
+
if (!import_node_fs.existsSync(file))
|
|
11
|
+
return {};
|
|
12
|
+
const value = json(file);
|
|
13
|
+
if (!value || typeof value !== "object" || Array.isArray(value))
|
|
14
|
+
throw new Error(`Invalid ${configName}; expected a JSON object.`);
|
|
15
|
+
return value;
|
|
16
|
+
}
|
|
17
|
+
function readSwitchConfig(root) {
|
|
18
|
+
const document = readWebQuarkConfig(root);
|
|
19
|
+
const value = document["wq-switch"];
|
|
20
|
+
if (value === undefined)
|
|
21
|
+
return;
|
|
22
|
+
if (!value || typeof value !== "object" || Array.isArray(value) || value.version !== 1 || typeof value.source !== "string" || value.preferredVersion !== undefined && typeof value.preferredVersion !== "string") {
|
|
23
|
+
throw new Error(`Invalid WebQuark wq-switch configuration; existing configuration was not overwritten.`);
|
|
24
|
+
}
|
|
25
|
+
return value;
|
|
26
|
+
}
|
|
7
27
|
function json(file) {
|
|
8
28
|
return JSON.parse(import_node_fs.readFileSync(file, "utf8"));
|
|
9
29
|
}
|
|
@@ -37,14 +57,11 @@ function validateSource(source) {
|
|
|
37
57
|
return root;
|
|
38
58
|
}
|
|
39
59
|
function sourceFor(root) {
|
|
40
|
-
const
|
|
41
|
-
if (!
|
|
60
|
+
const config = readSwitchConfig(root);
|
|
61
|
+
if (!config)
|
|
42
62
|
throw new Error("First run: wq-setup");
|
|
43
|
-
const config = json(file);
|
|
44
|
-
if (config.version !== 1 || typeof config.source !== "string")
|
|
45
|
-
throw new Error("Invalid .wq-switch.json. Run setup again.");
|
|
46
63
|
if (!config.source.trim())
|
|
47
|
-
throw new Error('Set source
|
|
64
|
+
throw new Error('Set source inside "wq-switch" in .webquark.json to your WebQuark repository, or run wq-setup --source "path/to/WebQuark".');
|
|
48
65
|
return validateSource(import_node_path.resolve(root, config.source));
|
|
49
66
|
}
|
|
50
67
|
function selectedPackages(root) {
|
|
@@ -273,10 +290,9 @@ function setup(root, source) {
|
|
|
273
290
|
selectedPackages(root);
|
|
274
291
|
if (readState(root))
|
|
275
292
|
throw new Error("Run wq-switch npm before changing configuration.");
|
|
276
|
-
const file = import_node_path3.join(root,
|
|
277
|
-
const
|
|
278
|
-
|
|
279
|
-
throw new Error("Invalid .wq-switch.json; existing configuration was not overwritten.");
|
|
293
|
+
const file = import_node_path3.join(root, configName);
|
|
294
|
+
const document = readWebQuarkConfig(root);
|
|
295
|
+
const previous = readSwitchConfig(root);
|
|
280
296
|
const pkg = manifest(root);
|
|
281
297
|
const scripts = { "wq-sandbox": "wq-sandbox", "wq-switch": "wq-switch" };
|
|
282
298
|
for (const [name, command] of Object.entries(scripts)) {
|
|
@@ -289,21 +305,21 @@ function setup(root, source) {
|
|
|
289
305
|
source: source === undefined ? previous?.source ?? "" : validateSource(import_node_path3.resolve(root, source)),
|
|
290
306
|
preferredVersion: previous?.preferredVersion ?? pkg.dependencies?.["@webquark/core"] ?? pkg.devDependencies["@webquark/core"]
|
|
291
307
|
};
|
|
292
|
-
writeJson(file, config);
|
|
308
|
+
writeJson(file, { ...document, "wq-switch": config });
|
|
293
309
|
writeJson(import_node_path3.join(root, "package.json"), { ...pkg, scripts: { ...pkg.scripts, ...scripts } });
|
|
294
310
|
const ignore = import_node_path3.join(root, ".gitignore");
|
|
295
311
|
const current = import_node_fs3.existsSync(ignore) ? import_node_fs3.readFileSync(ignore, "utf8") : "";
|
|
296
|
-
const missing = ["/.
|
|
312
|
+
const missing = ["/.webquark.json", "/.wq-switch/", "/node_modules/"].filter((line) => !current.split(/\r?\n/).includes(line));
|
|
297
313
|
if (missing.length)
|
|
298
314
|
import_node_fs3.appendFileSync(ignore, `
|
|
299
315
|
# Local WebQuark development
|
|
300
316
|
` + missing.join(`
|
|
301
317
|
`) + `
|
|
302
318
|
`);
|
|
303
|
-
console.log(`Created/updated .
|
|
319
|
+
console.log(`Created/updated .webquark.json and package scripts.
|
|
304
320
|
Preferred release: ${config.preferredVersion}
|
|
305
321
|
${config.source ? `Source: ${config.source}
|
|
306
|
-
Next: bun run wq-switch local` : "Next: fill in source in .
|
|
322
|
+
Next: bun run wq-switch local` : "Next: fill in wq-switch.source in .webquark.json before switching locally."}
|
|
307
323
|
Sandbox: bun run wq-sandbox
|
|
308
324
|
Status: bun run wq-switch status`);
|
|
309
325
|
}
|
|
@@ -444,8 +460,6 @@ Restart the consumer dev server.`);
|
|
|
444
460
|
}
|
|
445
461
|
|
|
446
462
|
// scripts/wq-switch/commands/status.ts
|
|
447
|
-
var import_node_fs5 = require("node:fs");
|
|
448
|
-
var import_node_path5 = require("node:path");
|
|
449
463
|
function status(root) {
|
|
450
464
|
const state = readState(root);
|
|
451
465
|
let broken = false, local2 = 0;
|
|
@@ -466,8 +480,7 @@ function status(root) {
|
|
|
466
480
|
}
|
|
467
481
|
const pending = hasJournal(root);
|
|
468
482
|
const mode = pending ? "RECOVERY NEEDED" : broken ? "BROKEN" : state ? local2 === state.entries.length ? "LOCAL" : "MIXED" : "NPM / UNMANAGED";
|
|
469
|
-
const
|
|
470
|
-
const config = import_node_fs5.existsSync(file) ? json(file) : undefined;
|
|
483
|
+
const config = readSwitchConfig(root);
|
|
471
484
|
console.log(`Mode: ${mode}
|
|
472
485
|
Source: ${config?.source || "not configured"}
|
|
473
486
|
Preferred release: ${config?.preferredVersion ?? "not configured"}
|
|
@@ -4,6 +4,26 @@
|
|
|
4
4
|
var import_node_fs = require("node:fs");
|
|
5
5
|
var import_node_path = require("node:path");
|
|
6
6
|
var names = ["@webquark/core", "@webquark/angular", "@webquark/react"];
|
|
7
|
+
var configName = ".webquark.json";
|
|
8
|
+
function readWebQuarkConfig(root) {
|
|
9
|
+
const file = import_node_path.join(root, configName);
|
|
10
|
+
if (!import_node_fs.existsSync(file))
|
|
11
|
+
return {};
|
|
12
|
+
const value = json(file);
|
|
13
|
+
if (!value || typeof value !== "object" || Array.isArray(value))
|
|
14
|
+
throw new Error(`Invalid ${configName}; expected a JSON object.`);
|
|
15
|
+
return value;
|
|
16
|
+
}
|
|
17
|
+
function readSwitchConfig(root) {
|
|
18
|
+
const document = readWebQuarkConfig(root);
|
|
19
|
+
const value = document["wq-switch"];
|
|
20
|
+
if (value === undefined)
|
|
21
|
+
return;
|
|
22
|
+
if (!value || typeof value !== "object" || Array.isArray(value) || value.version !== 1 || typeof value.source !== "string" || value.preferredVersion !== undefined && typeof value.preferredVersion !== "string") {
|
|
23
|
+
throw new Error(`Invalid WebQuark wq-switch configuration; existing configuration was not overwritten.`);
|
|
24
|
+
}
|
|
25
|
+
return value;
|
|
26
|
+
}
|
|
7
27
|
function json(file) {
|
|
8
28
|
return JSON.parse(import_node_fs.readFileSync(file, "utf8"));
|
|
9
29
|
}
|
|
@@ -37,14 +57,11 @@ function validateSource(source) {
|
|
|
37
57
|
return root;
|
|
38
58
|
}
|
|
39
59
|
function sourceFor(root) {
|
|
40
|
-
const
|
|
41
|
-
if (!
|
|
60
|
+
const config = readSwitchConfig(root);
|
|
61
|
+
if (!config)
|
|
42
62
|
throw new Error("First run: wq-setup");
|
|
43
|
-
const config = json(file);
|
|
44
|
-
if (config.version !== 1 || typeof config.source !== "string")
|
|
45
|
-
throw new Error("Invalid .wq-switch.json. Run setup again.");
|
|
46
63
|
if (!config.source.trim())
|
|
47
|
-
throw new Error('Set source
|
|
64
|
+
throw new Error('Set source inside "wq-switch" in .webquark.json to your WebQuark repository, or run wq-setup --source "path/to/WebQuark".');
|
|
48
65
|
return validateSource(import_node_path.resolve(root, config.source));
|
|
49
66
|
}
|
|
50
67
|
function selectedPackages(root) {
|
|
@@ -275,10 +292,9 @@ function setup(root, source) {
|
|
|
275
292
|
selectedPackages(root);
|
|
276
293
|
if (readState(root))
|
|
277
294
|
throw new Error("Run wq-switch npm before changing configuration.");
|
|
278
|
-
const file = import_node_path3.join(root,
|
|
279
|
-
const
|
|
280
|
-
|
|
281
|
-
throw new Error("Invalid .wq-switch.json; existing configuration was not overwritten.");
|
|
295
|
+
const file = import_node_path3.join(root, configName);
|
|
296
|
+
const document = readWebQuarkConfig(root);
|
|
297
|
+
const previous = readSwitchConfig(root);
|
|
282
298
|
const pkg = manifest(root);
|
|
283
299
|
const scripts = { "wq-sandbox": "wq-sandbox", "wq-switch": "wq-switch" };
|
|
284
300
|
for (const [name, command] of Object.entries(scripts)) {
|
|
@@ -291,21 +307,21 @@ function setup(root, source) {
|
|
|
291
307
|
source: source === undefined ? previous?.source ?? "" : validateSource(import_node_path3.resolve(root, source)),
|
|
292
308
|
preferredVersion: previous?.preferredVersion ?? pkg.dependencies?.["@webquark/core"] ?? pkg.devDependencies["@webquark/core"]
|
|
293
309
|
};
|
|
294
|
-
writeJson(file, config);
|
|
310
|
+
writeJson(file, { ...document, "wq-switch": config });
|
|
295
311
|
writeJson(import_node_path3.join(root, "package.json"), { ...pkg, scripts: { ...pkg.scripts, ...scripts } });
|
|
296
312
|
const ignore = import_node_path3.join(root, ".gitignore");
|
|
297
313
|
const current = import_node_fs3.existsSync(ignore) ? import_node_fs3.readFileSync(ignore, "utf8") : "";
|
|
298
|
-
const missing = ["/.
|
|
314
|
+
const missing = ["/.webquark.json", "/.wq-switch/", "/node_modules/"].filter((line) => !current.split(/\r?\n/).includes(line));
|
|
299
315
|
if (missing.length)
|
|
300
316
|
import_node_fs3.appendFileSync(ignore, `
|
|
301
317
|
# Local WebQuark development
|
|
302
318
|
` + missing.join(`
|
|
303
319
|
`) + `
|
|
304
320
|
`);
|
|
305
|
-
console.log(`Created/updated .
|
|
321
|
+
console.log(`Created/updated .webquark.json and package scripts.
|
|
306
322
|
Preferred release: ${config.preferredVersion}
|
|
307
323
|
${config.source ? `Source: ${config.source}
|
|
308
|
-
Next: bun run wq-switch local` : "Next: fill in source in .
|
|
324
|
+
Next: bun run wq-switch local` : "Next: fill in wq-switch.source in .webquark.json before switching locally."}
|
|
309
325
|
Sandbox: bun run wq-sandbox
|
|
310
326
|
Status: bun run wq-switch status`);
|
|
311
327
|
}
|
|
@@ -314,7 +330,7 @@ Status: bun run wq-switch status`);
|
|
|
314
330
|
async function main() {
|
|
315
331
|
const args = process.argv.slice(2);
|
|
316
332
|
const help = `wq-setup [--source <path>]
|
|
317
|
-
Creates .
|
|
333
|
+
Creates .webquark.json and wq-sandbox/wq-switch package scripts in the consuming project.`;
|
|
318
334
|
if (args.length === 1 && ["--help", "-h"].includes(args[0])) {
|
|
319
335
|
console.log(help);
|
|
320
336
|
return;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{r as e,c as t,a,h as n}from"./p-DbGG9Q40.js";import{i}from"./p-CGZPmEUB.js";import{s as o}from"./p-BJiYCN3i.js";let s=0;const r=class{constructor(a){e(this,a),this.qSelect=t(this,"qSelect"),this.qMenuToggle=t(this,"qMenuToggle")}get el(){return a(this)}brand;logoSrc;logoAlt="";brandHref="/";items=[];value;activeValue="";edge="top";sticky=!1;compact=!1;transparent=!1;bordered=!0;mobileMode="menu";mobileLabel="Menu";ariaLabel=null;qSelect;qMenuToggle;menuOpen=!1;hasMobileContent=!1;instanceId=++s;primaryNavId=`q-navbar-primary-nav-${this.instanceId}`;mobilePanelId=`q-navbar-mobile-panel-${this.instanceId}`;dismissListenersActive=!1;disconnectedCallback(){this.removeMenuDismissListeners()}get parsedItems(){return o(this.items,[],"QNavbar").flatMap((e=>{if("string"==typeof e){const t=e.trim();return t?[{label:t,value:t}]:[]}return e&&"object"==typeof e&&"string"==typeof e.label?[e]:[]}))}handleMenuToggle=()=>{this.setMenuOpen(!this.menuOpen)};handleMenuClose=()=>{this.setMenuOpen(!1)};setMenuOpen(e){this.menuOpen!==e&&(this.menuOpen=e,this.qMenuToggle.emit(e),e?this.addMenuDismissListeners():this.removeMenuDismissListeners())}addMenuDismissListeners(){this.dismissListenersActive||"undefined"==typeof document||"undefined"==typeof window||(document.addEventListener("keydown",this.handleDocumentKeyDown),window.addEventListener("click",this.handleWindowClick),this.dismissListenersActive=!0)}removeMenuDismissListeners(){this.dismissListenersActive&&"undefined"!=typeof document&&"undefined"!=typeof window&&(document.removeEventListener("keydown",this.handleDocumentKeyDown),window.removeEventListener("click",this.handleWindowClick),this.dismissListenersActive=!1)}handleDocumentKeyDown=e=>{"Escape"===e.key&&this.handleMenuClose()};handleWindowClick=e=>{const t="function"==typeof e.composedPath?e.composedPath():[];t.includes(this.el)||!t.length&&e.target instanceof Node&&this.el.contains(e.target)||this.handleMenuClose()};handleItemClick=(e,t)=>{if(e.disabled)return t.preventDefault(),void t.stopPropagation();this.qSelect.emit({value:e.value||e.href||e.label,label:e.label,item:e,originalEvent:t}),this.handleMenuClose()};handleMobileSlotChange=()=>{this.hasMobileContent=!!this.el.querySelector('[slot="mobile-nav"], [slot="mobile-actions"]')};setIconAttribute(e,t,a){if(null==a||""===a)return void e.removeAttribute(t);const n=String(a);e.getAttribute(t)!==n&&e.setAttribute(t,n)}syncIconAttributes=(e,t)=>{e&&t.icon&&(this.setIconAttribute(e,"name",t.icon),this.setIconAttribute(e,"library",t.iconLib||"lucide"),this.setIconAttribute(e,"size",t.iconSize||"sm"),this.setIconAttribute(e,"local-path",t.iconLocalPath))};renderBrand(){const e=n("span",{class:"brand-content"},this.logoSrc&&n("img",{class:"brand-logo",src:this.logoSrc,alt:this.logoAlt||(this.brand?"":"Brand")}),this.brand&&n("span",{class:"brand-text"},this.brand));return n("a",{class:"brand-link",href:this.brandHref,part:"brand"},n("slot",{name:"brand"},e))}renderNavItem({item:e,key:t}){const a=this.value??this.activeValue,i=e.active||!!a&&(e.value===a||e.href===a),o=!!e.iconOnly&&!!e.icon,s=o?e.ariaLabel||e.label:void 0,r=e.addonPlacement||"top-end",d={"nav-item":!0,"is-active":i,"is-disabled":!!e.disabled,"is-icon-only":o},l=[e.icon&&n("q-icon",{class:"nav-item__icon",name:e.icon,library:e.iconLib||"lucide",localPath:e.iconLocalPath,size:e.iconSize||"sm",ref:t=>this.syncIconAttributes(t,e)}),n("span",{class:"nav-item__label","aria-hidden":o?"true":void 0},e.label)],b=e.addonSlot?n("span",{class:`nav-item__addon is-${r}`,part:"item-addon"},n("slot",{name:e.addonSlot})):null;return n("span",{key:t,class:{"nav-item-shell":!0,"is-icon-only":o}},e.href?n("a",{class:d,href:e.disabled?void 0:e.href,target:e.disabled?void 0:e.target,rel:"_blank"===e.target?"noopener noreferrer":void 0,"aria-current":i?"page":void 0,"aria-disabled":e.disabled?"true":"false","aria-label":s,onClick:t=>this.handleItemClick(e,t)},l):n("button",{class:d,type:"button",disabled:e.disabled,"aria-current":i?"page":void 0,"aria-label":s,onClick:t=>this.handleItemClick(e,t)},l),b)}renderNavItems(e){return e.map((e=>this.renderNavItem(e)))}render(){const e=i(this.parsedItems,(e=>e.value),{warningContext:"q-navbar.items"}),t=e.length>0,a=this.ariaLabel?.trim()||void 0;return n("div",{key:"09ac3cccab41f89adaae0d308067ed0952ce1eb2",class:{navbar:!0,"is-open":this.menuOpen,"is-sticky":this.sticky,"is-compact":this.compact,"is-transparent":this.transparent,"is-bordered":this.bordered},part:"navbar"},n("div",{key:"2336b4b12aed62d0ba014f7a1e34b22e6952c444",class:"navbar-row"},this.renderBrand(),n("nav",{key:"2516df77be1739a34ab5b67296c11db776934261",id:this.primaryNavId,class:"desktop-nav","aria-label":a||"Primary navigation",part:"nav"},t&&this.renderNavItems(e),n("slot",{key:"d022935aebf6d62b6c12328d125e914a7a13b843",name:"nav"})),n("div",{key:"3f18ffcdcc918e56856df176810a049a00111886",class:"desktop-actions",part:"actions"},n("slot",{key:"8ebc6706ac2ff1006b262978e6f870a15ed1f5d5",name:"actions"})),n("button",{key:"5f0739a91b79594ff62f769498d3ee95004c55d9",class:"menu-button",type:"button","aria-label":this.mobileLabel,"aria-expanded":this.menuOpen?"true":"false","aria-controls":`${this.primaryNavId} ${this.mobilePanelId}`,"aria-haspopup":"true",onClick:this.handleMenuToggle,part:"menu-button"},n("span",{key:"ac577f3d6b9d5505dd372a23ec7e23a41030e05b"}),n("span",{key:"fdc13b36bff79c44df72b602078a4067db31319e"}),n("span",{key:"bcde22fc716c623002f723e99f14412a111420ad"}))),n("div",{key:"2265e94f7236b62de6e3f237dbe81cda556f3da2",id:this.mobilePanelId,class:{"mobile-panel":!0,"has-content":this.hasMobileContent},part:"mobile-panel"},n("nav",{key:"1166d0d59ff6a28eab548c971a94ea02199da5c0",class:"mobile-nav","aria-label":a||"Mobile navigation"},n("slot",{key:"812bc68a6e9f7496b8d7ea36a28fd3d83d0de780",name:"mobile-nav",onSlotchange:this.handleMobileSlotChange})),n("div",{key:"8ec6523d8098e013864f4dcc07cb6abccf332e34",class:"mobile-actions"},n("slot",{key:"92a75d93272c462624711ac2491f4ae79cf33651",name:"mobile-actions",onSlotchange:this.handleMobileSlotChange}))))}};r.style=":host{display:block;width:100%;box-sizing:border-box;z-index:var(--q-navbar-z-index, 100)}:host([edge='top']){--q-navbar-edge-padding:max(0px, env(safe-area-inset-top, 0px)) 24px 0;--q-navbar-edge-compact-padding:max(0px, env(safe-area-inset-top, 0px)) 16px 0;--q-navbar-edge-mobile-padding:max(0px, env(safe-area-inset-top, 0px)) 16px 0}:host([edge='bottom']){--q-navbar-edge-padding:0 24px max(0px, env(safe-area-inset-bottom, 0px));--q-navbar-edge-compact-padding:0 16px max(0px, env(safe-area-inset-bottom, 0px));--q-navbar-edge-mobile-padding:0 16px max(0px, env(safe-area-inset-bottom, 0px))}:host([edge='left']),:host([edge='right']){width:auto;height:100%}:host([edge='left']){--q-navbar-edge-padding:16px 16px 16px max(16px, env(safe-area-inset-left, 0px));--q-navbar-edge-compact-padding:12px 12px 12px max(12px, env(safe-area-inset-left, 0px))}:host([edge='right']){--q-navbar-edge-padding:16px max(16px, env(safe-area-inset-right, 0px)) 16px 16px;--q-navbar-edge-compact-padding:12px max(12px, env(safe-area-inset-right, 0px)) 12px 12px}:host([sticky][edge='top']){position:sticky;top:0}:host([sticky][edge='right']){position:sticky;right:0}:host([sticky][edge='bottom']){position:sticky;bottom:0}:host([sticky][edge='left']){position:sticky;left:0}.navbar{width:100%;color:var(--q-navbar-fg, var(--q-fg-base, #f9fafb));background:var(--q-navbar-bg, var(--q-bg-surface-1, #1f2937));font-family:var(--q-font-family, inherit);box-sizing:border-box}:host([edge='left']) .navbar,:host([edge='right']) .navbar{height:100%}.navbar.is-transparent{background:transparent}:host([edge='top']) .navbar.is-bordered{border-bottom:var(--q-navbar-border, 1px solid var(--q-border-color, #374151))}:host([edge='right']) .navbar.is-bordered{border-left:var(--q-navbar-border, 1px solid var(--q-border-color, #374151))}:host([edge='bottom']) .navbar.is-bordered{border-top:var(--q-navbar-border, 1px solid var(--q-border-color, #374151))}:host([edge='left']) .navbar.is-bordered{border-right:var(--q-navbar-border, 1px solid var(--q-border-color, #374151))}.navbar-row{display:flex;align-items:center;gap:var(--q-navbar-gap, 20px);min-height:var(--q-navbar-height, 64px);padding:var(--q-navbar-padding, var(--q-navbar-edge-padding, 0 24px));box-sizing:border-box}.is-compact .navbar-row{min-height:var(--q-navbar-compact-height, 52px);padding:var(--q-navbar-compact-padding, var(--q-navbar-edge-compact-padding, 0 16px))}:host([edge='left']) .navbar-row,:host([edge='right']) .navbar-row{flex-direction:column;align-items:stretch;width:var(--q-navbar-width, 240px);height:100%;min-height:0}:host([edge='left']) .is-compact .navbar-row,:host([edge='right']) .is-compact .navbar-row{width:var(--q-navbar-compact-width, 200px);min-height:0}.brand-link{display:inline-flex;align-items:center;min-width:0;color:inherit;text-decoration:none}.brand-content{display:inline-flex;align-items:center;gap:10px;min-width:0}.brand-logo{width:var(--q-navbar-logo-size, 32px);height:var(--q-navbar-logo-size, 32px);object-fit:contain;flex:0 0 auto}.brand-text{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:var(--q-navbar-brand-size, 1rem);font-weight:var(--q-font-weight-bold, 600)}.desktop-nav{display:flex;align-items:center;gap:var(--q-navbar-nav-gap, 6px);min-width:0;flex:1 1 auto}.desktop-actions{display:flex;align-items:center;justify-content:flex-end;gap:var(--q-navbar-action-gap, 8px);flex:0 0 auto}.nav-item-shell{position:relative;display:inline-flex;align-items:center;justify-content:center;justify-self:center;width:var(--q-navbar-item-width, fit-content);min-width:0}.nav-item{box-sizing:border-box;display:inline-flex;align-items:center;justify-content:center;width:var(--q-navbar-item-width, auto);gap:var(--q-navbar-item-gap, 8px);min-height:36px;padding:var(--q-navbar-item-padding, 7px 10px);border:0;border-radius:var(--q-navbar-item-radius, var(--q-radius-md, 7px));color:var(--q-navbar-item-fg, var(--q-fg-muted, #9ca3af));background:transparent;font:inherit;font-size:var(--q-navbar-item-size, 0.9rem);font-weight:var(--q-font-weight-medium, 500);line-height:1.2;text-decoration:none;cursor:pointer;transition:color var(--q-transition-fast, 150ms ease), background var(--q-transition-fast, 150ms ease)}.nav-item__addon{position:absolute;z-index:1;display:inline-flex;max-width:none}.nav-item__addon.is-top-start{inset-block-start:0;inset-inline-start:0;transform:translateY(-50%)}.nav-item__addon.is-top-center{inset-block-start:0;inset-inline-start:50%;transform:translate(-50%, -50%)}.nav-item__addon.is-top-end{inset-block-start:0;inset-inline-end:0;transform:translateY(-50%)}.nav-item__addon.is-bottom-start{inset-block-end:0;inset-inline-start:0;transform:translateY(50%)}.nav-item__addon.is-bottom-center{inset-block-end:0;inset-inline-start:50%;transform:translate(-50%, 50%)}.nav-item__addon.is-bottom-end{inset-block-end:0;inset-inline-end:0;transform:translateY(50%)}.nav-item:hover,.nav-item:focus-visible{color:var(--q-navbar-item-fg-hover, var(--q-fg-base, #f9fafb));background:var(--q-navbar-item-bg-hover, var(--q-bg-surface-2, #374151));outline:none}.nav-item:focus-visible{box-shadow:var(--q-glow-interactive, 0 0 20px rgba(96, 165, 250, 0.3))}.nav-item.is-active{color:var(--q-navbar-item-active-fg, var(--q-color-primary, #60a5fa));background:var(--q-navbar-item-active-bg, color-mix(in srgb, var(--q-color-primary, #60a5fa) 10%, transparent))}.nav-item.is-disabled,.nav-item:disabled{color:var(--q-navbar-item-disabled-fg, var(--q-fg-muted, #9ca3af));cursor:not-allowed;opacity:0.7}.nav-item__icon{flex:0 0 auto}:host([edge='left']) .brand-link,:host([edge='right']) .brand-link,:host([edge='left']) .desktop-nav,:host([edge='right']) .desktop-nav,:host([edge='left']) .desktop-actions,:host([edge='right']) .desktop-actions{width:100%}:host([edge='left']) .desktop-nav,:host([edge='right']) .desktop-nav,:host([edge='left']) .desktop-actions,:host([edge='right']) .desktop-actions{flex-direction:column;align-items:stretch}:host([edge='left']) .desktop-actions,:host([edge='right']) .desktop-actions{justify-content:flex-end}:host([edge='left']) .nav-item,:host([edge='right']) .nav-item{width:100%;justify-content:flex-start}:host([edge='left']) .nav-item-shell,:host([edge='right']) .nav-item-shell{justify-self:stretch;width:100%}:host([edge='left']) .nav-item-shell.is-icon-only,:host([edge='right']) .nav-item-shell.is-icon-only{width:var(--q-navbar-item-icon-only-size, 40px);align-self:center}:host([edge='left']) .nav-item.is-icon-only,:host([edge='right']) .nav-item.is-icon-only{width:var(--q-navbar-item-icon-only-size, 40px);align-self:center;justify-content:center}.nav-item__label{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.nav-item.is-icon-only{min-width:var(--q-navbar-item-icon-only-size, 40px);min-height:var(--q-navbar-item-icon-only-size, 40px);padding:var(--q-navbar-item-icon-only-padding, 8px)}.nav-item.is-icon-only .nav-item__label{display:none}.menu-button{display:none;width:40px;height:40px;align-items:center;justify-content:center;flex-direction:column;gap:4px;border:var(--q-navbar-menu-border, 1px solid var(--q-border-color, #374151));border-radius:var(--q-radius-md, 7px);color:var(--q-navbar-fg, var(--q-fg-base, #f9fafb));background:var(--q-navbar-menu-bg, transparent);cursor:pointer}.menu-button span{display:block;width:18px;height:2px;border-radius:999px;background:currentColor}.mobile-panel{display:none}@media (max-width: 720px){:host([edge='top']) .desktop-actions,:host([edge='bottom']) .desktop-actions{display:none}:host([edge='top']) .navbar-row,:host([edge='bottom']) .navbar-row{flex-wrap:wrap;justify-content:space-between;padding:var(--q-navbar-mobile-padding, var(--q-navbar-edge-mobile-padding, 0 16px))}:host([edge='top'][mobile-mode='menu']) .desktop-nav,:host([edge='bottom'][mobile-mode='menu']) .desktop-nav{display:none;order:3;flex:1 0 100%;flex-direction:column;align-items:stretch;gap:6px}:host([edge='bottom'][mobile-mode='menu']) .desktop-nav{order:-1}:host([edge='top'][mobile-mode='menu']) .navbar.is-open .desktop-nav,:host([edge='bottom'][mobile-mode='menu']) .navbar.is-open .desktop-nav{display:flex}:host([edge='top'][mobile-mode='menu']) .desktop-nav .nav-item-shell,:host([edge='bottom'][mobile-mode='menu']) .desktop-nav .nav-item-shell,:host([edge='top'][mobile-mode='menu']) .desktop-nav .nav-item,:host([edge='bottom'][mobile-mode='menu']) .desktop-nav .nav-item{width:100%}:host([edge='top'][mobile-mode='menu']) .desktop-nav .nav-item,:host([edge='bottom'][mobile-mode='menu']) .desktop-nav .nav-item{justify-content:flex-start}:host([edge='top'][mobile-mode='menu']) .desktop-nav slot[name='nav'],:host([edge='bottom'][mobile-mode='menu']) .desktop-nav slot[name='nav']{display:none}:host([edge='top']) .menu-button,:host([edge='bottom']) .menu-button{display:inline-flex}:host([edge='top']) .mobile-panel,:host([edge='bottom']) .mobile-panel{display:none;padding:var(--q-navbar-mobile-panel-padding, 8px 16px 16px);background:var(--q-navbar-mobile-bg, var(--q-navbar-bg, var(--q-bg-surface-1, #1f2937)))}:host([edge='top']) .mobile-panel{border-top:var(--q-navbar-border, 1px solid var(--q-border-color, #374151))}:host([edge='bottom']) .navbar{display:flex;flex-direction:column-reverse}:host([edge='bottom']) .mobile-panel{border-bottom:var(--q-navbar-border, 1px solid var(--q-border-color, #374151))}:host([edge='top']) .navbar.is-open .mobile-panel.has-content,:host([edge='bottom']) .navbar.is-open .mobile-panel.has-content{display:block}.mobile-nav,.mobile-actions{display:flex;flex-direction:column;gap:6px}.mobile-actions{margin-top:12px}.mobile-nav .nav-item{justify-content:flex-start;width:100%}:host([edge='top'][mobile-mode='inline']) .desktop-nav,:host([edge='bottom'][mobile-mode='inline']) .desktop-nav{display:flex}:host([edge='top'][mobile-mode='inline']) .menu-button,:host([edge='top'][mobile-mode='inline']) .mobile-panel,:host([edge='bottom'][mobile-mode='inline']) .menu-button,:host([edge='bottom'][mobile-mode='inline']) .mobile-panel{display:none}}";export{r as q_navbar}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{r as e,c as t,a,h as n}from"./p-DbGG9Q40.js";import{i}from"./p-CGZPmEUB.js";import{s as o}from"./p-BJiYCN3i.js";let s=0;const r=class{constructor(a){e(this,a),this.qSelect=t(this,"qSelect"),this.qMenuToggle=t(this,"qMenuToggle")}get el(){return a(this)}brand;logoSrc;logoAlt="";brandHref="/";items=[];value;activeValue="";edge="top";sticky=!1;compact=!1;transparent=!1;bordered=!0;mobileMode="menu";mobileLabel="Menu";ariaLabel=null;qSelect;qMenuToggle;menuOpen=!1;hasMobileContent=!1;instanceId=++s;primaryNavId=`q-navbar-primary-nav-${this.instanceId}`;mobilePanelId=`q-navbar-mobile-panel-${this.instanceId}`;dismissListenersActive=!1;disconnectedCallback(){this.removeMenuDismissListeners()}get parsedItems(){return o(this.items,[],"QNavbar").flatMap((e=>{if("string"==typeof e){const t=e.trim();return t?[{label:t,value:t}]:[]}return e&&"object"==typeof e&&"string"==typeof e.label?[e]:[]}))}handleMenuToggle=()=>{this.setMenuOpen(!this.menuOpen)};handleMenuClose=()=>{this.setMenuOpen(!1)};setMenuOpen(e){this.menuOpen!==e&&(this.menuOpen=e,this.qMenuToggle.emit(e),e?this.addMenuDismissListeners():this.removeMenuDismissListeners())}addMenuDismissListeners(){this.dismissListenersActive||"undefined"==typeof document||"undefined"==typeof window||(document.addEventListener("keydown",this.handleDocumentKeyDown),window.addEventListener("click",this.handleWindowClick),this.dismissListenersActive=!0)}removeMenuDismissListeners(){this.dismissListenersActive&&"undefined"!=typeof document&&"undefined"!=typeof window&&(document.removeEventListener("keydown",this.handleDocumentKeyDown),window.removeEventListener("click",this.handleWindowClick),this.dismissListenersActive=!1)}handleDocumentKeyDown=e=>{"Escape"===e.key&&this.handleMenuClose()};handleWindowClick=e=>{const t="function"==typeof e.composedPath?e.composedPath():[];t.includes(this.el)||!t.length&&e.target instanceof Node&&this.el.contains(e.target)||this.handleMenuClose()};handleItemClick=(e,t)=>{if(e.disabled)return t.preventDefault(),void t.stopPropagation();this.qSelect.emit({value:e.value||e.href||e.label,label:e.label,item:e,originalEvent:t}),this.handleMenuClose()};handleMobileSlotChange=()=>{this.hasMobileContent=!!this.el.querySelector('[slot="mobile-nav"], [slot="mobile-actions"]')};setIconAttribute(e,t,a){if(null==a||""===a)return void e.removeAttribute(t);const n=String(a);e.getAttribute(t)!==n&&e.setAttribute(t,n)}syncIconAttributes=(e,t)=>{e&&t.icon&&(this.setIconAttribute(e,"name",t.icon),this.setIconAttribute(e,"library",t.iconLib||"lucide"),this.setIconAttribute(e,"size",t.iconSize||"sm"),this.setIconAttribute(e,"local-path",t.iconLocalPath))};renderBrand(){const e=n("span",{class:"brand-content"},this.logoSrc&&n("img",{class:"brand-logo",src:this.logoSrc,alt:this.logoAlt||(this.brand?"":"Brand")}),this.brand&&n("span",{class:"brand-text"},this.brand));return n("a",{class:"brand-link",href:this.brandHref,part:"brand"},n("slot",{name:"brand"},e))}renderNavItem({item:e,key:t}){const a=this.value??this.activeValue,i=e.active||!!a&&(e.value===a||e.href===a),o=!!e.iconOnly&&!!e.icon,s=o?e.ariaLabel||e.label:void 0,r=e.addonPlacement||"top-end",d={"nav-item":!0,"is-active":i,"is-disabled":!!e.disabled,"is-icon-only":o},l=[e.icon&&n("q-icon",{class:"nav-item__icon",name:e.icon,library:e.iconLib||"lucide",localPath:e.iconLocalPath,size:e.iconSize||"sm",ref:t=>this.syncIconAttributes(t,e)}),n("span",{class:"nav-item__label","aria-hidden":o?"true":void 0},e.label)],b=e.addonSlot?n("span",{class:`nav-item__addon is-${r}`,part:"item-addon"},n("slot",{name:e.addonSlot})):null;return n("span",{key:t,class:{"nav-item-shell":!0,"is-icon-only":o}},e.href?n("a",{class:d,href:e.disabled?void 0:e.href,target:e.disabled?void 0:e.target,rel:"_blank"===e.target?"noopener noreferrer":void 0,"aria-current":i?"page":void 0,"aria-disabled":e.disabled?"true":"false","aria-label":s,onClick:t=>this.handleItemClick(e,t)},l):n("button",{class:d,type:"button",disabled:e.disabled,"aria-current":i?"page":void 0,"aria-label":s,onClick:t=>this.handleItemClick(e,t)},l),b)}renderNavItems(e){return e.map((e=>this.renderNavItem(e)))}render(){const e=i(this.parsedItems,(e=>e.value),{warningContext:"q-navbar.items"}),t=e.length>0,a=this.ariaLabel?.trim()||void 0;return n("div",{key:"09ac3cccab41f89adaae0d308067ed0952ce1eb2",class:{navbar:!0,"is-open":this.menuOpen,"is-sticky":this.sticky,"is-compact":this.compact,"is-transparent":this.transparent,"is-bordered":this.bordered},part:"navbar"},n("div",{key:"2336b4b12aed62d0ba014f7a1e34b22e6952c444",class:"navbar-row"},this.renderBrand(),n("nav",{key:"2516df77be1739a34ab5b67296c11db776934261",id:this.primaryNavId,class:"desktop-nav","aria-label":a||"Primary navigation",part:"nav"},t&&this.renderNavItems(e),n("slot",{key:"d022935aebf6d62b6c12328d125e914a7a13b843",name:"nav"})),n("div",{key:"3f18ffcdcc918e56856df176810a049a00111886",class:"desktop-actions",part:"actions"},n("slot",{key:"8ebc6706ac2ff1006b262978e6f870a15ed1f5d5",name:"actions"})),n("button",{key:"5f0739a91b79594ff62f769498d3ee95004c55d9",class:"menu-button",type:"button","aria-label":this.mobileLabel,"aria-expanded":this.menuOpen?"true":"false","aria-controls":`${this.primaryNavId} ${this.mobilePanelId}`,"aria-haspopup":"true",onClick:this.handleMenuToggle,part:"menu-button"},n("span",{key:"ac577f3d6b9d5505dd372a23ec7e23a41030e05b"}),n("span",{key:"fdc13b36bff79c44df72b602078a4067db31319e"}),n("span",{key:"bcde22fc716c623002f723e99f14412a111420ad"}))),n("div",{key:"2265e94f7236b62de6e3f237dbe81cda556f3da2",id:this.mobilePanelId,class:{"mobile-panel":!0,"has-content":this.hasMobileContent},part:"mobile-panel"},n("nav",{key:"1166d0d59ff6a28eab548c971a94ea02199da5c0",class:"mobile-nav","aria-label":a||"Mobile navigation"},n("slot",{key:"812bc68a6e9f7496b8d7ea36a28fd3d83d0de780",name:"mobile-nav",onSlotchange:this.handleMobileSlotChange})),n("div",{key:"8ec6523d8098e013864f4dcc07cb6abccf332e34",class:"mobile-actions"},n("slot",{key:"92a75d93272c462624711ac2491f4ae79cf33651",name:"mobile-actions",onSlotchange:this.handleMobileSlotChange}))))}};r.style=":host{display:block;width:100%;box-sizing:border-box;z-index:var(--q-navbar-z-index, 100)}:host([edge='top']){--q-navbar-edge-padding:max(0px, env(safe-area-inset-top, 0px)) 24px 0;--q-navbar-edge-compact-padding:max(0px, env(safe-area-inset-top, 0px)) 16px 0;--q-navbar-edge-mobile-padding:max(0px, env(safe-area-inset-top, 0px)) 16px 0}:host([edge='bottom']){--q-navbar-edge-padding:0 24px max(0px, env(safe-area-inset-bottom, 0px));--q-navbar-edge-compact-padding:0 16px max(0px, env(safe-area-inset-bottom, 0px));--q-navbar-edge-mobile-padding:0 16px max(0px, env(safe-area-inset-bottom, 0px))}:host([edge='left']),:host([edge='right']){width:auto;height:100%}:host([edge='left']){--q-navbar-edge-padding:16px 16px 16px max(16px, env(safe-area-inset-left, 0px));--q-navbar-edge-compact-padding:12px 12px 12px max(12px, env(safe-area-inset-left, 0px))}:host([edge='right']){--q-navbar-edge-padding:16px max(16px, env(safe-area-inset-right, 0px)) 16px 16px;--q-navbar-edge-compact-padding:12px max(12px, env(safe-area-inset-right, 0px)) 12px 12px}:host([sticky][edge='top']){position:sticky;top:0}:host([sticky][edge='right']){position:sticky;right:0}:host([sticky][edge='bottom']){position:sticky;bottom:0}:host([sticky][edge='left']){position:sticky;left:0}.navbar{width:100%;color:var(--q-navbar-fg, var(--q-fg-base, #f9fafb));background:var(--q-navbar-bg, var(--q-bg-surface-1, #1f2937));font-family:var(--q-font-family, inherit);box-sizing:border-box}:host([edge='left']) .navbar,:host([edge='right']) .navbar{height:100%}.navbar.is-transparent{background:transparent}:host([edge='top']) .navbar.is-bordered{border-bottom:var(--q-navbar-border, 1px solid var(--q-border-color, #374151))}:host([edge='right']) .navbar.is-bordered{border-left:var(--q-navbar-border, 1px solid var(--q-border-color, #374151))}:host([edge='bottom']) .navbar.is-bordered{border-top:var(--q-navbar-border, 1px solid var(--q-border-color, #374151))}:host([edge='left']) .navbar.is-bordered{border-right:var(--q-navbar-border, 1px solid var(--q-border-color, #374151))}.navbar-row{display:flex;align-items:center;gap:var(--q-navbar-gap, 20px);min-height:var(--q-navbar-height, 64px);padding:var(--q-navbar-padding, var(--q-navbar-edge-padding, 0 24px));box-sizing:border-box}.is-compact .navbar-row{min-height:var(--q-navbar-compact-height, 52px);padding:var(--q-navbar-compact-padding, var(--q-navbar-edge-compact-padding, 0 16px))}:host([edge='left']) .navbar-row,:host([edge='right']) .navbar-row{flex-direction:column;align-items:stretch;width:var(--q-navbar-width, 240px);height:100%;min-height:0}:host([edge='left']) .is-compact .navbar-row,:host([edge='right']) .is-compact .navbar-row{width:var(--q-navbar-compact-width, 200px);min-height:0}.brand-link{display:inline-flex;align-items:center;min-width:0;color:inherit;text-decoration:none}.brand-content{display:inline-flex;align-items:center;gap:10px;min-width:0}.brand-logo{width:var(--q-navbar-logo-size, 32px);height:var(--q-navbar-logo-size, 32px);object-fit:contain;flex:0 0 auto}.brand-text{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:var(--q-navbar-brand-size, 1rem);font-weight:var(--q-font-weight-bold, 600)}.desktop-nav{display:flex;align-items:center;gap:var(--q-navbar-nav-gap, 6px);min-width:0;flex:1 1 auto}.desktop-actions{display:flex;align-items:center;justify-content:flex-end;gap:var(--q-navbar-action-gap, 8px);flex:0 0 auto}.nav-item-shell{position:relative;display:inline-flex;align-items:center;justify-content:center;justify-self:center;width:var(--q-navbar-item-width, fit-content);min-width:0}.nav-item{box-sizing:border-box;display:inline-flex;align-items:center;justify-content:center;width:var(--q-navbar-item-width, auto);gap:var(--q-navbar-item-gap, 8px);min-height:36px;padding:var(--q-navbar-item-padding, 7px 10px);border:0;border-radius:var(--q-navbar-item-radius, var(--q-radius-md, 7px));color:var(--q-navbar-item-fg, var(--q-fg-muted, #9ca3af));background:transparent;font:inherit;font-size:var(--q-navbar-item-size, 0.9rem);font-weight:var(--q-font-weight-medium, 500);line-height:1.2;text-decoration:none;cursor:pointer;transition:color var(--q-transition-fast, 150ms ease), background var(--q-transition-fast, 150ms ease)}.nav-item__addon{position:absolute;z-index:1;display:inline-flex;max-width:none}.nav-item__addon.is-top-start{inset-block-start:0;inset-inline-start:0;transform:translateY(-50%)}.nav-item__addon.is-top-center{inset-block-start:0;inset-inline-start:50%;transform:translate(-50%, -50%)}.nav-item__addon.is-top-end{inset-block-start:0;inset-inline-end:0;transform:translateY(-50%)}.nav-item__addon.is-bottom-start{inset-block-end:0;inset-inline-start:0;transform:translateY(50%)}.nav-item__addon.is-bottom-center{inset-block-end:0;inset-inline-start:50%;transform:translate(-50%, 50%)}.nav-item__addon.is-bottom-end{inset-block-end:0;inset-inline-end:0;transform:translateY(50%)}.nav-item:hover,.nav-item:focus-visible{color:var(--q-navbar-item-fg-hover, var(--q-fg-base, #f9fafb));background:var(--q-navbar-item-bg-hover, var(--q-bg-surface-2, #374151));outline:none}.nav-item:focus-visible{box-shadow:var(--q-glow-interactive, 0 0 20px rgba(96, 165, 250, 0.3))}.nav-item.is-active{color:var(--q-navbar-item-active-fg, var(--q-color-primary, #60a5fa));background:var(--q-navbar-item-active-bg, color-mix(in srgb, var(--q-color-primary, #60a5fa) 10%, transparent))}.nav-item.is-disabled,.nav-item:disabled{color:var(--q-navbar-item-disabled-fg, var(--q-fg-muted, #9ca3af));cursor:not-allowed;opacity:0.7}.nav-item__icon{flex:0 0 auto}:host([edge='left']) .brand-link,:host([edge='right']) .brand-link,:host([edge='left']) .desktop-nav,:host([edge='right']) .desktop-nav,:host([edge='left']) .desktop-actions,:host([edge='right']) .desktop-actions{width:100%}:host([edge='left']) .desktop-nav,:host([edge='right']) .desktop-nav,:host([edge='left']) .desktop-actions,:host([edge='right']) .desktop-actions{flex-direction:column;align-items:stretch}:host([edge='left']) .desktop-actions,:host([edge='right']) .desktop-actions{justify-content:flex-end}:host([edge='left']) .nav-item,:host([edge='right']) .nav-item{width:100%;justify-content:flex-start}:host([edge='left']) .nav-item-shell,:host([edge='right']) .nav-item-shell{justify-self:stretch;width:100%}:host([edge='left']) .nav-item-shell.is-icon-only,:host([edge='right']) .nav-item-shell.is-icon-only{width:var(--q-navbar-item-icon-only-size, 40px);align-self:center}:host([edge='left']) .nav-item.is-icon-only,:host([edge='right']) .nav-item.is-icon-only{width:var(--q-navbar-item-icon-only-size, 40px);align-self:center;justify-content:center}.nav-item__label{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.nav-item.is-icon-only{min-width:var(--q-navbar-item-icon-only-size, 40px);min-height:var(--q-navbar-item-icon-only-size, 40px);padding:var(--q-navbar-item-icon-only-padding, 8px)}.nav-item.is-icon-only .nav-item__label{display:none}.menu-button{display:none;width:40px;height:40px;align-items:center;justify-content:center;flex-direction:column;gap:4px;border:var(--q-navbar-menu-border, 1px solid var(--q-border-color, #374151));border-radius:var(--q-radius-md, 7px);color:var(--q-navbar-fg, var(--q-fg-base, #f9fafb));background:var(--q-navbar-menu-bg, transparent);cursor:pointer}.menu-button span{display:block;width:18px;height:2px;border-radius:999px;background:currentColor}.mobile-panel{display:none}@media (max-width: 720px){:host([edge='top']) .desktop-actions,:host([edge='bottom']) .desktop-actions{display:none}:host([edge='top']) .navbar-row,:host([edge='bottom']) .navbar-row{flex-wrap:wrap;justify-content:space-between;padding:var(--q-navbar-mobile-padding, var(--q-navbar-edge-mobile-padding, 0 16px))}:host([edge='top'][mobile-mode='menu']) .desktop-nav,:host([edge='bottom'][mobile-mode='menu']) .desktop-nav{display:none;order:3;flex:1 0 100%;flex-direction:column;align-items:stretch;gap:6px}:host([edge='bottom'][mobile-mode='menu']) .desktop-nav{order:-1}:host([edge='top'][mobile-mode='menu']) .navbar.is-open .desktop-nav,:host([edge='bottom'][mobile-mode='menu']) .navbar.is-open .desktop-nav{display:flex}:host([edge='top'][mobile-mode='menu']) .desktop-nav .nav-item-shell,:host([edge='bottom'][mobile-mode='menu']) .desktop-nav .nav-item-shell,:host([edge='top'][mobile-mode='menu']) .desktop-nav .nav-item,:host([edge='bottom'][mobile-mode='menu']) .desktop-nav .nav-item{width:100%}:host([edge='top'][mobile-mode='menu']) .desktop-nav .nav-item,:host([edge='bottom'][mobile-mode='menu']) .desktop-nav .nav-item{justify-content:flex-start}:host([edge='top'][mobile-mode='menu']) .desktop-nav slot[name='nav'],:host([edge='bottom'][mobile-mode='menu']) .desktop-nav slot[name='nav']{display:none}:host([edge='top']) .menu-button,:host([edge='bottom']) .menu-button{display:inline-flex}:host([edge='top']) .mobile-panel,:host([edge='bottom']) .mobile-panel{display:none;padding:var(--q-navbar-mobile-panel-padding, 8px 16px 16px);background:var(--q-navbar-mobile-bg, var(--q-navbar-bg, var(--q-bg-surface-1, #1f2937)))}:host([edge='top']) .mobile-panel{border-top:var(--q-navbar-border, 1px solid var(--q-border-color, #374151))}:host([edge='bottom']) .navbar{display:flex;flex-direction:column-reverse}:host([edge='bottom']) .mobile-panel{border-bottom:var(--q-navbar-border, 1px solid var(--q-border-color, #374151))}:host([edge='top']) .navbar.is-open .mobile-panel.has-content,:host([edge='bottom']) .navbar.is-open .mobile-panel.has-content{display:block}.mobile-nav,.mobile-actions{display:flex;flex-direction:column;gap:6px}.mobile-actions{margin-top:12px}.mobile-nav .nav-item{justify-content:flex-start;width:100%}:host([edge='top'][mobile-mode='inline']) .desktop-nav,:host([edge='bottom'][mobile-mode='inline']) .desktop-nav{display:flex}:host([edge='top'][mobile-mode='inline']) .menu-button,:host([edge='top'][mobile-mode='inline']) .mobile-panel,:host([edge='bottom'][mobile-mode='inline']) .menu-button,:host([edge='bottom'][mobile-mode='inline']) .mobile-panel{display:none}}";export{r as q_navbar}
|