1 line
5.1 KiB
Plaintext
1 line
5.1 KiB
Plaintext
|
{"version":3,"file":"VSystemBar.mjs","names":["useBackgroundColor","makeComponentProps","makeElevationProps","useElevation","makeLayoutItemProps","useLayoutItem","makeRoundedProps","useRounded","useSsrBoot","makeTagProps","makeThemeProps","provideTheme","computed","shallowRef","toRef","genericComponent","propsFactory","useRender","makeVSystemBarProps","color","String","height","Number","window","Boolean","VSystemBar","name","props","setup","_ref","slots","themeClasses","backgroundColorClasses","backgroundColorStyles","elevationClasses","roundedClasses","ssrBootStyles","layoutItemStyles","id","order","parseInt","position","layoutSize","elementSize","active","absolute","_createVNode","tag","value","class","style"],"sources":["../../../src/components/VSystemBar/VSystemBar.tsx"],"sourcesContent":["// Styles\nimport './VSystemBar.sass'\n\n// Composables\nimport { useBackgroundColor } from '@/composables/color'\nimport { makeComponentProps } from '@/composables/component'\nimport { makeElevationProps, useElevation } from '@/composables/elevation'\nimport { makeLayoutItemProps, useLayoutItem } from '@/composables/layout'\nimport { makeRoundedProps, useRounded } from '@/composables/rounded'\nimport { useSsrBoot } from '@/composables/ssrBoot'\nimport { makeTagProps } from '@/composables/tag'\nimport { makeThemeProps, provideTheme } from '@/composables/theme'\n\n// Utilities\nimport { computed, shallowRef, toRef } from 'vue'\nimport { genericComponent, propsFactory, useRender } from '@/util'\n\nexport const makeVSystemBarProps = propsFactory({\n color: String,\n height: [Number, String],\n window: Boolean,\n\n ...makeComponentProps(),\n ...makeElevationProps(),\n ...makeLayoutItemProps(),\n ...makeRoundedProps(),\n ...makeTagProps(),\n ...makeThemeProps(),\n}, 'VSystemBar')\n\nexport const VSystemBar = genericComponent()({\n name: 'VSystemBar',\n\n props: makeVSystemBarProps(),\n\n setup (props, { slots }) {\n const { themeClasses } = provideTheme(props)\n const { backgroundColorClasses, backgroundColorStyles } = useBackgroundColor(toRef(props, 'color'))\n const { elevationClasses } = useElevation(props)\n const { roundedClasses } = useRounded(props)\n const { ssrBootStyles } = useSsrBoot()\n const height = computed(() => props.height ?? (props.window ? 32 : 24))\n const { layoutItemStyles } = useLayoutItem({\n id: props.name,\n order: computed(() => parseInt(props.order, 10)),\n position: shallowRef('top'),\n layoutSize: height,\n elementSize: height,\n active: computed(() => true),\n absolute: toRef(props, 'absolute'),\n })\n\n useRender(() => (\n <props.tag\n class={[\n 'v-system-bar',\n { 'v-system-bar--window': props.window },\n themeClasses.value,\n backgroundColorClasses.value,\n elevationClasses.value,\n roundedClasses.value,\n props.class,\n ]}\n style={[\n backgroundColorStyles.value,\n layoutItemStyles.value,\n ssrBootStyles.value,\n props.style,\n ]}\n v-slots={ slots }\n />\n ))\n\n return {}\n },\n})\n\nexport type VSystemBar = InstanceType<typeof VSystemBar>\n"],"mappings":";AAAA;AACA;;AAEA;AAAA,SACSA,kBAAkB;AAAA,SAClBC,kBAAkB;AAAA,SAClBC,kBAAkB,EAAEC,YAAY;AAAA,SAChCC,mBAAmB,EAAEC,aAAa;AAAA,SAClCC,gBAAgB,EAAEC,UAAU;AAAA,SAC5BC,UAAU;AAAA,SACVC,YAAY;AAAA,SACZC,cAAc,EAAEC,YAAY,uCAErC;AACA,SAASC,QAAQ,EAAEC,UAAU,EAAEC,KAAK,QAAQ,KAAK;AAAA,SACxCC,gBAAgB,EAAEC,YAAY,EAAEC,SAAS;AAElD,OAAO,MAAMC,mBAAmB,GAAGF,YAAY,CAAC;EAC9CG,KAAK,EAAEC,MAAM;EACbC,MAAM,EAAE,CAACC,MAAM,EAAEF,MAAM,CAAC;EACxBG,MAAM,EAAEC,OAAO;EAEf,GAAGvB,kBAAkB,CAAC,CAAC;EACvB,GAAGC,kBAAkB,CAAC,CAAC;EACvB,GAAGE,mBAAmB,CAAC,CAAC;EACxB,GAAGE,gBAAgB,CAAC,CAAC;EACrB,GAAGG,YAAY,CAAC,CAAC;EACjB,GAAGC,cAAc,CAAC;AACpB,CAAC,EAAE,YAAY,CAAC;AAEhB,OAAO,MAAMe,UAAU,GAAGV,gBAAgB,CAAC,CAAC,CAAC;EAC3CW,IAAI,EAAE,YAAY;EAElBC,KAAK,EAAET,mBAAmB,CAAC,CAAC;EAE5BU,KAAKA,CAAED,KAAK,EAAAE,IAAA,EAAa;IAAA,IAAX;MAAEC;IAAM,CAAC,GAAAD,IAAA;IACrB,MAAM;MAAEE;IAAa,CAAC,GAAGp
|