Opened 6 years ago

Closed 6 years ago

#123 closed defect (fixed)

PSI v.016-2018-07-16 produces a THEME error

Reported by: darcio Owned by:
Priority: Feedback Pending Component: psi
Version: Keywords: psi theme error
Cc:

Description

Upgraded to the latest release of the PSI app. No problem, previous program was completely wiped out, re-installed into empty tree, left the current configuration in the \.home\xxx tree.

The main window comes up fine, however when I open an individual message/chat window the following error message appears in the text window:

"Theme initialization failed: TypeError?: Result of expression 'sheet.cssRules' [null] is not an object."

Any message text entered in the window at this point in time does not show up in the chat history (upper) part of the window.

I will attach a screenshot next to illustrate better.

Attachments (1)

PSI_theme_error_ticket123-msg_window.jpg (29.2 KB) - added by darcio 6 years ago.
screenshot of the CHAT window showing the THEME error msg

Download all attachments as: .zip

Change History (12)

Changed 6 years ago by darcio

screenshot of the CHAT window showing the THEME error msg

comment:1 Changed 6 years ago by Silvan Scherrer

please try a complete new installation. means remove the configurations as well.

comment:2 Changed 6 years ago by Silvan Scherrer

go to themes/chatview/psi/new_classic/index.html and exchange the below part

//	var cssBody = chat.util.findStyleSheet(document.styleSheets[0], "body").style;
//	var cssSentMsg = chat.util.findStyleSheet(document.styleSheets[0], ".sent").style;
//	var cssReceivedMsg = chat.util.findStyleSheet(document.styleSheets[0], ".received").style;
//	var cssInfMsg = chat.util.findStyleSheet(document.styleSheets[0], ".infmsg").style;
//	var cssUserText = chat.util.findStyleSheet(document.styleSheets[0], ".usertext").style;
//	var cssChatSays = chat.util.findStyleSheet(document.styleSheets[0], ".msg>span:first").style;
	var cssBody = '{padding:0; margin:0; width:100%;}';
	var cssSentMsg = '{}';
	var cssReceivedMsg = '{}';
	var cssInfMsg = '{}';
	var cssUserText = '{}';
	var cssChatSays = '{}';

if you use the classic theme, then use themes/chatview/psi/classic/index.html

here it works.

comment:3 Changed 6 years ago by digi

It did not help me. Problem still exists.

comment:4 Changed 6 years ago by Silvan Scherrer

Priority: majorFeedback Pending

as I can't reproduce it anymore locally a fix might not be possible. are you sure you changed the index.html right?

comment:5 Changed 6 years ago by darcio

diver, I will try both the suggestions. Sorry about my delay I am just coming out of a HFPS386 to JFS migration and a HDD to SSD move at the same time...needless to say, a bit of cleanup here and there.

So I will do the following:

1) try the changes you outlined, digi says that did not work for him, let me see what that does here

2) try the NEW version on a FRESH install, so I will point PSI to a temp location as it's 'home' and try it out

Last edited 6 years ago by darcio (previous) (diff)

comment:6 Changed 6 years ago by darcio

@diver in your change above you left out the following:

var cssAlertMsg = chat.util.findStyleSheet(document.styleSheets[0], ".alert").style;[[BR]]

Note, this single line exists only in the CLASSIC theme, it does not exist in the NEW_CLASSIC.

Should this be changed as well, or leave it alone?

Last edited 6 years ago by darcio (previous) (diff)

comment:7 in reply to:  6 ; Changed 6 years ago by Digi

Replying to darcio:

@diver in your change above you left out the following:

You're right. Now all is ok. Thank you!

comment:8 in reply to:  7 Changed 6 years ago by darcio

Replying to Digi:

Replying to darcio:

@diver in your change above you left out the following:

You're right. Now all is ok. Thank you!


@Digi, what did you do? Did you replace with a similarly strutured replacement, or did you completely remove it?

comment:9 Changed 6 years ago by Silvan Scherrer

yes in the classic theme you need to change that as well.

var cssAlertMsg = '{font-weight:bold;}'

comment:10 Changed 6 years ago by Silvan Scherrer

as @digi confirms all works now. So I close the ticket.

comment:11 Changed 6 years ago by Silvan Scherrer

Resolution: fixed
Status: newclosed
Note: See TracTickets for help on using tickets.