1

Clients.showNotification(msg, closable) doesn't grow with content

asked 2012-09-25 02:06:05 +0800

RichardL gravatar image RichardL
768 4

As it says in the subject title, the notification information box has a limit to how much text it can hold. I prefer the Clients.showNotification styling over Messagebox, so is it possible in further editions to allow the height of the box to flex to the size of the content?

Thanks,
Richard

delete flag offensive retag edit

8 Replies

Sort by ยป oldest newest

answered 2012-10-03 01:42:04 +0800

samchuang gravatar image samchuang
4084 4

Hi, currently, ZK doesn't provide this feature, you can post new feature request

For now, you can override notification style by

.z-notification .z-notification-cl, 
.z-notification .z-notification-cnt {
    height: 500px;
    width: 250px;
}

link publish delete flag offensive edit

answered 2012-10-23 06:59:26 +0800

Senthilchettyin gravatar image Senthilchettyin flag of India
2611 3 8
http://emrpms.blogspot.in...

Clients.showNotification("hifffff","info", win, "middle_right",10);

Duration is not working. I want to show the notification for 30 sec and auto dismiss.

But no effect when i change the last argument

link publish delete flag offensive edit

answered 2012-11-01 07:02:36 +0800

benbai gravatar image benbai
2228 6
http://www.zkoss.org

The duration is in millisecond, please try

Clients.showNotification("hifffff","info", win, "middle_right",30000);

This works fine for me in ZK 6.5

Regards,
Ben

link publish delete flag offensive edit

answered 2014-01-30 09:57:23 +0800

sarco gravatar image sarco flag of Spain
93 6
https://github.com/sarcow...

updated 2014-01-30 09:57:53 +0800

I'm trying override notification style in ZK7, but it doesn't work. However in ZK 6.5.4 worked fine. Can somebody confirm that is a bug?

Thank you.

link publish delete flag offensive edit

answered 2014-01-30 10:50:54 +0800

MVarun gravatar image MVarun flag of India
268 1 6

Hi sarco,

Here is how you have to override in ZK7.

 .z-notification-pointer ~ .z-notification-content
    {
        display:table-cell;
        width:150px;
        height:50px;
        min-height:60px;
        ${t:borderRadius('5px') };
        padding:5px 18px 5px 45px;
        vertical-align:middle;
    }

Have Fun...

Greetings,

Varun.

link publish delete flag offensive edit

answered 2014-01-30 11:21:36 +0800

sitansu gravatar image sitansu
2254 13
http://java91.blogspot.in...
protected void showNotification(String message) {
    Clients.showNotification(message, Messagebox.INFORMATION, null, null, 3000);
}
link publish delete flag offensive edit

answered 2014-01-30 12:07:15 +0800

sarco gravatar image sarco flag of Spain
93 6
https://github.com/sarcow...

Hi Varun,

Thank you so much,

I have checked that works for Clients.showNotification(msg, component); but without 'component' it doesn't still work.

Thank you!

link publish delete flag offensive edit

answered 2015-06-13 07:59:42 +0800

llturro gravatar image llturro
15

Use this in your CSS:

.z-notification-content {
  width: auto;
}
link publish delete flag offensive edit
Your reply
Please start posting your answer anonymously - your answer will be saved within the current session and published after you log in or create a new account. Please try to give a substantial answer, for discussions, please use comments and please do remember to vote (after you log in)!

[hide preview]

Question tools

Follow

RSS

Stats

Asked: 2012-09-25 02:06:05 +0800

Seen: 404 times

Last updated: Jun 13 '15

Support Options
  • Email Support
  • Training
  • Consulting
  • Outsourcing
Learn More