pull/5756/head
tugcekucukoglu 2024-05-15 14:56:56 +03:00
commit 14ef7f8acf
3 changed files with 10 additions and 15 deletions

View File

@ -132,16 +132,15 @@ export default {
return '';
},
getCommonStyleSheet({ name = '', theme = {}, params, props = {}, set, defaults }) {
const { primitive, semantic } = this.getCommon({ name, theme, params, set, defaults });
const common_css = `${primitive.css}${semantic.css}`;
const common = this.getCommon({ name, theme, params, set, defaults });
const _props = Object.entries(props)
.reduce((acc, [k, v]) => acc.push(`${k}="${v}"`) && acc, [])
.join(' ');
return Object.entries(common_css || {})
return Object.entries(common || {})
.reduce((acc, [key, value]) => {
if (value) {
const _css = SharedUtils.object.minifyCSS(value);
if (value?.css) {
const _css = SharedUtils.object.minifyCSS(value?.css);
const id = `${key}-variables`;
acc.push(`<style type="text/css" data-primevue-style-id="${id}" ${_props}>${_css}</style>`);

View File

@ -22,11 +22,8 @@ export default defineNuxtConfig({
'/installation': { redirect: { to: '/vite', statusCode: 301 } }
},
primevue: {
usePrimeVue: false,
options: {
ripple: true
},
//importTheme: { from: '@/themes/app-theme.js' },
usePrimeVue: true,
importTheme: { from: '@/themes/app-theme.js' },
resolvePath: function ({ as, from, type }) {
const resolvedPath = from.replace('primevue', '@/components/lib');

View File

@ -1,5 +1,5 @@
import Noir from '@/themes/app-theme';
import PrimeVue from 'primevue/config';
//import Noir from '@/themes/app-theme';
//import PrimeVue from 'primevue/config';
import { reactive } from 'vue';
const $appState = {
@ -18,8 +18,7 @@ const $appState = {
export default defineNuxtPlugin((nuxtApp) => {
nuxtApp.vueApp.use($appState);
nuxtApp.vueApp.use(PrimeVue, {
/*nuxtApp.vueApp.use(PrimeVue, {
theme: Noir
});
});*/
});