2023-10-02 10:46:09 +00:00
|
|
|
import BaseStyle from 'primevue/base/style';
|
|
|
|
|
|
|
|
const classes = {
|
|
|
|
root: ({ props }) => [
|
|
|
|
'p-image p-component',
|
|
|
|
{
|
2024-04-10 06:16:00 +00:00
|
|
|
'p-image-preview': props.preview
|
2023-10-02 10:46:09 +00:00
|
|
|
}
|
|
|
|
],
|
|
|
|
image: ({ props }) => props.image,
|
2024-04-10 06:16:00 +00:00
|
|
|
button: 'p-image-preview-mask',
|
2023-10-02 10:46:09 +00:00
|
|
|
icon: 'p-image-preview-icon',
|
|
|
|
mask: 'p-image-mask p-component-overlay p-component-overlay-enter',
|
2023-10-05 07:08:28 +00:00
|
|
|
toolbar: 'p-image-toolbar',
|
2024-04-10 06:16:00 +00:00
|
|
|
rotateRightButton: 'p-image-action p-image-rotate-right-button',
|
|
|
|
rotateLeftButton: 'p-image-action p-image-rotate-left-button',
|
2023-10-02 10:46:09 +00:00
|
|
|
zoomOutButton: ({ instance }) => [
|
2024-04-10 06:16:00 +00:00
|
|
|
'p-image-action p-image-zoom-out-button',
|
2023-10-02 10:46:09 +00:00
|
|
|
{
|
|
|
|
'p-disabled': instance.isZoomOutDisabled
|
|
|
|
}
|
|
|
|
],
|
|
|
|
zoomInButton: ({ instance }) => [
|
2024-04-10 06:16:00 +00:00
|
|
|
'p-image-action p-image-zoom-in-button',
|
2023-10-02 10:46:09 +00:00
|
|
|
{
|
|
|
|
'p-disabled': instance.isZoomInDisabled
|
|
|
|
}
|
|
|
|
],
|
2024-04-10 06:16:00 +00:00
|
|
|
closeButton: 'p-image-action p-image-close-button',
|
|
|
|
preview: 'p-image-original'
|
2023-10-02 10:46:09 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
export default BaseStyle.extend({
|
|
|
|
name: 'image',
|
|
|
|
classes
|
|
|
|
});
|