cannot find "theme.css" resource of "primefaces-harmony-rebirth" library

Post Reply
senleft
Posts: 4
Joined: 26 Jul 2016, 22:00

11 Jul 2018, 17:06

Hello,

I trying to run the provided harmony-1.0.2 sample project on the IBM liberty 17.0.0.1. The Liberty JSF implementation is based on the MyFaces open source implementation.
So I removed the org.glassfish:javax.faces:2.2.8 dependency to exclude extra JSF implementation.
Application deployed successfully.
When I try to open it in browser the below error occurred:

Code: Select all

Exception thrown by application class 'javax.faces.webapp.FacesServlet.service:214'
javax.servlet.ServletException: Error loading css, cannot find "theme.css" resource of "primefaces-harmony-rebirth" library ...
Caused by: javax.faces.FacesException: Error loading css, cannot find "theme.css" resource of "primefaces-harmony-rebirth" library
I checked the referenced library and found that only theme.scss is available

Am I missed required steps for preparing harmony-1.0.2.war ?

huseyinT
Posts: 123
Joined: 27 Mar 2016, 13:05

12 Jul 2018, 07:43

You need to run sass files.

sass --update src/main/webapp/resources/ --sourcemap=none

or

sass -w src/main/webapp/resources/ --sourcemap=none

You can read the documentation

http://primefaces.org/harmony/docs.xhtml

senleft
Posts: 4
Joined: 26 Jul 2016, 22:00

19 Jul 2018, 19:15

Hello,

After installing the sass I tried to execute:
1.

Code: Select all

sass --update src/main/webapp/resources/ --sourcemap=none
Could not find an option named "sourcemap".
2.

Code: Select all

sass --update src/main/webapp/resources/ --no-source-map
--update is not allowed when printing to stdout.
3.

Code: Select all

sass -w src/main/webapp/resources/ --no-source-map
Could not find an option or flag "-w".
None from two provided commands working.
Could you please provide and update the documentation with the commands that will work with the current sass version or specify the sass version that understands provided commands?

huseyinT
Posts: 123
Joined: 27 Mar 2016, 13:05

19 Jul 2018, 20:22

I tested sass version 3.5.5, it works.

Could you try Sass version 3.5.5 ?

senleft
Posts: 4
Joined: 26 Jul 2016, 22:00

19 Jul 2018, 23:21

With sass 3.3.5:

Code: Select all

sass --update src/main/webapp/resources/ --sourcemap=none
OptionParser::NeedlessArgument: needless argument: --sourcemap=none
  Use --trace for backtrace.

Code: Select all

C:\Users\alex>sass -v
Sass 3.3.5 (Maptastic Maple)

C:\Users\alex>sass -h
Usage: sass [options] [INPUT] [OUTPUT]

        --sourcemap                  Create sourcemap files next to the generated CSS files.
So the correct command should be:

Code: Select all

sass -w src/main/webapp/resources/
I believe that you should specify the correct sass version in the documentation.
Last edited by senleft on 20 Jul 2018, 00:21, edited 2 times in total.

senleft
Posts: 4
Joined: 26 Jul 2016, 22:00

20 Jul 2018, 00:19

After CSS generation I started the jetty container.
I found that after the theme changing the CSS is not applied on the sample pages.
You may see it on the following link https://yadi.sk/i/Kp39ucib3ZNBFL
Is it expected?

huseyinT
Posts: 123
Joined: 27 Mar 2016, 13:05

20 Jul 2018, 10:09

I prepare according to the http://primefaces.org/harmony/docs.xhtml , screens.

First screen is about the SASS version and sass --update src/main/webapp/resources/ --sourcemap=none :

https://ibb.co/fAzxWy

After, I command mvn jetty:run, and all browser is like following:

https://ibb.co/ny1QjJ

There is not a problem.

Please check your console. Are you getting an error in the console?

You could delete your cookies ( for chrome : ctrl + shift + delete )

Post Reply

Return to “Harmony - PrimeFaces”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 1 guest