240 lines
6.7 KiB
JavaScript
240 lines
6.7 KiB
JavaScript
import {
|
|
VImg
|
|
} from "./chunk-TTIGZHWR.js";
|
|
import {
|
|
VExpandTransition
|
|
} from "./chunk-B4JFJDWM.js";
|
|
import {
|
|
makeBorderProps,
|
|
useBorder
|
|
} from "./chunk-X7YBE6PF.js";
|
|
import {
|
|
makeElevationProps,
|
|
useElevation
|
|
} from "./chunk-YJD2PNP6.js";
|
|
import {
|
|
makeRoundedProps,
|
|
useRounded
|
|
} from "./chunk-AQK3CYVW.js";
|
|
import {
|
|
VDefaultsProvider
|
|
} from "./chunk-PAT7NP2Z.js";
|
|
import {
|
|
makeTagProps
|
|
} from "./chunk-2HZIACSB.js";
|
|
import {
|
|
useBackgroundColor
|
|
} from "./chunk-BHV5Z34M.js";
|
|
import {
|
|
useRtl
|
|
} from "./chunk-ENTLCOCZ.js";
|
|
import {
|
|
makeThemeProps,
|
|
provideTheme
|
|
} from "./chunk-3DSR7NCB.js";
|
|
import {
|
|
convertToUnit,
|
|
genericComponent,
|
|
makeComponentProps,
|
|
propsFactory,
|
|
provideDefaults,
|
|
useRender
|
|
} from "./chunk-LZ5T2ERG.js";
|
|
import {
|
|
computed,
|
|
createBaseVNode,
|
|
createVNode,
|
|
normalizeClass,
|
|
normalizeStyle,
|
|
shallowRef
|
|
} from "./chunk-2MKFL3BX.js";
|
|
|
|
// node_modules/vuetify/lib/components/VToolbar/VToolbarTitle.js
|
|
var makeVToolbarTitleProps = propsFactory({
|
|
text: String,
|
|
...makeComponentProps(),
|
|
...makeTagProps()
|
|
}, "VToolbarTitle");
|
|
var VToolbarTitle = genericComponent()({
|
|
name: "VToolbarTitle",
|
|
props: makeVToolbarTitleProps(),
|
|
setup(props, _ref) {
|
|
let {
|
|
slots
|
|
} = _ref;
|
|
useRender(() => {
|
|
const hasText = !!(slots.default || slots.text || props.text);
|
|
return createVNode(props.tag, {
|
|
"class": normalizeClass(["v-toolbar-title", props.class]),
|
|
"style": normalizeStyle(props.style)
|
|
}, {
|
|
default: () => [hasText && createBaseVNode("div", {
|
|
"class": "v-toolbar-title__placeholder"
|
|
}, [slots.text ? slots.text() : props.text, slots.default?.()])]
|
|
});
|
|
});
|
|
return {};
|
|
}
|
|
});
|
|
|
|
// node_modules/vuetify/lib/components/VToolbar/VToolbar.js
|
|
import "/home/david/gitea_repo/personal_development/ServerManagerWebApp/frontend/node_modules/vuetify/lib/components/VToolbar/VToolbar.css";
|
|
var allowedDensities = [null, "prominent", "default", "comfortable", "compact"];
|
|
var makeVToolbarProps = propsFactory({
|
|
absolute: Boolean,
|
|
collapse: Boolean,
|
|
collapsePosition: {
|
|
type: String,
|
|
default: "start"
|
|
},
|
|
color: String,
|
|
density: {
|
|
type: String,
|
|
default: "default",
|
|
validator: (v) => allowedDensities.includes(v)
|
|
},
|
|
extended: {
|
|
type: Boolean,
|
|
default: null
|
|
},
|
|
extensionHeight: {
|
|
type: [Number, String],
|
|
default: 48
|
|
},
|
|
flat: Boolean,
|
|
floating: Boolean,
|
|
height: {
|
|
type: [Number, String],
|
|
default: 64
|
|
},
|
|
image: String,
|
|
title: String,
|
|
...makeBorderProps(),
|
|
...makeComponentProps(),
|
|
...makeElevationProps(),
|
|
...makeRoundedProps(),
|
|
...makeTagProps({
|
|
tag: "header"
|
|
}),
|
|
...makeThemeProps()
|
|
}, "VToolbar");
|
|
var VToolbar = genericComponent()({
|
|
name: "VToolbar",
|
|
props: makeVToolbarProps(),
|
|
setup(props, _ref) {
|
|
let {
|
|
slots
|
|
} = _ref;
|
|
const {
|
|
backgroundColorClasses,
|
|
backgroundColorStyles
|
|
} = useBackgroundColor(() => props.color);
|
|
const {
|
|
borderClasses
|
|
} = useBorder(props);
|
|
const {
|
|
elevationClasses
|
|
} = useElevation(props);
|
|
const {
|
|
roundedClasses
|
|
} = useRounded(props);
|
|
const {
|
|
themeClasses
|
|
} = provideTheme(props);
|
|
const {
|
|
rtlClasses
|
|
} = useRtl();
|
|
const isExtended = shallowRef(props.extended === null ? !!slots.extension?.() : props.extended);
|
|
const contentHeight = computed(() => parseInt(Number(props.height) + (props.density === "prominent" ? Number(props.height) : 0) - (props.density === "comfortable" ? 8 : 0) - (props.density === "compact" ? 16 : 0), 10));
|
|
const extensionHeight = computed(() => isExtended.value ? parseInt(Number(props.extensionHeight) + (props.density === "prominent" ? Number(props.extensionHeight) : 0) - (props.density === "comfortable" ? 4 : 0) - (props.density === "compact" ? 8 : 0), 10) : 0);
|
|
provideDefaults({
|
|
VBtn: {
|
|
variant: "text"
|
|
}
|
|
});
|
|
useRender(() => {
|
|
const hasTitle = !!(props.title || slots.title);
|
|
const hasImage = !!(slots.image || props.image);
|
|
const extension = slots.extension?.();
|
|
isExtended.value = props.extended === null ? !!extension : props.extended;
|
|
return createVNode(props.tag, {
|
|
"class": normalizeClass(["v-toolbar", `v-toolbar--collapse-${props.collapsePosition}`, {
|
|
"v-toolbar--absolute": props.absolute,
|
|
"v-toolbar--collapse": props.collapse,
|
|
"v-toolbar--flat": props.flat,
|
|
"v-toolbar--floating": props.floating,
|
|
[`v-toolbar--density-${props.density}`]: true
|
|
}, backgroundColorClasses.value, borderClasses.value, elevationClasses.value, roundedClasses.value, themeClasses.value, rtlClasses.value, props.class]),
|
|
"style": normalizeStyle([backgroundColorStyles.value, props.style])
|
|
}, {
|
|
default: () => [hasImage && createBaseVNode("div", {
|
|
"key": "image",
|
|
"class": "v-toolbar__image"
|
|
}, [!slots.image ? createVNode(VImg, {
|
|
"key": "image-img",
|
|
"cover": true,
|
|
"src": props.image
|
|
}, null) : createVNode(VDefaultsProvider, {
|
|
"key": "image-defaults",
|
|
"disabled": !props.image,
|
|
"defaults": {
|
|
VImg: {
|
|
cover: true,
|
|
src: props.image
|
|
}
|
|
}
|
|
}, slots.image)]), createVNode(VDefaultsProvider, {
|
|
"defaults": {
|
|
VTabs: {
|
|
height: convertToUnit(contentHeight.value)
|
|
}
|
|
}
|
|
}, {
|
|
default: () => [createBaseVNode("div", {
|
|
"class": "v-toolbar__content",
|
|
"style": {
|
|
height: convertToUnit(contentHeight.value)
|
|
}
|
|
}, [slots.prepend && createBaseVNode("div", {
|
|
"class": "v-toolbar__prepend"
|
|
}, [slots.prepend?.()]), hasTitle && createVNode(VToolbarTitle, {
|
|
"key": "title",
|
|
"text": props.title
|
|
}, {
|
|
text: slots.title
|
|
}), slots.default?.(), slots.append && createBaseVNode("div", {
|
|
"class": "v-toolbar__append"
|
|
}, [slots.append?.()])])]
|
|
}), createVNode(VDefaultsProvider, {
|
|
"defaults": {
|
|
VTabs: {
|
|
height: convertToUnit(extensionHeight.value)
|
|
}
|
|
}
|
|
}, {
|
|
default: () => [createVNode(VExpandTransition, null, {
|
|
default: () => [isExtended.value && createBaseVNode("div", {
|
|
"class": "v-toolbar__extension",
|
|
"style": {
|
|
height: convertToUnit(extensionHeight.value)
|
|
}
|
|
}, [extension])]
|
|
})]
|
|
})]
|
|
});
|
|
});
|
|
return {
|
|
contentHeight,
|
|
extensionHeight
|
|
};
|
|
}
|
|
});
|
|
|
|
export {
|
|
makeVToolbarTitleProps,
|
|
VToolbarTitle,
|
|
makeVToolbarProps,
|
|
VToolbar
|
|
};
|
|
//# sourceMappingURL=chunk-H2QFYTJQ.js.map
|