2023-07-27 07:48:45 +00:00
|
|
|
<template>
|
|
|
|
<DocSectionText v-bind="$attrs">
|
2023-08-02 12:30:28 +00:00
|
|
|
<p>Theming is implemented with the pass through properties in unstyled mode. Example below demonstrates the built-in Tailwind theme.</p>
|
2023-07-27 07:48:45 +00:00
|
|
|
</DocSectionText>
|
|
|
|
<DocSectionCode :code="code" embedded />
|
|
|
|
</template>
|
|
|
|
|
|
|
|
<script>
|
|
|
|
export default {
|
|
|
|
data() {
|
|
|
|
return {
|
|
|
|
code: {
|
|
|
|
composition: `
|
|
|
|
<template>
|
|
|
|
<div class="card">
|
|
|
|
<img alt="Logo" src="https://primefaces.org/cdn/primevue/images/nature/nature3.jpg" @contextmenu="onImageRightClick" class="w-full md:w-auto" aria-haspopup="true" />
|
|
|
|
<ContextMenu ref="menu" :model="items" />
|
|
|
|
</div>
|
|
|
|
</template>
|
|
|
|
|
|
|
|
<script setup>
|
|
|
|
import { ref } from 'vue';
|
|
|
|
|
|
|
|
const menu = ref();
|
|
|
|
const items = ref([
|
|
|
|
{ label: 'View', icon: 'pi pi-fw pi-search' },
|
|
|
|
{ label: 'Delete', icon: 'pi pi-fw pi-trash' }
|
|
|
|
]);
|
|
|
|
|
|
|
|
const onImageRightClick = (event) => {
|
|
|
|
menu.value.show(event);
|
|
|
|
};
|
|
|
|
|
|
|
|
<\/script>`
|
|
|
|
}
|
|
|
|
};
|
|
|
|
}
|
|
|
|
};
|
|
|
|
</script>
|