I have an image gallery which will be displayed as grid, but when i click on that image i need a dialogue box with that image and text fields with image title and author..
here is my code
https://codesandbox.io/s/github/logeshhy/Material-UI-ImageGallery
How about you save the selected tile instead of the boolean whether the dialog is open or not? And if you have a selected tile, you display the content within the dialog?
I modified your sandbox to reflect that: https://codesandbox.io/s/nameless-cache-75sns
Related
This question is related to my other question at Carousel with thumbnail images at the bottom
I'm trying to implement a similar carousel but only of Images, using ImageViewer and DefaultListModel. When I select a thumbnail image from the bottom carousel, I show corresponding image in the ImageViewer. But what I noticed is that; the list in the ImageViewer doesn't get scrolled to the selected image but the currently displayed image gets replaced with the selected one. The So when I swipe to left or right; the images are different than the original sequence. Following is my code to show the selected image in Imageviewer
imageviewer.setImage(imageviewer.getImageList().getItemAt(selectedImgIndx));
Is there any way to make it behave like a Tab.setSelectedIndex?
Sure, use:
imageviewer.getImageList().setSelectedIndex(idx);
In a Codenameone app, I'm trying to develop a carousel with a thumbnail list at the bottom. I've used Tabs control to display files (of diff types like images, video, text, button etc) in carousel style in the center of a form and another Tabs control to display thumbanail images (of the first carousel files) at the bottom of the form. When a user selects a thumbnail image in the bottom carousel, corresponding component should be displayed in the first carousel.
hi.add(BorderLayout.CENTER, mainCarousel);
hi.add(BorderLayout.SOUTH, bottom_tab);
bottom_tab.addSelectionListener((i1, i2) -> {
// bottom_tab.getTabComponentAt(i2).addPointerPressedListener((i) -> {
mainCarousel.getTabComponentAt(i2).setVisible(true);
mainCarousel.getTabComponentAt(i2).repaint();
// });
});
But the component not getting displayed in the central carousel.
Also, I tried to capture the event addPointerPressedListener, but it's not getting fired when I select a thumbnail image.
You can't set tab components to visible/invisible to show/hide them. That won't work. I'm guessing that what you want is a horizontal list for the bottom UI similar to the answer here.
I would suggest using pointer released always. Notice that this will only get delivered to focusable components or the form. To make sure you get the event you can register a pointer release listener on the form.
Following is the CkEditor I am trying to automate on my website:
CKEditor
I have automated clicking through the Bold, Italics, Subscript and Superscript buttons. However, the dropdown menu for Font color or Text style show up blank on the DOM as follows:
DOM for CKEditor
As you can notice, the span underneath the combo box element is empty. Thus any of the text color options available in the combo box do not show up on the DOM. How to automate clicking through various different text colors?
The issue is that at least this dropdown is inside an iframe. You have to switch context into that iframe before you can select something in the dropdown. The code below is working for me.
driver.findElement(By.cssSelector("a[title='Formatting Styles']")).click();
driver.switchTo().frame("cke_72_frame");
driver.findElement(By.cssSelector("a[title='Borderless Table']")).click();
How can I set a form background with an image.
I tried using the image Viewer component, but the image doesn't span the entire screen.
You can add a backgroudn image with the CodenameOne Designer. In your theme , you can edit the "Form" uiid and set background as IMAGE
Like this :
I have many fields in my profile page. I am making my profile page inline editable with Angularjs X-editable. I am making progress using guide http://vitalets.github.io/angular-xeditable/
With this I made all the fields editable except the image field. I have an image i.e. profile pic and I want it to be in place editable [clicking on the edit icon near by the image, the image should change into the image upload widget and after upload image, it should again change back to the show the new image].
Is X-editable having feature of in place editing the image field ?
Or is there any other alternative ?