Page 1 of 1

Galleria Component

Posted: 26 Aug 2020, 14:26
by kevinquinn1918
I'm fairly new to React and to PrimeReact, and I can't seem to get the Galleria component to display images. The example uses

Code: Select all

import { PhotoService } from '../service/PhotoService';
. I don't have access to that, so I removed that and made an array of images that I'm trying to load. I'm not sure of what all the properties needed are. I put the image name in itemImageSrc, and used the thumbnailImageSrc and alt properties. The only thing I see are the reverse arrow and forward arrow. I think I may be missing some other modules. I'm using

Code: Select all

import React, { Component } from 'react';
import ReactDOM from 'react-dom';
import classNames from 'classnames';
import { Button } from 'primereact/button';
import { Galleria } from 'primereact/galleria';
import './GalleriaDemo.scss';
I got the carousel to work and other components. Is there a version of this, that I can use on CodePen to debug with a working version?

Thanks,
Kevin

Re: Galleria Component

Posted: 28 Aug 2020, 00:03
by kevinquinn1918
I got it to work. I don't know what I did wrong but I started over and it worked just fine.

One thing I'm finding though is that I don't see any documentation for the PhotoService class used in this component. I looked through and I found that each item needs an id, itemImageSrc, thumbnailImageSrc, alt and title.

Overall, the Galleria looks great, and I put 3 of them on the website I'm making for a client.

Re: Galleria Component

Posted: 13 Sep 2020, 14:43
by leroydakari
kevinquinn1918 wrote:
28 Aug 2020, 00:03
I got it to work. I don't know what I did wrong but I started over and it worked just fine.

One thing I'm finding though is that I don't see any documentation for the PhotoService class used in this component. I looked through and I found that each item needs an id, itemImageSrc, thumbnailImageSrc, alt and title.

Overall, the Galleria looks great, and I put 3 of them on the website I'm making for a client.
I had a similar problem with the Galleria, not working and just like you, I started over and managed to launch it.

Re: Galleria Component

Posted: 10 Oct 2020, 21:22
by mert.sincan
Hi,

Sorry for the delayed response. Could you please attach a codesandbox for us to replicate? Please see our data;
https://github.com/primefaces/primereac ... hotos.json
https://github.com/primefaces/primereac ... Service.js

Best Regards,